affine: Add comments

This commit is contained in:
Hajime Hoshi 2018-02-28 02:21:07 +09:00
parent 2f1908b05c
commit 1a2a108639
2 changed files with 4 additions and 2 deletions

View File

@ -41,7 +41,7 @@ var (
// Before applying a matrix, a color is un-multiplied, and after applying the matrix,
// the color is multiplied again.
//
// The initial value is identity.
// The nil and initial value is identity.
type ColorM struct {
// When elements is nil, this matrix is identity.
// elements are immutable and a new array must be created when updating.

View File

@ -24,7 +24,9 @@ const GeoMDim = 3
// A GeoM represents a matrix to transform geometry when rendering an image.
//
// The initial value is identity.
// The nil value is identity.
//
// Note that the initial value GeoM{} is no longer identity. TODO: This is confusing. Fix this.
type GeoM struct {
a float64
b float64