VideoHelp Forum

Try DVDFab and download streaming video, copy, convert or make Blu-rays,DVDs! Download free trial !
+ Reply to Thread
Results 1 to 11 of 11
Thread
  1. Is it feasible to convert a short mp4 file to a GIF without negatively impacting the resolution, framerate or resulting in a considerably larger filesize?

    I am not hung up on it being a GIF necessarily if there is a better format for accomplishing a similar end result.
    Quote Quote  
  2. Originally Posted by Bluelude1 View Post
    Is it feasible to convert a short mp4 file to a GIF without negatively impacting the resolution, framerate or resulting in a considerably larger filesize?
    No.

    Originally Posted by Bluelude1 View Post
    I am not hung up on it being a GIF necessarily if there is a better format for accomplishing a similar end result.
    APNG is the modern version of GIF. But support isn't as widespread. And it has many of the drawbacks of GIF.

    https://en.wikipedia.org/wiki/APNG
    Quote Quote  
  3. Another option is Animated WEBP

    Pros:
    -lossless, lossy and alpha channel options
    -supported by many modern browsers (firefox, chrome, edge, opera, safari added recently)
    -8bit per channel color like PNG

    Cons:
    *like apng,gif - no temporal compression comparable to video - thus large filesizes compared to typical video
    -higher playback overhead (cpu usage) compared to gif or apng

    Typical usage scenario might be a lossy scenario, where filesize can be reduced compared to lossless, but retaining more colors and quality than GIF (256 colors) .

    Winner: typical mp4, or webm video with temporal compression the real winner. Forget about animated "image" formats.

    But if you "needed" an animated "image" format - lossless animated webp in rgb configuration is usually smaller than apng (both larger than gif); and in lossy configuration ~Q96-Q99 , it looks substantially better than "high quality" gifs at much smaller filesizes. But eitherway, expect a considerable increase in filesize over the input video
    Quote Quote  
  4. Dinosaur Supervisor KarMa's Avatar
    Join Date
    Jul 2015
    Location
    US
    Search Comp PM
    These days websites are switching to just using H.264 video in a .MP4 container (or VP8 in .WEBM) as a GIF alternative, and just embed it in the HTML.

    Example of videos used in place of GIF.

    https://www.nytimes.com/2020/08/07/world/middleeast/lebanon-explosion-ship.html
    if you are paywalled
    https://vp.nyt.com/video/2020/08/06/87868_1_beirut-ship-b_wg_720p.mp4

    Anyway, the filesize is going to grow by 10x or more if you want a 1:1 copy of a video converted to GIF. There are ways to reduce the size of GIF if the GIF is mostly stagnant, allowing frames to just copy information from previous frames. APNG on the other hand does not have this ability (that I know of), instead each frame is Intra and so can't use previous frames to reduce the size. Instead it just uses better Intra compression over GIF's. You aren't going to save much space if any with APNG unless it's an animation.

    GIF and PNG (APNG) were never designed around being video like, and so are not good at being video like. GIF was just picked for short clips because everyone already supported GIF the image format which comes with animation ability and so there was no bar to entry.
    Last edited by KarMa; 13th Aug 2020 at 23:25.
    Quote Quote  
  5. This is common misconception that GIF can be only 256 colors (GIF can be even 24 bit truecolor) however as for any lossless format, large file sizes should be expected.

    There is a lot of formats tailored to replace GIF and some of them can be transparent for modern browser (like https://blog.imgur.com//2014/10/09/introducing-gifv/).
    Sometimes changing extension of the file itself, from some common video extension like "MP4" to "GIF" may work just fine...
    Quote Quote  
  6. Member
    Join Date
    Aug 2013
    Location
    Central Germany
    Search PM
    24 bit GIF? Please link me that specification I've never heard of...
    Quote Quote  
  7. Originally Posted by LigH.de View Post
    24 bit GIF? Please link me that specification I've never heard of...
    This is not about different specification, this is way how to use already existing specification - http://aminet.net/package/docs/misc/GIF24 - as rarely picture and video will use al colors from 24 bit RGB color space then it may be alternative to other 24 bit formats (picture can be smaller than 24 bit bitmap).

    Picture from https://en.wikipedia.org/wiki/GIF#True_color

    Click image for larger version

Name:	FullColourGIF.gif
Views:	14
Size:	156.2 KB
ID:	54529
    Last edited by pandy; 14th Aug 2020 at 08:10.
    Quote Quote  
  8. That tiled gif is a neat workaround. But animated webp is modern, works in modern browsers. The main issues are legacy browser support, and higher decoding requirements

    original tiled gif from wikipedia
    53.0 KB (54,310 bytes)
    Image
    [Attachment 54539 - Click to enlarge]


    lossless animated webp version
    22.7 KB (23,332 bytes)
    Image
    [Attachment 54540 - Click to enlarge]
    Last edited by poisondeathray; 14th Aug 2020 at 10:43.
    Quote Quote  
  9. Some test observations for a AVC/MP4 source
    (I won't embed them or upload as image to be kind , but attach in a zip)


    source MP4 390KB
    gif, ffmpeg default paletteuse 7.14MB
    gif, gifski 7.46MB
    apng 9.10MB
    webp anim lossless RGB 6.88MB
    webp anim YUV Q98 1.94MB

    The "winner" is always video; even if you re-encoded source mp4 , it would still have smaller filesize.

    Animated webp in YUV lossy configuration ~Q96-99 will produce higher quality than gif, yet smaller filesizes ; and for RGB lossless it will usually produce smaller filesizes than APNG
    Image Attached Files
    Quote Quote  
  10. Member Cornucopia's Avatar
    Join Date
    Oct 2001
    Location
    Deep in the Heart of Texas
    Search PM
    @pandy, your semantic nitpicking and theoretical exceptions through multi-tile trickery notwithstanding, the GIF 87 and GIF 89a spec define the max # of colors in the colortable of each image as 256.

    It's a very good idea to use optimized palettes to improve the color impression of this limited format, but that in itself is advanced enough for most users. Sleights of hand with tiling might provide the equivalent of truecolor, but isn't guaranteed to work properly in all browser presentations, much less other vehicles.
    Probably best not to get peoples' hopes up with snake oil - much better to suggest newer & better formats.


    Scott
    Quote Quote  
  11. Originally Posted by Cornucopia View Post
    @pandy, your semantic nitpicking and theoretical exceptions through multi-tile trickery notwithstanding, the GIF 87 and GIF 89a spec define the max # of colors in the colortable of each image as 256.
    This is not a problem with specification or my "semantic nitpicking" but problem with way of how people think and limit themselves - name it whatever is your wish not my problem.
    Quote Quote  



Similar Threads