views:

158

answers:

2

Hello. I'm trying to make a GUI program with the Android SDK, using their Lunar Lander example as a significant self-teaching tool in the process. I've noticed their sprites' images' backgrounds, which were at least usually pure white, did not show up in their program. I want to ask how they did that, since their site doesn't explain simple things very well.

I've managed to pull that off before on another GUI SDK, wherein all I had to do was to call a function and pass it a few floats to define a certain color, and until my code told it to do otherwise, that function would make sure that that particular color in my sprites' images was totally transparent.

However I've wrestled with the Lunar Lander example and getting my own program to show some custom graphics for a week or two now, and I haven't noticed any such function call in the Lunar Lander example. I tried to look for it, but I did not find anything. I've tried to Google some tutorial or other reference material, but what I've found so far is just straying off into unrelated areas and totally dodging this EXTREMELY important lesson on the SDK's basics.

Any ideas? Thanks!

+1  A: 

you more try to say, that you have a problem, than what the problem really is.

i think, that you just need transparent PNG's

fazo
No, that's just background information. When people just give the smallest skeleton of a summary of anything, then they are far more prone to omit details that could help aid people in TRULY understanding what's being described. The problem there could indeed have been described in one small paragraph, but by giving background information - including a snippet of what I'm really trying to do with a solution to my question - I have decreased my chances of having to post another three or four times. I don't just need a very basic answer; I need one that will actually help.
Panzercrisis
A: 

Just dragging all the PNG's from the drawable folder of the project to my desktop, I can confirm they are all transparent. So you won't be able to find what you are looking for in that project.

jqpubliq
How do I make a PNG's background transparent?
Panzercrisis
if you have a png with a background that isn't transparent, open it in an image editor and delete the color range that is the background. This is harder in some editors than others. Then you should be able to save it with a transparent background. If you are making your own icons, usually you start off with transparency in most image editors.
jqpubliq
Thanks! It looks like Paint is kind of against it, but I can probably go find some other program.
Panzercrisis