How deform two 2D images to be correctly seen with 3D headset?

Hi, i've made my own 3D raycasting renderer,

I've two simultaneous rendering: one with the ingame perspective a bit on the left for the left eye and one a bit on the right for the right eye, it works (i've to cross the eyes [a sort of stereoscopic technique] and invert the left render and the right one).

IMAGES
(please don't mind the swastikas, those are texture from the old Wolfenstein3D)
https://i.postimg.cc/4yJyKpnf/RAYCAST-ENGINE-2022-01-14-18-49-16-214.png
https://i.postimg.cc/26d380k9/RAYCAST-ENGINE-2022-01-14-18-50-19-311.png
https://i.postimg.cc/c4xt6G8R/RAYCAST-ENGINE-2022-01-14-18-48-09-554.png


The next step is to stream those two images to a 3D headset BUT they need to be corrected in order to be correctly seen with the lenses of the headset (which for the moment will be my phone in a phone support streaming the whole desktop).
I can deform the 2 images before rendering, should be easy, but need the basic method (or formula); or maybe stream half of the desktop to each eyes with some program that do that automatically.. i know nothing on the topic so that's why i'm asking you:

-How i deform the two images?
-How do i stream them to my phone? (For now i'm using a AnyDesk, which is just desktop stream, no any 3D implementation).
Last edited on
are you asking how to align the images so they are as if taken correctly (from 2 cameras a short distance apart) ?
No images are correctly taken, if you check the border of the 2 images you'll notice.

I'm asking how to morph it into this https://freeapk.mobi/gen/screenshots/2556/56/8c/568c2f98dba0c3a085d13bb8f7863d41.png look at the white lines they are deformed in order to look straight when using vr headset with lenses.
Last edited on
I would say its done by putting the images on a surface as a texture with the correct dimensions, but I am really not sure on that one. I would have thought the driver or library would take a normal video stream and reproject it for you, but again, I do not know.
Last edited on
UPDATE: I've bought a "VR Box", one very cheap smartphone support, and its lenses do deform a bit the image but not much so my game, for this support of mine, doesn't need any correction, and considering that these are just experiments made for fun its perfect ahahaha!
Topic archived. No new replies allowed.