• Happy Earth Week! TBT is hosting a series of nature-based mini-events through April 28th. Breed flower hybrids by organizing your collectible lineup, enter our nature photography contest, purchase historically dated scenery collectibles, and earn bells around the site! Read more in the Earth Week and photography contest threads.

How would I go about putting a gif into the shape of another image (GIMP)

Mary

lemon girl 🍋
Joined
Oct 23, 2012
Posts
5,645
Bells
1,310
Pink Star Fragment
The Bell Tree Fair 2020 Patch
Pink Summer Shell
Kirby Easter Egg
Mother's Day Carnation
Zipper Sakura
Spring Sakura
Spring Sakura
Spring Sakura
Spring Sakura
Trying to figure out how to create a signature that I can edit myself by using a pixel art gif in the shape of a tree. (Similar to my current one made by A r i a n e. I have the gif and the tree is a .png file. Tried googling it to no avail. (Not sure if this goes in this board). I love my signature but would rather not have to bother her for edits whenever I change my mind :)
 
Last edited:
I'm tired and confused, but try using the fuzzy tool to select the tree. Be sure to crank up the number thing from 15 to enough for it to select the whole thing. Then, switch layers to whatever it is you want, invert the selection (somewhere in the Edit list?) and hit Del (be sure the layer has an alpha channel!). Now you have your thing in the shape of a tree.

Let me know if you have any trouble - I'll check this thread sometime after I wake up. Or just send me the files and I'll try and do whatever you wish to achieve. Have a nice day.

- - - Post Merge - - -

By the way, if you don't want to have a nice day, don't feel pressured to do so. You can have whatever emotions you want and no one can force you to have a nice day.
 
I'm tired and confused, but try using the fuzzy tool to select the tree. Be sure to crank up the number thing from 15 to enough for it to select the whole thing. Then, switch layers to whatever it is you want, invert the selection (somewhere in the Edit list?) and hit Del (be sure the layer has an alpha channel!). Now you have your thing in the shape of a tree.

Let me know if you have any trouble - I'll check this thread sometime after I wake up. Or just send me the files and I'll try and do whatever you wish to achieve. Have a nice day.

- - - Post Merge - - -

By the way, if you don't want to have a nice day, don't feel pressured to do so. You can have whatever emotions you want and no one can force you to have a nice day.
Yep, that did the trick :). Thanks for helping, and also thanks for not forcing me do have a nice day. I wish you whatever quality of sleep you would like to have. I played around a little and figured out how to create outlines for the text and for the picture itself xD I'll have to play some more, though, because it wants to include each layer as a frame in the gif so it looks pretty funny right now :p thank you for taking the time to post that when you were tired. :)
 
I'll have to play some more, though, because it wants to include each layer as a frame in the gif so it looks pretty funny right now

Oh yeah, GIFs can be a bit of a pain in GIMP. I think there are plugins which can help but usually I've just spent time sorting out each frame individually. Due to GIF's limit of 256 colours (or probably 255 plus transparency in this case), you'll probably want to convert your image to be indexed from somewhere in the Colours menu using Positioned dithering before exporting. The other dithering methods tend not to look as good, and no dithering will probably result in patches of solid colour.

GIFs have a lot more capabilities than any current software allows for (some software has had such capabilities but updates changed that). For example, it can be used to store images with more than 256 colours by splitting it up into different anination frames for different colours, giving each frame a different colour palette rather than using a global one. I don't know why you'd want to do this as it would be rather large in terms of file size, but it's possible.

You could, however, embed an animated GIF within an SVG which could also consist of a JPEG or PNG, which would allow you to, say, have part of your image animated while maintaining more colours and possibly lower file size. I say "possibly" because the GIF and JPEG/PNG would have to be encoded in base64 if the SVG were to be embedded on an external site such as TBT, which would result in a file size increase for them. But perhaps it would be worth it. I don't know.

There are also quite a few ways of achieving animation, from each frame replacing the previous to combining frames, as well as good ways of optimising GIFs for size due to the fact that they use LZW compression by doing things such as extending colours horizontally (GIMP can do this).

The delay between frames can only be multiples of 10 milliseconds, so you'd have to settle for something such as 25fps, unless some frames have a longer duration than others in order to achieve a different overall frame rate, although it's worth noting that most browsers and image viewers dislike frames with a duration of 10 of 0 milliseconds, often skipping them or displaying them for 50ms. It's probably not worth the hassle of different frame durstions. 50fps is the maximum for modern browsers, with some older versions of Internet Explorer being more like 10fps.

But it's certainly safe to say that these big, fancy animations are not what GIF was designed for, and you can tell easily by how large in size they tend to get. Fortunately, Chrome has recently started supporting animated PNGs (after Firefox has been doing so for years), which is certainly a step in the right direction, although mobile and Internet Explorer's lack of support will probably hold back the use of APNGs. A lot of sites tend to store animations as MP4s now anyway, or use CSS animation (neither of which you'll be able to do on here).

And although GIF doesn't really support partial transparency, I'm sure there was some sort of trick to get that working to some degree. It may have just been dithering.

One thing that I've managed to completely skip over in all of this is the fact that file size probably doesn't really matter to you. I assume you'll be using Imgur or something like that and how quickly a page loads on TBT for a first-time user doesn't make any difference for yourself. But it's still a good idea to keep images small when possible.

With PNGs, for example you can actually index them to ~256 colours to create a PNG8 image, which will result in an image about a third the size. If sticking to PNG24, removing the alpha channel when it isn't needed often helps, or simply using a JPEG when PNG offers no real benefits other than a lossless image. Oh, and don't get me started on JPEG compression - EXIF data, chroma subsampling and all.

I typed this long ramble on my phone. What a good use of time.

- - - Post Merge - - -

Oh, and I'm glad that it all worked nicely.
 
Oh yeah, GIFs can be a bit of a pain in GIMP. I think there are plugins which can help but usually I've just spent time sorting out each frame individually. Due to GIF's limit of 256 colours (or probably 255 plus transparency in this case), you'll probably want to convert your image to be indexed from somewhere in the Colours menu using Positioned dithering before exporting. The other dithering methods tend not to look as good, and no dithering will probably result in patches of solid colour.

GIFs have a lot more capabilities than any current software allows for (some software has had such capabilities but updates changed that). For example, it can be used to store images with more than 256 colours by splitting it up into different anination frames for different colours, giving each frame a different colour palette rather than using a global one. I don't know why you'd want to do this as it would be rather large in terms of file size, but it's possible.

You could, however, embed an animated GIF within an SVG which could also consist of a JPEG or PNG, which would allow you to, say, have part of your image animated while maintaining more colours and possibly lower file size. I say "possibly" because the GIF and JPEG/PNG would have to be encoded in base64 if the SVG were to be embedded on an external site such as TBT, which would result in a file size increase for them. But perhaps it would be worth it. I don't know.

There are also quite a few ways of achieving animation, from each frame replacing the previous to combining frames, as well as good ways of optimising GIFs for size due to the fact that they use LZW compression by doing things such as extending colours horizontally (GIMP can do this).

The delay between frames can only be multiples of 10 milliseconds, so you'd have to settle for something such as 25fps, unless some frames have a longer duration than others in order to achieve a different overall frame rate, although it's worth noting that most browsers and image viewers dislike frames with a duration of 10 of 0 milliseconds, often skipping them or displaying them for 50ms. It's probably not worth the hassle of different frame durstions. 50fps is the maximum for modern browsers, with some older versions of Internet Explorer being more like 10fps.

But it's certainly safe to say that these big, fancy animations are not what GIF was designed for, and you can tell easily by how large in size they tend to get. Fortunately, Chrome has recently started supporting animated PNGs (after Firefox has been doing so for years), which is certainly a step in the right direction, although mobile and Internet Explorer's lack of support will probably hold back the use of APNGs. A lot of sites tend to store animations as MP4s now anyway, or use CSS animation (neither of which you'll be able to do on here).

And although GIF doesn't really support partial transparency, I'm sure there was some sort of trick to get that working to some degree. It may have just been dithering.

One thing that I've managed to completely skip over in all of this is the fact that file size probably doesn't really matter to you. I assume you'll be using Imgur or something like that and how quickly a page loads on TBT for a first-time user doesn't make any difference for yourself. But it's still a good idea to keep images small when possible.

With PNGs, for example you can actually index them to ~256 colours to create a PNG8 image, which will result in an image about a third the size. If sticking to PNG24, removing the alpha channel when it isn't needed often helps, or simply using a JPEG when PNG offers no real benefits other than a lossless image. Oh, and don't get me started on JPEG compression - EXIF data, chroma subsampling and all.

I typed this long ramble on my phone. What a good use of time.

- - - Post Merge - - -

Oh, and I'm glad that it all worked nicely.
That's good to know :) since this only has two frames, I think if I want to put text over them, I'll have to compress the layers of the text and text outline onto the background layer and do the same with frame 2. As long as it's on those two layers, I should be fine, right? I think my issue is that it's treating all layers as frames, so this should fix that.
 
That's good to know :) since this only has two frames, I think if I want to put text over them, I'll have to compress the layers of the text and text outline onto the background layer and do the same with frame 2. As long as it's on those two layers, I should be fine, right? I think my issue is that it's treating all layers as frames, so this should fix that.

Maybe. Play around with it. But yeah, layers will need merging.
 
Back
Top