mirror of https://github.com/PCSX2/pcsx2.git
pcsx2-tas: Adjust TAS code to be properly disabled with macro.
VS complains about errors so isolate the code in each file for TAS with macros. Remove ifndef for m_capturingVideo as it is used for video capture menu.
This commit is contained in:
parent
5afa0e6d20
commit
62dd5d980d
|
@ -28,20 +28,23 @@
|
|||
#include <vector>
|
||||
|
||||
|
||||
InputRecording g_InputRecording;
|
||||
|
||||
// Tag and save framecount along with savestate
|
||||
void SaveStateBase::InputRecordingFreeze()
|
||||
{
|
||||
FreezeTag("InputRecording");
|
||||
Freeze(g_FrameCount);
|
||||
|
||||
#ifndef DISABLE_RECORDING
|
||||
if (g_FrameCount > 0 && IsLoading())
|
||||
{
|
||||
g_InputRecordingData.AddUndoCount();
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
#ifndef DISABLE_RECORDING
|
||||
InputRecording g_InputRecording;
|
||||
|
||||
// Main func for handling controller input data
|
||||
// - Called by Sio.cpp::sioWriteController
|
||||
void InputRecording::ControllerInterrupt(u8 &data, u8 &port, u16 & bufCount, u8 buf[])
|
||||
|
@ -231,3 +234,4 @@ bool InputRecording::IsInterruptFrame()
|
|||
{
|
||||
return fInterruptFrame;
|
||||
}
|
||||
#endif
|
||||
|
|
|
@ -18,6 +18,7 @@
|
|||
#include "InputRecordingFile.h"
|
||||
|
||||
|
||||
#ifndef DISABLE_RECORDING
|
||||
enum INPUT_RECORDING_MODE
|
||||
{
|
||||
INPUT_RECORDING_MODE_NONE,
|
||||
|
@ -52,3 +53,4 @@ private:
|
|||
extern InputRecording g_InputRecording;
|
||||
static InputRecordingFile& g_InputRecordingData = g_InputRecording.GetInputRecordingData();
|
||||
static InputRecordingHeader& g_InputRecordingHeader = g_InputRecording.GetInputRecordingData().GetHeader();
|
||||
#endif
|
||||
|
|
|
@ -23,6 +23,7 @@
|
|||
|
||||
#include "InputRecordingFile.h"
|
||||
|
||||
#ifndef DISABLE_RECORDING
|
||||
long InputRecordingFile::GetBlockSeekPoint(const long & frame)
|
||||
{
|
||||
if (savestate.fromSavestate)
|
||||
|
@ -396,3 +397,4 @@ const wxString & InputRecordingFile::GetFilename()
|
|||
{
|
||||
return filename;
|
||||
}
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,7 @@
|
|||
#include "System.h"
|
||||
|
||||
|
||||
#ifndef DISABLE_RECORDING
|
||||
struct InputRecordingHeader
|
||||
{
|
||||
u8 version = 1;
|
||||
|
@ -93,3 +94,4 @@ private:
|
|||
unsigned long MaxFrame = 0;
|
||||
unsigned long UndoCount = 0;
|
||||
};
|
||||
#endif
|
||||
|
|
|
@ -18,6 +18,7 @@
|
|||
#include "NewRecordingFrame.h"
|
||||
|
||||
|
||||
#ifndef DISABLE_RECORDING
|
||||
NewRecordingFrame::NewRecordingFrame(wxWindow *parent)
|
||||
: wxDialog(parent, wxID_ANY, "New Input Recording", wxDefaultPosition, wxDefaultSize, wxSTAY_ON_TOP | wxCAPTION)
|
||||
{
|
||||
|
@ -73,3 +74,4 @@ int NewRecordingFrame::GetFrom() const
|
|||
{
|
||||
return m_fromChoice->GetSelection();
|
||||
}
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,7 @@
|
|||
#include <wx/filepicker.h>
|
||||
|
||||
|
||||
#ifndef DISABLE_RECORDING
|
||||
enum MenuIds_New_Recording_Frame
|
||||
{
|
||||
MenuIds_New_Recording_Frame_File = 0,
|
||||
|
@ -46,3 +47,4 @@ private:
|
|||
wxButton *m_startRecording;
|
||||
wxButton *m_cancelRecording;
|
||||
};
|
||||
#endif
|
||||
|
|
|
@ -20,6 +20,7 @@
|
|||
#include "PadData.h"
|
||||
|
||||
|
||||
#ifndef DISABLE_RECORDING
|
||||
PadData::PadData()
|
||||
{
|
||||
// TODO - multi-tap support eventually?
|
||||
|
@ -330,3 +331,4 @@ int PadData::GetAnalogVectorByte(PadData_AnalogVector vector) const
|
|||
return -1;
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,7 @@
|
|||
#include <vector>
|
||||
|
||||
|
||||
#ifndef DISABLE_RECORDING
|
||||
static const int PadDataNormalButtonCount = 16;
|
||||
enum PadData_NormalButton
|
||||
{
|
||||
|
@ -85,3 +86,4 @@ private:
|
|||
int GetAnalogVector(int port, PadData_AnalogVector vector) const;
|
||||
int GetAnalogVectorByte(PadData_AnalogVector vector) const;
|
||||
};
|
||||
#endif
|
||||
|
|
|
@ -23,6 +23,7 @@
|
|||
#include "RecordingControls.h"
|
||||
|
||||
|
||||
#ifndef DISABLE_RECORDING
|
||||
RecordingControls g_RecordingControls;
|
||||
|
||||
//-----------------------------------------------
|
||||
|
@ -115,3 +116,4 @@ void RecordingControls::Unpause()
|
|||
fStart = true;
|
||||
fFrameAdvance = true;
|
||||
}
|
||||
#endif
|
||||
|
|
|
@ -15,6 +15,7 @@
|
|||
|
||||
#pragma once
|
||||
|
||||
#ifndef DISABLE_RECORDING
|
||||
class RecordingControls
|
||||
{
|
||||
public:
|
||||
|
@ -46,3 +47,4 @@ private:
|
|||
};
|
||||
|
||||
extern RecordingControls g_RecordingControls;
|
||||
#endif
|
||||
|
|
|
@ -19,6 +19,7 @@
|
|||
#include "InputRecording.h"
|
||||
|
||||
|
||||
#ifndef DISABLE_RECORDING
|
||||
RecordingInputManager g_RecordingInput;
|
||||
|
||||
RecordingInputManager::RecordingInputManager()
|
||||
|
@ -86,3 +87,4 @@ void RecordingInputManager::SetVirtualPadReading(int port, bool read)
|
|||
{
|
||||
virtualPad[port] = read;
|
||||
}
|
||||
#endif
|
||||
|
|
|
@ -18,6 +18,7 @@
|
|||
#include "PadData.h"
|
||||
|
||||
|
||||
#ifndef DISABLE_RECORDING
|
||||
class RecordingInputManager
|
||||
{
|
||||
public:
|
||||
|
@ -36,3 +37,4 @@ protected:
|
|||
};
|
||||
|
||||
extern RecordingInputManager g_RecordingInput;
|
||||
#endif
|
||||
|
|
|
@ -20,6 +20,7 @@
|
|||
#include "Recording/VirtualPad.h"
|
||||
#include "Recording/RecordingInputManager.h"
|
||||
|
||||
#ifndef DISABLE_RECORDING
|
||||
wxBEGIN_EVENT_TABLE(VirtualPad, wxFrame)
|
||||
EVT_CLOSE(VirtualPad::OnClose)
|
||||
wxEND_EVENT_TABLE()
|
||||
|
@ -398,3 +399,4 @@ void VirtualPad::DoLayout()
|
|||
SetSizer(container);
|
||||
Layout();
|
||||
}
|
||||
#endif
|
||||
|
|
|
@ -21,6 +21,7 @@
|
|||
|
||||
#include "Recording/PadData.h"
|
||||
|
||||
#ifndef DISABLE_RECORDING
|
||||
class VirtualPad : public wxFrame
|
||||
{
|
||||
public:
|
||||
|
@ -90,3 +91,4 @@ private:
|
|||
protected:
|
||||
wxDECLARE_EVENT_TABLE();
|
||||
};
|
||||
#endif
|
||||
|
|
|
@ -130,9 +130,7 @@ protected:
|
|||
|
||||
PerPluginMenuInfo m_PluginMenuPacks[PluginId_Count];
|
||||
|
||||
#ifndef DISABLE_RECORDING
|
||||
bool m_capturingVideo;
|
||||
#endif
|
||||
|
||||
virtual void DispatchEvent( const PluginEventType& plugin_evt );
|
||||
virtual void DispatchEvent( const CoreThreadStatus& status );
|
||||
|
|
Loading…
Reference in New Issue