JDK-8102395 : Provide default AmbientLight
  • Type: Enhancement
  • Component: javafx
  • Sub-Component: graphics
  • Affected Version: 8
  • Priority: P3
  • Status: Resolved
  • Resolution: Won't Fix
  • Submitted: 2013-04-06
  • Updated: 2015-06-16
  • Resolved: 2013-05-09
Related Reports
Relates :  
Relates :  
Description
Take a look at the code in the attachment. It sets a MeshView with TriangleMesh and PhongMaterial of RED color and adds it to the scene.

What you get is black rectangle.

It is not obvious that in order to see the color of the material you have to set AmbientLight.

I believe there should be default white AmbientLight if no ambient light is specified to the scene. It would make easier for developers to start with 3D in JavaFX.
Comments
Alexander and I have discussed this issue in detail. We agree that it is okay to resolve this as "Won't Fix" for Lombard. We will create new JIRA (that includes new light type) if there is real need based on community feedback.
09-05-2013

I agree with John. This help is best address with good documentation and tutorial. A simple sample framework for simple viewer setup that include lighting and navigation control will be excellent too. Not to forget we still have DirectionalLight and SpotLight to add to future API. Do we need default for this type of light sources too? We will run the risk of complicate of core 3D API and making doing straightforward setup slow and potential buggy and confusing.
09-05-2013

In my opinion, I think the default PointLIght attached to the camera is sufficient as a starting point. We can probably provide easy documentation on improving lighting setups, even including bits of code that users and copy and paste into their program to improve the quality of lighting. There are many ways to improve lighting setups with key, fill,and rim lighting, but I don't think that we need to provide these as defaults. I definitely think that these improved lighting setups can be covered in a sample, and users can copy and paste these setups into their program if desired.
08-05-2013

IMO, default camera light should include Ambient as it is too contrast. This Ambient light should be used only when there is no light for scene set (vs. no AmbientLight set). This is to cover case when user don't want to bother with lights to produce nice result.
08-05-2013

We have default camera light, does that not fix this need?
08-05-2013

I prefer to close this as "Won't Fix" too.
07-05-2013

I personally think that it is a mistake to make a library (JavaFX) to act like a viewer. It complicates the API specification and implementation logic. I'm going through my long list of p1-p3 tweaks and bugs for Lombard. My evaluation is to close this as "WON'T FIX" so that time can be spend on more important tweaks and bugs. What do you think?
07-05-2013

Need to reevaluate the need for a default ambient once RT-28624 is implemented.
06-04-2013

We actually plan to address this by adding a default PointLight attached to the camera if no lights are specified.
06-04-2013