Skip to content

Commit

Permalink
Delete name codec AV1
Browse files Browse the repository at this point in the history
  • Loading branch information
Jamaika1 authored and y-guyon committed Jan 11, 2024
1 parent 2a5809b commit 03de6c1
Showing 1 changed file with 8 additions and 23 deletions.
31 changes: 8 additions & 23 deletions apps/avifenc.c
Original file line number Diff line number Diff line change
Expand Up @@ -230,7 +230,7 @@ static void syntaxLong(void)
printf(" -g,--grid MxN : Encode a single-image grid AVIF with M cols & N rows. Either supply MxN identical W/H/D images, or a single\n");
printf(" image that can be evenly split into the MxN grid and follow AVIF grid image restrictions. The grid will adopt\n");
printf(" the color profile of the first image supplied.\n");
printf(" -c,--codec C : AV1/AV2 codec to use (choose from versions list below)\n");
printf(" -c,--codec C : codec to use (choose from versions list below)\n");
printf(" --exif FILENAME : Provide an Exif metadata payload to be associated with the primary item (implies --ignore-exif)\n");
printf(" --xmp FILENAME : Provide an XMP metadata payload to be associated with the primary item (implies --ignore-xmp)\n");
printf(" --icc FILENAME : Provide an ICC profile payload to be associated with the primary item (implies --ignore-icc)\n");
Expand Down Expand Up @@ -785,7 +785,7 @@ static avifBool avifGetBestCellSize(const char * dimensionStr, uint32_t numPixel

// The maximum AV1 frame size is 65536 pixels inclusive.
if (*cellSize > 65536) {
fprintf(stderr, "ERROR: Cell size %u is bigger %s than the maximum AV1/AV2 frame size 65536.\n", *cellSize, dimensionStr);
fprintf(stderr, "ERROR: Cell size %u is bigger %s than the maximum frame size 65536.\n", *cellSize, dimensionStr);
return AVIF_FALSE;
}

Expand Down Expand Up @@ -1192,13 +1192,7 @@ static avifBool avifEncodeImagesFixedQuality(const avifSettings * settings,
}
#endif

if (settings->codecChoice == AVIF_CODEC_CHOICE_AOM) {
printf("Encoding with AV1 codec ");
}
if (settings->codecChoice == AVIF_CODEC_CHOICE_AVM) {
printf("Encoding with AV2 codec ");
}
printf("'%s' speed [%s], color quality [%d (%s)], alpha quality [%d (%s)]%s, %s, %d worker thread(s), please wait...\n",
printf("Encoding with codec '%s' speed [%s], color quality [%d (%s)], alpha quality [%d (%s)]%s, %s, %d worker thread(s), please wait...\n",
codecName ? codecName : "none",
speedStr,
encoder->quality,
Expand Down Expand Up @@ -1827,7 +1821,7 @@ int main(int argc, char * argv[])
} else {
const char * codecName = avifCodecName(settings.codecChoice, AVIF_CODEC_FLAG_CAN_ENCODE);
if (codecName == NULL) {
fprintf(stderr, "ERROR: AV1/AV2 Codec cannot encode: %s\n", arg);
fprintf(stderr, "ERROR: Codec cannot encode: %s\n", arg);
goto cleanup;
}
}
Expand Down Expand Up @@ -2530,19 +2524,10 @@ int main(int argc, char * argv[])
}

printf("Encoded successfully.\n");
if (settings.codecChoice == AVIF_CODEC_CHOICE_AOM) {
printf(" * Color AV1 total size: %" AVIF_FMT_ZU " bytes\n", byteSizes.colorSizeBytes);
printf(" * Alpha AV1 total size: %" AVIF_FMT_ZU " bytes\n", byteSizes.alphaSizeBytes);
if (byteSizes.gainMapSizeBytes > 0) {
printf(" * Gain Map AV1 total size: %" AVIF_FMT_ZU " bytes\n", byteSizes.gainMapSizeBytes);
}
}
if (settings.codecChoice == AVIF_CODEC_CHOICE_AVM) {
printf(" * Color AV2 total size: %" AVIF_FMT_ZU " bytes\n", byteSizes.colorSizeBytes);
printf(" * Alpha AV2 total size: %" AVIF_FMT_ZU " bytes\n", byteSizes.alphaSizeBytes);
if (byteSizes.gainMapSizeBytes > 0) {
printf(" * Gain Map AV2 total size: %" AVIF_FMT_ZU " bytes\n", byteSizes.gainMapSizeBytes);
}
printf(" * Color total size: %" AVIF_FMT_ZU " bytes\n", byteSizes.colorSizeBytes);
printf(" * Alpha total size: %" AVIF_FMT_ZU " bytes\n", byteSizes.alphaSizeBytes);
if (byteSizes.gainMapSizeBytes > 0) {
printf(" * Gain Map AV1 total size: %" AVIF_FMT_ZU " bytes\n", byteSizes.gainMapSizeBytes);
}
if (isImageSequence) {
if (settings.repetitionCount == AVIF_REPETITION_COUNT_INFINITE) {
Expand Down

0 comments on commit 03de6c1

Please sign in to comment.