Compare commits

..

198 Commits

Author SHA1 Message Date
Sven Balzer 3a8adac185 add water collision
buildbot/windows Build done.
buildbot/linux Build done.
2026-08-07 20:02:30 +02:00
Sven Balzer 3f9f154939 add collision to placeables
buildbot/windows Build done.
buildbot/linux Build done.
2026-08-07 19:11:14 +02:00
Sven Balzer ecd6571785 rename Tree to placeable and dynamically load size
buildbot/windows Build done.
buildbot/linux Build done.
add stone variants as placeables
2026-08-06 19:45:47 +02:00
Sven Balzer ff82f59fdf add world list editor
buildbot/windows Build done.
buildbot/linux Build done.
change default tree ti tree_standard_tile_angle.png
2026-08-06 18:20:04 +02:00
Sven Balzer 963ccc4ec8 change rendering offsets for character, character shadow and trees
buildbot/windows Build done.
buildbot/linux Build done.
change default camera tilt
2026-08-05 21:50:13 +02:00
Sven Balzer 4c158f25f0 add trees into the game
buildbot/windows Build done.
buildbot/linux Build done.
2026-08-05 20:48:57 +02:00
Sven Balzer 6a984b40d9 remove vertex_buffer and index_buffer for characters and character shadows
refactor world shader vertex position calculation
2026-08-05 20:48:57 +02:00
Ammerhai 74d55cb087 update female character sprite sheet
buildbot/windows Build done.
buildbot/linux Build done.
2026-08-05 20:39:59 +02:00
Ammerhai 8f277c4d08 add correct tree angle
buildbot/windows Build done.
buildbot/linux Build done.
2026-08-05 20:39:09 +02:00
Sven Balzer 3366008d59 replace placeholder character with female
buildbot/windows Build done.
buildbot/linux Build done.
2026-08-03 18:36:40 +02:00
Ammerhai e49683eb7b update tree again
buildbot/windows Build done.
buildbot/linux Build done.
2026-08-03 18:34:49 +02:00
Ammerhai d04e231f4d update tree
buildbot/windows Build done.
buildbot/linux Build done.
2026-08-03 18:28:41 +02:00
Ammerhai 198ed44bbf add character female
buildbot/windows Build done.
buildbot/linux Build done.
2026-08-03 18:28:14 +02:00
Sven Balzer 7fe5419b02 fix leak of frame_fence in sdlgpu renderer
buildbot/windows Build done.
buildbot/linux Build done.
2026-08-03 17:32:57 +02:00
Sven Balzer 6aa530daea rename basic shader to character
buildbot/windows Build done.
buildbot/linux Build done.
add character shadow
make animation play twice as fast when sprinting
2026-08-03 13:32:52 +02:00
Ammerhai 4f4ec3cfd5 remove map layout
buildbot/windows Build done.
buildbot/linux Build done.
2026-08-02 13:20:08 +02:00
Sven Balzer e5cc22cb95 also respect arrow keys for continuous movement
buildbot/windows Build done.
buildbot/linux Build done.
2026-08-02 13:06:37 +02:00
Ammerhai b9eb121663 add last tile and tree
buildbot/windows Build done.
buildbot/linux Build done.
add water starter

#8
2026-08-02 12:56:13 +02:00
Sven Balzer f72ca9def5 add basic animation
buildbot/windows Build done.
buildbot/linux Build done.
2026-08-02 12:40:24 +02:00
Sven Balzer 70fac5bd72 fix clamping character movement to map boundaries 2026-08-02 10:57:59 +02:00
Ammerhai ab79875263 remove placeholder tiles
buildbot/windows Build done.
#8
2026-08-01 20:23:42 +02:00
Ammerhai 3a012fc564 fix incorrect tile corner infos
#8
2026-08-01 20:09:47 +02:00
Ammerhai bd727a6505 add correct tile values
#8
2026-08-01 19:39:07 +02:00
Ammerhai da801d1937 add region map day/night
add first two starter mons

- fire/feuer
- grass/pflanze
2026-08-01 19:38:10 +02:00
Ammerhai 1b03990f92 add new tiles and change paths to new ones
#8
2026-08-01 19:37:41 +02:00
Sven Balzer d2b472548f move per_frame and view_projection matrix into shared file 2026-08-01 13:36:30 +02:00
Sven Balzer 0c7ec7299e basic smooth movement 2026-08-01 12:37:53 +02:00
Sven Balzer f564c14354 change grid shader primitive to line from triangle 2026-08-01 09:37:43 +02:00
Sven Balzer 08b8b397e2 fix explicitly changing tiles 2026-08-01 09:07:45 +02:00
Sven Balzer e6fa28a18f make shaders be compiled by cmake instead of a script 2026-08-01 09:07:01 +02:00
Ammerhai 1ff65cd811 update map 2026-07-28 18:44:26 +02:00
Sven Balzer f3dcd26ce7 move framebuffer management from the renderer to the app 2026-07-03 14:42:20 +02:00
Sven Balzer 18c1b3639c remove old shaders 2026-07-03 14:23:55 +02:00
Sven Balzer e7ad1d36ba add sdlgpu renderer 2026-07-03 14:19:41 +02:00
Sven Balzer aaa5b2078b add renderer abstraction 2026-07-03 10:14:10 +02:00
Sven Balzer f8f82bc653 add missing tile variations for water 2026-05-13 18:18:28 +02:00
Sven Balzer 8bc6f68b3b convert gpu map format from buffer to texture2d 2026-05-01 19:55:39 +02:00
Sven Balzer fa9190b0e5 remove vertex and index buffer from world shader 2026-05-01 19:27:57 +02:00
Sven Balzer 7cb6dbc3e6 remove rotation from world tiles and instead apply it on load into atlas 2026-05-01 19:15:03 +02:00
Sven Balzer 59cb6fb6c1 replace the name ground with dirt
append TILEKIND_ to every argument of TILE_CORNER_INFO for better readability
2026-05-01 18:31:16 +02:00
Sven Balzer 3d85440aac stop recreating the framebuffer every frame if the aspect ratio is not 1:1 2026-05-01 18:25:15 +02:00
Sven Balzer 2adf75973a update tracy from 11.0 to 13.1 and fix build with tracy enabled 2026-05-01 18:24:04 +02:00
Sven Balzer 7fa5294e02 move game settings into their own file 2026-05-01 18:13:05 +02:00
Sven Balzer 91a4a2079b decouple grid from tile picker and make it toggleable 2026-05-01 17:53:55 +02:00
Sven Balzer 2af0361ac5 fix mouse wheel zooming map when hovering imgui windows 2026-05-01 17:49:10 +02:00
Sven Balzer 7e1894984c add zoom to editor 2026-04-18 14:52:11 +02:00
Sven Balzer 53a7ed7890 make editor camera independent of player camera 2026-04-18 13:33:01 +02:00
Sven Balzer 6305d0b096 split editor and game 2026-04-17 17:22:50 +02:00
Sven Balzer ae9571d270 replace log.c/h with SDL_Log* 2026-04-15 13:29:47 +02:00
Sven Balzer ba39a0e5eb replace map width/height and player pos_x/pos_y with i32vec2 size and position respectively 2026-04-15 11:27:08 +02:00
Sven Balzer 4ec664c8db replace math_graphics with glm version 1.0.3 2026-04-15 10:50:41 +02:00
Sven Balzer 07af9deb6a update wgpu-native from v25.0.2.2 to v29.0.0.0 2026-04-14 14:12:27 +02:00
Sven Balzer 6dc54f9ef6 change map.name to be an array 2026-04-14 09:37:23 +02:00
Sven Balzer 6ac2b1fde0 set SDLMIXER_VENDORED to ON and vendor the required libraries into libs/SDL3_mixer/external
disable SDLMIXER_VORBIS_VORBISFILE
add ogg v1.3.5-SDL
add opus v1.4.x-SDL
add opusfile v0.13-git-SDL
2026-04-13 11:20:08 +02:00
Sven Balzer 85d1832a0c update dear imgui from 1.92.6-docking to 1.92.7-docking 2026-04-02 20:22:14 +02:00
Sven Balzer b549728a24 change world tiles texture from texture_2d_array to an atlas texture_2d 2026-04-02 17:52:28 +02:00
Sven Balzer 9dd37f6d40 replace the x64 specific change_map_tile() with a generic c implementation 2026-04-02 17:02:16 +02:00
Sven Balzer 8a5caf5c0d update SDL_mixer to SDL3_mixer 3.2.0 2026-04-02 16:52:07 +02:00
Sven Balzer 05b19704f8 update SDL3 from 3.2.20 to 3.4.2 2026-04-01 18:25:03 +02:00
Sven Balzer 1daf4d79f1 update dear imgui from 1.92.2b-docking to 1.92.6-docking 2026-04-01 18:20:04 +02:00
Sven Balzer 3b7d593f4e switch to reverse z and get rid of tilt sign flip 2026-04-01 18:01:39 +02:00
Ammerhai 538849e607 Update README.md 2025-10-10 23:10:09 +02:00
Sven Balzer d4c3f59921 mark functions as static 2025-10-05 11:51:11 +02:00
Sven Balzer 617a4fbfb6 allow disabling time based tinting 2025-10-04 15:43:35 +02:00
Sven Balzer 5a1ea421f6 refactor webgpu initialization into init_webgpu() 2025-10-04 13:57:16 +02:00
Sven Balzer 0d3bfaf12d start at 50% volume for all channels to allow for more user control 2025-09-29 07:09:07 +02:00
Sven Balzer 5a77a4aacb try to change to working directory on startup so assets can be found 2025-09-29 06:54:33 +02:00
Sven Balzer c3c0f8adf7 add F5 hotkey to reload tile assets 2025-09-28 07:03:41 +02:00
Sven Balzer a5c0db824b add a version to map files 2025-09-27 08:38:46 +02:00
Sven Balzer 434abdc9a7 get rid of tile_infos buffer for world shader and instead just use the vertex uvs 2025-09-26 07:22:08 +02:00
Sven Balzer dcd40b6394 add uv to vertex format and remove it from instance 2025-09-25 08:04:16 +02:00
Sven Balzer 8633cff3cb switch front faces to be CCW instead of CW 2025-09-25 06:01:16 +02:00
Sven Balzer ec34b2df61 replace SDL_GPU renderer with wgpu 2025-09-06 13:59:00 +02:00
Sven Balzer 883e13cdf5 update dear imgui from 1.91.9b to 1.92.2b 2025-08-28 05:59:13 +02:00
Sven Balzer ad651462df Update SDL3 from 3.2.4 to 3.2.20 2025-08-27 21:24:05 +02:00
Sven Balzer 6283160467 remove unnecesary initializers 2025-08-27 21:14:33 +02:00
Ammerhai c806c1a67d Update README.md 2025-04-27 17:17:03 +02:00
Ammerhai 6efb964399 add SDLMIXER_DEPS_SHARED OFF
windows - static libs
2025-04-13 13:05:06 +02:00
Sven Balzer 932d5f629d automatically play setting_off_piano.opus when no other music is playing 2025-04-03 21:47:41 +02:00
Sven Balzer 14728d17f5 add SDL_mixer 2025-04-03 04:30:22 +02:00
Ammerhai 90d167857e Update README.md
cmake building
2025-04-02 19:54:52 +02:00
Ammerhai 3630965ff5 Update README.md 2025-04-02 19:29:46 +02:00
Ammerhai 9763955288 Update README.md 2025-04-02 19:29:35 +02:00
Ammerhai d32b99e814 change audio files to opus 2025-04-02 18:58:01 +02:00
Ammerhai 41048fc43e change ogg file type
add second version
2025-04-01 22:24:32 +02:00
Sven Balzer 3bf7cf7a17 get rid of __VA_OPT__ 2025-03-31 22:09:47 +02:00
Sven Balzer 832c23f85c fix for new pipewire headers 2025-03-31 17:28:23 +02:00
Sven Balzer 716f5fc11c fix condition for grid size 2025-03-30 17:35:01 +02:00
Sven Balzer 36d69e7fa0 make TileKind grid overlap the edge of the map to allow changing edge kinds 2025-03-30 17:23:59 +02:00
Ammerhai 59f61591e1 add first music track 2025-03-27 21:33:08 +01:00
Ammerhai ebffc3f32d change order of textures for autotiling 2025-03-27 21:17:03 +01:00
Sven Balzer d3be9552c9 fix cast to __m128i 2025-03-27 20:48:25 +01:00
Sven Balzer e5d90533dd make a SameLineOrWrap helper and fix wrapping bug introduced by switching to the docking branch of imgui 2025-03-27 12:45:45 +01:00
Sven Balzer e19a13c354 remove leftover debug logging 2025-03-27 12:45:20 +01:00
Sven Balzer 9480d4e2a7 add #include <bit> for rotl and rotr 2025-03-26 22:44:21 +01:00
Sven Balzer e129469b08 add basic autotiling 2025-03-26 22:04:53 +01:00
Sven Balzer db55a510a6 remove unnecessary uv_min and uv_max from tile_info 2025-03-26 22:04:36 +01:00
Sven Balzer 382ef67895 move shaders from assets to src 2025-03-26 19:25:38 +01:00
Sven Balzer 914cbf13f4 move shader dep files to binary dir 2025-03-26 19:19:21 +01:00
Sven Balzer 06ddce6f81 factor out PixelArtSample into common.slang 2025-03-26 19:17:52 +01:00
Sven Balzer 31c4bde4bf cleanup: remove load_entire_file and m_string 2025-03-25 21:19:54 +01:00
Sven Balzer 1db5440767 change asset loading paths to not include the leading "../assets/"
move "../assets/map/*" to "../assets/maps/*"
2025-03-25 21:17:05 +01:00
Sven Balzer 9810331253 remove old map_save_file 2025-03-25 20:22:07 +01:00
Ammerhai 6f9108d563 move overworld map files 2025-03-25 19:58:00 +01:00
Sven Balzer f7915b63c7 save the load path and gpu buffer in the map struct 2025-03-25 19:33:13 +01:00
Sven Balzer 0575989142 load maps into a struct instead of a global to allow for multiple to be loaded at once 2025-03-25 18:46:35 +01:00
Sven Balzer bec0f06e59 fix grid appearing deselected when dragging a selection outside the map 2025-03-25 17:55:43 +01:00
Sven Balzer d71daba073 pass view_projection matrix directly to the shaders instead of constructing it each time 2025-03-25 17:49:30 +01:00
Sven Balzer b48b5f0339 always show grid when tile picker is open 2025-03-23 18:19:59 +01:00
Ammerhai 3f380adb0a add diagonal corner grass_ground texture 2025-03-23 18:12:25 +01:00
Ammerhai ea47ade7b3 update map 2025-03-23 15:47:16 +01:00
Sven Balzer a7635a0abf save time tints into imgui.ini and allow changing the number of tint points 2025-03-23 14:16:22 +01:00
Ammerhai 2292c049b7 add texture variations
update map and character shadow texture
2025-03-23 13:50:12 +01:00
Sven Balzer 5aba854534 deselect tile when tile picker is closed 2025-03-22 20:48:11 +01:00
Sven Balzer f33ce18429 fix for minimized window 2025-03-22 20:46:19 +01:00
Sven Balzer e774305829 add grid and highlighting of selected tiles when picking 2025-03-22 20:39:36 +01:00
Sven Balzer 4c84899084 add settings menu
remove time_offset
2025-03-22 17:08:37 +01:00
Sven Balzer ea31729a74 change max anisotropy to 16 2025-03-22 16:12:32 +01:00
Sven Balzer 002bbcd097 add a MainMenuBar and make Tile Picker and Demo Window hidden by default
use dockspace for positioning Tile Picker
2025-03-21 21:35:45 +01:00
Sven Balzer dc7c424d7f update dear imgui from 1.91.8 to 1.91.9b and switch to docking branch 2025-03-21 12:35:00 +01:00
Ammerhai fe1561d8c8 update testmap with new textures 2025-03-20 20:31:25 +01:00
Sven Balzer d9bf936f0d add basic gamepad support 2025-03-20 20:25:59 +01:00
Sven Balzer 19e75d3807 add day/night color tints 2025-03-20 19:45:19 +01:00
Ammerhai d5b01e9f40 remove todo.txt 2025-03-20 18:19:18 +01:00
Sven Balzer 3a2b156951 change back from atlas texture for tiles to array texture
add callback support for imgui sdlgpu3 backend
2025-03-20 12:22:21 +01:00
Sven Balzer e87a66b984 rename biliear_sampler to pixel sampler and remove point_sampler 2025-03-18 06:06:13 +01:00
Sven Balzer 944c00b89e add hotkey (R) for rotation 2025-03-17 17:05:35 +01:00
Sven Balzer 5ac98b6203 make globals static 2025-03-17 16:24:51 +01:00
Sven Balzer fc88859eaf only upload data to texture if *data is not NULL
refactor create_shader_texture(path) to use the other create_shader_texture(name, data, width. height, channels)
2025-03-17 08:17:54 +01:00
Sven Balzer cdf6cf00a8 make other sampling the default 2025-03-16 21:23:34 +01:00
Sven Balzer 5b6d83ed90 add other filtering option for comparison 2025-03-16 21:04:00 +01:00
Sven Balzer 6a7f54ca5a convert indentation to spaces 2025-03-16 18:56:40 +01:00
Ammerhai 09b1f3943a add image to readme
update the readme image
2025-03-16 18:05:40 +01:00
Ammerhai 8d7a4e9a4a change map files
add character shadow
2025-03-16 17:46:02 +01:00
Ammerhai fd11d177c1 rename corner code 2025-03-16 17:34:28 +01:00
Ammerhai e2a4eec761 rename grass_ground corners 2025-03-16 17:32:30 +01:00
Ammerhai 65d79b8985 add sprout character tileset
rename map_scaled
2025-03-16 17:30:42 +01:00
Ammerhai 98844b6094 add new sprites 2025-03-16 17:26:21 +01:00
Sven Balzer 31823101a5 add msaa toggle 2025-03-16 16:06:52 +01:00
Sven Balzer 45ca42df99 mark things as static 2025-03-16 12:14:40 +01:00
Sven Balzer 1220cf6e7a add tracy memory tracking to SDL 2025-03-16 12:10:00 +01:00
Sven Balzer f1ffbbcfda change camera defaults 2025-03-16 08:08:41 +01:00
Sven Balzer ad37f333ae remove atlas_item from tile info 2025-03-16 08:07:31 +01:00
Sven Balzer 93708f37b8 make dual grid always be active 2025-03-16 07:49:19 +01:00
Sven Balzer 4b3ca3e673 inline PI for msvc 2025-03-15 16:22:50 +01:00
Sven Balzer 755befb89d destroy tile atlas structure after it is not needed anymore 2025-03-15 11:29:12 +01:00
Sven Balzer ce90ecdaea add tracy 2025-03-15 11:28:57 +01:00
Sven Balzer 592e1f39f3 put custom sdl changes into patches/ 2025-03-14 08:50:59 +01:00
Sven Balzer b9a52da265 add a dual grid toggle 2025-03-13 05:55:17 +01:00
Sven Balzer 57f6926d6f make tile border 4 wide and enable anisotropic filtering 2025-03-12 06:26:52 +01:00
Sven Balzer 0043563f7d add the ability to drag tile changes 2025-03-11 11:31:08 +01:00
Sven Balzer 2ad30458bf add camera tilt 2025-03-11 09:16:17 +01:00
Sven Balzer e77086601b clean up math_graphics.h 2025-03-09 20:34:08 +01:00
Sven Balzer 5016f906ea fix projection of mouse into view space 2025-03-09 20:34:07 +01:00
Sven Balzer 88da989ad7 major refactor and add a camera
change asset loading of images to be sRGB
use wayland by default on linux unless we are running under renderdoc
changed shaders to be combined vertex and fragment in a single file
require Vulkan 1.3 and enable shaderDrawParameters
2025-03-08 19:39:48 +01:00
Ammerhai d80ffe7c79 fix pixel bug 2025-03-07 19:25:06 +01:00
Sven Balzer ebddc0dfe2 add random rotation option 2025-02-28 16:16:21 +01:00
Sven Balzer 0d875d23ae make tiles rotatable 2025-02-28 16:05:51 +01:00
Ammerhai 611c1afcb6 add new tiles part 4 2025-02-27 18:44:15 +01:00
Ammerhai 1b75448163 add new tiles part 3 2025-02-27 18:29:03 +01:00
Sven Balzer 7b9db0b16b add grass_ground_1 tile 2025-02-27 18:22:05 +01:00
Sven Balzer 3c02064f2b make new map tiles be empty by default and only expand map by one row/column 2025-02-27 18:15:35 +01:00
Sven Balzer 08e3dfd9d3 add tile selector 2025-02-27 18:01:06 +01:00
Sven Balzer 1c8a65e8ad change tiles from a texture array to a texture atlas 2025-02-27 18:01:06 +01:00
Sven Balzer 2d583d8f72 put the player in the same tile that gets collision checked 2025-02-27 18:01:06 +01:00
Sven Balzer 095f94b098 make the imgui window not be focused by default and put math_graphics into a namespace 2025-02-27 18:01:06 +01:00
Ammerhai a872bede2c add new tiles part 2 2025-02-27 18:00:38 +01:00
Sven Balzer 526316a928 center player in tile again 2025-02-25 20:03:52 +01:00
Sven Balzer 5b29a2bd5b fix crash on minimize 2025-02-25 19:36:25 +01:00
Sven Balzer 920f93ea7a change tiles to be actually square 2025-02-25 19:27:25 +01:00
Ammerhai 97ff0726c9 change tile structure 2025-02-25 19:16:18 +01:00
Sven Balzer 2d5b36bbef change colorspace of sprites back to linear 2025-02-25 18:49:35 +01:00
Ammerhai a3ca31948b add SDL3 dependency to imgui 2025-02-25 18:39:56 +01:00
Ammerhai 59c55ac092 add png files 2025-02-25 18:29:42 +01:00
Sven Balzer f4418d94d9 remove quad_instance 2025-02-25 17:25:36 +01:00
Sven Balzer b1e657abc3 remove typedefs in favor of SDL ones 2025-02-25 16:56:12 +01:00
Sven Balzer 3e32ebd62b convert assets to png and switch to srgb color loading 2025-02-25 14:09:25 +01:00
Sven Balzer 2e2572a769 get rid of glyphs 2025-02-25 13:28:33 +01:00
Sven Balzer f2b992a39d add imgui 2025-02-25 13:23:17 +01:00
Sven Balzer a6a6761e9f update stb libs 2025-02-25 12:58:19 +01:00
Sven Balzer c70a9a245b fix for c++20 on linux 2025-02-25 12:58:19 +01:00
Ammerhai 85d653db29 add first map iteration 2025-02-24 21:17:06 +01:00
Sven Balzer 74e0d78a4c change build system to CMake and use SDL3 for everything 2025-02-24 19:56:47 +01:00
Ammerhai e6a5a00dcb README.md aktualisiert 2025-02-18 19:37:02 +01:00
Ammerhai 9a06173a7c add stone and grass/ground assets 2025-02-17 19:04:57 +01:00
Ammerhai 61713bb10f add gitignore 2024-07-16 22:21:51 +02:00
Ammerhai 5058054f3c extend readme 2024-05-26 21:06:39 +02:00
Ammerhai 5cf457561c README.md hinzugefügt 2024-05-26 20:52:21 +02:00
mikeb 61bef68b40 template tiles;
git-svn-id: svn://ammerhai.com/home/mike/pokemon_repo@23 24008968-59e6-ed4c-a10b-0b2c954b24ab
2024-02-03 13:46:36 +00:00
mikeb 5ce2942e71 git svn test
git-svn-id: svn://ammerhai.com/home/mike/pokemon_repo@22 24008968-59e6-ed4c-a10b-0b2c954b24ab
2024-02-03 13:40:16 +00:00
mikeb c7a9c2f78f math_graphics.h angepasst;
lerp angepasst;

git-svn-id: svn://ammerhai.com/home/mike/pokemon_repo@21 24008968-59e6-ed4c-a10b-0b2c954b24ab
2021-07-27 16:28:15 +00:00
mikeb efc6477180 Anpassung Window Größe und Spielfeld
-> gleiche Ratio (16:9);
Neue math_graphics.h Funktionen (Aufräumen);

git-svn-id: svn://ammerhai.com/home/mike/pokemon_repo@20 24008968-59e6-ed4c-a10b-0b2c954b24ab
2021-07-26 16:28:42 +00:00
mikeb b603d997cf Glyph output -> single Glyphs;
read bmp file (via stb, m_header is coming later)
 -> stb_image.h;
added monochrom imagetype (load_tga_file); 

git-svn-id: svn://ammerhai.com/home/mike/pokemon_repo@19 24008968-59e6-ed4c-a10b-0b2c954b24ab
2021-07-18 13:09:44 +00:00
mikeb 70a9074415 glyphs_project for text rendering
-> render text image -> gylp_map
 -> stb_image_write.h und stb_rect_pack.h;

git-svn-id: svn://ammerhai.com/home/mike/pokemon_repo@18 24008968-59e6-ed4c-a10b-0b2c954b24ab
2021-07-17 11:16:57 +00:00
mikeb 1f91eb9cf1 font_creator project for font loading;
init font_main + "stbtt_InitFont";
Lexend-Regular.ttf as normal font;


git-svn-id: svn://ammerhai.com/home/mike/pokemon_repo@17 24008968-59e6-ed4c-a10b-0b2c954b24ab
2021-07-03 17:31:05 +00:00
mikeb ce923a77fb UV Texturkoordinaten ergaenzt;
V2 struct fuer UV Koordinaten ergaenzt;

git-svn-id: svn://ammerhai.com/home/mike/pokemon_repo@16 24008968-59e6-ed4c-a10b-0b2c954b24ab
2021-06-30 16:00:14 +00:00
mikeb 0f6bfcdc4b added render_quad -> button + text rendering;
how to draw with directX;

git-svn-id: svn://ammerhai.com/home/mike/pokemon_repo@15 24008968-59e6-ed4c-a10b-0b2c954b24ab
2021-03-04 15:16:57 +00:00
mikeb d416f6d36e created gamedesign folder;
changed map_layout.tga path to gamedesign/map_layout;


git-svn-id: svn://ammerhai.com/home/mike/pokemon_repo@14 24008968-59e6-ed4c-a10b-0b2c954b24ab
2021-03-04 12:40:06 +00:00
5929 changed files with 4127313 additions and 2068 deletions
+1
View File
@@ -0,0 +1 @@
assets/shader/*.dep
+154
View File
@@ -0,0 +1,154 @@
cmake_minimum_required(VERSION 3.25)
project(mikemon VERSION 0.1 LANGUAGES CXX C)
set(CMAKE_C_STANDARD 23)
set(CMAKE_C_EXTENSIONS OFF)
set(CMAKE_CXX_STANDARD 20)
set(CMAKE_CXX_EXTENSIONS OFF)
set(CMAKE_DISABLE_PRECOMPILE_HEADERS ON)
option(TRACY_ENABLE "Enable Tracy profiling" OFF)
# glm
add_subdirectory(libs/glm)
target_compile_definitions(glm PUBLIC GLM_FORCE_SWIZZLE GLM_FORCE_XYZW_ONLY)
# SDL
set(SDL_SHARED OFF)
set(SDL_STATIC ON)
add_subdirectory(libs/SDL3)
# wgpu
add_subdirectory(libs/wgpu)
# SDL3_mixer
set(BUILD_SHARED_LIBS ${SDL_SHARED})
set(SDLMIXER_DEPS_SHARED OFF)
set(SDLMIXER_VENDORED ON)
set(SDLMIXER_OPUS ON)
set(SDLMIXER_VORBIS_VORBISFILE OFF)
set(SDLMIXER_AIFF OFF)
set(SDLMIXER_WAVE OFF)
set(SDLMIXER_VOC OFF)
set(SDLMIXER_AU OFF)
set(SDLMIXER_FLAC OFF)
set(SDLMIXER_GME OFF)
set(SDLMIXER_MOD OFF)
set(SDLMIXER_MP3 OFF)
set(SDLMIXER_MIDI OFF)
set(SDLMIXER_WAVPACK OFF)
add_subdirectory(libs/SDL3_mixer)
# Dear ImGui
add_library(imgui STATIC
libs/imgui/imgui.cpp
libs/imgui/imgui_draw.cpp
libs/imgui/imgui_demo.cpp
libs/imgui/imgui_tables.cpp
libs/imgui/imgui_widgets.cpp
libs/imgui/backends/imgui_impl_sdl3.cpp
libs/dcimgui/dcimgui.cpp
libs/dcimgui/dcimgui_internal.cpp
libs/dcimgui/backends/dcimgui_impl_sdl3.cpp
)
target_include_directories(imgui PUBLIC
libs/imgui
libs/dcimgui
libs/imgui/backends
)
target_link_libraries(imgui PRIVATE SDL3::SDL3)
# Dear ImGui WGPU backend
add_library(imgui_wgpu STATIC
libs/imgui/backends/imgui_impl_wgpu.cpp
libs/dcimgui/backends/dcimgui_impl_wgpu.cpp
)
target_include_directories(imgui_wgpu PUBLIC
libs/imgui/backends
libs/dcimgui/backends
)
target_link_libraries(imgui_wgpu PRIVATE imgui wgpu)
target_compile_definitions(imgui_wgpu PRIVATE IMGUI_IMPL_WEBGPU_BACKEND_WGPU=1)
# Dear ImGui SDLGPU backend
add_library(imgui_sdlgpu STATIC
libs/imgui/backends/imgui_impl_sdlgpu3.cpp
libs/dcimgui/backends/dcimgui_impl_sdlgpu3.cpp
)
target_include_directories(imgui_sdlgpu PUBLIC
libs/imgui/backends
libs/dcimgui/backends
)
target_link_libraries(imgui_sdlgpu PRIVATE imgui SDL3::SDL3)
# stb_image
add_library(stb_image STATIC libs/stb/stb_image.c)
target_include_directories(stb_image INTERFACE libs/stb)
# tracy
option(TRACY_ONLY_LOCALHOST "" ON)
add_subdirectory(libs/tracy)
# shaders
find_program(SLANGC_EXECUTABLE slangc)
set(SHADERS_SPV "")
set(SHADERS_WGSL "")
function(add_shader name)
if(SLANGC_EXECUTABLE)
add_custom_command(OUTPUT "${CMAKE_CURRENT_SOURCE_DIR}/src/shaders/spirv/${name}.spv" DEPFILE "${CMAKE_CURRENT_BINARY_DIR}/${name}-spv.dep" COMMAND "${SLANGC_EXECUTABLE}" -depfile "${CMAKE_CURRENT_BINARY_DIR}/${name}-spv.dep" "${CMAKE_CURRENT_SOURCE_DIR}/src/shaders/src/${name}.slang" -o "${CMAKE_CURRENT_SOURCE_DIR}/src/shaders/spirv/${name}.spv" -target spirv -profile spirv_1_0)
add_custom_command(OUTPUT "${CMAKE_CURRENT_SOURCE_DIR}/src/shaders/wgsl/${name}.wgsl" DEPFILE "${CMAKE_CURRENT_BINARY_DIR}/${name}-wgsl.dep" COMMAND "${SLANGC_EXECUTABLE}" -depfile "${CMAKE_CURRENT_BINARY_DIR}/${name}-wgsl.dep" "${CMAKE_CURRENT_SOURCE_DIR}/src/shaders/src/${name}.slang" -o "${CMAKE_CURRENT_SOURCE_DIR}/src/shaders/wgsl/${name}.wgsl" -target wgsl -D__wgsl__)
endif()
set(SHADERS_SPV ${SHADERS_SPV} "${CMAKE_CURRENT_SOURCE_DIR}/src/shaders/spirv/${name}.spv" PARENT_SCOPE)
set(SHADERS_WGSL ${SHADERS_WGSL} "${CMAKE_CURRENT_SOURCE_DIR}/src/shaders/wgsl/${name}.wgsl" PARENT_SCOPE)
endfunction()
add_shader(character)
add_shader(character_shadow)
add_shader(world)
add_shader(placeable)
add_shader(grid)
add_custom_target(shaders-spv DEPENDS ${SHADERS_SPV})
add_custom_target(shaders-wgsl DEPENDS ${SHADERS_WGSL})
# game
add_executable(mikemon
src/smol-atlas.cpp
src/change_directory.c
src/renderer_wgpu.c
src/main.cpp
)
target_link_libraries(mikemon
PRIVATE
glm
SDL3::SDL3
SDL3_mixer::SDL3_mixer
stb_image
imgui
imgui_wgpu
TracyClient
wgpu
)
add_dependencies(mikemon shaders-wgsl)
add_executable(mikemon-sdlgpu
src/smol-atlas.cpp
src/change_directory.c
src/renderer_sdlgpu.c
src/main.cpp
)
target_link_libraries(mikemon-sdlgpu
PRIVATE
glm
SDL3::SDL3
SDL3_mixer::SDL3_mixer
stb_image
imgui
imgui_sdlgpu
TracyClient
wgpu
)
add_dependencies(mikemon-sdlgpu shaders-spv)
+12
View File
@@ -0,0 +1,12 @@
# Mikemon
A not-so-little monster RPG inspired by the biggest of its kind in the late 2000s and early 2010s.
## CMAKE
```
cmake -G Ninja -B build
cmake --build build --parallel
```
Binary file not shown.

After

Width:  |  Height:  |  Size: 7.8 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 448 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 689 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 239 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.8 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 373 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 583 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 601 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 528 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.3 KiB

Binary file not shown.
Binary file not shown.

After

Width:  |  Height:  |  Size: 768 KiB

Binary file not shown.
Binary file not shown.
BIN
View File
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
+16
View File
@@ -0,0 +1,16 @@
#ifndef WORLDS_H
#define WORLDS_H
#ifdef __cplusplus
extern "C" {
#endif // __cplusplus
static const char *world_names[] = {
"map",
};
#ifdef __cplusplus
}
#endif // __cplusplus
#endif // WORLDS_H
Binary file not shown.

After

Width:  |  Height:  |  Size: 44 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 27 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 44 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 27 KiB

Binary file not shown.
+4
View File
@@ -0,0 +1,4 @@
Marker file version: 1
Time format: Samples
loop_start 2580480
loop_end 4976640
Binary file not shown.
Binary file not shown.
-24
View File
@@ -1,24 +0,0 @@
struct PixelShaderInput {
float4 pos : SV_POSITION;
float4 uvst : COORDINATES;
uint tile_type : TILE_TYPE;
};
struct PixelShaderOutput {
float4 color : SV_TARGET;
};
Texture2DArray<float4> tex1 : register(t0);
SamplerState texture_sampler : register(s0);
PixelShaderOutput main(PixelShaderInput input) {
PixelShaderOutput output;
#if 1
output.color = tex1.Sample(texture_sampler, float3(input.uvst.xy, input.tile_type));
#else
output.color = float4(1, 0, 1, 1);
#endif
return output;
}
-53
View File
@@ -1,53 +0,0 @@
struct VertexShaderInput {
// Per Vertex
float4 pos : VERTEX_POSITION;
float4 uvst : COORDINATES;
uint vid : SV_VertexID;
// Per Instance
float4 pos_size : INSTANCE_POSITION_SIZE;
uint tile_type : TILE_TYPE;
};
struct VertexShaderOutput {
float4 pos : SV_POSITION;
float4 uvst : COORDINATES;
uint tile_type : TILE_TYPE;
};
VertexShaderOutput main(VertexShaderInput input) {
VertexShaderOutput output;
float2 rect_pos = input.pos_size.xy;
float2 rect_size = input.pos_size.zw;
float3x3 coord_sys = {
2, 0, -1,
0, -2, 1,
0, 0, 1
};
input.pos_size.xy = mul(coord_sys, float3(input.pos_size.xy, 1)).xy;
float3x3 pos = {
1, 0, input.pos_size.x,
0, 1, input.pos_size.y,
0, 0, 1
};
float3x3 size = {
rect_size.x, 0, 0,
0, rect_size.y, 0,
0, 0, 1
};
output.pos.xy = mul(pos, mul(size, input.pos.xyz)).xy;
//output.pos.xy = mul(pos, input.pos.xyz).xy;
output.pos.zw = float2(0, 1);
output.uvst = input.uvst;
output.tile_type = input.tile_type;
return output;
}
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.

After

Width:  |  Height:  |  Size: 206 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 114 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 191 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 465 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 484 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 337 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 411 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 490 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 523 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 522 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 133 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 195 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 265 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 323 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 156 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 113 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 354 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 420 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 422 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 441 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 439 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 428 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 382 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 361 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 561 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 487 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 505 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 570 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 433 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 533 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 260 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 111 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 397 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 465 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 467 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 300 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 346 B

BIN
View File
Binary file not shown.
BIN
View File
Binary file not shown.
Binary file not shown.

After

Width:  |  Height:  |  Size: 7.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 31 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 67 KiB

+91
View File
@@ -0,0 +1,91 @@
---
AlignConsecutiveMacros: Consecutive
AlignConsecutiveAssignments: None
AlignConsecutiveBitFields: None
AlignConsecutiveDeclarations: None
AlignEscapedNewlines: Right
AlignOperands: Align
AlignTrailingComments: true
AllowAllArgumentsOnNextLine: true
AllowAllParametersOfDeclarationOnNextLine: true
AllowShortEnumsOnASingleLine: true
AllowShortBlocksOnASingleLine: Never
AllowShortCaseLabelsOnASingleLine: false
AllowShortFunctionsOnASingleLine: All
AllowShortIfStatementsOnASingleLine: Never
AllowShortLoopsOnASingleLine: false
AlwaysBreakAfterDefinitionReturnType: None
AlwaysBreakAfterReturnType: None
AlwaysBreakBeforeMultilineStrings: false
AlwaysBreakTemplateDeclarations: MultiLine
# Custom brace breaking
BreakBeforeBraces: Custom
BraceWrapping:
AfterCaseLabel: true
AfterClass: true
AfterControlStatement: Never
AfterEnum: true
AfterFunction: true
AfterNamespace: true
AfterObjCDeclaration: true
AfterStruct: true
AfterUnion: true
AfterExternBlock: false
BeforeElse: false
BeforeWhile: false
IndentBraces: false
SplitEmptyFunction: true
SplitEmptyRecord: true
# Make the closing brace of container literals go to a new line
Cpp11BracedListStyle: false
# Never format includes
IncludeBlocks: Preserve
# clang-format version 4.0 through 12.0:
#SortIncludes: false
# clang-format version 13.0+:
#SortIncludes: Never
# No length limit, in case it breaks macros, you can
# disable it with /* clang-format off/on */ comments
ColumnLimit: 0
IndentWidth: 4
ContinuationIndentWidth: 4
IndentCaseLabels: false
IndentCaseBlocks: false
IndentGotoLabels: true
IndentPPDirectives: None
IndentExternBlock: NoIndent
PointerAlignment: Right
SpaceAfterCStyleCast: false
SpacesInCStyleCastParentheses: false
SpacesInConditionalStatement: false
SpacesInContainerLiterals: true
SpaceBeforeAssignmentOperators: true
SpaceBeforeCaseColon: false
SpaceBeforeParens: ControlStatements
SpaceAroundPointerQualifiers: Default
SpaceInEmptyBlock: false
SpaceInEmptyParentheses: false
UseCRLF: false
UseTab: Never
ForEachMacros:
[
"spa_list_for_each",
"spa_list_for_each_safe",
"wl_list_for_each",
"wl_list_for_each_safe",
"wl_array_for_each",
"udev_list_entry_foreach",
]
---
+59
View File
@@ -0,0 +1,59 @@
---
Checks: >
-*,
bugprone-assert-side-effect,
bugprone-assignment-in-if-condition,
bugprone-bool-pointer-implicit-conversion,
bugprone-dangling-handle,
bugprone-dynamic-static-initializers,
bugprone-infinite-loop,
bugprone-integer-division,
bugprone-macro-repeated-side-effects,
bugprone-misplaced-operator-in-strlen-in-alloc,
bugprone-misplaced-pointer-arithmetic-in-alloc,
bugprone-misplaced-widening-cast,
bugprone-not-null-terminated-result,
bugprone-posix-return,
bugprone-redundant-branch-condition,
bugprone-string-literal-with-embedded-nul,
bugprone-suspicious-memset-usage,
bugprone-suspicious-semicolon,
bugprone-suspicious-string-compare,
bugprone-too-small-loop-variable,
bugprone-unused-return-value,
cert-err33-c,
clang-analyzer-core.*,
clang-analyzer-valist.*,
clang-analyzer-unix.Malloc,
clang-diagnostic-*,
google-readability-casting,
misc-misleading-bidirectional,
misc-misleading-identifier,
misc-misplaced-const,
misc-redundant-expression,
objc-*,
performance-type-promotion-in-math-fn,
readability-avoid-const-params-in-decls,
readability-braces-around-statements,
readability-const-return-type,
readability-duplicate-include,
readability-inconsistent-declaration-parameter-name,
readability-misplaced-array-index,
readability-non-const-parameter,
readability-redundant-control-flow,
readability-redundant-declaration,
readability-redundant-function-ptr-dereference,
readability-redundant-preprocessor,
readability-simplify-boolean-expr
CheckOptions:
- key: bugprone-assert-side-effect.AssertMacros
value: "SDL_assert, SDL_assert_release, SDL_assert_paranoid, SDL_assert_always, SDL_COMPILE_TIME_ASSERT"
- key: bugprone-misplaced-widening-cast.CheckImplicitCasts
value: true
- key: bugprone-not-null-terminated-result.WantToUseSafeFunctions
value: false # Do not recommend _s functions
FormatStyle: "file"
HeaderFilterRegex: "*.h$"
WarningsAsErrors: ""
+69
View File
@@ -0,0 +1,69 @@
# For format see editorconfig.org
# Copyright 2022 Collabora Ltd.
# SPDX-License-Identifier: Zlib
root = true
[*.{c,cc,cg,cpp,gradle,h,java,m,metal,pl,py,S,sh,txt}]
indent_size = 4
indent_style = space
insert_final_newline = true
trim_trailing_whitespace = true
[*.{html,js,json,m4,yml,yaml,vcxproj,vcxproj.filters}]
indent_size = 2
indent_style = space
trim_tailing_whitespace = true
[*.xml]
indent_size = 4
indent_style = space
[{CMakeLists.txt,cmake/*.cmake}]
indent_size = 2
indent_style = space
insert_final_newline = true
trim_trailing_whitespace = true
[{cmake/cmake_uninstall.cmake.in,test/CMakeLists.txt,cmake/SDL3Config.cmake.in}]
indent_size = 4
indent_style = space
insert_final_newline = true
trim_trailing_whitespace = true
[{Makefile.*,*.mk,*.sln,*.pbxproj,*.plist}]
indent_size = 8
indent_style = tab
tab_width = 8
[src/joystick/controller_type.*]
indent_style = tab
[src/joystick/hidapi/steam/*.h]
indent_style = tab
[src/libm/*.c]
indent_style = tab
[src/test/SDL_test_{crc32,md5,random}.c]
indent_size = 2
indent_style = space
[src/video/yuv2rgb/*.{c,h}]
indent_style = tab
[wayland-protocols/*.xml]
indent_size = 2
indent_style = space
[*.{markdown,md}]
indent_size = 4
indent_style = space
# Markdown syntax treats tabs as 4 spaces
tab_width = 4
[{*.bat,*.rc}]
end_of_line = crlf
[*.cocci]
insert_final_newline = true
+1
View File
@@ -0,0 +1 @@
683181b47cfabd293e3ea409f838915b8297a4fd
+41
View File
@@ -0,0 +1,41 @@
projectfullname = Simple Directmedia Layer
projectshortname = SDL
incsubdir = include/SDL3
wikisubdir =
readmesubdir = docs
apiprefixregex = (SDL_|SDLK_|[US]int\d+)
mainincludefname = SDL3/SDL.h
versionfname = include/SDL3/SDL_version.h
versionmajorregex = \A\#define\s+SDL_MAJOR_VERSION\s+(\d+)\Z
versionminorregex = \A\#define\s+SDL_MINOR_VERSION\s+(\d+)\Z
versionmicroregex = \A\#define\s+SDL_MICRO_VERSION\s+(\d+)\Z
apipropertyregex = \A\s*\#\s*define\s+SDL_PROP_
selectheaderregex = \ASDL.*?\.h\Z
projecturl = https://libsdl.org/
wikiurl = https://wiki.libsdl.org
bugreporturl = https://github.com/libsdl-org/sdlwiki/issues/new
warn_about_missing = 0
#wikipreamble = (This is the documentation for SDL3, which is the current stable version. [SDL2](https://wiki.libsdl.org/SDL2/) was the previous version!)
wikiheaderfiletext = Defined in [<SDL3/%fname%>](https://github.com/libsdl-org/SDL/blob/main/include/SDL3/%fname%)
manpageheaderfiletext = Defined in SDL3/%fname%
manpagesymbolfilterregex = \A[US]int\d+\Z
# All SDL_test_* headers become undefined categories, everything else just converts like SDL_audio.h -> Audio
# A handful of others we fix up in the header itself with /* WIKI CATEGORY: x */ comments.
headercategoryeval = s/\ASDL_test_?.*?\.h\Z//; s/\ASDL_?(.*?)\.h\Z/$1/; ucfirst();
quickrefenabled = 1
quickrefcategoryorder = Init,Hints,Error,Version,Properties,Log,Video,Events,Keyboard,Mouse,Touch,Gamepad,Joystick,Haptic,Audio,Time,Timer,Render,SharedObject,Thread,Mutex,Atomic,Filesystem,IOStream,AsyncIO,Storage,Pixels,Surface,Blendmode,Rect,Camera,Clipboard,Dialog,Tray,Messagebox,GPU,Vulkan,Metal,Platform,Power,Sensor,Process,Bits,Endian,Assert,CPUInfo,Intrinsics,Locale,System,Misc,GUID,Main,Stdinc
quickreftitle = SDL3 API Quick Reference
quickrefurl = https://libsdl.org/
quickrefdesc = The latest version of this document can be found at https://wiki.libsdl.org/SDL3/QuickReference
quickrefmacroregex = \A(SDL_PLATFORM_.*|SDL_.*_INTRINSICS|SDL_Atomic...Ref|SDL_assert.*?|SDL_COMPILE_TIME_ASSERT|SDL_arraysize|SDL_Swap[BL]E\d\d|SDL_[a-z]+_cast)\Z
envvarenabled = 1
envvartitle = SDL3 Environment Variables
envvardesc = SDL3 can be controlled by the user, externally, with environment variables. They are all operate exactly like the [hints you can get and set programmatically](CategoryHints), but named without the `_HINT` part (so `"SDL_HINT_A"` would be environment variable `"SDL_A"`).\n\nThis list matches the latest in SDL3's revision control.
envvarsymregex = \ASDL_HINT_(.*)\Z
envvarsymreplace = SDL_$1
+145
View File
@@ -0,0 +1,145 @@
LOCAL_PATH := $(call my-dir)
###########################
#
# SDL shared library
#
###########################
include $(CLEAR_VARS)
LOCAL_MODULE := SDL3
LOCAL_C_INCLUDES := $(LOCAL_PATH)/include $(LOCAL_PATH)/include/build_config $(LOCAL_PATH)/src
LOCAL_EXPORT_C_INCLUDES := $(LOCAL_PATH)/include
LOCAL_SRC_FILES := \
$(subst $(LOCAL_PATH)/,, \
$(wildcard $(LOCAL_PATH)/src/*.c) \
$(wildcard $(LOCAL_PATH)/src/audio/*.c) \
$(wildcard $(LOCAL_PATH)/src/audio/android/*.c) \
$(wildcard $(LOCAL_PATH)/src/audio/dummy/*.c) \
$(wildcard $(LOCAL_PATH)/src/audio/aaudio/*.c) \
$(wildcard $(LOCAL_PATH)/src/audio/openslES/*.c) \
$(LOCAL_PATH)/src/atomic/SDL_atomic.c.arm \
$(LOCAL_PATH)/src/atomic/SDL_spinlock.c.arm \
$(wildcard $(LOCAL_PATH)/src/camera/*.c) \
$(wildcard $(LOCAL_PATH)/src/camera/android/*.c) \
$(wildcard $(LOCAL_PATH)/src/camera/dummy/*.c) \
$(wildcard $(LOCAL_PATH)/src/core/*.c) \
$(wildcard $(LOCAL_PATH)/src/core/android/*.c) \
$(wildcard $(LOCAL_PATH)/src/cpuinfo/*.c) \
$(LOCAL_PATH)/src/dialog/SDL_dialog.c \
$(LOCAL_PATH)/src/dialog/SDL_dialog_utils.c \
$(LOCAL_PATH)/src/dialog/android/SDL_androiddialog.c \
$(wildcard $(LOCAL_PATH)/src/dynapi/*.c) \
$(wildcard $(LOCAL_PATH)/src/events/*.c) \
$(wildcard $(LOCAL_PATH)/src/io/*.c) \
$(wildcard $(LOCAL_PATH)/src/io/generic/*.c) \
$(wildcard $(LOCAL_PATH)/src/gpu/*.c) \
$(wildcard $(LOCAL_PATH)/src/gpu/vulkan/*.c) \
$(wildcard $(LOCAL_PATH)/src/haptic/*.c) \
$(wildcard $(LOCAL_PATH)/src/haptic/android/*.c) \
$(wildcard $(LOCAL_PATH)/src/haptic/dummy/*.c) \
$(wildcard $(LOCAL_PATH)/src/haptic/hidapi/*.c) \
$(wildcard $(LOCAL_PATH)/src/hidapi/*.c) \
$(wildcard $(LOCAL_PATH)/src/hidapi/android/*.cpp) \
$(wildcard $(LOCAL_PATH)/src/joystick/*.c) \
$(wildcard $(LOCAL_PATH)/src/joystick/android/*.c) \
$(wildcard $(LOCAL_PATH)/src/joystick/dummy/*.c) \
$(wildcard $(LOCAL_PATH)/src/joystick/hidapi/*.c) \
$(wildcard $(LOCAL_PATH)/src/joystick/steam/*.c) \
$(wildcard $(LOCAL_PATH)/src/joystick/virtual/*.c) \
$(wildcard $(LOCAL_PATH)/src/loadso/dlopen/*.c) \
$(wildcard $(LOCAL_PATH)/src/locale/*.c) \
$(wildcard $(LOCAL_PATH)/src/locale/android/*.c) \
$(wildcard $(LOCAL_PATH)/src/main/*.c) \
$(wildcard $(LOCAL_PATH)/src/main/generic/*.c) \
$(wildcard $(LOCAL_PATH)/src/misc/*.c) \
$(wildcard $(LOCAL_PATH)/src/misc/android/*.c) \
$(wildcard $(LOCAL_PATH)/src/power/*.c) \
$(wildcard $(LOCAL_PATH)/src/power/android/*.c) \
$(wildcard $(LOCAL_PATH)/src/process/*.c) \
$(wildcard $(LOCAL_PATH)/src/process/dummy/*.c) \
$(wildcard $(LOCAL_PATH)/src/filesystem/*.c) \
$(wildcard $(LOCAL_PATH)/src/filesystem/android/*.c) \
$(wildcard $(LOCAL_PATH)/src/filesystem/posix/*.c) \
$(wildcard $(LOCAL_PATH)/src/sensor/*.c) \
$(wildcard $(LOCAL_PATH)/src/sensor/android/*.c) \
$(wildcard $(LOCAL_PATH)/src/sensor/dummy/*.c) \
$(wildcard $(LOCAL_PATH)/src/render/*.c) \
$(wildcard $(LOCAL_PATH)/src/render/*/*.c) \
$(wildcard $(LOCAL_PATH)/src/stdlib/*.c) \
$(wildcard $(LOCAL_PATH)/src/storage/*.c) \
$(wildcard $(LOCAL_PATH)/src/storage/generic/*.c) \
$(wildcard $(LOCAL_PATH)/src/thread/*.c) \
$(wildcard $(LOCAL_PATH)/src/thread/pthread/*.c) \
$(wildcard $(LOCAL_PATH)/src/time/*.c) \
$(wildcard $(LOCAL_PATH)/src/time/unix/*.c) \
$(wildcard $(LOCAL_PATH)/src/timer/*.c) \
$(wildcard $(LOCAL_PATH)/src/timer/unix/*.c) \
$(wildcard $(LOCAL_PATH)/src/tray/dummy/*.c) \
$(wildcard $(LOCAL_PATH)/src/tray/*.c) \
$(wildcard $(LOCAL_PATH)/src/video/*.c) \
$(wildcard $(LOCAL_PATH)/src/video/android/*.c) \
$(wildcard $(LOCAL_PATH)/src/video/yuv2rgb/*.c))
LOCAL_CFLAGS += -DGL_GLEXT_PROTOTYPES
LOCAL_CFLAGS += \
-Wall -Wextra \
-Wmissing-prototypes \
-Wunreachable-code-break \
-Wunneeded-internal-declaration \
-Wmissing-variable-declarations \
-Wfloat-conversion \
-Wshorten-64-to-32 \
-Wunreachable-code-return \
-Wshift-sign-overflow \
-Wstrict-prototypes \
-Wkeyword-macro \
# Warnings we haven't fixed (yet)
LOCAL_CFLAGS += -Wno-unused-parameter -Wno-sign-compare
LOCAL_CXXFLAGS += -std=gnu++11
LOCAL_LDLIBS := -ldl -lGLESv1_CM -lGLESv2 -lOpenSLES -llog -landroid
LOCAL_LDFLAGS := -Wl,--no-undefined -Wl,--no-undefined-version -Wl,--version-script=$(LOCAL_PATH)/src/dynapi/SDL_dynapi.sym
ifeq ($(NDK_DEBUG),1)
cmd-strip :=
endif
include $(BUILD_SHARED_LIBRARY)
###########################
#
# SDL_test static library
#
###########################
include $(CLEAR_VARS)
LOCAL_C_INCLUDES := $(LOCAL_PATH)/include $(LOCAL_PATH)/src
LOCAL_EXPORT_C_INCLUDES := $(LOCAL_PATH)/include
LOCAL_MODULE := SDL3_test
LOCAL_MODULE_FILENAME := libSDL3_test
LOCAL_SRC_FILES := \
$(subst $(LOCAL_PATH)/,, \
$(wildcard $(LOCAL_PATH)/src/test/*.c))
LOCAL_LDLIBS :=
LOCAL_LDFLAGS :=
LOCAL_EXPORT_LDLIBS :=
include $(BUILD_STATIC_LIBRARY)
+19
View File
@@ -0,0 +1,19 @@
Bugs are now managed in the SDL issue tracker, here:
https://github.com/libsdl-org/SDL/issues
You may report bugs there, and search to see if a given issue has already
been reported, discussed, and maybe even fixed.
You may also find help at the SDL forums/mailing list:
https://discourse.libsdl.org/
or on Discord:
https://discord.com/invite/BwpFGBWsv8
Bug reports are welcome here, but we really appreciate if you use the issue tracker, as bugs discussed on the mailing list or Discord may be forgotten or missed.

Some files were not shown because too many files have changed in this diff Show More