Why is it that I can post the attached mp4 but not the source as a gif?

To make the mp4 I encoded the gif in handbrake, which actually made increased the file size but reduced the dimensions.

Source gif:  728*408, 785.5 KiB
Encoded mp4: 640*360, 836.7 KiB
    • jqubed@lemmy.world
      link
      fedilink
      arrow-up
      4
      ·
      7 days ago

      I feel like something’s gone very wrong if the MP4 is dimensionally smaller but has a larger file size than the GIF

      • tal@lemmy.today
        link
        fedilink
        English
        arrow-up
        2
        ·
        6 days ago

        The original video was not dithered.

        GIF is a format that was originally designed to do static images with flat colors. (Or, I think dithered…I know that PNG definitely can encode ordered dithers efficiently, and this is an ordered dither, rather than something like a Floyd-Steinberg dither).

        GIF cannot do more than 256 colors in a frame, so whoever created the GIF will have, as part of the compression, caused the number of colors to be reduced, with dithering used to try to compensate for the lack of colors. That’s why it looks “grainy”.

        Most video compression codecs are not optimized for compressing dithered images, because video normally doesn’t look like that.

        If you took the original, pre-GIF-compression video, which wasn’t dithered down, and compressed it with something like MP4, you’d probably get rather better quality per byte size than you do with GIF. But once the video has been passed through GIF’s compression…shrugs