example: Use new names of functions

The previous ones have just been deprecated.
This commit is contained in:
Antonio Niño Díaz 2022-10-25 23:47:29 +01:00
parent b3440e9526
commit f1ed942ec9
6 changed files with 11 additions and 11 deletions

View File

@ -52,19 +52,19 @@ int main(void)
NE_TEXGEN_TEXCOORD | NE_TEXTURE_COLOR0_TRANSPARENT,
(void *)button_tex_bin);
NE_PaletteLoad(ButtonPal, (void *)button_pal_bin, 256, NE_PAL256);
NE_MaterialTexSetPal(ButtonImg, ButtonPal);
NE_MaterialSetPalette(ButtonImg, ButtonPal);
NE_MaterialTexLoad(EmptyImg, NE_PAL256, 64, 64,
NE_TEXGEN_TEXCOORD | NE_TEXTURE_COLOR0_TRANSPARENT,
(void *)empty_tex_bin);
NE_PaletteLoad(EmptyPal, (void *)empty_pal_bin, 256, NE_PAL256);
NE_MaterialTexSetPal(EmptyImg, EmptyPal);
NE_MaterialSetPalette(EmptyImg, EmptyPal);
NE_MaterialTexLoad(TrueImg, NE_PAL256, 64, 64,
NE_TEXGEN_TEXCOORD | NE_TEXTURE_COLOR0_TRANSPARENT,
(void *)true_tex_bin);
NE_PaletteLoad(TruePal, (void *)true_pal_bin, 256, NE_PAL256);
NE_MaterialTexSetPal(TrueImg, TruePal);
NE_MaterialSetPalette(TrueImg, TruePal);
// Create one button

View File

@ -34,7 +34,7 @@ int main(void)
NE_MaterialTexLoad(Material, NE_PAL16, 128, 128, NE_TEXGEN_TEXCOORD,
(void *)icon_tex_bin);
NE_PaletteLoad(Palette, (void *)icon_pal_bin, 32, NE_PAL16);
NE_MaterialTexSetPal(Material, Palette);
NE_MaterialSetPalette(Material, Palette);
NE_ClearColorSet(NE_Gray, 31, 63);

View File

@ -72,8 +72,8 @@ int main(void)
NE_PaletteLoadFAT(PaletteBlue, "spiral_blue_pal32_pal.bin", NE_A3PAL32);
NE_PaletteLoadFAT(PaletteRed, "spiral_red_pal32_pal.bin", NE_A3PAL32);
NE_MaterialTexSetPal(MaterialBlue, PaletteBlue);
NE_MaterialTexSetPal(MaterialRed, PaletteRed);
NE_MaterialSetPalette(MaterialBlue, PaletteBlue);
NE_MaterialSetPalette(MaterialRed, PaletteRed);
// Assign material to model
NE_ModelSetMaterial(Model, MaterialBlue);

View File

@ -59,7 +59,7 @@ int main(void)
100, 256, // Width, height (in pixels)
NE_TEXGEN_TEXCOORD, (u8 *)a3pal32_tex_bin);
NE_PaletteLoad(Palette, (u16 *)a3pal32_pal_bin, 32, NE_A3PAL32);
NE_MaterialTexSetPal(Material, Palette);
NE_MaterialSetPalette(Material, Palette);
// Allocate objects for another material
Material2 = NE_MaterialCreate();
@ -68,7 +68,7 @@ int main(void)
NE_MaterialTexLoad(Material2, NE_PAL4, 100, 100, NE_TEXGEN_TEXCOORD,
(u8 *)pal4_tex_bin);
NE_PaletteLoad(Palette2, (u16 *)pal4_pal_bin, 4, NE_PAL4);
NE_MaterialTexSetPal(Material2, Palette2);
NE_MaterialSetPalette(Material2, Palette2);
while (1)
{

View File

@ -60,8 +60,8 @@ int main(void)
NE_PaletteLoad(Palette1, (u16 *)a3pal32_pal_bin, 32, NE_A3PAL32);
NE_PaletteLoad(Palette2, (u16 *)a5pal8_pal_bin, 32, NE_A5PAL8);
NE_MaterialTexSetPal(Material1, Palette1);
NE_MaterialTexSetPal(Material2, Palette2);
NE_MaterialSetPalette(Material1, Palette1);
NE_MaterialSetPalette(Material2, Palette2);
while (1)
{

View File

@ -39,7 +39,7 @@ int main(void)
NE_MaterialTexLoad(Material, NE_PAL256, 256, 256, NE_TEXGEN_TEXCOORD,
(void *)pal256_tex_bin);
NE_PaletteLoad(Palette, (void *)pal256_pal_bin, 32, NE_PAL256);
NE_MaterialTexSetPal(Material, Palette);
NE_MaterialSetPalette(Material, Palette);
// Modify color 254 of the palette so that we can use it to draw with a
// known color