Git Product home page Git Product logo

blendify's Introduction

blendify Logo

Introduction

Blendify is a lightweight Python framework that provides a high-level API for creating and rendering scenes with Blender. Developed with a focus on 3D computer vision visualization, Blendify simplifies access to selected Blender functions and objects.

Key features of Blendify:

  1. Simple interface: Blendify provides a user-friendly interface for performing common visualization tasks without having to dive into the complicated Blender API.

  2. Easy integration: Blendify seamlessly integrates with development scripts, implementing commonly used routines and functions:

    • native support of point clouds, meshes, and primitives;
    • support of per-vertex colors and textures;
    • advanced shadows with shadow catcher objects;
    • video rendering with smooth camera trajectories;
    • support for common camera models;
    • import and export of .blend files for deeper integration with Blender.
  3. Quick start: Blendify is easy to get started with and does not require a standalone Blender installation. All you need to do is run pip install blendify.

Installation instructions

Install from pip

pip install blendify

Optional requirements

pip install blendify[utils / examples / docs / all]

Running examples 4 and 5 requires PyTorch with PyTorch3D.

Running example 5 requires SMPL model files, please refer to the installation instructions in README.

Quick Start

# Script to render cube
from blendify import scene
from blendify.materials import PrincipledBSDFMaterial
from blendify.colors import UniformColors
# Add light
scene.lights.add_point(strength=1000, translation=(4, -2, 4))
# Add camera
scene.set_perspective_camera((512, 512), fov_x=0.7, quaternion=(0.82, 0.42, 0.18, 0.34), translation=(5, -5, 5))
# Create material
material = PrincipledBSDFMaterial()
# Create color
color = UniformColors((0.0, 1.0, 0.0))
# Add cube mesh
scene.renderables.add_cube_mesh(1.0, material, color)
# Render scene
scene.render(filepath="cube.png")

Examples

Cornell Box Color, albedo and depth
Mesh with texture Camera colored point cloud
SMPL movement NURBS trajectory

Works that use blendify

Contributors

Blendify is written and maintained by Vladimir Guzov and Ilya Petrov.

Acknowledgments

We thank Verica Lazova for providing her Blender rendering scripts. Our code for processing point clouds is mostly based on the amazing Blender-Photogrammetry-Importer addon.

License

The code is released under the GNU General Public License v3.

The Python logo is trademark of Python Software Foundation. The Blender logo is a registered property of Blender Foundation. Blender-Photogrammetry-Importer is distributed under the MIT License. Blender is released under the GNU General Public License v3.

blendify's People

Contributors

ptrvilya avatar vguzov avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.