Gunter
Gunter

Reputation: 23

Can you change decoded format with ffmpeg?

I'm trying to play some videos from my external hard drive onto my TV. However, it seems Planar 4:2:0 YUV 10 bit LE is too demanding for my TV. The video codec for my videos are h264. I have some other videos that are h264 and are able to run on my TV. When I open them on VLC, their decoded format is blank. The problem just occurs when the decoded format is YUV 10-bit.

I'm not too familiar with ffmpeg and I'm not sure what commands I need or if it's possible to change the decoded format.

Upvotes: 0

Views: 2507

Answers (3)

so_
so_

Reputation: 77

I faced the same issue and my file started working when I reduced the UHD quality to HD. It also removed my decoding format somehow. Make sure you are using the same aspect ratio as that of your original video. I used this command :

ffmpeg -i input.mp4 -vf "scale=1920:1080" output.mp4

Upvotes: 0

Riccardo Manfrin
Riccardo Manfrin

Reputation: 741

I also had some video which VLC codec information showed as with

Planar 4:2:0 YUV 10 bit LE

For my raspberry 3 along with x265 to h264, I had to add the : -pix_fmt yuv420p (Credits to @Gyan)

Full command:

ffmpeg -i $FILEIN  -map 0 -c:v libx264 -crf 18 -c:a copy -pix_fmt yuv420p $FILEOUT

Upvotes: 0

Gyan
Gyan

Reputation: 93221

Basic command to get 8-bit standard YUV 4:2:0 is

ffmpeg -i in.mp4 -map 0 -c copy -c:v libx264 -pix_fmt yuv420p +movflags +faststart out.mp4

Upvotes: 4

Related Questions