Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve Rendering code #9

Open
Rinnegatamante opened this issue Mar 25, 2016 · 3 comments
Open

Improve Rendering code #9

Rinnegatamante opened this issue Mar 25, 2016 · 3 comments

Comments

@Rinnegatamante
Copy link
Owner

In some games, renderer is too heavy and makes such games completely unplayable on O3DS (6-7 fps).

A suggestion could be to trying swapping from libsf2d to libcitro3d and seeing if it's faster.

@Cruel
Copy link

Cruel commented Mar 30, 2016

The GPU portion of the render seems pretty negligible. Most the rendering is done in software by pixman and rest of easyrpg core. The only slow part of sf2d was the software texture conversion which you already changed. I don't see citro3d helping at all, there is going to have to be a more elaborate change which may not be worth the effort.

@Rinnegatamante
Copy link
Owner Author

citro3D can help a lot at least for shaders usage (since if i'm not wrong, sf2dlib doesn't allow shaders swapping ) for some CPU intensive calculations like HARD_LIGHT_OP used for screen tone ( #11 )

@Ghabry
Copy link

Ghabry commented Mar 31, 2016

The way the rendering code of the Player is designed makes it not really usable for hardware rendering. This should be refactored someday :/.

Because the GPU of the 3DS can directly access normal RAM you save the slow up/download and you can probably just ask the GPU to do most blitting operations instead of Pixman.
I don't know how to use GPU_COMBINEFUNC but GPU_ADD sounds like OP_OVERLAY and GPU_REPLACE like OP_SRC. Maybe they can be used instead. But at least on the map most blit operations are just 16x16 pixel, so issuing the command to the GPU takes longer then the operation I assume.

I'm also not really good in 3D programming. I play around a bit with OpenGL before I dare to touch citro3d.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants