--background--

HISTORY

   51.1 (09.03.2013)
   - Initial release.
   52.2  (11.09.2014)
   - Setting compression added

DESCRIPTION

   The class is used to save video data as  Portable Network Graphics file.
   It cooperates  with png.encoder, which converts video PNG stream
   format.

   The class supports argument string and GUI configuration. GUI generator
   delivers a slider gadget for selecting compression mode. Reggae saver
   generator creates png.muxer object, png.encoder object, connects them
   and sets selected compression for the encoder.

NEW ATTRIBUTES

   MMA_Arguments

NEW METHODS

   OM_NEW
   OM_DISPOSE
   MMM_Pull

MMA_Arguments

MMA_Arguments (V51) [I.G.Q], const char*

DESCRIPTION

   Specifies configuration of the object, namely sets proper format to the
   input port. The template is "COMPRESSION/K/N"
   This attribute can be also read after the object has been configured in
   any of ways. In this case returned string is read-only

NOTES

   When specified for constructor, the string must be valid only until the
   constructor returns, so may be a local variable.

MMM_Pull

Delivers block of Portable Network Graphics (V51)

SYNOPSIS

   LONG DoMethod(obj, MMM_Pull, port, buffer, length);

DESCRIPTION

   PNG multiplexer delivers options to png.encoder. Requests are forwarded
   from output to input without any processing or data copying

INPUTS

   obj - object to pull data from.
   port - only pull on output port (port 1) is allowed
   buffer - destination data buffer. Must be AltiVec aligned.
   length - number of bytes to pull

RESULT

   Number of bytes pulled. In case of error, MMA_ErrorCode is set to a code
   received from the previous object in chain

MMM_Setup

Receives video parameters, generates SunRaster header (V51)

SYNOPSIS

   BOOL DoMethod(obj, MMM_Setup, port);

DESCRIPTION

   When object's input is connected to data source, the method reads video
   stream parameters and prepares SunRaster header.

   The method is a no-op for the output port

INPUTS

   port - number of port being connected

RESULT

   Boolean value of success

NOTES

   Data source must be of known length. As the stream length is stored in
   the SunRaster header, free streaming is not supported with this
   format. This method fails if reported stream length is 0.

OM_DISPOSE

Disposes Portable Network Graphics multiplexer object (V51)

SYNOPSIS

   DisposeObject(obj);

DESCRIPTION

   Disposes object, frees allocated memory

OM_NEW

Creates Reggae PNG multiplexer (V51)

SYNOPSIS

   obj = NewObject(NULL, "png.muxer", ...);

DESCRIPTION

   Creates a Portabe Network Graphics multiplexer object. By default
   the object is set up to generate 32-bit file

INPUTS

   Following attributes may be specified:
   - MMA_Arguments - configures input port format and determines number of
     bits per sample in output. Optional.
   - MMA_ErrorCode - pointer to LONG variable, where error code (or 0 in
     case of success) is stored. Optional

RESULT

   Created object, or NULL. In case of failure MMA_ErrorCode specifies
   reason:
   - MMERR_OUT_OF_MEMORY, no free memory,
   - MMERR_WRONG_ARGUMENTS, malformed MMA_Arguments, or unsupported number
     of bits per sample specified