A importância do JavaFX
para o mercado Embedded
Bruno Borges
Principal Product Manager
Oracle Latin America

Copyright © 2...
Bruno Borges

Oracle Product Manager
Desenvolvedor, Gamer
Entusiasta em Java Embedded e JavaFX
Twitter: @brunoborges

Copy...
Copyright © 2012, Oracle and/or its affiliates. All rights reserved.

Insert Information Protection Policy Classification ...
Uso de PCs na Indústria

Copyright © 2012, Oracle and/or its affiliates. All rights reserved.

Insert Information Protecti...
Peças antigas, custo alto de manutenção

Copyright © 2012, Oracle and/or its affiliates. All rights reserved.

Insert Info...
Raspberry.Pi – Custo de US$ 35,00

Copyright © 2012, Oracle and/or its affiliates. All rights reserved.

Insert Informatio...
Mercado para Embarcados

Copyright © 2012, Oracle and/or its affiliates. All rights reserved.

Insert Information Protecti...
Interfaces Touch Screen

Copyright © 2012, Oracle and/or its affiliates. All rights reserved.

Insert Information Protecti...
FX
Copyright © 2012, Oracle and/or its affiliates. All rights reserved.

Insert Information Protection Policy Classificati...
Copyright © 2012, Oracle and/or its affiliates. All rights reserved.

Insert Information Protection Policy Classification ...
Copyright © 2012, Oracle and/or its affiliates. All rights reserved.

Insert Information Protection Policy Classification ...
Copyright © 2012, Oracle and/or its affiliates. All rights reserved.

Insert Information Protection Policy Classification ...
DEMO
Projeto Ensemble

Copyright © 2012, Oracle and/or its affiliates. All rights reserved.

Insert Information Protection...
Copyright © 2012, Oracle and/or its affiliates. All rights reserved.

Insert Information Protection Policy Classification ...
JavaFX 3D
Copyright © 2012, Oracle and/or its affiliates. All rights reserved.

Insert Information Protection Policy Class...
Criando Formas e Materiais Primitivos

Copyright © 2012, Oracle and/or its affiliates. All rights reserved.

Insert Inform...
Colocando Textura em uma Esfera

Copyright © 2012, Oracle and/or its affiliates. All rights reserved.

Insert Information ...
Colocando Textura em uma Esfera

Copyright © 2012, Oracle and/or its affiliates. All rights reserved.

Insert Information ...
DEMO
JavaFX 3D

Copyright © 2012, Oracle and/or its affiliates. All rights reserved.

Insert Information Protection Policy...
Colocando Textura em uma Esfera

Copyright © 2012, Oracle and/or its affiliates. All rights reserved.

Insert Information ...
JavaFX é o

sucessor do
Java Swing
Copyright © 2012, Oracle and/or its affiliates. All rights reserved.

Insert Informatio...
Disponível para...
Windows, Linux, Mac OS X
E em Preview...
ARM*
Apple iOS* (usando RoboVM)
Android* (prototipo)
Sta...
Arquitetura
Prism – renderização
Direct3D em Windows
OpenGL em Linux/Mac/Embedded
Public API
JavaFX API
Scene Graph
...
OpenJFX
JavaFX open sourced!
http://openjdk.java.net/projects/openjfx/

Copyright © 2012, Oracle and/or its affiliates. Al...
DEMO
App JavaFX escrita em Javascript

Copyright © 2012, Oracle and/or its affiliates. All rights reserved.

Insert Inform...
Criando sua
primeira aplicação
JavaFX

Copyright © 2012, Oracle and/or its affiliates. All rights reserved.

Insert Inform...
JavaFX Scene Builder 1.1 GA
bit.ly/javafxdownload

Copyright © 2012, Oracle and/or its affiliates. All rights reserved.

I...
Your First JavaFX App for RaspberryPi



Copyright © 2012, Oracle and/or its affiliates. All rights reserved.

Insert Inf...
Scene
Graph

Copyright © 2012, Oracle and/or its affiliates. All rights reserved.

 Responsável pela UI
 Estrutura em Ár...
Scene Graph
Root Node – único sem um “parent”
Branch Node – deriva de javafx.scene.Parent
Pode possuir outros nós
Leaf...
Sua primeira aplicação JavaFX
public class MyApplication extends Application {
@Override
public void start(Stage stage) th...
Properties no Swing
// Java Swing
private static final String VALUE_PROPERTY = "value";
private double value = 0;
public d...
Properties no JavaFX
// JavaFX
DoubleProperty value = new SimpleDoubleProperty(0);
public double getValue() {
return value...
Bindings
Binding unidirecional
bind();
Binding bi-direcional
bindBidirectional();

Copyright © 2012, Oracle and/or its...
Bindings
IntegerProperty number1 = new SimpleIntegerProperty(1);
IntegerProperty number2 = new SimpleIntegerProperty(2);
D...
Limite de Velocidade
60 FPS

Copyright © 2012, Oracle and/or its affiliates. All rights reserved.

Insert Information Prot...
DEMO
JavaFX com NetBeans 7.4

Copyright © 2012, Oracle and/or its affiliates. All rights reserved.

Insert Information Pro...
Suporte a Dispositivos Embedded

Copyright © 2012, Oracle and/or its affiliates. All rights reserved.

Insert Information ...
Raspberry Pi Configurations
for JavaFX applications

CPU Overclock
900~950MHz
Memory split
128MB for video
Framebuffer
fra...
CPU Overclock
for JavaFX applications

$ cat /proc/cpuinfo
Processor
: ARMv6-compatible processor rev 7 (v6l)
BogoMIPS
: 6...
CPU Overclock
for JavaFX applications

$ cat /proc/cpuinfo
Processor
: ARMv6-compatible processor rev 7 (v6l)
BogoMIPS
: 6...
CPU Overclock
for JavaFX applications

$ cat /proc/cpuinfo
Processor
: ARMv6-compatible processor rev 7 (v6l)
BogoMIPS
: 6...
Memory Split
for JavaFX applications

128mb best
performance
64mb may work
$ sudo raspi-config

Copyright © 2012, Oracle a...
Memory Split
for JavaFX applications

128mb best
performance
64mb may work
$ sudo raspi-config

Copyright © 2012, Oracle a...
Video Framebuffer
for JavaFX applications

Edit /boot/config.txt
Enable (uncomment) these options, with these values:
fram...
Exiting a JavaFX Application on Raspberry.Pi

Connect over SSH and kill the java process
$ killall -9 java
Enable the debu...
Final parameters for JavaFX on Raspy

Do not show virtual keyboard (optional)
-Dcom.sun.javafx.isEmbedded=false
Send video...
Perguntas?
Copyright © 2012, Oracle and/or its affiliates. All rights reserved.

Insert Information Protection Policy Clas...
Obrigado!
@brunoborges

Copyright © 2012, Oracle and/or its affiliates. All rights reserved.

Insert Information Protectio...
The preceding is intended to outline our general product direction. It is intended
for information purposes only, and may ...
Copyright © 2012, Oracle and/or its affiliates. All rights reserved.

Insert Information Protection Policy Classification ...
Upcoming SlideShare
Loading in...5
×

A Importância do JavaFX no Mercado Embedded

1,547

Published on

Published in: Technology, Business
0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total Views
1,547
On Slideshare
0
From Embeds
0
Number of Embeds
2
Actions
Shares
0
Downloads
13
Comments
0
Likes
0
Embeds 0
No embeds

No notes for slide

A Importância do JavaFX no Mercado Embedded

  1. 1. A importância do JavaFX para o mercado Embedded Bruno Borges Principal Product Manager Oracle Latin America Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 13
  2. 2. Bruno Borges Oracle Product Manager Desenvolvedor, Gamer Entusiasta em Java Embedded e JavaFX Twitter: @brunoborges Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 13
  3. 3. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 13
  4. 4. Uso de PCs na Indústria Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 13
  5. 5. Peças antigas, custo alto de manutenção Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 13
  6. 6. Raspberry.Pi – Custo de US$ 35,00 Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 13
  7. 7. Mercado para Embarcados Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 13
  8. 8. Interfaces Touch Screen Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 13
  9. 9. FX Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 13
  10. 10. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 13
  11. 11. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 13
  12. 12. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 13
  13. 13. DEMO Projeto Ensemble Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 13
  14. 14. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 13
  15. 15. JavaFX 3D Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 13
  16. 16. Criando Formas e Materiais Primitivos Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 13 17
  17. 17. Colocando Textura em uma Esfera Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 13 18
  18. 18. Colocando Textura em uma Esfera Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 13 19
  19. 19. DEMO JavaFX 3D Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 13
  20. 20. Colocando Textura em uma Esfera Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 13 21
  21. 21. JavaFX é o sucessor do Java Swing Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 13
  22. 22. Disponível para... Windows, Linux, Mac OS X E em Preview... ARM* Apple iOS* (usando RoboVM) Android* (prototipo) Standalone para Java 6 JavaFX 2.2 vem junto com JDK 7u6+ Parte do ClassPath a partir do Java SE 8 Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 13
  23. 23. Arquitetura Prism – renderização Direct3D em Windows OpenGL em Linux/Mac/Embedded Public API JavaFX API Scene Graph Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 13
  24. 24. OpenJFX JavaFX open sourced! http://openjdk.java.net/projects/openjfx/ Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 13
  25. 25. DEMO App JavaFX escrita em Javascript Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 13
  26. 26. Criando sua primeira aplicação JavaFX Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 13
  27. 27. JavaFX Scene Builder 1.1 GA bit.ly/javafxdownload Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 13
  28. 28. Your First JavaFX App for RaspberryPi  Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 13
  29. 29. Scene Graph Copyright © 2012, Oracle and/or its affiliates. All rights reserved.  Responsável pela UI  Estrutura em Árvore  Possui um nó raiz  Vários nós branch e leaf Insert Information Protection Policy Classification from Slide 13 16
  30. 30. Scene Graph Root Node – único sem um “parent” Branch Node – deriva de javafx.scene.Parent Pode possuir outros nós Leaf Node – não possui filhos Shapes, Images, Text, WebView, Media, Controls, Charts, etc... Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 13
  31. 31. Sua primeira aplicação JavaFX public class MyApplication extends Application { @Override public void start(Stage stage) throws Exception { URL fxml = getClass().getResource("MyApplication.fxml"); Parent root = FXMLLoader.load(fxml); Scene scene = new Scene(root); stage.setScene(scene); stage.setFullScreen(true); stage.show(); } public static void main(String[] args) { launch(args); } } Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 13
  32. 32. Properties no Swing // Java Swing private static final String VALUE_PROPERTY = "value"; private double value = 0; public double getValue() { return value; } public void setValue(double newValue) { double oldValue = value; value = newValue; firePropertyChange(VALUE_PROPERTY, oldValue, value); } Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 13
  33. 33. Properties no JavaFX // JavaFX DoubleProperty value = new SimpleDoubleProperty(0); public double getValue() { return value.get(); } public void setValue(double newValue){ value.set(newValue); } public DoubleProperty valueProperty() { return value; } Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 13
  34. 34. Bindings Binding unidirecional bind(); Binding bi-direcional bindBidirectional(); Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 13
  35. 35. Bindings IntegerProperty number1 = new SimpleIntegerProperty(1); IntegerProperty number2 = new SimpleIntegerProperty(2); DoubleProperty number3 = new SimpleDoubleProperty(0.5); NumberBinding sum1 = number1.add(number2); NumberBinding result1 = number1 .add(number2) .multiply(number3); NumberBinding sum2 = Bindings.add(number1, number2); NumberBinding result2 = Bindings .add(number1, multiply(number2, number3)); Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 13
  36. 36. Limite de Velocidade 60 FPS Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 13
  37. 37. DEMO JavaFX com NetBeans 7.4 Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 13
  38. 38. Suporte a Dispositivos Embedded Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 13
  39. 39. Raspberry Pi Configurations for JavaFX applications CPU Overclock 900~950MHz Memory split 128MB for video Framebuffer framebuffer_width=1280 framebuffer_height=720 Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 13
  40. 40. CPU Overclock for JavaFX applications $ cat /proc/cpuinfo Processor : ARMv6-compatible processor rev 7 (v6l) BogoMIPS : 697.95 … $ sudo raspi-config bit.ly/raspioverclock Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 13
  41. 41. CPU Overclock for JavaFX applications $ cat /proc/cpuinfo Processor : ARMv6-compatible processor rev 7 (v6l) BogoMIPS : 697.95 … $ sudo raspi-config Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 13
  42. 42. CPU Overclock for JavaFX applications $ cat /proc/cpuinfo Processor : ARMv6-compatible processor rev 7 (v6l) BogoMIPS : 697.95 … $ sudo raspi-config Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 13
  43. 43. Memory Split for JavaFX applications 128mb best performance 64mb may work $ sudo raspi-config Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 13
  44. 44. Memory Split for JavaFX applications 128mb best performance 64mb may work $ sudo raspi-config Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 13
  45. 45. Video Framebuffer for JavaFX applications Edit /boot/config.txt Enable (uncomment) these options, with these values: framebuffer_width=1280 framebuffer_height=720 Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 13
  46. 46. Exiting a JavaFX Application on Raspberry.Pi Connect over SSH and kill the java process $ killall -9 java Enable the debug environment variable to enable control-C exit command $ export JAVA_DEBUG=1 $ java -cp Stopwatch.jar stopwatch.MainScreen Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 13
  47. 47. Final parameters for JavaFX on Raspy Do not show virtual keyboard (optional) -Dcom.sun.javafx.isEmbedded=false Send video to the framebuffer (required!) -Djavafx.platform=eglfb Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 13
  48. 48. Perguntas? Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 13
  49. 49. Obrigado! @brunoborges Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 13
  50. 50. The preceding is intended to outline our general product direction. It is intended for information purposes only, and may not be incorporated into any contract. It is not a commitment to deliver any material, code, or functionality, and should not be relied upon in making purchasing decisions. The development, release, and timing of any features or functionality described for Oracle’s products remains at the sole discretion of Oracle. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 13
  51. 51. Copyright © 2012, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 13
  1. A particular slide catching your eye?

    Clipping is a handy way to collect important slides you want to go back to later.

×