More codestyle changes

This commit is contained in:
Jaime van Kessel 2016-02-15 14:28:27 +01:00
parent 9bf783df4d
commit 5381c9c74b

View file

@ -138,7 +138,7 @@ class ImageReader(MeshReader):
# initialize to texel space vertex offsets. # initialize to texel space vertex offsets.
# 6 is for 6 vertices for each texel quad. # 6 is for 6 vertices for each texel quad.
heightmap_vertices = numpy.zeros((width_minus_one * height_minus_one, 6, 3), dtype=numpy.float32) heightmap_vertices = numpy.zeros((width_minus_one * height_minus_one, 6, 3), dtype = numpy.float32)
heightmap_vertices = heightmap_vertices + numpy.array([[ heightmap_vertices = heightmap_vertices + numpy.array([[
[0, base_height, 0], [0, base_height, 0],
[0, base_height, texel_height], [0, base_height, texel_height],
@ -146,9 +146,9 @@ class ImageReader(MeshReader):
[texel_width, base_height, texel_height], [texel_width, base_height, texel_height],
[texel_width, base_height, 0], [texel_width, base_height, 0],
[0, base_height, 0] [0, base_height, 0]
]], dtype=numpy.float32) ]], dtype = numpy.float32)
offsetsz, offsetsx = numpy.mgrid[0:height_minus_one, 0:width-1] offsetsz, offsetsx = numpy.mgrid[0: height_minus_one, 0: width - 1]
offsetsx = numpy.array(offsetsx, numpy.float32).reshape(-1, 1) * texel_width offsetsx = numpy.array(offsetsx, numpy.float32).reshape(-1, 1) * texel_width
offsetsz = numpy.array(offsetsz, numpy.float32).reshape(-1, 1) * texel_height offsetsz = numpy.array(offsetsz, numpy.float32).reshape(-1, 1) * texel_height