rename
This commit is contained in:
@@ -446,12 +446,12 @@ public class ModelFactory {
|
||||
//TODO: special case stuff like vines and glow lichen, where it can be represented by a single double sided quad
|
||||
// since that would help alot with perf of lots of vines, can be done by having one of the faces just not exist and the other be in no occlusion mode
|
||||
|
||||
var sizes = this.computeModelDepth(textureData, checkMode);
|
||||
var depths = this.computeModelDepth(textureData, checkMode);
|
||||
|
||||
//TODO: THIS, note this can be tested for in 2 ways, re render the model with quad culling disabled and see if the result
|
||||
// is the same, (if yes then needs double sided quads)
|
||||
// another way to test it is if e.g. up and down havent got anything rendered but the sides do (e.g. all plants etc)
|
||||
boolean needsDoubleSidedQuads = (sizes[0] < -0.1 && sizes[1] < -0.1) || (sizes[2] < -0.1 && sizes[3] < -0.1) || (sizes[4] < -0.1 && sizes[5] < -0.1);
|
||||
boolean needsDoubleSidedQuads = (depths[0] < -0.1 && depths[1] < -0.1) || (depths[2] < -0.1 && depths[3] < -0.1) || (depths[4] < -0.1 && depths[5] < -0.1);
|
||||
|
||||
|
||||
boolean cullsSame = false;
|
||||
@@ -499,7 +499,7 @@ public class ModelFactory {
|
||||
for (int face = 5; face != -1; face--) {//In reverse order to make indexing into the metadata long easier
|
||||
long faceUploadPtr = uploadPtr + 4L * face;//Each face gets 4 bytes worth of data
|
||||
metadata <<= 8;
|
||||
float offset = sizes[face];
|
||||
float offset = depths[face];
|
||||
if (offset < -0.1) {//Face is empty, so ignore
|
||||
metadata |= 0xFF;//Mark the face as non-existent
|
||||
//Set to -1 as safepoint
|
||||
|
||||
Reference in New Issue
Block a user