[FFmpeg-user] Alter YUV values of AVFrames
killkenny64
kennethjjgibson at gmail.com
Thu Feb 2 02:08:28 CET 2012
killkenny64 wrote
>
>
> Mike Scheutzow-3 wrote
>>
>> You must treat the AVFrame as read-only. AVFrame->data often points to
>> the actual reference frame memory used internally by the decoder.
>>
>> You must make a deep copy of AVFrame->data before modifying it, and pass
>> that to the next step.
>>
>
> Thanks for the help, I can see now how problems could arise by changing
> the AVFrame->data.
>
> Is there any chance you could give me a hint or two or point me toward
> some help on making a deep copy of the AVFrame->data? I'm not a big C
> person so I'm swimming in the deep end here.
>
> Thanks =)
>
I have now resolved this issue.
The problem was as Mike Scheutzow-3 suggested.
I was not treating the AVFrame->data as read only. I made a deep copy of the
data, changed it, encoded it and I can now alter the individual frames.
(Even with a gop_size of 12)
Thank you so much for the help! I would still be on this problem otherwise!
(Also learned a lot about GOP which helped me in my project as well so ty)
--
View this message in context: http://ffmpeg-users.933282.n4.nabble.com/Alter-YUV-values-of-AVFrames-tp4346567p4350177.html
Sent from the FFmpeg-users mailing list archive at Nabble.com.
More information about the ffmpeg-user
mailing list