| 1 | /* |
| 2 | * LegacyClonk |
| 3 | * |
| 4 | * Copyright (c) RedWolf Design |
| 5 | * Copyright (c) 2017-2021, The LegacyClonk Team and contributors |
| 6 | * |
| 7 | * Distributed under the terms of the ISC license; see accompanying file |
| 8 | * "COPYING" for details. |
| 9 | * |
| 10 | * "Clonk" is a registered trademark of Matthes Bender, used with permission. |
| 11 | * See accompanying file "TRADEMARK" for details. |
| 12 | * |
| 13 | * To redistribute this file separately, substitute the full license texts |
| 14 | * for the above references. |
| 15 | */ |
| 16 | |
| 17 | /* Implemention of NewGfx - without gfx */ |
| 18 | |
| 19 | #pragma once |
| 20 | |
| 21 | #include <StdDDraw2.h> |
| 22 | |
| 23 | class CStdNoGfx : public CStdDDraw |
| 24 | { |
| 25 | public: |
| 26 | CStdNoGfx(); |
| 27 | virtual ~CStdNoGfx(); |
| 28 | virtual bool CreateDirectDraw() override; |
| 29 | |
| 30 | public: |
| 31 | void PageFlip() override {} |
| 32 | virtual int GetEngine() override { return GFXENGN_NOGFX; } |
| 33 | std::string_view GetEngineName() const override { return "CStdNoGfx" ; } |
| 34 | virtual bool UpdateClipper() override { return true; } |
| 35 | virtual bool OnResolutionChanged() override { return true; } |
| 36 | virtual bool PrepareRendering(C4Surface *) override { return true; } |
| 37 | virtual void FillBG(uint32_t dwClr = 0) override {} |
| 38 | virtual void PerformBlt(CBltData &, C4TexRef *, uint32_t, bool, bool) override {} |
| 39 | virtual void DrawLineDw(C4Surface *, float, float, float, float, uint32_t) override {} |
| 40 | virtual void DrawQuadDw(C4Surface *, int *, uint32_t, uint32_t, uint32_t, uint32_t) override {} |
| 41 | virtual void DrawPixInt(C4Surface *, float, float, uint32_t) override {} |
| 42 | virtual bool ApplyGammaRamp(CGammaControl &, bool) override { return true; } |
| 43 | virtual bool SaveDefaultGammaRamp(CStdWindow *) override { return true; } |
| 44 | virtual void SetTexture() override {} |
| 45 | virtual void ResetTexture() override {} |
| 46 | virtual bool RestoreDeviceObjects() override { return true; } |
| 47 | virtual bool InvalidateDeviceObjects() override { return true; } |
| 48 | virtual bool DeviceReady() override { return true; } |
| 49 | virtual bool CreatePrimarySurfaces() override; |
| 50 | }; |
| 51 | |