mirror of
https://github.com/PixarAnimationStudios/OpenSubdiv
synced 2024-11-28 22:31:07 +00:00
Fix accumulation of stencil derivatives
- make sure not to skip CVs that have 0.0 weight because derivative may be contributing (non 0 tangent weight) fixes #364
This commit is contained in:
parent
ff223e4aaf
commit
e330b4513f
@ -228,7 +228,7 @@ public:
|
||||
|
||||
void PushBackVertex(Index protoStencil,
|
||||
Index vert, float weight, float tan1Weight, float tan2Weight) {
|
||||
assert(weight!=0.0f);
|
||||
assert(weight!=0.0f or tan1Weight!=0.0f or tan2Weight!=0.0f);
|
||||
unsigned char & size = this->_sizes[protoStencil];
|
||||
Index idx = protoStencil*this->_maxsize;
|
||||
if (size < (this->_maxsize-1)) {
|
||||
@ -458,7 +458,7 @@ public:
|
||||
void AddWithWeight(Stencil const & src,
|
||||
float weight, float tan1Weight, float tan2Weight) {
|
||||
|
||||
if(weight==0.0f) {
|
||||
if(weight==0.0f and tan1Weight==0.0f and tan1Weight==0.0f) {
|
||||
return;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user