YOUR ACCOUNT

Login or Register to post new topics or replies
uberzev
not lyftzev

Posts: 1890
Filters: 36
Source Map...



Zev's Emboss (Using Offset)...



Derivative Based Emboss...



Please see attachment for further examples!
(Note that changing the anti-aliasing settings may fix certain occurrences of this bug, but not all of them)

Derivative Bug.ffxml
  Details E-Mail
GMM
Moderator
Filter Forge, Inc
Posts: 3491
Vladimir says it's by design. You can apply a tiny offset to get rid of the artifacts.
  Details E-Mail
uberzev
not lyftzev

Posts: 1890
Filters: 36
Quote
GMM wrote:
You can apply a tiny offset to get rid of the artifacts.
Example?
  Details E-Mail
Sphinx.
Filter Optimizer

Posts: 1750
Filters: 39
It looks like a floating point error - the values of those B&W pixels will not change, even if you divide the result of the Derivative by some large number (the gray areas are affected, because here there the floating point values are still valid).
  Details E-Mail
GMM
Moderator
Filter Forge, Inc
Posts: 3491
Quote
uberzev wrote:
Example?


Plz see the attached example.

Derivative Bug Offset.ffxml
  Details E-Mail
Sphinx.
Filter Optimizer

Posts: 1750
Filters: 39
I just tested the offset trick - it seems to get around the problem at first sight.
It does so by luck though, since it avoid "stepping on the cracks".

Make it "step on the cracks" by enabling antialias and set the sample count to something high (I used 49 samples). Now the salt n pepper is back.

For the programmers:
Try uberzevs original filter and divide the immediate result of the Derivative with a constant (say 111). This should affect every sample going through the Divide right?

Now inspect the B&W samples before and after Divide: the value remains unaffected by the division, indicating that this is infact a bug related to invalid floating point result of the Derivative component.
  Details E-Mail
GMM
Moderator
Filter Forge, Inc
Posts: 3491
Quote
Sphinx. wrote:
For the programmers: Try uberzevs original filter and divide the immediate result of the Derivative with a constant (say 111). This should affect every sample going through the Divide right?


Right, but the artifacts in the original filter are very bright. When you divide the HDR-white value of 111,33 by 111 it still remains HDR-white and its value rightfully changes to 1,0029. Try dividing by 1110 instead.

Note that I'm not a programmer but I'd prefer to have a more vivid example to forward to the testers.
  Details E-Mail
Sphinx.
Filter Optimizer

Posts: 1750
Filters: 39
Hmm.. I could be wrong (I'm on another computer now) and here it seems to "behave" as expected. Either I'm wrong or the error is CPU specific. I'll let you know when I get back to the other computer.
  Details E-Mail
Sphinx.
Filter Optimizer

Posts: 1750
Filters: 39
Ahemn.. division works just fine on the old computer too. No floating point errors, just a large value. I was probably tricked by a locked preview or something, sorry smile:blush:

Anyways - the spots still appear when you increase AA samples..
  Details E-Mail
uberzev
not lyftzev

Posts: 1890
Filters: 36
IMO this is a bug. Yes you can jack the anti-aliasing way up but that's not an elegant solution.
  Details E-Mail
Sphinx.
Filter Optimizer

Posts: 1750
Filters: 39
That will not solve it - try GMMs offset version with high AA - *only* with high AA the bug is present smile;)
  Details E-Mail
jitspoe
Posts: 189
Filters: 27
Hm, I thought maybe it was because it wasn't normalized, so I used the same technique I used for generating normal maps: square, add 1, square root, divide by that. The end result was the same. I had some similar artifacts without the normalize that normalizing seemed to fix. Maybe it has something to do with the lerp? I've not used that. Without the lerp, it's impossible to tell if the issue is there because the pixels are white or black around that point already.
  Details E-Mail

Join Our Community!

Filter Forge has a thriving, vibrant, knowledgeable user community. Feel free to join us and have fun!

33,711 Registered Users
+18 new in 30 days!

153,531 Posts
+36 new in 30 days!

15,347 Topics
+72 new in year!

Create an Account

Online Users Last minute:

24 unregistered users.