how to reduce render time?

I have about 23 boxes, each of them with a 150x150 texture and a line (both box and line have the same material, but each of the box/lines pair has a different texture/material from the others).

It’s taking a lot of time to render - I’m still at 30fps, but really on this system I should be flying as this is all I’m doing.

All these box/line pair are each inside a geometry component. all the geometry components are inside another geometry component.

this is what I see in the performance monitor - what am I doing wrong?

render Updating Camera View 0.016 2.026 2.042 1
render Prepping Nodes For Render 0.074 2.042 2.116 1
render Pre-Render 0.067 2.116 2.183 1
render Rendering 0.016 2.183 3.044 1
render Rendering a group of SOP(s) 1 0.002 2.188 2.252 2
render Setting Up Material 0.010 2.189 2.207 3
gfx Enabling Phong Shader 0.008 2.198 2.206 4
render Rendering Primitive Batch(s) 35 0.042 2.208 2.252 3
render Waiting for Geometry to be sent to GPU 0.002 2.209 2.211 4
render Rendering a group of SOP(s) 1 0.000 2.253 2.294 2
render Changing Material 0.004 2.253 2.259 3
gfx Enabling Phong Shader 0.002 2.256 2.258 4
render Rendering Primitive Batch(s) 42 0.034 2.259 2.294 3
render Waiting for Geometry to be sent to GPU 0.001 2.260 2.261 4
render Rendering a group of SOP(s) 1 0.001 2.294 2.330 2
render Changing Material 0.002 2.295 2.300 3
gfx Enabling Phong Shader 0.003 2.297 2.300 4
render Rendering Primitive Batch(s) 33 0.029 2.300 2.330 3
render Waiting for Geometry to be sent to GPU 0.001 2.301 2.302 4
render Rendering a group of SOP(s) 1 0.000 2.331 2.371 2
render Changing Material 0.002 2.331 2.336 3
gfx Enabling Phong Shader 0.003 2.333 2.336 4
render Rendering Primitive Batch(s) 45 0.034 2.336 2.371 3
render Waiting for Geometry to be sent to GPU 0.001 2.337 2.338 4
render Rendering a group of SOP(s) 1 0.001 2.372 2.409 2
render Changing Material 0.002 2.372 2.377 3
gfx Enabling Phong Shader 0.003 2.374 2.377 4
render Rendering Primitive Batch(s) 42 0.030 2.378 2.409 3
render Waiting for Geometry to be sent to GPU 0.001 2.378 2.379 4
render Rendering a group of SOP(s) 1 0.000 2.410 2.446 2
render Changing Material 0.003 2.410 2.415 3
gfx Enabling Phong Shader 0.002 2.412 2.414 4
render Rendering Primitive Batch(s) 35 0.029 2.415 2.446 3
render Waiting for Geometry to be sent to GPU 0.002 2.415 2.417 4
render Rendering a group of SOP(s) 1 0.001 2.446 2.476 2
render Changing Material 0.003 2.447 2.452 3
gfx Enabling Phong Shader 0.002 2.449 2.451 4
render Rendering Primitive Batch(s) 25 0.023 2.452 2.476 3
render Waiting for Geometry to be sent to GPU 0.001 2.453 2.454 4
render Rendering a group of SOP(s) 1 0.001 2.477 2.509 2
render Changing Material 0.003 2.477 2.482 3
gfx Enabling Phong Shader 0.002 2.480 2.482 4
render Rendering Primitive Batch(s) 27 0.025 2.483 2.509 3
render Waiting for Geometry to be sent to GPU 0.001 2.483 2.484 4
render Rendering a group of SOP(s) 1 0.001 2.510 2.529 2
render Changing Material 0.003 2.510 2.515 3
gfx Enabling Phong Shader 0.002 2.512 2.514 4
render Rendering Primitive Batch(s) 8 0.011 2.515 2.528 3
render Waiting for Geometry to be sent to GPU 0.002 2.515 2.517 4
render Rendering a group of SOP(s) 1 0.002 2.529 2.548 2
render Changing Material 0.002 2.530 2.534 3
gfx Enabling Phong Shader 0.002 2.532 2.534 4
render Rendering Primitive Batch(s) 8 0.012 2.535 2.548 3
render Waiting for Geometry to be sent to GPU 0.001 2.535 2.536 4

hard to say without seing the file, but one reason it’s slower than it needs to be is that by using a seperate geometry COMP every piece of geometry, this gets rendered using multiple batches. So to reduce rendertime, you should put all your boxes into a single geometry COMP and assign the textures via 2DtextureArrays.

For the lines, I assume they just have a different color, so I would put them all into a second Geometry object and assign a single shader to it, but use pointcolors to control the shading. Or you use the same 2dtexture approach as desribed above, maybe even putting everything into a single geo object

btw, if you use the perform DAT and save out the stats as a table and attach that one, it’s easier to read and analyse the output.

how to create 2dtexturearrays?

does anyone have any example they can post on how to use this method?

I’m assuming Achim you’re saying to create one big texture and use uv offsets to the various sops I’ve merged together. I could do that just comping the textures and offsetting uvs, but what is the 2DTextureArray method you talk about?

thanks,
dani

2D texture arrays are created in the Texture 3D TOP (because they are very similar in how they are created and how they are used).

but how are they used, is there a wiki explanation of what they are and how they can be used?

derivative.ca/wiki/index.php … ture_Array

they are mostly useful for GLSL MATs, but if you assign texture coordinates that are integer 0, 1, 2, 3, you can reference the different array slices in the Phong MAT also.