Experimentation/simulation while waiting for the real thing

#1

Hi,
not sure where/how to post it but finally I managed to strip down to ‘bare bones’ ( probably around 40K or more lines of code :joy: ) our engine so to start ‘moving’ all this stuff into the world of OpenGL with Looking Glass support.

The ideas I am coming out with is a sort of ‘intermediate layer’ where ‘the final output’ gets ‘composed’ for what the ‘output device’ could be.

So after various thinking I came out with an idea along these lines

// Now this is 'the big change, we try to make it as much as generic as possible


numviews = display_compositor->GetNumberOfViews(); // could be 1 .. 2 .. 47 .. or whatever

if (numviews < 1) return -2; // nonsense but hey

display_compositor->BeginFrame(0); // for the moment so

for (i = 0; i < numviews; i++)
{
	display_compositor->BeginView(i, g_Neon_Device, NULL, 0);
	the_Game->draw(i, g_Neon_Device, numviews, NULL);
	display_compositor->EndView(i, g_Neon_Device);
}

display_compositor->EndFrame(0);

// SWAPBUFFERS() i.e. 'PRESENT' is done in the "main loop"

}

This “Display Compositor” is going to be my object / array of objects that handle ‘the final output’ be this 2D, 3Dtv, VR or looking glass.

Yesterday I created a ‘simulation’ where the above code remains the same but the ‘number of views’ changes with following outputs going from 1 to 16

In this ‘16 views’ I am ‘simulating the quilt’ with different camera angles.

The point is ‘the game’ does not know about it but works the same.

Anyway now I have this ‘cube framework’ I am starting to re-design all the ‘graphic driver part’ from DX into OpenGL while waiting for the looking glass to show up in the post next month :smiley:

Hopefully by that time I’ll have a basic of OpenGL stuff working so I’ll be able to integrate it quick.

Can’t wait to see if I can really make - we’ll see about the frame rate - our full game engine just work and output on the looking glass, in theory, it should be possible :smile:

3 Likes