mirror of
https://github.com/InsightGit/Morpheus.git
synced 2025-06-19 09:15:36 -04:00
155 lines
6.6 KiB
ReStructuredText
155 lines
6.6 KiB
ReStructuredText
============================
|
|
Morpheus buildtool reference
|
|
============================
|
|
|
|
Note: all of the Python 3 buildtools (or scripts) listed here are
|
|
labeled with their folder's name within the buildtools directory.
|
|
|
|
------------------
|
|
General buildtools
|
|
------------------
|
|
|
|
General buildtools are frequently used tools both in
|
|
compiling Morpheus and developing Morpheus games. They are included
|
|
within the release/dev packages found on itch and can also be
|
|
accessed through the GitHub or GitLab code repositories.
|
|
|
|
^^^^^^^^^^^^^^
|
|
bintileconvert
|
|
^^^^^^^^^^^^^^
|
|
|
|
Bintileconvert is used for converting regular non-streaming
|
|
backgrounds raw .bin binary tile map files
|
|
(specifically tested with `Tilemap Studio <https://github.com/Rangi42/tilemap-studio>`_)
|
|
to .c and .h files usable with Morpheus. You can use this buildtool by calling CMake
|
|
Morpheus utils function convert_tilemap_bin_image_file().
|
|
|
|
Buildtool arguments:
|
|
|
|
* *tilemap_studio_bin_file_path*: The file path to the tilemap .bin file to convert
|
|
* *build_dir*: The current build directory to place the generate .c and .h files in
|
|
* *width*: The width of the tilemap (in 8X8 TILES, NOT PIXELS) (32 or 64)
|
|
* *height*: The height of the tilemap (in 8X8 TILES, NOT PIXELS) (32 or 64)
|
|
|
|
Optional buildtool arguments:
|
|
|
|
* *palette_bank*: The [0-16] palette bank number to use for the entire tilemap
|
|
* *image_file*: The image file of the tilemap file's tiles to be converted using grit
|
|
* *image_bpp*: The 4, 8, or 1 bpp of the image file. This argument becomes required if image_file is passed in.
|
|
* *is_affine*: Whether this tilemap should be affine or not.
|
|
|
|
^^^^^^^^^^^^
|
|
bintilesplit
|
|
^^^^^^^^^^^^
|
|
|
|
Bintilesplit is used for converting one large 128x128, 256x256, or 512x512 background
|
|
into several smaller 64x64 backgrounds usable with StreamingBackgroundBase,
|
|
with a tilemap using the same raw binary tilemap format as in bintileconvert uses. You can
|
|
use this buildtool by calling CMake Morpheus utils function generate_streaming_background().
|
|
|
|
Buildtool arguments:
|
|
|
|
* *single_bin_file_path*: The large raw .bin binary background tilemap file
|
|
* *asset_dir*: The directory to produce the split 64x64 bin files used
|
|
* *width*: The width of the entire background (in 8X8 TILES, NOT PIXELS) (128, 256, or 512)
|
|
* *height*: The height of the entire background (in 8X8 TILES, NOT PIXELS) (128, 256, or 512)
|
|
|
|
Optional buildtool arguments:
|
|
|
|
* *palette_bank*: The [0-16] palette bank number to use for the entire tilemap
|
|
* *image_file*: The image file of the tilemap file's tiles to be converted using grit
|
|
* *image_bpp*: The 4, 8, or 1 bpp of the image file. This argument becomes required if image_file is passed in.
|
|
* *build_dir*: The current build directory to place the generate .c and .h files in
|
|
|
|
^^^^^^^^^^^^^
|
|
gba_fat_patch
|
|
^^^^^^^^^^^^^
|
|
|
|
Gba_fat_patch is used for applying a one-line header file patch to libgba's bundled
|
|
libfat library to prevent conflicts with libtonc while still being able to use libfat. If you
|
|
use the project template's CMakeLists.txt file, the patch will be handled automatically upon
|
|
the first build (though it might require superuser priviledges if running on Linux/macOS). If
|
|
you are making your own custom CMakeLists.txt file, use this buildtool by calling
|
|
libgba_fat_patch() and adding the libgba_fat_patch_target target as a dependency to your project
|
|
by using CMake's add_dependencies().
|
|
|
|
No arguments for this buildtool.
|
|
|
|
^^^^^^^^^^^^^^
|
|
generate_fonts
|
|
^^^^^^^^^^^^^^
|
|
|
|
Generate_fonts is used for converting a .ttf file and a .txt file containing a list of characters
|
|
into a font image which is then converted to .c and .h files by grit usable with Morpheus's
|
|
Expression text API. You can use this buildtool by calling the CMake Morpheus utils function
|
|
generate_font().
|
|
|
|
|
|
Buildtool arguments:
|
|
|
|
* *ttf_font_file*: The path to .ttf font file containing the appropriate glyphs
|
|
* *font_character_list_file*: The path or filename under buildtools/generate_fonts/character_lists/ for the list of characters seperated by spaces to be included
|
|
* *font_bpp*: The 1, 4, or 8 bpp of the font image to generate
|
|
* *destination_file*: The path and filename of the font image's .c and .h files being generated
|
|
* *make_1d*: Whether to make the font image use 1d or 2d mapping (currently only 2d mapping is supported by
|
|
the expression API)
|
|
* *use_utf8*: Whether this font is a UTF8 font containing non-ASCII/non-english characters(True) or a pure ASCII font (False)
|
|
|
|
Optional buildtool arguments:
|
|
|
|
* *background_color_r*: The red color component of the generated font image's background color
|
|
* *background_color_g*: The green color component of the generated font image's background color (required if background_color_r is given)
|
|
* *background_color_b*: The blue color component of the generated font image's background color (required if background_color_g is given)
|
|
* *font_size*: The font size of the characters generated within the font image, defaults to 16
|
|
|
|
^^^^^^^^^^^^^^^^^
|
|
project_generator
|
|
^^^^^^^^^^^^^^^^^
|
|
|
|
Project_generator is used for generating a project based on a default project template to get
|
|
started, with all appropriate buildtools copied over as well as a starter CMakeLists.txt preset
|
|
and an example "Hello World" project.
|
|
|
|
Buildtool arguments:
|
|
|
|
* *morpheus_dir_path*: The path to the root Morpheus release/dev/source package directory
|
|
* *new_project_name*: The name of the new project to be created
|
|
|
|
Optional buildtool arguments:
|
|
|
|
* *new_project_dir_path*: The path to the directory where the new project's directory should be created.
|
|
|
|
-------------------
|
|
Internal buildtools
|
|
-------------------
|
|
|
|
Internal buildtools are frequently used tools in compiling Morpheus,
|
|
but don't serve much purpose when developing Morpheus games. Thus,
|
|
they are **NOT** included within the release/dev package found on
|
|
itch and can only be accessed through the GitHub or GitLab
|
|
code repositories.
|
|
|
|
^^^^^^^^^^^^^^^^^^^^
|
|
generate_breathe_rst
|
|
^^^^^^^^^^^^^^^^^^^^
|
|
|
|
Generates `Breathe <https://github.com/michaeljones/breathe>`_-style
|
|
RestructedText files for the doxygen-documented Morpheus C++ classes,
|
|
used in the Documentation target for generation of C++ documentation.
|
|
|
|
Buildtool arguments:
|
|
|
|
* *header_path*: The path to the root directory of the headers to be documented
|
|
* *root_namespace*: The name of the root namespace of the headers to be documented (morpheus)
|
|
* *breathe_path*: The path to the directory where the breathe documentation will be generated in
|
|
|
|
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
|
generate_cd_release (Shell script)
|
|
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
|
|
|
A shell script that is part of this project's GitLab continuous deployment pipeline,
|
|
deploying a release/dev package to itch.io.
|
|
|
|
|
|
No arguments for this buildtool.
|