Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Play animated Stickers (gif) #2668

Closed
HarHarLinks opened this issue Jan 14, 2021 · 15 comments · Fixed by #5572
Closed

Play animated Stickers (gif) #2668

HarHarLinks opened this issue Jan 14, 2021 · 15 comments · Fixed by #5572
Labels
T-Enhancement New features, changes in functionality, performance boosts, user-facing improvements

Comments

@HarHarLinks
Copy link
Contributor

Problem
Stickers may be animated files, e.g. gif files, apng files, etc.
Animated images like these can usually (only) be played, by tapping to "open" them, presumably in a webview.
In case of a sticker with MIME type image/gif, the app recognizes the animated nature of the file and shows a play button overlaid on the sticker. However this isn't clickable, nor does the animation play.

Proposed Solution
Animated stickers should be supported. The support should at least match the regular file sending of the same file type. Inline playback would be preferable, perhaps similar to Element Web/Desktop, which can play on mouse hover, which could translate to tap to play the longer of one loop, loop for a minimum amount of time, or similar. See also #1160.

@HarHarLinks HarHarLinks added the T-Enhancement New features, changes in functionality, performance boosts, user-facing improvements label Jan 14, 2021
@binarydad
Copy link

I would love this as well. Rocket.Chat has this and it's nice, especially for my kids.

@kojid0
Copy link
Contributor

kojid0 commented Feb 28, 2021

I think this is not supported serverside, so the android dev can't fix it. I guess it's rather an issue for https://github.com/matrix-org/matrix-doc/issues, but I'm not 100% sure.

@HarHarLinks
Copy link
Contributor Author

I think this is not supported serverside

This is currently working on element-web/desktop, so I don't see how it could be a server/protocol issue. I think this would be working on android, if either stickers could be tapped for fullscreen viewing as normal pictures are, or just play gifs inline.

@HarHarLinks
Copy link
Contributor Author

Most gif stickers now autoplay indefinitely in 1.1.11

  • there is no download confirmation for what might be a huge gif
  • cant pause gif stickers
  • no (downloading) animation, just a black space and eventually the sticker appears and starts playing
  • I have at least 1 gif sticker that only plays once and does not loop on android, but does loop on desktop (i use the hover-to-play-gifs setting on desktop)

@DUCKCHI
Copy link
Contributor

DUCKCHI commented Oct 12, 2021

Most gif stickers now autoplay indefinitely in 1.1.11

In 1.3.2, the gif sticker is not played. It does not played regardless of size and capacity.

Given that it is supported on element/web and element/desktop, it seems that gif sticker autoplay is not supported on Android clients.

@HarHarLinks
Copy link
Contributor Author

You are correct, I can confirm that. I am no longer certain if my assessment for 1.1.11 was correct, however I can say that animated stickers work very nicely in the SchildiChat fork of Element Android.

@binarydad
Copy link

Is this a bug? Can this work in the same way as desktop/web?

@DUCKCHI
Copy link
Contributor

DUCKCHI commented Oct 14, 2021

Is this a bug?

No, it's not a bug. Shildichat is another messenger app forked from element-android and seems to support gif autoplay separately. I checked Schildichat, and it only supports gif autoplay, not animation stickers.

@binarydad
Copy link

I checked out Shildichat. It does seem nice, in terms of the GIFs and overall layout compared to Element. That name and icon for Shildichat is just... yeah.

Really wish Element would support at least the option for enabling animated GIFs by default.

@archerallstars
Copy link

archerallstars commented Dec 23, 2021

GIF images/stickers should be automatically played by default as:

  1. It's the default behavior on the desktop app. Changing this won't benefit mobile users in any way, so it should stay the same across all the platforms.
  2. It's the default behavior on other popular messenger apps including, Whatsapp, LINE, Facebook Messenger, and even Discord. Therefore, it should or better be automatically played in loops by default. This would help a lot for people to migrate to Element as this is the expected behavior across most if not all messenger apps.

Edit: considering that there's no sticker shop or anything of the sort in Element, this implementation is severely needed, as it is the only meaningful way to use stickers in Element.

@HarHarLinks
Copy link
Contributor Author

Changing this won't benefit mobile users in any way

downloading gifs can be fairly costly since they're quick to be a couple MB large. 🤷 clearly there should be an option to disable autoplay (and thus autodownload), plus another option to switch behaviour based on cell or wifi connectivity.

@binarydad
Copy link

I send my kids GIFs all the time. It's annoying for them (and me) to have to play each one.

Would LOVE an option for toggling this.

@HarHarLinks
Copy link
Contributor Author

HarHarLinks commented Jan 27, 2022

I send my kids GIFs all the time.

Please note that this issue is about animated Stickers (which you can send e.g. with this) in particular, which is still completely impossible in Element Android (contrary to SchildiChat and others).

It is not about general GIF playback (automatic or otherwise).

@DUCKCHI
Copy link
Contributor

DUCKCHI commented Feb 2, 2022

Animation stickers can be played on element-android. If you modify the source of maunium-stickerpicker a little, you can upload webp, gif, and use animation stickers (checked on element-web).

https://duckchi.github.io/stickerpicker/web/
example

Considering that gif automatic playback is possible in schildichat, animation sticker playback is also possible on element-android by simply reflecting the automatic playback code on the sticker.

@p1gp1g p1gp1g mentioned this issue Mar 18, 2022
15 tasks
@bmarty
Copy link
Member

bmarty commented Mar 21, 2022

Should be fixed in 1.4.6

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
T-Enhancement New features, changes in functionality, performance boosts, user-facing improvements
Projects
None yet
Development

Successfully merging a pull request may close this issue.

6 participants