func (rw *RWops) Write(data []byte) (int, error) { n := C.write(rw.c, unsafe.Pointer(&data[0]), 1, C.size_t(len(data))) switch { case n == 0: return 0, io.EOF case n < 0: return 0, getError() } return int(n), nil }
// WritePacketData transmits a raw packet. func (h *TPacket) WritePacketData(pkt []byte) error { _, err := C.write(h.fd, unsafe.Pointer(&pkt[0]), C.size_t(len(pkt))) return err }
func (self *Mem) Write(body string) C.int { if len(body) >= self.size { return C.int(0) } return C.write(C.CString(body)) }
func WriteGlx() { // C.write(display, window) }