I want to make a Custom Notification with big animated gif image. So I cannot find a solution resolve this problem. Because i can only use RemoteView to custome layout. Creating custom android notification without RemoteView
But RemoteView just support some basic view.
https://developer.android.com/guide/topics/appwidgets/index.html#CreatingLayout
How can i do this?
Provide the bitmap to be used as the payload for the BigPicture notification. Provide the content Uri to be used as the payload for the BigPicture notification. Overrides ContentTitle in the big form of the template. Set the content description of the big picture.
AFAIK videos and GIFs are not supported in the notification.
First you'll need to install GIFDroid from the Android Market, then open the app. Step 1: Press either the Select Video or Record Video button. Select Video will open your Gallery to choose a video. Step 2: Choose the section of the video you want to make into an animated GIF.
there is no good solution for this but you can use this trick :
you can set imageView to remoteView of your notification and than change the image of your imageView per gif frame and update your remoteView imageView image and your notification and you should do this on separate Thread because it is costly!
for splinting your gif to separate images you can try this sulutions :
splitting out side of your project :
https://ezgif.com/split
splitting inside your project and in runtime :
Split GIF into frames
please notify me if this solution worked for you
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With