Bugzilla – Bug 27
Default material colors in <phong>, <lambert>, etc
Last modified: 2008-06-10 12:50:26 PDT
In the spec it says that a <diffuse> inside a <phong> (or <lambert>, etc) can be declared 0 or 1 times, however it lists the default value as "N/A". If it doesn't have to be declared then it needs a reasonable default (black probably), right? Same goes for the other material properties (<emission>, <ambient>, ...). See this thread on collada.org for more details: https://collada.org/public_forum/viewtopic.php?t=600&sid=46503dc068197f75f45bcb39a56f4bba
Is this a documentation (Specification) omission or a schema enhancement request? If former, need info--
I'm not sure if the default values should go in the schema or not, but the spec should definitely mention what they are. What additional info do you need?
What are the defaults & where/how are they defined? I couldn't find anything when I looked.
Yes, that's the problem: there are no defaults defined. Mark Barnes (or one of the other schema guys) should decide what the default values should be. Currently a Collada reader can interpret the lack of a <diffuse> element however it wants. That's probably not a good thing. An alternative to default values would be making all elements required.
Reassigned. These things are elements of 'type="common_color_or_texture_type"'. The type itself is a complexType choice of: {color, param, texture}. This choice cannot be defaulted, so it doesn't help to supply default values at this level. Because the type is not a simple type, the elements cannot have schema supplied defaults either. We cannot make the optional elements required in 1.4.2 because then existing 1.4.x documents will no longer validate. We resist specifying default values that cannot be expressed in the schema. Daniel what do you think about this issue?
If this portion of the technique is missing then you should leave out that part of the equation. Ex Phong without diffuse Emissive + Ambient + Specular*(RdotL^SpecPower) Ironically this provides equivilant results to using black. Ellen can you document this?
Add to 1.4.1b release notes?
Assigned. (In reply to comment #6) > If this portion of the technique is missing then you should leave out that > part of the equation. > > Example <phong> without <diffuse> calculation > Emissive + Ambient + Specular*(RdotL^SpecPower) >
Adding to 1.4.1B release notes.
Fixed in 1.4.1 2nd Edition spec.