Work around of using 1D-LUT instead of 2D-LUT

J

Jason

Dear All,

I originally have a look up table of size UInt8[256][256].

However, there is a restriction that just 1D look up table of size
UInt8[256] can be use. The no. of UInt8[256] tables to be used is not
limited.

Are there any simple method for me to constructing many 1D look up
tables of UInt8[256] so that the same result can be obtained as if the
2D-LUT UInt8[256][256] is used?

Note that the 1D-LUT can just have max. no. of element of 256. Ans
just +,-,*,/ operations can be used.


Thank you,
Jason
 
B

Barry Schwarz

Dear All,

I originally have a look up table of size UInt8[256][256].

However, there is a restriction that just 1D look up table of size
UInt8[256] can be use. The no. of UInt8[256] tables to be used is not
limited.

Are there any simple method for me to constructing many 1D look up
tables of UInt8[256] so that the same result can be obtained as if the
2D-LUT UInt8[256][256] is used?

Note that the 1D-LUT can just have max. no. of element of 256. Ans
just +,-,*,/ operations can be used.


Thank you,
Jason

If you are allowed to use 2d subscript notation, then

UInt8 lut_000[256];
UInt8 lut_001[256];
.....
UInt8 lut_255[256];
UInt8 *lut[] = {lut_000, lut_001, ..., lut_255};

contains only 1d tables each with only 256 elements but lut[j]
provides a method of accessing all 65K objects.

If not, you are going to have to explain the intent and the
restrictions more clearly.


<<Remove the del for email>>
 
R

Rob Thorpe

Dear All,

I originally have a look up table of size UInt8[256][256].

However, there is a restriction that just 1D look up table of size
UInt8[256] can be use. The no. of UInt8[256] tables to be used is not
limited.

Are there any simple method for me to constructing many 1D look up
tables of UInt8[256] so that the same result can be obtained as if the
2D-LUT UInt8[256][256] is used?

Note that the 1D-LUT can just have max. no. of element of 256. Ans
just +,-,*,/ operations can be used.


Thank you,
Jason

Can you explain why only 1D lookup tables can be used?
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,776
Messages
2,569,603
Members
45,189
Latest member
CryptoTaxSoftware

Latest Threads

Top