Wendelin
Explore posts from serversDHDistant Horizons
•Created by Wendelin on 7/13/2024 in #bug-report
LOD Clouds render always
This bug report is for the in-dev lod cloud rendering.
Currently the clouds always render, even if the vanilla rendering is skipped. This causes issues with shaders, and also other mods that disable or mess with vanilla clouds (like mine, better-clouds). Mostly that clouds appear twice.
A solution would be to inject into the
LevelRenderer#renderClouds
methods and set a flag that is has been called in the current frame. Not sure if thats the best solution tho.20 replies
DHDistant Horizons
•Created by Wendelin on 7/1/2024 in #help-me
Unexpected DhApiRenderParam#dhProjectionMatrix content with Iris enabled
I'm grabbing the projection matrix from the DhApiAfterRenderEvent and use it to perform a depth test in one of my shaders. And this works fine as long as no Iris shaders are active.
Usually the projection matrix contains "normal" values, e.g.:
But when an Iris shader is active (in this case BSL but I don't think it matters) the values seem wrong:
In earlier version of DH and Iris (1.x on 1.20.1 for example) this wasn't an issue.
It seems to me that DH is not providing the correct projection matrix, which is causing the depth test in my shader to produce wrong results.
I'm using:
- DH 2.1.2-a
- Iris 1.7.2
- Indium 1.0.33
- Sodium 0.5.9
and trying to update the DH compatibility of my mod "Better Clouds"
34 replies
TIPThe Iris Project
•Created by Wendelin on 6/27/2024 in #iris-issues
duplicate field net/irisshaders/iris/mixin/vertices/MixinBufferBuilder/vertexCount;;I in inputs
This issue was already asked about here: https://discord.com/channels/774352792659820594/1253346239425150997/1253346239425150997
Since yarn mappings are very common in the fabric ecosystem, should I open an issue on github to request a rename of the
vertexCount
field to avoid the name conflict?4 replies
DHDistant Horizons
•Created by Wendelin on 2/25/2024 in #bug-report
DH API does not notify of texture change
Binding textures returned by the DH API as usual* results in broken code.
(usual* = how you'ld usually do it in MC modding)
The issue here is that DH doesn't use Minecraft's built-in GL State manager
RenderSystem
(yarn mappings). The problem only becomes apparent when DH reinitializes the LODRenderer
.
This action will:
1. glDeleteTextures
the old texture
2. glGenTextures
a new texture
3. On some systems the old and new texture will have the same id (valid by OpenGL Spec)
4. Call RenderSystem.bindTexture
with the same texture id.
5. RenderSystem
will not call glBindTexture
because it thinks the same old texture is still bound.
6. A deleted texture is now bound to GL_TEXTURE6
I hope my description was clear enough.
The DH API does not provide a way to notice this texture change.
Probably the only way to circumvent this issue is on my side is to do this:
This will keep MC's state management and the "real" state "in sync", but results in wasted performance and is generally not a nice solution,13 replies
DHDistant Horizons
•Created by Wendelin on 2/18/2024 in #help-me
Loading the DH Api
The example repo the DH Api is simply added through a
implementation
directive in the build.grade file. However, I am facing the issue that the game will obviously crash when my mod is loaded, but not DH, and the class loaded can't find DH's classes.
For example: java.lang.NoClassDefFoundError: com/seibel/distanthorizons/api/methods/events/interfaces/IDhApiEvent
Now I am not sure I am supposed to include
the DH Api jar or what? I'm also confused because the API version on Modrinth seems really old. Is it assured to be stable?9 replies