Morphic pixel writing

Joshua 'Schwa' Gargus schwa at cc.gatech.edu
Wed Jul 2 06:09:23 UTC 2003


The class Form has #colorAt:put:, which sounds like what you want (it's not
very fast, though).  Forms can be drawn on Canvases; see ImageMorph>>drawOn:
for an example.

It sounds like you probably want to subclass ImageMorph, and modify the
pixels in the ImageMorphs form.

Hope this helps,
Joshua


On Tue, Jul 01, 2003 at 10:46:26PM -0700, Joel Shellman wrote:
> How would one draw an image in Squeak pixel by pixel (programmatically)? I
> saw that generally you would subclass Morph or MorphForm or something like
> that and then override the #drawOn method, but I couldn't find anything in
> Canvas that would allow me to write a specific pixel. It only had lines,
> rectangles, fills and such.
> 
> Thanks,
> 
> -joel
> 



More information about the Squeak-dev mailing list