1
0
mirror of https://github.com/blawar/GLideN64.git synced 2024-07-02 09:03:37 +00:00
Commit Graph

148 Commits

Author SHA1 Message Date
Sergey Lipskiy
80ed169e24 Remove use of OpenGL.h 2017-01-22 20:43:05 +07:00
Sergey Lipskiy
f147927af9 Remove OpenGL use from FrameBuffer 2017-01-21 16:35:00 +07:00
Sergey Lipskiy
e83c3489a3 Replace OGLVideo by DisplayWindow
Replace OGLRender by GraphicsDrawer
2017-01-16 20:56:11 +07:00
Sergey Lipskiy
4cbb2d0189 Move #define INDEXMAP_SIZE to gSP.cpp 2017-01-09 21:05:42 +07:00
Sergey Lipskiy
daf6646b97 BufferManipulationObjects 2: createRenderbuffer, initRenderbuffer 2017-01-02 22:40:41 +07:00
Sergey Lipskiy
e8c47c0316 Use F3D_TRIX instead of F3D_Tri4.
Fixed #1307
2016-12-22 18:39:40 +07:00
Sergey Lipskiy
43d281e5bd Correct F3DEX2MM_Branch_W 2016-12-21 11:26:04 +07:00
Sergey Lipskiy
a7df7c13ac Rename parameter in gSPBranchLessW 2016-12-20 21:36:31 +07:00
Sergey Lipskiy
ae67daca9f Remove branchLessZ flag from MicrocodeInfo. Remove F3DEX2MM from specialMicrocodes list. 2016-12-20 17:50:03 +07:00
Gillou68310
9e8b32fc89 Implement ucode for Majora's Mask 2016-12-20 17:40:33 +07:00
Logan McNaughton
380725da53 remove inline specifier for gSPFlushTriangles 2016-12-15 07:30:52 -08:00
Sergey Lipskiy
cb2da455b6 gSPProcessVertex4: transform vertex normale with modelview matrix when LookAt is not used. 2016-12-04 11:46:13 +07:00
Sergey Lipskiy
74144d6126 Transform vertex normale with modelview matrix when LookAt is not used.
Fixed Quake 2 metallic effect in the menu is broken. #1279
2016-12-03 17:34:30 +07:00
Sergey Lipskiy
6af6e2c17f Rewrite lighting.
Fixed chopper attack wrong textures #99
Thanks Gillou68310 for detection of the problem's origin.
2016-11-26 19:31:50 +07:00
Sergey Lipskiy
83ff7f9ae5 Implement gSPSelectDL and gSPSelectBranchDL
Fixed Nushi Zuri 64 - Shiokaze ni Notte: #1230
2016-11-17 16:47:31 +07:00
Sergey Lipskiy
cf2bce9176 Implement gSPSetStatus. 2016-11-17 16:47:27 +07:00
Sergey Lipskiy
2b29b6c09a Fix linear texture coordinate transformation.
Fixed Zelda OOT rotating "N" is miscolored (HLE) #661
2016-10-27 13:24:19 +07:00
Sergey Lipskiy
abcbe96095 Fix gSPBillboardVertex4_default
Fixed alloons invisible in DKR with VEC4_OPT #1159
2016-10-08 14:29:50 +07:00
Sergey Lipskiy
ce5abcb21b Correct FrameBuffer::isValid - do not update m_validityChecked when isValid called from VI_UpdateScreen
Fixed Broken Pokemon stadium 2 in-game portraits #1149
2016-10-05 15:39:41 +07:00
Sergey Lipskiy
966b2d0f93 Fix compare of vertex Z and test Z in gSPBranchLessZ.
Fixed GT64 - Championship Edition: missing polygon #151
2016-09-28 23:24:17 +07:00
Sergey Lipskiy
25aa8889a8 Do not use 8bit CI frame buffer as texture for gSpBg commands.
Fixed Yoshi's Story black screen in some levels if frame buffer is enabled #1143

Problem:
The game draws background with BG command.
Background texture is 8bit CI.
For some reason the game set 8bit CI at the address of the
background texture, but renders nothing to it.
Plugin uses empty frame buffer texture instead of background texture.

Solution: Do not use 8bit CI frame buffer as BG textures.

Note: probably the game rendres something to the BG texture at some point
of the game. This can't be emulated in hardware anyway.
2016-09-28 22:29:45 +07:00
Sergey Lipskiy
d6dbfad902 Correct fix for #977 2016-09-23 10:57:44 +07:00
Sergey Lipskiy
38ff9e97d5 Reset texture mode to normal in gSPSetSpriteTile.
Fixed Nushi Zuri 64 incorrect gfx #977
2016-09-22 20:50:51 +07:00
Sergey Lipskiy
91f03c70bc Use dmaVertices when draw with drawScreenSpaceTriangle. 2016-09-21 15:24:15 +07:00
Sergey Lipskiy
77d0c9aada Code refactor: rename drawLLETriangle to drawScreenSpaceTriangle. 2016-09-20 16:21:54 +07:00
Sergey Lipskiy
e28bebd17e Add validity check for background fb textures.
Fixed Nushi Zuri 64: fb background doesn't work anymore #1115

Problem: The game normally uses color and depth buffers.
When it needs to show rectangle with text, CPU copies current color buffer
by depth buffer address. This buffer rendered as background, text rendered over.
Plugin detects buffer usage and tries to use depth buffer as background texture.
That buffer in video memory has no color information, because data copied by CPU and contained in RDRAM.

Solution: check that found frame buffer is valid.
In this case validity check will fail because RDRAM content modified by CPU,
and background will be read from RDRAM.
2016-09-16 17:09:25 +07:00
Sergey Lipskiy
1a5e971eea Minor code cleanup in gSPModifyVertex. 2016-09-02 11:05:38 +07:00
Francisco Zurita
b81fb23363 Fix CBFD lighting in Android 2016-08-16 22:07:51 +07:00
Sergey Lipskiy
c7c90cb7eb Add widescreen hack support to gSPProcessVertex4
Fixed Widescreen hack broken #1078
2016-08-04 12:25:07 +07:00
Francisco Zurita
51b8547eba Fix __VEC4_OPT issue for CBFD in gSPCBFDVertex.
This fixes incorrect lighting with VEC4_OPT enabled in CBFD.
2016-07-20 01:45:11 -04:00
Francisco Zurita
7386a036ce Port glN64 for Android NEON optimizations 2016-07-06 11:00:40 +06:00
Sergey Lipskiy
c816f7deeb Code refactor: rename CLIP_Z to CLIP_W 2016-06-20 15:12:31 +06:00
Sergey Lipskiy
86fbea9edc Code refactor: replace NULL by nullptr. 2016-06-10 12:40:18 +06:00
Sergey Lipskiy
8ab1ca7468 Code refactor: replace hack_skipVIChangeCheck and hack_ZeldaCamera by one hack_ZeldaMM 2016-05-08 16:58:21 +06:00
Sergey Lipskiy
cfc7f25e1a Fix typo in gSPProcessVertex4 2016-05-05 16:28:53 +06:00
Sergey Lipskiy
bea7adf4b3 Add a hack for Jeremy McGrath Supercross 2000 jauge line, see #274
Fixed issue #942
2016-03-29 22:21:52 +06:00
Sergey Lipskiy
8673e9382c Correct gSPModifyVertex for POINT_XYSCREEN.
Fixed tarzan: gfx are completely wrong (regression) #939
2016-03-28 22:02:12 +06:00
Sergey Lipskiy
38bc2145d2 Do not set MODIFY_ST in gSPModifyVertex.
Fixed South Park - Chef's Luv Shack: incorrect gfx (regression) #942
2016-03-27 10:38:11 +06:00
Sergey Lipskiy
7875b6057f Detect microcodes, where texture perspective correction is always enabled.
Fixed Quake 64 HLE incorrect particles. #637
2016-03-23 22:15:19 +06:00
Sergey Lipskiy
3c675b1cfb Do not draw Sprite2D when sprite->stride <= 0.
Fixed crash in Super Robot Spirits: Crash rankings option in HLE. #909
2016-03-20 17:43:12 +06:00
Sergey Lipskiy
80c954e5cc Move modify_vtx transformations to vertex shader.
Fixed Jeremy McGrath Supercross 2000: missing jauge line in menu #274
This game sets coordinates of lines vertices via modify_vtx.
modify_vtx set screen coordinates for the vertex.
Screen coordinates must be converted back to normalized device coordinates (NDC)
to apply viewport transformation. Unfortunately, the screen coordinates set are out of current viewport
and just clipped after transformation to NDC coordinates and viewport transformation.
Solution: use fullscreen viewport for modified vertex coordinates and
transform coordinates according to this viewport.
2016-03-19 14:02:57 +06:00
Sergey Lipskiy
7549e04157 Move calculations from drawLLETriangle to vertex shader. 2016-03-19 14:02:49 +06:00
Sergey Lipskiy
24885907d8 Add hack_ZeldaCamera to fix camera in Zelda MM, #577
The game copies current frame buffer to the area, which initially allocated for depth buffer.
Game read camera data from that area, not from normal frame buffer.
That's why 'copy color buffer to RDRAM' option does not help there.
Special code needed to process that. Looks ugly, but works.
2015-09-27 10:10:05 +06:00
Sergey Lipskiy
a3f9b43b4a Disable _copyDepthBuffer() for GLES2 only. 2015-09-26 22:36:25 +06:00
Sergey Lipskiy
27c4cccd81 Code refactor in _copyDepthBuffer(). 2015-09-26 22:13:49 +06:00
Sergey Lipskiy
4a75d4d357 Add hack to fix both mario 64 and mario kart 64 background (blue sky) with widescreen hack enable.
Author: Gillou68310
2015-06-26 22:06:06 +06:00
Sergey Lipskiy
2525b86f49 Implement "widescreen hack". 2015-05-13 10:21:43 +06:00
Sergey Lipskiy
52d68d1389 Move all sources to src folder. 2015-05-13 10:21:32 +06:00