Axiom.RenderSystems.OpenGL.GLPBRTTManager.GetContextFor C# (CSharp) Метод

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

Get GL rendering context for a certain component type and size.
public GetContextFor ( PixelComponentType pcType, int width, int height ) : GLContext
pcType PixelComponentType
width int
height int
Результат GLContext
		public GLContext GetContextFor( PixelComponentType pcType, int width, int height )
		{
			// Faster to return main context if the RTT is smaller than the window size
			// and pcType is PixelComponentType.Byte. This must be checked every time because the window might have been resized
			if ( pcType == PixelComponentType.Byte )
			{
				if ( width <= this._mainWindow.Width && height <= this._mainWindow.Height )
					return this._mainGLContext;
			}
			Debug.Assert( pBuffers[ (int)pcType ].PixelBuffer != null );
			return pBuffers[ (int)pcType ].PixelBuffer.Context;
		}