/AliceLG

A Blender add-on for the use of Blender with the Looking Glass holographic displays.

Primary LanguagePythonGNU General Public License v3.0GPL-3.0

Alice/LG (beta) - A Blender Add-on for Looking Glass Displays

Author: Christian Stolze

Let Alice/LG take your Blender artworks through the Looking Glass! This short guide is to get you started.

About the Add-on

This add-on was created for the use of Blender with the Looking Glass holographic displays. I am not associated with the Looking Glass Factory and devoloped this add-on privately in my freetime because I'm a fan of Blender as well as the amazing new holographic display technology created by the Looking Glass Factory.

If you like this add-on and want to do a private donation, thank you for your support! I will most-likely invest it into new hardware, since rendering with an Quad-Core Intel Core i7 increases my coffee consumption way too much ...

Donate

About the Repository

This repository is to provide a beta version of the add-on to anyone who would like to test it. The source code will be uploaded as repository files soon to enable cloning and editing on GitHub. However, it is already included in the zip file for download, which is used for installation of the add-on in Blender.

Please keep in mind that this beta version of the add-on might contain errors that cause Blender to crash. If you find a bug or have any idea for a missing feature, please open an issue in this repository with a detailed description. Thank you for your help and have fun blendering your holograms! :)

Main Features

  • integration into the common Blender workflow
  • an optional view frustum representing the Looking Glass volume in the scene
  • lightfield viewport in the Looking Glass with:
    • automatic and manual refresh modes
    • a holographic mouse cursor
    • most of the features of a native Blender viewport
  • render any camera view as single quilt image or animation
  • decide if you want to keep the separate view files or just the final quilt
  • support for multiple scenes and view layers
  • camera & quilt settings are saved with your Blender file
  • support for all available Looking Glass displays (including the new Looking Glass Portrait)
  • Experimental feature: Detect incomplete render jobs (see below for details)

System Requirements

  • Windows, Linux, or macOS
  • Blender 2.83 or later
  • Optional but recommended: Holoplay Service App

Installation

  1. Optional: Install the Holoplay Service App on your PC or Mac (recommended for maximum compatability).

  2. Download the zip file of this addon.

  3. Install Alice/LG in Blender:

    • Open Blender
    • In the main menu, navigate to Edit → Preferences → Add-ons → Install → Install Add-on
    • Select the downloaded zip file and click "Install"
    • Enable the add-on by activating the check box on the left
    • Expand the preferences of the add-on by clicking on the small arrow next to the checkbox
    • Click the "Install" button to install additional Python modules in the add-on directory for an optimized add-on experience
    • Restart Blender

How to Use

Add-on Controls

After the installation you find a Looking Glass tab in each Blender viewport. Depending on your current selections, the tab shows up to four control panels & subpanels:

  • Looking Glass. Contains the Looking Glass display selection, a view resolution selection, and a button to turn on/off the lightfield window. Furthermore, it has two subpanels:

    • Camera Setup. Select one of the cameras in the scene to setup a view for the Looking Glass and the quilt rendering.

    • Quilt Setup & Rendering. Controls for starting a quilt render.

  • Lightfield Window. The lightfield / hologram is rendered to a separate window, which needs to be placed inside your Looking Glass display. In this category you find options to switch between two different modes for the lightfield Window: Viewport and Quilt Viewer. It has two subpanels:

    • Lightfield Cursor. In Viewport mode you have the option to display a lightfield mouse cursor in the lightfield window. Only works if the lightfield window is the active window.

    • Shading & Overlay Settings. If the lightfield window is in Viewport mode, it basically acts like a native Blender viewport - except that it's a holographic viewport. The settings for this (lightfield) viewport are defined here.

Lightfield Window & Viewport

The lightfield window is the place where the hologram is rendered. It can be opened via a click on the button: Looking Glass → Lightfield Window, if you have a Looking Glass connected and HoloPlay Service is running. After the window was opened, move it to your Looking Glass screen and click the Looking Glass → Toggle Fullscreen Mode button, which appeared in the add-on controls after the lightfield window was opened. (NOTE: On Windows this should happen automatically) Only in fullscreen mode the hologram will be displayed correctly in your Looking Glass. The lightfield window can operate in two modes:

  • Viewport. In viewport mode, it basically acts like a normal Blender viewport in the Looking Glass - except that it is holographic. You can choose between Auto and Manual refresh mode: In Auto mode, the hologram is re-rendered everytime something in the scene changes, while in Manual mode the hologram is only rendered if you click the refresh button. NOTE: Due to the restrictions in the rendering pipeline Blender currently has for add-on developers, this mode can be quite slow. Hopefully, their will be a solution for that provided in future versions of Blender.

  • Quilt Viewer. In the quilt viewer mode, you can load or select a rendered quilt image and display it as a hologram in the Looking Glass. So, this mode is basically here to enjoy the fruits of your work. Playing animations is not supported yet. NOTE: To display the quilt correctly, the correct quilt preset must be selected under Looking Glass → Resolution

Camera Setup & Quilt Rendering

You can render still scenes and animation frames as complete quilt images. You can render for your currently connected device or for any other Looking Glass:

(1) Rendering for your currently connected device

  • select your connected Looking Glass (if not aleady selected) and a quilt resolution under Looking Glass → Resolution
  • select an existing camera in Looking Glass → Camera Setup → Camera or create a new camera by clicking "+" in the same panel
  • check the Looking Glass → Quilt Setup & Rendering → Use Device Settings checkbox
  • locate the camera to the specific view you would like to render
  • adjust the render and post-processing settings in the usual Blender panels (NOTE: Image dimensions are overwritten by the add-on based on your connected Looking Glass or your manual settings under Looking Glass → Quilt Setup & Rendering)
  • click on Looking Glass → Quilt Setup & Rendering → Render Quilt or Looking Glass → Quilt Setup & Rendering → Render Animation Quilt in the add-on controls.

(2) Rendering for other Looking Glasses

  • select an existing camera in Looking Glass → Camera Setup → Camera or create a new camera by clicking "+" in the same panel
  • uncheck the Looking Glass → Quilt Setup & Rendering → Use Device Settings checkbox, if it is checked
  • choose the Looking Glass you want to render for from the list Looking Glass → Quilt Setup & Rendering → Device
  • choose the quilt preset/resolution you want to render for from the list _Looking Glass → Quilt Setup & Rendering → Quilt
  • locate the camera to the specific view you would like to render
  • adjust the render and post-processing settings in the usual Blender panels (NOTE: Image dimensions are overwritten by the add-on based on your connected Looking Glass or your manual settings under Looking Glass → Quilt Setup & Rendering)
  • click on Looking Glass → Quilt Setup & Rendering → Render Quilt or (if you want to render animation frames) Looking Glass → Quilt Setup & Rendering → Render Animation Quilt in the add-on controls.

The Render Quilt option will render the different views separately. After the last view has been rendered, a quilt will be automatically assembled. For the Render Animation Quilt option, the same will happen for each frame of the animation, which will result in one quilt per frame. After rendering, the created quilt image or animation frames have to be handled in the same way as normal renders. You can still render normal (non-holographic) images in Blender as you usually do.

NOTE: Option (2) can be used even if no Looking Glass is connected.

Incomplete Render Jobs (Experimental)

The add-on attempts to detect Blender crashes during quilt rendering as well as quilt animation rendering and prompts you with an option to continue or to discard an incomplete render job the next time you open the crashed file. The successful detection of an incomplete render job and its continuation requires that:

  • the filename of the .blend-file did not change
  • the file was saved before starting the render job OR no significant changes happended to the setup (e.g., camera position, render settings, etc.)
  • the (temporary) view files of the incomplete render job are still on disk and not corrupted

While the add-on tries to check some basic settings, the user is highly recommended to check if the current render settings fit to the settings used for the incomplete render job before clicking the "Continue" button.

If you decide to discard the incomplete render jobs, the add-on will try to delete the view files of the incomplete render job.

NOTE: This feature is considered to be 'experimental'. It might not detect crashes under all circumstances and might not succeed to continue the rendering always. If you encounter a situation were this feature failed, please submit a detailed bug report.

License & Dependencies

The Blender add-on part of this project is licensed under the GNU GPL v3 License.

This Blender add-on partially relies on the following GPL-compatible open-source libraries / modules and their dependencies: