C arrays from LUA

View previous topic View next topic Go down

C arrays from LUA

Post  zzajin on Mon Mar 30, 2009 3:51 pm

Is there any way of accessing data from a C array from LUA?

something like:

Cube.obj.vbo_offset[1]

or

Cube.obj._SIO2vertexgroup.get(1)

zzajin

Posts : 81
Join date : 2008-10-14

View user profile

Back to top Go down

Re: C arrays from LUA

Post  sio2interactive on Mon Mar 30, 2009 4:10 pm

For this kind of stuff you need to write your own helpers depending on what you want to do exactly... You can either choose to expand the API in the sio2.module and use the sio2_to_lua command to generate the wrapper.

Or you can create your module & wrapper and plug it to the LUA virtual machine that SIO2 is using.

Either way is really a straightforward approach...

_________________
SIO2 Interactive
Free Open Source 3D Game Engine for iPhone and iPod Touch
http://sio2interactive.com
avatar
sio2interactive

Posts : 1526
Join date : 2008-08-26
Age : 38
Location : Shanghai

View user profile http://sio2interactive.com

Back to top Go down

View previous topic View next topic Back to top

- Similar topics

 
Permissions in this forum:
You cannot reply to topics in this forum