dummy timer class
This commit is contained in:
parent
79a6464c58
commit
20c0960cc6
|
@ -34,7 +34,7 @@ add_executable(shadps4
|
|||
src/Core/Memory.h
|
||||
src/Core/PS4/Linker.cpp
|
||||
src/Core/PS4/Linker.h
|
||||
"src/Util/Singleton.h" "src/Util/Disassembler.cpp" "src/Util/Disassembler.h" "src/Util/StringUtil.h" "src/Core/PS4/Util/aerolib.h" "src/Core/PS4/Loader/SymbolsResolver.h" "src/Core/PS4/Loader/SymbolsResolver.cpp" "src/Core/PS4/HLE/Libs.cpp" "src/Core/PS4/HLE/Libs.h" "src/Core/PS4/HLE/LibC.cpp" "src/Core/PS4/HLE/LibC.h")
|
||||
"src/Util/Singleton.h" "src/Util/Disassembler.cpp" "src/Util/Disassembler.h" "src/Util/StringUtil.h" "src/Core/PS4/Util/aerolib.h" "src/Core/PS4/Loader/SymbolsResolver.h" "src/Core/PS4/Loader/SymbolsResolver.cpp" "src/Core/PS4/HLE/Libs.cpp" "src/Core/PS4/HLE/Libs.h" "src/Core/PS4/HLE/LibC.cpp" "src/Core/PS4/HLE/LibC.h" "src/Lib/Timer.cpp" "src/Lib/Timer.h")
|
||||
|
||||
find_package(OpenGL REQUIRED)
|
||||
|
||||
|
|
|
@ -0,0 +1,42 @@
|
|||
#include "Timer.h"
|
||||
|
||||
Lib::Timer::Timer()
|
||||
{
|
||||
}
|
||||
|
||||
void Lib::Timer::Start()
|
||||
{
|
||||
}
|
||||
|
||||
void Lib::Timer::Pause()
|
||||
{
|
||||
}
|
||||
|
||||
void Lib::Timer::Resume()
|
||||
{
|
||||
}
|
||||
|
||||
bool Lib::Timer::IsPaused() const
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
double Lib::Timer::GetTimeMsec() const
|
||||
{
|
||||
return 0.0;
|
||||
}
|
||||
|
||||
double Lib::Timer::GetTimeSec() const
|
||||
{
|
||||
return 0.0;
|
||||
}
|
||||
|
||||
u64 Lib::Timer::GetTicks() const
|
||||
{
|
||||
return u64();
|
||||
}
|
||||
|
||||
u64 Lib::Timer::GetFrequency() const
|
||||
{
|
||||
return u64();
|
||||
}
|
|
@ -0,0 +1,34 @@
|
|||
#pragma once
|
||||
|
||||
#include "../Types.h"
|
||||
|
||||
namespace Lib {
|
||||
class Timer final
|
||||
{
|
||||
public:
|
||||
Timer();
|
||||
~Timer() = default;
|
||||
|
||||
void Start();
|
||||
void Pause();
|
||||
void Resume();
|
||||
bool IsPaused() const;
|
||||
|
||||
double GetTimeMsec() const;// return time in milliseconds
|
||||
double GetTimeSec() const;// return time in seconds
|
||||
u64 GetTicks() const;// return time in ticks
|
||||
u64 GetFrequency() const;// return ticks frequency
|
||||
|
||||
public:
|
||||
Timer(const Timer&) = delete;
|
||||
Timer& operator=(const Timer&) = delete;
|
||||
Timer(Timer&&) = delete;
|
||||
Timer& operator=(Timer&&) = delete;
|
||||
|
||||
private:
|
||||
bool m_is_timer_paused = true;
|
||||
u64 m_Frequency = 0;
|
||||
u64 m_StartTime = 0;
|
||||
u64 m_PauseTime = 0;
|
||||
};
|
||||
}
|
Loading…
Reference in New Issue