Quantcast
Channel: openFrameworks - Latest posts
Viewing all articles
Browse latest Browse all 40524

Best way to draw an array of objects

$
0
0
poly.arc(0, 0, radius, radius, 0, 360);

for(int i=0; i<poly.getVertices().size(); i++){
    mesh.addVertex(poly[i]);
    mesh.addVertex(poly[i+1]);
    mesh.addVertex(ofVec3f(0,0));
}

Something i just noticed here

mesh.addVertex(poly[i+1]);

Shouldn't this line throw an out of bounds error ?
It seems it doesn't...


Viewing all articles
Browse latest Browse all 40524

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>