I don't know if BYOND has moved away from OpenGL but if they haven't it'd be nice to allow us access to OpenGL functions such as enabling the GL_SCISSOR_TEST and allowing us to change how the screen is drawn. My goal for this would be to create a split screen. I don't know how it's set up it BYOND but it's easy enough to do in Objective-C that I don't see it being a problem giving us more control over how the screen is drawn.
Here is an example of one of the split screens in Objective-C using the cocos2D lib:
-(void) visit
{
CGSize bounds = [[CCDirector sharedDirector] winSize];
glEnable(GL_SCISSOR_TEST);
glPushMatrix();
CGPoint point = camera1;
self.anchorPoint = ccp(point.x/bounds.height, point.y/bounds.width);
self.position = ccpAdd(ccp(bounds.height * 0.5,bounds.width * 0.25),ccp(-point.x, -point.y));
glScissor(0,0,bounds.height,bounds.width / 2);
glTranslatef(bounds.width, 0, 0);
glRotatef(90.0f, 0.0f, 0.0f, 1.0f);
[super visit];
glPopMatrix();
...
glDisable(GL_SCISSOR_TEST);
}
ID:651161
Apr 9 2012, 10:27 pm
|
|||||||
| |||||||