z_media_gif (zotonic_core v1.0.0-rc.17)

Check if a GIF image is animated.

Summary

Functions

Return the number of frames in a GIF. Returns 0 for GIFs with an error.

Return the number of frames in a GIF. 0 if the GIF has errros.

Check if a GIF binary is animated.

Check if a GIF file is animated.

Functions

frame_count(Data)

-spec frame_count(Data) -> non_neg_integer() when Data :: binary().

Return the number of frames in a GIF. Returns 0 for GIFs with an error.

frame_count_file(Filename)

-spec frame_count_file(Filename) -> non_neg_integer() when Filename :: file:filename_all().

Return the number of frames in a GIF. 0 if the GIF has errros.

is_animated(Data)

-spec is_animated(Data) -> boolean() when Data :: binary().

Check if a GIF binary is animated.

is_animated_file(Filename)

-spec is_animated_file(Filename) -> boolean() when Filename :: file:filename_all().

Check if a GIF file is animated.