Skip to main content

A Renderer built for the SceneProg project

Project description

SceneProgRenderer

SceneProgRenderer is a Python-based Blender automation tool for rendering scenes programmatically. It allows users to generate high-quality renders, including 360-degree animations, custom camera angles, and transparent background images using Blender’s Python API.

🚀 Features

  • Scene Loading & Setup

    • Clears the scene and loads a new .blend file.
    • Applies smooth shading and fixes materials.
    • Adds an environment texture for realistic lighting.
  • Rendering Options

    • Single Render: Capture an image from a specified camera position.
    • Front/Top Views: Render images from standard viewpoints.
    • Corner Views: Automatically position the camera at four scene corners.
    • Edge Midpoints: Position the camera at four upper midpoints of the scene.
    • 360-Degree Animation: Generate a rotating video render.
  • Supports Transparent Backgrounds

    • Renders images with RGBA and film transparency for compositing.

📦 Installation

pip install sceneprogrenderer

📜 Usage

Importing the package:

from sceneprogrenderer import SceneProgRenderer

Initializing the Renderer

renderer = SceneProgRenderer(
    resolution_x=1920,
    resolution_y=1080,
    samples=128,
    frame_rate=30,
    num_frames=360,
    cuda=False,
    verbose=False,
)

Generic Render

renderer.render(
  path="scene.blend",
  output_path="output.png",
  location=(2, 2, 2),       ## Camera location
  target=(0, 0, 0),         ## Target location
)

Render from corners or edge midpoints

renderer.render_from_corners(
  path="scene.blend",
  output_paths=["corner1.png", "corner2.png", "corner3.png", "corner4.png"],
)

renderer.render_from_edge_midpoints(
  path="scene.blend",
  output_paths=["edge1.png", "edge2.png", "edge3.png", "edge4.png"],
)

Render from front or top views

renderer.render_from_front_view(
  path="scene.blend",
  output_path="front_view.png",
)

renderer.render_from_top_view(
  path="scene.blend",
  output_path="top_view.png",
)

Render 360-degree animation

renderer.render_360_animation(
  path="scene.blend",
  output_path="360_animation.mp4",
)

Project details


Download files

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

Source Distribution

sceneprogrenderer-0.1.2.tar.gz (6.8 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

sceneprogrenderer-0.1.2-py3-none-any.whl (7.0 kB view details)

Uploaded Python 3

File details

Details for the file sceneprogrenderer-0.1.2.tar.gz.

File metadata

  • Download URL: sceneprogrenderer-0.1.2.tar.gz
  • Upload date:
  • Size: 6.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.10.16

File hashes

Hashes for sceneprogrenderer-0.1.2.tar.gz
Algorithm Hash digest
SHA256 07f37dc1028bbb641f24d91996e41947a923514b4048a7ad1353878aed181374
MD5 2005c6fec8e79b61f3e508180119fade
BLAKE2b-256 0fbe3e3207da96d0a22a96bff4c3024862c1dc23858d82137ba22056208a5a06

See more details on using hashes here.

File details

Details for the file sceneprogrenderer-0.1.2-py3-none-any.whl.

File metadata

File hashes

Hashes for sceneprogrenderer-0.1.2-py3-none-any.whl
Algorithm Hash digest
SHA256 ae22114209992c6025408e025a10523ec2abc82052d92187f65653faf5c4f5e7
MD5 9a087f3028894ebc7026b7e53314cc2a
BLAKE2b-256 601c24a975fd69a1e7126d592fbd26fe10fc37ccb55c308fbe189e675468e185

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page