We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
I have an array of this struct (sd_image_t*) as the return value of a function:
sd_image_t*
typedef struct { uint32_t width; uint32_t height; uint32_t channel; uint8_t* data; } sd_image_t;
In C++ I can call sd_image_t[n].data while with SWIG created Lua bindings I can only call sd_image_t.data (which seems to be a pointer to all data of the struct). Is there a way to wrap it, so that I can call it like in C++? Could %naturalvar help in my case? https://www.swig.org/Doc1.3/SWIGPlus.html#SWIGPlus_member_data Here I tried to describe my issue too: https://forum.openframeworks.cc/t/swig-lua-binding-for-accessing-elements-of-an-image-array/43429
sd_image_t[n].data
sd_image_t.data
%naturalvar
The text was updated successfully, but these errors were encountered:
No branches or pull requests
I have an array of this struct (
sd_image_t*
) as the return value of a function:In C++ I can call
sd_image_t[n].data
while with SWIG created Lua bindings I can only callsd_image_t.data
(which seems to be a pointer to all data of the struct). Is there a way to wrap it, so that I can call it like in C++?Could
%naturalvar
help in my case? https://www.swig.org/Doc1.3/SWIGPlus.html#SWIGPlus_member_dataHere I tried to describe my issue too: https://forum.openframeworks.cc/t/swig-lua-binding-for-accessing-elements-of-an-image-array/43429
The text was updated successfully, but these errors were encountered: