0

The last few weeks I've been investigating the Vulkan API. This is my first time doing something with computer graphics and learning C++ but i'm highly interested in learning all of it.

My sole obective is to decode a H.264 file and render it to the screen with Vulkan. I have a RPi4B 1GB.

My understanding is that it is possible to decode with hardware acceleration, but the maximum resolution would be 1920x1080. Since Vulkan apparently don't support video acceleration yet, I looked for an another solution and found OpenMax(OMX).

My questions would be:

Would it be a good practice to decode with OpenMax library and display this content with Vulkan?

How would I approach decoding video with vulkan? How should I copy this data over (create a big buffer)?

Mr.Junior
  • 1
  • 3
  • 1
    Vulkan is overkill if all you need to do is blit an already-decoded frame onto the screen. – Colonel Thirty Two Apr 06 '21 at 15:02
  • @ColonelThirtyTwo I would like to keep CPU usage low and let the GPU do the work. – Mr.Junior Apr 06 '21 at 15:08
  • @ColonelThirtyTwo When blitting an image are you referring to [vkcmdblitimage](https://www.khronos.org/registry/vulkan/specs/1.2-extensions/man/html/vkCmdBlitImage.html) ? – Mr.Junior Apr 06 '21 at 15:10
  • The GPU is literally not going to do anything with your frame that it wouldn't already be doing if you were CPU rendering. Worst case scenario, you'll be initializing all the 3D hardware and software for no reason. By blitting, I mean copying it to the screen. – Colonel Thirty Two Apr 06 '21 at 22:16
  • (Now, it would be another thing entirely if you were actually doing hardware decoding - in which case, the GPU may do a significant amount of work. But as you said in your question, you aren't doing that, so there's no point.) – Colonel Thirty Two Apr 06 '21 at 22:18

0 Answers0