MeshMatcapNodeMaterial
A node material that defines an object's appearance using a 'Material Capture' (Matcap) texture. It maps the texture based on the surface normals relative to the camera, simulating complex lighting and reflections with a single image, but it is not affected by actual scene lights. [1, 8] It is the node-based version of MeshMatcapMaterial.
Core Advantages
Extremely performant because it bakes lighting and reflection information into a single texture, requiring only one texture lookup during rendering without complex light calculations. [2, 10, 11] This allows it to achieve highly stylized looks, such as clay, cartoons, or metallic finishes, at a very low cost. [4, 5]
Common Uses
Digital sculpting previews (similar to ZBrush or Blender) [1, 4]
Creating non-photorealistic rendering (NPR) and toon effects [4]
Rendering complex-looking materials like ceramics or metals cheaply [3]
Quick model visualization and debugging in scenes where dynamic lighting is not needed [1]
Performance-critical applications, such as mobile projects [5]
How to adjust
The primary way to adjust its look is by changing the texture referenced by the `matcap` property; different Matcap textures produce entirely different visual effects. [6] You can also tint the Matcap texture using the `color` property. Although it doesn't respond to lights, you can add surface detail using a `bumpMap` or `normalMap` to make it react to normal changes. [8]
Code Examples
1<mesh>
2 <torusKnotGeometry args={[0.4, 0.15, 128, 32]} />
3 {/* The matcap property requires a pre-loaded texture object */}
4 <meshMatcapNodeMaterial matcap={matcapTexture} />
5</mesh>