png transparency + a texture questions

Post Reply
slenkar
Posts: 43
Joined: Sun Apr 17, 2011 8:10 pm

png transparency + a texture questions

Post by slenkar » Mon May 02, 2011 4:49 am

1-In the EasyGl2d examples folder there is an example called sprites
when I put some black on the 'anya.png' picture it doesnt show up as transparent
(I am using the GL_TEXTURE_COLOR0_TRANSPARENT flag when loading the image )

Is there a way of using the transparency in the png in the sprite?

2-If I include 100 images in a NDS file they wont take up any video ram unless I actually load them with glLoadsprite- is this correct?

slenkar
Posts: 43
Joined: Sun Apr 17, 2011 8:10 pm

Re: png transparency + a texture questions

Post by slenkar » Mon May 02, 2011 2:10 pm

If I include pictures as BIN files they wont take up any normal RAM either will they?

elhobbs
Posts: 355
Joined: Thu Jul 02, 2009 1:19 pm

Re: png transparency + a texture questions

Post by elhobbs » Mon May 02, 2011 4:24 pm

yes, they will take up normal ram if you include bin files.

slenkar
Posts: 43
Joined: Sun Apr 17, 2011 8:10 pm

Re: png transparency + a texture questions

Post by slenkar » Mon May 02, 2011 5:00 pm

For example, GTA for NDS is about 128MB, how do they prevent all assets going into RAM?


If it cant be done thats OK, but I just want to make sure.

elhobbs
Posts: 355
Joined: Thu Jul 02, 2009 1:19 pm

Re: png transparency + a texture questions

Post by elhobbs » Mon May 02, 2011 6:04 pm

2 options for ds/dsi homebrew are libfat and libfilesystem. look in the examples\nds\filesystem directory under your devkitpro installation.

slenkar
Posts: 43
Joined: Sun Apr 17, 2011 8:10 pm

Re: png transparency + a texture questions

Post by slenkar » Mon May 02, 2011 6:33 pm

all the examples are for text files, do you have any examples for loading textures?

elhobbs
Posts: 355
Joined: Thu Jul 02, 2009 1:19 pm

Re: png transparency + a texture questions

Post by elhobbs » Mon May 02, 2011 9:34 pm

no, you may need to put some effort in at this point.

the same steps are used to read txt files as bin files.

Post Reply

Who is online

Users browsing this forum: No registered users and 3 guests