Using SDL2 Render Pixels to create video using ffmpeg
I made a small animation using SDL2 and I want to use ffmpeg to convert it to an h264 encoded video. I’m getting the texture RGBA pixels using SDL_RenderReadPixels
and sending them to ffmpeg for rendering. The video does render, but is all messed up. The following is my code