Two-tall plant model/rendering not optimized
The bug
Two-block-tall plants such as tall grass and tall flowers can be optimized such that they take less of a toll on the game's rendering engine and increase game performance.
Currently, the bottom half and top half are both separate block models, meaning that each full plant takes up eight texture planes. However, we can cut this in half and render the same plant using four texture planes, considerably increasing performance. This involves redoing textures such that each plant uses a single 16×32 texture rather than two 16×16 textures.
While this results in a considerable performance increase, I don't like this nearly as much as the other model optimizations I've done due to it causing the particles of these blocks to become distorted, potentially affecting how the blocks look with respect to lighting, and also violating the paradigm that every block texture must be a 16×16 square by default, among other reasons. As such, the attached demo resource pack only applies this to five of seven potential target plants (leaving out pitcher plants and sunflowers). If Mojang is still interested in implementing this optimization, I can extend it to these two plants as well if desired.
How to reproduce
As MC-118624 remains unfixed for some reason, we will need to set up our test environment manually.
- Create a superflat world with the preset
minecraft:bedrock,2*minecraft:dirt,minecraft:grass_block;minecraft:the_void
- Execute the command
/tp @s 0 -60 0
- Execute the command
/fill ~-90 ~ ~-90 ~90 ~ ~90 minecraft:tall_grass[half=lower]
- Execute the command
/fill ~-90 ~1 ~-90 ~90 ~1 ~90 minecraft:tall_grass[half=upper]
- Execute the command
/tp @s 0 0 0 0 90
- Set your render distance and simulation distance to five chunks
- Open the performance graphs with F3+2
- Observe with and without the attached resource pack
Expected results
Good framerates in vanilla.
Actual results
Not necessarily. The resource pack improves things considerably.
Linked Issues
relates to14
Created Issue:
Proof of concept: two-tall plant model/rendering optimization
Related to
MC-260296, MC-262427,MC-262433, MC-262452, MC-262461, MC-262470, MC-262527, MC-262641,MC-262652, MC-262689, MC-262953, MC-267127, MC-267281 and MC-267315.The bug
Two-block-tall plants such as tall grass and tall flowers can be optimized such that they take less of a toll on the game's rendering engine and increase game performance.
Currently, the bottom half and top half are both separate block models, meaning that each full plant takes up eight texture planes. However, we can cut this in half and render the same plant using four texture planes, considerably increasing performance. This involves redoing textures such that each plant uses a single 16×32 texture rather than two 16×16 textures.
While this results in a considerable performance increase, I don't like this nearly as much as the other model optimizations I've done due to it causing the particles of these blocks to become distorted, potentially affecting how the blocks look with respect to lighting, and also violating the paradigm that every block texture must be a 16×16 square by default, among other reasons. As such, the attached demo resource pack only applies this to five of seven potential target plants (leaving out pitcher plants and sunflowers). If Mojang is still interested in implementing this optimization, I can extend it to these two plants as well if desired.
How to reproduce
As MC-118624 remains unfixed for some reason, we will need to set up our test environment manually.
- Create a superflat world with the preset
minecraft:bedrock,2*minecraft:dirt,minecraft:grass_block;minecraft:the_void- Execute the command
/tp @s 0 -60 0- Execute the command
/fill ~-90 ~ ~-90 ~90 ~ ~90 minecraft:tall_grass[half=lower]- Execute the command
/fill ~-90 ~1 ~-90 ~90 ~1 ~90 minecraft:tall_grass[half=upper]- Execute the command
/tp @s 0 0 0 0 90- Set your render distance and simulation distance to five chunks
- Open the performance graphs with F3+2
- Observe with and without the attached resource pack
Expected results
Good framerates in vanilla.
Actual results
Not necessarily. The resource pack improves things considerably.
Proof of concept: two-tall plant model/rendering optimizationTwo-tall plant model/rendering not optimized
Related to
MC-260296, MC-262427,MC-262433, MC-262452, MC-262461, MC-262470, MC-262527, MC-262641,MC-262652, MC-262689, MC-262953, MC-267127, MC-267281 and MC-267315.The bug
Two-block-tall plants such as tall grass and tall flowers can be optimized such that they take less of a toll on the game's rendering engine and increase game performance.
Currently, the bottom half and top half are both separate block models, meaning that each full plant takes up eight texture planes. However, we can cut this in half and render the same plant using four texture planes, considerably increasing performance. This involves redoing textures such that each plant uses a single 16×32 texture rather than two 16×16 textures.
While this results in a considerable performance increase, I don't like this nearly as much as the other model optimizations I've done due to it causing the particles of these blocks to become distorted, potentially affecting how the blocks look with respect to lighting, and also violating the paradigm that every block texture must be a 16×16 square by default, among other reasons. As such, the attached demo resource pack only applies this to five of seven potential target plants (leaving out pitcher plants and sunflowers). If Mojang is still interested in implementing this optimization, I can extend it to these two plants as well if desired.
How to reproduce
As MC-118624 remains unfixed for some reason, we will need to set up our test environment manually.
- Create a superflat world with the preset
minecraft:bedrock,2*minecraft:dirt,minecraft:grass_block;minecraft:the_void- Execute the command
/tp @s 0 -60 0- Execute the command
/fill ~-90 ~ ~-90 ~90 ~ ~90 minecraft:tall_grass[half=lower]- Execute the command
/fill ~-90 ~1 ~-90 ~90 ~1 ~90 minecraft:tall_grass[half=upper]- Execute the command
/tp @s 0 0 0 0 90- Set your render distance and simulation distance to five chunks
- Open the performance graphs with F3+2
- Observe with and without the attached resource pack
Expected results
Good framerates in vanilla.
Actual results
Not necessarily. The resource pack improves things considerably.
relates to
Relates to: MC-260296 MC-262427 MC-262452 MC-262461 MC-262470 MC-262527 MC-262641 MC-262652 MC-262689 MC-262953 MC-267127 MC-267315 MC-267864 MC-279350
The bug
The current multipart system for walls can use more quads than are necessary to achieve an identical visual result. Making Minecraft render more quads increases render lag, so decreasing the amount needed will improve performance.
The case in question is much the same as MC-267281, arising where two opposite connections of a wall are either both "low" or both "tall". Minecraft, by default, will render one model in each direction, with a total of two. However, the exact same visual outcome can be achieved using a single, continuous model, reducing the amount of quads used for this case from 10 to 6. Since there are no texture mapping issues on walls (unlike MC-109478 and MC-225819/MC-267871), this fix also completely preserves their appearance, so we get no bonus fixes.
How to reproduce
- Create this superflat world:
minecraft:barrier;minecraft:the_void
- Initiate flying mode
/fill -30 -63 -30 30 -56 30 cobblestone_wall
/fill -30 -55 -30 30 -48 30 cobblestone_wall
/tp @s 0 0 0 0 90
- Compare framerates with and without the attached resource pack using F3+2
Expected results
Vanilla's framerates would be ideal.
Actual results
The resource pack gives better results.
How to fix
Adopt the system demonstrated by this resource pack for walls. I give Mojang full permission to use this resource pack to fix this optimization problem.
Relates to: MC-260296 MC-262427 MC-262452 MC-262461 MC-262470 MC-262527 MC-262641 MC-262652 MC-262689 MC-262953 MC-267127 MC-267281 MC-267315 MC-267864 MC-279350 MC-279354
The bug
Bamboo fences, like other fence types (see MC-267281), are not modelled in a way which is optimal for rendering performances. As a result, areas which use large amounts of bamboo fences will decrease framerate much more than otherwise should be the case.
Bamboo fences use a fundamentally different system for modelling compared to other fences, which is why I'm reporting this separately from the other fences. Tragically the issues with the normal fence model have carried over to the system used for bamboo fences.
The model system bamboo fences use is also more complicated than is neccessary - it uses four models for orthogonal connections, whereas this optimized system achieves a visually identical outcome using just three.
Note that since bamboo models use a unique texture rather than just copying the bamboo planks texture, the texture mapping will need to be shifted around. A modified version is found within the attached resource pack - the visual outcome will be identical, but existing resource packs will need to be changed by their authors to fit around it (assuming they don't take the lazy route and just copy over the old, terrible models).
How to reproduce
- Create a creative Superflat world with the following preset:
minecraft:barrier;minecraft:the_void
- Enter flying mode by double pressing the jump button
- Run the command
/tp @s 0 -20 0 0 90
- Run the command
/fill -30 -63 -30 30 -56 30 bamboo_fence
- Open the performance graphs via F3+2
- Switch between the default resources and the attached resource pack, comparing the performance
Expected results
Good framerates in vanilla.
Actual results
We can do far better.
How to fix
Simply implement the resources in the attached resource pack into vanilla. I give Mojang my full permission and encouragement to use these files to make vanilla Minecraft run better.
Further notes
Mipmapping will be affected, however this is a non-issue.
The bamboo fence item model is also updated to fit the new system.
Many of the old model files can be safely deleted once the new ones are added, as this improved system renders them completely superseded.






Yeah... This will also ruin single-block rendering of these plants (which can be made with commands), note that double chests used to render 1 end as both and the other end invisible. This was changed so that each end renders its corresponding side.
Also, reminding you of https://bugs.mojang.com/browse/MC-249034?focusedId=1150345&page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#comment-1150345
I'd say this is different from the latter point given that there is a clear performance benefit to making this change. The major things that make me hesitant are other issues with the game that this fix exposes, which could potentially themselves be fixed via other means.
Fixing the particle stretching is just including a square texture file with part of the whole texture, kinda like how it already is 2 separate texture files. Making particles consider element/texture stretching requires quite a rewrite of the block/item particle code.
While yes, it optimizes it, realistically you're not going to get affected by this much, nobody out there is going to fill a massive area with just double plants,and even if they did, there's other blocks that're more impactful.
You say it's different from the latter point (the reminder), but, quoting you in this report: "I don't like this nearly as much as the other model optimizations", in other words, you dislike the suggested optimization, in other words you prefer the current behavior or solution.
Mojang have recently been trying to optimize Java Edition performance, so even though I don't think this is a particularly elegant optimization, it still improves the game overall. If they choose to implement it, fine, if they choose not to do this specific optimization, also fine.
In addition, this resource pack still makes lower-half and top-half blocks visually distinguishable, even if it's not in the normal intuitive way.