Re: [julia-users] Controlling all Julia outputs upto four decimal points display

2016-09-28 Thread Bart Janssens
I have no idea if it's still the correct way, but I add this at the top of most notebooks: Base.show(io::IO, x::Float64) = @printf io "%0.4f" x; On Wed, Sep 28, 2016 at 6:22 PM parthasarathy ganguly < parthasarathygang...@gmail.com> wrote: > I would like to set all my Julia outputs unto 4 deci

[julia-users] Setting/getting field-like members with side effects

2016-10-09 Thread Bart Janssens
Hi all, I'm thinking about how to translate a Python interface that makes extensive use of __getattr__ and __setattr__ overloading to allow chaining a series of option values like this example: mysolver.linear_system.parameters.solver_type = "GMRES" Each time a . is encountered, the appropriate _

Re: [julia-users] Re: Setting/getting field-like members with side effects

2016-10-09 Thread Bart Janssens
OK, thanks, so symbols are definitely preferred for the [] variant then? As for using dispatch, I am certainly all for designing a "proper" Julian interface, but the number of parameters here can be daunting, see e.g. here for a more complete example: https://github.com/barche/coolfluid3/blob/mast

Re: [julia-users] GC rooting for embedding: what is safe and unsafe?

2016-10-14 Thread Bart Janssens
Hi, Replies below, to the best of my understanding of the Julia C interface: On Fri, Oct 14, 2016 at 11:47 AM Gunnar Farnebäck wrote: > Reading through the threads and issues on gc rooting for embedded code, as > well as the code comments above the JL_GC_PUSH* macros in julia.h, I'm > still unc

Re: [julia-users] Embedding Julia in C++ - Determining returned array types

2016-10-15 Thread Bart Janssens
In addition to this, CxxWrap.jl has some additional convenience classes to work with Julia arrays from C++, see https://github.com/JuliaInterop/CxxWrap.jl#working-with-arrays Cheers, Bart On Sat, Oct 15, 2016 at 2:45 AM Isaiah Norton wrote: > On Fri, Oct 14, 2016 at 2:28 PM, Kyle Kotowick wro

Re: [julia-users] automatically moving from cmake 3.6.1 to cmakex.y.z

2016-10-27 Thread Bart Janssens
Normally this is solved by running "cmake ." in the build directory or directories of the library or libraries compiled using cmake. Cheers, Bart On Thu, Oct 27, 2016 at 9:28 AM Federico Calboli wrote: > Hi, toady on a whim I tried > > make cleanall && make testall > > but it did not work beca

Re: [julia-users] automatically moving from cmake 3.6.1 to cmakex.y.z

2016-10-27 Thread Bart Janssens
On Thu, Oct 27, 2016 at 3:24 PM Isaiah Norton wrote: > > I'm not sure if there's any good way to introspect this and trigger a > reconfigure from Julia's build system without adding a lot of complexity. > Or even better: let's remove a lot of complexity and move the whole Julia build system to C

Re: [julia-users] Simulink alternative, based on Julia?

2016-11-04 Thread Bart Janssens
Hi Uwe, My colleague Ben and I would also like to see something like this. I've started implementing models for use with QML views in QML.jl. Once this is finished, I think it should be possible to show the Julia model of the nodes in a Repeater QML view and draw the connections (also supplied by

Re: [julia-users] Re: [Announcement] Moving to Discourse

2016-11-21 Thread Bart Janssens
I think this is because it loads the mobile version of the site. Often, mobile sites can't be zoomed in on. There should be an option in the browser to request the desktop version. Alternatively, I think you can also set the font size globally from the system settings. Also, I thought the list was

[julia-users] Boost.Python-like CppWrapper package

2015-11-12 Thread Bart Janssens
Hello, I've recently started using Julia, thanks to the great intro at the Julia meetup in Gent two months ago. To really start using it for my work, I would need to access some C++ software, most notably Trilinos and our own CFD code. We currently use Boost.Python to interface with Python, so

[julia-users] Re: Boost.Python-like CppWrapper package

2015-11-13 Thread Bart Janssens
Hi Steven, Yes, that's exactly right. I'd just like to add that the specific use case that I have in mind are C++ projects that already invested in a Python interface using Boost.Python. The aim is to make it easy to add a Julia interface with little effort. This is not intended to compete with

[julia-users] Re: Boost.Python-like CppWrapper package

2015-11-14 Thread Bart Janssens
Hi Eric, The Boost C++ library covers a lot more ground than just the Python wrappers. It could be Boost.Julia if the C++ part were part of Boost, but it's not my ambition to attempt to get this into Boost. That said, there may be better names than CppWrapper, so I'm open to suggestions for new

[julia-users] Re: Funny object wrapper in Julia

2015-12-07 Thread Bart Janssens
Hi Olli, I'm considering an approach like this for wrapping C++ class member functions in my CppWrapper package. I just wonder, is this kind of object.member_function(arguments) syntax acceptable for Julia, or is member_function(object, other_arguments) preferred? The former will be more natur

Re: [julia-users] Re: Lack of an explicit return in Julia, heartache or happiness?

2016-05-26 Thread Bart Janssens
In C++ I had quite a few nasty bugs where it turned out that I forgot the return statement, and the function then just returns garbage (if declared as non-void, so I think this can't happen in Julia since you don't declare the return type). At least what is returned in Julia is now clearly defi

Re: [julia-users] Signal / slot (or publish-subscribe) libraries in Julia

2016-06-02 Thread Bart Janssens
Hello, I would also be interested to know how and if this kind of functionality relates to Reactive.jl. Looking at the docs for Reactive, it seems it was designed for "continuous" signals. In Reactive, sampling seems to be needed, while in a classical signal/slot implementation (such as in Qt)

[julia-users] New constructor syntax in 0.5

2016-06-29 Thread Bart Janssens
Hi all, I'm having some trouble adapting CxxWrap to the new constructor syntax (as opposed to adding call(::Type{...) methods in 0.4). The error is equivalent to the following pure Julia example: type MT{T} msg::String end julia> MT{Float64}() = MT{Float64}("float") WARNING: static parame

Re: [julia-users] New constructor syntax in 0.5

2016-06-30 Thread Bart Janssens
s stay): > > call{T,Y}(::Type{A{I,T}}, t::T, y::Y) = ... > (::Type{A{I,T}}){T,Y}(t::T, y::Y) = ... > > On Wed, 2016-06-29 at 23:59, Yichao Yu wrote: > > On Wed, Jun 29, 2016 at 5:46 PM, Bart Janssens > wrote: > >> > >> Hi all, > >> > >> I'm h

Re: [julia-users] Julia ccall windows

2016-07-09 Thread Bart Janssens
Hi Karli, With CxxWrap.jl you can write a small C++ wrapper in VisualStudio that can then easily be used from Julia to access your C++ functions. See https://github.com/barche/CxxWrap.jl It does require at least Visual Studio 2015 update 2 (I tested with the community edition). Cheers, Bart On

Re: [julia-users] Re: Julia ccall windows

2016-07-11 Thread Bart Janssens
That looks very much like a plain C API, so I guess you'll get by with ccall. What to pass as socket depends on the type, but presumably you can pass a pointer to some integer type. Supposing SOCKET is a 32bit integer, something like this might work: fd = Array{Int32}(1) ccall((:MServerInit, your_l

Re: [julia-users] Re: Julia ccall windows

2016-07-12 Thread Bart Janssens
,16,32,64). nothing helps. Don't know if its > Julia problem or what. > > > tiistai 12. heinäkuuta 2016 0.31.46 UTC+3 Bart Janssens kirjoitti: > >> That looks very much like a plain C API, so I guess you'll get by with >> ccall. What to pass as socket depends on the typ

Re: [julia-users] Re: Julia ccall windows

2016-07-12 Thread Bart Janssens
with >>> output. But its wrong output. It should be 128, but in Julia set it 552. I >>> try different variables (8,16,32,64). nothing helps. Don't know if its >>> Julia problem or what. >>> >>> >>> tiistai 12. heinäkuuta 2016 0.31.46 UTC+3

Re: [julia-users] Re: Julia ccall windows

2016-07-13 Thread Bart Janssens
try to google Libc.WindowsRawSocke Julia, but > nothing. How I can use that library? > > keskiviikko 13. heinäkuuta 2016 0.05.23 UTC+3 Bart Janssens kirjoitti: > >> OK, if it's a normal Windows socket you may be able to use >> Libc.WindowsRawSocket instead of an integer type. It seems to

[julia-users] Threading in 0.5

2016-07-17 Thread Bart Janssens
Hi all, I'd like to experiment a bit with 0.5 threading for QML.jl, by trying to call a Julia function from within the QML rendering thread, which is created by Qt. Ultimately, I'm calling a Julia function from within C++. Is there any documentation yet on how to do this? In the code, I see some u

Re: [julia-users] Threading in 0.5

2016-07-18 Thread Bart Janssens
Op ma 18 jul. 2016 00:10 schreef Yichao Yu : > On Sun, Jul 17, 2016 at 6:07 PM, Bart Janssens > wrote: > > Hi all, > > > > I'd like to experiment a bit with 0.5 threading for QML.jl, by trying to > > call a Julia function from within the QML rendering thread,

[julia-users] Creating tuples from C/C++

2016-08-02 Thread Bart Janssens
Hi all, Looking through the Julia code, the following approach seems to work for creating a tuple from C++ (pseudocode): jl_value_t* make_tuple(...) { jl_datatype_t* tuple_type = nullptr; jl_svec_t* params = nullptr; jl_value_t* result = nullptr; JL_GC_PUSH3(&tuple_type, ¶ms, &result);

Re: [julia-users] Creating tuples from C/C++

2016-08-02 Thread Bart Janssens
On Tue, Aug 2, 2016 at 12:43 PM Yichao Yu wrote: > > Arguments needs to be rooted if you are doing it this way. > You can also just create an uninitialized box and populated the fields > like a normal struct. > OK, thanks, I used that method now, indeed I forgot to root the arguments, thanks!

Re: [julia-users] Creating tuples from C/C++

2016-08-03 Thread Bart Janssens
On Wed, Aug 3, 2016 at 12:33 AM Yichao Yu wrote: > On Wed, Aug 3, 2016 at 6:03 AM, Bart Janssens > wrote: > >> I'm just trying to understand how C structs like jl_value_t interact >> with the LLVM compiler. >> > > I'm not really sure what's th

Re: [julia-users] new installation of julia

2016-08-07 Thread Bart Janssens
Hi, I think you need to do: git checkout v0.4.6 You can also list the tags with git tag. Cheers, Bart On Sun, Aug 7, 2016 at 10:55 AM digxx wrote: > So, now I freshly compiled julia again from the source after I specified: > git checkout release-0.4 but then inside Julia I get by typing > ve

Re: [julia-users] How do I write `import Base.!` in julia 0.5?

2016-08-09 Thread Bart Janssens
On Tue, Aug 9, 2016 at 7:21 AM Kevin Squire wrote: > Generally it's not a different syntax, and the error generated here is > probably a consequence of recent parser changes to handle dot-operator > overloading (and should probably be reported as a bug, and possibly fixed.) > You mean fused broa

Re: [julia-users] Replacement for jl_gc_preserve() and jl_gc_unpreserve()?

2016-08-10 Thread Bart Janssens
On Wed, Aug 10, 2016 at 9:11 AM Yichao Yu wrote: > On Wed, Aug 10, 2016 at 2:17 PM, Kit Adams wrote: > >> I am investigating the feasibility of embedding Julia in a C++ real-time >> signal processing framework, using Julia-0.4.6 (BTW, the performance is >> looking amazing). >> >> However, for th

Re: [julia-users] Replacement for jl_gc_preserve() and jl_gc_unpreserve()?

2016-08-10 Thread Bart Janssens
On Wed, Aug 10, 2016 at 11:46 AM Kit Adams wrote: > Thank you for those links, they are a great help. > > Is there an "unprotect_from_gc(T* val)"? > > I am looking for a smart pointer a bit like v8's UniquePersistent<>. > > I guess I could make one that searched through the array for the value in

Re: [julia-users] Wrapping an array from C

2016-08-17 Thread Bart Janssens
On Tue, Aug 16, 2016 at 10:29 PM Kiran Pamnany > If I use a composite type, Bar, instead of a bits type, then I get back an > array of Bar, but each element is #undef. The memory for the elements of > the array is present (sizeof(Bar) was used to allocate the space), but the > array isn't set up c

Re: [julia-users] Re: How to set JULIA_NUM_THREADS for remote workers?

2016-08-17 Thread Bart Janssens
On Wed, Aug 17, 2016 at 12:53 PM Oliver Schulz wrote: > Sure, but *how* do I preset JULIA_NUM_THREADS in the environment of the > workers? It'll still be application dependent, so it can be in a .profile > or so (which probably won't be run anyway for the worker processes). > > > Hi Oliver, If t

Re: [julia-users] Broken PyPlot... need to revert to a previous version asap.

2016-08-18 Thread Bart Janssens
On Thu, Aug 18, 2016 at 10:47 AM Ferran Mazzanti wrote: > Dear all, > > looks like lots of messing around with versions had rendered PyPlot > unusable in 0.4.6 under OSX (at least). > Now I need to do some work that requires its use so I need to have it up > and working. Could anybody please let

Re: [julia-users] Re: Embedding julia in VC++ app - crash in jl_init()

2016-08-31 Thread Bart Janssens
Inspired by your question, I have posted an "embedding Julia" CMake project here: https://github.com/barche/embedding-julia It should allow easy compilation of the embedding.c example on Windows VC++, OS X and Linux. Cheers, Bart On Wed, Aug 3, 2016 at 4:46 AM Kit Adams wrote: > Many thanks f

Re: [julia-users] Is it better to call Julia from C++ or call C++ from Julia?

2016-09-03 Thread Bart Janssens
Hi, I'd say the better option in terms of performance depends on which path allows you to limit the number of calls into the other language, since there will often be some overhead in calling Julia from C++ or vice versa, even if it's just because things are less transparent to the compiler. When

Re: [julia-users] Re: Unitful.jl for physical units

2016-09-06 Thread Bart Janssens
Hi Andrew, Unitful.jl is awesome, many thanks for this work, I intend to use it for all my classroom notebooks. I especially like the fact that it supports units with offsets, like the different temperature scales, and the fact that it keeps derived units like J displayed as such in the output. T

Re: [julia-users] Re: Is it better to call Julia from C++ or call C++ from Julia?

2016-09-06 Thread Bart Janssens
On Tue, Sep 6, 2016 at 5:25 PM Páll Haraldsson wrote: > > As far as I understand: > > https://github.com/barche/CxxWrap.jl > > should also be [as, not faster or slower] fast. Meaning runtime speed (of > not development speed). > CxxWrap.jl actually has a slightly higher overhead: many calls are

Re: [julia-users] Further on calling C++ from Julia or vice versa

2016-09-07 Thread Bart Janssens
On Wed, Sep 7, 2016 at 3:15 PM K leo wrote: > So my question is how Cxx or CxxWrap can help me with these virtual > functions? Can I overload them in Julia? > Based on your description, I think the workflow for CxxWrap would be as follows: 1. Write and wrap a top-level function that starts up t

Re: [julia-users] ran into problem compiling C embedded with julia using mingw-w64 gcc on windows

2016-09-07 Thread Bart Janssens
On Tue, Sep 6, 2016 at 4:41 PM simon rss wrote: > > > Every thing seems to be OK, it successfully generated a test.exe > > But when I run this test.exe, windows pop up a window says " test.exe > stopped working" and I got nothing. > > What is wrong? How to correctly compile C embedded with julia

Re: [julia-users] How to use jl_call1 with a struct argument?

2016-09-09 Thread Bart Janssens
On Fri, Sep 9, 2016 at 6:44 PM Isaiah Norton wrote: >// construct a TestType instance > > jl_value_t* jl_A = > jl_new_struct((jl_datatype_t*)jl_get_function((jl_module_t*)mod, > "TestType"), > jl_box_float64(A.a), > jl_box_float64(A.b)); > > The argume

Re: [julia-users] How to use jl_call1 with a struct argument?

2016-09-10 Thread Bart Janssens
I just realise I made a typo, the rooting should be done using: (note the &) JL_GC_PUSH2(&a,&b); Op za 10 sep. 2016 02:36 schreef K leo : > Bart, > > Can you explain what you mean by "need to be rooted"? The jl_new_struct > statement as Isaiah suggested works, why do we need the additional > s

Re: [julia-users] How to use jl_call1 with a struct argument?

2016-09-10 Thread Bart Janssens
The concrete error you got is probably due to the missing -DJULIA_ENABLE_THREADING. Op za 10 sep. 2016 14:53 schreef K leo : > julia-config.jl is hardly useful at all. I unpacked the Linux binary of > Julia (0.5) in ~/Software/julia-9c76c3e89a, and I set JULIA_DIR > accordingly. When I execute

Re: [julia-users] How to use jl_call1 with a struct argument?

2016-09-11 Thread Bart Janssens
On Sun, Sep 11, 2016 at 2:47 AM K leo wrote: > Hi Bart, > > These are meant to call Julia code from C++. You mentioned "there may be > easier ways using Cxx.jl or CxxWrap.jl". Are the two packages only for > calling C/C++ from Julia, and not the otherway around? Am I missing > something? > > Y

Re: [julia-users] Re: There is very little overhead calling Julia from C++

2016-09-11 Thread Bart Janssens
On Fri, Sep 9, 2016 at 1:40 AM Steven G. Johnson wrote: > Except that in your example code, you aren't calling the Julia code > through a raw C function pointer. You are calling it through jl_call0, > which *does* have a fair amount of overhead (which you aren't seeing > because the function ex

Re: [julia-users] Re: There is very little overhead calling Julia from C++

2016-09-11 Thread Bart Janssens
ing jl_call from C++ is about > 25 times slower than using ccall from Julia? > > On Monday, September 12, 2016 at 5:33:02 AM UTC+8, Bart Janssens wrote: > >> On Fri, Sep 9, 2016 at 1:40 AM Steven G. Johnson >> wrote: >> >>> Except that in your example code, you

Re: [julia-users] code design question – best ideomatic way to define nested types?

2016-09-12 Thread Bart Janssens
Looking at this example, it seems mighty tempting to have the ability to subtype a concrete type. Are the exact problems with that documented somewhere? I am aware of the following section in the docs: "One particularly distinctive feature of Julia’s type system is that concrete types may not subt

Re: [julia-users] code design question – best ideomatic way to define nested types?

2016-09-15 Thread Bart Janssens
Thanks for the replies, very informative. I like the FooData solution best, it separates "code reuse through composition" from "shared interface through inheritance", which is what is recommended in the thoughtworks link Chris posted. On Mon, Sep 12, 2016 at 11:44 PM Stefan Karpinski wrote: > Th

Re: [julia-users] code design question – best ideomatic way to define nested types?

2016-09-15 Thread Bart Janssens
On Fri, Sep 16, 2016 at 1:54 AM 'Greg Plowman' via julia-users < julia-users@googlegroups.com> wrote: > Bart, > Which one is the FooData solution? > Is this Example 1,2 or 3? Or another solution. > > It's the one posted by Michael later. In the terminology of https://www.thoughtworks.com/insights

Re: [julia-users] v0.5 deprecates :call. so how do you :call now?

2016-09-19 Thread Bart Janssens
In 0.5-rc4 your code runs without any warnings. I think only the call function was deprecated, not the :call symbol in an expression tree: dump(:(f(3))) yields: Expr head: Symbol call args: Array{Any}((2,)) 1: Symbol f 2: Int64 3 typ: Any Cheers, Bart On Mon, Sep 19, 2016 at 9:32 A

Re: [julia-users] v0.5 deprecates :call. so how do you :call now?

2016-09-19 Thread Bart Janssens
On Mon, Sep 19, 2016 at 10:11 AM Florian Oswald wrote: > > So I read somewhere that my construction involving `eval` is bad practice. > can anyone give me some guidance as to what is the proper julian way of > expressing this: > > eval(Expr(:call,f,3))? > > Just calling the function: f(3) ?

[julia-users] Re: Finding all the arguments of a function

2016-01-29 Thread Bart Janssens
On Friday, January 29, 2016 at 12:26:20 PM UTC+1, Antoine Messager wrote: > I forgot for the n-th time how to prevent a sampling from having two times > the same value. While I wrote the previous sentence I remembered, but it is > not my issue. I was wondering whether there is an option that w

[julia-users] Abusing parametric types with pointers for overloading setfield!

2016-02-03 Thread Bart Janssens
Hi, Before getting to the main topic, let me give some context to avoid the XY problem: I am trying to implement a package for wrapping C++ classes, and now hit the stage where I want to do, on the Julia side: wrapped_cpp_object.somefield = newvalue In doing so, appropriate methods should be

[julia-users] Re: Understanding immutables

2016-02-07 Thread Bart Janssens
On Sunday, February 7, 2016 at 3:39:51 PM UTC+1, Cedric St-Jean wrote: > then `a` is stack-allocated. The foo(a) call may either copy `a` further, > or just pass on a stack pointer to the existing `a`, depending on compiler > details. Any stack-allocated object gets automatically wiped as the s

[julia-users] ANN: CppWrapper C++ wrapping package

2016-02-14 Thread Bart Janssens
Hi all, The CppWrapper package is meant to facilitate exposing C++ libraries to Julia, allowing library authors to write the wrapping code in C++ and import to Julia using a one-liner. I think I have now added most of the basic features needed to produce simple type wrappings. The detailed des

[julia-users] Re: Investigating instances of parametric types

2016-02-15 Thread Bart Janssens
There is the parameters field of the types, but I'm not sure if that's considered private. You can do Array{Float64, 1}.parameters[2] to get 1, for example. On Monday, February 15, 2016 at 2:14:35 PM UTC+1, jw3126 wrote: > > I have an instance of a parametric type, is there a canonical way to get

[julia-users] Re: ANN: CppWrapper C++ wrapping package

2016-02-15 Thread Bart Janssens
Hi Andreas, Yes, I'm aware of (and impressed by :) Cxx.jl. The reason I went ahead with CppWrapper anyway is that I wanted something like Boost.Python does for Python: allow writing the interface completely in C++. If I understand Cxx.jl correctly, the idea is that it becomes possible to direc

[julia-users] Re: ANN: CppWrapper C++ wrapping package

2016-02-16 Thread Bart Janssens
Hi Christoph, It should, yes. I have tested on stock Julia 0.4 on OS X and Linux. The only requirement is to have cmake (at least v3.1) in your path when running Pkg.build. Bart On Tuesday, February 16, 2016 at 12:57:53 PM UTC+1, Christoph Ortner wrote: > > Does this work *now* without special

Re: [julia-users] Weird Hygiene Issue

2016-02-17 Thread Bart Janssens
Hi Julia, Not sure if this helps, but wrapping the g definition in X.eval like this: module Y using X X.eval(:(g(x) = 2x)) f(4) end seems to make your sample work. On Wednesday, February 17, 2016 at 9:19:55 PM UTC+1, Julia Tylors wrote: > > julia> module X >export f >

[julia-users] Re: JuliaCon 2016: Program Committee Office Hours on the 5th of March at 15:00 UTC

2016-03-03 Thread Bart Janssens
Hi, Should we already fill in the proposal form for JuliaCon before this session, to improve upon it later, or is it better to just submit after? Cheers, Bart On Wednesday, March 2, 2016 at 11:55:22 PM UTC+1, Pontus Stenetorp wrote: > > Everyone, > > With the JuliaCon 2016 proposal deadline a

[julia-users] Re: QML (Qt5) binding for Julia (GSOC?)

2016-03-15 Thread Bart Janssens
I just couldn't resist taking a stab at this using CppWrapper. At https://github.com/barche/QML.jl there is a small example on how to launch a QML file from Julia (tested in v0.4). To make this useful, we would need to add some kind of interface to the "embedding julia" interface, to allow bind

[julia-users] Re: QML (Qt5) binding for Julia (GSOC?)

2016-03-18 Thread Bart Janssens
This could be either a missing Qt package, or the version is not recent enough. I don't use any recent QML commands, so it's safe to use QtQuick 2.0 and Controls and Layouts version 1.0. I have updated the main.qml in the repo. If you pass just QString("main.qml") as argument to QQmlApplication

[julia-users] Re: QML (Qt5) binding for Julia (GSOC?)

2016-03-19 Thread Bart Janssens
Awesome, reassuring to know it works elsewhere too :) In the mean time, I updated the test with a simple Julia callback to increase a counter on the Julia side at the click of a QML button. The interface is limited to 0-argument functions returning integers or doubles for now. The heart of the

[julia-users] Registering / renaming CppWrapper

2016-03-19 Thread Bart Janssens
Hi, I'd like to register the CppWrapper package: https://github.com/barche/CppWrapper At the very least, I'll have to rename the github repo to CppWrapper.jl, but while I'm at it I'd like to ask if there are any suggestions for a better name? The package is meant to "wrap" a C++ library in a se

[julia-users] Re: QML (Qt5) binding for Julia (GSOC?)

2016-03-19 Thread Bart Janssens
Hi, I think this is because the dynamic linker can't find your Qt libs. I have pushed a fix that should add the correct library to the rpath. After pulling the change, you may need to delete .julia/v0.4/QML/deps/usr and .julia/v0.4/QML/deps/builds for Pkg.build to detect the change. If it stil

Re: [julia-users] Registering / renaming CppWrapper

2016-03-21 Thread Bart Janssens
I like the sound of CxxWrap.jl. I was reluctant to use Cxx, to avoid giving the impression there is a dependency on Cxx.jl, but in the future I may actually use Cxx.jl to replace the current ccall usage, so then that is no longer an objection. I'll give it a few more days and then proceed with

Re: [julia-users] Registering / renaming CppWrapper

2016-03-25 Thread Bart Janssens
Thanks for the feedback, I'll probably do the rename to CxxWrap.jl tomorrow, so the ship is just about to sail ;) On Friday, March 25, 2016 at 1:18:41 PM UTC+1, Stefan Karpinski wrote: > > The ship may have sailed on giving feedback on this name too ;-) > > Personally, I just think "cxx" is coole

[julia-users] Re: Understanding QML.jl

2016-03-25 Thread Bart Janssens
Hi Uwe, See below for inline answers. As a general note, I mostly started the QML module as a proof-of-concept and a real-world test for CppWraper (soon CxxWrap.jl). I'm having a lot of fun with it at the moment, but I can't promise I'll be able to turn this into a feature-complete GUI toolkit.

Re: [julia-users] Re: raytracing in julia

2016-04-01 Thread Bart Janssens
Sorry for the shameless plug for my own package, but maybe CxxWrap.jl could help here: https://github.com/barche/CxxWrap.jl It was recently registered and works on Julia 0.4 and 0.5. If it seems like an option for you, I could help you get started to write the wrapper. Regards, Bart On Friday

[julia-users] Re: Interfacing C++ function which takes structure and arrays

2016-04-06 Thread Bart Janssens
Hi, The problem is that the float* type was not mapped yet by CxxWrap. I have just added it, so your example should work after you Pkg.checkout("CxxWrap") and rebuild. Before rebuilding you may need to remove the usr dir in .julia/v0.4/CxxWrap/deps. Also, you need to pass a Float32 array to He

[julia-users] build.jl help

2016-04-16 Thread Bart Janssens
Hi, I use CMake to build code from the deps directory using BinDeps. An issue with this is that when the C++ code is changed, the package is not rebuilt because the existence of the library is still detected. Is there an elegant way to force a make each time Pkg.build is called? The only way I

[julia-users] Re: what is the best way to create a Julia package which depends on a number of dynamic libraries?

2016-04-21 Thread Bart Janssens
Hi Igor, I'm not claiming it's the correct way, but for QML.jl I'm using CMake inside a BinDeps build script. On Windows, this works with the standard Visual Studio Qt packages. It requires the very latest Visual Studio release candidate (I use the free community edition) and CMake in the path.

[julia-users] Re: what is the best way to create a Julia package which depends on a number of dynamic libraries?

2016-04-22 Thread Bart Janssens
As Tony pointed out to me, modifying PATH is not allowed. If you call Libdl.dlopen on the DLLs that need to be loaded in the package init function, they will be visible and don't need to be in the path. Cheers, Bart On Friday, April 22, 2016 at 10:07:06 AM UTC+2, Igor wrote: > > Bart, Tom, Ton

[julia-users] [ANN] QML.jl progress

2016-04-25 Thread Bart Janssens
Hi all, I just wanted to report on some progress for QML.jl at https://github.com/barche/QML.jl : - Communication mechanisms with Julia for basic types (signals, function calls and context properties) - Display for PNG mime type (see plot.jl example using Plots.jl and the image test) - Integrat

[julia-users] Re: changing the package name

2016-04-26 Thread Bart Janssens
You could first uninstall the package, then rename on Github and then clone from the new address. Cheers, Bart On Tuesday, April 26, 2016 at 6:17:10 PM UTC+2, Chang Kwon wrote: > > I was wondering what is the proper way to change the package name under > development. This is often the case whe

[julia-users] GLVisualize in existing OpenGL context

2016-04-28 Thread Bart Janssens
Hi, For QML.jl, I have created an experimental OpenGL QML type that can be used as rendering target for GLAbstraction.jl by simply skipping the GLFW commands and drawing directly to the Qt-provided context (code: https://github.com/barche/QML.jl/blob/master/example/gltriangle.jl). I attempted