diff --git a/doc/libtheora-1.2/annotated.html b/doc/libtheora-1.2/annotated.html index cabd199df29638e9f3302068972975887b6d87c0..375c2e7a68cc1241a91b74c4766f271d155d1ec8 100644 --- a/doc/libtheora-1.2/annotated.html +++ b/doc/libtheora-1.2/annotated.html @@ -1,50 +1,66 @@ - + + + + libtheora: Data Structures - + + + - -
-Here are the data structures with brief descriptions: - - - - - - - - - - - +
Here are the data structures with brief descriptions:
+
th_commentThe comment information
th_huff_codeA Huffman code for a Theora DCT token
th_img_planeA buffer for a single color plane in an uncompressed image
th_infoTheora bitstream information
th_quant_infoA complete set of quantization parameters
th_quant_rangesA set of qi ranges
th_stripe_callbackThe striped decode callback data to pass to TH_DECCTL_SET_STRIPE_CB
theora_commentComment header metadata
theora_infoTheora bitstream info
theora_stateCodec internal state and context
yuv_bufferA YUV buffer for passing uncompressed frames to and from the codec
+ + + + + + + + + + +
 Cth_commentThe comment information
 Cth_huff_codeA Huffman code for a Theora DCT token
 Cth_img_planeA buffer for a single color plane in an uncompressed image
 Cth_infoTheora bitstream information
 Cth_quant_infoA complete set of quantization parameters
 Cth_quant_rangesA set of qi ranges
 Cth_stripe_callbackThe striped decode callback data to pass to TH_DECCTL_SET_STRIPE_CB
 Ctheora_commentComment header metadata
 Ctheora_infoTheora bitstream info
 Ctheora_stateCodec internal state and context
 Cyuv_bufferA YUV buffer for passing uncompressed frames to and from the codec
-
- + + + + diff --git a/doc/libtheora-1.2/bc_s.png b/doc/libtheora-1.2/bc_s.png index e4018628b5b45cb4301037485a29d7d74ac22138..224b29aa9847d5a4b3902efd602b7ddf7d33e6c2 100644 Binary files a/doc/libtheora-1.2/bc_s.png and b/doc/libtheora-1.2/bc_s.png differ diff --git a/doc/libtheora-1.2/bdwn.png b/doc/libtheora-1.2/bdwn.png new file mode 100644 index 0000000000000000000000000000000000000000..940a0b950443a0bb1b216ac03c45b8a16c955452 Binary files /dev/null and b/doc/libtheora-1.2/bdwn.png differ diff --git a/doc/libtheora-1.2/classes.html b/doc/libtheora-1.2/classes.html index d80c842987352c4902d6ba38c12651738e3440b3..d63bb9bfbfaffb23106208fe276406fbe27dcd2b 100644 --- a/doc/libtheora-1.2/classes.html +++ b/doc/libtheora-1.2/classes.html @@ -1,42 +1,60 @@ - + -libtheora: Alphabetical List + + + +libtheora: Data Structure Index - + + + - -
-
T | Y
- -
  T  
-
th_img_plane   th_quant_ranges   theora_info   
  Y  
-
th_comment   th_info   th_stripe_callback   theora_state   yuv_buffer   
th_huff_code   th_quant_info   theora_comment   
T | Y
+
T | Y
+
+
+
T
+
th_comment
th_huff_code
th_img_plane
th_info
th_quant_info
th_quant_ranges
th_stripe_callback
theora_comment
theora_info
theora_state
+
+
Y
+
yuv_buffer
- +
+ + diff --git a/doc/libtheora-1.2/closed.png b/doc/libtheora-1.2/closed.png index b7d4bd9fef2272c74b94762c9e2496177017775e..98cc2c909da37a6df914fbf67780eebd99c597f5 100644 Binary files a/doc/libtheora-1.2/closed.png and b/doc/libtheora-1.2/closed.png differ diff --git a/doc/libtheora-1.2/codec_8h.html b/doc/libtheora-1.2/codec_8h.html index b02ca0a024ac5cb85b6377019be956a1186750f1..539939893e1f15ab66ca805f54278b7e4804c421 100644 --- a/doc/libtheora-1.2/codec_8h.html +++ b/doc/libtheora-1.2/codec_8h.html @@ -1,321 +1,382 @@ - + + + + libtheora: codec.h File Reference - + + + - - +
codec.h File Reference
+

The shared libtheoradec and libtheoraenc C API. -More...

-#include <ogg/ogg.h>
- +More...

+
#include <ogg/ogg.h>
+

Go to the source code of this file.

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + +

+

Data Structures

struct  th_img_plane
 A buffer for a single color plane in an uncompressed image. More...
struct  th_info
 Theora bitstream information. More...
struct  th_comment
 The comment information. More...
struct  th_quant_ranges
 A set of qi ranges. More...
struct  th_quant_info
 A complete set of quantization parameters. More...
struct  th_huff_code
 A Huffman code for a Theora DCT token. More...

-Defines

#define _O_THEORA_CODEC_H_   (1)
#define TH_NHUFFMAN_TABLES   (80)
 The number of Huffman tables used by Theora.
#define TH_NDCT_TOKENS   (32)
 The number of DCT token values in each table.
Return codes

-
#define TH_EFAULT   (-1)
 An invalid pointer was provided.
#define TH_EINVAL   (-10)
 An invalid argument was provided.
#define TH_EBADHEADER   (-20)
 The contents of the header were incomplete, invalid, or unexpected.
#define TH_ENOTFORMAT   (-21)
 The header does not belong to a Theora stream.
#define TH_EVERSION   (-22)
 The bitstream version is too high.
#define TH_EIMPL   (-23)
 The specified function is not implemented.
#define TH_EBADPACKET   (-24)
 There were errors in the video data packet.
#define TH_DUPFRAME   (1)
 The decoded packet represented a dropped frame.

-Typedefs

typedef th_img_plane th_ycbcr_buffer [3]
 A complete image buffer for an uncompressed frame.
typedef struct th_comment th_comment
 The comment information.
typedef unsigned char th_quant_base [64]
 A single base matrix.

-Enumerations

enum  th_colorspace { TH_CS_UNSPECIFIED, -TH_CS_ITU_REC_470M, -TH_CS_ITU_REC_470BG, -TH_CS_NSPACES - }
 

The currently defined color space tags.

- More...
enum  th_pixel_fmt {
-  TH_PF_420, -TH_PF_RSVD, -TH_PF_422, -TH_PF_444, -
-  TH_PF_NFORMATS -
- }
 

The currently defined pixel format tags.

- More...

+

struct  th_img_plane
 A buffer for a single color plane in an uncompressed image. More...
 
struct  th_info
 Theora bitstream information. More...
 
struct  th_comment
 The comment information. More...
 
struct  th_quant_ranges
 A set of qi ranges. More...
 
struct  th_quant_info
 A complete set of quantization parameters. More...
 
struct  th_huff_code
 A Huffman code for a Theora DCT token. More...
 
+ + + +

+Macros

#define OGG_THEORA_CODEC_HEADER   (1)
 
+ - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + +

Functions

Basic shared functions

+

These functions return information about the library itself, or provide high-level information about codec state and packet type.

+

You must link to libtheoradec if you use any of the functions in this section.

const char * th_version_string (void)
 Retrieves a human-readable string to identify the library vendor and version.
ogg_uint32_t th_version_number (void)
 Retrieves the library version number.
ogg_int64_t th_granule_frame (void *_encdec, ogg_int64_t _granpos)
 Converts a granule position to an absolute frame index, starting at 0.
double th_granule_time (void *_encdec, ogg_int64_t _granpos)
 Converts a granule position to an absolute time in seconds.
int th_packet_isheader (ogg_packet *_op)
 Determines whether a Theora packet is a header or not.
int th_packet_iskeyframe (ogg_packet *_op)
 Determines whether a theora packet is a key frame or not.
const char * th_version_string (void)
 Retrieves a human-readable string to identify the library vendor and version. More...
 
ogg_uint32_t th_version_number (void)
 Retrieves the library version number. More...
 
ogg_int64_t th_granule_frame (void *_encdec, ogg_int64_t _granpos)
 Converts a granule position to an absolute frame index, starting at 0. More...
 
double th_granule_time (void *_encdec, ogg_int64_t _granpos)
 Converts a granule position to an absolute time in seconds. More...
 
int th_packet_isheader (ogg_packet *_op)
 Determines whether a Theora packet is a header or not. More...
 
int th_packet_iskeyframe (ogg_packet *_op)
 Determines whether a theora packet is a key frame or not. More...
 
Functions for manipulating header data

+

These functions manipulate the th_info and th_comment structures which describe video parameters and key-value metadata, respectively.

+

You must link to libtheoradec if you use any of the functions in this section.

void th_info_init (th_info *_info)
 Initializes a th_info structure.
void th_info_clear (th_info *_info)
 Clears a th_info structure.
void th_comment_init (th_comment *_tc)
 Initialize a th_comment structure.
void th_comment_add (th_comment *_tc, char *_comment)
 Add a comment to an initialized th_comment structure.
void th_comment_add_tag (th_comment *_tc, char *_tag, char *_val)
 Add a comment to an initialized th_comment structure.
char * th_comment_query (th_comment *_tc, char *_tag, int _count)
 Look up a comment value by its tag.
int th_comment_query_count (th_comment *_tc, char *_tag)
 Look up the number of instances of a tag.
void th_comment_clear (th_comment *_tc)
 Clears a th_comment structure.
void th_info_init (th_info *_info)
 Initializes a th_info structure. More...
 
void th_info_clear (th_info *_info)
 Clears a th_info structure. More...
 
void th_comment_init (th_comment *_tc)
 Initialize a th_comment structure. More...
 
void th_comment_add (th_comment *_tc, const char *_comment)
 Add a comment to an initialized th_comment structure. More...
 
void th_comment_add_tag (th_comment *_tc, const char *_tag, const char *_val)
 Add a comment to an initialized th_comment structure. More...
 
char * th_comment_query (th_comment *_tc, const char *_tag, int _count)
 Look up a comment value by its tag. More...
 
int th_comment_query_count (th_comment *_tc, const char *_tag)
 Look up the number of instances of a tag. More...
 
void th_comment_clear (th_comment *_tc)
 Clears a th_comment structure. More...
 
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +

Return codes

#define TH_EFAULT   (-1)
 An invalid pointer was provided. More...
 
#define TH_EINVAL   (-10)
 An invalid argument was provided. More...
 
#define TH_EBADHEADER   (-20)
 The contents of the header were incomplete, invalid, or unexpected. More...
 
#define TH_ENOTFORMAT   (-21)
 The header does not belong to a Theora stream. More...
 
#define TH_EVERSION   (-22)
 The bitstream version is too high. More...
 
#define TH_EIMPL   (-23)
 The specified function is not implemented. More...
 
#define TH_EBADPACKET   (-24)
 There were errors in the video data packet. More...
 
#define TH_DUPFRAME   (1)
 The decoded packet represented a dropped frame. More...
 
#define TH_NHUFFMAN_TABLES   (80)
 The number of Huffman tables used by Theora. More...
 
#define TH_NDCT_TOKENS   (32)
 The number of DCT token values in each table. More...
 
enum  th_colorspace { TH_CS_UNSPECIFIED +, TH_CS_ITU_REC_470M +, TH_CS_ITU_REC_470BG +, TH_CS_NSPACES + }
 The currently defined color space tags. More...
 
enum  th_pixel_fmt {
+  TH_PF_420 +, TH_PF_RSVD +, TH_PF_422 +, TH_PF_444 +,
+  TH_PF_NFORMATS +
+ }
 The currently defined pixel format tags. More...
 
typedef th_img_plane th_ycbcr_buffer[3]
 A complete image buffer for an uncompressed frame. More...
 
typedef struct th_comment th_comment
 The comment information. More...
 
typedef unsigned char th_quant_base[64]
 A single base matrix. More...
 
-

Detailed Description

-

The shared libtheoradec and libtheoraenc C API.

-

You don't need to include this directly.

-

Define Documentation

- +

Detailed Description

+

The shared libtheoradec and libtheoraenc C API.

+

You don't need to include this directly.

+

Macro Definition Documentation

+ +

◆ OGG_THEORA_CODEC_HEADER

+
- +
#define _O_THEORA_CODEC_H_   (1)#define OGG_THEORA_CODEC_HEADER   (1)
-
-
+
- + +

◆ TH_DUPFRAME

+
- +
#define TH_DUPFRAME   (1)#define TH_DUPFRAME   (1)
-
-
+

The decoded packet represented a dropped frame.

-

The player can continue to display the current frame, as the contents of the decoded frame buffer have not changed.

+

The player can continue to display the current frame, as the contents of the decoded frame buffer have not changed.

- + +

◆ TH_EBADHEADER

+
- +
#define TH_EBADHEADER   (-20)#define TH_EBADHEADER   (-20)
-
-
+

The contents of the header were incomplete, invalid, or unexpected.

- + +

◆ TH_EBADPACKET

+
- +
#define TH_EBADPACKET   (-24)#define TH_EBADPACKET   (-24)
-
-
+

There were errors in the video data packet.

- + +

◆ TH_EFAULT

+
- +
#define TH_EFAULT   (-1)#define TH_EFAULT   (-1)
-
-
+

An invalid pointer was provided.

- + +

◆ TH_EIMPL

+
- +
#define TH_EIMPL   (-23)#define TH_EIMPL   (-23)
-
-
+

The specified function is not implemented.

- + +

◆ TH_EINVAL

+
- +
#define TH_EINVAL   (-10)#define TH_EINVAL   (-10)
-
-
+

An invalid argument was provided.

- + +

◆ TH_ENOTFORMAT

+
- +
#define TH_ENOTFORMAT   (-21)#define TH_ENOTFORMAT   (-21)
-
-
+

The header does not belong to a Theora stream.

- + +

◆ TH_EVERSION

+
- +
#define TH_EVERSION   (-22)#define TH_EVERSION   (-22)
-
-
+

The bitstream version is too high.

- + +

◆ TH_NDCT_TOKENS

+
- +
#define TH_NDCT_TOKENS   (32)#define TH_NDCT_TOKENS   (32)
-
-
+

The number of DCT token values in each table.

- + +

◆ TH_NHUFFMAN_TABLES

+
- +
#define TH_NHUFFMAN_TABLES   (80)#define TH_NHUFFMAN_TABLES   (80)
-
-
+

The number of Huffman tables used by Theora.

-

Typedef Documentation

- +

Typedef Documentation

+ +

◆ th_comment

+
@@ -323,50 +384,52 @@ Functions
typedef struct th_comment th_comment
-
-
+

The comment information.

-

This structure holds the in-stream metadata corresponding to the 'comment' header packet. The comment header is meant to be used much like someone jotting a quick note on the label of a video. It should be a short, to the point text note that can be more than a couple words, but not more than a short paragraph.

-

The metadata is stored as a series of (tag, value) pairs, in length-encoded string vectors. The first occurrence of the '=' character delimits the tag and value. A particular tag may occur more than once, and order is significant. The character set encoding for the strings is always UTF-8, but the tag names are limited to ASCII, and treated as case-insensitive. See the Theora specification, Section 6.3.3 for details.

-

In filling in this structure, th_decode_headerin() will null-terminate the user_comment strings for safety. However, the bitstream format itself treats them as 8-bit clean vectors, possibly containing null characters, and so the length array should be treated as their authoritative length.

+

This structure holds the in-stream metadata corresponding to the 'comment' header packet. The comment header is meant to be used much like someone jotting a quick note on the label of a video. It should be a short, to the point text note that can be more than a couple words, but not more than a short paragraph.

+

The metadata is stored as a series of (tag, value) pairs, in length-encoded string vectors. The first occurrence of the '=' character delimits the tag and value. A particular tag may occur more than once, and order is significant. The character set encoding for the strings is always UTF-8, but the tag names are limited to ASCII, and treated as case-insensitive. See the Theora specification, Section 6.3.3 for details.

+

In filling in this structure, th_decode_headerin() will null-terminate the user_comment strings for safety. However, the bitstream format itself treats them as 8-bit clean vectors, possibly containing null characters, so the length array should be treated as their authoritative length.

- + +

◆ th_quant_base

+
- +
typedef unsigned char th_quant_base[64]typedef unsigned char th_quant_base[64]
-
-
+

A single base matrix.

- + +

◆ th_ycbcr_buffer

+
- +
typedef th_img_plane th_ycbcr_buffer[3]typedef th_img_plane th_ycbcr_buffer[3]
-
-
+

A complete image buffer for an uncompressed frame.

-

The chroma planes may be decimated by a factor of two in either direction, as indicated by th_info::pixel_fmt. The width and height of the Y' plane must be multiples of 16. They may need to be cropped for display, using the rectangle specified by th_info::pic_x, th_info::pic_y, th_info::pic_width, and th_info::pic_height. All samples are 8 bits.

-
Note:
The term YUV often used to describe a colorspace is ambiguous. The exact parameters of the RGB to YUV conversion process aside, in many contexts the U and V channels actually have opposite meanings. To avoid this confusion, we are explicit: the name of the color channels are Y'CbCr, and they appear in that order, always. The prime symbol denotes that the Y channel is non-linear. Cb and Cr stand for "Chroma blue" and "Chroma red", respectively.
+

The chroma planes may be decimated by a factor of two in either direction, as indicated by th_info::pixel_fmt. The width and height of the Y' plane must be multiples of 16. They may need to be cropped for display, using the rectangle specified by th_info::pic_x, th_info::pic_y, th_info::pic_width, and th_info::pic_height. All samples are 8 bits.

Note
The term YUV often used to describe a colorspace is ambiguous. The exact parameters of the RGB to YUV conversion process aside, in many contexts the U and V channels actually have opposite meanings. To avoid this confusion, we are explicit: the name of the color channels are Y'CbCr, and they appear in that order, always. The prime symbol denotes that the Y channel is non-linear. Cb and Cr stand for "Chroma blue" and "Chroma red", respectively.
-

Enumeration Type Documentation

- +

Enumeration Type Documentation

+ +

◆ th_colorspace

+
@@ -374,32 +437,27 @@ Functions
enum th_colorspace
-
-
+

The currently defined color space tags.

-

See the Theora specification, Chapter 4, for exact details on the meaning of each of these color spaces.

-
Enumerator:
-
The documentation for this struct was generated from the following file: - - + + + diff --git a/doc/libtheora-1.2/structth__info.html b/doc/libtheora-1.2/structth__info.html index f349f2db20e8a5024fd446e9eab8e37c98cd4e56..52f005ff73e40e50065f1ba23e2f3988297bf515 100644 --- a/doc/libtheora-1.2/structth__info.html +++ b/doc/libtheora-1.2/structth__info.html @@ -1,365 +1,416 @@ - + + + +libtheora: th_info Struct Reference - + + + - -
TH_CS_UNSPECIFIED  -

The color space was not specified at the encoder.

-

It may be conveyed by an external means.

+

See the Theora specification, Chapter 4, for exact details on the meaning of each of these color spaces.

+ + - - -
Enumerator
TH_CS_UNSPECIFIED 

The color space was not specified at the encoder.

+

It may be conveyed by an external means.

TH_CS_ITU_REC_470M  -

A color space designed for NTSC content.

+
TH_CS_ITU_REC_470M 

A color space designed for NTSC content.

TH_CS_ITU_REC_470BG  -

A color space designed for PAL/SECAM content.

+
TH_CS_ITU_REC_470BG 

A color space designed for PAL/SECAM content.

TH_CS_NSPACES  -

The total number of currently defined color spaces.

+
TH_CS_NSPACES 

The total number of currently defined color spaces.

- - - + +

◆ th_pixel_fmt

+
@@ -407,39 +465,507 @@ Functions
enum th_pixel_fmt
-
-
+

The currently defined pixel format tags.

-

See the Theora specification, Section 4.4, for details on the precise sample locations.

-
Enumerator:
-
The documentation for this struct was generated from the following file: - - + + + diff --git a/doc/libtheora-1.2/structth__img__plane.html b/doc/libtheora-1.2/structth__img__plane.html index 94456769c4ada46d894b600dc22eb846977bbdb3..0cc94809f0f04b1c475651f6966e26e09a6d61b9 100644 --- a/doc/libtheora-1.2/structth__img__plane.html +++ b/doc/libtheora-1.2/structth__img__plane.html @@ -1,112 +1,133 @@ - + + + +libtheora: th_img_plane Struct Reference - + + + - -
TH_PF_420  -

Chroma decimation by 2 in both the X and Y directions (4:2:0).

-

The Cb and Cr chroma planes are half the width and half the height of the luma plane.

+

See the Theora specification, Section 4.4, for details on the precise sample locations.

+ + - - - -
Enumerator
TH_PF_420 

Chroma decimation by 2 in both the X and Y directions (4:2:0).

+

The Cb and Cr chroma planes are half the width and half the height of the luma plane.

TH_PF_RSVD  -

Currently reserved.

+
TH_PF_RSVD 

Currently reserved.

TH_PF_422  -

Chroma decimation by 2 in the X direction (4:2:2).

-

The Cb and Cr chroma planes are half the width of the luma plane, but full height.

+
TH_PF_422 

Chroma decimation by 2 in the X direction (4:2:2).

+

The Cb and Cr chroma planes are half the width of the luma plane, but full height.

TH_PF_444  -

No chroma decimation (4:4:4).

-

The Cb and Cr chroma planes are full width and full height.

+
TH_PF_444 

No chroma decimation (4:4:4).

+

The Cb and Cr chroma planes are full width and full height.

TH_PF_NFORMATS  -

The total number of currently defined pixel formats.

+
TH_PF_NFORMATS 

The total number of currently defined pixel formats.

- + + + +

Function Documentation

+ +

◆ th_comment_add()

+ +
+
+ + + + + + + + + + + + + + + + + + +
void th_comment_add (th_comment_tc,
const char * _comment 
)
+
+ +

Add a comment to an initialized th_comment structure.

+
Note
Neither th_comment_add() nor th_comment_add_tag() support comments containing null values, although the bitstream format does support them. To add such comments you will need to manipulate the th_comment structure directly.
+
Parameters
+ + + +
_tcThe th_comment struct to add the comment to.
_commentMust be a null-terminated UTF-8 string containing the comment in "TAG=the value" form.
+
+
+ +
+
+ +

◆ th_comment_add_tag()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
void th_comment_add_tag (th_comment_tc,
const char * _tag,
const char * _val 
)
+
+ +

Add a comment to an initialized th_comment structure.

+
Note
Neither th_comment_add() nor th_comment_add_tag() support comments containing null values, although the bitstream format does support them. To add such comments you will need to manipulate the th_comment structure directly.
+
Parameters
+ + + + +
_tcThe th_comment struct to add the comment to.
_tagA null-terminated string containing the tag associated with the comment.
_valThe corresponding value as a null-terminated string.
+
+
+ +
+
+ +

◆ th_comment_clear()

+ +
+
+ + + + + + + + +
void th_comment_clear (th_comment_tc)
+
+ +

Clears a th_comment structure.

+

This should be called on a th_comment structure after it is no longer needed. It will free all memory used by the structure members.

Parameters
+ + +
_tcThe th_comment struct to clear.
+
+
+ +

◆ th_comment_init()

+ +
+
+ + + + + + + + +
void th_comment_init (th_comment_tc)
+
+ +

Initialize a th_comment structure.

+

This should be called on a freshly allocated th_comment structure before attempting to use it.

Parameters
+ + +
_tcThe th_comment struct to initialize.
+
+
+ +
+
+ +

◆ th_comment_query()

+ +
+
+ + + + + + + + + + + + + + + + + + + + + + + + +
char * th_comment_query (th_comment_tc,
const char * _tag,
int _count 
)
+
+ +

Look up a comment value by its tag.

+
Parameters
+ + + + +
_tcAn initialized th_comment structure.
_tagThe tag to look up.
_countThe instance of the tag. The same tag can appear multiple times, each with a distinct value, so an index is required to retrieve them all. The order in which these values appear is significant and should be preserved. Use th_comment_query_count() to get the legal range for the _count parameter.
+
+
+
Returns
A pointer to the queried tag's value. This points directly to data in the th_comment structure. It should not be modified or freed by the application, and modifications to the structure may invalidate the pointer.
+
Return values
+ + +
NULLIf no matching tag is found.
+
+
+ +
+
+ +

◆ th_comment_query_count()

+ +
+
+ + + + + + + + + + + + + + + + + + +
int th_comment_query_count (th_comment_tc,
const char * _tag 
)
+
+ +

Look up the number of instances of a tag.

+

Call this first when querying for a specific tag and then iterate over the number of instances with separate calls to th_comment_query() to retrieve all the values for that tag in order.

Parameters
+ + + +
_tcAn initialized th_comment structure.
_tagThe tag to look up.
+
+
+
Returns
The number of instances of this particular tag.
+ +
+
+ +

◆ th_granule_frame()

+ +
+
+ + + + + + + + + + + + + + + + + + +
ogg_int64_t th_granule_frame (void * _encdec,
ogg_int64_t _granpos 
)
+
+ +

Converts a granule position to an absolute frame index, starting at 0.

+

The granule position is interpreted in the context of a given th_enc_ctx or th_dec_ctx handle (either will suffice).

Parameters
+ + + +
_encdecA previously allocated th_enc_ctx or th_dec_ctx handle.
_granposThe granule position to convert.
+
+
+
Returns
The absolute frame index corresponding to _granpos.
+
Return values
+ + +
-1The given granule position was invalid (i.e. negative).
+
+
+ +
+
+ +

◆ th_granule_time()

+ +
+
+ + + + + + + + + + + + + + + + + + +
double th_granule_time (void * _encdec,
ogg_int64_t _granpos 
)
+
+ +

Converts a granule position to an absolute time in seconds.

+

The granule position is interpreted in the context of a given th_enc_ctx or th_dec_ctx handle (either will suffice).

Parameters
+ + + +
_encdecA previously allocated th_enc_ctx or th_dec_ctx handle.
_granposThe granule position to convert.
+
+
+
Returns
The absolute time in seconds corresponding to _granpos. This is the "end time" for the frame, or the latest time it should be displayed. It is not the presentation time.
+
Return values
+ + +
-1The given granule position was invalid (i.e. negative).
+
+
+ +
+
+ +

◆ th_info_clear()

+ +
+
+ + + + + + + + +
void th_info_clear (th_info_info)
+
+ +

Clears a th_info structure.

+

This should be called on a th_info structure after it is no longer needed.

Parameters
+ + +
_infoThe th_info struct to clear.
+
+
+ +
+
+ +

◆ th_info_init()

+ +
+
+ + + + + + + + +
void th_info_init (th_info_info)
+
+ +

Initializes a th_info structure.

+

This should be called on a freshly allocated th_info structure before attempting to use it.

Parameters
+ + +
_infoThe th_info struct to initialize.
+
+
+ +
+
+ +

◆ th_packet_isheader()

+ +
+
+ + + + + + + + +
int th_packet_isheader (ogg_packet * _op)
+
+ +

Determines whether a Theora packet is a header or not.

+

This function does no verification beyond checking the packet type bit, so it should not be used for bitstream identification; use th_decode_headerin() for that. As per the Theora specification, an empty (0-byte) packet is treated as a data packet (a delta frame with no coded blocks).

Parameters
+ + +
_opAn ogg_packet containing encoded Theora data.
+
+
+
Return values
+ + + +
1The packet is a header packet
0The packet is a video data packet.
+
+
+ +
+
+ +

◆ th_packet_iskeyframe()

+ +
+
+ + + + + + + + +
int th_packet_iskeyframe (ogg_packet * _op)
+
+ +

Determines whether a theora packet is a key frame or not.

+

This function does no verification beyond checking the packet type and key frame bits, so it should not be used for bitstream identification; use th_decode_headerin() for that. As per the Theora specification, an empty (0-byte) packet is treated as a delta frame (with no coded blocks).

Parameters
+ + +
_opAn ogg_packet containing encoded Theora data.
+
+
+
Return values
+ + + + +
1The packet contains a key frame.
0The packet contains a delta frame.
-1The packet is not a video data packet.
+
+
+ +
+
+ +

◆ th_version_number()

+ +
+
+ + + + + + + + +
ogg_uint32_t th_version_number (void )
+
+ +

Retrieves the library version number.

+

This is the highest bitstream version that the encoder library will produce, or that the decoder library can decode. This number is composed of a 16-bit major version, 8-bit minor version and 8 bit sub-version, composed as follows:

(VERSION_MAJOR<<16)+(VERSION_MINOR<<8)+(VERSION_SUBMINOR)
+
Returns
the version number.
+ +
+
+ +

◆ th_version_string()

+ +
+
+ + + + + + + + +
const char * th_version_string (void )
+
+ +

Retrieves a human-readable string to identify the library vendor and version.

+
Returns
the version string.
+
- + + + diff --git a/doc/libtheora-1.2/codec_8h_source.html b/doc/libtheora-1.2/codec_8h_source.html index 46f692e904db75b77ca05b08981c6ca2b0ac3bab..eefbe4dc85d29c90894919ada491c0049e48f58c 100644 --- a/doc/libtheora-1.2/codec_8h_source.html +++ b/doc/libtheora-1.2/codec_8h_source.html @@ -1,201 +1,275 @@ - + + + + libtheora: codec.h Source File - + + + - - + + diff --git a/doc/libtheora-1.2/folderclosed.png b/doc/libtheora-1.2/folderclosed.png new file mode 100644 index 0000000000000000000000000000000000000000..bb8ab35edce8e97554e360005ee9fc5bffb36e66 Binary files /dev/null and b/doc/libtheora-1.2/folderclosed.png differ diff --git a/doc/libtheora-1.2/folderopen.png b/doc/libtheora-1.2/folderopen.png new file mode 100644 index 0000000000000000000000000000000000000000..d6c7f676a3b3ef8c2c307d319dff3c6a604eb227 Binary files /dev/null and b/doc/libtheora-1.2/folderopen.png differ diff --git a/doc/libtheora-1.2/functions.html b/doc/libtheora-1.2/functions.html index 557828c58306b77a14cc157679b199fb609caaf8..f14e0346a7dfb7c4a8f93313c62019cd3f85c23e 100644 --- a/doc/libtheora-1.2/functions.html +++ b/doc/libtheora-1.2/functions.html @@ -1,353 +1,192 @@ - + + + + libtheora: Data Fields - + + + - - + + diff --git a/doc/libtheora-1.2/functions_vars.html b/doc/libtheora-1.2/functions_vars.html index 7a5fc6eec25e702b45a9c30c32c78592c839d118..f9ae1ae382d6920bd56187ef2e132a144a34e5be 100644 --- a/doc/libtheora-1.2/functions_vars.html +++ b/doc/libtheora-1.2/functions_vars.html @@ -1,353 +1,192 @@ - + + + + libtheora: Data Fields - Variables - + + + - - + + diff --git a/doc/libtheora-1.2/globals.html b/doc/libtheora-1.2/globals.html index 10d316847dab6773216814be6b0e56375fbb6fd8..ee85a6b9eedd195444ad40c1725850f5fa4c29ec 100644 --- a/doc/libtheora-1.2/globals.html +++ b/doc/libtheora-1.2/globals.html @@ -1,473 +1,190 @@ - + -libtheora: Data Fields + + + +libtheora: Globals - + + + - - + + diff --git a/doc/libtheora-1.2/globals_defs.html b/doc/libtheora-1.2/globals_defs.html index 8d84f3d497b7e3f74db48980cd465621890a434b..5fbbdf5fe36d8bebd36c13b19636da0b49302dcc 100644 --- a/doc/libtheora-1.2/globals_defs.html +++ b/doc/libtheora-1.2/globals_defs.html @@ -1,218 +1,105 @@ - + -libtheora: Data Fields + + + +libtheora: Globals - + + + - - + + diff --git a/doc/libtheora-1.2/globals_enum.html b/doc/libtheora-1.2/globals_enum.html index f031ddc63cc8dbe135cd6a95470c3fc902c2237a..fda1587eba9972f81612c6c8010a69b528f782da 100644 --- a/doc/libtheora-1.2/globals_enum.html +++ b/doc/libtheora-1.2/globals_enum.html @@ -1,58 +1,54 @@ - + -libtheora: Data Fields + + + +libtheora: Globals - + + + - - + + diff --git a/doc/libtheora-1.2/globals_eval.html b/doc/libtheora-1.2/globals_eval.html index 336df20f44cf0052285d93903ff66405d97155aa..b44f7acf831eba57864f02f8f8bf9791154bc381 100644 --- a/doc/libtheora-1.2/globals_eval.html +++ b/doc/libtheora-1.2/globals_eval.html @@ -1,97 +1,67 @@ - + -libtheora: Data Fields + + + +libtheora: Globals - + + + - - + + diff --git a/doc/libtheora-1.2/globals_func.html b/doc/libtheora-1.2/globals_func.html index 2647bc6afd3d1508f69d3cdde6980b77f1510333..95c64c5ffe4b4619892b229f007729b6cc19468b 100644 --- a/doc/libtheora-1.2/globals_func.html +++ b/doc/libtheora-1.2/globals_func.html @@ -1,215 +1,106 @@ - + -libtheora: Data Fields + + + +libtheora: Globals - + + + - - + + diff --git a/doc/libtheora-1.2/globals_type.html b/doc/libtheora-1.2/globals_type.html index 58a52b4d992eccf8a3bc18e08dbd2cfee2abaf43..d112736f42864b32e7ae4e5c85b664f32c500885 100644 --- a/doc/libtheora-1.2/globals_type.html +++ b/doc/libtheora-1.2/globals_type.html @@ -1,70 +1,58 @@ - + -libtheora: Data Fields + + + +libtheora: Globals - + + + - - + + diff --git a/doc/libtheora-1.2/globals_vars.html b/doc/libtheora-1.2/globals_vars.html index 8032a60034b5461c78220d7c4a09b94dff189cf2..ab2216989b42c0e9b198fb220d91c631402e484d 100644 --- a/doc/libtheora-1.2/globals_vars.html +++ b/doc/libtheora-1.2/globals_vars.html @@ -1,52 +1,52 @@ - + -libtheora: Data Fields + + + +libtheora: Globals - + + + - - + + diff --git a/doc/libtheora-1.2/group__basefuncs.html b/doc/libtheora-1.2/group__basefuncs.html index 81c1067294695087c671956341b28d457649be1f..5526797127c457dba3c464ec0a7a15a42592557c 100644 --- a/doc/libtheora-1.2/group__basefuncs.html +++ b/doc/libtheora-1.2/group__basefuncs.html @@ -1,548 +1,51 @@ - + + + + libtheora: Functions Shared by Encode and Decode - + + + - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

-Basic shared functions

-

const char * th_version_string (void)
 Retrieves a human-readable string to identify the library vendor and version.
ogg_uint32_t th_version_number (void)
 Retrieves the library version number.
ogg_int64_t th_granule_frame (void *_encdec, ogg_int64_t _granpos)
 Converts a granule position to an absolute frame index, starting at 0.
double th_granule_time (void *_encdec, ogg_int64_t _granpos)
 Converts a granule position to an absolute time in seconds.
int th_packet_isheader (ogg_packet *_op)
 Determines whether a Theora packet is a header or not.
int th_packet_iskeyframe (ogg_packet *_op)
 Determines whether a theora packet is a key frame or not.

-Functions for manipulating header data

-

void th_info_init (th_info *_info)
 Initializes a th_info structure.
void th_info_clear (th_info *_info)
 Clears a th_info structure.
void th_comment_init (th_comment *_tc)
 Initialize a th_comment structure.
void th_comment_add (th_comment *_tc, char *_comment)
 Add a comment to an initialized th_comment structure.
void th_comment_add_tag (th_comment *_tc, char *_tag, char *_val)
 Add a comment to an initialized th_comment structure.
char * th_comment_query (th_comment *_tc, char *_tag, int _count)
 Look up a comment value by its tag.
int th_comment_query_count (th_comment *_tc, char *_tag)
 Look up the number of instances of a tag.
void th_comment_clear (th_comment *_tc)
 Clears a th_comment structure.
-

Function Documentation

- -
-
- - - - - - - - - - - - - - - - - - -
void th_comment_add (th_comment _tc,
char *  _comment 
)
-
-
- -

Add a comment to an initialized th_comment structure.

-
Note:
Neither th_comment_add() nor th_comment_add_tag() support comments containing null values, although the bitstream format does support them. To add such comments you will need to manipulate the th_comment structure directly.
-
Parameters:
- - - -
_tc The th_comment struct to add the comment to.
_comment Must be a null-terminated UTF-8 string containing the comment in "TAG=the value" form.
-
-
- -
-
- -
-
- - - - - - - - - - - - - - - - - - - - - - - - -
void th_comment_add_tag (th_comment _tc,
char *  _tag,
char *  _val 
)
-
-
- -

Add a comment to an initialized th_comment structure.

-
Note:
Neither th_comment_add() nor th_comment_add_tag() support comments containing null values, although the bitstream format does support them. To add such comments you will need to manipulate the th_comment structure directly.
-
Parameters:
- - - - -
_tc The th_comment struct to add the comment to.
_tag A null-terminated string containing the tag associated with the comment.
_val The corresponding value as a null-terminated string.
-
-
- -
-
- -
-
- - - - - - - - - -
void th_comment_clear (th_comment _tc ) 
-
-
- -

Clears a th_comment structure.

-

This should be called on a th_comment structure after it is no longer needed. It will free all memory used by the structure members.

-
Parameters:
- - -
_tc The th_comment struct to clear.
-
-
- -
-
- -
-
- - - - - - - - - -
void th_comment_init (th_comment _tc ) 
-
-
- -

Initialize a th_comment structure.

-

This should be called on a freshly allocated th_comment structure before attempting to use it.

-
Parameters:
- - -
_tc The th_comment struct to initialize.
-
-
- -
-
- -
-
- - - - - - - - - - - - - - - - - - - - - - - - -
char* th_comment_query (th_comment _tc,
char *  _tag,
int  _count 
)
-
-
- -

Look up a comment value by its tag.

-
Parameters:
- - - - -
_tc An initialized th_comment structure.
_tag The tag to look up.
_count The instance of the tag. The same tag can appear multiple times, each with a distinct value, so an index is required to retrieve them all. The order in which these values appear is significant and should be preserved. Use th_comment_query_count() to get the legal range for the _count parameter.
-
-
-
Returns:
A pointer to the queried tag's value. This points directly to data in the th_comment structure. It should not be modified or freed by the application, and modifications to the structure may invalidate the pointer.
-
Return values:
- - -
NULL If no matching tag is found.
-
-
- -
-
- -
-
- - - - - - - - - - - - - - - - - - -
int th_comment_query_count (th_comment _tc,
char *  _tag 
)
-
-
- -

Look up the number of instances of a tag.

-

Call this first when querying for a specific tag and then iterate over the number of instances with separate calls to th_comment_query() to retrieve all the values for that tag in order.

-
Parameters:
- - - -
_tc An initialized th_comment structure.
_tag The tag to look up.
-
-
-
Returns:
The number on instances of this particular tag.
- -
-
- -
-
- - - - - - - - - - - - - - - - - - -
ogg_int64_t th_granule_frame (void *  _encdec,
ogg_int64_t  _granpos 
)
-
-
- -

Converts a granule position to an absolute frame index, starting at 0.

-

The granule position is interpreted in the context of a given th_enc_ctx or th_dec_ctx handle (either will suffice).

-
Parameters:
- - - -
_encdec A previously allocated th_enc_ctx or th_dec_ctx handle.
_granpos The granule position to convert.
-
-
-
Returns:
The absolute frame index corresponding to _granpos.
-
Return values:
- - -
-1 The given granule position was invalid (i.e. negative).
-
-
- -
-
- -
-
- - - - - - - - - - - - - - - - - - -
double th_granule_time (void *  _encdec,
ogg_int64_t  _granpos 
)
-
-
- -

Converts a granule position to an absolute time in seconds.

-

The granule position is interpreted in the context of a given th_enc_ctx or th_dec_ctx handle (either will suffice).

-
Parameters:
- - - -
_encdec A previously allocated th_enc_ctx or th_dec_ctx handle.
_granpos The granule position to convert.
-
-
-
Returns:
The absolute time in seconds corresponding to _granpos. This is the "end time" for the frame, or the latest time it should be displayed. It is not the presentation time.
-
Return values:
- - -
-1 The given granule position was invalid (i.e. negative).
-
-
- -
-
- -
-
- - - - - - - - - -
void th_info_clear (th_info _info ) 
-
-
- -

Clears a th_info structure.

-

This should be called on a th_info structure after it is no longer needed.

-
Parameters:
- - -
_info The th_info struct to clear.
-
-
- -
-
- -
-
- - - - - - - - - -
void th_info_init (th_info _info ) 
-
-
- -

Initializes a th_info structure.

-

This should be called on a freshly allocated th_info structure before attempting to use it.

-
Parameters:
- - -
_info The th_info struct to initialize.
-
-
- -
-
- -
-
- - - - - - - - - -
int th_packet_isheader (ogg_packet *  _op ) 
-
-
- -

Determines whether a Theora packet is a header or not.

-

This function does no verification beyond checking the packet type bit, so it should not be used for bitstream identification; use th_decode_headerin() for that. As per the Theora specification, an empty (0-byte) packet is treated as a data packet (a delta frame with no coded blocks).

-
Parameters:
- - -
_op An ogg_packet containing encoded Theora data.
-
-
-
Return values:
- - - -
1 The packet is a header packet
0 The packet is a video data packet.
-
-
- -
-
- -
-
- - - - - - - - - -
int th_packet_iskeyframe (ogg_packet *  _op ) 
-
-
- -

Determines whether a theora packet is a key frame or not.

-

This function does no verification beyond checking the packet type and key frame bits, so it should not be used for bitstream identification; use th_decode_headerin() for that. As per the Theora specification, an empty (0-byte) packet is treated as a delta frame (with no coded blocks).

-
Parameters:
- - -
_op An ogg_packet containing encoded Theora data.
-
-
-
Return values:
- - - - -
1 The packet contains a key frame.
0 The packet contains a delta frame.
-1 The packet is not a video data packet.
-
-
- -
-
- -
-
- - - - - - - - - -
ogg_uint32_t th_version_number (void  ) 
-
-
- -

Retrieves the library version number.

-

This is the highest bitstream version that the encoder library will produce, or that the decoder library can decode. This number is composed of a 16-bit major version, 8-bit minor version and 8 bit sub-version, composed as follows:

-
 (VERSION_MAJOR<<16)+(VERSION_MINOR<<8)+(VERSION_SUBMINOR)
-
Returns:
the version number.
- -
-
- -
-
- - - - - - - - - -
const char* th_version_string (void  ) 
-
-
- -

Retrieves a human-readable string to identify the library vendor and version.

-
Returns:
the version string.
- -
-
-
- + + + diff --git a/doc/libtheora-1.2/group__decfuncs.html b/doc/libtheora-1.2/group__decfuncs.html index bd1aa685aff9b701d45ed5f01cff6db192531df2..015f4f18921f88461db77558a50eb6581e7378a7 100644 --- a/doc/libtheora-1.2/group__decfuncs.html +++ b/doc/libtheora-1.2/group__decfuncs.html @@ -1,372 +1,51 @@ - + + + + libtheora: Functions for Decoding - + + + - -
- - - - - - - - - - - - - - - - - -

-Functions for decoding

You must link to libtheoradec if you use any of the functions in this section.

-

The functions are listed in the order they are used in a typical decode. The basic steps are:

- -

int th_decode_headerin (th_info *_info, th_comment *_tc, th_setup_info **_setup, ogg_packet *_op)
 Decodes the header packets of a Theora stream.
th_dec_ctxth_decode_alloc (const th_info *_info, const th_setup_info *_setup)
 Allocates a decoder instance.
void th_setup_free (th_setup_info *_setup)
 Releases all storage used for the decoder setup information.
int th_decode_ctl (th_dec_ctx *_dec, int _req, void *_buf, size_t _buf_sz)
 Decoder control function.
int th_decode_packetin (th_dec_ctx *_dec, const ogg_packet *_op, ogg_int64_t *_granpos)
 Submits a packet containing encoded video data to the decoder.
int th_decode_ycbcr_out (th_dec_ctx *_dec, th_ycbcr_buffer _ycbcr)
 Outputs the next available frame of decoded Y'CbCr data.
void th_decode_free (th_dec_ctx *_dec)
 Frees an allocated decoder instance.
-

Function Documentation

- -
-
- - - - - - - - - - - - - - - - - - -
th_dec_ctx* th_decode_alloc (const th_info _info,
const th_setup_info _setup 
)
-
-
- -

Allocates a decoder instance.

-

Security Warning: The Theora format supports very large frame sizes, potentially even larger than the address space of a 32-bit machine, and creating a decoder context allocates the space for several frames of data. If the allocation fails here, your program will crash, possibly at some future point because the OS kernel returned a valid memory range and will only fail when it tries to map the pages in it the first time they are used. Even if it succeeds, you may experience a denial of service if the frame size is large enough to cause excessive paging. If you are integrating libtheora in a larger application where such things are undesirable, it is highly recommended that you check the frame size in _info before calling this function and refuse to decode streams where it is larger than some reasonable maximum. libtheora will not check this for you, because there may be machines that can handle such streams and applications that wish to.

-
Parameters:
- - - -
_info A th_info struct filled via th_decode_headerin().
_setup A th_setup_info handle returned via th_decode_headerin().
-
-
-
Returns:
The initialized th_dec_ctx handle.
-
Return values:
- - -
NULL If the decoding parameters were invalid.
-
-
- -
-
- -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
int th_decode_ctl (th_dec_ctx _dec,
int  _req,
void *  _buf,
size_t  _buf_sz 
)
-
-
- -

Decoder control function.

-

This is used to provide advanced control of the decoding process.

-
Parameters:
- - - - - -
_dec A th_dec_ctx handle.
_req The control code to process. See the list of available control codes for details.
_buf The parameters for this control code.
_buf_sz The size of the parameter buffer.
-
-
- -
-
- -
-
- - - - - - - - - -
void th_decode_free (th_dec_ctx _dec ) 
-
-
- -

Frees an allocated decoder instance.

-
Parameters:
- - -
_dec A th_dec_ctx handle.
-
-
- -
-
- -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
int th_decode_headerin (th_info _info,
th_comment _tc,
th_setup_info **  _setup,
ogg_packet *  _op 
)
-
-
- -

Decodes the header packets of a Theora stream.

-

This should be called on the initial packets of the stream, in succession, until it returns 0, indicating that all headers have been processed, or an error is encountered. At least three header packets are required, and additional optional header packets may follow. This can be used on the first packet of any logical stream to determine if that stream is a Theora stream.

-
Parameters:
- - - - - -
_info A th_info structure to fill in. This must have been previously initialized with th_info_init(). The application may immediately begin using the contents of this structure after the first header is decoded, though it must continue to be passed in on all subsequent calls.
_tc A th_comment structure to fill in. The application may immediately begin using the contents of this structure after the second header is decoded, though it must continue to be passed in on all subsequent calls.
_setup Returns a pointer to additional, private setup information needed by the decoder. The contents of this pointer must be initialized to NULL on the first call, and the returned value must continue to be passed in on all subsequent calls.
_op An ogg_packet structure which contains one of the initial packets of an Ogg logical stream.
-
-
-
Returns:
A positive value indicates that a Theora header was successfully processed.
-
Return values:
- - - - - - -
0 The first video data packet was encountered after all required header packets were parsed. The packet just passed in on this call should be saved and fed to th_decode_packetin() to begin decoding video data.
TH_EFAULT One of _info, _tc, or _setup was NULL.
TH_EBADHEADER _op was NULL, the packet was not the next header packet in the expected sequence, or the format of the header data was invalid.
TH_EVERSION The packet data was a Theora info header, but for a bitstream version not decodable with this version of libtheoradec.
TH_ENOTFORMAT The packet was not a Theora header.
-
-
- -
-
- -
-
- - - - - - - - - - - - - - - - - - - - - - - - -
int th_decode_packetin (th_dec_ctx _dec,
const ogg_packet *  _op,
ogg_int64_t *  _granpos 
)
-
-
- -

Submits a packet containing encoded video data to the decoder.

-
Parameters:
- - - - -
_dec A th_dec_ctx handle.
_op An ogg_packet containing encoded video data.
_granpos Returns the granule position of the decoded packet. If non-NULL, the granule position for this specific packet is stored in this location. This is computed incrementally from previously decoded packets. After a seek, the correct granule position must be set via TH_DECCTL_SET_GRANPOS for this to work properly.
-
-
-
Return values:
- - - - - - -
0 Success. A new decoded frame can be retrieved by calling th_decode_ycbcr_out().
TH_DUPFRAME The packet represented a dropped frame (either a 0-byte frame or an INTER frame with no coded blocks). The player can skip the call to th_decode_ycbcr_out(), as the contents of the decoded frame buffer have not changed.
TH_EFAULT _dec or _op was NULL.
TH_EBADPACKET _op does not contain encoded video data.
TH_EIMPL The video data uses bitstream features which this library does not support.
-
-
- -
-
- -
-
- - - - - - - - - - - - - - - - - - -
int th_decode_ycbcr_out (th_dec_ctx _dec,
th_ycbcr_buffer  _ycbcr 
)
-
-
- -

Outputs the next available frame of decoded Y'CbCr data.

-

If a striped decode callback has been set with TH_DECCTL_SET_STRIPE_CB, then the application does not need to call this function.

-
Parameters:
- - - -
_dec A th_dec_ctx handle.
_ycbcr A video buffer structure to fill in. libtheoradec will fill in all the members of this structure, including the pointers to the uncompressed video data. The memory for this video data is owned by libtheoradec. It may be freed or overwritten without notification when subsequent frames are decoded.
-
-
-
Return values:
- - - -
0 Success
TH_EFAULT _dec or _ycbcr was NULL.
-
-
- -
-
- -
-
- - - - - - - - - -
void th_setup_free (th_setup_info _setup ) 
-
-
- -

Releases all storage used for the decoder setup information.

-

This should be called after you no longer want to create any decoders for a stream whose headers you have parsed with th_decode_headerin().

-
Parameters:
- - -
_setup The setup information to free. This can safely be NULL.
-
-
- -
-
-
- + + + diff --git a/doc/libtheora-1.2/group__encfuncs.html b/doc/libtheora-1.2/group__encfuncs.html index 17d70a70c2ceca24151d7f5cc7ec2319eb3e6fef..63bdb3eaa5d2a9386dd56e6088762e073f381d52 100644 --- a/doc/libtheora-1.2/group__encfuncs.html +++ b/doc/libtheora-1.2/group__encfuncs.html @@ -1,322 +1,51 @@ - + + + + libtheora: Functions for Encoding - + + + - -
- - - - - - - - - - - - - - - -

-Functions for encoding

You must link to libtheoraenc and libtheoradec if you use any of the functions in this section.

-

The functions are listed in the order they are used in a typical encode. The basic steps are:

- -

th_enc_ctxth_encode_alloc (const th_info *_info)
 Allocates an encoder instance.
int th_encode_ctl (th_enc_ctx *_enc, int _req, void *_buf, size_t _buf_sz)
 Encoder control function.
int th_encode_flushheader (th_enc_ctx *_enc, th_comment *_comments, ogg_packet *_op)
 Outputs the next header packet.
int th_encode_ycbcr_in (th_enc_ctx *_enc, th_ycbcr_buffer _ycbcr)
 Submits an uncompressed frame to the encoder.
int th_encode_packetout (th_enc_ctx *_enc, int _last, ogg_packet *_op)
 Retrieves encoded video data packets.
void th_encode_free (th_enc_ctx *_enc)
 Frees an allocated encoder instance.
-

Function Documentation

- -
-
- - - - - - - - - -
th_enc_ctx* th_encode_alloc (const th_info _info ) 
-
-
- -

Allocates an encoder instance.

-
Parameters:
- - -
_info A th_info struct filled with the desired encoding parameters.
-
-
-
Returns:
The initialized th_enc_ctx handle.
-
Return values:
- - -
NULL If the encoding parameters were invalid.
-
-
- -
-
- -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
int th_encode_ctl (th_enc_ctx _enc,
int  _req,
void *  _buf,
size_t  _buf_sz 
)
-
-
- -

Encoder control function.

-

This is used to provide advanced control the encoding process.

-
Parameters:
- - - - - -
_enc A th_enc_ctx handle.
_req The control code to process. See the list of available control codes for details.
_buf The parameters for this control code.
_buf_sz The size of the parameter buffer.
-
-
- -
-
- -
-
- - - - - - - - - - - - - - - - - - - - - - - - -
int th_encode_flushheader (th_enc_ctx _enc,
th_comment _comments,
ogg_packet *  _op 
)
-
-
- -

Outputs the next header packet.

-

This should be called repeatedly after encoder initialization until it returns 0 in order to get all of the header packets, in order, before encoding actual video data.

-
Parameters:
- - - - -
_enc A th_enc_ctx handle.
_comments The metadata to place in the comment header, when it is encoded.
_op An ogg_packet structure to fill. All of the elements of this structure will be set, including a pointer to the header data. The memory for the header data is owned by libtheoraenc, and may be invalidated when the next encoder function is called.
-
-
-
Returns:
A positive value indicates that a header packet was successfully produced.
-
Return values:
- - - -
0 No packet was produced, and no more header packets remain.
TH_EFAULT _enc, _comments, or _op was NULL.
-
-
- -
-
- -
-
- - - - - - - - - -
void th_encode_free (th_enc_ctx _enc ) 
-
-
- -

Frees an allocated encoder instance.

-
Parameters:
- - -
_enc A th_enc_ctx handle.
-
-
- -
-
- -
-
- - - - - - - - - - - - - - - - - - - - - - - - -
int th_encode_packetout (th_enc_ctx _enc,
int  _last,
ogg_packet *  _op 
)
-
-
- -

Retrieves encoded video data packets.

-

This should be called repeatedly after each frame is submitted to flush any encoded packets, until it returns 0. The encoder will not buffer these packets as subsequent frames are compressed, so a failure to do so will result in lost video data.

-
Note:
Currently the encoder operates in a one-frame-in, one-packet-out manner. However, this may be changed in the future.
-
Parameters:
- - - - -
_enc A th_enc_ctx handle.
_last Set this flag to a non-zero value if no more uncompressed frames will be submitted. This ensures that a proper EOS flag is set on the last packet.
_op An ogg_packet structure to fill. All of the elements of this structure will be set, including a pointer to the video data. The memory for the video data is owned by libtheoraenc, and may be invalidated when the next encoder function is called.
-
-
-
Returns:
A positive value indicates that a video data packet was successfully produced.
-
Return values:
- - - -
0 No packet was produced, and no more encoded video data remains.
TH_EFAULT _enc or _op was NULL.
-
-
- -
-
- -
-
- - - - - - - - - - - - - - - - - - -
int th_encode_ycbcr_in (th_enc_ctx _enc,
th_ycbcr_buffer  _ycbcr 
)
-
-
- -

Submits an uncompressed frame to the encoder.

-
Parameters:
- - - -
_enc A th_enc_ctx handle.
_ycbcr A buffer of Y'CbCr data to encode. If the width and height of the buffer matches the frame size the encoder was initialized with, the encoder will only reference the portion inside the picture region. Any data outside this region will be ignored, and need not map to a valid address. Alternatively, you can pass a buffer equal to the size of the picture region, if this is less than the full frame size. When using subsampled chroma planes, odd picture sizes or odd picture offsets may require an unexpected chroma plane size, and their use is generally discouraged, as they will not be well-supported by players and other media frameworks. See Section 4.4 of the Theora specification for details if you wish to use them anyway.
-
-
-
Return values:
- - - - -
0 Success.
TH_EFAULT _enc or _ycbcr is NULL.
TH_EINVAL The buffer size matches neither the frame size nor the picture size the encoder was initialized with, or encoding has already completed.
-
-
- -
-
-
- + + + diff --git a/doc/libtheora-1.2/group__oldfuncs.html b/doc/libtheora-1.2/group__oldfuncs.html index 38932328e8b034d90e02ea779477f7103a54861b..fb39f45dc157e31dfaa75d71bfba1e2a2a469837 100644 --- a/doc/libtheora-1.2/group__oldfuncs.html +++ b/doc/libtheora-1.2/group__oldfuncs.html @@ -1,1646 +1,61 @@ - + + + + libtheora: Legacy pre-1.0 C API - + + + - - +
Legacy pre-1.0 C API
+
- - - - - - - - - - - - -

-

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + +

-Data Structures

struct  yuv_buffer
 A YUV buffer for passing uncompressed frames to and from the codec. More...
struct  theora_info
 Theora bitstream info. More...
struct  theora_state
 Codec internal state and context. More...
struct  theora_comment
 Comment header metadata. More...

+

Files

file  theora.h
 

The libtheora pre-1.0 legacy C API.

-

-Defines

#define OC_FAULT   -1
 General failure.
#define OC_EINVAL   -10
 Library encountered invalid internal data.
#define OC_DISABLED   -11
 Requested action is disabled.
#define OC_BADHEADER   -20
 Header packet was corrupt/invalid.
#define OC_NOTFORMAT   -21
 Packet is not a theora packet.
#define OC_VERSION   -22
 Bitstream version is not handled.
#define OC_IMPL   -23
 Feature or action not implemented.
#define OC_BADPACKET   -24
 Packet is corrupt.
#define OC_NEWPACKET   -25
 Packet is an (ignorable) unhandled extension.
#define OC_DUPFRAME   1
 Packet is a dropped frame.

-Typedefs

typedef struct theora_comment theora_comment
 Comment header metadata.

-Enumerations

enum  theora_colorspace { OC_CS_UNSPECIFIED, -OC_CS_ITU_REC_470M, -OC_CS_ITU_REC_470BG, -OC_CS_NSPACES - }
 

A Colorspace.

- More...
enum  theora_pixelformat { OC_PF_420, -OC_PF_RSVD, -OC_PF_422, -OC_PF_444 - }
 

A Chroma subsampling.

- More...

-Functions

const char * theora_version_string (void)
 Retrieve a human-readable string to identify the encoder vendor and version.
ogg_uint32_t theora_version_number (void)
 Retrieve a 32-bit version number.
int theora_encode_init (theora_state *th, theora_info *ti)
 Initialize the theora encoder.
int theora_encode_YUVin (theora_state *t, yuv_buffer *yuv)
 Submit a YUV buffer to the theora encoder.
int theora_encode_packetout (theora_state *t, int last_p, ogg_packet *op)
 Request the next packet of encoded video.
int theora_encode_header (theora_state *t, ogg_packet *op)
 Request a packet containing the initial header.
int theora_encode_comment (theora_comment *tc, ogg_packet *op)
 Request a comment header packet from provided metadata.
int theora_encode_tables (theora_state *t, ogg_packet *op)
 Request a packet containing the codebook tables for the stream.
int theora_decode_header (theora_info *ci, theora_comment *cc, ogg_packet *op)
 Decode an Ogg packet, with the expectation that the packet contains an initial header, comment data or codebook tables.
int theora_decode_init (theora_state *th, theora_info *c)
 Initialize a theora_state handle for decoding.
int theora_decode_packetin (theora_state *th, ogg_packet *op)
 Input a packet containing encoded data into the theora decoder.
int theora_decode_YUVout (theora_state *th, yuv_buffer *yuv)
 Output the next available frame of decoded YUV data.
int theora_packet_isheader (ogg_packet *op)
 Report whether a theora packet is a header or not This function does no verification beyond checking the header flag bit so it should not be used for bitstream identification; use theora_decode_header() for that.
int theora_packet_iskeyframe (ogg_packet *op)
 Report whether a theora packet is a keyframe or not.
int theora_granule_shift (theora_info *ti)
 Report the granulepos shift radix.
ogg_int64_t theora_granule_frame (theora_state *th, ogg_int64_t granulepos)
 Convert a granulepos to an absolute frame index, starting at 0.
double theora_granule_time (theora_state *th, ogg_int64_t granulepos)
 Convert a granulepos to absolute time in seconds.
void theora_info_init (theora_info *c)
 Initialize a theora_info structure.
void theora_info_clear (theora_info *c)
 Clear a theora_info structure.
void theora_clear (theora_state *t)
 Free all internal data associated with a theora_state handle.
void theora_comment_init (theora_comment *tc)
 Initialize an allocated theora_comment structure.
void theora_comment_add (theora_comment *tc, char *comment)
 Add a comment to an initialized theora_comment structure.
void theora_comment_add_tag (theora_comment *tc, char *tag, char *value)
 Add a comment to an initialized theora_comment structure.
char * theora_comment_query (theora_comment *tc, char *tag, int count)
 Look up a comment value by tag.
int theora_comment_query_count (theora_comment *tc, char *tag)
 Look up the number of instances of a tag.
void theora_comment_clear (theora_comment *tc)
 Clear an allocated theora_comment struct so that it can be freed.
int theora_control (theora_state *th, int req, void *buf, size_t buf_sz)
 Encoder control function.

-theora_control() codes

-

#define TH_DECCTL_GET_PPLEVEL_MAX   (1)
 Get the maximum post-processing level.
#define TH_DECCTL_SET_PPLEVEL   (3)
 Set the post-processing level.
#define TH_ENCCTL_SET_KEYFRAME_FREQUENCY_FORCE   (4)
 Sets the maximum distance between key frames.
#define TH_DECCTL_SET_GRANPOS   (5)
 Set the granule position.
#define TH_ENCCTL_SET_QUANT_PARAMS   (2)
 Sets the quantization parameters to use.
#define TH_ENCCTL_SET_VP3_COMPATIBLE   (10)
 Disables any encoder features that would prevent lossless transcoding back to VP3.
#define TH_ENCCTL_GET_SPLEVEL_MAX   (12)
 Gets the maximum speed level.
#define TH_ENCCTL_SET_SPLEVEL   (14)
 Sets the speed level.
file  theora.h
 The libtheora pre-1.0 legacy C API.
 
-

Define Documentation

- -
-
- - - - -
#define OC_BADHEADER   -20
-
-
- -

Header packet was corrupt/invalid.

- -
-
- -
-
- - - - -
#define OC_BADPACKET   -24
-
-
- -

Packet is corrupt.

- -
-
- -
-
- - - - -
#define OC_DISABLED   -11
-
-
- -

Requested action is disabled.

- -
-
- -
-
- - - - -
#define OC_DUPFRAME   1
-
-
- -

Packet is a dropped frame.

- -
-
- -
-
- - - - -
#define OC_EINVAL   -10
-
-
- -

Library encountered invalid internal data.

- -
-
- -
-
- - - - -
#define OC_FAULT   -1
-
-
- -

General failure.

- -
-
- -
-
- - - - -
#define OC_IMPL   -23
-
-
- -

Feature or action not implemented.

- -
-
- -
-
- - - - -
#define OC_NEWPACKET   -25
-
-
- -

Packet is an (ignorable) unhandled extension.

- -
-
- -
-
- - - - -
#define OC_NOTFORMAT   -21
-
-
- -

Packet is not a theora packet.

- -
-
- -
-
- - - - -
#define OC_VERSION   -22
-
-
- -

Bitstream version is not handled.

- -
-
- -
-
- - - - -
#define TH_DECCTL_GET_PPLEVEL_MAX   (1)
-
-
- -

Get the maximum post-processing level.

-

The decoder supports a post-processing filter that can improve the appearance of the decoded images. This returns the highest level setting for this post-processor, corresponding to maximum improvement and computational expense.

- -
-
- -
-
- - - - -
#define TH_DECCTL_SET_GRANPOS   (5)
-
-
- -

Set the granule position.

-

Call this after a seek, to update the internal granulepos in the decoder, to insure that subsequent frames are marked properly. If you track timestamps yourself and do not use the granule postion returned by the decoder, then you do not need to use this control.

- -
-
- -
-
- - - - -
#define TH_DECCTL_SET_PPLEVEL   (3)
-
-
- -

Set the post-processing level.

-

Sets the level of post-processing to use when decoding the compressed stream. This must be a value between zero (off) and the maximum returned by TH_DECCTL_GET_PPLEVEL_MAX.

- -
-
- -
-
- - - - -
#define TH_ENCCTL_GET_SPLEVEL_MAX   (12)
-
-
- -

Gets the maximum speed level.

-

Higher speed levels favor quicker encoding over better quality per bit. Depending on the encoding mode, and the internal algorithms used, quality may actually improve, but in this case bitrate will also likely increase. In any case, overall rate/distortion performance will probably decrease. The maximum value, and the meaning of each value, may change depending on the current encoding mode (VBR vs. CQI, etc.).

-
Parameters:
- - -
[out] buf int: The maximum encoding speed level.
-
-
-
Return values:
- - - - -
OC_FAULT theora_state or buf is NULL.
OC_EINVAL buf_sz is not sizeof(int).
OC_IMPL Not supported by this implementation in the current encoding mode.
-
-
- -
-
- -
-
- - - - -
#define TH_ENCCTL_SET_KEYFRAME_FREQUENCY_FORCE   (4)
-
-
- -

Sets the maximum distance between key frames.

-

This can be changed during an encode, but will be bounded by 1<<th_info::keyframe_granule_shift. If it is set before encoding begins, th_info::keyframe_granule_shift will be enlarged appropriately.

-
Parameters:
- - - -
[in] buf ogg_uint32_t: The maximum distance between key frames.
[out] buf ogg_uint32_t: The actual maximum distance set.
-
-
-
Return values:
- - - - -
OC_FAULT theora_state or buf is NULL.
OC_EINVAL buf_sz is not sizeof(ogg_uint32_t).
OC_IMPL Not supported by this implementation.
-
-
- -
-
- -
-
- - - - -
#define TH_ENCCTL_SET_QUANT_PARAMS   (2)
-
-
- -

Sets the quantization parameters to use.

-

The parameters are copied, not stored by reference, so they can be freed after this call. NULL may be specified to revert to the default parameters.

-
Parameters:
- - -
[in] buf th_quant_info
-
-
-
Return values:
- - - - -
OC_FAULT theora_state is NULL.
OC_EINVAL Encoding has already begun, the quantization parameters are not acceptable to this version of the encoder, buf is NULL and buf_sz is not zero, or buf is non-NULL and buf_sz is not sizeof(th_quant_info).
OC_IMPL Not supported by this implementation.
-
-
- -
-
- -
-
- - - - -
#define TH_ENCCTL_SET_SPLEVEL   (14)
-
-
- -

Sets the speed level.

-

By default a speed value of 1 is used.

-
Parameters:
- - -
[in] buf int: The new encoding speed level. 0 is slowest, larger values use less CPU.
-
-
-
Return values:
- - - - -
OC_FAULT theora_state or buf is NULL.
OC_EINVAL buf_sz is not sizeof(int), or the encoding speed level is out of bounds. The maximum encoding speed level may be implementation- and encoding mode-specific, and can be obtained via TH_ENCCTL_GET_SPLEVEL_MAX.
OC_IMPL Not supported by this implementation in the current encoding mode.
-
-
- -
-
- -
-
- - - - -
#define TH_ENCCTL_SET_VP3_COMPATIBLE   (10)
-
-
- -

Disables any encoder features that would prevent lossless transcoding back to VP3.

-

This primarily means disabling block-level QI values and not using 4MV mode when any of the luma blocks in a macro block are not coded. It also includes using the VP3 quantization tables and Huffman codes; if you set them explicitly after calling this function, the resulting stream will not be VP3-compatible. If you enable VP3-compatibility when encoding 4:2:2 or 4:4:4 source material, or when using a picture region smaller than the full frame (e.g. a non-multiple-of-16 width or height), then non-VP3 bitstream features will still be disabled, but the stream will still not be VP3-compatible, as VP3 was not capable of encoding such formats. If you call this after encoding has already begun, then the quantization tables and codebooks cannot be changed, but the frame-level features will be enabled or disabled as requested.

-
Parameters:
- - - -
[in] buf int: a non-zero value to enable VP3 compatibility, or 0 to disable it (the default).
[out] buf int: 1 if all bitstream features required for VP3-compatibility could be set, and 0 otherwise. The latter will be returned if the pixel format is not 4:2:0, the picture region is smaller than the full frame, or if encoding has begun, preventing the quantization tables and codebooks from being set.
-
-
-
Return values:
- - - - -
OC_FAULT theora_state or buf is NULL.
OC_EINVAL buf_sz is not sizeof(int).
OC_IMPL Not supported by this implementation.
-
-
- -
-
-

Typedef Documentation

- -
-
- - - - -
typedef struct theora_comment theora_comment
-
-
- -

Comment header metadata.

-

This structure holds the in-stream metadata corresponding to the 'comment' header packet.

-

Meta data is stored as a series of (tag, value) pairs, in length-encoded string vectors. The first occurence of the '=' character delimits the tag and value. A particular tag may occur more than once. The character set encoding for the strings is always UTF-8, but the tag names are limited to case-insensitive ASCII. See the spec for details.

-

In filling in this structure, theora_decode_header() will null-terminate the user_comment strings for safety. However, the bitstream format itself treats them as 8-bit clean, and so the length array should be treated as authoritative for their length.

- -
-
-

Enumeration Type Documentation

- -
-
- - - - -
enum theora_colorspace
-
-
- -

A Colorspace.

-
Enumerator:
- - - - -
OC_CS_UNSPECIFIED  -

The colorspace is unknown or unspecified.

-
OC_CS_ITU_REC_470M  -

This is the best option for 'NTSC' content.

-
OC_CS_ITU_REC_470BG  -

This is the best option for 'PAL' content.

-
OC_CS_NSPACES  -

This marks the end of the defined colorspaces.

-
-
-
- -
-
- -
-
- - - - -
enum theora_pixelformat
-
-
- -

A Chroma subsampling.

-

These enumerate the available chroma subsampling options supported by the theora format. See Section 4.4 of the specification for exact definitions.

-
Enumerator:
- - - - -
OC_PF_420  -

Chroma subsampling by 2 in each direction (4:2:0).

-
OC_PF_RSVD  -

Reserved value.

-
OC_PF_422  -

Horizonatal chroma subsampling by 2 (4:2:2).

-
OC_PF_444  -

No chroma subsampling at all (4:4:4).

-
-
-
- -
-
-

Function Documentation

- -
-
- - - - - - - - - -
void theora_clear (theora_state t ) 
-
-
- -

Free all internal data associated with a theora_state handle.

-
Parameters:
- - -
t A theora_state handle.
-
-
- -
-
- -
-
- - - - - - - - - - - - - - - - - - -
void theora_comment_add (theora_comment tc,
char *  comment 
)
-
-
- -

Add a comment to an initialized theora_comment structure.

-
Parameters:
- - - -
tc A previously initialized theora comment structure
comment A null-terminated string encoding the comment in the form "TAG=the value"
-
-
-

Neither theora_comment_add() nor theora_comment_add_tag() support comments containing null values, although the bitstream format supports this. To add such comments you will need to manipulate the theora_comment structure directly.

- -
-
- -
-
- - - - - - - - - - - - - - - - - - - - - - - - -
void theora_comment_add_tag (theora_comment tc,
char *  tag,
char *  value 
)
-
-
- -

Add a comment to an initialized theora_comment structure.

-
Parameters:
- - - - -
tc A previously initialized theora comment structure
tag A null-terminated string containing the tag associated with the comment.
value The corresponding value as a null-terminated string
-
-
-

Neither theora_comment_add() nor theora_comment_add_tag() support comments containing null values, although the bitstream format supports this. To add such comments you will need to manipulate the theora_comment structure directly.

- -
-
- -
-
- - - - - - - - - -
void theora_comment_clear (theora_comment tc ) 
-
-
- -

Clear an allocated theora_comment struct so that it can be freed.

-
Parameters:
- - -
tc An allocated theora_comment structure.
-
-
- -
-
- -
-
- - - - - - - - - -
void theora_comment_init (theora_comment tc ) 
-
-
- -

Initialize an allocated theora_comment structure.

-
Parameters:
- - -
tc An allocated theora_comment structure
-
-
- -
-
- -
-
- - - - - - - - - - - - - - - - - - - - - - - - -
char* theora_comment_query (theora_comment tc,
char *  tag,
int  count 
)
-
-
- -

Look up a comment value by tag.

-
Parameters:
- - - - -
tc Tn initialized theora_comment structure
tag The tag to look up
count The instance of the tag. The same tag can appear multiple times, each with a distinct and ordered value, so an index is required to retrieve them all.
-
-
-
Returns:
A pointer to the queried tag's value
-
Return values:
- - -
NULL No matching tag is found
-
-
-
Note:
Use theora_comment_query_count() to get the legal range for the count parameter.
- -
-
- -
-
- - - - - - - - - - - - - - - - - - -
int theora_comment_query_count (theora_comment tc,
char *  tag 
)
-
-
- -

Look up the number of instances of a tag.

-
Parameters:
- - - -
tc An initialized theora_comment structure
tag The tag to look up
-
-
-
Returns:
The number on instances of a particular tag.
-

Call this first when querying for a specific tag and then interate over the number of instances with separate calls to theora_comment_query() to retrieve all instances in order.

- -
-
- -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
int theora_control (theora_state th,
int  req,
void *  buf,
size_t  buf_sz 
)
-
-
- -

Encoder control function.

-

This is used to provide advanced control the encoding process.

-
Parameters:
- - - - - -
th A theora_state handle.
req The control code to process. See the list of available control codes" for details.
buf The parameters for this control code.
buf_sz The size of the parameter buffer.
-
-
- -
-
- -
-
- - - - - - - - - - - - - - - - - - - - - - - - -
int theora_decode_header (theora_info ci,
theora_comment cc,
ogg_packet *  op 
)
-
-
- -

Decode an Ogg packet, with the expectation that the packet contains an initial header, comment data or codebook tables.

-
Parameters:
- - - - -
ci A theora_info structure to fill. This must have been previously initialized with theora_info_init(). If op contains an initial header, theora_decode_header() will fill ci with the parsed header values. If op contains codebook tables, theora_decode_header() will parse these and attach an internal representation to ci->codec_setup.
cc A theora_comment structure to fill. If op contains comment data, theora_decode_header() will fill cc with the parsed comments.
op An ogg_packet structure which you expect contains an initial header, comment data or codebook tables.
-
-
-
Return values:
- - - - - -
OC_BADHEADER op is NULL; OR the first byte of op->packet has the signature of an initial packet, but op is not a b_o_s packet; OR this packet has the signature of an initial header packet, but an initial header packet has already been seen; OR this packet has the signature of a comment packet, but the initial header has not yet been seen; OR this packet has the signature of a comment packet, but contains invalid data; OR this packet has the signature of codebook tables, but the initial header or comments have not yet been seen; OR this packet has the signature of codebook tables, but contains invalid data; OR the stream being decoded has a compatible version but this packet does not have the signature of a theora initial header, comments, or codebook packet
OC_VERSION The packet data of op is an initial header with a version which is incompatible with this version of libtheora.
OC_NEWPACKET the stream being decoded has an incompatible (future) version and contains an unknown signature.
0 Success
-
-
-
Note:
The normal usage is that theora_decode_header() be called on the first three packets of a theora logical bitstream in succession.
- -
-
- -
-
- - - - - - - - - - - - - - - - - - -
int theora_decode_init (theora_state th,
theora_info c 
)
-
-
- -

Initialize a theora_state handle for decoding.

-
Parameters:
- - - -
th The theora_state handle to initialize.
c A theora_info struct filled with the desired decoding parameters. This is of course usually obtained from a previous call to theora_decode_header().
-
-
-
Return values:
- - -
0 Success
-
-
- -
-
- -
-
- - - - - - - - - - - - - - - - - - -
int theora_decode_packetin (theora_state th,
ogg_packet *  op 
)
-
-
- -

Input a packet containing encoded data into the theora decoder.

-
Parameters:
- - - -
th A theora_state handle previously initialized for decoding.
op An ogg_packet containing encoded theora data.
-
-
-
Return values:
- - - -
0 Success
OC_BADPACKET op does not contain encoded video data
-
-
- -
-
- -
-
- - - - - - - - - - - - - - - - - - -
int theora_decode_YUVout (theora_state th,
yuv_buffer yuv 
)
-
-
- -

Output the next available frame of decoded YUV data.

-
Parameters:
- - - -
th A theora_state handle previously initialized for decoding.
yuv A yuv_buffer in which libtheora should place the decoded data. Note that the buffer struct itself is allocated by the user, but that the luma and chroma pointers will be filled in by the library. Also note that these luma and chroma regions should be considered read-only by the user.
-
-
-
Return values:
- - -
0 Success
-
-
- -
-
- -
-
- - - - - - - - - - - - - - - - - - -
int theora_encode_comment (theora_comment tc,
ogg_packet *  op 
)
-
-
- -

Request a comment header packet from provided metadata.

-

A pointer to the comment data is placed in a user-provided ogg_packet structure.

-
Parameters:
- - - -
tc A theora_comment structure filled with the desired metadata
op An ogg_packet structure to fill. libtheora will set all elements of this structure, including a pointer to the encoded comment data. The memory for the comment data is owned by libtheora.
-
-
-
Return values:
- - -
0 Success
-
-
- -
-
- -
-
- - - - - - - - - - - - - - - - - - -
int theora_encode_header (theora_state t,
ogg_packet *  op 
)
-
-
- -

Request a packet containing the initial header.

-

A pointer to the header data is placed in a user-provided ogg_packet structure.

-
Parameters:
- - - -
t A theora_state handle previously initialized for encoding.
op An ogg_packet structure to fill. libtheora will set all elements of this structure, including a pointer to the header data. The memory for the header data is owned by libtheora.
-
-
-
Return values:
- - -
0 Success
-
-
- -
-
- -
-
- - - - - - - - - - - - - - - - - - -
int theora_encode_init (theora_state th,
theora_info ti 
)
-
-
- -

Initialize the theora encoder.

-
Parameters:
- - - -
th The theora_state handle to initialize for encoding.
ti A theora_info struct filled with the desired encoding parameters.
-
-
-
Return values:
- - -
0 Success
-
-
- -
-
- -
-
- - - - - - - - - - - - - - - - - - - - - - - - -
int theora_encode_packetout (theora_state t,
int  last_p,
ogg_packet *  op 
)
-
-
- -

Request the next packet of encoded video.

-

The encoded data is placed in a user-provided ogg_packet structure.

-
Parameters:
- - - - -
t A theora_state handle previously initialized for encoding.
last_p whether this is the last packet the encoder should produce.
op An ogg_packet structure to fill. libtheora will set all elements of this structure, including a pointer to encoded data. The memory for the encoded data is owned by libtheora.
-
-
-
Return values:
- - - - -
0 No internal storage exists OR no packet is ready
-1 The encoding process has completed
1 Success
-
-
- -
-
- -
-
- - - - - - - - - - - - - - - - - - -
int theora_encode_tables (theora_state t,
ogg_packet *  op 
)
-
-
- -

Request a packet containing the codebook tables for the stream.

-

A pointer to the codebook data is placed in a user-provided ogg_packet structure.

-
Parameters:
- - - -
t A theora_state handle previously initialized for encoding.
op An ogg_packet structure to fill. libtheora will set all elements of this structure, including a pointer to the codebook data. The memory for the header data is owned by libtheora.
-
-
-
Return values:
- - -
0 Success
-
-
- -
-
- -
-
- - - - - - - - - - - - - - - - - - -
int theora_encode_YUVin (theora_state t,
yuv_buffer yuv 
)
-
-
- -

Submit a YUV buffer to the theora encoder.

-
Parameters:
- - - -
t A theora_state handle previously initialized for encoding.
yuv A buffer of YUV data to encode. Note that both the yuv_buffer struct and the luma/chroma buffers within should be allocated by the user.
-
-
-
Return values:
- - - - -
OC_EINVAL Encoder is not ready, or is finished.
-1 The size of the given frame differs from those previously input
0 Success
-
-
- -
-
- -
-
- - - - - - - - - - - - - - - - - - -
ogg_int64_t theora_granule_frame (theora_state th,
ogg_int64_t  granulepos 
)
-
-
- -

Convert a granulepos to an absolute frame index, starting at 0.

-

The granulepos is interpreted in the context of a given theora_state handle.

-

Note that while the granulepos encodes the frame count (i.e. starting from 1) this call returns the frame index, starting from zero. Thus One can calculate the presentation time by multiplying the index by the rate.

-
Parameters:
- - - -
th A previously initialized theora_state handle (encode or decode)
granulepos The granulepos to convert.
-
-
-
Returns:
The frame index corresponding to granulepos.
-
Return values:
- - -
-1 The given granulepos is undefined (i.e. negative)
-
-
-

Thus function was added in the 1.0alpha4 release.

- -
-
- -
-
- - - - - - - - - -
int theora_granule_shift (theora_info ti ) 
-
-
- -

Report the granulepos shift radix.

-

When embedded in Ogg, Theora uses a two-part granulepos, splitting the 64-bit field into two pieces. The more-significant section represents the frame count at the last keyframe, and the less-significant section represents the count of frames since the last keyframe. In this way the overall field is still non-decreasing with time, but usefully encodes a pointer to the last keyframe, which is necessary for correctly restarting decode after a seek.

-

This function reports the number of bits used to represent the distance to the last keyframe, and thus how the granulepos field must be shifted or masked to obtain the two parts.

-

Since libtheora returns compressed data in an ogg_packet structure, this may be generally useful even if the Theora packets are not being used in an Ogg container.

-
Parameters:
- - -
ti A previously initialized theora_info struct
-
-
-
Returns:
The bit shift dividing the two granulepos fields
-

This function was added in the 1.0alpha5 release.

- -
-
- -
-
- - - - - - - - - - - - - - - - - - -
double theora_granule_time (theora_state th,
ogg_int64_t  granulepos 
)
-
-
- -

Convert a granulepos to absolute time in seconds.

-

The granulepos is interpreted in the context of a given theora_state handle, and gives the end time of a frame's presentation as used in Ogg mux ordering.

-
Parameters:
- - - -
th A previously initialized theora_state handle (encode or decode)
granulepos The granulepos to convert.
-
-
-
Returns:
The absolute time in seconds corresponding to granulepos. This is the "end time" for the frame, or the latest time it should be displayed. It is not the presentation time.
-
Return values:
- - - -
-1. The given granulepos is undefined (i.e. negative), or
-1. The function has been disabled because floating point support is not available.
-
-
- -
-
- -
-
- - - - - - - - - -
void theora_info_clear (theora_info c ) 
-
-
- -

Clear a theora_info structure.

-

All values within the given theora_info structure are cleared, and associated internal codec setup data is freed.

-
Parameters:
- - -
c A theora_info struct to initialize.
-
-
- -
-
- -
-
- - - - - - - - - -
void theora_info_init (theora_info c ) 
-
-
- -

Initialize a theora_info structure.

-

All values within the given theora_info structure are initialized, and space is allocated within libtheora for internal codec setup data.

-
Parameters:
- - -
c A theora_info struct to initialize.
-
-
- -
-
- -
-
- - - - - - - - - -
int theora_packet_isheader (ogg_packet *  op ) 
-
-
- -

Report whether a theora packet is a header or not This function does no verification beyond checking the header flag bit so it should not be used for bitstream identification; use theora_decode_header() for that.

-
Parameters:
- - -
op An ogg_packet containing encoded theora data.
-
-
-
Return values:
- - - -
1 The packet is a header packet
0 The packet is not a header packet (and so contains frame data)
-
-
-

Thus function was added in the 1.0alpha4 release.

- -
-
- -
-
- - - - - - - - - -
int theora_packet_iskeyframe (ogg_packet *  op ) 
-
-
- -

Report whether a theora packet is a keyframe or not.

-
Parameters:
- - -
op An ogg_packet containing encoded theora data.
-
-
-
Return values:
- - - - -
1 The packet contains a keyframe image
0 The packet is contains an interframe delta
-1 The packet is not an image data packet at all
-
-
-

Thus function was added in the 1.0alpha4 release.

- -
-
- -
-
- - - - - - - - - -
ogg_uint32_t theora_version_number (void  ) 
-
-
- -

Retrieve a 32-bit version number.

-

This number is composed of a 16-bit major version, 8-bit minor version and 8 bit sub-version, composed as follows:

-
-   (VERSION_MAJOR<<16) + (VERSION_MINOR<<8) + (VERSION_SUB)
-
Returns:
The version number.
- -
-
- -
-
- - - - - - - - - -
const char* theora_version_string (void  ) 
-
-
- -

Retrieve a human-readable string to identify the encoder vendor and version.

-
Returns:
A version string.
- -
-
-
- +

Detailed Description

+ + + diff --git a/doc/libtheora-1.2/index.html b/doc/libtheora-1.2/index.html index 7af4ea6ef854468180fed084d22a415d32eec722..ab7aa54a8eab6d74fca5dc28a61dd430f3d3095c 100644 --- a/doc/libtheora-1.2/index.html +++ b/doc/libtheora-1.2/index.html @@ -1,44 +1,66 @@ - + -libtheora: Main Page + + + +libtheora: libtheora - + + + - - -
-
-

libtheora Documentation

+
+
+ + + + + + +
+
libtheora 1.2.0beta1 +
+
+ + + + + + +
+
+
libtheora
+
-

1.2.0alpha1

-Introduction

-

This is the documentation for libtheora C API. The current reference implementation for Theora, a free, patent-unencumbered video codec. Theora is derived from On2's VP3 codec with additional features and integration with Ogg multimedia formats by the Xiph.Org Foundation. Complete documentation of the format itself is available in the Theora specification.

-

-Organization

-

The functions documented here are actually subdivided into three separate libraries:

-
    +

    +Introduction

    +

    This is the documentation for the libtheora C API.

    +

    The libtheora package is the current reference implementation for Theora, a free, patent-unencumbered video codec. Theora is derived from On2's VP3 codec with additional features and integration with Ogg multimedia formats by the Xiph.Org Foundation. Complete documentation of the format itself is available in the Theora specification.

    +

    +Organization

    +

    The functions documented here are divided between two separate libraries:

    -

    New code should link to libtheoradec and, if using encoder features, libtheoraenc. Together these two export both the standard and the legacy API, so this is all that is needed by any code. The older libtheora library is provided just for compatibility with older build configurations.

    -

    In general the recommended 1.x API symbols can be distinguished by their th_ or TH_ namespace prefix. The older, legacy API uses theora_ or OC_ prefixes instead.

    -
    - +

    New code should link to libtheoradec. If using encoder features, it must also link to libtheoraenc.

    +

    During initial development, prior to the 1.0 release, libtheora exported a different Legacy pre-1.0 C API which combined both encode and decode functions. In general, legacy API symbols can be indentified by their theora_ or OC_ namespace prefixes. The current API uses th_ or TH_ instead.

    +

    While deprecated, libtheoraenc and libtheoradec together export the legacy api as well at the one documented above. Likewise, the legacy libtheora included with this package exports the new 1.x API. Older code and build scripts can therefore but updated independently to the current scheme.

    +
+
+ + diff --git a/doc/libtheora-1.2/jquery.js b/doc/libtheora-1.2/jquery.js new file mode 100644 index 0000000000000000000000000000000000000000..c9ed3d99cbc898d1ab4d9bd378e55e43ad9022f5 --- /dev/null +++ b/doc/libtheora-1.2/jquery.js @@ -0,0 +1,35 @@ +/*! jQuery v3.6.0 | (c) OpenJS Foundation and other contributors | jquery.org/license */ +!function(e,t){"use strict";"object"==typeof module&&"object"==typeof module.exports?module.exports=e.document?t(e,!0):function(e){if(!e.document)throw new Error("jQuery requires a window with a document");return t(e)}:t(e)}("undefined"!=typeof window?window:this,function(C,e){"use strict";var t=[],r=Object.getPrototypeOf,s=t.slice,g=t.flat?function(e){return t.flat.call(e)}:function(e){return t.concat.apply([],e)},u=t.push,i=t.indexOf,n={},o=n.toString,v=n.hasOwnProperty,a=v.toString,l=a.call(Object),y={},m=function(e){return"function"==typeof e&&"number"!=typeof e.nodeType&&"function"!=typeof e.item},x=function(e){return null!=e&&e===e.window},E=C.document,c={type:!0,src:!0,nonce:!0,noModule:!0};function b(e,t,n){var r,i,o=(n=n||E).createElement("script");if(o.text=e,t)for(r in c)(i=t[r]||t.getAttribute&&t.getAttribute(r))&&o.setAttribute(r,i);n.head.appendChild(o).parentNode.removeChild(o)}function w(e){return null==e?e+"":"object"==typeof e||"function"==typeof e?n[o.call(e)]||"object":typeof e}var f="3.6.0",S=function(e,t){return new S.fn.init(e,t)};function p(e){var t=!!e&&"length"in e&&e.length,n=w(e);return!m(e)&&!x(e)&&("array"===n||0===t||"number"==typeof t&&0+~]|"+M+")"+M+"*"),U=new RegExp(M+"|>"),X=new RegExp(F),V=new RegExp("^"+I+"$"),G={ID:new RegExp("^#("+I+")"),CLASS:new RegExp("^\\.("+I+")"),TAG:new RegExp("^("+I+"|[*])"),ATTR:new RegExp("^"+W),PSEUDO:new RegExp("^"+F),CHILD:new RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+M+"*(even|odd|(([+-]|)(\\d*)n|)"+M+"*(?:([+-]|)"+M+"*(\\d+)|))"+M+"*\\)|)","i"),bool:new RegExp("^(?:"+R+")$","i"),needsContext:new RegExp("^"+M+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+M+"*((?:-\\d)?\\d*)"+M+"*\\)|)(?=[^-]|$)","i")},Y=/HTML$/i,Q=/^(?:input|select|textarea|button)$/i,J=/^h\d$/i,K=/^[^{]+\{\s*\[native \w/,Z=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,ee=/[+~]/,te=new RegExp("\\\\[\\da-fA-F]{1,6}"+M+"?|\\\\([^\\r\\n\\f])","g"),ne=function(e,t){var n="0x"+e.slice(1)-65536;return t||(n<0?String.fromCharCode(n+65536):String.fromCharCode(n>>10|55296,1023&n|56320))},re=/([\0-\x1f\x7f]|^-?\d)|^-$|[^\0-\x1f\x7f-\uFFFF\w-]/g,ie=function(e,t){return t?"\0"===e?"\ufffd":e.slice(0,-1)+"\\"+e.charCodeAt(e.length-1).toString(16)+" ":"\\"+e},oe=function(){T()},ae=be(function(e){return!0===e.disabled&&"fieldset"===e.nodeName.toLowerCase()},{dir:"parentNode",next:"legend"});try{H.apply(t=O.call(p.childNodes),p.childNodes),t[p.childNodes.length].nodeType}catch(e){H={apply:t.length?function(e,t){L.apply(e,O.call(t))}:function(e,t){var n=e.length,r=0;while(e[n++]=t[r++]);e.length=n-1}}}function se(t,e,n,r){var i,o,a,s,u,l,c,f=e&&e.ownerDocument,p=e?e.nodeType:9;if(n=n||[],"string"!=typeof t||!t||1!==p&&9!==p&&11!==p)return n;if(!r&&(T(e),e=e||C,E)){if(11!==p&&(u=Z.exec(t)))if(i=u[1]){if(9===p){if(!(a=e.getElementById(i)))return n;if(a.id===i)return n.push(a),n}else if(f&&(a=f.getElementById(i))&&y(e,a)&&a.id===i)return n.push(a),n}else{if(u[2])return H.apply(n,e.getElementsByTagName(t)),n;if((i=u[3])&&d.getElementsByClassName&&e.getElementsByClassName)return H.apply(n,e.getElementsByClassName(i)),n}if(d.qsa&&!N[t+" "]&&(!v||!v.test(t))&&(1!==p||"object"!==e.nodeName.toLowerCase())){if(c=t,f=e,1===p&&(U.test(t)||z.test(t))){(f=ee.test(t)&&ye(e.parentNode)||e)===e&&d.scope||((s=e.getAttribute("id"))?s=s.replace(re,ie):e.setAttribute("id",s=S)),o=(l=h(t)).length;while(o--)l[o]=(s?"#"+s:":scope")+" "+xe(l[o]);c=l.join(",")}try{return H.apply(n,f.querySelectorAll(c)),n}catch(e){N(t,!0)}finally{s===S&&e.removeAttribute("id")}}}return g(t.replace($,"$1"),e,n,r)}function ue(){var r=[];return function e(t,n){return r.push(t+" ")>b.cacheLength&&delete e[r.shift()],e[t+" "]=n}}function le(e){return e[S]=!0,e}function ce(e){var t=C.createElement("fieldset");try{return!!e(t)}catch(e){return!1}finally{t.parentNode&&t.parentNode.removeChild(t),t=null}}function fe(e,t){var n=e.split("|"),r=n.length;while(r--)b.attrHandle[n[r]]=t}function pe(e,t){var n=t&&e,r=n&&1===e.nodeType&&1===t.nodeType&&e.sourceIndex-t.sourceIndex;if(r)return r;if(n)while(n=n.nextSibling)if(n===t)return-1;return e?1:-1}function de(t){return function(e){return"input"===e.nodeName.toLowerCase()&&e.type===t}}function he(n){return function(e){var t=e.nodeName.toLowerCase();return("input"===t||"button"===t)&&e.type===n}}function ge(t){return function(e){return"form"in e?e.parentNode&&!1===e.disabled?"label"in e?"label"in e.parentNode?e.parentNode.disabled===t:e.disabled===t:e.isDisabled===t||e.isDisabled!==!t&&ae(e)===t:e.disabled===t:"label"in e&&e.disabled===t}}function ve(a){return le(function(o){return o=+o,le(function(e,t){var n,r=a([],e.length,o),i=r.length;while(i--)e[n=r[i]]&&(e[n]=!(t[n]=e[n]))})})}function ye(e){return e&&"undefined"!=typeof e.getElementsByTagName&&e}for(e in d=se.support={},i=se.isXML=function(e){var t=e&&e.namespaceURI,n=e&&(e.ownerDocument||e).documentElement;return!Y.test(t||n&&n.nodeName||"HTML")},T=se.setDocument=function(e){var t,n,r=e?e.ownerDocument||e:p;return r!=C&&9===r.nodeType&&r.documentElement&&(a=(C=r).documentElement,E=!i(C),p!=C&&(n=C.defaultView)&&n.top!==n&&(n.addEventListener?n.addEventListener("unload",oe,!1):n.attachEvent&&n.attachEvent("onunload",oe)),d.scope=ce(function(e){return a.appendChild(e).appendChild(C.createElement("div")),"undefined"!=typeof e.querySelectorAll&&!e.querySelectorAll(":scope fieldset div").length}),d.attributes=ce(function(e){return e.className="i",!e.getAttribute("className")}),d.getElementsByTagName=ce(function(e){return e.appendChild(C.createComment("")),!e.getElementsByTagName("*").length}),d.getElementsByClassName=K.test(C.getElementsByClassName),d.getById=ce(function(e){return a.appendChild(e).id=S,!C.getElementsByName||!C.getElementsByName(S).length}),d.getById?(b.filter.ID=function(e){var t=e.replace(te,ne);return function(e){return e.getAttribute("id")===t}},b.find.ID=function(e,t){if("undefined"!=typeof t.getElementById&&E){var n=t.getElementById(e);return n?[n]:[]}}):(b.filter.ID=function(e){var n=e.replace(te,ne);return function(e){var t="undefined"!=typeof e.getAttributeNode&&e.getAttributeNode("id");return t&&t.value===n}},b.find.ID=function(e,t){if("undefined"!=typeof t.getElementById&&E){var n,r,i,o=t.getElementById(e);if(o){if((n=o.getAttributeNode("id"))&&n.value===e)return[o];i=t.getElementsByName(e),r=0;while(o=i[r++])if((n=o.getAttributeNode("id"))&&n.value===e)return[o]}return[]}}),b.find.TAG=d.getElementsByTagName?function(e,t){return"undefined"!=typeof t.getElementsByTagName?t.getElementsByTagName(e):d.qsa?t.querySelectorAll(e):void 0}:function(e,t){var n,r=[],i=0,o=t.getElementsByTagName(e);if("*"===e){while(n=o[i++])1===n.nodeType&&r.push(n);return r}return o},b.find.CLASS=d.getElementsByClassName&&function(e,t){if("undefined"!=typeof t.getElementsByClassName&&E)return t.getElementsByClassName(e)},s=[],v=[],(d.qsa=K.test(C.querySelectorAll))&&(ce(function(e){var t;a.appendChild(e).innerHTML="",e.querySelectorAll("[msallowcapture^='']").length&&v.push("[*^$]="+M+"*(?:''|\"\")"),e.querySelectorAll("[selected]").length||v.push("\\["+M+"*(?:value|"+R+")"),e.querySelectorAll("[id~="+S+"-]").length||v.push("~="),(t=C.createElement("input")).setAttribute("name",""),e.appendChild(t),e.querySelectorAll("[name='']").length||v.push("\\["+M+"*name"+M+"*="+M+"*(?:''|\"\")"),e.querySelectorAll(":checked").length||v.push(":checked"),e.querySelectorAll("a#"+S+"+*").length||v.push(".#.+[+~]"),e.querySelectorAll("\\\f"),v.push("[\\r\\n\\f]")}),ce(function(e){e.innerHTML="";var t=C.createElement("input");t.setAttribute("type","hidden"),e.appendChild(t).setAttribute("name","D"),e.querySelectorAll("[name=d]").length&&v.push("name"+M+"*[*^$|!~]?="),2!==e.querySelectorAll(":enabled").length&&v.push(":enabled",":disabled"),a.appendChild(e).disabled=!0,2!==e.querySelectorAll(":disabled").length&&v.push(":enabled",":disabled"),e.querySelectorAll("*,:x"),v.push(",.*:")})),(d.matchesSelector=K.test(c=a.matches||a.webkitMatchesSelector||a.mozMatchesSelector||a.oMatchesSelector||a.msMatchesSelector))&&ce(function(e){d.disconnectedMatch=c.call(e,"*"),c.call(e,"[s!='']:x"),s.push("!=",F)}),v=v.length&&new RegExp(v.join("|")),s=s.length&&new RegExp(s.join("|")),t=K.test(a.compareDocumentPosition),y=t||K.test(a.contains)?function(e,t){var n=9===e.nodeType?e.documentElement:e,r=t&&t.parentNode;return e===r||!(!r||1!==r.nodeType||!(n.contains?n.contains(r):e.compareDocumentPosition&&16&e.compareDocumentPosition(r)))}:function(e,t){if(t)while(t=t.parentNode)if(t===e)return!0;return!1},j=t?function(e,t){if(e===t)return l=!0,0;var n=!e.compareDocumentPosition-!t.compareDocumentPosition;return n||(1&(n=(e.ownerDocument||e)==(t.ownerDocument||t)?e.compareDocumentPosition(t):1)||!d.sortDetached&&t.compareDocumentPosition(e)===n?e==C||e.ownerDocument==p&&y(p,e)?-1:t==C||t.ownerDocument==p&&y(p,t)?1:u?P(u,e)-P(u,t):0:4&n?-1:1)}:function(e,t){if(e===t)return l=!0,0;var n,r=0,i=e.parentNode,o=t.parentNode,a=[e],s=[t];if(!i||!o)return e==C?-1:t==C?1:i?-1:o?1:u?P(u,e)-P(u,t):0;if(i===o)return pe(e,t);n=e;while(n=n.parentNode)a.unshift(n);n=t;while(n=n.parentNode)s.unshift(n);while(a[r]===s[r])r++;return r?pe(a[r],s[r]):a[r]==p?-1:s[r]==p?1:0}),C},se.matches=function(e,t){return se(e,null,null,t)},se.matchesSelector=function(e,t){if(T(e),d.matchesSelector&&E&&!N[t+" "]&&(!s||!s.test(t))&&(!v||!v.test(t)))try{var n=c.call(e,t);if(n||d.disconnectedMatch||e.document&&11!==e.document.nodeType)return n}catch(e){N(t,!0)}return 0":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(e){return e[1]=e[1].replace(te,ne),e[3]=(e[3]||e[4]||e[5]||"").replace(te,ne),"~="===e[2]&&(e[3]=" "+e[3]+" "),e.slice(0,4)},CHILD:function(e){return e[1]=e[1].toLowerCase(),"nth"===e[1].slice(0,3)?(e[3]||se.error(e[0]),e[4]=+(e[4]?e[5]+(e[6]||1):2*("even"===e[3]||"odd"===e[3])),e[5]=+(e[7]+e[8]||"odd"===e[3])):e[3]&&se.error(e[0]),e},PSEUDO:function(e){var t,n=!e[6]&&e[2];return G.CHILD.test(e[0])?null:(e[3]?e[2]=e[4]||e[5]||"":n&&X.test(n)&&(t=h(n,!0))&&(t=n.indexOf(")",n.length-t)-n.length)&&(e[0]=e[0].slice(0,t),e[2]=n.slice(0,t)),e.slice(0,3))}},filter:{TAG:function(e){var t=e.replace(te,ne).toLowerCase();return"*"===e?function(){return!0}:function(e){return e.nodeName&&e.nodeName.toLowerCase()===t}},CLASS:function(e){var t=m[e+" "];return t||(t=new RegExp("(^|"+M+")"+e+"("+M+"|$)"))&&m(e,function(e){return t.test("string"==typeof e.className&&e.className||"undefined"!=typeof e.getAttribute&&e.getAttribute("class")||"")})},ATTR:function(n,r,i){return function(e){var t=se.attr(e,n);return null==t?"!="===r:!r||(t+="","="===r?t===i:"!="===r?t!==i:"^="===r?i&&0===t.indexOf(i):"*="===r?i&&-1:\x20\t\r\n\f]*)[\x20\t\r\n\f]*\/?>(?:<\/\1>|)$/i;function j(e,n,r){return m(n)?S.grep(e,function(e,t){return!!n.call(e,t,e)!==r}):n.nodeType?S.grep(e,function(e){return e===n!==r}):"string"!=typeof n?S.grep(e,function(e){return-1)[^>]*|#([\w-]+))$/;(S.fn.init=function(e,t,n){var r,i;if(!e)return this;if(n=n||D,"string"==typeof e){if(!(r="<"===e[0]&&">"===e[e.length-1]&&3<=e.length?[null,e,null]:q.exec(e))||!r[1]&&t)return!t||t.jquery?(t||n).find(e):this.constructor(t).find(e);if(r[1]){if(t=t instanceof S?t[0]:t,S.merge(this,S.parseHTML(r[1],t&&t.nodeType?t.ownerDocument||t:E,!0)),N.test(r[1])&&S.isPlainObject(t))for(r in t)m(this[r])?this[r](t[r]):this.attr(r,t[r]);return this}return(i=E.getElementById(r[2]))&&(this[0]=i,this.length=1),this}return e.nodeType?(this[0]=e,this.length=1,this):m(e)?void 0!==n.ready?n.ready(e):e(S):S.makeArray(e,this)}).prototype=S.fn,D=S(E);var L=/^(?:parents|prev(?:Until|All))/,H={children:!0,contents:!0,next:!0,prev:!0};function O(e,t){while((e=e[t])&&1!==e.nodeType);return e}S.fn.extend({has:function(e){var t=S(e,this),n=t.length;return this.filter(function(){for(var e=0;e\x20\t\r\n\f]*)/i,he=/^$|^module$|\/(?:java|ecma)script/i;ce=E.createDocumentFragment().appendChild(E.createElement("div")),(fe=E.createElement("input")).setAttribute("type","radio"),fe.setAttribute("checked","checked"),fe.setAttribute("name","t"),ce.appendChild(fe),y.checkClone=ce.cloneNode(!0).cloneNode(!0).lastChild.checked,ce.innerHTML="",y.noCloneChecked=!!ce.cloneNode(!0).lastChild.defaultValue,ce.innerHTML="",y.option=!!ce.lastChild;var ge={thead:[1,"","
"],col:[2,"","
"],tr:[2,"","
"],td:[3,"","
"],_default:[0,"",""]};function ve(e,t){var n;return n="undefined"!=typeof e.getElementsByTagName?e.getElementsByTagName(t||"*"):"undefined"!=typeof e.querySelectorAll?e.querySelectorAll(t||"*"):[],void 0===t||t&&A(e,t)?S.merge([e],n):n}function ye(e,t){for(var n=0,r=e.length;n",""]);var me=/<|&#?\w+;/;function xe(e,t,n,r,i){for(var o,a,s,u,l,c,f=t.createDocumentFragment(),p=[],d=0,h=e.length;d\s*$/g;function je(e,t){return A(e,"table")&&A(11!==t.nodeType?t:t.firstChild,"tr")&&S(e).children("tbody")[0]||e}function De(e){return e.type=(null!==e.getAttribute("type"))+"/"+e.type,e}function qe(e){return"true/"===(e.type||"").slice(0,5)?e.type=e.type.slice(5):e.removeAttribute("type"),e}function Le(e,t){var n,r,i,o,a,s;if(1===t.nodeType){if(Y.hasData(e)&&(s=Y.get(e).events))for(i in Y.remove(t,"handle events"),s)for(n=0,r=s[i].length;n").attr(n.scriptAttrs||{}).prop({charset:n.scriptCharset,src:n.url}).on("load error",i=function(e){r.remove(),i=null,e&&t("error"===e.type?404:200,e.type)}),E.head.appendChild(r[0])},abort:function(){i&&i()}}});var _t,zt=[],Ut=/(=)\?(?=&|$)|\?\?/;S.ajaxSetup({jsonp:"callback",jsonpCallback:function(){var e=zt.pop()||S.expando+"_"+wt.guid++;return this[e]=!0,e}}),S.ajaxPrefilter("json jsonp",function(e,t,n){var r,i,o,a=!1!==e.jsonp&&(Ut.test(e.url)?"url":"string"==typeof e.data&&0===(e.contentType||"").indexOf("application/x-www-form-urlencoded")&&Ut.test(e.data)&&"data");if(a||"jsonp"===e.dataTypes[0])return r=e.jsonpCallback=m(e.jsonpCallback)?e.jsonpCallback():e.jsonpCallback,a?e[a]=e[a].replace(Ut,"$1"+r):!1!==e.jsonp&&(e.url+=(Tt.test(e.url)?"&":"?")+e.jsonp+"="+r),e.converters["script json"]=function(){return o||S.error(r+" was not called"),o[0]},e.dataTypes[0]="json",i=C[r],C[r]=function(){o=arguments},n.always(function(){void 0===i?S(C).removeProp(r):C[r]=i,e[r]&&(e.jsonpCallback=t.jsonpCallback,zt.push(r)),o&&m(i)&&i(o[0]),o=i=void 0}),"script"}),y.createHTMLDocument=((_t=E.implementation.createHTMLDocument("").body).innerHTML="
",2===_t.childNodes.length),S.parseHTML=function(e,t,n){return"string"!=typeof e?[]:("boolean"==typeof t&&(n=t,t=!1),t||(y.createHTMLDocument?((r=(t=E.implementation.createHTMLDocument("")).createElement("base")).href=E.location.href,t.head.appendChild(r)):t=E),o=!n&&[],(i=N.exec(e))?[t.createElement(i[1])]:(i=xe([e],t,o),o&&o.length&&S(o).remove(),S.merge([],i.childNodes)));var r,i,o},S.fn.load=function(e,t,n){var r,i,o,a=this,s=e.indexOf(" ");return-1").append(S.parseHTML(e)).find(r):e)}).always(n&&function(e,t){a.each(function(){n.apply(this,o||[e.responseText,t,e])})}),this},S.expr.pseudos.animated=function(t){return S.grep(S.timers,function(e){return t===e.elem}).length},S.offset={setOffset:function(e,t,n){var r,i,o,a,s,u,l=S.css(e,"position"),c=S(e),f={};"static"===l&&(e.style.position="relative"),s=c.offset(),o=S.css(e,"top"),u=S.css(e,"left"),("absolute"===l||"fixed"===l)&&-1<(o+u).indexOf("auto")?(a=(r=c.position()).top,i=r.left):(a=parseFloat(o)||0,i=parseFloat(u)||0),m(t)&&(t=t.call(e,n,S.extend({},s))),null!=t.top&&(f.top=t.top-s.top+a),null!=t.left&&(f.left=t.left-s.left+i),"using"in t?t.using.call(e,f):c.css(f)}},S.fn.extend({offset:function(t){if(arguments.length)return void 0===t?this:this.each(function(e){S.offset.setOffset(this,t,e)});var e,n,r=this[0];return r?r.getClientRects().length?(e=r.getBoundingClientRect(),n=r.ownerDocument.defaultView,{top:e.top+n.pageYOffset,left:e.left+n.pageXOffset}):{top:0,left:0}:void 0},position:function(){if(this[0]){var e,t,n,r=this[0],i={top:0,left:0};if("fixed"===S.css(r,"position"))t=r.getBoundingClientRect();else{t=this.offset(),n=r.ownerDocument,e=r.offsetParent||n.documentElement;while(e&&(e===n.body||e===n.documentElement)&&"static"===S.css(e,"position"))e=e.parentNode;e&&e!==r&&1===e.nodeType&&((i=S(e).offset()).top+=S.css(e,"borderTopWidth",!0),i.left+=S.css(e,"borderLeftWidth",!0))}return{top:t.top-i.top-S.css(r,"marginTop",!0),left:t.left-i.left-S.css(r,"marginLeft",!0)}}},offsetParent:function(){return this.map(function(){var e=this.offsetParent;while(e&&"static"===S.css(e,"position"))e=e.offsetParent;return e||re})}}),S.each({scrollLeft:"pageXOffset",scrollTop:"pageYOffset"},function(t,i){var o="pageYOffset"===i;S.fn[t]=function(e){return $(this,function(e,t,n){var r;if(x(e)?r=e:9===e.nodeType&&(r=e.defaultView),void 0===n)return r?r[i]:e[t];r?r.scrollTo(o?r.pageXOffset:n,o?n:r.pageYOffset):e[t]=n},t,e,arguments.length)}}),S.each(["top","left"],function(e,n){S.cssHooks[n]=Fe(y.pixelPosition,function(e,t){if(t)return t=We(e,n),Pe.test(t)?S(e).position()[n]+"px":t})}),S.each({Height:"height",Width:"width"},function(a,s){S.each({padding:"inner"+a,content:s,"":"outer"+a},function(r,o){S.fn[o]=function(e,t){var n=arguments.length&&(r||"boolean"!=typeof e),i=r||(!0===e||!0===t?"margin":"border");return $(this,function(e,t,n){var r;return x(e)?0===o.indexOf("outer")?e["inner"+a]:e.document.documentElement["client"+a]:9===e.nodeType?(r=e.documentElement,Math.max(e.body["scroll"+a],r["scroll"+a],e.body["offset"+a],r["offset"+a],r["client"+a])):void 0===n?S.css(e,t,i):S.style(e,t,n,i)},s,n?e:void 0,n)}})}),S.each(["ajaxStart","ajaxStop","ajaxComplete","ajaxError","ajaxSuccess","ajaxSend"],function(e,t){S.fn[t]=function(e){return this.on(t,e)}}),S.fn.extend({bind:function(e,t,n){return this.on(e,null,t,n)},unbind:function(e,t){return this.off(e,null,t)},delegate:function(e,t,n,r){return this.on(t,e,n,r)},undelegate:function(e,t,n){return 1===arguments.length?this.off(e,"**"):this.off(t,e||"**",n)},hover:function(e,t){return this.mouseenter(e).mouseleave(t||e)}}),S.each("blur focus focusin focusout resize scroll click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select submit keydown keypress keyup contextmenu".split(" "),function(e,n){S.fn[n]=function(e,t){return 0a;a++)for(i in o[a])n=o[a][i],o[a].hasOwnProperty(i)&&void 0!==n&&(e[i]=t.isPlainObject(n)?t.isPlainObject(e[i])?t.widget.extend({},e[i],n):t.widget.extend({},n):n);return e},t.widget.bridge=function(e,i){var n=i.prototype.widgetFullName||e;t.fn[e]=function(o){var a="string"==typeof o,r=s.call(arguments,1),h=this;return a?this.length||"instance"!==o?this.each(function(){var i,s=t.data(this,n);return"instance"===o?(h=s,!1):s?t.isFunction(s[o])&&"_"!==o.charAt(0)?(i=s[o].apply(s,r),i!==s&&void 0!==i?(h=i&&i.jquery?h.pushStack(i.get()):i,!1):void 0):t.error("no such method '"+o+"' for "+e+" widget instance"):t.error("cannot call methods on "+e+" prior to initialization; "+"attempted to call method '"+o+"'")}):h=void 0:(r.length&&(o=t.widget.extend.apply(null,[o].concat(r))),this.each(function(){var e=t.data(this,n);e?(e.option(o||{}),e._init&&e._init()):t.data(this,n,new i(o,this))})),h}},t.Widget=function(){},t.Widget._childConstructors=[],t.Widget.prototype={widgetName:"widget",widgetEventPrefix:"",defaultElement:"
",options:{classes:{},disabled:!1,create:null},_createWidget:function(e,s){s=t(s||this.defaultElement||this)[0],this.element=t(s),this.uuid=i++,this.eventNamespace="."+this.widgetName+this.uuid,this.bindings=t(),this.hoverable=t(),this.focusable=t(),this.classesElementLookup={},s!==this&&(t.data(s,this.widgetFullName,this),this._on(!0,this.element,{remove:function(t){t.target===s&&this.destroy()}}),this.document=t(s.style?s.ownerDocument:s.document||s),this.window=t(this.document[0].defaultView||this.document[0].parentWindow)),this.options=t.widget.extend({},this.options,this._getCreateOptions(),e),this._create(),this.options.disabled&&this._setOptionDisabled(this.options.disabled),this._trigger("create",null,this._getCreateEventData()),this._init()},_getCreateOptions:function(){return{}},_getCreateEventData:t.noop,_create:t.noop,_init:t.noop,destroy:function(){var e=this;this._destroy(),t.each(this.classesElementLookup,function(t,i){e._removeClass(i,t)}),this.element.off(this.eventNamespace).removeData(this.widgetFullName),this.widget().off(this.eventNamespace).removeAttr("aria-disabled"),this.bindings.off(this.eventNamespace)},_destroy:t.noop,widget:function(){return this.element},option:function(e,i){var s,n,o,a=e;if(0===arguments.length)return t.widget.extend({},this.options);if("string"==typeof e)if(a={},s=e.split("."),e=s.shift(),s.length){for(n=a[e]=t.widget.extend({},this.options[e]),o=0;s.length-1>o;o++)n[s[o]]=n[s[o]]||{},n=n[s[o]];if(e=s.pop(),1===arguments.length)return void 0===n[e]?null:n[e];n[e]=i}else{if(1===arguments.length)return void 0===this.options[e]?null:this.options[e];a[e]=i}return this._setOptions(a),this},_setOptions:function(t){var e;for(e in t)this._setOption(e,t[e]);return this},_setOption:function(t,e){return"classes"===t&&this._setOptionClasses(e),this.options[t]=e,"disabled"===t&&this._setOptionDisabled(e),this},_setOptionClasses:function(e){var i,s,n;for(i in e)n=this.classesElementLookup[i],e[i]!==this.options.classes[i]&&n&&n.length&&(s=t(n.get()),this._removeClass(n,i),s.addClass(this._classes({element:s,keys:i,classes:e,add:!0})))},_setOptionDisabled:function(t){this._toggleClass(this.widget(),this.widgetFullName+"-disabled",null,!!t),t&&(this._removeClass(this.hoverable,null,"ui-state-hover"),this._removeClass(this.focusable,null,"ui-state-focus"))},enable:function(){return this._setOptions({disabled:!1})},disable:function(){return this._setOptions({disabled:!0})},_classes:function(e){function i(i,o){var a,r;for(r=0;i.length>r;r++)a=n.classesElementLookup[i[r]]||t(),a=e.add?t(t.unique(a.get().concat(e.element.get()))):t(a.not(e.element).get()),n.classesElementLookup[i[r]]=a,s.push(i[r]),o&&e.classes[i[r]]&&s.push(e.classes[i[r]])}var s=[],n=this;return e=t.extend({element:this.element,classes:this.options.classes||{}},e),this._on(e.element,{remove:"_untrackClassesElement"}),e.keys&&i(e.keys.match(/\S+/g)||[],!0),e.extra&&i(e.extra.match(/\S+/g)||[]),s.join(" ")},_untrackClassesElement:function(e){var i=this;t.each(i.classesElementLookup,function(s,n){-1!==t.inArray(e.target,n)&&(i.classesElementLookup[s]=t(n.not(e.target).get()))})},_removeClass:function(t,e,i){return this._toggleClass(t,e,i,!1)},_addClass:function(t,e,i){return this._toggleClass(t,e,i,!0)},_toggleClass:function(t,e,i,s){s="boolean"==typeof s?s:i;var n="string"==typeof t||null===t,o={extra:n?e:i,keys:n?t:e,element:n?this.element:t,add:s};return o.element.toggleClass(this._classes(o),s),this},_on:function(e,i,s){var n,o=this;"boolean"!=typeof e&&(s=i,i=e,e=!1),s?(i=n=t(i),this.bindings=this.bindings.add(i)):(s=i,i=this.element,n=this.widget()),t.each(s,function(s,a){function r(){return e||o.options.disabled!==!0&&!t(this).hasClass("ui-state-disabled")?("string"==typeof a?o[a]:a).apply(o,arguments):void 0}"string"!=typeof a&&(r.guid=a.guid=a.guid||r.guid||t.guid++);var h=s.match(/^([\w:-]*)\s*(.*)$/),l=h[1]+o.eventNamespace,c=h[2];c?n.on(l,c,r):i.on(l,r)})},_off:function(e,i){i=(i||"").split(" ").join(this.eventNamespace+" ")+this.eventNamespace,e.off(i).off(i),this.bindings=t(this.bindings.not(e).get()),this.focusable=t(this.focusable.not(e).get()),this.hoverable=t(this.hoverable.not(e).get())},_delay:function(t,e){function i(){return("string"==typeof t?s[t]:t).apply(s,arguments)}var s=this;return setTimeout(i,e||0)},_hoverable:function(e){this.hoverable=this.hoverable.add(e),this._on(e,{mouseenter:function(e){this._addClass(t(e.currentTarget),null,"ui-state-hover")},mouseleave:function(e){this._removeClass(t(e.currentTarget),null,"ui-state-hover")}})},_focusable:function(e){this.focusable=this.focusable.add(e),this._on(e,{focusin:function(e){this._addClass(t(e.currentTarget),null,"ui-state-focus")},focusout:function(e){this._removeClass(t(e.currentTarget),null,"ui-state-focus")}})},_trigger:function(e,i,s){var n,o,a=this.options[e];if(s=s||{},i=t.Event(i),i.type=(e===this.widgetEventPrefix?e:this.widgetEventPrefix+e).toLowerCase(),i.target=this.element[0],o=i.originalEvent)for(n in o)n in i||(i[n]=o[n]);return this.element.trigger(i,s),!(t.isFunction(a)&&a.apply(this.element[0],[i].concat(s))===!1||i.isDefaultPrevented())}},t.each({show:"fadeIn",hide:"fadeOut"},function(e,i){t.Widget.prototype["_"+e]=function(s,n,o){"string"==typeof n&&(n={effect:n});var a,r=n?n===!0||"number"==typeof n?i:n.effect||i:e;n=n||{},"number"==typeof n&&(n={duration:n}),a=!t.isEmptyObject(n),n.complete=o,n.delay&&s.delay(n.delay),a&&t.effects&&t.effects.effect[r]?s[e](n):r!==e&&s[r]?s[r](n.duration,n.easing,o):s.queue(function(i){t(this)[e](),o&&o.call(s[0]),i()})}}),t.widget,function(){function e(t,e,i){return[parseFloat(t[0])*(u.test(t[0])?e/100:1),parseFloat(t[1])*(u.test(t[1])?i/100:1)]}function i(e,i){return parseInt(t.css(e,i),10)||0}function s(e){var i=e[0];return 9===i.nodeType?{width:e.width(),height:e.height(),offset:{top:0,left:0}}:t.isWindow(i)?{width:e.width(),height:e.height(),offset:{top:e.scrollTop(),left:e.scrollLeft()}}:i.preventDefault?{width:0,height:0,offset:{top:i.pageY,left:i.pageX}}:{width:e.outerWidth(),height:e.outerHeight(),offset:e.offset()}}var n,o=Math.max,a=Math.abs,r=/left|center|right/,h=/top|center|bottom/,l=/[\+\-]\d+(\.[\d]+)?%?/,c=/^\w+/,u=/%$/,d=t.fn.position;t.position={scrollbarWidth:function(){if(void 0!==n)return n;var e,i,s=t("
"),o=s.children()[0];return t("body").append(s),e=o.offsetWidth,s.css("overflow","scroll"),i=o.offsetWidth,e===i&&(i=s[0].clientWidth),s.remove(),n=e-i},getScrollInfo:function(e){var i=e.isWindow||e.isDocument?"":e.element.css("overflow-x"),s=e.isWindow||e.isDocument?"":e.element.css("overflow-y"),n="scroll"===i||"auto"===i&&e.widthi?"left":e>0?"right":"center",vertical:0>r?"top":s>0?"bottom":"middle"};l>p&&p>a(e+i)&&(u.horizontal="center"),c>f&&f>a(s+r)&&(u.vertical="middle"),u.important=o(a(e),a(i))>o(a(s),a(r))?"horizontal":"vertical",n.using.call(this,t,u)}),h.offset(t.extend(D,{using:r}))})},t.ui.position={fit:{left:function(t,e){var i,s=e.within,n=s.isWindow?s.scrollLeft:s.offset.left,a=s.width,r=t.left-e.collisionPosition.marginLeft,h=n-r,l=r+e.collisionWidth-a-n;e.collisionWidth>a?h>0&&0>=l?(i=t.left+h+e.collisionWidth-a-n,t.left+=h-i):t.left=l>0&&0>=h?n:h>l?n+a-e.collisionWidth:n:h>0?t.left+=h:l>0?t.left-=l:t.left=o(t.left-r,t.left)},top:function(t,e){var i,s=e.within,n=s.isWindow?s.scrollTop:s.offset.top,a=e.within.height,r=t.top-e.collisionPosition.marginTop,h=n-r,l=r+e.collisionHeight-a-n;e.collisionHeight>a?h>0&&0>=l?(i=t.top+h+e.collisionHeight-a-n,t.top+=h-i):t.top=l>0&&0>=h?n:h>l?n+a-e.collisionHeight:n:h>0?t.top+=h:l>0?t.top-=l:t.top=o(t.top-r,t.top)}},flip:{left:function(t,e){var i,s,n=e.within,o=n.offset.left+n.scrollLeft,r=n.width,h=n.isWindow?n.scrollLeft:n.offset.left,l=t.left-e.collisionPosition.marginLeft,c=l-h,u=l+e.collisionWidth-r-h,d="left"===e.my[0]?-e.elemWidth:"right"===e.my[0]?e.elemWidth:0,p="left"===e.at[0]?e.targetWidth:"right"===e.at[0]?-e.targetWidth:0,f=-2*e.offset[0];0>c?(i=t.left+d+p+f+e.collisionWidth-r-o,(0>i||a(c)>i)&&(t.left+=d+p+f)):u>0&&(s=t.left-e.collisionPosition.marginLeft+d+p+f-h,(s>0||u>a(s))&&(t.left+=d+p+f))},top:function(t,e){var i,s,n=e.within,o=n.offset.top+n.scrollTop,r=n.height,h=n.isWindow?n.scrollTop:n.offset.top,l=t.top-e.collisionPosition.marginTop,c=l-h,u=l+e.collisionHeight-r-h,d="top"===e.my[1],p=d?-e.elemHeight:"bottom"===e.my[1]?e.elemHeight:0,f="top"===e.at[1]?e.targetHeight:"bottom"===e.at[1]?-e.targetHeight:0,m=-2*e.offset[1];0>c?(s=t.top+p+f+m+e.collisionHeight-r-o,(0>s||a(c)>s)&&(t.top+=p+f+m)):u>0&&(i=t.top-e.collisionPosition.marginTop+p+f+m-h,(i>0||u>a(i))&&(t.top+=p+f+m))}},flipfit:{left:function(){t.ui.position.flip.left.apply(this,arguments),t.ui.position.fit.left.apply(this,arguments)},top:function(){t.ui.position.flip.top.apply(this,arguments),t.ui.position.fit.top.apply(this,arguments)}}}}(),t.ui.position,t.extend(t.expr[":"],{data:t.expr.createPseudo?t.expr.createPseudo(function(e){return function(i){return!!t.data(i,e)}}):function(e,i,s){return!!t.data(e,s[3])}}),t.fn.extend({disableSelection:function(){var t="onselectstart"in document.createElement("div")?"selectstart":"mousedown";return function(){return this.on(t+".ui-disableSelection",function(t){t.preventDefault()})}}(),enableSelection:function(){return this.off(".ui-disableSelection")}}),t.ui.focusable=function(i,s){var n,o,a,r,h,l=i.nodeName.toLowerCase();return"area"===l?(n=i.parentNode,o=n.name,i.href&&o&&"map"===n.nodeName.toLowerCase()?(a=t("img[usemap='#"+o+"']"),a.length>0&&a.is(":visible")):!1):(/^(input|select|textarea|button|object)$/.test(l)?(r=!i.disabled,r&&(h=t(i).closest("fieldset")[0],h&&(r=!h.disabled))):r="a"===l?i.href||s:s,r&&t(i).is(":visible")&&e(t(i)))},t.extend(t.expr[":"],{focusable:function(e){return t.ui.focusable(e,null!=t.attr(e,"tabindex"))}}),t.ui.focusable,t.fn.form=function(){return"string"==typeof this[0].form?this.closest("form"):t(this[0].form)},t.ui.formResetMixin={_formResetHandler:function(){var e=t(this);setTimeout(function(){var i=e.data("ui-form-reset-instances");t.each(i,function(){this.refresh()})})},_bindFormResetHandler:function(){if(this.form=this.element.form(),this.form.length){var t=this.form.data("ui-form-reset-instances")||[];t.length||this.form.on("reset.ui-form-reset",this._formResetHandler),t.push(this),this.form.data("ui-form-reset-instances",t)}},_unbindFormResetHandler:function(){if(this.form.length){var e=this.form.data("ui-form-reset-instances");e.splice(t.inArray(this,e),1),e.length?this.form.data("ui-form-reset-instances",e):this.form.removeData("ui-form-reset-instances").off("reset.ui-form-reset")}}},"1.7"===t.fn.jquery.substring(0,3)&&(t.each(["Width","Height"],function(e,i){function s(e,i,s,o){return t.each(n,function(){i-=parseFloat(t.css(e,"padding"+this))||0,s&&(i-=parseFloat(t.css(e,"border"+this+"Width"))||0),o&&(i-=parseFloat(t.css(e,"margin"+this))||0)}),i}var n="Width"===i?["Left","Right"]:["Top","Bottom"],o=i.toLowerCase(),a={innerWidth:t.fn.innerWidth,innerHeight:t.fn.innerHeight,outerWidth:t.fn.outerWidth,outerHeight:t.fn.outerHeight};t.fn["inner"+i]=function(e){return void 0===e?a["inner"+i].call(this):this.each(function(){t(this).css(o,s(this,e)+"px")})},t.fn["outer"+i]=function(e,n){return"number"!=typeof e?a["outer"+i].call(this,e):this.each(function(){t(this).css(o,s(this,e,!0,n)+"px")})}}),t.fn.addBack=function(t){return this.add(null==t?this.prevObject:this.prevObject.filter(t))}),t.ui.keyCode={BACKSPACE:8,COMMA:188,DELETE:46,DOWN:40,END:35,ENTER:13,ESCAPE:27,HOME:36,LEFT:37,PAGE_DOWN:34,PAGE_UP:33,PERIOD:190,RIGHT:39,SPACE:32,TAB:9,UP:38},t.ui.escapeSelector=function(){var t=/([!"#$%&'()*+,./:;<=>?@[\]^`{|}~])/g;return function(e){return e.replace(t,"\\$1")}}(),t.fn.labels=function(){var e,i,s,n,o;return this[0].labels&&this[0].labels.length?this.pushStack(this[0].labels):(n=this.eq(0).parents("label"),s=this.attr("id"),s&&(e=this.eq(0).parents().last(),o=e.add(e.length?e.siblings():this.siblings()),i="label[for='"+t.ui.escapeSelector(s)+"']",n=n.add(o.find(i).addBack(i))),this.pushStack(n))},t.fn.scrollParent=function(e){var i=this.css("position"),s="absolute"===i,n=e?/(auto|scroll|hidden)/:/(auto|scroll)/,o=this.parents().filter(function(){var e=t(this);return s&&"static"===e.css("position")?!1:n.test(e.css("overflow")+e.css("overflow-y")+e.css("overflow-x"))}).eq(0);return"fixed"!==i&&o.length?o:t(this[0].ownerDocument||document)},t.extend(t.expr[":"],{tabbable:function(e){var i=t.attr(e,"tabindex"),s=null!=i;return(!s||i>=0)&&t.ui.focusable(e,s)}}),t.fn.extend({uniqueId:function(){var t=0;return function(){return this.each(function(){this.id||(this.id="ui-id-"+ ++t)})}}(),removeUniqueId:function(){return this.each(function(){/^ui-id-\d+$/.test(this.id)&&t(this).removeAttr("id")})}}),t.ui.ie=!!/msie [\w.]+/.exec(navigator.userAgent.toLowerCase());var n=!1;t(document).on("mouseup",function(){n=!1}),t.widget("ui.mouse",{version:"1.12.1",options:{cancel:"input, textarea, button, select, option",distance:1,delay:0},_mouseInit:function(){var e=this;this.element.on("mousedown."+this.widgetName,function(t){return e._mouseDown(t)}).on("click."+this.widgetName,function(i){return!0===t.data(i.target,e.widgetName+".preventClickEvent")?(t.removeData(i.target,e.widgetName+".preventClickEvent"),i.stopImmediatePropagation(),!1):void 0}),this.started=!1},_mouseDestroy:function(){this.element.off("."+this.widgetName),this._mouseMoveDelegate&&this.document.off("mousemove."+this.widgetName,this._mouseMoveDelegate).off("mouseup."+this.widgetName,this._mouseUpDelegate)},_mouseDown:function(e){if(!n){this._mouseMoved=!1,this._mouseStarted&&this._mouseUp(e),this._mouseDownEvent=e;var i=this,s=1===e.which,o="string"==typeof this.options.cancel&&e.target.nodeName?t(e.target).closest(this.options.cancel).length:!1;return s&&!o&&this._mouseCapture(e)?(this.mouseDelayMet=!this.options.delay,this.mouseDelayMet||(this._mouseDelayTimer=setTimeout(function(){i.mouseDelayMet=!0},this.options.delay)),this._mouseDistanceMet(e)&&this._mouseDelayMet(e)&&(this._mouseStarted=this._mouseStart(e)!==!1,!this._mouseStarted)?(e.preventDefault(),!0):(!0===t.data(e.target,this.widgetName+".preventClickEvent")&&t.removeData(e.target,this.widgetName+".preventClickEvent"),this._mouseMoveDelegate=function(t){return i._mouseMove(t)},this._mouseUpDelegate=function(t){return i._mouseUp(t)},this.document.on("mousemove."+this.widgetName,this._mouseMoveDelegate).on("mouseup."+this.widgetName,this._mouseUpDelegate),e.preventDefault(),n=!0,!0)):!0}},_mouseMove:function(e){if(this._mouseMoved){if(t.ui.ie&&(!document.documentMode||9>document.documentMode)&&!e.button)return this._mouseUp(e);if(!e.which)if(e.originalEvent.altKey||e.originalEvent.ctrlKey||e.originalEvent.metaKey||e.originalEvent.shiftKey)this.ignoreMissingWhich=!0;else if(!this.ignoreMissingWhich)return this._mouseUp(e)}return(e.which||e.button)&&(this._mouseMoved=!0),this._mouseStarted?(this._mouseDrag(e),e.preventDefault()):(this._mouseDistanceMet(e)&&this._mouseDelayMet(e)&&(this._mouseStarted=this._mouseStart(this._mouseDownEvent,e)!==!1,this._mouseStarted?this._mouseDrag(e):this._mouseUp(e)),!this._mouseStarted)},_mouseUp:function(e){this.document.off("mousemove."+this.widgetName,this._mouseMoveDelegate).off("mouseup."+this.widgetName,this._mouseUpDelegate),this._mouseStarted&&(this._mouseStarted=!1,e.target===this._mouseDownEvent.target&&t.data(e.target,this.widgetName+".preventClickEvent",!0),this._mouseStop(e)),this._mouseDelayTimer&&(clearTimeout(this._mouseDelayTimer),delete this._mouseDelayTimer),this.ignoreMissingWhich=!1,n=!1,e.preventDefault()},_mouseDistanceMet:function(t){return Math.max(Math.abs(this._mouseDownEvent.pageX-t.pageX),Math.abs(this._mouseDownEvent.pageY-t.pageY))>=this.options.distance},_mouseDelayMet:function(){return this.mouseDelayMet},_mouseStart:function(){},_mouseDrag:function(){},_mouseStop:function(){},_mouseCapture:function(){return!0}}),t.ui.plugin={add:function(e,i,s){var n,o=t.ui[e].prototype;for(n in s)o.plugins[n]=o.plugins[n]||[],o.plugins[n].push([i,s[n]])},call:function(t,e,i,s){var n,o=t.plugins[e];if(o&&(s||t.element[0].parentNode&&11!==t.element[0].parentNode.nodeType))for(n=0;o.length>n;n++)t.options[o[n][0]]&&o[n][1].apply(t.element,i)}},t.widget("ui.resizable",t.ui.mouse,{version:"1.12.1",widgetEventPrefix:"resize",options:{alsoResize:!1,animate:!1,animateDuration:"slow",animateEasing:"swing",aspectRatio:!1,autoHide:!1,classes:{"ui-resizable-se":"ui-icon ui-icon-gripsmall-diagonal-se"},containment:!1,ghost:!1,grid:!1,handles:"e,s,se",helper:!1,maxHeight:null,maxWidth:null,minHeight:10,minWidth:10,zIndex:90,resize:null,start:null,stop:null},_num:function(t){return parseFloat(t)||0},_isNumber:function(t){return!isNaN(parseFloat(t))},_hasScroll:function(e,i){if("hidden"===t(e).css("overflow"))return!1;var s=i&&"left"===i?"scrollLeft":"scrollTop",n=!1;return e[s]>0?!0:(e[s]=1,n=e[s]>0,e[s]=0,n)},_create:function(){var e,i=this.options,s=this;this._addClass("ui-resizable"),t.extend(this,{_aspectRatio:!!i.aspectRatio,aspectRatio:i.aspectRatio,originalElement:this.element,_proportionallyResizeElements:[],_helper:i.helper||i.ghost||i.animate?i.helper||"ui-resizable-helper":null}),this.element[0].nodeName.match(/^(canvas|textarea|input|select|button|img)$/i)&&(this.element.wrap(t("
").css({position:this.element.css("position"),width:this.element.outerWidth(),height:this.element.outerHeight(),top:this.element.css("top"),left:this.element.css("left")})),this.element=this.element.parent().data("ui-resizable",this.element.resizable("instance")),this.elementIsWrapper=!0,e={marginTop:this.originalElement.css("marginTop"),marginRight:this.originalElement.css("marginRight"),marginBottom:this.originalElement.css("marginBottom"),marginLeft:this.originalElement.css("marginLeft")},this.element.css(e),this.originalElement.css("margin",0),this.originalResizeStyle=this.originalElement.css("resize"),this.originalElement.css("resize","none"),this._proportionallyResizeElements.push(this.originalElement.css({position:"static",zoom:1,display:"block"})),this.originalElement.css(e),this._proportionallyResize()),this._setupHandles(),i.autoHide&&t(this.element).on("mouseenter",function(){i.disabled||(s._removeClass("ui-resizable-autohide"),s._handles.show())}).on("mouseleave",function(){i.disabled||s.resizing||(s._addClass("ui-resizable-autohide"),s._handles.hide())}),this._mouseInit()},_destroy:function(){this._mouseDestroy();var e,i=function(e){t(e).removeData("resizable").removeData("ui-resizable").off(".resizable").find(".ui-resizable-handle").remove()};return this.elementIsWrapper&&(i(this.element),e=this.element,this.originalElement.css({position:e.css("position"),width:e.outerWidth(),height:e.outerHeight(),top:e.css("top"),left:e.css("left")}).insertAfter(e),e.remove()),this.originalElement.css("resize",this.originalResizeStyle),i(this.originalElement),this},_setOption:function(t,e){switch(this._super(t,e),t){case"handles":this._removeHandles(),this._setupHandles();break;default:}},_setupHandles:function(){var e,i,s,n,o,a=this.options,r=this;if(this.handles=a.handles||(t(".ui-resizable-handle",this.element).length?{n:".ui-resizable-n",e:".ui-resizable-e",s:".ui-resizable-s",w:".ui-resizable-w",se:".ui-resizable-se",sw:".ui-resizable-sw",ne:".ui-resizable-ne",nw:".ui-resizable-nw"}:"e,s,se"),this._handles=t(),this.handles.constructor===String)for("all"===this.handles&&(this.handles="n,e,s,w,se,sw,ne,nw"),s=this.handles.split(","),this.handles={},i=0;s.length>i;i++)e=t.trim(s[i]),n="ui-resizable-"+e,o=t("
"),this._addClass(o,"ui-resizable-handle "+n),o.css({zIndex:a.zIndex}),this.handles[e]=".ui-resizable-"+e,this.element.append(o);this._renderAxis=function(e){var i,s,n,o;e=e||this.element;for(i in this.handles)this.handles[i].constructor===String?this.handles[i]=this.element.children(this.handles[i]).first().show():(this.handles[i].jquery||this.handles[i].nodeType)&&(this.handles[i]=t(this.handles[i]),this._on(this.handles[i],{mousedown:r._mouseDown})),this.elementIsWrapper&&this.originalElement[0].nodeName.match(/^(textarea|input|select|button)$/i)&&(s=t(this.handles[i],this.element),o=/sw|ne|nw|se|n|s/.test(i)?s.outerHeight():s.outerWidth(),n=["padding",/ne|nw|n/.test(i)?"Top":/se|sw|s/.test(i)?"Bottom":/^e$/.test(i)?"Right":"Left"].join(""),e.css(n,o),this._proportionallyResize()),this._handles=this._handles.add(this.handles[i])},this._renderAxis(this.element),this._handles=this._handles.add(this.element.find(".ui-resizable-handle")),this._handles.disableSelection(),this._handles.on("mouseover",function(){r.resizing||(this.className&&(o=this.className.match(/ui-resizable-(se|sw|ne|nw|n|e|s|w)/i)),r.axis=o&&o[1]?o[1]:"se")}),a.autoHide&&(this._handles.hide(),this._addClass("ui-resizable-autohide"))},_removeHandles:function(){this._handles.remove()},_mouseCapture:function(e){var i,s,n=!1;for(i in this.handles)s=t(this.handles[i])[0],(s===e.target||t.contains(s,e.target))&&(n=!0);return!this.options.disabled&&n},_mouseStart:function(e){var i,s,n,o=this.options,a=this.element;return this.resizing=!0,this._renderProxy(),i=this._num(this.helper.css("left")),s=this._num(this.helper.css("top")),o.containment&&(i+=t(o.containment).scrollLeft()||0,s+=t(o.containment).scrollTop()||0),this.offset=this.helper.offset(),this.position={left:i,top:s},this.size=this._helper?{width:this.helper.width(),height:this.helper.height()}:{width:a.width(),height:a.height()},this.originalSize=this._helper?{width:a.outerWidth(),height:a.outerHeight()}:{width:a.width(),height:a.height()},this.sizeDiff={width:a.outerWidth()-a.width(),height:a.outerHeight()-a.height()},this.originalPosition={left:i,top:s},this.originalMousePosition={left:e.pageX,top:e.pageY},this.aspectRatio="number"==typeof o.aspectRatio?o.aspectRatio:this.originalSize.width/this.originalSize.height||1,n=t(".ui-resizable-"+this.axis).css("cursor"),t("body").css("cursor","auto"===n?this.axis+"-resize":n),this._addClass("ui-resizable-resizing"),this._propagate("start",e),!0},_mouseDrag:function(e){var i,s,n=this.originalMousePosition,o=this.axis,a=e.pageX-n.left||0,r=e.pageY-n.top||0,h=this._change[o];return this._updatePrevProperties(),h?(i=h.apply(this,[e,a,r]),this._updateVirtualBoundaries(e.shiftKey),(this._aspectRatio||e.shiftKey)&&(i=this._updateRatio(i,e)),i=this._respectSize(i,e),this._updateCache(i),this._propagate("resize",e),s=this._applyChanges(),!this._helper&&this._proportionallyResizeElements.length&&this._proportionallyResize(),t.isEmptyObject(s)||(this._updatePrevProperties(),this._trigger("resize",e,this.ui()),this._applyChanges()),!1):!1},_mouseStop:function(e){this.resizing=!1;var i,s,n,o,a,r,h,l=this.options,c=this;return this._helper&&(i=this._proportionallyResizeElements,s=i.length&&/textarea/i.test(i[0].nodeName),n=s&&this._hasScroll(i[0],"left")?0:c.sizeDiff.height,o=s?0:c.sizeDiff.width,a={width:c.helper.width()-o,height:c.helper.height()-n},r=parseFloat(c.element.css("left"))+(c.position.left-c.originalPosition.left)||null,h=parseFloat(c.element.css("top"))+(c.position.top-c.originalPosition.top)||null,l.animate||this.element.css(t.extend(a,{top:h,left:r})),c.helper.height(c.size.height),c.helper.width(c.size.width),this._helper&&!l.animate&&this._proportionallyResize()),t("body").css("cursor","auto"),this._removeClass("ui-resizable-resizing"),this._propagate("stop",e),this._helper&&this.helper.remove(),!1},_updatePrevProperties:function(){this.prevPosition={top:this.position.top,left:this.position.left},this.prevSize={width:this.size.width,height:this.size.height}},_applyChanges:function(){var t={};return this.position.top!==this.prevPosition.top&&(t.top=this.position.top+"px"),this.position.left!==this.prevPosition.left&&(t.left=this.position.left+"px"),this.size.width!==this.prevSize.width&&(t.width=this.size.width+"px"),this.size.height!==this.prevSize.height&&(t.height=this.size.height+"px"),this.helper.css(t),t},_updateVirtualBoundaries:function(t){var e,i,s,n,o,a=this.options;o={minWidth:this._isNumber(a.minWidth)?a.minWidth:0,maxWidth:this._isNumber(a.maxWidth)?a.maxWidth:1/0,minHeight:this._isNumber(a.minHeight)?a.minHeight:0,maxHeight:this._isNumber(a.maxHeight)?a.maxHeight:1/0},(this._aspectRatio||t)&&(e=o.minHeight*this.aspectRatio,s=o.minWidth/this.aspectRatio,i=o.maxHeight*this.aspectRatio,n=o.maxWidth/this.aspectRatio,e>o.minWidth&&(o.minWidth=e),s>o.minHeight&&(o.minHeight=s),o.maxWidth>i&&(o.maxWidth=i),o.maxHeight>n&&(o.maxHeight=n)),this._vBoundaries=o},_updateCache:function(t){this.offset=this.helper.offset(),this._isNumber(t.left)&&(this.position.left=t.left),this._isNumber(t.top)&&(this.position.top=t.top),this._isNumber(t.height)&&(this.size.height=t.height),this._isNumber(t.width)&&(this.size.width=t.width)},_updateRatio:function(t){var e=this.position,i=this.size,s=this.axis;return this._isNumber(t.height)?t.width=t.height*this.aspectRatio:this._isNumber(t.width)&&(t.height=t.width/this.aspectRatio),"sw"===s&&(t.left=e.left+(i.width-t.width),t.top=null),"nw"===s&&(t.top=e.top+(i.height-t.height),t.left=e.left+(i.width-t.width)),t},_respectSize:function(t){var e=this._vBoundaries,i=this.axis,s=this._isNumber(t.width)&&e.maxWidth&&e.maxWidtht.width,a=this._isNumber(t.height)&&e.minHeight&&e.minHeight>t.height,r=this.originalPosition.left+this.originalSize.width,h=this.originalPosition.top+this.originalSize.height,l=/sw|nw|w/.test(i),c=/nw|ne|n/.test(i);return o&&(t.width=e.minWidth),a&&(t.height=e.minHeight),s&&(t.width=e.maxWidth),n&&(t.height=e.maxHeight),o&&l&&(t.left=r-e.minWidth),s&&l&&(t.left=r-e.maxWidth),a&&c&&(t.top=h-e.minHeight),n&&c&&(t.top=h-e.maxHeight),t.width||t.height||t.left||!t.top?t.width||t.height||t.top||!t.left||(t.left=null):t.top=null,t},_getPaddingPlusBorderDimensions:function(t){for(var e=0,i=[],s=[t.css("borderTopWidth"),t.css("borderRightWidth"),t.css("borderBottomWidth"),t.css("borderLeftWidth")],n=[t.css("paddingTop"),t.css("paddingRight"),t.css("paddingBottom"),t.css("paddingLeft")];4>e;e++)i[e]=parseFloat(s[e])||0,i[e]+=parseFloat(n[e])||0;return{height:i[0]+i[2],width:i[1]+i[3]}},_proportionallyResize:function(){if(this._proportionallyResizeElements.length)for(var t,e=0,i=this.helper||this.element;this._proportionallyResizeElements.length>e;e++)t=this._proportionallyResizeElements[e],this.outerDimensions||(this.outerDimensions=this._getPaddingPlusBorderDimensions(t)),t.css({height:i.height()-this.outerDimensions.height||0,width:i.width()-this.outerDimensions.width||0})},_renderProxy:function(){var e=this.element,i=this.options;this.elementOffset=e.offset(),this._helper?(this.helper=this.helper||t("
"),this._addClass(this.helper,this._helper),this.helper.css({width:this.element.outerWidth(),height:this.element.outerHeight(),position:"absolute",left:this.elementOffset.left+"px",top:this.elementOffset.top+"px",zIndex:++i.zIndex}),this.helper.appendTo("body").disableSelection()):this.helper=this.element +},_change:{e:function(t,e){return{width:this.originalSize.width+e}},w:function(t,e){var i=this.originalSize,s=this.originalPosition;return{left:s.left+e,width:i.width-e}},n:function(t,e,i){var s=this.originalSize,n=this.originalPosition;return{top:n.top+i,height:s.height-i}},s:function(t,e,i){return{height:this.originalSize.height+i}},se:function(e,i,s){return t.extend(this._change.s.apply(this,arguments),this._change.e.apply(this,[e,i,s]))},sw:function(e,i,s){return t.extend(this._change.s.apply(this,arguments),this._change.w.apply(this,[e,i,s]))},ne:function(e,i,s){return t.extend(this._change.n.apply(this,arguments),this._change.e.apply(this,[e,i,s]))},nw:function(e,i,s){return t.extend(this._change.n.apply(this,arguments),this._change.w.apply(this,[e,i,s]))}},_propagate:function(e,i){t.ui.plugin.call(this,e,[i,this.ui()]),"resize"!==e&&this._trigger(e,i,this.ui())},plugins:{},ui:function(){return{originalElement:this.originalElement,element:this.element,helper:this.helper,position:this.position,size:this.size,originalSize:this.originalSize,originalPosition:this.originalPosition}}}),t.ui.plugin.add("resizable","animate",{stop:function(e){var i=t(this).resizable("instance"),s=i.options,n=i._proportionallyResizeElements,o=n.length&&/textarea/i.test(n[0].nodeName),a=o&&i._hasScroll(n[0],"left")?0:i.sizeDiff.height,r=o?0:i.sizeDiff.width,h={width:i.size.width-r,height:i.size.height-a},l=parseFloat(i.element.css("left"))+(i.position.left-i.originalPosition.left)||null,c=parseFloat(i.element.css("top"))+(i.position.top-i.originalPosition.top)||null;i.element.animate(t.extend(h,c&&l?{top:c,left:l}:{}),{duration:s.animateDuration,easing:s.animateEasing,step:function(){var s={width:parseFloat(i.element.css("width")),height:parseFloat(i.element.css("height")),top:parseFloat(i.element.css("top")),left:parseFloat(i.element.css("left"))};n&&n.length&&t(n[0]).css({width:s.width,height:s.height}),i._updateCache(s),i._propagate("resize",e)}})}}),t.ui.plugin.add("resizable","containment",{start:function(){var e,i,s,n,o,a,r,h=t(this).resizable("instance"),l=h.options,c=h.element,u=l.containment,d=u instanceof t?u.get(0):/parent/.test(u)?c.parent().get(0):u;d&&(h.containerElement=t(d),/document/.test(u)||u===document?(h.containerOffset={left:0,top:0},h.containerPosition={left:0,top:0},h.parentData={element:t(document),left:0,top:0,width:t(document).width(),height:t(document).height()||document.body.parentNode.scrollHeight}):(e=t(d),i=[],t(["Top","Right","Left","Bottom"]).each(function(t,s){i[t]=h._num(e.css("padding"+s))}),h.containerOffset=e.offset(),h.containerPosition=e.position(),h.containerSize={height:e.innerHeight()-i[3],width:e.innerWidth()-i[1]},s=h.containerOffset,n=h.containerSize.height,o=h.containerSize.width,a=h._hasScroll(d,"left")?d.scrollWidth:o,r=h._hasScroll(d)?d.scrollHeight:n,h.parentData={element:d,left:s.left,top:s.top,width:a,height:r}))},resize:function(e){var i,s,n,o,a=t(this).resizable("instance"),r=a.options,h=a.containerOffset,l=a.position,c=a._aspectRatio||e.shiftKey,u={top:0,left:0},d=a.containerElement,p=!0;d[0]!==document&&/static/.test(d.css("position"))&&(u=h),l.left<(a._helper?h.left:0)&&(a.size.width=a.size.width+(a._helper?a.position.left-h.left:a.position.left-u.left),c&&(a.size.height=a.size.width/a.aspectRatio,p=!1),a.position.left=r.helper?h.left:0),l.top<(a._helper?h.top:0)&&(a.size.height=a.size.height+(a._helper?a.position.top-h.top:a.position.top),c&&(a.size.width=a.size.height*a.aspectRatio,p=!1),a.position.top=a._helper?h.top:0),n=a.containerElement.get(0)===a.element.parent().get(0),o=/relative|absolute/.test(a.containerElement.css("position")),n&&o?(a.offset.left=a.parentData.left+a.position.left,a.offset.top=a.parentData.top+a.position.top):(a.offset.left=a.element.offset().left,a.offset.top=a.element.offset().top),i=Math.abs(a.sizeDiff.width+(a._helper?a.offset.left-u.left:a.offset.left-h.left)),s=Math.abs(a.sizeDiff.height+(a._helper?a.offset.top-u.top:a.offset.top-h.top)),i+a.size.width>=a.parentData.width&&(a.size.width=a.parentData.width-i,c&&(a.size.height=a.size.width/a.aspectRatio,p=!1)),s+a.size.height>=a.parentData.height&&(a.size.height=a.parentData.height-s,c&&(a.size.width=a.size.height*a.aspectRatio,p=!1)),p||(a.position.left=a.prevPosition.left,a.position.top=a.prevPosition.top,a.size.width=a.prevSize.width,a.size.height=a.prevSize.height)},stop:function(){var e=t(this).resizable("instance"),i=e.options,s=e.containerOffset,n=e.containerPosition,o=e.containerElement,a=t(e.helper),r=a.offset(),h=a.outerWidth()-e.sizeDiff.width,l=a.outerHeight()-e.sizeDiff.height;e._helper&&!i.animate&&/relative/.test(o.css("position"))&&t(this).css({left:r.left-n.left-s.left,width:h,height:l}),e._helper&&!i.animate&&/static/.test(o.css("position"))&&t(this).css({left:r.left-n.left-s.left,width:h,height:l})}}),t.ui.plugin.add("resizable","alsoResize",{start:function(){var e=t(this).resizable("instance"),i=e.options;t(i.alsoResize).each(function(){var e=t(this);e.data("ui-resizable-alsoresize",{width:parseFloat(e.width()),height:parseFloat(e.height()),left:parseFloat(e.css("left")),top:parseFloat(e.css("top"))})})},resize:function(e,i){var s=t(this).resizable("instance"),n=s.options,o=s.originalSize,a=s.originalPosition,r={height:s.size.height-o.height||0,width:s.size.width-o.width||0,top:s.position.top-a.top||0,left:s.position.left-a.left||0};t(n.alsoResize).each(function(){var e=t(this),s=t(this).data("ui-resizable-alsoresize"),n={},o=e.parents(i.originalElement[0]).length?["width","height"]:["width","height","top","left"];t.each(o,function(t,e){var i=(s[e]||0)+(r[e]||0);i&&i>=0&&(n[e]=i||null)}),e.css(n)})},stop:function(){t(this).removeData("ui-resizable-alsoresize")}}),t.ui.plugin.add("resizable","ghost",{start:function(){var e=t(this).resizable("instance"),i=e.size;e.ghost=e.originalElement.clone(),e.ghost.css({opacity:.25,display:"block",position:"relative",height:i.height,width:i.width,margin:0,left:0,top:0}),e._addClass(e.ghost,"ui-resizable-ghost"),t.uiBackCompat!==!1&&"string"==typeof e.options.ghost&&e.ghost.addClass(this.options.ghost),e.ghost.appendTo(e.helper)},resize:function(){var e=t(this).resizable("instance");e.ghost&&e.ghost.css({position:"relative",height:e.size.height,width:e.size.width})},stop:function(){var e=t(this).resizable("instance");e.ghost&&e.helper&&e.helper.get(0).removeChild(e.ghost.get(0))}}),t.ui.plugin.add("resizable","grid",{resize:function(){var e,i=t(this).resizable("instance"),s=i.options,n=i.size,o=i.originalSize,a=i.originalPosition,r=i.axis,h="number"==typeof s.grid?[s.grid,s.grid]:s.grid,l=h[0]||1,c=h[1]||1,u=Math.round((n.width-o.width)/l)*l,d=Math.round((n.height-o.height)/c)*c,p=o.width+u,f=o.height+d,m=s.maxWidth&&p>s.maxWidth,g=s.maxHeight&&f>s.maxHeight,_=s.minWidth&&s.minWidth>p,v=s.minHeight&&s.minHeight>f;s.grid=h,_&&(p+=l),v&&(f+=c),m&&(p-=l),g&&(f-=c),/^(se|s|e)$/.test(r)?(i.size.width=p,i.size.height=f):/^(ne)$/.test(r)?(i.size.width=p,i.size.height=f,i.position.top=a.top-d):/^(sw)$/.test(r)?(i.size.width=p,i.size.height=f,i.position.left=a.left-u):((0>=f-c||0>=p-l)&&(e=i._getPaddingPlusBorderDimensions(this)),f-c>0?(i.size.height=f,i.position.top=a.top-d):(f=c-e.height,i.size.height=f,i.position.top=a.top+o.height-f),p-l>0?(i.size.width=p,i.position.left=a.left-u):(p=l-e.width,i.size.width=p,i.position.left=a.left+o.width-p))}}),t.ui.resizable});/** + * Copyright (c) 2007 Ariel Flesler - aflesler ○ gmail • com | https://github.com/flesler + * Licensed under MIT + * @author Ariel Flesler + * @version 2.1.2 + */ +;(function(f){"use strict";"function"===typeof define&&define.amd?define(["jquery"],f):"undefined"!==typeof module&&module.exports?module.exports=f(require("jquery")):f(jQuery)})(function($){"use strict";function n(a){return!a.nodeName||-1!==$.inArray(a.nodeName.toLowerCase(),["iframe","#document","html","body"])}function h(a){return $.isFunction(a)||$.isPlainObject(a)?a:{top:a,left:a}}var p=$.scrollTo=function(a,d,b){return $(window).scrollTo(a,d,b)};p.defaults={axis:"xy",duration:0,limit:!0};$.fn.scrollTo=function(a,d,b){"object"=== typeof d&&(b=d,d=0);"function"===typeof b&&(b={onAfter:b});"max"===a&&(a=9E9);b=$.extend({},p.defaults,b);d=d||b.duration;var u=b.queue&&1=f[g]?0:Math.min(f[g],n));!a&&1-1){targetElements.on(evt+EVENT_NAMESPACE,function elementToggle(event){$.powerTip.toggle(this,event)})}else{targetElements.on(evt+EVENT_NAMESPACE,function elementOpen(event){$.powerTip.show(this,event)})}});$.each(options.closeEvents,function(idx,evt){if($.inArray(evt,options.openEvents)<0){targetElements.on(evt+EVENT_NAMESPACE,function elementClose(event){$.powerTip.hide(this,!isMouseEvent(event))})}});targetElements.on("keydown"+EVENT_NAMESPACE,function elementKeyDown(event){if(event.keyCode===27){$.powerTip.hide(this,true)}})}return targetElements};$.fn.powerTip.defaults={fadeInTime:200,fadeOutTime:100,followMouse:false,popupId:"powerTip",popupClass:null,intentSensitivity:7,intentPollInterval:100,closeDelay:100,placement:"n",smartPlacement:false,offset:10,mouseOnToPopup:false,manual:false,openEvents:["mouseenter","focus"],closeEvents:["mouseleave","blur"]};$.fn.powerTip.smartPlacementLists={n:["n","ne","nw","s"],e:["e","ne","se","w","nw","sw","n","s","e"],s:["s","se","sw","n"],w:["w","nw","sw","e","ne","se","n","s","w"],nw:["nw","w","sw","n","s","se","nw"],ne:["ne","e","se","n","s","sw","ne"],sw:["sw","w","nw","s","n","ne","sw"],se:["se","e","ne","s","n","nw","se"],"nw-alt":["nw-alt","n","ne-alt","sw-alt","s","se-alt","w","e"],"ne-alt":["ne-alt","n","nw-alt","se-alt","s","sw-alt","e","w"],"sw-alt":["sw-alt","s","se-alt","nw-alt","n","ne-alt","w","e"],"se-alt":["se-alt","s","sw-alt","ne-alt","n","nw-alt","e","w"]};$.powerTip={show:function apiShowTip(element,event){if(isMouseEvent(event)){trackMouse(event);session.previousX=event.pageX;session.previousY=event.pageY;$(element).data(DATA_DISPLAYCONTROLLER).show()}else{$(element).first().data(DATA_DISPLAYCONTROLLER).show(true,true)}return element},reposition:function apiResetPosition(element){$(element).first().data(DATA_DISPLAYCONTROLLER).resetPosition();return element},hide:function apiCloseTip(element,immediate){var displayController;immediate=element?immediate:true;if(element){displayController=$(element).first().data(DATA_DISPLAYCONTROLLER)}else if(session.activeHover){displayController=session.activeHover.data(DATA_DISPLAYCONTROLLER)}if(displayController){displayController.hide(immediate)}return element},toggle:function apiToggle(element,event){if(session.activeHover&&session.activeHover.is(element)){$.powerTip.hide(element,!isMouseEvent(event))}else{$.powerTip.show(element,event)}return element}};$.powerTip.showTip=$.powerTip.show;$.powerTip.closeTip=$.powerTip.hide;function CSSCoordinates(){var me=this;me.top="auto";me.left="auto";me.right="auto";me.bottom="auto";me.set=function(property,value){if($.isNumeric(value)){me[property]=Math.round(value)}}}function DisplayController(element,options,tipController){var hoverTimer=null,myCloseDelay=null;function openTooltip(immediate,forceOpen){cancelTimer();if(!element.data(DATA_HASACTIVEHOVER)){if(!immediate){session.tipOpenImminent=true;hoverTimer=setTimeout(function intentDelay(){hoverTimer=null;checkForIntent()},options.intentPollInterval)}else{if(forceOpen){element.data(DATA_FORCEDOPEN,true)}closeAnyDelayed();tipController.showTip(element)}}else{cancelClose()}}function closeTooltip(disableDelay){if(myCloseDelay){myCloseDelay=session.closeDelayTimeout=clearTimeout(myCloseDelay);session.delayInProgress=false}cancelTimer();session.tipOpenImminent=false;if(element.data(DATA_HASACTIVEHOVER)){element.data(DATA_FORCEDOPEN,false);if(!disableDelay){session.delayInProgress=true;session.closeDelayTimeout=setTimeout(function closeDelay(){session.closeDelayTimeout=null;tipController.hideTip(element);session.delayInProgress=false;myCloseDelay=null},options.closeDelay);myCloseDelay=session.closeDelayTimeout}else{tipController.hideTip(element)}}}function checkForIntent(){var xDifference=Math.abs(session.previousX-session.currentX),yDifference=Math.abs(session.previousY-session.currentY),totalDifference=xDifference+yDifference;if(totalDifference",{id:options.popupId});if($body.length===0){$body=$("body")}$body.append(tipElement);session.tooltips=session.tooltips?session.tooltips.add(tipElement):tipElement}if(options.followMouse){if(!tipElement.data(DATA_HASMOUSEMOVE)){$document.on("mousemove"+EVENT_NAMESPACE,positionTipOnCursor);$window.on("scroll"+EVENT_NAMESPACE,positionTipOnCursor);tipElement.data(DATA_HASMOUSEMOVE,true)}}function beginShowTip(element){element.data(DATA_HASACTIVEHOVER,true);tipElement.queue(function queueTipInit(next){showTip(element);next()})}function showTip(element){var tipContent;if(!element.data(DATA_HASACTIVEHOVER)){return}if(session.isTipOpen){if(!session.isClosing){hideTip(session.activeHover)}tipElement.delay(100).queue(function queueTipAgain(next){showTip(element);next()});return}element.trigger("powerTipPreRender");tipContent=getTooltipContent(element);if(tipContent){tipElement.empty().append(tipContent)}else{return}element.trigger("powerTipRender");session.activeHover=element;session.isTipOpen=true;tipElement.data(DATA_MOUSEONTOTIP,options.mouseOnToPopup);tipElement.addClass(options.popupClass);if(!options.followMouse||element.data(DATA_FORCEDOPEN)){positionTipOnElement(element);session.isFixedTipOpen=true}else{positionTipOnCursor()}if(!element.data(DATA_FORCEDOPEN)&&!options.followMouse){$document.on("click"+EVENT_NAMESPACE,function documentClick(event){var target=event.target;if(target!==element[0]){if(options.mouseOnToPopup){if(target!==tipElement[0]&&!$.contains(tipElement[0],target)){$.powerTip.hide()}}else{$.powerTip.hide()}}})}if(options.mouseOnToPopup&&!options.manual){tipElement.on("mouseenter"+EVENT_NAMESPACE,function tipMouseEnter(){if(session.activeHover){session.activeHover.data(DATA_DISPLAYCONTROLLER).cancel()}});tipElement.on("mouseleave"+EVENT_NAMESPACE,function tipMouseLeave(){if(session.activeHover){session.activeHover.data(DATA_DISPLAYCONTROLLER).hide()}})}tipElement.fadeIn(options.fadeInTime,function fadeInCallback(){if(!session.desyncTimeout){session.desyncTimeout=setInterval(closeDesyncedTip,500)}element.trigger("powerTipOpen")})}function hideTip(element){session.isClosing=true;session.isTipOpen=false;session.desyncTimeout=clearInterval(session.desyncTimeout);element.data(DATA_HASACTIVEHOVER,false);element.data(DATA_FORCEDOPEN,false);$document.off("click"+EVENT_NAMESPACE);tipElement.off(EVENT_NAMESPACE);tipElement.fadeOut(options.fadeOutTime,function fadeOutCallback(){var coords=new CSSCoordinates;session.activeHover=null;session.isClosing=false;session.isFixedTipOpen=false;tipElement.removeClass();coords.set("top",session.currentY+options.offset);coords.set("left",session.currentX+options.offset);tipElement.css(coords);element.trigger("powerTipClose")})}function positionTipOnCursor(){var tipWidth,tipHeight,coords,collisions,collisionCount;if(!session.isFixedTipOpen&&(session.isTipOpen||session.tipOpenImminent&&tipElement.data(DATA_HASMOUSEMOVE))){tipWidth=tipElement.outerWidth();tipHeight=tipElement.outerHeight();coords=new CSSCoordinates;coords.set("top",session.currentY+options.offset);coords.set("left",session.currentX+options.offset);collisions=getViewportCollisions(coords,tipWidth,tipHeight);if(collisions!==Collision.none){collisionCount=countFlags(collisions);if(collisionCount===1){if(collisions===Collision.right){coords.set("left",session.scrollLeft+session.windowWidth-tipWidth)}else if(collisions===Collision.bottom){coords.set("top",session.scrollTop+session.windowHeight-tipHeight)}}else{coords.set("left",session.currentX-tipWidth-options.offset);coords.set("top",session.currentY-tipHeight-options.offset)}}tipElement.css(coords)}}function positionTipOnElement(element){var priorityList,finalPlacement;if(options.smartPlacement||options.followMouse&&element.data(DATA_FORCEDOPEN)){priorityList=$.fn.powerTip.smartPlacementLists[options.placement];$.each(priorityList,function(idx,pos){var collisions=getViewportCollisions(placeTooltip(element,pos),tipElement.outerWidth(),tipElement.outerHeight());finalPlacement=pos;return collisions!==Collision.none})}else{placeTooltip(element,options.placement);finalPlacement=options.placement}tipElement.removeClass("w nw sw e ne se n s w se-alt sw-alt ne-alt nw-alt");tipElement.addClass(finalPlacement)}function placeTooltip(element,placement){var iterationCount=0,tipWidth,tipHeight,coords=new CSSCoordinates;coords.set("top",0);coords.set("left",0);tipElement.css(coords);do{tipWidth=tipElement.outerWidth();tipHeight=tipElement.outerHeight();coords=placementCalculator.compute(element,placement,tipWidth,tipHeight,options.offset);tipElement.css(coords)}while(++iterationCount<=5&&(tipWidth!==tipElement.outerWidth()||tipHeight!==tipElement.outerHeight()));return coords}function closeDesyncedTip(){var isDesynced=false,hasDesyncableCloseEvent=$.grep(["mouseleave","mouseout","blur","focusout"],function(eventType){return $.inArray(eventType,options.closeEvents)!==-1}).length>0;if(session.isTipOpen&&!session.isClosing&&!session.delayInProgress&&hasDesyncableCloseEvent){if(session.activeHover.data(DATA_HASACTIVEHOVER)===false||session.activeHover.is(":disabled")){isDesynced=true}else if(!isMouseOver(session.activeHover)&&!session.activeHover.is(":focus")&&!session.activeHover.data(DATA_FORCEDOPEN)){if(tipElement.data(DATA_MOUSEONTOTIP)){if(!isMouseOver(tipElement)){isDesynced=true}}else{isDesynced=true}}if(isDesynced){hideTip(session.activeHover)}}}this.showTip=beginShowTip;this.hideTip=hideTip;this.resetPosition=positionTipOnElement}function isSvgElement(element){return Boolean(window.SVGElement&&element[0]instanceof SVGElement)}function isMouseEvent(event){return Boolean(event&&$.inArray(event.type,MOUSE_EVENTS)>-1&&typeof event.pageX==="number")}function initTracking(){if(!session.mouseTrackingActive){session.mouseTrackingActive=true;getViewportDimensions();$(getViewportDimensions);$document.on("mousemove"+EVENT_NAMESPACE,trackMouse);$window.on("resize"+EVENT_NAMESPACE,trackResize);$window.on("scroll"+EVENT_NAMESPACE,trackScroll)}}function getViewportDimensions(){session.scrollLeft=$window.scrollLeft();session.scrollTop=$window.scrollTop();session.windowWidth=$window.width();session.windowHeight=$window.height()}function trackResize(){session.windowWidth=$window.width();session.windowHeight=$window.height()}function trackScroll(){var x=$window.scrollLeft(),y=$window.scrollTop();if(x!==session.scrollLeft){session.currentX+=x-session.scrollLeft;session.scrollLeft=x}if(y!==session.scrollTop){session.currentY+=y-session.scrollTop;session.scrollTop=y}}function trackMouse(event){session.currentX=event.pageX;session.currentY=event.pageY}function isMouseOver(element){var elementPosition=element.offset(),elementBox=element[0].getBoundingClientRect(),elementWidth=elementBox.right-elementBox.left,elementHeight=elementBox.bottom-elementBox.top;return session.currentX>=elementPosition.left&&session.currentX<=elementPosition.left+elementWidth&&session.currentY>=elementPosition.top&&session.currentY<=elementPosition.top+elementHeight}function getTooltipContent(element){var tipText=element.data(DATA_POWERTIP),tipObject=element.data(DATA_POWERTIPJQ),tipTarget=element.data(DATA_POWERTIPTARGET),targetElement,content;if(tipText){if($.isFunction(tipText)){tipText=tipText.call(element[0])}content=tipText}else if(tipObject){if($.isFunction(tipObject)){tipObject=tipObject.call(element[0])}if(tipObject.length>0){content=tipObject.clone(true,true)}}else if(tipTarget){targetElement=$("#"+tipTarget);if(targetElement.length>0){content=targetElement.html()}}return content}function getViewportCollisions(coords,elementWidth,elementHeight){var viewportTop=session.scrollTop,viewportLeft=session.scrollLeft,viewportBottom=viewportTop+session.windowHeight,viewportRight=viewportLeft+session.windowWidth,collisions=Collision.none;if(coords.topviewportBottom||Math.abs(coords.bottom-session.windowHeight)>viewportBottom){collisions|=Collision.bottom}if(coords.leftviewportRight){collisions|=Collision.left}if(coords.left+elementWidth>viewportRight||coords.right1)){a.preventDefault();var c=a.originalEvent.changedTouches[0],d=document.createEvent("MouseEvents");d.initMouseEvent(b,!0,!0,window,1,c.screenX,c.screenY,c.clientX,c.clientY,!1,!1,!1,!1,0,null),a.target.dispatchEvent(d)}}if(a.support.touch="ontouchend"in document,a.support.touch){var e,b=a.ui.mouse.prototype,c=b._mouseInit,d=b._mouseDestroy;b._touchStart=function(a){var b=this;!e&&b._mouseCapture(a.originalEvent.changedTouches[0])&&(e=!0,b._touchMoved=!1,f(a,"mouseover"),f(a,"mousemove"),f(a,"mousedown"))},b._touchMove=function(a){e&&(this._touchMoved=!0,f(a,"mousemove"))},b._touchEnd=function(a){e&&(f(a,"mouseup"),f(a,"mouseout"),this._touchMoved||f(a,"click"),e=!1)},b._mouseInit=function(){var b=this;b.element.bind({touchstart:a.proxy(b,"_touchStart"),touchmove:a.proxy(b,"_touchMove"),touchend:a.proxy(b,"_touchEnd")}),c.call(b)},b._mouseDestroy=function(){var b=this;b.element.unbind({touchstart:a.proxy(b,"_touchStart"),touchmove:a.proxy(b,"_touchMove"),touchend:a.proxy(b,"_touchEnd")}),d.call(b)}}}(jQuery);/*! SmartMenus jQuery Plugin - v1.1.0 - September 17, 2017 + * http://www.smartmenus.org/ + * Copyright Vasil Dinkov, Vadikom Web Ltd. http://vadikom.com; Licensed MIT */(function(t){"function"==typeof define&&define.amd?define(["jquery"],t):"object"==typeof module&&"object"==typeof module.exports?module.exports=t(require("jquery")):t(jQuery)})(function($){function initMouseDetection(t){var e=".smartmenus_mouse";if(mouseDetectionEnabled||t)mouseDetectionEnabled&&t&&($(document).off(e),mouseDetectionEnabled=!1);else{var i=!0,s=null,o={mousemove:function(t){var e={x:t.pageX,y:t.pageY,timeStamp:(new Date).getTime()};if(s){var o=Math.abs(s.x-e.x),a=Math.abs(s.y-e.y);if((o>0||a>0)&&2>=o&&2>=a&&300>=e.timeStamp-s.timeStamp&&(mouse=!0,i)){var n=$(t.target).closest("a");n.is("a")&&$.each(menuTrees,function(){return $.contains(this.$root[0],n[0])?(this.itemEnter({currentTarget:n[0]}),!1):void 0}),i=!1}}s=e}};o[touchEvents?"touchstart":"pointerover pointermove pointerout MSPointerOver MSPointerMove MSPointerOut"]=function(t){isTouchEvent(t.originalEvent)&&(mouse=!1)},$(document).on(getEventsNS(o,e)),mouseDetectionEnabled=!0}}function isTouchEvent(t){return!/^(4|mouse)$/.test(t.pointerType)}function getEventsNS(t,e){e||(e="");var i={};for(var s in t)i[s.split(" ").join(e+" ")+e]=t[s];return i}var menuTrees=[],mouse=!1,touchEvents="ontouchstart"in window,mouseDetectionEnabled=!1,requestAnimationFrame=window.requestAnimationFrame||function(t){return setTimeout(t,1e3/60)},cancelAnimationFrame=window.cancelAnimationFrame||function(t){clearTimeout(t)},canAnimate=!!$.fn.animate;return $.SmartMenus=function(t,e){this.$root=$(t),this.opts=e,this.rootId="",this.accessIdPrefix="",this.$subArrow=null,this.activatedItems=[],this.visibleSubMenus=[],this.showTimeout=0,this.hideTimeout=0,this.scrollTimeout=0,this.clickActivated=!1,this.focusActivated=!1,this.zIndexInc=0,this.idInc=0,this.$firstLink=null,this.$firstSub=null,this.disabled=!1,this.$disableOverlay=null,this.$touchScrollingSub=null,this.cssTransforms3d="perspective"in t.style||"webkitPerspective"in t.style,this.wasCollapsible=!1,this.init()},$.extend($.SmartMenus,{hideAll:function(){$.each(menuTrees,function(){this.menuHideAll()})},destroy:function(){for(;menuTrees.length;)menuTrees[0].destroy();initMouseDetection(!0)},prototype:{init:function(t){var e=this;if(!t){menuTrees.push(this),this.rootId=((new Date).getTime()+Math.random()+"").replace(/\D/g,""),this.accessIdPrefix="sm-"+this.rootId+"-",this.$root.hasClass("sm-rtl")&&(this.opts.rightToLeftSubMenus=!0);var i=".smartmenus";this.$root.data("smartmenus",this).attr("data-smartmenus-id",this.rootId).dataSM("level",1).on(getEventsNS({"mouseover focusin":$.proxy(this.rootOver,this),"mouseout focusout":$.proxy(this.rootOut,this),keydown:$.proxy(this.rootKeyDown,this)},i)).on(getEventsNS({mouseenter:$.proxy(this.itemEnter,this),mouseleave:$.proxy(this.itemLeave,this),mousedown:$.proxy(this.itemDown,this),focus:$.proxy(this.itemFocus,this),blur:$.proxy(this.itemBlur,this),click:$.proxy(this.itemClick,this)},i),"a"),i+=this.rootId,this.opts.hideOnClick&&$(document).on(getEventsNS({touchstart:$.proxy(this.docTouchStart,this),touchmove:$.proxy(this.docTouchMove,this),touchend:$.proxy(this.docTouchEnd,this),click:$.proxy(this.docClick,this)},i)),$(window).on(getEventsNS({"resize orientationchange":$.proxy(this.winResize,this)},i)),this.opts.subIndicators&&(this.$subArrow=$("").addClass("sub-arrow"),this.opts.subIndicatorsText&&this.$subArrow.html(this.opts.subIndicatorsText)),initMouseDetection()}if(this.$firstSub=this.$root.find("ul").each(function(){e.menuInit($(this))}).eq(0),this.$firstLink=this.$root.find("a").eq(0),this.opts.markCurrentItem){var s=/(index|default)\.[^#\?\/]*/i,o=/#.*/,a=window.location.href.replace(s,""),n=a.replace(o,"");this.$root.find("a").each(function(){var t=this.href.replace(s,""),i=$(this);(t==a||t==n)&&(i.addClass("current"),e.opts.markCurrentTree&&i.parentsUntil("[data-smartmenus-id]","ul").each(function(){$(this).dataSM("parent-a").addClass("current")}))})}this.wasCollapsible=this.isCollapsible()},destroy:function(t){if(!t){var e=".smartmenus";this.$root.removeData("smartmenus").removeAttr("data-smartmenus-id").removeDataSM("level").off(e),e+=this.rootId,$(document).off(e),$(window).off(e),this.opts.subIndicators&&(this.$subArrow=null)}this.menuHideAll();var i=this;this.$root.find("ul").each(function(){var t=$(this);t.dataSM("scroll-arrows")&&t.dataSM("scroll-arrows").remove(),t.dataSM("shown-before")&&((i.opts.subMenusMinWidth||i.opts.subMenusMaxWidth)&&t.css({width:"",minWidth:"",maxWidth:""}).removeClass("sm-nowrap"),t.dataSM("scroll-arrows")&&t.dataSM("scroll-arrows").remove(),t.css({zIndex:"",top:"",left:"",marginLeft:"",marginTop:"",display:""})),0==(t.attr("id")||"").indexOf(i.accessIdPrefix)&&t.removeAttr("id")}).removeDataSM("in-mega").removeDataSM("shown-before").removeDataSM("scroll-arrows").removeDataSM("parent-a").removeDataSM("level").removeDataSM("beforefirstshowfired").removeAttr("role").removeAttr("aria-hidden").removeAttr("aria-labelledby").removeAttr("aria-expanded"),this.$root.find("a.has-submenu").each(function(){var t=$(this);0==t.attr("id").indexOf(i.accessIdPrefix)&&t.removeAttr("id")}).removeClass("has-submenu").removeDataSM("sub").removeAttr("aria-haspopup").removeAttr("aria-controls").removeAttr("aria-expanded").closest("li").removeDataSM("sub"),this.opts.subIndicators&&this.$root.find("span.sub-arrow").remove(),this.opts.markCurrentItem&&this.$root.find("a.current").removeClass("current"),t||(this.$root=null,this.$firstLink=null,this.$firstSub=null,this.$disableOverlay&&(this.$disableOverlay.remove(),this.$disableOverlay=null),menuTrees.splice($.inArray(this,menuTrees),1))},disable:function(t){if(!this.disabled){if(this.menuHideAll(),!t&&!this.opts.isPopup&&this.$root.is(":visible")){var e=this.$root.offset();this.$disableOverlay=$('
').css({position:"absolute",top:e.top,left:e.left,width:this.$root.outerWidth(),height:this.$root.outerHeight(),zIndex:this.getStartZIndex(!0),opacity:0}).appendTo(document.body)}this.disabled=!0}},docClick:function(t){return this.$touchScrollingSub?(this.$touchScrollingSub=null,void 0):((this.visibleSubMenus.length&&!$.contains(this.$root[0],t.target)||$(t.target).closest("a").length)&&this.menuHideAll(),void 0)},docTouchEnd:function(){if(this.lastTouch){if(!(!this.visibleSubMenus.length||void 0!==this.lastTouch.x2&&this.lastTouch.x1!=this.lastTouch.x2||void 0!==this.lastTouch.y2&&this.lastTouch.y1!=this.lastTouch.y2||this.lastTouch.target&&$.contains(this.$root[0],this.lastTouch.target))){this.hideTimeout&&(clearTimeout(this.hideTimeout),this.hideTimeout=0);var t=this;this.hideTimeout=setTimeout(function(){t.menuHideAll()},350)}this.lastTouch=null}},docTouchMove:function(t){if(this.lastTouch){var e=t.originalEvent.touches[0];this.lastTouch.x2=e.pageX,this.lastTouch.y2=e.pageY}},docTouchStart:function(t){var e=t.originalEvent.touches[0];this.lastTouch={x1:e.pageX,y1:e.pageY,target:e.target}},enable:function(){this.disabled&&(this.$disableOverlay&&(this.$disableOverlay.remove(),this.$disableOverlay=null),this.disabled=!1)},getClosestMenu:function(t){for(var e=$(t).closest("ul");e.dataSM("in-mega");)e=e.parent().closest("ul");return e[0]||null},getHeight:function(t){return this.getOffset(t,!0)},getOffset:function(t,e){var i;"none"==t.css("display")&&(i={position:t[0].style.position,visibility:t[0].style.visibility},t.css({position:"absolute",visibility:"hidden"}).show());var s=t[0].getBoundingClientRect&&t[0].getBoundingClientRect(),o=s&&(e?s.height||s.bottom-s.top:s.width||s.right-s.left);return o||0===o||(o=e?t[0].offsetHeight:t[0].offsetWidth),i&&t.hide().css(i),o},getStartZIndex:function(t){var e=parseInt(this[t?"$root":"$firstSub"].css("z-index"));return!t&&isNaN(e)&&(e=parseInt(this.$root.css("z-index"))),isNaN(e)?1:e},getTouchPoint:function(t){return t.touches&&t.touches[0]||t.changedTouches&&t.changedTouches[0]||t},getViewport:function(t){var e=t?"Height":"Width",i=document.documentElement["client"+e],s=window["inner"+e];return s&&(i=Math.min(i,s)),i},getViewportHeight:function(){return this.getViewport(!0)},getViewportWidth:function(){return this.getViewport()},getWidth:function(t){return this.getOffset(t)},handleEvents:function(){return!this.disabled&&this.isCSSOn()},handleItemEvents:function(t){return this.handleEvents()&&!this.isLinkInMegaMenu(t)},isCollapsible:function(){return"static"==this.$firstSub.css("position")},isCSSOn:function(){return"inline"!=this.$firstLink.css("display")},isFixed:function(){var t="fixed"==this.$root.css("position");return t||this.$root.parentsUntil("body").each(function(){return"fixed"==$(this).css("position")?(t=!0,!1):void 0}),t},isLinkInMegaMenu:function(t){return $(this.getClosestMenu(t[0])).hasClass("mega-menu")},isTouchMode:function(){return!mouse||this.opts.noMouseOver||this.isCollapsible()},itemActivate:function(t,e){var i=t.closest("ul"),s=i.dataSM("level");if(s>1&&(!this.activatedItems[s-2]||this.activatedItems[s-2][0]!=i.dataSM("parent-a")[0])){var o=this;$(i.parentsUntil("[data-smartmenus-id]","ul").get().reverse()).add(i).each(function(){o.itemActivate($(this).dataSM("parent-a"))})}if((!this.isCollapsible()||e)&&this.menuHideSubMenus(this.activatedItems[s-1]&&this.activatedItems[s-1][0]==t[0]?s:s-1),this.activatedItems[s-1]=t,this.$root.triggerHandler("activate.smapi",t[0])!==!1){var a=t.dataSM("sub");a&&(this.isTouchMode()||!this.opts.showOnClick||this.clickActivated)&&this.menuShow(a)}},itemBlur:function(t){var e=$(t.currentTarget);this.handleItemEvents(e)&&this.$root.triggerHandler("blur.smapi",e[0])},itemClick:function(t){var e=$(t.currentTarget);if(this.handleItemEvents(e)){if(this.$touchScrollingSub&&this.$touchScrollingSub[0]==e.closest("ul")[0])return this.$touchScrollingSub=null,t.stopPropagation(),!1;if(this.$root.triggerHandler("click.smapi",e[0])===!1)return!1;var i=$(t.target).is(".sub-arrow"),s=e.dataSM("sub"),o=s?2==s.dataSM("level"):!1,a=this.isCollapsible(),n=/toggle$/.test(this.opts.collapsibleBehavior),r=/link$/.test(this.opts.collapsibleBehavior),h=/^accordion/.test(this.opts.collapsibleBehavior);if(s&&!s.is(":visible")){if((!r||!a||i)&&(this.opts.showOnClick&&o&&(this.clickActivated=!0),this.itemActivate(e,h),s.is(":visible")))return this.focusActivated=!0,!1}else if(a&&(n||i))return this.itemActivate(e,h),this.menuHide(s),n&&(this.focusActivated=!1),!1;return this.opts.showOnClick&&o||e.hasClass("disabled")||this.$root.triggerHandler("select.smapi",e[0])===!1?!1:void 0}},itemDown:function(t){var e=$(t.currentTarget);this.handleItemEvents(e)&&e.dataSM("mousedown",!0)},itemEnter:function(t){var e=$(t.currentTarget);if(this.handleItemEvents(e)){if(!this.isTouchMode()){this.showTimeout&&(clearTimeout(this.showTimeout),this.showTimeout=0);var i=this;this.showTimeout=setTimeout(function(){i.itemActivate(e)},this.opts.showOnClick&&1==e.closest("ul").dataSM("level")?1:this.opts.showTimeout)}this.$root.triggerHandler("mouseenter.smapi",e[0])}},itemFocus:function(t){var e=$(t.currentTarget);this.handleItemEvents(e)&&(!this.focusActivated||this.isTouchMode()&&e.dataSM("mousedown")||this.activatedItems.length&&this.activatedItems[this.activatedItems.length-1][0]==e[0]||this.itemActivate(e,!0),this.$root.triggerHandler("focus.smapi",e[0]))},itemLeave:function(t){var e=$(t.currentTarget);this.handleItemEvents(e)&&(this.isTouchMode()||(e[0].blur(),this.showTimeout&&(clearTimeout(this.showTimeout),this.showTimeout=0)),e.removeDataSM("mousedown"),this.$root.triggerHandler("mouseleave.smapi",e[0]))},menuHide:function(t){if(this.$root.triggerHandler("beforehide.smapi",t[0])!==!1&&(canAnimate&&t.stop(!0,!0),"none"!=t.css("display"))){var e=function(){t.css("z-index","")};this.isCollapsible()?canAnimate&&this.opts.collapsibleHideFunction?this.opts.collapsibleHideFunction.call(this,t,e):t.hide(this.opts.collapsibleHideDuration,e):canAnimate&&this.opts.hideFunction?this.opts.hideFunction.call(this,t,e):t.hide(this.opts.hideDuration,e),t.dataSM("scroll")&&(this.menuScrollStop(t),t.css({"touch-action":"","-ms-touch-action":"","-webkit-transform":"",transform:""}).off(".smartmenus_scroll").removeDataSM("scroll").dataSM("scroll-arrows").hide()),t.dataSM("parent-a").removeClass("highlighted").attr("aria-expanded","false"),t.attr({"aria-expanded":"false","aria-hidden":"true"});var i=t.dataSM("level");this.activatedItems.splice(i-1,1),this.visibleSubMenus.splice($.inArray(t,this.visibleSubMenus),1),this.$root.triggerHandler("hide.smapi",t[0])}},menuHideAll:function(){this.showTimeout&&(clearTimeout(this.showTimeout),this.showTimeout=0);for(var t=this.opts.isPopup?1:0,e=this.visibleSubMenus.length-1;e>=t;e--)this.menuHide(this.visibleSubMenus[e]);this.opts.isPopup&&(canAnimate&&this.$root.stop(!0,!0),this.$root.is(":visible")&&(canAnimate&&this.opts.hideFunction?this.opts.hideFunction.call(this,this.$root):this.$root.hide(this.opts.hideDuration))),this.activatedItems=[],this.visibleSubMenus=[],this.clickActivated=!1,this.focusActivated=!1,this.zIndexInc=0,this.$root.triggerHandler("hideAll.smapi")},menuHideSubMenus:function(t){for(var e=this.activatedItems.length-1;e>=t;e--){var i=this.activatedItems[e].dataSM("sub");i&&this.menuHide(i)}},menuInit:function(t){if(!t.dataSM("in-mega")){t.hasClass("mega-menu")&&t.find("ul").dataSM("in-mega",!0);for(var e=2,i=t[0];(i=i.parentNode.parentNode)!=this.$root[0];)e++;var s=t.prevAll("a").eq(-1);s.length||(s=t.prevAll().find("a").eq(-1)),s.addClass("has-submenu").dataSM("sub",t),t.dataSM("parent-a",s).dataSM("level",e).parent().dataSM("sub",t);var o=s.attr("id")||this.accessIdPrefix+ ++this.idInc,a=t.attr("id")||this.accessIdPrefix+ ++this.idInc;s.attr({id:o,"aria-haspopup":"true","aria-controls":a,"aria-expanded":"false"}),t.attr({id:a,role:"group","aria-hidden":"true","aria-labelledby":o,"aria-expanded":"false"}),this.opts.subIndicators&&s[this.opts.subIndicatorsPos](this.$subArrow.clone())}},menuPosition:function(t){var e,i,s=t.dataSM("parent-a"),o=s.closest("li"),a=o.parent(),n=t.dataSM("level"),r=this.getWidth(t),h=this.getHeight(t),u=s.offset(),l=u.left,c=u.top,d=this.getWidth(s),m=this.getHeight(s),p=$(window),f=p.scrollLeft(),v=p.scrollTop(),b=this.getViewportWidth(),S=this.getViewportHeight(),g=a.parent().is("[data-sm-horizontal-sub]")||2==n&&!a.hasClass("sm-vertical"),M=this.opts.rightToLeftSubMenus&&!o.is("[data-sm-reverse]")||!this.opts.rightToLeftSubMenus&&o.is("[data-sm-reverse]"),w=2==n?this.opts.mainMenuSubOffsetX:this.opts.subMenusSubOffsetX,T=2==n?this.opts.mainMenuSubOffsetY:this.opts.subMenusSubOffsetY;if(g?(e=M?d-r-w:w,i=this.opts.bottomToTopSubMenus?-h-T:m+T):(e=M?w-r:d-w,i=this.opts.bottomToTopSubMenus?m-T-h:T),this.opts.keepInViewport){var y=l+e,I=c+i;if(M&&f>y?e=g?f-y+e:d-w:!M&&y+r>f+b&&(e=g?f+b-r-y+e:w-r),g||(S>h&&I+h>v+S?i+=v+S-h-I:(h>=S||v>I)&&(i+=v-I)),g&&(I+h>v+S+.49||v>I)||!g&&h>S+.49){var x=this;t.dataSM("scroll-arrows")||t.dataSM("scroll-arrows",$([$('')[0],$('')[0]]).on({mouseenter:function(){t.dataSM("scroll").up=$(this).hasClass("scroll-up"),x.menuScroll(t)},mouseleave:function(e){x.menuScrollStop(t),x.menuScrollOut(t,e)},"mousewheel DOMMouseScroll":function(t){t.preventDefault()}}).insertAfter(t));var A=".smartmenus_scroll";if(t.dataSM("scroll",{y:this.cssTransforms3d?0:i-m,step:1,itemH:m,subH:h,arrowDownH:this.getHeight(t.dataSM("scroll-arrows").eq(1))}).on(getEventsNS({mouseover:function(e){x.menuScrollOver(t,e)},mouseout:function(e){x.menuScrollOut(t,e)},"mousewheel DOMMouseScroll":function(e){x.menuScrollMousewheel(t,e)}},A)).dataSM("scroll-arrows").css({top:"auto",left:"0",marginLeft:e+(parseInt(t.css("border-left-width"))||0),width:r-(parseInt(t.css("border-left-width"))||0)-(parseInt(t.css("border-right-width"))||0),zIndex:t.css("z-index")}).eq(g&&this.opts.bottomToTopSubMenus?0:1).show(),this.isFixed()){var C={};C[touchEvents?"touchstart touchmove touchend":"pointerdown pointermove pointerup MSPointerDown MSPointerMove MSPointerUp"]=function(e){x.menuScrollTouch(t,e)},t.css({"touch-action":"none","-ms-touch-action":"none"}).on(getEventsNS(C,A))}}}t.css({top:"auto",left:"0",marginLeft:e,marginTop:i-m})},menuScroll:function(t,e,i){var s,o=t.dataSM("scroll"),a=t.dataSM("scroll-arrows"),n=o.up?o.upEnd:o.downEnd;if(!e&&o.momentum){if(o.momentum*=.92,s=o.momentum,.5>s)return this.menuScrollStop(t),void 0}else s=i||(e||!this.opts.scrollAccelerate?this.opts.scrollStep:Math.floor(o.step));var r=t.dataSM("level");if(this.activatedItems[r-1]&&this.activatedItems[r-1].dataSM("sub")&&this.activatedItems[r-1].dataSM("sub").is(":visible")&&this.menuHideSubMenus(r-1),o.y=o.up&&o.y>=n||!o.up&&n>=o.y?o.y:Math.abs(n-o.y)>s?o.y+(o.up?s:-s):n,t.css(this.cssTransforms3d?{"-webkit-transform":"translate3d(0, "+o.y+"px, 0)",transform:"translate3d(0, "+o.y+"px, 0)"}:{marginTop:o.y}),mouse&&(o.up&&o.y>o.downEnd||!o.up&&o.y0;t.dataSM("scroll-arrows").eq(i?0:1).is(":visible")&&(t.dataSM("scroll").up=i,this.menuScroll(t,!0))}e.preventDefault()},menuScrollOut:function(t,e){mouse&&(/^scroll-(up|down)/.test((e.relatedTarget||"").className)||(t[0]==e.relatedTarget||$.contains(t[0],e.relatedTarget))&&this.getClosestMenu(e.relatedTarget)==t[0]||t.dataSM("scroll-arrows").css("visibility","hidden"))},menuScrollOver:function(t,e){if(mouse&&!/^scroll-(up|down)/.test(e.target.className)&&this.getClosestMenu(e.target)==t[0]){this.menuScrollRefreshData(t);var i=t.dataSM("scroll"),s=$(window).scrollTop()-t.dataSM("parent-a").offset().top-i.itemH;t.dataSM("scroll-arrows").eq(0).css("margin-top",s).end().eq(1).css("margin-top",s+this.getViewportHeight()-i.arrowDownH).end().css("visibility","visible")}},menuScrollRefreshData:function(t){var e=t.dataSM("scroll"),i=$(window).scrollTop()-t.dataSM("parent-a").offset().top-e.itemH;this.cssTransforms3d&&(i=-(parseFloat(t.css("margin-top"))-i)),$.extend(e,{upEnd:i,downEnd:i+this.getViewportHeight()-e.subH})},menuScrollStop:function(t){return this.scrollTimeout?(cancelAnimationFrame(this.scrollTimeout),this.scrollTimeout=0,t.dataSM("scroll").step=1,!0):void 0},menuScrollTouch:function(t,e){if(e=e.originalEvent,isTouchEvent(e)){var i=this.getTouchPoint(e);if(this.getClosestMenu(i.target)==t[0]){var s=t.dataSM("scroll");if(/(start|down)$/i.test(e.type))this.menuScrollStop(t)?(e.preventDefault(),this.$touchScrollingSub=t):this.$touchScrollingSub=null,this.menuScrollRefreshData(t),$.extend(s,{touchStartY:i.pageY,touchStartTime:e.timeStamp});else if(/move$/i.test(e.type)){var o=void 0!==s.touchY?s.touchY:s.touchStartY;if(void 0!==o&&o!=i.pageY){this.$touchScrollingSub=t;var a=i.pageY>o;void 0!==s.up&&s.up!=a&&$.extend(s,{touchStartY:i.pageY,touchStartTime:e.timeStamp}),$.extend(s,{up:a,touchY:i.pageY}),this.menuScroll(t,!0,Math.abs(i.pageY-o))}e.preventDefault()}else void 0!==s.touchY&&((s.momentum=15*Math.pow(Math.abs(i.pageY-s.touchStartY)/(e.timeStamp-s.touchStartTime),2))&&(this.menuScrollStop(t),this.menuScroll(t),e.preventDefault()),delete s.touchY)}}},menuShow:function(t){if((t.dataSM("beforefirstshowfired")||(t.dataSM("beforefirstshowfired",!0),this.$root.triggerHandler("beforefirstshow.smapi",t[0])!==!1))&&this.$root.triggerHandler("beforeshow.smapi",t[0])!==!1&&(t.dataSM("shown-before",!0),canAnimate&&t.stop(!0,!0),!t.is(":visible"))){var e=t.dataSM("parent-a"),i=this.isCollapsible();if((this.opts.keepHighlighted||i)&&e.addClass("highlighted"),i)t.removeClass("sm-nowrap").css({zIndex:"",width:"auto",minWidth:"",maxWidth:"",top:"",left:"",marginLeft:"",marginTop:""});else{if(t.css("z-index",this.zIndexInc=(this.zIndexInc||this.getStartZIndex())+1),(this.opts.subMenusMinWidth||this.opts.subMenusMaxWidth)&&(t.css({width:"auto",minWidth:"",maxWidth:""}).addClass("sm-nowrap"),this.opts.subMenusMinWidth&&t.css("min-width",this.opts.subMenusMinWidth),this.opts.subMenusMaxWidth)){var s=this.getWidth(t);t.css("max-width",this.opts.subMenusMaxWidth),s>this.getWidth(t)&&t.removeClass("sm-nowrap").css("width",this.opts.subMenusMaxWidth)}this.menuPosition(t)}var o=function(){t.css("overflow","")};i?canAnimate&&this.opts.collapsibleShowFunction?this.opts.collapsibleShowFunction.call(this,t,o):t.show(this.opts.collapsibleShowDuration,o):canAnimate&&this.opts.showFunction?this.opts.showFunction.call(this,t,o):t.show(this.opts.showDuration,o),e.attr("aria-expanded","true"),t.attr({"aria-expanded":"true","aria-hidden":"false"}),this.visibleSubMenus.push(t),this.$root.triggerHandler("show.smapi",t[0])}},popupHide:function(t){this.hideTimeout&&(clearTimeout(this.hideTimeout),this.hideTimeout=0);var e=this;this.hideTimeout=setTimeout(function(){e.menuHideAll()},t?1:this.opts.hideTimeout)},popupShow:function(t,e){if(!this.opts.isPopup)return alert('SmartMenus jQuery Error:\n\nIf you want to show this menu via the "popupShow" method, set the isPopup:true option.'),void 0;if(this.hideTimeout&&(clearTimeout(this.hideTimeout),this.hideTimeout=0),this.$root.dataSM("shown-before",!0),canAnimate&&this.$root.stop(!0,!0),!this.$root.is(":visible")){this.$root.css({left:t,top:e});var i=this,s=function(){i.$root.css("overflow","")};canAnimate&&this.opts.showFunction?this.opts.showFunction.call(this,this.$root,s):this.$root.show(this.opts.showDuration,s),this.visibleSubMenus[0]=this.$root}},refresh:function(){this.destroy(!0),this.init(!0)},rootKeyDown:function(t){if(this.handleEvents())switch(t.keyCode){case 27:var e=this.activatedItems[0];if(e){this.menuHideAll(),e[0].focus();var i=e.dataSM("sub");i&&this.menuHide(i)}break;case 32:var s=$(t.target);if(s.is("a")&&this.handleItemEvents(s)){var i=s.dataSM("sub");i&&!i.is(":visible")&&(this.itemClick({currentTarget:t.target}),t.preventDefault())}}},rootOut:function(t){if(this.handleEvents()&&!this.isTouchMode()&&t.target!=this.$root[0]&&(this.hideTimeout&&(clearTimeout(this.hideTimeout),this.hideTimeout=0),!this.opts.showOnClick||!this.opts.hideOnClick)){var e=this;this.hideTimeout=setTimeout(function(){e.menuHideAll()},this.opts.hideTimeout)}},rootOver:function(t){this.handleEvents()&&!this.isTouchMode()&&t.target!=this.$root[0]&&this.hideTimeout&&(clearTimeout(this.hideTimeout),this.hideTimeout=0)},winResize:function(t){if(this.handleEvents()){if(!("onorientationchange"in window)||"orientationchange"==t.type){var e=this.isCollapsible();this.wasCollapsible&&e||(this.activatedItems.length&&this.activatedItems[this.activatedItems.length-1][0].blur(),this.menuHideAll()),this.wasCollapsible=e}}else if(this.$disableOverlay){var i=this.$root.offset();this.$disableOverlay.css({top:i.top,left:i.left,width:this.$root.outerWidth(),height:this.$root.outerHeight()})}}}}),$.fn.dataSM=function(t,e){return e?this.data(t+"_smartmenus",e):this.data(t+"_smartmenus")},$.fn.removeDataSM=function(t){return this.removeData(t+"_smartmenus")},$.fn.smartmenus=function(options){if("string"==typeof options){var args=arguments,method=options;return Array.prototype.shift.call(args),this.each(function(){var t=$(this).data("smartmenus");t&&t[method]&&t[method].apply(t,args)})}return this.each(function(){var dataOpts=$(this).data("sm-options")||null;if(dataOpts)try{dataOpts=eval("("+dataOpts+")")}catch(e){dataOpts=null,alert('ERROR\n\nSmartMenus jQuery init:\nInvalid "data-sm-options" attribute value syntax.')}new $.SmartMenus(this,$.extend({},$.fn.smartmenus.defaults,options,dataOpts))})},$.fn.smartmenus.defaults={isPopup:!1,mainMenuSubOffsetX:0,mainMenuSubOffsetY:0,subMenusSubOffsetX:0,subMenusSubOffsetY:0,subMenusMinWidth:"10em",subMenusMaxWidth:"20em",subIndicators:!0,subIndicatorsPos:"append",subIndicatorsText:"",scrollStep:30,scrollAccelerate:!0,showTimeout:250,hideTimeout:500,showDuration:0,showFunction:null,hideDuration:0,hideFunction:function(t,e){t.fadeOut(200,e)},collapsibleShowDuration:0,collapsibleShowFunction:function(t,e){t.slideDown(200,e)},collapsibleHideDuration:0,collapsibleHideFunction:function(t,e){t.slideUp(200,e)},showOnClick:!1,hideOnClick:!0,noMouseOver:!1,keepInViewport:!0,keepHighlighted:!0,markCurrentItem:!1,markCurrentTree:!0,rightToLeftSubMenus:!1,bottomToTopSubMenus:!1,collapsibleBehavior:"default"},$}); \ No newline at end of file diff --git a/doc/libtheora-1.2/menu.js b/doc/libtheora-1.2/menu.js new file mode 100644 index 0000000000000000000000000000000000000000..818b859b7a1c3e57128ac5317ad8088120e2f941 --- /dev/null +++ b/doc/libtheora-1.2/menu.js @@ -0,0 +1,135 @@ +/* + @licstart The following is the entire license notice for the JavaScript code in this file. + + The MIT License (MIT) + + Copyright (C) 1997-2020 by Dimitri van Heesch + + Permission is hereby granted, free of charge, to any person obtaining a copy of this software + and associated documentation files (the "Software"), to deal in the Software without restriction, + including without limitation the rights to use, copy, modify, merge, publish, distribute, + sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is + furnished to do so, subject to the following conditions: + + The above copyright notice and this permission notice shall be included in all copies or + substantial portions of the Software. + + THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING + BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND + NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, + DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + + @licend The above is the entire license notice for the JavaScript code in this file + */ +function initMenu(relPath,searchEnabled,serverSide,searchPage,search) { + function makeTree(data,relPath) { + var result=''; + if ('children' in data) { + result+='
    '; + for (var i in data.children) { + var url; + var link; + link = data.children[i].url; + if (link.substring(0,1)=='^') { + url = link.substring(1); + } else { + url = relPath+link; + } + result+='
  • '+ + data.children[i].text+''+ + makeTree(data.children[i],relPath)+'
  • '; + } + result+='
'; + } + return result; + } + var searchBox; + if (searchEnabled) { + if (serverSide) { + searchBox='
'+ + '
'+ + '
'+ + ''+ + '
'+ + '
'+ + '
'+ + '
'; + } else { + searchBox='
'+ + ''+ + ''+ + ''+ + ''+ + ''+ + '' + '' + '
'; + } + } + + $('#main-nav').before('
'+ + ''+ + ''+ + '
'); + $('#main-nav').append(makeTree(menudata,relPath)); + $('#main-nav').children(':first').addClass('sm sm-dox').attr('id','main-menu'); + if (searchBox) { + $('#main-menu').append('
  • '); + } + var $mainMenuState = $('#main-menu-state'); + var prevWidth = 0; + if ($mainMenuState.length) { + function initResizableIfExists() { + if (typeof initResizable==='function') initResizable(); + } + // animate mobile menu + $mainMenuState.change(function(e) { + var $menu = $('#main-menu'); + var options = { duration: 250, step: initResizableIfExists }; + if (this.checked) { + options['complete'] = function() { $menu.css('display', 'block') }; + $menu.hide().slideDown(options); + } else { + options['complete'] = function() { $menu.css('display', 'none') }; + $menu.show().slideUp(options); + } + }); + // set default menu visibility + function resetState() { + var $menu = $('#main-menu'); + var $mainMenuState = $('#main-menu-state'); + var newWidth = $(window).outerWidth(); + if (newWidth!=prevWidth) { + if ($(window).outerWidth()<768) { + $mainMenuState.prop('checked',false); $menu.hide(); + $('#searchBoxPos1').html(searchBox); + $('#searchBoxPos2').hide(); + } else { + $menu.show(); + $('#searchBoxPos1').empty(); + $('#searchBoxPos2').html(searchBox); + $('#searchBoxPos2').show(); + } + prevWidth = newWidth; + } + } + $(window).ready(function() { resetState(); initResizableIfExists(); }); + $(window).resize(resetState); + } + $('#main-menu').smartmenus(); +} +/* @license-end */ diff --git a/doc/libtheora-1.2/menudata.js b/doc/libtheora-1.2/menudata.js new file mode 100644 index 0000000000000000000000000000000000000000..878996476ea0967de8fac0980e1e8c7fbe4b9284 --- /dev/null +++ b/doc/libtheora-1.2/menudata.js @@ -0,0 +1,87 @@ +/* + @licstart The following is the entire license notice for the JavaScript code in this file. + + The MIT License (MIT) + + Copyright (C) 1997-2020 by Dimitri van Heesch + + Permission is hereby granted, free of charge, to any person obtaining a copy of this software + and associated documentation files (the "Software"), to deal in the Software without restriction, + including without limitation the rights to use, copy, modify, merge, publish, distribute, + sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is + furnished to do so, subject to the following conditions: + + The above copyright notice and this permission notice shall be included in all copies or + substantial portions of the Software. + + THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING + BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND + NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, + DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + + @licend The above is the entire license notice for the JavaScript code in this file +*/ +var menudata={children:[ +{text:"Main Page",url:"index.html"}, +{text:"Modules",url:"modules.html"}, +{text:"Data Structures",url:"annotated.html",children:[ +{text:"Data Structures",url:"annotated.html"}, +{text:"Data Fields",url:"functions.html",children:[ +{text:"All",url:"functions.html",children:[ +{text:"a",url:"functions.html#index_a"}, +{text:"b",url:"functions.html#index_b"}, +{text:"c",url:"functions.html#index_c"}, +{text:"d",url:"functions.html#index_d"}, +{text:"f",url:"functions.html#index_f"}, +{text:"g",url:"functions.html#index_g"}, +{text:"h",url:"functions.html#index_h"}, +{text:"i",url:"functions.html#index_i"}, +{text:"k",url:"functions.html#index_k"}, +{text:"l",url:"functions.html#index_l"}, +{text:"n",url:"functions.html#index_n"}, +{text:"o",url:"functions.html#index_o"}, +{text:"p",url:"functions.html#index_p"}, +{text:"q",url:"functions.html#index_q"}, +{text:"s",url:"functions.html#index_s"}, +{text:"t",url:"functions.html#index_t"}, +{text:"u",url:"functions.html#index_u"}, +{text:"v",url:"functions.html#index_v"}, +{text:"w",url:"functions.html#index_w"}, +{text:"y",url:"functions.html#index_y"}]}, +{text:"Variables",url:"functions_vars.html",children:[ +{text:"a",url:"functions_vars.html#index_a"}, +{text:"b",url:"functions_vars.html#index_b"}, +{text:"c",url:"functions_vars.html#index_c"}, +{text:"d",url:"functions_vars.html#index_d"}, +{text:"f",url:"functions_vars.html#index_f"}, +{text:"g",url:"functions_vars.html#index_g"}, +{text:"h",url:"functions_vars.html#index_h"}, +{text:"i",url:"functions_vars.html#index_i"}, +{text:"k",url:"functions_vars.html#index_k"}, +{text:"l",url:"functions_vars.html#index_l"}, +{text:"n",url:"functions_vars.html#index_n"}, +{text:"o",url:"functions_vars.html#index_o"}, +{text:"p",url:"functions_vars.html#index_p"}, +{text:"q",url:"functions_vars.html#index_q"}, +{text:"s",url:"functions_vars.html#index_s"}, +{text:"t",url:"functions_vars.html#index_t"}, +{text:"u",url:"functions_vars.html#index_u"}, +{text:"v",url:"functions_vars.html#index_v"}, +{text:"w",url:"functions_vars.html#index_w"}, +{text:"y",url:"functions_vars.html#index_y"}]}]}]}, +{text:"Files",url:"files.html",children:[ +{text:"File List",url:"files.html"}, +{text:"Globals",url:"globals.html",children:[ +{text:"All",url:"globals.html",children:[ +{text:"o",url:"globals.html#index_o"}, +{text:"t",url:"globals.html#index_t"}]}, +{text:"Functions",url:"globals_func.html",children:[ +{text:"t",url:"globals_func.html#index_t"}]}, +{text:"Variables",url:"globals_vars.html"}, +{text:"Typedefs",url:"globals_type.html"}, +{text:"Enumerations",url:"globals_enum.html"}, +{text:"Enumerator",url:"globals_eval.html"}, +{text:"Macros",url:"globals_defs.html",children:[ +{text:"o",url:"globals_defs.html#index_o"}, +{text:"t",url:"globals_defs.html#index_t"}]}]}]}]} diff --git a/doc/libtheora-1.2/modules.html b/doc/libtheora-1.2/modules.html index 8328785b73302a82a9bbed50c405521bb619672f..31ad26c86adb256de0f2f035ce83493e21ddd9c0 100644 --- a/doc/libtheora-1.2/modules.html +++ b/doc/libtheora-1.2/modules.html @@ -1,37 +1,59 @@ - + -libtheora: Module Index + + + +libtheora: Modules - + + + - - - +
    Here is a list of all modules:
    +
    + + diff --git a/doc/libtheora-1.2/nav_f.png b/doc/libtheora-1.2/nav_f.png index 1b07a16207e67c95fe2ee17e7016e6d08ac7ac99..72a58a529ed3a9ed6aa0c51a79cf207e026deee2 100644 Binary files a/doc/libtheora-1.2/nav_f.png and b/doc/libtheora-1.2/nav_f.png differ diff --git a/doc/libtheora-1.2/nav_g.png b/doc/libtheora-1.2/nav_g.png new file mode 100644 index 0000000000000000000000000000000000000000..2093a237a94f6c83e19ec6e5fd42f7ddabdafa81 Binary files /dev/null and b/doc/libtheora-1.2/nav_g.png differ diff --git a/doc/libtheora-1.2/nav_h.png b/doc/libtheora-1.2/nav_h.png index 01f5fa6a596e36bd12c2d6ceff1b0169fda7e699..33389b101d9cd9b4c98ad286b5d9c46a6671f650 100644 Binary files a/doc/libtheora-1.2/nav_h.png and b/doc/libtheora-1.2/nav_h.png differ diff --git a/doc/libtheora-1.2/open.png b/doc/libtheora-1.2/open.png index 7b35d2c2c389743089632fe24c3104f2173d97af..30f75c7efe2dd0c9e956e35b69777a02751f048b 100644 Binary files a/doc/libtheora-1.2/open.png and b/doc/libtheora-1.2/open.png differ diff --git a/doc/libtheora-1.2/splitbar.png b/doc/libtheora-1.2/splitbar.png new file mode 100644 index 0000000000000000000000000000000000000000..fe895f2c58179b471a22d8320b39a4bd7312ec8e Binary files /dev/null and b/doc/libtheora-1.2/splitbar.png differ diff --git a/doc/libtheora-1.2/structth__comment.html b/doc/libtheora-1.2/structth__comment.html index a4ba33a63666a7a6b9327d7c30ae5f81ba8a29f3..0afaaa6441fe2ffdb19e01208bcd91db2240bf1c 100644 --- a/doc/libtheora-1.2/structth__comment.html +++ b/doc/libtheora-1.2/structth__comment.html @@ -1,126 +1,148 @@ - + + + + libtheora: th_comment Struct Reference - + + + - -
    - +

    The comment information. -More...

    + More...

    #include <codec.h>

    - - - - - - - - - + + + + + + + + + + + +

    +

    Data Fields

    char ** user_comments
     The array of comment string vectors.
    int * comment_lengths
     An array of the corresponding length of each vector, in bytes.
    int comments
     The total number of comment strings.
    char * vendor
     The null-terminated vendor string.
    char ** user_comments
     The array of comment string vectors. More...
     
    int * comment_lengths
     An array of the corresponding length of each vector, in bytes. More...
     
    int comments
     The total number of comment strings. More...
     
    char * vendor
     The null-terminated vendor string. More...
     
    -

    Detailed Description

    -

    The comment information.

    -

    This structure holds the in-stream metadata corresponding to the 'comment' header packet. The comment header is meant to be used much like someone jotting a quick note on the label of a video. It should be a short, to the point text note that can be more than a couple words, but not more than a short paragraph.

    -

    The metadata is stored as a series of (tag, value) pairs, in length-encoded string vectors. The first occurrence of the '=' character delimits the tag and value. A particular tag may occur more than once, and order is significant. The character set encoding for the strings is always UTF-8, but the tag names are limited to ASCII, and treated as case-insensitive. See the Theora specification, Section 6.3.3 for details.

    -

    In filling in this structure, th_decode_headerin() will null-terminate the user_comment strings for safety. However, the bitstream format itself treats them as 8-bit clean vectors, possibly containing null characters, and so the length array should be treated as their authoritative length.

    -

    Field Documentation

    - +

    Detailed Description

    +

    The comment information.

    +

    This structure holds the in-stream metadata corresponding to the 'comment' header packet. The comment header is meant to be used much like someone jotting a quick note on the label of a video. It should be a short, to the point text note that can be more than a couple words, but not more than a short paragraph.

    +

    The metadata is stored as a series of (tag, value) pairs, in length-encoded string vectors. The first occurrence of the '=' character delimits the tag and value. A particular tag may occur more than once, and order is significant. The character set encoding for the strings is always UTF-8, but the tag names are limited to ASCII, and treated as case-insensitive. See the Theora specification, Section 6.3.3 for details.

    +

    In filling in this structure, th_decode_headerin() will null-terminate the user_comment strings for safety. However, the bitstream format itself treats them as 8-bit clean vectors, possibly containing null characters, so the length array should be treated as their authoritative length.

    +

    Field Documentation

    + +

    ◆ comment_lengths

    +
    - +
    int* th_comment::comment_lengthsint* th_comment::comment_lengths
    -
    -
    +

    An array of the corresponding length of each vector, in bytes.

    - + +

    ◆ comments

    +
    - +
    int th_comment::commentsint th_comment::comments
    -
    -
    +

    The total number of comment strings.

    - + +

    ◆ user_comments

    +
    - +
    char** th_comment::user_commentschar** th_comment::user_comments
    -
    -
    +

    The array of comment string vectors.

    - + +

    ◆ vendor

    +
    - +
    char* th_comment::vendorchar* th_comment::vendor
    -
    -
    +

    The null-terminated vendor string.

    -

    This identifies the software used to encode the stream.

    +

    This identifies the software used to encode the stream.


    The documentation for this struct was generated from the following file: -
    - +
    + + diff --git a/doc/libtheora-1.2/structth__huff__code.html b/doc/libtheora-1.2/structth__huff__code.html index 48611879a843ec2c4d61766ba794241ab625c45f..309434d33367db553c88ddaa86873c7b87693326 100644 --- a/doc/libtheora-1.2/structth__huff__code.html +++ b/doc/libtheora-1.2/structth__huff__code.html @@ -1,79 +1,96 @@ - + + + + libtheora: th_huff_code Struct Reference - + + + - -
    - +

    A Huffman code for a Theora DCT token. -More...

    + More...

    #include <codec.h>

    - - - - - + + + + + +

    +

    Data Fields

    ogg_uint32_t pattern
     The bit pattern for the code, with the LSbit of the pattern aligned in the LSbit of the word.
    int nbits
     The number of bits in the code.
    ogg_uint32_t pattern
     The bit pattern for the code, with the LSbit of the pattern aligned in the LSbit of the word. More...
     
    int nbits
     The number of bits in the code. More...
     
    -

    Detailed Description

    -

    A Huffman code for a Theora DCT token.

    -

    Each set of Huffman codes in a given table must form a complete, prefix-free code. There is no requirement that all the tokens in a table have a valid code, but the current encoder is not optimized to take advantage of this. If each of the five grouops of 16 tables does not contain at least one table with a code for every token, then the encoder may fail to encode certain frames. The complete table in the first group of 16 does not have to be in the same place as the complete table in the other groups, but the complete tables in the remaining four groups must all be in the same place.

    -

    Field Documentation

    - +

    Detailed Description

    +

    A Huffman code for a Theora DCT token.

    +

    Each set of Huffman codes in a given table must form a complete, prefix-free code. There is no requirement that all the tokens in a table have a valid code, but the current encoder is not optimized to take advantage of this. If each of the five grouops of 16 tables does not contain at least one table with a code for every token, then the encoder may fail to encode certain frames. The complete table in the first group of 16 does not have to be in the same place as the complete table in the other groups, but the complete tables in the remaining four groups must all be in the same place.

    +

    Field Documentation

    + +

    ◆ nbits

    +
    - +
    int th_huff_code::nbitsint th_huff_code::nbits
    -
    -
    +

    The number of bits in the code.

    -

    This must be between 0 and 32, inclusive.

    +

    This must be between 0 and 32, inclusive.

    - + +

    ◆ pattern

    +
    - +
    ogg_uint32_t th_huff_code::patternogg_uint32_t th_huff_code::pattern
    -
    -
    +

    The bit pattern for the code, with the LSbit of the pattern aligned in the LSbit of the word.

    @@ -82,9 +99,10 @@ Data Fields
    + + + + + +
    +
    libtheora 1.2.0beta1 +
    +
    + + + + + + +
    -
    -

    th_img_plane Struct Reference

    -
    +
    th_img_plane Struct Reference
    +
    - +

    A buffer for a single color plane in an uncompressed image. -More...

    + More...

    #include <codec.h>

    - - - - - - - - - + + + + + + + + + + + +

    +

    Data Fields

    int width
     The width of this plane.
    int height
     The height of this plane.
    int stride
     The offset in bytes between successive rows.
    unsigned char * data
     A pointer to the beginning of the first row.
    int width
     The width of this plane. More...
     
    int height
     The height of this plane. More...
     
    int stride
     The offset in bytes between successive rows. More...
     
    unsigned char * data
     A pointer to the beginning of the first row. More...
     
    -

    Detailed Description

    -

    A buffer for a single color plane in an uncompressed image.

    -

    This contains the image data in a left-to-right, top-down format. Each row of pixels is stored contiguously in memory, but successive rows need not be. Use stride to compute the offset of the next row. The encoder accepts both positive stride values (top-down in memory) and negative (bottom-up in memory). The decoder currently always generates images with positive strides.

    -

    Field Documentation

    - +

    Detailed Description

    +

    A buffer for a single color plane in an uncompressed image.

    +

    This contains the image data in a left-to-right, top-down format. Each row of pixels is stored contiguously in memory, but successive rows need not be. Use stride to compute the offset of the next row. The encoder accepts both positive stride values (top-down in memory) and negative (bottom-up in memory). The decoder currently always generates images with positive strides.

    +

    Field Documentation

    + +

    ◆ data

    +
    - +
    unsigned char* th_img_plane::dataunsigned char* th_img_plane::data
    -
    -
    +

    A pointer to the beginning of the first row.

    - + +

    ◆ height

    +
    - +
    int th_img_plane::heightint th_img_plane::height
    -
    -
    +

    The height of this plane.

    - + +

    ◆ stride

    +
    - +
    int th_img_plane::strideint th_img_plane::stride
    -
    -
    +

    The offset in bytes between successive rows.

    - + +

    ◆ width

    +
    - +
    int th_img_plane::widthint th_img_plane::width
    -
    -
    +

    The width of this plane.

    @@ -115,9 +136,10 @@ Data Fields
    + + + + + +
    +
    libtheora 1.2.0beta1 +
    +
    + + + + + + +
    - -
    -

    th_info Struct Reference

    -
    +
    th_info Struct Reference
    +
    - +

    Theora bitstream information. -More...

    + More...

    #include <codec.h>

    - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + - - - + + + + - - - + + + + + + + + + + + + + + + + + + + +

    +

    Data Fields

    ogg_uint32_t frame_width
     The encoded frame width.
    ogg_uint32_t frame_height
     The encoded frame height.
    ogg_uint32_t pic_width
     The displayed picture width.
    ogg_uint32_t pic_height
     The displayed picture height.
    ogg_uint32_t pic_x
     The X offset of the displayed picture.
    ogg_uint32_t pic_y
     The Y offset of the displayed picture.
    th_colorspace colorspace
     The color space.
    th_pixel_fmt pixel_fmt
     The pixel format.
    int target_bitrate
     The target bit-rate in bits per second.
    int quality
     The target quality level.
    int keyframe_granule_shift
     The amount to shift to extract the last keyframe number from the granule position.
    Theora version

    Bitstream version information.

    +

    Bitstream version information.

    unsigned char version_major
    unsigned char version_minor
    unsigned char version_subminor
    unsigned char version_major
     
    unsigned char version_minor
     
    unsigned char version_subminor
     
    ogg_uint32_t frame_width
     The encoded frame width. More...
     
    ogg_uint32_t frame_height
     The encoded frame height. More...
     
    ogg_uint32_t pic_width
     The displayed picture width. More...
     
    ogg_uint32_t pic_height
     The displayed picture height. More...
     
    ogg_uint32_t pic_x
     The X offset of the displayed picture. More...
     
    ogg_uint32_t pic_y
     The Y offset of the displayed picture. More...
     
    Frame rate

    The frame rate, as a fraction.

    -

    If either is 0, the frame rate is undefined.

    +

    The frame rate, as a fraction.

    +

    If either is 0, the frame rate is undefined.

    ogg_uint32_t fps_numerator
    ogg_uint32_t fps_denominator
    ogg_uint32_t fps_numerator
     
    ogg_uint32_t fps_denominator
     
    Aspect ratio

    The aspect ratio of the pixels.

    -

    If either value is zero, the aspect ratio is undefined. If not specified by any external means, 1:1 should be assumed. The aspect ratio of the full picture can be computed as

    -
    ogg_uint32_t aspect_numerator
    ogg_uint32_t aspect_denominator

    The aspect ratio of the pixels.

    +

    If either value is zero, the aspect ratio is undefined. If not specified by any external means, 1:1 should be assumed. The aspect ratio of the full picture can be computed as

    +
    ogg_uint32_t aspect_denominator
    Definition: codec.h:255
    +
    ogg_uint32_t pic_width
    The displayed picture width.
    Definition: codec.h:222
    +
    ogg_uint32_t aspect_numerator
    Definition: codec.h:254
    +
    ogg_uint32_t pic_height
    The displayed picture height.
    Definition: codec.h:225
    +
    ogg_uint32_t aspect_numerator
     
    ogg_uint32_t aspect_denominator
     
    th_colorspace colorspace
     The color space. More...
     
    th_pixel_fmt pixel_fmt
     The pixel format. More...
     
    int target_bitrate
     The target bit-rate in bits per second. More...
     
    int quality
     The target quality level. More...
     
    int keyframe_granule_shift
     The amount to shift to extract the last keyframe number from the granule position. More...
     
    -

    Detailed Description

    -

    Theora bitstream information.

    -

    This contains the basic playback parameters for a stream, and corresponds to the initial 'info' header packet. To initialize an encoder, the application fills in this structure and passes it to th_encode_alloc(). A default encoding mode is chosen based on the values of the quality and target_bitrate fields. On decode, it is filled in by th_decode_headerin(), and then passed to th_decode_alloc().

    -

    Encoded Theora frames must be a multiple of 16 in size; this is what the frame_width and frame_height members represent. To handle arbitrary picture sizes, a crop rectangle is specified in the pic_x, pic_y, pic_width and pic_height members.

    -

    All frame buffers contain pointers to the full, padded frame. However, the current encoder will not reference pixels outside of the cropped picture region, and the application does not need to fill them in. The decoder will allocate storage for a full frame, but the application should not rely on the padding containing sensible data.

    -

    It is also generally recommended that the offsets and sizes should still be multiples of 2 to avoid chroma sampling shifts when chroma is sub-sampled. See the Theora specification, Section 4.4, for more details.

    -

    Frame rate, in frames per second, is stored as a rational fraction, as is the pixel aspect ratio. Note that this refers to the aspect ratio of the individual pixels, not of the overall frame itself. The frame aspect ratio can be computed from pixel aspect ratio using the image dimensions.

    -

    Field Documentation

    - +

    Detailed Description

    +

    Theora bitstream information.

    +

    This contains the basic playback parameters for a stream, and corresponds to the initial 'info' header packet. To initialize an encoder, the application fills in this structure and passes it to th_encode_alloc(). A default encoding mode is chosen based on the values of the quality and target_bitrate fields. On decode, it is filled in by th_decode_headerin(), and then passed to th_decode_alloc().

    +

    Encoded Theora frames must be a multiple of 16 in size; this is what the frame_width and frame_height members represent. To handle arbitrary picture sizes, a crop rectangle is specified in the pic_x, pic_y, pic_width and pic_height members.

    +

    All frame buffers contain pointers to the full, padded frame. However, the current encoder will not reference pixels outside of the cropped picture region, and the application does not need to fill them in. The decoder will allocate storage for a full frame, but the application should not rely on the padding containing sensible data.

    +

    It is also generally recommended that the offsets and sizes should still be multiples of 2 to avoid chroma sampling shifts when chroma is sub-sampled. See the Theora specification, Section 4.4, for more details.

    +

    Frame rate, in frames per second, is stored as a rational fraction, as is the pixel aspect ratio. Note that this refers to the aspect ratio of the individual pixels, not of the overall frame itself. The frame aspect ratio can be computed from pixel aspect ratio using the image dimensions.

    +

    Field Documentation

    + +

    ◆ aspect_denominator

    +
    - +
    ogg_uint32_t th_info::aspect_denominatorogg_uint32_t th_info::aspect_denominator
    -
    -
    +
    - + +

    ◆ aspect_numerator

    +
    - +
    ogg_uint32_t th_info::aspect_numeratorogg_uint32_t th_info::aspect_numerator
    -
    -
    +
    - + +

    ◆ colorspace

    +
    -
    +

    The color space.

    - + +

    ◆ fps_denominator

    +
    - +
    ogg_uint32_t th_info::fps_denominatorogg_uint32_t th_info::fps_denominator
    -
    -
    +
    - + +

    ◆ fps_numerator

    +
    - +
    ogg_uint32_t th_info::fps_numeratorogg_uint32_t th_info::fps_numerator
    -
    -
    +
    - + +

    ◆ frame_height

    +
    - +
    ogg_uint32_t th_info::frame_heightogg_uint32_t th_info::frame_height
    -
    -
    +

    The encoded frame height.

    -

    This must be a multiple of 16, and less than 1048576.

    +

    This must be a multiple of 16, and less than 1048576.

    - + +

    ◆ frame_width

    +
    - +
    ogg_uint32_t th_info::frame_widthogg_uint32_t th_info::frame_width
    -
    -
    +

    The encoded frame width.

    -

    This must be a multiple of 16, and less than 1048576.

    +

    This must be a multiple of 16, and less than 1048576.

    - + +

    ◆ keyframe_granule_shift

    +
    - +
    int th_info::keyframe_granule_shiftint th_info::keyframe_granule_shift
    -
    -
    +

    The amount to shift to extract the last keyframe number from the granule position.

    -

    This can be at most 31. th_info_init() will set this to a default value (currently 6, which is good for streaming applications), but you can set it to 0 to make every frame a keyframe. The maximum distance between key frames is 1<<keyframe_granule_shift. The keyframe frequency can be more finely controlled with TH_ENCCTL_SET_KEYFRAME_FREQUENCY_FORCE, which can also be adjusted during encoding (for example, to force the next frame to be a keyframe), but it cannot be set larger than the amount permitted by this field after the headers have been output.

    +

    This can be at most 31. th_info_init() will set this to a default value (currently 6, which is good for streaming applications), but you can set it to 0 to make every frame a keyframe. The maximum distance between key frames is 1<<keyframe_granule_shift. The keyframe frequency can be more finely controlled with TH_ENCCTL_SET_KEYFRAME_FREQUENCY_FORCE, which can also be adjusted during encoding (for example, to force the next frame to be a keyframe), but it cannot be set larger than the amount permitted by this field after the headers have been output.

    - + +

    ◆ pic_height

    +
    - +
    ogg_uint32_t th_info::pic_heightogg_uint32_t th_info::pic_height
    -
    -
    +

    The displayed picture height.

    -

    This must be no larger than height.

    +

    This must be no larger than height.

    - + +

    ◆ pic_width

    +
    - +
    ogg_uint32_t th_info::pic_widthogg_uint32_t th_info::pic_width
    -
    -
    +

    The displayed picture width.

    -

    This must be no larger than width.

    +

    This must be no larger than width.

    - + +

    ◆ pic_x

    +
    - +
    ogg_uint32_t th_info::pic_xogg_uint32_t th_info::pic_x
    -
    -
    +

    The X offset of the displayed picture.

    -

    This must be no larger than frame_width-pic_width or 255, whichever is smaller.

    +

    This must be no larger than frame_width-pic_width or 255, whichever is smaller.

    - + +

    ◆ pic_y

    +
    - +
    ogg_uint32_t th_info::pic_yogg_uint32_t th_info::pic_y
    -
    -
    +

    The Y offset of the displayed picture.

    -

    This must be no larger than frame_height-pic_height, and frame_height-pic_height-pic_y must be no larger than 255. This slightly funny restriction is due to the fact that the offset is specified from the top of the image for consistency with the standard graphics left-handed coordinate system used throughout this API, while it is stored in the encoded stream as an offset from the bottom.

    +

    This must be no larger than frame_height-pic_height, and frame_height-pic_height-pic_y must be no larger than 255. This slightly funny restriction is due to the fact that the offset is specified from the top of the image for consistency with the standard graphics left-handed coordinate system used throughout this API, while it is stored in the encoded stream as an offset from the bottom.

    - + +

    ◆ pixel_fmt

    +
    -
    +

    The pixel format.

    - + +

    ◆ quality

    +
    - +
    int th_info::qualityint th_info::quality
    -
    -
    +

    The target quality level.

    -

    Valid values range from 0 to 63, inclusive, with higher values giving higher quality. If initializing an encoder with this struct, and target_bitrate is set to zero, VBR encoding at this quality will be activated by default.

    +

    Valid values range from 0 to 63, inclusive, with higher values giving higher quality. If initializing an encoder with this struct, and target_bitrate is set to zero, VBR encoding at this quality will be activated by default.

    - + +

    ◆ target_bitrate

    +
    - +
    int th_info::target_bitrateint th_info::target_bitrate
    -
    -
    +

    The target bit-rate in bits per second.

    -

    If initializing an encoder with this struct, set this field to a non-zero value to activate CBR encoding by default.

    +

    If initializing an encoder with this struct, set this field to a non-zero value to activate CBR encoding by default.

    - + +

    ◆ version_major

    +
    - +
    unsigned char th_info::version_majorunsigned char th_info::version_major
    -
    -
    +
    - + +

    ◆ version_minor

    +
    - +
    unsigned char th_info::version_minorunsigned char th_info::version_minor
    -
    -
    +
    - + +

    ◆ version_subminor

    +
    - +
    unsigned char th_info::version_subminorunsigned char th_info::version_subminor
    -
    -
    +

    The documentation for this struct was generated from the following file: -
    - + + + diff --git a/doc/libtheora-1.2/structth__quant__info.html b/doc/libtheora-1.2/structth__quant__info.html index f6505c25fac8009bf69d9698918e788638ac6b83..af0843c686962461a218680ff88d4f61402857d4 100644 --- a/doc/libtheora-1.2/structth__quant__info.html +++ b/doc/libtheora-1.2/structth__quant__info.html @@ -1,128 +1,147 @@ - + + + + libtheora: th_quant_info Struct Reference - + + + - -
    - +

    A complete set of quantization parameters. -More...

    + More...

    #include <codec.h>

    - - - - - - - - - + + + + + + + + + + + +

    +

    Data Fields

    ogg_uint16_t dc_scale [64]
     The DC scaling factors.
    ogg_uint16_t ac_scale [64]
     The AC scaling factors.
    unsigned char loop_filter_limits [64]
     The loop filter limit values.
    th_quant_ranges qi_ranges [2][3]
     The qi ranges for each ci and pli.
    ogg_uint16_t dc_scale [64]
     The DC scaling factors. More...
     
    ogg_uint16_t ac_scale [64]
     The AC scaling factors. More...
     
    unsigned char loop_filter_limits [64]
     The loop filter limit values. More...
     
    th_quant_ranges qi_ranges [2][3]
     The qi ranges for each ci and pli. More...
     
    -

    Detailed Description

    -

    A complete set of quantization parameters.

    -

    The quantizer for each coefficient is calculated as:

    -
        Q=MAX(MIN(qmin[qti][ci!=0],scale[ci!=0][qi]*base[qti][pli][qi][ci]/100),
    -     1024).
    -

    qti is the quantization type index: 0 for intra, 1 for inter. ci!=0 is 0 for the DC coefficient and 1 for AC coefficients. qi is the quality index, ranging between 0 (low quality) and 63 (high quality). pli is the color plane index: 0 for Y', 1 for Cb, 2 for Cr. ci is the DCT coefficient index. Coefficient indices correspond to the normal 2D DCT block ordering--row-major with low frequencies first--not zig-zag order.

    -

    Minimum quantizers are constant, and are given by:

    -
       qmin[2][2]={{4,2},{8,4}}.
    -

    Parameters that can be stored in the bitstream are as follows:

    - -

    Base matrices are stored by reference, so if the same matrices are used multiple times, they will only appear once in the bitstream. The bitstream is also capable of omitting an entire set of ranges and its associated matrices if they are the same as either the previous set (indexed in row-major order) or if the inter set is the same as the intra set.

    -
    + + diff --git a/doc/libtheora-1.2/structth__stripe__callback.html b/doc/libtheora-1.2/structth__stripe__callback.html index 4c5f4b335b67d62375bfb95ef7a9f07cca221cec..d9f0e0c3000bba924bf19fe6f842c77b922d232a 100644 --- a/doc/libtheora-1.2/structth__stripe__callback.html +++ b/doc/libtheora-1.2/structth__stripe__callback.html @@ -1,78 +1,95 @@ - + + + + libtheora: th_stripe_callback Struct Reference - + + + - -
    - +

    The striped decode callback data to pass to TH_DECCTL_SET_STRIPE_CB. -More...

    + More...

    #include <theoradec.h>

    - - - - - + + + + + +

    +

    Data Fields

    void * ctx
     An application-provided context pointer.
    th_stripe_decoded_func stripe_decoded
     The callback function pointer.
    void * ctx
     An application-provided context pointer. More...
     
    th_stripe_decoded_func stripe_decoded
     The callback function pointer. More...
     
    -

    Detailed Description

    -

    The striped decode callback data to pass to TH_DECCTL_SET_STRIPE_CB.

    -

    Field Documentation

    - +

    Detailed Description

    +

    The striped decode callback data to pass to TH_DECCTL_SET_STRIPE_CB.

    +

    Field Documentation

    + +

    ◆ ctx

    +
    - +
    void* th_stripe_callback::ctxvoid* th_stripe_callback::ctx
    -
    -
    +

    An application-provided context pointer.

    -

    This will be passed back verbatim to the application.

    +

    This will be passed back verbatim to the application.

    - + +

    ◆ stripe_decoded

    +
    -
    +

    The callback function pointer.

    @@ -81,9 +98,10 @@ Data Fields
    The documentation for this struct was generated from the following file: -
    - +
    + + diff --git a/doc/libtheora-1.2/structtheora__comment.html b/doc/libtheora-1.2/structtheora__comment.html index 131dca788410018a343fe4355f781575464b9d35..277147e61f46c57547ca7e9103d95a3794a1a55a 100644 --- a/doc/libtheora-1.2/structtheora__comment.html +++ b/doc/libtheora-1.2/structtheora__comment.html @@ -1,117 +1,135 @@ - + + + + libtheora: theora_comment Struct Reference - + + + - -
    - +

    Comment header metadata. -More...

    + More...

    #include <theora.h>

    - - - - - - - - - + + + + + + + + + + + +

    +

    Data Fields

    char ** user_comments
     An array of comment string vectors.
    int * comment_lengths
     An array of corresponding string vector lengths in bytes.
    int comments
     The total number of comment string vectors.
    char * vendor
     The vendor string identifying the encoder, null terminated.
    char ** user_comments
     An array of comment string vectors. More...
     
    int * comment_lengths
     An array of corresponding string vector lengths in bytes. More...
     
    int comments
     The total number of comment string vectors. More...
     
    char * vendor
     The vendor string identifying the encoder, null terminated. More...
     
    -

    Detailed Description

    -

    Comment header metadata.

    -

    This structure holds the in-stream metadata corresponding to the 'comment' header packet.

    -

    Meta data is stored as a series of (tag, value) pairs, in length-encoded string vectors. The first occurence of the '=' character delimits the tag and value. A particular tag may occur more than once. The character set encoding for the strings is always UTF-8, but the tag names are limited to case-insensitive ASCII. See the spec for details.

    -

    In filling in this structure, theora_decode_header() will null-terminate the user_comment strings for safety. However, the bitstream format itself treats them as 8-bit clean, and so the length array should be treated as authoritative for their length.

    -

    Field Documentation

    - +

    Detailed Description

    +

    Comment header metadata.

    +

    This structure holds the in-stream metadata corresponding to the 'comment' header packet.

    +

    Meta data is stored as a series of (tag, value) pairs, in length-encoded string vectors. The first occurence of the '=' character delimits the tag and value. A particular tag may occur more than once. The character set encoding for the strings is always UTF-8, but the tag names are limited to case-insensitive ASCII. See the spec for details.

    +

    In filling in this structure, theora_decode_header() will null-terminate the user_comment strings for safety. However, the bitstream format itself treats them as 8-bit clean, and so the length array should be treated as authoritative for their length.

    +

    Field Documentation

    + +

    ◆ comment_lengths

    +
    - +
    int* theora_comment::comment_lengthsint* theora_comment::comment_lengths
    -
    -
    +

    An array of corresponding string vector lengths in bytes.

    - + +

    ◆ comments

    +
    - +
    int theora_comment::commentsint theora_comment::comments
    -
    -
    +

    The total number of comment string vectors.

    - + +

    ◆ user_comments

    +
    - +
    char** theora_comment::user_commentschar** theora_comment::user_comments
    -
    -
    +

    An array of comment string vectors.

    - + +

    ◆ vendor

    +
    - +
    char* theora_comment::vendorchar* theora_comment::vendor
    -
    -
    +

    The vendor string identifying the encoder, null terminated.

    @@ -120,9 +138,10 @@ Data Fields
    The documentation for this struct was generated from the following file: -
    - +
    + + diff --git a/doc/libtheora-1.2/structtheora__info.html b/doc/libtheora-1.2/structtheora__info.html index cf7a694d87f366947a3e3633cd2dd0c940758069..3e9ff140d49fc4aa4e24c701d8171d6dc1236be9 100644 --- a/doc/libtheora-1.2/structtheora__info.html +++ b/doc/libtheora-1.2/structtheora__info.html @@ -1,498 +1,569 @@ - + + + + libtheora: theora_info Struct Reference - + + + - -
    - +

    Theora bitstream info. -More...

    + More...

    #include <theora.h>

    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +

    +

    Data Fields

    ogg_uint32_t width
     encoded frame width
    ogg_uint32_t height
     encoded frame height
    ogg_uint32_t frame_width
     display frame width
    ogg_uint32_t frame_height
     display frame height
    ogg_uint32_t offset_x
     horizontal offset of the displayed frame
    ogg_uint32_t offset_y
     vertical offset of the displayed frame
    ogg_uint32_t fps_numerator
     frame rate numerator
    ogg_uint32_t fps_denominator
     frame rate denominator
    ogg_uint32_t aspect_numerator
     pixel aspect ratio numerator
    ogg_uint32_t aspect_denominator
     pixel aspect ratio denominator
    theora_colorspace colorspace
     colorspace
    int target_bitrate
     nominal bitrate in bits per second
    int quality
     Nominal quality setting, 0-63.
    int quick_p
     Quick encode/decode.
    unsigned char version_major
    unsigned char version_minor
    unsigned char version_subminor
    void * codec_setup
    int dropframes_p
    int keyframe_auto_p
    ogg_uint32_t keyframe_frequency
    ogg_uint32_t keyframe_frequency_force
    ogg_uint32_t keyframe_data_target_bitrate
    ogg_int32_t keyframe_auto_threshold
    ogg_uint32_t keyframe_mindistance
    ogg_int32_t noise_sensitivity
    ogg_int32_t sharpness
    theora_pixelformat pixelformat
     chroma subsampling mode to expect
    ogg_uint32_t width
     encoded frame width
    + More...
     
    ogg_uint32_t height
     encoded frame height More...
     
    ogg_uint32_t frame_width
     display frame width
    + More...
     
    ogg_uint32_t frame_height
     display frame height More...
     
    ogg_uint32_t offset_x
     horizontal offset of the displayed frame More...
     
    ogg_uint32_t offset_y
     vertical offset of the displayed frame More...
     
    ogg_uint32_t fps_numerator
     frame rate numerator More...
     
    ogg_uint32_t fps_denominator
     frame rate denominator More...
     
    ogg_uint32_t aspect_numerator
     pixel aspect ratio numerator More...
     
    ogg_uint32_t aspect_denominator
     pixel aspect ratio denominator More...
     
    theora_colorspace colorspace
     colorspace More...
     
    int target_bitrate
     nominal bitrate in bits per second More...
     
    int quality
     Nominal quality setting, 0-63. More...
     
    int quick_p
     Quick encode/decode. More...
     
    unsigned char version_major
     
    unsigned char version_minor
     
    unsigned char version_subminor
     
    void * codec_setup
     
    int dropframes_p
     
    int keyframe_auto_p
     
    ogg_uint32_t keyframe_frequency
     
    ogg_uint32_t keyframe_frequency_force
     
    ogg_uint32_t keyframe_data_target_bitrate
     
    ogg_int32_t keyframe_auto_threshold
     
    ogg_uint32_t keyframe_mindistance
     
    ogg_int32_t noise_sensitivity
     
    ogg_int32_t sharpness
     
    theora_pixelformat pixelformat
     chroma subsampling mode to expect More...
     
    -

    Detailed Description

    -

    Theora bitstream info.

    -

    Contains the basic playback parameters for a stream, corresponding to the initial 'info' header packet.

    -

    Encoded theora frames must be a multiple of 16 in width and height. To handle other frame sizes, a crop rectangle is specified in frame_height and frame_width, offset_x and * offset_y. The offset and size should still be a multiple of 2 to avoid chroma sampling shifts. Offset values in this structure are measured from the upper left of the image.

    -

    Frame rate, in frames per second, is stored as a rational fraction. Aspect ratio is also stored as a rational fraction, and refers to the aspect ratio of the frame pixels, not of the overall frame itself.

    -

    See examples/encoder_example.c for usage examples of the other paramters and good default settings for the encoder parameters.

    -

    Field Documentation

    - +

    Detailed Description

    +

    Theora bitstream info.

    +

    Contains the basic playback parameters for a stream, corresponding to the initial 'info' header packet.

    +

    Encoded theora frames must be a multiple of 16 in width and height. To handle other frame sizes, a crop rectangle is specified in frame_height and frame_width, offset_x and * offset_y. The offset and size should still be a multiple of 2 to avoid chroma sampling shifts. Offset values in this structure are measured from the upper left of the image.

    +

    Frame rate, in frames per second, is stored as a rational fraction. Aspect ratio is also stored as a rational fraction, and refers to the aspect ratio of the frame pixels, not of the overall frame itself.

    +

    See examples/encoder_example.c for usage examples of the other parameters and good default settings for the encoder parameters.

    +

    Field Documentation

    + +

    ◆ aspect_denominator

    +
    - +
    ogg_uint32_t theora_info::aspect_denominatorogg_uint32_t theora_info::aspect_denominator
    -
    -
    +

    pixel aspect ratio denominator

    - + +

    ◆ aspect_numerator

    +
    - +
    ogg_uint32_t theora_info::aspect_numeratorogg_uint32_t theora_info::aspect_numerator
    -
    -
    +

    pixel aspect ratio numerator

    - + +

    ◆ codec_setup

    +
    - +
    void* theora_info::codec_setupvoid* theora_info::codec_setup
    -
    -
    +
    - + +

    ◆ colorspace

    +
    -
    +

    colorspace

    - + +

    ◆ dropframes_p

    +
    - +
    int theora_info::dropframes_pint theora_info::dropframes_p
    -
    -
    +
    - + +

    ◆ fps_denominator

    +
    - +
    ogg_uint32_t theora_info::fps_denominatorogg_uint32_t theora_info::fps_denominator
    -
    -
    +

    frame rate denominator

    - + +

    ◆ fps_numerator

    +
    - +
    ogg_uint32_t theora_info::fps_numeratorogg_uint32_t theora_info::fps_numerator
    -
    -
    +

    frame rate numerator

    - + +

    ◆ frame_height

    +
    - +
    ogg_uint32_t theora_info::frame_heightogg_uint32_t theora_info::frame_height
    -
    -
    +

    display frame height

    - + +

    ◆ frame_width

    +
    - +
    ogg_uint32_t theora_info::frame_widthogg_uint32_t theora_info::frame_width
    -
    -
    +
    -

    display frame width

    +

    display frame width
    +

    - + +

    ◆ height

    +
    - +
    ogg_uint32_t theora_info::heightogg_uint32_t theora_info::height
    -
    -
    +

    encoded frame height

    - + +

    ◆ keyframe_auto_p

    +
    - +
    int theora_info::keyframe_auto_pint theora_info::keyframe_auto_p
    -
    -
    +
    - + +

    ◆ keyframe_auto_threshold

    +
    - +
    ogg_int32_t theora_info::keyframe_auto_thresholdogg_int32_t theora_info::keyframe_auto_threshold
    -
    -
    +
    - + +

    ◆ keyframe_data_target_bitrate

    +
    - +
    ogg_uint32_t theora_info::keyframe_data_target_bitrateogg_uint32_t theora_info::keyframe_data_target_bitrate
    -
    -
    +
    - + +

    ◆ keyframe_frequency

    +
    - +
    ogg_uint32_t theora_info::keyframe_frequencyogg_uint32_t theora_info::keyframe_frequency
    -
    -
    +
    - + +

    ◆ keyframe_frequency_force

    +
    - +
    ogg_uint32_t theora_info::keyframe_frequency_forceogg_uint32_t theora_info::keyframe_frequency_force
    -
    -
    +
    - + +

    ◆ keyframe_mindistance

    +
    - +
    ogg_uint32_t theora_info::keyframe_mindistanceogg_uint32_t theora_info::keyframe_mindistance
    -
    -
    +
    - + +

    ◆ noise_sensitivity

    +
    - +
    ogg_int32_t theora_info::noise_sensitivityogg_int32_t theora_info::noise_sensitivity
    -
    -
    +
    - + +

    ◆ offset_x

    +
    - +
    ogg_uint32_t theora_info::offset_xogg_uint32_t theora_info::offset_x
    -
    -
    +

    horizontal offset of the displayed frame

    - + +

    ◆ offset_y

    +
    - +
    ogg_uint32_t theora_info::offset_yogg_uint32_t theora_info::offset_y
    -
    -
    +

    vertical offset of the displayed frame

    - + +

    ◆ pixelformat

    +
    -
    +

    chroma subsampling mode to expect

    - + +

    ◆ quality

    +
    - +
    int theora_info::qualityint theora_info::quality
    -
    -
    +

    Nominal quality setting, 0-63.

    - + +

    ◆ quick_p

    +
    - +
    int theora_info::quick_pint theora_info::quick_p
    -
    -
    +

    Quick encode/decode.

    - + +

    ◆ sharpness

    +
    - +
    ogg_int32_t theora_info::sharpnessogg_int32_t theora_info::sharpness
    -
    -
    +
    - + +

    ◆ target_bitrate

    +
    - +
    int theora_info::target_bitrateint theora_info::target_bitrate
    -
    -
    +

    nominal bitrate in bits per second

    - + +

    ◆ version_major

    +
    - +
    unsigned char theora_info::version_majorunsigned char theora_info::version_major
    -
    -
    +
    - + +

    ◆ version_minor

    +
    - +
    unsigned char theora_info::version_minorunsigned char theora_info::version_minor
    -
    -
    +
    - + +

    ◆ version_subminor

    +
    - +
    unsigned char theora_info::version_subminorunsigned char theora_info::version_subminor
    -
    -
    +
    - + +

    ◆ width

    +
    - +
    ogg_uint32_t theora_info::widthogg_uint32_t theora_info::width
    -
    -
    +
    -

    encoded frame width

    +

    encoded frame width
    +


    The documentation for this struct was generated from the following file: -
    - +
    + + diff --git a/doc/libtheora-1.2/structtheora__state.html b/doc/libtheora-1.2/structtheora__state.html index ef22252fef8008d07bbe1f6c6ed529e69f7ac3d5..be71fbdc4012de17db86fd1e127574287a1cb56f 100644 --- a/doc/libtheora-1.2/structtheora__state.html +++ b/doc/libtheora-1.2/structtheora__state.html @@ -1,113 +1,132 @@ - + + + + libtheora: theora_state Struct Reference - + + + - -
    - +

    Codec internal state and context. -More...

    + More...

    #include <theora.h>

    - - - - - + + + + + + + +

    +

    Data Fields

    theora_infoi
    ogg_int64_t granulepos
    void * internal_encode
    void * internal_decode
    theora_infoi
     
    ogg_int64_t granulepos
     
    void * internal_encode
     
    void * internal_decode
     
    -

    Detailed Description

    -

    Codec internal state and context.

    -

    Field Documentation

    - +

    Detailed Description

    +

    Codec internal state and context.

    +

    Field Documentation

    + +

    ◆ granulepos

    +
    - +
    ogg_int64_t theora_state::granuleposogg_int64_t theora_state::granulepos
    -
    -
    +
    - + +

    ◆ i

    +
    - +
    theora_info* theora_state::itheora_info* theora_state::i
    -
    -
    +
    - + +

    ◆ internal_decode

    +
    - +
    void* theora_state::internal_decodevoid* theora_state::internal_decode
    -
    -
    +
    - + +

    ◆ internal_encode

    +
    - +
    void* theora_state::internal_encodevoid* theora_state::internal_encode
    -
    -
    +

    The documentation for this struct was generated from the following file: -
    - +
    + + diff --git a/doc/libtheora-1.2/structyuv__buffer.html b/doc/libtheora-1.2/structyuv__buffer.html index afa5dd94546c5f8424063c3cdbe8c37d8716743a..070cccd7566170cfa21c1a935bcf5e5b224c6ace 100644 --- a/doc/libtheora-1.2/structyuv__buffer.html +++ b/doc/libtheora-1.2/structyuv__buffer.html @@ -1,203 +1,231 @@ - + + + + libtheora: yuv_buffer Struct Reference - + + + - -
    - +

    A YUV buffer for passing uncompressed frames to and from the codec. -More...

    + More...

    #include <theora.h>

    - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + +

    +

    Data Fields

    int y_width
     Width of the Y' luminance plane.
    int y_height
     Height of the luminance plane.
    int y_stride
     Offset in bytes between successive rows.
    int uv_width
     Width of the Cb and Cr chroma planes.
    int uv_height
     Height of the chroma planes.
    int uv_stride
     Offset between successive chroma rows.
    unsigned char * y
     Pointer to start of luminance data.
    unsigned char * u
     Pointer to start of Cb data.
    unsigned char * v
     Pointer to start of Cr data.
    int y_width
     Width of the Y' luminance plane. More...
     
    int y_height
     Height of the luminance plane. More...
     
    int y_stride
     Offset in bytes between successive rows. More...
     
    int uv_width
     Width of the Cb and Cr chroma planes. More...
     
    int uv_height
     Height of the chroma planes. More...
     
    int uv_stride
     Offset between successive chroma rows. More...
     
    unsigned char * y
     Pointer to start of luminance data. More...
     
    unsigned char * u
     Pointer to start of Cb data. More...
     
    unsigned char * v
     Pointer to start of Cr data. More...
     
    -

    Detailed Description

    -

    A YUV buffer for passing uncompressed frames to and from the codec.

    -

    This holds a Y'CbCr frame in planar format. The CbCr planes can be subsampled and have their own separate dimensions and row stride offsets. Note that the strides may be negative in some configurations. For theora the width and height of the largest plane must be a multiple of 16. The actual meaningful picture size and offset are stored in the theora_info structure; frames returned by the decoder may need to be cropped for display.

    -

    All samples are 8 bits. Within each plane samples are ordered by row from the top of the frame to the bottom. Within each row samples are ordered from left to right.

    -

    During decode, the yuv_buffer struct is allocated by the user, but all fields (including luma and chroma pointers) are filled by the library. These pointers address library-internal memory and their contents should not be modified.

    -

    Conversely, during encode the user allocates the struct and fills out all fields. The user also manages the data addressed by the luma and chroma pointers. See the encoder_example.c and dump_video.c example files in theora/examples/ for more information.

    -

    Field Documentation

    - +

    Detailed Description

    +

    A YUV buffer for passing uncompressed frames to and from the codec.

    +

    This holds a Y'CbCr frame in planar format. The CbCr planes can be subsampled and have their own separate dimensions and row stride offsets. Note that the strides may be negative in some configurations. For theora the width and height of the largest plane must be a multiple of 16. The actual meaningful picture size and offset are stored in the theora_info structure; frames returned by the decoder may need to be cropped for display.

    +

    All samples are 8 bits. Within each plane samples are ordered by row from the top of the frame to the bottom. Within each row samples are ordered from left to right.

    +

    During decode, the yuv_buffer struct is allocated by the user, but all fields (including luma and chroma pointers) are filled by the library. These pointers address library-internal memory and their contents should not be modified.

    +

    Conversely, during encode the user allocates the struct and fills out all fields. The user also manages the data addressed by the luma and chroma pointers. See the encoder_example.c and dump_video.c example files in theora/examples/ for more information.

    +

    Field Documentation

    + +

    ◆ u

    +
    - +
    unsigned char* yuv_buffer::uunsigned char* yuv_buffer::u
    -
    -
    +

    Pointer to start of Cb data.

    - + +

    ◆ uv_height

    +
    - +
    int yuv_buffer::uv_heightint yuv_buffer::uv_height
    -
    -
    +

    Height of the chroma planes.

    - + +

    ◆ uv_stride

    +
    - +
    int yuv_buffer::uv_strideint yuv_buffer::uv_stride
    -
    -
    +

    Offset between successive chroma rows.

    - + +

    ◆ uv_width

    +
    - +
    int yuv_buffer::uv_widthint yuv_buffer::uv_width
    -
    -
    +

    Width of the Cb and Cr chroma planes.

    - + +

    ◆ v

    +
    - +
    unsigned char* yuv_buffer::vunsigned char* yuv_buffer::v
    -
    -
    +

    Pointer to start of Cr data.

    - + +

    ◆ y

    +
    - +
    unsigned char* yuv_buffer::yunsigned char* yuv_buffer::y
    -
    -
    +

    Pointer to start of luminance data.

    - + +

    ◆ y_height

    +
    - +
    int yuv_buffer::y_heightint yuv_buffer::y_height
    -
    -
    +

    Height of the luminance plane.

    - + +

    ◆ y_stride

    +
    - +
    int yuv_buffer::y_strideint yuv_buffer::y_stride
    -
    -
    +

    Offset in bytes between successive rows.

    - + +

    ◆ y_width

    +
    - +
    int yuv_buffer::y_widthint yuv_buffer::y_width
    -
    -
    +

    Width of the Y' luminance plane.

    @@ -206,9 +234,10 @@ Data Fields
    The documentation for this struct was generated from the following file: -
    - +
    + + diff --git a/doc/libtheora-1.2/sync_off.png b/doc/libtheora-1.2/sync_off.png new file mode 100644 index 0000000000000000000000000000000000000000..3b443fc62892114406e3d399421b2a881b897acc Binary files /dev/null and b/doc/libtheora-1.2/sync_off.png differ diff --git a/doc/libtheora-1.2/sync_on.png b/doc/libtheora-1.2/sync_on.png new file mode 100644 index 0000000000000000000000000000000000000000..e08320fb64e6fa33b573005ed6d8fe294e19db76 Binary files /dev/null and b/doc/libtheora-1.2/sync_on.png differ diff --git a/doc/libtheora-1.2/tab_a.png b/doc/libtheora-1.2/tab_a.png index 2d99ef23fed78c7683f0b5aa803d937060d288c4..3b725c41c5a527a3a3e40097077d0e206a681247 100644 Binary files a/doc/libtheora-1.2/tab_a.png and b/doc/libtheora-1.2/tab_a.png differ diff --git a/doc/libtheora-1.2/tab_b.png b/doc/libtheora-1.2/tab_b.png index b2c3d2be3c7e518fbca6bb30f571882e72fc506d..e2b4a8638cb3496a016eaed9e16ffc12846dea18 100644 Binary files a/doc/libtheora-1.2/tab_b.png and b/doc/libtheora-1.2/tab_b.png differ diff --git a/doc/libtheora-1.2/tab_h.png b/doc/libtheora-1.2/tab_h.png index c11f48f19bbe1f178d95397b98075bdd6d989328..fd5cb705488e60fcf30f56fcc951dee74f3b095b 100644 Binary files a/doc/libtheora-1.2/tab_h.png and b/doc/libtheora-1.2/tab_h.png differ diff --git a/doc/libtheora-1.2/tab_s.png b/doc/libtheora-1.2/tab_s.png index 978943ac807718de0e69e5a585a8f0a1e5999285..ab478c95b67371d700a20869f7de1ddd73522d50 100644 Binary files a/doc/libtheora-1.2/tab_s.png and b/doc/libtheora-1.2/tab_s.png differ diff --git a/doc/libtheora-1.2/tabs.css b/doc/libtheora-1.2/tabs.css index 21920562a831f80ad5df7d913b1d3d64db994510..fb0977a521426db2edb63efb2e526f44811f6415 100644 --- a/doc/libtheora-1.2/tabs.css +++ b/doc/libtheora-1.2/tabs.css @@ -1,59 +1 @@ -.tabs, .tabs2, .tabs3 { - background-image: url('tab_b.png'); - width: 100%; - z-index: 101; - font-size: 13px; -} - -.tabs2 { - font-size: 10px; -} -.tabs3 { - font-size: 9px; -} - -.tablist { - margin: 0; - padding: 0; - display: table; -} - -.tablist li { - float: left; - display: table-cell; - background-image: url('tab_b.png'); - line-height: 36px; - list-style: none; -} - -.tablist a { - display: block; - padding: 0 20px; - font-weight: bold; - background-image:url('tab_s.png'); - background-repeat:no-repeat; - background-position:right; - color: #283A5D; - text-shadow: 0px 1px 1px rgba(255, 255, 255, 0.9); - text-decoration: none; - outline: none; -} - -.tabs3 .tablist a { - padding: 0 10px; -} - -.tablist a:hover { - background-image: url('tab_h.png'); - background-repeat:repeat-x; - color: #fff; - text-shadow: 0px 1px 1px rgba(0, 0, 0, 1.0); - text-decoration: none; -} - -.tablist li.current a { - background-image: url('tab_a.png'); - background-repeat:repeat-x; - color: #fff; - text-shadow: 0px 1px 1px rgba(0, 0, 0, 1.0); -} +.sm{position:relative;z-index:9999}.sm,.sm ul,.sm li{display:block;list-style:none;margin:0;padding:0;line-height:normal;direction:ltr;text-align:left;-webkit-tap-highlight-color:rgba(0,0,0,0)}.sm-rtl,.sm-rtl ul,.sm-rtl li{direction:rtl;text-align:right}.sm>li>h1,.sm>li>h2,.sm>li>h3,.sm>li>h4,.sm>li>h5,.sm>li>h6{margin:0;padding:0}.sm ul{display:none}.sm li,.sm a{position:relative}.sm a{display:block}.sm a.disabled{cursor:not-allowed}.sm:after{content:"\00a0";display:block;height:0;font:0px/0 serif;clear:both;visibility:hidden;overflow:hidden}.sm,.sm *,.sm *:before,.sm *:after{-moz-box-sizing:border-box;-webkit-box-sizing:border-box;box-sizing:border-box}.main-menu-btn{position:relative;display:inline-block;width:36px;height:36px;text-indent:36px;margin-left:8px;white-space:nowrap;overflow:hidden;cursor:pointer;-webkit-tap-highlight-color:rgba(0,0,0,0)}.main-menu-btn-icon,.main-menu-btn-icon:before,.main-menu-btn-icon:after{position:absolute;top:50%;left:2px;height:2px;width:24px;background:#666;-webkit-transition:all 0.25s;transition:all 0.25s}.main-menu-btn-icon:before{content:'';top:-7px;left:0}.main-menu-btn-icon:after{content:'';top:7px;left:0}#main-menu-state:checked~.main-menu-btn .main-menu-btn-icon{height:0}#main-menu-state:checked~.main-menu-btn .main-menu-btn-icon:before{top:0;-webkit-transform:rotate(-45deg);transform:rotate(-45deg)}#main-menu-state:checked~.main-menu-btn .main-menu-btn-icon:after{top:0;-webkit-transform:rotate(45deg);transform:rotate(45deg)}#main-menu-state{position:absolute;width:1px;height:1px;margin:-1px;border:0;padding:0;overflow:hidden;clip:rect(1px, 1px, 1px, 1px)}#main-menu-state:not(:checked)~#main-menu{display:none}#main-menu-state:checked~#main-menu{display:block}@media (min-width: 768px){.main-menu-btn{position:absolute;top:-99999px}#main-menu-state:not(:checked)~#main-menu{display:block}}.sm-dox{background-image:url("tab_b.png")}.sm-dox a,.sm-dox a:focus,.sm-dox a:hover,.sm-dox a:active{padding:0px 12px;padding-right:43px;font-family:"Lucida Grande","Geneva","Helvetica",Arial,sans-serif;font-size:13px;font-weight:bold;line-height:36px;text-decoration:none;text-shadow:0px 1px 1px rgba(255,255,255,0.9);color:#283A5D;outline:none}.sm-dox a:hover{background-image:url("tab_a.png");background-repeat:repeat-x;color:#fff;text-shadow:0px 1px 1px #000}.sm-dox a.current{color:#D23600}.sm-dox a.disabled{color:#bbb}.sm-dox a span.sub-arrow{position:absolute;top:50%;margin-top:-14px;left:auto;right:3px;width:28px;height:28px;overflow:hidden;font:bold 12px/28px monospace !important;text-align:center;text-shadow:none;background:rgba(255,255,255,0.5);border-radius:5px}.sm-dox a span.sub-arrow:before{display:block;content:'+'}.sm-dox a.highlighted span.sub-arrow:before{display:block;content:'-'}.sm-dox>li:first-child>a,.sm-dox>li:first-child>:not(ul) a{border-radius:5px 5px 0 0}.sm-dox>li:last-child>a,.sm-dox>li:last-child>*:not(ul) a,.sm-dox>li:last-child>ul,.sm-dox>li:last-child>ul>li:last-child>a,.sm-dox>li:last-child>ul>li:last-child>*:not(ul) a,.sm-dox>li:last-child>ul>li:last-child>ul,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>a,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>*:not(ul) a,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>a,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>*:not(ul) a,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>ul,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>a,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>*:not(ul) a,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>ul{border-radius:0 0 5px 5px}.sm-dox>li:last-child>a.highlighted,.sm-dox>li:last-child>*:not(ul) a.highlighted,.sm-dox>li:last-child>ul>li:last-child>a.highlighted,.sm-dox>li:last-child>ul>li:last-child>*:not(ul) a.highlighted,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>a.highlighted,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>*:not(ul) a.highlighted,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>a.highlighted,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>*:not(ul) a.highlighted,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>a.highlighted,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>*:not(ul) a.highlighted{border-radius:0}.sm-dox ul{background:rgba(162,162,162,0.1)}.sm-dox ul a,.sm-dox ul a:focus,.sm-dox ul a:hover,.sm-dox ul a:active{font-size:12px;border-left:8px solid transparent;line-height:36px;text-shadow:none;background-color:white;background-image:none}.sm-dox ul a:hover{background-image:url("tab_a.png");background-repeat:repeat-x;color:#fff;text-shadow:0px 1px 1px #000}.sm-dox ul ul a,.sm-dox ul ul a:hover,.sm-dox ul ul a:focus,.sm-dox ul ul a:active{border-left:16px solid transparent}.sm-dox ul ul ul a,.sm-dox ul ul ul a:hover,.sm-dox ul ul ul a:focus,.sm-dox ul ul ul a:active{border-left:24px solid transparent}.sm-dox ul ul ul ul a,.sm-dox ul ul ul ul a:hover,.sm-dox ul ul ul ul a:focus,.sm-dox ul ul ul ul a:active{border-left:32px solid transparent}.sm-dox ul ul ul ul ul a,.sm-dox ul ul ul ul ul a:hover,.sm-dox ul ul ul ul ul a:focus,.sm-dox ul ul ul ul ul a:active{border-left:40px solid transparent}@media (min-width: 768px){.sm-dox ul{position:absolute;width:12em}.sm-dox li{float:left}.sm-dox.sm-rtl li{float:right}.sm-dox ul li,.sm-dox.sm-rtl ul li,.sm-dox.sm-vertical li{float:none}.sm-dox a{white-space:nowrap}.sm-dox ul a,.sm-dox.sm-vertical a{white-space:normal}.sm-dox .sm-nowrap>li>a,.sm-dox .sm-nowrap>li>:not(ul) a{white-space:nowrap}.sm-dox{padding:0 10px;background-image:url("tab_b.png");line-height:36px}.sm-dox a span.sub-arrow{top:50%;margin-top:-2px;right:12px;width:0;height:0;border-width:4px;border-style:solid dashed dashed dashed;border-color:#283A5D transparent transparent transparent;background:transparent;border-radius:0}.sm-dox a,.sm-dox a:focus,.sm-dox a:active,.sm-dox a:hover,.sm-dox a.highlighted{padding:0px 12px;background-image:url("tab_s.png");background-repeat:no-repeat;background-position:right;border-radius:0 !important}.sm-dox a:hover{background-image:url("tab_a.png");background-repeat:repeat-x;color:#fff;text-shadow:0px 1px 1px #000}.sm-dox a:hover span.sub-arrow{border-color:#fff transparent transparent transparent}.sm-dox a.has-submenu{padding-right:24px}.sm-dox li{border-top:0}.sm-dox>li>ul:before,.sm-dox>li>ul:after{content:'';position:absolute;top:-18px;left:30px;width:0;height:0;overflow:hidden;border-width:9px;border-style:dashed dashed solid dashed;border-color:transparent transparent #bbb transparent}.sm-dox>li>ul:after{top:-16px;left:31px;border-width:8px;border-color:transparent transparent #fff transparent}.sm-dox ul{border:1px solid #bbb;padding:5px 0;background:#fff;border-radius:5px !important;box-shadow:0 5px 9px rgba(0,0,0,0.2)}.sm-dox ul a span.sub-arrow{right:8px;top:50%;margin-top:-5px;border-width:5px;border-color:transparent transparent transparent #555;border-style:dashed dashed dashed solid}.sm-dox ul a,.sm-dox ul a:hover,.sm-dox ul a:focus,.sm-dox ul a:active,.sm-dox ul a.highlighted{color:#555;background-image:none;border:0 !important;color:#555;background-image:none}.sm-dox ul a:hover{background-image:url("tab_a.png");background-repeat:repeat-x;color:#fff;text-shadow:0px 1px 1px #000}.sm-dox ul a:hover span.sub-arrow{border-color:transparent transparent transparent #fff}.sm-dox span.scroll-up,.sm-dox span.scroll-down{position:absolute;display:none;visibility:hidden;overflow:hidden;background:#fff;height:36px}.sm-dox span.scroll-up:hover,.sm-dox span.scroll-down:hover{background:#eee}.sm-dox span.scroll-up:hover span.scroll-up-arrow,.sm-dox span.scroll-up:hover span.scroll-down-arrow{border-color:transparent transparent #D23600 transparent}.sm-dox span.scroll-down:hover span.scroll-down-arrow{border-color:#D23600 transparent transparent transparent}.sm-dox span.scroll-up-arrow,.sm-dox span.scroll-down-arrow{position:absolute;top:0;left:50%;margin-left:-6px;width:0;height:0;overflow:hidden;border-width:6px;border-style:dashed dashed solid dashed;border-color:transparent transparent #555 transparent}.sm-dox span.scroll-down-arrow{top:8px;border-style:solid dashed dashed dashed;border-color:#555 transparent transparent transparent}.sm-dox.sm-rtl a.has-submenu{padding-right:12px;padding-left:24px}.sm-dox.sm-rtl a span.sub-arrow{right:auto;left:12px}.sm-dox.sm-rtl.sm-vertical a.has-submenu{padding:10px 20px}.sm-dox.sm-rtl.sm-vertical a span.sub-arrow{right:auto;left:8px;border-style:dashed solid dashed dashed;border-color:transparent #555 transparent transparent}.sm-dox.sm-rtl>li>ul:before{left:auto;right:30px}.sm-dox.sm-rtl>li>ul:after{left:auto;right:31px}.sm-dox.sm-rtl ul a.has-submenu{padding:10px 20px !important}.sm-dox.sm-rtl ul a span.sub-arrow{right:auto;left:8px;border-style:dashed solid dashed dashed;border-color:transparent #555 transparent transparent}.sm-dox.sm-vertical{padding:10px 0;border-radius:5px}.sm-dox.sm-vertical a{padding:10px 20px}.sm-dox.sm-vertical a:hover,.sm-dox.sm-vertical a:focus,.sm-dox.sm-vertical a:active,.sm-dox.sm-vertical a.highlighted{background:#fff}.sm-dox.sm-vertical a.disabled{background-image:url("tab_b.png")}.sm-dox.sm-vertical a span.sub-arrow{right:8px;top:50%;margin-top:-5px;border-width:5px;border-style:dashed dashed dashed solid;border-color:transparent transparent transparent #555}.sm-dox.sm-vertical>li>ul:before,.sm-dox.sm-vertical>li>ul:after{display:none}.sm-dox.sm-vertical ul a{padding:10px 20px}.sm-dox.sm-vertical ul a:hover,.sm-dox.sm-vertical ul a:focus,.sm-dox.sm-vertical ul a:active,.sm-dox.sm-vertical ul a.highlighted{background:#eee}.sm-dox.sm-vertical ul a.disabled{background:#fff}} diff --git a/doc/libtheora-1.2/theora_8h.html b/doc/libtheora-1.2/theora_8h.html index 7961f2623289ad3fb7c7fc4dbe1e2b67ea1bb1d9..879ad4859314408b349b665fa9cff12b19f1d967 100644 --- a/doc/libtheora-1.2/theora_8h.html +++ b/doc/libtheora-1.2/theora_8h.html @@ -1,230 +1,1775 @@ - + + + + libtheora: theora.h File Reference - + + + - - +
    theora.h File Reference
    +

    The libtheora pre-1.0 legacy C API. -More...

    -#include <stddef.h>
    -#include <ogg/ogg.h>
    - +More...

    +
    #include <stddef.h>
    +#include <ogg/ogg.h>
    +

    Go to the source code of this file.

    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + +

    +

    Data Structures

    struct  yuv_buffer
     A YUV buffer for passing uncompressed frames to and from the codec. More...
    struct  theora_info
     Theora bitstream info. More...
    struct  theora_state
     Codec internal state and context. More...
    struct  theora_comment
     Comment header metadata. More...

    -Defines

    #define OC_FAULT   -1
     General failure.
    #define OC_EINVAL   -10
     Library encountered invalid internal data.
    #define OC_DISABLED   -11
     Requested action is disabled.
    #define OC_BADHEADER   -20
     Header packet was corrupt/invalid.
    #define OC_NOTFORMAT   -21
     Packet is not a theora packet.
    #define OC_VERSION   -22
     Bitstream version is not handled.
    #define OC_IMPL   -23
     Feature or action not implemented.
    #define OC_BADPACKET   -24
     Packet is corrupt.
    #define OC_NEWPACKET   -25
     Packet is an (ignorable) unhandled extension.
    #define OC_DUPFRAME   1
     Packet is a dropped frame.
    theora_control() codes

    -
    #define TH_DECCTL_GET_PPLEVEL_MAX   (1)
     Get the maximum post-processing level.
    #define TH_DECCTL_SET_PPLEVEL   (3)
     Set the post-processing level.
    #define TH_ENCCTL_SET_KEYFRAME_FREQUENCY_FORCE   (4)
     Sets the maximum distance between key frames.
    #define TH_DECCTL_SET_GRANPOS   (5)
     Set the granule position.
    #define TH_ENCCTL_SET_QUANT_PARAMS   (2)
     Sets the quantization parameters to use.
    #define TH_ENCCTL_SET_VP3_COMPATIBLE   (10)
     Disables any encoder features that would prevent lossless transcoding back to VP3.
    #define TH_ENCCTL_GET_SPLEVEL_MAX   (12)
     Gets the maximum speed level.
    #define TH_ENCCTL_SET_SPLEVEL   (14)
     Sets the speed level.

    +

    struct  yuv_buffer
     A YUV buffer for passing uncompressed frames to and from the codec. More...
     
    struct  theora_info
     Theora bitstream info. More...
     
    struct  theora_state
     Codec internal state and context. More...
     
    struct  theora_comment
     Comment header metadata. More...
     
    + - - - + + +

    Typedefs

    typedef struct theora_comment theora_comment
     Comment header metadata.

    +

    typedef struct theora_comment theora_comment
     Comment header metadata. More...
     
    + - - - + + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + +

    Enumerations

    enum  theora_colorspace { OC_CS_UNSPECIFIED, -OC_CS_ITU_REC_470M, -OC_CS_ITU_REC_470BG, -OC_CS_NSPACES +
    enum  theora_colorspace { OC_CS_UNSPECIFIED +, OC_CS_ITU_REC_470M +, OC_CS_ITU_REC_470BG +, OC_CS_NSPACES }
     

    A Colorspace.

    - More...
    enum  theora_pixelformat { OC_PF_420, -OC_PF_RSVD, -OC_PF_422, -OC_PF_444 +
     A Colorspace. More...
     
    enum  theora_pixelformat { OC_PF_420 +, OC_PF_RSVD +, OC_PF_422 +, OC_PF_444 }
     

    A Chroma subsampling.

    - More...

    -Functions

    const char * theora_version_string (void)
     Retrieve a human-readable string to identify the encoder vendor and version.
    ogg_uint32_t theora_version_number (void)
     Retrieve a 32-bit version number.
    int theora_encode_init (theora_state *th, theora_info *ti)
     Initialize the theora encoder.
    int theora_encode_YUVin (theora_state *t, yuv_buffer *yuv)
     Submit a YUV buffer to the theora encoder.
    int theora_encode_packetout (theora_state *t, int last_p, ogg_packet *op)
     Request the next packet of encoded video.
    int theora_encode_header (theora_state *t, ogg_packet *op)
     Request a packet containing the initial header.
    int theora_encode_comment (theora_comment *tc, ogg_packet *op)
     Request a comment header packet from provided metadata.
    int theora_encode_tables (theora_state *t, ogg_packet *op)
     Request a packet containing the codebook tables for the stream.
    int theora_decode_header (theora_info *ci, theora_comment *cc, ogg_packet *op)
     Decode an Ogg packet, with the expectation that the packet contains an initial header, comment data or codebook tables.
    int theora_decode_init (theora_state *th, theora_info *c)
     Initialize a theora_state handle for decoding.
    int theora_decode_packetin (theora_state *th, ogg_packet *op)
     Input a packet containing encoded data into the theora decoder.
    int theora_decode_YUVout (theora_state *th, yuv_buffer *yuv)
     Output the next available frame of decoded YUV data.
    int theora_packet_isheader (ogg_packet *op)
     Report whether a theora packet is a header or not This function does no verification beyond checking the header flag bit so it should not be used for bitstream identification; use theora_decode_header() for that.
    int theora_packet_iskeyframe (ogg_packet *op)
     Report whether a theora packet is a keyframe or not.
    int theora_granule_shift (theora_info *ti)
     Report the granulepos shift radix.
    ogg_int64_t theora_granule_frame (theora_state *th, ogg_int64_t granulepos)
     Convert a granulepos to an absolute frame index, starting at 0.
    double theora_granule_time (theora_state *th, ogg_int64_t granulepos)
     Convert a granulepos to absolute time in seconds.
    void theora_info_init (theora_info *c)
     Initialize a theora_info structure.
    void theora_info_clear (theora_info *c)
     Clear a theora_info structure.
    void theora_clear (theora_state *t)
     Free all internal data associated with a theora_state handle.
    void theora_comment_init (theora_comment *tc)
     Initialize an allocated theora_comment structure.
    void theora_comment_add (theora_comment *tc, char *comment)
     Add a comment to an initialized theora_comment structure.
    void theora_comment_add_tag (theora_comment *tc, char *tag, char *value)
     Add a comment to an initialized theora_comment structure.
    char * theora_comment_query (theora_comment *tc, char *tag, int count)
     Look up a comment value by tag.
    int theora_comment_query_count (theora_comment *tc, char *tag)
     Look up the number of instances of a tag.
    void theora_comment_clear (theora_comment *tc)
     Clear an allocated theora_comment struct so that it can be freed.
    int theora_control (theora_state *th, int req, void *buf, size_t buf_sz)
     Encoder control function.
     A Chroma subsampling. More...
     
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +

    theora_control() codes

    #define TH_DECCTL_GET_PPLEVEL_MAX   (1)
     Get the maximum post-processing level. More...
     
    #define TH_DECCTL_SET_PPLEVEL   (3)
     Set the post-processing level. More...
     
    #define TH_ENCCTL_SET_KEYFRAME_FREQUENCY_FORCE   (4)
     Sets the maximum distance between key frames. More...
     
    #define TH_DECCTL_SET_GRANPOS   (5)
     Set the granule position. More...
     
    #define TH_ENCCTL_SET_QUANT_PARAMS   (2)
      More...
     
    #define TH_ENCCTL_SET_VP3_COMPATIBLE   (10)
     Disables any encoder features that would prevent lossless transcoding back to VP3. More...
     
    #define TH_ENCCTL_GET_SPLEVEL_MAX   (12)
     Gets the maximum speed level. More...
     
    #define TH_ENCCTL_SET_SPLEVEL   (14)
     Sets the speed level. More...
     
    #define OC_FAULT   -1
     General failure. More...
     
    #define OC_EINVAL   -10
     Library encountered invalid internal data. More...
     
    #define OC_DISABLED   -11
     Requested action is disabled. More...
     
    #define OC_BADHEADER   -20
     Header packet was corrupt/invalid. More...
     
    #define OC_NOTFORMAT   -21
     Packet is not a theora packet. More...
     
    #define OC_VERSION   -22
     Bitstream version is not handled. More...
     
    #define OC_IMPL   -23
     Feature or action not implemented. More...
     
    #define OC_BADPACKET   -24
     Packet is corrupt. More...
     
    #define OC_NEWPACKET   -25
     Packet is an (ignorable) unhandled extension. More...
     
    #define OC_DUPFRAME   1
     Packet is a dropped frame. More...
     
    const char * theora_version_string (void)
     Retrieve a human-readable string to identify the encoder vendor and version. More...
     
    ogg_uint32_t theora_version_number (void)
     Retrieve a 32-bit version number. More...
     
    int theora_encode_init (theora_state *th, theora_info *ti)
     Initialize the theora encoder. More...
     
    int theora_encode_YUVin (theora_state *t, yuv_buffer *yuv)
     Submit a YUV buffer to the theora encoder. More...
     
    int theora_encode_packetout (theora_state *t, int last_p, ogg_packet *op)
     Request the next packet of encoded video. More...
     
    int theora_encode_header (theora_state *t, ogg_packet *op)
     Request a packet containing the initial header. More...
     
    int theora_encode_comment (theora_comment *tc, ogg_packet *op)
     Request a comment header packet from provided metadata. More...
     
    int theora_encode_tables (theora_state *t, ogg_packet *op)
     Request a packet containing the codebook tables for the stream. More...
     
    int theora_decode_header (theora_info *ci, theora_comment *cc, ogg_packet *op)
     Decode an Ogg packet, with the expectation that the packet contains an initial header, comment data or codebook tables. More...
     
    int theora_decode_init (theora_state *th, theora_info *c)
     Initialize a theora_state handle for decoding. More...
     
    int theora_decode_packetin (theora_state *th, ogg_packet *op)
     Input a packet containing encoded data into the theora decoder. More...
     
    int theora_decode_YUVout (theora_state *th, yuv_buffer *yuv)
     Output the next available frame of decoded YUV data. More...
     
    int theora_packet_isheader (ogg_packet *op)
     Report whether a theora packet is a header or not This function does no verification beyond checking the header flag bit so it should not be used for bitstream identification; use theora_decode_header() for that. More...
     
    int theora_packet_iskeyframe (ogg_packet *op)
     Report whether a theora packet is a keyframe or not. More...
     
    int theora_granule_shift (theora_info *ti)
     Report the granulepos shift radix. More...
     
    ogg_int64_t theora_granule_frame (theora_state *th, ogg_int64_t granulepos)
     Convert a granulepos to an absolute frame index, starting at 0. More...
     
    double theora_granule_time (theora_state *th, ogg_int64_t granulepos)
     Convert a granulepos to absolute time in seconds. More...
     
    void theora_info_init (theora_info *c)
     Initialize a theora_info structure. More...
     
    void theora_info_clear (theora_info *c)
     Clear a theora_info structure. More...
     
    void theora_clear (theora_state *t)
     Free all internal data associated with a theora_state handle. More...
     
    void theora_comment_init (theora_comment *tc)
     Initialize an allocated theora_comment structure. More...
     
    void theora_comment_add (theora_comment *tc, char *comment)
     Add a comment to an initialized theora_comment structure. More...
     
    void theora_comment_add_tag (theora_comment *tc, char *tag, char *value)
     Add a comment to an initialized theora_comment structure. More...
     
    char * theora_comment_query (theora_comment *tc, char *tag, int count)
     Look up a comment value by tag. More...
     
    int theora_comment_query_count (theora_comment *tc, char *tag)
     Look up the number of instances of a tag. More...
     
    void theora_comment_clear (theora_comment *tc)
     Clear an allocated theora_comment struct so that it can be freed. More...
     
    int theora_control (theora_state *th, int req, void *buf, size_t buf_sz)
     Encoder control function. More...
     
    -

    Detailed Description

    -

    The libtheora pre-1.0 legacy C API.

    -

    -Introduction

    -

    This is the documentation for the libtheora legacy C API, declared in the theora.h header, which describes the old interface used before the 1.0 release. This API was widely deployed for several years and remains supported, but for new code we recommend the cleaner API declared in theoradec.h and theoraenc.h.

    -

    libtheora is the reference implementation for Theora, a free video codec. Theora is derived from On2's VP3 codec with improved integration with Ogg multimedia formats by Xiph.Org.

    -

    -Overview

    -

    This library will both decode and encode theora packets to/from raw YUV frames. In either case, the packets will most likely either come from or need to be embedded in an Ogg stream. Use libogg or liboggz to extract/package these packets.

    -

    -Decoding Process

    -

    Decoding can be separated into the following steps:

    -
      -
    1. initialise theora_info and theora_comment structures using theora_info_init() and theora_comment_init():
      - theora_info     info;
      - theora_comment  comment;
      -   
      - theora_info_init(&info);
      - theora_comment_init(&comment);
      - 
    2. -
    3. retrieve header packets from Ogg stream (there should be 3) and decode into theora_info and theora_comment structures using theora_decode_header(). See Identifying Theora Packets for more information on identifying which packets are theora packets.
      - int i;
      - for (i = 0; i < 3; i++)
      - {
      -   (get a theora packet "op" from the Ogg stream)
      -   theora_decode_header(&info, &comment, op);
      - }
      - 
    4. -
    5. initialise the decoder based on the information retrieved into the theora_info struct by theora_decode_header(). You will need a theora_state struct.
      - theora_state state;
      - 
      - theora_decode_init(&state, &info);
      - 
    6. -
    7. pass in packets and retrieve decoded frames! See the yuv_buffer documentation for information on how to retrieve raw YUV data.
      - yuf_buffer buffer;
      - while (last packet was not e_o_s) {
      -   (get a theora packet "op" from the Ogg stream)
      -   theora_decode_packetin(&state, op);
      -   theora_decode_YUVout(&state, &buffer);
      - }
      - 
    8. +

      Detailed Description

      +

      The libtheora pre-1.0 legacy C API.

      +

      +Introduction

      +

      This is the documentation for the libtheora legacy C API, declared in the theora.h header, which describes the old interface used before the 1.0 release. This API was widely deployed for several years and remains supported, but for new code we recommend the cleaner API declared in theoradec.h and theoraenc.h.

      +

      libtheora is the reference implementation for Theora, a free video codec. Theora is derived from On2's VP3 codec with improved integration with Ogg multimedia formats by Xiph.Org.

      +

      +Overview

      +

      This library will both decode and encode theora packets to/from raw YUV frames. In either case, the packets will most likely either come from or need to be embedded in an Ogg stream. Use libogg or liboggz to extract/package these packets.

      +

      +Decoding Process

      +

      Decoding can be separated into the following steps:

        +
      1. initialise theora_info and theora_comment structures using theora_info_init() and theora_comment_init():
        theora_info     info;
        +theora_comment  comment;
        +
        +theora_info_init(&info);
        +theora_comment_init(&comment);
        +
      2. +
      3. retrieve header packets from Ogg stream (there should be 3) and decode into theora_info and theora_comment structures using theora_decode_header(). See Identifying Theora Packets for more information on identifying which packets are theora packets.
        int i;
        +for (i = 0; i < 3; i++)
        +{
        +  (get a theora packet "op" from the Ogg stream)
        +  theora_decode_header(&info, &comment, op);
        +}
        +
      4. +
      5. initialise the decoder based on the information retrieved into the theora_info struct by theora_decode_header(). You will need a theora_state struct.
        theora_state state;
        +
        +theora_decode_init(&state, &info);
        +
      6. +
      7. pass in packets and retrieve decoded frames! See the yuv_buffer documentation for information on how to retrieve raw YUV data.
        yuf_buffer buffer;
        +while (last packet was not e_o_s) {
        +  (get a theora packet "op" from the Ogg stream)
        +  theora_decode_packetin(&state, op);
        +  theora_decode_YUVout(&state, &buffer);
        +}
        +
      -

      -Identifying Theora Packets

      -

      All streams inside an Ogg file have a unique serial_no attached to the stream. Typically, you will want to

      -
        +

        +Identifying Theora Packets

        +

        All streams inside an Ogg file have a unique serial_no attached to the stream. Typically, you will want to

        • retrieve the serial_no for each b_o_s (beginning of stream) page encountered within the Ogg file;
        • test the first (only) packet on that page to determine if it is a theora packet;
        • once you have found a theora b_o_s page then use the retrieved serial_no to identify future packets belonging to the same theora stream.
        -

        Note that you cannot use theora_packet_isheader() to determine if a packet is a theora packet or not, as this function does not perform any checking beyond whether a header bit is present. Instead, use the theora_decode_header() function and check the return value; or examine the header bytes at the beginning of the Ogg page.

        +

        Note that you cannot use theora_packet_isheader() to determine if a packet is a theora packet or not, as this function does not perform any checking beyond whether a header bit is present. Instead, use the theora_decode_header() function and check the return value; or examine the header bytes at the beginning of the Ogg page.

        +

      Macro Definition Documentation

      + +

      ◆ OC_BADHEADER

      + +
      +
      + + + + +
      #define OC_BADHEADER   -20
      +
      + +

      Header packet was corrupt/invalid.

      + +
      +
      + +

      ◆ OC_BADPACKET

      + +
      +
      + + + + +
      #define OC_BADPACKET   -24
      +
      + +

      Packet is corrupt.

      + +
      +
      + +

      ◆ OC_DISABLED

      + +
      +
      + + + + +
      #define OC_DISABLED   -11
      +
      + +

      Requested action is disabled.

      + +
      +
      + +

      ◆ OC_DUPFRAME

      + +
      +
      + + + + +
      #define OC_DUPFRAME   1
      +
      + +

      Packet is a dropped frame.

      + +
      +
      + +

      ◆ OC_EINVAL

      + +
      +
      + + + + +
      #define OC_EINVAL   -10
      +
      + +

      Library encountered invalid internal data.

      + +
      +
      + +

      ◆ OC_FAULT

      + +
      +
      + + + + +
      #define OC_FAULT   -1
      +
      + +

      General failure.

      + +
      +
      + +

      ◆ OC_IMPL

      + +
      +
      + + + + +
      #define OC_IMPL   -23
      +
      + +

      Feature or action not implemented.

      + +
      +
      + +

      ◆ OC_NEWPACKET

      + +
      +
      + + + + +
      #define OC_NEWPACKET   -25
      +
      + +

      Packet is an (ignorable) unhandled extension.

      + +
      +
      + +

      ◆ OC_NOTFORMAT

      + +
      +
      + + + + +
      #define OC_NOTFORMAT   -21
      +
      + +

      Packet is not a theora packet.

      + +
      +
      + +

      ◆ OC_VERSION

      + +
      +
      + + + + +
      #define OC_VERSION   -22
      +
      + +

      Bitstream version is not handled.

      + +
      +
      + +

      ◆ TH_DECCTL_GET_PPLEVEL_MAX

      + +
      +
      + + + + +
      #define TH_DECCTL_GET_PPLEVEL_MAX   (1)
      +
      + +

      Get the maximum post-processing level.

      +

      The decoder supports a post-processing filter that can improve the appearance of the decoded images. This returns the highest level setting for this post-processor, corresponding to maximum improvement and computational expense.

      + +
      +
      + +

      ◆ TH_DECCTL_SET_GRANPOS

      + +
      +
      + + + + +
      #define TH_DECCTL_SET_GRANPOS   (5)
      +
      + +

      Set the granule position.

      +

      Call this after a seek, to update the internal granulepos in the decoder, to insure that subsequent frames are marked properly. If you track timestamps yourself and do not use the granule postion returned by the decoder, then you do not need to use this control.

      + +
      +
      + +

      ◆ TH_DECCTL_SET_PPLEVEL

      + +
      +
      + + + + +
      #define TH_DECCTL_SET_PPLEVEL   (3)
      +
      + +

      Set the post-processing level.

      +

      Sets the level of post-processing to use when decoding the compressed stream. This must be a value between zero (off) and the maximum returned by TH_DECCTL_GET_PPLEVEL_MAX.

      + +
      +
      + +

      ◆ TH_ENCCTL_GET_SPLEVEL_MAX

      + +
      +
      + + + + +
      #define TH_ENCCTL_GET_SPLEVEL_MAX   (12)
      +
      + +

      Gets the maximum speed level.

      +

      Higher speed levels favor quicker encoding over better quality per bit. Depending on the encoding mode, and the internal algorithms used, quality may actually improve, but in this case bitrate will also likely increase. In any case, overall rate/distortion performance will probably decrease. The maximum value, and the meaning of each value, may change depending on the current encoding mode (VBR vs. CQI, etc.).

      +
      Parameters
      + + +
      [out]bufint: The maximum encoding speed level.
      +
      +
      +
      Return values
      + + + + +
      OC_FAULTtheora_state or buf is NULL.
      OC_EINVALbuf_sz is not sizeof(int).
      OC_IMPLNot supported by this implementation in the current encoding mode.
      +
      +
      + +
      +
      + +

      ◆ TH_ENCCTL_SET_KEYFRAME_FREQUENCY_FORCE

      + +
      +
      + + + + +
      #define TH_ENCCTL_SET_KEYFRAME_FREQUENCY_FORCE   (4)
      +
      + +

      Sets the maximum distance between key frames.

      +

      This can be changed during an encode, but will be bounded by 1<<th_info::keyframe_granule_shift. If it is set before encoding begins, th_info::keyframe_granule_shift will be enlarged appropriately.

      +
      Parameters
      + + + +
      [in]bufogg_uint32_t: The maximum distance between key frames.
      [out]bufogg_uint32_t: The actual maximum distance set.
      +
      +
      +
      Return values
      + + + + +
      OC_FAULTtheora_state or buf is NULL.
      OC_EINVALbuf_sz is not sizeof(ogg_uint32_t).
      OC_IMPLNot supported by this implementation.
      +
      +
      + +
      +
      + +

      ◆ TH_ENCCTL_SET_QUANT_PARAMS

      + +
      +
      + + + + +
      #define TH_ENCCTL_SET_QUANT_PARAMS   (2)
      +
      + +

      +

      Sets the quantization parameters to use. The parameters are copied, not stored by reference, so they can be freed after this call. NULL may be specified to revert to the default parameters.

      +
      Parameters
      + + +
      [in]bufth_quant_info
      +
      +
      +
      Return values
      + + + + +
      OC_FAULTtheora_state is NULL.
      OC_EINVALEncoding has already begun, the quantization parameters are not acceptable to this version of the encoder, buf is NULL and buf_sz is not zero, or buf is non-NULL and buf_sz is not sizeof(th_quant_info).
      OC_IMPLNot supported by this implementation.
      +
      +
      + +
      +
      + +

      ◆ TH_ENCCTL_SET_SPLEVEL

      + +
      +
      + + + + +
      #define TH_ENCCTL_SET_SPLEVEL   (14)
      +
      + +

      Sets the speed level.

      +

      By default a speed value of 1 is used.

      +
      Parameters
      + + +
      [in]bufint: The new encoding speed level. 0 is slowest, larger values use less CPU.
      +
      +
      +
      Return values
      + + + + +
      OC_FAULTtheora_state or buf is NULL.
      OC_EINVALbuf_sz is not sizeof(int), or the encoding speed level is out of bounds. The maximum encoding speed level may be implementation- and encoding mode-specific, and can be obtained via TH_ENCCTL_GET_SPLEVEL_MAX.
      OC_IMPLNot supported by this implementation in the current encoding mode.
      +
      +
      + +
      +
      + +

      ◆ TH_ENCCTL_SET_VP3_COMPATIBLE

      + +
      +
      + + + + +
      #define TH_ENCCTL_SET_VP3_COMPATIBLE   (10)
      +
      + +

      Disables any encoder features that would prevent lossless transcoding back to VP3.

      +

      This primarily means disabling block-level QI values and not using 4MV mode when any of the luma blocks in a macro block are not coded. It also includes using the VP3 quantization tables and Huffman codes; if you set them explicitly after calling this function, the resulting stream will not be VP3-compatible. If you enable VP3-compatibility when encoding 4:2:2 or 4:4:4 source material, or when using a picture region smaller than the full frame (e.g. a non-multiple-of-16 width or height), then non-VP3 bitstream features will still be disabled, but the stream will still not be VP3-compatible, as VP3 was not capable of encoding such formats. If you call this after encoding has already begun, then the quantization tables and codebooks cannot be changed, but the frame-level features will be enabled or disabled as requested.

      +
      Parameters
      + + + +
      [in]bufint: a non-zero value to enable VP3 compatibility, or 0 to disable it (the default).
      [out]bufint: 1 if all bitstream features required for VP3-compatibility could be set, and 0 otherwise. The latter will be returned if the pixel format is not 4:2:0, the picture region is smaller than the full frame, or if encoding has begun, preventing the quantization tables and codebooks from being set.
      +
      +
      +
      Return values
      + + + + +
      OC_FAULTtheora_state or buf is NULL.
      OC_EINVALbuf_sz is not sizeof(int).
      OC_IMPLNot supported by this implementation.
      +
      +
      + +
      +
      +

      Typedef Documentation

      + +

      ◆ theora_comment

      + +
      +
      + + + + +
      typedef struct theora_comment theora_comment
      +
      + +

      Comment header metadata.

      +

      This structure holds the in-stream metadata corresponding to the 'comment' header packet.

      +

      Meta data is stored as a series of (tag, value) pairs, in length-encoded string vectors. The first occurence of the '=' character delimits the tag and value. A particular tag may occur more than once. The character set encoding for the strings is always UTF-8, but the tag names are limited to case-insensitive ASCII. See the spec for details.

      +

      In filling in this structure, theora_decode_header() will null-terminate the user_comment strings for safety. However, the bitstream format itself treats them as 8-bit clean, and so the length array should be treated as authoritative for their length.

      + +
      +
      +

      Enumeration Type Documentation

      + +

      ◆ theora_colorspace

      + +
      +
      + + + + +
      enum theora_colorspace
      +
      + +

      A Colorspace.

      + + + + + +
      Enumerator
      OC_CS_UNSPECIFIED 

      The colorspace is unknown or unspecified.

      +
      OC_CS_ITU_REC_470M 

      This is the best option for 'NTSC' content.

      +
      OC_CS_ITU_REC_470BG 

      This is the best option for 'PAL' content.

      +
      OC_CS_NSPACES 

      This marks the end of the defined colorspaces.

      +
      + +
      +
      + +

      ◆ theora_pixelformat

      + +
      +
      + + + + +
      enum theora_pixelformat
      +
      + +

      A Chroma subsampling.

      +

      These enumerate the available chroma subsampling options supported by the theora format. See Section 4.4 of the specification for exact definitions.

      + + + + + +
      Enumerator
      OC_PF_420 

      Chroma subsampling by 2 in each direction (4:2:0)

      +
      OC_PF_RSVD 

      Reserved value.

      +
      OC_PF_422 

      Horizonatal chroma subsampling by 2 (4:2:2)

      +
      OC_PF_444 

      No chroma subsampling at all (4:4:4)

      +
      + +
      +
      +

      Function Documentation

      + +

      ◆ theora_clear()

      + +
      +
      + + + + + + + + +
      void theora_clear (theora_statet)
      +
      + +

      Free all internal data associated with a theora_state handle.

      +
      Parameters
      + + +
      tA theora_state handle.
      +
      +
      + +
      +
      + +

      ◆ theora_comment_add()

      + +
      +
      + + + + + + + + + + + + + + + + + + +
      void theora_comment_add (theora_commenttc,
      char * comment 
      )
      +
      + +

      Add a comment to an initialized theora_comment structure.

      +
      Parameters
      + + + +
      tcA previously initialized theora comment structure
      commentA null-terminated string encoding the comment in the form "TAG=the value"
      +
      +
      +

      Neither theora_comment_add() nor theora_comment_add_tag() support comments containing null values, although the bitstream format supports this. To add such comments you will need to manipulate the theora_comment structure directly.

      + +
      +
      + +

      ◆ theora_comment_add_tag()

      + +
      +
      + + + + + + + + + + + + + + + + + + + + + + + + +
      void theora_comment_add_tag (theora_commenttc,
      char * tag,
      char * value 
      )
      +
      + +

      Add a comment to an initialized theora_comment structure.

      +
      Parameters
      + + + + +
      tcA previously initialized theora comment structure
      tagA null-terminated string containing the tag associated with the comment.
      valueThe corresponding value as a null-terminated string
      +
      +
      +

      Neither theora_comment_add() nor theora_comment_add_tag() support comments containing null values, although the bitstream format supports this. To add such comments you will need to manipulate the theora_comment structure directly.

      + +
      +
      + +

      ◆ theora_comment_clear()

      + +
      +
      + + + + + + + + +
      void theora_comment_clear (theora_commenttc)
      +
      + +

      Clear an allocated theora_comment struct so that it can be freed.

      +
      Parameters
      + + +
      tcAn allocated theora_comment structure.
      +
      +
      + +
      +
      + +

      ◆ theora_comment_init()

      + +
      +
      + + + + + + + + +
      void theora_comment_init (theora_commenttc)
      +
      + +

      Initialize an allocated theora_comment structure.

      +
      Parameters
      + + +
      tcAn allocated theora_comment structure
      +
      +
      + +
      +
      + +

      ◆ theora_comment_query()

      + +
      +
      + + + + + + + + + + + + + + + + + + + + + + + + +
      char * theora_comment_query (theora_commenttc,
      char * tag,
      int count 
      )
      +
      + +

      Look up a comment value by tag.

      +
      Parameters
      + + + + +
      tcTn initialized theora_comment structure
      tagThe tag to look up
      countThe instance of the tag. The same tag can appear multiple times, each with a distinct and ordered value, so an index is required to retrieve them all.
      +
      +
      +
      Returns
      A pointer to the queried tag's value
      +
      Return values
      + + +
      NULLNo matching tag is found
      +
      +
      +
      Note
      Use theora_comment_query_count() to get the legal range for the count parameter.
      + +
      +
      + +

      ◆ theora_comment_query_count()

      + +
      +
      + + + + + + + + + + + + + + + + + + +
      int theora_comment_query_count (theora_commenttc,
      char * tag 
      )
      +
      + +

      Look up the number of instances of a tag.

      +
      Parameters
      + + + +
      tcAn initialized theora_comment structure
      tagThe tag to look up
      +
      +
      +
      Returns
      The number on instances of a particular tag.
      +

      Call this first when querying for a specific tag and then interate over the number of instances with separate calls to theora_comment_query() to retrieve all instances in order.

      + +
      +
      + +

      ◆ theora_control()

      + +
      +
      + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
      int theora_control (theora_stateth,
      int req,
      void * buf,
      size_t buf_sz 
      )
      +
      + +

      Encoder control function.

      +

      This is used to provide advanced control the encoding process.

      Parameters
      + + + + + +
      thA theora_state handle.
      reqThe control code to process. See the list of available control codes" for details.
      bufThe parameters for this control code.
      buf_szThe size of the parameter buffer.
      +
      +
      + +
      +
      + +

      ◆ theora_decode_header()

      + +
      +
      + + + + + + + + + + + + + + + + + + + + + + + + +
      int theora_decode_header (theora_infoci,
      theora_commentcc,
      ogg_packet * op 
      )
      +
      + +

      Decode an Ogg packet, with the expectation that the packet contains an initial header, comment data or codebook tables.

      +
      Parameters
      + + + + +
      ciA theora_info structure to fill. This must have been previously initialized with theora_info_init(). If op contains an initial header, theora_decode_header() will fill ci with the parsed header values. If op contains codebook tables, theora_decode_header() will parse these and attach an internal representation to ci->codec_setup.
      ccA theora_comment structure to fill. If op contains comment data, theora_decode_header() will fill cc with the parsed comments.
      opAn ogg_packet structure which you expect contains an initial header, comment data or codebook tables.
      +
      +
      +
      Return values
      + + + + + +
      OC_BADHEADERop is NULL; OR the first byte of op->packet has the signature of an initial packet, but op is not a b_o_s packet; OR this packet has the signature of an initial header packet, but an initial header packet has already been seen; OR this packet has the signature of a comment packet, but the initial header has not yet been seen; OR this packet has the signature of a comment packet, but contains invalid data; OR this packet has the signature of codebook tables, but the initial header or comments have not yet been seen; OR this packet has the signature of codebook tables, but contains invalid data; OR the stream being decoded has a compatible version but this packet does not have the signature of a theora initial header, comments, or codebook packet
      OC_VERSIONThe packet data of op is an initial header with a version which is incompatible with this version of libtheora.
      OC_NEWPACKETthe stream being decoded has an incompatible (future) version and contains an unknown signature.
      0Success
      +
      +
      +
      Note
      The normal usage is that theora_decode_header() be called on the first three packets of a theora logical bitstream in succession.
      + +
      +
      + +

      ◆ theora_decode_init()

      + +
      +
      + + + + + + + + + + + + + + + + + + +
      int theora_decode_init (theora_stateth,
      theora_infoc 
      )
      +
      + +

      Initialize a theora_state handle for decoding.

      +
      Parameters
      + + + +
      thThe theora_state handle to initialize.
      cA theora_info struct filled with the desired decoding parameters. This is of course usually obtained from a previous call to theora_decode_header().
      +
      +
      +
      Return values
      + + +
      0Success
      +
      +
      + +
      +
      + +

      ◆ theora_decode_packetin()

      + +
      +
      + + + + + + + + + + + + + + + + + + +
      int theora_decode_packetin (theora_stateth,
      ogg_packet * op 
      )
      +
      + +

      Input a packet containing encoded data into the theora decoder.

      +
      Parameters
      + + + +
      thA theora_state handle previously initialized for decoding.
      opAn ogg_packet containing encoded theora data.
      +
      +
      +
      Return values
      + + + +
      0Success
      OC_BADPACKETop does not contain encoded video data
      +
      +
      + +
      +
      + +

      ◆ theora_decode_YUVout()

      + +
      +
      + + + + + + + + + + + + + + + + + + +
      int theora_decode_YUVout (theora_stateth,
      yuv_bufferyuv 
      )
      +
      + +

      Output the next available frame of decoded YUV data.

      +
      Parameters
      + + + +
      thA theora_state handle previously initialized for decoding.
      yuvA yuv_buffer in which libtheora should place the decoded data. Note that the buffer struct itself is allocated by the user, but that the luma and chroma pointers will be filled in by the library. Also note that these luma and chroma regions should be considered read-only by the user.
      +
      +
      +
      Return values
      + + +
      0Success
      +
      +
      + +
      +
      + +

      ◆ theora_encode_comment()

      + +
      +
      + + + + + + + + + + + + + + + + + + +
      int theora_encode_comment (theora_commenttc,
      ogg_packet * op 
      )
      +
      + +

      Request a comment header packet from provided metadata.

      +

      A pointer to the comment data is placed in a user-provided ogg_packet structure.

      Parameters
      + + + +
      tcA theora_comment structure filled with the desired metadata
      opAn ogg_packet structure to fill. libtheora will set all elements of this structure, including a pointer to the encoded comment data. The memory for the comment data is owned by the application, and must be freed by it using _ogg_free(). On some systems (such as Windows when using dynamic linking), this may mean the free is executed in a different module from the malloc, which will crash; there is no way to free this memory on such systems.
      +
      +
      +
      Return values
      + + +
      0Success
      +
      +
      + +
      +
      + +

      ◆ theora_encode_header()

      + +
      +
      + + + + + + + + + + + + + + + + + + +
      int theora_encode_header (theora_statet,
      ogg_packet * op 
      )
      +
      + +

      Request a packet containing the initial header.

      +

      A pointer to the header data is placed in a user-provided ogg_packet structure.

      Parameters
      + + + +
      tA theora_state handle previously initialized for encoding.
      opAn ogg_packet structure to fill. libtheora will set all elements of this structure, including a pointer to the header data. The memory for the header data is owned by libtheora.
      +
      +
      +
      Return values
      + + +
      0Success
      +
      +
      + +
      +
      + +

      ◆ theora_encode_init()

      + +
      +
      + + + + + + + + + + + + + + + + + + +
      int theora_encode_init (theora_stateth,
      theora_infoti 
      )
      +
      + +

      Initialize the theora encoder.

      +
      Parameters
      + + + +
      thThe theora_state handle to initialize for encoding.
      tiA theora_info struct filled with the desired encoding parameters.
      +
      +
      +
      Return values
      + + +
      0Success
      +
      +
      + +
      +
      + +

      ◆ theora_encode_packetout()

      + +
      +
      + + + + + + + + + + + + + + + + + + + + + + + + +
      int theora_encode_packetout (theora_statet,
      int last_p,
      ogg_packet * op 
      )
      +
      + +

      Request the next packet of encoded video.

      +

      The encoded data is placed in a user-provided ogg_packet structure.

      Parameters
      + + + + +
      tA theora_state handle previously initialized for encoding.
      last_pwhether this is the last packet the encoder should produce.
      opAn ogg_packet structure to fill. libtheora will set all elements of this structure, including a pointer to encoded data. The memory for the encoded data is owned by libtheora.
      +
      +
      +
      Return values
      + + + + +
      0No internal storage exists OR no packet is ready
      -1The encoding process has completed
      1Success
      +
      +
      + +
      +
      + +

      ◆ theora_encode_tables()

      + +
      +
      + + + + + + + + + + + + + + + + + + +
      int theora_encode_tables (theora_statet,
      ogg_packet * op 
      )
      +
      + +

      Request a packet containing the codebook tables for the stream.

      +

      A pointer to the codebook data is placed in a user-provided ogg_packet structure.

      Parameters
      + + + +
      tA theora_state handle previously initialized for encoding.
      opAn ogg_packet structure to fill. libtheora will set all elements of this structure, including a pointer to the codebook data. The memory for the header data is owned by libtheora.
      +
      +
      +
      Return values
      + + +
      0Success
      +
      +
      + +
      +
      + +

      ◆ theora_encode_YUVin()

      + +
      +
      + + + + + + + + + + + + + + + + + + +
      int theora_encode_YUVin (theora_statet,
      yuv_bufferyuv 
      )
      +
      + +

      Submit a YUV buffer to the theora encoder.

      +
      Parameters
      + + + +
      tA theora_state handle previously initialized for encoding.
      yuvA buffer of YUV data to encode. Note that both the yuv_buffer struct and the luma/chroma buffers within should be allocated by the user.
      +
      +
      +
      Return values
      + + + + +
      OC_EINVALEncoder is not ready, or is finished.
      -1The size of the given frame differs from those previously input
      0Success
      +
      +
      + +
      +
      + +

      ◆ theora_granule_frame()

      + +
      +
      + + + + + + + + + + + + + + + + + + +
      ogg_int64_t theora_granule_frame (theora_stateth,
      ogg_int64_t granulepos 
      )
      +
      + +

      Convert a granulepos to an absolute frame index, starting at 0.

      +

      The granulepos is interpreted in the context of a given theora_state handle.

      +

      Note that while the granulepos encodes the frame count (i.e. starting from 1) this call returns the frame index, starting from zero. Thus One can calculate the presentation time by multiplying the index by the rate.

      +
      Parameters
      + + + +
      thA previously initialized theora_state handle (encode or decode)
      granuleposThe granulepos to convert.
      +
      +
      +
      Returns
      The frame index corresponding to granulepos.
      +
      Return values
      + + +
      -1The given granulepos is undefined (i.e. negative)
      +
      +
      +

      Thus function was added in the 1.0alpha4 release.

      + +
      +
      + +

      ◆ theora_granule_shift()

      + +
      +
      + + + + + + + + +
      int theora_granule_shift (theora_infoti)
      +
      + +

      Report the granulepos shift radix.

      +

      When embedded in Ogg, Theora uses a two-part granulepos, splitting the 64-bit field into two pieces. The more-significant section represents the frame count at the last keyframe, and the less-significant section represents the count of frames since the last keyframe. In this way the overall field is still non-decreasing with time, but usefully encodes a pointer to the last keyframe, which is necessary for correctly restarting decode after a seek.

      +

      This function reports the number of bits used to represent the distance to the last keyframe, and thus how the granulepos field must be shifted or masked to obtain the two parts.

      +

      Since libtheora returns compressed data in an ogg_packet structure, this may be generally useful even if the Theora packets are not being used in an Ogg container.

      +
      Parameters
      + + +
      tiA previously initialized theora_info struct
      +
      +
      +
      Returns
      The bit shift dividing the two granulepos fields
      +

      This function was added in the 1.0alpha5 release.

      + +
      +
      + +

      ◆ theora_granule_time()

      + +
      +
      + + + + + + + + + + + + + + + + + + +
      double theora_granule_time (theora_stateth,
      ogg_int64_t granulepos 
      )
      +
      + +

      Convert a granulepos to absolute time in seconds.

      +

      The granulepos is interpreted in the context of a given theora_state handle, and gives the end time of a frame's presentation as used in Ogg mux ordering.

      +
      Parameters
      + + + +
      thA previously initialized theora_state handle (encode or decode)
      granuleposThe granulepos to convert.
      +
      +
      +
      Returns
      The absolute time in seconds corresponding to granulepos. This is the "end time" for the frame, or the latest time it should be displayed. It is not the presentation time.
      +
      Return values
      + + +
      -1.The given granulepos is undefined (i.e. negative).
      +
      +
      + +
      +
      + +

      ◆ theora_info_clear()

      + +
      +
      + + + + + + + + +
      void theora_info_clear (theora_infoc)
      +
      + +

      Clear a theora_info structure.

      +

      All values within the given theora_info structure are cleared, and associated internal codec setup data is freed.

      Parameters
      + + +
      cA theora_info struct to initialize.
      +
      +
      + +
      +
      + +

      ◆ theora_info_init()

      + +
      +
      + + + + + + + + +
      void theora_info_init (theora_infoc)
      +
      + +

      Initialize a theora_info structure.

      +

      All values within the given theora_info structure are initialized, and space is allocated within libtheora for internal codec setup data.

      Parameters
      + + +
      cA theora_info struct to initialize.
      +
      +
      + +
      +
      + +

      ◆ theora_packet_isheader()

      + +
      +
      + + + + + + + + +
      int theora_packet_isheader (ogg_packet * op)
      +
      + +

      Report whether a theora packet is a header or not This function does no verification beyond checking the header flag bit so it should not be used for bitstream identification; use theora_decode_header() for that.

      +
      Parameters
      + + +
      opAn ogg_packet containing encoded theora data.
      +
      +
      +
      Return values
      + + + +
      1The packet is a header packet
      0The packet is not a header packet (and so contains frame data)
      +
      +
      +

      Thus function was added in the 1.0alpha4 release.

      + +
      +
      + +

      ◆ theora_packet_iskeyframe()

      + +
      +
      + + + + + + + + +
      int theora_packet_iskeyframe (ogg_packet * op)
      +
      + +

      Report whether a theora packet is a keyframe or not.

      +
      Parameters
      + + +
      opAn ogg_packet containing encoded theora data.
      +
      +
      +
      Return values
      + + + + +
      1The packet contains a keyframe image
      0The packet is contains an interframe delta
      -1The packet is not an image data packet at all
      +
      +
      +

      Thus function was added in the 1.0alpha4 release.

      + +
      +
      + +

      ◆ theora_version_number()

      + +
      +
      + + + + + + + + +
      ogg_uint32_t theora_version_number (void )
      +
      + +

      Retrieve a 32-bit version number.

      +

      This number is composed of a 16-bit major version, 8-bit minor version and 8 bit sub-version, composed as follows:

      +   (VERSION_MAJOR<<16) + (VERSION_MINOR<<8) + (VERSION_SUB)
      +
      Returns
      The version number.
      + +
      +
      + +

      ◆ theora_version_string()

      + +
      +
      + + + + + + + + +
      const char * theora_version_string (void )
      +
      + +

      Retrieve a human-readable string to identify the encoder vendor and version.

      +
      Returns
      A version string.
      + +
      - +
    + + diff --git a/doc/libtheora-1.2/theora_8h_source.html b/doc/libtheora-1.2/theora_8h_source.html index e08684ec10ad9f31ddd8071b0082959c37e757b9..3332b4acbbd10dcd000b93fb4a752d1c1515acc8 100644 --- a/doc/libtheora-1.2/theora_8h_source.html +++ b/doc/libtheora-1.2/theora_8h_source.html @@ -1,251 +1,355 @@ - + + + + libtheora: theora.h Source File - + + + - -