HAP encoding workflow


I’m starting to explore converting video files to the HAP codec for the project I am working on, in which I’m trying to achieve real-time playback of multiple 360 videos and depthkit clips with VFX graph. Is it better to re-export my depthkit clips as image sequences and encode them in ffmpeg, or will it be fine to just convert the combined per pixel videos from H.264 to HAP? Also planning to use KlakHAP to play the HAP videos, will that work with depth kit core or do I need to use AVPro?


Hi Whitt,

Great questions. we’ve used HAP very successfully in the past. The playback performance is great, especially for multiple clips. The cost is huge files and limited platform support

We strongly recommend encoding from image sequence using FFMpeg, otherwise you are double compressing your footage going from H.264 → HAP.

To playback HAP to Depthkit, our supported player is AVPro 2 Ultra: Hap Codec | AVPro Video - Documentation This works with our AVPro player back end. Using KlakHap you’ll have to code your own player to get the video piped into Depthkit

Let us know how it goes!

Gotcha thank you! Will probably start with the 360 videos first, then move on to the combined per pixel videos if necessary. Will report back and let you know how it goes!

1 Like

I can only backup what what James wrote accordingly the png export and the ffmpeg workflow as otherwise (at least in the past) the mp4 have bin scale extrem tiny to the resolution of the depth … I learn then here at the forum that you have to click redifine (if I memorize correctly) to achieve a scaling to rgb size (your choosen recording format) this through the png workflow resulted in top big size scourge material which I then could tweak and tune in ffmpeg … all the best for your tests …



Hi @MartnD Thanks for jumping in to support and add to @WhittSellers question

A quick update for you, last July we released version 0.6.0 which fixed the issues you cite here. See the release notes here

  • Custom Export Resolution & Bitrate: The Depthkit Edit context now supports user-defined resolution contraints for (Multiperspective) Combined-Per-Pixel video and image sequence export formats, as well as user-defined bitrate for (Multiperspective) Combined-Per-Pixel video export formats.
  • Automatic Multi-Row Formatting: Multiperpective Combined per Pixel (CPP) export formats now automatically are formatted into multiple rows to optimize for export resolution constraints. This replaces the multi-row stacking Python script workflow.
  • Improved Export Resolution Calculation: Depthkit now factors the resolution of each component sensor into the scaling of Multiperpective Combined per Pixel (CPP) export formats, improving resolution and reducing aliasing artifacts.