Optimization for glow ink sac sign.
NamiUni opened this issue ยท 12 comments
Is your feature request related to a problem? Please describe.
Yes, it might a problem related to the signs lag (#350) . It is about glow ink sac sign.
Like literally, even 10 glow ink sac signs make fps significantly decay.
Describe the solution you'd like
The optimization for the sign render
Using "Enhanced Block Entities" to resolve by my own.
Describe alternatives you've considered
Optimize sign rendering and enhance in performance.
Additional context
The video that I filmed to examine the fps ratio per signs: https://youtu.be/2lazxwyKUXw
Enhanced Block Entities: https://www.curseforge.com/minecraft/mc-mods/enhanced-block-entities
https://www.curseforge.com/minecraft/mc-mods/enhanced-block-entities
is this link working
@Rajbir98 Thank you for pointing that out ๐
Welcome I Also have the same problem i wanted to make a led room with these glowing signs but its lagging my game i get 64 to 90 fps in max it droped to 5 to 10
and with Enhanced Block Entities it becomes 15 to 25 fps so it get rids of a lag a bit but not completely remove the lag
I took a comparison video.
5 times the performance of vanilla and 1.3 times the performance of 0.3.2.
https://youtu.be/znGDVf_8ijM
Is this still a relevant issue for sodium if immediately fast seems to have more or less fixed it?
The IF experimental optimization is incompatible with using a different Font than the unreadable default font that comes with Vanilla, and also break for signs with unicode chars.
That being said, there are other mods that also do some work on signs, e.g. EBE, Exordium and these don't have corner cases. They do a good job of making the problem less painful but not sure this is completely solved.
i have been thinking about this issue and my idea on this would be to replace the font of glowing signs with an emmisive font that has an outline, rather then generating an outline for the font by copying text as vanilla does, i did manage to make an example font but i had to do it manually and would prefer a way to do it programatically to avoid headaches for people maintaining it. here is the ascii font file i tested with;
this is probably a fairly important thing to optimise, as one glowing sign is the equivalant of 5 non glowing signs
Doing it separately for each colour, each alphabet, each language would be too much work for a sign and would make compatibility with mods worse.
I don't know what Sodium did in 0.4, so I'm speaking accordingly: (I couldn't find the release notes)
If it renders the text first, then the outline, it would degrade performance a lot. Instead, it might be a much better solution to combine the text with the outline and render it. It would be less work than the previous solution, with better compatibility with mods, but less performance.
I think this is efficiently solved in ImmediatelyFast 1.2.4 and above, you just need to enable experimental options