Topic: PSVita Port

Forum: General Topics

6 posts · 11024 views

devuser1
Posts: 4
Joined: 22.04.2022, 16:32:27

Hello Guys,
i wanted to show off my Sony playstation vita port (https://github.com/PSVita-Dev/FreeRCT-Vita) using vitasdk (https://github.com/vitasdk)
you can find my first build in the releases tab. Note: it didnt have touchscreen support at the time so i will release a new build as soon as i get the main issue fixed.

the issue is that pixel blitting is too slow on the vita so it is only 2fps.
i might try switching to vita2d (https://github.com/xerpi/libvita2d)
which has functions like
-vita2d_draw_pixel
-vita2d_draw_line
-vita2d_draw_rectangle
-vita2d_set_clip_rectangle
and many more.

i also really wanted to thank the devs for this awesome project!

Newbyte
Posts: 1
Joined: 24.04.2022, 17:37:19

Nice job! Have you considered sending a pull request with your work to the main repository?

devuser1
Posts: 4
Joined: 22.04.2022, 16:32:27

Newbyte wrote:


Nice job! Have you considered sending a pull request with your work to the main repository?

yes, i might do it when i fixed the rendering / blitting algorithm.

devuser1
Posts: 4
Joined: 22.04.2022, 16:32:27

Hello, i was updating the port to match the new opengl standards.
Altough (before loading opengl) it gives me this error :
terminate called after throwing an instance of 'std::bad_alloc'
what(): std::bad_alloc
I have gotten the same error in a test PSP port back then, but now i also get it on the vita update.
Help welcome!
P.S. Nordfriese, i would like to know where you updated something that may have to do something with it. Thanks!
devuser1(psvita-dev)

Nordfriese
Administrator
Posts: 19
Joined: 07.02.2022, 19:27:49

Can you try running the code in a debugger such as GDB to get a backtrace for the crash (ideally compiled as a debug build) and post it here? That will help a lot with finding out where this is coming from.

One thing I can think of that might be a problem is preallocation of large memory batches especially in the text renderer, but without a trace this is just random guessing. The move to OpenGL changed a lot of code paths…

devuser1
Posts: 4
Joined: 22.04.2022, 16:32:27

Hello, sorry it was my fault i only allocated 150mb in that build (you have to manually set it when using the opengl driver with the vita) i have set it to 250mb now and it works (atleast goes further) i need to fix the glfw stuff.
That also makes sense given the psp only has 64mb ram in total it wont work.

Thanks, devuser1