go-gl-legacy / glfw

Go bindings for libglfw 2.x
http://www.glfw.org
BSD 3-Clause "New" or "Revised" License
73 stars 8 forks source link

Image.SetHeight() sets... width? #37

Closed metaleap closed 11 years ago

metaleap commented 11 years ago

I don't actually use the Image.go functionality but was just idly browsing its source (an odd hobby of mine) and noticed:

func (i *Image) Width() int { return int(i.img.Width) }

func (i *Image) SetWidth(v int) { i.img.Width = C.int(v) }

func (i *Image) Height() int { return int(i.img.Height) }

func (i *Image) SetHeight(v int) { i.img.Width = C.int(v) }

Is the last one of these indeed correct-as-intended? ;)

ghost commented 11 years ago

O_o It's been a while since I wrote all that, but I get the impression I was half asleep while doing so. Patch incoming.