Implement primitive drawing methods for Emscripten

This commit is contained in:
James Gregory 2013-04-22 18:08:25 -07:00
parent 92e4c76f20
commit 7b04e6b0e7
1 changed files with 0 additions and 13 deletions

View File

@ -140,9 +140,6 @@ void ccDrawPoint( const CCPoint& point )
glVertexAttribPointer(kCCVertexAttrib_Position, 2, GL_FLOAT, GL_FALSE, 0, &p);
#endif // EMSCRIPTEN
#ifdef EMSCRIPTEN
printf("WARNING: %s does not have client-side buffer fix for Emscripten\n", __func__);
#endif // EMSCRIPTEN
glDrawArrays(GL_POINTS, 0, 1);
CC_INCREMENT_GL_DRAWS(1);
@ -178,7 +175,6 @@ void ccDrawPoints( const CCPoint *points, unsigned int numberOfPoints )
newPoints[i].x = points[i].x;
newPoints[i].y = points[i].y;
}
#ifdef EMSCRIPTEN
// Suspect Emscripten won't be emitting 64-bit code for a while yet,
// but want to make sure this continues to work even if they do.
@ -189,9 +185,6 @@ void ccDrawPoints( const CCPoint *points, unsigned int numberOfPoints )
#endif // EMSCRIPTEN
}
#ifdef EMSCRIPTEN
printf("WARNING: %s does not have client-side buffer fix for Emscripten\n", __func__);
#endif // EMSCRIPTEN
glDrawArrays(GL_POINTS, 0, (GLsizei) numberOfPoints);
CC_SAFE_DELETE_ARRAY(newPoints);
@ -255,9 +248,6 @@ void ccDrawPoly( const CCPoint *poli, unsigned int numberOfPoints, bool closePol
ccGLEnableVertexAttribs( kCCVertexAttribFlag_Position );
#ifdef EMSCRIPTEN
printf("WARNING: %s does not have client-side buffer fix for Emscripten\n", __func__);
#endif // EMSCRIPTEN
// iPhone and 32-bit machines optimization
if( sizeof(CCPoint) == sizeof(ccVertex2F) )
{
@ -338,9 +328,6 @@ void ccDrawSolidPoly( const CCPoint *poli, unsigned int numberOfPoints, ccColor4
#endif // EMSCRIPTEN
}
#ifdef EMSCRIPTEN
printf("WARNING: %s does not have client-side buffer fix for Emscripten\n", __func__);
#endif // EMSCRIPTEN
glDrawArrays(GL_TRIANGLE_FAN, 0, (GLsizei) numberOfPoints);
CC_SAFE_DELETE_ARRAY(newPoli);