|
I have three questions about a function of real-time shader of Softimage 7.5 adv.
1.Is it possible to use a directx(9 and 10) real time shader on particles (point cloud)?
When I applied directx real-time shader to a polygon mesh, it worked. However, when I tried to apply same directx real-time shader to particles, it didn’t work and show anything.
Is the way to bring a position of particles different to a polygon mesh? I wonder if I can get a position of particles in directx shader. If it is not possible, let me know whether there are any other possible solutions to get particle’s position and apply a directx reatime shader on particles. I hope you can give me any alternative way to get the solution.
This is my vertex and pixel shader code. I just tried very simple one, and it didn’t work on particles.
<vertex shader code>
struct VS_OUTPUT
{
float4 pos : POSITION;
float4 color : COLOR0;
};
VS_OUTPUT main(
float4 pos :POSITION,
uniform float4x4 simodelviewproj
)
{
VS_OUTPU Out;
Out.pos= mul(simodelviewproj,pos)
Out.color=float4(1,1,1,1)
return Out;
}
struct VS_OUTPUT
{
float4 pos : POSITION;
float4 color : COLOR0;
};
float4 main(VS_OUTPUT Out) : COLOR
{
//Out.color=float4(1,1,1,1)
return float4(1,1,1,1)
}
2. Is it possible to use a multi pass render or a render target function, when I want to build a render tree using directx?
If it’s not possible, should I make a real-time shader node for render tree using XSISDK?
3. Can I use a geometry shader yet, when I write a shader code in OpenGL or Cg mode?
|