1
0
mirror of https://github.com/blawar/GLideN64.git synced 2024-07-04 10:03:36 +00:00
Commit Graph

19 Commits

Author SHA1 Message Date
matto
fa7e1c8137 Splitting up asserts
If these asserts are to be useful for debugging, they should really
be split up so that we can tell which one is failing.
2015-08-29 11:55:34 -04:00
Sergey Lipskiy
74afd9f114 Fix getTextureShiftScale for case of one-level mip-map.
Fixed guard rail in Banjo Kazooie, #158
2015-06-17 22:58:03 +06:00
Sergey Lipskiy
27149064e0 Correct load to TMEM functions: wrap tmem address in case of overflow.
Necessary for issue #571
2015-06-17 16:02:06 +06:00
Sergey Lipskiy
e3dcba03f6 Minor correction in GetCI16RGBA functions.
Make calculations a bit more optimal and clear.
2015-06-05 00:07:51 +06:00
Sergey Lipskiy
37b5a38486 Enable texture_filter_anisotropic for GLES. 2015-06-01 14:50:04 +06:00
Sergey Lipskiy
9299dc5549 Disable mip-map texture load for GLES2. 2015-05-26 14:03:53 +06:00
Sergey Lipskiy
ae694f98e0 Always use GL_RGBA as internal texture format for GLES2.
Fixed compatibility with Mali400 GPU.
2015-05-26 14:03:47 +06:00
Sergey Lipskiy
0c416070c7 Fix load RGBA16 texture when tlut is enabled.
Solution is taken from Angrylion's software lle plugin.

Fixed Mario Kart- thwomp textures #532
2015-05-22 19:05:21 +06:00
Sergey Lipskiy
47719e3ce3 Don't set GL_TEXTURE_MAX_LEVEL for GLES2. 2015-05-18 13:51:14 +06:00
Sergey Lipskiy
73fcf8d551 Move TextureCache::m_curUnpackAlignment initialization to TextureCache::_addTexture
Mupen64plus set GL_UNPACK_ALIGNMENT to 1 after TextureCache::init().
When TextureCache set GL_UNPACK_ALIGNMENT back to value obtained in init(),
it broke text in mupen64plus messages.
2015-05-13 10:22:34 +06:00
Sergey Lipskiy
2feb8a24dd Use glTexStorage2DMultisample for GLES3_1 2015-05-13 10:22:33 +06:00
Sergey Lipskiy
7f9a3973eb Do not use textureLod for fetching normal textures. It kills anisotropic filtering:
https://www.opengl.org/wiki/Sampler_(GLSL)
Also need to keep in mind issue #232 and not allow mip-mapping for combiners,
which do not use it.

Fixed anisotropic filtering not working #505
2015-05-13 10:22:29 +06:00
Sergey Lipskiy
eabbd252f8 Change CachedTexture::frameBufferTexture type to enum.
Need to separate one-sampled frame buffer textures from multosampled ones.
2015-05-13 10:22:27 +06:00
Sergey Lipskiy
663a0d76f1 Implement multisampled textures fetch in shaders.
Thanks mudlord for the idea.

Fixed Perfect Dark frame buffer effects do not work when FSAA is on. #244
2015-05-13 10:22:26 +06:00
Sergey Lipskiy
6afe5fe30c Disable anisotropy for GL ES 2015-05-13 10:22:08 +06:00
Sergey Lipskiy
ded889350c Remove use of obsolete texture type GL_LUMINANCE8_ALPHA8. 2015-05-13 10:22:07 +06:00
Sergey Lipskiy
d95103d3d1 Correct condition for mip-mapped textures filtering in 3 point filter mode. 2015-05-13 10:21:54 +06:00
Sergey Lipskiy
4b1114a113 Fix texture ShiftScale calculation.
Pokemon Stadium missing ground texture #412 reveals the problem:
the game loads the same texture into tile0 and tile1.
The only difference is ShiftScale values.
Since the checksum is the same, the same CachedTexture is used for both tiles.
Shift scale correction ovrwrites ShiftScale for tile0 when tile1 is loaded.
Thus, texture coordinates for both tiles will be same.
Combiner uses (tile0-tile1)*env_a+shade. Since t0==t1, texture component is missing.

Solution: calculate ShiftScale for each tile right before use.

Fixed #412
2015-05-13 10:21:49 +06:00
Sergey Lipskiy
52d68d1389 Move all sources to src folder. 2015-05-13 10:21:32 +06:00