#ifdef OUTPUT_YUV_REC
FILE *yuv_rec_file;
#endif
+#ifdef OUTPUT_YUV_SVC_SRC
+FILE *yuv_svc_src[3] = { NULL, NULL, NULL };
+#endif
#if 0
FILE *framepsnr;
#ifdef OUTPUT_YUV_REC
yuv_rec_file = fopen("rec.yuv", "wb");
#endif
+#ifdef OUTPUT_YUV_SVC_SRC
+ yuv_svc_src[0] = fopen("svc_src_0.yuv", "wb");
+ yuv_svc_src[1] = fopen("svc_src_1.yuv", "wb");
+ yuv_svc_src[2] = fopen("svc_src_2.yuv", "wb");
+#endif
#if 0
framepsnr = fopen("framepsnr.stt", "a");
#ifdef OUTPUT_YUV_REC
fclose(yuv_rec_file);
#endif
+#ifdef OUTPUT_YUV_SVC_SRC
+ fclose(yuv_svc_src[0]);
+ fclose(yuv_svc_src[1]);
+ fclose(yuv_svc_src[2]);
+#endif
#if 0
cm, cpi->un_scaled_source, &cpi->scaled_source, (cpi->oxcf.pass == 0),
filter_scaler, phase_scaler);
}
+#ifdef OUTPUT_YUV_SVC_SRC
+ // Write out at most 3 spatial layers.
+ if (is_one_pass_cbr_svc(cpi) && cpi->svc.spatial_layer_id < 3) {
+ vpx_write_yuv_frame(yuv_svc_src[cpi->svc.spatial_layer_id], cpi->Source);
+ }
+#endif
// Unfiltered raw source used in metrics calculation if the source
// has been filtered.
if (is_psnr_calc_enabled(cpi)) {
void vpx_write_yuv_frame(FILE *yuv_file, YV12_BUFFER_CONFIG *s) {
#if defined(OUTPUT_YUV_SRC) || defined(OUTPUT_YUV_DENOISED) || \
- defined(OUTPUT_YUV_SKINMAP)
+ defined(OUTPUT_YUV_SKINMAP) || defined(OUTPUT_YUV_SVC_SRC)
unsigned char *src = s->y_buffer;
int h = s->y_crop_height;