New compact texture type for OGL/D3D: RGB565

git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@2225 8ced0084-cf51-0410-be5f-012b33b47a6e
This commit is contained in:
XTra.KrazzY
2009-02-12 22:32:33 +00:00
parent 57c4620902
commit e557e090dd
5 changed files with 31 additions and 11 deletions

View File

@ -358,6 +358,11 @@ TextureMngr::TCacheEntry* TextureMngr::Load(int texstage, u32 address, int width
gl_iformat = GL_INTENSITY;
gl_type = GL_UNSIGNED_BYTE;
break;
case PC_TEX_FMT_RGB565:
gl_format = GL_RGB;
gl_iformat = GL_RGB;
gl_type = GL_UNSIGNED_SHORT_5_6_5;
break;
}
if (!entry.isNonPow2 && ((tm0.min_filter & 3) == 1 || (tm0.min_filter & 3) == 2)) {
glTexParameteri(GL_TEXTURE_2D, GL_GENERATE_MIPMAP, GL_TRUE);