Neuron®
The Neuron® is the basis for the creation of open and secure federated networks for smart societies.
Loading...
Searching...
No Matches
PhongMaterialOutput.cs
1using System;
2using System.Text;
5
7{
12 {
18 public Grade Supports(Type Object) => Object == typeof(PhongMaterial) ? Grade.Ok : Grade.NotAtAll;
19
25 public string GetString(object Value)
26 {
27 PhongMaterial Material = (PhongMaterial)Value;
28 StringBuilder sb = new StringBuilder();
29
30 sb.Append("PhongMaterial(");
32 sb.Append(',');
34 sb.Append(',');
36 sb.Append(',');
37 sb.Append(Expression.ToString(Material.Shininess));
38 sb.Append(')');
39
40 return sb.ToString();
41 }
42 }
43}
Class managing a script expression.
Definition: Expression.cs:39
static string ToString(double Value)
Converts a value to a string, that can be parsed as part of an expression.
Definition: Expression.cs:4496
Converts values of type PhongMaterial to expression strings.
string GetString(object Value)
Gets a string representing a value.
Grade Supports(Type Object)
If the interface understands objects such as Object .
Contains information about a material, as used in the Phong reflection model. https://en....
float AmbientReflectionConstant
Ratio of reflection of the ambient term present in all points in the scene rendered.
float DiffuseReflectionConstant
Ratio of reflection of the diffuse term of incoming light.
float Shininess
Shininess coefficient.
float SpecularReflectionConstant
Ratio of reflection of the specular term of incoming light.
Interface for custom string output classes. Converts objects of a given type to an expression string.
Grade
Grade enumeration
Definition: Grade.cs:7