diff --git a/docs/readme.md b/docs/readme.md new file mode 100644 index 0000000..b2bc873 --- /dev/null +++ b/docs/readme.md @@ -0,0 +1,19 @@ +# Docs for kiuikit + +We use [sphinx](https://www.sphinx-doc.org/en/master/) and [m2r2](https://github.com/CrossNox/m2r2) to build the documentation in markdown language. + +### Usage + +Since sphinx needs to import the module for auto-doc, we need to install full dependency first: +```bash +pip install -e ".[full]" +pip install -r docs/requirements.txt +``` + +Build the docs by: +```bash +cd docs +make html +``` + +View the local [html](docs/build/html/index.html) by VSCode `Live Server` extension. \ No newline at end of file diff --git a/docs/source/blender.md b/docs/source/blender.md index 5330484..1b21b5b 100644 --- a/docs/source/blender.md +++ b/docs/source/blender.md @@ -1,22 +1,22 @@ -# Blender +# Blender Scripts To render complex 3D models (specifically with multiple submeshes), the only choice is to use `blender` and `bpy`. We provide an example code for rendering with blender: ```bash -# make sure you are using python 3.10 +# make sure you are using python>=3.10, tested with bpy==4.0.0 pip install bpy mathutils # help python -m kiui.cli.blender_render --help # example -python -m kiui.cli.blender_render --mesh chest.glb --gpu 0 --depth --normal --albedo +python -m kiui.cli.blender_render --mesh chest.glb --gpu 0 --depth --normal --albedo --camera --blend ``` Features include: * Set which GPU to use with `--gpu 0` for `CYCLES` rendering engine. -* Render with random HDRI environment texture shading (check `assets/blender_lights`). -* Render depth (`exr`), normal, and albedo. +* Render with random built-in HDRI environment texture shading (check `assets/blender_lights`). +* Optionally render depth (`exr`), normal, and albedo. * Empirical cleaning of the scene (remove the annoying plane under the object). \ No newline at end of file diff --git a/docs/source/camera.md b/docs/source/camera.md index cc2b1f4..ebc74bb 100644 --- a/docs/source/camera.md +++ b/docs/source/camera.md @@ -1,6 +1,6 @@ # Camera -### Common world coordinate systems +### World coordinate systems ``` OpenGL/MAYA OpenCV/Colmap Blender Unity/DirectX Unreal Right-handed Right-handed Right-handed Left-handed Left-handed @@ -20,7 +20,9 @@ A common color code: x = red, y = red., up =