Texture2D Class Reference

#import <Texture2D.h>

List of all members.

Public Member Functions

(id) - initWithData:pixelFormat:pixelsWide:pixelsHigh:contentSize:

Properties

Texture2DPixelFormat pixelFormat
NSUInteger pixelsWide
NSUInteger pixelsHigh
GLuint name
CGSize contentSize
GLfloat maxS
GLfloat maxT


Detailed Description

Texture2D class This class allows to easily create OpenGL 2D textures from images, text or raw data. The created Texture2D object will always have power-of-two dimensions. Depending on how you create the Texture2D object, the actual image area of the texture might be smaller than the texture dimensions i.e. "contentSize" != (pixelsWide, pixelsHigh) and (maxS, maxT) != (1.0, 1.0). Be aware that the content of the generated textures will be upside-down!

Member Function Documentation

- (id) initWithData: (const void *)  data
pixelFormat: (Texture2DPixelFormat)  pixelFormat
pixelsWide: (NSUInteger)  width
pixelsHigh: (NSUInteger)  height
contentSize: (CGSize)  size 

Intializes with a texture2d with data


Property Documentation

- (CGSize) contentSize [read, assign]

content size

- (GLfloat) maxS [read, assign]

texture max S

- (GLfloat) maxT [read, assign]

texture max T

- (GLuint) name [read, assign]

texture name

- (Texture2DPixelFormat) pixelFormat [read, assign]

pixelFormat

- (NSUInteger) pixelsHigh [read, assign]

hight in pixels

- (NSUInteger) pixelsWide [read, assign]

width in pixels


The documentation for this class was generated from the following file:

Generated on Tue Jun 9 10:39:45 2009 for cocos2d for iPhone 0.7.3 by  doxygen 1.5.8