danaugrs пре 7 година
родитељ
комит
c95c1e9d96

+ 0 - 1
physics/constraint/conetwist.go

@@ -2,7 +2,6 @@
 // Use of this source code is governed by a BSD-style
 // Use of this source code is governed by a BSD-style
 // license that can be found in the LICENSE file.
 // license that can be found in the LICENSE file.
 
 
-// Package physics implements a basic physics engine.
 package constraint
 package constraint
 
 
 import (
 import (

+ 1 - 1
physics/constraint/constraint.go

@@ -2,7 +2,7 @@
 // Use of this source code is governed by a BSD-style
 // Use of this source code is governed by a BSD-style
 // license that can be found in the LICENSE file.
 // license that can be found in the LICENSE file.
 
 
-// Package physics implements a basic physics engine.
+// Package constraint implements physics constraints.
 package constraint
 package constraint
 
 
 import (
 import (

+ 0 - 1
physics/constraint/distance.go

@@ -2,7 +2,6 @@
 // Use of this source code is governed by a BSD-style
 // Use of this source code is governed by a BSD-style
 // license that can be found in the LICENSE file.
 // license that can be found in the LICENSE file.
 
 
-// Package physics implements a basic physics engine.
 package constraint
 package constraint
 
 
 import (
 import (

+ 0 - 1
physics/constraint/hinge.go

@@ -2,7 +2,6 @@
 // Use of this source code is governed by a BSD-style
 // Use of this source code is governed by a BSD-style
 // license that can be found in the LICENSE file.
 // license that can be found in the LICENSE file.
 
 
-// Package physics implements a basic physics engine.
 package constraint
 package constraint
 
 
 import (
 import (

+ 0 - 1
physics/constraint/lock.go

@@ -2,7 +2,6 @@
 // Use of this source code is governed by a BSD-style
 // Use of this source code is governed by a BSD-style
 // license that can be found in the LICENSE file.
 // license that can be found in the LICENSE file.
 
 
-// Package physics implements a basic physics engine.
 package constraint
 package constraint
 
 
 import (
 import (

+ 0 - 1
physics/constraint/pointtopoint.go

@@ -2,7 +2,6 @@
 // Use of this source code is governed by a BSD-style
 // Use of this source code is governed by a BSD-style
 // license that can be found in the LICENSE file.
 // license that can be found in the LICENSE file.
 
 
-// Package physics implements a basic physics engine.
 package constraint
 package constraint
 
 
 import (
 import (

+ 0 - 1
physics/equation/cone.go

@@ -2,7 +2,6 @@
 // Use of this source code is governed by a BSD-style
 // Use of this source code is governed by a BSD-style
 // license that can be found in the LICENSE file.
 // license that can be found in the LICENSE file.
 
 
-// Package physics implements a basic physics engine.
 package equation
 package equation
 
 
 import (
 import (

+ 0 - 1
physics/equation/contact.go

@@ -2,7 +2,6 @@
 // Use of this source code is governed by a BSD-style
 // Use of this source code is governed by a BSD-style
 // license that can be found in the LICENSE file.
 // license that can be found in the LICENSE file.
 
 
-// Package physics implements a basic physics engine.
 package equation
 package equation
 
 
 import (
 import (

+ 6 - 7
physics/equation/equation.go

@@ -2,27 +2,26 @@
 // Use of this source code is governed by a BSD-style
 // Use of this source code is governed by a BSD-style
 // license that can be found in the LICENSE file.
 // license that can be found in the LICENSE file.
 
 
-// Package physics implements a basic physics engine.
+// Package equation implements SPOOK equations based on
+// the 2007 PhD thesis of Claude Lacoursière titled
+// "Ghosts and Machines: Regularized Variational Methods for
+// Interactive Simulations of Multibodies with Dry Frictional Contacts"
 package equation
 package equation
 
 
 import (
 import (
 	"github.com/g3n/engine/math32"
 	"github.com/g3n/engine/math32"
 )
 )
 
 
+// IBody is the interface of all body types.
 type IBody interface {
 type IBody interface {
+	Index() int
 	Position() math32.Vector3
 	Position() math32.Vector3
 	Velocity() math32.Vector3
 	Velocity() math32.Vector3
-	//Vlambda() math32.Vector3
-	//AddToVlambda(*math32.Vector3)
 	AngularVelocity() math32.Vector3
 	AngularVelocity() math32.Vector3
-	//Wlambda() math32.Vector3
-	//AddToWlambda(*math32.Vector3)
 	Force() math32.Vector3
 	Force() math32.Vector3
 	Torque() math32.Vector3
 	Torque() math32.Vector3
 	InvMassSolve() float32
 	InvMassSolve() float32
 	InvInertiaWorldSolve() *math32.Matrix3
 	InvInertiaWorldSolve() *math32.Matrix3
-
-	Index() int
 }
 }
 
 
 // Equation is a SPOOK constraint equation.
 // Equation is a SPOOK constraint equation.

+ 0 - 1
physics/equation/friction.go

@@ -2,7 +2,6 @@
 // Use of this source code is governed by a BSD-style
 // Use of this source code is governed by a BSD-style
 // license that can be found in the LICENSE file.
 // license that can be found in the LICENSE file.
 
 
-// Package physics implements a basic physics engine.
 package equation
 package equation
 
 
 import (
 import (

+ 0 - 1
physics/equation/jacobian.go

@@ -2,7 +2,6 @@
 // Use of this source code is governed by a BSD-style
 // Use of this source code is governed by a BSD-style
 // license that can be found in the LICENSE file.
 // license that can be found in the LICENSE file.
 
 
-// Package physics implements a basic physics engine.
 package equation
 package equation
 
 
 import "github.com/g3n/engine/math32"
 import "github.com/g3n/engine/math32"

+ 0 - 1
physics/equation/rotational.go

@@ -2,7 +2,6 @@
 // Use of this source code is governed by a BSD-style
 // Use of this source code is governed by a BSD-style
 // license that can be found in the LICENSE file.
 // license that can be found in the LICENSE file.
 
 
-// Package physics implements a basic physics engine.
 package equation
 package equation
 
 
 import (
 import (

+ 0 - 1
physics/equation/rotationalmotor.go

@@ -2,7 +2,6 @@
 // Use of this source code is governed by a BSD-style
 // Use of this source code is governed by a BSD-style
 // license that can be found in the LICENSE file.
 // license that can be found in the LICENSE file.
 
 
-// Package physics implements a basic physics engine.
 package equation
 package equation
 
 
 import (
 import (