Rocket::Core::TextureLayoutTexture Class Reference

#include <TextureLayoutTexture.h>

Collaboration diagram for Rocket::Core::TextureLayoutTexture:

Public Member Functions

const Vector2iGetDimensions () const
int Generate (TextureLayout &layout, int maximum_dimensions)
byte * AllocateTexture ()

Detailed Description

A texture layout texture is a single rectangular area which sub-rectangles are placed on within a complete texture layout.

Author:
Peter

Member Function Documentation

const Vector2i & Rocket::Core::TextureLayoutTexture::GetDimensions (  )  const

Returns the texture's dimensions. This is only valid after the texture has been generated.

Returns:
The texture's dimensions.

int Rocket::Core::TextureLayoutTexture::Generate ( TextureLayout layout,
int  maximum_dimensions 
)

Attempts to position unplaced rectangles from the layout into this texture. The size of this texture will be determined by its contents.

Parameters:
[in] layout The layout to position rectangles from.
[in] maximum_dimensions The maximum dimensions of this texture. If this is not big enough to place all the rectangles, then as many will be placed as possible.
Returns:
The number of placed rectangles.

byte * Rocket::Core::TextureLayoutTexture::AllocateTexture (  ) 

Allocates the texture.

Returns:
The allocated texture data.


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