http://www.zorba-xquery.com/modules/image/animation

Description

Before using any of the functions below please remember to import the module namespace:

import module namespace anim = "http://www.zorba-xquery.com/modules/image/animation";

This module provides functions to create animated GIF images.

Author

Daniel Thomas

XQuery version and encoding

xquery version "3.0" encoding "utf-8";

Namespaces

animhttp://www.zorba-xquery.com/modules/image/animation
ierrhttp://www.zorba-xquery.com/modules/image/error
verhttp://www.zorba-xquery.com/options/versioning

Function Summary

 create-animated-gif($images as xs:base64Binary+, $delay as xs:unsignedInt, $iterations as xs:unsignedInt) as xs:base64Binary external

Creates an animated GIF image.

 create-morphed-gif($images as xs:base64Binary+, $delay as xs:unsignedInt, $iterations as xs:unsignedInt, $nr-of-morph-images as xs:unsignedInt) as xs:base64Binary external

Creates an animated GIF image with morph effect.

Functions

create-animated-gif#3

declare function anim:create-animated-gif(
    $images as xs:base64Binary+,
    $delay as xs:unsignedInt,
    $iterations as xs:unsignedInt
) as xs:base64Binary external

Creates an animated GIF image. The resulting animated GIF shows the passed images consecutively. It has the same width and height as the first passed image.

Parameters

  • $images as xs:base64Binary
    the image sequence
  • $delay as xs:unsignedInt
    the hundredths of seconds an image is shown
  • $iterations as xs:unsignedInt
    the amount of times all images are shown. 0 for infinite.

Returns

  • xs:base64Binary

    the animated GIF

Errors

  • ierr:IM001 one of the passed images is invalid.

Examples

create-morphed-gif#4

declare function anim:create-morphed-gif(
    $images as xs:base64Binary+,
    $delay as xs:unsignedInt,
    $iterations as xs:unsignedInt,
    $nr-of-morph-images as xs:unsignedInt
) as xs:base64Binary external

Creates an animated GIF image with morph effect. The resulting animated GIF shows the passed images consecutively with morph effect between the changes. It has the same width and height as the first passed image.

Parameters

  • $images as xs:base64Binary
    the image sequence
  • $delay as xs:unsignedInt
    the hundredths of seconds an image is shown
  • $iterations as xs:unsignedInt
    the amount of times all images are shown. 0 for infinite.
  • $nr-of-morph-images as xs:unsignedInt
    the number of additionally added images to create the morph effect between two passed images.

Returns

  • xs:base64Binary

    the animated GIF

Errors

  • ierr:IM001 one of the passed images is invalid.

Examples

blog comments powered by Disqus