Simplify Oculus example...
...to align it with standard raylib code. Final goal would be having the same code work for every platform with no changes...
This commit is contained in:
parent
b01f5ff6a7
commit
6062201e8f
4 changed files with 16 additions and 14 deletions
|
@ -52,14 +52,9 @@ int main()
|
|||
ClearBackground(RAYWHITE);
|
||||
|
||||
Begin3dMode(camera);
|
||||
//BeginOculusDrawing(camera); // Add it to Begin3dMode() ?
|
||||
|
||||
|
||||
for (int eye = 0; eye < 2; eye++)
|
||||
{
|
||||
// TODO: Probably projection and view matrices could be created here...
|
||||
// ...without the need to create it internally through Begin3dMode()
|
||||
//Begin3dMode(camera);
|
||||
|
||||
SetOculusView(eye);
|
||||
|
||||
DrawCube(cubePosition, 2.0f, 2.0f, 2.0f, RED);
|
||||
|
@ -67,15 +62,10 @@ int main()
|
|||
|
||||
DrawGrid(10, 1.0f);
|
||||
|
||||
// TODO: Call internal buffers drawing directly (rlglDraw()) and...
|
||||
// ...reset internal matrices, instead of letting End3dMode() do that
|
||||
//End3dMode();
|
||||
|
||||
DrawDefaultBuffers(); // Process internal dynamic buffers
|
||||
}
|
||||
|
||||
End3dMode();
|
||||
//EndOculusDrawing(); // Add it to End3dMode() ?
|
||||
|
||||
EndDrawing();
|
||||
//----------------------------------------------------------------------------------
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue