MathGroup Archive 1998

[Date Index] [Thread Index] [Author Index]

Search the Archive

Getting a bitmap to display with the proper dimensions


If I have a RasterArray an I want to display it such as to get a one to
one mapping of my elements to the pixels in the notebook.

here is an example that works:

Show[Graphics[RasterArray[Table[GrayLevel[Mod[i+j,2]],{i,50},{j,40}]]],
  AspectRatio->Automatic,ImageSize->{40+3,50+9}]

as you see I had to add 3 and 9. those numbers are working for 40 and 50
as the dimensions. in practice I have to do trial and error to figure
what they need to be.It changes with a lot of options.For example add
Axes->True and try to get a one to one mapping again.

Is there an option or a formula that could make this an easier process?

thanks.



  • Prev by Date: Non-commutative algebra
  • Next by Date: processing {x,y,z} data
  • Previous by thread: Re: Re: Non-commutative algebra
  • Next by thread: Re: Getting a bitmap to display with the proper dimensions