color primaries (from 1 to INT_MAX) (default unknown)Ĭolor_trc ED.V. It may be better for compatibility to add them to the output file too. Note: if they are passed to the output file, it seems they do nothing to the actual colors but are stored anyway in the metadata of the file (they are displayed by ffprobe). These options have to be passed before the input -i inputFile. Here are the tests we've run to make sure the files are rendered with the same colors both for the input and the output. From our tests, applying a gamma value of 1/2.4 (~0.417) results in the right gamma and colors in the mp4 output file. Without the option at all, the transfer curve (gamma) is not right (darker), even if the colors are the right ones.Īs it seems the -apply_trc option does not work correctly (and exists only for EXR), we've tried applying our own LUT to adjust the gamma. iec61966_2_1 (sRGB) is closer but still a bit too dark The result with the colors the closest to the input file is by using smpte428_1 (which is used in the 4K DCI specs), but there is still a slight difference in the colors (and not just the transfer curve). mp4 files, the colors with this option being a bit too dark. Strangely, -apply_trc bt709 does not result in the right gamma to output. To convert from EXR, in theory, the right -apply_trc option has to be set. Note that the color parameters are set also for the output, in order to have them in the metadata and to make FFProbe/FFmpeg report them correctly, but it is not needed to store the actual colors. Here, all color parameters are set to make sure everything is correct, but the result is exactly the same as the simple version, in terms of color. Ffmpeg -color_range tv -colorspace bt709 -color_primaries bt709 -color_trc bt709 -i '/home/duduf/DEV_SRC/DuME/Test Medias/PNG/MediaTest_%5d.png' -pix_fmt yuv420p -color_range tv -colorspace bt709 -color_primaries bt709 -color_trc bt709 '/home/duduf/DEV_SRC/DuME/Test Medias/MediaTest-ffmpeg.mp4'
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |