Pimax 5k+ parallel projection HAM mod

Recently I have been playing with the geometry and the HAM and tried what I call “HAM mod” (HAM = hidden area mask).

The original HAM for the parallel projection mode is just a copy-paste from the native mode, i.e it does not take into account the actual projection. Below is a visualization of the native and parallel projection HAMs for Pimax 5k+ with Normal FOV:

The blue mesh is the native HAM (canted by 10°), which is projected into the parallel plane (checkerboard) as the green mesh. Technically, to hide the same area in the parallel projection mode as in the native one, the HAM in the parallel projection mode should have the green shape. Yet it has the red shape (i.e. the copy paste).

The consequence is that there are areas in PP mode, which are rendered into, but never visible, because they are out of the native viewing frustum (anything outside the green trapezoid) or because they should not be visible (green area).

So I modified the HAM to make it follow the green shape this way:

effectively increasing the HAM size from 8.73% to 21.49%, which has a consequence that in SteamVR the automatic SS factor changed from 0.42 to 0.50 (for PiTool RQ=1.0) and it seemed to improve the FPS slightly as well (when comparing with SteamVR SS set to 100%). I tried to get some idea in Elite game menu, and it seemed to give 4-7 FPS more.

I guess it is not much, but since it is free, I am not complaining.

Now doing all this was definitely not a trivial task, so I cannot really recommend it as DIY mod, but the point is that it should be pretty easy to fix for Pimax, they would just need to define the HAMs correctly for PP modes.

Now when you look at the new HAM, you can also notice that there are “non-zero” margins at the top and the bottom of the projection, which are masked. These could technically also be cut off (by changing the viewing frustum) to make the vertical size of the render target smaller and save more performance. Again, an easy thing to do for Pimax, but quite difficult for an “ad-hoc” patch.

Could you fix it, @SweViver, @PimaxUSA, @PimaxVR ? @Sean.Huang @Alex.liu


Interesting. Any performance gain is a +. The new headsets are going to be harder and harder to run.


Wow, sounds great. Hope this can be implemented in the next pitool version :slight_smile:


Great work! :slight_smile:

(EDIT: Hmm… apparently emoticon tokens count toward character count - good to know… :7 :happytwentycharacterface: :stuck_out_tongue: )


whoaaa that is alot of pixels that do not need to be rendered, that’s great work risa2000 :+1: and if they add the last piece og the puzzle you found the “non zero” margins that would gain us even more performance. Not as great as non PP, but alot better. I someone could just fix PP in large FOW the that would be super :grinning: id really like to Play ED in large FOW :smile:


You rock @risa2000! :clap::+1::sunglasses:


That sounds awesome.


Martin and I will show this to the dev team later today. Thank you so much.


hoping that Tuesday will also be announced open source phase-2, with drivers and firmwares


There are situations where even that small amount of additional performance can make a lot of difference (to prevent juddering, for example).


Yes, 4-7 fps is a lot. Nice work !


Ahhh a man of science, excellent. A nice visualization of the practical problem too. Would these sorts of investigations be made easier with full open source access to Pitool and the HMD drivers?


It could help in the investigation, but I guess it would not be obvious even if you have a full access to the source and the HAM data, because the point is more in understanding what is wrong than about the particular implementation. But the fix is much easier, if you have an access to the source and the data, because you just need to modify the data (HAM mesh).

The other fix (changing the viewing frustum definition and therefore repositioning the image on the panel) however would require code change as well and is very difficult to do outside of the Pimax code.


Brilliant work Risa, thanks.

The power of the Pimax community works again.


Wow, those pics look super sweet. :ok_hand:t2:

I think risa deserves some nudes now, don’t you think guys?


Great! Good job, man. Even better, pimaxUSA is picking this up! :+1:


thanks for your feedback, i will share the link with our engineer.


4-7 FPS more

Actually, this could be huge. We could get significantly more total resolution before frame dropping occurs.