Change the bitmap file in a DirectX shader
Hello everyone,
I'm working on a simple way to create bitmap texture in a DirectX material. The steps:
1) (we create a Dx shader: ) meditMaterials[1] = DirectX_9_Shader ()
2) (we load the StandardFx shader: ) meditMaterials[1].effectfile = "\maps\fx\StandardFX.fx"
3) here must be the bitmap file in the diffuse...
I can check the bitmap file in the Dx shader, with this...:
meditMaterials[1].g_TopTexture
...and the result is (for example) : "Bitmap:D\test01.jpg"
But when i write this...:
meditMaterials[1].g_TopTexture = Bitmap:D\test02.jpg
...it is not work.
What is the right syntax of this line?
meditMaterials[1].g_TopTexture = ... what?
Thanks your answers in advance,
Matyrix
Comments
I have a script that utilizes
I have a script that utilizes the StandardFX.fx but the problem I am having is that I do not know how to programmatically turn on/off the texture usage.
How do I turn on Top Diffuse Color Enable (or bottom, specular, normal, etc) via MAXScript as I would via the UI?
Thanks in advance.
_______________________
Shawn Olson
Developer of Wall Worm
Got an answer over at the
Got an answer over at the Area: http://area.autodesk.com/forum/autodesk-3ds-max/maxscript/directx-shader...
_______________________
Shawn Olson
Developer of Wall Worm
Anubis, le1setreter: really
Anubis, le1setreter: really thanks for your help! it works fine!
try this: myTextureMap =
try this:
I'm searching the solution,
I'm searching the solution, and i have seen that this question was asked on the CGTalk:
http://forums.cgsociety.org/archive/index.php/t-519984.html
But there is no good result, i think what Dave Black wrote is not the best solution in my case.
So i hope you have got some tipps...
bMap = openBitMap
my recent MAXScripts RSS (archive here)