Use brute force to link the software plugin.

Not yet functional.


git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7050 8ced0084-cf51-0410-be5f-012b33b47a6e
This commit is contained in:
Soren Jorvang 2011-02-03 19:55:30 +00:00
parent 439baff4cc
commit 1619e176ff
50 changed files with 308 additions and 607 deletions

View File

@ -124,12 +124,15 @@ if sys.platform == 'darwin':
env['CCFLAGS'] += ['-Xarch_i386', '-msse3', '-Xarch_x86_64', '-mssse3']
env['CC'] = '/Developer/usr/bin/llvm-gcc'
env['CXX'] = '/Developer/usr/bin/llvm-g++'
#env['CC'] = 'clang'
#env['CXX'] = 'clang++'
env['CXXFLAGS'] += ['-x', 'objective-c++']
env['FRAMEWORKS'] += ['AppKit', 'Carbon', 'CoreFoundation', 'CoreServices']
env['FRAMEWORKS'] += ['AudioToolbox', 'AudioUnit', 'CoreAudio', 'WebKit']
env['FRAMEWORKS'] += ['IOBluetooth', 'IOKit', 'OpenGL']
env['LIBPATH'] += ['/usr/lib'] # XXX clang
env['LINKFLAGS'] += ccld
env['LINKFLAGS'] += ['-Wl,-dead_strip']
env['LINKFLAGS'] += ['-Wl,-dead_strip', '-Wl,-dead_strip_dylibs']
env['LINKFLAGS'] += ['-Wl,-pagezero_size,0x1000']
env['LINKFLAGS'] += ['-Wl,-search_paths_first']
@ -149,7 +152,6 @@ if sys.platform == 'darwin':
wxconfig.ParseWXConfig(wxenv)
env['CPPDEFINES'] += ['__WXOSX_COCOA__']
env['CPPPATH'] += wxenv['CPPPATH']
#env['LIBPATH'] += wxenv['LIBPATH']
env['wxconfiglibs'] = wxenv['LIBS']
env['CPPPATH'] += ['#Externals']

View File

@ -23,7 +23,9 @@
#include "../../../Plugins/Plugin_VideoDX11/Src/VideoBackend.h"
#endif
#include "../../../Plugins/Plugin_VideoOGL/Src/VideoBackend.h"
//#include "../Plugins/Plugin_VideoSoftware/Src/VideoBackend.h"
#ifndef _WIN32 // XXX
#include "../../../Plugins/Plugin_VideoSoftware/Src/VideoBackend.h"
#endif
std::vector<VideoBackend*> g_available_video_backends;
VideoBackend* g_video_backend = NULL;
@ -36,7 +38,9 @@ void VideoBackend::PopulateList()
g_available_video_backends.push_back(new DX11::VideoBackend);
#endif
g_available_video_backends.push_back(new OGL::VideoBackend);
//g_available_video_backends.push_back(new SW::VideoBackend);
#ifndef _WIN32 // XXX
g_available_video_backends.push_back(new SW::VideoBackend);
#endif
g_video_backend = g_available_video_backends.front();
}

View File

@ -182,7 +182,7 @@ set(SRCS Src/ActionReplay.cpp
Src/PowerPC/JitCommon/JitCache.cpp
Src/PowerPC/JitCommon/Jit_Util.cpp)
set(LIBS bdisasm inputcommon videoogl lua sfml-network)
set(LIBS bdisasm inputcommon videoogl videosoftware lua sfml-network)
if(WIN32)
set(SRCS ${SRCS} Src/HW/BBA-TAP/TAP_Win32.cpp Src/stdafx.cpp

View File

@ -31,6 +31,7 @@ else:
'ISOFile.cpp',
'ISOProperties.cpp',
'PatchAddEdit.cpp',
'PHackSettings.cpp',
'CheatsWindow.cpp',
'MemcardManager.cpp',
'MemoryCards/GCMemcard.cpp',
@ -49,7 +50,7 @@ else:
libs += ['debwx', 'debugger_ui_util', 'dolphinwx']
libs += ['core', 'common', 'discio', 'plugin_videoogl'] # 'plugin_videosoftware'
libs += ['core', 'common', 'discio', 'plugin_videoogl', 'plugin_videosoftware']
if env['HAVE_WX']:
libs += ['videouicommon']
libs += ['audiocommon', 'inputcommon', 'videocommon']
@ -58,8 +59,8 @@ libs += ['GLEW', 'SOIL', 'bdisasm', 'lua', 'lzo2', 'sfml-network', 'z']
if sys.platform == 'win32':
files += [ "stdafx.cpp" ]
elif sys.platform == 'darwin':
ldflags += [ '-Xarch_i386', '-Wl,-framework,QuickTime' ]
ldflags += [ '-weak_framework', 'OpenCL' ]
ldflags += ['-Wl,-framework,QuickTime', '-Wl,-no_arch_warnings']
ldflags += ['-weak_framework', 'OpenCL']
exe = '#' + env['prefix'] + '/Dolphin.app/Contents/MacOS/Dolphin'

View File

@ -510,7 +510,7 @@
</File>
</Filter>
<File
RelativePath=".\Src\main.cpp"
RelativePath=".\Src\DSPTool.cpp"
>
</File>
<File

View File

@ -4,7 +4,7 @@ Import('env')
import sys
files = [
'main.cpp',
'DSPTool.cpp',
]
libs = [

View File

@ -1,25 +1,24 @@
set(SRCS Src/BPMemLoader.cpp
Src/Clipper.cpp
Src/CommandProcessor.cpp
Src/SWCommandProcessor.cpp
Src/CPMemLoader.cpp
Src/DebugUtil.cpp
Src/EfbCopy.cpp
Src/EfbInterface.cpp
Src/GLUtil.cpp
Src/SWGLUtil.cpp
Src/HwRasterizer.cpp
Src/main.cpp
Src/SWmain.cpp
Src/OpcodeDecoder.cpp
Src/PixelEngine.cpp
Src/SWPixelEngine.cpp
Src/Rasterizer.cpp
Src/RasterFont.cpp
Src/Renderer.cpp
Src/SWRenderer.cpp
Src/SetupUnit.cpp
Src/Statistics.cpp
Src/SWStatistics.cpp
Src/Tev.cpp
Src/TextureEncoder.cpp
Src/TextureSampler.cpp
Src/TransformUnit.cpp
Src/VertexLoader.cpp
Src/SWVertexLoader.cpp
Src/SWVideoConfig.cpp
Src/XFMemLoader.cpp)

View File

@ -307,14 +307,6 @@
RelativePath="..\..\Core\VideoCommon\Src\OpenCL\OCLTextureDecoder.cpp"
>
</File>
<File
RelativePath=".\Src\RasterFont.cpp"
>
</File>
<File
RelativePath=".\Src\RasterFont.h"
>
</File>
<File
RelativePath="..\..\Core\VideoCommon\Src\TextureDecoder.cpp"
>
@ -369,11 +361,11 @@
>
</File>
<File
RelativePath=".\Src\CommandProcessor.cpp"
RelativePath=".\Src\SWCommandProcessor.cpp"
>
</File>
<File
RelativePath=".\Src\CommandProcessor.h"
RelativePath=".\Src\SWCommandProcessor.h"
>
</File>
<File
@ -409,11 +401,11 @@
>
</File>
<File
RelativePath=".\Src\GLUtil.cpp"
RelativePath=".\Src\SWGLUtil.cpp"
>
</File>
<File
RelativePath=".\Src\GLUtil.h"
RelativePath=".\Src\SWGLUtil.h"
>
</File>
<File
@ -445,11 +437,11 @@
>
</File>
<File
RelativePath=".\Src\PixelEngine.cpp"
RelativePath=".\Src\SWPixelEngine.cpp"
>
</File>
<File
RelativePath=".\Src\PixelEngine.h"
RelativePath=".\Src\SWPixelEngine.h"
>
</File>
<File
@ -461,11 +453,11 @@
>
</File>
<File
RelativePath=".\Src\Renderer.cpp"
RelativePath=".\Src\SWRenderer.cpp"
>
</File>
<File
RelativePath=".\Src\Renderer.h"
RelativePath=".\Src\SWRenderer.h"
>
</File>
<File
@ -477,11 +469,11 @@
>
</File>
<File
RelativePath=".\Src\Statistics.cpp"
RelativePath=".\Src\SWStatistics.cpp"
>
</File>
<File
RelativePath=".\Src\Statistics.h"
RelativePath=".\Src\SWStatistics.h"
>
</File>
<File
@ -569,11 +561,11 @@
>
</File>
<File
RelativePath=".\Src\VertexLoader.cpp"
RelativePath=".\Src\SWVertexLoader.cpp"
>
</File>
<File
RelativePath=".\Src\VertexLoader.h"
RelativePath=".\Src\SWVertexLoader.h"
>
</File>
<File

View File

@ -169,21 +169,21 @@
<ItemGroup>
<ClCompile Include="Src\BPMemLoader.cpp" />
<ClCompile Include="Src\Clipper.cpp" />
<ClCompile Include="Src\CommandProcessor.cpp" />
<ClCompile Include="Src\SWCommandProcessor.cpp" />
<ClCompile Include="Src\CPMemLoader.cpp" />
<ClCompile Include="Src\DebugUtil.cpp" />
<ClCompile Include="Src\EfbCopy.cpp" />
<ClCompile Include="Src\EfbInterface.cpp" />
<ClCompile Include="Src\GLUtil.cpp" />
<ClCompile Include="Src\SWGLUtil.cpp" />
<ClCompile Include="Src\HwRasterizer.cpp" />
<ClCompile Include="Src\main.cpp" />
<ClCompile Include="Src\SWmain.cpp" />
<ClCompile Include="Src\OpcodeDecoder.cpp" />
<ClCompile Include="Src\PixelEngine.cpp" />
<ClCompile Include="Src\SWPixelEngine.cpp" />
<ClCompile Include="Src\RasterFont.cpp" />
<ClCompile Include="Src\Rasterizer.cpp" />
<ClCompile Include="Src\Renderer.cpp" />
<ClCompile Include="Src\SWRenderer.cpp" />
<ClCompile Include="Src\SetupUnit.cpp" />
<ClCompile Include="Src\Statistics.cpp" />
<ClCompile Include="Src\SWStatistics.cpp" />
<ClCompile Include="Src\stdafx.cpp">
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">Create</PrecompiledHeader>
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">Create</PrecompiledHeader>
@ -195,7 +195,7 @@
<ClCompile Include="Src\TextureEncoder.cpp" />
<ClCompile Include="Src\TextureSampler.cpp" />
<ClCompile Include="Src\TransformUnit.cpp" />
<ClCompile Include="Src\VertexLoader.cpp" />
<ClCompile Include="Src\SWVertexLoader.cpp" />
<ClCompile Include="Src\VideoConfigDialog.cpp" />
<ClCompile Include="Src\Win32.cpp" />
<ClCompile Include="Src\XFMemLoader.cpp" />
@ -203,22 +203,21 @@
<ItemGroup>
<ClInclude Include="Src\BPMemLoader.h" />
<ClInclude Include="Src\Clipper.h" />
<ClInclude Include="Src\CommandProcessor.h" />
<ClInclude Include="Src\SWCommandProcessor.h" />
<ClInclude Include="Src\CPMemLoader.h" />
<ClInclude Include="Src\DebugUtil.h" />
<ClInclude Include="Src\EfbCopy.h" />
<ClInclude Include="Src\EfbInterface.h" />
<ClInclude Include="Src\GLUtil.h" />
<ClInclude Include="Src\SWGLUtil.h" />
<ClInclude Include="Src\HwRasterizer.h" />
<ClInclude Include="Src\main.h" />
<ClInclude Include="Src\NativeVertexFormat.h" />
<ClInclude Include="Src\OpcodeDecoder.h" />
<ClInclude Include="Src\PixelEngine.h" />
<ClInclude Include="Src\SWPixelEngine.h" />
<ClInclude Include="Src\RasterFont.h" />
<ClInclude Include="Src\Rasterizer.h" />
<ClInclude Include="Src\Renderer.h" />
<ClInclude Include="Src\SWRenderer.h" />
<ClInclude Include="Src\SetupUnit.h" />
<ClInclude Include="Src\Statistics.h" />
<ClInclude Include="Src\SWStatistics.h" />
<ClInclude Include="Src\stdafx.h" />
<ClInclude Include="Src\SWVideoConfig.h" />
<ClInclude Include="Src\Tev.h" />
@ -226,7 +225,7 @@
<ClInclude Include="Src\TextureSampler.h" />
<ClInclude Include="Src\TransformUnit.h" />
<ClInclude Include="Src\Vec3.h" />
<ClInclude Include="Src\VertexLoader.h" />
<ClInclude Include="Src\SWVertexLoader.h" />
<ClInclude Include="Src\VertexLoader_Position.h" />
<ClInclude Include="Src\VideoBackend.h" />
<ClInclude Include="Src\VideoConfigDialog.h" />

View File

@ -3,54 +3,50 @@
<ItemGroup>
<ClCompile Include="Src\BPMemLoader.cpp" />
<ClCompile Include="Src\Clipper.cpp" />
<ClCompile Include="Src\CommandProcessor.cpp" />
<ClCompile Include="Src\SWCommandProcessor.cpp" />
<ClCompile Include="Src\CPMemLoader.cpp" />
<ClCompile Include="Src\DebugUtil.cpp" />
<ClCompile Include="Src\EfbCopy.cpp" />
<ClCompile Include="Src\EfbInterface.cpp" />
<ClCompile Include="Src\GLUtil.cpp" />
<ClCompile Include="Src\SWGLUtil.cpp" />
<ClCompile Include="Src\HwRasterizer.cpp" />
<ClCompile Include="Src\main.cpp" />
<ClCompile Include="Src\SWmain.cpp" />
<ClCompile Include="Src\OpcodeDecoder.cpp" />
<ClCompile Include="Src\PixelEngine.cpp" />
<ClCompile Include="Src\SWPixelEngine.cpp" />
<ClCompile Include="Src\Rasterizer.cpp" />
<ClCompile Include="Src\Renderer.cpp" />
<ClCompile Include="Src\SWRenderer.cpp" />
<ClCompile Include="Src\SetupUnit.cpp" />
<ClCompile Include="Src\Statistics.cpp" />
<ClCompile Include="Src\SWStatistics.cpp" />
<ClCompile Include="Src\stdafx.cpp" />
<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\VertexLoader.cpp" />
<ClCompile Include="Src\SWVertexLoader.cpp" />
<ClCompile Include="Src\VideoConfigDialog.cpp" />
<ClCompile Include="Src\XFMemLoader.cpp" />
<ClCompile Include="Src\Win32.cpp">
<Filter>Win32</Filter>
</ClCompile>
<ClCompile Include="Src\RasterFont.cpp">
<Filter>Common</Filter>
</ClCompile>
</ItemGroup>
<ItemGroup>
<ClInclude Include="Src\BPMemLoader.h" />
<ClInclude Include="Src\Clipper.h" />
<ClInclude Include="Src\CommandProcessor.h" />
<ClInclude Include="Src\SWCommandProcessor.h" />
<ClInclude Include="Src\CPMemLoader.h" />
<ClInclude Include="Src\DebugUtil.h" />
<ClInclude Include="Src\EfbCopy.h" />
<ClInclude Include="Src\EfbInterface.h" />
<ClInclude Include="Src\GLUtil.h" />
<ClInclude Include="Src\SWGLUtil.h" />
<ClInclude Include="Src\HwRasterizer.h" />
<ClInclude Include="Src\main.h" />
<ClInclude Include="Src\NativeVertexFormat.h" />
<ClInclude Include="Src\OpcodeDecoder.h" />
<ClInclude Include="Src\PixelEngine.h" />
<ClInclude Include="Src\SWPixelEngine.h" />
<ClInclude Include="Src\Rasterizer.h" />
<ClInclude Include="Src\Renderer.h" />
<ClInclude Include="Src\SWRenderer.h" />
<ClInclude Include="Src\SetupUnit.h" />
<ClInclude Include="Src\Statistics.h" />
<ClInclude Include="Src\SWStatistics.h" />
<ClInclude Include="Src\stdafx.h" />
<ClInclude Include="Src\SWVideoConfig.h" />
<ClInclude Include="Src\Tev.h" />
@ -58,16 +54,13 @@
<ClInclude Include="Src\TextureSampler.h" />
<ClInclude Include="Src\TransformUnit.h" />
<ClInclude Include="Src\Vec3.h" />
<ClInclude Include="Src\VertexLoader.h" />
<ClInclude Include="Src\SWVertexLoader.h" />
<ClInclude Include="Src\VideoBackend.h" />
<ClInclude Include="Src\VideoConfigDialog.h" />
<ClInclude Include="Src\XFMemLoader.h" />
<ClInclude Include="Src\Win32.h">
<Filter>Win32</Filter>
</ClInclude>
<ClInclude Include="Src\RasterFont.h">
<Filter>Common</Filter>
</ClInclude>
<ClInclude Include="Src\VertexLoader_Position.h">
<Filter>Common</Filter>
</ClInclude>
@ -84,4 +77,4 @@
<UniqueIdentifier>{80e30848-1174-4168-a8f7-da2553f872b1}</UniqueIdentifier>
</Filter>
</ItemGroup>
</Project>
</Project>

View File

@ -16,12 +16,11 @@
// http://code.google.com/p/dolphin-emu/
#include "../../../Core/VideoCommon/Src/VideoCommon.h"
#include "main.h"
#include "BPMemLoader.h"
#include "EfbCopy.h"
#include "Rasterizer.h"
#include "PixelEngine.h"
#include "SWPixelEngine.h"
#include "Tev.h"
#include "../../../Core/VideoCommon/Src/TextureDecoder.h"
#include "HW/Memmap.h"
@ -35,9 +34,7 @@ void InitBPMemory()
bpmem.bpMask = 0xFFFFFF;
}
void BPWritten(int address, int newvalue);
void LoadBPReg(u32 value)
void SWLoadBPReg(u32 value)
{
//handle the mask register
int address = value >> 24;
@ -50,10 +47,10 @@ void LoadBPReg(u32 value)
if (address != 0xFE)
bpmem.bpMask = 0xFFFFFF;
BPWritten(address, newval);
SWBPWritten(address, newval);
}
void BPWritten(int address, int newvalue)
void SWBPWritten(int address, int newvalue)
{
switch (address)
{
@ -66,7 +63,7 @@ void BPWritten(int address, int newvalue)
switch (bpmem.drawdone & 0xFF)
{
case 0x02:
PixelEngine::SetFinish(); // may generate interrupt
SWPixelEngine::SetFinish(); // may generate interrupt
DEBUG_LOG(VIDEO, "GXSetDrawDone SetPEFinish (value: 0x%02X)", (bpmem.drawdone & 0xFFFF));
break;
@ -77,22 +74,22 @@ void BPWritten(int address, int newvalue)
break;
case BPMEM_PE_TOKEN_ID: // Pixel Engine Token ID
DEBUG_LOG(VIDEO, "SetPEToken 0x%04x", (bpmem.petoken & 0xFFFF));
PixelEngine::SetToken(static_cast<u16>(bpmem.petokenint & 0xFFFF), false);
SWPixelEngine::SetToken(static_cast<u16>(bpmem.petokenint & 0xFFFF), false);
break;
case BPMEM_PE_TOKEN_INT_ID: // Pixel Engine Interrupt Token ID
DEBUG_LOG(VIDEO, "SetPEToken + INT 0x%04x", (bpmem.petokenint & 0xFFFF));
PixelEngine::SetToken(static_cast<u16>(bpmem.petokenint & 0xFFFF), true);
SWPixelEngine::SetToken(static_cast<u16>(bpmem.petokenint & 0xFFFF), true);
break;
case BPMEM_TRIGGER_EFB_COPY:
EfbCopy::CopyEfb();
break;
case BPMEM_CLEARBBOX1:
PixelEngine::pereg.boxRight = newvalue >> 10;
PixelEngine::pereg.boxLeft = newvalue & 0x3ff;
SWPixelEngine::pereg.boxRight = newvalue >> 10;
SWPixelEngine::pereg.boxLeft = newvalue & 0x3ff;
break;
case BPMEM_CLEARBBOX2:
PixelEngine::pereg.boxBottom = newvalue >> 10;
PixelEngine::pereg.boxTop = newvalue & 0x3ff;
SWPixelEngine::pereg.boxBottom = newvalue >> 10;
SWPixelEngine::pereg.boxTop = newvalue & 0x3ff;
break;
case BPMEM_LOADTLUT0: // This one updates bpmem.tlutXferSrc, no need to do anything here.
break;

View File

@ -24,5 +24,7 @@
#include "../../../Core/VideoCommon/Src/BPMemory.h"
void InitBPMemory();
void SWBPWritten(int address, int newvalue);
void SWLoadBPReg(u32 value);
#endif

View File

@ -30,8 +30,7 @@ TMatrixIndexB MatrixIndexB;
TVtxDesc g_VtxDesc;
VAT g_VtxAttr[8];
void LoadCPReg(u32 sub_cmd, u32 value)
void SWLoadCPReg(u32 sub_cmd, u32 value)
{
switch (sub_cmd & 0xF0)
{
@ -79,4 +78,3 @@ void LoadCPReg(u32 sub_cmd, u32 value)
break;
}
}

View File

@ -23,5 +23,6 @@
#include "../../../Core/VideoCommon/Src/CPMemory.h"
void SWLoadCPReg(u32 sub_cmd, u32 value);
#endif

View File

@ -53,7 +53,7 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include "NativeVertexFormat.h"
#include "XFMemLoader.h"
#include "BPMemLoader.h"
#include "Statistics.h"
#include "SWStatistics.h"
namespace Clipper
@ -73,8 +73,8 @@ namespace Clipper
void SetViewOffset()
{
m_ViewOffset[0] = xfregs.viewport.xOrig - 342;
m_ViewOffset[1] = xfregs.viewport.yOrig - 342;
m_ViewOffset[0] = swxfregs.viewport.xOrig - 342;
m_ViewOffset[1] = swxfregs.viewport.yOrig - 342;
}
@ -209,7 +209,7 @@ namespace Clipper
POLY_CLIP(CLIP_POS_Z_BIT, 0, 0, 0, 1);
POLY_CLIP(CLIP_NEG_Z_BIT, 0, 0, 1, 1);
INCSTAT(stats.thisFrame.numTrianglesClipped);
INCSTAT(swstats.thisFrame.numTrianglesClipped);
// transform the poly in inlist into triangles
indices[0] = inlist[0];
@ -273,7 +273,7 @@ namespace Clipper
void ProcessTriangle(OutputVertexData *v0, OutputVertexData *v1, OutputVertexData *v2)
{
INCSTAT(stats.thisFrame.numTrianglesIn)
INCSTAT(swstats.thisFrame.numTrianglesIn)
bool backface;
@ -395,7 +395,7 @@ namespace Clipper
if(mask)
{
INCSTAT(stats.thisFrame.numTrianglesRejected)
INCSTAT(swstats.thisFrame.numTrianglesRejected)
return false;
}
@ -415,13 +415,13 @@ namespace Clipper
if ((bpmem.genMode.cullmode & 1) && !backface) // cull frontfacing
{
INCSTAT(stats.thisFrame.numTrianglesCulled)
INCSTAT(swstats.thisFrame.numTrianglesCulled)
return false;
}
if ((bpmem.genMode.cullmode & 2) && backface) // cull backfacing
{
INCSTAT(stats.thisFrame.numTrianglesCulled)
INCSTAT(swstats.thisFrame.numTrianglesCulled)
return false;
}
@ -434,9 +434,9 @@ namespace Clipper
Vec3 &screen = vertex->screenPosition;
float wInverse = 1.0f/projected.w;
screen.x = projected.x * wInverse * xfregs.viewport.wd + m_ViewOffset[0];
screen.y = projected.y * wInverse * xfregs.viewport.ht + m_ViewOffset[1];
screen.z = projected.z * wInverse * xfregs.viewport.zRange + xfregs.viewport.farZ;
screen.x = projected.x * wInverse * swxfregs.viewport.wd + m_ViewOffset[0];
screen.y = projected.y * wInverse * swxfregs.viewport.ht + m_ViewOffset[1];
screen.z = projected.z * wInverse * swxfregs.viewport.zRange + swxfregs.viewport.farZ;
}
}

View File

@ -17,16 +17,15 @@
#include "Common.h"
#include "main.h"
#include "DebugUtil.h"
#include "BPMemLoader.h"
#include "TextureSampler.h"
#include "SWVideoConfig.h"
#include "EfbInterface.h"
#include "Statistics.h"
#include "SWStatistics.h"
#include "HwRasterizer.h"
#include "StringUtil.h"
#include "CommandProcessor.h"
#include "SWCommandProcessor.h"
#include "../../../Core/VideoCommon/Src/ImageWrite.h"
#include "FileUtil.h"
@ -114,7 +113,7 @@ void DumpActiveTextures()
s32 maxLod = GetMaxTextureLod(texmap);
for (s32 mip = 0; mip <= maxLod; ++mip)
{
SaveTexture(StringFromFormat("%star%i_ind%i_map%i_mip%i.tga", File::GetUserPath(D_DUMPTEXTURES_IDX), stats.thisFrame.numDrawnObjects, stageNum, texmap, mip).c_str(), texmap, mip);
SaveTexture(StringFromFormat("%star%i_ind%i_map%i_mip%i.tga", File::GetUserPath(D_DUMPTEXTURES_IDX), swstats.thisFrame.numDrawnObjects, stageNum, texmap, mip).c_str(), texmap, mip);
}
}
@ -129,7 +128,7 @@ void DumpActiveTextures()
s32 maxLod = GetMaxTextureLod(texmap);
for (s32 mip = 0; mip <= maxLod; ++mip)
{
SaveTexture(StringFromFormat("%star%i_stage%i_map%i_mip%i.tga", File::GetUserPath(D_DUMPTEXTURES_IDX), stats.thisFrame.numDrawnObjects, stageNum, texmap, mip).c_str(), texmap, mip);
SaveTexture(StringFromFormat("%star%i_stage%i_map%i_mip%i.tga", File::GetUserPath(D_DUMPTEXTURES_IDX), swstats.thisFrame.numDrawnObjects, stageNum, texmap, mip).c_str(), texmap, mip);
}
}
}
@ -216,7 +215,7 @@ void OnObjectBegin()
{
if (!g_bSkipCurrentFrame)
{
if (g_SWVideoConfig.bDumpTextures && stats.thisFrame.numDrawnObjects >= g_SWVideoConfig.drawStart && stats.thisFrame.numDrawnObjects < g_SWVideoConfig.drawEnd)
if (g_SWVideoConfig.bDumpTextures && swstats.thisFrame.numDrawnObjects >= g_SWVideoConfig.drawStart && swstats.thisFrame.numDrawnObjects < g_SWVideoConfig.drawEnd)
DumpActiveTextures();
if (g_SWVideoConfig.bHwRasterizer)
@ -231,8 +230,8 @@ void OnObjectEnd()
{
if (!g_bSkipCurrentFrame)
{
if (g_SWVideoConfig.bDumpObjects && stats.thisFrame.numDrawnObjects >= g_SWVideoConfig.drawStart && stats.thisFrame.numDrawnObjects < g_SWVideoConfig.drawEnd)
DumpEfb(StringFromFormat("%sobject%i.tga", File::GetUserPath(D_DUMPFRAMES_IDX), stats.thisFrame.numDrawnObjects).c_str());
if (g_SWVideoConfig.bDumpObjects && swstats.thisFrame.numDrawnObjects >= g_SWVideoConfig.drawStart && swstats.thisFrame.numDrawnObjects < g_SWVideoConfig.drawEnd)
DumpEfb(StringFromFormat("%sobject%i.tga", File::GetUserPath(D_DUMPFRAMES_IDX), swstats.thisFrame.numDrawnObjects).c_str());
if (g_SWVideoConfig.bHwRasterizer || drawingHwTriangles)
{
@ -246,12 +245,12 @@ void OnObjectEnd()
{
DrawnToBuffer[i] = false;
(void)SaveTGA(StringFromFormat("%sobject%i_%s(%i).tga", File::GetUserPath(D_DUMPFRAMES_IDX),
stats.thisFrame.numDrawnObjects, ObjectBufferName[i], i - BufferBase[i]).c_str(), EFB_WIDTH, EFB_HEIGHT, ObjectBuffer[i]);
swstats.thisFrame.numDrawnObjects, ObjectBufferName[i], i - BufferBase[i]).c_str(), EFB_WIDTH, EFB_HEIGHT, ObjectBuffer[i]);
memset(ObjectBuffer[i], 0, sizeof(ObjectBuffer[i]));
}
}
stats.thisFrame.numDrawnObjects++;
swstats.thisFrame.numDrawnObjects++;
}
}
@ -261,8 +260,8 @@ void OnFrameEnd()
{
if (g_SWVideoConfig.bDumpFrames)
{
DumpEfb(StringFromFormat("%sframe%i_color.tga", File::GetUserPath(D_DUMPFRAMES_IDX), stats.frameCount).c_str());
DumpDepth(StringFromFormat("%sframe%i_depth.tga", File::GetUserPath(D_DUMPFRAMES_IDX), stats.frameCount).c_str());
DumpEfb(StringFromFormat("%sframe%i_color.tga", File::GetUserPath(D_DUMPFRAMES_IDX), swstats.frameCount).c_str());
DumpDepth(StringFromFormat("%sframe%i_depth.tga", File::GetUserPath(D_DUMPFRAMES_IDX), swstats.frameCount).c_str());
}
}
}

View File

@ -15,18 +15,17 @@
// Official SVN repository and contact information can be found at
// http://code.google.com/p/dolphin-emu/
#include "main.h"
#include "BPMemLoader.h"
#include "EfbCopy.h"
#include "EfbInterface.h"
#include "Renderer.h"
#include "SWRenderer.h"
#include "TextureEncoder.h"
#include "Statistics.h"
#include "SWStatistics.h"
#include "SWVideoConfig.h"
#include "DebugUtil.h"
#include "HwRasterizer.h"
#include "CommandProcessor.h"
#include "GLUtil.h"
#include "SWCommandProcessor.h"
#include "SWGLUtil.h"
#include "HW/Memmap.h"
#include "Core.h"
@ -40,10 +39,10 @@ namespace EfbCopy
{
// copy to open gl for rendering
EfbInterface::UpdateColorTexture();
Renderer::DrawTexture(EfbInterface::efbColorTexture, EFB_WIDTH, EFB_HEIGHT);
SWRenderer::DrawTexture(EfbInterface::efbColorTexture, EFB_WIDTH, EFB_HEIGHT);
}
Renderer::SwapBuffer();
SWRenderer::SwapBuffer();
}
@ -88,7 +87,7 @@ namespace EfbCopy
CopyToXfb();
Core::Callback_VideoCopiedToXFB(false);
stats.frameCount++;
swstats.frameCount++;
}
else
{

View File

@ -20,7 +20,7 @@
#include "EfbInterface.h"
#include "BPMemLoader.h"
#include "../../../Core/VideoCommon/Src/LookUpTables.h"
#include "PixelEngine.h"
#include "SWPixelEngine.h"
u8 efb[EFB_WIDTH*EFB_HEIGHT*6];
@ -434,10 +434,10 @@ namespace EfbInterface
SetPixelAlphaOnly(offset, dstClrPtr[ALP_C]);
// branchless bounding box update
PixelEngine::pereg.boxLeft = PixelEngine::pereg.boxLeft>x?x:PixelEngine::pereg.boxLeft;
PixelEngine::pereg.boxRight = PixelEngine::pereg.boxRight<x?x:PixelEngine::pereg.boxRight;
PixelEngine::pereg.boxTop = PixelEngine::pereg.boxTop>y?y:PixelEngine::pereg.boxTop;
PixelEngine::pereg.boxBottom = PixelEngine::pereg.boxBottom<y?y:PixelEngine::pereg.boxBottom;
SWPixelEngine::pereg.boxLeft = SWPixelEngine::pereg.boxLeft>x?x:SWPixelEngine::pereg.boxLeft;
SWPixelEngine::pereg.boxRight = SWPixelEngine::pereg.boxRight<x?x:SWPixelEngine::pereg.boxRight;
SWPixelEngine::pereg.boxTop = SWPixelEngine::pereg.boxTop>y?y:SWPixelEngine::pereg.boxTop;
SWPixelEngine::pereg.boxBottom = SWPixelEngine::pereg.boxBottom<y?y:SWPixelEngine::pereg.boxBottom;
}
void SetColor(u16 x, u16 y, u8 *color)

View File

@ -22,7 +22,7 @@
#include "BPMemLoader.h"
#include "HwRasterizer.h"
#include "GLUtil.h"
#include "SWGLUtil.h"
#include "NativeVertexFormat.h"
#include "DebugUtil.h"

View File

@ -21,7 +21,7 @@
#include <map>
#include "BPMemLoader.h"
#include "GLUtil.h"
#include "SWGLUtil.h"
struct OutputVertexData;

View File

@ -19,15 +19,15 @@
#include "../../../Core/VideoCommon/Src/DataReader.h"
#include "main.h"
#include "OpcodeDecoder.h"
#include "BPMemLoader.h"
#include "CPMemLoader.h"
#include "XFMemLoader.h"
#include "VertexLoader.h"
#include "Statistics.h"
#include "SWVertexLoader.h"
#include "SWStatistics.h"
#include "DebugUtil.h"
#include "CommandProcessor.h"
#include "SWCommandProcessor.h"
#include "CPMemLoader.h"
#include "SWVideoConfig.h"
#include "HW/Memmap.h"
@ -38,7 +38,7 @@ u32 minCommandSize;
u16 streamSize;
u16 streamAddress;
bool readOpcode;
VertexLoader vertexLoader;
SWVertexLoader vertexLoader;
bool inObjectStream;
u8 lastPrimCmd;
@ -51,8 +51,8 @@ void DecodePrimitiveStream(u32 iBufferSize)
u32 vertexSize = vertexLoader.GetVertexSize();
bool skipPrimitives = g_bSkipCurrentFrame ||
stats.thisFrame.numDrawnObjects < g_SWVideoConfig.drawStart ||
stats.thisFrame.numDrawnObjects >= g_SWVideoConfig.drawEnd;
swstats.thisFrame.numDrawnObjects < g_SWVideoConfig.drawStart ||
swstats.thisFrame.numDrawnObjects >= g_SWVideoConfig.drawEnd;
if (skipPrimitives)
{
@ -87,7 +87,7 @@ void ReadXFData(u32 iBufferSize)
u32 pData[16];
for (int i = 0; i < streamSize; i++)
pData[i] = DataReadU32();
LoadXFReg(streamSize, streamAddress, pData);
SWLoadXFReg(streamSize, streamAddress, pData);
// return to normal command processing
ResetDecoding();
@ -149,7 +149,7 @@ void DecodeStandard(u32 bufferSize)
{
u32 SubCmd = DataReadU8();
u32 Value = DataReadU32();
LoadCPReg(SubCmd, Value);
SWLoadCPReg(SubCmd, Value);
}
break;
@ -165,16 +165,16 @@ void DecodeStandard(u32 bufferSize)
break;
case GX_LOAD_INDX_A: //used for position matrices
LoadIndexedXF(DataReadU32(), 0xC);
SWLoadIndexedXF(DataReadU32(), 0xC);
break;
case GX_LOAD_INDX_B: //used for normal matrices
LoadIndexedXF(DataReadU32(), 0xD);
SWLoadIndexedXF(DataReadU32(), 0xD);
break;
case GX_LOAD_INDX_C: //used for postmatrices
LoadIndexedXF(DataReadU32(), 0xE);
SWLoadIndexedXF(DataReadU32(), 0xE);
break;
case GX_LOAD_INDX_D: //used for lights
LoadIndexedXF(DataReadU32(), 0xF);
SWLoadIndexedXF(DataReadU32(), 0xF);
break;
case GX_CMD_CALL_DL:
@ -196,7 +196,7 @@ void DecodeStandard(u32 bufferSize)
case GX_LOAD_BP_REG: //0x61
{
u32 cmd = DataReadU32();
LoadBPReg(cmd);
SWLoadBPReg(cmd);
}
break;
@ -214,7 +214,7 @@ void DecodeStandard(u32 bufferSize)
minCommandSize = vertexLoader.GetVertexSize();
readOpcode = false;
INCSTAT(stats.thisFrame.numPrimatives);
INCSTAT(swstats.thisFrame.numPrimatives);
DEBUG_LOG(VIDEO, "Draw begin");
}
else

View File

@ -1,223 +0,0 @@
// Copyright (C) 2003 Dolphin Project.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU General Public License as published by
// the Free Software Foundation, version 2.0.
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License 2.0 for more details.
// A copy of the GPL 2.0 should have been included with the program.
// If not, see http://www.gnu.org/licenses/
// Official SVN repository and contact information can be found at
// http://code.google.com/p/dolphin-emu/
#include "GLUtil.h"
#include <string.h>
#include "RasterFont.h"
// globals
GLubyte rasters[][13] = {
{0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00},
{0x00, 0x00, 0x18, 0x18, 0x00, 0x00, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18},
{0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x36, 0x36, 0x36, 0x36},
{0x00, 0x00, 0x00, 0x66, 0x66, 0xff, 0x66, 0x66, 0xff, 0x66, 0x66, 0x00, 0x00},
{0x00, 0x00, 0x18, 0x7e, 0xff, 0x1b, 0x1f, 0x7e, 0xf8, 0xd8, 0xff, 0x7e, 0x18},
{0x00, 0x00, 0x0e, 0x1b, 0xdb, 0x6e, 0x30, 0x18, 0x0c, 0x76, 0xdb, 0xd8, 0x70},
{0x00, 0x00, 0x7f, 0xc6, 0xcf, 0xd8, 0x70, 0x70, 0xd8, 0xcc, 0xcc, 0x6c, 0x38},
{0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x1c, 0x0c, 0x0e},
{0x00, 0x00, 0x0c, 0x18, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x18, 0x0c},
{0x00, 0x00, 0x30, 0x18, 0x0c, 0x0c, 0x0c, 0x0c, 0x0c, 0x0c, 0x0c, 0x18, 0x30},
{0x00, 0x00, 0x00, 0x00, 0x99, 0x5a, 0x3c, 0xff, 0x3c, 0x5a, 0x99, 0x00, 0x00},
{0x00, 0x00, 0x00, 0x18, 0x18, 0x18, 0xff, 0xff, 0x18, 0x18, 0x18, 0x00, 0x00},
{0x00, 0x00, 0x30, 0x18, 0x1c, 0x1c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00},
{0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00},
{0x00, 0x00, 0x00, 0x38, 0x38, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00},
{0x00, 0x60, 0x60, 0x30, 0x30, 0x18, 0x18, 0x0c, 0x0c, 0x06, 0x06, 0x03, 0x03},
{0x00, 0x00, 0x3c, 0x66, 0xc3, 0xe3, 0xf3, 0xdb, 0xcf, 0xc7, 0xc3, 0x66, 0x3c},
{0x00, 0x00, 0x7e, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x78, 0x38, 0x18},
{0x00, 0x00, 0xff, 0xc0, 0xc0, 0x60, 0x30, 0x18, 0x0c, 0x06, 0x03, 0xe7, 0x7e},
{0x00, 0x00, 0x7e, 0xe7, 0x03, 0x03, 0x07, 0x7e, 0x07, 0x03, 0x03, 0xe7, 0x7e},
{0x00, 0x00, 0x0c, 0x0c, 0x0c, 0x0c, 0x0c, 0xff, 0xcc, 0x6c, 0x3c, 0x1c, 0x0c},
{0x00, 0x00, 0x7e, 0xe7, 0x03, 0x03, 0x07, 0xfe, 0xc0, 0xc0, 0xc0, 0xc0, 0xff},
{0x00, 0x00, 0x7e, 0xe7, 0xc3, 0xc3, 0xc7, 0xfe, 0xc0, 0xc0, 0xc0, 0xe7, 0x7e},
{0x00, 0x00, 0x30, 0x30, 0x30, 0x30, 0x18, 0x0c, 0x06, 0x03, 0x03, 0x03, 0xff},
{0x00, 0x00, 0x7e, 0xe7, 0xc3, 0xc3, 0xe7, 0x7e, 0xe7, 0xc3, 0xc3, 0xe7, 0x7e},
{0x00, 0x00, 0x7e, 0xe7, 0x03, 0x03, 0x03, 0x7f, 0xe7, 0xc3, 0xc3, 0xe7, 0x7e},
{0x00, 0x00, 0x00, 0x38, 0x38, 0x00, 0x00, 0x38, 0x38, 0x00, 0x00, 0x00, 0x00},
{0x00, 0x00, 0x30, 0x18, 0x1c, 0x1c, 0x00, 0x00, 0x1c, 0x1c, 0x00, 0x00, 0x00},
{0x00, 0x00, 0x06, 0x0c, 0x18, 0x30, 0x60, 0xc0, 0x60, 0x30, 0x18, 0x0c, 0x06},
{0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 0x00, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00},
{0x00, 0x00, 0x60, 0x30, 0x18, 0x0c, 0x06, 0x03, 0x06, 0x0c, 0x18, 0x30, 0x60},
{0x00, 0x00, 0x18, 0x00, 0x00, 0x18, 0x18, 0x0c, 0x06, 0x03, 0xc3, 0xc3, 0x7e},
{0x00, 0x00, 0x3f, 0x60, 0xcf, 0xdb, 0xd3, 0xdd, 0xc3, 0x7e, 0x00, 0x00, 0x00},
{0x00, 0x00, 0xc3, 0xc3, 0xc3, 0xc3, 0xff, 0xc3, 0xc3, 0xc3, 0x66, 0x3c, 0x18},
{0x00, 0x00, 0xfe, 0xc7, 0xc3, 0xc3, 0xc7, 0xfe, 0xc7, 0xc3, 0xc3, 0xc7, 0xfe},
{0x00, 0x00, 0x7e, 0xe7, 0xc0, 0xc0, 0xc0, 0xc0, 0xc0, 0xc0, 0xc0, 0xe7, 0x7e},
{0x00, 0x00, 0xfc, 0xce, 0xc7, 0xc3, 0xc3, 0xc3, 0xc3, 0xc3, 0xc7, 0xce, 0xfc},
{0x00, 0x00, 0xff, 0xc0, 0xc0, 0xc0, 0xc0, 0xfc, 0xc0, 0xc0, 0xc0, 0xc0, 0xff},
{0x00, 0x00, 0xc0, 0xc0, 0xc0, 0xc0, 0xc0, 0xc0, 0xfc, 0xc0, 0xc0, 0xc0, 0xff},
{0x00, 0x00, 0x7e, 0xe7, 0xc3, 0xc3, 0xcf, 0xc0, 0xc0, 0xc0, 0xc0, 0xe7, 0x7e},
{0x00, 0x00, 0xc3, 0xc3, 0xc3, 0xc3, 0xc3, 0xff, 0xc3, 0xc3, 0xc3, 0xc3, 0xc3},
{0x00, 0x00, 0x7e, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x7e},
{0x00, 0x00, 0x7c, 0xee, 0xc6, 0x06, 0x06, 0x06, 0x06, 0x06, 0x06, 0x06, 0x06},
{0x00, 0x00, 0xc3, 0xc6, 0xcc, 0xd8, 0xf0, 0xe0, 0xf0, 0xd8, 0xcc, 0xc6, 0xc3},
{0x00, 0x00, 0xff, 0xc0, 0xc0, 0xc0, 0xc0, 0xc0, 0xc0, 0xc0, 0xc0, 0xc0, 0xc0},
{0x00, 0x00, 0xc3, 0xc3, 0xc3, 0xc3, 0xc3, 0xc3, 0xdb, 0xff, 0xff, 0xe7, 0xc3},
{0x00, 0x00, 0xc7, 0xc7, 0xcf, 0xcf, 0xdf, 0xdb, 0xfb, 0xf3, 0xf3, 0xe3, 0xe3},
{0x00, 0x00, 0x7e, 0xe7, 0xc3, 0xc3, 0xc3, 0xc3, 0xc3, 0xc3, 0xc3, 0xe7, 0x7e},
{0x00, 0x00, 0xc0, 0xc0, 0xc0, 0xc0, 0xc0, 0xfe, 0xc7, 0xc3, 0xc3, 0xc7, 0xfe},
{0x00, 0x00, 0x3f, 0x6e, 0xdf, 0xdb, 0xc3, 0xc3, 0xc3, 0xc3, 0xc3, 0x66, 0x3c},
{0x00, 0x00, 0xc3, 0xc6, 0xcc, 0xd8, 0xf0, 0xfe, 0xc7, 0xc3, 0xc3, 0xc7, 0xfe},
{0x00, 0x00, 0x7e, 0xe7, 0x03, 0x03, 0x07, 0x7e, 0xe0, 0xc0, 0xc0, 0xe7, 0x7e},
{0x00, 0x00, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0xff},
{0x00, 0x00, 0x7e, 0xe7, 0xc3, 0xc3, 0xc3, 0xc3, 0xc3, 0xc3, 0xc3, 0xc3, 0xc3},
{0x00, 0x00, 0x18, 0x3c, 0x3c, 0x66, 0x66, 0xc3, 0xc3, 0xc3, 0xc3, 0xc3, 0xc3},
{0x00, 0x00, 0xc3, 0xe7, 0xff, 0xff, 0xdb, 0xdb, 0xc3, 0xc3, 0xc3, 0xc3, 0xc3},
{0x00, 0x00, 0xc3, 0x66, 0x66, 0x3c, 0x3c, 0x18, 0x3c, 0x3c, 0x66, 0x66, 0xc3},
{0x00, 0x00, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x3c, 0x3c, 0x66, 0x66, 0xc3},
{0x00, 0x00, 0xff, 0xc0, 0xc0, 0x60, 0x30, 0x7e, 0x0c, 0x06, 0x03, 0x03, 0xff},
{0x00, 0x00, 0x3c, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x3c},
{0x00, 0x03, 0x03, 0x06, 0x06, 0x0c, 0x0c, 0x18, 0x18, 0x30, 0x30, 0x60, 0x60},
{0x00, 0x00, 0x3c, 0x0c, 0x0c, 0x0c, 0x0c, 0x0c, 0x0c, 0x0c, 0x0c, 0x0c, 0x3c},
{0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc3, 0x66, 0x3c, 0x18},
{0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00},
{0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x38, 0x30, 0x70},
{0x00, 0x00, 0x7f, 0xc3, 0xc3, 0x7f, 0x03, 0xc3, 0x7e, 0x00, 0x00, 0x00, 0x00},
{0x00, 0x00, 0xfe, 0xc3, 0xc3, 0xc3, 0xc3, 0xfe, 0xc0, 0xc0, 0xc0, 0xc0, 0xc0},
{0x00, 0x00, 0x7e, 0xc3, 0xc0, 0xc0, 0xc0, 0xc3, 0x7e, 0x00, 0x00, 0x00, 0x00},
{0x00, 0x00, 0x7f, 0xc3, 0xc3, 0xc3, 0xc3, 0x7f, 0x03, 0x03, 0x03, 0x03, 0x03},
{0x00, 0x00, 0x7f, 0xc0, 0xc0, 0xfe, 0xc3, 0xc3, 0x7e, 0x00, 0x00, 0x00, 0x00},
{0x00, 0x00, 0x30, 0x30, 0x30, 0x30, 0x30, 0xfc, 0x30, 0x30, 0x30, 0x33, 0x1e},
{0x7e, 0xc3, 0x03, 0x03, 0x7f, 0xc3, 0xc3, 0xc3, 0x7e, 0x00, 0x00, 0x00, 0x00},
{0x00, 0x00, 0xc3, 0xc3, 0xc3, 0xc3, 0xc3, 0xc3, 0xfe, 0xc0, 0xc0, 0xc0, 0xc0},
{0x00, 0x00, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x00, 0x00, 0x18, 0x00},
{0x38, 0x6c, 0x0c, 0x0c, 0x0c, 0x0c, 0x0c, 0x0c, 0x0c, 0x00, 0x00, 0x0c, 0x00},
{0x00, 0x00, 0xc6, 0xcc, 0xf8, 0xf0, 0xd8, 0xcc, 0xc6, 0xc0, 0xc0, 0xc0, 0xc0},
{0x00, 0x00, 0x7e, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x78},
{0x00, 0x00, 0xdb, 0xdb, 0xdb, 0xdb, 0xdb, 0xdb, 0xfe, 0x00, 0x00, 0x00, 0x00},
{0x00, 0x00, 0xc6, 0xc6, 0xc6, 0xc6, 0xc6, 0xc6, 0xfc, 0x00, 0x00, 0x00, 0x00},
{0x00, 0x00, 0x7c, 0xc6, 0xc6, 0xc6, 0xc6, 0xc6, 0x7c, 0x00, 0x00, 0x00, 0x00},
{0xc0, 0xc0, 0xc0, 0xfe, 0xc3, 0xc3, 0xc3, 0xc3, 0xfe, 0x00, 0x00, 0x00, 0x00},
{0x03, 0x03, 0x03, 0x7f, 0xc3, 0xc3, 0xc3, 0xc3, 0x7f, 0x00, 0x00, 0x00, 0x00},
{0x00, 0x00, 0xc0, 0xc0, 0xc0, 0xc0, 0xc0, 0xe0, 0xfe, 0x00, 0x00, 0x00, 0x00},
{0x00, 0x00, 0xfe, 0x03, 0x03, 0x7e, 0xc0, 0xc0, 0x7f, 0x00, 0x00, 0x00, 0x00},
{0x00, 0x00, 0x1c, 0x36, 0x30, 0x30, 0x30, 0x30, 0xfc, 0x30, 0x30, 0x30, 0x00},
{0x00, 0x00, 0x7e, 0xc6, 0xc6, 0xc6, 0xc6, 0xc6, 0xc6, 0x00, 0x00, 0x00, 0x00},
{0x00, 0x00, 0x18, 0x3c, 0x3c, 0x66, 0x66, 0xc3, 0xc3, 0x00, 0x00, 0x00, 0x00},
{0x00, 0x00, 0xc3, 0xe7, 0xff, 0xdb, 0xc3, 0xc3, 0xc3, 0x00, 0x00, 0x00, 0x00},
{0x00, 0x00, 0xc3, 0x66, 0x3c, 0x18, 0x3c, 0x66, 0xc3, 0x00, 0x00, 0x00, 0x00},
{0xc0, 0x60, 0x60, 0x30, 0x18, 0x3c, 0x66, 0x66, 0xc3, 0x00, 0x00, 0x00, 0x00},
{0x00, 0x00, 0xff, 0x60, 0x30, 0x18, 0x0c, 0x06, 0xff, 0x00, 0x00, 0x00, 0x00},
{0x00, 0x00, 0x0f, 0x18, 0x18, 0x18, 0x38, 0xf0, 0x38, 0x18, 0x18, 0x18, 0x0f},
{0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18},
{0x00, 0x00, 0xf0, 0x18, 0x18, 0x18, 0x1c, 0x0f, 0x1c, 0x18, 0x18, 0x18, 0xf0},
{0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x8f, 0xf1, 0x60, 0x00, 0x00, 0x00}
};
RasterFont::RasterFont()
{
// set GL modes
glPixelStorei(GL_UNPACK_ALIGNMENT, 1);
// create the raster font
fontOffset = glGenLists(128);
for (int i = 32; i < 127; i++) {
glNewList(i + fontOffset, GL_COMPILE);
glBitmap(8, 13, 0.0f, 2.0f, 10.0f, 0.0f, rasters[i - 32]);
glEndList();
}
temp_buffer = new char[TEMP_BUFFER_SIZE];
}
RasterFont::~RasterFont()
{
glDeleteLists(fontOffset, 128);
delete [] temp_buffer;
}
void RasterFont::printString(const char *s, double x, double y, double z)
{
int length = (int)strlen(s);
if (!length)
return;
if (length >= TEMP_BUFFER_SIZE)
length = TEMP_BUFFER_SIZE - 1;
// Sanitize string to avoid GL errors.
char *s2 = temp_buffer;
memcpy(s2, s, length);
s2[length] = 0;
for (int i = 0; i < length; i++) {
if (s2[i] < 32 || s2[i] > 126)
s2[i] = '!';
}
// go to the right spot
glRasterPos3d(x, y, z);
GL_REPORT_ERRORD();
glPushAttrib (GL_LIST_BIT);
glListBase(fontOffset);
glCallLists((GLsizei)strlen(s2), GL_UNSIGNED_BYTE, (GLubyte *) s2);
GL_REPORT_ERRORD();
glPopAttrib();
GL_REPORT_ERRORD();
}
void RasterFont::printCenteredString(const char *s, double y, int screen_width, double z)
{
int length = (int)strlen(s);
int x = (int)(screen_width/2.0 - (length/2.0)*char_width);
printString(s, x, y, z);
}
void RasterFont::printMultilineText(const char *text, double start_x, double start_y, double z, int bbWidth, int bbHeight)
{
double x = start_x;
double y = start_y;
char temp[1024];
char *t = temp;
while (*text)
{
if (*text == '\n')
{
*t = 0;
printString(temp, x, y, z);
y -= char_height * 2.0f / bbHeight;
x = start_x;
t = temp;
}
else if (*text == '\r')
{
t = temp;
}
else if (*text == '\t')
{
//todo: add tabs every something like 4*char_width
*t = 0;
int cpos = (int)strlen(temp);
int newpos = (cpos + 4) & (~3);
printString(temp, x, y, z);
x = start_x + (char_width*newpos) * 2.0f / bbWidth;
t = temp;
*t++ = ' ';
}
else
*t++ = *text;
text++;
}
// ????
if (t != text)
{
*t = 0;
printString(temp, x, y, z);
}
}

View File

@ -1,42 +0,0 @@
// Copyright (C) 2003 Dolphin Project.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU General Public License as published by
// the Free Software Foundation, version 2.0.
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License 2.0 for more details.
// A copy of the GPL 2.0 should have been included with the program.
// If not, see http://www.gnu.org/licenses/
// Official SVN repository and contact information can be found at
// http://code.google.com/p/dolphin-emu/
#ifndef _RASTERFONT_H_
#define _RASTERFONT_H_
class RasterFont {
public:
RasterFont();
~RasterFont(void);
static int debug;
// some useful constants
enum {char_width = 10};
enum {char_height = 15};
// and the happy helper functions
void printString(const char *s, double x, double y, double z=0.0);
void printCenteredString(const char *s, double y, int screen_width, double z=0.0);
void printMultilineText(const char *text, double x, double y, double z, int bbWidth, int bbHeight);
private:
int fontOffset;
char *temp_buffer;
enum {TEMP_BUFFER_SIZE = 64 * 1024};
};
#endif // _RASTERFONT_H_

View File

@ -23,7 +23,7 @@
#include "BPMemLoader.h"
#include "XFMemLoader.h"
#include "Tev.h"
#include "Statistics.h"
#include "SWStatistics.h"
#include "SWVideoConfig.h"
@ -111,7 +111,7 @@ void SetTevReg(int reg, int comp, bool konst, s16 color)
inline void Draw(s32 x, s32 y, s32 xi, s32 yi)
{
INCSTAT(stats.thisFrame.rasterizedPixels);
INCSTAT(swstats.thisFrame.rasterizedPixels);
float dx = vertexOffsetX + (float)(x - vertex0X);
float dy = vertexOffsetY + (float)(y - vertex0Y);
@ -258,7 +258,7 @@ void BuildBlock(s32 blockX, s32 blockY)
for (unsigned int i = 0; i < bpmem.genMode.numtexgens; i++)
{
float projection = invW;
if (xfregs.texMtxInfo[i].projection)
if (swxfregs.texMtxInfo[i].projection)
{
float q = TexSlopes[i][2].GetValue(dx, dy) * invW;
if (q != 0.0f)
@ -298,7 +298,7 @@ void BuildBlock(s32 blockX, s32 blockY)
void DrawTriangleFrontFace(OutputVertexData *v0, OutputVertexData *v1, OutputVertexData *v2)
{
INCSTAT(stats.thisFrame.numTrianglesDrawn);
INCSTAT(swstats.thisFrame.numTrianglesDrawn);
if (g_SWVideoConfig.bHwRasterizer)
{

View File

@ -7,26 +7,25 @@ import sys
files = [
'BPMemLoader.cpp',
'Clipper.cpp',
'CommandProcessor.cpp',
'SWCommandProcessor.cpp',
'CPMemLoader.cpp',
'DebugUtil.cpp',
'EfbCopy.cpp',
'EfbInterface.cpp',
'GLUtil.cpp',
'SWGLUtil.cpp',
'HwRasterizer.cpp',
'main.cpp',
'SWmain.cpp',
'OpcodeDecoder.cpp',
'PixelEngine.cpp',
'SWPixelEngine.cpp',
'Rasterizer.cpp',
'RasterFont.cpp',
'Renderer.cpp',
'SWRenderer.cpp',
'SetupUnit.cpp',
'Statistics.cpp',
'SWStatistics.cpp',
'Tev.cpp',
'TextureEncoder.cpp',
'TextureSampler.cpp',
'TransformUnit.cpp',
'VertexLoader.cpp',
'SWVertexLoader.cpp',
'SWVideoConfig.cpp',
'XFMemLoader.cpp',
]

View File

@ -24,11 +24,11 @@
#include "HW/Memmap.h"
#include "HW/ProcessorInterface.h"
#include "CommandProcessor.h"
#include "VideoBackend.h"
#include "SWCommandProcessor.h"
#include "ChunkFile.h"
#include "MathUtil.h"
volatile bool g_bSkipCurrentFrame;
bool fifoStateRun;
// set to 0 if using in video common
@ -37,8 +37,6 @@ bool fifoStateRun;
#if (SW_PLUGIN)
#include "OpcodeDecoder.h"
#include "main.h"
u8* g_pVideoData;
#else
@ -49,7 +47,7 @@ extern u8* g_pVideoData;
#endif
namespace CommandProcessor
namespace SWCommandProcessor
{
enum
@ -407,10 +405,10 @@ void SetStatus()
if (SConfig::GetInstance().m_LocalCoreStartupParameter.bCPUThread)
{
interruptWaiting = true;
CommandProcessor::UpdateInterruptsFromVideoPlugin(userdata);
SWCommandProcessor::UpdateInterruptsFromVideoPlugin(userdata);
}
else
CommandProcessor::UpdateInterrupts(userdata);
SWCommandProcessor::UpdateInterrupts(userdata);
}
}
@ -468,20 +466,20 @@ bool RunBuffer()
return ranDecoder;
}
} // end of namespace CommandProcessor
} // end of namespace SWCommandProcessor
// fifo functions
#if (SW_PLUGIN)
void Fifo_EnterLoop()
void SWFifo_EnterLoop()
{
fifoStateRun = true;
while (fifoStateRun)
{
g_video_backend->PeekMessages();
if (!CommandProcessor::RunBuffer()) {
if (!SWCommandProcessor::RunBuffer()) {
Common::YieldCPU();
}
}
@ -508,6 +506,7 @@ void Fifo_EnterLoop(const SVideoInitialize &video_initialize)
#endif
#if 0
void Fifo_ExitLoop()
{
fifoStateRun = false;
@ -525,10 +524,11 @@ void Fifo_DoState(PointerWrap &p) {}
u8* FAKE_GetFifoStartPtr()
{
return CommandProcessor::commandBuffer;
return SWCommandProcessor::commandBuffer;
}
u8* FAKE_GetFifoEndPtr()
{
return &CommandProcessor::commandBuffer[CommandProcessor::writePos];
return &SWCommandProcessor::commandBuffer[SWCommandProcessor::writePos];
}
#endif

View File

@ -23,6 +23,7 @@
class PointerWrap;
extern volatile bool g_bSkipCurrentFrame;
extern u8* g_pVideoData;
// for compatibility with video common
void Fifo_Init();
@ -38,7 +39,7 @@ void VideoFifo_CheckSwapRequest();
void VideoFifo_CheckSwapRequestAt(u32 xfbAddr, u32 fbWidth, u32 fbHeight);
void VideoFifo_CheckEFBAccess();
namespace CommandProcessor
namespace SWCommandProcessor
{
// internal hardware addresses
enum
@ -164,7 +165,7 @@ namespace CommandProcessor
void UpdateInterruptsFromVideoPlugin(u64 userdata);
} // end of namespace CommandProcessor
} // end of namespace SWCommandProcessor
#endif

View File

@ -15,7 +15,6 @@
// Official SVN repository and contact information can be found at
// http://code.google.com/p/dolphin-emu/
#include "main.h"
#include "SWVideoConfig.h"
#include "IniFile.h"
#include "Setup.h"
@ -23,7 +22,7 @@
#include "Core.h"
#include "Host.h"
#include "GLUtil.h"
#include "SWGLUtil.h"
#if defined(_WIN32)
#include "Win32.h"

View File

@ -26,11 +26,11 @@
#include "ConfigManager.h"
#include "HW/ProcessorInterface.h"
#include "PixelEngine.h"
#include "CommandProcessor.h"
#include "SWPixelEngine.h"
#include "SWCommandProcessor.h"
namespace PixelEngine
namespace SWPixelEngine
{
enum
@ -170,4 +170,4 @@ void SetFinish()
INFO_LOG(PIXELENGINE, "VIDEO Set Finish");
}
} // end of namespace PixelEngine
} // end of namespace SWPixelEngine

View File

@ -22,7 +22,7 @@
class PointerWrap;
namespace PixelEngine
namespace SWPixelEngine
{
// internal hardware addresses
enum
@ -148,8 +148,6 @@ namespace PixelEngine
void SetFinish(void);
bool AllowIdleSkipping();
} // end of namespace PixelEngine
} // end of namespace SWPixelEngine
#endif

View File

@ -18,11 +18,10 @@
#include "Common.h"
#include "Core.h"
#include "GLUtil.h"
#include "Renderer.h"
#include "main.h"
#include "Statistics.h"
#include "RasterFont.h"
#include "SWGLUtil.h"
#include "SWRenderer.h"
#include "SWStatistics.h"
#include "../../Plugin_VideoOGL/Src/RasterFont.h"
#define VSYNC_ENABLED 0
@ -30,16 +29,16 @@ static GLuint s_RenderTarget = 0;
RasterFont* s_pfont = NULL;
void Renderer::Init()
void SWRenderer::Init()
{
if (!OpenGL_Create(640, 480)) // 640x480 will be the default if all else fails
{
Core::Callback_VideoLog("Renderer::Create failed\n");
Core::Callback_VideoLog("SWRenderer::Create failed\n");
return;
}
}
void Renderer::Shutdown()
void SWRenderer::Shutdown()
{
glDeleteTextures(1, &s_RenderTarget);
@ -47,7 +46,7 @@ void Renderer::Shutdown()
s_pfont = 0;
}
void Renderer::Prepare()
void SWRenderer::Prepare()
{
OpenGL_MakeCurrent();
@ -104,7 +103,7 @@ void Renderer::Prepare()
glEnable(GL_TEXTURE_RECTANGLE_ARB);
}
void Renderer::RenderText(const char* pstr, int left, int top, u32 color)
void SWRenderer::RenderText(const char* pstr, int left, int top, u32 color)
{
int nBackbufferWidth = (int)OpenGL_GetBackbufferWidth();
int nBackbufferHeight = (int)OpenGL_GetBackbufferHeight();
@ -116,7 +115,7 @@ void Renderer::RenderText(const char* pstr, int left, int top, u32 color)
0, nBackbufferWidth, nBackbufferHeight);
}
void Renderer::DrawDebugText()
void SWRenderer::DrawDebugText()
{
char debugtext_buffer[8192];
char *p = debugtext_buffer;
@ -124,27 +123,27 @@ void Renderer::DrawDebugText()
if (g_SWVideoConfig.bShowStats)
{
p+=sprintf(p,"Objects: %i\n",stats.thisFrame.numDrawnObjects);
p+=sprintf(p,"Primatives: %i\n",stats.thisFrame.numPrimatives);
p+=sprintf(p,"Vertices Loaded: %i\n",stats.thisFrame.numVerticesLoaded);
p+=sprintf(p,"Objects: %i\n",swstats.thisFrame.numDrawnObjects);
p+=sprintf(p,"Primatives: %i\n",swstats.thisFrame.numPrimatives);
p+=sprintf(p,"Vertices Loaded: %i\n",swstats.thisFrame.numVerticesLoaded);
p+=sprintf(p,"Triangles Input: %i\n",stats.thisFrame.numTrianglesIn);
p+=sprintf(p,"Triangles Rejected: %i\n",stats.thisFrame.numTrianglesRejected);
p+=sprintf(p,"Triangles Culled: %i\n",stats.thisFrame.numTrianglesCulled);
p+=sprintf(p,"Triangles Clipped: %i\n",stats.thisFrame.numTrianglesClipped);
p+=sprintf(p,"Triangles Drawn: %i\n",stats.thisFrame.numTrianglesDrawn);
p+=sprintf(p,"Triangles Input: %i\n",swstats.thisFrame.numTrianglesIn);
p+=sprintf(p,"Triangles Rejected: %i\n",swstats.thisFrame.numTrianglesRejected);
p+=sprintf(p,"Triangles Culled: %i\n",swstats.thisFrame.numTrianglesCulled);
p+=sprintf(p,"Triangles Clipped: %i\n",swstats.thisFrame.numTrianglesClipped);
p+=sprintf(p,"Triangles Drawn: %i\n",swstats.thisFrame.numTrianglesDrawn);
p+=sprintf(p,"Rasterized Pix: %i\n",stats.thisFrame.rasterizedPixels);
p+=sprintf(p,"TEV Pix In: %i\n",stats.thisFrame.tevPixelsIn);
p+=sprintf(p,"TEV Pix Out: %i\n",stats.thisFrame.tevPixelsOut);
p+=sprintf(p,"Rasterized Pix: %i\n",swstats.thisFrame.rasterizedPixels);
p+=sprintf(p,"TEV Pix In: %i\n",swstats.thisFrame.tevPixelsIn);
p+=sprintf(p,"TEV Pix Out: %i\n",swstats.thisFrame.tevPixelsOut);
}
// Render a shadow, and then the text.
Renderer::RenderText(debugtext_buffer, 21, 21, 0xDD000000);
Renderer::RenderText(debugtext_buffer, 20, 20, 0xFFFFFF00);
SWRenderer::RenderText(debugtext_buffer, 21, 21, 0xDD000000);
SWRenderer::RenderText(debugtext_buffer, 20, 20, 0xFFFFFF00);
}
void Renderer::DrawTexture(u8 *texture, int width, int height)
void SWRenderer::DrawTexture(u8 *texture, int width, int height)
{
GLsizei glWidth = (GLsizei)OpenGL_GetBackbufferWidth();
GLsizei glHeight = (GLsizei)OpenGL_GetBackbufferHeight();
@ -173,7 +172,7 @@ void Renderer::DrawTexture(u8 *texture, int width, int height)
glBindTexture(GL_TEXTURE_RECTANGLE_ARB, 0);
}
void Renderer::SwapBuffer()
void SWRenderer::SwapBuffer()
{
DrawDebugText();
@ -183,7 +182,7 @@ void Renderer::SwapBuffer()
GL_REPORT_ERRORD();
stats.ResetFrame();
swstats.ResetFrame();
// Clear framebuffer
glClearColor(0, 0, 0, 0);
@ -192,5 +191,3 @@ void Renderer::SwapBuffer()
GL_REPORT_ERRORD();
}

View File

@ -20,7 +20,7 @@
#include "CommonTypes.h"
namespace Renderer
namespace SWRenderer
{
void Init();
void Prepare();

View File

@ -15,9 +15,9 @@
// Official SVN repository and contact information can be found at
// http://code.google.com/p/dolphin-emu/
#include "Statistics.h"
#include "SWStatistics.h"
Statistics stats;
SWStatistics swstats;
template <class T>
void Xchg(T& a, T&b)
@ -27,12 +27,12 @@ void Xchg(T& a, T&b)
b = c;
}
Statistics::Statistics()
SWStatistics::SWStatistics()
{
frameCount = 0;
}
void Statistics::ResetFrame()
void SWStatistics::ResetFrame()
{
memset(&thisFrame, 0, sizeof(ThisFrame));
}

View File

@ -21,7 +21,7 @@
#ifndef _STATISTICS_H
#define _STATISTICS_H
struct Statistics
struct SWStatistics
{
struct ThisFrame
{
@ -42,13 +42,13 @@ struct Statistics
};
u32 frameCount;
Statistics();
SWStatistics();
ThisFrame thisFrame;
void ResetFrame();
};
extern Statistics stats;
extern SWStatistics swstats;
#if (STATISTICS)
#define INCSTAT(a) (a)++;

View File

@ -17,7 +17,7 @@
#include "Common.h"
#include "VertexLoader.h"
#include "SWVertexLoader.h"
#include "VertexLoader_Position.h"
#include "../../../Core/VideoCommon/Src/VertexLoader_Normal.h"
#include "../../../Core/VideoCommon/Src/VertexLoader_Color.h"
@ -28,19 +28,18 @@
#include "TransformUnit.h"
#include "SetupUnit.h"
#include "Statistics.h"
#include "SWStatistics.h"
#include "VertexManagerBase.h"
#include "../../../Core/VideoCommon/Src/DataReader.h"
// Vertex loaders read these
int tcIndex;
int colIndex;
int colElements[2];
float posScale;
float tcScale[8];
static int tcIndex;
static int colIndex;
static int colElements[2];
static float posScale;
static float tcScale[8];
VertexLoader::VertexLoader() :
SWVertexLoader::SWVertexLoader() :
m_VertexSize(0),
m_NumAttributeLoaders(0)
{
@ -51,13 +50,13 @@ VertexLoader::VertexLoader() :
m_SetupUnit = new SetupUnit;
}
VertexLoader::~VertexLoader()
SWVertexLoader::~SWVertexLoader()
{
delete m_SetupUnit;
m_SetupUnit = NULL;
}
void VertexLoader::SetFormat(u8 attributeIndex, u8 primitiveType)
void SWVertexLoader::SetFormat(u8 attributeIndex, u8 primitiveType)
{
m_CurrentVat = &g_VtxAttr[attributeIndex];
@ -107,15 +106,15 @@ void VertexLoader::SetFormat(u8 attributeIndex, u8 primitiveType)
// Reset vertex
// matrix index from xf regs or cp memory?
if (xfregs.MatrixIndexA.PosNormalMtxIdx != MatrixIndexA.PosNormalMtxIdx ||
xfregs.MatrixIndexA.Tex0MtxIdx != MatrixIndexA.Tex0MtxIdx ||
xfregs.MatrixIndexA.Tex1MtxIdx != MatrixIndexA.Tex1MtxIdx ||
xfregs.MatrixIndexA.Tex2MtxIdx != MatrixIndexA.Tex2MtxIdx ||
xfregs.MatrixIndexA.Tex3MtxIdx != MatrixIndexA.Tex3MtxIdx ||
xfregs.MatrixIndexB.Tex4MtxIdx != MatrixIndexB.Tex4MtxIdx ||
xfregs.MatrixIndexB.Tex5MtxIdx != MatrixIndexB.Tex5MtxIdx ||
xfregs.MatrixIndexB.Tex6MtxIdx != MatrixIndexB.Tex6MtxIdx ||
xfregs.MatrixIndexB.Tex7MtxIdx != MatrixIndexB.Tex7MtxIdx)
if (swxfregs.MatrixIndexA.PosNormalMtxIdx != MatrixIndexA.PosNormalMtxIdx ||
swxfregs.MatrixIndexA.Tex0MtxIdx != MatrixIndexA.Tex0MtxIdx ||
swxfregs.MatrixIndexA.Tex1MtxIdx != MatrixIndexA.Tex1MtxIdx ||
swxfregs.MatrixIndexA.Tex2MtxIdx != MatrixIndexA.Tex2MtxIdx ||
swxfregs.MatrixIndexA.Tex3MtxIdx != MatrixIndexA.Tex3MtxIdx ||
swxfregs.MatrixIndexB.Tex4MtxIdx != MatrixIndexB.Tex4MtxIdx ||
swxfregs.MatrixIndexB.Tex5MtxIdx != MatrixIndexB.Tex5MtxIdx ||
swxfregs.MatrixIndexB.Tex6MtxIdx != MatrixIndexB.Tex6MtxIdx ||
swxfregs.MatrixIndexB.Tex7MtxIdx != MatrixIndexB.Tex7MtxIdx)
{
WARN_LOG(VIDEO, "Matrix indices don't match");
@ -126,15 +125,15 @@ void VertexLoader::SetFormat(u8 attributeIndex, u8 primitiveType)
}
#if(1)
m_Vertex.posMtx = xfregs.MatrixIndexA.PosNormalMtxIdx;
m_Vertex.texMtx[0] = xfregs.MatrixIndexA.Tex0MtxIdx;
m_Vertex.texMtx[1] = xfregs.MatrixIndexA.Tex1MtxIdx;
m_Vertex.texMtx[2] = xfregs.MatrixIndexA.Tex2MtxIdx;
m_Vertex.texMtx[3] = xfregs.MatrixIndexA.Tex3MtxIdx;
m_Vertex.texMtx[4] = xfregs.MatrixIndexB.Tex4MtxIdx;
m_Vertex.texMtx[5] = xfregs.MatrixIndexB.Tex5MtxIdx;
m_Vertex.texMtx[6] = xfregs.MatrixIndexB.Tex6MtxIdx;
m_Vertex.texMtx[7] = xfregs.MatrixIndexB.Tex7MtxIdx;
m_Vertex.posMtx = swxfregs.MatrixIndexA.PosNormalMtxIdx;
m_Vertex.texMtx[0] = swxfregs.MatrixIndexA.Tex0MtxIdx;
m_Vertex.texMtx[1] = swxfregs.MatrixIndexA.Tex1MtxIdx;
m_Vertex.texMtx[2] = swxfregs.MatrixIndexA.Tex2MtxIdx;
m_Vertex.texMtx[3] = swxfregs.MatrixIndexA.Tex3MtxIdx;
m_Vertex.texMtx[4] = swxfregs.MatrixIndexB.Tex4MtxIdx;
m_Vertex.texMtx[5] = swxfregs.MatrixIndexB.Tex5MtxIdx;
m_Vertex.texMtx[6] = swxfregs.MatrixIndexB.Tex6MtxIdx;
m_Vertex.texMtx[7] = swxfregs.MatrixIndexB.Tex7MtxIdx;
#else
m_Vertex.posMtx = MatrixIndexA.PosNormalMtxIdx;
m_Vertex.texMtx[0] = MatrixIndexA.Tex0MtxIdx;
@ -245,14 +244,14 @@ void VertexLoader::SetFormat(u8 attributeIndex, u8 primitiveType)
m_TexGenSpecialCase =
((g_VtxDesc.Hex & 0x60600L) == g_VtxDesc.Hex) && // only pos and tex coord 0
(g_VtxDesc.Tex0Coord != NOT_PRESENT) &&
(xfregs.texMtxInfo[0].projection == XF_TEXPROJ_ST);
(swxfregs.texMtxInfo[0].projection == XF_TEXPROJ_ST);
m_SetupUnit->Init(primitiveType);
}
void VertexLoader::LoadVertex()
void SWVertexLoader::LoadVertex()
{
for (int i = 0; i < m_NumAttributeLoaders; i++)
m_AttributeLoaders[i].loader(this, &m_Vertex, m_AttributeLoaders[i].index);
@ -273,39 +272,39 @@ void VertexLoader::LoadVertex()
m_SetupUnit->SetupVertex();
INCSTAT(stats.thisFrame.numVerticesLoaded)
INCSTAT(swstats.thisFrame.numVerticesLoaded)
}
void VertexLoader::AddAttributeLoader(AttributeLoader loader, u8 index)
void SWVertexLoader::AddAttributeLoader(AttributeLoader loader, u8 index)
{
_assert_msg_(VIDEO, m_NumAttributeLoaders < 21, "Too many attribute loaders");
m_AttributeLoaders[m_NumAttributeLoaders].loader = loader;
m_AttributeLoaders[m_NumAttributeLoaders++].index = index;
}
void VertexLoader::LoadPosMtx(VertexLoader *vertexLoader, InputVertexData *vertex, u8 unused)
void SWVertexLoader::LoadPosMtx(SWVertexLoader *vertexLoader, InputVertexData *vertex, u8 unused)
{
vertex->posMtx = DataReadU8() & 0x3f;
}
void VertexLoader::LoadTexMtx(VertexLoader *vertexLoader, InputVertexData *vertex, u8 index)
void SWVertexLoader::LoadTexMtx(SWVertexLoader *vertexLoader, InputVertexData *vertex, u8 index)
{
vertex->texMtx[index] = DataReadU8() & 0x3f;
}
void VertexLoader::LoadPosition(VertexLoader *vertexLoader, InputVertexData *vertex, u8 unused)
void SWVertexLoader::LoadPosition(SWVertexLoader *vertexLoader, InputVertexData *vertex, u8 unused)
{
VertexManager::s_pCurBufferPointer = (u8*)&vertex->position;
vertexLoader->m_positionLoader();
}
void VertexLoader::LoadNormal(VertexLoader *vertexLoader, InputVertexData *vertex, u8 unused)
void SWVertexLoader::LoadNormal(SWVertexLoader *vertexLoader, InputVertexData *vertex, u8 unused)
{
VertexManager::s_pCurBufferPointer = (u8*)&vertex->normal;
vertexLoader->m_normalLoader();
}
void VertexLoader::LoadColor(VertexLoader *vertexLoader, InputVertexData *vertex, u8 index)
void SWVertexLoader::LoadColor(SWVertexLoader *vertexLoader, InputVertexData *vertex, u8 index)
{
u32 color;
VertexManager::s_pCurBufferPointer = (u8*)&color;
@ -316,7 +315,7 @@ void VertexLoader::LoadColor(VertexLoader *vertexLoader, InputVertexData *vertex
*(u32*)vertex->color[index] = Common::swap32(color);
}
void VertexLoader::LoadTexCoord(VertexLoader *vertexLoader, InputVertexData *vertex, u8 index)
void SWVertexLoader::LoadTexCoord(SWVertexLoader *vertexLoader, InputVertexData *vertex, u8 index)
{
VertexManager::s_pCurBufferPointer = (u8*)&vertex->texCoords[index];
tcIndex = index;

View File

@ -25,7 +25,7 @@
class SetupUnit;
class VertexLoader
class SWVertexLoader
{
u32 m_VertexSize;
@ -38,7 +38,7 @@ class VertexLoader
InputVertexData m_Vertex;
typedef void (*AttributeLoader)(VertexLoader*, InputVertexData*, u8);
typedef void (*AttributeLoader)(SWVertexLoader*, InputVertexData*, u8);
struct AttrLoaderCall
{
AttributeLoader loader;
@ -49,20 +49,20 @@ class VertexLoader
void AddAttributeLoader(AttributeLoader loader, u8 index=0);
// attribute loader functions
static void LoadPosMtx(VertexLoader *vertexLoader, InputVertexData *vertex, u8 unused);
static void LoadTexMtx(VertexLoader *vertexLoader, InputVertexData *vertex, u8 index);
static void LoadPosition(VertexLoader *vertexLoader, InputVertexData *vertex, u8 unused);
static void LoadNormal(VertexLoader *vertexLoader, InputVertexData *vertex, u8 unused);
static void LoadColor(VertexLoader *vertexLoader, InputVertexData *vertex, u8 index);
static void LoadTexCoord(VertexLoader *vertexLoader, InputVertexData *vertex, u8 index);
static void LoadPosMtx(SWVertexLoader *vertexLoader, InputVertexData *vertex, u8 unused);
static void LoadTexMtx(SWVertexLoader *vertexLoader, InputVertexData *vertex, u8 index);
static void LoadPosition(SWVertexLoader *vertexLoader, InputVertexData *vertex, u8 unused);
static void LoadNormal(SWVertexLoader *vertexLoader, InputVertexData *vertex, u8 unused);
static void LoadColor(SWVertexLoader *vertexLoader, InputVertexData *vertex, u8 index);
static void LoadTexCoord(SWVertexLoader *vertexLoader, InputVertexData *vertex, u8 index);
SetupUnit *m_SetupUnit;
bool m_TexGenSpecialCase;
public:
VertexLoader();
~VertexLoader();
SWVertexLoader();
~SWVertexLoader();
void SetFormat(u8 attributeIndex, u8 primitiveType);

View File

@ -22,16 +22,15 @@
#include "VideoConfigDialog.h"
#endif // HAVE_WX
#include "CommandProcessor.h"
#include "SWCommandProcessor.h"
#include "OpcodeDecoder.h"
#include "SWVideoConfig.h"
#include "PixelEngine.h"
#include "CommandProcessor.h"
#include "SWPixelEngine.h"
#include "BPMemLoader.h"
#include "XFMemLoader.h"
#include "Clipper.h"
#include "Rasterizer.h"
#include "Renderer.h"
#include "SWRenderer.h"
#include "../../../Core/VideoCommon/Src/LookUpTables.h"
#include "HwRasterizer.h"
#include "LogManager.h"
@ -68,13 +67,13 @@ void VideoBackend::Initialize()
InitBPMemory();
InitXFMemory();
CommandProcessor::Init();
PixelEngine::Init();
SWCommandProcessor::Init();
SWPixelEngine::Init();
OpcodeDecoder::Init();
Clipper::Init();
Rasterizer::Init();
HwRasterizer::Init();
Renderer::Init();
SWRenderer::Init();
DebugUtil::Init();
}
@ -95,14 +94,14 @@ void VideoBackend::EmuStateChange(EMUSTATE_CHANGE newState)
void VideoBackend::Shutdown()
{
Renderer::Shutdown();
SWRenderer::Shutdown();
OpenGL_Shutdown();
}
// This is called after Video_Initialize() from the Core
void VideoBackend::Video_Prepare()
{
Renderer::Prepare();
SWRenderer::Prepare();
INFO_LOG(VIDEO, "Video plugin initialized.");
}
@ -169,6 +168,10 @@ void VideoBackend::Video_AddMessage(const char* pstr, u32 milliseconds)
{
}
void VideoBackend::Video_ClearMessages()
{
}
void VideoBackend::Video_SetRendering(bool bEnabled)
{
Fifo_SetRendering(bEnabled);
@ -176,7 +179,6 @@ void VideoBackend::Video_SetRendering(bool bEnabled)
void VideoBackend::Video_WaitForFrameFinish(void)
{
}
bool VideoBackend::Video_IsFifoBusy(void)
@ -186,7 +188,15 @@ bool VideoBackend::Video_IsFifoBusy(void)
void VideoBackend::Video_AbortFrame(void)
{
}
void VideoBackend::UpdateFPSDisplay(const char*)
{
}
unsigned int VideoBackend::PeekMessages()
{
return 0;
}
}

View File

@ -19,7 +19,7 @@
#include "CPMemLoader.h"
#include "OpcodeDecoder.h"
#include "Statistics.h"
#include "SWStatistics.h"
#include "Clipper.h"

View File

@ -20,7 +20,7 @@
#include "Tev.h"
#include "EfbInterface.h"
#include "TextureSampler.h"
#include "Statistics.h"
#include "SWStatistics.h"
#include "SWVideoConfig.h"
#include "DebugUtil.h"
@ -581,7 +581,7 @@ void Tev::Draw()
_assert_(Position[0] >= 0 && Position[0] < EFB_WIDTH);
_assert_(Position[1] >= 0 && Position[1] < EFB_HEIGHT);
INCSTAT(stats.thisFrame.tevPixelsIn);
INCSTAT(swstats.thisFrame.tevPixelsIn);
for (unsigned int stageNum = 0; stageNum < bpmem.genMode.numindstages; stageNum++)
{
@ -810,7 +810,7 @@ void Tev::Draw()
}
#endif
INCSTAT(stats.thisFrame.tevPixelsOut);
INCSTAT(swstats.thisFrame.tevPixelsOut);
EfbInterface::BlendTev(Position[0], Position[1], output);
}

View File

@ -16,7 +16,6 @@
#include "TextureSampler.h"
#include "main.h"
#include "BPMemLoader.h"
#include "../../../Core/VideoCommon/Src/TextureDecoder.h"

View File

@ -85,22 +85,22 @@ void MultipleVec3Ortho(const Vec3 &vec, const float *proj, Vec4 &result)
void TransformPosition(const InputVertexData *src, OutputVertexData *dst)
{
const float* mat = (const float*)&xfregs.posMatrices[src->posMtx * 4];
const float* mat = (const float*)&swxfregs.posMatrices[src->posMtx * 4];
MultiplyVec3Mat34(src->position, mat, dst->mvPosition);
if (xfregs.projection[6] == 0)
if (swxfregs.projection[6] == 0)
{
MultipleVec3Perspective(dst->mvPosition, xfregs.projection, dst->projectedPosition);
MultipleVec3Perspective(dst->mvPosition, swxfregs.projection, dst->projectedPosition);
}
else
{
MultipleVec3Ortho(dst->mvPosition, xfregs.projection, dst->projectedPosition);
MultipleVec3Ortho(dst->mvPosition, swxfregs.projection, dst->projectedPosition);
}
}
void TransformNormal(const InputVertexData *src, bool nbt, OutputVertexData *dst)
{
const float* mat = (const float*)&xfregs.normalMatrices[(src->posMtx & 31) * 3];
const float* mat = (const float*)&swxfregs.normalMatrices[(src->posMtx & 31) * 3];
if (nbt)
{
@ -139,7 +139,7 @@ inline void TransformTexCoordRegular(const TexMtxInfo &texinfo, int coordNum, bo
break;
}
const float *mat = (const float*)&xfregs.posMatrices[srcVertex->texMtx[coordNum] * 4];
const float *mat = (const float*)&swxfregs.posMatrices[srcVertex->texMtx[coordNum] * 4];
Vec3 *dst = &dstVertex->texCoords[coordNum];
if (texinfo.projection == XF_TEXPROJ_ST)
@ -159,13 +159,13 @@ inline void TransformTexCoordRegular(const TexMtxInfo &texinfo, int coordNum, bo
MultiplyVec3Mat34(*src, mat, *dst);
}
if (xfregs.dualTexTrans)
if (swxfregs.dualTexTrans)
{
Vec3 tempCoord;
// normalize
const PostMtxInfo &postInfo = xfregs.postMtxInfo[coordNum];
const float *postMat = (const float*)&xfregs.postMatrices[postInfo.index * 4];
const PostMtxInfo &postInfo = swxfregs.postMtxInfo[coordNum];
const float *postMat = (const float*)&swxfregs.postMatrices[postInfo.index * 4];
if (specialCase)
{
@ -227,7 +227,7 @@ inline float SafeDivide(float n, float d)
void LightColor(const Vec3 &pos, const Vec3 &normal, u8 lightNum, const LitChannel &chan, Vec3 &lightCol)
{
const LightPointer *light = (const LightPointer*)&xfregs.lights[0x10*lightNum];
const LightPointer *light = (const LightPointer*)&swxfregs.lights[0x10*lightNum];
if (!(chan.attnfunc & 1)) {
// atten disabled
@ -304,7 +304,7 @@ void LightColor(const Vec3 &pos, const Vec3 &normal, u8 lightNum, const LitChann
void LightAlpha(const Vec3 &pos, const Vec3 &normal, u8 lightNum, const LitChannel &chan, float &lightCol)
{
const LightPointer *light = (const LightPointer*)&xfregs.lights[0x10*lightNum];
const LightPointer *light = (const LightPointer*)&swxfregs.lights[0x10*lightNum];
if (!(chan.attnfunc & 1)) {
// atten disabled
@ -377,18 +377,18 @@ void LightAlpha(const Vec3 &pos, const Vec3 &normal, u8 lightNum, const LitChann
void TransformColor(const InputVertexData *src, OutputVertexData *dst)
{
for (u32 chan = 0; chan < xfregs.nNumChans; chan++)
for (u32 chan = 0; chan < swxfregs.nNumChans; chan++)
{
// abgr
u8 matcolor[4];
u8 chancolor[4];
// color
LitChannel &colorchan = xfregs.color[chan];
LitChannel &colorchan = swxfregs.color[chan];
if (colorchan.matsource)
*(u32*)matcolor = *(u32*)src->color[chan]; // vertex
else
*(u32*)matcolor = xfregs.matColor[chan];
*(u32*)matcolor = swxfregs.matColor[chan];
if (colorchan.enablelighting)
{
@ -402,7 +402,7 @@ void TransformColor(const InputVertexData *src, OutputVertexData *dst)
}
else
{
u8 *ambColor = (u8*)&xfregs.ambColor[chan];
u8 *ambColor = (u8*)&swxfregs.ambColor[chan];
lightCol.x = ambColor[1];
lightCol.y = ambColor[2];
lightCol.z = ambColor[3];
@ -425,19 +425,19 @@ void TransformColor(const InputVertexData *src, OutputVertexData *dst)
}
// alpha
LitChannel &alphachan = xfregs.alpha[chan];
LitChannel &alphachan = swxfregs.alpha[chan];
if (alphachan.matsource)
matcolor[0] = src->color[chan][0]; // vertex
else
matcolor[0] = xfregs.matColor[chan] & 0xff;
matcolor[0] = swxfregs.matColor[chan] & 0xff;
if (xfregs.alpha[chan].enablelighting)
if (swxfregs.alpha[chan].enablelighting)
{
float lightCol;
if (alphachan.ambsource)
lightCol = src->color[chan][0]; // vertex
else
lightCol = (float)(xfregs.ambColor[chan] & 0xff);
lightCol = (float)(swxfregs.ambColor[chan] & 0xff);
u8 mask = alphachan.GetFullLightMask();
for (int i = 0; i < 8; ++i) {
@ -459,9 +459,9 @@ void TransformColor(const InputVertexData *src, OutputVertexData *dst)
void TransformTexCoord(const InputVertexData *src, OutputVertexData *dst, bool specialCase)
{
for (u32 coordNum = 0; coordNum < xfregs.numTexGens; coordNum++)
for (u32 coordNum = 0; coordNum < swxfregs.numTexGens; coordNum++)
{
const TexMtxInfo &texinfo = xfregs.texMtxInfo[coordNum];
const TexMtxInfo &texinfo = swxfregs.texMtxInfo[coordNum];
switch (texinfo.texgentype)
{
@ -470,7 +470,7 @@ void TransformTexCoord(const InputVertexData *src, OutputVertexData *dst, bool s
break;
case XF_TEXGEN_EMBOSS_MAP:
{
const LightPointer *light = (const LightPointer*)&xfregs.lights[0x10*texinfo.embosslightshift];
const LightPointer *light = (const LightPointer*)&swxfregs.lights[0x10*texinfo.embosslightshift];
Vec3 ldir = (light->pos - dst->mvPosition).normalized();
float d1 = ldir * dst->normal[1];
@ -500,7 +500,7 @@ void TransformTexCoord(const InputVertexData *src, OutputVertexData *dst, bool s
}
}
for (u32 coordNum = 0; coordNum < xfregs.numTexGens; coordNum++)
for (u32 coordNum = 0; coordNum < swxfregs.numTexGens; coordNum++)
{
dst->texCoords[coordNum][0] *= (bpmem.texcoords[coordNum].s.scale_minus_1 + 1);
dst->texCoords[coordNum][1] *= (bpmem.texcoords[coordNum].t.scale_minus_1 + 1);

View File

@ -29,6 +29,7 @@ class VideoBackend : public VideoBackendLLE
u32 Video_AccessEFB(EFBAccessType, u32, u32, u32);
void Video_AddMessage(const char* pstr, unsigned int milliseconds);
void Video_ClearMessages();
bool Video_Screenshot(const char* filename);
void Video_SetRendering(bool bEnabled);

View File

@ -22,10 +22,10 @@
#define _connect_macro_(b, f, c, s) (b)->Connect(wxID_ANY, (c), wxCommandEventHandler( f ), (wxObject*)0, (wxEvtHandler*)s)
// template instantiation
template class BoolSetting<wxCheckBox>;
template class _BoolSetting<wxCheckBox>;
template <>
SettingCheckBox::BoolSetting(wxWindow* parent, const wxString& label, bool &setting, bool reverse, long style) :
SettingCheckBox::_BoolSetting(wxWindow* parent, const wxString& label, bool &setting, bool reverse, long style) :
wxCheckBox(parent, -1, label, wxDefaultPosition, wxDefaultSize, style),
m_setting(setting),
m_reverse(reverse)

View File

@ -34,10 +34,10 @@
#include <wx/spinctrl.h>
template <typename W>
class BoolSetting : public W
class _BoolSetting : public W
{
public:
BoolSetting(wxWindow* parent, const wxString& label, bool &setting, bool reverse = false, long style = 0);
_BoolSetting(wxWindow* parent, const wxString& label, bool &setting, bool reverse = false, long style = 0);
void UpdateValue(wxCommandEvent& ev)
{
@ -64,7 +64,7 @@ private:
T& m_setting;
};
typedef BoolSetting<wxCheckBox> SettingCheckBox;
typedef _BoolSetting<wxCheckBox> SettingCheckBox;
typedef IntegerSetting<u32> U32Setting;
class VideoConfigDialog : public wxDialog

View File

@ -24,8 +24,8 @@
#include <wx/aboutdlg.h>
#include "ConfigManager.h"
#include "VideoBackend.h"
#include "SWVideoConfig.h"
#include "main.h"
#include "Win32.h"
#include "StringUtil.h"

View File

@ -22,11 +22,11 @@
#include "Clipper.h"
#include "HW/Memmap.h"
XFRegisters xfregs;
XFRegisters swxfregs;
void InitXFMemory()
{
memset(&xfregs, 0, sizeof(xfregs));
memset(&swxfregs, 0, sizeof(swxfregs));
}
void XFWritten(u32 transferSize, u32 baseAddress)
@ -39,7 +39,7 @@ void XFWritten(u32 transferSize, u32 baseAddress)
// fix lights so invalid values don't trash the lighting computations
if (baseAddress <= 0x067f && topAddress >= 0x0604)
{
u32* x = xfregs.lights;
u32* x = swxfregs.lights;
// go through all lights
for (int light = 0; light < 8; light++)
@ -61,7 +61,7 @@ void XFWritten(u32 transferSize, u32 baseAddress)
}
}
void LoadXFReg(u32 transferSize, u32 baseAddress, u32 *pData)
void SWLoadXFReg(u32 transferSize, u32 baseAddress, u32 *pData)
{
u32 size = transferSize;
@ -77,13 +77,13 @@ void LoadXFReg(u32 transferSize, u32 baseAddress, u32 *pData)
}
if (size > 0) {
memcpy_gc( &((u32*)&xfregs)[baseAddress], pData, size * 4);
memcpy_gc( &((u32*)&swxfregs)[baseAddress], pData, size * 4);
XFWritten(transferSize, baseAddress);
}
}
void LoadIndexedXF(u32 val, int array)
void SWLoadIndexedXF(u32 val, int array)
{
int index = val >> 16;
int address = val & 0xFFF; //check mask
@ -97,5 +97,5 @@ void LoadIndexedXF(u32 val, int array)
for (int i = 0; i < size; ++i)
buffer[i] = Common::swap32(*(pData + i));
LoadXFReg(size, address, buffer);
SWLoadXFReg(size, address, buffer);
}

View File

@ -236,14 +236,14 @@ struct XFRegisters
#define XFMEM_LIGHTS_END 0x680
extern XFRegisters xfregs;
extern XFRegisters swxfregs;
void InitXFMemory();
void XFWritten(u32 transferSize, u32 baseAddress);
void LoadXFReg(u32 transferSize, u32 baseAddress, u32 *pData);
void SWLoadXFReg(u32 transferSize, u32 baseAddress, u32 *pData);
void LoadIndexedXF(u32 val, int array);
void SWLoadIndexedXF(u32 val, int array);
#endif

View File

@ -1,23 +0,0 @@
// Copyright (C) 2003-2009 Dolphin Project.
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU General Public License as published by
// the Free Software Foundation, version 2.0.
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License 2.0 for more details.
// A copy of the GPL 2.0 should have been included with the program.
// If not, see http://www.gnu.org/licenses/
// Official SVN repository and contact information can be found at
// http://code.google.com/p/dolphin-emu/
#ifndef MAIN_H
#define MAIN_H
#include "VideoBackend.h"
#endif