merged mesh vs grouped by behavior

Begin with a repeatable camera and interaction sequence. Record the current render statistics and visible behavior. A static overview alone is not enough for a configurator whose most expensive state appears after opening panels or switching options.

Group parts by behavior before geometry

Classify parts as fixed, selectable, movable, replaceable, or repeated. Record which parts share materials and which need independent identity.

part behavior classes five items

Three.js describes geometry merging as one approach to reducing object-related overhead. Use it where the resulting object can behave as a unit. Keep a door separate if it opens independently, even when its material matches the cabinet body.

If a merged region still needs selection, plan how a hit maps back to the product part. Do not discard that identity and attempt to reconstruct it later from appearance.

Use instancing for genuinely repeated parts

Consider InstancedMesh when many parts share geometry and material but differ in placement. Maintain a stable mapping from each instance to its product meaning.

instance to product part mapping

Repeated handles or fasteners are candidates only if their required appearance and behavior fit the implementation. Independently replacing a part, using a different material, or changing its geometry can alter the choice.

Test picking, highlighting, bounds, and updates after adopting instancing. A visually correct first frame does not establish that the selection system still identifies the right component.

Review material partitions

Inspect whether superficially identical materials are separate for a reason. Consolidate only when the product does not need independent behavior that depends on those assignments.

Merging geometry while retaining many material groups may preserve more draw submissions than expected. Inspect the output instead of assuming one object means one draw call.

merged object multiple material groups

Keep transparency and special render behavior in the test. An optimization suitable for opaque fixed parts may be inappropriate for another region.

Preserve part identity alongside batching

For an instanced group, map the raycast result's instance ID to a stable product-part ID. Rebuilding instance order requires rebuilding that mapping. A highlighted handle should still refer to the same orderable component after a configuration change.

For merged fixed geometry, keep the metadata required by any remaining selection system. Merging does not necessarily make picking impossible, but it removes the original object boundaries unless the application preserves another mapping.

Compare render calls with the same shadow and post-processing configuration. One mesh can contain multiple material groups, and additional passes can submit it more than once. A lower scene-object count therefore does not establish a specific reduction in draw calls or frame time.

Before approval, repeat an entire interaction: select the part, change its finish, open a moving component, restore the product, and select the part again. Measure the change only after those behaviors remain correct.

Measure the complete interaction

Use the renderer statistics with the same scene, viewport, and sequence before and after the change. Record more than the final object count.

Repeat selection, material switching, opening parts, and restoring the default state. Check that a selected component still matches the order or product record. Inspect whether the optimization adds update work elsewhere.

fixed interaction sequence measurement

Accept the change when it improves the measured target without losing required behavior. Keep a comparison record and a reversible source scene. The best grouping is determined by how the product works in the experience, not by a rule that every assembly should become one mesh.