nn::tpl::CTR::GetTexture Function

Syntax

void * GetTexture(
     s32 * mipLevel,
     u32 * mipmapSize,
     const void * pTexPackage,
     const s16 texIndex
);

Arguments

Name Description
out mipLevel Number of mipmap levels.
out mipmapSize Data size (in bytes) of each mipmap (specify an array).
in pTexPackage Pointer to the header of a texture package file that has been loaded.
in texIndex Texture index.

Return Values

Pointer to the start of the texture. The function returns 0 if the index value could not be found.

Description

Gets the texture.

Returns a pointer to the corresponding texture within the package. The main image is also considered to have the maximum size of all the mipmap levels, so if the texture in question is found, the miplevel argument will always have a value of 1 or greater.

Specify valid pointers for mipLevel and mipmapSize. If a NULL pointer is specified, the process stops on an assertion in the Development build.

Revision History

2012/02/01
Added a description of behavior when a NULL pointer is specified for the mipLevel and mipmapSize arguments.
2010/08/16
Initial version.

CONFIDENTIAL