Sub ResizeGIF
Dim EncGIF As AnimatedGifEncoder
Dim DecGIF As GifDecoder
Dim dir As String =rp.GetSafeDirDefaultExternal("") '<< replace with dir=File.DirDefaultExternal if you don't wanna use runtime permissions
DecGIF.Load(File.DirAssets,"test.gif")'<< original gif path
Dim out As OutputStream
out = File.OpenOutput(dir, "resized.gif", False) '<< resized gif path
EncGIF.Initialize("gif")
EncGIF.Quality=10
EncGIF.start(out)
Dim b As Bitmap
For i = 0 To DecGIF.FrameCount-1
b=DecGIF.Frame(i)
b=b.Resize(150,150,True)
EncGIF.addFrame(b)
EncGIF.Delay=DecGIF.Delay(i)
Next
EncGIF.Repeat=DecGIF.LoopCount
EncGIF.finish
out.Close
ToastMessageShow("GIF RESIZED",True)
End Sub