Asp Forum
Home
|
Login
|
Register
|
Search
Forums
>
comp.lang.ruby
Re: Rendering ruby openGL output to a file.
Eric Peden
2/28/2005 10:42:00 PM
On Feb 28, 2005, at 11:25 AM, Ruby NNTP->SMTP Gate wrote:
>> The OpenGL API works with raw color values packed into an array;
>> RMagick
>> (as far as I can tell) cannot. You should be able to draw your scene
>> offscreen, then do a readPixels() and then convert the resulting array
>> to RMagick Pixel values. Tell RMagick what your intended resolution
>> is,
>> and it will handle the rest.
> The #constitute method takes an array of RGBA values as input:
>
http://www.simplesystems.org/RMagick/doc/image1.html#...
I stand corrected. #constitute even scales floats to the correct range
automatically; this should help tidy up some of my code quite nicely.
#constitute should probably appear under store_pixel's "See also" in
the docs. I've always thought the xMagick libraries had rather poorly
named functions: heavy cross-linking makes it easier to find the tools
you never knew you needed.
Thanks for the pointer.
--
eric
Servizio di avviso nuovi messaggi
Ricevi direttamente nella tua mail i nuovi messaggi per
Re: Rendering ruby openGL output to a file.
Inserendo la tua e-mail nella casella sotto, riceverai un avviso tramite posta elettronica ogni volta che il motore di ricerca troverà un nuovo messaggio per te
Il servizio è completamente GRATUITO!
x
Login to ForumsZone
Login with Google
Login with E-Mail & Password