Changed an RGBA vector getter from copy to reference to reduce CPU usage.

This commit is contained in:
Leon Styhre 2021-10-26 18:23:52 +02:00
parent 3d3d951842
commit 58345863b3

View file

@ -67,7 +67,7 @@ public:
// Has the image been loaded but not yet been rasterized as the size was not known?
bool getPendingRasterization() { return mPendingRasterization; }
std::vector<unsigned char> getRawRGBAData() { return mDataRGBA; }
std::vector<unsigned char>& getRawRGBAData() { return mDataRGBA; }
std::string getTextureFilePath() { return mPath; }
bool tiled() { return mTile; }