mirror of
https://github.com/hrydgard/ppsspp.git
synced 2026-07-11 01:25:07 +02:00
Remove unnecessary IsStarted method
This commit is contained in:
+4
-10
@@ -85,18 +85,12 @@ static GPUCommon *CreateGPUCore(GPUCore gpuCore, GraphicsContext *ctx, Draw::Dra
|
||||
|
||||
bool GPU_Init(GPUCore gpuCore, GraphicsContext *ctx, Draw::DrawContext *draw) {
|
||||
_dbg_assert_(draw || gpuCore == GPUCORE_SOFTWARE);
|
||||
_dbg_assert_(!gpu);
|
||||
|
||||
GPUCommon *createdGPU = CreateGPUCore(gpuCore, ctx, draw);
|
||||
|
||||
// This can happen on some memory allocation failure, but can probably just be ignored in practice.
|
||||
if (createdGPU && !createdGPU->IsStarted()) {
|
||||
delete createdGPU;
|
||||
createdGPU = nullptr;
|
||||
}
|
||||
|
||||
if (createdGPU) {
|
||||
gpu = createdGPU;
|
||||
gpuDebug = createdGPU;
|
||||
}
|
||||
gpu = createdGPU;
|
||||
gpuDebug = createdGPU;
|
||||
|
||||
return gpu != nullptr;
|
||||
}
|
||||
|
||||
@@ -70,9 +70,6 @@ public:
|
||||
|
||||
virtual void UpdateCmdInfo() = 0;
|
||||
|
||||
virtual bool IsStarted() {
|
||||
return true;
|
||||
}
|
||||
virtual void Reinitialize();
|
||||
|
||||
virtual void BeginHostFrame(const DisplayLayoutConfig &config);
|
||||
|
||||
@@ -437,8 +437,7 @@ SoftGPU::SoftGPU(GraphicsContext *gfxCtx, Draw::DrawContext *draw)
|
||||
drawEngineCommon_ = drawEngine_;
|
||||
|
||||
// Push the initial CLUT buffer in case it's all zero (we push only on change.)
|
||||
if (drawEngine_->transformUnit.IsStarted())
|
||||
drawEngine_->transformUnit.NotifyClutUpdate(clut);
|
||||
drawEngine_->transformUnit.NotifyClutUpdate(clut);
|
||||
|
||||
// No need to flush for simple parameter changes.
|
||||
flushOnParams_ = false;
|
||||
@@ -795,10 +794,6 @@ void SoftGPU::FastRunLoop(DisplayList &list) {
|
||||
dirtyFlags_ = dirty;
|
||||
}
|
||||
|
||||
bool SoftGPU::IsStarted() {
|
||||
return drawEngine_ && drawEngine_->transformUnit.IsStarted();
|
||||
}
|
||||
|
||||
void SoftGPU::ExecuteOp(u32 op, u32 diff) {
|
||||
const u8 cmd = op >> 24;
|
||||
const auto info = softgpuCmdInfo[cmd];
|
||||
|
||||
@@ -129,7 +129,6 @@ public:
|
||||
~SoftGPU();
|
||||
|
||||
u32 CheckGPUFeatures() const override { return 0; }
|
||||
bool IsStarted() override;
|
||||
void ExecuteOp(u32 op, u32 diff) override;
|
||||
void FinishDeferred() override;
|
||||
int ListSync(int listid, int mode) override;
|
||||
|
||||
@@ -53,10 +53,6 @@ TransformUnit::~TransformUnit() {
|
||||
delete binner_;
|
||||
}
|
||||
|
||||
bool TransformUnit::IsStarted() {
|
||||
return binner_ && decoded_;
|
||||
}
|
||||
|
||||
SoftwareDrawEngine::SoftwareDrawEngine() {
|
||||
flushOnParams_ = false;
|
||||
}
|
||||
|
||||
@@ -117,8 +117,6 @@ public:
|
||||
TransformUnit();
|
||||
~TransformUnit();
|
||||
|
||||
bool IsStarted();
|
||||
|
||||
static WorldCoords ModelToWorldNormal(const ModelCoords& coords);
|
||||
static WorldCoords ModelToWorld(const ModelCoords& coords);
|
||||
static ScreenCoords ClipToScreen(const ClipCoords &coords, bool *outsideRangeFlag);
|
||||
|
||||
Reference in New Issue
Block a user