Example usage for javafx.scene.paint PhongMaterial setSpecularColor

List of usage examples for javafx.scene.paint PhongMaterial setSpecularColor

Introduction

In this page you can find the example usage for javafx.scene.paint PhongMaterial setSpecularColor.

Prototype

public final void setSpecularColor(Color value) 

Source Link

Usage

From source file:nars.rl.util.ThreeDView.java

private void buildAxes() {
    final PhongMaterial redMaterial = new PhongMaterial();
    redMaterial.setDiffuseColor(Color.DARKRED);
    redMaterial.setSpecularColor(Color.RED);

    final PhongMaterial greenMaterial = new PhongMaterial();
    greenMaterial.setDiffuseColor(Color.DARKGREEN);
    greenMaterial.setSpecularColor(Color.GREEN);

    final PhongMaterial blueMaterial = new PhongMaterial();
    blueMaterial.setDiffuseColor(Color.DARKBLUE);
    blueMaterial.setSpecularColor(Color.BLUE);

    final Box xAxis = new Box(240.0, 1, 1);
    final Box yAxis = new Box(1, 240.0, 1);
    final Box zAxis = new Box(1, 1, 240.0);

    xAxis.setMaterial(redMaterial);//ww  w  .  j  av a2  s.c  o m
    yAxis.setMaterial(greenMaterial);
    zAxis.setMaterial(blueMaterial);

    axisGroup.getChildren().addAll(xAxis, yAxis, zAxis);
    world.getChildren().addAll(axisGroup);
}