Axiom.RenderSystems.OpenGL.GLFrameBufferObject.BindSurface C# (CSharp) Метод

BindSurface() публичный Метод

Bind a surface to a certain attachment point.
public BindSurface ( int attachment, Axiom.RenderSystems.OpenGL.GLSurfaceDesc target ) : void
attachment int 0..Config.MaxMultipleRenderTargets-1
target Axiom.RenderSystems.OpenGL.GLSurfaceDesc
Результат void
		public void BindSurface( int attachment, GLSurfaceDesc target )
		{
			//assert( attachment < OGRE_MAX_MULTIPLE_RENDER_TARGETS );
			_color[ attachment ] = target;
			// Re-initialise
			if ( _color[ 0 ].Buffer != null )
				_initialize();
		}

Usage Example

Пример #1
0
		public GLFBORenderTexture( GLFBORTTManager manager, string name, GLSurfaceDesc target, bool writeGamma, int fsaa )
			: base( name, target, writeGamma, fsaa )
		{
			_fbo = new GLFrameBufferObject( manager );

			// Bind target to surface 0 and initialise
			_fbo.BindSurface( 0, target );

			// Get attributes
			width = _fbo.Width;
			height = _fbo.Height;
		}