- Mesaj
- 595
- Çözümler
- 18
- Beğeni
- 618
- Puan
- 829
- Ticaret Puanı
- 0
MSAA YOKKEN
MSAA VARKEN (8x)
EterLib/GrpDevice.cpp içinde aratılır:
MSAA VARKEN (8x)
C++:
ms_dwD3DBehavior = pkD3DModeInfo->m_dwD3DBehavior;
ve hemen üstüne eklenir;
C++:
for (uint8_t i = 0; i <= D3DMULTISAMPLE_8_SAMPLES; i++)
{
const auto multisamplelevel = static_cast<D3DMULTISAMPLE_TYPE>(i);
const auto result = ms_lpd3d->CheckDeviceMultiSampleType(ms_iD3DAdapterInfo, D3DDEVTYPE_HAL, ms_d3dPresentParameter.BackBufferFormat, Windowed, multisamplelevel, nullptr); // !!! REMOVE nullptr FOR DX8 !!!
if (SUCCEEDED(result))
{
#ifdef _DEBUG
TraceError("multisamplelevel == %u", multisamplelevel);
#endif
ms_d3dPresentParameter.MultiSampleType = multisamplelevel;
}
}
EterLib/GrpScreen.cpp içinde aratılır:
C++:
void CScreen::RenderBar3d(float sx, float sy, float sz, float ex, float ey, float ez)
ve fonksiyon komple değiştirilir;
C++:
void CScreen::RenderBar3d(float sx, float sy, float sz, float ex, float ey, float ez)
{
assert(ms_lpd3dDevice != NULL);
SPDTVertexRaw vertices[4] =
{
// HARD FIX BEGIN
{ sx - 0.5f, sy - 0.5f, sz, ms_diffuseColor, 0.0f, 0.0f },
{ sx - 0.5f, ey - 0.5f, ez, ms_diffuseColor, 0.0f, 0.0f },
{ ex - 0.5f, sy - 0.5f, sz, ms_diffuseColor, 0.0f, 0.0f },
{ ex - 0.5f, ey - 0.5f, ez, ms_diffuseColor, 0.0f, 0.0f },
// HARD FIX END
};
if (SetPDTStream(vertices, 4))
{
STATEMANAGER.SetTexture(0, NULL);
STATEMANAGER.SetTexture(1, NULL);
STATEMANAGER.SetVertexShader(D3DFVF_XYZ|D3DFVF_DIFFUSE|D3DFVF_TEX1);
STATEMANAGER.DrawPrimitive(D3DPT_TRIANGLESTRIP, 0, 2);
}
}
Otomatik olarak aygıt desteğini 8X e kadar tarar ve en yüksek olanı seçer. normal şartlarda D3DMULTISAMPLE_16_SAMPLES (16x) desteklenmiyor ama vulkan gibi d3d wrapper kullanılırsa destekliyor tabii tam ekran modda oyun çöküyor o yüzden en fazla D3DMULTISAMPLE_8_SAMPLES (8x) e kadar taramasını sağladım. (intel arc kaynaklı sıkıntı olabilir)..
Son düzenleme: