vp9 svc: fix a few compile warnings.

Change-Id: I4cb878600038066513ab73f3658990d1245ff2fb
This commit is contained in:
Jerome Jiang 2017-11-17 14:33:21 -08:00
parent 849b3c238d
commit 8b7a6ca60a
2 changed files with 7 additions and 7 deletions

View File

@ -168,7 +168,7 @@ void usage_exit(void) {
static void parse_command_line(int argc, const char **argv_, static void parse_command_line(int argc, const char **argv_,
AppInput *app_input, SvcContext *svc_ctx, AppInput *app_input, SvcContext *svc_ctx,
vpx_codec_enc_cfg_t *enc_cfg) { vpx_codec_enc_cfg_t *enc_cfg) {
struct arg arg = { 0 }; struct arg arg;
char **argv = NULL; char **argv = NULL;
char **argi = NULL; char **argi = NULL;
char **argj = NULL; char **argj = NULL;
@ -509,7 +509,7 @@ static void printout_rate_control_summary(struct RateControlStats *rc,
} }
vpx_codec_err_t parse_superframe_index(const uint8_t *data, size_t data_sz, vpx_codec_err_t parse_superframe_index(const uint8_t *data, size_t data_sz,
uint32_t sizes[8], int *count) { uint64_t sizes[8], int *count) {
// A chunk ending with a byte matching 0xc0 is an invalid chunk unless // A chunk ending with a byte matching 0xc0 is an invalid chunk unless
// it is a super frame index. If the last byte of real video compression // it is a super frame index. If the last byte of real video compression
// data is 0xc0 the encoder must add a 0 byte. If we have the marker but // data is 0xc0 the encoder must add a 0 byte. If we have the marker but
@ -606,9 +606,9 @@ void set_frame_flags_bypass_mode(int sl, int tl, int num_spatial_layers,
} }
int main(int argc, const char **argv) { int main(int argc, const char **argv) {
AppInput app_input = { 0 }; AppInput app_input;
VpxVideoWriter *writer = NULL; VpxVideoWriter *writer = NULL;
VpxVideoInfo info = { 0 }; VpxVideoInfo info;
vpx_codec_ctx_t codec; vpx_codec_ctx_t codec;
vpx_codec_enc_cfg_t enc_cfg; vpx_codec_enc_cfg_t enc_cfg;
SvcContext svc_ctx; SvcContext svc_ctx;
@ -770,7 +770,7 @@ int main(int argc, const char **argv) {
SvcInternal_t *const si = (SvcInternal_t *)svc_ctx.internal; SvcInternal_t *const si = (SvcInternal_t *)svc_ctx.internal;
if (cx_pkt->data.frame.sz > 0) { if (cx_pkt->data.frame.sz > 0) {
#if OUTPUT_RC_STATS #if OUTPUT_RC_STATS
uint32_t sizes[8]; uint64_t sizes[8];
int count = 0; int count = 0;
#endif #endif
vpx_video_writer_write_frame(writer, cx_pkt->data.frame.buf, vpx_video_writer_write_frame(writer, cx_pkt->data.frame.buf,

View File

@ -131,9 +131,9 @@ static int svc_log(SvcContext *svc_ctx, SVC_LOG_LEVEL level, const char *fmt,
static vpx_codec_err_t extract_option(LAYER_OPTION_TYPE type, char *input, static vpx_codec_err_t extract_option(LAYER_OPTION_TYPE type, char *input,
int *value0, int *value1) { int *value0, int *value1) {
if (type == SCALE_FACTOR) { if (type == SCALE_FACTOR) {
*value0 = strtol(input, &input, 10); *value0 = (int)strtol(input, &input, 10);
if (*input++ != '/') return VPX_CODEC_INVALID_PARAM; if (*input++ != '/') return VPX_CODEC_INVALID_PARAM;
*value1 = strtol(input, &input, 10); *value1 = (int)strtol(input, &input, 10);
if (*value0 < option_min_values[SCALE_FACTOR] || if (*value0 < option_min_values[SCALE_FACTOR] ||
*value1 < option_min_values[SCALE_FACTOR] || *value1 < option_min_values[SCALE_FACTOR] ||