diff --git a/data/tests/test_bsdf.xml b/data/tests/test_bsdf.xml index c47ad338..6f7b0448 100644 --- a/data/tests/test_bsdf.xml +++ b/data/tests/test_bsdf.xml @@ -1,18 +1,7 @@ - - - - - - - + @@ -211,4 +200,12 @@ + + + + + + + + diff --git a/doc/images/bsdf_roughcoating_gold_rough.jpg b/doc/images/bsdf_roughcoating_gold_rough.jpg new file mode 100644 index 00000000..4b92804e Binary files /dev/null and b/doc/images/bsdf_roughcoating_gold_rough.jpg differ diff --git a/doc/images/bsdf_roughcoating_gold_smooth.jpg b/doc/images/bsdf_roughcoating_gold_smooth.jpg new file mode 100644 index 00000000..1dd8b60a Binary files /dev/null and b/doc/images/bsdf_roughcoating_gold_smooth.jpg differ diff --git a/doc/main.tex b/doc/main.tex index a1e34d57..673d7eec 100644 --- a/doc/main.tex +++ b/doc/main.tex @@ -138,9 +138,12 @@ % ----- 8< ----- 8< ------ \title{ - \includegraphics[width=4cm]{images/logo_plain.pdf}\\\vspace{2cm} - Mitsuba Documentation\\\vspace{3mm} - \large Version \MitsubaVersion + \vspace{3cm} + \includegraphics[width=4cm]{images/logo_plain.pdf}\\\vspace{1.5cm} + \Huge + Mitsuba Documentation\\\vspace{4mm} + \LARGE Version \MitsubaVersion + \vspace{5mm} } \author{Wenzel Jakob} \date{\today} diff --git a/src/bsdfs/coating.cpp b/src/bsdfs/coating.cpp index 5b4f9f93..cd17a995 100644 --- a/src/bsdfs/coating.cpp +++ b/src/bsdfs/coating.cpp @@ -48,9 +48,9 @@ MTS_NAMESPACE_BEGIN * * This plugin implements a smooth dielectric coating (e.g. a layer of varnish) * in the style of the paper ``Arbitrarily Layered Micro-Facet Surfaces'' by - * Weidlich and Wilkie \cite{Weidlich2007Arbitrarily}. Any non-transmissive - * BSDF in Mitsuba can be coated using this plugin, and multiple coating layers - * can be applied in sequence. This allows designing interesting custom materials + * Weidlich and Wilkie \cite{Weidlich2007Arbitrarily}. Any BSDF in Mitsuba + * can be coated using this plugin, and multiple coating layers can even + * be applied in sequence. This allows designing interesting custom materials * like car paint or glazed metal foil. The coating layer can optionally be * tinted (i.e. filled with an absorbing medium), in which case this model also * accounts for the directionally dependent absorption within the layer. diff --git a/src/bsdfs/roughcoating.cpp b/src/bsdfs/roughcoating.cpp index 2e8c0d8b..54b8babb 100644 --- a/src/bsdfs/roughcoating.cpp +++ b/src/bsdfs/roughcoating.cpp @@ -25,7 +25,7 @@ MTS_NAMESPACE_BEGIN #define TRANSMITTANCE_PRECOMP_NODES 200 -/*!\plugin{roughcoating}{Rough coating material} +/*!\plugin{roughcoating}{Rough dielectric coating} * \order{10} * \icon{bsdf_roughcoating} * \parameters{ @@ -59,8 +59,37 @@ MTS_NAMESPACE_BEGIN * \parameter{sigmaA}{\Spectrum\Or\Texture}{The absorption coefficient of the * coating layer. \default{0, i.e. there is no absorption}} * \parameter{\Unnamed}{\BSDF}{A nested BSDF model that should be coated.} + * }\vspace{-4mm} + * \renderings{ + * \rendering{Rough gold coated with a \emph{smooth} varnish layer} + * {bsdf_roughcoating_gold_smooth} + * \rendering{Rough gold coated with a \emph{rough} ($\alpha\!=\!0.03$) varnish layer} + * {bsdf_roughcoating_gold_rough} * } * + * This plugin implements a \emph{very} approximate\footnote{ + * The model only accounts for roughness + * in the specular reflection and Fresnel transmittance through the interface. + * The interior model receives incident illumination + * that is transformed \emph{as if} the coating was smooth. While + * that's not quite correct, it is a convenient workaround when the + * \pluginref{coating} plugin produces specular highlights that are too sharp.} + * model that simulates a rough dielectric coating. It is essentially the + * roughened version of \pluginref{coating}. + * Any BSDF in Mitsuba can be coated using this plugin, and multiple coating + * layers can even be applied in sequence. This allows designing interesting + * custom materials. The coating layer can optionally be tinted (i.e. filled + * with an absorbing medium), in which case this model also accounts for the + * directionally dependent absorption within the layer. +* + * Note that the plugin discards illumination that undergoes internal + * reflection within the coating. This can lead to a noticeable energy + * loss for materials that reflect much of their energy near or below the critical + * angle (i.e. diffuse or very rough materials). + * + * The implementation here is influenced by the paper + * ``Arbitrarily Layered Micro-Facet Surfaces'' by Weidlich and + * Wilkie \cite{Weidlich2007Arbitrarily}. */ class RoughCoating : public BSDF { public: