1. A method for obtaining an interpolated color output value corresponding to a color input value based on a color look-up table which stores color output values of each vertex of a cubic grid of color input values, the method comprising the steps of:
- for at least one vertex of at least one cube of a cubic grid, determining a distance of an input color from the at least one vertex, the distance comprising plural component distances each of which corresponds to a component value of the input color;
- calculating plural weights corresponding to the at least one cube of the cubic grid and at least one tetrahedron into which the at least one cube is dissected, the plural weights being calculated based on the distance of the input color from the at least one vertex of the at least one cube;
- storing the calculated weights in a temporary look-up table accessible by an index;
- executing a block of code, wherein instead of using conditional branch instructions conditioned on a comparison of the plural component values of the input color to determine interpolating weights, the block of code using therein the component distances to calculate the index to the look-up table of weights; and
- applying weights accessed at the indexed location of the temporary look-up table to color output values of the color look-up table, the weights being applied to the color output values at vertices of a tetrahedron identified by the index so as to obtain an interpolated output color corresponding to the input color.
2. A method according to claim 1, wherein the block of code also calculates the plural weights by arithmetic operations.
3. A method according to claim 2, wherein the arithmetic operations include subtraction commands that set a condition code.
4. A method according to claim 3, wherein the block of code uses the condition code to build the index.
5. A method according to claim 4, wherein the plural weights and the index are calculated coextensively.
6. A method according to claim 1, wherein the block of code calculates the index using bit shift commands.
7. A method according to claim 1, wherein the block of code calculates the index using bit masking commands.
8. A method according to claim 1, wherein the steps of determining a distance, calculating the plural weights, storing the calculated weights, executing the block of code, and applying the weights are repeated for each pixel of an input image.
9. An apparatus for obtaining an interpolated color output value corresponding to a color input value based on a color look-up table which stores color output values of each vertex of a cubic grid of color input values, comprising:
- a memory including a region for storing the color look-up table, a region for storing a temporary look-up table, and a region for storing executable process steps; and
- a processor for executing the executable process steps;
- wherein the executable process steps include steps of: (a) for at least one vertex of at least one cube of a cubic grid, determining a distance of an input color from the at least one vertex, the distance comprising plural component distances each of which corresponds to a component value of the input color, (b) calculating plural weights corresponding to the at least one cube of the cubic grid and at least one tetrahedron into which the at least one cube is dissected, the plural weights being calculated based on the distance of the input color from the at least one vertex of the at least one cube, (c) storing the calculated weights in the temporary look-up table accessible by an index, (d) executing a block of code, wherein instead of using conditional branch instructions conditioned on a comparison of the plural component values of the input color to determine interpolating weights, the block of code using therein the component distances to calculate the index to the look-up table of weights, and (e) applying weights, accessed at the indexed location of the temporary look-up table to color output values of the color look-up table, the weights being applied to the color output values at vertices of a tetrahedron identified by the index so as to obtain an interpolated output color corresponding to the input color.
10. An apparatus according to claim 9, wherein the block of code also calculates the plural weights by arithmetic operations.
11. An apparatus according to claim 10, wherein the arithmetic operations include subtraction commands that set a condition code.
12. An apparatus according to claim 11, wherein the block of code uses the condition code to build the index.
13. An apparatus according to claim 12, wherein the plural weights and the index are calculated coextensively.
14. An apparatus according to claim 9, wherein the block of code calculates the index using bit shift commands.
15. An apparatus according to claim 9, wherein the block of code calculates the index using bit masking commands.
16. An apparatus according to claim 9, wherein the executable-process steps of determining a distance, calculating the plural weights, storing the calculated weights, executing the block of code, and applying the weights are repeated for each pixel of an input image.
17. Computer-executable process steps stored on a computer-readable medium, the computer executable process steps to obtain an interpolated color output value corresponding to a color input value based on a color look-up table which stores color output values of each vertex of a cubic grid of color input values, the computer-executable process steps comprising:
- for at least one vertex of at least one cube of a cubic grid, code to determine a distance of an input color from the at least one vertex, the distance comprising plural component distances each of which corresponds to a component value of the input color;
- code to calculate plural weights corresponding to the at least one cube of the cubic grid and at least one tetrahedron into which the at least one cube is dissected, the plural weights being calculated based on the distance of the input color from the at least one vertex of the at least one cube;
- code to store the calculated weights in a temporary look-up table accessible by an index;
- code to calculate the index to the look-up table of weights, wherein instead of using conditional branch instructions conditioned on a comparison of the plural component values of the input color to determine interpolating weights, the code using therein the component distances to calculate the index to the look-up table of weights; and
- code to apply weights accessed at the indexed location of the temporary look-up table to color output values of the color look-up table, the weights being applied to the color output values at vertices of a tetrahedron identified by the index so as to obtain an interpolated output color corresponding to the input color.
18. Computer-executable process steps according to claim 17, wherein the plural weights are calculated by arithmetic operations.
19. Computer-executable process steps according to claim 18, wherein the arithmetic operations include subtraction commands that set a condition code.
20. Computer-executable process steps according to claim 19, wherein the condition code is used to build the index.
21. Computer-executable process steps according to claim 20, wherein the plural weights and the index are calculated coextensively.
22. Computer-executable process steps according to claim 17, wherein the index is calculated using bit shift commands.
23. Computer-executable process steps according to claim 17, wherein the index is calculated using bit masking commands.
24. Computer-executable process steps according to claim 17, wherein the codes to determine a distance, calculate the plural weights, store the calculated weights, execute the block of code, and apply the weights are repeated for each pixel of an input image.
25. A computer-readable medium which stores computer-executable process steps, the computer-executable process steps to obtain an interpolated color output value corresponding to a color input value based on a color look-up table which stores color output values of each vertex of a cubic grid of color input values, the computer-executable process steps comprising:
- a determining step to determine, for at least one vertex of at least one cube of a cubic grid, a distance of an input color from the at least one vertex, the distance comprising plural component distances each of which corresponds to a component value of the input color;
- a calculating step to calculate plural weights corresponding to the at least one cube of the cubic grid and at least one tetrahedron into which the at least one cube is dissected, the plural weights being calculated based on the distance of the input color from the at least one vertex of the at least one cube;
- a storing step to store the calculated weights in a temporary look-up table accessible by an index;
- an executing step to execute a block of code, wherein instead of using conditional branch instructions conditioned on a comparison of the plural component values of the input color to determine interpolating weights, the block of code using therein the component distances to calculate the index to the look-up table of weights; and
- an applying step to apply weights accessed at the indexed location of the temporary look-up table to color output values of the color look-up table, the weights being applied to the color output values at vertices of a tetrahedron identified by the index so as to obtain an interpolated output color corresponding to the input color.
26. A computer-readable medium according to claim 25, wherein the block of code also calculates the plural weights by arithmetic operations.
27. A computer-readable medium according to claim 26, wherein the arithmetic operations include subtraction commands that set a condition code.
28. A computer-readable medium according to claim 27, wherein the block of code uses the condition code to build the index.
29. A computer-readable medium according to claim 28, wherein the plural weights and the index are calculated coextensively.
30. A computer-readable medium according to claim 25, wherein the block of code calculates the index using bit shift commands.
31. A computer-readable medium according to claim 25, wherein the block of code calculates the index using bit masking commands.
32. A computer-readable medium according to claim 25, wherein the executable-process steps of determining a distance, calculating the plural weights, storing the calculated weights, executing the block of code, and applying the weights are repeated for each pixel of an input image.