-
Bug
-
Resolution: Unresolved
-
None
-
1.19.4, 23w18a
-
Confirmed
-
Performance, Textures and models
-
Normal
-
Gameplay
This is a merge of MC-262427 and MC-262433 as requested by Fantastime in the comments of the latter.
Here is the latest revision of the resource pack to fix this: reworked-pot-models-and-texture-25w02a-v1.0.zip
The bug
The models for flower pots, as well as the models for objects inside of flower pots, are very poorly made:
- The shape is defined in a very wasteful way; currently the flower pot model itself uses 22 quads to define its mesh, but a visually identical result can be achieved using just 11 quads (similarly to how it was rendered prior to release 1.8).
- The texture mapping on the pot itself is also not done very well - the side texture shares a row of pixels with the top texture, and the bottom texture uses two planes to create a weird hodgepodge of the rim and side. It is extremely difficult to create a good texture for flower pots without outright replacing the model file.
It is possible to completely solve both of these problems simply by reworking the flower pot texture and the affected models.
How to reproduce
This concerns reproducing the render lag.
- Download the attached resource pack
- Set your render distance to 16 chunks
- Create this superflat world:
100*minecraft:flower_pot;minecraft:the_void
- Enter flying mode
/tp @s 0 64 0 0 90
- Compare performance with and without the resource pack using F3+2
Expected results
Flower pots would be optimal in vanilla already.
Actual results
We get much less lag with the resource pack, even though the pots ultimately look no different (MC-246224) aside.
How to fix
The fix should be simple:
- replace vanilla's current model files with the model files in the attached resource pack
- replace vanilla's flower pot texture with the texture provided in the resource pack
- replace Programmer Art's flower pot texture with the texture attached:
Further notes
Why are flower pots like this, anyway?
In release 1.4, when flower pots were implemented, their model system was just about optimal. However, when blocks were converted over to using data-driven models in 1.8, the model that flower pots were made to use was of an inferior quality, a fate shared by many other blocks such as cauldrons. Two of the outer areas of the pot use a cuboid of six sides, and the other two use four, which already gets us 20 planes. The dirt is another plane, and the bottom texture to plug the gap is another, getting us up to the 22-faced mess we have today.
Notably, the top face now uses four texture planes to define the outer rim, even though it previously only used one before 1.8. Any retexturing of the inner area of the rim texture will not be visible in vanilla's current model.
And what's up with the mapping on the bottom?
Up until 1.13, block placement rules were far more restrictive. Flower pots required a supporting block, and could not be placed on a visually transparent block such as glass. So the bottom was never visible in normal gameplay.
When these placement rules were relaxed, it was noted that the mapping on the bottom was incorrect, and that an empty area of the texture was mapped to this area instead. This was eventually fixed in 1.16 (MC-120335, MC-170842), however only the model file was changed to fix this, and the texture was left completely untouched despite there not being a dedicated "bottom" part. This means that the bottom "texture" is actually a weird combination of the top texture and side texture, and cannot be changed independently of either of them. The potted cactus model doesn't even use it currectly anymore (MC-194192).
How is the mapping fixed?
We have enough space in a 16x16 texture file to fit a dedicated "rim" texture, a dedicated "side" texture, a dedicated "inside" texture and a dedicated "bottom" texture - so that's what I've done here. All of the potted object models have been updated to match it. This means that we can also make potted cactus's bottom look correct without needing to waste an extra plane on it. The outcomes, besides the fix for potted cactus, and ignoring clipping inside of the pots, should be 100% visually identical to how flower pots already look in-game; MC-246224 may cause discrepancies, but these are unnoticeable in most cases even if you're actively looking for them.
Since the new format will break any existing textures for flower pots, here's the new specification, and how to update an existing texture file to match it:
- The top-left 6x6 region is for the top texture of the flower pot, so move the middle 6x6 region to the top left.
- The bottom-left 6x6 region is for the side texture of the flower pot. Move the bottom-middle 6x6 region of the old texture to this quadrant. (The top row of pixels should be a duplicate of the bottom row of pixels for the top texture.)
- The top-right 6x6 region is for the inside of the flower pot. By default, this visually duplicates the outside, so you can copy that region to here.
- The bottom-right 6x6 region is for the bottom of the flower pot. Resource pack creators will probably want to create their own bottom texture, but if the previous appearance is desired it can be recreated by placing the top texture here, and filling in its central 4x4 gap with the bottom-middle 4x4 region of the side texture.
- is duplicated by
-
MC-262433 Flower pots have redundant coplanar top faces, impacting performance, and extra interior faces that cannot normally be seen
- Resolved
- relates to
-
MC-262452 Hopper models are unoptimized and cause rendering lag
- Open
-
MC-262461 Stair models are unoptimized and can cause rendering lag
- Open
-
MC-262470 Cauldron models are very unoptimized, causing render lag
- Open
-
MC-262527 Item frame models are quite unoptimized
- Open
-
MC-267127 Composter model is unoptimized, causing extra rendering lag
- Open
-
MC-252693 Huge FPS drop in areas with a lot of honey blocks and slime blocks
- Resolved
-
MC-260296 Pink petal block models are not optimized
- Resolved
-
MC-262652 Dragon egg's side texture is mapped strangely as of 1.8 (and the model is also unoptimized)
- Resolved
-
MC-262641 Chorus flower models are incredibly unoptimized and cause serious rendering lag
- Open
-
MC-262689 Hanging mangrove propagule models are comically unoptimized
- Open
-
MC-262953 Fence gate models are very unoptimized, causing lag among other issues
- Open
-
MC-267281 Fence multipart model system performance optimization
- Open
-
MC-267315 Rendering performance optimization for glass pane models
- Open
-
MC-267864 Two-tall plant model/rendering not optimized
- Open
-
MC-279350 Leaf litter multipart model system is unoptimized, causing render lag
- Open