# \[SOLVED\] GIF Motion Texture Support?

**URL:** <https://forum.playcanvas.com/t/solved-gif-motion-texture-support/1760>\
**Category:** Help & Support\
**Tags:** textures\
**Created:** [April 3, 2016, 10:29pm UTC](https://forum.playcanvas.com/t/solved-gif-motion-texture-support/1760 "2016-04-03T22:29:16Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![AmbushGames](https://forum.playcanvas.com/user_avatar/forum.playcanvas.com/ambushgames/32/4928_2.png) [@AmbushGames](https://forum.playcanvas.com/u/AmbushGames)\
**Post date:** [April 3, 2016, 10:29pm UTC](https://forum.playcanvas.com/t/solved-gif-motion-texture-support/1760/1 "2016-04-03T22:29:16Z")

</div>

Can you use a GIF as a texture and the texture will move like a GIF does? If not, how do I do that?

---

<div class="post-metadata">

**Author:** ![dave](https://forum.playcanvas.com/user_avatar/forum.playcanvas.com/dave/32/4558_2.png) [@dave](https://forum.playcanvas.com/u/dave)\
**Post date:** [April 4, 2016, 8:52am UTC](https://forum.playcanvas.com/t/solved-gif-motion-texture-support/1760/2 "2016-04-04T08:52:57Z")

</div>

Unfortunately no. You can use a gif as a texture, but it won’t animate.

There is a tutorial on how to animate textures here: [http://developer.playcanvas.com/en/tutorials/intermediate/animated-textures/](http://developer.playcanvas.com/en/tutorials/intermediate/animated-textures/)

Basically, you need to make a spritesheet of the animation frames then cycle through the frames using the texture offset.

---

<div class="post-metadata">

**Author:** ![Mystik](https://forum.playcanvas.com/user_avatar/forum.playcanvas.com/mystik/32/5730_2.png) [@Mystik](https://forum.playcanvas.com/u/Mystik)\
**Post date:** [July 19, 2019, 7:10pm UTC](https://forum.playcanvas.com/t/solved-gif-motion-texture-support/1760/3 "2019-07-19T19:10:08Z")

</div>

Is this still true in 2019. Playcanvas don’t support animated GIF?

---

<div class="post-metadata">

**Author:** ![will](https://forum.playcanvas.com/user_avatar/forum.playcanvas.com/will/32/4560_2.png) [@will](https://forum.playcanvas.com/u/will)\
**Post date:** [July 20, 2019, 5:20am UTC](https://forum.playcanvas.com/t/solved-gif-motion-texture-support/1760/4 "2019-07-20T05:20:36Z")

</div>

Correct.

But you could [convert the animated GIF to an MP4](https://ezgif.com/gif-to-mp4) to do a [video texture](https://developer.playcanvas.com/en/tutorials/video-textures/).

Or place the frames side by side in a JPG/PNG and create an [animated sprite](https://developer.playcanvas.com/en/user-manual/2D/sprite-editor/).

---

<div class="post-metadata">

**Author:** ![Mystik](https://forum.playcanvas.com/user_avatar/forum.playcanvas.com/mystik/32/5730_2.png) [@Mystik](https://forum.playcanvas.com/u/Mystik)\
**Post date:** [July 22, 2019, 12:34pm UTC](https://forum.playcanvas.com/t/solved-gif-motion-texture-support/1760/5 "2019-07-22T12:34:48Z")

</div>

Thank you for your solution with MP4 and video texture.

I have found another solution that I have documented here: [How can I create an animated sprite on 2D screen UI in a 3D application?](https://forum.playcanvas.com/t/how-can-i-create-an-animated-sprite-on-2d-screen-ui-in-a-3d-application/10404/2)

---

<div class="post-metadata">

**Author:** ![MarkoZivkovic](https://forum.playcanvas.com/letter_avatar_proxy/v4/letter/m/4bbf92/32.png) [@MarkoZivkovic](https://forum.playcanvas.com/u/MarkoZivkovic)\
**Post date:** [July 23, 2019, 1:18am UTC](https://forum.playcanvas.com/t/solved-gif-motion-texture-support/1760/6 "2019-07-23T01:18:34Z")

</div>

Unfortunately no. You can use a gif as a texture, but it won’t animate.  
Fortunately,you can make a GIF as a texture and make it move by three-plain-animator. Steps are here: [https://docsbay.net/three-plain-animator](https://docsbay.net/three-plain-animator)

---

<div class="post-metadata">

**Author:** ![ignacio\_padilla](https://forum.playcanvas.com/user_avatar/forum.playcanvas.com/ignacio_padilla/32/12190_2.png) [@ignacio\_padilla](https://forum.playcanvas.com/u/ignacio_padilla)\
**Post date:** [January 29, 2021, 6:13pm UTC](https://forum.playcanvas.com/t/solved-gif-motion-texture-support/1760/7 "2021-01-29T18:13:34Z")

</div>

How is this going from the gif to 2021? The truth is that I would like it to be used in Interface, use html for the gif I don’t like ☹

---

<div class="post-metadata">

**Author:** ![Leonidas](https://forum.playcanvas.com/user_avatar/forum.playcanvas.com/leonidas/32/6495_2.png) [@Leonidas](https://forum.playcanvas.com/u/Leonidas)\
**Post date:** [January 29, 2021, 7:04pm UTC](https://forum.playcanvas.com/t/solved-gif-motion-texture-support/1760/8 "2021-01-29T19:04:55Z")

</div>

Hi @ignacio_padilla,

You can use an animated sprite, though they aren’t supported in pc.Element components to be used in a UI screen.

You can still add it as a child to your active camera to be locked on screen.

---

<div class="post-metadata">

**Author:** ![eproasim](https://forum.playcanvas.com/user_avatar/forum.playcanvas.com/eproasim/32/22818_2.png) [@eproasim](https://forum.playcanvas.com/u/eproasim)\
**Post date:** [January 29, 2021, 7:09pm UTC](https://forum.playcanvas.com/t/solved-gif-motion-texture-support/1760/9 "2021-01-29T19:09:32Z")

</div>

You can also sort of animate your sprite in pc.Element components if you have a steady frame rate and Tween through the spriteFrames.

---

<div class="post-metadata">

**Author:** ![Saad\_Haider](https://forum.playcanvas.com/user_avatar/forum.playcanvas.com/saad_haider/32/28525_2.png) [@Saad\_Haider](https://forum.playcanvas.com/u/Saad_Haider)\
**Post date:** [May 25, 2021, 11:28am UTC](https://forum.playcanvas.com/t/solved-gif-motion-texture-support/1760/10 "2021-05-25T11:28:38Z")

</div>

Using ffmpeg.wasm ([https://github.com/ffmpegwasm/ffmpeg.wasm](https://github.com/ffmpegwasm/ffmpeg.wasm)) I convert the Gif in browser to a video and run it using a video texture.

[https://playcanvas.com/project/798640/overview/animated-gif](https://playcanvas.com/project/798640/overview/animated-gif)

---

<div class="post-metadata">

**Author:** ![Marks](https://forum.playcanvas.com/user_avatar/forum.playcanvas.com/marks/32/17790_2.png) [@Marks](https://forum.playcanvas.com/u/Marks)\
**Post date:** [November 29, 2021, 5:53pm UTC](https://forum.playcanvas.com/t/solved-gif-motion-texture-support/1760/11 "2021-11-29T17:53:49Z")

</div>

> [@MarkoZivkovic](#):
>
> Fortunately,you can make a GIF a

Does this work if the video has a transparent background?

---

<div class="post-metadata">

**Author:** ![eproasim](https://forum.playcanvas.com/user_avatar/forum.playcanvas.com/eproasim/32/22818_2.png) [@eproasim](https://forum.playcanvas.com/u/eproasim)\
**Post date:** [November 29, 2021, 6:10pm UTC](https://forum.playcanvas.com/t/solved-gif-motion-texture-support/1760/12 "2021-11-29T18:10:34Z")

</div>

If you export the video with an included alpha channel it should work. I haven’t tried it in playcanvas, but I have used transparent videos in other projects. I use After Effects to make transparent mp4’s :

> **[Exporting Video With An Alpha Channel for Transparency in After Effects](https://www.premiumbeat.com/blog/export-video-alpha-channel-transparency/)**
>
> This tutorial shows you how to speed through some After Effects fundamentals, including transparency information. Here's what you need to know.

This tutorial uses the Quicktime video export, but you can use mp4 as well.

---

<div class="post-metadata">

**Author:** ![Kevin\_Herod](https://forum.playcanvas.com/user_avatar/forum.playcanvas.com/kevin_herod/32/31887_2.png) [@Kevin\_Herod](https://forum.playcanvas.com/u/Kevin_Herod)\
**Post date:** [January 4, 2022, 4:46pm UTC](https://forum.playcanvas.com/t/solved-gif-motion-texture-support/1760/13 "2022-01-04T16:46:34Z")

</div>

can you just add gif support to playcanvas because that would make it much easier and would make it less time consuming and boring to have animated textures

---

<div class="post-metadata">

**Author:** ![Kevin\_Herod](https://forum.playcanvas.com/user_avatar/forum.playcanvas.com/kevin_herod/32/31887_2.png) [@Kevin\_Herod](https://forum.playcanvas.com/u/Kevin_Herod)\
**Post date:** [January 4, 2022, 4:53pm UTC](https://forum.playcanvas.com/t/solved-gif-motion-texture-support/1760/14 "2022-01-04T16:53:21Z")

</div>

or at least apng support

---

<div class="post-metadata">

**Author:** ![yaustar](https://forum.playcanvas.com/user_avatar/forum.playcanvas.com/yaustar/32/2268_2.png) [@yaustar](https://forum.playcanvas.com/u/yaustar)\
**Post date:** [January 4, 2022, 5:09pm UTC](https://forum.playcanvas.com/t/solved-gif-motion-texture-support/1760/15 "2022-01-04T17:09:49Z")

</div>

It’s currently not on our roadmap yet. For the moment, you can use something like this tool to convert GIFs to a sprite sheet: [Online GIF to sprite sheet converter](https://ezgif.com/gif-to-sprite)

What is your use case for GIFs and APNGs?

---

<div class="post-metadata">

**Author:** ![Kevin\_Herod](https://forum.playcanvas.com/user_avatar/forum.playcanvas.com/kevin_herod/32/31887_2.png) [@Kevin\_Herod](https://forum.playcanvas.com/u/Kevin_Herod)\
**Post date:** [January 5, 2022, 3:51pm UTC](https://forum.playcanvas.com/t/solved-gif-motion-texture-support/1760/16 "2022-01-05T15:51:16Z")

</div>

i wanted animated gunskins for my game called last life  
-also can you help me with attachments loadouts and actually changing the gunskin ingame

---

<div class="post-metadata">

**Author:** ![Kevin\_Herod](https://forum.playcanvas.com/user_avatar/forum.playcanvas.com/kevin_herod/32/31887_2.png) [@Kevin\_Herod](https://forum.playcanvas.com/u/Kevin_Herod)\
**Post date:** [January 5, 2022, 3:52pm UTC](https://forum.playcanvas.com/t/solved-gif-motion-texture-support/1760/17 "2022-01-05T15:52:02Z")

</div>

also how do you use a sprite sheet?

---

<div class="post-metadata">

**Author:** ![Leonidas](https://forum.playcanvas.com/user_avatar/forum.playcanvas.com/leonidas/32/6495_2.png) [@Leonidas](https://forum.playcanvas.com/u/Leonidas)\
**Post date:** [January 5, 2022, 3:56pm UTC](https://forum.playcanvas.com/t/solved-gif-motion-texture-support/1760/18 "2022-01-05T15:56:54Z")

</div>

Check this manual page on how the sprite editor works:

[https://developer.playcanvas.com/en/user-manual/2D/sprite-editor/](https://developer.playcanvas.com/en/user-manual/2D/sprite-editor/)

---

<div class="post-metadata">

**Author:** ![Kevin\_Herod](https://forum.playcanvas.com/user_avatar/forum.playcanvas.com/kevin_herod/32/31887_2.png) [@Kevin\_Herod](https://forum.playcanvas.com/u/Kevin_Herod)\
**Post date:** [January 5, 2022, 3:58pm UTC](https://forum.playcanvas.com/t/solved-gif-motion-texture-support/1760/19 "2022-01-05T15:58:06Z")

</div>

this is very confusing do you have an example?

---

<div class="post-metadata">

**Author:** ![Kevin\_Herod](https://forum.playcanvas.com/user_avatar/forum.playcanvas.com/kevin_herod/32/31887_2.png) [@Kevin\_Herod](https://forum.playcanvas.com/u/Kevin_Herod)\
**Post date:** [January 5, 2022, 3:58pm UTC](https://forum.playcanvas.com/t/solved-gif-motion-texture-support/1760/20 "2022-01-05T15:58:48Z")

</div>

here’s the link to my game so you can see if it will work on my game  
[https://launch.playcanvas.com/1303797?debug=true](https://launch.playcanvas.com/1303797?debug=true)

[Next page](https://forum.playcanvas.com/t/solved-gif-motion-texture-support/1760.md?page=2)
