fixed manifold exploration for point light sources and cylinders (cardioid test scene works again..)
parent
f1f91c2ebd
commit
4a86baac4e
|
@ -915,7 +915,7 @@ Float SpecularManifold::G(const Path &path, int a, int b) {
|
|||
|
||||
SimpleVertex &last = m_vertices[m_vertices.size()-1];
|
||||
const PathVertex *vb = path.vertex(b);
|
||||
if (vb->isMediumInteraction()) {
|
||||
if (!vb->isOnSurface()) {
|
||||
last.n = Vector(path.edge(a < b ? (b-1) : b)->d);
|
||||
} else {
|
||||
last.n = vb->getShadingNormal();
|
||||
|
|
|
@ -495,7 +495,7 @@ public:
|
|||
|
||||
void getNormalDerivative(const Intersection &its,
|
||||
Vector &dndu, Vector &dndv, bool shadingFrame) const {
|
||||
dndu = its.dpdu / m_radius;
|
||||
dndu = its.dpdu / (m_radius * m_flipNormals ? -1 : 1);
|
||||
dndv = Vector(0.0f);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue