1
0
mirror of https://github.com/blawar/GLideN64.git synced 2024-06-30 08:24:05 +00:00
Commit Graph

3577 Commits

Author SHA1 Message Date
Rosalie Wanders
b0385c5100 GLideNUI: allow resizing 2022-03-13 11:27:34 +07:00
zilmar
37c09949b3
Fix Vs2015 compile issues (#2665)
* fix vs2015 compile issue
2022-03-04 18:35:29 +07:00
Sergey Lipskiy
1a711257ed Log unknown gbi command. 2022-02-20 13:48:14 +07:00
Sergey Lipskiy
8a0752a2f2 Update cmake/Readme.txt 2022-02-20 13:47:29 +07:00
トトも
efc88a2d5b
README Formatting (#2636)
* README Formatting
2022-02-20 13:12:10 +07:00
Francisco Zurita
5ee1de6ec1 Detect the Angle renderer
Also, in Android disable EGL image if using the angle renderer and disable fragment based depth.
Neither of the above seem to work in Android with the Angle renderer
2022-02-20 11:22:27 +07:00
Sergey Lipskiy
66a71307e8 Disable color buffer copy for JFG in custom settings.
FBInfo should control all copies to RDRAM.
2022-02-20 11:16:49 +07:00
Sergey Lipskiy
9e5564dc7c Make FBInfo working when when "copy to RDRAM" option is disabled.
By design, FBInfo should control all copies from/to RDRAM.
When it is enabled, other options should be disabled.
IN practice it does not always work yet.
2022-02-20 11:16:49 +07:00
Sergey Lipskiy
ccc8587367 Allow copy color buffer to RDRAM when current buffer is null.
Problem: JFG crosshair has incorrect color when FBInfo and Aux buffer copy are enabled.
"Aux buffer copy" copies the buffer and removes it.
If aux buffer is the current one, the current buffer set to null.
FBInfo uses ColorBufferToRDRAM to copy color buffer ti RDRAM.
ColorBufferToRDRAM does nothing when current frame buffer is null, so
FBInfo can't copy the buffer.

Solution: allow copy to RDRAM when current buffer is null.

Note: copy to RDRAM when current buffer is null was disabled in
commit bbc71c3f0 to fix problem "Snowboard Kids causes segmentation fault #477"
Now Snowboard Kids does not crash here.
2022-02-20 11:16:49 +07:00
Sergey Lipskiy
342683d2c6 Allow to draw aux (not produced by gDPTextureRectangle) texrects
when current frame buffer is null.

Problem: FBInfo does not work when Aux buffer copy is enabled.
"Aux buffer copy" copies the buffer and removes it.
If aux buffer is the current one, the current buffer set to null.
FBinfo renders RDRAM buffer to the frame buffer using GraphicsDrawer::drawTexturedRect.
It does nothing if GraphicsDrawer::_canDraw() returns false.
_canDraw() returns false if current buffer is null.
Thus, pixels from RDRAM are not copied.

Solution: Always render aux texrects.
2022-02-20 11:16:49 +07:00
Sergey Lipskiy
7eef2b3684 Code refactor: get rid of Windows macro min and max. 2022-02-20 11:16:49 +07:00
Sergey Lipskiy
f4d83cd9bd Ensure that mipmap shader will not try to load HD textures from atlas. 2022-02-19 13:39:50 +07:00
Rosalie
941e054157 GLideNUI: copy M64P_GLIDENUI fix to Config_LoadConfig() aswell 2022-02-19 11:50:15 +07:00
Sergey Lipskiy
49373fde71 Correct FrameBuffer::isAuxiliary()
If buffer's size is 8bit, it is an auxiliary buffer.

Fixed homebrew toonshading not working properly. #2644
2022-02-14 18:16:01 +07:00
Sergey Lipskiy
58faa2874a Add support for HD textures, which have the same checksum but different format or size.
See #2569 for details.
2022-02-14 18:12:14 +07:00
Sergey Lipskiy
555fbac213 Fix mip-mapped textures not filtered with fast texture path when "emulate mip-map" is disabled. 2022-02-13 21:40:31 +07:00
Sergey Lipskiy
31553a3532 Correct load of mip-map textures with accurate path when mip-map emulation is disabled.
Fast path totally disables mip-map calculations when "mip-map emulation" option is disabled.
Accurate path works differently. It just set lod to 1.0, which forces most detailed textures to be used.
However, the remained calculations are performed and the mip-map tiles still must be in texture atlas format.

Fixed black textures in GE when mip-map emulation is disabled, see #2641
2022-02-13 21:00:26 +07:00
fzurita
bf7dd027ba Don't use a vertex offset in the fast shader path 2022-02-13 18:38:28 +07:00
Rosalie Wanders
7e728b1f55 GLideNUI: copy config files to user config path when needed 2022-02-13 11:45:41 +07:00
Rosalie Wanders
4598939a90 Add inaccurate texture coordinates hotkey 2022-02-13 11:38:27 +07:00
Sergey Lipskiy
8a0db39812 Refactor texture load: apply proper mask to tmem read address to prevent out of bounds reads.
Fixes #2641 Regression: Check that texture fit TMEM before load
2022-02-13 11:16:24 +07:00
Sergey Lipskiy
1e0699bf73 Revert "Check that texture fit TMEM before load."
This reverts commit 7417144f64.
2022-02-13 11:16:24 +07:00
Sergey Lipskiy
7417144f64 Check that texture fit TMEM before load.
It should prevent out of TMEM bounds read.
2022-01-22 11:21:29 +07:00
s2s
0d765008d0 Do not apply shift scale to background textures.
Fixes issue with Command & Conquer described in #2617
2022-01-21 17:58:58 +07:00
fzurita
df2d4debbb Workaround for PowerVR issues
PowerVR needs depth to be cleared every frame, otherwise most geometry
is rendered behind the background.

It also needs fragment based depth to be disabled, otherwise geometry
has various depth glitches.
2022-01-16 18:35:05 +07:00
Sergey Lipskiy
30e4d3416b Minor code cleanup in gSPCullVertices 2022-01-16 18:07:24 +07:00
Sergey Lipskiy
fd29c4386a Fix renderScreenSpaceTriangles when input vertices represent TRIANGLE_STRIP. 2022-01-16 17:24:49 +07:00
Sergey Lipskiy
e9a6f258af Apply mask on DMEM address to avoid segmentation fault in Indiana Jones,
see #2628
2022-01-08 11:22:42 +07:00
fzurita
6275140109 Fix build with CMake on Windows 2022-01-07 19:05:08 +07:00
Sergey Lipskiy
8343fd05c9 Restore logic for uTexOffset uniform.
fixed #2621 Mario tennis broken shadows in accurate path
2021-12-21 00:54:17 +07:00
Sergey Lipskiy
506f263c13 Correct imageW/imageH calculation in ObjCoordinates again.
fixes #2617 RE2 bottom of the screen is being cut off
2021-12-19 20:53:09 +07:00
Sergey Lipskiy
b2f3caa1a4 Revert "Shift S2DEX background texture coordinates in non-native resolutions."
This reverts commit e0d5b0be7b.

fixes #2625 Majora's Mask misplaced blur
2021-12-19 20:46:16 +07:00
Sergey Lipskiy
2c8533661b Fix crash in Mario Tennis, caused by wrong tile size calculation.
Regressions in S2DEX games are possible, but not found yet.
Also make sure that size of mip-map tile is not greater than possible.
2021-12-18 23:59:19 +07:00
Sergey Lipskiy
223a6b757b "Correct" mipmap shader.
It was correct, but absence of space between '}' and '\n' makes it working incorrect on Radeons.
Looks like a driver error.
2021-12-18 22:56:10 +07:00
Sergey Lipskiy
7b507e74d4 Correct TextureCache::activateTexture 2021-12-08 20:37:36 +07:00
Sergey Lipskiy
f4fce5608f Correct mip-map shader for the case when texture level is 0 and detailed texture enabled 2021-12-08 20:37:36 +07:00
orbea
9d0e92a10d cmake: Generate Revision.h in the build directory 2021-12-06 23:57:51 +07:00
Sergey Lipskiy
727639c8ba Fix gDP.m_texCoordBounds validity. 2021-12-05 15:18:51 +07:00
s2s
337e96d3b0 Use texture coordinate bounds for s2dex one-piece backgrounds 2021-12-05 15:18:51 +07:00
s2s
75fd353741 Modify implementation of texture coordinate bounds for non-native resolutions. 2021-12-05 15:18:51 +07:00
Sergey Lipskiy
21fe9d5f92 GraphicsDrawer::drawTexturedRect fixes:
* remove old hack for clamp/wrap tex coords. It seems that the hack is not necessary anymore.
necessary anymore.
* minor optimization for accurate texture path.
2021-12-05 15:18:00 +07:00
s2s
4e0a4f700c Remove duplicated uniforms in accurate texture coordinate path. 2021-11-30 11:23:26 +07:00
orbea
6b8b53f633 cmake: Set OpenGL_GL_PREFERENCE
Silences a cmake warning for Policy CMP0072 with cmake-3.21.4.
2021-11-30 11:23:03 +07:00
orbea
ea98e44d7f cmake: Better handling of git
This fixes some problems:

* When building out of tree the git command will work in the wrong
  directory.
* The user may not actually have git installed.
* The source tree may not actually have the .git directory, for example
  when downloading a source archive from github.
2021-11-30 11:21:11 +07:00
orbea
c6fdaa899f src/GLideNHQ/CMakeLists.txt: Bump cmake version
This matches the other cmake files.
2021-11-30 11:18:09 +07:00
orbea
72062a142e cmake: Better handling of CMAKE_BUILD_TYPE
There are four main variable for CMAKE_BUILD_TYPE, 'Debug',
'Release', 'RelWithDebInfo' and 'MinSizeRel'. Additionally
there is 'None' which acts as a plain build.
2021-11-28 23:38:58 +07:00
orbea
e25cb4f111 cmake: Add an install target 2021-11-28 21:32:51 +07:00
s2s
e0d5b0be7b Shift S2DEX background texture coordinates in non-native resolutions. 2021-11-26 19:14:37 +07:00
s2s
865e9b443e Fix S2DEX one-piece backgrounds 2021-11-26 19:14:36 +07:00
Rosalie Wanders
62e49b9cdf ci: fix build failure 2021-11-26 19:05:35 +07:00