MCPcopy Create free account
hub / github.com/BZFlag-Dev/bzflag / draw

Method draw

tools/modeltool/modeltool.cpp:1636–1650  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1634#ifdef _MODEL_TOOL_GFX
1635
1636void CMesh::draw() {
1637 // do the material here
1638 glColor4f(1, 1, 1, 1);
1639
1640 for (int f = 0; f < (int)faces.size(); f++) {
1641 CFace& face = faces[f];
1642
1643 glBegin(GL_POLYGON);
1644 for (int v = 0; v < (int)face.verts.size(); v++) {
1645 glNormal3f(normals[face.normals[v]].x, normals[face.normals[v]].y, normals[face.normals[v]].z);
1646 glVertex3f(verts[face.verts[v]].x, verts[face.verts[v]].y, verts[face.verts[v]].z);
1647 }
1648 glEnd();
1649 }
1650}
1651
1652void CModel::draw() {
1653 for (int i = 0; i < (int)meshes.size(); i++) {

Callers 2

drawModelsMethod · 0.45
drawViewMethod · 0.45

Calls 1

sizeMethod · 0.45

Tested by

no test coverage detected