From d25565d0302ab3e87c3554e4c1ff5f9ec76adc35 Mon Sep 17 00:00:00 2001 From: Jaby Date: Sun, 11 Sep 2022 11:44:58 +0200 Subject: [PATCH] Clean Up --- include/PSX/Auxiliary/complex_bitmap.hpp | 147 ----------------------- include/PSX/System/IOPorts/IOPort.hpp | 9 -- src/Library/src/BootLoader/gpu_boot.cpp | 2 - 3 files changed, 158 deletions(-) diff --git a/include/PSX/Auxiliary/complex_bitmap.hpp b/include/PSX/Auxiliary/complex_bitmap.hpp index 2ea4fdeb..95c421ae 100644 --- a/include/PSX/Auxiliary/complex_bitmap.hpp +++ b/include/PSX/Auxiliary/complex_bitmap.hpp @@ -150,151 +150,4 @@ public: } }; -/*template -class ComplexBitMap { -public: - T value = 0; - -private: - template - constexpr ComplexBitMap& set_va(const S& value) { - return this->set(value); - } - - template - constexpr ComplexBitMap& set_va(const S& value, const ARGS&...args) { - return this->set_va(value).set_va(args...); - } - -public: - constexpr ComplexBitMap() = default; - constexpr ComplexBitMap(T value) : value(value) { - } - - template - static constexpr ComplexBitMap with(ARGS...args) { - return ComplexBitMap().set_va(args...); - } - - //Accesssing bits - template - constexpr ComplexBitMap& set_bit(S bit) { - this->value = bit::set(this->value, static_cast(bit)); - return *this; - } - - template - constexpr void set_bit(S bit) volatile { - this->value = bit::set(this->value, static_cast(bit)); - } - - template - constexpr ComplexBitMap& clear_bit(S bit) { - this->value = bit::clear(this->value, static_cast(bit)); - return *this; - } - - template - constexpr void clear_bit(S bit) volatile { - this->value = bit::clear(this->value, static_cast(bit)); - } - - template - constexpr bool is_bit_set(S bit) { - return bit::is_set(this->value, static_cast(bit)); - } - - template - constexpr bool is_bit_set(S bit) volatile { - return bit::is_set(this->value, static_cast(bit)); - } - - //Accessing values - template - constexpr ComplexBitMap& set_value(S value, const BitRange& range) { - this->value = bit::value::set_normalized(this->value, static_cast(value), range.begin, range.length); - return *this; - } - - template - constexpr void set_value(S value, const BitRange& range) volatile { - this->value = bit::value::set_normalized(this->value, static_cast(value), range.begin, range.length); - } - - template - constexpr ComplexBitMap& clear_value(const BitRange& range) { - this->value = bit::value::clear_normalized(this->value, range.begin, range.length); - return *this; - } - - template - constexpr void clear_value(const BitRange& range) volatile { - this->value = bit::value::clear_normalized(this->value, range.begin, range.length); - } - - template - constexpr S get_value(const BitRange& range) { - return static_cast(bit::value::get_normalized(this->value, range.begin, range.length)); - } - - template - constexpr S get_value(const BitRange& range) volatile { - return static_cast(bit::value::get_normalized(this->value, range.begin, range.length)); - } - - // For easier constructing - constexpr ComplexBitMap& set(const BitRange& range, T value) { - this->set_value(value, range); - return *this; - } - - constexpr ComplexBitMap& set(const BitRangeValue& value) { - this->set_value(value.value, {value.begin, value.length}); - return *this; - } - - constexpr ComplexBitMap& set(const Bit& bit) { - this->set_bit(bit.value); - return *this; - } - - constexpr ComplexBitMap& set(const ClearBitValue& value) { - this->clear_bit(value.bit); - return *this; - } - - constexpr ComplexBitMap& operator|(const BitRangeValue& value) { - this->set_value(value.value, value.range); - return *this; - } - - constexpr ComplexBitMap& operator|(const Bit& bit) { - this->set_bit(bit.value); - return *this; - } - - constexpr ComplexBitMap& operator|(const ClearBitValue& value) { - this->clear_bit(value.bit); - return *this; - } - - //For raw access - constexpr operator T() const { - return this->value; - } - - constexpr operator T() const volatile { - return this->value; - } - - constexpr ComplexBitMap& operator=(T value) { - this->value = value; - return *this; - } - - constexpr void operator=(T value) volatile { - this->value = value; - } -};*/ - #endif //!__JABYENGINE_COMPLEX_BITMAP_HPP__ \ No newline at end of file diff --git a/include/PSX/System/IOPorts/IOPort.hpp b/include/PSX/System/IOPorts/IOPort.hpp index f4ab46b2..b12a8680 100644 --- a/include/PSX/System/IOPorts/IOPort.hpp +++ b/include/PSX/System/IOPorts/IOPort.hpp @@ -70,13 +70,4 @@ static constexpr uintptr_t IO_Base_Adr = 0x10000000; this->raw = value.raw; \ } -/*\ - using ComplexBitMap::operator=; \ - constexpr name() = default; \ - constexpr name(ComplexBitMap value) : ComplexBitMap(value) { \ - }\ - template \ - constexpr name(ARGS...args) : ComplexBitMap(args...) {\ - }*/ - #endif //!__JABYENGINE_IOPORT_HPP__ \ No newline at end of file diff --git a/src/Library/src/BootLoader/gpu_boot.cpp b/src/Library/src/BootLoader/gpu_boot.cpp index da2d0ade..f31e85cc 100644 --- a/src/Library/src/BootLoader/gpu_boot.cpp +++ b/src/Library/src/BootLoader/gpu_boot.cpp @@ -2,8 +2,6 @@ #include namespace GPU { - - void display_logo() { Display::disable(); quick_fill_fast(Color24(0x0, 0x80, 0x80), PositionU16(0, 0), SizeU16(640, 480));