diff --git a/dgVoodooAPI/Bin/Release/dgVoodooAPI.dll b/dgVoodooAPI/Bin/Release/dgVoodooAPI.dll index 42d45da..d7d79f1 100644 Binary files a/dgVoodooAPI/Bin/Release/dgVoodooAPI.dll and b/dgVoodooAPI/Bin/Release/dgVoodooAPI.dll differ diff --git a/dgVoodooAPI/Bin/Spec Release/dgVoodooAPI.dll b/dgVoodooAPI/Bin/Spec Release/dgVoodooAPI.dll index b50dd08..dcb5eec 100644 Binary files a/dgVoodooAPI/Bin/Spec Release/dgVoodooAPI.dll and b/dgVoodooAPI/Bin/Spec Release/dgVoodooAPI.dll differ diff --git a/dgVoodooAPI/Doc/dgVoodooAPI.chm b/dgVoodooAPI/Doc/dgVoodooAPI.chm index c692fdb..bdab889 100644 Binary files a/dgVoodooAPI/Doc/dgVoodooAPI.chm and b/dgVoodooAPI/Doc/dgVoodooAPI.chm differ diff --git a/dgVoodooAPI/Inc/APIDebugObj.hpp b/dgVoodooAPI/Inc/APIDebugObj.hpp index aedda99..aa18f8c 100644 --- a/dgVoodooAPI/Inc/APIDebugObj.hpp +++ b/dgVoodooAPI/Inc/APIDebugObj.hpp @@ -57,8 +57,8 @@ struct APIDebugObj { return infoLevel; } - - + + WarningLevel inline GetWarningLevel () const { return warningLevel; @@ -70,7 +70,7 @@ struct APIDebugObj return errorLevel; } - + UInt32 inline GetMaxTraceLevel () const { return maxTraceLevel; @@ -88,7 +88,7 @@ struct APIDebugObj pOutputStream = _pOutputStream; } - + APIDebugObj (InfoLevel _infoLevel, WarningLevel _warningLevel, ErrorLevel _errorLevel, const char* _pPrefixString, UInt32 _maxTraceLevel, IAPIDataStream* _pOutputStream = NULL): infoLevel (_infoLevel), diff --git a/dgVoodooAPI/Inc/APIObject.hpp b/dgVoodooAPI/Inc/APIObject.hpp index d33e19d..60d0eed 100644 --- a/dgVoodooAPI/Inc/APIObject.hpp +++ b/dgVoodooAPI/Inc/APIObject.hpp @@ -5,7 +5,7 @@ // // Contact person: DG // -// ***************************************************************************** +// ***************************************************************************** #ifndef APIOBJECT_HPP #define APIOBJECT_HPP diff --git a/dgVoodooAPI/Inc/IAPIDataStream.hpp b/dgVoodooAPI/Inc/IAPIDataStream.hpp index a0a76a1..4e354f6 100644 --- a/dgVoodooAPI/Inc/IAPIDataStream.hpp +++ b/dgVoodooAPI/Inc/IAPIDataStream.hpp @@ -21,7 +21,7 @@ namespace dgVoodoo { class IAPIDataStream { public: - + enum Origin { OSet = 0, diff --git a/dgVoodooAPI/Inc/dgVoodooConfig.hpp b/dgVoodooAPI/Inc/dgVoodooConfig.hpp index 2e2f21c..0c9ac0f 100644 --- a/dgVoodooAPI/Inc/dgVoodooConfig.hpp +++ b/dgVoodooAPI/Inc/dgVoodooConfig.hpp @@ -194,27 +194,38 @@ struct ConfigGeneralExt }; - UInt32 desktopResWidth; - UInt32 desktopResHeight; - UInt32 desktopRefRateNumerator; - UInt32 desktopRefRateDenominator; - UInt32 desktopBitDepth; - UInt32 deframerSize; - UInt32 imageXScaleFactor; - UInt32 imageYScaleFactor; - UInt32 cursorScaleFactor; - UInt32 displayROIPosX; - UInt32 displayROIPosY; - UInt32 displayROISizeX; - UInt32 displayROISizeY; - Environment environment; - UInt32 windowedAttributes; - UInt32 fullscreenAttributes; - Resampling resampling; - UInt32 fpsLimitNumerator; - UInt32 fpsLimitDenominator; - bool freeMouse; - bool enableGDIHooking; + enum PresentationModel + { + PM_Automatic = 0, + PM_Discard, + PM_Sequential, + PM_FlipDiscard, + PM_FlipSequential + }; + + + UInt32 desktopResWidth; + UInt32 desktopResHeight; + UInt32 desktopRefRateNumerator; + UInt32 desktopRefRateDenominator; + UInt32 desktopBitDepth; + UInt32 deframerSize; + UInt32 imageXScaleFactor; + UInt32 imageYScaleFactor; + UInt32 cursorScaleFactor; + UInt32 displayROIPosX; + UInt32 displayROIPosY; + UInt32 displayROISizeX; + UInt32 displayROISizeY; + Environment environment; + UInt32 windowedAttributes; + UInt32 fullscreenAttributes; + Resampling resampling; + PresentationModel presentationModel; + UInt32 fpsLimitNumerator; + UInt32 fpsLimitDenominator; + bool freeMouse; + bool enableGDIHooking; ConfigGeneralExt (): desktopResWidth (0), @@ -234,6 +245,7 @@ struct ConfigGeneralExt windowedAttributes (WA_DefaultAttributes), fullscreenAttributes (FSA_DefaultAttributes), resampling (RS_Bilinear), + presentationModel (PM_Automatic), fpsLimitNumerator (0), fpsLimitDenominator (0), freeMouse (false), @@ -524,12 +536,12 @@ struct ConfigDirectXExt UInt32 enumeratedResolutionBitDepths; UInt32 maxVSConstRegisters; UInt32 nPatchTesselationLevel; + UInt32 renderingOutputEnablingMask; bool msD3DDeviceNames; bool rtTexturesForceScaleAndMSAA; bool smoothedDepthSampling; bool deferredScreenModeSwitch; bool primarySurfaceBatchedUpdate; - bool enableSpecializedShaders; ConfigDirectXExt () : adapterIDType (AIDT_Default), @@ -546,12 +558,12 @@ struct ConfigDirectXExt enumeratedResolutionBitDepths (ERBD_All), maxVSConstRegisters (256), nPatchTesselationLevel (0), + renderingOutputEnablingMask (0xFFFFFFFF), msD3DDeviceNames (false), rtTexturesForceScaleAndMSAA (true), smoothedDepthSampling (true), deferredScreenModeSwitch (false), - primarySurfaceBatchedUpdate (false), - enableSpecializedShaders (true) + primarySurfaceBatchedUpdate (false) { memset (extraResolutions, 0, sizeof (extraResolutions)); } diff --git a/dgVoodooAPI/Lib/dgVoodooAPI.lib b/dgVoodooAPI/Lib/dgVoodooAPI.lib index df9e051..1f0a38c 100644 Binary files a/dgVoodooAPI/Lib/dgVoodooAPI.lib and b/dgVoodooAPI/Lib/dgVoodooAPI.lib differ diff --git a/dgVoodooAPI/SampleApp/SampleApp.cpp b/dgVoodooAPI/SampleApp/SampleApp.cpp index 91fcbcd..95d6041 100644 --- a/dgVoodooAPI/SampleApp/SampleApp.cpp +++ b/dgVoodooAPI/SampleApp/SampleApp.cpp @@ -81,8 +81,8 @@ static void ConfigFromCustomINIStream (IMainFactory* pFactory) status = (currentPos >= 0 && currentPos < (Int32) strlen (pStreamData)) ? StatusOk : StatusError; return status; } - - + + virtual Status Read (UInt32 count, void* buffer, UInt32* readBytes = NULL) const { if (status == IAPIDataStream::StatusOk) { @@ -98,8 +98,8 @@ static void ConfigFromCustomINIStream (IMainFactory* pFactory) } return status; } - - + + virtual Status Write (UInt32 /*count*/, void* /*buffer*/, UInt32* /*writtenBytes*/) const { // no need to implement @@ -124,7 +124,7 @@ static void ConfigFromCustomINIStream (IMainFactory* pFactory) IConfig* pConfig = pFactory->GetIConfig (); if (pConfig != NULL) { - + // --- Test for a right configuration { const char* pStreamData = "version = 0x255\n"\ @@ -169,15 +169,15 @@ static void ConfigFromCustomINIStream (IMainFactory* pFactory) // no need to implement return StatusError; } - - + + virtual Status Read (UInt32 count, void* buffer, UInt32* readBytes = NULL) const { // no need to implement return StatusError; } - - + + virtual Status Write (UInt32 count, void* buffer, UInt32* writtenBytes) const { // Ok, it's a lame solution here, serves only demonstrating purposes @@ -231,7 +231,7 @@ static void INIPropertySetRead (IMainFactory* pFactory) if (pParser->Parse ("TestFiles\\INIPropertySet.ini", IIniParser::LowerCase)) { printf ("INIPropertySet.ini is successfully parsed. Dumping its content:\n\n"); - + // Dump the property set to the console window for (UInt32 i = 0; i < pParser->GetNumberOfSections (); i++) { const char* pSectionName = pParser->GetSectionName (i); @@ -286,7 +286,7 @@ static void DumpGraphicsSystemInformation (IMainFactory* pFactory) pCPLDDI->GetAdapterName (i, adapterName); printf ("\nAdapter %i: %ls", i, adapterName); - + UInt32 numOutputs = pCPLDDI->GetNumberOfOutputs (i); printf ("\n Number of outputs: %d\n", numOutputs); for (UInt32 j = 0; j < numOutputs; j++) { @@ -322,7 +322,7 @@ int main() ConfigReadWrite (pFactory); ConfigFromCustomINIStream (pFactory); INIPropertySetRead (pFactory); - DumpGraphicsSystemInformation (pFactory); + DumpGraphicsSystemInformation (pFactory); dgVoodoo_API_Exit (); }