Re: Function set-gl-vertex-array in Guile-opengl

2019-02-09 Thread Luis Souto Graña
I found the mistake. I only had to add two lines. It works. (use-modules (gl) (glut)) (use-modules (gl contrib packed-struct)) (define-packed-struct vertices (x float) (y float) (z float) (r float) (g float) (b float)) (define vertices-square (make-packed-array vertices 4)) (pack ver

Re: Function set-gl-vertex-array in Guile-opengl

2019-01-31 Thread Luis Souto Graña
I think I almost have it. I made a minimal example with a square. It starts but the square doesn't appear. If anyone finds where the fault is, please let me know. (use-modules (gl) (glut)) (use-modules (gl contrib packed-struct)) (define-packed-struct vertices (x float) (y float) (z float)

Re: Function set-gl-vertex-array in Guile-opengl

2019-01-28 Thread Luis Souto Graña
Andy Wingo doesn't use f32vectors, he uses packed-struct.scm https:// github.com/guildhall/guile-opengl/blob/master/gl/contrib/packed-struct.scm . There are bytevector-ieee-single-native-set in it. It works because I wrote: $ cd /home/spectrumgomas/guile-opengl-01.0/examples/particle-system $ gui

Re: Function set-gl-vertex-array in Guile-opengl

2019-01-26 Thread Luis Souto Graña
Thank a lot, now at least I have clear f32vector structure. El sáb., 26 ene. 2019 a las 16:39, Daniel Llorens (< daniel.llor...@bluewin.ch>) escribió: > > > > On 26 Jan 2019, at 17:05, Luis Souto Graña > wrote: > > > > The structure of my byvector is: > > > > 30.0(float) --- IEE754 converter -->

Re: Function set-gl-vertex-array in Guile-opengl

2019-01-26 Thread Daniel Llorens
> On 26 Jan 2019, at 17:05, Luis Souto Graña wrote: > > The structure of my byvector is: > > 30.0(float) --- IEE754 converter --> 0x41F0 (hexadecimal) --- little > endian ---> F041 --- hexadecimal to decimal converter ---> 00 00 240 65 > > But I didn't notice and there's a lot of z

Re: Function set-gl-vertex-array in Guile-opengl

2019-01-26 Thread Luis Souto Graña
The structure of my byvector is: 30.0(float) --- IEE754 converter --> 0x41F0 (hexadecimal) --- little endian ---> F041 --- hexadecimal to decimal converter ---> 00 00 240 65 But I didn't notice and there's a lot of zeros before the next 00 00 240 65. I have to study what is the structur

Re: Function set-gl-vertex-array in Guile-opengl

2019-01-26 Thread Luis Souto Graña
> it uust to see if I could reproduce this error you are running into > > Il giorno ven 25 gen 2019 alle ore 15:58 Luis Souto Graña < > luissoutob...@gmail.com> ha scritto: > >> Hello, I'm trying to use the function set-gl-vertex-array in Guile-opengl >> . >&

Re: Function set-gl-vertex-array in Guile-opengl

2019-01-26 Thread Daniel Llorens
> On 26 Jan 2019, at 13:52, Daniel Llorens wrote: > > > >> On 26 Jan 2019, at 02:33, Luis Souto Graña wrote: > > ,apropos set-gl-vertex-array >>> (gl): set-gl-vertex-array#>> bv-or-pointer #:optional size #:key stride offset)> >>> >>> (set-gl-vertex-array (bytevector

Re: Function set-gl-vertex-array in Guile-opengl

2019-01-26 Thread Daniel Llorens
't understand the purpose of (* n 30) on your code. The original you > link has (* n 4) which is what I'd expect for f32. > > Regards > > Daniel > > >> From: Luis Souto Graña >> Subject: Function set-gl-vertex-array in Guile-opengl >>

Re: Function set-gl-vertex-array in Guile-opengl

2019-01-26 Thread Catonano
the function set-gl-vertex-array in Guile-opengl . > It needs a bytevector as an argument. I wrote this doing a copy-paste from > here: https://github.com/marcomaggi/vicare/blob/master/attic/lab/gears.scm > > (use-modules (rnrs bytevectors)) > (use-modules (system foreign)) > &g

Re: Function set-gl-vertex-array in Guile-opengl

2019-01-25 Thread Luis Souto Graña
has (* n 4) which is what I'd expect for f32. > > Regards > > Daniel > > > *From: *Luis Souto Graña > *Subject: **Function set-gl-vertex-array in Guile-opengl* > *Date: *25 January 2019 at 11:36:33 CET > *To: *guile-user@gnu.org > > > Hello, I'm trying

Re: Function set-gl-vertex-array in Guile-opengl

2019-01-25 Thread Daniel Llorens
> Subject: Function set-gl-vertex-array in Guile-opengl > Date: 25 January 2019 at 11:36:33 CET > To: guile-user@gnu.org > > > Hello, I'm trying to use the function set-gl-vertex-array in Guile-opengl . > It needs a bytevector as an argument. I wrote this doing a copy-p

Function set-gl-vertex-array in Guile-opengl

2019-01-25 Thread Luis Souto Graña
Hello, I'm trying to use the function set-gl-vertex-array in Guile-opengl . It needs a bytevector as an argument. I wrote this doing a copy-paste from here: https://github.com/marcomaggi/vicare/blob/master/attic/lab/gears.scm (use-modules (rnrs bytevectors)) (use-modules (system fo