www

Unnamed repository; edit this file 'description' to name the repository.
Log | Files | Refs

commit ae0b4241a1ae2b0269da34284a9452e847daa00b
parent 474ab3e7069bb73b06662eab4c38dc7140aa4c0f
Author: Yoann <yoann.b87@voila.fr>
Date:   Tue, 10 Jan 2012 16:49:44 +0100

Correction d'un bug sur les toits.

Diffstat:
Mrules/batiment/batimentquadtoit.cpp | 4++--
1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/rules/batiment/batimentquadtoit.cpp b/rules/batiment/batimentquadtoit.cpp @@ -13,7 +13,7 @@ void BatimentQuadToit::triangulation() { if(type == 1) { if(c.minLengthNS() < c.minLengthEW()) c = c << 1; - c = c.inset(S, -20).inset(S,-20); + c = c.inset(N, -20).inset(S,-20); height = c.minLengthEW() / 5; Vertex ce = c[SE] + (c[NE] - c[SE])/2 + Vertex(0,0,height); Vertex cw = c[SW] + (c[NW] - c[SW])/2 + Vertex(0,0,height); @@ -21,7 +21,7 @@ void BatimentQuadToit::triangulation() { addGPUTriangle(c[NW],cw,c[SW],0xF1,0xE0,0xE0); addGPUTriangle(c[SE],ce,c[NE],0xF1,0xE0,0xE0); - addGPUQuad(c,0xF1,0xE0,0xE0); + addGPUQuad(c[NE],c[NW],c[SW],c[SE],0xF1,0xE0,0xE0); addGPUQuad(c[NE],c[NW],cw,ce,0xE0,0x20,0x00); addGPUQuad(c[SW],c[SE],ce,cw,0xE0,0x20,0x00); }