Пример #1
0
// Sets the yellow color of the pixel wand
func (pw *PixelWand) SetYellowQuantum(yellow Quantum) {
	C.PixelSetYellowQuantum(pw.pw, C.Quantum(yellow))
}
Пример #2
0
// Sets the opacity color of the pixel wand
func (pw *PixelWand) SetOpacityQuantum(opacity Quantum) {
	C.PixelSetOpacityQuantum(pw.pw, C.Quantum(opacity))
}
Пример #3
0
// Sets the red color of the pixel wand
func (pw *PixelWand) SetRedQuantum(red Quantum) {
	C.PixelSetRedQuantum(pw.pw, C.Quantum(red))
}
Пример #4
0
// Sets the green color of the pixel wand
func (pw *PixelWand) SetGreenQuantum(green Quantum) {
	C.PixelSetGreenQuantum(pw.pw, C.Quantum(green))
}
Пример #5
0
// Sets the magenta color of the pixel wand
func (pw *PixelWand) SetMagentaQuantum(magenta Quantum) {
	C.PixelSetMagentaQuantum(pw.pw, C.Quantum(magenta))
}
Пример #6
0
// Sets the cyan color of the pixel wand
func (pw *PixelWand) SetCyanQuantum(cyan Quantum) {
	C.PixelSetCyanQuantum(pw.pw, C.Quantum(cyan))
}
Пример #7
0
// Sets the blue color of the pixel wand
func (pw *PixelWand) SetBlueQuantum(blue Quantum) {
	C.PixelSetBlueQuantum(pw.pw, C.Quantum(blue))
}
Пример #8
0
// Sets the black color of the pixel wand
func (pw *PixelWand) SetBlackQuantum(black Quantum) {
	C.PixelSetBlackQuantum(pw.pw, C.Quantum(black))
}
Пример #9
0
func ConvertRGBToHSL(qr, qg, qb Quantum) (h, s, l float64) {
	var dh, ds, dl C.double
	C.ConvertRGBToHSL(C.Quantum(qr), C.Quantum(qg), C.Quantum(qb), &dh, &ds, &dl)
	return float64(dh), float64(ds), float64(dl)
}
Пример #10
0
func ConvertRGBToHSB(qr, qg, qb Quantum) (h, s, b float64) {
	var dh, ds, db C.double
	C.ConvertRGBToHSB(C.Quantum(qr), C.Quantum(qg), C.Quantum(qb), &dh, &ds, &db)
	return float64(dh), float64(ds), float64(db)
}