summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJosé Hiram Soltren <jsoltren@nvidia.com>2012-11-14 15:06:49 -0800
committerJosé Hiram Soltren <jsoltren@nvidia.com>2012-11-14 16:29:31 -0800
commit09a467217ed3347a30c3899dace68bc24021af3f (patch)
tree496a1d01ec26723a080d975eaffb8992627bb150
parentfb754701e83d565e4333ce7d3fce216194b40266 (diff)
Only query ranges for appropriate VDPAU attributes
Update vdpauinfo.cpp to not query values from VDPAU which do not support ranges. See vdpau.h for more information.
-rw-r--r--vdpauinfo.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/vdpauinfo.cpp b/vdpauinfo.cpp
index 60f3619..062859c 100644
--- a/vdpauinfo.cpp
+++ b/vdpauinfo.cpp
@@ -287,7 +287,8 @@ void queryVideoMixer(VDPDeviceImpl *device)
is_supported = (rv == VDP_STATUS_OK && is_supported);
printf("%-32s %c ", mixer_parameters[x].name,
is_supported?'y':'-');
- if(is_supported)
+ /* VDPAU spec does not allow range query for DT_NONE types */
+ if(is_supported && mixer_parameters[x].aux != DT_NONE)
{
uint32_t minval, maxval;
rv = device->VideoMixerQueryParameterValueRange(device->device, mixer_parameters[x].id,
@@ -311,7 +312,8 @@ void queryVideoMixer(VDPDeviceImpl *device)
is_supported = (rv == VDP_STATUS_OK && is_supported);
printf("%-32s %c ", mixer_attributes[x].name,
is_supported?'y':'-');
- if(is_supported)
+ /* VDPAU spec does not allow range query for DT_NONE types */
+ if(is_supported && mixer_attributes[x].aux != DT_NONE)
{
uint32_t minval, maxval;
rv = device->VideoMixerQueryAttributeValueRange(device->device, mixer_parameters[x].id,