Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #pragma once
- #include <eight/vr/vr.h>
- //------------------------------------------------------------------------------
- namespace eight {
- //------------------------------------------------------------------------------
- class OculusDevice : Interface<OculusDevice>
- {
- public:
- void GetRenderTargetSize( uint& w, uint& h ) const;
- u32 GetRenderTargetFlags() const;
- void GetAdapter( GfxAdapterId& ) const;
- void Attach( OsWindow&, GpuDevice&, TextureId backBuffer, TextureId left, TextureId right, u32 textureWidth, u32 textureHeight );
- void GetViewports( Viewport views[2] );
- void GetViewData( ViewData views[2], float near, float far );
- bool BeginFrame( GpuDevice& gpu );//if false, you must still call EndFrame, but nothing will be displayed
- bool EndFrame(GpuDevice& gpu);//if false, device is lost...
- private:
- ~OculusDevice();
- };
- class OculusSystem : Interface<OculusSystem>
- {
- public:
- OculusSystem();
- OculusDevice* CreateDevice( Scope&, GpuInterface&, OsWindowArgs* );
- private:
- ~OculusSystem();
- };
- //------------------------------------------------------------------------------
- } // namespace eight
- //------------------------------------------------------------------------------
Add Comment
Please, Sign In to add comment