<div dir="ltr">Hi,<br><br>I'm working on a video editor that uses ffmpeg to encode output renders and I'm having some trouble properly tagging .mov files. Specifically I want to set the nclc color tags so that QuickTime and other players will properly display the files.<br><br>If I generate a file with the following ffmpeg command:<br><br>ffmpeg -f lavfi -i color=#E51818:320x240:d=3 -color_primaries 1 -color_trc 13 -colorspace 0 srgb.mov<br><br>I get a file that is correctly interpreted by QuickTime. However when I try to do the same via the C API  things don't go as well. I set the following options:<br><br>codec_ctx->color_primaries = AVCOL_PRI_BT709;<br>codec_ctx->color_trc = AVCOL_TRC_IEC61966_2_1;<br>codec_ctx->colorspace = AVCOL_SPC_RGB;<br><br>And most metadata inspectors (MediaInfo, ffprobe) report the tags as being there. In fact, ffprobe gives the same output for both the clips generated via the ffmpeg command and the clips generated by my code. However, players do not seem to respect the tags in the clips I generate with my code. Interestingly exiftool only reports the "Color Representation: nclc 1 13 0" when looking at clips generated by the ffmpeg command implying there is something happening there that is not in my code.<br><br>I appreciate this is a bit open ended but I wondered if anyone could shine any light on the situation or explain the correct method of setting nclc tags via the C API.<br><br>I have had some success in setting the movflags write_colr flag in that exiftool now shows a "Color Representation" tag.<br><br>av_dict_set(&options, "movflags", "write_colr", (1 << 15));<br><br>However it seems to be ignoring the actual primaries etc. that I then set and just using the defaults. Is this the right path or should I be doing something differently?<br><br>Cheers,<br>Tom<br></div>