Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.ruby > #3585
| From | Ville Sipola <ville_sipola@hotmail.com> |
|---|---|
| Newsgroups | comp.lang.ruby |
| Subject | Re: Fast way to move C array to ruby (rb_ary_new4)? |
| Date | 2011-04-27 17:01 -0500 |
| Organization | Service de news de lacave.net |
| Message-ID | <104a6c52e34d44d0b57874ca7d51a4c3@ruby-forum.com> (permalink) |
| References | <7bb00dec91cd520ed45220d7d899f294@ruby-forum.com> <BANLkTimkAt-43cdMX+ZEETjJ-K7X=kSPnw@mail.gmail.com> <BANLkTinmauNPb+vZ8Tv5Fw_OSx=Xc_oT3Q@mail.gmail.com> <BANLkTi=F7J=Fg52aFeSOqtqL1XsS4VuVtg@mail.gmail.com> |
That's a lot of answers in a short time. Thank you all! The kind of hack that Brian Candler mentioned (writing directly to struct RFloat) was one of the ways that I already tried to accomplish, but if it's likely to get broken in future, then I guess it's not a solution to fight for. And for Robert's second answer: yes, I need the whole data back, I'm sending it all to other functions. I guess I'll try them all, starting with the NArray. Now I only have to figure out how to use that. From narray.c I get the impression that they can be read into C by creating a struct NARRAY and then using the command GetNArray, right? But how would you write into it in C? Thank you for the help. Ville -- Posted via http://www.ruby-forum.com/.
Back to comp.lang.ruby | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
Fast way to move C array to ruby (rb_ary_new4)? Ville Sipola <ville_sipola@hotmail.com> - 2011-04-27 05:46 -0500
Re: Fast way to move C array to ruby (rb_ary_new4)? Robert Klemme <shortcutter@googlemail.com> - 2011-04-27 07:08 -0500
Re: Fast way to move C array to ruby (rb_ary_new4)? Robert Klemme <shortcutter@googlemail.com> - 2011-04-27 08:06 -0500
Re: Fast way to move C array to ruby (rb_ary_new4)? Cameron McBride <cameron.mcbride@gmail.com> - 2011-04-27 15:02 -0500
Re: Fast way to move C array to ruby (rb_ary_new4)? Ville Sipola <ville_sipola@hotmail.com> - 2011-04-27 17:01 -0500
Re: Fast way to move C array to ruby (rb_ary_new4)? Ville Sipola <ville_sipola@hotmail.com> - 2011-05-06 14:47 -0500
Re: Fast way to move C array to ruby (rb_ary_new4)? Brian Candler <b.candler@pobox.com> - 2011-04-27 11:15 -0500
csiph-web