make FromImage work with gifs
This commit is contained in:
parent
f5cf2f6e3b
commit
d9acb35527
2 changed files with 3 additions and 3 deletions
|
|
@ -30,7 +30,7 @@ func FromImage(img image.Image) *IplImage {
|
||||||
c := model.Convert(px).(color.RGBA)
|
c := model.Convert(px).(color.RGBA)
|
||||||
|
|
||||||
value := NewScalar(float64(c.B), float64(c.G), float64(c.R), float64(c.A))
|
value := NewScalar(float64(c.B), float64(c.G), float64(c.R), float64(c.A))
|
||||||
dst.Set2D(x, y, value)
|
dst.Set2D(x-b.Min.X, y-b.Min.Y, value)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue