#include <stdio.h>
#include <stdlib.h>
#include <png.h>
#include "libps2.h"
Include dependency graph for texture.c:
Go to the source code of this file.
Defines | |
#define | MAX_GIF_NUM 32766 |
Functions | |
int | get_exponent_number (int number) |
void | set_default_texenv (TEXTURE *tex) |
int | load_textures (int tex_number, TEXTURE **tex_tbl) |
Set texture to VRAM. | |
void | free_texture (TEXTURE *tex) |
Free a texture data. | |
void | free_tex_tbl (int number, TEXTURE **tex) |
Free a texture table. | |
void * | create_image_data (png_bytep *rows_ptr, int c_type, TEXTURE *tex) |
TEXTURE * | create_texture (int w, int h) |
void | swap4 (png_bytep a, png_bytep b) |
void | fix_png (png_bytep *rows_ptr, int height, int width) |
TEXTURE * | read_png_file (char *file_name) |
read PNG file and create a texture file_name a PNG file | |
TEXTURE * | read_png_file0 (char *file_name, int fix_flag) |
read PNG file and create a texture file_name a PNG file | |
Variables | |
int | g_textop64 |
int | g_zbits |
|
|
|
|
|
|
|
|
|
Free a texture table. This library uses a simple array table to manage several textures. This function erases a texture on that table. Be careful! A erased texture is retained on main memory. So, we have to free that memory area explicitly with using free_texture. |
|
Free a texture data.
|
|
|
|
Set texture to VRAM.
|
|
read PNG file and create a texture file_name a PNG file This function reads a specified PNG image file and creates a texture data. Usually, a texture is a image data to painting 3D object's face. So, this function uses a PNG formated file and read it, then create a texture data. |
|
read PNG file and create a texture file_name a PNG file This function reads a specified PNG image file and creates a texture data. Usually, a texture is a image data to painting 3D object's face. So, this function uses a PNG formated file and read it, then create a texture data. This function is equal to read_png_file function. But, turned up by kono-sensei. |
|
|
|
|