From 6c097aea994335e2c1f84a2c64461aeda7509f06 Mon Sep 17 00:00:00 2001 From: XorTroll Date: Sat, 23 Mar 2019 14:53:48 +0100 Subject: [PATCH] Improved README --- README.md | 37 ++++++++++++++++++++++++++++--------- 1 file changed, 28 insertions(+), 9 deletions(-) diff --git a/README.md b/README.md index 3f4fb979..fe638286 100644 --- a/README.md +++ b/README.md @@ -8,13 +8,13 @@ It uses libnx and SDL2, so both libraries are required. To be more exact, this libraries should be installed via pacman: -``` --lnx -lfreetype -lSDL2_ttf -lSDL2_gfx -lSDL2_image -lSDL2 -lEGL -lGLESv2 -lglapi -ldrm_nouveau -lpng -ljpeg `sdl2-config --libs` `freetype-config --libs` +```sh +pacman -S switch-sdl2 switch-sdl2_ttf switch-sdl2_gfx ``` ## Internal structure and performance -Plutonium uses software-accelerated SDL2 rendering. +Plutonium uses SDL2 (SDL2 via OpenGL) rendering. Plutonium's performance is based on WPF's system. The user doesn't directly interact with the rendering, as it's done via a main rendering system and different objects to render. @@ -30,19 +30,38 @@ Check the [documentation](https://XorTroll.github.io/Plutonium/) for a more deta On the [releases](https://github.com/XorTroll/Plutonium/releases) page you have all the released versions. All of them are zipped files, containing `include` and `lib` directories. -To link them to a devkitPro libnx project, on the `LIBDIRS` variable of the Makefile add the folder containing the two folders mentioned above. (if you set `plutonium`, place the other two folders as `plutonium/include` and `plutonium/lib`) +### Simple project layout + +This is how a regular Plutonium project would (more or less) have its Makefile and project layout using Plutonium: + +- Makefile -Include the main header: +```Makefile +... -```cpp -#include +LIBS := -lpu -lfreetype -lSDL2_ttf -lSDL2_gfx -lSDL2_image -lSDL2 -lEGL -lGLESv2 -lglapi -ldrm_nouveau -lpng -ljpeg `sdl2-config --libs` `freetype-config --libs` -lnx +LIBDIRS := $(PORTLIBS) $(LIBNX) $(CURDIR)/Plutonium + +... ``` -And don't forget to add the libraries mentioned in the first section! +- Project directory + +```txt +Project + | + |-- Makefile + |-- source + |-- include + |-- Plutonium + | + |-- include + |-- lib +``` ## Building -Clone the repository, go into `Plutonium` directory and run `make`. +Clone the repository, cd into `Plutonium` directory and run `make`. You will need devkitPro, libnx and all the libraries mentioned above installed via pacman.