script-fu: what's an INT8ARRAY?

script-fu: what's an INT8ARRAY?

Post by Afzal Balli » Sat, 14 Nov 1998 04:00:00



Can anyone tell me what an INT8ARRAY is?

I presumed that it's a list of 8bit values, but I can't seem to get
anything to work using this
notion. For instance, the following function is supposed to write to a
particular point in a drawable:

(define (test a bk inv)
         ; create image and layer
  (set! img
        (car (gimp-image-new a a 0)))
  (set! layer
        (car (gimp-layer-new img a a
              0 "layer 1" 100 0)))
  (gimp-image-disable-undo img)
  (gimp-image-add-layer img layer 0)
  (cond ((equalp inv 0)
         (gimp-palette-set-background bk)))
  (gimp-edit-fill img layer)
  (gimp-drawable-set-pixel layer 10 10 3 '(128 64 128))
  (gimp-display-new img)
  (gimp-image-enable-undo img))

(script-fu-register
 "test"          ; name of func
 "<Toolbox>/Xtns/Script-Fu/Utils/Test" ; menu posn.
 "Does something"  ; help string
 "I. Am"           ; author
 "It's mine"       ; copyright
 "Today"           ; date
 ""                ;accepts any image type
 SF-VALUE "size" "128"  ; value param
 SF-COLOR "bk" '(0 0 0) ; color param
 SF-TOGGLE "inv" 0      ; boolean
)

However, I get an error message when I try to use it, saying that
there's a type
mismatch (and suggesting I may not have installed the correct font!).

--
Afzal Ballim - MEDIA Research Group (LITH-EPFL)
Swiss Federal Institute of Technology, IN Ecublens, 1015 Lausanne, Switzerland
 Voice: (+41 21) 693 52 34   |  fax: (+41 21) 693 52 78

 
 
 

1. script-fu and int8array

Hello

I want to use the function

(gimp-curves-explicit image drawable channel num_bytes curve)

or

(gimp-curves-spline image drawable channel num_points control_pts)

in script-fu.

curve or control_pts shall be entered as an INT8ARRAY.

Can somebody tell me in what format (syntax) the points or a curve will
be written ???

An example would be helpfull

thanks

2. Text on a DelphiX surface

3. Script-Fu from Perl-Fu non-interactively

4. HOW DO I ADD SOUND TO A .FLI ANIMATION?? HELP! OTHER FORMATS??

5. Script-fu GIMP 1.2 Win32 GPF's gimp

6. camera raw

7. script-fu's in text mode?

8. System Memory Surface - Wide Surface??

9. Beginner's script-fu questions

10. Where to download script-fu's?

11. Help Problem PERL-Fu script logo creation

12. finding function name for script-fu

13. Gimp 1.2.3 - Script-Fu freezing