mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-08-21 17:59:50 +00:00
Eliminated the plugin interface. Merged DX9/DX11/OGL video plugins into Dolphin. It could still use a lot of cleanup. Lots of things are still named "plugin". Software renderer is temporarily disabled until it gets some namespaces. I only updated vs08/10, Linux/OSX builds are broken.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6996 8ced0084-cf51-0410-be5f-012b33b47a6e
This commit is contained in:
parent
ae7c64ec13
commit
fbaf965995
136 changed files with 1537 additions and 3412 deletions
|
@ -2,7 +2,7 @@
|
|||
<VisualStudioProject
|
||||
ProjectType="Visual C++"
|
||||
Version="9.00"
|
||||
Name="Plugin_VideoDX11"
|
||||
Name="VideoDX11"
|
||||
ProjectGUID="{21DBE606-2958-43AC-A14E-B6B798D56554}"
|
||||
RootNamespace="Plugin_VideoDX11"
|
||||
TargetFrameworkVersion="196613"
|
||||
|
@ -22,7 +22,7 @@
|
|||
Name="Release|Win32"
|
||||
OutputDirectory="$(PlatformName)\$(ConfigurationName)"
|
||||
IntermediateDirectory="$(PlatformName)\$(ConfigurationName)"
|
||||
ConfigurationType="2"
|
||||
ConfigurationType="4"
|
||||
InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC71.vsprops"
|
||||
UseOfMFC="0"
|
||||
ATLMinimizesCRunTimeLibraryUsage="false"
|
||||
|
@ -58,7 +58,7 @@
|
|||
FavorSizeOrSpeed="1"
|
||||
OmitFramePointers="false"
|
||||
WholeProgramOptimization="true"
|
||||
AdditionalIncludeDirectories="../../../Externals;../../PluginSpecs;../../Core/Common/Src;../../Core/VideoCommon/Src;../../Core/VideoUICommon/Src;..\..\..\Externals\wxWidgets\Include;..\..\..\Externals\wxWidgets\Include\msvc"
|
||||
AdditionalIncludeDirectories="../../../Externals;../../PluginSpecs;../../Core/Common/Src;../../Core/Core/Src;../../Core/VideoCommon/Src;../../Core/VideoUICommon/Src;..\..\..\Externals\wxWidgets\Include;..\..\..\Externals\wxWidgets\Include\msvc"
|
||||
PreprocessorDefinitions="_WIN32;WIN32;NDEBUG;_WINDOWS;_USRDLL;VIDEO_DIRECTX11_EXPORTS;_CRT_SECURE_NO_DEPRECATE;_SECURE_SCL=0"
|
||||
StringPooling="true"
|
||||
RuntimeLibrary="0"
|
||||
|
@ -89,26 +89,11 @@
|
|||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLinkerTool"
|
||||
AdditionalOptions=""..\..\core\common\win32\release\common.lib""
|
||||
AdditionalDependencies="odbc32.lib odbccp32.lib comctl32.lib dxguid.lib winmm.lib vfw32.lib wxbase28u.lib wxmsw28u_core.lib"
|
||||
OutputFile="..\..\..\Binary\Win32\Plugins\Plugin_VideoDX11.dll"
|
||||
LinkIncremental="1"
|
||||
SuppressStartupBanner="true"
|
||||
AdditionalLibraryDirectories="../../../Externals/Cg;"..\..\..\Externals\wxWidgets\lib\vc_lib\$(PlatformName)""
|
||||
GenerateManifest="false"
|
||||
ProgramDatabaseFile="$(PlatformName)\$(ConfigurationName)\$(TargetName).pdb"
|
||||
RandomizedBaseAddress="1"
|
||||
DataExecutionPrevention="0"
|
||||
ImportLibrary="$(PlatformName)\$(ConfigurationName)\$(TargetName).lib"
|
||||
TargetMachine="1"
|
||||
Name="VCLibrarianTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManifestTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
|
@ -118,9 +103,6 @@
|
|||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCAppVerifierTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
/>
|
||||
|
@ -129,7 +111,7 @@
|
|||
Name="Release|x64"
|
||||
OutputDirectory="$(PlatformName)\$(ConfigurationName)"
|
||||
IntermediateDirectory="$(PlatformName)\$(ConfigurationName)"
|
||||
ConfigurationType="2"
|
||||
ConfigurationType="4"
|
||||
InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC71.vsprops"
|
||||
UseOfMFC="0"
|
||||
ATLMinimizesCRunTimeLibraryUsage="false"
|
||||
|
@ -166,7 +148,7 @@
|
|||
FavorSizeOrSpeed="1"
|
||||
OmitFramePointers="false"
|
||||
WholeProgramOptimization="true"
|
||||
AdditionalIncludeDirectories="../../../Externals;../../PluginSpecs;../../Core/Common/Src;../../Core/VideoCommon/Src;../../Core/VideoUICommon/Src;..\..\..\Externals\wxWidgets\Include;..\..\..\Externals\wxWidgets\Include\msvc"
|
||||
AdditionalIncludeDirectories="../../../Externals;../../PluginSpecs;../../Core/Common/Src;../../Core/Core/Src;../../Core/VideoCommon/Src;../../Core/VideoUICommon/Src;..\..\..\Externals\wxWidgets\Include;..\..\..\Externals\wxWidgets\Include\msvc"
|
||||
PreprocessorDefinitions="WIN32;NDEBUG;_WINDOWS;_USRDLL;VIDEO_DIRECTX11_EXPORTS;_CRT_SECURE_NO_DEPRECATE;_SECURE_SCL=0"
|
||||
StringPooling="true"
|
||||
ExceptionHandling="1"
|
||||
|
@ -198,27 +180,11 @@
|
|||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLinkerTool"
|
||||
AdditionalDependencies="odbc32.lib odbccp32.lib comctl32.lib dxguid.lib winmm.lib vfw32.lib wxbase28u.lib wxmsw28u_core.lib"
|
||||
OutputFile="..\..\..\Binary\x64\Plugins\Plugin_VideoDX11.dll"
|
||||
LinkIncremental="1"
|
||||
SuppressStartupBanner="true"
|
||||
AdditionalLibraryDirectories="..\..\..\Externals\Cg64;"..\..\..\Externals\wxWidgets\lib\vc_lib\$(PlatformName)""
|
||||
GenerateManifest="false"
|
||||
GenerateDebugInformation="true"
|
||||
ProgramDatabaseFile="$(PlatformName)\$(ConfigurationName)\$(TargetName).pdb"
|
||||
SubSystem="2"
|
||||
RandomizedBaseAddress="1"
|
||||
DataExecutionPrevention="0"
|
||||
ImportLibrary="$(PlatformName)\$(ConfigurationName)\$(TargetName).lib"
|
||||
TargetMachine="17"
|
||||
Name="VCLibrarianTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManifestTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
|
@ -228,9 +194,6 @@
|
|||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCAppVerifierTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
/>
|
||||
|
@ -239,7 +202,7 @@
|
|||
Name="Debug|Win32"
|
||||
OutputDirectory="$(PlatformName)\$(ConfigurationName)"
|
||||
IntermediateDirectory="$(PlatformName)\$(ConfigurationName)"
|
||||
ConfigurationType="2"
|
||||
ConfigurationType="4"
|
||||
InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC71.vsprops"
|
||||
UseOfMFC="0"
|
||||
ATLMinimizesCRunTimeLibraryUsage="false"
|
||||
|
@ -269,7 +232,7 @@
|
|||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
Optimization="0"
|
||||
AdditionalIncludeDirectories="../../../Externals;../../PluginSpecs;../../Core/Common/Src;../../Core/VideoCommon/Src;../../Core/VideoUICommon/Src;..\..\..\Externals\wxWidgets\Include;..\..\..\Externals\wxWidgets\Include\msvc"
|
||||
AdditionalIncludeDirectories="../../../Externals;../../PluginSpecs;../../Core/Common/Src;../../Core/Core/Src;../../Core/VideoCommon/Src;../../Core/VideoUICommon/Src;..\..\..\Externals\wxWidgets\Include;..\..\..\Externals\wxWidgets\Include\msvc"
|
||||
PreprocessorDefinitions="_WIN32;WIN32;_DEBUG;_WINDOWS;_USRDLL;VIDEO_DIRECTX11_EXPORTS;_CRT_SECURE_NO_DEPRECATE;_SECURE_SCL=0"
|
||||
BasicRuntimeChecks="3"
|
||||
RuntimeLibrary="1"
|
||||
|
@ -295,27 +258,11 @@
|
|||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLinkerTool"
|
||||
AdditionalOptions=""..\..\core\common\win32\debug\common.lib""
|
||||
AdditionalDependencies="odbc32.lib odbccp32.lib comctl32.lib uuid.lib dxguid.lib Rpcrt4.lib winmm.lib vfw32.lib wxbase28ud.lib wxmsw28ud_core.lib"
|
||||
OutputFile="..\..\..\Binary\Win32/Plugins\Plugin_VideoDX11D.dll"
|
||||
LinkIncremental="1"
|
||||
SuppressStartupBanner="true"
|
||||
AdditionalLibraryDirectories="../../../Externals/Cg;"..\..\..\Externals\wxWidgets\lib\vc_lib\$(PlatformName)""
|
||||
GenerateManifest="false"
|
||||
GenerateDebugInformation="true"
|
||||
ProgramDatabaseFile="$(PlatformName)\$(ConfigurationName)\$(TargetName).pdb"
|
||||
RandomizedBaseAddress="1"
|
||||
DataExecutionPrevention="0"
|
||||
ImportLibrary="$(PlatformName)\$(ConfigurationName)\$(TargetName).lib"
|
||||
TargetMachine="1"
|
||||
Name="VCLibrarianTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManifestTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
|
@ -325,9 +272,6 @@
|
|||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCAppVerifierTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
/>
|
||||
|
@ -336,7 +280,7 @@
|
|||
Name="Debug|x64"
|
||||
OutputDirectory="$(PlatformName)\$(ConfigurationName)"
|
||||
IntermediateDirectory="$(PlatformName)\$(ConfigurationName)"
|
||||
ConfigurationType="2"
|
||||
ConfigurationType="4"
|
||||
InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC71.vsprops"
|
||||
UseOfMFC="0"
|
||||
ATLMinimizesCRunTimeLibraryUsage="false"
|
||||
|
@ -366,7 +310,7 @@
|
|||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
Optimization="0"
|
||||
AdditionalIncludeDirectories="../../../Externals;../../PluginSpecs;../../Core/Common/Src;../../Core/VideoCommon/Src;../../Core/VideoUICommon/Src;..\..\..\Externals\wxWidgets\Include;..\..\..\Externals\wxWidgets\Include\msvc"
|
||||
AdditionalIncludeDirectories="../../../Externals;../../PluginSpecs;../../Core/Common/Src;../../Core/Core/Src;../../Core/VideoCommon/Src;../../Core/VideoUICommon/Src;..\..\..\Externals\wxWidgets\Include;..\..\..\Externals\wxWidgets\Include\msvc"
|
||||
PreprocessorDefinitions="WIN32;_DEBUG;_WINDOWS;_USRDLL;VIDEO_DIRECTX11_EXPORTS;_CRT_SECURE_NO_DEPRECATE;_SECURE_SCL=0"
|
||||
BasicRuntimeChecks="3"
|
||||
RuntimeLibrary="1"
|
||||
|
@ -392,26 +336,11 @@
|
|||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLinkerTool"
|
||||
AdditionalDependencies="odbc32.lib odbccp32.lib comctl32.lib uuid.lib dxguid.lib Rpcrt4.lib winmm.lib vfw32.lib"
|
||||
OutputFile="..\..\..\Binary\x64\Plugins\Plugin_VideoDX11D.dll"
|
||||
LinkIncremental="1"
|
||||
SuppressStartupBanner="true"
|
||||
AdditionalLibraryDirectories="..\..\..\Externals\Cg64;"..\..\..\Externals\wxWidgets\lib\vc_lib\$(PlatformName)""
|
||||
GenerateManifest="false"
|
||||
GenerateDebugInformation="true"
|
||||
ProgramDatabaseFile="$(PlatformName)\$(ConfigurationName)\$(TargetName).pdb"
|
||||
RandomizedBaseAddress="1"
|
||||
DataExecutionPrevention="0"
|
||||
ImportLibrary="$(PlatformName)\$(ConfigurationName)\$(TargetName).lib"
|
||||
TargetMachine="17"
|
||||
Name="VCLibrarianTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManifestTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
|
@ -421,9 +350,6 @@
|
|||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCAppVerifierTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
/>
|
||||
|
@ -432,7 +358,7 @@
|
|||
Name="DebugFast|Win32"
|
||||
OutputDirectory="$(PlatformName)\$(ConfigurationName)"
|
||||
IntermediateDirectory="$(PlatformName)\$(ConfigurationName)"
|
||||
ConfigurationType="2"
|
||||
ConfigurationType="4"
|
||||
InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC71.vsprops"
|
||||
UseOfMFC="0"
|
||||
ATLMinimizesCRunTimeLibraryUsage="false"
|
||||
|
@ -468,7 +394,7 @@
|
|||
FavorSizeOrSpeed="1"
|
||||
OmitFramePointers="false"
|
||||
WholeProgramOptimization="true"
|
||||
AdditionalIncludeDirectories="../../../Externals;../../PluginSpecs;../../Core/Common/Src;../../Core/VideoCommon/Src;../../Core/VideoUICommon/Src;..\..\..\Externals\wxWidgets\Include;..\..\..\Externals\wxWidgets\Include\msvc"
|
||||
AdditionalIncludeDirectories="../../../Externals;../../PluginSpecs;../../Core/Common/Src;../../Core/Core/Src;../../Core/VideoCommon/Src;../../Core/VideoUICommon/Src;..\..\..\Externals\wxWidgets\Include;..\..\..\Externals\wxWidgets\Include\msvc"
|
||||
PreprocessorDefinitions="_WIN32;WIN32;NDEBUG;_WINDOWS;_USRDLL;VIDEO_DIRECTX11_EXPORTS;_CRT_SECURE_NO_DEPRECATE;_SECURE_SCL=0;DEBUGFAST"
|
||||
StringPooling="true"
|
||||
RuntimeLibrary="0"
|
||||
|
@ -498,27 +424,11 @@
|
|||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLinkerTool"
|
||||
AdditionalDependencies="odbc32.lib odbccp32.lib comctl32.lib uuid.lib dxguid.lib Rpcrt4.lib winmm.lib vfw32.lib"
|
||||
OutputFile="..\..\..\Binary\Win32\Plugins\Plugin_VideoDX11DF.dll"
|
||||
LinkIncremental="1"
|
||||
SuppressStartupBanner="true"
|
||||
AdditionalLibraryDirectories="../../../Externals/Cg;"..\..\..\Externals\wxWidgets\lib\vc_lib\$(PlatformName)""
|
||||
GenerateManifest="false"
|
||||
IgnoreDefaultLibraryNames=""
|
||||
GenerateDebugInformation="true"
|
||||
ProgramDatabaseFile="$(PlatformName)\$(ConfigurationName)\$(TargetName).pdb"
|
||||
RandomizedBaseAddress="1"
|
||||
DataExecutionPrevention="0"
|
||||
ImportLibrary="$(PlatformName)\$(ConfigurationName)\$(TargetName).lib"
|
||||
TargetMachine="1"
|
||||
Name="VCLibrarianTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManifestTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
|
@ -528,9 +438,6 @@
|
|||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCAppVerifierTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
/>
|
||||
|
@ -539,7 +446,7 @@
|
|||
Name="DebugFast|x64"
|
||||
OutputDirectory="$(PlatformName)\$(ConfigurationName)"
|
||||
IntermediateDirectory="$(PlatformName)\$(ConfigurationName)"
|
||||
ConfigurationType="2"
|
||||
ConfigurationType="4"
|
||||
InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC71.vsprops"
|
||||
UseOfMFC="0"
|
||||
ATLMinimizesCRunTimeLibraryUsage="false"
|
||||
|
@ -576,7 +483,7 @@
|
|||
FavorSizeOrSpeed="1"
|
||||
OmitFramePointers="false"
|
||||
WholeProgramOptimization="true"
|
||||
AdditionalIncludeDirectories="../../../Externals;../../PluginSpecs;../../Core/Common/Src;../../Core/VideoCommon/Src;../../Core/VideoUICommon/Src;..\..\..\Externals\wxWidgets\Include;..\..\..\Externals\wxWidgets\Include\msvc"
|
||||
AdditionalIncludeDirectories="../../../Externals;../../PluginSpecs;../../Core/Common/Src;../../Core/Core/Src;../../Core/VideoCommon/Src;../../Core/VideoUICommon/Src;..\..\..\Externals\wxWidgets\Include;..\..\..\Externals\wxWidgets\Include\msvc"
|
||||
PreprocessorDefinitions="WIN32;NDEBUG;_WINDOWS;_USRDLL;VIDEO_DIRECTX11_EXPORTS;_CRT_SECURE_NO_DEPRECATE;_SECURE_SCL=0;;DEBUGFAST"
|
||||
StringPooling="true"
|
||||
ExceptionHandling="1"
|
||||
|
@ -607,26 +514,11 @@
|
|||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLinkerTool"
|
||||
AdditionalDependencies="odbc32.lib odbccp32.lib comctl32.lib uuid.lib dxguid.lib Rpcrt4.lib winmm.lib vfw32.lib"
|
||||
OutputFile="..\..\..\Binary\x64\Plugins\Plugin_VideoDX11DF.dll"
|
||||
LinkIncremental="1"
|
||||
SuppressStartupBanner="true"
|
||||
AdditionalLibraryDirectories="..\..\..\Externals\Cg64;"..\..\..\Externals\wxWidgets\lib\vc_lib\$(PlatformName)""
|
||||
GenerateManifest="false"
|
||||
GenerateDebugInformation="true"
|
||||
ProgramDatabaseFile="$(PlatformName)\$(ConfigurationName)\$(TargetName).pdb"
|
||||
RandomizedBaseAddress="1"
|
||||
DataExecutionPrevention="0"
|
||||
ImportLibrary="$(PlatformName)\$(ConfigurationName)\$(TargetName).lib"
|
||||
TargetMachine="17"
|
||||
Name="VCLibrarianTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManifestTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
|
@ -636,9 +528,6 @@
|
|||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCAppVerifierTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
/>
|
||||
|
|
|
@ -29,38 +29,39 @@
|
|||
<PropertyGroup Label="Globals">
|
||||
<ProjectGuid>{9A4C733C-BADE-4AC6-B58A-6E274395E90E}</ProjectGuid>
|
||||
<RootNamespace>Plugin_VideoDX11</RootNamespace>
|
||||
<ProjectName>VideoDX11</ProjectName>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
|
||||
<ConfigurationType>DynamicLibrary</ConfigurationType>
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>true</UseDebugLibraries>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">
|
||||
<ConfigurationType>DynamicLibrary</ConfigurationType>
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>true</UseDebugLibraries>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
|
||||
<ConfigurationType>DynamicLibrary</ConfigurationType>
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>false</UseDebugLibraries>
|
||||
<WholeProgramOptimization>true</WholeProgramOptimization>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='DebugFast|Win32'" Label="Configuration">
|
||||
<ConfigurationType>DynamicLibrary</ConfigurationType>
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>false</UseDebugLibraries>
|
||||
<WholeProgramOptimization>true</WholeProgramOptimization>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
|
||||
<ConfigurationType>DynamicLibrary</ConfigurationType>
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>false</UseDebugLibraries>
|
||||
<WholeProgramOptimization>true</WholeProgramOptimization>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='DebugFast|x64'" Label="Configuration">
|
||||
<ConfigurationType>DynamicLibrary</ConfigurationType>
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>false</UseDebugLibraries>
|
||||
<WholeProgramOptimization>true</WholeProgramOptimization>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
|
@ -131,7 +132,7 @@
|
|||
<ClCompile>
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
<Optimization>Disabled</Optimization>
|
||||
<AdditionalIncludeDirectories>..\..\Core\Common\Src;..\..\PluginSpecs;..\..\Core\VideoCommon\Src;..\..\Core\VideoUICommon\Src;..\..\..\Externals\wxWidgets\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<AdditionalIncludeDirectories>..\..\Core\Common\Src;..\..\Core\Core\Src;..\..\PluginSpecs;..\..\Core\VideoCommon\Src;..\..\Core\VideoUICommon\Src;..\..\..\Externals\wxWidgets\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<PreprocessorDefinitions>_SECURE_SCL=0;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<RuntimeLibrary>MultiThreadedDebug</RuntimeLibrary>
|
||||
<ForcedIncludeFiles>stdafx.h</ForcedIncludeFiles>
|
||||
|
@ -147,7 +148,7 @@
|
|||
<ClCompile>
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
<Optimization>Disabled</Optimization>
|
||||
<AdditionalIncludeDirectories>..\..\Core\Common\Src;..\..\PluginSpecs;..\..\Core\VideoCommon\Src;..\..\Core\VideoUICommon\Src;..\..\..\Externals\wxWidgets\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<AdditionalIncludeDirectories>..\..\Core\Common\Src;..\..\Core\Core\Src;..\..\PluginSpecs;..\..\Core\VideoCommon\Src;..\..\Core\VideoUICommon\Src;..\..\..\Externals\wxWidgets\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<PreprocessorDefinitions>_SECURE_SCL=0;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<RuntimeLibrary>MultiThreadedDebug</RuntimeLibrary>
|
||||
<ForcedIncludeFiles>stdafx.h</ForcedIncludeFiles>
|
||||
|
@ -165,7 +166,7 @@
|
|||
<Optimization>MaxSpeed</Optimization>
|
||||
<FunctionLevelLinking>true</FunctionLevelLinking>
|
||||
<IntrinsicFunctions>true</IntrinsicFunctions>
|
||||
<AdditionalIncludeDirectories>..\..\Core\Common\Src;..\..\PluginSpecs;..\..\Core\VideoCommon\Src;..\..\Core\VideoUICommon\Src;..\..\..\Externals\wxWidgets\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<AdditionalIncludeDirectories>..\..\Core\Common\Src;..\..\Core\Core\Src;..\..\PluginSpecs;..\..\Core\VideoCommon\Src;..\..\Core\VideoUICommon\Src;..\..\..\Externals\wxWidgets\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<PreprocessorDefinitions>_SECURE_SCL=0;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<RuntimeLibrary>MultiThreaded</RuntimeLibrary>
|
||||
<ForcedIncludeFiles>stdafx.h</ForcedIncludeFiles>
|
||||
|
@ -205,7 +206,7 @@
|
|||
<Optimization>MaxSpeed</Optimization>
|
||||
<FunctionLevelLinking>true</FunctionLevelLinking>
|
||||
<IntrinsicFunctions>true</IntrinsicFunctions>
|
||||
<AdditionalIncludeDirectories>..\..\Core\Common\Src;..\..\PluginSpecs;..\..\Core\VideoCommon\Src;..\..\Core\VideoUICommon\Src;..\..\..\Externals\wxWidgets\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<AdditionalIncludeDirectories>..\..\Core\Common\Src;..\..\Core\Core\Src;..\..\PluginSpecs;..\..\Core\VideoCommon\Src;..\..\Core\VideoUICommon\Src;..\..\..\Externals\wxWidgets\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<PreprocessorDefinitions>_SECURE_SCL=0;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<RuntimeLibrary>MultiThreaded</RuntimeLibrary>
|
||||
<ForcedIncludeFiles>stdafx.h</ForcedIncludeFiles>
|
||||
|
@ -287,6 +288,7 @@
|
|||
<ClInclude Include="Src\TextureCache.h" />
|
||||
<ClInclude Include="Src\VertexManager.h" />
|
||||
<ClInclude Include="Src\VertexShaderCache.h" />
|
||||
<ClInclude Include="Src\VideoBackend.h" />
|
||||
</ItemGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
|
||||
<ImportGroup Label="ExtensionTargets">
|
||||
|
|
|
@ -23,9 +23,5 @@
|
|||
#include "main.h"
|
||||
|
||||
#include "VideoCommon.h"
|
||||
#include "pluginspecs_video.h"
|
||||
|
||||
// A global plugin specification
|
||||
extern PLUGIN_GLOBALS* globals;
|
||||
|
||||
#endif // _GLOBALS_H_
|
|
@ -22,6 +22,9 @@
|
|||
#include "VertexManager.h"
|
||||
#include "VertexShaderCache.h"
|
||||
|
||||
namespace DX11
|
||||
{
|
||||
|
||||
class D3DVertexFormat : public NativeVertexFormat
|
||||
{
|
||||
D3D11_INPUT_ELEMENT_DESC m_elems[32];
|
||||
|
@ -38,16 +41,11 @@ public:
|
|||
void SetupVertexPointers();
|
||||
};
|
||||
|
||||
namespace DX11
|
||||
{
|
||||
|
||||
NativeVertexFormat* VertexManager::CreateNativeVertexFormat()
|
||||
{
|
||||
return new D3DVertexFormat();
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
DXGI_FORMAT VarToD3D(VarType t, int size)
|
||||
{
|
||||
DXGI_FORMAT retval = DXGI_FORMAT_UNKNOWN;
|
||||
|
@ -155,3 +153,5 @@ void D3DVertexFormat::SetupVertexPointers()
|
|||
}
|
||||
DX11::D3D::context->IASetInputLayout(m_layout);
|
||||
}
|
||||
|
||||
} // namespace DX11
|
||||
|
|
|
@ -28,6 +28,8 @@
|
|||
#include "PixelShaderGen.h"
|
||||
#include "PixelShaderCache.h"
|
||||
|
||||
#include "ConfigManager.h"
|
||||
|
||||
extern int frameCount;
|
||||
|
||||
// See comment near the bottom of this file.
|
||||
|
@ -37,7 +39,6 @@ bool pscbufchanged = true;
|
|||
namespace DX11
|
||||
{
|
||||
|
||||
|
||||
PixelShaderCache::PSCache PixelShaderCache::PixelShaders;
|
||||
const PixelShaderCache::PSCacheEntry* PixelShaderCache::last_entry;
|
||||
|
||||
|
@ -271,7 +272,7 @@ void PixelShaderCache::Init()
|
|||
SETSTAT(stats.numPixelShadersAlive, 0);
|
||||
|
||||
char cache_filename[MAX_PATH];
|
||||
sprintf(cache_filename, "%sdx11-%s-ps.cache", File::GetUserPath(D_SHADERCACHE_IDX), globals->unique_id);
|
||||
sprintf(cache_filename, "%sdx11-%s-ps.cache", File::GetUserPath(D_SHADERCACHE_IDX), SConfig::GetInstance().m_LocalCoreStartupParameter.m_strUniqueID.c_str());
|
||||
PixelShaderCacheInserter inserter;
|
||||
g_ps_disk_cache.OpenAndRead(cache_filename, inserter);
|
||||
}
|
||||
|
@ -386,9 +387,6 @@ bool PixelShaderCache::InsertByteCode(const PIXELSHADERUID &uid, const void* byt
|
|||
return true;
|
||||
}
|
||||
|
||||
} // DX11
|
||||
|
||||
|
||||
// These are "callbacks" from VideoCommon and thus must be outside namespace DX11.
|
||||
// This will have to be changed when we merge.
|
||||
|
||||
|
@ -414,7 +412,7 @@ static const unsigned int ps_constant_offset_table[] = {
|
|||
260, 264, 268, 272, 276, // C_PLIGHTS7, 20
|
||||
280, 284, 288, 292 // C_PMATERIALS, 16
|
||||
};
|
||||
void SetPSConstant4f(unsigned int const_number, float f1, float f2, float f3, float f4)
|
||||
void Renderer::SetPSConstant4f(unsigned int const_number, float f1, float f2, float f3, float f4)
|
||||
{
|
||||
psconstants[ps_constant_offset_table[const_number] ] = f1;
|
||||
psconstants[ps_constant_offset_table[const_number]+1] = f2;
|
||||
|
@ -423,14 +421,16 @@ void SetPSConstant4f(unsigned int const_number, float f1, float f2, float f3, fl
|
|||
pscbufchanged = true;
|
||||
}
|
||||
|
||||
void SetPSConstant4fv(unsigned int const_number, const float* f)
|
||||
void Renderer::SetPSConstant4fv(unsigned int const_number, const float* f)
|
||||
{
|
||||
memcpy(&psconstants[ps_constant_offset_table[const_number]], f, sizeof(float)*4);
|
||||
pscbufchanged = true;
|
||||
}
|
||||
|
||||
void SetMultiPSConstant4fv(unsigned int const_number, unsigned int count, const float* f)
|
||||
void Renderer::SetMultiPSConstant4fv(unsigned int const_number, unsigned int count, const float* f)
|
||||
{
|
||||
memcpy(&psconstants[ps_constant_offset_table[const_number]], f, sizeof(float)*4*count);
|
||||
pscbufchanged = true;
|
||||
}
|
||||
|
||||
} // DX11
|
||||
|
|
|
@ -24,7 +24,8 @@
|
|||
class PIXELSHADERUID;
|
||||
enum DSTALPHA_MODE;
|
||||
|
||||
namespace DX11 {
|
||||
namespace DX11
|
||||
{
|
||||
|
||||
class PixelShaderCache
|
||||
{
|
||||
|
@ -61,4 +62,4 @@ private:
|
|||
static const PSCacheEntry* last_entry;
|
||||
};
|
||||
|
||||
} // namespace DX11
|
||||
} // namespace DX11
|
||||
|
|
|
@ -38,7 +38,7 @@
|
|||
#include "Render.h"
|
||||
#include "TextureCache.h"
|
||||
#include "VertexShaderCache.h"
|
||||
|
||||
#include "Core.h"
|
||||
|
||||
namespace DX11
|
||||
{
|
||||
|
@ -313,7 +313,7 @@ Renderer::Renderer()
|
|||
int x, y, w_temp, h_temp;
|
||||
s_blendMode = 0;
|
||||
|
||||
g_VideoInitialize.pGetWindowSize(x, y, w_temp, h_temp);
|
||||
Core::Callback_VideoGetWindowSize(x, y, w_temp, h_temp);
|
||||
|
||||
D3D::Create(EmuWindow::GetWnd());
|
||||
|
||||
|
@ -447,7 +447,7 @@ void Renderer::SetWindowSize(int width, int height)
|
|||
// Scale the window size by the EFB scale.
|
||||
CalculateTargetScale(width, height, width, height);
|
||||
|
||||
g_VideoInitialize.pRequestWindowSize(width, height);
|
||||
Core::Callback_VideoRequestWindowSize(width, height);
|
||||
}
|
||||
|
||||
bool Renderer::SetScissorRect()
|
||||
|
@ -897,7 +897,7 @@ void Renderer::Swap(u32 xfbAddr, FieldType field, u32 fbWidth, u32 fbHeight,cons
|
|||
{
|
||||
if (g_bSkipCurrentFrame || (!XFBWrited && (!g_ActiveConfig.bUseXFB || !g_ActiveConfig.bUseRealXFB)) || !fbWidth || !fbHeight)
|
||||
{
|
||||
g_VideoInitialize.pCopiedToXFB(false);
|
||||
Core::Callback_VideoCopiedToXFB(false);
|
||||
return;
|
||||
}
|
||||
// this function is called after the XFB field is changed, not after
|
||||
|
@ -909,7 +909,7 @@ void Renderer::Swap(u32 xfbAddr, FieldType field, u32 fbWidth, u32 fbHeight,cons
|
|||
const XFBSourceBase* const* xfbSourceList = FramebufferManager::GetXFBSource(xfbAddr, fbWidth, fbHeight, xfbCount);
|
||||
if ((!xfbSourceList || xfbCount == 0) && g_ActiveConfig.bUseXFB && !g_ActiveConfig.bUseRealXFB)
|
||||
{
|
||||
g_VideoInitialize.pCopiedToXFB(false);
|
||||
Core::Callback_VideoCopiedToXFB(false);
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -1120,7 +1120,7 @@ void Renderer::Swap(u32 xfbAddr, FieldType field, u32 fbWidth, u32 fbHeight,cons
|
|||
UpdateViewport();
|
||||
VertexShaderManager::SetViewportChanged();
|
||||
|
||||
g_VideoInitialize.pCopiedToXFB(XFBWrited || (g_ActiveConfig.bUseXFB && g_ActiveConfig.bUseRealXFB));
|
||||
Core::Callback_VideoCopiedToXFB(XFBWrited || (g_ActiveConfig.bUseXFB && g_ActiveConfig.bUseRealXFB));
|
||||
XFBWrited = false;
|
||||
}
|
||||
|
||||
|
|
|
@ -49,6 +49,15 @@ public:
|
|||
|
||||
static bool CheckForResize();
|
||||
static void SetWindowSize(int width, int height);
|
||||
|
||||
void SetPSConstant4f(unsigned int const_number, float f1, float f2, float f3, float f4);
|
||||
void SetPSConstant4fv(unsigned int const_number, const float *f);
|
||||
void SetMultiPSConstant4fv(unsigned int const_number, unsigned int count, const float *f);
|
||||
|
||||
void SetVSConstant4f(unsigned int const_number, float f1, float f2, float f3, float f4);
|
||||
void SetVSConstant4fv(unsigned int const_number, const float *f);
|
||||
void SetMultiVSConstant3fv(unsigned int const_number, unsigned int count, const float *f);
|
||||
void SetMultiVSConstant4fv(unsigned int const_number, unsigned int count, const float *f);
|
||||
};
|
||||
|
||||
}
|
||||
|
|
|
@ -26,6 +26,8 @@
|
|||
#include "Globals.h"
|
||||
#include "VertexShaderCache.h"
|
||||
|
||||
#include "ConfigManager.h"
|
||||
|
||||
// See comment near the bottom of this file
|
||||
static unsigned int vs_constant_offset_table[C_VENVCONST_END];
|
||||
float vsconstants[C_VENVCONST_END*4];
|
||||
|
@ -168,7 +170,7 @@ void VertexShaderCache::Init()
|
|||
SETSTAT(stats.numVertexShadersAlive, 0);
|
||||
|
||||
char cache_filename[MAX_PATH];
|
||||
sprintf(cache_filename, "%sdx11-%s-vs.cache", File::GetUserPath(D_SHADERCACHE_IDX), globals->unique_id);
|
||||
sprintf(cache_filename, "%sdx11-%s-vs.cache", File::GetUserPath(D_SHADERCACHE_IDX), SConfig::GetInstance().m_LocalCoreStartupParameter.m_strUniqueID.c_str());
|
||||
VertexShaderCacheInserter inserter;
|
||||
g_vs_disk_cache.OpenAndRead(cache_filename, inserter);
|
||||
}
|
||||
|
@ -264,13 +266,11 @@ bool VertexShaderCache::InsertByteCode(const VERTEXSHADERUID &uid, D3DBlob* bcod
|
|||
return true;
|
||||
}
|
||||
|
||||
} // namespace DX11
|
||||
|
||||
// These are "callbacks" from VideoCommon and thus must be outside namespace DX11.
|
||||
// This will have to be changed when we merge.
|
||||
|
||||
// maps the constant numbers to float indices in the constant buffer
|
||||
void SetVSConstant4f(unsigned int const_number, float f1, float f2, float f3, float f4)
|
||||
void Renderer::SetVSConstant4f(unsigned int const_number, float f1, float f2, float f3, float f4)
|
||||
{
|
||||
vsconstants[vs_constant_offset_table[const_number] ] = f1;
|
||||
vsconstants[vs_constant_offset_table[const_number]+1] = f2;
|
||||
|
@ -279,13 +279,13 @@ void SetVSConstant4f(unsigned int const_number, float f1, float f2, float f3, fl
|
|||
vscbufchanged = true;
|
||||
}
|
||||
|
||||
void SetVSConstant4fv(unsigned int const_number, const float* f)
|
||||
void Renderer::SetVSConstant4fv(unsigned int const_number, const float* f)
|
||||
{
|
||||
memcpy(&vsconstants[vs_constant_offset_table[const_number]], f, sizeof(float)*4);
|
||||
vscbufchanged = true;
|
||||
}
|
||||
|
||||
void SetMultiVSConstant3fv(unsigned int const_number, unsigned int count, const float* f)
|
||||
void Renderer::SetMultiVSConstant3fv(unsigned int const_number, unsigned int count, const float* f)
|
||||
{
|
||||
for (unsigned int i = 0; i < count; i++)
|
||||
{
|
||||
|
@ -295,8 +295,10 @@ void SetMultiVSConstant3fv(unsigned int const_number, unsigned int count, const
|
|||
vscbufchanged = true;
|
||||
}
|
||||
|
||||
void SetMultiVSConstant4fv(unsigned int const_number, unsigned int count, const float* f)
|
||||
void Renderer::SetMultiVSConstant4fv(unsigned int const_number, unsigned int count, const float* f)
|
||||
{
|
||||
memcpy(&vsconstants[vs_constant_offset_table[const_number]], f, sizeof(float)*4*count);
|
||||
vscbufchanged = true;
|
||||
}
|
||||
}
|
||||
|
||||
} // namespace DX11
|
||||
|
|
27
Source/Plugins/Plugin_VideoDX11/Src/VideoBackend.h
Normal file
27
Source/Plugins/Plugin_VideoDX11/Src/VideoBackend.h
Normal file
|
@ -0,0 +1,27 @@
|
|||
|
||||
#ifndef DX11_VIDEO_BACKEND_H_
|
||||
#define DX11_VIDEO_BACKEND_H_
|
||||
|
||||
#include "VideoBackendBase.h"
|
||||
|
||||
namespace DX11
|
||||
{
|
||||
|
||||
class VideoBackend : public VideoBackendHLE
|
||||
{
|
||||
void Initialize();
|
||||
void Shutdown();
|
||||
|
||||
std::string GetName();
|
||||
|
||||
void Video_Prepare();
|
||||
|
||||
void ShowConfig(void* parent);
|
||||
|
||||
void UpdateFPSDisplay(const char*);
|
||||
unsigned int PeekMessages();
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
#endif
|
|
@ -30,6 +30,7 @@
|
|||
#include "VertexLoaderManager.h"
|
||||
#include "VertexShaderManager.h"
|
||||
#include "XFBConvert.h"
|
||||
#include "Core.h"
|
||||
|
||||
#include "DebuggerPanel.h"
|
||||
#include "DLCache.h"
|
||||
|
@ -46,83 +47,18 @@
|
|||
#include "VertexManager.h"
|
||||
#include "VertexShaderCache.h"
|
||||
|
||||
#include "VideoBackend.h"
|
||||
#include "ConfigManager.h"
|
||||
|
||||
HINSTANCE g_hInstance = NULL;
|
||||
|
||||
wxLocale *InitLanguageSupport()
|
||||
namespace DX11
|
||||
{
|
||||
wxLocale *m_locale;
|
||||
unsigned int language = 0;
|
||||
|
||||
IniFile ini;
|
||||
ini.Load(File::GetUserPath(F_DOLPHINCONFIG_IDX));
|
||||
ini.Get("Interface", "Language", &language, wxLANGUAGE_DEFAULT);
|
||||
|
||||
// Load language if possible, fall back to system default otherwise
|
||||
if(wxLocale::IsAvailable(language))
|
||||
{
|
||||
m_locale = new wxLocale(language);
|
||||
|
||||
m_locale->AddCatalogLookupPathPrefix(wxT("Languages"));
|
||||
|
||||
m_locale->AddCatalog(wxT("dolphin-emu"));
|
||||
|
||||
if(!m_locale->IsOk())
|
||||
{
|
||||
PanicAlertT("Error loading selected language. Falling back to system default.");
|
||||
delete m_locale;
|
||||
m_locale = new wxLocale(wxLANGUAGE_DEFAULT);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
PanicAlertT("The selected language is not supported by your system. Falling back to system default.");
|
||||
m_locale = new wxLocale(wxLANGUAGE_DEFAULT);
|
||||
}
|
||||
return m_locale;
|
||||
void*& VideoWindowHandle()
|
||||
{
|
||||
return SConfig::GetInstance().m_LocalCoreStartupParameter.hMainWindow;
|
||||
}
|
||||
|
||||
// This is used for the functions right below here which use wxwidgets
|
||||
WXDLLIMPEXP_BASE void wxSetInstance(HINSTANCE hInst);
|
||||
|
||||
void *DllDebugger(void *_hParent, bool Show)
|
||||
{
|
||||
return new GFXDebuggerPanel((wxWindow*)_hParent);
|
||||
}
|
||||
|
||||
class wxDLLApp : public wxApp
|
||||
{
|
||||
bool OnInit()
|
||||
{
|
||||
return true;
|
||||
}
|
||||
};
|
||||
IMPLEMENT_APP_NO_MAIN(wxDLLApp)
|
||||
WXDLLIMPEXP_BASE void wxSetInstance(HINSTANCE hInst);
|
||||
|
||||
BOOL APIENTRY DllMain(HINSTANCE hinstDLL, DWORD dwReason, LPVOID lpvReserved)
|
||||
{
|
||||
static wxLocale *m_locale;
|
||||
switch (dwReason)
|
||||
{
|
||||
case DLL_PROCESS_ATTACH:
|
||||
{
|
||||
wxSetInstance((HINSTANCE)hinstDLL);
|
||||
wxInitialize();
|
||||
m_locale = InitLanguageSupport();
|
||||
}
|
||||
break;
|
||||
case DLL_PROCESS_DETACH:
|
||||
wxUninitialize();
|
||||
delete m_locale;
|
||||
break;
|
||||
}
|
||||
|
||||
g_hInstance = hinstDLL;
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
unsigned int Callback_PeekMessages()
|
||||
unsigned int VideoBackend::PeekMessages()
|
||||
{
|
||||
MSG msg;
|
||||
while (PeekMessage(&msg, 0, 0, 0, PM_REMOVE))
|
||||
|
@ -135,31 +71,29 @@ unsigned int Callback_PeekMessages()
|
|||
return TRUE;
|
||||
}
|
||||
|
||||
|
||||
void UpdateFPSDisplay(const char *text)
|
||||
void VideoBackend::UpdateFPSDisplay(const char *text)
|
||||
{
|
||||
char temp[512];
|
||||
sprintf_s(temp, sizeof temp, "%s | DX11 | %s", svn_rev_str, text);
|
||||
SetWindowTextA(EmuWindow::GetWnd(), temp);
|
||||
}
|
||||
|
||||
void GetDllInfo(PLUGIN_INFO* _PluginInfo)
|
||||
{
|
||||
_PluginInfo->Version = 0x0100;
|
||||
_PluginInfo->Type = PLUGIN_TYPE_VIDEO;
|
||||
#ifdef DEBUGFAST
|
||||
sprintf_s(_PluginInfo->Name, 100, "Dolphin Direct3D11 (DebugFast)");
|
||||
#elif defined _DEBUG
|
||||
sprintf_s(_PluginInfo->Name, 100, "Dolphin Direct3D11 (Debug)");
|
||||
#else
|
||||
sprintf_s(_PluginInfo->Name, 100, "Dolphin Direct3D11");
|
||||
#endif
|
||||
}
|
||||
//void GetDllInfo(PLUGIN_INFO* _PluginInfo)
|
||||
//{
|
||||
// _PluginInfo->Version = 0x0100;
|
||||
// //_PluginInfo->Type = PLUGIN_TYPE_VIDEO;
|
||||
//#ifdef DEBUGFAST
|
||||
// sprintf_s(_PluginInfo->Name, 100, "Dolphin Direct3D11 (DebugFast)");
|
||||
//#elif defined _DEBUG
|
||||
// sprintf_s(_PluginInfo->Name, 100, "Dolphin Direct3D11 (Debug)");
|
||||
//#else
|
||||
// sprintf_s(_PluginInfo->Name, 100, "Dolphin Direct3D11");
|
||||
//#endif
|
||||
//}
|
||||
|
||||
void SetDllGlobals(PLUGIN_GLOBALS* _pPluginGlobals)
|
||||
std::string VideoBackend::GetName()
|
||||
{
|
||||
globals = _pPluginGlobals;
|
||||
LogManager::SetInstance((LogManager*)globals->logManager);
|
||||
return "Direct3D11";
|
||||
}
|
||||
|
||||
void InitBackendInfo()
|
||||
|
@ -175,7 +109,7 @@ void InitBackendInfo()
|
|||
g_Config.backend_info.bSupportsPixelLighting = true;
|
||||
}
|
||||
|
||||
void DllConfig(void *_hParent)
|
||||
void VideoBackend::ShowConfig(void *_hParent)
|
||||
{
|
||||
#if defined(HAVE_WX) && HAVE_WX
|
||||
InitBackendInfo();
|
||||
|
@ -234,42 +168,30 @@ void DllConfig(void *_hParent)
|
|||
#endif
|
||||
}
|
||||
|
||||
void Initialize(void *init)
|
||||
void VideoBackend::Initialize()
|
||||
{
|
||||
InitBackendInfo();
|
||||
|
||||
frameCount = 0;
|
||||
SVideoInitialize *_pVideoInitialize = (SVideoInitialize*)init;
|
||||
// Create a shortcut to _pVideoInitialize that can also update it
|
||||
g_VideoInitialize = *(_pVideoInitialize);
|
||||
InitXFBConvTables();
|
||||
|
||||
g_Config.Load((std::string(File::GetUserPath(D_CONFIG_IDX)) + "gfx_dx11.ini").c_str());
|
||||
g_Config.GameIniLoad(globals->game_ini);
|
||||
g_Config.GameIniLoad(SConfig::GetInstance().m_LocalCoreStartupParameter.m_strGameIni.c_str());
|
||||
UpdateProjectionHack(g_Config.iPhackvalue, g_Config.sPhackvalue);
|
||||
UpdateActiveConfig();
|
||||
|
||||
g_VideoInitialize.pWindowHandle = (void*)EmuWindow::Create((HWND)g_VideoInitialize.pWindowHandle, g_hInstance, _T("Loading - Please wait."));
|
||||
if (g_VideoInitialize.pWindowHandle == NULL)
|
||||
VideoWindowHandle() = (void*)EmuWindow::Create((HWND)VideoWindowHandle(), GetModuleHandle(0), _T("Loading - Please wait."));
|
||||
if (VideoWindowHandle() == NULL)
|
||||
{
|
||||
ERROR_LOG(VIDEO, "An error has occurred while trying to create the window.");
|
||||
return;
|
||||
}
|
||||
|
||||
g_VideoInitialize.pPeekMessages = &Callback_PeekMessages;
|
||||
g_VideoInitialize.pUpdateFPSDisplay = &UpdateFPSDisplay;
|
||||
|
||||
_pVideoInitialize->pPeekMessages = g_VideoInitialize.pPeekMessages;
|
||||
_pVideoInitialize->pUpdateFPSDisplay = g_VideoInitialize.pUpdateFPSDisplay;
|
||||
|
||||
// Now the window handle is written
|
||||
_pVideoInitialize->pWindowHandle = g_VideoInitialize.pWindowHandle;
|
||||
|
||||
OSD::AddMessage("Dolphin Direct3D11 Video Plugin.", 5000);
|
||||
s_PluginInitialized = true;
|
||||
}
|
||||
|
||||
void Video_Prepare()
|
||||
void VideoBackend::Video_Prepare()
|
||||
{
|
||||
// Better be safe...
|
||||
s_efbAccessRequested = FALSE;
|
||||
|
@ -277,12 +199,12 @@ void Video_Prepare()
|
|||
s_swapRequested = FALSE;
|
||||
|
||||
// internal interfaces
|
||||
g_renderer = new DX11::Renderer;
|
||||
g_texture_cache = new DX11::TextureCache;
|
||||
g_vertex_manager = new DX11::VertexManager;
|
||||
DX11::VertexShaderCache::Init();
|
||||
DX11::PixelShaderCache::Init();
|
||||
DX11::D3D::InitUtils();
|
||||
g_renderer = new Renderer;
|
||||
g_texture_cache = new TextureCache;
|
||||
g_vertex_manager = new VertexManager;
|
||||
VertexShaderCache::Init();
|
||||
PixelShaderCache::Init();
|
||||
D3D::InitUtils();
|
||||
|
||||
// VideoCommon
|
||||
BPInit();
|
||||
|
@ -296,10 +218,10 @@ void Video_Prepare()
|
|||
DLCache::Init();
|
||||
|
||||
// Tell the host that the window is ready
|
||||
g_VideoInitialize.pCoreMessage(WM_USER_CREATE);
|
||||
Core::Callback_CoreMessage(WM_USER_CREATE);
|
||||
}
|
||||
|
||||
void Shutdown()
|
||||
void VideoBackend::Shutdown()
|
||||
{
|
||||
s_PluginInitialized = false;
|
||||
|
||||
|
@ -317,9 +239,9 @@ void Shutdown()
|
|||
VertexLoaderManager::Shutdown();
|
||||
|
||||
// internal interfaces
|
||||
DX11::D3D::ShutdownUtils();
|
||||
DX11::PixelShaderCache::Shutdown();
|
||||
DX11::VertexShaderCache::Shutdown();
|
||||
D3D::ShutdownUtils();
|
||||
PixelShaderCache::Shutdown();
|
||||
VertexShaderCache::Shutdown();
|
||||
delete g_vertex_manager;
|
||||
delete g_texture_cache;
|
||||
delete g_renderer;
|
||||
|
@ -327,3 +249,5 @@ void Shutdown()
|
|||
|
||||
s_PluginInitialized = false;
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -18,10 +18,7 @@
|
|||
#ifndef MAIN_H
|
||||
#define MAIN_H
|
||||
|
||||
#include "PluginSpecs_Video.h"
|
||||
#include "Render.h"
|
||||
#include "MainBase.h"
|
||||
|
||||
extern SVideoInitialize g_VideoInitialize;
|
||||
|
||||
#endif
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
<VisualStudioProject
|
||||
ProjectType="Visual C++"
|
||||
Version="9.00"
|
||||
Name="Plugin_VideoDX9"
|
||||
Name="VideoDX9"
|
||||
ProjectGUID="{636FAD5F-02D1-4E9A-BE67-FB8EA99B9A18}"
|
||||
RootNamespace="Plugin_VideoDX9"
|
||||
TargetFrameworkVersion="131072"
|
||||
|
@ -22,7 +22,7 @@
|
|||
Name="Release|Win32"
|
||||
OutputDirectory="$(PlatformName)\$(ConfigurationName)"
|
||||
IntermediateDirectory="$(PlatformName)\$(ConfigurationName)"
|
||||
ConfigurationType="2"
|
||||
ConfigurationType="4"
|
||||
InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC71.vsprops"
|
||||
UseOfMFC="0"
|
||||
ATLMinimizesCRunTimeLibraryUsage="false"
|
||||
|
@ -58,7 +58,7 @@
|
|||
FavorSizeOrSpeed="1"
|
||||
OmitFramePointers="false"
|
||||
WholeProgramOptimization="true"
|
||||
AdditionalIncludeDirectories="../../../Externals;../../PluginSpecs;../../Core/Common/Src;../../Core/VideoCommon/Src;../../Core/VideoUICommon/Src;..\..\..\Externals\wxWidgets\Include;..\..\..\Externals\wxWidgets\Include\msvc"
|
||||
AdditionalIncludeDirectories="../../../Externals;../../PluginSpecs;../../Core/Common/Src;../../Core/Core/Src;../../Core/VideoCommon/Src;../../Core/VideoUICommon/Src;..\..\..\Externals\wxWidgets\Include;..\..\..\Externals\wxWidgets\Include\msvc"
|
||||
PreprocessorDefinitions="_WIN32;WIN32;NDEBUG;_WINDOWS;_USRDLL;VIDEO_DIRECTX9_EXPORTS;_CRT_SECURE_NO_DEPRECATE;_SECURE_SCL=0"
|
||||
StringPooling="true"
|
||||
RuntimeLibrary="0"
|
||||
|
@ -91,26 +91,11 @@
|
|||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLinkerTool"
|
||||
AdditionalOptions=""..\..\core\common\win32\release\common.lib""
|
||||
AdditionalDependencies="comctl32.lib winmm.lib vfw32.lib wxbase28u.lib wxmsw28u_core.lib"
|
||||
OutputFile="..\..\..\Binary\Win32\Plugins\Plugin_VideoDX9.dll"
|
||||
LinkIncremental="1"
|
||||
SuppressStartupBanner="true"
|
||||
AdditionalLibraryDirectories="../../../Externals/Cg;"..\..\..\Externals\wxWidgets\lib\vc_lib\$(PlatformName)""
|
||||
GenerateManifest="false"
|
||||
ProgramDatabaseFile="$(PlatformName)\$(ConfigurationName)\$(TargetName).pdb"
|
||||
RandomizedBaseAddress="1"
|
||||
DataExecutionPrevention="0"
|
||||
ImportLibrary="$(PlatformName)\$(ConfigurationName)\$(TargetName).lib"
|
||||
TargetMachine="1"
|
||||
Name="VCLibrarianTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManifestTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
|
@ -120,9 +105,6 @@
|
|||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCAppVerifierTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
/>
|
||||
|
@ -131,7 +113,7 @@
|
|||
Name="Release|x64"
|
||||
OutputDirectory="$(PlatformName)\$(ConfigurationName)"
|
||||
IntermediateDirectory="$(PlatformName)\$(ConfigurationName)"
|
||||
ConfigurationType="2"
|
||||
ConfigurationType="4"
|
||||
InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC71.vsprops"
|
||||
UseOfMFC="0"
|
||||
ATLMinimizesCRunTimeLibraryUsage="false"
|
||||
|
@ -168,7 +150,7 @@
|
|||
FavorSizeOrSpeed="1"
|
||||
OmitFramePointers="false"
|
||||
WholeProgramOptimization="true"
|
||||
AdditionalIncludeDirectories="../../../Externals;../../PluginSpecs;../../Core/Common/Src;../../Core/VideoCommon/Src;../../Core/VideoUICommon/Src;..\..\..\Externals\wxWidgets\Include;..\..\..\Externals\wxWidgets\Include\msvc"
|
||||
AdditionalIncludeDirectories="../../../Externals;../../PluginSpecs;../../Core/Common/Src;../../Core/Core/Src;../../Core/VideoCommon/Src;../../Core/VideoUICommon/Src;..\..\..\Externals\wxWidgets\Include;..\..\..\Externals\wxWidgets\Include\msvc"
|
||||
PreprocessorDefinitions="WIN32;NDEBUG;_WINDOWS;_USRDLL;VIDEO_DIRECTX9_EXPORTS;_CRT_SECURE_NO_DEPRECATE;_SECURE_SCL=0"
|
||||
StringPooling="true"
|
||||
ExceptionHandling="1"
|
||||
|
@ -202,27 +184,11 @@
|
|||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLinkerTool"
|
||||
AdditionalDependencies="comctl32.lib winmm.lib vfw32.lib rpcrt4.lib wxbase28u.lib wxmsw28u_core.lib"
|
||||
OutputFile="..\..\..\Binary\x64\Plugins\Plugin_VideoDX9.dll"
|
||||
LinkIncremental="1"
|
||||
SuppressStartupBanner="true"
|
||||
AdditionalLibraryDirectories="..\..\..\Externals\Cg64;"..\..\..\Externals\wxWidgets\lib\vc_lib\$(PlatformName)""
|
||||
GenerateManifest="false"
|
||||
GenerateDebugInformation="true"
|
||||
ProgramDatabaseFile="$(PlatformName)\$(ConfigurationName)\$(TargetName).pdb"
|
||||
SubSystem="2"
|
||||
RandomizedBaseAddress="1"
|
||||
DataExecutionPrevention="0"
|
||||
ImportLibrary="$(PlatformName)\$(ConfigurationName)\$(TargetName).lib"
|
||||
TargetMachine="17"
|
||||
Name="VCLibrarianTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManifestTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
|
@ -232,9 +198,6 @@
|
|||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCAppVerifierTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
/>
|
||||
|
@ -243,7 +206,7 @@
|
|||
Name="Debug|Win32"
|
||||
OutputDirectory="$(PlatformName)\$(ConfigurationName)"
|
||||
IntermediateDirectory="$(PlatformName)\$(ConfigurationName)"
|
||||
ConfigurationType="2"
|
||||
ConfigurationType="4"
|
||||
InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC71.vsprops"
|
||||
UseOfMFC="0"
|
||||
ATLMinimizesCRunTimeLibraryUsage="false"
|
||||
|
@ -273,7 +236,7 @@
|
|||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
Optimization="0"
|
||||
AdditionalIncludeDirectories="../../../Externals;../../PluginSpecs;../../Core/Common/Src;../../Core/VideoCommon/Src;../../Core/VideoUICommon/Src;..\..\..\Externals\wxWidgets\Include;..\..\..\Externals\wxWidgets\Include\msvc"
|
||||
AdditionalIncludeDirectories="../../../Externals;../../PluginSpecs;../../Core/Common/Src;../../Core/Core/Src;../../Core/VideoCommon/Src;../../Core/VideoUICommon/Src;..\..\..\Externals\wxWidgets\Include;..\..\..\Externals\wxWidgets\Include\msvc"
|
||||
PreprocessorDefinitions="_WIN32;WIN32;_DEBUG;_WINDOWS;_USRDLL;VIDEO_DIRECTX9_EXPORTS;_CRT_SECURE_NO_DEPRECATE;_SECURE_SCL=0"
|
||||
BasicRuntimeChecks="3"
|
||||
RuntimeLibrary="1"
|
||||
|
@ -301,27 +264,11 @@
|
|||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLinkerTool"
|
||||
AdditionalOptions=""..\..\core\common\win32\debug\common.lib""
|
||||
AdditionalDependencies="comctl32.lib winmm.lib vfw32.lib rpcrt4.lib wxbase28ud.lib wxmsw28ud_core.lib"
|
||||
OutputFile="..\..\..\Binary\Win32/Plugins\Plugin_VideoDX9D.dll"
|
||||
LinkIncremental="1"
|
||||
SuppressStartupBanner="true"
|
||||
AdditionalLibraryDirectories="../../../Externals/Cg;"..\..\..\Externals\wxWidgets\lib\vc_lib\$(PlatformName)""
|
||||
GenerateManifest="false"
|
||||
GenerateDebugInformation="true"
|
||||
ProgramDatabaseFile="$(PlatformName)\$(ConfigurationName)\$(TargetName).pdb"
|
||||
RandomizedBaseAddress="1"
|
||||
DataExecutionPrevention="0"
|
||||
ImportLibrary="$(PlatformName)\$(ConfigurationName)\$(TargetName).lib"
|
||||
TargetMachine="1"
|
||||
Name="VCLibrarianTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManifestTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
|
@ -331,9 +278,6 @@
|
|||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCAppVerifierTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
/>
|
||||
|
@ -342,7 +286,7 @@
|
|||
Name="Debug|x64"
|
||||
OutputDirectory="$(PlatformName)\$(ConfigurationName)"
|
||||
IntermediateDirectory="$(PlatformName)\$(ConfigurationName)"
|
||||
ConfigurationType="2"
|
||||
ConfigurationType="4"
|
||||
InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC71.vsprops"
|
||||
UseOfMFC="0"
|
||||
ATLMinimizesCRunTimeLibraryUsage="false"
|
||||
|
@ -372,7 +316,7 @@
|
|||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
Optimization="0"
|
||||
AdditionalIncludeDirectories="../../../Externals;../../PluginSpecs;../../Core/Common/Src;../../Core/VideoCommon/Src;../../Core/VideoUICommon/Src;..\..\..\Externals\wxWidgets\Include;..\..\..\Externals\wxWidgets\Include\msvc"
|
||||
AdditionalIncludeDirectories="../../../Externals;../../PluginSpecs;../../Core/Common/Src;../../Core/Core/Src;../../Core/VideoCommon/Src;../../Core/VideoUICommon/Src;..\..\..\Externals\wxWidgets\Include;..\..\..\Externals\wxWidgets\Include\msvc"
|
||||
PreprocessorDefinitions="WIN32;_DEBUG;_WINDOWS;_USRDLL;VIDEO_DIRECTX9_EXPORTS;_CRT_SECURE_NO_DEPRECATE;_SECURE_SCL=0"
|
||||
BasicRuntimeChecks="3"
|
||||
RuntimeLibrary="1"
|
||||
|
@ -400,26 +344,11 @@
|
|||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLinkerTool"
|
||||
AdditionalDependencies="comctl32.lib winmm.lib vfw32.lib rpcrt4.lib wxbase28ud.lib wxmsw28ud_core.lib"
|
||||
OutputFile="..\..\..\Binary\x64\Plugins\Plugin_VideoDX9D.dll"
|
||||
LinkIncremental="1"
|
||||
SuppressStartupBanner="true"
|
||||
AdditionalLibraryDirectories="..\..\..\Externals\Cg64;"..\..\..\Externals\wxWidgets\lib\vc_lib\$(PlatformName)""
|
||||
GenerateManifest="false"
|
||||
GenerateDebugInformation="true"
|
||||
ProgramDatabaseFile="$(PlatformName)\$(ConfigurationName)\$(TargetName).pdb"
|
||||
RandomizedBaseAddress="1"
|
||||
DataExecutionPrevention="0"
|
||||
ImportLibrary="$(PlatformName)\$(ConfigurationName)\$(TargetName).lib"
|
||||
TargetMachine="17"
|
||||
Name="VCLibrarianTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManifestTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
|
@ -429,9 +358,6 @@
|
|||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCAppVerifierTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
/>
|
||||
|
@ -440,7 +366,7 @@
|
|||
Name="DebugFast|Win32"
|
||||
OutputDirectory="$(PlatformName)\$(ConfigurationName)"
|
||||
IntermediateDirectory="$(PlatformName)\$(ConfigurationName)"
|
||||
ConfigurationType="2"
|
||||
ConfigurationType="4"
|
||||
InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC71.vsprops"
|
||||
UseOfMFC="0"
|
||||
ATLMinimizesCRunTimeLibraryUsage="false"
|
||||
|
@ -476,7 +402,7 @@
|
|||
FavorSizeOrSpeed="1"
|
||||
OmitFramePointers="false"
|
||||
WholeProgramOptimization="true"
|
||||
AdditionalIncludeDirectories="../../../Externals;../../PluginSpecs;../../Core/Common/Src;../../Core/VideoCommon/Src;../../Core/VideoUICommon/Src;..\..\..\Externals\wxWidgets\Include;..\..\..\Externals\wxWidgets\Include\msvc"
|
||||
AdditionalIncludeDirectories="../../../Externals;../../PluginSpecs;../../Core/Common/Src;../../Core/Core/Src;../../Core/VideoCommon/Src;../../Core/VideoUICommon/Src;..\..\..\Externals\wxWidgets\Include;..\..\..\Externals\wxWidgets\Include\msvc"
|
||||
PreprocessorDefinitions="_WIN32;WIN32;NDEBUG;_WINDOWS;_USRDLL;VIDEO_DIRECTX9_EXPORTS;_CRT_SECURE_NO_DEPRECATE;_SECURE_SCL=0;DEBUGFAST"
|
||||
StringPooling="true"
|
||||
RuntimeLibrary="0"
|
||||
|
@ -508,27 +434,11 @@
|
|||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLinkerTool"
|
||||
AdditionalDependencies="comctl32.lib winmm.lib vfw32.lib wxbase28u.lib wxmsw28u_core.lib"
|
||||
OutputFile="..\..\..\Binary\Win32\Plugins\Plugin_VideoDX9DF.dll"
|
||||
LinkIncremental="1"
|
||||
SuppressStartupBanner="true"
|
||||
AdditionalLibraryDirectories="../../../Externals/Cg;"..\..\..\Externals\wxWidgets\lib\vc_lib\$(PlatformName)""
|
||||
GenerateManifest="false"
|
||||
IgnoreDefaultLibraryNames=""
|
||||
GenerateDebugInformation="true"
|
||||
ProgramDatabaseFile="$(PlatformName)\$(ConfigurationName)\$(TargetName).pdb"
|
||||
RandomizedBaseAddress="1"
|
||||
DataExecutionPrevention="0"
|
||||
ImportLibrary="$(PlatformName)\$(ConfigurationName)\$(TargetName).lib"
|
||||
TargetMachine="1"
|
||||
Name="VCLibrarianTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManifestTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
|
@ -538,9 +448,6 @@
|
|||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCAppVerifierTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
/>
|
||||
|
@ -549,7 +456,7 @@
|
|||
Name="DebugFast|x64"
|
||||
OutputDirectory="$(PlatformName)\$(ConfigurationName)"
|
||||
IntermediateDirectory="$(PlatformName)\$(ConfigurationName)"
|
||||
ConfigurationType="2"
|
||||
ConfigurationType="4"
|
||||
InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC71.vsprops"
|
||||
UseOfMFC="0"
|
||||
ATLMinimizesCRunTimeLibraryUsage="false"
|
||||
|
@ -586,7 +493,7 @@
|
|||
FavorSizeOrSpeed="1"
|
||||
OmitFramePointers="false"
|
||||
WholeProgramOptimization="true"
|
||||
AdditionalIncludeDirectories="../../../Externals;../../PluginSpecs;../../Core/Common/Src;../../Core/VideoCommon/Src;../../Core/VideoUICommon/Src;..\..\..\Externals\wxWidgets\Include;..\..\..\Externals\wxWidgets\Include\msvc"
|
||||
AdditionalIncludeDirectories="../../../Externals;../../PluginSpecs;../../Core/Common/Src;../../Core/Core/Src;../../Core/VideoCommon/Src;../../Core/VideoUICommon/Src;..\..\..\Externals\wxWidgets\Include;..\..\..\Externals\wxWidgets\Include\msvc"
|
||||
PreprocessorDefinitions="WIN32;NDEBUG;_WINDOWS;_USRDLL;VIDEO_DIRECTX9_EXPORTS;_CRT_SECURE_NO_DEPRECATE;_SECURE_SCL=0;;DEBUGFAST"
|
||||
StringPooling="true"
|
||||
ExceptionHandling="1"
|
||||
|
@ -619,26 +526,11 @@
|
|||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLinkerTool"
|
||||
AdditionalDependencies="comctl32.lib winmm.lib vfw32.lib rpcrt4.lib wxbase28u.lib wxmsw28u_core.lib"
|
||||
OutputFile="..\..\..\Binary\x64\Plugins\Plugin_VideoDX9DF.dll"
|
||||
LinkIncremental="1"
|
||||
SuppressStartupBanner="true"
|
||||
AdditionalLibraryDirectories="..\..\..\Externals\Cg64;"..\..\..\Externals\wxWidgets\lib\vc_lib\$(PlatformName)""
|
||||
GenerateManifest="false"
|
||||
GenerateDebugInformation="true"
|
||||
ProgramDatabaseFile="$(PlatformName)\$(ConfigurationName)\$(TargetName).pdb"
|
||||
RandomizedBaseAddress="1"
|
||||
DataExecutionPrevention="0"
|
||||
ImportLibrary="$(PlatformName)\$(ConfigurationName)\$(TargetName).lib"
|
||||
TargetMachine="17"
|
||||
Name="VCLibrarianTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManifestTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
|
@ -648,9 +540,6 @@
|
|||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCAppVerifierTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
/>
|
||||
|
|
|
@ -29,38 +29,39 @@
|
|||
<PropertyGroup Label="Globals">
|
||||
<ProjectGuid>{DC7D7AF4-CE47-49E8-8B63-265CB6233A49}</ProjectGuid>
|
||||
<RootNamespace>Plugin_VideoDX9</RootNamespace>
|
||||
<ProjectName>VideoDX9</ProjectName>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
|
||||
<ConfigurationType>DynamicLibrary</ConfigurationType>
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>true</UseDebugLibraries>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">
|
||||
<ConfigurationType>DynamicLibrary</ConfigurationType>
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>true</UseDebugLibraries>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
|
||||
<ConfigurationType>DynamicLibrary</ConfigurationType>
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>false</UseDebugLibraries>
|
||||
<WholeProgramOptimization>true</WholeProgramOptimization>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='DebugFast|Win32'" Label="Configuration">
|
||||
<ConfigurationType>DynamicLibrary</ConfigurationType>
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>false</UseDebugLibraries>
|
||||
<WholeProgramOptimization>true</WholeProgramOptimization>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
|
||||
<ConfigurationType>DynamicLibrary</ConfigurationType>
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>false</UseDebugLibraries>
|
||||
<WholeProgramOptimization>true</WholeProgramOptimization>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='DebugFast|x64'" Label="Configuration">
|
||||
<ConfigurationType>DynamicLibrary</ConfigurationType>
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>false</UseDebugLibraries>
|
||||
<WholeProgramOptimization>true</WholeProgramOptimization>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
|
@ -131,7 +132,7 @@
|
|||
<ClCompile>
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
<Optimization>Disabled</Optimization>
|
||||
<AdditionalIncludeDirectories>..\..\Core\Common\Src;..\..\PluginSpecs;..\..\Core\VideoCommon\Src;..\..\Core\VideoUICommon\Src;..\..\..\Externals\wxWidgets\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<AdditionalIncludeDirectories>..\..\Core\Common\Src;..\..\Core\Core\Src;..\..\PluginSpecs;..\..\Core\VideoCommon\Src;..\..\Core\VideoUICommon\Src;..\..\..\Externals\wxWidgets\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<PreprocessorDefinitions>_SECURE_SCL=0;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<RuntimeLibrary>MultiThreadedDebug</RuntimeLibrary>
|
||||
<ForcedIncludeFiles>stdafx.h</ForcedIncludeFiles>
|
||||
|
@ -146,7 +147,7 @@
|
|||
<ClCompile>
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
<Optimization>Disabled</Optimization>
|
||||
<AdditionalIncludeDirectories>..\..\Core\Common\Src;..\..\PluginSpecs;..\..\Core\VideoCommon\Src;..\..\Core\VideoUICommon\Src;..\..\..\Externals\wxWidgets\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<AdditionalIncludeDirectories>..\..\Core\Common\Src;..\..\Core\Core\Src;..\..\PluginSpecs;..\..\Core\VideoCommon\Src;..\..\Core\VideoUICommon\Src;..\..\..\Externals\wxWidgets\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<PreprocessorDefinitions>_SECURE_SCL=0;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<RuntimeLibrary>MultiThreadedDebug</RuntimeLibrary>
|
||||
<ForcedIncludeFiles>stdafx.h</ForcedIncludeFiles>
|
||||
|
@ -163,7 +164,7 @@
|
|||
<Optimization>MaxSpeed</Optimization>
|
||||
<FunctionLevelLinking>true</FunctionLevelLinking>
|
||||
<IntrinsicFunctions>true</IntrinsicFunctions>
|
||||
<AdditionalIncludeDirectories>..\..\Core\Common\Src;..\..\PluginSpecs;..\..\Core\VideoCommon\Src;..\..\Core\VideoUICommon\Src;..\..\..\Externals\wxWidgets\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<AdditionalIncludeDirectories>..\..\Core\Common\Src;..\..\Core\Core\Src;..\..\PluginSpecs;..\..\Core\VideoCommon\Src;..\..\Core\VideoUICommon\Src;..\..\..\Externals\wxWidgets\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<PreprocessorDefinitions>_SECURE_SCL=0;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<RuntimeLibrary>MultiThreaded</RuntimeLibrary>
|
||||
<ForcedIncludeFiles>stdafx.h</ForcedIncludeFiles>
|
||||
|
@ -182,7 +183,7 @@
|
|||
<Optimization>MaxSpeed</Optimization>
|
||||
<FunctionLevelLinking>true</FunctionLevelLinking>
|
||||
<IntrinsicFunctions>true</IntrinsicFunctions>
|
||||
<AdditionalIncludeDirectories>..\..\Core\Common\Src;..\..\PluginSpecs;..\..\Core\VideoCommon\Src;..\..\Core\VideoUICommon\Src;..\..\..\Externals\wxWidgets\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<AdditionalIncludeDirectories>..\..\Core\Common\Src;..\..\Core\Core\Src;..\..\PluginSpecs;..\..\Core\VideoCommon\Src;..\..\Core\VideoUICommon\Src;..\..\..\Externals\wxWidgets\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<PreprocessorDefinitions>DEBUGFAST;_SECURE_SCL=0;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<RuntimeLibrary>MultiThreaded</RuntimeLibrary>
|
||||
<ForcedIncludeFiles>stdafx.h</ForcedIncludeFiles>
|
||||
|
@ -201,7 +202,7 @@
|
|||
<Optimization>MaxSpeed</Optimization>
|
||||
<FunctionLevelLinking>true</FunctionLevelLinking>
|
||||
<IntrinsicFunctions>true</IntrinsicFunctions>
|
||||
<AdditionalIncludeDirectories>..\..\Core\Common\Src;..\..\PluginSpecs;..\..\Core\VideoCommon\Src;..\..\Core\VideoUICommon\Src;..\..\..\Externals\wxWidgets\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<AdditionalIncludeDirectories>..\..\Core\Common\Src;..\..\Core\Core\Src;..\..\PluginSpecs;..\..\Core\VideoCommon\Src;..\..\Core\VideoUICommon\Src;..\..\..\Externals\wxWidgets\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<PreprocessorDefinitions>_SECURE_SCL=0;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<RuntimeLibrary>MultiThreaded</RuntimeLibrary>
|
||||
<ForcedIncludeFiles>stdafx.h</ForcedIncludeFiles>
|
||||
|
@ -220,7 +221,7 @@
|
|||
<Optimization>MaxSpeed</Optimization>
|
||||
<FunctionLevelLinking>true</FunctionLevelLinking>
|
||||
<IntrinsicFunctions>true</IntrinsicFunctions>
|
||||
<AdditionalIncludeDirectories>..\..\Core\Common\Src;..\..\PluginSpecs;..\..\Core\VideoCommon\Src;..\..\Core\VideoUICommon\Src;..\..\..\Externals\wxWidgets\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<AdditionalIncludeDirectories>..\..\Core\Common\Src;..\..\Core\Core\Src;..\..\PluginSpecs;..\..\Core\VideoCommon\Src;..\..\Core\VideoUICommon\Src;..\..\..\Externals\wxWidgets\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<PreprocessorDefinitions>DEBUGFAST;_SECURE_SCL=0;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<RuntimeLibrary>MultiThreaded</RuntimeLibrary>
|
||||
<ForcedIncludeFiles>stdafx.h</ForcedIncludeFiles>
|
||||
|
@ -279,6 +280,7 @@
|
|||
<ClInclude Include="Src\TextureConverter.h" />
|
||||
<ClInclude Include="Src\VertexManager.h" />
|
||||
<ClInclude Include="Src\VertexShaderCache.h" />
|
||||
<ClInclude Include="Src\VideoBackend.h" />
|
||||
</ItemGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
|
||||
<ImportGroup Label="ExtensionTargets">
|
||||
|
|
|
@ -22,6 +22,7 @@
|
|||
#include "PixelShaderCache.h"
|
||||
#include "VertexShaderCache.h"
|
||||
#include "TextureConverter.h"
|
||||
#include "HW/Memmap.h"
|
||||
|
||||
namespace DX9
|
||||
{
|
||||
|
@ -176,7 +177,7 @@ void XFBSource::DecodeToTexture(u32 xfbAddr, u32 fbWidth, u32 fbHeight)
|
|||
|
||||
void FramebufferManager::CopyToRealXFB(u32 xfbAddr, u32 fbWidth, u32 fbHeight, const EFBRectangle& sourceRc,float Gamma)
|
||||
{
|
||||
u8* xfb_in_ram = Memory_GetPtr(xfbAddr);
|
||||
u8* xfb_in_ram = Memory::GetPointer(xfbAddr);
|
||||
if (!xfb_in_ram)
|
||||
{
|
||||
WARN_LOG(VIDEO, "Tried to copy to invalid XFB address");
|
||||
|
|
|
@ -23,9 +23,5 @@
|
|||
#include "main.h"
|
||||
|
||||
#include "VideoCommon.h"
|
||||
#include "pluginspecs_video.h"
|
||||
|
||||
// A global plugin specification
|
||||
extern PLUGIN_GLOBALS* globals;
|
||||
|
||||
#endif // _GLOBALS_H_
|
|
@ -27,6 +27,9 @@
|
|||
#include "NativeVertexFormat.h"
|
||||
#include "VertexManager.h"
|
||||
|
||||
namespace DX9
|
||||
{
|
||||
|
||||
class D3DVertexFormat : public NativeVertexFormat
|
||||
{
|
||||
LPDIRECT3DVERTEXDECLARATION9 d3d_decl;
|
||||
|
@ -43,16 +46,11 @@ public:
|
|||
#endif
|
||||
};
|
||||
|
||||
namespace DX9
|
||||
{
|
||||
|
||||
NativeVertexFormat* VertexManager::CreateNativeVertexFormat()
|
||||
{
|
||||
return new D3DVertexFormat();
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
void DX9::VertexManager::GetElements(NativeVertexFormat* format, D3DVERTEXELEMENT9** elems, int* num)
|
||||
{
|
||||
#if defined(_DEBUG) || defined(DEBUGFAST)
|
||||
|
@ -191,3 +189,5 @@ void D3DVertexFormat::SetupVertexPointers()
|
|||
else
|
||||
ERROR_LOG(VIDEO, "invalid d3d decl");
|
||||
}
|
||||
|
||||
} // namespace DX9
|
||||
|
|
|
@ -36,6 +36,7 @@
|
|||
#include "XFMemory.h"
|
||||
#include "ImageWrite.h"
|
||||
#include "Debugger.h"
|
||||
#include "ConfigManager.h"
|
||||
|
||||
namespace DX9
|
||||
{
|
||||
|
@ -274,7 +275,7 @@ void PixelShaderCache::Init()
|
|||
SETSTAT(stats.numPixelShadersAlive, 0);
|
||||
|
||||
char cache_filename[MAX_PATH];
|
||||
sprintf(cache_filename, "%sdx9-%s-ps.cache", File::GetUserPath(D_SHADERCACHE_IDX), globals->unique_id);
|
||||
sprintf(cache_filename, "%sdx9-%s-ps.cache", File::GetUserPath(D_SHADERCACHE_IDX), SConfig::GetInstance().m_LocalCoreStartupParameter.m_strUniqueID.c_str());
|
||||
PixelShaderCacheInserter inserter;
|
||||
g_ps_disk_cache.OpenAndRead(cache_filename, inserter);
|
||||
}
|
||||
|
@ -418,21 +419,20 @@ bool PixelShaderCache::InsertByteCode(const PIXELSHADERUID &uid, const u8 *bytec
|
|||
return true;
|
||||
}
|
||||
|
||||
} // namespace DX9
|
||||
|
||||
|
||||
void SetPSConstant4f(unsigned int const_number, float f1, float f2, float f3, float f4)
|
||||
void Renderer::SetPSConstant4f(unsigned int const_number, float f1, float f2, float f3, float f4)
|
||||
{
|
||||
float f[4] = { f1, f2, f3, f4 };
|
||||
DX9::D3D::dev->SetPixelShaderConstantF(const_number, f, 1);
|
||||
}
|
||||
|
||||
void SetPSConstant4fv(unsigned int const_number, const float *f)
|
||||
void Renderer::SetPSConstant4fv(unsigned int const_number, const float *f)
|
||||
{
|
||||
DX9::D3D::dev->SetPixelShaderConstantF(const_number, f, 1);
|
||||
}
|
||||
|
||||
void SetMultiPSConstant4fv(unsigned int const_number, unsigned int count, const float *f)
|
||||
void Renderer::SetMultiPSConstant4fv(unsigned int const_number, unsigned int count, const float *f)
|
||||
{
|
||||
DX9::D3D::dev->SetPixelShaderConstantF(const_number, f, count);
|
||||
}
|
||||
|
||||
} // namespace DX9
|
||||
|
|
|
@ -50,6 +50,7 @@
|
|||
#include "TextureConverter.h"
|
||||
#include "DLCache.h"
|
||||
#include "Debugger.h"
|
||||
#include "Core.h"
|
||||
|
||||
namespace DX9
|
||||
{
|
||||
|
@ -256,7 +257,7 @@ Renderer::Renderer()
|
|||
// Multisample Anti-aliasing hasn't been implemented yet use supersamling instead
|
||||
int backbuffer_ms_mode = 0;
|
||||
|
||||
g_VideoInitialize.pGetWindowSize(x, y, w_temp, h_temp);
|
||||
Core::Callback_VideoGetWindowSize(x, y, w_temp, h_temp);
|
||||
|
||||
for (fullScreenRes = 0; fullScreenRes < (int)D3D::GetAdapter(g_ActiveConfig.iAdapter).resolutions.size(); fullScreenRes++)
|
||||
{
|
||||
|
@ -433,7 +434,7 @@ void Renderer::SetWindowSize(int width, int height)
|
|||
// Scale the window size by the EFB scale.
|
||||
CalculateTargetScale(width, height, width, height);
|
||||
|
||||
g_VideoInitialize.pRequestWindowSize(width, height);
|
||||
Core::Callback_VideoRequestWindowSize(width, height);
|
||||
}
|
||||
|
||||
bool Renderer::SetScissorRect()
|
||||
|
@ -920,7 +921,7 @@ void Renderer::Swap(u32 xfbAddr, FieldType field, u32 fbWidth, u32 fbHeight,cons
|
|||
{
|
||||
if (g_bSkipCurrentFrame || (!XFBWrited && (!g_ActiveConfig.bUseXFB || !g_ActiveConfig.bUseRealXFB)) || !fbWidth || !fbHeight)
|
||||
{
|
||||
g_VideoInitialize.pCopiedToXFB(false);
|
||||
Core::Callback_VideoCopiedToXFB(false);
|
||||
return;
|
||||
}
|
||||
// this function is called after the XFB field is changed, not after
|
||||
|
@ -932,7 +933,7 @@ void Renderer::Swap(u32 xfbAddr, FieldType field, u32 fbWidth, u32 fbHeight,cons
|
|||
const XFBSourceBase* const* xfbSourceList = FramebufferManager::GetXFBSource(xfbAddr, fbWidth, fbHeight, xfbCount);
|
||||
if ((!xfbSourceList || xfbCount == 0) && g_ActiveConfig.bUseXFB && !g_ActiveConfig.bUseRealXFB)
|
||||
{
|
||||
g_VideoInitialize.pCopiedToXFB(false);
|
||||
Core::Callback_VideoCopiedToXFB(false);
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -1256,7 +1257,7 @@ void Renderer::Swap(u32 xfbAddr, FieldType field, u32 fbWidth, u32 fbHeight,cons
|
|||
// Renderer::SetZBufferRender();
|
||||
// SaveTexture("tex.tga", GL_TEXTURE_RECTANGLE_ARB, s_FakeZTarget,
|
||||
// GetTargetWidth(), GetTargetHeight());
|
||||
g_VideoInitialize.pCopiedToXFB(XFBWrited || (g_ActiveConfig.bUseXFB && g_ActiveConfig.bUseRealXFB));
|
||||
Core::Callback_VideoCopiedToXFB(XFBWrited || (g_ActiveConfig.bUseXFB && g_ActiveConfig.bUseRealXFB));
|
||||
XFBWrited = false;
|
||||
}
|
||||
|
||||
|
|
|
@ -48,6 +48,15 @@ public:
|
|||
|
||||
static bool CheckForResize();
|
||||
static void SetWindowSize(int width, int height);
|
||||
|
||||
void SetPSConstant4f(unsigned int const_number, float f1, float f2, float f3, float f4);
|
||||
void SetPSConstant4fv(unsigned int const_number, const float *f);
|
||||
void SetMultiPSConstant4fv(unsigned int const_number, unsigned int count, const float *f);
|
||||
|
||||
void SetVSConstant4f(unsigned int const_number, float f1, float f2, float f3, float f4);
|
||||
void SetVSConstant4fv(unsigned int const_number, const float *f);
|
||||
void SetMultiVSConstant3fv(unsigned int const_number, unsigned int count, const float *f);
|
||||
void SetMultiVSConstant4fv(unsigned int const_number, unsigned int count, const float *f);
|
||||
};
|
||||
|
||||
} // namespace DX9
|
||||
|
|
|
@ -31,6 +31,7 @@
|
|||
#include "TextureCache.h"
|
||||
#include "Math.h"
|
||||
#include "FileUtil.h"
|
||||
#include "HW/Memmap.h"
|
||||
|
||||
namespace DX9
|
||||
{
|
||||
|
@ -339,7 +340,7 @@ void EncodeToRam(u32 address, bool bFromZBuffer, bool bIsIntensityFmt, u32 copyf
|
|||
if (!texconv_shader)
|
||||
return;
|
||||
|
||||
u8 *dest_ptr = Memory_GetPtr(address);
|
||||
u8 *dest_ptr = Memory::GetPointer(address);
|
||||
|
||||
LPDIRECT3DTEXTURE9 source_texture = bFromZBuffer ? FramebufferManager::GetEFBDepthTexture() : FramebufferManager::GetEFBColorTexture();
|
||||
int width = (source.right - source.left) >> bScaleByHalf;
|
||||
|
@ -408,7 +409,7 @@ u64 EncodeToRamFromTexture(u32 address,LPDIRECT3DTEXTURE9 source_texture, u32 So
|
|||
if (!texconv_shader)
|
||||
return 0;
|
||||
|
||||
u8 *dest_ptr = Memory_GetPtr(address);
|
||||
u8 *dest_ptr = Memory::GetPointer(address);
|
||||
|
||||
int width = (source.right - source.left) >> bScaleByHalf;
|
||||
int height = (source.bottom - source.top) >> bScaleByHalf;
|
||||
|
@ -480,7 +481,7 @@ void EncodeToRamYUYV(LPDIRECT3DTEXTURE9 srcTexture, const TargetRectangle& sourc
|
|||
// Should be scale free.
|
||||
void DecodeToTexture(u32 xfbAddr, int srcWidth, int srcHeight, LPDIRECT3DTEXTURE9 destTexture)
|
||||
{
|
||||
u8* srcAddr = Memory_GetPtr(xfbAddr);
|
||||
u8* srcAddr = Memory::GetPointer(xfbAddr);
|
||||
if (!srcAddr)
|
||||
{
|
||||
WARN_LOG(VIDEO, "Tried to decode from invalid memory address");
|
||||
|
|
|
@ -31,6 +31,7 @@
|
|||
#include "BPMemory.h"
|
||||
#include "XFMemory.h"
|
||||
#include "Debugger.h"
|
||||
#include "ConfigManager.h"
|
||||
|
||||
namespace DX9
|
||||
{
|
||||
|
@ -146,7 +147,7 @@ void VertexShaderCache::Init()
|
|||
SETSTAT(stats.numVertexShadersAlive, 0);
|
||||
|
||||
char cache_filename[MAX_PATH];
|
||||
sprintf(cache_filename, "%sdx9-%s-vs.cache", File::GetUserPath(D_SHADERCACHE_IDX), globals->unique_id);
|
||||
sprintf(cache_filename, "%sdx9-%s-vs.cache", File::GetUserPath(D_SHADERCACHE_IDX), SConfig::GetInstance().m_LocalCoreStartupParameter.m_strUniqueID.c_str());
|
||||
VertexShaderCacheInserter inserter;
|
||||
g_vs_disk_cache.OpenAndRead(cache_filename, inserter);
|
||||
}
|
||||
|
@ -246,21 +247,18 @@ bool VertexShaderCache::InsertByteCode(const VERTEXSHADERUID &uid, const u8 *byt
|
|||
return false;
|
||||
}
|
||||
|
||||
} // namespace DX9
|
||||
|
||||
|
||||
void SetVSConstant4f(unsigned int const_number, float f1, float f2, float f3, float f4)
|
||||
void Renderer::SetVSConstant4f(unsigned int const_number, float f1, float f2, float f3, float f4)
|
||||
{
|
||||
const float f[4] = { f1, f2, f3, f4 };
|
||||
DX9::D3D::dev->SetVertexShaderConstantF(const_number, f, 1);
|
||||
}
|
||||
|
||||
void SetVSConstant4fv(unsigned int const_number, const float *f)
|
||||
void Renderer::SetVSConstant4fv(unsigned int const_number, const float *f)
|
||||
{
|
||||
DX9::D3D::dev->SetVertexShaderConstantF(const_number, f, 1);
|
||||
}
|
||||
|
||||
void SetMultiVSConstant3fv(unsigned int const_number, unsigned int count, const float *f)
|
||||
void Renderer::SetMultiVSConstant3fv(unsigned int const_number, unsigned int count, const float *f)
|
||||
{
|
||||
float buf[4*C_VENVCONST_END];
|
||||
for (unsigned int i = 0; i < count; i++)
|
||||
|
@ -273,7 +271,9 @@ void SetMultiVSConstant3fv(unsigned int const_number, unsigned int count, const
|
|||
DX9::D3D::dev->SetVertexShaderConstantF(const_number, buf, count);
|
||||
}
|
||||
|
||||
void SetMultiVSConstant4fv(unsigned int const_number, unsigned int count, const float *f)
|
||||
void Renderer::SetMultiVSConstant4fv(unsigned int const_number, unsigned int count, const float *f)
|
||||
{
|
||||
DX9::D3D::dev->SetVertexShaderConstantF(const_number, f, count);
|
||||
}
|
||||
|
||||
} // namespace DX9
|
||||
|
|
27
Source/Plugins/Plugin_VideoDX9/Src/VideoBackend.h
Normal file
27
Source/Plugins/Plugin_VideoDX9/Src/VideoBackend.h
Normal file
|
@ -0,0 +1,27 @@
|
|||
|
||||
#ifndef DX9_VIDEO_BACKEND_H_
|
||||
#define DX9_VIDEO_BACKEND_H_
|
||||
|
||||
#include "VideoBackendBase.h"
|
||||
|
||||
namespace DX9
|
||||
{
|
||||
|
||||
class VideoBackend : public VideoBackendHLE
|
||||
{
|
||||
void Initialize();
|
||||
void Shutdown();
|
||||
|
||||
std::string GetName();
|
||||
|
||||
void Video_Prepare();
|
||||
|
||||
void ShowConfig(void* parent);
|
||||
|
||||
void UpdateFPSDisplay(const char*);
|
||||
unsigned int PeekMessages();
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
#endif
|
|
@ -53,84 +53,20 @@
|
|||
#include "render.h"
|
||||
#include "DLCache.h"
|
||||
#include "IniFile.h"
|
||||
#include "Core.h"
|
||||
|
||||
HINSTANCE g_hInstance = NULL;
|
||||
#include "ConfigManager.h"
|
||||
#include "VideoBackend.h"
|
||||
|
||||
wxLocale *InitLanguageSupport()
|
||||
namespace DX9
|
||||
{
|
||||
wxLocale *m_locale;
|
||||
unsigned int language = 0;
|
||||
|
||||
IniFile ini;
|
||||
ini.Load(File::GetUserPath(F_DOLPHINCONFIG_IDX));
|
||||
ini.Get("Interface", "Language", &language, wxLANGUAGE_DEFAULT);
|
||||
|
||||
// Load language if possible, fall back to system default otherwise
|
||||
if(wxLocale::IsAvailable(language))
|
||||
{
|
||||
m_locale = new wxLocale(language);
|
||||
|
||||
m_locale->AddCatalogLookupPathPrefix(wxT("Languages"));
|
||||
|
||||
m_locale->AddCatalog(wxT("dolphin-emu"));
|
||||
|
||||
if(!m_locale->IsOk())
|
||||
{
|
||||
PanicAlertT("Error loading selected language. Falling back to system default.");
|
||||
delete m_locale;
|
||||
m_locale = new wxLocale(wxLANGUAGE_DEFAULT);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
PanicAlertT("The selected language is not supported by your system. Falling back to system default.");
|
||||
m_locale = new wxLocale(wxLANGUAGE_DEFAULT);
|
||||
}
|
||||
return m_locale;
|
||||
void*& VideoWindowHandle()
|
||||
{
|
||||
return SConfig::GetInstance().m_LocalCoreStartupParameter.hMainWindow;
|
||||
}
|
||||
|
||||
|
||||
// This is used for the functions right below here which use wxwidgets
|
||||
WXDLLIMPEXP_BASE void wxSetInstance(HINSTANCE hInst);
|
||||
|
||||
void *DllDebugger(void *_hParent, bool Show)
|
||||
{
|
||||
return new GFXDebuggerPanel((wxWindow*)_hParent);
|
||||
}
|
||||
|
||||
class wxDLLApp : public wxApp
|
||||
{
|
||||
bool OnInit()
|
||||
{
|
||||
return true;
|
||||
}
|
||||
};
|
||||
IMPLEMENT_APP_NO_MAIN(wxDLLApp)
|
||||
WXDLLIMPEXP_BASE void wxSetInstance(HINSTANCE hInst);
|
||||
|
||||
BOOL APIENTRY DllMain(HINSTANCE hinstDLL, DWORD dwReason, LPVOID lpvReserved)
|
||||
{
|
||||
static wxLocale *m_locale;
|
||||
switch (dwReason)
|
||||
{
|
||||
case DLL_PROCESS_ATTACH:
|
||||
{
|
||||
wxSetInstance((HINSTANCE)hinstDLL);
|
||||
wxInitialize();
|
||||
m_locale = InitLanguageSupport();
|
||||
}
|
||||
break;
|
||||
case DLL_PROCESS_DETACH:
|
||||
wxUninitialize();
|
||||
delete m_locale;
|
||||
break;
|
||||
}
|
||||
|
||||
g_hInstance = hinstDLL;
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
unsigned int Callback_PeekMessages()
|
||||
unsigned int VideoBackend::PeekMessages()
|
||||
{
|
||||
MSG msg;
|
||||
while (PeekMessage(&msg, 0, 0, 0, PM_REMOVE))
|
||||
|
@ -143,36 +79,29 @@ unsigned int Callback_PeekMessages()
|
|||
return TRUE;
|
||||
}
|
||||
|
||||
|
||||
void UpdateFPSDisplay(const char *text)
|
||||
void VideoBackend::UpdateFPSDisplay(const char *text)
|
||||
{
|
||||
TCHAR temp[512];
|
||||
swprintf_s(temp, sizeof(temp)/sizeof(TCHAR), _T("%hs | DX9 | %hs"), svn_rev_str, text);
|
||||
SetWindowText(EmuWindow::GetWnd(), temp);
|
||||
}
|
||||
|
||||
void GetDllInfo(PLUGIN_INFO* _PluginInfo)
|
||||
{
|
||||
_PluginInfo->Version = 0x0100;
|
||||
_PluginInfo->Type = PLUGIN_TYPE_VIDEO;
|
||||
#ifdef DEBUGFAST
|
||||
sprintf_s(_PluginInfo->Name, 100, "Dolphin Direct3D9 (DebugFast)");
|
||||
#elif defined _DEBUG
|
||||
sprintf_s(_PluginInfo->Name, 100, "Dolphin Direct3D9 (Debug)");
|
||||
#else
|
||||
sprintf_s(_PluginInfo->Name, 100, "Dolphin Direct3D9");
|
||||
#endif
|
||||
}
|
||||
//void GetDllInfo(PLUGIN_INFO* _PluginInfo)
|
||||
//{
|
||||
// _PluginInfo->Version = 0x0100;
|
||||
// //_PluginInfo->Type = PLUGIN_TYPE_VIDEO;
|
||||
//#ifdef DEBUGFAST
|
||||
// sprintf_s(_PluginInfo->Name, 100, "Dolphin Direct3D9 (DebugFast)");
|
||||
//#elif defined _DEBUG
|
||||
// sprintf_s(_PluginInfo->Name, 100, "Dolphin Direct3D9 (Debug)");
|
||||
//#else
|
||||
// sprintf_s(_PluginInfo->Name, 100, "Dolphin Direct3D9");
|
||||
//#endif
|
||||
//}
|
||||
|
||||
void SetDllGlobals(PLUGIN_GLOBALS* _pPluginGlobals)
|
||||
std::string VideoBackend::GetName()
|
||||
{
|
||||
globals = _pPluginGlobals;
|
||||
LogManager::SetInstance((LogManager*)globals->logManager);
|
||||
}
|
||||
|
||||
void DllAbout(HWND _hParent)
|
||||
{
|
||||
//DialogBox(g_hInstance,(LPCTSTR)IDD_ABOUT,_hParent,(DLGPROC)AboutProc);
|
||||
return "Direct3D9";
|
||||
}
|
||||
|
||||
void InitBackendInfo()
|
||||
|
@ -190,7 +119,7 @@ void InitBackendInfo()
|
|||
g_Config.backend_info.bSupportsPixelLighting = C_PLIGHTS + 40 <= maxConstants && C_PMATERIALS + 4 <= maxConstants;
|
||||
}
|
||||
|
||||
void DllConfig(void *_hParent)
|
||||
void VideoBackend::ShowConfig(void* parent)
|
||||
{
|
||||
#if defined(HAVE_WX) && HAVE_WX
|
||||
InitBackendInfo();
|
||||
|
@ -212,7 +141,7 @@ void DllConfig(void *_hParent)
|
|||
}
|
||||
|
||||
|
||||
VideoConfigDiag *const diag = new VideoConfigDiag((wxWindow*)_hParent, _trans("Direct3D9"), "gfx_dx9");
|
||||
VideoConfigDiag *const diag = new VideoConfigDiag((wxWindow*)parent, _trans("Direct3D9"), "gfx_dx9");
|
||||
diag->ShowModal();
|
||||
diag->Destroy();
|
||||
|
||||
|
@ -220,23 +149,20 @@ void DllConfig(void *_hParent)
|
|||
#endif
|
||||
}
|
||||
|
||||
void Initialize(void *init)
|
||||
void VideoBackend::Initialize()
|
||||
{
|
||||
InitBackendInfo();
|
||||
|
||||
frameCount = 0;
|
||||
SVideoInitialize *_pVideoInitialize = (SVideoInitialize*)init;
|
||||
// Create a shortcut to _pVideoInitialize that can also update it
|
||||
g_VideoInitialize = *(_pVideoInitialize);
|
||||
InitXFBConvTables();
|
||||
|
||||
g_Config.Load((std::string(File::GetUserPath(D_CONFIG_IDX)) + "gfx_dx9.ini").c_str());
|
||||
g_Config.GameIniLoad(globals->game_ini);
|
||||
g_Config.GameIniLoad(SConfig::GetInstance().m_LocalCoreStartupParameter.m_strGameIni.c_str());
|
||||
UpdateProjectionHack(g_Config.iPhackvalue, g_Config.sPhackvalue); // DX9 projection hack could be disabled by commenting out this line
|
||||
UpdateActiveConfig();
|
||||
|
||||
g_VideoInitialize.pWindowHandle = (void*)EmuWindow::Create((HWND)g_VideoInitialize.pWindowHandle, g_hInstance, _T("Loading - Please wait."));
|
||||
if (g_VideoInitialize.pWindowHandle == NULL)
|
||||
VideoWindowHandle() = (void*)EmuWindow::Create((HWND)VideoWindowHandle(), GetModuleHandle(0), _T("Loading - Please wait."));
|
||||
if (VideoWindowHandle() == NULL)
|
||||
{
|
||||
ERROR_LOG(VIDEO, "An error has occurred while trying to create the window.");
|
||||
return;
|
||||
|
@ -247,20 +173,11 @@ void Initialize(void *init)
|
|||
return;
|
||||
}
|
||||
|
||||
g_VideoInitialize.pPeekMessages = &Callback_PeekMessages;
|
||||
g_VideoInitialize.pUpdateFPSDisplay = &UpdateFPSDisplay;
|
||||
|
||||
_pVideoInitialize->pPeekMessages = g_VideoInitialize.pPeekMessages;
|
||||
_pVideoInitialize->pUpdateFPSDisplay = g_VideoInitialize.pUpdateFPSDisplay;
|
||||
|
||||
// Now the window handle is written
|
||||
_pVideoInitialize->pWindowHandle = g_VideoInitialize.pWindowHandle;
|
||||
|
||||
OSD::AddMessage("Dolphin Direct3D9 Video Plugin.", 5000);
|
||||
s_PluginInitialized = true;
|
||||
}
|
||||
|
||||
void Video_Prepare()
|
||||
void VideoBackend::Video_Prepare()
|
||||
{
|
||||
// Better be safe...
|
||||
s_efbAccessRequested = FALSE;
|
||||
|
@ -268,9 +185,9 @@ void Video_Prepare()
|
|||
s_swapRequested = FALSE;
|
||||
|
||||
// internal interfaces
|
||||
g_renderer = new DX9::Renderer;
|
||||
g_texture_cache = new DX9::TextureCache;
|
||||
g_vertex_manager = new DX9::VertexManager;
|
||||
g_renderer = new Renderer;
|
||||
g_texture_cache = new TextureCache;
|
||||
g_vertex_manager = new VertexManager;
|
||||
// VideoCommon
|
||||
BPInit();
|
||||
Fifo_Init();
|
||||
|
@ -283,10 +200,10 @@ void Video_Prepare()
|
|||
DLCache::Init();
|
||||
|
||||
// Notify the core that the video plugin is ready
|
||||
g_VideoInitialize.pCoreMessage(WM_USER_CREATE);
|
||||
Core::Callback_CoreMessage(WM_USER_CREATE);
|
||||
}
|
||||
|
||||
void Shutdown()
|
||||
void VideoBackend::Shutdown()
|
||||
{
|
||||
s_PluginInitialized = false;
|
||||
|
||||
|
@ -304,11 +221,13 @@ void Shutdown()
|
|||
VertexLoaderManager::Shutdown();
|
||||
|
||||
// internal interfaces
|
||||
DX9::PixelShaderCache::Shutdown();
|
||||
DX9::VertexShaderCache::Shutdown();
|
||||
PixelShaderCache::Shutdown();
|
||||
VertexShaderCache::Shutdown();
|
||||
delete g_vertex_manager;
|
||||
delete g_texture_cache;
|
||||
delete g_renderer;
|
||||
DX9::D3D::Shutdown();
|
||||
D3D::Shutdown();
|
||||
EmuWindow::Close();
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -18,10 +18,10 @@
|
|||
#ifndef MAIN_H
|
||||
#define MAIN_H
|
||||
|
||||
#include "PluginSpecs_Video.h"
|
||||
#include <string>
|
||||
|
||||
#include "VideoBackend.h"
|
||||
#include "Render.h"
|
||||
#include "MainBase.h"
|
||||
|
||||
extern SVideoInitialize g_VideoInitialize;
|
||||
|
||||
#endif
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
<VisualStudioProject
|
||||
ProjectType="Visual C++"
|
||||
Version="9.00"
|
||||
Name="Plugin_VideoOGL"
|
||||
Name="VideoOGL"
|
||||
ProjectGUID="{CFDCEE0E-FA45-4F72-9FCC-0B88F5A75160}"
|
||||
RootNamespace="Plugin_VideoOGL"
|
||||
TargetFrameworkVersion="131072"
|
||||
|
@ -22,7 +22,7 @@
|
|||
Name="Release|Win32"
|
||||
OutputDirectory="$(PlatformName)\$(ConfigurationName)"
|
||||
IntermediateDirectory="$(PlatformName)\$(ConfigurationName)"
|
||||
ConfigurationType="2"
|
||||
ConfigurationType="4"
|
||||
InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC71.vsprops"
|
||||
UseOfMFC="0"
|
||||
ATLMinimizesCRunTimeLibraryUsage="false"
|
||||
|
@ -57,7 +57,7 @@
|
|||
EnableIntrinsicFunctions="true"
|
||||
OmitFramePointers="true"
|
||||
WholeProgramOptimization="true"
|
||||
AdditionalIncludeDirectories="../../PluginSpecs;../../Core/Common/Src;../../Core/InputCommon/Src;../../Core/VideoCommon/Src;../../Core/VideoUICommon/Src;./Src;./Src/Windows;../../../Externals;..\..\..\Externals\libjpeg;..\..\..\Externals\wxWidgets\Include;..\..\..\Externals\wxWidgets\Include\msvc;..\..\..\Externals\Glew\include"
|
||||
AdditionalIncludeDirectories="../../PluginSpecs;../../Core/Common/Src;../../Core/Core/Src;../../Core/InputCommon/Src;../../Core/VideoCommon/Src;../../Core/VideoUICommon/Src;./Src;./Src/Windows;../../../Externals;..\..\..\Externals\libjpeg;..\..\..\Externals\wxWidgets\Include;..\..\..\Externals\wxWidgets\Include\msvc;..\..\..\Externals\Glew\include"
|
||||
PreprocessorDefinitions="_WIN32;WIN32;NDEBUG;_WINDOWS;_USRDLL;_CRT_SECURE_NO_DEPRECATE;_SECURE_SCL=0"
|
||||
StringPooling="true"
|
||||
RuntimeLibrary="0"
|
||||
|
@ -89,25 +89,13 @@
|
|||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLinkerTool"
|
||||
AdditionalDependencies="comctl32.lib cg.lib cgGL.lib opengl32.lib glew32s.lib libjpeg.lib glu32.lib SOIL.lib zlib.lib rpcrt4.lib winmm.lib vfw32.lib wxbase28u.lib wxmsw28u_core.lib"
|
||||
OutputFile="..\..\..\Binary\Win32\Plugins\Plugin_VideoOGL.dll"
|
||||
LinkIncremental="1"
|
||||
SuppressStartupBanner="true"
|
||||
AdditionalLibraryDirectories="..\..\..\Externals\Cg;..\..\..\Externals\GLew;..\..\..\Externals\libjpeg;$(SolutionDir)\$(ConfigurationName)\$(PlatformName);..\..\..\Externals\wxWidgets\lib\vc_lib\$(PlatformName)"
|
||||
GenerateManifest="false"
|
||||
ProgramDatabaseFile="$(PlatformName)\$(ConfigurationName)\$(TargetName).pdb"
|
||||
RandomizedBaseAddress="1"
|
||||
DataExecutionPrevention="0"
|
||||
ImportLibrary="$(PlatformName)\$(ConfigurationName)\$(TargetName).lib"
|
||||
TargetMachine="1"
|
||||
Name="VCLibrarianTool"
|
||||
AdditionalDependencies="cg.lib cgGL.lib glu32.lib glew32s.lib opengl32.lib Vfw32.lib"
|
||||
AdditionalLibraryDirectories="..\..\..\Externals\Cg;..\..\..\Externals\GLew"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManifestTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
|
@ -117,9 +105,6 @@
|
|||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCAppVerifierTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
/>
|
||||
|
@ -128,7 +113,7 @@
|
|||
Name="Release|x64"
|
||||
OutputDirectory="$(PlatformName)\$(ConfigurationName)"
|
||||
IntermediateDirectory="$(PlatformName)\$(ConfigurationName)"
|
||||
ConfigurationType="2"
|
||||
ConfigurationType="4"
|
||||
InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC71.vsprops"
|
||||
UseOfMFC="0"
|
||||
ATLMinimizesCRunTimeLibraryUsage="false"
|
||||
|
@ -165,7 +150,7 @@
|
|||
FavorSizeOrSpeed="1"
|
||||
OmitFramePointers="false"
|
||||
WholeProgramOptimization="true"
|
||||
AdditionalIncludeDirectories="../../PluginSpecs;../../Core/Common/Src;../../Core/InputCommon/Src;../../Core/VideoCommon/Src;../../Core/VideoUICommon/Src;./Src;./Src/Windows;../../../Externals;..\..\..\Externals\libjpeg;..\..\..\Externals\wxWidgets\Include;..\..\..\Externals\wxWidgets\Include\msvc;..\..\..\Externals\Glew\include"
|
||||
AdditionalIncludeDirectories="../../PluginSpecs;../../Core/Common/Src;../../Core/Core/Src;../../Core/InputCommon/Src;../../Core/VideoCommon/Src;../../Core/VideoUICommon/Src;./Src;./Src/Windows;../../../Externals;..\..\..\Externals\libjpeg;..\..\..\Externals\wxWidgets\Include;..\..\..\Externals\wxWidgets\Include\msvc;..\..\..\Externals\Glew\include"
|
||||
PreprocessorDefinitions="WIN32;NDEBUG;_WINDOWS;_USRDLL;_CRT_SECURE_NO_DEPRECATE;_SECURE_SCL=0"
|
||||
StringPooling="true"
|
||||
ExceptionHandling="1"
|
||||
|
@ -199,27 +184,13 @@
|
|||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLinkerTool"
|
||||
AdditionalDependencies="comctl32.lib winmm.lib cg.lib cgGL.lib opengl32.lib libjpeg64.lib glu32.lib rpcrt4.lib glew64s.lib vfw32.lib wxbase28u.lib wxmsw28u_core.lib"
|
||||
OutputFile="..\..\..\Binary\x64\Plugins\Plugin_VideoOGL.dll"
|
||||
LinkIncremental="1"
|
||||
SuppressStartupBanner="true"
|
||||
AdditionalLibraryDirectories="..\..\..\Externals\Cg64;..\..\..\Externals\GLew;..\..\..\Externals\libjpeg;..\..\..\Externals\wxWidgets\lib\vc_lib\$(PlatformName)"
|
||||
GenerateManifest="false"
|
||||
GenerateDebugInformation="true"
|
||||
ProgramDatabaseFile="$(PlatformName)\$(ConfigurationName)\$(TargetName).pdb"
|
||||
RandomizedBaseAddress="1"
|
||||
FixedBaseAddress="1"
|
||||
DataExecutionPrevention="2"
|
||||
ImportLibrary="$(PlatformName)\$(ConfigurationName)\$(TargetName).lib"
|
||||
TargetMachine="17"
|
||||
Name="VCLibrarianTool"
|
||||
AdditionalDependencies="cg.lib cgGL.lib glu32.lib glew64s.lib opengl32.lib Vfw32.lib"
|
||||
AdditionalLibraryDirectories="..\..\..\Externals\Cg64;..\..\..\Externals\GLew"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManifestTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
|
@ -229,9 +200,6 @@
|
|||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCAppVerifierTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
/>
|
||||
|
@ -240,7 +208,7 @@
|
|||
Name="Debug|Win32"
|
||||
OutputDirectory="$(PlatformName)\$(ConfigurationName)"
|
||||
IntermediateDirectory="$(PlatformName)\$(ConfigurationName)"
|
||||
ConfigurationType="2"
|
||||
ConfigurationType="4"
|
||||
InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC71.vsprops"
|
||||
UseOfMFC="0"
|
||||
ATLMinimizesCRunTimeLibraryUsage="false"
|
||||
|
@ -270,7 +238,7 @@
|
|||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
Optimization="0"
|
||||
AdditionalIncludeDirectories="../../PluginSpecs;../../Core/Common/Src;../../Core/InputCommon/Src;../../Core/VideoCommon/Src;../../Core/VideoUICommon/Src;./Src;./Src/Windows;../../../Externals;..\..\..\Externals\libjpeg;..\..\..\Externals\wxWidgets\Include;..\..\..\Externals\wxWidgets\Include\msvc;..\..\..\Externals\Glew\include"
|
||||
AdditionalIncludeDirectories="../../PluginSpecs;../../Core/Common/Src;../../Core/Core/Src;../../Core/InputCommon/Src;../../Core/VideoCommon/Src;../../Core/VideoUICommon/Src;./Src;./Src/Windows;../../../Externals;..\..\..\Externals\libjpeg;..\..\..\Externals\wxWidgets\Include;..\..\..\Externals\wxWidgets\Include\msvc;..\..\..\Externals\Glew\include"
|
||||
PreprocessorDefinitions="_WIN32;WIN32;_DEBUG;_WINDOWS;_USRDLL;_CRT_SECURE_NO_DEPRECATE;_SECURE_SCL=0"
|
||||
BasicRuntimeChecks="3"
|
||||
RuntimeLibrary="1"
|
||||
|
@ -298,26 +266,13 @@
|
|||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLinkerTool"
|
||||
AdditionalDependencies="odbc32.lib odbccp32.lib comctl32.lib winmm.lib cg.lib cgGL.lib opengl32.lib glew32s.lib libjpeg.lib SOIL.lib zlib.lib glu32.lib rpcrt4.lib vfw32.lib wxbase28ud.lib wxmsw28ud_core.lib"
|
||||
OutputFile="..\..\..\Binary\Win32/Plugins\Plugin_VideoOGLD.dll"
|
||||
LinkIncremental="1"
|
||||
SuppressStartupBanner="true"
|
||||
AdditionalLibraryDirectories=""$(SolutionDir)\$(ConfigurationName)\$(PlatformName)";..\..\..\Externals\Cg;..\..\..\Externals\GLew;..\..\..\Externals\libjpeg;"..\..\..\Externals\wxWidgets\lib\vc_lib\$(PlatformName)""
|
||||
GenerateManifest="false"
|
||||
GenerateDebugInformation="true"
|
||||
ProgramDatabaseFile="$(PlatformName)\$(ConfigurationName)\$(TargetName).pdb"
|
||||
RandomizedBaseAddress="1"
|
||||
DataExecutionPrevention="0"
|
||||
ImportLibrary="$(PlatformName)\$(ConfigurationName)\$(TargetName).lib"
|
||||
TargetMachine="1"
|
||||
Name="VCLibrarianTool"
|
||||
AdditionalDependencies="cg.lib cgGL.lib glu32.lib glew32s.lib opengl32.lib Vfw32.lib"
|
||||
AdditionalLibraryDirectories="..\..\..\Externals\Cg;..\..\..\Externals\GLew"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManifestTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
|
@ -327,9 +282,6 @@
|
|||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCAppVerifierTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
/>
|
||||
|
@ -338,7 +290,7 @@
|
|||
Name="Debug|x64"
|
||||
OutputDirectory="$(PlatformName)\$(ConfigurationName)"
|
||||
IntermediateDirectory="$(PlatformName)\$(ConfigurationName)"
|
||||
ConfigurationType="2"
|
||||
ConfigurationType="4"
|
||||
InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC71.vsprops"
|
||||
UseOfMFC="0"
|
||||
ATLMinimizesCRunTimeLibraryUsage="false"
|
||||
|
@ -368,7 +320,7 @@
|
|||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
Optimization="0"
|
||||
AdditionalIncludeDirectories="../../PluginSpecs;../../Core/Common/Src;../../Core/InputCommon/Src;../../Core/VideoCommon/Src;../../Core/VideoUICommon/Src;./Src;./Src/Windows;../../../Externals;..\..\..\Externals\libjpeg;..\..\..\Externals\wxWidgets\Include;..\..\..\Externals\wxWidgets\Include\msvc;..\..\..\Externals\Glew\include"
|
||||
AdditionalIncludeDirectories="../../PluginSpecs;../../Core/Common/Src;../../Core/Core/Src;../../Core/InputCommon/Src;../../Core/VideoCommon/Src;../../Core/VideoUICommon/Src;./Src;./Src/Windows;../../../Externals;..\..\..\Externals\libjpeg;..\..\..\Externals\wxWidgets\Include;..\..\..\Externals\wxWidgets\Include\msvc;..\..\..\Externals\Glew\include"
|
||||
PreprocessorDefinitions="WIN32;_DEBUG;_WINDOWS;_USRDLL;_CRT_SECURE_NO_DEPRECATE;_SECURE_SCL=0"
|
||||
BasicRuntimeChecks="3"
|
||||
RuntimeLibrary="1"
|
||||
|
@ -396,27 +348,13 @@
|
|||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLinkerTool"
|
||||
AdditionalDependencies="comctl32.lib winmm.lib cg.lib cgGL.lib opengl32.lib libjpeg64.lib glu32.lib glew64s.lib SOIL.lib zlib.lib rpcrt4.lib vfw32.lib wxbase28ud.lib wxmsw28ud_core.lib"
|
||||
OutputFile="..\..\..\Binary\x64\Plugins\Plugin_VideoOGLD.dll"
|
||||
LinkIncremental="1"
|
||||
SuppressStartupBanner="true"
|
||||
AdditionalLibraryDirectories=""$(SolutionDir)\$(ConfigurationName)\$(PlatformName)";..\..\..\Externals\Cg64;..\..\..\Externals\GLew;..\..\..\Externals\libjpeg;"..\..\..\Externals\wxWidgets\lib\vc_lib\$(PlatformName)""
|
||||
GenerateManifest="false"
|
||||
GenerateDebugInformation="true"
|
||||
ProgramDatabaseFile="$(PlatformName)\$(ConfigurationName)\$(TargetName).pdb"
|
||||
LargeAddressAware="1"
|
||||
RandomizedBaseAddress="1"
|
||||
DataExecutionPrevention="0"
|
||||
ImportLibrary="$(PlatformName)\$(ConfigurationName)\$(TargetName).lib"
|
||||
TargetMachine="17"
|
||||
Name="VCLibrarianTool"
|
||||
AdditionalDependencies="cg.lib cgGL.lib glu32.lib glew64s.lib opengl32.lib Vfw32.lib"
|
||||
AdditionalLibraryDirectories="..\..\..\Externals\Cg64;..\..\..\Externals\GLew"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManifestTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
|
@ -426,9 +364,6 @@
|
|||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCAppVerifierTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
/>
|
||||
|
@ -437,7 +372,7 @@
|
|||
Name="DebugFast|Win32"
|
||||
OutputDirectory="$(PlatformName)\$(ConfigurationName)"
|
||||
IntermediateDirectory="$(PlatformName)\$(ConfigurationName)"
|
||||
ConfigurationType="2"
|
||||
ConfigurationType="4"
|
||||
InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC71.vsprops"
|
||||
UseOfMFC="0"
|
||||
ATLMinimizesCRunTimeLibraryUsage="false"
|
||||
|
@ -472,7 +407,7 @@
|
|||
EnableIntrinsicFunctions="true"
|
||||
OmitFramePointers="true"
|
||||
WholeProgramOptimization="false"
|
||||
AdditionalIncludeDirectories="../../PluginSpecs;../../Core/Common/Src;../../Core/InputCommon/Src;../../Core/VideoCommon/Src;../../Core/VideoUICommon/Src;./Src;./Src/Windows;../../../Externals;..\..\..\Externals\libjpeg;..\..\..\Externals\wxWidgets\Include;..\..\..\Externals\wxWidgets\Include\msvc;..\..\..\Externals\Glew\include"
|
||||
AdditionalIncludeDirectories="../../PluginSpecs;../../Core/Common/Src;../../Core/Core/Src;../../Core/InputCommon/Src;../../Core/VideoCommon/Src;../../Core/VideoUICommon/Src;./Src;./Src/Windows;../../../Externals;..\..\..\Externals\libjpeg;..\..\..\Externals\wxWidgets\Include;..\..\..\Externals\wxWidgets\Include\msvc;..\..\..\Externals\Glew\include"
|
||||
PreprocessorDefinitions="_WIN32;WIN32;NDEBUG;_WINDOWS;_USRDLL;_CRT_SECURE_NO_DEPRECATE;_SECURE_SCL=0;DEBUGFAST"
|
||||
StringPooling="true"
|
||||
RuntimeLibrary="0"
|
||||
|
@ -504,27 +439,13 @@
|
|||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLinkerTool"
|
||||
AdditionalDependencies="comctl32.lib winmm.lib cg.lib cgGL.lib opengl32.lib glew32s.lib libjpeg.lib glu32.lib rpcrt4.lib vfw32.lib SOIL.lib zlib.lib wxbase28u.lib wxmsw28u_core.lib"
|
||||
OutputFile="..\..\..\Binary\Win32\Plugins\Plugin_VideoOGLDF.dll"
|
||||
LinkIncremental="1"
|
||||
SuppressStartupBanner="true"
|
||||
AdditionalLibraryDirectories=""$(SolutionDir)\Release\$(PlatformName)";..\..\..\Externals\Cg;..\..\..\Externals\GLew;..\..\..\Externals\libjpeg;"..\..\..\Externals\wxWidgets\lib\vc_lib\$(PlatformName)""
|
||||
GenerateManifest="false"
|
||||
IgnoreDefaultLibraryNames=""
|
||||
GenerateDebugInformation="true"
|
||||
ProgramDatabaseFile="$(PlatformName)\$(ConfigurationName)\$(TargetName).pdb"
|
||||
RandomizedBaseAddress="1"
|
||||
DataExecutionPrevention="0"
|
||||
ImportLibrary="$(PlatformName)\$(ConfigurationName)\$(TargetName).lib"
|
||||
TargetMachine="1"
|
||||
Name="VCLibrarianTool"
|
||||
AdditionalDependencies="cg.lib cgGL.lib glu32.lib glew32s.lib opengl32.lib Vfw32.lib"
|
||||
AdditionalLibraryDirectories="..\..\..\Externals\Cg;..\..\..\Externals\GLew"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManifestTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
|
@ -534,9 +455,6 @@
|
|||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCAppVerifierTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
/>
|
||||
|
@ -545,7 +463,7 @@
|
|||
Name="DebugFast|x64"
|
||||
OutputDirectory="$(PlatformName)\$(ConfigurationName)"
|
||||
IntermediateDirectory="$(PlatformName)\$(ConfigurationName)"
|
||||
ConfigurationType="2"
|
||||
ConfigurationType="4"
|
||||
InheritedPropertySheets="$(VCInstallDir)VCProjectDefaults\UpgradeFromVC71.vsprops"
|
||||
UseOfMFC="0"
|
||||
ATLMinimizesCRunTimeLibraryUsage="false"
|
||||
|
@ -581,7 +499,7 @@
|
|||
FavorSizeOrSpeed="1"
|
||||
OmitFramePointers="false"
|
||||
WholeProgramOptimization="false"
|
||||
AdditionalIncludeDirectories="../../PluginSpecs;../../Core/Common/Src;../../Core/InputCommon/Src;../../Core/VideoCommon/Src;../../Core/VideoUICommon/Src;./Src;./Src/Windows;../../../Externals;..\..\..\Externals\libjpeg;..\..\..\Externals\wxWidgets\Include;..\..\..\Externals\wxWidgets\Include\msvc;..\..\..\Externals\Glew\include"
|
||||
AdditionalIncludeDirectories="../../PluginSpecs;../../Core/Common/Src;../../Core/Core/Src;../../Core/InputCommon/Src;../../Core/VideoCommon/Src;../../Core/VideoUICommon/Src;./Src;./Src/Windows;../../../Externals;..\..\..\Externals\libjpeg;..\..\..\Externals\wxWidgets\Include;..\..\..\Externals\wxWidgets\Include\msvc;..\..\..\Externals\Glew\include"
|
||||
PreprocessorDefinitions="WIN32;NDEBUG;_WINDOWS;_USRDLL;_CRT_SECURE_NO_DEPRECATE;_SECURE_SCL=0;DEBUGFAST"
|
||||
StringPooling="true"
|
||||
ExceptionHandling="1"
|
||||
|
@ -614,26 +532,13 @@
|
|||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLinkerTool"
|
||||
AdditionalDependencies="comctl32.lib winmm.lib cg.lib cgGL.lib opengl32.lib libjpeg64.lib glu32.lib glew64s.lib rpcrt4.lib vfw32.lib wxbase28u.lib wxmsw28u_core.lib"
|
||||
OutputFile="..\..\..\Binary\x64\Plugins\Plugin_VideoOGLDF.dll"
|
||||
LinkIncremental="1"
|
||||
SuppressStartupBanner="true"
|
||||
AdditionalLibraryDirectories="..\..\..\Externals\Cg64;..\..\..\Externals\GLew;..\..\..\Externals\libjpeg;"..\..\..\Externals\wxWidgets\lib\vc_lib\$(PlatformName)""
|
||||
GenerateManifest="false"
|
||||
GenerateDebugInformation="true"
|
||||
ProgramDatabaseFile="$(PlatformName)\$(ConfigurationName)\$(TargetName).pdb"
|
||||
RandomizedBaseAddress="1"
|
||||
DataExecutionPrevention="0"
|
||||
ImportLibrary="$(PlatformName)\$(ConfigurationName)\$(TargetName).lib"
|
||||
TargetMachine="17"
|
||||
Name="VCLibrarianTool"
|
||||
AdditionalDependencies="cg.lib cgGL.lib glu32.lib glew64s.lib opengl32.lib Vfw32.lib"
|
||||
AdditionalLibraryDirectories="..\..\..\Externals\Cg64;..\..\..\Externals\GLew"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManifestTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
|
@ -643,9 +548,6 @@
|
|||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCAppVerifierTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
/>
|
||||
|
|
|
@ -29,38 +29,39 @@
|
|||
<PropertyGroup Label="Globals">
|
||||
<ProjectGuid>{1909CD2D-1707-456F-86CA-0DF42A727C99}</ProjectGuid>
|
||||
<RootNamespace>Plugin_VideoOGL</RootNamespace>
|
||||
<ProjectName>VideoOGL</ProjectName>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
|
||||
<ConfigurationType>DynamicLibrary</ConfigurationType>
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>true</UseDebugLibraries>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">
|
||||
<ConfigurationType>DynamicLibrary</ConfigurationType>
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>true</UseDebugLibraries>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
|
||||
<ConfigurationType>DynamicLibrary</ConfigurationType>
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>false</UseDebugLibraries>
|
||||
<WholeProgramOptimization>true</WholeProgramOptimization>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='DebugFast|Win32'" Label="Configuration">
|
||||
<ConfigurationType>DynamicLibrary</ConfigurationType>
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>false</UseDebugLibraries>
|
||||
<WholeProgramOptimization>true</WholeProgramOptimization>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
|
||||
<ConfigurationType>DynamicLibrary</ConfigurationType>
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>false</UseDebugLibraries>
|
||||
<WholeProgramOptimization>true</WholeProgramOptimization>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='DebugFast|x64'" Label="Configuration">
|
||||
<ConfigurationType>DynamicLibrary</ConfigurationType>
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>false</UseDebugLibraries>
|
||||
<WholeProgramOptimization>true</WholeProgramOptimization>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
|
@ -131,7 +132,7 @@
|
|||
<ClCompile>
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
<Optimization>Disabled</Optimization>
|
||||
<AdditionalIncludeDirectories>..\..\Core\Common\Src;..\..\PluginSpecs;..\..\Core\VideoCommon\Src;..\..\Core\VideoUICommon\Src;..\..\..\Externals\wxWidgets\include;..\..\..\Externals\GLew\include;..\..\..\Externals</AdditionalIncludeDirectories>
|
||||
<AdditionalIncludeDirectories>..\..\Core\Common\Src;..\..\Core\Core\Src;..\..\PluginSpecs;..\..\Core\VideoCommon\Src;..\..\Core\VideoUICommon\Src;..\..\..\Externals\wxWidgets\include;..\..\..\Externals\GLew\include;..\..\..\Externals</AdditionalIncludeDirectories>
|
||||
<PreprocessorDefinitions>_SECURE_SCL=0;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<RuntimeLibrary>MultiThreadedDebug</RuntimeLibrary>
|
||||
<ForcedIncludeFiles>stdafx.h</ForcedIncludeFiles>
|
||||
|
@ -143,12 +144,16 @@
|
|||
<AdditionalLibraryDirectories>..\..\..\Externals\GLew;..\..\..\Externals\Cg;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<OutputFile>..\..\..\Binary\$(PlatformName)\Plugins\$(TargetName)$(TargetExt)</OutputFile>
|
||||
</Link>
|
||||
<Lib>
|
||||
<AdditionalDependencies>cg.lib;cgGL.lib;opengl32.lib;glew32s.lib;glu32.lib</AdditionalDependencies>
|
||||
<AdditionalLibraryDirectories>..\..\..\Externals\Cg;..\..\..\Externals\GLew;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
</Lib>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
|
||||
<ClCompile>
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
<Optimization>Disabled</Optimization>
|
||||
<AdditionalIncludeDirectories>..\..\Core\Common\Src;..\..\PluginSpecs;..\..\Core\VideoCommon\Src;..\..\Core\VideoUICommon\Src;..\..\..\Externals\wxWidgets\include;..\..\..\Externals\GLew\include;..\..\..\Externals</AdditionalIncludeDirectories>
|
||||
<AdditionalIncludeDirectories>..\..\Core\Common\Src;..\..\Core\Core\Src;..\..\PluginSpecs;..\..\Core\VideoCommon\Src;..\..\Core\VideoUICommon\Src;..\..\..\Externals\wxWidgets\include;..\..\..\Externals\GLew\include;..\..\..\Externals</AdditionalIncludeDirectories>
|
||||
<PreprocessorDefinitions>_SECURE_SCL=0;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<RuntimeLibrary>MultiThreadedDebug</RuntimeLibrary>
|
||||
<ForcedIncludeFiles>stdafx.h</ForcedIncludeFiles>
|
||||
|
@ -160,6 +165,10 @@
|
|||
<AdditionalLibraryDirectories>..\..\..\Externals\GLew;..\..\..\Externals\Cg64;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<OutputFile>..\..\..\Binary\$(PlatformName)\Plugins\$(TargetName)$(TargetExt)</OutputFile>
|
||||
</Link>
|
||||
<Lib>
|
||||
<AdditionalDependencies>cg.lib;cgGL.lib;opengl32.lib;glew64s.lib;glu32.lib</AdditionalDependencies>
|
||||
<AdditionalLibraryDirectories>..\..\..\Externals\Cg64;..\..\..\Externals\GLew;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
</Lib>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<ClCompile>
|
||||
|
@ -167,7 +176,7 @@
|
|||
<Optimization>MaxSpeed</Optimization>
|
||||
<FunctionLevelLinking>true</FunctionLevelLinking>
|
||||
<IntrinsicFunctions>true</IntrinsicFunctions>
|
||||
<AdditionalIncludeDirectories>..\..\Core\Common\Src;..\..\PluginSpecs;..\..\Core\VideoCommon\Src;..\..\Core\VideoUICommon\Src;..\..\..\Externals\wxWidgets\include;..\..\..\Externals\GLew\include;..\..\..\Externals</AdditionalIncludeDirectories>
|
||||
<AdditionalIncludeDirectories>..\..\Core\Common\Src;..\..\Core\Core\Src;..\..\PluginSpecs;..\..\Core\VideoCommon\Src;..\..\Core\VideoUICommon\Src;..\..\..\Externals\wxWidgets\include;..\..\..\Externals\GLew\include;..\..\..\Externals</AdditionalIncludeDirectories>
|
||||
<PreprocessorDefinitions>_SECURE_SCL=0;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<RuntimeLibrary>MultiThreaded</RuntimeLibrary>
|
||||
<ForcedIncludeFiles>stdafx.h</ForcedIncludeFiles>
|
||||
|
@ -181,6 +190,10 @@
|
|||
<AdditionalLibraryDirectories>..\..\..\Externals\GLew;..\..\..\Externals\Cg;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<OutputFile>..\..\..\Binary\$(PlatformName)\Plugins\$(TargetName)$(TargetExt)</OutputFile>
|
||||
</Link>
|
||||
<Lib>
|
||||
<AdditionalDependencies>cg.lib;cgGL.lib;opengl32.lib;glew32s.lib;glu32.lib</AdditionalDependencies>
|
||||
<AdditionalLibraryDirectories>..\..\..\Externals\Cg;..\..\..\Externals\GLew;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
</Lib>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='DebugFast|Win32'">
|
||||
<ClCompile>
|
||||
|
@ -202,6 +215,10 @@
|
|||
<AdditionalLibraryDirectories>..\..\..\Externals\GLew;..\..\..\Externals\Cg;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<OutputFile>..\..\..\Binary\$(PlatformName)\Plugins\$(TargetName)$(TargetExt)</OutputFile>
|
||||
</Link>
|
||||
<Lib>
|
||||
<AdditionalDependencies>cg.lib;cgGL.lib;opengl32.lib;glew32s.lib;glu32.lib</AdditionalDependencies>
|
||||
<AdditionalLibraryDirectories>..\..\..\Externals\Cg;..\..\..\Externals\GLew;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
</Lib>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
|
||||
<ClCompile>
|
||||
|
@ -209,7 +226,7 @@
|
|||
<Optimization>MaxSpeed</Optimization>
|
||||
<FunctionLevelLinking>true</FunctionLevelLinking>
|
||||
<IntrinsicFunctions>true</IntrinsicFunctions>
|
||||
<AdditionalIncludeDirectories>..\..\Core\Common\Src;..\..\PluginSpecs;..\..\Core\VideoCommon\Src;..\..\Core\VideoUICommon\Src;..\..\..\Externals\wxWidgets\include;..\..\..\Externals\GLew\include;..\..\..\Externals</AdditionalIncludeDirectories>
|
||||
<AdditionalIncludeDirectories>..\..\Core\Common\Src;..\..\Core\Core\Src;..\..\PluginSpecs;..\..\Core\VideoCommon\Src;..\..\Core\VideoUICommon\Src;..\..\..\Externals\wxWidgets\include;..\..\..\Externals\GLew\include;..\..\..\Externals</AdditionalIncludeDirectories>
|
||||
<PreprocessorDefinitions>_SECURE_SCL=0;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<RuntimeLibrary>MultiThreaded</RuntimeLibrary>
|
||||
<ForcedIncludeFiles>stdafx.h</ForcedIncludeFiles>
|
||||
|
@ -223,6 +240,10 @@
|
|||
<AdditionalLibraryDirectories>..\..\..\Externals\GLew;..\..\..\Externals\Cg64;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<OutputFile>..\..\..\Binary\$(PlatformName)\Plugins\$(TargetName)$(TargetExt)</OutputFile>
|
||||
</Link>
|
||||
<Lib>
|
||||
<AdditionalDependencies>cg.lib;cgGL.lib;opengl32.lib;glew64s.lib;glu32.lib</AdditionalDependencies>
|
||||
<AdditionalLibraryDirectories>..\..\..\Externals\Cg64;..\..\..\Externals\GLew;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
</Lib>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='DebugFast|x64'">
|
||||
<ClCompile>
|
||||
|
@ -244,6 +265,10 @@
|
|||
<AdditionalLibraryDirectories>..\..\..\Externals\GLew;..\..\..\Externals\Cg64;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<OutputFile>..\..\..\Binary\$(PlatformName)\Plugins\$(TargetName)$(TargetExt)</OutputFile>
|
||||
</Link>
|
||||
<Lib>
|
||||
<AdditionalDependencies>cg.lib;cgGL.lib;opengl32.lib;glew64s.lib;glu32.lib</AdditionalDependencies>
|
||||
<AdditionalLibraryDirectories>..\..\..\Externals\Cg64;..\..\..\Externals\GLew;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
</Lib>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemGroup>
|
||||
<ClCompile Include="Src\FramebufferManager.cpp" />
|
||||
|
@ -282,6 +307,7 @@
|
|||
<ClInclude Include="Src\TextureConverter.h" />
|
||||
<ClInclude Include="Src\VertexManager.h" />
|
||||
<ClInclude Include="Src\VertexShaderCache.h" />
|
||||
<ClInclude Include="Src\VideoBackend.h" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="Src\SConscript" />
|
||||
|
|
|
@ -20,8 +20,7 @@
|
|||
|
||||
#include "TextureConverter.h"
|
||||
#include "Render.h"
|
||||
|
||||
|
||||
#include "HW/Memmap.h"
|
||||
|
||||
namespace OGL
|
||||
{
|
||||
|
@ -272,7 +271,7 @@ GLuint FramebufferManager::GetEFBDepthTexture(const EFBRectangle& sourceRc)
|
|||
|
||||
void FramebufferManager::CopyToRealXFB(u32 xfbAddr, u32 fbWidth, u32 fbHeight, const EFBRectangle& sourceRc,float Gamma)
|
||||
{
|
||||
u8* xfb_in_ram = Memory_GetPtr(xfbAddr);
|
||||
u8* xfb_in_ram = Memory::GetPointer(xfbAddr);
|
||||
if (!xfb_in_ram)
|
||||
{
|
||||
WARN_LOG(VIDEO, "Tried to copy to invalid XFB address");
|
||||
|
|
|
@ -19,6 +19,10 @@
|
|||
#include "VideoConfig.h"
|
||||
#include "IniFile.h"
|
||||
#include "Setup.h"
|
||||
#include "Core.h"
|
||||
#include "Host.h"
|
||||
#include "VideoBackend.h"
|
||||
#include "ConfigManager.h"
|
||||
|
||||
#include "Render.h"
|
||||
#include "VertexShaderManager.h"
|
||||
|
@ -29,7 +33,6 @@
|
|||
#include "EmuWindow.h"
|
||||
static HDC hDC = NULL; // Private GDI Device Context
|
||||
static HGLRC hRC = NULL; // Permanent Rendering Context
|
||||
extern HINSTANCE g_hInstance;
|
||||
#else
|
||||
GLWindow GLWin;
|
||||
#endif
|
||||
|
@ -79,8 +82,16 @@ void OpenGL_SetWindowText(const char *text)
|
|||
#endif
|
||||
}
|
||||
|
||||
static void*& VideoWindowHandle()
|
||||
{
|
||||
return SConfig::GetInstance().m_LocalCoreStartupParameter.hMainWindow;
|
||||
}
|
||||
|
||||
namespace OGL
|
||||
{
|
||||
|
||||
// Draw messages on top of the screen
|
||||
unsigned int Callback_PeekMessages()
|
||||
unsigned int VideoBackend::PeekMessages()
|
||||
{
|
||||
#ifdef _WIN32
|
||||
// TODO: peekmessage
|
||||
|
@ -99,13 +110,15 @@ unsigned int Callback_PeekMessages()
|
|||
}
|
||||
|
||||
// Show the current FPS
|
||||
void UpdateFPSDisplay(const char *text)
|
||||
void VideoBackend::UpdateFPSDisplay(const char *text)
|
||||
{
|
||||
char temp[100];
|
||||
snprintf(temp, sizeof temp, "%s | OpenGL | %s", svn_rev_str, text);
|
||||
OpenGL_SetWindowText(temp);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
#if defined(HAVE_X11) && HAVE_X11
|
||||
void XEventThread();
|
||||
|
||||
|
@ -291,7 +304,7 @@ void XEventThread()
|
|||
break;
|
||||
case ClientMessage:
|
||||
if ((unsigned long) event.xclient.data.l[0] == XInternAtom(GLWin.evdpy, "WM_DELETE_WINDOW", False))
|
||||
g_VideoInitialize.pCoreMessage(WM_USER_STOP);
|
||||
Core::Callback_CoreMessage(WM_USER_STOP);
|
||||
if ((unsigned long) event.xclient.data.l[0] == XInternAtom(GLWin.evdpy, "RESIZE", False))
|
||||
XMoveResizeWindow(GLWin.evdpy, GLWin.win, event.xclient.data.l[1],
|
||||
event.xclient.data.l[2], event.xclient.data.l[3], event.xclient.data.l[4]);
|
||||
|
@ -307,20 +320,17 @@ void XEventThread()
|
|||
|
||||
// Create rendering window.
|
||||
// Call browser: Core.cpp:EmuThread() > main.cpp:Video_Initialize()
|
||||
bool OpenGL_Create(SVideoInitialize &_VideoInitialize, int _iwidth, int _iheight)
|
||||
bool OpenGL_Create(int _iwidth, int _iheight)
|
||||
{
|
||||
int _tx, _ty, _twidth, _theight;
|
||||
g_VideoInitialize.pGetWindowSize(_tx, _ty, _twidth, _theight);
|
||||
Core::Callback_VideoGetWindowSize(_tx, _ty, _twidth, _theight);
|
||||
|
||||
// Control window size and picture scaling
|
||||
s_backbuffer_width = _twidth;
|
||||
s_backbuffer_height = _theight;
|
||||
|
||||
g_VideoInitialize.pPeekMessages = &Callback_PeekMessages;
|
||||
g_VideoInitialize.pUpdateFPSDisplay = &UpdateFPSDisplay;
|
||||
|
||||
#if defined(USE_WX) && USE_WX
|
||||
GLWin.panel = (wxPanel *)g_VideoInitialize.pWindowHandle;
|
||||
GLWin.panel = (wxPanel *)VideoWindowHandle();
|
||||
GLWin.glCanvas = new wxGLCanvas(GLWin.panel, wxID_ANY, NULL,
|
||||
wxPoint(0, 0), wxSize(_twidth, _theight));
|
||||
GLWin.glCanvas->Show(true);
|
||||
|
@ -333,7 +343,7 @@ bool OpenGL_Create(SVideoInitialize &_VideoInitialize, int _iwidth, int _iheight
|
|||
initWithAttributes: attr];
|
||||
if (fmt == nil) {
|
||||
printf("failed to create pixel format\n");
|
||||
return false;
|
||||
return NULL;
|
||||
}
|
||||
|
||||
GLWin.cocoaCtx = [[NSOpenGLContext alloc]
|
||||
|
@ -341,7 +351,7 @@ bool OpenGL_Create(SVideoInitialize &_VideoInitialize, int _iwidth, int _iheight
|
|||
[fmt release];
|
||||
if (GLWin.cocoaCtx == nil) {
|
||||
printf("failed to create context\n");
|
||||
return false;
|
||||
return NULL;
|
||||
}
|
||||
|
||||
GLWin.cocoaWin = [[NSWindow alloc]
|
||||
|
@ -353,10 +363,10 @@ bool OpenGL_Create(SVideoInitialize &_VideoInitialize, int _iwidth, int _iheight
|
|||
[GLWin.cocoaCtx setView: [GLWin.cocoaWin contentView]];
|
||||
|
||||
#elif defined(_WIN32)
|
||||
g_VideoInitialize.pWindowHandle = (void*)EmuWindow::Create((HWND)g_VideoInitialize.pWindowHandle, g_hInstance, _T("Please wait..."));
|
||||
if (g_VideoInitialize.pWindowHandle == NULL)
|
||||
VideoWindowHandle() = (void*)EmuWindow::Create((HWND)VideoWindowHandle(), GetModuleHandle(0), _T("Please wait..."));
|
||||
if (VideoWindowHandle() == NULL)
|
||||
{
|
||||
g_VideoInitialize.pSysMessage("failed to create window");
|
||||
Host_SysMessage("failed to create window");
|
||||
return false;
|
||||
}
|
||||
|
||||
|
@ -438,7 +448,7 @@ bool OpenGL_Create(SVideoInitialize &_VideoInitialize, int _iwidth, int _iheight
|
|||
|
||||
GLWin.dpy = XOpenDisplay(0);
|
||||
GLWin.evdpy = XOpenDisplay(0);
|
||||
GLWin.parent = (Window)g_VideoInitialize.pWindowHandle;
|
||||
GLWin.parent = (Window)VideoWindowHandle();
|
||||
GLWin.screen = DefaultScreen(GLWin.dpy);
|
||||
if (GLWin.parent == 0)
|
||||
GLWin.parent = RootWindow(GLWin.dpy, GLWin.screen);
|
||||
|
@ -482,9 +492,9 @@ bool OpenGL_Create(SVideoInitialize &_VideoInitialize, int _iwidth, int _iheight
|
|||
GLWin.height = _theight;
|
||||
|
||||
CreateXWindow();
|
||||
g_VideoInitialize.pWindowHandle = (void *)GLWin.win;
|
||||
VideoWindowHandle() = (void *)GLWin.win;
|
||||
#endif
|
||||
return true;
|
||||
return false;
|
||||
}
|
||||
|
||||
bool OpenGL_MakeCurrent()
|
||||
|
@ -498,7 +508,7 @@ bool OpenGL_MakeCurrent()
|
|||
return wglMakeCurrent(hDC,hRC) ? true : false;
|
||||
#elif defined(HAVE_X11) && HAVE_X11
|
||||
#if defined(HAVE_WX) && (HAVE_WX)
|
||||
g_VideoInitialize.pGetWindowSize(GLWin.x, GLWin.y, (int&)GLWin.width, (int&)GLWin.height);
|
||||
Core::Callback_VideoGetWindowSize(GLWin.x, GLWin.y, (int&)GLWin.width, (int&)GLWin.height);
|
||||
XMoveResizeWindow(GLWin.dpy, GLWin.win, GLWin.x, GLWin.y, GLWin.width, GLWin.height);
|
||||
#endif
|
||||
return glXMakeCurrent(GLWin.dpy, GLWin.win, GLWin.ctx);
|
||||
|
|
|
@ -21,7 +21,6 @@
|
|||
#include "VideoConfig.h"
|
||||
#include "MathUtil.h"
|
||||
#include "Thread.h"
|
||||
#include "pluginspecs_video.h"
|
||||
|
||||
#ifdef _WIN32
|
||||
#define GLEW_STATIC
|
||||
|
@ -85,7 +84,7 @@ extern GLWindow GLWin;
|
|||
// Public OpenGL util
|
||||
|
||||
// Initialization / upkeep
|
||||
bool OpenGL_Create(SVideoInitialize &_VideoInitialize, int _width, int _height);
|
||||
bool OpenGL_Create(int _width, int _height);
|
||||
void OpenGL_Shutdown();
|
||||
void OpenGL_Update();
|
||||
bool OpenGL_MakeCurrent();
|
||||
|
|
|
@ -22,9 +22,5 @@
|
|||
#include "VideoConfig.h"
|
||||
|
||||
#include "VideoCommon.h"
|
||||
#include "pluginspecs_video.h"
|
||||
|
||||
// A global plugin specification
|
||||
extern PLUGIN_GLOBALS* globals;
|
||||
|
||||
#endif // _GLOBALS_H_
|
||||
|
|
|
@ -324,7 +324,6 @@ void PixelShaderCache::DisableShader()
|
|||
}
|
||||
}
|
||||
|
||||
|
||||
//bind a program if is diferent from the binded oone
|
||||
void PixelShaderCache::SetCurrentShader(GLuint Shader)
|
||||
{
|
||||
|
@ -341,22 +340,21 @@ void PixelShaderCache::SetCurrentShader(GLuint Shader)
|
|||
}
|
||||
}
|
||||
|
||||
} // namespace OGL
|
||||
|
||||
|
||||
void SetPSConstant4f(unsigned int const_number, float f1, float f2, float f3, float f4)
|
||||
void Renderer::SetPSConstant4f(unsigned int const_number, float f1, float f2, float f3, float f4)
|
||||
{
|
||||
float f[4] = { f1, f2, f3, f4 };
|
||||
glProgramEnvParameter4fvARB(GL_FRAGMENT_PROGRAM_ARB, const_number, f);
|
||||
}
|
||||
|
||||
void SetPSConstant4fv(unsigned int const_number, const float *f)
|
||||
void Renderer::SetPSConstant4fv(unsigned int const_number, const float *f)
|
||||
{
|
||||
glProgramEnvParameter4fvARB(GL_FRAGMENT_PROGRAM_ARB, const_number, f);
|
||||
}
|
||||
|
||||
void SetMultiPSConstant4fv(unsigned int const_number, unsigned int count, const float *f)
|
||||
void Renderer::SetMultiPSConstant4fv(unsigned int const_number, unsigned int count, const float *f)
|
||||
{
|
||||
for (unsigned int i = 0; i < count; i++,f+=4)
|
||||
glProgramEnvParameter4fvARB(GL_FRAGMENT_PROGRAM_ARB, const_number + i, f);
|
||||
}
|
||||
|
||||
} // namespace OGL
|
||||
|
|
|
@ -57,6 +57,7 @@
|
|||
#include "FramebufferManager.h"
|
||||
#include "Fifo.h"
|
||||
#include "Debugger.h"
|
||||
#include "Core.h"
|
||||
|
||||
#include "main.h" // Local
|
||||
#ifdef _WIN32
|
||||
|
@ -962,7 +963,7 @@ void Renderer::Swap(u32 xfbAddr, FieldType field, u32 fbWidth, u32 fbHeight,cons
|
|||
{
|
||||
if (g_bSkipCurrentFrame || (!XFBWrited && (!g_ActiveConfig.bUseXFB || !g_ActiveConfig.bUseRealXFB)) || !fbWidth || !fbHeight)
|
||||
{
|
||||
g_VideoInitialize.pCopiedToXFB(false);
|
||||
Core::Callback_VideoCopiedToXFB(false);
|
||||
return;
|
||||
}
|
||||
// this function is called after the XFB field is changed, not after
|
||||
|
@ -974,7 +975,7 @@ void Renderer::Swap(u32 xfbAddr, FieldType field, u32 fbWidth, u32 fbHeight,cons
|
|||
const XFBSourceBase* const* xfbSourceList = FramebufferManager::GetXFBSource(xfbAddr, fbWidth, fbHeight, xfbCount);
|
||||
if ((!xfbSourceList || xfbCount == 0) && g_ActiveConfig.bUseXFB && !g_ActiveConfig.bUseRealXFB)
|
||||
{
|
||||
g_VideoInitialize.pCopiedToXFB(false);
|
||||
Core::Callback_VideoCopiedToXFB(false);
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -1365,7 +1366,7 @@ void Renderer::Swap(u32 xfbAddr, FieldType field, u32 fbWidth, u32 fbHeight,cons
|
|||
// Renderer::SetZBufferRender();
|
||||
// SaveTexture("tex.tga", GL_TEXTURE_RECTANGLE_ARB, s_FakeZTarget,
|
||||
// GetTargetWidth(), GetTargetHeight());
|
||||
g_VideoInitialize.pCopiedToXFB(XFBWrited || (g_ActiveConfig.bUseXFB && g_ActiveConfig.bUseRealXFB));
|
||||
Core::Callback_VideoCopiedToXFB(XFBWrited || (g_ActiveConfig.bUseXFB && g_ActiveConfig.bUseRealXFB));
|
||||
XFBWrited = false;
|
||||
}
|
||||
|
||||
|
@ -1485,6 +1486,9 @@ void Renderer::FlipImageData(u8 *data, int w, int h)
|
|||
|
||||
}
|
||||
|
||||
// TODO: remove
|
||||
extern bool g_aspect_wide;
|
||||
|
||||
#if defined(HAVE_WX) && HAVE_WX
|
||||
void TakeScreenshot(ScrStrct* threadStruct)
|
||||
{
|
||||
|
@ -1495,7 +1499,7 @@ void TakeScreenshot(ScrStrct* threadStruct)
|
|||
// Handle aspect ratio for the final ScrStrct to look exactly like what's on screen.
|
||||
if (g_ActiveConfig.iAspectRatio != ASPECT_STRETCH)
|
||||
{
|
||||
bool use16_9 = g_VideoInitialize.bAutoAspectIs16_9;
|
||||
bool use16_9 = g_aspect_wide;
|
||||
|
||||
// Check for force-settings and override.
|
||||
if (g_ActiveConfig.iAspectRatio == ASPECT_FORCE_16_9)
|
||||
|
@ -1589,7 +1593,7 @@ void Renderer::SetWindowSize(int width, int height)
|
|||
// Scale the window size by the EFB scale.
|
||||
CalculateTargetScale(width, height, width, height);
|
||||
|
||||
g_VideoInitialize.pRequestWindowSize(width, height);
|
||||
Core::Callback_VideoRequestWindowSize(width, height);
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -50,6 +50,15 @@ public:
|
|||
bool SaveScreenshot(const std::string &filename, const TargetRectangle &rc);
|
||||
|
||||
void SetWindowSize(int width, int height);
|
||||
|
||||
void SetPSConstant4f(unsigned int const_number, float f1, float f2, float f3, float f4);
|
||||
void SetPSConstant4fv(unsigned int const_number, const float *f);
|
||||
void SetMultiPSConstant4fv(unsigned int const_number, unsigned int count, const float *f);
|
||||
|
||||
void SetVSConstant4f(unsigned int const_number, float f1, float f2, float f3, float f4);
|
||||
void SetVSConstant4fv(unsigned int const_number, const float *f);
|
||||
void SetMultiVSConstant3fv(unsigned int const_number, unsigned int count, const float *f);
|
||||
void SetMultiVSConstant4fv(unsigned int const_number, unsigned int count, const float *f);
|
||||
};
|
||||
|
||||
}
|
||||
|
|
|
@ -18,6 +18,8 @@
|
|||
// Fast image conversion using OpenGL shaders.
|
||||
// This kind of stuff would be a LOT nicer with OpenCL.
|
||||
|
||||
#include <math.h>
|
||||
|
||||
#include "TextureConverter.h"
|
||||
#include "TextureConversionShader.h"
|
||||
#include "TextureCache.h"
|
||||
|
@ -28,8 +30,8 @@
|
|||
#include "VideoConfig.h"
|
||||
#include "ImageWrite.h"
|
||||
#include "Render.h"
|
||||
#include <math.h>
|
||||
#include "FileUtil.h"
|
||||
#include "HW/Memmap.h"
|
||||
|
||||
namespace OGL
|
||||
{
|
||||
|
@ -265,7 +267,7 @@ void EncodeToRam(u32 address, bool bFromZBuffer, bool bIsIntensityFmt, u32 copyf
|
|||
if (texconv_shader.glprogid == 0)
|
||||
return;
|
||||
|
||||
u8 *dest_ptr = Memory_GetPtr(address);
|
||||
u8 *dest_ptr = Memory::GetPointer(address);
|
||||
|
||||
GLuint source_texture = bFromZBuffer ? FramebufferManager::ResolveAndGetDepthTarget(source) : FramebufferManager::ResolveAndGetRenderTarget(source);
|
||||
|
||||
|
@ -336,7 +338,7 @@ u64 EncodeToRamFromTexture(u32 address,GLuint source_texture, bool bFromZBuffer,
|
|||
if (texconv_shader.glprogid == 0)
|
||||
return 0;
|
||||
|
||||
u8 *dest_ptr = Memory_GetPtr(address);
|
||||
u8 *dest_ptr = Memory::GetPointer(address);
|
||||
|
||||
int width = (source.right - source.left) >> bScaleByHalf;
|
||||
int height = (source.bottom - source.top) >> bScaleByHalf;
|
||||
|
@ -405,7 +407,7 @@ void EncodeToRamYUYV(GLuint srcTexture, const TargetRectangle& sourceRc, u8* des
|
|||
// Should be scale free.
|
||||
void DecodeToTexture(u32 xfbAddr, int srcWidth, int srcHeight, GLuint destTexture)
|
||||
{
|
||||
u8* srcAddr = Memory_GetPtr(xfbAddr);
|
||||
u8* srcAddr = Memory::GetPointer(xfbAddr);
|
||||
if (!srcAddr)
|
||||
{
|
||||
WARN_LOG(VIDEO, "Tried to decode from invalid memory address");
|
||||
|
|
|
@ -210,19 +210,17 @@ void VertexShaderCache::SetCurrentShader(GLuint Shader)
|
|||
}
|
||||
}
|
||||
|
||||
} // namespace OGL
|
||||
|
||||
void SetVSConstant4f(unsigned int const_number, float f1, float f2, float f3, float f4)
|
||||
void Renderer::SetVSConstant4f(unsigned int const_number, float f1, float f2, float f3, float f4)
|
||||
{
|
||||
glProgramEnvParameter4fARB(GL_VERTEX_PROGRAM_ARB, const_number, f1, f2, f3, f4);
|
||||
}
|
||||
|
||||
void SetVSConstant4fv(unsigned int const_number, const float *f)
|
||||
void Renderer::SetVSConstant4fv(unsigned int const_number, const float *f)
|
||||
{
|
||||
glProgramEnvParameter4fvARB(GL_VERTEX_PROGRAM_ARB, const_number, f);
|
||||
}
|
||||
|
||||
void SetMultiVSConstant4fv(unsigned int const_number, unsigned int count, const float *f)
|
||||
void Renderer::SetMultiVSConstant4fv(unsigned int const_number, unsigned int count, const float *f)
|
||||
{
|
||||
if(GLEW_EXT_gpu_program_parameters)
|
||||
{
|
||||
|
@ -235,7 +233,7 @@ void SetMultiVSConstant4fv(unsigned int const_number, unsigned int count, const
|
|||
}
|
||||
}
|
||||
|
||||
void SetMultiVSConstant3fv(unsigned int const_number, unsigned int count, const float *f)
|
||||
void Renderer::SetMultiVSConstant3fv(unsigned int const_number, unsigned int count, const float *f)
|
||||
{
|
||||
if(GLEW_EXT_gpu_program_parameters)
|
||||
{
|
||||
|
@ -262,3 +260,5 @@ void SetMultiVSConstant3fv(unsigned int const_number, unsigned int count, const
|
|||
}
|
||||
}
|
||||
}
|
||||
|
||||
} // namespace OGL
|
||||
|
|
27
Source/Plugins/Plugin_VideoOGL/Src/VideoBackend.h
Normal file
27
Source/Plugins/Plugin_VideoOGL/Src/VideoBackend.h
Normal file
|
@ -0,0 +1,27 @@
|
|||
|
||||
#ifndef OGL_VIDEO_BACKEND_H_
|
||||
#define OGL_VIDEO_BACKEND_H_
|
||||
|
||||
#include "VideoBackendBase.h"
|
||||
|
||||
namespace OGL
|
||||
{
|
||||
|
||||
class VideoBackend : public VideoBackendHLE
|
||||
{
|
||||
void Initialize();
|
||||
void Shutdown();
|
||||
|
||||
std::string GetName();
|
||||
|
||||
void Video_Prepare();
|
||||
|
||||
void ShowConfig(void* parent);
|
||||
|
||||
void UpdateFPSDisplay(const char*);
|
||||
unsigned int PeekMessages();
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
#endif
|
|
@ -92,109 +92,21 @@ Make AA apply instantly during gameplay if possible
|
|||
#include "Setup.h"
|
||||
#include "DLCache.h"
|
||||
#include "FramebufferManager.h"
|
||||
#include "Core.h"
|
||||
|
||||
#include "VideoState.h"
|
||||
#include "VideoBackend.h"
|
||||
#include "ConfigManager.h"
|
||||
|
||||
// Logging
|
||||
int GLScissorX, GLScissorY, GLScissorW, GLScissorH;
|
||||
|
||||
#ifdef _WIN32
|
||||
HINSTANCE g_hInstance;
|
||||
|
||||
wxLocale *InitLanguageSupport()
|
||||
namespace OGL
|
||||
{
|
||||
wxLocale *m_locale;
|
||||
unsigned int language = 0;
|
||||
|
||||
IniFile ini;
|
||||
ini.Load(File::GetUserPath(F_DOLPHINCONFIG_IDX));
|
||||
ini.Get("Interface", "Language", &language, wxLANGUAGE_DEFAULT);
|
||||
|
||||
// Load language if possible, fall back to system default otherwise
|
||||
if(wxLocale::IsAvailable(language))
|
||||
{
|
||||
m_locale = new wxLocale(language);
|
||||
|
||||
m_locale->AddCatalogLookupPathPrefix(wxT("Languages"));
|
||||
|
||||
m_locale->AddCatalog(wxT("dolphin-emu"));
|
||||
|
||||
if(!m_locale->IsOk())
|
||||
{
|
||||
PanicAlertT("Error loading selected language. Falling back to system default.");
|
||||
delete m_locale;
|
||||
m_locale = new wxLocale(wxLANGUAGE_DEFAULT);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
PanicAlertT("The selected language is not supported by your system. Falling back to system default.");
|
||||
m_locale = new wxLocale(wxLANGUAGE_DEFAULT);
|
||||
}
|
||||
return m_locale;
|
||||
}
|
||||
|
||||
class wxDLLApp : public wxApp
|
||||
std::string VideoBackend::GetName()
|
||||
{
|
||||
bool OnInit()
|
||||
{
|
||||
return true;
|
||||
}
|
||||
};
|
||||
IMPLEMENT_APP_NO_MAIN(wxDLLApp)
|
||||
WXDLLIMPEXP_BASE void wxSetInstance(HINSTANCE hInst);
|
||||
// ------------------
|
||||
|
||||
BOOL APIENTRY DllMain(HINSTANCE hinstDLL, DWORD dwReason, LPVOID lpvReserved)
|
||||
{
|
||||
static wxLocale *m_locale;
|
||||
switch (dwReason)
|
||||
{
|
||||
case DLL_PROCESS_ATTACH:
|
||||
{
|
||||
wxSetInstance((HINSTANCE)hinstDLL);
|
||||
wxInitialize();
|
||||
m_locale = InitLanguageSupport();
|
||||
}
|
||||
break;
|
||||
|
||||
case DLL_PROCESS_DETACH:
|
||||
wxUninitialize();
|
||||
delete m_locale;
|
||||
break;
|
||||
}
|
||||
|
||||
g_hInstance = hinstDLL;
|
||||
return TRUE;
|
||||
}
|
||||
#endif // _WIN32
|
||||
|
||||
void GetDllInfo(PLUGIN_INFO* _PluginInfo)
|
||||
{
|
||||
_PluginInfo->Version = 0x0100;
|
||||
_PluginInfo->Type = PLUGIN_TYPE_VIDEO;
|
||||
#ifdef DEBUGFAST
|
||||
sprintf(_PluginInfo->Name, "Dolphin OpenGL (DebugFast)");
|
||||
#elif defined _DEBUG
|
||||
sprintf(_PluginInfo->Name, "Dolphin OpenGL (Debug)");
|
||||
#else
|
||||
sprintf(_PluginInfo->Name, _trans("Dolphin OpenGL"));
|
||||
#endif
|
||||
}
|
||||
|
||||
void SetDllGlobals(PLUGIN_GLOBALS* _pPluginGlobals)
|
||||
{
|
||||
globals = _pPluginGlobals;
|
||||
LogManager::SetInstance((LogManager*)globals->logManager);
|
||||
}
|
||||
|
||||
void *DllDebugger(void *_hParent, bool Show)
|
||||
{
|
||||
#if defined(HAVE_WX) && HAVE_WX
|
||||
return new GFXDebuggerPanel((wxWindow *)_hParent);
|
||||
#else
|
||||
return NULL;
|
||||
#endif
|
||||
return "OpenGL";
|
||||
}
|
||||
|
||||
void GetShaders(std::vector<std::string> &shaders)
|
||||
|
@ -231,7 +143,7 @@ void InitBackendInfo()
|
|||
g_Config.backend_info.bSupportsPixelLighting = true;
|
||||
}
|
||||
|
||||
void DllConfig(void *_hParent)
|
||||
void VideoBackend::ShowConfig(void *_hParent)
|
||||
{
|
||||
#if defined(HAVE_WX) && HAVE_WX
|
||||
InitBackendInfo();
|
||||
|
@ -249,18 +161,15 @@ void DllConfig(void *_hParent)
|
|||
#endif
|
||||
}
|
||||
|
||||
void Initialize(void *init)
|
||||
void VideoBackend::Initialize()
|
||||
{
|
||||
InitBackendInfo();
|
||||
|
||||
frameCount = 0;
|
||||
SVideoInitialize *_pVideoInitialize = (SVideoInitialize*)init;
|
||||
// Create a shortcut to _pVideoInitialize that can also update it
|
||||
g_VideoInitialize = *(_pVideoInitialize);
|
||||
InitXFBConvTables();
|
||||
|
||||
g_Config.Load((std::string(File::GetUserPath(D_CONFIG_IDX)) + "gfx_opengl.ini").c_str());
|
||||
g_Config.GameIniLoad(globals->game_ini);
|
||||
g_Config.GameIniLoad(SConfig::GetInstance().m_LocalCoreStartupParameter.m_strGameIni.c_str());
|
||||
|
||||
g_Config.UpdateProjectionHack();
|
||||
#if defined _WIN32
|
||||
|
@ -269,25 +178,20 @@ void Initialize(void *init)
|
|||
#endif
|
||||
UpdateActiveConfig();
|
||||
|
||||
if (!OpenGL_Create(g_VideoInitialize, 640, 480))
|
||||
if (!OpenGL_Create(640, 480))
|
||||
{
|
||||
g_VideoInitialize.pLog("Renderer::Create failed\n", TRUE);
|
||||
return;
|
||||
}
|
||||
|
||||
_pVideoInitialize->pPeekMessages = g_VideoInitialize.pPeekMessages;
|
||||
_pVideoInitialize->pUpdateFPSDisplay = g_VideoInitialize.pUpdateFPSDisplay;
|
||||
|
||||
// Now the window handle is written
|
||||
_pVideoInitialize->pWindowHandle = g_VideoInitialize.pWindowHandle;
|
||||
|
||||
OSD::AddMessage("Dolphin OpenGL Video Plugin.", 5000);
|
||||
s_PluginInitialized = true;
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
// This is called after Initialize() from the Core
|
||||
// Run from the graphics thread
|
||||
void Video_Prepare()
|
||||
void VideoBackend::Video_Prepare()
|
||||
{
|
||||
OpenGL_MakeCurrent();
|
||||
//if (!Renderer::Init()) {
|
||||
|
@ -296,7 +200,7 @@ void Video_Prepare()
|
|||
// exit(1);
|
||||
//}
|
||||
|
||||
g_renderer = new OGL::Renderer;
|
||||
g_renderer = new Renderer;
|
||||
|
||||
s_efbAccessRequested = FALSE;
|
||||
s_FifoShuttingDown = FALSE;
|
||||
|
@ -305,31 +209,31 @@ void Video_Prepare()
|
|||
CommandProcessor::Init();
|
||||
PixelEngine::Init();
|
||||
|
||||
g_texture_cache = new OGL::TextureCache;
|
||||
g_texture_cache = new TextureCache;
|
||||
|
||||
BPInit();
|
||||
g_vertex_manager = new OGL::VertexManager;
|
||||
g_vertex_manager = new VertexManager;
|
||||
Fifo_Init(); // must be done before OpcodeDecoder_Init()
|
||||
OpcodeDecoder_Init();
|
||||
OGL::VertexShaderCache::Init();
|
||||
VertexShaderCache::Init();
|
||||
VertexShaderManager::Init();
|
||||
OGL::PixelShaderCache::Init();
|
||||
PixelShaderCache::Init();
|
||||
PixelShaderManager::Init();
|
||||
OGL::PostProcessing::Init();
|
||||
PostProcessing::Init();
|
||||
GL_REPORT_ERRORD();
|
||||
VertexLoaderManager::Init();
|
||||
OGL::TextureConverter::Init();
|
||||
TextureConverter::Init();
|
||||
DLCache::Init();
|
||||
|
||||
// Notify the core that the video plugin is ready
|
||||
g_VideoInitialize.pCoreMessage(WM_USER_CREATE);
|
||||
Core::Callback_CoreMessage(WM_USER_CREATE);
|
||||
|
||||
s_PluginInitialized = true;
|
||||
INFO_LOG(VIDEO, "Video plugin initialized.");
|
||||
|
||||
}
|
||||
|
||||
void Shutdown()
|
||||
void VideoBackend::Shutdown()
|
||||
{
|
||||
s_PluginInitialized = false;
|
||||
|
||||
|
@ -354,3 +258,5 @@ void Shutdown()
|
|||
delete g_renderer;
|
||||
OpenGL_Shutdown();
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -18,9 +18,6 @@
|
|||
#ifndef _MAIN_H_
|
||||
#define _MAIN_H_
|
||||
|
||||
#include "pluginspecs_video.h"
|
||||
#include "MainBase.h"
|
||||
|
||||
extern SVideoInitialize g_VideoInitialize;
|
||||
|
||||
#endif // _MAIN_H_
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
<VisualStudioProject
|
||||
ProjectType="Visual C++"
|
||||
Version="9.00"
|
||||
Name="Plugin_VideoSoftware"
|
||||
Name="VideoSoftware"
|
||||
ProjectGUID="{66A4E7BD-E2E8-4373-9B75-8750EB5AE683}"
|
||||
RootNamespace="Plugin_VideoSoftware"
|
||||
Keyword="Win32Proj"
|
||||
|
@ -23,7 +23,7 @@
|
|||
Name="Debug|Win32"
|
||||
OutputDirectory="$(PlatformName)\$(ConfigurationName)"
|
||||
IntermediateDirectory="$(PlatformName)\$(ConfigurationName)"
|
||||
ConfigurationType="2"
|
||||
ConfigurationType="4"
|
||||
CharacterSet="1"
|
||||
>
|
||||
<Tool
|
||||
|
@ -44,7 +44,7 @@
|
|||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
Optimization="0"
|
||||
AdditionalIncludeDirectories="../../PluginSpecs;../../Core/Common/Src;../../Core/InputCommon/Src;../../Core/VideoCommon/Src;./Src;./Src/Windows;../../../Externals;..\..\..\Externals\libjpeg;..\..\..\Externals\wxWidgets\Include;..\..\..\Externals\wxWidgets\Include\msvc;..\..\..\Externals\Glew\include;..\..\..\Externals\CLRun\include"
|
||||
AdditionalIncludeDirectories="../../PluginSpecs;../../Core/Common/Src;../../Core/Core/Src;../../Core/InputCommon/Src;../../Core/VideoCommon/Src;./Src;./Src/Windows;../../../Externals;..\..\..\Externals\libjpeg;..\..\..\Externals\wxWidgets\Include;..\..\..\Externals\wxWidgets\Include\msvc;..\..\..\Externals\Glew\include;..\..\..\Externals\CLRun\include"
|
||||
PreprocessorDefinitions="WIN32;_DEBUG;_WINDOWS;_USRDLL;_WIN32;_CRT_SECURE_NO_DEPRECATE;_SECURE_SCL=0"
|
||||
MinimalRebuild="false"
|
||||
BasicRuntimeChecks="3"
|
||||
|
@ -68,27 +68,11 @@
|
|||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLinkerTool"
|
||||
IgnoreImportLibrary="false"
|
||||
AdditionalDependencies="odbc32.lib odbccp32.lib comctl32.lib winmm.lib opengl32.lib glew32s.lib glu32.lib rpcrt4.lib"
|
||||
OutputFile="..\..\..\Binary\Win32/Plugins\Plugin_VideoSWD.dll"
|
||||
LinkIncremental="1"
|
||||
AdditionalLibraryDirectories=""..\..\core\common\$(PlatformName)\$(ConfigurationName)";..\..\..\Externals\Cg;..\..\..\Externals\GLew;..\..\..\Externals\libjpeg;"..\..\..\Externals\wxWidgets\lib\vc_lib\$(PlatformName)""
|
||||
IgnoreDefaultLibraryNames=""
|
||||
GenerateDebugInformation="true"
|
||||
ProgramDatabaseFile="$(PlatformName)\$(ConfigurationName)\$(TargetName).pdb"
|
||||
SubSystem="0"
|
||||
RandomizedBaseAddress="1"
|
||||
DataExecutionPrevention="0"
|
||||
ImportLibrary="$(PlatformName)\$(ConfigurationName)\$(TargetName).lib"
|
||||
TargetMachine="1"
|
||||
Name="VCLibrarianTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManifestTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
|
@ -98,9 +82,6 @@
|
|||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCAppVerifierTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
/>
|
||||
|
@ -109,7 +90,7 @@
|
|||
Name="Debug|x64"
|
||||
OutputDirectory="$(PlatformName)\$(ConfigurationName)"
|
||||
IntermediateDirectory="$(PlatformName)\$(ConfigurationName)"
|
||||
ConfigurationType="2"
|
||||
ConfigurationType="4"
|
||||
CharacterSet="1"
|
||||
>
|
||||
<Tool
|
||||
|
@ -131,7 +112,7 @@
|
|||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
Optimization="0"
|
||||
AdditionalIncludeDirectories="../../PluginSpecs;../../Core/Common/Src;../../Core/InputCommon/Src;../../Core/VideoCommon/Src;./Src;./Src/Windows;../../../Externals;..\..\..\Externals\libjpeg;..\..\..\Externals\wxWidgets\Include;..\..\..\Externals\wxWidgets\Include\msvc;..\..\..\Externals\Glew\include;..\..\..\Externals\CLRun\include"
|
||||
AdditionalIncludeDirectories="../../PluginSpecs;../../Core/Common/Src;../../Core/Core/Src;../../Core/InputCommon/Src;../../Core/VideoCommon/Src;./Src;./Src/Windows;../../../Externals;..\..\..\Externals\libjpeg;..\..\..\Externals\wxWidgets\Include;..\..\..\Externals\wxWidgets\Include\msvc;..\..\..\Externals\Glew\include;..\..\..\Externals\CLRun\include"
|
||||
PreprocessorDefinitions="WIN32;_DEBUG;_WINDOWS;_USRDLL;_WIN32;_CRT_SECURE_NO_DEPRECATE;_SECURE_SCL=0"
|
||||
MinimalRebuild="false"
|
||||
BasicRuntimeChecks="3"
|
||||
|
@ -155,28 +136,11 @@
|
|||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLinkerTool"
|
||||
IgnoreImportLibrary="false"
|
||||
AdditionalDependencies="odbc32.lib odbccp32.lib comctl32.lib winmm.lib opengl32.lib glew64s.lib glu32.lib rpcrt4.lib"
|
||||
OutputFile="..\..\..\Binary\x64\Plugins\Plugin_VideoSWD.dll"
|
||||
LinkIncremental="1"
|
||||
AdditionalLibraryDirectories=""..\..\core\common\$(PlatformName)\$(ConfigurationName)";..\..\..\Externals\Cg;..\..\..\Externals\GLew;..\..\..\Externals\libjpeg;"..\..\..\Externals\wxWidgets\lib\vc_lib\$(PlatformName)""
|
||||
IgnoreAllDefaultLibraries="false"
|
||||
IgnoreDefaultLibraryNames=""
|
||||
GenerateDebugInformation="true"
|
||||
ProgramDatabaseFile="$(PlatformName)\$(ConfigurationName)\$(TargetName).pdb"
|
||||
SubSystem="0"
|
||||
RandomizedBaseAddress="1"
|
||||
DataExecutionPrevention="0"
|
||||
ImportLibrary="$(PlatformName)\$(ConfigurationName)\$(TargetName).lib"
|
||||
TargetMachine="17"
|
||||
Name="VCLibrarianTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManifestTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
|
@ -186,9 +150,6 @@
|
|||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCAppVerifierTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
/>
|
||||
|
@ -197,7 +158,7 @@
|
|||
Name="Release|Win32"
|
||||
OutputDirectory="$(PlatformName)\$(ConfigurationName)"
|
||||
IntermediateDirectory="$(PlatformName)\$(ConfigurationName)"
|
||||
ConfigurationType="2"
|
||||
ConfigurationType="4"
|
||||
CharacterSet="1"
|
||||
WholeProgramOptimization="1"
|
||||
>
|
||||
|
@ -220,7 +181,7 @@
|
|||
Name="VCCLCompilerTool"
|
||||
Optimization="2"
|
||||
EnableIntrinsicFunctions="true"
|
||||
AdditionalIncludeDirectories="../../PluginSpecs;../../Core/Common/Src;../../Core/InputCommon/Src;../../Core/VideoCommon/Src;./Src;./Src/Windows;../../../Externals;..\..\..\Externals\libjpeg;..\..\..\Externals\wxWidgets\Include;..\..\..\Externals\wxWidgets\Include\msvc;..\..\..\Externals\Glew\include;..\..\..\Externals\CLRun\include"
|
||||
AdditionalIncludeDirectories="../../PluginSpecs;../../Core/Common/Src;../../Core/Core/Src;../../Core/InputCommon/Src;../../Core/VideoCommon/Src;./Src;./Src/Windows;../../../Externals;..\..\..\Externals\libjpeg;..\..\..\Externals\wxWidgets\Include;..\..\..\Externals\wxWidgets\Include\msvc;..\..\..\Externals\Glew\include;..\..\..\Externals\CLRun\include"
|
||||
PreprocessorDefinitions="WIN32;_WINDOWS;_USRDLL;_WIN32;PLUGIN_VIDEOSOFTWARE_EXPORTS;_CRT_SECURE_NO_DEPRECATE;_SECURE_SCL=0"
|
||||
RuntimeLibrary="0"
|
||||
EnableFunctionLevelLinking="true"
|
||||
|
@ -241,28 +202,11 @@
|
|||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLinkerTool"
|
||||
IgnoreImportLibrary="false"
|
||||
AdditionalDependencies="odbc32.lib odbccp32.lib comctl32.lib winmm.lib opengl32.lib glew32s.lib glu32.lib rpcrt4.lib libjpeg.lib"
|
||||
OutputFile="..\..\..\Binary\Win32/Plugins\Plugin_VideoSW.dll"
|
||||
LinkIncremental="1"
|
||||
AdditionalLibraryDirectories=""..\..\core\common\$(PlatformName)\$(ConfigurationName)";..\..\..\Externals\Cg;..\..\..\Externals\GLew;..\..\..\Externals\libjpeg;"..\..\..\Externals\wxWidgets\lib\vc_lib\$(PlatformName)""
|
||||
IgnoreAllDefaultLibraries="false"
|
||||
IgnoreDefaultLibraryNames=""
|
||||
GenerateDebugInformation="true"
|
||||
ProgramDatabaseFile="$(PlatformName)\$(ConfigurationName)\$(TargetName).pdb"
|
||||
SubSystem="2"
|
||||
OptimizeReferences="2"
|
||||
EnableCOMDATFolding="2"
|
||||
ImportLibrary="$(PlatformName)\$(ConfigurationName)\$(TargetName).lib"
|
||||
TargetMachine="1"
|
||||
Name="VCLibrarianTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManifestTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
|
@ -272,9 +216,6 @@
|
|||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCAppVerifierTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
/>
|
||||
|
@ -283,7 +224,7 @@
|
|||
Name="Release|x64"
|
||||
OutputDirectory="$(PlatformName)\$(ConfigurationName)"
|
||||
IntermediateDirectory="$(PlatformName)\$(ConfigurationName)"
|
||||
ConfigurationType="2"
|
||||
ConfigurationType="4"
|
||||
CharacterSet="1"
|
||||
WholeProgramOptimization="1"
|
||||
>
|
||||
|
@ -308,7 +249,7 @@
|
|||
AdditionalOptions="/MP"
|
||||
Optimization="2"
|
||||
EnableIntrinsicFunctions="true"
|
||||
AdditionalIncludeDirectories="../../PluginSpecs;../../Core/Common/Src;../../Core/InputCommon/Src;../../Core/VideoCommon/Src;./Src;./Src/Windows;../../../Externals;..\..\..\Externals\libjpeg;..\..\..\Externals\wxWidgets\Include;..\..\..\Externals\wxWidgets\Include\msvc;..\..\..\Externals\Glew\include;..\..\..\Externals\CLRun\include"
|
||||
AdditionalIncludeDirectories="../../PluginSpecs;../../Core/Common/Src;../../Core/Core/Src;../../Core/InputCommon/Src;../../Core/VideoCommon/Src;./Src;./Src/Windows;../../../Externals;..\..\..\Externals\libjpeg;..\..\..\Externals\wxWidgets\Include;..\..\..\Externals\wxWidgets\Include\msvc;..\..\..\Externals\Glew\include;..\..\..\Externals\CLRun\include"
|
||||
PreprocessorDefinitions="WIN32;_WINDOWS;_USRDLL;_WIN32;PLUGIN_VIDEOSOFTWARE_EXPORTS;_CRT_SECURE_NO_DEPRECATE;_SECURE_SCL=0"
|
||||
RuntimeLibrary="0"
|
||||
EnableFunctionLevelLinking="true"
|
||||
|
@ -329,28 +270,11 @@
|
|||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLinkerTool"
|
||||
IgnoreImportLibrary="false"
|
||||
AdditionalDependencies="odbc32.lib odbccp32.lib comctl32.lib winmm.lib opengl32.lib glew64s.lib glu32.lib rpcrt4.lib libjpeg64.lib"
|
||||
OutputFile="..\..\..\Binary\x64\Plugins\Plugin_VideoSW.dll"
|
||||
LinkIncremental="1"
|
||||
AdditionalLibraryDirectories=""..\..\core\common\$(PlatformName)\$(ConfigurationName)";..\..\..\Externals\Cg;..\..\..\Externals\GLew;..\..\..\Externals\libjpeg;"..\..\..\Externals\wxWidgets\lib\vc_lib\$(PlatformName)""
|
||||
IgnoreAllDefaultLibraries="false"
|
||||
IgnoreDefaultLibraryNames=""
|
||||
GenerateDebugInformation="true"
|
||||
ProgramDatabaseFile="$(PlatformName)\$(ConfigurationName)\$(TargetName).pdb"
|
||||
SubSystem="2"
|
||||
OptimizeReferences="2"
|
||||
EnableCOMDATFolding="2"
|
||||
ImportLibrary="$(PlatformName)\$(ConfigurationName)\$(TargetName).lib"
|
||||
TargetMachine="17"
|
||||
Name="VCLibrarianTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManifestTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
|
@ -360,9 +284,6 @@
|
|||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCAppVerifierTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
/>
|
||||
|
@ -603,6 +524,14 @@
|
|||
RelativePath=".\Src\stdafx.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\Src\SWVideoConfig.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\Src\SWVideoConfig.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\Src\Tev.cpp"
|
||||
>
|
||||
|
@ -647,14 +576,6 @@
|
|||
RelativePath=".\Src\VertexLoader.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\Src\SWVideoConfig.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\Src\SWVideoConfig.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\Src\VideoConfigDialog.cpp"
|
||||
>
|
||||
|
|
|
@ -21,26 +21,27 @@
|
|||
<PropertyGroup Label="Globals">
|
||||
<ProjectGuid>{9E9DA440-E9AD-413C-B648-91030E792211}</ProjectGuid>
|
||||
<RootNamespace>Plugin_VideoSoftware</RootNamespace>
|
||||
<ProjectName>VideoSoftware</ProjectName>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
|
||||
<ConfigurationType>DynamicLibrary</ConfigurationType>
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>true</UseDebugLibraries>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">
|
||||
<ConfigurationType>DynamicLibrary</ConfigurationType>
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>true</UseDebugLibraries>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
|
||||
<ConfigurationType>DynamicLibrary</ConfigurationType>
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>false</UseDebugLibraries>
|
||||
<WholeProgramOptimization>true</WholeProgramOptimization>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
|
||||
<ConfigurationType>DynamicLibrary</ConfigurationType>
|
||||
<ConfigurationType>StaticLibrary</ConfigurationType>
|
||||
<UseDebugLibraries>false</UseDebugLibraries>
|
||||
<WholeProgramOptimization>true</WholeProgramOptimization>
|
||||
<CharacterSet>Unicode</CharacterSet>
|
||||
|
@ -91,7 +92,7 @@
|
|||
<ClCompile>
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
<Optimization>Disabled</Optimization>
|
||||
<AdditionalIncludeDirectories>..\..\Core\Common\Src;..\..\PluginSpecs;..\..\Core\VideoCommon\Src;..\..\..\Externals\GLew\include;..\..\..\Externals\wxWidgets\Include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<AdditionalIncludeDirectories>..\..\Core\Common\Src;..\..\Core\Core\Src;..\..\PluginSpecs;..\..\Core\VideoCommon\Src;..\..\..\Externals\GLew\include;..\..\..\Externals\wxWidgets\Include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<RuntimeLibrary>MultiThreadedDebug</RuntimeLibrary>
|
||||
<PreprocessorDefinitions>_SECURE_SCL=0;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<ForcedIncludeFiles>stdafx.h</ForcedIncludeFiles>
|
||||
|
@ -108,7 +109,7 @@
|
|||
<ClCompile>
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
<Optimization>Disabled</Optimization>
|
||||
<AdditionalIncludeDirectories>..\..\Core\Common\Src;..\..\PluginSpecs;..\..\Core\VideoCommon\Src;..\..\..\Externals\GLew\include;..\..\..\Externals\wxWidgets\Include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<AdditionalIncludeDirectories>..\..\Core\Common\Src;..\..\Core\Core\Src;..\..\PluginSpecs;..\..\Core\VideoCommon\Src;..\..\..\Externals\GLew\include;..\..\..\Externals\wxWidgets\Include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<RuntimeLibrary>MultiThreadedDebug</RuntimeLibrary>
|
||||
<PreprocessorDefinitions>_SECURE_SCL=0;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<ForcedIncludeFiles>stdafx.h</ForcedIncludeFiles>
|
||||
|
@ -127,7 +128,7 @@
|
|||
<Optimization>MaxSpeed</Optimization>
|
||||
<FunctionLevelLinking>true</FunctionLevelLinking>
|
||||
<IntrinsicFunctions>true</IntrinsicFunctions>
|
||||
<AdditionalIncludeDirectories>..\..\Core\Common\Src;..\..\PluginSpecs;..\..\Core\VideoCommon\Src;..\..\Core\VideoUICommon\Src;..\..\..\Externals\GLew\include;..\..\..\Externals\wxWidgets\Include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<AdditionalIncludeDirectories>..\..\Core\Common\Src;..\..\Core\Core\Src;..\..\PluginSpecs;..\..\Core\VideoCommon\Src;..\..\Core\VideoUICommon\Src;..\..\..\Externals\GLew\include;..\..\..\Externals\wxWidgets\Include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<RuntimeLibrary>MultiThreaded</RuntimeLibrary>
|
||||
<PreprocessorDefinitions>_SECURE_SCL=0;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<ForcedIncludeFiles>stdafx.h</ForcedIncludeFiles>
|
||||
|
@ -148,7 +149,7 @@
|
|||
<Optimization>MaxSpeed</Optimization>
|
||||
<FunctionLevelLinking>true</FunctionLevelLinking>
|
||||
<IntrinsicFunctions>true</IntrinsicFunctions>
|
||||
<AdditionalIncludeDirectories>..\..\Core\Common\Src;..\..\PluginSpecs;..\..\Core\VideoCommon\Src;..\..\Core\VideoUICommon\Src;..\..\..\Externals\GLew\include;..\..\..\Externals\wxWidgets\Include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<AdditionalIncludeDirectories>..\..\Core\Common\Src;..\..\Core\Core\Src;..\..\PluginSpecs;..\..\Core\VideoCommon\Src;..\..\Core\VideoUICommon\Src;..\..\..\Externals\GLew\include;..\..\..\Externals\wxWidgets\Include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<RuntimeLibrary>MultiThreaded</RuntimeLibrary>
|
||||
<PreprocessorDefinitions>_SECURE_SCL=0;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<ForcedIncludeFiles>stdafx.h</ForcedIncludeFiles>
|
||||
|
@ -183,17 +184,16 @@
|
|||
<ClCompile Include="Src\Statistics.cpp" />
|
||||
<ClCompile Include="Src\stdafx.cpp">
|
||||
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">Create</PrecompiledHeader>
|
||||
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">Create</PrecompiledHeader>
|
||||
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">Create</PrecompiledHeader>
|
||||
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">Create</PrecompiledHeader>
|
||||
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Release|x64'">Create</PrecompiledHeader>
|
||||
</ClCompile>
|
||||
<ClCompile Include="Src\SWVideoConfig.cpp" />
|
||||
<ClCompile Include="Src\Tev.cpp" />
|
||||
<ClCompile Include="Src\TextureEncoder.cpp" />
|
||||
<ClCompile Include="Src\TextureSampler.cpp" />
|
||||
<ClCompile Include="Src\TransformUnit.cpp" />
|
||||
<ClCompile Include="Src\VertexFormatConverter.cpp" />
|
||||
<ClCompile Include="Src\VertexLoader.cpp" />
|
||||
<ClCompile Include="Src\SWVideoConfig.cpp" />
|
||||
<ClCompile Include="Src\VideoConfigDialog.cpp" />
|
||||
<ClCompile Include="Src\Win32.cpp" />
|
||||
<ClCompile Include="Src\XFMemLoader.cpp" />
|
||||
|
@ -218,22 +218,19 @@
|
|||
<ClInclude Include="Src\SetupUnit.h" />
|
||||
<ClInclude Include="Src\Statistics.h" />
|
||||
<ClInclude Include="Src\stdafx.h" />
|
||||
<ClInclude Include="Src\SWVideoConfig.h" />
|
||||
<ClInclude Include="Src\Tev.h" />
|
||||
<ClInclude Include="Src\TextureEncoder.h" />
|
||||
<ClInclude Include="Src\TextureSampler.h" />
|
||||
<ClInclude Include="Src\TransformUnit.h" />
|
||||
<ClInclude Include="Src\Vec3.h" />
|
||||
<ClInclude Include="Src\VertexFormatConverter.h" />
|
||||
<ClInclude Include="Src\VertexLoader.h" />
|
||||
<ClInclude Include="Src\VertexLoader_Position.h" />
|
||||
<ClInclude Include="Src\SWVideoConfig.h" />
|
||||
<ClInclude Include="Src\VideoBackend.h" />
|
||||
<ClInclude Include="Src\VideoConfigDialog.h" />
|
||||
<ClInclude Include="Src\Win32.h" />
|
||||
<ClInclude Include="Src\XFMemLoader.h" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="Src\SConscript" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ProjectReference Include="..\..\..\Externals\wxWidgets\build\msw\wx_adv.vcxproj">
|
||||
<Project>{0e231fb1-f3c9-4724-accb-de8bcb3c089e}</Project>
|
||||
|
@ -248,7 +245,10 @@
|
|||
<Project>{3e5c4e02-1ba9-4776-bdbe-e3f91ffa34cf}</Project>
|
||||
</ProjectReference>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="Src\SConscript" />
|
||||
</ItemGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
|
||||
<ImportGroup Label="ExtensionTargets">
|
||||
</ImportGroup>
|
||||
</Project>
|
||||
</Project>
|
|
@ -15,7 +15,6 @@
|
|||
// Official SVN repository and contact information can be found at
|
||||
// http://code.google.com/p/dolphin-emu/
|
||||
|
||||
#include "pluginspecs_video.h"
|
||||
#include "../../../Core/VideoCommon/Src/VideoCommon.h"
|
||||
#include "main.h"
|
||||
|
||||
|
@ -25,9 +24,10 @@
|
|||
#include "PixelEngine.h"
|
||||
#include "Tev.h"
|
||||
#include "../../../Core/VideoCommon/Src/TextureDecoder.h"
|
||||
#include "HW/Memmap.h"
|
||||
#include "Core.h"
|
||||
|
||||
|
||||
BPMemory bpmem;
|
||||
extern BPMemory bpmem;
|
||||
|
||||
void InitBPMemory()
|
||||
{
|
||||
|
@ -104,10 +104,10 @@ void BPWritten(int address, int newvalue)
|
|||
u8 *ptr = 0;
|
||||
|
||||
// TODO - figure out a cleaner way.
|
||||
if (g_VideoInitialize.bWii)
|
||||
ptr = g_VideoInitialize.pGetMemoryPointer(bpmem.tlutXferSrc << 5);
|
||||
if (Core::g_CoreStartupParameter.bWii)
|
||||
ptr = Memory::GetPointer(bpmem.tlutXferSrc << 5);
|
||||
else
|
||||
ptr = g_VideoInitialize.pGetMemoryPointer((bpmem.tlutXferSrc & 0xFFFFF) << 5);
|
||||
ptr = Memory::GetPointer((bpmem.tlutXferSrc & 0xFFFFF) << 5);
|
||||
|
||||
if (ptr)
|
||||
memcpy_gc(texMem + tlutTMemAddr, ptr, tlutXferCount);
|
||||
|
|
|
@ -17,7 +17,7 @@
|
|||
#include "VideoCommon.h"
|
||||
|
||||
#include "CPMemLoader.h"
|
||||
|
||||
#include "HW/Memmap.h"
|
||||
|
||||
// CP state
|
||||
u8 *cached_arraybases[16];
|
||||
|
@ -71,7 +71,7 @@ void LoadCPReg(u32 sub_cmd, u32 value)
|
|||
// Pointers to vertex arrays in GC RAM
|
||||
case 0xA0:
|
||||
arraybases[sub_cmd & 0xF] = value;
|
||||
cached_arraybases[sub_cmd & 0xF] = Memory_GetPtr(value);
|
||||
cached_arraybases[sub_cmd & 0xF] = Memory::GetPointer(value);
|
||||
break;
|
||||
|
||||
case 0xB0:
|
||||
|
|
|
@ -16,9 +16,13 @@
|
|||
// http://code.google.com/p/dolphin-emu/
|
||||
|
||||
#include "Common.h"
|
||||
#include "pluginspecs_video.h"
|
||||
#include "Thread.h"
|
||||
#include "Atomic.h"
|
||||
#include "ConfigManager.h"
|
||||
#include "Core.h"
|
||||
#include "CoreTiming.h"
|
||||
#include "HW/Memmap.h"
|
||||
#include "HW/ProcessorInterface.h"
|
||||
|
||||
#include "CommandProcessor.h"
|
||||
#include "ChunkFile.h"
|
||||
|
@ -109,7 +113,7 @@ void Init()
|
|||
|
||||
cpreg.token = 0;
|
||||
|
||||
et_UpdateInterrupts = g_VideoInitialize.pRegisterEvent("UpdateInterrupts", UpdateInterrupts_Wrapper);
|
||||
et_UpdateInterrupts = CoreTiming::RegisterEvent("UpdateInterrupts", UpdateInterrupts_Wrapper);
|
||||
|
||||
// internal buffer position
|
||||
readPos = 0;
|
||||
|
@ -128,7 +132,7 @@ void Shutdown()
|
|||
|
||||
void RunGpu()
|
||||
{
|
||||
if (!g_VideoInitialize.bOnThread)
|
||||
if (!SConfig::GetInstance().m_LocalCoreStartupParameter.bCPUThread)
|
||||
{
|
||||
// We are going to do FP math on the main thread so have to save the current state
|
||||
SaveSSEState();
|
||||
|
@ -309,20 +313,20 @@ void UpdateInterrupts(u64 userdata)
|
|||
{
|
||||
interruptSet = true;
|
||||
INFO_LOG(COMMANDPROCESSOR,"Interrupt set");
|
||||
g_VideoInitialize.pSetInterrupt(INT_CAUSE_CP, true);
|
||||
ProcessorInterface::SetInterrupt(INT_CAUSE_CP, true);
|
||||
}
|
||||
else
|
||||
{
|
||||
interruptSet = false;
|
||||
INFO_LOG(COMMANDPROCESSOR,"Interrupt cleared");
|
||||
g_VideoInitialize.pSetInterrupt(INT_CAUSE_CP, false);
|
||||
ProcessorInterface::SetInterrupt(INT_CAUSE_CP, false);
|
||||
}
|
||||
interruptWaiting = false;
|
||||
}
|
||||
|
||||
void UpdateInterruptsFromVideoPlugin(u64 userdata)
|
||||
{
|
||||
g_VideoInitialize.pScheduleEvent_Threadsafe(0, et_UpdateInterrupts, userdata);
|
||||
CoreTiming::ScheduleEvent_Threadsafe(0, et_UpdateInterrupts, userdata);
|
||||
}
|
||||
|
||||
void ReadFifo()
|
||||
|
@ -333,7 +337,7 @@ void ReadFifo()
|
|||
if (canRead && !atBreakpoint)
|
||||
{
|
||||
// read from fifo
|
||||
u8 *ptr = g_VideoInitialize.pGetMemoryPointer(cpreg.readptr);
|
||||
u8 *ptr = Memory::GetPointer(cpreg.readptr);
|
||||
int bytesRead = 0;
|
||||
|
||||
do
|
||||
|
@ -346,7 +350,7 @@ void ReadFifo()
|
|||
if (cpreg.readptr == cpreg.fifoend)
|
||||
{
|
||||
cpreg.readptr = cpreg.fifobase;
|
||||
ptr = g_VideoInitialize.pGetMemoryPointer(cpreg.readptr);
|
||||
ptr = Memory::GetPointer(cpreg.readptr);
|
||||
}
|
||||
else
|
||||
{
|
||||
|
@ -400,7 +404,7 @@ void SetStatus()
|
|||
if (interrupt != interruptSet && !interruptWaiting)
|
||||
{
|
||||
u64 userdata = interrupt?1:0;
|
||||
if (g_VideoInitialize.bOnThread)
|
||||
if (SConfig::GetInstance().m_LocalCoreStartupParameter.bCPUThread)
|
||||
{
|
||||
interruptWaiting = true;
|
||||
CommandProcessor::UpdateInterruptsFromVideoPlugin(userdata);
|
||||
|
@ -470,13 +474,13 @@ bool RunBuffer()
|
|||
// fifo functions
|
||||
#if (SW_PLUGIN)
|
||||
|
||||
void Fifo_EnterLoop(const SVideoInitialize &video_initialize)
|
||||
void Fifo_EnterLoop()
|
||||
{
|
||||
fifoStateRun = true;
|
||||
|
||||
while (fifoStateRun)
|
||||
{
|
||||
g_VideoInitialize.pPeekMessages();
|
||||
g_video_backend->PeekMessages();
|
||||
if (!CommandProcessor::RunBuffer()) {
|
||||
Common::YieldCPU();
|
||||
}
|
||||
|
|
|
@ -19,7 +19,7 @@
|
|||
#define _COMMANDPROCESSOR_H_
|
||||
|
||||
#include "Common.h"
|
||||
#include "pluginspecs_video.h"
|
||||
|
||||
class PointerWrap;
|
||||
|
||||
extern volatile bool g_bSkipCurrentFrame;
|
||||
|
@ -29,7 +29,7 @@ void Fifo_Init();
|
|||
void Fifo_Shutdown();
|
||||
void Fifo_DoState(PointerWrap &p);
|
||||
|
||||
void Fifo_EnterLoop(const SVideoInitialize &video_initialize);
|
||||
void Fifo_EnterLoop();
|
||||
void Fifo_ExitLoop();
|
||||
void Fifo_SetRendering(bool bEnabled);
|
||||
|
||||
|
|
|
@ -27,7 +27,8 @@
|
|||
#include "HwRasterizer.h"
|
||||
#include "CommandProcessor.h"
|
||||
#include "GLUtil.h"
|
||||
|
||||
#include "HW/Memmap.h"
|
||||
#include "Core.h"
|
||||
|
||||
namespace EfbCopy
|
||||
{
|
||||
|
@ -50,7 +51,7 @@ namespace EfbCopy
|
|||
{
|
||||
if (!g_SWVideoConfig.bHwRasterizer)
|
||||
{
|
||||
u8 *dest_ptr = g_VideoInitialize.pGetMemoryPointer(bpmem.copyTexDest << 5);
|
||||
u8 *dest_ptr = Memory::GetPointer(bpmem.copyTexDest << 5);
|
||||
|
||||
TextureEncoder::Encode(dest_ptr);
|
||||
}
|
||||
|
@ -85,7 +86,7 @@ namespace EfbCopy
|
|||
if (bpmem.triggerEFBCopy.copy_to_xfb)
|
||||
{
|
||||
CopyToXfb();
|
||||
g_VideoInitialize.pCopiedToXFB(false);
|
||||
Core::Callback_VideoCopiedToXFB(false);
|
||||
|
||||
stats.frameCount++;
|
||||
}
|
||||
|
@ -107,7 +108,7 @@ namespace EfbCopy
|
|||
if (bpmem.triggerEFBCopy.copy_to_xfb)
|
||||
{
|
||||
// no frame rendered but tell that a frame has finished for frame skip counter
|
||||
g_VideoInitialize.pCopiedToXFB(false);
|
||||
Core::Callback_VideoCopiedToXFB(false);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -19,6 +19,9 @@
|
|||
#include "SWVideoConfig.h"
|
||||
#include "IniFile.h"
|
||||
#include "Setup.h"
|
||||
#include "ConfigManager.h"
|
||||
#include "Core.h"
|
||||
#include "Host.h"
|
||||
|
||||
#include "GLUtil.h"
|
||||
|
||||
|
@ -37,6 +40,11 @@ GLWindow GLWin;
|
|||
static int s_backbuffer_width;
|
||||
static int s_backbuffer_height;
|
||||
|
||||
static void*& VideoWindowHandle()
|
||||
{
|
||||
return SConfig::GetInstance().m_LocalCoreStartupParameter.hMainWindow;
|
||||
}
|
||||
|
||||
void OpenGL_SwapBuffers()
|
||||
{
|
||||
#if defined(USE_WX) && USE_WX
|
||||
|
@ -101,10 +109,10 @@ void UpdateFPSDisplay(const char *text)
|
|||
|
||||
// Create rendering window.
|
||||
// Call browser: Core.cpp:EmuThread() > main.cpp:Video_Initialize()
|
||||
bool OpenGL_Create(SVideoInitialize &_VideoInitialize, int _twidth, int _theight)
|
||||
bool OpenGL_Create(int _twidth, int _theight)
|
||||
{
|
||||
int xPos, yPos;
|
||||
g_VideoInitialize.pGetWindowSize(xPos, yPos, _twidth, _theight);
|
||||
Core::Callback_VideoGetWindowSize(xPos, yPos, _twidth, _theight);
|
||||
|
||||
#if defined(_WIN32)
|
||||
EmuWindow::SetSize(_twidth, _theight);
|
||||
|
@ -114,11 +122,8 @@ bool OpenGL_Create(SVideoInitialize &_VideoInitialize, int _twidth, int _theight
|
|||
s_backbuffer_width = _twidth;
|
||||
s_backbuffer_height = _theight;
|
||||
|
||||
g_VideoInitialize.pPeekMessages = &Callback_PeekMessages;
|
||||
g_VideoInitialize.pUpdateFPSDisplay = &UpdateFPSDisplay;
|
||||
|
||||
#if defined(USE_WX) && USE_WX
|
||||
GLWin.panel = (wxPanel *)g_VideoInitialize.pWindowHandle;
|
||||
GLWin.panel = (wxPanel*)VideoWindowHandle();
|
||||
GLWin.glCanvas = new wxGLCanvas(GLWin.panel, wxID_ANY, NULL,
|
||||
wxPoint(0, 0), wxSize(_twidth, _theight));
|
||||
GLWin.glCanvas->Show(true);
|
||||
|
@ -127,14 +132,14 @@ bool OpenGL_Create(SVideoInitialize &_VideoInitialize, int _twidth, int _theight
|
|||
|
||||
#elif defined(_WIN32)
|
||||
// Create rendering window in Windows
|
||||
g_VideoInitialize.pWindowHandle = (void*)EmuWindow::Create((HWND)g_VideoInitialize.pWindowHandle, g_hInstance, _T("Please wait..."));
|
||||
VideoWindowHandle() = (void*)EmuWindow::Create((HWND)VideoWindowHandle(), g_hInstance, _T("Please wait..."));
|
||||
|
||||
// Show the window
|
||||
EmuWindow::Show();
|
||||
|
||||
if (g_VideoInitialize.pWindowHandle == NULL)
|
||||
if (VideoWindowHandle() == NULL)
|
||||
{
|
||||
g_VideoInitialize.pSysMessage("failed to create window");
|
||||
Host_SysMessage("failed to create window");
|
||||
return false;
|
||||
}
|
||||
|
||||
|
@ -301,7 +306,7 @@ bool OpenGL_MakeCurrent()
|
|||
#elif defined(_WIN32)
|
||||
return wglMakeCurrent(hDC,hRC) ? true : false;
|
||||
#elif defined(HAVE_X11) && HAVE_X11
|
||||
g_VideoInitialize.pGetWindowSize(GLWin.x, GLWin.y, (int&)GLWin.width, (int&)GLWin.height);
|
||||
Core::Callback_VideoGetWindowSize(GLWin.x, GLWin.y, (int&)GLWin.width, (int&)GLWin.height);
|
||||
XMoveResizeWindow(GLWin.dpy, GLWin.win, GLWin.x, GLWin.y, GLWin.width, GLWin.height);
|
||||
return glXMakeCurrent(GLWin.dpy, GLWin.win, GLWin.ctx);
|
||||
#endif
|
||||
|
|
|
@ -21,7 +21,6 @@
|
|||
|
||||
#include <string>
|
||||
#include "SWVideoConfig.h"
|
||||
#include "pluginspecs_video.h"
|
||||
|
||||
#ifdef _WIN32
|
||||
#define GLEW_STATIC
|
||||
|
@ -78,7 +77,7 @@ extern GLWindow GLWin;
|
|||
// Public OpenGL util
|
||||
|
||||
// Initialization / upkeep
|
||||
bool OpenGL_Create(SVideoInitialize &_VideoInitialize, int _width, int _height);
|
||||
bool OpenGL_Create(int _width, int _height);
|
||||
void OpenGL_Shutdown();
|
||||
void OpenGL_Update();
|
||||
bool OpenGL_MakeCurrent();
|
||||
|
|
|
@ -29,6 +29,7 @@
|
|||
#include "DebugUtil.h"
|
||||
#include "CommandProcessor.h"
|
||||
#include "SWVideoConfig.h"
|
||||
#include "HW/Memmap.h"
|
||||
|
||||
typedef void (*DecodingFunction)(u32);
|
||||
DecodingFunction currentFunction = NULL;
|
||||
|
@ -96,7 +97,7 @@ void ExecuteDisplayList(u32 addr, u32 count)
|
|||
{
|
||||
u8 *videoDataSave = g_pVideoData;
|
||||
|
||||
u8 *dlStart = g_VideoInitialize.pGetMemoryPointer(addr);
|
||||
u8 *dlStart = Memory::GetPointer(addr);
|
||||
|
||||
g_pVideoData = dlStart;
|
||||
|
||||
|
|
|
@ -19,7 +19,7 @@
|
|||
#ifndef _OPCODEDECODER_H_
|
||||
#define _OPCODEDECODER_H_
|
||||
|
||||
#include "pluginspecs_video.h"
|
||||
#include "CommonTypes.h"
|
||||
|
||||
namespace OpcodeDecoder
|
||||
{
|
||||
|
|
|
@ -22,6 +22,9 @@
|
|||
|
||||
#include "Common.h"
|
||||
#include "ChunkFile.h"
|
||||
#include "CoreTiming.h"
|
||||
#include "ConfigManager.h"
|
||||
#include "HW/ProcessorInterface.h"
|
||||
|
||||
#include "PixelEngine.h"
|
||||
#include "CommandProcessor.h"
|
||||
|
@ -64,8 +67,8 @@ void Init()
|
|||
et_SetTokenOnMainThread = false;
|
||||
g_bSignalFinishInterrupt = false;
|
||||
|
||||
et_SetTokenOnMainThread = g_VideoInitialize.pRegisterEvent("SetToken", SetToken_OnMainThread);
|
||||
et_SetFinishOnMainThread = g_VideoInitialize.pRegisterEvent("SetFinish", SetFinish_OnMainThread);
|
||||
et_SetTokenOnMainThread = CoreTiming::RegisterEvent("SetToken", SetToken_OnMainThread);
|
||||
et_SetFinishOnMainThread = CoreTiming::RegisterEvent("SetFinish", SetFinish_OnMainThread);
|
||||
}
|
||||
|
||||
void Read16(u16& _uReturnValue, const u32 _iAddress)
|
||||
|
@ -114,22 +117,22 @@ void Write16(const u16 _iValue, const u32 _iAddress)
|
|||
|
||||
bool AllowIdleSkipping()
|
||||
{
|
||||
return !g_VideoInitialize.bOnThread || (!pereg.ctrl.PETokenEnable && !pereg.ctrl.PEFinishEnable);
|
||||
return !SConfig::GetInstance().m_LocalCoreStartupParameter.bCPUThread || (!pereg.ctrl.PETokenEnable && !pereg.ctrl.PEFinishEnable);
|
||||
}
|
||||
|
||||
void UpdateInterrupts()
|
||||
{
|
||||
// check if there is a token-interrupt
|
||||
if (g_bSignalTokenInterrupt & pereg.ctrl.PETokenEnable)
|
||||
g_VideoInitialize.pSetInterrupt(INT_CAUSE_PE_TOKEN, true);
|
||||
ProcessorInterface::SetInterrupt(INT_CAUSE_PE_TOKEN, true);
|
||||
else
|
||||
g_VideoInitialize.pSetInterrupt(INT_CAUSE_PE_TOKEN, false);
|
||||
ProcessorInterface::SetInterrupt(INT_CAUSE_PE_TOKEN, false);
|
||||
|
||||
// check if there is a finish-interrupt
|
||||
if (g_bSignalFinishInterrupt & pereg.ctrl.PEFinishEnable)
|
||||
g_VideoInitialize.pSetInterrupt(INT_CAUSE_PE_FINISH, true);
|
||||
ProcessorInterface::SetInterrupt(INT_CAUSE_PE_FINISH, true);
|
||||
else
|
||||
g_VideoInitialize.pSetInterrupt(INT_CAUSE_PE_FINISH, false);
|
||||
ProcessorInterface::SetInterrupt(INT_CAUSE_PE_FINISH, false);
|
||||
}
|
||||
|
||||
|
||||
|
@ -154,8 +157,8 @@ void SetToken(const u16 _token, const int _bSetTokenAcknowledge)
|
|||
pereg.token = _token;
|
||||
if (_bSetTokenAcknowledge) // set token INT
|
||||
{
|
||||
g_VideoInitialize.pScheduleEvent_Threadsafe(
|
||||
0, et_SetTokenOnMainThread, _token | (_bSetTokenAcknowledge << 16));
|
||||
CoreTiming::ScheduleEvent_Threadsafe(0, et_SetTokenOnMainThread,
|
||||
_token | (_bSetTokenAcknowledge << 16));
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -163,8 +166,7 @@ void SetToken(const u16 _token, const int _bSetTokenAcknowledge)
|
|||
// THIS IS EXECUTED FROM VIDEO THREAD
|
||||
void SetFinish()
|
||||
{
|
||||
g_VideoInitialize.pScheduleEvent_Threadsafe(
|
||||
0, et_SetFinishOnMainThread, 0);
|
||||
CoreTiming::ScheduleEvent_Threadsafe(0, et_SetFinishOnMainThread, 0);
|
||||
INFO_LOG(PIXELENGINE, "VIDEO Set Finish");
|
||||
}
|
||||
|
||||
|
|
|
@ -18,8 +18,8 @@
|
|||
#define _PIXELENGINE_H
|
||||
|
||||
#include "Common.h"
|
||||
#include "pluginspecs_video.h"
|
||||
#include "VideoCommon.h"
|
||||
|
||||
class PointerWrap;
|
||||
|
||||
namespace PixelEngine
|
||||
|
|
|
@ -16,6 +16,7 @@
|
|||
// http://code.google.com/p/dolphin-emu/
|
||||
|
||||
#include "Common.h"
|
||||
#include "Core.h"
|
||||
|
||||
#include "GLUtil.h"
|
||||
#include "Renderer.h"
|
||||
|
@ -29,17 +30,13 @@ static GLuint s_RenderTarget = 0;
|
|||
|
||||
RasterFont* s_pfont = NULL;
|
||||
|
||||
void Renderer::Init(SVideoInitialize *_pVideoInitialize)
|
||||
void Renderer::Init()
|
||||
{
|
||||
if (!OpenGL_Create(g_VideoInitialize, 640, 480)) // 640x480 will be the default if all else fails
|
||||
if (!OpenGL_Create(640, 480)) // 640x480 will be the default if all else fails
|
||||
{
|
||||
g_VideoInitialize.pLog("Renderer::Create failed\n", TRUE);
|
||||
Core::Callback_VideoLog("Renderer::Create failed\n", TRUE);
|
||||
return;
|
||||
}
|
||||
|
||||
_pVideoInitialize->pPeekMessages = g_VideoInitialize.pPeekMessages;
|
||||
_pVideoInitialize->pUpdateFPSDisplay = g_VideoInitialize.pUpdateFPSDisplay;
|
||||
_pVideoInitialize->pWindowHandle = g_VideoInitialize.pWindowHandle;
|
||||
}
|
||||
|
||||
void Renderer::Shutdown()
|
||||
|
|
|
@ -18,11 +18,11 @@
|
|||
#ifndef _RENDERER_H_
|
||||
#define _RENDERER_H_
|
||||
|
||||
#include "pluginspecs_video.h"
|
||||
#include "CommonTypes.h"
|
||||
|
||||
namespace Renderer
|
||||
{
|
||||
void Init(SVideoInitialize *_pVideoInitialize);
|
||||
void Init();
|
||||
void Prepare();
|
||||
void Shutdown();
|
||||
|
||||
|
|
|
@ -20,6 +20,7 @@
|
|||
|
||||
#include "BPMemLoader.h"
|
||||
#include "../../../Core/VideoCommon/Src/TextureDecoder.h"
|
||||
#include "HW/Memmap.h"
|
||||
|
||||
#include <cmath>
|
||||
|
||||
|
@ -121,7 +122,7 @@ void SampleMip(s32 s, s32 t, s32 mip, bool linear, u8 texmap, u8 *sample)
|
|||
TexTLUT& texTlut = texUnit.texTlut[subTexmap];
|
||||
|
||||
u32 imageBase = texUnit.texImage3[subTexmap].image_base << 5;
|
||||
u8 *imageSrc = g_VideoInitialize.pGetMemoryPointer(imageBase);
|
||||
u8 *imageSrc = Memory::GetPointer(imageBase);
|
||||
|
||||
int imageWidth = ti0.width;
|
||||
int imageHeight = ti0.height;
|
||||
|
|
46
Source/Plugins/Plugin_VideoSoftware/Src/VideoBackend.h
Normal file
46
Source/Plugins/Plugin_VideoSoftware/Src/VideoBackend.h
Normal file
|
@ -0,0 +1,46 @@
|
|||
|
||||
#ifndef SW_VIDEO_BACKEND_H_
|
||||
#define SW_VIDEO_BACKEND_H_
|
||||
|
||||
#include "VideoBackendBase.h"
|
||||
|
||||
namespace SW
|
||||
{
|
||||
|
||||
class VideoBackend : public VideoBackendLLE
|
||||
{
|
||||
void Initialize();
|
||||
void Shutdown();
|
||||
|
||||
std::string GetName();
|
||||
|
||||
void EmuStateChange(PLUGIN_EMUSTATE newState);
|
||||
|
||||
void DoState(PointerWrap &p);
|
||||
|
||||
void ShowConfig(void* parent);
|
||||
|
||||
void Video_Prepare();
|
||||
|
||||
void Video_EnterLoop();
|
||||
void Video_ExitLoop();
|
||||
void Video_BeginField(u32, FieldType, u32, u32);
|
||||
void Video_EndField();
|
||||
u32 Video_AccessEFB(EFBAccessType, u32, u32, u32);
|
||||
|
||||
void Video_AddMessage(const char* pstr, unsigned int milliseconds);
|
||||
bool Video_Screenshot(const char* filename);
|
||||
|
||||
void Video_SetRendering(bool bEnabled);
|
||||
|
||||
void Video_WaitForFrameFinish();
|
||||
bool Video_IsFifoBusy();
|
||||
void Video_AbortFrame();
|
||||
|
||||
void UpdateFPSDisplay(const char*);
|
||||
unsigned int PeekMessages();
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
#endif
|
|
@ -23,54 +23,13 @@
|
|||
#include <wx/dialog.h>
|
||||
#include <wx/aboutdlg.h>
|
||||
|
||||
#include "ConfigManager.h"
|
||||
#include "SWVideoConfig.h"
|
||||
#include "main.h"
|
||||
#include "Win32.h"
|
||||
|
||||
#include "StringUtil.h"
|
||||
|
||||
|
||||
HINSTANCE g_hInstance;
|
||||
|
||||
#if defined(HAVE_WX) && HAVE_WX
|
||||
class wxDLLApp : public wxApp
|
||||
{
|
||||
bool OnInit()
|
||||
{
|
||||
return true;
|
||||
}
|
||||
};
|
||||
IMPLEMENT_APP_NO_MAIN(wxDLLApp)
|
||||
WXDLLIMPEXP_BASE void wxSetInstance(HINSTANCE hInst);
|
||||
#endif
|
||||
// ------------------
|
||||
|
||||
BOOL APIENTRY DllMain(HINSTANCE hinstDLL, // DLL module handle
|
||||
DWORD dwReason, // reason called
|
||||
LPVOID lpvReserved) // reserved
|
||||
{
|
||||
switch (dwReason)
|
||||
{
|
||||
case DLL_PROCESS_ATTACH:
|
||||
{
|
||||
#if defined(HAVE_WX) && HAVE_WX
|
||||
wxSetInstance((HINSTANCE)hinstDLL);
|
||||
wxInitialize();
|
||||
#endif
|
||||
}
|
||||
break;
|
||||
|
||||
case DLL_PROCESS_DETACH:
|
||||
#if defined(HAVE_WX) && HAVE_WX
|
||||
wxUninitialize();
|
||||
#endif
|
||||
break;
|
||||
}
|
||||
|
||||
g_hInstance = hinstDLL;
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
// ----------------------
|
||||
// The rendering window
|
||||
// ----------------------
|
||||
|
@ -80,11 +39,15 @@ namespace EmuWindow
|
|||
HWND m_hWnd = NULL; // The new window that is created here
|
||||
HWND m_hParent = NULL;
|
||||
|
||||
HINSTANCE m_hInstance = NULL;
|
||||
WNDCLASSEX wndClass;
|
||||
const TCHAR m_szClassName[] = _T("DolphinEmuWnd");
|
||||
int g_winstyle;
|
||||
|
||||
static void*& VideoWindowHandle()
|
||||
{
|
||||
return SConfig::GetInstance().m_LocalCoreStartupParameter.hMainWindow;
|
||||
}
|
||||
|
||||
// ------------------------------------------
|
||||
/* Invisible cursor option. In the lack of a predefined IDC_BLANK we make
|
||||
an empty transparent cursor */
|
||||
|
@ -202,7 +165,7 @@ LRESULT CALLBACK WndProc( HWND hWnd, UINT iMsg, WPARAM wParam, LPARAM lParam )
|
|||
break;
|
||||
|
||||
case WM_DESTROY:
|
||||
Shutdown();
|
||||
g_video_backend->Shutdown();
|
||||
break;
|
||||
|
||||
// Called when a screensaver wants to show up while this window is active
|
||||
|
@ -241,10 +204,10 @@ HWND OpenWindow(HWND parent, HINSTANCE hInstance, int width, int height, const T
|
|||
wndClass.lpszClassName = m_szClassName;
|
||||
wndClass.hIconSm = LoadIcon( NULL, IDI_APPLICATION );
|
||||
|
||||
m_hInstance = hInstance;
|
||||
//m_hInstance = hInstance;
|
||||
RegisterClassEx( &wndClass );
|
||||
|
||||
CreateCursors(m_hInstance);
|
||||
CreateCursors(/*m_hInstance*/GetModuleHandle(0));
|
||||
|
||||
// Create child window
|
||||
if (parent)
|
||||
|
@ -275,7 +238,7 @@ HWND OpenWindow(HWND parent, HINSTANCE hInstance, int width, int height, const T
|
|||
rc.top = (1024 - h)/2;
|
||||
rc.bottom = rc.top + h;
|
||||
|
||||
m_hParent = (HWND)g_VideoInitialize.pWindowHandle;
|
||||
m_hParent = (HWND)VideoWindowHandle();
|
||||
|
||||
m_hWnd = CreateWindow(m_szClassName, title,
|
||||
style,
|
||||
|
@ -364,7 +327,7 @@ void Close()
|
|||
{
|
||||
if (!m_hParent)
|
||||
DestroyWindow(m_hWnd);
|
||||
UnregisterClass(m_szClassName, m_hInstance);
|
||||
UnregisterClass(m_szClassName, /*m_hInstance*/GetModuleHandle(0));
|
||||
}
|
||||
|
||||
// ------------------------------------------
|
||||
|
|
|
@ -20,7 +20,7 @@
|
|||
#include "XFMemLoader.h"
|
||||
#include "CPMemLoader.h"
|
||||
#include "Clipper.h"
|
||||
|
||||
#include "HW/Memmap.h"
|
||||
|
||||
XFRegisters xfregs;
|
||||
|
||||
|
@ -90,7 +90,7 @@ void LoadIndexedXF(u32 val, int array)
|
|||
int size = ((val >> 12) & 0xF) + 1;
|
||||
//load stuff from array to address in xf mem
|
||||
|
||||
u32 *pData = (u32*)g_VideoInitialize.pGetMemoryPointer(arraybases[array] + arraystrides[array]*index);
|
||||
u32 *pData = (u32*)Memory::GetPointer(arraybases[array] + arraystrides[array]*index);
|
||||
|
||||
// byteswap data
|
||||
u32 buffer[16];
|
||||
|
|
|
@ -17,7 +17,6 @@
|
|||
|
||||
|
||||
#include "Common.h"
|
||||
#include "pluginspecs_video.h"
|
||||
|
||||
#if defined(HAVE_WX) && HAVE_WX
|
||||
#include "VideoConfigDialog.h"
|
||||
|
@ -39,31 +38,14 @@
|
|||
#include "EfbInterface.h"
|
||||
#include "DebugUtil.h"
|
||||
#include "FileUtil.h"
|
||||
#include "VideoBackend.h"
|
||||
|
||||
|
||||
PLUGIN_GLOBALS* globals = NULL;
|
||||
SVideoInitialize g_VideoInitialize;
|
||||
|
||||
|
||||
void GetDllInfo (PLUGIN_INFO* _PluginInfo)
|
||||
namespace SW
|
||||
{
|
||||
_PluginInfo->Version = 0x0100;
|
||||
_PluginInfo->Type = PLUGIN_TYPE_VIDEO;
|
||||
#ifdef DEBUGFAST
|
||||
sprintf(_PluginInfo->Name, "Dolphin Software Renderer (DebugFast)");
|
||||
#else
|
||||
#ifndef _DEBUG
|
||||
sprintf(_PluginInfo->Name, "Dolphin Software Renderer");
|
||||
#else
|
||||
sprintf(_PluginInfo->Name, "Dolphin Software Renderer (Debug)");
|
||||
#endif
|
||||
#endif
|
||||
}
|
||||
|
||||
void SetDllGlobals(PLUGIN_GLOBALS* _pPluginGlobals)
|
||||
std::string VideoBackend::GetName()
|
||||
{
|
||||
globals = _pPluginGlobals;
|
||||
LogManager::SetInstance((LogManager *)globals->logManager);
|
||||
return "Software Renderer";
|
||||
}
|
||||
|
||||
void *DllDebugger(void *_hParent, bool Show)
|
||||
|
@ -71,7 +53,7 @@ void *DllDebugger(void *_hParent, bool Show)
|
|||
return NULL;
|
||||
}
|
||||
|
||||
void DllConfig(void *_hParent)
|
||||
void VideoBackend::ShowConfig(void *_hParent)
|
||||
{
|
||||
#if defined(HAVE_WX) && HAVE_WX
|
||||
VideoConfigDialog* const diag = new VideoConfigDialog((wxWindow*)_hParent, "Software", "gfx_software");
|
||||
|
@ -80,11 +62,8 @@ void DllConfig(void *_hParent)
|
|||
#endif
|
||||
}
|
||||
|
||||
void Initialize(void *init)
|
||||
void VideoBackend::Initialize()
|
||||
{
|
||||
SVideoInitialize *_pVideoInitialize = (SVideoInitialize*)init;
|
||||
g_VideoInitialize = *_pVideoInitialize;
|
||||
|
||||
g_SWVideoConfig.Load((std::string(File::GetUserPath(D_CONFIG_IDX)) + "gfx_software.ini").c_str());
|
||||
|
||||
InitBPMemory();
|
||||
|
@ -95,31 +74,33 @@ void Initialize(void *init)
|
|||
Clipper::Init();
|
||||
Rasterizer::Init();
|
||||
HwRasterizer::Init();
|
||||
Renderer::Init(_pVideoInitialize);
|
||||
Renderer::Init();
|
||||
DebugUtil::Init();
|
||||
}
|
||||
|
||||
void DoState(unsigned char **ptr, int mode)
|
||||
void VideoBackend::DoState(PointerWrap&)
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
void EmuStateChange(PLUGIN_EMUSTATE newState)
|
||||
void VideoBackend::EmuStateChange(PLUGIN_EMUSTATE newState)
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
bool IsD3D()
|
||||
{
|
||||
return false;
|
||||
}
|
||||
//bool IsD3D()
|
||||
//{
|
||||
// return false;
|
||||
//}
|
||||
|
||||
void Shutdown(void)
|
||||
void VideoBackend::Shutdown()
|
||||
{
|
||||
Renderer::Shutdown();
|
||||
OpenGL_Shutdown();
|
||||
}
|
||||
|
||||
// This is called after Video_Initialize() from the Core
|
||||
void Video_Prepare(void)
|
||||
void VideoBackend::Video_Prepare()
|
||||
{
|
||||
Renderer::Prepare();
|
||||
|
||||
|
@ -127,16 +108,16 @@ void Video_Prepare(void)
|
|||
}
|
||||
|
||||
// Run from the CPU thread (from VideoInterface.cpp)
|
||||
void Video_BeginField(u32 xfbAddr, FieldType field, u32 fbWidth, u32 fbHeight)
|
||||
void VideoBackend::Video_BeginField(u32 xfbAddr, FieldType field, u32 fbWidth, u32 fbHeight)
|
||||
{
|
||||
}
|
||||
|
||||
// Run from the CPU thread (from VideoInterface.cpp)
|
||||
void Video_EndField()
|
||||
void VideoBackend::Video_EndField()
|
||||
{
|
||||
}
|
||||
|
||||
u32 Video_AccessEFB(EFBAccessType type, u32 x, u32 y, u32 InputData)
|
||||
u32 VideoBackend::Video_AccessEFB(EFBAccessType type, u32 x, u32 y, u32 InputData)
|
||||
{
|
||||
u32 value = 0;
|
||||
|
||||
|
@ -166,71 +147,46 @@ u32 Video_AccessEFB(EFBAccessType type, u32 x, u32 y, u32 InputData)
|
|||
return value;
|
||||
}
|
||||
|
||||
void Video_Screenshot(const char *_szFilename)
|
||||
bool VideoBackend::Video_Screenshot(const char *_szFilename)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
// -------------------------------
|
||||
// Enter and exit the video loop
|
||||
// -------------------------------
|
||||
void Video_EnterLoop()
|
||||
void VideoBackend::Video_EnterLoop()
|
||||
{
|
||||
Fifo_EnterLoop(g_VideoInitialize);
|
||||
Fifo_EnterLoop();
|
||||
}
|
||||
|
||||
void Video_ExitLoop()
|
||||
void VideoBackend::Video_ExitLoop()
|
||||
{
|
||||
Fifo_ExitLoop();
|
||||
}
|
||||
|
||||
void Video_AddMessage(const char* pstr, u32 milliseconds)
|
||||
void VideoBackend::Video_AddMessage(const char* pstr, u32 milliseconds)
|
||||
{
|
||||
}
|
||||
|
||||
void Video_SetRendering(bool bEnabled)
|
||||
void VideoBackend::Video_SetRendering(bool bEnabled)
|
||||
{
|
||||
Fifo_SetRendering(bEnabled);
|
||||
}
|
||||
|
||||
void Video_CommandProcessorRead16(u16& _rReturnValue, const u32 _Address)
|
||||
void VideoBackend::Video_WaitForFrameFinish(void)
|
||||
{
|
||||
CommandProcessor::Read16(_rReturnValue, _Address);
|
||||
|
||||
}
|
||||
|
||||
void Video_CommandProcessorWrite16(const u16 _Data, const u32 _Address)
|
||||
{
|
||||
CommandProcessor::Write16(_Data, _Address);
|
||||
}
|
||||
|
||||
void Video_PixelEngineRead16(u16& _rReturnValue, const u32 _Address)
|
||||
{
|
||||
PixelEngine::Read16(_rReturnValue, _Address);
|
||||
}
|
||||
|
||||
void Video_PixelEngineWrite16(const u16 _Data, const u32 _Address)
|
||||
{
|
||||
PixelEngine::Write16(_Data, _Address);
|
||||
}
|
||||
|
||||
void Video_PixelEngineWrite32(const u32 _Data, const u32 _Address)
|
||||
{
|
||||
PixelEngine::Write32(_Data, _Address);
|
||||
}
|
||||
|
||||
void Video_GatherPipeBursted(void)
|
||||
{
|
||||
CommandProcessor::GatherPipeBursted();
|
||||
}
|
||||
|
||||
void Video_WaitForFrameFinish(void)
|
||||
{
|
||||
}
|
||||
|
||||
bool Video_IsFifoBusy(void)
|
||||
bool VideoBackend::Video_IsFifoBusy(void)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
void Video_AbortFrame(void)
|
||||
void VideoBackend::Video_AbortFrame(void)
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
}
|
|
@ -18,8 +18,6 @@
|
|||
#ifndef MAIN_H
|
||||
#define MAIN_H
|
||||
|
||||
#include "pluginspecs_video.h"
|
||||
|
||||
extern SVideoInitialize g_VideoInitialize;
|
||||
#include "VideoBackend.h"
|
||||
|
||||
#endif
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue