particles inherit color

   5201   1   0
User Avatar
Member
523 posts
Joined: July 2005
Offline
Hello,


I have got a textured grid.

How can I let my particles emitting from this grid, inherit the color of the texture?

Example: red part of texture emits red particles, green part emits green particles, and so on…


thanks,



bern
User Avatar
Member
1908 posts
Joined: Nov. 2006
Offline
In order to have your particles inherit the color of the surface they are emitting from, you must have applied a point color attribute.

In this example, an image is read in through a file COP and, using the ‘pic()’ function, is projected onto the grid using the bounding box X and Z values as UV coordinates. This transfers the colors to the points on the grid and allows particles to inherit them. The shader afterwards merely applies a material shader that understands the point color attributes in order for the color to be rendered.

Attachments:
particle_colors.hip (388.4 KB)

Graham Thompson, Technical Artist @ Rockstar Games
  • Quick Links