Export problem (codec)

So I just exported a video using the libx264 codec and when viewing the video via films and TV on Windows 10 the video is absent and all I can hear is the audio. Is there a reason why this would be happening? Video stats are 16:9 aspect ratio, 1920x1080 @ 60fps. Codec: libx264 with quality at 100% and quality-based VBR.

100% quality is a different mode, specifically 4:4:4 Lossless mode. The Windows player doesn’t know how to play that mode. Use a lower quality percent and it will work. The human eye can’t really detect additional detail beyond 68%. Default setting is 55% for a good compromise of quality and file size.

You know what’s strange though? When I leave all settings the same but change the codec to libx265 it comes out fine and the Films and TV is able to play it perfectly fine. Why would that be the case?

crf 0 , qp 0 , or 100% quality are all equivalent and lossless for libx264, but it is not for libx265

libx265 requires a --lossless switch to enable lossless mode (and it occurs at qp=4, not qp=0)

Is libx265 the best codec? Before I tried using it I used h264_nvenc and when comparing screenshots between outputs of libx265 and h264_nvenc the former has less quality loss than the latter. I thought h264 was lossless, is this not the case?

“best” by what criteria ?

In general, libx265 will offer higher compression ratio than any h264 derivative (higher quality at a given bitrate or filesize)

libx264 (software h264 encoder) will compress better than h264_nvenc

h264 can be lossy or lossless - it depends on the settings used. libx264 at 100% quality is the same thing as crf0 - which is lossless

I’m using h264_nvenc at 100% quality and it doesn’t look as good as libx265 at 100% quality. How do I export using libx264 while keeping the quality value at 100%? I know it doesn’t need to be 100% but I insist that it be 100%. I would attach screenshots but I can only attach one as a new user despite needing to attach more than that to show the comparison.

For libx264, you can use 100%, just use a different player like VLC or MPV. Your player doesn’t support lossless AVC decoding

If you need to use that player, use 99% quality or crf1, because that player probably does not support lossless decoding

For libx265, 100% isn’t really “100%” in that it’s not lossless. The quality can be higher (measureable with metrics)

So you’re saying that even though Films and TV can’t display the video, the video is still there?

It is viewable in VLC but that’s a big inconvenience to me and screenshots from libx264 and libx265 show no significant change in quality so I think I’ll stick with libx265, less quality loss than h264_nvenc but can be viewed without requiring 3rd party software. Plus libx264 drastically increases the file size.