mirror of
https://port.numenaute.org/aleajactaest/khanat-opennel-code.git
synced 2024-11-27 09:36:15 +00:00
Fixes for d3d
This commit is contained in:
parent
b77101cdd4
commit
2ee6843cd9
2 changed files with 5 additions and 5 deletions
|
@ -57,7 +57,7 @@ CPixelProgramDrvInfosD3D::~CPixelProgramDrvInfosD3D()
|
||||||
bool CDriverD3D::supportPixelProgram (CPixelProgram::TProfile profile) const
|
bool CDriverD3D::supportPixelProgram (CPixelProgram::TProfile profile) const
|
||||||
{
|
{
|
||||||
H_AUTO_D3D(CDriverD3D_supportPixelProgram_profile)
|
H_AUTO_D3D(CDriverD3D_supportPixelProgram_profile)
|
||||||
return ((profile & 0xFFFF0000) == 0xD3D00000)
|
return ((profile & 0xFFFF0000) == 0xD9020000)
|
||||||
&& (_PixelProgramVersion >= (uint16)(profile & 0x0000FFFF));
|
&& (_PixelProgramVersion >= (uint16)(profile & 0x0000FFFF));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -118,7 +118,6 @@ const char *a_ps_2_0 =
|
||||||
"mov r0.yzw, r2\n"
|
"mov r0.yzw, r2\n"
|
||||||
"cmp r0.x, -r0, r1, r2\n"
|
"cmp r0.x, -r0, r1, r2\n"
|
||||||
"mov oC0, r0\n";
|
"mov oC0, r0\n";
|
||||||
;
|
|
||||||
|
|
||||||
class CStereoDebuggerFactory : public IStereoDeviceFactory
|
class CStereoDebuggerFactory : public IStereoDeviceFactory
|
||||||
{
|
{
|
||||||
|
@ -156,6 +155,7 @@ void CStereoDebugger::setDriver(NL3D::UDriver *driver)
|
||||||
{
|
{
|
||||||
nlassert(!m_PixelProgram);
|
nlassert(!m_PixelProgram);
|
||||||
|
|
||||||
|
m_Driver = driver;
|
||||||
NL3D::IDriver *drvInternal = (static_cast<CDriverUser *>(driver))->getDriver();
|
NL3D::IDriver *drvInternal = (static_cast<CDriverUser *>(driver))->getDriver();
|
||||||
|
|
||||||
if (drvInternal->supportBloomEffect() && drvInternal->supportNonPowerOfTwoTextures())
|
if (drvInternal->supportBloomEffect() && drvInternal->supportNonPowerOfTwoTextures())
|
||||||
|
@ -179,6 +179,8 @@ void CStereoDebugger::setDriver(NL3D::UDriver *driver)
|
||||||
}
|
}
|
||||||
if (!drvInternal->compilePixelProgram(m_PixelProgram))
|
if (!drvInternal->compilePixelProgram(m_PixelProgram))
|
||||||
{
|
{
|
||||||
|
nlwarning("No supported pixel program for stereo debugger");
|
||||||
|
|
||||||
delete m_PixelProgram;
|
delete m_PixelProgram;
|
||||||
m_PixelProgram = NULL;
|
m_PixelProgram = NULL;
|
||||||
}
|
}
|
||||||
|
@ -186,8 +188,6 @@ void CStereoDebugger::setDriver(NL3D::UDriver *driver)
|
||||||
|
|
||||||
if (m_PixelProgram)
|
if (m_PixelProgram)
|
||||||
{
|
{
|
||||||
m_Driver = driver;
|
|
||||||
|
|
||||||
initTextures();
|
initTextures();
|
||||||
|
|
||||||
m_Mat = m_Driver->createMaterial();
|
m_Mat = m_Driver->createMaterial();
|
||||||
|
|
Loading…
Reference in a new issue