Getting Started
Pages 14
-
3.1. CoreModifiable
3.1.1. Upgrador
3.2. Attributes
3.3. Methods
3.4. CoreItem
3.6. Lua Binding
-
Other Modules
4.1. FileManager
4.2. Timer
4.3. 2DLayers
4.4. Collision
4.5. GUI
4.6. Input
4.7. SceneGraph
4.8. Renderer
Clone this wiki locally
Prerequisites
In all cases, a recent version of CMake (>3.15.5) is needed.
Windows platform
Our scripts need Visual Studio C++ 2019 (Community edition is OK).
HTML5 platform
Emscripten must be correctly installed on a Linux system or in WSL ( Windows subsystem for Linux ).
Android platform
The tools for Visual Studio C++ mobile development must be installed and a recent Android NDK.
Building projects
Windows platform
Go to the kigs\scripts folder and launch one of the following script :
- generateWinCMake.bat for the generation of win32 (OpenGL) applications
- generateWinCMake64.bat for the generation of win64 (OpenGL) applications
- generateWinD3DCMake.bat for the generation of win32 (D3D) applications
- generateWinD3DCMake64.bat for the generation of win64 (D3D) applications
- generateWUPD3DCMake.bat for the generation of Universal Windows Platform D3D applications ( only for graphical data driven project )
- generateWUPD3DCMakeARM.bat for the generation of Universal Windows Platform ARM D3D applications (Hololens 2)
- generateWUPD3DCMakeARM64.bat for the generation of Universal Windows Platform ARM64 D3D applications (Hololens 2)
A new Build[solutionType] folder is created at the same level as kigs folder.
Browse in this folder to reach Build[solutionType]\kigs\projects\ProjectName and choose ProjectName.sln to open it in Visual Studio.
Once the solution is loaded in Visual Studio, set "ProjectName" as your start-up project, choose the build configuration you want :
- StaticDebug : for a compilation with full debug info and no optimization
- StaticReleaseTools : for a compilation with optimizations, but keeping all the export functionalities
- StaticRelease : for full optimizations but no export functionality
Build, launch. That's it.
HTML5 platform
After Emscripten and CMake were correctly installed (Linux or WSL environment), open a terminal and go to the kigs\scripts folder.
launch :
./generateEmscriptenCMake.sh
A new Build\solutionEmscriptenCMake folder is created at the same level as kigs folder.
Navigate to StaticDebug\kigs\projects\ProjectName or StaticReleaseTools\kigs\projects\ProjectName or StaticRelease\kigs\projects\ProjectName folder in your terminal. Generally, it's easier to develop/debug a Win32 application, and then to build a StaticRelease version of the HTML5 application.
Build with the command :
emmake make
At the end of the build, ProjectName.js, ProjectName.wasm and ProjectName.data have been generated. Copy those files to your ProjectName directory where an index.html and indexDebug.html are present. Open index.html or indexDebug.html in a Webbrowser.
Android platform
Go to the kigs\scripts folder and launch the following script :
- generateAndroidCMakeVS.bat
A new Build\solutionAndroidVSCMake folder is created at the same level as kigs folder.
Browse in this folder to reach Build\solutionAndroidVSCMake\kigs\projects\ProjectName and choose ProjectName.sln to open it in Visual Studio.
Once the solution is loaded in Visual Studio, set "kigs.ProjectName.Packaging" as your start-up project, choose the build configuration you want :
- StaticDebug : for a compilation with full debug info and no optimization
- StaticReleaseTools : for a compilation with optimizations, but keeping all the export functionalities
- StaticRelease : for full optimizations but no export functionality
Connect your Android device ( or Android simulator ).
Build, launch. That's it.
Creating a new project
Go to the kigs\projects folder. Launch one of the two present scripts : CreateNewConsoleProject.vbs (for a command line type project) or CreateNewDDProject.vbs (for a graphical data driven project).
Enter a name for the project : a new folder with this name will be created. For example "SimpleTest" and press OK.
Now open "kigs\projects\CMakeLists.txt" file in a text editor and add the line :
add_subdirectory(MyProjectName)
replacing "MyProjectName" by the name of the project (SimpleTest in our example).
Save and close "CMakeLists.txt" file.
Then go to kigs\scripts and launch the script corresponding to the platform you want to build for ( see Building projects )
Kigs framework Wiki - kigs-framework.org