[HtoA] Example package file


Here’s the package file I’m currently using.

{
    "load_package_once": true,
    "env":
    [
        {"HTOA_PACKAGE": "HTOA"},
        {
            "HTOA_INSTALL_PATH" :
            [

                {"houdini_version == '20.0.506'": "D:/programs/htoa/htoa-6.2.5.0_re21740b_houdini-20.0.506/htoa-6.2.5.0_re21740b_houdini-20.0.506"},
                {"houdini_version == '20.0.547'": "D:\programs\htoa\htoa-6.2.5.1_r539f2c5_houdini-20.0.547\htoa-6.2.5.1_r539f2c5_houdini-20.0.547"}
            ]
        },
        {"HTOA_STARTUP_LOG": 3},
        {"HTOA_MAKETX_WORKERS": 30},
        {"HOUDINI_PATH": [
                {
                    "value": "$HTOA_INSTALL_PATH",
                    "method": "prepend"
                }
            ]
        },
        {"HOUDINI_TEXT_CONSOLE": [
                {
                    "value": "1",
                    "method": "append"
                }
            ]
        },
        {"HDARNOLD_DEBUG_SCENE": [
		                {
		                    "value": "C:/temp/hdarnold_debug.ass",
		                    "method": "append"
		                }
		            ]
        },
        {"HOUDINI_SPLASH_MESSAGE": "Loading HtoA: $HTOA_PACKAGE"},
        {"PATH": [
                {
                    "value": "$HTOA_INSTALL_PATH/scripts/bin",
                    "method": "prepend"
                }
            ]
        }
    ]
}

[HTOA] How to…use append mode in Solaris


Append mode (aka check-pointing) allows you to restart an interrupted render, and render just the remaining tiles. Those tiles are “appended” to the tiles that were rendered before.

If you’re using the Arnold Render Settings LOP,  the Append check box is under File Output > Driver Options. You have to enable Arnold product type for any of the driver options to work.

If you’re using the regular Render Settings LOP, you can turn on Append mode in the Render Product LOP. Don’t forget to change the Product Type to arnold.

Looking for the Arnold API Reference?


Here’s the table of contents for the API Reference

Writing an Arnold-based app:

Core data structures:

Writing plug-in extensions:

Writing shaders:

The case of the hrender that failed to start AdskLicensingAgent


Or, “things that happen when you use single-user licensing on a render node” 😉

In this case, a Houdini command-line render with Arnold (HtoA) failed because the AdskLicensingAgent failed to start.

---------------------------
AdskLicensingAgent
---------------------------
This application failed to start because no Qt platform plugin could be initialized. Reinstalling the application may fix this problem.

Available platform plugins are: minimal, offscreen, webgl, windows.

---------------------------
OK  
---------------------------

After AdskLicensingAgent crashed, the render would continue, but license authorization would fail:

00:00:00   148MB         | authorizing with license manager: user ...
00:00:31   153MB WARNING | rendering with watermarks because of failed authorization:
00:00:31   153MB         |  [clm.v2] timeout before callback was called

Using Process Monitor, I saw (as expected) that the problem was that the AdskLicensingAgent was loading Qt platform plugins from Houdini:

The solution? Set QT_QPA_PLATFORM_PLUGIN_PATH to point to the AdskLicensingAgent\platforms folder.

set QT_QPA_PLATFORM_PLUGIN_PATH=C:\Program Files (x86)\Common Files\Autodesk Shared\AdskLicensing\Current\AdskLicensingAgent\platforms

Troubleshooting HtoA installs


If you have a problem like this:

  • HtoA does not show up in Houdini
  • the HtoA material nodes are missing
  • or you get node type errors such as
    • Failed to match node type definition
    • Error: bad node type found
    • Unknown operator on load

that is almost always because the environment (PATH and HOUDINI_PATH) is not set up correctly for HtoA and Houdini.

First, how to do you start Houdini? Don’t double-click on a hip file, because the Houdini environment won’t be set up correctly.

Second, what’s your houdini.env look like?
You want something like this (PATH is for Windows only):

# htoa config start
PATH = "$PATH;C:/arnold/htoa/htoa-5.6.0.0_r370661f_houdini-18.0.597/htoa-5.6.0.0_r370661f_houdini-${HOUDINI_VERSION}/scripts/bin"
HOUDINI_PATH = "C:/arnold/htoa/htoa-5.6.0.0_r370661f_houdini-18.0.597/htoa-5.6.0.0_r370661f_houdini-${HOUDINI_VERSION};&"
# htoa config end

Third, check Help > About Houdini > Show Details
You want to see the HtoA location at the start of HOUDINI_PATH

If you have other renderers and plugins, I would remove all other plugins from HOUDINI_PATH, get HtoA working, and then put the other stuff back.

If you need more help, please send support your houdini.env file (or json package if that’s what you’re using) and the Houdini info from Show Details.

NEW: Getting a trial license for Arnold


To get a trial license, go to the Free Trial page at https://www.autodesk.com/products/arnold/trial-intake

You have to click the Download button. That’s what generates the trial license and adds it to your Autodesk account. But you don’t need that download (it’s the Arnold SDK, not an Arnold plugin), so Cancel that download after it starts.

You can download the Arnold plugin of your choice from arnoldrenderer.com/download.

To use the trial license, install the Arnold plugin and then start the Arnold License Manager and sign in.

[HtoA] Denoising light group AVOs with noice


To use the Arnold Denoiser (noice) on light groups, you need to have variance AOVs for the light group AOVs.

There are two ways to associate a variance AOV with a light group AOV.

  • Use the same light path expression (LPE) for both the light group AOV and the variance AOV.

    For example, the “red” and “red_variance” AOVs use the same LPE: C.*<L.'red'>
  • Use the same name for both AOVs, but give the variance AOV a different layer name.

    For example, suppose you give both AOVs the name “RGBA_green”. Then give the variance AOV a different layer name, like “RGB_variance_green”

Use the same light path expression (LPE) for both the light group AOV and the variance AOV.

Give the light group and variance AOVs the same name, but different layer names

Then to denoise the AOVs:

noice -i "light_group_denoise.0001.exr" -o C:\temp\denoised.exr -pr 3 -sr 3 -l red -l RGBA_green
noice 7.1.1.0 [72784a51] - the Arnold denoiser
Using 8 threads.
Loading images...
Loading file "light_group_denoise.0001.exr".
Using feature AOV 'denoise_albedo' with filter 'gaussian_filter'
Using feature AOV 'N' with filter 'gaussian_filter'
Using feature AOV 'Z' with filter 'gaussian_filter'
Working with 1 frame at 1280x720
Will denoise AOV "RGBA", using associated variance
   Output file will be "C:\temp\denoised.exr"
Will denoise AOV "RGBA_green", using associated variance
   Output file will be "C:\temp\denoised.exr"
Will denoise AOV "red", using associated variance
   Output file will be "C:\temp\denoised.exr"
Start denoising (patch radius 3, search radius 3, variance 0.5)
Denoising RGBA
Denoising RGBA_green
Denoising red
Finished denoising
Saving image C:\temp\denoised.exr (1280 x 720 x 12)

Add -irgba to that if you want to skip denoising the beauty. Note that with -irgba. the beauty AOV won’t be copied to the output file. Only the denoised AOVs go the output file.

All the AOV, LPE, and layer information that you set up in HtoA goes into EXR metadata.
noice uses that metadata to find the variance AOVs for each AOV. The association may be through the AOVs having the same name, or the AOVs using the same explicit LPE.

error: (44) Product key not found


If you get this error, it means that Arnold is not registered in the Autodesk product information file.

With Arnold 5.3 and later, you use the AdskLicensingInstHelper tool (all Autodesk software now uses AdskLicensingInstHelper). The pitreg utility was removed in Arnold 5.3

Note AdskLicensingInstHelper requires that the Autodesk Licensing Service is installed and running on the machine.

For example:

sudo /opt/Autodesk/AdskLicensing/Current/helper/AdskLicensingInstHelper register --pk C0PL1 --pv 2020.0.0.F --lm NETWORK -cf /opt/Autodesk/arnold/maya2019-4.2.0/license/ArnoldConfig.pit

or

"C:\Program Files (x86)\Common Files\Autodesk Shared\AdskLicensing\Current\helper\AdskLicensingInstHelper.exe" register --pk C0PN1 --pv 2022.0.0.F --lm NETWORK --cf "C:\Program Files\Autodesk\Arnold\maya2022-5.0.0.2\license\ArnoldConfig.pit"

In addition to registering Arnold in the global ProductInformation.pit file used by all Autodesk products, AdskLicensingInstHelper also registers Arnold with the Autodesk licensing service (that’s for single-user licensing).

The ProductInformation.pit file is located here:

  • /var/opt/Autodesk/Adlm/.config/ProductInformation.pit
  • C:\ProgramData\Autodesk\Adlm\ProductInformation.pit
  • /Library/Application Support/Autodesk/Adlm/.config/ProductInformation.pit

Here’s the help for the register command:

C:\Users\blairs>"C:\Program Files (x86)\Common Files\Autodesk Shared\AdskLicensing\Current\helper\AdskLicensingInstHelper.exe" -help register
NAME:
   AdskLicensingInstHelper - Manage products registration with Autodesk Licensing

USAGE:
   AdskLicensingInstHelper.exe [global options] command [command options] [arguments...]

VERSION:
   2.11.0.666

COMMANDS:
     register    Register product with the licensing components. Requires admin rights
     deregister  Deregister product from the licensing components. Requires admin rights
     list        List all products registered with licensing components
     change      Change registered product
     help, h     Shows a list of commands or help for one command

GLOBAL OPTIONS:
   --verbose, -d  [O] Output verbose log
   --help, -h     show help
   --version, -v  print the version

signal caught: error C0000005 — access violation


People often ask me why they get this error…

Unfortunately, there’s no one answer. This is a totally generic error message, and it could be anything. Typically, it’s a bug somewhere. But where?

You could try to manually isolate it…is it shaders? textures? displacement? some object in the scene?

Ideally, you’ll be able to submit a Crash Error Report (CER). That would let us see where the crash actually happened.

Crash Error Report

The backtrace in an Arnold log won’t tell you, because we hide all the symbols in the shipping Arnold. So every backtrace comes out with things like Ordinal0 or AiLightsPrepare or AiADPDialogStrings, because those just happens to be the nearest unhidden symbols.

If you had a linux backtrace, we could symbolicate that on our end to see where the crash is happening. But on Window, it’s not so easy.

****
* Arnold 7.0.0.1 [5e3b4fd3] windows clang-10.0.1 oiio-2.3.2 osl-1.12.0 vdb-7.1.1 clm-2.0.0.235 rlm-14.1.3 optix-6.6.0 2021/11/18 13:08:38
* CRASHED in Ordinal0 at 00:00:00, pixel (946, 377)
* signal caught: error C0000005 -- access violation
*
* backtrace:
>> 0 0x00007ffb083cc387 [ai      ] Ordinal0
*  1 0x00007ffb08a24b56 [ai      ]
*  2 0x00007ffb0891cd0c [ai      ]
*  3 0x00007ffb087eaa92 [ai      ] AiLightsPrepare
*  4 0x00007ffb088ce771 [ai      ]
*  5 0x00007ffb088d4ef6 [ai      ]
*  6 0x00007ffb0870b67a [ai      ] Ordinal0
*  7 0x00007ffb09244186 [ai      ] AiADPSendPayload
*  8 0x00007ffb09243da3 [ai      ] AiADPSendPayload
*  9 0x00007ffb08db0a54 [ai      ] AiADPSendPayload
* 10 0x00007ffb09245414 [ai      ] AiADPSendPayload
* 11 0x00007ffb0989a74c [ai      ] AiADPSendPayload
* 12 0x00007ffb0989a8ed [ai      ] AiADPSendPayload
* 13 0x00007ffbd77c1bb2 [ucrtbase] configthreadlocale
* 14 0x00007ffbd8807034 [KERNEL32] BaseThreadInitThunk
* 15 0x00007ffbd9d22651 [ntdll   ] RtlUserThreadStart