Metadata-Version: 2.4
Name: heightcraft
Version: 2.0.0
Summary: A powerful and flexible height map generator
Project-URL: Repository, https://github.com/andre-silva-14/heightcraft
Project-URL: Documentation, https://andre-silva-14.github.io/heightcraft/
Author-email: Heightcraft Team <info@heightcraft.com>
License: MIT
License-File: LICENSE
Keywords: 3D model,ai,height map,lidar,rendering,terrain,upscaling,visualization
Classifier: Development Status :: 4 - Beta
Classifier: Intended Audience :: Developers
Classifier: Intended Audience :: Science/Research
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.8
Classifier: Programming Language :: Python :: 3.9
Classifier: Topic :: Multimedia :: Graphics :: 3D Modeling
Classifier: Topic :: Multimedia :: Graphics :: 3D Rendering
Classifier: Topic :: Scientific/Engineering :: Visualization
Requires-Python: >=3.8
Requires-Dist: laspy[lazrs]>=2.0.0
Requires-Dist: matplotlib>=3.3.4
Requires-Dist: numpy>=1.19.5
Requires-Dist: pillow>=9.0.0
Requires-Dist: psutil>=5.9.0
Requires-Dist: scipy
Requires-Dist: tifffile>=2023.0.0
Requires-Dist: torch
Requires-Dist: trimesh>=4.0.0
Requires-Dist: xxhash>=3.0.0
Description-Content-Type: text/markdown

<div align="center">
  <img src=".github/assets/banner.png" alt="Heightcraft Banner" width="60%" />
  
  **Heightmap Generation & AI Upscaling Tool**

  [![License](https://img.shields.io/badge/license-MIT-blue.svg)](LICENSE)
[![Python](https://img.shields.io/badge/python-3.8%2B-blue)](https://www.python.org/)
[![Documentation](https://img.shields.io/badge/docs-docusaurus-green)](./docs)
[![PyTest Coverage](https://img.shields.io/badge/coverage-90%25-green)](./tests)
</div>



**Heightcraft** is a high-performance CLI tool designed for **Game Engineers**, **GIS Professionals**, and **Researchers**. It automates the pipeline of converting 3D data into high-precision heightmaps, featuring accessible **AI Upscaling**.

---

## 🚀 Key Features

- **🤖 Heightmap AI Upscaling**: Transform low-res inputs into crisp, hi-res/high-detail heightmaps. Also supporting bit depth increase (8-bit → 16/32-bit) with AI hallucination.
- **📡 LiDAR Support**: Stream process massive `.las` and `.laz` point clouds into Digital Elevation Models (DEMs).
- **🏔️ Mesh to Heightmap**: Bake `.gltf`, `.glb`, `.obj`, `.stl`, and `.ply` meshes into heightmaps with automated chunking.
- **🌊 Feature Masks**: Optionally export water masks with sea level thresholds and texture masks for slope and curvature.
- **🎯 High Precision**: Native support for **32-bit Float TIFF**, **16-bit PNG**, and **RAW** formats.
- **⚡ Performance**: GPU acceleration and memory-efficient streaming for gigabyte-scale datasets.

## 📖 Documentation

Full documentation is available in the [Docs](https://andre-silva-14.github.io/heightcraft/).

- [**Getting Started**](https://andre-silva-14.github.io/heightcraft/docs/getting-started)
- [**LiDAR Processing**](https://andre-silva-14.github.io/heightcraft/docs/guides/lidar-processing)
- [**Mesh Processing**](https://andre-silva-14.github.io/heightcraft/docs/guides/mesh-processing)
- [**AI Upscaling Deep Dive**](https://andre-silva-14.github.io/heightcraft/docs/guides/ai-upscaling)

## 📦 Installation

```bash
pipx install heightcraft
```

## ⚡ Quick Start

**Upscale an image (8-bit → 16-bit and 3x upscale):**
```bash
heightcraft input.png --upscale --upscale-factor 3 --bit_depth 16 --output_path high_res.png
```

**Process LiDAR data into an high-res 32-bit heightmap:**
```bash
heightcraft scan.laz --bit_depth 32 --chunk_size 600000 --max_resolution 24576
```

**Convert a 3D Mesh to an upscaled heightmap:**
```bash
heightcraft terrain.obj --large-model --chunk_size 200000 --max_resolution 8192 --upscale
```

## Development

To install development dependencies:
```bash
pipx install uv
uv sync --group dev
uv run main.py
```

## 🧪 Testing

Run the test suite:

```bash
pytest tests
```
