Add multisampling to librw

This commit is contained in:
Sergeanur 2020-11-28 15:13:06 +02:00
parent f50a53e290
commit 18d0fd2e48
5 changed files with 10 additions and 3 deletions

View File

@ -353,5 +353,4 @@ enum Config {
#ifdef LIBRW
// these are not supported with librw yet
# undef MULTISAMPLING
#endif

View File

@ -601,6 +601,9 @@ void RwD3D8EngineSetRefreshRate(RwUInt32 refreshRate) {}
RwBool RwD3D8DeviceSupportsDXTTexture(void) { return true; }
void RwD3D8EngineSetMultiSamplingLevels(RwUInt32 level) { Engine::setMultiSamplingLevels(level); }
RwUInt32 RwD3D8EngineGetMaxMultiSamplingLevels(void) { return Engine::getMaxMultiSamplingLevels(); }
RpMaterial *RpMaterialCreate(void) { return Material::create(); }
RwBool RpMaterialDestroy(RpMaterial *material) { material->destroy(); return true; }

View File

@ -411,3 +411,5 @@ RwFrame *RwCameraGetFrame(const RwCamera *camera);
void RwD3D8EngineSetRefreshRate(RwUInt32 refreshRate);
RwBool RwD3D8DeviceSupportsDXTTexture(void);
void RwD3D8EngineSetMultiSamplingLevels(RwUInt32 level);
RwUInt32 RwD3D8EngineGetMaxMultiSamplingLevels(void);

View File

@ -833,7 +833,10 @@ psSelectDevice()
PSGLOBAL(fullScreen) = !FrontEndMenuManager.m_nPrefsWindowed;
#endif
#ifdef MULTISAMPLING
RwD3D8EngineSetMultiSamplingLevels(1 << FrontEndMenuManager.m_nPrefsMSAALevel);
#endif
return TRUE;
}

2
vendor/librw vendored

@ -1 +1 @@
Subproject commit e8990d5b3d50be72594f93dcc42d749f29761516
Subproject commit 2066cf6634383e056cd5dda105e87f8da04b1ed8