Storage Drawers: Natura Pack

Storage Drawers: Natura Pack

9M Downloads

Rendered items issue (render state leak) with Item Frames

maruohon opened this issue ยท 5 comments

commented

Yes, it's me again... :P
This time there is a rendering derp when there is an Item Frame being rendered, with an item in it, and then you hover over ItemStacks in your inventory. One of the Storage Drawers then changes to a darker item rendering.

Storage Drawers 4.2.6 on MC 1.11.2, Forge 2298.

Examples:

Isn't rendering fun...

commented

I sort of want to find an even weirder problems by putting skulls inside item frames.

commented

The interesting behavior is only the first item in the last drawer block placed rendered without proper lighting (I'm going to assume that the last-placed block TESR renders first).

Maybe it's our fault, or maybe rescale normal gets into a weird state somewhere else, but toggling it both ways before our disable hack seems to fix it. Disable alone didn't work, so I suspect the state was opposite to what we wanted: enabled in GL state, but marked disabled in the manager.

        GlStateManager.enableRescaleNormal();
        GlStateManager.disableRescaleNormal();
        GlStateManager.pushAttrib();
        GlStateManager.enableRescaleNormal();
        GlStateManager.popAttrib();
commented

Interesting. I really should learn OpenGL properly myself at some point... just never seems to be the time for that.

For me it was the first drawer block placed that rendered funny. Without taking a closer look, I'm assuming it depends on which order the TEs come out of the chunk TileEntity map when the chunk is being rendered, so it might be world-position dependant which one renders first(?)

commented

I don't know if it does any kind of sorting, but TEs are just in a list on disk.

commented

Fixed in the latest releases