mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-06-25 03:21:36 +02:00
VideoCommon: remove 'GetByteSizeInMemory()' from custom asset, it is not needed anymore
This commit is contained in:
@ -3,6 +3,8 @@
|
||||
|
||||
#include "VideoCommon/Assets/CustomAsset.h"
|
||||
|
||||
#include <utility>
|
||||
|
||||
namespace VideoCommon
|
||||
{
|
||||
CustomAsset::CustomAsset(std::shared_ptr<CustomAssetLibrary> library,
|
||||
@ -33,7 +35,7 @@ std::size_t CustomAsset::Unload()
|
||||
{
|
||||
std::lock_guard lk(m_info_lock);
|
||||
UnloadImpl();
|
||||
return m_bytes_loaded.exchange(0);
|
||||
return std::exchange(m_bytes_loaded, 0);
|
||||
}
|
||||
|
||||
CustomAsset::TimeType CustomAsset::GetLastLoadedTime() const
|
||||
@ -51,9 +53,4 @@ const CustomAssetLibrary::AssetID& CustomAsset::GetAssetId() const
|
||||
return m_asset_id;
|
||||
}
|
||||
|
||||
std::size_t CustomAsset::GetByteSizeInMemory() const
|
||||
{
|
||||
return m_bytes_loaded;
|
||||
}
|
||||
|
||||
} // namespace VideoCommon
|
||||
|
@ -46,10 +46,6 @@ public:
|
||||
// as an index
|
||||
std::size_t GetHandle() const;
|
||||
|
||||
// A rough estimate of how much space this asset
|
||||
// will take in memroy
|
||||
std::size_t GetByteSizeInMemory() const;
|
||||
|
||||
protected:
|
||||
const std::shared_ptr<CustomAssetLibrary> m_owning_library;
|
||||
|
||||
@ -60,7 +56,7 @@ private:
|
||||
std::size_t m_handle;
|
||||
|
||||
mutable std::mutex m_info_lock;
|
||||
std::atomic<std::size_t> m_bytes_loaded = 0;
|
||||
std::size_t m_bytes_loaded = 0;
|
||||
std::atomic<TimeType> m_last_loaded_time = {};
|
||||
};
|
||||
|
||||
|
Reference in New Issue
Block a user