JavaScript ( QScript Qt-5 ) in GUI framework QtE5
Support of JavaScript which is a part of Qt-5 is added to QtE5. The possibility of a call from the JS functions and methods written to D is provided. There is an opportunity to save JS status in case of execution of a series of scripts and from D to read values of any variables in JS. screenshot: https://pp.vk.me/c637429/v637429885/16b14/mSDeRXCZcdI.jpg github https://github.com/MGWL/QtE5
Got a post for the D Blog?
So far, getting content for the blog has, with a few exceptions, been a process of sending out emails prompted by activity on my radar. This is no problem when it comes to project highlights or other fairly broad topics, but it's highly inefficient for ginning up technical posts on the implementation of specific algorithms, or optimization details, or how a D feature prevented a nuclear meltdown. I want to publish more posts like Andreas's 'Find Was Too Damn Slow, So We Fixed It` [1] (which, by the way, is the most-viewed post so far, just ahead of Joakim's interview with Walter [2]), or Steven's 'How to Write @trusted Code in D' [3], but I need help. If you, or someone you know, have done something interesting with an algorithm or optimization in D, or have used a D idiom to do things in a way that pleasantly surprised you, please let me know. If I think it's something we can work with, I'll help you in putting together a guest post, or something like I do with the project highlights (where I build a post around whatever info you give me). Also, I need news. If you see or hear any D news anywhere outside of the forums -- new projects, research papers, usage at a company, a game using D -- please drop me a line. I'll either get a post together for it or make sure Adam knows about it for 'This Week in D'. I'm also open to ideas for other types of posts, like project highlights, but I'd really like more of the technical stuff. Please send any suggestions to aldac...@gmail.com. Thanks! [1] http://dlang.org/blog/2016/06/16/find-was-too-damn-slow-so-we-fixed-it/ [2] http://dlang.org/blog/2016/08/30/ruminations-on-d-an-interview-with-walter-bright/ [3] http://dlang.org/blog/2016/09/28/how-to-write-trusted-code-in-d/
Re: Release D 2.072.0
On 10/30/2016 09:27 PM, Martin Nowak wrote: This is the release ships with the latest version of dub (v1.1.0), Changelog for dub 1.1.0?
Box2D Lite D Port (Yet Another)
hi. i was in need of very simple (yet usable for something more than "hey, this is how Big Players doing physics!") 2d physics engine for some of my pet projects, and i decided to use Box2D Lite as base (mostly 'cause it has simple joints implemented). so i ported it, mutilated it and had it working in less than 40 kb of source code. so far, so good. but suddenly... but suddenly i realised that B2DL can operate only on boxes (no other body shapes were implemented), and it has O(N^2) broad phase. of course, this is perfectly fine for a demo purposes, but little limiting for my projects. so after mutilating the patient, i surgically enhanced it a little[1]. now my port supports the following features: * convex polygonal bodies with different density * SAT collistion detection * hard and soft joints * friction * O(N*logN) broad phase * source size is still ~65 KB this is not a finished physics engine, of course, and you will have to do some more work to make it usable in real apps (like adding contact callbacks, for example), but it can give you something you can start with, still not really hard to follow, but more complete than original Box2D Lite. among other things my port has (almost) standalone implementation of Dynamic AABB Tree, which powers new broad phase. even without further optimizations (like frozen bodies), it allows me to process 1100 bodies in less than 30 milliseconds. don't even try that with O(N^2) broad phase! ;-) even if you aren't interested in physics engine per se, you can rip (and tear ;-) this implementation and use it in your projects. any project that needs some form of fast spatial selection (either 2D or 3D, the implementation supports both) can benefit from using dynamic balanced trees for that. it is based on "real" Box2D AABB Trees, and is fairly efficient (and taken from another project too ;-). it is using malloced pool of nodes internally, so it should be suitable for nogc realtime rendering. you will need my iv.vmath[2] library for vector math. physics library doesn't draw anything on it's own, but the sample does, so it requires my iv.glbinds[3] and simpledisplay from Adam's arsd[4]. the code itself is not the cleanest one, but it is still readable (i hope), and should be easy to follow and modify. good luck and happy hacking! p.s. it looks like Chipmunk library has the same origins (and genesis, at least to some extent ;-). [1] http://repo.or.cz/b2ld.git [2] http://repo.or.cz/iv.d.git/blob_plain/HEAD:/vmath.d [3] http://repo.or.cz/iv.d.git/tree/HEAD:/glbinds [4] https://github.com/adamdruppe/arsd
Release D 2.072.0
Glad to announce D 2.072.0. http://dlang.org/download.html This is the release ships with the latest version of dub (v1.1.0), comes with lots of phobos additions and native TLS on OSX. See the changelog for more details. http://dlang.org/changelog/2.072.0.html -Martin
Re: Battle-plan for CTFE
On Sunday, 30 October 2016 at 21:09:19 UTC, Stefan Koch wrote: On Sunday, 30 October 2016 at 03:07:13 UTC, Stefan Koch wrote: I just made progress on another fundamental feature, function call support. It's does not [fully] work yet, but it shows promise. The following just compiled : int fn(int a) { return a + fn2(2); } int fn2(int a) { return a + 2; } static assert(fn2(4) == 6); static assert(fn(4) == 8); static assert(fn(fn(2)) == 10); Oh shoot! I did not enable the new call system :( This computed by the old interpreter. The new engine fails :(
Re: Battle-plan for CTFE
On Sunday, 30 October 2016 at 03:07:13 UTC, Stefan Koch wrote: I just made progress on another fundamental feature, function call support. It's does not [fully] work yet, but it shows promise. The following just compiled : int fn(int a) { return a + fn2(2); } int fn2(int a) { return a + 2; } static assert(fn2(4) == 6); static assert(fn(4) == 8); static assert(fn(fn(2)) == 10);