Repository navigation
draw particles through shader pack programs - #862
Merged
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Type of change
Summary
with a shader pack on, particles weren't drawn at all. they now go through
gbuffers_particles(falling back totextured_lit) andgbuffers_particles_translucent(falling back toparticles), as iris does: opaque particles before deferred, translucent ones after water and before composite, in thePARTICLESrender stage.gbuffers programs now end with iris's alpha test (
CommonTransformer): adiscardongl_FragData[0]'s alpha, by the render type'sShaderKeythreshold (0.1 for particles, block entities and most entities, just above zero for eyes, off for sky and terrain), or the pack'salphaTest.<program>. cutout terrain (0.5) and solid entity render types are TODOs, since pomme draws them in the same pass as their neighbours.ParticlePipelinenow builds its vertices once per frame (prepare) and draws them either through its own pipelines or one layer through the pack's program.first of a stack for the missing pack programs (weather, clouds and hand next; glint waits for a glint pass).
Reference
n/a (iris:
ProgramId,ShaderKey,IrisPipelines,MixinParticleEngine)Testing
world/shaderpack_particles: breaks a block and spawns end rods with the test pack, whose particle programs tint magenta and cyan in the particle stage, then the same with packs off. shots show each layer through its own program.world/shaderpack,entities/shaderpack_layers,world/deterministicandblocks/blocksstill pass.just shaderpack-corpusover complementary compiles all 69 programs; its particles draw shaded through itsgbuffers_texturedfallback.