CLI Setup Guide
Installation & Set-Up
Download
In order to obtain the RapidPipeline 3D Processor CLI package for the OS of your choice, navigate to CLI page on https://app.rapidpipeline.com/cli.
In order to run the CLI, you will need an rpd_account.json file on your computer as well as an account with an Enterprise Plan on https://app.rapidpipeline.com and a valid API token. Start with the account file first:
Make sure to download only the CLI installers with version number 7.0 or higher = 3D Processor. For version 6.x or lower please refer to the Legacy Documentation
Account File Setup
Please download the file from here. It then can be put in a place of your choosing, we would recommend creating a “3d-processor” folder in your root directory. For example on windows this would be:
C:\3d-processor\rpd_account.json
Windows
Here are the steps to set it up on Windows:
- Navigate to control panel / System&Security / System / Advanced System Settings / Environment Variables
- Click on “New…” and name the environment variable “RPD_ACCOUNTFILE”, then you can either simply browse the rpd_account.json file or type in the exact path; In this example that is: “C:\3d-processor\rpd_account.json”. This is it. You are almost all set!
MacOS
First of all the MacOS 10.15 Catalina Update introduced a change from the Commandline Tool "bash" to "zsh@.
To know which shell is being used, type this command in the terminal:
echo "$SHELL"
To switch to “zsh” type in the following command:
chsh -s /bin/zsh
To switch to “bash” type in the following command:
chsh -s /bin/bash
Similar to the windows setup you will need to save the rpd_account.json file somewhere on your system.
Let's assume your file is under /Users/YOUR_USER_NAME/Documents/ rpd_account.json
(replace the username, you can check what is your username in the terminal using the command "whoami").
To configure the environment variable, you can use the terminal:
For Catalina, if using "zsh" enter this command in the terminal (make sure the command is in one single line):
echo 'export RPD_ACCOUNTFILE=/Users/YOUR_USER_NAME/Documents/rpd_account.json' >> ~/.zshenv
When using the "bash" shell, use this instead:
echo 'export RPD_ACCOUNTFILE=/Users/YOUR_USER_NAME/Documents/rpd_account.json' >> ~/.bash_profile
After this, when you open a new terminal, rpdx should find the file. You can confirm the variable is set using this command:
echo $RPD_ACCOUNTFILE
Linux
Again, similar to the windows setup you will need to save the rpd_account.json file somewhere on your system.
Let's assume your file is under /home/YOUR_USER_NAME/rpd_account.json
To configure the environment variable, use the following command:
export RPD_ACCOUNTFILE=/home/YOUR_USER_NAME/rpd_account.json
You can confirm the variable is set using this command:
echo $RPD_ACCOUNTFILE
API Token Generation
Log in on https://app.rapidpipeline.com and navigate to your account settings on the top right corner -> API Tokens. Now name your token to your liking and hit “Create API Token”:
You can then copy the token string once (it won’t be accessible through the Web interface later, for security reasons) and then insert it into your account file, which you did set up before:
{
"host" : "api.rapidpipeline.com",
"token" : "YOUR API TOKEN HERE"
}
In order to track usage and receive data for technical support the CLI will share some information with DGG. HTTPS license authentication request uses end-to-end encryption.
Shared Data to the DGG License Server
- Your command line (commands and parameters)
- Your optimization settings
Data which is not shared with the DGG License Server
- Any 3D model data
- Any texture data
- Any statistics about your 3D model
- File names (obfuscated)
You should now be able to use the 3D Processor CLI by opening your systems’ command line and type “rpdx”.
If you are looking for commands and what configurable parameter settings the 3D Processor CLI has to offer, please visit our CLI Documentation.
Hardware Requirements
Hardware | Recommendation | Description |
---|---|---|
Processor | x86-64 CPU, 8vCPUs recommended | rpdx makes use of multiple cores/threads for the following operations: UV unwrapping, texture baking, rendering |
RAM | 1GB minimum, 16GB recommended | The amount of RAM required is highly dependent on the input models and operations performed. |
Hard disk space | Ubuntu: 100MB, macOS: 85MB, Windows: 85MB | Executable and libraries only. |
Graphics Card | Not used | rpdx can run headless, it has no dependencies on OS graphics APIs. rpdx does not support GPU acceleration. |
Memory Usage Estimation
Basic estimation
The following provides a conservative estimation on the amount of memory necessary to compact a 3D model using rpdx. In some cases, the estimate could be much higher than the actual number.
inputMem = numInputTris * 36 + numInputVertices * 64 + numInputTexels * 3
totalMem = 100MB + (inputMem + numOutputTexels * 3) *4
Note, that all of the values used in the calculation can be printed or written from any given input or output files using the following commands:
rpdx -i foo.bar -p
rpdx -i foo.bar --write_info
Precise estimation
This estimation should be more accurate but may in some cases be under the target. The number of vertices can be approximated as 0.75* numTriangles for many models.
inputEstimationGeo = inTris * 3 * 3 * 4 + inVerts * (3 + 3 + 2) * 8
# assuming tangents are needed (baking normalmaps)
outputEstimationGeo = outTris * 3 * 4 * 4 + outVerts * (3 + 3 + 6 + 2) * 8
estimation = (100 * 1024 * 1024) + (inputEstimationGeo + inTexels * 3) * 2 + (outputEstimationGeo + outTexels * 3) * 2