VideoHelp Forum




+ Reply to Thread
Results 1 to 5 of 5
  1. Member
    Join Date
    Feb 2022
    Location
    colombo
    Search Comp PM
    Hi All,

    I was trying to convert YUV file to mp4 using the below command.

    ffmpeg -f rawvideo -pix_fmt yuv420p -video_size 640*360 -framerate 25 -i 16778240_16778241.yuv -f mp4 16778240_16778241.mp4

    It converted the video but seems YUV planes are not overlapped properly.
    Image
    [Attachment 63435 - Click to enlarge]


    Then I tried to extract planes separately and found there is a black stripe between each plane.

    ffplay -vf extractplanes=y -f rawvideo -pixel_format yuv420p -video_size 640x360 -i 16778240_16778241.yuv

    Image
    [Attachment 63436 - Click to enlarge]


    Image
    [Attachment 63437 - Click to enlarge]


    Image
    [Attachment 63438 - Click to enlarge]


    Is there a way to detect this stripe and remove it? What may cause this issue?

    Thank You!
    Quote Quote  
  2. Perhaps size is different or there some header at the beginning (not so RAW as you think)?

    Btw seem one of the chroma planes (U?) is horizontally mirrored when compared to Y and second chroma plane also seem there is an offset between U and V...
    Quote Quote  
  3. Member
    Join Date
    Feb 2022
    Location
    colombo
    Search Comp PM
    Hi Pandy,
    Originally Posted by pandy View Post
    Perhaps size is different or there some header at the beginning (not so RAW as you think)?
    Ok this could be the reason. But, I can assure that size is correct

    Originally Posted by pandy View Post
    Btw seem one of the chroma planes (U?) is horizontally mirrored when compared to Y and second chroma plane also seem there is an offset between U and V...
    It is not mirrored, I just extracted it from a different timestamp

    Yes, I can see the offset between all three planes

    Is there a way I can identify and clear these bytes?
    Quote Quote  
  4. Originally Posted by sukithaj View Post
    Ok this could be the reason. But, I can assure that size is correct
    Then some data was lost or there is some error in data alignment

    Originally Posted by sukithaj View Post
    It is not mirrored, I just extracted it from a different timestamp
    Don't blame me - this is your responsibility to provide correct information as it will determine answer you get in exchange.

    Originally Posted by sukithaj View Post
    Yes, I can see the offset between all three planes

    Is there a way I can identify and clear these bytes?
    Crude workaround is to replace all black i.e. "0" by "128" i.e. no color - de-saturate - i.e. only luminance i.e. grayscale will be visible without color artifacts.
    Quote Quote  
  5. Member
    Join Date
    Feb 2022
    Location
    colombo
    Search Comp PM
    Hi Pandy,

    Thank You for the Reply. Let me check if there is any data loss or data format issue.
    Quote Quote  



Similar Threads

Visit our sponsor! Try DVDFab and backup Blu-rays!