On Tue, Aug 31, 2010 at 9:35 PM, P Kishor <[email protected]> wrote: > So, now that I have my images at least being created with wpic, I am > still facing problems with getting correct colors in with LUT. > > With the help of ngood(), I know that my $pdl has 6766 good values. I > printed out the unique values, and I have 28 unique good values (btw, > is there a PDL method that returns the unique values in a piddle? > Kinda like ngoodover() and ngood(), but instead of the number of good > values, returns the actual good values?). > > Ok, my LUT has 256 colors in it ranging from green (for 0) to yellow > (for 255). Yet, the generated image has only green and yellow. The > same image generated from IDL has all the colors showing up properly. > > The unique values I have are > (35,26,32,37,19,15,15,41,34,32,23,32,24,81,1,39,55,62,10,20,127,30,39,16,3,25,23,55), > and yet, colors for none of those values show up. >
Same problem as above even with PDL::IO::GD, so there something wrong in my understanding of how these commands work. Here is what I have ### Info for pdl: 'PDL: Byte D [252,189]' ### ngood in pdl: 6766 ### Info for lut: 'PDL: Byte D [3,256]' Good values listed above. Yet write_png($pdl, $lut, 'with_pdl_io_gd.png'); produces an image shown as attached.. only yellow (for 255) and green (for 0), the two ends of the spectrum. -- Puneet Kishor http://www.punkish.org Carbon Model http://carbonmodel.org Charter Member, Open Source Geospatial Foundation http://www.osgeo.org Science Commons Fellow, http://sciencecommons.org/about/whoweare/kishor Nelson Institute, UW-Madison http://www.nelson.wisc.edu ----------------------------------------------------------------------- Assertions are politics; backing up assertions with evidence is science =======================================================================
<<attachment: with_pdl_io_gd.png>>
_______________________________________________ Perldl mailing list [email protected] http://mailman.jach.hawaii.edu/mailman/listinfo/perldl
