d3d11decoder: Do not hardcode the limit minimum resolution to 64

Decoder should be able to support lower resolution than 64x64

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2113>
This commit is contained in:
Seungha Yang 2021-03-26 21:06:59 +09:00
parent f74ed67ba0
commit c9518780fd
5 changed files with 20 additions and 20 deletions

View file

@ -1330,11 +1330,11 @@ gst_d3d11_h264_dec_register (GstPlugin * plugin, GstD3D11Device * device,
/* To cover both landscape and portrait, select max value */
resolution = MAX (max_width, max_height);
gst_caps_set_simple (sink_caps,
"width", GST_TYPE_INT_RANGE, 64, resolution,
"height", GST_TYPE_INT_RANGE, 64, resolution, NULL);
"width", GST_TYPE_INT_RANGE, 1, resolution,
"height", GST_TYPE_INT_RANGE, 1, resolution, NULL);
gst_caps_set_simple (src_caps,
"width", GST_TYPE_INT_RANGE, 64, resolution,
"height", GST_TYPE_INT_RANGE, 64, resolution, NULL);
"width", GST_TYPE_INT_RANGE, 1, resolution,
"height", GST_TYPE_INT_RANGE, 1, resolution, NULL);
type_info.class_data =
gst_d3d11_decoder_class_data_new (device, sink_caps, src_caps);

View file

@ -1527,11 +1527,11 @@ gst_d3d11_h265_dec_register (GstPlugin * plugin, GstD3D11Device * device,
/* To cover both landscape and portrait, select max value */
resolution = MAX (max_width, max_height);
gst_caps_set_simple (sink_caps,
"width", GST_TYPE_INT_RANGE, 64, resolution,
"height", GST_TYPE_INT_RANGE, 64, resolution, NULL);
"width", GST_TYPE_INT_RANGE, 1, resolution,
"height", GST_TYPE_INT_RANGE, 1, resolution, NULL);
gst_caps_set_simple (src_caps,
"width", GST_TYPE_INT_RANGE, 64, resolution,
"height", GST_TYPE_INT_RANGE, 64, resolution, NULL);
"width", GST_TYPE_INT_RANGE, 1, resolution,
"height", GST_TYPE_INT_RANGE, 1, resolution, NULL);
/* Copy src caps to append other capsfeatures */
src_caps_copy = gst_caps_copy (src_caps);

View file

@ -1021,11 +1021,11 @@ gst_d3d11_mpeg2_dec_register (GstPlugin * plugin, GstD3D11Device * device,
gst_caps_set_simple (src_caps, "format", G_TYPE_STRING, "NV12", NULL);
gst_caps_set_simple (sink_caps,
"width", GST_TYPE_INT_RANGE, 64, 1920,
"height", GST_TYPE_INT_RANGE, 64, 1920, NULL);
"width", GST_TYPE_INT_RANGE, 1, 1920,
"height", GST_TYPE_INT_RANGE, 1, 1920, NULL);
gst_caps_set_simple (src_caps,
"width", GST_TYPE_INT_RANGE, 64, 1920,
"height", GST_TYPE_INT_RANGE, 64, 1920, NULL);
"width", GST_TYPE_INT_RANGE, 1, 1920,
"height", GST_TYPE_INT_RANGE, 1, 1920, NULL);
type_info.class_data =
gst_d3d11_decoder_class_data_new (device, sink_caps, src_caps);

View file

@ -917,11 +917,11 @@ gst_d3d11_vp8_dec_register (GstPlugin * plugin, GstD3D11Device * device,
/* To cover both landscape and portrait, select max value */
resolution = MAX (max_width, max_height);
gst_caps_set_simple (sink_caps,
"width", GST_TYPE_INT_RANGE, 64, resolution,
"height", GST_TYPE_INT_RANGE, 64, resolution, NULL);
"width", GST_TYPE_INT_RANGE, 1, resolution,
"height", GST_TYPE_INT_RANGE, 1, resolution, NULL);
gst_caps_set_simple (src_caps,
"width", GST_TYPE_INT_RANGE, 64, resolution,
"height", GST_TYPE_INT_RANGE, 64, resolution, NULL);
"width", GST_TYPE_INT_RANGE, 1, resolution,
"height", GST_TYPE_INT_RANGE, 1, resolution, NULL);
type_info.class_data =
gst_d3d11_decoder_class_data_new (device, sink_caps, src_caps);

View file

@ -1220,11 +1220,11 @@ gst_d3d11_vp9_dec_register (GstPlugin * plugin, GstD3D11Device * device,
/* To cover both landscape and portrait, select max value */
resolution = MAX (max_width, max_height);
gst_caps_set_simple (sink_caps,
"width", GST_TYPE_INT_RANGE, 64, resolution,
"height", GST_TYPE_INT_RANGE, 64, resolution, NULL);
"width", GST_TYPE_INT_RANGE, 1, resolution,
"height", GST_TYPE_INT_RANGE, 1, resolution, NULL);
gst_caps_set_simple (src_caps,
"width", GST_TYPE_INT_RANGE, 64, resolution,
"height", GST_TYPE_INT_RANGE, 64, resolution, NULL);
"width", GST_TYPE_INT_RANGE, 1, resolution,
"height", GST_TYPE_INT_RANGE, 1, resolution, NULL);
type_info.class_data =
gst_d3d11_decoder_class_data_new (device, sink_caps, src_caps);