diff options
| author | Joe Ludwig <[email protected]> | 2013-12-03 08:54:16 -0800 |
|---|---|---|
| committer | Joe Ludwig <[email protected]> | 2013-12-03 08:54:16 -0800 |
| commit | beaae8ac45a2f322a792404092d4482065bef7ef (patch) | |
| tree | 747f35193ba235f0f0b070c05b53468a54559c8e /mp/src/public/togl/osx/cglmfbo.h | |
| parent | Make .xcconfigs text files too. (diff) | |
| download | source-sdk-2013-beaae8ac45a2f322a792404092d4482065bef7ef.tar.xz source-sdk-2013-beaae8ac45a2f322a792404092d4482065bef7ef.zip | |
Updated the SDK with the latest code from the TF and HL2 branches
* Adds support for Visual Studio 2012 and 2013
* VR Mode:
. Switches from headtrack.dll to sourcevr.dll
. Improved readability of the UI in VR
. Removed the IPD calibration tool. TF2 will now obey the Oculus
configuration file. Use the Oculus calibration tool in your SDK or
install and run "OpenVR" under Tools in Steam to calibrate your IPD.
. Added dropdown to enable VR mode in the Video options. Removed the -vr
command line option.
. Added the ability to switch in and out of VR mode without quitting the
game
. By default VR mode will run full screen. To switch back to a
borderless window set the vr_force_windowed convar.
. Added support for VR mode on Linux
* Many assorted bug fixes and other changes from Team Fortress in
various shared files
Diffstat (limited to 'mp/src/public/togl/osx/cglmfbo.h')
| -rw-r--r-- | mp/src/public/togl/osx/cglmfbo.h | 180 |
1 files changed, 90 insertions, 90 deletions
diff --git a/mp/src/public/togl/osx/cglmfbo.h b/mp/src/public/togl/osx/cglmfbo.h index ccf3e970..c94bac70 100644 --- a/mp/src/public/togl/osx/cglmfbo.h +++ b/mp/src/public/togl/osx/cglmfbo.h @@ -1,91 +1,91 @@ //========= Copyright Valve Corporation, All rights reserved. ============// -// -// cglmfbo.h -// GLMgr FBO's (render targets) -// -//=============================================================================== - -#ifndef CGLMFBO_H -#define CGLMFBO_H - -#pragma once - -#include "togl/rendermechanism.h" - -// good FBO references / recaps -// http://www.songho.ca/opengl/gl_fbo.html -// http://www.gamedev.net/reference/articles/article2331.asp - -// ext links - -// http://www.opengl.org/registry/specs/EXT/framebuffer_object.txt -// http://www.opengl.org/registry/specs/EXT/framebuffer_multisample.txt - -//=============================================================================== - -// tokens not in the SDK headers - -#ifndef GL_DEPTH_STENCIL_ATTACHMENT_EXT - #define GL_DEPTH_STENCIL_ATTACHMENT_EXT 0x84F9 -#endif - -//=============================================================================== - -// forward declarations - -class GLMContext; - -// implicitly 16 maximum color attachments possible -enum EGLMFBOAttachment { - kAttColor0, kAttColor1, kAttColor2, kAttColor3, - kAttColor4, kAttColor5, kAttColor6, kAttColor7, - kAttColor8, kAttColor9, kAttColor10, kAttColor11, - kAttColor12, kAttColor13, kAttColor14, kAttColor15, - kAttDepth, kAttStencil, kAttDepthStencil, - kAttCount -}; - -struct GLMFBOTexAttachParams -{ - CGLMTex *m_tex; - int m_face; // keep zero if not cube map - int m_mip; // keep zero if notmip mapped - int m_zslice; // keep zero if not a 3D tex -}; - -class CGLMFBO -{ - -public: - -protected: - friend class GLMContext; // only GLMContext can make CGLMFBO objects - friend class GLMTester; - friend class CGLMTex; - - friend class IDirect3D9; - friend class IDirect3DDevice9; - - CGLMFBO( GLMContext *ctx ); - ~CGLMFBO( ); - - void TexAttach( GLMFBOTexAttachParams *params, EGLMFBOAttachment attachIndex, GLenum fboBindPoint = GL_FRAMEBUFFER_EXT ); - void TexDetach( EGLMFBOAttachment attachIndex, GLenum fboBindPoint = GL_FRAMEBUFFER_EXT ); - // you can also pass GL_READ_FRAMEBUFFER_EXT or GL_DRAW_FRAMEBUFFER_EXT to selectively bind the receiving FBO to one or the other. - - void TexScrub( CGLMTex *tex ); - // search and destroy any attachment for the named texture - - bool IsReady( void ); // aka FBO completeness check - ready to draw - - GLMContext *m_ctx; // link back to parent context - - GLuint m_name; // name of this FBO in the context - - GLMFBOTexAttachParams m_attach[ kAttCount ]; // indexed by EGLMFBOAttachment - - int m_sizeX,m_sizeY; -}; - - -#endif +//
+// cglmfbo.h
+// GLMgr FBO's (render targets)
+//
+//===============================================================================
+
+#ifndef CGLMFBO_H
+#define CGLMFBO_H
+
+#pragma once
+
+#include "togl/rendermechanism.h"
+
+// good FBO references / recaps
+// http://www.songho.ca/opengl/gl_fbo.html
+// http://www.gamedev.net/reference/articles/article2331.asp
+
+// ext links
+
+// http://www.opengl.org/registry/specs/EXT/framebuffer_object.txt
+// http://www.opengl.org/registry/specs/EXT/framebuffer_multisample.txt
+
+//===============================================================================
+
+// tokens not in the SDK headers
+
+#ifndef GL_DEPTH_STENCIL_ATTACHMENT_EXT
+ #define GL_DEPTH_STENCIL_ATTACHMENT_EXT 0x84F9
+#endif
+
+//===============================================================================
+
+// forward declarations
+
+class GLMContext;
+
+// implicitly 16 maximum color attachments possible
+enum EGLMFBOAttachment {
+ kAttColor0, kAttColor1, kAttColor2, kAttColor3,
+ kAttColor4, kAttColor5, kAttColor6, kAttColor7,
+ kAttColor8, kAttColor9, kAttColor10, kAttColor11,
+ kAttColor12, kAttColor13, kAttColor14, kAttColor15,
+ kAttDepth, kAttStencil, kAttDepthStencil,
+ kAttCount
+};
+
+struct GLMFBOTexAttachParams
+{
+ CGLMTex *m_tex;
+ int m_face; // keep zero if not cube map
+ int m_mip; // keep zero if notmip mapped
+ int m_zslice; // keep zero if not a 3D tex
+};
+
+class CGLMFBO
+{
+
+public:
+
+protected:
+ friend class GLMContext; // only GLMContext can make CGLMFBO objects
+ friend class GLMTester;
+ friend class CGLMTex;
+
+ friend class IDirect3D9;
+ friend class IDirect3DDevice9;
+
+ CGLMFBO( GLMContext *ctx );
+ ~CGLMFBO( );
+
+ void TexAttach( GLMFBOTexAttachParams *params, EGLMFBOAttachment attachIndex, GLenum fboBindPoint = GL_FRAMEBUFFER_EXT );
+ void TexDetach( EGLMFBOAttachment attachIndex, GLenum fboBindPoint = GL_FRAMEBUFFER_EXT );
+ // you can also pass GL_READ_FRAMEBUFFER_EXT or GL_DRAW_FRAMEBUFFER_EXT to selectively bind the receiving FBO to one or the other.
+
+ void TexScrub( CGLMTex *tex );
+ // search and destroy any attachment for the named texture
+
+ bool IsReady( void ); // aka FBO completeness check - ready to draw
+
+ GLMContext *m_ctx; // link back to parent context
+
+ GLuint m_name; // name of this FBO in the context
+
+ GLMFBOTexAttachParams m_attach[ kAttCount ]; // indexed by EGLMFBOAttachment
+
+ int m_sizeX,m_sizeY;
+};
+
+
+#endif
|