diff options
| author | degasus <wickmarkus@web.de> | 2014-07-08 14:29:26 +0200 |
|---|---|---|
| committer | degasus <wickmarkus@web.de> | 2014-07-11 16:07:23 +0200 |
| commit | 22e1aa5bb4a159d6d66a321f978917614aa36331 (patch) | |
| tree | 5f1ec329704dd6120cfb5966dba76387ad1bbc2f /Source/Core/VideoBackends | |
| parent | 3ff1c538ee20f59e513640865bab8fb430e70e84 (diff) | |
mark all local functions as static
Diffstat (limited to 'Source/Core/VideoBackends')
16 files changed, 70 insertions, 70 deletions
diff --git a/Source/Core/VideoBackends/OGL/GLExtensions/GLExtensions.cpp b/Source/Core/VideoBackends/OGL/GLExtensions/GLExtensions.cpp index d7ba6292c9..5a62de6e65 100644 --- a/Source/Core/VideoBackends/OGL/GLExtensions/GLExtensions.cpp +++ b/Source/Core/VideoBackends/OGL/GLExtensions/GLExtensions.cpp @@ -1583,7 +1583,7 @@ namespace GLExtensions bool InitFunctionPointers(); // Initializes the extension list the old way - void InitExtensionList21() + static void InitExtensionList21() { const char* extensions = (const char*)glGetString(GL_EXTENSIONS); std::string tmp(extensions); @@ -1593,7 +1593,7 @@ namespace GLExtensions m_extension_list[tmp] = true; } - void InitExtensionList() + static void InitExtensionList() { m_extension_list.clear(); if (_isES3) @@ -1730,7 +1730,7 @@ namespace GLExtensions for (GLint i = 0; i < NumExtension; ++i) m_extension_list[std::string((const char*)glGetStringi(GL_EXTENSIONS, i))] = true; } - void InitVersion() + static void InitVersion() { GLint major, minor; glGetIntegerv(GL_MAJOR_VERSION, &major); @@ -1743,7 +1743,7 @@ namespace GLExtensions _GLVersion = 330; // Get all the fun things } - void* GetFuncAddress(std::string name, void **func) + static void* GetFuncAddress(std::string name, void **func) { *func = GLInterface->GetFuncAddress(name); if (*func == nullptr) @@ -1792,7 +1792,7 @@ namespace GLExtensions } // Private initialization functions - bool HasFeatures(const std::string& extensions) + static bool HasFeatures(const std::string& extensions) { bool result = true; std::string tmp; diff --git a/Source/Core/VideoBackends/OGL/ProgramShaderCache.cpp b/Source/Core/VideoBackends/OGL/ProgramShaderCache.cpp index c4c8f7c888..cafa560485 100644 --- a/Source/Core/VideoBackends/OGL/ProgramShaderCache.cpp +++ b/Source/Core/VideoBackends/OGL/ProgramShaderCache.cpp @@ -39,7 +39,7 @@ UidChecker<VertexShaderUid,VertexShaderCode> ProgramShaderCache::vertex_uid_chec static char s_glsl_header[1024] = ""; -std::string GetGLSLVersionString() +static std::string GetGLSLVersionString() { GLSL_VERSION v = g_ogl_config.eSupportedGLSLVersion; switch(v) diff --git a/Source/Core/VideoBackends/OGL/Render.cpp b/Source/Core/VideoBackends/OGL/Render.cpp index f2567c0c8b..5cdc8d031f 100644 --- a/Source/Core/VideoBackends/OGL/Render.cpp +++ b/Source/Core/VideoBackends/OGL/Render.cpp @@ -112,7 +112,7 @@ static bool s_efbCacheValid[2][EFB_CACHE_WIDTH * EFB_CACHE_HEIGHT]; static bool s_efbCacheIsCleared = false; static std::vector<u32> s_efbCache[2][EFB_CACHE_WIDTH * EFB_CACHE_HEIGHT]; // 2 for PEEK_Z and PEEK_COLOR -int GetNumMSAASamples(int MSAAMode) +static int GetNumMSAASamples(int MSAAMode) { int samples; switch (MSAAMode) @@ -145,7 +145,7 @@ int GetNumMSAASamples(int MSAAMode) return g_ogl_config.max_samples; } -void ApplySSAASettings() { +static void ApplySSAASettings() { // GLES3 doesn't support SSAA if (GLInterface->GetMode() == GLInterfaceMode::MODE_OPENGL) { @@ -163,7 +163,7 @@ void ApplySSAASettings() { } } -void GLAPIENTRY ErrorCallback( GLenum source, GLenum type, GLuint id, GLenum severity, GLsizei length, const char* message, const void* userParam) +static void GLAPIENTRY ErrorCallback( GLenum source, GLenum type, GLuint id, GLenum severity, GLsizei length, const char* message, const void* userParam) { const char *s_source; const char *s_type; @@ -198,16 +198,16 @@ void GLAPIENTRY ErrorCallback( GLenum source, GLenum type, GLuint id, GLenum sev } // Two small Fallbacks to avoid GL_ARB_ES2_compatibility -void GLAPIENTRY DepthRangef(GLfloat neardepth, GLfloat fardepth) +static void GLAPIENTRY DepthRangef(GLfloat neardepth, GLfloat fardepth) { glDepthRange(neardepth, fardepth); } -void GLAPIENTRY ClearDepthf(GLfloat depthval) +static void GLAPIENTRY ClearDepthf(GLfloat depthval) { glClearDepth(depthval); } -void InitDriverInfo() +static void InitDriverInfo() { std::string svendor = std::string(g_ogl_config.gl_vendor); std::string srenderer = std::string(g_ogl_config.gl_renderer); @@ -1299,7 +1299,7 @@ void Renderer::SetBlendMode(bool forceUpdate) s_blendMode = newval; } -void DumpFrame(const std::vector<u8>& data, int w, int h) +static void DumpFrame(const std::vector<u8>& data, int w, int h) { #if defined(HAVE_LIBAV) || defined(_WIN32) if (g_ActiveConfig.bDumpFrames && !data.empty()) diff --git a/Source/Core/VideoBackends/OGL/main.cpp b/Source/Core/VideoBackends/OGL/main.cpp index c4db8d94e9..fb4079a9c8 100644 --- a/Source/Core/VideoBackends/OGL/main.cpp +++ b/Source/Core/VideoBackends/OGL/main.cpp @@ -103,7 +103,7 @@ std::string VideoBackend::GetDisplayName() const return "OpenGL"; } -void GetShaders(std::vector<std::string> &shaders) +static void GetShaders(std::vector<std::string> &shaders) { std::set<std::string> already_found; @@ -138,7 +138,7 @@ void GetShaders(std::vector<std::string> &shaders) std::sort(shaders.begin(), shaders.end()); } -void InitBackendInfo() +static void InitBackendInfo() { g_Config.backend_info.APIType = API_OPENGL; g_Config.backend_info.bUseRGBATextures = true; diff --git a/Source/Core/VideoBackends/Software/Clipper.cpp b/Source/Core/VideoBackends/Software/Clipper.cpp index 9cd41958c7..4bdbe85230 100644 --- a/Source/Core/VideoBackends/Software/Clipper.cpp +++ b/Source/Core/VideoBackends/Software/Clipper.cpp @@ -169,7 +169,7 @@ namespace Clipper } \ } - void ClipTriangle(int *indices, int &numIndices) + static void ClipTriangle(int *indices, int &numIndices) { int mask = 0; @@ -218,7 +218,7 @@ namespace Clipper } } - void ClipLine(int *indices) + static void ClipLine(int *indices) { int mask = 0; int clip_mask[2] = { 0, 0 }; @@ -310,7 +310,7 @@ namespace Clipper } } - void CopyVertex(OutputVertexData *dst, OutputVertexData *src, float dx, float dy, unsigned int sOffset) + static void CopyVertex(OutputVertexData *dst, OutputVertexData *src, float dx, float dy, unsigned int sOffset) { dst->screenPosition.x = src->screenPosition.x + dx; dst->screenPosition.y = src->screenPosition.y + dy; diff --git a/Source/Core/VideoBackends/Software/DebugUtil.cpp b/Source/Core/VideoBackends/Software/DebugUtil.cpp index 8157567268..bd59779e86 100644 --- a/Source/Core/VideoBackends/Software/DebugUtil.cpp +++ b/Source/Core/VideoBackends/Software/DebugUtil.cpp @@ -51,7 +51,7 @@ void Shutdown() } } -void SaveTexture(const std::string& filename, u32 texmap, s32 mip) +static void SaveTexture(const std::string& filename, u32 texmap, s32 mip) { FourTexUnits& texUnit = bpmem.tex[(texmap >> 2) & 1]; u8 subTexmap = texmap & 3; @@ -82,7 +82,7 @@ void GetTextureRGBA(u8 *dst, u32 texmap, s32 mip, u32 width, u32 height) } } -s32 GetMaxTextureLod(u32 texmap) +static s32 GetMaxTextureLod(u32 texmap) { FourTexUnits& texUnit = bpmem.tex[(texmap >> 2) & 1]; u8 subTexmap = texmap & 3; @@ -130,7 +130,7 @@ void DumpActiveTextures() } } -void DumpEfb(const std::string& filename) +static void DumpEfb(const std::string& filename) { u8 *data = new u8[EFB_WIDTH * EFB_HEIGHT * 4]; u8 *writePtr = data; @@ -153,7 +153,7 @@ void DumpEfb(const std::string& filename) delete[] data; } -void DumpDepth(const std::string& filename) +static void DumpDepth(const std::string& filename) { u8 *data = new u8[EFB_WIDTH * EFB_HEIGHT * 4]; u8 *writePtr = data; diff --git a/Source/Core/VideoBackends/Software/EfbCopy.cpp b/Source/Core/VideoBackends/Software/EfbCopy.cpp index 6018e2b3ce..9629670a3f 100644 --- a/Source/Core/VideoBackends/Software/EfbCopy.cpp +++ b/Source/Core/VideoBackends/Software/EfbCopy.cpp @@ -25,7 +25,7 @@ static const float s_gammaLUT[] = namespace EfbCopy { - void CopyToXfb(u32 xfbAddr, u32 fbWidth, u32 fbHeight, const EFBRectangle& sourceRc, float Gamma) + static void CopyToXfb(u32 xfbAddr, u32 fbWidth, u32 fbHeight, const EFBRectangle& sourceRc, float Gamma) { GLInterface->Update(); // update the render window position and the backbuffer size @@ -61,7 +61,7 @@ namespace EfbCopy } } - void CopyToRam() + static void CopyToRam() { if (!g_SWVideoConfig.bHwRasterizer) { @@ -71,7 +71,7 @@ namespace EfbCopy } } - void ClearEfb() + static void ClearEfb() { u32 clearColor = (bpmem.clearcolorAR & 0xff) << 24 | bpmem.clearcolorGB << 8 | (bpmem.clearcolorAR & 0xff00) >> 8; diff --git a/Source/Core/VideoBackends/Software/EfbInterface.cpp b/Source/Core/VideoBackends/Software/EfbInterface.cpp index 8187345d89..fd985f8662 100644 --- a/Source/Core/VideoBackends/Software/EfbInterface.cpp +++ b/Source/Core/VideoBackends/Software/EfbInterface.cpp @@ -35,7 +35,7 @@ namespace EfbInterface p.DoArray(efb, EFB_WIDTH*EFB_HEIGHT*6); } - void SetPixelAlphaOnly(u32 offset, u8 a) + static void SetPixelAlphaOnly(u32 offset, u8 a) { switch (bpmem.zcontrol.pixel_format) { @@ -58,7 +58,7 @@ namespace EfbInterface } } - void SetPixelColorOnly(u32 offset, u8 *rgb) + static void SetPixelColorOnly(u32 offset, u8 *rgb) { switch (bpmem.zcontrol.pixel_format) { @@ -98,7 +98,7 @@ namespace EfbInterface } } - void SetPixelAlphaColor(u32 offset, u8 *color) + static void SetPixelAlphaColor(u32 offset, u8 *color) { switch (bpmem.zcontrol.pixel_format) { @@ -139,7 +139,7 @@ namespace EfbInterface } } - void GetPixelColor(u32 offset, u8 *color) + static void GetPixelColor(u32 offset, u8 *color) { switch (bpmem.zcontrol.pixel_format) { @@ -175,7 +175,7 @@ namespace EfbInterface } } - void SetPixelDepth(u32 offset, u32 depth) + static void SetPixelDepth(u32 offset, u32 depth) { switch (bpmem.zcontrol.pixel_format) { @@ -203,7 +203,7 @@ namespace EfbInterface } } - u32 GetPixelDepth(u32 offset) + static u32 GetPixelDepth(u32 offset) { u32 depth = 0; @@ -229,7 +229,7 @@ namespace EfbInterface return depth; } - u32 GetSourceFactor(u8 *srcClr, u8 *dstClr, BlendMode::BlendFactor mode) + static u32 GetSourceFactor(u8 *srcClr, u8 *dstClr, BlendMode::BlendFactor mode) { switch (mode) { @@ -270,7 +270,7 @@ namespace EfbInterface return 0; } - u32 GetDestinationFactor(u8 *srcClr, u8 *dstClr, BlendMode::BlendFactor mode) + static u32 GetDestinationFactor(u8 *srcClr, u8 *dstClr, BlendMode::BlendFactor mode) { switch (mode) { @@ -311,7 +311,7 @@ namespace EfbInterface return 0; } - void BlendColor(u8 *srcClr, u8 *dstClr) + static void BlendColor(u8 *srcClr, u8 *dstClr) { u32 srcFactor = GetSourceFactor(srcClr, dstClr, bpmem.blendmode.srcfactor); u32 dstFactor = GetDestinationFactor(srcClr, dstClr, bpmem.blendmode.dstfactor); @@ -333,7 +333,7 @@ namespace EfbInterface } } - void LogicBlend(u32 srcClr, u32 &dstClr, BlendMode::LogicOp op) + static void LogicBlend(u32 srcClr, u32 &dstClr, BlendMode::LogicOp op) { switch (op) { @@ -388,7 +388,7 @@ namespace EfbInterface } } - void SubtractBlend(u8 *srcClr, u8 *dstClr) + static void SubtractBlend(u8 *srcClr, u8 *dstClr) { for (int i = 0; i < 4; i++) { diff --git a/Source/Core/VideoBackends/Software/HwRasterizer.cpp b/Source/Core/VideoBackends/Software/HwRasterizer.cpp index 1a85b34263..9515e8d8af 100644 --- a/Source/Core/VideoBackends/Software/HwRasterizer.cpp +++ b/Source/Core/VideoBackends/Software/HwRasterizer.cpp @@ -35,7 +35,7 @@ namespace HwRasterizer // Clear shader static GLint clear_apos = -1, clear_ucol = -1; - void CreateShaders() + static void CreateShaders() { // Color Vertices static const char *fragcolText = @@ -155,7 +155,7 @@ namespace HwRasterizer GL_REPORT_ERRORD(); } static float width, height; - void LoadTexture() + static void LoadTexture() { FourTexUnits &texUnit = bpmem.tex[0]; u32 imageAddr = texUnit.texImage3[0].image_base; @@ -199,7 +199,7 @@ namespace HwRasterizer glDisable(GL_BLEND); } - void DrawColorVertex(OutputVertexData *v0, OutputVertexData *v1, OutputVertexData *v2) + static void DrawColorVertex(OutputVertexData *v0, OutputVertexData *v1, OutputVertexData *v2) { float x0 = (v0->screenPosition.x / efbHalfWidth) - 1.0f; float y0 = 1.0f - (v0->screenPosition.y / efbHalfHeight); @@ -249,7 +249,7 @@ namespace HwRasterizer GL_REPORT_ERRORD(); } - void DrawTextureVertex(OutputVertexData *v0, OutputVertexData *v1, OutputVertexData *v2) + static void DrawTextureVertex(OutputVertexData *v0, OutputVertexData *v1, OutputVertexData *v2) { float x0 = (v0->screenPosition.x / efbHalfWidth) - 1.0f; float y0 = 1.0f - (v0->screenPosition.y / efbHalfHeight); diff --git a/Source/Core/VideoBackends/Software/OpcodeDecoder.cpp b/Source/Core/VideoBackends/Software/OpcodeDecoder.cpp index 52bd632e15..524a960d3e 100644 --- a/Source/Core/VideoBackends/Software/OpcodeDecoder.cpp +++ b/Source/Core/VideoBackends/Software/OpcodeDecoder.cpp @@ -43,7 +43,7 @@ void DoState(PointerWrap &p) ResetDecoding(); } -void DecodePrimitiveStream(u32 iBufferSize) +static void DecodePrimitiveStream(u32 iBufferSize) { u32 vertexSize = vertexLoader.GetVertexSize(); @@ -77,7 +77,7 @@ void DecodePrimitiveStream(u32 iBufferSize) } } -void ReadXFData(u32 iBufferSize) +static void ReadXFData(u32 iBufferSize) { _assert_msg_(VIDEO, iBufferSize >= (u32)(streamSize * 4), "Underflow during standard opcode decoding"); @@ -90,7 +90,7 @@ void ReadXFData(u32 iBufferSize) ResetDecoding(); } -void ExecuteDisplayList(u32 addr, u32 count) +static void ExecuteDisplayList(u32 addr, u32 count) { u8 *videoDataSave = g_pVideoData; @@ -114,7 +114,7 @@ void ExecuteDisplayList(u32 addr, u32 count) g_pVideoData = videoDataSave; } -void DecodeStandard(u32 bufferSize) +static void DecodeStandard(u32 bufferSize) { _assert_msg_(VIDEO, CommandRunnable(bufferSize), "Underflow during standard opcode decoding"); diff --git a/Source/Core/VideoBackends/Software/Rasterizer.cpp b/Source/Core/VideoBackends/Software/Rasterizer.cpp index 915757f766..90fe84ffee 100644 --- a/Source/Core/VideoBackends/Software/Rasterizer.cpp +++ b/Source/Core/VideoBackends/Software/Rasterizer.cpp @@ -183,7 +183,7 @@ inline void Draw(s32 x, s32 y, s32 xi, s32 yi) tev.Draw(); } -void InitTriangle(float X1, float Y1, s32 xi, s32 yi) +static void InitTriangle(float X1, float Y1, s32 xi, s32 yi) { vertex0X = xi; vertex0Y = yi; @@ -195,7 +195,7 @@ void InitTriangle(float X1, float Y1, s32 xi, s32 yi) vertexOffsetY = ((float)yi - Y1) + adjust; } -void InitSlope(Slope *slope, float f1, float f2, float f3, float DX31, float DX12, float DY12, float DY31) +static void InitSlope(Slope *slope, float f1, float f2, float f3, float DX31, float DX12, float DY12, float DY31) { float DF31 = f3 - f1; float DF21 = f2 - f1; @@ -253,7 +253,7 @@ inline void CalculateLOD(s32 &lod, bool &linear, u32 texmap, u32 texcoord) lod = CLAMP(lod, (s32)tm1.min_lod, (s32)tm1.max_lod); } -void BuildBlock(s32 blockX, s32 blockY) +static void BuildBlock(s32 blockX, s32 blockY) { for (s32 yi = 0; yi < BLOCK_SIZE; yi++) { diff --git a/Source/Core/VideoBackends/Software/SWCommandProcessor.cpp b/Source/Core/VideoBackends/Software/SWCommandProcessor.cpp index d310a5584d..ed8115f1ab 100644 --- a/Source/Core/VideoBackends/Software/SWCommandProcessor.cpp +++ b/Source/Core/VideoBackends/Software/SWCommandProcessor.cpp @@ -66,7 +66,7 @@ inline u16 ReadLow (u32 _reg) {return (u16)(_reg & 0xFFFF);} inline u16 ReadHigh (u32 _reg) {return (u16)(_reg >> 16);} -void UpdateInterrupts_Wrapper(u64 userdata, int cyclesLate) +static void UpdateInterrupts_Wrapper(u64 userdata, int cyclesLate) { UpdateInterrupts(userdata); } @@ -219,7 +219,7 @@ void UpdateInterruptsFromVideoBackend(u64 userdata) CoreTiming::ScheduleEvent_Threadsafe(0, et_UpdateInterrupts, userdata); } -void ReadFifo() +static void ReadFifo() { bool canRead = cpreg.readptr != cpreg.writeptr && writePos < (int)maxCommandBufferWrite; bool atBreakpoint = AtBreakpoint(); @@ -256,7 +256,7 @@ void ReadFifo() } } -void SetStatus() +static void SetStatus() { // overflow check if (cpreg.rwdistance > cpreg.hiwatermark) diff --git a/Source/Core/VideoBackends/Software/SWRenderer.cpp b/Source/Core/VideoBackends/Software/SWRenderer.cpp index ef6c491449..5bd44782a7 100644 --- a/Source/Core/VideoBackends/Software/SWRenderer.cpp +++ b/Source/Core/VideoBackends/Software/SWRenderer.cpp @@ -52,7 +52,7 @@ void SWRenderer::Shutdown() } } -void CreateShaders() +static void CreateShaders() { static const char *fragShaderText = "#ifdef GL_ES\n" diff --git a/Source/Core/VideoBackends/Software/SWmain.cpp b/Source/Core/VideoBackends/Software/SWmain.cpp index 6fe4cf4dcb..8abfa81c65 100644 --- a/Source/Core/VideoBackends/Software/SWmain.cpp +++ b/Source/Core/VideoBackends/Software/SWmain.cpp @@ -62,7 +62,7 @@ std::string VideoSoftware::GetName() const return _trans("Software Renderer"); } -void *DllDebugger(void *_hParent, bool Show) +static void *DllDebugger(void *_hParent, bool Show) { return nullptr; } diff --git a/Source/Core/VideoBackends/Software/TextureEncoder.cpp b/Source/Core/VideoBackends/Software/TextureEncoder.cpp index 5913125a08..8351d39a29 100644 --- a/Source/Core/VideoBackends/Software/TextureEncoder.cpp +++ b/Source/Core/VideoBackends/Software/TextureEncoder.cpp @@ -196,7 +196,7 @@ inline void boxfilterRGB_to_xx8(u8 *src, u8 &x1, u8 &x2, int comp1, int comp2) x2 = x16_2 >> 2; } -void SetBlockDimensions(int blkWidthLog2, int blkHeightLog2, u16 &sBlkCount, u16 &tBlkCount, u16 &sBlkSize, u16 &tBlkSize) +static void SetBlockDimensions(int blkWidthLog2, int blkHeightLog2, u16 &sBlkCount, u16 &tBlkCount, u16 &sBlkSize, u16 &tBlkSize) { // if half_scale is 1 then the size is cut in half u32 width = bpmem.copyTexSrcWH.x >> bpmem.triggerEFBCopy.half_scale; @@ -209,7 +209,7 @@ void SetBlockDimensions(int blkWidthLog2, int blkHeightLog2, u16 &sBlkCount, u16 tBlkSize = 1 << blkHeightLog2; } -void SetSpans(int sBlkSize, int tBlkSize, s32 &tSpan, s32 &sBlkSpan, s32 &tBlkSpan, s32 &writeStride) +static void SetSpans(int sBlkSize, int tBlkSize, s32 &tSpan, s32 &sBlkSpan, s32 &tBlkSpan, s32 &writeStride) { // width is 1 less than the number of pixels of width u32 width = bpmem.copyTexSrcWH.x >> bpmem.triggerEFBCopy.half_scale; @@ -253,7 +253,7 @@ void SetSpans(int sBlkSize, int tBlkSize, s32 &tSpan, s32 &sBlkSpan, s32 &tBlkSp dstBlockStart += writeStride; \ } \ -void EncodeRGBA6(u8 *dst, u8 *src, u32 format) +static void EncodeRGBA6(u8 *dst, u8 *src, u32 format) { u16 sBlkCount, tBlkCount, sBlkSize, tBlkSize; s32 tSpan, sBlkSpan, tBlkSpan, writeStride; @@ -490,7 +490,7 @@ void EncodeRGBA6(u8 *dst, u8 *src, u32 format) } -void EncodeRGBA6halfscale(u8 *dst, u8 *src, u32 format) +static void EncodeRGBA6halfscale(u8 *dst, u8 *src, u32 format) { u16 sBlkCount, tBlkCount, sBlkSize, tBlkSize; s32 tSpan, sBlkSpan, tBlkSpan, writeStride; @@ -725,7 +725,7 @@ void EncodeRGBA6halfscale(u8 *dst, u8 *src, u32 format) } } -void EncodeRGB8(u8 *dst, u8 *src, u32 format) +static void EncodeRGB8(u8 *dst, u8 *src, u32 format) { u16 sBlkCount, tBlkCount, sBlkSize, tBlkSize; s32 tSpan, sBlkSpan, tBlkSpan, writeStride; @@ -939,7 +939,7 @@ void EncodeRGB8(u8 *dst, u8 *src, u32 format) } } -void EncodeRGB8halfscale(u8 *dst, u8 *src, u32 format) +static void EncodeRGB8halfscale(u8 *dst, u8 *src, u32 format) { u16 sBlkCount, tBlkCount, sBlkSize, tBlkSize; s32 tSpan, sBlkSpan, tBlkSpan, writeStride; @@ -1170,7 +1170,7 @@ void EncodeRGB8halfscale(u8 *dst, u8 *src, u32 format) } } -void EncodeZ24(u8 *dst, u8 *src, u32 format) +static void EncodeZ24(u8 *dst, u8 *src, u32 format) { u16 sBlkCount, tBlkCount, sBlkSize, tBlkSize; s32 tSpan, sBlkSpan, tBlkSpan, writeStride; @@ -1274,7 +1274,7 @@ void EncodeZ24(u8 *dst, u8 *src, u32 format) } } -void EncodeZ24halfscale(u8 *dst, u8 *src, u32 format) +static void EncodeZ24halfscale(u8 *dst, u8 *src, u32 format) { u16 sBlkCount, tBlkCount, sBlkSize, tBlkSize; s32 tSpan, sBlkSpan, tBlkSpan, writeStride; diff --git a/Source/Core/VideoBackends/Software/TransformUnit.cpp b/Source/Core/VideoBackends/Software/TransformUnit.cpp index f79c57be00..e0907d7543 100644 --- a/Source/Core/VideoBackends/Software/TransformUnit.cpp +++ b/Source/Core/VideoBackends/Software/TransformUnit.cpp @@ -19,42 +19,42 @@ namespace TransformUnit { -void MultiplyVec2Mat24(const Vec3 &vec, const float *mat, Vec3 &result) +static void MultiplyVec2Mat24(const Vec3 &vec, const float *mat, Vec3 &result) { result.x = mat[0] * vec.x + mat[1] * vec.y + mat[2] + mat[3]; result.y = mat[4] * vec.x + mat[5] * vec.y + mat[6] + mat[7]; result.z = 1.0f; } -void MultiplyVec2Mat34(const Vec3 &vec, const float *mat, Vec3 &result) +static void MultiplyVec2Mat34(const Vec3 &vec, const float *mat, Vec3 &result) { result.x = mat[0] * vec.x + mat[1] * vec.y + mat[2] + mat[3]; result.y = mat[4] * vec.x + mat[5] * vec.y + mat[6] + mat[7]; result.z = mat[8] * vec.x + mat[9] * vec.y + mat[10] + mat[11]; } -void MultiplyVec3Mat33(const Vec3 &vec, const float *mat, Vec3 &result) +static void MultiplyVec3Mat33(const Vec3 &vec, const float *mat, Vec3 &result) { result.x = mat[0] * vec.x + mat[1] * vec.y + mat[2] * vec.z; result.y = mat[3] * vec.x + mat[4] * vec.y + mat[5] * vec.z; result.z = mat[6] * vec.x + mat[7] * vec.y + mat[8] * vec.z; } -void MultiplyVec3Mat24(const Vec3 &vec, const float *mat, Vec3 &result) +static void MultiplyVec3Mat24(const Vec3 &vec, const float *mat, Vec3 &result) { result.x = mat[0] * vec.x + mat[1] * vec.y + mat[2] * vec.z + mat[3]; result.y = mat[4] * vec.x + mat[5] * vec.y + mat[6] * vec.z + mat[7]; result.z = 1.0f; } -void MultiplyVec3Mat34(const Vec3 &vec, const float *mat, Vec3 &result) +static void MultiplyVec3Mat34(const Vec3 &vec, const float *mat, Vec3 &result) { result.x = mat[0] * vec.x + mat[1] * vec.y + mat[2] * vec.z + mat[3]; result.y = mat[4] * vec.x + mat[5] * vec.y + mat[6] * vec.z + mat[7]; result.z = mat[8] * vec.x + mat[9] * vec.y + mat[10] * vec.z + mat[11]; } -void MultipleVec3Perspective(const Vec3 &vec, const float *proj, Vec4 &result) +static void MultipleVec3Perspective(const Vec3 &vec, const float *proj, Vec4 &result) { result.x = proj[0] * vec.x + proj[1] * vec.z; result.y = proj[2] * vec.y + proj[3] * vec.z; @@ -63,7 +63,7 @@ void MultipleVec3Perspective(const Vec3 &vec, const float *proj, Vec4 &result) result.w = -vec.z; } -void MultipleVec3Ortho(const Vec3 &vec, const float *proj, Vec4 &result) +static void MultipleVec3Ortho(const Vec3 &vec, const float *proj, Vec4 &result) { result.x = proj[0] * vec.x + proj[1]; result.y = proj[2] * vec.y + proj[3]; @@ -104,7 +104,7 @@ void TransformNormal(const InputVertexData *src, bool nbt, OutputVertexData *dst } } -void TransformTexCoordRegular(const TexMtxInfo &texinfo, int coordNum, bool specialCase, const InputVertexData *srcVertex, OutputVertexData *dstVertex) +static void TransformTexCoordRegular(const TexMtxInfo &texinfo, int coordNum, bool specialCase, const InputVertexData *srcVertex, OutputVertexData *dstVertex) { const Vec3 *src; switch (texinfo.sourcerow) @@ -208,7 +208,7 @@ inline float SafeDivide(float n, float d) return (d==0) ? (n>0?1:0) : n/d; } -void LightColor(const Vec3 &pos, const Vec3 &normal, u8 lightNum, const LitChannel &chan, Vec3 &lightCol) +static void LightColor(const Vec3 &pos, const Vec3 &normal, u8 lightNum, const LitChannel &chan, Vec3 &lightCol) { const LightPointer *light = (const LightPointer*)&xfmem.lights[lightNum]; @@ -293,7 +293,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) +static void LightAlpha(const Vec3 &pos, const Vec3 &normal, u8 lightNum, const LitChannel &chan, float &lightCol) { const LightPointer *light = (const LightPointer*)&xfmem.lights[lightNum]; |
