问题描述
这里我们使用directx 9.0c和c#3.5,并提供directx的参考
代码..
foreach(devTypeArray中的DeviceType devType)
$
GraphicsDeviceInfo deviceInfo = new GraphicsDeviceInfo();
deviceInfo.AdapterOrdinal = adapterInfo.AdapterOrdinal;
deviceInfo.DevType = devType;
尝试
{
deviceInfo.Caps = Manager.GetDeviceCaps(adapterInfo.AdapterOrdinal,devType);
}
catch(DirectXException)
{
继续;
}
//获取此设备上每个devicecombo的信息
EnumerateDeviceCombos(deviceInfo,adapterFormatList);
//如果在找到此设备的至少一个devicecombo,
//将deviceInfo添加到列表
if(deviceInfo.DeviceComboList.Count == 0)
继续;
adapterInfo.DeviceInfoList.Add(deviceInfo);
}
devTypeArray零计数..
请建议我如何在XP 64位中运行directx版本..
here we using directx 9.0c and c# 3.5, and provide reference of directx
code..
foreach (DeviceType devType in devTypeArray)
{
GraphicsDeviceInfo deviceInfo = new GraphicsDeviceInfo();
deviceInfo.AdapterOrdinal = adapterInfo.AdapterOrdinal;
deviceInfo.DevType = devType;
try
{
deviceInfo.Caps = Manager.GetDeviceCaps(adapterInfo.AdapterOrdinal, devType);
}
catch (DirectXException)
{
continue;
}
// Get info for each devicecombo on this device
EnumerateDeviceCombos(deviceInfo, adapterFormatList);
// If at least one devicecombo for this device is found,
// add the deviceInfo to the list
if (deviceInfo.DeviceComboList.Count == 0)
continue;
adapterInfo.DeviceInfoList.Add(deviceInfo);
}
devTypeArray got zero count..
please suggest me how to work directx version in XP 64 bit..
推荐答案
- 确保代码编译为64位。
- 确保你在目标机器上有合适的dll。
祝你好运!
Good Luck!
这篇关于基于directx 9.0c的代码不工作窗口xp 64位操作系统的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!