Thanks for the suggestions! I think then I will stay with
a wrapping struct. How would I make the extern C functions
invisible for other sources?
extern (C) c_ulong loadFont(char * path);
extern (C) void render(c_ulong font, char * text);
extern (C) void destroyFont(c_ulong font);
struct Font
Oh, thanks for all of your help. Nice
to see, that D guys do really help. :)
Using a double4 could improve the performance of your code, but
it must be used wisely. (One general tip is to avoid mixing
SIMD
and serial code. if you want to use SIMD code, then it's often
better to keep using SIMD registers even if you have one
value).
I sadly could not get it to work
I am programming a new GUI widget library based on OpenGL for D.
For that I manually bind the used OpenGL functions to D and create
an abstraction layer to draw things, boxes, texts, shapes, etc.
http://palaes.rudanium.org/HueApp/intro.php
The thing compiles nicely with SDL, FreeType, FTGL. But
Thanks! I already do tracing the samples parallel.
Strangly I have a core 2 duo and it seems that using
3 threads is the best (slightly better than 2). Aldough
this might be accidetal. Maybe the more-complex
samples are more equally in separate threds.
@Jacob Carlborg
I would say use structs. For compiler I would go with LDC or
GDC. Both of these are faster for floating point calculations
than DMD. You can always benchmark.
Thank you for the advice!
I installed ldc and used ldmd2.
Te benchmarks are amazing! :O
DMD compile = 2503 run =
-platform. What optimizations can I assume for various
compilers? Are only once used local variables inlined? So it
secure to extract local variables only to make the code more easy
to understand?
Thanks is Advance!
Róbert László Páli