This is a read-only archive of the old Scratch 1.x Forums.
Try searching the current Scratch discussion forums.

#1 2011-04-04 20:35:22

cpumaster930
Scratcher
Registered: 2009-02-23
Posts: 100+

Export as GIF?

I'm trying to export a sprite's costume as a PNG (so there's no background) but it keeps exporting as a .bmp.

Can I get it to export as a PNG?


http://i.imgur.com/Qd0lu.png

Offline

 

#2 2011-04-04 20:57:19

Pecola1
Scratcher
Registered: 2010-09-06
Posts: 1000+

Re: Export as GIF?

Not sure, I tried editing the source once, but it wouldn't work. Good luck.


If you are reading this, please read to the end, because if you don't you won't know what's at the end. Don't just skip to the end though otherwise you won't be able to read the middle, which is most important. Now you must be wondering why you just read all that, the reason is you may have not noticed something, read it again and see if you notice it this time  smile

Offline

 

#3 2011-04-04 21:12:22

Pecola1
Scratcher
Registered: 2010-09-06
Posts: 1000+

Re: Export as GIF?

Now tell me, was I helpful? LOL XD


If you are reading this, please read to the end, because if you don't you won't know what's at the end. Don't just skip to the end though otherwise you won't be able to read the middle, which is most important. Now you must be wondering why you just read all that, the reason is you may have not noticed something, read it again and see if you notice it this time  smile

Offline

 

#4 2011-04-04 21:53:54

Harakou
Community Moderator
Registered: 2009-10-11
Posts: 1000+

Re: Export as GIF?

As far as I'm aware, Scratch only supports exporting bitmaps and GIF's.

Last edited by Harakou (2011-04-04 21:54:24)


http://www.blocks.scratchr.org/API.php?action=random&return=image&link1=http://i.imgur.com/OZn2RD3.png&link2=http://i.imgur.com/duzaGTB.png&link3=http://i.imgur.com/CrDGvvZ.png&link4=http://i.imgur.com/POEpQyZ.png&link5=http://i.imgur.com/ZKJF8ac.png

Offline

 

#5 2011-04-04 21:54:53

Pecola1
Scratcher
Registered: 2010-09-06
Posts: 1000+

Re: Export as GIF?

Harakou wrote:

As far as I'm aware, Scratch only supports exporting bitmaps and GIF's.

Unless you hack the code.


If you are reading this, please read to the end, because if you don't you won't know what's at the end. Don't just skip to the end though otherwise you won't be able to read the middle, which is most important. Now you must be wondering why you just read all that, the reason is you may have not noticed something, read it again and see if you notice it this time  smile

Offline

 

#6 2011-04-04 22:08:27

Harakou
Community Moderator
Registered: 2009-10-11
Posts: 1000+

Re: Export as GIF?

Pecola1 wrote:

Harakou wrote:

As far as I'm aware, Scratch only supports exporting bitmaps and GIF's.

Unless you hack the code.

Modding != Hacking
It takes more than simple code to export in a new format; you also need the correct codec and support for its features.


http://www.blocks.scratchr.org/API.php?action=random&return=image&link1=http://i.imgur.com/OZn2RD3.png&link2=http://i.imgur.com/duzaGTB.png&link3=http://i.imgur.com/CrDGvvZ.png&link4=http://i.imgur.com/POEpQyZ.png&link5=http://i.imgur.com/ZKJF8ac.png

Offline

 

#7 2011-04-05 10:59:36

LS97
Scratcher
Registered: 2009-06-14
Posts: 1000+

Re: Export as GIF?

Harakou wrote:

Pecola1 wrote:

Harakou wrote:

As far as I'm aware, Scratch only supports exporting bitmaps and GIF's.

Unless you hack the code.

Modding != Hacking
It takes more than simple code to export in a new format; you also need the correct codec and support for its features.

Squeak supports many different image formats.
I looked at the code once and saw that a boolean determines whether it exports as a GIF or as a Bitmap. Let me go check what it was...

Stay posted for episode 5429681, right after a short commercial.

EDIT
Wow, that's weird. It saves images as GIF only if they contain less than 256 colors. That's pretty much never.

Anyway, if you feel like changing the source to allow this it's under
Scratch-Objects -> ImageMedia -> exportFilename:for:

Last edited by LS97 (2011-04-05 11:05:58)

Offline

 

#8 2011-04-05 11:05:15

Lar-Rew
Scratcher
Registered: 2010-02-19
Posts: 100+

Re: Export as GIF?

You can use GIMP to save it as a PNG, and then use the "Color to Alpha" tool in GIMP to do what you want to do.

Offline

 

#9 2011-04-05 13:29:07

scimonster
Community Moderator
Registered: 2010-06-13
Posts: 1000+

Re: Export as GIF?

Scratch can export PNGs. I hacked so that scripts save that way so I don't have to make a separate file.

Offline

 

Board footer