texture-png.h File Reference

#include "CrabClaw/types.h"
#include "CrabClaw/texture.h"

Functions

int cc_texture_load_png (const char *fn, cc_texture_t *dst)
 Load a PNG image as a texture.

Function Documentation

int cc_texture_load_png ( const char *  fn,
cc_texture_t dst 
)

Load a PNG image as a texture.

This function loads a PNG file from the filesystem, and creates a cc_texture_t object from the image. This object will generally be in CC_TXRFMT_RGBA8888 format (or the platform's closest relative of that format).

Since:
1.0.0
Parameters:
fn The file to load.
dst The texture object to load into.
Returns:
0 on success, non-zero on failure.

SourceForge.net Logo