liboggz: oggz_deprecated.h File Reference

# oggz_deprecated.h File Reference

Deprecated interfaces. More...

Go to the source code of this file.

## Defines
#define | OGGZ_ERR_USER_STOPPED OGGZ_ERR_STOP_OK
| DEPRECATED CONSTANT.
#define | OGGZ_ERR_READ_STOP_OK OGGZ_ERR_STOP_OK
| DEPRECATED CONSTANT.
#define | OGGZ_ERR_READ_STOP_ERR OGGZ_ERR_STOP_ERR
| DEPRECATED CONSTANT.
## Functions
int | oggz_set_metric_linear (OGGZ *oggz, long serialno, ogg_int64_t granule_rate_numerator, ogg_int64_t granule_rate_denominator)
| DEPRECATED FUNCTION This function has been replaced with the more clearly named oggz_set_granulerate().
ogg_packet * | oggz_comment_generate (OGGZ *oggz, long serialno, OggzStreamContent packet_type, int FLAC_final_metadata_block)
| DEPRECATED FUNCTION This function has been replaced with oggz_comments_generate(), which does not require the packet_type argument.

## Detailed Description

Deprecated interfaces.

## Define Documentation

#define OGGZ_ERR_READ_STOP_ERR OGGZ_ERR_STOP_ERR

DEPRECATED CONSTANT.

OGGZ_ERR_READ_STOP_OK, OGGZ_ERR_READ_STOP_ERR were introduced to allow the user to differentiate between a cancelled oggz_read_*() returning due to error or an ok condition. From 0.9.4 similar functionality was added for oggz_write_*(), hence this constant was renamed.

#define OGGZ_ERR_READ_STOP_OK OGGZ_ERR_STOP_OK

DEPRECATED CONSTANT.

OGGZ_ERR_READ_STOP_OK, OGGZ_ERR_READ_STOP_ERR were introduced to allow the user to differentiate between a cancelled oggz_read_*() returning due to error or an ok condition. From 0.9.4 similar functionality was added for oggz_write_*(), hence this constant was renamed.

#define OGGZ_ERR_USER_STOPPED OGGZ_ERR_STOP_OK

DEPRECATED CONSTANT.

OGGZ_ERR_USER_STOPPED was introduced during development (post 0.8.3), and is similar in functionality to and numerically equal to (ie. ABI compatible with) OGGZ_ERR_STOP_OK in <oggz/oggz_constants.h>. It was badly named, as the preferred functionality distinguishes between a user's OggzReadCallback returning OGGZ_STOP_OK or OGGZ_STOP_ERR; your code should distinguish between these two too :-) Hence, don't use this (unreleased) name in new code.

## Function Documentation

ogg_packet* oggz_comment_generate | ( | OGGZ * | oggz,
|  | long | serialno,
|  | OggzStreamContent | packet_type,
|  | int | FLAC_final_metadata_block |
| ) |  |  |

DEPRECATED FUNCTION This function has been replaced with oggz_comments_generate(), which does not require the packet_type argument.

Instead, the packet type is determined by the content type of the stream, which was discovered when the bos packet was passed to oggz_write_feed.

Output a comment packet for the specified stream.

Parameters:

  | oggz | A OGGZ* handle (created with OGGZ_WRITE)
  | serialno | Identify a logical bitstream within oggz
  | packet_type | Type of comment packet to generate, FLAC, OggPCM, Speex, Theora and Vorbis are supported
  | FLAC_final_metadata_block | Set this to zero unless the packet_type is FLAC, and there are no further metadata blocks to follow. See note below for details.

Returns:
  A comment packet for the stream. When no longer needed it should be freed with oggz_packet_destroy().

Return values:

  | NULL | content type does not support comments, not enough memory or comment was too long for FLAC

Note:
  FLAC streams may contain multiple metadata blocks of different types. When encapsulated in Ogg the first of these must be a Vorbis comment packet but PADDING, APPLICATION, SEEKTABLE, CUESHEET and PICTURE may follow. The last metadata block must have its first bit set to 1. Since liboggz does not know whether you will supply more metadata blocks you must tell it if this is the last (or only) metadata block by setting FLAC_final_metadata_block to 1.
  As FLAC metadata blocks are limited in size to 16MB minus 1 byte, this function will refuse to produce longer comment packets for FLAC.
  See http://flac.sourceforge.net/format.html for more details.

int oggz_set_metric_linear | ( | OGGZ * | oggz,
|  | long | serialno,
|  | ogg_int64_t | granule_rate_numerator,
|  | ogg_int64_t | granule_rate_denominator |
| ) |  |  |

DEPRECATED FUNCTION This function has been replaced with the more clearly named oggz_set_granulerate().

Specify that a logical bitstream has a linear metric

Parameters:

  | oggz | An OGGZ handle
  | serialno | Identify the logical bitstream in oggz to attach this linear metric to. A value of -1 indicates that the metric should be attached to all unattached logical bitstreams in oggz.
  | granule_rate_numerator | The numerator of the granule rate
  | granule_rate_denominator | The denominator of the granule rate

Returns:
  0 Success

Return values:

  | OGGZ_ERR_BAD_SERIALNO | serialno does not identify an existing logical bitstream in oggz.
  | OGGZ_ERR_BAD_OGGZ | oggz does not refer to an existing OGGZ