Fix black dotted lines in night rendermode.
Also reduces the night rendermode render time by a 10% and increses the lighting rendermode render time by a 5% (globally it reduces the render time).
This commit is contained in:
@@ -227,6 +227,24 @@ do_shading_with_mask(RenderModeLighting *self, RenderState *state,
|
|||||||
/* this face isn't visible, so don't draw anything */
|
/* this face isn't visible, so don't draw anything */
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
} else if ((x == -1) && (state->left_blocks != Py_None)) {
|
||||||
|
unsigned char block = getArrayByte3D(state->left_blocks, 15, state->y, state->z);
|
||||||
|
if (!is_transparent(block)) {
|
||||||
|
/* the same thing but for adjacent chunks, this solves an
|
||||||
|
ugly black doted line between chunks in night rendermode.
|
||||||
|
This wouldn't be necessary if the textures were truly
|
||||||
|
tessellate-able */
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
} else if ((y == 16) && (state->right_blocks != Py_None)) {
|
||||||
|
unsigned char block = getArrayByte3D(state->right_blocks, state->x, 0, state->z);
|
||||||
|
if (!is_transparent(block)) {
|
||||||
|
/* the same thing but for adjacent chunks, this solves an
|
||||||
|
ugly black doted line between chunks in night rendermode.
|
||||||
|
This wouldn't be necessary if the textures were truly
|
||||||
|
tessellate-able */
|
||||||
|
return;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
black_coeff = get_lighting_coefficient(self, state, x, y, z);
|
black_coeff = get_lighting_coefficient(self, state, x, y, z);
|
||||||
|
|||||||
Reference in New Issue
Block a user