Commit 7fa59a29 authored by Aaron Plattner's avatar Aaron Plattner
Browse files

libvdpau_trace cleanups

parent 240441a8
...@@ -37,7 +37,7 @@ ...@@ -37,7 +37,7 @@
static void _vdp_trace_error_breakpoint(char const * file, int line, char const * function) static void _vdp_trace_error_breakpoint(char const * file, int line, char const * function)
{ {
fprintf(stderr, "VDPAU trace:: Error detected at %s:%d %s()\n", file, line, function); fprintf(stderr, "VDPAU trace: Error detected at %s:%d %s()\n", file, line, function);
} }
#define _VDP_TRACE_ERROR_BREAKPOINT() _vdp_trace_error_breakpoint(__FILE__, __LINE__, __FUNCTION__) #define _VDP_TRACE_ERROR_BREAKPOINT() _vdp_trace_error_breakpoint(__FILE__, __LINE__, __FUNCTION__)
...@@ -490,24 +490,17 @@ static void _vdp_cap_dump_video_mixer_attribute_value( ...@@ -490,24 +490,17 @@ static void _vdp_cap_dump_video_mixer_attribute_value(
break; break;
case VDP_VIDEO_MIXER_ATTRIBUTE_CSC_MATRIX: case VDP_VIDEO_MIXER_ATTRIBUTE_CSC_MATRIX:
{ {
// We don't really need/want to cast away the const here, VdpCSCMatrix const * ptr;
// but the buggy compiler thinks we are, even when we don't.
// The const_cast tells it to quit complaining.
VdpCSCMatrix * ptr;
// For some objects, the "default" value is a NULL pointer. // For some objects, the "default" value is a NULL pointer.
// So, VdpVideoMixerGetAttributeValues expects a double pointer to // So, VdpVideoMixerGetAttributeValues expects a double pointer to
// the value, so it can either fill in the value, or NULL out the // the value, so it can either fill in the value, or NULL out the
// pointer. // pointer.
if (get_operation) { if (get_operation) {
VdpCSCMatrix * * dptr = (VdpCSCMatrix * *)const_cast<void *>(value); ptr = *(VdpCSCMatrix const * *)value;
if (!dptr) {
return;
}
ptr = *dptr;
} }
else { else {
ptr = (VdpCSCMatrix *)const_cast<void *>(value); ptr = (VdpCSCMatrix const *)value;
} }
_vdp_cap_dump_csc_matrix(ptr); _vdp_cap_dump_csc_matrix(ptr);
} }
...@@ -1336,11 +1329,12 @@ static VdpStatus _vdp_cap_get_api_version( ...@@ -1336,11 +1329,12 @@ static VdpStatus _vdp_cap_get_api_version(
if (_vdp_cap_data.level >= LEVEL_PARAMS) { if (_vdp_cap_data.level >= LEVEL_PARAMS) {
fprintf(_vdp_cap_data.fp, " -> %d", ret); fprintf(_vdp_cap_data.fp, " -> %d", ret);
if (ret == VDP_STATUS_OK) { if (ret == VDP_STATUS_OK) {
fprintf( if (api_version) {
_vdp_cap_data.fp, fprintf(_vdp_cap_data.fp, ", %u", *api_version);
", %u", }
*api_version else {
); fputs(", ???", _vdp_cap_data.fp);
}
} }
fputs("\n", _vdp_cap_data.fp); fputs("\n", _vdp_cap_data.fp);
} }
...@@ -1372,8 +1366,16 @@ static VdpStatus _vdp_cap_get_information_string( ...@@ -1372,8 +1366,16 @@ static VdpStatus _vdp_cap_get_information_string(
if (_vdp_cap_data.level >= LEVEL_PARAMS) { if (_vdp_cap_data.level >= LEVEL_PARAMS) {
fprintf(_vdp_cap_data.fp, " -> %d", ret); fprintf(_vdp_cap_data.fp, " -> %d", ret);
if (ret == VDP_STATUS_OK) { if (ret == VDP_STATUS_OK) {
if (information_string && *information_string) {
fprintf(_vdp_cap_data.fp, ", \"%s\"", *information_string); fprintf(_vdp_cap_data.fp, ", \"%s\"", *information_string);
} }
else if (information_string) {
fputs(", (null)", _vdp_cap_data.fp);
}
else {
fputs(", ???", _vdp_cap_data.fp);
}
}
fputs("\n", _vdp_cap_data.fp); fputs("\n", _vdp_cap_data.fp);
} }
...@@ -1437,9 +1439,14 @@ static VdpStatus _vdp_cap_generate_csc_matrix( ...@@ -1437,9 +1439,14 @@ static VdpStatus _vdp_cap_generate_csc_matrix(
if (_vdp_cap_data.level >= LEVEL_PARAMS) { if (_vdp_cap_data.level >= LEVEL_PARAMS) {
fprintf(_vdp_cap_data.fp, " -> %d", ret); fprintf(_vdp_cap_data.fp, " -> %d", ret);
if (ret == VDP_STATUS_OK) { if (ret == VDP_STATUS_OK) {
if (csc_matrix) {
fputs(", ", _vdp_cap_data.fp); fputs(", ", _vdp_cap_data.fp);
_vdp_cap_dump_csc_matrix(csc_matrix); _vdp_cap_dump_csc_matrix(csc_matrix);
} }
else {
fputs(", ???", _vdp_cap_data.fp);
}
}
fputs("\n", _vdp_cap_data.fp); fputs("\n", _vdp_cap_data.fp);
} }
...@@ -1482,13 +1489,24 @@ static VdpStatus _vdp_cap_video_surface_query_capabilities( ...@@ -1482,13 +1489,24 @@ static VdpStatus _vdp_cap_video_surface_query_capabilities(
if (_vdp_cap_data.level >= LEVEL_PARAMS) { if (_vdp_cap_data.level >= LEVEL_PARAMS) {
fprintf(_vdp_cap_data.fp, " -> %d", ret); fprintf(_vdp_cap_data.fp, " -> %d", ret);
if (ret == VDP_STATUS_OK) { if (ret == VDP_STATUS_OK) {
fprintf( if (is_supported) {
_vdp_cap_data.fp, fprintf(_vdp_cap_data.fp, ", %d", *is_supported);
", %d, %u, %u", }
*is_supported, else {
*max_width, fputs(", ???", _vdp_cap_data.fp);
*max_height }
); if (max_width) {
fprintf(_vdp_cap_data.fp, ", %u", *max_width);
}
else {
fputs(", ???", _vdp_cap_data.fp);
}
if (max_height) {
fprintf(_vdp_cap_data.fp, ", %u", *max_height);
}
else {
fputs(", ???", _vdp_cap_data.fp);
}
} }
fputs("\n", _vdp_cap_data.fp); fputs("\n", _vdp_cap_data.fp);
} }
...@@ -1529,11 +1547,12 @@ static VdpStatus _vdp_cap_video_surface_query_get_put_bits_y_cb_cr_capabilities( ...@@ -1529,11 +1547,12 @@ static VdpStatus _vdp_cap_video_surface_query_get_put_bits_y_cb_cr_capabilities(
if (_vdp_cap_data.level >= LEVEL_PARAMS) { if (_vdp_cap_data.level >= LEVEL_PARAMS) {
fprintf(_vdp_cap_data.fp, " -> %d", ret); fprintf(_vdp_cap_data.fp, " -> %d", ret);
if (ret == VDP_STATUS_OK) { if (ret == VDP_STATUS_OK) {
fprintf( if (is_supported) {
_vdp_cap_data.fp, fprintf(_vdp_cap_data.fp, ", %d", *is_supported);
", %d", }
*is_supported else {
); fputs(", ???", _vdp_cap_data.fp);
}
} }
fputs("\n", _vdp_cap_data.fp); fputs("\n", _vdp_cap_data.fp);
} }
...@@ -1577,11 +1596,12 @@ static VdpStatus _vdp_cap_video_surface_create( ...@@ -1577,11 +1596,12 @@ static VdpStatus _vdp_cap_video_surface_create(
if (_vdp_cap_data.level >= LEVEL_PARAMS) { if (_vdp_cap_data.level >= LEVEL_PARAMS) {
fprintf(_vdp_cap_data.fp, " -> %d", ret); fprintf(_vdp_cap_data.fp, " -> %d", ret);
if (ret == VDP_STATUS_OK) { if (ret == VDP_STATUS_OK) {
fprintf( if (surface) {
_vdp_cap_data.fp, fprintf(_vdp_cap_data.fp, ", %u", *surface);
", %u", }
*surface else {
); fputs(", ???", _vdp_cap_data.fp);
}
} }
fputs("\n", _vdp_cap_data.fp); fputs("\n", _vdp_cap_data.fp);
} }
...@@ -1649,13 +1669,24 @@ static VdpStatus _vdp_cap_video_surface_get_parameters( ...@@ -1649,13 +1669,24 @@ static VdpStatus _vdp_cap_video_surface_get_parameters(
if (_vdp_cap_data.level >= LEVEL_PARAMS) { if (_vdp_cap_data.level >= LEVEL_PARAMS) {
fprintf(_vdp_cap_data.fp, " -> %d", ret); fprintf(_vdp_cap_data.fp, " -> %d", ret);
if (ret == VDP_STATUS_OK) { if (ret == VDP_STATUS_OK) {
fprintf( if (chroma_type) {
_vdp_cap_data.fp, fprintf(_vdp_cap_data.fp, ", %u", *chroma_type);
", %u, %u, %u", }
*chroma_type, else {
*width, fputs(", ???", _vdp_cap_data.fp);
*height }
); if (width) {
fprintf(_vdp_cap_data.fp, ", %u", *width);
}
else {
fputs(", ???", _vdp_cap_data.fp);
}
if (height) {
fprintf(_vdp_cap_data.fp, ", %u", *height);
}
else {
fputs(", ???", _vdp_cap_data.fp);
}
} }
fputs("\n", _vdp_cap_data.fp); fputs("\n", _vdp_cap_data.fp);
} }
...@@ -1828,13 +1859,24 @@ static VdpStatus _vdp_cap_output_surface_query_capabilities( ...@@ -1828,13 +1859,24 @@ static VdpStatus _vdp_cap_output_surface_query_capabilities(
if (_vdp_cap_data.level >= LEVEL_PARAMS) { if (_vdp_cap_data.level >= LEVEL_PARAMS) {
fprintf(_vdp_cap_data.fp, " -> %d", ret); fprintf(_vdp_cap_data.fp, " -> %d", ret);
if (ret == VDP_STATUS_OK) { if (ret == VDP_STATUS_OK) {
fprintf( if (is_supported) {
_vdp_cap_data.fp, fprintf(_vdp_cap_data.fp, ", %d", *is_supported);
", %d, %u, %u", }
*is_supported, else {
*max_width, fputs(", ???", _vdp_cap_data.fp);
*max_height }
); if (max_width) {
fprintf(_vdp_cap_data.fp, ", %u", *max_width);
}
else {
fputs(", ???", _vdp_cap_data.fp);
}
if (max_height) {
fprintf(_vdp_cap_data.fp, ", %u", *max_height);
}
else {
fputs(", ???", _vdp_cap_data.fp);
}
} }
fputs("\n", _vdp_cap_data.fp); fputs("\n", _vdp_cap_data.fp);
} }
...@@ -1872,11 +1914,12 @@ static VdpStatus _vdp_cap_output_surface_query_get_put_bits_native_capabilities( ...@@ -1872,11 +1914,12 @@ static VdpStatus _vdp_cap_output_surface_query_get_put_bits_native_capabilities(
if (_vdp_cap_data.level >= LEVEL_PARAMS) { if (_vdp_cap_data.level >= LEVEL_PARAMS) {
fprintf(_vdp_cap_data.fp, " -> %d", ret); fprintf(_vdp_cap_data.fp, " -> %d", ret);
if (ret == VDP_STATUS_OK) { if (ret == VDP_STATUS_OK) {
fprintf( if (is_supported) {
_vdp_cap_data.fp, fprintf(_vdp_cap_data.fp, ", %d", *is_supported);
", %d", }
*is_supported else {
); fputs(", ???", _vdp_cap_data.fp);
}
} }
fputs("\n", _vdp_cap_data.fp); fputs("\n", _vdp_cap_data.fp);
} }
...@@ -1920,11 +1963,12 @@ static VdpStatus _vdp_cap_output_surface_query_put_bits_indexed_capabilities( ...@@ -1920,11 +1963,12 @@ static VdpStatus _vdp_cap_output_surface_query_put_bits_indexed_capabilities(
if (_vdp_cap_data.level >= LEVEL_PARAMS) { if (_vdp_cap_data.level >= LEVEL_PARAMS) {
fprintf(_vdp_cap_data.fp, " -> %d", ret); fprintf(_vdp_cap_data.fp, " -> %d", ret);
if (ret == VDP_STATUS_OK) { if (ret == VDP_STATUS_OK) {
fprintf( if (is_supported) {
_vdp_cap_data.fp, fprintf(_vdp_cap_data.fp, ", %d", *is_supported);
", %d", }
*is_supported else {
); fputs(", ???", _vdp_cap_data.fp);
}
} }
fputs("\n", _vdp_cap_data.fp); fputs("\n", _vdp_cap_data.fp);
} }
...@@ -1965,11 +2009,12 @@ static VdpStatus _vdp_cap_output_surface_query_put_bits_y_cb_cr_capabilities( ...@@ -1965,11 +2009,12 @@ static VdpStatus _vdp_cap_output_surface_query_put_bits_y_cb_cr_capabilities(
if (_vdp_cap_data.level >= LEVEL_PARAMS) { if (_vdp_cap_data.level >= LEVEL_PARAMS) {
fprintf(_vdp_cap_data.fp, " -> %d", ret); fprintf(_vdp_cap_data.fp, " -> %d", ret);
if (ret == VDP_STATUS_OK) { if (ret == VDP_STATUS_OK) {
fprintf( if (is_supported) {
_vdp_cap_data.fp, fprintf(_vdp_cap_data.fp, ", %d", *is_supported);
", %d", }
*is_supported else {
); fputs(", ???", _vdp_cap_data.fp);
}
} }
fputs("\n", _vdp_cap_data.fp); fputs("\n", _vdp_cap_data.fp);
} }
...@@ -2013,11 +2058,12 @@ static VdpStatus _vdp_cap_output_surface_create( ...@@ -2013,11 +2058,12 @@ static VdpStatus _vdp_cap_output_surface_create(
if (_vdp_cap_data.level >= LEVEL_PARAMS) { if (_vdp_cap_data.level >= LEVEL_PARAMS) {
fprintf(_vdp_cap_data.fp, " -> %d", ret); fprintf(_vdp_cap_data.fp, " -> %d", ret);
if (ret == VDP_STATUS_OK) { if (ret == VDP_STATUS_OK) {
fprintf( if (surface) {
_vdp_cap_data.fp, fprintf(_vdp_cap_data.fp, ", %u", *surface);
", %u", }
*surface else {
); fputs(", ???", _vdp_cap_data.fp);
}
} }
fputs("\n", _vdp_cap_data.fp); fputs("\n", _vdp_cap_data.fp);
} }
...@@ -2085,13 +2131,24 @@ static VdpStatus _vdp_cap_output_surface_get_parameters( ...@@ -2085,13 +2131,24 @@ static VdpStatus _vdp_cap_output_surface_get_parameters(
if (_vdp_cap_data.level >= LEVEL_PARAMS) { if (_vdp_cap_data.level >= LEVEL_PARAMS) {
fprintf(_vdp_cap_data.fp, " -> %d", ret); fprintf(_vdp_cap_data.fp, " -> %d", ret);
if (ret == VDP_STATUS_OK) { if (ret == VDP_STATUS_OK) {
fprintf( if (rgba_format) {
_vdp_cap_data.fp, fprintf(_vdp_cap_data.fp, ", %u", *rgba_format);
", %u, %u, %u", }
*rgba_format, else {
*width, fputs(", ???", _vdp_cap_data.fp);
*height }
); if (width) {
fprintf(_vdp_cap_data.fp, ", %u", *width);
}
else {
fputs(", ???", _vdp_cap_data.fp);
}
if (height) {
fprintf(_vdp_cap_data.fp, ", %u", *height);
}
else {
fputs(", ???", _vdp_cap_data.fp);
}
} }
fputs("\n", _vdp_cap_data.fp); fputs("\n", _vdp_cap_data.fp);
} }
...@@ -2419,13 +2476,24 @@ static VdpStatus _vdp_cap_bitmap_surface_query_capabilities( ...@@ -2419,13 +2476,24 @@ static VdpStatus _vdp_cap_bitmap_surface_query_capabilities(
if (_vdp_cap_data.level >= LEVEL_PARAMS) { if (_vdp_cap_data.level >= LEVEL_PARAMS) {
fprintf(_vdp_cap_data.fp, " -> %d", ret); fprintf(_vdp_cap_data.fp, " -> %d", ret);
if (ret == VDP_STATUS_OK) { if (ret == VDP_STATUS_OK) {
fprintf( if (is_supported) {
_vdp_cap_data.fp, fprintf(_vdp_cap_data.fp, ", %d", *is_supported);
", %d, %u, %u", }
*is_supported, else {
*max_width, fputs(", ???", _vdp_cap_data.fp);
*max_height }
); if (max_width) {
fprintf(_vdp_cap_data.fp, ", %u", *max_width);
}
else {
fputs(", ???", _vdp_cap_data.fp);
}
if (max_height) {
fprintf(_vdp_cap_data.fp, ", %u", *max_height);
}
else {
fputs(", ???", _vdp_cap_data.fp);
}
} }
fputs("\n", _vdp_cap_data.fp); fputs("\n", _vdp_cap_data.fp);
} }
...@@ -2472,11 +2540,12 @@ static VdpStatus _vdp_cap_bitmap_surface_create( ...@@ -2472,11 +2540,12 @@ static VdpStatus _vdp_cap_bitmap_surface_create(
if (_vdp_cap_data.level >= LEVEL_PARAMS) { if (_vdp_cap_data.level >= LEVEL_PARAMS) {
fprintf(_vdp_cap_data.fp, " -> %d", ret); fprintf(_vdp_cap_data.fp, " -> %d", ret);
if (ret == VDP_STATUS_OK) { if (ret == VDP_STATUS_OK) {
fprintf( if (surface) {
_vdp_cap_data.fp, fprintf(_vdp_cap_data.fp, ", %u", *surface);
", %u", }
*surface else {
); fputs(", ???", _vdp_cap_data.fp);
}
} }
fputs("\n", _vdp_cap_data.fp); fputs("\n", _vdp_cap_data.fp);
} }
...@@ -2547,14 +2616,30 @@ static VdpStatus _vdp_cap_bitmap_surface_get_parameters( ...@@ -2547,14 +2616,30 @@ static VdpStatus _vdp_cap_bitmap_surface_get_parameters(
if (_vdp_cap_data.level >= LEVEL_PARAMS) { if (_vdp_cap_data.level >= LEVEL_PARAMS) {
fprintf(_vdp_cap_data.fp, " -> %d", ret); fprintf(_vdp_cap_data.fp, " -> %d", ret);
if (ret == VDP_STATUS_OK) { if (ret == VDP_STATUS_OK) {
fprintf( if (rgba_format) {
_vdp_cap_data.fp, fprintf(_vdp_cap_data.fp, ", %u", *rgba_format);
", %u, %u, %u, %d", }
*rgba_format, else {
*width, fputs(", ???", _vdp_cap_data.fp);
*height, }
*frequently_accessed if (width) {
); fprintf(_vdp_cap_data.fp, ", %u", *width);
}
else {
fputs(", ???", _vdp_cap_data.fp);
}
if (height) {
fprintf(_vdp_cap_data.fp, ", %u", *height);
}
else {
fputs(", ???", _vdp_cap_data.fp);
}
if (frequently_accessed) {
fprintf(_vdp_cap_data.fp, ", %d", *frequently_accessed);
}
else {
fputs(", ???", _vdp_cap_data.fp);
}
} }
fputs("\n", _vdp_cap_data.fp); fputs("\n", _vdp_cap_data.fp);
} }
...@@ -2779,15 +2864,36 @@ static VdpStatus _vdp_cap_decoder_query_capabilities( ...@@ -2779,15 +2864,36 @@ static VdpStatus _vdp_cap_decoder_query_capabilities(
if (_vdp_cap_data.level >= LEVEL_PARAMS) { if (_vdp_cap_data.level >= LEVEL_PARAMS) {
fprintf(_vdp_cap_data.fp, " -> %d", ret); fprintf(_vdp_cap_data.fp, " -> %d", ret);
if (ret == VDP_STATUS_OK) { if (ret == VDP_STATUS_OK) {
fprintf( if (is_supported) {
_vdp_cap_data.fp, fprintf(_vdp_cap_data.fp, ", %d", *is_supported);
", %d, %u, %u, %u, %u", }
*is_supported, else {
*max_level, fputs(", ???", _vdp_cap_data.fp);
*max_macroblocks, }
*max_width, if (max_level) {
*max_height fprintf(_vdp_cap_data.fp, ", %u", *max_level);
); }
else {
fputs(", ???", _vdp_cap_data.fp);
}
if (max_macroblocks) {
fprintf(_vdp_cap_data.fp, ", %u", *max_macroblocks);
}
else {
fputs(", ???", _vdp_cap_data.fp);
}
if (max_width) {
fprintf(_vdp_cap_data.fp, ", %u", *max_width);
}
else {
fputs(", ???", _vdp_cap_data.fp);
}
if (max_height) {
fprintf(_vdp_cap_data.fp, ", %u", *max_height);
}
else {
fputs(", ???", _vdp_cap_data.fp);
}
} }
fputs("\n", _vdp_cap_data.fp); fputs("\n", _vdp_cap_data.fp);
} }
...@@ -2834,11 +2940,12 @@ static VdpStatus _vdp_cap_decoder_create( ...@@ -2834,11 +2940,12 @@ static VdpStatus _vdp_cap_decoder_create(
if (_vdp_cap_data.level >= LEVEL_PARAMS) { if (_vdp_cap_data.level >= LEVEL_PARAMS) {
fprintf(_vdp_cap_data.fp, " -> %d", ret); fprintf(_vdp_cap_data.fp, " -> %d", ret);
if (ret == VDP_STATUS_OK) { if (ret == VDP_STATUS_OK) {
fprintf( if (decoder) {
_vdp_cap_data.fp, fprintf(_vdp_cap_data.fp, ", %u", *decoder);
", %u", }
*decoder else {
); fputs(", ???", _vdp_cap_data.fp);
}
} }
fputs("\n", _vdp_cap_data.fp); fputs("\n", _vdp_cap_data.fp);
} }
...@@ -2906,13 +3013,24 @@ static VdpStatus _vdp_cap_decoder_get_parameters( ...@@ -2906,13 +3013,24 @@ static VdpStatus _vdp_cap_decoder_get_parameters(
if (_vdp_cap_data.level >= LEVEL_PARAMS) { if (_vdp_cap_data.level >= LEVEL_PARAMS) {
fprintf(_vdp_cap_data.fp, " -> %d", ret); fprintf(_vdp_cap_data.fp, " -> %d", ret);
if (ret == VDP_STATUS_OK) { if (ret == VDP_STATUS_OK) {
fprintf( if (profile) {
_vdp_cap_data.fp, fprintf(_vdp_cap_data.fp, ", %u", *profile);
", %u, %u, %u", }
*profile, else {
*width, fputs(", ???", _vdp_cap_data.fp);
*height }
); if (width) {
fprintf(_vdp_cap_data.fp, ", %u", *width);
}
else {
fputs(", ???", _vdp_cap_data.fp);
}
if (height) {
fprintf(_vdp_cap_data.fp, ", %u", *height);
}
else {
fputs(", ???", _vdp_cap_data.fp);
}
} }
fputs("\n", _vdp_cap_data.fp); fputs("\n", _vdp_cap_data.fp);
} }
...@@ -3005,8 +3123,13 @@ static VdpStatus _vdp_cap_video_mixer_query_feature_support( ...@@ -3005,8 +3123,13 @@ static VdpStatus _vdp_cap_video_mixer_query_feature_support(
if (_vdp_cap_data.level >= LEVEL_PARAMS) { if (_vdp_cap_data.level >= LEVEL_PARAMS) {
fprintf(_vdp_cap_data.fp, " -> %d", ret); fprintf(_vdp_cap_data.fp, " -> %d", ret);
if (ret == VDP_STATUS_OK) { if (ret == VDP_STATUS_OK) {
if (is_supported) {
fprintf(_vdp_cap_data.fp, ", %d", *is_supported); fprintf(_vdp_cap_data.fp, ", %d", *is_supported);
} }
else {
fputs(", ???", _vdp_cap_data.fp);
}
}
fputs("\n", _vdp_cap_data.fp); fputs("\n", _vdp_cap_data.fp);
} }
...@@ -3043,8 +3166,13 @@ static VdpStatus _vdp_cap_video_mixer_query_parameter_support( ...@@ -3043,8 +3166,13 @@ static VdpStatus _vdp_cap_video_mixer_query_parameter_support(
if (_vdp_cap_data.level >= LEVEL_PARAMS) { if (_vdp_cap_data.level >= LEVEL_PARAMS) {
fprintf(_vdp_cap_data.fp, " -> %d", ret); fprintf(_vdp_cap_data.fp, " -> %d", ret);
if (ret == VDP_STATUS_OK) { if (ret == VDP_STATUS_OK) {
if (is_supported) {
fprintf(_vdp_cap_data.fp, ", %d", *is_supported); fprintf(_vdp_cap_data.fp, ", %d", *is_supported);
} }
else {
fputs(", ???", _vdp_cap_data.fp);
}
}
fputs("\n", _vdp_cap_data.fp); fputs("\n", _vdp_cap_data.fp);
} }
...@@ -3081,8 +3209,13 @@ static VdpStatus _vdp_cap_video_mixer_query_attribute_support( ...@@ -3081,8 +3209,13 @@ static VdpStatus _vdp_cap_video_mixer_query_attribute_support(
if (_vdp_cap_data.level >= LEVEL_PARAMS) { if (_vdp_cap_data.level >= LEVEL_PARAMS) {
fprintf(_vdp_cap_data.fp, " -> %d", ret); fprintf(_vdp_cap_data.fp, " -> %d", ret);
if (ret == VDP_STATUS_OK) { if (ret == VDP_STATUS_OK) {
if (is_supported) {
fprintf(_vdp_cap_data.fp, ", %d", *is_supported); fprintf(_vdp_cap_data.fp, ", %d", *is_supported);
} }
else {
fputs(", ???", _vdp_cap_data.fp);
}
}
fputs("\n", _vdp_cap_data.fp); fputs("\n", _vdp_cap_data.fp);
} }
...@@ -3219,11 +3352,12 @@ static VdpStatus _vdp_cap_video_mixer_create( ...@@ -3219,11 +3352,12 @@ static VdpStatus _vdp_cap_video_mixer_create(
if (_vdp_cap_data.level >= LEVEL_PARAMS) { if (_vdp_cap_data.level >= LEVEL_PARAMS) {
fprintf(_vdp_cap_data.fp, " -> %d", ret); fprintf(_vdp_cap_data.fp, " -> %d", ret);
if (ret == VDP_STATUS_OK) { if (ret == VDP_STATUS_OK) {
fprintf( if (mixer) {
_vdp_cap_data.fp, fprintf(_vdp_cap_data.fp, ", %u", *mixer);
", %u", }
*mixer else {
); fputs(", ???", _vdp_cap_data.fp);
}
} }
fputs("\n", _vdp_cap_data.fp); fputs("\n", _vdp_cap_data.fp);
} }
...@@ -3628,11 +3762,12 @@ static VdpStatus _vdp_cap_presentation_queue_create( ...@@ -3628,11 +3762,12 @@ static VdpStatus _vdp_cap_presentation_queue_create(
if (_vdp_cap_data.level >= LEVEL_PARAMS) { if (_vdp_cap_data.level >= LEVEL_PARAMS) {
fprintf(_vdp_cap_data.fp, " -> %d", ret); fprintf(_vdp_cap_data.fp, " -> %d", ret);
if (ret == VDP_STATUS_OK) { if (ret == VDP_STATUS_OK) {
fprintf( if (presentation_queue) {
_vdp_cap_data.fp, fprintf(_vdp_cap_data.fp, ", %u", *presentation_queue);
", %u", }
*presentation_queue else {
); fputs(", ???", _vdp_cap_data.fp);
}
} }
fputs("\n", _vdp_cap_data.fp); fputs("\n", _vdp_cap_data.fp);
} }
...@@ -3759,11 +3894,12 @@ static VdpStatus _vdp_cap_presentation_queue_get_time( ...@@ -3759,11 +3894,12 @@ static VdpStatus _vdp_cap_presentation_queue_get_time(
if (_vdp_cap_data.level >= LEVEL_PARAMS) { if (_vdp_cap_data.level >= LEVEL_PARAMS) {
fprintf(_vdp_cap_data.fp, " -> %d", ret); fprintf(_vdp_cap_data.fp, " -> %d", ret);
if (ret == VDP_STATUS_OK) { if (ret == VDP_STATUS_OK) {
fprintf( if (current_time) {
_vdp_cap_data.fp, fprintf(_vdp_cap_data.fp, ", %" PRIu64, *current_time);
", %" PRIu64, }
*current_time else {
); fputs(", ???", _vdp_cap_data.fp);
}
} }
fputs("\n", _vdp_cap_data.fp); fputs("\n", _vdp_cap_data.fp);
} }
...@@ -3840,11 +3976,12 @@ static VdpStatus _vdp_cap_presentation_queue_block_until_surface_idle( ...@@ -3840,11 +3976,12 @@ static VdpStatus _vdp_cap_presentation_queue_block_until_surface_idle(
if (_vdp_cap_data.level >= LEVEL_PARAMS) { if (_vdp_cap_data.level >= LEVEL_PARAMS) {
fprintf(_vdp_cap_data.fp, " -> %d", ret); fprintf(_vdp_cap_data.fp, " -> %d", ret);
if (ret == VDP_STATUS_OK) { if (ret == VDP_STATUS_OK) {
fprintf( if (first_presentation_time) {
_vdp_cap_data.fp, fprintf(_vdp_cap_data.fp, ", %" PRIu64, *first_presentation_time);
", %" PRIu64, }
*first_presentation_time else {
); fputs(", ???", _vdp_cap_data.fp);
}
} }
fputs("\n", _vdp_cap_data.fp); fputs("\n", _vdp_cap_data.fp);
} }
...@@ -3885,12 +4022,18 @@ static VdpStatus _vdp_cap_presentation_queue_query_surface_status( ...@@ -3885,12 +4022,18 @@ static VdpStatus _vdp_cap_presentation_queue_query_surface_status(
if (_vdp_cap_data.level >= LEVEL_PARAMS) { if (_vdp_cap_data.level >= LEVEL_PARAMS) {
fprintf(_vdp_cap_data.fp, " -> %d", ret); fprintf(_vdp_cap_data.fp, " -> %d", ret);
if (ret == VDP_STATUS_OK) { if (ret == VDP_STATUS_OK) {
fprintf( if (status) {
_vdp_cap_data.fp, fprintf(_vdp_cap_data.fp, ", %d", *status);
", %d, %" PRIu64, }
*status, else {
*first_presentation_time fputs(", ???", _vdp_cap_data.fp);
); }
if (first_presentation_time) {
fprintf(_vdp_cap_data.fp, ", %" PRIu64, *first_presentation_time);
}
else {
fputs(", ???", _vdp_cap_data.fp);
}
} }
fputs("\n", _vdp_cap_data.fp); fputs("\n", _vdp_cap_data.fp);
} }
...@@ -3961,11 +4104,12 @@ static VdpStatus _vdp_cap_presentation_queue_target_create_x11( ...@@ -3961,11 +4104,12 @@ static VdpStatus _vdp_cap_presentation_queue_target_create_x11(
if (_vdp_cap_data.level >= LEVEL_PARAMS) { if (_vdp_cap_data.level >= LEVEL_PARAMS) {
fprintf(_vdp_cap_data.fp, " -> %d", ret); fprintf(_vdp_cap_data.fp, " -> %d", ret);
if (ret == VDP_STATUS_OK) { if (ret == VDP_STATUS_OK) {
fprintf( if (target) {
_vdp_cap_data.fp, fprintf(_vdp_cap_data.fp, ", %u", *target);
", %u", }
*target else {
); fputs(", ???", _vdp_cap_data.fp);
}
} }
fputs("\n", _vdp_cap_data.fp); fputs("\n", _vdp_cap_data.fp);
} }
...@@ -4004,190 +4148,313 @@ static VdpStatus _vdp_cap_get_proc_address( ...@@ -4004,190 +4148,313 @@ static VdpStatus _vdp_cap_get_proc_address(
} }
else { else {
ret = VDP_STATUS_OK; ret = VDP_STATUS_OK;
*function_pointer = 0;
switch (function_id) { switch (function_id) {
case VDP_FUNC_ID_GET_ERROR_STRING: case VDP_FUNC_ID_GET_ERROR_STRING:
if (_vdp_cap_data.vdp_get_error_string) {
*function_pointer = (void *)&_vdp_cap_get_error_string; *function_pointer = (void *)&_vdp_cap_get_error_string;
}
break; break;
case VDP_FUNC_ID_GET_PROC_ADDRESS: case VDP_FUNC_ID_GET_PROC_ADDRESS:
if (_vdp_cap_data.vdp_get_proc_address) {
*function_pointer = (void *)&_vdp_cap_get_proc_address; *function_pointer = (void *)&_vdp_cap_get_proc_address;
}
break; break;
case VDP_FUNC_ID_GET_API_VERSION: case VDP_FUNC_ID_GET_API_VERSION:
if (_vdp_cap_data.vdp_get_api_version) {
*function_pointer = (void *)&_vdp_cap_get_api_version; *function_pointer = (void *)&_vdp_cap_get_api_version;
}
break; break;
case VDP_FUNC_ID_GET_INFORMATION_STRING: case VDP_FUNC_ID_GET_INFORMATION_STRING:
if (_vdp_cap_data.vdp_get_information_string) {
*function_pointer = (void *)&_vdp_cap_get_information_string; *function_pointer = (void *)&_vdp_cap_get_information_string;
}
break; break;
case VDP_FUNC_ID_DEVICE_DESTROY: case VDP_FUNC_ID_DEVICE_DESTROY:
if (_vdp_cap_data.vdp_device_destroy) {
*function_pointer = (void *)&_vdp_cap_device_destroy; *function_pointer = (void *)&_vdp_cap_device_destroy;
}
break; break;
case VDP_FUNC_ID_GENERATE_CSC_MATRIX: case VDP_FUNC_ID_GENERATE_CSC_MATRIX:
if (_vdp_cap_data.vdp_generate_csc_matrix) {
*function_pointer = (void *)&_vdp_cap_generate_csc_matrix; *function_pointer = (void *)&_vdp_cap_generate_csc_matrix;
}
break; break;
case VDP_FUNC_ID_VIDEO_SURFACE_QUERY_CAPABILITIES: case VDP_FUNC_ID_VIDEO_SURFACE_QUERY_CAPABILITIES:
if (_vdp_cap_data.vdp_video_surface_query_capabilities) {
*function_pointer = (void *)&_vdp_cap_video_surface_query_capabilities; *function_pointer = (void *)&_vdp_cap_video_surface_query_capabilities;
}
break; break;
case VDP_FUNC_ID_VIDEO_SURFACE_QUERY_GET_PUT_BITS_Y_CB_CR_CAPABILITIES: case VDP_FUNC_ID_VIDEO_SURFACE_QUERY_GET_PUT_BITS_Y_CB_CR_CAPABILITIES:
if (_vdp_cap_data.vdp_video_surface_query_get_put_bits_y_cb_cr_capabilities) {
*function_pointer = (void *)&_vdp_cap_video_surface_query_get_put_bits_y_cb_cr_capabilities; *function_pointer = (void *)&_vdp_cap_video_surface_query_get_put_bits_y_cb_cr_capabilities;
}
break; break;
case VDP_FUNC_ID_VIDEO_SURFACE_CREATE: case VDP_FUNC_ID_VIDEO_SURFACE_CREATE:
if (_vdp_cap_data.vdp_video_surface_create) {
*function_pointer = (void *)&_vdp_cap_video_surface_create; *function_pointer = (void *)&_vdp_cap_video_surface_create;
}
break; break;
case VDP_FUNC_ID_VIDEO_SURFACE_DESTROY: case VDP_FUNC_ID_VIDEO_SURFACE_DESTROY:
if (_vdp_cap_data.vdp_video_surface_destroy) {
*function_pointer = (void *)&_vdp_cap_video_surface_destroy; *function_pointer = (void *)&_vdp_cap_video_surface_destroy;
}
break; break;
case VDP_FUNC_ID_VIDEO_SURFACE_GET_PARAMETERS: case VDP_FUNC_ID_VIDEO_SURFACE_GET_PARAMETERS:
if (_vdp_cap_data.vdp_video_surface_get_parameters) {
*function_pointer = (void *)&_vdp_cap_video_surface_get_parameters; *function_pointer = (void *)&_vdp_cap_video_surface_get_parameters;
}
break; break;
case VDP_FUNC_ID_VIDEO_SURFACE_GET_BITS_Y_CB_CR: case VDP_FUNC_ID_VIDEO_SURFACE_GET_BITS_Y_CB_CR:
if (_vdp_cap_data.vdp_video_surface_get_bits_y_cb_cr) {
*function_pointer = (void *)&_vdp_cap_video_surface_get_bits_y_cb_cr; *function_pointer = (void *)&_vdp_cap_video_surface_get_bits_y_cb_cr;
}
break; break;
case VDP_FUNC_ID_VIDEO_SURFACE_PUT_BITS_Y_CB_CR: case VDP_FUNC_ID_VIDEO_SURFACE_PUT_BITS_Y_CB_CR:
if (_vdp_cap_data.vdp_video_surface_put_bits_y_cb_cr) {
*function_pointer = (void *)&_vdp_cap_video_surface_put_bits_y_cb_cr; *function_pointer = (void *)&_vdp_cap_video_surface_put_bits_y_cb_cr;
}
break; break;
case VDP_FUNC_ID_OUTPUT_SURFACE_QUERY_CAPABILITIES: case VDP_FUNC_ID_OUTPUT_SURFACE_QUERY_CAPABILITIES:
if (_vdp_cap_data.vdp_output_surface_query_capabilities) {
*function_pointer = (void *)&_vdp_cap_output_surface_query_capabilities; *function_pointer = (void *)&_vdp_cap_output_surface_query_capabilities;
}
break; break;
case VDP_FUNC_ID_OUTPUT_SURFACE_QUERY_GET_PUT_BITS_NATIVE_CAPABILITIES: case VDP_FUNC_ID_OUTPUT_SURFACE_QUERY_GET_PUT_BITS_NATIVE_CAPABILITIES:
if (_vdp_cap_data.vdp_output_surface_query_get_put_bits_native_capabilities) {
*function_pointer = (void *)&_vdp_cap_output_surface_query_get_put_bits_native_capabilities; *function_pointer = (void *)&_vdp_cap_output_surface_query_get_put_bits_native_capabilities;
}
break; break;
case VDP_FUNC_ID_OUTPUT_SURFACE_QUERY_PUT_BITS_INDEXED_CAPABILITIES: case VDP_FUNC_ID_OUTPUT_SURFACE_QUERY_PUT_BITS_INDEXED_CAPABILITIES:
if (_vdp_cap_data.vdp_output_surface_query_put_bits_indexed_capabilities) {
*function_pointer = (void *)&_vdp_cap_output_surface_query_put_bits_indexed_capabilities; *function_pointer = (void *)&_vdp_cap_output_surface_query_put_bits_indexed_capabilities;
}
break; break;
case VDP_FUNC_ID_OUTPUT_SURFACE_QUERY_PUT_BITS_Y_CB_CR_CAPABILITIES: case VDP_FUNC_ID_OUTPUT_SURFACE_QUERY_PUT_BITS_Y_CB_CR_CAPABILITIES:
if (_vdp_cap_data.vdp_output_surface_query_put_bits_y_cb_cr_capabilities) {
*function_pointer = (void *)&_vdp_cap_output_surface_query_put_bits_y_cb_cr_capabilities; *function_pointer = (void *)&_vdp_cap_output_surface_query_put_bits_y_cb_cr_capabilities;
}
break; break;
case VDP_FUNC_ID_OUTPUT_SURFACE_CREATE: case VDP_FUNC_ID_OUTPUT_SURFACE_CREATE:
if (_vdp_cap_data.vdp_output_surface_create) {
*function_pointer = (void *)&_vdp_cap_output_surface_create; *function_pointer = (void *)&_vdp_cap_output_surface_create;
}
break; break;
case VDP_FUNC_ID_OUTPUT_SURFACE_DESTROY: case VDP_FUNC_ID_OUTPUT_SURFACE_DESTROY:
if (_vdp_cap_data.vdp_output_surface_destroy) {
*function_pointer = (void *)&_vdp_cap_output_surface_destroy; *function_pointer = (void *)&_vdp_cap_output_surface_destroy;
}
break; break;
case VDP_FUNC_ID_OUTPUT_SURFACE_GET_PARAMETERS: case VDP_FUNC_ID_OUTPUT_SURFACE_GET_PARAMETERS:
if (_vdp_cap_data.vdp_output_surface_get_parameters) {
*function_pointer = (void *)&_vdp_cap_output_surface_get_parameters; *function_pointer = (void *)&_vdp_cap_output_surface_get_parameters;
}
break; break;
case VDP_FUNC_ID_OUTPUT_SURFACE_GET_BITS_NATIVE: case VDP_FUNC_ID_OUTPUT_SURFACE_GET_BITS_NATIVE:
if (_vdp_cap_data.vdp_output_surface_get_bits_native) {
*function_pointer = (void *)&_vdp_cap_output_surface_get_bits_native; *function_pointer = (void *)&_vdp_cap_output_surface_get_bits_native;
}
break; break;
case VDP_FUNC_ID_OUTPUT_SURFACE_PUT_BITS_NATIVE: case VDP_FUNC_ID_OUTPUT_SURFACE_PUT_BITS_NATIVE:
if (_vdp_cap_data.vdp_output_surface_put_bits_native) {
*function_pointer = (void *)&_vdp_cap_output_surface_put_bits_native; *function_pointer = (void *)&_vdp_cap_output_surface_put_bits_native;
}
break; break;
case VDP_FUNC_ID_OUTPUT_SURFACE_PUT_BITS_INDEXED: case VDP_FUNC_ID_OUTPUT_SURFACE_PUT_BITS_INDEXED:
if (_vdp_cap_data.vdp_output_surface_put_bits_indexed) {
*function_pointer = (void *)&_vdp_cap_output_surface_put_bits_indexed; *function_pointer = (void *)&_vdp_cap_output_surface_put_bits_indexed;
}
break; break;
case VDP_FUNC_ID_OUTPUT_SURFACE_PUT_BITS_Y_CB_CR: case VDP_FUNC_ID_OUTPUT_SURFACE_PUT_BITS_Y_CB_CR:
if (_vdp_cap_data.vdp_output_surface_put_bits_y_cb_cr) {
*function_pointer = (void *)&_vdp_cap_output_surface_put_bits_y_cb_cr; *function_pointer = (void *)&_vdp_cap_output_surface_put_bits_y_cb_cr;
}
break; break;
case VDP_FUNC_ID_BITMAP_SURFACE_QUERY_CAPABILITIES: case VDP_FUNC_ID_BITMAP_SURFACE_QUERY_CAPABILITIES:
if (_vdp_cap_data.vdp_bitmap_surface_query_capabilities) {
*function_pointer = (void *)&_vdp_cap_bitmap_surface_query_capabilities; *function_pointer = (void *)&_vdp_cap_bitmap_surface_query_capabilities;
}
break; break;
case VDP_FUNC_ID_BITMAP_SURFACE_CREATE: case VDP_FUNC_ID_BITMAP_SURFACE_CREATE:
if (_vdp_cap_data.vdp_bitmap_surface_create) {
*function_pointer = (void *)&_vdp_cap_bitmap_surface_create; *function_pointer = (void *)&_vdp_cap_bitmap_surface_create;
}
break; break;
case VDP_FUNC_ID_BITMAP_SURFACE_DESTROY: case VDP_FUNC_ID_BITMAP_SURFACE_DESTROY:
if (_vdp_cap_data.vdp_bitmap_surface_destroy) {
*function_pointer = (void *)&_vdp_cap_bitmap_surface_destroy; *function_pointer = (void *)&_vdp_cap_bitmap_surface_destroy;
}
break; break;
case VDP_FUNC_ID_BITMAP_SURFACE_GET_PARAMETERS: case VDP_FUNC_ID_BITMAP_SURFACE_GET_PARAMETERS:
if (_vdp_cap_data.vdp_bitmap_surface_get_parameters) {
*function_pointer = (void *)&_vdp_cap_bitmap_surface_get_parameters; *function_pointer = (void *)&_vdp_cap_bitmap_surface_get_parameters;
}
break; break;
case VDP_FUNC_ID_BITMAP_SURFACE_PUT_BITS_NATIVE: case VDP_FUNC_ID_BITMAP_SURFACE_PUT_BITS_NATIVE:
if (_vdp_cap_data.vdp_bitmap_surface_put_bits_native) {
*function_pointer = (void *)&_vdp_cap_bitmap_surface_put_bits_native; *function_pointer = (void *)&_vdp_cap_bitmap_surface_put_bits_native;
}
break; break;
case VDP_FUNC_ID_OUTPUT_SURFACE_RENDER_OUTPUT_SURFACE: case VDP_FUNC_ID_OUTPUT_SURFACE_RENDER_OUTPUT_SURFACE:
if (_vdp_cap_data.vdp_output_surface_render_output_surface) {
*function_pointer = (void *)&_vdp_cap_output_surface_render_output_surface; *function_pointer = (void *)&_vdp_cap_output_surface_render_output_surface;
}
break; break;
case VDP_FUNC_ID_OUTPUT_SURFACE_RENDER_BITMAP_SURFACE: case VDP_FUNC_ID_OUTPUT_SURFACE_RENDER_BITMAP_SURFACE:
if (_vdp_cap_data.vdp_output_surface_render_bitmap_surface) {
*function_pointer = (void *)&_vdp_cap_output_surface_render_bitmap_surface; *function_pointer = (void *)&_vdp_cap_output_surface_render_bitmap_surface;
}
break; break;
case VDP_FUNC_ID_DECODER_QUERY_CAPABILITIES: case VDP_FUNC_ID_DECODER_QUERY_CAPABILITIES:
if (_vdp_cap_data.vdp_decoder_query_capabilities) {
*function_pointer = (void *)&_vdp_cap_decoder_query_capabilities; *function_pointer = (void *)&_vdp_cap_decoder_query_capabilities;
}
break; break;
case VDP_FUNC_ID_DECODER_CREATE: case VDP_FUNC_ID_DECODER_CREATE:
if (_vdp_cap_data.vdp_decoder_create) {
*function_pointer = (void *)&_vdp_cap_decoder_create; *function_pointer = (void *)&_vdp_cap_decoder_create;
}
break; break;
case VDP_FUNC_ID_DECODER_DESTROY: case VDP_FUNC_ID_DECODER_DESTROY:
if (_vdp_cap_data.vdp_decoder_destroy) {
*function_pointer = (void *)&_vdp_cap_decoder_destroy; *function_pointer = (void *)&_vdp_cap_decoder_destroy;
}
break; break;
case VDP_FUNC_ID_DECODER_GET_PARAMETERS: case VDP_FUNC_ID_DECODER_GET_PARAMETERS:
if (_vdp_cap_data.vdp_decoder_get_parameters) {
*function_pointer = (void *)&_vdp_cap_decoder_get_parameters; *function_pointer = (void *)&_vdp_cap_decoder_get_parameters;
}
break; break;
case VDP_FUNC_ID_DECODER_RENDER: case VDP_FUNC_ID_DECODER_RENDER:
if (_vdp_cap_data.vdp_decoder_render) {
*function_pointer = (void *)&_vdp_cap_decoder_render; *function_pointer = (void *)&_vdp_cap_decoder_render;
}
break; break;
case VDP_FUNC_ID_VIDEO_MIXER_QUERY_FEATURE_SUPPORT: case VDP_FUNC_ID_VIDEO_MIXER_QUERY_FEATURE_SUPPORT:
if (_vdp_cap_data.vdp_video_mixer_query_feature_support) {
*function_pointer = (void *)&_vdp_cap_video_mixer_query_feature_support; *function_pointer = (void *)&_vdp_cap_video_mixer_query_feature_support;
}
break; break;
case VDP_FUNC_ID_VIDEO_MIXER_QUERY_PARAMETER_SUPPORT: case VDP_FUNC_ID_VIDEO_MIXER_QUERY_PARAMETER_SUPPORT:
if (_vdp_cap_data.vdp_video_mixer_query_parameter_support) {
*function_pointer = (void *)&_vdp_cap_video_mixer_query_parameter_support; *function_pointer = (void *)&_vdp_cap_video_mixer_query_parameter_support;
}
break; break;
case VDP_FUNC_ID_VIDEO_MIXER_QUERY_ATTRIBUTE_SUPPORT: case VDP_FUNC_ID_VIDEO_MIXER_QUERY_ATTRIBUTE_SUPPORT:
if (_vdp_cap_data.vdp_video_mixer_query_attribute_support) {
*function_pointer = (void *)&_vdp_cap_video_mixer_query_attribute_support; *function_pointer = (void *)&_vdp_cap_video_mixer_query_attribute_support;
}
break; break;
case VDP_FUNC_ID_VIDEO_MIXER_QUERY_PARAMETER_VALUE_RANGE: case VDP_FUNC_ID_VIDEO_MIXER_QUERY_PARAMETER_VALUE_RANGE:
if (_vdp_cap_data.vdp_video_mixer_query_parameter_value_range) {
*function_pointer = (void *)&_vdp_cap_video_mixer_query_parameter_value_range; *function_pointer = (void *)&_vdp_cap_video_mixer_query_parameter_value_range;
}
break; break;
case VDP_FUNC_ID_VIDEO_MIXER_QUERY_ATTRIBUTE_VALUE_RANGE: case VDP_FUNC_ID_VIDEO_MIXER_QUERY_ATTRIBUTE_VALUE_RANGE:
if (_vdp_cap_data.vdp_video_mixer_query_attribute_value_range) {
*function_pointer = (void *)&_vdp_cap_video_mixer_query_attribute_value_range; *function_pointer = (void *)&_vdp_cap_video_mixer_query_attribute_value_range;
}
break; break;
case VDP_FUNC_ID_VIDEO_MIXER_CREATE: case VDP_FUNC_ID_VIDEO_MIXER_CREATE:
if (_vdp_cap_data.vdp_video_mixer_create) {
*function_pointer = (void *)&_vdp_cap_video_mixer_create; *function_pointer = (void *)&_vdp_cap_video_mixer_create;
}
break; break;
case VDP_FUNC_ID_VIDEO_MIXER_SET_FEATURE_ENABLES: case VDP_FUNC_ID_VIDEO_MIXER_SET_FEATURE_ENABLES:
if (_vdp_cap_data.vdp_video_mixer_set_feature_enables) {
*function_pointer = (void *)&_vdp_cap_video_mixer_set_feature_enables; *function_pointer = (void *)&_vdp_cap_video_mixer_set_feature_enables;
}
break; break;
case VDP_FUNC_ID_VIDEO_MIXER_SET_ATTRIBUTE_VALUES: case VDP_FUNC_ID_VIDEO_MIXER_SET_ATTRIBUTE_VALUES:
if (_vdp_cap_data.vdp_video_mixer_set_attribute_values) {
*function_pointer = (void *)&_vdp_cap_video_mixer_set_attribute_values; *function_pointer = (void *)&_vdp_cap_video_mixer_set_attribute_values;
}
break; break;
case VDP_FUNC_ID_VIDEO_MIXER_GET_FEATURE_SUPPORT: case VDP_FUNC_ID_VIDEO_MIXER_GET_FEATURE_SUPPORT:
if (_vdp_cap_data.vdp_video_mixer_get_feature_support) {
*function_pointer = (void *)&_vdp_cap_video_mixer_get_feature_support; *function_pointer = (void *)&_vdp_cap_video_mixer_get_feature_support;
}
break; break;
case VDP_FUNC_ID_VIDEO_MIXER_GET_FEATURE_ENABLES: case VDP_FUNC_ID_VIDEO_MIXER_GET_FEATURE_ENABLES:
if (_vdp_cap_data.vdp_video_mixer_get_feature_enables) {
*function_pointer = (void *)&_vdp_cap_video_mixer_get_feature_enables; *function_pointer = (void *)&_vdp_cap_video_mixer_get_feature_enables;
}
break; break;
case VDP_FUNC_ID_VIDEO_MIXER_GET_PARAMETER_VALUES: case VDP_FUNC_ID_VIDEO_MIXER_GET_PARAMETER_VALUES:
if (_vdp_cap_data.vdp_video_mixer_get_parameter_values) {
*function_pointer = (void *)&_vdp_cap_video_mixer_get_parameter_values; *function_pointer = (void *)&_vdp_cap_video_mixer_get_parameter_values;
}
break; break;
case VDP_FUNC_ID_VIDEO_MIXER_GET_ATTRIBUTE_VALUES: case VDP_FUNC_ID_VIDEO_MIXER_GET_ATTRIBUTE_VALUES:
if (_vdp_cap_data.vdp_video_mixer_get_attribute_values) {
*function_pointer = (void *)&_vdp_cap_video_mixer_get_attribute_values; *function_pointer = (void *)&_vdp_cap_video_mixer_get_attribute_values;
}
break; break;
case VDP_FUNC_ID_VIDEO_MIXER_DESTROY: case VDP_FUNC_ID_VIDEO_MIXER_DESTROY:
if (_vdp_cap_data.vdp_video_mixer_destroy) {
*function_pointer = (void *)&_vdp_cap_video_mixer_destroy; *function_pointer = (void *)&_vdp_cap_video_mixer_destroy;
}
break; break;
case VDP_FUNC_ID_VIDEO_MIXER_RENDER: case VDP_FUNC_ID_VIDEO_MIXER_RENDER:
if (_vdp_cap_data.vdp_video_mixer_render) {
*function_pointer = (void *)&_vdp_cap_video_mixer_render; *function_pointer = (void *)&_vdp_cap_video_mixer_render;
}
break; break;
case VDP_FUNC_ID_PRESENTATION_QUEUE_TARGET_DESTROY: case VDP_FUNC_ID_PRESENTATION_QUEUE_TARGET_DESTROY:
if (_vdp_cap_data.vdp_presentation_queue_target_destroy) {
*function_pointer = (void *)&_vdp_cap_presentation_queue_target_destroy; *function_pointer = (void *)&_vdp_cap_presentation_queue_target_destroy;
}
break; break;
case VDP_FUNC_ID_PRESENTATION_QUEUE_CREATE: case VDP_FUNC_ID_PRESENTATION_QUEUE_CREATE:
if (_vdp_cap_data.vdp_presentation_queue_create) {
*function_pointer = (void *)&_vdp_cap_presentation_queue_create; *function_pointer = (void *)&_vdp_cap_presentation_queue_create;
}
break; break;
case VDP_FUNC_ID_PRESENTATION_QUEUE_DESTROY: case VDP_FUNC_ID_PRESENTATION_QUEUE_DESTROY:
if (_vdp_cap_data.vdp_presentation_queue_destroy) {
*function_pointer = (void *)&_vdp_cap_presentation_queue_destroy; *function_pointer = (void *)&_vdp_cap_presentation_queue_destroy;
}
break; break;
case VDP_FUNC_ID_PRESENTATION_QUEUE_SET_BACKGROUND_COLOR: case VDP_FUNC_ID_PRESENTATION_QUEUE_SET_BACKGROUND_COLOR:
if (_vdp_cap_data.vdp_presentation_queue_set_background_color) {
*function_pointer = (void *)&_vdp_cap_presentation_queue_set_background_color; *function_pointer = (void *)&_vdp_cap_presentation_queue_set_background_color;
}
break; break;
case VDP_FUNC_ID_PRESENTATION_QUEUE_GET_BACKGROUND_COLOR: case VDP_FUNC_ID_PRESENTATION_QUEUE_GET_BACKGROUND_COLOR:
if (_vdp_cap_data.vdp_presentation_queue_get_background_color) {
*function_pointer = (void *)&_vdp_cap_presentation_queue_get_background_color; *function_pointer = (void *)&_vdp_cap_presentation_queue_get_background_color;
}
break; break;
case VDP_FUNC_ID_PRESENTATION_QUEUE_GET_TIME: case VDP_FUNC_ID_PRESENTATION_QUEUE_GET_TIME:
if (_vdp_cap_data.vdp_presentation_queue_get_time) {
*function_pointer = (void *)&_vdp_cap_presentation_queue_get_time; *function_pointer = (void *)&_vdp_cap_presentation_queue_get_time;
}
break; break;
case VDP_FUNC_ID_PRESENTATION_QUEUE_DISPLAY: case VDP_FUNC_ID_PRESENTATION_QUEUE_DISPLAY:
if (_vdp_cap_data.vdp_presentation_queue_display) {
*function_pointer = (void *)&_vdp_cap_presentation_queue_display; *function_pointer = (void *)&_vdp_cap_presentation_queue_display;
}
break; break;
case VDP_FUNC_ID_PRESENTATION_QUEUE_BLOCK_UNTIL_SURFACE_IDLE: case VDP_FUNC_ID_PRESENTATION_QUEUE_BLOCK_UNTIL_SURFACE_IDLE:
if (_vdp_cap_data.vdp_presentation_queue_block_until_surface_idle) {
*function_pointer = (void *)&_vdp_cap_presentation_queue_block_until_surface_idle; *function_pointer = (void *)&_vdp_cap_presentation_queue_block_until_surface_idle;
}
break; break;
case VDP_FUNC_ID_PRESENTATION_QUEUE_QUERY_SURFACE_STATUS: case VDP_FUNC_ID_PRESENTATION_QUEUE_QUERY_SURFACE_STATUS:
if (_vdp_cap_data.vdp_presentation_queue_query_surface_status) {
*function_pointer = (void *)&_vdp_cap_presentation_queue_query_surface_status; *function_pointer = (void *)&_vdp_cap_presentation_queue_query_surface_status;
}
break; break;
case VDP_FUNC_ID_PREEMPTION_CALLBACK_REGISTER: case VDP_FUNC_ID_PREEMPTION_CALLBACK_REGISTER:
if (_vdp_cap_data.vdp_preemption_callback_register) {
*function_pointer = (void *)&_vdp_cap_preemption_callback_register; *function_pointer = (void *)&_vdp_cap_preemption_callback_register;
}
break; break;
case VDP_FUNC_ID_PRESENTATION_QUEUE_TARGET_CREATE_X11: case VDP_FUNC_ID_PRESENTATION_QUEUE_TARGET_CREATE_X11:
if (_vdp_cap_data.vdp_presentation_queue_target_create_x11) {
*function_pointer = (void *)&_vdp_cap_presentation_queue_target_create_x11; *function_pointer = (void *)&_vdp_cap_presentation_queue_target_create_x11;
}
break; break;
default: default:
fprintf( fprintf(
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment