Replaced type "BYTE" by "u8", except where "BYTE" is used to access the Windows API.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@408 8ced0084-cf51-0410-be5f-012b33b47a6e
This commit is contained in:
parent
965fd33f16
commit
0bebbcb5f4
|
@ -20,6 +20,8 @@
|
|||
|
||||
#pragma once
|
||||
|
||||
#include "Common.h"
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
// C L A S S/////////////////////////////////////////////////////////////////////////////////////////
|
||||
/////////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
|
@ -48,7 +50,7 @@ public:
|
|||
{
|
||||
if(m_dolheader.textOffset[i] != 0)
|
||||
{
|
||||
BYTE* pTemp = new BYTE[m_dolheader.textSize[i]];
|
||||
u8* pTemp = new u8[m_dolheader.textSize[i]];
|
||||
|
||||
fseek(pStream, m_dolheader.textOffset[i], SEEK_SET);
|
||||
fread(pTemp, 1, m_dolheader.textSize[i], pStream);
|
||||
|
@ -65,7 +67,7 @@ public:
|
|||
{
|
||||
if(m_dolheader.dataOffset[i] != 0)
|
||||
{
|
||||
BYTE* pTemp = new BYTE[m_dolheader.dataSize[i]];
|
||||
u8* pTemp = new u8[m_dolheader.dataSize[i]];
|
||||
|
||||
fseek(pStream, m_dolheader.dataOffset[i], SEEK_SET);
|
||||
fread(pTemp, 1, m_dolheader.dataSize[i], pStream);
|
||||
|
|
|
@ -33,8 +33,8 @@ typedef void (__cdecl* TDllAbout)(HWND);
|
|||
typedef void (__cdecl* TDllConfig)(HWND);
|
||||
typedef void (__cdecl* TPAD_Initialize)(SPADInitialize);
|
||||
typedef void (__cdecl* TPAD_Shutdown)();
|
||||
typedef void (__cdecl* TPAD_GetStatus)(BYTE, SPADStatus*);
|
||||
typedef void (__cdecl* TPAD_Rumble)(BYTE, unsigned int, unsigned int);
|
||||
typedef void (__cdecl* TPAD_GetStatus)(u8, SPADStatus*);
|
||||
typedef void (__cdecl* TPAD_Rumble)(u8, unsigned int, unsigned int);
|
||||
typedef unsigned int (__cdecl* TPAD_GetAttachedPads)();
|
||||
|
||||
// Function Pointers
|
||||
|
|
|
@ -37,8 +37,8 @@ typedef void (__cdecl* TDllConfig)(HWND);
|
|||
typedef void (__cdecl* TVideo_Initialize)(SVideoInitialize*);
|
||||
typedef void (__cdecl* TVideo_Prepare)();
|
||||
typedef void (__cdecl* TVideo_Shutdown)();
|
||||
typedef void (__cdecl* TVideo_SendFifoData)(BYTE*);
|
||||
typedef void (__cdecl* TVideo_UpdateXFB)(BYTE*, DWORD, DWORD);
|
||||
typedef void (__cdecl* TVideo_SendFifoData)(u8*);
|
||||
typedef void (__cdecl* TVideo_UpdateXFB)(u8*, DWORD, DWORD);
|
||||
typedef BOOL (__cdecl* TVideo_Screenshot)(TCHAR*);
|
||||
typedef void (__cdecl* TVideo_EnterLoop)();
|
||||
typedef void (__cdecl* TVideo_AddMessage)(const char* pstr, unsigned int milliseconds);
|
||||
|
|
|
@ -102,7 +102,7 @@ void FAKE_SkipFifo(u32 skip)
|
|||
readptr += skip;
|
||||
}
|
||||
|
||||
void Video_SendFifoData(BYTE *_uData)
|
||||
void Video_SendFifoData(u8* _uData)
|
||||
{
|
||||
memcpy(videoBuffer + size, _uData, 32);
|
||||
size += 32;
|
||||
|
|
|
@ -41,7 +41,6 @@ typedef signed __int64 s64;
|
|||
#else
|
||||
|
||||
typedef unsigned char u8;
|
||||
typedef unsigned char BYTE;
|
||||
typedef unsigned short u16;
|
||||
typedef unsigned int u32;
|
||||
typedef unsigned int BOOL;
|
||||
|
|
|
@ -5,6 +5,8 @@
|
|||
#ifndef _PLUGINS_H_INCLUDED__
|
||||
#define _PLUGINS_H_INCLUDED__
|
||||
|
||||
#include "CommonTypes.h"
|
||||
|
||||
#ifdef _WIN32
|
||||
#define EXPORT __declspec(dllexport)
|
||||
#define CALL __cdecl
|
||||
|
@ -29,14 +31,12 @@
|
|||
// simulate something that looks like win32
|
||||
// long term, kill these
|
||||
|
||||
// glxew defines BOOL and BYTE. evil.
|
||||
// glxew defines BOOL. evil.
|
||||
#ifdef BOOL
|
||||
#undef BOOL
|
||||
#undef BYTE
|
||||
#endif
|
||||
|
||||
#define BOOL unsigned int
|
||||
#define BYTE unsigned char
|
||||
#define WORD unsigned short
|
||||
#define DWORD unsigned int
|
||||
#define HWND void*
|
||||
|
|
|
@ -105,7 +105,7 @@ EXPORT void CALL PAD_Shutdown();
|
|||
// input:
|
||||
// output:
|
||||
//
|
||||
EXPORT void CALL PAD_GetStatus(BYTE _numPAD, SPADStatus* _pPADStatus);
|
||||
EXPORT void CALL PAD_GetStatus(u8 _numPAD, SPADStatus* _pPADStatus);
|
||||
|
||||
// __________________________________________________________________________________________________
|
||||
// Function: PAD_Rumble
|
||||
|
@ -113,7 +113,7 @@ EXPORT void CALL PAD_GetStatus(BYTE _numPAD, SPADStatus* _pPADStatus);
|
|||
// input: PAD number, Command type (Stop=0, Rumble=1, Stop Hard=2) and strength of Rumble
|
||||
// output: none
|
||||
//
|
||||
EXPORT void CALL PAD_Rumble(BYTE _numPAD, unsigned int _uType, unsigned int _uStrength);
|
||||
EXPORT void CALL PAD_Rumble(u8 _numPAD, unsigned int _uType, unsigned int _uStrength);
|
||||
|
||||
// __________________________________________________________________________________________________
|
||||
// Function: PAD_GetAttachedPads
|
||||
|
|
|
@ -132,7 +132,7 @@ EXPORT void CALL Video_Shutdown(void);
|
|||
// input: a data-byte (i know we have to optimize this ;-))
|
||||
// output: none
|
||||
//
|
||||
EXPORT void CALL Video_SendFifoData(BYTE *_uData);
|
||||
EXPORT void CALL Video_SendFifoData(u8* _uData);
|
||||
|
||||
// __________________________________________________________________________________________________
|
||||
// Function: Video_UpdateXFB
|
||||
|
@ -142,7 +142,7 @@ EXPORT void CALL Video_SendFifoData(BYTE *_uData);
|
|||
// input: pointer to the XFB, width and height of the XFB
|
||||
// output: none
|
||||
//
|
||||
EXPORT void CALL Video_UpdateXFB(BYTE* _pXFB, DWORD _dwWidth, DWORD _dwHeight);
|
||||
EXPORT void CALL Video_UpdateXFB(u8* _pXFB, DWORD _dwWidth, DWORD _dwHeight);
|
||||
|
||||
// __________________________________________________________________________________________________
|
||||
// Function: Video_Screenshot
|
||||
|
|
|
@ -124,7 +124,7 @@ void PAD_Shutdown(void)
|
|||
// __________________________________________________________________________________________________
|
||||
// PADGetStatus
|
||||
//
|
||||
void PAD_GetStatus(BYTE _numPAD, SPADStatus* _pPADStatus)
|
||||
void PAD_GetStatus(u8 _numPAD, SPADStatus* _pPADStatus)
|
||||
{
|
||||
// check if all is okay
|
||||
if ((_numPAD != 0) || // we support just pad 0
|
||||
|
@ -187,6 +187,6 @@ void PAD_GetStatus(BYTE _numPAD, SPADStatus* _pPADStatus)
|
|||
// __________________________________________________________________________________________________
|
||||
// PAD_Rumble
|
||||
//
|
||||
void PAD_Rumble(BYTE _numPAD, unsigned int _uType, unsigned int _uStrength)
|
||||
void PAD_Rumble(u8 _numPAD, unsigned int _uType, unsigned int _uStrength)
|
||||
{
|
||||
}
|
||||
|
|
|
@ -521,7 +521,7 @@ unsigned int PAD_GetAttachedPads()
|
|||
connected |= 1;
|
||||
return connected;
|
||||
}
|
||||
void PAD_GetStatus(BYTE _numPAD, SPADStatus* _pPADStatus)
|
||||
void PAD_GetStatus(u8 _numPAD, SPADStatus* _pPADStatus)
|
||||
{
|
||||
// check if all is okay
|
||||
if ((_pPADStatus == NULL))
|
||||
|
@ -568,7 +568,7 @@ void PAD_GetStatus(BYTE _numPAD, SPADStatus* _pPADStatus)
|
|||
|
||||
|
||||
// Rough approximation of GC behaviour - needs improvement.
|
||||
void PAD_Rumble(BYTE _numPAD, unsigned int _uType, unsigned int _uStrength)
|
||||
void PAD_Rumble(u8 _numPAD, unsigned int _uType, unsigned int _uStrength)
|
||||
{
|
||||
#ifdef _WIN32
|
||||
static int a = 0;
|
||||
|
|
|
@ -8,7 +8,7 @@
|
|||
#include "VertexLoader.h"
|
||||
#include "VertexLoader_Normal.h"
|
||||
|
||||
BYTE VertexLoader_Normal::m_sizeTable[NUM_NRM_TYPE][NUM_NRM_FORMAT][NUM_NRM_ELEMENTS];
|
||||
u8 VertexLoader_Normal::m_sizeTable[NUM_NRM_TYPE][NUM_NRM_FORMAT][NUM_NRM_ELEMENTS];
|
||||
TPipelineFunction VertexLoader_Normal::m_funcTable[NUM_NRM_TYPE][NUM_NRM_FORMAT][NUM_NRM_ELEMENTS];
|
||||
|
||||
bool VertexLoader_Normal::index3;
|
||||
|
|
|
@ -4,6 +4,8 @@
|
|||
|
||||
#pragma once
|
||||
|
||||
#include "CommonTypes.h"
|
||||
|
||||
class VertexLoader_Normal
|
||||
{
|
||||
public:
|
||||
|
@ -46,7 +48,7 @@ private:
|
|||
};
|
||||
|
||||
// tables
|
||||
static BYTE m_sizeTable[NUM_NRM_TYPE][NUM_NRM_FORMAT][NUM_NRM_ELEMENTS];
|
||||
static u8 m_sizeTable[NUM_NRM_TYPE][NUM_NRM_FORMAT][NUM_NRM_ELEMENTS];
|
||||
static TPipelineFunction m_funcTable[NUM_NRM_TYPE][NUM_NRM_FORMAT][NUM_NRM_ELEMENTS];
|
||||
|
||||
// direct
|
||||
|
|
|
@ -202,7 +202,7 @@ void Video_Shutdown(void)
|
|||
DeInit();
|
||||
}
|
||||
|
||||
void Video_UpdateXFB(BYTE* /*_pXFB*/, DWORD /*_dwWidth*/, DWORD /*_dwHeight*/)
|
||||
void Video_UpdateXFB(u8* /*_pXFB*/, DWORD /*_dwWidth*/, DWORD /*_dwHeight*/)
|
||||
{
|
||||
/*
|
||||
ConvertXFB(tempBuffer, _pXFB, _dwWidth, _dwHeight);
|
||||
|
|
|
@ -26,7 +26,7 @@
|
|||
#define LOG_NORM16() PRIM_LOG("norm: %f %f %f, ", ((s16*)VertexManager::s_pCurBufferPointer)[-3]/32767.0f, ((s16*)VertexManager::s_pCurBufferPointer)[-2]/32767.0f, ((s16*)VertexManager::s_pCurBufferPointer)[-1]/32767.0f);
|
||||
#define LOG_NORMF() PRIM_LOG("norm: %f %f %f, ", ((float*)VertexManager::s_pCurBufferPointer)[-3], ((float*)VertexManager::s_pCurBufferPointer)[-2], ((float*)VertexManager::s_pCurBufferPointer)[-1]);
|
||||
|
||||
BYTE VertexLoader_Normal::m_sizeTable[NUM_NRM_TYPE][NUM_NRM_FORMAT][NUM_NRM_ELEMENTS];
|
||||
u8 VertexLoader_Normal::m_sizeTable[NUM_NRM_TYPE][NUM_NRM_FORMAT][NUM_NRM_ELEMENTS];
|
||||
TPipelineFunction VertexLoader_Normal::m_funcTable[NUM_NRM_TYPE][NUM_NRM_FORMAT][NUM_NRM_ELEMENTS];
|
||||
|
||||
bool VertexLoader_Normal::index3;
|
||||
|
|
|
@ -18,6 +18,8 @@
|
|||
#ifndef _VERTEXLOADER_NORMAL_H
|
||||
#define _VERTEXLOADER_NORMAL_H
|
||||
|
||||
#include "CommonTypes.h"
|
||||
|
||||
class VertexLoader_Normal
|
||||
{
|
||||
public:
|
||||
|
@ -60,7 +62,7 @@ private:
|
|||
};
|
||||
|
||||
// tables
|
||||
static BYTE m_sizeTable[NUM_NRM_TYPE][NUM_NRM_FORMAT][NUM_NRM_ELEMENTS];
|
||||
static u8 m_sizeTable[NUM_NRM_TYPE][NUM_NRM_FORMAT][NUM_NRM_ELEMENTS];
|
||||
static TPipelineFunction m_funcTable[NUM_NRM_TYPE][NUM_NRM_FORMAT][NUM_NRM_ELEMENTS];
|
||||
|
||||
// direct
|
||||
|
|
|
@ -274,7 +274,7 @@ BOOL Video_Screenshot(TCHAR* _szFilename)
|
|||
}
|
||||
|
||||
|
||||
void Video_UpdateXFB(BYTE* _pXFB, DWORD _dwWidth, DWORD _dwHeight)
|
||||
void Video_UpdateXFB(u8* _pXFB, DWORD _dwWidth, DWORD _dwHeight)
|
||||
{
|
||||
}
|
||||
|
||||
|
|
|
@ -304,7 +304,7 @@ void PAD_Shutdown()
|
|||
|
||||
// Set PAD status
|
||||
// ¯¯¯¯¯¯¯¯¯¯¯¯¯¯
|
||||
void PAD_GetStatus(BYTE _numPAD, SPADStatus* _pPADStatus)
|
||||
void PAD_GetStatus(u8 _numPAD, SPADStatus* _pPADStatus)
|
||||
{
|
||||
if(!joysticks[_numPAD].enabled)
|
||||
return;
|
||||
|
@ -474,7 +474,7 @@ void PAD_GetStatus(BYTE _numPAD, SPADStatus* _pPADStatus)
|
|||
// Set PAD rumble
|
||||
// ¯¯¯¯¯¯¯¯¯¯¯¯¯¯
|
||||
// (Stop=0, Rumble=1)
|
||||
void PAD_Rumble(BYTE _numPAD, unsigned int _uType, unsigned int _uStrength)
|
||||
void PAD_Rumble(u8 _numPAD, unsigned int _uType, unsigned int _uStrength)
|
||||
{
|
||||
//if(_numPAD > 0)
|
||||
// return;
|
||||
|
|
Loading…
Reference in New Issue