ork::Buffer::Parameters Class Reference

A Buffer layout in client memory for transferring pixels to or from GPU. More...

#include <Buffer.h>

List of all members.

Public Member Functions

 Parameters ()
 Creates a new buffer layout with default parameter values.
bool swapBytes () const
 Returns true if little endian mode is used.
bool leastSignificantBitFirst () const
 Returns true if least significant bit is first.
GLint alignment () const
 Returns the alignment of data in memory.
GLsizei compressedSize () const
 Returns the compressed size in bytes of the pixels.
vec3< GLint > subImage2D () const
 Returns the 2D subpart of the buffer that must be used for transferring pixels.
vec2< GLint > subImage3D () const
 Returns the 3D subpart of the buffer that must be used for transferring pixels.
ParametersswapBytes (bool swapBytes)
 Sets the endianness mode to use.
ParametersleastSignificantBitFirst (bool leastSignificantBitFirst)
 Sets the bit ordering mode to use.
Parametersalignment (GLint alignment)
 Sets the alignment of data in memory.
ParameterscompressedSize (GLsizei compressedSize)
 Returns the size in bytes of the compressed pixels.
ParameterssubImage2D (GLint skipPixels, GLint skipRows, GLint rowLength)
 Sets the 2D subpart of the buffer that must be used for transferring pixels.
ParameterssubImage3D (GLint skipImages, GLint imageHeight)
 Sets the 3D subpart of the buffer that must be used for transferring pixels.

Detailed Description

A Buffer layout in client memory for transferring pixels to or from GPU.


Constructor & Destructor Documentation

ork::Buffer::Parameters::Parameters (  ) 

Creates a new buffer layout with default parameter values.


Member Function Documentation

Parameters& ork::Buffer::Parameters::alignment ( GLint  alignment  ) 

Sets the alignment of data in memory.

Parameters:
alignment the alignment of data in memory.
GLint ork::Buffer::Parameters::alignment (  )  const

Returns the alignment of data in memory.

Default is 4 bytes.

Parameters& ork::Buffer::Parameters::compressedSize ( GLsizei  compressedSize  ) 

Returns the size in bytes of the compressed pixels.

Parameters:
compressedSize the size in bytes of the compressed pixels, or 0 if the buffer data is not compressed.
GLsizei ork::Buffer::Parameters::compressedSize (  )  const

Returns the compressed size in bytes of the pixels.

Default is 0, meaning that the buffer contains uncompressed data.

Parameters& ork::Buffer::Parameters::leastSignificantBitFirst ( bool  leastSignificantBitFirst  ) 

Sets the bit ordering mode to use.

Parameters:
leastSignificantBitFirst true if least significant bit is first.
bool ork::Buffer::Parameters::leastSignificantBitFirst (  )  const

Returns true if least significant bit is first.

Default is false.

Parameters& ork::Buffer::Parameters::subImage2D ( GLint  skipPixels,
GLint  skipRows,
GLint  rowLength 
)

Sets the 2D subpart of the buffer that must be used for transferring pixels.

Parameters:
skipPixels the x origin of the subpart to transfer.
skipRows the y origin of the subpart to transfer.
rowLength the total width of the image.
vec3<GLint> ork::Buffer::Parameters::subImage2D (  )  const

Returns the 2D subpart of the buffer that must be used for transferring pixels.

Default is whole buffer.

Returns:
a vector containing the x and y origin of the subpart to transfer, and the total width of the image.
Parameters& ork::Buffer::Parameters::subImage3D ( GLint  skipImages,
GLint  imageHeight 
)

Sets the 3D subpart of the buffer that must be used for transferring pixels.

Parameters:
skipImages the z origin of the subpart to transfer.
imageHeight the total height of the image.
vec2<GLint> ork::Buffer::Parameters::subImage3D (  )  const

Returns the 3D subpart of the buffer that must be used for transferring pixels.

Default is whole buffer.

Returns:
a vector containing the z origin of the subpart to transfer, and the total height of the image.
Parameters& ork::Buffer::Parameters::swapBytes ( bool  swapBytes  ) 

Sets the endianness mode to use.

Parameters:
swapBytes true to use little endian mode.
bool ork::Buffer::Parameters::swapBytes (  )  const

Returns true if little endian mode is used.

Default is false.


Generated on Mon Oct 18 09:36:08 2010 for ork by  doxygen 1.6.1