but in C i have **double, wich is pointer pointer to array. Also in link that I gave, there an example for 2D where it is Ptr{Ptr{Float64}}
But anyway, could you give an example for ccall in your case??? пятница, 4 ноября 2016 г., 17:05:57 UTC+3 пользователь Yichao Yu написал: > > On Fri, Nov 4, 2016 at 9:22 AM, Alexander Lyapin > <lyapinaa...@gmail.com <javascript:>> wrote: > > There is a topic: > > https://groups.google.com/d/msg/julia-users/EK9oNzzaoAk/kJqagPL0Ku0J > > > > However could some one give an example how to pass 3-d or 4-d array to C > > function. > > > > I have Array{Float64, 4} and for ccall I use Ptr{Ptr{Ptr{Ptr{Float64}}}} > as > > Type of parameter. Is there some way to make it more common for > > Array{Float64, N}??? Thank you > > No matter what the dimension is,it's always a `Ptr{eltype(array)}` in > C (`Ptr{Float64}` in thiscase) and since it's just a normalpointer, > you always need topass the dimensions explicitlyto C in another > argumetns. >