Login [Register]
Don't have an account? Register now to chat, post, use our tools, and much more.
How would i set a picture as the background in my ICE program?
Use ConvPNG (found here).
Create a PNG that's 160x120 (or make sure your current PNG is 160 pixels by 120 pixels).
Put the PNG in the same folder as ConvPNG.
Create a file called convpng.ini in the same folder as ConvPNG.
Open convpng.ini in a text editor and make it look like this:

Code:
#AppvarICE   : <AppVarName>
#PNGImages   :
 <PNGName>

#GroupICE   : ice_gfx
#Palette   : xlibc
#PNGImages   :
 <PNGName>

where <AppVarName> is the name of the AppVar (E.G. IMAGE) and <PNGName> is the name of the PNG minus the .png (E.G. myimage)

Run ConvPNG and send the AppVar that gets created to your calculator.
To display it in your program (fullscreen), use:

Code:
LoadData("<AppVarName>",0,3)→<SpriteName>
det(62,<SpriteName>,0,0,2,2

Where <SpriteName> is the name of the pointer that you would like to store the sprite in (E.G. BGPIC)

You must include the AppVar with your program and have them both on your calc at all times.

Hope this helps,
calclover2514 wrote:
Use ConvPNG (found here).
Create a PNG that's 160x120 (or make sure your current PNG is 160 pixels by 120 pixels).
Put the PNG in the same folder as ConvPNG.
Create a file called convpng.ini in the same folder as ConvPNG.
Open convpng.ini in a text editor and make it look like this:

Code:
#AppvarICE   : <AppVarName>
#PNGImages   :
 <PNGName>

#GroupICE   : ice_gfx
#Palette   : xlibc
#PNGImages   :
 <PNGName>

where <AppVarName> is the name of the AppVar (E.G. IMAGE) and <PNGName> is the name of the PNG minus the .png (E.G. myimage)

Run ConvPNG and send the AppVar that gets created to your calculator.
To display it in your program (fullscreen), use:

Code:
LoadData("<AppVarName>",0,3)→<SpriteName>
det(62,<SpriteName>,0,0,2,2

Where <SpriteName> is the name of the pointer that you would like to store the sprite in (E.G. BGPIC)

You must include the AppVar with your program and have them both on your calc at all times.

Hope this helps,


This helped a ton! Thank you so much!
Tried using convpng, but convpng.log just said:

opened convpng.ini
[error] unknown command #AppvarICE\'a0 (line 12)

What does this mean and how can I fix it?
Argus wrote:
Tried using convpng, but convpng.log just said:

opened convpng.ini
[error] unknown command #AppvarICE\'a0 (line 12)

What does this mean and how can I fix it?

Are you using the latest version of convPNG?
(NOT the one included in ICE, but the one in mateoconlechuga's repository)



EDIT:
It appears that your text editor has converted the spaces in between 'AppvarICE' and the colon with some other character (a tab or something else). Simply remove the whitespace in between the two and it should work.

Fixed Example:

Code:
#AppvarICE: <AppVarName>
#PNGImages:
<PNGName>

#GroupICE: ice_gfx
#Palette: xlibc
#PNGImages:
<PNGName>

It looks less pretty, but it will probably work.
Thanks for the help! It worked this time!
  
Register to Join the Conversation
Have your own thoughts to add to this or any other topic? Want to ask a question, offer a suggestion, share your own programs and projects, upload a file to the file archives, get help with calculator and computer programming, or simply chat with like-minded coders and tech and calculator enthusiasts via the site-wide AJAX SAX widget? Registration for a free Cemetech account only takes a minute.

» Go to Registration page
Page 1 of 1
» All times are GMT - 5 Hours
 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum

 

Advertisement