| OLD | NEW | 
|    1 /* |    1 /* | 
|    2  *  Copyright (c) 2010 The WebM project authors. All Rights Reserved. |    2  *  Copyright (c) 2010 The WebM project authors. All Rights Reserved. | 
|    3  * |    3  * | 
|    4  *  Use of this source code is governed by a BSD-style license |    4  *  Use of this source code is governed by a BSD-style license | 
|    5  *  that can be found in the LICENSE file in the root of the source |    5  *  that can be found in the LICENSE file in the root of the source | 
|    6  *  tree. An additional intellectual property rights grant can be found |    6  *  tree. An additional intellectual property rights grant can be found | 
|    7  *  in the file PATENTS.  All contributing project authors may |    7  *  in the file PATENTS.  All contributing project authors may | 
|    8  *  be found in the AUTHORS file in the root of the source tree. |    8  *  be found in the AUTHORS file in the root of the source tree. | 
|    9  */ |    9  */ | 
|   10 #ifndef TOOLS_COMMON_H_ |   10 #ifndef TOOLS_COMMON_H_ | 
| (...skipping 85 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
|   96   struct VpxRational framerate; |   96   struct VpxRational framerate; | 
|   97 #if CONFIG_ENCODERS |   97 #if CONFIG_ENCODERS | 
|   98   y4m_input y4m; |   98   y4m_input y4m; | 
|   99 #endif |   99 #endif | 
|  100 }; |  100 }; | 
|  101  |  101  | 
|  102 #ifdef __cplusplus |  102 #ifdef __cplusplus | 
|  103 extern "C" { |  103 extern "C" { | 
|  104 #endif |  104 #endif | 
|  105  |  105  | 
 |  106 #if defined(__GNUC__) | 
 |  107 #define VPX_NO_RETURN __attribute__((noreturn)) | 
 |  108 #else | 
 |  109 #define VPX_NO_RETURN | 
 |  110 #endif | 
 |  111  | 
|  106 /* Sets a stdio stream into binary mode */ |  112 /* Sets a stdio stream into binary mode */ | 
|  107 FILE *set_binary_mode(FILE *stream); |  113 FILE *set_binary_mode(FILE *stream); | 
|  108  |  114  | 
|  109 void die(const char *fmt, ...); |  115 void die(const char *fmt, ...) VPX_NO_RETURN; | 
|  110 void fatal(const char *fmt, ...); |  116 void fatal(const char *fmt, ...) VPX_NO_RETURN; | 
|  111 void warn(const char *fmt, ...); |  117 void warn(const char *fmt, ...); | 
|  112  |  118  | 
|  113 void die_codec(vpx_codec_ctx_t *ctx, const char *s); |  119 void die_codec(vpx_codec_ctx_t *ctx, const char *s) VPX_NO_RETURN; | 
|  114  |  120  | 
|  115 /* The tool including this file must define usage_exit() */ |  121 /* The tool including this file must define usage_exit() */ | 
|  116 void usage_exit(); |  122 void usage_exit() VPX_NO_RETURN; | 
 |  123  | 
 |  124 #undef VPX_NO_RETURN | 
|  117  |  125  | 
|  118 int read_yuv_frame(struct VpxInputContext *input_ctx, vpx_image_t *yuv_frame); |  126 int read_yuv_frame(struct VpxInputContext *input_ctx, vpx_image_t *yuv_frame); | 
|  119  |  127  | 
|  120 typedef struct VpxInterface { |  128 typedef struct VpxInterface { | 
|  121   const char *const name; |  129   const char *const name; | 
|  122   const uint32_t fourcc; |  130   const uint32_t fourcc; | 
|  123   vpx_codec_iface_t *(*const codec_interface)(); |  131   vpx_codec_iface_t *(*const codec_interface)(); | 
|  124 } VpxInterface; |  132 } VpxInterface; | 
|  125  |  133  | 
|  126 int get_vpx_encoder_count(); |  134 int get_vpx_encoder_count(); | 
| (...skipping 12 matching lines...) Expand all  Loading... | 
|  139 void vpx_img_write(const vpx_image_t *img, FILE *file); |  147 void vpx_img_write(const vpx_image_t *img, FILE *file); | 
|  140 int vpx_img_read(vpx_image_t *img, FILE *file); |  148 int vpx_img_read(vpx_image_t *img, FILE *file); | 
|  141  |  149  | 
|  142 double sse_to_psnr(double samples, double peak, double mse); |  150 double sse_to_psnr(double samples, double peak, double mse); | 
|  143  |  151  | 
|  144 #ifdef __cplusplus |  152 #ifdef __cplusplus | 
|  145 }  /* extern "C" */ |  153 }  /* extern "C" */ | 
|  146 #endif |  154 #endif | 
|  147  |  155  | 
|  148 #endif  // TOOLS_COMMON_H_ |  156 #endif  // TOOLS_COMMON_H_ | 
| OLD | NEW |