On Sat, Oct 21, 2017 at 02:38:18PM +0200, Alfonso Villén wrote:
> The function arguments don't work as you expected. That C function needs
> some weird information such as an array of integers giving the length of
> the strings in the other array if those don't end with null bytes...

Ah, I see. Didn't know that. Then it is probably something like:

   (de glShaderSource (Shader Strings)
               '((Str) (cons (native "@" "strdup" 'N Str) 8))
               Strings )
            Len (length Strings) )
         (native `*GlutLib "glShaderSource" NIL
            (cons NIL (list (* 8 Len)) Lst)
            (cons NIL (list (* 8 Len))
                  '((Str) (- (length Str)))
                  Strings ) ) )
         (mapc '((X) (native "@" "free" NIL (car X))) Lst) ) )

> I'm also having problems with other function, and in all of them there are
> pointer arguments involved. But I hope I'll be able to figure the solution
> myself.
> When I get some examples working I'd like to share the code with you all.

Great, thanks! Perhaps we can add them to @lib/openGl.l then.

♪♫ Alex

UNSUBSCRIBE: mailto:picolisp@software-lab.de?subject=Unsubscribe

Reply via email to