mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-07-30 17:49:48 -06:00
VideoCommon: Use std::span for BoundingBox::Write()
Crosses off a lingering TODO. Also amends a few nearby cases where a u32 cast was being repromoted to size_t.
This commit is contained in:
@ -18,7 +18,7 @@ public:
|
||||
|
||||
protected:
|
||||
std::vector<BBoxType> Read(u32 index, u32 length) override;
|
||||
void Write(u32 index, const std::vector<BBoxType>& values) override;
|
||||
void Write(u32 index, std::span<const BBoxType> values) override;
|
||||
|
||||
private:
|
||||
BBoxType* m_cpu_buffer_ptr;
|
||||
|
@ -42,7 +42,7 @@ std::vector<BBoxType> Metal::BoundingBox::Read(u32 index, u32 length)
|
||||
}
|
||||
}
|
||||
|
||||
void Metal::BoundingBox::Write(u32 index, const std::vector<BBoxType>& values)
|
||||
void Metal::BoundingBox::Write(u32 index, std::span<const BBoxType> values)
|
||||
{
|
||||
const u32 size = values.size() * sizeof(BBoxType);
|
||||
if (!g_state_tracker->HasUnflushedData() && !g_state_tracker->GPUBusy())
|
||||
|
Reference in New Issue
Block a user