From 50bfa7cd5e53b09bd803d5b6c35f8a30b62ec224 Mon Sep 17 00:00:00 2001 From: mniip Date: Wed, 5 Apr 2023 14:16:25 +0200 Subject: [PATCH] Remove unused VideoBuffer code --- src/graphics/Graphics.cpp | 16 ---------------- src/graphics/Graphics.h | 26 -------------------------- 2 files changed, 42 deletions(-) diff --git a/src/graphics/Graphics.cpp b/src/graphics/Graphics.cpp index 4181c2736..7820deacc 100644 --- a/src/graphics/Graphics.cpp +++ b/src/graphics/Graphics.cpp @@ -150,22 +150,6 @@ void VideoBuffer::ResizeToFit(Vec2 bound, bool resample) Resize(size, resample); } -int VideoBuffer::SetCharacter(int x, int y, String::value_type c, int r, int g, int b, int a) -{ - // Technically inaccurate but oh well - return x + BlendChar(Vec2(x, y), c, RGBA(r, g, b, a)); -} - -int VideoBuffer::BlendCharacter(int x, int y, String::value_type c, int r, int g, int b, int a) -{ - return x + BlendChar(Vec2(x, y), c, RGBA(r, g, b, a)); -} - -int VideoBuffer::AddCharacter(int x, int y, String::value_type c, int r, int g, int b, int a) -{ - return x + AddChar(Vec2(x, y), c, RGBA(r, g, b, a)); -} - template class RasterDrawMethods; int Graphics::textwidth(const String &str) diff --git a/src/graphics/Graphics.h b/src/graphics/Graphics.h index f71a88cdf..9882f4c59 100644 --- a/src/graphics/Graphics.h +++ b/src/graphics/Graphics.h @@ -55,32 +55,6 @@ public: [[deprecated("Use VideoBuffer(Vec2)")]] VideoBuffer(int width, int height); - using RasterDrawMethods::BlendPixel; - [[deprecated("Use BlendPixel(Vec2, RGBA)")]] - TPT_INLINE void BlendPixel(int x, int y, int r, int g, int b, int a) - { - BlendPixel(Vec2(x, y), RGBA(r, g, b, a)); - } - - [[deprecated("Use DrawPixel")]] - TPT_INLINE void SetPixel(int x, int y, int r, int g, int b, int a) - { - DrawPixel(Vec2(x, y), 0x000000_rgb .Blend(RGBA(r, g, b, a))); - } - - using RasterDrawMethods::AddPixel; - [[deprecated("Use AddPixel(Vec2, RGBA)")]] - TPT_INLINE void AddPixel(int x, int y, int r, int g, int b, int a) - { - AddPixel(Vec2(x, y), RGBA(r, g, b, a)); - } - [[deprecated("Use BlendChar")]] - int SetCharacter(int x, int y, String::value_type c, int r, int g, int b, int a); - [[deprecated("Use BlendChar")]] - int BlendCharacter(int x, int y, String::value_type c, int r, int g, int b, int a); - [[deprecated("Use AddChar")]] - int AddCharacter(int x, int y, String::value_type c, int r, int g, int b, int a); - bool WritePNG(const ByteString &path) const; };