Reintegrated GSopen2 branch. Rundown of new features:

* Implemented proper shader management, fixes several bugs where video would be lost or crash, and is a small speedup.
 * Retains GS state across open/close, same as every other PS2E plugin now.
 * Implemented GSopen2(), which is used by wx-pcsx2 to bind the GS output to a window handle of pcsx2's choosing.
 * Retained full backwards compat with the current legacy gui. :)

git-svn-id: http://pcsx2.googlecode.com/svn/trunk@1871 96395faa-99c1-11dd-bbfe-3dabce05a288
This commit is contained in:
Jake.Stine 2009-09-19 08:51:11 +00:00
commit ac88159fb3
58 changed files with 28199 additions and 912 deletions

12262
3rdparty/GL/glew.h vendored Normal file

File diff suppressed because it is too large Load Diff

1397
3rdparty/GL/glxew.h vendored Normal file

File diff suppressed because it is too large Load Diff

1165
3rdparty/GL/wglew.h vendored Normal file

File diff suppressed because it is too large Load Diff

12180
3rdparty/glew/glew.c vendored Normal file

File diff suppressed because it is too large Load Diff

77
3rdparty/glew/glew.rc vendored Normal file
View File

@ -0,0 +1,77 @@
#include <windows.h>
#ifdef GLEW_MX
# ifdef GLEW_STATIC
# ifdef _DEBUG
# define FILENAME "glew32mxsd.dll"
# else
# define FILENAME "glew32mxs.dll"
# endif
# else
# ifdef _DEBUG
# define FILENAME "glew32mxd.dll"
# else
# define FILENAME "glew32mx.dll"
# endif
# endif
#else
# ifdef GLEW_STATIC
# ifdef _DEBUG
# define FILENAME "glew32sd.dll"
# else
# define FILENAME "glew32s.dll"
# endif
# else
# ifdef _DEBUG
# define FILENAME "glew32d.dll"
# else
# define FILENAME "glew32.dll"
# endif
# endif
#endif
/////////////////////////////////////////////////////////////////////////////
//
// Version
//
VS_VERSION_INFO VERSIONINFO
FILEVERSION 1, 5, 1, 0
PRODUCTVERSION 1, 5, 1, 0
FILEFLAGSMASK VS_FFI_FILEFLAGSMASK
#ifdef _DEBUG
FILEFLAGS VS_FF_DEBUG
#else
FILEFLAGS 0x0L
#endif
FILEOS VOS__WINDOWS32
#ifdef GLEW_STATIC
FILETYPE VFT_STATIC_LIB
#else
FILETYPE VFT_DLL
#endif
FILESUBTYPE VFT2_UNKNOWN
BEGIN
BLOCK "StringFileInfo"
BEGIN
BLOCK "040904b0"
BEGIN
VALUE "Comments", "The OpenGL Extension Wrangler Library\r\nCopyright (C) 2002-2008, Milan Ikits <milan ikits[]ieee org>\r\nCopyright (C) 2002-2008, Marcelo E. Magallon <mmagallo[]debian org>\r\nCopyright (C) 2002, Lev Povalahev\r\nAll rights reserved.\r\n\r\nRedistribution and use in source and binary forms, with or without \r\nmodification, are permitted provided that the following conditions are met:\r\n\r\n* Redistributions of source code must retain the above copyright notice, \r\n this list of conditions and the following disclaimer.\r\n* Redistributions in binary form must reproduce the above copyright notice, \r\n this list of conditions and the following disclaimer in the documentation \r\n and/or other materials provided with the distribution.\r\n* The name of the author may be used to endorse or promote products \r\n derived from this software without specific prior written permission.\r\n\r\nTHIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS ''AS IS'' \r\nAND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE \r\nIMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE\r\nARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE \r\nLIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR \r\nCONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF \r\nSUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS\r\nINTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN\r\nCONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)\r\nARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF\r\nTHE POSSIBILITY OF SUCH DAMAGE.\r\n\r\n\r\nMesa 3-D graphics library\r\n\r\nVersion: 7.0\r\n\r\nCopyright (C) 1999-2007 Brian Paul All Rights Reserved.\r\n\r\nPermission is hereby granted, free of charge, to any person obtaining a\r\ncopy of this software and associated documentation files (the ''Software''),\r\nto deal in the Software without restriction, including without limitation\r\nthe rights to use, copy, modify, merge, publish, distribute, sublicense,\r\nand/or sell copies of the Software, and to permit persons to whom the\r\nSoftware is furnished to do so, subject to the following conditions:\r\n\r\nThe above copyright notice and this permission notice shall be included\r\nin all copies or substantial portions of the Software.\r\n\r\nTHE SOFTWARE IS PROVIDED ''AS IS'', WITHOUT WARRANTY OF ANY KIND, EXPRESS\r\nOR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\r\nFITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL\r\nBRIAN PAUL BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN\r\nAN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN\r\nCONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.\r\n\r\n\r\nCopyright (c) 2007 The Khronos Group Inc.\r\n\r\nPermission is hereby granted, free of charge, to any person obtaining a\r\ncopy of this software and/or associated documentation files (the\r\n''Materials''), to deal in the Materials without restriction, including\r\nwithout limitation the rights to use, copy, modify, merge, publish,\r\ndistribute, sublicense, and/or sell copies of the Materials, and to\r\npermit persons to whom the Materials are furnished to do so, subject to\r\nthe following conditions:\r\n\r\nThe above copyright notice and this permission notice shall be included\r\nin all copies or substantial portions of the Materials.\r\n\r\nTHE MATERIALS ARE PROVIDED ''AS IS'', WITHOUT WARRANTY OF ANY KIND,\r\nEXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF\r\nMERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.\r\nIN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY\r\nCLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,\r\nTORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE\r\nMATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.\0"
VALUE "CompanyName", "\0"
VALUE "FileDescription", "The OpenGL Extension Wrangler Library\0"
VALUE "FileVersion", "1,5,1,0\0"
VALUE "InternalName", "GLEW\0"
VALUE "LegalCopyright", "© 2002-2008 Milan Ikits & Marcelo Magallon\0"
VALUE "LegalTrademarks", "\0"
VALUE "OriginalFilename", FILENAME "\0"
VALUE "PrivateBuild", "\0"
VALUE "ProductName", "The OpenGL Extension Wrangler Library\0"
VALUE "ProductVersion", "1,5,1,0\0"
VALUE "SpecialBuild", "\0"
END
END
BLOCK "VarFileInfo"
BEGIN
VALUE "Translation", 0x409, 1200
END
END

218
3rdparty/glew/glew_static_vs2008.vcproj vendored Normal file
View File

@ -0,0 +1,218 @@
<?xml version="1.0" encoding="Windows-1252"?>
<VisualStudioProject
ProjectType="Visual C++"
Version="9.00"
Name="glew_static"
ProjectGUID="{067D7863-393B-494F-B296-4A8853EB3D1D}"
RootNamespace="glew_static"
TargetFrameworkVersion="196613"
>
<Platforms>
<Platform
Name="Win32"
/>
</Platforms>
<ToolFiles>
</ToolFiles>
<Configurations>
<Configuration
Name="Debug|Win32"
ConfigurationType="4"
InheritedPropertySheets="..\3rdparty.vsprops;..\..\common\vsprops\CodeGen_Debug.vsprops;..\..\common\vsprops\IncrementalLinking.vsprops"
CharacterSet="2"
>
<Tool
Name="VCPreBuildEventTool"
/>
<Tool
Name="VCCustomBuildTool"
/>
<Tool
Name="VCXMLDataGeneratorTool"
/>
<Tool
Name="VCWebServiceProxyGeneratorTool"
/>
<Tool
Name="VCMIDLTool"
/>
<Tool
Name="VCCLCompilerTool"
PreprocessorDefinitions="GLEW_STATIC"
/>
<Tool
Name="VCManagedResourceCompilerTool"
/>
<Tool
Name="VCResourceCompilerTool"
/>
<Tool
Name="VCPreLinkEventTool"
/>
<Tool
Name="VCLibrarianTool"
/>
<Tool
Name="VCALinkTool"
/>
<Tool
Name="VCXDCMakeTool"
/>
<Tool
Name="VCBscMakeTool"
/>
<Tool
Name="VCFxCopTool"
/>
<Tool
Name="VCPostBuildEventTool"
/>
</Configuration>
<Configuration
Name="Release|Win32"
ConfigurationType="4"
InheritedPropertySheets="..\3rdparty.vsprops;..\..\common\vsprops\CodeGen_Release.vsprops"
CharacterSet="2"
WholeProgramOptimization="1"
>
<Tool
Name="VCPreBuildEventTool"
/>
<Tool
Name="VCCustomBuildTool"
/>
<Tool
Name="VCXMLDataGeneratorTool"
/>
<Tool
Name="VCWebServiceProxyGeneratorTool"
/>
<Tool
Name="VCMIDLTool"
/>
<Tool
Name="VCCLCompilerTool"
PreprocessorDefinitions="GLEW_STATIC"
WarningLevel="3"
/>
<Tool
Name="VCManagedResourceCompilerTool"
/>
<Tool
Name="VCResourceCompilerTool"
/>
<Tool
Name="VCPreLinkEventTool"
/>
<Tool
Name="VCLibrarianTool"
/>
<Tool
Name="VCALinkTool"
/>
<Tool
Name="VCXDCMakeTool"
/>
<Tool
Name="VCBscMakeTool"
/>
<Tool
Name="VCFxCopTool"
/>
<Tool
Name="VCPostBuildEventTool"
/>
</Configuration>
<Configuration
Name="Devel|Win32"
ConfigurationType="4"
InheritedPropertySheets="..\3rdparty.vsprops;..\..\common\vsprops\CodeGen_Devel.vsprops;..\..\common\vsprops\IncrementalLinking.vsprops"
CharacterSet="2"
WholeProgramOptimization="0"
>
<Tool
Name="VCPreBuildEventTool"
/>
<Tool
Name="VCCustomBuildTool"
/>
<Tool
Name="VCXMLDataGeneratorTool"
/>
<Tool
Name="VCWebServiceProxyGeneratorTool"
/>
<Tool
Name="VCMIDLTool"
/>
<Tool
Name="VCCLCompilerTool"
PreprocessorDefinitions="GLEW_STATIC"
WarningLevel="3"
/>
<Tool
Name="VCManagedResourceCompilerTool"
/>
<Tool
Name="VCResourceCompilerTool"
/>
<Tool
Name="VCPreLinkEventTool"
/>
<Tool
Name="VCLibrarianTool"
/>
<Tool
Name="VCALinkTool"
/>
<Tool
Name="VCXDCMakeTool"
/>
<Tool
Name="VCBscMakeTool"
/>
<Tool
Name="VCFxCopTool"
/>
<Tool
Name="VCPostBuildEventTool"
/>
</Configuration>
</Configurations>
<References>
</References>
<Files>
<Filter
Name="Source Files"
Filter="cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
>
<File
RelativePath=".\glew.c"
>
</File>
</Filter>
<Filter
Name="Header Files"
Filter="h;hpp;hxx;hm;inl"
>
<File
RelativePath="..\GL\glew.h"
>
</File>
<File
RelativePath="..\GL\wglew.h"
>
</File>
</Filter>
<Filter
Name="Resources"
>
<File
RelativePath=".\glew.rc"
>
</File>
</Filter>
</Files>
<Globals>
</Globals>
</VisualStudioProject>

View File

@ -2,9 +2,21 @@
Folder: /3rdparty Folder: /3rdparty
This folder contains libraries written and (un?)maintained by people or parties This folder contains libraries written and (un?)maintained by people or parties
outside the Pcsx2 DevTeam. Libraries or code snippets written by the Pcsx2 team outside the Pcsx2 DevTeam. Libraries or code snippets written by the PCSX2 team
are housed in /common instead. are housed in /common instead.
Cross-Compilation:
Most libraries includes in /3rdparty come as either default installations in Linux
distributions, or are easily obtainable. Using the PCSX2 versions included here is
optional in such cases, however using the distro-provided packages is not recommended.
(using PCSX2 included versions may help resolve versioning issues).
Note that wxWidgets includes *only* MSW projects and files. Linux and Mac platforms
are assumed to have wx already available in your distributions.
Modifications:
Most of these libs in /3rdparty have been tailored slightly from the original Most of these libs in /3rdparty have been tailored slightly from the original
forms downloaded from the net. So if you want to upgrade to a new version you forms downloaded from the net. So if you want to upgrade to a new version you
will need to do a proper diff merge. Likewise, if you modify anything in a will need to do a proper diff merge. Likewise, if you modify anything in a

View File

@ -9,4 +9,4 @@
:: so, don't go running this batch file in your root c:\ folder. It's probably not a wise action. :: so, don't go running this batch file in your root c:\ folder. It's probably not a wise action.
:: Enjoy. :) :: Enjoy. :)
del /s *.ncb;*.ilk;*.pdb;*.bsc;*.sbr;*.res del /s *.ncb;*.ilk;*.pdb;*.bsc;*.sbr;*.res;*.pch

View File

@ -511,7 +511,7 @@ typedef char*(CALLBACK* _PS2EgetLibName)(void);
// NOTE: GSreadFIFOX/GSwriteCSR functions CANNOT use XMM/MMX regs // NOTE: GSreadFIFOX/GSwriteCSR functions CANNOT use XMM/MMX regs
// If you want to use them, need to save and restore current ones // If you want to use them, need to save and restore current ones
typedef s32 (CALLBACK* _GSopen)(void *pDsp, char *Title, int multithread); typedef s32 (CALLBACK* _GSopen)(void *pDsp, char *Title, int multithread);
typedef s32 (CALLBACK* _GSopen2)( void *pDsp, u32 forceSoftware ); typedef s32 (CALLBACK* _GSopen2)( void *pDsp, u32 flags );
typedef void (CALLBACK* _GSvsync)(int field); typedef void (CALLBACK* _GSvsync)(int field);
typedef void (CALLBACK* _GSgifTransfer1)(u32 *pMem, u32 addr); typedef void (CALLBACK* _GSgifTransfer1)(u32 *pMem, u32 addr);
typedef void (CALLBACK* _GSgifTransfer2)(u32 *pMem, u32 size); typedef void (CALLBACK* _GSgifTransfer2)(u32 *pMem, u32 size);

View File

@ -604,7 +604,7 @@ sptr mtgsThreadObject::ExecuteTask()
Console::WriteLn( "\t\tForced software switch enabled." ); Console::WriteLn( "\t\tForced software switch enabled." );
if( GSopen2 != NULL ) if( GSopen2 != NULL )
m_returncode = GSopen2( (void*)&pDsp, !!renderswitch ); m_returncode = GSopen2( (void*)&pDsp, 1 | (renderswitch ? 4 : 0) );
else else
m_returncode = GSopen( (void*)&pDsp, "PCSX2", renderswitch ? 2 : 1 ); m_returncode = GSopen( (void*)&pDsp, "PCSX2", renderswitch ? 2 : 1 );

View File

@ -31,6 +31,9 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "SPU2-X", "plugins\spu2-x\sr
EndProjectSection EndProjectSection
EndProject EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "GSdx", "plugins\GSdx\GSdx_vs2008.vcproj", "{18E42F6F-3A62-41EE-B42F-79366C4F1E95}" Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "GSdx", "plugins\GSdx\GSdx_vs2008.vcproj", "{18E42F6F-3A62-41EE-B42F-79366C4F1E95}"
ProjectSection(ProjectDependencies) = postProject
{067D7863-393B-494F-B296-4A8853EB3D1D} = {067D7863-393B-494F-B296-4A8853EB3D1D}
EndProjectSection
EndProject EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "SoundTouch", "3rdparty\SoundTouch\SoundTouch.vcproj", "{E9B51944-7E6D-4BCD-83F2-7BBD5A46182D}" Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "SoundTouch", "3rdparty\SoundTouch\SoundTouch.vcproj", "{E9B51944-7E6D-4BCD-83F2-7BBD5A46182D}"
EndProject EndProject
@ -124,6 +127,8 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Tools", "Tools", "{2D6F0A62
EndProject EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "libjpeg", "3rdparty\libjpeg\libjpeg.vcproj", "{BC236261-77E8-4567-8D09-45CD02965EB6}" Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "libjpeg", "3rdparty\libjpeg\libjpeg.vcproj", "{BC236261-77E8-4567-8D09-45CD02965EB6}"
EndProject EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "glew_static", "3rdparty\glew\glew_static_vs2008.vcproj", "{067D7863-393B-494F-B296-4A8853EB3D1D}"
EndProject
Global Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Win32 = Debug|Win32 Debug|Win32 = Debug|Win32
@ -136,8 +141,6 @@ Global
Release SSE4|x64 = Release SSE4|x64 Release SSE4|x64 = Release SSE4|x64
Release SSSE3|Win32 = Release SSSE3|Win32 Release SSSE3|Win32 = Release SSSE3|Win32
Release SSSE3|x64 = Release SSSE3|x64 Release SSSE3|x64 = Release SSSE3|x64
Release|Win32 = Release|Win32
Release|x64 = Release|x64
EndGlobalSection EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution GlobalSection(ProjectConfigurationPlatforms) = postSolution
{1CEFD830-2B76-4596-A4EE-BCD7280A60BD}.Debug|Win32.ActiveCfg = Debug|Win32 {1CEFD830-2B76-4596-A4EE-BCD7280A60BD}.Debug|Win32.ActiveCfg = Debug|Win32
@ -155,9 +158,6 @@ Global
{1CEFD830-2B76-4596-A4EE-BCD7280A60BD}.Release SSSE3|Win32.ActiveCfg = Release|Win32 {1CEFD830-2B76-4596-A4EE-BCD7280A60BD}.Release SSSE3|Win32.ActiveCfg = Release|Win32
{1CEFD830-2B76-4596-A4EE-BCD7280A60BD}.Release SSSE3|Win32.Build.0 = Release|Win32 {1CEFD830-2B76-4596-A4EE-BCD7280A60BD}.Release SSSE3|Win32.Build.0 = Release|Win32
{1CEFD830-2B76-4596-A4EE-BCD7280A60BD}.Release SSSE3|x64.ActiveCfg = Release|Win32 {1CEFD830-2B76-4596-A4EE-BCD7280A60BD}.Release SSSE3|x64.ActiveCfg = Release|Win32
{1CEFD830-2B76-4596-A4EE-BCD7280A60BD}.Release|Win32.ActiveCfg = Release|Win32
{1CEFD830-2B76-4596-A4EE-BCD7280A60BD}.Release|Win32.Build.0 = Release|Win32
{1CEFD830-2B76-4596-A4EE-BCD7280A60BD}.Release|x64.ActiveCfg = Release|Win32
{5C6B7D28-E73D-4F71-8FC0-17ADA640EBD8}.Debug|Win32.ActiveCfg = Debug|Win32 {5C6B7D28-E73D-4F71-8FC0-17ADA640EBD8}.Debug|Win32.ActiveCfg = Debug|Win32
{5C6B7D28-E73D-4F71-8FC0-17ADA640EBD8}.Debug|Win32.Build.0 = Debug|Win32 {5C6B7D28-E73D-4F71-8FC0-17ADA640EBD8}.Debug|Win32.Build.0 = Debug|Win32
{5C6B7D28-E73D-4F71-8FC0-17ADA640EBD8}.Debug|x64.ActiveCfg = Debug|Win32 {5C6B7D28-E73D-4F71-8FC0-17ADA640EBD8}.Debug|x64.ActiveCfg = Debug|Win32
@ -173,9 +173,6 @@ Global
{5C6B7D28-E73D-4F71-8FC0-17ADA640EBD8}.Release SSSE3|Win32.ActiveCfg = Release|Win32 {5C6B7D28-E73D-4F71-8FC0-17ADA640EBD8}.Release SSSE3|Win32.ActiveCfg = Release|Win32
{5C6B7D28-E73D-4F71-8FC0-17ADA640EBD8}.Release SSSE3|Win32.Build.0 = Release|Win32 {5C6B7D28-E73D-4F71-8FC0-17ADA640EBD8}.Release SSSE3|Win32.Build.0 = Release|Win32
{5C6B7D28-E73D-4F71-8FC0-17ADA640EBD8}.Release SSSE3|x64.ActiveCfg = Release|Win32 {5C6B7D28-E73D-4F71-8FC0-17ADA640EBD8}.Release SSSE3|x64.ActiveCfg = Release|Win32
{5C6B7D28-E73D-4F71-8FC0-17ADA640EBD8}.Release|Win32.ActiveCfg = Release|Win32
{5C6B7D28-E73D-4F71-8FC0-17ADA640EBD8}.Release|Win32.Build.0 = Release|Win32
{5C6B7D28-E73D-4F71-8FC0-17ADA640EBD8}.Release|x64.ActiveCfg = Release|Win32
{5F78E90B-BD22-47B1-9CA5-7A80F4DF5EF3}.Debug|Win32.ActiveCfg = Debug|Win32 {5F78E90B-BD22-47B1-9CA5-7A80F4DF5EF3}.Debug|Win32.ActiveCfg = Debug|Win32
{5F78E90B-BD22-47B1-9CA5-7A80F4DF5EF3}.Debug|Win32.Build.0 = Debug|Win32 {5F78E90B-BD22-47B1-9CA5-7A80F4DF5EF3}.Debug|Win32.Build.0 = Debug|Win32
{5F78E90B-BD22-47B1-9CA5-7A80F4DF5EF3}.Debug|x64.ActiveCfg = Debug|Win32 {5F78E90B-BD22-47B1-9CA5-7A80F4DF5EF3}.Debug|x64.ActiveCfg = Debug|Win32
@ -191,9 +188,6 @@ Global
{5F78E90B-BD22-47B1-9CA5-7A80F4DF5EF3}.Release SSSE3|Win32.ActiveCfg = Release|Win32 {5F78E90B-BD22-47B1-9CA5-7A80F4DF5EF3}.Release SSSE3|Win32.ActiveCfg = Release|Win32
{5F78E90B-BD22-47B1-9CA5-7A80F4DF5EF3}.Release SSSE3|Win32.Build.0 = Release|Win32 {5F78E90B-BD22-47B1-9CA5-7A80F4DF5EF3}.Release SSSE3|Win32.Build.0 = Release|Win32
{5F78E90B-BD22-47B1-9CA5-7A80F4DF5EF3}.Release SSSE3|x64.ActiveCfg = Release|Win32 {5F78E90B-BD22-47B1-9CA5-7A80F4DF5EF3}.Release SSSE3|x64.ActiveCfg = Release|Win32
{5F78E90B-BD22-47B1-9CA5-7A80F4DF5EF3}.Release|Win32.ActiveCfg = Release|Win32
{5F78E90B-BD22-47B1-9CA5-7A80F4DF5EF3}.Release|Win32.Build.0 = Release|Win32
{5F78E90B-BD22-47B1-9CA5-7A80F4DF5EF3}.Release|x64.ActiveCfg = Release|Win32
{5307BBB7-EBB9-4AA4-8CB6-A94EC473C8C4}.Debug|Win32.ActiveCfg = Debug|Win32 {5307BBB7-EBB9-4AA4-8CB6-A94EC473C8C4}.Debug|Win32.ActiveCfg = Debug|Win32
{5307BBB7-EBB9-4AA4-8CB6-A94EC473C8C4}.Debug|Win32.Build.0 = Debug|Win32 {5307BBB7-EBB9-4AA4-8CB6-A94EC473C8C4}.Debug|Win32.Build.0 = Debug|Win32
{5307BBB7-EBB9-4AA4-8CB6-A94EC473C8C4}.Debug|x64.ActiveCfg = Debug|Win32 {5307BBB7-EBB9-4AA4-8CB6-A94EC473C8C4}.Debug|x64.ActiveCfg = Debug|Win32
@ -209,9 +203,6 @@ Global
{5307BBB7-EBB9-4AA4-8CB6-A94EC473C8C4}.Release SSSE3|Win32.ActiveCfg = Release|Win32 {5307BBB7-EBB9-4AA4-8CB6-A94EC473C8C4}.Release SSSE3|Win32.ActiveCfg = Release|Win32
{5307BBB7-EBB9-4AA4-8CB6-A94EC473C8C4}.Release SSSE3|Win32.Build.0 = Release|Win32 {5307BBB7-EBB9-4AA4-8CB6-A94EC473C8C4}.Release SSSE3|Win32.Build.0 = Release|Win32
{5307BBB7-EBB9-4AA4-8CB6-A94EC473C8C4}.Release SSSE3|x64.ActiveCfg = Release|Win32 {5307BBB7-EBB9-4AA4-8CB6-A94EC473C8C4}.Release SSSE3|x64.ActiveCfg = Release|Win32
{5307BBB7-EBB9-4AA4-8CB6-A94EC473C8C4}.Release|Win32.ActiveCfg = Release|Win32
{5307BBB7-EBB9-4AA4-8CB6-A94EC473C8C4}.Release|Win32.Build.0 = Release|Win32
{5307BBB7-EBB9-4AA4-8CB6-A94EC473C8C4}.Release|x64.ActiveCfg = Release|Win32
{18E42F6F-3A62-41EE-B42F-79366C4F1E95}.Debug|Win32.ActiveCfg = Debug SSE4|Win32 {18E42F6F-3A62-41EE-B42F-79366C4F1E95}.Debug|Win32.ActiveCfg = Debug SSE4|Win32
{18E42F6F-3A62-41EE-B42F-79366C4F1E95}.Debug|Win32.Build.0 = Debug SSE4|Win32 {18E42F6F-3A62-41EE-B42F-79366C4F1E95}.Debug|Win32.Build.0 = Debug SSE4|Win32
{18E42F6F-3A62-41EE-B42F-79366C4F1E95}.Debug|x64.ActiveCfg = Debug|Win32 {18E42F6F-3A62-41EE-B42F-79366C4F1E95}.Debug|x64.ActiveCfg = Debug|Win32
@ -227,9 +218,6 @@ Global
{18E42F6F-3A62-41EE-B42F-79366C4F1E95}.Release SSSE3|Win32.ActiveCfg = Release SSSE3|Win32 {18E42F6F-3A62-41EE-B42F-79366C4F1E95}.Release SSSE3|Win32.ActiveCfg = Release SSSE3|Win32
{18E42F6F-3A62-41EE-B42F-79366C4F1E95}.Release SSSE3|Win32.Build.0 = Release SSSE3|Win32 {18E42F6F-3A62-41EE-B42F-79366C4F1E95}.Release SSSE3|Win32.Build.0 = Release SSSE3|Win32
{18E42F6F-3A62-41EE-B42F-79366C4F1E95}.Release SSSE3|x64.ActiveCfg = Release SSSE3|Win32 {18E42F6F-3A62-41EE-B42F-79366C4F1E95}.Release SSSE3|x64.ActiveCfg = Release SSSE3|Win32
{18E42F6F-3A62-41EE-B42F-79366C4F1E95}.Release|Win32.ActiveCfg = Release|Win32
{18E42F6F-3A62-41EE-B42F-79366C4F1E95}.Release|Win32.Build.0 = Release|Win32
{18E42F6F-3A62-41EE-B42F-79366C4F1E95}.Release|x64.ActiveCfg = Release|Win32
{E9B51944-7E6D-4BCD-83F2-7BBD5A46182D}.Debug|Win32.ActiveCfg = Debug|Win32 {E9B51944-7E6D-4BCD-83F2-7BBD5A46182D}.Debug|Win32.ActiveCfg = Debug|Win32
{E9B51944-7E6D-4BCD-83F2-7BBD5A46182D}.Debug|Win32.Build.0 = Debug|Win32 {E9B51944-7E6D-4BCD-83F2-7BBD5A46182D}.Debug|Win32.Build.0 = Debug|Win32
{E9B51944-7E6D-4BCD-83F2-7BBD5A46182D}.Debug|x64.ActiveCfg = Debug|Win32 {E9B51944-7E6D-4BCD-83F2-7BBD5A46182D}.Debug|x64.ActiveCfg = Debug|Win32
@ -245,9 +233,6 @@ Global
{E9B51944-7E6D-4BCD-83F2-7BBD5A46182D}.Release SSSE3|Win32.ActiveCfg = Release|Win32 {E9B51944-7E6D-4BCD-83F2-7BBD5A46182D}.Release SSSE3|Win32.ActiveCfg = Release|Win32
{E9B51944-7E6D-4BCD-83F2-7BBD5A46182D}.Release SSSE3|Win32.Build.0 = Release|Win32 {E9B51944-7E6D-4BCD-83F2-7BBD5A46182D}.Release SSSE3|Win32.Build.0 = Release|Win32
{E9B51944-7E6D-4BCD-83F2-7BBD5A46182D}.Release SSSE3|x64.ActiveCfg = Release|Win32 {E9B51944-7E6D-4BCD-83F2-7BBD5A46182D}.Release SSSE3|x64.ActiveCfg = Release|Win32
{E9B51944-7E6D-4BCD-83F2-7BBD5A46182D}.Release|Win32.ActiveCfg = Release|Win32
{E9B51944-7E6D-4BCD-83F2-7BBD5A46182D}.Release|Win32.Build.0 = Release|Win32
{E9B51944-7E6D-4BCD-83F2-7BBD5A46182D}.Release|x64.ActiveCfg = Release|Win32
{2F6C0388-20CB-4242-9F6C-A6EBB6A83F47}.Debug|Win32.ActiveCfg = Debug|Win32 {2F6C0388-20CB-4242-9F6C-A6EBB6A83F47}.Debug|Win32.ActiveCfg = Debug|Win32
{2F6C0388-20CB-4242-9F6C-A6EBB6A83F47}.Debug|Win32.Build.0 = Debug|Win32 {2F6C0388-20CB-4242-9F6C-A6EBB6A83F47}.Debug|Win32.Build.0 = Debug|Win32
{2F6C0388-20CB-4242-9F6C-A6EBB6A83F47}.Debug|x64.ActiveCfg = Debug|Win32 {2F6C0388-20CB-4242-9F6C-A6EBB6A83F47}.Debug|x64.ActiveCfg = Debug|Win32
@ -263,9 +248,6 @@ Global
{2F6C0388-20CB-4242-9F6C-A6EBB6A83F47}.Release SSSE3|Win32.ActiveCfg = Release|Win32 {2F6C0388-20CB-4242-9F6C-A6EBB6A83F47}.Release SSSE3|Win32.ActiveCfg = Release|Win32
{2F6C0388-20CB-4242-9F6C-A6EBB6A83F47}.Release SSSE3|Win32.Build.0 = Release|Win32 {2F6C0388-20CB-4242-9F6C-A6EBB6A83F47}.Release SSSE3|Win32.Build.0 = Release|Win32
{2F6C0388-20CB-4242-9F6C-A6EBB6A83F47}.Release SSSE3|x64.ActiveCfg = Release|Win32 {2F6C0388-20CB-4242-9F6C-A6EBB6A83F47}.Release SSSE3|x64.ActiveCfg = Release|Win32
{2F6C0388-20CB-4242-9F6C-A6EBB6A83F47}.Release|Win32.ActiveCfg = Release|Win32
{2F6C0388-20CB-4242-9F6C-A6EBB6A83F47}.Release|Win32.Build.0 = Release|Win32
{2F6C0388-20CB-4242-9F6C-A6EBB6A83F47}.Release|x64.ActiveCfg = Release|Win32
{F4EB4AB2-C595-4B05-8BC0-059024BC796C}.Debug|Win32.ActiveCfg = Debug|Win32 {F4EB4AB2-C595-4B05-8BC0-059024BC796C}.Debug|Win32.ActiveCfg = Debug|Win32
{F4EB4AB2-C595-4B05-8BC0-059024BC796C}.Debug|Win32.Build.0 = Debug|Win32 {F4EB4AB2-C595-4B05-8BC0-059024BC796C}.Debug|Win32.Build.0 = Debug|Win32
{F4EB4AB2-C595-4B05-8BC0-059024BC796C}.Debug|x64.ActiveCfg = Debug|Win32 {F4EB4AB2-C595-4B05-8BC0-059024BC796C}.Debug|x64.ActiveCfg = Debug|Win32
@ -281,9 +263,6 @@ Global
{F4EB4AB2-C595-4B05-8BC0-059024BC796C}.Release SSSE3|Win32.ActiveCfg = Release|Win32 {F4EB4AB2-C595-4B05-8BC0-059024BC796C}.Release SSSE3|Win32.ActiveCfg = Release|Win32
{F4EB4AB2-C595-4B05-8BC0-059024BC796C}.Release SSSE3|Win32.Build.0 = Release|Win32 {F4EB4AB2-C595-4B05-8BC0-059024BC796C}.Release SSSE3|Win32.Build.0 = Release|Win32
{F4EB4AB2-C595-4B05-8BC0-059024BC796C}.Release SSSE3|x64.ActiveCfg = Release|Win32 {F4EB4AB2-C595-4B05-8BC0-059024BC796C}.Release SSSE3|x64.ActiveCfg = Release|Win32
{F4EB4AB2-C595-4B05-8BC0-059024BC796C}.Release|Win32.ActiveCfg = Release|Win32
{F4EB4AB2-C595-4B05-8BC0-059024BC796C}.Release|Win32.Build.0 = Release|Win32
{F4EB4AB2-C595-4B05-8BC0-059024BC796C}.Release|x64.ActiveCfg = Release|Win32
{E4081455-398C-4610-A87C-90A8A7D72DC3}.Debug|Win32.ActiveCfg = Debug|Win32 {E4081455-398C-4610-A87C-90A8A7D72DC3}.Debug|Win32.ActiveCfg = Debug|Win32
{E4081455-398C-4610-A87C-90A8A7D72DC3}.Debug|Win32.Build.0 = Debug|Win32 {E4081455-398C-4610-A87C-90A8A7D72DC3}.Debug|Win32.Build.0 = Debug|Win32
{E4081455-398C-4610-A87C-90A8A7D72DC3}.Debug|x64.ActiveCfg = Debug|Win32 {E4081455-398C-4610-A87C-90A8A7D72DC3}.Debug|x64.ActiveCfg = Debug|Win32
@ -299,9 +278,6 @@ Global
{E4081455-398C-4610-A87C-90A8A7D72DC3}.Release SSSE3|Win32.ActiveCfg = Release|Win32 {E4081455-398C-4610-A87C-90A8A7D72DC3}.Release SSSE3|Win32.ActiveCfg = Release|Win32
{E4081455-398C-4610-A87C-90A8A7D72DC3}.Release SSSE3|Win32.Build.0 = Release|Win32 {E4081455-398C-4610-A87C-90A8A7D72DC3}.Release SSSE3|Win32.Build.0 = Release|Win32
{E4081455-398C-4610-A87C-90A8A7D72DC3}.Release SSSE3|x64.ActiveCfg = Release|Win32 {E4081455-398C-4610-A87C-90A8A7D72DC3}.Release SSSE3|x64.ActiveCfg = Release|Win32
{E4081455-398C-4610-A87C-90A8A7D72DC3}.Release|Win32.ActiveCfg = Release|Win32
{E4081455-398C-4610-A87C-90A8A7D72DC3}.Release|Win32.Build.0 = Release|Win32
{E4081455-398C-4610-A87C-90A8A7D72DC3}.Release|x64.ActiveCfg = Release|Win32
{26511268-2902-4997-8421-ECD7055F9E28}.Debug|Win32.ActiveCfg = Debug|Win32 {26511268-2902-4997-8421-ECD7055F9E28}.Debug|Win32.ActiveCfg = Debug|Win32
{26511268-2902-4997-8421-ECD7055F9E28}.Debug|Win32.Build.0 = Debug|Win32 {26511268-2902-4997-8421-ECD7055F9E28}.Debug|Win32.Build.0 = Debug|Win32
{26511268-2902-4997-8421-ECD7055F9E28}.Debug|x64.ActiveCfg = Debug|Win32 {26511268-2902-4997-8421-ECD7055F9E28}.Debug|x64.ActiveCfg = Debug|Win32
@ -317,9 +293,6 @@ Global
{26511268-2902-4997-8421-ECD7055F9E28}.Release SSSE3|Win32.ActiveCfg = Release|Win32 {26511268-2902-4997-8421-ECD7055F9E28}.Release SSSE3|Win32.ActiveCfg = Release|Win32
{26511268-2902-4997-8421-ECD7055F9E28}.Release SSSE3|Win32.Build.0 = Release|Win32 {26511268-2902-4997-8421-ECD7055F9E28}.Release SSSE3|Win32.Build.0 = Release|Win32
{26511268-2902-4997-8421-ECD7055F9E28}.Release SSSE3|x64.ActiveCfg = Release|Win32 {26511268-2902-4997-8421-ECD7055F9E28}.Release SSSE3|x64.ActiveCfg = Release|Win32
{26511268-2902-4997-8421-ECD7055F9E28}.Release|Win32.ActiveCfg = Release|Win32
{26511268-2902-4997-8421-ECD7055F9E28}.Release|Win32.Build.0 = Release|Win32
{26511268-2902-4997-8421-ECD7055F9E28}.Release|x64.ActiveCfg = Release|Win32
{7F059854-568D-4E08-9D00-1E78E203E4DC}.Debug|Win32.ActiveCfg = Debug|Win32 {7F059854-568D-4E08-9D00-1E78E203E4DC}.Debug|Win32.ActiveCfg = Debug|Win32
{7F059854-568D-4E08-9D00-1E78E203E4DC}.Debug|Win32.Build.0 = Debug|Win32 {7F059854-568D-4E08-9D00-1E78E203E4DC}.Debug|Win32.Build.0 = Debug|Win32
{7F059854-568D-4E08-9D00-1E78E203E4DC}.Debug|x64.ActiveCfg = Debug|Win32 {7F059854-568D-4E08-9D00-1E78E203E4DC}.Debug|x64.ActiveCfg = Debug|Win32
@ -335,9 +308,6 @@ Global
{7F059854-568D-4E08-9D00-1E78E203E4DC}.Release SSSE3|Win32.ActiveCfg = Release|Win32 {7F059854-568D-4E08-9D00-1E78E203E4DC}.Release SSSE3|Win32.ActiveCfg = Release|Win32
{7F059854-568D-4E08-9D00-1E78E203E4DC}.Release SSSE3|Win32.Build.0 = Release|Win32 {7F059854-568D-4E08-9D00-1E78E203E4DC}.Release SSSE3|Win32.Build.0 = Release|Win32
{7F059854-568D-4E08-9D00-1E78E203E4DC}.Release SSSE3|x64.ActiveCfg = Release|Win32 {7F059854-568D-4E08-9D00-1E78E203E4DC}.Release SSSE3|x64.ActiveCfg = Release|Win32
{7F059854-568D-4E08-9D00-1E78E203E4DC}.Release|Win32.ActiveCfg = Release|Win32
{7F059854-568D-4E08-9D00-1E78E203E4DC}.Release|Win32.Build.0 = Release|Win32
{7F059854-568D-4E08-9D00-1E78E203E4DC}.Release|x64.ActiveCfg = Release|Win32
{6F3C4136-5801-4EBC-AC6E-37DF6FAB150A}.Debug|Win32.ActiveCfg = Debug|Win32 {6F3C4136-5801-4EBC-AC6E-37DF6FAB150A}.Debug|Win32.ActiveCfg = Debug|Win32
{6F3C4136-5801-4EBC-AC6E-37DF6FAB150A}.Debug|Win32.Build.0 = Debug|Win32 {6F3C4136-5801-4EBC-AC6E-37DF6FAB150A}.Debug|Win32.Build.0 = Debug|Win32
{6F3C4136-5801-4EBC-AC6E-37DF6FAB150A}.Debug|x64.ActiveCfg = Debug|Win32 {6F3C4136-5801-4EBC-AC6E-37DF6FAB150A}.Debug|x64.ActiveCfg = Debug|Win32
@ -353,9 +323,6 @@ Global
{6F3C4136-5801-4EBC-AC6E-37DF6FAB150A}.Release SSSE3|Win32.ActiveCfg = Release|Win32 {6F3C4136-5801-4EBC-AC6E-37DF6FAB150A}.Release SSSE3|Win32.ActiveCfg = Release|Win32
{6F3C4136-5801-4EBC-AC6E-37DF6FAB150A}.Release SSSE3|Win32.Build.0 = Release|Win32 {6F3C4136-5801-4EBC-AC6E-37DF6FAB150A}.Release SSSE3|Win32.Build.0 = Release|Win32
{6F3C4136-5801-4EBC-AC6E-37DF6FAB150A}.Release SSSE3|x64.ActiveCfg = Release SSSE3|Win32 {6F3C4136-5801-4EBC-AC6E-37DF6FAB150A}.Release SSSE3|x64.ActiveCfg = Release SSSE3|Win32
{6F3C4136-5801-4EBC-AC6E-37DF6FAB150A}.Release|Win32.ActiveCfg = Release|Win32
{6F3C4136-5801-4EBC-AC6E-37DF6FAB150A}.Release|Win32.Build.0 = Release|Win32
{6F3C4136-5801-4EBC-AC6E-37DF6FAB150A}.Release|x64.ActiveCfg = Release|Win32
{FCDF5AE2-EA47-4CC6-9F20-23A0517FEBCB}.Debug|Win32.ActiveCfg = Debug|Win32 {FCDF5AE2-EA47-4CC6-9F20-23A0517FEBCB}.Debug|Win32.ActiveCfg = Debug|Win32
{FCDF5AE2-EA47-4CC6-9F20-23A0517FEBCB}.Debug|Win32.Build.0 = Debug|Win32 {FCDF5AE2-EA47-4CC6-9F20-23A0517FEBCB}.Debug|Win32.Build.0 = Debug|Win32
{FCDF5AE2-EA47-4CC6-9F20-23A0517FEBCB}.Debug|x64.ActiveCfg = Debug|Win32 {FCDF5AE2-EA47-4CC6-9F20-23A0517FEBCB}.Debug|x64.ActiveCfg = Debug|Win32
@ -371,9 +338,6 @@ Global
{FCDF5AE2-EA47-4CC6-9F20-23A0517FEBCB}.Release SSSE3|Win32.ActiveCfg = Release|Win32 {FCDF5AE2-EA47-4CC6-9F20-23A0517FEBCB}.Release SSSE3|Win32.ActiveCfg = Release|Win32
{FCDF5AE2-EA47-4CC6-9F20-23A0517FEBCB}.Release SSSE3|Win32.Build.0 = Release|Win32 {FCDF5AE2-EA47-4CC6-9F20-23A0517FEBCB}.Release SSSE3|Win32.Build.0 = Release|Win32
{FCDF5AE2-EA47-4CC6-9F20-23A0517FEBCB}.Release SSSE3|x64.ActiveCfg = Release SSSE3|Win32 {FCDF5AE2-EA47-4CC6-9F20-23A0517FEBCB}.Release SSSE3|x64.ActiveCfg = Release SSSE3|Win32
{FCDF5AE2-EA47-4CC6-9F20-23A0517FEBCB}.Release|Win32.ActiveCfg = Release|Win32
{FCDF5AE2-EA47-4CC6-9F20-23A0517FEBCB}.Release|Win32.Build.0 = Release|Win32
{FCDF5AE2-EA47-4CC6-9F20-23A0517FEBCB}.Release|x64.ActiveCfg = Release|Win32
{F38D9DF0-F68D-49D9-B3A0-932E74FB74A0}.Debug|Win32.ActiveCfg = Release|Win32 {F38D9DF0-F68D-49D9-B3A0-932E74FB74A0}.Debug|Win32.ActiveCfg = Release|Win32
{F38D9DF0-F68D-49D9-B3A0-932E74FB74A0}.Debug|Win32.Build.0 = Release|Win32 {F38D9DF0-F68D-49D9-B3A0-932E74FB74A0}.Debug|Win32.Build.0 = Release|Win32
{F38D9DF0-F68D-49D9-B3A0-932E74FB74A0}.Debug|x64.ActiveCfg = Release|Win32 {F38D9DF0-F68D-49D9-B3A0-932E74FB74A0}.Debug|x64.ActiveCfg = Release|Win32
@ -389,9 +353,6 @@ Global
{F38D9DF0-F68D-49D9-B3A0-932E74FB74A0}.Release SSSE3|Win32.ActiveCfg = Release|Win32 {F38D9DF0-F68D-49D9-B3A0-932E74FB74A0}.Release SSSE3|Win32.ActiveCfg = Release|Win32
{F38D9DF0-F68D-49D9-B3A0-932E74FB74A0}.Release SSSE3|Win32.Build.0 = Release|Win32 {F38D9DF0-F68D-49D9-B3A0-932E74FB74A0}.Release SSSE3|Win32.Build.0 = Release|Win32
{F38D9DF0-F68D-49D9-B3A0-932E74FB74A0}.Release SSSE3|x64.ActiveCfg = Release|Win32 {F38D9DF0-F68D-49D9-B3A0-932E74FB74A0}.Release SSSE3|x64.ActiveCfg = Release|Win32
{F38D9DF0-F68D-49D9-B3A0-932E74FB74A0}.Release|Win32.ActiveCfg = Release|Win32
{F38D9DF0-F68D-49D9-B3A0-932E74FB74A0}.Release|Win32.Build.0 = Release|Win32
{F38D9DF0-F68D-49D9-B3A0-932E74FB74A0}.Release|x64.ActiveCfg = Release|Win32
{BF7B81A5-E348-4F7C-A69F-F74C8EEEAD70}.Debug|Win32.ActiveCfg = Debug|Win32 {BF7B81A5-E348-4F7C-A69F-F74C8EEEAD70}.Debug|Win32.ActiveCfg = Debug|Win32
{BF7B81A5-E348-4F7C-A69F-F74C8EEEAD70}.Debug|Win32.Build.0 = Debug|Win32 {BF7B81A5-E348-4F7C-A69F-F74C8EEEAD70}.Debug|Win32.Build.0 = Debug|Win32
{BF7B81A5-E348-4F7C-A69F-F74C8EEEAD70}.Debug|x64.ActiveCfg = Debug|Win32 {BF7B81A5-E348-4F7C-A69F-F74C8EEEAD70}.Debug|x64.ActiveCfg = Debug|Win32
@ -407,9 +368,6 @@ Global
{BF7B81A5-E348-4F7C-A69F-F74C8EEEAD70}.Release SSSE3|Win32.ActiveCfg = Release|Win32 {BF7B81A5-E348-4F7C-A69F-F74C8EEEAD70}.Release SSSE3|Win32.ActiveCfg = Release|Win32
{BF7B81A5-E348-4F7C-A69F-F74C8EEEAD70}.Release SSSE3|Win32.Build.0 = Release|Win32 {BF7B81A5-E348-4F7C-A69F-F74C8EEEAD70}.Release SSSE3|Win32.Build.0 = Release|Win32
{BF7B81A5-E348-4F7C-A69F-F74C8EEEAD70}.Release SSSE3|x64.ActiveCfg = Release|Win32 {BF7B81A5-E348-4F7C-A69F-F74C8EEEAD70}.Release SSSE3|x64.ActiveCfg = Release|Win32
{BF7B81A5-E348-4F7C-A69F-F74C8EEEAD70}.Release|Win32.ActiveCfg = Release|Win32
{BF7B81A5-E348-4F7C-A69F-F74C8EEEAD70}.Release|Win32.Build.0 = Release|Win32
{BF7B81A5-E348-4F7C-A69F-F74C8EEEAD70}.Release|x64.ActiveCfg = Release|Win32
{3D0EB14D-32F3-4D82-9C6D-B806ADBB859C}.Debug|Win32.ActiveCfg = Debug|Win32 {3D0EB14D-32F3-4D82-9C6D-B806ADBB859C}.Debug|Win32.ActiveCfg = Debug|Win32
{3D0EB14D-32F3-4D82-9C6D-B806ADBB859C}.Debug|Win32.Build.0 = Debug|Win32 {3D0EB14D-32F3-4D82-9C6D-B806ADBB859C}.Debug|Win32.Build.0 = Debug|Win32
{3D0EB14D-32F3-4D82-9C6D-B806ADBB859C}.Debug|x64.ActiveCfg = Debug|Win32 {3D0EB14D-32F3-4D82-9C6D-B806ADBB859C}.Debug|x64.ActiveCfg = Debug|Win32
@ -425,9 +383,6 @@ Global
{3D0EB14D-32F3-4D82-9C6D-B806ADBB859C}.Release SSSE3|Win32.ActiveCfg = Release|Win32 {3D0EB14D-32F3-4D82-9C6D-B806ADBB859C}.Release SSSE3|Win32.ActiveCfg = Release|Win32
{3D0EB14D-32F3-4D82-9C6D-B806ADBB859C}.Release SSSE3|Win32.Build.0 = Release|Win32 {3D0EB14D-32F3-4D82-9C6D-B806ADBB859C}.Release SSSE3|Win32.Build.0 = Release|Win32
{3D0EB14D-32F3-4D82-9C6D-B806ADBB859C}.Release SSSE3|x64.ActiveCfg = Release|Win32 {3D0EB14D-32F3-4D82-9C6D-B806ADBB859C}.Release SSSE3|x64.ActiveCfg = Release|Win32
{3D0EB14D-32F3-4D82-9C6D-B806ADBB859C}.Release|Win32.ActiveCfg = Release|Win32
{3D0EB14D-32F3-4D82-9C6D-B806ADBB859C}.Release|Win32.Build.0 = Release|Win32
{3D0EB14D-32F3-4D82-9C6D-B806ADBB859C}.Release|x64.ActiveCfg = Release|Win32
{04439C5F-05FB-4A9C-AAD1-5388C25377DB}.Debug|Win32.ActiveCfg = Debug|Win32 {04439C5F-05FB-4A9C-AAD1-5388C25377DB}.Debug|Win32.ActiveCfg = Debug|Win32
{04439C5F-05FB-4A9C-AAD1-5388C25377DB}.Debug|Win32.Build.0 = Debug|Win32 {04439C5F-05FB-4A9C-AAD1-5388C25377DB}.Debug|Win32.Build.0 = Debug|Win32
{04439C5F-05FB-4A9C-AAD1-5388C25377DB}.Debug|x64.ActiveCfg = Debug|Win32 {04439C5F-05FB-4A9C-AAD1-5388C25377DB}.Debug|x64.ActiveCfg = Debug|Win32
@ -443,9 +398,6 @@ Global
{04439C5F-05FB-4A9C-AAD1-5388C25377DB}.Release SSSE3|Win32.ActiveCfg = Release|Win32 {04439C5F-05FB-4A9C-AAD1-5388C25377DB}.Release SSSE3|Win32.ActiveCfg = Release|Win32
{04439C5F-05FB-4A9C-AAD1-5388C25377DB}.Release SSSE3|Win32.Build.0 = Release|Win32 {04439C5F-05FB-4A9C-AAD1-5388C25377DB}.Release SSSE3|Win32.Build.0 = Release|Win32
{04439C5F-05FB-4A9C-AAD1-5388C25377DB}.Release SSSE3|x64.ActiveCfg = Release|Win32 {04439C5F-05FB-4A9C-AAD1-5388C25377DB}.Release SSSE3|x64.ActiveCfg = Release|Win32
{04439C5F-05FB-4A9C-AAD1-5388C25377DB}.Release|Win32.ActiveCfg = Release|Win32
{04439C5F-05FB-4A9C-AAD1-5388C25377DB}.Release|Win32.Build.0 = Release|Win32
{04439C5F-05FB-4A9C-AAD1-5388C25377DB}.Release|x64.ActiveCfg = Release|Win32
{48AD7E0A-25B1-4974-A1E3-03F8C438D34F}.Debug|Win32.ActiveCfg = Debug|Win32 {48AD7E0A-25B1-4974-A1E3-03F8C438D34F}.Debug|Win32.ActiveCfg = Debug|Win32
{48AD7E0A-25B1-4974-A1E3-03F8C438D34F}.Debug|Win32.Build.0 = Debug|Win32 {48AD7E0A-25B1-4974-A1E3-03F8C438D34F}.Debug|Win32.Build.0 = Debug|Win32
{48AD7E0A-25B1-4974-A1E3-03F8C438D34F}.Debug|x64.ActiveCfg = Debug|Win32 {48AD7E0A-25B1-4974-A1E3-03F8C438D34F}.Debug|x64.ActiveCfg = Debug|Win32
@ -461,9 +413,6 @@ Global
{48AD7E0A-25B1-4974-A1E3-03F8C438D34F}.Release SSSE3|Win32.ActiveCfg = Release|Win32 {48AD7E0A-25B1-4974-A1E3-03F8C438D34F}.Release SSSE3|Win32.ActiveCfg = Release|Win32
{48AD7E0A-25B1-4974-A1E3-03F8C438D34F}.Release SSSE3|Win32.Build.0 = Release|Win32 {48AD7E0A-25B1-4974-A1E3-03F8C438D34F}.Release SSSE3|Win32.Build.0 = Release|Win32
{48AD7E0A-25B1-4974-A1E3-03F8C438D34F}.Release SSSE3|x64.ActiveCfg = Release|Win32 {48AD7E0A-25B1-4974-A1E3-03F8C438D34F}.Release SSSE3|x64.ActiveCfg = Release|Win32
{48AD7E0A-25B1-4974-A1E3-03F8C438D34F}.Release|Win32.ActiveCfg = Release|Win32
{48AD7E0A-25B1-4974-A1E3-03F8C438D34F}.Release|Win32.Build.0 = Release|Win32
{48AD7E0A-25B1-4974-A1E3-03F8C438D34F}.Release|x64.ActiveCfg = Release|Win32
{0318BA30-EF48-441A-9E10-DC85EFAE39F0}.Debug|Win32.ActiveCfg = Debug|Win32 {0318BA30-EF48-441A-9E10-DC85EFAE39F0}.Debug|Win32.ActiveCfg = Debug|Win32
{0318BA30-EF48-441A-9E10-DC85EFAE39F0}.Debug|Win32.Build.0 = Debug|Win32 {0318BA30-EF48-441A-9E10-DC85EFAE39F0}.Debug|Win32.Build.0 = Debug|Win32
{0318BA30-EF48-441A-9E10-DC85EFAE39F0}.Debug|x64.ActiveCfg = Debug|Win32 {0318BA30-EF48-441A-9E10-DC85EFAE39F0}.Debug|x64.ActiveCfg = Debug|Win32
@ -479,9 +428,6 @@ Global
{0318BA30-EF48-441A-9E10-DC85EFAE39F0}.Release SSSE3|Win32.ActiveCfg = Release|Win32 {0318BA30-EF48-441A-9E10-DC85EFAE39F0}.Release SSSE3|Win32.ActiveCfg = Release|Win32
{0318BA30-EF48-441A-9E10-DC85EFAE39F0}.Release SSSE3|Win32.Build.0 = Release|Win32 {0318BA30-EF48-441A-9E10-DC85EFAE39F0}.Release SSSE3|Win32.Build.0 = Release|Win32
{0318BA30-EF48-441A-9E10-DC85EFAE39F0}.Release SSSE3|x64.ActiveCfg = Release|Win32 {0318BA30-EF48-441A-9E10-DC85EFAE39F0}.Release SSSE3|x64.ActiveCfg = Release|Win32
{0318BA30-EF48-441A-9E10-DC85EFAE39F0}.Release|Win32.ActiveCfg = Release|Win32
{0318BA30-EF48-441A-9E10-DC85EFAE39F0}.Release|Win32.Build.0 = Release|Win32
{0318BA30-EF48-441A-9E10-DC85EFAE39F0}.Release|x64.ActiveCfg = Release|Win32
{C34487AF-228A-4D11-8E50-27803DF76873}.Debug|Win32.ActiveCfg = Debug|Win32 {C34487AF-228A-4D11-8E50-27803DF76873}.Debug|Win32.ActiveCfg = Debug|Win32
{C34487AF-228A-4D11-8E50-27803DF76873}.Debug|Win32.Build.0 = Debug|Win32 {C34487AF-228A-4D11-8E50-27803DF76873}.Debug|Win32.Build.0 = Debug|Win32
{C34487AF-228A-4D11-8E50-27803DF76873}.Debug|x64.ActiveCfg = Debug|Win32 {C34487AF-228A-4D11-8E50-27803DF76873}.Debug|x64.ActiveCfg = Debug|Win32
@ -497,9 +443,6 @@ Global
{C34487AF-228A-4D11-8E50-27803DF76873}.Release SSSE3|Win32.ActiveCfg = Release|Win32 {C34487AF-228A-4D11-8E50-27803DF76873}.Release SSSE3|Win32.ActiveCfg = Release|Win32
{C34487AF-228A-4D11-8E50-27803DF76873}.Release SSSE3|Win32.Build.0 = Release|Win32 {C34487AF-228A-4D11-8E50-27803DF76873}.Release SSSE3|Win32.Build.0 = Release|Win32
{C34487AF-228A-4D11-8E50-27803DF76873}.Release SSSE3|x64.ActiveCfg = Release|Win32 {C34487AF-228A-4D11-8E50-27803DF76873}.Release SSSE3|x64.ActiveCfg = Release|Win32
{C34487AF-228A-4D11-8E50-27803DF76873}.Release|Win32.ActiveCfg = Release|Win32
{C34487AF-228A-4D11-8E50-27803DF76873}.Release|Win32.Build.0 = Release|Win32
{C34487AF-228A-4D11-8E50-27803DF76873}.Release|x64.ActiveCfg = Release|Win32
{A51123F5-9505-4EAE-85E7-D320290A272C}.Debug|Win32.ActiveCfg = Debug|Win32 {A51123F5-9505-4EAE-85E7-D320290A272C}.Debug|Win32.ActiveCfg = Debug|Win32
{A51123F5-9505-4EAE-85E7-D320290A272C}.Debug|Win32.Build.0 = Debug|Win32 {A51123F5-9505-4EAE-85E7-D320290A272C}.Debug|Win32.Build.0 = Debug|Win32
{A51123F5-9505-4EAE-85E7-D320290A272C}.Debug|x64.ActiveCfg = Debug|Win32 {A51123F5-9505-4EAE-85E7-D320290A272C}.Debug|x64.ActiveCfg = Debug|Win32
@ -515,9 +458,6 @@ Global
{A51123F5-9505-4EAE-85E7-D320290A272C}.Release SSSE3|Win32.ActiveCfg = Release|Win32 {A51123F5-9505-4EAE-85E7-D320290A272C}.Release SSSE3|Win32.ActiveCfg = Release|Win32
{A51123F5-9505-4EAE-85E7-D320290A272C}.Release SSSE3|Win32.Build.0 = Release|Win32 {A51123F5-9505-4EAE-85E7-D320290A272C}.Release SSSE3|Win32.Build.0 = Release|Win32
{A51123F5-9505-4EAE-85E7-D320290A272C}.Release SSSE3|x64.ActiveCfg = Release|Win32 {A51123F5-9505-4EAE-85E7-D320290A272C}.Release SSSE3|x64.ActiveCfg = Release|Win32
{A51123F5-9505-4EAE-85E7-D320290A272C}.Release|Win32.ActiveCfg = Release|Win32
{A51123F5-9505-4EAE-85E7-D320290A272C}.Release|Win32.Build.0 = Release|Win32
{A51123F5-9505-4EAE-85E7-D320290A272C}.Release|x64.ActiveCfg = Release|Win32
{4639972E-424E-4E13-8B07-CA403C481346}.Debug|Win32.ActiveCfg = Debug|Win32 {4639972E-424E-4E13-8B07-CA403C481346}.Debug|Win32.ActiveCfg = Debug|Win32
{4639972E-424E-4E13-8B07-CA403C481346}.Debug|Win32.Build.0 = Debug|Win32 {4639972E-424E-4E13-8B07-CA403C481346}.Debug|Win32.Build.0 = Debug|Win32
{4639972E-424E-4E13-8B07-CA403C481346}.Debug|x64.ActiveCfg = Debug|Win32 {4639972E-424E-4E13-8B07-CA403C481346}.Debug|x64.ActiveCfg = Debug|Win32
@ -533,9 +473,6 @@ Global
{4639972E-424E-4E13-8B07-CA403C481346}.Release SSSE3|Win32.ActiveCfg = Release|Win32 {4639972E-424E-4E13-8B07-CA403C481346}.Release SSSE3|Win32.ActiveCfg = Release|Win32
{4639972E-424E-4E13-8B07-CA403C481346}.Release SSSE3|Win32.Build.0 = Release|Win32 {4639972E-424E-4E13-8B07-CA403C481346}.Release SSSE3|Win32.Build.0 = Release|Win32
{4639972E-424E-4E13-8B07-CA403C481346}.Release SSSE3|x64.ActiveCfg = Release|Win32 {4639972E-424E-4E13-8B07-CA403C481346}.Release SSSE3|x64.ActiveCfg = Release|Win32
{4639972E-424E-4E13-8B07-CA403C481346}.Release|Win32.ActiveCfg = Release|Win32
{4639972E-424E-4E13-8B07-CA403C481346}.Release|Win32.Build.0 = Release|Win32
{4639972E-424E-4E13-8B07-CA403C481346}.Release|x64.ActiveCfg = Release|Win32
{0E231FB1-F3C9-4724-ACCB-DE8BCB3C089E}.Debug|Win32.ActiveCfg = Debug|Win32 {0E231FB1-F3C9-4724-ACCB-DE8BCB3C089E}.Debug|Win32.ActiveCfg = Debug|Win32
{0E231FB1-F3C9-4724-ACCB-DE8BCB3C089E}.Debug|Win32.Build.0 = Debug|Win32 {0E231FB1-F3C9-4724-ACCB-DE8BCB3C089E}.Debug|Win32.Build.0 = Debug|Win32
{0E231FB1-F3C9-4724-ACCB-DE8BCB3C089E}.Debug|x64.ActiveCfg = Debug|Win32 {0E231FB1-F3C9-4724-ACCB-DE8BCB3C089E}.Debug|x64.ActiveCfg = Debug|Win32
@ -551,9 +488,6 @@ Global
{0E231FB1-F3C9-4724-ACCB-DE8BCB3C089E}.Release SSSE3|Win32.ActiveCfg = Release|Win32 {0E231FB1-F3C9-4724-ACCB-DE8BCB3C089E}.Release SSSE3|Win32.ActiveCfg = Release|Win32
{0E231FB1-F3C9-4724-ACCB-DE8BCB3C089E}.Release SSSE3|Win32.Build.0 = Release|Win32 {0E231FB1-F3C9-4724-ACCB-DE8BCB3C089E}.Release SSSE3|Win32.Build.0 = Release|Win32
{0E231FB1-F3C9-4724-ACCB-DE8BCB3C089E}.Release SSSE3|x64.ActiveCfg = Release|Win32 {0E231FB1-F3C9-4724-ACCB-DE8BCB3C089E}.Release SSSE3|x64.ActiveCfg = Release|Win32
{0E231FB1-F3C9-4724-ACCB-DE8BCB3C089E}.Release|Win32.ActiveCfg = Release|Win32
{0E231FB1-F3C9-4724-ACCB-DE8BCB3C089E}.Release|Win32.Build.0 = Release|Win32
{0E231FB1-F3C9-4724-ACCB-DE8BCB3C089E}.Release|x64.ActiveCfg = Release|Win32
{677B7D11-D5E1-40B3-88B1-9A4DF83D2213}.Debug|Win32.ActiveCfg = Release|Win32 {677B7D11-D5E1-40B3-88B1-9A4DF83D2213}.Debug|Win32.ActiveCfg = Release|Win32
{677B7D11-D5E1-40B3-88B1-9A4DF83D2213}.Debug|Win32.Build.0 = Release|Win32 {677B7D11-D5E1-40B3-88B1-9A4DF83D2213}.Debug|Win32.Build.0 = Release|Win32
{677B7D11-D5E1-40B3-88B1-9A4DF83D2213}.Debug|x64.ActiveCfg = Debug|Win32 {677B7D11-D5E1-40B3-88B1-9A4DF83D2213}.Debug|x64.ActiveCfg = Debug|Win32
@ -569,9 +503,6 @@ Global
{677B7D11-D5E1-40B3-88B1-9A4DF83D2213}.Release SSSE3|Win32.ActiveCfg = Release|Win32 {677B7D11-D5E1-40B3-88B1-9A4DF83D2213}.Release SSSE3|Win32.ActiveCfg = Release|Win32
{677B7D11-D5E1-40B3-88B1-9A4DF83D2213}.Release SSSE3|Win32.Build.0 = Release|Win32 {677B7D11-D5E1-40B3-88B1-9A4DF83D2213}.Release SSSE3|Win32.Build.0 = Release|Win32
{677B7D11-D5E1-40B3-88B1-9A4DF83D2213}.Release SSSE3|x64.ActiveCfg = Release|Win32 {677B7D11-D5E1-40B3-88B1-9A4DF83D2213}.Release SSSE3|x64.ActiveCfg = Release|Win32
{677B7D11-D5E1-40B3-88B1-9A4DF83D2213}.Release|Win32.ActiveCfg = Release|Win32
{677B7D11-D5E1-40B3-88B1-9A4DF83D2213}.Release|Win32.Build.0 = Release|Win32
{677B7D11-D5E1-40B3-88B1-9A4DF83D2213}.Release|x64.ActiveCfg = Release|Win32
{BC236261-77E8-4567-8D09-45CD02965EB6}.Debug|Win32.ActiveCfg = Debug|Win32 {BC236261-77E8-4567-8D09-45CD02965EB6}.Debug|Win32.ActiveCfg = Debug|Win32
{BC236261-77E8-4567-8D09-45CD02965EB6}.Debug|Win32.Build.0 = Debug|Win32 {BC236261-77E8-4567-8D09-45CD02965EB6}.Debug|Win32.Build.0 = Debug|Win32
{BC236261-77E8-4567-8D09-45CD02965EB6}.Debug|x64.ActiveCfg = Debug|Win32 {BC236261-77E8-4567-8D09-45CD02965EB6}.Debug|x64.ActiveCfg = Debug|Win32
@ -587,9 +518,21 @@ Global
{BC236261-77E8-4567-8D09-45CD02965EB6}.Release SSSE3|Win32.ActiveCfg = Release|Win32 {BC236261-77E8-4567-8D09-45CD02965EB6}.Release SSSE3|Win32.ActiveCfg = Release|Win32
{BC236261-77E8-4567-8D09-45CD02965EB6}.Release SSSE3|Win32.Build.0 = Release|Win32 {BC236261-77E8-4567-8D09-45CD02965EB6}.Release SSSE3|Win32.Build.0 = Release|Win32
{BC236261-77E8-4567-8D09-45CD02965EB6}.Release SSSE3|x64.ActiveCfg = Release|Win32 {BC236261-77E8-4567-8D09-45CD02965EB6}.Release SSSE3|x64.ActiveCfg = Release|Win32
{BC236261-77E8-4567-8D09-45CD02965EB6}.Release|Win32.ActiveCfg = Release|Win32 {067D7863-393B-494F-B296-4A8853EB3D1D}.Debug|Win32.ActiveCfg = Debug|Win32
{BC236261-77E8-4567-8D09-45CD02965EB6}.Release|Win32.Build.0 = Release|Win32 {067D7863-393B-494F-B296-4A8853EB3D1D}.Debug|Win32.Build.0 = Debug|Win32
{BC236261-77E8-4567-8D09-45CD02965EB6}.Release|x64.ActiveCfg = Release|Win32 {067D7863-393B-494F-B296-4A8853EB3D1D}.Debug|x64.ActiveCfg = Debug|Win32
{067D7863-393B-494F-B296-4A8853EB3D1D}.Devel|Win32.ActiveCfg = Release|Win32
{067D7863-393B-494F-B296-4A8853EB3D1D}.Devel|Win32.Build.0 = Release|Win32
{067D7863-393B-494F-B296-4A8853EB3D1D}.Devel|x64.ActiveCfg = Devel|Win32
{067D7863-393B-494F-B296-4A8853EB3D1D}.Release SSE2|Win32.ActiveCfg = Release|Win32
{067D7863-393B-494F-B296-4A8853EB3D1D}.Release SSE2|Win32.Build.0 = Release|Win32
{067D7863-393B-494F-B296-4A8853EB3D1D}.Release SSE2|x64.ActiveCfg = Release|Win32
{067D7863-393B-494F-B296-4A8853EB3D1D}.Release SSE4|Win32.ActiveCfg = Release|Win32
{067D7863-393B-494F-B296-4A8853EB3D1D}.Release SSE4|Win32.Build.0 = Release|Win32
{067D7863-393B-494F-B296-4A8853EB3D1D}.Release SSE4|x64.ActiveCfg = Release|Win32
{067D7863-393B-494F-B296-4A8853EB3D1D}.Release SSSE3|Win32.ActiveCfg = Release|Win32
{067D7863-393B-494F-B296-4A8853EB3D1D}.Release SSSE3|Win32.Build.0 = Release|Win32
{067D7863-393B-494F-B296-4A8853EB3D1D}.Release SSSE3|x64.ActiveCfg = Release|Win32
EndGlobalSection EndGlobalSection
GlobalSection(SolutionProperties) = preSolution GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE HideSolutionNode = FALSE
@ -613,6 +556,7 @@ Global
{C34487AF-228A-4D11-8E50-27803DF76873} = {78EBE642-7A4D-4EA7-86BE-5639C6646C38} {C34487AF-228A-4D11-8E50-27803DF76873} = {78EBE642-7A4D-4EA7-86BE-5639C6646C38}
{0E231FB1-F3C9-4724-ACCB-DE8BCB3C089E} = {78EBE642-7A4D-4EA7-86BE-5639C6646C38} {0E231FB1-F3C9-4724-ACCB-DE8BCB3C089E} = {78EBE642-7A4D-4EA7-86BE-5639C6646C38}
{BC236261-77E8-4567-8D09-45CD02965EB6} = {78EBE642-7A4D-4EA7-86BE-5639C6646C38} {BC236261-77E8-4567-8D09-45CD02965EB6} = {78EBE642-7A4D-4EA7-86BE-5639C6646C38}
{067D7863-393B-494F-B296-4A8853EB3D1D} = {78EBE642-7A4D-4EA7-86BE-5639C6646C38}
{BF7B81A5-E348-4F7C-A69F-F74C8EEEAD70} = {E1828E40-2FBB-48FE-AE7F-5587755DCE0E} {BF7B81A5-E348-4F7C-A69F-F74C8EEEAD70} = {E1828E40-2FBB-48FE-AE7F-5587755DCE0E}
{3D0EB14D-32F3-4D82-9C6D-B806ADBB859C} = {E1828E40-2FBB-48FE-AE7F-5587755DCE0E} {3D0EB14D-32F3-4D82-9C6D-B806ADBB859C} = {E1828E40-2FBB-48FE-AE7F-5587755DCE0E}
{04439C5F-05FB-4A9C-AAD1-5388C25377DB} = {E1828E40-2FBB-48FE-AE7F-5587755DCE0E} {04439C5F-05FB-4A9C-AAD1-5388C25377DB} = {E1828E40-2FBB-48FE-AE7F-5587755DCE0E}

View File

@ -37,6 +37,8 @@ GPURendererSW::~GPURendererSW()
void GPURendererSW::ResetDevice() void GPURendererSW::ResetDevice()
{ {
__super::ResetDevice();
delete m_texture; delete m_texture;
m_texture = NULL; m_texture = NULL;

View File

@ -38,6 +38,7 @@ static HRESULT s_hr = E_FAIL;
static GSRenderer* s_gs = NULL; static GSRenderer* s_gs = NULL;
static void (*s_irq)() = NULL; static void (*s_irq)() = NULL;
static uint8* s_basemem = NULL; static uint8* s_basemem = NULL;
static int s_renderer = -1;
EXPORT_C_(uint32) PS2EgetLibType() EXPORT_C_(uint32) PS2EgetLibType()
{ {
@ -68,7 +69,11 @@ EXPORT_C_(uint32) PS2EgetCpuPlatform()
EXPORT_C GSsetBaseMem(uint8* mem) EXPORT_C GSsetBaseMem(uint8* mem)
{ {
s_basemem = mem - 0x12000000; s_basemem = mem;
if( s_gs )
{
s_gs->SetRegsMem( s_basemem );
}
} }
EXPORT_C_(INT32) GSinit() EXPORT_C_(INT32) GSinit()
@ -78,18 +83,26 @@ EXPORT_C_(INT32) GSinit()
return -1; return -1;
} }
#ifdef _WINDOWS
s_hr = ::CoInitializeEx(NULL, COINIT_MULTITHREADED);
if(!GSUtil::CheckDirectX())
{
return -1;
}
#endif
return 0; return 0;
} }
EXPORT_C GSshutdown() EXPORT_C GSshutdown()
{
}
EXPORT_C GSclose()
{ {
delete s_gs; delete s_gs;
s_gs = NULL; s_gs = NULL;
s_renderer = -1;
#ifdef _WINDOWS #ifdef _WINDOWS
@ -103,61 +116,151 @@ EXPORT_C GSclose()
#endif #endif
} }
static INT32 GSopen(void* dsp, char* title, int mt, int renderer) EXPORT_C GSclose()
{
if( !s_gs ) return;
s_gs->ResetDevice();
delete s_gs->m_dev;
s_gs->m_dev = NULL;
s_gs->m_wnd.Detach();
}
static INT32 _GSopen(void* dsp, char* title, int renderer)
{ {
GSclose(); GSclose();
#ifdef _WINDOWS GSDevice* dev = NULL;
s_hr = ::CoInitializeEx(NULL, COINIT_MULTITHREADED); try
if(!GSUtil::CheckDirectX())
{ {
GSFreezeData tempsave = { 0, NULL };
if(s_gs && (s_renderer != renderer))
{
// This isn't a "normal" suspend resume case -- We need to swap renderers, but
// we have to preserve the GSState at the same time, so quick-save it to the
// tempsave, and then recover below after the new GSRenderer is in place.
s_gs->Freeze(&tempsave, true);
tempsave.data = (uint8*)_aligned_malloc( tempsave.size, 16 );
if(!tempsave.data)
{
throw std::bad_alloc("Failed allocating buffer for device-change savestate.");
}
s_gs->Freeze( &tempsave, false );
delete s_gs;
s_gs = NULL;
s_renderer = -1;
}
switch(renderer)
{
default:
case 0: case 1: case 2: dev = new GSDevice9(); break;
case 3: case 4: case 5: dev = new GSDevice10(); break;
case 6: case 7: case 8: dev = new GSDevice11(); break;
#if 0
case 9: case 10: case 11: dev = new GSDeviceOGL(); break;
#endif
case 12: case 13: new GSDeviceNull(); break;
}
if( !dev ) return -1;
if( !s_gs )
{
switch(renderer)
{
default:
case 0: s_gs = new GSRendererDX9(); break;
case 3: s_gs = new GSRendererDX10(); break;
case 6: s_gs = new GSRendererDX11(); break;
#if 0
case 9: s_gs = new GSRendererOGL(); break;
#endif
case 2: case 5: case 8: case 11: case 13:
s_gs = new GSRendererNull(); break;
case 1: case 4: case 7: case 10: case 12:
s_gs = new GSRendererSW(); break;
}
s_renderer = renderer;
}
if(tempsave.data)
{
s_gs->Defrost(&tempsave);
}
}
catch( std::exception& ex )
{
// Allowing std exceptions to escape the scope of the plugin callstack could
// be problematic, because of differing typeids between DLL and EXE compilations.
// ('new' could throw std::alloc)
printf( "GSdx error: Exception caught in GSopen: %s", ex.what() );
return -1; return -1;
} }
#endif s_gs->SetRegsMem(s_basemem);
s_gs->SetIrqCallback(s_irq);
switch(renderer) if( *(HWND*)dsp == NULL )
{ {
default: // old-style API expects us to create and manage our own window:
case 0: s_gs = new GSRendererDX9(s_basemem, !!mt, s_irq); break;
case 1: s_gs = new GSRendererSW(s_basemem, !!mt, s_irq, new GSDevice9()); break; int w = theApp.GetConfig("ModeWidth", 0);
case 2: s_gs = new GSRendererNull(s_basemem, !!mt, s_irq, new GSDevice9()); break; int h = theApp.GetConfig("ModeHeight", 0);
case 3: s_gs = new GSRendererDX10(s_basemem, !!mt, s_irq); break;
case 4: s_gs = new GSRendererSW(s_basemem, !!mt, s_irq, new GSDevice10()); break; if(!s_gs->CreateWnd(title, w, h))
case 5: s_gs = new GSRendererNull(s_basemem, !!mt, s_irq, new GSDevice10()); break; {
case 6: s_gs = new GSRendererDX11(s_basemem, !!mt, s_irq); break; GSclose();
case 7: s_gs = new GSRendererSW(s_basemem, !!mt, s_irq, new GSDevice11()); break; return -1;
case 8: s_gs = new GSRendererNull(s_basemem, !!mt, s_irq, new GSDevice11()); break; }
#if 0
case 9: s_gs = new GSRendererOGL(s_basemem, !!mt, s_irq); break; s_gs->m_wnd.Show();
case 10: s_gs = new GSRendererSW(s_basemem, !!mt, s_irq, new GSDeviceOGL()); break; *(HWND*)dsp = (HWND)s_gs->m_wnd.GetHandle();
case 11: s_gs = new GSRendererNull(s_basemem, !!mt, s_irq, new GSDeviceOGL()); break; }
#endif else
case 12: s_gs = new GSRendererSW(s_basemem, !!mt, s_irq, new GSDeviceNull()); break; {
case 13: s_gs = new GSRendererNull(s_basemem, !!mt, s_irq, new GSDeviceNull()); break; s_gs->SetMultithreaded( true );
s_gs->m_wnd.Attach( *(HWND*)dsp, false );
} }
int w = theApp.GetConfig("ModeWidth", 0); if( !s_gs->CreateDevice(dev) )
int h = theApp.GetConfig("ModeHeight", 0);
if(!s_gs->Create(title, w, h))
{ {
GSclose(); GSclose();
return -1; return -1;
} }
s_gs->m_wnd.Show();
*(HWND*)dsp = (HWND)s_gs->m_wnd.GetHandle();
// if(mt) _mm_setcsr(MXCSR); // if(mt) _mm_setcsr(MXCSR);
return 0; return 0;
} }
EXPORT_C_(INT32) GSopen2( void* dsp, INT32 flags )
{
theApp.SetConfig("windowed", flags & 1);
theApp.SetConfig("vsync", flags & 2);
int renderer = theApp.GetConfig("renderer", 0);
if( flags & 4 )
{
renderer = 1;
}
return _GSopen( dsp, NULL, renderer );
}
EXPORT_C_(INT32) GSopen(void* dsp, char* title, int mt) EXPORT_C_(INT32) GSopen(void* dsp, char* title, int mt)
{ {
int renderer; int renderer;
@ -174,7 +277,16 @@ EXPORT_C_(INT32) GSopen(void* dsp, char* title, int mt)
renderer = theApp.GetConfig("renderer", 0); renderer = theApp.GetConfig("renderer", 0);
} }
return GSopen(dsp, title, mt, renderer); *(HWND*)dsp = NULL;
int retval = _GSopen(dsp, title, renderer);
if( retval == 0 && s_gs )
{
s_gs->SetMultithreaded( !!mt );
}
return retval;
} }
EXPORT_C GSreset() EXPORT_C GSreset()
@ -266,12 +378,13 @@ EXPORT_C_(int) GSfreeze(int mode, GSFreezeData* data)
EXPORT_C GSconfigure() EXPORT_C GSconfigure()
{ {
GSSettingsDlg dlg; if( GSSettingsDlg().DoModal() == IDOK )
if(IDOK == dlg.DoModal())
{ {
GSshutdown(); if( s_gs != NULL && s_gs->m_wnd.IsManaged() )
GSinit(); {
// Legacy apps like gsdxgui expect this...
GSshutdown();
}
} }
} }
@ -287,6 +400,10 @@ EXPORT_C GSabout()
EXPORT_C GSirqCallback(void (*irq)()) EXPORT_C GSirqCallback(void (*irq)())
{ {
s_irq = irq; s_irq = irq;
if( s_gs )
{
s_gs->SetIrqCallback(s_irq);
}
} }
EXPORT_C_(int) GSsetupRecording(int start, void* data) EXPORT_C_(int) GSsetupRecording(int start, void* data)
@ -348,7 +465,7 @@ EXPORT_C GSReplay(HWND hwnd, HINSTANCE hinst, LPSTR lpszCmdLine, int nCmdShow)
GSsetBaseMem(regs); GSsetBaseMem(regs);
HWND hWnd = NULL; HWND hWnd = NULL;
GSopen(&hWnd, "", true, renderer); GSopen(&hWnd, "", renderer);
uint32 crc; uint32 crc;
fread(&crc, 4, 1, fp); fread(&crc, 4, 1, fp);

View File

@ -59,7 +59,7 @@ bool GSDevice::Create(GSWnd* wnd, bool vsync)
return true; return true;
} }
bool GSDevice::Reset(int w, int h, int mode) bool GSDevice::Reset(int w, int h)
{ {
for_each(m_pool.begin(), m_pool.end(), delete_object()); for_each(m_pool.begin(), m_pool.end(), delete_object());
@ -79,7 +79,7 @@ bool GSDevice::Reset(int w, int h, int mode)
m_current = NULL; // current is special, points to other textures, no need to delete m_current = NULL; // current is special, points to other textures, no need to delete
return true; return m_wnd != NULL;
} }
void GSDevice::Present(const GSVector4i& r, int shader, bool limit) void GSDevice::Present(const GSVector4i& r, int shader, bool limit)
@ -91,7 +91,7 @@ void GSDevice::Present(const GSVector4i& r, int shader, bool limit)
if(!m_backbuffer || m_backbuffer->GetWidth() != w || m_backbuffer->GetHeight() != h) if(!m_backbuffer || m_backbuffer->GetWidth() != w || m_backbuffer->GetHeight() != h)
{ {
if(!Reset(w, h, DontCare)) if(!Reset(w, h))
{ {
return; return;
} }

View File

@ -81,7 +81,7 @@ public:
enum {Windowed, Fullscreen, DontCare}; enum {Windowed, Fullscreen, DontCare};
virtual bool Create(GSWnd* wnd, bool vsync); virtual bool Create(GSWnd* wnd, bool vsync);
virtual bool Reset(int w, int h, int mode); virtual bool Reset(int w, int h);
virtual bool IsLost(bool update = false) {return false;} virtual bool IsLost(bool update = false) {return false;}
virtual void Present(const GSVector4i& r, int shader, bool limit); virtual void Present(const GSVector4i& r, int shader, bool limit);
virtual void Flip(bool limit) {} virtual void Flip(bool limit) {}

View File

@ -27,6 +27,8 @@
GSDevice10::GSDevice10() GSDevice10::GSDevice10()
{ {
memset(&m_state, 0, sizeof(m_state)); memset(&m_state, 0, sizeof(m_state));
memset(&m_vs_cb_cache, 0, sizeof(m_vs_cb_cache));
memset(&m_ps_cb_cache, 0, sizeof(m_ps_cb_cache));
m_state.topology = D3D10_PRIMITIVE_TOPOLOGY_UNDEFINED; m_state.topology = D3D10_PRIMITIVE_TOPOLOGY_UNDEFINED;
m_state.bf = -1; m_state.bf = -1;
@ -222,16 +224,18 @@ bool GSDevice10::Create(GSWnd* wnd, bool vsync)
// //
Reset(1, 1, Windowed); Reset(1, 1);
// //
CreateTextureFX();
return true; return true;
} }
bool GSDevice10::Reset(int w, int h, int mode) bool GSDevice10::Reset(int w, int h)
{ {
if(!__super::Reset(w, h, mode)) if(!__super::Reset(w, h))
return false; return false;
if(m_swapchain) if(m_swapchain)

View File

@ -21,10 +21,10 @@
#pragma once #pragma once
#include "GSDevice.h" #include "GSDeviceDX.h"
#include "GSTexture10.h" #include "GSTexture10.h"
class GSDevice10 : public GSDevice class GSDevice10 : public GSDeviceDX
{ {
GSTexture* Create(int type, int w, int h, bool msaa, int format); GSTexture* Create(int type, int w, int h, bool msaa, int format);
@ -88,12 +88,28 @@ public: // TODO
CComPtr<ID3D10Buffer> cb; CComPtr<ID3D10Buffer> cb;
} m_interlace; } m_interlace;
CComPtr<ID3D10InputLayout> m_il;
hash_map<uint32, CComPtr<ID3D10VertexShader> > m_vs;
CComPtr<ID3D10Buffer> m_vs_cb;
hash_map<uint32, CComPtr<ID3D10GeometryShader> > m_gs;
hash_map<uint32, CComPtr<ID3D10PixelShader> > m_ps;
CComPtr<ID3D10Buffer> m_ps_cb;
hash_map<uint32, CComPtr<ID3D10SamplerState> > m_ps_ss;
CComPtr<ID3D10SamplerState> m_palette_ss;
// hash_map<uint32, CComPtr<ID3D10DepthStencilState> > m_om_dss;
CComPtr<ID3D10DepthStencilState> m_om_dss[32];
hash_map<uint32, CComPtr<ID3D10BlendState> > m_om_bs;
VSConstantBuffer m_vs_cb_cache;
PSConstantBuffer m_ps_cb_cache;
public: public:
GSDevice10(); GSDevice10();
virtual ~GSDevice10(); virtual ~GSDevice10();
bool Create(GSWnd* wnd, bool vsync); bool Create(GSWnd* wnd, bool vsync);
bool Reset(int w, int h, int mode); bool CreateTextureFX();
bool Reset(int w, int h);
void Flip(bool limit); void Flip(bool limit);
void DrawPrimitive(); void DrawPrimitive();
@ -131,6 +147,12 @@ public:
void OMSetBlendState(ID3D10BlendState* bs, float bf); void OMSetBlendState(ID3D10BlendState* bs, float bf);
void OMSetRenderTargets(GSTexture* rt, GSTexture* ds, const GSVector4i* scissor = NULL); void OMSetRenderTargets(GSTexture* rt, GSTexture* ds, const GSVector4i* scissor = NULL);
void SetupIA(const void* vertices, int count, int prim);
void SetupVS(VSSelector sel, const VSConstantBuffer* cb);
void SetupGS(GSSelector sel);
void SetupPS(PSSelector sel, const PSConstantBuffer* cb, PSSamplerSelector ssel);
void SetupOM(OMDepthStencilSelector dssel, OMBlendSelector bsel, uint8 afix);
ID3D10Device* operator->() {return m_dev;} ID3D10Device* operator->() {return m_dev;}
operator ID3D10Device*() {return m_dev;} operator ID3D10Device*() {return m_dev;}

View File

@ -27,6 +27,8 @@
GSDevice11::GSDevice11() GSDevice11::GSDevice11()
{ {
memset(&m_state, 0, sizeof(m_state)); memset(&m_state, 0, sizeof(m_state));
memset(&m_vs_cb_cache, 0, sizeof(m_vs_cb_cache));
memset(&m_ps_cb_cache, 0, sizeof(m_ps_cb_cache));
m_state.topology = D3D11_PRIMITIVE_TOPOLOGY_UNDEFINED; m_state.topology = D3D11_PRIMITIVE_TOPOLOGY_UNDEFINED;
m_state.bf = -1; m_state.bf = -1;
@ -221,16 +223,17 @@ bool GSDevice11::Create(GSWnd* wnd, bool vsync)
// //
Reset(1, 1, Windowed); Reset(1, 1);
// //
CreateTextureFX();
return true; return true;
} }
bool GSDevice11::Reset(int w, int h, int mode) bool GSDevice11::Reset(int w, int h)
{ {
if(!__super::Reset(w, h, mode)) if(!__super::Reset(w, h))
return false; return false;
if(m_swapchain) if(m_swapchain)

View File

@ -21,10 +21,10 @@
#pragma once #pragma once
#include "GSDevice.h" #include "GSDeviceDX.h"
#include "GSTexture11.h" #include "GSTexture11.h"
class GSDevice11 : public GSDevice class GSDevice11 : public GSDeviceDX
{ {
GSTexture* Create(int type, int w, int h, bool msaa, int format); GSTexture* Create(int type, int w, int h, bool msaa, int format);
@ -89,12 +89,29 @@ public: // TODO
CComPtr<ID3D11Buffer> cb; CComPtr<ID3D11Buffer> cb;
} m_interlace; } m_interlace;
// Shaders...
CComPtr<ID3D11InputLayout> m_il;
hash_map<uint32, CComPtr<ID3D11VertexShader> > m_vs;
CComPtr<ID3D11Buffer> m_vs_cb;
hash_map<uint32, CComPtr<ID3D11GeometryShader> > m_gs;
hash_map<uint32, CComPtr<ID3D11PixelShader> > m_ps;
CComPtr<ID3D11Buffer> m_ps_cb;
hash_map<uint32, CComPtr<ID3D11SamplerState> > m_ps_ss;
CComPtr<ID3D11SamplerState> m_palette_ss;
hash_map<uint32, CComPtr<ID3D11DepthStencilState> > m_om_dss;
hash_map<uint32, CComPtr<ID3D11BlendState> > m_om_bs;
VSConstantBuffer m_vs_cb_cache;
PSConstantBuffer m_ps_cb_cache;
public: public:
GSDevice11(); GSDevice11();
virtual ~GSDevice11(); virtual ~GSDevice11();
bool Create(GSWnd* wnd, bool vsync); bool Create(GSWnd* wnd, bool vsync);
bool Reset(int w, int h, int mode); bool CreateTextureFX();
bool Reset(int w, int h);
void Flip(bool limit); void Flip(bool limit);
void DrawPrimitive(); void DrawPrimitive();
@ -132,6 +149,12 @@ public:
void OMSetBlendState(ID3D11BlendState* bs, float bf); void OMSetBlendState(ID3D11BlendState* bs, float bf);
void OMSetRenderTargets(GSTexture* rt, GSTexture* ds, const GSVector4i* scissor = NULL); void OMSetRenderTargets(GSTexture* rt, GSTexture* ds, const GSVector4i* scissor = NULL);
void SetupIA(const void* vertices, int count, int prim);
void SetupVS(VSSelector sel, const VSConstantBuffer* cb);
void SetupGS(GSSelector sel);
void SetupPS(PSSelector sel, const PSConstantBuffer* cb, PSSamplerSelector ssel);
void SetupOM(OMDepthStencilSelector dssel, OMBlendSelector bsel, uint8 afix);
ID3D11Device* operator->() {return m_dev;} ID3D11Device* operator->() {return m_dev;}
operator ID3D11Device*() {return m_dev;} operator ID3D11Device*() {return m_dev;}
operator ID3D11DeviceContext*() {return m_ctx;} operator ID3D11DeviceContext*() {return m_ctx;}

View File

@ -76,14 +76,14 @@ bool GSDevice7::Create(GSWnd* wnd, bool vsync)
return false; return false;
} }
Reset(1, 1, Windowed); Reset(1, 1);
return true; return true;
} }
bool GSDevice7::Reset(int w, int h, int mode) bool GSDevice7::Reset(int w, int h)
{ {
if(!__super::Reset(w, h, mode)) if(!__super::Reset(w, h))
return false; return false;
DDSURFACEDESC2 desc; DDSURFACEDESC2 desc;
@ -147,7 +147,7 @@ void GSDevice7::Present(const GSVector4i& r, int shader, bool limit)
if(!m_backbuffer || m_backbuffer->GetWidth() != w || m_backbuffer->GetHeight() != h) if(!m_backbuffer || m_backbuffer->GetWidth() != w || m_backbuffer->GetHeight() != h)
{ {
if(!Reset(w, h, DontCare)) if(!Reset(w, h))
{ {
return; return;
} }

View File

@ -41,7 +41,7 @@ public:
virtual ~GSDevice7(); virtual ~GSDevice7();
bool Create(GSWnd* wnd, bool vsync); bool Create(GSWnd* wnd, bool vsync);
bool Reset(int w, int h, int mode); bool Reset(int w, int h);
bool IsLost(bool update) {return m_lost;} bool IsLost(bool update) {return m_lost;}
void Present(const GSVector4i& r, int shader, bool limit); void Present(const GSVector4i& r, int shader, bool limit);
}; };

View File

@ -40,6 +40,8 @@ GSDevice9::GSDevice9()
GSDevice9::~GSDevice9() GSDevice9::~GSDevice9()
{ {
for_each(m_mskfix.begin(), m_mskfix.end(), delete_second());
if(m_state.vs_cb) _aligned_free(m_state.vs_cb); if(m_state.vs_cb) _aligned_free(m_state.vs_cb);
if(m_state.ps_cb) _aligned_free(m_state.ps_cb); if(m_state.ps_cb) _aligned_free(m_state.ps_cb);
} }
@ -142,7 +144,7 @@ bool GSDevice9::Create(GSWnd* wnd, bool vsync)
// //
if(!Reset(1, 1, theApp.GetConfig("windowed", 1) ? Windowed : Fullscreen)) if(!Reset(1, 1))
{ {
return false; return false;
} }
@ -208,18 +210,24 @@ bool GSDevice9::Create(GSWnd* wnd, bool vsync)
CompileShader(IDR_INTERLACE_FX, format("ps_main%d", i), NULL, &m_interlace.ps[i]); CompileShader(IDR_INTERLACE_FX, format("ps_main%d", i), NULL, &m_interlace.ps[i]);
} }
// // create shader layout
VSSelector sel;
VSConstantBuffer cb;
SetupVS(sel, &cb);
return true; return true;
} }
bool GSDevice9::Reset(int w, int h, int mode) bool GSDevice9::Reset(int w, int h)
{ {
if(!__super::Reset(w, h, mode)) if(!__super::Reset(w, h))
return false; return false;
HRESULT hr; HRESULT hr;
int mode = theApp.GetConfig("windowed", 1) ? Windowed : Fullscreen;
if(mode == DontCare) if(mode == DontCare)
{ {
mode = m_pp.Windowed ? Windowed : Fullscreen; mode = m_pp.Windowed ? Windowed : Fullscreen;

View File

@ -21,7 +21,7 @@
#pragma once #pragma once
#include "GSDevice.h" #include "GSDeviceDX.h"
#include "GSTexture9.h" #include "GSTexture9.h"
struct Direct3DSamplerState9 struct Direct3DSamplerState9
@ -59,7 +59,7 @@ struct Direct3DBlendState9
UINT8 RenderTargetWriteMask; UINT8 RenderTargetWriteMask;
}; };
class GSDevice9 : public GSDevice class GSDevice9 : public GSDeviceDX
{ {
GSTexture* Create(int type, int w, int h, bool msaa, int format); GSTexture* Create(int type, int w, int h, bool msaa, int format);
@ -124,12 +124,25 @@ public: // TODO
CComPtr<IDirect3DPixelShader9> ps[4]; CComPtr<IDirect3DPixelShader9> ps[4];
} m_interlace; } m_interlace;
// Shaders...
CComPtr<IDirect3DVertexDeclaration9> m_il;
hash_map<uint32, CComPtr<IDirect3DVertexShader9> > m_vs;
D3DXHANDLE m_vs_params;
hash_map<uint32, CComPtr<IDirect3DPixelShader9> > m_ps;
hash_map<uint32, Direct3DSamplerState9* > m_ps_ss;
hash_map<uint32, Direct3DDepthStencilState9* > m_om_dss;
hash_map<uint32, Direct3DBlendState9* > m_om_bs;
hash_map<uint32, GSTexture*> m_mskfix;
GSTexture* CreateMskFix(uint32 size, uint32 msk, uint32 fix);
public: public:
GSDevice9(); GSDevice9();
virtual ~GSDevice9(); virtual ~GSDevice9();
bool Create(GSWnd* wnd, bool vsync); bool Create(GSWnd* wnd, bool vsync);
bool Reset(int w, int h, int mode); bool Reset(int w, int h);
bool IsLost(bool update); bool IsLost(bool update);
void Flip(bool limit); void Flip(bool limit);
@ -174,4 +187,10 @@ public:
HRESULT CompileShader(uint32 id, const string& entry, const D3DXMACRO* macro, IDirect3DVertexShader9** vs, const D3DVERTEXELEMENT9* layout, int count, IDirect3DVertexDeclaration9** il); HRESULT CompileShader(uint32 id, const string& entry, const D3DXMACRO* macro, IDirect3DVertexShader9** vs, const D3DVERTEXELEMENT9* layout, int count, IDirect3DVertexDeclaration9** il);
HRESULT CompileShader(uint32 id, const string& entry, const D3DXMACRO* macro, IDirect3DPixelShader9** ps); HRESULT CompileShader(uint32 id, const string& entry, const D3DXMACRO* macro, IDirect3DPixelShader9** ps);
void SetupIA(const void* vertices, int count, int prim);
void SetupVS(VSSelector sel, const VSConstantBuffer* cb);
void SetupGS(GSSelector sel) {}
void SetupPS(PSSelector sel, const PSConstantBuffer* cb, PSSamplerSelector ssel);
void SetupOM(OMDepthStencilSelector dssel, OMBlendSelector bsel, uint8 afix);
}; };

View File

@ -1,286 +1,283 @@
/* /*
* Copyright (C) 2007-2009 Gabest * Copyright (C) 2007-2009 Gabest
* http://www.gabest.org * http://www.gabest.org
* *
* This Program is free software; you can redistribute it and/or modify * This Program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by * it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2, or (at your option) * the Free Software Foundation; either version 2, or (at your option)
* any later version. * any later version.
* *
* This Program is distributed in the hope that it will be useful, * This Program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of * but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details. * GNU General Public License for more details.
* *
* You should have received a copy of the GNU General Public License * You should have received a copy of the GNU General Public License
* along with GNU Make; see the file COPYING. If not, write to * along with GNU Make; see the file COPYING. If not, write to
* the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. * the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
* http://www.gnu.org/copyleft/gpl.html * http://www.gnu.org/copyleft/gpl.html
* *
*/ */
#pragma once #pragma once
#include "GSVector.h" #include "GSVector.h"
#include "GSDevice.h" #include "GSDevice.h"
#include "GSAlignedClass.h" #include "GSAlignedClass.h"
class GSTextureFX : public GSAlignedClass<16> class GSDeviceDX : public GSDevice
{ {
public: public:
#pragma pack(push, 1) #pragma pack(push, 1)
enum __declspec(align(16)) struct VSConstantBuffer
{ {
FMT_32, GSVector4 VertexScale;
FMT_24, GSVector4 VertexOffset;
FMT_16, GSVector4 TextureScale;
FMT_8H,
FMT_4HL, struct VSConstantBuffer()
FMT_4HH, {
FMT_8, VertexScale = GSVector4::zero();
}; VertexOffset = GSVector4::zero();
TextureScale = GSVector4::zero();
__declspec(align(16)) struct VSConstantBuffer }
{
GSVector4 VertexScale; __forceinline bool Update(const VSConstantBuffer* cb)
GSVector4 VertexOffset; {
GSVector4 TextureScale; GSVector4i* a = (GSVector4i*)this;
GSVector4i* b = (GSVector4i*)cb;
struct VSConstantBuffer()
{ GSVector4i b0 = b[0];
VertexScale = GSVector4::zero(); GSVector4i b1 = b[1];
VertexOffset = GSVector4::zero(); GSVector4i b2 = b[2];
TextureScale = GSVector4::zero();
} if(!((a[0] == b0) & (a[1] == b1) & (a[2] == b2)).alltrue())
{
__forceinline bool Update(const VSConstantBuffer* cb) a[0] = b0;
{ a[1] = b1;
GSVector4i* a = (GSVector4i*)this; a[2] = b2;
GSVector4i* b = (GSVector4i*)cb;
return true;
GSVector4i b0 = b[0]; }
GSVector4i b1 = b[1];
GSVector4i b2 = b[2]; return false;
}
if(!((a[0] == b0) & (a[1] == b1) & (a[2] == b2)).alltrue()) };
{
a[0] = b0; struct VSSelector
a[1] = b1; {
a[2] = b2; union
{
return true; struct
} {
uint32 bppz:2;
return false; uint32 tme:1;
} uint32 fst:1;
}; uint32 logz:1;
};
struct VSSelector
{ uint32 key;
union };
{
struct operator uint32() {return key & 0x1f;}
{
uint32 bppz:2; VSSelector() : key(0) {}
uint32 tme:1; };
uint32 fst:1;
uint32 logz:1; __declspec(align(16)) struct PSConstantBuffer
}; {
GSVector4 FogColor_AREF;
uint32 key; GSVector4 HalfTexel;
}; GSVector4 WH;
GSVector4 MinMax;
operator uint32() {return key & 0x1f;} GSVector4 MinF_TA;
GSVector4i MskFix;
VSSelector() : key(0) {}
}; struct PSConstantBuffer()
{
__declspec(align(16)) struct PSConstantBuffer FogColor_AREF = GSVector4::zero();
{ HalfTexel = GSVector4::zero();
GSVector4 FogColor_AREF; WH = GSVector4::zero();
GSVector4 HalfTexel; MinMax = GSVector4::zero();
GSVector4 WH; MinF_TA = GSVector4::zero();
GSVector4 MinMax; MskFix = GSVector4i::zero();
GSVector4 MinF_TA; }
GSVector4i MskFix;
__forceinline bool Update(const PSConstantBuffer* cb)
struct PSConstantBuffer() {
{ GSVector4i* a = (GSVector4i*)this;
FogColor_AREF = GSVector4::zero(); GSVector4i* b = (GSVector4i*)cb;
HalfTexel = GSVector4::zero();
WH = GSVector4::zero(); GSVector4i b0 = b[0];
MinMax = GSVector4::zero(); GSVector4i b1 = b[1];
MinF_TA = GSVector4::zero(); GSVector4i b2 = b[2];
MskFix = GSVector4i::zero(); GSVector4i b3 = b[3];
} GSVector4i b4 = b[4];
GSVector4i b5 = b[5];
__forceinline bool Update(const PSConstantBuffer* cb)
{ if(!((a[0] == b0) /*& (a[1] == b1)*/ & (a[2] == b2) & (a[3] == b3) & (a[4] == b4) & (a[5] == b5)).alltrue()) // if WH matches HalfTexel does too
GSVector4i* a = (GSVector4i*)this; {
GSVector4i* b = (GSVector4i*)cb; a[0] = b0;
a[1] = b1;
GSVector4i b0 = b[0]; a[2] = b2;
GSVector4i b1 = b[1]; a[3] = b3;
GSVector4i b2 = b[2]; a[4] = b4;
GSVector4i b3 = b[3]; a[5] = b5;
GSVector4i b4 = b[4];
GSVector4i b5 = b[5]; return true;
}
if(!((a[0] == b0) /*& (a[1] == b1)*/ & (a[2] == b2) & (a[3] == b3) & (a[4] == b4) & (a[5] == b5)).alltrue()) // if WH matches HalfTexel does too
{ return false;
a[0] = b0; }
a[1] = b1; };
a[2] = b2;
a[3] = b3; struct GSSelector
a[4] = b4; {
a[5] = b5; union
{
return true; struct
} {
uint32 iip:1;
return false; uint32 prim:2;
} };
};
uint32 key;
struct GSSelector };
{
union operator uint32() {return key & 0x7;}
{
struct GSSelector() : key(0) {}
{ };
uint32 iip:1;
uint32 prim:2; struct PSSelector
}; {
union
uint32 key; {
}; struct
{
operator uint32() {return key & 0x7;} uint32 fst:1;
uint32 wms:2;
GSSelector() : key(0) {} uint32 wmt:2;
}; uint32 fmt:3;
uint32 aem:1;
struct PSSelector uint32 tfx:3;
{ uint32 tcc:1;
union uint32 atst:3;
{ uint32 fog:1;
struct uint32 clr1:1;
{ uint32 fba:1;
uint32 fst:1; uint32 aout:1;
uint32 wms:2; uint32 rt:1;
uint32 wmt:2; uint32 ltf:1;
uint32 fmt:3; };
uint32 aem:1;
uint32 tfx:3; uint32 key;
uint32 tcc:1; };
uint32 atst:3;
uint32 fog:1; operator uint32() {return key & 0x3fffff;}
uint32 clr1:1;
uint32 fba:1; PSSelector() : key(0) {}
uint32 aout:1; };
uint32 rt:1;
uint32 ltf:1; struct PSSamplerSelector
}; {
union
uint32 key; {
}; struct
{
operator uint32() {return key & 0x3fffff;} uint32 tau:1;
uint32 tav:1;
PSSelector() : key(0) {} uint32 ltf:1;
}; };
struct PSSamplerSelector uint32 key;
{ };
union
{ operator uint32() {return key & 0x7;}
struct
{ PSSamplerSelector() : key(0) {}
uint32 tau:1; };
uint32 tav:1;
uint32 ltf:1; struct OMDepthStencilSelector
}; {
union
uint32 key; {
}; struct
{
operator uint32() {return key & 0x7;} uint32 ztst:2;
uint32 zwe:1;
PSSamplerSelector() : key(0) {} uint32 date:1;
}; uint32 fba:1;
};
struct OMDepthStencilSelector
{ uint32 key;
union };
{
struct operator uint32() {return key & 0x1f;}
{
uint32 ztst:2; OMDepthStencilSelector() : key(0) {}
uint32 zwe:1; };
uint32 date:1;
uint32 fba:1; struct OMBlendSelector
}; {
union
uint32 key; {
}; struct
{
operator uint32() {return key & 0x1f;} uint32 abe:1;
uint32 a:2;
OMDepthStencilSelector() : key(0) {} uint32 b:2;
}; uint32 c:2;
uint32 d:2;
struct OMBlendSelector uint32 wr:1;
{ uint32 wg:1;
union uint32 wb:1;
{ uint32 wa:1;
struct };
{
uint32 abe:1; struct
uint32 a:2; {
uint32 b:2; uint32 _pad:1;
uint32 c:2; uint32 abcd:8;
uint32 d:2; uint32 wrgba:4;
uint32 wr:1; };
uint32 wg:1;
uint32 wb:1; uint32 key;
uint32 wa:1; };
};
operator uint32() {return key & 0x1fff;}
struct
{ OMBlendSelector() : key(0) {}
uint32 _pad:1;
uint32 abcd:8; bool IsCLR1() const
uint32 wrgba:4; {
}; return (key & 0x19f) == 0x93; // abe == 1 && a == 1 && b == 2 && d == 1
}
uint32 key; };
};
#pragma pack(pop)
operator uint32() {return key & 0x1fff;}
public:
OMBlendSelector() : key(0) {} GSDeviceDX() {};
virtual ~GSDeviceDX() {}
bool IsCLR1() const
{ virtual bool Create(GSWnd* wnd, bool vsync)
return (key & 0x19f) == 0x93; // abe == 1 && a == 1 && b == 2 && d == 1 {
} return __super::Create( wnd, vsync );
}; }
#pragma pack(pop) virtual bool Reset(int w, int h)
{
protected: return __super::Reset( w, h );
GSDevice* m_dev; }
public: //virtual void Present(const GSVector4i& r, int shader, bool limit);
GSTextureFX(); //virtual void Flip(bool limit) {}
virtual ~GSTextureFX() {}
virtual void SetupIA(const void* vertices, int count, int prim) = 0;
virtual bool Create(GSDevice* dev); virtual void SetupVS(VSSelector sel, const VSConstantBuffer* cb) = 0;
virtual void SetupGS(GSSelector sel) = 0;
virtual void SetupIA(const void* vertices, int count, int prim) = 0; virtual void SetupPS(PSSelector sel, const PSConstantBuffer* cb, PSSamplerSelector ssel) = 0;
virtual void SetupVS(VSSelector sel, const VSConstantBuffer* cb) = 0; virtual void SetupOM(OMDepthStencilSelector dssel, OMBlendSelector bsel, uint8 afix) = 0;
virtual void SetupGS(GSSelector sel) = 0; };
virtual void SetupPS(PSSelector sel, const PSConstantBuffer* cb, PSSamplerSelector ssel) = 0;
virtual void SetupOM(OMDepthStencilSelector dssel, OMBlendSelector bsel, uint8 afix) = 0;
};

View File

@ -29,14 +29,14 @@ bool GSDeviceNull::Create(GSWnd* wnd, bool vsync)
return false; return false;
} }
Reset(1, 1, Windowed); Reset(1, 1);
return true; return true;
} }
bool GSDeviceNull::Reset(int w, int h, int mode) bool GSDeviceNull::Reset(int w, int h)
{ {
if(!__super::Reset(w, h, mode)) if(!__super::Reset(w, h))
return false; return false;
return true; return true;

View File

@ -36,5 +36,5 @@ public:
GSDeviceNull() {} GSDeviceNull() {}
bool Create(GSWnd* wnd, bool vsync); bool Create(GSWnd* wnd, bool vsync);
bool Reset(int w, int h, int mode); bool Reset(int w, int h);
}; };

View File

@ -150,14 +150,14 @@ bool GSDeviceOGL::Create(GSWnd* wnd, bool vsync)
*/ */
GSVector4i r = wnd->GetClientRect(); GSVector4i r = wnd->GetClientRect();
Reset(r.width(), r.height(), Windowed); Reset(r.width(), r.height());
return true; return true;
} }
bool GSDeviceOGL::Reset(int w, int h, int mode) bool GSDeviceOGL::Reset(int w, int h)
{ {
if(!__super::Reset(w, h, mode)) if(!__super::Reset(w, h))
return false; return false;
glCullFace(GL_FRONT_AND_BACK); CheckError(); glCullFace(GL_FRONT_AND_BACK); CheckError();

View File

@ -110,7 +110,7 @@ public:
virtual ~GSDeviceOGL(); virtual ~GSDeviceOGL();
bool Create(GSWnd* wnd, bool vsync); bool Create(GSWnd* wnd, bool vsync);
bool Reset(int w, int h, int mode); bool Reset(int w, int h);
void Present(const GSVector4i& r, int shader, bool limit); void Present(const GSVector4i& r, int shader, bool limit);
void Flip(bool limit); void Flip(bool limit);

View File

@ -22,9 +22,9 @@
#include "StdAfx.h" #include "StdAfx.h"
#include "GSRenderer.h" #include "GSRenderer.h"
GSRenderer::GSRenderer(uint8* base, bool mt, void (*irq)(), GSDevice* dev) GSRenderer::GSRenderer()
: GSState(base, mt, irq) : GSState()
, m_dev(dev) , m_dev(NULL)
, m_shader(0) , m_shader(0)
, m_vt(this) , m_vt(this)
{ {
@ -47,29 +47,34 @@ GSRenderer::GSRenderer(uint8* base, bool mt, void (*irq)(), GSDevice* dev)
GSRenderer::~GSRenderer() GSRenderer::~GSRenderer()
{ {
if(m_dev) /*if(m_dev)
{ {
m_dev->Reset(1, 1, GSDevice::Windowed); m_dev->Reset(1, 1, GSDevice::Windowed);
} }*/
delete m_dev; delete m_dev;
} }
bool GSRenderer::Create(const string& title, int w, int h) bool GSRenderer::CreateWnd(const string& title, int w, int h)
{ {
if(!m_wnd.Create(title.c_str(), w, h)) if(!m_wnd.Create(title.c_str(), w, h))
{ {
return false; return false;
} }
return true;
}
ASSERT(m_dev); bool GSRenderer::CreateDevice(GSDevice* dev)
{
ASSERT(dev);
ASSERT(!m_dev);
if(!m_dev->Create(&m_wnd, m_vsync)) if(!dev->Create(&m_wnd, m_vsync))
{ {
return false; return false;
} }
Reset(); m_dev = dev;
return true; return true;
} }
@ -316,7 +321,11 @@ void GSRenderer::VSync(int field)
s += " | Recording..."; s += " | Recording...";
} }
m_wnd.SetWindowText(s.c_str()); if( !m_wnd.SetWindowText(s.c_str()) )
{
// We don't have window title rights, or the window has no title,
// so let's use actual OSD!
}
} }
if(m_frameskip) if(m_frameskip)

View File

@ -46,7 +46,6 @@ protected:
bool m_aa1; bool m_aa1;
bool m_blur; bool m_blur;
virtual void ResetDevice() {}
virtual GSTexture* GetOutput(int i) = 0; virtual GSTexture* GetOutput(int i) = 0;
GSVertexTrace m_vt; GSVertexTrace m_vt;
@ -70,10 +69,16 @@ public:
int s_saven; int s_saven;
public: public:
GSRenderer(uint8* base, bool mt, void (*irq)(), GSDevice* dev); GSRenderer();
virtual ~GSRenderer(); virtual ~GSRenderer();
virtual bool Create(const string& title, int w, int h); virtual bool CreateWnd(const string& title, int w, int h);
virtual bool CreateDevice(GSDevice* dev);
virtual void ResetDevice()
{
InvalidateTextureCache();
ResetPrim();
}
virtual void VSync(int field); virtual void VSync(int field);
virtual bool MakeSnapshot(const string& path); virtual bool MakeSnapshot(const string& path);
virtual void KeyEvent(GSKeyEventData* e, int param = 0); virtual void KeyEvent(GSKeyEventData* e, int param = 0);
@ -212,8 +217,8 @@ protected:
virtual void Draw() = 0; virtual void Draw() = 0;
public: public:
GSRendererT(uint8* base, bool mt, void (*irq)(), GSDevice* dev) GSRendererT()
: GSRenderer(base, mt, irq, dev) : GSRenderer()
, m_vertices(NULL) , m_vertices(NULL)
, m_count(0) , m_count(0)
, m_maxcount(0) , m_maxcount(0)

View File

@ -22,12 +22,10 @@
#pragma once #pragma once
#include "GSRendererHW.h" #include "GSRendererHW.h"
#include "GSTextureFX.h"
template<class Vertex> template<class Vertex>
class GSRendererDX : public GSRendererHW<Vertex> class GSRendererDX : public GSRendererHW<Vertex>
{ {
GSTextureFX* m_tfx;
GSVector2 m_pixelcenter; GSVector2 m_pixelcenter;
bool m_logz; bool m_logz;
bool m_fba; bool m_fba;
@ -41,9 +39,8 @@ protected:
virtual void UpdateFBA(GSTexture* rt) {} virtual void UpdateFBA(GSTexture* rt) {}
public: public:
GSRendererDX(uint8* base, bool mt, void (*irq)(), GSDevice* dev, GSTextureCache* tc, GSTextureFX* tfx, const GSVector2& pixelcenter = GSVector2(0, 0)) GSRendererDX(GSTextureCache* tc, const GSVector2& pixelcenter = GSVector2(0, 0))
: GSRendererHW<Vertex>(base, mt, irq, dev, tc) : GSRendererHW<Vertex>(tc)
, m_tfx(tfx)
, m_pixelcenter(pixelcenter) , m_pixelcenter(pixelcenter)
, m_topology(-1) , m_topology(-1)
{ {
@ -55,36 +52,34 @@ public:
virtual ~GSRendererDX() virtual ~GSRendererDX()
{ {
delete m_tfx;
} }
bool Create(const string& title, int w, int h) bool CreateDevice(GSDevice* dev)
{ {
if(!__super::Create(title, w, h)) if(!__super::CreateDevice(dev))
return false;
if(!m_tfx->Create(m_dev))
return false; return false;
return true; return true;
} }
void Draw(GSTexture* rt, GSTexture* ds, GSTextureCache::Source* tex) __forceinline void Draw(GSTexture* rt, GSTexture* ds, GSTextureCache::Source* tex)
{ {
GSDrawingEnvironment& env = m_env; GSDrawingEnvironment& env = m_env;
GSDrawingContext* context = m_context; GSDrawingContext* context = m_context;
GSDeviceDX& dev = (GSDeviceDX&)*m_dev;
// //
SetupDATE(rt, ds); SetupDATE(rt, ds);
// //
m_dev->BeginScene(); dev.BeginScene();
// om // om
GSTextureFX::OMDepthStencilSelector om_dssel; GSDeviceDX::OMDepthStencilSelector om_dssel;
if(context->TEST.ZTE) if(context->TEST.ZTE)
{ {
@ -106,7 +101,7 @@ public:
om_dssel.fba = context->FBA.FBA; om_dssel.fba = context->FBA.FBA;
} }
GSTextureFX::OMBlendSelector om_bsel; GSDeviceDX::OMBlendSelector om_bsel;
if(!IsOpaque()) if(!IsOpaque())
{ {
@ -137,7 +132,7 @@ public:
// vs // vs
GSTextureFX::VSSelector vs_sel; GSDeviceDX::VSSelector vs_sel;
vs_sel.tme = PRIM->TME; vs_sel.tme = PRIM->TME;
vs_sel.fst = PRIM->FST; vs_sel.fst = PRIM->FST;
@ -167,7 +162,7 @@ public:
} }
} }
GSTextureFX::VSConstantBuffer vs_cb; GSDeviceDX::VSConstantBuffer vs_cb;
float sx = 2.0f * rt->GetScale().x / (rt->GetWidth() << 4); float sx = 2.0f * rt->GetScale().x / (rt->GetWidth() << 4);
float sy = 2.0f * rt->GetScale().y / (rt->GetHeight() << 4); float sy = 2.0f * rt->GetScale().y / (rt->GetHeight() << 4);
@ -181,16 +176,16 @@ public:
// gs // gs
GSTextureFX::GSSelector gs_sel; GSDeviceDX::GSSelector gs_sel;
gs_sel.iip = PRIM->IIP; gs_sel.iip = PRIM->IIP;
gs_sel.prim = m_vt.m_primclass; gs_sel.prim = m_vt.m_primclass;
// ps // ps
GSTextureFX::PSSelector ps_sel; GSDeviceDX::PSSelector ps_sel;
GSTextureFX::PSSamplerSelector ps_ssel; GSDeviceDX::PSSamplerSelector ps_ssel;
GSTextureFX::PSConstantBuffer ps_cb; GSDeviceDX::PSConstantBuffer ps_cb;
ps_sel.clr1 = om_bsel.IsCLR1(); ps_sel.clr1 = om_bsel.IsCLR1();
ps_sel.fba = context->FBA.FBA; ps_sel.fba = context->FBA.FBA;
@ -274,22 +269,22 @@ public:
GSVector4i scissor = GSVector4i(GSVector4(rt->GetScale()).xyxy() * context->scissor.in).rintersect(GSVector4i(rt->GetSize()).zwxy()); GSVector4i scissor = GSVector4i(GSVector4(rt->GetScale()).xyxy() * context->scissor.in).rintersect(GSVector4i(rt->GetSize()).zwxy());
m_dev->OMSetRenderTargets(rt, ds, &scissor); dev.OMSetRenderTargets(rt, ds, &scissor);
m_dev->PSSetShaderResources(tex ? tex->m_texture : NULL, tex ? tex->m_palette : NULL); dev.PSSetShaderResources(tex ? tex->m_texture : NULL, tex ? tex->m_palette : NULL);
uint8 afix = context->ALPHA.FIX; uint8 afix = context->ALPHA.FIX;
m_tfx->SetupOM(om_dssel, om_bsel, afix); dev.SetupOM(om_dssel, om_bsel, afix);
m_tfx->SetupIA(m_vertices, m_count, m_topology); dev.SetupIA(m_vertices, m_count, m_topology);
m_tfx->SetupVS(vs_sel, &vs_cb); dev.SetupVS(vs_sel, &vs_cb);
m_tfx->SetupGS(gs_sel); dev.SetupGS(gs_sel);
m_tfx->SetupPS(ps_sel, &ps_cb, ps_ssel); dev.SetupPS(ps_sel, &ps_cb, ps_ssel);
// draw // draw
if(context->TEST.DoFirstPass()) if(context->TEST.DoFirstPass())
{ {
m_dev->DrawPrimitive(); dev.DrawPrimitive();
} }
if(context->TEST.DoSecondPass()) if(context->TEST.DoSecondPass())
@ -313,7 +308,7 @@ public:
break; break;
} }
m_tfx->SetupPS(ps_sel, &ps_cb, ps_ssel); dev.SetupPS(ps_sel, &ps_cb, ps_ssel);
bool z = om_dssel.zwe; bool z = om_dssel.zwe;
bool r = om_bsel.wr; bool r = om_bsel.wr;
@ -338,13 +333,13 @@ public:
om_bsel.wb = b; om_bsel.wb = b;
om_bsel.wa = a; om_bsel.wa = a;
m_tfx->SetupOM(om_dssel, om_bsel, afix); dev.SetupOM(om_dssel, om_bsel, afix);
m_dev->DrawPrimitive(); dev.DrawPrimitive();
} }
} }
m_dev->EndScene(); dev.EndScene();
if(om_dssel.fba) UpdateFBA(rt); if(om_dssel.fba) UpdateFBA(rt);
} }

View File

@ -24,15 +24,15 @@
#include "GSCrc.h" #include "GSCrc.h"
#include "resource.h" #include "resource.h"
GSRendererDX10::GSRendererDX10(uint8* base, bool mt, void (*irq)()) GSRendererDX10::GSRendererDX10()
: GSRendererDX<GSVertexHW10>(base, mt, irq, new GSDevice10(), new GSTextureCache10(this), new GSTextureFX10(), GSVector2(-0.5f, -0.5f)) : GSRendererDX<GSVertexHW10>(new GSTextureCache10(this), GSVector2(-0.5f, -0.5f))
{ {
InitVertexKick<GSRendererDX10>(); InitVertexKick<GSRendererDX10>();
} }
bool GSRendererDX10::Create(const string& title, int w, int h) bool GSRendererDX10::CreateDevice(GSDevice* dev)
{ {
if(!__super::Create(title, w, h)) if(!__super::CreateDevice(dev))
return false; return false;
// //

View File

@ -24,7 +24,6 @@
#include "GSRendererDX.h" #include "GSRendererDX.h"
#include "GSVertexHW.h" #include "GSVertexHW.h"
#include "GSTextureCache10.h" #include "GSTextureCache10.h"
#include "GSTextureFX10.h"
class GSRendererDX10 : public GSRendererDX<GSVertexHW10> class GSRendererDX10 : public GSRendererDX<GSVertexHW10>
{ {
@ -39,9 +38,9 @@ protected:
void SetupDATE(GSTexture* rt, GSTexture* ds); void SetupDATE(GSTexture* rt, GSTexture* ds);
public: public:
GSRendererDX10(uint8* base, bool mt, void (*irq)()); GSRendererDX10();
bool Create(const string& title, int w, int h); bool CreateDevice(GSDevice* dev);
template<uint32 prim, uint32 tme, uint32 fst> void VertexKick(bool skip); template<uint32 prim, uint32 tme, uint32 fst> void VertexKick(bool skip);
}; };

View File

@ -24,15 +24,15 @@
#include "GSCrc.h" #include "GSCrc.h"
#include "resource.h" #include "resource.h"
GSRendererDX11::GSRendererDX11(uint8* base, bool mt, void (*irq)()) GSRendererDX11::GSRendererDX11()
: GSRendererDX<GSVertexHW11>(base, mt, irq, new GSDevice11(), new GSTextureCache11(this), new GSTextureFX11(), GSVector2(-0.5f, -0.5f)) : GSRendererDX<GSVertexHW11>(new GSTextureCache11(this), GSVector2(-0.5f, -0.5f))
{ {
InitVertexKick<GSRendererDX11>(); InitVertexKick<GSRendererDX11>();
} }
bool GSRendererDX11::Create(const string& title, int w, int h) bool GSRendererDX11::CreateDevice(GSDevice* dev)
{ {
if(!__super::Create(title, w, h)) if(!__super::CreateDevice(dev))
return false; return false;
// //

View File

@ -24,7 +24,6 @@
#include "GSRendererDX.h" #include "GSRendererDX.h"
#include "GSVertexHW.h" #include "GSVertexHW.h"
#include "GSTextureCache11.h" #include "GSTextureCache11.h"
#include "GSTextureFX11.h"
class GSRendererDX11 : public GSRendererDX<GSVertexHW11> class GSRendererDX11 : public GSRendererDX<GSVertexHW11>
{ {
@ -40,9 +39,9 @@ protected:
void SetupDATE(GSTexture* rt, GSTexture* ds); void SetupDATE(GSTexture* rt, GSTexture* ds);
public: public:
GSRendererDX11(uint8* base, bool mt, void (*irq)()); GSRendererDX11();
bool Create(const string& title, int w, int h); bool CreateDevice(GSDevice* dev);
template<uint32 prim, uint32 tme, uint32 fst> void VertexKick(bool skip); template<uint32 prim, uint32 tme, uint32 fst> void VertexKick(bool skip);
}; };

View File

@ -24,15 +24,15 @@
#include "GSCrc.h" #include "GSCrc.h"
#include "resource.h" #include "resource.h"
GSRendererDX9::GSRendererDX9(uint8* base, bool mt, void (*irq)()) GSRendererDX9::GSRendererDX9()
: GSRendererDX<GSVertexHW9>(base, mt, irq, new GSDevice9(), new GSTextureCache9(this), new GSTextureFX9()) : GSRendererDX<GSVertexHW9>(new GSTextureCache9(this))
{ {
InitVertexKick<GSRendererDX9>(); InitVertexKick<GSRendererDX9>();
} }
bool GSRendererDX9::Create(const string& title, int w, int h) bool GSRendererDX9::CreateDevice(GSDevice* dev)
{ {
if(!__super::Create(title, w, h)) if(!__super::CreateDevice(dev))
return false; return false;
// //

View File

@ -24,7 +24,6 @@
#include "GSRendererDX.h" #include "GSRendererDX.h"
#include "GSVertexHW.h" #include "GSVertexHW.h"
#include "GSTextureCache9.h" #include "GSTextureCache9.h"
#include "GSTextureFX9.h"
class GSRendererDX9 : public GSRendererDX<GSVertexHW9> class GSRendererDX9 : public GSRendererDX<GSVertexHW9>
{ {
@ -46,9 +45,9 @@ protected:
void UpdateFBA(GSTexture* rt); void UpdateFBA(GSTexture* rt);
public: public:
GSRendererDX9(uint8* base, bool mt, void (*irq)()); GSRendererDX9();
bool Create(const string& title, int w, int h); bool CreateDevice(GSDevice* dev);
template<uint32 prim, uint32 tme, uint32 fst> void VertexKick(bool skip); template<uint32 prim, uint32 tme, uint32 fst> void VertexKick(bool skip);
}; };

View File

@ -478,6 +478,7 @@ protected:
void ResetDevice() void ResetDevice()
{ {
__super::ResetDevice();
m_tc->RemoveAll(); m_tc->RemoveAll();
} }
@ -703,8 +704,8 @@ protected:
} }
public: public:
GSRendererHW(uint8* base, bool mt, void (*irq)(), GSDevice* dev, GSTextureCache* tc) GSRendererHW(GSTextureCache* tc)
: GSRendererT<Vertex>(base, mt, irq, dev) : GSRendererT<Vertex>()
, m_tc(tc) , m_tc(tc)
, m_width(1024) , m_width(1024)
, m_height(1024) , m_height(1024)

View File

@ -37,8 +37,8 @@ protected:
} }
public: public:
GSRendererNull(uint8* base, bool mt, void (*irq)(), GSDevice* dev) GSRendererNull()
: GSRendererT<GSVertexNull>(base, mt, irq, dev) : GSRendererT<GSVertexNull>()
{ {
InitVertexKick<GSRendererNull>(); InitVertexKick<GSRendererNull>();
} }

View File

@ -24,15 +24,15 @@
#include "GSCrc.h" #include "GSCrc.h"
#include "resource.h" #include "resource.h"
GSRendererOGL::GSRendererOGL(uint8* base, bool mt, void (*irq)()) GSRendererOGL::GSRendererOGL()
: GSRendererHW<GSVertexOGL>(base, mt, irq, new GSDeviceOGL(), new GSTextureCacheOGL(this)) : GSRendererHW<GSVertexOGL>(new GSTextureCacheOGL(this))
{ {
InitVertexKick<GSRendererOGL>(); InitVertexKick<GSRendererOGL>();
} }
bool GSRendererOGL::Create(const string& title, int w, int h) bool GSRendererOGL::CreateDevice(GSDevice* dev)
{ {
if(!__super::Create(title, w, h)) if(!__super::CreateDevice(dev))
return false; return false;
// TODO // TODO

View File

@ -24,7 +24,6 @@
#include "GSRendererHW.h" #include "GSRendererHW.h"
#include "GSVertexHW.h" #include "GSVertexHW.h"
#include "GSTextureCacheOGL.h" #include "GSTextureCacheOGL.h"
// TODO: #include "GSTextureFXOGL.h"
class GSRendererOGL : public GSRendererHW<GSVertexOGL> class GSRendererOGL : public GSRendererHW<GSVertexOGL>
{ {
@ -32,9 +31,9 @@ protected:
void Draw(GSTexture* rt, GSTexture* ds, GSTextureCache::Source* tex); void Draw(GSTexture* rt, GSTexture* ds, GSTextureCache::Source* tex);
public: public:
GSRendererOGL(uint8* base, bool mt, void (*irq)()); GSRendererOGL();
bool Create(const string& title, int w, int h); bool CreateDevice(GSDevice* dev);
template<uint32 prim, uint32 tme, uint32 fst> void VertexKick(bool skip); template<uint32 prim, uint32 tme, uint32 fst> void VertexKick(bool skip);
}; };

View File

@ -24,8 +24,8 @@
const GSVector4 g_pos_scale(1.0f / 16, 1.0f / 16, 1.0f, 128.0f); const GSVector4 g_pos_scale(1.0f / 16, 1.0f / 16, 1.0f, 128.0f);
GSRendererSW::GSRendererSW(uint8* base, bool mt, void (*irq)(), GSDevice* dev) GSRendererSW::GSRendererSW()
: GSRendererT(base, mt, irq, dev) : GSRendererT()
{ {
m_tc = new GSTextureCacheSW(this); m_tc = new GSTextureCacheSW(this);

View File

@ -44,7 +44,7 @@ protected:
void GetScanlineParam(GSScanlineParam& p, GS_PRIM_CLASS primclass); void GetScanlineParam(GSScanlineParam& p, GS_PRIM_CLASS primclass);
public: public:
GSRendererSW(uint8* base, bool mt, void (*irq)(), GSDevice* dev); GSRendererSW();
virtual ~GSRendererSW(); virtual ~GSRendererSW();
template<uint32 prim, uint32 tme, uint32 fst> template<uint32 prim, uint32 tme, uint32 fst>

View File

@ -22,9 +22,10 @@
#include "stdafx.h" #include "stdafx.h"
#include "GSState.h" #include "GSState.h"
GSState::GSState(uint8* base, bool mt, void (*irq)()) GSState::GSState()
: m_mt(mt) : m_mt(false)
, m_irq(irq) , m_irq(NULL)
, m_regs(NULL)
, m_crc(0) , m_crc(0)
, m_options(0) , m_options(0)
, m_path3hack(0) , m_path3hack(0)
@ -84,10 +85,6 @@ GSState::GSState(uint8* base, bool mt, void (*irq)())
m_sssize += (sizeof(m_path[0].tag) + sizeof(m_path[0].reg)) * 3; m_sssize += (sizeof(m_path[0].tag) + sizeof(m_path[0].reg)) * 3;
m_sssize += sizeof(m_q); m_sssize += sizeof(m_q);
ASSERT(base);
m_regs = (GSPrivRegSet*)(base + 0x12000000);
PRIM = &m_env.PRIM; PRIM = &m_env.PRIM;
// CSR->rREV = 0x20; // CSR->rREV = 0x20;
m_env.PRMODECONT.AC = 1; m_env.PRMODECONT.AC = 1;
@ -101,6 +98,39 @@ GSState::~GSState()
{ {
} }
void GSState::SetRegsMem(uint8* basemem)
{
ASSERT(basemem);
m_regs = (GSPrivRegSet*)basemem;
}
void GSState::SetIrqCallback(void (*irq)())
{
m_irq = irq;
}
void GSState::SetMultithreaded( bool isMT )
{
// Some older versions of PCSX2 didn't properly set the irq callback to NULL
// in multithreaded mode (possibly because ZeroGS itself would assert in such
// cases), and didn't bind them to a dummy callback either. PCSX2 handles all
// IRQs internally when multithreaded anyway -- so let's ignore them here:
m_mt = isMT;
if( isMT )
{
m_fpGIFRegHandlers[GIF_A_D_REG_SIGNAL] = &GSState::GIFRegHandlerNull;
m_fpGIFRegHandlers[GIF_A_D_REG_FINISH] = &GSState::GIFRegHandlerNull;
m_fpGIFRegHandlers[GIF_A_D_REG_LABEL] = &GSState::GIFRegHandlerNull;
}
else
{
m_fpGIFRegHandlers[GIF_A_D_REG_SIGNAL] = &GSState::GIFRegHandlerSIGNAL;
m_fpGIFRegHandlers[GIF_A_D_REG_FINISH] = &GSState::GIFRegHandlerFINISH;
m_fpGIFRegHandlers[GIF_A_D_REG_LABEL] = &GSState::GIFRegHandlerLABEL;
}
}
void GSState::Reset() void GSState::Reset()
{ {
memset(&m_path[0], 0, sizeof(m_path[0]) * 3); memset(&m_path[0], 0, sizeof(m_path[0]) * 3);
@ -196,9 +226,8 @@ void GSState::ResetHandlers()
m_fpGIFRegHandlers[GIF_A_D_REG_TRXREG] = &GSState::GIFRegHandlerTRXREG; m_fpGIFRegHandlers[GIF_A_D_REG_TRXREG] = &GSState::GIFRegHandlerTRXREG;
m_fpGIFRegHandlers[GIF_A_D_REG_TRXDIR] = &GSState::GIFRegHandlerTRXDIR; m_fpGIFRegHandlers[GIF_A_D_REG_TRXDIR] = &GSState::GIFRegHandlerTRXDIR;
m_fpGIFRegHandlers[GIF_A_D_REG_HWREG] = &GSState::GIFRegHandlerHWREG; m_fpGIFRegHandlers[GIF_A_D_REG_HWREG] = &GSState::GIFRegHandlerHWREG;
m_fpGIFRegHandlers[GIF_A_D_REG_SIGNAL] = &GSState::GIFRegHandlerSIGNAL;
m_fpGIFRegHandlers[GIF_A_D_REG_FINISH] = &GSState::GIFRegHandlerFINISH; SetMultithreaded( m_mt );
m_fpGIFRegHandlers[GIF_A_D_REG_LABEL] = &GSState::GIFRegHandlerLABEL;
} }
GSVector4i GSState::GetDisplayRect(int i) GSVector4i GSState::GetDisplayRect(int i)
@ -912,8 +941,6 @@ void GSState::GIFRegHandlerHWREG(GIFReg* r)
void GSState::GIFRegHandlerSIGNAL(GIFReg* r) void GSState::GIFRegHandlerSIGNAL(GIFReg* r)
{ {
if(m_mt) return;
m_regs->SIGLBLID.SIGID = (m_regs->SIGLBLID.SIGID & ~r->SIGNAL.IDMSK) | (r->SIGNAL.ID & r->SIGNAL.IDMSK); m_regs->SIGLBLID.SIGID = (m_regs->SIGLBLID.SIGID & ~r->SIGNAL.IDMSK) | (r->SIGNAL.ID & r->SIGNAL.IDMSK);
if(m_regs->CSR.wSIGNAL) m_regs->CSR.rSIGNAL = 1; if(m_regs->CSR.wSIGNAL) m_regs->CSR.rSIGNAL = 1;
@ -922,16 +949,12 @@ void GSState::GIFRegHandlerSIGNAL(GIFReg* r)
void GSState::GIFRegHandlerFINISH(GIFReg* r) void GSState::GIFRegHandlerFINISH(GIFReg* r)
{ {
if(m_mt) return;
if(m_regs->CSR.wFINISH) m_regs->CSR.rFINISH = 1; if(m_regs->CSR.wFINISH) m_regs->CSR.rFINISH = 1;
if(!m_regs->IMR.FINISHMSK && m_irq) m_irq(); if(!m_regs->IMR.FINISHMSK && m_irq) m_irq();
} }
void GSState::GIFRegHandlerLABEL(GIFReg* r) void GSState::GIFRegHandlerLABEL(GIFReg* r)
{ {
if(m_mt) return;
m_regs->SIGLBLID.LBLID = (m_regs->SIGLBLID.LBLID & ~r->LABEL.IDMSK) | (r->LABEL.ID & r->LABEL.IDMSK); m_regs->SIGLBLID.LBLID = (m_regs->SIGLBLID.LBLID & ~r->LABEL.IDMSK) | (r->LABEL.ID & r->LABEL.IDMSK);
} }

View File

@ -215,7 +215,7 @@ public:
GSDump m_dump; GSDump m_dump;
public: public:
GSState(uint8* base, bool mt, void (*irq)()); GSState();
virtual ~GSState(); virtual ~GSState();
void ResetHandlers(); void ResetHandlers();
@ -250,5 +250,8 @@ public:
virtual void SetGameCRC(uint32 crc, int options); virtual void SetGameCRC(uint32 crc, int options);
void SetFrameSkip(int skip); void SetFrameSkip(int skip);
void SetFrameLimit(bool limit); void SetFrameLimit(bool limit);
void SetRegsMem(uint8* basemem);
void SetIrqCallback(void (*irq)());
void SetMultithreaded(bool isMT=true);
}; };

View File

@ -21,7 +21,6 @@
#include "StdAfx.h" #include "StdAfx.h"
#include "GSTextureCache.h" #include "GSTextureCache.h"
#include "GSTextureFX.h"
GSTextureCache::GSTextureCache(GSRenderer* r) GSTextureCache::GSTextureCache(GSRenderer* r)
: m_renderer(r) : m_renderer(r)
@ -497,14 +496,14 @@ GSTextureCache::Source* GSTextureCache::CreateSource(const GIFRegTEX0& TEX0, con
{ {
if(m_paltex && GSLocalMemory::m_psm[TEX0.PSM].pal > 0) if(m_paltex && GSLocalMemory::m_psm[TEX0.PSM].pal > 0)
{ {
src->m_fmt = GSTextureFX::FMT_8; src->m_fmt = FMT_8;
src->m_texture = m_renderer->m_dev->CreateTexture(tw, th, Get8bitFormat()); src->m_texture = m_renderer->m_dev->CreateTexture(tw, th, Get8bitFormat());
src->m_palette = m_renderer->m_dev->CreateTexture(256, 1); src->m_palette = m_renderer->m_dev->CreateTexture(256, 1);
} }
else else
{ {
src->m_fmt = GSTextureFX::FMT_32; src->m_fmt = FMT_32;
src->m_texture = m_renderer->m_dev->CreateTexture(tw, th); src->m_texture = m_renderer->m_dev->CreateTexture(tw, th);
} }
@ -650,25 +649,25 @@ GSTextureCache::Source* GSTextureCache::CreateSource(const GIFRegTEX0& TEX0, con
default: default:
ASSERT(0); ASSERT(0);
case PSM_PSMCT32: case PSM_PSMCT32:
src->m_fmt = GSTextureFX::FMT_32; src->m_fmt = FMT_32;
break; break;
case PSM_PSMCT24: case PSM_PSMCT24:
src->m_fmt = GSTextureFX::FMT_24; src->m_fmt = FMT_24;
break; break;
case PSM_PSMCT16: case PSM_PSMCT16:
case PSM_PSMCT16S: case PSM_PSMCT16S:
src->m_fmt = GSTextureFX::FMT_16; src->m_fmt = FMT_16;
break; break;
case PSM_PSMT8H: case PSM_PSMT8H:
src->m_fmt = GSTextureFX::FMT_8H; src->m_fmt = FMT_8H;
src->m_palette = m_renderer->m_dev->CreateTexture(256, 1); src->m_palette = m_renderer->m_dev->CreateTexture(256, 1);
break; break;
case PSM_PSMT4HL: case PSM_PSMT4HL:
src->m_fmt = GSTextureFX::FMT_4HL; src->m_fmt = FMT_4HL;
src->m_palette = m_renderer->m_dev->CreateTexture(256, 1); src->m_palette = m_renderer->m_dev->CreateTexture(256, 1);
break; break;
case PSM_PSMT4HH: case PSM_PSMT4HH:
src->m_fmt = GSTextureFX::FMT_4HH; src->m_fmt = FMT_4HH;
src->m_palette = m_renderer->m_dev->CreateTexture(256, 1); src->m_palette = m_renderer->m_dev->CreateTexture(256, 1);
break; break;
} }
@ -863,7 +862,7 @@ void GSTextureCache::Source::Update(const GIFRegTEX0& TEX0, const GIFRegTEXA& TE
} }
} }
m_renderer->m_perfmon.Put(GSPerfMon::Unswizzle, bs.x * bs.y * blocks << (m_fmt == GSTextureFX::FMT_32 ? 2 : 0)); m_renderer->m_perfmon.Put(GSPerfMon::Unswizzle, bs.x * bs.y * blocks << (m_fmt == FMT_32 ? 2 : 0));
Flush(m_write.count); Flush(m_write.count);
} }
@ -922,7 +921,7 @@ void GSTextureCache::Source::Flush(uint32 count)
GSLocalMemory::readTexture rtx = psm.rtx; GSLocalMemory::readTexture rtx = psm.rtx;
if(m_fmt == GSTextureFX::FMT_8) if(m_fmt == FMT_8)
{ {
pitch >>= 2; pitch >>= 2;
rtx = psm.rtxP; rtx = psm.rtxP;

View File

@ -28,6 +28,17 @@ class GSTextureCache
public: public:
enum {RenderTarget, DepthStencil}; enum {RenderTarget, DepthStencil};
enum TextureFormatType
{
FMT_32,
FMT_24,
FMT_16,
FMT_8H,
FMT_4HL,
FMT_4HH,
FMT_8,
};
class Surface : public GSAlignedClass<16> class Surface : public GSAlignedClass<16>
{ {
protected: protected:

View File

@ -20,22 +20,11 @@
*/ */
#include "stdafx.h" #include "stdafx.h"
#include "GSTextureFX10.h" #include "GSDevice10.h"
#include "resource.h" #include "resource.h"
GSTextureFX10::GSTextureFX10() bool GSDevice10::CreateTextureFX()
{ {
memset(&m_vs_cb_cache, 0, sizeof(m_vs_cb_cache));
memset(&m_ps_cb_cache, 0, sizeof(m_ps_cb_cache));
}
bool GSTextureFX10::Create(GSDevice* dev)
{
if(!__super::Create(dev))
{
return false;
}
HRESULT hr; HRESULT hr;
D3D10_BUFFER_DESC bd; D3D10_BUFFER_DESC bd;
@ -46,7 +35,7 @@ bool GSTextureFX10::Create(GSDevice* dev)
bd.Usage = D3D10_USAGE_DEFAULT; bd.Usage = D3D10_USAGE_DEFAULT;
bd.BindFlags = D3D10_BIND_CONSTANT_BUFFER; bd.BindFlags = D3D10_BIND_CONSTANT_BUFFER;
hr = (*(GSDevice10*)dev)->CreateBuffer(&bd, NULL, &m_vs_cb); hr = m_dev->CreateBuffer(&bd, NULL, &m_vs_cb);
if(FAILED(hr)) return false; if(FAILED(hr)) return false;
@ -56,7 +45,7 @@ bool GSTextureFX10::Create(GSDevice* dev)
bd.Usage = D3D10_USAGE_DEFAULT; bd.Usage = D3D10_USAGE_DEFAULT;
bd.BindFlags = D3D10_BIND_CONSTANT_BUFFER; bd.BindFlags = D3D10_BIND_CONSTANT_BUFFER;
hr = (*(GSDevice10*)dev)->CreateBuffer(&bd, NULL, &m_ps_cb); hr = m_dev->CreateBuffer(&bd, NULL, &m_ps_cb);
if(FAILED(hr)) return false; if(FAILED(hr)) return false;
@ -72,7 +61,7 @@ bool GSTextureFX10::Create(GSDevice* dev)
sd.MaxAnisotropy = 16; sd.MaxAnisotropy = 16;
sd.ComparisonFunc = D3D10_COMPARISON_NEVER; sd.ComparisonFunc = D3D10_COMPARISON_NEVER;
hr = (*(GSDevice10*)dev)->CreateSamplerState(&sd, &m_palette_ss); hr = m_dev->CreateSamplerState(&sd, &m_palette_ss);
if(FAILED(hr)) return false; if(FAILED(hr)) return false;
@ -82,25 +71,19 @@ bool GSTextureFX10::Create(GSDevice* dev)
VSConstantBuffer cb; VSConstantBuffer cb;
SetupVS(sel, &cb); SetupVS(sel, &cb);
//
return true; return true;
} }
void GSTextureFX10::SetupIA(const void* vertices, int count, int prim) void GSDevice10::SetupIA(const void* vertices, int count, int prim)
{ {
GSDevice10* dev = (GSDevice10*)m_dev; IASetVertexBuffer(vertices, sizeof(GSVertexHW10), count);
IASetInputLayout(m_il);
dev->IASetVertexBuffer(vertices, sizeof(GSVertexHW10), count); IASetPrimitiveTopology((D3D10_PRIMITIVE_TOPOLOGY)prim);
dev->IASetInputLayout(m_il);
dev->IASetPrimitiveTopology((D3D10_PRIMITIVE_TOPOLOGY)prim);
} }
void GSTextureFX10::SetupVS(VSSelector sel, const VSConstantBuffer* cb) void GSDevice10::SetupVS(VSSelector sel, const VSConstantBuffer* cb)
{ {
GSDevice10* dev = (GSDevice10*)m_dev;
hash_map<uint32, CComPtr<ID3D10VertexShader> >::const_iterator i = m_vs.find(sel); hash_map<uint32, CComPtr<ID3D10VertexShader> >::const_iterator i = m_vs.find(sel);
if(i == m_vs.end()) if(i == m_vs.end())
@ -132,7 +115,7 @@ void GSTextureFX10::SetupVS(VSSelector sel, const VSConstantBuffer* cb)
CComPtr<ID3D10InputLayout> il; CComPtr<ID3D10InputLayout> il;
CComPtr<ID3D10VertexShader> vs; CComPtr<ID3D10VertexShader> vs;
dev->CompileShader(IDR_TFX_FX, "vs_main", macro, &vs, layout, countof(layout), &il); CompileShader(IDR_TFX_FX, "vs_main", macro, &vs, layout, countof(layout), &il);
if(m_il == NULL) if(m_il == NULL)
{ {
@ -146,16 +129,14 @@ void GSTextureFX10::SetupVS(VSSelector sel, const VSConstantBuffer* cb)
if(m_vs_cb_cache.Update(cb)) if(m_vs_cb_cache.Update(cb))
{ {
(*dev)->UpdateSubresource(m_vs_cb, 0, NULL, cb, 0, 0); m_dev->UpdateSubresource(m_vs_cb, 0, NULL, cb, 0, 0);
} }
dev->VSSetShader(i->second, m_vs_cb); VSSetShader(i->second, m_vs_cb);
} }
void GSTextureFX10::SetupGS(GSSelector sel) void GSDevice10::SetupGS(GSSelector sel)
{ {
GSDevice10* dev = (GSDevice10*)m_dev;
ID3D10GeometryShader* gs = NULL; ID3D10GeometryShader* gs = NULL;
if(sel.prim > 0 && (sel.iip == 0 || sel.prim == 3)) // geometry shader works in every case, but not needed if(sel.prim > 0 && (sel.iip == 0 || sel.prim == 3)) // geometry shader works in every case, but not needed
@ -180,19 +161,17 @@ void GSTextureFX10::SetupGS(GSSelector sel)
{NULL, NULL}, {NULL, NULL},
}; };
dev->CompileShader(IDR_TFX_FX, "gs_main", macro, &gs); CompileShader(IDR_TFX_FX, "gs_main", macro, &gs);
m_gs[sel] = gs; m_gs[sel] = gs;
} }
} }
dev->GSSetShader(gs); GSSetShader(gs);
} }
void GSTextureFX10::SetupPS(PSSelector sel, const PSConstantBuffer* cb, PSSamplerSelector ssel) void GSDevice10::SetupPS(PSSelector sel, const PSConstantBuffer* cb, PSSamplerSelector ssel)
{ {
GSDevice10* dev = (GSDevice10*)m_dev;
hash_map<uint32, CComPtr<ID3D10PixelShader> >::const_iterator i = m_ps.find(sel); hash_map<uint32, CComPtr<ID3D10PixelShader> >::const_iterator i = m_ps.find(sel);
if(i == m_ps.end()) if(i == m_ps.end())
@ -233,7 +212,7 @@ void GSTextureFX10::SetupPS(PSSelector sel, const PSConstantBuffer* cb, PSSample
CComPtr<ID3D10PixelShader> ps; CComPtr<ID3D10PixelShader> ps;
dev->CompileShader(IDR_TFX_FX, "ps_main", macro, &ps); CompileShader(IDR_TFX_FX, "ps_main", macro, &ps);
m_ps[sel] = ps; m_ps[sel] = ps;
@ -242,10 +221,10 @@ void GSTextureFX10::SetupPS(PSSelector sel, const PSConstantBuffer* cb, PSSample
if(m_ps_cb_cache.Update(cb)) if(m_ps_cb_cache.Update(cb))
{ {
(*dev)->UpdateSubresource(m_ps_cb, 0, NULL, cb, 0, 0); m_dev->UpdateSubresource(m_ps_cb, 0, NULL, cb, 0, 0);
} }
dev->PSSetShader(i->second, m_ps_cb); PSSetShader(i->second, m_ps_cb);
ID3D10SamplerState* ss0 = NULL; ID3D10SamplerState* ss0 = NULL;
ID3D10SamplerState* ss1 = NULL; ID3D10SamplerState* ss1 = NULL;
@ -279,7 +258,7 @@ void GSTextureFX10::SetupPS(PSSelector sel, const PSConstantBuffer* cb, PSSample
sd.MaxAnisotropy = 16; sd.MaxAnisotropy = 16;
sd.ComparisonFunc = D3D10_COMPARISON_NEVER; sd.ComparisonFunc = D3D10_COMPARISON_NEVER;
(*dev)->CreateSamplerState(&sd, &ss0); m_dev->CreateSamplerState(&sd, &ss0);
m_ps_ss[ssel] = ss0; m_ps_ss[ssel] = ss0;
} }
@ -290,12 +269,11 @@ void GSTextureFX10::SetupPS(PSSelector sel, const PSConstantBuffer* cb, PSSample
} }
} }
dev->PSSetSamplerState(ss0, ss1); PSSetSamplerState(ss0, ss1);
} }
void GSTextureFX10::SetupOM(OMDepthStencilSelector dssel, OMBlendSelector bsel, uint8 afix) void GSDevice10::SetupOM(OMDepthStencilSelector dssel, OMBlendSelector bsel, uint8 afix)
{ {
GSDevice10* dev = (GSDevice10*)m_dev;
/* /*
hash_map<uint32, CComPtr<ID3D10DepthStencilState> >::const_iterator i = m_om_dss.find(dssel); hash_map<uint32, CComPtr<ID3D10DepthStencilState> >::const_iterator i = m_om_dss.find(dssel);
@ -342,18 +320,18 @@ void GSTextureFX10::SetupOM(OMDepthStencilSelector dssel, OMBlendSelector bsel,
/* /*
CComPtr<ID3D10DepthStencilState> dss; CComPtr<ID3D10DepthStencilState> dss;
(*dev)->CreateDepthStencilState(&dsd, &dss); m_dev->CreateDepthStencilState(&dsd, &dss);
m_om_dss[dssel] = dss; m_om_dss[dssel] = dss;
i = m_om_dss.find(dssel); i = m_om_dss.find(dssel);
*/ */
(*dev)->CreateDepthStencilState(&dsd, &om_dss); m_dev->CreateDepthStencilState(&dsd, &om_dss);
} }
// dev->OMSetDepthStencilState(i->second, 1); // OMSetDepthStencilState(i->second, 1);
dev->OMSetDepthStencilState(om_dss, 1); OMSetDepthStencilState(om_dss, 1);
hash_map<uint32, CComPtr<ID3D10BlendState> >::const_iterator j = m_om_bs.find(bsel); hash_map<uint32, CComPtr<ID3D10BlendState> >::const_iterator j = m_om_bs.find(bsel);
@ -487,12 +465,12 @@ void GSTextureFX10::SetupOM(OMDepthStencilSelector dssel, OMBlendSelector bsel,
CComPtr<ID3D10BlendState> bs; CComPtr<ID3D10BlendState> bs;
(*dev)->CreateBlendState(&bd, &bs); m_dev->CreateBlendState(&bd, &bs);
m_om_bs[bsel] = bs; m_om_bs[bsel] = bs;
j = m_om_bs.find(bsel); j = m_om_bs.find(bsel);
} }
dev->OMSetBlendState(j->second, (float)(int)afix / 0x80); OMSetBlendState(j->second, (float)(int)afix / 0x80);
} }

View File

@ -1,54 +0,0 @@
/*
* Copyright (C) 2007-2009 Gabest
* http://www.gabest.org
*
* This Program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2, or (at your option)
* any later version.
*
* This Program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with GNU Make; see the file COPYING. If not, write to
* the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
* http://www.gnu.org/copyleft/gpl.html
*
*/
#pragma once
#include "GSTextureFX.h"
#include "GSDevice10.h"
class GSTextureFX10 : public GSTextureFX
{
CComPtr<ID3D10InputLayout> m_il;
hash_map<uint32, CComPtr<ID3D10VertexShader> > m_vs;
CComPtr<ID3D10Buffer> m_vs_cb;
hash_map<uint32, CComPtr<ID3D10GeometryShader> > m_gs;
hash_map<uint32, CComPtr<ID3D10PixelShader> > m_ps;
CComPtr<ID3D10Buffer> m_ps_cb;
hash_map<uint32, CComPtr<ID3D10SamplerState> > m_ps_ss;
CComPtr<ID3D10SamplerState> m_palette_ss;
// hash_map<uint32, CComPtr<ID3D10DepthStencilState> > m_om_dss;
CComPtr<ID3D10DepthStencilState> m_om_dss[32];
hash_map<uint32, CComPtr<ID3D10BlendState> > m_om_bs;
VSConstantBuffer m_vs_cb_cache;
PSConstantBuffer m_ps_cb_cache;
public:
GSTextureFX10();
bool Create(GSDevice* dev);
void SetupIA(const void* vertices, int count, int prim);
void SetupVS(VSSelector sel, const VSConstantBuffer* cb);
void SetupGS(GSSelector sel);
void SetupPS(PSSelector sel, const PSConstantBuffer* cb, PSSamplerSelector ssel);
void SetupOM(OMDepthStencilSelector dssel, OMBlendSelector bsel, uint8 afix);
};

View File

@ -20,22 +20,11 @@
*/ */
#include "stdafx.h" #include "stdafx.h"
#include "GSTextureFX11.h" #include "GSDevice11.h"
#include "resource.h" #include "resource.h"
GSTextureFX11::GSTextureFX11() bool GSDevice11::CreateTextureFX()
{ {
memset(&m_vs_cb_cache, 0, sizeof(m_vs_cb_cache));
memset(&m_ps_cb_cache, 0, sizeof(m_ps_cb_cache));
}
bool GSTextureFX11::Create(GSDevice* dev)
{
if(!__super::Create(dev))
{
return false;
}
HRESULT hr; HRESULT hr;
D3D11_BUFFER_DESC bd; D3D11_BUFFER_DESC bd;
@ -46,7 +35,7 @@ bool GSTextureFX11::Create(GSDevice* dev)
bd.Usage = D3D11_USAGE_DEFAULT; bd.Usage = D3D11_USAGE_DEFAULT;
bd.BindFlags = D3D11_BIND_CONSTANT_BUFFER; bd.BindFlags = D3D11_BIND_CONSTANT_BUFFER;
hr = (*(GSDevice11*)dev)->CreateBuffer(&bd, NULL, &m_vs_cb); hr = m_dev->CreateBuffer(&bd, NULL, &m_vs_cb);
if(FAILED(hr)) return false; if(FAILED(hr)) return false;
@ -56,7 +45,7 @@ bool GSTextureFX11::Create(GSDevice* dev)
bd.Usage = D3D11_USAGE_DEFAULT; bd.Usage = D3D11_USAGE_DEFAULT;
bd.BindFlags = D3D11_BIND_CONSTANT_BUFFER; bd.BindFlags = D3D11_BIND_CONSTANT_BUFFER;
hr = (*(GSDevice11*)dev)->CreateBuffer(&bd, NULL, &m_ps_cb); hr = m_dev->CreateBuffer(&bd, NULL, &m_ps_cb);
if(FAILED(hr)) return false; if(FAILED(hr)) return false;
@ -72,7 +61,7 @@ bool GSTextureFX11::Create(GSDevice* dev)
sd.MaxAnisotropy = 16; sd.MaxAnisotropy = 16;
sd.ComparisonFunc = D3D11_COMPARISON_NEVER; sd.ComparisonFunc = D3D11_COMPARISON_NEVER;
hr = (*(GSDevice11*)dev)->CreateSamplerState(&sd, &m_palette_ss); hr = m_dev->CreateSamplerState(&sd, &m_palette_ss);
if(FAILED(hr)) return false; if(FAILED(hr)) return false;
@ -88,19 +77,15 @@ bool GSTextureFX11::Create(GSDevice* dev)
return true; return true;
} }
void GSTextureFX11::SetupIA(const void* vertices, int count, int prim) void GSDevice11::SetupIA(const void* vertices, int count, int prim)
{ {
GSDevice11* dev = (GSDevice11*)m_dev; IASetVertexBuffer(vertices, sizeof(GSVertexHW11), count);
IASetInputLayout(m_il);
dev->IASetVertexBuffer(vertices, sizeof(GSVertexHW11), count); IASetPrimitiveTopology((D3D11_PRIMITIVE_TOPOLOGY)prim);
dev->IASetInputLayout(m_il);
dev->IASetPrimitiveTopology((D3D11_PRIMITIVE_TOPOLOGY)prim);
} }
void GSTextureFX11::SetupVS(VSSelector sel, const VSConstantBuffer* cb) void GSDevice11::SetupVS(VSSelector sel, const VSConstantBuffer* cb)
{ {
GSDevice11* dev = (GSDevice11*)m_dev;
hash_map<uint32, CComPtr<ID3D11VertexShader> >::const_iterator i = m_vs.find(sel); hash_map<uint32, CComPtr<ID3D11VertexShader> >::const_iterator i = m_vs.find(sel);
if(i == m_vs.end()) if(i == m_vs.end())
@ -132,7 +117,7 @@ void GSTextureFX11::SetupVS(VSSelector sel, const VSConstantBuffer* cb)
CComPtr<ID3D11InputLayout> il; CComPtr<ID3D11InputLayout> il;
CComPtr<ID3D11VertexShader> vs; CComPtr<ID3D11VertexShader> vs;
dev->CompileShader(IDR_TFX_FX, "vs_main", macro, &vs, layout, countof(layout), &il); CompileShader(IDR_TFX_FX, "vs_main", macro, &vs, layout, countof(layout), &il);
if(m_il == NULL) if(m_il == NULL)
{ {
@ -146,18 +131,16 @@ void GSTextureFX11::SetupVS(VSSelector sel, const VSConstantBuffer* cb)
if(m_vs_cb_cache.Update(cb)) if(m_vs_cb_cache.Update(cb))
{ {
ID3D11DeviceContext* ctx = *dev; ID3D11DeviceContext* ctx = m_ctx;
ctx->UpdateSubresource(m_vs_cb, 0, NULL, cb, 0, 0); ctx->UpdateSubresource(m_vs_cb, 0, NULL, cb, 0, 0);
} }
dev->VSSetShader(i->second, m_vs_cb); VSSetShader(i->second, m_vs_cb);
} }
void GSTextureFX11::SetupGS(GSSelector sel) void GSDevice11::SetupGS(GSSelector sel)
{ {
GSDevice11* dev = (GSDevice11*)m_dev;
ID3D11GeometryShader* gs = NULL; ID3D11GeometryShader* gs = NULL;
if(sel.prim > 0 && (sel.iip == 0 || sel.prim == 3)) // geometry shader works in every case, but not needed if(sel.prim > 0 && (sel.iip == 0 || sel.prim == 3)) // geometry shader works in every case, but not needed
@ -182,19 +165,17 @@ void GSTextureFX11::SetupGS(GSSelector sel)
{NULL, NULL}, {NULL, NULL},
}; };
dev->CompileShader(IDR_TFX_FX, "gs_main", macro, &gs); CompileShader(IDR_TFX_FX, "gs_main", macro, &gs);
m_gs[sel] = gs; m_gs[sel] = gs;
} }
} }
dev->GSSetShader(gs); GSSetShader(gs);
} }
void GSTextureFX11::SetupPS(PSSelector sel, const PSConstantBuffer* cb, PSSamplerSelector ssel) void GSDevice11::SetupPS(PSSelector sel, const PSConstantBuffer* cb, PSSamplerSelector ssel)
{ {
GSDevice11* dev = (GSDevice11*)m_dev;
hash_map<uint32, CComPtr<ID3D11PixelShader> >::const_iterator i = m_ps.find(sel); hash_map<uint32, CComPtr<ID3D11PixelShader> >::const_iterator i = m_ps.find(sel);
if(i == m_ps.end()) if(i == m_ps.end())
@ -235,7 +216,7 @@ void GSTextureFX11::SetupPS(PSSelector sel, const PSConstantBuffer* cb, PSSample
CComPtr<ID3D11PixelShader> ps; CComPtr<ID3D11PixelShader> ps;
dev->CompileShader(IDR_TFX_FX, "ps_main", macro, &ps); CompileShader(IDR_TFX_FX, "ps_main", macro, &ps);
m_ps[sel] = ps; m_ps[sel] = ps;
@ -244,12 +225,12 @@ void GSTextureFX11::SetupPS(PSSelector sel, const PSConstantBuffer* cb, PSSample
if(m_ps_cb_cache.Update(cb)) if(m_ps_cb_cache.Update(cb))
{ {
ID3D11DeviceContext* ctx = *dev; ID3D11DeviceContext* ctx = m_ctx;
ctx->UpdateSubresource(m_ps_cb, 0, NULL, cb, 0, 0); ctx->UpdateSubresource(m_ps_cb, 0, NULL, cb, 0, 0);
} }
dev->PSSetShader(i->second, m_ps_cb); PSSetShader(i->second, m_ps_cb);
ID3D11SamplerState* ss0 = NULL; ID3D11SamplerState* ss0 = NULL;
ID3D11SamplerState* ss1 = NULL; ID3D11SamplerState* ss1 = NULL;
@ -283,7 +264,7 @@ void GSTextureFX11::SetupPS(PSSelector sel, const PSConstantBuffer* cb, PSSample
sd.MaxAnisotropy = 16; sd.MaxAnisotropy = 16;
sd.ComparisonFunc = D3D11_COMPARISON_NEVER; sd.ComparisonFunc = D3D11_COMPARISON_NEVER;
(*dev)->CreateSamplerState(&sd, &ss0); m_dev->CreateSamplerState(&sd, &ss0);
m_ps_ss[ssel] = ss0; m_ps_ss[ssel] = ss0;
} }
@ -294,13 +275,11 @@ void GSTextureFX11::SetupPS(PSSelector sel, const PSConstantBuffer* cb, PSSample
} }
} }
dev->PSSetSamplerState(ss0, ss1); PSSetSamplerState(ss0, ss1);
} }
void GSTextureFX11::SetupOM(OMDepthStencilSelector dssel, OMBlendSelector bsel, uint8 afix) void GSDevice11::SetupOM(OMDepthStencilSelector dssel, OMBlendSelector bsel, uint8 afix)
{ {
GSDevice11* dev = (GSDevice11*)m_dev;
hash_map<uint32, CComPtr<ID3D11DepthStencilState> >::const_iterator i = m_om_dss.find(dssel); hash_map<uint32, CComPtr<ID3D11DepthStencilState> >::const_iterator i = m_om_dss.find(dssel);
if(i == m_om_dss.end()) if(i == m_om_dss.end())
@ -341,14 +320,14 @@ void GSTextureFX11::SetupOM(OMDepthStencilSelector dssel, OMBlendSelector bsel,
CComPtr<ID3D11DepthStencilState> dss; CComPtr<ID3D11DepthStencilState> dss;
(*dev)->CreateDepthStencilState(&dsd, &dss); m_dev->CreateDepthStencilState(&dsd, &dss);
m_om_dss[dssel] = dss; m_om_dss[dssel] = dss;
i = m_om_dss.find(dssel); i = m_om_dss.find(dssel);
} }
dev->OMSetDepthStencilState(i->second, 1); OMSetDepthStencilState(i->second, 1);
hash_map<uint32, CComPtr<ID3D11BlendState> >::const_iterator j = m_om_bs.find(bsel); hash_map<uint32, CComPtr<ID3D11BlendState> >::const_iterator j = m_om_bs.find(bsel);
@ -482,12 +461,12 @@ void GSTextureFX11::SetupOM(OMDepthStencilSelector dssel, OMBlendSelector bsel,
CComPtr<ID3D11BlendState> bs; CComPtr<ID3D11BlendState> bs;
(*dev)->CreateBlendState(&bd, &bs); m_dev->CreateBlendState(&bd, &bs);
m_om_bs[bsel] = bs; m_om_bs[bsel] = bs;
j = m_om_bs.find(bsel); j = m_om_bs.find(bsel);
} }
dev->OMSetBlendState(j->second, (float)(int)afix / 0x80); OMSetBlendState(j->second, (float)(int)afix / 0x80);
} }

View File

@ -1,53 +0,0 @@
/*
* Copyright (C) 2007-2009 Gabest
* http://www.gabest.org
*
* This Program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2, or (at your option)
* any later version.
*
* This Program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with GNU Make; see the file COPYING. If not, write to
* the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
* http://www.gnu.org/copyleft/gpl.html
*
*/
#pragma once
#include "GSTextureFX.h"
#include "GSDevice11.h"
class GSTextureFX11 : public GSTextureFX
{
CComPtr<ID3D11InputLayout> m_il;
hash_map<uint32, CComPtr<ID3D11VertexShader> > m_vs;
CComPtr<ID3D11Buffer> m_vs_cb;
hash_map<uint32, CComPtr<ID3D11GeometryShader> > m_gs;
hash_map<uint32, CComPtr<ID3D11PixelShader> > m_ps;
CComPtr<ID3D11Buffer> m_ps_cb;
hash_map<uint32, CComPtr<ID3D11SamplerState> > m_ps_ss;
CComPtr<ID3D11SamplerState> m_palette_ss;
hash_map<uint32, CComPtr<ID3D11DepthStencilState> > m_om_dss;
hash_map<uint32, CComPtr<ID3D11BlendState> > m_om_bs;
VSConstantBuffer m_vs_cb_cache;
PSConstantBuffer m_ps_cb_cache;
public:
GSTextureFX11();
bool Create(GSDevice* dev);
void SetupIA(const void* vertices, int count, int prim);
void SetupVS(VSSelector sel, const VSConstantBuffer* cb);
void SetupGS(GSSelector sel);
void SetupPS(PSSelector sel, const PSConstantBuffer* cb, PSSamplerSelector ssel);
void SetupOM(OMDepthStencilSelector dssel, OMBlendSelector bsel, uint8 afix);
};

View File

@ -20,38 +20,11 @@
*/ */
#include "stdafx.h" #include "stdafx.h"
#include "GSTextureFX9.h" #include "GSDevice9.h"
#include "resource.h" #include "resource.h"
GSTextureFX9::GSTextureFX9()
{
}
GSTextureFX9::~GSTextureFX9() GSTexture* GSDevice9::CreateMskFix(uint32 size, uint32 msk, uint32 fix)
{
for_each(m_mskfix.begin(), m_mskfix.end(), delete_second());
}
bool GSTextureFX9::Create(GSDevice* dev)
{
if(!__super::Create(dev))
{
return false;
}
// create layout
VSSelector sel;
VSConstantBuffer cb;
SetupVS(sel, &cb);
//
return true;
}
GSTexture* GSTextureFX9::CreateMskFix(uint32 size, uint32 msk, uint32 fix)
{ {
GSTexture* t = NULL; GSTexture* t = NULL;
@ -65,7 +38,7 @@ GSTexture* GSTextureFX9::CreateMskFix(uint32 size, uint32 msk, uint32 fix)
} }
else else
{ {
t = m_dev->CreateTexture(size, 1, D3DFMT_R32F); t = CreateTexture(size, 1, D3DFMT_R32F);
if(t) if(t)
{ {
@ -88,20 +61,16 @@ GSTexture* GSTextureFX9::CreateMskFix(uint32 size, uint32 msk, uint32 fix)
return t; return t;
} }
void GSTextureFX9::SetupIA(const void* vertices, int count, int prim) void GSDevice9::SetupIA(const void* vertices, int count, int prim)
{ {
GSDevice9* dev = (GSDevice9*)m_dev; IASetVertexBuffer(vertices, sizeof(GSVertexHW9), count);
IASetInputLayout(m_il);
dev->IASetVertexBuffer(vertices, sizeof(GSVertexHW9), count); IASetPrimitiveTopology((D3DPRIMITIVETYPE)prim);
dev->IASetInputLayout(m_il);
dev->IASetPrimitiveTopology((D3DPRIMITIVETYPE)prim);
} }
void GSTextureFX9::SetupVS(VSSelector sel, const VSConstantBuffer* cb) void GSDevice9::SetupVS(VSSelector sel, const VSConstantBuffer* cb)
{ {
GSDevice9* dev = (GSDevice9*)m_dev; hash_map< uint32, CComPtr<IDirect3DVertexShader9> >::const_iterator i = m_vs.find(sel);
hash_map<uint32, CComPtr<IDirect3DVertexShader9> >::const_iterator i = m_vs.find(sel);
if(i == m_vs.end()) if(i == m_vs.end())
{ {
@ -133,7 +102,7 @@ void GSTextureFX9::SetupVS(VSSelector sel, const VSConstantBuffer* cb)
CComPtr<IDirect3DVertexDeclaration9> il; CComPtr<IDirect3DVertexDeclaration9> il;
CComPtr<IDirect3DVertexShader9> vs; CComPtr<IDirect3DVertexShader9> vs;
dev->CompileShader(IDR_TFX_FX, "vs_main", macro, &vs, layout, countof(layout), &il); CompileShader(IDR_TFX_FX, "vs_main", macro, &vs, layout, countof(layout), &il);
if(m_il == NULL) if(m_il == NULL)
{ {
@ -145,13 +114,11 @@ void GSTextureFX9::SetupVS(VSSelector sel, const VSConstantBuffer* cb)
i = m_vs.find(sel); i = m_vs.find(sel);
} }
dev->VSSetShader(i->second, (const float*)cb, sizeof(*cb) / sizeof(GSVector4)); VSSetShader(i->second, (const float*)cb, sizeof(*cb) / sizeof(GSVector4));
} }
void GSTextureFX9::SetupPS(PSSelector sel, const PSConstantBuffer* cb, PSSamplerSelector ssel) void GSDevice9::SetupPS(PSSelector sel, const PSConstantBuffer* cb, PSSamplerSelector ssel)
{ {
GSDevice9* dev = (GSDevice9*)m_dev;
if(cb->WH.z > 0 && cb->WH.w > 0 && (sel.wms == 3 || sel.wmt == 3)) if(cb->WH.z > 0 && cb->WH.w > 0 && (sel.wms == 3 || sel.wmt == 3))
{ {
GSVector4i size(cb->WH); GSVector4i size(cb->WH);
@ -160,7 +127,7 @@ void GSTextureFX9::SetupPS(PSSelector sel, const PSConstantBuffer* cb, PSSampler
{ {
if(GSTexture* t = CreateMskFix(size.z, cb->MskFix.x, cb->MskFix.z)) if(GSTexture* t = CreateMskFix(size.z, cb->MskFix.x, cb->MskFix.z))
{ {
(*dev)->SetTexture(2, *(GSTexture9*)t); m_dev->SetTexture(2, *(GSTexture9*)t);
} }
} }
@ -168,7 +135,7 @@ void GSTextureFX9::SetupPS(PSSelector sel, const PSConstantBuffer* cb, PSSampler
{ {
if(GSTexture* t = CreateMskFix(size.w, cb->MskFix.y, cb->MskFix.w)) if(GSTexture* t = CreateMskFix(size.w, cb->MskFix.y, cb->MskFix.w))
{ {
(*dev)->SetTexture(3, *(GSTexture9*)t); m_dev->SetTexture(3, *(GSTexture9*)t);
} }
} }
} }
@ -211,14 +178,14 @@ void GSTextureFX9::SetupPS(PSSelector sel, const PSConstantBuffer* cb, PSSampler
CComPtr<IDirect3DPixelShader9> ps; CComPtr<IDirect3DPixelShader9> ps;
dev->CompileShader(IDR_TFX_FX, "ps_main", macro, &ps); CompileShader(IDR_TFX_FX, "ps_main", macro, &ps);
m_ps[sel] = ps; m_ps[sel] = ps;
i = m_ps.find(sel); i = m_ps.find(sel);
} }
dev->PSSetShader(i->second, (const float*)cb, sizeof(*cb) / sizeof(GSVector4)); PSSetShader(i->second, (const float*)cb, sizeof(*cb) / sizeof(GSVector4));
Direct3DSamplerState9* ss = NULL; Direct3DSamplerState9* ss = NULL;
@ -253,13 +220,11 @@ void GSTextureFX9::SetupPS(PSSelector sel, const PSConstantBuffer* cb, PSSampler
} }
} }
dev->PSSetSamplerState(ss); PSSetSamplerState(ss);
} }
void GSTextureFX9::SetupOM(OMDepthStencilSelector dssel, OMBlendSelector bsel, uint8 afix) void GSDevice9::SetupOM(OMDepthStencilSelector dssel, OMBlendSelector bsel, uint8 afix)
{ {
GSDevice9* dev = (GSDevice9*)m_dev;
Direct3DDepthStencilState9* dss = NULL; Direct3DDepthStencilState9* dss = NULL;
hash_map<uint32, Direct3DDepthStencilState9*>::const_iterator i = m_om_dss.find(dssel); hash_map<uint32, Direct3DDepthStencilState9*>::const_iterator i = m_om_dss.find(dssel);
@ -302,7 +267,7 @@ void GSTextureFX9::SetupOM(OMDepthStencilSelector dssel, OMBlendSelector bsel, u
i = m_om_dss.find(dssel); i = m_om_dss.find(dssel);
} }
dev->OMSetDepthStencilState(i->second); OMSetDepthStencilState(i->second);
hash_map<uint32, Direct3DBlendState9*>::const_iterator j = m_om_bs.find(bsel); hash_map<uint32, Direct3DBlendState9*>::const_iterator j = m_om_bs.find(bsel);
@ -439,5 +404,5 @@ void GSTextureFX9::SetupOM(OMDepthStencilSelector dssel, OMBlendSelector bsel, u
j = m_om_bs.find(bsel); j = m_om_bs.find(bsel);
} }
dev->OMSetBlendState(j->second, afix >= 0x80 ? 0xffffff : 0x020202 * afix); OMSetBlendState(j->second, afix >= 0x80 ? 0xffffff : 0x020202 * afix);
} }

View File

@ -1,51 +0,0 @@
/*
* Copyright (C) 2007-2009 Gabest
* http://www.gabest.org
*
* This Program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2, or (at your option)
* any later version.
*
* This Program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with GNU Make; see the file COPYING. If not, write to
* the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
* http://www.gnu.org/copyleft/gpl.html
*
*/
#pragma once
#include "GSTextureFX.h"
#include "GSDevice9.h"
class GSTextureFX9 : public GSTextureFX
{
CComPtr<IDirect3DVertexDeclaration9> m_il;
hash_map<uint32, CComPtr<IDirect3DVertexShader9> > m_vs;
D3DXHANDLE m_vs_params;
hash_map<uint32, CComPtr<IDirect3DPixelShader9> > m_ps;
hash_map<uint32, Direct3DSamplerState9* > m_ps_ss;
hash_map<uint32, Direct3DDepthStencilState9* > m_om_dss;
hash_map<uint32, Direct3DBlendState9* > m_om_bs;
hash_map<uint32, GSTexture*> m_mskfix;
GSTexture* CreateMskFix(uint32 size, uint32 msk, uint32 fix);
public:
GSTextureFX9();
virtual ~GSTextureFX9();
bool Create(GSDevice* dev);
void SetupIA(const void* vertices, int count, int prim);
void SetupVS(VSSelector sel, const VSConstantBuffer* cb);
void SetupGS(GSSelector sel) {}
void SetupPS(PSSelector sel, const PSConstantBuffer* cb, PSSamplerSelector ssel);
void SetupOM(OMDepthStencilSelector dssel, OMBlendSelector bsel, uint8 afix);
};

View File

@ -25,6 +25,8 @@
GSWnd::GSWnd() GSWnd::GSWnd()
: m_hWnd(NULL) : m_hWnd(NULL)
, m_IsManaged(true)
, m_HasFrame(true)
{ {
} }
@ -66,7 +68,10 @@ LRESULT GSWnd::OnMessage(UINT message, WPARAM wParam, LPARAM lParam)
// DestroyWindow(m_hWnd); // DestroyWindow(m_hWnd);
return 0; return 0;
case WM_DESTROY: case WM_DESTROY:
PostQuitMessage(0); // This kills the emulator when GS is closed, which *really* isn't desired behavior,
// especially in STGS mode (worked in MTGS mode since it only quit the thread, but even
// that wasn't needed).
//PostQuitMessage(0);
return 0; return 0;
default: default:
break; break;
@ -77,6 +82,8 @@ LRESULT GSWnd::OnMessage(UINT message, WPARAM wParam, LPARAM lParam)
bool GSWnd::Create(const string& title, int w, int h) bool GSWnd::Create(const string& title, int w, int h)
{ {
if(m_hWnd) return true;
WNDCLASS wc; WNDCLASS wc;
memset(&wc, 0, sizeof(wc)); memset(&wc, 0, sizeof(wc));
@ -134,15 +141,28 @@ bool GSWnd::Create(const string& title, int w, int h)
return true; return true;
} }
bool GSWnd::Attach(HWND hWnd) bool GSWnd::Attach(HWND hWnd, bool isManaged)
{ {
// TODO: subclass // TODO: subclass
m_hWnd = hWnd; m_hWnd = hWnd;
m_IsManaged = isManaged;
return true; return true;
} }
void GSWnd::Detach()
{
if(m_hWnd && m_IsManaged)
{
// close the window, since it's under GSdx care. It's not taking messages anyway, and
// that means its big, ugly, and in the way.
DestroyWindow(m_hWnd);
}
m_hWnd = NULL;
m_IsManaged = true;
}
GSVector4i GSWnd::GetClientRect() GSVector4i GSWnd::GetClientRect()
{ {
GSVector4i r; GSVector4i r;
@ -152,13 +172,21 @@ GSVector4i GSWnd::GetClientRect()
return r; return r;
} }
void GSWnd::SetWindowText(const char* title) // Returns FALSE if the window has no title, or if th window title is under the strict
// management of the emulator.
bool GSWnd::SetWindowText(const char* title)
{ {
if( !m_IsManaged ) return false;
::SetWindowText(m_hWnd, title); ::SetWindowText(m_hWnd, title);
return m_HasFrame;
} }
void GSWnd::Show() void GSWnd::Show()
{ {
if( !m_IsManaged ) return;
//SetWindowPos(&wndTop, 0, 0, 0, 0, SWP_NOMOVE|SWP_NOSIZE); //SetWindowPos(&wndTop, 0, 0, 0, 0, SWP_NOMOVE|SWP_NOSIZE);
SetForegroundWindow(m_hWnd); SetForegroundWindow(m_hWnd);
@ -170,14 +198,20 @@ void GSWnd::Show()
void GSWnd::Hide() void GSWnd::Hide()
{ {
if( !m_IsManaged ) return;
ShowWindow(m_hWnd, SW_HIDE); ShowWindow(m_hWnd, SW_HIDE);
} }
void GSWnd::HideFrame() void GSWnd::HideFrame()
{ {
if( !m_IsManaged ) return;
SetWindowLong(m_hWnd, GWL_STYLE, GetWindowLong(m_hWnd, GWL_STYLE) & ~(WS_CAPTION|WS_THICKFRAME)); SetWindowLong(m_hWnd, GWL_STYLE, GetWindowLong(m_hWnd, GWL_STYLE) & ~(WS_CAPTION|WS_THICKFRAME));
SetWindowPos(m_hWnd, NULL, 0, 0, 0, 0, SWP_NOSIZE | SWP_NOMOVE | SWP_NOZORDER | SWP_NOACTIVATE); SetWindowPos(m_hWnd, NULL, 0, 0, 0, 0, SWP_NOSIZE | SWP_NOMOVE | SWP_NOZORDER | SWP_NOACTIVATE);
SetMenu(m_hWnd, NULL); SetMenu(m_hWnd, NULL);
m_HasFrame = false;
} }

View File

@ -26,6 +26,8 @@
class GSWnd class GSWnd
{ {
HWND m_hWnd; HWND m_hWnd;
bool m_IsManaged; // set true when we're attached to a 3rdparty window that's amanged by the emulator
bool m_HasFrame;
static LRESULT CALLBACK WndProc(HWND hWnd, UINT message, WPARAM wParam, LPARAM lParam); static LRESULT CALLBACK WndProc(HWND hWnd, UINT message, WPARAM wParam, LPARAM lParam);
virtual LRESULT OnMessage(UINT message, WPARAM wParam, LPARAM lParam); virtual LRESULT OnMessage(UINT message, WPARAM wParam, LPARAM lParam);
@ -35,13 +37,15 @@ public:
virtual ~GSWnd(); virtual ~GSWnd();
bool Create(const string& title, int w, int h); bool Create(const string& title, int w, int h);
bool Attach(HWND hWnd); bool Attach(HWND hWnd, bool isManaged=true);
void Detach();
bool IsManaged() const { return m_IsManaged; }
void* GetHandle() {return m_hWnd;} void* GetHandle() {return m_hWnd;}
GSVector4i GetClientRect(); GSVector4i GetClientRect();
void SetWindowText(const char* title); bool SetWindowText(const char* title);
void Show(); void Show();
void Hide(); void Hide();

View File

@ -11,7 +11,8 @@ EXPORTS
GSsetBaseMem GSsetBaseMem
GSinit GSinit
GSshutdown GSshutdown
GSopen GSopen
GSopen2
GSclose GSclose
GSreset GSreset
GSwriteCSR GSwriteCSR

View File

@ -22,7 +22,7 @@
<Configuration <Configuration
Name="Debug SSE2|Win32" Name="Debug SSE2|Win32"
ConfigurationType="2" ConfigurationType="2"
InheritedPropertySheets=".\vsprops\common.vsprops;.\vsprops\ProjectRootDir.vsprops;.\vsprops\debug.vsprops;.\vsprops\sse2.vsprops" InheritedPropertySheets=".\vsprops\common.vsprops;.\vsprops\ProjectRootDir.vsprops;.\vsprops\debug.vsprops;.\vsprops\sse2.vsprops;..\..\common\vsprops\3rdpartyDeps.vsprops"
UseOfMFC="0" UseOfMFC="0"
CharacterSet="2" CharacterSet="2"
> >
@ -57,6 +57,7 @@
<Tool <Tool
Name="VCLinkerTool" Name="VCLinkerTool"
OutputFile="$(OutDir)\$(ProjectName)-$(SSEtype)-dbg.dll" OutputFile="$(OutDir)\$(ProjectName)-$(SSEtype)-dbg.dll"
AdditionalLibraryDirectories="&quot;$(SvnRootDir)\deps\$(PlatformName)\Debug&quot;"
ModuleDefinitionFile=".\GSdx.def" ModuleDefinitionFile=".\GSdx.def"
TargetMachine="1" TargetMachine="1"
/> />
@ -85,7 +86,7 @@
<Configuration <Configuration
Name="Release SSE2|Win32" Name="Release SSE2|Win32"
ConfigurationType="2" ConfigurationType="2"
InheritedPropertySheets=".\vsprops\common.vsprops;.\vsprops\ProjectRootDir.vsprops;.\vsprops\release.vsprops;.\vsprops\sse2.vsprops" InheritedPropertySheets=".\vsprops\common.vsprops;.\vsprops\ProjectRootDir.vsprops;.\vsprops\release.vsprops;.\vsprops\sse2.vsprops;..\..\common\vsprops\3rdpartyDeps.vsprops"
UseOfMFC="0" UseOfMFC="0"
CharacterSet="2" CharacterSet="2"
WholeProgramOptimization="1" WholeProgramOptimization="1"
@ -120,6 +121,7 @@
/> />
<Tool <Tool
Name="VCLinkerTool" Name="VCLinkerTool"
AdditionalLibraryDirectories="&quot;$(SvnRootDir)\deps\$(PlatformName)\Release&quot;"
ModuleDefinitionFile=".\GSdx.def" ModuleDefinitionFile=".\GSdx.def"
TargetMachine="1" TargetMachine="1"
/> />
@ -148,7 +150,7 @@
<Configuration <Configuration
Name="Release SSSE3|Win32" Name="Release SSSE3|Win32"
ConfigurationType="2" ConfigurationType="2"
InheritedPropertySheets=".\vsprops\common.vsprops;.\vsprops\ProjectRootDir.vsprops;.\vsprops\release.vsprops;.\vsprops\ssse3.vsprops" InheritedPropertySheets=".\vsprops\common.vsprops;.\vsprops\ProjectRootDir.vsprops;.\vsprops\release.vsprops;.\vsprops\ssse3.vsprops;..\..\common\vsprops\3rdpartyDeps.vsprops"
UseOfMFC="0" UseOfMFC="0"
CharacterSet="2" CharacterSet="2"
WholeProgramOptimization="1" WholeProgramOptimization="1"
@ -183,6 +185,7 @@
/> />
<Tool <Tool
Name="VCLinkerTool" Name="VCLinkerTool"
AdditionalLibraryDirectories="&quot;$(SvnRootDir)\deps\$(PlatformName)\Release&quot;"
ModuleDefinitionFile=".\GSdx.def" ModuleDefinitionFile=".\GSdx.def"
TargetMachine="1" TargetMachine="1"
/> />
@ -211,7 +214,7 @@
<Configuration <Configuration
Name="Debug SSSE3|Win32" Name="Debug SSSE3|Win32"
ConfigurationType="2" ConfigurationType="2"
InheritedPropertySheets=".\vsprops\common.vsprops;.\vsprops\ProjectRootDir.vsprops;.\vsprops\debug.vsprops;.\vsprops\ssse3.vsprops" InheritedPropertySheets=".\vsprops\common.vsprops;.\vsprops\ProjectRootDir.vsprops;.\vsprops\debug.vsprops;.\vsprops\ssse3.vsprops;..\..\common\vsprops\3rdpartyDeps.vsprops"
UseOfMFC="0" UseOfMFC="0"
CharacterSet="2" CharacterSet="2"
> >
@ -246,6 +249,7 @@
<Tool <Tool
Name="VCLinkerTool" Name="VCLinkerTool"
OutputFile="$(OutDir)\$(ProjectName)-$(SSEtype)-dbg.dll" OutputFile="$(OutDir)\$(ProjectName)-$(SSEtype)-dbg.dll"
AdditionalLibraryDirectories="&quot;$(SvnRootDir)\deps\$(PlatformName)\Debug&quot;"
ModuleDefinitionFile=".\GSdx.def" ModuleDefinitionFile=".\GSdx.def"
TargetMachine="1" TargetMachine="1"
/> />
@ -274,7 +278,7 @@
<Configuration <Configuration
Name="Debug SSE4|Win32" Name="Debug SSE4|Win32"
ConfigurationType="2" ConfigurationType="2"
InheritedPropertySheets=".\vsprops\common.vsprops;.\vsprops\debug.vsprops;.\vsprops\ProjectRootDir.vsprops;.\vsprops\sse4.vsprops" InheritedPropertySheets=".\vsprops\common.vsprops;.\vsprops\debug.vsprops;.\vsprops\ProjectRootDir.vsprops;.\vsprops\sse4.vsprops;..\..\common\vsprops\3rdpartyDeps.vsprops"
UseOfMFC="0" UseOfMFC="0"
CharacterSet="2" CharacterSet="2"
> >
@ -309,6 +313,7 @@
<Tool <Tool
Name="VCLinkerTool" Name="VCLinkerTool"
OutputFile="$(OutDir)\$(ProjectName)-$(SSEtype)-dbg.dll" OutputFile="$(OutDir)\$(ProjectName)-$(SSEtype)-dbg.dll"
AdditionalLibraryDirectories="&quot;$(SvnRootDir)\deps\$(PlatformName)\Debug&quot;"
ModuleDefinitionFile=".\GSdx.def" ModuleDefinitionFile=".\GSdx.def"
TargetMachine="1" TargetMachine="1"
/> />
@ -337,7 +342,7 @@
<Configuration <Configuration
Name="Release SSE4|Win32" Name="Release SSE4|Win32"
ConfigurationType="2" ConfigurationType="2"
InheritedPropertySheets=".\vsprops\common.vsprops;.\vsprops\release.vsprops;.\vsprops\sse4.vsprops;.\vsprops\ProjectRootDir.vsprops" InheritedPropertySheets=".\vsprops\common.vsprops;.\vsprops\release.vsprops;.\vsprops\sse4.vsprops;.\vsprops\ProjectRootDir.vsprops;..\..\common\vsprops\3rdpartyDeps.vsprops"
UseOfMFC="0" UseOfMFC="0"
CharacterSet="2" CharacterSet="2"
WholeProgramOptimization="1" WholeProgramOptimization="1"
@ -372,6 +377,7 @@
/> />
<Tool <Tool
Name="VCLinkerTool" Name="VCLinkerTool"
AdditionalLibraryDirectories="&quot;$(SvnRootDir)\deps\$(PlatformName)\Release&quot;"
ModuleDefinitionFile=".\GSdx.def" ModuleDefinitionFile=".\GSdx.def"
TargetMachine="1" TargetMachine="1"
/> />
@ -432,6 +438,7 @@
/> />
<Tool <Tool
Name="VCLinkerTool" Name="VCLinkerTool"
AdditionalLibraryDirectories="&quot;$(SvnRootDir)\deps\$(PlatformName)\Debug&quot;"
/> />
<Tool <Tool
Name="VCALinkTool" Name="VCALinkTool"
@ -490,6 +497,7 @@
/> />
<Tool <Tool
Name="VCLinkerTool" Name="VCLinkerTool"
AdditionalLibraryDirectories="&quot;$(SvnRootDir)\deps\$(PlatformName)\Release&quot;"
/> />
<Tool <Tool
Name="VCALinkTool" Name="VCALinkTool"
@ -1197,10 +1205,6 @@
/> />
</FileConfiguration> </FileConfiguration>
</File> </File>
<File
RelativePath=".\GSdx.def"
>
</File>
<File <File
RelativePath=".\GSFunctionMap.cpp" RelativePath=".\GSFunctionMap.cpp"
> >
@ -1453,10 +1457,6 @@
/> />
</FileConfiguration> </FileConfiguration>
</File> </File>
<File
RelativePath=".\GSTextureFX.cpp"
>
</File>
<File <File
RelativePath=".\GSTextureFX10.cpp" RelativePath=".\GSTextureFX10.cpp"
> >
@ -1743,6 +1743,10 @@
RelativePath=".\GSDevice9.h" RelativePath=".\GSDevice9.h"
> >
</File> </File>
<File
RelativePath=".\GSDeviceDX.h"
>
</File>
<File <File
RelativePath=".\GSDeviceNull.h" RelativePath=".\GSDeviceNull.h"
> >
@ -1867,10 +1871,6 @@
RelativePath=".\GSTexture10.h" RelativePath=".\GSTexture10.h"
> >
</File> </File>
<File
RelativePath=".\GSTexture11.h"
>
</File>
<File <File
RelativePath=".\GSTexture7.h" RelativePath=".\GSTexture7.h"
> >
@ -1903,22 +1903,10 @@
RelativePath=".\GSTextureCacheSW.h" RelativePath=".\GSTextureCacheSW.h"
> >
</File> </File>
<File
RelativePath=".\GSTextureFX.h"
>
</File>
<File
RelativePath=".\GSTextureFX10.h"
>
</File>
<File <File
RelativePath=".\GSTextureFX11.h" RelativePath=".\GSTextureFX11.h"
> >
</File> </File>
<File
RelativePath=".\GSTextureFX9.h"
>
</File>
<File <File
RelativePath=".\GSTextureNull.h" RelativePath=".\GSTextureNull.h"
> >
@ -1977,6 +1965,10 @@
Filter="rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav" Filter="rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav"
UniqueIdentifier="{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}" UniqueIdentifier="{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}"
> >
<File
RelativePath=".\GSdx.def"
>
</File>
<File <File
RelativePath=".\GSdx.rc" RelativePath=".\GSdx.rc"
> >

View File

@ -9,7 +9,7 @@
<Tool <Tool
Name="VCCLCompilerTool" Name="VCCLCompilerTool"
EnableIntrinsicFunctions="true" EnableIntrinsicFunctions="true"
PreprocessorDefinitions="WIN32;_WINDOWS;_WIN32_WINNT=0x500" PreprocessorDefinitions="WIN32;_WINDOWS;_WIN32_WINNT=0x500;GLEW_STATIC"
FloatingPointModel="2" FloatingPointModel="2"
RuntimeTypeInfo="false" RuntimeTypeInfo="false"
WarningLevel="4" WarningLevel="4"
@ -18,10 +18,10 @@
/> />
<Tool <Tool
Name="VCLinkerTool" Name="VCLinkerTool"
AdditionalDependencies="JITProfiling.lib d3d11_beta.lib d3dx11.lib d3d10_1.lib d3dx10.lib d3d9.lib d3dx9.lib ddraw.lib dxguid.lib winmm.lib strmiids.lib xinput.lib cg.lib cgGL.lib glut32.lib glew32.lib" AdditionalDependencies="JITProfiling.lib d3d11.lib d3dx11.lib d3d10_1.lib d3dx10.lib d3d9.lib d3dx9.lib ddraw.lib dxguid.lib winmm.lib strmiids.lib xinput.lib cg.lib cgGL.lib glut32.lib glew_static.lib"
OutputFile="$(OutDir)\$(ProjectName)-$(SSEtype).dll" OutputFile="$(OutDir)\$(ProjectName)-$(SSEtype).dll"
AdditionalLibraryDirectories="./vtune" AdditionalLibraryDirectories="./vtune"
DelayLoadDLLs="d3d9.dll;d3dx9_41.dll;d3d10.dll;d3d10_1.dll;d3dx10_41.dll;d3d11.dll;d3d11_beta.dll;d3dx11_41.dll;cg.dll;cgGL.dll;glut32.dll" DelayLoadDLLs="d3d9.dll;d3dx9_41.dll;d3d10.dll;d3d10_1.dll;d3dx10_41.dll;d3d11.dll;d3dx11_41.dll;cg.dll;cgGL.dll;glut32.dll"
GenerateDebugInformation="true" GenerateDebugInformation="true"
SubSystem="2" SubSystem="2"
RandomizedBaseAddress="1" RandomizedBaseAddress="1"