You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The aspell-python-py3 requirement is optional to enable spell check.
136
136
137
+
You may need to set the `QT_PREFERRED_BINDING` or `QT_PREFERRED_BINDING_JSON`
138
+
[environment variable](https://github.com/mottosso/Qt.py?tab=readme-ov-file#override-preferred-choice) to ensure that PrEditor can use PyQt5/PyQt6.
137
139
138
140
# DCC Integration
139
141
140
-
## Maya
141
-
142
-
PrEditor is pre-setup to use as a Maya module. To use it, create a virtualenv
143
-
with the same python as maya, or install it using mayapy.
144
-
145
-
```
146
-
virtualenv venv_preditor
147
-
venv_preditor\Scripts\activate
148
-
pip install PrEditor
149
-
set MAYA_MODULE_PATH=c:\path\to\venv_preditor\Lib\site-packages\preditor\dccs
150
-
```
151
-
Note: Due to how maya .mod files works if you are using development installs you
152
-
can't use pip editable installs. This is due to the relative path used
153
-
`PYTHONPATH +:= ../..` in `PrEditor_maya.mod`. You can modify that to use a hard
154
-
coded file path for testing, or add a second .mod file to add the virtualenv's
155
-
`site-packages` file path as a hard coded file path.
156
-
142
+
Here are several example integrations for DCC's included in PrEditor. These
143
+
require some setup to manage installing all pip requirements. These will require
144
+
you to follow the [Setup](#setup) instructions below.
145
+
146
+
-[Maya](/preditor/dccs/maya/README.md)
147
+
-[3ds Max](/preditor/dccs/studiomax/README.md)
148
+
149
+
If you are using hab, you can simply add the path to the [preditor](/preditor) folder to your site's `distro_paths`. [See .hab.json](/preditor/dccs/.hab.json)
150
+
151
+
## Setup
152
+
153
+
PrEditor has many python pip requirements. The easiest way to get access to all
154
+
of them inside an DCC is to create a virtualenv and pip install the requirements.
155
+
You can possibly use the python included with DCC(mayapy), but this guide covers
156
+
using a system install of python.
157
+
158
+
1. Identify the minor version of python that the dcc is using. Running `sys.version_info[:2]` in the DCC returns the major and minor version of python.
159
+
2. Download and install the required version of python. Note, you likely only need to match the major and minor version of python(3.11 not 3.11.12). It's recommended that you don't use the windows store to install python as it has had issues when used to create virtualenvs.
160
+
3. Create a virtualenv using that version of python. On windows you can use `py.exe -3.11` or call the correct python.exe file. Change `-3.11` to match the major and minor version returned by step 1. Note that you should create separate venvs for a given python minor version and potentially for minor versions of Qt if you are using PyQt.
161
+
```batch
162
+
cd c:\path\to\venv\parent
163
+
py -3.11 -m virtualenv preditor_311
164
+
```
165
+
4. Use the newly created pip exe to install PrEditor and its dependencies.
166
+
* This example shows using PySide and the simple TextEdit workbox in a minimal configuration.
* This example shows using QScintilla in PyQt6 for a better editing experience. Note that you need to match the PyQt version used by the DCC, This may require matching the exact version of PyQt.
This is an example of using an Maya module to add PrEditor into Maya. This adds
4
+
a PrEditor menu with a PrEditor action in Maya's menu bar letting you open PrEditor. It
5
+
adds the excepthook so if a python exception is raised it will prompt the user
6
+
to show PrEditor. PrEditor will show all python stdout/stderr output generated
7
+
after the plugin is loaded.
8
+
9
+
# Setup
10
+
11
+
Make sure to follow these [setup instructions](/preditor/README.md#Setup) first to create the virtualenv.
12
+
13
+
Alternatively you can use [myapy's](https://help.autodesk.com/view/MAYAUL/2026/ENU/?guid=GUID-72A245EC-CDB4-46AB-BEE0-4BBBF9791627) pip to install the requirements, but a
14
+
separate virtualenv is recommended. This method should not require setting the
15
+
`PREDITOR_SITE` environment variable even if you use an editable install.
16
+
17
+
# Use
18
+
19
+
The [preditor/dccs/maya](/preditor/dccs/maya) directory is setup as a Maya Module. To load it in
20
+
maya add the full path to that directory to the `MAYA_MODULE_PATH` environment
21
+
variable. You can use `;` on windows and `:` on linux to join multiple paths together.
22
+
You will need to enable auto load for the `PrEditor_maya.py` plugin.
Copy file name to clipboardExpand all lines: preditor/dccs/studiomax/README.md
+4-40Lines changed: 4 additions & 40 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -8,46 +8,10 @@ output generated after the plugin is loaded.
8
8
9
9
# Setup
10
10
11
-
PrEditor has many python pip requirements. The easiest way to get access to all
12
-
of them is to create a virtualenv and pip install the requirements. You can possibly use the python included with 3ds Max, but this guide covers using a system install of python.
13
-
14
-
1. Identify the minor version of python that 3ds Max is using. 3ds Max 2025 and 2026 are both using python 3.11. The version of python is printed when you first activate python mode in the Scripting Listener.
15
-
2. Download and install the required version of python. Note, you likely only need to match the major and minor version of python(3.11 not 3.11.12). It's recommended that you don't use the windows store to do this as it has had issues when used to create virtualenvs.
16
-
3. Create a virtualenv using that version of python. On windows you can use `py.exe -3.11` or call the correct python.exe file.
17
-
```batch
18
-
cd c:\path\to\venv\parent
19
-
py -3.11 -m virtualenv preditor_venv
20
-
```
21
-
4. Use the newly created pip exe to install PrEditor and its dependencies.
22
-
* This example shows using PySide and the simple TextEdit workbox in a minimal configuration.
* This example shows using QScintilla in PyQt6 for a better editing experience. Note that you need to match the Qt version used by 3ds Max. Both 2025 and 2026 use 6.5.3.
Make sure to follow these [setup instructions](/preditor/README.md#Setup) first to create the virtualenv.
30
12
31
13
# Use
32
14
33
-
There are a few environment variables that need to be set. They can be set permanently, but this
34
-
example shows setting them temporarily for the current command prompt window.
35
-
Note that these paths are referencing the site-packages folder of the virtualenv.
36
-
37
-
1. Open a command prompt.
38
-
2. Set the `ADSK_APPLICATION_PLUGINS` variable. This env var is used by 3ds Max to load the package defined by the PackageContents.xml file. If you are using an editable install of PrEditor, this should point to it's `preditor\dccs\studiomax` folder not inside the virtualenv's site-packages.
39
-
```batch
40
-
set "ADSK_APPLICATION_PLUGINS=c:\path\to\venv\parent\preditor_venv\Lib\site-packages\preditor\dccs\studiomax"
41
-
```
42
-
3. Set the `PREDITOR_SITE` variable. This env var is used to make the packages in the virtualenv's site-packages accessible in 3ds Max's python. The virtualenv is only used to handle the pip installations, 3ds Max doesn't activate the virtualenv, it just makes its site-packages folder importable.
43
-
```batch
44
-
set "PREDITOR_SITE=c:\path\to\venv\parent\preditor_venv\Lib\site-packages"
45
-
```
46
-
4. Optional: If using QScintilla, you will also need to force Qt.py to load it instead of PySide by setting `QT_PREFERRED_BINDING` or `QT_PREFERRED_BINDING_JSON`.
47
-
```batch
48
-
set "QT_PREFERRED_BINDING=PyQt6"
49
-
```
50
-
5. Launch 3ds Max.
51
-
```batch
52
-
"C:\Program Files\Autodesk\3ds Max 2026\3dsmax.exe"
53
-
```
15
+
The [preditor/dccs/studiomax](/preditor/dccs/studiomax) directory is setup as a 3ds Max Application Plugin.
16
+
To load it in 3ds Max add the full path to that directory to the `ADSK_APPLICATION_PLUGINS` environment
17
+
variable. You can use `;` on windows and `:` on linux to join multiple paths together.
0 commit comments