Skip to main content

LiVision

LiVision is a lightweight C++ 3D visualizer for rapid prototyping with ImGui and ImPlot.

PPA liblivision-dev build

✨ Features

  • 🧪 Rapid Prototyping: Fast setup for visual experiments and ideas.
  • 🔷 Primitive-Rich Drawing: Plane, box, sphere, cylinder, cone, and more.
  • 🗂️ Container-Based Group Control: Move/transform multiple objects together.
  • 🌐 3D Object Coverage: Meshes, models, and SDF-based objects.
  • 📊 ImGui + ImPlot UI: Quick interactive tools and plotting dashboards.

🚀 Quick Start

📦 Installation

Install from PPA

sudo add-apt-repository ppa:hamatakuzaq/livision
sudo apt update
sudo apt install -y liblivision-dev

Install from source

sudo apt update
sudo apt install -y \
  build-essential \
  cmake \
  pkg-config \
  git \
  libsdl2-dev \
  libeigen3-dev \
  libsdformat14-dev \
  libassimp-dev \
  libcurl4-openssl-dev

git clone https://github.com/hamataku/LiVision.git --recursive
mkdir -p LiVision/build && cd LiVision/build
cmake ..
make -j"$(nproc)"
sudo make install

🛠️ CMake Example

# Find package
find_package(livision REQUIRED)

# Add include dirs and link libraries
add_executable(your_program
  src/your_program.cpp
)
target_link_libraries(your_program
  livision::livision
)

💻 Example Program

#include "livision/Viewer.hpp"
#include "livision/marker/Grid.hpp"
#include "livision/object/primitives.hpp"

int main() {
  auto viewer = livision::Viewer::Instance({
      .width = 1280,
      .height = 720,
  });

  // UI callback
  float theta = 0;
  viewer->RegisterUICallback([&]() {
    ImGui::SliderFloat("theta", &theta, 0, M_PI * 2.0F);
    if (ImGui::Button("Close")) {
      viewer->Close();
    }
  });

  // Grid
  auto grid = livision::Grid::Instance({.scale = {15.0, 15.0, 0.0}});
  grid->SetResolution(1.0)->SetColor(livision::color::dark_gray);
  viewer->AddObject(grid);

  // Sphere
  auto sphere =
      livision::Sphere::Instance({.pos = {0.0, 0.0, 0.0},
                                  .scale = {2.0, 2.0, 2.0},
                                  .color = livision::color::rainbow_z,
                                  .wire_color = livision::color::black});
  viewer->AddObject(sphere);

  while (viewer->SpinOnce()) {
    sphere->SetRadRotation({0, 0, theta});
  }
  return 0;
}

🐍 Python

The same API is available from Python (pybind11). Building from source takes a few minutes.

pip install .
import livision as lv

viewer = lv.Viewer()
viewer.add_object(lv.Grid(scale=[15.0, 15.0, 0.0]))
viewer.add_object(lv.Sphere(scale=2.0, color=lv.color.rainbow_z, wire_color=lv.color.black))
while viewer.spin_once():
    pass

See the Python guide for the full mapping from C++.

📄 License

MIT. See LICENSE. Third-party notices are listed in NOTICE.

🙏 Special thanks to koide3/iridescene, which greatly inspired this project.

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

livision-0.3.7.tar.gz (9.8 MB view details)

Uploaded Source

File details

Details for the file livision-0.3.7.tar.gz.

File metadata

  • Download URL: livision-0.3.7.tar.gz
  • Upload date:
  • Size: 9.8 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for livision-0.3.7.tar.gz
Algorithm Hash digest
SHA256 4e3e22999bd63e4b4a65f669812b683514b86258750de62b7ddf8ce220031ed1
MD5 61bf30962861818b274b8f936965cdd3
BLAKE2b-256 6b3770f05fdca3f7bd4fbb412079dd338cf153156062bd4133fc771111f9a0fe

See more details on using hashes here.

Provenance

The following attestation bundles were made for livision-0.3.7.tar.gz:

Publisher: pypi.yml on hamataku/LiVision

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Release history Release notifications | RSS feed

0.3.8

1 file

This release

0.3.7 This release

1 file

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page