Since its inception in 1988, Blender has gone through many challenges, tweaks, and improvements to become the software we know today. In 2002, one of the biggest and most significant changes came when Blender was reborn as a non-profit organization, and the software became an open-source distribution under the GNU General Public License (GPL), thanks to the “Free Blender” campaign. This allowed interested parties to freely and actively participate in improvements and tweaks to the software.

This change attracted many artists, designers, and enthusiasts worldwide, as the software’s functionalities were superior to other options available at the time. Another important factor that facilitated ongoing developments was the integration of Python into Blender. This integration was a game changer for software improvements and has since paved the way for early experiments to create AI tools for Blender.

In November 2022, OpenAI released the ChatGPT 3.5, which shook the technological world with breathtaking innovations. Among other things, the AI tool is capable of composing music, creating texts, and, of course, programming scripts. Improvements with the release of GPT-4 have turned attention even more towards the possibilities of AI.

As Blender has evolved to the point where it can execute commands through code, many are using ChatGPT to create customized scripts that support their creative workflow. In this article, we’ll introduce you to some concrete ways that users are combining these powerful tools to support their creative process. You just might be amazed!

Featured image of Blender
All Things
Blender

Back to Contents

Blender & ChatGPT: Are AI-Generated 3D Models a Thing?

How They Work Together

Fun with AI
Fun with AI (Source: Kruithne via Gumroad)

Thanks to a built-in Python interpreter that remains active while Blender is running, users are able to run custom scripts that access resources in Blender, create new tools for the interface, or draw and edit objects with the built-in tools, among many other possibilities. At users request, ChatGPT draws upon several sources of knowledge in its database, including information about programming and Blender commands, to create Python scripts for Blender.

However, there’s more than one way to run a Python script in Blender. Blender’s API interface can interpret and execute both direct commands and modules, it’s important to know what you’re doing so as not to generate instability and errors in the software.

When loading and directly executing a script, the created classes remain available even after the script is closed, and this can generate errors and failures in the program. When the script is loaded as a module, the classes will remain within its instances, facilitating new access and avoiding problems. As

The dangers mentioned above reveal the continued importance of having Python programming skills. In theory, ChatGPT does exactly what a Python programmer would do in an API, but there are certain limitations.

Limitations

Not quite the house on the beach that Alex had in mind
Not quite the house on the beach that Alex had in mind (Source: Blender Academy via YouTube)

Despite significant advances, AI is still not perfect and is susceptible to errors and failures. These are rooted not only in how it interprets your request but also in how the script is interpreted and executed in Blender. AI is only intelligent because it’s trained to understand information, texts, and verbal requests, then use its database to create a response within the requested context.

For example, ChatGPT may produce a script that interprets your request differently than what you had envisioned. Manual adjustments may be required. With general technical knowledge and Python programming skills, it’ll be easier to spot where the AI went wrong and adjust to script to make it work as expected. This is certainly the case with more complex scripts.

Lastly, there are also differences between AI versions as there are in programs. ChatGPT 3.5 is powerful enough to work with texts but doesn’t recognize images, has a shorter memory, and draws from less training data than version 4. 3.5’s intelligence database is limited to data produced until the year 2021.

Just as the interpretation depends on what and how something is requested from ChatGPT, the AI ​​also depends on the available information to formulate a precise and assertive answer. If you’re requesting something related to a command for a newer version of Blender created after 2021, ChatGPT will answer that this command doesn’t exist, that it’s not possible, or will give a result that won’t work as expected. The same can also happen if you’re on a very old version of Blender, but the AI-generated command refers to something from a newer Blender version.

Despite its limitations, working with ChatGPT and Blender together can help both lay users as well as professionals to optimize their workflow. In the next few sections, we’ll discuss exactly how that’s being done.

Back to Contents

Advertisement
Advertisement

Examples

In the following sections, we will discuss some specific examples of how Blender users are integrating ChatGPT into their workflow for creating in Blender.

Back to Contents

Advertisement
Blender & ChatGPT: Are AI-Generated 3D Models a Thing?

Writing Scripts

Write or paste scripts?
Write or paste scripts? (Source: Dr. Ho's ELearning Blog)

Above, we saw that there’s more than one way to load Python scripts in Blender. This opens up different possibilities to integrate the AI. The most obvious one is to ask ChatGPT to create a purpose-built Python script for you to use in Blender.

If you don’t understand anything about programming, no problem! When generating scripts, ChatGPT includes comment lines that describe what each line of code does. You then copy, load, and run that script in Blender.

The key to successfully working with AI is to be precise with your requests. For example, if you ask ChatGPT to create a ball in Blender without specifying that you need a script command that can be used in the Blender API interface, ChatGPT may respond that it alone does not have the ability to create objects in Blender. It might return step-by-step instructions on how to execute the necessary commands. It could even return its interpretation of a “ball”, which could range from a sphere to a mere two-dimensional circle in a random size.

Simpler requests are more likely to yield predictable results, yet complex requests may butt up against the interpretative limitations of the AI. Attention to detail and patience are essential. Knowing Blender commands and the context of the tools helps a lot, too. The AI ​​will more easily associate what you’re requesting with the correct software tool or function.

Examples

  • Step by step: YouTuber ADMCGI demonstrates how to use ChatGPT to make Python script for Blender.
  • Limitations: In addition to explaining how to write scripts, Alex from Blender Academy explains some of the pitfalls in the process and how to overcome them.
  • More efficient workflow: In addition to creating objects, you can create scenes as well as edit and even apply modifiers and animations. Stray Creations provides some great examples of how ChatGPT can save you hours of work.

Back to Contents

Advertisement
Advertisement
Blender & ChatGPT: Are AI-Generated 3D Models a Thing?

Using Add-Ons

Fully integrated AI
Fully integrated AI (Source: gd3kr via GitHub)

As we mentioned earlier on, the fact that Blender is open source has enabled many to participate in the development of the software. There is a vast number of community-developed add-ons that enhance Blender’s features and functionality. It hasn’t taken indie developers long to start releasing ChatGPT-related add-ons.

Rather than copying and pasting scripts, these add-ons actually integrate the power of AI directly into Blender’s graphical interface. Most take the form of a chat interface that’s accessible in the 3D viewport. Users enter their requests, and the AI executes its interpretation of the command as actions in Blender.

At the time of writing, all of these add-ons will need to be downloaded and installed into Blender. You’ll also need to set up an API key with access to the OpenAI tool used by the add-on.

Examples

  • BlenderGPT: This add-on allows you to enter natural language text commands to create in Blender. The developer says users can use either GPT-3.5 or GPT-4. YouTuber Stray Creations demonstrates how to use it.
  • Blender-GPT: This add-on is similar to the previous – and not only in name. It’s billed as “the all-in-one Blender assisted powered by GPT-3/4”. The main differentiation from the previous add-on is its ability to accept voice commands. These are converted into text, then into a script that is executed by Blender’s Python interpreter. A video by YouTuber TopChannel1on1 demonstrates how it works.
  • Blender Copilot: This add-on is based on BlenderGPT and includes new features and improvements such as a small history of requests and a selection field for either GPT-3.5 or 4, among others.

Back to Contents

Advertisement
Advertisement
Blender & ChatGPT: Are AI-Generated 3D Models a Thing?

Creating New Add-ons

Creating the functionality you want to see in Blender
Creating the functionality you want to see in Blender (Source: Mikkel Nielsen via Gumroad)

In the same way that scripts are created with ChatGPT, it’s possible to ask the AI ​​to develop code for custom-built add-ons. Instead of copying and pasting the code directly into Blender, you copy and paste the code into a text editor program, save it with a .py file extension, then install this file as a normal add-on in Blender. Usually, ChatGPT explains the whole process when you ask it to make the add-on.

It’s important to test the script before creating and installing the add-on in Blender. After all, adjustments may be needed, which you can either do yourself or ask ChatGPT to do so by pointing out the errors Blender reports to the AI.

Examples

  • Step by step: Bobo 3D shows you how to create and install a custom-built add-on without any coding experience whatsoever. For even simpler text creation, Wanderson experimented with ChatGPT to create and fine-tune an add-on.
  • RenderAll: This is an add-on created with the help ChatGPT that allows users to render all cameras in a scene with the press of a button. Blender Viking explains how it was created.
  • When all goes wrong: You’re likely to experience success with this method for simpler tasks. Elaborate processes may result in some frustration. YouTuber SouthernShotty shows you why.

Back to Contents

Advertisement
Advertisement
Advertisement