From nlisker at gmail.com Thu Jan 3 00:31:02 2019 From: nlisker at gmail.com (Nir Lisker) Date: Thu, 3 Jan 2019 02:31:02 +0200 Subject: 3D light enhancements Message-ID: Hi All, FalcoTheBold and I been discussing enhancements to the 3D lighting mechanism on GitHub [1]. The summary is as follows: 1. We want to add additional light types: directional light and spotlight. 2. We want to add attenuation and range parameters to the current point light and future spotlight. Our efforts are currently directed at 2, specifically, adding attenuation (inc. range) to the current point light. Some preliminary results for the d3d pipeline can be seen in [2]. I'm working on the d3d pipeline (with a lot behind-the-scenes help from Ambarish) while Falco is working on the es2 pipeline. Iv'e also taken upon me to do the Java side modifications. >From the 3d3 pipeline perspective, it seems that this change will require upgrading the shader models from 2.0 to 3.0. This means that backwards compatibility is lost for graphic cards that support DirectX 9.0 but not 9.0c. Fortunately, these should be a small number of very old cards. On the API level, I'm thinking about adding 4 `DoubleProperty`s to PointLight for the 3 attenuation factors and the range. Their default values are such that current behavior is preserved. SpotLight will also have these values (in addition to other required parameters). If this plan is approved by Kevin/Johan, I will create JBS tickets for step-by-step implementations. Other comments are welcome. Thanks, Nir [1] https://github.com/javafxports/openjdk-jfx/issues/256 [2] https://github.com/javafxports/openjdk-jfx/issues/256#issuecomment-450762358 From 1032453509 at qq.com Fri Jan 18 10:46:20 2019 From: 1032453509 at qq.com (=?ISO-8859-1?B?MTAzMjQ1MzUwOQ==?=) Date: Fri, 18 Jan 2019 18:46:20 +0800 Subject: Have any idea or plan about hot reload like TornadoFx or Flutter? Message-ID: See: https://www.youtube.com/watch?v=HbPngSnvaWQ https://www.youtube.com/watch?v=1UZ6686QsOw From pnem at cmail.cz Fri Jan 18 14:28:32 2019 From: pnem at cmail.cz (Petr Nemecek) Date: Fri, 18 Jan 2019 15:28:32 +0100 Subject: JavaFX 11/TableView/Resize column to fit content Message-ID: <00f901d4af3a$16c0b900$44422b00$@cmail.cz> Hi all, I'm migrating from Java 8 to Java 11 + JavaFX 11. I was using TableViewSkin.resizeColumnToFitContent in Java 8 in order to resize the width of a column to fit its content. As this methods is not available in JavaFX 11 anymore, is there any other way how to achieve this programatically? Many thanks, Petr From kevin.rushforth at oracle.com Fri Jan 18 14:34:17 2019 From: kevin.rushforth at oracle.com (Kevin Rushforth) Date: Fri, 18 Jan 2019 06:34:17 -0800 Subject: JavaFX 11/TableView/Resize column to fit content In-Reply-To: <00f901d4af3a$16c0b900$44422b00$@cmail.cz> References: <00f901d4af3a$16c0b900$44422b00$@cmail.cz> Message-ID: This is more relevant to the openjfx-dev alias, so I have redirected the thread there (with a "Bcc" of the -discuss alias). There is currently no way to do this, but it is a known issue [1][2] that is under discussion. -- Kevin [1] https://bugs.openjdk.java.net/browse/JDK-8207957 [2] https://github.com/javafxports/openjdk-jfx/pull/289 On 1/18/2019 6:28 AM, Petr Nemecek wrote: > Hi all, > > I'm migrating from Java 8 to Java 11 + JavaFX 11. > > I was using TableViewSkin.resizeColumnToFitContent in Java 8 in order to > resize the width of a column to fit its content. > > As this methods is not available in JavaFX 11 anymore, is there any other > way how to achieve this programatically? > > Many thanks, > Petr > From kevin.rushforth at oracle.com Mon Jan 21 15:44:39 2019 From: kevin.rushforth at oracle.com (Kevin Rushforth) Date: Mon, 21 Jan 2019 07:44:39 -0800 Subject: 3D light enhancements In-Reply-To: References: Message-ID: Both enhancements seem like interesting additions to JavaFX's 3D API. As long as it's only the 3D support that will no longer work on older cards -- meaning that those older cards will no longer report that ConditionalFeature.SCENE3D is supported, but 2D HW acceleration will still be available -- then this seems fine to me. Given that these enhancements will only touch the 3D shaders, it should be fairly straight-forward to make the check for shader model be part of the "is 3D supported" calculation. -- Kevin On 1/2/2019 4:31 PM, Nir Lisker wrote: > Hi All, > > FalcoTheBold and I been discussing enhancements to the 3D lighting > mechanism on GitHub [1]. The summary is as follows: > > 1. We want to add additional light types: directional light and spotlight. > 2. We want to add attenuation and range parameters to the current point > light and future spotlight. > > Our efforts are currently directed at 2, specifically, adding attenuation > (inc. range) to the current point light. Some preliminary results for the > d3d pipeline can be seen in [2]. I'm working on the d3d pipeline (with a > lot behind-the-scenes help from Ambarish) while Falco is working on the es2 > pipeline. Iv'e also taken upon me to do the Java side modifications. > > From the 3d3 pipeline perspective, it seems that this change will require > upgrading the shader models from 2.0 to 3.0. This means that backwards > compatibility is lost for graphic cards that support DirectX 9.0 but not > 9.0c. Fortunately, these should be a small number of very old cards. > > On the API level, I'm thinking about adding 4 `DoubleProperty`s to > PointLight for the 3 attenuation factors and the range. Their default > values are such that current behavior is preserved. SpotLight will also > have these values (in addition to other required parameters). > > If this plan is approved by Kevin/Johan, I will create JBS tickets for > step-by-step implementations. Other comments are welcome. > > Thanks, > Nir > > [1] https://github.com/javafxports/openjdk-jfx/issues/256 > [2] > https://github.com/javafxports/openjdk-jfx/issues/256#issuecomment-450762358 From nlisker at gmail.com Tue Jan 22 06:00:58 2019 From: nlisker at gmail.com (Nir Lisker) Date: Tue, 22 Jan 2019 08:00:58 +0200 Subject: 3D light enhancements In-Reply-To: References: Message-ID: I created [1] for upgrading the shader model and [2] for adding attenuation to SpotLight. [1] https://bugs.openjdk.java.net/browse/JDK-8217470 [2] https://bugs.openjdk.java.net/browse/JDK-8217472 On Mon, Jan 21, 2019 at 5:44 PM Kevin Rushforth wrote: > Both enhancements seem like interesting additions to JavaFX's 3D API. As > long as it's only the 3D support that will no longer work on older cards > -- meaning that those older cards will no longer report that > ConditionalFeature.SCENE3D is supported, but 2D HW acceleration will > still be available -- then this seems fine to me. Given that these > enhancements will only touch the 3D shaders, it should be fairly > straight-forward to make the check for shader model be part of the "is > 3D supported" calculation. > > -- Kevin > > > On 1/2/2019 4:31 PM, Nir Lisker wrote: > > Hi All, > > > > FalcoTheBold and I been discussing enhancements to the 3D lighting > > mechanism on GitHub [1]. The summary is as follows: > > > > 1. We want to add additional light types: directional light and > spotlight. > > 2. We want to add attenuation and range parameters to the current point > > light and future spotlight. > > > > Our efforts are currently directed at 2, specifically, adding attenuation > > (inc. range) to the current point light. Some preliminary results for the > > d3d pipeline can be seen in [2]. I'm working on the d3d pipeline (with a > > lot behind-the-scenes help from Ambarish) while Falco is working on the > es2 > > pipeline. Iv'e also taken upon me to do the Java side modifications. > > > > From the 3d3 pipeline perspective, it seems that this change will > require > > upgrading the shader models from 2.0 to 3.0. This means that backwards > > compatibility is lost for graphic cards that support DirectX 9.0 but not > > 9.0c. Fortunately, these should be a small number of very old cards. > > > > On the API level, I'm thinking about adding 4 `DoubleProperty`s to > > PointLight for the 3 attenuation factors and the range. Their default > > values are such that current behavior is preserved. SpotLight will also > > have these values (in addition to other required parameters). > > > > If this plan is approved by Kevin/Johan, I will create JBS tickets for > > step-by-step implementations. Other comments are welcome. > > > > Thanks, > > Nir > > > > [1] https://github.com/javafxports/openjdk-jfx/issues/256 > > [2] > > > https://github.com/javafxports/openjdk-jfx/issues/256#issuecomment-450762358 > >