trueSpace seems to be equiped with a large number of math nodes.
Unfortunately I don't know how to use them. I have no Scalar float, no Vector floats, no Integer or Boolean float input. I can't really use the Math Nodes (or I have no idea how to).
How do I create a Boolean input? Or a Scalar (that isn't a "float" input)? How do I use all these nodes? How do I connect all these nodes together?
And ultimately, how do I convert a scalar number into an integer!? (main goal)
How to use Math Nodes?
- clintonman
- Captain
- Posts: 5434
- Joined: 21 May 2009, 21:08
- Type the number ten into the box: 0
- Location: California
- Contact:
Re: How to use Math Nodes?
I think the math nodes are only for use inside materials.
- Draise
- Captain
- Posts: 3200
- Joined: 21 Sep 2009, 19:33
- Type the number ten into the box: 0
- Location: Bogota, Colombia
- Contact:
Re: How to use Math Nodes?
Oh. So I'd need to create these with Javascript and make my own nodes?
Re: How to use Math Nodes?
I think the Math nodes can be used for Objects and the Component nodes can be used for Materials.
All of these nodes are compiled and are more efficient compared to using it in Jscripts.
You can also use the BinaryOp and UnaryOp with math operands like * = multiply, \ = Divide, etc... HLSL Script Brick is used for D3D materials and is a different language. Scalar is the same as a Real number in Rosetta.
All of these nodes are compiled and are more efficient compared to using it in Jscripts.
You can also use the BinaryOp and UnaryOp with math operands like * = multiply, \ = Divide, etc... HLSL Script Brick is used for D3D materials and is a different language. Scalar is the same as a Real number in Rosetta.
You do not have the required permissions to view the files attached to this post.
- Draise
- Captain
- Posts: 3200
- Joined: 21 Sep 2009, 19:33
- Type the number ten into the box: 0
- Location: Bogota, Colombia
- Contact:
Re: How to use Math Nodes?
Ah yes, I use the BinaryOp and UnaryOp a lot. They work with Real Number, or Scalar as you say! Yeah!
I'd like to convert a Scalar to an Integer or boolean though.. I guess I don't know how to "round" out scalars using the BinaryOp, or basic maths. I'd need an "If" node no?
I can't seem to use the Math nodes with any BinaryOp or UnaryOp.
I'd like to convert a Scalar to an Integer or boolean though.. I guess I don't know how to "round" out scalars using the BinaryOp, or basic maths. I'd need an "If" node no?
I can't seem to use the Math nodes with any BinaryOp or UnaryOp.
- clintonman
- Captain
- Posts: 5434
- Joined: 21 May 2009, 21:08
- Type the number ten into the box: 0
- Location: California
- Contact:
Re: How to use Math Nodes?
The formula node is neat. See the before and after the formula is entered at the lower right.
I found the info below in a beta version of the original tS manual in the reference section.
http://clintons3d.com/stuff/" onclick="window.open(this.href);return false; the file is named ts7_help.chm
Binary Op takes +, -, *, /, max, min
Unary Op takes sin, cos, abs, pow, neg
"Math Formula node finds variables in given formula, adds these variables as connectors and compute result of the formula depending on values of variables. Node recognizes and computes following strings in the formula:
- binary operations: ^,*,/,-,+
- functions: sin, cos, tan, arcsin, arcos, sqrt, ln, log ,exp
- constants: PI, real numbers
- variables: any other strings
Example of formula: (a+c)*sin(a+c)-PI*log(c+d)/3.2
"
You do not have the required permissions to view the files attached to this post.
- Draise
- Captain
- Posts: 3200
- Joined: 21 Sep 2009, 19:33
- Type the number ten into the box: 0
- Location: Bogota, Colombia
- Contact:
Re: How to use Math Nodes?
Very handy your help file! Now I understand a bit more about scripting and making node programming in trueSpace. I can see potential to make particle systems, rough AI systems, and other things - even procedural geometry.. hmm.... just thinking.
I also know.. that with the power of Javascript I can.. and did make my Float to Integer (Scalar to Integer) converter. I am still learning Javascript, but it's kinda working. Now I can make a pixelized character of a sort. Let me first make a proof of concept..... hmm.
I still don't have much clue as to know how to apply trigonometry though with the Sin, Con and others...
Download Float (Scalar or Real Number) to Integer
I also know.. that with the power of Javascript I can.. and did make my Float to Integer (Scalar to Integer) converter. I am still learning Javascript, but it's kinda working. Now I can make a pixelized character of a sort. Let me first make a proof of concept..... hmm.
I still don't have much clue as to know how to apply trigonometry though with the Sin, Con and others...
Download Float (Scalar or Real Number) to Integer
Re: How to use Math Nodes?
If you make it with a jScript Object you will not need the Watch Dog, which can be unreliable when encapsulated.
You do not have the required permissions to view the files attached to this post.
Re: How to use Math Nodes?
Hey Draise.
Not sure if a node exists but you can convert (force) a scalar to an integer by casting it to type: int.
Also not sure how to do that in jscript; it's been quite awhile since I've delved into code; doing less fun
stuff lately (like boring documentation ugh!).
Not sure if a node exists but you can convert (force) a scalar to an integer by casting it to type: int.
Also not sure how to do that in jscript; it's been quite awhile since I've delved into code; doing less fun
stuff lately (like boring documentation ugh!).