Form manipulation from a Plugin

diegogomezdeck at consultar.com diegogomezdeck at consultar.com
Mon Apr 7 13:57:33 UTC 2003


Hi list...

I'm processing a 32 bits Form in a slang-plugin.

The method receive the Form as a parameter:

   formOop := interpreterProxy stackObjectValue: 1.

Then I ask for widht, height and a pointer to bits:

   bits := interpreterProxy fetchPointer: 0 ofObject: formOop.
   width := self fetchIntOrFloat: 1 ofObject: formOop.
   height := self fetchIntOrFloat: 2 ofObject: formOop.

Then I iterate over the bits:

   bits
      to: bits + (height - 1 * (width * 4))
      by: 4
      do: [:pos |
         pixel := interpreterProxy longAt: pos.
         alpha := (pixel bitAnd: 16rFF000000) >> 24.
         <some other stuff>
      ].

The problem I have is the following: The alpha part of pixel is always 0.
(I don't need to say that the form has not transparent colors)

Any idea of my problem?


TIA,

Diego Gomez Deck






More information about the Squeak-dev mailing list