字幕表 動画を再生する
The Standard Shader is a powerful and versatile shader.
標準シェーダーは強力かつ汎用性の高いシェーダーです
This single physically-based shader
この物理ベースシェーダーひとつで
can be used to make such a wide variety
実に多様なマテリアルを作成できるため
of materials it's easily
このシェーダーのみで
possible that this one shader can make
プロジェクトの全マテリアルを
every material in a given project.
作成することも可能なほどです
The standard is used to create Unity's default material.
標準シェーダーは Unity のデフォルトマテリアル作成時に使われます
So all mesh rendered using
つまりデフォルトマテリアルを使う
the default material will be using the standard shader.
全 Mesh Renderer は 標準シェーダーを使用するわけです
All new materials that are created
新規作成されるマテリアルもまた
will use the standard shader as well.
すべて 標準シェーダーを使用します
To change the shader used by a material
マテリアルで使用するシェーダーを変更するには
select the Shader menu on the material.
マテリアルの Shader メニューを使います
Select Standard to use the standard shader.
標準シェーダーを使うなら Standard を選択します
It is worth noting the Unity
なお Unity では物理ベースレンダリングの
has shaders available for both
主要アプローチのそれぞれに
popular approaches to physically-based rendering.
対応するシェーダーを用意してあります
Metallic, as default,
デフォルトの Metallic と
and specular.
Specular です
To choose the standard shader
標準シェーダーを
using the specular approach
Specular アプローチで使う場合は
select Standard (Specular Setup).
Standard (Specular Setup) を選択してください
Otherwise use Standard
Standard を選択すると
for the metallic approach.
Metallic アプローチとなります
It is important to understand that the
なお物理ベースシェーディングにおける
metallic approach to physically-based shading
Metalic アプローチはメタリックな見た目の
is not only for materials which are
マテリアル用というわけではないので
supposed to look metallic.
注意してください
This mode is known as metallic
Metallic と呼ばれているのは
because this approach is based on
このアプローチがマテリアルの
defining how metallic or non-metallic
サーフェイスのメタリック度 / 非メタリック度を
that material's surface is.
定義するためです
This is opposed to the specular approach
反対に Specular アプローチでは
which defines how specular,
サーフェイスがどの程度 Specular(鏡面反射)
or non-specular that surface is.
するかを定義していきます
Both approaches are valid ways to
いずれのアプローチも物理ベースマテリアルを
describe a physically-based material.
記述する上では有効な方法です
This physically-based material is
この物理ベースマテリアルも
still a standard Unity material
標準の Unity マテリアルですから
and this material is associated
通常と同じように
with a renderer in the same way as usual.
レンダラーに関連付けることが可能です
There are three sections to the standard shader.
標準シェーダーは次の 3 セクションに分かれています
Rendering Mode.
Rendering Mode
Main Maps
Main Maps
and Secondary Maps.
Secondary Maps
The standard shader has four rendering modes.
標準シェーダーには次の 4 つのレンダリングモードがあります
Opaque, Cutout, Fade and Transparent.
Opaque / Cutout / Fade / Transparent
Most materials are opaque, or solid materials.
多くのマテリアルは Opaque つまり不透明なマテリアルですので
Opaque is the default render mode.
Opaque はデフォルトのレンダリングモードになっています
For transparent materials, such as glass,
ガラスのような透明なマテリアルには
choose Transparent.
Transparent を使用します
In transparent rendering mode
Transparent レンダリングモードでは
the alpha channel on the diffuse colour property
ディフューズカラープロパティのアルファチャンネルが
is used to control the level of transparency.
透明度の制御に使われます
With rendering mode cutout
レンダリングモード Cutout では
the alpha channel of the diffuse image
ディフューズイメージのアルファチャンネルが
is used to mask out parts of the texture.
テクスチャの一部をマスクする用途で使われます
If the alpha channel has a gradient value to the mask
アルファチャンネルがマスクに対してグラデーション値を持っている場合は
the alpha cutoff slider can be used
Alpha Cutoff スライダーを使うと
to adjust the shape of the cutout.
アルファチャンネルのマスクの強さに応じて
based on the strength of the mask in the alpha channel.
カットアウト部分の形状を調整できます
Rendering mode fade is similar
レンダリングモード Fade は
to rendering mode transparent.
レンダリングモード Transparent に似ています
Fade is intended for fading out
Fade はゲームオブジェクトを画面から
game objects on screen.
フェードアウトさせる時に使います
With rendering mode transparent
レンダリングモード Transparent では
a transparent material will preserve it's
アルファ値がいくつになっても
reflectivity regardless of it's alpha value.
反射率は保持されましたが
Fade however will fade all
Fade の場合にはマテリアルに関する
relevant aspects of the material
一切の項目がフェードするため
so the faded material is completely invisible.
完全にフェードされたマテリアルは不可視になります
The main map section defines the look of the material.
Main Map セクションはマテリアルの見た目を定義します
Before going in to the details of each property
ここでは各プロパティの詳細を見て行く前に
there are a few subjects that are worth covering first.
いくつか重要な点についてカバーしておきたいと思います
Optimisation.
まず 最適化
The standard shader is highly optimised.
標準シェーダーは高度な最適化がなされています
When the standard shader is built
標準シェーダーのビルド時には
two important things happen.
2 つの重要なことが起きます
All properties that are not being used are discarded.
まず使用されていないプロパティがすべて破棄されます
The build target is checked
次にビルドターゲットがチェックされ
and the shader is optimised for that device.
シェーダーが対象デバイスに向けて最適化されます
Because of this there is no need to populate every
このため各プロパティにマップや値を
property with a map or values.
入れる必要はありません
And there is no need to worry about wasted
そして使用されていないプロパティが無駄に
resources due to unused properties.
リソースを取ってしまう心配も不要です
Physically-based shading.
物理ベースシェーディング
Physically-based shading tries to define
物理ベースシェーディングではマテリアルの
certain physical aspects of a material's surface.
サーフェイスの特定の物理的側面を定義しようとします
Including it's diffuse colour,
これにはディフューズカラー
specular refection and other properties
スペキュラ反射やその他のプロパティが含まれます
so the material behaves correctly
これらはあらゆるライティング条件下で
and believably in all lighting environments.
マテリアルが正しく説得力のある外観を持つようにするためです
The response of the scene lighting to the material
物理ベースシェーダーで作られたマテリアルを
created with a physically based shader
シーンライティングが照らした時の反応は
mimics light in the real physical world.
現実の物理世界の光と近くなります
This means that even though there is
つまり 標準シェーダーでは
full control over the values on
すべてのプロパティの値を
all of the properties in the standard shader
制御できますがマテリアルによって
there are certain ranges of values that
最適な値の範囲があると
work best for certain types of materials.
いうことを意味します
This is particularly true of the metallic and specular values
これは特に Metallic と Specular の値で顕著です
depending up which approach is being used
どちらのアプローチを採用しているかにもよりますが
Taking specular colour for example,
ここでは仮に Specular カラーを取り上げましょう
when analysing real-world materials
現実世界のマテリアルを分析してみると
most materials have a specular range
多くのマテリアルのスペキュラ範囲は
that is a very dark grey.
とても暗い灰色をしています
Metals created with a specular workflow are one of the few exceptions,
ただしスペキュラワークフローでもメタルは例外的で
they have very bright specular values.
とても明るいスペキュラ値をしています
As well, no material, even the most dull,
そしてどのようなマテリアルであっても
has no specularity at all.
スペキュラ値がないことはありません
This means to have a physically based
これは物理ベースマテリアルを正しく見せるには
material behave correctly
主要プロパティに適切な値を
some attention needs to be paid in using
入れる必要があることを意味します
the correct physical values for some key properties,
特に使用するアプローチに応じて
especially the specular or metallic properties
Specular / Metallic プロパティを適切に
depending upon the approach being used.
設定することが重要です
For more information on physical-based shading,
物理ベースシェーディングやマテリアルチャート
material charts and sample materials
サンプルマテリアルの詳細については
please see the information linked below.
下記リンク先の情報を参照してください
There is no need to panic however.
でもあわてる必要はありません
Items with materials from previous versions of Unity
過去バージョンの Unity から持ってきたマテリアル付きアイテムも
will work well out of the box.
そのまま使うことができます
Upgrading from a legacy diffuse shader
レガシーのデフューズシェーダーから
to the standard shader should display little or no difference.
標準シェーダーにアップグレードしても違いはほぼないはずです
In the main map section each of these properties
Main Map セクションにあるプロパティは
control one aspect of the final material.
最終マテリアルの各項目を制御するものです
Each property can be defined by a texture map.
各プロパティはテクスチャーマップで定義することができます
With the metallic approach,
Metallic アプローチを取る場合
for the albido, metallic and emission properties
Albido / Metallic / Emission プロパティの
the texture is optional.
テクスチャは任意指定です
The albido and emission properties
Albido と Emission プロパティには
can simply use a colour value instead of a texture.
テクスチャの代わりにカラー値を指定できます
The colour value is not available on
Emission プロパティのカラー値は
the emission property until the emissive
フィールド値が 0 よりも大きくならないと
scale is larger than 0.
有効になりません
The metallic property can use a slider
Metallic プロパティではテクスチャの代わりに
instead of a texture.
スライダーを使用できます
The albido property uses a
Albido プロパティには
combination of an optional texture.
任意指定のテクスチャを追加した後
And a colour value to define the base look of the material.
さらにカラーを追加してマテリアルの見た目を定義することができます
The colour value will tint the texture.
このカラー値はテクスチャーにTint(淡い色付け)します
Where pure white leaves the main texture unaffected,
真っ白にした場合にはテクスチャに変化は起きません
if there is no texture being used
テクスチャが使用されていない場合は
the tint colour will be the base colour for the material
この Tint 色がマテリアルのベース色になります
The metallic property can be defined
Metallic プロパティは
by either a texture
テクスチャーを使うか
or a value from 0 to 1
0 ~ 1 の値を
set by the slider.
スライダーで指定して定義します
This defines the metalness of the material surface.
このプロパティはマテリアルのサーフェイスのメタルネスを定義します
Metalness works very closely with smoothness.
メタルネスと Smoothness には深い相関関係があります
The smoothness property is used to
Smoothness プロパティは
control the smoothness,
マテリアルの滑らかさ あるいは
or micro-surface detail, of the material.
サーフェイスの細かなディテールを制御するプロパティです
It is also a value between 0 and 1.
値は 0 ~ 1 で指定します
The less smooth the surface is,
サーフェイスがスムースでないほど
the more diffuse the reflections will be.
反射は拡散し
The more smooth, the sharper the reflections.
スムースであるほど反射は鋭角になります
The metallic property can use a texture
Metallic プロパティではテクスチャを使って
to define the material's metalness.
マテリアルのメタルネスを定義することが可能です
This texture can be a simple shade of grey
このテクスチャーは灰色のグラデーションで
used to define the metalness from black,
メタルネスを定義します 黒は
or non-metallic,
非メタリック
to white, completely metallic.
白は完全にメタリックを意味します
However, the advantage of using a texture
テクスチャを使用する利点は
to define the metalness of a material
マテリアルのサーフェイスの
is to vary the metalness value
部分ごとに異なるメタルネスを
across the surface of the material.
与えられる点にあります
An additional advantage is this texture's alpha channel.
またさらに便利なのがテクスチャのアルファチャンネルです
This alpha channel can be used to define
このアルファチャンネルはスムースネスマップの
a smoothness map.
定義にも使用できます
Many materials are far more complex
マテリアルの多くはすべて同じサーフェイスではなく
than a single uniform surface.
より複雑な構造をしています
Take this leather case for example.
たとえばこのレザーケース
With a single value for metalness and a
メタルネスとスムースネスの値を
single value for smoothness
それぞれ指定しただけの状態でも
the case looks good.
見た目はそれなりに良いですが
But it could look better.
これはもっと良くできます
Use a metalness and smoothness map
メタルネスとスムースネスのマップを使って
to describe the properties.
プロパティを記述してみましょう
And it looks much better.
ほら グッと良くなりました
Note how the straps are far more glossy
ストラップ部分がケースの他の部分よりも
than the main body of the case.
ピカピカしているのが分かるでしょうか?
Giving them a feel of polished leather.
磨かれた皮革の感じが出てきますね
It is worth noting that when using a texture
なおテクスチャを使ってメタルネスを
to define the metalness
定義する場合には
the smoothness value must also be
スムースネスの値をそのテクスチャの
defined by that texture's alpha channel.
アルファチャンネルで定義しておく必要があります
It is also worth noting that the metalness
metalnessの値はmetalnessマップの
value is stored only in the red
RGB 値において Red チャンネルにのみ
channel of the metalness map's RGB values.
格納されることも覚えておいてください
The green and blue channels are ignored.
Green と Blue チャンネルの値は無視されます
It is often easier however to visualise
ただカラーチャンネル 3 つが同じマップを
the metalness values of a texture
使っているのならmetalness値を
if all three colour channels share the same map,
示すのに問題はないのでテクスチャは
so the texture appears as a greyscale image.
グレースケールで表示されます
When using the standard shader with the specular setup
標準シェーダーを Specular セットアップで使用する場合
the metallic property is replaced with
Metallic プロパティは
the specular property.
Specular プロパティと置き換わります
The specular approach also uses
Specular アプローチでも
a smoothness property, which behaves essentially
Smoothness プロパティを使い その振る舞いも
in the same way as with the metalness approach.
基本的には Metalic アプローチの時と同じです
The specualar property can either be a texture
Specualar プロパティはテクスチャーまたは
or a colour value
カラー値になり
and defines the specular reflectivity
マテリアルのサーフェイスの
of the material's surface.
スペキュラ反射率を定義します
The specular value can have some colour in it
Specular 値には色を持たせることが可能ですが
but looking at real world values
現実世界の観点から見るとこの色は
with the exception of some metals
一部の金属を除いて灰色
this is usually a grey and often very dark.
あるいは暗い灰色になります
Specular maps are usually a dark grey as well.
スペキュラマップも通常は暗い灰色になります
When a specular texture map is not being used
スペキュラテクスチャマップが使われていない場合は
the overall surface smoothness can be
サーフェイス全体のスムースネスは
set with the slider.
スライダーで指定できます
This is easier to see when the albido
Albido テクスチャを外してみると
texture is removed.
smoothnessはより分かりやすくなります
The ball looks like polished porcelain.
ボールはよく磨かれた陶器のように見えますね
For a more true mirror, the specular from dark grey,
これを鏡のようにするには Specular の色を暗い灰色から変えてみます
which makes the ball look like porcelain
こうすると先ほどまでは陶器のようだったボールが
in to the range of metals and it will now
金属のような見た目になり
reflect the sky and surroundings.
空や周辺を反射するようになります
The smoother the surface, the more it is mirror-like.
Smoothness は高いほど鏡のようになります
The rougher the surface the more diffuse,
サーフェイスが荒くなるほどデフューズがかかり
or scattered the reflections are.
反射は四散するようになります
The normal map property is an optional property
Normal Map プロパティは任意指定のプロパティで
used to define the apparent bumpiness of the surface.
サーフェイスの凹凸を定義するのに使用されます
When a normal map is applied
Normal Map の適用後は
the strength of the normal map can be controlled
Normal Map の値でノーマルマップの強さを
by adjusting the normal map value.
調節できるようになります
As well as positive numbers, this value
ここでは正の値はもちろん
can be a negative number
負の値や
or 0.
0 を指定することも可能です
The height map property is an optional
Height Map は任意指定のプロパティで
property used to define the apparent
サーフェイスの高さを定義する
height of the surface.
際に使用します
When a height map is applied
Height Map 適用後は
the strength of the height map can be controlled
Height Map の値でハイトマップの強さを
by adjusting the height map value.
調節できるようになります
The occlusion property uses a
Occlusion プロパティは
texture map to define the amount of
テクスチャマップを使ってマテリアルに
ambient occlusion that is applied to the material.
適用されたアンビエントオクルージョンを定義します
This is used to help darken
これは暗い部分 / 隠された部分 /
hidden or recessed areas on the texture.
あるいは凹みを補佐する目的で使用します
The ambient occlusion map also
またアンビエントオクルージョンマップは
prevents specular and reflections in
遮蔽エリアのスペキュラと反射を防ぎ
these occluded areas, given the material
マテリアルがよりリアルな見た目を
a more realistic look.
実現できるようにします
The emission property controls whether or not
Emission プロパティはマテリアルのサーフェイスが
the material's surface will emit light.
自己発光するかどうかを制御します
The material's emission value can contribute
マテリアルの Emission 値はシーンの
to the scene's global illumination.
グローバルイルミネーションにも関係してきます
The strength of the emission can be controlled
Emission の強さは横にあるフィールドに
by the emission value.
指定する値で定義されます
The shape of the emission can be controlled with an emission map.
Emission の形は Emission Map で制御します
The map can be a simple black and white map.
このマップは単純な白黒マップで OK ですが
bBut this texture can also be a colour map.
色付きのマップにすることも可能です
When there is a value for emission
Emission に値が指定されている場合
the contribution of the emissive light
その光の割り当て先として
can be assigned to either the baked light maps
Baked ライトマップまたは
or to the real time light maps.
Realtime ライトマップが指定できます
The detail mask property is an optional mask element
Detail Mask プロパティは任意指定のマスク要素で
to control the secondary maps.
セカンダリマップの管理に使用します
Tiling and offset control the position of the map.
Tiling と Offset はマップの位置を制御するのに使用します
The secondary maps are used to define
Secondary Maps はサーフェイスにより
additional surface detail.
補足的ディテールを追加する際に使用します
This additional detail, sometimes referred to as micro detail,
補足的ディテール あるいはマイクロディテールは
is added on top of the surface defined
メインマップで定義されたサーフェイスの上に
by the main maps.
追加されます
This helps to add extra detail and
これらはうまく活用することでメインマップの上に
variation to a material, which is overlaid
マテリアルを上乗せしてより細やかな
on top of the main maps defining that material.
書き込みをしたり変化を加えたりすることが可能になります
Because detail maps can be tiled across meshes
ディテールマップはメッシュに対してタイル配置できるので
they can add incredibly high levels of surface detail.
サーフェイスに驚くほど細やかなディテールを加える事が可能です