Lighting with textures

In Blender Cycles using common lamps we can illuminate objects with any texture, not just a single color.

Add an object, for example – sphere, to the scene:

shift+a – Mesh – UVSphere

and set a simple diffuse shader to it.

Add a light source:

shift+a – Light – Spot

and direct it to the sphere.

In the “Properties” window in the light properties tab press the “Use Nodes” button to enable node tree editing for the created lamp.

Make sure the lamp is selected and open the Shader Editor window to edit its node tree.

Add ImageTexture, Mapping and TextureCoordinate nodes:

shift+a – Texture – ImageTexture

shift+a – Vector – Mapping

shift+a – Input – TextureCoordinate

and connect them as on the following image:

Open the desired texture image in the ImageTexture node. Increase the “Strength” parameter value in the Emission node. Check “Min” and “Max” checkboxes in the Mapping node to remove texture duplications, adjust location, rotation, and size.

The final node tree looks like the following:

Now you can switch to the “Render” mode to see how the lamp lights with the texture, we used.

It should be noted that this method works only with “Spot” и “Point” lamp types, which use normals.

0 0 votes
Article Rating
Subscribe
Notify of
guest

0 Comment
Newest
Oldest Most Voted
Inline Feedbacks
View all comments