Exemplo n.º 1
0
PlasticBsdf::PlasticBsdf()
: _ior(1.5f),
  _thickness(1.0f),
  _sigmaA(0.0f)
{
    _lobes = BsdfLobes(BsdfLobes::SpecularReflectionLobe | BsdfLobes::DiffuseReflectionLobe);
}
Exemplo n.º 2
0
void PhongBsdf::prepareForRender()
{
    _lobes       = BsdfLobes(BsdfLobes::GlossyReflectionLobe | BsdfLobes::DiffuseReflectionLobe);
    _invExponent = 1.0f/(1.0f + _exponent);
    _pdfFactor   = (_exponent + 1.0f)*INV_TWO_PI;
    _brdfFactor  = (_exponent + 2.0f)*INV_TWO_PI;
}
Exemplo n.º 3
0
void RoughCoatBsdf::prepareForRender()
{
    _scaledSigmaA = _thickness*_sigmaA;
    _avgTransmittance = std::exp(-2.0f*_scaledSigmaA.avg());
    _distribution = Microfacet::stringToType(_distributionName);
    _lobes = BsdfLobes(BsdfLobes::GlossyReflectionLobe, _substrate->lobes());
}
Exemplo n.º 4
0
ConductorBsdf::ConductorBsdf()
: _materialName("Cu"),
  _eta(0.200438f, 0.924033f, 1.10221f),
  _k(3.91295f, 2.45285f, 2.14219f)
{
    _lobes = BsdfLobes(BsdfLobes::SpecularReflectionLobe);
}
Exemplo n.º 5
0
MixedBsdf::MixedBsdf(std::shared_ptr<Bsdf> bsdf0, std::shared_ptr<Bsdf> bsdf1, float ratio)
: _bsdf0(bsdf0),
  _bsdf1(bsdf1),
  _ratio(std::make_shared<ConstantTexture>(ratio))
{
    _lobes = BsdfLobes(_bsdf0->lobes(), _bsdf1->lobes());
}
Exemplo n.º 6
0
ThinSheetBsdf::ThinSheetBsdf()
: _ior(1.5f),
  _enableInterference(false),
  _thickness(std::make_shared<ConstantTexture>(0.5f)),
  _sigmaA(0.0f)
{
    _lobes = BsdfLobes(BsdfLobes::SpecularReflectionLobe | BsdfLobes::ForwardLobe);
}
Exemplo n.º 7
0
RoughWireBcsdf::RoughWireBcsdf()
: _materialName("Cu"),
  _eta(0.200438f, 0.924033f, 1.10221f),
  _k(3.91295f, 2.45285f, 2.14219f),
  _roughness(0.1f)
{
    _lobes = BsdfLobes(BsdfLobes::GlossyLobe | BsdfLobes::AnisotropicLobe);
}
Exemplo n.º 8
0
RoughPlasticBsdf::RoughPlasticBsdf()
: _ior(1.5f),
  _thickness(1.0f),
  _sigmaA(0.0f),
  _distribution("ggx"),
  _roughness(std::make_shared<ConstantTexture>(0.02f))
{
    _lobes = BsdfLobes(BsdfLobes::GlossyReflectionLobe | BsdfLobes::DiffuseReflectionLobe);
}
Exemplo n.º 9
0
HairBcsdf::HairBcsdf()
: _scaleAngleDeg(2.0f),
  _melaninRatio(0.5f),
  _melaninConcentration(0.25f),
  _overridesSigmaA(false),
  _sigmaA(0.0f),
  _roughness(0.1f)
{
    _lobes = BsdfLobes(BsdfLobes::GlossyLobe | BsdfLobes::AnisotropicLobe);
}
Exemplo n.º 10
0
OrenNayarBsdf::OrenNayarBsdf()
: _roughness(std::make_shared<ConstantTexture>(1.0f))
{
    _lobes = BsdfLobes(BsdfLobes::DiffuseReflectionLobe);
}
Exemplo n.º 11
0
LambertBsdf::LambertBsdf()
{
    _lobes = BsdfLobes(BsdfLobes::DiffuseReflectionLobe);
}
Exemplo n.º 12
0
void TransparencyBsdf::prepareForRender()
{
    _lobes = BsdfLobes(BsdfLobes::ForwardLobe, _base->lobes());
}
Exemplo n.º 13
0
void MixedBsdf::prepareForRender()
{
    _lobes = BsdfLobes(_bsdf0->lobes(), _bsdf1->lobes());
}