nux-1.16.0
nux::GpuDevice Class Reference

List of all members.

Classes

struct  PixelBufferObject

Public Member Functions

ObjectPtr< IOpenGLTexture2DCreateTexture (int Width, int Height, int Levels, BitmapFormat PixelFormat)
ObjectPtr< IOpenGLTexture2DCreateTexture2DFromID (int id, int Width, int Height, int Levels, BitmapFormat PixelFormat)
ObjectPtr
< IOpenGLRectangleTexture
CreateRectangleTexture (int Width, int Height, int Levels, BitmapFormat PixelFormat)
ObjectPtr< IOpenGLCubeTextureCreateCubeTexture (int EdgeLength, int Levels, BitmapFormat PixelFormat)
ObjectPtr< IOpenGLVolumeTextureCreateVolumeTexture (int Width, int Height, int Depth, int Levels, BitmapFormat PixelFormat)
ObjectPtr< IOpenGLAnimatedTextureCreateAnimatedTexture (int Width, int Height, int Depth, BitmapFormat PixelFormat)
ObjectPtr< IOpenGLVertexBufferCreateVertexBuffer (int Length, VBO_USAGE Usage)
ObjectPtr< IOpenGLIndexBufferCreateIndexBuffer (int Length, VBO_USAGE Usage, INDEX_FORMAT Format)
ObjectPtr
< IOpenGLPixelBufferObject
CreatePixelBufferObject (int Size, VBO_USAGE Usage)
ObjectPtr< IOpenGLQueryCreateQuery (QUERY_TYPE Type)
ObjectPtr
< IOpenGLVertexDeclaration
CreateVertexDeclaration (const VERTEXELEMENT *pVertexElements)
ObjectPtr
< IOpenGLFrameBufferObject
CreateFrameBufferObject ()
ObjectPtr< IOpenGLShaderProgramCreateShaderProgram ()
ObjectPtr< IOpenGLVertexShaderCreateVertexShader ()
ObjectPtr< IOpenGLPixelShaderCreatePixelShader ()
ObjectPtr
< IOpenGLAsmShaderProgram
CreateAsmShaderProgram ()
ObjectPtr< IOpenGLAsmVertexShaderCreateAsmVertexShader ()
ObjectPtr< IOpenGLAsmPixelShaderCreateAsmPixelShader ()
int SetTexture (unsigned int TextureUnit, IOpenGLBaseTexture *texture)
int DrawIndexedPrimitive (ObjectPtr< IOpenGLIndexBuffer > IndexBuffer, ObjectPtr< IOpenGLVertexDeclaration > VertexDeclaration, PRIMITIVE_TYPE PrimitiveType, int PrimitiveCount)
int DrawPrimitive (ObjectPtr< IOpenGLVertexDeclaration > VertexDeclaration, PRIMITIVE_TYPE pt_, unsigned vtx_start_, unsigned num_prims_)
int DrawPrimitiveUP (ObjectPtr< IOpenGLVertexDeclaration > VertexDeclaration, PRIMITIVE_TYPE PrimitiveType, unsigned int PrimitiveCount, const void *pVertexStreamZeroData, unsigned int VertexStreamZeroStride)
int SetStreamSource (unsigned int StreamNumber, ObjectPtr< IOpenGLVertexBuffer > pStreamData, unsigned int OffsetInBytes, unsigned int Stride)
void InvalidateVertexBuffer ()
 Setup a NULL vertex buffer.
void InvalidateIndexBuffer ()
 Setup a NULL index buffer.
void InvalidateTextureUnit (int TextureUnitIndex)
 Setup a NULL texture.
unsigned int GetPixelStoreAlignment ()
int AllocateUnpackPixelBufferIndex (int *index)
int FreeUnpackPixelBufferIndex (const int index)
int BindUnpackPixelBufferIndex (const int index)
int BindPackPixelBufferIndex (const int index)
void * LockUnpackPixelBufferIndex (const int index, const int Size)
void * LockPackPixelBufferIndex (const int index, const int Size)
void UnlockUnpackPixelBufferIndex (const int index)
void UnlockPackPixelBufferIndex (const int index)
int FormatFrameBufferObject (unsigned int Width, unsigned int Height, BitmapFormat PixelFormat)
int SetColorRenderTargetSurface (unsigned int ColorAttachmentIndex, ObjectPtr< IOpenGLSurface > pRenderTargetSurface)
int SetDepthRenderTargetSurface (ObjectPtr< IOpenGLSurface > pDepthSurface)
ObjectPtr< IOpenGLSurfaceGetColorRenderTargetSurface (unsigned int ColorAttachmentIndex)
ObjectPtr< IOpenGLSurfaceGetDepthRenderTargetSurface ()
void ActivateFrameBuffer ()
void DeactivateFrameBuffer ()
 Restore the backbuffer as the render target.
void SetCurrentFrameBufferObject (ObjectPtr< IOpenGLFrameBufferObject > fbo)
ObjectPtr
< IOpenGLFrameBufferObject
GetCurrentFrameBufferObject ()
int GetOpenGLMajorVersion () const
int GetOpenGLMinorVersion () const
bool UsePixelBufferObjects () const
GpuBrand GetGPUBrand () const
GpuRenderStatesGetRenderStates ()
GpuInfoGetGpuInfo ()
void ResetRenderStates ()
void VerifyRenderStates ()
ObjectPtr< IOpenGLBaseTextureCreateSystemCapableDeviceTexture (int Width, int Height, int Levels, BitmapFormat PixelFormat)
 Create a texture that the system supports. Rectangle texture or 2D texture.
BaseTextureCreateSystemCapableTexture ()
 Created a cached texture.
bool SUPPORT_GL_ARB_TEXTURE_NON_POWER_OF_TWO () const
bool SUPPORT_GL_EXT_TEXTURE_RECTANGLE () const
bool SUPPORT_GL_ARB_TEXTURE_RECTANGLE () const

Public Attributes

ObjectPtr< IOpenGLTexture2Dbackup_texture0_

Friends

class IOpenGLSurface
class GraphicsEngine

Detailed Description

Definition at line 169 of file GpuDevice.h.


Member Function Documentation

ObjectPtr<IOpenGLBaseTexture> nux::GpuDevice::CreateSystemCapableDeviceTexture ( int  Width,
int  Height,
int  Levels,
BitmapFormat  PixelFormat 
)

Create a texture that the system supports. Rectangle texture or 2D texture.

Texture width. Texture height. Texture number of mipmaps. If 0, all the mipmaps levels are created Texture format.

Returns:
A device texture. Depending on the system capabilities returns a ObjectPtr<IOpenGLTexture2D> or ObjectPtr<IOpenGLRectangleTexture>.

Referenced by nux::WindowCompositor::RestoreRenderingSurface().

BaseTexture* nux::GpuDevice::CreateSystemCapableTexture ( )

Created a cached texture.

Returns:
A cached texture. Depending on the system capabilities, returns a Texture2D or TextureRectangle.

Referenced by nux::CreateTexture2DFromPixbuf().


The documentation for this class was generated from the following files:
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Friends