Unified · Split
| @@ -1114,8 +1114,20 @@ static void draw_frame(struct vo *vo, struct vo_frame *frame) · 1113 unmodified lines | |||
| 1114 | goto done; | 1114 | goto done; |
| 1115 | } | 1115 | } |
| 1116 | 1116 | ||
| 1117 | const struct pl_frame *cur_frame = pl_frame_mix_nearest(&mix); | ||
| 1118 | mp_mutex_lock(&vo->params_mutex); | 1117 | mp_mutex_lock(&vo->params_mutex); |
| 1118 | if (!vo->target_params) | ||
| 1119 | vo->target_params = talloc(vo, struct mp_image_params); | ||
| 1120 | *vo->target_params = (struct mp_image_params){ | ||
| 1121 | .imgfmt_name = swframe.fbo->params.format | ||
| 1122 | ? swframe.fbo->params.format->name : NULL, | ||
| 1123 | .w = swframe.fbo->params.w, | ||
| 1124 | .h = swframe.fbo->params.h, | ||
| 1125 | .color = target.color, | ||
| 1126 | .repr = target.repr, | ||
| 1127 | .rotate = target.rotation, | ||
| 1128 | }; | ||
| 1129 | |||
| 1130 | const struct pl_frame *cur_frame = pl_frame_mix_nearest(&mix); | ||
| 1119 | if (cur_frame && vo->params) { | 1131 | if (cur_frame && vo->params) { |
| 1120 | vo->params->color.hdr = cur_frame->color.hdr; | 1132 | vo->params->color.hdr = cur_frame->color.hdr; |
| 1121 | // Augment metadata with peak detection max_pq_y / avg_pq_y | 1133 | // Augment metadata with peak detection max_pq_y / avg_pq_y |