Index: source/libvpx/vpx/vpx_encoder.h |
=================================================================== |
--- source/libvpx/vpx/vpx_encoder.h (revision 291857) |
+++ source/libvpx/vpx/vpx_encoder.h (working copy) |
@@ -80,6 +80,9 @@ |
*/ |
#define VPX_CODEC_CAP_OUTPUT_PARTITION 0x20000 |
+/*! Can support input images at greater than 8 bitdepth. |
+ */ |
+#define VPX_CODEC_CAP_HIGHBITDEPTH 0x40000 |
/*! \brief Initialization-time Feature Enabling |
* |
@@ -91,6 +94,7 @@ |
#define VPX_CODEC_USE_PSNR 0x10000 /**< Calculate PSNR on each frame */ |
#define VPX_CODEC_USE_OUTPUT_PARTITION 0x20000 /**< Make the encoder output one |
partition at a time. */ |
+#define VPX_CODEC_USE_HIGHBITDEPTH 0x40000 /**< Use high bitdepth */ |
/*!\brief Generic fixed size buffer structure |
@@ -188,14 +192,14 @@ |
has id 0.*/ |
} frame; /**< data for compressed frame packet */ |
- struct vpx_fixed_buf twopass_stats; /**< data for two-pass packet */ |
- struct vpx_fixed_buf firstpass_mb_stats; /**< first pass mb packet */ |
+ vpx_fixed_buf_t twopass_stats; /**< data for two-pass packet */ |
+ vpx_fixed_buf_t firstpass_mb_stats; /**< first pass mb packet */ |
struct vpx_psnr_pkt { |
unsigned int samples[4]; /**< Number of samples, total/y/u/v */ |
uint64_t sse[4]; /**< sum squared error, total/y/u/v */ |
double psnr[4]; /**< PSNR, total/y/u/v */ |
} psnr; /**< data for PSNR packet */ |
- struct vpx_fixed_buf raw; /**< data for arbitrary packets */ |
+ vpx_fixed_buf_t raw; /**< data for arbitrary packets */ |
#if CONFIG_SPATIAL_SVC |
size_t layer_sizes[VPX_SS_MAX_LAYERS]; |
#endif |
@@ -324,7 +328,22 @@ |
*/ |
unsigned int g_h; |
+ /*!\brief Bit-depth of the codec |
+ * |
+ * This value identifies the bit_depth of the codec, |
+ * Only certain bit-depths are supported as identified in the |
+ * vpx_bit_depth_t enum. |
+ */ |
+ vpx_bit_depth_t g_bit_depth; |
+ /*!\brief Bit-depth of the input frames |
+ * |
+ * This value identifies the bit_depth of the input frames in bits. |
+ * Note that the frames passed as input to the encoder must have |
+ * this bit-depth. |
+ */ |
+ unsigned int g_input_bit_depth; |
+ |
/*!\brief Stream timebase units |
* |
* Indicates the smallest interval of time, in seconds, used by the stream. |
@@ -452,14 +471,14 @@ |
* A buffer containing all of the stats packets produced in the first |
* pass, concatenated. |
*/ |
- struct vpx_fixed_buf rc_twopass_stats_in; |
+ vpx_fixed_buf_t rc_twopass_stats_in; |
/*!\brief first pass mb stats buffer. |
* |
* A buffer containing all of the first pass mb stats packets produced |
* in the first pass, concatenated. |
*/ |
- struct vpx_fixed_buf rc_firstpass_mb_stats_in; |
+ vpx_fixed_buf_t rc_firstpass_mb_stats_in; |
/*!\brief Target data rate |
* |
@@ -715,7 +734,7 @@ |
*/ |
vpx_codec_err_t vpx_codec_enc_init_ver(vpx_codec_ctx_t *ctx, |
vpx_codec_iface_t *iface, |
- vpx_codec_enc_cfg_t *cfg, |
+ const vpx_codec_enc_cfg_t *cfg, |
vpx_codec_flags_t flags, |
int ver); |