JOODE: trying to understand t_larkworthy's convex-hull code

Jeah - I’ve not much to do currently… (If you know something we need more urgently than this convex-hull code - I could also do that)

I’m currently trying to understand Tom’s code. 4 eyes mostly find the error more easily…

I’m wondering about what I found here in the constructor of Plane:

	public Plane(float a, float b, float c, float d) {
		float total = (float) Math.sqrt(a*a+b*b+c*c);
		this.a = a/total;
		this.b = b/total;
		this.c = c/total;
		this.d = d/total;
		
		float dividor = (float) Math.sqrt(a*a+b*b+c*c);
		
		nx = a / dividor; //turns out I was trying to do exactly the same thing
		ny = b / dividor;
		nz = c / dividor;
		p = d / dividor;	
		
	}

divider = total
nx = this.a
ny = this.b
nz = this.c
p = this.d

why compute everything twice? (Ok doesn’t seem to be very problematic, but it’s bugging me none the less)

  • from my first impression it looks well commented :smiley:

haha! don’t read that code!

That plane class has been a massive pain in the **** I started off with one representation, then realised I needed a different one. Then it all converged…

I don’t think I have checked in the latest version of the code for the convex stuff, so you probably don’t want to mess around with it too much.

If you want somthing to do then I think getting the joints powered and limited is pretty important. (oh and when I say powered I don’t mean angular motors, I mean being able to set a desired length etc. the LCP solver has all the functionality implemented, it just needs the code adding in the Joint classes)

I just saw that in the current head of ODE cvs is an implementation of convex geometry and collision as well. Does anybody know, if t_larkworthy is porting this code or if is is trying to do another implementation?

Hello. I am doing a new implementation. Based on the DEEP algorithm. Though there are a few problems with that algorithm I did not expect…
I wil get it done as soon as I get this heap of work off my desk…