HtoA Assigning materials

HtoA Assigning materials

Matthew_Zinn
Not applicable
2,311 Views
11 Replies
Message 1 of 12

HtoA Assigning materials

Matthew_Zinn
Not applicable

I've got an alembic file with multiple materials imported in Houdini from another program. When I create multiple materials and try a render preview, the screen just gets stuck "Generating Scene". If I try just one material it works fine, though it assigns that material to the entire mesh regardless of the group I tell it to use. In Mantra everything works as expected in terms of creating and assigning multiple materials to different groups. I've tried this with the same result using both CPU and GPU rendering.

0 Likes
2,312 Views
11 Replies
  • htoa
Replies (11)
Message 2 of 12

Stephen.Blair
Community Manager
Community Manager

Can you render to disk or mplay? Enable file logging and increase the Arnold vebosity, and try that.

Or, can you test exporting to ass?



// Stephen Blair
// Arnold Renderer Support
0 Likes
Message 3 of 12

Matthew_Zinn
Not applicable

doesnt work either. I get the following error:


Interestingly. If I seperate out each group using a blast and then assign each group a material that way and merge them all together, it works just fine...


Error

Command Exit Code: -6

00:00:00 75MB | [hick] Received: AA: 3 3
00:00:00 76MB | [hick] Received: begin
00:00:00 76MB | [hick] Batch mode
00:00:00 76MB | log started Wed Feb 24 12:29:48 2021
00:00:00 76MB | Arnold 6.2.0.1 [903992ac] windows clang-10.0.1 oiio-2.2.1 osl-1.11.6 vdb-7.1.1 clm-2.0.0.235 rlm-12.4.2 optix-6.6.0 2021/02/09 10:40:42
00:00:00 76MB | running on 3Zvfx-PC, pid=6432
00:00:00 76MB | 1 x Intel(R) Core(TM) i7-5930K CPU @ 3.50GHz (6 cores, 12 logical) with 32594MB
00:00:00 76MB | NVIDIA driver version 460.89 (Optix 60800)
00:00:00 76MB | GPU 0: GeForce RTX 3070 @ 1725MHz (compute 8.6) with 8192MB (7413MB available) (NVLink:0)
00:00:00 76MB | GPU 1: GeForce GTX 1070 Ti @ 1683MHz (compute 6.1) with 8192MB (7135MB available) (NVLink:0)
00:00:00 76MB | Windows 10 (version 10.0, build 19041)
00:00:00 76MB | soft limit for open files raised from 512 to 2048
00:00:00 76MB |
00:00:00 76MB | [hick] Start
00:00:00 76MB | [hick] Received: log_verbosity: 7942
00:00:00 76MB | [hick] Received: log_console_enable: 1
00:00:04 173MB ERROR | [polymesh] /obj/_2021_Kia1/PARENT_Kia_001/Kia_RIG/Kia_K5_GT_2021/Kia_K5_GT_2021/polygons: out-of-range shader index (2/2)
00:00:04 173MB ERROR | [polymesh] /obj/_2021_Kia1/PARENT_Kia_001/Kia_RIG/Kia_K5_GT_2021/Kia_K5_GT_2021/polygons: out-of-range shader index (2/2)
00:00:04 173MB ERROR | [polymesh] /obj/_2021_Kia1/PARENT_Kia_001/Kia_RIG/Kia_K5_GT_2021/Kia_K5_GT_2021/polygons: out-of-range shader index (2/2)
00:00:04 173MB ERROR | [polymesh] /obj/_2021_Kia1/PARENT_Kia_001/Kia_RIG/Kia_K5_GT_2021/Kia_K5_GT_2021/polygons: out-of-range shader index (2/2)
00:00:04 173MB ERROR | [polymesh] /obj/_2021_Kia1/PARENT_Kia_001/Kia_RIG/Kia_K5_GT_2021/Kia_K5_GT_2021/polygons: out-of-range shader index (2/2)
00:00:04 174MB WARNING | Aborted by user: received abort signal



0 Likes
Message 4 of 12

Stephen.Blair
Community Manager
Community Manager

Given the "out-of-range shader index" errors, the workaround sounds about right.

Is there any way we can get the files to reproduce and investigate this?
You can send something to support @ arnoldrenderer . com



// Stephen Blair
// Arnold Renderer Support
0 Likes
Message 5 of 12

julian.hodgson
Advocate
Advocate

Can you provide a simple example scene showing the issue?

0 Likes
Message 6 of 12

Stephen.Blair
Community Manager
Community Manager

@

I have the scene here in support



// Stephen Blair
// Arnold Renderer Support
0 Likes
Message 7 of 12

T.RoyH86
Explorer
Explorer

I have exactly the same problem, Arnold won't
render any more than one material per object, if you group primitives (faces) and assign them a
material, then Arnold doesn't render.

0 Likes
Message 8 of 12

T.RoyH86
Explorer
Explorer

I have come from Softimage then Maya and it is very frustrating to have to blast the geometry into separate objects, then group the separated pieces into groups which will receive the same materials, then assign all the groups to the required materials in a material sop, if you don't do this then Arnold will refuse to render. Mantra has no problems with assigning different materials to an object by grouping primitives and assigning them a material, so what the hell is wrong with Arnold, has it always been like this or is it a bug.

0 Likes
Message 9 of 12

Stephen.Blair
Community Manager
Community Manager

The exact same problem would be if you are using Alembic, and unpacking the alembic procedural before assigning a material. Is that what you are doing?

If so, then there are other ways to apply materials to alembic files:

  • Use the AssignMaterial ROP if you can pick out the desired object with a selection expression
  • Export alembics that include the shop_materialpath property so that the material assignment is done on translation




// Stephen Blair
// Arnold Renderer Support
0 Likes
Message 10 of 12

Slava_91
Advocate
Advocate

some part of the primitives is not in groups and does not have material, assign one material to full alembic cache, and only then assign materials to groups


0 Likes
Message 11 of 12

alainh3d
Contributor
Contributor

I get exactely the same error... Blasting every group and re-merging it all together fixes it...

0 Likes
Message 12 of 12

hamed_nabilpour
Contributor
Contributor

this method worked for me, first created one material node for the object, then created another material node for the object's parts.

0 Likes