 <p>From the cocos2d <a href="http://github.com/cocos2d/cocos2d-iphone/blob/454d1753ea73b37dbde4d686a876a542a65e4677/tests/drawPrimitivesTest.m" rel="nofollow noreferrer">drawPrimitivesTest.m</a>:</p> <pre><code>- (void)draw { // ... // draw a simple line // The default state is: // Line Width: 1 // color: 255,255,255,255 (white, non-transparent) // Anti-Aliased glEnable(GL_LINE_SMOOTH); ccDrawLine( ccp(0, 0), ccp(s.width, s.height) ); // ... } </code></pre>