Jump to content

I3d Question


pld

Recommended Posts

Hi All,

I've created a POPnet which has metaballs attached to particles. I'm happy with the simulation however I wanted to know if there's a way to control the color and alpha of the particles when using i3d. I can easily do it if I use a surface shader (using the pointSOP) to render the metaballs... is it possible to do it with the VEX3D texture FOG? Would I have to write my own i3d shader?

thanks for your help!

Link to comment
Share on other sites

Hi All,

I've created a POPnet which has metaballs attached to particles. I'm happy with the simulation however I wanted to know if there's a way to control the color and alpha of the particles when using i3d.

21468[/snapback]

To control the "alpha" I would just use copy stamping to control the weight of the metaball.

This will control the density of each metaball and hence control the alpha.

for color you'll need to modify one of the existing i3d shaders so that it writes out an i3d image

with an extra channel for color. In order to get the color off of the metaballs you'll need to make

use of the vex function mattrib(). I think someone has already done this and posted it on odforce,

so have a look around.

feel free to ask questions if you run into trouble

Luca

Link to comment
Share on other sites

To control the "alpha" I would just use copy stamping to control the weight of the metaball.

This will control the density of each metaball and hence control the alpha.

Luca

21471[/snapback]

Hi Luca,

if I change the weight of the metaballs, won't this simply affect their pulling power with respect to other metaballs? What I'm trying to achieve is smoke that gradually disappears after some time. The way it is set up at the moment is annoying because the particles die after a given time and this results in smoke vanishing from one frame to another...Hence was trying to fade out that effect

patrick

Link to comment
Share on other sites

For some reason I can't stamp $ALPHA only $LIFE for my stamping expression for the metaball weight. Any thoughts as to why?

21491[/snapback]

The copy sop is limited to the local variables that it supports have a look at the help card

for a list. That being said, $LIFE is supported by the copy sop, so it should work.

for a variable like $ALPHA, or any other attribute, you'll want to use the point expression.

type:

exhelp point

in the textport to see the help.

the point expression to retrieve the alpha value would probably look something like this:

point("../mySopWithAlpha",$PT,"Alpha",0)

let me know if you run into trouble

Luca

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...