Hazoc Posted April 21, 2009 Share Posted April 21, 2009 Hello. I was wondering if there's a method for SHOPs to read in a signal modeled in CHOPS while calculating displacement or some other shading ? The thing is, I want to make a displacement shader for dew drops and I want to model the displaced profile of a water drop in CHOPs, instead of using a ramp parameter. I create the index (in this case the distance from a drop's center to the point being shaded) inside the shader and need to use that for sampling displacement values from the CHOP. I guess at the end I could bake signals into 1d textures if nothing else works.. Quote Link to comment Share on other sites More sharing options...
edward Posted April 22, 2009 Share Posted April 22, 2009 Offhand, I don't see an easy way to do that. My first thought is to create as many ramp points as the number of samples and then adding in chopf() expressions in the ramp marker value parameters. For this approach, scripting will be necessary for any thing more than a few samples. Without thinking it too much, baking the textures in COPs and then using them in your shader might be easier. Quote Link to comment Share on other sites More sharing options...
Hazoc Posted April 22, 2009 Author Share Posted April 22, 2009 Thanks. The only reason I don't want to use ramp is that making slopes that are more like 1x1 than 10x1 is unintuitive. Plus I find it hard to get that nice dome-like form anyway with ramp knots. I was wondering if the new motion effects feature could be extended to support ramp modeling in the future. Quote Link to comment Share on other sites More sharing options...
stevenong Posted April 22, 2009 Share Posted April 22, 2009 You should be able to read the chop data in your SHOP parameter using chop() or chopf() or even export the channel to the SHOP parameter itself. If I misunderstood what you want, please ignore me. Cheers! steven Quote Link to comment Share on other sites More sharing options...
Hazoc Posted April 22, 2009 Author Share Posted April 22, 2009 Yep, but the index value that I need to evaluate a channel at a given sample point is being produced inside a shader so it cannot be used to drive expressions set in the shader's parameters:) That's my problem. Quote Link to comment Share on other sites More sharing options...
symek Posted April 22, 2009 Share Posted April 22, 2009 Yep, but the index value that I need to evaluate a channel at a given sample point is being produced inside a shader so it cannot be used to drive expressions set in the shader's parameters:) That's my problem. I suppose you could bake your channel to an array. Rather crazy but doable... Quote Link to comment Share on other sites More sharing options...
Hazoc Posted April 22, 2009 Author Share Posted April 22, 2009 I suppose you could bake your channel to an array. Rather crazy but doable... That's what I'm about to do:) To read a chop into Pixel COP and write out a 1d texture. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
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.