Overview
QuickGame is an API written in C that promotes the rapid development of games for the PSP without extensive knowledge of the PSP hardware and APIs. To set up, you will need a git repository, CMake and the PSP Toolchain installed.
Adding QuickGame
To add to your project, first navigate to the directory in which your git repository is stored. Next:
git submodule add https://github.com/IridescentRose/QuickGame git submodule update --init --recursive
This will clone QuickGame into your project and recursively initalize it. You're now good to move onto the CMakeLists.txt
CMake
To add to an existing CMakeLists (for example from the CMake Tutorial), you'll only need 3 lines of code.
add_subdirectory(./QuickGame/ QuickGame) target_link_libraries(project_name PUBLIC QuickGame) target_include_directories(project_name PUBLIC QuickGame/include)
With that, you should be good to go!
Example Code
#include <QuickGame.h> int main(int argc, char** argv){ if(QuickGame_Init() < 0) return 1; QuickGame_Graphics_Set2D(); while(QuickGame_Running()){ QuickGame_Graphics_Start_Frame(); QuickGame_Graphics_Clear(); QuickGame_Graphics_End_Frame(true); } QuickGame_Terminate(); return 0; }
This basic sample should result in a blank screen drawing in an infinite loop until you exit manually. It initializes the API, sets our mode to 2D mode, runs a loop to start a frame, clear, and end the frame, and then terminate.