38 #ifndef VPX_VPX_CODEC_H_ 39 #define VPX_VPX_CODEC_H_ 46 #include "./vpx_integer.h" 50 #if defined(__GNUC__) && __GNUC__ 51 #define DEPRECATED __attribute__((deprecated)) 52 #elif defined(_MSC_VER) 59 #ifndef DECLSPEC_DEPRECATED 60 #if defined(__GNUC__) && __GNUC__ 61 #define DECLSPEC_DEPRECATED 62 #elif defined(_MSC_VER) 64 #define DECLSPEC_DEPRECATED __declspec(deprecated) 66 #define DECLSPEC_DEPRECATED 72 #elif defined(__GNUC__) || defined(__clang__) 73 #define UNUSED __attribute__((unused)) 86 #define VPX_CODEC_ABI_VERSION (4 + VPX_IMAGE_ABI_VERSION) 152 #define VPX_CODEC_CAP_DECODER 0x1 153 #define VPX_CODEC_CAP_ENCODER 0x2 157 #define VPX_CODEC_CAP_HIGHBITDEPTH 0x4 242 #define VPX_VERSION_MAJOR(v) \ 244 #define VPX_VERSION_MINOR(v) \ 246 #define VPX_VERSION_PATCH(v) \ 250 #define vpx_codec_version_major() ((vpx_codec_version() >> 16) & 0xff) 253 #define vpx_codec_version_minor() ((vpx_codec_version() >> 8) & 0xff) 256 #define vpx_codec_version_patch() ((vpx_codec_version() >> 0) & 0xff) 384 #if defined(VPX_DISABLE_CTRL_TYPECHECKS) && VPX_DISABLE_CTRL_TYPECHECKS 385 #define vpx_codec_control(ctx, id, data) vpx_codec_control_(ctx, id, data) 386 #define VPX_CTRL_USE_TYPE(id, typ) 387 #define VPX_CTRL_USE_TYPE_DEPRECATED(id, typ) 388 #define VPX_CTRL_VOID(id, typ) 400 #define vpx_codec_control(ctx, id, data) \ 401 vpx_codec_control_##id(ctx, id, data) 414 #define VPX_CTRL_USE_TYPE(id, typ) \ 415 static vpx_codec_err_t vpx_codec_control_##id(vpx_codec_ctx_t *, int, typ) \ 418 static vpx_codec_err_t vpx_codec_control_##id(vpx_codec_ctx_t *ctx, \ 419 int ctrl_id, typ data) { \ 420 return vpx_codec_control_(ctx, ctrl_id, data); \ 433 #define VPX_CTRL_USE_TYPE_DEPRECATED(id, typ) \ 434 DECLSPEC_DEPRECATED static vpx_codec_err_t vpx_codec_control_##id( \ 435 vpx_codec_ctx_t *, int, typ) DEPRECATED UNUSED; \ 437 DECLSPEC_DEPRECATED static vpx_codec_err_t vpx_codec_control_##id( \ 438 vpx_codec_ctx_t *ctx, int ctrl_id, typ data) { \ 439 return vpx_codec_control_(ctx, ctrl_id, data); \ 452 #define VPX_CTRL_VOID(id) \ 453 static vpx_codec_err_t vpx_codec_control_##id(vpx_codec_ctx_t *, int) \ 456 static vpx_codec_err_t vpx_codec_control_##id(vpx_codec_ctx_t *ctx, \ 458 return vpx_codec_control_(ctx, ctrl_id); \ 467 #endif // VPX_VPX_CODEC_H_ const char * vpx_codec_iface_name(vpx_codec_iface_t *iface)
Return the name for a given interface.
const char * vpx_codec_err_to_string(vpx_codec_err_t err)
Convert error number to printable string.
vpx_codec_flags_t init_flags
Definition: vpx_codec.h:201
Unspecified error.
Definition: vpx_codec.h:94
The given bitstream is not supported.
Definition: vpx_codec.h:110
Memory operation failed.
Definition: vpx_codec.h:97
Encoder configuration structure.
Definition: vpx_encoder.h:281
The coded data for this stream is corrupt or incomplete.
Definition: vpx_codec.h:129
int vpx_codec_version(void)
Return the version information (as an integer)
An application-supplied parameter is not valid.
Definition: vpx_codec.h:134
const char * vpx_codec_version_extra_str(void)
Return the version information (as a string)
const char * vpx_codec_build_config(void)
Return the build configuration.
const char * name
Definition: vpx_codec.h:197
enum vpx_bit_depth vpx_bit_depth_t
Bit depth for codecThis enumeration determines the bit depth of the codec.
vpx_codec_caps_t vpx_codec_get_caps(vpx_codec_iface_t *iface)
Get the capabilities of an algorithm.
Operation completed without error.
Definition: vpx_codec.h:91
struct vpx_codec_ctx vpx_codec_ctx_t
Codec context structure.
vpx_bit_depth
Bit depth for codecThis enumeration determines the bit depth of the codec.
Definition: vpx_codec.h:216
vpx_codec_iface_t * iface
Definition: vpx_codec.h:198
Describes the vpx image descriptor and associated operations.
const struct vpx_codec_iface vpx_codec_iface_t
Codec interface structure.
Definition: vpx_codec.h:173
Definition: vpx_codec.h:219
long vpx_codec_flags_t
Initialization-time Feature Enabling.
Definition: vpx_codec.h:166
const char * err_detail
Definition: vpx_codec.h:200
const char * vpx_codec_error_detail(vpx_codec_ctx_t *ctx)
Retrieve detailed error information for codec context.
const char * vpx_codec_version_str(void)
Return the version information (as a string)
vpx_codec_err_t
Algorithm return codes.
Definition: vpx_codec.h:89
struct vpx_codec_priv vpx_codec_priv_t
Codec private data structure.
Definition: vpx_codec.h:180
Encoded bitstream uses an unsupported feature.
Definition: vpx_codec.h:119
ABI version mismatch.
Definition: vpx_codec.h:100
union vpx_codec_ctx::@0 config
vpx_codec_err_t vpx_codec_control_(vpx_codec_ctx_t *ctx, int ctrl_id,...)
Control algorithm.
An iterator reached the end of list.
Definition: vpx_codec.h:139
vpx_codec_priv_t * priv
Definition: vpx_codec.h:209
const struct vpx_codec_dec_cfg * dec
Definition: vpx_codec.h:204
vpx_codec_err_t vpx_codec_destroy(vpx_codec_ctx_t *ctx)
Destroy a codec instance.
long vpx_codec_caps_t
Codec capabilities bitfield.
Definition: vpx_codec.h:151
Definition: vpx_codec.h:217
Algorithm does not have required capability.
Definition: vpx_codec.h:103
vpx_codec_err_t err
Definition: vpx_codec.h:199
const char * vpx_codec_error(vpx_codec_ctx_t *ctx)
Retrieve error synopsis for codec context.
Initialization Configurations.
Definition: vpx_decoder.h:107
Definition: vpx_codec.h:218
const void * vpx_codec_iter_t
Iterator.
Definition: vpx_codec.h:186
Codec context structure.
Definition: vpx_codec.h:196