??? 06/10/10 20:35 Modified: 06/10/10 20:38 Read: times |
#176589 - Gives color jumps Responding to: ???'s previous message |
Nice excel sheet. I had to explicitly rename it to *.xlsm - the browser wanted to save it as *.zip and if opened it just contained a large number of xml files that no program would be able to open.
But note that whatever order of the color planes, it will not solve the issue with jumping color values. When "exploding" the index into its three components, the three components will form three saw-tooth curves. One color component will have one tooth. One color component will have five tooths. And one color component will have 25 tooths. And this means that steping from the index sequentially will always result in large jumps for one or more color channels when passing n%4 -> n%5. /| /| / | / | / | / | / |/ | The only way to arrange 125 colors so that colors doesn't jump is by doing something similar to gray-code - every step in the index should only change one color channel, and only with one step up or down. /\ /\ /\ / / \ / \ / \ / / \/ \/ \/ -- -- -- --/ \-- --/ \-- --/ --/ \-- --/ \-- --/ --/ \--/ \--/ -------- --------/ \-------- --------/ \-------- ---------/ \-------- This is basically a zig-zag of a RGB cube Red-> Green >>>>> | <<<<< - v >>>>> /| <<<<< / >>>>> Blue Zig-zaging or any other continuous walk through the 5x5x5 cube that spans all 125 positions is the only way that removes the big jumps within the sequence. Right now, I'm too tired to think closer about the problem but I'm not sure if there can exist any walk through a 5x5x5 cube where the last step will be neighbour with the first step, or if there will be one big color jump. One way to loosen up the rule is to allow diagonal moves, i.e. allowing more than one color channel to step one step up or down. |