From: mfranz Date: Tue, 11 Apr 2006 21:32:15 +0000 (+0000) Subject: add minimalistic backside to signs as a temporary solution X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=9d9610a88252c91a1384c97abb2a88a9ece0da08;p=simgear.git add minimalistic backside to signs as a temporary solution --- diff --git a/simgear/scene/tgdb/apt_signs.cxx b/simgear/scene/tgdb/apt_signs.cxx index ef2e384d..e4d9fb57 100644 --- a/simgear/scene/tgdb/apt_signs.cxx +++ b/simgear/scene/tgdb/apt_signs.cxx @@ -308,6 +308,23 @@ ssgBranch *sgMakeTaxiSign( SGMaterialLib *matlib, delete element; } + + // minimalistic backside + ssgVertexArray *vl = new ssgVertexArray(4); + vl->add(hpos, 0, dist); + vl->add(hpos - total_width, 0, dist); + vl->add(hpos, 0, dist + sign_height); + vl->add(hpos - total_width, 0, dist + sign_height); + + ssgNormalArray *nl = new ssgNormalArray(1); + nl->add(0, 1, 0); + + ssgLeaf *leaf = new ssgVtxTable(GL_TRIANGLE_STRIP, vl, nl, 0, 0); + SGMaterial *mat = matlib->find("BlackSign"); + if (mat) + leaf->setState(mat->get_state()); + object->addKid(leaf); + return object; }