[wxruby-users] render natively
Alex Fenton
alex at pressure.to
Tue Sep 9 05:40:34 EDT 2008
Jim flip wrote:
> Thanks for the pointers, I think I will try using a bitmap and it's
> set_data method as this should be simple to try out but may be a bit
> slow.
>
If you can avoid composing or decomposing the image data in Ruby (using
pack etc) this will be pretty fast - for example, if you can get your
extension to emit image data in that format. Then it's just a C-level
memcpy going on.
Similarly Image.read should be fast if you can get your extension to
produce a known image format. These wxRuby methods are not particularly
far off the native C library functions in libtiff, libpng etc
alex
More information about the wxruby-users
mailing list