JPEG not working on shoebox

Previous topic - Next topic

ampos

If a jpg file is inside a shoebox, it does not load.

Code (glbasic) Select
loadbmp "background.jpg"

did not work. Don't know if it is because the jpg does not load from a shoebox or if the shoebox tool does not "copy" the jpg file inside the shoebox.

Also,

Code (glbasic) Select
savebmp "back.jpg"

saves a wrong file (bad colors)
check my web and/or my blog :D
http://diniplay.blogspot.com (devblog)
http://www.ampostata.org
http://ampostata.blogspot.com
I own PC-Win, MacBook 13", iPhone 3G/3GS/4G and iPAC-WinCE

Crivens

Yeah I never use jpgs. Would be ideal for backgrounds but I've had loads of problems in GLB from loading causing freezes to complete program shutdowns. And yeah when I used my resize routine on them I got weird colouring when it saved the file. Ie just avoid them for now.

Cheers
Current fave quote: Cause you like musicians and I like people with boobs.

MrTAToad

#2
Yes, I mentioned JPEGs inside Shoebox files a while ago - Gernot said that it wasn't possible to fix...

Using JPEG's should be no problem, although the colouring problem could be to do with with lossy format it uses...

Kitty Hello

It should be possible with a stupid hack. I had not time to do that, yet.

Ian Price

It's been a very long time, but any chance of fixing .JPG files in Shoebox?
I came. I saw. I played.

Kitty Hello

As a hack: openfile, read and write to a temp file.

spacefractal

Could been done internally like copy assets for android.

Etc using that function we did for that.

Could extends to jpg as well there....
Genius.Greedy Mouse - Karma Miwa - Spot Race - CatchOut - PowerUp Elevation - The beagle Jam - Cave Heroes 2023 - https://spacefractal.itch.io/

Ian Price

I don't think it's really a big issue, but if other media can be stored in a shoebox (.BMP. .PNG, .WAV, .OGG, .MP3) why not .JPG? What's so different about this format?
I came. I saw. I played.

Kitty Hello

The jpg lib uses its own fopen() so I can't tell it to read from memory. (or I am too stupid to do so)....

Ian Price

Not at all Gernot. This was not a question about your competence. I know nothing about the differences between the image formats and wondered why the others could be shoeboxed. Now I know.

As I said, it wasn't a major issue, but it was a question asked a long while ago and the issue still existed.
I came. I saw. I played.

spacefractal

As im wrote, we could implement the hack directly in the function internal as well.
Genius.Greedy Mouse - Karma Miwa - Spot Race - CatchOut - PowerUp Elevation - The beagle Jam - Cave Heroes 2023 - https://spacefractal.itch.io/

Kitty Hello