BoltBait Posted January 24, 2018 Share Posted January 24, 2018 In some instances, Adjustments > Posterize is rendering too many colors. In this example, I'm asking it to render 16 different colors, it is actually rendering 32. Maybe I just don't know how posterize is supposed to work. I just assumed with linked sliders and choosing 16, I'd get 16 colors. Is that wrong? If I render a gradient from black to white, posterize gives me exactly the number of colors I choose, 16. Quote Click to play: Download: BoltBait's Plugin Pack | CodeLab | and how about a Computer Dominos Game Link to comment Share on other sites More sharing options...
MJW Posted January 24, 2018 Share Posted January 24, 2018 1 hour ago, BoltBait said: Maybe I just don't know how posterize is supposed to work. I just assumed with linked sliders and choosing 16, I'd get 16 colors. Is that wrong? You get 16 levels per color channel, but that can produce 4096 (16^3) colors. If you had a multi-color image, with various mixtures of red, green, and blue, it would probably be clear; the confusion results from having all the colors be nearly red. Consider an image with a white-to-green gradient on the top, and a black-to-red gradient on the bottom. Posterize set to 16, 16, 16, would produce 16 saturations of green on the top, and 16 values of red on the bottom. Quote Link to comment Share on other sites More sharing options...
BoltBait Posted January 24, 2018 Author Share Posted January 24, 2018 With the same gradient, if I move the linked sliders to 2, I get 3 colors. Quote Click to play: Download: BoltBait's Plugin Pack | CodeLab | and how about a Computer Dominos Game Link to comment Share on other sites More sharing options...
MJW Posted January 24, 2018 Share Posted January 24, 2018 I hate to say that's just how it works out, but that's just how it woks out. For any setting, you can end up with anywhere between 1 color and the product of the channel settings, depending on the image. In your gradient, the level of green is very low, so if there are large gaps between the colors -- as there are for a setting of 3, 3, 3 -- it may not be enough to show up in a separate color. Quote Link to comment Share on other sites More sharing options...
BoltBait Posted January 24, 2018 Author Share Posted January 24, 2018 Well, if that's how Posterize "works", I hate it. Has anyone written a better one? Or, should I start thinking of a better algorithm? Quote Click to play: Download: BoltBait's Plugin Pack | CodeLab | and how about a Computer Dominos Game Link to comment Share on other sites More sharing options...
MJW Posted January 24, 2018 Share Posted January 24, 2018 That's really the only easy way it can work. Producing exactly 16 good color choices is a non-trivial task. Programs that produce GIFs do something like that, but they produce 256 colors, so they have more leeway. You might try Neil Cassidy's Segment Image plugin. It's old, so I don't know if it still works. Quote Link to comment Share on other sites More sharing options...
BoltBait Posted January 24, 2018 Author Share Posted January 24, 2018 6 minutes ago, MJW said: You might try Neil Cassidy's Segment Image plugin. It's old, so I don't know if it still works. It works perfectly. If I choose (16, 0.1, good quality) I get just the image I expect. Quote Click to play: Download: BoltBait's Plugin Pack | CodeLab | and how about a Computer Dominos Game Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.