Skip to content

add workaround #17

Merged
merged 2 commits into from Oct 13, 2013

2 participants

@p0nce
p0nce commented Oct 13, 2013

Yesterday a gl3n user on IRC found a DMD regression:
http://d.puremagic.com/issues/show_bug.cgi?id=11238

It affected Matrix.invert(); (wrong results), starting from DMD 2.063.

A simple program to expose the bug:

import std.stdio;
import gl3n.linalg;

void main()
{
    mat4 M = mat4(2, 0, 0, 0, 
                  0, 1, 0, 0,
                  0, 0, 1, 0,
                  0, 0, 0, 1);

    writefln("M = %s", M);
    M.invert();
    writefln("M = %s", M);
    M.invert();
    writefln("M = %s", M);
}

This pull request is one way to workaround it.
(damn, a newline in the diff)

p0nce added some commits Oct 13, 2013
@p0nce p0nce add workaround b7fd580
@p0nce p0nce Fix quanternion unittest for x64.
Problem was both with reduced precision and not testing for values near zero.
70b5e14
@Dav1dde Dav1dde merged commit 9095b9a into Dav1dde:master Oct 13, 2013
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.