{"id":19125503,"url":"https://github.com/davidhubbard/v0lum3","last_synced_at":"2025-05-05T20:15:11.085Z","repository":{"id":69431911,"uuid":"63919788","full_name":"davidhubbard/v0lum3","owner":"davidhubbard","description":"GPL3 Vulkan voxel library","archived":false,"fork":false,"pushed_at":"2017-04-10T16:14:24.000Z","size":1949,"stargazers_count":5,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-05-05T20:15:06.723Z","etag":null,"topics":["c-plus-plus-11","gpl","gplv3","gpu","graphics-3d","graphics-engine","skia","vulkan"],"latest_commit_sha":null,"homepage":"","language":"C++","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/davidhubbard.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"COPYING.md","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2016-07-22T03:15:08.000Z","updated_at":"2022-06-01T14:48:58.000Z","dependencies_parsed_at":null,"dependency_job_id":"2a0b35b4-16b4-45af-88e2-65f965c2131d","html_url":"https://github.com/davidhubbard/v0lum3","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/davidhubbard%2Fv0lum3","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/davidhubbard%2Fv0lum3/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/davidhubbard%2Fv0lum3/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/davidhubbard%2Fv0lum3/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/davidhubbard","download_url":"https://codeload.github.com/davidhubbard/v0lum3/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":252569648,"owners_count":21769517,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["c-plus-plus-11","gpl","gplv3","gpu","graphics-3d","graphics-engine","skia","vulkan"],"created_at":"2024-11-09T05:35:56.391Z","updated_at":"2025-05-05T20:15:11.076Z","avatar_url":"https://github.com/davidhubbard.png","language":"C++","funding_links":[],"categories":[],"sub_categories":[],"readme":"# v0lum3\n\nv0lum3 is a GPL3 library to create voxel worlds using Vulkan\n\n# build.sh\n\nThe edit-recompile-run process is done using\n[`ninja`](https://chromium.googlesource.com/chromium/src/tools/gn/), like this:\n```\nvi main/main.cpp\nninja -C out/Debug\nout/Debug/v\n```\n\nBut after a clean checkout, please run `build.sh` first. Of course, it will\nimmediately ask you to install\n[depot_tools](http://www.chromium.org/developers/how-tos/install-depot-tools).\nThis is a one-time setup step:\n\n```\n# do not start in another git repo!\n# do this in your home dir or something\n# so first type 'cd' to go to your home dir:\ncd\ngit clone https://chromium.googlesource.com/chromium/tools/depot_tools.git\n# maybe edit your .bashrc to permanently setup the PATH:\nexport PATH=$PWD/depot_tools:$PATH\n```\n\nSince `depot_tools` does not auto-update, you may want to check for updates\nmanually (say, in 6 months) by typing:\n\n```\ngsutil.py update\n```\n\nNow you are ready for `build.sh`:\n\n```\ncd v0lum3\n./build.sh\n```\n\n(See [an example](#buildsh-example) below)\n\nIt builds the following libraries with their dependencies:\n\n* [VulkanSamples](https://github.com/LunarG/VulkanSamples) which has\n  [LoaderAndValidationLayers](https://github.com/KhronosGroup/Vulkan-LoaderAndValidationLayers)\n  built into it\n\n* [skia](https://skia.org). This is why `depot_tools`,\n  [`ninja` and `gn`](https://chromium.googlesource.com/chromium/src/tools/gn/)\n  are necessary.\n\n# Fetching updates from upstream\n\nTo pull the latest commits from github, e.g. to prepare a pull request, you\nwill need to do a few cleanup steps to avoid having merge conflicts:\n\n1. `( cd vendor/glfw \u0026\u0026 git checkout -- . )`\n2. `( cd vendor/skia \u0026\u0026 git checkout -- . )`\n3. Get the latest commits with `git fetch` + `git merge` (or some people use\n   `git pull`)\n4. Rebuild the project with `build.sh` (this will re-patch glfw and skia)\n\n# `build.sh` Example\n\nHere is a somewhat outdated example showing what `build.sh` does:\n\n```\n$ cd\n~ $ mkdir src\n~ $ cd src\nsrc $ git clone https://chromium.googlesource.com/chromium/tools/depot_tools.git\nCloning into 'depot_tools'...\nremote: [snip]\nChecking connectivity... done.\nsrc $ export PATH=$PWD/depot_tools:$PATH\nsrc $ git clone https://github.com/davidhubbard/v0lum3\nCloning into 'v0lum3'...\nremote: Counting objects: 1008, done.\nremote: Compressing objects: 100% (629/629), done.\nremote: Total 1008 (delta 579), reused 593 (delta 358)\nReceiving objects: 100% (1008/1008), 1.65 MiB | 0 bytes/s, done.\nResolving deltas: 100% (579/579), done.\nChecking connectivity... done.\nsrc $ cd v0lum3\nv0lum3 $ ./update.sh\n```\nThe script first checks out all the submodules.\n```\ngit submodule update --init --recursive\nSubmodule 'vendor/VulkanSamples' (https://github.com/LunarG/VulkanSamples.git) registered for path 'vendor/VulkanSamples'\nSubmodule 'vendor/glfw' (https://github.com/glfw/glfw.git) registered for path 'vendor/glfw'\nSubmodule 'vendor/glslang' (https://github.com/KhronosGroup/glslang.git) registered for path 'vendor/glslang'\nSubmodule 'vendor/skia' (https://github.com/google/skia) registered for path 'vendor/skia'\nCloning into 'vendor/VulkanSamples'...\nremote: Counting objects: 60790, done.\nremote: Total 60790 (delta 0), reused 0 (delta 0), pack-reused 60790\nReceiving objects: 100% (60790/60790), 56.64 MiB | 16.80 MiB/s, done.\nResolving deltas: 100% (45817/45817), done.\nChecking connectivity... done.\nSubmodule path 'vendor/VulkanSamples': checked out '9fb1b977604cb36f211fa241212afe8aed79412f'\nCloning into 'vendor/glfw'...\nremote: Counting objects: 20499, done.\nremote: Compressing objects: 100% (38/38), done.\nremote: Total 20499 (delta 17), reused 0 (delta 0), pack-reused 20461\nReceiving objects: 100% (20499/20499), 9.39 MiB | 12.39 MiB/s, done.\nResolving deltas: 100% (14172/14172), done.\nChecking connectivity... done.\nSubmodule path 'vendor/glfw': checked out '798d7c6d68bb17480fcda6074b1d5a946a05ed52'\nCloning into 'vendor/glslang'...\nremote: Counting objects: 23002, done.\nremote: Compressing objects: 100% (37/37), done.\nremote: Total 23002 (delta 12), reused 0 (delta 0), pack-reused 22965\nReceiving objects: 100% (23002/23002), 33.49 MiB | 16.03 MiB/s, done.\nResolving deltas: 100% (19217/19217), done.\nChecking connectivity... done.\nSubmodule path 'vendor/glslang': checked out '8f674e821e1e5f628474b21d7fe21af2e86b5fb4'\nCloning into 'vendor/skia'...\nremote: Counting objects: 280231, done.\nremote: Compressing objects: 100% (20/20), done.\nremote: Total 280231 (delta 6), reused 1 (delta 1), pack-reused 280210\nReceiving objects: 100% (280231/280231), 205.79 MiB | 13.90 MiB/s, done.\nResolving deltas: 100% (228855/228855), done.\nChecking connectivity... done.\nSubmodule path 'vendor/skia': checked out '86271240068a8c4eef24dcd4454dff4d2dc64faf'\n```\nThen it asks `skia` to check out its submodules.\n```\nvendor/skia/tools/git-sync-deps\nthird_party/externals/piex           @ 8f540f64b6c170a16fb7e6e52d61819705c1522a\nthird_party/externals/dng_sdk        @ 96443b262250c390b0caefbf3eed8463ba35ecae\ncommon                               @ 9737551d7a52c3db3262db5856e6bcd62c462b92\nbuildtools                           @ 55ad626b08ef971fd82a62b7abb325359542952b\nthird_party/externals/expat          @ android-6.0.1_r55\nthird_party/externals/spirv-headers  @ 2d6ba39368a781edd82eff5df2b6bc614e892329\nthird_party/externals/zlib           @ 4576304a4b9835aa8646c9735b079e1d96858633\nthird_party/externals/spirv-tools    @ 1fb8c37b5718118b49eec59dc383cfa3f98643c0\nthird_party/externals/jsoncpp        @ 1.0.0\nthird_party/externals/harfbuzz       @ 1.4.2\nthird_party/externals/imgui          @ 6384eee34f08cb7eab8d835043e1738e4adcdf75\nthird_party/externals/libjpeg-turbo  @ 6de58e0d28014caf2fc1370145f22fd6d65f63e3\nthird_party/externals/freetype       @ 447a0b62634802d8acdb56008cff5ff4e50be244\nthird_party/externals/libwebp        @ v0.6.0\nthird_party/externals/microhttpd     @ 748945ec6f1c67b7efc934ab0808e1d32f2fb98d\nthird_party/externals/angle2         @ 57f17473791703ac82add77c3d77d13d8e2dfbc4\nthird_party/externals/sfntly         @ b18b09b6114b9b7fe6fc2f96d8b15e8a72f66916\nthird_party/externals/sdl            @ 9b526d28cb2d7f0ccff0613c94bb52abc8f53b6f\nthird_party/externals/icu            @ ec9c1133693148470ffe2e5e53576998e3650c1d\n```\nThen it runs `gn gen` to generate build.ninja files.\n```\nDone. Made 93 targets from 43 files in 36ms\n```\nThen it runs `ninja` to build the application.\n```\nninja: Entering directory `out/Debug'\n[63/2479] compile ../../third_party/externals/dng_sdk/source/dng_safe_arithmetic.cpp\n```\nWhen it is done building skia submodules, it builds skia proper.\n```\n[783/2479] compile ../../vendor/skia/bench/HairlinePathBench.cpp\n```\nWhen all done it says:\n```\n[2479/2479] stamp obj/root.stamp\nv0lum3 $\n```\n\n# Adopting build.sh to your project\n\n`build.sh` builds the project but it is also super useful for anyone who\nwants to quickly create a clean Vulkan dev environment:\n\n1. Clone this repo\n\n2. Throw away everything under `main`.\n\n3. Write your own application by customizing `BUILD.gn` in the top level\n   directory.\n\n## Where can I get skpmaker?\n\n`skpmaker` just generates a single filled rectangle. Other, easier ways to\nproduce sample skp files are:\n\n* The skia.org docs for SkCanvas have a\n  [number of examples](https://skia.org/user/api/skcanvas). Launch one in\n  under fiddle.skia.org and download the skp by clicking the \"skp\" link.\n* The skia.org Tips \u0026 FAQ includes how to\n  [capture a `.skp` file on a web page](https://skia.org/user/tips#skp-capture).\n\nOr apply this patch to `vendor/skia/BUILD.gn`:\n```\n--- a/BUILD.gn\n+++ b/BUILD.gn\n@@ -1186,6 +1186,16 @@ if (skia_enable_tools) {\n     ]\n   }\n \n+  test_app(\"skpmaker\") {\n+    sources = [\n+      \"tools/skpmaker.cpp\",\n+    ]\n+    deps = [\n+      \":flags\",\n+      \":skia\",\n+    ]\n+  }\n+\n   if (is_linux || is_win || is_mac) {\n     test_app(\"SampleApp\") {\n       sources = [\n```\n\n## Why not use gclient?\n\nThe `gn` developers have voiced some support for use outside of chromium.\ngclient does not seem to have such an indication, though there are many\nskia clients that use it anyway.\n\n## What about vulkantools.sh and lunarglass.sh?\n\nOh yeah, if you want to run:\n\n* `vktrace`\n\n* `vkreplay`\n\n* `vktraceviewer` (requires Qt-svg)\n\nThen type `vendor/vulkantools.sh` and those will be built and installed\nin `vendor/bin` next to `glslangValidator` and friends.\n\nFor [LunarGLASS](https://github.com/LunarG/LunarGLASS) type\n`vendor/lunarglass.sh` and it will be built in `vendor/LunarGLASS`.\n\n## What about the Vulkan Conformance Test Suite (CTS)?\n\nTo run the [Vulkan CTS](https://github.com/KhronosGroup/VK-GL-CTS/)\ntype `vendor/vulkancts.sh` and it will be built in `vendor/cts`.\nAfter a successful build, `vendor/vulkancts.sh` prints instructions\non running the CTS.\n\nA full run takes about 2 hours. To avoid running all cases again,\nlocate the test log and look for results that are not\n`StatusCode=\"Pass\"` or `StatusCode=\"NotSupported\"`.\n\nThen put just these interesting test cases in a separate text file,\nso that the CTS does not take as long to run. Specify a text file of\ntest cases with the `--deqp-caselist-file=` parameter. (See\n`vendor/vulkancts.sh` for more information.)\n\n## Why VulkanSamples and not Vulkan-LoaderAndValidationLayers?\n\nTwo reasons:\n\n1. Samples! VulkanSamples means you can examine / modify / run\n   the samples written by LunarG, but you don't have to fiddle with them\n   to get them to run first.\n\n2. Slightly slower update rate than syncing directly to\n   [LVL](https://github.com/KhronosGroup/Vulkan-LoaderAndValidationLayers)\n   HEAD makes it less work to maintain as a submodule.\n\n## Why not include SaschaWillems (or your favorite set of samples)\n\nAttempting to strike a balance between providing some usable\nreference binaries (to prove that Vulkan is \"working\" at some basic\nlevel, to give you something to start from) but at the same time\nleave the repo at a very minimal \"blank slate,\" from which you\ncan build.\n\nIt is a design goal that this repo is easily converted over to using\nLVL directly. It is also possible to bypass LVL and write your own\nloader, but tests have not shown that to be a significant performance\ngain.\n\n## Notes\n\nShould probably take a look at [CUDA Voxelizer 0.1](https://github.com/Forceflow/cuda_voxelizer)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdavidhubbard%2Fv0lum3","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdavidhubbard%2Fv0lum3","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdavidhubbard%2Fv0lum3/lists"}