2

enter image description hereHi, I did a project and I would like to texture it, I wanted to put some building textures in it, as I thought it was a night scene, I wanted the windows to be bright, but not all, so I wanted only some windows to emit light, I took a simple texture from the internet, and used colorRamp, to differentiate the windows from the walls, but they all emitted light, so as my knowledge of shaders, it's almost 0, I left the image in black and white in photoshop and erased some windows, it worked, but I would like to know if it is possible, to make the windows stay lit, just with the nodes, thank you


This is my file i want texture with windows emission

enter image description here

Robert Gützkow
  • 25,622
  • 3
  • 47
  • 78
  • 2
    if you are in Cycles and if your windows are separate meshes, you can us Input > Geometry, Random Per Island output. I don't know how you could do it in Eevee. If each of your window was a separate object, you could use the Input > Object Info > Random output, but it's not convenient – moonboots Sep 04 '21 at 09:01

1 Answers1

1

you can get random emission for each object by using this node setup:

enter image description here

The random value of object info outputs a value between 0 and 1.

The colorramp takes this value and converts it to your chosen colors.

The principled BSDF gets the color from the colorramp and use this as emission color. You can change the strength or even randomize the strength too.

Chris
  • 59,454
  • 6
  • 30
  • 84