Ejemplo n.º 1
0
Archivo: pplot.go Proyecto: DaviWei/iup
func AddPoints(ih *iup.Ihandle, index int, x, y []float64) {
	count := len(x)
	cX := float64ArrayToC(x)
	cY := float64ArrayToC(y)

	C.IupPPlotAddPoints(ih.C(), C.int(index), &cX[0], &cY[0], C.int(count))
}
Ejemplo n.º 2
0
Archivo: pplot.go Proyecto: DaviWei/iup
func Transform(ih *iup.Ihandle, x, y float64) (int, int) {
	cIX := new(C.int)
	cIY := new(C.int)

	C.IupPPlotTransform(ih.C(), C.float(x), C.float(y), cIX, cIY)

	return int(*cIX), int(*cIY)
}
Ejemplo n.º 3
0
Archivo: pplot.go Proyecto: DaviWei/iup
func AddStringPoints(ih *iup.Ihandle, index int, x []string, y []float64) {
	count := len(x)

	cX := stringArrayToC(x)
	defer freeCStringArray(cX)

	cY := float64ArrayToC(y)

	C.IupPPlotAddStrPoints(ih.C(), C.int(index), &cX[0], &cY[0], C.int(count))
}
Ejemplo n.º 4
0
Archivo: pplot.go Proyecto: DaviWei/iup
func Begin(ih *iup.Ihandle, strXdata int) {
	C.IupPPlotBegin(ih.C(), C.int(strXdata))
}
Ejemplo n.º 5
0
Archivo: pplot.go Proyecto: DaviWei/iup
func InsertString(ih *iup.Ihandle, index, sample_index int, x string, y float64) {
	cX := C.CString(x)
	defer C.free(unsafe.Pointer(cX))

	C.IupPPlotInsertStr(ih.C(), C.int(index), C.int(sample_index), cX, C.float(y))
}
Ejemplo n.º 6
0
Archivo: pplot.go Proyecto: DaviWei/iup
func End(ih *iup.Ihandle) {
	C.IupPPlotEnd(ih.C())
}
Ejemplo n.º 7
0
Archivo: pplot.go Proyecto: DaviWei/iup
func Insert(ih *iup.Ihandle, index, sample_index int, x, y float64) {
	C.IupPPlotInsert(ih.C(), C.int(index), C.int(sample_index), C.float(x), C.float(y))
}
Ejemplo n.º 8
0
Archivo: pplot.go Proyecto: DaviWei/iup
func Add(ih *iup.Ihandle, x, y float64) {
	C.IupPPlotAdd(ih.C(), C.float(x), C.float(y))
}
Ejemplo n.º 9
0
Archivo: pplot.go Proyecto: DaviWei/iup
func AddString(ih *iup.Ihandle, x string, y float64) {
	cX := C.CString(x)
	defer C.free(unsafe.Pointer(cX))

	C.IupPPlotAddStr(ih.C(), cX, C.float(y))
}
Ejemplo n.º 10
0
func UseFont(ih *iup.Ihandle, first, count, list_base int) {
	C.IupGLUseFont(ih.C(), C.int(first), C.int(count), C.int(list_base))
}
Ejemplo n.º 11
0
func Palette(ih *iup.Ihandle, index int, r, g, b float64) {
	C.IupGLPalette(ih.C(), C.int(index), C.float(r), C.float(g), C.float(b))
}
Ejemplo n.º 12
0
func SwapBuffers(ih *iup.Ihandle) {
	C.IupGLSwapBuffers(ih.C())
}
Ejemplo n.º 13
0
func IsCurrent(ih *iup.Ihandle) int {
	return int(C.IupGLIsCurrent(ih.C()))
}
Ejemplo n.º 14
0
func MakeCurrent(ih *iup.Ihandle) {
	C.IupGLMakeCurrent(ih.C())
}