mirror of
https://github.com/ctruLua/ctruLua.git
synced 2025-10-27 16:39:29 +00:00
Updated the sf2dlib and sftdlib; Added the gfx.color.hex() function; Added the New3DS CPU mode control.
As the color order of the sf2dlib changed, you have to change it in your code, or use the color.hex() function. To fix the problems, just change "0xRRGGBBAA" to "0xAABBGGRR". Also, the shader compiler changed to Picasso, so you'll need it in order to compile. https://github.com/fincs/picasso
This commit is contained in:
parent
0105970ab7
commit
b4d025d602
17 changed files with 205 additions and 131 deletions
|
|
@ -35,13 +35,13 @@ int getType(const char *name) {
|
|||
Load a texture from a file. Supported formats: PNG, JPEG, BMP.
|
||||
@function load
|
||||
@tparam string path path to the image file
|
||||
@tparam[opt=PLACE_RAM] number place where to put the loaded texture
|
||||
@tparam[opt=PLACE_VRAM] number place where to put the loaded texture
|
||||
@tparam[opt=auto] number type type of the image
|
||||
@treturn texture the loaded texture object
|
||||
*/
|
||||
static int texture_load(lua_State *L) {
|
||||
const char *path = luaL_checkstring(L, 1);
|
||||
u8 place = luaL_optinteger(L, 2, SF2D_PLACE_RAM); //place in ram by default
|
||||
u8 place = luaL_optinteger(L, 2, SF2D_PLACE_VRAM); //place in vram by default
|
||||
u8 type = luaL_optinteger(L, 3, 3); //type 3 is "search at the end of the filename"
|
||||
|
||||
texture_userdata *texture;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue