public class Lighting extends Effect
例:
Light.Distant light = new Light.Distant();
light.setAzimuth(-135.0);
Lighting lighting = new Lighting();
lighting.setLight(light);
lighting.setSurfaceScale(5.0);
Text text = new Text();
text.setText("JavaFX!");
text.setFill(Color.STEELBLUE);
text.setFont(Font.font(null, FontWeight.BOLD, 60));
text.setX(10.0);
text.setY(10.0);
text.setTextOrigin(VPos.TOP);
text.setEffect(lighting);
前述のコードにより、次の出力が生成されます。
Type | プロパティと説明 |
---|---|
ObjectProperty<Effect> |
bumpInput
オプションのバンプ・マップ入力。
|
ObjectProperty<Effect> |
contentInput
この
Effect のコンテンツの入力。 |
DoubleProperty |
diffuseConstant
拡散定数。
|
ObjectProperty<Light> |
light
この
Lighting 効果の光源。 |
DoubleProperty |
specularConstant
鏡面定数。
|
DoubleProperty |
specularExponent
鏡面指数。
|
DoubleProperty |
surfaceScale
表面スケール係数。
|
コンストラクタと説明 |
---|
Lighting()
デフォルトのパラメータでLightingの新しいインスタンスを作成します。
|
Lighting(Light light)
指定されたlightを持つLightingの新しいインスタンスを作成します。
|
修飾子と型 | メソッドと説明 |
---|---|
ObjectProperty<Effect> |
bumpInputProperty()
オプションのバンプ・マップ入力。
|
ObjectProperty<Effect> |
contentInputProperty()
この
Effect のコンテンツの入力。 |
DoubleProperty |
diffuseConstantProperty()
拡散定数。
|
Effect |
getBumpInput()
プロパティbumpInputの値を取得します。
|
Effect |
getContentInput()
プロパティcontentInputの値を取得します。
|
double |
getDiffuseConstant()
プロパティdiffuseConstantの値を取得します。
|
Light |
getLight()
プロパティlightの値を取得します。
|
double |
getSpecularConstant()
プロパティspecularConstantの値を取得します。
|
double |
getSpecularExponent()
プロパティspecularExponentの値を取得します。
|
double |
getSurfaceScale()
プロパティsurfaceScaleの値を取得します。
|
ObjectProperty<Light> |
lightProperty()
この
Lighting 効果の光源。 |
void |
setBumpInput(Effect value)
プロパティbumpInputの値を設定します。
|
void |
setContentInput(Effect value)
プロパティcontentInputの値を設定します。
|
void |
setDiffuseConstant(double value)
プロパティdiffuseConstantの値を設定します。
|
void |
setLight(Light value)
プロパティlightの値を設定します。
|
void |
setSpecularConstant(double value)
プロパティspecularConstantの値を設定します。
|
void |
setSpecularExponent(double value)
プロパティspecularExponentの値を設定します。
|
void |
setSurfaceScale(double value)
プロパティsurfaceScaleの値を設定します。
|
DoubleProperty |
specularConstantProperty()
鏡面定数。
|
DoubleProperty |
specularExponentProperty()
鏡面指数。
|
DoubleProperty |
surfaceScaleProperty()
表面スケール係数。
|
public final ObjectProperty<Light> lightProperty
Lighting
効果の光源。getLight()
、setLight(Light)
public final ObjectProperty<Effect> bumpInputProperty
null
に設定した場合、または指定しない場合、Effect
がアタッチされているNode
のグラフィカル・イメージを使用してデフォルトのバンプ・マップが生成されます。getBumpInput()
、setBumpInput(Effect)
public final ObjectProperty<Effect> contentInputProperty
Effect
のコンテンツの入力。null
に設定した場合、または指定しない場合、Effect
がアタッチされているNode
のグラフィカル・イメージが入力として使用されます。getContentInput()
、setContentInput(Effect)
public final DoubleProperty diffuseConstantProperty
Min: 0.0 Max: 2.0 Default: 1.0 Identity: n/a
getDiffuseConstant()
、setDiffuseConstant(double)
public final DoubleProperty specularConstantProperty
Min: 0.0 Max: 2.0 Default: 0.3 Identity: n/a
getSpecularConstant()
、setSpecularConstant(double)
public final DoubleProperty specularExponentProperty
Min: 0.0 Max: 40.0 Default: 20.0 Identity: n/a
getSpecularExponent()
、setSpecularExponent(double)
public final DoubleProperty surfaceScaleProperty
Min: 0.0 Max: 10.0 Default: 1.5 Identity: n/a
getSurfaceScale()
、setSurfaceScale(double)
public Lighting()
public Lighting(Light light)
light
- このLighting
効果の光源public final void setLight(Light value)
Lighting
効果の光源。public final Light getLight()
Lighting
効果の光源。public final ObjectProperty<Light> lightProperty()
Lighting
効果の光源。getLight()
、setLight(Light)
public final void setBumpInput(Effect value)
null
に設定した場合、または指定しない場合、Effect
がアタッチされているNode
のグラフィカル・イメージを使用してデフォルトのバンプ・マップが生成されます。public final Effect getBumpInput()
null
に設定した場合、または指定しない場合、Effect
がアタッチされているNode
のグラフィカル・イメージを使用してデフォルトのバンプ・マップが生成されます。public final ObjectProperty<Effect> bumpInputProperty()
null
に設定した場合、または指定しない場合、Effect
がアタッチされているNode
のグラフィカル・イメージを使用してデフォルトのバンプ・マップが生成されます。getBumpInput()
、setBumpInput(Effect)
public final void setContentInput(Effect value)
Effect
のコンテンツの入力。null
に設定した場合、または指定しない場合、Effect
がアタッチされているNode
のグラフィカル・イメージが入力として使用されます。public final Effect getContentInput()
Effect
のコンテンツの入力。null
に設定した場合、または指定しない場合、Effect
がアタッチされているNode
のグラフィカル・イメージが入力として使用されます。public final ObjectProperty<Effect> contentInputProperty()
Effect
のコンテンツの入力。null
に設定した場合、または指定しない場合、Effect
がアタッチされているNode
のグラフィカル・イメージが入力として使用されます。getContentInput()
、setContentInput(Effect)
public final void setDiffuseConstant(double value)
Min: 0.0 Max: 2.0 Default: 1.0 Identity: n/a
public final double getDiffuseConstant()
Min: 0.0 Max: 2.0 Default: 1.0 Identity: n/a
public final DoubleProperty diffuseConstantProperty()
Min: 0.0 Max: 2.0 Default: 1.0 Identity: n/a
getDiffuseConstant()
、setDiffuseConstant(double)
public final void setSpecularConstant(double value)
Min: 0.0 Max: 2.0 Default: 0.3 Identity: n/a
public final double getSpecularConstant()
Min: 0.0 Max: 2.0 Default: 0.3 Identity: n/a
public final DoubleProperty specularConstantProperty()
Min: 0.0 Max: 2.0 Default: 0.3 Identity: n/a
getSpecularConstant()
、setSpecularConstant(double)
public final void setSpecularExponent(double value)
Min: 0.0 Max: 40.0 Default: 20.0 Identity: n/a
public final double getSpecularExponent()
Min: 0.0 Max: 40.0 Default: 20.0 Identity: n/a
public final DoubleProperty specularExponentProperty()
Min: 0.0 Max: 40.0 Default: 20.0 Identity: n/a
getSpecularExponent()
、setSpecularExponent(double)
public final void setSurfaceScale(double value)
Min: 0.0 Max: 10.0 Default: 1.5 Identity: n/a
public final double getSurfaceScale()
Min: 0.0 Max: 10.0 Default: 1.5 Identity: n/a
public final DoubleProperty surfaceScaleProperty()
Min: 0.0 Max: 10.0 Default: 1.5 Identity: n/a
getSurfaceScale()
、setSurfaceScale(double)
Copyright (c) 2008, 2015, Oracle and/or its affiliates. All rights reserved.