* 2. When we are scaling to certain sizes and placing the result into a larger
* black frame.
*
- * Clear out the left hand side of the image to take care of that.
+ * Clear out the sides of the image to take care of those cases.
*/
- out->make_part_black (corner.x + inter_size.width, (out_size.width - inter_size.width) / 2);
+ auto const pad = (out_size.width - inter_size.width) / 2;
+ out->make_part_black(0, pad);
+ out->make_part_black(corner.x + inter_size.width, pad);
if (
video_range == VideoRange::VIDEO &&
}
break;
}
+ case AV_PIX_FMT_YUV444P10LE:
+ {
+ y_part();
+ for (int i = 1; i < 3; ++i) {
+ auto p = reinterpret_cast<int16_t*>(data()[i]);
+ int const h = sample_size(i).height;
+ for (int y = 0; y < h; ++y) {
+ for (int x = start; x < (start + width); ++x) {
+ p[x] = ten_bit_uv;
+ }
+ p += stride()[i] / 2;
+ }
+ }
+ break;
+ }
default:
throw PixelFormatError ("make_part_black()", _pixel_format);
}