Skip to content

Support for clearing HDRI background #1226

@kevinfoley

Description

@kevinfoley

Describe your feature request

BlenderProc offers a method set_world_background_hdr_img() which we can use to load an HDRI image as the scene background. This method creates new nodes, but does not remove previous nodes. If we use the function repeatedly (e.g. to load different background images for different camera angles), unused nodes from previous backgrounds remain in the scene (they will be overlapping in the Shader Editor, so move the nodes around to reveal unused leftover nodes). This could be considered a memory leak and may be problematic if we load many different backgrounds.

Perhaps there should be a function for clearing any previous background HDR image, which we could call manually and would also be automatically called by set_world_background_hdr_img().

Describe a possible solution

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions