All Projects → bwasty → Gltf Viewer

bwasty / Gltf Viewer

Licence: unlicense
glTF 2.0 Viewer written in Rust

Programming Languages

rust
11053 projects

Projects that are alternatives of or similar to Gltf Viewer

Hybridrenderingengine
Clustered Forward/Deferred renderer with Physically Based Shading, Image Based Lighting and a whole lot of OpenGL.
Stars: ✭ 563 (+343.31%)
Mutual labels:  opengl, 3d-graphics
Tinyrenderer
A brief computer graphics / rendering course
Stars: ✭ 11,776 (+9172.44%)
Mutual labels:  opengl, 3d-graphics
Pyrender
Easy-to-use glTF 2.0-compliant OpenGL renderer for visualization of 3D scenes.
Stars: ✭ 582 (+358.27%)
Mutual labels:  opengl, 3d-graphics
Openscad
OpenSCAD - The Programmers Solid 3D CAD Modeller
Stars: ✭ 4,444 (+3399.21%)
Mutual labels:  opengl, 3d-graphics
Assetkit
🎨 Modern 2D/3D - Importer • Exporter • Util - Library, also called (AssetIO)
Stars: ✭ 97 (-23.62%)
Mutual labels:  3d-graphics, gltf
Renderhelp
⚡️ 可编程渲染管线实现,帮助初学者学习渲染
Stars: ✭ 494 (+288.98%)
Mutual labels:  opengl, 3d-graphics
Melo
melo is mesh loader for OBJ, glTF2 and PLY
Stars: ✭ 41 (-67.72%)
Mutual labels:  opengl, gltf
f3d
Fast and minimalist 3D viewer.
Stars: ✭ 791 (+522.83%)
Mutual labels:  gltf, 3d-graphics
Pyearth
🌐 A lightweight 3D visualization of the earth in 150 lines of Qt/OpenGL
Stars: ✭ 78 (-38.58%)
Mutual labels:  opengl, 3d-graphics
3d Game Shaders For Beginners
🎮 A step-by-step guide to implementing SSAO, depth of field, lighting, normal mapping, and more for your 3D game.
Stars: ✭ 11,698 (+9111.02%)
Mutual labels:  opengl, 3d-graphics
Overload
3D Game engine with editor
Stars: ✭ 335 (+163.78%)
Mutual labels:  opengl, 3d-graphics
Tinyraycaster
486 lines of C++: old-school FPS in a weekend
Stars: ✭ 1,383 (+988.98%)
Mutual labels:  opengl, 3d-graphics
Limonengine
3D FPS game engine with full dynamic lighting and shadows
Stars: ✭ 331 (+160.63%)
Mutual labels:  opengl, 3d-graphics
Lighthouse2
Lighthouse 2 framework for real-time ray tracing
Stars: ✭ 542 (+326.77%)
Mutual labels:  opengl, gltf
Mxengine
C++ open source 3D game engine
Stars: ✭ 284 (+123.62%)
Mutual labels:  opengl, 3d-graphics
Kepler3d
OpenGL and C++14 game engine that loads glTF 2.0
Stars: ✭ 9 (-92.91%)
Mutual labels:  opengl, gltf
Tomviz
Cross platform, open source application for the processing, visualization, and analysis of 3D tomography data
Stars: ✭ 230 (+81.1%)
Mutual labels:  opengl, 3d-graphics
Arcane Engine
3D C/C++ Game Engine - Created By Brady Jessup
Stars: ✭ 242 (+90.55%)
Mutual labels:  opengl, 3d-graphics
Ueviewer
Viewer and exporter for Unreal Engine 1-4 assets (UE Viewer).
Stars: ✭ 1,083 (+752.76%)
Mutual labels:  opengl, gltf
Engine
Go 3D Game Engine
Stars: ✭ 1,362 (+972.44%)
Mutual labels:  opengl, 3d-graphics

gltf-viewer status

crates.io GitHub release Build Status Build status Docker build status Maintenance

Rust glTF 2.0 viewer, written using the gltf crate and plain OpenGL.

Current state: All official sample models can be loaded and are rendered with the reference PBR shader. Example:
SciFiHelmet
Gallery with all sample models: https://bwasty.github.io/gltf-viewer/0.3.0/

Some glTF features are not yet implemented, most notably animations. See #3 for details.

Installation

Binaries (Win/Linux/macOS)

See Latest Release

From crate (requires Rust)

cargo install gltf-viewer

Latest version (unstable):

cargo install --git https://github.com/bwasty/gltf-viewer.git

Usage

USAGE:
    gltf-viewer [OPTIONS] <FILE>

OPTIONS:
    -v, --verbose                    Enable verbose logging (log level INFO). Can be repeated up to 3 times to increase
                                     log level to DEBUG/TRACE)
    -s, --screenshot <FILE>          Create screenshot (PNG)
    -w, --width <WIDTH>              Width in pixels [default: 800]
    -h, --height <HEIGHT>            Height in pixels [default: 600]
    -c, --count <COUNT>              Saves N screenshots of size WxH, rotating evenly spaced around the object [default:
                                     1]
        --headless                   Use real headless rendering for screenshots (default is a hidden window)
                                     [EXPERIMENTAL - see README for details]
        --straight                   Position camera in front of model if using default camera (i.e. glTF doesn't
                                     contain a camera or `--cam-index -1` is passed).
        --scene <scene>              Index of the scene to load [default: 0]
        --cam-index <CAM-INDEX>      Use the glTF camera with the given index (starting at 0).
                                     Fallback if there is none: determine 'nice' camera position based on the scene's
                                     bounding box. Can be forced by passing -1.
                                     Note: All other camera options are ignored if this one is given. [default: 0]
        --cam-pos <CAM-POS>          Camera (aka eye) position override as comma-separated Vector3. Example: 1.2,3.4,5.6
        --cam-target <CAM-TARGET>    Camera target (aka center) override as comma-separated Vector3. Example:
                                     1.2,3.4,5.6
        --cam-fovy <CAM-FOVY>        Vertical field of view ('zoom') in degrees. [default: 75]
        --help                       Prints help information
    -V, --version                    Prints version information

ARGS:
    <FILE>    glTF file name

Both .gltf and .glb files are supported. Navigate the scene with the mouse: Rotate with left click + drag, pan with right click + drag, zoom with mouse wheel.

Example

$ curl -O https://raw.githubusercontent.com/KhronosGroup/glTF-Sample-Models/master/2.0/Box/glTF-Binary/Box.glb
$ gltf-viewer Box.glb

Headless screenshot generation

Proper headless screenshot generation with the --headless flag currently only works on macOS. To work around that, a Docker setup that uses xvfb is provided. Usage examples:

# Build docker image and run it with the gltf mounted in a volume.
# The image will be saved next to the gltf file.
./screenshot_docker.sh Box.glb
./screenshot_docker.sh ../models/Box.gltf -w 1920 -h 1080 --count 3 -vv
# Use pre-built docker image from Docker Hub
DOCKER_IMAGE=bwasty/gltf-viewer ./screenshot_docker.sh Box.glb

Alternatively, you can also install xvfb and use ./run_xvfb.sh directly (Linux only).

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].