mirror of
https://github.com/yuzu-emu/FasTC.git
synced 2024-11-24 07:45:49 +01:00
Move default bit depth definitions to abstracted pixel buffer loading function.
This commit is contained in:
parent
7359f9e758
commit
e780560d1e
@ -138,6 +138,11 @@ unsigned int ImageLoader::GetChannelForPixel(uint32 x, uint32 y, uint32 ch) {
|
||||
}
|
||||
|
||||
bool ImageLoader::LoadFromPixelBuffer(uint32 *data) {
|
||||
m_RedChannelPrecision = 8;
|
||||
m_GreenChannelPrecision = 8;
|
||||
m_BlueChannelPrecision = 8;
|
||||
m_AlphaChannelPrecision = 8;
|
||||
|
||||
const int nPixels = m_Width * m_Height;
|
||||
m_RedData = new uint8[nPixels];
|
||||
m_GreenData = new uint8[nPixels];
|
||||
|
@ -74,11 +74,6 @@ bool ImageLoaderPVR::ReadData() {
|
||||
return false;
|
||||
}
|
||||
|
||||
m_RedChannelPrecision = 8;
|
||||
m_GreenChannelPrecision = 8;
|
||||
m_BlueChannelPrecision = 8;
|
||||
m_AlphaChannelPrecision = 8;
|
||||
|
||||
const pvrtexture::CPVRTextureHeader &hdr = pvrTex.getHeader();
|
||||
|
||||
m_Width = hdr.getWidth();
|
||||
|
Loading…
Reference in New Issue
Block a user