Changing the rendering resolution while maintaining the design layout

Posted by Coyote on Game Development See other posts from Game Development or by Coyote
Published on 2013-06-29T08:24:44Z Indexed on 2013/06/29 10:30 UTC
Read the original article Hit count: 236

Filed under:
|

I would like to increase the FPS of my project.

Currently I would like to try reducing the resolution at which the scenes are rendered.

Let's say I never want to draw more than 1280*720. What ever the real resolution is. How should I proceed?

I tried pEGLView->setFrameSize(1280, 720); but only reduces the displayed size of the frame on screen (boxing).

In my activity I tried setting the size of the "surface" but this seems to completely break the layout (as defined by setDesignResolutionSize).

@Override
public Cocos2dxGLSurfaceView onCreateView() {
    Cocos2dxGLSurfaceView surfaceView = new Cocos2dxGLSurfaceView(this);
    surfaceView.getHolder().setFixedSize(1280, 720);
    return surfaceView;
}

Is there a way to simply change the rendered

© Game Development or respective owner

Related posts about cocos2d-x

Related posts about resolution