query
stringlengths
7
3.85k
document
stringlengths
11
430k
metadata
dict
negatives
sequencelengths
0
101
negative_scores
sequencelengths
0
101
document_score
stringlengths
3
10
document_rank
stringclasses
102 values
fill all or part of buffer object's data store with a fixed value
func ClearBufferSubData(target uint32, internalformat uint32, offset int, size int, format uint32, xtype uint32, data unsafe.Pointer) { C.glowClearBufferSubData(gpClearBufferSubData, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLintptr)(offset), (C.GLsizeiptr)(size), (C.GLenum)(format), (C.GLenum)(xtype), data) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func (dataBlock *DataBlock) fill(offset uint64, buf *bytes.Buffer) uint64 {\n\tbyteToFill := dataBlock.Capacity - offset\n\tbyteActualFill := buf.Next(int(byteToFill)) // API user...\n\tif len(byteActualFill) < int(byteToFill) {\n\t\t// Not sure if the byte at `offset` would be covered by new value...???????????????\n\t\tleftover := dataBlock.Data[(int(offset) + len(byteActualFill)):]\n\t\tdataBlock.Data = append(dataBlock.Data[:offset], append(byteActualFill, leftover...)...)\n\t} else {\n\t\tdataBlock.Data = append(dataBlock.Data[:offset], byteActualFill...)\n\t}\n\treturn uint64(len(byteActualFill))\n}", "func (b *mpgBuff) fill(buff *concBuff) {\n\tbuff.Lock()\n\tn, err := b.fileDec.Read(buff.data)\n\tbuff.len = n\n\tbuff.pos = 0\n\tif err == mpg123.EOF {\n\t\tb.eof = true\n\t}\n\tbuff.Unlock()\n}", "func (b base) Fill(value uint64) {\n\tbinary.PutUvarint(b.inputBuffer[b.seedLen:], value)\n\t// base64 encoding reduce byte size\n\t// from i to o\n\tb64encoder.Encode(b.outputBuffer, b.inputBuffer)\n}", "func (r *BytesRecord) Fill(rid RID, version int, content []byte) error {\n\tr.RID = rid\n\tr.Vers = version\n\tr.Data = content\n\treturn nil\n}", "func (d *OneToOne) Set(data GenericDataType) {\n\tidx := d.writeIndex % uint64(len(d.buffer))\n\n\tnewBucket := &bucket{\n\t\tdata: data,\n\t\tseq: d.writeIndex,\n\t}\n\td.writeIndex++\n\n\tatomic.StorePointer(&d.buffer[idx], unsafe.Pointer(newBucket))\n}", "func (b *buffer) fill(need int) (err error) {\n\tb.idx = 0\n\tb.length = 0\n\n\tvar n int\n\tfor b.length < need {\n\t\tn, err = b.rd.Read(b.buf[b.length:])\n\t\tb.length += n\n\n\t\tif err == nil {\n\t\t\tcontinue\n\t\t}\n\t\treturn // err\n\t}\n\n\treturn\n}", "func (bs endecBytes) fill(offset int, fields ...interface{}) int {\n\tfor _, val := range fields {\n\t\tswitch val.(type) {\n\t\tcase byte:\n\t\t\tbs[offset] = val.(byte)\n\t\t\toffset++\n\t\tcase uint16:\n\t\t\tbinary.BigEndian.PutUint16(bs[offset:], val.(uint16))\n\t\t\toffset += 2\n\t\tcase uint32: // remaingLength\n\t\t\tn := binary.PutUvarint(bs[offset:], uint64(val.(uint32)))\n\t\t\toffset += n\n\t\tcase string:\n\t\t\tstr := val.(string)\n\t\t\tbinary.BigEndian.PutUint16(bs[offset:], uint16(len(str)))\n\t\t\toffset += 2\n\t\t\toffset += copy(bs[offset:], str)\n\t\tcase []byte:\n\t\t\toffset += copy(bs[offset:], val.([]byte))\n\t\tdefault: // unknown type\n\t\t\treturn -offset\n\t\t}\n\t}\n\treturn offset\n}", "func (al *AudioListener) setBuffer(size int) {\n\tal.Lock()\n\tdefer al.Unlock()\n\n\tal.buffer = make([]gumble.AudioPacket, 0, size)\n}", "func (b *CompactableBuffer) Update(address *EntryAddress, data []byte) error {\n\taddress.LockForWrite()\n\tdefer address.UnlockWrite()\n\theader, err := b.ReadHeader(address)\n\tif err != nil {\n\t\treturn err\n\t}\n\tbeforeUpdataDataSize := header.dataSize\n\tafterUpdateDataSize := len(data) + VarIntSize(len(data))\n\tdataSizeDelta := afterUpdateDataSize - int(beforeUpdataDataSize)\n\n\tremainingSpace := int(header.entrySize) - reservedSize - afterUpdateDataSize\n\theader.dataSize = int64(afterUpdateDataSize)\n\tif remainingSpace <= 0 {\n\t\tatomic.AddInt64(&b.dataSize, int64(-beforeUpdataDataSize))\n\t\tatomic.AddInt64(&b.entrySize, int64(-header.entrySize))\n\t\treturn b.expand(address, data)\n\t}\n\n\tatomic.AddInt64(&b.dataSize, int64(dataSizeDelta))\n\tvar target = make([]byte, 0)\n\tAppendToBytes(data, &target)\n\tif len(target) > int(header.dataSize) {\n\t\treturn io.EOF\n\t}\n\twritableBuffer := b.writableBuffer()\n\t_, err = writableBuffer.Write(address.Position()+reservedSize, target...)\n\treturn err\n}", "func (b *Binding) Set(buf uint32) {\n\tgl.BindBufferBase(gl.SHADER_STORAGE_BUFFER, b.uint32, buf)\n}", "func WriteCount(buffer []byte, offset int, value byte, valueCount int) {\n for i := 0; i < valueCount; i++ {\n buffer[offset + i] = value\n }\n}", "func (addr *Bytes) Store(val []byte) {\n\taddr.v.Store(val)\n}", "func (dc *FixedLenByteArrayDictConverter) Fill(out interface{}, val utils.IndexType) error {\n\to := out.([]parquet.FixedLenByteArray)\n\tif err := dc.ensure(val); err != nil {\n\t\treturn err\n\t}\n\to[0] = dc.dict[val]\n\tfor i := 1; i < len(o); i *= 2 {\n\t\tcopy(o[i:], o[:i])\n\t}\n\treturn nil\n}", "func (r *Ring) set(p int, v interface{}) {\n\tr.buff[r.mod(p)] = v\n}", "func (vm *VM) bufferVariable(variable Variable) {\n\tvm.bufferPush(variable.Value())\n}", "func (storage *Storage) SetValue(key string, value []byte) {\n\tfullEntity := encodeRecord(key, string(value))\n\tstorage.mutex.Lock()\n\tbytesWritten := addBlock(storage.file, fullEntity)\n\toffset := int64(storage.size) + int64(len(key)) + 8\n\tatomic.AddInt64(&storage.size, int64(bytesWritten))\n\tstorage.mutex.Unlock()\n\tstorage.store.Store(key, Coords{offset: offset, len: len(value)})\n}", "func (lvs *ValueStore) bufferChunk(v Value, c chunks.Chunk, height uint64, hints Hints) {\n\tlvs.pendingMu.Lock()\n\tdefer lvs.pendingMu.Unlock()\n\th := c.Hash()\n\td.Chk.NotZero(height)\n\tlvs.pendingPuts[h] = pendingChunk{c, height, hints}\n\tlvs.pendingPutSize += uint64(len(c.Data()))\n\n\tputChildren := func(parent hash.Hash) (dataPut int) {\n\t\tpc, present := lvs.pendingPuts[parent]\n\t\td.Chk.True(present)\n\t\tv := DecodeValue(pc.c, lvs)\n\t\tv.WalkRefs(func(grandchildRef Ref) {\n\t\t\tif pc, present := lvs.pendingPuts[grandchildRef.TargetHash()]; present {\n\t\t\t\tlvs.bs.SchedulePut(pc.c, pc.height, pc.hints)\n\t\t\t\tdataPut += len(pc.c.Data())\n\t\t\t\tdelete(lvs.pendingPuts, grandchildRef.TargetHash())\n\t\t\t}\n\t\t})\n\t\treturn\n\t}\n\n\t// Enforce invariant (1)\n\tif height > 1 {\n\t\tv.WalkRefs(func(childRef Ref) {\n\t\t\tchildHash := childRef.TargetHash()\n\t\t\tif _, present := lvs.pendingPuts[childHash]; present {\n\t\t\t\tlvs.pendingParents[h] = height\n\t\t\t} else {\n\t\t\t\t// Shouldn't be able to be in pendingParents without being in pendingPuts\n\t\t\t\t_, present := lvs.pendingParents[childHash]\n\t\t\t\td.Chk.False(present)\n\t\t\t}\n\n\t\t\tif _, present := lvs.pendingParents[childHash]; present {\n\t\t\t\tlvs.pendingPutSize -= uint64(putChildren(childHash))\n\t\t\t\tdelete(lvs.pendingParents, childHash)\n\t\t\t}\n\t\t})\n\t}\n\n\t// Enforce invariant (2)\n\tfor lvs.pendingPutSize > lvs.pendingPutMax {\n\t\tvar tallest hash.Hash\n\t\tvar height uint64 = 0\n\t\tfor parent, ht := range lvs.pendingParents {\n\t\t\tif ht > height {\n\t\t\t\ttallest = parent\n\t\t\t\theight = ht\n\t\t\t}\n\t\t}\n\t\tif height == 0 { // This can happen if there are no pending parents\n\t\t\tvar pc pendingChunk\n\t\t\tfor tallest, pc = range lvs.pendingPuts {\n\t\t\t\t// Any pendingPut is as good as another in this case, so take the first one\n\t\t\t\tbreak\n\t\t\t}\n\t\t\tlvs.bs.SchedulePut(pc.c, pc.height, pc.hints)\n\t\t\tlvs.pendingPutSize -= uint64(len(pc.c.Data()))\n\t\t\tdelete(lvs.pendingPuts, tallest)\n\t\t\tcontinue\n\t\t}\n\n\t\tlvs.pendingPutSize -= uint64(putChildren(tallest))\n\t\tdelete(lvs.pendingParents, tallest)\n\t}\n}", "func (d *Object) flush() {\n\n\td.buf.Pos = offsetFieldCount\n\td.buf.WriteUint16(d.fieldCount)\n\n\td.buf.Pos = offsetSize\n\td.buf.WriteUint24(d.size)\n}", "func (dc *FixedLenByteArrayDictConverter) FillZero(out interface{}) {\n\to := out.([]parquet.FixedLenByteArray)\n\to[0] = dc.zeroVal\n\tfor i := 1; i < len(o); i *= 2 {\n\t\tcopy(o[i:], o[:i])\n\t}\n}", "func (dc *ByteArrayDictConverter) FillZero(out interface{}) {\n\to := out.([]parquet.ByteArray)\n\to[0] = dc.zeroVal\n\tfor i := 1; i < len(o); i *= 2 {\n\t\tcopy(o[i:], o[:i])\n\t}\n}", "func (w *Writer) SetBuffer(raw []byte) {\n\tif w.err != nil {\n\t\treturn\n\t}\n\tw.b = w.b[:0]\n\tw.b = append(w.b, raw...)\n}", "func (b *buffer) grow() {\n\t// ugh all these atomics\n\tatomic.AddUint32(&b.free, uint32(len(b.data)))\n\tatomic.AddUint32(&b.mask, atomic.LoadUint32(&b.mask))\n\tatomic.AddUint32(&b.mask, 1)\n\tatomic.AddUint32(&b.bits, 1)\n\n\tnext := make([]unsafe.Pointer, 2*len(b.data))\n\tcopy(next, b.data)\n\n\t// UGH need to do this with atomics. one pointer + 2 uint64 calls?\n\tb.data = next\n}", "func (p *movingAverageProcessor) addBufferData(index int, data interface{}, namespace string) error {\n\tif _, ok := p.movingAverageMap[namespace]; ok {\n\t\tif index >= len(p.movingAverageMap[namespace].movingAverageBuf) {\n\t\t\treturn errors.New(\"Incorrect value of index, trying to access non-existing element of buffer\")\n\t\t}\n\t\tp.movingAverageMap[namespace].movingAverageBuf[index] = data\n\t\treturn nil\n\t} else {\n\t\treturn errors.New(\"Namespace is not present in the map\")\n\t}\n}", "func (b *Buf) Reset() { b.b = b.b[:0] }", "func (self Source) SetBuffer(buffer Buffer) {\n\tself.Seti(AlBuffer, int32(buffer))\n}", "func BufferStorage(target uint32, size int, data unsafe.Pointer, flags uint32) {\n\tsyscall.Syscall6(gpBufferStorage, 4, uintptr(target), uintptr(size), uintptr(data), uintptr(flags), 0, 0)\n}", "func (s *Arena) putVal(v y.ValueStruct) uint32 {\n\tl := uint32(v.EncodedSize())\n\toffset := s.allocate(l) - l\n\tbuf := s.data[offset : offset+l]\n\tv.Encode(buf)\n\treturn offset\n}", "func ringBufferInitBuffer(buflen uint32, rb *ringBuffer) {\n\tvar new_data []byte\n\tvar i uint\n\tsize := 2 + int(buflen) + int(kSlackForEightByteHashingEverywhere)\n\tif cap(rb.data_) < size {\n\t\tnew_data = make([]byte, size)\n\t} else {\n\t\tnew_data = rb.data_[:size]\n\t}\n\tif rb.data_ != nil {\n\t\tcopy(new_data, rb.data_[:2+rb.cur_size_+uint32(kSlackForEightByteHashingEverywhere)])\n\t}\n\n\trb.data_ = new_data\n\trb.cur_size_ = buflen\n\trb.buffer_ = rb.data_[2:]\n\trb.data_[1] = 0\n\trb.data_[0] = rb.data_[1]\n\tfor i = 0; i < kSlackForEightByteHashingEverywhere; i++ {\n\t\trb.buffer_[rb.cur_size_+uint32(i)] = 0\n\t}\n}", "func (vm *VM) bufferPush(data string) {\n\tnewBuffer := &buffer{\n\t\tprevious: vm.buffer,\n\t\tvalue: data,\n\t}\n\tvm.buffer = newBuffer\n}", "func (c *ChannelData) grow(v int) {\n\tn := len(c.Raw) + v\n\tfor cap(c.Raw) < n {\n\t\tc.Raw = append(c.Raw, 0)\n\t}\n\tc.Raw = c.Raw[:n]\n}", "func Memset(data []byte, value byte) {\n\tif value == 0 {\n\t\tfor i := range data {\n\t\t\tdata[i] = 0\n\t\t}\n\t} else if len(data) != 0 {\n\t\tdata[0] = value\n\n\t\tfor i := 1; i < len(data); i *= 2 {\n\t\t\tcopy(data[i:], data[:i])\n\t\t}\n\t}\n}", "func (src *Source) SetNewBuffer() {\n\tsrc.buf = make([]byte, 64)\n}", "func (dc *ByteArrayDictConverter) Fill(out interface{}, val utils.IndexType) error {\n\to := out.([]parquet.ByteArray)\n\tif err := dc.ensure(val); err != nil {\n\t\treturn err\n\t}\n\to[0] = dc.dict[val]\n\tfor i := 1; i < len(o); i *= 2 {\n\t\tcopy(o[i:], o[:i])\n\t}\n\treturn nil\n}", "func (b *Ring) push(value interface{}) {\n\tb.lock.Lock()\n\tdefer b.lock.Unlock()\n\tif len(b.buf) == 0 || b.size == 0 { // nothing to do\n\t\treturn\n\t}\n\tnext := Next(1, b.head, len(b.buf))\n\tb.buf[next] = value\n\tb.head = next\n\t// note that the oldest is auto pruned, when size== capacity, but with the size attribute we know it has been discarded\n}", "func (d *Display) resetBuffer() {\n\td.width = d.device.Width()\n\td.height = d.device.Height()\n\td.buffer = make([][]byte, d.height)\n\tfor y := range d.buffer {\n\t\td.buffer[y] = make([]byte, d.width)\n\t}\n}", "func (rb *RingBuffer) Add(value stats.Record) {\n\trb.lock.Lock()\n\tdefer rb.lock.Unlock()\n\trb.data[rb.seq%uint64(len(rb.data))] = value\n\trb.seq++\n}", "func (z nat) setBytes(buf []byte) nat {\n\tz = z.make((len(buf) + _S - 1) / _S)\n\n\tk := 0\n\ts := uint(0)\n\tvar d Word\n\tfor i := len(buf); i > 0; i-- {\n\t\td |= Word(buf[i-1]) << s\n\t\tif s += 8; s == _S*8 {\n\t\t\tz[k] = d\n\t\t\tk++\n\t\t\ts = 0\n\t\t\td = 0\n\t\t}\n\t}\n\tif k < len(z) {\n\t\tz[k] = d\n\t}\n\n\treturn z.norm()\n}", "func (dc *Float32DictConverter) Fill(out interface{}, val utils.IndexType) error {\n\to := out.([]float32)\n\tif err := dc.ensure(val); err != nil {\n\t\treturn err\n\t}\n\to[0] = dc.dict[val]\n\tfor i := 1; i < len(o); i *= 2 {\n\t\tcopy(o[i:], o[:i])\n\t}\n\treturn nil\n}", "func (b *Buffer) Sync() {\n\tb.SetArea(b.Bounds())\n}", "func (dc *Float64DictConverter) Fill(out interface{}, val utils.IndexType) error {\n\to := out.([]float64)\n\tif err := dc.ensure(val); err != nil {\n\t\treturn err\n\t}\n\to[0] = dc.dict[val]\n\tfor i := 1; i < len(o); i *= 2 {\n\t\tcopy(o[i:], o[:i])\n\t}\n\treturn nil\n}", "func (self *ValueStore) Append(options WriteOptions, instanceId uint64, buffer []byte, fileIdStr *string) error {\n begin := util.NowTimeMs()\n\n self.mutex.Lock()\n defer self.mutex.Unlock()\n\n bufferLen := len(buffer)\n len := util.UINT64SIZE + bufferLen\n tmpBufLen := len + util.INT32SIZE\n\n var fileId int32\n var offset uint32\n err := self.getFileId(uint32(tmpBufLen), &fileId, &offset)\n if err != nil {\n return err\n }\n\n tmpBuf := make([]byte, tmpBufLen)\n util.EncodeInt32(tmpBuf, 0, int32(len))\n util.EncodeUint64(tmpBuf, util.INT32SIZE, instanceId)\n copy(tmpBuf[util.INT32SIZE+util.UINT64SIZE:], []byte(buffer))\n\n ret, err := self.file.Write(tmpBuf)\n if ret != tmpBufLen {\n err = fmt.Errorf(\"writelen %d not equal to %d,buffer size %d\",\n ret, tmpBufLen, bufferLen)\n return err\n }\n\n if options.Sync {\n self.file.Sync()\n }\n\n self.nowFileOffset += uint64(tmpBufLen)\n\n ckSum := util.Crc32(0, tmpBuf[util.INT32SIZE:], common.CRC32_SKIP)\n self.EncodeFileId(fileId, uint64(offset), ckSum, fileIdStr)\n\n useMs := util.NowTimeMs() - begin\n\n log.Info(\"ok, offset %d fileid %d cksum %d instanceid %d buffersize %d usetime %d ms sync %t\",\n offset, fileId, ckSum, instanceId, bufferLen, useMs, options.Sync)\n return nil\n}", "func (debugging *debuggingOpenGL) BufferData(target uint32, size int, data interface{}, usage uint32) {\n\tdebugging.recordEntry(\"BufferData\", target, size, data, usage)\n\tdebugging.gl.BufferData(target, size, data, usage)\n\tdebugging.recordExit(\"BufferData\")\n}", "func newBuffer(bits uint32) buffer {\n\tvar b buffer\n\tb.data = make([]unsafe.Pointer, 1<<bits)\n\tb.free = 1 << bits\n\tb.mask = 1<<bits - 1\n\tb.bits = bits\n\treturn b\n}", "func BufferStorage(target uint32, size int, data unsafe.Pointer, flags uint32) {\n C.glowBufferStorage(gpBufferStorage, (C.GLenum)(target), (C.GLsizeiptr)(size), data, (C.GLbitfield)(flags))\n}", "func (src *Source) SetBuffer(buf []byte) {\n\tsrc.buf = buf\n}", "func (c *SimpleMemoryCache) Set(ctx *Context, next Next) {\n\tc.data[ctx.Key] = ctx.Value.(int64)\n\n\t// call next to make sure all memory cache ready\n\t// maybe you should check next is nil or not\n\tnext(ctx)\n}", "func (w *buffer) reset() {\n\tfor i := range (*w)[:cap(*w)] {\n\t\t(*w)[i] = 0\n\t}\n\t*w = (*w)[:0]\n}", "func (wb *fieldWriteBuf) reset(seq int, label string) {\n\twb.seq = seq\n\twb.label = label\n\twb.defaultBuf = wb.defaultBuf[:0]\n\twb.blobBuf = wb.blobBuf[:0]\n\twb.prevString = wb.prevString[:0]\n\twb.prevInt64Value0 = 0\n\twb.prevInt64Value1 = 0\n\twb.startAddr = biopb.Coord{biopb.InvalidRefID, biopb.InvalidPos, 0}\n\twb.endAddr = biopb.Coord{biopb.InvalidRefID, biopb.InvalidPos, 0}\n\twb.numRecords = 0\n}", "func (b *Buffer) Clear() {\n\tb.currentSize = 0\n\tb.contents = map[entity.Key]inventoryapi.PostDeltaBody{}\n}", "func (p *Lexer) fill() {\n\n\tif p.r >= 0 && p.r < bufSize {\n\t\treturn\n\t}\n\n\t// Read new data: try a limited number of times.\n\t// The first time read the full buffer, else only half.\n\toffset := 0\n\tif p.r >= 0 {\n\t\tcopy(p.buf, p.buf[halfSize:])\n\t\tp.r = halfSize\n\t\toffset = halfSize\n\t} else {\n\t\tp.r = 0\n\t}\n\n\tfor i := maxConsecutiveEmptyReads; i > 0; i-- {\n\t\tn, err := p.rd.Read(p.buf[offset:])\n\t\tif n < 0 {\n\t\t\tpanic(errNegativeRead)\n\t\t}\n\t\tif err != nil {\n\t\t\tp.err = err\n\t\t\tbreak\n\t\t}\n\n\t\toffset += n\n\t\tif offset >= halfSize {\n\t\t\tbreak\n\t\t}\n\t}\n\n\tp.lastByte = offset\n}", "func (b *Ring) Add(values ...interface{}) error {\n\tif len(values) == 0 {\n\t\treturn nil\n\t}\n\tif len(values) == 1 {\n\t\treturn b.add(values[0])\n\n\t}\n\tb.lock.Lock()\n\tdefer b.lock.Unlock()\n\n\t//check that we will be able to fill it.\n\tif b.size+len(values) > len(b.buf) {\n\t\treturn ErrFull\n\t}\n\n\t//alg: add as much as possible in a single copy, and repeat until exhaustion\n\n\tfor len(values) > 0 {\n\t\t// is all about slicing right\n\t\t//\n\t\t// the extra space to add value too can be either\n\t\t// from next position, to the end of the buffer\n\t\t// or from the beginning to the tail of the ring\n\n\t\tnext := Next(1, b.head, len(b.buf))\n\n\t\t//tail := Index(-1, b.head, b.size, len(b.buf)\n\n\t\t// tail is the absolute index of the buffer tail\n\t\t// next is the absolute index of the buffer head+1\n\t\t//I want to write as much as possible after next.\n\t\t// so it's either till the end, or till the tail\n\t\t// if the ring's tail is behind we can use the slice from next to the end\n\t\t// if the ring's tail is ahead we can't use the whole slice.\n\t\t// BUT, we know that there is enough room left, so we don't care if the slice is \"too\" big\n\t\t// Therefore, instead of dealing with all the cases\n\t\t// we always use:\n\t\ttgt := b.buf[next:]\n\t\t// a slice of the buffer, that we'll used to write into\n\n\t\t//we copy as much as possible.\n\t\tn := copy(tgt, values) //n is the number of copied values\n\n\t\tif n == 0 { // could not write ! the buf is exhausted\n\t\t\tpanic(ErrFull) // because we have tested this case before,I'd rather panic than infinite loop\n\t\t}\n\n\t\t// we adjust local variables (latest has moved, and so has size)\n\t\tb.head = Next(n, b.head, len(b.buf))\n\t\tb.size += n // increase the inner size\n\n\t\t// we remove from the source, the value copied.\n\t\tvalues = values[n:]\n\t}\n\treturn nil\n\n}", "func (b *Ring) add(val interface{}) error {\n\tif b.size >= len(b.buf) {\n\t\treturn ErrFull\n\t}\n\tb.lock.Lock()\n\tdefer b.lock.Unlock()\n\n\tnext := Next(1, b.head, len(b.buf))\n\tb.buf[next] = val\n\tb.head = next\n\tb.size++ // increase the inner size\n\treturn nil\n}", "func (r *ringBufferProvider) Feed(elem interface{}) {\n\trbs := uint64(len(r.ringBuffer))\n\tfor i := 0; ; i++ {\n\t\tringRead := atomic.LoadUint64(&r.ringRead)\n\t\tringWrite := atomic.LoadUint64(&r.ringWrite)\n\t\tringWAlloc := atomic.LoadUint64(&r.ringWAlloc)\n\t\tringWriteNextVal := ringWrite + 1\n\t\tif ringWrite == ringWAlloc && ringWriteNextVal-uint64(len(r.ringBuffer)) != ringRead {\n\t\t\tif atomic.CompareAndSwapUint64(&r.ringWAlloc, ringWAlloc, ringWriteNextVal) {\n\t\t\t\tr.ringBuffer[ringWrite%rbs] = elem\n\t\t\t\tif !atomic.CompareAndSwapUint64(&r.ringWrite, ringWrite, ringWriteNextVal) {\n\t\t\t\t\tpanic(\"failed to commit allocated write in ring-buffer\")\n\t\t\t\t}\n\t\t\t\treturn\n\t\t\t}\n\t\t}\n\t\truntime.Gosched()\n\t\ttime.Sleep(time.Duration(i) * time.Nanosecond) // notice nanos vs micros\n\t}\n}", "func (b *RecordBuffer) Flush() {\n\tb.recordsInBuffer = b.recordsInBuffer[:0]\n\tb.sequencesInBuffer = b.sequencesInBuffer[:0]\n}", "func (b *BufferPool) Flush(interface{}) {\n\tb.Lock()\n\tb.Data = make([]byte, b.Size)\n\tb.Unlock()\n}", "func (b *Ring) Push(values ...interface{}) {\n\tif len(values) == 0 || b.size == 0 {\n\t\treturn\n\t}\n\tif len(values) == 1 {\n\t\tb.push(values[0])\n\t\treturn\n\t}\n\tb.lock.Lock()\n\tdefer b.lock.Unlock()\n\t//alg: just write as much as you need after next\n\n\t// if len(values) is greater than b.size it is useless to fully write it down.\n\t// We know that the first items will be overwritten.\n\t// so we slice down values in that case\n\n\tif len(values) > b.size {\n\t\t//only write down the last b.size ones\n\t\tvalues = values[len(values)-b.size:] // cut the one before, there are useless.\n\t}\n\t// now we need to write down values (that is never greater than b.size)\n\n\t// next is the absolute index of the buffer head+1\n\tnext := Next(1, b.head, len(b.buf))\n\n\t// we are going to write down from 'next' toward the end of the buffer.\n\ttgt := b.buf[next:]\n\n\t//we copy as much as possible.\n\tn := copy(tgt, values) //n is the number of copied values\n\n\t// if we have exhausted the buffer (we have reached the end of the buffer) we need to start again from zero this time.\n\tif n < len(values) { // there are still values to copy\n\t\tcopy(b.buf, values[n:]) //copy remaining from the begining this time.\n\t}\n\t//move the head\n\tb.head = Next(len(values), b.head, len(b.buf))\n\n}", "func (dc *Float32DictConverter) FillZero(out interface{}) {\n\to := out.([]float32)\n\to[0] = dc.zeroVal\n\tfor i := 1; i < len(o); i *= 2 {\n\t\tcopy(o[i:], o[:i])\n\t}\n}", "func (b *Ring) SetCapacity(capacity int) {\n\tb.lock.Lock()\n\tdefer b.lock.Unlock()\n\n\tif capacity < b.size {\n\t\tcapacity = b.size\n\t}\n\tif capacity == len(b.buf) { //nothing to be done\n\t\treturn\n\t}\n\n\tnbuf := make([]interface{}, capacity)\n\n\t// now that the new capacity is enough we just copy down the buffer\n\n\t//there are only two cases:\n\t// either the values are contiguous, then they goes from\n\t// tail to head\n\t// or there are splitted in two:\n\t// tail to buffer's end\n\t// 0 to head.\n\n\thead := b.head\n\ttail := Index(-1, head, b.size, len(b.buf))\n\n\t// we are not going to copy the buffer in the same state (absolute position of head and tail)\n\t// instead, we are going to select the simplest solution.\n\tif tail < head { //data is in one piece\n\t\tcopy(nbuf, b.buf[tail:head+1])\n\t} else { //two pieces\n\t\t//copy as much as possible to the end of the buf\n\t\tn := copy(nbuf, b.buf[tail:])\n\t\t//and then from the beginning\n\t\tcopy(nbuf[n:], b.buf[:head+1])\n\t}\n\tb.buf = nbuf\n\tb.head = b.size - 1\n\treturn\n}", "func (buf *Buffer) reset() {\n\tbuf.DNCReports = nil\n\tbuf.DNCReports = make([]DNCReport, 0)\n\tbuf.CNIReports = nil\n\tbuf.CNIReports = make([]CNIReport, 0)\n\tbuf.NPMReports = nil\n\tbuf.NPMReports = make([]NPMReport, 0)\n\tbuf.CNSReports = nil\n\tbuf.CNSReports = make([]CNSReport, 0)\n\tpayloadSize = 0\n}", "func (d *datastoreValues) set(data map[string][]byte) {\n\td.mu.Lock()\n\tdefer d.mu.Unlock()\n\n\tif d.Data == nil {\n\t\td.Data = data\n\t\treturn\n\t}\n\n\tfor key, value := range data {\n\t\td.Data[key] = value\n\t}\n}", "func BufferData(target uint32, size int, data unsafe.Pointer, usage uint32) {\n\tsyscall.Syscall6(gpBufferData, 4, uintptr(target), uintptr(size), uintptr(data), uintptr(usage), 0, 0)\n}", "func (g *GrowingBuffer) Values() interface{} {\n return g.bufferPtr.Elem().Interface()\n}", "func hostSetBytes(objId int32, keyId int32, typeId int32, value *byte, size int32)", "func (b *Buffer) Data() []byte { return b.data }", "func (b *Buffer) updateFirst(fsize uint64) {\n\tif b.biggest == 0 {\n\t\t// Just starting out, no need to update.\n\t\treturn\n\t}\n\n\tvar (\n\t\tstart = b.last % b.capacity\n\t\tend = (start + fsize) % b.capacity\n\t\twrapping = end <= start\n\t)\n\n\tif start == end {\n\t\tb.length = 0\n\t\tb.first = b.last\n\t\treturn\n\t}\n\n\tfor {\n\t\tif b.first == b.last {\n\t\t\t// b can fit only the new incoming record.\n\t\t\treturn\n\t\t}\n\n\t\tfirstWrapped := b.first % b.capacity\n\n\t\tif wrapping {\n\t\t\tif end <= firstWrapped && firstWrapped < start {\n\t\t\t\treturn\n\t\t\t}\n\t\t} else {\n\t\t\tif end <= firstWrapped {\n\t\t\t\treturn\n\t\t\t}\n\t\t\tif start > firstWrapped {\n\t\t\t\treturn\n\t\t\t}\n\t\t}\n\n\t\tsecond := b.nextFrameOffset(b.first)\n\t\tb.length -= (second - b.first - total)\n\t\tb.first = second\n\n\t\t// May need to discard multiple records at the begining.\n\t}\n}", "func (b *Builder) Buffer(count int) value.Pointer {\n\tpointerSize := b.memoryLayout.GetPointer().GetSize()\n\tdynamic := false\n\tsize := 0\n\n\t// Examine the stack to see where these values came from\n\tfor i := 0; i < count; i++ {\n\t\te := b.stack[len(b.stack)-i-1]\n\t\top := b.instructions[e.idx]\n\t\tty := e.ty\n\t\tif _, isPush := op.(asm.Push); !isPush {\n\t\t\t// Values that have made their way on to the stack from non-constant\n\t\t\t// sources cannot be put in the constant buffer.\n\t\t\tdynamic = true\n\t\t}\n\t\tswitch ty {\n\t\tcase protocol.Type_ConstantPointer, protocol.Type_VolatilePointer:\n\t\t\t// Pointers cannot be put into the constant buffer as they are remapped\n\t\t\t// by the VM\n\t\t\tdynamic = true\n\t\t}\n\n\t\tsize += ty.Size(pointerSize)\n\t}\n\n\tif dynamic {\n\t\t// At least one of the values was not from a Push()\n\t\t// Build the buffer in temporary memory at replay time.\n\t\tbuf := b.AllocateTemporaryMemory(uint64(size))\n\t\toffset := size\n\t\tfor i := 0; i < count; i++ {\n\t\t\te := b.stack[len(b.stack)-1]\n\t\t\toffset -= e.ty.Size(pointerSize)\n\t\t\tb.Store(buf.Offset(uint64(offset)))\n\t\t}\n\t\treturn buf\n\t}\n\t// All the values are constant.\n\t// Move the pushed values into a constant memory buffer.\n\tvalues := make([]value.Value, count)\n\tfor i := 0; i < count; i++ {\n\t\te := b.stack[len(b.stack)-1]\n\t\tvalues[count-i-1] = b.instructions[e.idx].(asm.Push).Value\n\t\tb.removeInstruction(e.idx)\n\t\tb.popStack()\n\t}\n\treturn b.constantMemory.writeValues(values...)\n}", "func (f *File) FillRecord(r int) error {\n\t_, slabsize := f.Header.slabs()\n\tfor i := range f.Header.vars {\n\t\tvv := &f.Header.vars[i]\n\t\tif !vv.isRecordVariable() {\n\t\t\tcontinue\n\t\t}\n\t\tbegin := vv.begin + int64(r)*slabsize\n\t\tend := begin + pad4(vv.vSize())\n\t\tif err := fill(f.rw, begin, end, vv.fillValue(), vv.dtype); err != nil {\n\t\t\treturn err\n\t\t}\n\t}\n\treturn nil\n}", "func (g *GLTF) loadBuffer(bufIdx int) ([]byte, error) {\n\n\t// Check if provided buffer index is valid\n\tif bufIdx < 0 || bufIdx >= len(g.Buffers) {\n\t\treturn nil, fmt.Errorf(\"invalid buffer index\")\n\t}\n\tbufData := &g.Buffers[bufIdx]\n\t// Return cached if available\n\tif bufData.cache != nil {\n\t\tlog.Debug(\"Fetching Buffer %d (cached)\", bufIdx)\n\t\treturn bufData.cache, nil\n\t}\n\tlog.Debug(\"Loading Buffer %d\", bufIdx)\n\n\t// If buffer URI use the chunk data field\n\tif bufData.Uri == \"\" {\n\t\treturn g.data, nil\n\t}\n\n\t// Checks if buffer URI is a data URI\n\tvar data []byte\n\tvar err error\n\tif isDataURL(bufData.Uri) {\n\t\tdata, err = loadDataURL(bufData.Uri)\n\t} else {\n\t\t// Try to load buffer from file\n\t\tdata, err = g.loadFileBytes(bufData.Uri)\n\t}\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\n\t// Checks data length\n\tif len(data) != bufData.ByteLength {\n\t\treturn nil, fmt.Errorf(\"buffer:%d read data length:%d expected:%d\", bufIdx, len(data), bufData.ByteLength)\n\t}\n\t// Cache buffer data\n\tg.Buffers[bufIdx].cache = data\n\tlog.Debug(\"cache data:%v\", len(bufData.cache))\n\treturn data, nil\n}", "func (c *fakeRedisConn) SetReadBuffer(bytes int) {}", "func (bp *bufferPool) putBuffer(b *buffer) {\n\tbp.lock.Lock()\n\tif bp.freeBufNum < 1000 {\n\t\tb.next = bp.freeList\n\t\tbp.freeList = b\n\t\tbp.freeBufNum++\n\t}\n\tbp.lock.Unlock()\n}", "func (geom Geometry) Buffer(distance float64, segments int) Geometry {\n\tnewGeom := C.OGR_G_Buffer(geom.cval, C.double(distance), C.int(segments))\n\treturn Geometry{newGeom}\n}", "func (fm *FinalModelStructBytes) Set(fbeValue *StructBytes) (int, error) {\n fm.buffer.Shift(fm.FBEOffset())\n fbeResult, err := fm.SetFields(fbeValue)\n fm.buffer.Unshift(fm.FBEOffset())\n return fbeResult, err\n}", "func (s *scratch) add(c byte) {\n\tif s.fill+1 >= cap(s.data) {\n\t\ts.grow()\n\t}\n\n\ts.data[s.fill] = c\n\ts.fill++\n}", "func (p *byteBufferPool) give(buf *[]byte) {\n\tif buf == nil {\n\t\treturn\n\t}\n\tsize := cap(*buf)\n\tslot := p.slot(size)\n\tif slot == errSlot {\n\t\treturn\n\t}\n\tif size != int(p.pool[slot].defaultSize) {\n\t\treturn\n\t}\n\tp.pool[slot].pool.Put(buf)\n}", "func (b *Buffer) Reset() {\n\tb.Line = b.Line[:0]\n\tb.Val = b.Val[:0]\n}", "func (d *decoder) buffer() []byte {\n\tif d.buf == nil {\n\t\td.buf = make([]byte, 8)\n\t}\n\treturn d.buf\n}", "func (b *Buffer) Clear() {\n\tb.series = make(map[string]*influxdb.Series)\n\tb.size = 0\n}", "func (e rawEntry) value(buf []byte) rawValue { return buf[e.ptr():][:e.sz()] }", "func (ms *MemStore) SetAll(data map[string]io.WriterTo) error {\n\tvar err error\n\tms.mu.Lock()\n\tfor k, d := range data {\n\t\tvar buf memio.Buffer\n\t\tif _, err = d.WriteTo(&buf); err != nil {\n\t\t\tbreak\n\t\t}\n\t\tms.data[k] = buf\n\t}\n\tms.mu.Unlock()\n\treturn err\n}", "func NewBuffer(aSlice interface{}) *Buffer {\n return &Buffer{buffer: sliceValue(aSlice, false), handler: valueHandler{}}\n}", "func (b *Buffer) AttachNew() {\n b.data = make([]byte, 0)\n b.size = 0\n b.offset = 0\n}", "func (c webgl) BufferDataX(target Enum, d interface{}, usage Enum) {\n\tc.ctx.Call(\"bufferData\", target, conv(d), usage)\n}", "func (gen *DataGen) Init(m *pktmbuf.Packet, args ...any) {\n\tdata := ndn.MakeData(args...)\n\twire, e := tlv.EncodeValueOnly(data)\n\tif e != nil {\n\t\tlogger.Panic(\"encode Data error\", zap.Error(e))\n\t}\n\n\tm.SetHeadroom(0)\n\tif e := m.Append(wire); e != nil {\n\t\tlogger.Panic(\"insufficient dataroom\", zap.Error(e))\n\t}\n\tbufBegin := unsafe.Pointer(unsafe.SliceData(m.SegmentBytes()[0]))\n\tbufEnd := unsafe.Add(bufBegin, len(wire))\n\t*gen = DataGen{\n\t\ttpl: (*C.struct_rte_mbuf)(m.Ptr()),\n\t\tmeta: unsafe.SliceData(C.DataEnc_NoMetaInfo[:]),\n\t\tcontentIov: [1]C.struct_iovec{{\n\t\t\tiov_base: bufEnd,\n\t\t}},\n\t}\n\n\td := tlv.DecodingBuffer(wire)\n\tfor _, de := range d.Elements() {\n\t\tswitch de.Type {\n\t\tcase an.TtName:\n\t\t\tgen.suffix = C.LName{\n\t\t\t\tvalue: (*C.uint8_t)(unsafe.Add(bufEnd, -len(de.After)-de.Length())),\n\t\t\t\tlength: C.uint16_t(de.Length()),\n\t\t\t}\n\t\tcase an.TtMetaInfo:\n\t\t\tgen.meta = (*C.uint8_t)(unsafe.Add(bufEnd, -len(de.WireAfter())))\n\t\tcase an.TtContent:\n\t\t\tgen.contentIov[0] = C.struct_iovec{\n\t\t\t\tiov_base: unsafe.Add(bufEnd, -len(de.After)-de.Length()),\n\t\t\t\tiov_len: C.size_t(de.Length()),\n\t\t\t}\n\t\t}\n\t}\n\n\tC.rte_pktmbuf_adj(gen.tpl, C.uint16_t(uintptr(gen.contentIov[0].iov_base)-uintptr(bufBegin)))\n\tC.rte_pktmbuf_trim(gen.tpl, C.uint16_t(C.size_t(gen.tpl.pkt_len)-gen.contentIov[0].iov_len))\n}", "func putBuffer(buf *bytes.Buffer) {\n\tbuf.Reset()\n\tbufferPool.Put(buf)\n}", "func (access FloatAccess) Set(row int, val float64) {\n access.rawData[access.indices[row]] = val\n}", "func (p *Buffer) SetBuf(s []byte) {\n\tp.buf = s\n\tp.index = 0\n\tp.length = len(s)\n}", "func Set(height uint64, digest blockdigest.Digest, version uint16, timestamp uint64) {\n\n\tglobalData.Lock()\n\n\tglobalData.height = height\n\tglobalData.previousBlock = digest\n\tglobalData.previousVersion = version\n\tglobalData.previousTimestamp = timestamp\n\n\tglobalData.Unlock()\n}", "func (b *Buffer) Reset() {\n\tb.B = b.B[:0]\n}", "func (dc *Float64DictConverter) FillZero(out interface{}) {\n\to := out.([]float64)\n\to[0] = dc.zeroVal\n\tfor i := 1; i < len(o); i *= 2 {\n\t\tcopy(o[i:], o[:i])\n\t}\n}", "func (b *Buffer) Reset() {\n b.size = 0\n b.offset = 0\n}", "func (rb *ringBuffer) read(f func([]byte)) {\n\tvar dataHead, dataTail uint64\n\n\tdataTail = rb.metadata.DataTail\n\tdataHead = atomic.LoadUint64(&rb.metadata.DataHead)\n\n\tfor dataTail < dataHead {\n\t\tdataBegin := dataTail % uint64(len(rb.data))\n\t\tdataEnd := dataHead % uint64(len(rb.data))\n\n\t\tvar data []byte\n\t\tif dataEnd >= dataBegin {\n\t\t\tdata = rb.data[dataBegin:dataEnd]\n\t\t} else {\n\t\t\tdata = rb.data[dataBegin:]\n\t\t\tdata = append(data, rb.data[:dataEnd]...)\n\t\t}\n\n\t\tf(data)\n\n\t\t//\n\t\t// Write dataHead to dataTail to let kernel know that we've\n\t\t// consumed the data up to it.\n\t\t//\n\t\tdataTail = dataHead\n\t\tatomic.StoreUint64(&rb.metadata.DataTail, dataTail)\n\n\t\t// Update dataHead in case it has been advanced in the interim\n\t\tdataHead = atomic.LoadUint64(&rb.metadata.DataHead)\n\t}\n}", "func (b *Buffer) AttachBytes(buffer []byte, offset int, size int) {\n if len(buffer) < size {\n panic(\"invalid buffer\")\n }\n if size <= 0 {\n panic(\"invalid size\")\n }\n if offset > size {\n panic(\"invalid offset\")\n }\n\n b.data = buffer\n b.size = size\n b.offset = offset\n}", "func (st *Stat) Fill(ost *Stat) {\n\tif ost.Following >= 0 {\n\t\tst.Following = ost.Following\n\t}\n\tif ost.Whisper >= 0 {\n\t\tst.Whisper = ost.Whisper\n\t}\n\tif ost.Black >= 0 {\n\t\tst.Black = ost.Black\n\t}\n\tif ost.Follower >= 0 {\n\t\tst.Follower = ost.Follower\n\t}\n}", "func (b *BufferPool) Put(data interface{}) (n int64, err error) {\n\tvar putData []byte\n\tvar putDataLength int64\n\tvar blackspaceLength int64\n\tswitch info := data.(type) {\n\tcase string:\n\t\tputData = []byte(info)\n\t\tputDataLength = int64(len(putData))\n\tcase []byte:\n\t\tputData = info\n\t\tputDataLength = int64(len(putData))\n\tdefault:\n\t\treturn 0, TYPEERROR\n\t}\n\n\tb.Lock()\n\t// free buffer size smaller than data size which will be written to.\n\tif b.Free < int64(len(putData)) {\n\t\taddRate := math.Ceil(float64(putDataLength) / float64(b.Size))\n\t\tif addRate <= 1 {\n\t\t\taddRate = 2\n\t\t}\n\t\tif b.AutoIncrement == true {\n\t\t\tblackspaceLength = b.Size*int64(addRate) - b.Used - putDataLength\n\t\t} else {\n\t\t\treturn 0, BUFFERNOTENOUGH\n\t\t}\n\t} else {\n\t\tblackspaceLength = b.Free - putDataLength\n\t}\n\tb.Data = append(b.Data[:b.Used], putData...)\n\tb.Data = append(b.Data, make([]byte, blackspaceLength)...)\n\tb.Used = b.Used + putDataLength\n\tb.Free = blackspaceLength\n\tb.Size = b.Used + b.Free\n\tb.Unlock()\n\treturn putDataLength, nil\n}", "func (_e *MockTestTransportInstance_Expecter) FillBuffer(until interface{}) *MockTestTransportInstance_FillBuffer_Call {\n\treturn &MockTestTransportInstance_FillBuffer_Call{Call: _e.mock.On(\"FillBuffer\", until)}\n}", "func BufferData(target Enum, src []byte, usage Enum) {\n\tgl.BufferData(uint32(target), int(len(src)), gl.Ptr(&src[0]), uint32(usage))\n}", "func (j *JSendBuilderBuffer) Data(data interface{}) JSendBuilder {\n\treturn j.Set(FieldData, data)\n}", "func (native *OpenGL) BufferData(target uint32, size int, data interface{}, usage uint32) {\n\tdataPtr, isPtr := data.(unsafe.Pointer)\n\tif isPtr {\n\t\tgl.BufferData(target, size, dataPtr, usage)\n\t} else {\n\t\tgl.BufferData(target, size, gl.Ptr(data), usage)\n\t}\n}", "func (m *Marshaler) reset() {\n\tm.b = m.b[:0]\n}", "func (b *Buffer) updateMeta() {\n\t// First 8 bytes have the first frame offset,\n\t// next 8 bytes have the last frame offset,\n\t// next 8 bytes are the next sequence number,\n\t// next 4 bytes are the biggest data record we've seen,\n\t// next 8 bytes are the total data in the buffer.\n\toff := int(b.capacity)\n\tbinary.PutLittleEndianUint64(b.data, off, b.first)\n\tbinary.PutLittleEndianUint64(b.data, off+8, b.last)\n\tbinary.PutLittleEndianUint64(b.data, off+16, b.nextSeq)\n\tbinary.PutLittleEndianUint32(b.data, off+24, b.biggest)\n\tbinary.PutLittleEndianUint64(b.data, off+28, b.length)\n}", "func (p *Buffer) Next() (id int, full []byte, val []byte, wt WireType, err error) {\n\tstart := p.index\n\tif start == ulen(p.buf) {\n\t\t// end of buffer\n\t\treturn 0, nil, nil, 0, nil\n\t}\n\n\tvar vi uint64\n\tvi, err = p.DecodeVarint()\n\tif err != nil {\n\t\treturn 0, nil, nil, 0, err\n\t}\n\twt = WireType(vi) & 7\n\tid = int(vi >> 3)\n\n\tval_start := p.index // correct except in the case of WireBytes, where the value starts after the varint byte length\n\n\tswitch wt {\n\tcase WireBytes:\n\t\tval, err = p.DecodeRawBytes()\n\n\tcase WireVarint:\n\t\terr = p.SkipVarint()\n\n\tcase WireFixed32:\n\t\terr = p.SkipFixed(4)\n\n\tcase WireFixed64:\n\t\terr = p.SkipFixed(8)\n\n\tdefault:\n\t\terr = fmt.Errorf(\"protobuf3: unsupported wiretype %d\", int(wt))\n\t}\n\n\tif val == nil {\n\t\tval = p.buf[val_start:p.index:p.index]\n\t} // else val is already set up\n\n\treturn id, p.buf[start:p.index:p.index], val, wt, err\n}" ]
[ "0.64327663", "0.6065965", "0.5938841", "0.5930446", "0.58814", "0.57420343", "0.56903076", "0.55134517", "0.5493611", "0.54920614", "0.5434967", "0.53940076", "0.5355823", "0.5331252", "0.53291017", "0.53227663", "0.5294519", "0.52847886", "0.52817476", "0.52698314", "0.5257352", "0.5248694", "0.52422035", "0.52407455", "0.5239166", "0.52310663", "0.5223177", "0.52153194", "0.5193254", "0.51925313", "0.5190229", "0.5158831", "0.5158346", "0.51423043", "0.51274", "0.5125035", "0.51128435", "0.51071674", "0.5106349", "0.5093516", "0.5092829", "0.50892085", "0.5088171", "0.50783265", "0.5076578", "0.50740874", "0.50699687", "0.5049184", "0.5041723", "0.5036494", "0.50361615", "0.50338656", "0.50320417", "0.5030238", "0.5027376", "0.50198275", "0.5012754", "0.5010058", "0.50084335", "0.50079536", "0.5004138", "0.49936023", "0.49932954", "0.49901545", "0.49871805", "0.4985008", "0.49793822", "0.4975482", "0.49739474", "0.49728462", "0.49728078", "0.49714607", "0.4967535", "0.49637827", "0.49615", "0.49574837", "0.49558467", "0.4955299", "0.4946967", "0.49409303", "0.49350944", "0.493493", "0.49336797", "0.4931858", "0.49274474", "0.4924168", "0.49149293", "0.49137682", "0.49136373", "0.49088612", "0.49060798", "0.49050328", "0.4904419", "0.4899608", "0.48987642", "0.48973107", "0.48971277", "0.48962426", "0.4894596", "0.48942596", "0.48926157" ]
0.0
-1
specify clear values for the color buffers
func ClearColor(red float32, green float32, blue float32, alpha float32) { C.glowClearColor(gpClearColor, (C.GLfloat)(red), (C.GLfloat)(green), (C.GLfloat)(blue), (C.GLfloat)(alpha)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func Clear(r, g, b, a float32) {\n\tgl.ClearColor(r, g, b, a)\n\tgl.Clear(gl.COLOR_BUFFER_BIT)\n}", "func ClearColor(red float32, green float32, blue float32, alpha float32) {\n\tsyscall.Syscall6(gpClearColor, 4, uintptr(math.Float32bits(red)), uintptr(math.Float32bits(green)), uintptr(math.Float32bits(blue)), uintptr(math.Float32bits(alpha)), 0, 0)\n}", "func ClearColor(red float32, green float32, blue float32, alpha float32) {\n C.glowClearColor(gpClearColor, (C.GLfloat)(red), (C.GLfloat)(green), (C.GLfloat)(blue), (C.GLfloat)(alpha))\n}", "func (debugging *debuggingOpenGL) Clear(mask uint32) {\n\tdebugging.recordEntry(\"Clear\", mask)\n\tdebugging.gl.Clear(mask)\n\tdebugging.recordExit(\"Clear\")\n}", "func (native *OpenGL) Clear(mask uint32) {\n\tgl.Clear(mask)\n}", "func Clear(mask uint32) {\n C.glowClear(gpClear, (C.GLbitfield)(mask))\n}", "func (c *Color) Reset() {\n\tc.params = c.params[:0]\n}", "func Clear(mask Enum) {\n\tgl.Clear(uint32(mask))\n}", "func (glx *Context) Clear() {\n\tglx.constants.Clear(glx.constants.COLOR_BUFFER_BIT)\n\tglx.constants.Clear(glx.constants.DEPTH_BUFFER_BIT)\n}", "func ClearColor(red Float, green Float, blue Float, alpha Float) {\n\tcred, _ := (C.GLfloat)(red), cgoAllocsUnknown\n\tcgreen, _ := (C.GLfloat)(green), cgoAllocsUnknown\n\tcblue, _ := (C.GLfloat)(blue), cgoAllocsUnknown\n\tcalpha, _ := (C.GLfloat)(alpha), cgoAllocsUnknown\n\tC.glClearColor(cred, cgreen, cblue, calpha)\n}", "func ClearAccum(red float32, green float32, blue float32, alpha float32) {\n C.glowClearAccum(gpClearAccum, (C.GLfloat)(red), (C.GLfloat)(green), (C.GLfloat)(blue), (C.GLfloat)(alpha))\n}", "func Clear(mask GLbitfield) {\n\tC.glClear(C.GLbitfield(mask))\n}", "func (c *Canvas) Clear(color color.Color) {\n\tc.gf.Dirty()\n\n\trgba := pixel.ToRGBA(color)\n\n\t// color masking\n\trgba = rgba.Mul(pixel.RGBA{\n\t\tR: float64(c.col[0]),\n\t\tG: float64(c.col[1]),\n\t\tB: float64(c.col[2]),\n\t\tA: float64(c.col[3]),\n\t})\n\n\tmainthread.CallNonBlock(func() {\n\t\tc.setGlhfBounds()\n\t\tc.gf.Frame().Begin()\n\t\tglhf.Clear(\n\t\t\tfloat32(rgba.R),\n\t\t\tfloat32(rgba.G),\n\t\t\tfloat32(rgba.B),\n\t\t\tfloat32(rgba.A),\n\t\t)\n\t\tc.gf.Frame().End()\n\t})\n}", "func Clear(mask Bitfield) {\n\tcmask, _ := (C.GLbitfield)(mask), cgoAllocsUnknown\n\tC.glClear(cmask)\n}", "func ClearAccum(red float32, green float32, blue float32, alpha float32) {\n\tsyscall.Syscall6(gpClearAccum, 4, uintptr(math.Float32bits(red)), uintptr(math.Float32bits(green)), uintptr(math.Float32bits(blue)), uintptr(math.Float32bits(alpha)), 0, 0)\n}", "func Clear(l Layer, c color.RGBA) {\n\tFill{Fullscreen, c}.Draw(l)\n}", "func SetClearColor(r uint8, g uint8, b uint8) {\n\n\tgl.ClearColor(gl.Float(r)/255, gl.Float(g)/255, gl.Float(b)/255, 1.0)\n}", "func Clear(mask uint32) {\n\tC.glowClear(gpClear, (C.GLbitfield)(mask))\n}", "func Clear(mask uint32) {\n\tC.glowClear(gpClear, (C.GLbitfield)(mask))\n}", "func (b *Builder) ClearBackbuffer(ctx context.Context) (red, green, blue, black api.CmdID) {\n\tred = b.Add(\n\t\tb.CB.GlClearColor(1.0, 0.0, 0.0, 1.0),\n\t\tb.CB.GlClear(gles.GLbitfield_GL_COLOR_BUFFER_BIT),\n\t) + 1\n\tgreen = b.Add(\n\t\tb.CB.GlClearColor(0.0, 1.0, 0.0, 1.0),\n\t\tb.CB.GlClear(gles.GLbitfield_GL_COLOR_BUFFER_BIT),\n\t) + 1\n\tblue = b.Add(\n\t\tb.CB.GlClearColor(0.0, 0.0, 1.0, 1.0),\n\t\tb.CB.GlClear(gles.GLbitfield_GL_COLOR_BUFFER_BIT),\n\t) + 1\n\tblack = b.Add(\n\t\tb.CB.GlClearColor(0.0, 0.0, 0.0, 1.0),\n\t\tb.CB.GlClear(gles.GLbitfield_GL_COLOR_BUFFER_BIT),\n\t) + 1\n\treturn red, green, blue, black\n}", "func (c *Canvas) Clear() error {\n\tb, err := buffer.New(c.Size())\n\tif err != nil {\n\t\treturn err\n\t}\n\tc.buffer = b\n\treturn nil\n}", "func ClearColor(red GLfloat, green GLfloat, blue GLfloat, alpha GLfloat) {\n\tC.glClearColor(C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))\n}", "func ClearIndex(c float32) {\n C.glowClearIndex(gpClearIndex, (C.GLfloat)(c))\n}", "func ClearColor(red, green, blue, alpha float32) {\n\tgl.ClearColor(red, green, blue, alpha)\n}", "func ClearAccum(red float32, green float32, blue float32, alpha float32) {\n\tC.glowClearAccum(gpClearAccum, (C.GLfloat)(red), (C.GLfloat)(green), (C.GLfloat)(blue), (C.GLfloat)(alpha))\n}", "func (spriteBatch *SpriteBatch) ClearColor() {\n\tspriteBatch.color = []float32{1, 1, 1, 1}\n}", "func (obj *Device) Clear(\n\trects []RECT,\n\tflags uint32,\n\tcolor COLOR,\n\tz float32,\n\tstencil uint32,\n) Error {\n\tvar rectPtr *RECT\n\tif len(rects) > 0 {\n\t\trectPtr = &rects[0]\n\t}\n\tret, _, _ := syscall.Syscall9(\n\t\tobj.vtbl.Clear,\n\t\t7,\n\t\tuintptr(unsafe.Pointer(obj)),\n\t\tuintptr(len(rects)),\n\t\tuintptr(unsafe.Pointer(rectPtr)),\n\t\tuintptr(flags),\n\t\tuintptr(color),\n\t\tuintptr(math.Float32bits(z)),\n\t\tuintptr(stencil),\n\t\t0,\n\t\t0,\n\t)\n\treturn toErr(ret)\n}", "func (f *Framebuffer) Clear(m gfx.ClearMask) {\n\tvar mask int\n\tif m&gfx.ColorBuffer != 0 {\n\t\tmask |= f.ctx.COLOR_BUFFER_BIT\n\t}\n\tif m&gfx.DepthBuffer != 0 {\n\t\tmask |= f.ctx.DEPTH_BUFFER_BIT\n\t}\n\tif m&gfx.StencilBuffer != 0 {\n\t\tmask |= f.ctx.STENCIL_BUFFER_BIT\n\t}\n\n\t// Use this framebuffer's state, and perform the clear operation.\n\tf.useState()\n\tf.ctx.O.Call(\"clear\", mask)\n}", "func (v *Bitmap256) Clear(pos uint8) {\n\tv[pos>>6] &= ^(1 << (pos & 63))\n}", "func (debugging *debuggingOpenGL) ClearColor(red float32, green float32, blue float32, alpha float32) {\n\tdebugging.recordEntry(\"ClearColor\", red, green, blue, alpha)\n\tdebugging.gl.ClearColor(red, green, blue, alpha)\n\tdebugging.recordExit(\"ClearColor\")\n}", "func Clear() error {\n\n\tgl.Clear(gl.COLOR_BUFFER_BIT)\n\n\treturn checkForErrors()\n}", "func (gl *WebGL) ClearColor(r, g, b, a float64) {\n\tgl.context.Call(\"clearColor\", float32(r), float32(g), float32(b), float32(a))\n}", "func (r *Render) clear(cursor int) {\n\tr.move(cursor, 0)\n\tr.out.EraseDown()\n}", "func (frac *Fractal) Clear() {\n\tfrac.R = histo.New(frac.Width, frac.Height)\n\tfrac.G = histo.New(frac.Width, frac.Height)\n\tfrac.B = histo.New(frac.Width, frac.Height)\n}", "func (f *Framebuffer) ClearColor(r, g, b, a float32) gfx.FramebufferStateValue {\n\treturn s.CSV{\n\t\tValue: [4]float32{r, g, b, a},\n\t\tDefaultValue: [4]float32{0, 0, 0, 0}, // TODO(slimsag): verify\n\t\tKey: csClearColor,\n\t\tGLCall: f.ctx.glClearColor,\n\t}\n}", "func ClearBufferData(target uint32, internalformat uint32, format uint32, xtype uint32, data unsafe.Pointer) {\n C.glowClearBufferData(gpClearBufferData, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLenum)(format), (C.GLenum)(xtype), data)\n}", "func (ctl *Controller) Clear() {\n\tfor i := 0; i < ctl.count; i++ {\n\t\tctl.SetColour(i, Off)\n\t}\n}", "func ClearBufferData(target uint32, internalformat uint32, format uint32, xtype uint32, data unsafe.Pointer) {\n\tC.glowClearBufferData(gpClearBufferData, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLenum)(format), (C.GLenum)(xtype), data)\n}", "func ClearBufferData(target uint32, internalformat uint32, format uint32, xtype uint32, data unsafe.Pointer) {\n\tC.glowClearBufferData(gpClearBufferData, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLenum)(format), (C.GLenum)(xtype), data)\n}", "func (native *OpenGL) ClearColor(red float32, green float32, blue float32, alpha float32) {\n\tgl.ClearColor(red, green, blue, alpha)\n}", "func (b *Buffer) Clear() {\n\tfor o := range b.Tiles {\n\t\tb.Tiles[o] = nil\n\t}\n}", "func (n *saturationDegreeIterator) Reset() { panic(\"coloring: invalid call to Reset\") }", "func (w *Window) Clear() {\n\tfor i, _ := range w.tex {\n\t\tw.tex[i] = 0\n\t}\n}", "func Clear() {\n\tfor i := 0; i < bufferLength; i++ {\n\t\tbuffer[i] = 0x00\n\t}\n}", "func (pw *PixelWand) Clear() {\n\tC.ClearPixelWand(pw.pw)\n\truntime.KeepAlive(pw)\n}", "func (gl *WebGL) Clear(option GLEnum) {\n\tgl.context.Call(\"clear\", option)\n}", "func (d *Driver) Clear() {\n\tfor i := 0; i < len(d.buff); i++ {\n\t\td.buff[i] = 0\n\t}\n}", "func (d *Display) resetBuffer() {\n\td.width = d.device.Width()\n\td.height = d.device.Height()\n\td.buffer = make([][]byte, d.height)\n\tfor y := range d.buffer {\n\t\td.buffer[y] = make([]byte, d.width)\n\t}\n}", "func ClearIndex(c float32) {\n\tC.glowClearIndex(gpClearIndex, (C.GLfloat)(c))\n}", "func ClearBlueSky() Color {\n\treturn Color{R: 64, G: 156, B: 255, W: 0}\n}", "func (pi *PixelIterator) Clear() {\n\tC.ClearPixelIterator(pi.pi)\n\truntime.KeepAlive(pi)\n}", "func (b *Buffer) Clear() {\n\tb.series = make(map[string]*influxdb.Series)\n\tb.size = 0\n}", "func (c *ChromaHighlight) ClrBuffer() {\n\tswitch c.srcBuff {\n\tcase nil:\n\t\tc.txtBuff.Delete(c.txtBuff.GetStartIter(), c.txtBuff.GetEndIter())\n\tdefault:\n\t\tc.srcBuff.Delete(c.srcBuff.GetStartIter(), c.srcBuff.GetEndIter())\n\t}\n}", "func Clear(mask uint32) {\n\tsyscall.Syscall(gpClear, 1, uintptr(mask), 0, 0)\n}", "func ClearBufferData(target uint32, internalformat uint32, format uint32, xtype uint32, data unsafe.Pointer) {\n\tsyscall.Syscall6(gpClearBufferData, 5, uintptr(target), uintptr(internalformat), uintptr(format), uintptr(xtype), uintptr(data), 0)\n}", "func (this *channelStruct) Clear() {\n\tthis.samples = make([]float64, 0)\n}", "func ClearDepth(depth float64) {\n C.glowClearDepth(gpClearDepth, (C.GLdouble)(depth))\n}", "func Unset() {\n\tif NoColor {\n\t\treturn\n\t}\n\n\tOutput.Write(unsafeByteSlice(escapePrefix + Reset.String() + escapeSuffix))\n}", "func ClearBufferSubData(target uint32, internalformat uint32, offset int, size int, format uint32, xtype uint32, data unsafe.Pointer) {\n C.glowClearBufferSubData(gpClearBufferSubData, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLintptr)(offset), (C.GLsizeiptr)(size), (C.GLenum)(format), (C.GLenum)(xtype), data)\n}", "func (c *Canvas) Reset() {\n\tfor y := 0; uint8(y) < canvasHeight; y++ {\n\t\tfor x := 0; uint8(x) < canvasWidth; x++ {\n\t\t\t(*c)[y][x] = 0\n\t\t}\n\t}\n}", "func (d *Display) Clear() {\n\td.sendCommand(0b00000001)\n\ttime.Sleep(10 * time.Millisecond) // long instruction, max 6.2ms\n}", "func (d *Device) ClearDisplay() {\n\td.writeData([]byte{0, 0, 0, 0}, 0)\n}", "func (x *FzColorParams) Free() {\n\tif x != nil {\n\t\tC.free(unsafe.Pointer(x))\n\t}\n}", "func (g *gfx) ClearPixel(x, y int) {\n\tg[x][y] = COLOR_BLACK\n}", "func ClearBufferSubData(target uint32, internalformat uint32, offset int, size int, format uint32, xtype uint32, data unsafe.Pointer) {\n\tC.glowClearBufferSubData(gpClearBufferSubData, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLintptr)(offset), (C.GLsizeiptr)(size), (C.GLenum)(format), (C.GLenum)(xtype), data)\n}", "func ClearBufferSubData(target uint32, internalformat uint32, offset int, size int, format uint32, xtype uint32, data unsafe.Pointer) {\n\tC.glowClearBufferSubData(gpClearBufferSubData, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLintptr)(offset), (C.GLsizeiptr)(size), (C.GLenum)(format), (C.GLenum)(xtype), data)\n}", "func clearScreen() {\n\tfmt.Print(\"\\x1b[2J\")\n}", "func Color(foreColor, backColor, mode gb.UINT8) {}", "func ClearScreen() {\n\temitEscape(\"J\", 2)\n}", "func (rb *RingBuffer[T]) Clear() {\n\trb.mu.Lock()\n\tdefer rb.mu.Unlock()\n\trb.pos = 0\n\trb.buf = nil\n}", "func (NilUGauge) Clear() uint64 { return 0 }", "func (mc *MultiCursor) Clear() {\n\tmc.cursors = mc.cursors[0:1]\n}", "func ClearScreen() {\n\tfmt.Printf(CSI+EraseDisplaySeq, 2)\n\tMoveCursor(1, 1)\n}", "func (ld *LEDraw) Clear() {\n\tif ld.Image == nil {\n\t\tld.Init()\n\t}\n\tld.Paint.Clear(&ld.Render)\n}", "func (display smallEpd) Clear() (err error) {\n\tlog.Debug(\"EPD42 Clear\")\n\n\tif err = display.sendCommand(DATA_START_TRANSMISSION_1); err != nil {\n\t\treturn\n\t}\n\n\t// TODO: Verify that this is enough bits\n\tfor i := 0; i < display.Width()*display.Height()/8; i++ {\n\t\tif err = display.sendData([]byte{0xFF}); err != nil {\n\t\t\treturn\n\t\t}\n\t}\n\n\tif err = display.sendCommand(DATA_START_TRANSMISSION_2); err != nil {\n\t\treturn\n\t}\n\n\tfor i := 0; i < display.Width()*display.Height()/8; i++ {\n\t\tif err = display.sendData([]byte{0xFF}); err != nil {\n\t\t\treturn\n\t\t}\n\t}\n\n\tif err = display.sendCommand(DISPLAY_REFRESH); err != nil {\n\t\treturn\n\t}\n\n\tif err = display.waitUntilIdle(); err != nil {\n\t\treturn\n\t}\n\n\tlog.Debug(\"EPD42 Clear End\")\n\treturn\n}", "func (i *ImageBuf) Clear() {\n\tif i.ptr == nil {\n\t\treturn\n\t}\n\tC.ImageBuf_clear(i.ptr)\n\truntime.KeepAlive(i)\n}", "func Clear(rect ...int) {\n\n\toffX, offY, w, h := 0, 0, width, height\n\n\tif len(rect) == 4 {\n\t\toffX, offY, w, h = rect[0], rect[1], rect[2], rect[3]\n\t}\n\n\tfor i := 0; i < w*h; i++ {\n\t\tx := offX + i%w\n\t\ty := offY + i/w\n\t\tgrid[y*width+x].Clear()\n\t}\n}", "func (g *gfx) Cls() {\n\tfor i := 0; i < 64; i++ {\n\t\tfor j := 0; j < 32; j++ {\n\t\t\tg.ClearPixel(i, j)\n\t\t}\n\t}\n}", "func InvalidateBufferData(buffer uint32) {\n C.glowInvalidateBufferData(gpInvalidateBufferData, (C.GLuint)(buffer))\n}", "func (b *Buffer) ClearMatches() {\n\tfor i := range b.lines {\n\t\tb.SetMatch(i, nil)\n\t\tb.SetState(i, nil)\n\t}\n}", "func (i *Input) Clear() {\n\ti.Pos = 0\n\ti.Buffer = NewLine()\n}", "func (o *Plotter) set_default_clr_mrk() {\n\tif o.ClrPC == \"\" {\n\t\to.ClrPC = \"#85b9ff\"\n\t}\n\tif o.ArrWid == 0 {\n\t\to.ArrWid = 10\n\t}\n\tif o.Clr == \"\" {\n\t\to.Clr = \"red\"\n\t}\n\tif o.Mrk == \"\" {\n\t\to.Mrk = \"\"\n\t}\n\tif o.Ls == \"\" {\n\t\to.Ls = \"-\"\n\t}\n\tif o.LsAlt == \"\" {\n\t\to.LsAlt = \"--\"\n\t}\n\tif o.SpMrk == \"\" {\n\t\to.SpMrk = \".\"\n\t}\n\tif o.EpMrk == \"\" {\n\t\to.EpMrk = \"o\"\n\t}\n\tif o.SpClr == \"\" {\n\t\to.SpClr = \"black\"\n\t}\n\tif o.EpClr == \"\" {\n\t\to.EpClr = \"black\"\n\t}\n\tif o.SpMs == 0 {\n\t\to.SpMs = 3\n\t}\n\tif o.EpMs == 0 {\n\t\to.EpMs = 3\n\t}\n\tif o.YsClr0 == \"\" {\n\t\to.YsClr0 = \"green\"\n\t}\n\tif o.YsClr1 == \"\" {\n\t\to.YsClr1 = \"cyan\"\n\t}\n\tif o.YsLs0 == \"\" {\n\t\to.YsLs0 = \"-\"\n\t}\n\tif o.YsLs1 == \"\" {\n\t\to.YsLs1 = \"--\"\n\t}\n\tif o.YsLw0 < 0.1 {\n\t\to.YsLw0 = 0.7\n\t}\n\tif o.YsLw1 < 0.1 {\n\t\to.YsLw1 = 0.7\n\t}\n}", "func ClearStencil(s int32) {\n C.glowClearStencil(gpClearStencil, (C.GLint)(s))\n}", "func (self *nativePduBuffer) Clear() {\n\tself.start = 0\n\tself.count = 0\n}", "func (console *testConsole) Clear() {\n\tconsole.bufMx.Lock()\n\tconsole.buf = console.buf[:0]\n\tconsole.bufMx.Unlock()\n}", "func (win *Window) Fill(c color.Color) {\n\tC.sfRenderWindow_clear(win.win, sfmlColor(c))\n}", "func (t *FileTarget) clearBuffer() {\n\tfor {\n\t\tselect {\n\t\tcase <-t.tick.C:\n\t\t\t_ = t.writer.Flush()\n\t\t}\n\t}\n}", "func (x *Secp256k1N) Clear() {\n\tx.limbs[0] = 0\n\tx.limbs[1] = 0\n\tx.limbs[2] = 0\n\tx.limbs[3] = 0\n\tx.limbs[4] = 0\n}", "func (b *Buffer) Clear() {\n\tb.mu.Lock()\n\tdefer b.mu.Unlock()\n\tif err := b.flushAll(); err != nil {\n\t\tb.logger.ErrorContext(context.Background(), `k-stream.changelog.buffer`, err)\n\t}\n\n}", "func ClearStencil(s int32) {\n\tsyscall.Syscall(gpClearStencil, 1, uintptr(s), 0, 0)\n}", "func (s *Screen) ClearToCursor(bos bool) {\n\tif !bos {\n\t\tfmt.Fprint(s.Terminal, \"\\x1b[1K\")\n\t} else {\n\t\tfmt.Fprint(s.Terminal, \"\\x1b[1J\")\n\t}\n}", "func (pb *PacketBuffer) Clear() {\n\tpb.numPackets = 0\n\tpb.offsets[0] = 0\n}", "func (c Color) Clearer(pct float32) Color {\n\tf32 := NRGBAf32Model.Convert(c).(NRGBAf32)\n\tf32.A -= pct / 100\n\tf32.A = mat32.Clamp(f32.A, 0, 1)\n\treturn ColorModel.Convert(f32).(Color)\n}", "func Clear() {\n\tprint(\"\\033[H\\033[2J\")\n}", "func (imd *IMDraw) Reset() {\n\timd.points = imd.points[:0]\n\timd.Color = pixel.Alpha(1)\n\timd.Picture = pixel.ZV\n\timd.Intensity = 0\n\timd.Precision = 64\n\timd.EndShape = NoEndShape\n}", "func (spriteBatch *SpriteBatch) Clear() {\n\tspriteBatch.arrayBuf = newVertexBuffer(spriteBatch.size*4*8, []float32{}, spriteBatch.usage)\n\tspriteBatch.count = 0\n}", "func (b *Buffer) Reset() {\n\tb.Line = b.Line[:0]\n\tb.Val = b.Val[:0]\n}", "func Clear() string {\n\treturn csi(\"2J\") + csi(\"H\")\n}", "func ClearDepth(depth float64) {\n\tsyscall.Syscall(gpClearDepth, 1, uintptr(math.Float64bits(depth)), 0, 0)\n}" ]
[ "0.68750846", "0.6867058", "0.6803924", "0.67899007", "0.6782192", "0.6766238", "0.6725869", "0.66564834", "0.6638832", "0.66279083", "0.6609465", "0.6559809", "0.6556905", "0.6534886", "0.6451326", "0.6402057", "0.63869715", "0.63792676", "0.63792676", "0.63789874", "0.63727105", "0.63670135", "0.63537145", "0.63453317", "0.6324575", "0.6269932", "0.62634283", "0.6261521", "0.6257223", "0.6252948", "0.62254703", "0.6189583", "0.6183613", "0.6165", "0.61623603", "0.61236763", "0.60936147", "0.6065815", "0.6065815", "0.60619193", "0.6009263", "0.6000688", "0.60006183", "0.59936893", "0.59746194", "0.59074", "0.5883756", "0.58656615", "0.58552957", "0.58439046", "0.582749", "0.58266747", "0.58201104", "0.58082074", "0.5807411", "0.57846963", "0.57715386", "0.57588494", "0.57549655", "0.5745524", "0.57421905", "0.5733845", "0.56881934", "0.56575966", "0.5652059", "0.5652059", "0.56475073", "0.56388015", "0.56360924", "0.5634598", "0.5631466", "0.56101155", "0.5608422", "0.55881065", "0.5584652", "0.5582524", "0.5576474", "0.5566083", "0.5565149", "0.55543655", "0.554981", "0.554392", "0.55398023", "0.55310124", "0.55260676", "0.5516877", "0.55074936", "0.5504898", "0.54969615", "0.5469602", "0.54663086", "0.546059", "0.5460351", "0.5459541", "0.5450691", "0.5439276", "0.54380924", "0.5433277", "0.5431696" ]
0.6449455
16
specify the clear value for the depth buffer
func ClearDepth(depth float64) { C.glowClearDepth(gpClearDepth, (C.GLdouble)(depth)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func ClearDepth(depth float64) {\n\tsyscall.Syscall(gpClearDepth, 1, uintptr(math.Float64bits(depth)), 0, 0)\n}", "func ClearDepth(depth float64) {\n C.glowClearDepth(gpClearDepth, (C.GLdouble)(depth))\n}", "func ClearDepthf(d float32) {\n\tsyscall.Syscall(gpClearDepthf, 1, uintptr(math.Float32bits(d)), 0, 0)\n}", "func ClearDepthf(d float32) {\n\tC.glowClearDepthf(gpClearDepthf, (C.GLfloat)(d))\n}", "func ClearDepthf(d float32) {\n\tC.glowClearDepthf(gpClearDepthf, (C.GLfloat)(d))\n}", "func (gl *WebGL) ClearDepth(depth float64) {\n\tgl.context.Call(\"clearDepth\", float32(depth))\n}", "func (f *Framebuffer) ClearDepth(depth float64) gfx.FramebufferStateValue {\n\treturn s.CSV{\n\t\tValue: depth,\n\t\tDefaultValue: 0, // TODO(slimsag): verify\n\t\tKey: csClearDepth,\n\t\tGLCall: f.ctx.glClearDepth,\n\t}\n}", "func ClearDepthf(d float32) {\n\tgl.ClearDepthf(d)\n}", "func (debugging *debuggingOpenGL) Clear(mask uint32) {\n\tdebugging.recordEntry(\"Clear\", mask)\n\tdebugging.gl.Clear(mask)\n\tdebugging.recordExit(\"Clear\")\n}", "func Clear(mask uint32) {\n C.glowClear(gpClear, (C.GLbitfield)(mask))\n}", "func ClearDepthf(d Float) {\n\tcd, _ := (C.GLfloat)(d), cgoAllocsUnknown\n\tC.glClearDepthf(cd)\n}", "func (f *Framebuffer) Clear(m gfx.ClearMask) {\n\tvar mask int\n\tif m&gfx.ColorBuffer != 0 {\n\t\tmask |= f.ctx.COLOR_BUFFER_BIT\n\t}\n\tif m&gfx.DepthBuffer != 0 {\n\t\tmask |= f.ctx.DEPTH_BUFFER_BIT\n\t}\n\tif m&gfx.StencilBuffer != 0 {\n\t\tmask |= f.ctx.STENCIL_BUFFER_BIT\n\t}\n\n\t// Use this framebuffer's state, and perform the clear operation.\n\tf.useState()\n\tf.ctx.O.Call(\"clear\", mask)\n}", "func Clear(mask Enum) {\n\tgl.Clear(uint32(mask))\n}", "func ClearIndex(c float32) {\n C.glowClearIndex(gpClearIndex, (C.GLfloat)(c))\n}", "func Clear(mask Bitfield) {\n\tcmask, _ := (C.GLbitfield)(mask), cgoAllocsUnknown\n\tC.glClear(cmask)\n}", "func (native *OpenGL) Clear(mask uint32) {\n\tgl.Clear(mask)\n}", "func (dev *Device) SetDepthBuffer(buf unsafe.Pointer) int {\n\treturn int(C.freenect_set_depth_buffer(dev.ptr(), buf))\n}", "func (frac *Fractal) Clear() {\n\tfrac.R = histo.New(frac.Width, frac.Height)\n\tfrac.G = histo.New(frac.Width, frac.Height)\n\tfrac.B = histo.New(frac.Width, frac.Height)\n}", "func Clear(mask GLbitfield) {\n\tC.glClear(C.GLbitfield(mask))\n}", "func (glx *Context) Clear() {\n\tglx.constants.Clear(glx.constants.COLOR_BUFFER_BIT)\n\tglx.constants.Clear(glx.constants.DEPTH_BUFFER_BIT)\n}", "func (gl *WebGL) Clear(option GLEnum) {\n\tgl.context.Call(\"clear\", option)\n}", "func (d *Driver) Clear() {\n\tfor i := 0; i < len(d.buff); i++ {\n\t\td.buff[i] = 0\n\t}\n}", "func (this *channelStruct) Clear() {\n\tthis.samples = make([]float64, 0)\n}", "func Clear(mask uint32) {\n\tC.glowClear(gpClear, (C.GLbitfield)(mask))\n}", "func Clear(mask uint32) {\n\tC.glowClear(gpClear, (C.GLbitfield)(mask))\n}", "func (c *Canvas) Clear() error {\n\tb, err := buffer.New(c.Size())\n\tif err != nil {\n\t\treturn err\n\t}\n\tc.buffer = b\n\treturn nil\n}", "func (r *Render) clear(cursor int) {\n\tr.move(cursor, 0)\n\tr.out.EraseDown()\n}", "func (b *Buffer) Clear() {\n\tfor o := range b.Tiles {\n\t\tb.Tiles[o] = nil\n\t}\n}", "func Clear(l Layer, c color.RGBA) {\n\tFill{Fullscreen, c}.Draw(l)\n}", "func (NilUGauge) Clear() uint64 { return 0 }", "func (obj *Device) Clear(\n\trects []RECT,\n\tflags uint32,\n\tcolor COLOR,\n\tz float32,\n\tstencil uint32,\n) Error {\n\tvar rectPtr *RECT\n\tif len(rects) > 0 {\n\t\trectPtr = &rects[0]\n\t}\n\tret, _, _ := syscall.Syscall9(\n\t\tobj.vtbl.Clear,\n\t\t7,\n\t\tuintptr(unsafe.Pointer(obj)),\n\t\tuintptr(len(rects)),\n\t\tuintptr(unsafe.Pointer(rectPtr)),\n\t\tuintptr(flags),\n\t\tuintptr(color),\n\t\tuintptr(math.Float32bits(z)),\n\t\tuintptr(stencil),\n\t\t0,\n\t\t0,\n\t)\n\treturn toErr(ret)\n}", "func (rb *RingBuffer[T]) Clear() {\n\trb.mu.Lock()\n\tdefer rb.mu.Unlock()\n\trb.pos = 0\n\trb.buf = nil\n}", "func ClearAccum(red float32, green float32, blue float32, alpha float32) {\n C.glowClearAccum(gpClearAccum, (C.GLfloat)(red), (C.GLfloat)(green), (C.GLfloat)(blue), (C.GLfloat)(alpha))\n}", "func (s *StackF64) clear() {\n\tfor i := 0; i < len(s.data); i++ {\n\t\ts.data[i] = 0\n\t}\n}", "func ClearIndex(c float32) {\n\tC.glowClearIndex(gpClearIndex, (C.GLfloat)(c))\n}", "func (t *RedBlackTree) Clear() {\n\tt.root = nil\n\tt.min = nil\n\tt.max = nil\n\tt.size = 0\n}", "func (self *nativePduBuffer) Clear() {\n\tself.start = 0\n\tself.count = 0\n}", "func (pb *PacketBuffer) Clear() {\n\tpb.numPackets = 0\n\tpb.offsets[0] = 0\n}", "func DepthMask(flag bool) {\n C.glowDepthMask(gpDepthMask, (C.GLboolean)(boolToInt(flag)))\n}", "func (pw *PixelWand) Clear() {\n\tC.ClearPixelWand(pw.pw)\n\truntime.KeepAlive(pw)\n}", "func Clear(mask uint32) {\n\tsyscall.Syscall(gpClear, 1, uintptr(mask), 0, 0)\n}", "func (channelTree *ChannelTree) Clear() {\n\tchannelTree.channelStates = make(map[*tview.TreeNode]channelState)\n\tchannelTree.channelPosition = make(map[string]int)\n\tchannelTree.GetRoot().ClearChildren()\n}", "func (r *Ring) Clear() {\n\tr.size, r.in, r.out = 0, 0, 0\n}", "func (d *Display) Clear() {\n\td.sendCommand(0b00000001)\n\ttime.Sleep(10 * time.Millisecond) // long instruction, max 6.2ms\n}", "func (b *FixedBuffer) Reset() {\n\tb.w = 0\n\tb.r = 0\n}", "func (v *Bitmap256) Clear(pos uint8) {\n\tv[pos>>6] &= ^(1 << (pos & 63))\n}", "func (d *Display) resetBuffer() {\n\td.width = d.device.Width()\n\td.height = d.device.Height()\n\td.buffer = make([][]byte, d.height)\n\tfor y := range d.buffer {\n\t\td.buffer[y] = make([]byte, d.width)\n\t}\n}", "func Clear(r, g, b, a float32) {\n\tgl.ClearColor(r, g, b, a)\n\tgl.Clear(gl.COLOR_BUFFER_BIT)\n}", "func (n *Node) Clear() {\n\n}", "func (c *Color) Reset() {\n\tc.params = c.params[:0]\n}", "func (x *fastReflection_DenomUnit) Clear(fd protoreflect.FieldDescriptor) {\n\tswitch fd.FullName() {\n\tcase \"cosmos.bank.v1beta1.DenomUnit.denom\":\n\t\tx.Denom = \"\"\n\tcase \"cosmos.bank.v1beta1.DenomUnit.exponent\":\n\t\tx.Exponent = uint32(0)\n\tcase \"cosmos.bank.v1beta1.DenomUnit.aliases\":\n\t\tx.Aliases = nil\n\tdefault:\n\t\tif fd.IsExtension() {\n\t\t\tpanic(fmt.Errorf(\"proto3 declared messages do not support extensions: cosmos.bank.v1beta1.DenomUnit\"))\n\t\t}\n\t\tpanic(fmt.Errorf(\"message cosmos.bank.v1beta1.DenomUnit does not contain field %s\", fd.FullName()))\n\t}\n}", "func (c *Canvas) Clear(color color.Color) {\n\tc.gf.Dirty()\n\n\trgba := pixel.ToRGBA(color)\n\n\t// color masking\n\trgba = rgba.Mul(pixel.RGBA{\n\t\tR: float64(c.col[0]),\n\t\tG: float64(c.col[1]),\n\t\tB: float64(c.col[2]),\n\t\tA: float64(c.col[3]),\n\t})\n\n\tmainthread.CallNonBlock(func() {\n\t\tc.setGlhfBounds()\n\t\tc.gf.Frame().Begin()\n\t\tglhf.Clear(\n\t\t\tfloat32(rgba.R),\n\t\t\tfloat32(rgba.G),\n\t\t\tfloat32(rgba.B),\n\t\t\tfloat32(rgba.A),\n\t\t)\n\t\tc.gf.Frame().End()\n\t})\n}", "func (t *FileTarget) clearBuffer() {\n\tfor {\n\t\tselect {\n\t\tcase <-t.tick.C:\n\t\t\t_ = t.writer.Flush()\n\t\t}\n\t}\n}", "func (f *fragment) clearValue(columnID uint64, bitDepth uint, value int64) (changed bool, err error) {\n\treturn f.setValueBase(columnID, bitDepth, value, true)\n}", "func ClearStencil(s int32) {\n\tsyscall.Syscall(gpClearStencil, 1, uintptr(s), 0, 0)\n}", "func (console *testConsole) Clear() {\n\tconsole.bufMx.Lock()\n\tconsole.buf = console.buf[:0]\n\tconsole.bufMx.Unlock()\n}", "func (b *Buffer) Clear() {\n\tb.series = make(map[string]*influxdb.Series)\n\tb.size = 0\n}", "func ClearAccum(red float32, green float32, blue float32, alpha float32) {\n\tC.glowClearAccum(gpClearAccum, (C.GLfloat)(red), (C.GLfloat)(green), (C.GLfloat)(blue), (C.GLfloat)(alpha))\n}", "func (b *Buffer) Clear() {\n\tb.currentSize = 0\n\tb.contents = map[entity.Key]inventoryapi.PostDeltaBody{}\n}", "func DepthMask(flag bool) {\n\tgl.DepthMask(flag)\n}", "func Clear() {\n\tfor i := 0; i < bufferLength; i++ {\n\t\tbuffer[i] = 0x00\n\t}\n}", "func (b *Buffer) Reset() {\n b.size = 0\n b.offset = 0\n}", "func (i *Input) Clear() {\n\ti.Pos = 0\n\ti.Buffer = NewLine()\n}", "func DepthMask(flag bool) {\n\tC.glDepthMask(glBool(flag))\n}", "func (n *saturationDegreeIterator) Reset() { panic(\"coloring: invalid call to Reset\") }", "func ClearColor(red float32, green float32, blue float32, alpha float32) {\n C.glowClearColor(gpClearColor, (C.GLfloat)(red), (C.GLfloat)(green), (C.GLfloat)(blue), (C.GLfloat)(alpha))\n}", "func (x *Secp256k1N) Clear() {\n\tx.limbs[0] = 0\n\tx.limbs[1] = 0\n\tx.limbs[2] = 0\n\tx.limbs[3] = 0\n\tx.limbs[4] = 0\n}", "func (gdt *Array) Clear() {\n\targ0 := gdt.getBase()\n\n\tC.go_godot_array_clear(GDNative.api, arg0)\n}", "func DepthMask(flag Boolean) {\n\tcflag, _ := (C.GLboolean)(flag), cgoAllocsUnknown\n\tC.glDepthMask(cflag)\n}", "func (tv *TextView) Clear() {\n\tif tv.Buf == nil {\n\t\treturn\n\t}\n\ttv.Buf.New(0)\n}", "func (tree *Tree) Clear() {\n\ttree.Root = nil\n\ttree.size = 0\n}", "func (b *Buffer) Reset() {\n\tb.Line = b.Line[:0]\n\tb.Val = b.Val[:0]\n}", "func (b *Buffer) ClearTo(o int) {\n\tfor o = calc.MinInt(o, len(b.Tiles)); o >= 0; o-- {\n\t\tb.Tiles[o] = nil\n\t}\n}", "func ClearStencil(s int32) {\n C.glowClearStencil(gpClearStencil, (C.GLint)(s))\n}", "func (t *RbTree[K, V]) Clear() {\n\tt.root = nil\n\tt.size = 0\n}", "func ClearBufferData(target uint32, internalformat uint32, format uint32, xtype uint32, data unsafe.Pointer) {\n C.glowClearBufferData(gpClearBufferData, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLenum)(format), (C.GLenum)(xtype), data)\n}", "func (imd *IMDraw) Clear() {\n\timd.tri.SetLen(0)\n\timd.batch.Dirty()\n}", "func ClearAccum(red float32, green float32, blue float32, alpha float32) {\n\tsyscall.Syscall6(gpClearAccum, 4, uintptr(math.Float32bits(red)), uintptr(math.Float32bits(green)), uintptr(math.Float32bits(blue)), uintptr(math.Float32bits(alpha)), 0, 0)\n}", "func (w *Window) Clear() {\n\tfor i, _ := range w.tex {\n\t\tw.tex[i] = 0\n\t}\n}", "func ClearIndex(c float32) {\n\tsyscall.Syscall(gpClearIndex, 1, uintptr(math.Float32bits(c)), 0, 0)\n}", "func (native *OpenGL) DepthMask(mask bool) {\n\tgl.DepthMask(mask)\n}", "func Clearslim(n *Node)", "func (ds *Dataset) Clear() {\n\tds.min = math.MaxFloat64\n\tds.max = math.SmallestNonzeroFloat64\n\tds.product = 1\n\tds.total = 0\n\tds.recipsum = 0\n\tds.values = ds.values[:0]\n}", "func (imd *IMDraw) Reset() {\n\timd.points = imd.points[:0]\n\timd.Color = pixel.Alpha(1)\n\timd.Picture = pixel.ZV\n\timd.Intensity = 0\n\timd.Precision = 64\n\timd.EndShape = NoEndShape\n}", "func (x *fastReflection_FlagOptions) Clear(fd protoreflect.FieldDescriptor) {\n\tswitch fd.FullName() {\n\tcase \"cosmos.autocli.v1.FlagOptions.name\":\n\t\tx.Name = \"\"\n\tcase \"cosmos.autocli.v1.FlagOptions.shorthand\":\n\t\tx.Shorthand = \"\"\n\tcase \"cosmos.autocli.v1.FlagOptions.usage\":\n\t\tx.Usage = \"\"\n\tcase \"cosmos.autocli.v1.FlagOptions.default_value\":\n\t\tx.DefaultValue = \"\"\n\tcase \"cosmos.autocli.v1.FlagOptions.deprecated\":\n\t\tx.Deprecated = \"\"\n\tcase \"cosmos.autocli.v1.FlagOptions.shorthand_deprecated\":\n\t\tx.ShorthandDeprecated = \"\"\n\tcase \"cosmos.autocli.v1.FlagOptions.hidden\":\n\t\tx.Hidden = false\n\tdefault:\n\t\tif fd.IsExtension() {\n\t\t\tpanic(fmt.Errorf(\"proto3 declared messages do not support extensions: cosmos.autocli.v1.FlagOptions\"))\n\t\t}\n\t\tpanic(fmt.Errorf(\"message cosmos.autocli.v1.FlagOptions does not contain field %s\", fd.FullName()))\n\t}\n}", "func ClearBufferSubData(target uint32, internalformat uint32, offset int, size int, format uint32, xtype uint32, data unsafe.Pointer) {\n C.glowClearBufferSubData(gpClearBufferSubData, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLintptr)(offset), (C.GLsizeiptr)(size), (C.GLenum)(format), (C.GLenum)(xtype), data)\n}", "func (w *buffer) reset() {\n\tfor i := range (*w)[:cap(*w)] {\n\t\t(*w)[i] = 0\n\t}\n\t*w = (*w)[:0]\n}", "func (w *RootWalker) Clear() {\n\tw.stack = []*objWrap{}\n}", "func (b FormatOption) Clear(flag FormatOption) FormatOption { return b &^ flag }", "func (v *mandelbrotViewer) reset() {\n\tv.redraw = true\n\tv.maxIterations = defaultIterations\n\tv.rMin = rMin\n\tv.rMax = rMax\n\tv.iMin = iMin\n\tv.iMax = iMax\n\tv.zoom = zoom\n}", "func clearLoopLen(b []byte) {\n\tb[0] = 0xf0\n\tb[1] = 0\n}", "func (c *Canvas) Reset() {\n\tfor y := 0; uint8(y) < canvasHeight; y++ {\n\t\tfor x := 0; uint8(x) < canvasWidth; x++ {\n\t\t\t(*c)[y][x] = 0\n\t\t}\n\t}\n}", "func (t *Tree) Clear() {\n\t*t = Tree{}\n}", "func (b *Buf) Reset() { b.b = b.b[:0] }", "func (wv *Spectrum) SetZero() {\n\tfor k := 0; k < 4; k++ {\n\t\twv.C[k] = 0\n\t}\n\n}", "func (q *QuadTree) Clear() {\n\tq.objects = make([]*Rectangle, 0)\n\tfor _, node := range q.nodes {\n\t\tnode.Clear()\n\t}\n\tq.nodes = make(map[int]*QuadTree, 4)\n}", "func (t *T) Clear() {\n\tt.root = nil\n\tt.words = 0\n}", "func DepthMask(flag bool) {\n\tsyscall.Syscall(gpDepthMask, 1, boolToUintptr(flag), 0, 0)\n}", "func (g *GaugeInt64) Clear() {\n\tatomic.StoreInt64(&g.val, 0)\n}" ]
[ "0.75890833", "0.72645503", "0.6958771", "0.6629535", "0.6629535", "0.66152805", "0.6614693", "0.6408458", "0.63807887", "0.63124526", "0.6286633", "0.6259047", "0.62279314", "0.61254436", "0.6097784", "0.60644794", "0.6030776", "0.60261285", "0.6020509", "0.6003938", "0.598665", "0.59376526", "0.5924923", "0.59192103", "0.59192103", "0.59120345", "0.5873365", "0.5850158", "0.58395344", "0.5831722", "0.57954454", "0.57913995", "0.5743282", "0.5720936", "0.5714612", "0.5704691", "0.5703654", "0.56623214", "0.56572866", "0.5623973", "0.56196797", "0.5614962", "0.56081986", "0.55990666", "0.55942875", "0.5591088", "0.55605155", "0.55411917", "0.5535894", "0.5533964", "0.5505422", "0.5493488", "0.54723024", "0.54696405", "0.54689234", "0.54639596", "0.54637295", "0.5457312", "0.54503375", "0.54491246", "0.54481894", "0.54368407", "0.5419412", "0.54191804", "0.5410395", "0.54080683", "0.54075235", "0.54068196", "0.5398636", "0.53902686", "0.53891873", "0.5382545", "0.5376758", "0.5373908", "0.53675365", "0.5350096", "0.53386027", "0.53363085", "0.5324637", "0.53194046", "0.5315946", "0.5304898", "0.5304431", "0.529406", "0.52863497", "0.5282072", "0.5275665", "0.526696", "0.5265039", "0.52641636", "0.52632886", "0.52590317", "0.5254658", "0.5245086", "0.5238329", "0.5231144", "0.52302724", "0.5229807", "0.5224555" ]
0.67747325
4
specify the clear value for the depth buffer
func ClearDepthf(d float32) { C.glowClearDepthf(gpClearDepthf, (C.GLfloat)(d)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func ClearDepth(depth float64) {\n\tsyscall.Syscall(gpClearDepth, 1, uintptr(math.Float64bits(depth)), 0, 0)\n}", "func ClearDepth(depth float64) {\n C.glowClearDepth(gpClearDepth, (C.GLdouble)(depth))\n}", "func ClearDepthf(d float32) {\n\tsyscall.Syscall(gpClearDepthf, 1, uintptr(math.Float32bits(d)), 0, 0)\n}", "func ClearDepth(depth float64) {\n\tC.glowClearDepth(gpClearDepth, (C.GLdouble)(depth))\n}", "func ClearDepth(depth float64) {\n\tC.glowClearDepth(gpClearDepth, (C.GLdouble)(depth))\n}", "func (gl *WebGL) ClearDepth(depth float64) {\n\tgl.context.Call(\"clearDepth\", float32(depth))\n}", "func (f *Framebuffer) ClearDepth(depth float64) gfx.FramebufferStateValue {\n\treturn s.CSV{\n\t\tValue: depth,\n\t\tDefaultValue: 0, // TODO(slimsag): verify\n\t\tKey: csClearDepth,\n\t\tGLCall: f.ctx.glClearDepth,\n\t}\n}", "func ClearDepthf(d float32) {\n\tgl.ClearDepthf(d)\n}", "func (debugging *debuggingOpenGL) Clear(mask uint32) {\n\tdebugging.recordEntry(\"Clear\", mask)\n\tdebugging.gl.Clear(mask)\n\tdebugging.recordExit(\"Clear\")\n}", "func Clear(mask uint32) {\n C.glowClear(gpClear, (C.GLbitfield)(mask))\n}", "func ClearDepthf(d Float) {\n\tcd, _ := (C.GLfloat)(d), cgoAllocsUnknown\n\tC.glClearDepthf(cd)\n}", "func (f *Framebuffer) Clear(m gfx.ClearMask) {\n\tvar mask int\n\tif m&gfx.ColorBuffer != 0 {\n\t\tmask |= f.ctx.COLOR_BUFFER_BIT\n\t}\n\tif m&gfx.DepthBuffer != 0 {\n\t\tmask |= f.ctx.DEPTH_BUFFER_BIT\n\t}\n\tif m&gfx.StencilBuffer != 0 {\n\t\tmask |= f.ctx.STENCIL_BUFFER_BIT\n\t}\n\n\t// Use this framebuffer's state, and perform the clear operation.\n\tf.useState()\n\tf.ctx.O.Call(\"clear\", mask)\n}", "func Clear(mask Enum) {\n\tgl.Clear(uint32(mask))\n}", "func ClearIndex(c float32) {\n C.glowClearIndex(gpClearIndex, (C.GLfloat)(c))\n}", "func Clear(mask Bitfield) {\n\tcmask, _ := (C.GLbitfield)(mask), cgoAllocsUnknown\n\tC.glClear(cmask)\n}", "func (native *OpenGL) Clear(mask uint32) {\n\tgl.Clear(mask)\n}", "func (dev *Device) SetDepthBuffer(buf unsafe.Pointer) int {\n\treturn int(C.freenect_set_depth_buffer(dev.ptr(), buf))\n}", "func (frac *Fractal) Clear() {\n\tfrac.R = histo.New(frac.Width, frac.Height)\n\tfrac.G = histo.New(frac.Width, frac.Height)\n\tfrac.B = histo.New(frac.Width, frac.Height)\n}", "func Clear(mask GLbitfield) {\n\tC.glClear(C.GLbitfield(mask))\n}", "func (glx *Context) Clear() {\n\tglx.constants.Clear(glx.constants.COLOR_BUFFER_BIT)\n\tglx.constants.Clear(glx.constants.DEPTH_BUFFER_BIT)\n}", "func (gl *WebGL) Clear(option GLEnum) {\n\tgl.context.Call(\"clear\", option)\n}", "func (d *Driver) Clear() {\n\tfor i := 0; i < len(d.buff); i++ {\n\t\td.buff[i] = 0\n\t}\n}", "func (this *channelStruct) Clear() {\n\tthis.samples = make([]float64, 0)\n}", "func Clear(mask uint32) {\n\tC.glowClear(gpClear, (C.GLbitfield)(mask))\n}", "func Clear(mask uint32) {\n\tC.glowClear(gpClear, (C.GLbitfield)(mask))\n}", "func (c *Canvas) Clear() error {\n\tb, err := buffer.New(c.Size())\n\tif err != nil {\n\t\treturn err\n\t}\n\tc.buffer = b\n\treturn nil\n}", "func (r *Render) clear(cursor int) {\n\tr.move(cursor, 0)\n\tr.out.EraseDown()\n}", "func (b *Buffer) Clear() {\n\tfor o := range b.Tiles {\n\t\tb.Tiles[o] = nil\n\t}\n}", "func Clear(l Layer, c color.RGBA) {\n\tFill{Fullscreen, c}.Draw(l)\n}", "func (NilUGauge) Clear() uint64 { return 0 }", "func (obj *Device) Clear(\n\trects []RECT,\n\tflags uint32,\n\tcolor COLOR,\n\tz float32,\n\tstencil uint32,\n) Error {\n\tvar rectPtr *RECT\n\tif len(rects) > 0 {\n\t\trectPtr = &rects[0]\n\t}\n\tret, _, _ := syscall.Syscall9(\n\t\tobj.vtbl.Clear,\n\t\t7,\n\t\tuintptr(unsafe.Pointer(obj)),\n\t\tuintptr(len(rects)),\n\t\tuintptr(unsafe.Pointer(rectPtr)),\n\t\tuintptr(flags),\n\t\tuintptr(color),\n\t\tuintptr(math.Float32bits(z)),\n\t\tuintptr(stencil),\n\t\t0,\n\t\t0,\n\t)\n\treturn toErr(ret)\n}", "func (rb *RingBuffer[T]) Clear() {\n\trb.mu.Lock()\n\tdefer rb.mu.Unlock()\n\trb.pos = 0\n\trb.buf = nil\n}", "func ClearAccum(red float32, green float32, blue float32, alpha float32) {\n C.glowClearAccum(gpClearAccum, (C.GLfloat)(red), (C.GLfloat)(green), (C.GLfloat)(blue), (C.GLfloat)(alpha))\n}", "func (s *StackF64) clear() {\n\tfor i := 0; i < len(s.data); i++ {\n\t\ts.data[i] = 0\n\t}\n}", "func ClearIndex(c float32) {\n\tC.glowClearIndex(gpClearIndex, (C.GLfloat)(c))\n}", "func (t *RedBlackTree) Clear() {\n\tt.root = nil\n\tt.min = nil\n\tt.max = nil\n\tt.size = 0\n}", "func (self *nativePduBuffer) Clear() {\n\tself.start = 0\n\tself.count = 0\n}", "func (pb *PacketBuffer) Clear() {\n\tpb.numPackets = 0\n\tpb.offsets[0] = 0\n}", "func DepthMask(flag bool) {\n C.glowDepthMask(gpDepthMask, (C.GLboolean)(boolToInt(flag)))\n}", "func (pw *PixelWand) Clear() {\n\tC.ClearPixelWand(pw.pw)\n\truntime.KeepAlive(pw)\n}", "func Clear(mask uint32) {\n\tsyscall.Syscall(gpClear, 1, uintptr(mask), 0, 0)\n}", "func (channelTree *ChannelTree) Clear() {\n\tchannelTree.channelStates = make(map[*tview.TreeNode]channelState)\n\tchannelTree.channelPosition = make(map[string]int)\n\tchannelTree.GetRoot().ClearChildren()\n}", "func (r *Ring) Clear() {\n\tr.size, r.in, r.out = 0, 0, 0\n}", "func (d *Display) Clear() {\n\td.sendCommand(0b00000001)\n\ttime.Sleep(10 * time.Millisecond) // long instruction, max 6.2ms\n}", "func (b *FixedBuffer) Reset() {\n\tb.w = 0\n\tb.r = 0\n}", "func (v *Bitmap256) Clear(pos uint8) {\n\tv[pos>>6] &= ^(1 << (pos & 63))\n}", "func (d *Display) resetBuffer() {\n\td.width = d.device.Width()\n\td.height = d.device.Height()\n\td.buffer = make([][]byte, d.height)\n\tfor y := range d.buffer {\n\t\td.buffer[y] = make([]byte, d.width)\n\t}\n}", "func Clear(r, g, b, a float32) {\n\tgl.ClearColor(r, g, b, a)\n\tgl.Clear(gl.COLOR_BUFFER_BIT)\n}", "func (n *Node) Clear() {\n\n}", "func (c *Color) Reset() {\n\tc.params = c.params[:0]\n}", "func (x *fastReflection_DenomUnit) Clear(fd protoreflect.FieldDescriptor) {\n\tswitch fd.FullName() {\n\tcase \"cosmos.bank.v1beta1.DenomUnit.denom\":\n\t\tx.Denom = \"\"\n\tcase \"cosmos.bank.v1beta1.DenomUnit.exponent\":\n\t\tx.Exponent = uint32(0)\n\tcase \"cosmos.bank.v1beta1.DenomUnit.aliases\":\n\t\tx.Aliases = nil\n\tdefault:\n\t\tif fd.IsExtension() {\n\t\t\tpanic(fmt.Errorf(\"proto3 declared messages do not support extensions: cosmos.bank.v1beta1.DenomUnit\"))\n\t\t}\n\t\tpanic(fmt.Errorf(\"message cosmos.bank.v1beta1.DenomUnit does not contain field %s\", fd.FullName()))\n\t}\n}", "func (c *Canvas) Clear(color color.Color) {\n\tc.gf.Dirty()\n\n\trgba := pixel.ToRGBA(color)\n\n\t// color masking\n\trgba = rgba.Mul(pixel.RGBA{\n\t\tR: float64(c.col[0]),\n\t\tG: float64(c.col[1]),\n\t\tB: float64(c.col[2]),\n\t\tA: float64(c.col[3]),\n\t})\n\n\tmainthread.CallNonBlock(func() {\n\t\tc.setGlhfBounds()\n\t\tc.gf.Frame().Begin()\n\t\tglhf.Clear(\n\t\t\tfloat32(rgba.R),\n\t\t\tfloat32(rgba.G),\n\t\t\tfloat32(rgba.B),\n\t\t\tfloat32(rgba.A),\n\t\t)\n\t\tc.gf.Frame().End()\n\t})\n}", "func (t *FileTarget) clearBuffer() {\n\tfor {\n\t\tselect {\n\t\tcase <-t.tick.C:\n\t\t\t_ = t.writer.Flush()\n\t\t}\n\t}\n}", "func (f *fragment) clearValue(columnID uint64, bitDepth uint, value int64) (changed bool, err error) {\n\treturn f.setValueBase(columnID, bitDepth, value, true)\n}", "func ClearStencil(s int32) {\n\tsyscall.Syscall(gpClearStencil, 1, uintptr(s), 0, 0)\n}", "func (b *Buffer) Clear() {\n\tb.series = make(map[string]*influxdb.Series)\n\tb.size = 0\n}", "func (console *testConsole) Clear() {\n\tconsole.bufMx.Lock()\n\tconsole.buf = console.buf[:0]\n\tconsole.bufMx.Unlock()\n}", "func ClearAccum(red float32, green float32, blue float32, alpha float32) {\n\tC.glowClearAccum(gpClearAccum, (C.GLfloat)(red), (C.GLfloat)(green), (C.GLfloat)(blue), (C.GLfloat)(alpha))\n}", "func (b *Buffer) Clear() {\n\tb.currentSize = 0\n\tb.contents = map[entity.Key]inventoryapi.PostDeltaBody{}\n}", "func DepthMask(flag bool) {\n\tgl.DepthMask(flag)\n}", "func Clear() {\n\tfor i := 0; i < bufferLength; i++ {\n\t\tbuffer[i] = 0x00\n\t}\n}", "func (b *Buffer) Reset() {\n b.size = 0\n b.offset = 0\n}", "func (i *Input) Clear() {\n\ti.Pos = 0\n\ti.Buffer = NewLine()\n}", "func DepthMask(flag bool) {\n\tC.glDepthMask(glBool(flag))\n}", "func (n *saturationDegreeIterator) Reset() { panic(\"coloring: invalid call to Reset\") }", "func ClearColor(red float32, green float32, blue float32, alpha float32) {\n C.glowClearColor(gpClearColor, (C.GLfloat)(red), (C.GLfloat)(green), (C.GLfloat)(blue), (C.GLfloat)(alpha))\n}", "func (x *Secp256k1N) Clear() {\n\tx.limbs[0] = 0\n\tx.limbs[1] = 0\n\tx.limbs[2] = 0\n\tx.limbs[3] = 0\n\tx.limbs[4] = 0\n}", "func (gdt *Array) Clear() {\n\targ0 := gdt.getBase()\n\n\tC.go_godot_array_clear(GDNative.api, arg0)\n}", "func DepthMask(flag Boolean) {\n\tcflag, _ := (C.GLboolean)(flag), cgoAllocsUnknown\n\tC.glDepthMask(cflag)\n}", "func (tv *TextView) Clear() {\n\tif tv.Buf == nil {\n\t\treturn\n\t}\n\ttv.Buf.New(0)\n}", "func (tree *Tree) Clear() {\n\ttree.Root = nil\n\ttree.size = 0\n}", "func (b *Buffer) Reset() {\n\tb.Line = b.Line[:0]\n\tb.Val = b.Val[:0]\n}", "func (b *Buffer) ClearTo(o int) {\n\tfor o = calc.MinInt(o, len(b.Tiles)); o >= 0; o-- {\n\t\tb.Tiles[o] = nil\n\t}\n}", "func ClearStencil(s int32) {\n C.glowClearStencil(gpClearStencil, (C.GLint)(s))\n}", "func (t *RbTree[K, V]) Clear() {\n\tt.root = nil\n\tt.size = 0\n}", "func ClearBufferData(target uint32, internalformat uint32, format uint32, xtype uint32, data unsafe.Pointer) {\n C.glowClearBufferData(gpClearBufferData, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLenum)(format), (C.GLenum)(xtype), data)\n}", "func (imd *IMDraw) Clear() {\n\timd.tri.SetLen(0)\n\timd.batch.Dirty()\n}", "func ClearAccum(red float32, green float32, blue float32, alpha float32) {\n\tsyscall.Syscall6(gpClearAccum, 4, uintptr(math.Float32bits(red)), uintptr(math.Float32bits(green)), uintptr(math.Float32bits(blue)), uintptr(math.Float32bits(alpha)), 0, 0)\n}", "func (w *Window) Clear() {\n\tfor i, _ := range w.tex {\n\t\tw.tex[i] = 0\n\t}\n}", "func ClearIndex(c float32) {\n\tsyscall.Syscall(gpClearIndex, 1, uintptr(math.Float32bits(c)), 0, 0)\n}", "func (native *OpenGL) DepthMask(mask bool) {\n\tgl.DepthMask(mask)\n}", "func (ds *Dataset) Clear() {\n\tds.min = math.MaxFloat64\n\tds.max = math.SmallestNonzeroFloat64\n\tds.product = 1\n\tds.total = 0\n\tds.recipsum = 0\n\tds.values = ds.values[:0]\n}", "func Clearslim(n *Node)", "func (imd *IMDraw) Reset() {\n\timd.points = imd.points[:0]\n\timd.Color = pixel.Alpha(1)\n\timd.Picture = pixel.ZV\n\timd.Intensity = 0\n\timd.Precision = 64\n\timd.EndShape = NoEndShape\n}", "func (x *fastReflection_FlagOptions) Clear(fd protoreflect.FieldDescriptor) {\n\tswitch fd.FullName() {\n\tcase \"cosmos.autocli.v1.FlagOptions.name\":\n\t\tx.Name = \"\"\n\tcase \"cosmos.autocli.v1.FlagOptions.shorthand\":\n\t\tx.Shorthand = \"\"\n\tcase \"cosmos.autocli.v1.FlagOptions.usage\":\n\t\tx.Usage = \"\"\n\tcase \"cosmos.autocli.v1.FlagOptions.default_value\":\n\t\tx.DefaultValue = \"\"\n\tcase \"cosmos.autocli.v1.FlagOptions.deprecated\":\n\t\tx.Deprecated = \"\"\n\tcase \"cosmos.autocli.v1.FlagOptions.shorthand_deprecated\":\n\t\tx.ShorthandDeprecated = \"\"\n\tcase \"cosmos.autocli.v1.FlagOptions.hidden\":\n\t\tx.Hidden = false\n\tdefault:\n\t\tif fd.IsExtension() {\n\t\t\tpanic(fmt.Errorf(\"proto3 declared messages do not support extensions: cosmos.autocli.v1.FlagOptions\"))\n\t\t}\n\t\tpanic(fmt.Errorf(\"message cosmos.autocli.v1.FlagOptions does not contain field %s\", fd.FullName()))\n\t}\n}", "func ClearBufferSubData(target uint32, internalformat uint32, offset int, size int, format uint32, xtype uint32, data unsafe.Pointer) {\n C.glowClearBufferSubData(gpClearBufferSubData, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLintptr)(offset), (C.GLsizeiptr)(size), (C.GLenum)(format), (C.GLenum)(xtype), data)\n}", "func (w *buffer) reset() {\n\tfor i := range (*w)[:cap(*w)] {\n\t\t(*w)[i] = 0\n\t}\n\t*w = (*w)[:0]\n}", "func (w *RootWalker) Clear() {\n\tw.stack = []*objWrap{}\n}", "func (v *mandelbrotViewer) reset() {\n\tv.redraw = true\n\tv.maxIterations = defaultIterations\n\tv.rMin = rMin\n\tv.rMax = rMax\n\tv.iMin = iMin\n\tv.iMax = iMax\n\tv.zoom = zoom\n}", "func (b FormatOption) Clear(flag FormatOption) FormatOption { return b &^ flag }", "func clearLoopLen(b []byte) {\n\tb[0] = 0xf0\n\tb[1] = 0\n}", "func (c *Canvas) Reset() {\n\tfor y := 0; uint8(y) < canvasHeight; y++ {\n\t\tfor x := 0; uint8(x) < canvasWidth; x++ {\n\t\t\t(*c)[y][x] = 0\n\t\t}\n\t}\n}", "func (t *Tree) Clear() {\n\t*t = Tree{}\n}", "func (b *Buf) Reset() { b.b = b.b[:0] }", "func (wv *Spectrum) SetZero() {\n\tfor k := 0; k < 4; k++ {\n\t\twv.C[k] = 0\n\t}\n\n}", "func (q *QuadTree) Clear() {\n\tq.objects = make([]*Rectangle, 0)\n\tfor _, node := range q.nodes {\n\t\tnode.Clear()\n\t}\n\tq.nodes = make(map[int]*QuadTree, 4)\n}", "func (t *T) Clear() {\n\tt.root = nil\n\tt.words = 0\n}", "func DepthMask(flag bool) {\n\tsyscall.Syscall(gpDepthMask, 1, boolToUintptr(flag), 0, 0)\n}", "func (g *GaugeInt64) Clear() {\n\tatomic.StoreInt64(&g.val, 0)\n}" ]
[ "0.75885737", "0.72638", "0.69582975", "0.67742234", "0.67742234", "0.66150177", "0.66142136", "0.6408065", "0.63803303", "0.6311345", "0.6286103", "0.62583685", "0.6226915", "0.61234146", "0.60970527", "0.6063397", "0.60306644", "0.6026708", "0.6019697", "0.60041845", "0.59860325", "0.5937975", "0.59250563", "0.59184575", "0.59184575", "0.59115994", "0.58730835", "0.58508176", "0.58379436", "0.5830797", "0.5794835", "0.5792122", "0.57422346", "0.57204753", "0.57129115", "0.5705267", "0.5703906", "0.56634146", "0.56569666", "0.56228954", "0.56185085", "0.5615715", "0.56088924", "0.55985", "0.55946594", "0.55887926", "0.556049", "0.5540739", "0.5535735", "0.5533685", "0.5506096", "0.5493001", "0.54733884", "0.546891", "0.54675233", "0.546431", "0.54642934", "0.54564416", "0.545185", "0.54495627", "0.5448643", "0.5437417", "0.5419608", "0.54195136", "0.5411198", "0.5407134", "0.54066324", "0.540599", "0.5398896", "0.539027", "0.5390154", "0.5382861", "0.53765684", "0.53720844", "0.5368516", "0.5349746", "0.5338759", "0.5335353", "0.5323766", "0.5317603", "0.5316431", "0.53041726", "0.53040427", "0.52940464", "0.52864313", "0.52813137", "0.5274998", "0.5268453", "0.52639174", "0.5263432", "0.52631253", "0.525879", "0.52550024", "0.5244974", "0.52366537", "0.5232835", "0.5231735", "0.5230038", "0.5223766" ]
0.6629029
6
specify the clear value for the color index buffers
func ClearIndex(c float32) { C.glowClearIndex(gpClearIndex, (C.GLfloat)(c)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func ClearIndex(c float32) {\n C.glowClearIndex(gpClearIndex, (C.GLfloat)(c))\n}", "func ClearIndex(c float32) {\n\tsyscall.Syscall(gpClearIndex, 1, uintptr(math.Float32bits(c)), 0, 0)\n}", "func (debugging *debuggingOpenGL) Clear(mask uint32) {\n\tdebugging.recordEntry(\"Clear\", mask)\n\tdebugging.gl.Clear(mask)\n\tdebugging.recordExit(\"Clear\")\n}", "func (v *Bitmap256) Clear(pos uint8) {\n\tv[pos>>6] &= ^(1 << (pos & 63))\n}", "func (native *OpenGL) Clear(mask uint32) {\n\tgl.Clear(mask)\n}", "func Clear(mask uint32) {\n C.glowClear(gpClear, (C.GLbitfield)(mask))\n}", "func Clear(mask Enum) {\n\tgl.Clear(uint32(mask))\n}", "func Clear(mask GLbitfield) {\n\tC.glClear(C.GLbitfield(mask))\n}", "func ClearColor(red float32, green float32, blue float32, alpha float32) {\n C.glowClearColor(gpClearColor, (C.GLfloat)(red), (C.GLfloat)(green), (C.GLfloat)(blue), (C.GLfloat)(alpha))\n}", "func ClearColor(red float32, green float32, blue float32, alpha float32) {\n\tsyscall.Syscall6(gpClearColor, 4, uintptr(math.Float32bits(red)), uintptr(math.Float32bits(green)), uintptr(math.Float32bits(blue)), uintptr(math.Float32bits(alpha)), 0, 0)\n}", "func Clear(mask Bitfield) {\n\tcmask, _ := (C.GLbitfield)(mask), cgoAllocsUnknown\n\tC.glClear(cmask)\n}", "func Clear(r, g, b, a float32) {\n\tgl.ClearColor(r, g, b, a)\n\tgl.Clear(gl.COLOR_BUFFER_BIT)\n}", "func (ctl *Controller) Clear() {\n\tfor i := 0; i < ctl.count; i++ {\n\t\tctl.SetColour(i, Off)\n\t}\n}", "func ClearAccum(red float32, green float32, blue float32, alpha float32) {\n C.glowClearAccum(gpClearAccum, (C.GLfloat)(red), (C.GLfloat)(green), (C.GLfloat)(blue), (C.GLfloat)(alpha))\n}", "func (c *Color) Reset() {\n\tc.params = c.params[:0]\n}", "func (c *Canvas) Clear(color color.Color) {\n\tc.gf.Dirty()\n\n\trgba := pixel.ToRGBA(color)\n\n\t// color masking\n\trgba = rgba.Mul(pixel.RGBA{\n\t\tR: float64(c.col[0]),\n\t\tG: float64(c.col[1]),\n\t\tB: float64(c.col[2]),\n\t\tA: float64(c.col[3]),\n\t})\n\n\tmainthread.CallNonBlock(func() {\n\t\tc.setGlhfBounds()\n\t\tc.gf.Frame().Begin()\n\t\tglhf.Clear(\n\t\t\tfloat32(rgba.R),\n\t\t\tfloat32(rgba.G),\n\t\t\tfloat32(rgba.B),\n\t\t\tfloat32(rgba.A),\n\t\t)\n\t\tc.gf.Frame().End()\n\t})\n}", "func Clear(mask uint32) {\n\tC.glowClear(gpClear, (C.GLbitfield)(mask))\n}", "func Clear(mask uint32) {\n\tC.glowClear(gpClear, (C.GLbitfield)(mask))\n}", "func (n *saturationDegreeIterator) Reset() { panic(\"coloring: invalid call to Reset\") }", "func (r *Render) clear(cursor int) {\n\tr.move(cursor, 0)\n\tr.out.EraseDown()\n}", "func (b *Builder) ClearBackbuffer(ctx context.Context) (red, green, blue, black api.CmdID) {\n\tred = b.Add(\n\t\tb.CB.GlClearColor(1.0, 0.0, 0.0, 1.0),\n\t\tb.CB.GlClear(gles.GLbitfield_GL_COLOR_BUFFER_BIT),\n\t) + 1\n\tgreen = b.Add(\n\t\tb.CB.GlClearColor(0.0, 1.0, 0.0, 1.0),\n\t\tb.CB.GlClear(gles.GLbitfield_GL_COLOR_BUFFER_BIT),\n\t) + 1\n\tblue = b.Add(\n\t\tb.CB.GlClearColor(0.0, 0.0, 1.0, 1.0),\n\t\tb.CB.GlClear(gles.GLbitfield_GL_COLOR_BUFFER_BIT),\n\t) + 1\n\tblack = b.Add(\n\t\tb.CB.GlClearColor(0.0, 0.0, 0.0, 1.0),\n\t\tb.CB.GlClear(gles.GLbitfield_GL_COLOR_BUFFER_BIT),\n\t) + 1\n\treturn red, green, blue, black\n}", "func SetClearColor(r uint8, g uint8, b uint8) {\n\n\tgl.ClearColor(gl.Float(r)/255, gl.Float(g)/255, gl.Float(b)/255, 1.0)\n}", "func ClearAccum(red float32, green float32, blue float32, alpha float32) {\n\tsyscall.Syscall6(gpClearAccum, 4, uintptr(math.Float32bits(red)), uintptr(math.Float32bits(green)), uintptr(math.Float32bits(blue)), uintptr(math.Float32bits(alpha)), 0, 0)\n}", "func ClearColor(red float32, green float32, blue float32, alpha float32) {\n\tC.glowClearColor(gpClearColor, (C.GLfloat)(red), (C.GLfloat)(green), (C.GLfloat)(blue), (C.GLfloat)(alpha))\n}", "func ClearColor(red float32, green float32, blue float32, alpha float32) {\n\tC.glowClearColor(gpClearColor, (C.GLfloat)(red), (C.GLfloat)(green), (C.GLfloat)(blue), (C.GLfloat)(alpha))\n}", "func (glx *Context) Clear() {\n\tglx.constants.Clear(glx.constants.COLOR_BUFFER_BIT)\n\tglx.constants.Clear(glx.constants.DEPTH_BUFFER_BIT)\n}", "func ClearColor(red Float, green Float, blue Float, alpha Float) {\n\tcred, _ := (C.GLfloat)(red), cgoAllocsUnknown\n\tcgreen, _ := (C.GLfloat)(green), cgoAllocsUnknown\n\tcblue, _ := (C.GLfloat)(blue), cgoAllocsUnknown\n\tcalpha, _ := (C.GLfloat)(alpha), cgoAllocsUnknown\n\tC.glClearColor(cred, cgreen, cblue, calpha)\n}", "func (obj *Device) Clear(\n\trects []RECT,\n\tflags uint32,\n\tcolor COLOR,\n\tz float32,\n\tstencil uint32,\n) Error {\n\tvar rectPtr *RECT\n\tif len(rects) > 0 {\n\t\trectPtr = &rects[0]\n\t}\n\tret, _, _ := syscall.Syscall9(\n\t\tobj.vtbl.Clear,\n\t\t7,\n\t\tuintptr(unsafe.Pointer(obj)),\n\t\tuintptr(len(rects)),\n\t\tuintptr(unsafe.Pointer(rectPtr)),\n\t\tuintptr(flags),\n\t\tuintptr(color),\n\t\tuintptr(math.Float32bits(z)),\n\t\tuintptr(stencil),\n\t\t0,\n\t\t0,\n\t)\n\treturn toErr(ret)\n}", "func ClearAccum(red float32, green float32, blue float32, alpha float32) {\n\tC.glowClearAccum(gpClearAccum, (C.GLfloat)(red), (C.GLfloat)(green), (C.GLfloat)(blue), (C.GLfloat)(alpha))\n}", "func (c *Canvas) Clear() error {\n\tb, err := buffer.New(c.Size())\n\tif err != nil {\n\t\treturn err\n\t}\n\tc.buffer = b\n\treturn nil\n}", "func ClearColor(red, green, blue, alpha float32) {\n\tgl.ClearColor(red, green, blue, alpha)\n}", "func (spriteBatch *SpriteBatch) ClearColor() {\n\tspriteBatch.color = []float32{1, 1, 1, 1}\n}", "func (debugging *debuggingOpenGL) ClearColor(red float32, green float32, blue float32, alpha float32) {\n\tdebugging.recordEntry(\"ClearColor\", red, green, blue, alpha)\n\tdebugging.gl.ClearColor(red, green, blue, alpha)\n\tdebugging.recordExit(\"ClearColor\")\n}", "func Clear() {\n\tfor i := 0; i < bufferLength; i++ {\n\t\tbuffer[i] = 0x00\n\t}\n}", "func (f *Framebuffer) ClearColor(r, g, b, a float32) gfx.FramebufferStateValue {\n\treturn s.CSV{\n\t\tValue: [4]float32{r, g, b, a},\n\t\tDefaultValue: [4]float32{0, 0, 0, 0}, // TODO(slimsag): verify\n\t\tKey: csClearColor,\n\t\tGLCall: f.ctx.glClearColor,\n\t}\n}", "func Clear(l Layer, c color.RGBA) {\n\tFill{Fullscreen, c}.Draw(l)\n}", "func (NilUGauge) Clear() uint64 { return 0 }", "func ClearColor(red GLfloat, green GLfloat, blue GLfloat, alpha GLfloat) {\n\tC.glClearColor(C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))\n}", "func (gl *WebGL) Clear(option GLEnum) {\n\tgl.context.Call(\"clear\", option)\n}", "func ClearBufferData(target uint32, internalformat uint32, format uint32, xtype uint32, data unsafe.Pointer) {\n C.glowClearBufferData(gpClearBufferData, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLenum)(format), (C.GLenum)(xtype), data)\n}", "func (native *OpenGL) ClearColor(red float32, green float32, blue float32, alpha float32) {\n\tgl.ClearColor(red, green, blue, alpha)\n}", "func (w *Window) Clear() {\n\tfor i, _ := range w.tex {\n\t\tw.tex[i] = 0\n\t}\n}", "func (gl *WebGL) ClearColor(r, g, b, a float64) {\n\tgl.context.Call(\"clearColor\", float32(r), float32(g), float32(b), float32(a))\n}", "func Clear() string {\n\treturn csi(\"2J\") + csi(\"H\")\n}", "func Clear(mask uint32) {\n\tsyscall.Syscall(gpClear, 1, uintptr(mask), 0, 0)\n}", "func Clear(data []uintptr, bitIdx int) {\n\twordIdx := uint(bitIdx) / BitsPerWord\n\tdata[wordIdx] = data[wordIdx] &^ (1 << (uint(bitIdx) % BitsPerWord))\n}", "func Clear() error {\n\n\tgl.Clear(gl.COLOR_BUFFER_BIT)\n\n\treturn checkForErrors()\n}", "func (d *Driver) Clear() {\n\tfor i := 0; i < len(d.buff); i++ {\n\t\td.buff[i] = 0\n\t}\n}", "func (b *Buffer) Clear() {\n\tb.series = make(map[string]*influxdb.Series)\n\tb.size = 0\n}", "func (NilCounter) Clear() {}", "func (NilCounter) Clear() {}", "func (b *Buffer) ClearAt(o int) {\n\tif o < len(b.Tiles) {\n\t\tb.Tiles[o] = nil\n\t}\n}", "func (b *Buffer) Clear() {\n\tfor o := range b.Tiles {\n\t\tb.Tiles[o] = nil\n\t}\n}", "func (g *gfx) ClearPixel(x, y int) {\n\tg[x][y] = COLOR_BLACK\n}", "func (f *Framebuffer) Clear(m gfx.ClearMask) {\n\tvar mask int\n\tif m&gfx.ColorBuffer != 0 {\n\t\tmask |= f.ctx.COLOR_BUFFER_BIT\n\t}\n\tif m&gfx.DepthBuffer != 0 {\n\t\tmask |= f.ctx.DEPTH_BUFFER_BIT\n\t}\n\tif m&gfx.StencilBuffer != 0 {\n\t\tmask |= f.ctx.STENCIL_BUFFER_BIT\n\t}\n\n\t// Use this framebuffer's state, and perform the clear operation.\n\tf.useState()\n\tf.ctx.O.Call(\"clear\", mask)\n}", "func (frac *Fractal) Clear() {\n\tfrac.R = histo.New(frac.Width, frac.Height)\n\tfrac.G = histo.New(frac.Width, frac.Height)\n\tfrac.B = histo.New(frac.Width, frac.Height)\n}", "func (d *Display) Clear() {\n\td.sendCommand(0b00000001)\n\ttime.Sleep(10 * time.Millisecond) // long instruction, max 6.2ms\n}", "func (z *Int) Clear() *Int {\n\tz[3], z[2], z[1], z[0] = 0, 0, 0, 0\n\treturn z\n}", "func ClearBufferData(target uint32, internalformat uint32, format uint32, xtype uint32, data unsafe.Pointer) {\n\tC.glowClearBufferData(gpClearBufferData, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLenum)(format), (C.GLenum)(xtype), data)\n}", "func ClearBufferData(target uint32, internalformat uint32, format uint32, xtype uint32, data unsafe.Pointer) {\n\tC.glowClearBufferData(gpClearBufferData, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLenum)(format), (C.GLenum)(xtype), data)\n}", "func (c *ChromaHighlight) ClrBuffer() {\n\tswitch c.srcBuff {\n\tcase nil:\n\t\tc.txtBuff.Delete(c.txtBuff.GetStartIter(), c.txtBuff.GetEndIter())\n\tdefault:\n\t\tc.srcBuff.Delete(c.srcBuff.GetStartIter(), c.srcBuff.GetEndIter())\n\t}\n}", "func (pi *PixelIterator) Clear() {\n\tC.ClearPixelIterator(pi.pi)\n\truntime.KeepAlive(pi)\n}", "func (this *channelStruct) Clear() {\n\tthis.samples = make([]float64, 0)\n}", "func (p Pin) Clear() {\n\tp.Port().bsrr.Store(uint32(Pin0) << 16 << p.index())\n}", "func (rb *RingBuffer[T]) Clear() {\n\trb.mu.Lock()\n\tdefer rb.mu.Unlock()\n\trb.pos = 0\n\trb.buf = nil\n}", "func Unset() {\n\tif NoColor {\n\t\treturn\n\t}\n\n\tOutput.Write(unsafeByteSlice(escapePrefix + Reset.String() + escapeSuffix))\n}", "func (b *Buffer) ClearTo(o int) {\n\tfor o = calc.MinInt(o, len(b.Tiles)); o >= 0; o-- {\n\t\tb.Tiles[o] = nil\n\t}\n}", "func ClearBufferSubData(target uint32, internalformat uint32, offset int, size int, format uint32, xtype uint32, data unsafe.Pointer) {\n C.glowClearBufferSubData(gpClearBufferSubData, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLintptr)(offset), (C.GLsizeiptr)(size), (C.GLenum)(format), (C.GLenum)(xtype), data)\n}", "func (self *nativePduBuffer) Clear() {\n\tself.start = 0\n\tself.count = 0\n}", "func (i *Input) Clear() {\n\ti.Pos = 0\n\ti.Buffer = NewLine()\n}", "func (wv *Spectrum) SetZero() {\n\tfor k := 0; k < 4; k++ {\n\t\twv.C[k] = 0\n\t}\n\n}", "func ClearStencil(s int32) {\n C.glowClearStencil(gpClearStencil, (C.GLint)(s))\n}", "func (c *Canvas) Reset() {\n\tfor y := 0; uint8(y) < canvasHeight; y++ {\n\t\tfor x := 0; uint8(x) < canvasWidth; x++ {\n\t\t\t(*c)[y][x] = 0\n\t\t}\n\t}\n}", "func InvalidateBufferData(buffer uint32) {\n C.glowInvalidateBufferData(gpInvalidateBufferData, (C.GLuint)(buffer))\n}", "func (pw *PixelWand) Clear() {\n\tC.ClearPixelWand(pw.pw)\n\truntime.KeepAlive(pw)\n}", "func ClearDepth(depth float64) {\n C.glowClearDepth(gpClearDepth, (C.GLdouble)(depth))\n}", "func (c *standardResettingCounter) Clear() {\n\tatomic.StoreInt64(&c.count, 0)\n}", "func ClearBufferData(target uint32, internalformat uint32, format uint32, xtype uint32, data unsafe.Pointer) {\n\tsyscall.Syscall6(gpClearBufferData, 5, uintptr(target), uintptr(internalformat), uintptr(format), uintptr(xtype), uintptr(data), 0)\n}", "func Clear() {\n\tprint(\"\\033[H\\033[2J\")\n}", "func (sd *saturationDegree) reset(colors map[int64]int) {\n\tsd.colors = colors\n\tfor i := range sd.nodes {\n\t\tsd.adjColors[i] = make(set.Ints)\n\t}\n\tfor uid, c := range colors {\n\t\tto := sd.g.From(uid)\n\t\tfor to.Next() {\n\t\t\tsd.adjColors[sd.indexOf[to.Node().ID()]].Add(c)\n\t\t}\n\t}\n}", "func Clear() {\n\tfmt.Print(\"\\033[2J\")\n}", "func (c Color) Clearer(pct float32) Color {\n\tf32 := NRGBAf32Model.Convert(c).(NRGBAf32)\n\tf32.A -= pct / 100\n\tf32.A = mat32.Clamp(f32.A, 0, 1)\n\treturn ColorModel.Convert(f32).(Color)\n}", "func (x *Secp256k1N) Clear() {\n\tx.limbs[0] = 0\n\tx.limbs[1] = 0\n\tx.limbs[2] = 0\n\tx.limbs[3] = 0\n\tx.limbs[4] = 0\n}", "func (m *MIDs) Clear() {\n\tm.index = make([]*CPContext, int(midMax))\n}", "func (t *FileTarget) clearBuffer() {\n\tfor {\n\t\tselect {\n\t\tcase <-t.tick.C:\n\t\t\t_ = t.writer.Flush()\n\t\t}\n\t}\n}", "func ClearScreen() {\n\temitEscape(\"J\", 2)\n}", "func (imd *IMDraw) Clear() {\n\timd.tri.SetLen(0)\n\timd.batch.Dirty()\n}", "func ClearStencil(s int32) {\n\tsyscall.Syscall(gpClearStencil, 1, uintptr(s), 0, 0)\n}", "func (n *Uint256) Zero() {\n\tn.n[0], n.n[1], n.n[2], n.n[3] = 0, 0, 0, 0\n}", "func opUI8Bitclear(inputs []ast.CXValue, outputs []ast.CXValue) {\n\toutV0 := inputs[0].Get_ui8() &^ inputs[1].Get_ui8()\n\toutputs[0].Set_ui8(outV0)\n}", "func (mc *MultiCursor) Clear() {\n\tmc.cursors = mc.cursors[0:1]\n}", "func (b FormatOption) Clear(flag FormatOption) FormatOption { return b &^ flag }", "func clearLoopLen(b []byte) {\n\tb[0] = 0xf0\n\tb[1] = 0\n}", "func (d *Display) resetBuffer() {\n\td.width = d.device.Width()\n\td.height = d.device.Height()\n\td.buffer = make([][]byte, d.height)\n\tfor y := range d.buffer {\n\t\td.buffer[y] = make([]byte, d.width)\n\t}\n}", "func (gdt *Array) Clear() {\n\targ0 := gdt.getBase()\n\n\tC.go_godot_array_clear(GDNative.api, arg0)\n}", "func ClearBufferSubData(target uint32, internalformat uint32, offset int, size int, format uint32, xtype uint32, data unsafe.Pointer) {\n\tC.glowClearBufferSubData(gpClearBufferSubData, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLintptr)(offset), (C.GLsizeiptr)(size), (C.GLenum)(format), (C.GLenum)(xtype), data)\n}", "func ClearBufferSubData(target uint32, internalformat uint32, offset int, size int, format uint32, xtype uint32, data unsafe.Pointer) {\n\tC.glowClearBufferSubData(gpClearBufferSubData, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLintptr)(offset), (C.GLsizeiptr)(size), (C.GLenum)(format), (C.GLenum)(xtype), data)\n}", "func clearIndex(\n\tctx context.Context,\n\texecCfg *sql.ExecutorConfig,\n\ttableDesc catalog.TableDescriptor,\n\tindex descpb.IndexDescriptor,\n) error {\n\tlog.Infof(ctx, \"clearing index %d from table %d\", index.ID, tableDesc.GetID())\n\tif index.IsInterleaved() {\n\t\treturn errors.Errorf(\"unexpected interleaved index %d\", index.ID)\n\t}\n\n\tsp := tableDesc.IndexSpan(execCfg.Codec, index.ID)\n\tstart, err := keys.Addr(sp.Key)\n\tif err != nil {\n\t\treturn errors.Errorf(\"failed to addr index start: %v\", err)\n\t}\n\tend, err := keys.Addr(sp.EndKey)\n\tif err != nil {\n\t\treturn errors.Errorf(\"failed to addr index end: %v\", err)\n\t}\n\trSpan := roachpb.RSpan{Key: start, EndKey: end}\n\treturn clearSpanData(ctx, execCfg.DB, execCfg.DistSender, rSpan)\n}", "func (mg *MoveGen) Clear() {\n\tmg.index = 0\n}", "func (display smallEpd) Clear() (err error) {\n\tlog.Debug(\"EPD42 Clear\")\n\n\tif err = display.sendCommand(DATA_START_TRANSMISSION_1); err != nil {\n\t\treturn\n\t}\n\n\t// TODO: Verify that this is enough bits\n\tfor i := 0; i < display.Width()*display.Height()/8; i++ {\n\t\tif err = display.sendData([]byte{0xFF}); err != nil {\n\t\t\treturn\n\t\t}\n\t}\n\n\tif err = display.sendCommand(DATA_START_TRANSMISSION_2); err != nil {\n\t\treturn\n\t}\n\n\tfor i := 0; i < display.Width()*display.Height()/8; i++ {\n\t\tif err = display.sendData([]byte{0xFF}); err != nil {\n\t\t\treturn\n\t\t}\n\t}\n\n\tif err = display.sendCommand(DISPLAY_REFRESH); err != nil {\n\t\treturn\n\t}\n\n\tif err = display.waitUntilIdle(); err != nil {\n\t\treturn\n\t}\n\n\tlog.Debug(\"EPD42 Clear End\")\n\treturn\n}" ]
[ "0.7557742", "0.6926225", "0.6661539", "0.66511786", "0.6609662", "0.65809613", "0.6549761", "0.6321644", "0.63114774", "0.6242595", "0.62145805", "0.62142456", "0.6212063", "0.62066", "0.61998916", "0.6166759", "0.6153944", "0.6153944", "0.61492884", "0.61306447", "0.602728", "0.6015588", "0.60130703", "0.5992833", "0.5992833", "0.59668773", "0.59666157", "0.596032", "0.59461194", "0.59434265", "0.59326655", "0.59303963", "0.5919334", "0.5916094", "0.58646196", "0.5863361", "0.5848986", "0.58480567", "0.5811105", "0.57845265", "0.5783361", "0.5750174", "0.57318616", "0.57291764", "0.5723938", "0.5714473", "0.5708906", "0.5702252", "0.5694861", "0.5685039", "0.5685039", "0.5684971", "0.567208", "0.5667179", "0.56595093", "0.564808", "0.5635059", "0.5624169", "0.56084096", "0.56084096", "0.55884326", "0.55857986", "0.55799407", "0.557674", "0.55751646", "0.5555243", "0.5545292", "0.55275065", "0.5522197", "0.5520504", "0.5511463", "0.55046326", "0.55007905", "0.5490794", "0.5480402", "0.547568", "0.54690456", "0.54374766", "0.54239565", "0.5407808", "0.53873134", "0.5377919", "0.537424", "0.5368595", "0.5348063", "0.5343423", "0.5340826", "0.5327524", "0.53236634", "0.53167635", "0.5309815", "0.5308199", "0.53061134", "0.5303768", "0.53021544", "0.52970123", "0.52970123", "0.5294328", "0.5289729", "0.5288904" ]
0.732023
1
fill a buffer object's data store with a fixed value
func ClearNamedBufferData(buffer uint32, internalformat uint32, format uint32, xtype uint32, data unsafe.Pointer) { C.glowClearNamedBufferData(gpClearNamedBufferData, (C.GLuint)(buffer), (C.GLenum)(internalformat), (C.GLenum)(format), (C.GLenum)(xtype), data) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func (dataBlock *DataBlock) fill(offset uint64, buf *bytes.Buffer) uint64 {\n\tbyteToFill := dataBlock.Capacity - offset\n\tbyteActualFill := buf.Next(int(byteToFill)) // API user...\n\tif len(byteActualFill) < int(byteToFill) {\n\t\t// Not sure if the byte at `offset` would be covered by new value...???????????????\n\t\tleftover := dataBlock.Data[(int(offset) + len(byteActualFill)):]\n\t\tdataBlock.Data = append(dataBlock.Data[:offset], append(byteActualFill, leftover...)...)\n\t} else {\n\t\tdataBlock.Data = append(dataBlock.Data[:offset], byteActualFill...)\n\t}\n\treturn uint64(len(byteActualFill))\n}", "func (b *mpgBuff) fill(buff *concBuff) {\n\tbuff.Lock()\n\tn, err := b.fileDec.Read(buff.data)\n\tbuff.len = n\n\tbuff.pos = 0\n\tif err == mpg123.EOF {\n\t\tb.eof = true\n\t}\n\tbuff.Unlock()\n}", "func (b base) Fill(value uint64) {\n\tbinary.PutUvarint(b.inputBuffer[b.seedLen:], value)\n\t// base64 encoding reduce byte size\n\t// from i to o\n\tb64encoder.Encode(b.outputBuffer, b.inputBuffer)\n}", "func (r *BytesRecord) Fill(rid RID, version int, content []byte) error {\n\tr.RID = rid\n\tr.Vers = version\n\tr.Data = content\n\treturn nil\n}", "func (b *Binding) Set(buf uint32) {\n\tgl.BindBufferBase(gl.SHADER_STORAGE_BUFFER, b.uint32, buf)\n}", "func (al *AudioListener) setBuffer(size int) {\n\tal.Lock()\n\tdefer al.Unlock()\n\n\tal.buffer = make([]gumble.AudioPacket, 0, size)\n}", "func (d *OneToOne) Set(data GenericDataType) {\n\tidx := d.writeIndex % uint64(len(d.buffer))\n\n\tnewBucket := &bucket{\n\t\tdata: data,\n\t\tseq: d.writeIndex,\n\t}\n\td.writeIndex++\n\n\tatomic.StorePointer(&d.buffer[idx], unsafe.Pointer(newBucket))\n}", "func newBuffer(bits uint32) buffer {\n\tvar b buffer\n\tb.data = make([]unsafe.Pointer, 1<<bits)\n\tb.free = 1 << bits\n\tb.mask = 1<<bits - 1\n\tb.bits = bits\n\treturn b\n}", "func (addr *Bytes) Store(val []byte) {\n\taddr.v.Store(val)\n}", "func (self Source) SetBuffer(buffer Buffer) {\n\tself.Seti(AlBuffer, int32(buffer))\n}", "func NewBuffer(aSlice interface{}) *Buffer {\n return &Buffer{buffer: sliceValue(aSlice, false), handler: valueHandler{}}\n}", "func ringBufferInitBuffer(buflen uint32, rb *ringBuffer) {\n\tvar new_data []byte\n\tvar i uint\n\tsize := 2 + int(buflen) + int(kSlackForEightByteHashingEverywhere)\n\tif cap(rb.data_) < size {\n\t\tnew_data = make([]byte, size)\n\t} else {\n\t\tnew_data = rb.data_[:size]\n\t}\n\tif rb.data_ != nil {\n\t\tcopy(new_data, rb.data_[:2+rb.cur_size_+uint32(kSlackForEightByteHashingEverywhere)])\n\t}\n\n\trb.data_ = new_data\n\trb.cur_size_ = buflen\n\trb.buffer_ = rb.data_[2:]\n\trb.data_[1] = 0\n\trb.data_[0] = rb.data_[1]\n\tfor i = 0; i < kSlackForEightByteHashingEverywhere; i++ {\n\t\trb.buffer_[rb.cur_size_+uint32(i)] = 0\n\t}\n}", "func (vm *VM) bufferVariable(variable Variable) {\n\tvm.bufferPush(variable.Value())\n}", "func (vm *VM) bufferPush(data string) {\n\tnewBuffer := &buffer{\n\t\tprevious: vm.buffer,\n\t\tvalue: data,\n\t}\n\tvm.buffer = newBuffer\n}", "func (rb *RingBuffer) Add(value stats.Record) {\n\trb.lock.Lock()\n\tdefer rb.lock.Unlock()\n\trb.data[rb.seq%uint64(len(rb.data))] = value\n\trb.seq++\n}", "func (b *buffer) fill(need int) (err error) {\n\tb.idx = 0\n\tb.length = 0\n\n\tvar n int\n\tfor b.length < need {\n\t\tn, err = b.rd.Read(b.buf[b.length:])\n\t\tb.length += n\n\n\t\tif err == nil {\n\t\t\tcontinue\n\t\t}\n\t\treturn // err\n\t}\n\n\treturn\n}", "func newBuffer(buf []byte) *Buffer {\n\treturn &Buffer{data: buf}\n}", "func (geom Geometry) Buffer(distance float64, segments int) Geometry {\n\tnewGeom := C.OGR_G_Buffer(geom.cval, C.double(distance), C.int(segments))\n\treturn Geometry{newGeom}\n}", "func WriteCount(buffer []byte, offset int, value byte, valueCount int) {\n for i := 0; i < valueCount; i++ {\n buffer[offset + i] = value\n }\n}", "func BufferStorage(target uint32, size int, data unsafe.Pointer, flags uint32) {\n\tsyscall.Syscall6(gpBufferStorage, 4, uintptr(target), uintptr(size), uintptr(data), uintptr(flags), 0, 0)\n}", "func (b *Buffer) AttachNew() {\n b.data = make([]byte, 0)\n b.size = 0\n b.offset = 0\n}", "func (debugging *debuggingOpenGL) BufferData(target uint32, size int, data interface{}, usage uint32) {\n\tdebugging.recordEntry(\"BufferData\", target, size, data, usage)\n\tdebugging.gl.BufferData(target, size, data, usage)\n\tdebugging.recordExit(\"BufferData\")\n}", "func (src *Source) SetNewBuffer() {\n\tsrc.buf = make([]byte, 64)\n}", "func (w *Writer) SetBuffer(raw []byte) {\n\tif w.err != nil {\n\t\treturn\n\t}\n\tw.b = w.b[:0]\n\tw.b = append(w.b, raw...)\n}", "func newBuffer(r io.Reader, offset int64) *buffer {\n\treturn &buffer{\n\t\tr: r,\n\t\toffset: offset,\n\t\tbuf: make([]byte, 0, 4096),\n\t\tallowObjptr: true,\n\t\tallowStream: true,\n\t}\n}", "func (p *movingAverageProcessor) addBufferData(index int, data interface{}, namespace string) error {\n\tif _, ok := p.movingAverageMap[namespace]; ok {\n\t\tif index >= len(p.movingAverageMap[namespace].movingAverageBuf) {\n\t\t\treturn errors.New(\"Incorrect value of index, trying to access non-existing element of buffer\")\n\t\t}\n\t\tp.movingAverageMap[namespace].movingAverageBuf[index] = data\n\t\treturn nil\n\t} else {\n\t\treturn errors.New(\"Namespace is not present in the map\")\n\t}\n}", "func (src *Source) SetBuffer(buf []byte) {\n\tsrc.buf = buf\n}", "func BufferStorage(target uint32, size int, data unsafe.Pointer, flags uint32) {\n C.glowBufferStorage(gpBufferStorage, (C.GLenum)(target), (C.GLsizeiptr)(size), data, (C.GLbitfield)(flags))\n}", "func (bs endecBytes) fill(offset int, fields ...interface{}) int {\n\tfor _, val := range fields {\n\t\tswitch val.(type) {\n\t\tcase byte:\n\t\t\tbs[offset] = val.(byte)\n\t\t\toffset++\n\t\tcase uint16:\n\t\t\tbinary.BigEndian.PutUint16(bs[offset:], val.(uint16))\n\t\t\toffset += 2\n\t\tcase uint32: // remaingLength\n\t\t\tn := binary.PutUvarint(bs[offset:], uint64(val.(uint32)))\n\t\t\toffset += n\n\t\tcase string:\n\t\t\tstr := val.(string)\n\t\t\tbinary.BigEndian.PutUint16(bs[offset:], uint16(len(str)))\n\t\t\toffset += 2\n\t\t\toffset += copy(bs[offset:], str)\n\t\tcase []byte:\n\t\t\toffset += copy(bs[offset:], val.([]byte))\n\t\tdefault: // unknown type\n\t\t\treturn -offset\n\t\t}\n\t}\n\treturn offset\n}", "func (r *Ring) set(p int, v interface{}) {\n\tr.buff[r.mod(p)] = v\n}", "func newBuffer(e []byte) *Buffer {\n\tp := buffer_pool.Get().(*Buffer)\n\tp.buf = e\n\treturn p\n}", "func (b *buffer) grow() {\n\t// ugh all these atomics\n\tatomic.AddUint32(&b.free, uint32(len(b.data)))\n\tatomic.AddUint32(&b.mask, atomic.LoadUint32(&b.mask))\n\tatomic.AddUint32(&b.mask, 1)\n\tatomic.AddUint32(&b.bits, 1)\n\n\tnext := make([]unsafe.Pointer, 2*len(b.data))\n\tcopy(next, b.data)\n\n\t// UGH need to do this with atomics. one pointer + 2 uint64 calls?\n\tb.data = next\n}", "func (s *Arena) putVal(v y.ValueStruct) uint32 {\n\tl := uint32(v.EncodedSize())\n\toffset := s.allocate(l) - l\n\tbuf := s.data[offset : offset+l]\n\tv.Encode(buf)\n\treturn offset\n}", "func newBuffer() Buffer {\n\treturn &buffer{\n\t\tbytes: make([]byte, 0, 64),\n\t}\n}", "func newBuffer() *buffer {\n\treturn &buffer{\n\t\tdata: make([]byte, 0),\n\t\tlen: 0,\n\t\tpkg: nil,\n\t\tconn: nil,\n\t\tpkgCh: make(chan *pkg),\n\t\tevCh: make(chan *pkg),\n\t\terrCh: make(chan error, 1),\n\t}\n}", "func (g *GLTF) loadBuffer(bufIdx int) ([]byte, error) {\n\n\t// Check if provided buffer index is valid\n\tif bufIdx < 0 || bufIdx >= len(g.Buffers) {\n\t\treturn nil, fmt.Errorf(\"invalid buffer index\")\n\t}\n\tbufData := &g.Buffers[bufIdx]\n\t// Return cached if available\n\tif bufData.cache != nil {\n\t\tlog.Debug(\"Fetching Buffer %d (cached)\", bufIdx)\n\t\treturn bufData.cache, nil\n\t}\n\tlog.Debug(\"Loading Buffer %d\", bufIdx)\n\n\t// If buffer URI use the chunk data field\n\tif bufData.Uri == \"\" {\n\t\treturn g.data, nil\n\t}\n\n\t// Checks if buffer URI is a data URI\n\tvar data []byte\n\tvar err error\n\tif isDataURL(bufData.Uri) {\n\t\tdata, err = loadDataURL(bufData.Uri)\n\t} else {\n\t\t// Try to load buffer from file\n\t\tdata, err = g.loadFileBytes(bufData.Uri)\n\t}\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\n\t// Checks data length\n\tif len(data) != bufData.ByteLength {\n\t\treturn nil, fmt.Errorf(\"buffer:%d read data length:%d expected:%d\", bufIdx, len(data), bufData.ByteLength)\n\t}\n\t// Cache buffer data\n\tg.Buffers[bufIdx].cache = data\n\tlog.Debug(\"cache data:%v\", len(bufData.cache))\n\treturn data, nil\n}", "func (d *decoder) buffer() []byte {\n\tif d.buf == nil {\n\t\td.buf = make([]byte, 8)\n\t}\n\treturn d.buf\n}", "func (b *Buffer) Data() []byte { return b.data }", "func (b *Ring) push(value interface{}) {\n\tb.lock.Lock()\n\tdefer b.lock.Unlock()\n\tif len(b.buf) == 0 || b.size == 0 { // nothing to do\n\t\treturn\n\t}\n\tnext := Next(1, b.head, len(b.buf))\n\tb.buf[next] = value\n\tb.head = next\n\t// note that the oldest is auto pruned, when size== capacity, but with the size attribute we know it has been discarded\n}", "func (m *MsgMemoryBuffer) Insert(value interface{}) {\n\tm.buff.Value = value\n\tm.buff = m.buff.Next()\n}", "func (b *CompactableBuffer) Update(address *EntryAddress, data []byte) error {\n\taddress.LockForWrite()\n\tdefer address.UnlockWrite()\n\theader, err := b.ReadHeader(address)\n\tif err != nil {\n\t\treturn err\n\t}\n\tbeforeUpdataDataSize := header.dataSize\n\tafterUpdateDataSize := len(data) + VarIntSize(len(data))\n\tdataSizeDelta := afterUpdateDataSize - int(beforeUpdataDataSize)\n\n\tremainingSpace := int(header.entrySize) - reservedSize - afterUpdateDataSize\n\theader.dataSize = int64(afterUpdateDataSize)\n\tif remainingSpace <= 0 {\n\t\tatomic.AddInt64(&b.dataSize, int64(-beforeUpdataDataSize))\n\t\tatomic.AddInt64(&b.entrySize, int64(-header.entrySize))\n\t\treturn b.expand(address, data)\n\t}\n\n\tatomic.AddInt64(&b.dataSize, int64(dataSizeDelta))\n\tvar target = make([]byte, 0)\n\tAppendToBytes(data, &target)\n\tif len(target) > int(header.dataSize) {\n\t\treturn io.EOF\n\t}\n\twritableBuffer := b.writableBuffer()\n\t_, err = writableBuffer.Write(address.Position()+reservedSize, target...)\n\treturn err\n}", "func newBuffer(b []byte) *buffer {\n\treturn &buffer{proto.NewBuffer(b), 0}\n}", "func (native *OpenGL) BufferData(target uint32, size int, data interface{}, usage uint32) {\n\tdataPtr, isPtr := data.(unsafe.Pointer)\n\tif isPtr {\n\t\tgl.BufferData(target, size, dataPtr, usage)\n\t} else {\n\t\tgl.BufferData(target, size, gl.Ptr(data), usage)\n\t}\n}", "func putBuffer(buf *bytes.Buffer) {\n\tbuf.Reset()\n\tbufferPool.Put(buf)\n}", "func (bp *bufferPool) putBuffer(b *buffer) {\n\tbp.lock.Lock()\n\tif bp.freeBufNum < 1000 {\n\t\tb.next = bp.freeList\n\t\tbp.freeList = b\n\t\tbp.freeBufNum++\n\t}\n\tbp.lock.Unlock()\n}", "func (c webgl) BufferDataX(target Enum, d interface{}, usage Enum) {\n\tc.ctx.Call(\"bufferData\", target, conv(d), usage)\n}", "func BufferData(target uint32, size int, data unsafe.Pointer, usage uint32) {\n\tsyscall.Syscall6(gpBufferData, 4, uintptr(target), uintptr(size), uintptr(data), uintptr(usage), 0, 0)\n}", "func NewEmptyBuffer() *Buffer {\n return &Buffer{data: make([]byte, 0)}\n}", "func new_buffer(conn *websocket.Conn, ctrl chan struct{}, txqueuelen int) *Buffer {\n\tbuf := Buffer{conn: conn}\n\tbuf.pending = make(chan []byte, txqueuelen)\n\tbuf.ctrl = ctrl\n\tbuf.cache = make([]byte, packet.PACKET_LIMIT+2)\n\treturn &buf\n}", "func (storage *Storage) SetValue(key string, value []byte) {\n\tfullEntity := encodeRecord(key, string(value))\n\tstorage.mutex.Lock()\n\tbytesWritten := addBlock(storage.file, fullEntity)\n\toffset := int64(storage.size) + int64(len(key)) + 8\n\tatomic.AddInt64(&storage.size, int64(bytesWritten))\n\tstorage.mutex.Unlock()\n\tstorage.store.Store(key, Coords{offset: offset, len: len(value)})\n}", "func BufferData(target Enum, src []byte, usage Enum) {\n\tgl.BufferData(uint32(target), int(len(src)), gl.Ptr(&src[0]), uint32(usage))\n}", "func initBuffer(size int) {\n\tif len(buffer) == size {\n\t\treturn\n\t}\n\tbuffer = make([]uint8, size)\n}", "func (d *Display) resetBuffer() {\n\td.width = d.device.Width()\n\td.height = d.device.Height()\n\td.buffer = make([][]byte, d.height)\n\tfor y := range d.buffer {\n\t\td.buffer[y] = make([]byte, d.width)\n\t}\n}", "func (b *Ring) add(val interface{}) error {\n\tif b.size >= len(b.buf) {\n\t\treturn ErrFull\n\t}\n\tb.lock.Lock()\n\tdefer b.lock.Unlock()\n\n\tnext := Next(1, b.head, len(b.buf))\n\tb.buf[next] = val\n\tb.head = next\n\tb.size++ // increase the inner size\n\treturn nil\n}", "func NewBuffer(capacity int, fn func(series []*influxdb.Series)) *Buffer {\n\tb := &Buffer{\n\t\tfn: fn,\n\t\tin: make(chan *influxdb.Series),\n\t\tseries: make(map[string]*influxdb.Series),\n\t\tcapacity: capacity,\n\t}\n\tif b.capacity > 0 {\n\t\tgo b.aggregate()\n\t}\n\n\treturn b\n}", "func BufferInit(target Enum, size int, usage Enum) {\n\tgl.BufferData(uint32(target), size, nil, uint32(usage))\n}", "func (c *fakeRedisConn) SetReadBuffer(bytes int) {}", "func (b *Buffer) Store(record *data.Record) {\n\tb.mu.Lock()\n\tdefer b.mu.Unlock()\n\n\tb.records = append(b.records, record)\n\n\tif len(b.records) >= b.bufferSize {\n\t\tb.flush()\n\t}\n}", "func (b *Builder) Buffer(count int) value.Pointer {\n\tpointerSize := b.memoryLayout.GetPointer().GetSize()\n\tdynamic := false\n\tsize := 0\n\n\t// Examine the stack to see where these values came from\n\tfor i := 0; i < count; i++ {\n\t\te := b.stack[len(b.stack)-i-1]\n\t\top := b.instructions[e.idx]\n\t\tty := e.ty\n\t\tif _, isPush := op.(asm.Push); !isPush {\n\t\t\t// Values that have made their way on to the stack from non-constant\n\t\t\t// sources cannot be put in the constant buffer.\n\t\t\tdynamic = true\n\t\t}\n\t\tswitch ty {\n\t\tcase protocol.Type_ConstantPointer, protocol.Type_VolatilePointer:\n\t\t\t// Pointers cannot be put into the constant buffer as they are remapped\n\t\t\t// by the VM\n\t\t\tdynamic = true\n\t\t}\n\n\t\tsize += ty.Size(pointerSize)\n\t}\n\n\tif dynamic {\n\t\t// At least one of the values was not from a Push()\n\t\t// Build the buffer in temporary memory at replay time.\n\t\tbuf := b.AllocateTemporaryMemory(uint64(size))\n\t\toffset := size\n\t\tfor i := 0; i < count; i++ {\n\t\t\te := b.stack[len(b.stack)-1]\n\t\t\toffset -= e.ty.Size(pointerSize)\n\t\t\tb.Store(buf.Offset(uint64(offset)))\n\t\t}\n\t\treturn buf\n\t}\n\t// All the values are constant.\n\t// Move the pushed values into a constant memory buffer.\n\tvalues := make([]value.Value, count)\n\tfor i := 0; i < count; i++ {\n\t\te := b.stack[len(b.stack)-1]\n\t\tvalues[count-i-1] = b.instructions[e.idx].(asm.Push).Value\n\t\tb.removeInstruction(e.idx)\n\t\tb.popStack()\n\t}\n\treturn b.constantMemory.writeValues(values...)\n}", "func (self *ValueStore) Append(options WriteOptions, instanceId uint64, buffer []byte, fileIdStr *string) error {\n begin := util.NowTimeMs()\n\n self.mutex.Lock()\n defer self.mutex.Unlock()\n\n bufferLen := len(buffer)\n len := util.UINT64SIZE + bufferLen\n tmpBufLen := len + util.INT32SIZE\n\n var fileId int32\n var offset uint32\n err := self.getFileId(uint32(tmpBufLen), &fileId, &offset)\n if err != nil {\n return err\n }\n\n tmpBuf := make([]byte, tmpBufLen)\n util.EncodeInt32(tmpBuf, 0, int32(len))\n util.EncodeUint64(tmpBuf, util.INT32SIZE, instanceId)\n copy(tmpBuf[util.INT32SIZE+util.UINT64SIZE:], []byte(buffer))\n\n ret, err := self.file.Write(tmpBuf)\n if ret != tmpBufLen {\n err = fmt.Errorf(\"writelen %d not equal to %d,buffer size %d\",\n ret, tmpBufLen, bufferLen)\n return err\n }\n\n if options.Sync {\n self.file.Sync()\n }\n\n self.nowFileOffset += uint64(tmpBufLen)\n\n ckSum := util.Crc32(0, tmpBuf[util.INT32SIZE:], common.CRC32_SKIP)\n self.EncodeFileId(fileId, uint64(offset), ckSum, fileIdStr)\n\n useMs := util.NowTimeMs() - begin\n\n log.Info(\"ok, offset %d fileid %d cksum %d instanceid %d buffersize %d usetime %d ms sync %t\",\n offset, fileId, ckSum, instanceId, bufferLen, useMs, options.Sync)\n return nil\n}", "func (p *Buffer) SetBuf(s []byte) {\n\tp.buf = s\n\tp.index = 0\n\tp.length = len(s)\n}", "func BufferData(target uint32, size int, data unsafe.Pointer, usage uint32) {\n C.glowBufferData(gpBufferData, (C.GLenum)(target), (C.GLsizeiptr)(size), data, (C.GLenum)(usage))\n}", "func (lvs *ValueStore) bufferChunk(v Value, c chunks.Chunk, height uint64, hints Hints) {\n\tlvs.pendingMu.Lock()\n\tdefer lvs.pendingMu.Unlock()\n\th := c.Hash()\n\td.Chk.NotZero(height)\n\tlvs.pendingPuts[h] = pendingChunk{c, height, hints}\n\tlvs.pendingPutSize += uint64(len(c.Data()))\n\n\tputChildren := func(parent hash.Hash) (dataPut int) {\n\t\tpc, present := lvs.pendingPuts[parent]\n\t\td.Chk.True(present)\n\t\tv := DecodeValue(pc.c, lvs)\n\t\tv.WalkRefs(func(grandchildRef Ref) {\n\t\t\tif pc, present := lvs.pendingPuts[grandchildRef.TargetHash()]; present {\n\t\t\t\tlvs.bs.SchedulePut(pc.c, pc.height, pc.hints)\n\t\t\t\tdataPut += len(pc.c.Data())\n\t\t\t\tdelete(lvs.pendingPuts, grandchildRef.TargetHash())\n\t\t\t}\n\t\t})\n\t\treturn\n\t}\n\n\t// Enforce invariant (1)\n\tif height > 1 {\n\t\tv.WalkRefs(func(childRef Ref) {\n\t\t\tchildHash := childRef.TargetHash()\n\t\t\tif _, present := lvs.pendingPuts[childHash]; present {\n\t\t\t\tlvs.pendingParents[h] = height\n\t\t\t} else {\n\t\t\t\t// Shouldn't be able to be in pendingParents without being in pendingPuts\n\t\t\t\t_, present := lvs.pendingParents[childHash]\n\t\t\t\td.Chk.False(present)\n\t\t\t}\n\n\t\t\tif _, present := lvs.pendingParents[childHash]; present {\n\t\t\t\tlvs.pendingPutSize -= uint64(putChildren(childHash))\n\t\t\t\tdelete(lvs.pendingParents, childHash)\n\t\t\t}\n\t\t})\n\t}\n\n\t// Enforce invariant (2)\n\tfor lvs.pendingPutSize > lvs.pendingPutMax {\n\t\tvar tallest hash.Hash\n\t\tvar height uint64 = 0\n\t\tfor parent, ht := range lvs.pendingParents {\n\t\t\tif ht > height {\n\t\t\t\ttallest = parent\n\t\t\t\theight = ht\n\t\t\t}\n\t\t}\n\t\tif height == 0 { // This can happen if there are no pending parents\n\t\t\tvar pc pendingChunk\n\t\t\tfor tallest, pc = range lvs.pendingPuts {\n\t\t\t\t// Any pendingPut is as good as another in this case, so take the first one\n\t\t\t\tbreak\n\t\t\t}\n\t\t\tlvs.bs.SchedulePut(pc.c, pc.height, pc.hints)\n\t\t\tlvs.pendingPutSize -= uint64(len(pc.c.Data()))\n\t\t\tdelete(lvs.pendingPuts, tallest)\n\t\t\tcontinue\n\t\t}\n\n\t\tlvs.pendingPutSize -= uint64(putChildren(tallest))\n\t\tdelete(lvs.pendingParents, tallest)\n\t}\n}", "func NewBuffer(capacity int) Buffer {\n\treturn Buffer{\n\t\tcapacity: capacity,\n\t\tcurrentSize: 0,\n\t\tcontents: map[entity.Key]inventoryapi.PostDeltaBody{},\n\t}\n}", "func (ab *Buffer) Add(ctx context.Context, obj interface{}) {\n\tif ab.Tracer != nil {\n\t\tfinisher := ab.Tracer.StartAdd(ctx)\n\t\tdefer finisher.Finish(nil)\n\t}\n\tvar bufferLength int\n\tif ab.Stats != nil {\n\t\tab.maybeStatCount(ctx, MetricAdd, 1)\n\t\tstart := time.Now().UTC()\n\t\tdefer func() {\n\t\t\tab.maybeStatGauge(ctx, MetricBufferLength, float64(bufferLength))\n\t\t\tab.maybeStatElapsed(ctx, MetricAddElapsed, start)\n\t\t}()\n\t}\n\n\tvar flush []interface{}\n\tab.contentsMu.Lock()\n\tbufferLength = ab.contents.Len()\n\tab.contents.Enqueue(obj)\n\tif ab.contents.Len() >= ab.MaxLen {\n\t\tflush = ab.contents.Drain()\n\t}\n\tab.contentsMu.Unlock()\n\tab.unsafeFlushAsync(ctx, flush)\n}", "func newDatabaseBuffer() databaseBuffer {\n\tb := &dbBuffer{\n\t\tbucketsMap: make(map[xtime.UnixNano]*BufferBucketVersions),\n\t\tinOrderBlockStarts: make([]xtime.UnixNano, 0, bucketsCacheSize),\n\t}\n\treturn b\n}", "func (p *byteBufferPool) give(buf *[]byte) {\n\tif buf == nil {\n\t\treturn\n\t}\n\tsize := cap(*buf)\n\tslot := p.slot(size)\n\tif slot == errSlot {\n\t\treturn\n\t}\n\tif size != int(p.pool[slot].defaultSize) {\n\t\treturn\n\t}\n\tp.pool[slot].pool.Put(buf)\n}", "func NewBuffer() *Buffer {\n\treturn &Buffer{Line: []byte{}, Val: make([]byte, 0, 32)}\n}", "func (gl *WebGL) BufferData(target GLEnum, data interface{}, usage GLEnum) {\n\tvalues := sliceToTypedArray(data)\n\tgl.context.Call(\"bufferData\", target, values, usage)\n}", "func (client *Client) addToBuffer(key string, metricValue string) {\n\t// build metric\n\tmetric := fmt.Sprintf(\"%s:%s\", key, metricValue)\n\n\t// flush\n\tif client.keyBuffer == nil {\n\t\t// send metric now\n\t\tgo client.send(metric)\n\t} else {\n\t\t// add metric to buffer for next manual flush\n\t\tclient.keyBufferLock.Lock()\n\t\tclient.keyBuffer = append(client.keyBuffer, metric)\n\t\tclient.keyBufferLock.Unlock()\n\t}\n}", "func NewProxyWithBuffer(buffer *fbe.Buffer) *Proxy {\n proxy := &Proxy{\n fbe.NewReceiver(buffer, false),\n proto.NewProxyWithBuffer(buffer),\n NewStructSimpleModel(buffer),\n NewStructOptionalModel(buffer),\n NewStructNestedModel(buffer),\n NewStructBytesModel(buffer),\n NewStructArrayModel(buffer),\n NewStructVectorModel(buffer),\n NewStructListModel(buffer),\n NewStructSetModel(buffer),\n NewStructMapModel(buffer),\n NewStructHashModel(buffer),\n NewStructHashExModel(buffer),\n NewStructEmptyModel(buffer),\n nil,\n nil,\n nil,\n nil,\n nil,\n nil,\n nil,\n nil,\n nil,\n nil,\n nil,\n nil,\n }\n proxy.SetupHandlerOnReceive(proxy)\n proxy.SetupHandlerOnProxyStructSimpleFunc(func(model *StructSimpleModel, fbeType int, buffer []byte) {})\n proxy.SetupHandlerOnProxyStructOptionalFunc(func(model *StructOptionalModel, fbeType int, buffer []byte) {})\n proxy.SetupHandlerOnProxyStructNestedFunc(func(model *StructNestedModel, fbeType int, buffer []byte) {})\n proxy.SetupHandlerOnProxyStructBytesFunc(func(model *StructBytesModel, fbeType int, buffer []byte) {})\n proxy.SetupHandlerOnProxyStructArrayFunc(func(model *StructArrayModel, fbeType int, buffer []byte) {})\n proxy.SetupHandlerOnProxyStructVectorFunc(func(model *StructVectorModel, fbeType int, buffer []byte) {})\n proxy.SetupHandlerOnProxyStructListFunc(func(model *StructListModel, fbeType int, buffer []byte) {})\n proxy.SetupHandlerOnProxyStructSetFunc(func(model *StructSetModel, fbeType int, buffer []byte) {})\n proxy.SetupHandlerOnProxyStructMapFunc(func(model *StructMapModel, fbeType int, buffer []byte) {})\n proxy.SetupHandlerOnProxyStructHashFunc(func(model *StructHashModel, fbeType int, buffer []byte) {})\n proxy.SetupHandlerOnProxyStructHashExFunc(func(model *StructHashExModel, fbeType int, buffer []byte) {})\n proxy.SetupHandlerOnProxyStructEmptyFunc(func(model *StructEmptyModel, fbeType int, buffer []byte) {})\n return proxy\n}", "func (b *Buffer) Sync() {\n\tb.SetArea(b.Bounds())\n}", "func (j *JSendBuilderBuffer) Data(data interface{}) JSendBuilder {\n\treturn j.Set(FieldData, data)\n}", "func (l *Logger) initLoggerBuffer() (err error) {\n\t// build\n\tl.LoggerBuffer = LoggerBuffer{}\n\n\t// get serial data\n\tlConfig, err := l.getSerialConfig()\n\tif err != nil {\n\t\treturn\n\t}\n\n\tport, err := serial.OpenPort(lConfig)\n\tif err != nil {\n\t\treturn\n\t}\n\tl.serialPort = *port\n\n\tgo func() {\n\t\tfor {\n\t\t\tselect {\n\t\t\tcase <-l.stop:\n\t\t\t\treturn\n\t\t\tdefault:\n\t\t\t\t// get data\n\t\t\t\tbuf := make([]byte, bufSize)\n\n\t\t\t\tn, err := port.Read(buf)\n\t\t\t\ttime := time.Now().UTC()\n\t\t\t\tif err != nil {\n\t\t\t\t\tlog.Print(err)\n\t\t\t\t\tcontinue\n\t\t\t\t}\n\t\t\t\t//log.Printf(\"NEW DATA [%03d]: %02X %03d\", n, buf[:n], buf[:n]) // LOG\n\n\t\t\t\t// push to LoggerBuffer\n\t\t\t\tt := util.TimestampBuilder(time)\n\t\t\t\tdu := DataUnit{\n\t\t\t\t\tData: buf[:n],\n\t\t\t\t\tTime: &t,\n\t\t\t\t}\n\n\t\t\t\tl.DataUnit = append(l.DataUnit, &du)\n\n\t\t\t\t// feed consumers\n\t\t\t\tfor _, c := range l.consumers {\n\t\t\t\t\tc <- du\n\n\t\t\t\t\tif l.config.Debug {\n\t\t\t\t\t\tlog.Print(\"Data received: \", du.PrettyString())\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\t// Flush every time new data is received\n\t\t\t\tl.flush()\n\t\t\t}\n\t\t}\n\t}()\n\n\treturn\n}", "func (s *scratch) add(c byte) {\n\tif s.fill+1 >= cap(s.data) {\n\t\ts.grow()\n\t}\n\n\ts.data[s.fill] = c\n\ts.fill++\n}", "func (b *Buf) Reset() { b.b = b.b[:0] }", "func (b *Buffer) AttachBytes(buffer []byte, offset int, size int) {\n if len(buffer) < size {\n panic(\"invalid buffer\")\n }\n if size <= 0 {\n panic(\"invalid size\")\n }\n if offset > size {\n panic(\"invalid offset\")\n }\n\n b.data = buffer\n b.size = size\n b.offset = offset\n}", "func (u *Uintptr) Store(val uintptr) {\n\tatomic.StoreUintptr(&u.v, val)\n}", "func NewCapacityBuffer(capacity int) *Buffer {\n return &Buffer{data: make([]byte, capacity)}\n}", "func advanceBuffer(buff *bytes.Buffer, num int) {\n\tbuff.Next(num)\n\t// move buffer from num offset to 0\n\tbytearr := buff.Bytes()\n\tbuff.Reset()\n\tbuff.Write(bytearr)\n}", "func (tb *TelemetryBuffer) BufferAndPushData(intervalms time.Duration) {\n\tdefer tb.close()\n\tif !tb.FdExists {\n\t\ttelemetryLogger.Printf(\"[Telemetry] Buffer telemetry data and send it to host\")\n\t\tif intervalms < DefaultInterval {\n\t\t\tintervalms = DefaultInterval\n\t\t}\n\n\t\tinterval := time.NewTicker(intervalms).C\n\t\tfor {\n\t\t\tselect {\n\t\t\tcase <-interval:\n\t\t\t\t// Send payload to host and clear cache when sent successfully\n\t\t\t\t// To-do : if we hit max slice size in payload, write to disk and process the logs on disk on future sends\n\t\t\t\ttelemetryLogger.Printf(\"[Telemetry] send data to host\")\n\t\t\t\tif err := tb.sendToHost(); err == nil {\n\t\t\t\t\ttb.payload.reset()\n\t\t\t\t} else {\n\t\t\t\t\ttelemetryLogger.Printf(\"[Telemetry] sending to host failed with error %+v\", err)\n\t\t\t\t}\n\t\t\tcase report := <-tb.data:\n\t\t\t\ttelemetryLogger.Printf(\"[Telemetry] Got data..Append it to buffer\")\n\t\t\t\ttb.payload.push(report)\n\t\t\tcase <-tb.cancel:\n\t\t\t\tgoto EXIT\n\t\t\t}\n\t\t}\n\t} else {\n\t\t<-tb.cancel\n\t}\n\nEXIT:\n}", "func (g *GrowingBuffer) Values() interface{} {\n return g.bufferPtr.Elem().Interface()\n}", "func (_e *MockTestTransportInstance_Expecter) FillBuffer(until interface{}) *MockTestTransportInstance_FillBuffer_Call {\n\treturn &MockTestTransportInstance_FillBuffer_Call{Call: _e.mock.On(\"FillBuffer\", until)}\n}", "func NewProxyWithBuffer(buffer *fbe.Buffer) *Proxy {\n proxy := &Proxy{\n fbe.NewReceiver(buffer, false),\n NewOrderModel(buffer),\n NewBalanceModel(buffer),\n NewAccountModel(buffer),\n nil,\n nil,\n nil,\n }\n proxy.SetupHandlerOnReceive(proxy)\n proxy.SetupHandlerOnProxyOrderFunc(func(model *OrderModel, fbeType int, buffer []byte) {})\n proxy.SetupHandlerOnProxyBalanceFunc(func(model *BalanceModel, fbeType int, buffer []byte) {})\n proxy.SetupHandlerOnProxyAccountFunc(func(model *AccountModel, fbeType int, buffer []byte) {})\n return proxy\n}", "func Put(buffer *Buffer) {\n\t// Prohibit uninitialized buffers from being added to the pool\n\tif buffer.arena == nil {\n\t\tpanic(\"invalid Buffer object\")\n\t}\n\t// Resetting happens inside put\n\tfreeList.put(buffer)\n}", "func (b *BufferPool) Flush(interface{}) {\n\tb.Lock()\n\tb.Data = make([]byte, b.Size)\n\tb.Unlock()\n}", "func (b *BufferManager) SetBuffer(peer *PeerSession) {\n\tb.lock.Lock()\n\tdefer b.lock.Unlock()\n\toffset, ok := b.freeIndex.TryDequeue()\n\tif ok {\n\t\tpeer.bufferOffst = offset.(int64)\n\t\tpeer.buffers = b.buffers[peer.bufferOffst : peer.bufferOffst+int64(b.bufferSize)]\n\t} else {\n\t\tif b.totalBytes-int64(b.bufferSize) < b.currentIndex {\n\t\t\tpeer.buffers = make([]byte, b.bufferSize)\n\t\t\tpeer.bufferOffst = -1\n\t\t\t//The buffer pool is empty.\n\t\t\t//return false\n\t\t} else {\n\t\t\tpeer.bufferOffst = b.currentIndex\n\t\t\tpeer.buffers = b.buffers[peer.bufferOffst : peer.bufferOffst+int64(b.bufferSize)]\n\t\t\tb.currentIndex += int64(b.bufferSize)\n\t\t}\n\t}\n\t//return true\n}", "func (dc *FixedLenByteArrayDictConverter) FillZero(out interface{}) {\n\to := out.([]parquet.FixedLenByteArray)\n\to[0] = dc.zeroVal\n\tfor i := 1; i < len(o); i *= 2 {\n\t\tcopy(o[i:], o[:i])\n\t}\n}", "func (gen *DataGen) Init(m *pktmbuf.Packet, args ...any) {\n\tdata := ndn.MakeData(args...)\n\twire, e := tlv.EncodeValueOnly(data)\n\tif e != nil {\n\t\tlogger.Panic(\"encode Data error\", zap.Error(e))\n\t}\n\n\tm.SetHeadroom(0)\n\tif e := m.Append(wire); e != nil {\n\t\tlogger.Panic(\"insufficient dataroom\", zap.Error(e))\n\t}\n\tbufBegin := unsafe.Pointer(unsafe.SliceData(m.SegmentBytes()[0]))\n\tbufEnd := unsafe.Add(bufBegin, len(wire))\n\t*gen = DataGen{\n\t\ttpl: (*C.struct_rte_mbuf)(m.Ptr()),\n\t\tmeta: unsafe.SliceData(C.DataEnc_NoMetaInfo[:]),\n\t\tcontentIov: [1]C.struct_iovec{{\n\t\t\tiov_base: bufEnd,\n\t\t}},\n\t}\n\n\td := tlv.DecodingBuffer(wire)\n\tfor _, de := range d.Elements() {\n\t\tswitch de.Type {\n\t\tcase an.TtName:\n\t\t\tgen.suffix = C.LName{\n\t\t\t\tvalue: (*C.uint8_t)(unsafe.Add(bufEnd, -len(de.After)-de.Length())),\n\t\t\t\tlength: C.uint16_t(de.Length()),\n\t\t\t}\n\t\tcase an.TtMetaInfo:\n\t\t\tgen.meta = (*C.uint8_t)(unsafe.Add(bufEnd, -len(de.WireAfter())))\n\t\tcase an.TtContent:\n\t\t\tgen.contentIov[0] = C.struct_iovec{\n\t\t\t\tiov_base: unsafe.Add(bufEnd, -len(de.After)-de.Length()),\n\t\t\t\tiov_len: C.size_t(de.Length()),\n\t\t\t}\n\t\t}\n\t}\n\n\tC.rte_pktmbuf_adj(gen.tpl, C.uint16_t(uintptr(gen.contentIov[0].iov_base)-uintptr(bufBegin)))\n\tC.rte_pktmbuf_trim(gen.tpl, C.uint16_t(C.size_t(gen.tpl.pkt_len)-gen.contentIov[0].iov_len))\n}", "func New(i int) *Buffer {\n\treturn &Buffer{\n\t\tsize: i,\n\t}\n}", "func (c *SimpleMemoryCache) Set(ctx *Context, next Next) {\n\tc.data[ctx.Key] = ctx.Value.(int64)\n\n\t// call next to make sure all memory cache ready\n\t// maybe you should check next is nil or not\n\tnext(ctx)\n}", "func BufferStorage(target uint32, size int, data unsafe.Pointer, flags uint32) {\n\tC.glowBufferStorage(gpBufferStorage, (C.GLenum)(target), (C.GLsizeiptr)(size), data, (C.GLbitfield)(flags))\n}", "func BufferStorage(target uint32, size int, data unsafe.Pointer, flags uint32) {\n\tC.glowBufferStorage(gpBufferStorage, (C.GLenum)(target), (C.GLsizeiptr)(size), data, (C.GLbitfield)(flags))\n}", "func NewBuffer() *Buffer { return globalPool.NewBuffer() }", "func (b *BufferPool) Put(data interface{}) (n int64, err error) {\n\tvar putData []byte\n\tvar putDataLength int64\n\tvar blackspaceLength int64\n\tswitch info := data.(type) {\n\tcase string:\n\t\tputData = []byte(info)\n\t\tputDataLength = int64(len(putData))\n\tcase []byte:\n\t\tputData = info\n\t\tputDataLength = int64(len(putData))\n\tdefault:\n\t\treturn 0, TYPEERROR\n\t}\n\n\tb.Lock()\n\t// free buffer size smaller than data size which will be written to.\n\tif b.Free < int64(len(putData)) {\n\t\taddRate := math.Ceil(float64(putDataLength) / float64(b.Size))\n\t\tif addRate <= 1 {\n\t\t\taddRate = 2\n\t\t}\n\t\tif b.AutoIncrement == true {\n\t\t\tblackspaceLength = b.Size*int64(addRate) - b.Used - putDataLength\n\t\t} else {\n\t\t\treturn 0, BUFFERNOTENOUGH\n\t\t}\n\t} else {\n\t\tblackspaceLength = b.Free - putDataLength\n\t}\n\tb.Data = append(b.Data[:b.Used], putData...)\n\tb.Data = append(b.Data, make([]byte, blackspaceLength)...)\n\tb.Used = b.Used + putDataLength\n\tb.Free = blackspaceLength\n\tb.Size = b.Used + b.Free\n\tb.Unlock()\n\treturn putDataLength, nil\n}", "func (c *ChannelData) grow(v int) {\n\tn := len(c.Raw) + v\n\tfor cap(c.Raw) < n {\n\t\tc.Raw = append(c.Raw, 0)\n\t}\n\tc.Raw = c.Raw[:n]\n}", "func Memset(data []byte, value byte) {\n\tif value == 0 {\n\t\tfor i := range data {\n\t\t\tdata[i] = 0\n\t\t}\n\t} else if len(data) != 0 {\n\t\tdata[0] = value\n\n\t\tfor i := 1; i < len(data); i *= 2 {\n\t\t\tcopy(data[i:], data[:i])\n\t\t}\n\t}\n}", "func (_this *StreamingReadBuffer) Init(reader io.Reader, bufferSize int, minFreeBytes int) {\n\tif cap(_this.Buffer) < bufferSize {\n\t\t_this.Buffer = make([]byte, 0, bufferSize)\n\t} else {\n\t\t_this.Buffer = _this.Buffer[:0]\n\t}\n\t_this.reader = reader\n\t_this.minFreeBytes = minFreeBytes\n}", "func (d *Object) flush() {\n\n\td.buf.Pos = offsetFieldCount\n\td.buf.WriteUint16(d.fieldCount)\n\n\td.buf.Pos = offsetSize\n\td.buf.WriteUint24(d.size)\n}", "func NewBuffer(p producer.Producer, size int, flushInterval time.Duration, logger log.Logger) *Buffer {\n\tflush := 1 * time.Second\n\tif flushInterval != 0 {\n\t\tflush = flushInterval\n\t}\n\n\tb := &Buffer{\n\t\trecords: make([]*data.Record, 0, size),\n\t\tmu: new(sync.Mutex),\n\t\tproducer: p,\n\t\tbufferSize: size,\n\t\tlogger: logger,\n\t\tshouldFlush: make(chan bool, 1),\n\t\tflushInterval: flush,\n\t\tlastFlushed: time.Now(),\n\t}\n\n\tgo b.runFlusher()\n\n\treturn b\n}", "func (r *DBReader) SetBuffer(buffer io.Reader) {\n\tr.buffer = buffer\n}" ]
[ "0.5932752", "0.5734838", "0.5678285", "0.56575704", "0.565682", "0.5643374", "0.5642318", "0.55881345", "0.5571034", "0.55051994", "0.5500698", "0.5496386", "0.5485012", "0.5478254", "0.54011256", "0.53939354", "0.53479874", "0.5335982", "0.5331352", "0.532966", "0.5309759", "0.5296057", "0.5286058", "0.52831966", "0.5281891", "0.52748287", "0.5247775", "0.52266586", "0.5222271", "0.52146494", "0.5214304", "0.5211984", "0.5196486", "0.5192103", "0.518555", "0.5175499", "0.5173198", "0.5169991", "0.5167336", "0.51523554", "0.51521516", "0.515018", "0.5145603", "0.51449215", "0.5137784", "0.51350534", "0.5117907", "0.5108699", "0.51039183", "0.508503", "0.508456", "0.50689125", "0.5051397", "0.5045432", "0.5045167", "0.5038706", "0.5033315", "0.50119543", "0.50049376", "0.5002351", "0.50016403", "0.49979174", "0.49967128", "0.4985536", "0.49722958", "0.4970573", "0.49704558", "0.49689072", "0.4968269", "0.49679992", "0.49672273", "0.4965999", "0.49625775", "0.4960239", "0.4955156", "0.49476492", "0.49473548", "0.49403834", "0.49390844", "0.49358124", "0.49352425", "0.49278685", "0.49226865", "0.49095052", "0.48937458", "0.48934686", "0.48890376", "0.48757586", "0.4874286", "0.48737428", "0.48647708", "0.48567122", "0.48567122", "0.48552528", "0.4849615", "0.48482677", "0.48477465", "0.48437017", "0.4843111", "0.4842041", "0.48395348" ]
0.0
-1
fill all or part of buffer object's data store with a fixed value
func ClearNamedBufferSubData(buffer uint32, internalformat uint32, offset int, size int, format uint32, xtype uint32, data unsafe.Pointer) { C.glowClearNamedBufferSubData(gpClearNamedBufferSubData, (C.GLuint)(buffer), (C.GLenum)(internalformat), (C.GLintptr)(offset), (C.GLsizeiptr)(size), (C.GLenum)(format), (C.GLenum)(xtype), data) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func (dataBlock *DataBlock) fill(offset uint64, buf *bytes.Buffer) uint64 {\n\tbyteToFill := dataBlock.Capacity - offset\n\tbyteActualFill := buf.Next(int(byteToFill)) // API user...\n\tif len(byteActualFill) < int(byteToFill) {\n\t\t// Not sure if the byte at `offset` would be covered by new value...???????????????\n\t\tleftover := dataBlock.Data[(int(offset) + len(byteActualFill)):]\n\t\tdataBlock.Data = append(dataBlock.Data[:offset], append(byteActualFill, leftover...)...)\n\t} else {\n\t\tdataBlock.Data = append(dataBlock.Data[:offset], byteActualFill...)\n\t}\n\treturn uint64(len(byteActualFill))\n}", "func (b *mpgBuff) fill(buff *concBuff) {\n\tbuff.Lock()\n\tn, err := b.fileDec.Read(buff.data)\n\tbuff.len = n\n\tbuff.pos = 0\n\tif err == mpg123.EOF {\n\t\tb.eof = true\n\t}\n\tbuff.Unlock()\n}", "func (b base) Fill(value uint64) {\n\tbinary.PutUvarint(b.inputBuffer[b.seedLen:], value)\n\t// base64 encoding reduce byte size\n\t// from i to o\n\tb64encoder.Encode(b.outputBuffer, b.inputBuffer)\n}", "func (r *BytesRecord) Fill(rid RID, version int, content []byte) error {\n\tr.RID = rid\n\tr.Vers = version\n\tr.Data = content\n\treturn nil\n}", "func (d *OneToOne) Set(data GenericDataType) {\n\tidx := d.writeIndex % uint64(len(d.buffer))\n\n\tnewBucket := &bucket{\n\t\tdata: data,\n\t\tseq: d.writeIndex,\n\t}\n\td.writeIndex++\n\n\tatomic.StorePointer(&d.buffer[idx], unsafe.Pointer(newBucket))\n}", "func (b *buffer) fill(need int) (err error) {\n\tb.idx = 0\n\tb.length = 0\n\n\tvar n int\n\tfor b.length < need {\n\t\tn, err = b.rd.Read(b.buf[b.length:])\n\t\tb.length += n\n\n\t\tif err == nil {\n\t\t\tcontinue\n\t\t}\n\t\treturn // err\n\t}\n\n\treturn\n}", "func (bs endecBytes) fill(offset int, fields ...interface{}) int {\n\tfor _, val := range fields {\n\t\tswitch val.(type) {\n\t\tcase byte:\n\t\t\tbs[offset] = val.(byte)\n\t\t\toffset++\n\t\tcase uint16:\n\t\t\tbinary.BigEndian.PutUint16(bs[offset:], val.(uint16))\n\t\t\toffset += 2\n\t\tcase uint32: // remaingLength\n\t\t\tn := binary.PutUvarint(bs[offset:], uint64(val.(uint32)))\n\t\t\toffset += n\n\t\tcase string:\n\t\t\tstr := val.(string)\n\t\t\tbinary.BigEndian.PutUint16(bs[offset:], uint16(len(str)))\n\t\t\toffset += 2\n\t\t\toffset += copy(bs[offset:], str)\n\t\tcase []byte:\n\t\t\toffset += copy(bs[offset:], val.([]byte))\n\t\tdefault: // unknown type\n\t\t\treturn -offset\n\t\t}\n\t}\n\treturn offset\n}", "func (al *AudioListener) setBuffer(size int) {\n\tal.Lock()\n\tdefer al.Unlock()\n\n\tal.buffer = make([]gumble.AudioPacket, 0, size)\n}", "func (b *CompactableBuffer) Update(address *EntryAddress, data []byte) error {\n\taddress.LockForWrite()\n\tdefer address.UnlockWrite()\n\theader, err := b.ReadHeader(address)\n\tif err != nil {\n\t\treturn err\n\t}\n\tbeforeUpdataDataSize := header.dataSize\n\tafterUpdateDataSize := len(data) + VarIntSize(len(data))\n\tdataSizeDelta := afterUpdateDataSize - int(beforeUpdataDataSize)\n\n\tremainingSpace := int(header.entrySize) - reservedSize - afterUpdateDataSize\n\theader.dataSize = int64(afterUpdateDataSize)\n\tif remainingSpace <= 0 {\n\t\tatomic.AddInt64(&b.dataSize, int64(-beforeUpdataDataSize))\n\t\tatomic.AddInt64(&b.entrySize, int64(-header.entrySize))\n\t\treturn b.expand(address, data)\n\t}\n\n\tatomic.AddInt64(&b.dataSize, int64(dataSizeDelta))\n\tvar target = make([]byte, 0)\n\tAppendToBytes(data, &target)\n\tif len(target) > int(header.dataSize) {\n\t\treturn io.EOF\n\t}\n\twritableBuffer := b.writableBuffer()\n\t_, err = writableBuffer.Write(address.Position()+reservedSize, target...)\n\treturn err\n}", "func (b *Binding) Set(buf uint32) {\n\tgl.BindBufferBase(gl.SHADER_STORAGE_BUFFER, b.uint32, buf)\n}", "func WriteCount(buffer []byte, offset int, value byte, valueCount int) {\n for i := 0; i < valueCount; i++ {\n buffer[offset + i] = value\n }\n}", "func (addr *Bytes) Store(val []byte) {\n\taddr.v.Store(val)\n}", "func (dc *FixedLenByteArrayDictConverter) Fill(out interface{}, val utils.IndexType) error {\n\to := out.([]parquet.FixedLenByteArray)\n\tif err := dc.ensure(val); err != nil {\n\t\treturn err\n\t}\n\to[0] = dc.dict[val]\n\tfor i := 1; i < len(o); i *= 2 {\n\t\tcopy(o[i:], o[:i])\n\t}\n\treturn nil\n}", "func (r *Ring) set(p int, v interface{}) {\n\tr.buff[r.mod(p)] = v\n}", "func (vm *VM) bufferVariable(variable Variable) {\n\tvm.bufferPush(variable.Value())\n}", "func (storage *Storage) SetValue(key string, value []byte) {\n\tfullEntity := encodeRecord(key, string(value))\n\tstorage.mutex.Lock()\n\tbytesWritten := addBlock(storage.file, fullEntity)\n\toffset := int64(storage.size) + int64(len(key)) + 8\n\tatomic.AddInt64(&storage.size, int64(bytesWritten))\n\tstorage.mutex.Unlock()\n\tstorage.store.Store(key, Coords{offset: offset, len: len(value)})\n}", "func (lvs *ValueStore) bufferChunk(v Value, c chunks.Chunk, height uint64, hints Hints) {\n\tlvs.pendingMu.Lock()\n\tdefer lvs.pendingMu.Unlock()\n\th := c.Hash()\n\td.Chk.NotZero(height)\n\tlvs.pendingPuts[h] = pendingChunk{c, height, hints}\n\tlvs.pendingPutSize += uint64(len(c.Data()))\n\n\tputChildren := func(parent hash.Hash) (dataPut int) {\n\t\tpc, present := lvs.pendingPuts[parent]\n\t\td.Chk.True(present)\n\t\tv := DecodeValue(pc.c, lvs)\n\t\tv.WalkRefs(func(grandchildRef Ref) {\n\t\t\tif pc, present := lvs.pendingPuts[grandchildRef.TargetHash()]; present {\n\t\t\t\tlvs.bs.SchedulePut(pc.c, pc.height, pc.hints)\n\t\t\t\tdataPut += len(pc.c.Data())\n\t\t\t\tdelete(lvs.pendingPuts, grandchildRef.TargetHash())\n\t\t\t}\n\t\t})\n\t\treturn\n\t}\n\n\t// Enforce invariant (1)\n\tif height > 1 {\n\t\tv.WalkRefs(func(childRef Ref) {\n\t\t\tchildHash := childRef.TargetHash()\n\t\t\tif _, present := lvs.pendingPuts[childHash]; present {\n\t\t\t\tlvs.pendingParents[h] = height\n\t\t\t} else {\n\t\t\t\t// Shouldn't be able to be in pendingParents without being in pendingPuts\n\t\t\t\t_, present := lvs.pendingParents[childHash]\n\t\t\t\td.Chk.False(present)\n\t\t\t}\n\n\t\t\tif _, present := lvs.pendingParents[childHash]; present {\n\t\t\t\tlvs.pendingPutSize -= uint64(putChildren(childHash))\n\t\t\t\tdelete(lvs.pendingParents, childHash)\n\t\t\t}\n\t\t})\n\t}\n\n\t// Enforce invariant (2)\n\tfor lvs.pendingPutSize > lvs.pendingPutMax {\n\t\tvar tallest hash.Hash\n\t\tvar height uint64 = 0\n\t\tfor parent, ht := range lvs.pendingParents {\n\t\t\tif ht > height {\n\t\t\t\ttallest = parent\n\t\t\t\theight = ht\n\t\t\t}\n\t\t}\n\t\tif height == 0 { // This can happen if there are no pending parents\n\t\t\tvar pc pendingChunk\n\t\t\tfor tallest, pc = range lvs.pendingPuts {\n\t\t\t\t// Any pendingPut is as good as another in this case, so take the first one\n\t\t\t\tbreak\n\t\t\t}\n\t\t\tlvs.bs.SchedulePut(pc.c, pc.height, pc.hints)\n\t\t\tlvs.pendingPutSize -= uint64(len(pc.c.Data()))\n\t\t\tdelete(lvs.pendingPuts, tallest)\n\t\t\tcontinue\n\t\t}\n\n\t\tlvs.pendingPutSize -= uint64(putChildren(tallest))\n\t\tdelete(lvs.pendingParents, tallest)\n\t}\n}", "func (d *Object) flush() {\n\n\td.buf.Pos = offsetFieldCount\n\td.buf.WriteUint16(d.fieldCount)\n\n\td.buf.Pos = offsetSize\n\td.buf.WriteUint24(d.size)\n}", "func (dc *FixedLenByteArrayDictConverter) FillZero(out interface{}) {\n\to := out.([]parquet.FixedLenByteArray)\n\to[0] = dc.zeroVal\n\tfor i := 1; i < len(o); i *= 2 {\n\t\tcopy(o[i:], o[:i])\n\t}\n}", "func (dc *ByteArrayDictConverter) FillZero(out interface{}) {\n\to := out.([]parquet.ByteArray)\n\to[0] = dc.zeroVal\n\tfor i := 1; i < len(o); i *= 2 {\n\t\tcopy(o[i:], o[:i])\n\t}\n}", "func (w *Writer) SetBuffer(raw []byte) {\n\tif w.err != nil {\n\t\treturn\n\t}\n\tw.b = w.b[:0]\n\tw.b = append(w.b, raw...)\n}", "func (b *buffer) grow() {\n\t// ugh all these atomics\n\tatomic.AddUint32(&b.free, uint32(len(b.data)))\n\tatomic.AddUint32(&b.mask, atomic.LoadUint32(&b.mask))\n\tatomic.AddUint32(&b.mask, 1)\n\tatomic.AddUint32(&b.bits, 1)\n\n\tnext := make([]unsafe.Pointer, 2*len(b.data))\n\tcopy(next, b.data)\n\n\t// UGH need to do this with atomics. one pointer + 2 uint64 calls?\n\tb.data = next\n}", "func (p *movingAverageProcessor) addBufferData(index int, data interface{}, namespace string) error {\n\tif _, ok := p.movingAverageMap[namespace]; ok {\n\t\tif index >= len(p.movingAverageMap[namespace].movingAverageBuf) {\n\t\t\treturn errors.New(\"Incorrect value of index, trying to access non-existing element of buffer\")\n\t\t}\n\t\tp.movingAverageMap[namespace].movingAverageBuf[index] = data\n\t\treturn nil\n\t} else {\n\t\treturn errors.New(\"Namespace is not present in the map\")\n\t}\n}", "func (b *Buf) Reset() { b.b = b.b[:0] }", "func (self Source) SetBuffer(buffer Buffer) {\n\tself.Seti(AlBuffer, int32(buffer))\n}", "func BufferStorage(target uint32, size int, data unsafe.Pointer, flags uint32) {\n\tsyscall.Syscall6(gpBufferStorage, 4, uintptr(target), uintptr(size), uintptr(data), uintptr(flags), 0, 0)\n}", "func (s *Arena) putVal(v y.ValueStruct) uint32 {\n\tl := uint32(v.EncodedSize())\n\toffset := s.allocate(l) - l\n\tbuf := s.data[offset : offset+l]\n\tv.Encode(buf)\n\treturn offset\n}", "func ringBufferInitBuffer(buflen uint32, rb *ringBuffer) {\n\tvar new_data []byte\n\tvar i uint\n\tsize := 2 + int(buflen) + int(kSlackForEightByteHashingEverywhere)\n\tif cap(rb.data_) < size {\n\t\tnew_data = make([]byte, size)\n\t} else {\n\t\tnew_data = rb.data_[:size]\n\t}\n\tif rb.data_ != nil {\n\t\tcopy(new_data, rb.data_[:2+rb.cur_size_+uint32(kSlackForEightByteHashingEverywhere)])\n\t}\n\n\trb.data_ = new_data\n\trb.cur_size_ = buflen\n\trb.buffer_ = rb.data_[2:]\n\trb.data_[1] = 0\n\trb.data_[0] = rb.data_[1]\n\tfor i = 0; i < kSlackForEightByteHashingEverywhere; i++ {\n\t\trb.buffer_[rb.cur_size_+uint32(i)] = 0\n\t}\n}", "func (c *ChannelData) grow(v int) {\n\tn := len(c.Raw) + v\n\tfor cap(c.Raw) < n {\n\t\tc.Raw = append(c.Raw, 0)\n\t}\n\tc.Raw = c.Raw[:n]\n}", "func (vm *VM) bufferPush(data string) {\n\tnewBuffer := &buffer{\n\t\tprevious: vm.buffer,\n\t\tvalue: data,\n\t}\n\tvm.buffer = newBuffer\n}", "func Memset(data []byte, value byte) {\n\tif value == 0 {\n\t\tfor i := range data {\n\t\t\tdata[i] = 0\n\t\t}\n\t} else if len(data) != 0 {\n\t\tdata[0] = value\n\n\t\tfor i := 1; i < len(data); i *= 2 {\n\t\t\tcopy(data[i:], data[:i])\n\t\t}\n\t}\n}", "func (src *Source) SetNewBuffer() {\n\tsrc.buf = make([]byte, 64)\n}", "func (dc *ByteArrayDictConverter) Fill(out interface{}, val utils.IndexType) error {\n\to := out.([]parquet.ByteArray)\n\tif err := dc.ensure(val); err != nil {\n\t\treturn err\n\t}\n\to[0] = dc.dict[val]\n\tfor i := 1; i < len(o); i *= 2 {\n\t\tcopy(o[i:], o[:i])\n\t}\n\treturn nil\n}", "func (b *Ring) push(value interface{}) {\n\tb.lock.Lock()\n\tdefer b.lock.Unlock()\n\tif len(b.buf) == 0 || b.size == 0 { // nothing to do\n\t\treturn\n\t}\n\tnext := Next(1, b.head, len(b.buf))\n\tb.buf[next] = value\n\tb.head = next\n\t// note that the oldest is auto pruned, when size== capacity, but with the size attribute we know it has been discarded\n}", "func (d *Display) resetBuffer() {\n\td.width = d.device.Width()\n\td.height = d.device.Height()\n\td.buffer = make([][]byte, d.height)\n\tfor y := range d.buffer {\n\t\td.buffer[y] = make([]byte, d.width)\n\t}\n}", "func (rb *RingBuffer) Add(value stats.Record) {\n\trb.lock.Lock()\n\tdefer rb.lock.Unlock()\n\trb.data[rb.seq%uint64(len(rb.data))] = value\n\trb.seq++\n}", "func (z nat) setBytes(buf []byte) nat {\n\tz = z.make((len(buf) + _S - 1) / _S)\n\n\tk := 0\n\ts := uint(0)\n\tvar d Word\n\tfor i := len(buf); i > 0; i-- {\n\t\td |= Word(buf[i-1]) << s\n\t\tif s += 8; s == _S*8 {\n\t\t\tz[k] = d\n\t\t\tk++\n\t\t\ts = 0\n\t\t\td = 0\n\t\t}\n\t}\n\tif k < len(z) {\n\t\tz[k] = d\n\t}\n\n\treturn z.norm()\n}", "func (b *Buffer) Sync() {\n\tb.SetArea(b.Bounds())\n}", "func (dc *Float32DictConverter) Fill(out interface{}, val utils.IndexType) error {\n\to := out.([]float32)\n\tif err := dc.ensure(val); err != nil {\n\t\treturn err\n\t}\n\to[0] = dc.dict[val]\n\tfor i := 1; i < len(o); i *= 2 {\n\t\tcopy(o[i:], o[:i])\n\t}\n\treturn nil\n}", "func (dc *Float64DictConverter) Fill(out interface{}, val utils.IndexType) error {\n\to := out.([]float64)\n\tif err := dc.ensure(val); err != nil {\n\t\treturn err\n\t}\n\to[0] = dc.dict[val]\n\tfor i := 1; i < len(o); i *= 2 {\n\t\tcopy(o[i:], o[:i])\n\t}\n\treturn nil\n}", "func (self *ValueStore) Append(options WriteOptions, instanceId uint64, buffer []byte, fileIdStr *string) error {\n begin := util.NowTimeMs()\n\n self.mutex.Lock()\n defer self.mutex.Unlock()\n\n bufferLen := len(buffer)\n len := util.UINT64SIZE + bufferLen\n tmpBufLen := len + util.INT32SIZE\n\n var fileId int32\n var offset uint32\n err := self.getFileId(uint32(tmpBufLen), &fileId, &offset)\n if err != nil {\n return err\n }\n\n tmpBuf := make([]byte, tmpBufLen)\n util.EncodeInt32(tmpBuf, 0, int32(len))\n util.EncodeUint64(tmpBuf, util.INT32SIZE, instanceId)\n copy(tmpBuf[util.INT32SIZE+util.UINT64SIZE:], []byte(buffer))\n\n ret, err := self.file.Write(tmpBuf)\n if ret != tmpBufLen {\n err = fmt.Errorf(\"writelen %d not equal to %d,buffer size %d\",\n ret, tmpBufLen, bufferLen)\n return err\n }\n\n if options.Sync {\n self.file.Sync()\n }\n\n self.nowFileOffset += uint64(tmpBufLen)\n\n ckSum := util.Crc32(0, tmpBuf[util.INT32SIZE:], common.CRC32_SKIP)\n self.EncodeFileId(fileId, uint64(offset), ckSum, fileIdStr)\n\n useMs := util.NowTimeMs() - begin\n\n log.Info(\"ok, offset %d fileid %d cksum %d instanceid %d buffersize %d usetime %d ms sync %t\",\n offset, fileId, ckSum, instanceId, bufferLen, useMs, options.Sync)\n return nil\n}", "func (debugging *debuggingOpenGL) BufferData(target uint32, size int, data interface{}, usage uint32) {\n\tdebugging.recordEntry(\"BufferData\", target, size, data, usage)\n\tdebugging.gl.BufferData(target, size, data, usage)\n\tdebugging.recordExit(\"BufferData\")\n}", "func newBuffer(bits uint32) buffer {\n\tvar b buffer\n\tb.data = make([]unsafe.Pointer, 1<<bits)\n\tb.free = 1 << bits\n\tb.mask = 1<<bits - 1\n\tb.bits = bits\n\treturn b\n}", "func BufferStorage(target uint32, size int, data unsafe.Pointer, flags uint32) {\n C.glowBufferStorage(gpBufferStorage, (C.GLenum)(target), (C.GLsizeiptr)(size), data, (C.GLbitfield)(flags))\n}", "func (src *Source) SetBuffer(buf []byte) {\n\tsrc.buf = buf\n}", "func (c *SimpleMemoryCache) Set(ctx *Context, next Next) {\n\tc.data[ctx.Key] = ctx.Value.(int64)\n\n\t// call next to make sure all memory cache ready\n\t// maybe you should check next is nil or not\n\tnext(ctx)\n}", "func (w *buffer) reset() {\n\tfor i := range (*w)[:cap(*w)] {\n\t\t(*w)[i] = 0\n\t}\n\t*w = (*w)[:0]\n}", "func (wb *fieldWriteBuf) reset(seq int, label string) {\n\twb.seq = seq\n\twb.label = label\n\twb.defaultBuf = wb.defaultBuf[:0]\n\twb.blobBuf = wb.blobBuf[:0]\n\twb.prevString = wb.prevString[:0]\n\twb.prevInt64Value0 = 0\n\twb.prevInt64Value1 = 0\n\twb.startAddr = biopb.Coord{biopb.InvalidRefID, biopb.InvalidPos, 0}\n\twb.endAddr = biopb.Coord{biopb.InvalidRefID, biopb.InvalidPos, 0}\n\twb.numRecords = 0\n}", "func (b *Buffer) Clear() {\n\tb.currentSize = 0\n\tb.contents = map[entity.Key]inventoryapi.PostDeltaBody{}\n}", "func (p *Lexer) fill() {\n\n\tif p.r >= 0 && p.r < bufSize {\n\t\treturn\n\t}\n\n\t// Read new data: try a limited number of times.\n\t// The first time read the full buffer, else only half.\n\toffset := 0\n\tif p.r >= 0 {\n\t\tcopy(p.buf, p.buf[halfSize:])\n\t\tp.r = halfSize\n\t\toffset = halfSize\n\t} else {\n\t\tp.r = 0\n\t}\n\n\tfor i := maxConsecutiveEmptyReads; i > 0; i-- {\n\t\tn, err := p.rd.Read(p.buf[offset:])\n\t\tif n < 0 {\n\t\t\tpanic(errNegativeRead)\n\t\t}\n\t\tif err != nil {\n\t\t\tp.err = err\n\t\t\tbreak\n\t\t}\n\n\t\toffset += n\n\t\tif offset >= halfSize {\n\t\t\tbreak\n\t\t}\n\t}\n\n\tp.lastByte = offset\n}", "func (b *Ring) Add(values ...interface{}) error {\n\tif len(values) == 0 {\n\t\treturn nil\n\t}\n\tif len(values) == 1 {\n\t\treturn b.add(values[0])\n\n\t}\n\tb.lock.Lock()\n\tdefer b.lock.Unlock()\n\n\t//check that we will be able to fill it.\n\tif b.size+len(values) > len(b.buf) {\n\t\treturn ErrFull\n\t}\n\n\t//alg: add as much as possible in a single copy, and repeat until exhaustion\n\n\tfor len(values) > 0 {\n\t\t// is all about slicing right\n\t\t//\n\t\t// the extra space to add value too can be either\n\t\t// from next position, to the end of the buffer\n\t\t// or from the beginning to the tail of the ring\n\n\t\tnext := Next(1, b.head, len(b.buf))\n\n\t\t//tail := Index(-1, b.head, b.size, len(b.buf)\n\n\t\t// tail is the absolute index of the buffer tail\n\t\t// next is the absolute index of the buffer head+1\n\t\t//I want to write as much as possible after next.\n\t\t// so it's either till the end, or till the tail\n\t\t// if the ring's tail is behind we can use the slice from next to the end\n\t\t// if the ring's tail is ahead we can't use the whole slice.\n\t\t// BUT, we know that there is enough room left, so we don't care if the slice is \"too\" big\n\t\t// Therefore, instead of dealing with all the cases\n\t\t// we always use:\n\t\ttgt := b.buf[next:]\n\t\t// a slice of the buffer, that we'll used to write into\n\n\t\t//we copy as much as possible.\n\t\tn := copy(tgt, values) //n is the number of copied values\n\n\t\tif n == 0 { // could not write ! the buf is exhausted\n\t\t\tpanic(ErrFull) // because we have tested this case before,I'd rather panic than infinite loop\n\t\t}\n\n\t\t// we adjust local variables (latest has moved, and so has size)\n\t\tb.head = Next(n, b.head, len(b.buf))\n\t\tb.size += n // increase the inner size\n\n\t\t// we remove from the source, the value copied.\n\t\tvalues = values[n:]\n\t}\n\treturn nil\n\n}", "func (b *Ring) add(val interface{}) error {\n\tif b.size >= len(b.buf) {\n\t\treturn ErrFull\n\t}\n\tb.lock.Lock()\n\tdefer b.lock.Unlock()\n\n\tnext := Next(1, b.head, len(b.buf))\n\tb.buf[next] = val\n\tb.head = next\n\tb.size++ // increase the inner size\n\treturn nil\n}", "func (r *ringBufferProvider) Feed(elem interface{}) {\n\trbs := uint64(len(r.ringBuffer))\n\tfor i := 0; ; i++ {\n\t\tringRead := atomic.LoadUint64(&r.ringRead)\n\t\tringWrite := atomic.LoadUint64(&r.ringWrite)\n\t\tringWAlloc := atomic.LoadUint64(&r.ringWAlloc)\n\t\tringWriteNextVal := ringWrite + 1\n\t\tif ringWrite == ringWAlloc && ringWriteNextVal-uint64(len(r.ringBuffer)) != ringRead {\n\t\t\tif atomic.CompareAndSwapUint64(&r.ringWAlloc, ringWAlloc, ringWriteNextVal) {\n\t\t\t\tr.ringBuffer[ringWrite%rbs] = elem\n\t\t\t\tif !atomic.CompareAndSwapUint64(&r.ringWrite, ringWrite, ringWriteNextVal) {\n\t\t\t\t\tpanic(\"failed to commit allocated write in ring-buffer\")\n\t\t\t\t}\n\t\t\t\treturn\n\t\t\t}\n\t\t}\n\t\truntime.Gosched()\n\t\ttime.Sleep(time.Duration(i) * time.Nanosecond) // notice nanos vs micros\n\t}\n}", "func (b *RecordBuffer) Flush() {\n\tb.recordsInBuffer = b.recordsInBuffer[:0]\n\tb.sequencesInBuffer = b.sequencesInBuffer[:0]\n}", "func (b *BufferPool) Flush(interface{}) {\n\tb.Lock()\n\tb.Data = make([]byte, b.Size)\n\tb.Unlock()\n}", "func (b *Ring) Push(values ...interface{}) {\n\tif len(values) == 0 || b.size == 0 {\n\t\treturn\n\t}\n\tif len(values) == 1 {\n\t\tb.push(values[0])\n\t\treturn\n\t}\n\tb.lock.Lock()\n\tdefer b.lock.Unlock()\n\t//alg: just write as much as you need after next\n\n\t// if len(values) is greater than b.size it is useless to fully write it down.\n\t// We know that the first items will be overwritten.\n\t// so we slice down values in that case\n\n\tif len(values) > b.size {\n\t\t//only write down the last b.size ones\n\t\tvalues = values[len(values)-b.size:] // cut the one before, there are useless.\n\t}\n\t// now we need to write down values (that is never greater than b.size)\n\n\t// next is the absolute index of the buffer head+1\n\tnext := Next(1, b.head, len(b.buf))\n\n\t// we are going to write down from 'next' toward the end of the buffer.\n\ttgt := b.buf[next:]\n\n\t//we copy as much as possible.\n\tn := copy(tgt, values) //n is the number of copied values\n\n\t// if we have exhausted the buffer (we have reached the end of the buffer) we need to start again from zero this time.\n\tif n < len(values) { // there are still values to copy\n\t\tcopy(b.buf, values[n:]) //copy remaining from the begining this time.\n\t}\n\t//move the head\n\tb.head = Next(len(values), b.head, len(b.buf))\n\n}", "func (dc *Float32DictConverter) FillZero(out interface{}) {\n\to := out.([]float32)\n\to[0] = dc.zeroVal\n\tfor i := 1; i < len(o); i *= 2 {\n\t\tcopy(o[i:], o[:i])\n\t}\n}", "func (b *Ring) SetCapacity(capacity int) {\n\tb.lock.Lock()\n\tdefer b.lock.Unlock()\n\n\tif capacity < b.size {\n\t\tcapacity = b.size\n\t}\n\tif capacity == len(b.buf) { //nothing to be done\n\t\treturn\n\t}\n\n\tnbuf := make([]interface{}, capacity)\n\n\t// now that the new capacity is enough we just copy down the buffer\n\n\t//there are only two cases:\n\t// either the values are contiguous, then they goes from\n\t// tail to head\n\t// or there are splitted in two:\n\t// tail to buffer's end\n\t// 0 to head.\n\n\thead := b.head\n\ttail := Index(-1, head, b.size, len(b.buf))\n\n\t// we are not going to copy the buffer in the same state (absolute position of head and tail)\n\t// instead, we are going to select the simplest solution.\n\tif tail < head { //data is in one piece\n\t\tcopy(nbuf, b.buf[tail:head+1])\n\t} else { //two pieces\n\t\t//copy as much as possible to the end of the buf\n\t\tn := copy(nbuf, b.buf[tail:])\n\t\t//and then from the beginning\n\t\tcopy(nbuf[n:], b.buf[:head+1])\n\t}\n\tb.buf = nbuf\n\tb.head = b.size - 1\n\treturn\n}", "func (buf *Buffer) reset() {\n\tbuf.DNCReports = nil\n\tbuf.DNCReports = make([]DNCReport, 0)\n\tbuf.CNIReports = nil\n\tbuf.CNIReports = make([]CNIReport, 0)\n\tbuf.NPMReports = nil\n\tbuf.NPMReports = make([]NPMReport, 0)\n\tbuf.CNSReports = nil\n\tbuf.CNSReports = make([]CNSReport, 0)\n\tpayloadSize = 0\n}", "func (d *datastoreValues) set(data map[string][]byte) {\n\td.mu.Lock()\n\tdefer d.mu.Unlock()\n\n\tif d.Data == nil {\n\t\td.Data = data\n\t\treturn\n\t}\n\n\tfor key, value := range data {\n\t\td.Data[key] = value\n\t}\n}", "func BufferData(target uint32, size int, data unsafe.Pointer, usage uint32) {\n\tsyscall.Syscall6(gpBufferData, 4, uintptr(target), uintptr(size), uintptr(data), uintptr(usage), 0, 0)\n}", "func hostSetBytes(objId int32, keyId int32, typeId int32, value *byte, size int32)", "func (g *GrowingBuffer) Values() interface{} {\n return g.bufferPtr.Elem().Interface()\n}", "func (b *Buffer) Data() []byte { return b.data }", "func (b *Buffer) updateFirst(fsize uint64) {\n\tif b.biggest == 0 {\n\t\t// Just starting out, no need to update.\n\t\treturn\n\t}\n\n\tvar (\n\t\tstart = b.last % b.capacity\n\t\tend = (start + fsize) % b.capacity\n\t\twrapping = end <= start\n\t)\n\n\tif start == end {\n\t\tb.length = 0\n\t\tb.first = b.last\n\t\treturn\n\t}\n\n\tfor {\n\t\tif b.first == b.last {\n\t\t\t// b can fit only the new incoming record.\n\t\t\treturn\n\t\t}\n\n\t\tfirstWrapped := b.first % b.capacity\n\n\t\tif wrapping {\n\t\t\tif end <= firstWrapped && firstWrapped < start {\n\t\t\t\treturn\n\t\t\t}\n\t\t} else {\n\t\t\tif end <= firstWrapped {\n\t\t\t\treturn\n\t\t\t}\n\t\t\tif start > firstWrapped {\n\t\t\t\treturn\n\t\t\t}\n\t\t}\n\n\t\tsecond := b.nextFrameOffset(b.first)\n\t\tb.length -= (second - b.first - total)\n\t\tb.first = second\n\n\t\t// May need to discard multiple records at the begining.\n\t}\n}", "func (b *Builder) Buffer(count int) value.Pointer {\n\tpointerSize := b.memoryLayout.GetPointer().GetSize()\n\tdynamic := false\n\tsize := 0\n\n\t// Examine the stack to see where these values came from\n\tfor i := 0; i < count; i++ {\n\t\te := b.stack[len(b.stack)-i-1]\n\t\top := b.instructions[e.idx]\n\t\tty := e.ty\n\t\tif _, isPush := op.(asm.Push); !isPush {\n\t\t\t// Values that have made their way on to the stack from non-constant\n\t\t\t// sources cannot be put in the constant buffer.\n\t\t\tdynamic = true\n\t\t}\n\t\tswitch ty {\n\t\tcase protocol.Type_ConstantPointer, protocol.Type_VolatilePointer:\n\t\t\t// Pointers cannot be put into the constant buffer as they are remapped\n\t\t\t// by the VM\n\t\t\tdynamic = true\n\t\t}\n\n\t\tsize += ty.Size(pointerSize)\n\t}\n\n\tif dynamic {\n\t\t// At least one of the values was not from a Push()\n\t\t// Build the buffer in temporary memory at replay time.\n\t\tbuf := b.AllocateTemporaryMemory(uint64(size))\n\t\toffset := size\n\t\tfor i := 0; i < count; i++ {\n\t\t\te := b.stack[len(b.stack)-1]\n\t\t\toffset -= e.ty.Size(pointerSize)\n\t\t\tb.Store(buf.Offset(uint64(offset)))\n\t\t}\n\t\treturn buf\n\t}\n\t// All the values are constant.\n\t// Move the pushed values into a constant memory buffer.\n\tvalues := make([]value.Value, count)\n\tfor i := 0; i < count; i++ {\n\t\te := b.stack[len(b.stack)-1]\n\t\tvalues[count-i-1] = b.instructions[e.idx].(asm.Push).Value\n\t\tb.removeInstruction(e.idx)\n\t\tb.popStack()\n\t}\n\treturn b.constantMemory.writeValues(values...)\n}", "func (f *File) FillRecord(r int) error {\n\t_, slabsize := f.Header.slabs()\n\tfor i := range f.Header.vars {\n\t\tvv := &f.Header.vars[i]\n\t\tif !vv.isRecordVariable() {\n\t\t\tcontinue\n\t\t}\n\t\tbegin := vv.begin + int64(r)*slabsize\n\t\tend := begin + pad4(vv.vSize())\n\t\tif err := fill(f.rw, begin, end, vv.fillValue(), vv.dtype); err != nil {\n\t\t\treturn err\n\t\t}\n\t}\n\treturn nil\n}", "func (g *GLTF) loadBuffer(bufIdx int) ([]byte, error) {\n\n\t// Check if provided buffer index is valid\n\tif bufIdx < 0 || bufIdx >= len(g.Buffers) {\n\t\treturn nil, fmt.Errorf(\"invalid buffer index\")\n\t}\n\tbufData := &g.Buffers[bufIdx]\n\t// Return cached if available\n\tif bufData.cache != nil {\n\t\tlog.Debug(\"Fetching Buffer %d (cached)\", bufIdx)\n\t\treturn bufData.cache, nil\n\t}\n\tlog.Debug(\"Loading Buffer %d\", bufIdx)\n\n\t// If buffer URI use the chunk data field\n\tif bufData.Uri == \"\" {\n\t\treturn g.data, nil\n\t}\n\n\t// Checks if buffer URI is a data URI\n\tvar data []byte\n\tvar err error\n\tif isDataURL(bufData.Uri) {\n\t\tdata, err = loadDataURL(bufData.Uri)\n\t} else {\n\t\t// Try to load buffer from file\n\t\tdata, err = g.loadFileBytes(bufData.Uri)\n\t}\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\n\t// Checks data length\n\tif len(data) != bufData.ByteLength {\n\t\treturn nil, fmt.Errorf(\"buffer:%d read data length:%d expected:%d\", bufIdx, len(data), bufData.ByteLength)\n\t}\n\t// Cache buffer data\n\tg.Buffers[bufIdx].cache = data\n\tlog.Debug(\"cache data:%v\", len(bufData.cache))\n\treturn data, nil\n}", "func (c *fakeRedisConn) SetReadBuffer(bytes int) {}", "func (bp *bufferPool) putBuffer(b *buffer) {\n\tbp.lock.Lock()\n\tif bp.freeBufNum < 1000 {\n\t\tb.next = bp.freeList\n\t\tbp.freeList = b\n\t\tbp.freeBufNum++\n\t}\n\tbp.lock.Unlock()\n}", "func (geom Geometry) Buffer(distance float64, segments int) Geometry {\n\tnewGeom := C.OGR_G_Buffer(geom.cval, C.double(distance), C.int(segments))\n\treturn Geometry{newGeom}\n}", "func (fm *FinalModelStructBytes) Set(fbeValue *StructBytes) (int, error) {\n fm.buffer.Shift(fm.FBEOffset())\n fbeResult, err := fm.SetFields(fbeValue)\n fm.buffer.Unshift(fm.FBEOffset())\n return fbeResult, err\n}", "func (s *scratch) add(c byte) {\n\tif s.fill+1 >= cap(s.data) {\n\t\ts.grow()\n\t}\n\n\ts.data[s.fill] = c\n\ts.fill++\n}", "func (p *byteBufferPool) give(buf *[]byte) {\n\tif buf == nil {\n\t\treturn\n\t}\n\tsize := cap(*buf)\n\tslot := p.slot(size)\n\tif slot == errSlot {\n\t\treturn\n\t}\n\tif size != int(p.pool[slot].defaultSize) {\n\t\treturn\n\t}\n\tp.pool[slot].pool.Put(buf)\n}", "func (b *Buffer) Reset() {\n\tb.Line = b.Line[:0]\n\tb.Val = b.Val[:0]\n}", "func (d *decoder) buffer() []byte {\n\tif d.buf == nil {\n\t\td.buf = make([]byte, 8)\n\t}\n\treturn d.buf\n}", "func (b *Buffer) Clear() {\n\tb.series = make(map[string]*influxdb.Series)\n\tb.size = 0\n}", "func (e rawEntry) value(buf []byte) rawValue { return buf[e.ptr():][:e.sz()] }", "func (ms *MemStore) SetAll(data map[string]io.WriterTo) error {\n\tvar err error\n\tms.mu.Lock()\n\tfor k, d := range data {\n\t\tvar buf memio.Buffer\n\t\tif _, err = d.WriteTo(&buf); err != nil {\n\t\t\tbreak\n\t\t}\n\t\tms.data[k] = buf\n\t}\n\tms.mu.Unlock()\n\treturn err\n}", "func NewBuffer(aSlice interface{}) *Buffer {\n return &Buffer{buffer: sliceValue(aSlice, false), handler: valueHandler{}}\n}", "func (c webgl) BufferDataX(target Enum, d interface{}, usage Enum) {\n\tc.ctx.Call(\"bufferData\", target, conv(d), usage)\n}", "func (b *Buffer) AttachNew() {\n b.data = make([]byte, 0)\n b.size = 0\n b.offset = 0\n}", "func (gen *DataGen) Init(m *pktmbuf.Packet, args ...any) {\n\tdata := ndn.MakeData(args...)\n\twire, e := tlv.EncodeValueOnly(data)\n\tif e != nil {\n\t\tlogger.Panic(\"encode Data error\", zap.Error(e))\n\t}\n\n\tm.SetHeadroom(0)\n\tif e := m.Append(wire); e != nil {\n\t\tlogger.Panic(\"insufficient dataroom\", zap.Error(e))\n\t}\n\tbufBegin := unsafe.Pointer(unsafe.SliceData(m.SegmentBytes()[0]))\n\tbufEnd := unsafe.Add(bufBegin, len(wire))\n\t*gen = DataGen{\n\t\ttpl: (*C.struct_rte_mbuf)(m.Ptr()),\n\t\tmeta: unsafe.SliceData(C.DataEnc_NoMetaInfo[:]),\n\t\tcontentIov: [1]C.struct_iovec{{\n\t\t\tiov_base: bufEnd,\n\t\t}},\n\t}\n\n\td := tlv.DecodingBuffer(wire)\n\tfor _, de := range d.Elements() {\n\t\tswitch de.Type {\n\t\tcase an.TtName:\n\t\t\tgen.suffix = C.LName{\n\t\t\t\tvalue: (*C.uint8_t)(unsafe.Add(bufEnd, -len(de.After)-de.Length())),\n\t\t\t\tlength: C.uint16_t(de.Length()),\n\t\t\t}\n\t\tcase an.TtMetaInfo:\n\t\t\tgen.meta = (*C.uint8_t)(unsafe.Add(bufEnd, -len(de.WireAfter())))\n\t\tcase an.TtContent:\n\t\t\tgen.contentIov[0] = C.struct_iovec{\n\t\t\t\tiov_base: unsafe.Add(bufEnd, -len(de.After)-de.Length()),\n\t\t\t\tiov_len: C.size_t(de.Length()),\n\t\t\t}\n\t\t}\n\t}\n\n\tC.rte_pktmbuf_adj(gen.tpl, C.uint16_t(uintptr(gen.contentIov[0].iov_base)-uintptr(bufBegin)))\n\tC.rte_pktmbuf_trim(gen.tpl, C.uint16_t(C.size_t(gen.tpl.pkt_len)-gen.contentIov[0].iov_len))\n}", "func putBuffer(buf *bytes.Buffer) {\n\tbuf.Reset()\n\tbufferPool.Put(buf)\n}", "func (access FloatAccess) Set(row int, val float64) {\n access.rawData[access.indices[row]] = val\n}", "func (p *Buffer) SetBuf(s []byte) {\n\tp.buf = s\n\tp.index = 0\n\tp.length = len(s)\n}", "func (b *Buffer) Reset() {\n\tb.B = b.B[:0]\n}", "func Set(height uint64, digest blockdigest.Digest, version uint16, timestamp uint64) {\n\n\tglobalData.Lock()\n\n\tglobalData.height = height\n\tglobalData.previousBlock = digest\n\tglobalData.previousVersion = version\n\tglobalData.previousTimestamp = timestamp\n\n\tglobalData.Unlock()\n}", "func (dc *Float64DictConverter) FillZero(out interface{}) {\n\to := out.([]float64)\n\to[0] = dc.zeroVal\n\tfor i := 1; i < len(o); i *= 2 {\n\t\tcopy(o[i:], o[:i])\n\t}\n}", "func (b *Buffer) Reset() {\n b.size = 0\n b.offset = 0\n}", "func (rb *ringBuffer) read(f func([]byte)) {\n\tvar dataHead, dataTail uint64\n\n\tdataTail = rb.metadata.DataTail\n\tdataHead = atomic.LoadUint64(&rb.metadata.DataHead)\n\n\tfor dataTail < dataHead {\n\t\tdataBegin := dataTail % uint64(len(rb.data))\n\t\tdataEnd := dataHead % uint64(len(rb.data))\n\n\t\tvar data []byte\n\t\tif dataEnd >= dataBegin {\n\t\t\tdata = rb.data[dataBegin:dataEnd]\n\t\t} else {\n\t\t\tdata = rb.data[dataBegin:]\n\t\t\tdata = append(data, rb.data[:dataEnd]...)\n\t\t}\n\n\t\tf(data)\n\n\t\t//\n\t\t// Write dataHead to dataTail to let kernel know that we've\n\t\t// consumed the data up to it.\n\t\t//\n\t\tdataTail = dataHead\n\t\tatomic.StoreUint64(&rb.metadata.DataTail, dataTail)\n\n\t\t// Update dataHead in case it has been advanced in the interim\n\t\tdataHead = atomic.LoadUint64(&rb.metadata.DataHead)\n\t}\n}", "func (b *Buffer) AttachBytes(buffer []byte, offset int, size int) {\n if len(buffer) < size {\n panic(\"invalid buffer\")\n }\n if size <= 0 {\n panic(\"invalid size\")\n }\n if offset > size {\n panic(\"invalid offset\")\n }\n\n b.data = buffer\n b.size = size\n b.offset = offset\n}", "func (st *Stat) Fill(ost *Stat) {\n\tif ost.Following >= 0 {\n\t\tst.Following = ost.Following\n\t}\n\tif ost.Whisper >= 0 {\n\t\tst.Whisper = ost.Whisper\n\t}\n\tif ost.Black >= 0 {\n\t\tst.Black = ost.Black\n\t}\n\tif ost.Follower >= 0 {\n\t\tst.Follower = ost.Follower\n\t}\n}", "func (b *BufferPool) Put(data interface{}) (n int64, err error) {\n\tvar putData []byte\n\tvar putDataLength int64\n\tvar blackspaceLength int64\n\tswitch info := data.(type) {\n\tcase string:\n\t\tputData = []byte(info)\n\t\tputDataLength = int64(len(putData))\n\tcase []byte:\n\t\tputData = info\n\t\tputDataLength = int64(len(putData))\n\tdefault:\n\t\treturn 0, TYPEERROR\n\t}\n\n\tb.Lock()\n\t// free buffer size smaller than data size which will be written to.\n\tif b.Free < int64(len(putData)) {\n\t\taddRate := math.Ceil(float64(putDataLength) / float64(b.Size))\n\t\tif addRate <= 1 {\n\t\t\taddRate = 2\n\t\t}\n\t\tif b.AutoIncrement == true {\n\t\t\tblackspaceLength = b.Size*int64(addRate) - b.Used - putDataLength\n\t\t} else {\n\t\t\treturn 0, BUFFERNOTENOUGH\n\t\t}\n\t} else {\n\t\tblackspaceLength = b.Free - putDataLength\n\t}\n\tb.Data = append(b.Data[:b.Used], putData...)\n\tb.Data = append(b.Data, make([]byte, blackspaceLength)...)\n\tb.Used = b.Used + putDataLength\n\tb.Free = blackspaceLength\n\tb.Size = b.Used + b.Free\n\tb.Unlock()\n\treturn putDataLength, nil\n}", "func (_e *MockTestTransportInstance_Expecter) FillBuffer(until interface{}) *MockTestTransportInstance_FillBuffer_Call {\n\treturn &MockTestTransportInstance_FillBuffer_Call{Call: _e.mock.On(\"FillBuffer\", until)}\n}", "func BufferData(target Enum, src []byte, usage Enum) {\n\tgl.BufferData(uint32(target), int(len(src)), gl.Ptr(&src[0]), uint32(usage))\n}", "func (j *JSendBuilderBuffer) Data(data interface{}) JSendBuilder {\n\treturn j.Set(FieldData, data)\n}", "func (native *OpenGL) BufferData(target uint32, size int, data interface{}, usage uint32) {\n\tdataPtr, isPtr := data.(unsafe.Pointer)\n\tif isPtr {\n\t\tgl.BufferData(target, size, dataPtr, usage)\n\t} else {\n\t\tgl.BufferData(target, size, gl.Ptr(data), usage)\n\t}\n}", "func (m *Marshaler) reset() {\n\tm.b = m.b[:0]\n}", "func (b *Buffer) updateMeta() {\n\t// First 8 bytes have the first frame offset,\n\t// next 8 bytes have the last frame offset,\n\t// next 8 bytes are the next sequence number,\n\t// next 4 bytes are the biggest data record we've seen,\n\t// next 8 bytes are the total data in the buffer.\n\toff := int(b.capacity)\n\tbinary.PutLittleEndianUint64(b.data, off, b.first)\n\tbinary.PutLittleEndianUint64(b.data, off+8, b.last)\n\tbinary.PutLittleEndianUint64(b.data, off+16, b.nextSeq)\n\tbinary.PutLittleEndianUint32(b.data, off+24, b.biggest)\n\tbinary.PutLittleEndianUint64(b.data, off+28, b.length)\n}", "func (p *Buffer) Next() (id int, full []byte, val []byte, wt WireType, err error) {\n\tstart := p.index\n\tif start == ulen(p.buf) {\n\t\t// end of buffer\n\t\treturn 0, nil, nil, 0, nil\n\t}\n\n\tvar vi uint64\n\tvi, err = p.DecodeVarint()\n\tif err != nil {\n\t\treturn 0, nil, nil, 0, err\n\t}\n\twt = WireType(vi) & 7\n\tid = int(vi >> 3)\n\n\tval_start := p.index // correct except in the case of WireBytes, where the value starts after the varint byte length\n\n\tswitch wt {\n\tcase WireBytes:\n\t\tval, err = p.DecodeRawBytes()\n\n\tcase WireVarint:\n\t\terr = p.SkipVarint()\n\n\tcase WireFixed32:\n\t\terr = p.SkipFixed(4)\n\n\tcase WireFixed64:\n\t\terr = p.SkipFixed(8)\n\n\tdefault:\n\t\terr = fmt.Errorf(\"protobuf3: unsupported wiretype %d\", int(wt))\n\t}\n\n\tif val == nil {\n\t\tval = p.buf[val_start:p.index:p.index]\n\t} // else val is already set up\n\n\treturn id, p.buf[start:p.index:p.index], val, wt, err\n}" ]
[ "0.6435121", "0.6067852", "0.59396887", "0.5931773", "0.5882379", "0.5744095", "0.56914604", "0.55147654", "0.5495607", "0.5492796", "0.54362786", "0.53932476", "0.5356813", "0.53318596", "0.5328969", "0.53223467", "0.5295687", "0.5286243", "0.52827585", "0.5270708", "0.5259329", "0.52498883", "0.52439505", "0.52425444", "0.5239899", "0.5231892", "0.52237874", "0.52169174", "0.5194738", "0.5193942", "0.51914525", "0.5159462", "0.5159152", "0.51433223", "0.5129237", "0.51256096", "0.511354", "0.5107809", "0.51074654", "0.50938374", "0.50930476", "0.50912976", "0.50892335", "0.50789195", "0.50779253", "0.50738543", "0.50714", "0.50505656", "0.504209", "0.5038214", "0.5036817", "0.50345683", "0.5033721", "0.5031803", "0.50292015", "0.50209486", "0.50131804", "0.50113595", "0.5009509", "0.5008249", "0.5007137", "0.49936685", "0.4993491", "0.49918115", "0.49883723", "0.49848178", "0.49813786", "0.49757308", "0.49753678", "0.49740675", "0.4972943", "0.49713105", "0.49686733", "0.49641982", "0.49627802", "0.49586916", "0.4956851", "0.49558914", "0.49459836", "0.4942", "0.4937197", "0.49357754", "0.49346423", "0.49323395", "0.4928221", "0.49263248", "0.4915157", "0.49149367", "0.49140847", "0.49104175", "0.4907539", "0.49063525", "0.49053437", "0.490116", "0.49001867", "0.48996055", "0.48990092", "0.48984617", "0.48958454", "0.48958045", "0.48937643" ]
0.0
-1
specify the clear value for the stencil buffer
func ClearStencil(s int32) { C.glowClearStencil(gpClearStencil, (C.GLint)(s)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func ClearStencil(s int32) {\n C.glowClearStencil(gpClearStencil, (C.GLint)(s))\n}", "func ClearStencil(s int32) {\n\tsyscall.Syscall(gpClearStencil, 1, uintptr(s), 0, 0)\n}", "func ClearStencil(s int) {\n\tgl.ClearStencil(int32(s))\n}", "func (debugging *debuggingOpenGL) Clear(mask uint32) {\n\tdebugging.recordEntry(\"Clear\", mask)\n\tdebugging.gl.Clear(mask)\n\tdebugging.recordExit(\"Clear\")\n}", "func ClearStencil(s int) {\n\tC.glClearStencil(C.GLint(s))\n}", "func (native *OpenGL) Clear(mask uint32) {\n\tgl.Clear(mask)\n}", "func ClearStencil(s Int) {\n\tcs, _ := (C.GLint)(s), cgoAllocsUnknown\n\tC.glClearStencil(cs)\n}", "func Clear(mask uint32) {\n C.glowClear(gpClear, (C.GLbitfield)(mask))\n}", "func (f *Framebuffer) ClearStencil(stencil int) gfx.FramebufferStateValue {\n\treturn s.CSV{\n\t\tValue: stencil,\n\t\tDefaultValue: 0, // TODO(slimsag): verify\n\t\tKey: csClearStencil,\n\t\tGLCall: f.ctx.glClearStencil,\n\t}\n}", "func Clear(mask GLbitfield) {\n\tC.glClear(C.GLbitfield(mask))\n}", "func Clear(mask Enum) {\n\tgl.Clear(uint32(mask))\n}", "func (f *Framebuffer) Clear(m gfx.ClearMask) {\n\tvar mask int\n\tif m&gfx.ColorBuffer != 0 {\n\t\tmask |= f.ctx.COLOR_BUFFER_BIT\n\t}\n\tif m&gfx.DepthBuffer != 0 {\n\t\tmask |= f.ctx.DEPTH_BUFFER_BIT\n\t}\n\tif m&gfx.StencilBuffer != 0 {\n\t\tmask |= f.ctx.STENCIL_BUFFER_BIT\n\t}\n\n\t// Use this framebuffer's state, and perform the clear operation.\n\tf.useState()\n\tf.ctx.O.Call(\"clear\", mask)\n}", "func Clear(mask Bitfield) {\n\tcmask, _ := (C.GLbitfield)(mask), cgoAllocsUnknown\n\tC.glClear(cmask)\n}", "func (gl *WebGL) Clear(option GLEnum) {\n\tgl.context.Call(\"clear\", option)\n}", "func Clear(mask uint32) {\n\tC.glowClear(gpClear, (C.GLbitfield)(mask))\n}", "func Clear(mask uint32) {\n\tC.glowClear(gpClear, (C.GLbitfield)(mask))\n}", "func ClearDepth(depth float64) {\n C.glowClearDepth(gpClearDepth, (C.GLdouble)(depth))\n}", "func ClearIndex(c float32) {\n C.glowClearIndex(gpClearIndex, (C.GLfloat)(c))\n}", "func (pw *PixelWand) Clear() {\n\tC.ClearPixelWand(pw.pw)\n\truntime.KeepAlive(pw)\n}", "func Clear(r, g, b, a float32) {\n\tgl.ClearColor(r, g, b, a)\n\tgl.Clear(gl.COLOR_BUFFER_BIT)\n}", "func ClearAccum(red float32, green float32, blue float32, alpha float32) {\n C.glowClearAccum(gpClearAccum, (C.GLfloat)(red), (C.GLfloat)(green), (C.GLfloat)(blue), (C.GLfloat)(alpha))\n}", "func (obj *Device) Clear(\n\trects []RECT,\n\tflags uint32,\n\tcolor COLOR,\n\tz float32,\n\tstencil uint32,\n) Error {\n\tvar rectPtr *RECT\n\tif len(rects) > 0 {\n\t\trectPtr = &rects[0]\n\t}\n\tret, _, _ := syscall.Syscall9(\n\t\tobj.vtbl.Clear,\n\t\t7,\n\t\tuintptr(unsafe.Pointer(obj)),\n\t\tuintptr(len(rects)),\n\t\tuintptr(unsafe.Pointer(rectPtr)),\n\t\tuintptr(flags),\n\t\tuintptr(color),\n\t\tuintptr(math.Float32bits(z)),\n\t\tuintptr(stencil),\n\t\t0,\n\t\t0,\n\t)\n\treturn toErr(ret)\n}", "func Clear(l Layer, c color.RGBA) {\n\tFill{Fullscreen, c}.Draw(l)\n}", "func ClearDepth(depth float64) {\n\tsyscall.Syscall(gpClearDepth, 1, uintptr(math.Float64bits(depth)), 0, 0)\n}", "func (glx *Context) Clear() {\n\tglx.constants.Clear(glx.constants.COLOR_BUFFER_BIT)\n\tglx.constants.Clear(glx.constants.DEPTH_BUFFER_BIT)\n}", "func ClearColor(red float32, green float32, blue float32, alpha float32) {\n C.glowClearColor(gpClearColor, (C.GLfloat)(red), (C.GLfloat)(green), (C.GLfloat)(blue), (C.GLfloat)(alpha))\n}", "func ClearBufferData(target uint32, internalformat uint32, format uint32, xtype uint32, data unsafe.Pointer) {\n C.glowClearBufferData(gpClearBufferData, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLenum)(format), (C.GLenum)(xtype), data)\n}", "func (c *Canvas) Clear(color color.Color) {\n\tc.gf.Dirty()\n\n\trgba := pixel.ToRGBA(color)\n\n\t// color masking\n\trgba = rgba.Mul(pixel.RGBA{\n\t\tR: float64(c.col[0]),\n\t\tG: float64(c.col[1]),\n\t\tB: float64(c.col[2]),\n\t\tA: float64(c.col[3]),\n\t})\n\n\tmainthread.CallNonBlock(func() {\n\t\tc.setGlhfBounds()\n\t\tc.gf.Frame().Begin()\n\t\tglhf.Clear(\n\t\t\tfloat32(rgba.R),\n\t\t\tfloat32(rgba.G),\n\t\t\tfloat32(rgba.B),\n\t\t\tfloat32(rgba.A),\n\t\t)\n\t\tc.gf.Frame().End()\n\t})\n}", "func ClearDepth(depth float64) {\n\tC.glowClearDepth(gpClearDepth, (C.GLdouble)(depth))\n}", "func ClearDepth(depth float64) {\n\tC.glowClearDepth(gpClearDepth, (C.GLdouble)(depth))\n}", "func (c *Canvas) Clear() error {\n\tb, err := buffer.New(c.Size())\n\tif err != nil {\n\t\treturn err\n\t}\n\tc.buffer = b\n\treturn nil\n}", "func (gl *WebGL) ClearDepth(depth float64) {\n\tgl.context.Call(\"clearDepth\", float32(depth))\n}", "func ClearIndex(c float32) {\n\tC.glowClearIndex(gpClearIndex, (C.GLfloat)(c))\n}", "func Clear(mask uint32) {\n\tsyscall.Syscall(gpClear, 1, uintptr(mask), 0, 0)\n}", "func ClearBufferData(target uint32, internalformat uint32, format uint32, xtype uint32, data unsafe.Pointer) {\n\tC.glowClearBufferData(gpClearBufferData, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLenum)(format), (C.GLenum)(xtype), data)\n}", "func ClearBufferData(target uint32, internalformat uint32, format uint32, xtype uint32, data unsafe.Pointer) {\n\tC.glowClearBufferData(gpClearBufferData, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLenum)(format), (C.GLenum)(xtype), data)\n}", "func ClearBufferSubData(target uint32, internalformat uint32, offset int, size int, format uint32, xtype uint32, data unsafe.Pointer) {\n C.glowClearBufferSubData(gpClearBufferSubData, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLintptr)(offset), (C.GLsizeiptr)(size), (C.GLenum)(format), (C.GLenum)(xtype), data)\n}", "func ClearAccum(red float32, green float32, blue float32, alpha float32) {\n\tC.glowClearAccum(gpClearAccum, (C.GLfloat)(red), (C.GLfloat)(green), (C.GLfloat)(blue), (C.GLfloat)(alpha))\n}", "func (v *Bitmap256) Clear(pos uint8) {\n\tv[pos>>6] &= ^(1 << (pos & 63))\n}", "func ClearAccum(red float32, green float32, blue float32, alpha float32) {\n\tsyscall.Syscall6(gpClearAccum, 4, uintptr(math.Float32bits(red)), uintptr(math.Float32bits(green)), uintptr(math.Float32bits(blue)), uintptr(math.Float32bits(alpha)), 0, 0)\n}", "func (r *Render) clear(cursor int) {\n\tr.move(cursor, 0)\n\tr.out.EraseDown()\n}", "func StencilMask(mask uint32) {\n C.glowStencilMask(gpStencilMask, (C.GLuint)(mask))\n}", "func ClearBufferData(target uint32, internalformat uint32, format uint32, xtype uint32, data unsafe.Pointer) {\n\tsyscall.Syscall6(gpClearBufferData, 5, uintptr(target), uintptr(internalformat), uintptr(format), uintptr(xtype), uintptr(data), 0)\n}", "func ClearDepthf(d float32) {\n\tC.glowClearDepthf(gpClearDepthf, (C.GLfloat)(d))\n}", "func ClearDepthf(d float32) {\n\tC.glowClearDepthf(gpClearDepthf, (C.GLfloat)(d))\n}", "func ClearDepthf(d float32) {\n\tsyscall.Syscall(gpClearDepthf, 1, uintptr(math.Float32bits(d)), 0, 0)\n}", "func (b *Buffer) Clear() {\n\tfor o := range b.Tiles {\n\t\tb.Tiles[o] = nil\n\t}\n}", "func (p Pin) Clear() {\n\tp.Port().bsrr.Store(uint32(Pin0) << 16 << p.index())\n}", "func (w *Window) Clear() {\n\tfor i, _ := range w.tex {\n\t\tw.tex[i] = 0\n\t}\n}", "func (s *StackF64) clear() {\n\tfor i := 0; i < len(s.data); i++ {\n\t\ts.data[i] = 0\n\t}\n}", "func ClearDepthf(d float32) {\n\tgl.ClearDepthf(d)\n}", "func StencilMask(mask Uint) {\n\tcmask, _ := (C.GLuint)(mask), cgoAllocsUnknown\n\tC.glStencilMask(cmask)\n}", "func (c *Color) Reset() {\n\tc.params = c.params[:0]\n}", "func ClearColor(red, green, blue, alpha float32) {\n\tgl.ClearColor(red, green, blue, alpha)\n}", "func (b *Builder) ClearBackbuffer(ctx context.Context) (red, green, blue, black api.CmdID) {\n\tred = b.Add(\n\t\tb.CB.GlClearColor(1.0, 0.0, 0.0, 1.0),\n\t\tb.CB.GlClear(gles.GLbitfield_GL_COLOR_BUFFER_BIT),\n\t) + 1\n\tgreen = b.Add(\n\t\tb.CB.GlClearColor(0.0, 1.0, 0.0, 1.0),\n\t\tb.CB.GlClear(gles.GLbitfield_GL_COLOR_BUFFER_BIT),\n\t) + 1\n\tblue = b.Add(\n\t\tb.CB.GlClearColor(0.0, 0.0, 1.0, 1.0),\n\t\tb.CB.GlClear(gles.GLbitfield_GL_COLOR_BUFFER_BIT),\n\t) + 1\n\tblack = b.Add(\n\t\tb.CB.GlClearColor(0.0, 0.0, 0.0, 1.0),\n\t\tb.CB.GlClear(gles.GLbitfield_GL_COLOR_BUFFER_BIT),\n\t) + 1\n\treturn red, green, blue, black\n}", "func ClearColor(red float32, green float32, blue float32, alpha float32) {\n\tsyscall.Syscall6(gpClearColor, 4, uintptr(math.Float32bits(red)), uintptr(math.Float32bits(green)), uintptr(math.Float32bits(blue)), uintptr(math.Float32bits(alpha)), 0, 0)\n}", "func StencilMask(mask uint) {\n\tC.glStencilMask(C.GLuint(mask))\n}", "func (s *UniformSample) Clear() {\n\ts.mutex.Lock()\n\tdefer s.mutex.Unlock()\n\ts.count = 0\n\ts.values = make([]int64, 0, s.reservoirSize)\n}", "func (frac *Fractal) Clear() {\n\tfrac.R = histo.New(frac.Width, frac.Height)\n\tfrac.G = histo.New(frac.Width, frac.Height)\n\tfrac.B = histo.New(frac.Width, frac.Height)\n}", "func ClearBufferSubData(target uint32, internalformat uint32, offset int, size int, format uint32, xtype uint32, data unsafe.Pointer) {\n\tC.glowClearBufferSubData(gpClearBufferSubData, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLintptr)(offset), (C.GLsizeiptr)(size), (C.GLenum)(format), (C.GLenum)(xtype), data)\n}", "func ClearBufferSubData(target uint32, internalformat uint32, offset int, size int, format uint32, xtype uint32, data unsafe.Pointer) {\n\tC.glowClearBufferSubData(gpClearBufferSubData, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLintptr)(offset), (C.GLsizeiptr)(size), (C.GLenum)(format), (C.GLenum)(xtype), data)\n}", "func (NilUGauge) Clear() uint64 { return 0 }", "func StencilMask(mask uint32) {\n\tgl.StencilMask(mask)\n}", "func ClearColor(red float32, green float32, blue float32, alpha float32) {\n\tC.glowClearColor(gpClearColor, (C.GLfloat)(red), (C.GLfloat)(green), (C.GLfloat)(blue), (C.GLfloat)(alpha))\n}", "func ClearColor(red float32, green float32, blue float32, alpha float32) {\n\tC.glowClearColor(gpClearColor, (C.GLfloat)(red), (C.GLfloat)(green), (C.GLfloat)(blue), (C.GLfloat)(alpha))\n}", "func (b *FixedBuffer) Reset() {\n\tb.w = 0\n\tb.r = 0\n}", "func (rb *RingBuffer[T]) Clear() {\n\trb.mu.Lock()\n\tdefer rb.mu.Unlock()\n\trb.pos = 0\n\trb.buf = nil\n}", "func (r *Ring) Clear() {\n\tr.size, r.in, r.out = 0, 0, 0\n}", "func (gl *WebGL) ClearColor(r, g, b, a float64) {\n\tgl.context.Call(\"clearColor\", float32(r), float32(g), float32(b), float32(a))\n}", "func (d *Driver) Clear() {\n\tfor i := 0; i < len(d.buff); i++ {\n\t\td.buff[i] = 0\n\t}\n}", "func InvalidateBufferData(buffer uint32) {\n C.glowInvalidateBufferData(gpInvalidateBufferData, (C.GLuint)(buffer))\n}", "func SetClearColor(r uint8, g uint8, b uint8) {\n\n\tgl.ClearColor(gl.Float(r)/255, gl.Float(g)/255, gl.Float(b)/255, 1.0)\n}", "func (gdt *Array) Clear() {\n\targ0 := gdt.getBase()\n\n\tC.go_godot_array_clear(GDNative.api, arg0)\n}", "func ClearIndex(c float32) {\n\tsyscall.Syscall(gpClearIndex, 1, uintptr(math.Float32bits(c)), 0, 0)\n}", "func (pb *PacketBuffer) Clear() {\n\tpb.numPackets = 0\n\tpb.offsets[0] = 0\n}", "func ClearColor(red Float, green Float, blue Float, alpha Float) {\n\tcred, _ := (C.GLfloat)(red), cgoAllocsUnknown\n\tcgreen, _ := (C.GLfloat)(green), cgoAllocsUnknown\n\tcblue, _ := (C.GLfloat)(blue), cgoAllocsUnknown\n\tcalpha, _ := (C.GLfloat)(alpha), cgoAllocsUnknown\n\tC.glClearColor(cred, cgreen, cblue, calpha)\n}", "func (spriteBatch *SpriteBatch) Clear() {\n\tspriteBatch.arrayBuf = newVertexBuffer(spriteBatch.size*4*8, []float32{}, spriteBatch.usage)\n\tspriteBatch.count = 0\n}", "func (this *channelStruct) Clear() {\n\tthis.samples = make([]float64, 0)\n}", "func (wv *Spectrum) SetZero() {\n\tfor k := 0; k < 4; k++ {\n\t\twv.C[k] = 0\n\t}\n\n}", "func (b *Buffer) ClearTo(o int) {\n\tfor o = calc.MinInt(o, len(b.Tiles)); o >= 0; o-- {\n\t\tb.Tiles[o] = nil\n\t}\n}", "func ClearColor(red GLfloat, green GLfloat, blue GLfloat, alpha GLfloat) {\n\tC.glClearColor(C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))\n}", "func (b *Buffer) Reset() {\n b.size = 0\n b.offset = 0\n}", "func ClearDepthf(d Float) {\n\tcd, _ := (C.GLfloat)(d), cgoAllocsUnknown\n\tC.glClearDepthf(cd)\n}", "func (g *gfx) ClearPixel(x, y int) {\n\tg[x][y] = COLOR_BLACK\n}", "func (self *nativePduBuffer) Clear() {\n\tself.start = 0\n\tself.count = 0\n}", "func (x *Secp256k1N) Clear() {\n\tx.limbs[0] = 0\n\tx.limbs[1] = 0\n\tx.limbs[2] = 0\n\tx.limbs[3] = 0\n\tx.limbs[4] = 0\n}", "func Clear() {\n\tfor i := 0; i < bufferLength; i++ {\n\t\tbuffer[i] = 0x00\n\t}\n}", "func (debugging *debuggingOpenGL) ClearColor(red float32, green float32, blue float32, alpha float32) {\n\tdebugging.recordEntry(\"ClearColor\", red, green, blue, alpha)\n\tdebugging.gl.ClearColor(red, green, blue, alpha)\n\tdebugging.recordExit(\"ClearColor\")\n}", "func (b *Buffer) ClearAt(o int) {\n\tif o < len(b.Tiles) {\n\t\tb.Tiles[o] = nil\n\t}\n}", "func (d *Display) Clear() {\n\td.sendCommand(0b00000001)\n\ttime.Sleep(10 * time.Millisecond) // long instruction, max 6.2ms\n}", "func (z *Int) Clear() *Int {\n\tz[3], z[2], z[1], z[0] = 0, 0, 0, 0\n\treturn z\n}", "func (b *Buffer) Clear() {\n\tb.series = make(map[string]*influxdb.Series)\n\tb.size = 0\n}", "func Clear(data []uintptr, bitIdx int) {\n\twordIdx := uint(bitIdx) / BitsPerWord\n\tdata[wordIdx] = data[wordIdx] &^ (1 << (uint(bitIdx) % BitsPerWord))\n}", "func (ld *LEDraw) Clear() {\n\tif ld.Image == nil {\n\t\tld.Init()\n\t}\n\tld.Paint.Clear(&ld.Render)\n}", "func (b FormatOption) Clear(flag FormatOption) FormatOption { return b &^ flag }", "func (display smallEpd) Clear() (err error) {\n\tlog.Debug(\"EPD42 Clear\")\n\n\tif err = display.sendCommand(DATA_START_TRANSMISSION_1); err != nil {\n\t\treturn\n\t}\n\n\t// TODO: Verify that this is enough bits\n\tfor i := 0; i < display.Width()*display.Height()/8; i++ {\n\t\tif err = display.sendData([]byte{0xFF}); err != nil {\n\t\t\treturn\n\t\t}\n\t}\n\n\tif err = display.sendCommand(DATA_START_TRANSMISSION_2); err != nil {\n\t\treturn\n\t}\n\n\tfor i := 0; i < display.Width()*display.Height()/8; i++ {\n\t\tif err = display.sendData([]byte{0xFF}); err != nil {\n\t\t\treturn\n\t\t}\n\t}\n\n\tif err = display.sendCommand(DISPLAY_REFRESH); err != nil {\n\t\treturn\n\t}\n\n\tif err = display.waitUntilIdle(); err != nil {\n\t\treturn\n\t}\n\n\tlog.Debug(\"EPD42 Clear End\")\n\treturn\n}", "func ClearBufferSubData(target uint32, internalformat uint32, offset int, size int, format uint32, xtype uint32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpClearBufferSubData, 7, uintptr(target), uintptr(internalformat), uintptr(offset), uintptr(size), uintptr(format), uintptr(xtype), uintptr(data), 0, 0)\n}", "func ClearBlueSky() Color {\n\treturn Color{R: 64, G: 156, B: 255, W: 0}\n}", "func Clear() string {\n\treturn csi(\"2J\") + csi(\"H\")\n}" ]
[ "0.73086315", "0.7286953", "0.69857603", "0.6924906", "0.69165", "0.6864337", "0.68532676", "0.68230957", "0.6695288", "0.66714644", "0.6593278", "0.65412724", "0.65304893", "0.6464722", "0.6383803", "0.6383803", "0.63575023", "0.62926835", "0.6273837", "0.6157368", "0.61367255", "0.6117947", "0.6095509", "0.6079787", "0.6072212", "0.6065046", "0.606133", "0.5953744", "0.59081054", "0.59081054", "0.5898721", "0.5895105", "0.5870025", "0.5848188", "0.58410054", "0.58410054", "0.5838703", "0.5828682", "0.5809319", "0.5774904", "0.577003", "0.57402635", "0.57040846", "0.57039976", "0.57039976", "0.5691547", "0.5680884", "0.567416", "0.5667512", "0.5656319", "0.56552696", "0.5621992", "0.5621142", "0.56163204", "0.5602671", "0.5602138", "0.5593614", "0.559158", "0.5585108", "0.55849123", "0.55849123", "0.55584455", "0.55462825", "0.55449265", "0.55449265", "0.55390894", "0.5532581", "0.5518357", "0.55175996", "0.55070513", "0.54985094", "0.54917425", "0.5473224", "0.54721135", "0.54667765", "0.54626894", "0.54590225", "0.5451396", "0.5447094", "0.5431551", "0.54302096", "0.5427293", "0.54218256", "0.5413672", "0.5398422", "0.53814644", "0.53777134", "0.5372847", "0.53518414", "0.5340729", "0.53406", "0.5337343", "0.5327472", "0.5319061", "0.53132206", "0.5313074", "0.5307801", "0.52909815", "0.5289887" ]
0.7056484
3
fills all a texture image with a constant value
func ClearTexImage(texture uint32, level int32, format uint32, xtype uint32, data unsafe.Pointer) { C.glowClearTexImage(gpClearTexImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLenum)(format), (C.GLenum)(xtype), data) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func (t *Texture) Set(x uint16, y uint16, value rgb565.Rgb565Color) {\n\tt.pixels[y*t.width+x] = value\n}", "func InvalidateTexImage(texture uint32, level int32) {\n C.glowInvalidateTexImage(gpInvalidateTexImage, (C.GLuint)(texture), (C.GLint)(level))\n}", "func (i *ImageBuf) SetFull(xbegin, xend, ybegin, yend, zbegin, zend int) {\n\tC.ImageBuf_set_full(\n\t\ti.ptr,\n\t\tC.int(xbegin), C.int(xend),\n\t\tC.int(ybegin), C.int(yend),\n\t\tC.int(zbegin), C.int(zend))\n\truntime.KeepAlive(i)\n}", "func fill(pix []byte, c color.RGBA) {\n\tfor i := 0; i < len(pix); i += 4 {\n\t\tpix[i] = c.R\n\t\tpix[i+1] = c.G\n\t\tpix[i+2] = c.B\n\t\tpix[i+3] = c.A\n\t}\n}", "func (m RGBImage) Fill(vl RGB) {\n\tl := m.Area()\n\tfor i := 0; i < l; i++ {\n\t\tm.Pixels[i] = vl\n\t}\n}", "func ClearTexImage(texture uint32, level int32, format uint32, xtype uint32, data unsafe.Pointer) {\n C.glowClearTexImage(gpClearTexImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLenum)(format), (C.GLenum)(xtype), data)\n}", "func Uniform1fv(location int32, count int32, value *float32) {\n C.glowUniform1fv(gpUniform1fv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func (self *TileSprite) SetTexture(texture *Texture) {\n self.Object.Call(\"setTexture\", texture)\n}", "func (w *Worley) GenerateTexture(tex *texture.Texture) {\n\tgl.BindImageTexture(0, tex.GetHandle(), 0, false, 0, gl.READ_WRITE, gl.RGBA32F)\n\tgl.BindImageTexture(1, w.noisetexture.GetHandle(), 0, false, 0, gl.READ_ONLY, gl.RGBA32F)\n\n\tw.computeshader.Use()\n\tw.computeshader.UpdateInt32(\"uWidth\", w.width)\n\tw.computeshader.UpdateInt32(\"uHeight\", w.height)\n\tw.computeshader.UpdateInt32(\"uResolution\", w.resolution)\n\tw.computeshader.UpdateInt32(\"uOctaves\", w.octaves)\n\tw.computeshader.UpdateFloat32(\"uRadius\", w.radius)\n\tw.computeshader.UpdateFloat32(\"uRadiusScale\", w.radiusscale)\n\tw.computeshader.UpdateFloat32(\"uBrightness\", w.brightness)\n\tw.computeshader.UpdateFloat32(\"uContrast\", w.contrast)\n\tw.computeshader.UpdateFloat32(\"uScale\", w.scale)\n\tw.computeshader.UpdateFloat32(\"uPersistance\", w.persistance)\n\tw.computeshader.Compute(uint32(w.width), uint32(w.height), 1)\n\tw.computeshader.Compute(1024, 1024, 1)\n\tw.computeshader.Release()\n\n\tgl.MemoryBarrier(gl.ALL_BARRIER_BITS)\n\n\tgl.BindImageTexture(0, 0, 0, false, 0, gl.WRITE_ONLY, gl.RGBA32F)\n\tgl.BindImageTexture(1, 0, 0, false, 0, gl.READ_ONLY, gl.RGBA32F)\n}", "func BindImageTextures(first uint32, count int32, textures *uint32) {\n C.glowBindImageTextures(gpBindImageTextures, (C.GLuint)(first), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(textures)))\n}", "func Make(width, height int, internalformat int32, format, pixelType uint32,\n\tdata unsafe.Pointer, min, mag, s, t int32) Texture {\n\n\ttexture := Texture{0, gl.TEXTURE_2D, 0}\n\n\t// generate and bind texture\n\tgl.GenTextures(1, &texture.handle)\n\ttexture.Bind(0)\n\n\t// set texture properties\n\tgl.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, min)\n\tgl.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, mag)\n\tgl.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_S, s)\n\tgl.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_T, t)\n\n\t// specify a texture image\n\tgl.TexImage2D(gl.TEXTURE_2D, 0, internalformat, int32(width), int32(height),\n\t\t0, format, pixelType, data)\n\n\t// unbind texture\n\ttexture.Unbind()\n\n\treturn texture\n}", "func (self *TileSprite) SetTintedTextureA(member *Canvas) {\n self.Object.Set(\"tintedTexture\", member)\n}", "func Uniform1iv(location int32, count int32, value *int32) {\n C.glowUniform1iv(gpUniform1iv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func (self *TileSprite) SetTexture1O(texture *Texture, destroy bool) {\n self.Object.Call(\"setTexture\", texture, destroy)\n}", "func InvalidateTexSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32) {\n C.glowInvalidateTexSubImage(gpInvalidateTexSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth))\n}", "func (level *Level) SetTextures(newIds []int) {\n\tblockStore := level.store.Get(res.ResourceID(4000 + level.id*100 + 7))\n\tvar ids [54]uint16\n\ttoCopy := len(ids)\n\n\tif len(newIds) < toCopy {\n\t\ttoCopy = len(newIds)\n\t}\n\tfor index := 0; index < len(ids); index++ {\n\t\tids[index] = uint16(newIds[index])\n\t}\n\n\tbuffer := bytes.NewBuffer(nil)\n\tbinary.Write(buffer, binary.LittleEndian, &ids)\n\tblockStore.SetBlockData(0, buffer.Bytes())\n}", "func (self *TileSprite) SetTextureA(member *Texture) {\n self.Object.Set(\"texture\", member)\n}", "func (m GrayImage) Fill(vl byte) {\n\tl := m.Area()\n\tfor i := 0; i < l; i++ {\n\t\tm.Pixels[i] = vl\n\t}\n}", "func BindImageTexture(unit uint32, texture uint32, level int32, layered bool, layer int32, access uint32, format uint32) {\n C.glowBindImageTexture(gpBindImageTexture, (C.GLuint)(unit), (C.GLuint)(texture), (C.GLint)(level), (C.GLboolean)(boolToInt(layered)), (C.GLint)(layer), (C.GLenum)(access), (C.GLenum)(format))\n}", "func (m IntGrayImage) Fill(vl int) {\n\tl := m.Area()\n\tfor i := 0; i < l; i++ {\n\t\tm.Pixels[i] = vl\n\t}\n}", "func ShaderProgramFill(r, g, b, a byte) *shaderir.Program {\n\tir, err := graphics.CompileShader([]byte(fmt.Sprintf(`//kage:unit pixels\n\npackage main\n\nfunc Fragment(position vec4, texCoord vec2, color vec4) vec4 {\n\treturn vec4(%0.9f, %0.9f, %0.9f, %0.9f)\n}\n`, float64(r)/0xff, float64(g)/0xff, float64(b)/0xff, float64(a)/0xff)))\n\tif err != nil {\n\t\tpanic(err)\n\t}\n\treturn ir\n}", "func Uniform4fv(location int32, count int32, value *float32) {\n C.glowUniform4fv(gpUniform4fv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func (self *TileSprite) SetTilingTextureA(member *PIXITexture) {\n self.Object.Set(\"tilingTexture\", member)\n}", "func BindTextures(first uint32, count int32, textures *uint32) {\n C.glowBindTextures(gpBindTextures, (C.GLuint)(first), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(textures)))\n}", "func ClearTexImage(texture uint32, level int32, format uint32, xtype uint32, data unsafe.Pointer) {\n\tsyscall.Syscall6(gpClearTexImage, 5, uintptr(texture), uintptr(level), uintptr(format), uintptr(xtype), uintptr(data), 0)\n}", "func Uniform4iv(location int32, count int32, value *int32) {\n C.glowUniform4iv(gpUniform4iv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func TexImage1D(target uint32, level int32, internalformat int32, width int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexImage1D(gpTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func New(width uint16, height uint16) *Texture {\n\tt := &Texture{\n\t\twidth: width,\n\t\theight: height,\n\t\tpixels: make([]rgb565.Rgb565Color, width*height),\n\t}\n\n\tfor i := range t.pixels {\n\t\tt.pixels[i] = rgb565.New(0x00, 0x00, 0x00)\n\t}\n\n\treturn t\n}", "func TexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexSubImage1D(gpTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func LoadTextures(eng sprite.Engine) map[string]sprite.SubTex {\n\tallTexs := make(map[string]sprite.SubTex)\n\tboundedImgs := []string{\"Clubs-2.png\", \"Clubs-3.png\", \"Clubs-4.png\", \"Clubs-5.png\", \"Clubs-6.png\", \"Clubs-7.png\", \"Clubs-8.png\",\n\t\t\"Clubs-9.png\", \"Clubs-10.png\", \"Clubs-Jack.png\", \"Clubs-Queen.png\", \"Clubs-King.png\", \"Clubs-Ace.png\",\n\t\t\"Diamonds-2.png\", \"Diamonds-3.png\", \"Diamonds-4.png\", \"Diamonds-5.png\", \"Diamonds-6.png\", \"Diamonds-7.png\", \"Diamonds-8.png\",\n\t\t\"Diamonds-9.png\", \"Diamonds-10.png\", \"Diamonds-Jack.png\", \"Diamonds-Queen.png\", \"Diamonds-King.png\", \"Diamonds-Ace.png\",\n\t\t\"Spades-2.png\", \"Spades-3.png\", \"Spades-4.png\", \"Spades-5.png\", \"Spades-6.png\", \"Spades-7.png\", \"Spades-8.png\",\n\t\t\"Spades-9.png\", \"Spades-10.png\", \"Spades-Jack.png\", \"Spades-Queen.png\", \"Spades-King.png\", \"Spades-Ace.png\",\n\t\t\"Hearts-2.png\", \"Hearts-3.png\", \"Hearts-4.png\", \"Hearts-5.png\", \"Hearts-6.png\", \"Hearts-7.png\", \"Hearts-8.png\",\n\t\t\"Hearts-9.png\", \"Hearts-10.png\", \"Hearts-Jack.png\", \"Hearts-Queen.png\", \"Hearts-King.png\", \"Hearts-Ace.png\", \"BakuSquare.png\",\n\t}\n\tunboundedImgs := []string{\"Club.png\", \"Diamond.png\", \"Spade.png\", \"Heart.png\", \"gray.jpeg\", \"blue.png\", \"trickDrop.png\",\n\t\t\"trickDropBlue.png\", \"player0.jpeg\", \"player1.jpeg\", \"player2.jpeg\", \"player3.jpeg\", \"laptopIcon.png\", \"watchIcon.png\",\n\t\t\"phoneIcon.png\", \"tabletIcon.png\", \"A-Upper.png\", \"B-Upper.png\", \"C-Upper.png\", \"D-Upper.png\", \"E-Upper.png\", \"F-Upper.png\",\n\t\t\"G-Upper.png\", \"H-Upper.png\", \"I-Upper.png\", \"J-Upper.png\", \"K-Upper.png\", \"L-Upper.png\", \"M-Upper.png\", \"N-Upper.png\",\n\t\t\"O-Upper.png\", \"P-Upper.png\", \"Q-Upper.png\", \"R-Upper.png\", \"S-Upper.png\", \"T-Upper.png\", \"U-Upper.png\", \"V-Upper.png\",\n\t\t\"W-Upper.png\", \"X-Upper.png\", \"Y-Upper.png\", \"Z-Upper.png\", \"A-Lower.png\", \"B-Lower.png\", \"C-Lower.png\", \"D-Lower.png\",\n\t\t\"E-Lower.png\", \"F-Lower.png\", \"G-Lower.png\", \"H-Lower.png\", \"I-Lower.png\", \"J-Lower.png\", \"K-Lower.png\", \"L-Lower.png\",\n\t\t\"M-Lower.png\", \"N-Lower.png\", \"O-Lower.png\", \"P-Lower.png\", \"Q-Lower.png\", \"R-Lower.png\", \"S-Lower.png\", \"T-Lower.png\",\n\t\t\"U-Lower.png\", \"V-Lower.png\", \"W-Lower.png\", \"X-Lower.png\", \"Y-Lower.png\", \"Z-Lower.png\", \"Space.png\", \"Colon.png\", \"Bang.png\",\n\t\t\"Apostrophe.png\", \"1.png\", \"2.png\", \"3.png\", \"4.png\", \"5.png\", \"6.png\", \"7.png\", \"8.png\", \"9.png\", \"0.png\", \"1-Red.png\",\n\t\t\"2-Red.png\", \"3-Red.png\", \"4-Red.png\", \"5-Red.png\", \"6-Red.png\", \"7-Red.png\", \"8-Red.png\", \"9-Red.png\", \"0-Red.png\",\n\t\t\"1-DBlue.png\", \"2-DBlue.png\", \"3-DBlue.png\", \"4-DBlue.png\", \"5-DBlue.png\", \"6-DBlue.png\", \"7-DBlue.png\", \"8-DBlue.png\",\n\t\t\"9-DBlue.png\", \"0-DBlue.png\", \"A-Upper-DBlue.png\", \"B-Upper-DBlue.png\",\n\t\t\"C-Upper-DBlue.png\", \"D-Upper-DBlue.png\", \"E-Upper-DBlue.png\", \"F-Upper-DBlue.png\", \"G-Upper-DBlue.png\", \"H-Upper-DBlue.png\",\n\t\t\"I-Upper-DBlue.png\", \"J-Upper-DBlue.png\", \"K-Upper-DBlue.png\", \"L-Upper-DBlue.png\", \"M-Upper-DBlue.png\", \"N-Upper-DBlue.png\",\n\t\t\"O-Upper-DBlue.png\", \"P-Upper-DBlue.png\", \"Q-Upper-DBlue.png\", \"R-Upper-DBlue.png\", \"S-Upper-DBlue.png\", \"T-Upper-DBlue.png\",\n\t\t\"U-Upper-DBlue.png\", \"V-Upper-DBlue.png\", \"W-Upper-DBlue.png\", \"X-Upper-DBlue.png\", \"Y-Upper-DBlue.png\", \"Z-Upper-DBlue.png\",\n\t\t\"A-Lower-DBlue.png\", \"B-Lower-DBlue.png\", \"C-Lower-DBlue.png\", \"D-Lower-DBlue.png\", \"E-Lower-DBlue.png\", \"F-Lower-DBlue.png\",\n\t\t\"G-Lower-DBlue.png\", \"H-Lower-DBlue.png\", \"I-Lower-DBlue.png\", \"J-Lower-DBlue.png\", \"K-Lower-DBlue.png\", \"L-Lower-DBlue.png\",\n\t\t\"M-Lower-DBlue.png\", \"N-Lower-DBlue.png\", \"O-Lower-DBlue.png\", \"P-Lower-DBlue.png\", \"Q-Lower-DBlue.png\", \"R-Lower-DBlue.png\",\n\t\t\"S-Lower-DBlue.png\", \"T-Lower-DBlue.png\", \"U-Lower-DBlue.png\", \"V-Lower-DBlue.png\", \"W-Lower-DBlue.png\", \"X-Lower-DBlue.png\",\n\t\t\"Y-Lower-DBlue.png\", \"Z-Lower-DBlue.png\", \"Apostrophe-DBlue.png\", \"Space-DBlue.png\", \"A-Upper-LBlue.png\", \"B-Upper-LBlue.png\",\n\t\t\"C-Upper-LBlue.png\", \"D-Upper-LBlue.png\", \"E-Upper-LBlue.png\", \"F-Upper-LBlue.png\", \"G-Upper-LBlue.png\", \"H-Upper-LBlue.png\",\n\t\t\"I-Upper-LBlue.png\", \"J-Upper-LBlue.png\", \"K-Upper-LBlue.png\", \"L-Upper-LBlue.png\", \"M-Upper-LBlue.png\", \"N-Upper-LBlue.png\",\n\t\t\"O-Upper-LBlue.png\", \"P-Upper-LBlue.png\", \"Q-Upper-LBlue.png\", \"R-Upper-LBlue.png\", \"S-Upper-LBlue.png\", \"T-Upper-LBlue.png\",\n\t\t\"U-Upper-LBlue.png\", \"V-Upper-LBlue.png\", \"W-Upper-LBlue.png\", \"X-Upper-LBlue.png\", \"Y-Upper-LBlue.png\", \"Z-Upper-LBlue.png\",\n\t\t\"A-Lower-LBlue.png\", \"B-Lower-LBlue.png\", \"C-Lower-LBlue.png\", \"D-Lower-LBlue.png\", \"E-Lower-LBlue.png\", \"F-Lower-LBlue.png\",\n\t\t\"G-Lower-LBlue.png\", \"H-Lower-LBlue.png\", \"I-Lower-LBlue.png\", \"J-Lower-LBlue.png\", \"K-Lower-LBlue.png\", \"L-Lower-LBlue.png\",\n\t\t\"M-Lower-LBlue.png\", \"N-Lower-LBlue.png\", \"O-Lower-LBlue.png\", \"P-Lower-LBlue.png\", \"Q-Lower-LBlue.png\", \"R-Lower-LBlue.png\",\n\t\t\"S-Lower-LBlue.png\", \"T-Lower-LBlue.png\", \"U-Lower-LBlue.png\", \"V-Lower-LBlue.png\", \"W-Lower-LBlue.png\", \"X-Lower-LBlue.png\",\n\t\t\"Y-Lower-LBlue.png\", \"Z-Lower-LBlue.png\", \"A-Upper-Gray.png\", \"B-Upper-Gray.png\", \"C-Upper-Gray.png\", \"D-Upper-Gray.png\",\n\t\t\"E-Upper-Gray.png\", \"F-Upper-Gray.png\", \"G-Upper-Gray.png\", \"H-Upper-Gray.png\", \"I-Upper-Gray.png\", \"J-Upper-Gray.png\",\n\t\t\"K-Upper-Gray.png\", \"L-Upper-Gray.png\", \"M-Upper-Gray.png\", \"N-Upper-Gray.png\", \"O-Upper-Gray.png\", \"P-Upper-Gray.png\",\n\t\t\"Q-Upper-Gray.png\", \"R-Upper-Gray.png\", \"S-Upper-Gray.png\", \"T-Upper-Gray.png\", \"U-Upper-Gray.png\", \"V-Upper-Gray.png\",\n\t\t\"W-Upper-Gray.png\", \"X-Upper-Gray.png\", \"Y-Upper-Gray.png\", \"Z-Upper-Gray.png\", \"A-Lower-Gray.png\", \"B-Lower-Gray.png\",\n\t\t\"C-Lower-Gray.png\", \"D-Lower-Gray.png\", \"E-Lower-Gray.png\", \"F-Lower-Gray.png\", \"G-Lower-Gray.png\", \"H-Lower-Gray.png\",\n\t\t\"I-Lower-Gray.png\", \"J-Lower-Gray.png\", \"K-Lower-Gray.png\", \"L-Lower-Gray.png\", \"M-Lower-Gray.png\", \"N-Lower-Gray.png\",\n\t\t\"O-Lower-Gray.png\", \"P-Lower-Gray.png\", \"Q-Lower-Gray.png\", \"R-Lower-Gray.png\", \"S-Lower-Gray.png\", \"T-Lower-Gray.png\",\n\t\t\"U-Lower-Gray.png\", \"V-Lower-Gray.png\", \"W-Lower-Gray.png\", \"X-Lower-Gray.png\", \"Y-Lower-Gray.png\", \"Z-Lower-Gray.png\",\n\t\t\"Space-Gray.png\", \"RoundedRectangle-DBlue.png\", \"RoundedRectangle-LBlue.png\", \"RoundedRectangle-Gray.png\", \"Rectangle-LBlue.png\",\n\t\t\"Rectangle-DBlue.png\", \"HorizontalPullTab.png\", \"VerticalPullTab.png\", \"NewGamePressed.png\", \"NewGameUnpressed.png\",\n\t\t\"NewRoundPressed.png\", \"NewRoundUnpressed.png\", \"JoinGamePressed.png\", \"JoinGameUnpressed.png\", \"Period.png\",\n\t\t\"SitSpotPressed.png\", \"SitSpotUnpressed.png\", \"WatchSpotPressed.png\", \"WatchSpotUnpressed.png\", \"StartBlue.png\", \"StartGray.png\",\n\t\t\"StartBluePressed.png\", \"Restart.png\", \"Visibility.png\", \"VisibilityOff.png\", \"QuitPressed.png\", \"QuitUnpressed.png\",\n\t\t\"PassPressed.png\", \"PassUnpressed.png\", \"RightArrowBlue.png\", \"LeftArrowBlue.png\", \"AcrossArrowBlue.png\", \"RightArrowGray.png\",\n\t\t\"LeftArrowGray.png\", \"AcrossArrowGray.png\", \"TakeTrickTableUnpressed.png\", \"TakeTrickTablePressed.png\", \"TakeTrickHandPressed.png\",\n\t\t\"TakeTrickHandUnpressed.png\", \"android.png\", \"cat.png\", \"man.png\", \"woman.png\", \"TakeUnpressed.png\", \"TakePressed.png\",\n\t\t\"UnplayedBorder1.png\", \"UnplayedBorder2.png\", \"RejoinPressed.png\", \"RejoinUnpressed.png\",\n\t}\n\tfor _, f := range boundedImgs {\n\t\ta, err := asset.Open(f)\n\t\tif err != nil {\n\t\t\tlog.Fatal(err)\n\t\t}\n\n\t\timg, _, err := image.Decode(a)\n\t\tif err != nil {\n\t\t\tlog.Fatal(err)\n\t\t}\n\t\tt, err := eng.LoadTexture(img)\n\t\tif err != nil {\n\t\t\tlog.Fatal(err)\n\t\t}\n\t\timgWidth, imgHeight := t.Bounds()\n\t\tallTexs[f] = sprite.SubTex{t, image.Rect(0, 0, imgWidth, imgHeight)}\n\t\ta.Close()\n\t}\n\tfor _, f := range unboundedImgs {\n\t\ta, err := asset.Open(f)\n\t\tif err != nil {\n\t\t\tlog.Fatal(err)\n\t\t}\n\n\t\timg, _, err := image.Decode(a)\n\t\tif err != nil {\n\t\t\tlog.Fatal(err)\n\t\t}\n\t\tt, err := eng.LoadTexture(img)\n\t\tif err != nil {\n\t\t\tlog.Fatal(err)\n\t\t}\n\t\timgWidth, imgHeight := t.Bounds()\n\t\tallTexs[f] = sprite.SubTex{t, image.Rect(1, 1, imgWidth-1, imgHeight-1)}\n\t\ta.Close()\n\t}\n\treturn allTexs\n}", "func (b *XMobileBackend) PutImageData(img *image.RGBA, x, y int) {\n\tb.activate()\n\n\tb.glctx.ActiveTexture(gl.TEXTURE0)\n\tif b.imageBufTex.Value == 0 {\n\t\tb.imageBufTex = b.glctx.CreateTexture()\n\t\tb.glctx.BindTexture(gl.TEXTURE_2D, b.imageBufTex)\n\t\tb.glctx.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.LINEAR)\n\t\tb.glctx.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, gl.LINEAR)\n\t\tb.glctx.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_S, gl.CLAMP_TO_EDGE)\n\t\tb.glctx.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_T, gl.CLAMP_TO_EDGE)\n\t} else {\n\t\tb.glctx.BindTexture(gl.TEXTURE_2D, b.imageBufTex)\n\t}\n\n\tw, h := img.Bounds().Dx(), img.Bounds().Dy()\n\n\tif img.Stride == img.Bounds().Dx()*4 {\n\t\tb.glctx.TexImage2D(gl.TEXTURE_2D, 0, gl.RGBA, w, h, gl.RGBA, gl.UNSIGNED_BYTE, img.Pix[0:])\n\t} else {\n\t\tdata := make([]uint8, 0, w*h*4)\n\t\tfor cy := 0; cy < h; cy++ {\n\t\t\tstart := cy * img.Stride\n\t\t\tend := start + w*4\n\t\t\tdata = append(data, img.Pix[start:end]...)\n\t\t}\n\t\tb.glctx.TexImage2D(gl.TEXTURE_2D, 0, gl.RGBA, w, h, gl.RGBA, gl.UNSIGNED_BYTE, data[0:])\n\t}\n\n\tdx, dy := float32(x), float32(y)\n\tdw, dh := float32(w), float32(h)\n\n\tb.glctx.BindBuffer(gl.ARRAY_BUFFER, b.buf)\n\tdata := [16]float32{dx, dy, dx + dw, dy, dx + dw, dy + dh, dx, dy + dh,\n\t\t0, 0, 1, 0, 1, 1, 0, 1}\n\tb.glctx.BufferData(gl.ARRAY_BUFFER, byteSlice(unsafe.Pointer(&data[0]), len(data)*4), gl.STREAM_DRAW)\n\n\tb.glctx.UseProgram(b.shd.ID)\n\tb.glctx.Uniform1i(b.shd.Image, 0)\n\tb.glctx.Uniform2f(b.shd.CanvasSize, float32(b.fw), float32(b.fh))\n\tb.glctx.UniformMatrix3fv(b.shd.Matrix, mat3identity[:])\n\tb.glctx.Uniform1f(b.shd.GlobalAlpha, 1)\n\tb.glctx.Uniform1i(b.shd.UseAlphaTex, 0)\n\tb.glctx.Uniform1i(b.shd.Func, shdFuncImage)\n\tb.glctx.VertexAttribPointer(b.shd.Vertex, 2, gl.FLOAT, false, 0, 0)\n\tb.glctx.VertexAttribPointer(b.shd.TexCoord, 2, gl.FLOAT, false, 0, 8*4)\n\tb.glctx.EnableVertexAttribArray(b.shd.Vertex)\n\tb.glctx.EnableVertexAttribArray(b.shd.TexCoord)\n\tb.glctx.DrawArrays(gl.TRIANGLE_FAN, 0, 4)\n\tb.glctx.DisableVertexAttribArray(b.shd.Vertex)\n\tb.glctx.DisableVertexAttribArray(b.shd.TexCoord)\n}", "func InvalidateTexImage(texture uint32, level int32) {\n\tsyscall.Syscall(gpInvalidateTexImage, 2, uintptr(texture), uintptr(level), 0)\n}", "func Uniform2fv(location int32, count int32, value *float32) {\n C.glowUniform2fv(gpUniform2fv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func (self *TileSprite) SetRefreshTextureA(member bool) {\n self.Object.Set(\"refreshTexture\", member)\n}", "func loadTextures() {\n\tfor i := 0; i < 7; i++ {\n\n\t\ttextures[i], _, _ = ebutil.NewImageFromFile(\"assets/image/\"+colors[i]+\".png\", eb.FilterDefault)\n\t}\n\ttextures[7], _, _ = ebutil.NewImageFromFile(\"assets/image/tetris_backgraund.png\", eb.FilterDefault)\n}", "func CopyTexImage1D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, border int32) {\n C.glowCopyTexImage1D(gpCopyTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLint)(border))\n}", "func (self *TileSprite) SetTextureI(args ...interface{}) {\n self.Object.Call(\"setTexture\", args)\n}", "func loadImage(pattern int, data []uint8) {\n\tfor i := 0; i < rows; i++ {\n\t\tfor j := 0; j < cols; j++ {\n\t\t\tdata[(4*(i*cols+j))+0] = 0xff\n\t\t\tdata[(4*(i*cols+j))+1] = 0x00\n\t\t\tdata[(4*(i*cols+j))+2] = 0x00\n\t\t\tdata[(4*(i*cols+j))+3] = 0xff\n\t\t}\n\t}\n\tif pattern == 1 {\n\t\tvar border = cols / 4\n\t\tfor i := border; i < rows-border; i++ {\n\t\t\tfor j := border; j < cols-border; j++ {\n\t\t\t\tvalue := rand.Float64()\n\t\t\t\tif value > 0.7 {\n\t\t\t\t\tdata[(4*(i*cols+j))+2] = uint8(math.Round(255.0 * value))\n\t\t\t\t} else {\n\t\t\t\t\tdata[(4*(i*cols+j))+2] = 0xff\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t} else {\n\t\tvar checker = 40\n\t\tfor i := 0; i < rows; i++ {\n\t\t\tfor j := 0; j < cols; j++ {\n\t\t\t\tif (((i/checker)%2) == 0 && ((j/checker)%2) == 0) ||\n\t\t\t\t\t(((i/checker)%2) == 1 && ((j/checker)%2) == 1) {\n\t\t\t\t\tvalue := rand.Float64()\n\t\t\t\t\tdata[(4*(i*cols+j))+2] = uint8(math.Round(255.0 * value))\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n}", "func Uniform3fv(location int32, count int32, value *float32) {\n C.glowUniform3fv(gpUniform3fv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexImage2D(gpTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func ClearTexSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, data unsafe.Pointer) {\n C.glowClearTexSubImage(gpClearTexSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), data)\n}", "func CopyTexSubImage1D(target uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n C.glowCopyTexSubImage1D(gpCopyTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func CopyTexImage2D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, height int32, border int32) {\n C.glowCopyTexImage2D(gpCopyTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border))\n}", "func Uniform1uiv(location int32, count int32, value *uint32) {\n C.glowUniform1uiv(gpUniform1uiv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func (self *Graphics) GenerateTexture1O(resolution int) *Texture{\n return &Texture{self.Object.Call(\"generateTexture\", resolution)}\n}", "func MakeEmpty() Texture {\n\treturn Texture{0, gl.TEXTURE_2D, 0}\n}", "func Uniform2iv(location int32, count int32, value *int32) {\n C.glowUniform2iv(gpUniform2iv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func (t *Texture2D) Generate(width, height int32, data []byte) {\n\tt.width = width\n\tt.height = height\n\t// Create Texture\n\tgl.BindTexture(gl.TEXTURE_2D, t.ID)\n\tif data != nil {\n\t\tgl.TexImage2D(gl.TEXTURE_2D, 0, t.internalFormat, width, height, 0, t.imageFormat, gl.UNSIGNED_BYTE, gl.Ptr(&data[0]))\n\t} else {\n\t\tgl.TexImage2D(gl.TEXTURE_2D, 0, t.internalFormat, width, height, 0, t.imageFormat, gl.UNSIGNED_BYTE, nil)\n\t}\n\t// Set Texture wrap and filter modes\n\tgl.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_S, t.wrapS)\n\tgl.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_T, t.wrapT)\n\tgl.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, t.filterMin)\n\tgl.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, t.filterMax)\n\t// Unbind texture\n\tgl.BindTexture(gl.TEXTURE_2D, 0)\n}", "func FramebufferTexture(target uint32, attachment uint32, texture uint32, level int32) {\n C.glowFramebufferTexture(gpFramebufferTexture, (C.GLenum)(target), (C.GLenum)(attachment), (C.GLuint)(texture), (C.GLint)(level))\n}", "func Uniform3iv(location int32, count int32, value *int32) {\n C.glowUniform3iv(gpUniform3iv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexSubImage3D(gpTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func fill(b *Board, t TileColor) {\n\tfor y := 0; y < BOARD_HEIGHT; y++ {\n\t\tfor x := 0; x < BOARD_WIDTH; x++ {\n\t\t\tb.SetTile(t, x, y)\n\t\t}\n\t}\n}", "func Uniform4uiv(location int32, count int32, value *uint32) {\n C.glowUniform4uiv(gpUniform4uiv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func Uniform1f(location int32, v0 float32) {\n C.glowUniform1f(gpUniform1f, (C.GLint)(location), (C.GLfloat)(v0))\n}", "func Uniform4f(location int32, v0 float32, v1 float32, v2 float32, v3 float32) {\n C.glowUniform4f(gpUniform4f, (C.GLint)(location), (C.GLfloat)(v0), (C.GLfloat)(v1), (C.GLfloat)(v2), (C.GLfloat)(v3))\n}", "func InvalidateTexImage(texture uint32, level int32) {\n\tC.glowInvalidateTexImage(gpInvalidateTexImage, (C.GLuint)(texture), (C.GLint)(level))\n}", "func InvalidateTexImage(texture uint32, level int32) {\n\tC.glowInvalidateTexImage(gpInvalidateTexImage, (C.GLuint)(texture), (C.GLint)(level))\n}", "func (cache *FrameCache) SetTexture(key FrameCacheKey, width, height uint16, pixels []byte, palette *bitmap.Palette) {\n\tcache.DropTextureForKey(key)\n\ttex := NewBitmapTexture(cache.gl, int(width), int(height), pixels)\n\tcache.textures[key] = tex\n\tif palette == nil {\n\t\treturn\n\t}\n\tpal := NewPaletteTexture(cache.gl, palette)\n\tcache.palettes[key] = pal\n}", "func Uniform4i(location int32, v0 int32, v1 int32, v2 int32, v3 int32) {\n C.glowUniform4i(gpUniform4i, (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2), (C.GLint)(v3))\n}", "func TexImage3D(target uint32, level int32, internalformat int32, width int32, height int32, depth int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexImage3D(gpTexImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func (self *GameObjectCreator) RenderTexture1O(width int) *RenderTexture{\n return &RenderTexture{self.Object.Call(\"renderTexture\", width)}\n}", "func (self *GameObjectCreator) RenderTexture4O(width int, height int, key string, addToCache bool) *RenderTexture{\n return &RenderTexture{self.Object.Call(\"renderTexture\", width, height, key, addToCache)}\n}", "func Fill(imageBytes []byte, width, height int, maxBytes int, anchor imaging.Anchor) ([]byte, string, error) {\n\treturn process(imageBytes, maxBytes, func(image image.Image) image.Image {\n\t\treturn imaging.Fill(image, width, height, anchor, imaging.MitchellNetravali)\n\t})\n}", "func (self *TileSprite) LoadTexture1O(key interface{}, frame interface{}) {\n self.Object.Call(\"loadTexture\", key, frame)\n}", "func TexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexSubImage2D(gpTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexImage1D(target uint32, level int32, internalformat int32, width int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexImage1D(gpTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexImage1D(target uint32, level int32, internalformat int32, width int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexImage1D(gpTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func (self *TileSprite) LoadTexture(key interface{}) {\n self.Object.Call(\"loadTexture\", key)\n}", "func drawBackground(image *image.RGBA, mem *GBMem) *image.RGBA {\n\tfor x := 0; x < MapWidth; x++ {\n\t\tfor y := 0; y < MapHeight; y++ {\n\t\t\t// get tile index\n\t\t\ttileIndex := mem.read(uint16(VRAMBackgroundMap + x + (y * MapHeight)))\n\n\t\t\t// get pixels corresponding to tile index\n\t\t\tpixels := tileToPixel(tileIndex, mem)\n\n\t\t\t// draw pixels\n\t\t\tdrawTilePixels(image, pixels, x, y)\n\t\t}\n\t}\n\treturn image\n}", "func draw(window *glfw.Window, reactProg, landProg uint32) {\n\n\tvar renderLoops = 4\n\tfor i := 0; i < renderLoops; i++ {\n\t\t// -- DRAW TO BUFFER --\n\t\t// define destination of pixels\n\t\t//gl.BindFramebuffer(gl.FRAMEBUFFER, 0)\n\t\tgl.BindFramebuffer(gl.FRAMEBUFFER, FBO[1])\n\n\t\tgl.Viewport(0, 0, width, height) // Retina display doubles the framebuffer !?!\n\n\t\tgl.Clear(gl.COLOR_BUFFER_BIT | gl.DEPTH_BUFFER_BIT)\n\t\tgl.UseProgram(reactProg)\n\n\t\t// bind Texture\n\t\tgl.ActiveTexture(gl.TEXTURE0)\n\t\tgl.BindTexture(gl.TEXTURE_2D, renderedTexture)\n\t\tgl.Uniform1i(uniTex, 0)\n\n\t\tgl.BindVertexArray(VAO)\n\t\tgl.DrawElements(gl.TRIANGLE_STRIP, int32(len(indices)), gl.UNSIGNED_INT, nil)\n\n\t\tgl.BindVertexArray(0)\n\n\t\t// -- copy back textures --\n\t\tgl.BindFramebuffer(gl.READ_FRAMEBUFFER, FBO[1]) // source is high res array\n\t\tgl.ReadBuffer(gl.COLOR_ATTACHMENT0)\n\t\tgl.BindFramebuffer(gl.DRAW_FRAMEBUFFER, FBO[0]) // destination is cells array\n\t\tgl.DrawBuffer(gl.COLOR_ATTACHMENT0)\n\t\tgl.BlitFramebuffer(0, 0, width, height,\n\t\t\t0, 0, cols, rows,\n\t\t\tgl.COLOR_BUFFER_BIT, gl.NEAREST) // downsample\n\t\tgl.BindFramebuffer(gl.READ_FRAMEBUFFER, FBO[0]) // source is low res array - put in texture\n\t\t// read pixels saves data read as unsigned bytes and then loads them in TexImage same way\n\t\tgl.ReadPixels(0, 0, cols, rows, gl.RGBA, gl.FLOAT, gl.Ptr(fData))\n\t\tgl.BindTexture(gl.TEXTURE_2D, renderedTexture)\n\t\tgl.TexImage2D(gl.TEXTURE_2D, 0, gl.RGBA, cols, rows, 0, gl.RGBA, gl.FLOAT, gl.Ptr(fData))\n\t\tCheckGLErrors()\n\t}\n\t// -- DRAW TO SCREEN --\n\tvar model glm.Mat4\n\n\t// destination 0 means screen\n\tgl.BindFramebuffer(gl.FRAMEBUFFER, 0)\n\tgl.Viewport(0, 0, width*2, height*2) // Retina display doubles the framebuffer !?!\n\tgl.Clear(gl.COLOR_BUFFER_BIT | gl.DEPTH_BUFFER_BIT)\n\tgl.UseProgram(landProg)\n\t// bind Texture\n\tgl.ActiveTexture(gl.TEXTURE0)\n\tgl.BindTexture(gl.TEXTURE_2D, drawTexture)\n\n\tvar view glm.Mat4\n\tvar brakeFactor = float64(20000.0)\n\tvar xCoord, yCoord float32\n\txCoord = float32(-3.0 * math.Sin(float64(myClock)))\n\tyCoord = float32(-3.0 * math.Cos(float64(myClock)))\n\t//xCoord = 0.0\n\t//yCoord = float32(-2.5)\n\tmyClock = math.Mod((myClock + float64(deltaTime)/brakeFactor), (math.Pi * 2))\n\tview = glm.LookAt(xCoord, yCoord, 2.0, 0.0, 0.0, 0.0, 0.0, 0.0, 1.0)\n\tgl.UniformMatrix4fv(uniView, 1, false, &view[0])\n\tmodel = glm.HomogRotate3DX(glm.DegToRad(00.0))\n\tgl.UniformMatrix4fv(uniModel, 1, false, &model[0])\n\tgl.Uniform1i(uniTex2, 0)\n\n\t// render container\n\t//gl.PolygonMode(gl.FRONT_AND_BACK, gl.FILL)\n\t//gl.PolygonMode(gl.FRONT_AND_BACK, gl.LINE)\n\n\tgl.BindVertexArray(VAO)\n\tgl.DrawElements(gl.TRIANGLE_STRIP, int32(len(indices)), gl.UNSIGNED_INT, nil)\n\tgl.BindVertexArray(0)\n\n\tCheckGLErrors()\n\n\tglfw.PollEvents()\n\twindow.SwapBuffers()\n\n\t//time.Sleep(100 * 1000 * 1000)\n}", "func (tex Texture) Sub(ctx gl.Context, lvl int, width int, height int, data []byte) {\n\tctx.TexSubImage2D(gl.TEXTURE_2D, lvl, 0, 0, width, height, gl.RGBA, gl.UNSIGNED_BYTE, data)\n\tif lvl > 0 {\n\t\tctx.GenerateMipmap(gl.TEXTURE_2D)\n\t}\n}", "func Image(m *image.RGBA, key string, colors []color.RGBA) {\n\tsize := m.Bounds().Size()\n\tsquares := 6\n\tquad := size.X / squares\n\tmiddle := math.Ceil(float64(squares) / float64(2))\n\tcolorMap := make(map[int]color.RGBA)\n\tvar currentYQuadrand = 0\n\tfor y := 0; y < size.Y; y++ {\n\t\tyQuadrant := y / quad\n\t\tif yQuadrant != currentYQuadrand {\n\t\t\t// when y quadrant changes, clear map\n\t\t\tcolorMap = make(map[int]color.RGBA)\n\t\t\tcurrentYQuadrand = yQuadrant\n\t\t}\n\t\tfor x := 0; x < size.X; x++ {\n\t\t\txQuadrant := x / quad\n\t\t\tif _, ok := colorMap[xQuadrant]; !ok {\n\t\t\t\tif float64(xQuadrant) < middle {\n\t\t\t\t\tcolorMap[xQuadrant] = draw.PickColor(key, colors, xQuadrant+3*yQuadrant)\n\t\t\t\t} else if xQuadrant < squares {\n\t\t\t\t\tcolorMap[xQuadrant] = colorMap[squares-xQuadrant-1]\n\t\t\t\t} else {\n\t\t\t\t\tcolorMap[xQuadrant] = colorMap[0]\n\t\t\t\t}\n\t\t\t}\n\t\t\tm.Set(x, y, colorMap[xQuadrant])\n\t\t}\n\t}\n}", "func init() {\r\n\tfor y := 0; y < Height; y++ {\r\n\t\tfor x := 0; x < Width; x++ {\r\n\t\t\tfx, fy := float64(x), float64(y)\r\n\t\t\ti := y*Width + x\r\n\t\t\tvalue := math.Sin(fx / 16.0)\r\n\t\t\tvalue += math.Sin(fy / 8.0)\r\n\t\t\tvalue += math.Sin((fx + fy) / 16.0)\r\n\t\t\tvalue += math.Sin(math.Sqrt(fx*fx+fy*fy) / 8.0)\r\n\t\t\tvalue += 4 // shift range from -4 .. 4 to 0 .. 8\r\n\t\t\tvalue /= 8 // bring range down to 0 .. 1\r\n\t\t\tplasma[i] = value\r\n\t\t}\r\n\t}\r\n}", "func ActiveTexture(texture uint32) {\n C.glowActiveTexture(gpActiveTexture, (C.GLenum)(texture))\n}", "func Uniform1i(location int32, v0 int32) {\n C.glowUniform1i(gpUniform1i, (C.GLint)(location), (C.GLint)(v0))\n}", "func UniformMatrix4x2fv(location int32, count int32, transpose bool, value *float32) {\n C.glowUniformMatrix4x2fv(gpUniformMatrix4x2fv, (C.GLint)(location), (C.GLsizei)(count), (C.GLboolean)(boolToInt(transpose)), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func TexParameterfv(target, pname Enum, params []float32) {\n\tgl.TexParameterfv(uint32(target), uint32(pname), &params[0])\n}", "func Uniform1iv(location int32, count int32, value *int32) {\n\tC.glowUniform1iv(gpUniform1iv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func Uniform1iv(location int32, count int32, value *int32) {\n\tC.glowUniform1iv(gpUniform1iv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func (p *RGBAf) Set(x, y int, c color.Color) {\n\tif !(image.Point{x, y}.In(p.Rect)) {\n\t\treturn\n\t}\n\ti := p.PixOffset(x, y)\n\tc1 := color.RGBAModel.Convert(c).(color.RGBA)\n\ts := p.Pix[i : i+4 : i+4] // Small cap improves performance, see https://golang.org/issue/27857\n\ts[0] = float32(c1.R)\n\ts[1] = float32(c1.G)\n\ts[2] = float32(c1.B)\n\ts[3] = float32(c1.A)\n}", "func (s *Shader) setUniformMatrix(name string, value *mgl32.Mat4) {\n location:=gl.GetUniformLocation(s.idPrograma, gl.Str(name + \"\\x00\"))\n if location != -1 { // Si existe ese nombre de variable\n\n bb := new([16]float32) // Creamos un buffer de floats\n for i:=0; i<4; i++{\n for j:=0; j<4; j++ {\n bb[j+i*4] = float32(value.At(i,j))\n }\n }\n gl.UniformMatrix4fv(location, 1, false, &bb[0]) // Enviar a shader matriz PROJECTION * SCALE\n }\n}", "func BindTexture(target uint32, texture uint32) {\n C.glowBindTexture(gpBindTexture, (C.GLenum)(target), (C.GLuint)(texture))\n}", "func (self *TileSprite) TilePattern() *PIXITexture{\n return &PIXITexture{self.Object.Get(\"tilePattern\")}\n}", "func Uniform3uiv(location int32, count int32, value *uint32) {\n C.glowUniform3uiv(gpUniform3uiv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func CopyTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n C.glowCopyTexSubImage3D(gpCopyTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func Interpolate(src image.Image, cube colorcube.Cube, intensity float64) (image.Image, error) {\n\tif intensity < 0 || intensity > 1 {\n\t\treturn src, errors.New(\"intensity must be between 0 and 1\")\n\t}\n\n\tbounds := src.Bounds()\n\n\tout := image.NewNRGBA(image.Rectangle{\n\t\timage.Point{0, 0},\n\t\timage.Point{bounds.Max.X, bounds.Max.Y},\n\t})\n\n\tk := (float64(cube.Size) - 1) / bpc\n\n\tspace := &image.NRGBA{}\n\tmodel := space.ColorModel()\n\n\tdKR := cube.DomainMax[0] - cube.DomainMin[0]\n\tdKG := cube.DomainMax[1] - cube.DomainMin[1]\n\tdKB := cube.DomainMax[2] - cube.DomainMin[2]\n\n\twidth, height := bounds.Dx(), bounds.Dy()\n\tparallel.Line(height, func(start, end int) {\n\t\tfor y := start; y < end; y++ {\n\t\t\tfor x := 0; x < width; x++ {\n\t\t\t\tpx := src.At(x, y)\n\t\t\t\tc := model.Convert(px).(color.NRGBA)\n\n\t\t\t\trgb := getFromRGBTrilinear(\n\t\t\t\t\tint(c.R),\n\t\t\t\t\tint(c.G),\n\t\t\t\t\tint(c.B),\n\t\t\t\t\tcube.Size,\n\t\t\t\t\tk,\n\t\t\t\t\tcube,\n\t\t\t\t)\n\n\t\t\t\to := color.NRGBA{}\n\t\t\t\to.R = uint8(float64(c.R)*(1-intensity) + float64(toIntCh(rgb[0]*dKR))*intensity)\n\t\t\t\to.G = uint8(float64(c.G)*(1-intensity) + float64(toIntCh(rgb[1]*dKG))*intensity)\n\t\t\t\to.B = uint8(float64(c.B)*(1-intensity) + float64(toIntCh(rgb[2]*dKB))*intensity)\n\t\t\t\to.A = c.A\n\n\t\t\t\tout.Set(x, y, o)\n\t\t\t}\n\t\t}\n\t})\n\n\treturn out, nil\n}", "func TexParameterfv(target Enum, pname Enum, params []Float) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tcpname, _ := (C.GLenum)(pname), cgoAllocsUnknown\n\tcparams, _ := (*C.GLfloat)(unsafe.Pointer((*sliceHeader)(unsafe.Pointer(&params)).Data)), cgoAllocsUnknown\n\tC.glTexParameterfv(ctarget, cpname, cparams)\n}", "func ProgramUniform1fv(program uint32, location int32, count int32, value *float32) {\n C.glowProgramUniform1fv(gpProgramUniform1fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func TextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTextureSubImage1D, 7, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(width), uintptr(format), uintptr(xtype), uintptr(pixels), 0, 0)\n}", "func (debugging *debuggingOpenGL) TexParameteri(target uint32, pname uint32, param int32) {\n\tdebugging.recordEntry(\"TexParameteri\", target, pname, param)\n\tdebugging.gl.TexParameteri(target, pname, param)\n\tdebugging.recordExit(\"TexParameteri\")\n}", "func (t Texture3D) SetPixelArea(x, y, z, w, h, depth int32, d []byte, genMipmap bool) error {\n\tif x < 0 || y < 0 || z < 0 || x >= t.width || y >= t.height || z >= t.depth {\n\t\treturn fmt.Errorf(\"SetPixelArea(%v %v %v %v %v %v): %w\", x, y, z, w, h, depth, ErrCoordOutOfRange)\n\t}\n\tgl.PixelStorei(gl.UNPACK_ALIGNMENT, t.alignment)\n\tgl.TextureSubImage3D(t.id, 0, x, y, z, w, h, depth, t.format, gl.UNSIGNED_BYTE, unsafe.Pointer(&d[0]))\n\tif genMipmap {\n\t\tt.Bind()\n\t\tgl.GenerateMipmap(gl.TEXTURE_3D)\n\t\tt.Unbind()\n\t}\n\treturn nil\n}", "func (self *TileSprite) SetTilePatternA(member *PIXITexture) {\n self.Object.Set(\"tilePattern\", member)\n}", "func (t *SinglePixelTexture) Draw(renderer *sdl.Renderer) {\n\trenderer.Copy(t.Texture, nil, &t.Rect)\n}", "func GetTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetTextureSubImage(gpGetTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), (C.GLsizei)(bufSize), pixels)\n}", "func GetTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetTextureSubImage(gpGetTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), (C.GLsizei)(bufSize), pixels)\n}", "func Uniform3f(location int32, v0 float32, v1 float32, v2 float32) {\n C.glowUniform3f(gpUniform3f, (C.GLint)(location), (C.GLfloat)(v0), (C.GLfloat)(v1), (C.GLfloat)(v2))\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexImage2D(gpTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexImage2D(gpTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func (b base) Fill(value uint64) {\n\tbinary.PutUvarint(b.inputBuffer[b.seedLen:], value)\n\t// base64 encoding reduce byte size\n\t// from i to o\n\tb64encoder.Encode(b.outputBuffer, b.inputBuffer)\n}" ]
[ "0.5976961", "0.58245194", "0.5757982", "0.5730466", "0.55506533", "0.55366975", "0.553421", "0.5499369", "0.54849815", "0.54829645", "0.5474141", "0.5471818", "0.54688376", "0.5454622", "0.54320496", "0.54219913", "0.54141694", "0.53985035", "0.5388446", "0.5371576", "0.53577083", "0.53569096", "0.5350548", "0.53480506", "0.5339963", "0.5323169", "0.53196657", "0.5309842", "0.5309006", "0.52795213", "0.52635866", "0.5257321", "0.52554756", "0.5250925", "0.5246948", "0.52450526", "0.5220119", "0.5212222", "0.5206657", "0.51966923", "0.51877725", "0.5163449", "0.51515305", "0.5151056", "0.51413894", "0.5141191", "0.51403475", "0.5135618", "0.5134511", "0.51334137", "0.51170546", "0.5102044", "0.5093191", "0.507102", "0.5068231", "0.50565463", "0.50565463", "0.5049011", "0.50452036", "0.50448483", "0.5044581", "0.5027614", "0.50264984", "0.500606", "0.49989825", "0.49862722", "0.49862722", "0.49807844", "0.49747747", "0.49721178", "0.4965325", "0.4957202", "0.4956149", "0.4951763", "0.49513486", "0.49506474", "0.493924", "0.49388325", "0.49388325", "0.49381933", "0.49263987", "0.49244007", "0.49180967", "0.49077967", "0.49016458", "0.48866636", "0.48858142", "0.488009", "0.4877684", "0.48757935", "0.487154", "0.48696008", "0.48626816", "0.484718", "0.484718", "0.4841193", "0.48382983", "0.48382983", "0.4833647" ]
0.50407785
62
fills all or part of a texture image with a constant value
func ClearTexSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, data unsafe.Pointer) { C.glowClearTexSubImage(gpClearTexSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), data) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func (i *ImageBuf) SetFull(xbegin, xend, ybegin, yend, zbegin, zend int) {\n\tC.ImageBuf_set_full(\n\t\ti.ptr,\n\t\tC.int(xbegin), C.int(xend),\n\t\tC.int(ybegin), C.int(yend),\n\t\tC.int(zbegin), C.int(zend))\n\truntime.KeepAlive(i)\n}", "func (t *Texture) Set(x uint16, y uint16, value rgb565.Rgb565Color) {\n\tt.pixels[y*t.width+x] = value\n}", "func fill(pix []byte, c color.RGBA) {\n\tfor i := 0; i < len(pix); i += 4 {\n\t\tpix[i] = c.R\n\t\tpix[i+1] = c.G\n\t\tpix[i+2] = c.B\n\t\tpix[i+3] = c.A\n\t}\n}", "func (m RGBImage) Fill(vl RGB) {\n\tl := m.Area()\n\tfor i := 0; i < l; i++ {\n\t\tm.Pixels[i] = vl\n\t}\n}", "func (m GrayImage) Fill(vl byte) {\n\tl := m.Area()\n\tfor i := 0; i < l; i++ {\n\t\tm.Pixels[i] = vl\n\t}\n}", "func InvalidateTexImage(texture uint32, level int32) {\n C.glowInvalidateTexImage(gpInvalidateTexImage, (C.GLuint)(texture), (C.GLint)(level))\n}", "func (m IntGrayImage) Fill(vl int) {\n\tl := m.Area()\n\tfor i := 0; i < l; i++ {\n\t\tm.Pixels[i] = vl\n\t}\n}", "func InvalidateTexSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32) {\n C.glowInvalidateTexSubImage(gpInvalidateTexSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth))\n}", "func ShaderProgramFill(r, g, b, a byte) *shaderir.Program {\n\tir, err := graphics.CompileShader([]byte(fmt.Sprintf(`//kage:unit pixels\n\npackage main\n\nfunc Fragment(position vec4, texCoord vec2, color vec4) vec4 {\n\treturn vec4(%0.9f, %0.9f, %0.9f, %0.9f)\n}\n`, float64(r)/0xff, float64(g)/0xff, float64(b)/0xff, float64(a)/0xff)))\n\tif err != nil {\n\t\tpanic(err)\n\t}\n\treturn ir\n}", "func (self *TileSprite) SetTintedTextureA(member *Canvas) {\n self.Object.Set(\"tintedTexture\", member)\n}", "func Uniform1fv(location int32, count int32, value *float32) {\n C.glowUniform1fv(gpUniform1fv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func fill(b *Board, t TileColor) {\n\tfor y := 0; y < BOARD_HEIGHT; y++ {\n\t\tfor x := 0; x < BOARD_WIDTH; x++ {\n\t\t\tb.SetTile(t, x, y)\n\t\t}\n\t}\n}", "func (self *TileSprite) SetTexture(texture *Texture) {\n self.Object.Call(\"setTexture\", texture)\n}", "func TexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexSubImage1D(gpTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func ClearTexImage(texture uint32, level int32, format uint32, xtype uint32, data unsafe.Pointer) {\n C.glowClearTexImage(gpClearTexImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLenum)(format), (C.GLenum)(xtype), data)\n}", "func ClearTexSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, data unsafe.Pointer) {\n C.glowClearTexSubImage(gpClearTexSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), data)\n}", "func (self *TileSprite) SetTilingTextureA(member *PIXITexture) {\n self.Object.Set(\"tilingTexture\", member)\n}", "func (self *TileSprite) SetTextureA(member *Texture) {\n self.Object.Set(\"texture\", member)\n}", "func Uniform1iv(location int32, count int32, value *int32) {\n C.glowUniform1iv(gpUniform1iv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func Uniform4fv(location int32, count int32, value *float32) {\n C.glowUniform4fv(gpUniform4fv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func (p *RGBAf) Set(x, y int, c color.Color) {\n\tif !(image.Point{x, y}.In(p.Rect)) {\n\t\treturn\n\t}\n\ti := p.PixOffset(x, y)\n\tc1 := color.RGBAModel.Convert(c).(color.RGBA)\n\ts := p.Pix[i : i+4 : i+4] // Small cap improves performance, see https://golang.org/issue/27857\n\ts[0] = float32(c1.R)\n\ts[1] = float32(c1.G)\n\ts[2] = float32(c1.B)\n\ts[3] = float32(c1.A)\n}", "func loadImage(pattern int, data []uint8) {\n\tfor i := 0; i < rows; i++ {\n\t\tfor j := 0; j < cols; j++ {\n\t\t\tdata[(4*(i*cols+j))+0] = 0xff\n\t\t\tdata[(4*(i*cols+j))+1] = 0x00\n\t\t\tdata[(4*(i*cols+j))+2] = 0x00\n\t\t\tdata[(4*(i*cols+j))+3] = 0xff\n\t\t}\n\t}\n\tif pattern == 1 {\n\t\tvar border = cols / 4\n\t\tfor i := border; i < rows-border; i++ {\n\t\t\tfor j := border; j < cols-border; j++ {\n\t\t\t\tvalue := rand.Float64()\n\t\t\t\tif value > 0.7 {\n\t\t\t\t\tdata[(4*(i*cols+j))+2] = uint8(math.Round(255.0 * value))\n\t\t\t\t} else {\n\t\t\t\t\tdata[(4*(i*cols+j))+2] = 0xff\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t} else {\n\t\tvar checker = 40\n\t\tfor i := 0; i < rows; i++ {\n\t\t\tfor j := 0; j < cols; j++ {\n\t\t\t\tif (((i/checker)%2) == 0 && ((j/checker)%2) == 0) ||\n\t\t\t\t\t(((i/checker)%2) == 1 && ((j/checker)%2) == 1) {\n\t\t\t\t\tvalue := rand.Float64()\n\t\t\t\t\tdata[(4*(i*cols+j))+2] = uint8(math.Round(255.0 * value))\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n}", "func CopyTexSubImage1D(target uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n C.glowCopyTexSubImage1D(gpCopyTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func (self *TileSprite) SetTexture1O(texture *Texture, destroy bool) {\n self.Object.Call(\"setTexture\", texture, destroy)\n}", "func BindImageTexture(unit uint32, texture uint32, level int32, layered bool, layer int32, access uint32, format uint32) {\n C.glowBindImageTexture(gpBindImageTexture, (C.GLuint)(unit), (C.GLuint)(texture), (C.GLint)(level), (C.GLboolean)(boolToInt(layered)), (C.GLint)(layer), (C.GLenum)(access), (C.GLenum)(format))\n}", "func (b *XMobileBackend) PutImageData(img *image.RGBA, x, y int) {\n\tb.activate()\n\n\tb.glctx.ActiveTexture(gl.TEXTURE0)\n\tif b.imageBufTex.Value == 0 {\n\t\tb.imageBufTex = b.glctx.CreateTexture()\n\t\tb.glctx.BindTexture(gl.TEXTURE_2D, b.imageBufTex)\n\t\tb.glctx.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.LINEAR)\n\t\tb.glctx.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, gl.LINEAR)\n\t\tb.glctx.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_S, gl.CLAMP_TO_EDGE)\n\t\tb.glctx.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_T, gl.CLAMP_TO_EDGE)\n\t} else {\n\t\tb.glctx.BindTexture(gl.TEXTURE_2D, b.imageBufTex)\n\t}\n\n\tw, h := img.Bounds().Dx(), img.Bounds().Dy()\n\n\tif img.Stride == img.Bounds().Dx()*4 {\n\t\tb.glctx.TexImage2D(gl.TEXTURE_2D, 0, gl.RGBA, w, h, gl.RGBA, gl.UNSIGNED_BYTE, img.Pix[0:])\n\t} else {\n\t\tdata := make([]uint8, 0, w*h*4)\n\t\tfor cy := 0; cy < h; cy++ {\n\t\t\tstart := cy * img.Stride\n\t\t\tend := start + w*4\n\t\t\tdata = append(data, img.Pix[start:end]...)\n\t\t}\n\t\tb.glctx.TexImage2D(gl.TEXTURE_2D, 0, gl.RGBA, w, h, gl.RGBA, gl.UNSIGNED_BYTE, data[0:])\n\t}\n\n\tdx, dy := float32(x), float32(y)\n\tdw, dh := float32(w), float32(h)\n\n\tb.glctx.BindBuffer(gl.ARRAY_BUFFER, b.buf)\n\tdata := [16]float32{dx, dy, dx + dw, dy, dx + dw, dy + dh, dx, dy + dh,\n\t\t0, 0, 1, 0, 1, 1, 0, 1}\n\tb.glctx.BufferData(gl.ARRAY_BUFFER, byteSlice(unsafe.Pointer(&data[0]), len(data)*4), gl.STREAM_DRAW)\n\n\tb.glctx.UseProgram(b.shd.ID)\n\tb.glctx.Uniform1i(b.shd.Image, 0)\n\tb.glctx.Uniform2f(b.shd.CanvasSize, float32(b.fw), float32(b.fh))\n\tb.glctx.UniformMatrix3fv(b.shd.Matrix, mat3identity[:])\n\tb.glctx.Uniform1f(b.shd.GlobalAlpha, 1)\n\tb.glctx.Uniform1i(b.shd.UseAlphaTex, 0)\n\tb.glctx.Uniform1i(b.shd.Func, shdFuncImage)\n\tb.glctx.VertexAttribPointer(b.shd.Vertex, 2, gl.FLOAT, false, 0, 0)\n\tb.glctx.VertexAttribPointer(b.shd.TexCoord, 2, gl.FLOAT, false, 0, 8*4)\n\tb.glctx.EnableVertexAttribArray(b.shd.Vertex)\n\tb.glctx.EnableVertexAttribArray(b.shd.TexCoord)\n\tb.glctx.DrawArrays(gl.TRIANGLE_FAN, 0, 4)\n\tb.glctx.DisableVertexAttribArray(b.shd.Vertex)\n\tb.glctx.DisableVertexAttribArray(b.shd.TexCoord)\n}", "func InvalidateTexImage(texture uint32, level int32) {\n\tsyscall.Syscall(gpInvalidateTexImage, 2, uintptr(texture), uintptr(level), 0)\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexSubImage3D(gpTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func ClearTexImage(texture uint32, level int32, format uint32, xtype uint32, data unsafe.Pointer) {\n\tsyscall.Syscall6(gpClearTexImage, 5, uintptr(texture), uintptr(level), uintptr(format), uintptr(xtype), uintptr(data), 0)\n}", "func (t Texture3D) SetPixelArea(x, y, z, w, h, depth int32, d []byte, genMipmap bool) error {\n\tif x < 0 || y < 0 || z < 0 || x >= t.width || y >= t.height || z >= t.depth {\n\t\treturn fmt.Errorf(\"SetPixelArea(%v %v %v %v %v %v): %w\", x, y, z, w, h, depth, ErrCoordOutOfRange)\n\t}\n\tgl.PixelStorei(gl.UNPACK_ALIGNMENT, t.alignment)\n\tgl.TextureSubImage3D(t.id, 0, x, y, z, w, h, depth, t.format, gl.UNSIGNED_BYTE, unsafe.Pointer(&d[0]))\n\tif genMipmap {\n\t\tt.Bind()\n\t\tgl.GenerateMipmap(gl.TEXTURE_3D)\n\t\tt.Unbind()\n\t}\n\treturn nil\n}", "func (self *TileSprite) SetRefreshTextureA(member bool) {\n self.Object.Set(\"refreshTexture\", member)\n}", "func Fill(imageBytes []byte, width, height int, maxBytes int, anchor imaging.Anchor) ([]byte, string, error) {\n\treturn process(imageBytes, maxBytes, func(image image.Image) image.Image {\n\t\treturn imaging.Fill(image, width, height, anchor, imaging.MitchellNetravali)\n\t})\n}", "func Uniform4iv(location int32, count int32, value *int32) {\n C.glowUniform4iv(gpUniform4iv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func Uniform2fv(location int32, count int32, value *float32) {\n C.glowUniform2fv(gpUniform2fv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func TexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexSubImage2D(gpTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func (fb *FrameBuffer) Fill(rect _core.Rect, c color.Color) {\n\tfor i := rect.Min.Y; i < rect.Max.Y; i++ {\n\t\tfor j := rect.Min.X; j < rect.Max.X; j++ {\n\t\t\tfb.SetColorAt(int(j), int(i), c)\n\t\t}\n\t}\n}", "func BindImageTextures(first uint32, count int32, textures *uint32) {\n C.glowBindImageTextures(gpBindImageTextures, (C.GLuint)(first), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(textures)))\n}", "func Make(width, height int, internalformat int32, format, pixelType uint32,\n\tdata unsafe.Pointer, min, mag, s, t int32) Texture {\n\n\ttexture := Texture{0, gl.TEXTURE_2D, 0}\n\n\t// generate and bind texture\n\tgl.GenTextures(1, &texture.handle)\n\ttexture.Bind(0)\n\n\t// set texture properties\n\tgl.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, min)\n\tgl.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, mag)\n\tgl.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_S, s)\n\tgl.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_T, t)\n\n\t// specify a texture image\n\tgl.TexImage2D(gl.TEXTURE_2D, 0, internalformat, int32(width), int32(height),\n\t\t0, format, pixelType, data)\n\n\t// unbind texture\n\ttexture.Unbind()\n\n\treturn texture\n}", "func (self *TraitPixbuf) Fill(pixel uint32) {\n\tC.gdk_pixbuf_fill(self.CPointer, C.guint32(pixel))\n\treturn\n}", "func (p *P1D) Fill(x, y, w float64) {\n\tp.bng.fill(x, y, w)\n}", "func Uniform3fv(location int32, count int32, value *float32) {\n C.glowUniform3fv(gpUniform3fv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func (tex Texture) Sub(ctx gl.Context, lvl int, width int, height int, data []byte) {\n\tctx.TexSubImage2D(gl.TEXTURE_2D, lvl, 0, 0, width, height, gl.RGBA, gl.UNSIGNED_BYTE, data)\n\tif lvl > 0 {\n\t\tctx.GenerateMipmap(gl.TEXTURE_2D)\n\t}\n}", "func CopyTexImage2D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, height int32, border int32) {\n C.glowCopyTexImage2D(gpCopyTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border))\n}", "func CopyTexImage1D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, border int32) {\n C.glowCopyTexImage1D(gpCopyTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLint)(border))\n}", "func (level *Level) SetTextures(newIds []int) {\n\tblockStore := level.store.Get(res.ResourceID(4000 + level.id*100 + 7))\n\tvar ids [54]uint16\n\ttoCopy := len(ids)\n\n\tif len(newIds) < toCopy {\n\t\ttoCopy = len(newIds)\n\t}\n\tfor index := 0; index < len(ids); index++ {\n\t\tids[index] = uint16(newIds[index])\n\t}\n\n\tbuffer := bytes.NewBuffer(nil)\n\tbinary.Write(buffer, binary.LittleEndian, &ids)\n\tblockStore.SetBlockData(0, buffer.Bytes())\n}", "func Interpolate(src image.Image, cube colorcube.Cube, intensity float64) (image.Image, error) {\n\tif intensity < 0 || intensity > 1 {\n\t\treturn src, errors.New(\"intensity must be between 0 and 1\")\n\t}\n\n\tbounds := src.Bounds()\n\n\tout := image.NewNRGBA(image.Rectangle{\n\t\timage.Point{0, 0},\n\t\timage.Point{bounds.Max.X, bounds.Max.Y},\n\t})\n\n\tk := (float64(cube.Size) - 1) / bpc\n\n\tspace := &image.NRGBA{}\n\tmodel := space.ColorModel()\n\n\tdKR := cube.DomainMax[0] - cube.DomainMin[0]\n\tdKG := cube.DomainMax[1] - cube.DomainMin[1]\n\tdKB := cube.DomainMax[2] - cube.DomainMin[2]\n\n\twidth, height := bounds.Dx(), bounds.Dy()\n\tparallel.Line(height, func(start, end int) {\n\t\tfor y := start; y < end; y++ {\n\t\t\tfor x := 0; x < width; x++ {\n\t\t\t\tpx := src.At(x, y)\n\t\t\t\tc := model.Convert(px).(color.NRGBA)\n\n\t\t\t\trgb := getFromRGBTrilinear(\n\t\t\t\t\tint(c.R),\n\t\t\t\t\tint(c.G),\n\t\t\t\t\tint(c.B),\n\t\t\t\t\tcube.Size,\n\t\t\t\t\tk,\n\t\t\t\t\tcube,\n\t\t\t\t)\n\n\t\t\t\to := color.NRGBA{}\n\t\t\t\to.R = uint8(float64(c.R)*(1-intensity) + float64(toIntCh(rgb[0]*dKR))*intensity)\n\t\t\t\to.G = uint8(float64(c.G)*(1-intensity) + float64(toIntCh(rgb[1]*dKG))*intensity)\n\t\t\t\to.B = uint8(float64(c.B)*(1-intensity) + float64(toIntCh(rgb[2]*dKB))*intensity)\n\t\t\t\to.A = c.A\n\n\t\t\t\tout.Set(x, y, o)\n\t\t\t}\n\t\t}\n\t})\n\n\treturn out, nil\n}", "func (self *TileSprite) SetTilePatternA(member *PIXITexture) {\n self.Object.Set(\"tilePattern\", member)\n}", "func (self *TileSprite) SetTextureI(args ...interface{}) {\n self.Object.Call(\"setTexture\", args)\n}", "func InvalidateTexImage(texture uint32, level int32) {\n\tC.glowInvalidateTexImage(gpInvalidateTexImage, (C.GLuint)(texture), (C.GLint)(level))\n}", "func InvalidateTexImage(texture uint32, level int32) {\n\tC.glowInvalidateTexImage(gpInvalidateTexImage, (C.GLuint)(texture), (C.GLint)(level))\n}", "func TexImage1D(target uint32, level int32, internalformat int32, width int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexImage1D(gpTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func drawBackground(image *image.RGBA, mem *GBMem) *image.RGBA {\n\tfor x := 0; x < MapWidth; x++ {\n\t\tfor y := 0; y < MapHeight; y++ {\n\t\t\t// get tile index\n\t\t\ttileIndex := mem.read(uint16(VRAMBackgroundMap + x + (y * MapHeight)))\n\n\t\t\t// get pixels corresponding to tile index\n\t\t\tpixels := tileToPixel(tileIndex, mem)\n\n\t\t\t// draw pixels\n\t\t\tdrawTilePixels(image, pixels, x, y)\n\t\t}\n\t}\n\treturn image\n}", "func (v *Bitmap256) Set(pos uint8) {\n\tv[pos>>6] |= 1 << (pos & 63)\n}", "func (w *Worley) GenerateTexture(tex *texture.Texture) {\n\tgl.BindImageTexture(0, tex.GetHandle(), 0, false, 0, gl.READ_WRITE, gl.RGBA32F)\n\tgl.BindImageTexture(1, w.noisetexture.GetHandle(), 0, false, 0, gl.READ_ONLY, gl.RGBA32F)\n\n\tw.computeshader.Use()\n\tw.computeshader.UpdateInt32(\"uWidth\", w.width)\n\tw.computeshader.UpdateInt32(\"uHeight\", w.height)\n\tw.computeshader.UpdateInt32(\"uResolution\", w.resolution)\n\tw.computeshader.UpdateInt32(\"uOctaves\", w.octaves)\n\tw.computeshader.UpdateFloat32(\"uRadius\", w.radius)\n\tw.computeshader.UpdateFloat32(\"uRadiusScale\", w.radiusscale)\n\tw.computeshader.UpdateFloat32(\"uBrightness\", w.brightness)\n\tw.computeshader.UpdateFloat32(\"uContrast\", w.contrast)\n\tw.computeshader.UpdateFloat32(\"uScale\", w.scale)\n\tw.computeshader.UpdateFloat32(\"uPersistance\", w.persistance)\n\tw.computeshader.Compute(uint32(w.width), uint32(w.height), 1)\n\tw.computeshader.Compute(1024, 1024, 1)\n\tw.computeshader.Release()\n\n\tgl.MemoryBarrier(gl.ALL_BARRIER_BITS)\n\n\tgl.BindImageTexture(0, 0, 0, false, 0, gl.WRITE_ONLY, gl.RGBA32F)\n\tgl.BindImageTexture(1, 0, 0, false, 0, gl.READ_ONLY, gl.RGBA32F)\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexImage2D(gpTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func (p *GIFPrinter) drawExact(target *image.Paletted, source image.Image) {\n\tbounds := source.Bounds()\n\tfor y := bounds.Min.Y; y < bounds.Max.Y; y++ {\n\t\tfor x := bounds.Min.X; x < bounds.Max.X; x++ {\n\t\t\ttarget.Set(x, y, source.At(x, y))\n\t\t}\n\t}\n}", "func Uniform4f(location int32, v0 float32, v1 float32, v2 float32, v3 float32) {\n C.glowUniform4f(gpUniform4f, (C.GLint)(location), (C.GLfloat)(v0), (C.GLfloat)(v1), (C.GLfloat)(v2), (C.GLfloat)(v3))\n}", "func Uniform2iv(location int32, count int32, value *int32) {\n C.glowUniform2iv(gpUniform2iv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func Uniform1f(location int32, v0 float32) {\n C.glowUniform1f(gpUniform1f, (C.GLint)(location), (C.GLfloat)(v0))\n}", "func BindTextures(first uint32, count int32, textures *uint32) {\n C.glowBindTextures(gpBindTextures, (C.GLuint)(first), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(textures)))\n}", "func Uniform1uiv(location int32, count int32, value *uint32) {\n C.glowUniform1uiv(gpUniform1uiv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func Uniform3iv(location int32, count int32, value *int32) {\n C.glowUniform3iv(gpUniform3iv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLint)(unsafe.Pointer(value)))\n}", "func New(width uint16, height uint16) *Texture {\n\tt := &Texture{\n\t\twidth: width,\n\t\theight: height,\n\t\tpixels: make([]rgb565.Rgb565Color, width*height),\n\t}\n\n\tfor i := range t.pixels {\n\t\tt.pixels[i] = rgb565.New(0x00, 0x00, 0x00)\n\t}\n\n\treturn t\n}", "func SetPixel(n, r, g, b uint8) {\n\tbuffer[n*3] = g\n\tbuffer[n*3+1] = r\n\tbuffer[n*3+2] = b\n}", "func Uniform4uiv(location int32, count int32, value *uint32) {\n C.glowUniform4uiv(gpUniform4uiv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(value)))\n}", "func FramebufferTexture(target uint32, attachment uint32, texture uint32, level int32) {\n C.glowFramebufferTexture(gpFramebufferTexture, (C.GLenum)(target), (C.GLenum)(attachment), (C.GLuint)(texture), (C.GLint)(level))\n}", "func InvalidateTexSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32) {\n\tC.glowInvalidateTexSubImage(gpInvalidateTexSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth))\n}", "func InvalidateTexSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32) {\n\tC.glowInvalidateTexSubImage(gpInvalidateTexSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth))\n}", "func (t *SinglePixelTexture) Draw(renderer *sdl.Renderer) {\n\trenderer.Copy(t.Texture, nil, &t.Rect)\n}", "func CopyTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n C.glowCopyTexSubImage3D(gpCopyTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func (self *TileSprite) TilePattern() *PIXITexture{\n return &PIXITexture{self.Object.Get(\"tilePattern\")}\n}", "func GetTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetTextureSubImage(gpGetTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), (C.GLsizei)(bufSize), pixels)\n}", "func GetTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetTextureSubImage(gpGetTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), (C.GLsizei)(bufSize), pixels)\n}", "func Image(m *image.RGBA, key string, colors []color.RGBA) {\n\tsize := m.Bounds().Size()\n\tsquares := 6\n\tquad := size.X / squares\n\tmiddle := math.Ceil(float64(squares) / float64(2))\n\tcolorMap := make(map[int]color.RGBA)\n\tvar currentYQuadrand = 0\n\tfor y := 0; y < size.Y; y++ {\n\t\tyQuadrant := y / quad\n\t\tif yQuadrant != currentYQuadrand {\n\t\t\t// when y quadrant changes, clear map\n\t\t\tcolorMap = make(map[int]color.RGBA)\n\t\t\tcurrentYQuadrand = yQuadrant\n\t\t}\n\t\tfor x := 0; x < size.X; x++ {\n\t\t\txQuadrant := x / quad\n\t\t\tif _, ok := colorMap[xQuadrant]; !ok {\n\t\t\t\tif float64(xQuadrant) < middle {\n\t\t\t\t\tcolorMap[xQuadrant] = draw.PickColor(key, colors, xQuadrant+3*yQuadrant)\n\t\t\t\t} else if xQuadrant < squares {\n\t\t\t\t\tcolorMap[xQuadrant] = colorMap[squares-xQuadrant-1]\n\t\t\t\t} else {\n\t\t\t\t\tcolorMap[xQuadrant] = colorMap[0]\n\t\t\t\t}\n\t\t\t}\n\t\t\tm.Set(x, y, colorMap[xQuadrant])\n\t\t}\n\t}\n}", "func CopyTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n C.glowCopyTexSubImage2D(gpCopyTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func Uniform4i(location int32, v0 int32, v1 int32, v2 int32, v3 int32) {\n C.glowUniform4i(gpUniform4i, (C.GLint)(location), (C.GLint)(v0), (C.GLint)(v1), (C.GLint)(v2), (C.GLint)(v3))\n}", "func TexParameterfv(target, pname Enum, params []float32) {\n\tgl.TexParameterfv(uint32(target), uint32(pname), &params[0])\n}", "func ClearTexImage(texture uint32, level int32, format uint32, xtype uint32, data unsafe.Pointer) {\n\tC.glowClearTexImage(gpClearTexImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLenum)(format), (C.GLenum)(xtype), data)\n}", "func ClearTexImage(texture uint32, level int32, format uint32, xtype uint32, data unsafe.Pointer) {\n\tC.glowClearTexImage(gpClearTexImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLenum)(format), (C.GLenum)(xtype), data)\n}", "func (b base) Fill(value uint64) {\n\tbinary.PutUvarint(b.inputBuffer[b.seedLen:], value)\n\t// base64 encoding reduce byte size\n\t// from i to o\n\tb64encoder.Encode(b.outputBuffer, b.inputBuffer)\n}", "func PaintFill(image [][]rune, row, col int, newColor rune) {\n\tpaintFillHelper(image, row, col, image[row][col], newColor)\n}", "func TextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTextureSubImage1D, 7, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(width), uintptr(format), uintptr(xtype), uintptr(pixels), 0, 0)\n}", "func (r *Rasterizer8BitsSample) fillNonZero(img *image.RGBA, c color.Color, clipBound [4]float64) {\n\tvar x, y uint32\n\n\tminX := uint32(clipBound[0])\n\tmaxX := uint32(clipBound[2])\n\n\tminY := uint32(clipBound[1]) >> SUBPIXEL_SHIFT\n\tmaxY := uint32(clipBound[3]) >> SUBPIXEL_SHIFT\n\n\trgba := convert(c)\n\tpixColor := *(*uint32)(unsafe.Pointer(&rgba))\n\tcs1 := pixColor & 0xff00ff\n\tcs2 := pixColor >> 8 & 0xff00ff\n\n\tstride := uint32(img.Stride)\n\tvar mask SUBPIXEL_DATA\n\tvar n uint32\n\tvar values [SUBPIXEL_COUNT]NON_ZERO_MASK_DATA_UNIT\n\n\tmaskY := minY * uint32(r.BufferWidth)\n\tminY *= stride\n\tmaxY *= stride\n\tvar pixelx uint32\n\tfor y = minY; y < maxY; y += stride {\n\t\ttp := img.Pix[y:]\n\t\tmask = 0\n\t\tpixelx = minX * 4\n\t\tfor x = minX; x <= maxX; x++ {\n\t\t\ttemp := r.MaskBuffer[maskY+x]\n\t\t\tif temp != 0 {\n\t\t\t\tvar bit SUBPIXEL_DATA = 1\n\t\t\t\tfor n = 0; n < SUBPIXEL_COUNT; n++ {\n\t\t\t\t\tif temp&bit != 0 {\n\t\t\t\t\t\tt := values[n]\n\t\t\t\t\t\tvalues[n] += r.WindingBuffer[(maskY+x)*SUBPIXEL_COUNT+n]\n\t\t\t\t\t\tif (t == 0 || values[n] == 0) && t != values[n] {\n\t\t\t\t\t\t\tmask ^= bit\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\tbit <<= 1\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t// 8bits\r\n\t\t\talpha := uint32(coverageTable[mask])\n\t\t\t// 16bits\r\n\t\t\t//alpha := uint32(coverageTable[mask & 0xff] + coverageTable[(mask >> 8) & 0xff])\r\n\t\t\t// 32bits\r\n\t\t\t//alpha := uint32(coverageTable[mask & 0xff] + coverageTable[(mask >> 8) & 0xff] + coverageTable[(mask >> 16) & 0xff] + coverageTable[(mask >> 24) & 0xff])\r\n\n\t\t\tp := (*uint32)(unsafe.Pointer(&tp[pixelx]))\n\t\t\tif alpha == SUBPIXEL_FULL_COVERAGE {\n\t\t\t\t*p = pixColor\n\t\t\t} else if alpha != 0 {\n\t\t\t\t// alpha is in range of 0 to SUBPIXEL_COUNT\r\n\t\t\t\tinvAlpha := uint32(SUBPIXEL_COUNT) - alpha\n\n\t\t\t\tct1 := *p & 0xff00ff * invAlpha\n\t\t\t\tct2 := *p >> 8 & 0xff00ff * invAlpha\n\n\t\t\t\tct1 = (ct1 + cs1*alpha) >> SUBPIXEL_SHIFT & 0xff00ff\n\t\t\t\tct2 = (ct2 + cs2*alpha) << (8 - SUBPIXEL_SHIFT) & 0xff00ff00\n\n\t\t\t\t*p = ct1 + ct2\n\t\t\t}\n\t\t\tpixelx += 4\n\t\t}\n\t\tmaskY += uint32(r.BufferWidth)\n\t}\n}", "func (tb *Textbox) Fill(u rune) error {\n\tif !utf8.ValidRune(u) {\n\t\treturn errors.New(\"invalid rune\")\n\t}\n\n\tfor i := range tb.pixels {\n\t\ttb.pixels[i] = u\n\t}\n\treturn nil\n}", "func TextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage1D(gpTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage1D(gpTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CopyTextureSubImage1D(texture uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tC.glowCopyTextureSubImage1D(gpCopyTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func CopyTextureSubImage1D(texture uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tC.glowCopyTextureSubImage1D(gpCopyTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func (v *Vec4) Fill(x, y, z, w float32) {\n\tv.X = x\n\tv.Y = y\n\tv.Z = z\n\tv.W = w\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage3D(gpTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage3D(gpTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func LoadTextures(eng sprite.Engine) map[string]sprite.SubTex {\n\tallTexs := make(map[string]sprite.SubTex)\n\tboundedImgs := []string{\"Clubs-2.png\", \"Clubs-3.png\", \"Clubs-4.png\", \"Clubs-5.png\", \"Clubs-6.png\", \"Clubs-7.png\", \"Clubs-8.png\",\n\t\t\"Clubs-9.png\", \"Clubs-10.png\", \"Clubs-Jack.png\", \"Clubs-Queen.png\", \"Clubs-King.png\", \"Clubs-Ace.png\",\n\t\t\"Diamonds-2.png\", \"Diamonds-3.png\", \"Diamonds-4.png\", \"Diamonds-5.png\", \"Diamonds-6.png\", \"Diamonds-7.png\", \"Diamonds-8.png\",\n\t\t\"Diamonds-9.png\", \"Diamonds-10.png\", \"Diamonds-Jack.png\", \"Diamonds-Queen.png\", \"Diamonds-King.png\", \"Diamonds-Ace.png\",\n\t\t\"Spades-2.png\", \"Spades-3.png\", \"Spades-4.png\", \"Spades-5.png\", \"Spades-6.png\", \"Spades-7.png\", \"Spades-8.png\",\n\t\t\"Spades-9.png\", \"Spades-10.png\", \"Spades-Jack.png\", \"Spades-Queen.png\", \"Spades-King.png\", \"Spades-Ace.png\",\n\t\t\"Hearts-2.png\", \"Hearts-3.png\", \"Hearts-4.png\", \"Hearts-5.png\", \"Hearts-6.png\", \"Hearts-7.png\", \"Hearts-8.png\",\n\t\t\"Hearts-9.png\", \"Hearts-10.png\", \"Hearts-Jack.png\", \"Hearts-Queen.png\", \"Hearts-King.png\", \"Hearts-Ace.png\", \"BakuSquare.png\",\n\t}\n\tunboundedImgs := []string{\"Club.png\", \"Diamond.png\", \"Spade.png\", \"Heart.png\", \"gray.jpeg\", \"blue.png\", \"trickDrop.png\",\n\t\t\"trickDropBlue.png\", \"player0.jpeg\", \"player1.jpeg\", \"player2.jpeg\", \"player3.jpeg\", \"laptopIcon.png\", \"watchIcon.png\",\n\t\t\"phoneIcon.png\", \"tabletIcon.png\", \"A-Upper.png\", \"B-Upper.png\", \"C-Upper.png\", \"D-Upper.png\", \"E-Upper.png\", \"F-Upper.png\",\n\t\t\"G-Upper.png\", \"H-Upper.png\", \"I-Upper.png\", \"J-Upper.png\", \"K-Upper.png\", \"L-Upper.png\", \"M-Upper.png\", \"N-Upper.png\",\n\t\t\"O-Upper.png\", \"P-Upper.png\", \"Q-Upper.png\", \"R-Upper.png\", \"S-Upper.png\", \"T-Upper.png\", \"U-Upper.png\", \"V-Upper.png\",\n\t\t\"W-Upper.png\", \"X-Upper.png\", \"Y-Upper.png\", \"Z-Upper.png\", \"A-Lower.png\", \"B-Lower.png\", \"C-Lower.png\", \"D-Lower.png\",\n\t\t\"E-Lower.png\", \"F-Lower.png\", \"G-Lower.png\", \"H-Lower.png\", \"I-Lower.png\", \"J-Lower.png\", \"K-Lower.png\", \"L-Lower.png\",\n\t\t\"M-Lower.png\", \"N-Lower.png\", \"O-Lower.png\", \"P-Lower.png\", \"Q-Lower.png\", \"R-Lower.png\", \"S-Lower.png\", \"T-Lower.png\",\n\t\t\"U-Lower.png\", \"V-Lower.png\", \"W-Lower.png\", \"X-Lower.png\", \"Y-Lower.png\", \"Z-Lower.png\", \"Space.png\", \"Colon.png\", \"Bang.png\",\n\t\t\"Apostrophe.png\", \"1.png\", \"2.png\", \"3.png\", \"4.png\", \"5.png\", \"6.png\", \"7.png\", \"8.png\", \"9.png\", \"0.png\", \"1-Red.png\",\n\t\t\"2-Red.png\", \"3-Red.png\", \"4-Red.png\", \"5-Red.png\", \"6-Red.png\", \"7-Red.png\", \"8-Red.png\", \"9-Red.png\", \"0-Red.png\",\n\t\t\"1-DBlue.png\", \"2-DBlue.png\", \"3-DBlue.png\", \"4-DBlue.png\", \"5-DBlue.png\", \"6-DBlue.png\", \"7-DBlue.png\", \"8-DBlue.png\",\n\t\t\"9-DBlue.png\", \"0-DBlue.png\", \"A-Upper-DBlue.png\", \"B-Upper-DBlue.png\",\n\t\t\"C-Upper-DBlue.png\", \"D-Upper-DBlue.png\", \"E-Upper-DBlue.png\", \"F-Upper-DBlue.png\", \"G-Upper-DBlue.png\", \"H-Upper-DBlue.png\",\n\t\t\"I-Upper-DBlue.png\", \"J-Upper-DBlue.png\", \"K-Upper-DBlue.png\", \"L-Upper-DBlue.png\", \"M-Upper-DBlue.png\", \"N-Upper-DBlue.png\",\n\t\t\"O-Upper-DBlue.png\", \"P-Upper-DBlue.png\", \"Q-Upper-DBlue.png\", \"R-Upper-DBlue.png\", \"S-Upper-DBlue.png\", \"T-Upper-DBlue.png\",\n\t\t\"U-Upper-DBlue.png\", \"V-Upper-DBlue.png\", \"W-Upper-DBlue.png\", \"X-Upper-DBlue.png\", \"Y-Upper-DBlue.png\", \"Z-Upper-DBlue.png\",\n\t\t\"A-Lower-DBlue.png\", \"B-Lower-DBlue.png\", \"C-Lower-DBlue.png\", \"D-Lower-DBlue.png\", \"E-Lower-DBlue.png\", \"F-Lower-DBlue.png\",\n\t\t\"G-Lower-DBlue.png\", \"H-Lower-DBlue.png\", \"I-Lower-DBlue.png\", \"J-Lower-DBlue.png\", \"K-Lower-DBlue.png\", \"L-Lower-DBlue.png\",\n\t\t\"M-Lower-DBlue.png\", \"N-Lower-DBlue.png\", \"O-Lower-DBlue.png\", \"P-Lower-DBlue.png\", \"Q-Lower-DBlue.png\", \"R-Lower-DBlue.png\",\n\t\t\"S-Lower-DBlue.png\", \"T-Lower-DBlue.png\", \"U-Lower-DBlue.png\", \"V-Lower-DBlue.png\", \"W-Lower-DBlue.png\", \"X-Lower-DBlue.png\",\n\t\t\"Y-Lower-DBlue.png\", \"Z-Lower-DBlue.png\", \"Apostrophe-DBlue.png\", \"Space-DBlue.png\", \"A-Upper-LBlue.png\", \"B-Upper-LBlue.png\",\n\t\t\"C-Upper-LBlue.png\", \"D-Upper-LBlue.png\", \"E-Upper-LBlue.png\", \"F-Upper-LBlue.png\", \"G-Upper-LBlue.png\", \"H-Upper-LBlue.png\",\n\t\t\"I-Upper-LBlue.png\", \"J-Upper-LBlue.png\", \"K-Upper-LBlue.png\", \"L-Upper-LBlue.png\", \"M-Upper-LBlue.png\", \"N-Upper-LBlue.png\",\n\t\t\"O-Upper-LBlue.png\", \"P-Upper-LBlue.png\", \"Q-Upper-LBlue.png\", \"R-Upper-LBlue.png\", \"S-Upper-LBlue.png\", \"T-Upper-LBlue.png\",\n\t\t\"U-Upper-LBlue.png\", \"V-Upper-LBlue.png\", \"W-Upper-LBlue.png\", \"X-Upper-LBlue.png\", \"Y-Upper-LBlue.png\", \"Z-Upper-LBlue.png\",\n\t\t\"A-Lower-LBlue.png\", \"B-Lower-LBlue.png\", \"C-Lower-LBlue.png\", \"D-Lower-LBlue.png\", \"E-Lower-LBlue.png\", \"F-Lower-LBlue.png\",\n\t\t\"G-Lower-LBlue.png\", \"H-Lower-LBlue.png\", \"I-Lower-LBlue.png\", \"J-Lower-LBlue.png\", \"K-Lower-LBlue.png\", \"L-Lower-LBlue.png\",\n\t\t\"M-Lower-LBlue.png\", \"N-Lower-LBlue.png\", \"O-Lower-LBlue.png\", \"P-Lower-LBlue.png\", \"Q-Lower-LBlue.png\", \"R-Lower-LBlue.png\",\n\t\t\"S-Lower-LBlue.png\", \"T-Lower-LBlue.png\", \"U-Lower-LBlue.png\", \"V-Lower-LBlue.png\", \"W-Lower-LBlue.png\", \"X-Lower-LBlue.png\",\n\t\t\"Y-Lower-LBlue.png\", \"Z-Lower-LBlue.png\", \"A-Upper-Gray.png\", \"B-Upper-Gray.png\", \"C-Upper-Gray.png\", \"D-Upper-Gray.png\",\n\t\t\"E-Upper-Gray.png\", \"F-Upper-Gray.png\", \"G-Upper-Gray.png\", \"H-Upper-Gray.png\", \"I-Upper-Gray.png\", \"J-Upper-Gray.png\",\n\t\t\"K-Upper-Gray.png\", \"L-Upper-Gray.png\", \"M-Upper-Gray.png\", \"N-Upper-Gray.png\", \"O-Upper-Gray.png\", \"P-Upper-Gray.png\",\n\t\t\"Q-Upper-Gray.png\", \"R-Upper-Gray.png\", \"S-Upper-Gray.png\", \"T-Upper-Gray.png\", \"U-Upper-Gray.png\", \"V-Upper-Gray.png\",\n\t\t\"W-Upper-Gray.png\", \"X-Upper-Gray.png\", \"Y-Upper-Gray.png\", \"Z-Upper-Gray.png\", \"A-Lower-Gray.png\", \"B-Lower-Gray.png\",\n\t\t\"C-Lower-Gray.png\", \"D-Lower-Gray.png\", \"E-Lower-Gray.png\", \"F-Lower-Gray.png\", \"G-Lower-Gray.png\", \"H-Lower-Gray.png\",\n\t\t\"I-Lower-Gray.png\", \"J-Lower-Gray.png\", \"K-Lower-Gray.png\", \"L-Lower-Gray.png\", \"M-Lower-Gray.png\", \"N-Lower-Gray.png\",\n\t\t\"O-Lower-Gray.png\", \"P-Lower-Gray.png\", \"Q-Lower-Gray.png\", \"R-Lower-Gray.png\", \"S-Lower-Gray.png\", \"T-Lower-Gray.png\",\n\t\t\"U-Lower-Gray.png\", \"V-Lower-Gray.png\", \"W-Lower-Gray.png\", \"X-Lower-Gray.png\", \"Y-Lower-Gray.png\", \"Z-Lower-Gray.png\",\n\t\t\"Space-Gray.png\", \"RoundedRectangle-DBlue.png\", \"RoundedRectangle-LBlue.png\", \"RoundedRectangle-Gray.png\", \"Rectangle-LBlue.png\",\n\t\t\"Rectangle-DBlue.png\", \"HorizontalPullTab.png\", \"VerticalPullTab.png\", \"NewGamePressed.png\", \"NewGameUnpressed.png\",\n\t\t\"NewRoundPressed.png\", \"NewRoundUnpressed.png\", \"JoinGamePressed.png\", \"JoinGameUnpressed.png\", \"Period.png\",\n\t\t\"SitSpotPressed.png\", \"SitSpotUnpressed.png\", \"WatchSpotPressed.png\", \"WatchSpotUnpressed.png\", \"StartBlue.png\", \"StartGray.png\",\n\t\t\"StartBluePressed.png\", \"Restart.png\", \"Visibility.png\", \"VisibilityOff.png\", \"QuitPressed.png\", \"QuitUnpressed.png\",\n\t\t\"PassPressed.png\", \"PassUnpressed.png\", \"RightArrowBlue.png\", \"LeftArrowBlue.png\", \"AcrossArrowBlue.png\", \"RightArrowGray.png\",\n\t\t\"LeftArrowGray.png\", \"AcrossArrowGray.png\", \"TakeTrickTableUnpressed.png\", \"TakeTrickTablePressed.png\", \"TakeTrickHandPressed.png\",\n\t\t\"TakeTrickHandUnpressed.png\", \"android.png\", \"cat.png\", \"man.png\", \"woman.png\", \"TakeUnpressed.png\", \"TakePressed.png\",\n\t\t\"UnplayedBorder1.png\", \"UnplayedBorder2.png\", \"RejoinPressed.png\", \"RejoinUnpressed.png\",\n\t}\n\tfor _, f := range boundedImgs {\n\t\ta, err := asset.Open(f)\n\t\tif err != nil {\n\t\t\tlog.Fatal(err)\n\t\t}\n\n\t\timg, _, err := image.Decode(a)\n\t\tif err != nil {\n\t\t\tlog.Fatal(err)\n\t\t}\n\t\tt, err := eng.LoadTexture(img)\n\t\tif err != nil {\n\t\t\tlog.Fatal(err)\n\t\t}\n\t\timgWidth, imgHeight := t.Bounds()\n\t\tallTexs[f] = sprite.SubTex{t, image.Rect(0, 0, imgWidth, imgHeight)}\n\t\ta.Close()\n\t}\n\tfor _, f := range unboundedImgs {\n\t\ta, err := asset.Open(f)\n\t\tif err != nil {\n\t\t\tlog.Fatal(err)\n\t\t}\n\n\t\timg, _, err := image.Decode(a)\n\t\tif err != nil {\n\t\t\tlog.Fatal(err)\n\t\t}\n\t\tt, err := eng.LoadTexture(img)\n\t\tif err != nil {\n\t\t\tlog.Fatal(err)\n\t\t}\n\t\timgWidth, imgHeight := t.Bounds()\n\t\tallTexs[f] = sprite.SubTex{t, image.Rect(1, 1, imgWidth-1, imgHeight-1)}\n\t\ta.Close()\n\t}\n\treturn allTexs\n}", "func InvalidateTexSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32) {\n\tsyscall.Syscall9(gpInvalidateTexSubImage, 8, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), 0)\n}", "func (uni *Uniform4fv) Set(idx int, v0, v1, v2, v3 float32) {\n\n\tpos := idx * 4\n\tuni.v[pos] = v0\n\tuni.v[pos+1] = v1\n\tuni.v[pos+2] = v2\n\tuni.v[pos+3] = v3\n}", "func ActiveTexture(texture uint32) {\n C.glowActiveTexture(gpActiveTexture, (C.GLenum)(texture))\n}", "func MakeEmpty() Texture {\n\treturn Texture{0, gl.TEXTURE_2D, 0}\n}", "func (pic *Picture) Fill(contour DrawableContour) {\n\tpendiam := pic.currentPen.diameter\n\tpic.surface.AddContour(contour, pendiam, nil, pic.currentColor)\n}", "func Linear(img image.Image, value float64) image.Image {\n\treturn utils.MapColor(img, LinearC(value))\n}", "func draw(window *glfw.Window, reactProg, landProg uint32) {\n\n\tvar renderLoops = 4\n\tfor i := 0; i < renderLoops; i++ {\n\t\t// -- DRAW TO BUFFER --\n\t\t// define destination of pixels\n\t\t//gl.BindFramebuffer(gl.FRAMEBUFFER, 0)\n\t\tgl.BindFramebuffer(gl.FRAMEBUFFER, FBO[1])\n\n\t\tgl.Viewport(0, 0, width, height) // Retina display doubles the framebuffer !?!\n\n\t\tgl.Clear(gl.COLOR_BUFFER_BIT | gl.DEPTH_BUFFER_BIT)\n\t\tgl.UseProgram(reactProg)\n\n\t\t// bind Texture\n\t\tgl.ActiveTexture(gl.TEXTURE0)\n\t\tgl.BindTexture(gl.TEXTURE_2D, renderedTexture)\n\t\tgl.Uniform1i(uniTex, 0)\n\n\t\tgl.BindVertexArray(VAO)\n\t\tgl.DrawElements(gl.TRIANGLE_STRIP, int32(len(indices)), gl.UNSIGNED_INT, nil)\n\n\t\tgl.BindVertexArray(0)\n\n\t\t// -- copy back textures --\n\t\tgl.BindFramebuffer(gl.READ_FRAMEBUFFER, FBO[1]) // source is high res array\n\t\tgl.ReadBuffer(gl.COLOR_ATTACHMENT0)\n\t\tgl.BindFramebuffer(gl.DRAW_FRAMEBUFFER, FBO[0]) // destination is cells array\n\t\tgl.DrawBuffer(gl.COLOR_ATTACHMENT0)\n\t\tgl.BlitFramebuffer(0, 0, width, height,\n\t\t\t0, 0, cols, rows,\n\t\t\tgl.COLOR_BUFFER_BIT, gl.NEAREST) // downsample\n\t\tgl.BindFramebuffer(gl.READ_FRAMEBUFFER, FBO[0]) // source is low res array - put in texture\n\t\t// read pixels saves data read as unsigned bytes and then loads them in TexImage same way\n\t\tgl.ReadPixels(0, 0, cols, rows, gl.RGBA, gl.FLOAT, gl.Ptr(fData))\n\t\tgl.BindTexture(gl.TEXTURE_2D, renderedTexture)\n\t\tgl.TexImage2D(gl.TEXTURE_2D, 0, gl.RGBA, cols, rows, 0, gl.RGBA, gl.FLOAT, gl.Ptr(fData))\n\t\tCheckGLErrors()\n\t}\n\t// -- DRAW TO SCREEN --\n\tvar model glm.Mat4\n\n\t// destination 0 means screen\n\tgl.BindFramebuffer(gl.FRAMEBUFFER, 0)\n\tgl.Viewport(0, 0, width*2, height*2) // Retina display doubles the framebuffer !?!\n\tgl.Clear(gl.COLOR_BUFFER_BIT | gl.DEPTH_BUFFER_BIT)\n\tgl.UseProgram(landProg)\n\t// bind Texture\n\tgl.ActiveTexture(gl.TEXTURE0)\n\tgl.BindTexture(gl.TEXTURE_2D, drawTexture)\n\n\tvar view glm.Mat4\n\tvar brakeFactor = float64(20000.0)\n\tvar xCoord, yCoord float32\n\txCoord = float32(-3.0 * math.Sin(float64(myClock)))\n\tyCoord = float32(-3.0 * math.Cos(float64(myClock)))\n\t//xCoord = 0.0\n\t//yCoord = float32(-2.5)\n\tmyClock = math.Mod((myClock + float64(deltaTime)/brakeFactor), (math.Pi * 2))\n\tview = glm.LookAt(xCoord, yCoord, 2.0, 0.0, 0.0, 0.0, 0.0, 0.0, 1.0)\n\tgl.UniformMatrix4fv(uniView, 1, false, &view[0])\n\tmodel = glm.HomogRotate3DX(glm.DegToRad(00.0))\n\tgl.UniformMatrix4fv(uniModel, 1, false, &model[0])\n\tgl.Uniform1i(uniTex2, 0)\n\n\t// render container\n\t//gl.PolygonMode(gl.FRONT_AND_BACK, gl.FILL)\n\t//gl.PolygonMode(gl.FRONT_AND_BACK, gl.LINE)\n\n\tgl.BindVertexArray(VAO)\n\tgl.DrawElements(gl.TRIANGLE_STRIP, int32(len(indices)), gl.UNSIGNED_INT, nil)\n\tgl.BindVertexArray(0)\n\n\tCheckGLErrors()\n\n\tglfw.PollEvents()\n\twindow.SwapBuffers()\n\n\t//time.Sleep(100 * 1000 * 1000)\n}", "func ProgramUniform1fv(program uint32, location int32, count int32, value *float32) {\n C.glowProgramUniform1fv(gpProgramUniform1fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func (self *TileSprite) LoadTexture(key interface{}) {\n self.Object.Call(\"loadTexture\", key)\n}" ]
[ "0.6033916", "0.5979142", "0.59077275", "0.58477914", "0.5768154", "0.57606286", "0.57316107", "0.5637083", "0.5411705", "0.5394399", "0.53766215", "0.5368511", "0.53565407", "0.53512436", "0.53442234", "0.5289618", "0.5264422", "0.525809", "0.52554697", "0.52210635", "0.5210149", "0.52098656", "0.5208418", "0.52052516", "0.5200814", "0.51822937", "0.5181527", "0.51670724", "0.51667774", "0.51588917", "0.5158406", "0.5155656", "0.5155466", "0.51489305", "0.5130815", "0.5129831", "0.51061344", "0.5091566", "0.50884897", "0.5088135", "0.5080127", "0.5079088", "0.50480187", "0.5042762", "0.504022", "0.5037214", "0.50153166", "0.50058526", "0.4995629", "0.4995629", "0.49948588", "0.49936387", "0.4989647", "0.49809635", "0.4974841", "0.49721208", "0.4970248", "0.4969123", "0.4967944", "0.49673465", "0.49629572", "0.4959251", "0.4940137", "0.4938914", "0.49337023", "0.4932057", "0.49209562", "0.49209562", "0.49186167", "0.49148023", "0.48909366", "0.48895204", "0.48895204", "0.48829183", "0.48812622", "0.48776466", "0.4876486", "0.48639318", "0.48639318", "0.4856505", "0.48563346", "0.4851401", "0.48477036", "0.48339176", "0.48338863", "0.48338863", "0.48247448", "0.48247448", "0.4823397", "0.48146486", "0.48146486", "0.48145956", "0.48108554", "0.48089582", "0.4806487", "0.4796555", "0.4795089", "0.47935647", "0.47913858", "0.47910354", "0.47884223" ]
0.0
-1
select active texture unit
func ClientActiveTexture(texture uint32) { C.glowClientActiveTexture(gpClientActiveTexture, (C.GLenum)(texture)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func ActiveTexture(texture uint32) {\n C.glowActiveTexture(gpActiveTexture, (C.GLenum)(texture))\n}", "func ActiveTexture(texture Enum) {\n\tgl.ActiveTexture(uint32(texture))\n}", "func ActiveTexture(texture uint32) {\n\tsyscall.Syscall(gpActiveTexture, 1, uintptr(texture), 0, 0)\n}", "func (gl *WebGL) ActiveTexture(target GLEnum) {\n\tgl.context.Call(\"activeTexture\", target)\n}", "func ClientActiveTexture(texture uint32) {\n C.glowClientActiveTexture(gpClientActiveTexture, (C.GLenum)(texture))\n}", "func (native *OpenGL) ActiveTexture(texture uint32) {\n\tgl.ActiveTexture(texture)\n}", "func ActiveTexture(texture uint32) {\n\tC.glowActiveTexture(gpActiveTexture, (C.GLenum)(texture))\n}", "func ActiveTexture(texture uint32) {\n\tC.glowActiveTexture(gpActiveTexture, (C.GLenum)(texture))\n}", "func SetActiveTexture(texture Enum) {\n\tctexture, _ := (C.GLenum)(texture), cgoAllocsUnknown\n\tC.glActiveTexture(ctexture)\n}", "func (debugging *debuggingOpenGL) ActiveTexture(texture uint32) {\n\tdebugging.recordEntry(\"ActiveTexture\", texture)\n\tdebugging.gl.ActiveTexture(texture)\n\tdebugging.recordExit(\"ActiveTexture\")\n}", "func (bm Blendmap) Texture() *gl.Texture {\n\treturn bm.Map.id\n}", "func ClientActiveTexture(texture uint32) {\n\tsyscall.Syscall(gpClientActiveTexture, 1, uintptr(texture), 0, 0)\n}", "func GetActiveUniform(program uint32, index uint32, bufSize int32, length *int32, size *int32, xtype *uint32, name *int8) {\n C.glowGetActiveUniform(gpGetActiveUniform, (C.GLuint)(program), (C.GLuint)(index), (C.GLsizei)(bufSize), (*C.GLsizei)(unsafe.Pointer(length)), (*C.GLint)(unsafe.Pointer(size)), (*C.GLenum)(unsafe.Pointer(xtype)), (*C.GLchar)(unsafe.Pointer(name)))\n}", "func (self *TileSprite) SetTexture1O(texture *Texture, destroy bool) {\n self.Object.Call(\"setTexture\", texture, destroy)\n}", "func BindTextureUnit(unit uint32, texture uint32) {\n\tC.glowBindTextureUnit(gpBindTextureUnit, (C.GLuint)(unit), (C.GLuint)(texture))\n}", "func BindTextureUnit(unit uint32, texture uint32) {\n\tC.glowBindTextureUnit(gpBindTextureUnit, (C.GLuint)(unit), (C.GLuint)(texture))\n}", "func BindTextureUnit(unit uint32, texture uint32) {\n\tsyscall.Syscall(gpBindTextureUnit, 2, uintptr(unit), uintptr(texture), 0)\n}", "func (self *TileSprite) TilingTexture() *PIXITexture{\n return &PIXITexture{self.Object.Get(\"tilingTexture\")}\n}", "func GetActiveUniform(program uint32, index uint32, bufSize int32, length *int32, size *int32, xtype *uint32, name *uint8) {\n\tC.glowGetActiveUniform(gpGetActiveUniform, (C.GLuint)(program), (C.GLuint)(index), (C.GLsizei)(bufSize), (*C.GLsizei)(unsafe.Pointer(length)), (*C.GLint)(unsafe.Pointer(size)), (*C.GLenum)(unsafe.Pointer(xtype)), (*C.GLchar)(unsafe.Pointer(name)))\n}", "func GetActiveUniform(program uint32, index uint32, bufSize int32, length *int32, size *int32, xtype *uint32, name *uint8) {\n\tC.glowGetActiveUniform(gpGetActiveUniform, (C.GLuint)(program), (C.GLuint)(index), (C.GLsizei)(bufSize), (*C.GLsizei)(unsafe.Pointer(length)), (*C.GLint)(unsafe.Pointer(size)), (*C.GLenum)(unsafe.Pointer(xtype)), (*C.GLchar)(unsafe.Pointer(name)))\n}", "func (self *TileSprite) SetTextureA(member *Texture) {\n self.Object.Set(\"texture\", member)\n}", "func (self *TileSprite) TintedTexture() *Canvas{\n return &Canvas{self.Object.Get(\"tintedTexture\")}\n}", "func TextureView(texture uint32, target uint32, origtexture uint32, internalformat uint32, minlevel uint32, numlevels uint32, minlayer uint32, numlayers uint32) {\n C.glowTextureView(gpTextureView, (C.GLuint)(texture), (C.GLenum)(target), (C.GLuint)(origtexture), (C.GLenum)(internalformat), (C.GLuint)(minlevel), (C.GLuint)(numlevels), (C.GLuint)(minlayer), (C.GLuint)(numlayers))\n}", "func (t *Three) Texture() *Texture {\n\tp := t.ctx.Get(\"Texture\")\n\treturn TextureFromJSObject(p)\n}", "func (self *TileSprite) SetTilingTextureA(member *PIXITexture) {\n self.Object.Set(\"tilingTexture\", member)\n}", "func (self *TileSprite) Texture() *Texture{\n return &Texture{self.Object.Get(\"texture\")}\n}", "func (self *GameObjectCreator) RenderTexture1O(width int) *RenderTexture{\n return &RenderTexture{self.Object.Call(\"renderTexture\", width)}\n}", "func (self *Graphics) GenerateTexture1O(resolution int) *Texture{\n return &Texture{self.Object.Call(\"generateTexture\", resolution)}\n}", "func (md MetalDrawable) Texture() mtl.Texture {\n\treturn mtl.NewTexture(C.MetalDrawable_Texture(md.metalDrawable))\n}", "func (tx *TextureBase) Activate(sc *Scene, texNo int) {\n\tif tx.Tex != nil {\n\t\ttx.Tex.SetBotZero(tx.Bot0)\n\t\ttx.Tex.Activate(texNo)\n\t}\n}", "func (self *TileSprite) SetTexture(texture *Texture) {\n self.Object.Call(\"setTexture\", texture)\n}", "func (self *TileSprite) SetTintedTextureA(member *Canvas) {\n self.Object.Set(\"tintedTexture\", member)\n}", "func (self *TileSprite) LoadTexture1O(key interface{}, frame interface{}) {\n self.Object.Call(\"loadTexture\", key, frame)\n}", "func (f *Font) GetTexture() *Texture { return f.texture }", "func GetActiveUniform(program uint32, index uint32, bufSize int32, length *int32, size *int32, xtype *uint32, name *uint8) {\n\tsyscall.Syscall9(gpGetActiveUniform, 7, uintptr(program), uintptr(index), uintptr(bufSize), uintptr(unsafe.Pointer(length)), uintptr(unsafe.Pointer(size)), uintptr(unsafe.Pointer(xtype)), uintptr(unsafe.Pointer(name)), 0, 0)\n}", "func GetActiveUniform(program Uint, index Uint, bufSize Sizei, length *Sizei, size *Int, kind *Enum, name []byte) {\n\tcprogram, _ := (C.GLuint)(program), cgoAllocsUnknown\n\tcindex, _ := (C.GLuint)(index), cgoAllocsUnknown\n\tcbufSize, _ := (C.GLsizei)(bufSize), cgoAllocsUnknown\n\tclength, _ := (*C.GLsizei)(unsafe.Pointer(length)), cgoAllocsUnknown\n\tcsize, _ := (*C.GLint)(unsafe.Pointer(size)), cgoAllocsUnknown\n\tckind, _ := (*C.GLenum)(unsafe.Pointer(kind)), cgoAllocsUnknown\n\tcname, _ := (*C.GLchar)(unsafe.Pointer((*sliceHeader)(unsafe.Pointer(&name)).Data)), cgoAllocsUnknown\n\tC.glGetActiveUniform(cprogram, cindex, cbufSize, clength, csize, ckind, cname)\n}", "func (c *Canvas) Texture() *glhf.Texture {\n\treturn c.gf.Texture()\n}", "func GetActiveUniformName(program uint32, uniformIndex uint32, bufSize int32, length *int32, uniformName *int8) {\n C.glowGetActiveUniformName(gpGetActiveUniformName, (C.GLuint)(program), (C.GLuint)(uniformIndex), (C.GLsizei)(bufSize), (*C.GLsizei)(unsafe.Pointer(length)), (*C.GLchar)(unsafe.Pointer(uniformName)))\n}", "func GetActiveUniformsiv(program uint32, uniformCount int32, uniformIndices *uint32, pname uint32, params *int32) {\n C.glowGetActiveUniformsiv(gpGetActiveUniformsiv, (C.GLuint)(program), (C.GLsizei)(uniformCount), (*C.GLuint)(unsafe.Pointer(uniformIndices)), (C.GLenum)(pname), (*C.GLint)(unsafe.Pointer(params)))\n}", "func GetTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, bufSize int32, pixels unsafe.Pointer) {\n\tsyscall.Syscall12(gpGetTextureSubImage, 12, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(xtype), uintptr(bufSize), uintptr(pixels))\n}", "func GetActiveUniformBlockName(program uint32, uniformBlockIndex uint32, bufSize int32, length *int32, uniformBlockName *int8) {\n C.glowGetActiveUniformBlockName(gpGetActiveUniformBlockName, (C.GLuint)(program), (C.GLuint)(uniformBlockIndex), (C.GLsizei)(bufSize), (*C.GLsizei)(unsafe.Pointer(length)), (*C.GLchar)(unsafe.Pointer(uniformBlockName)))\n}", "func (self *GameObjectCreator) RenderTexture3O(width int, height int, key string) *RenderTexture{\n return &RenderTexture{self.Object.Call(\"renderTexture\", width, height, key)}\n}", "func BindTexture(target Enum, t Texture) {\n\tgl.BindTexture(uint32(target), t.Value)\n}", "func (tx *TextureFile) Activate(sc *Scene, texNo int) {\n\tif tx.Tex == nil {\n\t\ttx.Init(sc)\n\t}\n\ttx.Tex.SetBotZero(tx.Bot0)\n\ttx.Tex.Activate(texNo)\n}", "func TextureView(texture uint32, target uint32, origtexture uint32, internalformat uint32, minlevel uint32, numlevels uint32, minlayer uint32, numlayers uint32) {\n\tsyscall.Syscall9(gpTextureView, 8, uintptr(texture), uintptr(target), uintptr(origtexture), uintptr(internalformat), uintptr(minlevel), uintptr(numlevels), uintptr(minlayer), uintptr(numlayers), 0)\n}", "func (fnt *Font) Texture() *Texture {\n\treturn fnt.texture\n}", "func GetTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetTextureSubImage(gpGetTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), (C.GLsizei)(bufSize), pixels)\n}", "func GetTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetTextureSubImage(gpGetTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), (C.GLsizei)(bufSize), pixels)\n}", "func GetActiveUniformBlockiv(program uint32, uniformBlockIndex uint32, pname uint32, params *int32) {\n\tC.glowGetActiveUniformBlockiv(gpGetActiveUniformBlockiv, (C.GLuint)(program), (C.GLuint)(uniformBlockIndex), (C.GLenum)(pname), (*C.GLint)(unsafe.Pointer(params)))\n}", "func GetActiveUniformBlockiv(program uint32, uniformBlockIndex uint32, pname uint32, params *int32) {\n\tC.glowGetActiveUniformBlockiv(gpGetActiveUniformBlockiv, (C.GLuint)(program), (C.GLuint)(uniformBlockIndex), (C.GLenum)(pname), (*C.GLint)(unsafe.Pointer(params)))\n}", "func BindImageTexture(unit uint32, texture uint32, level int32, layered bool, layer int32, access uint32, format uint32) {\n C.glowBindImageTexture(gpBindImageTexture, (C.GLuint)(unit), (C.GLuint)(texture), (C.GLint)(level), (C.GLboolean)(boolToInt(layered)), (C.GLint)(layer), (C.GLenum)(access), (C.GLenum)(format))\n}", "func (self *Graphics) GenerateTexture3O(resolution int, scaleMode int, padding int) *Texture{\n return &Texture{self.Object.Call(\"generateTexture\", resolution, scaleMode, padding)}\n}", "func (self *TileSprite) LoadTexture(key interface{}) {\n self.Object.Call(\"loadTexture\", key)\n}", "func (self *Graphics) GenerateTexture() *Texture{\n return &Texture{self.Object.Call(\"generateTexture\")}\n}", "func TexStorage2D(target uint32, levels int32, internalformat uint32, width int32, height int32) {\n C.glowTexStorage2D(gpTexStorage2D, (C.GLenum)(target), (C.GLsizei)(levels), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func IsTexture(texture uint32) bool {\n ret := C.glowIsTexture(gpIsTexture, (C.GLuint)(texture))\n return ret == TRUE\n}", "func (self *TileSprite) BlendMode() int{\n return self.Object.Get(\"blendMode\").Int()\n}", "func (am *Manager) GetTexture(name string) (*Texture, bool) {\n\tif tex, ok := am.Textures[name]; ok {\n\t\treturn tex, ok\n\t}\n\n\tif am.Parent != nil {\n\t\treturn am.Parent.GetTexture(name)\n\t}\n\n\treturn nil, false\n}", "func GetActiveUniformName(program uint32, uniformIndex uint32, bufSize int32, length *int32, uniformName *uint8) {\n\tC.glowGetActiveUniformName(gpGetActiveUniformName, (C.GLuint)(program), (C.GLuint)(uniformIndex), (C.GLsizei)(bufSize), (*C.GLsizei)(unsafe.Pointer(length)), (*C.GLchar)(unsafe.Pointer(uniformName)))\n}", "func GetActiveUniformName(program uint32, uniformIndex uint32, bufSize int32, length *int32, uniformName *uint8) {\n\tC.glowGetActiveUniformName(gpGetActiveUniformName, (C.GLuint)(program), (C.GLuint)(uniformIndex), (C.GLsizei)(bufSize), (*C.GLsizei)(unsafe.Pointer(length)), (*C.GLchar)(unsafe.Pointer(uniformName)))\n}", "func GetActiveUniformBlockName(program uint32, uniformBlockIndex uint32, bufSize int32, length *int32, uniformBlockName *uint8) {\n\tC.glowGetActiveUniformBlockName(gpGetActiveUniformBlockName, (C.GLuint)(program), (C.GLuint)(uniformBlockIndex), (C.GLsizei)(bufSize), (*C.GLsizei)(unsafe.Pointer(length)), (*C.GLchar)(unsafe.Pointer(uniformBlockName)))\n}", "func GetActiveUniformBlockName(program uint32, uniformBlockIndex uint32, bufSize int32, length *int32, uniformBlockName *uint8) {\n\tC.glowGetActiveUniformBlockName(gpGetActiveUniformBlockName, (C.GLuint)(program), (C.GLuint)(uniformBlockIndex), (C.GLsizei)(bufSize), (*C.GLsizei)(unsafe.Pointer(length)), (*C.GLchar)(unsafe.Pointer(uniformBlockName)))\n}", "func (obj *Device) GetTexture(stage uint32) (*BaseTexture, Error) {\n\tvar tex *BaseTexture\n\tret, _, _ := syscall.Syscall(\n\t\tobj.vtbl.GetTexture,\n\t\t3,\n\t\tuintptr(unsafe.Pointer(obj)),\n\t\tuintptr(stage),\n\t\tuintptr(unsafe.Pointer(&tex)),\n\t)\n\treturn tex, toErr(ret)\n}", "func GetActiveAttrib(program uint32, index uint32, bufSize int32, length *int32, size *int32, xtype *uint32, name *int8) {\n C.glowGetActiveAttrib(gpGetActiveAttrib, (C.GLuint)(program), (C.GLuint)(index), (C.GLsizei)(bufSize), (*C.GLsizei)(unsafe.Pointer(length)), (*C.GLint)(unsafe.Pointer(size)), (*C.GLenum)(unsafe.Pointer(xtype)), (*C.GLchar)(unsafe.Pointer(name)))\n}", "func FramebufferTexture(target uint32, attachment uint32, texture uint32, level int32) {\n C.glowFramebufferTexture(gpFramebufferTexture, (C.GLenum)(target), (C.GLenum)(attachment), (C.GLuint)(texture), (C.GLint)(level))\n}", "func TexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexSubImage1D(gpTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexSubImage3D(gpTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func GetActiveUniformsiv(program uint32, uniformCount int32, uniformIndices *uint32, pname uint32, params *int32) {\n\tC.glowGetActiveUniformsiv(gpGetActiveUniformsiv, (C.GLuint)(program), (C.GLsizei)(uniformCount), (*C.GLuint)(unsafe.Pointer(uniformIndices)), (C.GLenum)(pname), (*C.GLint)(unsafe.Pointer(params)))\n}", "func GetActiveUniformsiv(program uint32, uniformCount int32, uniformIndices *uint32, pname uint32, params *int32) {\n\tC.glowGetActiveUniformsiv(gpGetActiveUniformsiv, (C.GLuint)(program), (C.GLsizei)(uniformCount), (*C.GLuint)(unsafe.Pointer(uniformIndices)), (C.GLenum)(pname), (*C.GLint)(unsafe.Pointer(params)))\n}", "func ActiveShaderProgram(pipeline uint32, program uint32) {\n C.glowActiveShaderProgram(gpActiveShaderProgram, (C.GLuint)(pipeline), (C.GLuint)(program))\n}", "func TextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTextureSubImage1D, 7, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(width), uintptr(format), uintptr(xtype), uintptr(pixels), 0, 0)\n}", "func (self *TileSprite) LoadTexture2O(key interface{}, frame interface{}, stopAnimation bool) {\n self.Object.Call(\"loadTexture\", key, frame, stopAnimation)\n}", "func TextureView(texture uint32, target uint32, origtexture uint32, internalformat uint32, minlevel uint32, numlevels uint32, minlayer uint32, numlayers uint32) {\n\tC.glowTextureView(gpTextureView, (C.GLuint)(texture), (C.GLenum)(target), (C.GLuint)(origtexture), (C.GLenum)(internalformat), (C.GLuint)(minlevel), (C.GLuint)(numlevels), (C.GLuint)(minlayer), (C.GLuint)(numlayers))\n}", "func TextureView(texture uint32, target uint32, origtexture uint32, internalformat uint32, minlevel uint32, numlevels uint32, minlayer uint32, numlayers uint32) {\n\tC.glowTextureView(gpTextureView, (C.GLuint)(texture), (C.GLenum)(target), (C.GLuint)(origtexture), (C.GLenum)(internalformat), (C.GLuint)(minlevel), (C.GLuint)(numlevels), (C.GLuint)(minlayer), (C.GLuint)(numlayers))\n}", "func (self *GameObjectCreator) RenderTexture2O(width int, height int) *RenderTexture{\n return &RenderTexture{self.Object.Call(\"renderTexture\", width, height)}\n}", "func (self *GameObjectCreator) RenderTexture4O(width int, height int, key string, addToCache bool) *RenderTexture{\n return &RenderTexture{self.Object.Call(\"renderTexture\", width, height, key, addToCache)}\n}", "func GetActiveUniform(p Program, index uint32) (name string, size int, ty Enum) {\n\tvar length, si int32\n\tvar typ uint32\n\tname = strings.Repeat(\"\\x00\", 256)\n\tcname := gl.Str(name)\n\tgl.GetActiveUniform(p.Value, uint32(index), int32(len(name)-1), &length, &si, &typ, cname)\n\tname = name[:strings.IndexRune(name, 0)]\n\treturn name, int(si), Enum(typ)\n}", "func (obj *Device) GetCurrentTexturePalette() (paletteNumber uint, err Error) {\n\tret, _, _ := syscall.Syscall(\n\t\tobj.vtbl.GetCurrentTexturePalette,\n\t\t2,\n\t\tuintptr(unsafe.Pointer(obj)),\n\t\tuintptr(unsafe.Pointer(&paletteNumber)),\n\t\t0,\n\t)\n\terr = toErr(ret)\n\treturn\n}", "func BindTexture(target Enum, texture Uint) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tctexture, _ := (C.GLuint)(texture), cgoAllocsUnknown\n\tC.glBindTexture(ctarget, ctexture)\n}", "func (self *GameObjectCreator) RenderTexture() *RenderTexture{\n return &RenderTexture{self.Object.Call(\"renderTexture\")}\n}", "func (tex Texture) Sub(ctx gl.Context, lvl int, width int, height int, data []byte) {\n\tctx.TexSubImage2D(gl.TEXTURE_2D, lvl, 0, 0, width, height, gl.RGBA, gl.UNSIGNED_BYTE, data)\n\tif lvl > 0 {\n\t\tctx.GenerateMipmap(gl.TEXTURE_2D)\n\t}\n}", "func GetActiveUniformBlockiv(program uint32, uniformBlockIndex uint32, pname uint32, params *int32) {\n\tsyscall.Syscall6(gpGetActiveUniformBlockiv, 4, uintptr(program), uintptr(uniformBlockIndex), uintptr(pname), uintptr(unsafe.Pointer(params)), 0, 0)\n}", "func TexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexSubImage2D(gpTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func GetActiveUniformsiv(program uint32, uniformCount int32, uniformIndices *uint32, pname uint32, params *int32) {\n\tsyscall.Syscall6(gpGetActiveUniformsiv, 5, uintptr(program), uintptr(uniformCount), uintptr(unsafe.Pointer(uniformIndices)), uintptr(pname), uintptr(unsafe.Pointer(params)), 0)\n}", "func EGLImageTargetTextureStorageEXT(texture uint32, image unsafe.Pointer, attrib_list *int32) {\n\tsyscall.Syscall(gpEGLImageTargetTextureStorageEXT, 3, uintptr(texture), uintptr(image), uintptr(unsafe.Pointer(attrib_list)))\n}", "func (gstr *GlyphString) GetTexture() *Texture { return gstr.font.GetTexture() }", "func (self *Graphics) GenerateTexture2O(resolution int, scaleMode int) *Texture{\n return &Texture{self.Object.Call(\"generateTexture\", resolution, scaleMode)}\n}", "func TexBufferRange(target uint32, internalformat uint32, buffer uint32, offset int, size int) {\n C.glowTexBufferRange(gpTexBufferRange, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLuint)(buffer), (C.GLintptr)(offset), (C.GLsizeiptr)(size))\n}", "func TexStorage1D(target uint32, levels int32, internalformat uint32, width int32) {\n C.glowTexStorage1D(gpTexStorage1D, (C.GLenum)(target), (C.GLsizei)(levels), (C.GLenum)(internalformat), (C.GLsizei)(width))\n}", "func (self *TileSprite) SetTextureDebugA(member bool) {\n self.Object.Set(\"textureDebug\", member)\n}", "func (spriteBatch *SpriteBatch) SetTexture(newtexture ITexture) {\n\tspriteBatch.texture = newtexture\n}", "func (obj *Device) SetTexture(sampler uint32, texture BaseTextureImpl) Error {\n\tvar base uintptr\n\tif texture != nil {\n\t\tbase = texture.baseTexturePointer()\n\t}\n\tret, _, _ := syscall.Syscall(\n\t\tobj.vtbl.SetTexture,\n\t\t3,\n\t\tuintptr(unsafe.Pointer(obj)),\n\t\tuintptr(sampler),\n\t\tbase,\n\t)\n\treturn toErr(ret)\n}", "func (self *TileSprite) SetRefreshTextureA(member bool) {\n self.Object.Set(\"refreshTexture\", member)\n}", "func (this *RectangleShape) GetTexture() *Texture {\n\treturn this.texture\n}", "func BindTexture(target uint32, texture uint32) {\n C.glowBindTexture(gpBindTexture, (C.GLenum)(target), (C.GLuint)(texture))\n}", "func Make(width, height int, internalformat int32, format, pixelType uint32,\n\tdata unsafe.Pointer, min, mag, s, t int32) Texture {\n\n\ttexture := Texture{0, gl.TEXTURE_2D, 0}\n\n\t// generate and bind texture\n\tgl.GenTextures(1, &texture.handle)\n\ttexture.Bind(0)\n\n\t// set texture properties\n\tgl.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, min)\n\tgl.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, mag)\n\tgl.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_S, s)\n\tgl.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_T, t)\n\n\t// specify a texture image\n\tgl.TexImage2D(gl.TEXTURE_2D, 0, internalformat, int32(width), int32(height),\n\t\t0, format, pixelType, data)\n\n\t// unbind texture\n\ttexture.Unbind()\n\n\treturn texture\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage3D(gpTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage3D(gpTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func (self *TileSprite) SetTextureI(args ...interface{}) {\n self.Object.Call(\"setTexture\", args)\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexImage2D(gpTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}" ]
[ "0.6990008", "0.6661706", "0.66074866", "0.65897524", "0.6373429", "0.62392634", "0.62287843", "0.62287843", "0.6157311", "0.6041385", "0.5987386", "0.5792542", "0.57850623", "0.57787174", "0.5760657", "0.5760657", "0.56287324", "0.5581819", "0.5571051", "0.5571051", "0.55343205", "0.5533581", "0.55307955", "0.55149984", "0.54577416", "0.5420691", "0.54166234", "0.54111207", "0.53856814", "0.53617424", "0.5310755", "0.53080904", "0.5302808", "0.527681", "0.5254511", "0.52530897", "0.5237286", "0.5219553", "0.51983416", "0.51954335", "0.51877534", "0.518254", "0.51776826", "0.5173706", "0.5173239", "0.5143349", "0.5138034", "0.5138034", "0.5137577", "0.5137577", "0.51077557", "0.5087507", "0.50765115", "0.50557774", "0.5034768", "0.50326663", "0.50257176", "0.502086", "0.5011349", "0.5011349", "0.49847806", "0.49847806", "0.49763274", "0.4971726", "0.49689424", "0.49667034", "0.49663737", "0.49662846", "0.49662846", "0.4954679", "0.4946543", "0.4942423", "0.49338806", "0.49338806", "0.49214026", "0.4919405", "0.49188524", "0.49187338", "0.49167424", "0.49127075", "0.49078625", "0.490764", "0.48963618", "0.48884535", "0.48695686", "0.48683763", "0.48627985", "0.4852556", "0.48492885", "0.4848795", "0.48460007", "0.48433644", "0.48158276", "0.48094735", "0.48079482", "0.47981542", "0.47881767", "0.47881767", "0.47864822", "0.47777602" ]
0.5475351
24
block and wait for a sync object to become signaled
func ClientWaitSync(sync uintptr, flags uint32, timeout uint64) uint32 { ret := C.glowClientWaitSync(gpClientWaitSync, (C.GLsync)(sync), (C.GLbitfield)(flags), (C.GLuint64)(timeout)) return (uint32)(ret) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func (t *SyncTransport) Wait() {}", "func WaitSync(sync uintptr, flags uint32, timeout uint64) {\n\tsyscall.Syscall(gpWaitSync, 3, uintptr(sync), uintptr(flags), uintptr(timeout))\n}", "func (bus *EventBus) WaitAsync() {\n\tbus.wg.Wait()\n}", "func (bus *EventBus) WaitAsync() {\n\tbus.wg.Wait()\n}", "func WaitSync(sync unsafe.Pointer, flags uint32, timeout uint64) {\n C.glowWaitSync(gpWaitSync, (C.GLsync)(sync), (C.GLbitfield)(flags), (C.GLuint64)(timeout))\n}", "func (async *async) wait() {\n\t<-async.done\n}", "func (chanSync *channelRelaySync) WaitOnSetup() {\n\tdefer chanSync.shared.setupComplete.Wait()\n}", "func (a *Async) Wait() {\n\ta.waiting = true\n\t<-a.done\n}", "func WaitSync(sync uintptr, flags uint32, timeout uint64) {\n\tC.glowWaitSync(gpWaitSync, (C.GLsync)(sync), (C.GLbitfield)(flags), (C.GLuint64)(timeout))\n}", "func WaitSync(sync uintptr, flags uint32, timeout uint64) {\n\tC.glowWaitSync(gpWaitSync, (C.GLsync)(sync), (C.GLbitfield)(flags), (C.GLuint64)(timeout))\n}", "func (s *SplitStore) waitForSync() {\n\tif atomic.LoadInt32(&s.outOfSync) == 0 {\n\t\treturn\n\t}\n\ts.chainSyncMx.Lock()\n\tdefer s.chainSyncMx.Unlock()\n\n\tfor !s.chainSyncFinished {\n\t\ts.chainSyncCond.Wait()\n\t}\n}", "func (e *AutoResetEvent) Wait() {\n\t<-e.c\n}", "func (w *waiterOnce) wait() error {\n\tif w == nil {\n\t\treturn nil\n\t}\n\n\tif w.isReady() {\n\t\t// println(\"waiter: wait() is Ready\")\n\t\treturn w.err // no need to wait.\n\t}\n\n\tif atomic.CompareAndSwapUint32(w.locked, 0, 1) {\n\t\t// println(\"waiter: lock\")\n\t\t<-w.ch\n\t}\n\n\treturn w.err\n}", "func WaitForSyncComplete(ctx context.Context, napi api.FullNode) error {\n\tfor {\n\t\tselect {\n\t\tcase <-ctx.Done():\n\t\t\treturn ctx.Err()\n\t\tcase <-time.After(3 * time.Second):\n\t\t\thead, err := napi.ChainHead(ctx)\n\t\t\tif err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\n\t\t\tif time.Now().Unix()-int64(head.MinTimestamp()) < build.BlockDelay {\n\t\t\t\treturn nil\n\t\t\t}\n\t\t}\n\t}\n}", "func WaitForNotify() {\n\tcount++\n\t<-done\n}", "func (s *testSignaler) wait() bool {\n\tselect {\n\tcase s := <-s.nonBlockingStatus:\n\t\treturn s\n\tcase s := <-s.status:\n\t\treturn s\n\t}\n}", "func ClientWaitSync(sync unsafe.Pointer, flags uint32, timeout uint64) uint32 {\n ret := C.glowClientWaitSync(gpClientWaitSync, (C.GLsync)(sync), (C.GLbitfield)(flags), (C.GLuint64)(timeout))\n return (uint32)(ret)\n}", "func (c *Eventer) sync() {\n\tc.syncc <- struct{}{}\n\t<-c.syncDonec\n}", "func (c *Concurrent) Wait() {\n\tc.semaphore.Wait()\n}", "func (tx *Tx) wait() {\n\tglobalCond.L.Lock()\n\tfor tx.verify() {\n\t\tglobalCond.Wait()\n\t}\n\tglobalCond.L.Unlock()\n}", "func (transport *Transport) Wait() {\n\ttransport.lock.Lock()\n\ttransport.lock.Unlock()\n}", "func waitForPromise() {\n\tfor {\n\t\t<-waitPromisChan\n\t\twaiting = true\n\t\ttime.Sleep(2 * time.Second)\n\t\twaiting = false\n\t\tcheckPromises()\n\t}\n}", "func (d *LoopVars) askForSync() {\n\td.ensureInit()\n\tselect {\n\tcase d.syncSoon <- struct{}{}:\n\tdefault:\n\t}\n}", "func (lc *Closer) SignalAndWait() {\n\tlc.Signal()\n\tlc.Wait()\n}", "func (g *Group) Wait() error", "func ClientWaitSync(sync uintptr, flags uint32, timeout uint64) uint32 {\n\tret, _, _ := syscall.Syscall(gpClientWaitSync, 3, uintptr(sync), uintptr(flags), uintptr(timeout))\n\treturn (uint32)(ret)\n}", "func (l *CommandQueueStatusListener) Wait() {\n\t<-l.signal\n}", "func (p *Init) Wait() {\n\t<-p.waitBlock\n}", "func (m *MountCompletedWatcher) Wait(ctx context.Context) (MountCompleted, error) {\n\tvar ret MountCompleted\n\tselect {\n\tcase s := <-m.Signals:\n\t\tif err := dbus.Store(s.Body, &ret.Status, &ret.SourcePath, &ret.SourceType, &ret.MountPath, &ret.ReadOnly); err != nil {\n\t\t\treturn ret, errors.Wrap(err, \"failed to store MountCompleted data\")\n\t\t}\n\t\treturn ret, nil\n\tcase <-ctx.Done():\n\t\treturn ret, errors.Wrap(ctx.Err(), \"didn't get MountCompleted signal\")\n\t}\n}", "func wait() {\n\twaitImpl()\n}", "func (s *Stream) notifyWaiting() {\n\tasyncNotify(s.recvNotifyCh)\n\tasyncNotify(s.sendNotifyCh)\n\tasyncNotify(s.establishCh)\n}", "func (ks *Kind) WaitForSync(ctx context.Context) error {\n\tselect {\n\tcase err := <-ks.started:\n\t\treturn err\n\tcase <-ctx.Done():\n\t\tks.startCancel()\n\t\tif errors.Is(ctx.Err(), context.Canceled) {\n\t\t\treturn nil\n\t\t}\n\t\treturn errors.New(\"timed out waiting for cache to be synced\")\n\t}\n}", "func (lc *Closer) Wait() {\n\tlc.waiting.Wait()\n}", "func (c *Condition) Wait() {\n\tc.mu.Lock()\n\tfor !c.set {\n\t\tif c.cond == nil {\n\t\t\tc.cond = sync.NewCond(&c.mu)\n\t\t}\n\t\tc.cond.Wait()\n\t}\n\tc.mu.Unlock()\n}", "func (c Mutex) Await() <-chan struct{} {\n\treturn c.ch\n}", "func (m *DeviceOperationCompletionWatcher) Wait(ctx context.Context) (DeviceOperationCompleted, error) {\n\tvar ret DeviceOperationCompleted\n\tselect {\n\tcase s := <-m.Signals:\n\t\tif err := dbus.Store(s.Body, &ret.Status, &ret.Device); err != nil {\n\t\t\treturn ret, errors.Wrap(err, \"failed to store DeviceOperationCompleted data\")\n\t\t}\n\t\treturn ret, nil\n\tcase <-ctx.Done():\n\t\treturn ret, errors.Wrap(ctx.Err(), \"didn't get DeviceOperationCompleted signal\")\n\t}\n}", "func (c *NetClient) Wait() {\n\t<-c.haltedCh\n}", "func (eq *EventQueue) Wait() {\n\teq.closingWaitGroup.Wait()\n}", "func (c *C) Wait() {\n\tc.wg.Wait()\n}", "func (chanSync *channelRelaySync) WaitOnLegComplete() {\n\tdefer chanSync.shared.legComplete.Wait()\n}", "func Wait() {\n\t<-wait\n}", "func (w *Watcher) Wait() {\n\tw.wg.Wait()\n}", "func (c *lockBased) Wait(ctx context.Context) error {\n\tc.mux.RLock()\n\tdefer c.mux.RUnlock()\n\treturn ctx.Err()\n}", "func (g *Group) WaitTillReady() {\n\t<-g.readyCh\n}", "func (g *guard) Wait() {\n\tg.cond.L.Lock()\n\tfor !g.done {\n\t\tg.cond.Wait()\n\t}\n\tg.cond.L.Unlock()\n}", "func (s *Serv) Wait() {\n\t<-s.done\n}", "func (s *InvokeSync) Wait(ctx context.Context) error {\n\tif !s.wait.Wait(ctx) {\n\t\treturn task.StopReason(ctx)\n\t}\n\treturn s.err\n}", "func Synchronising() {\n\tdone := make(chan bool, 1)\n\n\tgo worker(done)\n\n\t<-done\n}", "func (p *EventReplay) Wait() {}", "func (c *Client) WaitFor(o client.Object, condition Condition) (err error) {\n\tw, err := c.WatchObject(o)\n\tif err != nil {\n\t\treturn err\n\t}\n\tdefer w.Stop()\n\tmsg := fmt.Sprintf(\"WaitFor(%v)\", funcName(condition))\n\treturn c.waitFor(o, condition, w, msg)\n}", "func (w *LimitedConcurrencySingleFlight) Wait() {\n\tw.inflightCalls.Wait()\n}", "func (aio *AsyncIO) waitAll() {\n\taio.trigger <- struct{}{}\n\t<-aio.trigger\n}", "func (a *Application) Wait() {\n\t<-a.terminated\n}", "func (t *Terminal) Wait() {\n\tfor <-t.stopChan {\n\t\treturn\n\t}\n}", "func (m *HeavySyncMock) Wait(timeout time.Duration) {\n\tm.MinimockWait(timeout)\n}", "func (m *Music) Wait() {\n\t<-m.played\n}", "func (p *Probe) wait() {\n\tp.waitGroup.Wait()\n}", "func (c *Cond) Wait() {\n\t<-c.C\n}", "func (_m *MockWaiter) Wait() {\n\t_m.Called()\n}", "func (e *WindowsEvent) Wait() {\n\te.WaitTimeout(-1)\n}", "func (server *Server) Wait(){\n\tfor{\n\t\tif server.threads > 0 {\n\t\t\tserver.Logger.Info(server.threads, \"active channels at the moment. Waiting for busy goroutine.\")\n\t\t\t<-server.ThreadSync\n\t\t} else {\n\t\t\tbreak\n\t\t}\n\t}\n}", "func (self *Conn) Wait() error {\n\tif self.mainloop != nil {\n\t\tC.pa_threaded_mainloop_wait(self.mainloop)\n\t} else {\n\t\treturn fmt.Errorf(\"Cannot operate on undefined PulseAudio mainloop\")\n\t}\n\n\treturn nil\n}", "func (s *Server) Wait() {\n\t<-s.stopChan\n}", "func (s *Server) Wait() {\n\t<-s.stopChan\n}", "func (p *ParallelManager) wait() {\n\tp.wg.Wait()\n\tclose(p.stopMonitorCh)\n}", "func (self *ShadowRedisSlave) wait() {\n\tsigChan := make(chan os.Signal, 1)\n\tsignal.Notify(sigChan, os.Interrupt, os.Kill)\n\n\t// Block until a signal is received.\n\ts := <-sigChan\n\tlog.Debugf(\"Got signal:%v\", s)\n\tself.Close()\n}", "func (s *countingSemaphore) Wait() {\n\t<-s.sem\n}", "func (wal *BaseWAL) Wait() {\n\twal.group.Wait()\n}", "func (g *FuncGroup) Wait() { (*sync.WaitGroup)(unsafe.Pointer(g)).Wait() }", "func (relaySync *relaySync) WaitForInit(ctx context.Context) error {\n\tselect {\n\tcase <-relaySync.firstSetupWait:\n\tcase <-ctx.Done():\n\t\treturn streadway.ErrClosed\n\t}\n\n\treturn nil\n}", "func Wait() {\n\tselect {}\n}", "func (d *Dispatcher) Wait() {\n\td.wg.Wait()\n}", "func (c *Client) wait() {\n\tc.logger.Debug(\"starting gateway connection manager\")\n\tdefer c.logger.Debug(\"stopped gateway connection manager\")\n\n\tvar err error\n\tselect {\n\t// An unexpected error occurred while communicating with the Gateway.\n\tcase err = <-c.error:\n\t\tc.onGatewayError(err)\n\n\t// User called Client.Disconnect.\n\tcase <-c.stop:\n\t\tc.logger.Debug(\"disconnecting from the gateway\")\n\t\tc.onDisconnect()\n\t}\n\n\tclose(c.voicePayloads)\n\n\tc.cancel()\n\tc.connected.Store(false)\n\n\tc.wg.Done()\n\tc.wg.Wait()\n\n\t// If there was an error, try to reconnect depending on its code.\n\tif shouldReconnect(err) {\n\t\tc.reconnectWithBackoff()\n\t}\n}", "func (d *Dispatcher) Wait() error {\n\t// TODO\n\treturn nil\n}", "func (i *InvokeMotorBrake) Wait() error {\n\treturn i.Result(nil)\n}", "func (s *RPC) Wait(c context.Context, id string) error {\n\treturn s.queue.Wait(c, id)\n}", "func (m *mware) Wait() error {\n\treturn m.cmd.Wait()\n}", "func (e *MemEventBus) Wait(channel string) {\n\t// Block briefly to find the handler struct for the channel.\n\te.mutex.Lock()\n\tth, ok := e.handlers[channel]\n\te.mutex.Unlock()\n\tif ok {\n\t\tth.wg.Wait()\n\t}\n}", "func (_m *BandwidthThrottlerSvc) Wait() {\n\t_m.Called()\n}", "func (s *Service) Wait() {\n\ts.waiter.Wait()\n}", "func (s *Service) Wait() {\n\ts.waiter.Wait()\n}", "func (s *Service) Wait() {\n\ts.waiter.Wait()\n}", "func (t *Group) Wait() {\n\tselect {\n\tcase _, ok := <-t.wait:\n\t\tif !ok {\n\t\t\treturn\n\t\t}\n\t}\n}", "func (m *AtomicRecordStorageMock) MinimockWait(timeout mm_time.Duration) {\n\ttimeoutCh := mm_time.After(timeout)\n\tfor {\n\t\tif m.minimockDone() {\n\t\t\treturn\n\t\t}\n\t\tselect {\n\t\tcase <-timeoutCh:\n\t\t\tm.MinimockFinish()\n\t\t\treturn\n\t\tcase <-mm_time.After(10 * mm_time.Millisecond):\n\t\t}\n\t}\n}", "func (s *BlockingWaitStrategy) Wait() {\n\ts.mut.Lock()\n\ts.cond.Wait()\n\ts.mut.Unlock()\n}", "func (t *simpleToken) Wait() bool {\n\treturn true\n}", "func (eb *EventBox) Wait(callback func(*Events)) {\n\teb.cond.L.Lock()\n\n\tif len(eb.events) == 0 {\n\t\teb.cond.Wait()\n\t}\n\n\tcallback(&eb.events)\n\teb.cond.L.Unlock()\n}", "func (rm *ResponseManager) synchronize() {\n\tsync := make(chan error)\n\trm.send(&synchronizeMessage{sync}, nil)\n\tselect {\n\tcase <-rm.ctx.Done():\n\tcase <-sync:\n\t}\n}", "func (m *EventHandler) Wait(d time.Duration) bool {\n\tselect {\n\tcase <-m.Recv:\n\t\treturn true\n\tcase <-time.After(d):\n\t\treturn false\n\t}\n}", "func (q *Queue) Wait() {\n\tq.cond.Wait()\n}", "func wait() {\n\tsig := make(chan os.Signal, 1)\n\tsignal.Notify(sig, os.Interrupt, os.Kill)\n\t<-sig\n\tfmt.Println()\n}", "func wait() {\n\tsig := make(chan os.Signal, 1)\n\tsignal.Notify(sig, os.Interrupt, os.Kill)\n\t<-sig\n\tfmt.Println()\n}", "func (r *result) Wait() {\n\t<-r.done\n}", "func (c *apiConsumers) Wait() {\n\tc.wait()\n}", "func (a *Application) Wait() {\n\t<-a.terminated\n\tlog.Printf(\"[TEST] thats all folks\")\n}", "func (c *Connection) Wait() error {\n\tc.connection.Wait()\n\treturn nil\n}", "func (m *RingMock) MinimockWait(timeout mm_time.Duration) {\n\ttimeoutCh := mm_time.After(timeout)\n\tfor {\n\t\tif m.minimockDone() {\n\t\t\treturn\n\t\t}\n\t\tselect {\n\t\tcase <-timeoutCh:\n\t\t\tm.MinimockFinish()\n\t\t\treturn\n\t\tcase <-mm_time.After(10 * mm_time.Millisecond):\n\t\t}\n\t}\n}", "func (s *Server) Wait() {\n\ts.wg.Wait()\n}", "func (s *Server) Wait() {\n\ts.wg.Wait()\n}" ]
[ "0.71638316", "0.67670363", "0.6692661", "0.6692661", "0.64020497", "0.6372807", "0.634265", "0.630982", "0.62865365", "0.62865365", "0.6208311", "0.61638635", "0.61532706", "0.61414415", "0.61360407", "0.61281914", "0.60768455", "0.60408664", "0.60355836", "0.6030008", "0.5999007", "0.59909517", "0.5963424", "0.59479576", "0.5946819", "0.5920583", "0.5903166", "0.5890581", "0.58802944", "0.58783746", "0.58110625", "0.5809214", "0.5791697", "0.57882476", "0.5788177", "0.57799953", "0.5779446", "0.57715386", "0.5761939", "0.5742536", "0.5740086", "0.5737564", "0.5730264", "0.57243025", "0.57041085", "0.56911415", "0.5688756", "0.56677175", "0.5665699", "0.5660126", "0.564268", "0.564175", "0.56293136", "0.5624622", "0.5601043", "0.55998343", "0.55984783", "0.5596816", "0.5592735", "0.55783886", "0.5577105", "0.5548344", "0.55480826", "0.55480826", "0.55425256", "0.55303264", "0.5528682", "0.5526802", "0.55190074", "0.55183864", "0.55172867", "0.5510977", "0.5506518", "0.55021644", "0.55018806", "0.5489529", "0.5487301", "0.54721045", "0.5467282", "0.546569", "0.546569", "0.546569", "0.54592717", "0.54524326", "0.5452132", "0.544101", "0.54356974", "0.54315835", "0.54271036", "0.54203707", "0.54160184", "0.54160184", "0.5415949", "0.541439", "0.541205", "0.5407783", "0.5399928", "0.53989", "0.53989" ]
0.564632
51
control clip coordinate to window coordinate behavior
func ClipControl(origin uint32, depth uint32) { C.glowClipControl(gpClipControl, (C.GLenum)(origin), (C.GLenum)(depth)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func clip(dst draw.Image, r *image.Rectangle, src image.Image, sp *image.Point) {\n\torig := r.Min\n\t*r = r.Intersect(dst.Bounds())\n\t*r = r.Intersect(src.Bounds().Add(orig.Sub(*sp)))\n\tdx := r.Min.X - orig.X\n\tdy := r.Min.Y - orig.Y\n\tif dx == 0 && dy == 0 {\n\t\treturn\n\t}\n\t(*sp).X += dx\n\t(*sp).Y += dy\n}", "func ClipControl(origin uint32, depth uint32) {\n\tsyscall.Syscall(gpClipControl, 2, uintptr(origin), uintptr(depth), 0)\n}", "func clip(dst Image, r *image.Rectangle, src image.Image, sp *image.Point, mask image.Image, mp *image.Point) {\n\torig := r.Min\n\t*r = r.Intersect(dst.Bounds())\n\t*r = r.Intersect(src.Bounds().Add(orig.Sub(*sp)))\n\tif mask != nil {\n\t\t*r = r.Intersect(mask.Bounds().Add(orig.Sub(*mp)))\n\t}\n\tdx := r.Min.X - orig.X\n\tdy := r.Min.Y - orig.Y\n\tif dx == 0 && dy == 0 {\n\t\treturn\n\t}\n\tsp.X += dx\n\tsp.Y += dy\n\tif mp != nil {\n\t\tmp.X += dx\n\t\tmp.Y += dy\n\t}\n}", "func (cv *Canvas) Clip() {\n\tcv.clip(&cv.path, matIdentity())\n}", "func (c *canvasRenderer) Clip() {\n\tc.clipPath(c.canvasPath)\n}", "func (w *Widget) getDeviceClientCoords(clientAreaType TClientAreaType) (region Region, clipRegion ClippingRegion) {\r\n var parentRegion Region\r\n var parentClip ClippingRegion\r\n\r\n\tif w.parent == nil {\r\n region = Region{\r\n x1: w.left,\r\n y1: w.top,\r\n x2: w.left + w.w - 1,\r\n y2: w.top + w.h - 1,\r\n }\r\n parentClip = ClippingRegion{\r\n x1: region.x1,\r\n y1: region.y1,\r\n x2: region.x2,\r\n y2: region.y2,\r\n }\r\n\t} else {\r\n\t\tparentRegion, parentClip = w.parent.getDeviceClientCoords(windowClientArea)\r\n\r\n region = Region{\r\n x1: parentRegion.x1 + w.left,\r\n y1: parentRegion.y1 + w.top,\r\n x2: parentRegion.x1 + w.left + w.w - 1,\r\n y2: parentRegion.y1 + w.top + w.h - 1,\r\n }\r\n\t}\r\n\r\n if clientAreaType == windowWithBorders || clientAreaType == windowClientArea {\r\n if w.border.top != BorderStyleNone {\r\n region.y1++\r\n // clipRegion.y1++\r\n }\r\n if w.border.left != BorderStyleNone {\r\n region.x1++\r\n // clipRegion.x1++\r\n }\r\n if w.border.bottom != BorderStyleNone {\r\n region.y2--\r\n // clipRegion.y2--\r\n }\r\n if w.border.right != BorderStyleNone {\r\n region.x2--\r\n // clipRegion.x2--\r\n }\r\n }\r\n\r\n // Adjust clipRegion\r\n if w.parent != nil {\r\n clipRegion.x1 = maxInt(region.x1, parentClip.x1)\r\n clipRegion.y1 = maxInt(region.y1, parentClip.y1)\r\n clipRegion.x2 = minInt(region.x2, parentClip.x2)\r\n clipRegion.y2 = minInt(region.y2, parentClip.y2)\r\n }\r\n\r\n\treturn\r\n}", "func ClipPos(in Res) Res {\n\tout := in.Output().Copy()\n\tanyvec.ClipPos(out)\n\treturn &clipPosRes{\n\t\tIn: in,\n\t\tOutVec: out,\n\t}\n}", "func (c *canvasRenderer) SetClipRect(left, right, top, bottom float32) {\n\tc.currentLayer.ClipTransform = sprec.Mat4Prod(\n\t\tsprec.NewMat4(\n\t\t\t1.0, 0.0, 0.0, -left,\n\t\t\t-1.0, 0.0, 0.0, right,\n\t\t\t0.0, 1.0, 0.0, -top,\n\t\t\t0.0, -1.0, 0.0, bottom,\n\t\t),\n\t\tsprec.InverseMat4(c.currentLayer.Transform),\n\t)\n}", "func (r Rectangle) Clip(pts []Point) []Point {\n\tclipped := make([]Point, 0, len(pts))\n\tfor _, pt := range pts {\n\t\tif pt.In(r) {\n\t\t\tclipped = append(clipped, pt)\n\t\t}\n\t}\n\treturn clipped\n}", "func (dl *DrawList) UpdateClipRect() {\n\t//clip := dl.CurrentClipRect()\n}", "func clip(x, a, b int) int {\n\tif x < a {\n\t\treturn a\n\t}\n\tif x > b-1 {\n\t\treturn b - 1\n\t}\n\treturn x\n}", "func (o *NewWindowOptions) Fixup() {\n\tsc := TheApp.Screen(0)\n\tscsz := sc.Geometry.Size() // window coords size\n\n\tif o.Size.X <= 0 {\n\t\to.StdPixels = false\n\t\to.Size.X = int(0.8 * float32(scsz.X) * sc.DevicePixelRatio)\n\t}\n\tif o.Size.Y <= 0 {\n\t\to.StdPixels = false\n\t\to.Size.Y = int(0.8 * float32(scsz.Y) * sc.DevicePixelRatio)\n\t}\n\n\to.Size, o.Pos = sc.ConstrainWinGeom(o.Size, o.Pos)\n\tif o.Pos.X == 0 && o.Pos.Y == 0 {\n\t\twsz := sc.WinSizeFmPix(o.Size)\n\t\tdialog, modal, _, _ := WindowFlagsToBool(o.Flags)\n\t\tnw := TheApp.NWindows()\n\t\tif nw > 0 {\n\t\t\tlastw := TheApp.Window(nw - 1)\n\t\t\tlsz := lastw.WinSize()\n\t\t\tlp := lastw.Position()\n\n\t\t\tnwbig := wsz.X > lsz.X || wsz.Y > lsz.Y\n\n\t\t\tif modal || dialog || !nwbig { // place centered on top of current\n\t\t\t\tctrx := lp.X + (lsz.X / 2)\n\t\t\t\tctry := lp.Y + (lsz.Y / 2)\n\t\t\t\to.Pos.X = ctrx - wsz.X/2\n\t\t\t\to.Pos.Y = ctry - wsz.Y/2\n\t\t\t} else { // cascade to right\n\t\t\t\to.Pos.X = lp.X + lsz.X // tile to right -- could depend on orientation\n\t\t\t\to.Pos.Y = lp.Y + 72 // and move down a bit\n\t\t\t}\n\t\t} else { // center in screen\n\t\t\to.Pos.X = scsz.X/2 - wsz.X/2\n\t\t\to.Pos.Y = scsz.Y/2 - wsz.Y/2\n\t\t}\n\t\to.Size, o.Pos = sc.ConstrainWinGeom(o.Size, o.Pos) // make sure ok\n\t}\n}", "func (c *Camera) santizeBounds() {\n\t// x and y\n\tif c.x < 0 {\n\t\tc.x = 0\n\t}\n\tif c.y < 0 {\n\t\tc.y = 0\n\t}\n\tif c.x+c.width > c.worldWidth {\n\t\tc.x = c.worldWidth - c.width\n\t}\n\tif c.y+c.height > c.worldHeight {\n\t\tc.y = c.worldHeight - c.height\n\t}\n\n\t// width and height\n\tif c.width < 100 {\n\t\tc.width = 100\n\t}\n\tif c.height < 100 {\n\t\tc.height = 100\n\t}\n\tif c.width > c.worldWidth {\n\t\tc.width = c.worldWidth\n\t}\n\tif c.height > c.worldHeight {\n\t\tc.height = c.worldHeight\n\t}\n}", "func (dw *DrawingWand) PopClipPath() {\n\tC.DrawPopClipPath(dw.dw)\n}", "func clipperPoint(p data.MicroPoint) *clipper.IntPoint {\n\treturn &clipper.IntPoint{\n\t\tX: clipper.CInt(p.X()),\n\t\tY: clipper.CInt(p.Y()),\n\t}\n}", "func (r Rectangle) Clip(r1 Rectangle) Rectangle {\n\tif r.Empty() {\n\t\treturn r\n\t}\n\tif r1.Empty() {\n\t\treturn r1\n\t}\n\tif !r.Overlaps(r1) {\n\t\treturn Rectangle{r.Min, r.Min}\n\t}\n\tif r.Min.X < r1.Min.X {\n\t\tr.Min.X = r1.Min.X\n\t}\n\tif r.Min.Y < r1.Min.Y {\n\t\tr.Min.Y = r1.Min.Y\n\t}\n\tif r.Max.X > r1.Max.X {\n\t\tr.Max.X = r1.Max.X\n\t}\n\tif r.Max.Y > r1.Max.Y {\n\t\tr.Max.Y = r1.Max.Y\n\t}\n\treturn r\n}", "func (d *Device) setWindow(x, y, w, h int16) {\n\tx += d.columnOffset\n\ty += d.rowOffset\n\tcopy(d.buf[:4], []uint8{uint8(x >> 8), uint8(x), uint8((x + w - 1) >> 8), uint8(x + w - 1)})\n\td.sendCommand(CASET, d.buf[:4])\n\tcopy(d.buf[:4], []uint8{uint8(y >> 8), uint8(y), uint8((y + h - 1) >> 8), uint8(y + h - 1)})\n\td.sendCommand(RASET, d.buf[:4])\n\td.sendCommand(RAMWR, nil)\n}", "func ClipPlane(plane uint32, equation *float64) {\n\tsyscall.Syscall(gpClipPlane, 2, uintptr(plane), uintptr(unsafe.Pointer(equation)), 0)\n}", "func Vclip(input []float32, inputStride int, low, high float32, output []float32, outputStride int) {\n\tC.vDSP_vclip((*C.float)(&input[0]), C.vDSP_Stride(inputStride), (*C.float)(&low), (*C.float)(&high), (*C.float)(&output[0]), C.vDSP_Stride(outputStride), minLen(len(input)/inputStride, len(output)/outputStride))\n}", "func WithClip(ctx context.Context, clip bool) context.Context {\n\treturn context.WithValue(ctx, ctxKeyClip, clip)\n}", "func ClipPlane(plane uint32, equation *float64) {\n C.glowClipPlane(gpClipPlane, (C.GLenum)(plane), (*C.GLdouble)(unsafe.Pointer(equation)))\n}", "func IsClip(ctx context.Context) bool {\n\tbv, ok := ctx.Value(ctxKeyClip).(bool)\n\tif !ok {\n\t\treturn false\n\t}\n\n\treturn bv\n}", "func (s *Surface) ClipPath(p *Path) {\n\ts.Ctx.Call(\"clip\", p.obj)\n}", "func (c *Context) SetClip(clip image.Rectangle) {\n\tc.clip = clip\n}", "func (icn *Icon) Move(x, y int) {\n icn.Window.Move(x, y)\n icn.Blend()\n}", "func (dw *DrawingWand) SetClipUnits(clipUnits ClipPathUnits) {\n\tC.MagickDrawSetClipUnits(dw.dw, C.ClipPathUnits(clipUnits))\n}", "func (p *Projection) project(wx float64, wy float64) (float64, float64) {\n return ((wx / p.worldWidth) * p.canvasWidth) + (p.canvasWidth * 0.5),\n ((wy / p.worldHeight) * -p.canvasHeight) + (p.canvasHeight * 0.5)\n}", "func (t *Text) Clip(start, end int) error {\n\treturn clipboard.WriteAll(string(t.Compiled[start:end]))\n}", "func ClipPlane(plane uint32, equation *float64) {\n\tC.glowClipPlane(gpClipPlane, (C.GLenum)(plane), (*C.GLdouble)(unsafe.Pointer(equation)))\n}", "func (ac *Activity) ResizeWindow(ctx context.Context, border BorderType, to Point, t time.Duration) error {\n\ttask, err := ac.getTaskInfo(ctx)\n\tif err != nil {\n\t\treturn errors.Wrap(err, \"could not get task info\")\n\t}\n\n\tif task.windowState != WindowStateNormal && task.windowState != WindowStatePIP {\n\t\treturn errors.Errorf(\"cannot move window in state %d\", int(task.windowState))\n\t}\n\n\t// Default value: center of window.\n\tbounds, err := ac.WindowBounds(ctx)\n\tif err != nil {\n\t\treturn errors.Wrap(err, \"could not get activity bounds\")\n\t}\n\tsrc := Point{\n\t\tbounds.Left + bounds.Width/2,\n\t\tbounds.Top + bounds.Height/2,\n\t}\n\n\tborderOffset := borderOffsetForNormal\n\tif task.windowState == WindowStatePIP {\n\t\tborderOffset = borderOffsetForPIP\n\t}\n\n\t// Top & Bottom are exclusive.\n\tif border&BorderTop != 0 {\n\t\tsrc.Y = bounds.Top - borderOffset\n\t} else if border&BorderBottom != 0 {\n\t\tsrc.Y = bounds.Top + bounds.Height + borderOffset\n\t}\n\n\t// Left & Right are exclusive.\n\tif border&BorderLeft != 0 {\n\t\tsrc.X = bounds.Left - borderOffset\n\t} else if border&BorderRight != 0 {\n\t\tsrc.X = bounds.Left + bounds.Width + borderOffset\n\t}\n\n\t// After updating src, clamp it to valid display bounds.\n\tds, err := ac.disp.Size(ctx)\n\tif err != nil {\n\t\treturn errors.Wrap(err, \"could not get display size\")\n\t}\n\tsrc.X = int(math.Max(0, math.Min(float64(ds.W-1), float64(src.X))))\n\tsrc.Y = int(math.Max(0, math.Min(float64(ds.H-1), float64(src.Y))))\n\n\treturn ac.swipe(ctx, src, to, t)\n}", "func (histogram Histogram) Clip(limit int) {\n\n\tvar buffer int\n\n\tbinCount := len(histogram)\n\texcess := 0\n\n\tfor i := 0; i < binCount; i++ {\n\t\tbuffer = histogram[i] - limit\n\t\tif buffer > 0 {\n\t\t\texcess += buffer\n\t\t}\n\t}\n\n\tincrementPerBin := excess / binCount\n\tupper := binCount - incrementPerBin\n\n\tfor i := 0; i < binCount; i++ {\n\t\tswitch {\n\t\tcase histogram[i] > limit:\n\t\t\thistogram[i] = limit\n\t\tcase histogram[i] > upper:\n\t\t\texcess += upper - histogram[i]\n\t\t\thistogram[i] = limit\n\t\tdefault:\n\t\t\texcess -= incrementPerBin\n\t\t\thistogram[i] += incrementPerBin\n\t\t}\n\t}\n\n\tif excess > 0 {\n\n\t\tstep := (1 + (excess / binCount))\n\t\tif step < 1 {\n\t\t\tstep = 1\n\t\t}\n\n\t\tfor i := 0; i < binCount; i++ {\n\t\t\texcess -= step\n\t\t\thistogram[i] += step\n\t\t\tif excess < 1 {\n\t\t\t\tbreak\n\t\t\t}\n\t\t}\n\n\t}\n\n}", "func ClipRange(in Res, min, max anyvec.Numeric) Res {\n\treturn Pool(in, func(in Res) Res {\n\t\thighEnough, lowEnough := in.Output().Copy(), in.Output().Copy()\n\t\tanyvec.GreaterThan(highEnough, min)\n\t\tanyvec.LessThan(lowEnough, max)\n\n\t\tmidRange := highEnough.Copy()\n\t\tmidRange.Mul(lowEnough)\n\t\tmiddlePart := Mul(in, NewConst(midRange))\n\n\t\tanyvec.Complement(lowEnough)\n\t\tlowEnough.Scale(max)\n\t\tanyvec.Complement(highEnough)\n\t\thighEnough.Scale(min)\n\t\treturn Add(\n\t\t\tmiddlePart,\n\t\t\tAdd(\n\t\t\t\tNewConst(lowEnough),\n\t\t\t\tNewConst(highEnough),\n\t\t\t),\n\t\t)\n\t})\n}", "func ClipByValue(scope *Scope, t tf.Output, clip_value_min tf.Output, clip_value_max tf.Output) (output tf.Output) {\n\tif scope.Err() != nil {\n\t\treturn\n\t}\n\topspec := tf.OpSpec{\n\t\tType: \"ClipByValue\",\n\t\tInput: []tf.Input{\n\t\t\tt, clip_value_min, clip_value_max,\n\t\t},\n\t}\n\top := scope.AddOperation(opspec)\n\treturn op.Output(0)\n}", "func (dw *DrawingWand) SetClipRule(fillRule FillRule) {\n\tC.MagickDrawSetClipRule(dw.dw, C.FillRule(fillRule))\n}", "func (p *Projection) cross(wx float64, wy float64, col color.RGBA) {\n cx, cy := p.project(wx, wy)\n\n c := draw2d.NewGraphicContext(p.img)\n c.SetStrokeColor(col)\n c.SetLineWidth(1)\n size := 2.0\n\n // top left -> bottom right\n c.MoveTo(cx - size, cy - size)\n c.LineTo(cx + size, cy + size)\n c.Stroke()\n\n // top right -> bottom left\n c.MoveTo(cx + size, cy - size)\n c.LineTo(cx - size, cy + size)\n c.Stroke()\n}", "func (w *windowImpl) Copy(dp image.Point, src screen.Texture, sr image.Rectangle, op draw.Op, opts *screen.DrawOptions) {\n\tpanic(\"not implemented\") // TODO: Implement\n}", "func (win *Window) moveNoReset() {\n\twin.Window.Move(win.Layout.X, win.Layout.Y)\n}", "func (obj *Device) SetClipStatus(clipStatus CLIPSTATUS) Error {\n\tret, _, _ := syscall.Syscall(\n\t\tobj.vtbl.SetClipStatus,\n\t\t2,\n\t\tuintptr(unsafe.Pointer(obj)),\n\t\tuintptr(unsafe.Pointer(&clipStatus)),\n\t\t0,\n\t)\n\treturn toErr(ret)\n}", "func (f *Frame) Crop(w, h, xOffset, yOffset int) error {\n\tif w+xOffset > f.Width {\n\t\treturn fmt.Errorf(\"cropped width + x offset (%d) cannot exceed original width (%d)\",\n\t\t\tw+xOffset, f.Width)\n\t}\n\tif h+yOffset > f.Height {\n\t\treturn fmt.Errorf(\"cropped height + y offset (%d) cannot exceed original height (%d)\",\n\t\t\th+yOffset, f.Height)\n\t}\n\tnewY := make([]byte, 0, w*h)\n\tfor y := 0; y < h; y++ {\n\t\tyt := y + yOffset\n\t\tx0 := yt*f.Width + xOffset\n\t\tx1 := x0 + w\n\t\tnewY = append(newY, f.Y[x0:x1]...)\n\t}\n\tf.Y = newY\n\txss := xSubsamplingFactor[f.Chroma]\n\tyss := ySubsamplingFactor[f.Chroma]\n\tnewCb := make([]byte, 0, w/xss*h/yss)\n\tnewCr := make([]byte, 0, w/xss*h/yss)\n\tfor y := 0; y < h/yss; y++ {\n\t\tyt := y + yOffset/yss\n\t\tx0 := yt*f.Width/xss + xOffset/xss\n\t\tx1 := x0 + w/xss\n\t\tnewCb = append(newCb, f.Cb[x0:x1]...)\n\t\tnewCr = append(newCr, f.Cr[x0:x1]...)\n\t}\n\tf.Cb = newCb\n\tf.Cr = newCr\n\tif len(f.Alpha) > 0 {\n\t\tnewAlpha := make([]byte, 0, w*h)\n\t\tfor y := 0; y < h; y++ {\n\t\t\tyt := y + yOffset\n\t\t\tx0 := yt*f.Width + xOffset\n\t\t\tx1 := x0 + w\n\t\t\tnewAlpha = append(newAlpha, f.Alpha[x0:x1]...)\n\t\t}\n\t\tf.Alpha = newAlpha\n\t}\n\tf.Width = w\n\tf.Height = h\n\treturn nil\n}", "func WithOnlyClip(ctx context.Context, clip bool) context.Context {\n\treturn context.WithValue(ctx, ctxKeyOnlyClip, clip)\n}", "func (t *Tty) clampCursorStrict(c Pt) Pt {\n\treturn Pt{\n\t\tX: clamp(c.X, 0, t.Size.X-1),\n\t\tY: clamp(c.Y, 0, t.Size.Y-1),\n\t}\n}", "func (w *Window) Center() {\n\tif err := driver.macRPC.Call(\"windows.Center\", nil, struct {\n\t\tID string\n\t}{\n\t\tID: w.ID().String(),\n\t}); err != nil {\n\t\tpanic(err)\n\t}\n}", "func world2screen(wx, wy float32) (sx, sy int) {\n\tsx = int((wx * pixel_per_meter) + (float32(WINDOW_X) / 2.0))\n\tsy = int((-wy * pixel_per_meter) + (float32(WINDOW_Y) / 2.0))\n\treturn\n}", "func IsOnlyClip(ctx context.Context) bool {\n\tbv, ok := ctx.Value(ctxKeyOnlyClip).(bool)\n\tif !ok {\n\t\treturn false\n\t}\n\n\treturn bv\n}", "func (self *Graphics) UpdateLocalBounds() {\n self.Object.Call(\"updateLocalBounds\")\n}", "func ScreenXY(value Vec2) *SimpleElement { return newSEVec2(\"screenXY\", value) }", "func (dw *DrawingWand) SetClipPath(clipMaskId string) {\n\tcstr := C.CString(clipMaskId)\n\tdefer C.free(unsafe.Pointer(cstr))\n\tC.MagickDrawSetClipPath(dw.dw, cstr)\n}", "func AbsRect(cont *fyne.Container, x, y, w, h int, color color.RGBA) {\n\tfx, fy, fw, fh := float32(x), float32(y), float32(w), float32(h)\n\tr := &canvas.Rectangle{FillColor: color}\n\tr.Move(fyne.Position{X: fx - (fw / 2), Y: fy - (fh / 2)})\n\tr.Resize(fyne.Size{Width: fw, Height: fh})\n\tcont.AddObject(r)\n}", "func OverlayXY(value Vec2) *SimpleElement { return newSEVec2(\"overlayXY\", value) }", "func ccw(a, b, c image.Point) bool {\n\treturn ((b.X - a.X) * (c.Y - a.Y)) > ((b.Y - a.Y) * (c.X - a.X))\n}", "func (bl *Blend) clip(rgb Color) Color {\r\n\tr, g, b := rgb.R, rgb.G, rgb.B\r\n\r\n\tl := bl.Lum(rgb)\r\n\tmin := utils.Min(r, g, b)\r\n\tmax := utils.Max(r, g, b)\r\n\r\n\tif min < 0 {\r\n\t\tr = l + (((r - l) * l) / (l - min))\r\n\t\tg = l + (((g - l) * l) / (l - min))\r\n\t\tb = l + (((b - l) * l) / (l - min))\r\n\t}\r\n\tif max > 1 {\r\n\t\tr = l + (((r - l) * (1 - l)) / (max - l))\r\n\t\tg = l + (((g - l) * (1 - l)) / (max - l))\r\n\t\tb = l + (((b - l) * (1 - l)) / (max - l))\r\n\t}\r\n\r\n\treturn Color{R: r, G: g, B: b}\r\n}", "func (b *BaseDevice) SetMatrixClip(mat *Matrix, bw *Region, clipStack *ClipStack) {\n\ttoimpl()\n}", "func (c *Canvas) SetBounds(bounds pixel.Rect) {\n\tc.gf.SetBounds(bounds)\n\tif c.sprite == nil {\n\t\tc.sprite = pixel.NewSprite(nil, pixel.Rect{})\n\t}\n\tc.sprite.Set(c, c.Bounds())\n\t//c.sprite.SetMatrix(pixel.IM.Moved(c.Bounds().Center()))\n}", "func (win *Window) move() {\n\twin.Window.Move(win.Layout.X, win.Layout.Y)\n\twin.Layout.State &= ^MaximizedFull\n\twin.updateWmState()\n}", "func VPBLENDW(i, mxy, xy, xy1 operand.Op) { ctx.VPBLENDW(i, mxy, xy, xy1) }", "func (gd *Definition) ConatainsPoint(x, y, buf float64) bool {\n\tif x < gd.Eorig-buf {\n\t\treturn false\n\t}\n\tif x > gd.Eorig+float64(gd.Ncol)*gd.Cwidth+buf {\n\t\treturn false\n\t}\n\tif y > gd.Norig+buf {\n\t\treturn false\n\t}\n\tif y < gd.Norig-float64(gd.Nrow)*gd.Cwidth-buf {\n\t\treturn false\n\t}\n\treturn true\n}", "func (c *Camera) StoW(sx, sy int) (float64, float64) {\n\tvar x, y float64\n\tx = (float64(sx)-float64(c.screenW)/2.0)/c.zoom + c.lookAtX\n\ty = c.lookAtY - (float64(sy)-float64(c.screenH)/2.0)/c.zoom\n\treturn x, y\n}", "func (m *MainWindow) checkMainPanePosition() {\n\tglib.IdleAdd(func() bool {\n\t\tm.pane_negative_position = m.window_width - m.hpane.GetPosition()\n\t\treturn false\n\t})\n}", "func (dw *DrawingWand) PushClipPath(clipMaskId string) {\n\tcstr := C.CString(clipMaskId)\n\tdefer C.free(unsafe.Pointer(cstr))\n\tC.MagickDrawPushClipPath(dw.dw, cstr)\n}", "func (m *MainWindow) checkPositionAndSize() {\n\tglib.IdleAdd(func() bool {\n\t\tm.window_pos_x, m.window_pos_y = m.window.GetPosition()\n\t\tm.window_width, m.window_height = m.window.GetSize()\n\n\t\tm.hpane.SetPosition(m.window_width - m.pane_negative_position)\n\t\treturn false\n\t})\n}", "func (obj *Device) SetClipPlane(index uint32, plane [4]float32) Error {\n\tret, _, _ := syscall.Syscall(\n\t\tobj.vtbl.SetClipPlane,\n\t\t3,\n\t\tuintptr(unsafe.Pointer(obj)),\n\t\tuintptr(index),\n\t\tuintptr(unsafe.Pointer(&plane[0])),\n\t)\n\treturn toErr(ret)\n}", "func (t *Tile) ScaledRelativePos(p Point) (np Point) {\n\trelPos := t.RelativePos(p)\n\tnp = Point{relPos.X / t.Width, relPos.Y / t.Width}\n\treturn\n}", "func (b *baseComponent) holdPosInsideParent(pos rl.Vector2) rl.Vector2 {\n\tbounds := b.GetParentBounds()\n\tif pos.X > bounds.Width {\n\t\tpos.X = bounds.Width\n\t} else if pos.X < bounds.X {\n\t\tpos.X = bounds.X\n\t}\n\n\tif pos.Y > bounds.Height {\n\t\tpos.Y = bounds.Height\n\t} else if pos.Y < bounds.Y {\n\t\tpos.Y = bounds.Y\n\t}\n\n\treturn pos\n}", "func VPSIGNW(mxy, xy, xy1 operand.Op) { ctx.VPSIGNW(mxy, xy, xy1) }", "func (v *IconView) ConvertWidgetToBinWindowCoords(x, y int) (int, int) {\n\tvar bx, by C.gint\n\n\tC.gtk_icon_view_convert_widget_to_bin_window_coords(v.native(), C.gint(x), C.gint(y), &bx, &by)\n\n\treturn int(bx), int(by)\n}", "func (p *HatchPattern) ClipTo(r Renderer, clip *Path) {\n\thatch := p.Tile(clip)\n\tr.RenderPath(hatch, Style{Fill: p.Fill}, Identity)\n}", "func (b *Bound) SouthWest() *Point { return b.sw.Clone() }", "func (c *Camera) Update(window *pixelgl.Window) {\n\tc.pixelPosition.X = c.chaseObject.GetPosition().X - window.Bounds().Max.X / 2\n\tc.pixelPosition.Y = c.chaseObject.GetPosition().Y - window.Bounds().Max.Y / 2\n\n\tc.matrixPosition = pixel.IM.Moved(c.pixelPosition.Scaled(-1))\n\twindow.SetMatrix(c.matrixPosition)\n\n\tc.zoom *= math.Pow(c.zoomSpeed, window.MouseScroll().Y)\n\n\tif c.zoom > c.maxZoom {\n\t\tc.zoom = c.maxZoom\n\t} else if c.zoom < c.minZoom {\n\t\tc.zoom = c.minZoom\n\t}\n}", "func Dimen(c canvas, xp, yp, sp float64) (x, y, s float64) {\n\tx = (xp / 100) * float64(c.Width)\n\ty = (yp / 100) * float64(c.Height)\n\ts = (sp / 100) * float64(c.Width)\n\treturn\n}", "func ApplyOfficialWindowScaling(storedValue int, rescaleSlope, rescaleIntercept, windowWidth, windowCenter float64, bitsAllocated uint16) uint16 {\n\t// 1: StoredValue to ModalityValue\n\tvar modalityValue float64\n\tif rescaleSlope == 0 {\n\t\t// Via https://dgobbi.github.io/vtk-dicom/doc/api/image_display.html :\n\t\t// For modalities such as ultrasound and MRI that do not have any units,\n\t\t// the RescaleSlope and RescaleIntercept are absent and the Modality\n\t\t// Values are equal to the Stored Values.\n\t\tmodalityValue = float64(storedValue)\n\t} else {\n\t\t// Otherwise, we can apply the rescale slope and intercept to the stored\n\t\t// value.\n\t\tmodalityValue = float64(storedValue)*rescaleSlope + rescaleIntercept\n\t}\n\n\t// 2: ModalityValue to WindowedValue\n\n\t// The key here is that we're using bitsAllocated (e.g., 16 bits) instead of\n\t// bitsStored (e.g., 11 bits)\n\tvar grayLevels float64\n\tswitch bitsAllocated {\n\t// Precompute common cases so you're not exponentiating in the hot path\n\tcase 16:\n\t\tgrayLevels = 65536\n\tcase 8:\n\t\tgrayLevels = 256\n\tdefault:\n\t\tgrayLevels = math.Pow(2, float64(bitsAllocated))\n\t}\n\n\t// We are creating a 16-bit image, so we need to scale the modality value to\n\t// the range of 0-65535. Particularly if we're using 8-bit, then we need to\n\t// scale the 0-255 range to 0-65535, otherwise the images will look black.\n\tsixteenBitCorrection := math.MaxUint16 / uint16(grayLevels-1)\n\n\t// Via https://dgobbi.github.io/vtk-dicom/doc/api/image_display.html : For\n\t// ultrasound (and for 8-bit images in general) the WindowWidth and\n\t// WindowCenter may be absent from the file. If absent, they can be assumed\n\t// to be 256 and 128 respectively, which provides an 8-bit identity mapping.\n\t// Here, instead of assuming 8 bit, we use the grayLevels value.\n\tif windowWidth == 0 && windowCenter == 0 {\n\t\twindowWidth = grayLevels\n\t\twindowCenter = grayLevels / 2\n\t}\n\n\tw := windowWidth - 1.0\n\tc := windowCenter - 0.5\n\n\t// Below the lower bound of our window, draw black\n\tif modalityValue <= c-0.5*w {\n\t\treturn 0\n\t}\n\n\t// Above the upper bound of our window, draw white\n\tif modalityValue > c+0.5*w {\n\t\treturn uint16(grayLevels-1.0) * sixteenBitCorrection\n\t}\n\n\t// Within the window, return a scaled value\n\treturn uint16(((modalityValue-c)/w+0.5)*(grayLevels-1.0)) * sixteenBitCorrection\n\n}", "func (m *Match) printMatchClip() {\n\tstartStr := \"...\"\n\tendStr := \"...\"\n\tstart := m.Match[0] - SideBuffer\n\tend := m.Match[1] + SideBuffer\n\n\tif start < 0 {\n\t\tstart = 0\n\t\tstartStr = \"\"\n\t}\n\tif end > len(m.Line)-1 {\n\t\tend = len(m.Line) - 1\n\t\tendStr = \"\"\n\t}\n\n\tfmt.Printf(\"%s%s%s%s:%s:%s%s%s%s%s%s%s%s%s%s%s%s\\n\",\n\t\tcolors.Purple,\n\t\tm.Path,\n\t\tcolors.Restore,\n\t\tcolors.Green,\n\t\tstrconv.Itoa(m.LineNumber),\n\t\tcolors.Restore,\n\t\tcolors.Yellow,\n\t\tstartStr,\n\t\tcolors.Restore,\n\t\tstring(m.Line[start:m.Match[0]]),\n\t\tcolors.LightRed,\n\t\tstring(m.Line[m.Match[0]:m.Match[1]]),\n\t\tcolors.Restore,\n\t\tstring(m.Line[m.Match[1]:end]),\n\t\tcolors.Yellow,\n\t\tendStr,\n\t\tcolors.Restore,\n\t)\n}", "func (bm Blendmap) View() (float32, float32, float32, float32) {\n\treturn bm.Map.viewport.Min.X, bm.Map.viewport.Min.Y, bm.Map.viewport.Max.X, bm.Map.viewport.Max.Y\n}", "func (self *Graphics) SetOffsetXA(member int) {\n self.Object.Set(\"offsetX\", member)\n}", "func (dw *DrawingWand) PathMoveToAbsolute(x, y float64) {\n\tC.MagickDrawPathMoveToAbsolute(dw.dw, C.double(x), C.double(y))\n}", "func (t *Three) AnimationClip() *AnimationClip {\n\tp := t.ctx.Get(\"AnimationClip\")\n\treturn AnimationClipFromJSObject(p)\n}", "func (self *Graphics) SetOutOfCameraBoundsKillA(member bool) {\n self.Object.Set(\"outOfCameraBoundsKill\", member)\n}", "func (w *WindowWidget) Pos(x, y float32) *WindowWidget {\n\tw.x, w.y = x, y\n\treturn w\n}", "func (self *Graphics) CameraOffset() *Point{\n return &Point{self.Object.Get(\"cameraOffset\")}\n}", "func ClipTable(table Table, i, j, m, n int) Table {\n\tminR, minC := i, j\n\tmaxR, maxC := i+m, j+n\n\tif minR < 0 || minC < 0 || minR > maxR || minC > maxC || maxR >= table.RowCount() || maxC >= table.ColCount() {\n\t\tpanic(\"out of bound\")\n\t}\n\treturn &TableView{table, i, j, m, n}\n}", "func transformProcessRect(rect image.Rectangle) image.Rectangle {\n\treturn image.Rectangle{\n\t\tMin: image.Point{\n\t\t\tX: rect.Min.X * config.AppConfig.ImageProcessScale,\n\t\t\tY: rect.Min.Y * config.AppConfig.ImageProcessScale,\n\t\t},\n\t\tMax: image.Point{\n\t\t\tX: rect.Max.X * config.AppConfig.ImageProcessScale,\n\t\t\tY: rect.Max.Y * config.AppConfig.ImageProcessScale,\n\t\t},\n\t}\n}", "func (self *Rectangle) CenterOn(x int, y int) *Rectangle{\n return &Rectangle{self.Object.Call(\"centerOn\", x, y)}\n}", "func backToOriginCap(c int) int {\n\tif c <= neighbour {\n\t\treturn c\n\t}\n\treturn c + 1 - neighbour\n}", "func (s *Scroll) DrawOnTop(t ggl.Target, c *drw.Geom) {\n\tif s.X.use {\n\t\trect := mat.AABB{Min: s.Frame.Min, Max: s.corner}\n\t\tc.Color(s.RailColor).AABB(rect)\n\t\trect.Min.X, rect.Max.X = s.barBounds(&s.X, 0)\n\t\tc.Color(s.BarColor).AABB(rect)\n\t}\n\tif s.Y.use {\n\t\trect := mat.AABB{Min: s.corner, Max: s.Frame.Max}\n\t\tc.Color(s.RailColor).AABB(rect)\n\t\trect.Min.Y, rect.Max.Y = s.barBounds(&s.Y, 1)\n\t\tc.Color(s.BarColor).AABB(rect)\n\t}\n\n\tif s.X.use && s.Y.use {\n\t\trect := mat.A(s.corner.X, s.Frame.Min.Y, s.Frame.Max.X, s.corner.Y)\n\t\tc.Color(s.IntersectionColor).AABB(rect)\n\t}\n\n\tc.Fetch(t)\n}", "func toPixelVector(win *pixelgl.Window, x float64, y float64) pixel.Vec {\n\tvar (\n\t\tnewY = win.Bounds().Max.Y - y\n\t)\n\n\treturn pixel.Vec{x, newY}\n}", "func (p *player) adjustPosition() {\n\tif p.startedMoving == 0 {\n\t\treturn\n\t}\n\tp.location.x, p.location.y = p.calculatePosition()\n\tval, _ := w.inPlatform(p.location.x, p.location.y)\n\tlog.Println(\"in platform,\", val, p.location.x, p.location.y)\n\tp.startedMoving = 0\n}", "func (e *Emulator) Bounds() image.Rectangle { return image.Rect(0, 0, e.Width, e.Height) }", "func (win *Window) moveAndResizeNoReset() {\n\twin.Window.MoveResize(win.Layout.X, win.Layout.Y, win.Layout.Width, win.Layout.Height)\n}", "func (c *Client) SimpleHlsClip(request *SimpleHlsClipRequest) (response *SimpleHlsClipResponse, err error) {\n if request == nil {\n request = NewSimpleHlsClipRequest()\n }\n response = NewSimpleHlsClipResponse()\n err = c.Send(request, response)\n return\n}", "func clipperPath(p data.Path) clipper.Path {\n\tvar result clipper.Path\n\tfor _, point := range p {\n\t\tresult = append(result, clipperPoint(point))\n\t}\n\n\treturn result\n}", "func (self *Rectangle) OffsetPoint(point *Point) *Rectangle{\n return &Rectangle{self.Object.Call(\"offsetPoint\", point)}\n}", "func (e *Element) move(offset mat.Vec, horizontal bool) mat.Vec {\n\toff := offset.Add(e.margin.Min).Add(e.Offest)\n\te.Frame = e.size.ToAABB().Moved(off)\n\toff.AddE(e.Padding.Min)\n\toOff := off\n\te.Module.OnFrameChange()\n\te.forChild(FCfg{\n\t\tFilter: IgnoreHidden.Filter,\n\t\tReverse: !e.Horizontal(),\n\t}, func(ch *Element) {\n\t\tif ch.Relative {\n\t\t\tch.move(oOff, false)\n\t\t} else {\n\t\t\toff = ch.move(off, e.Horizontal())\n\t\t}\n\n\t})\n\n\tif horizontal {\n\t\tl, _, r, _ := e.margin.Deco()\n\t\toffset.X += l + r + e.Frame.W()\n\t} else {\n\t\t_, b, _, t := e.margin.Deco()\n\t\toffset.Y += b + t + e.Frame.H()\n\t}\n\n\treturn offset\n}", "func (dw *DrawingWand) Translate(x, y float64) {\n\tC.MagickDrawTranslate(dw.dw, C.double(x), C.double(y))\n}", "func (m *MovingAverage) clean() {\n\tif curLen := len(m.concludeWindows); curLen == WindowCap {\n\t\tvar tenPct = math.Round(CleanPct * float64(WindowCap))\n\t\tm.concludeWindows = m.concludeWindows[int(tenPct):]\n\t}\n}", "func (self *Graphics) OffsetX() int{\n return self.Object.Get(\"offsetX\").Int()\n}", "func (self *Graphics) FixedToCamera() bool{\n return self.Object.Get(\"fixedToCamera\").Bool()\n}", "func (dw *DrawingWand) GetClipPath() string {\n\tcscp := C.MagickDrawGetClipPath(dw.dw)\n\tdefer C.MagickRelinquishMemory(unsafe.Pointer(cscp))\n\treturn C.GoString(cscp)\n}", "func (wb *WidgetBase) BoundsPixels() Rectangle {\n\tb := wb.WindowBase.BoundsPixels()\n\n\tif wb.parent != nil {\n\t\tp := b.Location().toPOINT()\n\t\tif !win.ScreenToClient(wb.parent.Handle(), &p) {\n\t\t\tnewError(\"ScreenToClient failed\")\n\t\t\treturn Rectangle{}\n\t\t}\n\t\tb.X = int(p.X)\n\t\tb.Y = int(p.Y)\n\t}\n\n\treturn b\n}", "func rcube(x, y, l int) {\n\ttx := []int{x, x + (l * 3), x, x - (l * 3), x}\n\tty := []int{y, y + (l * 2), y + (l * 4), y + (l * 2), y}\n\n\tlx := []int{x - (l * 3), x, x, x - (l * 3), x - (l * 3)}\n\tly := []int{y + (l * 2), y + (l * 4), y + (l * 8), y + (l * 6), y + (l * 2)}\n\n\trx := []int{x + (l * 3), x + (l * 3), x, x, x + (l * 3)}\n\try := []int{y + (l * 2), y + (l * 6), y + (l * 8), y + (l * 4), y + (l * 2)}\n\n\tcanvas.Polygon(tx, ty, randcolor())\n\tcanvas.Polygon(lx, ly, randcolor())\n\tcanvas.Polygon(rx, ry, randcolor())\n}", "func (r *Robot) Paint(grid Grid, v int64) {\n\tgrid[r.Pos] = v == 1\n}" ]
[ "0.6419761", "0.63266224", "0.6249813", "0.60190547", "0.6001477", "0.586602", "0.5684156", "0.56382644", "0.56131184", "0.5407927", "0.5405326", "0.52320653", "0.5171175", "0.50993764", "0.5087996", "0.5048353", "0.50385576", "0.50358623", "0.50173783", "0.5014067", "0.49500734", "0.49163026", "0.49129426", "0.49011806", "0.48925847", "0.4887815", "0.4795089", "0.47696325", "0.47683343", "0.4735198", "0.47346127", "0.47298422", "0.47049925", "0.46718183", "0.46519", "0.46501186", "0.46293768", "0.46218264", "0.46200192", "0.46167284", "0.45847777", "0.4559469", "0.45553967", "0.45499367", "0.4534747", "0.45223126", "0.45161596", "0.45142817", "0.45108035", "0.4496508", "0.44866356", "0.44727412", "0.44688815", "0.4466658", "0.44642514", "0.4460032", "0.44453126", "0.44442055", "0.44250065", "0.4408647", "0.44077656", "0.44054887", "0.4400775", "0.43924448", "0.43916827", "0.4374234", "0.4371338", "0.43679842", "0.4366728", "0.43631783", "0.43616086", "0.4342477", "0.4334511", "0.43260062", "0.4324166", "0.4323961", "0.43192837", "0.43189254", "0.43141684", "0.4303542", "0.42907768", "0.4289595", "0.4287076", "0.42863223", "0.42831838", "0.42672148", "0.4259086", "0.4258924", "0.42535523", "0.42499095", "0.42497057", "0.42495072", "0.42490456", "0.42483267", "0.42483148", "0.42468107", "0.42443693", "0.42404497", "0.4228294" ]
0.5742994
7
specify a plane against which all geometry is clipped
func ClipPlane(plane uint32, equation *float64) { C.glowClipPlane(gpClipPlane, (C.GLenum)(plane), (*C.GLdouble)(unsafe.Pointer(equation))) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func ClipPlane(plane uint32, equation *float64) {\n\tsyscall.Syscall(gpClipPlane, 2, uintptr(plane), uintptr(unsafe.Pointer(equation)), 0)\n}", "func ClipPlane(plane uint32, equation *float64) {\n C.glowClipPlane(gpClipPlane, (C.GLenum)(plane), (*C.GLdouble)(unsafe.Pointer(equation)))\n}", "func GetClipPlane(plane uint32, equation *float64) {\n C.glowGetClipPlane(gpGetClipPlane, (C.GLenum)(plane), (*C.GLdouble)(unsafe.Pointer(equation)))\n}", "func GetClipPlane(plane uint32, equation *float64) {\n\tC.glowGetClipPlane(gpGetClipPlane, (C.GLenum)(plane), (*C.GLdouble)(unsafe.Pointer(equation)))\n}", "func GetClipPlane(plane uint32, equation *float64) {\n\tsyscall.Syscall(gpGetClipPlane, 2, uintptr(plane), uintptr(unsafe.Pointer(equation)), 0)\n}", "func (obj *Device) SetClipPlane(index uint32, plane [4]float32) Error {\n\tret, _, _ := syscall.Syscall(\n\t\tobj.vtbl.SetClipPlane,\n\t\t3,\n\t\tuintptr(unsafe.Pointer(obj)),\n\t\tuintptr(index),\n\t\tuintptr(unsafe.Pointer(&plane[0])),\n\t)\n\treturn toErr(ret)\n}", "func IntersectPlane( plane_p, plane_n Vec3D, lineStart , lineEnd Vec3D ) Vec3D {\n plane_n = plane_n.Normalize()\n plane_d := -plane_n.Dot( plane_p)\n ad := lineStart.Dot(plane_n)\n bd := lineEnd.Dot(plane_n)\n t := (-plane_d - ad) / (bd - ad)\n lineStartToEnd := lineEnd.Sub(lineStart)\n lineToIntersect := lineStartToEnd.Mul(t)\n return lineStart.Add(lineToIntersect)\n}", "func (r Rectangle) Clip(pts []Point) []Point {\n\tclipped := make([]Point, 0, len(pts))\n\tfor _, pt := range pts {\n\t\tif pt.In(r) {\n\t\t\tclipped = append(clipped, pt)\n\t\t}\n\t}\n\treturn clipped\n}", "func make_plane(tWidth, tHeight uint32, vertices []float32, indices []uint32) {\n\t// width and height are the number of triangles across and down\n\t// plus one for the vertices to define them\n\ttWidth++\n\ttHeight++\n\n\tvar makeIsland = true\n\tvar heightMap = make([]float32, tWidth*tHeight)\n\tmake_height_map(tWidth, tHeight, heightMap, makeIsland)\n\tvar x, y uint32\n\tvar scale float32\n\tscale = 2.0 / float32(plane_rows)\n\thScale := scale * 2\n\t//var fbTexScale = float32(cols / width)\n\tvar fbTexScale = float32(1.0)\n\t// Set up vertices\n\tfor y = 0; y < tHeight; y++ {\n\t\tbase := y * tWidth\n\t\tfor x = 0; x < tWidth; x++ {\n\t\t\tindex := base + x\n\t\t\t// Position\n\t\t\tvertices[(8 * index)] = float32(x)*scale - 1.0\n\t\t\tvertices[(8*index)+1] = float32(y)*scale - 1.0\n\t\t\tvertices[(8*index)+2] = heightMap[index] * hScale\n\t\t\t// Colours\n\t\t\tvertices[(8*index)+3] = float32(1.0)\n\t\t\tvertices[(8*index)+4] = float32(1.0)\n\t\t\tvertices[(8*index)+5] = float32(1.0)\n\t\t\t// Texture\n\t\t\tvertices[(8*index)+6] = fbTexScale * float32(x) / float32(tWidth-1)\n\t\t\tvertices[(8*index)+7] = fbTexScale * float32(y) / float32(tHeight-1)\n\t\t\t/*fmt.Printf(\"%d: Ver ( %.2f, %.2f, %.2f ) / Col ( %.2f %.2f %.2f ) / Text ( %.2f, %.2f )\\n\",\n\t\t\tindex, vertices[(8*index)+0], vertices[(8*index)+1], vertices[(8*index)+2],\n\t\t\tvertices[(8*index)+3], vertices[(8*index)+4], vertices[(8*index)+5],\n\t\t\tvertices[(8*index)+6], vertices[(8*index)+7])*/\n\t\t}\n\t}\n\n\t// Set up indices\n\ti := 0\n\ttHeight--\n\tfor y = 0; y < tHeight; y++ {\n\t\tbase := y * tWidth\n\n\t\t//indices[i++] = (uint16)base;\n\t\tfor x = 0; x < tWidth; x++ {\n\t\t\tindices[i] = (uint32)(base + x)\n\t\t\ti += 1\n\t\t\tindices[i] = (uint32)(base + tWidth + x)\n\t\t\ti += 1\n\t\t}\n\t\t// add a degenerate triangle (except in a last row)\n\t\tif y < tHeight-1 {\n\t\t\tindices[i] = (uint32)((y+1)*tWidth + (tWidth - 1))\n\t\t\ti += 1\n\t\t\tindices[i] = (uint32)((y + 1) * tWidth)\n\t\t\ti += 1\n\t\t}\n\t}\n\n\t/*var ind int\n\tfor ind = 0; ind < i; ind++ {\n\t\tfmt.Printf(\"%d \", indices[ind])\n\t}\n\tfmt.Printf(\"\\nIn total %d indices\\n\", ind)*/\n}", "func (p *Plane3D) isBounded() bool {\n\n\treturn false\n}", "func (f *APIAuditFilter) WherePlane(p entql.StringP) {\n\tf.Where(p.Field(apiaudit.FieldPlane))\n}", "func clip(dst draw.Image, r *image.Rectangle, src image.Image, sp *image.Point) {\n\torig := r.Min\n\t*r = r.Intersect(dst.Bounds())\n\t*r = r.Intersect(src.Bounds().Add(orig.Sub(*sp)))\n\tdx := r.Min.X - orig.X\n\tdy := r.Min.Y - orig.Y\n\tif dx == 0 && dy == 0 {\n\t\treturn\n\t}\n\t(*sp).X += dx\n\t(*sp).Y += dy\n}", "func clip(dst Image, r *image.Rectangle, src image.Image, sp *image.Point, mask image.Image, mp *image.Point) {\n\torig := r.Min\n\t*r = r.Intersect(dst.Bounds())\n\t*r = r.Intersect(src.Bounds().Add(orig.Sub(*sp)))\n\tif mask != nil {\n\t\t*r = r.Intersect(mask.Bounds().Add(orig.Sub(*mp)))\n\t}\n\tdx := r.Min.X - orig.X\n\tdy := r.Min.Y - orig.Y\n\tif dx == 0 && dy == 0 {\n\t\treturn\n\t}\n\tsp.X += dx\n\tsp.Y += dy\n\tif mp != nil {\n\t\tmp.X += dx\n\t\tmp.Y += dy\n\t}\n}", "func (p Plane) Bound(Transform) AABB {\n\treturn NewAABB(\n\t\tVector{\n\t\t\t-math.MaxFloat32,\n\t\t\t-math.MaxFloat32,\n\t\t\t-math.MaxFloat32},\n\t\tVector{\n\t\t\tmath.MaxFloat32,\n\t\t\tmath.MaxFloat32,\n\t\t\tmath.MaxFloat32},\n\t)\n}", "func (p plane) splitPolygon(poly polygon, coplanarFront, coplanarBack, front, back *[]polygon) {\n\tconst (\n\t\tcoplanarType = 0\n\t\tfrontType = 1\n\t\tbackType = 2\n\t\tspanningType = 3\n\t)\n\tpolygonType := 0\n\tvar types []int\n\tfor _, v := range poly.vertices {\n\t\tt := p.normal.dot(v.pos) - p.w\n\t\tvar pType int\n\t\tif t < -planeEpsilon {\n\t\t\tpType = backType\n\t\t} else {\n\t\t\tif t > planeEpsilon {\n\t\t\t\tpType = frontType\n\t\t\t} else {\n\t\t\t\tpType = coplanarType\n\t\t\t}\n\t\t}\n\t\tpolygonType |= pType\n\t\ttypes = append(types, pType)\n\t}\n\tswitch polygonType {\n\tcase coplanarType:\n\t\tif p.normal.dot(poly.plane.normal) > 0 {\n\t\t\t*coplanarFront = append(*coplanarFront, poly)\n\t\t} else {\n\t\t\t*coplanarBack = append(*coplanarBack, poly)\n\t\t}\n\tcase frontType:\n\t\t*front = append(*front, poly)\n\tcase backType:\n\t\t*back = append(*back, poly)\n\tcase spanningType:\n\t\tvar f, b []vertex\n\t\tfor i, vi := range poly.vertices {\n\t\t\tj := (i + 1) % len(poly.vertices) // next vertex of polygon (wraps over)\n\t\t\tti := types[i]\n\t\t\ttj := types[j]\n\t\t\tvj := poly.vertices[j]\n\t\t\tif ti != backType {\n\t\t\t\tf = append(f, vi)\n\t\t\t}\n\t\t\tif ti != frontType {\n\t\t\t\tb = append(b, vi)\n\t\t\t}\n\t\t\tif (ti | tj) == spanningType {\n\t\t\t\tt := (p.w - p.normal.dot(vi.pos)) / p.normal.dot(vj.pos.minus(vi.pos))\n\t\t\t\tv := vi.interpolated(vj, t)\n\t\t\t\tf = append(f, v)\n\t\t\t\tb = append(b, v)\n\t\t\t}\n\t\t}\n\t\tif len(f) >= 3 {\n\t\t\t*front = append(*front, newPolygon(f, poly.shared))\n\t\t}\n\t\tif len(b) >= 3 {\n\t\t\t*back = append(*back, newPolygon(b, poly.shared))\n\t\t}\n\t}\n}", "func clampPlaneExtension(index, limit int) int {\n\tif index >= limit {\n\t\tindex = limit - 1\n\t} else if index < 0 {\n\t\tindex = 0\n\t}\n\treturn index\n}", "func (r Rectangle) Clip(r1 Rectangle) Rectangle {\n\tif r.Empty() {\n\t\treturn r\n\t}\n\tif r1.Empty() {\n\t\treturn r1\n\t}\n\tif !r.Overlaps(r1) {\n\t\treturn Rectangle{r.Min, r.Min}\n\t}\n\tif r.Min.X < r1.Min.X {\n\t\tr.Min.X = r1.Min.X\n\t}\n\tif r.Min.Y < r1.Min.Y {\n\t\tr.Min.Y = r1.Min.Y\n\t}\n\tif r.Max.X > r1.Max.X {\n\t\tr.Max.X = r1.Max.X\n\t}\n\tif r.Max.Y > r1.Max.Y {\n\t\tr.Max.Y = r1.Max.Y\n\t}\n\treturn r\n}", "func NewPlane() *Mesh {\n\n\tmesh := NewMesh(\"Plane\",\n\t\tNewVertex(1, 0, -1, 1, 0),\n\t\tNewVertex(1, 0, 1, 1, 1),\n\t\tNewVertex(-1, 0, -1, 0, 0),\n\n\t\tNewVertex(-1, 0, -1, 0, 0),\n\t\tNewVertex(1, 0, 1, 1, 1),\n\t\tNewVertex(-1, 0, 1, 0, 1),\n\t)\n\n\treturn mesh\n\n}", "func NewPlane(corner1 rays.Point, corner2 rays.Point, corner3 rays.Point, color rays.Point) Plane {\n\tp := Plane{Color: color, CornerOne: corner1, CornerTwo: corner2, CornerThree: corner3}\n\n\tp.normal = calcNormal(p)\n\n\treturn p\n}", "func (me *Frustum) UpdatePlanesGH(mat *unum.Mat4, normalize bool) {\n\t// Left clipping plane\n\tme.Planes[0].X = mat[12] + mat[0]\n\tme.Planes[0].Y = mat[13] + mat[1]\n\tme.Planes[0].Z = mat[14] + mat[2]\n\tme.Planes[0].W = mat[15] + mat[3]\n\t// Right clipping plane\n\tme.Planes[1].X = mat[12] - mat[0]\n\tme.Planes[1].Y = mat[13] - mat[1]\n\tme.Planes[1].Z = mat[14] - mat[2]\n\tme.Planes[1].W = mat[15] - mat[3]\n\t// Bottom clipping plane\n\tme.Planes[2].X = mat[12] + mat[4]\n\tme.Planes[2].Y = mat[13] + mat[5]\n\tme.Planes[2].Z = mat[14] + mat[6]\n\tme.Planes[2].W = mat[15] + mat[7]\n\t// Top clipping plane\n\tme.Planes[3].X = mat[12] - mat[4]\n\tme.Planes[3].Y = mat[13] - mat[5]\n\tme.Planes[3].Z = mat[14] - mat[6]\n\tme.Planes[3].W = mat[15] - mat[7]\n\t// Near clipping plane\n\tme.Planes[4].X = mat[12] + mat[8]\n\tme.Planes[4].Y = mat[13] + mat[9]\n\tme.Planes[4].Z = mat[14] + mat[10]\n\tme.Planes[4].W = mat[15] + mat[11]\n\t// Far clipping plane\n\tme.Planes[5].X = mat[12] - mat[8]\n\tme.Planes[5].Y = mat[13] - mat[9]\n\tme.Planes[5].Z = mat[14] - mat[10]\n\tme.Planes[5].W = mat[15] - mat[11]\n\tif normalize {\n\t\tfor i := 0; i < len(me.Planes); i++ {\n\t\t\tme.Planes[i].Normalize()\n\t\t}\n\t}\n}", "func (s Surface) RestrictTo(level level) error {\n\tC.cairo_ps_surface_restrict_to_level(s.XtensionRaw(), level.c())\n\treturn s.Err()\n}", "func System(engine *gosge.Engine, gs geometry.Scale, dr geometry.Size) error {\n\tps := planeSystem{\n\t\tgs: gs,\n\t\tdr: dr,\n\t\tplane: nil,\n\t}\n\n\treturn ps.load(engine)\n}", "func (obj *Device) GetClipPlane(index uint32) (plane [4]float32, err Error) {\n\tret, _, _ := syscall.Syscall(\n\t\tobj.vtbl.GetClipPlane,\n\t\t3,\n\t\tuintptr(unsafe.Pointer(obj)),\n\t\tuintptr(index),\n\t\tuintptr(unsafe.Pointer(&plane[0])),\n\t)\n\terr = toErr(ret)\n\treturn\n}", "func ClipControl(origin uint32, depth uint32) {\n\tsyscall.Syscall(gpClipControl, 2, uintptr(origin), uintptr(depth), 0)\n}", "func NewPlane() *Plane {\n\tself := Plane{}\n\tself.SetDefaults()\n\treturn &self\n}", "func ControlPlanes(controlPlanes int) CreateOption {\n\treturn func(c *CreateOptions) {\n\t\tc.controlPlanes = controlPlanes\n\t}\n}", "func ClonePlaneSlice(dst, src []Plane) {\n\tfor i := range src {\n\t\tdst[i] = *src[i].Clone()\n\t}\n}", "func NewPlane(name string, client sleepwalker.RESTClient) Plane {\n\tdesc := \"airstrike.NewPlane\"\n\tlog.WithFields(map[string]interface{}{\n\t\t\"name\": name,\n\t\t\"client\": client,\n\t}).Debug(desc)\n\treturn Plane{Name: name, Client: client}\n}", "func (r Rectangle) Sub(p Point) Rectangle { return Rectangle{r.Min.Sub(p), r.Max.Sub(p)} }", "func (c *canvasRenderer) Clip() {\n\tc.clipPath(c.canvasPath)\n}", "func (c *canvasRenderer) SetClipRect(left, right, top, bottom float32) {\n\tc.currentLayer.ClipTransform = sprec.Mat4Prod(\n\t\tsprec.NewMat4(\n\t\t\t1.0, 0.0, 0.0, -left,\n\t\t\t-1.0, 0.0, 0.0, right,\n\t\t\t0.0, 1.0, 0.0, -top,\n\t\t\t0.0, -1.0, 0.0, bottom,\n\t\t),\n\t\tsprec.InverseMat4(c.currentLayer.Transform),\n\t)\n}", "func (c *Camera) santizeBounds() {\n\t// x and y\n\tif c.x < 0 {\n\t\tc.x = 0\n\t}\n\tif c.y < 0 {\n\t\tc.y = 0\n\t}\n\tif c.x+c.width > c.worldWidth {\n\t\tc.x = c.worldWidth - c.width\n\t}\n\tif c.y+c.height > c.worldHeight {\n\t\tc.y = c.worldHeight - c.height\n\t}\n\n\t// width and height\n\tif c.width < 100 {\n\t\tc.width = 100\n\t}\n\tif c.height < 100 {\n\t\tc.height = 100\n\t}\n\tif c.width > c.worldWidth {\n\t\tc.width = c.worldWidth\n\t}\n\tif c.height > c.worldHeight {\n\t\tc.height = c.worldHeight\n\t}\n}", "func (p *Plane3D) boundingBox() *BoundingBox3D {\n\n\treturn NewBoundingBox3D(Vector3D.NewVector(0, 0, 0), Vector3D.NewVector(0, 0, 0))\n}", "func ClipRange(in Res, min, max anyvec.Numeric) Res {\n\treturn Pool(in, func(in Res) Res {\n\t\thighEnough, lowEnough := in.Output().Copy(), in.Output().Copy()\n\t\tanyvec.GreaterThan(highEnough, min)\n\t\tanyvec.LessThan(lowEnough, max)\n\n\t\tmidRange := highEnough.Copy()\n\t\tmidRange.Mul(lowEnough)\n\t\tmiddlePart := Mul(in, NewConst(midRange))\n\n\t\tanyvec.Complement(lowEnough)\n\t\tlowEnough.Scale(max)\n\t\tanyvec.Complement(highEnough)\n\t\thighEnough.Scale(min)\n\t\treturn Add(\n\t\t\tmiddlePart,\n\t\t\tAdd(\n\t\t\t\tNewConst(lowEnough),\n\t\t\t\tNewConst(highEnough),\n\t\t\t),\n\t\t)\n\t})\n}", "func (p *Plane3D) isInside(otherPoint *Vector3D.Vector3D) bool {\n\n\treturn p.isNormalFlipped == !p.isInsideLocal(p.transform.toLocal(otherPoint))\n}", "func clipperPath(p data.Path) clipper.Path {\n\tvar result clipper.Path\n\tfor _, point := range p {\n\t\tresult = append(result, clipperPoint(point))\n\t}\n\n\treturn result\n}", "func CreateFilterRing(m *model3d.Mesh) *model3d.Mesh {\n\tcollider := model3d.MeshToCollider(m)\n\n\t// Pick a z-axis where we can slice the ring.\n\tsliceZ := 2 + m.Min().Z\n\t// Scale up the bitmap to get accurate resolution.\n\tconst scale = 20\n\n\tlog.Println(\"Tracing ring outline...\")\n\tmin := m.Min()\n\tsize := m.Max().Sub(min)\n\tbitmap := model2d.NewBitmap(int(size.X*scale), int(size.Y*scale))\n\tfor y := 0; y < bitmap.Height; y++ {\n\t\tfor x := 0; x < bitmap.Width; x++ {\n\t\t\trealX := min.X + float64(x)/scale\n\t\t\trealY := min.Y + float64(y)/scale\n\t\t\tnumColl := collider.RayCollisions(&model3d.Ray{\n\t\t\t\tOrigin: model3d.XYZ(realX, realY, sliceZ),\n\t\t\t\tDirection: model3d.X(1),\n\t\t\t}, nil)\n\t\t\tnumColl1 := collider.RayCollisions(&model3d.Ray{\n\t\t\t\tOrigin: model3d.XYZ(realX, realY, sliceZ),\n\t\t\t\tDirection: model3d.Coord3D{X: -1},\n\t\t\t}, nil)\n\t\t\tbitmap.Set(x, y, numColl == 2 && numColl1 == 2)\n\t\t}\n\t}\n\n\tsolid := NewRingSolid(bitmap, scale)\n\tsqueeze := &toolbox3d.AxisSqueeze{\n\t\tAxis: toolbox3d.AxisZ,\n\t\tMin: 1,\n\t\tMax: 4.5,\n\t\tRatio: 0.1,\n\t}\n\tlog.Println(\"Creating mesh...\")\n\tmesh := model3d.MarchingCubesConj(solid, 0.1, 8, squeeze)\n\tlog.Println(\"Done creating mesh...\")\n\tmesh = mesh.FlattenBase(0)\n\tmesh = mesh.EliminateCoplanar(1e-8)\n\treturn mesh\n}", "func (self *Graphics) AutoCull() bool{\n return self.Object.Get(\"autoCull\").Bool()\n}", "func MakeClippingAV(d []float64, m int) []float64 {\n\tav := make([]float64, len(d)-m+1)\n\tmaxVal, minVal := floats.Max(d), floats.Min(d)\n\tvar numClip int\n\tfor i := 0; i < len(d)-m+1; i++ {\n\t\tnumClip = 0\n\t\tfor j := 0; j < m; j++ {\n\t\t\tif d[i+j] == maxVal || d[i+j] == minVal {\n\t\t\t\tnumClip++\n\t\t\t}\n\t\t}\n\t\tav[i] = float64(numClip)\n\t}\n\n\tminVal = floats.Min(av)\n\tfor i := 0; i < len(av); i++ {\n\t\tav[i] -= minVal\n\t}\n\n\tmaxVal = floats.Max(av)\n\tfor i := 0; i < len(av); i++ {\n\t\tav[i] = 1 - av[i]/maxVal\n\t}\n\n\treturn av\n}", "func NewPlane() *Plane {\n\tpl := &Plane{\n\t\tObject: *NewObject(),\n\t}\n\treturn pl\n}", "func (cp *ControlPlane) Clone() data.Clonable {\n\treturn newControlPlane().Replace(cp)\n}", "func (p *Plane) Scale(scaleVec mgl32.Vec3) {\n\tp.model.Scale = scaleVec\n\tp.centroid = CalculateCentroid(p.vertexValues.Vertices, p.model.Scale)\n\tp.boundingBox = ScaleBoundingBox(p.boundingBox, scaleVec)\n}", "func (t *Terrain) CutAround(x, y, w int) {\n\tfor i := x; i < x+w; i++ {\n\t\tif len(t.columns[i]) == 0 {\n\t\t\tcontinue\n\t\t}\n\t\tcolY := t.HeightOn(i)\n\t\tif colY < y {\n\t\t\tt.cutter.CutFromTop(i, y-colY)\n\t\t}\n\t}\n}", "func (self *Viewport) Reshape(width int, height int) {\n\tself.selectionDirty = false\n\tself.screenWidth = width\n\tself.screenHeight = height\n\n\tgl.Viewport(0, 0, width, height)\n\n\tviewWidth := float64(self.screenWidth) / float64(SCREEN_SCALE)\n\tviewHeight := float64(self.screenHeight) / float64(SCREEN_SCALE)\n\n\tself.lplane = -viewWidth / 2\n\tself.rplane = viewWidth / 2\n\tself.bplane = -viewHeight / 4\n\tself.tplane = 3 * viewHeight / 4\n\n\tgl.MatrixMode(gl.PROJECTION)\n\tgl.LoadIdentity()\n\tgl.Ortho(self.lplane, self.rplane, self.bplane, self.tplane, -60, 60)\n\n\t// self.Perspective(90, 1, 0.01,1000);\n\n\tgl.MatrixMode(gl.MODELVIEW)\n\tgl.LoadIdentity()\n\tpicker.x = float32(viewport.rplane) - picker.radius + BLOCK_SCALE*0.5\n\tpicker.y = float32(viewport.bplane) + picker.radius - BLOCK_SCALE*0.5\n\n}", "func newPlane(mk, mdl string) *plane {\n\tp := &plane{}\n\tp.make = mk\n\tp.model = mdl\n\treturn p\n}", "func (s *Surface) ClipPath(p *Path) {\n\ts.Ctx.Call(\"clip\", p.obj)\n}", "func convolvePlane(planePtr *[]float32, kernel *ConvKernel, width, height int, toPlaneCoords planeExtension) *[]float32 {\n\n\tplane := *planePtr\n\tradius := kernel.Radius\n\tdiameter := radius*2 + 1\n\tres := make([]float32, width*height)\n\n\t// for each pixel of the intensity plane:\n\tfor y := 0; y < height; y++ {\n\t\tfor x := 0; x < width; x++ {\n\t\t\tindex := y*width + x\n\n\t\t\t// compute convolved value of the pixel:\n\t\t\tresV := float32(0)\n\t\t\tfor yk := 0; yk < diameter; yk++ {\n\t\t\t\typ := toPlaneCoords(y+yk-radius, height)\n\t\t\t\tfor xk := 0; xk < diameter; xk++ {\n\t\t\t\t\txp := toPlaneCoords(x+xk-radius, width)\n\t\t\t\t\tplaneIndex := yp*width + xp\n\t\t\t\t\tkernelIndex := yk*diameter + xk\n\t\t\t\t\tresV += (plane[planeIndex] * kernel.Kernel[kernelIndex])\n\t\t\t\t}\n\t\t\t}\n\t\t\tres[index] = resV\n\t\t}\n\t}\n\n\treturn &res\n}", "func (s *Stream) AlphaPlaneSize() int {\n\tif s.Chroma == \"444alpha\" {\n\t\treturn s.Width * s.Height\n\t}\n\treturn 0\n}", "func ClipControl(origin uint32, depth uint32) {\n\tC.glowClipControl(gpClipControl, (C.GLenum)(origin), (C.GLenum)(depth))\n}", "func ClipControl(origin uint32, depth uint32) {\n\tC.glowClipControl(gpClipControl, (C.GLenum)(origin), (C.GLenum)(depth))\n}", "func NewBPlane(o Orbit) BPlane {\n\t// Some of this is quite similar to RV2COE.\n\thHat := Unit(Cross(o.rVec, o.vVec))\n\tk := []float64{0, 0, 1}\n\tv := Norm(o.vVec)\n\tr := Norm(o.rVec)\n\teVec := make([]float64, 3, 3)\n\tfor i := 0; i < 3; i++ {\n\t\teVec[i] = ((v*v-o.Origin.μ/r)*o.rVec[i] - Dot(o.rVec, o.vVec)*o.vVec[i]) / o.Origin.μ\n\t}\n\te := Norm(eVec)\n\tξ := (v*v)/2 - o.Origin.μ/r\n\ta := -o.Origin.μ / (2 * ξ)\n\tc := a * e\n\tb := math.Sqrt(math.Pow(c, 2) - math.Pow(a, 2))\n\n\t// Compute B plane frame\n\theVec := Unit(Cross(hHat, eVec))\n\tβ := math.Acos(1 / e)\n\tsinβ, cosβ := math.Sincos(β)\n\tsHat := make([]float64, 3)\n\tfor i := 0; i < 3; i++ {\n\t\tsHat[i] = cosβ*eVec[i]/e + sinβ*heVec[i]\n\t}\n\ttHat := Unit(Cross(sHat, k))\n\trHat := Unit(Cross(sHat, tHat))\n\tbVec := Cross(sHat, hHat)\n\tfor i := 0; i < 3; i++ {\n\t\tbVec[i] *= b\n\t}\n\tbT := Dot(bVec, tHat)\n\tbR := Dot(bVec, rHat)\n\tνB := math.Pi/2 - β\n\tsinνB, cosνB := math.Sincos(νB)\n\tνR := math.Acos((-a*(e*e-1))/(r*e) - 1/e)\n\tsinνR, cosνR := math.Sincos(νR)\n\n\tfB := math.Asinh(sinνB*math.Sqrt(e*e-1)) / (1 + e*cosνB)\n\tfR := math.Asinh(sinνR*math.Sqrt(e*e-1)) / (1 + e*cosνR)\n\tltof := ((e*math.Sinh(fB) - fB) - (e*math.Sinh(fR) - fR)) / o.MeanAnomaly()\n\treturn BPlane{Orbit: o, BR: bR, BT: bT, LTOF: ltof, goalBT: math.NaN(), goalBR: math.NaN(), goalLTOF: math.NaN()}\n}", "func (v *Vec3i) SetSub(other Vec3i) {\n\tv.X -= other.X\n\tv.Y -= other.Y\n\tv.Z -= other.Z\n}", "func ControlPlane() *ControlPlaneContract {\n\tonceControlPlane.Do(func() {\n\t\tcontrolPlane = &ControlPlaneContract{}\n\t})\n\treturn controlPlane\n}", "func (v Vector3D) Sub(other Vector3D) Vector3D {\n\treturn Vector3D{\n\t\tx: v.x - other.x,\n\t\ty: v.y - other.y,\n\t\tz: v.z - other.z,\n\t}\n}", "func (p *Point) Sub(p2 Point) {\n\tp.X -= p2.X\n\tp.Y -= p2.Y\n\tp.Z -= p2.Z\n}", "func (qh *QuickHull) createConvexHalfEdgeMesh() {\n\tvar visibleFaces []int\n\tvar horizontalEdges []int\n\n\ttype faceData struct {\n\t\tfaceIndex int\n\t\tenteredFromHalfEdge int // If the Face turns out not to be visible, this half edge will be marked as horizon edge\n\t}\n\n\tvar possiblyVisibleFaces []faceData\n\n\t// Compute base tetrahedron\n\tqh.mesh = qh.initialTetrahedron()\n\tassertTrue(len(qh.mesh.faces) == 4)\n\n\tvar faceList []int\n\tfor i := 0; i < 4; i++ {\n\t\tf := &qh.mesh.faces[i]\n\t\tif len(f.pointsOnPositiveSide) > 0 {\n\t\t\tfaceList = append(faceList, i)\n\t\t\tf.inFaceStack = true\n\t\t}\n\t}\n\n\t// Process Faces until the Face list is empty.\n\titer := 0\n\tfor len(faceList) > 0 {\n\t\titer++\n\t\tif iter == maxInt {\n\t\t\t// Visible Face traversal marks visited Faces with iteration counter (to mark that the Face has been visited on this iteration) and the max value represents unvisited Faces. At this point we have to reset iteration counter. This shouldn't be an\n\t\t\t// issue on 64 bit machines.\n\t\t\titer = 0\n\t\t}\n\n\t\tvar topFaceIndex int\n\t\ttopFaceIndex, faceList = faceList[0], faceList[1:]\n\n\t\ttf := &qh.mesh.faces[topFaceIndex]\n\t\ttf.inFaceStack = false\n\n\t\tassertTrue(tf.pointsOnPositiveSide == nil || len(tf.pointsOnPositiveSide) > 0)\n\t\tif tf.pointsOnPositiveSide == nil || tf.isDisabled() {\n\t\t\tcontinue\n\t\t}\n\n\t\t// Pick the most distant point to this triangle plane as the point to which we extrude\n\t\tactivePoint := qh.vertexData[tf.mostDistantPoint]\n\t\tactivePointIndex := tf.mostDistantPoint\n\n\t\t// Clear outer vars\n\t\thorizontalEdges = horizontalEdges[:0]\n\t\tvisibleFaces = visibleFaces[:0]\n\t\tpossiblyVisibleFaces = possiblyVisibleFaces[:0]\n\n\t\t// Find out the Faces that have our active point on their positive side (these are the \"visible Faces\").\n\t\t// The Face on top of the stack of course is one of them. At the same time, we create a list of horizon edges.\n\t\tpossiblyVisibleFaces = append(possiblyVisibleFaces, faceData{faceIndex: topFaceIndex, enteredFromHalfEdge: maxInt})\n\t\tfor len(possiblyVisibleFaces) > 0 {\n\t\t\tfd := possiblyVisibleFaces[len(possiblyVisibleFaces)-1]\n\t\t\tpossiblyVisibleFaces = possiblyVisibleFaces[:len(possiblyVisibleFaces)-1]\n\t\t\tpvf := &qh.mesh.faces[fd.faceIndex]\n\t\t\tassertTrue(!pvf.isDisabled())\n\n\t\t\tif pvf.visibilityCheckedOnIteration == iter {\n\t\t\t\tif pvf.isVisibleFaceOnCurrentIteration {\n\t\t\t\t\tcontinue\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\tp := pvf.plane\n\t\t\t\tpvf.visibilityCheckedOnIteration = iter\n\t\t\t\td := p.n.Dot(activePoint) + p.d\n\t\t\t\tif d > 0 {\n\t\t\t\t\tpvf.isVisibleFaceOnCurrentIteration = true\n\t\t\t\t\tpvf.horizonEdgesOnCurrentIteration = 0\n\t\t\t\t\tvisibleFaces = append(visibleFaces, fd.faceIndex)\n\n\t\t\t\t\tfor _, heIndex := range qh.mesh.halfEdgeIndicesOfFace(*pvf) {\n\t\t\t\t\t\topp := qh.mesh.halfEdges[heIndex].Opp\n\t\t\t\t\t\tif opp != fd.enteredFromHalfEdge {\n\t\t\t\t\t\t\tpossiblyVisibleFaces = append(possiblyVisibleFaces, faceData{faceIndex: qh.mesh.halfEdges[opp].Face, enteredFromHalfEdge: heIndex})\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\tcontinue\n\t\t\t\t}\n\t\t\t\tassertTrue(fd.faceIndex != topFaceIndex)\n\t\t\t}\n\n\t\t\t// The Face is not visible. Therefore, the halfedge we came from is part of the horizon edge.\n\t\t\tpvf.isVisibleFaceOnCurrentIteration = false\n\t\t\thorizontalEdges = append(horizontalEdges, fd.enteredFromHalfEdge)\n\n\t\t\t// Store which half edge is the horizon edge. The other half edges of the Face will not be part of the final mesh so their data slots can by recycled.\n\t\t\thalfEdges := qh.mesh.halfEdgeIndicesOfFace(qh.mesh.faces[qh.mesh.halfEdges[fd.enteredFromHalfEdge].Face])\n\t\t\tvar ind byte\n\t\t\tif halfEdges[0] != fd.enteredFromHalfEdge {\n\t\t\t\tif halfEdges[1] == fd.enteredFromHalfEdge {\n\t\t\t\t\tind = 1\n\t\t\t\t} else {\n\t\t\t\t\tind = 2\n\t\t\t\t}\n\t\t\t}\n\t\t\tqh.mesh.faces[qh.mesh.halfEdges[fd.enteredFromHalfEdge].Face].horizonEdgesOnCurrentIteration |= 1 << ind\n\t\t}\n\n\t\tnHorizontalEdges := len(horizontalEdges)\n\n\t\t// Order horizon edges so that they form a loop. This may fail due to numerical instability in which case we give up trying to solve horizon edge for this point and accept a minor degeneration in the convex hull.\n\t\tif !qh.reorderHorizontalEdges(horizontalEdges) {\n\t\t\tqh.diagnostics.failedHorizonEdges++\n\t\t\tlog.Println(\"Failed to solve horizon edge\")\n\n\t\t\tfor i := range tf.pointsOnPositiveSide {\n\t\t\t\tif tf.pointsOnPositiveSide[i] == activePointIndex {\n\t\t\t\t\ttf.pointsOnPositiveSide = append(tf.pointsOnPositiveSide[:i], tf.pointsOnPositiveSide[i+1:]...)\n\t\t\t\t\tbreak\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t/*\n\t\t\t\tTODO: optimize\n\t\t\t\tif len(tf.pointsOnPositiveSide) == 0 {\n\t\t\t\t\treclaimToIndexVectorPool(tf.m_pointsOnPositiveSide);\n\t\t\t\t}\n\t\t\t*/\n\t\t\tcontinue\n\t\t}\n\n\t\t// Except for the horizon edges, all half edges of the visible Faces can be marked as disabled. Their data slots will be reused.\n\t\t// The Faces will be disabled as well, but we need to remember the points that were on the positive side of them - therefore\n\t\t// we save pointers to them.\n\t\tqh.newFaceIndices = qh.newFaceIndices[:0]\n\t\tqh.newHalfEdgeIndices = qh.newHalfEdgeIndices[:0]\n\t\tqh.disabledFacePointVectors = qh.disabledFacePointVectors[:0]\n\n\t\tvar nDisabled int\n\t\tfor _, faceIdx := range visibleFaces {\n\t\t\tdisabledFace := qh.mesh.faces[faceIdx]\n\t\t\thalfEdges := qh.mesh.halfEdgeIndicesOfFace(disabledFace)\n\t\t\tfor i := uint(0); i < 3; i++ {\n\t\t\t\tif disabledFace.horizonEdgesOnCurrentIteration&(1<<i) == 0 {\n\t\t\t\t\tif nDisabled < nHorizontalEdges*2 {\n\t\t\t\t\t\t// Use on this iteration\n\t\t\t\t\t\tqh.newHalfEdgeIndices = append(qh.newHalfEdgeIndices, halfEdges[i])\n\t\t\t\t\t\tnDisabled++\n\t\t\t\t\t} else {\n\t\t\t\t\t\t// Mark for reusal on later iteration step\n\t\t\t\t\t\tqh.mesh.disableHalfEdge(halfEdges[i])\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\t// Disable the Face, but retain pointer to the points that were on the positive side of it. We need to assign those points\n\t\t\t// to the new Faces we create shortly.\n\t\t\tt := qh.mesh.disableFace(faceIdx)\n\t\t\tif t != nil {\n\t\t\t\tassertTrue(len(t) > 0)\n\t\t\t\tqh.disabledFacePointVectors = append(qh.disabledFacePointVectors, t)\n\t\t\t}\n\t\t}\n\t\tif nDisabled < nHorizontalEdges*2 {\n\t\t\tnNewHalfEdgesNeeded := nHorizontalEdges*2 - nDisabled\n\t\t\tfor i := 0; i < nNewHalfEdgesNeeded; i++ {\n\t\t\t\tqh.newHalfEdgeIndices = append(qh.newHalfEdgeIndices, qh.mesh.addHalfEdge())\n\t\t\t}\n\t\t}\n\t\t// Create new Faces using the edgeloop\n\t\tfor i := 0; i < nHorizontalEdges; i++ {\n\t\t\tab := horizontalEdges[i]\n\n\t\t\thorizonEdgeVertexIndices := qh.mesh.vertexIndicesOfHalfEdge(qh.mesh.halfEdges[ab])\n\t\t\ta, b, c := horizonEdgeVertexIndices[0], horizonEdgeVertexIndices[1], activePointIndex\n\n\t\t\tnewFaceIdx := qh.mesh.addFace()\n\t\t\tqh.newFaceIndices = append(qh.newFaceIndices, newFaceIdx)\n\n\t\t\tca, bc := qh.newHalfEdgeIndices[2*i+0], qh.newHalfEdgeIndices[2*i+1]\n\n\t\t\tqh.mesh.halfEdges[ab].Next = bc\n\t\t\tqh.mesh.halfEdges[bc].Next = ca\n\t\t\tqh.mesh.halfEdges[ca].Next = ab\n\n\t\t\tqh.mesh.halfEdges[bc].Face = newFaceIdx\n\t\t\tqh.mesh.halfEdges[ca].Face = newFaceIdx\n\t\t\tqh.mesh.halfEdges[ab].Face = newFaceIdx\n\n\t\t\tqh.mesh.halfEdges[ca].EndVertex = a\n\t\t\tqh.mesh.halfEdges[bc].EndVertex = c\n\n\t\t\tnewFace := &qh.mesh.faces[newFaceIdx]\n\n\t\t\tplaneNormal := triangleNormal(qh.vertexData[a], qh.vertexData[b], activePoint)\n\t\t\tnewFace.plane = newPlane(planeNormal, activePoint)\n\t\t\tnewFace.halfEdgeIndex = ab\n\n\t\t\tvar idx int\n\t\t\tif i > 0 {\n\t\t\t\tidx = i*2 - 1\n\t\t\t} else {\n\t\t\t\tidx = 2*nHorizontalEdges - 1\n\t\t\t}\n\t\t\tqh.mesh.halfEdges[ca].Opp = qh.newHalfEdgeIndices[idx]\n\t\t\tqh.mesh.halfEdges[bc].Opp = qh.newHalfEdgeIndices[((i+1)*2)%(nHorizontalEdges*2)]\n\t\t}\n\n\t\tfor _, disabledPoints := range qh.disabledFacePointVectors {\n\t\t\tassertTrue(disabledPoints != nil)\n\t\t\tfor _, pointIdx := range disabledPoints {\n\t\t\t\tif pointIdx == activePointIndex {\n\t\t\t\t\tcontinue\n\t\t\t\t}\n\t\t\t\tfor i := 0; i < nHorizontalEdges; i++ {\n\t\t\t\t\tif qh.addPointToFace(&qh.mesh.faces[qh.newFaceIndices[i]], pointIdx) {\n\t\t\t\t\t\tbreak\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\t/* TODO: optimize\n\t\t\t// The points are no longer needed: we can move them to the vector pool for reuse.\n\t\t\treclaimToIndexVectorPool(disabledPoints);\n\t\t\t*/\n\t\t}\n\t\t// Increase Face stack size if needed\n\t\tfor _, newFaceIdx := range qh.newFaceIndices {\n\t\t\tnewFace := &qh.mesh.faces[newFaceIdx]\n\t\t\tif newFace.pointsOnPositiveSide != nil {\n\t\t\t\tassertTrue(len(newFace.pointsOnPositiveSide) > 0)\n\t\t\t\tif !newFace.inFaceStack {\n\t\t\t\t\tfaceList = append(faceList, newFaceIdx)\n\t\t\t\t\tnewFace.inFaceStack = true\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\t/* TODO: optimize\n\t// Cleanup\n\tm_indexVectorPool.clear();\n\t*/\n}", "func (a *Vec4) Subtract(b Vec4) {\n\ta.X -= b.X\n\ta.Y -= b.Y\n\ta.Z -= b.Z\n\ta.W -= b.W\n}", "func (s *Slicer) PrepareRenderZ() error {\n\tleft := float32(s.irmf.Min[0])\n\tright := float32(s.irmf.Max[0])\n\tbottom := float32(s.irmf.Min[1])\n\ttop := float32(s.irmf.Max[1])\n\tcamera := mgl32.LookAtV(mgl32.Vec3{0, 0, 3}, mgl32.Vec3{0, 0, 0}, mgl32.Vec3{0, 1, 0})\n\tvec3Str := \"fragVert.xy,u_slice\"\n\n\tzPlaneVertices[0], zPlaneVertices[10], zPlaneVertices[25] = left, left, left\n\tzPlaneVertices[5], zPlaneVertices[15], zPlaneVertices[20] = right, right, right\n\tzPlaneVertices[1], zPlaneVertices[6], zPlaneVertices[16] = bottom, bottom, bottom\n\tzPlaneVertices[11], zPlaneVertices[21], zPlaneVertices[26] = top, top, top\n\n\taspectRatio := ((right - left) * s.deltaY) / ((top - bottom) * s.deltaX)\n\tnewWidth := int(0.5 + (right-left)/float32(s.deltaX))\n\tnewHeight := int(0.5 + (top-bottom)/float32(s.deltaY))\n\tlog.Printf(\"aspectRatio=%v, newWidth=%v, newHeight=%v\", aspectRatio, newWidth, newHeight)\n\tif aspectRatio*float32(newHeight) < float32(newWidth) {\n\t\tnewHeight = int(0.5 + float32(newWidth)/aspectRatio)\n\t}\n\n\treturn s.prepareRender(newWidth, newHeight, left, right, bottom, top, camera, vec3Str, zPlaneVertices)\n}", "func (cv *Canvas) Clip() {\n\tcv.clip(&cv.path, matIdentity())\n}", "func (a KubectlLayerApplier) Prune(ctx context.Context, layer layers.Layer, pruneHrs []*helmctlv2.HelmRelease) (err error) {\n\tlogging.TraceCall(a.getLog(layer))\n\tdefer logging.TraceExit(a.getLog(layer))\n\tfor _, hr := range pruneHrs {\n\t\terr := a.client.Delete(ctx, hr, client.PropagationPolicy(metav1.DeletePropagationBackground))\n\t\tif err != nil {\n\t\t\treturn errors.Wrapf(err, \"%s - unable to delete HelmRelease '%s' for AddonsLayer '%s'\",\n\t\t\t\tlogging.CallerStr(logging.Me), getLabel(hr.ObjectMeta), layer.GetName())\n\t\t}\n\t}\n\treturn nil\n}", "func (self *Graphics) SetOutOfCameraBoundsKillA(member bool) {\n self.Object.Set(\"outOfCameraBoundsKill\", member)\n}", "func (self *Rectangle) Aabb(points []Point) *Rectangle{\n return &Rectangle{self.Object.Call(\"aabb\", points)}\n}", "func AllElementsScene(frame int) (*render.Scene, error) {\n\tcamera, err := render.NewCamera(geometry.Ray{geometry.Point{10, 10, 5}, geometry.Vector{-10, -10, -5}},\n\t\tgeometry.Vector{-10, -10, 40}, 30, 0, 1, 1, 2)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\n\tscene := render.Scene{Camera: camera, BackgroundColor: shading.Color{0.1, 0.8, 1}}\n\n\tyzPlane, err := surface.NewPlane(\n\t\tgeometry.Point{0, 0, 0},\n\t\tgeometry.Vector{0, 4, 0},\n\t\tgeometry.Vector{0, 0, 2},\n\t\tshading.ShadingProperties{\n\t\t\tDiffuseTexture: shading.CheckerboardTexture{shading.Color{0.9, 0.1, 0.1}, shading.Color{0.8, 0.8, 0.8}, 1,\n\t\t\t\t0.5},\n\t\t\tOpacity: 1,\n\t\t},\n\t)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\tscene.AddSurface(yzPlane)\n\n\txzPlane, err := surface.NewPlane(\n\t\tgeometry.Point{0, 0, 0},\n\t\tgeometry.Vector{4, 0, 0},\n\t\tgeometry.Vector{0, 0, 2},\n\t\tshading.ShadingProperties{\n\t\t\tDiffuseTexture: shading.CheckerboardTexture{shading.Color{0.2, 0.5, 1}, shading.Color{0, 0, 0}, 0.1, 0.1},\n\t\t\tOpacity: 1,\n\t\t},\n\t)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\tscene.AddSurface(xzPlane)\n\n\txyPlane, err := surface.NewPlane(\n\t\tgeometry.Point{0, 0, 0},\n\t\tgeometry.Vector{4, 0, 0},\n\t\tgeometry.Vector{0, 10, 0},\n\t\tshading.ShadingProperties{\n\t\t\tDiffuseTexture: shading.CheckerboardTexture{shading.Color{0.9, 0.9, 0.9}, shading.Color{0.2, 0.2, 0.2}, 0.3,\n\t\t\t\t0.3},\n\t\t\tOpacity: 1,\n\t\t},\n\t)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\tscene.AddSurface(xyPlane)\n\n\tmirrorSphere, err := surface.NewSphere(\n\t\tgeometry.Point{1.5, 1.5, 0.75},\n\t\t0.5,\n\t\tgeometry.Vector{0, 0, 1},\n\t\tgeometry.Vector{1, 0, 0},\n\t\tshading.ShadingProperties{\n\t\t\tDiffuseTexture: shading.SolidTexture{shading.Color{0.5, 0.5, 0.5}},\n\t\t\tSpecularExponent: 100,\n\t\t\tSpecularIntensity: 0.5,\n\t\t\tOpacity: 1,\n\t\t\tReflectivity: 0.8,\n\t\t},\n\t)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\tscene.AddSurface(mirrorSphere)\n\n\tcheckerboardSphere, err := surface.NewSphere(\n\t\tgeometry.Point{1, 4.4, 1},\n\t\t0.3,\n\t\tgeometry.Vector{0, 1, 0},\n\t\tgeometry.Vector{1, 0, 0},\n\t\tshading.ShadingProperties{\n\t\t\tDiffuseTexture: shading.CheckerboardTexture{\n\t\t\t\tColor1: shading.Color{1, 1, 1},\n\t\t\t\tColor2: shading.Color{0, 0, 1},\n\t\t\t\tUPitch: math.Pi / 2,\n\t\t\t\tVPitch: math.Pi / 4,\n\t\t\t},\n\t\t\tSpecularExponent: 100,\n\t\t\tSpecularIntensity: 0.5,\n\t\t\tOpacity: 1,\n\t\t\tReflectivity: 0.3,\n\t\t},\n\t)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\tscene.AddSurface(checkerboardSphere)\n\n\tcheckerboardDisc, err := surface.NewDisc(\n\t\tgeometry.Point{3, 1, 0.5},\n\t\tgeometry.Vector{0.5, 0, 0},\n\t\tgeometry.Vector{0, 0.5, 0},\n\t\tshading.ShadingProperties{\n\t\t\tDiffuseTexture: shading.CheckerboardTexture{\n\t\t\t\tColor1: shading.Color{0.9, 0.8, 0.4},\n\t\t\t\tColor2: shading.Color{0.3, 0.3, 0},\n\t\t\t\tUPitch: 0.125,\n\t\t\t\tVPitch: math.Pi / 2,\n\t\t\t},\n\t\t\tOpacity: 1,\n\t\t},\n\t)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\tscene.AddSurface(checkerboardDisc)\n\n\tmirrorDisc, err := surface.NewDisc(\n\t\tgeometry.Point{2, 2, 0.1},\n\t\tgeometry.Vector{1.5, 0, 0},\n\t\tgeometry.Vector{0, 1.5, 0},\n\t\tshading.ShadingProperties{\n\t\t\tDiffuseTexture: shading.SolidTexture{shading.Color{0, 0, 0}},\n\t\t\tSpecularExponent: 100,\n\t\t\tSpecularIntensity: 0.5,\n\t\t\tOpacity: 1,\n\t\t\tReflectivity: 0.7,\n\t\t},\n\t)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\tscene.AddSurface(mirrorDisc)\n\n\tgoldCubePlanes, err := surface.NewBox(\n\t\tgeometry.Point{1, 3, 0.75},\n\t\tgeometry.Vector{0, 0.5, 0.5},\n\t\tgeometry.Vector{0, -0.5, 0.5},\n\t\t0.5,\n\t\tshading.ShadingProperties{\n\t\t\tDiffuseTexture: shading.SolidTexture{shading.Color{0.9, 0.6, 0.2}},\n\t\t\tSpecularExponent: 100,\n\t\t\tSpecularIntensity: 0.5,\n\t\t\tOpacity: 1,\n\t\t\tReflectivity: 0.1,\n\t\t},\n\t)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\tfor _, plane := range goldCubePlanes {\n\t\tscene.AddSurface(plane)\n\t}\n\n\tboxPlanes, err := surface.NewBox(\n\t\tgeometry.Point{2.5, 4.3, 0.1},\n\t\tgeometry.Vector{-0.8, 0.6, 0},\n\t\tgeometry.Vector{0, 0, 2},\n\t\t0.05,\n\t\tshading.ShadingProperties{\n\t\t\tDiffuseTexture: shading.SolidTexture{shading.Color{0, 1, 0}},\n\t\t\tSpecularExponent: 100,\n\t\t\tSpecularIntensity: 0.5,\n\t\t\tOpacity: 0.1,\n\t\t\tReflectivity: 0.5,\n\t\t\tRefractiveIndex: 1.1,\n\t\t},\n\t)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\tfor _, plane := range boxPlanes {\n\t\tscene.AddSurface(plane)\n\t}\n\n\tlight1, err := light.NewDistantLight(\n\t\tgeometry.Vector{-10, -10, -20},\n\t\tshading.Color{1, 1, 1},\n\t\t0.75,\n\t\t0,\n\t)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\tscene.AddLight(light1)\n\n\tlight2, err := light.NewDistantLight(\n\t\tgeometry.Vector{-10, -10, -25},\n\t\tshading.Color{1, 1, 1},\n\t\t0.75,\n\t\t0,\n\t)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\tscene.AddLight(light2)\n\n\tlight3, err := light.NewDistantLight(\n\t\tgeometry.Vector{-11, -9, -20},\n\t\tshading.Color{1, 1, 1},\n\t\t0.75,\n\t\t0,\n\t)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\tscene.AddLight(light3)\n\n\tlight4, err := light.NewPointLight(\n\t\tgeometry.Point{5, 1, 10},\n\t\tshading.Color{1, 1, 1},\n\t\t1000,\n\t\t0,\n\t)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\tscene.AddLight(light4)\n\n\treturn &scene, nil\n}", "func (s *Slicer) PrepareRenderY() error {\n\tleft := float32(s.irmf.Min[0])\n\tright := float32(s.irmf.Max[0])\n\tbottom := float32(s.irmf.Min[2])\n\ttop := float32(s.irmf.Max[2])\n\tcamera := mgl32.LookAtV(mgl32.Vec3{0, -3, 0}, mgl32.Vec3{0, 0, 0}, mgl32.Vec3{0, 0, 1})\n\tvec3Str := \"fragVert.x,u_slice,fragVert.z\"\n\n\tyPlaneVertices[0], yPlaneVertices[10], yPlaneVertices[25] = left, left, left\n\tyPlaneVertices[5], yPlaneVertices[15], yPlaneVertices[20] = right, right, right\n\tyPlaneVertices[2], yPlaneVertices[7], yPlaneVertices[17] = bottom, bottom, bottom\n\tyPlaneVertices[12], yPlaneVertices[22], yPlaneVertices[27] = top, top, top\n\n\taspectRatio := ((right - left) * s.deltaZ) / ((top - bottom) * s.deltaX)\n\tnewWidth := int(0.5 + (right-left)/float32(s.deltaX))\n\tnewHeight := int(0.5 + (top-bottom)/float32(s.deltaZ))\n\tlog.Printf(\"aspectRatio=%v, newWidth=%v, newHeight=%v\", aspectRatio, newWidth, newHeight)\n\tif aspectRatio*float32(newHeight) < float32(newWidth) {\n\t\tnewHeight = int(0.5 + float32(newWidth)/aspectRatio)\n\t}\n\n\treturn s.prepareRender(newWidth, newHeight, left, right, bottom, top, camera, vec3Str, yPlaneVertices)\n}", "func Vclip(input []float32, inputStride int, low, high float32, output []float32, outputStride int) {\n\tC.vDSP_vclip((*C.float)(&input[0]), C.vDSP_Stride(inputStride), (*C.float)(&low), (*C.float)(&high), (*C.float)(&output[0]), C.vDSP_Stride(outputStride), minLen(len(input)/inputStride, len(output)/outputStride))\n}", "func (v *Vector) Min(m *Vector) {\n\tif m.X < v.X {\n\t\tv.X = m.X\n\t}\n\tif m.Y < v.Y {\n\t\tv.Y = m.Y\n\t}\n\tif m.Z < v.Z {\n\t\tv.Z = m.Z\n\t}\n}", "func (self *Graphics) SetAutoCullA(member bool) {\n self.Object.Set(\"autoCull\", member)\n}", "func (v *Vec4) Subtract(x *Vec4) {\n\tv.X -= x.X\n\tv.Y -= x.Y\n\tv.Z -= x.Z\n\tv.W -= v.W\n}", "func (m *Mesh) EliminateCoplanarFiltered(epsilon float64, f func(Coord3D) bool) *Mesh {\n\tdec := &decimator{\n\t\tFeatureAngle: math.Acos(1 - epsilon),\n\t\tMinimumAspectRatio: 0.01,\n\t\tCriterion: &normalDecCriterion{\n\t\t\tCosineEpsilon: epsilon,\n\t\t\tFilterFunc: f,\n\t\t},\n\t}\n\treturn dec.Decimate(m)\n}", "func (g *Generator) deselectControlPlane() *Machine {\n\tcountByRack := g.countMachinesByRack(true, \"\")\n\tsort.Slice(g.nextControlPlanes, func(i, j int) bool {\n\t\tsi := scoreMachineWithHealthStatus(g.nextControlPlanes[i], countByRack, g.timestamp)\n\t\tsj := scoreMachineWithHealthStatus(g.nextControlPlanes[j], countByRack, g.timestamp)\n\t\t// lower first\n\t\treturn si < sj\n\t})\n\treturn g.nextControlPlanes[0]\n}", "func (self *PhysicsP2) SetBoundsCollidesWithA(member []interface{}) {\n self.Object.Set(\"boundsCollidesWith\", member)\n}", "func (p *SamplePoint2D) PlaneDistance(planePosition float64, dim int) float64 {\n\treturn math.Abs(planePosition - p.Dimension(dim))\n}", "func (mesh *Mesh) UpdateBounds() {\n\n\tfor _, v := range mesh.Vertices {\n\n\t\tif v.Position[0] < mesh.Dimensions[0][0] {\n\t\t\tmesh.Dimensions[0][0] = v.Position[0]\n\t\t}\n\t\tif v.Position[0] > mesh.Dimensions[1][0] {\n\t\t\tmesh.Dimensions[1][0] = v.Position[0]\n\t\t}\n\n\t\tif v.Position[1] < mesh.Dimensions[0][1] {\n\t\t\tmesh.Dimensions[0][1] = v.Position[1]\n\t\t}\n\t\tif v.Position[1] > mesh.Dimensions[1][1] {\n\t\t\tmesh.Dimensions[1][1] = v.Position[1]\n\t\t}\n\n\t\tif v.Position[2] < mesh.Dimensions[0][2] {\n\t\t\tmesh.Dimensions[0][2] = v.Position[2]\n\t\t}\n\t\tif v.Position[2] > mesh.Dimensions[1][2] {\n\t\t\tmesh.Dimensions[1][2] = v.Position[2]\n\t\t}\n\n\t}\n\n}", "func (p *Plane) Setup(mat Material, mod Model, name string, collide bool, reflective int, refractionIndex float32) error {\n\n\tp.vertexValues.Vertices = []float32{\n\t\t0.0, 0.5, 0.5,\n\t\t0.0, 0.5, 0.0,\n\t\t0.5, 0.5, 0.0,\n\t\t0.5, 0.5, 0.5,\n\t}\n\n\tp.vertexValues.Faces = []uint32{\n\t\t0, 2, 1, 2, 0, 3,\n\t}\n\n\tp.vertexValues.Normals = []float32{\n\t\t0.0, -1.0, 0.0,\n\t\t0.0, -1.0, 0.0,\n\t\t0.0, -1.0, 0.0,\n\t\t0.0, -1.0, 0.0,\n\t}\n\tp.vertexValues.Uvs = []float32{\n\t\t0.0, 0.0,\n\t\t5.0, 0.0,\n\t\t5.0, 5.0,\n\t\t0.0, 5.0,\n\t}\n\n\tp.name = name\n\tp.programInfo = ProgramInfo{}\n\tp.material = mat\n\n\tvar shaderVals map[string]bool\n\tshaderVals = make(map[string]bool)\n\n\tif mat.ShaderType == 0 {\n\t\tshaderVals[\"aPosition\"] = true\n\t\tbS := &shader.BasicShader{}\n\t\tbS.Setup()\n\t\tp.shaderVal = bS\n\t\tp.programInfo.Program = InitOpenGL(p.shaderVal.GetVertShader(), p.shaderVal.GetFragShader(), p.shaderVal.GetGeometryShader())\n\t\tp.programInfo.attributes = Attributes{\n\t\t\tposition: 0,\n\t\t\tnormal: 1,\n\t\t}\n\n\t\tSetupAttributesMap(&p.programInfo, shaderVals)\n\n\t\tp.buffers.Vao = CreateTriangleVAO(&p.programInfo, p.vertexValues.Vertices, nil, nil, nil, nil, p.vertexValues.Faces)\n\n\t} else if mat.ShaderType == 1 {\n\t\tshaderVals[\"aPosition\"] = true\n\t\tshaderVals[\"aNormal\"] = true\n\t\tshaderVals[\"diffuseVal\"] = true\n\t\tshaderVals[\"ambientVal\"] = true\n\t\tshaderVals[\"specularVal\"] = true\n\t\tshaderVals[\"nVal\"] = true\n\t\tshaderVals[\"uProjectionMatrix\"] = true\n\t\tshaderVals[\"uViewMatrix\"] = true\n\t\tshaderVals[\"uModelMatrix\"] = true\n\t\tshaderVals[\"pointLights\"] = true\n\t\tshaderVals[\"cameraPosition\"] = true\n\n\t\tbS := &shader.BlinnNoTexture{}\n\t\tbS.Setup()\n\t\tp.shaderVal = bS\n\t\tp.programInfo.Program = InitOpenGL(p.shaderVal.GetVertShader(), p.shaderVal.GetFragShader(), p.shaderVal.GetGeometryShader())\n\t\tp.programInfo.attributes = Attributes{\n\t\t\tposition: 0,\n\t\t\tnormal: 1,\n\t\t}\n\n\t\tSetupAttributesMap(&p.programInfo, shaderVals)\n\n\t\tp.buffers.Vao = CreateTriangleVAO(&p.programInfo, p.vertexValues.Vertices, p.vertexValues.Normals, nil, nil, nil, p.vertexValues.Faces)\n\n\t} else if mat.ShaderType == 2 {\n\t\tp.programInfo.Program = InitOpenGL(p.shaderVal.GetVertShader(), p.shaderVal.GetFragShader(), p.shaderVal.GetGeometryShader())\n\t\tp.programInfo.attributes = Attributes{\n\t\t\tposition: 0,\n\t\t\tnormal: 1,\n\t\t\tuv: 2,\n\t\t}\n\n\t} else if mat.ShaderType == 3 {\n\t\tshaderVals[\"aPosition\"] = true\n\t\tshaderVals[\"aNormal\"] = true\n\t\tshaderVals[\"aUV\"] = true\n\t\tshaderVals[\"diffuseVal\"] = true\n\t\tshaderVals[\"ambientVal\"] = true\n\t\tshaderVals[\"specularVal\"] = true\n\t\tshaderVals[\"nVal\"] = true\n\t\tshaderVals[\"uProjectionMatrix\"] = true\n\t\tshaderVals[\"uViewMatrix\"] = true\n\t\tshaderVals[\"uModelMatrix\"] = true\n\t\tshaderVals[\"pointLights\"] = true\n\t\tshaderVals[\"cameraPosition\"] = true\n\t\tshaderVals[\"uDiffuseTexture\"] = true\n\n\t\tbS := &shader.BlinnDiffuseTexture{}\n\t\tbS.Setup()\n\t\tp.shaderVal = bS\n\t\tp.programInfo.Program = InitOpenGL(p.shaderVal.GetVertShader(), p.shaderVal.GetFragShader(), p.shaderVal.GetGeometryShader())\n\t\tp.programInfo.attributes = Attributes{\n\t\t\tposition: 0,\n\t\t\tnormal: 1,\n\t\t\tuv: 2,\n\t\t}\n\t\ttexture0, err := texture.NewTextureFromFile(\"../Editor/materials/\"+p.material.DiffuseTexture,\n\t\t\tgl.REPEAT, gl.REPEAT)\n\n\t\tif err != nil {\n\t\t\tpanic(err)\n\t\t}\n\t\tp.diffuseTexture = texture0\n\n\t\tSetupAttributesMap(&p.programInfo, shaderVals)\n\t\tp.buffers.Vao = CreateTriangleVAO(&p.programInfo, p.vertexValues.Vertices, p.vertexValues.Normals, p.vertexValues.Uvs, nil, nil, p.vertexValues.Faces)\n\n\t} else if mat.ShaderType == 4 {\n\t\tshaderVals[\"aPosition\"] = true\n\t\tshaderVals[\"aNormal\"] = true\n\t\tshaderVals[\"aUV\"] = true\n\t\tshaderVals[\"diffuseVal\"] = true\n\t\tshaderVals[\"ambientVal\"] = true\n\t\tshaderVals[\"specularVal\"] = true\n\t\tshaderVals[\"nVal\"] = true\n\t\tshaderVals[\"uProjectionMatrix\"] = true\n\t\tshaderVals[\"uViewMatrix\"] = true\n\t\tshaderVals[\"uModelMatrix\"] = true\n\t\tshaderVals[\"pointLights\"] = true\n\t\tshaderVals[\"cameraPosition\"] = true\n\t\tshaderVals[\"uDiffuseTexture\"] = true\n\n\t\t//calculate tangents and bitangents\n\t\ttangents, bitangents := CalculateBitangents(p.vertexValues.Vertices, p.vertexValues.Uvs)\n\n\t\tbS := &shader.BlinnDiffuseAndNormal{}\n\t\tbS.Setup()\n\t\tp.shaderVal = bS\n\t\tp.programInfo.Program = InitOpenGL(p.shaderVal.GetVertShader(), p.shaderVal.GetFragShader(), p.shaderVal.GetGeometryShader())\n\t\tp.programInfo.attributes = Attributes{\n\t\t\tposition: 0,\n\t\t\tnormal: 1,\n\t\t\tuv: 2,\n\t\t\ttangent: 3,\n\t\t\tbitangent: 4,\n\t\t}\n\t\t//load diffuse texture\n\t\ttexture0, err := texture.NewTextureFromFile(\"../Editor/materials/\"+p.material.DiffuseTexture,\n\t\t\tgl.REPEAT, gl.REPEAT)\n\n\t\tif err != nil {\n\t\t\tpanic(err)\n\t\t}\n\t\t//load normal texture\n\t\ttexture1, err := texture.NewTextureFromFile(\"../Editor/materials/\"+p.material.NormalTexture,\n\t\t\tgl.REPEAT, gl.REPEAT)\n\n\t\tif err != nil {\n\t\t\tpanic(err)\n\t\t}\n\n\t\tp.diffuseTexture = texture0\n\t\tp.normalTexture = texture1\n\n\t\tSetupAttributesMap(&p.programInfo, shaderVals)\n\t\tp.buffers.Vao = CreateTriangleVAO(&p.programInfo, p.vertexValues.Vertices, p.vertexValues.Normals, p.vertexValues.Uvs, tangents, bitangents, p.vertexValues.Faces)\n\n\t}\n\n\tp.boundingBox = GetBoundingBox(p.vertexValues.Vertices)\n\n\tif collide {\n\t\tp.boundingBox.Collide = true\n\t} else {\n\t\tp.boundingBox.Collide = false\n\t}\n\tp.Scale(mod.Scale)\n\tp.boundingBox = ScaleBoundingBox(p.boundingBox, mod.Scale)\n\tp.model.Position = mod.Position\n\tp.boundingBox = TranslateBoundingBox(p.boundingBox, mod.Position)\n\tp.model.Rotation = mod.Rotation\n\tp.centroid = CalculateCentroid(p.vertexValues.Vertices, p.model.Scale)\n\tp.onCollide = func(box BoundingBox) {}\n\tp.reflective = reflective\n\tp.refractionIndex = refractionIndex\n\n\treturn nil\n}", "func (r *Geometry) Copy() Geometry {\n\tgeom := Geometry{\n\t\tID: r.ID,\n\t\tBoxes: make([]*Rect, len(r.Boxes)),\n\t\tInComplete: r.InComplete,\n\t}\n\tfor i, box := range r.Boxes {\n\t\tboxCp := box.Copy()\n\t\tif boxCp.Layer != nil {\n\t\t\tboxCp.Layer = &Layer{\n\t\t\t\tID: boxCp.Layer.ID,\n\t\t\t\tInComplete: true,\n\t\t\t}\n\t\t}\n\t\tif boxCp.Via != nil {\n\t\t\tboxCp.Via = &Via{\n\t\t\t\tID: boxCp.Via.ID,\n\t\t\t\tInComplete: true,\n\t\t\t}\n\t\t}\n\t\tgeom.Boxes[i] = &boxCp\n\t}\n\treturn geom\n}", "func (p *PGeometry) CoveredBy(other *Geometry) (bool, error) {\n\treturn p.predicate(\"covered by\", cGEOSPreparedCoveredBy, other)\n}", "func VBLENDPD(i, mxy, xy, xy1 operand.Op) { ctx.VBLENDPD(i, mxy, xy, xy1) }", "func Destructure(ctx context.Context, cmp pkgcmp.Compare, clipbox *geom.Extent, multipolygon *geom.MultiPolygon) ([]geom.Line, error) {\n\n\tsegments, err := asSegments(*multipolygon)\n\tif err != nil {\n\t\tif debug {\n\t\t\tlog.Printf(\"asSegments returned error: %v\", err)\n\t\t}\n\t\treturn nil, err\n\t}\n\tgext, err := geom.NewExtentFromGeometry(multipolygon)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\n\t// Let's see if our clip box is bigger then our polygon.\n\t// if it is we don't need the clip box.\n\thasClipbox := clipbox != nil && !clipbox.Contains(gext)\n\t// Let's get the edges of our clipbox; as segments and add it to the begining.\n\tif hasClipbox {\n\t\tedges := clipbox.Edges(nil)\n\t\tsegments = append([]geom.Line{\n\t\t\tgeom.Line(edges[0]), geom.Line(edges[1]),\n\t\t\tgeom.Line(edges[2]), geom.Line(edges[3]),\n\t\t}, segments...)\n\t}\n\tipts := make(map[int][][2]float64)\n\n\t// Lets find all the places we need to split the lines on.\n\teq := intersect.NewEventQueue(segments)\n\teq.FindIntersects(ctx, true, func(src, dest int, pt [2]float64) error {\n\t\tipts[src] = append(ipts[src], pt)\n\t\tipts[dest] = append(ipts[dest], pt)\n\t\treturn nil\n\t})\n\n\t// Time to start splitting lines. if we have a clip box we can ignore the first 4 (0,1,2,3) lines.\n\n\tnsegs := make([]geom.Line, 0, len(segments))\n\n\tfor i := 0; i < len(segments); i++ {\n\t\tpts := append([][2]float64{segments[i][0], segments[i][1]}, ipts[i]...)\n\n\t\t// Normalize the direction of the points.\n\t\tsort.Sort(ByXYPoint(pts))\n\n\t\tfor j := 1; j < len(pts); j++ {\n\t\t\tif cmp.PointEqual(pts[j-1], pts[j]) {\n\t\t\t\tcontinue\n\t\t\t}\n\t\t\tnl := geom.Line{pts[j-1], pts[j]}\n\t\t\tif hasClipbox && !clipbox.ContainsLine(nl) {\n\t\t\t\t// Not in clipbox discard segment.\n\t\t\t\tcontinue\n\t\t\t}\n\t\t\tnsegs = append(nsegs, nl)\n\t\t}\n\t\tif ctx.Err() != nil {\n\t\t\treturn nil, err\n\t\t}\n\t}\n\n\tunique(nsegs)\n\treturn nsegs, nil\n}", "func rcube(x, y, l int) {\n\ttx := []int{x, x + (l * 3), x, x - (l * 3), x}\n\tty := []int{y, y + (l * 2), y + (l * 4), y + (l * 2), y}\n\n\tlx := []int{x - (l * 3), x, x, x - (l * 3), x - (l * 3)}\n\tly := []int{y + (l * 2), y + (l * 4), y + (l * 8), y + (l * 6), y + (l * 2)}\n\n\trx := []int{x + (l * 3), x + (l * 3), x, x, x + (l * 3)}\n\try := []int{y + (l * 2), y + (l * 6), y + (l * 8), y + (l * 4), y + (l * 2)}\n\n\tcanvas.Polygon(tx, ty, randcolor())\n\tcanvas.Polygon(lx, ly, randcolor())\n\tcanvas.Polygon(rx, ry, randcolor())\n}", "func (r Rectangle) Sub(p Point) Rectangle {\n\treturn Rectangle{\n\t\tPoint{r.Min.X - p.X, r.Min.Y - p.Y},\n\t\tPoint{r.Max.X - p.X, r.Max.Y - p.Y},\n\t}\n}", "func VPBLENDW(i, mxy, xy, xy1 operand.Op) { ctx.VPBLENDW(i, mxy, xy, xy1) }", "func (gd Grid) Slice(rg Range) Grid {\n\tif rg.Min.X < 0 {\n\t\trg.Min.X = 0\n\t}\n\tif rg.Min.Y < 0 {\n\t\trg.Min.Y = 0\n\t}\n\tmax := gd.Rg.Size()\n\tif rg.Max.X > max.X {\n\t\trg.Max.X = max.X\n\t}\n\tif rg.Max.Y > max.Y {\n\t\trg.Max.Y = max.Y\n\t}\n\tmin := gd.Rg.Min\n\trg.Min = rg.Min.Add(min)\n\trg.Max = rg.Max.Add(min)\n\treturn Grid{innerGrid{Ug: gd.Ug, Rg: rg}}\n}", "func (poly Polygon) Shift(x float64, y float64) Polygon {\r\n\treplica := poly\r\n\treplicatedArray := make([]linalg.Vector2f64, len(poly.vertices))\r\n\tcopy(replicatedArray, poly.vertices)\r\n\treplica.vertices = replicatedArray\r\n\tfor idx, vertice := range replica.vertices {\r\n\t\treplica.vertices[idx] = vertice.Add(linalg.NewVector2f64(x, y))\r\n\t}\r\n\treturn replica\r\n}", "func (c *Camera) debugUpdate() {\n\tc.State = gfx.NewState()\n\tc.Shader = shader\n\tc.State.FaceCulling = gfx.BackFaceCulling\n\n\tm := gfx.NewMesh()\n\tm.Primitive = gfx.Lines\n\n\tm.Vertices = []gfx.Vec3{}\n\tm.Colors = []gfx.Color{}\n\n\tnear := float32(c.Near)\n\tfar := float32(c.Far)\n\n\tif c.Ortho {\n\t\twidth := float32(c.View.Dx())\n\t\theight := float32(c.View.Dy())\n\n\t\tm.Vertices = []gfx.Vec3{\n\t\t\t{width / 2, 0, height / 2},\n\n\t\t\t// Near\n\t\t\t{0, near, 0},\n\t\t\t{width, near, 0},\n\t\t\t{width, near, height},\n\t\t\t{0, near, height},\n\n\t\t\t// Far\n\t\t\t{0, far, 0},\n\t\t\t{width, far, 0},\n\t\t\t{width, far, height},\n\t\t\t{0, far, height},\n\n\t\t\t{width / 2, far, height / 2},\n\n\t\t\t// Up\n\t\t\t{0, near, height},\n\t\t\t{0, near, height},\n\t\t\t{width, near, height},\n\t\t}\n\t} else {\n\t\tratio := float32(c.View.Dx()) / float32(c.View.Dy())\n\t\tfovRad := c.FOV / 180 * math.Pi\n\n\t\thNear := float32(2 * math.Tan(fovRad/2) * c.Near)\n\t\twNear := hNear * ratio\n\n\t\thFar := float32(2 * math.Tan(fovRad/2) * c.Far)\n\t\twFar := hFar * ratio\n\n\t\tm.Vertices = []gfx.Vec3{\n\t\t\t{0, 0, 0},\n\n\t\t\t// Near\n\t\t\t{-wNear / 2, near, -hNear / 2},\n\t\t\t{wNear / 2, near, -hNear / 2},\n\t\t\t{wNear / 2, near, hNear / 2},\n\t\t\t{-wNear / 2, near, hNear / 2},\n\n\t\t\t// Far\n\t\t\t{-wFar / 2, far, -hFar / 2},\n\t\t\t{wFar / 2, far, -hFar / 2},\n\t\t\t{wFar / 2, far, hFar / 2},\n\t\t\t{-wFar / 2, far, hFar / 2},\n\n\t\t\t{0, far, 0},\n\n\t\t\t// Up\n\t\t\t{0, near, hNear},\n\t\t\t{-wNear / 2 * 0.7, near, hNear / 2 * 1.1},\n\t\t\t{wNear / 2 * 0.7, near, hNear / 2 * 1.1},\n\t\t}\n\t}\n\n\tm.Colors = []gfx.Color{\n\t\t{1, 1, 1, 1},\n\t\t{1, 0.67, 0, 1},\n\t\t{1, 0.67, 0, 1},\n\t\t{1, 0.67, 0, 1},\n\t\t{1, 0.67, 0, 1},\n\n\t\t{1, 0.67, 0, 1},\n\t\t{1, 0.67, 0, 1},\n\t\t{1, 0.67, 0, 1},\n\t\t{1, 0.67, 0, 1},\n\t\t{1, 1, 1, 1},\n\n\t\t{0, 0.67, 1, 1},\n\t\t{0, 0.67, 1, 1},\n\t\t{0, 0.67, 1, 1},\n\t}\n\n\tm.Indices = []uint32{\n\t\t// From 0 to near plane\n\t\t0, 1,\n\t\t0, 2,\n\t\t0, 3,\n\t\t0, 4,\n\n\t\t// Near plane\n\t\t1, 2,\n\t\t2, 3,\n\t\t3, 4,\n\t\t4, 1,\n\n\t\t// Far plane\n\t\t5, 6,\n\t\t6, 7,\n\t\t7, 8,\n\t\t8, 5,\n\n\t\t// Lines from near to far plane\n\t\t1, 5,\n\t\t2, 6,\n\t\t3, 7,\n\t\t4, 8,\n\n\t\t0, 9,\n\n\t\t// Up\n\t\t10, 11,\n\t\t11, 12,\n\t\t12, 10,\n\t}\n\n\tc.Meshes = []*gfx.Mesh{m}\n}", "func (rs *RenderSystem) TogglePolygons() {\n\trs.drawPolygon = !rs.drawPolygon\n}", "func DistPointPlane32(x, y, z, a, b, c, d float32) float32 {\n\tdevised := x * a + y * b + z * c + d\n\tdevisor := a * a + b * b + c * c\n\tif devised > 0 {\n\t\treturn devised / SqrtRootFloat32(devisor)\n\t} else {\n\t\treturn -devised / SqrtRootFloat32(devisor)\n\t}\n}", "func (p Vector3) Sub(o Vector3) Vector3 {\n\treturn Vector3{p.X - o.X, p.Y - o.Y, p.Z - o.Z}\n}", "func CreateRect(llc, urc vec.Vec3) Mesh {\n\tdiag := urc.Sub(llc)\n\tc0 := llc\n\tc1 := llc.Add(vec.Vec3{diag.X, 0.0, 0.0})\n\tc2 := llc.Add(vec.Vec3{0.0, diag.Y, 0.0})\n\tc3 := llc.Add(vec.Vec3{0.0, 0.0, diag.Z})\n\tc4 := llc.Add(vec.Vec3{diag.X, diag.Y, 0.0})\n\tc5 := llc.Add(vec.Vec3{diag.X, 0.0, diag.Z})\n\tc6 := llc.Add(vec.Vec3{0.0, diag.Y, diag.Z})\n\tc7 := urc\n\n\treturn Mesh{\n\t\t*NewMeshElem(c0, c1, c5),\n\t\t*NewMeshElem(c0, c5, c3),\n\t\t*NewMeshElem(c1, c4, c7),\n\t\t*NewMeshElem(c1, c7, c5),\n\t\t*NewMeshElem(c4, c2, c6),\n\t\t*NewMeshElem(c4, c6, c7),\n\t\t*NewMeshElem(c2, c0, c3),\n\t\t*NewMeshElem(c2, c3, c6),\n\t\t*NewMeshElem(c5, c7, c6),\n\t\t*NewMeshElem(c5, c6, c3),\n\t\t*NewMeshElem(c0, c2, c1),\n\t\t*NewMeshElem(c1, c2, c4),\n\t}\n}", "func NewProjectionPlane(args ...interface{}) (*ProjectionPlane, error) {\n\twidth, height, pixelSize, distance, err := projectionPlaneParams(args)\n\n\tprojectionPlane := &ProjectionPlane{\n\t\tWidth: width,\n\t\tHeight: height,\n\t\tPixelSize: pixelSize,\n\t\tDistance: distance,\n\t\tGamma: 1.0,\n\t\tClampOutOfGamut: false,\n\t\tClampColor: *color.NewColor(0., 0., 0.),\n\t\tImage: *image.NewRGBA(image.Rect(0, 0, width, height)),\n\t}\n\n\treturn projectionPlane, err\n}", "func (v Vec3) Negate() Vec3 {\n\treturn Vec3{-v.X, -v.Y, -v.Z}\n}", "func TestTwoDimensionalPlaneShouldFail1(t *testing.T) {\n\tvar err error\n\n\tmodel := NewLogistic(base.BatchGD, 1e-4, 1e4, 500, twoDX, twoDY)\n\terr = model.Learn()\n\tassert.Nil(t, err, \"Learning error should be nil\")\n\n\tvar guess []float64\n\tvar faliures int\n\n\tfor i := -200; i < 200; i += 15 {\n\t\tguess, err = model.Predict([]float64{float64(i)})\n\t\tif i/2+10 > 0 && guess[0] < 0.5 {\n\t\t\tfaliures++\n\t\t} else if i/2+10 < 0 && guess[0] > 0.5 {\n\t\t\tfaliures++\n\t\t}\n\n\t\tassert.Len(t, guess, 1, \"Length of a Logistic model output from the hypothesis should always be a 1 dimensional vector. Never multidimensional.\")\n\t\tassert.Nil(t, err, \"Prediction error should be nil\")\n\t}\n\n\tassert.True(t, faliures > 10, \"There should be a strong majority of faliures of the training set\")\n}", "func (p *panel) merge() {\n\tp.trash()\n\tsize := p.csize * 0.5\n\tp.slab = p.part.AddPart().SetAt(p.cx, p.cy, p.cz)\n\tscale := float64(p.lvl-1) * size\n\tif (p.cx > p.cy && p.cx > p.cz) || (p.cx < p.cy && p.cx < p.cz) {\n\t\tp.slab.SetScale(size, scale, scale)\n\t} else if (p.cy > p.cx && p.cy > p.cz) || (p.cy < p.cx && p.cy < p.cz) {\n\t\tp.slab.SetScale(scale, size, scale)\n\t} else if (p.cz > p.cx && p.cz > p.cy) || (p.cz < p.cx && p.cz < p.cy) {\n\t\tp.slab.SetScale(scale, scale, size)\n\t}\n\tm := p.slab.MakeModel(\"flata\", \"msh:cube\", \"mat:tblue\")\n\tm.SetUniform(\"fd\", 1000)\n}", "func (o *Octant) Add(s Boundable) {\n\tsb := s.AABB()\n\n\t// If the spatial is too large to fit into this octant then we expand.\n\tif !o.AABB.Contains(sb) {\n\t\t// The spatial is too large to fit into this octant. We will expand our\n\t\t// octant to be large enough to contain both the spatial and our old\n\t\t// octant.\n\t\told := o.AABB\n\n\t\tlargest := largestAxis(o.AABB.Fit(sb))\n\t\to.AABB = AABB{\n\t\t\tMin: math.Vec3{-largest, -largest, -largest},\n\t\t\tMax: math.Vec3{largest, largest, largest},\n\t\t}\n\n\t\t/*\n\t\t\tlargest := largestAxis(o.AABB.Fit(sb))\n\t\t\tif !o.AABB.Empty() {\n\t\t\t\t// If this octant was not the empty-starting octant then we must\n\t\t\t\t// move this octant to become the [-x, +y, +z] child octant.\n\t\t\t\tfirstChild := &Octant{\n\t\t\t\t\tDepth: o.Depth + 1,\n\t\t\t\t\tAABB: o.AABB,\n\t\t\t\t\tOctants: o.Octants,\n\t\t\t\t\tObjects: o.Objects,\n\t\t\t\t}\n\t\t\t\to.Octants = [8]*Octant{firstChild}\n\t\t\t}\n\t\t\to.AABB = AABB{\n\t\t\t\tMin: math.Vec3{-largest, -largest, -largest},\n\t\t\t\tMax: math.Vec3{largest, largest, largest},\n\t\t\t}\n\t\t*/\n\n\t\tfmt.Println(\"Expand to\", o.AABB)\n\t\t//fmt.Println(\" New:\", o.AABB)\n\t\t//fmt.Println(\" Size:\", o.AABB.Size())\n\t\t//fmt.Println(\" :\")\n\t\tfmt.Println(\" Small:\", sb)\n\t\tfmt.Println(\" Small-Center:\", sb.Center())\n\t\tfmt.Println(\" Small-Size:\", sb.Size())\n\t\t//fmt.Println(\" Size:\", sb.Size())\n\t\tfmt.Println(\" :\")\n\t\tfmt.Println(\" Big:\", old)\n\t\tfmt.Println(\" Big-Center:\", old.Center())\n\t\tfmt.Println(\" Big-Size:\", old.Size())\n\t\t//fmt.Println(\" Size:\", old.Size())\n\t\tfmt.Println(\" :\")\n\t\to.Objects = make(map[Boundable]struct{})\n\t}\n\n\tif !o.AABB.Contains(sb) {\n\t\tfmt.Println(\"Failure to contain:\", sb)\n\t\tfmt.Println(\" Size:\", sb.Size())\n\t\tfmt.Println(\"Expansion failed!\")\n\t\t//panic(\"Expansion failed!\")\n\t}\n\n\t// Find an octant (this one or a distant child one) that the spatial can be\n\t// fit into.\n\tdst := o.findDistantOctant(sb)\n\tif dst == nil {\n\t\tdst = o\n\t}\n\tfmt.Println(\"fit in\", dst.Depth, len(dst.Objects))\n\tdst.Objects[s] = struct{}{}\n}", "func (p *Particle) Bounds(maxx, maxy float64) {\n\tif p.Position[0] > maxx {\n\t\tp.Position[0] = 0.0\n\t}\n\tif p.Position[1] > maxy {\n\t\tp.Position[1] = 0.0\n\t}\n\n\tif p.Position[0] < 0.0 {\n\t\tp.Position[0] = maxx\n\t}\n\tif p.Position[1] < 0.0 {\n\t\tp.Position[1] = maxy\n\t}\n}", "func NewClipper() Clipper {\n\treturn &clipperClipper{}\n}", "func (r *Ray) Intersect(o Ray) (Vector, bool) {\n\tconst width = 0.03\n\n\tclampInRange := func(p Vector) (Vector, bool) {\n\t\tdist := r.Origin.Distance(p)\n\t\tif dist < r.Mint || dist > r.Maxt {\n\t\t\treturn r.Origin, false\n\t\t}\n\n\t\treturn p, true\n\t}\n\n\tif r.Origin == o.Origin {\n\t\treturn r.Origin, true\n\t}\n\n\td3 := r.Direction.Cross(o.Direction)\n\n\tif !d3.Equals(NewVector(0, 0, 0)) {\n\t\tmatrix := [12]float64{\n\t\t\tr.Direction.X,\n\t\t\t-o.Direction.X,\n\t\t\td3.X,\n\t\t\to.Origin.X - r.Origin.X,\n\n\t\t\tr.Direction.Y,\n\t\t\t-o.Direction.Y,\n\t\t\td3.Y,\n\t\t\to.Origin.Y - r.Origin.Y,\n\n\t\t\tr.Direction.Z,\n\t\t\t-o.Direction.Z,\n\t\t\td3.Z,\n\t\t\to.Origin.Z - r.Origin.Z,\n\t\t}\n\n\t\tresult := solve(matrix, 3, 4)\n\n\t\ta := result[3]\n\t\tb := result[7]\n\t\tc := result[11]\n\n\t\tif a >= 0 && b >= 0 {\n\t\t\tdist := d3.MultiplyScalar(c)\n\t\t\tif dist.Length() <= width {\n\t\t\t\treturn clampInRange(r.At(a))\n\t\t\t}\n\t\t\treturn r.Origin, false\n\t\t}\n\t}\n\n\tdP := o.Origin.Multiply(r.Origin)\n\n\ta2 := r.Direction.Dot(dP)\n\tb2 := o.Direction.Dot(dP.Neg())\n\n\tif a2 < 0 && b2 < 0 {\n\t\tdist := r.Origin.Distance(dP)\n\t\tif dP.Length() <= width {\n\t\t\treturn clampInRange(r.At(dist))\n\t\t}\n\t\treturn r.Origin, false\n\t}\n\n\tp3a := r.Origin.Plus(r.Direction.MultiplyScalar(a2))\n\td3a := o.Origin.Minus(p3a)\n\n\tp3b := r.Origin\n\td3b := o.Origin.Plus(o.Direction.MultiplyScalar(b2)).Minus(p3b)\n\n\tif b2 < 0 {\n\t\tif d3a.Length() <= width {\n\t\t\treturn clampInRange(p3a)\n\t\t}\n\t\treturn r.Origin, false\n\t}\n\n\tif a2 < 0 {\n\t\tif d3b.Length() <= width {\n\t\t\treturn clampInRange(p3b)\n\t\t}\n\t\treturn r.Origin, false\n\t}\n\n\tif d3a.Length() <= d3b.Length() {\n\t\tif d3a.Length() <= width {\n\t\t\treturn clampInRange(p3a)\n\t\t}\n\t\treturn r.Origin, false\n\t}\n\n\tif d3b.Length() <= width {\n\t\treturn clampInRange(p3b)\n\t}\n\n\treturn r.Origin, false\n}", "func (u UDim) Sub(v UDim) UDim {\n\treturn UDim{\n\t\tScale: u.Scale - v.Scale,\n\t\tOffset: u.Offset - v.Offset,\n\t}\n}", "func (b Bounds3) Offset(p Point3) Vec3 {\n\to := p.SubtractP(b.pMin)\n\tif b.pMax.X > b.pMin.X {\n\t\to.X /= b.pMax.X - b.pMin.X\n\t}\n\tif b.pMax.Y > b.pMin.Y {\n\t\to.Y /= b.pMax.Y - b.pMin.Y\n\t}\n\tif b.pMax.Z > b.pMin.Z {\n\t\to.Z /= b.pMax.Z - b.pMin.Z\n\t}\n\treturn o\n}", "func (histogram Histogram) Clip(limit int) {\n\n\tvar buffer int\n\n\tbinCount := len(histogram)\n\texcess := 0\n\n\tfor i := 0; i < binCount; i++ {\n\t\tbuffer = histogram[i] - limit\n\t\tif buffer > 0 {\n\t\t\texcess += buffer\n\t\t}\n\t}\n\n\tincrementPerBin := excess / binCount\n\tupper := binCount - incrementPerBin\n\n\tfor i := 0; i < binCount; i++ {\n\t\tswitch {\n\t\tcase histogram[i] > limit:\n\t\t\thistogram[i] = limit\n\t\tcase histogram[i] > upper:\n\t\t\texcess += upper - histogram[i]\n\t\t\thistogram[i] = limit\n\t\tdefault:\n\t\t\texcess -= incrementPerBin\n\t\t\thistogram[i] += incrementPerBin\n\t\t}\n\t}\n\n\tif excess > 0 {\n\n\t\tstep := (1 + (excess / binCount))\n\t\tif step < 1 {\n\t\t\tstep = 1\n\t\t}\n\n\t\tfor i := 0; i < binCount; i++ {\n\t\t\texcess -= step\n\t\t\thistogram[i] += step\n\t\t\tif excess < 1 {\n\t\t\t\tbreak\n\t\t\t}\n\t\t}\n\n\t}\n\n}", "func (m *Match) printMatchClip() {\n\tstartStr := \"...\"\n\tendStr := \"...\"\n\tstart := m.Match[0] - SideBuffer\n\tend := m.Match[1] + SideBuffer\n\n\tif start < 0 {\n\t\tstart = 0\n\t\tstartStr = \"\"\n\t}\n\tif end > len(m.Line)-1 {\n\t\tend = len(m.Line) - 1\n\t\tendStr = \"\"\n\t}\n\n\tfmt.Printf(\"%s%s%s%s:%s:%s%s%s%s%s%s%s%s%s%s%s%s\\n\",\n\t\tcolors.Purple,\n\t\tm.Path,\n\t\tcolors.Restore,\n\t\tcolors.Green,\n\t\tstrconv.Itoa(m.LineNumber),\n\t\tcolors.Restore,\n\t\tcolors.Yellow,\n\t\tstartStr,\n\t\tcolors.Restore,\n\t\tstring(m.Line[start:m.Match[0]]),\n\t\tcolors.LightRed,\n\t\tstring(m.Line[m.Match[0]:m.Match[1]]),\n\t\tcolors.Restore,\n\t\tstring(m.Line[m.Match[1]:end]),\n\t\tcolors.Yellow,\n\t\tendStr,\n\t\tcolors.Restore,\n\t)\n}" ]
[ "0.7158832", "0.710133", "0.6163395", "0.56733644", "0.5549828", "0.5395412", "0.5308266", "0.5185617", "0.5155969", "0.5075975", "0.48775586", "0.48698863", "0.4835573", "0.47909898", "0.47605744", "0.4717083", "0.46650428", "0.46585107", "0.46503273", "0.4640544", "0.45716512", "0.4556805", "0.4547562", "0.4467173", "0.44532543", "0.44467127", "0.44392735", "0.43906838", "0.4384058", "0.43682715", "0.43598616", "0.43388116", "0.4337546", "0.43346077", "0.43241295", "0.4298007", "0.4287476", "0.42866257", "0.4252791", "0.42446914", "0.42328098", "0.42297393", "0.42247477", "0.42141363", "0.42036092", "0.4171739", "0.4167562", "0.41571125", "0.415276", "0.415276", "0.4146107", "0.41183305", "0.41178334", "0.40947852", "0.40842122", "0.4080743", "0.40790305", "0.4068069", "0.40567556", "0.4055594", "0.40499428", "0.40437567", "0.40378112", "0.40354297", "0.40346205", "0.40331295", "0.40144885", "0.40117848", "0.40003747", "0.39903307", "0.39852348", "0.39834806", "0.39811915", "0.3977725", "0.39721477", "0.39696583", "0.39642563", "0.39598572", "0.3952045", "0.39264673", "0.3916899", "0.39125142", "0.3911155", "0.39099738", "0.39060044", "0.39023206", "0.39022148", "0.39011687", "0.3893156", "0.3878946", "0.3874762", "0.38745388", "0.3870859", "0.38704908", "0.3865043", "0.38631257", "0.38618693", "0.3860539", "0.3848988", "0.38358492" ]
0.70023525
2
cause a material color to track the current color
func ColorMaterial(face uint32, mode uint32) { C.glowColorMaterial(gpColorMaterial, (C.GLenum)(face), (C.GLenum)(mode)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func ColorMaterial(face uint32, mode uint32) {\n C.glowColorMaterial(gpColorMaterial, (C.GLenum)(face), (C.GLenum)(mode))\n}", "func ColorMaterial(face uint32, mode uint32) {\n\tsyscall.Syscall(gpColorMaterial, 2, uintptr(face), uintptr(mode), 0)\n}", "func MaterialColor(col threejs.Color) MeshOption {\n\treturn func(t *Mesh) error {\n\t\tt.renderColor = col\n\n\t\treturn nil\n\t}\n}", "func (c *meshPhysicalMaterialImp) Color() threejs.Color {\n\treturn threejs.NewColorFromJSValue(\n\t\tc.JSValue().Get(\"color\"),\n\t)\n}", "func (s Sphere) Color() Material {\n\treturn s.Mat\n}", "func (m *Milight) Color(color byte) error {\n\tcmd := []byte{0x31, 0x00, 0x00, 0x00, 0x01, color, color, color, color}\n\treturn m.sendCommand(cmd)\n}", "func color(r geometry.Ray, world geometry.Hitable, depth int) geometry.Vector {\n\thit, record := world.CheckForHit(r, 0.001, math.MaxFloat64)\n\n\t// if hit {\n\t// \ttarget := record.Point.Add(record.Normal).Add(RandomInUnitSphere())\n\t// \treturn color(&geometry.Ray{Origin: record.Point, Direction: target.Subtract(record.P)}, world).Scale(0.5)\n\t// }\n\n\tif hit {\n\t\tif depth < 50 {\n\t\t\tscattered, scatteredRay := record.Scatter(r, record)\n\t\t\tif scattered {\n\t\t\t\tnewColor := color(scatteredRay, world, depth+1)\n\t\t\t\treturn record.Material.Albedo().Multiply(newColor)\n\t\t\t}\n\t\t}\n\t}\n\n\t// Make unit vector so y is between -1.0 and 1.0\n\tunitDirection := r.Direction.Normalize()\n\n\tvar t float64 = 0.5 * (unitDirection.Y + 1.0)\n\n\t// The two vectors here are what creates the sky(Blue to white gradient of the background)\n\treturn geometry.Vector{X: 1.0, Y: 1.0, Z: 1.0}.Scale(1.0 - t).Add(geometry.Vector{X: 0.5, Y: 0.7, Z: 1.0}.Scale(t))\n}", "func (m *material) setMaterial(kd, ka, ks *rgb, tr float32) {\n\tm.kd.R, m.kd.G, m.kd.B = kd.R, kd.G, kd.B\n\tm.ks.R, m.ks.G, m.ks.B = ks.R, ks.G, ks.B\n\tm.ka.R, m.ka.G, m.ka.B = ka.R, ka.G, ka.B\n\tm.tr = tr\n\tm.loaded = true\n}", "func SetColorTemp(temp int) {\n\t// An attempt to fix https://github.com/d4l3k/go-sct/issues/9\n\tif runtime.GOOS == \"windows\" {\n\t\tsetColorTemp(temp + 1)\n\t}\n\tsetColorTemp(temp)\n}", "func (c *Color) Reset() {\n\tc.params = c.params[:0]\n}", "func Color(foreColor, backColor, mode gb.UINT8) {}", "func (b *Base) getColor() bool {\n\treturn b.isBlack\n}", "func (dw *DrawingWand) Color(x, y float64, pm PaintMethod) {\n\tC.MagickDrawColor(dw.dw, C.double(x), C.double(y), C.PaintMethod(pm))\n}", "func ClearColor(red float32, green float32, blue float32, alpha float32) {\n C.glowClearColor(gpClearColor, (C.GLfloat)(red), (C.GLfloat)(green), (C.GLfloat)(blue), (C.GLfloat)(alpha))\n}", "func (debugging *debuggingOpenGL) ClearColor(red float32, green float32, blue float32, alpha float32) {\n\tdebugging.recordEntry(\"ClearColor\", red, green, blue, alpha)\n\tdebugging.gl.ClearColor(red, green, blue, alpha)\n\tdebugging.recordExit(\"ClearColor\")\n}", "func (c *Change) Colour(hue, saturation int) *Change {\n\tc.params[\"hue\"], c.params[\"sat\"] = hue, saturation\n\treturn c\n}", "func getColor(r Ray, world HittableList, depth int) mgl64.Vec3 {\n\thits := world.Hit(r, Epsilon, math.MaxFloat64)\n\tif len(hits) > 0 {\n\t\t// HittableList makes sure the first (and only) intersection\n\t\t// is the closest one:\n\t\thit := hits[0]\n\t\t// Simulate the light response of this material.\n\t\tisScattered, attenuation, scattered := hit.Mat.Scatter(r, hit)\n\t\t// If this ray is reflected off the surface, determine the response\n\t\t// of the scattered ray:\n\t\tif isScattered && depth < MaxBounces {\n\t\t\tresponse := getColor(scattered, world, depth+1)\n\n\t\t\treturn mgl64.Vec3{response.X() * attenuation.X(),\n\t\t\t\tresponse.Y() * attenuation.Y(),\n\t\t\t\tresponse.Z() * attenuation.Z()}\n\t\t}\n\t\t// Otherwise, the ray was absorbed, or we have exceeded the\n\t\t// maximum number of light bounces:\n\t\treturn mgl64.Vec3{0.0, 0.0, 0.0}\n\t}\n\t// If we don't intersect with anything, plot a background instead:\n\tunitDirection := r.Direction().Normalize()\n\tt := 0.5*unitDirection.Y() + 1.0\n\t// Linearly interpolate between white and blue:\n\tA := mgl64.Vec3{1.0, 1.0, 1.0}.Mul(1.0 - t)\n\tB := mgl64.Vec3{0.5, 0.7, 1.0}.Mul(t)\n\treturn A.Add(B)\n}", "func ClearAccum(red float32, green float32, blue float32, alpha float32) {\n C.glowClearAccum(gpClearAccum, (C.GLfloat)(red), (C.GLfloat)(green), (C.GLfloat)(blue), (C.GLfloat)(alpha))\n}", "func (b *Bulb) ColorTemp(temp int) error {\n\tswitch {\n\tcase temp < 1700:\n\t\ttemp = 1700\n\tcase temp > 6500:\n\t\ttemp = 6500\n\t}\n\treturn b.Send(MethodSetCTABX, temp)\n}", "func (e *Emulator) ColorModel() color.Model { return color.RGBAModel }", "func (pic *Picture) SetColor(color color.Color) {\n\tpic.currentColor = color\n}", "func ForceOpenColor() bool {\n\toldVal := isSupportColor\n\tisSupportColor = true\n\n\treturn oldVal\n}", "func (uni *Uniform3fv) SetColor(idx int, color *math32.Color) {\n\n\tpos := idx * 3\n\tuni.v[pos] = color.R\n\tuni.v[pos+1] = color.G\n\tuni.v[pos+2] = color.B\n}", "func SetColor(mode bool) {\n\tColorize = mode\n}", "func (p *Ball) Color() *objects.Vector { return p.color }", "func (uni *Uniform1fv) SetColor(pos int, color *math32.Color) {\n\n\tuni.v[pos] = color.R\n\tuni.v[pos+1] = color.G\n\tuni.v[pos+2] = color.B\n}", "func (p *Ball) SetColor(color *objects.Vector) { p.color = color }", "func (n *saturationDegreeIterator) Reset() { panic(\"coloring: invalid call to Reset\") }", "func Candle() Color {\n\treturn Color{R: 255, G: 147, B: 41, W: 0}\n}", "func (c Color) Samelight(pct float32) Color {\n\thsl := HSLAModel.Convert(c).(HSLA)\n\tif hsl.L >= .5 {\n\t\thsl.L += pct / 100\n\t} else {\n\t\thsl.L -= pct / 100\n\t}\n\thsl.L = mat32.Clamp(hsl.L, 0, 1)\n\treturn ColorModel.Convert(hsl).(Color)\n}", "func Color(c color.Color) termbox.Attribute {\n\tswitch termbox.SetOutputMode(termbox.OutputCurrent) {\n\tcase termbox.OutputNormal:\n\t\treturn ColorNormal(c)\n\tcase termbox.Output256:\n\t\treturn Color256(c)\n\tcase termbox.Output216:\n\t\treturn Color216(c)\n\tcase termbox.OutputGrayscale:\n\t\treturn ColorGray(c)\n\tdefault:\n\t\tpanic(\"unexpected output mode\")\n\t}\n}", "func (pb *Pbar) changeColor() {\n\tif pb.fgString != \" \" {\n\t\tpb.color = -10\n\t} else {\n\t\tpb.color = 0\n\t}\n\tif pb.currentAmount <= pb.totalAmount/4 {\n\t\tpb.color += pb.LOW\n\t} else if pb.currentAmount >= pb.totalAmount/4 && pb.currentAmount <= 2*pb.totalAmount/3 {\n\t\tpb.color += pb.MEDIUM\n\t} else if pb.currentAmount >= 2*pb.totalAmount/3 && pb.currentAmount <= pb.totalAmount {\n\t\tpb.color += pb.HIGH\n\t} else {\n\t\tpb.color += pb.FULL\n\t}\n\n}", "func SetForceColor(mode bool) {\n\tForceColorize = mode\n}", "func (c *Canvas) Color(at pixel.Vec) pixel.RGBA {\n\treturn c.gf.Color(at)\n}", "func (v *mandelbrotViewer) color(m float64) color.Color {\n\t_, f := math.Modf(m)\n\tncol := len(palette.Plan9)\n\tc1, _ := colorful.MakeColor(palette.Plan9[int(m)%ncol])\n\tc2, _ := colorful.MakeColor(palette.Plan9[int(m+1)%ncol])\n\tr, g, b := c1.BlendHcl(c2, f).Clamped().RGB255()\n\treturn color.RGBA{r, g, b, 255}\n}", "func (sphr sphere) color() color.NRGBA {\n\treturn sphr.col\n}", "func (g *Gopher) SetColor(c Color) {\n\tg.mu.Lock()\n\tdefer g.mu.Unlock()\n\tg.color = c\n}", "func (s *Sphere) Color() color.Color {\n\treturn s.color\n}", "func (c *car) setColor(color string) {\n\tc.color = color\n}", "func (c *car) setColor(color string) {\n\tc.color = color\n}", "func (db *DB) SetLastPulseAsLightMaterial(ctx context.Context, pulsenum core.PulseNumber) error {\n\treturn db.Update(ctx, func(tx *TransactionManager) error {\n\t\treturn tx.set(ctx, prefixkey(scopeIDSystem, []byte{sysLastPulseAsLightMaterial}), pulsenum.Bytes())\n\t})\n}", "func (c car) getColor() string {\n\treturn c.color\n}", "func (c car) getColor() string {\n\treturn c.color\n}", "func ColorState(r *Redlight, t time.Time) int {\n\ttotalPatternDuration := func() (result int) {\n\t\tfor _, v := range r.pattern {\n\t\t\tresult += v[1]\n\t\t}\n\t\treturn\n\t}()\n\truntime := int(t.Sub(r.initialTime).Seconds())\n\ttimeInLoop := runtime % totalPatternDuration\n\n\tvar cumulatedTime int\n\tvar state int\n\tfor _, v := range r.pattern {\n\t\tif cumulatedTime > timeInLoop {\n\t\t\tbreak\n\t\t}\n\t\tcumulatedTime += v[1]\n\t\tstate = v[0]\n\t}\n\treturn state\n}", "func (f *FenceComponent) SetColor(color api.IPalette) {\n\tgr := f.bottom.(*custom.LineNode)\n\tgr.SetColor(color)\n\tgr = f.right.(*custom.LineNode)\n\tgr.SetColor(color)\n\tgr = f.top.(*custom.LineNode)\n\tgr.SetColor(color)\n\tgr = f.left.(*custom.LineNode)\n\tgr.SetColor(color)\n}", "func (g *Group) SetMaterial(m *canvas.Material) {\n\treturn\n}", "func (spriteBatch *SpriteBatch) ClearColor() {\n\tspriteBatch.color = []float32{1, 1, 1, 1}\n}", "func (sd *saturationDegree) reset(colors map[int64]int) {\n\tsd.colors = colors\n\tfor i := range sd.nodes {\n\t\tsd.adjColors[i] = make(set.Ints)\n\t}\n\tfor uid, c := range colors {\n\t\tto := sd.g.From(uid)\n\t\tfor to.Next() {\n\t\t\tsd.adjColors[sd.indexOf[to.Node().ID()]].Add(c)\n\t\t}\n\t}\n}", "func (r ApiGetBitlinkQRCodeRequest) Color(color string) ApiGetBitlinkQRCodeRequest {\n\tr.color = &color\n\treturn r\n}", "func (win *window) SetColor(p sparta.Property, c color.RGBA) {\n\tif (p != sparta.Background) && (p != sparta.Foreground) {\n\t\treturn\n\t}\n\ts := xwin.DefaultScreen()\n\tcode := getColorCode(c)\n\tpx, ok := pixelMap[code]\n\tif !ok {\n\t\tr, g, b, _ := c.RGBA()\n\t\tcl, _ := xwin.AllocColor(s.DefaultColormap, uint16(r), uint16(g), uint16(b))\n\t\tpx = cl.Pixel\n\t\tpixelMap[code] = px\n\t}\n\tif p == sparta.Foreground {\n\t\txwin.ChangeGC(win.gc, xgb.GCForeground, []uint32{px})\n\t} else {\n\t\txwin.ChangeGC(win.gc, xgb.GCBackground, []uint32{px})\n\t}\n}", "func (m *PlayerMutation) OldColor(ctx context.Context) (v player.Color, err error) {\n\tif !m.op.Is(OpUpdateOne) {\n\t\treturn v, fmt.Errorf(\"OldColor is only allowed on UpdateOne operations\")\n\t}\n\tif m.id == nil || m.oldValue == nil {\n\t\treturn v, fmt.Errorf(\"OldColor requires an ID field in the mutation\")\n\t}\n\toldValue, err := m.oldValue(ctx)\n\tif err != nil {\n\t\treturn v, fmt.Errorf(\"querying old value for OldColor: %w\", err)\n\t}\n\treturn oldValue.Color, nil\n}", "func (m *PlayerMutation) ResetColor() {\n\tm.color = nil\n}", "func UpdateColor(c *fiber.Ctx) error {\n\treturn c.JSON(\"Update color\")\n}", "func (r *paintingRobot) scanColor() int {\n for _, p := range r.paintedPoints {\n if p.x == r.position.x && p.y == r.position.y {\n return p.color\n }\n }\n\n return 0\n}", "func (t *TrafficLightTTY) Red() {\n\tt.send([]byte(RED))\n}", "func ClearColor(red float32, green float32, blue float32, alpha float32) {\n\tC.glowClearColor(gpClearColor, (C.GLfloat)(red), (C.GLfloat)(green), (C.GLfloat)(blue), (C.GLfloat)(alpha))\n}", "func ClearColor(red float32, green float32, blue float32, alpha float32) {\n\tC.glowClearColor(gpClearColor, (C.GLfloat)(red), (C.GLfloat)(green), (C.GLfloat)(blue), (C.GLfloat)(alpha))\n}", "func (y *Yeelight) SetRGB(value, effect, duration string) string {\n\tcmd := `{\"id\":3,\"method\":\"set_rgb\",\"params\":[` + value + `,\"` + effect + `\",` + duration + `]}`\n\treturn y.request(cmd)\n}", "func (c *Color) Set() *Color {\n\tif c.isNoColorSet() {\n\t\treturn c\n\t}\n\tfmt.Fprintf(Output, c.format())\n\n\treturn c\n}", "func newMaterial(name string) *material {\n\tmat := &material{name: name, tag: mat + stringHash(name)<<32}\n\tmat.kd.R, mat.kd.G, mat.kd.B, mat.tr = 1, 1, 1, 1\n\treturn mat\n}", "func (c dSaturColoring) color(id int64) {\n\tif !c.uncolored.Has(id) {\n\t\tif _, ok := c.colors[id]; ok {\n\t\t\tpanic(\"coloring: coloring already colored node\")\n\t\t}\n\t\tpanic(\"coloring: coloring non-existent node\")\n\t}\n\t// The node has its uncolored mark removed, but is\n\t// not explicitly colored until the dSaturExact\n\t// caller has completed its recursive exploration\n\t// of the feasible colors.\n\tc.uncolored.Remove(id)\n}", "func (m *TagManager) ChangeColor(name, color string) error {\n\ttag, err := m.Get(name)\n\tif err != nil {\n\t\treturn fmt.Errorf(\"error getting tag %v\", err)\n\t}\n\tif color != tag.Color {\n\t\tif err := m.DB.Model(&tag).Update(\"color\", color).Error; err != nil {\n\t\t\treturn fmt.Errorf(\"Update %v\", err)\n\t\t}\n\t}\n\treturn nil\n}", "func (o *Plotter) set_default_clr_mrk() {\n\tif o.ClrPC == \"\" {\n\t\to.ClrPC = \"#85b9ff\"\n\t}\n\tif o.ArrWid == 0 {\n\t\to.ArrWid = 10\n\t}\n\tif o.Clr == \"\" {\n\t\to.Clr = \"red\"\n\t}\n\tif o.Mrk == \"\" {\n\t\to.Mrk = \"\"\n\t}\n\tif o.Ls == \"\" {\n\t\to.Ls = \"-\"\n\t}\n\tif o.LsAlt == \"\" {\n\t\to.LsAlt = \"--\"\n\t}\n\tif o.SpMrk == \"\" {\n\t\to.SpMrk = \".\"\n\t}\n\tif o.EpMrk == \"\" {\n\t\to.EpMrk = \"o\"\n\t}\n\tif o.SpClr == \"\" {\n\t\to.SpClr = \"black\"\n\t}\n\tif o.EpClr == \"\" {\n\t\to.EpClr = \"black\"\n\t}\n\tif o.SpMs == 0 {\n\t\to.SpMs = 3\n\t}\n\tif o.EpMs == 0 {\n\t\to.EpMs = 3\n\t}\n\tif o.YsClr0 == \"\" {\n\t\to.YsClr0 = \"green\"\n\t}\n\tif o.YsClr1 == \"\" {\n\t\to.YsClr1 = \"cyan\"\n\t}\n\tif o.YsLs0 == \"\" {\n\t\to.YsLs0 = \"-\"\n\t}\n\tif o.YsLs1 == \"\" {\n\t\to.YsLs1 = \"--\"\n\t}\n\tif o.YsLw0 < 0.1 {\n\t\to.YsLw0 = 0.7\n\t}\n\tif o.YsLw1 < 0.1 {\n\t\to.YsLw1 = 0.7\n\t}\n}", "func (b *Bit) Update(color HasColor) {\n\tb.color = color\n\tif b.ref != nil {\n\t\tb.enable() // reenable if it was enabled\n\t}\n}", "func (c * Case)TakeColor(color int)int8{\n\tif color > len(c.cows){\n\t\treturn 0\n\t}\n\tnb := c.cows[color]\n\tc.cows[color] = 0\n\treturn int8(nb)\n}", "func getAmbientLighting(ambient Color, Ka []float64) Color {\n return Color{int(Ka[0] * float64(ambient.r)),\n int(Ka[1] * float64(ambient.g)),\n int(Ka[2] * float64(ambient.b))}\n}", "func BlendColor(red float32, green float32, blue float32, alpha float32) {\n C.glowBlendColor(gpBlendColor, (C.GLfloat)(red), (C.GLfloat)(green), (C.GLfloat)(blue), (C.GLfloat)(alpha))\n}", "func (c *Color) Spectrum() Spectrum {\n\treturn c.s\n}", "func (uni *Uniform1fv) GetColor(pos int) math32.Color {\n\n\treturn math32.Color{uni.v[pos], uni.v[pos+1], uni.v[pos+2]}\n}", "func nextcolor(c color.RGBA) color.RGBA {\n\tswitch {\n\tcase c.R == 255 && c.G == 0 && c.B == 0:\n\t\tc.G += 5\n\tcase c.R == 255 && c.G != 255 && c.B == 0:\n\t\tc.G += 5\n\tcase c.G == 255 && c.R != 0:\n\t\tc.R -= 5\n\tcase c.R == 0 && c.B != 255:\n\t\tc.B += 5\n\tcase c.B == 255 && c.G != 0:\n\t\tc.G -= 5\n\tcase c.G == 0 && c.R != 255:\n\t\tc.R += 5\n\tdefault:\n\t\tc.B -= 5\n\t}\n\treturn c\n}", "func (gl *WebGL) ClearColor(r, g, b, a float64) {\n\tgl.context.Call(\"clearColor\", float32(r), float32(g), float32(b), float32(a))\n}", "func (spriteBatch *SpriteBatch) SetColor(vals ...float32) {\n\tspriteBatch.color = vals\n}", "func (native *OpenGL) ClearColor(red float32, green float32, blue float32, alpha float32) {\n\tgl.ClearColor(red, green, blue, alpha)\n}", "func (ctl *Controller) SetColour(position int, colour Colour) {\n\tif position >= ctl.count || position < 0 {\n\t\t// Do nothing - out of bounds\n\t\treturn\n\t}\n\n\tctl.ledColours[position] = colour\n\n\tctl.updateBuffer(position, colour)\n}", "func (rgbw *Rgbw) SetRed(r uint8) {\n\trgbw[0] = r\n}", "func (m *PrinterDefaults) SetMediaColor(value *string)() {\n err := m.GetBackingStore().Set(\"mediaColor\", value)\n if err != nil {\n panic(err)\n }\n}", "func (g *Game) ChangeColor() string {\n\tif game_color == 1 {\n\t\tgame_color = 2\n\t\treturn \"Color: Black\"\n\t} else {\n\t\tgame_color = 1\n\t\treturn \"Color: White\"\n\t}\n}", "func getRed(ftemp float64) int {\n\t//range from 0 to 20 now\n\tftempConv := ftemp - min\n\tred := (ftempConv / diff) * 255\n\treturn int(red)\n}", "func (c LightEmitter) Type() string { return ComponentTypeLightEmitter }", "func (pb *Pbar) ToggleColor(arg interface{}) {\n\tswitch reflect.TypeOf(arg).Kind() {\n\tcase reflect.Slice:\n\t\tcol := reflect.ValueOf(arg)\n\t\tl := col.Len()\n\n\t\tif l < 0 || l > 4 {\n\t\t\tfmt.Println(\"Error: Must provide a number of colors between 0 - 4.\\nSwitching to b/w...\")\n\t\t\tpb.isColor = false\n\t\t\treturn\n\t\t}\n\n\t\tfor i := 0; i < col.Len(); i++ {\n\t\t\tcolStr := col.Index(i).String()\n\t\t\tif _, ok := colors[colStr]; !ok {\n\t\t\t\tfmt.Printf(\"'%s' is not a valid color. Switching to b/w...\\n\\n\", colStr)\n\t\t\t\tpb.isColor = false\n\t\t\t\treturn\n\t\t\t}\n\t\t}\n\n\t\tif l == 4 {\n\t\t\tpb.LOW = colors[(col.Index(0)).String()]\n\t\t\tpb.MEDIUM = colors[(col.Index(1)).String()]\n\t\t\tpb.HIGH = colors[(col.Index(2)).String()]\n\t\t\tpb.FULL = colors[(col.Index(3)).String()]\n\t\t} else if l == 3 {\n\t\t\tpb.LOW = colors[(col.Index(0)).String()]\n\t\t\tpb.MEDIUM = colors[(col.Index(1)).String()]\n\t\t\tpb.HIGH = colors[(col.Index(2)).String()]\n\t\t\tpb.FULL = colors[(col.Index(2)).String()]\n\t\t} else if l == 2 {\n\t\t\tpb.LOW = colors[(col.Index(0)).String()]\n\t\t\tpb.MEDIUM = colors[(col.Index(0)).String()]\n\t\t\tpb.HIGH = colors[(col.Index(1)).String()]\n\t\t\tpb.FULL = colors[(col.Index(1)).String()]\n\t\t} else if l == 1 {\n\t\t\tpb.LOW = colors[(col.Index(0)).String()]\n\t\t\tpb.MEDIUM = colors[(col.Index(0)).String()]\n\t\t\tpb.HIGH = colors[(col.Index(0)).String()]\n\t\t\tpb.FULL = colors[(col.Index(0)).String()]\n\t\t} else {\n\t\t\tpb.isColor = false\n\t\t\treturn\n\t\t}\n\t\tpb.isColor = true\n\tcase reflect.String:\n\t\tcol := reflect.ValueOf(arg)\n\t\tif _, ok := colors[col.String()]; ok {\n\t\t\tpb.LOW = colors[col.String()]\n\t\t\tpb.MEDIUM = colors[col.String()]\n\t\t\tpb.HIGH = colors[col.String()]\n\t\t\tpb.FULL = colors[col.String()]\n\t\t\tpb.isColor = true\n\t\t}\n\t}\n}", "func (r Ray) Colour(world Hittable, depth int) vec3.Colour {\n\t// t := r.HitSphere(vec3.Point3{Z: -1}, .5)\n\t// if t > 0.0 {\n\t// \tN := r.At(t).SubtractVec3(vec3.Vec3{Z: -1}).UnitVector()\n\t// \treturn vec3.Colour{X: N.X + 1, Y: N.Y + 1, Z: N.Z + 1}.MultiplyFloat(.5)\n\t// }\n\trec, worldHit := world.Hit(r, 0.001, constants.PositiveInfinity)\n\tif depth <= 0 {\n\t\treturn vec3.Colour{} // 0, 0, 0\n\t}\n\tif worldHit {\n\t\t// return rec.Normal.AddVec3(vec3.Colour{X: 1, Y: 1, Z: 1}).MultiplyFloat(.5)\n\t\t// target := rec.P.AddVec3(rec.Normal).AddVec3(vec3util.RandomInUnitSphere())\n\t\t// target := rec.P.AddVec3(vec3util.RandomInHemisphere(rec.Normal))\n\t\t// return Ray{rec.P, target.SubtractVec3(rec.P)}.Colour(world, depth-1).MultiplyFloat(.5)\n\t\tif attenuation, scattered, cond := rec.Mat.Scatter(r, rec); cond {\n\t\t\treturn attenuation.MultiplyVec3(scattered.Colour(world, depth-1))\n\t\t}\n\t\treturn vec3.Colour{} // 0, 0, 0\n\t}\n\tunitDirection := r.Direction.UnitVector()\n\tt := .5 * (unitDirection.Y + 1.0)\n\treturn vec3.Colour{\n\t\tX: 1.0,\n\t\tY: 1.0,\n\t\tZ: 1.0,\n\t}.MultiplyFloat(1.0 - t).AddVec3(\n\t\tvec3.Colour{\n\t\t\tX: 0.5,\n\t\t\tY: 0.7,\n\t\t\tZ: 1.0,\n\t\t}.MultiplyFloat(t))\n}", "func (r *Rook) Color() PieceColor {\n\treturn r.color\n}", "func (r *wavefrontSceneReader) defaultMaterial() *wavefrontMaterial {\n\tmatName := \"\"\n\n\t// Search for material in referenced list\n\tmatIndex, exists := r.matNameToIndex[matName]\n\tif !exists {\n\t\t// Add it now\n\t\tr.materials = append(r.materials, &wavefrontMaterial{Kd: types.Vec3{0.7, 0.7, 0.7}})\n\t\tmatIndex = len(r.materials) - 1\n\t\tr.matNameToIndex[matName] = matIndex\n\t}\n\tr.curMaterial = r.materials[matIndex]\n\treturn r.curMaterial\n}", "func (s Slot) Color() string {\n\tif s.car == nil {\n\t\treturn \"\"\n\t}\n\n\treturn s.car.color\n}", "func (m *ParentLabelDetails) SetColor(value *string)() {\n err := m.GetBackingStore().Set(\"color\", value)\n if err != nil {\n panic(err)\n }\n}", "func (d *DB) StoreMaterial(mtrl *material.Material) error {\n\tif d.shadow == nil {\n\t\td.shadow = make(map[string][]byte)\n\t}\n\n\tdata, err := mtrl.Marshal()\n\tif err != nil {\n\t\treturn err\n\t}\n\td.shadow[hex.EncodeToString(mtrl.ID)] = data\n\n\treturn nil\n}", "func ClearColor(red, green, blue, alpha float32) {\n\tgl.ClearColor(red, green, blue, alpha)\n}", "func (c *Color) Red() byte {\n\treturn c.r\n}", "func (builder *SentenceBuilder) ColorReset() *SentenceBuilder {\n\tif currentColor := builder.colorStack.Front(); currentColor != nil {\n\t\tbuilder.colorStack.Remove(currentColor)\n\t}\n\n\tif color := builder.colorStack.Front(); color != nil {\n\t\tif colorInt, ok := color.Value.(uint8); ok {\n\t\t\tbuilder.writeColor(colorInt)\n\t\t}\n\n\t\tif colorRgb, ok := color.Value.(string); ok {\n\t\t\tbuilder.writeColorRgb(colorRgb)\n\t\t}\n\t} else {\n\t\tbuilder.write(fgColorResetSeq)\n\t}\n\n\treturn builder\n}", "func (rx *RotationX) SetMaterial(m material.Material) {\r\n\trx.Primitive.SetMaterial(m)\r\n}", "func (r *RayTracer) findColor(ray *Ray, scene []Shape, lights []Light, curDepth int) *Vec3 {\n\n\t// check if the ray hits any objects:\n\tif hit, inter, closest := findClosestIntersection(ray, scene); hit {\n\n\t\t// apply material of the closest shape\n\t\tmaterial := (*closest).GetMaterial()\n\t\tcolor := material.ambient.plus(&material.emission)\n\n\t\t// apply each light that is visible from the intersection point\n\t\tfor _, light := range lights {\n\n\t\t\t// find offset to light\n\t\t\tlightOffset := light.OffsetFrom(&inter.point)\n\t\t\tdistToLight := lightOffset.magnitude()\n\n\t\t\t// enable soft-shadowing by tracing multiple shadow rays\n\t\t\tnumRays := r.options.numShadowRays\n\t\t\trayWeight := ONE / entry(numRays)\n\t\t\tfor j := 0; j < numRays; j++ {\n\t\t\t\tshadowRayDir := lightOffset.plus(randVec()).direction()\n\t\t\t\tshadowRay := &Ray{\n\t\t\t\t\t*inter.point.plus(shadowRayDir.scale(entry(0.001))), // push ray towards light\n\t\t\t\t\t*shadowRayDir,\n\t\t\t\t}\n\n\t\t\t\t// check if shadowRay hits any objects in the scene:\n\t\t\t\tif h, i, _ := findClosestIntersection(shadowRay, scene); (!h) || i.dist >= distToLight {\n\t\t\t\t\textraColor := BlinnPhongShader(&light, shadowRayDir, &inter.normal, ray, material, distToLight)\n\t\t\t\t\tcolor = color.plus(extraColor.scale(rayWeight))\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\t// recursively trace rays\n\t\tif curDepth < r.options.maxDepth {\n\t\t\trefRayDir := reflect(&ray.direction, &inter.normal)\n\n\t\t\t// if this is the primary ray, perform some blurring\n\t\t\tnumRays := 1\n\t\t\tif curDepth == 0 {\n\t\t\t\tnumRays = 4 // TODO move into options\n\t\t\t}\n\t\t\trefRayWeight := ONE / entry(numRays)\n\n\t\t\tfor i := 0; i < numRays; i++ {\n\n\t\t\t\t// build reflected ray\n\t\t\t\trefRay := &Ray{\n\t\t\t\t\t*inter.point.plus(refRayDir.scale(entry(0.001))), // to avoid self-collision\n\t\t\t\t\t*refRayDir.plus(inter.normal.scale(smallRand(0.001))).direction(),\n\t\t\t\t}\n\n\t\t\t\t// trace the reflected ray // TODO early stop if extraColor is small\n\t\t\t\textraColor := material.specular.scale(refRayWeight).times(r.findColor(refRay, scene, lights, curDepth+1))\n\t\t\t\tcolor = color.plus(extraColor)\n\t\t\t}\n\t\t}\n\t\treturn color\n\t}\n\n\t// no intersections:\n\treturn &ZERO_V3\n}", "func (lg *logger) nextColor() func(string) string {\n\n\tif len(colors) == lastUsedColor+1 {\n\t\tlastUsedColor = 0\n\t} else {\n\t\tlastUsedColor = lastUsedColor + 1\n\t}\n\n\treturn colors[lastUsedColor]\n\n}", "func (m *PlayerMutation) Color() (r player.Color, exists bool) {\n\tv := m.color\n\tif v == nil {\n\t\treturn\n\t}\n\treturn *v, true\n}", "func (r *paintingRobot) paint(color int) {\n fmt.Println(fmt.Sprintf(\"robot paints [%d,%d] to color %d\", r.position.x, r.position.y, color))\n\n for _, p := range r.paintedPoints {\n if p.x == r.position.x && p.y == r.position.y {\n p.color = color\n fmt.Println(\"just repainted, # of painted tiles: \", len(r.paintedPoints))\n return\n }\n }\n\n r.position.color = color\n r.paintedPoints = append(r.paintedPoints, r.position)\n fmt.Println(\"NEW painting, # of painted tiles: \", len(r.paintedPoints))\n}", "func (rgbw *Rgbw) SetColor(r uint8, g uint8, b uint8, w uint8) {\n\trgbw[0] = r\n\trgbw[1] = g\n\trgbw[2] = b\n\trgbw[3] = w\n}", "func (c *Color) SetColor(ci color.Color) {\n\tif ci == nil {\n\t\tc.SetToNil()\n\t\treturn\n\t}\n\tr, g, b, a := ci.RGBA()\n\tc.SetUInt32(r, g, b, a)\n}", "func getColorIndex(temp float64) int {\n\tif temp < *minTemp {\n\t\treturn 0\n\t}\n\tif temp > *maxTemp {\n\t\treturn len(colors) - 1\n\t}\n\treturn int((temp - *minTemp) * float64(len(colors)-1) / (*maxTemp - *minTemp))\n}", "func (n *Node) generateUniqueColor() {\n\tif colorIter == 13 {\n\t\tcolorIter = 0\n\t}\n\n\tn.Color = colors[colorIter]\n\tcolorIter++\n}", "func (obj *Device) ColorFill(\n\tsurface *Surface,\n\trect *RECT,\n\tcolor COLOR,\n) Error {\n\tret, _, _ := syscall.Syscall6(\n\t\tobj.vtbl.ColorFill,\n\t\t4,\n\t\tuintptr(unsafe.Pointer(obj)),\n\t\tuintptr(unsafe.Pointer(surface)),\n\t\tuintptr(unsafe.Pointer(rect)),\n\t\tuintptr(color),\n\t\t0,\n\t\t0,\n\t)\n\treturn toErr(ret)\n}", "func (Screen *ScreenManager) Color(str string, color int) string {\n\treturn applyScreenTransform(str, func(idx int, line string) string {\n\t\treturn fmt.Sprintf(\"%s%s%s\", getScreenColor(color), line, RESET)\n\t})\n}" ]
[ "0.6981486", "0.66909766", "0.6087489", "0.5918387", "0.5870019", "0.5862606", "0.57150435", "0.57144535", "0.57004493", "0.56751585", "0.5466822", "0.5432201", "0.54093975", "0.54062957", "0.5389144", "0.538787", "0.5347877", "0.53256637", "0.53208923", "0.5315993", "0.53156143", "0.5288125", "0.5268713", "0.5268162", "0.5261344", "0.5261023", "0.5242333", "0.52249587", "0.5221562", "0.5212902", "0.5206964", "0.51980585", "0.5185111", "0.51738703", "0.51685625", "0.51531327", "0.51452297", "0.5144513", "0.51312137", "0.51312137", "0.50963", "0.5095557", "0.5095557", "0.50725853", "0.50656235", "0.5049072", "0.49782637", "0.49764463", "0.49751014", "0.4967328", "0.49665666", "0.49628282", "0.496179", "0.49584866", "0.4952916", "0.49506652", "0.49506652", "0.49455106", "0.48988968", "0.4898892", "0.48933563", "0.48913106", "0.48905608", "0.48867515", "0.48832023", "0.48828828", "0.4882747", "0.48804155", "0.48742655", "0.48679608", "0.48630232", "0.48629087", "0.48564073", "0.4847752", "0.48460534", "0.48459247", "0.48399207", "0.48387975", "0.4838572", "0.48357853", "0.48291942", "0.4826524", "0.48257142", "0.4817413", "0.48120493", "0.48104006", "0.48013848", "0.47928834", "0.47918057", "0.4786911", "0.47864717", "0.47844696", "0.47785303", "0.47698933", "0.47647727", "0.476114", "0.47583532", "0.47425205", "0.4730142", "0.4727701" ]
0.6886134
1
define an array of colors
func ColorPointer(size int32, xtype uint32, stride int32, pointer unsafe.Pointer) { C.glowColorPointer(gpColorPointer, (C.GLint)(size), (C.GLenum)(xtype), (C.GLsizei)(stride), pointer) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func GenColor(intr int) [][]uint8 {\n\toutput := [][]uint8{}\n\tfor i := 0; i <= 255; i += intr {\n\t\tfor j := 0; j <= 255; j += intr {\n\t\t\tfor k := 0; k <= 255; k += intr {\n\t\t\t\ta := []uint8{uint8(i), uint8(j), uint8(k)}\n\t\t\t\toutput = append(output, a)\n\n\t\t\t}\n\t\t}\n\t}\n\treturn output\n\n}", "func Colors() []string {\n\treturn []string{\"black\", \"brown\", \"red\", \"orange\", \"yellow\", \"green\", \"blue\", \"violet\", \"grey\", \"white\"}\n}", "func (gw2 *GW2Api) ColorIds(lang string, ids ...int) (colors []Color, err error) {\n\tver := \"v2\"\n\ttag := \"colors\"\n\tparams := url.Values{}\n\tif lang != \"\" {\n\t\tparams.Add(\"lang\", lang)\n\t}\n\tparams.Add(\"ids\", commaList(stringSlice(ids)))\n\terr = gw2.fetchEndpoint(ver, tag, params, &colors)\n\treturn\n}", "func EnabledColors(red, green, blue, yellow bool) []Color {\n\tr := []Color{}\n\tif red {\n\t\tfor _, red := range RedishColors {\n\t\t\tr = append(r, Color(red))\n\t\t}\n\t}\n\tif green {\n\t\tfor _, green := range GreenishColors {\n\t\t\tr = append(r, Color(green))\n\t\t}\n\t}\n\tif blue {\n\t\tfor _, blue := range BluishColors {\n\t\t\tr = append(r, Color(blue))\n\t\t}\n\t}\n\tif yellow {\n\t\tfor _, yellow := range YellowishColors {\n\t\t\tr = append(r, Color(yellow))\n\t\t}\n\t}\n\treturn r\n}", "func main() {\n\tvar colors [3]string // items have to be of the same type\n\tcolors[0] = \"Red\" // no ':' as the type is already inferred\n\tcolors[1] = \"Green\"\n\tcolors[2] = \"Blue\"\n\tfmt.Println(colors)\n\tfmt.Println(colors[1])\n\n\tvar numbers = [5]int{1,2,3,4,5}\n\tfmt.Println(numbers)\n\tfmt.Println(\"numbers length is:\", len(numbers))\n}", "func solarizedColors() *Palette {\n\tsize := 9\n\tp := Palette{\n\t\tcolors: make([]Style, size),\n\t\tsize: size,\n\t}\n\tnums := [9]int{1, 2, 3, 4, 5, 6, 7, 9, 13}\n\tfor x := 0; x < 9; x++ {\n\t\tp.colors[x] = Color256(nums[x])\n\t}\n\treturn &p\n}", "func GeneratePalette(numberOfColors int) ([]color.RGBA, error) {\n if numberOfColors <= 0 {\n return nil, errors.New(nonPositiveNumber)\n }\n rand.Seed(time.Now().UnixNano())\n nodesPerSide := findEdge(numberOfColors)\n skipThreshold := math.Ceil(float64(nodesPerSide)/6)\n nodeSize := 255/(nodesPerSide - 1)\n randomColors := rand.Perm(nodesPerSide*nodesPerSide*nodesPerSide)\n colors := make([]color.RGBA, numberOfColors)\n j := 0\n for i:=0;i<numberOfColors;i++ {\n var x, y, z int\n for ; ; j++ {\n x, y, z = coordinatesFromIndex(randomColors[j], nodesPerSide)\n //Avoid colors among the diagonal of the cube, as they are low contrast\n if math.Abs(float64(x - y)) >= skipThreshold || math.Abs(float64(y - z)) >= skipThreshold || math.Abs(float64(x - z)) >= skipThreshold {\n j++\n break\n }\n }\n x, y, z = x*nodeSize, y*nodeSize, z*nodeSize\n x, y, z = rotateColorSpace(x, y, z)\n colors[i] = color.RGBA{uint8(x), uint8(y), uint8(z), 255}\n }\n return colors, nil\n}", "func makeColorLookup(vals []int, length int) []int {\n\tres := make([]int, length)\n\n\tvi := 0\n\tfor i := 0; i < len(res); i++ {\n\t\tif vi+1 < len(vals) {\n\t\t\tif i <= (vals[vi]+vals[vi+1])/2 {\n\t\t\t\tres[i] = vi\n\t\t\t} else {\n\t\t\t\tvi++\n\t\t\t\tres[i] = vi\n\t\t\t}\n\t\t} else if vi < len(vals) {\n\t\t\t// only last vi is valid\n\t\t\tres[i] = vi\n\t\t}\n\t}\n\treturn res\n}", "func Color(foreColor, backColor, mode gb.UINT8) {}", "func (s Sprite) Colors() []byte {\n\tcs := make([]byte, spriteWidth*spriteWidth)\n\tfor i := uint(0); i < spriteWidth; i++ {\n\t\tc1 := s[i]\n\t\tc2 := s[i+spriteWidth]\n\t\tfor j := uint(0); j < spriteWidth; j++ {\n\t\t\tv := (c1 >> j & 1) + (c2>>j)&1<<1\n\t\t\tx := spriteWidth - j - 1\n\t\t\ty := i * spriteWidth\n\t\t\tcs[x+y] = v\n\t\t}\n\t}\n\treturn cs\n}", "func getColors(w http.ResponseWriter) {\n\t// creates a new slice of colors\n\tvar colors []Color\n\n\t// runs a query to pull data from the database\n\trows, err := db.Query(`SELECT color, r, g, b, a, hex, creatorId, creatorHash FROM colors ORDER BY g ASC, b ASC, hex;`)\n\t// checks the error\n\thtmlCheck(err, w, fmt.Sprint(\"There was an error \", err))\n\t// create variables to hold color properties\n\tvar name, r, g, b, a, hex, cID, cH string\n\t// for each color\n\tfor rows.Next() {\n\t\t// fill in the variables in given order\n\t\terr = rows.Scan(&name, &r, &g, &b, &a, &hex, &cID, &cH)\n\t\t// checks the error\n\t\thtmlCheck(err, w, fmt.Sprint(\"There was an error \", err))\n\t\t// creates a color with the rows details\n\t\tc := Color{\n\t\t\tname,\n\t\t\tr,\n\t\t\tg,\n\t\t\tb,\n\t\t\ta,\n\t\t\thex,\n\t\t\t0.,\n\t\t\tcID,\n\t\t\tcH,\n\t\t}\n\t\t// calculate the hue and add it to the color\n\t\tc.Hue = calcHue(c)\n\t\t// if the hue is not returned set it to zero\n\t\tif math.IsNaN(c.Hue) {\n\t\t\tc.Hue = 0.\n\t\t}\n\t\t// add the new color to the colors slice\n\t\tcolors = append(colors, c)\n\n\t}\n\t// encodes the colors array to json\n\terr = json.NewEncoder(w).Encode(getColorSorted(colors))\n\t// checks the error\n\thtmlCheck(err, w, fmt.Sprint(\"There was an error \", err))\n}", "func colorClique(clique []graph.Node) map[int64]int {\n\tcolors := make(map[int64]int, len(clique))\n\tfor c, u := range clique {\n\t\tcolors[u.ID()] = c\n\t}\n\treturn colors\n}", "func (s *Service) setColorPairs() {\n\tswitch s.primaryColor {\n\tcase \"green\":\n\t\tgc.InitPair(1, gc.C_GREEN, gc.C_BLACK)\n\tcase \"cyan\", \"blue\":\n\t\tgc.InitPair(1, gc.C_CYAN, gc.C_BLACK)\n\tcase \"magenta\", \"pink\", \"purple\":\n\t\tgc.InitPair(1, gc.C_MAGENTA, gc.C_BLACK)\n\tcase \"white\":\n\t\tgc.InitPair(1, gc.C_WHITE, gc.C_BLACK)\n\tcase \"red\":\n\t\tgc.InitPair(1, gc.C_RED, gc.C_BLACK)\n\tcase \"yellow\", \"orange\":\n\t\tgc.InitPair(1, gc.C_YELLOW, gc.C_BLACK)\n\tdefault:\n\t\tgc.InitPair(1, gc.C_WHITE, gc.C_BLACK)\n\t}\n\n\tgc.InitPair(2, gc.C_BLACK, gc.C_BLACK)\n\tgc.InitPair(3, gc.C_BLACK, gc.C_GREEN)\n\tgc.InitPair(4, gc.C_BLACK, gc.C_CYAN)\n\tgc.InitPair(5, gc.C_WHITE, gc.C_BLUE)\n\tgc.InitPair(6, gc.C_BLACK, -1)\n}", "func (c Color) Values() []float64 {\n\treturn c\n}", "func generatePalette(c0, c1 float64) [8]float64 {\n\n\t//Get signed float normalized palette (0 to 1)\n\tpal := [8]float64{}\n\tpal[0], pal[1] = c0, c1\n\tif c0 > c1 {\n\t\tpal[2] = (6*c0 + 1*c1) / 7\n\t\tpal[3] = (5*c0 + 2*c1) / 7\n\t\tpal[4] = (4*c0 + 3*c1) / 7\n\t\tpal[5] = (3*c0 + 4*c1) / 7\n\t\tpal[6] = (2*c0 + 5*c1) / 7\n\t\tpal[7] = (1*c0 + 6*c1) / 7\n\t} else {\n\t\tpal[2] = (4*c0 + 1*c1) / 5\n\t\tpal[3] = (3*c0 + 2*c1) / 5\n\t\tpal[4] = (2*c0 + 3*c1) / 5\n\t\tpal[5] = (1*c0 + 4*c1) / 5\n\t\tpal[6] = 0\n\t\tpal[7] = 1\n\t}\n\treturn pal\n}", "func New(value ...Attribute) *Color {\n\tc := &Color{params: make([]Attribute, 0)}\n\tc.Add(value...)\n\treturn c\n}", "func permuteColors(nr, ng, nb uint8) []color.Model {\n\tvar colorModels []color.Model\n\tfor _, r := range iterate(nr) {\n\t\tfor _, g := range iterate(ng) {\n\t\t\tfor _, b := range iterate(nb) {\n\t\t\t\tcolorModels = append(colorModels, clrlib.Scaled{R: r, G: g, B: b})\n\t\t\t}\n\t\t}\n\t}\n\treturn colorModels\n}", "func (gw2 *GW2Api) Colors() (res []int, err error) {\n\tver := \"v2\"\n\ttag := \"colors\"\n\terr = gw2.fetchEndpoint(ver, tag, nil, &res)\n\treturn\n}", "func ShowColors() {\n\tfmt.Printf(\"%#v\\n\", colors)\n}", "func (pb *Pbar) ToggleColor(arg interface{}) {\n\tswitch reflect.TypeOf(arg).Kind() {\n\tcase reflect.Slice:\n\t\tcol := reflect.ValueOf(arg)\n\t\tl := col.Len()\n\n\t\tif l < 0 || l > 4 {\n\t\t\tfmt.Println(\"Error: Must provide a number of colors between 0 - 4.\\nSwitching to b/w...\")\n\t\t\tpb.isColor = false\n\t\t\treturn\n\t\t}\n\n\t\tfor i := 0; i < col.Len(); i++ {\n\t\t\tcolStr := col.Index(i).String()\n\t\t\tif _, ok := colors[colStr]; !ok {\n\t\t\t\tfmt.Printf(\"'%s' is not a valid color. Switching to b/w...\\n\\n\", colStr)\n\t\t\t\tpb.isColor = false\n\t\t\t\treturn\n\t\t\t}\n\t\t}\n\n\t\tif l == 4 {\n\t\t\tpb.LOW = colors[(col.Index(0)).String()]\n\t\t\tpb.MEDIUM = colors[(col.Index(1)).String()]\n\t\t\tpb.HIGH = colors[(col.Index(2)).String()]\n\t\t\tpb.FULL = colors[(col.Index(3)).String()]\n\t\t} else if l == 3 {\n\t\t\tpb.LOW = colors[(col.Index(0)).String()]\n\t\t\tpb.MEDIUM = colors[(col.Index(1)).String()]\n\t\t\tpb.HIGH = colors[(col.Index(2)).String()]\n\t\t\tpb.FULL = colors[(col.Index(2)).String()]\n\t\t} else if l == 2 {\n\t\t\tpb.LOW = colors[(col.Index(0)).String()]\n\t\t\tpb.MEDIUM = colors[(col.Index(0)).String()]\n\t\t\tpb.HIGH = colors[(col.Index(1)).String()]\n\t\t\tpb.FULL = colors[(col.Index(1)).String()]\n\t\t} else if l == 1 {\n\t\t\tpb.LOW = colors[(col.Index(0)).String()]\n\t\t\tpb.MEDIUM = colors[(col.Index(0)).String()]\n\t\t\tpb.HIGH = colors[(col.Index(0)).String()]\n\t\t\tpb.FULL = colors[(col.Index(0)).String()]\n\t\t} else {\n\t\t\tpb.isColor = false\n\t\t\treturn\n\t\t}\n\t\tpb.isColor = true\n\tcase reflect.String:\n\t\tcol := reflect.ValueOf(arg)\n\t\tif _, ok := colors[col.String()]; ok {\n\t\t\tpb.LOW = colors[col.String()]\n\t\t\tpb.MEDIUM = colors[col.String()]\n\t\t\tpb.HIGH = colors[col.String()]\n\t\t\tpb.FULL = colors[col.String()]\n\t\t\tpb.isColor = true\n\t\t}\n\t}\n}", "func sortColors(nums []int) {\n\tidx0, idx1, idx2 := -1, -1, -1\n\tfor i := range nums {\n\t\tswitch nums[i] {\n\t\tcase 0:\n\t\t\tnums[idx0+1] = 0\n\t\t\tif idx1 != idx0 {\n\t\t\t\tnums[idx1+1] = 1\n\t\t\t}\n\t\t\tif idx2 != idx1 {\n\t\t\t\tnums[idx2+1] = 2\n\t\t\t}\n\t\t\tidx0++\n\t\t\tidx1++\n\t\t\tidx2++\n\n\t\tcase 1:\n\t\t\tnums[idx1+1] = 1\n\t\t\tif idx2 != idx1 {\n\t\t\t\tnums[idx2+1] = 2\n\t\t\t}\n\t\t\tidx1++\n\t\t\tidx2++\n\n\t\tcase 2: // maybe can replace idx2 with i\n\t\t\tnums[idx2+1] = 2\n\t\t\tidx2++\n\t\t}\n\t}\n\n}", "func sortColors(nums []int) {\n\tzero := 0\n\tone := 0\n\ttwo := 0\n\tfor i := 0; i < len(nums); i++ {\n\t\tif nums[i] == 0 {\n\t\t\tzero++\n\t\t} else if nums[i] == 1 {\n\t\t\tone++\n\t\t} else {\n\t\t\ttwo++\n\t\t}\n\t}\n\tfor i := 0; i < len(nums); i++ {\n\t\tif zero > 0 {\n\t\t\tnums[i] = 0\n\t\t\tzero--\n\t\t} else if one > 0 {\n\t\t\tnums[i] = 1\n\t\t\tone--\n\t\t} else {\n\t\t\tnums[i] = 2\n\t\t}\n\t}\n}", "func New(color string) *ml.Color {\n\tcolor = Normalize(color)\n\n\t//check if it's indexed color\n\tfor i, c := range indexed {\n\t\tif color == c {\n\t\t\treturn &ml.Color{Indexed: &i}\n\t\t}\n\t}\n\n\treturn &ml.Color{RGB: color}\n}", "func sortColors(nums []int) {\n\tfor l, i, r := 0, 0, len(nums)-1; i <= r; {\n\t\tswitch nums[i] {\n\t\tcase 0:\n\t\t\tnums[i], nums[l] = nums[l], nums[i]\n\t\t\tl++\n\t\t\ti++\n\t\tcase 1:\n\t\t\ti++\n\t\tcase 2:\n\t\t\tnums[i], nums[r] = nums[r], nums[i]\n\t\t\tr--\n\t\t}\n\t}\n}", "func triangleColors(id int, key string, colors []color.RGBA, lines int) (tColors []string) {\n\n\tfor _, t := range triangles[id] {\n\t\tx := t.x\n\t\ty := t.y\n\t\ttColors = append(tColors, draw.FillFromRGBA(draw.PickColor(key, colors, (x+3*y+lines)%15)))\n\t}\n\treturn\n}", "func GetColors() map[int]string {\n\treturn colors\n}", "func (d Device) WriteColors(buf []color.RGBA) error {\n\tfor _, color := range buf {\n\t\td.WriteByte(color.G) // green\n\t\td.WriteByte(color.R) // red\n\t\td.WriteByte(color.B) // blue\n\t}\n\treturn nil\n}", "func Red(format string, a ...interface{}) { colorPrint(FgRed, format, a...) }", "func newColorsImage(width, height int, colors []colorFreq, save bool) image.Image {\n\timg := image.NewRGBA(image.Rectangle{image.Point{0, 0}, image.Point{width, height}})\n\tvar xStart, xEnd int\n\t// for each color, calculate the start and end x positions, then fill in the column\n\tfor i, c := range colors {\n\t\tif i == 0 {\n\t\t\txStart = 0\n\t\t} else {\n\t\t\txStart = xEnd\n\t\t}\n\t\txEnd = xStart + int(c.freq*float32(width))\n\n\t\tfor x := xStart; x < xEnd; x++ {\n\t\t\tfor y := 0; y < height; y++ {\n\t\t\t\timg.Set(x, y, c.color)\n\t\t\t}\n\t\t}\n\t}\n\n\tif save {\n\t\tout, _ := os.Create(\"./newColorsImage.png\")\n\t\tjpeg.Encode(out, img, nil)\n\t}\n\n\treturn img\n}", "func toRGB(p []color.NRGBA) []byte {\n\tb := make([]byte, 0, len(p)*3)\n\tfor _, c := range p {\n\t\tb = append(b, c.R, c.G, c.B)\n\t}\n\treturn b\n}", "func GenerateColormap(colors []models.ColorModel) {\n\tlogger := log.ColoredLogger()\n\tdateStr := strings.ReplaceAll(time.Now().Format(time.UnixDate), \":\", \"-\")\n\tfilepath := fmt.Sprintf(\"lib/assets/images/colormap_%s.png\", dateStr)\n\t// alright, this is going to be a very long terminal command. Hopefully there aren't limits.\n\tqueryStr := fmt.Sprintf(\"convert -size %dx1 xc:white \", len(colors))\n\tfor i, c := range colors {\n\t\tqueryStr += fmt.Sprintf(\"-fill '%s' -draw 'point %d,0' \", c.Hex, i)\n\t}\n\tqueryStr += filepath\n\n\tcmd := exec.Command(queryStr)\n\tcmd.Stdout = os.Stdout\n\tcmd.Stderr = os.Stderr\n\tlogger.Error(\"error\", zap.Error(cmd.Run()))\n}", "func hackerColors() *Palette {\n\tsize := 1\n\tp := Palette{\n\t\tcolors: make([]Style, size),\n\t\tsize: size,\n\t}\n\tp.colors[0] = Color256(82)\n\treturn &p\n}", "func Set(p ...Attribute) (c *Color) {\n\tc = New(p...)\n\tc.Set()\n\n\treturn\n}", "func sortColors(nums []int) {\n\tred, blue := 0, len(nums)-1\n\tfor i := 0; i <= blue; i++ {\n\t\tif nums[i] == 0 {\n\t\t\tnums[red], nums[i] = nums[i], nums[red]\n\t\t\tred += 1\n\t\t\tcontinue\n\t\t}\n\t\tif nums[i] == 2 {\n\t\t\tnums[blue], nums[i] = nums[i], nums[blue]\n\t\t\tblue -= 1\n\t\t\ti -= 1\n\t\t}\n\t}\n}", "func RandomColorset() {\n\treturn Colorset{}\n}", "func getColorSorted(c []Color) []Color {\n\t// Sorts the colors by hue Ascending\n\tsort.Slice(c, func(i, j int) bool {\n\t\treturn c[i].Hue > c[j].Hue\n\t})\n\treturn c\n}", "func New(value ...Attribute) *Color {\n\treturn getCacheColor(value...)\n}", "func Convert(c []float64) ([]float64, error) {\n\tif len(c) != 3 {\n\t\treturn nil, fmt.Errorf(\"color dimension=[%d] error\", len(c))\n\t}\n\tc[0], c[1], c[2] = colorful.Color{R: c[0], G: c[1], B: c[2]}.Hsl()\n\treturn c, nil\n}", "func (o GoogleCloudRetailV2alphaColorInfoOutput) Colors() pulumi.StringArrayOutput {\n\treturn o.ApplyT(func(v GoogleCloudRetailV2alphaColorInfo) []string { return v.Colors }).(pulumi.StringArrayOutput)\n}", "func (b *BoardTest) TestQuickColors(t *C) {\n\tl := new(RGBLED, 9, 10, 11)\n\tvar cs = map[string][3]byte{\n\t\t\"red\": [3]byte{0xFF, 00, 00},\n\t\t\"green\": [3]byte{00, 0xFF, 00},\n\t\t\"blue\": [3]byte{00, 00, 0xFF},\n\t\t\"black\": [3]byte{00, 00, 00},\n\t\t\"white\": [3]byte{0xFF, 0xFF, 0xFF},\n\t}\n\tfor c, v := range cs {\n\t\tl.QuickColor(c)\n\t\tt.Check(l.Red, Equals, v[0])\n\t\tt.Check(l.Green, Equals, v[1])\n\t\tt.Check(l.Blue, Equals, v[2])\n\t}\n}", "func HiRed(format string, a ...interface{}) { colorPrint(FgHiRed, format, a...) }", "func RandColor(dst inter.Adder, n, m, k int) {\n\tg := RandGraph(n, m)\n\tvar mkVar = func(n, c int) z.Var {\n\t\treturn z.Var(n*c + c + 1)\n\t}\n\tfor i := range g {\n\t\tfor j := 0; j < k; j++ {\n\t\t\tm := mkVar(i, j).Pos()\n\t\t\tdst.Add(m)\n\t\t}\n\t\tdst.Add(0)\n\t}\n\tfor a, es := range g {\n\t\tfor _, b := range es {\n\t\t\tif b >= a {\n\t\t\t\tcontinue\n\t\t\t}\n\t\t\tfor c := 0; c < k; c++ {\n\t\t\t\ta := mkVar(a, c).Neg()\n\t\t\t\tb := mkVar(b, c).Neg()\n\t\t\t\tdst.Add(a)\n\t\t\t\tdst.Add(b)\n\t\t\t}\n\t\t\tdst.Add(0)\n\t\t}\n\t}\n}", "func (o GoogleCloudRetailV2alphaColorInfoResponseOutput) Colors() pulumi.StringArrayOutput {\n\treturn o.ApplyT(func(v GoogleCloudRetailV2alphaColorInfoResponse) []string { return v.Colors }).(pulumi.StringArrayOutput)\n}", "func Red(v ...interface{}) string {\n\treturn fmt.Sprintf(\"%c[1;0;31m%s%c[0m\", 0x1B, v, 0x1B)\n}", "func Colored(c int, b []byte) []byte {\n\treturn concat(ansi[c].Chars, b, ansi[Reset].Chars)\n}", "func appendHLColor(hl []byte, n int, hlType byte) []byte {\n\treturn append(hl, bytes.Repeat([]byte{hlType}, n)...)\n}", "func SliceToHex(colors [5]color.Color, treshold int) uint8 {\n\tresult := uint8(0)\n\tfor index, c := range colors {\n\t\tr, g, b, _ := c.RGBA()\n\t\tlum := 0.299*float64(r) + 0.587*float64(g) + 0.114*float64(b)\n\n\t\tgrayness := uint8(lum / 256) // keep highest 8 bits\n\t\t//\t\tfmt.Printf(\"\\t\\t%10d %10d %v\\n\", int64(lum), grayness, grayness > 0x80)\n\t\tif grayness > uint8(treshold) {\n\t\t\tresult |= (uint8(1) << uint8(index))\n\t\t}\n\t\tif index >= 4 {\n\t\t\tbreak\n\t\t}\n\t}\n\treturn result\n}", "func Colors() *DefinedColors {\n\tif definedColors == nil {\n\t\tdefinedColors = new(DefinedColors)\n\t}\n\treturn definedColors\n}", "func COLORSn(n uint) Component {\n\t//aiComponent_COLORSn(n) (1u << (n+20u))\n\treturn Component(1 << (n + 20))\n}", "func grey() (g [256]color.Color) {\n\tfor i := 0; i < 256; i++ {\n\t\tg[i] = color.Gray{Y: uint8(i)}\n\t}\n\treturn g\n}", "func colors2code(colors ...Color) string {\n\tif len(colors) == 0 {\n\t\treturn \"\"\n\t}\n\n\tvar codes []string\n\tfor _, c := range colors {\n\t\tcodes = append(codes, c.String())\n\t}\n\n\treturn strings.Join(codes, \";\")\n}", "func colorsOf(nodes graph.Nodes, coloring map[int64]int) set.Ints {\n\tc := make(set.Ints, nodes.Len())\n\tfor nodes.Next() {\n\t\tused, ok := coloring[nodes.Node().ID()]\n\t\tif ok {\n\t\t\tc.Add(used)\n\t\t}\n\t}\n\treturn c\n}", "func (o GoogleCloudRetailV2alphaColorInfoPtrOutput) Colors() pulumi.StringArrayOutput {\n\treturn o.ApplyT(func(v *GoogleCloudRetailV2alphaColorInfo) []string {\n\t\tif v == nil {\n\t\t\treturn nil\n\t\t}\n\t\treturn v.Colors\n\t}).(pulumi.StringArrayOutput)\n}", "func TrueColor(r uint8, g uint8, b uint8) string {\n\treturn fmt.Sprintf(\"38;%d;%d;%d\", r, g, b)\n}", "func getColorIndex(temp float64) int {\n\tif temp < *minTemp {\n\t\treturn 0\n\t}\n\tif temp > *maxTemp {\n\t\treturn len(colors) - 1\n\t}\n\treturn int((temp - *minTemp) * float64(len(colors)-1) / (*maxTemp - *minTemp))\n}", "func print_color(chunks []Chunk) {\n\tc := 1\n\tfor i := range chunks {\n\t\tpayload := chunks[i].payload\n\t\ttag := chunks[i].tag\n\t\tvar x int\n\t\tif tag == \"\" {\n\t\t\tx = 7 // white\n\t\t} else {\n\t\t\tx = c\n\t\t\tc++\n\t\t\tif c > 6 {\n\t\t\t\tc = 1\n\t\t\t}\n\t\t}\n\t\tcolor := \"\\x1b[3\" + strconv.Itoa(x) + \"m\"\n\t\tfmt.Printf(\"%s%s\", color, payload)\n\t}\n\tfmt.Println()\n}", "func randColor(i int) string {\n\tswitch i {\n\tcase 0:\n\t\treturn \"red\"\n\tcase 1:\n\t\treturn \"blue\"\n\tcase 2:\n\t\treturn \"green\"\n\tcase 3:\n\t\treturn \"yellow\"\n\t}\n\treturn \"\"\n}", "func Default(s float64) *Palette {\n\tvar p Palette\n\n\tfor x := 0; x < 256; x++ {\n\t\tr := (128.0 + 128*math.Sin(math.Pi*float64(x)/16.0)) / 256.0\n\t\tg := (128.0 + 128*math.Sin(math.Pi*float64(x)/128.0)) / 256.0\n\t\tb := (8.0) / 256.0\n\n\t\tp[x] = colorful.Color{r, g, b}\n\t}\n\n\treturn &p\n}", "func HiRedString(format string, a ...interface{}) string { return colorString(format, FgHiRed, a...) }", "func main() {\n\tvar nums []int\n\tpp.Println(\"=========================================\")\n\tnums = []int{2, 0, 2, 1, 1, 0}\n\tsortColors(nums)\n\tfmt.Println(nums)\n\tfmt.Println([]int{0, 0, 1, 1, 2, 2})\n\tpp.Println(\"=========================================\")\n\tnums = []int{2, 0, 1}\n\tsortColors(nums)\n\tfmt.Println(nums)\n\tfmt.Println([]int{0, 1, 2})\n\tpp.Println(\"=========================================\")\n\tnums = []int{2, 1, 0, 1, 2}\n\tsortColors(nums)\n\tfmt.Println(nums)\n\tfmt.Println([]int{0, 1, 1, 2, 2})\n\tpp.Println(\"=========================================\")\n}", "func Rainbow(colors int, start, end Hue, sat, val, alpha float64) Palette {\n\tp := make(palette, colors)\n\thd := float64(end-start) / float64(colors-1)\n\tc := HSVA{V: val, S: sat, A: alpha}\n\tfor i := range p {\n\t\tc.H = float64(start) + float64(i)*hd\n\t\tp[i] = color.NRGBAModel.Convert(c)\n\t}\n\n\treturn p\n}", "func RedString(format string, a ...interface{}) string { return colorString(format, FgRed, a...) }", "func GetColors(c *fiber.Ctx) error {\n\tdb := database.DBConn\n\tvar colors []models.Color\n\tdb.Find(&colors)\n\treturn c.JSON(colors)\n}", "func (ctl *Controller) SetColours(clrs []Colour) {\n\tfor pos, c := range clrs {\n\t\tif pos >= ctl.count {\n\t\t\treturn\n\t\t}\n\t\tctl.SetColour(pos, c)\n\t}\n}", "func Get(img image.Image, n int) []color.Color {\n\tbuckets := gatherColorBuckets(img, defaultThreshold)\n\tsort.Sort(buckets)\n\n\tif len(buckets) > n {\n\t\tbuckets = buckets[:n]\n\t}\n\n\tcolors := make([]color.Color, len(buckets))\n\tfor idx, b := range buckets {\n\t\tcolors[idx] = b.mean()\n\t}\n\n\treturn colors\n}", "func colorPair(c color.Color) (hi, lo color.Color) {\n\tr, g, b, a := c.RGBA()\n\tr >>= 8\n\tg >>= 8\n\tb >>= 8\n\ta >>= 8\n\tmaxd := uint32(40)\n\tif r < maxd {\n\t\tmaxd = r\n\t}\n\tif g < maxd {\n\t\tmaxd = g\n\t}\n\tif b < maxd {\n\t\tmaxd = b\n\t}\n\tif r > 128 && (255-r) < maxd {\n\t\tmaxd = (255 - r)\n\t}\n\tif g > 128 && (255-g) < maxd {\n\t\tmaxd = (255 - g)\n\t}\n\tif b > 128 && (255-b) < maxd {\n\t\tmaxd = (255 - b)\n\t}\n\thi = color.RGBA{\n\t\tR: uint8(r + maxd),\n\t\tG: uint8(g + maxd),\n\t\tB: uint8(b + maxd),\n\t\tA: uint8(a),\n\t}\n\tlo = color.RGBA{\n\t\tR: uint8(r - maxd),\n\t\tG: uint8(g - maxd),\n\t\tB: uint8(b - maxd),\n\t\tA: uint8(a),\n\t}\n\treturn hi, lo\n}", "func Cyan(format string, a ...interface{}) { colorPrint(FgCyan, format, a...) }", "func ColorTable(target uint32, internalformat uint32, width int32, format uint32, xtype uint32, table unsafe.Pointer) {\n C.glowColorTable(gpColorTable, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), table)\n}", "func fill(pix []byte, c color.RGBA) {\n\tfor i := 0; i < len(pix); i += 4 {\n\t\tpix[i] = c.R\n\t\tpix[i+1] = c.G\n\t\tpix[i+2] = c.B\n\t\tpix[i+3] = c.A\n\t}\n}", "func SetColors(n map[int]string) map[int]string {\n\told := colors\n\tcolors = n\n\treturn old\n}", "func Colorize(x string) string {\n\tattr := 0\n\tfg := 39\n\tbg := 49\n\n\tfor _, key := range x {\n\t\tc, ok := codeMap[int(key)]\n\t\tswitch {\n\t\tcase !ok:\n\t\t\tlog.Printf(\"Wrong color syntax: %c\", key)\n\t\tcase 0 <= c && c <= 8:\n\t\t\tattr = c\n\t\tcase 30 <= c && c <= 37:\n\t\t\tfg = c\n\t\tcase 40 <= c && c <= 47:\n\t\t\tbg = c\n\t\t}\n\t}\n\treturn fmt.Sprintf(\"\\033[%d;%d;%dm\", attr, fg, bg)\n}", "func loadColorBuckets(colorPath string) ([]colorBucket, string, string, error) {\n buckets := make([]colorBucket, 0)\n multiId := \"\"\n whiteId := \"\"\n\n colorFile, err := os.Open(colorPath)\n if err != nil { return buckets, multiId, whiteId, err}\n defer colorFile.Close()\n\n rdr := csv.NewReader(colorFile)\n idx := 0\n for {\n record, err := rdr.Read()\n if err == io.EOF { break }\n if err != nil { return buckets, multiId, whiteId, err }\n\n if len(record) != CSV_RECORD_LENGTH {\n return buckets, multiId, whiteId, errors.New(\"Malformed color csv file\")\n }\n\n if record[2] == MULTI_CODE {\n multiId = record[0]\n continue\n }\n if record[1] == \"White\" || record[1] == \"white\" {\n whiteId = record[0]\n }\n\n lab, err := converter.HexStringToLab(record[2])\n if err != nil { return buckets, multiId, whiteId, err }\n\n buckets = append(buckets, colorBucket{\n colorId: record[0],\n colorName: record[1],\n labColor: lab,\n })\n\n idx++\n }\n\n if multiId == \"\" { return buckets, multiId, whiteId, errors.New(\"No multival given\")}\n return buckets, multiId, whiteId, nil\n}", "func Colourize(parts [][]string) [][]string {\n\tvar colourized [][]string\n\n\tfor i, p := range parts {\n\t\tvar rowParts []string\n\n\t\tfor _, rp := range p {\n\t\t\t// In case we deal with the first row we colourize the header parts.\n\t\t\tif i == 0 {\n\t\t\t\trp = color.CyanString(rp)\n\t\t\t}\n\t\t\trowParts = append(rowParts, rp)\n\t\t}\n\n\t\tcolourized = append(colourized, rowParts)\n\t}\n\n\treturn colourized\n}", "func formatToCsv(file string, colors []Hexcode) [4]string {\n\tvar data [4]string\n\tdata[0] = file\n\tfor k, v := range colors {\n\t\tdata[k+1] = v.Key\n\t}\n\treturn data\n}", "func ColorCount() int {\n\treturn palette.count\n}", "func Color(value color.Color) *SimpleElement { return newSEColor(\"color\", value) }", "func defaultColors(colors Colors) Colors {\n\tif colors.Black == \"\" {\n\t\tcolors.Black = DefaultColors.Black\n\t}\n\n\tif colors.Red == \"\" {\n\t\tcolors.Red = DefaultColors.Red\n\t}\n\n\tif colors.Green == \"\" {\n\t\tcolors.Green = DefaultColors.Green\n\t}\n\n\tif colors.Yellow == \"\" {\n\t\tcolors.Yellow = DefaultColors.Yellow\n\t}\n\n\tif colors.Blue == \"\" {\n\t\tcolors.Blue = DefaultColors.Blue\n\t}\n\n\tif colors.Magenta == \"\" {\n\t\tcolors.Magenta = DefaultColors.Magenta\n\t}\n\n\tif colors.Cyan == \"\" {\n\t\tcolors.Cyan = DefaultColors.Cyan\n\t}\n\n\tif colors.White == \"\" {\n\t\tcolors.White = DefaultColors.White\n\t}\n\n\tif colors.Reset == \"\" {\n\t\tcolors.Reset = DefaultColors.Reset\n\t}\n\n\treturn colors\n}", "func makeRamp(colorA, colorB string, steps float64) (s []string) {\n\tcA, _ := colorful.Hex(colorA)\n\tcB, _ := colorful.Hex(colorB)\n\n\tfor i := 0.0; i < steps; i++ {\n\t\tc := cA.BlendLuv(cB, i/steps)\n\t\ts = append(s, colorToHex(c))\n\t}\n\treturn\n}", "func Yellow(format string, a ...interface{}) { colorPrint(FgYellow, format, a...) }", "func New() Colored {\n\treturn Colored{}\n}", "func Green(format string, a ...interface{}) { colorPrint(FgGreen, format, a...) }", "func rotateColorSpace(green_magenta, red_cyan, blue_yellow int) (red, green, blue int) {\n red = (green_magenta + blue_yellow )/2\n green = (red_cyan + blue_yellow )/2\n blue = (green_magenta + red_cyan )/2\n return\n}", "func BgColor(value color.Color) *SimpleElement { return newSEColor(\"bgColor\", value) }", "func HiBlack(format string, a ...interface{}) { colorPrint(FgHiBlack, format, a...) }", "func PreconvertColors() {\r\n\tfor name, color := range colors {\r\n\t\tcolorsBRS[name] = brs.ConvertColor(color)\r\n\t}\r\n}", "func colors(w http.ResponseWriter, req *http.Request) {\n\t// if method is get\n\tif req.Method == http.MethodGet {\n\t\t// grabs the color hex from the request\n\t\tc := req.FormValue(\"color\")\n\t\t// if one color is not specified get them all\n\t\tif c == \"\" {\n\t\t\tgetColors(w)\n\t\t\treturn\n\t\t}\n\t\t// gets the specific color asked for\n\t\tgetColor(w, c)\n\t\treturn\n\t}\n\t// if the request is a post method, add the color to the db.\n\tif req.Method == http.MethodPost {\n\t\taddColor(w, req)\n\t\treturn\n\t}\n\t// if the Method is a patch methd update the color\n\tif req.Method == http.MethodPatch {\n\t\teditColor(w, req)\n\t\treturn\n\t}\n}", "func ColorTable(target uint32, internalformat uint32, width int32, format uint32, xtype uint32, table unsafe.Pointer) {\n\tC.glowColorTable(gpColorTable, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), table)\n}", "func (rgbw *Rgbw) SetRed(r uint8) {\n\trgbw[0] = r\n}", "func TestColorCount(t *testing.T) {\n fmt.Printf(\"Testing up to %v palettes may take a while...\\n\", 100)\n for i := 0; i < 100; i++ {\n //pal, err := SoftPaletteEx(i, SoftPaletteGenSettings{nil, 50, true})\n pal, err := SoftPalette(i)\n if err != nil {\n t.Errorf(\"Error: %v\", err)\n }\n\n // Check the color count of the palette\n if len(pal) != i {\n t.Errorf(\"Requested %v colors but got %v\", i, len(pal))\n }\n\n // Also check whether all colors exist in RGB space.\n for icol, col := range pal {\n if !col.IsValid() {\n t.Errorf(\"Color %v in palette of %v is invalid: %v\", icol, len(pal), col)\n }\n }\n }\n fmt.Println(\"Done with that, but more tests to run.\")\n}", "func Blue(format string, a ...interface{}) { colorPrint(FgBlue, format, a...) }", "func (h *Heuristics) ShowColors() {\n\t\n\tfmt.Println(\"colors :: \")\n\tfor k, v := range h.colors {\n\t\tif v == 0 {\n\t\t\tfmt.Println(\"Need[\", k+1, \"] = \", h.need[k], \" Utility[\", k+1, \"] = \", h.utility[k])\n\t\t} else {\n\t\t\tfmt.Print(\"Colors[\", k+1, \"] = \", h.colors[k], \"\\t\")\n\t\t\tneighbors := h.g.AdjList[k]\n\t\t\tfor _, value := range neighbors {\n\t\t\t\tfmt.Print(value, \"\\t\")\n\t\t\t}\n\t\t\tfmt.Print(\"\\n\")\n\t\t}\n\t}\n\tfmt.Print(\"\\n\")\n}", "func HiBlue(format string, a ...interface{}) { colorPrint(FgHiBlue, format, a...) }", "func (n *Node) generateUniqueColor() {\n\tif colorIter == 13 {\n\t\tcolorIter = 0\n\t}\n\n\tn.Color = colors[colorIter]\n\tcolorIter++\n}", "func PaletteFrom(array []byte) *Palette {\n\tvar palette Palette\n\n\tfor i:= 0 ; i < 15 ; i++ {\n\t\tr := array[i * 2]\n\t\tgb := array[i * 2 + 1]\n\t\tpalette[i] = color.RGBA{r & 0xF * 17, (gb >> 4) * 17, gb & 0xF * 17, 0xff}\n\t}\n\tpalette[15] = color.RGBA{0x00, 0x00, 0x00, 0x00}\n\treturn &palette\n}", "func PossibleURIColorValues() []URIColor {\n\treturn []URIColor{\n\t\tURIColorBlueColor,\n\t\tURIColorGreenColor,\n\t\tURIColorRedColor,\n\t}\n}", "func (b *BoardTest) TestHexColors(t *C) {\n\tl := new(RGBLED, 9, 10, 11)\n\tl.Red = 02 // Test padding\n\tl.Green = 255 // largest\n\tl.Blue = 0 // Zero\n\tt.check(l.HexString(), Equals, \"02FF00\")\n}", "func GetHueColors(nbColors int, imgData []byte) (colors []CIExyY, params string, err error) {\n\t// Decode data as image\n\timg, _, err := image.Decode(bytes.NewBuffer(imgData))\n\tif err != nil {\n\t\terr = fmt.Errorf(\"can't decode data as image: %v\", err)\n\t\treturn\n\t}\n\t// Create each set\n\tvar RGBcolors []prominentcolor.ColorItem\n\tpossibilities := make(ColorSets, len(prominentcolorsParams))\n\tfor index, param := range prominentcolorsParams {\n\t\t// Extract main colors with current params\n\t\tRGBcolors, err = prominentcolor.KmeansWithAll(nbColors, img, param,\n\t\t\tprominentcolor.DefaultSize, prominentcolor.GetDefaultMasks())\n\t\tif err != nil {\n\t\t\terr = fmt.Errorf(\"prominent colors extraction failed with params '%s': %v\", genPColorParamsString(param), err)\n\t\t\treturn\n\t\t}\n\t\t// Add them to the list\n\t\tpossibilities[index] = NewColorSet(RGBcolors, param)\n\t}\n\t// Get the set with the most differents colors\n\tsort.Sort(sort.Reverse(possibilities))\n\t// Build the answer\n\tparams = possibilities[0].GetPColorParamsString()\n\tcolors = make([]CIExyY, nbColors)\n\tfor index, color := range possibilities[0].GetColorfullSet() {\n\t\tcolors[index].X, colors[index].Y, colors[index].Luminance = color.Xyy()\n\t}\n\treturn\n}", "func constructColorMap(limit float64, colorized bool) ColorMap {\n\tif colorized {\n\t\treturn func(x float64) (uint8, uint8, uint8) {\n\t\t\tr, g, b, _ := colorful.Hsl(x/limit-180, saturation, luminance*(1-x/limit)).RGBA()\n\t\t\treturn uint8(r), uint8(g), uint8(b)\n\t\t}\n\t} else {\n\t\treturn func(x float64) (uint8, uint8, uint8) {\n\t\t\tc := uint8(255 * x / limit)\n\t\t\treturn c, c, c\n\t\t}\n\t}\n}", "func extractSwatches(src *image.RGBA, numColors int) []colorful.Color {\n\tconst (\n\t\tW = 400\n\t\tH = 75\n\t)\n\tvar swatches []colorful.Color\n\tb := src.Bounds()\n\tsw := W / numColors\n\tfor i := 0; i < numColors; i++ {\n\t\tm := src.SubImage(trimRect(image.Rect(b.Min.X+i*sw, b.Max.Y-H, b.Min.X+(i+1)*sw, b.Max.Y), 10))\n\t\tswatches = append(swatches, toColorful(averageColor(m)))\n\t\tsavePNG(strconv.Itoa(i), m) // for debugging\n\t}\n\tconst dim = 50\n\tm := image.NewRGBA(image.Rect(0, 0, dim*len(swatches), dim))\n\tfor i, c := range swatches {\n\t\tr := image.Rect(i*dim, 0, (i+1)*dim, dim)\n\t\tdraw.Draw(m, r, &image.Uniform{fromColorful(c)}, image.ZP, draw.Src)\n\t}\n\tsavePNG(\"swatches\", m) // for debugging\n\treturn swatches\n}", "func Heat(colors int, alpha float64) Palette {\n\tp := make(palette, colors)\n\tj := colors / 4\n\ti := colors - j\n\n\thd := float64(Yellow-Red) / float64(i-1)\n\tc := HSVA{V: 1, S: 1, A: alpha}\n\tfor k := range p[:i] {\n\t\tc.H = float64(Red) + float64(k)*hd\n\t\tp[k] = color.NRGBAModel.Convert(c)\n\t}\n\tif j == 0 {\n\t\treturn p\n\t}\n\n\tc.H = float64(Yellow)\n\tstart, end := 1-1/(2*float64(j)), 1/(2*float64(j))\n\tc.S = start\n\tsd := (end - start) / float64(j-1)\n\tfor k := range p[i:] {\n\t\tc.S = start + float64(k)*sd\n\t\tp[k+i] = color.NRGBAModel.Convert(c)\n\t}\n\n\treturn p\n}", "func (c *Color) Set(value string) error {\n\n\tif !strings.HasPrefix(value, \"#\") {\n\t\treturn errors.New(\"Colours must start with a #\")\n\t}\n\n\tchars := strings.Split(value, \"\")\n\n\tif len(chars) != 7 {\n\t\treturn errors.New(\"Colour string is not the right length\")\n\t}\n\n\trString := strings.Join(chars[1:3], \"\")\n\tgString := strings.Join(chars[3:5], \"\")\n\tbString := strings.Join(chars[5:7], \"\")\n\n\tr, err := strconv.ParseUint(rString, 16, 32)\n\tif err != nil {\n\t\treturn errors.New(\"Invalid hexadecimal number (red)\")\n\t}\n\n\tg, err := strconv.ParseUint(gString, 16, 32)\n\tif err != nil {\n\t\treturn errors.New(\"Invalid hexadecimal number (green)\")\n\t}\n\n\tb, err := strconv.ParseUint(bString, 16, 32)\n\tif err != nil {\n\t\treturn errors.New(\"Invalid hexadecimal number (blue)\")\n\t}\n\n\tc.R = uint8(r)\n\tc.G = uint8(g)\n\tc.B = uint8(b)\n\tc.A = 255\n\n\treturn nil\n}" ]
[ "0.70033413", "0.65414596", "0.6218888", "0.61678225", "0.61441046", "0.6124971", "0.60197467", "0.5992145", "0.58543175", "0.58477825", "0.57905287", "0.5769831", "0.57049125", "0.56985646", "0.56981", "0.56568223", "0.5587713", "0.5554854", "0.5528026", "0.549864", "0.5485356", "0.54774857", "0.5466469", "0.54542816", "0.54540664", "0.54526204", "0.5448137", "0.5437212", "0.5412478", "0.53891474", "0.5378455", "0.53777665", "0.5377245", "0.5360539", "0.53573316", "0.535715", "0.5331176", "0.5320558", "0.53139454", "0.52747494", "0.5270191", "0.52664864", "0.52534944", "0.52401775", "0.5229218", "0.52096933", "0.5194963", "0.518247", "0.51632214", "0.51620346", "0.5137353", "0.5133825", "0.51052964", "0.51043254", "0.50992244", "0.50881416", "0.508346", "0.50550884", "0.5042046", "0.5034228", "0.5029988", "0.5028905", "0.49908948", "0.4985435", "0.4966625", "0.49595723", "0.49541974", "0.4951019", "0.4949876", "0.49440604", "0.49434087", "0.49316767", "0.49228773", "0.49149188", "0.49104175", "0.48957962", "0.48947603", "0.48939323", "0.48895", "0.48892578", "0.48888075", "0.48875034", "0.48831567", "0.4862655", "0.48571718", "0.48546368", "0.48468435", "0.48298797", "0.48291007", "0.48288518", "0.48257315", "0.482104", "0.48141253", "0.48085544", "0.4802215", "0.4801231", "0.47981542", "0.4785854", "0.47672382", "0.47629446", "0.47580191" ]
0.0
-1
respecify a portion of a color table
func ColorSubTable(target uint32, start int32, count int32, format uint32, xtype uint32, data unsafe.Pointer) { C.glowColorSubTable(gpColorSubTable, (C.GLenum)(target), (C.GLsizei)(start), (C.GLsizei)(count), (C.GLenum)(format), (C.GLenum)(xtype), data) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func ColorSubTable(target uint32, start int32, count int32, format uint32, xtype uint32, data unsafe.Pointer) {\n C.glowColorSubTable(gpColorSubTable, (C.GLenum)(target), (C.GLsizei)(start), (C.GLsizei)(count), (C.GLenum)(format), (C.GLenum)(xtype), data)\n}", "func CopyColorSubTable(target uint32, start int32, x int32, y int32, width int32) {\n C.glowCopyColorSubTable(gpCopyColorSubTable, (C.GLenum)(target), (C.GLsizei)(start), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func CopyColorSubTable(target uint32, start int32, x int32, y int32, width int32) {\n\tC.glowCopyColorSubTable(gpCopyColorSubTable, (C.GLenum)(target), (C.GLsizei)(start), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func ColorTable(target uint32, internalformat uint32, width int32, format uint32, xtype uint32, table unsafe.Pointer) {\n C.glowColorTable(gpColorTable, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), table)\n}", "func CopyColorTable(target uint32, internalformat uint32, x int32, y int32, width int32) {\n C.glowCopyColorTable(gpCopyColorTable, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func ColorTable(target uint32, internalformat uint32, width int32, format uint32, xtype uint32, table unsafe.Pointer) {\n\tC.glowColorTable(gpColorTable, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), table)\n}", "func CopyColorTable(target uint32, internalformat uint32, x int32, y int32, width int32) {\n\tC.glowCopyColorTable(gpCopyColorTable, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func GetColorTable(target uint32, format uint32, xtype uint32, table unsafe.Pointer) {\n C.glowGetColorTable(gpGetColorTable, (C.GLenum)(target), (C.GLenum)(format), (C.GLenum)(xtype), table)\n}", "func Color(foreColor, backColor, mode gb.UINT8) {}", "func getPieceColor(square uint8) int {\n\treturn int((square & ColorMask) >> 2)\n}", "func (c Chessboard) pieceColorOnPosition(pos int) int {\n if c.boardSquares[pos] < 0 {\n return -1\n }\n\n return int(c.boardSquares[pos] / 10)\n}", "func color(r geometry.Ray, world geometry.Hitable, depth int) geometry.Vector {\n\thit, record := world.CheckForHit(r, 0.001, math.MaxFloat64)\n\n\t// if hit {\n\t// \ttarget := record.Point.Add(record.Normal).Add(RandomInUnitSphere())\n\t// \treturn color(&geometry.Ray{Origin: record.Point, Direction: target.Subtract(record.P)}, world).Scale(0.5)\n\t// }\n\n\tif hit {\n\t\tif depth < 50 {\n\t\t\tscattered, scatteredRay := record.Scatter(r, record)\n\t\t\tif scattered {\n\t\t\t\tnewColor := color(scatteredRay, world, depth+1)\n\t\t\t\treturn record.Material.Albedo().Multiply(newColor)\n\t\t\t}\n\t\t}\n\t}\n\n\t// Make unit vector so y is between -1.0 and 1.0\n\tunitDirection := r.Direction.Normalize()\n\n\tvar t float64 = 0.5 * (unitDirection.Y + 1.0)\n\n\t// The two vectors here are what creates the sky(Blue to white gradient of the background)\n\treturn geometry.Vector{X: 1.0, Y: 1.0, Z: 1.0}.Scale(1.0 - t).Add(geometry.Vector{X: 0.5, Y: 0.7, Z: 1.0}.Scale(t))\n}", "func COLORSn(n uint) Component {\n\t//aiComponent_COLORSn(n) (1u << (n+20u))\n\treturn Component(1 << (n + 20))\n}", "func (c *Color) Sub(dc Color) {\n\tr, g, b, a := c.RGBA() // uint32\n\tr = (r >> 8) - uint32(dc.R)\n\tg = (g >> 8) - uint32(dc.G)\n\tb = (b >> 8) - uint32(dc.B)\n\ta = (a >> 8) - uint32(dc.A)\n\tif r > 255 { // overflow\n\t\tr = 0\n\t}\n\tif g > 255 {\n\t\tg = 0\n\t}\n\tif b > 255 {\n\t\tb = 0\n\t}\n\tif a > 255 {\n\t\ta = 0\n\t}\n\tc.SetUInt8(uint8(r), uint8(g), uint8(b), uint8(a))\n}", "func printColored(boundaries []colored_data, data []byte) []string {\n\tgrouping := 2\n\tper_line := 16\n\t// 16 bytes per line, grouped by 2 bytes\n\tnlines := len(data) / 16\n\tif len(data) % 16 > 0 {\n\t\tnlines++\n\t}\n\t\n\tout := make([]string, nlines)\n\n\tkolo := \"\\x1B[0m\"\n\t\n\tfor line := 0; line < nlines; line++ {\n\t\ts := \"\\t0x\"\n\t\txy := make([]byte, 2)\n\t\tline_offset := line * per_line\n\t\txy[0] = byte(line_offset >> 8)\n\t\txy[1] = byte(line_offset & 0xff)\n\t\ts = s + hex.EncodeToString(xy) + \":\\t\" + kolo\n\n\n\t\tline_length := per_line\n\t\tif line == nlines - 1 && len(data) % 16 > 0 {\n\t\t\tline_length = len(data) % 16\n\t\t}\n\n\t\tfor b := 0; b < line_length; b++ {\n\t\t\ttotal_offset := line * per_line + b\n\n\t\t\t// inserting coulourings\n\t\t\tfor x := 0; x < len(boundaries); x++ {\n\t\t\t\t//fmt.Println(\"!\")\n\t\t\t\tif(boundaries[x].offset == uint16(total_offset)) {\n\t\t\t\t\ts = s + boundaries[x].color\n\t\t\t\t\tkolo = boundaries[x].color\n\t\t\t\t}\n\t\t\t}\n\t\n\t\t\t// add byte from total_offset\n\t\t\txxx := make([]byte, 1)\n\t\t\txxx[0] = data[total_offset]\n\t\t\ts = s + hex.EncodeToString(xxx)\n\t\t\t\n\t\t\t// if b > 0 && b % grouping == 0, insert space\n\t\t\t\n\t\t\tif b > 0 && (b-1) % grouping == 0 {\n\t\t\t\ts = s + \" \"\n\t\t\t}\n\t\t\t\n\t\t}\n\t\t\n\t\tout[line] = s + COLOR_NORMAL\n\t}\n\t\n\treturn out\n}", "func (x *ImgSpanner) SpanColorFunc(yi, xi0, xi1 int, ma uint32) {\n\ti0 := (yi)*x.stride + (xi0)*4\n\ti1 := i0 + (xi1-xi0)*4\n\tcx := xi0\n\n\tfor i := i0; i < i1; i += 4 {\n\t\t// uses the Porter-Duff composition operator.\n\t\trcr, rcg, rcb, rca := x.colorFunc(cx, yi).RGBA()\n\t\tif x.xpixel == true {\n\t\t\trcr, rcb = rcb, rcr\n\t\t}\n\t\tcx++\n\t\ta := (m - (rca * ma / m)) * pa\n\t\tdr := uint32(x.pix[i+0])\n\t\tdg := uint32(x.pix[i+1])\n\t\tdb := uint32(x.pix[i+2])\n\t\tda := uint32(x.pix[i+3])\n\t\tx.pix[i+0] = uint8((dr*a + rcr*ma) / mp)\n\t\tx.pix[i+1] = uint8((dg*a + rcg*ma) / mp)\n\t\tx.pix[i+2] = uint8((db*a + rcb*ma) / mp)\n\t\tx.pix[i+3] = uint8((da*a + rca*ma) / mp)\n\t}\n}", "func nextcolor(c color.RGBA) color.RGBA {\n\tswitch {\n\tcase c.R == 255 && c.G == 0 && c.B == 0:\n\t\tc.G += 5\n\tcase c.R == 255 && c.G != 255 && c.B == 0:\n\t\tc.G += 5\n\tcase c.G == 255 && c.R != 0:\n\t\tc.R -= 5\n\tcase c.R == 0 && c.B != 255:\n\t\tc.B += 5\n\tcase c.B == 255 && c.G != 0:\n\t\tc.G -= 5\n\tcase c.G == 0 && c.R != 255:\n\t\tc.R += 5\n\tdefault:\n\t\tc.B -= 5\n\t}\n\treturn c\n}", "func makeColorLookup(vals []int, length int) []int {\n\tres := make([]int, length)\n\n\tvi := 0\n\tfor i := 0; i < len(res); i++ {\n\t\tif vi+1 < len(vals) {\n\t\t\tif i <= (vals[vi]+vals[vi+1])/2 {\n\t\t\t\tres[i] = vi\n\t\t\t} else {\n\t\t\t\tvi++\n\t\t\t\tres[i] = vi\n\t\t\t}\n\t\t} else if vi < len(vals) {\n\t\t\t// only last vi is valid\n\t\t\tres[i] = vi\n\t\t}\n\t}\n\treturn res\n}", "func calcTableCap(c int) int {\n\tif c <= neighbour {\n\t\treturn c\n\t}\n\treturn c + neighbour - 1\n}", "func colorIsland(grid [][]byte, color byte, nX, nY, x, y int) {\r\n\tif x < 0 || x >= nX || y < 0 || y >= nY || grid[y][x] != '1' {\r\n\t\treturn // no island found\r\n\t}\r\n\tgrid[y][x] = '0' // + byte(color) // // useful for debugging\r\n\t// check adjacent grid squares\r\n\tcolorIsland(grid, color, nX, nY, x - 1, y)\r\n\tcolorIsland(grid, color, nX, nY, x + 1, y)\r\n\tcolorIsland(grid, color, nX, nY, x, y - 1)\r\n\tcolorIsland(grid, color, nX, nY, x, y + 1)\r\n}", "func p256Select(point, table []uint64, idx int)", "func p256Select(point, table []uint64, idx int)", "func GetColorTable(target uint32, format uint32, xtype uint32, table unsafe.Pointer) {\n\tC.glowGetColorTable(gpGetColorTable, (C.GLenum)(target), (C.GLenum)(format), (C.GLenum)(xtype), table)\n}", "func paintFill(image [][]string, c string, y, x int) [][]string {\n\t//range check\n\tif y > len(image)-1 {\n\t\treturn image\n\t}\n\tif x > len(image[y])-1 {\n\t\treturn image\n\t}\n\t//dupe color check\n\tif image[y][x] == c {\n\t\treturn image\n\t}\n\t//identify origin color\n\torig := image[y][x]\n\t//color origin\n\tmImage := image\n\tmImage[y][x] = c\n\t//check for valid left\n\tif x > 0 && mImage[y][x-1] == orig {\n\t\tmImage = paintFill(mImage, c, y, x-1)\n\t}\n\t//check for valid right\n\tif x < len(mImage[y])-1 && mImage[y][x+1] == orig {\n\t\tmImage = paintFill(mImage, c, y, x+1)\n\t}\n\t//check for valid up\n\tif y > 0 && mImage[y-1][x] == orig {\n\t\tmImage = paintFill(mImage, c, y-1, x)\n\t}\n\t//check for valid down\n\tif y < len(mImage)-1 && mImage[y+1][x] == orig {\n\t\tmImage = paintFill(mImage, c, y+1, x)\n\t}\n\treturn mImage\n}", "func RandColor(dst inter.Adder, n, m, k int) {\n\tg := RandGraph(n, m)\n\tvar mkVar = func(n, c int) z.Var {\n\t\treturn z.Var(n*c + c + 1)\n\t}\n\tfor i := range g {\n\t\tfor j := 0; j < k; j++ {\n\t\t\tm := mkVar(i, j).Pos()\n\t\t\tdst.Add(m)\n\t\t}\n\t\tdst.Add(0)\n\t}\n\tfor a, es := range g {\n\t\tfor _, b := range es {\n\t\t\tif b >= a {\n\t\t\t\tcontinue\n\t\t\t}\n\t\t\tfor c := 0; c < k; c++ {\n\t\t\t\ta := mkVar(a, c).Neg()\n\t\t\t\tb := mkVar(b, c).Neg()\n\t\t\t\tdst.Add(a)\n\t\t\t\tdst.Add(b)\n\t\t\t}\n\t\t\tdst.Add(0)\n\t\t}\n\t}\n}", "func TestConstraint(t *testing.T) {\n octant := func(lab ColorLab) bool { return lab.L <= 0.5 && lab.A <= 0.0 && lab.B <= 0.0 }\n\n pal, err := SoftPaletteEx(100, SoftPaletteSettings{octant, 50, true})\n if err != nil {\n t.Errorf(\"Error: %v\", err)\n }\n\n // Check ALL the colors!\n for icol, col := range pal {\n if !col.IsValid() {\n t.Errorf(\"Color %v in constrained palette is invalid: %v\", icol, col)\n }\n\n lab := col.Lab()\n if lab.L > 0.5 || lab.A > 0.0 || lab.B > 0.0 {\n t.Errorf(\"Color %v in constrained palette violates the constraint: %v (lab: %v)\", icol, col, [3]float64{lab.L, lab.A, lab.B})\n }\n }\n}", "func (c Chessboard) validColorPiece(pos int, color int) bool {\n return c.pieceColorOnPosition(pos) == color\n}", "func ColorSamplingPointsForStillColorsVideo(videoW, videoH int) map[string]image.Point {\n\touterCorners := map[string]image.Point{\n\t\t\"outer_top_left\": {1, 1},\n\t\t\"outer_top_right\": {(videoW - 1) - 1, 1},\n\t\t\"outer_bottom_right\": {videoW - 1, videoH - 1},\n\t\t\"outer_bottom_left\": {1, (videoH - 1) - 1},\n\t}\n\tedgeOffset := 5\n\tstencilW := 5\n\tinnerCorners := map[string]image.Point{\n\t\t\"inner_top_left_00\": {edgeOffset, edgeOffset},\n\t\t\"inner_top_left_01\": {edgeOffset, edgeOffset + stencilW},\n\t\t\"inner_top_left_10\": {edgeOffset + stencilW, edgeOffset},\n\t\t\"inner_top_left_11\": {edgeOffset + stencilW, edgeOffset + stencilW},\n\t\t\"inner_top_right_00\": {(videoW - 1) - edgeOffset, edgeOffset},\n\t\t\"inner_top_right_01\": {(videoW - 1) - edgeOffset, edgeOffset + stencilW},\n\t\t\"inner_top_right_10\": {(videoW - 1) - edgeOffset - stencilW, edgeOffset},\n\t\t\"inner_top_right_11\": {(videoW - 1) - edgeOffset - stencilW, edgeOffset + stencilW},\n\t\t\"inner_bottom_right_00\": {(videoW - 1) - edgeOffset, (videoH - 1) - edgeOffset},\n\t\t\"inner_bottom_right_01\": {(videoW - 1) - edgeOffset, (videoH - 1) - edgeOffset - stencilW},\n\t\t\"inner_bottom_right_10\": {(videoW - 1) - edgeOffset - stencilW, (videoH - 1) - edgeOffset},\n\t\t\"inner_bottom_right_11\": {(videoW - 1) - edgeOffset - stencilW, (videoH - 1) - edgeOffset - stencilW},\n\t\t\"inner_bottom_left_00\": {edgeOffset, (videoH - 1) - edgeOffset},\n\t\t\"inner_bottom_left_01\": {edgeOffset, (videoH - 1) - edgeOffset - stencilW},\n\t\t\"inner_bottom_left_10\": {edgeOffset + stencilW, (videoH - 1) - edgeOffset},\n\t\t\"inner_bottom_left_11\": {edgeOffset + stencilW, (videoH - 1) - edgeOffset - stencilW},\n\t}\n\tsamples := map[string]image.Point{}\n\tfor k, v := range innerCorners {\n\t\tsamples[k] = v\n\t}\n\tfor k, v := range outerCorners {\n\t\tsamples[k] = v\n\t}\n\treturn samples\n}", "func (x *ImgSpanner) SpanColorFuncR(yi, xi0, xi1 int, ma uint32) {\n\ti0 := (yi)*x.stride + (xi0)*4\n\ti1 := i0 + (xi1-xi0)*4\n\tcx := xi0\n\tfor i := i0; i < i1; i += 4 {\n\t\trcr, rcg, rcb, rca := x.colorFunc(cx, yi).RGBA()\n\t\tif x.xpixel == true {\n\t\t\trcr, rcb = rcb, rcr\n\t\t}\n\t\tcx++\n\t\tx.pix[i+0] = uint8(rcr * ma / mp)\n\t\tx.pix[i+1] = uint8(rcg * ma / mp)\n\t\tx.pix[i+2] = uint8(rcb * ma / mp)\n\t\tx.pix[i+3] = uint8(rca * ma / mp)\n\t}\n}", "func (r *paintingRobot) scanColor() int {\n for _, p := range r.paintedPoints {\n if p.x == r.position.x && p.y == r.position.y {\n return p.color\n }\n }\n\n return 0\n}", "func StandardTileColorer(frame []byte, stride int) TileColorFunction {\n\treturn func(hTile int, vTile int, lookupArray []byte, mask uint64, indexBitSize uint64) {\n\t\tstart := vTile*TileSideLength*stride + hTile*TileSideLength\n\t\tsingleMask := ^(^uint64(0) << indexBitSize)\n\n\t\tfor i := 0; i < PixelPerTile; i++ {\n\t\t\tpixelValue := lookupArray[(mask>>(indexBitSize*uint64(i)))&singleMask]\n\n\t\t\tif pixelValue != 0x00 {\n\t\t\t\toffset := start + (i % TileSideLength) + stride*(i/TileSideLength)\n\n\t\t\t\tframe[offset] = pixelValue\n\t\t\t}\n\t\t}\n\t}\n}", "func (s *binaryScanner) IsUniformColor(r image.Rectangle, c color.Color) bool {\n\tvar (\n\t\tok bool\n\t\tbit binimg.Bit\n\t)\n\t// ensure c is a binimg.Bit, or convert it\n\tif bit, ok = c.(binimg.Bit); !ok {\n\t\tbit = s.ColorModel().Convert(c).(binimg.Bit)\n\t}\n\n\t// in a binary image, pixel/bytes are 1 or 0, we want the other color for\n\t// bytes.IndexBytes\n\tother := bit.Other().V\n\tfor y := r.Min.Y; y < r.Max.Y; y++ {\n\t\ti := s.PixOffset(r.Min.X, y)\n\t\tj := s.PixOffset(r.Max.X, y)\n\t\t// look for the first pixel that is not c\n\t\tif bytes.IndexByte(s.Pix[i:j], other) != -1 {\n\t\t\treturn false\n\t\t}\n\t}\n\treturn true\n}", "func tableCoords(i int) (col coord, row coord) {\n\trow = (i % 3) * CardHeight\n\tcol = 1 + ((i / 3) * (CardWidth + 2))\n\treturn\n}", "func (c * Case)TakeColor(color int)int8{\n\tif color > len(c.cows){\n\t\treturn 0\n\t}\n\tnb := c.cows[color]\n\tc.cows[color] = 0\n\treturn int8(nb)\n}", "func constructColorMap(limit float64, colorized bool) ColorMap {\n\tif colorized {\n\t\treturn func(x float64) (uint8, uint8, uint8) {\n\t\t\tr, g, b, _ := colorful.Hsl(x/limit-180, saturation, luminance*(1-x/limit)).RGBA()\n\t\t\treturn uint8(r), uint8(g), uint8(b)\n\t\t}\n\t} else {\n\t\treturn func(x float64) (uint8, uint8, uint8) {\n\t\t\tc := uint8(255 * x / limit)\n\t\t\treturn c, c, c\n\t\t}\n\t}\n}", "func (pb *Pbar) ToggleColor(arg interface{}) {\n\tswitch reflect.TypeOf(arg).Kind() {\n\tcase reflect.Slice:\n\t\tcol := reflect.ValueOf(arg)\n\t\tl := col.Len()\n\n\t\tif l < 0 || l > 4 {\n\t\t\tfmt.Println(\"Error: Must provide a number of colors between 0 - 4.\\nSwitching to b/w...\")\n\t\t\tpb.isColor = false\n\t\t\treturn\n\t\t}\n\n\t\tfor i := 0; i < col.Len(); i++ {\n\t\t\tcolStr := col.Index(i).String()\n\t\t\tif _, ok := colors[colStr]; !ok {\n\t\t\t\tfmt.Printf(\"'%s' is not a valid color. Switching to b/w...\\n\\n\", colStr)\n\t\t\t\tpb.isColor = false\n\t\t\t\treturn\n\t\t\t}\n\t\t}\n\n\t\tif l == 4 {\n\t\t\tpb.LOW = colors[(col.Index(0)).String()]\n\t\t\tpb.MEDIUM = colors[(col.Index(1)).String()]\n\t\t\tpb.HIGH = colors[(col.Index(2)).String()]\n\t\t\tpb.FULL = colors[(col.Index(3)).String()]\n\t\t} else if l == 3 {\n\t\t\tpb.LOW = colors[(col.Index(0)).String()]\n\t\t\tpb.MEDIUM = colors[(col.Index(1)).String()]\n\t\t\tpb.HIGH = colors[(col.Index(2)).String()]\n\t\t\tpb.FULL = colors[(col.Index(2)).String()]\n\t\t} else if l == 2 {\n\t\t\tpb.LOW = colors[(col.Index(0)).String()]\n\t\t\tpb.MEDIUM = colors[(col.Index(0)).String()]\n\t\t\tpb.HIGH = colors[(col.Index(1)).String()]\n\t\t\tpb.FULL = colors[(col.Index(1)).String()]\n\t\t} else if l == 1 {\n\t\t\tpb.LOW = colors[(col.Index(0)).String()]\n\t\t\tpb.MEDIUM = colors[(col.Index(0)).String()]\n\t\t\tpb.HIGH = colors[(col.Index(0)).String()]\n\t\t\tpb.FULL = colors[(col.Index(0)).String()]\n\t\t} else {\n\t\t\tpb.isColor = false\n\t\t\treturn\n\t\t}\n\t\tpb.isColor = true\n\tcase reflect.String:\n\t\tcol := reflect.ValueOf(arg)\n\t\tif _, ok := colors[col.String()]; ok {\n\t\t\tpb.LOW = colors[col.String()]\n\t\t\tpb.MEDIUM = colors[col.String()]\n\t\t\tpb.HIGH = colors[col.String()]\n\t\t\tpb.FULL = colors[col.String()]\n\t\t\tpb.isColor = true\n\t\t}\n\t}\n}", "func (nv *NetView) UnitValColor(lay emer.Layer, idx1d int, raw float32, hasval bool) (scaled float32, clr gist.Color) {\n\tif nv.CurVarParams == nil || nv.CurVarParams.Var != nv.Var {\n\t\tok := false\n\t\tnv.CurVarParams, ok = nv.VarParams[nv.Var]\n\t\tif !ok {\n\t\t\treturn\n\t\t}\n\t}\n\tif !hasval {\n\t\tscaled = 0\n\t\tif lay.Name() == nv.Data.PrjnLay && idx1d == nv.Data.PrjnUnIdx {\n\t\t\tclr.SetUInt8(0x20, 0x80, 0x20, 0x80)\n\t\t} else {\n\t\t\tclr = NilColor\n\t\t}\n\t} else {\n\t\tclp := nv.CurVarParams.Range.ClipVal(raw)\n\t\tnorm := nv.CurVarParams.Range.NormVal(clp)\n\t\tvar op float32\n\t\tif nv.CurVarParams.ZeroCtr {\n\t\t\tscaled = float32(2*norm - 1)\n\t\t\top = (nv.Params.ZeroAlpha + (1-nv.Params.ZeroAlpha)*mat32.Abs(scaled))\n\t\t} else {\n\t\t\tscaled = float32(norm)\n\t\t\top = (nv.Params.ZeroAlpha + (1-nv.Params.ZeroAlpha)*0.8) // no meaningful alpha -- just set at 80\\%\n\t\t}\n\t\tclr = nv.ColorMap.Map(float64(norm))\n\t\tr, g, b, a := clr.ToNPFloat32()\n\t\tclr.SetNPFloat32(r, g, b, a*op)\n\t}\n\treturn\n}", "func (b board) at(c coord, cf colorFlags) (bool, bool) {\n\tf := b.fields[c.y][c.x]\n\treturn f&cf.color == cf.color,\n\t\tf&cf.connected == cf.connected\n}", "func colourRow(s tcell.Screen, style tcell.Style, row int) {\n\tfor x := 0; x < windowWidth; x++ {\n\t\ts.SetCell(x, row, style, ' ')\n\t}\n}", "func colFromPosition(pos int) int {\n return pos % 8\n}", "func (r *Rasterizer8BitsSample) fillEvenOdd(img *image.RGBA, c color.Color, clipBound [4]float64) {\n\tvar x, y uint32\n\n\tminX := uint32(clipBound[0])\n\tmaxX := uint32(clipBound[2])\n\n\tminY := uint32(clipBound[1]) >> SUBPIXEL_SHIFT\n\tmaxY := uint32(clipBound[3]) >> SUBPIXEL_SHIFT\n\n\trgba := convert(c)\n\tpixColor := *(*uint32)(unsafe.Pointer(&rgba))\n\n\tcs1 := pixColor & 0xff00ff\n\tcs2 := pixColor >> 8 & 0xff00ff\n\n\tstride := uint32(img.Stride)\n\tvar mask SUBPIXEL_DATA\n\tmaskY := minY * uint32(r.BufferWidth)\n\tminY *= stride\n\tmaxY *= stride\n\tvar tp []uint8\n\tvar pixelx uint32\n\tfor y = minY; y < maxY; y += stride {\n\t\ttp = img.Pix[y:]\n\t\tmask = 0\n\n\t\t//i0 := (s.Y-r.Image.Rect.Min.Y)*r.Image.Stride + (s.X0-r.Image.Rect.Min.X)*4\r\n\t\t//i1 := i0 + (s.X1-s.X0)*4\r\n\t\tpixelx = minX * 4\n\t\tfor x = minX; x <= maxX; x++ {\n\t\t\tmask ^= r.MaskBuffer[maskY+x]\n\t\t\t// 8bits\r\n\t\t\talpha := uint32(coverageTable[mask])\n\t\t\t// 16bits\r\n\t\t\t//alpha := uint32(coverageTable[mask & 0xff] + coverageTable[(mask >> 8) & 0xff])\r\n\t\t\t// 32bits\r\n\t\t\t//alpha := uint32(coverageTable[mask & 0xff] + coverageTable[(mask >> 8) & 0xff] + coverageTable[(mask >> 16) & 0xff] + coverageTable[(mask >> 24) & 0xff])\r\n\n\t\t\t// alpha is in range of 0 to SUBPIXEL_COUNT\r\n\t\t\tp := (*uint32)(unsafe.Pointer(&tp[pixelx]))\n\t\t\tif alpha == SUBPIXEL_FULL_COVERAGE {\n\t\t\t\t*p = pixColor\n\t\t\t} else if alpha != 0 {\n\t\t\t\tinvAlpha := SUBPIXEL_COUNT - alpha\n\t\t\t\tct1 := *p & 0xff00ff * invAlpha\n\t\t\t\tct2 := *p >> 8 & 0xff00ff * invAlpha\n\n\t\t\t\tct1 = (ct1 + cs1*alpha) >> SUBPIXEL_SHIFT & 0xff00ff\n\t\t\t\tct2 = (ct2 + cs2*alpha) << (8 - SUBPIXEL_SHIFT) & 0xff00ff00\n\n\t\t\t\t*p = ct1 + ct2\n\t\t\t}\n\t\t\tpixelx += 4\n\t\t}\n\t\tmaskY += uint32(r.BufferWidth)\n\t}\n}", "func (otuTable *otuTable) ColourTopN(colourStore colour.ColourSketchStore, pad bool) ([][][]color.RGBA, error) {\n\t// attach the colour store\n\totuTable.ColourSketchStore = colourStore\n\t// make the image template\n\trgbaLines := make([][][]color.RGBA, otuTable.GetNumSamples())\n\t// perform for each sample in the OTU table\n\tfor i := range otuTable.sampleNames {\n\t\trgbaLines[i] = make([][]color.RGBA, len(otuTable.topN[i]))\n\t\t// for each sample, range over the topN otus\n\t\tfor j, otu := range otuTable.topN[i] {\n\t\t\t// if OTU is has 0 abundance, add row of padding pixels if requested, else skip this OTU\n\t\t\tif otu.otu == PAD_LINE && !pad {\n\t\t\t\tcontinue\n\t\t\t}\n\t\t\t// lookup the otu in the css\n\t\t\tif cs, ok := otuTable.ColourSketchStore[otu.otu]; !ok {\n\t\t\t\t// TODO: if the topN OTUs are not present in the REFSEQ db, this error will be raised - need to work on handling this event\n\t\t\t\tcontinue\n\t\t\t\t//return nil, fmt.Errorf(\"sample %v: the genus name `%v` (abundance: %d) could not be found in the coloursketches\", string(otuTable.sampleNames[i]), otu.otu, otu.abundance)\n\t\t\t} else {\n\t\t\t\t// make a copy of the colour sketch\n\t\t\t\tcsCopy := cs.CopySketch()\n\t\t\t\t// adjust the colour sketch so that the B slot corresponds to the OTU abundance\n\t\t\t\t// first scale the abundance value to fit the uint8 slot\n\t\t\t\t// TODO: set a customisable cap for abundance values\n\t\t\t\tabunCap := 5000\n\t\t\t\tvar abunVal float32\n\t\t\t\tif otu.abundance > abunCap {\n\t\t\t\t\tabunVal = 255\n\t\t\t\t} else {\n\t\t\t\t\tabunVal = (float32(otu.abundance) / float32(abunCap)) * 255\n\t\t\t\t}\n\t\t\t\t// adjust the B slot\n\t\t\t\tif err := csCopy.Adjust('B', uint8(abunVal)); err != nil {\n\t\t\t\t\treturn nil, err\n\t\t\t\t}\n\t\t\t\t// adjust the A slot so that it is set to visible\n\t\t\t\tif err := csCopy.Adjust('A', 255); err != nil {\n\t\t\t\t\treturn nil, err\n\t\t\t\t}\n\t\t\t\tif rgba, err := csCopy.PrintPNGline(); err != nil {\n\t\t\t\t\treturn nil, err\n\t\t\t\t} else {\n\t\t\t\t\trgbaLines[i][j] = rgba\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\treturn rgbaLines, nil\n}", "func rect(img *image.NRGBA, x1, y1, x2, y2 int, col color.Color) {\r\n\thLine(img, x1, y1, x2, col)\r\n\thLine(img, x1, y2, x2, col)\r\n\tvLine(img, x1, y1, y2, col)\r\n\tvLine(img, x2, y1, y2, col)\r\n}", "func printTable(data []string, color bool) {\n\tvar listType string\n\n\ttable := tablewriter.NewWriter(os.Stdout)\n\n\tswitch color {\n\tcase true:\n\t\tlistType = \"White\"\n\tcase false:\n\t\tlistType = \"Black\"\n\t}\n\n\ttable.SetHeader([]string{\"#\", \"B/W\", \"CIDR\"})\n\n\tfor i, v := range data {\n\t\tl := make([]string, 0)\n\t\tl = append(l, strconv.Itoa(i+offset))\n\t\tl = append(l, listType)\n\t\tl = append(l, v)\n\t\ttable.Append(l)\n\t}\n\n\ttable.Render()\n}", "func combineColor(color ColorName, isBackgroundColor bool) outPutSet {\n\tif color >= COLOR_BLACK && color <= COLOR_WHITE {\n\t\tif isBackgroundColor {\n\t\t\treturn COLOR_BACKGROUND + outPutSet(color)\n\t\t}\n\t\treturn COLOR_FOREGROUND + outPutSet(color)\n\t}\n\treturn 0\n}", "func (v *mandelbrotViewer) color(m float64) color.Color {\n\t_, f := math.Modf(m)\n\tncol := len(palette.Plan9)\n\tc1, _ := colorful.MakeColor(palette.Plan9[int(m)%ncol])\n\tc2, _ := colorful.MakeColor(palette.Plan9[int(m+1)%ncol])\n\tr, g, b := c1.BlendHcl(c2, f).Clamped().RGB255()\n\treturn color.RGBA{r, g, b, 255}\n}", "func (c *Color) Sub(o *Color) *Color {\n\treturn NewColor(\n\t\tc.r-o.r,\n\t\tc.g-o.g,\n\t\tc.b-o.b,\n\t)\n}", "func (w *LDRWrapper) HDRAt(x, y int) hdrcolor.Color {\n\tr, g, b, _ := w.At(x, y).RGBA()\n\treturn hdrcolor.RGB{R: float64(r) / 0xFFFF, G: float64(g) / 0xFFFF, B: float64(b) / 0xFFFF}\n}", "func d10nodeCover(node *d10nodeT) d10rectT {\n\trect := node.branch[0].rect\n\tfor index := 1; index < node.count; index++ {\n\t\trect = d10combineRect(&rect, &(node.branch[index].rect))\n\t}\n\treturn rect\n}", "func calcMask(tableCap uint32) uint32 {\n\tif tableCap <= neighbour {\n\t\treturn tableCap - 1\n\t}\n\treturn tableCap - neighbour // Always has a virtual bucket with neigh slots.\n}", "func colorToMode(c cell.Color, colorMode terminalapi.ColorMode) cell.Color {\n\tif c == cell.ColorDefault {\n\t\treturn c\n\t}\n\tswitch colorMode {\n\tcase terminalapi.ColorModeNormal:\n\t\tc %= 16 + 1 // Add one for cell.ColorDefault.\n\tcase terminalapi.ColorMode256:\n\t\tc %= 256 + 1 // Add one for cell.ColorDefault.\n\tcase terminalapi.ColorMode216:\n\t\tif c <= 216 { // Add one for cell.ColorDefault.\n\t\t\treturn c + 16\n\t\t}\n\t\tc = c%216 + 16\n\tcase terminalapi.ColorModeGrayscale:\n\t\tif c <= 24 { // Add one for cell.ColorDefault.\n\t\t\treturn c + 232\n\t\t}\n\t\tc = c%24 + 232\n\tdefault:\n\t\tc = cell.ColorDefault\n\t}\n\treturn c\n}", "func GenColor(intr int) [][]uint8 {\n\toutput := [][]uint8{}\n\tfor i := 0; i <= 255; i += intr {\n\t\tfor j := 0; j <= 255; j += intr {\n\t\t\tfor k := 0; k <= 255; k += intr {\n\t\t\t\ta := []uint8{uint8(i), uint8(j), uint8(k)}\n\t\t\t\toutput = append(output, a)\n\n\t\t\t}\n\t\t}\n\t}\n\treturn output\n\n}", "func MakeTable(poly uint32) *Table {}", "func d16nodeCover(node *d16nodeT) d16rectT {\n\trect := node.branch[0].rect\n\tfor index := 1; index < node.count; index++ {\n\t\trect = d16combineRect(&rect, &(node.branch[index].rect))\n\t}\n\treturn rect\n}", "func getColorIndex(temp float64) int {\n\tif temp < *minTemp {\n\t\treturn 0\n\t}\n\tif temp > *maxTemp {\n\t\treturn len(colors) - 1\n\t}\n\treturn int((temp - *minTemp) * float64(len(colors)-1) / (*maxTemp - *minTemp))\n}", "func extractSwatches(src *image.RGBA, numColors int) []colorful.Color {\n\tconst (\n\t\tW = 400\n\t\tH = 75\n\t)\n\tvar swatches []colorful.Color\n\tb := src.Bounds()\n\tsw := W / numColors\n\tfor i := 0; i < numColors; i++ {\n\t\tm := src.SubImage(trimRect(image.Rect(b.Min.X+i*sw, b.Max.Y-H, b.Min.X+(i+1)*sw, b.Max.Y), 10))\n\t\tswatches = append(swatches, toColorful(averageColor(m)))\n\t\tsavePNG(strconv.Itoa(i), m) // for debugging\n\t}\n\tconst dim = 50\n\tm := image.NewRGBA(image.Rect(0, 0, dim*len(swatches), dim))\n\tfor i, c := range swatches {\n\t\tr := image.Rect(i*dim, 0, (i+1)*dim, dim)\n\t\tdraw.Draw(m, r, &image.Uniform{fromColorful(c)}, image.ZP, draw.Src)\n\t}\n\tsavePNG(\"swatches\", m) // for debugging\n\treturn swatches\n}", "func d8nodeCover(node *d8nodeT) d8rectT {\n\trect := node.branch[0].rect\n\tfor index := 1; index < node.count; index++ {\n\t\trect = d8combineRect(&rect, &(node.branch[index].rect))\n\t}\n\treturn rect\n}", "func getColor(r Ray, world HittableList, depth int) mgl64.Vec3 {\n\thits := world.Hit(r, Epsilon, math.MaxFloat64)\n\tif len(hits) > 0 {\n\t\t// HittableList makes sure the first (and only) intersection\n\t\t// is the closest one:\n\t\thit := hits[0]\n\t\t// Simulate the light response of this material.\n\t\tisScattered, attenuation, scattered := hit.Mat.Scatter(r, hit)\n\t\t// If this ray is reflected off the surface, determine the response\n\t\t// of the scattered ray:\n\t\tif isScattered && depth < MaxBounces {\n\t\t\tresponse := getColor(scattered, world, depth+1)\n\n\t\t\treturn mgl64.Vec3{response.X() * attenuation.X(),\n\t\t\t\tresponse.Y() * attenuation.Y(),\n\t\t\t\tresponse.Z() * attenuation.Z()}\n\t\t}\n\t\t// Otherwise, the ray was absorbed, or we have exceeded the\n\t\t// maximum number of light bounces:\n\t\treturn mgl64.Vec3{0.0, 0.0, 0.0}\n\t}\n\t// If we don't intersect with anything, plot a background instead:\n\tunitDirection := r.Direction().Normalize()\n\tt := 0.5*unitDirection.Y() + 1.0\n\t// Linearly interpolate between white and blue:\n\tA := mgl64.Vec3{1.0, 1.0, 1.0}.Mul(1.0 - t)\n\tB := mgl64.Vec3{0.5, 0.7, 1.0}.Mul(t)\n\treturn A.Add(B)\n}", "func d9nodeCover(node *d9nodeT) d9rectT {\n\trect := node.branch[0].rect\n\tfor index := 1; index < node.count; index++ {\n\t\trect = d9combineRect(&rect, &(node.branch[index].rect))\n\t}\n\treturn rect\n}", "func chooseColor(height int, lowColor bool) tl.Attr {\n\tif lowColor {\n\t\treturn tl.ColorGreen\n\t}\n\tidx := int(math.Sqrt(float64(height+1))) - 1\n\tif idx >= len(palette) {\n\t\tidx = len(palette) - 1\n\t}\n\treturn tl.Attr(palette[idx])\n}", "func rotateColorSpace(green_magenta, red_cyan, blue_yellow int) (red, green, blue int) {\n red = (green_magenta + blue_yellow )/2\n green = (red_cyan + blue_yellow )/2\n blue = (green_magenta + red_cyan )/2\n return\n}", "func d11nodeCover(node *d11nodeT) d11rectT {\n\trect := node.branch[0].rect\n\tfor index := 1; index < node.count; index++ {\n\t\trect = d11combineRect(&rect, &(node.branch[index].rect))\n\t}\n\treturn rect\n}", "func getTileColor(tile model.Tile) tcell.Style {\n\ttileColor := tcell.StyleDefault.Foreground(tcell.ColorBlack)\n\tswitch tile {\n\tcase 0:\n\t\ttileColor = tileColor.Background(tcell.ColorLightGrey)\n\tcase 2:\n\t\ttileColor = tileColor.Background(tcell.ColorDarkGrey)\n\tcase 4:\n\t\ttileColor = tileColor.Background(tcell.ColorSlateGrey)\n\tcase 8:\n\t\ttileColor = tileColor.Background(tcell.ColorGrey)\n\tcase 16:\n\t\ttileColor = tileColor.Background(tcell.ColorTeal)\n\tcase 32:\n\t\ttileColor = tileColor.Background(tcell.ColorTan)\n\tcase 64:\n\t\ttileColor = tileColor.Background(tcell.ColorOrange)\n\tcase 128:\n\t\ttileColor = tileColor.Background(tcell.ColorDarkOrange)\n\tcase 256:\n\t\ttileColor = tileColor.Background(tcell.ColorOrangeRed)\n\tcase 512:\n\t\ttileColor = tileColor.Background(tcell.ColorRed)\n\tcase 1024:\n\t\ttileColor = tileColor.Background(tcell.ColorDarkRed)\n\tcase 2048:\n\t\ttileColor = tileColor.Background(tcell.ColorDarkViolet)\n\tcase 4096:\n\t\ttileColor = tileColor.Background(tcell.ColorBlueViolet)\n\t// We don't have a lot of colors to work with so for now we'll make it boring\n\t// pass 4096.\n\tdefault:\n\t\ttileColor = tileColor.Background(tcell.ColorSlateGrey)\n\t}\n\treturn tileColor\n}", "func d1nodeCover(node *d1nodeT) d1rectT {\n\trect := node.branch[0].rect\n\tfor index := 1; index < node.count; index++ {\n\t\trect = d1combineRect(&rect, &(node.branch[index].rect))\n\t}\n\treturn rect\n}", "func d17nodeCover(node *d17nodeT) d17rectT {\n\trect := node.branch[0].rect\n\tfor index := 1; index < node.count; index++ {\n\t\trect = d17combineRect(&rect, &(node.branch[index].rect))\n\t}\n\treturn rect\n}", "func ClipTable(table Table, i, j, m, n int) Table {\n\tminR, minC := i, j\n\tmaxR, maxC := i+m, j+n\n\tif minR < 0 || minC < 0 || minR > maxR || minC > maxC || maxR >= table.RowCount() || maxC >= table.ColCount() {\n\t\tpanic(\"out of bound\")\n\t}\n\treturn &TableView{table, i, j, m, n}\n}", "func (c Chessboard) rookCastleKingsidePosition(color int) int {\n if color == 0 {\n return 63\n }\n\n return 7\n}", "func greedyColoringOf(g graph.Undirected, order graph.Nodes, partial map[int64]int) (k int, colors map[int64]int) {\n\tcolors = partial\n\tconstrained := false\n\tfor _, c := range colors {\n\t\tif c > k {\n\t\t\tk = c\n\t\t\tconstrained = true\n\t\t}\n\t}\n\n\t// Next nodes are chosen by the specified heuristic in order.\n\tfor order.Next() {\n\t\tuid := order.Node().ID()\n\t\tused := colorsOf(g.From(uid), colors)\n\t\tif c, ok := colors[uid]; ok {\n\t\t\tif used.Has(c) {\n\t\t\t\treturn -1, nil\n\t\t\t}\n\t\t\tcontinue\n\t\t}\n\t\t// Color the chosen vertex with the least possible\n\t\t// (lowest numbered) color.\n\t\tfor c := 0; c <= k+1; c++ {\n\t\t\tif !used.Has(c) {\n\t\t\t\tcolors[uid] = c\n\t\t\t\tif c > k {\n\t\t\t\t\tk = c\n\t\t\t\t}\n\t\t\t\tbreak\n\t\t\t}\n\t\t}\n\t}\n\n\tif !constrained {\n\t\treturn k + 1, colors\n\t}\n\tseen := make(set.Ints)\n\tfor _, c := range colors {\n\t\tseen.Add(c)\n\t}\n\treturn seen.Count(), colors\n}", "func colorizeMatches(line string, matches [][]int) string {\n\toutput := \"\"\n\tpointer := 0\n\tfor _, match := range matches {\n\t\tstart := match[0]\n\t\tend := match[1]\n\n\t\tif start >= pointer {\n\t\t\toutput += line[pointer:start]\n\t\t}\n\n\t\toutput += Bold(Red(line[start:end])).String()\n\t\tpointer = end\n\t}\n\n\tif pointer < (len(line) - 1) {\n\t\toutput += line[pointer:]\n\t}\n\treturn output\n}", "func d6nodeCover(node *d6nodeT) d6rectT {\n\trect := node.branch[0].rect\n\tfor index := 1; index < node.count; index++ {\n\t\trect = d6combineRect(&rect, &(node.branch[index].rect))\n\t}\n\treturn rect\n}", "func findEdge(numberOfColors int) int {\n //Indicating the thickness of the area around the diagonal by L, the number of nodes is found by solving the equation\n //n^3 -6Ln^2+(6L-1)n-numberOfColors = 0\n //Making the choice L=1/6 leads to a much simpler equation, and it's also a good choice for it as it leads to skipping around a third of the colors.\n delta := math.Cbrt((math.Sqrt(float64(27*27*numberOfColors*numberOfColors + 27*4*numberOfColors)) + float64(27*numberOfColors + 2))/2)\n return int(math.Ceil((delta + 1/delta + 1.)/3))\n}", "func (g grid) getRandomUnoccupiedPixelBlock() {\n\n}", "func shortestDistanceColor(colors []int, queries [][]int) []int {\n\tr := make([]int, 0)\n\t//data structure\n\t// brain storm:\n\t// 1) linked list\n\t// 2) hash\n\t// map[value int] indexes []int | ordered?\n\t// loop through colors to create map\n\t// check if the value exist\n\t// loop through indexes to find the lowest difference\n\t//\n\t// optionb) only 3 values not too much sense to hash it.\n\t//\n\t// O(1*ln(M) + N)\n\t// 3) list\n\t// brute force loop forward and backward until match\n\t// O(N)\n\t// Probably going with this\n\n\tfor _, v := range queries {\n\t\tshortest := -1\n\t\tfunc() {\n\t\t\tfor i := v[0]; i < len(colors); i++ {\n\n\t\t\t\tif v[1] == colors[i] {\n\t\t\t\t\tdistance := i - v[0]\n\t\t\t\t\tshortest = distance\n\t\t\t\t}\n\t\t\t}\n\t\t\tfor i := v[0]; i >= 0; i-- {\n\t\t\t\tdistance := v[0] - i\n\t\t\t\tif shortest != -1 {\n\t\t\t\t\tif distance < shortest {\n\t\t\t\t\t\tshortest = distance\n\t\t\t\t\t}\n\t\t\t\t} else {\n\t\t\t\t\tshortest = distance\n\t\t\t\t}\n\t\t\t}\n\t\t}()\n\t\tr = append(r, shortest)\n\t}\n\n\treturn r\n}", "func TableSetBgColorV(target TableBgTarget, color Vec4, columnN int) {\n\tcolorArg, _ := color.wrapped()\n\tC.iggTableSetBgColor(C.int(target), colorArg, C.int(columnN))\n}", "func print_color(chunks []Chunk) {\n\tc := 1\n\tfor i := range chunks {\n\t\tpayload := chunks[i].payload\n\t\ttag := chunks[i].tag\n\t\tvar x int\n\t\tif tag == \"\" {\n\t\t\tx = 7 // white\n\t\t} else {\n\t\t\tx = c\n\t\t\tc++\n\t\t\tif c > 6 {\n\t\t\t\tc = 1\n\t\t\t}\n\t\t}\n\t\tcolor := \"\\x1b[3\" + strconv.Itoa(x) + \"m\"\n\t\tfmt.Printf(\"%s%s\", color, payload)\n\t}\n\tfmt.Println()\n}", "func (table *Table) Draw(buf *Buffer) {\n\ttable.Block.Draw(buf)\n\n\ttable.drawLocation(buf)\n\ttable.drawUpdated(buf)\n\ttable.ColResizer()\n\n\tcolXPos := []int{}\n\tcur := 1 + table.PadLeft\n\tfor _, w := range table.ColWidths {\n\t\tcolXPos = append(colXPos, cur)\n\t\tcur += w\n\t\tcur += table.ColGap\n\t}\n\n\tfor i, h := range table.Header {\n\t\twidth := table.ColWidths[i]\n\t\tif width == 0 {\n\t\t\tcontinue\n\t\t}\n\n\t\tif width > (table.Inner.Dx()-colXPos[i])+1 {\n\t\t\tcontinue\n\t\t}\n\t\tbuf.SetString(\n\t\t\th,\n\t\t\tNewStyle(Theme.Default.Fg, ColorClear, ModifierBold),\n\t\t\timage.Pt(table.Inner.Min.X+colXPos[i]-1, table.Inner.Min.Y),\n\t\t)\n\t}\n\n\tif table.TopRow < 0 {\n\t\treturn\n\t}\n\n\tfor rowNum := table.TopRow; rowNum < table.TopRow+table.Inner.Dy()-1 && rowNum < len(table.Rows); rowNum++ {\n\t\trow := table.Rows[rowNum]\n\t\ty := (rowNum + 2) - table.TopRow\n\n\t\tstyle := NewStyle(Theme.Default.Fg)\n\t\tfor i, width := range table.ColWidths {\n\t\t\tif width == 0 {\n\t\t\t\tcontinue\n\t\t\t}\n\t\t\tif width > (table.Inner.Dx()-colXPos[i])+1 {\n\t\t\t\tcontinue\n\t\t\t}\n\t\t\tr := TrimString(row[i], width)\n\t\t\tif table.Styles[rowNum][i] != nil {\n\t\t\t\tbuf.SetString(\n\t\t\t\t\tr,\n\t\t\t\t\t*table.Styles[rowNum][i],\n\t\t\t\t\timage.Pt(table.Inner.Min.X+colXPos[i]-1, table.Inner.Min.Y+y-1),\n\t\t\t\t)\n\t\t\t} else {\n\t\t\t\tbuf.SetString(\n\t\t\t\t\tr,\n\t\t\t\t\tstyle,\n\t\t\t\t\timage.Pt(table.Inner.Min.X+colXPos[i]-1, table.Inner.Min.Y+y-1),\n\t\t\t\t)\n\t\t\t}\n\t\t}\n\t}\n}", "func (s *Service) setColorPairs() {\n\tswitch s.primaryColor {\n\tcase \"green\":\n\t\tgc.InitPair(1, gc.C_GREEN, gc.C_BLACK)\n\tcase \"cyan\", \"blue\":\n\t\tgc.InitPair(1, gc.C_CYAN, gc.C_BLACK)\n\tcase \"magenta\", \"pink\", \"purple\":\n\t\tgc.InitPair(1, gc.C_MAGENTA, gc.C_BLACK)\n\tcase \"white\":\n\t\tgc.InitPair(1, gc.C_WHITE, gc.C_BLACK)\n\tcase \"red\":\n\t\tgc.InitPair(1, gc.C_RED, gc.C_BLACK)\n\tcase \"yellow\", \"orange\":\n\t\tgc.InitPair(1, gc.C_YELLOW, gc.C_BLACK)\n\tdefault:\n\t\tgc.InitPair(1, gc.C_WHITE, gc.C_BLACK)\n\t}\n\n\tgc.InitPair(2, gc.C_BLACK, gc.C_BLACK)\n\tgc.InitPair(3, gc.C_BLACK, gc.C_GREEN)\n\tgc.InitPair(4, gc.C_BLACK, gc.C_CYAN)\n\tgc.InitPair(5, gc.C_WHITE, gc.C_BLUE)\n\tgc.InitPair(6, gc.C_BLACK, -1)\n}", "func d18nodeCover(node *d18nodeT) d18rectT {\n\trect := node.branch[0].rect\n\tfor index := 1; index < node.count; index++ {\n\t\trect = d18combineRect(&rect, &(node.branch[index].rect))\n\t}\n\treturn rect\n}", "func (t *table) appendBounds(cr *colReader) {\n\tbounds := []execute.Time{t.bounds.Start, t.bounds.Stop}\n\tfor j := range []int{startColIdx, stopColIdx} {\n\t\tb := arrow.NewIntBuilder(t.alloc)\n\t\tb.Reserve(cr.l)\n\t\tfor i := 0; i < cr.l; i++ {\n\t\t\tb.UnsafeAppend(int64(bounds[j]))\n\t\t}\n\t\tcr.cols[j] = b.NewArray()\n\t\tb.Release()\n\t}\n}", "func findAndIndex(abc *st.Art) (index1 int, index2 int) {\n\tsourse := abc.Flag.Color.ByIndex.Range\n\tlSourse := len(sourse)\n\n\tindex1 = sourse[0]\n\tindex2 = sourse[lSourse-1]\n\t// if wrong range, fix it\n\tif index1 > index2 {\n\t\tindex1, index2 = index2, index1\n\t}\n\treturn index1, index2\n}", "func d4nodeCover(node *d4nodeT) d4rectT {\n\trect := node.branch[0].rect\n\tfor index := 1; index < node.count; index++ {\n\t\trect = d4combineRect(&rect, &(node.branch[index].rect))\n\t}\n\treturn rect\n}", "func getTileFromColor(color *Color, tiles *[]TileImg, tolerance float64) *gmagick.MagickWand {\n\tvar matched = make([]int, 0)\n\t// compare color pixel with tolerance\n\tfor idx, tile := range *tiles {\n\t\tvar _matched = matchedPixels(color, tile.Color, tolerance)\n\t\tif _matched.Matched {\n\t\t\tmatched = append(matched, idx)\n\t\t}\n\t}\n\tif len(matched) > 0 {\n\t\tidx := getRandomItemIndex(len(matched))\n\t\tvar m = matched[idx]\n\t\treturn (*tiles)[m].Image\n\t}\n\treturn nil\n\n}", "func isGraphColouredProperly(graph [][]bool, V int, colour []int, v int, c int) bool {\n\tfor i := 0; i < V; i++ {\n\t\tif graph[v][i] && c == colour[i] {\n\t\t\treturn false\n\t\t}\n\t}\n\treturn true\n}", "func tableSetUp(m, n int) *[][]int {\n\tresult := make([][]int, m)\n\tfor i := range result {\n\t\tresult[i] = make([]int, n)\n\t}\n\tfor c := range result[0] {\n\t\tresult[0][c] = c\n\t}\n\tfor r := 0; r < len(result); r++ {\n\t\tresult[r][0] = r\n\t}\n\n\treturn &result\n}", "func (c *Colorscheme) tcellColor(name string) tcell.Color {\n\tv, ok := c.colors[name].(string)\n\tif !ok {\n\t\treturn tcell.ColorDefault\n\t}\n\n\tif color, found := TcellColorschemeColorsMap[v]; found {\n\t\treturn color\n\t}\n\n\tcolor := tcell.GetColor(v)\n\tif color != tcell.ColorDefault {\n\t\treturn color\n\t}\n\n\t// find closest X11 color to RGB\n\t// if code, ok := HexToAnsi(v); ok {\n\t// \treturn tcell.PaletteColor(int(code) & 0xff)\n\t// }\n\treturn color\n}", "func ScissorIndexed(index uint32, left int32, bottom int32, width int32, height int32) {\n C.glowScissorIndexed(gpScissorIndexed, (C.GLuint)(index), (C.GLint)(left), (C.GLint)(bottom), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func (l LCDControl) TilePatternTableAddress() mmu.Range {\n\tif binary.Bit(4, byte(l)) == 0 {\n\t\treturn mmu.Range{\n\t\t\tStart: 0x8800, End: 0x97FF,\n\t\t}\n\t}\n\treturn mmu.Range{\n\t\tStart: 0x8000, End: 0x8FFF,\n\t}\n}", "func (b box) color() color.NRGBA {\n\treturn b.col\n}", "func drawCell(rectImg *image.RGBA, x, y, size int) {\n\trectLine := image.NewRGBA(image.Rect(x, y, x+size, y+size))\n\t//COLOR\n\tgreyRect := color.RGBA{169, 169, 169, 255}\n\tblackRect := color.RGBA{0, 0, 0, 230}\n\n\tif flagColor{\n\t\tdraw.Draw(rectImg, rectLine.Bounds(), &image.Uniform{blackRect}, image.ZP, draw.Src)\n\t}else {\n\t\tdraw.Draw(rectImg, rectLine.Bounds(), &image.Uniform{greyRect}, image.ZP, draw.Src)\n\t}\n}", "func setcolor(what string, level int, str string) string {\n\tRet := \"\"\n\tswitch colors[level] {\n\tcase \"Black\":\n\t\tRet = color.Black(str)\n\tcase \"Red\":\n\t\tRet = color.Red(str)\n\tcase \"Green\":\n\t\tRet = color.Green(str)\n\tcase \"Yellow\":\n\t\tRet = color.Yellow(str)\n\tcase \"Blue\":\n\t\tRet = color.Blue(str)\n\tcase \"Purple\":\n\t\tRet = color.Purple(str)\n\tcase \"Cyan\":\n\t\tRet = color.Cyan(str)\n\tcase \"LightGray\":\n\t\tRet = color.LightGray(str)\n\tcase \"DarkGray\":\n\t\tRet = color.DarkGray(str)\n\tcase \"LightRed\":\n\t\tRet = color.LightRed(str)\n\tcase \"LightGreen\":\n\t\tRet = color.LightGreen(str)\n\tcase \"LightYellow\":\n\t\tRet = color.LightYellow(str)\n\tcase \"LightBlue\":\n\t\tRet = color.LightBlue(str)\n\tcase \"LightPurple\":\n\t\tRet = color.LightPurple(str)\n\tcase \"LightCyan\":\n\t\tRet = color.LightCyan(str)\n\tcase \"White\":\n\t\tRet = color.White(str)\n\t// bold\n\tcase \"BBlack\":\n\t\tRet = color.BBlack(str)\n\tcase \"BRed\":\n\t\tRet = color.BRed(str)\n\tcase \"BGreen\":\n\t\tRet = color.BGreen(str)\n\tcase \"BYellow\":\n\t\tRet = color.BYellow(str)\n\tcase \"BBlue\":\n\t\tRet = color.BBlue(str)\n\tcase \"BPurple\":\n\t\tRet = color.BPurple(str)\n\tcase \"BCyan\":\n\t\tRet = color.BCyan(str)\n\tcase \"BLightGray\":\n\t\tRet = color.BLightGray(str)\n\tcase \"BDarkGray\":\n\t\tRet = color.BDarkGray(str)\n\tcase \"BLightRed\":\n\t\tRet = color.BLightRed(str)\n\tcase \"BLightGreen\":\n\t\tRet = color.BLightGreen(str)\n\tcase \"BLightYellow\":\n\t\tRet = color.BLightYellow(str)\n\tcase \"BLightBlue\":\n\t\tRet = color.BLightBlue(str)\n\tcase \"BLightPurple\":\n\t\tRet = color.BLightPurple(str)\n\tcase \"BLightCyan\":\n\t\tRet = color.BLightCyan(str)\n\tcase \"BWhite\":\n\t\tRet = color.BWhite(str)\n\t// background\n\tcase \"GBlack\":\n\t\tRet = color.GBlack(str)\n\tcase \"GRed\":\n\t\tRet = color.GRed(str)\n\tcase \"GGreen\":\n\t\tRet = color.GGreen(str)\n\tcase \"GYellow\":\n\t\tRet = color.GYellow(str)\n\tcase \"GBlue\":\n\t\tRet = color.GBlue(str)\n\tcase \"GPurple\":\n\t\tRet = color.GPurple(str)\n\tcase \"GCyan\":\n\t\tRet = color.GCyan(str)\n\tcase \"GLightGray\":\n\t\tRet = color.GLightGray(str)\n\tcase \"GDarkGray\":\n\t\tRet = color.GDarkGray(str)\n\tcase \"GLightRed\":\n\t\tRet = color.GLightRed(str)\n\tcase \"GLightGreen\":\n\t\tRet = color.GLightGreen(str)\n\tcase \"GLightYellow\":\n\t\tRet = color.GLightYellow(str)\n\tcase \"GLightBlue\":\n\t\tRet = color.GLightBlue(str)\n\tcase \"GLightPurple\":\n\t\tRet = color.GLightPurple(str)\n\tcase \"GLightCyan\":\n\t\tRet = color.GLightCyan(str)\n\tcase \"GWhite\":\n\t\tRet = color.GWhite(str)\n\t// special\n\tcase \"Bold\":\n\t\tRet = color.Bold(str)\n\tcase \"Dim\":\n\t\tRet = color.Dim(str)\n\tcase \"Underline\":\n\t\tRet = color.Underline(str)\n\tcase \"Invert\":\n\t\tRet = color.Invert(str)\n\tcase \"Hide\":\n\t\tRet = color.Hide(str)\n\tcase \"Blink\":\n\t\tRet = color.Blink(str) // blinking works only on mac\n\tdefault:\n\t\tRet = str\n\t}\n\treturn Ret\n}", "func Hsl(h, s, l float64) Color {\r\n if s == 0 {\r\n return Color{l, l, l}\r\n }\r\n\r\n var r, g, b float64\r\n var t1 float64\r\n var t2 float64\r\n var tr float64\r\n var tg float64\r\n var tb float64\r\n\r\n if l < 0.5 {\r\n t1 = l * (1.0 + s)\r\n } else {\r\n t1 = l + s - l*s\r\n }\r\n\r\n t2 = 2*l - t1\r\n h = h / 360\r\n tr = h + 1.0/3.0\r\n tg = h\r\n tb = h - 1.0/3.0\r\n\r\n if tr < 0 {\r\n tr += 1\r\n }\r\n if tr > 1 {\r\n tr -= 1\r\n }\r\n if tg < 0 {\r\n tg += 1\r\n }\r\n if tg > 1 {\r\n tg -= 1\r\n }\r\n if tb < 0 {\r\n tb += 1\r\n }\r\n if tb > 1 {\r\n tb -= 1\r\n }\r\n\r\n // Red\r\n if 6*tr < 1 {\r\n r = t2 + (t1-t2)*6*tr\r\n } else if 2*tr < 1 {\r\n r = t1\r\n } else if 3*tr < 2 {\r\n r = t2 + (t1-t2)*(2.0/3.0-tr)*6\r\n } else {\r\n r = t2\r\n }\r\n\r\n // Green\r\n if 6*tg < 1 {\r\n g = t2 + (t1-t2)*6*tg\r\n } else if 2*tg < 1 {\r\n g = t1\r\n } else if 3*tg < 2 {\r\n g = t2 + (t1-t2)*(2.0/3.0-tg)*6\r\n } else {\r\n g = t2\r\n }\r\n\r\n // Blue\r\n if 6*tb < 1 {\r\n b = t2 + (t1-t2)*6*tb\r\n } else if 2*tb < 1 {\r\n b = t1\r\n } else if 3*tb < 2 {\r\n b = t2 + (t1-t2)*(2.0/3.0-tb)*6\r\n } else {\r\n b = t2\r\n }\r\n\r\n return Color{r, g, b}\r\n}", "func d20nodeCover(node *d20nodeT) d20rectT {\n\trect := node.branch[0].rect\n\tfor index := 1; index < node.count; index++ {\n\t\trect = d20combineRect(&rect, &(node.branch[index].rect))\n\t}\n\treturn rect\n}", "func (g *GMRES) hcol(j int) []float64 {\n\tldh := g.m + 1\n\treturn g.ht[j*ldh : (j+1)*ldh]\n}", "func d12nodeCover(node *d12nodeT) d12rectT {\n\trect := node.branch[0].rect\n\tfor index := 1; index < node.count; index++ {\n\t\trect = d12combineRect(&rect, &(node.branch[index].rect))\n\t}\n\treturn rect\n}", "func cellColor(c cell.Color) tcell.Color {\n\tif c == cell.ColorDefault {\n\t\treturn tcell.ColorDefault\n\t}\n\t// Subtract one, because cell.ColorBlack has value one instead of zero.\n\t// Zero is used for cell.ColorDefault instead.\n\treturn tcell.Color(c-1) + tcell.ColorValid\n}", "func (b *BoardTest) TestQuickColors(t *C) {\n\tl := new(RGBLED, 9, 10, 11)\n\tvar cs = map[string][3]byte{\n\t\t\"red\": [3]byte{0xFF, 00, 00},\n\t\t\"green\": [3]byte{00, 0xFF, 00},\n\t\t\"blue\": [3]byte{00, 00, 0xFF},\n\t\t\"black\": [3]byte{00, 00, 00},\n\t\t\"white\": [3]byte{0xFF, 0xFF, 0xFF},\n\t}\n\tfor c, v := range cs {\n\t\tl.QuickColor(c)\n\t\tt.Check(l.Red, Equals, v[0])\n\t\tt.Check(l.Green, Equals, v[1])\n\t\tt.Check(l.Blue, Equals, v[2])\n\t}\n}", "func d13nodeCover(node *d13nodeT) d13rectT {\n\trect := node.branch[0].rect\n\tfor index := 1; index < node.count; index++ {\n\t\trect = d13combineRect(&rect, &(node.branch[index].rect))\n\t}\n\treturn rect\n}", "func d5nodeCover(node *d5nodeT) d5rectT {\n\trect := node.branch[0].rect\n\tfor index := 1; index < node.count; index++ {\n\t\trect = d5combineRect(&rect, &(node.branch[index].rect))\n\t}\n\treturn rect\n}", "func colorsOf(nodes graph.Nodes, coloring map[int64]int) set.Ints {\n\tc := make(set.Ints, nodes.Len())\n\tfor nodes.Next() {\n\t\tused, ok := coloring[nodes.Node().ID()]\n\t\tif ok {\n\t\t\tc.Add(used)\n\t\t}\n\t}\n\treturn c\n}", "func (x *ImgSpanner) SpanFgColor(yi, xi0, xi1 int, ma uint32) {\n\ti0 := (yi)*x.stride + (xi0)*4\n\ti1 := i0 + (xi1-xi0)*4\n\t// uses the Porter-Duff composition operator.\n\tcr, cg, cb, ca := x.fgColor.RGBA()\n\tama := ca * ma\n\tif ama == 0xFFFF*0xFFFF { // undercolor is ignored\n\t\trmb := uint8(cr * ma / mp)\n\t\tgmb := uint8(cg * ma / mp)\n\t\tbmb := uint8(cb * ma / mp)\n\t\tamb := uint8(ama / mp)\n\t\tfor i := i0; i < i1; i += 4 {\n\t\t\tx.pix[i+0] = rmb\n\t\t\tx.pix[i+1] = gmb\n\t\t\tx.pix[i+2] = bmb\n\t\t\tx.pix[i+3] = amb\n\t\t}\n\t\treturn\n\t}\n\trma := cr * ma\n\tgma := cg * ma\n\tbma := cb * ma\n\ta := (m - (ama / m)) * pa\n\tfor i := i0; i < i1; i += 4 {\n\t\tx.pix[i+0] = uint8((uint32(x.pix[i+0])*a + rma) / mp)\n\t\tx.pix[i+1] = uint8((uint32(x.pix[i+1])*a + gma) / mp)\n\t\tx.pix[i+2] = uint8((uint32(x.pix[i+2])*a + bma) / mp)\n\t\tx.pix[i+3] = uint8((uint32(x.pix[i+3])*a + ama) / mp)\n\t}\n}" ]
[ "0.7169887", "0.68756604", "0.6508021", "0.61563814", "0.6053618", "0.5870142", "0.572057", "0.54090625", "0.5268068", "0.5217324", "0.5199247", "0.51871884", "0.5184359", "0.51665777", "0.5125286", "0.5103398", "0.509819", "0.5085142", "0.5067481", "0.50626045", "0.5054786", "0.5054786", "0.5042424", "0.50336534", "0.5008503", "0.4975407", "0.49391797", "0.49195895", "0.490381", "0.48778984", "0.4873281", "0.48655534", "0.48577544", "0.48415816", "0.4830478", "0.4826598", "0.4822823", "0.48151708", "0.4805355", "0.48027042", "0.47905463", "0.4786877", "0.47745356", "0.47678155", "0.4740655", "0.47398892", "0.4737554", "0.47304115", "0.47238773", "0.47177628", "0.47149423", "0.4707004", "0.47064972", "0.47012928", "0.46940535", "0.467435", "0.46731883", "0.46692616", "0.46688527", "0.46647125", "0.46632978", "0.46622315", "0.46577463", "0.4656629", "0.46521655", "0.4635064", "0.4599794", "0.4598576", "0.45982486", "0.4594544", "0.45940018", "0.45824838", "0.4582404", "0.45818678", "0.45813406", "0.4580641", "0.45738462", "0.45650902", "0.456462", "0.45615774", "0.4561139", "0.45605904", "0.4553223", "0.4551032", "0.4547096", "0.45452031", "0.4544669", "0.45431784", "0.45396078", "0.4536519", "0.45251036", "0.4523833", "0.45230514", "0.45203233", "0.45171833", "0.45146677", "0.4506833", "0.45035705", "0.4502162", "0.4500437" ]
0.6995501
1
define a color lookup table
func ColorTable(target uint32, internalformat uint32, width int32, format uint32, xtype uint32, table unsafe.Pointer) { C.glowColorTable(gpColorTable, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), table) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func ColorTable(target uint32, internalformat uint32, width int32, format uint32, xtype uint32, table unsafe.Pointer) {\n C.glowColorTable(gpColorTable, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), table)\n}", "func makeColorLookup(vals []int, length int) []int {\n\tres := make([]int, length)\n\n\tvi := 0\n\tfor i := 0; i < len(res); i++ {\n\t\tif vi+1 < len(vals) {\n\t\t\tif i <= (vals[vi]+vals[vi+1])/2 {\n\t\t\t\tres[i] = vi\n\t\t\t} else {\n\t\t\t\tvi++\n\t\t\t\tres[i] = vi\n\t\t\t}\n\t\t} else if vi < len(vals) {\n\t\t\t// only last vi is valid\n\t\t\tres[i] = vi\n\t\t}\n\t}\n\treturn res\n}", "func GetColorTable(target uint32, format uint32, xtype uint32, table unsafe.Pointer) {\n C.glowGetColorTable(gpGetColorTable, (C.GLenum)(target), (C.GLenum)(format), (C.GLenum)(xtype), table)\n}", "func colorStr(value uint16) (key string) {\n\tfor k, v := range colorLookUp {\n\t\tif v == value {\n\t\t\tkey = k\n\t\t\treturn\n\t\t}\n\t}\n\treturn\n}", "func GetColorTable(target uint32, format uint32, xtype uint32, table unsafe.Pointer) {\n\tC.glowGetColorTable(gpGetColorTable, (C.GLenum)(target), (C.GLenum)(format), (C.GLenum)(xtype), table)\n}", "func (r *RSCodec) InitLookupTables() {\n\t// Precompute the logarithm and anti-log tables for faster computation, using the provided primitive polynomial.\n\t// The idea: b**(log_b(x), log_b(y)) == x * y, where b is the base or generator of the logarithm =>\n\t// we can use any b to precompute logarithm and anti-log tables to use for multiplying two numbers x and y.\n\tx := 1\n\tfor i := 0; i < 255; i++ {\n\t\texponents[i] = x\n\t\tlogs[x] = i\n\t\tx = russianPeasantMult(x, 2, r.Primitive, 256, true)\n\t}\n\n\tfor i := 255; i < 512; i++ {\n\t\texponents[i] = exponents[i-255]\n\t}\n}", "func ColorSubTable(target uint32, start int32, count int32, format uint32, xtype uint32, data unsafe.Pointer) {\n C.glowColorSubTable(gpColorSubTable, (C.GLenum)(target), (C.GLsizei)(start), (C.GLsizei)(count), (C.GLenum)(format), (C.GLenum)(xtype), data)\n}", "func (s *Service) setColorPairs() {\n\tswitch s.primaryColor {\n\tcase \"green\":\n\t\tgc.InitPair(1, gc.C_GREEN, gc.C_BLACK)\n\tcase \"cyan\", \"blue\":\n\t\tgc.InitPair(1, gc.C_CYAN, gc.C_BLACK)\n\tcase \"magenta\", \"pink\", \"purple\":\n\t\tgc.InitPair(1, gc.C_MAGENTA, gc.C_BLACK)\n\tcase \"white\":\n\t\tgc.InitPair(1, gc.C_WHITE, gc.C_BLACK)\n\tcase \"red\":\n\t\tgc.InitPair(1, gc.C_RED, gc.C_BLACK)\n\tcase \"yellow\", \"orange\":\n\t\tgc.InitPair(1, gc.C_YELLOW, gc.C_BLACK)\n\tdefault:\n\t\tgc.InitPair(1, gc.C_WHITE, gc.C_BLACK)\n\t}\n\n\tgc.InitPair(2, gc.C_BLACK, gc.C_BLACK)\n\tgc.InitPair(3, gc.C_BLACK, gc.C_GREEN)\n\tgc.InitPair(4, gc.C_BLACK, gc.C_CYAN)\n\tgc.InitPair(5, gc.C_WHITE, gc.C_BLUE)\n\tgc.InitPair(6, gc.C_BLACK, -1)\n}", "func ColorSubTable(target uint32, start int32, count int32, format uint32, xtype uint32, data unsafe.Pointer) {\n\tC.glowColorSubTable(gpColorSubTable, (C.GLenum)(target), (C.GLsizei)(start), (C.GLsizei)(count), (C.GLenum)(format), (C.GLenum)(xtype), data)\n}", "func constructColorMap(limit float64, colorized bool) ColorMap {\n\tif colorized {\n\t\treturn func(x float64) (uint8, uint8, uint8) {\n\t\t\tr, g, b, _ := colorful.Hsl(x/limit-180, saturation, luminance*(1-x/limit)).RGBA()\n\t\t\treturn uint8(r), uint8(g), uint8(b)\n\t\t}\n\t} else {\n\t\treturn func(x float64) (uint8, uint8, uint8) {\n\t\t\tc := uint8(255 * x / limit)\n\t\t\treturn c, c, c\n\t\t}\n\t}\n}", "func Color(foreColor, backColor, mode gb.UINT8) {}", "func New(color string) *ml.Color {\n\tcolor = Normalize(color)\n\n\t//check if it's indexed color\n\tfor i, c := range indexed {\n\t\tif color == c {\n\t\t\treturn &ml.Color{Indexed: &i}\n\t\t}\n\t}\n\n\treturn &ml.Color{RGB: color}\n}", "func CopyColorTable(target uint32, internalformat uint32, x int32, y int32, width int32) {\n C.glowCopyColorTable(gpCopyColorTable, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func getColor(w http.ResponseWriter, c string) {\n\t// querys the DB to select color props based on the given hex\n\tq := fmt.Sprint(`SELECT color, r, g, b, a, hex, creatorId, creatorHash FROM colors WHERE hex =\"`, c, `\";`)\n\t// queries the DB\n\trows, err := db.Query(q)\n\t// checks the error\n\thtmlCheck(err, w, fmt.Sprint(\"There was an error \", err))\n\t// creates variables to hold color information\n\tvar name, r, g, b, a, hex, cID, cH string\n\t// creates a color variable\n\tvar co Color\n\t// for each row\n\tfor rows.Next() {\n\t\t// fill in the variables in given order\n\t\terr = rows.Scan(&name, &r, &g, &b, &a, &hex, &cID, &cH)\n\t\t// checks the error\n\t\thtmlCheck(err, w, fmt.Sprint(\"There was an error \", err))\n\t\t// sets co to be the color with the given variables\n\t\tco = Color{\n\t\t\tname,\n\t\t\tr,\n\t\t\tg,\n\t\t\tb,\n\t\t\ta,\n\t\t\thex,\n\t\t\t0.,\n\t\t\tcID,\n\t\t\tcH,\n\t\t}\n\t}\n\t// if no color, color needs to be created\n\tif co.Color == \"\" {\n\t\t// writes the status to the response\n\t\tw.WriteHeader(http.StatusPartialContent)\n\t\tfmt.Fprintf(w, \"Color has to be created\")\n\t\treturn\n\t}\n\t// encodes the color as json\n\terr = json.NewEncoder(w).Encode(co)\n\t// checks the error\n\thtmlCheck(err, w, fmt.Sprint(\"There was an error \", err))\n\n}", "func hashColor(s string) string {\n\th := fnv.New32a()\n\th.Write([]byte(s))\n\ti := h.Sum32() % 6\n\treturn fmt.Sprintf(\"\\033[1;3%dm%s\\033[0m\", i+1, s)\n}", "func setcolor(what string, level int, str string) string {\n\tRet := \"\"\n\tswitch colors[level] {\n\tcase \"Black\":\n\t\tRet = color.Black(str)\n\tcase \"Red\":\n\t\tRet = color.Red(str)\n\tcase \"Green\":\n\t\tRet = color.Green(str)\n\tcase \"Yellow\":\n\t\tRet = color.Yellow(str)\n\tcase \"Blue\":\n\t\tRet = color.Blue(str)\n\tcase \"Purple\":\n\t\tRet = color.Purple(str)\n\tcase \"Cyan\":\n\t\tRet = color.Cyan(str)\n\tcase \"LightGray\":\n\t\tRet = color.LightGray(str)\n\tcase \"DarkGray\":\n\t\tRet = color.DarkGray(str)\n\tcase \"LightRed\":\n\t\tRet = color.LightRed(str)\n\tcase \"LightGreen\":\n\t\tRet = color.LightGreen(str)\n\tcase \"LightYellow\":\n\t\tRet = color.LightYellow(str)\n\tcase \"LightBlue\":\n\t\tRet = color.LightBlue(str)\n\tcase \"LightPurple\":\n\t\tRet = color.LightPurple(str)\n\tcase \"LightCyan\":\n\t\tRet = color.LightCyan(str)\n\tcase \"White\":\n\t\tRet = color.White(str)\n\t// bold\n\tcase \"BBlack\":\n\t\tRet = color.BBlack(str)\n\tcase \"BRed\":\n\t\tRet = color.BRed(str)\n\tcase \"BGreen\":\n\t\tRet = color.BGreen(str)\n\tcase \"BYellow\":\n\t\tRet = color.BYellow(str)\n\tcase \"BBlue\":\n\t\tRet = color.BBlue(str)\n\tcase \"BPurple\":\n\t\tRet = color.BPurple(str)\n\tcase \"BCyan\":\n\t\tRet = color.BCyan(str)\n\tcase \"BLightGray\":\n\t\tRet = color.BLightGray(str)\n\tcase \"BDarkGray\":\n\t\tRet = color.BDarkGray(str)\n\tcase \"BLightRed\":\n\t\tRet = color.BLightRed(str)\n\tcase \"BLightGreen\":\n\t\tRet = color.BLightGreen(str)\n\tcase \"BLightYellow\":\n\t\tRet = color.BLightYellow(str)\n\tcase \"BLightBlue\":\n\t\tRet = color.BLightBlue(str)\n\tcase \"BLightPurple\":\n\t\tRet = color.BLightPurple(str)\n\tcase \"BLightCyan\":\n\t\tRet = color.BLightCyan(str)\n\tcase \"BWhite\":\n\t\tRet = color.BWhite(str)\n\t// background\n\tcase \"GBlack\":\n\t\tRet = color.GBlack(str)\n\tcase \"GRed\":\n\t\tRet = color.GRed(str)\n\tcase \"GGreen\":\n\t\tRet = color.GGreen(str)\n\tcase \"GYellow\":\n\t\tRet = color.GYellow(str)\n\tcase \"GBlue\":\n\t\tRet = color.GBlue(str)\n\tcase \"GPurple\":\n\t\tRet = color.GPurple(str)\n\tcase \"GCyan\":\n\t\tRet = color.GCyan(str)\n\tcase \"GLightGray\":\n\t\tRet = color.GLightGray(str)\n\tcase \"GDarkGray\":\n\t\tRet = color.GDarkGray(str)\n\tcase \"GLightRed\":\n\t\tRet = color.GLightRed(str)\n\tcase \"GLightGreen\":\n\t\tRet = color.GLightGreen(str)\n\tcase \"GLightYellow\":\n\t\tRet = color.GLightYellow(str)\n\tcase \"GLightBlue\":\n\t\tRet = color.GLightBlue(str)\n\tcase \"GLightPurple\":\n\t\tRet = color.GLightPurple(str)\n\tcase \"GLightCyan\":\n\t\tRet = color.GLightCyan(str)\n\tcase \"GWhite\":\n\t\tRet = color.GWhite(str)\n\t// special\n\tcase \"Bold\":\n\t\tRet = color.Bold(str)\n\tcase \"Dim\":\n\t\tRet = color.Dim(str)\n\tcase \"Underline\":\n\t\tRet = color.Underline(str)\n\tcase \"Invert\":\n\t\tRet = color.Invert(str)\n\tcase \"Hide\":\n\t\tRet = color.Hide(str)\n\tcase \"Blink\":\n\t\tRet = color.Blink(str) // blinking works only on mac\n\tdefault:\n\t\tRet = str\n\t}\n\treturn Ret\n}", "func colorPair(c color.Color) (hi, lo color.Color) {\n\tr, g, b, a := c.RGBA()\n\tr >>= 8\n\tg >>= 8\n\tb >>= 8\n\ta >>= 8\n\tmaxd := uint32(40)\n\tif r < maxd {\n\t\tmaxd = r\n\t}\n\tif g < maxd {\n\t\tmaxd = g\n\t}\n\tif b < maxd {\n\t\tmaxd = b\n\t}\n\tif r > 128 && (255-r) < maxd {\n\t\tmaxd = (255 - r)\n\t}\n\tif g > 128 && (255-g) < maxd {\n\t\tmaxd = (255 - g)\n\t}\n\tif b > 128 && (255-b) < maxd {\n\t\tmaxd = (255 - b)\n\t}\n\thi = color.RGBA{\n\t\tR: uint8(r + maxd),\n\t\tG: uint8(g + maxd),\n\t\tB: uint8(b + maxd),\n\t\tA: uint8(a),\n\t}\n\tlo = color.RGBA{\n\t\tR: uint8(r - maxd),\n\t\tG: uint8(g - maxd),\n\t\tB: uint8(b - maxd),\n\t\tA: uint8(a),\n\t}\n\treturn hi, lo\n}", "func (e *Square10) Reference(modifiers map[int]api.Color, refPlayer int) map[int]api.Color {\n\treferenceBoard := make(map[int]api.Color, len(modifiers))\n\tfor tile, color := range modifiers {\n\t\ttargetID := refPlayer*99 - tile*(refPlayer*2-1)\n\t\treferenceBoard[targetID] = color\n\t}\n\treturn referenceBoard\n}", "func CopyColorSubTable(target uint32, start int32, x int32, y int32, width int32) {\n C.glowCopyColorSubTable(gpCopyColorSubTable, (C.GLenum)(target), (C.GLsizei)(start), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func (e Color2) String() string {\n name, _ := color2Map[int32(e)]\n return name\n}", "func colorsOf(nodes graph.Nodes, coloring map[int64]int) set.Ints {\n\tc := make(set.Ints, nodes.Len())\n\tfor nodes.Next() {\n\t\tused, ok := coloring[nodes.Node().ID()]\n\t\tif ok {\n\t\t\tc.Add(used)\n\t\t}\n\t}\n\treturn c\n}", "func getOneColor(h string) Color {\n\t// creates a query to select all relevent data from color table by hex\n\tq := fmt.Sprint(`SELECT color, r, g, b, a, hex, creatorId, creatorHash FROM colors WHERE hex =\"`, h, `\";`)\n\t// Runs the query checking for errors\n\trows, err := db.Query(q)\n\t// check the errors\n\tcheck(err)\n\t// Creates a variable to store all color data\n\tvar name, r, g, b, a, hex, cID, cH string\n\tvar co Color\n\t// loops through each row retuened from the query\n\tfor rows.Next() {\n\t\t// sets each data piece to be what is in the row\n\t\terr = rows.Scan(&name, &r, &g, &b, &a, &hex, &cID, &cH)\n\t\t// saves data to color struct\n\t\tco = Color{\n\t\t\tname,\n\t\t\tr,\n\t\t\tg,\n\t\t\tb,\n\t\t\ta,\n\t\t\thex,\n\t\t\t0.,\n\t\t\tcID,\n\t\t\tcH,\n\t\t}\n\t}\n\t// returns the color\n\treturn co\n}", "func (c *Colorscheme) tcellColor(name string) tcell.Color {\n\tv, ok := c.colors[name].(string)\n\tif !ok {\n\t\treturn tcell.ColorDefault\n\t}\n\n\tif color, found := TcellColorschemeColorsMap[v]; found {\n\t\treturn color\n\t}\n\n\tcolor := tcell.GetColor(v)\n\tif color != tcell.ColorDefault {\n\t\treturn color\n\t}\n\n\t// find closest X11 color to RGB\n\t// if code, ok := HexToAnsi(v); ok {\n\t// \treturn tcell.PaletteColor(int(code) & 0xff)\n\t// }\n\treturn color\n}", "func CopyColorTable(target uint32, internalformat uint32, x int32, y int32, width int32) {\n\tC.glowCopyColorTable(gpCopyColorTable, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func main() {\n\n\tvar colors = []string{\"Red\", \"Blue\", \"Yellow\", \"Pink\", \"Purple\", \"Brown\", \"Green\"}\n\n\tvar buckets = 7\n\n\tvar hashMap = make([]string, buckets)\n\n\tfor _, color := range colors {\n\t\thash := hashFunction(color, buckets)\n\t\thashMap[hash] = color\n\t}\n\tfmt.Println(hashMap[3])\n\n\tfmt.Println(hashMap)\n}", "func solarizedColors() *Palette {\n\tsize := 9\n\tp := Palette{\n\t\tcolors: make([]Style, size),\n\t\tsize: size,\n\t}\n\tnums := [9]int{1, 2, 3, 4, 5, 6, 7, 9, 13}\n\tfor x := 0; x < 9; x++ {\n\t\tp.colors[x] = Color256(nums[x])\n\t}\n\treturn &p\n}", "func printMap(c map[string]string) {\n\tfor color, hex := range c {\n\t\tfmt.Println(\"Hex code for\", color, \"is\", hex)\n\t}\n}", "func ColorLib(name string) string {\n\tswitch name {\n\tcase \"black\":\n\t\treturn \"\\033[30m\"\n\tcase \"red\":\n\t\treturn \"\\033[31m\"\n\tcase \"green\":\n\t\treturn \"\\033[32m\"\n\tcase \"yellow\":\n\t\treturn \"\\033[33m\"\n\tcase \"blue\":\n\t\treturn \"\\033[34m\"\n\tcase \"purple\":\n\t\treturn \"\\033[35m\"\n\tcase \"cyan\":\n\t\treturn \"\\033[36m\"\n\tcase \"white\":\n\t\treturn \"\\033[37m\"\n\tcase \"orange\":\n\t\treturn \"\\033[38;2;255;186;0m\"\n\tdefault:\n\t\treturn \"\\033[0m\"\n\t}\n}", "func lookupShadeInPlatter(platter byte, colorNum uint8) Shade {\n\treturn Shade((platter >> (2 * colorNum)) & 0x03)\n}", "func COLORSn(n uint) Component {\n\t//aiComponent_COLORSn(n) (1u << (n+20u))\n\treturn Component(1 << (n + 20))\n}", "func HiRedString(format string, a ...interface{}) string { return colorString(format, FgHiRed, a...) }", "func Colorize(x string) string {\n\tattr := 0\n\tfg := 39\n\tbg := 49\n\n\tfor _, key := range x {\n\t\tc, ok := codeMap[int(key)]\n\t\tswitch {\n\t\tcase !ok:\n\t\t\tlog.Printf(\"Wrong color syntax: %c\", key)\n\t\tcase 0 <= c && c <= 8:\n\t\t\tattr = c\n\t\tcase 30 <= c && c <= 37:\n\t\t\tfg = c\n\t\tcase 40 <= c && c <= 47:\n\t\t\tbg = c\n\t\t}\n\t}\n\treturn fmt.Sprintf(\"\\033[%d;%d;%dm\", attr, fg, bg)\n}", "func Hsl(h, s, l float64) Color {\r\n if s == 0 {\r\n return Color{l, l, l}\r\n }\r\n\r\n var r, g, b float64\r\n var t1 float64\r\n var t2 float64\r\n var tr float64\r\n var tg float64\r\n var tb float64\r\n\r\n if l < 0.5 {\r\n t1 = l * (1.0 + s)\r\n } else {\r\n t1 = l + s - l*s\r\n }\r\n\r\n t2 = 2*l - t1\r\n h = h / 360\r\n tr = h + 1.0/3.0\r\n tg = h\r\n tb = h - 1.0/3.0\r\n\r\n if tr < 0 {\r\n tr += 1\r\n }\r\n if tr > 1 {\r\n tr -= 1\r\n }\r\n if tg < 0 {\r\n tg += 1\r\n }\r\n if tg > 1 {\r\n tg -= 1\r\n }\r\n if tb < 0 {\r\n tb += 1\r\n }\r\n if tb > 1 {\r\n tb -= 1\r\n }\r\n\r\n // Red\r\n if 6*tr < 1 {\r\n r = t2 + (t1-t2)*6*tr\r\n } else if 2*tr < 1 {\r\n r = t1\r\n } else if 3*tr < 2 {\r\n r = t2 + (t1-t2)*(2.0/3.0-tr)*6\r\n } else {\r\n r = t2\r\n }\r\n\r\n // Green\r\n if 6*tg < 1 {\r\n g = t2 + (t1-t2)*6*tg\r\n } else if 2*tg < 1 {\r\n g = t1\r\n } else if 3*tg < 2 {\r\n g = t2 + (t1-t2)*(2.0/3.0-tg)*6\r\n } else {\r\n g = t2\r\n }\r\n\r\n // Blue\r\n if 6*tb < 1 {\r\n b = t2 + (t1-t2)*6*tb\r\n } else if 2*tb < 1 {\r\n b = t1\r\n } else if 3*tb < 2 {\r\n b = t2 + (t1-t2)*(2.0/3.0-tb)*6\r\n } else {\r\n b = t2\r\n }\r\n\r\n return Color{r, g, b}\r\n}", "func GenerateColormap(colors []models.ColorModel) {\n\tlogger := log.ColoredLogger()\n\tdateStr := strings.ReplaceAll(time.Now().Format(time.UnixDate), \":\", \"-\")\n\tfilepath := fmt.Sprintf(\"lib/assets/images/colormap_%s.png\", dateStr)\n\t// alright, this is going to be a very long terminal command. Hopefully there aren't limits.\n\tqueryStr := fmt.Sprintf(\"convert -size %dx1 xc:white \", len(colors))\n\tfor i, c := range colors {\n\t\tqueryStr += fmt.Sprintf(\"-fill '%s' -draw 'point %d,0' \", c.Hex, i)\n\t}\n\tqueryStr += filepath\n\n\tcmd := exec.Command(queryStr)\n\tcmd.Stdout = os.Stdout\n\tcmd.Stderr = os.Stderr\n\tlogger.Error(\"error\", zap.Error(cmd.Run()))\n}", "func main() {\n\t//empty init style with \"zero\" values\n\t// var colors map[string]string\n\n\t//direct declaration and assign style\n\tcolors := map[string]string{\n\t\t\"red\": \"#ff0000\",\n\t\t\"green\" : \"#45b467\",\n\t\t\"black\": \"#000000\",\n\t}\n\n\tfmt.Println(colors)\n\t//add key value pairs, note the types must match what was declared\n\tcolors[\"white\"] = \"#ffffff\"\n\n\t//remove a key value pair\n\tdelete(colors, \"red\")\n\tfmt.Printf(\"Updated colors: %v \\n\", colors)\n\n}", "func getColors(w http.ResponseWriter) {\n\t// creates a new slice of colors\n\tvar colors []Color\n\n\t// runs a query to pull data from the database\n\trows, err := db.Query(`SELECT color, r, g, b, a, hex, creatorId, creatorHash FROM colors ORDER BY g ASC, b ASC, hex;`)\n\t// checks the error\n\thtmlCheck(err, w, fmt.Sprint(\"There was an error \", err))\n\t// create variables to hold color properties\n\tvar name, r, g, b, a, hex, cID, cH string\n\t// for each color\n\tfor rows.Next() {\n\t\t// fill in the variables in given order\n\t\terr = rows.Scan(&name, &r, &g, &b, &a, &hex, &cID, &cH)\n\t\t// checks the error\n\t\thtmlCheck(err, w, fmt.Sprint(\"There was an error \", err))\n\t\t// creates a color with the rows details\n\t\tc := Color{\n\t\t\tname,\n\t\t\tr,\n\t\t\tg,\n\t\t\tb,\n\t\t\ta,\n\t\t\thex,\n\t\t\t0.,\n\t\t\tcID,\n\t\t\tcH,\n\t\t}\n\t\t// calculate the hue and add it to the color\n\t\tc.Hue = calcHue(c)\n\t\t// if the hue is not returned set it to zero\n\t\tif math.IsNaN(c.Hue) {\n\t\t\tc.Hue = 0.\n\t\t}\n\t\t// add the new color to the colors slice\n\t\tcolors = append(colors, c)\n\n\t}\n\t// encodes the colors array to json\n\terr = json.NewEncoder(w).Encode(getColorSorted(colors))\n\t// checks the error\n\thtmlCheck(err, w, fmt.Sprint(\"There was an error \", err))\n}", "func generatePalette(c0, c1 float64) [8]float64 {\n\n\t//Get signed float normalized palette (0 to 1)\n\tpal := [8]float64{}\n\tpal[0], pal[1] = c0, c1\n\tif c0 > c1 {\n\t\tpal[2] = (6*c0 + 1*c1) / 7\n\t\tpal[3] = (5*c0 + 2*c1) / 7\n\t\tpal[4] = (4*c0 + 3*c1) / 7\n\t\tpal[5] = (3*c0 + 4*c1) / 7\n\t\tpal[6] = (2*c0 + 5*c1) / 7\n\t\tpal[7] = (1*c0 + 6*c1) / 7\n\t} else {\n\t\tpal[2] = (4*c0 + 1*c1) / 5\n\t\tpal[3] = (3*c0 + 2*c1) / 5\n\t\tpal[4] = (2*c0 + 3*c1) / 5\n\t\tpal[5] = (1*c0 + 4*c1) / 5\n\t\tpal[6] = 0\n\t\tpal[7] = 1\n\t}\n\treturn pal\n}", "func ColorCode(s string) string {\n\tattr := 0\n\tfg := 39\n\tbg := 49\n\n\tfor _, key := range s {\n\t\tc, ok := codeMap[int(key)]\n\t\tif !ok {\n\t\t\tpanic(\"wrong color syntax: \" + string(key))\n\t\t}\n\n\t\tswitch {\n\t\tcase 0 <= c && c <= 8:\n\t\t\tattr = c\n\t\tcase 30 <= c && c <= 37:\n\t\t\tfg = c\n\t\tcase 40 <= c && c <= 47:\n\t\t\tbg = c\n\t\t}\n\t}\n\treturn fmt.Sprintf(\"\\033[%d;%d;%dm\", attr, fg, bg)\n}", "func GenColor(intr int) [][]uint8 {\n\toutput := [][]uint8{}\n\tfor i := 0; i <= 255; i += intr {\n\t\tfor j := 0; j <= 255; j += intr {\n\t\t\tfor k := 0; k <= 255; k += intr {\n\t\t\t\ta := []uint8{uint8(i), uint8(j), uint8(k)}\n\t\t\t\toutput = append(output, a)\n\n\t\t\t}\n\t\t}\n\t}\n\treturn output\n\n}", "func FindColor(c Color, palette []Color) Color {\n\tmatch := Default\n\tdist := float64(0)\n\tr, g, b := ToRGB(c)\n\tc1 := RGB{\n\t\tR: float64(r) / 255.0,\n\t\tG: float64(g) / 255.0,\n\t\tB: float64(b) / 255.0,\n\t}\n\tfor _, d := range palette {\n\t\tr, g, b = ToRGB(d)\n\t\tc2 := RGB{\n\t\t\tR: float64(r) / 255.0,\n\t\t\tG: float64(g) / 255.0,\n\t\t\tB: float64(b) / 255.0,\n\t\t}\n\t\t// CIE94 is more accurate, but really-really expensive.\n\t\tnd := DistanceCIE76(c1, c2)\n\t\tif math.IsNaN(nd) {\n\t\t\tnd = math.Inf(1)\n\t\t}\n\t\tif match == Default || nd < dist {\n\t\t\tmatch = d\n\t\t\tdist = nd\n\t\t}\n\t}\n\treturn match\n}", "func (this *Dcmp0_Chunk_TableLookupBody) LookupTable() (v [][]byte, err error) {\n\tif (this._f_lookupTable) {\n\t\treturn this.lookupTable, nil\n\t}\n\tthis.lookupTable = [][]byte([][]byte{[]uint8{0, 0}, []uint8{78, 186}, []uint8{0, 8}, []uint8{78, 117}, []uint8{0, 12}, []uint8{78, 173}, []uint8{32, 83}, []uint8{47, 11}, []uint8{97, 0}, []uint8{0, 16}, []uint8{112, 0}, []uint8{47, 0}, []uint8{72, 110}, []uint8{32, 80}, []uint8{32, 110}, []uint8{47, 46}, []uint8{255, 252}, []uint8{72, 231}, []uint8{63, 60}, []uint8{0, 4}, []uint8{255, 248}, []uint8{47, 12}, []uint8{32, 6}, []uint8{78, 237}, []uint8{78, 86}, []uint8{32, 104}, []uint8{78, 94}, []uint8{0, 1}, []uint8{88, 143}, []uint8{79, 239}, []uint8{0, 2}, []uint8{0, 24}, []uint8{96, 0}, []uint8{255, 255}, []uint8{80, 143}, []uint8{78, 144}, []uint8{0, 6}, []uint8{38, 110}, []uint8{0, 20}, []uint8{255, 244}, []uint8{76, 238}, []uint8{0, 10}, []uint8{0, 14}, []uint8{65, 238}, []uint8{76, 223}, []uint8{72, 192}, []uint8{255, 240}, []uint8{45, 64}, []uint8{0, 18}, []uint8{48, 46}, []uint8{112, 1}, []uint8{47, 40}, []uint8{32, 84}, []uint8{103, 0}, []uint8{0, 32}, []uint8{0, 28}, []uint8{32, 95}, []uint8{24, 0}, []uint8{38, 111}, []uint8{72, 120}, []uint8{0, 22}, []uint8{65, 250}, []uint8{48, 60}, []uint8{40, 64}, []uint8{114, 0}, []uint8{40, 110}, []uint8{32, 12}, []uint8{102, 0}, []uint8{32, 107}, []uint8{47, 7}, []uint8{85, 143}, []uint8{0, 40}, []uint8{255, 254}, []uint8{255, 236}, []uint8{34, 216}, []uint8{32, 11}, []uint8{0, 15}, []uint8{89, 143}, []uint8{47, 60}, []uint8{255, 0}, []uint8{1, 24}, []uint8{129, 225}, []uint8{74, 0}, []uint8{78, 176}, []uint8{255, 232}, []uint8{72, 199}, []uint8{0, 3}, []uint8{0, 34}, []uint8{0, 7}, []uint8{0, 26}, []uint8{103, 6}, []uint8{103, 8}, []uint8{78, 249}, []uint8{0, 36}, []uint8{32, 120}, []uint8{8, 0}, []uint8{102, 4}, []uint8{0, 42}, []uint8{78, 208}, []uint8{48, 40}, []uint8{38, 95}, []uint8{103, 4}, []uint8{0, 48}, []uint8{67, 238}, []uint8{63, 0}, []uint8{32, 31}, []uint8{0, 30}, []uint8{255, 246}, []uint8{32, 46}, []uint8{66, 167}, []uint8{32, 7}, []uint8{255, 250}, []uint8{96, 2}, []uint8{61, 64}, []uint8{12, 64}, []uint8{102, 6}, []uint8{0, 38}, []uint8{45, 72}, []uint8{47, 1}, []uint8{112, 255}, []uint8{96, 4}, []uint8{24, 128}, []uint8{74, 64}, []uint8{0, 64}, []uint8{0, 44}, []uint8{47, 8}, []uint8{0, 17}, []uint8{255, 228}, []uint8{33, 64}, []uint8{38, 64}, []uint8{255, 242}, []uint8{66, 110}, []uint8{78, 185}, []uint8{61, 124}, []uint8{0, 56}, []uint8{0, 13}, []uint8{96, 6}, []uint8{66, 46}, []uint8{32, 60}, []uint8{103, 12}, []uint8{45, 104}, []uint8{102, 8}, []uint8{74, 46}, []uint8{74, 174}, []uint8{0, 46}, []uint8{72, 64}, []uint8{34, 95}, []uint8{34, 0}, []uint8{103, 10}, []uint8{48, 7}, []uint8{66, 103}, []uint8{0, 50}, []uint8{32, 40}, []uint8{0, 9}, []uint8{72, 122}, []uint8{2, 0}, []uint8{47, 43}, []uint8{0, 5}, []uint8{34, 110}, []uint8{102, 2}, []uint8{229, 128}, []uint8{103, 14}, []uint8{102, 10}, []uint8{0, 80}, []uint8{62, 0}, []uint8{102, 12}, []uint8{46, 0}, []uint8{255, 238}, []uint8{32, 109}, []uint8{32, 64}, []uint8{255, 224}, []uint8{83, 64}, []uint8{96, 8}, []uint8{4, 128}, []uint8{0, 104}, []uint8{11, 124}, []uint8{68, 0}, []uint8{65, 232}, []uint8{72, 65}})\n\tthis._f_lookupTable = true\n\treturn this.lookupTable, nil\n}", "func (e Color) String() string {\n name, _ := colorMap[int32(e)]\n return name\n}", "func Linear(img image.Image, value float64) image.Image {\n\treturn utils.MapColor(img, LinearC(value))\n}", "func CopyColorSubTable(target uint32, start int32, x int32, y int32, width int32) {\n\tC.glowCopyColorSubTable(gpCopyColorSubTable, (C.GLenum)(target), (C.GLsizei)(start), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func shortestDistanceColor(colors []int, queries [][]int) []int {\n\tr := make([]int, 0)\n\t//data structure\n\t// brain storm:\n\t// 1) linked list\n\t// 2) hash\n\t// map[value int] indexes []int | ordered?\n\t// loop through colors to create map\n\t// check if the value exist\n\t// loop through indexes to find the lowest difference\n\t//\n\t// optionb) only 3 values not too much sense to hash it.\n\t//\n\t// O(1*ln(M) + N)\n\t// 3) list\n\t// brute force loop forward and backward until match\n\t// O(N)\n\t// Probably going with this\n\n\tfor _, v := range queries {\n\t\tshortest := -1\n\t\tfunc() {\n\t\t\tfor i := v[0]; i < len(colors); i++ {\n\n\t\t\t\tif v[1] == colors[i] {\n\t\t\t\t\tdistance := i - v[0]\n\t\t\t\t\tshortest = distance\n\t\t\t\t}\n\t\t\t}\n\t\t\tfor i := v[0]; i >= 0; i-- {\n\t\t\t\tdistance := v[0] - i\n\t\t\t\tif shortest != -1 {\n\t\t\t\t\tif distance < shortest {\n\t\t\t\t\t\tshortest = distance\n\t\t\t\t\t}\n\t\t\t\t} else {\n\t\t\t\t\tshortest = distance\n\t\t\t\t}\n\t\t\t}\n\t\t}()\n\t\tr = append(r, shortest)\n\t}\n\n\treturn r\n}", "func Default(s float64) *Palette {\n\tvar p Palette\n\n\tfor x := 0; x < 256; x++ {\n\t\tr := (128.0 + 128*math.Sin(math.Pi*float64(x)/16.0)) / 256.0\n\t\tg := (128.0 + 128*math.Sin(math.Pi*float64(x)/128.0)) / 256.0\n\t\tb := (8.0) / 256.0\n\n\t\tp[x] = colorful.Color{r, g, b}\n\t}\n\n\treturn &p\n}", "func New(value ...Attribute) *Color {\n\treturn getCacheColor(value...)\n}", "func hueToRGB(p, q, t float64) float64 {\n if t < 0 {\n t += 1\n }\n if t > 1 {\n t -= 1\n }\n if t < 1.0/6 {\n return p + (q-p)*6*t\n }\n if t < 0.5 {\n return q\n }\n if t < 2.0/3 {\n return p + (q-p)*(2.0/3-t)*6\n }\n return p\n}", "func getColor[K, V any](n *Node[K, V]) Color {\n\tif n == nil {\n\t\treturn BLACK\n\t}\n\treturn n.color\n}", "func (h *Heuristics) ShowColors() {\n\t\n\tfmt.Println(\"colors :: \")\n\tfor k, v := range h.colors {\n\t\tif v == 0 {\n\t\t\tfmt.Println(\"Need[\", k+1, \"] = \", h.need[k], \" Utility[\", k+1, \"] = \", h.utility[k])\n\t\t} else {\n\t\t\tfmt.Print(\"Colors[\", k+1, \"] = \", h.colors[k], \"\\t\")\n\t\t\tneighbors := h.g.AdjList[k]\n\t\t\tfor _, value := range neighbors {\n\t\t\t\tfmt.Print(value, \"\\t\")\n\t\t\t}\n\t\t\tfmt.Print(\"\\n\")\n\t\t}\n\t}\n\tfmt.Print(\"\\n\")\n}", "func HiRed(format string, a ...interface{}) { colorPrint(FgHiRed, format, a...) }", "func Num2DiaCol(pinyinWithNumbers string, colors []string, separator string) string {\n pinyinWithNumbers = strings.Replace(pinyinWithNumbers, \"v\", \"ü\", -1)\n pinyinWithNumbers = strings.Replace(pinyinWithNumbers, \"V\", \"Ü\", -1)\n\n splitString := splitNumbersString(pinyinWithNumbers)\n\n s := \"\"\n\n for i, w := range splitString {\n t := addDiacritic(w)\n if colors != nil {\n if w.tone != -1 {\n t = addHTMLColors(t, colors[w.tone])\n }\n }\n s += t\n if i < len(splitString)-1 {\n s += separator\n }\n }\n return s\n}", "func (t *Table) Lookup(s string) (n uint32, ok bool) {\n\ti0 := int(murmurSeed(0).hash(s)) & t.level0Mask\n\tseed := t.level0[i0]\n\ti1 := int(murmurSeed(seed).hash(s)) & t.level1Mask\n\tn = t.level1[i1]\n\treturn n, s == t.keys[int(n)]\n}", "func MakeTable(poly uint32) *Table {}", "func printMap(m map[string]string) {\n\tfor color, hex := range m { //key, value\n\t\tfmt.Println(\"Hex code for\", color, \"is\", hex)\n\t}\n}", "func (s *Surface) Eval2(x, y float64) col.Color {\n\t// For any point, the color rendered is the sum of the emissive, ambient and the diffuse/specular\n\t// contributions from all of the lights.\n\n\tmaterial := s.Mat\n\tnormals := s.Normals\n\tif normals == nil {\n\t\tnormals = texture.DefaultNormal\n\t}\n\tambient := s.Ambient\n\tview := []float64{0, 0, 1}\n\n\temm, amb, diff, spec, shine := material.Eval2(x, y) // Emissive\n\n\t// Emissive\n\tlemm := &color.FRGBA{}\n\tif emm != nil {\n\t\tlemm = emm\n\t}\n\n\t// Ambient\n\tacol, _, _, _ := ambient.Eval2(x, y)\n\tlamb := amb.Prod(acol) // Ambient\n\tcol := lemm\n\tcol = col.Add(lamb)\n\tif diff == nil {\n\t\treturn col\n\t}\n\n\t// Cummulative diffuse and specular for all lights\n\tnormal := normals.Eval2(x, y)\n\tcdiff, cspec := &color.FRGBA{}, &color.FRGBA{}\n\tfor _, light := range s.Lights {\n\t\tlcol, dir, dist, pow := light.Eval2(x, y)\n\t\tif lcol.IsBlack() {\n\t\t\tcontinue\n\t\t}\n\t\tlambert := Dot(dir, normal)\n\t\tif lambert < 0 {\n\t\t\tcontinue\n\t\t}\n\t\tif dist > 0 {\n\t\t\tlcol = lcol.Scale(pow / (dist * dist))\n\t\t}\n\t\tcdiff = cdiff.Add(lcol.Prod(diff.Scale(lambert))) // Diffuse\n\t\tif spec != nil {\n\t\t\tif blinn {\n\t\t\t\t// Blinn-Phong\n\t\t\t\thalf := Unit([]float64{dir[0] + view[0], dir[1] + view[1], dir[2] + view[2]})\n\t\t\t\tdp := Dot(half, normal)\n\t\t\t\tif dp > 0 {\n\t\t\t\t\tphong := math.Pow(dp, shine*4)\n\t\t\t\t\tcspec = cspec.Add(lcol.Prod(spec.Scale(phong))) // Specular\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\t// Phong\n\t\t\t\tdp := Dot(Reflect(dir, normal), view)\n\t\t\t\tif dp > 0 {\n\t\t\t\t\tphong := math.Pow(dp, shine)\n\t\t\t\t\tcspec = cspec.Add(lcol.Prod(spec.Scale(phong))) // Specular\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\tcol = col.Add(cdiff)\n\tcol = col.Add(cspec)\n\treturn col\n}", "func (c Hex) ColorName(colors ColorTable) ColorSpace {\n\treturn c.getRGB().ColorName(colors)\n}", "func colorcomp(s string) (red, green, blue, alpha float64) {\n\tif len(s) < 7 && s[0:0] != \"#\" {\n\t\treturn red, green, blue, alpha\n\t}\n\tvar av = make([]byte, 1)\n\trv, _ := hex.DecodeString(s[1:3])\n\tgv, _ := hex.DecodeString(s[3:5])\n\tbv, _ := hex.DecodeString(s[5:7])\n\n\tred = float64(rv[0])\n\tgreen = float64(gv[0])\n\tblue = float64(bv[0])\n\talpha = 255.0\n\n\tif len(s) == 9 {\n\t\tav, _ = hex.DecodeString(s[7:9])\n\t\talpha = float64(av[0])\n\t}\n\treturn red, green, blue, alpha\n}", "func printMap(c map[string]string) {\n\t// Iterate over a map\n\tfor color, hex := range c {\n\t\tfmt.Println(\"Hex code for\", color, \"is\", hex)\n\t}\n}", "func getColor(colorstr string) (*color.RGBA, error) {\n\tvar r, g, b uint8\n\tformat := \"%02x%02x%02x\"\n\t_, err := fmt.Sscanf(colorstr, format, &r, &g, &b)\n\tif err != nil {\n\t\treturn DefaultBackgroundColor, err\n\t}\n\treturn &color.RGBA{r, g, b, 255}, nil\n}", "func ReadColorMap(r io.Reader, h *FileHeader) (ColorMap, error) {\n\tvar m ColorMap = make([]Color, h.NumberOfColors)\n\n\t// Use NumOfColors instead of ColorMapEntries: https://gitlab.freedesktop.org/xorg/app/xwd/-/blob/master/xwd.c#L489\n\tvar i uint32\n\tvar err error\n\n\tbuf := make([]byte, colorSize)\n\n\tfor i = 0; i < h.ColorMapEntries; i++ {\n\t\t_, err = r.Read(buf)\n\t\tif err != nil {\n\t\t\treturn nil, &IOError{err, \"reading colormap\"}\n\t\t}\n\n\t\tm[i] = Color{\n\t\t\tbinary.BigEndian.Uint32(buf[0:4]), // << 8 seems to be wrong\n\t\t\tbinary.BigEndian.Uint16(buf[4:6]),\n\t\t\tbinary.BigEndian.Uint16(buf[6:8]),\n\t\t\tbinary.BigEndian.Uint16(buf[8:10]),\n\t\t\tbuf[10], buf[11],\n\t\t}\n\t}\n\n\treturn m, nil\n}", "func hsv(h, s, v float64) color.Color {\n\th *= 6\n\tc := s * v\n\tx := c * (1 - math.Abs(math.Mod(h, 2)-1))\n\n\tvar r, g, b float64\n\tswitch {\n\tcase 0 <= h && h <= 1:\n\t\tr, g, b = c, x, 0\n\tcase 1 < h && h <= 2:\n\t\tr, g, b = x, c, 0\n\tcase 2 < h && h <= 3:\n\t\tr, g, b = 0, c, x\n\tcase 3 < h && h <= 4:\n\t\tr, g, b = 0, x, c\n\tcase 4 < h && h <= 5:\n\t\tr, g, b = x, 0, c\n\tcase 5 < h && h <= 6:\n\t\tr, g, b = c, 0, x\n\t}\n\n\tm := v - c\n\tr, g, b = r+m, g+m, b+m\n\n\tconst max = (1 << 16) - 1\n\tr, g, b = r*max, g*max, b*max\n\treturn color.RGBA64{R: uint16(r), G: uint16(g), B: uint16(b), A: max}\n}", "func getColorIndex(temp float64) int {\n\tif temp < *minTemp {\n\t\treturn 0\n\t}\n\tif temp > *maxTemp {\n\t\treturn len(colors) - 1\n\t}\n\treturn int((temp - *minTemp) * float64(len(colors)-1) / (*maxTemp - *minTemp))\n}", "func appendHLColor(hl []byte, n int, hlType byte) []byte {\n\treturn append(hl, bytes.Repeat([]byte{hlType}, n)...)\n}", "func Lookup(k byte, x *[16]byte) int32", "func (b *BoardTest) TestQuickColors(t *C) {\n\tl := new(RGBLED, 9, 10, 11)\n\tvar cs = map[string][3]byte{\n\t\t\"red\": [3]byte{0xFF, 00, 00},\n\t\t\"green\": [3]byte{00, 0xFF, 00},\n\t\t\"blue\": [3]byte{00, 00, 0xFF},\n\t\t\"black\": [3]byte{00, 00, 00},\n\t\t\"white\": [3]byte{0xFF, 0xFF, 0xFF},\n\t}\n\tfor c, v := range cs {\n\t\tl.QuickColor(c)\n\t\tt.Check(l.Red, Equals, v[0])\n\t\tt.Check(l.Green, Equals, v[1])\n\t\tt.Check(l.Blue, Equals, v[2])\n\t}\n}", "func colorClique(clique []graph.Node) map[int64]int {\n\tcolors := make(map[int64]int, len(clique))\n\tfor c, u := range clique {\n\t\tcolors[u.ID()] = c\n\t}\n\treturn colors\n}", "func Color() string {\n\treturn lookup(lang, \"colors\", true)\n}", "func RedString(format string, a ...interface{}) string { return colorString(format, FgRed, a...) }", "func colorize(s interface{}, c int) string {\n\treturn fmt.Sprintf(\"\\x1b[%dm%v\\x1b[0m\", c, s)\n}", "func colorize(s interface{}, c int) string {\n\treturn fmt.Sprintf(\"\\x1b[%dm%v\\x1b[0m\", c, s)\n}", "func Red(format string, a ...interface{}) { colorPrint(FgRed, format, a...) }", "func Image(m *image.RGBA, key string, colors []color.RGBA) {\n\tsize := m.Bounds().Size()\n\tsquares := 6\n\tquad := size.X / squares\n\tmiddle := math.Ceil(float64(squares) / float64(2))\n\tcolorMap := make(map[int]color.RGBA)\n\tvar currentYQuadrand = 0\n\tfor y := 0; y < size.Y; y++ {\n\t\tyQuadrant := y / quad\n\t\tif yQuadrant != currentYQuadrand {\n\t\t\t// when y quadrant changes, clear map\n\t\t\tcolorMap = make(map[int]color.RGBA)\n\t\t\tcurrentYQuadrand = yQuadrant\n\t\t}\n\t\tfor x := 0; x < size.X; x++ {\n\t\t\txQuadrant := x / quad\n\t\t\tif _, ok := colorMap[xQuadrant]; !ok {\n\t\t\t\tif float64(xQuadrant) < middle {\n\t\t\t\t\tcolorMap[xQuadrant] = draw.PickColor(key, colors, xQuadrant+3*yQuadrant)\n\t\t\t\t} else if xQuadrant < squares {\n\t\t\t\t\tcolorMap[xQuadrant] = colorMap[squares-xQuadrant-1]\n\t\t\t\t} else {\n\t\t\t\t\tcolorMap[xQuadrant] = colorMap[0]\n\t\t\t\t}\n\t\t\t}\n\t\t\tm.Set(x, y, colorMap[xQuadrant])\n\t\t}\n\t}\n}", "func GetColors() map[int]string {\n\treturn colors\n}", "func (c *Color) SetString(str string, base color.Color) error {\n\tif len(str) == 0 { // consider it null\n\t\tc.SetToNil()\n\t\treturn nil\n\t}\n\t// pr := prof.Start(\"Color.SetString\")\n\t// defer pr.End()\n\tlstr := strings.ToLower(str)\n\tswitch {\n\tcase lstr[0] == '#':\n\t\treturn c.ParseHex(str)\n\tcase strings.HasPrefix(lstr, \"hsl(\"):\n\t\tval := lstr[4:]\n\t\tval = strings.TrimRight(val, \")\")\n\t\tformat := \"%d,%d,%d\"\n\t\tvar h, s, l int\n\t\tfmt.Sscanf(val, format, &h, &s, &l)\n\t\tc.SetHSL(float32(h), float32(s)/100.0, float32(l)/100.0)\n\tcase strings.HasPrefix(lstr, \"rgb(\"):\n\t\tval := lstr[4:]\n\t\tval = strings.TrimRight(val, \")\")\n\t\tval = strings.Trim(val, \"%\")\n\t\tvar r, g, b, a int\n\t\ta = 255\n\t\tformat := \"%d,%d,%d\"\n\t\tif strings.Count(val, \",\") == 4 {\n\t\t\tformat = \"%d,%d,%d,%d\"\n\t\t\tfmt.Sscanf(val, format, &r, &g, &b, &a)\n\t\t} else {\n\t\t\tfmt.Sscanf(val, format, &r, &g, &b)\n\t\t}\n\t\tc.SetUInt8(uint8(r), uint8(g), uint8(b), uint8(a))\n\tcase strings.HasPrefix(lstr, \"rgba(\"):\n\t\tval := lstr[5:]\n\t\tval = strings.TrimRight(val, \")\")\n\t\tval = strings.Trim(val, \"%\")\n\t\tvar r, g, b, a int\n\t\tformat := \"%d,%d,%d,%d\"\n\t\tfmt.Sscanf(val, format, &r, &g, &b, &a)\n\t\tc.SetUInt8(uint8(r), uint8(g), uint8(b), uint8(a))\n\tcase strings.HasPrefix(lstr, \"pref(\"):\n\t\tval := lstr[5:]\n\t\tval = strings.TrimRight(val, \")\")\n\t\tclr := ThePrefs.PrefColor(val)\n\t\tif clr != nil {\n\t\t\t*c = *clr\n\t\t}\n\tdefault:\n\t\tif hidx := strings.Index(lstr, \"-\"); hidx > 0 {\n\t\t\tcmd := lstr[:hidx]\n\t\t\tpctstr := lstr[hidx+1:]\n\t\t\tpct, gotpct := kit.ToFloat32(pctstr)\n\t\t\tswitch cmd {\n\t\t\tcase \"lighter\":\n\t\t\t\tcvtPctStringErr(gotpct, pctstr)\n\t\t\t\tif base != nil {\n\t\t\t\t\tc.SetColor(base)\n\t\t\t\t}\n\t\t\t\tc.SetColor(c.Lighter(pct))\n\t\t\t\treturn nil\n\t\t\tcase \"darker\":\n\t\t\t\tcvtPctStringErr(gotpct, pctstr)\n\t\t\t\tif base != nil {\n\t\t\t\t\tc.SetColor(base)\n\t\t\t\t}\n\t\t\t\tc.SetColor(c.Darker(pct))\n\t\t\t\treturn nil\n\t\t\tcase \"highlight\":\n\t\t\t\tcvtPctStringErr(gotpct, pctstr)\n\t\t\t\tif base != nil {\n\t\t\t\t\tc.SetColor(base)\n\t\t\t\t}\n\t\t\t\tc.SetColor(c.Highlight(pct))\n\t\t\t\treturn nil\n\t\t\tcase \"samelight\":\n\t\t\t\tcvtPctStringErr(gotpct, pctstr)\n\t\t\t\tif base != nil {\n\t\t\t\t\tc.SetColor(base)\n\t\t\t\t}\n\t\t\t\tc.SetColor(c.Samelight(pct))\n\t\t\t\treturn nil\n\t\t\tcase \"saturate\":\n\t\t\t\tcvtPctStringErr(gotpct, pctstr)\n\t\t\t\tif base != nil {\n\t\t\t\t\tc.SetColor(base)\n\t\t\t\t}\n\t\t\t\tc.SetColor(c.Saturate(pct))\n\t\t\t\treturn nil\n\t\t\tcase \"pastel\":\n\t\t\t\tcvtPctStringErr(gotpct, pctstr)\n\t\t\t\tif base != nil {\n\t\t\t\t\tc.SetColor(base)\n\t\t\t\t}\n\t\t\t\tc.SetColor(c.Pastel(pct))\n\t\t\t\treturn nil\n\t\t\tcase \"clearer\":\n\t\t\t\tcvtPctStringErr(gotpct, pctstr)\n\t\t\t\tif base != nil {\n\t\t\t\t\tc.SetColor(base)\n\t\t\t\t}\n\t\t\t\tc.SetColor(c.Clearer(pct))\n\t\t\t\treturn nil\n\t\t\tcase \"opaquer\":\n\t\t\t\tcvtPctStringErr(gotpct, pctstr)\n\t\t\t\tif base != nil {\n\t\t\t\t\tc.SetColor(base)\n\t\t\t\t}\n\t\t\t\tc.SetColor(c.Opaquer(pct))\n\t\t\t\treturn nil\n\t\t\tcase \"blend\":\n\t\t\t\tif base != nil {\n\t\t\t\t\tc.SetColor(base)\n\t\t\t\t}\n\t\t\t\tclridx := strings.Index(pctstr, \"-\")\n\t\t\t\tif clridx < 0 {\n\t\t\t\t\terr := fmt.Errorf(\"gi.Color.SetString -- blend color spec not found -- format is: blend-PCT-color, got: %v -- PCT-color is: %v\", lstr, pctstr)\n\t\t\t\t\treturn err\n\t\t\t\t}\n\t\t\t\tpctstr = lstr[hidx+1 : clridx]\n\t\t\t\tpct, gotpct = kit.ToFloat32(pctstr)\n\t\t\t\tcvtPctStringErr(gotpct, pctstr)\n\t\t\t\tclrstr := lstr[clridx+1:]\n\t\t\t\tothc, err := ColorFromString(clrstr, base)\n\t\t\t\tc.SetColor(c.Blend(pct, &othc))\n\t\t\t\treturn err\n\t\t\t}\n\t\t}\n\t\tswitch lstr {\n\t\tcase \"none\", \"off\":\n\t\t\tc.SetToNil()\n\t\t\treturn nil\n\t\tcase \"transparent\":\n\t\t\tc.SetUInt8(0xFF, 0xFF, 0xFF, 0)\n\t\t\treturn nil\n\t\tcase \"inverse\":\n\t\t\tif base != nil {\n\t\t\t\tc.SetColor(base)\n\t\t\t}\n\t\t\tc.SetColor(c.Inverse())\n\t\t\treturn nil\n\t\tdefault:\n\t\t\treturn c.SetName(lstr)\n\t\t}\n\t}\n\treturn nil\n}", "func newDsaturColoring(nodes []graph.Node, colors map[int64]int) dSaturColoring {\n\tuncolored := make(set.Int64s)\n\tfor _, v := range nodes {\n\t\tvid := v.ID()\n\t\tif _, ok := colors[vid]; !ok {\n\t\t\tuncolored.Add(vid)\n\t\t}\n\t}\n\treturn dSaturColoring{\n\t\tcolors: colors,\n\t\tuncolored: uncolored,\n\t}\n}", "func (pal *CGBPalette) get(palette byte, num byte) (uint8, uint8, uint8) {\n\tidx := (palette * 8) + (num * 2)\n\tcolour := uint16(pal.palette[idx]) | uint16(pal.palette[idx + 1]) << 8\n\tr := uint8(colour & 0x1F)\n\tg := uint8((colour >> 5) & 0x1F)\n\tb := uint8((colour >> 10) & 0x1F)\n\treturn colMap[r], colMap[g], colMap[b]\n}", "func ccColor(val float32) color.Color {\n\tgradient := []gradientValue{\n\t\t{0.275, colornames.Black},\n\t\t{0.35, colornames.Darkgrey},\n\t\t{0.4, colornames.Gray},\n\t\t{0.5, colornames.Silver},\n\t\t{0.6, colornames.Midnightblue},\n\t\t{0.7, colornames.Darkblue},\n\t\t{0.8, colornames.Blue},\n\t\t{0.91, colornames.Green},\n\t\t{0.92, colornames.Yellowgreen},\n\t\t{0.93, colornames.Olivedrab},\n\t\t{0.94, colornames.Yellow},\n\t\t{0.95, colornames.Gold},\n\t\t{0.96, colornames.Orange},\n\t\t{0.97, colornames.Orangered},\n\t\t{0.98, colornames.Red},\n\t\t{0.99, colornames.Firebrick},\n\t\t{1.0, colornames.Maroon},\n\t\t{1.01, colornames.Darkmagenta},\n\t\t{1.02, colornames.Purple},\n\t\t{1.03, colornames.Mediumvioletred},\n\t\t{1.04, colornames.Palevioletred},\n\t\t{1.045, colornames.Pink},\n\t\t{1.05, colornames.Lavenderblush},\n\t}\n\n\tfor _, gv := range gradient {\n\t\tif val < gv.val {\n\t\t\treturn gv.color\n\t\t}\n\t}\n\n\treturn colornames.White\n}", "func buildColorOrder(habits habits.HabitList) *ColorAssignments {\n\tnumHabits := len(habits)\n\n\tcolorOrder := make([]uint8, numHabits)\n\tboundaries := make([]int, 0, numHabits)\n\ttags := make([]string, 0, numHabits)\n\tca := &ColorAssignments{colorOrder, boundaries, tags}\n\n\tif numHabits == 0 {\n\t\treturn ca\n\t}\n\n\t// Build color pallete from base color\n\t// Each group of 6x3 is a pallete.\n\t// Offset 160 dark colors\n\ttagChanged := true\n\tmodulate := false\n\tvar tagIndex, habitIndex, modulation uint8 = 0, 0, 0\n\tfor index, habit := range habits {\n\t\t// Reset groupings for each new tag\n\t\tif index > 0 && habit.Tag != habits[index-1].Tag {\n\t\t\ttagChanged = true\n\t\t\ttagIndex++\n\t\t\thabitIndex = 0\n\t\t\tca.TagBoundaries = append(ca.TagBoundaries, index)\n\t\t\tca.Tags = append(ca.Tags, habit.Tag)\n\t\t\tmodulate = false\n\t\t\tmodulation = 0\n\t\t}\n\t\t// If there are more than 6 habits per tag\n\t\t// \"modulate\" to the next row of ansi colors\n\t\t// and zig zag back towards the start of the group\n\t\tif modulate {\n\t\t\tmodulation += 36 + ColorGroupLength - habitIndex%ColorGroupLength - 1\n\t\t}\n\t\tif tagChanged {\n\t\t\tbaseColor := uint8(tagIndex*ColorGroupLength + ColorCodeOffset)\n\t\t\tcolorAssignment := baseColor + uint8(habitIndex) + modulation\n\t\t\tca.ColorOrder[index] = colorAssignment\n\t\t}\n\t\thabitIndex++\n\t}\n\t// Edge case for the last tag where there is no change\n\tca.TagBoundaries = append(ca.TagBoundaries, numHabits)\n\tca.Tags = append(ca.Tags, habits[numHabits-1].Tag)\n\treturn ca\n}", "func (s *videoController) lookupTile(tileY, tileX uint8, tileNumber byte, tileDataSelect bool) uint8 {\n\t// 8800 addressing mode - tileNumber is signed\n\ttileAddress := offsetAddress(0x9000, 16*int16(int8(tileNumber)))\n\tif tileDataSelect {\n\t\t// 8000 addressing mode\n\t\ttileAddress = 0x8000 + 16*uint16(tileNumber)\n\t}\n\n\trowAddress := offsetAddress(tileAddress, 2*int16(tileY)) // 2 bytes for every row\n\tlowerByte := s.readVRAM(rowAddress)\n\thigherByte := s.readVRAM(rowAddress + 1)\n\n\t// The leftmost pixel is represented by the rightmost (index-0) bit, thus the \"7-\"\n\tlowerBit := readBitN(lowerByte, 7-tileX)\n\thigherBit := readBitN(higherByte, 7-tileX)\n\n\tcolorNum := uint8(0)\n\tcolorNum = writeBitN(colorNum, 0, lowerBit)\n\tcolorNum = writeBitN(colorNum, 1, higherBit)\n\n\treturn colorNum\n}", "func ColorsStyle(cStyle colorStyle) {\n\tcolorFormating = cStyle\n}", "func color(r geometry.Ray, world geometry.Hitable, depth int) geometry.Vector {\n\thit, record := world.CheckForHit(r, 0.001, math.MaxFloat64)\n\n\t// if hit {\n\t// \ttarget := record.Point.Add(record.Normal).Add(RandomInUnitSphere())\n\t// \treturn color(&geometry.Ray{Origin: record.Point, Direction: target.Subtract(record.P)}, world).Scale(0.5)\n\t// }\n\n\tif hit {\n\t\tif depth < 50 {\n\t\t\tscattered, scatteredRay := record.Scatter(r, record)\n\t\t\tif scattered {\n\t\t\t\tnewColor := color(scatteredRay, world, depth+1)\n\t\t\t\treturn record.Material.Albedo().Multiply(newColor)\n\t\t\t}\n\t\t}\n\t}\n\n\t// Make unit vector so y is between -1.0 and 1.0\n\tunitDirection := r.Direction.Normalize()\n\n\tvar t float64 = 0.5 * (unitDirection.Y + 1.0)\n\n\t// The two vectors here are what creates the sky(Blue to white gradient of the background)\n\treturn geometry.Vector{X: 1.0, Y: 1.0, Z: 1.0}.Scale(1.0 - t).Add(geometry.Vector{X: 0.5, Y: 0.7, Z: 1.0}.Scale(t))\n}", "func getColor(r Ray, world HittableList, depth int) mgl64.Vec3 {\n\thits := world.Hit(r, Epsilon, math.MaxFloat64)\n\tif len(hits) > 0 {\n\t\t// HittableList makes sure the first (and only) intersection\n\t\t// is the closest one:\n\t\thit := hits[0]\n\t\t// Simulate the light response of this material.\n\t\tisScattered, attenuation, scattered := hit.Mat.Scatter(r, hit)\n\t\t// If this ray is reflected off the surface, determine the response\n\t\t// of the scattered ray:\n\t\tif isScattered && depth < MaxBounces {\n\t\t\tresponse := getColor(scattered, world, depth+1)\n\n\t\t\treturn mgl64.Vec3{response.X() * attenuation.X(),\n\t\t\t\tresponse.Y() * attenuation.Y(),\n\t\t\t\tresponse.Z() * attenuation.Z()}\n\t\t}\n\t\t// Otherwise, the ray was absorbed, or we have exceeded the\n\t\t// maximum number of light bounces:\n\t\treturn mgl64.Vec3{0.0, 0.0, 0.0}\n\t}\n\t// If we don't intersect with anything, plot a background instead:\n\tunitDirection := r.Direction().Normalize()\n\tt := 0.5*unitDirection.Y() + 1.0\n\t// Linearly interpolate between white and blue:\n\tA := mgl64.Vec3{1.0, 1.0, 1.0}.Mul(1.0 - t)\n\tB := mgl64.Vec3{0.5, 0.7, 1.0}.Mul(t)\n\treturn A.Add(B)\n}", "func getHashColorBullet(v string) string {\n\tif len(v) > 6 {\n\t\tv = strutil.Head(v, 6)\n\t}\n\n\treturn fmtc.Sprintf(\" {#\" + strutil.Head(v, 6) + \"}● {!}\")\n}", "func ColorState(r *Redlight, t time.Time) int {\n\ttotalPatternDuration := func() (result int) {\n\t\tfor _, v := range r.pattern {\n\t\t\tresult += v[1]\n\t\t}\n\t\treturn\n\t}()\n\truntime := int(t.Sub(r.initialTime).Seconds())\n\ttimeInLoop := runtime % totalPatternDuration\n\n\tvar cumulatedTime int\n\tvar state int\n\tfor _, v := range r.pattern {\n\t\tif cumulatedTime > timeInLoop {\n\t\t\tbreak\n\t\t}\n\t\tcumulatedTime += v[1]\n\t\tstate = v[0]\n\t}\n\treturn state\n}", "func HiBlack(format string, a ...interface{}) { colorPrint(FgHiBlack, format, a...) }", "func loadColorBuckets(colorPath string) ([]colorBucket, string, string, error) {\n buckets := make([]colorBucket, 0)\n multiId := \"\"\n whiteId := \"\"\n\n colorFile, err := os.Open(colorPath)\n if err != nil { return buckets, multiId, whiteId, err}\n defer colorFile.Close()\n\n rdr := csv.NewReader(colorFile)\n idx := 0\n for {\n record, err := rdr.Read()\n if err == io.EOF { break }\n if err != nil { return buckets, multiId, whiteId, err }\n\n if len(record) != CSV_RECORD_LENGTH {\n return buckets, multiId, whiteId, errors.New(\"Malformed color csv file\")\n }\n\n if record[2] == MULTI_CODE {\n multiId = record[0]\n continue\n }\n if record[1] == \"White\" || record[1] == \"white\" {\n whiteId = record[0]\n }\n\n lab, err := converter.HexStringToLab(record[2])\n if err != nil { return buckets, multiId, whiteId, err }\n\n buckets = append(buckets, colorBucket{\n colorId: record[0],\n colorName: record[1],\n labColor: lab,\n })\n\n idx++\n }\n\n if multiId == \"\" { return buckets, multiId, whiteId, errors.New(\"No multival given\")}\n return buckets, multiId, whiteId, nil\n}", "func calcHue(c Color) float64 {\n\t// divides the R, G, and B values by 255\n\tr, _ := strconv.ParseFloat(c.R, 64)\n\tr = float64(r / 255)\n\tg, _ := strconv.ParseFloat(c.G, 64)\n\tg = float64(g / 255)\n\tb, _ := strconv.ParseFloat(c.B, 64)\n\tb = float64(b / 255)\n\n\t// finds the min and max of the colors\n\tmax := findMax([]float64{r, g, b})\n\tmin := findMin([]float64{r, g, b})\n\t// finds the difference between the min and max\n\tdif := max - min\n\t// add := max + min\n\tvar hue float64\n\tif min == max {\n\t\thue = 0.\n\t}\n\t// if red is the max\n\tif r == max {\n\t\thue = (((60 * (g - b)) / dif) + 360)\n\t}\n\t// if green is the max\n\tif g == max {\n\t\thue = 2.0 + ((60 * (b - r)) / dif) + 120\n\t}\n\t// if blue is the max\n\tif b == max {\n\t\thue = ((60 * (r - g)) / dif) + 240\n\t}\n\t// return the hue\n\treturn hue\n}", "func chooseColor(height int, lowColor bool) tl.Attr {\n\tif lowColor {\n\t\treturn tl.ColorGreen\n\t}\n\tidx := int(math.Sqrt(float64(height+1))) - 1\n\tif idx >= len(palette) {\n\t\tidx = len(palette) - 1\n\t}\n\treturn tl.Attr(palette[idx])\n}", "func RandColor(dst inter.Adder, n, m, k int) {\n\tg := RandGraph(n, m)\n\tvar mkVar = func(n, c int) z.Var {\n\t\treturn z.Var(n*c + c + 1)\n\t}\n\tfor i := range g {\n\t\tfor j := 0; j < k; j++ {\n\t\t\tm := mkVar(i, j).Pos()\n\t\t\tdst.Add(m)\n\t\t}\n\t\tdst.Add(0)\n\t}\n\tfor a, es := range g {\n\t\tfor _, b := range es {\n\t\t\tif b >= a {\n\t\t\t\tcontinue\n\t\t\t}\n\t\t\tfor c := 0; c < k; c++ {\n\t\t\t\ta := mkVar(a, c).Neg()\n\t\t\t\tb := mkVar(b, c).Neg()\n\t\t\t\tdst.Add(a)\n\t\t\t\tdst.Add(b)\n\t\t\t}\n\t\t\tdst.Add(0)\n\t\t}\n\t}\n}", "func colors(w http.ResponseWriter, req *http.Request) {\n\t// if method is get\n\tif req.Method == http.MethodGet {\n\t\t// grabs the color hex from the request\n\t\tc := req.FormValue(\"color\")\n\t\t// if one color is not specified get them all\n\t\tif c == \"\" {\n\t\t\tgetColors(w)\n\t\t\treturn\n\t\t}\n\t\t// gets the specific color asked for\n\t\tgetColor(w, c)\n\t\treturn\n\t}\n\t// if the request is a post method, add the color to the db.\n\tif req.Method == http.MethodPost {\n\t\taddColor(w, req)\n\t\treturn\n\t}\n\t// if the Method is a patch methd update the color\n\tif req.Method == http.MethodPatch {\n\t\teditColor(w, req)\n\t\treturn\n\t}\n}", "func HiBlue(format string, a ...interface{}) { colorPrint(FgHiBlue, format, a...) }", "func ColorByStatus(cond bool, code int) string {\n\tswitch {\n\tcase code >= 200 && code < 300:\n\t\treturn map[bool]string{true: green, false: w32Green}[cond]\n\tcase code >= 300 && code < 400:\n\t\treturn map[bool]string{true: white, false: w32White}[cond]\n\tcase code >= 400 && code < 500:\n\t\treturn map[bool]string{true: yellow, false: w32Yellow}[cond]\n\tdefault:\n\t\treturn map[bool]string{true: red, false: w32Red}[cond]\n\t}\n}", "func Color(value color.Color) *SimpleElement { return newSEColor(\"color\", value) }", "func getTileColor(tile model.Tile) tcell.Style {\n\ttileColor := tcell.StyleDefault.Foreground(tcell.ColorBlack)\n\tswitch tile {\n\tcase 0:\n\t\ttileColor = tileColor.Background(tcell.ColorLightGrey)\n\tcase 2:\n\t\ttileColor = tileColor.Background(tcell.ColorDarkGrey)\n\tcase 4:\n\t\ttileColor = tileColor.Background(tcell.ColorSlateGrey)\n\tcase 8:\n\t\ttileColor = tileColor.Background(tcell.ColorGrey)\n\tcase 16:\n\t\ttileColor = tileColor.Background(tcell.ColorTeal)\n\tcase 32:\n\t\ttileColor = tileColor.Background(tcell.ColorTan)\n\tcase 64:\n\t\ttileColor = tileColor.Background(tcell.ColorOrange)\n\tcase 128:\n\t\ttileColor = tileColor.Background(tcell.ColorDarkOrange)\n\tcase 256:\n\t\ttileColor = tileColor.Background(tcell.ColorOrangeRed)\n\tcase 512:\n\t\ttileColor = tileColor.Background(tcell.ColorRed)\n\tcase 1024:\n\t\ttileColor = tileColor.Background(tcell.ColorDarkRed)\n\tcase 2048:\n\t\ttileColor = tileColor.Background(tcell.ColorDarkViolet)\n\tcase 4096:\n\t\ttileColor = tileColor.Background(tcell.ColorBlueViolet)\n\t// We don't have a lot of colors to work with so for now we'll make it boring\n\t// pass 4096.\n\tdefault:\n\t\ttileColor = tileColor.Background(tcell.ColorSlateGrey)\n\t}\n\treturn tileColor\n}", "func ColorDistance(a, b color.Color) int {\n\taR, aG, aB, aA := a.RGBA()\n\tbR, bG, bB, bA := b.RGBA()\n\tabs := func(a int) int {\n\t\tif a < 0 {\n\t\t\treturn -a\n\t\t}\n\t\treturn a\n\t}\n\tmax := func(nums ...int) int {\n\t\tm := 0\n\t\tfor _, n := range nums {\n\t\t\tif n > m {\n\t\t\t\tm = n\n\t\t\t}\n\t\t}\n\t\treturn m\n\t}\n\t// Interestingly, the RGBA method returns components in the range [0, 0xFFFF] corresponding\n\t// to the 8-bit values multiplied by 0x101 (see https://blog.golang.org/image). Therefore,\n\t// we must shift them to the right by 8 so that they are in the more typical [0, 255] range.\n\treturn max(abs(int(aR>>8)-int(bR>>8)),\n\t\tabs(int(aG>>8)-int(bG>>8)),\n\t\tabs(int(aB>>8)-int(bB>>8)),\n\t\tabs(int(aA>>8)-int(bA>>8)))\n}", "func hackerColors() *Palette {\n\tsize := 1\n\tp := Palette{\n\t\tcolors: make([]Style, size),\n\t\tsize: size,\n\t}\n\tp.colors[0] = Color256(82)\n\treturn &p\n}", "func makeRamp(colorA, colorB string, steps float64) (s []string) {\n\tcA, _ := colorful.Hex(colorA)\n\tcB, _ := colorful.Hex(colorB)\n\n\tfor i := 0.0; i < steps; i++ {\n\t\tc := cA.BlendLuv(cB, i/steps)\n\t\ts = append(s, colorToHex(c))\n\t}\n\treturn\n}", "func combineColor(color ColorName, isBackgroundColor bool) outPutSet {\n\tif color >= COLOR_BLACK && color <= COLOR_WHITE {\n\t\tif isBackgroundColor {\n\t\t\treturn COLOR_BACKGROUND + outPutSet(color)\n\t\t}\n\t\treturn COLOR_FOREGROUND + outPutSet(color)\n\t}\n\treturn 0\n}", "func BlueString(format string, a ...interface{}) string { return colorString(format, FgBlue, a...) }" ]
[ "0.66989845", "0.65118223", "0.64939904", "0.62917787", "0.61029834", "0.6091843", "0.60855556", "0.590682", "0.58695626", "0.57240605", "0.5704761", "0.5699862", "0.5600927", "0.5594857", "0.5483596", "0.5458877", "0.54586065", "0.5406009", "0.5386899", "0.5356313", "0.53404915", "0.5337457", "0.5333159", "0.53113717", "0.5296344", "0.5281006", "0.52733624", "0.5254439", "0.52399266", "0.5238037", "0.5232978", "0.52198654", "0.51875925", "0.51736677", "0.5163871", "0.5160846", "0.51489097", "0.5132551", "0.5129989", "0.511636", "0.50875837", "0.50754213", "0.507273", "0.50638187", "0.5052353", "0.50265485", "0.5025689", "0.501379", "0.5002624", "0.5000391", "0.4988256", "0.49773747", "0.49646628", "0.49609476", "0.49532986", "0.49449584", "0.49392396", "0.49227652", "0.49219286", "0.48950887", "0.48835236", "0.48820725", "0.48621005", "0.48596647", "0.48567814", "0.48273432", "0.48256886", "0.48171094", "0.48111397", "0.479865", "0.479865", "0.4796038", "0.47957534", "0.4794578", "0.47898275", "0.4785653", "0.47623798", "0.47606578", "0.475896", "0.47576198", "0.4756861", "0.4755707", "0.47535065", "0.47403562", "0.47394517", "0.47386646", "0.47370872", "0.47333205", "0.47112504", "0.47070342", "0.4700392", "0.4699993", "0.4688923", "0.46887675", "0.4676788", "0.46739548", "0.465602", "0.46548414", "0.46547627", "0.46483847" ]
0.64137495
3
Compiles a shader object
func CompileShader(shader uint32) { C.glowCompileShader(gpCompileShader, (C.GLuint)(shader)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func (shader Shader) Compile() {\n\tgl.CompileShader(uint32(shader))\n}", "func CompileShader(shader uint32) {\n C.glowCompileShader(gpCompileShader, (C.GLuint)(shader))\n}", "func CompileShader(s Shader) {\n\tgl.CompileShader(s.Value)\n}", "func compileShader(shaderType wasm.GLenum, shaderSrc string) (wasm.WebGLShader, error) {\n\tvar shader = gl.CreateShader(shaderType)\n\tgl.ShaderSource(shader, shaderSrc)\n\tgl.CompileShader(shader)\n\n\tif !gl.GetShaderParameter(shader, wasm.COMPILE_STATUS).(bool) {\n\t\treturn nil, fmt.Errorf(\"could not compile shader: %s\", gl.GetShaderInfoLog(shader))\n\t}\n\treturn shader, nil\n}", "func CompileShader(shader uint32) {\n\tsyscall.Syscall(gpCompileShader, 1, uintptr(shader), 0, 0)\n}", "func (s *Shader) compile(source string, shaderType uint32) (shader uint32, err error) {\n\t// create a shader from source (returns shader ID)\n\tshader = gl.CreateShader(shaderType)\n\tcsource, free := gl.Strs(source) // returns a C String and a function to free the memory\n\t//\t\t\t\tshader, count, source string, length (unused)\n\tgl.ShaderSource(shader, 1, csource, nil)\n\tfree() // frees the memory used by csource\n\tgl.CompileShader(shader) // compile the shader\n\n\t// check if compiling failed\n\tvar status int32\n\t//\t\t\t shader info type\t\t pointer\n\tgl.GetShaderiv(shader, gl.COMPILE_STATUS, &status) // returns shader info\n\tif status == gl.FALSE {\n\t\tvar logLength int32\n\t\tgl.GetShaderiv(shader, gl.INFO_LOG_LENGTH, &logLength)\n\n\t\t// create empty string that can hold the log content\n\t\tlog := strings.Repeat(\"\\x00\", int(logLength+1))\n\t\tgl.GetShaderInfoLog(shader, logLength, nil, gl.Str(log)) // returns the shader compile log\n\n\t\t// set error message\n\t\terr = errors.New(\"Failed to compile OpenGL shader:\\n\" + log)\n\t}\n\n\treturn\n}", "func (native *OpenGL) CompileShader(shader uint32) {\n\tgl.CompileShader(shader)\n}", "func CompileShader(shader Uint) {\n\tcshader, _ := (C.GLuint)(shader), cgoAllocsUnknown\n\tC.glCompileShader(cshader)\n}", "func (r *device) LoadShader(s *gfx.Shader, done chan *gfx.Shader) {\n\t// If we are sharing assets with another renderer, allow it to load the\n\t// shader instead.\n\tr.shared.RLock()\n\tif r.shared.device != nil {\n\t\tr.shared.device.LoadShader(s, done)\n\t\tr.shared.RUnlock()\n\t\treturn\n\t}\n\tr.shared.RUnlock()\n\n\t// Perform pre-load checks on the shader.\n\tdoLoad, err := glutil.PreLoadShader(s, done)\n\tif err != nil {\n\t\tr.warner.Warnf(\"%v\\n\", err)\n\t\treturn\n\t}\n\tif !doLoad {\n\t\treturn\n\t}\n\n\tr.renderExec <- func() bool {\n\t\tnative := &nativeShader{\n\t\t\tr: r.rsrcManager,\n\t\t}\n\n\t\t// Compile vertex shader.\n\t\tnative.vertex = gl.CreateShader(gl.VERTEX_SHADER)\n\t\tsources, free := gl.Strs(string(s.GLSL.Vertex) + \"\\x00\")\n\t\tgl.ShaderSource(native.vertex, 1, sources, nil) // TODO(slimsag): use length parameter instead of null terminator\n\t\tgl.CompileShader(native.vertex)\n\t\tfree()\n\n\t\t// Check if the shader compiled or not.\n\t\tlog, compiled := shaderCompilerLog(native.vertex)\n\t\tif !compiled {\n\t\t\t// Just for sanity.\n\t\t\tnative.vertex = 0\n\n\t\t\t// Append the errors.\n\t\t\ts.Error = append(s.Error, []byte(s.Name+\" | Vertex shader errors:\\n\")...)\n\t\t\ts.Error = append(s.Error, log...)\n\t\t}\n\t\tif len(log) > 0 {\n\t\t\t// Send the compiler log to the debug writer.\n\t\t\tr.warner.Warnf(\"%s | Vertex shader errors:\\n\", s.Name)\n\t\t\tr.warner.Warnf(string(log))\n\t\t}\n\n\t\t// Compile fragment shader.\n\t\tnative.fragment = gl.CreateShader(gl.FRAGMENT_SHADER)\n\t\tsources, free = gl.Strs(string(s.GLSL.Fragment) + \"\\x00\")\n\t\tgl.ShaderSource(native.fragment, 1, sources, nil) // TODO(slimsag): use length parameter instead of null terminator\n\t\tgl.CompileShader(native.fragment)\n\t\tfree()\n\n\t\t// Check if the shader compiled or not.\n\t\tlog, compiled = shaderCompilerLog(native.fragment)\n\t\tif !compiled {\n\t\t\t// Just for sanity.\n\t\t\tnative.fragment = 0\n\n\t\t\t// Append the errors.\n\t\t\ts.Error = append(s.Error, []byte(s.Name+\" | Fragment shader errors:\\n\")...)\n\t\t\ts.Error = append(s.Error, log...)\n\t\t}\n\t\tif len(log) > 0 {\n\t\t\t// Send the compiler log to the debug writer.\n\t\t\tr.warner.Warnf(\"%s | Fragment shader errors:\\n\", s.Name)\n\t\t\tr.warner.Warnf(string(log))\n\t\t}\n\n\t\t// Create the shader program if all went well with the vertex and\n\t\t// fragment shaders.\n\t\tif native.vertex != 0 && native.fragment != 0 {\n\t\t\tnative.program = gl.CreateProgram()\n\t\t\tgl.AttachShader(native.program, native.vertex)\n\t\t\tgl.AttachShader(native.program, native.fragment)\n\t\t\tgl.LinkProgram(native.program)\n\n\t\t\t// Grab the linker's log.\n\t\t\tvar (\n\t\t\t\tlogSize int32\n\t\t\t\tlog []byte\n\t\t\t)\n\t\t\tgl.GetProgramiv(native.program, gl.INFO_LOG_LENGTH, &logSize)\n\n\t\t\tif logSize > 0 {\n\t\t\t\tlog = make([]byte, logSize)\n\t\t\t\tgl.GetProgramInfoLog(native.program, logSize, nil, &log[0])\n\n\t\t\t\t// Strip the null-termination byte.\n\t\t\t\tlog = log[:len(log)-1]\n\t\t\t}\n\n\t\t\t// Check for linker errors.\n\t\t\tvar ok int32\n\t\t\tgl.GetProgramiv(native.program, gl.LINK_STATUS, &ok)\n\t\t\tif ok == 0 {\n\t\t\t\t// Just for sanity.\n\t\t\t\tnative.program = 0\n\n\t\t\t\t// Append the errors.\n\t\t\t\ts.Error = append(s.Error, []byte(s.Name+\" | Linker errors:\\n\")...)\n\t\t\t\ts.Error = append(s.Error, log...)\n\t\t\t}\n\t\t\tif len(log) > 0 {\n\t\t\t\t// Send the linker log to the debug writer.\n\t\t\t\tr.warner.Warnf(\"%s | Linker errors:\\n\", s.Name)\n\t\t\t\tr.warner.Warnf(string(log))\n\t\t\t}\n\t\t}\n\n\t\t// Mark the shader as loaded if there were no errors.\n\t\tif len(s.Error) == 0 {\n\t\t\tnative.LocationCache = &glutil.LocationCache{\n\t\t\t\tGetAttribLocation: func(name string) int {\n\t\t\t\t\treturn int(gl.GetAttribLocation(native.program, gl.Str(name+\"\\x00\")))\n\t\t\t\t},\n\t\t\t\tGetUniformLocation: func(name string) int {\n\t\t\t\t\treturn int(gl.GetUniformLocation(native.program, gl.Str(name+\"\\x00\")))\n\t\t\t\t},\n\t\t\t}\n\n\t\t\ts.Loaded = true\n\t\t\ts.NativeShader = native\n\t\t\ts.ClearData()\n\n\t\t\t// Attach a finalizer to the shader that will later free it.\n\t\t\truntime.SetFinalizer(native, finalizeShader)\n\t\t}\n\n\t\t// Finish not Flush, see http://higherorderfun.com/blog/2011/05/26/multi-thread-opengl-texture-loading/\n\t\tgl.Finish()\n\n\t\t// Signal completion and return.\n\t\tselect {\n\t\tcase done <- s:\n\t\tdefault:\n\t\t}\n\t\treturn false // no frame rendered.\n\t}\n}", "func ShaderBinary(count int32, shaders *uint32, binaryformat uint32, binary unsafe.Pointer, length int32) {\n C.glowShaderBinary(gpShaderBinary, (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(shaders)), (C.GLenum)(binaryformat), binary, (C.GLsizei)(length))\n}", "func (debugging *debuggingOpenGL) CompileShader(shader uint32) {\n\tdebugging.recordEntry(\"CompileShader\", shader)\n\tdebugging.gl.CompileShader(shader)\n\tdebugging.recordExit(\"CompileShader\")\n}", "func (s *Shader) Init(shader io.Reader) (err error) {\n\ts.uniformLocs = make(map[string]int32)\n\ts.uniformBIndices = make(map[string]uint32)\n\ts.uniformBOs = make(map[string]uint32)\n\tshaders := []uint32{}\n\n\treader := bufio.NewReader(shader)\n\n\tshaderTypeLine, err := reader.ReadString('\\n')\n\tif err != nil {\n\t\treturn err\n\t}\n\n\t// eof gets set to true if we reached the end of the file\n\teof := false\n\n\tfor {\n\t\tshader := \"\"\n\n\t\t// decide on the shader type\n\t\tvar shaderType uint32\n\t\ttypeStr := strings.Split(shaderTypeLine, \" \")[1]\n\t\tswitch strings.ToLower(typeStr) {\n\t\tcase \"vertex\\n\":\n\t\t\tshaderType = gl.VERTEX_SHADER\n\t\tcase \"fragment\\n\":\n\t\t\tshaderType = gl.FRAGMENT_SHADER\n\t\tdefault:\n\t\t\terr = errors.New(\"Shader type \" + typeStr + \" not known.\")\n\t\t\treturn err\n\t\t}\n\n\t\tfor {\n\t\t\tline, err := reader.ReadString('\\n')\n\t\t\tif err == io.EOF {\n\t\t\t\teof = true\n\t\t\t\tbreak\n\t\t\t}\n\t\t\tif err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\n\t\t\t// start a new shader string with a new type if the line starts with \"#shader\"\n\t\t\tif strings.HasPrefix(line, \"#shader\") {\n\t\t\t\t// tell the next iteration the information on shader type we read\n\t\t\t\tshaderTypeLine = line\n\t\t\t\tbreak\n\t\t\t} else {\n\t\t\t\tshader += line\n\t\t\t}\n\t\t}\n\n\t\t// if the shader is not empty, compile it\n\t\tif len(shader) > 0 {\n\t\t\tshaderptr, err := s.compile(shader+\"\\x00\", shaderType)\n\t\t\tif err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\n\t\t\tshaders = append(shaders, shaderptr)\n\t\t} else {\n\t\t\tbreak\n\t\t}\n\n\t\tif eof {\n\t\t\tbreak\n\t\t}\n\t}\n\n\t// link shaders\n\ts.Program = gl.CreateProgram()\n\tfor _, shader := range shaders {\n\t\tgl.AttachShader(s.Program, shader)\n\t}\n\tgl.LinkProgram(s.Program)\n\n\t// delete the singke shaders. we won't need them anymore\n\tfor _, shader := range shaders {\n\t\tgl.DeleteShader(shader)\n\t}\n\n\treturn\n}", "func NewShader(vertexFmt, uniformFmt AttrFormat, vertexShader, fragmentShader string) (*Shader, error) {\n\tshader := &Shader{\n\t\tprogram: binder{\n\t\t\trestoreLoc: gl.CURRENT_PROGRAM,\n\t\t\tbindFunc: func(obj uint32) {\n\t\t\t\tgl.UseProgram(obj)\n\t\t\t},\n\t\t},\n\t\tvertexFmt: vertexFmt,\n\t\tuniformFmt: uniformFmt,\n\t\tuniformLoc: make([]int32, len(uniformFmt)),\n\t}\n\n\tvar vshader, fshader uint32\n\n\t// vertex shader\n\t{\n\t\tvshader = gl.CreateShader(gl.VERTEX_SHADER)\n\t\tsrc, free := gl.Strs(vertexShader)\n\t\tdefer free()\n\t\tlength := int32(len(vertexShader))\n\t\tgl.ShaderSource(vshader, 1, src, &length)\n\t\tgl.CompileShader(vshader)\n\n\t\tvar success int32\n\t\tgl.GetShaderiv(vshader, gl.COMPILE_STATUS, &success)\n\t\tif success == gl.FALSE {\n\t\t\tvar logLen int32\n\t\t\tgl.GetShaderiv(vshader, gl.INFO_LOG_LENGTH, &logLen)\n\n\t\t\tinfoLog := make([]byte, logLen)\n\t\t\tgl.GetShaderInfoLog(vshader, logLen, nil, &infoLog[0])\n\t\t\treturn nil, fmt.Errorf(\"error compiling vertex shader: %s\", string(infoLog))\n\t\t}\n\n\t\tdefer gl.DeleteShader(vshader)\n\t}\n\n\t// fragment shader\n\t{\n\t\tfshader = gl.CreateShader(gl.FRAGMENT_SHADER)\n\t\tsrc, free := gl.Strs(fragmentShader)\n\t\tdefer free()\n\t\tlength := int32(len(fragmentShader))\n\t\tgl.ShaderSource(fshader, 1, src, &length)\n\t\tgl.CompileShader(fshader)\n\n\t\tvar success int32\n\t\tgl.GetShaderiv(fshader, gl.COMPILE_STATUS, &success)\n\t\tif success == gl.FALSE {\n\t\t\tvar logLen int32\n\t\t\tgl.GetShaderiv(fshader, gl.INFO_LOG_LENGTH, &logLen)\n\n\t\t\tinfoLog := make([]byte, logLen)\n\t\t\tgl.GetShaderInfoLog(fshader, logLen, nil, &infoLog[0])\n\t\t\treturn nil, fmt.Errorf(\"error compiling fragment shader: %s\", string(infoLog))\n\t\t}\n\n\t\tdefer gl.DeleteShader(fshader)\n\t}\n\n\t// shader program\n\t{\n\t\tshader.program.obj = gl.CreateProgram()\n\t\tgl.AttachShader(shader.program.obj, vshader)\n\t\tgl.AttachShader(shader.program.obj, fshader)\n\t\tgl.LinkProgram(shader.program.obj)\n\n\t\tvar success int32\n\t\tgl.GetProgramiv(shader.program.obj, gl.LINK_STATUS, &success)\n\t\tif success == gl.FALSE {\n\t\t\tvar logLen int32\n\t\t\tgl.GetProgramiv(shader.program.obj, gl.INFO_LOG_LENGTH, &logLen)\n\n\t\t\tinfoLog := make([]byte, logLen)\n\t\t\tgl.GetProgramInfoLog(shader.program.obj, logLen, nil, &infoLog[0])\n\t\t\treturn nil, fmt.Errorf(\"error linking shader program: %s\", string(infoLog))\n\t\t}\n\t}\n\n\t// uniforms\n\tfor i, uniform := range uniformFmt {\n\t\tloc := gl.GetUniformLocation(shader.program.obj, gl.Str(uniform.Name+\"\\x00\"))\n\t\tshader.uniformLoc[i] = loc\n\t}\n\n\truntime.SetFinalizer(shader, (*Shader).delete)\n\n\treturn shader, nil\n}", "func ShaderBinary(count int32, shaders *uint32, binaryFormat uint32, binary unsafe.Pointer, length int32) {\n\tC.glowShaderBinary(gpShaderBinary, (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(shaders)), (C.GLenum)(binaryFormat), binary, (C.GLsizei)(length))\n}", "func ShaderBinary(count int32, shaders *uint32, binaryFormat uint32, binary unsafe.Pointer, length int32) {\n\tC.glowShaderBinary(gpShaderBinary, (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(shaders)), (C.GLenum)(binaryFormat), binary, (C.GLsizei)(length))\n}", "func ShaderBinary(count int32, shaders *uint32, binaryformat uint32, binary unsafe.Pointer, length int32) {\n\tsyscall.Syscall6(gpShaderBinary, 5, uintptr(count), uintptr(unsafe.Pointer(shaders)), uintptr(binaryformat), uintptr(binary), uintptr(length), 0)\n}", "func ShaderSource(shader uint32, count int32, xstring **int8, length *int32) {\n C.glowShaderSource(gpShaderSource, (C.GLuint)(shader), (C.GLsizei)(count), (**C.GLchar)(unsafe.Pointer(xstring)), (*C.GLint)(unsafe.Pointer(length)))\n}", "func GLShader(shaderType uint32, source string) (uint32, error) {\n\t// Create shader based on shaderType\n\tshader := gl.CreateShader(shaderType)\n\t// Compile the Shader with the source\n\tcsources, free := gl.Strs(source)\n\tgl.ShaderSource(shader, 1, csources, nil)\n\tfree()\n\tgl.CompileShader(shader)\n\n\tvar status int32\n\tgl.GetShaderiv(shader, gl.COMPILE_STATUS, &status)\n\tif status == gl.FALSE {\n\t\tvar logLen int32\n\t\tgl.GetShaderiv(shader, gl.INFO_LOG_LENGTH, &logLen)\n\t\tlog := strings.Repeat(\"\\x00\", int(logLen+1))\n\t\tgl.GetShaderInfoLog(shader, logLen, nil, gl.Str(log))\n\n\t\treturn 0, fmt.Errorf(\"Failed to compile %v: %v\", source, log)\n\t}\n\n\treturn shader, nil\n}", "func (shader Shader) Source(source string) {\n\tcstrs, free := gl.Strs(source + \"\\x00\")\n\tgl.ShaderSource(uint32(shader), 1, cstrs, nil)\n\tfree()\n}", "func ShaderBinary(count Sizei, shaders []Uint, binaryformat Enum, binary unsafe.Pointer, length Sizei) {\n\tccount, _ := (C.GLsizei)(count), cgoAllocsUnknown\n\tcshaders, _ := (*C.GLuint)(unsafe.Pointer((*sliceHeader)(unsafe.Pointer(&shaders)).Data)), cgoAllocsUnknown\n\tcbinaryformat, _ := (C.GLenum)(binaryformat), cgoAllocsUnknown\n\tcbinary, _ := (unsafe.Pointer)(unsafe.Pointer(binary)), cgoAllocsUnknown\n\tclength, _ := (C.GLsizei)(length), cgoAllocsUnknown\n\tC.glShaderBinary(ccount, cshaders, cbinaryformat, cbinary, clength)\n}", "func (gl *WebGL) CompileShader(shader WebGLShader) error {\n\tgl.context.Call(\"compileShader\", shader)\n\n\tif !gl.GetShaderParameter(shader, GlCompileStatus).Bool() {\n\t\terr := errors.New(gl.GetShaderInfoLog(shader))\n\t\tlog.Println(\"Failed to compile shader\", err)\n\t\treturn err\n\t}\n\n\treturn nil\n}", "func ShaderSource(shader uint32, count int32, xstring **uint8, length *int32) {\n\tsyscall.Syscall6(gpShaderSource, 4, uintptr(shader), uintptr(count), uintptr(unsafe.Pointer(xstring)), uintptr(unsafe.Pointer(length)), 0, 0)\n}", "func (p *Prog) BuildProgram() {\n\tvar (\n\t\tprogram gl.Program\n\t\tvshader gl.Shader\n\t\tfshader gl.Shader\n\t)\n\tprogram = gl.CreateProgram()\n\t//vertex shader\n\tvshader = gl.CreateShader(gl.VERTEX_SHADER)\n\tgl.ShaderSource(vshader, p.Vs)\n\tgl.CompileShader(vshader)\n\tif gl.GetShaderi(vshader, gl.COMPILE_STATUS) == gl.FALSE {\n\t\tlog.Printf(\"glprog: VS compilation failed: %v\", gl.GetShaderInfoLog(vshader))\n\t}\n\t//fragment shader\n\tfshader = gl.CreateShader(gl.FRAGMENT_SHADER)\n\tgl.ShaderSource(fshader, p.Fs)\n\tgl.CompileShader(fshader)\n\tif gl.GetShaderi(fshader, gl.COMPILE_STATUS) == gl.FALSE {\n\t\tlog.Printf(\"glprog: FS compilation failed: %v\", gl.GetShaderInfoLog(fshader))\n\t}\n\t//link program\n\tgl.AttachShader(program, vshader)\n\tgl.AttachShader(program, fshader)\n\tgl.LinkProgram(program)\n\tif gl.GetProgrami(program, gl.LINK_STATUS) == gl.FALSE {\n\t\tlog.Printf(\"glprog: LinkProgram failed: %v\", gl.GetProgramInfoLog(program))\n\t\tgl.DeleteProgram(program)\n\t}\n\t//mark shaders for deletion when program is unlinked\n\tgl.DeleteShader(vshader)\n\tgl.DeleteShader(fshader)\n\n\tp.P = program\n\tfor i := range p.Uniforms {\n\t\tp.Uniforms[i].Location = gl.GetUniformLocation(p.P, p.Uniforms[i].Name)\n\t}\n}", "func ReleaseShaderCompiler() {\n C.glowReleaseShaderCompiler(gpReleaseShaderCompiler)\n}", "func CompileNewShader(gl interfaces.OpenGL, shaderType uint32, source string) (shader uint32, err error) {\n\tshader = gl.CreateShader(shaderType)\n\n\tgl.ShaderSource(shader, source)\n\tgl.CompileShader(shader)\n\n\tcompileStatus := gl.GetShaderParameter(shader, oglconsts.COMPILE_STATUS)\n\tif compileStatus == 0 {\n\t\terr = fmt.Errorf(\"%s\", gl.GetShaderInfoLog(shader))\n\t\tgl.DeleteShader(shader)\n\t\tshader = 0\n\t}\n\n\treturn\n}", "func (gl *WebGL) ShaderSource(shader WebGLShader, source string) {\n\tgl.context.Call(\"shaderSource\", shader, source)\n}", "func CreateShader(ty Enum) Shader {\n\treturn Shader{Value: uint32(gl.CreateShader(uint32(ty)))}\n}", "func CompileNewShader(gl OpenGL, shaderType uint32, source string) (shader uint32, err error) {\n\tshader = gl.CreateShader(shaderType)\n\n\tgl.ShaderSource(shader, source)\n\tgl.CompileShader(shader)\n\n\tcompileStatus := gl.GetShaderParameter(shader, COMPILE_STATUS)\n\tif compileStatus == 0 {\n\t\terr = ShaderError{Log: gl.GetShaderInfoLog(shader)}\n\t\tgl.DeleteShader(shader)\n\t\tshader = 0\n\t}\n\n\treturn\n}", "func (debugging *debuggingOpenGL) ShaderSource(shader uint32, source string) {\n\tdebugging.recordEntry(\"ShaderSource\", shader, source)\n\tdebugging.gl.ShaderSource(shader, source)\n\tdebugging.recordExit(\"ShaderSource\")\n}", "func CreateShader(xtype uint32) uint32 {\n ret := C.glowCreateShader(gpCreateShader, (C.GLenum)(xtype))\n return (uint32)(ret)\n}", "func ShaderSource(s Shader, src string) {\n\tglsource, free := gl.Strs(src + \"\\x00\")\n\tgl.ShaderSource(s.Value, 1, glsource, nil)\n\tfree()\n}", "func CreateShader(xtype GLEnum) Shader {\n\treturn Shader(gl.CreateShader(uint32(xtype)))\n}", "func initOpenGL() uint32 {\n\tif err := gl.Init(); err != nil {\n\t\tpanic(err)\n\t}\n\tversion := gl.GoStr(gl.GetString(gl.VERSION))\n\tlog.Println(\"OpenGL version\", version)\n\n\tvar vertexShaderSource string\n\tvar fragmentShaderSource string\n\n\tvertexShaderSource = `\n\t#version 410\n\tlayout (location=0) in vec3 position;\n\tlayout (location=1) in vec2 texcoord;\n\tout vec2 tCoord;\n\tuniform mat4 projection;\n\tuniform mat4 world;\n\tuniform mat4 view;\n\tuniform vec2 texScale;\n\tuniform vec2 texOffset;\n\tvoid main() {\n\t\tgl_Position = projection * world * vec4(position, 1.0);\n\t\ttCoord = (texcoord+texOffset) * texScale;\n\t}\n\t` + \"\\x00\"\n\t//gl_Position = vec4(position, 10.0, 1.0) * camera * projection;\n\n\tfragmentShaderSource = `\n\t#version 410\n\tin vec2 tCoord;\n\tout vec4 frag_colour;\n\tuniform sampler2D ourTexture;\n\tuniform vec4 color;\n\tvoid main() {\n\t\t\tfrag_colour = texture(ourTexture, tCoord) * color;\n\t}\n\t` + \"\\x00\"\n\n\tprog := CreateProgram(vertexShaderSource, fragmentShaderSource)\n\n\tgl.UseProgram(prog)\n\tgl.Uniform2f(\n\t\tgl.GetUniformLocation(prog, gl.Str(\"texScale\\x00\")),\n\t\t1.0, 1.0,\n\t)\n\tgl.Uniform4f(\n\t\tgl.GetUniformLocation(prog, gl.Str(\"color\\x00\")),\n\t\t1, 1, 1, 1,\n\t)\n\n\t// line opengl program\n\tvertexShaderSource = `\n\t#version 330 core\n\tlayout (location = 0) in vec3 aPos;\n\tuniform mat4 uProjection;\n\tuniform mat4 uWorld;\n\n\tvoid main()\n\t{\n\t gl_Position = uProjection * vec4(aPos, 1.0);\n\t}` + \"\\x00\"\n\n\tfragmentShaderSource = `\n\t#version 330 core\n\tout vec4 FragColor;\n\tuniform vec3 uColor;\n\n\tvoid main()\n\t{\n\t FragColor = vec4(uColor, 1.0f);\n\t}` + \"\\x00\"\n\n\tlineProgram = CreateProgram(vertexShaderSource, fragmentShaderSource)\n\n\treturn prog\n}", "func ShaderSource(shader Uint, count Sizei, string []string, length []Int) {\n\tcshader, _ := (C.GLuint)(shader), cgoAllocsUnknown\n\tccount, _ := (C.GLsizei)(count), cgoAllocsUnknown\n\tcstring, _ := unpackArgSString(string)\n\tclength, _ := (*C.GLint)(unsafe.Pointer((*sliceHeader)(unsafe.Pointer(&length)).Data)), cgoAllocsUnknown\n\tC.glShaderSource(cshader, ccount, cstring, clength)\n\tpackSString(string, cstring)\n}", "func StringShader(content, contentType string) string {\n\tif content == \"\" {\n\t\treturn \"\"\n\t}\n\tif contentType == \"\" {\n\t\treturn content\n\t}\n\n\tvar shaderResult string\n\tvar offSet int\n\truneStr := []rune(content)\n\tswitch contentType {\n\tcase \"UserName\":\n\t\tshaderResult = fmt.Sprintf(\"%s**\", string(runeStr[:1]))\n\tcase \"BusinessCode\":\n\t\tshaderResult = fmt.Sprintf(\"%s*********\", string(runeStr[:6]))\n\tcase \"CreditCode\":\n\t\tshaderResult = fmt.Sprintf(\"%s**********\", string(runeStr[:8]))\n\tcase \"IdentityNo\":\n\t\tshaderResult = fmt.Sprintf(\"%s**********%s\", string(runeStr[:1]), string(runeStr[len(runeStr)-1:]))\n\tcase \"BankAccount\":\n\t\toffSet = MinInt(len(runeStr), 4)\n\t\tshaderResult = fmt.Sprintf(\"**************%s\", string(runeStr[len(runeStr)-offSet:]))\n\tcase \"AlipayAccount\":\n\t\tindexOfAt := strings.LastIndex(content, \"@\")\n\t\tif indexOfAt == -1 {\n\t\t\toffSet = MinInt(len(runeStr), 4)\n\t\t\tshaderResult = fmt.Sprintf(\"*******%s\", string(runeStr[len(runeStr)-offSet:]))\n\t\t} else {\n\t\t\toffSet = MinInt(indexOfAt, 2)\n\t\t\tshaderResult = fmt.Sprintf(\"*********%s\", string(runeStr[indexOfAt-offSet:]))\n\t\t}\n\t}\n\n\treturn shaderResult\n}", "func ShaderSource(shader uint32, count int32, xstring **uint8, length *int32) {\n\tC.glowShaderSource(gpShaderSource, (C.GLuint)(shader), (C.GLsizei)(count), (**C.GLchar)(unsafe.Pointer(xstring)), (*C.GLint)(unsafe.Pointer(length)))\n}", "func ShaderSource(shader uint32, count int32, xstring **uint8, length *int32) {\n\tC.glowShaderSource(gpShaderSource, (C.GLuint)(shader), (C.GLsizei)(count), (**C.GLchar)(unsafe.Pointer(xstring)), (*C.GLint)(unsafe.Pointer(length)))\n}", "func (native *OpenGL) ShaderSource(shader uint32, source string) {\n\tcsources, free := gl.Strs(source + \"\\x00\")\n\tdefer free()\n\n\tgl.ShaderSource(shader, 1, csources, nil)\n}", "func CreateShaderProgramv(xtype uint32, count int32, strings **int8) uint32 {\n ret := C.glowCreateShaderProgramv(gpCreateShaderProgramv, (C.GLenum)(xtype), (C.GLsizei)(count), (**C.GLchar)(unsafe.Pointer(strings)))\n return (uint32)(ret)\n}", "func ShaderProgramFill(r, g, b, a byte) *shaderir.Program {\n\tir, err := graphics.CompileShader([]byte(fmt.Sprintf(`//kage:unit pixels\n\npackage main\n\nfunc Fragment(position vec4, texCoord vec2, color vec4) vec4 {\n\treturn vec4(%0.9f, %0.9f, %0.9f, %0.9f)\n}\n`, float64(r)/0xff, float64(g)/0xff, float64(b)/0xff, float64(a)/0xff)))\n\tif err != nil {\n\t\tpanic(err)\n\t}\n\treturn ir\n}", "func (sh *ShaderStd) PostRender() error { return nil }", "func AttachShader(program uint32, shader uint32) {\n C.glowAttachShader(gpAttachShader, (C.GLuint)(program), (C.GLuint)(shader))\n}", "func CreateProgram(vertexSource string, fragmentSource string) (gl.Uint, error) {\n\t// Vertex shader\n\tvs := gl.CreateShader(gl.VERTEX_SHADER)\n\tvsSource := gl.GLStringArray(vertexSource)\n\tdefer gl.GLStringArrayFree(vsSource)\n\tgl.ShaderSource(vs, 1, &vsSource[0], nil)\n\n\tgl.CompileShader(vs)\n\n\tstatus, err := compileStatus(vs)\n\tif err != nil {\n\t\treturn status, err\n\t}\n\n\t// Fragment shader\n\tfs := gl.CreateShader(gl.FRAGMENT_SHADER)\n\tfsSource := gl.GLStringArray(fragmentSource)\n\tdefer gl.GLStringArrayFree(fsSource)\n\tgl.ShaderSource(fs, 1, &fsSource[0], nil)\n\tgl.CompileShader(fs)\n\n\tstatus, err = compileStatus(fs)\n\tif err != nil {\n\t\treturn status, err\n\t}\n\n\t// create program\n\tprogram := gl.CreateProgram()\n\tgl.AttachShader(program, vs)\n\tgl.AttachShader(program, fs)\n\n\tgl.LinkProgram(program)\n\tvar linkstatus gl.Int\n\tgl.GetProgramiv(program, gl.LINK_STATUS, &linkstatus)\n\tif linkstatus == gl.FALSE {\n\t\treturn gl.FALSE, errors.New(\"Program link failed\")\n\t}\n\n\treturn program, nil\n}", "func (s *Shader) Use() {\n\tgl.UseProgram(s.programID)\n}", "func (native *OpenGL) GLShaderSource(shader uint32, count int32, xstring **uint8, length *int32) {\n\tgl.ShaderSource(shader, count, xstring, length)\n}", "func (gl *WebGL) NewShader(shaderType GLEnum, sourceCode string) (WebGLShader, error) {\n\tshader := gl.CreateShader(shaderType)\n\tgl.ShaderSource(shader, sourceCode)\n\terr := gl.CompileShader(shader)\n\treturn shader, err\n}", "func MakeShader() *Shader {\n\treturn &Shader{\n\t\tuniforms: make(map[string]*Uniform),\n\t}\n}", "func CreateShader(xtype uint32) uint32 {\n\tret, _, _ := syscall.Syscall(gpCreateShader, 1, uintptr(xtype), 0, 0)\n\treturn (uint32)(ret)\n}", "func CreateShader(kind Enum) Uint {\n\tckind, _ := (C.GLenum)(kind), cgoAllocsUnknown\n\t__ret := C.glCreateShader(ckind)\n\t__v := (Uint)(__ret)\n\treturn __v\n}", "func initOpenGL() uint32 {\n\tif err := gl.Init(); err != nil {\n\t\tpanic(err)\n\t}\n\tversion := gl.GoStr(gl.GetString(gl.VERSION))\n\tlog.Println(\"OpenGL version\", version)\n\n\tvertexShaderSource, err := files.ReadTextFile(vertexShaderFile)\n\tmust(err)\n\n\tvertexShaderSource += \"\\x00\"\n\n\tfragmentShaderSource, err := files.ReadTextFile(fragmentShaderFile)\n\tmust(err)\n\n\tfragmentShaderSource += \"\\x00\"\n\n\tvertexShader, err := compileShader(vertexShaderSource, gl.VERTEX_SHADER)\n\tmust(err)\n\n\tfragmentShader, err := compileShader(fragmentShaderSource, gl.FRAGMENT_SHADER)\n\tmust(err)\n\n\tprogram := gl.CreateProgram()\n\tgl.AttachShader(program, vertexShader)\n\tgl.AttachShader(program, fragmentShader)\n\tgl.LinkProgram(program)\n\n\tvar status int32\n\tgl.GetProgramiv(program, gl.LINK_STATUS, &status)\n\tif status == gl.FALSE {\n\t\tvar logLength int32\n\t\tgl.GetProgramiv(program, gl.INFO_LOG_LENGTH, &logLength)\n\n\t\tlog := strings.Repeat(\"\\x00\", int(logLength+1))\n\t\tgl.GetProgramInfoLog(program, logLength, nil, gl.Str(log))\n\n\t\terr := fmt.Errorf(\"failed to link program: %v\", log)\n\t\tpanic(err)\n\t}\n\n\tgl.DeleteShader(vertexShader)\n\tgl.DeleteShader(fragmentShader)\n\n\treturn program\n}", "func (debugging *debuggingOpenGL) CreateShader(shaderType uint32) uint32 {\n\tdebugging.recordEntry(\"CreateShader\", shaderType)\n\tresult := debugging.gl.CreateShader(shaderType)\n\tdebugging.recordExit(\"CreateShader\", result)\n\treturn result\n}", "func ReleaseShaderCompiler() {\n\tC.glReleaseShaderCompiler()\n}", "func compileStatus(shader gl.Uint) (gl.Uint, error) {\n\tvar status gl.Int\n\tgl.GetShaderiv(shader, gl.COMPILE_STATUS, &status)\n\tif status == gl.FALSE {\n\t\tvar logLength gl.Int\n\t\tgl.GetShaderiv(shader, gl.INFO_LOG_LENGTH, &logLength)\n\n\t\tlog := strings.Repeat(\"\\x00\", int(logLength+1))\n\t\tchary := gl.GLStringArray(log)\n\t\tdefer gl.GLStringArrayFree(chary)\n\t\tgl.GetShaderInfoLog(shader, gl.Sizei(logLength), nil, chary[0])\n\t\tlogOut := gl.GoString(chary[0])\n\n\t\treturn gl.FALSE, fmt.Errorf(\"failed to compile %v\", logOut)\n\t}\n\n\treturn gl.TRUE, nil\n}", "func CreateShader(xtype uint32) uint32 {\n\tret := C.glowCreateShader(gpCreateShader, (C.GLenum)(xtype))\n\treturn (uint32)(ret)\n}", "func CreateShader(xtype uint32) uint32 {\n\tret := C.glowCreateShader(gpCreateShader, (C.GLenum)(xtype))\n\treturn (uint32)(ret)\n}", "func (s *s2d) Pre() error {\n\treturn Exec(func() error {\n\t\tflush_errors(\"pre: start\")\n\t\ts.vao = gl.GenVertexArray()\n\t\ts.vao.Bind()\n\n\t\ts.vertvbo = gl.GenBuffer()\n\t\ts.vertvbo.Bind(gl.ARRAY_BUFFER)\n\t\ts.quad = []float32{\n\t\t\t0.9, 0.9,\n\t\t\t0.9, -0.9,\n\t\t\t-0.9, -0.9,\n\t\t\t-0.9, 0.9,\n\t\t}\n\t\t// unsafe.Sizeof(quad) seems to think quad is 24 bytes, which is absurd.\n\t\t// so we just calculate the size manually.\n\t\tgl.BufferData(gl.ARRAY_BUFFER, len(s.quad)*4, s.quad, gl.STATIC_DRAW)\n\n\t\tflush_errors(\"creating program\")\n\t\ts.program = s2dprogram()\n\t\tflush_errors(\"program created, gen'ing texturing\")\n\n\t\ts.texture = gl.GenTexture()\n\t\tgl.ActiveTexture(gl.TEXTURE0)\n\t\ts.texture.Bind(gl.TEXTURE_2D)\n\n\t\tgl.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.LINEAR)\n\t\tgl.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, gl.LINEAR)\n\t\t// never ever use anything but clamp to edge; others do not make any sense.\n\t\tgl.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_R, gl.CLAMP_TO_EDGE)\n\t\tgl.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_S, gl.CLAMP_TO_EDGE)\n\t\tgl.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_T, gl.CLAMP_TO_EDGE)\n\t\ttxs2d := s.program.GetUniformLocation(tex2dname)\n\t\ttxs2d.Uniform1i(0)\n\t\tflush_errors(\"setting '\" + tex2dname + \"' uniform.\")\n\n\t\ts.fldmaxloc = s.program.GetUniformLocation(\"fieldmax\")\n\t\tgfx.Trace(\"field max loc is: %v\\n\", s.fldmaxloc)\n\t\treturn nil\n\t})\n}", "func newModel(src []byte) (*IRMF, error) {\n\tif bytes.Index(src, []byte(\"/*{\")) != 0 {\n\t\treturn nil, errors.New(`Unable to find leading \"/*{\"`)\n\t}\n\tendJSON := bytes.Index(src, []byte(\"\\n}*/\\n\"))\n\tif endJSON < 0 {\n\t\treturn nil, errors.New(`Unable to find trailing \"}*/\"`)\n\t}\n\n\tjsonBlobStr := string(src[2 : endJSON+2])\n\tjsonBlob, err := parseJSON(jsonBlobStr)\n\tif err != nil {\n\t\treturn nil, fmt.Errorf(\"unable to parse JSON blob: %v\", err)\n\t}\n\n\tshaderSrcBuf := src[endJSON+5:]\n\tunzip := func(data []byte) error {\n\t\tzr, err := gzip.NewReader(bytes.NewReader(data))\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tbuf := &bytes.Buffer{}\n\t\tif _, err := io.Copy(buf, zr); err != nil {\n\t\t\treturn err\n\t\t}\n\t\tif err := zr.Close(); err != nil {\n\t\t\treturn err\n\t\t}\n\t\tjsonBlob.Shader = buf.String()\n\t\treturn nil\n\t}\n\n\tif jsonBlob.Encoding != nil && *jsonBlob.Encoding == \"gzip+base64\" {\n\t\tdata, err := base64.RawStdEncoding.DecodeString(string(shaderSrcBuf))\n\t\tif err != nil {\n\t\t\treturn nil, fmt.Errorf(\"uudecode error: %v\", err)\n\t\t}\n\t\tif err := unzip(data); err != nil {\n\t\t\treturn nil, fmt.Errorf(\"unzip: %v\", err)\n\t\t}\n\t\tjsonBlob.Encoding = nil\n\t} else if jsonBlob.Encoding != nil && *jsonBlob.Encoding == \"gzip\" {\n\t\tif err := unzip(shaderSrcBuf); err != nil {\n\t\t\treturn nil, fmt.Errorf(\"unzip: %v\", err)\n\t\t}\n\t\tjsonBlob.Encoding = nil\n\t} else {\n\t\tjsonBlob.Shader = string(shaderSrcBuf)\n\t}\n\n\tjsonBlob.Shader = processIncludes(jsonBlob.Shader)\n\n\tif lineNum, err := jsonBlob.validate(jsonBlobStr, jsonBlob.Shader); err != nil {\n\t\treturn nil, fmt.Errorf(\"invalid JSON blob on line %v: %v\", lineNum, err)\n\t}\n\n\treturn jsonBlob, nil\n}", "func CreateShaderProgramv(xtype uint32, count int32, strings **uint8) uint32 {\n\tret := C.glowCreateShaderProgramv(gpCreateShaderProgramv, (C.GLenum)(xtype), (C.GLsizei)(count), (**C.GLchar)(unsafe.Pointer(strings)))\n\treturn (uint32)(ret)\n}", "func CreateShaderProgramv(xtype uint32, count int32, strings **uint8) uint32 {\n\tret := C.glowCreateShaderProgramv(gpCreateShaderProgramv, (C.GLenum)(xtype), (C.GLsizei)(count), (**C.GLchar)(unsafe.Pointer(strings)))\n\treturn (uint32)(ret)\n}", "func ReleaseShaderCompiler() {\n\tC.glowReleaseShaderCompiler(gpReleaseShaderCompiler)\n}", "func ReleaseShaderCompiler() {\n\tC.glowReleaseShaderCompiler(gpReleaseShaderCompiler)\n}", "func (shader Shader) Delete() {\n\tgl.DeleteShader(uint32(shader))\n}", "func ActiveShaderProgram(pipeline uint32, program uint32) {\n C.glowActiveShaderProgram(gpActiveShaderProgram, (C.GLuint)(pipeline), (C.GLuint)(program))\n}", "func ReleaseShaderCompiler() {\n\tgl.ReleaseShaderCompiler()\n}", "func (self *TileSprite) Shader() *AbstractFilter{\n return &AbstractFilter{self.Object.Get(\"shader\")}\n}", "func finalizeShader(n *nativeShader) {\n\tn.r.Lock()\n\n\t// If the shader program is zero, it has already been free'd.\n\tif n.program == 0 {\n\t\tn.r.Unlock()\n\t\treturn\n\t}\n\tn.r.shaders = append(n.r.shaders, n)\n\tn.r.Unlock()\n}", "func LoadShaderFromFile(path string) (string, error) {\n\tshaderCode, err := ioutil.ReadFile(path)\n\tif err != nil {\n\t\treturn \"\", err\n\t}\n\tresult := string(shaderCode) + \"\\x00\"\n\treturn result, nil\n}", "func ShaderProgramImages(numImages int) *shaderir.Program {\n\tif numImages <= 0 {\n\t\tpanic(\"testing: numImages must be >= 1\")\n\t}\n\n\tvar exprs []string\n\tfor i := 0; i < numImages; i++ {\n\t\texprs = append(exprs, fmt.Sprintf(\"imageSrc%dUnsafeAt(texCoord)\", i))\n\t}\n\n\tir, err := graphics.CompileShader([]byte(fmt.Sprintf(`//kage:unit pixels\n\npackage main\n\nfunc Fragment(position vec4, texCoord vec2, color vec4) vec4 {\n\treturn %s\n}\n`, strings.Join(exprs, \" + \"))))\n\tif err != nil {\n\t\tpanic(err)\n\t}\n\treturn ir\n}", "func AttachShader(p Program, s Shader) {\n\tgl.AttachShader(p.Value, s.Value)\n}", "func (gl *WebGL) CreateShader(shaderType GLEnum) WebGLShader {\n\treturn gl.context.Call(\"createShader\", shaderType)\n}", "func (gui *GUI) createProgram() (uint32, error) {\n\tif err := gl.Init(); err != nil {\n\t\treturn 0, fmt.Errorf(\"Failed to initialise OpenGL: %s\", err)\n\t}\n\tgui.logger.Infof(\"OpenGL version %s\", gl.GoStr(gl.GetString(gl.VERSION)))\n\n\tgui.logger.Debugf(\"Compiling shaders...\")\n\n\tvertexShader, err := compileShader(vertexShaderSource, gl.VERTEX_SHADER)\n\tif err != nil {\n\t\treturn 0, err\n\t}\n\n\tfragmentShader, err := compileShader(fragmentShaderSource, gl.FRAGMENT_SHADER)\n\tif err != nil {\n\t\treturn 0, err\n\t}\n\n\tprog := gl.CreateProgram()\n\tgl.AttachShader(prog, vertexShader)\n\tgl.AttachShader(prog, fragmentShader)\n\tgl.LinkProgram(prog)\n\n\treturn prog, nil\n}", "func Compile(state *lua.LState, moonscriptCode string) (string, error) {\n\tmoonbundle, err := Asset(\"moon-bundle.lua\")\n\tif err != nil {\n\t\treturn \"\", err\n\t}\n\n\tstate.SetGlobal(\"_moonbundle_code\", lua.LString(moonbundle))\n\tstate.SetGlobal(\"__moonscript_code\", lua.LString(moonscriptCode))\n\n\terr = state.DoString(`\n package.loaded.moonscript = loadstring(_moonbundle_code)()\n\n local moonparse = require(\"moonscript.parse\")\n local mooncompile = require(\"moonscript.compile\")\n\n local tree, err = moonparse.string(__moonscript_code)\n if not tree then\n print(\"gmoonscript error: unable to parse moonscript, check formatting!\")\n else\n __output_lua_code_, err = mooncompile.tree(tree)\n end\n\n -- remove all created modules and vars\n package.loaded.moonscript = nil\n moonparse = nil\n mooncompile = nil\n\n _moonbundle_code = nil\n __moonscript_code = nil\n collectgarbage()\n `)\n\tif err != nil {\n\t\treturn \"\", err\n\t}\n\n\tluaOutput := state.GetGlobal(\"__output_lua_code_\")\n\tstate.SetGlobal(\"__output_lua_code\", lua.LNil)\n\n\treturn luaOutput.String(), nil\n}", "func DeleteShader(shader uint32) {\n C.glowDeleteShader(gpDeleteShader, (C.GLuint)(shader))\n}", "func ReleaseShaderCompiler() {\n\tsyscall.Syscall(gpReleaseShaderCompiler, 0, 0, 0, 0)\n}", "func (self *TileSprite) SetShaderA(member *AbstractFilter) {\n self.Object.Set(\"shader\", member)\n}", "func (spirv *SPIRVCross) Convert(path, variant string, shader []byte, target, version string) (string, error) {\n\tbase := spirv.WorkDir.Path(filepath.Base(path), variant)\n\n\tif err := spirv.WorkDir.WriteFile(base, shader); err != nil {\n\t\treturn \"\", fmt.Errorf(\"unable to write shader to disk: %w\", err)\n\t}\n\n\tvar cmd *exec.Cmd\n\tswitch target {\n\tcase \"glsl\":\n\t\tcmd = exec.Command(spirv.Bin,\n\t\t\t\"--no-es\",\n\t\t\t\"--version\", version,\n\t\t)\n\tcase \"es\":\n\t\tcmd = exec.Command(spirv.Bin,\n\t\t\t\"--es\",\n\t\t\t\"--version\", version,\n\t\t)\n\tcase \"hlsl\":\n\t\tcmd = exec.Command(spirv.Bin,\n\t\t\t\"--hlsl\",\n\t\t\t\"--shader-model\", version,\n\t\t)\n\tdefault:\n\t\treturn \"\", fmt.Errorf(\"unknown target %q\", target)\n\t}\n\tcmd.Args = append(cmd.Args, \"--no-420pack-extension\", base)\n\n\tout, err := cmd.CombinedOutput()\n\tif err != nil {\n\t\treturn \"\", fmt.Errorf(\"%s\\nfailed to run %v: %w\", out, cmd.Args, err)\n\t}\n\ts := string(out)\n\tif target != \"hlsl\" {\n\t\t// Strip Windows \\r in line endings.\n\t\ts = unixLineEnding(s)\n\t}\n\n\treturn s, nil\n}", "func GetShaderSource(shader uint32, bufSize int32, length *int32, source *int8) {\n C.glowGetShaderSource(gpGetShaderSource, (C.GLuint)(shader), (C.GLsizei)(bufSize), (*C.GLsizei)(unsafe.Pointer(length)), (*C.GLchar)(unsafe.Pointer(source)))\n}", "func ProgramUniformMatrix4x2fv(program uint32, location int32, count int32, transpose bool, value *float32) {\n C.glowProgramUniformMatrix4x2fv(gpProgramUniformMatrix4x2fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (C.GLboolean)(boolToInt(transpose)), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func compile(dest string, src string, vars []string) error {\n\targs := []string{\n\t\t\"build\",\n\t\t\"-o\", dest,\n\t}\n\n\tif len(vars) > 0 {\n\t\targs = append(args, \"-ldflags\")\n\n\t\tfor idx, val := range vars {\n\t\t\tvars[idx] = \"-X \" + val\n\t\t}\n\n\t\tif Debug {\n\t\t\tvars = append(vars, \"-X main.debug=true\")\n\t\t}\n\n\t\targs = append(args, strings.Join(vars, \" \"))\n\t}\n\n\tt := time.Now()\n\n\toutput, err := exec.Command(\"go\", append(args, src)...).CombinedOutput()\n\tif err != nil {\n\t\treturn fmt.Errorf(\"Compile of %s failed: %s\", src, output)\n\t}\n\n\tdebugf(\"Compile %#v finished in %s\", args, time.Now().Sub(t))\n\treturn nil\n}", "func ProgramUniformMatrix4x3fv(program uint32, location int32, count int32, transpose bool, value *float32) {\n C.glowProgramUniformMatrix4x3fv(gpProgramUniformMatrix4x3fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (C.GLboolean)(boolToInt(transpose)), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func CreateShaderProgramv(xtype uint32, count int32, strings **uint8) uint32 {\n\tret, _, _ := syscall.Syscall(gpCreateShaderProgramv, 3, uintptr(xtype), uintptr(count), uintptr(unsafe.Pointer(strings)))\n\treturn (uint32)(ret)\n}", "func (am *Manager) LoadShader(typ uint32, name string) (uint32, error) {\n\tif shader, ok := am.GetShader(name); ok {\n\t\treturn shader, nil\n\t}\n\n\tLogger.Printf(\"asset.Manager.LoadShader: loading Shader '%s'\\n\", name)\n\n\tvar shader, err = newShader(\"assets/shaders/\"+name, typ)\n\tif err != nil {\n\t\tLogger.Print(\"asset.Manager.LoadShader: failed\")\n\t\treturn 0, err\n\t}\n\n\tLogger.Print(\"asset.Manager.LoadShader: shader loaded\")\n\n\tam.AddShader(name, shader)\n\n\treturn shader, nil\n}", "func GetShaderiv(shader uint32, pname uint32, params *int32) {\n C.glowGetShaderiv(gpGetShaderiv, (C.GLuint)(shader), (C.GLenum)(pname), (*C.GLint)(unsafe.Pointer(params)))\n}", "func IsShader(shader uint32) bool {\n ret := C.glowIsShader(gpIsShader, (C.GLuint)(shader))\n return ret == TRUE\n}", "func (am *Manager) LoadProgram(vfile, ffile, gfile string) (uint32, error) {\n\tvar (\n\t\tset ShaderSet\n\t\terr error\n\t)\n\n\tif set.Vs, err = am.LoadShader(gl.VERTEX_SHADER, vfile); err != nil {\n\t\treturn 0, err\n\t}\n\tif set.Fs, err = am.LoadShader(gl.FRAGMENT_SHADER, ffile); err != nil {\n\t\treturn 0, err\n\t}\n\tif len(gfile) > 0 {\n\t\tif set.Gs, err = am.LoadShader(gl.GEOMETRY_SHADER, gfile); err != nil {\n\t\t\treturn 0, err\n\t\t}\n\t}\n\n\tif prog, ok := am.GetProgram(set); ok {\n\t\treturn prog, nil\n\t}\n\n\tLogger.Printf(\"Manager: loading Program '%v'\\n\", set)\n\n\tvar prog = gl.CreateProgram()\n\tgl.AttachShader(prog, set.Vs)\n\tgl.AttachShader(prog, set.Fs)\n\tif set.Gs > 0 {\n\t\tgl.AttachShader(prog, set.Gs)\n\t}\n\tgl.LinkProgram(prog)\n\n\tvar infoLogLen int32\n\tgl.GetProgramiv(prog, gl.INFO_LOG_LENGTH, &infoLogLen)\n\n\tif infoLogLen > 1 {\n\t\tvar log = make([]uint8, infoLogLen)\n\t\tgl.GetProgramInfoLog(prog, infoLogLen, nil, &log[0])\n\t\treturn 0, errors.New(string(log))\n\t}\n\n\tam.AddProgram(set, prog)\n\n\treturn prog, nil\n}", "func ProgramUniformMatrix3x4fv(program uint32, location int32, count int32, transpose bool, value *float32) {\n C.glowProgramUniformMatrix3x4fv(gpProgramUniformMatrix3x4fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (C.GLboolean)(boolToInt(transpose)), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniformMatrix2x4fv(program uint32, location int32, count int32, transpose bool, value *float32) {\n C.glowProgramUniformMatrix2x4fv(gpProgramUniformMatrix2x4fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (C.GLboolean)(boolToInt(transpose)), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func ProgramUniform4f(program uint32, location int32, v0 float32, v1 float32, v2 float32, v3 float32) {\n C.glowProgramUniform4f(gpProgramUniform4f, (C.GLuint)(program), (C.GLint)(location), (C.GLfloat)(v0), (C.GLfloat)(v1), (C.GLfloat)(v2), (C.GLfloat)(v3))\n}", "func (s *Shader) Begin() {\n\ts.program.bind()\n}", "func (native *OpenGL) CreateShader(shaderType uint32) uint32 {\n\treturn gl.CreateShader(shaderType)\n}", "func (c *Context) BindShader(shader *ShaderProgram) {\n\tif c.currentShaderProgram == nil || shader.id != c.currentShaderProgram.id {\n\t\tgl.UseProgram(shader.id)\n\t\tc.currentShaderProgram = shader\n\t}\n}", "func ProgramUniformMatrix3x2fv(program uint32, location int32, count int32, transpose bool, value *float32) {\n C.glowProgramUniformMatrix3x2fv(gpProgramUniformMatrix3x2fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (C.GLboolean)(boolToInt(transpose)), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func (program Program) AttachShader(shader Shader) {\n\tgl.AttachShader(uint32(program), uint32(shader))\n}", "func AttachShader(program uint32, shader uint32) {\n\tsyscall.Syscall(gpAttachShader, 2, uintptr(program), uintptr(shader), 0)\n}", "func ProgramUniformMatrix2x3fv(program uint32, location int32, count int32, transpose bool, value *float32) {\n C.glowProgramUniformMatrix2x3fv(gpProgramUniformMatrix2x3fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (C.GLboolean)(boolToInt(transpose)), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func DeleteShader(s Shader) {\n\tgl.DeleteShader(s.Value)\n}", "func (sh *ShaderStd) Eval(sg *core.ShaderContext) {\n\n\t//fmt.Printf(\"%v %v %v %v\\n\", sg.DdDdx, sg.DdNdx, sg.DdDdy, sg.DdNdy)\n\t/*\tdeltaTx := m.Vec2Scale(sg.Image.PixelDelta[0], sg.Dduvdx)\n\t\tdeltaTy := m.Vec2Scale(sg.Image.PixelDelta[1], sg.Dduvdy)\n\n\t\tlod := m.Log2(m.Max(m.Vec2Length(deltaTx), m.Vec2Length(deltaTy)))\n\t\t//return\n\t\tfmt.Printf(\"lod: %v\\n\", lod)\n\n\t\tif lod >= 0 {\n\t\t\tsg.OutRGB[0] = m.Floor(lod) * 10\n\t\t} else {\n\t\t\tsg.OutRGB[0] = 100\n\t\t\tsg.OutRGB[1] = 100\n\t\t}\n\t\treturn\n\t*/\n\tif sg.Level > 3 {\n\t\treturn\n\t}\n\n\t// Construct a tangent space\n\tV := m.Vec3Cross(sg.N, sg.DdPdu)\n\n\tif m.Vec3Length2(V) < 0.1 {\n\t\tV = m.Vec3Cross(sg.N, sg.DdPdv)\n\t}\n\tV = m.Vec3Normalize(V)\n\tU := m.Vec3Normalize(m.Vec3Cross(sg.N, V))\n\n\tdiffRoughness := float32(0.5)\n\n\tif sh.DiffuseRoughness != nil {\n\t\tdiffRoughness = sh.DiffuseRoughness.Float32(sg)\n\t}\n\n\tvar _ = diffRoughness\n\tdiffBrdf := bsdf.NewOrenNayar(sg.Lambda, m.Vec3Neg(sg.Rd), diffRoughness, U, V, sg.N)\n\t//diffBrdf := bsdf.NewLambert(sg.Lambda, m.Vec3Neg(sg.Rd), U, V, sg.N)\n\n\tvar diffContrib colour.RGB\n\n\tvar diffColour colour.RGB\n\n\tif sh.DiffuseColour != nil {\n\t\tdiffColour = sh.DiffuseColour.RGB(sg)\n\t}\n\n\tdiffWeight := float32(0)\n\tspec1Weight := float32(0)\n\n\tif sh.DiffuseStrength != nil {\n\t\tdiffWeight = sh.DiffuseStrength.Float32(sg)\n\t}\n\n\tif sh.Spec1Strength != nil {\n\t\tspec1Weight = sh.Spec1Strength.Float32(sg)\n\t}\n\n\ttotalWeight := diffWeight + spec1Weight\n\tdiffWeight /= totalWeight\n\tspec1Weight /= totalWeight\n\n\tif totalWeight == 0.0 {\n\t\tpanic(fmt.Sprintf(\"Shader %v has no weight\", sh.Name()))\n\t}\n\n\tif diffWeight > 0.0 {\n\n\t\tsg.LightsPrepare()\n\n\t\tfor sg.NextLight() {\n\n\t\t\tif sg.Lp.DiffuseShadeMult() > 0.0 {\n\n\t\t\t\t// In this example the brdf passed is an interface\n\t\t\t\t// allowing sampling, pdf and bsdf eval\n\t\t\t\tcol := sg.EvaluateLightSamples(diffBrdf)\n\t\t\t\tcol.Mul(diffColour)\n\t\t\t\tdiffContrib.Add(col)\n\t\t\t}\n\n\t\t}\n\n\t\tdiffContrib.Scale(diffWeight)\n\t}\n\n\tior := float32(1.7)\n\n\tif sh.IOR != nil {\n\t\tior = sh.IOR.Float32(sg)\n\t}\n\n\tvar fresnel core.Fresnel\n\n\tswitch sh.spec1FresnelModel {\n\tcase fr.DielectricModel:\n\t\tfresnel = fr.NewDielectric(ior)\n\tcase fr.ConductorModel:\n\n\t\trefl := colour.RGB{0.5, 0.5, 0.5}\n\t\tedge := colour.RGB{0.5, 0.5, 0.5}\n\n\t\tif sh.Spec1FresnelRefl != nil {\n\t\t\trefl = sh.Spec1FresnelRefl.RGB(sg)\n\t\t}\n\n\t\tif sh.Spec1FresnelEdge != nil {\n\t\t\trefl = sh.Spec1FresnelEdge.RGB(sg)\n\t\t}\n\n\t\tfresnel = fr.NewConductor(0, refl, edge)\n\t}\n\n\tvar spec1Contrib colour.RGB\n\n\tif spec1Weight > 0.0 {\n\t\tspec1Roughness := float32(0.5)\n\n\t\tif sh.Spec1Roughness != nil {\n\t\t\tspec1Roughness = sh.Spec1Roughness.Float32(sg)\n\t\t}\n\n\t\tvar spec1Colour colour.RGB\n\n\t\tif sh.Spec1Colour != nil {\n\t\t\tspec1Colour = sh.Spec1Colour.RGB(sg)\n\t\t}\n\n\t\tvar spec1BRDF core.BSDF\n\n\t\tif spec1Roughness == 0.0 {\n\t\t\tspec1BRDF = bsdf.NewSpecular(sg, m.Vec3Neg(sg.Rd), fresnel, U, V, sg.N)\n\t\t} else {\n\t\t\tspec1BRDF = bsdf.NewMicrofacetGGX(sg, m.Vec3Neg(sg.Rd), fresnel, spec1Roughness, U, V, sg.N)\n\t\t}\n\n\t\t//\tKr := fresnel.Kr(m.Vec3DotAbs(sg.N, m.Vec3Neg(sg.Rd)))\n\t\tvar samp core.TraceSample\n\t\tray := sg.NewRay()\n\n\t\tspec1Samples := 0\n\n\t\tif spec1Roughness == 0.0 {\n\t\t\tspec1Samples = 1\n\t\t}\n\n\t\tfor i := 0; i < spec1Samples; i++ {\n\t\t\tidx := uint64(sg.I*spec1Samples /*+ sg.Sample*/ + i)\n\t\t\tr0 := ldseq.VanDerCorput(idx, sg.Scramble[0])\n\t\t\tr1 := ldseq.Sobol(idx, sg.Scramble[1])\n\n\t\t\tspec1OmegaO := spec1BRDF.Sample(r0, r1)\n\t\t\tpdf := spec1BRDF.PDF(spec1OmegaO)\n\n\t\t\tif m.Vec3Dot(spec1OmegaO, sg.Ng) <= 0.0 {\n\t\t\t\tcontinue\n\n\t\t\t}\n\t\t\t//fmt.Printf(\"%v %v\\n\", spec1Omega, m.Vec3Length(spec1Omega))\n\n\t\t\tray.Init(core.RayTypeReflected, sg.OffsetP(1), spec1OmegaO, m.Inf(1), sg.Level+1, sg)\n\n\t\t\tif core.Trace(ray, &samp) {\n\n\t\t\t\trho := spec1BRDF.Eval(spec1OmegaO)\n\n\t\t\t\trho.Scale(1.0 / float32(pdf))\n\n\t\t\t\tcol := rho.ToRGB()\n\n\t\t\t\t//fmt.Printf(\"%v %v\\n\", col, samp.Colour)\n\t\t\t\tcol.Mul(spec1Colour)\n\t\t\t\tcol.Mul(samp.Colour)\n\n\t\t\t\tfor k := range col {\n\t\t\t\t\tif col[k] < 0 || math.IsNaN(float64(col[k])) {\n\t\t\t\t\t\tcol[k] = 0\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tspec1Contrib.Add(col)\n\t\t\t}\n\n\t\t}\n\n\t\tsg.ReleaseRay(ray)\n\n\t\tif spec1Samples > 0 {\n\t\t\tspec1Contrib.Scale(spec1Weight / float32(spec1Samples))\n\t\t}\n\n\t\tif spec1Roughness > 0.0 { // No point doing direct lighting for mirror surfaces!\n\t\t\tsg.LightsPrepare()\n\n\t\t\tfor sg.NextLight() {\n\n\t\t\t\t//\t\t\tif sg.Lp.DiffuseShadeMult() > 0.0 {\n\n\t\t\t\t// In this example the brdf passed is an interface\n\t\t\t\t// allowing sampling, pdf and bsdf eval\n\t\t\t\tcol := sg.EvaluateLightSamples(spec1BRDF)\n\t\t\t\tcol.Mul(spec1Colour)\n\t\t\t\tspec1Contrib.Add(col)\n\t\t\t\t//\t\t\t}\n\n\t\t\t}\n\t\t}\n\t}\n\n\tcontrib := colour.RGB{}\n\n\temissContrib := sh.EvalEmission(sg, m.Vec3Neg(sg.Rd))\n\n\tcontrib.Add(emissContrib)\n\tcontrib.Add(diffContrib)\n\tcontrib.Add(spec1Contrib)\n\n\tsg.OutRGB = contrib\n}", "func compileToObjectFile(inFile, outputDir, filename, inHash string, additionalFlags, kernelHeaders []string) (CompiledOutput, CompilationResult, error) {\n\tflags, flagHash := computeFlagsAndHash(additionalFlags)\n\n\toutputFile, err := getOutputFilePath(outputDir, filename, inHash, flagHash)\n\tif err != nil {\n\t\treturn nil, outputFileErr, fmt.Errorf(\"unable to get output file path: %w\", err)\n\t}\n\n\tvar result CompilationResult\n\tif _, err := os.Stat(outputFile); err != nil {\n\t\tif !os.IsNotExist(err) {\n\t\t\treturn nil, outputFileErr, fmt.Errorf(\"error stat-ing output file %s: %w\", outputFile, err)\n\t\t}\n\n\t\tkv, err := kernel.HostVersion()\n\t\tif err != nil {\n\t\t\treturn nil, kernelVersionErr, fmt.Errorf(\"unable to get kernel version: %w\", err)\n\t\t}\n\t\t_, family, _, err := host.PlatformInformation()\n\t\tif err != nil {\n\t\t\treturn nil, kernelVersionErr, fmt.Errorf(\"unable to get kernel family: %w\", err)\n\t\t}\n\n\t\t// RHEL platforms back-ported the __BPF_FUNC_MAPPER macro, so we can always use the dynamic method there\n\t\tif kv >= kernel.VersionCode(4, 10, 0) || family == \"rhel\" {\n\t\t\tvar helperPath string\n\t\t\thelperPath, err = includeHelperAvailability(kernelHeaders)\n\t\t\tif err != nil {\n\t\t\t\treturn nil, compilationErr, fmt.Errorf(\"error getting helper availability: %w\", err)\n\t\t\t}\n\t\t\tdefer os.Remove(helperPath)\n\t\t\tflags = append(flags, fmt.Sprintf(\"-include%s\", helperPath))\n\t\t}\n\n\t\tif err := compiler.CompileToObjectFile(inFile, outputFile, flags, kernelHeaders); err != nil {\n\t\t\treturn nil, compilationErr, fmt.Errorf(\"failed to compile runtime version of %s: %s\", filename, err)\n\t\t}\n\n\t\tlog.Infof(\"successfully compiled runtime version of %s\", filename)\n\t\tresult = compilationSuccess\n\t} else {\n\t\tlog.Infof(\"found previously compiled runtime version of %s\", filename)\n\t\tresult = compiledOutputFound\n\t}\n\n\terr = bytecode.VerifyAssetPermissions(outputFile)\n\tif err != nil {\n\t\treturn nil, outputFileErr, err\n\t}\n\n\tout, err := os.Open(outputFile)\n\tif err != nil {\n\t\treturn nil, resultReadErr, err\n\t}\n\treturn out, result, nil\n}", "func (l *loader) compile(name string) (string, error) {\n // Copy the file to the objects directory with a different name\n // each time, to avoid retrieving the cached version.\n // Apparently the cache key is the path of the file compiled and\n // there's no way to invalidate it.\n\n f, err := ioutil.ReadFile(filepath.Join(l.pluginsDir, name + \".go\"))\n if err != nil {\n return \"\", fmt.Errorf(\"Cannot read %s.go: %v\", name, err)\n }\n\n name = fmt.Sprintf(\"%d.go\", rand.Int())\n srcPath := filepath.Join(l.objectsDir, name)\n if err := ioutil.WriteFile(srcPath, f, 0666); err != nil {\n return \"\", fmt.Errorf(\"Cannot write %s: %v\", name, err)\n }\n\n objectPath := srcPath[:len(srcPath)-3] + \".so\"\n\n cmd := exec.Command(\"go\", \"build\", \"-buildmode=plugin\", \"-o=\"+objectPath, srcPath)\n cmd.Stderr = os.Stderr\n cmd.Stdout = os.Stdout\n if err := cmd.Run(); err != nil {\n return \"\", fmt.Errorf(\"Cannot compile %s: %v\", name, err)\n }\n\n return objectPath, nil\n}" ]
[ "0.75421816", "0.73613364", "0.7229039", "0.70668304", "0.6974781", "0.6844204", "0.6806778", "0.66904193", "0.66267055", "0.6579397", "0.65686613", "0.64385533", "0.6426448", "0.6321086", "0.6321086", "0.6304544", "0.62004995", "0.61681575", "0.61516255", "0.6124041", "0.60831565", "0.6076725", "0.59953904", "0.5983942", "0.59385437", "0.5929255", "0.5925926", "0.5917888", "0.5915961", "0.5866483", "0.5853832", "0.5808545", "0.5787499", "0.5785967", "0.5747528", "0.5729894", "0.5729894", "0.57182074", "0.57169527", "0.5701616", "0.5677421", "0.5641719", "0.5633336", "0.56233954", "0.55936486", "0.5545704", "0.552682", "0.55216825", "0.55111307", "0.5508511", "0.54896826", "0.5485505", "0.54612345", "0.5458172", "0.5458172", "0.54504305", "0.5436218", "0.54260546", "0.54260546", "0.5418988", "0.5418988", "0.5412412", "0.540014", "0.53524756", "0.53440773", "0.5336031", "0.53355294", "0.53236455", "0.53228015", "0.5313995", "0.53076184", "0.5289644", "0.52876997", "0.5287372", "0.52826035", "0.5268176", "0.52436984", "0.5233932", "0.5216815", "0.52126807", "0.5203532", "0.5200928", "0.5198572", "0.51840705", "0.5178714", "0.5171173", "0.51703495", "0.51614153", "0.51446795", "0.5142656", "0.5139072", "0.51181394", "0.51176023", "0.51026434", "0.50938064", "0.50936687", "0.50917536", "0.5071769", "0.5050858" ]
0.66935635
8
specify a onedimensional texture image in a compressed format
func CompressedTexImage1D(target uint32, level int32, internalformat uint32, width int32, border int32, imageSize int32, data unsafe.Pointer) { C.glowCompressedTexImage1D(gpCompressedTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLint)(border), (C.GLsizei)(imageSize), data) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func CompressedTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall12(gpCompressedTextureSubImage3D, 11, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(imageSize), uintptr(data), 0)\n}", "func CompressedTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage3D(gpCompressedTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage3D(gpCompressedTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func GetCompressedTextureImage(texture uint32, level int32, bufSize int32, pixels unsafe.Pointer) {\n\tsyscall.Syscall6(gpGetCompressedTextureImage, 4, uintptr(texture), uintptr(level), uintptr(bufSize), uintptr(pixels), 0, 0)\n}", "func CompressedTextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTextureSubImage1D, 7, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(width), uintptr(format), uintptr(imageSize), uintptr(data), 0, 0)\n}", "func GetCompressedTextureImage(texture uint32, level int32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetCompressedTextureImage(gpGetCompressedTextureImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLsizei)(bufSize), pixels)\n}", "func GetCompressedTextureImage(texture uint32, level int32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetCompressedTextureImage(gpGetCompressedTextureImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLsizei)(bufSize), pixels)\n}", "func CompressedTextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage1D(gpCompressedTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage1D(gpCompressedTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexImage2D(target uint32, level int32, internalformat uint32, width int32, height int32, border int32, imageSize int32, data unsafe.Pointer) {\n C.glowCompressedTexImage2D(gpCompressedTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func GetCompressedTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetCompressedTextureSubImage(gpGetCompressedTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLsizei)(bufSize), pixels)\n}", "func GetCompressedTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetCompressedTextureSubImage(gpGetCompressedTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLsizei)(bufSize), pixels)\n}", "func CompressedTexImage1D(target uint32, level int32, internalformat uint32, width int32, border int32, imageSize int32, data unsafe.Pointer) {\n C.glowCompressedTexImage1D(gpCompressedTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func CompressedTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTextureSubImage2D, 9, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(width), uintptr(height), uintptr(format), uintptr(imageSize), uintptr(data))\n}", "func CompressedTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage2D(gpCompressedTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage2D(gpCompressedTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func GetCompressedTexImage(target uint32, level int32, img unsafe.Pointer) {\n C.glowGetCompressedTexImage(gpGetCompressedTexImage, (C.GLenum)(target), (C.GLint)(level), img)\n}", "func GetCompressedTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, bufSize int32, pixels unsafe.Pointer) {\n\tsyscall.Syscall12(gpGetCompressedTextureSubImage, 10, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(bufSize), uintptr(pixels), 0, 0)\n}", "func CompressedTexImage3D(target uint32, level int32, internalformat uint32, width int32, height int32, depth int32, border int32, imageSize int32, data unsafe.Pointer) {\n C.glowCompressedTexImage3D(gpCompressedTexImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexImage1D(target uint32, level int32, internalformat uint32, width int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTexImage1D, 7, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(width), uintptr(border), uintptr(imageSize), uintptr(data), 0, 0)\n}", "func CompressedTexImage3D(target uint32, level int32, internalformat uint32, width int32, height int32, depth int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTexImage3D, 9, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(width), uintptr(height), uintptr(depth), uintptr(border), uintptr(imageSize), uintptr(data))\n}", "func CompressedTexImage2D(target uint32, level int32, internalformat uint32, width int32, height int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTexImage2D, 8, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(width), uintptr(height), uintptr(border), uintptr(imageSize), uintptr(data), 0)\n}", "func CompressedTexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n C.glowCompressedTexSubImage1D(gpCompressedTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexImage2D(target uint32, level int32, internalformat uint32, width int32, height int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexImage2D(gpCompressedTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexImage2D(target uint32, level int32, internalformat uint32, width int32, height int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexImage2D(gpCompressedTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n C.glowCompressedTexSubImage3D(gpCompressedTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexImage3D(target uint32, level int32, internalformat uint32, width int32, height int32, depth int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexImage3D(gpCompressedTexImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexImage3D(target uint32, level int32, internalformat uint32, width int32, height int32, depth int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexImage3D(gpCompressedTexImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func TexImage1D(target uint32, level int32, internalformat int32, width int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTexImage1D, 8, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(width), uintptr(border), uintptr(format), uintptr(xtype), uintptr(pixels), 0)\n}", "func CompressedTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n C.glowCompressedTexSubImage2D(gpCompressedTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func TexImage3D(target uint32, level int32, internalformat int32, width int32, height int32, depth int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall12(gpTexImage3D, 10, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(width), uintptr(height), uintptr(depth), uintptr(border), uintptr(format), uintptr(xtype), uintptr(pixels), 0, 0)\n}", "func CompressedTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall12(gpCompressedTexSubImage3D, 11, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(imageSize), uintptr(data), 0)\n}", "func TexImage1D(target uint32, level int32, internalformat int32, width int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexImage1D(gpTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall12(gpTextureSubImage3D, 11, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(xtype), uintptr(pixels), 0)\n}", "func TexImage2D(target GLEnum, level int32, internalformat GLEnum, width, height, border int32, format, xtype GLEnum, pixels []float32) {\n\tgl.TexImage2D(uint32(target), level, int32(internalformat), width, height, border, uint32(format), uint32(xtype), unsafe.Pointer(&pixels[0]))\n}", "func GetCompressedTexImage(target uint32, level int32, img unsafe.Pointer) {\n\tsyscall.Syscall(gpGetCompressedTexImage, 3, uintptr(target), uintptr(level), uintptr(img))\n}", "func TexImage3D(target uint32, level int32, internalformat int32, width int32, height int32, depth int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexImage3D(gpTexImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CompressedTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexSubImage3D(gpCompressedTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexSubImage3D(gpCompressedTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func BindImageTexture(unit uint32, texture uint32, level int32, layered bool, layer int32, access uint32, format uint32) {\n C.glowBindImageTexture(gpBindImageTexture, (C.GLuint)(unit), (C.GLuint)(texture), (C.GLint)(level), (C.GLboolean)(boolToInt(layered)), (C.GLint)(layer), (C.GLenum)(access), (C.GLenum)(format))\n}", "func TextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTextureSubImage1D, 7, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(width), uintptr(format), uintptr(xtype), uintptr(pixels), 0, 0)\n}", "func CompressedTexImage2D(target Enum, level int, internalformat Enum, width, height, border int, data []byte) {\n\tgl.CompressedTexImage2D(uint32(target), int32(level), uint32(internalformat), int32(width), int32(height), int32(border), int32(len(data)), gl.Ptr(data))\n}", "func CompressedTexImage2D(target GLEnum, level int32, internalformat GLEnum, width, height, border, imageSize int32, pixels []float32) {\n\tgl.CompressedTexImage2D(uint32(target), level, uint32(internalformat), width, height, border, imageSize, unsafe.Pointer(&pixels[0]))\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexImage2D(gpTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTexImage2D, 9, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(width), uintptr(height), uintptr(border), uintptr(format), uintptr(xtype), uintptr(pixels))\n}", "func GetCompressedTexImage(target uint32, level int32, img unsafe.Pointer) {\n\tC.glowGetCompressedTexImage(gpGetCompressedTexImage, (C.GLenum)(target), (C.GLint)(level), img)\n}", "func GetCompressedTexImage(target uint32, level int32, img unsafe.Pointer) {\n\tC.glowGetCompressedTexImage(gpGetCompressedTexImage, (C.GLenum)(target), (C.GLint)(level), img)\n}", "func TexImage1D(target uint32, level int32, internalformat int32, width int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexImage1D(gpTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexImage1D(target uint32, level int32, internalformat int32, width int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexImage1D(gpTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func (self *Graphics) GenerateTexture3O(resolution int, scaleMode int, padding int) *Texture{\n return &Texture{self.Object.Call(\"generateTexture\", resolution, scaleMode, padding)}\n}", "func TexImage2D(target Enum, level int, width, height int, format Enum, ty Enum, data []byte) {\n\tp := unsafe.Pointer(nil)\n\tif len(data) > 0 {\n\t\tp = gl.Ptr(&data[0])\n\t}\n\tgl.TexImage2D(uint32(target), int32(level), int32(format), int32(width), int32(height), 0, uint32(format), uint32(ty), p)\n}", "func TexImage3D(target uint32, level int32, internalformat int32, width int32, height int32, depth int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexImage3D(gpTexImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexImage3D(target uint32, level int32, internalformat int32, width int32, height int32, depth int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexImage3D(gpTexImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func New(width uint16, height uint16) *Texture {\n\tt := &Texture{\n\t\twidth: width,\n\t\theight: height,\n\t\tpixels: make([]rgb565.Rgb565Color, width*height),\n\t}\n\n\tfor i := range t.pixels {\n\t\tt.pixels[i] = rgb565.New(0x00, 0x00, 0x00)\n\t}\n\n\treturn t\n}", "func TextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage3D(gpTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage3D(gpTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexSubImage3D(gpTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CompressedTexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTexSubImage1D, 7, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(width), uintptr(format), uintptr(imageSize), uintptr(data), 0, 0)\n}", "func YinYang(width uint16, height uint16) *Texture {\n\tt := New(width, height)\n\tfor y := uint16(0); y < height/2; y++ {\n\t\tfor x := uint16(0); x < width; x++ {\n\t\t\tt.Set(x, y, rgb565.New(0xFF, 0xFF, 0xFF))\n\t\t}\n\t}\n\tfor y := uint16(height/2) + 1; y < height; y++ {\n\t\tfor x := uint16(0); x < width; x++ {\n\t\t\tt.Set(x, y, rgb565.New(0x00, 0x00, 0x00))\n\t\t}\n\t}\n\treturn t\n}", "func CopyTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n\tsyscall.Syscall9(gpCopyTextureSubImage3D, 9, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(x), uintptr(y), uintptr(width), uintptr(height))\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexImage2D(gpTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexImage2D(gpTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func (debugging *debuggingOpenGL) TexImage2D(target uint32, level int32, internalFormat uint32, width int32, height int32,\n\tborder int32, format uint32, xtype uint32, pixels interface{}) {\n\tdebugging.recordEntry(\"TexImage2D\", target, level, internalFormat, width, height, border, format, xtype, pixels)\n\tdebugging.gl.TexImage2D(target, level, internalFormat, width, height, border, format, xtype, pixels)\n\tdebugging.recordExit(\"TexImage2D\")\n}", "func CompressedTexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexSubImage1D(gpCompressedTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexSubImage1D(gpCompressedTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CopyTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTextureSubImage3D(gpCopyTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CopyTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTextureSubImage3D(gpCopyTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CompressedTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTexSubImage2D, 9, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(width), uintptr(height), uintptr(format), uintptr(imageSize), uintptr(data))\n}", "func TexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexSubImage1D(gpTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall12(gpTexSubImage3D, 11, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(xtype), uintptr(pixels), 0)\n}", "func TextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage1D(gpTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage1D(gpTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CompressedTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexSubImage2D(gpCompressedTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexSubImage2D(gpCompressedTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func FromImage(width uint16, height uint16, m image.Image) *Texture {\n\tb := m.Bounds()\n\n\t// m must be at least 8x8\n\tif b.Max.X < 8 || b.Max.Y < 8 {\n\t\tfmt.Println(errorsIncompatibleSize.Error())\n\t\treturn New(width, height)\n\t}\n\n\t// set pixels in current texture to the upper left 8x8 pixels of the provided image\n\tt := New(width, height)\n\tvar x, y uint16\n\tfor y = 0; y < 8; y++ {\n\t\tfor x = 0; x < 8; x++ {\n\t\t\tp := m.At(int(x), int(y))\n\t\t\tt.Set(x, y, rgb565.FromColor(p))\n\t\t}\n\t}\n\n\treturn t\n}", "func CompressedTexSubImage2D(target GLEnum, level, xoffset, yoffset, width, height int32, format GLEnum, imageSize int32, pixels []float32) {\n\tgl.CompressedTexSubImage2D(uint32(target), level, xoffset, yoffset, width, height, uint32(format), imageSize, unsafe.Pointer(&pixels[0]))\n}", "func (w *Worley) GenerateTexture(tex *texture.Texture) {\n\tgl.BindImageTexture(0, tex.GetHandle(), 0, false, 0, gl.READ_WRITE, gl.RGBA32F)\n\tgl.BindImageTexture(1, w.noisetexture.GetHandle(), 0, false, 0, gl.READ_ONLY, gl.RGBA32F)\n\n\tw.computeshader.Use()\n\tw.computeshader.UpdateInt32(\"uWidth\", w.width)\n\tw.computeshader.UpdateInt32(\"uHeight\", w.height)\n\tw.computeshader.UpdateInt32(\"uResolution\", w.resolution)\n\tw.computeshader.UpdateInt32(\"uOctaves\", w.octaves)\n\tw.computeshader.UpdateFloat32(\"uRadius\", w.radius)\n\tw.computeshader.UpdateFloat32(\"uRadiusScale\", w.radiusscale)\n\tw.computeshader.UpdateFloat32(\"uBrightness\", w.brightness)\n\tw.computeshader.UpdateFloat32(\"uContrast\", w.contrast)\n\tw.computeshader.UpdateFloat32(\"uScale\", w.scale)\n\tw.computeshader.UpdateFloat32(\"uPersistance\", w.persistance)\n\tw.computeshader.Compute(uint32(w.width), uint32(w.height), 1)\n\tw.computeshader.Compute(1024, 1024, 1)\n\tw.computeshader.Release()\n\n\tgl.MemoryBarrier(gl.ALL_BARRIER_BITS)\n\n\tgl.BindImageTexture(0, 0, 0, false, 0, gl.WRITE_ONLY, gl.RGBA32F)\n\tgl.BindImageTexture(1, 0, 0, false, 0, gl.READ_ONLY, gl.RGBA32F)\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage3D(gpTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage3D(gpTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CopyTextureSubImage1D(texture uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tsyscall.Syscall6(gpCopyTextureSubImage1D, 6, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(x), uintptr(y), uintptr(width))\n}", "func CopyTextureSubImage1D(texture uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tC.glowCopyTextureSubImage1D(gpCopyTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func CopyTextureSubImage1D(texture uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tC.glowCopyTextureSubImage1D(gpCopyTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func GetTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetTextureSubImage(gpGetTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), (C.GLsizei)(bufSize), pixels)\n}", "func GetTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetTextureSubImage(gpGetTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), (C.GLsizei)(bufSize), pixels)\n}", "func CopyTexImage1D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, border int32) {\n C.glowCopyTexImage1D(gpCopyTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLint)(border))\n}", "func (native *OpenGL) TexImage2D(target uint32, level int32, internalFormat uint32, width int32, height int32,\n\tborder int32, format uint32, xtype uint32, pixels interface{}) {\n\tptr, isPointer := pixels.(unsafe.Pointer)\n\tif isPointer {\n\t\tgl.TexImage2D(target, level, int32(internalFormat), width, height, border, format, xtype, ptr)\n\t} else {\n\t\tgl.TexImage2D(target, level, int32(internalFormat), width, height, border, format, xtype, gl.Ptr(pixels))\n\t}\n}", "func CompressedTexImage2D(target Enum, level Int, internalformat Enum, width Sizei, height Sizei, border Int, imageSize Sizei, data unsafe.Pointer) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tclevel, _ := (C.GLint)(level), cgoAllocsUnknown\n\tcinternalformat, _ := (C.GLenum)(internalformat), cgoAllocsUnknown\n\tcwidth, _ := (C.GLsizei)(width), cgoAllocsUnknown\n\tcheight, _ := (C.GLsizei)(height), cgoAllocsUnknown\n\tcborder, _ := (C.GLint)(border), cgoAllocsUnknown\n\tcimageSize, _ := (C.GLsizei)(imageSize), cgoAllocsUnknown\n\tcdata, _ := (unsafe.Pointer)(unsafe.Pointer(data)), cgoAllocsUnknown\n\tC.glCompressedTexImage2D(ctarget, clevel, cinternalformat, cwidth, cheight, cborder, cimageSize, cdata)\n}", "func Make(width, height int, internalformat int32, format, pixelType uint32,\n\tdata unsafe.Pointer, min, mag, s, t int32) Texture {\n\n\ttexture := Texture{0, gl.TEXTURE_2D, 0}\n\n\t// generate and bind texture\n\tgl.GenTextures(1, &texture.handle)\n\ttexture.Bind(0)\n\n\t// set texture properties\n\tgl.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, min)\n\tgl.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, mag)\n\tgl.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_S, s)\n\tgl.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_T, t)\n\n\t// specify a texture image\n\tgl.TexImage2D(gl.TEXTURE_2D, 0, internalformat, int32(width), int32(height),\n\t\t0, format, pixelType, data)\n\n\t// unbind texture\n\ttexture.Unbind()\n\n\treturn texture\n}", "func TextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTextureSubImage2D, 9, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(width), uintptr(height), uintptr(format), uintptr(xtype), uintptr(pixels))\n}", "func (self *Graphics) GenerateTexture2O(resolution int, scaleMode int) *Texture{\n return &Texture{self.Object.Call(\"generateTexture\", resolution, scaleMode)}\n}", "func GetTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, bufSize int32, pixels unsafe.Pointer) {\n\tsyscall.Syscall12(gpGetTextureSubImage, 12, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(xtype), uintptr(bufSize), uintptr(pixels))\n}", "func (self *Graphics) GenerateTexture1O(resolution int) *Texture{\n return &Texture{self.Object.Call(\"generateTexture\", resolution)}\n}", "func CopyTexImage1D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, border int32) {\n\tsyscall.Syscall9(gpCopyTexImage1D, 7, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(x), uintptr(y), uintptr(width), uintptr(border), 0, 0)\n}", "func TextureView(texture uint32, target uint32, origtexture uint32, internalformat uint32, minlevel uint32, numlevels uint32, minlayer uint32, numlayers uint32) {\n C.glowTextureView(gpTextureView, (C.GLuint)(texture), (C.GLenum)(target), (C.GLuint)(origtexture), (C.GLenum)(internalformat), (C.GLuint)(minlevel), (C.GLuint)(numlevels), (C.GLuint)(minlayer), (C.GLuint)(numlayers))\n}", "func TexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexSubImage2D(gpTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CompressedTexSubImage2D(target Enum, level, xoffset, yoffset, width, height int, format Enum, data []byte) {\n\tgl.CompressedTexSubImage2D(uint32(target), int32(level), int32(xoffset), int32(yoffset), int32(width), int32(height), uint32(format), int32(len(data)), gl.Ptr(data))\n}", "func TexImage2DMultisample(target uint32, samples int32, internalformat uint32, width int32, height int32, fixedsamplelocations bool) {\n C.glowTexImage2DMultisample(gpTexImage2DMultisample, (C.GLenum)(target), (C.GLsizei)(samples), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLboolean)(boolToInt(fixedsamplelocations)))\n}", "func TextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage2D(gpTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage2D(gpTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}" ]
[ "0.6528373", "0.64994603", "0.64994603", "0.6460156", "0.64568317", "0.64497167", "0.64497167", "0.6359567", "0.6359567", "0.62451667", "0.6209575", "0.6209575", "0.6203879", "0.61754", "0.61376697", "0.61376697", "0.6132292", "0.61253023", "0.6076437", "0.6020382", "0.6018831", "0.60054815", "0.5940681", "0.5849737", "0.5849737", "0.58347994", "0.5814781", "0.5814781", "0.58038664", "0.5745331", "0.57237434", "0.57112306", "0.566421", "0.5659777", "0.565477", "0.56471246", "0.5637132", "0.5635265", "0.5635265", "0.5622039", "0.5619701", "0.561282", "0.5608559", "0.5586933", "0.5581844", "0.55643374", "0.55643374", "0.55410135", "0.55410135", "0.5538894", "0.55295885", "0.5508691", "0.5508691", "0.54810673", "0.54770756", "0.54770756", "0.5470057", "0.5448053", "0.54376334", "0.5417054", "0.54082507", "0.54082507", "0.5405062", "0.5400081", "0.5400081", "0.538113", "0.538113", "0.5376022", "0.53468126", "0.5337337", "0.5328484", "0.5328484", "0.53284204", "0.53284204", "0.5320283", "0.5309875", "0.53052694", "0.5287718", "0.5287718", "0.52818894", "0.5256268", "0.5256268", "0.52359277", "0.52359277", "0.52335197", "0.52307755", "0.5230408", "0.5217051", "0.52135307", "0.5194599", "0.5170732", "0.5160056", "0.51143295", "0.5095357", "0.5076729", "0.5043771", "0.50388044", "0.5007845", "0.5007845" ]
0.5766065
30
specify a twodimensional texture image in a compressed format
func CompressedTexImage2D(target uint32, level int32, internalformat uint32, width int32, height int32, border int32, imageSize int32, data unsafe.Pointer) { C.glowCompressedTexImage2D(gpCompressedTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLsizei)(imageSize), data) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func CompressedTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTextureSubImage2D, 9, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(width), uintptr(height), uintptr(format), uintptr(imageSize), uintptr(data))\n}", "func CompressedTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage2D(gpCompressedTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage2D(gpCompressedTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall12(gpCompressedTextureSubImage3D, 11, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(imageSize), uintptr(data), 0)\n}", "func CompressedTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage3D(gpCompressedTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage3D(gpCompressedTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func GetCompressedTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetCompressedTextureSubImage(gpGetCompressedTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLsizei)(bufSize), pixels)\n}", "func GetCompressedTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetCompressedTextureSubImage(gpGetCompressedTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLsizei)(bufSize), pixels)\n}", "func GetCompressedTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, bufSize int32, pixels unsafe.Pointer) {\n\tsyscall.Syscall12(gpGetCompressedTextureSubImage, 10, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(bufSize), uintptr(pixels), 0, 0)\n}", "func CompressedTextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTextureSubImage1D, 7, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(width), uintptr(format), uintptr(imageSize), uintptr(data), 0, 0)\n}", "func GetCompressedTextureImage(texture uint32, level int32, bufSize int32, pixels unsafe.Pointer) {\n\tsyscall.Syscall6(gpGetCompressedTextureImage, 4, uintptr(texture), uintptr(level), uintptr(bufSize), uintptr(pixels), 0, 0)\n}", "func GetCompressedTextureImage(texture uint32, level int32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetCompressedTextureImage(gpGetCompressedTextureImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLsizei)(bufSize), pixels)\n}", "func GetCompressedTextureImage(texture uint32, level int32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetCompressedTextureImage(gpGetCompressedTextureImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLsizei)(bufSize), pixels)\n}", "func CompressedTextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage1D(gpCompressedTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage1D(gpCompressedTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexImage2D(target uint32, level int32, internalformat uint32, width int32, height int32, border int32, imageSize int32, data unsafe.Pointer) {\n C.glowCompressedTexImage2D(gpCompressedTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexImage2D(target uint32, level int32, internalformat uint32, width int32, height int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTexImage2D, 8, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(width), uintptr(height), uintptr(border), uintptr(imageSize), uintptr(data), 0)\n}", "func CompressedTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n C.glowCompressedTexSubImage2D(gpCompressedTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func GetCompressedTexImage(target uint32, level int32, img unsafe.Pointer) {\n C.glowGetCompressedTexImage(gpGetCompressedTexImage, (C.GLenum)(target), (C.GLint)(level), img)\n}", "func TexImage2D(target Enum, level int, width, height int, format Enum, ty Enum, data []byte) {\n\tp := unsafe.Pointer(nil)\n\tif len(data) > 0 {\n\t\tp = gl.Ptr(&data[0])\n\t}\n\tgl.TexImage2D(uint32(target), int32(level), int32(format), int32(width), int32(height), 0, uint32(format), uint32(ty), p)\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTexImage2D, 9, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(width), uintptr(height), uintptr(border), uintptr(format), uintptr(xtype), uintptr(pixels))\n}", "func TextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall12(gpTextureSubImage3D, 11, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(xtype), uintptr(pixels), 0)\n}", "func TexImage2D(target GLEnum, level int32, internalformat GLEnum, width, height, border int32, format, xtype GLEnum, pixels []float32) {\n\tgl.TexImage2D(uint32(target), level, int32(internalformat), width, height, border, uint32(format), uint32(xtype), unsafe.Pointer(&pixels[0]))\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexImage2D(gpTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTextureSubImage2D, 9, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(width), uintptr(height), uintptr(format), uintptr(xtype), uintptr(pixels))\n}", "func CompressedTexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n C.glowCompressedTexSubImage1D(gpCompressedTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTexSubImage2D, 9, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(width), uintptr(height), uintptr(format), uintptr(imageSize), uintptr(data))\n}", "func CompressedTexImage2D(target Enum, level int, internalformat Enum, width, height, border int, data []byte) {\n\tgl.CompressedTexImage2D(uint32(target), int32(level), uint32(internalformat), int32(width), int32(height), int32(border), int32(len(data)), gl.Ptr(data))\n}", "func CompressedTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n C.glowCompressedTexSubImage3D(gpCompressedTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexImage1D(target uint32, level int32, internalformat uint32, width int32, border int32, imageSize int32, data unsafe.Pointer) {\n C.glowCompressedTexImage1D(gpCompressedTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func TextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage3D(gpTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage3D(gpTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTextureSubImage1D, 7, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(width), uintptr(format), uintptr(xtype), uintptr(pixels), 0, 0)\n}", "func CompressedTexImage3D(target uint32, level int32, internalformat uint32, width int32, height int32, depth int32, border int32, imageSize int32, data unsafe.Pointer) {\n C.glowCompressedTexImage3D(gpCompressedTexImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexImage2D(gpTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexImage2D(gpTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CompressedTexImage2D(target GLEnum, level int32, internalformat GLEnum, width, height, border, imageSize int32, pixels []float32) {\n\tgl.CompressedTexImage2D(uint32(target), level, uint32(internalformat), width, height, border, imageSize, unsafe.Pointer(&pixels[0]))\n}", "func CompressedTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexSubImage2D(gpCompressedTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexSubImage2D(gpCompressedTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CopyTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n\tsyscall.Syscall9(gpCopyTextureSubImage3D, 9, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(x), uintptr(y), uintptr(width), uintptr(height))\n}", "func (debugging *debuggingOpenGL) TexImage2D(target uint32, level int32, internalFormat uint32, width int32, height int32,\n\tborder int32, format uint32, xtype uint32, pixels interface{}) {\n\tdebugging.recordEntry(\"TexImage2D\", target, level, internalFormat, width, height, border, format, xtype, pixels)\n\tdebugging.gl.TexImage2D(target, level, internalFormat, width, height, border, format, xtype, pixels)\n\tdebugging.recordExit(\"TexImage2D\")\n}", "func GetTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetTextureSubImage(gpGetTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), (C.GLsizei)(bufSize), pixels)\n}", "func GetTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetTextureSubImage(gpGetTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), (C.GLsizei)(bufSize), pixels)\n}", "func CompressedTexSubImage2D(target GLEnum, level, xoffset, yoffset, width, height int32, format GLEnum, imageSize int32, pixels []float32) {\n\tgl.CompressedTexSubImage2D(uint32(target), level, xoffset, yoffset, width, height, uint32(format), imageSize, unsafe.Pointer(&pixels[0]))\n}", "func CopyTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTextureSubImage3D(gpCopyTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CopyTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTextureSubImage3D(gpCopyTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CompressedTexImage3D(target uint32, level int32, internalformat uint32, width int32, height int32, depth int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTexImage3D, 9, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(width), uintptr(height), uintptr(depth), uintptr(border), uintptr(imageSize), uintptr(data))\n}", "func TextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage2D(gpTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage2D(gpTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func YinYang(width uint16, height uint16) *Texture {\n\tt := New(width, height)\n\tfor y := uint16(0); y < height/2; y++ {\n\t\tfor x := uint16(0); x < width; x++ {\n\t\t\tt.Set(x, y, rgb565.New(0xFF, 0xFF, 0xFF))\n\t\t}\n\t}\n\tfor y := uint16(height/2) + 1; y < height; y++ {\n\t\tfor x := uint16(0); x < width; x++ {\n\t\t\tt.Set(x, y, rgb565.New(0x00, 0x00, 0x00))\n\t\t}\n\t}\n\treturn t\n}", "func CompressedTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall12(gpCompressedTexSubImage3D, 11, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(imageSize), uintptr(data), 0)\n}", "func GetTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, bufSize int32, pixels unsafe.Pointer) {\n\tsyscall.Syscall12(gpGetTextureSubImage, 12, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(xtype), uintptr(bufSize), uintptr(pixels))\n}", "func TexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexSubImage2D(gpTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func (native *OpenGL) TexImage2D(target uint32, level int32, internalFormat uint32, width int32, height int32,\n\tborder int32, format uint32, xtype uint32, pixels interface{}) {\n\tptr, isPointer := pixels.(unsafe.Pointer)\n\tif isPointer {\n\t\tgl.TexImage2D(target, level, int32(internalFormat), width, height, border, format, xtype, ptr)\n\t} else {\n\t\tgl.TexImage2D(target, level, int32(internalFormat), width, height, border, format, xtype, gl.Ptr(pixels))\n\t}\n}", "func (w *Worley) GenerateTexture(tex *texture.Texture) {\n\tgl.BindImageTexture(0, tex.GetHandle(), 0, false, 0, gl.READ_WRITE, gl.RGBA32F)\n\tgl.BindImageTexture(1, w.noisetexture.GetHandle(), 0, false, 0, gl.READ_ONLY, gl.RGBA32F)\n\n\tw.computeshader.Use()\n\tw.computeshader.UpdateInt32(\"uWidth\", w.width)\n\tw.computeshader.UpdateInt32(\"uHeight\", w.height)\n\tw.computeshader.UpdateInt32(\"uResolution\", w.resolution)\n\tw.computeshader.UpdateInt32(\"uOctaves\", w.octaves)\n\tw.computeshader.UpdateFloat32(\"uRadius\", w.radius)\n\tw.computeshader.UpdateFloat32(\"uRadiusScale\", w.radiusscale)\n\tw.computeshader.UpdateFloat32(\"uBrightness\", w.brightness)\n\tw.computeshader.UpdateFloat32(\"uContrast\", w.contrast)\n\tw.computeshader.UpdateFloat32(\"uScale\", w.scale)\n\tw.computeshader.UpdateFloat32(\"uPersistance\", w.persistance)\n\tw.computeshader.Compute(uint32(w.width), uint32(w.height), 1)\n\tw.computeshader.Compute(1024, 1024, 1)\n\tw.computeshader.Release()\n\n\tgl.MemoryBarrier(gl.ALL_BARRIER_BITS)\n\n\tgl.BindImageTexture(0, 0, 0, false, 0, gl.WRITE_ONLY, gl.RGBA32F)\n\tgl.BindImageTexture(1, 0, 0, false, 0, gl.READ_ONLY, gl.RGBA32F)\n}", "func CompressedTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexSubImage3D(gpCompressedTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexSubImage3D(gpCompressedTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexImage1D(target uint32, level int32, internalformat uint32, width int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTexImage1D, 7, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(width), uintptr(border), uintptr(imageSize), uintptr(data), 0, 0)\n}", "func TexImage3D(target uint32, level int32, internalformat int32, width int32, height int32, depth int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall12(gpTexImage3D, 10, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(width), uintptr(height), uintptr(depth), uintptr(border), uintptr(format), uintptr(xtype), uintptr(pixels), 0, 0)\n}", "func CompressedTexSubImage2D(target Enum, level, xoffset, yoffset, width, height int, format Enum, data []byte) {\n\tgl.CompressedTexSubImage2D(uint32(target), int32(level), int32(xoffset), int32(yoffset), int32(width), int32(height), uint32(format), int32(len(data)), gl.Ptr(data))\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexSubImage3D(gpTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func GetCompressedTexImage(target uint32, level int32, img unsafe.Pointer) {\n\tsyscall.Syscall(gpGetCompressedTexImage, 3, uintptr(target), uintptr(level), uintptr(img))\n}", "func CopyTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTextureSubImage2D(gpCopyTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CopyTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTextureSubImage2D(gpCopyTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func New(width uint16, height uint16) *Texture {\n\tt := &Texture{\n\t\twidth: width,\n\t\theight: height,\n\t\tpixels: make([]rgb565.Rgb565Color, width*height),\n\t}\n\n\tfor i := range t.pixels {\n\t\tt.pixels[i] = rgb565.New(0x00, 0x00, 0x00)\n\t}\n\n\treturn t\n}", "func CopyTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n\tsyscall.Syscall9(gpCopyTextureSubImage2D, 8, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(x), uintptr(y), uintptr(width), uintptr(height), 0)\n}", "func CopyTextureSubImage1D(texture uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tsyscall.Syscall6(gpCopyTextureSubImage1D, 6, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(x), uintptr(y), uintptr(width))\n}", "func TextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage1D(gpTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage1D(gpTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func BindImageTexture(unit uint32, texture uint32, level int32, layered bool, layer int32, access uint32, format uint32) {\n C.glowBindImageTexture(gpBindImageTexture, (C.GLuint)(unit), (C.GLuint)(texture), (C.GLint)(level), (C.GLboolean)(boolToInt(layered)), (C.GLint)(layer), (C.GLenum)(access), (C.GLenum)(format))\n}", "func CopyTextureSubImage1D(texture uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tC.glowCopyTextureSubImage1D(gpCopyTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func CopyTextureSubImage1D(texture uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tC.glowCopyTextureSubImage1D(gpCopyTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall12(gpTexSubImage3D, 11, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(xtype), uintptr(pixels), 0)\n}", "func CompressedTexImage3D(target uint32, level int32, internalformat uint32, width int32, height int32, depth int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexImage3D(gpCompressedTexImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexImage3D(target uint32, level int32, internalformat uint32, width int32, height int32, depth int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexImage3D(gpCompressedTexImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexImage2D(target Enum, level Int, internalformat Enum, width Sizei, height Sizei, border Int, imageSize Sizei, data unsafe.Pointer) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tclevel, _ := (C.GLint)(level), cgoAllocsUnknown\n\tcinternalformat, _ := (C.GLenum)(internalformat), cgoAllocsUnknown\n\tcwidth, _ := (C.GLsizei)(width), cgoAllocsUnknown\n\tcheight, _ := (C.GLsizei)(height), cgoAllocsUnknown\n\tcborder, _ := (C.GLint)(border), cgoAllocsUnknown\n\tcimageSize, _ := (C.GLsizei)(imageSize), cgoAllocsUnknown\n\tcdata, _ := (unsafe.Pointer)(unsafe.Pointer(data)), cgoAllocsUnknown\n\tC.glCompressedTexImage2D(ctarget, clevel, cinternalformat, cwidth, cheight, cborder, cimageSize, cdata)\n}", "func TexImage1D(target uint32, level int32, internalformat int32, width int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTexImage1D, 8, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(width), uintptr(border), uintptr(format), uintptr(xtype), uintptr(pixels), 0)\n}", "func Make(width, height int, internalformat int32, format, pixelType uint32,\n\tdata unsafe.Pointer, min, mag, s, t int32) Texture {\n\n\ttexture := Texture{0, gl.TEXTURE_2D, 0}\n\n\t// generate and bind texture\n\tgl.GenTextures(1, &texture.handle)\n\ttexture.Bind(0)\n\n\t// set texture properties\n\tgl.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, min)\n\tgl.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, mag)\n\tgl.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_S, s)\n\tgl.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_T, t)\n\n\t// specify a texture image\n\tgl.TexImage2D(gl.TEXTURE_2D, 0, internalformat, int32(width), int32(height),\n\t\t0, format, pixelType, data)\n\n\t// unbind texture\n\ttexture.Unbind()\n\n\treturn texture\n}", "func (self *Graphics) GenerateTexture3O(resolution int, scaleMode int, padding int) *Texture{\n return &Texture{self.Object.Call(\"generateTexture\", resolution, scaleMode, padding)}\n}", "func TexImage3D(target uint32, level int32, internalformat int32, width int32, height int32, depth int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexImage3D(gpTexImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexSubImage1D(gpTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage3D(gpTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage3D(gpTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func (self *Graphics) GenerateTexture2O(resolution int, scaleMode int) *Texture{\n return &Texture{self.Object.Call(\"generateTexture\", resolution, scaleMode)}\n}", "func TexImage2D(target Enum, level Int, internalformat Int, width Sizei, height Sizei, border Int, format Enum, kind Enum, pixels unsafe.Pointer) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tclevel, _ := (C.GLint)(level), cgoAllocsUnknown\n\tcinternalformat, _ := (C.GLint)(internalformat), cgoAllocsUnknown\n\tcwidth, _ := (C.GLsizei)(width), cgoAllocsUnknown\n\tcheight, _ := (C.GLsizei)(height), cgoAllocsUnknown\n\tcborder, _ := (C.GLint)(border), cgoAllocsUnknown\n\tcformat, _ := (C.GLenum)(format), cgoAllocsUnknown\n\tckind, _ := (C.GLenum)(kind), cgoAllocsUnknown\n\tcpixels, _ := (unsafe.Pointer)(unsafe.Pointer(pixels)), cgoAllocsUnknown\n\tC.glTexImage2D(ctarget, clevel, cinternalformat, cwidth, cheight, cborder, cformat, ckind, cpixels)\n}", "func GetCompressedTexImage(target uint32, level int32, img unsafe.Pointer) {\n\tC.glowGetCompressedTexImage(gpGetCompressedTexImage, (C.GLenum)(target), (C.GLint)(level), img)\n}", "func GetCompressedTexImage(target uint32, level int32, img unsafe.Pointer) {\n\tC.glowGetCompressedTexImage(gpGetCompressedTexImage, (C.GLenum)(target), (C.GLint)(level), img)\n}", "func TexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTexSubImage2D, 9, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(width), uintptr(height), uintptr(format), uintptr(xtype), uintptr(pixels))\n}", "func TexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage2D(gpTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage2D(gpTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CompressedTexSubImage2D(target Enum, level Int, xoffset Int, yoffset Int, width Sizei, height Sizei, format Enum, imageSize Sizei, data unsafe.Pointer) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tclevel, _ := (C.GLint)(level), cgoAllocsUnknown\n\tcxoffset, _ := (C.GLint)(xoffset), cgoAllocsUnknown\n\tcyoffset, _ := (C.GLint)(yoffset), cgoAllocsUnknown\n\tcwidth, _ := (C.GLsizei)(width), cgoAllocsUnknown\n\tcheight, _ := (C.GLsizei)(height), cgoAllocsUnknown\n\tcformat, _ := (C.GLenum)(format), cgoAllocsUnknown\n\tcimageSize, _ := (C.GLsizei)(imageSize), cgoAllocsUnknown\n\tcdata, _ := (unsafe.Pointer)(unsafe.Pointer(data)), cgoAllocsUnknown\n\tC.glCompressedTexSubImage2D(ctarget, clevel, cxoffset, cyoffset, cwidth, cheight, cformat, cimageSize, cdata)\n}", "func TexSubImage2D(target GLEnum, level, xoffset, yoffset, width, height int32, format, xtype GLEnum, pixels []float32) {\n\tgl.TexSubImage2D(uint32(target), level, xoffset, yoffset, width, height, uint32(format), uint32(xtype), unsafe.Pointer(&pixels[0]))\n}", "func TexImage3D(target uint32, level int32, internalformat int32, width int32, height int32, depth int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexImage3D(gpTexImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexImage3D(target uint32, level int32, internalformat int32, width int32, height int32, depth int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexImage3D(gpTexImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage2D(target Enum, level int, x, y, width, height int, format, ty Enum, data []byte) {\n\tgl.TexSubImage2D(uint32(target), int32(level), int32(x), int32(y), int32(width), int32(height), uint32(format), uint32(ty), gl.Ptr(&data[0]))\n}", "func CompressedTexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTexSubImage1D, 7, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(width), uintptr(format), uintptr(imageSize), uintptr(data), 0, 0)\n}", "func (gl *WebGL) TexImage2D(target GLEnum, level int, internalFormat GLEnum, format GLEnum, texelType GLEnum, pixels interface{}) {\n\tgl.context.Call(\"texImage2D\", target, level, internalFormat, format, texelType, pixels)\n}", "func TexImage1D(target uint32, level int32, internalformat int32, width int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexImage1D(gpTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CompressedTexImage1D(target uint32, level int32, internalformat uint32, width int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexImage1D(gpCompressedTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}" ]
[ "0.6820861", "0.6780762", "0.6780762", "0.67249054", "0.67241544", "0.67241544", "0.6654857", "0.6654857", "0.65744406", "0.6558697", "0.6558555", "0.65300393", "0.65300393", "0.6460095", "0.6460095", "0.6400892", "0.6201863", "0.61903274", "0.60405064", "0.60118544", "0.6005927", "0.5975421", "0.59753966", "0.5960947", "0.5934735", "0.58886987", "0.588064", "0.5833584", "0.5832671", "0.58311903", "0.58294195", "0.58294195", "0.5827777", "0.58272725", "0.58117646", "0.58117646", "0.58070666", "0.5794567", "0.5794567", "0.5787485", "0.57804626", "0.5780053", "0.5780053", "0.57780576", "0.57723415", "0.57723415", "0.5753454", "0.57487357", "0.57487357", "0.5748527", "0.57149714", "0.5713758", "0.5677855", "0.5650116", "0.5640897", "0.5620233", "0.5620233", "0.5618861", "0.5609456", "0.56084013", "0.5608129", "0.5572971", "0.5569787", "0.5569787", "0.55586207", "0.5555001", "0.55453473", "0.55437386", "0.55437386", "0.5538387", "0.5535265", "0.5535265", "0.5525439", "0.5524647", "0.5524647", "0.5517401", "0.54989403", "0.5493592", "0.548996", "0.54854447", "0.5479624", "0.54714304", "0.54714304", "0.5468537", "0.545125", "0.5450867", "0.5450867", "0.54499614", "0.5446701", "0.5446701", "0.5430085", "0.54061234", "0.5390657", "0.5390657", "0.53671926", "0.53583723", "0.53507286", "0.5347153", "0.5326404" ]
0.6014798
20
specify a threedimensional texture image in a compressed format
func CompressedTexImage3D(target uint32, level int32, internalformat uint32, width int32, height int32, depth int32, border int32, imageSize int32, data unsafe.Pointer) { C.glowCompressedTexImage3D(gpCompressedTexImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLint)(border), (C.GLsizei)(imageSize), data) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func CompressedTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall12(gpCompressedTextureSubImage3D, 11, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(imageSize), uintptr(data), 0)\n}", "func CompressedTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage3D(gpCompressedTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage3D(gpCompressedTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTextureSubImage1D, 7, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(width), uintptr(format), uintptr(imageSize), uintptr(data), 0, 0)\n}", "func GetCompressedTextureImage(texture uint32, level int32, bufSize int32, pixels unsafe.Pointer) {\n\tsyscall.Syscall6(gpGetCompressedTextureImage, 4, uintptr(texture), uintptr(level), uintptr(bufSize), uintptr(pixels), 0, 0)\n}", "func GetCompressedTextureImage(texture uint32, level int32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetCompressedTextureImage(gpGetCompressedTextureImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLsizei)(bufSize), pixels)\n}", "func GetCompressedTextureImage(texture uint32, level int32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetCompressedTextureImage(gpGetCompressedTextureImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLsizei)(bufSize), pixels)\n}", "func CompressedTextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage1D(gpCompressedTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage1D(gpCompressedTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTextureSubImage2D, 9, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(width), uintptr(height), uintptr(format), uintptr(imageSize), uintptr(data))\n}", "func GetCompressedTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetCompressedTextureSubImage(gpGetCompressedTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLsizei)(bufSize), pixels)\n}", "func GetCompressedTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetCompressedTextureSubImage(gpGetCompressedTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLsizei)(bufSize), pixels)\n}", "func CompressedTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage2D(gpCompressedTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage2D(gpCompressedTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexImage3D(target uint32, level int32, internalformat uint32, width int32, height int32, depth int32, border int32, imageSize int32, data unsafe.Pointer) {\n C.glowCompressedTexImage3D(gpCompressedTexImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexImage2D(target uint32, level int32, internalformat uint32, width int32, height int32, border int32, imageSize int32, data unsafe.Pointer) {\n C.glowCompressedTexImage2D(gpCompressedTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func GetCompressedTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, bufSize int32, pixels unsafe.Pointer) {\n\tsyscall.Syscall12(gpGetCompressedTextureSubImage, 10, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(bufSize), uintptr(pixels), 0, 0)\n}", "func CompressedTexImage3D(target uint32, level int32, internalformat uint32, width int32, height int32, depth int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTexImage3D, 9, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(width), uintptr(height), uintptr(depth), uintptr(border), uintptr(imageSize), uintptr(data))\n}", "func CompressedTexImage1D(target uint32, level int32, internalformat uint32, width int32, border int32, imageSize int32, data unsafe.Pointer) {\n C.glowCompressedTexImage1D(gpCompressedTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func GetCompressedTexImage(target uint32, level int32, img unsafe.Pointer) {\n C.glowGetCompressedTexImage(gpGetCompressedTexImage, (C.GLenum)(target), (C.GLint)(level), img)\n}", "func TexImage3D(target uint32, level int32, internalformat int32, width int32, height int32, depth int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall12(gpTexImage3D, 10, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(width), uintptr(height), uintptr(depth), uintptr(border), uintptr(format), uintptr(xtype), uintptr(pixels), 0, 0)\n}", "func CompressedTexImage2D(target uint32, level int32, internalformat uint32, width int32, height int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTexImage2D, 8, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(width), uintptr(height), uintptr(border), uintptr(imageSize), uintptr(data), 0)\n}", "func CompressedTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n C.glowCompressedTexSubImage3D(gpCompressedTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func TextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall12(gpTextureSubImage3D, 11, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(xtype), uintptr(pixels), 0)\n}", "func TexImage3D(target uint32, level int32, internalformat int32, width int32, height int32, depth int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexImage3D(gpTexImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CompressedTexImage1D(target uint32, level int32, internalformat uint32, width int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTexImage1D, 7, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(width), uintptr(border), uintptr(imageSize), uintptr(data), 0, 0)\n}", "func CompressedTexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n C.glowCompressedTexSubImage1D(gpCompressedTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexImage2D(target uint32, level int32, internalformat uint32, width int32, height int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexImage2D(gpCompressedTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexImage2D(target uint32, level int32, internalformat uint32, width int32, height int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexImage2D(gpCompressedTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func TexImage3D(target uint32, level int32, internalformat int32, width int32, height int32, depth int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexImage3D(gpTexImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexImage3D(target uint32, level int32, internalformat int32, width int32, height int32, depth int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexImage3D(gpTexImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CompressedTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall12(gpCompressedTexSubImage3D, 11, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(imageSize), uintptr(data), 0)\n}", "func TextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage3D(gpTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage3D(gpTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CompressedTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexSubImage3D(gpCompressedTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexSubImage3D(gpCompressedTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n C.glowCompressedTexSubImage2D(gpCompressedTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func TexImage2D(target Enum, level int, width, height int, format Enum, ty Enum, data []byte) {\n\tp := unsafe.Pointer(nil)\n\tif len(data) > 0 {\n\t\tp = gl.Ptr(&data[0])\n\t}\n\tgl.TexImage2D(uint32(target), int32(level), int32(format), int32(width), int32(height), 0, uint32(format), uint32(ty), p)\n}", "func TexImage1D(target uint32, level int32, internalformat int32, width int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTexImage1D, 8, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(width), uintptr(border), uintptr(format), uintptr(xtype), uintptr(pixels), 0)\n}", "func CopyTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n\tsyscall.Syscall9(gpCopyTextureSubImage3D, 9, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(x), uintptr(y), uintptr(width), uintptr(height))\n}", "func TexImage2D(target GLEnum, level int32, internalformat GLEnum, width, height, border int32, format, xtype GLEnum, pixels []float32) {\n\tgl.TexImage2D(uint32(target), level, int32(internalformat), width, height, border, uint32(format), uint32(xtype), unsafe.Pointer(&pixels[0]))\n}", "func CopyTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTextureSubImage3D(gpCopyTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CopyTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTextureSubImage3D(gpCopyTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CompressedTexImage1D(target uint32, level int32, internalformat uint32, width int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexImage1D(gpCompressedTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexImage1D(target uint32, level int32, internalformat uint32, width int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexImage1D(gpCompressedTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexSubImage3D(gpTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTexImage2D, 9, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(width), uintptr(height), uintptr(border), uintptr(format), uintptr(xtype), uintptr(pixels))\n}", "func TextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTextureSubImage1D, 7, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(width), uintptr(format), uintptr(xtype), uintptr(pixels), 0, 0)\n}", "func CompressedTexImage2D(target Enum, level int, internalformat Enum, width, height, border int, data []byte) {\n\tgl.CompressedTexImage2D(uint32(target), int32(level), uint32(internalformat), int32(width), int32(height), int32(border), int32(len(data)), gl.Ptr(data))\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexImage2D(gpTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func GetCompressedTexImage(target uint32, level int32, img unsafe.Pointer) {\n\tsyscall.Syscall(gpGetCompressedTexImage, 3, uintptr(target), uintptr(level), uintptr(img))\n}", "func TexImage1D(target uint32, level int32, internalformat int32, width int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexImage1D(gpTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CompressedTexImage2D(target GLEnum, level int32, internalformat GLEnum, width, height, border, imageSize int32, pixels []float32) {\n\tgl.CompressedTexImage2D(uint32(target), level, uint32(internalformat), width, height, border, imageSize, unsafe.Pointer(&pixels[0]))\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall12(gpTexSubImage3D, 11, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(xtype), uintptr(pixels), 0)\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage3D(gpTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage3D(gpTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func GetCompressedTexImage(target uint32, level int32, img unsafe.Pointer) {\n\tC.glowGetCompressedTexImage(gpGetCompressedTexImage, (C.GLenum)(target), (C.GLint)(level), img)\n}", "func GetCompressedTexImage(target uint32, level int32, img unsafe.Pointer) {\n\tC.glowGetCompressedTexImage(gpGetCompressedTexImage, (C.GLenum)(target), (C.GLint)(level), img)\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexImage2D(gpTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexImage2D(gpTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexImage1D(target uint32, level int32, internalformat int32, width int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexImage1D(gpTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexImage1D(target uint32, level int32, internalformat int32, width int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexImage1D(gpTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func BindImageTexture(unit uint32, texture uint32, level int32, layered bool, layer int32, access uint32, format uint32) {\n C.glowBindImageTexture(gpBindImageTexture, (C.GLuint)(unit), (C.GLuint)(texture), (C.GLint)(level), (C.GLboolean)(boolToInt(layered)), (C.GLint)(layer), (C.GLenum)(access), (C.GLenum)(format))\n}", "func (debugging *debuggingOpenGL) TexImage2D(target uint32, level int32, internalFormat uint32, width int32, height int32,\n\tborder int32, format uint32, xtype uint32, pixels interface{}) {\n\tdebugging.recordEntry(\"TexImage2D\", target, level, internalFormat, width, height, border, format, xtype, pixels)\n\tdebugging.gl.TexImage2D(target, level, internalFormat, width, height, border, format, xtype, pixels)\n\tdebugging.recordExit(\"TexImage2D\")\n}", "func TextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage1D(gpTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage1D(gpTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CompressedTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTexSubImage2D, 9, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(width), uintptr(height), uintptr(format), uintptr(imageSize), uintptr(data))\n}", "func CopyTextureSubImage1D(texture uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tsyscall.Syscall6(gpCopyTextureSubImage1D, 6, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(x), uintptr(y), uintptr(width))\n}", "func CopyTextureSubImage1D(texture uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tC.glowCopyTextureSubImage1D(gpCopyTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func CopyTextureSubImage1D(texture uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tC.glowCopyTextureSubImage1D(gpCopyTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func CompressedTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexSubImage2D(gpCompressedTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexSubImage2D(gpCompressedTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTexSubImage1D, 7, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(width), uintptr(format), uintptr(imageSize), uintptr(data), 0, 0)\n}", "func CompressedTexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexSubImage1D(gpCompressedTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexSubImage1D(gpCompressedTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func TexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexSubImage1D(gpTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func (self *Graphics) GenerateTexture3O(resolution int, scaleMode int, padding int) *Texture{\n return &Texture{self.Object.Call(\"generateTexture\", resolution, scaleMode, padding)}\n}", "func TextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTextureSubImage2D, 9, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(width), uintptr(height), uintptr(format), uintptr(xtype), uintptr(pixels))\n}", "func GetTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetTextureSubImage(gpGetTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), (C.GLsizei)(bufSize), pixels)\n}", "func GetTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetTextureSubImage(gpGetTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), (C.GLsizei)(bufSize), pixels)\n}", "func CompressedTexSubImage2D(target GLEnum, level, xoffset, yoffset, width, height int32, format GLEnum, imageSize int32, pixels []float32) {\n\tgl.CompressedTexSubImage2D(uint32(target), level, xoffset, yoffset, width, height, uint32(format), imageSize, unsafe.Pointer(&pixels[0]))\n}", "func CompressedTexImage2D(target Enum, level Int, internalformat Enum, width Sizei, height Sizei, border Int, imageSize Sizei, data unsafe.Pointer) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tclevel, _ := (C.GLint)(level), cgoAllocsUnknown\n\tcinternalformat, _ := (C.GLenum)(internalformat), cgoAllocsUnknown\n\tcwidth, _ := (C.GLsizei)(width), cgoAllocsUnknown\n\tcheight, _ := (C.GLsizei)(height), cgoAllocsUnknown\n\tcborder, _ := (C.GLint)(border), cgoAllocsUnknown\n\tcimageSize, _ := (C.GLsizei)(imageSize), cgoAllocsUnknown\n\tcdata, _ := (unsafe.Pointer)(unsafe.Pointer(data)), cgoAllocsUnknown\n\tC.glCompressedTexImage2D(ctarget, clevel, cinternalformat, cwidth, cheight, cborder, cimageSize, cdata)\n}", "func YinYang(width uint16, height uint16) *Texture {\n\tt := New(width, height)\n\tfor y := uint16(0); y < height/2; y++ {\n\t\tfor x := uint16(0); x < width; x++ {\n\t\t\tt.Set(x, y, rgb565.New(0xFF, 0xFF, 0xFF))\n\t\t}\n\t}\n\tfor y := uint16(height/2) + 1; y < height; y++ {\n\t\tfor x := uint16(0); x < width; x++ {\n\t\t\tt.Set(x, y, rgb565.New(0x00, 0x00, 0x00))\n\t\t}\n\t}\n\treturn t\n}", "func (native *OpenGL) TexImage2D(target uint32, level int32, internalFormat uint32, width int32, height int32,\n\tborder int32, format uint32, xtype uint32, pixels interface{}) {\n\tptr, isPointer := pixels.(unsafe.Pointer)\n\tif isPointer {\n\t\tgl.TexImage2D(target, level, int32(internalFormat), width, height, border, format, xtype, ptr)\n\t} else {\n\t\tgl.TexImage2D(target, level, int32(internalFormat), width, height, border, format, xtype, gl.Ptr(pixels))\n\t}\n}", "func GetTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, bufSize int32, pixels unsafe.Pointer) {\n\tsyscall.Syscall12(gpGetTextureSubImage, 12, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(xtype), uintptr(bufSize), uintptr(pixels))\n}", "func TexImage3DMultisample(target uint32, samples int32, internalformat uint32, width int32, height int32, depth int32, fixedsamplelocations bool) {\n C.glowTexImage3DMultisample(gpTexImage3DMultisample, (C.GLenum)(target), (C.GLsizei)(samples), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLboolean)(boolToInt(fixedsamplelocations)))\n}", "func New(width uint16, height uint16) *Texture {\n\tt := &Texture{\n\t\twidth: width,\n\t\theight: height,\n\t\tpixels: make([]rgb565.Rgb565Color, width*height),\n\t}\n\n\tfor i := range t.pixels {\n\t\tt.pixels[i] = rgb565.New(0x00, 0x00, 0x00)\n\t}\n\n\treturn t\n}", "func TexImage2DMultisample(target uint32, samples int32, internalformat uint32, width int32, height int32, fixedsamplelocations bool) {\n C.glowTexImage2DMultisample(gpTexImage2DMultisample, (C.GLenum)(target), (C.GLsizei)(samples), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLboolean)(boolToInt(fixedsamplelocations)))\n}", "func (w *Worley) GenerateTexture(tex *texture.Texture) {\n\tgl.BindImageTexture(0, tex.GetHandle(), 0, false, 0, gl.READ_WRITE, gl.RGBA32F)\n\tgl.BindImageTexture(1, w.noisetexture.GetHandle(), 0, false, 0, gl.READ_ONLY, gl.RGBA32F)\n\n\tw.computeshader.Use()\n\tw.computeshader.UpdateInt32(\"uWidth\", w.width)\n\tw.computeshader.UpdateInt32(\"uHeight\", w.height)\n\tw.computeshader.UpdateInt32(\"uResolution\", w.resolution)\n\tw.computeshader.UpdateInt32(\"uOctaves\", w.octaves)\n\tw.computeshader.UpdateFloat32(\"uRadius\", w.radius)\n\tw.computeshader.UpdateFloat32(\"uRadiusScale\", w.radiusscale)\n\tw.computeshader.UpdateFloat32(\"uBrightness\", w.brightness)\n\tw.computeshader.UpdateFloat32(\"uContrast\", w.contrast)\n\tw.computeshader.UpdateFloat32(\"uScale\", w.scale)\n\tw.computeshader.UpdateFloat32(\"uPersistance\", w.persistance)\n\tw.computeshader.Compute(uint32(w.width), uint32(w.height), 1)\n\tw.computeshader.Compute(1024, 1024, 1)\n\tw.computeshader.Release()\n\n\tgl.MemoryBarrier(gl.ALL_BARRIER_BITS)\n\n\tgl.BindImageTexture(0, 0, 0, false, 0, gl.WRITE_ONLY, gl.RGBA32F)\n\tgl.BindImageTexture(1, 0, 0, false, 0, gl.READ_ONLY, gl.RGBA32F)\n}", "func TextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage2D(gpTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage2D(gpTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexImage3DMultisample(target uint32, samples int32, internalformat uint32, width int32, height int32, depth int32, fixedsamplelocations bool) {\n\tsyscall.Syscall9(gpTexImage3DMultisample, 7, uintptr(target), uintptr(samples), uintptr(internalformat), uintptr(width), uintptr(height), uintptr(depth), boolToUintptr(fixedsamplelocations), 0, 0)\n}", "func Make(width, height int, internalformat int32, format, pixelType uint32,\n\tdata unsafe.Pointer, min, mag, s, t int32) Texture {\n\n\ttexture := Texture{0, gl.TEXTURE_2D, 0}\n\n\t// generate and bind texture\n\tgl.GenTextures(1, &texture.handle)\n\ttexture.Bind(0)\n\n\t// set texture properties\n\tgl.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, min)\n\tgl.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, mag)\n\tgl.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_S, s)\n\tgl.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_T, t)\n\n\t// specify a texture image\n\tgl.TexImage2D(gl.TEXTURE_2D, 0, internalformat, int32(width), int32(height),\n\t\t0, format, pixelType, data)\n\n\t// unbind texture\n\ttexture.Unbind()\n\n\treturn texture\n}", "func TexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexSubImage2D(gpTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexImage3DMultisample(target uint32, samples int32, internalformat uint32, width int32, height int32, depth int32, fixedsamplelocations bool) {\n\tC.glowTexImage3DMultisample(gpTexImage3DMultisample, (C.GLenum)(target), (C.GLsizei)(samples), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLboolean)(boolToInt(fixedsamplelocations)))\n}", "func TexImage3DMultisample(target uint32, samples int32, internalformat uint32, width int32, height int32, depth int32, fixedsamplelocations bool) {\n\tC.glowTexImage3DMultisample(gpTexImage3DMultisample, (C.GLenum)(target), (C.GLsizei)(samples), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLboolean)(boolToInt(fixedsamplelocations)))\n}", "func CompressedTexSubImage2D(target Enum, level, xoffset, yoffset, width, height int, format Enum, data []byte) {\n\tgl.CompressedTexSubImage2D(uint32(target), int32(level), int32(xoffset), int32(yoffset), int32(width), int32(height), uint32(format), int32(len(data)), gl.Ptr(data))\n}", "func TexImage2D(target Enum, level Int, internalformat Int, width Sizei, height Sizei, border Int, format Enum, kind Enum, pixels unsafe.Pointer) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tclevel, _ := (C.GLint)(level), cgoAllocsUnknown\n\tcinternalformat, _ := (C.GLint)(internalformat), cgoAllocsUnknown\n\tcwidth, _ := (C.GLsizei)(width), cgoAllocsUnknown\n\tcheight, _ := (C.GLsizei)(height), cgoAllocsUnknown\n\tcborder, _ := (C.GLint)(border), cgoAllocsUnknown\n\tcformat, _ := (C.GLenum)(format), cgoAllocsUnknown\n\tckind, _ := (C.GLenum)(kind), cgoAllocsUnknown\n\tcpixels, _ := (unsafe.Pointer)(unsafe.Pointer(pixels)), cgoAllocsUnknown\n\tC.glTexImage2D(ctarget, clevel, cinternalformat, cwidth, cheight, cborder, cformat, ckind, cpixels)\n}", "func CopyTexImage1D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, border int32) {\n C.glowCopyTexImage1D(gpCopyTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLint)(border))\n}" ]
[ "0.67944324", "0.6788097", "0.6788097", "0.65358734", "0.64502954", "0.6446981", "0.6446981", "0.64390385", "0.64390385", "0.6344451", "0.6342221", "0.6342221", "0.63141984", "0.63141984", "0.62797177", "0.6261731", "0.62611717", "0.61913854", "0.61417705", "0.61244947", "0.60201854", "0.6011617", "0.59888446", "0.5951418", "0.5933692", "0.5928058", "0.5905512", "0.58863497", "0.58863497", "0.58447564", "0.58447564", "0.58405685", "0.581825", "0.581825", "0.5795406", "0.5795406", "0.57785034", "0.5760746", "0.5739522", "0.57220376", "0.5711681", "0.56998026", "0.56998026", "0.5693129", "0.5693129", "0.5686025", "0.56679094", "0.5658572", "0.56504065", "0.5648697", "0.56169176", "0.56115925", "0.5588692", "0.5577437", "0.5572512", "0.5572512", "0.55528104", "0.55528104", "0.55381227", "0.55381227", "0.55190337", "0.55190337", "0.54663414", "0.54148567", "0.5411766", "0.5411766", "0.54079074", "0.5395077", "0.5392542", "0.5392542", "0.5387498", "0.5387498", "0.53853244", "0.5358082", "0.5358082", "0.53566766", "0.53305805", "0.5328324", "0.53131", "0.53131", "0.5300455", "0.5290145", "0.5271728", "0.5251714", "0.5236574", "0.5235931", "0.5216911", "0.52073187", "0.5201773", "0.5171397", "0.5171397", "0.51511645", "0.51488656", "0.5136181", "0.51296175", "0.51296175", "0.5126438", "0.51163125", "0.5094325" ]
0.6014296
22
specify a onedimensional texture subimage in a compressed format
func CompressedTexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) { C.glowCompressedTexSubImage1D(gpCompressedTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLsizei)(imageSize), data) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func CompressedTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage3D(gpCompressedTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage3D(gpCompressedTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func GetCompressedTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetCompressedTextureSubImage(gpGetCompressedTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLsizei)(bufSize), pixels)\n}", "func GetCompressedTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetCompressedTextureSubImage(gpGetCompressedTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLsizei)(bufSize), pixels)\n}", "func CompressedTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall12(gpCompressedTextureSubImage3D, 11, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(imageSize), uintptr(data), 0)\n}", "func CompressedTextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTextureSubImage1D, 7, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(width), uintptr(format), uintptr(imageSize), uintptr(data), 0, 0)\n}", "func CompressedTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage2D(gpCompressedTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage2D(gpCompressedTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage1D(gpCompressedTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage1D(gpCompressedTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTextureSubImage2D, 9, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(width), uintptr(height), uintptr(format), uintptr(imageSize), uintptr(data))\n}", "func GetCompressedTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, bufSize int32, pixels unsafe.Pointer) {\n\tsyscall.Syscall12(gpGetCompressedTextureSubImage, 10, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(bufSize), uintptr(pixels), 0, 0)\n}", "func TextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTextureSubImage1D, 7, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(width), uintptr(format), uintptr(xtype), uintptr(pixels), 0, 0)\n}", "func TextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall12(gpTextureSubImage3D, 11, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(xtype), uintptr(pixels), 0)\n}", "func TextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage3D(gpTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage3D(gpTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTextureSubImage2D, 9, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(width), uintptr(height), uintptr(format), uintptr(xtype), uintptr(pixels))\n}", "func CopyTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTextureSubImage3D(gpCopyTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CopyTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTextureSubImage3D(gpCopyTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func TextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage1D(gpTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage1D(gpTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func GetTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetTextureSubImage(gpGetTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), (C.GLsizei)(bufSize), pixels)\n}", "func GetTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetTextureSubImage(gpGetTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), (C.GLsizei)(bufSize), pixels)\n}", "func CopyTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n\tsyscall.Syscall9(gpCopyTextureSubImage3D, 9, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(x), uintptr(y), uintptr(width), uintptr(height))\n}", "func CompressedTexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n C.glowCompressedTexSubImage1D(gpCompressedTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n C.glowCompressedTexSubImage2D(gpCompressedTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func GetTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, bufSize int32, pixels unsafe.Pointer) {\n\tsyscall.Syscall12(gpGetTextureSubImage, 12, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(xtype), uintptr(bufSize), uintptr(pixels))\n}", "func (tex Texture) Sub(ctx gl.Context, lvl int, width int, height int, data []byte) {\n\tctx.TexSubImage2D(gl.TEXTURE_2D, lvl, 0, 0, width, height, gl.RGBA, gl.UNSIGNED_BYTE, data)\n\tif lvl > 0 {\n\t\tctx.GenerateMipmap(gl.TEXTURE_2D)\n\t}\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexSubImage3D(gpTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CopyTextureSubImage1D(texture uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tsyscall.Syscall6(gpCopyTextureSubImage1D, 6, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(x), uintptr(y), uintptr(width))\n}", "func GetCompressedTextureImage(texture uint32, level int32, bufSize int32, pixels unsafe.Pointer) {\n\tsyscall.Syscall6(gpGetCompressedTextureImage, 4, uintptr(texture), uintptr(level), uintptr(bufSize), uintptr(pixels), 0, 0)\n}", "func CopyTextureSubImage1D(texture uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tC.glowCopyTextureSubImage1D(gpCopyTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func CopyTextureSubImage1D(texture uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tC.glowCopyTextureSubImage1D(gpCopyTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func TextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage2D(gpTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage2D(gpTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexSubImage1D(gpTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall12(gpTexSubImage3D, 11, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(xtype), uintptr(pixels), 0)\n}", "func GetCompressedTextureImage(texture uint32, level int32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetCompressedTextureImage(gpGetCompressedTextureImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLsizei)(bufSize), pixels)\n}", "func GetCompressedTextureImage(texture uint32, level int32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetCompressedTextureImage(gpGetCompressedTextureImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLsizei)(bufSize), pixels)\n}", "func TexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexSubImage2D(gpTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage3D(gpTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage3D(gpTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CompressedTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n C.glowCompressedTexSubImage3D(gpCompressedTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexImage2D(target uint32, level int32, internalformat uint32, width int32, height int32, border int32, imageSize int32, data unsafe.Pointer) {\n C.glowCompressedTexImage2D(gpCompressedTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTexSubImage2D, 9, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(width), uintptr(height), uintptr(format), uintptr(imageSize), uintptr(data))\n}", "func CompressedTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall12(gpCompressedTexSubImage3D, 11, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(imageSize), uintptr(data), 0)\n}", "func CompressedTexSubImage2D(target GLEnum, level, xoffset, yoffset, width, height int32, format GLEnum, imageSize int32, pixels []float32) {\n\tgl.CompressedTexSubImage2D(uint32(target), level, xoffset, yoffset, width, height, uint32(format), imageSize, unsafe.Pointer(&pixels[0]))\n}", "func CompressedTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexSubImage2D(gpCompressedTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexSubImage2D(gpCompressedTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CopyTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTextureSubImage2D(gpCopyTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CopyTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTextureSubImage2D(gpCopyTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CompressedTexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTexSubImage1D, 7, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(width), uintptr(format), uintptr(imageSize), uintptr(data), 0, 0)\n}", "func TexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTexSubImage1D, 7, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(width), uintptr(format), uintptr(xtype), uintptr(pixels), 0, 0)\n}", "func CompressedTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexSubImage3D(gpCompressedTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexSubImage3D(gpCompressedTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CopyTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n\tsyscall.Syscall9(gpCopyTextureSubImage2D, 8, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(x), uintptr(y), uintptr(width), uintptr(height), 0)\n}", "func CompressedTexImage2D(target uint32, level int32, internalformat uint32, width int32, height int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTexImage2D, 8, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(width), uintptr(height), uintptr(border), uintptr(imageSize), uintptr(data), 0)\n}", "func GetCompressedTexImage(target uint32, level int32, img unsafe.Pointer) {\n C.glowGetCompressedTexImage(gpGetCompressedTexImage, (C.GLenum)(target), (C.GLint)(level), img)\n}", "func TexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage1D(gpTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage1D(gpTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTexSubImage2D, 9, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(width), uintptr(height), uintptr(format), uintptr(xtype), uintptr(pixels))\n}", "func TexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage2D(gpTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage2D(gpTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage2D(target Enum, level int, x, y, width, height int, format, ty Enum, data []byte) {\n\tgl.TexSubImage2D(uint32(target), int32(level), int32(x), int32(y), int32(width), int32(height), uint32(format), uint32(ty), gl.Ptr(&data[0]))\n}", "func CompressedTexImage1D(target uint32, level int32, internalformat uint32, width int32, border int32, imageSize int32, data unsafe.Pointer) {\n C.glowCompressedTexImage1D(gpCompressedTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func CopyImageSubData(srcName uint32, srcTarget uint32, srcLevel int32, srcX int32, srcY int32, srcZ int32, dstName uint32, dstTarget uint32, dstLevel int32, dstX int32, dstY int32, dstZ int32, srcWidth int32, srcHeight int32, srcDepth int32) {\n C.glowCopyImageSubData(gpCopyImageSubData, (C.GLuint)(srcName), (C.GLenum)(srcTarget), (C.GLint)(srcLevel), (C.GLint)(srcX), (C.GLint)(srcY), (C.GLint)(srcZ), (C.GLuint)(dstName), (C.GLenum)(dstTarget), (C.GLint)(dstLevel), (C.GLint)(dstX), (C.GLint)(dstY), (C.GLint)(dstZ), (C.GLsizei)(srcWidth), (C.GLsizei)(srcHeight), (C.GLsizei)(srcDepth))\n}", "func TexSubImage2D(target GLEnum, level, xoffset, yoffset, width, height int32, format, xtype GLEnum, pixels []float32) {\n\tgl.TexSubImage2D(uint32(target), level, xoffset, yoffset, width, height, uint32(format), uint32(xtype), unsafe.Pointer(&pixels[0]))\n}", "func CompressedTexSubImage2D(target Enum, level, xoffset, yoffset, width, height int, format Enum, data []byte) {\n\tgl.CompressedTexSubImage2D(uint32(target), int32(level), int32(xoffset), int32(yoffset), int32(width), int32(height), uint32(format), int32(len(data)), gl.Ptr(data))\n}", "func CompressedTexImage2D(target uint32, level int32, internalformat uint32, width int32, height int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexImage2D(gpCompressedTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexImage2D(target uint32, level int32, internalformat uint32, width int32, height int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexImage2D(gpCompressedTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexImage1D(target uint32, level int32, internalformat uint32, width int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTexImage1D, 7, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(width), uintptr(border), uintptr(imageSize), uintptr(data), 0, 0)\n}", "func CompressedTexImage3D(target uint32, level int32, internalformat uint32, width int32, height int32, depth int32, border int32, imageSize int32, data unsafe.Pointer) {\n C.glowCompressedTexImage3D(gpCompressedTexImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexImage2D(target Enum, level int, internalformat Enum, width, height, border int, data []byte) {\n\tgl.CompressedTexImage2D(uint32(target), int32(level), uint32(internalformat), int32(width), int32(height), int32(border), int32(len(data)), gl.Ptr(data))\n}", "func CompressedTexImage2D(target GLEnum, level int32, internalformat GLEnum, width, height, border, imageSize int32, pixels []float32) {\n\tgl.CompressedTexImage2D(uint32(target), level, uint32(internalformat), width, height, border, imageSize, unsafe.Pointer(&pixels[0]))\n}", "func CopyImageSubData(srcName uint32, srcTarget uint32, srcLevel int32, srcX int32, srcY int32, srcZ int32, dstName uint32, dstTarget uint32, dstLevel int32, dstX int32, dstY int32, dstZ int32, srcWidth int32, srcHeight int32, srcDepth int32) {\n\tC.glowCopyImageSubData(gpCopyImageSubData, (C.GLuint)(srcName), (C.GLenum)(srcTarget), (C.GLint)(srcLevel), (C.GLint)(srcX), (C.GLint)(srcY), (C.GLint)(srcZ), (C.GLuint)(dstName), (C.GLenum)(dstTarget), (C.GLint)(dstLevel), (C.GLint)(dstX), (C.GLint)(dstY), (C.GLint)(dstZ), (C.GLsizei)(srcWidth), (C.GLsizei)(srcHeight), (C.GLsizei)(srcDepth))\n}", "func CopyImageSubData(srcName uint32, srcTarget uint32, srcLevel int32, srcX int32, srcY int32, srcZ int32, dstName uint32, dstTarget uint32, dstLevel int32, dstX int32, dstY int32, dstZ int32, srcWidth int32, srcHeight int32, srcDepth int32) {\n\tC.glowCopyImageSubData(gpCopyImageSubData, (C.GLuint)(srcName), (C.GLenum)(srcTarget), (C.GLint)(srcLevel), (C.GLint)(srcX), (C.GLint)(srcY), (C.GLint)(srcZ), (C.GLuint)(dstName), (C.GLenum)(dstTarget), (C.GLint)(dstLevel), (C.GLint)(dstX), (C.GLint)(dstY), (C.GLint)(dstZ), (C.GLsizei)(srcWidth), (C.GLsizei)(srcHeight), (C.GLsizei)(srcDepth))\n}", "func TexImage2D(target GLEnum, level int32, internalformat GLEnum, width, height, border int32, format, xtype GLEnum, pixels []float32) {\n\tgl.TexImage2D(uint32(target), level, int32(internalformat), width, height, border, uint32(format), uint32(xtype), unsafe.Pointer(&pixels[0]))\n}", "func CompressedTexImage3D(target uint32, level int32, internalformat uint32, width int32, height int32, depth int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTexImage3D, 9, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(width), uintptr(height), uintptr(depth), uintptr(border), uintptr(imageSize), uintptr(data))\n}", "func GetCompressedTexImage(target uint32, level int32, img unsafe.Pointer) {\n\tsyscall.Syscall(gpGetCompressedTexImage, 3, uintptr(target), uintptr(level), uintptr(img))\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTexImage2D, 9, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(width), uintptr(height), uintptr(border), uintptr(format), uintptr(xtype), uintptr(pixels))\n}", "func CompressedTexSubImage2D(target Enum, level Int, xoffset Int, yoffset Int, width Sizei, height Sizei, format Enum, imageSize Sizei, data unsafe.Pointer) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tclevel, _ := (C.GLint)(level), cgoAllocsUnknown\n\tcxoffset, _ := (C.GLint)(xoffset), cgoAllocsUnknown\n\tcyoffset, _ := (C.GLint)(yoffset), cgoAllocsUnknown\n\tcwidth, _ := (C.GLsizei)(width), cgoAllocsUnknown\n\tcheight, _ := (C.GLsizei)(height), cgoAllocsUnknown\n\tcformat, _ := (C.GLenum)(format), cgoAllocsUnknown\n\tcimageSize, _ := (C.GLsizei)(imageSize), cgoAllocsUnknown\n\tcdata, _ := (unsafe.Pointer)(unsafe.Pointer(data)), cgoAllocsUnknown\n\tC.glCompressedTexSubImage2D(ctarget, clevel, cxoffset, cyoffset, cwidth, cheight, cformat, cimageSize, cdata)\n}", "func TexSubImage2D(target Enum, level Int, xoffset Int, yoffset Int, width Sizei, height Sizei, format Enum, kind Enum, pixels unsafe.Pointer) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tclevel, _ := (C.GLint)(level), cgoAllocsUnknown\n\tcxoffset, _ := (C.GLint)(xoffset), cgoAllocsUnknown\n\tcyoffset, _ := (C.GLint)(yoffset), cgoAllocsUnknown\n\tcwidth, _ := (C.GLsizei)(width), cgoAllocsUnknown\n\tcheight, _ := (C.GLsizei)(height), cgoAllocsUnknown\n\tcformat, _ := (C.GLenum)(format), cgoAllocsUnknown\n\tckind, _ := (C.GLenum)(kind), cgoAllocsUnknown\n\tcpixels, _ := (unsafe.Pointer)(unsafe.Pointer(pixels)), cgoAllocsUnknown\n\tC.glTexSubImage2D(ctarget, clevel, cxoffset, cyoffset, cwidth, cheight, cformat, ckind, cpixels)\n}", "func GetCompressedTexImage(target uint32, level int32, img unsafe.Pointer) {\n\tC.glowGetCompressedTexImage(gpGetCompressedTexImage, (C.GLenum)(target), (C.GLint)(level), img)\n}", "func GetCompressedTexImage(target uint32, level int32, img unsafe.Pointer) {\n\tC.glowGetCompressedTexImage(gpGetCompressedTexImage, (C.GLenum)(target), (C.GLint)(level), img)\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexImage2D(gpTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexImage1D(target uint32, level int32, internalformat int32, width int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTexImage1D, 8, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(width), uintptr(border), uintptr(format), uintptr(xtype), uintptr(pixels), 0)\n}", "func (debugging *debuggingOpenGL) TexImage2D(target uint32, level int32, internalFormat uint32, width int32, height int32,\n\tborder int32, format uint32, xtype uint32, pixels interface{}) {\n\tdebugging.recordEntry(\"TexImage2D\", target, level, internalFormat, width, height, border, format, xtype, pixels)\n\tdebugging.gl.TexImage2D(target, level, internalFormat, width, height, border, format, xtype, pixels)\n\tdebugging.recordExit(\"TexImage2D\")\n}", "func TexImage2D(target Enum, level int, width, height int, format Enum, ty Enum, data []byte) {\n\tp := unsafe.Pointer(nil)\n\tif len(data) > 0 {\n\t\tp = gl.Ptr(&data[0])\n\t}\n\tgl.TexImage2D(uint32(target), int32(level), int32(format), int32(width), int32(height), 0, uint32(format), uint32(ty), p)\n}", "func CompressedTexImage1D(target uint32, level int32, internalformat uint32, width int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexImage1D(gpCompressedTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexImage1D(target uint32, level int32, internalformat uint32, width int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexImage1D(gpCompressedTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func (p *Alpha16) SubImage(r Rectangle) Image {\n\tr = r.Intersect(p.Rect)\n\t// If r1 and r2 are Rectangles, r1.Intersect(r2) is not guaranteed to be inside\n\t// either r1 or r2 if the intersection is empty. Without explicitly checking for\n\t// this, the Pix[i:] expression below can panic.\n\tif r.Empty() {\n\t\treturn &Alpha16{}\n\t}\n\ti := p.PixOffset(r.Min.X, r.Min.Y)\n\treturn &Alpha16{\n\t\tPix: p.Pix[i:],\n\t\tStride: p.Stride,\n\t\tRect: r,\n\t}\n}", "func CompressedTexImage3D(target uint32, level int32, internalformat uint32, width int32, height int32, depth int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexImage3D(gpCompressedTexImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexImage3D(target uint32, level int32, internalformat uint32, width int32, height int32, depth int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexImage3D(gpCompressedTexImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func BindImageTexture(unit uint32, texture uint32, level int32, layered bool, layer int32, access uint32, format uint32) {\n C.glowBindImageTexture(gpBindImageTexture, (C.GLuint)(unit), (C.GLuint)(texture), (C.GLint)(level), (C.GLboolean)(boolToInt(layered)), (C.GLint)(layer), (C.GLenum)(access), (C.GLenum)(format))\n}", "func CopyTexSubImage1D(target uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n C.glowCopyTexSubImage1D(gpCopyTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexImage2D(gpTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexImage2D(gpTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CopyTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n C.glowCopyTexSubImage3D(gpCopyTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func TexImage1D(target uint32, level int32, internalformat int32, width int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexImage1D(gpTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}" ]
[ "0.7192663", "0.7192663", "0.7148786", "0.7148786", "0.71463704", "0.7104704", "0.70999265", "0.70999265", "0.70813614", "0.70813614", "0.7079332", "0.707832", "0.64743364", "0.6446946", "0.633491", "0.633491", "0.6282994", "0.62674683", "0.62674683", "0.62573236", "0.62573236", "0.6255767", "0.6255767", "0.62466943", "0.6221279", "0.6217863", "0.6204014", "0.6166575", "0.6158077", "0.6151243", "0.6146721", "0.6144936", "0.6144936", "0.6130324", "0.6130324", "0.6124414", "0.6067131", "0.6066933", "0.6066933", "0.6028035", "0.6017329", "0.6017329", "0.59932816", "0.5987074", "0.59823084", "0.5931711", "0.5910406", "0.5892303", "0.5892303", "0.588412", "0.588412", "0.5853548", "0.58522815", "0.5848349", "0.5848349", "0.5841012", "0.58277386", "0.5822359", "0.5819963", "0.5819963", "0.5815222", "0.5783863", "0.5783863", "0.5778719", "0.57194513", "0.5707058", "0.57009894", "0.56747895", "0.5655224", "0.5655224", "0.5572276", "0.5499627", "0.54943514", "0.548499", "0.5458238", "0.5458238", "0.545762", "0.5448591", "0.541291", "0.54015434", "0.5385922", "0.5353554", "0.5333577", "0.5333577", "0.53321695", "0.53306454", "0.53237355", "0.5311662", "0.5311391", "0.5311391", "0.52917504", "0.52484316", "0.52484316", "0.5220464", "0.52142555", "0.5212394", "0.5212394", "0.5153851", "0.51238036" ]
0.57617414
65
specify a twodimensional texture subimage in a compressed format
func CompressedTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) { C.glowCompressedTexSubImage2D(gpCompressedTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLsizei)(imageSize), data) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func CompressedTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage2D(gpCompressedTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage2D(gpCompressedTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTextureSubImage2D, 9, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(width), uintptr(height), uintptr(format), uintptr(imageSize), uintptr(data))\n}", "func GetCompressedTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetCompressedTextureSubImage(gpGetCompressedTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLsizei)(bufSize), pixels)\n}", "func GetCompressedTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetCompressedTextureSubImage(gpGetCompressedTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLsizei)(bufSize), pixels)\n}", "func GetCompressedTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, bufSize int32, pixels unsafe.Pointer) {\n\tsyscall.Syscall12(gpGetCompressedTextureSubImage, 10, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(bufSize), uintptr(pixels), 0, 0)\n}", "func CompressedTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage3D(gpCompressedTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage3D(gpCompressedTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall12(gpCompressedTextureSubImage3D, 11, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(imageSize), uintptr(data), 0)\n}", "func CompressedTextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTextureSubImage1D, 7, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(width), uintptr(format), uintptr(imageSize), uintptr(data), 0, 0)\n}", "func CompressedTextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage1D(gpCompressedTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage1D(gpCompressedTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func TextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTextureSubImage2D, 9, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(width), uintptr(height), uintptr(format), uintptr(xtype), uintptr(pixels))\n}", "func TextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage2D(gpTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage2D(gpTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall12(gpTextureSubImage3D, 11, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(xtype), uintptr(pixels), 0)\n}", "func GetTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetTextureSubImage(gpGetTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), (C.GLsizei)(bufSize), pixels)\n}", "func GetTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetTextureSubImage(gpGetTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), (C.GLsizei)(bufSize), pixels)\n}", "func GetTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, bufSize int32, pixels unsafe.Pointer) {\n\tsyscall.Syscall12(gpGetTextureSubImage, 12, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(xtype), uintptr(bufSize), uintptr(pixels))\n}", "func TextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTextureSubImage1D, 7, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(width), uintptr(format), uintptr(xtype), uintptr(pixels), 0, 0)\n}", "func TextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage3D(gpTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage3D(gpTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CopyTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTextureSubImage3D(gpCopyTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CopyTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTextureSubImage3D(gpCopyTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CopyTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n\tsyscall.Syscall9(gpCopyTextureSubImage3D, 9, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(x), uintptr(y), uintptr(width), uintptr(height))\n}", "func CompressedTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n C.glowCompressedTexSubImage2D(gpCompressedTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CopyTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTextureSubImage2D(gpCopyTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CopyTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTextureSubImage2D(gpCopyTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func TexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexSubImage2D(gpTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CopyTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n\tsyscall.Syscall9(gpCopyTextureSubImage2D, 8, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(x), uintptr(y), uintptr(width), uintptr(height), 0)\n}", "func (tex Texture) Sub(ctx gl.Context, lvl int, width int, height int, data []byte) {\n\tctx.TexSubImage2D(gl.TEXTURE_2D, lvl, 0, 0, width, height, gl.RGBA, gl.UNSIGNED_BYTE, data)\n\tif lvl > 0 {\n\t\tctx.GenerateMipmap(gl.TEXTURE_2D)\n\t}\n}", "func TextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage1D(gpTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage1D(gpTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CopyTextureSubImage1D(texture uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tC.glowCopyTextureSubImage1D(gpCopyTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func CopyTextureSubImage1D(texture uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tC.glowCopyTextureSubImage1D(gpCopyTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func TexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTexSubImage2D, 9, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(width), uintptr(height), uintptr(format), uintptr(xtype), uintptr(pixels))\n}", "func CompressedTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTexSubImage2D, 9, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(width), uintptr(height), uintptr(format), uintptr(imageSize), uintptr(data))\n}", "func CopyTextureSubImage1D(texture uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tsyscall.Syscall6(gpCopyTextureSubImage1D, 6, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(x), uintptr(y), uintptr(width))\n}", "func TexSubImage2D(target Enum, level int, x, y, width, height int, format, ty Enum, data []byte) {\n\tgl.TexSubImage2D(uint32(target), int32(level), int32(x), int32(y), int32(width), int32(height), uint32(format), uint32(ty), gl.Ptr(&data[0]))\n}", "func TexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage2D(gpTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage2D(gpTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CompressedTexSubImage2D(target GLEnum, level, xoffset, yoffset, width, height int32, format GLEnum, imageSize int32, pixels []float32) {\n\tgl.CompressedTexSubImage2D(uint32(target), level, xoffset, yoffset, width, height, uint32(format), imageSize, unsafe.Pointer(&pixels[0]))\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexSubImage3D(gpTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall12(gpTexSubImage3D, 11, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(xtype), uintptr(pixels), 0)\n}", "func TexSubImage2D(target GLEnum, level, xoffset, yoffset, width, height int32, format, xtype GLEnum, pixels []float32) {\n\tgl.TexSubImage2D(uint32(target), level, xoffset, yoffset, width, height, uint32(format), uint32(xtype), unsafe.Pointer(&pixels[0]))\n}", "func GetCompressedTextureImage(texture uint32, level int32, bufSize int32, pixels unsafe.Pointer) {\n\tsyscall.Syscall6(gpGetCompressedTextureImage, 4, uintptr(texture), uintptr(level), uintptr(bufSize), uintptr(pixels), 0, 0)\n}", "func TexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexSubImage1D(gpTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage3D(gpTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage3D(gpTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CompressedTexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n C.glowCompressedTexSubImage1D(gpCompressedTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func GetCompressedTextureImage(texture uint32, level int32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetCompressedTextureImage(gpGetCompressedTextureImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLsizei)(bufSize), pixels)\n}", "func GetCompressedTextureImage(texture uint32, level int32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetCompressedTextureImage(gpGetCompressedTextureImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLsizei)(bufSize), pixels)\n}", "func CompressedTexSubImage2D(target Enum, level, xoffset, yoffset, width, height int, format Enum, data []byte) {\n\tgl.CompressedTexSubImage2D(uint32(target), int32(level), int32(xoffset), int32(yoffset), int32(width), int32(height), uint32(format), int32(len(data)), gl.Ptr(data))\n}", "func CompressedTexImage2D(target uint32, level int32, internalformat uint32, width int32, height int32, border int32, imageSize int32, data unsafe.Pointer) {\n C.glowCompressedTexImage2D(gpCompressedTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n C.glowCompressedTexSubImage3D(gpCompressedTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexImage2D(target uint32, level int32, internalformat uint32, width int32, height int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTexImage2D, 8, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(width), uintptr(height), uintptr(border), uintptr(imageSize), uintptr(data), 0)\n}", "func TexSubImage2D(target Enum, level Int, xoffset Int, yoffset Int, width Sizei, height Sizei, format Enum, kind Enum, pixels unsafe.Pointer) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tclevel, _ := (C.GLint)(level), cgoAllocsUnknown\n\tcxoffset, _ := (C.GLint)(xoffset), cgoAllocsUnknown\n\tcyoffset, _ := (C.GLint)(yoffset), cgoAllocsUnknown\n\tcwidth, _ := (C.GLsizei)(width), cgoAllocsUnknown\n\tcheight, _ := (C.GLsizei)(height), cgoAllocsUnknown\n\tcformat, _ := (C.GLenum)(format), cgoAllocsUnknown\n\tckind, _ := (C.GLenum)(kind), cgoAllocsUnknown\n\tcpixels, _ := (unsafe.Pointer)(unsafe.Pointer(pixels)), cgoAllocsUnknown\n\tC.glTexSubImage2D(ctarget, clevel, cxoffset, cyoffset, cwidth, cheight, cformat, ckind, cpixels)\n}", "func TexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTexSubImage1D, 7, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(width), uintptr(format), uintptr(xtype), uintptr(pixels), 0, 0)\n}", "func CompressedTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall12(gpCompressedTexSubImage3D, 11, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(imageSize), uintptr(data), 0)\n}", "func TexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage1D(gpTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage1D(gpTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CopyImageSubData(srcName uint32, srcTarget uint32, srcLevel int32, srcX int32, srcY int32, srcZ int32, dstName uint32, dstTarget uint32, dstLevel int32, dstX int32, dstY int32, dstZ int32, srcWidth int32, srcHeight int32, srcDepth int32) {\n C.glowCopyImageSubData(gpCopyImageSubData, (C.GLuint)(srcName), (C.GLenum)(srcTarget), (C.GLint)(srcLevel), (C.GLint)(srcX), (C.GLint)(srcY), (C.GLint)(srcZ), (C.GLuint)(dstName), (C.GLenum)(dstTarget), (C.GLint)(dstLevel), (C.GLint)(dstX), (C.GLint)(dstY), (C.GLint)(dstZ), (C.GLsizei)(srcWidth), (C.GLsizei)(srcHeight), (C.GLsizei)(srcDepth))\n}", "func CompressedTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexSubImage3D(gpCompressedTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexSubImage3D(gpCompressedTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexSubImage2D(target Enum, level Int, xoffset Int, yoffset Int, width Sizei, height Sizei, format Enum, imageSize Sizei, data unsafe.Pointer) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tclevel, _ := (C.GLint)(level), cgoAllocsUnknown\n\tcxoffset, _ := (C.GLint)(xoffset), cgoAllocsUnknown\n\tcyoffset, _ := (C.GLint)(yoffset), cgoAllocsUnknown\n\tcwidth, _ := (C.GLsizei)(width), cgoAllocsUnknown\n\tcheight, _ := (C.GLsizei)(height), cgoAllocsUnknown\n\tcformat, _ := (C.GLenum)(format), cgoAllocsUnknown\n\tcimageSize, _ := (C.GLsizei)(imageSize), cgoAllocsUnknown\n\tcdata, _ := (unsafe.Pointer)(unsafe.Pointer(data)), cgoAllocsUnknown\n\tC.glCompressedTexSubImage2D(ctarget, clevel, cxoffset, cyoffset, cwidth, cheight, cformat, cimageSize, cdata)\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTexImage2D, 9, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(width), uintptr(height), uintptr(border), uintptr(format), uintptr(xtype), uintptr(pixels))\n}", "func CompressedTexImage2D(target uint32, level int32, internalformat uint32, width int32, height int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexImage2D(gpCompressedTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexImage2D(target uint32, level int32, internalformat uint32, width int32, height int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexImage2D(gpCompressedTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func TexImage2D(target GLEnum, level int32, internalformat GLEnum, width, height, border int32, format, xtype GLEnum, pixels []float32) {\n\tgl.TexImage2D(uint32(target), level, int32(internalformat), width, height, border, uint32(format), uint32(xtype), unsafe.Pointer(&pixels[0]))\n}", "func CompressedTexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTexSubImage1D, 7, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(width), uintptr(format), uintptr(imageSize), uintptr(data), 0, 0)\n}", "func TexImage2D(target Enum, level int, width, height int, format Enum, ty Enum, data []byte) {\n\tp := unsafe.Pointer(nil)\n\tif len(data) > 0 {\n\t\tp = gl.Ptr(&data[0])\n\t}\n\tgl.TexImage2D(uint32(target), int32(level), int32(format), int32(width), int32(height), 0, uint32(format), uint32(ty), p)\n}", "func GetCompressedTexImage(target uint32, level int32, img unsafe.Pointer) {\n C.glowGetCompressedTexImage(gpGetCompressedTexImage, (C.GLenum)(target), (C.GLint)(level), img)\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexImage2D(gpTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func (debugging *debuggingOpenGL) TexImage2D(target uint32, level int32, internalFormat uint32, width int32, height int32,\n\tborder int32, format uint32, xtype uint32, pixels interface{}) {\n\tdebugging.recordEntry(\"TexImage2D\", target, level, internalFormat, width, height, border, format, xtype, pixels)\n\tdebugging.gl.TexImage2D(target, level, internalFormat, width, height, border, format, xtype, pixels)\n\tdebugging.recordExit(\"TexImage2D\")\n}", "func CompressedTexImage2D(target Enum, level int, internalformat Enum, width, height, border int, data []byte) {\n\tgl.CompressedTexImage2D(uint32(target), int32(level), uint32(internalformat), int32(width), int32(height), int32(border), int32(len(data)), gl.Ptr(data))\n}", "func CompressedTexImage2D(target GLEnum, level int32, internalformat GLEnum, width, height, border, imageSize int32, pixels []float32) {\n\tgl.CompressedTexImage2D(uint32(target), level, uint32(internalformat), width, height, border, imageSize, unsafe.Pointer(&pixels[0]))\n}", "func CompressedTexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexSubImage1D(gpCompressedTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexSubImage1D(gpCompressedTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexImage2D(gpTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexImage2D(gpTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CopyImageSubData(srcName uint32, srcTarget uint32, srcLevel int32, srcX int32, srcY int32, srcZ int32, dstName uint32, dstTarget uint32, dstLevel int32, dstX int32, dstY int32, dstZ int32, srcWidth int32, srcHeight int32, srcDepth int32) {\n\tC.glowCopyImageSubData(gpCopyImageSubData, (C.GLuint)(srcName), (C.GLenum)(srcTarget), (C.GLint)(srcLevel), (C.GLint)(srcX), (C.GLint)(srcY), (C.GLint)(srcZ), (C.GLuint)(dstName), (C.GLenum)(dstTarget), (C.GLint)(dstLevel), (C.GLint)(dstX), (C.GLint)(dstY), (C.GLint)(dstZ), (C.GLsizei)(srcWidth), (C.GLsizei)(srcHeight), (C.GLsizei)(srcDepth))\n}", "func CopyImageSubData(srcName uint32, srcTarget uint32, srcLevel int32, srcX int32, srcY int32, srcZ int32, dstName uint32, dstTarget uint32, dstLevel int32, dstX int32, dstY int32, dstZ int32, srcWidth int32, srcHeight int32, srcDepth int32) {\n\tC.glowCopyImageSubData(gpCopyImageSubData, (C.GLuint)(srcName), (C.GLenum)(srcTarget), (C.GLint)(srcLevel), (C.GLint)(srcX), (C.GLint)(srcY), (C.GLint)(srcZ), (C.GLuint)(dstName), (C.GLenum)(dstTarget), (C.GLint)(dstLevel), (C.GLint)(dstX), (C.GLint)(dstY), (C.GLint)(dstZ), (C.GLsizei)(srcWidth), (C.GLsizei)(srcHeight), (C.GLsizei)(srcDepth))\n}", "func CopyTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n C.glowCopyTexSubImage2D(gpCopyTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func (native *OpenGL) TexImage2D(target uint32, level int32, internalFormat uint32, width int32, height int32,\n\tborder int32, format uint32, xtype uint32, pixels interface{}) {\n\tptr, isPointer := pixels.(unsafe.Pointer)\n\tif isPointer {\n\t\tgl.TexImage2D(target, level, int32(internalFormat), width, height, border, format, xtype, ptr)\n\t} else {\n\t\tgl.TexImage2D(target, level, int32(internalFormat), width, height, border, format, xtype, gl.Ptr(pixels))\n\t}\n}", "func CompressedTexImage1D(target uint32, level int32, internalformat uint32, width int32, border int32, imageSize int32, data unsafe.Pointer) {\n C.glowCompressedTexImage1D(gpCompressedTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func CopyTexImage2D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, height int32, border int32) {\n C.glowCopyTexImage2D(gpCopyTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border))\n}", "func GetCompressedTexImage(target uint32, level int32, img unsafe.Pointer) {\n\tsyscall.Syscall(gpGetCompressedTexImage, 3, uintptr(target), uintptr(level), uintptr(img))\n}", "func CopyTexSubImage1D(target uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n C.glowCopyTexSubImage1D(gpCopyTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func (gl *WebGL) TexImage2D(target GLEnum, level int, internalFormat GLEnum, format GLEnum, texelType GLEnum, pixels interface{}) {\n\tgl.context.Call(\"texImage2D\", target, level, internalFormat, format, texelType, pixels)\n}", "func CopyTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n C.glowCopyTexSubImage3D(gpCopyTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CompressedTexImage3D(target uint32, level int32, internalformat uint32, width int32, height int32, depth int32, border int32, imageSize int32, data unsafe.Pointer) {\n C.glowCompressedTexImage3D(gpCompressedTexImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexImage3D(target uint32, level int32, internalformat uint32, width int32, height int32, depth int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTexImage3D, 9, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(width), uintptr(height), uintptr(depth), uintptr(border), uintptr(imageSize), uintptr(data))\n}", "func CompressedTexImage1D(target uint32, level int32, internalformat uint32, width int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTexImage1D, 7, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(width), uintptr(border), uintptr(imageSize), uintptr(data), 0, 0)\n}", "func BindImageTexture(unit uint32, texture uint32, level int32, layered bool, layer int32, access uint32, format uint32) {\n C.glowBindImageTexture(gpBindImageTexture, (C.GLuint)(unit), (C.GLuint)(texture), (C.GLint)(level), (C.GLboolean)(boolToInt(layered)), (C.GLint)(layer), (C.GLenum)(access), (C.GLenum)(format))\n}", "func CompressedTexImage2D(target Enum, level Int, internalformat Enum, width Sizei, height Sizei, border Int, imageSize Sizei, data unsafe.Pointer) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tclevel, _ := (C.GLint)(level), cgoAllocsUnknown\n\tcinternalformat, _ := (C.GLenum)(internalformat), cgoAllocsUnknown\n\tcwidth, _ := (C.GLsizei)(width), cgoAllocsUnknown\n\tcheight, _ := (C.GLsizei)(height), cgoAllocsUnknown\n\tcborder, _ := (C.GLint)(border), cgoAllocsUnknown\n\tcimageSize, _ := (C.GLsizei)(imageSize), cgoAllocsUnknown\n\tcdata, _ := (unsafe.Pointer)(unsafe.Pointer(data)), cgoAllocsUnknown\n\tC.glCompressedTexImage2D(ctarget, clevel, cinternalformat, cwidth, cheight, cborder, cimageSize, cdata)\n}", "func GetCompressedTexImage(target uint32, level int32, img unsafe.Pointer) {\n\tC.glowGetCompressedTexImage(gpGetCompressedTexImage, (C.GLenum)(target), (C.GLint)(level), img)\n}", "func GetCompressedTexImage(target uint32, level int32, img unsafe.Pointer) {\n\tC.glowGetCompressedTexImage(gpGetCompressedTexImage, (C.GLenum)(target), (C.GLint)(level), img)\n}", "func CopyTexImage2D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, height int32, border int32) {\n\tsyscall.Syscall9(gpCopyTexImage2D, 8, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(x), uintptr(y), uintptr(width), uintptr(height), uintptr(border), 0)\n}", "func (p *Alpha16) SubImage(r Rectangle) Image {\n\tr = r.Intersect(p.Rect)\n\t// If r1 and r2 are Rectangles, r1.Intersect(r2) is not guaranteed to be inside\n\t// either r1 or r2 if the intersection is empty. Without explicitly checking for\n\t// this, the Pix[i:] expression below can panic.\n\tif r.Empty() {\n\t\treturn &Alpha16{}\n\t}\n\ti := p.PixOffset(r.Min.X, r.Min.Y)\n\treturn &Alpha16{\n\t\tPix: p.Pix[i:],\n\t\tStride: p.Stride,\n\t\tRect: r,\n\t}\n}" ]
[ "0.7577563", "0.7577563", "0.75629306", "0.74470943", "0.74470943", "0.738315", "0.73312634", "0.73312634", "0.7266035", "0.712903", "0.7098043", "0.7098043", "0.68603545", "0.6716065", "0.6716065", "0.6694078", "0.66790736", "0.66790736", "0.66281074", "0.6611796", "0.6604542", "0.6604542", "0.6573335", "0.6573335", "0.65349364", "0.65143824", "0.6503476", "0.6503476", "0.64785737", "0.64575344", "0.64015985", "0.6389023", "0.6389023", "0.6337207", "0.6337207", "0.63337237", "0.63331234", "0.633243", "0.6303646", "0.6297663", "0.6297663", "0.62407726", "0.623749", "0.61958116", "0.61935586", "0.6189275", "0.61760587", "0.6137317", "0.6137317", "0.60946846", "0.6091771", "0.6091771", "0.606533", "0.6056275", "0.5942571", "0.59345835", "0.5905827", "0.5902369", "0.5887347", "0.5873099", "0.5873099", "0.5791345", "0.57883066", "0.57883066", "0.57866967", "0.573977", "0.57369906", "0.57369906", "0.57140154", "0.5700371", "0.56840825", "0.56737137", "0.56205994", "0.56186473", "0.560395", "0.55993176", "0.55798787", "0.55798787", "0.55315316", "0.55315316", "0.5530086", "0.5530086", "0.54770327", "0.54433256", "0.5348", "0.5305952", "0.5288515", "0.52676785", "0.52667224", "0.52619094", "0.52576673", "0.51913106", "0.5181854", "0.51725215", "0.5171566", "0.51681936", "0.51681936", "0.51529616", "0.5134202" ]
0.62119097
44
specify a threedimensional texture subimage in a compressed format
func CompressedTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) { C.glowCompressedTexSubImage3D(gpCompressedTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLsizei)(imageSize), data) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func CompressedTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage3D(gpCompressedTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage3D(gpCompressedTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall12(gpCompressedTextureSubImage3D, 11, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(imageSize), uintptr(data), 0)\n}", "func GetCompressedTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetCompressedTextureSubImage(gpGetCompressedTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLsizei)(bufSize), pixels)\n}", "func GetCompressedTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetCompressedTextureSubImage(gpGetCompressedTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLsizei)(bufSize), pixels)\n}", "func CompressedTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage2D(gpCompressedTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage2D(gpCompressedTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTextureSubImage2D, 9, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(width), uintptr(height), uintptr(format), uintptr(imageSize), uintptr(data))\n}", "func GetCompressedTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, bufSize int32, pixels unsafe.Pointer) {\n\tsyscall.Syscall12(gpGetCompressedTextureSubImage, 10, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(bufSize), uintptr(pixels), 0, 0)\n}", "func CompressedTextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTextureSubImage1D, 7, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(width), uintptr(format), uintptr(imageSize), uintptr(data), 0, 0)\n}", "func CompressedTextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage1D(gpCompressedTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage1D(gpCompressedTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func TextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall12(gpTextureSubImage3D, 11, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(xtype), uintptr(pixels), 0)\n}", "func TextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage3D(gpTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage3D(gpTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CopyTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTextureSubImage3D(gpCopyTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CopyTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTextureSubImage3D(gpCopyTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CopyTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n\tsyscall.Syscall9(gpCopyTextureSubImage3D, 9, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(x), uintptr(y), uintptr(width), uintptr(height))\n}", "func TextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTextureSubImage1D, 7, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(width), uintptr(format), uintptr(xtype), uintptr(pixels), 0, 0)\n}", "func TextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTextureSubImage2D, 9, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(width), uintptr(height), uintptr(format), uintptr(xtype), uintptr(pixels))\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexSubImage3D(gpTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func GetTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetTextureSubImage(gpGetTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), (C.GLsizei)(bufSize), pixels)\n}", "func GetTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetTextureSubImage(gpGetTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), (C.GLsizei)(bufSize), pixels)\n}", "func TextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage1D(gpTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage1D(gpTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall12(gpTexSubImage3D, 11, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(xtype), uintptr(pixels), 0)\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage3D(gpTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage3D(gpTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage2D(gpTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage2D(gpTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func GetTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, bufSize int32, pixels unsafe.Pointer) {\n\tsyscall.Syscall12(gpGetTextureSubImage, 12, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(xtype), uintptr(bufSize), uintptr(pixels))\n}", "func CopyTextureSubImage1D(texture uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tC.glowCopyTextureSubImage1D(gpCopyTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func CopyTextureSubImage1D(texture uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tC.glowCopyTextureSubImage1D(gpCopyTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func CompressedTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n C.glowCompressedTexSubImage2D(gpCompressedTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CopyTextureSubImage1D(texture uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tsyscall.Syscall6(gpCopyTextureSubImage1D, 6, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(x), uintptr(y), uintptr(width))\n}", "func CompressedTexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n C.glowCompressedTexSubImage1D(gpCompressedTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n C.glowCompressedTexSubImage3D(gpCompressedTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func GetCompressedTextureImage(texture uint32, level int32, bufSize int32, pixels unsafe.Pointer) {\n\tsyscall.Syscall6(gpGetCompressedTextureImage, 4, uintptr(texture), uintptr(level), uintptr(bufSize), uintptr(pixels), 0, 0)\n}", "func TexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexSubImage1D(gpTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func GetCompressedTextureImage(texture uint32, level int32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetCompressedTextureImage(gpGetCompressedTextureImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLsizei)(bufSize), pixels)\n}", "func GetCompressedTextureImage(texture uint32, level int32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetCompressedTextureImage(gpGetCompressedTextureImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLsizei)(bufSize), pixels)\n}", "func CompressedTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall12(gpCompressedTexSubImage3D, 11, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(imageSize), uintptr(data), 0)\n}", "func TexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexSubImage2D(gpTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CopyTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTextureSubImage2D(gpCopyTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CopyTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTextureSubImage2D(gpCopyTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CompressedTexImage2D(target uint32, level int32, internalformat uint32, width int32, height int32, border int32, imageSize int32, data unsafe.Pointer) {\n C.glowCompressedTexImage2D(gpCompressedTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func (tex Texture) Sub(ctx gl.Context, lvl int, width int, height int, data []byte) {\n\tctx.TexSubImage2D(gl.TEXTURE_2D, lvl, 0, 0, width, height, gl.RGBA, gl.UNSIGNED_BYTE, data)\n\tif lvl > 0 {\n\t\tctx.GenerateMipmap(gl.TEXTURE_2D)\n\t}\n}", "func CopyTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n\tsyscall.Syscall9(gpCopyTextureSubImage2D, 8, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(x), uintptr(y), uintptr(width), uintptr(height), 0)\n}", "func CompressedTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTexSubImage2D, 9, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(width), uintptr(height), uintptr(format), uintptr(imageSize), uintptr(data))\n}", "func TexSubImage2D(target Enum, level int, x, y, width, height int, format, ty Enum, data []byte) {\n\tgl.TexSubImage2D(uint32(target), int32(level), int32(x), int32(y), int32(width), int32(height), uint32(format), uint32(ty), gl.Ptr(&data[0]))\n}", "func CompressedTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexSubImage2D(gpCompressedTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexSubImage2D(gpCompressedTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func TexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage2D(gpTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage2D(gpTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CompressedTexSubImage2D(target GLEnum, level, xoffset, yoffset, width, height int32, format GLEnum, imageSize int32, pixels []float32) {\n\tgl.CompressedTexSubImage2D(uint32(target), level, xoffset, yoffset, width, height, uint32(format), imageSize, unsafe.Pointer(&pixels[0]))\n}", "func TexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage1D(gpTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage1D(gpTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTexSubImage2D, 9, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(width), uintptr(height), uintptr(format), uintptr(xtype), uintptr(pixels))\n}", "func CompressedTexImage2D(target uint32, level int32, internalformat uint32, width int32, height int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTexImage2D, 8, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(width), uintptr(height), uintptr(border), uintptr(imageSize), uintptr(data), 0)\n}", "func TexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTexSubImage1D, 7, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(width), uintptr(format), uintptr(xtype), uintptr(pixels), 0, 0)\n}", "func TexSubImage2D(target GLEnum, level, xoffset, yoffset, width, height int32, format, xtype GLEnum, pixels []float32) {\n\tgl.TexSubImage2D(uint32(target), level, xoffset, yoffset, width, height, uint32(format), uint32(xtype), unsafe.Pointer(&pixels[0]))\n}", "func GetCompressedTexImage(target uint32, level int32, img unsafe.Pointer) {\n C.glowGetCompressedTexImage(gpGetCompressedTexImage, (C.GLenum)(target), (C.GLint)(level), img)\n}", "func CompressedTexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTexSubImage1D, 7, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(width), uintptr(format), uintptr(imageSize), uintptr(data), 0, 0)\n}", "func CompressedTexSubImage2D(target Enum, level, xoffset, yoffset, width, height int, format Enum, data []byte) {\n\tgl.CompressedTexSubImage2D(uint32(target), int32(level), int32(xoffset), int32(yoffset), int32(width), int32(height), uint32(format), int32(len(data)), gl.Ptr(data))\n}", "func CompressedTexImage3D(target uint32, level int32, internalformat uint32, width int32, height int32, depth int32, border int32, imageSize int32, data unsafe.Pointer) {\n C.glowCompressedTexImage3D(gpCompressedTexImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexSubImage1D(gpCompressedTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexSubImage1D(gpCompressedTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CopyImageSubData(srcName uint32, srcTarget uint32, srcLevel int32, srcX int32, srcY int32, srcZ int32, dstName uint32, dstTarget uint32, dstLevel int32, dstX int32, dstY int32, dstZ int32, srcWidth int32, srcHeight int32, srcDepth int32) {\n C.glowCopyImageSubData(gpCopyImageSubData, (C.GLuint)(srcName), (C.GLenum)(srcTarget), (C.GLint)(srcLevel), (C.GLint)(srcX), (C.GLint)(srcY), (C.GLint)(srcZ), (C.GLuint)(dstName), (C.GLenum)(dstTarget), (C.GLint)(dstLevel), (C.GLint)(dstX), (C.GLint)(dstY), (C.GLint)(dstZ), (C.GLsizei)(srcWidth), (C.GLsizei)(srcHeight), (C.GLsizei)(srcDepth))\n}", "func CompressedTexImage2D(target uint32, level int32, internalformat uint32, width int32, height int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexImage2D(gpCompressedTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexImage2D(target uint32, level int32, internalformat uint32, width int32, height int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexImage2D(gpCompressedTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexImage1D(target uint32, level int32, internalformat uint32, width int32, border int32, imageSize int32, data unsafe.Pointer) {\n C.glowCompressedTexImage1D(gpCompressedTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexImage3D(target uint32, level int32, internalformat uint32, width int32, height int32, depth int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTexImage3D, 9, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(width), uintptr(height), uintptr(depth), uintptr(border), uintptr(imageSize), uintptr(data))\n}", "func TexImage2D(target GLEnum, level int32, internalformat GLEnum, width, height, border int32, format, xtype GLEnum, pixels []float32) {\n\tgl.TexImage2D(uint32(target), level, int32(internalformat), width, height, border, uint32(format), uint32(xtype), unsafe.Pointer(&pixels[0]))\n}", "func TexImage2D(target Enum, level int, width, height int, format Enum, ty Enum, data []byte) {\n\tp := unsafe.Pointer(nil)\n\tif len(data) > 0 {\n\t\tp = gl.Ptr(&data[0])\n\t}\n\tgl.TexImage2D(uint32(target), int32(level), int32(format), int32(width), int32(height), 0, uint32(format), uint32(ty), p)\n}", "func CompressedTexImage2D(target Enum, level int, internalformat Enum, width, height, border int, data []byte) {\n\tgl.CompressedTexImage2D(uint32(target), int32(level), uint32(internalformat), int32(width), int32(height), int32(border), int32(len(data)), gl.Ptr(data))\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTexImage2D, 9, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(width), uintptr(height), uintptr(border), uintptr(format), uintptr(xtype), uintptr(pixels))\n}", "func CompressedTexImage1D(target uint32, level int32, internalformat uint32, width int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTexImage1D, 7, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(width), uintptr(border), uintptr(imageSize), uintptr(data), 0, 0)\n}", "func CompressedTexImage2D(target GLEnum, level int32, internalformat GLEnum, width, height, border, imageSize int32, pixels []float32) {\n\tgl.CompressedTexImage2D(uint32(target), level, uint32(internalformat), width, height, border, imageSize, unsafe.Pointer(&pixels[0]))\n}", "func TexSubImage2D(target Enum, level Int, xoffset Int, yoffset Int, width Sizei, height Sizei, format Enum, kind Enum, pixels unsafe.Pointer) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tclevel, _ := (C.GLint)(level), cgoAllocsUnknown\n\tcxoffset, _ := (C.GLint)(xoffset), cgoAllocsUnknown\n\tcyoffset, _ := (C.GLint)(yoffset), cgoAllocsUnknown\n\tcwidth, _ := (C.GLsizei)(width), cgoAllocsUnknown\n\tcheight, _ := (C.GLsizei)(height), cgoAllocsUnknown\n\tcformat, _ := (C.GLenum)(format), cgoAllocsUnknown\n\tckind, _ := (C.GLenum)(kind), cgoAllocsUnknown\n\tcpixels, _ := (unsafe.Pointer)(unsafe.Pointer(pixels)), cgoAllocsUnknown\n\tC.glTexSubImage2D(ctarget, clevel, cxoffset, cyoffset, cwidth, cheight, cformat, ckind, cpixels)\n}", "func CompressedTexImage3D(target uint32, level int32, internalformat uint32, width int32, height int32, depth int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexImage3D(gpCompressedTexImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexImage3D(target uint32, level int32, internalformat uint32, width int32, height int32, depth int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexImage3D(gpCompressedTexImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func CopyImageSubData(srcName uint32, srcTarget uint32, srcLevel int32, srcX int32, srcY int32, srcZ int32, dstName uint32, dstTarget uint32, dstLevel int32, dstX int32, dstY int32, dstZ int32, srcWidth int32, srcHeight int32, srcDepth int32) {\n\tC.glowCopyImageSubData(gpCopyImageSubData, (C.GLuint)(srcName), (C.GLenum)(srcTarget), (C.GLint)(srcLevel), (C.GLint)(srcX), (C.GLint)(srcY), (C.GLint)(srcZ), (C.GLuint)(dstName), (C.GLenum)(dstTarget), (C.GLint)(dstLevel), (C.GLint)(dstX), (C.GLint)(dstY), (C.GLint)(dstZ), (C.GLsizei)(srcWidth), (C.GLsizei)(srcHeight), (C.GLsizei)(srcDepth))\n}", "func CopyImageSubData(srcName uint32, srcTarget uint32, srcLevel int32, srcX int32, srcY int32, srcZ int32, dstName uint32, dstTarget uint32, dstLevel int32, dstX int32, dstY int32, dstZ int32, srcWidth int32, srcHeight int32, srcDepth int32) {\n\tC.glowCopyImageSubData(gpCopyImageSubData, (C.GLuint)(srcName), (C.GLenum)(srcTarget), (C.GLint)(srcLevel), (C.GLint)(srcX), (C.GLint)(srcY), (C.GLint)(srcZ), (C.GLuint)(dstName), (C.GLenum)(dstTarget), (C.GLint)(dstLevel), (C.GLint)(dstX), (C.GLint)(dstY), (C.GLint)(dstZ), (C.GLsizei)(srcWidth), (C.GLsizei)(srcHeight), (C.GLsizei)(srcDepth))\n}", "func CompressedTexSubImage2D(target Enum, level Int, xoffset Int, yoffset Int, width Sizei, height Sizei, format Enum, imageSize Sizei, data unsafe.Pointer) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tclevel, _ := (C.GLint)(level), cgoAllocsUnknown\n\tcxoffset, _ := (C.GLint)(xoffset), cgoAllocsUnknown\n\tcyoffset, _ := (C.GLint)(yoffset), cgoAllocsUnknown\n\tcwidth, _ := (C.GLsizei)(width), cgoAllocsUnknown\n\tcheight, _ := (C.GLsizei)(height), cgoAllocsUnknown\n\tcformat, _ := (C.GLenum)(format), cgoAllocsUnknown\n\tcimageSize, _ := (C.GLsizei)(imageSize), cgoAllocsUnknown\n\tcdata, _ := (unsafe.Pointer)(unsafe.Pointer(data)), cgoAllocsUnknown\n\tC.glCompressedTexSubImage2D(ctarget, clevel, cxoffset, cyoffset, cwidth, cheight, cformat, cimageSize, cdata)\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexImage2D(gpTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexImage3D(target uint32, level int32, internalformat int32, width int32, height int32, depth int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall12(gpTexImage3D, 10, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(width), uintptr(height), uintptr(depth), uintptr(border), uintptr(format), uintptr(xtype), uintptr(pixels), 0, 0)\n}", "func GetCompressedTexImage(target uint32, level int32, img unsafe.Pointer) {\n\tsyscall.Syscall(gpGetCompressedTexImage, 3, uintptr(target), uintptr(level), uintptr(img))\n}", "func (debugging *debuggingOpenGL) TexImage2D(target uint32, level int32, internalFormat uint32, width int32, height int32,\n\tborder int32, format uint32, xtype uint32, pixels interface{}) {\n\tdebugging.recordEntry(\"TexImage2D\", target, level, internalFormat, width, height, border, format, xtype, pixels)\n\tdebugging.gl.TexImage2D(target, level, internalFormat, width, height, border, format, xtype, pixels)\n\tdebugging.recordExit(\"TexImage2D\")\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexImage2D(gpTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexImage2D(gpTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CopyTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n C.glowCopyTexSubImage3D(gpCopyTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func GetCompressedTexImage(target uint32, level int32, img unsafe.Pointer) {\n\tC.glowGetCompressedTexImage(gpGetCompressedTexImage, (C.GLenum)(target), (C.GLint)(level), img)\n}", "func GetCompressedTexImage(target uint32, level int32, img unsafe.Pointer) {\n\tC.glowGetCompressedTexImage(gpGetCompressedTexImage, (C.GLenum)(target), (C.GLint)(level), img)\n}", "func TexImage1D(target uint32, level int32, internalformat int32, width int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTexImage1D, 8, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(width), uintptr(border), uintptr(format), uintptr(xtype), uintptr(pixels), 0)\n}", "func TexImage3D(target uint32, level int32, internalformat int32, width int32, height int32, depth int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexImage3D(gpTexImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CompressedTexImage1D(target uint32, level int32, internalformat uint32, width int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexImage1D(gpCompressedTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexImage1D(target uint32, level int32, internalformat uint32, width int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexImage1D(gpCompressedTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func TexImage3D(target uint32, level int32, internalformat int32, width int32, height int32, depth int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexImage3D(gpTexImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexImage3D(target uint32, level int32, internalformat int32, width int32, height int32, depth int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexImage3D(gpTexImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}" ]
[ "0.74802285", "0.74802285", "0.7413762", "0.726753", "0.726753", "0.72593474", "0.72593474", "0.7232897", "0.7199341", "0.71802086", "0.71552026", "0.71552026", "0.6744676", "0.667433", "0.667433", "0.6587511", "0.6587511", "0.6553164", "0.65196425", "0.63975227", "0.6391272", "0.6342379", "0.6342379", "0.6335705", "0.6335705", "0.63193494", "0.6305585", "0.6305585", "0.6284242", "0.6284242", "0.6277623", "0.6271112", "0.6271112", "0.62583905", "0.62547237", "0.62024236", "0.61768454", "0.61734706", "0.6142903", "0.6101152", "0.6101152", "0.608834", "0.6088192", "0.6079898", "0.6079898", "0.60359746", "0.6034976", "0.6015362", "0.6014512", "0.59687316", "0.5948147", "0.5948147", "0.5918612", "0.5918612", "0.59132814", "0.58945316", "0.58945316", "0.5894125", "0.5861998", "0.5861822", "0.5839391", "0.58344233", "0.57997257", "0.57462", "0.5737097", "0.5725774", "0.5725774", "0.57246256", "0.5715732", "0.5715732", "0.5699877", "0.56535393", "0.55589014", "0.55479765", "0.55442345", "0.5522677", "0.55188686", "0.5493213", "0.5491885", "0.54781926", "0.54781926", "0.54684263", "0.54684263", "0.5441828", "0.54332495", "0.541208", "0.54057884", "0.53769135", "0.5370847", "0.5370847", "0.5363173", "0.534126", "0.534126", "0.5321106", "0.5287312", "0.5275723", "0.5275723", "0.5232185", "0.5232185" ]
0.6031571
48
specify a onedimensional texture subimage in a compressed format
func CompressedTextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) { C.glowCompressedTextureSubImage1D(gpCompressedTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLsizei)(imageSize), data) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func CompressedTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage3D(gpCompressedTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage3D(gpCompressedTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func GetCompressedTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetCompressedTextureSubImage(gpGetCompressedTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLsizei)(bufSize), pixels)\n}", "func GetCompressedTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetCompressedTextureSubImage(gpGetCompressedTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLsizei)(bufSize), pixels)\n}", "func CompressedTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall12(gpCompressedTextureSubImage3D, 11, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(imageSize), uintptr(data), 0)\n}", "func CompressedTextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTextureSubImage1D, 7, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(width), uintptr(format), uintptr(imageSize), uintptr(data), 0, 0)\n}", "func CompressedTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage2D(gpCompressedTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage2D(gpCompressedTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTextureSubImage2D, 9, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(width), uintptr(height), uintptr(format), uintptr(imageSize), uintptr(data))\n}", "func GetCompressedTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, bufSize int32, pixels unsafe.Pointer) {\n\tsyscall.Syscall12(gpGetCompressedTextureSubImage, 10, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(bufSize), uintptr(pixels), 0, 0)\n}", "func TextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTextureSubImage1D, 7, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(width), uintptr(format), uintptr(xtype), uintptr(pixels), 0, 0)\n}", "func TextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall12(gpTextureSubImage3D, 11, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(xtype), uintptr(pixels), 0)\n}", "func TextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage3D(gpTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage3D(gpTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTextureSubImage2D, 9, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(width), uintptr(height), uintptr(format), uintptr(xtype), uintptr(pixels))\n}", "func CopyTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTextureSubImage3D(gpCopyTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CopyTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTextureSubImage3D(gpCopyTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func TextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage1D(gpTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage1D(gpTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func GetTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetTextureSubImage(gpGetTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), (C.GLsizei)(bufSize), pixels)\n}", "func GetTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetTextureSubImage(gpGetTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), (C.GLsizei)(bufSize), pixels)\n}", "func CopyTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n\tsyscall.Syscall9(gpCopyTextureSubImage3D, 9, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(x), uintptr(y), uintptr(width), uintptr(height))\n}", "func CompressedTexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n C.glowCompressedTexSubImage1D(gpCompressedTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n C.glowCompressedTexSubImage2D(gpCompressedTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func GetTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, bufSize int32, pixels unsafe.Pointer) {\n\tsyscall.Syscall12(gpGetTextureSubImage, 12, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(xtype), uintptr(bufSize), uintptr(pixels))\n}", "func (tex Texture) Sub(ctx gl.Context, lvl int, width int, height int, data []byte) {\n\tctx.TexSubImage2D(gl.TEXTURE_2D, lvl, 0, 0, width, height, gl.RGBA, gl.UNSIGNED_BYTE, data)\n\tif lvl > 0 {\n\t\tctx.GenerateMipmap(gl.TEXTURE_2D)\n\t}\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexSubImage3D(gpTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CopyTextureSubImage1D(texture uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tsyscall.Syscall6(gpCopyTextureSubImage1D, 6, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(x), uintptr(y), uintptr(width))\n}", "func GetCompressedTextureImage(texture uint32, level int32, bufSize int32, pixels unsafe.Pointer) {\n\tsyscall.Syscall6(gpGetCompressedTextureImage, 4, uintptr(texture), uintptr(level), uintptr(bufSize), uintptr(pixels), 0, 0)\n}", "func CopyTextureSubImage1D(texture uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tC.glowCopyTextureSubImage1D(gpCopyTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func CopyTextureSubImage1D(texture uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tC.glowCopyTextureSubImage1D(gpCopyTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func TextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage2D(gpTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage2D(gpTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexSubImage1D(gpTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func GetCompressedTextureImage(texture uint32, level int32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetCompressedTextureImage(gpGetCompressedTextureImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLsizei)(bufSize), pixels)\n}", "func GetCompressedTextureImage(texture uint32, level int32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetCompressedTextureImage(gpGetCompressedTextureImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLsizei)(bufSize), pixels)\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall12(gpTexSubImage3D, 11, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(xtype), uintptr(pixels), 0)\n}", "func TexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexSubImage2D(gpTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage3D(gpTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage3D(gpTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CompressedTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n C.glowCompressedTexSubImage3D(gpCompressedTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexImage2D(target uint32, level int32, internalformat uint32, width int32, height int32, border int32, imageSize int32, data unsafe.Pointer) {\n C.glowCompressedTexImage2D(gpCompressedTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTexSubImage2D, 9, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(width), uintptr(height), uintptr(format), uintptr(imageSize), uintptr(data))\n}", "func CompressedTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall12(gpCompressedTexSubImage3D, 11, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(imageSize), uintptr(data), 0)\n}", "func CompressedTexSubImage2D(target GLEnum, level, xoffset, yoffset, width, height int32, format GLEnum, imageSize int32, pixels []float32) {\n\tgl.CompressedTexSubImage2D(uint32(target), level, xoffset, yoffset, width, height, uint32(format), imageSize, unsafe.Pointer(&pixels[0]))\n}", "func CompressedTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexSubImage2D(gpCompressedTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexSubImage2D(gpCompressedTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CopyTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTextureSubImage2D(gpCopyTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CopyTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTextureSubImage2D(gpCopyTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CompressedTexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTexSubImage1D, 7, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(width), uintptr(format), uintptr(imageSize), uintptr(data), 0, 0)\n}", "func TexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTexSubImage1D, 7, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(width), uintptr(format), uintptr(xtype), uintptr(pixels), 0, 0)\n}", "func CompressedTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexSubImage3D(gpCompressedTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexSubImage3D(gpCompressedTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CopyTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n\tsyscall.Syscall9(gpCopyTextureSubImage2D, 8, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(x), uintptr(y), uintptr(width), uintptr(height), 0)\n}", "func CompressedTexImage2D(target uint32, level int32, internalformat uint32, width int32, height int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTexImage2D, 8, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(width), uintptr(height), uintptr(border), uintptr(imageSize), uintptr(data), 0)\n}", "func GetCompressedTexImage(target uint32, level int32, img unsafe.Pointer) {\n C.glowGetCompressedTexImage(gpGetCompressedTexImage, (C.GLenum)(target), (C.GLint)(level), img)\n}", "func TexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage1D(gpTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage1D(gpTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTexSubImage2D, 9, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(width), uintptr(height), uintptr(format), uintptr(xtype), uintptr(pixels))\n}", "func TexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage2D(gpTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage2D(gpTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage2D(target Enum, level int, x, y, width, height int, format, ty Enum, data []byte) {\n\tgl.TexSubImage2D(uint32(target), int32(level), int32(x), int32(y), int32(width), int32(height), uint32(format), uint32(ty), gl.Ptr(&data[0]))\n}", "func CompressedTexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexSubImage1D(gpCompressedTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexSubImage1D(gpCompressedTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexImage1D(target uint32, level int32, internalformat uint32, width int32, border int32, imageSize int32, data unsafe.Pointer) {\n C.glowCompressedTexImage1D(gpCompressedTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func CopyImageSubData(srcName uint32, srcTarget uint32, srcLevel int32, srcX int32, srcY int32, srcZ int32, dstName uint32, dstTarget uint32, dstLevel int32, dstX int32, dstY int32, dstZ int32, srcWidth int32, srcHeight int32, srcDepth int32) {\n C.glowCopyImageSubData(gpCopyImageSubData, (C.GLuint)(srcName), (C.GLenum)(srcTarget), (C.GLint)(srcLevel), (C.GLint)(srcX), (C.GLint)(srcY), (C.GLint)(srcZ), (C.GLuint)(dstName), (C.GLenum)(dstTarget), (C.GLint)(dstLevel), (C.GLint)(dstX), (C.GLint)(dstY), (C.GLint)(dstZ), (C.GLsizei)(srcWidth), (C.GLsizei)(srcHeight), (C.GLsizei)(srcDepth))\n}", "func TexSubImage2D(target GLEnum, level, xoffset, yoffset, width, height int32, format, xtype GLEnum, pixels []float32) {\n\tgl.TexSubImage2D(uint32(target), level, xoffset, yoffset, width, height, uint32(format), uint32(xtype), unsafe.Pointer(&pixels[0]))\n}", "func CompressedTexSubImage2D(target Enum, level, xoffset, yoffset, width, height int, format Enum, data []byte) {\n\tgl.CompressedTexSubImage2D(uint32(target), int32(level), int32(xoffset), int32(yoffset), int32(width), int32(height), uint32(format), int32(len(data)), gl.Ptr(data))\n}", "func CompressedTexImage2D(target uint32, level int32, internalformat uint32, width int32, height int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexImage2D(gpCompressedTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexImage2D(target uint32, level int32, internalformat uint32, width int32, height int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexImage2D(gpCompressedTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexImage1D(target uint32, level int32, internalformat uint32, width int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTexImage1D, 7, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(width), uintptr(border), uintptr(imageSize), uintptr(data), 0, 0)\n}", "func CompressedTexImage3D(target uint32, level int32, internalformat uint32, width int32, height int32, depth int32, border int32, imageSize int32, data unsafe.Pointer) {\n C.glowCompressedTexImage3D(gpCompressedTexImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexImage2D(target Enum, level int, internalformat Enum, width, height, border int, data []byte) {\n\tgl.CompressedTexImage2D(uint32(target), int32(level), uint32(internalformat), int32(width), int32(height), int32(border), int32(len(data)), gl.Ptr(data))\n}", "func CompressedTexImage2D(target GLEnum, level int32, internalformat GLEnum, width, height, border, imageSize int32, pixels []float32) {\n\tgl.CompressedTexImage2D(uint32(target), level, uint32(internalformat), width, height, border, imageSize, unsafe.Pointer(&pixels[0]))\n}", "func CopyImageSubData(srcName uint32, srcTarget uint32, srcLevel int32, srcX int32, srcY int32, srcZ int32, dstName uint32, dstTarget uint32, dstLevel int32, dstX int32, dstY int32, dstZ int32, srcWidth int32, srcHeight int32, srcDepth int32) {\n\tC.glowCopyImageSubData(gpCopyImageSubData, (C.GLuint)(srcName), (C.GLenum)(srcTarget), (C.GLint)(srcLevel), (C.GLint)(srcX), (C.GLint)(srcY), (C.GLint)(srcZ), (C.GLuint)(dstName), (C.GLenum)(dstTarget), (C.GLint)(dstLevel), (C.GLint)(dstX), (C.GLint)(dstY), (C.GLint)(dstZ), (C.GLsizei)(srcWidth), (C.GLsizei)(srcHeight), (C.GLsizei)(srcDepth))\n}", "func CopyImageSubData(srcName uint32, srcTarget uint32, srcLevel int32, srcX int32, srcY int32, srcZ int32, dstName uint32, dstTarget uint32, dstLevel int32, dstX int32, dstY int32, dstZ int32, srcWidth int32, srcHeight int32, srcDepth int32) {\n\tC.glowCopyImageSubData(gpCopyImageSubData, (C.GLuint)(srcName), (C.GLenum)(srcTarget), (C.GLint)(srcLevel), (C.GLint)(srcX), (C.GLint)(srcY), (C.GLint)(srcZ), (C.GLuint)(dstName), (C.GLenum)(dstTarget), (C.GLint)(dstLevel), (C.GLint)(dstX), (C.GLint)(dstY), (C.GLint)(dstZ), (C.GLsizei)(srcWidth), (C.GLsizei)(srcHeight), (C.GLsizei)(srcDepth))\n}", "func TexImage2D(target GLEnum, level int32, internalformat GLEnum, width, height, border int32, format, xtype GLEnum, pixels []float32) {\n\tgl.TexImage2D(uint32(target), level, int32(internalformat), width, height, border, uint32(format), uint32(xtype), unsafe.Pointer(&pixels[0]))\n}", "func CompressedTexImage3D(target uint32, level int32, internalformat uint32, width int32, height int32, depth int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTexImage3D, 9, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(width), uintptr(height), uintptr(depth), uintptr(border), uintptr(imageSize), uintptr(data))\n}", "func GetCompressedTexImage(target uint32, level int32, img unsafe.Pointer) {\n\tsyscall.Syscall(gpGetCompressedTexImage, 3, uintptr(target), uintptr(level), uintptr(img))\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTexImage2D, 9, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(width), uintptr(height), uintptr(border), uintptr(format), uintptr(xtype), uintptr(pixels))\n}", "func CompressedTexSubImage2D(target Enum, level Int, xoffset Int, yoffset Int, width Sizei, height Sizei, format Enum, imageSize Sizei, data unsafe.Pointer) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tclevel, _ := (C.GLint)(level), cgoAllocsUnknown\n\tcxoffset, _ := (C.GLint)(xoffset), cgoAllocsUnknown\n\tcyoffset, _ := (C.GLint)(yoffset), cgoAllocsUnknown\n\tcwidth, _ := (C.GLsizei)(width), cgoAllocsUnknown\n\tcheight, _ := (C.GLsizei)(height), cgoAllocsUnknown\n\tcformat, _ := (C.GLenum)(format), cgoAllocsUnknown\n\tcimageSize, _ := (C.GLsizei)(imageSize), cgoAllocsUnknown\n\tcdata, _ := (unsafe.Pointer)(unsafe.Pointer(data)), cgoAllocsUnknown\n\tC.glCompressedTexSubImage2D(ctarget, clevel, cxoffset, cyoffset, cwidth, cheight, cformat, cimageSize, cdata)\n}", "func TexSubImage2D(target Enum, level Int, xoffset Int, yoffset Int, width Sizei, height Sizei, format Enum, kind Enum, pixels unsafe.Pointer) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tclevel, _ := (C.GLint)(level), cgoAllocsUnknown\n\tcxoffset, _ := (C.GLint)(xoffset), cgoAllocsUnknown\n\tcyoffset, _ := (C.GLint)(yoffset), cgoAllocsUnknown\n\tcwidth, _ := (C.GLsizei)(width), cgoAllocsUnknown\n\tcheight, _ := (C.GLsizei)(height), cgoAllocsUnknown\n\tcformat, _ := (C.GLenum)(format), cgoAllocsUnknown\n\tckind, _ := (C.GLenum)(kind), cgoAllocsUnknown\n\tcpixels, _ := (unsafe.Pointer)(unsafe.Pointer(pixels)), cgoAllocsUnknown\n\tC.glTexSubImage2D(ctarget, clevel, cxoffset, cyoffset, cwidth, cheight, cformat, ckind, cpixels)\n}", "func GetCompressedTexImage(target uint32, level int32, img unsafe.Pointer) {\n\tC.glowGetCompressedTexImage(gpGetCompressedTexImage, (C.GLenum)(target), (C.GLint)(level), img)\n}", "func GetCompressedTexImage(target uint32, level int32, img unsafe.Pointer) {\n\tC.glowGetCompressedTexImage(gpGetCompressedTexImage, (C.GLenum)(target), (C.GLint)(level), img)\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexImage2D(gpTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexImage1D(target uint32, level int32, internalformat int32, width int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTexImage1D, 8, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(width), uintptr(border), uintptr(format), uintptr(xtype), uintptr(pixels), 0)\n}", "func (debugging *debuggingOpenGL) TexImage2D(target uint32, level int32, internalFormat uint32, width int32, height int32,\n\tborder int32, format uint32, xtype uint32, pixels interface{}) {\n\tdebugging.recordEntry(\"TexImage2D\", target, level, internalFormat, width, height, border, format, xtype, pixels)\n\tdebugging.gl.TexImage2D(target, level, internalFormat, width, height, border, format, xtype, pixels)\n\tdebugging.recordExit(\"TexImage2D\")\n}", "func CompressedTexImage1D(target uint32, level int32, internalformat uint32, width int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexImage1D(gpCompressedTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexImage1D(target uint32, level int32, internalformat uint32, width int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexImage1D(gpCompressedTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func TexImage2D(target Enum, level int, width, height int, format Enum, ty Enum, data []byte) {\n\tp := unsafe.Pointer(nil)\n\tif len(data) > 0 {\n\t\tp = gl.Ptr(&data[0])\n\t}\n\tgl.TexImage2D(uint32(target), int32(level), int32(format), int32(width), int32(height), 0, uint32(format), uint32(ty), p)\n}", "func (p *Alpha16) SubImage(r Rectangle) Image {\n\tr = r.Intersect(p.Rect)\n\t// If r1 and r2 are Rectangles, r1.Intersect(r2) is not guaranteed to be inside\n\t// either r1 or r2 if the intersection is empty. Without explicitly checking for\n\t// this, the Pix[i:] expression below can panic.\n\tif r.Empty() {\n\t\treturn &Alpha16{}\n\t}\n\ti := p.PixOffset(r.Min.X, r.Min.Y)\n\treturn &Alpha16{\n\t\tPix: p.Pix[i:],\n\t\tStride: p.Stride,\n\t\tRect: r,\n\t}\n}", "func CompressedTexImage3D(target uint32, level int32, internalformat uint32, width int32, height int32, depth int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexImage3D(gpCompressedTexImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexImage3D(target uint32, level int32, internalformat uint32, width int32, height int32, depth int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexImage3D(gpCompressedTexImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func BindImageTexture(unit uint32, texture uint32, level int32, layered bool, layer int32, access uint32, format uint32) {\n C.glowBindImageTexture(gpBindImageTexture, (C.GLuint)(unit), (C.GLuint)(texture), (C.GLint)(level), (C.GLboolean)(boolToInt(layered)), (C.GLint)(layer), (C.GLenum)(access), (C.GLenum)(format))\n}", "func CopyTexSubImage1D(target uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n C.glowCopyTexSubImage1D(gpCopyTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexImage2D(gpTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexImage2D(gpTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CopyTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n C.glowCopyTexSubImage3D(gpCopyTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func TexImage1D(target uint32, level int32, internalformat int32, width int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexImage1D(gpTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}" ]
[ "0.7192947", "0.7192947", "0.714907", "0.714907", "0.71469426", "0.71051484", "0.70993614", "0.70993614", "0.7078862", "0.7078731", "0.6472296", "0.6445187", "0.6333098", "0.6333098", "0.62800336", "0.62663424", "0.62663424", "0.6255392", "0.6255392", "0.6253487", "0.6253487", "0.62457734", "0.62220424", "0.6217866", "0.6201825", "0.6165179", "0.6156424", "0.61500704", "0.61478186", "0.6143618", "0.6143618", "0.61274195", "0.61274195", "0.6122326", "0.60680825", "0.60680825", "0.6065709", "0.6025231", "0.6015744", "0.6015744", "0.5994164", "0.5986875", "0.5983162", "0.5933607", "0.59113497", "0.58929884", "0.58929884", "0.58819646", "0.58819646", "0.58554894", "0.585069", "0.5849909", "0.5849909", "0.58389384", "0.5828439", "0.5823542", "0.581819", "0.581819", "0.5812524", "0.57810426", "0.57810426", "0.57760864", "0.5763505", "0.5763505", "0.5720026", "0.5705759", "0.5698424", "0.5675976", "0.5655775", "0.5655775", "0.55738425", "0.5500198", "0.54954314", "0.5485873", "0.5456925", "0.5456925", "0.5454037", "0.5450141", "0.5414742", "0.5398002", "0.5386937", "0.53510964", "0.53356415", "0.53356415", "0.5328699", "0.53284675", "0.53202266", "0.53128016", "0.53128016", "0.5308011", "0.52914625", "0.52497447", "0.52497447", "0.52164364", "0.52133113", "0.5208732", "0.5208732", "0.5153347", "0.5121519" ]
0.70817184
9
specify a twodimensional texture subimage in a compressed format
func CompressedTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) { C.glowCompressedTextureSubImage2D(gpCompressedTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLsizei)(imageSize), data) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func CompressedTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTextureSubImage2D, 9, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(width), uintptr(height), uintptr(format), uintptr(imageSize), uintptr(data))\n}", "func GetCompressedTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetCompressedTextureSubImage(gpGetCompressedTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLsizei)(bufSize), pixels)\n}", "func GetCompressedTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetCompressedTextureSubImage(gpGetCompressedTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLsizei)(bufSize), pixels)\n}", "func GetCompressedTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, bufSize int32, pixels unsafe.Pointer) {\n\tsyscall.Syscall12(gpGetCompressedTextureSubImage, 10, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(bufSize), uintptr(pixels), 0, 0)\n}", "func CompressedTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage3D(gpCompressedTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage3D(gpCompressedTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall12(gpCompressedTextureSubImage3D, 11, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(imageSize), uintptr(data), 0)\n}", "func CompressedTextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTextureSubImage1D, 7, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(width), uintptr(format), uintptr(imageSize), uintptr(data), 0, 0)\n}", "func CompressedTextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage1D(gpCompressedTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage1D(gpCompressedTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func TextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTextureSubImage2D, 9, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(width), uintptr(height), uintptr(format), uintptr(xtype), uintptr(pixels))\n}", "func TextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage2D(gpTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage2D(gpTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall12(gpTextureSubImage3D, 11, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(xtype), uintptr(pixels), 0)\n}", "func GetTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetTextureSubImage(gpGetTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), (C.GLsizei)(bufSize), pixels)\n}", "func GetTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetTextureSubImage(gpGetTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), (C.GLsizei)(bufSize), pixels)\n}", "func GetTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, bufSize int32, pixels unsafe.Pointer) {\n\tsyscall.Syscall12(gpGetTextureSubImage, 12, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(xtype), uintptr(bufSize), uintptr(pixels))\n}", "func TextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTextureSubImage1D, 7, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(width), uintptr(format), uintptr(xtype), uintptr(pixels), 0, 0)\n}", "func TextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage3D(gpTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage3D(gpTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CopyTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTextureSubImage3D(gpCopyTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CopyTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTextureSubImage3D(gpCopyTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CopyTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n\tsyscall.Syscall9(gpCopyTextureSubImage3D, 9, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(x), uintptr(y), uintptr(width), uintptr(height))\n}", "func CompressedTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n C.glowCompressedTexSubImage2D(gpCompressedTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CopyTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTextureSubImage2D(gpCopyTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CopyTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTextureSubImage2D(gpCopyTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func TexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexSubImage2D(gpTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CopyTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n\tsyscall.Syscall9(gpCopyTextureSubImage2D, 8, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(x), uintptr(y), uintptr(width), uintptr(height), 0)\n}", "func (tex Texture) Sub(ctx gl.Context, lvl int, width int, height int, data []byte) {\n\tctx.TexSubImage2D(gl.TEXTURE_2D, lvl, 0, 0, width, height, gl.RGBA, gl.UNSIGNED_BYTE, data)\n\tif lvl > 0 {\n\t\tctx.GenerateMipmap(gl.TEXTURE_2D)\n\t}\n}", "func TextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage1D(gpTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage1D(gpTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CopyTextureSubImage1D(texture uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tC.glowCopyTextureSubImage1D(gpCopyTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func CopyTextureSubImage1D(texture uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tC.glowCopyTextureSubImage1D(gpCopyTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func TexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTexSubImage2D, 9, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(width), uintptr(height), uintptr(format), uintptr(xtype), uintptr(pixels))\n}", "func CopyTextureSubImage1D(texture uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tsyscall.Syscall6(gpCopyTextureSubImage1D, 6, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(x), uintptr(y), uintptr(width))\n}", "func CompressedTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTexSubImage2D, 9, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(width), uintptr(height), uintptr(format), uintptr(imageSize), uintptr(data))\n}", "func TexSubImage2D(target Enum, level int, x, y, width, height int, format, ty Enum, data []byte) {\n\tgl.TexSubImage2D(uint32(target), int32(level), int32(x), int32(y), int32(width), int32(height), uint32(format), uint32(ty), gl.Ptr(&data[0]))\n}", "func TexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage2D(gpTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage2D(gpTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CompressedTexSubImage2D(target GLEnum, level, xoffset, yoffset, width, height int32, format GLEnum, imageSize int32, pixels []float32) {\n\tgl.CompressedTexSubImage2D(uint32(target), level, xoffset, yoffset, width, height, uint32(format), imageSize, unsafe.Pointer(&pixels[0]))\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexSubImage3D(gpTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CompressedTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexSubImage2D(gpCompressedTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexSubImage2D(gpCompressedTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall12(gpTexSubImage3D, 11, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(xtype), uintptr(pixels), 0)\n}", "func TexSubImage2D(target GLEnum, level, xoffset, yoffset, width, height int32, format, xtype GLEnum, pixels []float32) {\n\tgl.TexSubImage2D(uint32(target), level, xoffset, yoffset, width, height, uint32(format), uint32(xtype), unsafe.Pointer(&pixels[0]))\n}", "func GetCompressedTextureImage(texture uint32, level int32, bufSize int32, pixels unsafe.Pointer) {\n\tsyscall.Syscall6(gpGetCompressedTextureImage, 4, uintptr(texture), uintptr(level), uintptr(bufSize), uintptr(pixels), 0, 0)\n}", "func TexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexSubImage1D(gpTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage3D(gpTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage3D(gpTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CompressedTexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n C.glowCompressedTexSubImage1D(gpCompressedTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func GetCompressedTextureImage(texture uint32, level int32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetCompressedTextureImage(gpGetCompressedTextureImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLsizei)(bufSize), pixels)\n}", "func GetCompressedTextureImage(texture uint32, level int32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetCompressedTextureImage(gpGetCompressedTextureImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLsizei)(bufSize), pixels)\n}", "func CompressedTexSubImage2D(target Enum, level, xoffset, yoffset, width, height int, format Enum, data []byte) {\n\tgl.CompressedTexSubImage2D(uint32(target), int32(level), int32(xoffset), int32(yoffset), int32(width), int32(height), uint32(format), int32(len(data)), gl.Ptr(data))\n}", "func CompressedTexImage2D(target uint32, level int32, internalformat uint32, width int32, height int32, border int32, imageSize int32, data unsafe.Pointer) {\n C.glowCompressedTexImage2D(gpCompressedTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n C.glowCompressedTexSubImage3D(gpCompressedTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexImage2D(target uint32, level int32, internalformat uint32, width int32, height int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTexImage2D, 8, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(width), uintptr(height), uintptr(border), uintptr(imageSize), uintptr(data), 0)\n}", "func TexSubImage2D(target Enum, level Int, xoffset Int, yoffset Int, width Sizei, height Sizei, format Enum, kind Enum, pixels unsafe.Pointer) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tclevel, _ := (C.GLint)(level), cgoAllocsUnknown\n\tcxoffset, _ := (C.GLint)(xoffset), cgoAllocsUnknown\n\tcyoffset, _ := (C.GLint)(yoffset), cgoAllocsUnknown\n\tcwidth, _ := (C.GLsizei)(width), cgoAllocsUnknown\n\tcheight, _ := (C.GLsizei)(height), cgoAllocsUnknown\n\tcformat, _ := (C.GLenum)(format), cgoAllocsUnknown\n\tckind, _ := (C.GLenum)(kind), cgoAllocsUnknown\n\tcpixels, _ := (unsafe.Pointer)(unsafe.Pointer(pixels)), cgoAllocsUnknown\n\tC.glTexSubImage2D(ctarget, clevel, cxoffset, cyoffset, cwidth, cheight, cformat, ckind, cpixels)\n}", "func TexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTexSubImage1D, 7, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(width), uintptr(format), uintptr(xtype), uintptr(pixels), 0, 0)\n}", "func CompressedTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall12(gpCompressedTexSubImage3D, 11, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(imageSize), uintptr(data), 0)\n}", "func TexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage1D(gpTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage1D(gpTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CopyImageSubData(srcName uint32, srcTarget uint32, srcLevel int32, srcX int32, srcY int32, srcZ int32, dstName uint32, dstTarget uint32, dstLevel int32, dstX int32, dstY int32, dstZ int32, srcWidth int32, srcHeight int32, srcDepth int32) {\n C.glowCopyImageSubData(gpCopyImageSubData, (C.GLuint)(srcName), (C.GLenum)(srcTarget), (C.GLint)(srcLevel), (C.GLint)(srcX), (C.GLint)(srcY), (C.GLint)(srcZ), (C.GLuint)(dstName), (C.GLenum)(dstTarget), (C.GLint)(dstLevel), (C.GLint)(dstX), (C.GLint)(dstY), (C.GLint)(dstZ), (C.GLsizei)(srcWidth), (C.GLsizei)(srcHeight), (C.GLsizei)(srcDepth))\n}", "func CompressedTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexSubImage3D(gpCompressedTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexSubImage3D(gpCompressedTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexSubImage2D(target Enum, level Int, xoffset Int, yoffset Int, width Sizei, height Sizei, format Enum, imageSize Sizei, data unsafe.Pointer) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tclevel, _ := (C.GLint)(level), cgoAllocsUnknown\n\tcxoffset, _ := (C.GLint)(xoffset), cgoAllocsUnknown\n\tcyoffset, _ := (C.GLint)(yoffset), cgoAllocsUnknown\n\tcwidth, _ := (C.GLsizei)(width), cgoAllocsUnknown\n\tcheight, _ := (C.GLsizei)(height), cgoAllocsUnknown\n\tcformat, _ := (C.GLenum)(format), cgoAllocsUnknown\n\tcimageSize, _ := (C.GLsizei)(imageSize), cgoAllocsUnknown\n\tcdata, _ := (unsafe.Pointer)(unsafe.Pointer(data)), cgoAllocsUnknown\n\tC.glCompressedTexSubImage2D(ctarget, clevel, cxoffset, cyoffset, cwidth, cheight, cformat, cimageSize, cdata)\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTexImage2D, 9, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(width), uintptr(height), uintptr(border), uintptr(format), uintptr(xtype), uintptr(pixels))\n}", "func CompressedTexImage2D(target uint32, level int32, internalformat uint32, width int32, height int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexImage2D(gpCompressedTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexImage2D(target uint32, level int32, internalformat uint32, width int32, height int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexImage2D(gpCompressedTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func TexImage2D(target GLEnum, level int32, internalformat GLEnum, width, height, border int32, format, xtype GLEnum, pixels []float32) {\n\tgl.TexImage2D(uint32(target), level, int32(internalformat), width, height, border, uint32(format), uint32(xtype), unsafe.Pointer(&pixels[0]))\n}", "func CompressedTexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTexSubImage1D, 7, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(width), uintptr(format), uintptr(imageSize), uintptr(data), 0, 0)\n}", "func TexImage2D(target Enum, level int, width, height int, format Enum, ty Enum, data []byte) {\n\tp := unsafe.Pointer(nil)\n\tif len(data) > 0 {\n\t\tp = gl.Ptr(&data[0])\n\t}\n\tgl.TexImage2D(uint32(target), int32(level), int32(format), int32(width), int32(height), 0, uint32(format), uint32(ty), p)\n}", "func GetCompressedTexImage(target uint32, level int32, img unsafe.Pointer) {\n C.glowGetCompressedTexImage(gpGetCompressedTexImage, (C.GLenum)(target), (C.GLint)(level), img)\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexImage2D(gpTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func (debugging *debuggingOpenGL) TexImage2D(target uint32, level int32, internalFormat uint32, width int32, height int32,\n\tborder int32, format uint32, xtype uint32, pixels interface{}) {\n\tdebugging.recordEntry(\"TexImage2D\", target, level, internalFormat, width, height, border, format, xtype, pixels)\n\tdebugging.gl.TexImage2D(target, level, internalFormat, width, height, border, format, xtype, pixels)\n\tdebugging.recordExit(\"TexImage2D\")\n}", "func CompressedTexImage2D(target Enum, level int, internalformat Enum, width, height, border int, data []byte) {\n\tgl.CompressedTexImage2D(uint32(target), int32(level), uint32(internalformat), int32(width), int32(height), int32(border), int32(len(data)), gl.Ptr(data))\n}", "func CompressedTexImage2D(target GLEnum, level int32, internalformat GLEnum, width, height, border, imageSize int32, pixels []float32) {\n\tgl.CompressedTexImage2D(uint32(target), level, uint32(internalformat), width, height, border, imageSize, unsafe.Pointer(&pixels[0]))\n}", "func CompressedTexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexSubImage1D(gpCompressedTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexSubImage1D(gpCompressedTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexImage2D(gpTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexImage2D(gpTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CopyImageSubData(srcName uint32, srcTarget uint32, srcLevel int32, srcX int32, srcY int32, srcZ int32, dstName uint32, dstTarget uint32, dstLevel int32, dstX int32, dstY int32, dstZ int32, srcWidth int32, srcHeight int32, srcDepth int32) {\n\tC.glowCopyImageSubData(gpCopyImageSubData, (C.GLuint)(srcName), (C.GLenum)(srcTarget), (C.GLint)(srcLevel), (C.GLint)(srcX), (C.GLint)(srcY), (C.GLint)(srcZ), (C.GLuint)(dstName), (C.GLenum)(dstTarget), (C.GLint)(dstLevel), (C.GLint)(dstX), (C.GLint)(dstY), (C.GLint)(dstZ), (C.GLsizei)(srcWidth), (C.GLsizei)(srcHeight), (C.GLsizei)(srcDepth))\n}", "func CopyImageSubData(srcName uint32, srcTarget uint32, srcLevel int32, srcX int32, srcY int32, srcZ int32, dstName uint32, dstTarget uint32, dstLevel int32, dstX int32, dstY int32, dstZ int32, srcWidth int32, srcHeight int32, srcDepth int32) {\n\tC.glowCopyImageSubData(gpCopyImageSubData, (C.GLuint)(srcName), (C.GLenum)(srcTarget), (C.GLint)(srcLevel), (C.GLint)(srcX), (C.GLint)(srcY), (C.GLint)(srcZ), (C.GLuint)(dstName), (C.GLenum)(dstTarget), (C.GLint)(dstLevel), (C.GLint)(dstX), (C.GLint)(dstY), (C.GLint)(dstZ), (C.GLsizei)(srcWidth), (C.GLsizei)(srcHeight), (C.GLsizei)(srcDepth))\n}", "func CopyTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n C.glowCopyTexSubImage2D(gpCopyTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func (native *OpenGL) TexImage2D(target uint32, level int32, internalFormat uint32, width int32, height int32,\n\tborder int32, format uint32, xtype uint32, pixels interface{}) {\n\tptr, isPointer := pixels.(unsafe.Pointer)\n\tif isPointer {\n\t\tgl.TexImage2D(target, level, int32(internalFormat), width, height, border, format, xtype, ptr)\n\t} else {\n\t\tgl.TexImage2D(target, level, int32(internalFormat), width, height, border, format, xtype, gl.Ptr(pixels))\n\t}\n}", "func CompressedTexImage1D(target uint32, level int32, internalformat uint32, width int32, border int32, imageSize int32, data unsafe.Pointer) {\n C.glowCompressedTexImage1D(gpCompressedTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func CopyTexImage2D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, height int32, border int32) {\n C.glowCopyTexImage2D(gpCopyTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border))\n}", "func GetCompressedTexImage(target uint32, level int32, img unsafe.Pointer) {\n\tsyscall.Syscall(gpGetCompressedTexImage, 3, uintptr(target), uintptr(level), uintptr(img))\n}", "func CopyTexSubImage1D(target uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n C.glowCopyTexSubImage1D(gpCopyTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func (gl *WebGL) TexImage2D(target GLEnum, level int, internalFormat GLEnum, format GLEnum, texelType GLEnum, pixels interface{}) {\n\tgl.context.Call(\"texImage2D\", target, level, internalFormat, format, texelType, pixels)\n}", "func CopyTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n C.glowCopyTexSubImage3D(gpCopyTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CompressedTexImage3D(target uint32, level int32, internalformat uint32, width int32, height int32, depth int32, border int32, imageSize int32, data unsafe.Pointer) {\n C.glowCompressedTexImage3D(gpCompressedTexImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexImage3D(target uint32, level int32, internalformat uint32, width int32, height int32, depth int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTexImage3D, 9, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(width), uintptr(height), uintptr(depth), uintptr(border), uintptr(imageSize), uintptr(data))\n}", "func CompressedTexImage1D(target uint32, level int32, internalformat uint32, width int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTexImage1D, 7, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(width), uintptr(border), uintptr(imageSize), uintptr(data), 0, 0)\n}", "func BindImageTexture(unit uint32, texture uint32, level int32, layered bool, layer int32, access uint32, format uint32) {\n C.glowBindImageTexture(gpBindImageTexture, (C.GLuint)(unit), (C.GLuint)(texture), (C.GLint)(level), (C.GLboolean)(boolToInt(layered)), (C.GLint)(layer), (C.GLenum)(access), (C.GLenum)(format))\n}", "func CompressedTexImage2D(target Enum, level Int, internalformat Enum, width Sizei, height Sizei, border Int, imageSize Sizei, data unsafe.Pointer) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tclevel, _ := (C.GLint)(level), cgoAllocsUnknown\n\tcinternalformat, _ := (C.GLenum)(internalformat), cgoAllocsUnknown\n\tcwidth, _ := (C.GLsizei)(width), cgoAllocsUnknown\n\tcheight, _ := (C.GLsizei)(height), cgoAllocsUnknown\n\tcborder, _ := (C.GLint)(border), cgoAllocsUnknown\n\tcimageSize, _ := (C.GLsizei)(imageSize), cgoAllocsUnknown\n\tcdata, _ := (unsafe.Pointer)(unsafe.Pointer(data)), cgoAllocsUnknown\n\tC.glCompressedTexImage2D(ctarget, clevel, cinternalformat, cwidth, cheight, cborder, cimageSize, cdata)\n}", "func GetCompressedTexImage(target uint32, level int32, img unsafe.Pointer) {\n\tC.glowGetCompressedTexImage(gpGetCompressedTexImage, (C.GLenum)(target), (C.GLint)(level), img)\n}", "func GetCompressedTexImage(target uint32, level int32, img unsafe.Pointer) {\n\tC.glowGetCompressedTexImage(gpGetCompressedTexImage, (C.GLenum)(target), (C.GLint)(level), img)\n}", "func CopyTexImage2D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, height int32, border int32) {\n\tsyscall.Syscall9(gpCopyTexImage2D, 8, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(x), uintptr(y), uintptr(width), uintptr(height), uintptr(border), 0)\n}", "func (self *Graphics) GenerateTexture2O(resolution int, scaleMode int) *Texture{\n return &Texture{self.Object.Call(\"generateTexture\", resolution, scaleMode)}\n}" ]
[ "0.75624573", "0.74462503", "0.74462503", "0.7382152", "0.733096", "0.733096", "0.7265395", "0.71279454", "0.7097129", "0.7097129", "0.6861826", "0.6717682", "0.6717682", "0.6695255", "0.6680614", "0.6680614", "0.66295075", "0.6612707", "0.6605899", "0.6605899", "0.6574313", "0.6574313", "0.65357566", "0.65144676", "0.6504656", "0.6504656", "0.6480661", "0.64585876", "0.6403474", "0.6390071", "0.6390071", "0.6337915", "0.6337915", "0.6335403", "0.6332997", "0.6332359", "0.6305687", "0.62996304", "0.62996304", "0.6239961", "0.62393045", "0.6211405", "0.6211405", "0.61972624", "0.61952597", "0.6187488", "0.6177589", "0.6139043", "0.6139043", "0.60941833", "0.60900843", "0.60900843", "0.60647374", "0.6056523", "0.5942622", "0.59338504", "0.5907641", "0.59032553", "0.5886487", "0.5874333", "0.5874333", "0.57928145", "0.5787828", "0.5787828", "0.5786048", "0.5741639", "0.57364833", "0.57364833", "0.57158744", "0.5698743", "0.56864345", "0.5672856", "0.56230116", "0.5620403", "0.5603419", "0.55983955", "0.5578517", "0.5578517", "0.55336726", "0.55336726", "0.55312806", "0.55312806", "0.5478601", "0.5445027", "0.5347705", "0.53076416", "0.5286839", "0.52686876", "0.52682906", "0.52631176", "0.5257812", "0.51905894", "0.51804966", "0.5174424", "0.5171122", "0.51666373", "0.51666373", "0.5154171", "0.5135581" ]
0.7577275
1
specify a threedimensional texture subimage in a compressed format
func CompressedTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) { C.glowCompressedTextureSubImage3D(gpCompressedTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLsizei)(imageSize), data) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func CompressedTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall12(gpCompressedTextureSubImage3D, 11, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(imageSize), uintptr(data), 0)\n}", "func GetCompressedTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetCompressedTextureSubImage(gpGetCompressedTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLsizei)(bufSize), pixels)\n}", "func GetCompressedTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetCompressedTextureSubImage(gpGetCompressedTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLsizei)(bufSize), pixels)\n}", "func CompressedTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage2D(gpCompressedTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage2D(gpCompressedTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTextureSubImage2D, 9, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(width), uintptr(height), uintptr(format), uintptr(imageSize), uintptr(data))\n}", "func GetCompressedTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, bufSize int32, pixels unsafe.Pointer) {\n\tsyscall.Syscall12(gpGetCompressedTextureSubImage, 10, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(bufSize), uintptr(pixels), 0, 0)\n}", "func CompressedTextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTextureSubImage1D, 7, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(width), uintptr(format), uintptr(imageSize), uintptr(data), 0, 0)\n}", "func CompressedTextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage1D(gpCompressedTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage1D(gpCompressedTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func TextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall12(gpTextureSubImage3D, 11, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(xtype), uintptr(pixels), 0)\n}", "func TextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage3D(gpTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage3D(gpTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CopyTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTextureSubImage3D(gpCopyTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CopyTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTextureSubImage3D(gpCopyTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CopyTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n\tsyscall.Syscall9(gpCopyTextureSubImage3D, 9, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(x), uintptr(y), uintptr(width), uintptr(height))\n}", "func TextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTextureSubImage1D, 7, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(width), uintptr(format), uintptr(xtype), uintptr(pixels), 0, 0)\n}", "func TextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTextureSubImage2D, 9, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(width), uintptr(height), uintptr(format), uintptr(xtype), uintptr(pixels))\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexSubImage3D(gpTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func GetTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetTextureSubImage(gpGetTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), (C.GLsizei)(bufSize), pixels)\n}", "func GetTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetTextureSubImage(gpGetTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), (C.GLsizei)(bufSize), pixels)\n}", "func TextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage1D(gpTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage1D(gpTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall12(gpTexSubImage3D, 11, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(xtype), uintptr(pixels), 0)\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage3D(gpTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage3D(gpTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage2D(gpTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage2D(gpTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func GetTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, bufSize int32, pixels unsafe.Pointer) {\n\tsyscall.Syscall12(gpGetTextureSubImage, 12, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(xtype), uintptr(bufSize), uintptr(pixels))\n}", "func CopyTextureSubImage1D(texture uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tC.glowCopyTextureSubImage1D(gpCopyTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func CopyTextureSubImage1D(texture uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tC.glowCopyTextureSubImage1D(gpCopyTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func CompressedTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n C.glowCompressedTexSubImage2D(gpCompressedTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CopyTextureSubImage1D(texture uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tsyscall.Syscall6(gpCopyTextureSubImage1D, 6, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(x), uintptr(y), uintptr(width))\n}", "func CompressedTexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n C.glowCompressedTexSubImage1D(gpCompressedTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n C.glowCompressedTexSubImage3D(gpCompressedTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func GetCompressedTextureImage(texture uint32, level int32, bufSize int32, pixels unsafe.Pointer) {\n\tsyscall.Syscall6(gpGetCompressedTextureImage, 4, uintptr(texture), uintptr(level), uintptr(bufSize), uintptr(pixels), 0, 0)\n}", "func TexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexSubImage1D(gpTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func GetCompressedTextureImage(texture uint32, level int32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetCompressedTextureImage(gpGetCompressedTextureImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLsizei)(bufSize), pixels)\n}", "func GetCompressedTextureImage(texture uint32, level int32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetCompressedTextureImage(gpGetCompressedTextureImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLsizei)(bufSize), pixels)\n}", "func CompressedTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall12(gpCompressedTexSubImage3D, 11, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(imageSize), uintptr(data), 0)\n}", "func TexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexSubImage2D(gpTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CopyTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTextureSubImage2D(gpCopyTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CopyTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTextureSubImage2D(gpCopyTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CompressedTexImage2D(target uint32, level int32, internalformat uint32, width int32, height int32, border int32, imageSize int32, data unsafe.Pointer) {\n C.glowCompressedTexImage2D(gpCompressedTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func (tex Texture) Sub(ctx gl.Context, lvl int, width int, height int, data []byte) {\n\tctx.TexSubImage2D(gl.TEXTURE_2D, lvl, 0, 0, width, height, gl.RGBA, gl.UNSIGNED_BYTE, data)\n\tif lvl > 0 {\n\t\tctx.GenerateMipmap(gl.TEXTURE_2D)\n\t}\n}", "func CompressedTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexSubImage3D(gpCompressedTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexSubImage3D(gpCompressedTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CopyTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n\tsyscall.Syscall9(gpCopyTextureSubImage2D, 8, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(x), uintptr(y), uintptr(width), uintptr(height), 0)\n}", "func CompressedTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTexSubImage2D, 9, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(width), uintptr(height), uintptr(format), uintptr(imageSize), uintptr(data))\n}", "func TexSubImage2D(target Enum, level int, x, y, width, height int, format, ty Enum, data []byte) {\n\tgl.TexSubImage2D(uint32(target), int32(level), int32(x), int32(y), int32(width), int32(height), uint32(format), uint32(ty), gl.Ptr(&data[0]))\n}", "func CompressedTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexSubImage2D(gpCompressedTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexSubImage2D(gpCompressedTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func TexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage2D(gpTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage2D(gpTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CompressedTexSubImage2D(target GLEnum, level, xoffset, yoffset, width, height int32, format GLEnum, imageSize int32, pixels []float32) {\n\tgl.CompressedTexSubImage2D(uint32(target), level, xoffset, yoffset, width, height, uint32(format), imageSize, unsafe.Pointer(&pixels[0]))\n}", "func TexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage1D(gpTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage1D(gpTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTexSubImage2D, 9, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(width), uintptr(height), uintptr(format), uintptr(xtype), uintptr(pixels))\n}", "func CompressedTexImage2D(target uint32, level int32, internalformat uint32, width int32, height int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTexImage2D, 8, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(width), uintptr(height), uintptr(border), uintptr(imageSize), uintptr(data), 0)\n}", "func TexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTexSubImage1D, 7, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(width), uintptr(format), uintptr(xtype), uintptr(pixels), 0, 0)\n}", "func TexSubImage2D(target GLEnum, level, xoffset, yoffset, width, height int32, format, xtype GLEnum, pixels []float32) {\n\tgl.TexSubImage2D(uint32(target), level, xoffset, yoffset, width, height, uint32(format), uint32(xtype), unsafe.Pointer(&pixels[0]))\n}", "func GetCompressedTexImage(target uint32, level int32, img unsafe.Pointer) {\n C.glowGetCompressedTexImage(gpGetCompressedTexImage, (C.GLenum)(target), (C.GLint)(level), img)\n}", "func CompressedTexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTexSubImage1D, 7, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(width), uintptr(format), uintptr(imageSize), uintptr(data), 0, 0)\n}", "func CompressedTexSubImage2D(target Enum, level, xoffset, yoffset, width, height int, format Enum, data []byte) {\n\tgl.CompressedTexSubImage2D(uint32(target), int32(level), int32(xoffset), int32(yoffset), int32(width), int32(height), uint32(format), int32(len(data)), gl.Ptr(data))\n}", "func CompressedTexImage3D(target uint32, level int32, internalformat uint32, width int32, height int32, depth int32, border int32, imageSize int32, data unsafe.Pointer) {\n C.glowCompressedTexImage3D(gpCompressedTexImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexSubImage1D(gpCompressedTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexSubImage1D(gpCompressedTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CopyImageSubData(srcName uint32, srcTarget uint32, srcLevel int32, srcX int32, srcY int32, srcZ int32, dstName uint32, dstTarget uint32, dstLevel int32, dstX int32, dstY int32, dstZ int32, srcWidth int32, srcHeight int32, srcDepth int32) {\n C.glowCopyImageSubData(gpCopyImageSubData, (C.GLuint)(srcName), (C.GLenum)(srcTarget), (C.GLint)(srcLevel), (C.GLint)(srcX), (C.GLint)(srcY), (C.GLint)(srcZ), (C.GLuint)(dstName), (C.GLenum)(dstTarget), (C.GLint)(dstLevel), (C.GLint)(dstX), (C.GLint)(dstY), (C.GLint)(dstZ), (C.GLsizei)(srcWidth), (C.GLsizei)(srcHeight), (C.GLsizei)(srcDepth))\n}", "func CompressedTexImage2D(target uint32, level int32, internalformat uint32, width int32, height int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexImage2D(gpCompressedTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexImage2D(target uint32, level int32, internalformat uint32, width int32, height int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexImage2D(gpCompressedTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexImage1D(target uint32, level int32, internalformat uint32, width int32, border int32, imageSize int32, data unsafe.Pointer) {\n C.glowCompressedTexImage1D(gpCompressedTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexImage3D(target uint32, level int32, internalformat uint32, width int32, height int32, depth int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTexImage3D, 9, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(width), uintptr(height), uintptr(depth), uintptr(border), uintptr(imageSize), uintptr(data))\n}", "func TexImage2D(target GLEnum, level int32, internalformat GLEnum, width, height, border int32, format, xtype GLEnum, pixels []float32) {\n\tgl.TexImage2D(uint32(target), level, int32(internalformat), width, height, border, uint32(format), uint32(xtype), unsafe.Pointer(&pixels[0]))\n}", "func TexImage2D(target Enum, level int, width, height int, format Enum, ty Enum, data []byte) {\n\tp := unsafe.Pointer(nil)\n\tif len(data) > 0 {\n\t\tp = gl.Ptr(&data[0])\n\t}\n\tgl.TexImage2D(uint32(target), int32(level), int32(format), int32(width), int32(height), 0, uint32(format), uint32(ty), p)\n}", "func CompressedTexImage2D(target Enum, level int, internalformat Enum, width, height, border int, data []byte) {\n\tgl.CompressedTexImage2D(uint32(target), int32(level), uint32(internalformat), int32(width), int32(height), int32(border), int32(len(data)), gl.Ptr(data))\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTexImage2D, 9, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(width), uintptr(height), uintptr(border), uintptr(format), uintptr(xtype), uintptr(pixels))\n}", "func CompressedTexImage1D(target uint32, level int32, internalformat uint32, width int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTexImage1D, 7, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(width), uintptr(border), uintptr(imageSize), uintptr(data), 0, 0)\n}", "func CompressedTexImage2D(target GLEnum, level int32, internalformat GLEnum, width, height, border, imageSize int32, pixels []float32) {\n\tgl.CompressedTexImage2D(uint32(target), level, uint32(internalformat), width, height, border, imageSize, unsafe.Pointer(&pixels[0]))\n}", "func TexSubImage2D(target Enum, level Int, xoffset Int, yoffset Int, width Sizei, height Sizei, format Enum, kind Enum, pixels unsafe.Pointer) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tclevel, _ := (C.GLint)(level), cgoAllocsUnknown\n\tcxoffset, _ := (C.GLint)(xoffset), cgoAllocsUnknown\n\tcyoffset, _ := (C.GLint)(yoffset), cgoAllocsUnknown\n\tcwidth, _ := (C.GLsizei)(width), cgoAllocsUnknown\n\tcheight, _ := (C.GLsizei)(height), cgoAllocsUnknown\n\tcformat, _ := (C.GLenum)(format), cgoAllocsUnknown\n\tckind, _ := (C.GLenum)(kind), cgoAllocsUnknown\n\tcpixels, _ := (unsafe.Pointer)(unsafe.Pointer(pixels)), cgoAllocsUnknown\n\tC.glTexSubImage2D(ctarget, clevel, cxoffset, cyoffset, cwidth, cheight, cformat, ckind, cpixels)\n}", "func CompressedTexImage3D(target uint32, level int32, internalformat uint32, width int32, height int32, depth int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexImage3D(gpCompressedTexImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexImage3D(target uint32, level int32, internalformat uint32, width int32, height int32, depth int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexImage3D(gpCompressedTexImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func CopyImageSubData(srcName uint32, srcTarget uint32, srcLevel int32, srcX int32, srcY int32, srcZ int32, dstName uint32, dstTarget uint32, dstLevel int32, dstX int32, dstY int32, dstZ int32, srcWidth int32, srcHeight int32, srcDepth int32) {\n\tC.glowCopyImageSubData(gpCopyImageSubData, (C.GLuint)(srcName), (C.GLenum)(srcTarget), (C.GLint)(srcLevel), (C.GLint)(srcX), (C.GLint)(srcY), (C.GLint)(srcZ), (C.GLuint)(dstName), (C.GLenum)(dstTarget), (C.GLint)(dstLevel), (C.GLint)(dstX), (C.GLint)(dstY), (C.GLint)(dstZ), (C.GLsizei)(srcWidth), (C.GLsizei)(srcHeight), (C.GLsizei)(srcDepth))\n}", "func CopyImageSubData(srcName uint32, srcTarget uint32, srcLevel int32, srcX int32, srcY int32, srcZ int32, dstName uint32, dstTarget uint32, dstLevel int32, dstX int32, dstY int32, dstZ int32, srcWidth int32, srcHeight int32, srcDepth int32) {\n\tC.glowCopyImageSubData(gpCopyImageSubData, (C.GLuint)(srcName), (C.GLenum)(srcTarget), (C.GLint)(srcLevel), (C.GLint)(srcX), (C.GLint)(srcY), (C.GLint)(srcZ), (C.GLuint)(dstName), (C.GLenum)(dstTarget), (C.GLint)(dstLevel), (C.GLint)(dstX), (C.GLint)(dstY), (C.GLint)(dstZ), (C.GLsizei)(srcWidth), (C.GLsizei)(srcHeight), (C.GLsizei)(srcDepth))\n}", "func CompressedTexSubImage2D(target Enum, level Int, xoffset Int, yoffset Int, width Sizei, height Sizei, format Enum, imageSize Sizei, data unsafe.Pointer) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tclevel, _ := (C.GLint)(level), cgoAllocsUnknown\n\tcxoffset, _ := (C.GLint)(xoffset), cgoAllocsUnknown\n\tcyoffset, _ := (C.GLint)(yoffset), cgoAllocsUnknown\n\tcwidth, _ := (C.GLsizei)(width), cgoAllocsUnknown\n\tcheight, _ := (C.GLsizei)(height), cgoAllocsUnknown\n\tcformat, _ := (C.GLenum)(format), cgoAllocsUnknown\n\tcimageSize, _ := (C.GLsizei)(imageSize), cgoAllocsUnknown\n\tcdata, _ := (unsafe.Pointer)(unsafe.Pointer(data)), cgoAllocsUnknown\n\tC.glCompressedTexSubImage2D(ctarget, clevel, cxoffset, cyoffset, cwidth, cheight, cformat, cimageSize, cdata)\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexImage2D(gpTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexImage3D(target uint32, level int32, internalformat int32, width int32, height int32, depth int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall12(gpTexImage3D, 10, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(width), uintptr(height), uintptr(depth), uintptr(border), uintptr(format), uintptr(xtype), uintptr(pixels), 0, 0)\n}", "func GetCompressedTexImage(target uint32, level int32, img unsafe.Pointer) {\n\tsyscall.Syscall(gpGetCompressedTexImage, 3, uintptr(target), uintptr(level), uintptr(img))\n}", "func (debugging *debuggingOpenGL) TexImage2D(target uint32, level int32, internalFormat uint32, width int32, height int32,\n\tborder int32, format uint32, xtype uint32, pixels interface{}) {\n\tdebugging.recordEntry(\"TexImage2D\", target, level, internalFormat, width, height, border, format, xtype, pixels)\n\tdebugging.gl.TexImage2D(target, level, internalFormat, width, height, border, format, xtype, pixels)\n\tdebugging.recordExit(\"TexImage2D\")\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexImage2D(gpTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexImage2D(gpTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CopyTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n C.glowCopyTexSubImage3D(gpCopyTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func GetCompressedTexImage(target uint32, level int32, img unsafe.Pointer) {\n\tC.glowGetCompressedTexImage(gpGetCompressedTexImage, (C.GLenum)(target), (C.GLint)(level), img)\n}", "func GetCompressedTexImage(target uint32, level int32, img unsafe.Pointer) {\n\tC.glowGetCompressedTexImage(gpGetCompressedTexImage, (C.GLenum)(target), (C.GLint)(level), img)\n}", "func TexImage1D(target uint32, level int32, internalformat int32, width int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTexImage1D, 8, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(width), uintptr(border), uintptr(format), uintptr(xtype), uintptr(pixels), 0)\n}", "func TexImage3D(target uint32, level int32, internalformat int32, width int32, height int32, depth int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexImage3D(gpTexImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CompressedTexImage1D(target uint32, level int32, internalformat uint32, width int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexImage1D(gpCompressedTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexImage1D(target uint32, level int32, internalformat uint32, width int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexImage1D(gpCompressedTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func TexImage3D(target uint32, level int32, internalformat int32, width int32, height int32, depth int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexImage3D(gpTexImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexImage3D(target uint32, level int32, internalformat int32, width int32, height int32, depth int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexImage3D(gpTexImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}" ]
[ "0.7413762", "0.726753", "0.726753", "0.72593474", "0.72593474", "0.7232897", "0.7199341", "0.71802086", "0.71552026", "0.71552026", "0.6744676", "0.667433", "0.667433", "0.6587511", "0.6587511", "0.6553164", "0.65196425", "0.63975227", "0.6391272", "0.6342379", "0.6342379", "0.6335705", "0.6335705", "0.63193494", "0.6305585", "0.6305585", "0.6284242", "0.6284242", "0.6277623", "0.6271112", "0.6271112", "0.62583905", "0.62547237", "0.62024236", "0.61768454", "0.61734706", "0.6142903", "0.6101152", "0.6101152", "0.608834", "0.6088192", "0.6079898", "0.6079898", "0.60359746", "0.6034976", "0.6031571", "0.6031571", "0.6015362", "0.6014512", "0.59687316", "0.5948147", "0.5948147", "0.5918612", "0.5918612", "0.59132814", "0.58945316", "0.58945316", "0.5894125", "0.5861998", "0.5861822", "0.5839391", "0.58344233", "0.57997257", "0.57462", "0.5737097", "0.5725774", "0.5725774", "0.57246256", "0.5715732", "0.5715732", "0.5699877", "0.56535393", "0.55589014", "0.55479765", "0.55442345", "0.5522677", "0.55188686", "0.5493213", "0.5491885", "0.54781926", "0.54781926", "0.54684263", "0.54684263", "0.5441828", "0.54332495", "0.541208", "0.54057884", "0.53769135", "0.5370847", "0.5370847", "0.5363173", "0.534126", "0.534126", "0.5321106", "0.5287312", "0.5275723", "0.5275723", "0.5232185", "0.5232185" ]
0.74802285
1
define a onedimensional convolution filter
func ConvolutionFilter1D(target uint32, internalformat uint32, width int32, format uint32, xtype uint32, image unsafe.Pointer) { C.glowConvolutionFilter1D(gpConvolutionFilter1D, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), image) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func ConvolutionFilter1D(target uint32, internalformat uint32, width int32, format uint32, xtype uint32, image unsafe.Pointer) {\n C.glowConvolutionFilter1D(gpConvolutionFilter1D, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), image)\n}", "func ConvolutionFilter2D(target uint32, internalformat uint32, width int32, height int32, format uint32, xtype uint32, image unsafe.Pointer) {\n C.glowConvolutionFilter2D(gpConvolutionFilter2D, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), image)\n}", "func (img *FloatImage) convolve(kernel *ConvKernel, px planeExtension) *FloatImage {\n\n\t// convolve each plane independently:\n\tres := new([3][]float32)\n\tfor i := 0; i < 3; i++ {\n\t\tconvolvePlane(&img.Ip[i], kernel, img.Width, img.Height, px)\n\t}\n\n\treturn &FloatImage{\n\t\tIp: *res,\n\t\tWidth: img.Width,\n\t\tHeight: img.Height,\n\t}\n}", "func CopyConvolutionFilter1D(target uint32, internalformat uint32, x int32, y int32, width int32) {\n C.glowCopyConvolutionFilter1D(gpCopyConvolutionFilter1D, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func ConvolutionFilter2D(target uint32, internalformat uint32, width int32, height int32, format uint32, xtype uint32, image unsafe.Pointer) {\n\tC.glowConvolutionFilter2D(gpConvolutionFilter2D, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), image)\n}", "func createFilter(img image.Image, factor [2]float32, size int, kernel func(float32) float32) (f Filter) {\n\tsizeX := size * (int(math.Ceil(float64(factor[0]))))\n\tsizeY := size * (int(math.Ceil(float64(factor[1]))))\n\n\tswitch img.(type) {\n\tdefault:\n\t\tf = &filterModel{\n\t\t\t&genericConverter{img},\n\t\t\tfactor, kernel,\n\t\t\tmake([]colorArray, sizeX), make([]colorArray, sizeY),\n\t\t}\n\tcase *image.RGBA:\n\t\tf = &filterModel{\n\t\t\t&rgbaConverter{img.(*image.RGBA)},\n\t\t\tfactor, kernel,\n\t\t\tmake([]colorArray, sizeX), make([]colorArray, sizeY),\n\t\t}\n\tcase *image.RGBA64:\n\t\tf = &filterModel{\n\t\t\t&rgba64Converter{img.(*image.RGBA64)},\n\t\t\tfactor, kernel,\n\t\t\tmake([]colorArray, sizeX), make([]colorArray, sizeY),\n\t\t}\n\tcase *image.Gray:\n\t\tf = &filterModel{\n\t\t\t&grayConverter{img.(*image.Gray)},\n\t\t\tfactor, kernel,\n\t\t\tmake([]colorArray, sizeX), make([]colorArray, sizeY),\n\t\t}\n\tcase *image.Gray16:\n\t\tf = &filterModel{\n\t\t\t&gray16Converter{img.(*image.Gray16)},\n\t\t\tfactor, kernel,\n\t\t\tmake([]colorArray, sizeX), make([]colorArray, sizeY),\n\t\t}\n\tcase *image.YCbCr:\n\t\tf = &filterModel{\n\t\t\t&ycbcrConverter{img.(*image.YCbCr)},\n\t\t\tfactor, kernel,\n\t\t\tmake([]colorArray, sizeX), make([]colorArray, sizeY),\n\t\t}\n\t}\n\treturn\n}", "func CopyConvolutionFilter2D(target uint32, internalformat uint32, x int32, y int32, width int32, height int32) {\n C.glowCopyConvolutionFilter2D(gpCopyConvolutionFilter2D, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CopyConvolutionFilter1D(target uint32, internalformat uint32, x int32, y int32, width int32) {\n\tC.glowCopyConvolutionFilter1D(gpCopyConvolutionFilter1D, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func Convolve(src, dst []float64, kernel []float64, border Border) {\n\twidth := len(kernel)\n\thalfWidth := width / 2\n\tfor i := range dst {\n\t\tk := i - halfWidth\n\t\tvar sum float64\n\t\tif k >= 0 && k <= len(src)-width {\n\t\t\tfor j, x := range kernel {\n\t\t\t\tsum += src[k+j] * x\n\t\t\t}\n\t\t} else {\n\t\t\tfor j, x := range kernel {\n\t\t\t\tsum += border.Interpolate(src, k+j) * x\n\t\t\t}\n\t\t}\n\t\tdst[i] = sum\n\t}\n}", "func GetConvolutionFilter(target uint32, format uint32, xtype uint32, image unsafe.Pointer) {\n C.glowGetConvolutionFilter(gpGetConvolutionFilter, (C.GLenum)(target), (C.GLenum)(format), (C.GLenum)(xtype), image)\n}", "func ConstructedConv2D(m *Model, x tensor.Tensor, kernelH int, kernelW int, filters int) tensor.Tensor {\n\tslen := len(x.Shape())\n\tfAxis := slen - 1\n\twAxis := slen - 2\n\thAxis := slen - 3\n\tinFilters := x.Shape()[fAxis]\n\tinW := x.Shape()[wAxis]\n\tinH := x.Shape()[hAxis]\n\n\twShape := onesLike(x)\n\twShape[fAxis] = filters\n\twShape[wAxis] = inFilters * kernelH * kernelW\n\n\tbShape := onesLike(x)\n\tbShape[fAxis] = filters\n\n\tweight := m.AddWeight(wShape...)\n\tbias := m.AddBias(bShape...)\n\n\tslices := make([]tensor.Tensor, 0, kernelH*kernelW)\n\n\tfor hoff := 0; hoff < kernelH; hoff++ {\n\t\thslice := tensor.Slice(x, hAxis, hoff, inH-kernelH+1+hoff)\n\t\tfor woff := 0; woff < kernelW; woff++ {\n\t\t\twslice := tensor.Slice(hslice, wAxis, woff, inW-kernelW+1+woff)\n\t\t\tslices = append(slices, wslice)\n\t\t}\n\t}\n\n\tx = tensor.Concat(fAxis, slices...)\n\tx = tensor.MatMul(x, weight, wAxis, fAxis)\n\tx = tensor.Add(x, bias)\n\n\treturn x\n}", "func CopyConvolutionFilter2D(target uint32, internalformat uint32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyConvolutionFilter2D(gpCopyConvolutionFilter2D, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func (img *FloatImage) convolveWith(kernel *ConvKernel, px planeExtension) {\n\n\t// convolve each plane independently:\n\tfor i := 0; i < 3; i++ {\n\t\timg.Ip[i] = *convolvePlane(&img.Ip[i], kernel, img.Width, img.Height, px)\n\t}\n}", "func (fir *FIR) Convolve(input []float64) ([]float64, error) {\n\tkernelSize := len(fir.kernel)\n\tn := len(input)\n\n\tif n <= kernelSize {\n\t\terr := fmt.Errorf(\"input size %d is not greater than kernel size %d\", n, kernelSize)\n\t\treturn []float64{}, err\n\t}\n\n\toutput := make([]float64, n)\n\n\t//\n\tfor i := 0; i < kernelSize; i++ {\n\t\tsum := 0.0\n\n\t\t// convolve the input with the filter kernel\n\t\tfor j := 0; j < i; j++ {\n\t\t\tsum += (input[j] * fir.kernel[kernelSize-(1+i-j)])\n\t\t}\n\n\t\toutput[i] = sum\n\t}\n\n\tfor i := kernelSize; i < n; i++ {\n\t\tsum := 0.0\n\n\t\t// convolve the input with the filter kernel\n\t\tfor j := 0; j < kernelSize; j++ {\n\t\t\tsum += (input[i-j] * fir.kernel[j])\n\t\t}\n\n\t\toutput[i] = sum\n\t}\n\n\treturn output, nil\n}", "func New(c *Config) (*Filter, error) {\n\n\t//\n\t// dimensions\n\t//\n\n\trF, cF := c.F.Dims()\n\trG, cG := c.G.Dims()\n\trQ, cQ := c.Q.Dims()\n\trH, cH := c.H.Dims()\n\trR, cR := c.R.Dims()\n\n\t//\n\t// validate\n\t//\n\n\tif rF != cF {\n\t\treturn nil, errors.New(\"F must be square matrix\")\n\t}\n\n\tif rQ != cQ {\n\t\treturn nil, errors.New(\"Q must be square matrix\")\n\t}\n\n\tif rR != cR {\n\t\treturn nil, errors.New(\"R must be square matrix\")\n\t}\n\n\tif rF != rG {\n\t\treturn nil, errors.New(\"row dim of F must be matched to row dim of G\")\n\t}\n\n\tif cG != rQ {\n\t\treturn nil, errors.New(\"column dim of G must be matched to row dim of Q\")\n\t}\n\n\tif cH != cF {\n\t\treturn nil, errors.New(\"column dim of H must be matched to column dim of F\")\n\t}\n\n\tif rH != rR {\n\t\treturn nil, errors.New(\"row dim of H must be matched to row dim of R\")\n\t}\n\n\t// init internal states\n\n\tx := mat64.NewVector(cF, nil)\n\tv := mat64.NewDense(rF, cF, nil)\n\tident := mat64.NewDense(rF, cF, nil)\n\tfor i := 0; i < rF; i++ {\n\t\tident.Set(i, i, 1.0)\n\t}\n\n\treturn &Filter{\n\t\tConfig: *c,\n\t\tI: ident,\n\t\tX: x,\n\t\tV: v,\n\t}, nil\n}", "func applyConvolutionToPixel(im ImageMatrix, x int, y int, cmSize int, column []color.RGBA, cm ConvolutionMatrix, conFunc func(ImageMatrix, int, int, int, int, color.RGBA, float64) int) {\n\tcurrentColour := im[x][y]\n\tredTotal := 0\n\tgreenTotal := 0\n\tblueTotal := 0\n\tweight := 0\n\n\tkernelMatrix := im.GetKernelMatrix(x, y, cmSize)\n\n\tfor i, kernelColumn := range kernelMatrix {\n\t\tfor j, kernelPixelColour := range kernelColumn {\n\n\t\t\t// get the distance of the current pixel compared to the centre of the kernel\n\t\t\t// the centre one is the one we are modifying and saving to a new image/matrix of course...\n\t\t\tdistance := math.Sqrt(math.Pow(float64(cmSize-i), 2) + math.Pow(float64(cmSize-j), 2))\n\n\t\t\t// Call the function the user passed and get the return weight of how much influence\n\t\t\t// it should have over the centre pixel we want to change\n\t\t\t// We are multipling it by the weight in the convolution matrix as that way you can\n\t\t\t// control an aspect of the weight through the matrix as well (as well as the function that\n\t\t\t// we pass in of course :)\n\t\t\tcmValue := conFunc(im, x, y, i, j, kernelPixelColour, distance) * int(cm[i][j])\n\n\t\t\t// apply the influence / weight ... (eg. if cmValue was 0, then the current pixel would have\n\t\t\t// no influence over the pixel we are changing, if it was large in comparision to what we return\n\t\t\t// for the other kernel pixels, then it will have a large influence)\n\t\t\tredTotal += int(kernelPixelColour.R) * cmValue\n\t\t\tgreenTotal += int(kernelPixelColour.G) * cmValue\n\t\t\tblueTotal += int(kernelPixelColour.B) * cmValue\n\t\t\tweight += cmValue\n\t\t}\n\t}\n\n\t// If the convolution matrix normalised itself; aka, say it was something like:\n\t// { 0 -1 0}\n\t// {-1 4 -1}\n\t// { 0 -1 0}\n\t// then adding the entries (4 + (-1) + (-1) + (-1) + (-1)) results in a zero, in which case we leave\n\t// the weights alone (by setting the weight to divide by to 1) (aka, the weights do not have an impact,\n\t// but the pixels with a weight more more or less than 0 still do have an impact on the pixel\n\t// we are changing of course)\n\tif weight == 0 {\n\t\tweight = 1\n\t}\n\n\t// Normalise the values (based on the weight (total's in the matrix))\n\tnewRedValue := redTotal / weight\n\tnewGreenValue := greenTotal / weight\n\tnewBlueValue := blueTotal / weight\n\n\t// If the values are \"out of range\" (outside the colour range of 0-255) then set them to 0 (absence of that\n\t// colour) if they were negative or 255 (100% of that colour) if they were greater than the max allowed.\n\tif newRedValue < 0 {\n\t\tnewRedValue = 0\n\t} else if newRedValue > 255 {\n\t\tnewRedValue = 255\n\t}\n\n\tif newGreenValue < 0 {\n\t\tnewGreenValue = 0\n\t} else if newGreenValue > 255 {\n\t\tnewGreenValue = 255\n\t}\n\n\tif newBlueValue < 0 {\n\t\tnewBlueValue = 0\n\t} else if newBlueValue > 255 {\n\t\tnewBlueValue = 255\n\t}\n\n\t// Assign the new values to the pixel in the column 'column' at position y\n\tcolumn[y] = color.RGBA{uint8(newRedValue), uint8(newGreenValue), uint8(newBlueValue), currentColour.A}\n\t// fmt.Printf(\"[%v,%v] %v => %v\\n\", x, y, currentColour, column[y])\n}", "func MakeConvolutionCoder(r, k int, poly []uint16) *ConvolutionCoder {\n\tif len(poly) != r {\n\t\tpanic(\"The number of polys should match the rate\")\n\t}\n\n\treturn &ConvolutionCoder{\n\t\tr: r,\n\t\tk: k,\n\t\tpoly: poly,\n\t\tcc: correctwrap.Correct_convolutional_create(int64(r), int64(k), &poly[0]),\n\t}\n}", "func (img *ImageTask) ApplyConvulusion(neighbors *Neighbors, kernel [9]float64) *Colors{\n\n\tvar blue float64\n\tvar green float64\n\tvar red float64\n\tfor r := 0; r < 9; r++ {\n\t\tred = red + (neighbors.inputs[r].Red * kernel[r])\n\t\tgreen = green + (neighbors.inputs[r].Green * kernel[r])\n\t\tblue = blue + (neighbors.inputs[r].Blue * kernel[r])\n\t}\n\n\treturned := Colors{Red: red, Green: green, Blue: blue, Alpha: neighbors.inputs[4].Alpha}\n\treturn &returned\n}", "func Conv(scope *Scope, input tf.Output, filter tf.Output, strides []int64, padding string, optional ...ConvAttr) (output tf.Output) {\n\tif scope.Err() != nil {\n\t\treturn\n\t}\n\tattrs := map[string]interface{}{\"strides\": strides, \"padding\": padding}\n\tfor _, a := range optional {\n\t\ta(attrs)\n\t}\n\topspec := tf.OpSpec{\n\t\tType: \"Conv\",\n\t\tInput: []tf.Input{\n\t\t\tinput, filter,\n\t\t},\n\t\tAttrs: attrs,\n\t}\n\top := scope.AddOperation(opspec)\n\treturn op.Output(0)\n}", "func ConvDiff(geom *Geom, fltOn, fltOff *etensor.Float32, imgOn, imgOff, out *etensor.Float32, gain, gainOn float32) {\n\tfy := fltOn.Dim(0)\n\tfx := fltOn.Dim(1)\n\n\tgeom.FiltSz = image.Point{fx, fy}\n\tgeom.UpdtFilt()\n\n\timgSz := image.Point{imgOn.Dim(1), imgOn.Dim(0)}\n\tgeom.SetSize(imgSz)\n\toshp := []int{2, int(geom.Out.Y), int(geom.Out.X)}\n\tif !etensor.EqualInts(oshp, out.Shp) {\n\t\tout.SetShape(oshp, nil, []string{\"OnOff\", \"Y\", \"X\"})\n\t}\n\tncpu := nproc.NumCPU()\n\tnthrs, nper, rmdr := nproc.ThreadNs(ncpu, geom.Out.Y)\n\tvar wg sync.WaitGroup\n\tfor th := 0; th < nthrs; th++ {\n\t\twg.Add(1)\n\t\tyst := th * nper\n\t\tgo convDiffThr(&wg, geom, yst, nper, fltOn, fltOff, imgOn, imgOff, out, gain, gainOn)\n\t}\n\tif rmdr > 0 {\n\t\twg.Add(1)\n\t\tyst := nthrs * nper\n\t\tgo convDiffThr(&wg, geom, yst, rmdr, fltOn, fltOff, imgOn, imgOff, out, gain, gainOn)\n\t}\n\twg.Wait()\n}", "func GetConvolutionFilter(target uint32, format uint32, xtype uint32, image unsafe.Pointer) {\n\tC.glowGetConvolutionFilter(gpGetConvolutionFilter, (C.GLenum)(target), (C.GLenum)(format), (C.GLenum)(xtype), image)\n}", "func MakePixelMixingFilter() *Filter {\n\tf := new(Filter)\n\tf.F = func(x float64, scaleFactor float64) float64 {\n\t\tvar p float64\n\t\tif scaleFactor < 1.0 {\n\t\t\tp = scaleFactor\n\t\t} else {\n\t\t\tp = 1.0 / scaleFactor\n\t\t}\n\t\tif x < 0.5-p/2.0 {\n\t\t\treturn 1.0\n\t\t} else if x < 0.5+p/2.0 {\n\t\t\treturn 0.5 - (x-0.5)/p\n\t\t}\n\t\treturn 0.0\n\t}\n\tf.Radius = func(scaleFactor float64) float64 {\n\t\tif scaleFactor < 1.0 {\n\t\t\treturn 0.5 + scaleFactor\n\t\t}\n\t\treturn 0.5 + 1.0/scaleFactor\n\t}\n\treturn f\n}", "func (p *Image64) Convolved(k Kernel64) *Image64 {\n\tswitch k.(type) {\n\tcase *separableKernel64:\n\t\treturn p.separableConvolution(k.(*separableKernel64))\n\tdefault:\n\t\treturn p.fullConvolution(k)\n\t}\n\tpanic(\"unreachable\")\n}", "func Sigmoid(midpoint, factor float32) Filter {\n\ta := minf32(maxf32(midpoint, 0), 1)\n\tb := absf32(factor)\n\tsig0 := sigmoid(a, b, 0)\n\tsig1 := sigmoid(a, b, 1)\n\te := float32(1.0e-5)\n\n\treturn &colorchanFilter{\n\t\tfn: func(x float32) float32 {\n\t\t\tif factor == 0 {\n\t\t\t\treturn x\n\t\t\t} else if factor > 0 {\n\t\t\t\tsig := sigmoid(a, b, x)\n\t\t\t\treturn (sig - sig0) / (sig1 - sig0)\n\t\t\t} else {\n\t\t\t\targ := minf32(maxf32((sig1-sig0)*x+sig0, e), 1-e)\n\t\t\t\treturn a - logf32(1/arg-1)/b\n\t\t\t}\n\t\t},\n\t\tlut: true,\n\t}\n}", "func GaussianFilter(src, dst []float64, width int, sigma float64, border Border) {\n\tif width <= 0 {\n\t\twidth = 1 + 2*int(math.Floor(sigma*4+0.5))\n\t}\n\tkernel := make([]float64, width)\n\tGaussianKernel(kernel, sigma)\n\tConvolve(src, dst, kernel, border)\n}", "func convolvePlane(planePtr *[]float32, kernel *ConvKernel, width, height int, toPlaneCoords planeExtension) *[]float32 {\n\n\tplane := *planePtr\n\tradius := kernel.Radius\n\tdiameter := radius*2 + 1\n\tres := make([]float32, width*height)\n\n\t// for each pixel of the intensity plane:\n\tfor y := 0; y < height; y++ {\n\t\tfor x := 0; x < width; x++ {\n\t\t\tindex := y*width + x\n\n\t\t\t// compute convolved value of the pixel:\n\t\t\tresV := float32(0)\n\t\t\tfor yk := 0; yk < diameter; yk++ {\n\t\t\t\typ := toPlaneCoords(y+yk-radius, height)\n\t\t\t\tfor xk := 0; xk < diameter; xk++ {\n\t\t\t\t\txp := toPlaneCoords(x+xk-radius, width)\n\t\t\t\t\tplaneIndex := yp*width + xp\n\t\t\t\t\tkernelIndex := yk*diameter + xk\n\t\t\t\t\tresV += (plane[planeIndex] * kernel.Kernel[kernelIndex])\n\t\t\t\t}\n\t\t\t}\n\t\t\tres[index] = resV\n\t\t}\n\t}\n\n\treturn &res\n}", "func NewKalmanFilter(n int, n0, sigmaK0, sigmaK, sigmaM float64) (k *Filter) {\n\tk = new(Filter)\n\tk.n = n\n\n\tk.x = make(Matrix, 2*n)\n\tk.p = make(Matrix, 2*n)\n\tk.q = make(Matrix, 2*n)\n\n\tfor i := 0; i < n; i++ {\n\t\tk.x[2*i] = []float64{1}\n\t\tk.x[2*i+1] = []float64{0}\n\n\t\tk.p[2*i] = make([]float64, 2*n)\n\t\tk.p[2*i+1] = make([]float64, 2*n)\n\t\tk.p[2*i][2*i] = sigmaK0 * sigmaK0\n\t\tk.p[2*i+1][2*i+1] = (n0 * sigmaK0) * (n0 * sigmaK0)\n\n\t\tk.q[2*i] = make([]float64, 2*n)\n\t\tk.q[2*i+1] = make([]float64, 2*n)\n\t\tk.q[2*i][2*i] = sigmaK * sigmaK\n\t\tk.q[2*i+1][2*i+1] = (n0 * sigmaK) * (n0 * sigmaK)\n\t}\n\n\tk.r = Matrix{{(n0 * sigmaM) * (n0 * sigmaM)}}\n\n\tk.U = make(chan Matrix)\n\tk.Z = make(chan float64)\n\n\tgo k.runFilter()\n\n\treturn k\n}", "func NewConvolutionalLayer(\n\tinputSize, kernelSize, stride, padding []int,\n\tGPUDriver *driver.Driver,\n\tGPUCtx *driver.Context,\n\tTensorOperator *TensorOperator,\n) *Conv2D {\n\t// argumentsMustBeValid(inputSize, kernelSize, stride, padding)\n\n\tl := &Conv2D{\n\t\tinputSize: inputSize,\n\t\tkernelSize: kernelSize,\n\t\tstride: stride,\n\t\tpadding: padding,\n\t\tGPUDriver: GPUDriver,\n\t\tGPUCtx: GPUCtx,\n\t\tTensorOperator: TensorOperator,\n\t}\n\tl.calculateOutputSize()\n\tl.loadKernels()\n\tl.allocateMemory()\n\n\treturn l\n}", "func ExampleConv() {\n\n\tconv := cnns.NewConvLayer(&tensor.TDsize{X: 9, Y: 8, Z: 1}, 1, 3, 1)\n\trelu := cnns.NewReLULayer(conv.GetOutputSize())\n\tmaxpool := cnns.NewPoolingLayer(relu.GetOutputSize(), 2, 2, \"max\", \"valid\")\n\tfullyconnected := cnns.NewFullyConnectedLayer(maxpool.GetOutputSize(), 3)\n\n\tconvCustomWeights := mat.NewDense(3, 3, []float64{\n\t\t0.10466029, -0.06228581, -0.43436298,\n\t\t0.44050909, -0.07536250, -0.34348075,\n\t\t0.16456005, 0.18682307, -0.40303048,\n\t})\n\tconv.SetCustomWeights([]*mat.Dense{convCustomWeights})\n\n\tfcCustomWeights := mat.NewDense(3, maxpool.GetOutputSize().Total(), []float64{\n\t\t-0.19908814, 0.01521263, 0.31363996, -0.28573613, -0.11934281, -0.18194183, -0.03111016, -0.21696585, -0.20689814,\n\t\t0.17908468, -0.28144695, -0.29681312, -0.13912858, 0.07067328, 0.36249144, -0.20688576, -0.20291744, 0.25257304,\n\t\t-0.29341734, 0.36533501, 0.19671917, 0.02382031, -0.47169692, -0.34167172, 0.10725344, 0.47524162, -0.42054638,\n\t})\n\tfullyconnected.SetCustomWeights([]*mat.Dense{fcCustomWeights})\n\n\tnet := cnns.WholeNet{\n\t\tLP: cnns.NewLearningParametersDefault(),\n\t}\n\tnet.Layers = append(net.Layers, conv)\n\tnet.Layers = append(net.Layers, relu)\n\tnet.Layers = append(net.Layers, maxpool)\n\tnet.Layers = append(net.Layers, fullyconnected)\n\n\timage := mat.NewDense(9, 8, []float64{\n\t\t-0.1, 0.2, 0.3, 0.4, 0.5, 0.6, 0.7, 0.8,\n\t\t-0.9, -0.10, 0.11, 0.12, 0.13, 0.14, 0.15, 0.16,\n\t\t-0.17, 0.18, -0.19, 0.20, 0.21, 0.22, 0.23, 0.24,\n\t\t-0.25, 0.26, 0.27, -0.28, 0.29, 0.30, 0.31, 0.32,\n\t\t-0.33, 0.34, 0.35, 0.36, -0.37, 0.38, 0.39, 0.40,\n\t\t-0.41, 0.42, 0.43, 0.44, 0.45, -0.46, 0.47, 0.48,\n\t\t-0.49, 0.50, 0.51, 0.52, 0.53, 0.54, -0.55, 0.56,\n\t\t-0.57, 0.58, 0.59, 0.60, 0.61, 0.62, 0.63, -0.64,\n\t\t-0.65, 0.66, 0.67, 0.68, 0.69, 0.70, 0.71, 0.72,\n\t})\n\n\tfmt.Printf(\"Layers weights:\\n\")\n\tfor i := range net.Layers {\n\t\tfmt.Printf(\"%s #%d weights:\\n\", net.Layers[i].GetType(), i)\n\t\tnet.Layers[i].PrintWeights()\n\t}\n\tfmt.Println(\"\\tDoing training....\")\n\tfor e := 0; e < 3; e++ {\n\t\terr := net.FeedForward(image)\n\t\tif err != nil {\n\t\t\tlog.Printf(\"Feedforward caused error: %s\", err.Error())\n\t\t\treturn\n\t\t}\n\t\tdesired := mat.NewDense(3, 1, []float64{0.32, 0.45, 0.96})\n\t\terr = net.Backpropagate(desired)\n\t\tif err != nil {\n\t\t\tlog.Printf(\"Backpropagate caused error: %s\", err.Error())\n\t\t\treturn\n\t\t}\n\n\t\tfmt.Printf(\"Epoch #%d. New layers weights\\n\", e)\n\t\tfor i := range net.Layers {\n\t\t\tfmt.Printf(\"%s #%d weights on epoch #%d:\\n\", net.Layers[i].GetType(), i, e)\n\t\t\tnet.Layers[i].PrintWeights()\n\t\t}\n\t}\n\n}", "func worker(threads int, doneWorker chan<- bool, imageTasks <-chan *imagetask.ImageTask, imageResults chan<- *imagetask.ImageTask) {\n\n\t// Initial placing image chunks in to a channel for filter to consume.\n\tchunkStreamGenerator := func(done <- chan interface{}, imageChunks []*imagetask.ImageTask) chan *imagetask.ImageTask {\n\t\tchunkStream := make(chan *imagetask.ImageTask)\n\t\tgo func() {\n\t\t\tdefer close(chunkStream)\n\t\t\tfor _, chunk := range imageChunks {\n\t\t\t\tselect {\n\t\t\t\tcase <-done:\n\t\t\t\t\treturn\n\t\t\t\tcase chunkStream <- chunk:\n\t\t\t\t}\n\t\t\t}\n\t\t}()\n\t\treturn chunkStream\n\t}\n\n\t// Filter applies a filter in a pipeline fashion. \n\t// A goroutine is spawned for each chunk that needs to be filtered (which is numOfThreads chunks for each filter effect)\n\tfilter := func(threads int, effect string, effectNum int, done <- chan interface{}, chunkStream chan *imagetask.ImageTask) chan *imagetask.ImageTask {\n\t\tfilterStream := make(chan *imagetask.ImageTask, threads) // Only numOfThreads image chunks should be in the local filter channel.\n\t\tdonefilterChunk := make(chan bool)\n\t\tfor chunk := range chunkStream { // For each image chunk ...\n\t\t\tif effectNum > 0 {\n\t\t\t\tchunk.Img.UpdateInImg() // Replace inImg with outImg if not the first effect to compund effects.\n\t\t\t}\t\n\t\t\tgo func(chunk *imagetask.ImageTask) { // Spawn a goroutine for each chunk, which is equal to the numOfThreads. Each goroutine works on a portion of the image.\n\t\t\t\tselect {\n\t\t\t\tcase <-done:\n\t\t\t\t\tdonefilterChunk <- true\n\t\t\t\t\treturn\n\t\t\t\tcase filterStream <- chunk:\n\t\t\t\t\tif effect != \"G\" {\n\t\t\t\t\t\tchunk.Img.ApplyConvolution(effect) // Can wait to apply effect until after chunk is in the channel because has to wait for all goroutines to finish before it can move on to the next filter for a given image.\n\t\t\t\t\t} else {\n\t\t\t\t\t\tchunk.Img.Grayscale()\n\t\t\t\t\t}\n\t\t\t\t\tdonefilterChunk <- true // Indicate that the filtering is done for the given chunk.\n\t\t\t\t}\n\t\t\t}(chunk)\n\t\t}\n\t\tfor i := 0; i < threads; i ++ { // Wait for all portions to be put through one filter because of image dependencies with convolution.\n\t\t\t<-donefilterChunk\n\t\t}\n\t\treturn filterStream\n\t}\n\n\t// While there are more image tasks to grab ...\n\tfor true {\n\t\t// Grab image task from image task channel.\t\n\t\timgTask, more := <-imageTasks\n\n\t\t// If you get an image task, split up the image in to even chunks by y-pixels.\n\t\tif more {\n\t\t\timageChunks := imgTask.SplitImage(threads)\n\t\t\t\n\t\t\t// Iterate through filters on image chunks.\n\t\t\t// Will spawn a goroutine for each chunk in each filter (n goroutines per filter)\n\t\t\tdone := make(chan interface{})\n\t\t\tdefer close(done)\n\t\t\tchunkStream := chunkStreamGenerator(done, imageChunks)\n\t\t\tfor i := 0; i < len(imgTask.Effects); i++ {\n\t\t\t\teffect := imgTask.Effects[i]\n\t\t\t\tchunkStream = filter(threads, effect, i, done, chunkStream)\n\t\t\t\tclose(chunkStream)\n\t\t\t}\n\n\t\t\t// Put the image back together.\n\t\t\treconstructedImage, _ := imgTask.Img.NewImage()\n\t\t\tfor imgChunk := range chunkStream {\n\t\t\t\treconstructedImage.ReAddChunk(imgChunk.Img, imgChunk.YPixelStart, imgChunk.ChunkPart)\n\t\t\t}\n\t\t\timgTask.Img = reconstructedImage\n\t\t\timageResults <- imgTask // Send image to results channel to be saved.\n\n\t\t} else { // Otherwise, if there are no more image tasks, then goroutine worker exits.\n\t\t\tdoneWorker <- true // Indicate that the worker is done.\n\t\t\treturn\n\t\t}\n\t}\n}", "func BoxFilter(src, dst []float64, width int, border Border) {\n\t// TODO optimize\n\talpha := 1.0 / float64(width)\n\tkernel := make([]float64, width)\n\tfor i := range kernel {\n\t\tkernel[i] = alpha\n\t}\n\tConvolve(src, dst, kernel, border)\n}", "func ConcurrentEdgeFilter(imgSrc image.Image) image.Image {\n\tngo:=runtime.NumCPU()\n\tout := make(chan portion)\n\tslices := imagetools.CropChevauchement(imgSrc, ngo, 10) //on laisse 5 pixels de chevauchement\n\n\tfor i := 0; i < ngo; i++ {\n\t\tgo edgWorker(i, out, slices[i][0])\n\t}\n\n\tfor i := 0; i < ngo; i++ {\n\t\tslice := <-out\n\t\tslices[slice.id][0] = slice.img\n\t}\n\n\timgEnd := imagetools.RebuildChevauchement(slices, 10)\n\n\treturn imgEnd\n\n}", "func convolutionMatrixSampleFunction(im ImageMatrix, imagePositionX int, imagePositionY int, kernelPixelX int, kernelPixel int, colour color.RGBA, distance float64) int {\n\tif distance < 1 {\n\t\treturn 1\n\t}\n\n\tif colour.R > 150 && colour.G < 100 && colour.B < 100 {\n\t\treturn int(5 * distance)\n\t}\n\n\treturn 5\n}", "func (b *Bilateral) Apply(t *Tensor) *Tensor {\n\tdistances := NewTensor(b.KernelSize, b.KernelSize, 1)\n\tcenter := b.KernelSize / 2\n\tfor i := 0; i < b.KernelSize; i++ {\n\t\tfor j := 0; j < b.KernelSize; j++ {\n\t\t\t*distances.At(i, j, 0) = float32((i-center)*(i-center) + (j-center)*(j-center))\n\t\t}\n\t}\n\n\t// Pad with very large negative numbers to prevent\n\t// the filter from incorporating the padding.\n\tpadded := t.Add(100).Pad(center, center, center, center).Add(-100)\n\tout := NewTensor(t.Height, t.Width, t.Depth)\n\tPatches(padded, b.KernelSize, 1, func(idx int, patch *Tensor) {\n\t\tb.blurPatch(distances, patch, out.Data[idx*out.Depth:(idx+1)*out.Depth])\n\t})\n\n\treturn out\n}", "func ExampleConv2() {\n\n\tconv := cnns.NewConvLayer(&tensor.TDsize{X: 5, Y: 5, Z: 3}, 1, 3, 2)\n\trelu := cnns.NewReLULayer(conv.GetOutputSize())\n\tmaxpool := cnns.NewPoolingLayer(relu.GetOutputSize(), 2, 2, \"max\", \"valid\")\n\tfullyconnected := cnns.NewFullyConnectedLayer(maxpool.GetOutputSize(), 2)\n\n\tnet := cnns.WholeNet{\n\t\tLP: cnns.NewLearningParametersDefault(),\n\t}\n\tnet.Layers = append(net.Layers, conv)\n\tnet.Layers = append(net.Layers, relu)\n\tnet.Layers = append(net.Layers, maxpool)\n\tnet.Layers = append(net.Layers, fullyconnected)\n\n\tredChannel := mat.NewDense(5, 5, []float64{\n\t\t1, 0, 1, 0, 2,\n\t\t1, 1, 3, 2, 1,\n\t\t1, 1, 0, 1, 1,\n\t\t2, 3, 2, 1, 3,\n\t\t0, 2, 0, 1, 0,\n\t})\n\tgreenChannel := mat.NewDense(5, 5, []float64{\n\t\t1, 0, 0, 1, 0,\n\t\t2, 0, 1, 2, 0,\n\t\t3, 1, 1, 3, 0,\n\t\t0, 3, 0, 3, 2,\n\t\t1, 0, 3, 2, 1,\n\t})\n\tblueChannel := mat.NewDense(5, 5, []float64{\n\t\t2, 0, 1, 2, 1,\n\t\t3, 3, 1, 3, 2,\n\t\t2, 1, 1, 1, 0,\n\t\t3, 1, 3, 2, 0,\n\t\t1, 1, 2, 1, 1,\n\t})\n\n\tkernel1R := mat.NewDense(3, 3, []float64{\n\t\t0, 1, 0,\n\t\t0, 0, 2,\n\t\t0, 1, 0,\n\t})\n\tkernel1G := mat.NewDense(3, 3, []float64{\n\t\t2, 1, 0,\n\t\t0, 0, 0,\n\t\t0, 3, 0,\n\t})\n\tkernel1B := mat.NewDense(3, 3, []float64{\n\t\t1, 0, 0,\n\t\t1, 0, 0,\n\t\t0, 0, 2,\n\t})\n\n\tkernel2R := mat.NewDense(3, 3, []float64{\n\t\t0, -1, 0,\n\t\t0, 0, 2,\n\t\t0, 1, 0,\n\t})\n\tkernel2G := mat.NewDense(3, 3, []float64{\n\t\t2, 1, 0,\n\t\t0, 0, 0,\n\t\t0, -3, 0,\n\t})\n\tkernel2B := mat.NewDense(3, 3, []float64{\n\t\t1, 0, 0,\n\t\t1, 0, 0,\n\t\t0, 0, -2,\n\t})\n\n\timg2 := &mat.Dense{}\n\timg2.Stack(redChannel, greenChannel)\n\timage := &mat.Dense{}\n\timage.Stack(img2, blueChannel)\n\n\tkernel1 := &mat.Dense{}\n\tkernel1.Stack(kernel1R, kernel1G)\n\tconvCustomWeights1 := &mat.Dense{}\n\tconvCustomWeights1.Stack(kernel1, kernel1B)\n\n\tkernel2 := &mat.Dense{}\n\tkernel2.Stack(kernel2R, kernel2G)\n\tconvCustomWeights2 := &mat.Dense{}\n\tconvCustomWeights2.Stack(kernel2, kernel2B)\n\tconv.SetCustomWeights([]*mat.Dense{convCustomWeights1, convCustomWeights2})\n\n\tfcCustomWeights := mat.NewDense(2, maxpool.GetOutputSize().Total(), []float64{\n\t\t-0.19908814, 0.01521263,\n\t\t0.17908468, -0.28144695,\n\t})\n\tfullyconnected.SetCustomWeights([]*mat.Dense{fcCustomWeights})\n\n\tfmt.Printf(\"Layers weights:\\n\")\n\tfor i := range net.Layers {\n\t\tfmt.Printf(\"%s #%d weights:\\n\", net.Layers[i].GetType(), i)\n\t\tnet.Layers[i].PrintWeights()\n\t}\n\n\tfmt.Println(\"\\tDoing training....\")\n\tfor e := 0; e < 1; e++ {\n\t\terr := net.FeedForward(image)\n\t\tif err != nil {\n\t\t\tlog.Printf(\"Feedforward caused error: %s\", err.Error())\n\t\t\treturn\n\t\t}\n\n\t\tdesired := mat.NewDense(2, 1, []float64{0.15, 0.8})\n\t\terr = net.Backpropagate(desired)\n\t\tif err != nil {\n\t\t\tlog.Printf(\"Backpropagate caused error: %s\", err.Error())\n\t\t\treturn\n\t\t}\n\n\t\tfmt.Printf(\"Epoch #%d. New layers weights\\n\", e)\n\t\tfor i := range net.Layers {\n\t\t\tfmt.Printf(\"%s #%d weights on epoch #%d:\\n\", net.Layers[i].GetType(), i, e)\n\t\t\tnet.Layers[i].PrintWeights()\n\t\t}\n\t}\n}", "func NewFilter(bitmapSize int32) Filter {\n\treturn Filter{\n\t\tbitmapSize: bitmapSize,\n\t\tbitmap: make([]bool, bitmapSize, bitmapSize),\n\t\tnumberMapper: NewNumberMapper(minInt32, maxInt32, 0, bitmapSize-1),\n\t}\n}", "func SpectralConvolution(spectrum []int) []int {\n\tvar convolution []int\n\tfor i := 0; i < len(spectrum)-1; i++ {\n\t\tfor j := i + 1; j < len(spectrum); j++ {\n\t\t\tval := spectrum[j] - spectrum[i]\n\t\t\tif val > 0 {\n\t\t\t\tconvolution = append(convolution, val)\n\t\t\t}\n\t\t}\n\t}\n\treturn convolution\n}", "func (f *Filter) Init(x *mat64.Vector, v mat64.Matrix) error {\n\n\trF, cF := f.F.Dims()\n\n\t//\n\t// X\n\t//\n\n\tif x == nil {\n\t\tf.X = mat64.NewVector(cF, nil)\n\n\t} else {\n\t\trX, _ := x.Dims()\n\t\tif rX != cF {\n\t\t\treturn errors.New(\"row dim of x must be matched to column dim of F\")\n\t\t}\n\t\tf.X = x\n\t}\n\n\t//\n\t// V\n\t//\n\n\tif v == nil {\n\t\tvar m *mat64.Dense\n\t\tm.Mul(f.G, f.Q)\n\t\tf.V.Mul(m, f.G.T())\n\n\t} else {\n\t\trV, cV := v.Dims()\n\t\tif rV != cV {\n\t\t\treturn errors.New(\"V must be square matrix\")\n\t\t}\n\t\tif rV != rF {\n\t\t\treturn errors.New(\"row dim of V must be matched to row dim of F\")\n\t\t}\n\n\t\tf.V = mat64.DenseCopyOf(v)\n\t}\n\n\treturn nil\n}", "func Contrast(percentage float32) Filter {\n\tif percentage == 0 {\n\t\treturn &copyimageFilter{}\n\t}\n\n\tp := 1 + minf32(maxf32(percentage, -100), 100)/100\n\n\treturn &colorchanFilter{\n\t\tfn: func(x float32) float32 {\n\t\t\tif 0 <= p && p <= 1 {\n\t\t\t\treturn 0.5 + (x-0.5)*p\n\t\t\t} else if 1 < p && p < 2 {\n\t\t\t\treturn 0.5 + (x-0.5)*(1/(2.0-p))\n\t\t\t} else {\n\t\t\t\tif x < 0.5 {\n\t\t\t\t\treturn 0\n\t\t\t\t}\n\t\t\t\treturn 1\n\t\t\t}\n\t\t},\n\t\tlut: false,\n\t}\n}", "func SeparableFilter2D(target uint32, internalformat uint32, width int32, height int32, format uint32, xtype uint32, row unsafe.Pointer, column unsafe.Pointer) {\n C.glowSeparableFilter2D(gpSeparableFilter2D, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), row, column)\n}", "func MakeCubicFilter(b float64, c float64) *Filter {\n\tvar radius float64\n\tif b == 0 && c == 0 {\n\t\tradius = 1.0\n\t} else {\n\t\tradius = 2.0\n\t}\n\tf := new(Filter)\n\tf.F = func(x float64, scaleFactor float64) float64 {\n\t\tif x < 1.0 {\n\t\t\treturn ((12.0-9.0*b-6.0*c)*x*x*x +\n\t\t\t\t(-18.0+12.0*b+6.0*c)*x*x +\n\t\t\t\t(6.0 - 2.0*b)) / 6.0\n\t\t} else if x < 2.0 {\n\t\t\treturn ((-b-6.0*c)*x*x*x +\n\t\t\t\t(6.0*b+30.0*c)*x*x +\n\t\t\t\t(-12.0*b-48.0*c)*x +\n\t\t\t\t(8.0*b + 24.0*c)) / 6.0\n\t\t}\n\t\treturn 0.0\n\t}\n\tf.Radius = func(scaleFactor float64) float64 {\n\t\treturn radius\n\t}\n\treturn f\n}", "func Dilation2DBackpropFilter(scope *Scope, input tf.Output, filter tf.Output, out_backprop tf.Output, strides []int64, rates []int64, padding string) (filter_backprop tf.Output) {\n\tif scope.Err() != nil {\n\t\treturn\n\t}\n\tattrs := map[string]interface{}{\"strides\": strides, \"rates\": rates, \"padding\": padding}\n\topspec := tf.OpSpec{\n\t\tType: \"Dilation2DBackpropFilter\",\n\t\tInput: []tf.Input{\n\t\t\tinput, filter, out_backprop,\n\t\t},\n\t\tAttrs: attrs,\n\t}\n\top := scope.AddOperation(opspec)\n\treturn op.Output(0)\n}", "func (img *FloatImage) ConvolveWrap(kernel *ConvKernel) *FloatImage {\n\treturn img.convolve(kernel, wrapPlaneExtension)\n}", "func (t1 *Tensor) Convolve2D(kernel *Tensor, stride int) (*Tensor, error) {\n\toutTensor := NewTensor((t1.Size.X-kernel.Size.X)/stride+1, (t1.Size.Y-kernel.Size.Y)/stride+1, t1.Size.Z)\n\tfor x := 0; x < outTensor.Size.X; x++ {\n\t\tfor y := 0; y < outTensor.Size.Y; y++ {\n\t\t\tmappedX, mappedY := x*stride, y*stride\n\t\t\tfor i := 0; i < kernel.Size.X; i++ {\n\t\t\t\tfor j := 0; j < kernel.Size.X; j++ {\n\t\t\t\t\tfor z := 0; z < t1.Size.Z; z++ {\n\t\t\t\t\t\tf := kernel.Get(i, j, z)\n\t\t\t\t\t\tv := t1.Get(mappedX+i, mappedY+j, z)\n\t\t\t\t\t\toutTensor.SetAdd(x, y, z, f*v)\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\treturn outTensor, nil\n}", "func Catnip(cfg *Config) error {\n\t// allocate as much as possible as soon as possible\n\tvar (\n\n\t\t// slowMax/fastMax\n\t\tslowMax = ((int(ScalingSlowWindow * cfg.SampleRate)) / cfg.SampleSize) * 2\n\t\tfastMax = ((int(ScalingFastWindow * cfg.SampleRate)) / cfg.SampleSize) * 2\n\n\t\ttotal = ((cfg.ChannelCount * cfg.SampleSize) * 2) + (slowMax + fastMax)\n\n\t\tfloatData = make([]float64, total)\n\t)\n\n\tvar sessConfig = input.SessionConfig{\n\t\tFrameSize: cfg.ChannelCount,\n\t\tSampleSize: cfg.SampleSize,\n\t\tSampleRate: cfg.SampleRate,\n\t}\n\n\tvis := visualizer{\n\t\tcfg: cfg,\n\t\tslowWindow: util.MovingWindow{\n\t\t\tCapacity: slowMax,\n\t\t\tData: floatData[:slowMax],\n\t\t},\n\t\tfastWindow: util.MovingWindow{\n\t\t\tCapacity: fastMax,\n\t\t\tData: floatData[slowMax : slowMax+fastMax],\n\t\t},\n\n\t\tfftBuf: make([]complex128, cfg.SampleSize/2+1),\n\t\tinputBufs: make([][]float64, cfg.ChannelCount),\n\t\tbarBufs: make([][]float64, cfg.ChannelCount),\n\n\t\tplans: make([]*fft.Plan, cfg.ChannelCount),\n\t\tspectrum: dsp.Spectrum{\n\t\t\tSampleRate: cfg.SampleRate,\n\t\t\tSampleSize: cfg.SampleSize,\n\t\t\tBins: make([]dsp.Bin, cfg.SampleSize),\n\t\t\tOldValues: make([][]float64, cfg.ChannelCount),\n\t\t},\n\n\t\tbars: 0,\n\t\tdisplay: graphic.Display{},\n\t}\n\n\tvar pos = slowMax + fastMax\n\tfor idx := range vis.barBufs {\n\n\t\tvis.barBufs[idx] = floatData[pos : pos+cfg.SampleSize]\n\t\tpos += cfg.SampleSize\n\n\t\tvis.inputBufs[idx] = floatData[pos : pos+cfg.SampleSize]\n\t\tpos += cfg.SampleSize\n\n\t\tvis.plans[idx] = &fft.Plan{\n\t\t\tInput: vis.inputBufs[idx],\n\t\t\tOutput: vis.fftBuf,\n\t\t}\n\n\t\tvis.spectrum.OldValues[idx] = make([]float64, cfg.SampleSize)\n\n\t\tvis.plans[idx].Init()\n\t}\n\n\t// INPUT SETUP\n\n\tvar backend, err = initBackend(cfg)\n\tif err != nil {\n\t\treturn err\n\t}\n\n\tif sessConfig.Device, err = getDevice(backend, cfg); err != nil {\n\t\treturn err\n\t}\n\n\taudio, err := backend.Start(sessConfig)\n\tdefer backend.Close()\n\n\tif err != nil {\n\t\treturn errors.Wrap(err, \"failed to start the input backend\")\n\t}\n\n\tvis.spectrum.SetSmoothing(cfg.SmoothFactor)\n\tvis.spectrum.SetWinVar(cfg.WinVar)\n\n\tif err = vis.display.Init(); err != nil {\n\t\treturn err\n\t}\n\tdefer vis.display.Close()\n\n\tvis.display.SetSizes(cfg.BarSize, cfg.SpaceSize)\n\tvis.display.SetBase(cfg.BaseSize)\n\tvis.display.SetDrawType(graphic.DrawType(cfg.DrawType))\n\tvis.display.SetStyles(cfg.Styles)\n\n\t// Root Context\n\tctx, cancel := context.WithCancel(context.Background())\n\tdefer cancel()\n\n\t// Start the display\n\t// replace our context so display can signal quit\n\tctx = vis.display.Start(ctx)\n\tdefer vis.display.Stop()\n\n\tif err := audio.Start(ctx, vis.inputBufs, &vis); err != nil {\n\t\treturn errors.Wrap(err, \"failed to start input session\")\n\t}\n\n\treturn nil\n}", "func Conv2DBackpropFilter(scope *Scope, input tf.Output, filter_sizes tf.Output, out_backprop tf.Output, strides []int64, padding string, optional ...Conv2DBackpropFilterAttr) (output tf.Output) {\n\tif scope.Err() != nil {\n\t\treturn\n\t}\n\tattrs := map[string]interface{}{\"strides\": strides, \"padding\": padding}\n\tfor _, a := range optional {\n\t\ta(attrs)\n\t}\n\topspec := tf.OpSpec{\n\t\tType: \"Conv2DBackpropFilter\",\n\t\tInput: []tf.Input{\n\t\t\tinput, filter_sizes, out_backprop,\n\t\t},\n\t\tAttrs: attrs,\n\t}\n\top := scope.AddOperation(opspec)\n\treturn op.Output(0)\n}", "func SeparableFilter2D(target uint32, internalformat uint32, width int32, height int32, format uint32, xtype uint32, row unsafe.Pointer, column unsafe.Pointer) {\n\tC.glowSeparableFilter2D(gpSeparableFilter2D, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), row, column)\n}", "func (n *Node) Convconst(con *Node, t *Type)", "func NewWithdrawableFilterer(address common.Address, filterer bind.ContractFilterer) (*WithdrawableFilterer, error) {\n\tcontract, err := bindWithdrawable(address, nil, nil, filterer)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\treturn &WithdrawableFilterer{contract: contract}, nil\n}", "func (cc *ConvolutionCoder) Encode(data []byte) (output []byte) {\n\tframeBits := cc.EncodedSize(len(data))\n\tbl := frameBits/8 + 1\n\n\tif frameBits%8 == 0 {\n\t\tbl -= 1\n\t}\n\n\toutput = make([]byte, bl)\n\n\tcorrectwrap.Correct_convolutional_encode(cc.cc, &data[0], int64(len(data)), &output[0])\n\n\treturn output\n}", "func (ev *ImgEnv) FilterImg() {\n\tev.XFormRand.Gen(&ev.XForm)\n\toimg := ev.Images[ev.ImageIdx.Cur]\n\t// following logic first extracts a sub-image of 2x the ultimate filtered size of image\n\t// from original image, which greatly speeds up the xform processes, relative to working\n\t// on entire 800x600 original image\n\tinsz := ev.Vis.Geom.In.Mul(2) // target size * 2\n\tibd := oimg.Bounds()\n\tisz := ibd.Size()\n\tirng := isz.Sub(insz)\n\tvar st image.Point\n\tst.X = rand.Intn(irng.X)\n\tst.Y = rand.Intn(irng.Y)\n\ted := st.Add(insz)\n\tsimg := oimg.SubImage(image.Rectangle{Min: st, Max: ed})\n\timg := ev.XForm.Image(simg)\n\tev.Vis.Filter(img)\n}", "func (img *FloatImage) ConvolveWrapWith(kernel *ConvKernel, px planeExtension) {\n\timg.convolveWith(kernel, wrapPlaneExtension)\n}", "func (af *filtBase) initWeights(w []float64, n int) error {\n\tif n <= 0 {\n\t\tn = af.n\n\t}\n\tif w == nil {\n\t\tw = make([]float64, n)\n\t}\n\tif len(w) != n {\n\t\treturn fmt.Errorf(\"the length of slice `w` and `n` must agree. len(w): %d, n: %d\", len(w), n)\n\t}\n\taf.w = mat.NewDense(1, n, w)\n\n\treturn nil\n}", "func Conv2DBackpropFilterUseCudnnOnGpu(value bool) Conv2DBackpropFilterAttr {\n\treturn func(m optionalAttr) {\n\t\tm[\"use_cudnn_on_gpu\"] = value\n\t}\n}", "func NewFilter(config *config.Config) (filter *Filter) {\n\tfilter = new(Filter)\n\tfilter.Config = config\n\treturn\n}", "func NewFilter() *Builder {\n\treturn &Builder{}\n}", "func clientFilter(node *Node, isBuffered bool, udata userdata, push func(*Node, uint32),\n\tpushBuf func(*Node, interface{}, uint32)) error {\n\t//\n\tuserfunc := udata.filterdata.(Predicate)\n\tserial := udata.serial\n\tn, err := userfunc(node, node)\n\tif n != nil && err != nil {\n\t\tpush(n, serial) // forward filtered node to next pipeline stage\n\t}\n\treturn err\n}", "func NewFilter(P uint8, key [KeySize]byte, data [][]byte) (*Filter, error) {\n\t// Some initial parameter checks: make sure we have data from which to\n\t// build the filter, and make sure our parameters will fit the hash\n\t// function we're using.\n\tif len(data) == 0 {\n\t\treturn nil, ErrNoData\n\t}\n\tif len(data) > math.MaxInt32 {\n\t\treturn nil, ErrNTooBig\n\t}\n\tif P > 32 {\n\t\treturn nil, ErrPTooBig\n\t}\n\n\t// Create the filter object and insert metadata.\n\tmodP := uint64(1 << P)\n\tmodPMask := modP - 1\n\tf := Filter{\n\t\tn: uint32(len(data)),\n\t\tp: P,\n\t\tmodulusNP: uint64(len(data)) * modP,\n\t}\n\n\t// Allocate filter data.\n\tvalues := make([]uint64, 0, len(data))\n\n\t// Insert the hash (modulo N*P) of each data element into a slice and\n\t// sort the slice.\n\tk0 := binary.LittleEndian.Uint64(key[0:8])\n\tk1 := binary.LittleEndian.Uint64(key[8:16])\n\tfor _, d := range data {\n\t\tv := siphash.Hash(k0, k1, d) % f.modulusNP\n\t\tvalues = append(values, v)\n\t}\n\tsort.Sort((*uint64s)(&values))\n\n\tvar b bitWriter\n\n\t// Write the sorted list of values into the filter bitstream,\n\t// compressing it using Golomb coding.\n\tvar value, lastValue, remainder uint64\n\tfor _, v := range values {\n\t\t// Calculate the difference between this value and the last,\n\t\t// modulo P.\n\t\tremainder = (v - lastValue) & modPMask\n\n\t\t// Calculate the difference between this value and the last,\n\t\t// divided by P.\n\t\tvalue = (v - lastValue - remainder) >> f.p\n\t\tlastValue = v\n\n\t\t// Write the P multiple into the bitstream in unary; the\n\t\t// average should be around 1 (2 bits - 0b10).\n\t\tfor value > 0 {\n\t\t\tb.writeOne()\n\t\t\tvalue--\n\t\t}\n\t\tb.writeZero()\n\n\t\t// Write the remainder as a big-endian integer with enough bits\n\t\t// to represent the appropriate collision probability.\n\t\tb.writeNBits(remainder, uint(f.p))\n\t}\n\n\t// Save the filter data internally as n + filter bytes\n\tndata := make([]byte, 4+len(b.bytes))\n\tbinary.BigEndian.PutUint32(ndata, f.n)\n\tcopy(ndata[4:], b.bytes)\n\tf.filterNData = ndata\n\n\treturn &f, nil\n}", "func StepConvolution() *Step {\n\t// TODO\n\treturn nil\n}", "func (r *Ri) PixelFilter(filterfunc RtFilterFunc, xwidth, ywidth RtFloat) error {\n\treturn r.writef(\"PixelFilter\", filterfunc, xwidth, ywidth)\n}", "func dontModifyConvolutionMatrixWeights(im ImageMatrix, imagePositionX int, imagePositionY int, kernelPixelX int, kernelPixel int, colour color.RGBA, distance float64) int {\n\treturn 1\n}", "func (l *Conv2D) Forward(inputTensor tensor.Tensor) tensor.Tensor {\n\tl.inputSizeMustMatch(inputTensor)\n\n\tsave := inputTensor.(*Tensor)\n\tl.saveInput(save)\n\n\tbatchSize := l.inputBatchSize(inputTensor)\n\n\tinput := save\n\toutputSize := []int{\n\t\tl.outputSize[0],\n\t\tbatchSize,\n\t\tl.outputSize[1],\n\t\tl.outputSize[2],\n\t}\n\n\toutputHeight := outputSize[2]\n\toutputWidth := outputSize[3]\n\n\tim2ColMatrixHeight := l.numChannels() * l.kernelWidth() * l.kernelHeight()\n\tim2ColMatrixWidth := outputWidth * outputHeight * batchSize\n\tim2ColMatrix := l.TensorOperator.CreateTensor(\n\t\t[]int{im2ColMatrixHeight, im2ColMatrixWidth})\n\tdefer l.TensorOperator.Free(im2ColMatrix)\n\n\tl.im2Col(input, im2ColMatrix,\n\t\t[2]int{l.kernelWidth(), l.kernelHeight()},\n\t\t[4]int{l.padding[0], l.padding[1], l.padding[2], l.padding[3]},\n\t\t[2]int{l.stride[0], l.stride[1]},\n\t\t[2]int{0, 0},\n\t)\n\n\tkernelMatrixWidth := l.kernelWidth() * l.kernelHeight() * l.numChannels()\n\tkernelMatrixHeight := l.numKernels()\n\tkernelMatrix := l.kernel.Reshape(\n\t\t[]int{kernelMatrixHeight, kernelMatrixWidth})\n\n\thKernelData := make([]float32, kernelMatrixWidth*kernelMatrixHeight)\n\tl.GPUDriver.MemCopyD2H(l.GPUCtx, hKernelData, kernelMatrix.ptr)\n\n\toutputMatrix := l.TensorOperator.CreateTensor(\n\t\t[]int{kernelMatrixHeight, im2ColMatrixWidth})\n\tbiasTensor := l.TensorOperator.CreateTensor(\n\t\t[]int{batchSize, l.outputSize[0], l.outputSize[1], l.outputSize[2]})\n\tbiasTensorTrans := l.TensorOperator.CreateTensor(\n\t\t[]int{l.outputSize[0], batchSize, l.outputSize[1], l.outputSize[2]})\n\tl.TensorOperator.Repeat(l.bias, biasTensor, batchSize)\n\tl.TensorOperator.TransposeTensor(biasTensor, biasTensorTrans,\n\t\t[]int{1, 0, 2, 3})\n\tbiasMatrix := biasTensorTrans.Reshape(\n\t\t[]int{l.numKernels(), im2ColMatrixWidth})\n\n\tl.TensorOperator.Gemm(\n\t\tfalse, false,\n\t\tkernelMatrixHeight,\n\t\tim2ColMatrixWidth,\n\t\tkernelMatrixWidth,\n\t\t1.0, 1.0,\n\t\tkernelMatrix, im2ColMatrix, biasMatrix, outputMatrix)\n\n\toutput := &Tensor{\n\t\tdriver: l.GPUDriver,\n\t\tctx: l.GPUCtx,\n\t\tsize: outputSize,\n\t\tptr: outputMatrix.ptr,\n\t\tdescriptor: \"CNHW\",\n\t}\n\n\ttransposedOutput := l.TensorOperator.CreateTensor([]int{\n\t\tbatchSize,\n\t\tl.outputSize[0],\n\t\tl.outputSize[1],\n\t\tl.outputSize[2]})\n\tl.TensorOperator.TransposeTensor(\n\t\toutput, transposedOutput, []int{1, 0, 2, 3})\n\n\tl.TensorOperator.Free(biasTensor)\n\tl.TensorOperator.Free(biasTensorTrans)\n\tl.TensorOperator.Free(output)\n\n\treturn transposedOutput\n}", "func Conv3DBackpropFilter(scope *Scope, input tf.Output, filter tf.Output, out_backprop tf.Output, strides []int64, padding string, optional ...Conv3DBackpropFilterAttr) (output tf.Output) {\n\tif scope.Err() != nil {\n\t\treturn\n\t}\n\tattrs := map[string]interface{}{\"strides\": strides, \"padding\": padding}\n\tfor _, a := range optional {\n\t\ta(attrs)\n\t}\n\topspec := tf.OpSpec{\n\t\tType: \"Conv3DBackpropFilter\",\n\t\tInput: []tf.Input{\n\t\t\tinput, filter, out_backprop,\n\t\t},\n\t\tAttrs: attrs,\n\t}\n\top := scope.AddOperation(opspec)\n\treturn op.Output(0)\n}", "func newImageBinaryChannels(imgSrc image.Image, colorChannelTypes ...channelType) []*imageBinaryChannel {\n\tchannels := make([]*imageBinaryChannel, 3)\n\tmax := imgSrc.Bounds().Max\n\tw, h := max.X, max.Y\n\tfor i, channelType := range colorChannelTypes {\n\t\tcolorChannel := image.NewGray(image.Rectangle{Max: image.Point{w, h}})\n\t\tfor x := 0; x < w; x++ {\n\t\t\tfor y := 0; y < h; y++ {\n\t\t\t\tcolorPixel := imgSrc.At(x, y).(color.NRGBA)\n\t\t\t\tvar c uint8\n\t\t\t\tswitch channelType {\n\t\t\t\tcase red:\n\t\t\t\t\tc = colorPixel.R\n\t\t\t\tcase green:\n\t\t\t\t\tc = colorPixel.G\n\t\t\t\tcase blue:\n\t\t\t\t\tc = colorPixel.B\n\t\t\t\t}\n\t\t\t\tgrayPixel := color.Gray{Y: c}\n\t\t\t\tcolorChannel.Set(x, y, grayPixel)\n\t\t\t}\n\t\t}\n\t\tchannels[i] = newImageBinaryChannel(colorChannel, channelType)\n\t}\n\treturn channels\n}", "func NewFilter(size int) *Filter {\n\treturn &Filter{\n\t\tbufsize: size,\n\t\tbuf: make([]int, size),\n\t\tsum: 0,\n\t\tnextindex: 0,\n\t}\n}", "func Conv2D(t Tensor, k Tensor, hAxis int, wAxis int, fAxis int) Tensor {\n\tkh, kw := k.Shape()[0], k.Shape()[1]\n\treturn &Conv2DTensor{\n\t\tbaseTensor: base(conv2d(t, k, hAxis, wAxis, fAxis), 1, t, k),\n\t\tt: t,\n\t\tk: k,\n\t\thAxis: hAxis,\n\t\twAxis: wAxis,\n\t\tfAxis: fAxis,\n\t\tpadH: kh - 1,\n\t\tpadW: kw - 1,\n\t}\n}", "func initContainerFilter() {\n\tvar err error\n\tif filter, err = containers.GetSharedMetricFilter(); err != nil {\n\t\tlog.Errorf(\"Error initializing container filtering: %s\", err)\n\t}\n}", "func (cc *ConvolutionCoder) Decode(data []byte) (output []byte) {\n\tframeBits := int64(len(data)) * 8\n\toutput = make([]byte, int(frameBits)/(8*cc.r))\n\tcorrectwrap.Correct_convolutional_decode(cc.cc, &data[0], frameBits, &output[0])\n\n\treturn output\n}", "func newFiltBase(n int, mu float64, w []float64) (AdaptiveFilter, error) {\n\tvar err error\n\tp := new(filtBase)\n\tp.kind = \"Base filter\"\n\tp.n = n\n\tp.muMin = 0\n\tp.muMax = 1000\n\tp.mu, err = p.checkFloatParam(mu, p.muMin, p.muMax, \"mu\")\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\terr = p.initWeights(w, n)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\treturn p, nil\n}", "func (filter *Merge) Process(img *FilterImage) error {\n\tout := img.Image\n\tbounds := out.Bounds()\n\tinbounds := filter.Image.Bounds()\n\n\txmin := bounds.Min.X\n\tif xmin < inbounds.Min.X {\n\t\txmin = inbounds.Min.X\n\t}\n\txmax := bounds.Max.X\n\tif xmax > inbounds.Max.X {\n\t\txmax = inbounds.Max.X\n\t}\n\tymin := bounds.Min.Y\n\tif ymin < inbounds.Min.Y {\n\t\tymin = inbounds.Min.Y\n\t}\n\tymax := bounds.Max.Y\n\tif ymax > inbounds.Max.Y {\n\t\tymax = inbounds.Max.Y\n\t}\n\n\tfor x := xmin; x < xmax; x++ {\n\t\tfor y := ymin; y < ymax; y++ {\n\t\t\tr, g, b, a := out.At(x, y).RGBA()\n\t\t\tir, ig, ib, ia := filter.Image.At(x, y).RGBA()\n\n\t\t\tr = uint32(ClipInt(int(r + ir), 0, 0xFFFF))\n\t\t\tg = uint32(ClipInt(int(g + ig), 0, 0xFFFF))\n\t\t\tb = uint32(ClipInt(int(b + ib), 0, 0xFFFF))\n\t\t\ta = uint32(ClipInt(int(a + ia), 0, 0xFFFF))\n\n\t\t\tout.Set(x, y, color.NRGBA64{uint16(r), uint16(g), uint16(b), uint16(a)})\n\t\t}\n\t}\n\n\treturn nil\n}", "func (filter *Saturation) Process(img *FilterImage) error {\n\tout := img.Image\n\tbounds := out.Bounds()\n\tfor x := bounds.Min.X; x < bounds.Max.X; x++ {\n\t\tfor y := bounds.Min.Y; y < bounds.Max.Y; y++ {\n\t\t\tr, g, b, a := out.At(x, y).RGBA()\n\n\t\t\tgrey := (r + g + b) / 3\n\n\t\t\tnr := Trunc(r + ((Abs(int32(r-grey)) * filter.Strength) / 100))\n\t\t\tng := Trunc(g + ((Abs(int32(g-grey)) * filter.Strength) / 100))\n\t\t\tnb := Trunc(b + ((Abs(int32(b-grey)) * filter.Strength) / 100))\n\n\t\t\tnc := color.NRGBA64{nr, ng, nb, uint16(a)}\n\t\t\tout.Set(x, y, nc)\n\t\t}\n\t}\n\treturn nil\n}", "func (s *Signal) EmitFiltered(sender Ki, sig int64, data any, filtFun SignalFilterFunc) {\n\ts.Mu.RLock()\n\tfor recv, fun := range s.Cons {\n\t\tif s.DisconnectDestroyed(recv) {\n\t\t\tcontinue\n\t\t}\n\t\ts.Mu.RUnlock()\n\t\tif filtFun(recv) {\n\t\t\tfun(recv, sender, sig, data)\n\t\t}\n\t\ts.Mu.RLock()\n\t}\n\ts.Mu.RUnlock()\n}", "func CreateFilterRing(m *model3d.Mesh) *model3d.Mesh {\n\tcollider := model3d.MeshToCollider(m)\n\n\t// Pick a z-axis where we can slice the ring.\n\tsliceZ := 2 + m.Min().Z\n\t// Scale up the bitmap to get accurate resolution.\n\tconst scale = 20\n\n\tlog.Println(\"Tracing ring outline...\")\n\tmin := m.Min()\n\tsize := m.Max().Sub(min)\n\tbitmap := model2d.NewBitmap(int(size.X*scale), int(size.Y*scale))\n\tfor y := 0; y < bitmap.Height; y++ {\n\t\tfor x := 0; x < bitmap.Width; x++ {\n\t\t\trealX := min.X + float64(x)/scale\n\t\t\trealY := min.Y + float64(y)/scale\n\t\t\tnumColl := collider.RayCollisions(&model3d.Ray{\n\t\t\t\tOrigin: model3d.XYZ(realX, realY, sliceZ),\n\t\t\t\tDirection: model3d.X(1),\n\t\t\t}, nil)\n\t\t\tnumColl1 := collider.RayCollisions(&model3d.Ray{\n\t\t\t\tOrigin: model3d.XYZ(realX, realY, sliceZ),\n\t\t\t\tDirection: model3d.Coord3D{X: -1},\n\t\t\t}, nil)\n\t\t\tbitmap.Set(x, y, numColl == 2 && numColl1 == 2)\n\t\t}\n\t}\n\n\tsolid := NewRingSolid(bitmap, scale)\n\tsqueeze := &toolbox3d.AxisSqueeze{\n\t\tAxis: toolbox3d.AxisZ,\n\t\tMin: 1,\n\t\tMax: 4.5,\n\t\tRatio: 0.1,\n\t}\n\tlog.Println(\"Creating mesh...\")\n\tmesh := model3d.MarchingCubesConj(solid, 0.1, 8, squeeze)\n\tlog.Println(\"Done creating mesh...\")\n\tmesh = mesh.FlattenBase(0)\n\tmesh = mesh.EliminateCoplanar(1e-8)\n\treturn mesh\n}", "func (img *FloatImage) ConvolveClampWith(kernel *ConvKernel, px planeExtension) {\n\timg.convolveWith(kernel, clampPlaneExtension)\n}", "func (qb QueryBuilder) composeFilter() string {\n\tfilterBuilder := qb.getFilterBuilder().\n\t\tWithMetricType(qb.metricName).\n\t\tWithProject(qb.translator.config.Project).\n\t\tWithCluster(qb.translator.config.Cluster)\n\n\tresourceNames := qb.getResourceNames()\n\tif qb.translator.useNewResourceModel {\n\t\t// new resource model specific filters\n\t\tfilterBuilder = filterBuilder.WithLocation(qb.translator.config.Location)\n\t\tif !qb.nodes.isNodeValuesEmpty() {\n\t\t\t// node metrics\n\t\t\treturn filterBuilder.WithNodes(resourceNames).Build()\n\t\t}\n\t\t// pod metrics\n\t\treturn filterBuilder.\n\t\t\tWithNamespace(qb.namespace).\n\t\t\tWithPods(resourceNames).\n\t\t\tBuild()\n\n\t}\n\t// legacy resource model specific filters\n\treturn filterBuilder.\n\t\tWithContainer().\n\t\tWithPods(resourceNames).\n\t\tBuild()\n}", "func QuantizedConv2DPerChannel(scope *Scope, input tf.Output, filter tf.Output, min_input tf.Output, max_input tf.Output, min_filter tf.Output, max_filter tf.Output, strides []int64, padding string, optional ...QuantizedConv2DPerChannelAttr) (output tf.Output, min_output tf.Output, max_output tf.Output) {\n\tif scope.Err() != nil {\n\t\treturn\n\t}\n\tattrs := map[string]interface{}{\"strides\": strides, \"padding\": padding}\n\tfor _, a := range optional {\n\t\ta(attrs)\n\t}\n\topspec := tf.OpSpec{\n\t\tType: \"QuantizedConv2DPerChannel\",\n\t\tInput: []tf.Input{\n\t\t\tinput, filter, min_input, max_input, min_filter, max_filter,\n\t\t},\n\t\tAttrs: attrs,\n\t}\n\top := scope.AddOperation(opspec)\n\treturn op.Output(0), op.Output(1), op.Output(2)\n}", "func (r ApiGetHyperflexWitnessConfigurationListRequest) Filter(filter string) ApiGetHyperflexWitnessConfigurationListRequest {\n\tr.filter = &filter\n\treturn r\n}", "func Conv3DBackpropFilterV2(scope *Scope, input tf.Output, filter_sizes tf.Output, out_backprop tf.Output, strides []int64, padding string, optional ...Conv3DBackpropFilterV2Attr) (output tf.Output) {\n\tif scope.Err() != nil {\n\t\treturn\n\t}\n\tattrs := map[string]interface{}{\"strides\": strides, \"padding\": padding}\n\tfor _, a := range optional {\n\t\ta(attrs)\n\t}\n\topspec := tf.OpSpec{\n\t\tType: \"Conv3DBackpropFilterV2\",\n\t\tInput: []tf.Input{\n\t\t\tinput, filter_sizes, out_backprop,\n\t\t},\n\t\tAttrs: attrs,\n\t}\n\top := scope.AddOperation(opspec)\n\treturn op.Output(0)\n}", "func NewFilter(keys []uint32, bitsPerKey int) Filter {\n\treturn Filter(appendFilter(nil, keys, bitsPerKey))\n}", "func (o NetworkPacketCaptureOutput) Filters() NetworkPacketCaptureFilterArrayOutput {\n\treturn o.ApplyT(func(v *NetworkPacketCapture) NetworkPacketCaptureFilterArrayOutput { return v.Filters }).(NetworkPacketCaptureFilterArrayOutput)\n}", "func convDiffThr(wg *sync.WaitGroup, geom *Geom, yst, ny int, fltOn, fltOff *etensor.Float32, imgOn, imgOff, out *etensor.Float32, gain, gainOn float32) {\n\tist := geom.Border.Sub(geom.FiltLt)\n\tfor yi := 0; yi < ny; yi++ {\n\t\ty := yst + yi\n\t\tiy := int(ist.Y + y*geom.Spacing.Y)\n\t\tfor x := 0; x < geom.Out.X; x++ {\n\t\t\tix := ist.X + x*geom.Spacing.X\n\t\t\tvar sumOn, sumOff float32\n\t\t\tfi := 0\n\t\t\tfor fy := 0; fy < geom.FiltSz.Y; fy++ {\n\t\t\t\tfor fx := 0; fx < geom.FiltSz.X; fx++ {\n\t\t\t\t\tidx := imgOn.Offset([]int{iy + fy, ix + fx})\n\t\t\t\t\tsumOn += imgOn.Values[idx] * fltOn.Values[fi]\n\t\t\t\t\tsumOff += imgOff.Values[idx] * fltOff.Values[fi]\n\t\t\t\t\tfi++\n\t\t\t\t}\n\t\t\t}\n\t\t\tdiff := gain * (gainOn*sumOn - sumOff)\n\t\t\tif diff > 0 {\n\t\t\t\tout.Set([]int{0, y, x}, diff)\n\t\t\t\tout.Set([]int{1, y, x}, float32(0))\n\t\t\t} else {\n\t\t\t\tout.Set([]int{0, y, x}, float32(0))\n\t\t\t\tout.Set([]int{1, y, x}, -diff)\n\t\t\t}\n\t\t}\n\t}\n\twg.Done()\n}", "func InverseBloomFilterFactory(capacity uint) func() boom.Filter {\n\treturn func() boom.Filter {\n\t\treturn boom.NewInverseBloomFilter(capacity)\n\t}\n}", "func Filter(dst, src []float64, f func(v float64) bool) []float64 {\n\n\tif dst == nil {\n\t\tdst = make([]float64, 0, len(src))\n\t}\n\n\tdst = dst[:0]\n\tfor _, x := range src {\n\t\tif f(x) {\n\t\t\tdst = append(dst, x)\n\t\t}\n\t}\n\n\treturn dst\n}", "func (cm *ConnectionManager) RegisterFilters(source <-chan packet.Packet,\n\tfilters ...func(packet.Packet) packet.Packet) <-chan packet.Packet {\n\tsink := make(chan packet.Packet)\n\n\tgo func() {\n\t\tfor p := range source {\n\t\t\tfor _, filter := range filters {\n\t\t\t\tif pass := filter(p); pass != nil {\n\t\t\t\t\tsink <- pass\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}()\n\n\treturn sink\n}", "func NewFilter(controllerChannel chan Frame, messageCenter MessageCenter) Filter {\n\tfilter := Filter{}\n\n\tfilter.FilterChannel = make(chan Frame)\n\tfilter.FilterFunc = defaultFilterFunc\n\tfilter.controllerChannel = controllerChannel\n\tfilter.messageCenter = messageCenter\n\n\treturn filter\n}", "func (*FilterConfig) Name() string {\n\treturn \"filter\"\n}", "func Forward(x []float64, net Network) []float64{\n\t// The output of the nerual network defined as \"out\"\n\tout := []float64{}\n\n\t// Loop through the hidden layers of the network.\n\tfor h := range net.HiddenLayers {\n\n\t\t// Loop through each neuron in the hidden layer\n\t\tfor i := range net.HiddenLayers[h].Neurons {\n\t\t\t// Initialize the output of the neuron \n\t\t\tvalue := 0.0\n\t\t\t// Loop through the weights of the neuron\n\t\t\tfor j := range net.HiddenLayers[h].Neurons[i].Weights {\n\t\t\t\t// If this is the first layer (h = 0) then use the input array \"x\". Else use the previous hidden layer output.\n\t\t\t\tif h == 0 {\n\t\t\t\t\tvalue += net.HiddenLayers[h].Neurons[i].Weights[j]*x[j]\t\t\t\t\t\n\t\t\t\t} else {\n\t\t\t\t\t// Multiply the currnt neuron weight by the output of the connected input neuron. \n\t\t\t\t\tvalue += net.HiddenLayers[h].Neurons[i].Weights[j]*net.HiddenLayers[h-1].Neurons[j].Output\t\t\t\t\n\t\t\t\t}\n\t\t\t}\n\t\t\t// Update the \"value\" variale with the activated version of the neuron output\n\t\t\tvalue = N.Activate(value + net.HiddenLayers[h].Neurons[i].Bias, net.HiddenLayers[h].Neurons[i].Activation)\n\t\t\tnet.HiddenLayers[h].Neurons[i].Output = value\n\t\t}\n\t}\n\n\t// The output layer is handled slightly differently. \n\tendLayers := len(net.HiddenLayers) - 1\n\n\tfor i := range net.OutputLayer.Neurons {\n\t\tvalue := 0.0\n\t\tfor j := range net.OutputLayer.Neurons[i].Weights {\n\t\t\tvalue += net.HiddenLayers[endLayers].Neurons[j].Output * net.OutputLayer.Neurons[i].Weights[j]\n\t\t}\n\t\tvalue = N.Activate(value + net.OutputLayer.Neurons[i].Bias, net.HiddenLayers[0].Neurons[0].Activation)\n\t\tnet.OutputLayer.Neurons[i].Output = value\n\t\tout = append(out, value)\n\t}\n\treturn out\n}", "func buildFilterData(columns []ColumnSchema, index int, filters []Filters) []Filters {\n\tfilters = append(filters, Filters{\n\t\tId: columns[index].Field,\n\t\tLabel: columns[index].Name,\n\t\tType: columns[index].Type,\n\t\tInput: buildInput(columns[index].Type, columns[index].Values),\n\t\tValues: buildValues(columns[index].Values),\n\t\tOperators: buildOperations(columns[index].Type),\n\t\tPlugin: buildPlug(columns[index].Type),\n\t\tPlugin_config: buildPlugConfig(columns[index].Field,columns[index].Type),\n\t})\n\treturn filters\n}", "func FusedPadConv2D(scope *Scope, input tf.Output, paddings tf.Output, filter tf.Output, mode string, strides []int64, padding string) (output tf.Output) {\n\tif scope.Err() != nil {\n\t\treturn\n\t}\n\tattrs := map[string]interface{}{\"mode\": mode, \"strides\": strides, \"padding\": padding}\n\topspec := tf.OpSpec{\n\t\tType: \"FusedPadConv2D\",\n\t\tInput: []tf.Input{\n\t\t\tinput, paddings, filter,\n\t\t},\n\t\tAttrs: attrs,\n\t}\n\top := scope.AddOperation(opspec)\n\treturn op.Output(0)\n}", "func MakeGaussianFilter() *Filter {\n\tf := new(Filter)\n\tf.F = func(x float64, scaleFactor float64) float64 {\n\t\tif x >= 2.0 {\n\t\t\treturn 0.0\n\t\t}\n\t\tv := math.Exp(-2.0*x*x) * 0.79788456080286535587989\n\t\tif x <= 1.999 {\n\t\t\treturn v\n\t\t}\n\t\t// Slightly alter the filter to make it continuous:\n\t\treturn 1000.0 * (2.0 - x) * v\n\t}\n\tf.Radius = func(scaleFactor float64) float64 {\n\t\treturn 2.0\n\t}\n\treturn f\n}", "func Conv2DBackpropFilterV2UseCudnnOnGpu(value bool) Conv2DBackpropFilterV2Attr {\n\treturn func(m optionalAttr) {\n\t\tm[\"use_cudnn_on_gpu\"] = value\n\t}\n}", "func NewPoolLayerConfig(filters int, opts ...LayerOptionFunc) LayerConfig {\n\tif filters <= 0 {\n\t\tpanic(\"Filter count must be greater than 0\")\n\t}\n\n\tconf := &poolLayerConfig{\n\t\tSx: filters,\n\t\tSy: filters,\n\t\tStride: 2,\n\t\tPadding: 0,\n\t}\n\tfor i := 0; i < len(opts); i++ {\n\t\terr := opts[i](conf)\n\t\tif err != nil {\n\t\t\tpanic(err)\n\t\t}\n\t}\n\treturn conf\n}", "func MakeTriangleFilter() *Filter {\n\tf := new(Filter)\n\tf.F = func(x float64, scaleFactor float64) float64 {\n\t\tif x < 1.0 {\n\t\t\treturn 1.0 - x\n\t\t}\n\t\treturn 0.0\n\t}\n\tf.Radius = func(scaleFactor float64) float64 {\n\t\treturn 1.0\n\t}\n\treturn f\n}", "func Conv2DBackpropFilterV2(scope *Scope, input tf.Output, filter tf.Output, out_backprop tf.Output, strides []int64, padding string, optional ...Conv2DBackpropFilterV2Attr) (output tf.Output) {\n\tif scope.Err() != nil {\n\t\treturn\n\t}\n\tattrs := map[string]interface{}{\"strides\": strides, \"padding\": padding}\n\tfor _, a := range optional {\n\t\ta(attrs)\n\t}\n\topspec := tf.OpSpec{\n\t\tType: \"Conv2DBackpropFilterV2\",\n\t\tInput: []tf.Input{\n\t\t\tinput, filter, out_backprop,\n\t\t},\n\t\tAttrs: attrs,\n\t}\n\top := scope.AddOperation(opspec)\n\treturn op.Output(0)\n}", "func (op *InvMuler) Mul(f *rimg64.Multi) *rimg64.Multi {\n\tif f.Channels != op.Channels {\n\t\tpanic(fmt.Sprintf(\n\t\t\t\"bad number of channels: covar %d, image %d\",\n\t\t\top.Channels, f.Channels,\n\t\t))\n\t}\n\tif f.Width != op.Width || f.Height != op.Height {\n\t\tpanic(fmt.Sprintf(\n\t\t\t\"bad dimensions: operator %dx%d, image %dx%d\",\n\t\t\top.Width, op.Height,\n\t\t\tf.Width, f.Height,\n\t\t))\n\t}\n\n\tfHat := make([]*fftw.Array2, op.Channels)\n\tfor p := 0; p < op.Channels; p++ {\n\t\tfHat[p] = dftChannel(f, p, f.Width, f.Height)\n\t}\n\txHat := make([]*fftw.Array2, op.Channels)\n\tfor p := 0; p < op.Channels; p++ {\n\t\txHat[p] = fftw.NewArray2(f.Width, f.Height)\n\t}\n\n\t// Solve a channels x channels system per pixel.\n\tN := float64(op.Width) * float64(op.Height)\n\tfor u := 0; u < f.Width; u++ {\n\t\tfor v := 0; v < f.Height; v++ {\n\t\t\ty := make([]complex128, op.Channels)\n\t\t\tfor p := 0; p < op.Channels; p++ {\n\t\t\t\ty[p] = fHat[p].At(u, v)\n\t\t\t}\n\t\t\tz, err := op.Fact[u][v].Solve(y)\n\t\t\tif err != nil {\n\t\t\t\tpanic(err)\n\t\t\t}\n\t\t\tfor p := 0; p < op.Channels; p++ {\n\t\t\t\txHat[p].Set(u, v, complex(1/N, 0)*z[p])\n\t\t\t}\n\t\t}\n\t}\n\n\t// Take inverse transform of each channel.\n\tx := rimg64.NewMulti(f.Width, f.Height, op.Channels)\n\tfor p := 0; p < op.Channels; p++ {\n\t\tidftToChannel(x, p, xHat[p])\n\t}\n\treturn x\n}", "func (spec *Filter) CreateFilter(config []interface{}) (filters.Filter, error) {\n\treturn &Filter{spec.FilterName, config}, nil\n}", "func NewFilter(name string) (Config, error) {\n\tfn, ok := newFilterFuncs[name]\n\tif !ok {\n\t\treturn nil, fmt.Errorf(\"No registered filter '%s'\", name)\n\t}\n\n\treturn fn(), nil\n}", "func Conv3D(scope *Scope, input tf.Output, filter tf.Output, strides []int64, padding string, optional ...Conv3DAttr) (output tf.Output) {\n\tif scope.Err() != nil {\n\t\treturn\n\t}\n\tattrs := map[string]interface{}{\"strides\": strides, \"padding\": padding}\n\tfor _, a := range optional {\n\t\ta(attrs)\n\t}\n\topspec := tf.OpSpec{\n\t\tType: \"Conv3D\",\n\t\tInput: []tf.Input{\n\t\t\tinput, filter,\n\t\t},\n\t\tAttrs: attrs,\n\t}\n\top := scope.AddOperation(opspec)\n\treturn op.Output(0)\n}", "func (b Bonds) Filter(f Filter) Bonds {\n\tfiltered := make(Bonds, 0, len(b))\n\tfor _, bond := range b {\n\t\tif bond.Interesting(f) {\n\t\t\tfiltered = append(filtered, bond)\n\t\t}\n\t}\n\treturn filtered\n}", "func Filtered(filtered bool) func(*adapter) {\n\treturn func(a *adapter) {\n\t\ta.filtered = filtered\n\t}\n}" ]
[ "0.6695128", "0.653654", "0.6511346", "0.6391525", "0.6300939", "0.6234931", "0.6102328", "0.6088056", "0.58660406", "0.58625305", "0.5834148", "0.58220327", "0.5806408", "0.5761543", "0.54394716", "0.53300667", "0.52854687", "0.52549875", "0.52449787", "0.52423936", "0.5200652", "0.5188772", "0.5155922", "0.51289314", "0.5101284", "0.50313824", "0.49637708", "0.48927784", "0.48782247", "0.487193", "0.4847856", "0.48369697", "0.4830472", "0.4805046", "0.47997105", "0.4796913", "0.4786742", "0.47583872", "0.47382942", "0.47247753", "0.47200218", "0.4699255", "0.46754333", "0.46095407", "0.45930856", "0.45901528", "0.45829368", "0.4574354", "0.45616442", "0.456054", "0.44932735", "0.44926122", "0.44699508", "0.44591168", "0.44587713", "0.44427136", "0.44371596", "0.44331506", "0.4423732", "0.44235784", "0.43873125", "0.43843308", "0.4381543", "0.4370996", "0.43624645", "0.4362404", "0.4347783", "0.43469667", "0.43290645", "0.43217853", "0.43191665", "0.43158492", "0.4290117", "0.42811218", "0.4276809", "0.42714414", "0.4270599", "0.42689207", "0.4264812", "0.42636377", "0.4262331", "0.42611912", "0.42586303", "0.4254742", "0.42503515", "0.42424932", "0.42313206", "0.4230312", "0.42264876", "0.42228", "0.42226654", "0.4218925", "0.42041364", "0.42028117", "0.4194137", "0.41878304", "0.41813987", "0.41769153", "0.4176089", "0.4174693" ]
0.6414992
3
define a twodimensional convolution filter
func ConvolutionFilter2D(target uint32, internalformat uint32, width int32, height int32, format uint32, xtype uint32, image unsafe.Pointer) { C.glowConvolutionFilter2D(gpConvolutionFilter2D, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), image) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func ConvolutionFilter2D(target uint32, internalformat uint32, width int32, height int32, format uint32, xtype uint32, image unsafe.Pointer) {\n C.glowConvolutionFilter2D(gpConvolutionFilter2D, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), image)\n}", "func CopyConvolutionFilter2D(target uint32, internalformat uint32, x int32, y int32, width int32, height int32) {\n C.glowCopyConvolutionFilter2D(gpCopyConvolutionFilter2D, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func ConstructedConv2D(m *Model, x tensor.Tensor, kernelH int, kernelW int, filters int) tensor.Tensor {\n\tslen := len(x.Shape())\n\tfAxis := slen - 1\n\twAxis := slen - 2\n\thAxis := slen - 3\n\tinFilters := x.Shape()[fAxis]\n\tinW := x.Shape()[wAxis]\n\tinH := x.Shape()[hAxis]\n\n\twShape := onesLike(x)\n\twShape[fAxis] = filters\n\twShape[wAxis] = inFilters * kernelH * kernelW\n\n\tbShape := onesLike(x)\n\tbShape[fAxis] = filters\n\n\tweight := m.AddWeight(wShape...)\n\tbias := m.AddBias(bShape...)\n\n\tslices := make([]tensor.Tensor, 0, kernelH*kernelW)\n\n\tfor hoff := 0; hoff < kernelH; hoff++ {\n\t\thslice := tensor.Slice(x, hAxis, hoff, inH-kernelH+1+hoff)\n\t\tfor woff := 0; woff < kernelW; woff++ {\n\t\t\twslice := tensor.Slice(hslice, wAxis, woff, inW-kernelW+1+woff)\n\t\t\tslices = append(slices, wslice)\n\t\t}\n\t}\n\n\tx = tensor.Concat(fAxis, slices...)\n\tx = tensor.MatMul(x, weight, wAxis, fAxis)\n\tx = tensor.Add(x, bias)\n\n\treturn x\n}", "func Convolve(src, dst []float64, kernel []float64, border Border) {\n\twidth := len(kernel)\n\thalfWidth := width / 2\n\tfor i := range dst {\n\t\tk := i - halfWidth\n\t\tvar sum float64\n\t\tif k >= 0 && k <= len(src)-width {\n\t\t\tfor j, x := range kernel {\n\t\t\t\tsum += src[k+j] * x\n\t\t\t}\n\t\t} else {\n\t\t\tfor j, x := range kernel {\n\t\t\t\tsum += border.Interpolate(src, k+j) * x\n\t\t\t}\n\t\t}\n\t\tdst[i] = sum\n\t}\n}", "func CopyConvolutionFilter2D(target uint32, internalformat uint32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyConvolutionFilter2D(gpCopyConvolutionFilter2D, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func (img *FloatImage) convolve(kernel *ConvKernel, px planeExtension) *FloatImage {\n\n\t// convolve each plane independently:\n\tres := new([3][]float32)\n\tfor i := 0; i < 3; i++ {\n\t\tconvolvePlane(&img.Ip[i], kernel, img.Width, img.Height, px)\n\t}\n\n\treturn &FloatImage{\n\t\tIp: *res,\n\t\tWidth: img.Width,\n\t\tHeight: img.Height,\n\t}\n}", "func ConvolutionFilter1D(target uint32, internalformat uint32, width int32, format uint32, xtype uint32, image unsafe.Pointer) {\n C.glowConvolutionFilter1D(gpConvolutionFilter1D, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), image)\n}", "func CopyConvolutionFilter1D(target uint32, internalformat uint32, x int32, y int32, width int32) {\n C.glowCopyConvolutionFilter1D(gpCopyConvolutionFilter1D, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func createFilter(img image.Image, factor [2]float32, size int, kernel func(float32) float32) (f Filter) {\n\tsizeX := size * (int(math.Ceil(float64(factor[0]))))\n\tsizeY := size * (int(math.Ceil(float64(factor[1]))))\n\n\tswitch img.(type) {\n\tdefault:\n\t\tf = &filterModel{\n\t\t\t&genericConverter{img},\n\t\t\tfactor, kernel,\n\t\t\tmake([]colorArray, sizeX), make([]colorArray, sizeY),\n\t\t}\n\tcase *image.RGBA:\n\t\tf = &filterModel{\n\t\t\t&rgbaConverter{img.(*image.RGBA)},\n\t\t\tfactor, kernel,\n\t\t\tmake([]colorArray, sizeX), make([]colorArray, sizeY),\n\t\t}\n\tcase *image.RGBA64:\n\t\tf = &filterModel{\n\t\t\t&rgba64Converter{img.(*image.RGBA64)},\n\t\t\tfactor, kernel,\n\t\t\tmake([]colorArray, sizeX), make([]colorArray, sizeY),\n\t\t}\n\tcase *image.Gray:\n\t\tf = &filterModel{\n\t\t\t&grayConverter{img.(*image.Gray)},\n\t\t\tfactor, kernel,\n\t\t\tmake([]colorArray, sizeX), make([]colorArray, sizeY),\n\t\t}\n\tcase *image.Gray16:\n\t\tf = &filterModel{\n\t\t\t&gray16Converter{img.(*image.Gray16)},\n\t\t\tfactor, kernel,\n\t\t\tmake([]colorArray, sizeX), make([]colorArray, sizeY),\n\t\t}\n\tcase *image.YCbCr:\n\t\tf = &filterModel{\n\t\t\t&ycbcrConverter{img.(*image.YCbCr)},\n\t\t\tfactor, kernel,\n\t\t\tmake([]colorArray, sizeX), make([]colorArray, sizeY),\n\t\t}\n\t}\n\treturn\n}", "func GetConvolutionFilter(target uint32, format uint32, xtype uint32, image unsafe.Pointer) {\n C.glowGetConvolutionFilter(gpGetConvolutionFilter, (C.GLenum)(target), (C.GLenum)(format), (C.GLenum)(xtype), image)\n}", "func (fir *FIR) Convolve(input []float64) ([]float64, error) {\n\tkernelSize := len(fir.kernel)\n\tn := len(input)\n\n\tif n <= kernelSize {\n\t\terr := fmt.Errorf(\"input size %d is not greater than kernel size %d\", n, kernelSize)\n\t\treturn []float64{}, err\n\t}\n\n\toutput := make([]float64, n)\n\n\t//\n\tfor i := 0; i < kernelSize; i++ {\n\t\tsum := 0.0\n\n\t\t// convolve the input with the filter kernel\n\t\tfor j := 0; j < i; j++ {\n\t\t\tsum += (input[j] * fir.kernel[kernelSize-(1+i-j)])\n\t\t}\n\n\t\toutput[i] = sum\n\t}\n\n\tfor i := kernelSize; i < n; i++ {\n\t\tsum := 0.0\n\n\t\t// convolve the input with the filter kernel\n\t\tfor j := 0; j < kernelSize; j++ {\n\t\t\tsum += (input[i-j] * fir.kernel[j])\n\t\t}\n\n\t\toutput[i] = sum\n\t}\n\n\treturn output, nil\n}", "func ConvolutionFilter1D(target uint32, internalformat uint32, width int32, format uint32, xtype uint32, image unsafe.Pointer) {\n\tC.glowConvolutionFilter1D(gpConvolutionFilter1D, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), image)\n}", "func (t1 *Tensor) Convolve2D(kernel *Tensor, stride int) (*Tensor, error) {\n\toutTensor := NewTensor((t1.Size.X-kernel.Size.X)/stride+1, (t1.Size.Y-kernel.Size.Y)/stride+1, t1.Size.Z)\n\tfor x := 0; x < outTensor.Size.X; x++ {\n\t\tfor y := 0; y < outTensor.Size.Y; y++ {\n\t\t\tmappedX, mappedY := x*stride, y*stride\n\t\t\tfor i := 0; i < kernel.Size.X; i++ {\n\t\t\t\tfor j := 0; j < kernel.Size.X; j++ {\n\t\t\t\t\tfor z := 0; z < t1.Size.Z; z++ {\n\t\t\t\t\t\tf := kernel.Get(i, j, z)\n\t\t\t\t\t\tv := t1.Get(mappedX+i, mappedY+j, z)\n\t\t\t\t\t\toutTensor.SetAdd(x, y, z, f*v)\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\treturn outTensor, nil\n}", "func CopyConvolutionFilter1D(target uint32, internalformat uint32, x int32, y int32, width int32) {\n\tC.glowCopyConvolutionFilter1D(gpCopyConvolutionFilter1D, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func Conv2D(t Tensor, k Tensor, hAxis int, wAxis int, fAxis int) Tensor {\n\tkh, kw := k.Shape()[0], k.Shape()[1]\n\treturn &Conv2DTensor{\n\t\tbaseTensor: base(conv2d(t, k, hAxis, wAxis, fAxis), 1, t, k),\n\t\tt: t,\n\t\tk: k,\n\t\thAxis: hAxis,\n\t\twAxis: wAxis,\n\t\tfAxis: fAxis,\n\t\tpadH: kh - 1,\n\t\tpadW: kw - 1,\n\t}\n}", "func (img *FloatImage) convolveWith(kernel *ConvKernel, px planeExtension) {\n\n\t// convolve each plane independently:\n\tfor i := 0; i < 3; i++ {\n\t\timg.Ip[i] = *convolvePlane(&img.Ip[i], kernel, img.Width, img.Height, px)\n\t}\n}", "func MakeConvolutionCoder(r, k int, poly []uint16) *ConvolutionCoder {\n\tif len(poly) != r {\n\t\tpanic(\"The number of polys should match the rate\")\n\t}\n\n\treturn &ConvolutionCoder{\n\t\tr: r,\n\t\tk: k,\n\t\tpoly: poly,\n\t\tcc: correctwrap.Correct_convolutional_create(int64(r), int64(k), &poly[0]),\n\t}\n}", "func GetConvolutionFilter(target uint32, format uint32, xtype uint32, image unsafe.Pointer) {\n\tC.glowGetConvolutionFilter(gpGetConvolutionFilter, (C.GLenum)(target), (C.GLenum)(format), (C.GLenum)(xtype), image)\n}", "func ConvDiff(geom *Geom, fltOn, fltOff *etensor.Float32, imgOn, imgOff, out *etensor.Float32, gain, gainOn float32) {\n\tfy := fltOn.Dim(0)\n\tfx := fltOn.Dim(1)\n\n\tgeom.FiltSz = image.Point{fx, fy}\n\tgeom.UpdtFilt()\n\n\timgSz := image.Point{imgOn.Dim(1), imgOn.Dim(0)}\n\tgeom.SetSize(imgSz)\n\toshp := []int{2, int(geom.Out.Y), int(geom.Out.X)}\n\tif !etensor.EqualInts(oshp, out.Shp) {\n\t\tout.SetShape(oshp, nil, []string{\"OnOff\", \"Y\", \"X\"})\n\t}\n\tncpu := nproc.NumCPU()\n\tnthrs, nper, rmdr := nproc.ThreadNs(ncpu, geom.Out.Y)\n\tvar wg sync.WaitGroup\n\tfor th := 0; th < nthrs; th++ {\n\t\twg.Add(1)\n\t\tyst := th * nper\n\t\tgo convDiffThr(&wg, geom, yst, nper, fltOn, fltOff, imgOn, imgOff, out, gain, gainOn)\n\t}\n\tif rmdr > 0 {\n\t\twg.Add(1)\n\t\tyst := nthrs * nper\n\t\tgo convDiffThr(&wg, geom, yst, rmdr, fltOn, fltOff, imgOn, imgOff, out, gain, gainOn)\n\t}\n\twg.Wait()\n}", "func ExampleConv2() {\n\n\tconv := cnns.NewConvLayer(&tensor.TDsize{X: 5, Y: 5, Z: 3}, 1, 3, 2)\n\trelu := cnns.NewReLULayer(conv.GetOutputSize())\n\tmaxpool := cnns.NewPoolingLayer(relu.GetOutputSize(), 2, 2, \"max\", \"valid\")\n\tfullyconnected := cnns.NewFullyConnectedLayer(maxpool.GetOutputSize(), 2)\n\n\tnet := cnns.WholeNet{\n\t\tLP: cnns.NewLearningParametersDefault(),\n\t}\n\tnet.Layers = append(net.Layers, conv)\n\tnet.Layers = append(net.Layers, relu)\n\tnet.Layers = append(net.Layers, maxpool)\n\tnet.Layers = append(net.Layers, fullyconnected)\n\n\tredChannel := mat.NewDense(5, 5, []float64{\n\t\t1, 0, 1, 0, 2,\n\t\t1, 1, 3, 2, 1,\n\t\t1, 1, 0, 1, 1,\n\t\t2, 3, 2, 1, 3,\n\t\t0, 2, 0, 1, 0,\n\t})\n\tgreenChannel := mat.NewDense(5, 5, []float64{\n\t\t1, 0, 0, 1, 0,\n\t\t2, 0, 1, 2, 0,\n\t\t3, 1, 1, 3, 0,\n\t\t0, 3, 0, 3, 2,\n\t\t1, 0, 3, 2, 1,\n\t})\n\tblueChannel := mat.NewDense(5, 5, []float64{\n\t\t2, 0, 1, 2, 1,\n\t\t3, 3, 1, 3, 2,\n\t\t2, 1, 1, 1, 0,\n\t\t3, 1, 3, 2, 0,\n\t\t1, 1, 2, 1, 1,\n\t})\n\n\tkernel1R := mat.NewDense(3, 3, []float64{\n\t\t0, 1, 0,\n\t\t0, 0, 2,\n\t\t0, 1, 0,\n\t})\n\tkernel1G := mat.NewDense(3, 3, []float64{\n\t\t2, 1, 0,\n\t\t0, 0, 0,\n\t\t0, 3, 0,\n\t})\n\tkernel1B := mat.NewDense(3, 3, []float64{\n\t\t1, 0, 0,\n\t\t1, 0, 0,\n\t\t0, 0, 2,\n\t})\n\n\tkernel2R := mat.NewDense(3, 3, []float64{\n\t\t0, -1, 0,\n\t\t0, 0, 2,\n\t\t0, 1, 0,\n\t})\n\tkernel2G := mat.NewDense(3, 3, []float64{\n\t\t2, 1, 0,\n\t\t0, 0, 0,\n\t\t0, -3, 0,\n\t})\n\tkernel2B := mat.NewDense(3, 3, []float64{\n\t\t1, 0, 0,\n\t\t1, 0, 0,\n\t\t0, 0, -2,\n\t})\n\n\timg2 := &mat.Dense{}\n\timg2.Stack(redChannel, greenChannel)\n\timage := &mat.Dense{}\n\timage.Stack(img2, blueChannel)\n\n\tkernel1 := &mat.Dense{}\n\tkernel1.Stack(kernel1R, kernel1G)\n\tconvCustomWeights1 := &mat.Dense{}\n\tconvCustomWeights1.Stack(kernel1, kernel1B)\n\n\tkernel2 := &mat.Dense{}\n\tkernel2.Stack(kernel2R, kernel2G)\n\tconvCustomWeights2 := &mat.Dense{}\n\tconvCustomWeights2.Stack(kernel2, kernel2B)\n\tconv.SetCustomWeights([]*mat.Dense{convCustomWeights1, convCustomWeights2})\n\n\tfcCustomWeights := mat.NewDense(2, maxpool.GetOutputSize().Total(), []float64{\n\t\t-0.19908814, 0.01521263,\n\t\t0.17908468, -0.28144695,\n\t})\n\tfullyconnected.SetCustomWeights([]*mat.Dense{fcCustomWeights})\n\n\tfmt.Printf(\"Layers weights:\\n\")\n\tfor i := range net.Layers {\n\t\tfmt.Printf(\"%s #%d weights:\\n\", net.Layers[i].GetType(), i)\n\t\tnet.Layers[i].PrintWeights()\n\t}\n\n\tfmt.Println(\"\\tDoing training....\")\n\tfor e := 0; e < 1; e++ {\n\t\terr := net.FeedForward(image)\n\t\tif err != nil {\n\t\t\tlog.Printf(\"Feedforward caused error: %s\", err.Error())\n\t\t\treturn\n\t\t}\n\n\t\tdesired := mat.NewDense(2, 1, []float64{0.15, 0.8})\n\t\terr = net.Backpropagate(desired)\n\t\tif err != nil {\n\t\t\tlog.Printf(\"Backpropagate caused error: %s\", err.Error())\n\t\t\treturn\n\t\t}\n\n\t\tfmt.Printf(\"Epoch #%d. New layers weights\\n\", e)\n\t\tfor i := range net.Layers {\n\t\t\tfmt.Printf(\"%s #%d weights on epoch #%d:\\n\", net.Layers[i].GetType(), i, e)\n\t\t\tnet.Layers[i].PrintWeights()\n\t\t}\n\t}\n}", "func Conv(scope *Scope, input tf.Output, filter tf.Output, strides []int64, padding string, optional ...ConvAttr) (output tf.Output) {\n\tif scope.Err() != nil {\n\t\treturn\n\t}\n\tattrs := map[string]interface{}{\"strides\": strides, \"padding\": padding}\n\tfor _, a := range optional {\n\t\ta(attrs)\n\t}\n\topspec := tf.OpSpec{\n\t\tType: \"Conv\",\n\t\tInput: []tf.Input{\n\t\t\tinput, filter,\n\t\t},\n\t\tAttrs: attrs,\n\t}\n\top := scope.AddOperation(opspec)\n\treturn op.Output(0)\n}", "func applyConvolutionToPixel(im ImageMatrix, x int, y int, cmSize int, column []color.RGBA, cm ConvolutionMatrix, conFunc func(ImageMatrix, int, int, int, int, color.RGBA, float64) int) {\n\tcurrentColour := im[x][y]\n\tredTotal := 0\n\tgreenTotal := 0\n\tblueTotal := 0\n\tweight := 0\n\n\tkernelMatrix := im.GetKernelMatrix(x, y, cmSize)\n\n\tfor i, kernelColumn := range kernelMatrix {\n\t\tfor j, kernelPixelColour := range kernelColumn {\n\n\t\t\t// get the distance of the current pixel compared to the centre of the kernel\n\t\t\t// the centre one is the one we are modifying and saving to a new image/matrix of course...\n\t\t\tdistance := math.Sqrt(math.Pow(float64(cmSize-i), 2) + math.Pow(float64(cmSize-j), 2))\n\n\t\t\t// Call the function the user passed and get the return weight of how much influence\n\t\t\t// it should have over the centre pixel we want to change\n\t\t\t// We are multipling it by the weight in the convolution matrix as that way you can\n\t\t\t// control an aspect of the weight through the matrix as well (as well as the function that\n\t\t\t// we pass in of course :)\n\t\t\tcmValue := conFunc(im, x, y, i, j, kernelPixelColour, distance) * int(cm[i][j])\n\n\t\t\t// apply the influence / weight ... (eg. if cmValue was 0, then the current pixel would have\n\t\t\t// no influence over the pixel we are changing, if it was large in comparision to what we return\n\t\t\t// for the other kernel pixels, then it will have a large influence)\n\t\t\tredTotal += int(kernelPixelColour.R) * cmValue\n\t\t\tgreenTotal += int(kernelPixelColour.G) * cmValue\n\t\t\tblueTotal += int(kernelPixelColour.B) * cmValue\n\t\t\tweight += cmValue\n\t\t}\n\t}\n\n\t// If the convolution matrix normalised itself; aka, say it was something like:\n\t// { 0 -1 0}\n\t// {-1 4 -1}\n\t// { 0 -1 0}\n\t// then adding the entries (4 + (-1) + (-1) + (-1) + (-1)) results in a zero, in which case we leave\n\t// the weights alone (by setting the weight to divide by to 1) (aka, the weights do not have an impact,\n\t// but the pixels with a weight more more or less than 0 still do have an impact on the pixel\n\t// we are changing of course)\n\tif weight == 0 {\n\t\tweight = 1\n\t}\n\n\t// Normalise the values (based on the weight (total's in the matrix))\n\tnewRedValue := redTotal / weight\n\tnewGreenValue := greenTotal / weight\n\tnewBlueValue := blueTotal / weight\n\n\t// If the values are \"out of range\" (outside the colour range of 0-255) then set them to 0 (absence of that\n\t// colour) if they were negative or 255 (100% of that colour) if they were greater than the max allowed.\n\tif newRedValue < 0 {\n\t\tnewRedValue = 0\n\t} else if newRedValue > 255 {\n\t\tnewRedValue = 255\n\t}\n\n\tif newGreenValue < 0 {\n\t\tnewGreenValue = 0\n\t} else if newGreenValue > 255 {\n\t\tnewGreenValue = 255\n\t}\n\n\tif newBlueValue < 0 {\n\t\tnewBlueValue = 0\n\t} else if newBlueValue > 255 {\n\t\tnewBlueValue = 255\n\t}\n\n\t// Assign the new values to the pixel in the column 'column' at position y\n\tcolumn[y] = color.RGBA{uint8(newRedValue), uint8(newGreenValue), uint8(newBlueValue), currentColour.A}\n\t// fmt.Printf(\"[%v,%v] %v => %v\\n\", x, y, currentColour, column[y])\n}", "func SpectralConvolution(spectrum []int) []int {\n\tvar convolution []int\n\tfor i := 0; i < len(spectrum)-1; i++ {\n\t\tfor j := i + 1; j < len(spectrum); j++ {\n\t\t\tval := spectrum[j] - spectrum[i]\n\t\t\tif val > 0 {\n\t\t\t\tconvolution = append(convolution, val)\n\t\t\t}\n\t\t}\n\t}\n\treturn convolution\n}", "func (img *ImageTask) ApplyConvulusion(neighbors *Neighbors, kernel [9]float64) *Colors{\n\n\tvar blue float64\n\tvar green float64\n\tvar red float64\n\tfor r := 0; r < 9; r++ {\n\t\tred = red + (neighbors.inputs[r].Red * kernel[r])\n\t\tgreen = green + (neighbors.inputs[r].Green * kernel[r])\n\t\tblue = blue + (neighbors.inputs[r].Blue * kernel[r])\n\t}\n\n\treturned := Colors{Red: red, Green: green, Blue: blue, Alpha: neighbors.inputs[4].Alpha}\n\treturn &returned\n}", "func MakePixelMixingFilter() *Filter {\n\tf := new(Filter)\n\tf.F = func(x float64, scaleFactor float64) float64 {\n\t\tvar p float64\n\t\tif scaleFactor < 1.0 {\n\t\t\tp = scaleFactor\n\t\t} else {\n\t\t\tp = 1.0 / scaleFactor\n\t\t}\n\t\tif x < 0.5-p/2.0 {\n\t\t\treturn 1.0\n\t\t} else if x < 0.5+p/2.0 {\n\t\t\treturn 0.5 - (x-0.5)/p\n\t\t}\n\t\treturn 0.0\n\t}\n\tf.Radius = func(scaleFactor float64) float64 {\n\t\tif scaleFactor < 1.0 {\n\t\t\treturn 0.5 + scaleFactor\n\t\t}\n\t\treturn 0.5 + 1.0/scaleFactor\n\t}\n\treturn f\n}", "func (p *Image64) Convolved(k Kernel64) *Image64 {\n\tswitch k.(type) {\n\tcase *separableKernel64:\n\t\treturn p.separableConvolution(k.(*separableKernel64))\n\tdefault:\n\t\treturn p.fullConvolution(k)\n\t}\n\tpanic(\"unreachable\")\n}", "func SeparableFilter2D(target uint32, internalformat uint32, width int32, height int32, format uint32, xtype uint32, row unsafe.Pointer, column unsafe.Pointer) {\n C.glowSeparableFilter2D(gpSeparableFilter2D, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), row, column)\n}", "func convDiffThr(wg *sync.WaitGroup, geom *Geom, yst, ny int, fltOn, fltOff *etensor.Float32, imgOn, imgOff, out *etensor.Float32, gain, gainOn float32) {\n\tist := geom.Border.Sub(geom.FiltLt)\n\tfor yi := 0; yi < ny; yi++ {\n\t\ty := yst + yi\n\t\tiy := int(ist.Y + y*geom.Spacing.Y)\n\t\tfor x := 0; x < geom.Out.X; x++ {\n\t\t\tix := ist.X + x*geom.Spacing.X\n\t\t\tvar sumOn, sumOff float32\n\t\t\tfi := 0\n\t\t\tfor fy := 0; fy < geom.FiltSz.Y; fy++ {\n\t\t\t\tfor fx := 0; fx < geom.FiltSz.X; fx++ {\n\t\t\t\t\tidx := imgOn.Offset([]int{iy + fy, ix + fx})\n\t\t\t\t\tsumOn += imgOn.Values[idx] * fltOn.Values[fi]\n\t\t\t\t\tsumOff += imgOff.Values[idx] * fltOff.Values[fi]\n\t\t\t\t\tfi++\n\t\t\t\t}\n\t\t\t}\n\t\t\tdiff := gain * (gainOn*sumOn - sumOff)\n\t\t\tif diff > 0 {\n\t\t\t\tout.Set([]int{0, y, x}, diff)\n\t\t\t\tout.Set([]int{1, y, x}, float32(0))\n\t\t\t} else {\n\t\t\t\tout.Set([]int{0, y, x}, float32(0))\n\t\t\t\tout.Set([]int{1, y, x}, -diff)\n\t\t\t}\n\t\t}\n\t}\n\twg.Done()\n}", "func Conv2DBackpropFilter(scope *Scope, input tf.Output, filter_sizes tf.Output, out_backprop tf.Output, strides []int64, padding string, optional ...Conv2DBackpropFilterAttr) (output tf.Output) {\n\tif scope.Err() != nil {\n\t\treturn\n\t}\n\tattrs := map[string]interface{}{\"strides\": strides, \"padding\": padding}\n\tfor _, a := range optional {\n\t\ta(attrs)\n\t}\n\topspec := tf.OpSpec{\n\t\tType: \"Conv2DBackpropFilter\",\n\t\tInput: []tf.Input{\n\t\t\tinput, filter_sizes, out_backprop,\n\t\t},\n\t\tAttrs: attrs,\n\t}\n\top := scope.AddOperation(opspec)\n\treturn op.Output(0)\n}", "func Dilation2DBackpropFilter(scope *Scope, input tf.Output, filter tf.Output, out_backprop tf.Output, strides []int64, rates []int64, padding string) (filter_backprop tf.Output) {\n\tif scope.Err() != nil {\n\t\treturn\n\t}\n\tattrs := map[string]interface{}{\"strides\": strides, \"rates\": rates, \"padding\": padding}\n\topspec := tf.OpSpec{\n\t\tType: \"Dilation2DBackpropFilter\",\n\t\tInput: []tf.Input{\n\t\t\tinput, filter, out_backprop,\n\t\t},\n\t\tAttrs: attrs,\n\t}\n\top := scope.AddOperation(opspec)\n\treturn op.Output(0)\n}", "func BoxFilter(src, dst []float64, width int, border Border) {\n\t// TODO optimize\n\talpha := 1.0 / float64(width)\n\tkernel := make([]float64, width)\n\tfor i := range kernel {\n\t\tkernel[i] = alpha\n\t}\n\tConvolve(src, dst, kernel, border)\n}", "func Sigmoid(midpoint, factor float32) Filter {\n\ta := minf32(maxf32(midpoint, 0), 1)\n\tb := absf32(factor)\n\tsig0 := sigmoid(a, b, 0)\n\tsig1 := sigmoid(a, b, 1)\n\te := float32(1.0e-5)\n\n\treturn &colorchanFilter{\n\t\tfn: func(x float32) float32 {\n\t\t\tif factor == 0 {\n\t\t\t\treturn x\n\t\t\t} else if factor > 0 {\n\t\t\t\tsig := sigmoid(a, b, x)\n\t\t\t\treturn (sig - sig0) / (sig1 - sig0)\n\t\t\t} else {\n\t\t\t\targ := minf32(maxf32((sig1-sig0)*x+sig0, e), 1-e)\n\t\t\t\treturn a - logf32(1/arg-1)/b\n\t\t\t}\n\t\t},\n\t\tlut: true,\n\t}\n}", "func (b *Bilateral) Apply(t *Tensor) *Tensor {\n\tdistances := NewTensor(b.KernelSize, b.KernelSize, 1)\n\tcenter := b.KernelSize / 2\n\tfor i := 0; i < b.KernelSize; i++ {\n\t\tfor j := 0; j < b.KernelSize; j++ {\n\t\t\t*distances.At(i, j, 0) = float32((i-center)*(i-center) + (j-center)*(j-center))\n\t\t}\n\t}\n\n\t// Pad with very large negative numbers to prevent\n\t// the filter from incorporating the padding.\n\tpadded := t.Add(100).Pad(center, center, center, center).Add(-100)\n\tout := NewTensor(t.Height, t.Width, t.Depth)\n\tPatches(padded, b.KernelSize, 1, func(idx int, patch *Tensor) {\n\t\tb.blurPatch(distances, patch, out.Data[idx*out.Depth:(idx+1)*out.Depth])\n\t})\n\n\treturn out\n}", "func convolvePlane(planePtr *[]float32, kernel *ConvKernel, width, height int, toPlaneCoords planeExtension) *[]float32 {\n\n\tplane := *planePtr\n\tradius := kernel.Radius\n\tdiameter := radius*2 + 1\n\tres := make([]float32, width*height)\n\n\t// for each pixel of the intensity plane:\n\tfor y := 0; y < height; y++ {\n\t\tfor x := 0; x < width; x++ {\n\t\t\tindex := y*width + x\n\n\t\t\t// compute convolved value of the pixel:\n\t\t\tresV := float32(0)\n\t\t\tfor yk := 0; yk < diameter; yk++ {\n\t\t\t\typ := toPlaneCoords(y+yk-radius, height)\n\t\t\t\tfor xk := 0; xk < diameter; xk++ {\n\t\t\t\t\txp := toPlaneCoords(x+xk-radius, width)\n\t\t\t\t\tplaneIndex := yp*width + xp\n\t\t\t\t\tkernelIndex := yk*diameter + xk\n\t\t\t\t\tresV += (plane[planeIndex] * kernel.Kernel[kernelIndex])\n\t\t\t\t}\n\t\t\t}\n\t\t\tres[index] = resV\n\t\t}\n\t}\n\n\treturn &res\n}", "func SeparableFilter2D(target uint32, internalformat uint32, width int32, height int32, format uint32, xtype uint32, row unsafe.Pointer, column unsafe.Pointer) {\n\tC.glowSeparableFilter2D(gpSeparableFilter2D, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), row, column)\n}", "func worker(threads int, doneWorker chan<- bool, imageTasks <-chan *imagetask.ImageTask, imageResults chan<- *imagetask.ImageTask) {\n\n\t// Initial placing image chunks in to a channel for filter to consume.\n\tchunkStreamGenerator := func(done <- chan interface{}, imageChunks []*imagetask.ImageTask) chan *imagetask.ImageTask {\n\t\tchunkStream := make(chan *imagetask.ImageTask)\n\t\tgo func() {\n\t\t\tdefer close(chunkStream)\n\t\t\tfor _, chunk := range imageChunks {\n\t\t\t\tselect {\n\t\t\t\tcase <-done:\n\t\t\t\t\treturn\n\t\t\t\tcase chunkStream <- chunk:\n\t\t\t\t}\n\t\t\t}\n\t\t}()\n\t\treturn chunkStream\n\t}\n\n\t// Filter applies a filter in a pipeline fashion. \n\t// A goroutine is spawned for each chunk that needs to be filtered (which is numOfThreads chunks for each filter effect)\n\tfilter := func(threads int, effect string, effectNum int, done <- chan interface{}, chunkStream chan *imagetask.ImageTask) chan *imagetask.ImageTask {\n\t\tfilterStream := make(chan *imagetask.ImageTask, threads) // Only numOfThreads image chunks should be in the local filter channel.\n\t\tdonefilterChunk := make(chan bool)\n\t\tfor chunk := range chunkStream { // For each image chunk ...\n\t\t\tif effectNum > 0 {\n\t\t\t\tchunk.Img.UpdateInImg() // Replace inImg with outImg if not the first effect to compund effects.\n\t\t\t}\t\n\t\t\tgo func(chunk *imagetask.ImageTask) { // Spawn a goroutine for each chunk, which is equal to the numOfThreads. Each goroutine works on a portion of the image.\n\t\t\t\tselect {\n\t\t\t\tcase <-done:\n\t\t\t\t\tdonefilterChunk <- true\n\t\t\t\t\treturn\n\t\t\t\tcase filterStream <- chunk:\n\t\t\t\t\tif effect != \"G\" {\n\t\t\t\t\t\tchunk.Img.ApplyConvolution(effect) // Can wait to apply effect until after chunk is in the channel because has to wait for all goroutines to finish before it can move on to the next filter for a given image.\n\t\t\t\t\t} else {\n\t\t\t\t\t\tchunk.Img.Grayscale()\n\t\t\t\t\t}\n\t\t\t\t\tdonefilterChunk <- true // Indicate that the filtering is done for the given chunk.\n\t\t\t\t}\n\t\t\t}(chunk)\n\t\t}\n\t\tfor i := 0; i < threads; i ++ { // Wait for all portions to be put through one filter because of image dependencies with convolution.\n\t\t\t<-donefilterChunk\n\t\t}\n\t\treturn filterStream\n\t}\n\n\t// While there are more image tasks to grab ...\n\tfor true {\n\t\t// Grab image task from image task channel.\t\n\t\timgTask, more := <-imageTasks\n\n\t\t// If you get an image task, split up the image in to even chunks by y-pixels.\n\t\tif more {\n\t\t\timageChunks := imgTask.SplitImage(threads)\n\t\t\t\n\t\t\t// Iterate through filters on image chunks.\n\t\t\t// Will spawn a goroutine for each chunk in each filter (n goroutines per filter)\n\t\t\tdone := make(chan interface{})\n\t\t\tdefer close(done)\n\t\t\tchunkStream := chunkStreamGenerator(done, imageChunks)\n\t\t\tfor i := 0; i < len(imgTask.Effects); i++ {\n\t\t\t\teffect := imgTask.Effects[i]\n\t\t\t\tchunkStream = filter(threads, effect, i, done, chunkStream)\n\t\t\t\tclose(chunkStream)\n\t\t\t}\n\n\t\t\t// Put the image back together.\n\t\t\treconstructedImage, _ := imgTask.Img.NewImage()\n\t\t\tfor imgChunk := range chunkStream {\n\t\t\t\treconstructedImage.ReAddChunk(imgChunk.Img, imgChunk.YPixelStart, imgChunk.ChunkPart)\n\t\t\t}\n\t\t\timgTask.Img = reconstructedImage\n\t\t\timageResults <- imgTask // Send image to results channel to be saved.\n\n\t\t} else { // Otherwise, if there are no more image tasks, then goroutine worker exits.\n\t\t\tdoneWorker <- true // Indicate that the worker is done.\n\t\t\treturn\n\t\t}\n\t}\n}", "func New(c *Config) (*Filter, error) {\n\n\t//\n\t// dimensions\n\t//\n\n\trF, cF := c.F.Dims()\n\trG, cG := c.G.Dims()\n\trQ, cQ := c.Q.Dims()\n\trH, cH := c.H.Dims()\n\trR, cR := c.R.Dims()\n\n\t//\n\t// validate\n\t//\n\n\tif rF != cF {\n\t\treturn nil, errors.New(\"F must be square matrix\")\n\t}\n\n\tif rQ != cQ {\n\t\treturn nil, errors.New(\"Q must be square matrix\")\n\t}\n\n\tif rR != cR {\n\t\treturn nil, errors.New(\"R must be square matrix\")\n\t}\n\n\tif rF != rG {\n\t\treturn nil, errors.New(\"row dim of F must be matched to row dim of G\")\n\t}\n\n\tif cG != rQ {\n\t\treturn nil, errors.New(\"column dim of G must be matched to row dim of Q\")\n\t}\n\n\tif cH != cF {\n\t\treturn nil, errors.New(\"column dim of H must be matched to column dim of F\")\n\t}\n\n\tif rH != rR {\n\t\treturn nil, errors.New(\"row dim of H must be matched to row dim of R\")\n\t}\n\n\t// init internal states\n\n\tx := mat64.NewVector(cF, nil)\n\tv := mat64.NewDense(rF, cF, nil)\n\tident := mat64.NewDense(rF, cF, nil)\n\tfor i := 0; i < rF; i++ {\n\t\tident.Set(i, i, 1.0)\n\t}\n\n\treturn &Filter{\n\t\tConfig: *c,\n\t\tI: ident,\n\t\tX: x,\n\t\tV: v,\n\t}, nil\n}", "func (img *FloatImage) ConvolveWrap(kernel *ConvKernel) *FloatImage {\n\treturn img.convolve(kernel, wrapPlaneExtension)\n}", "func ExampleConv() {\n\n\tconv := cnns.NewConvLayer(&tensor.TDsize{X: 9, Y: 8, Z: 1}, 1, 3, 1)\n\trelu := cnns.NewReLULayer(conv.GetOutputSize())\n\tmaxpool := cnns.NewPoolingLayer(relu.GetOutputSize(), 2, 2, \"max\", \"valid\")\n\tfullyconnected := cnns.NewFullyConnectedLayer(maxpool.GetOutputSize(), 3)\n\n\tconvCustomWeights := mat.NewDense(3, 3, []float64{\n\t\t0.10466029, -0.06228581, -0.43436298,\n\t\t0.44050909, -0.07536250, -0.34348075,\n\t\t0.16456005, 0.18682307, -0.40303048,\n\t})\n\tconv.SetCustomWeights([]*mat.Dense{convCustomWeights})\n\n\tfcCustomWeights := mat.NewDense(3, maxpool.GetOutputSize().Total(), []float64{\n\t\t-0.19908814, 0.01521263, 0.31363996, -0.28573613, -0.11934281, -0.18194183, -0.03111016, -0.21696585, -0.20689814,\n\t\t0.17908468, -0.28144695, -0.29681312, -0.13912858, 0.07067328, 0.36249144, -0.20688576, -0.20291744, 0.25257304,\n\t\t-0.29341734, 0.36533501, 0.19671917, 0.02382031, -0.47169692, -0.34167172, 0.10725344, 0.47524162, -0.42054638,\n\t})\n\tfullyconnected.SetCustomWeights([]*mat.Dense{fcCustomWeights})\n\n\tnet := cnns.WholeNet{\n\t\tLP: cnns.NewLearningParametersDefault(),\n\t}\n\tnet.Layers = append(net.Layers, conv)\n\tnet.Layers = append(net.Layers, relu)\n\tnet.Layers = append(net.Layers, maxpool)\n\tnet.Layers = append(net.Layers, fullyconnected)\n\n\timage := mat.NewDense(9, 8, []float64{\n\t\t-0.1, 0.2, 0.3, 0.4, 0.5, 0.6, 0.7, 0.8,\n\t\t-0.9, -0.10, 0.11, 0.12, 0.13, 0.14, 0.15, 0.16,\n\t\t-0.17, 0.18, -0.19, 0.20, 0.21, 0.22, 0.23, 0.24,\n\t\t-0.25, 0.26, 0.27, -0.28, 0.29, 0.30, 0.31, 0.32,\n\t\t-0.33, 0.34, 0.35, 0.36, -0.37, 0.38, 0.39, 0.40,\n\t\t-0.41, 0.42, 0.43, 0.44, 0.45, -0.46, 0.47, 0.48,\n\t\t-0.49, 0.50, 0.51, 0.52, 0.53, 0.54, -0.55, 0.56,\n\t\t-0.57, 0.58, 0.59, 0.60, 0.61, 0.62, 0.63, -0.64,\n\t\t-0.65, 0.66, 0.67, 0.68, 0.69, 0.70, 0.71, 0.72,\n\t})\n\n\tfmt.Printf(\"Layers weights:\\n\")\n\tfor i := range net.Layers {\n\t\tfmt.Printf(\"%s #%d weights:\\n\", net.Layers[i].GetType(), i)\n\t\tnet.Layers[i].PrintWeights()\n\t}\n\tfmt.Println(\"\\tDoing training....\")\n\tfor e := 0; e < 3; e++ {\n\t\terr := net.FeedForward(image)\n\t\tif err != nil {\n\t\t\tlog.Printf(\"Feedforward caused error: %s\", err.Error())\n\t\t\treturn\n\t\t}\n\t\tdesired := mat.NewDense(3, 1, []float64{0.32, 0.45, 0.96})\n\t\terr = net.Backpropagate(desired)\n\t\tif err != nil {\n\t\t\tlog.Printf(\"Backpropagate caused error: %s\", err.Error())\n\t\t\treturn\n\t\t}\n\n\t\tfmt.Printf(\"Epoch #%d. New layers weights\\n\", e)\n\t\tfor i := range net.Layers {\n\t\t\tfmt.Printf(\"%s #%d weights on epoch #%d:\\n\", net.Layers[i].GetType(), i, e)\n\t\t\tnet.Layers[i].PrintWeights()\n\t\t}\n\t}\n\n}", "func Contrast(percentage float32) Filter {\n\tif percentage == 0 {\n\t\treturn &copyimageFilter{}\n\t}\n\n\tp := 1 + minf32(maxf32(percentage, -100), 100)/100\n\n\treturn &colorchanFilter{\n\t\tfn: func(x float32) float32 {\n\t\t\tif 0 <= p && p <= 1 {\n\t\t\t\treturn 0.5 + (x-0.5)*p\n\t\t\t} else if 1 < p && p < 2 {\n\t\t\t\treturn 0.5 + (x-0.5)*(1/(2.0-p))\n\t\t\t} else {\n\t\t\t\tif x < 0.5 {\n\t\t\t\t\treturn 0\n\t\t\t\t}\n\t\t\t\treturn 1\n\t\t\t}\n\t\t},\n\t\tlut: false,\n\t}\n}", "func (n *Node) Convconst(con *Node, t *Type)", "func ConcurrentEdgeFilter(imgSrc image.Image) image.Image {\n\tngo:=runtime.NumCPU()\n\tout := make(chan portion)\n\tslices := imagetools.CropChevauchement(imgSrc, ngo, 10) //on laisse 5 pixels de chevauchement\n\n\tfor i := 0; i < ngo; i++ {\n\t\tgo edgWorker(i, out, slices[i][0])\n\t}\n\n\tfor i := 0; i < ngo; i++ {\n\t\tslice := <-out\n\t\tslices[slice.id][0] = slice.img\n\t}\n\n\timgEnd := imagetools.RebuildChevauchement(slices, 10)\n\n\treturn imgEnd\n\n}", "func Conv2DBackpropFilterV2(scope *Scope, input tf.Output, filter tf.Output, out_backprop tf.Output, strides []int64, padding string, optional ...Conv2DBackpropFilterV2Attr) (output tf.Output) {\n\tif scope.Err() != nil {\n\t\treturn\n\t}\n\tattrs := map[string]interface{}{\"strides\": strides, \"padding\": padding}\n\tfor _, a := range optional {\n\t\ta(attrs)\n\t}\n\topspec := tf.OpSpec{\n\t\tType: \"Conv2DBackpropFilterV2\",\n\t\tInput: []tf.Input{\n\t\t\tinput, filter, out_backprop,\n\t\t},\n\t\tAttrs: attrs,\n\t}\n\top := scope.AddOperation(opspec)\n\treturn op.Output(0)\n}", "func GaussianFilter(src, dst []float64, width int, sigma float64, border Border) {\n\tif width <= 0 {\n\t\twidth = 1 + 2*int(math.Floor(sigma*4+0.5))\n\t}\n\tkernel := make([]float64, width)\n\tGaussianKernel(kernel, sigma)\n\tConvolve(src, dst, kernel, border)\n}", "func (af *filtBase) initWeights(w []float64, n int) error {\n\tif n <= 0 {\n\t\tn = af.n\n\t}\n\tif w == nil {\n\t\tw = make([]float64, n)\n\t}\n\tif len(w) != n {\n\t\treturn fmt.Errorf(\"the length of slice `w` and `n` must agree. len(w): %d, n: %d\", len(w), n)\n\t}\n\taf.w = mat.NewDense(1, n, w)\n\n\treturn nil\n}", "func Conv3DBackpropFilterV2(scope *Scope, input tf.Output, filter_sizes tf.Output, out_backprop tf.Output, strides []int64, padding string, optional ...Conv3DBackpropFilterV2Attr) (output tf.Output) {\n\tif scope.Err() != nil {\n\t\treturn\n\t}\n\tattrs := map[string]interface{}{\"strides\": strides, \"padding\": padding}\n\tfor _, a := range optional {\n\t\ta(attrs)\n\t}\n\topspec := tf.OpSpec{\n\t\tType: \"Conv3DBackpropFilterV2\",\n\t\tInput: []tf.Input{\n\t\t\tinput, filter_sizes, out_backprop,\n\t\t},\n\t\tAttrs: attrs,\n\t}\n\top := scope.AddOperation(opspec)\n\treturn op.Output(0)\n}", "func StepConvolution() *Step {\n\t// TODO\n\treturn nil\n}", "func convolutionMatrixSampleFunction(im ImageMatrix, imagePositionX int, imagePositionY int, kernelPixelX int, kernelPixel int, colour color.RGBA, distance float64) int {\n\tif distance < 1 {\n\t\treturn 1\n\t}\n\n\tif colour.R > 150 && colour.G < 100 && colour.B < 100 {\n\t\treturn int(5 * distance)\n\t}\n\n\treturn 5\n}", "func (r *Ri) PixelFilter(filterfunc RtFilterFunc, xwidth, ywidth RtFloat) error {\n\treturn r.writef(\"PixelFilter\", filterfunc, xwidth, ywidth)\n}", "func DepthwiseConv2dNativeBackpropFilter(scope *Scope, input tf.Output, filter_sizes tf.Output, out_backprop tf.Output, strides []int64, padding string, optional ...DepthwiseConv2dNativeBackpropFilterAttr) (output tf.Output) {\n\tif scope.Err() != nil {\n\t\treturn\n\t}\n\tattrs := map[string]interface{}{\"strides\": strides, \"padding\": padding}\n\tfor _, a := range optional {\n\t\ta(attrs)\n\t}\n\topspec := tf.OpSpec{\n\t\tType: \"DepthwiseConv2dNativeBackpropFilter\",\n\t\tInput: []tf.Input{\n\t\t\tinput, filter_sizes, out_backprop,\n\t\t},\n\t\tAttrs: attrs,\n\t}\n\top := scope.AddOperation(opspec)\n\treturn op.Output(0)\n}", "func FusedPadConv2D(scope *Scope, input tf.Output, paddings tf.Output, filter tf.Output, mode string, strides []int64, padding string) (output tf.Output) {\n\tif scope.Err() != nil {\n\t\treturn\n\t}\n\tattrs := map[string]interface{}{\"mode\": mode, \"strides\": strides, \"padding\": padding}\n\topspec := tf.OpSpec{\n\t\tType: \"FusedPadConv2D\",\n\t\tInput: []tf.Input{\n\t\t\tinput, paddings, filter,\n\t\t},\n\t\tAttrs: attrs,\n\t}\n\top := scope.AddOperation(opspec)\n\treturn op.Output(0)\n}", "func QuantizedConv2DPerChannel(scope *Scope, input tf.Output, filter tf.Output, min_input tf.Output, max_input tf.Output, min_filter tf.Output, max_filter tf.Output, strides []int64, padding string, optional ...QuantizedConv2DPerChannelAttr) (output tf.Output, min_output tf.Output, max_output tf.Output) {\n\tif scope.Err() != nil {\n\t\treturn\n\t}\n\tattrs := map[string]interface{}{\"strides\": strides, \"padding\": padding}\n\tfor _, a := range optional {\n\t\ta(attrs)\n\t}\n\topspec := tf.OpSpec{\n\t\tType: \"QuantizedConv2DPerChannel\",\n\t\tInput: []tf.Input{\n\t\t\tinput, filter, min_input, max_input, min_filter, max_filter,\n\t\t},\n\t\tAttrs: attrs,\n\t}\n\top := scope.AddOperation(opspec)\n\treturn op.Output(0), op.Output(1), op.Output(2)\n}", "func IFFT2D(scope *Scope, input tf.Output) (output tf.Output) {\n\tif scope.Err() != nil {\n\t\treturn\n\t}\n\topspec := tf.OpSpec{\n\t\tType: \"IFFT2D\",\n\t\tInput: []tf.Input{\n\t\t\tinput,\n\t\t},\n\t}\n\top := scope.AddOperation(opspec)\n\treturn op.Output(0)\n}", "func NewDisconnectFilter() Filter {\n\treturn &disconnectFilter{}\n}", "func FusedResizeAndPadConv2D(scope *Scope, input tf.Output, size tf.Output, paddings tf.Output, filter tf.Output, mode string, strides []int64, padding string, optional ...FusedResizeAndPadConv2DAttr) (output tf.Output) {\n\tif scope.Err() != nil {\n\t\treturn\n\t}\n\tattrs := map[string]interface{}{\"mode\": mode, \"strides\": strides, \"padding\": padding}\n\tfor _, a := range optional {\n\t\ta(attrs)\n\t}\n\topspec := tf.OpSpec{\n\t\tType: \"FusedResizeAndPadConv2D\",\n\t\tInput: []tf.Input{\n\t\t\tinput, size, paddings, filter,\n\t\t},\n\t\tAttrs: attrs,\n\t}\n\top := scope.AddOperation(opspec)\n\treturn op.Output(0)\n}", "func MakeCubicFilter(b float64, c float64) *Filter {\n\tvar radius float64\n\tif b == 0 && c == 0 {\n\t\tradius = 1.0\n\t} else {\n\t\tradius = 2.0\n\t}\n\tf := new(Filter)\n\tf.F = func(x float64, scaleFactor float64) float64 {\n\t\tif x < 1.0 {\n\t\t\treturn ((12.0-9.0*b-6.0*c)*x*x*x +\n\t\t\t\t(-18.0+12.0*b+6.0*c)*x*x +\n\t\t\t\t(6.0 - 2.0*b)) / 6.0\n\t\t} else if x < 2.0 {\n\t\t\treturn ((-b-6.0*c)*x*x*x +\n\t\t\t\t(6.0*b+30.0*c)*x*x +\n\t\t\t\t(-12.0*b-48.0*c)*x +\n\t\t\t\t(8.0*b + 24.0*c)) / 6.0\n\t\t}\n\t\treturn 0.0\n\t}\n\tf.Radius = func(scaleFactor float64) float64 {\n\t\treturn radius\n\t}\n\treturn f\n}", "func QuantizedConv2D(scope *Scope, input tf.Output, filter tf.Output, min_input tf.Output, max_input tf.Output, min_filter tf.Output, max_filter tf.Output, strides []int64, padding string, optional ...QuantizedConv2DAttr) (output tf.Output, min_output tf.Output, max_output tf.Output) {\n\tif scope.Err() != nil {\n\t\treturn\n\t}\n\tattrs := map[string]interface{}{\"strides\": strides, \"padding\": padding}\n\tfor _, a := range optional {\n\t\ta(attrs)\n\t}\n\topspec := tf.OpSpec{\n\t\tType: \"QuantizedConv2D\",\n\t\tInput: []tf.Input{\n\t\t\tinput, filter, min_input, max_input, min_filter, max_filter,\n\t\t},\n\t\tAttrs: attrs,\n\t}\n\top := scope.AddOperation(opspec)\n\treturn op.Output(0), op.Output(1), op.Output(2)\n}", "func (l *Conv2D) Forward(inputTensor tensor.Tensor) tensor.Tensor {\n\tl.inputSizeMustMatch(inputTensor)\n\n\tsave := inputTensor.(*Tensor)\n\tl.saveInput(save)\n\n\tbatchSize := l.inputBatchSize(inputTensor)\n\n\tinput := save\n\toutputSize := []int{\n\t\tl.outputSize[0],\n\t\tbatchSize,\n\t\tl.outputSize[1],\n\t\tl.outputSize[2],\n\t}\n\n\toutputHeight := outputSize[2]\n\toutputWidth := outputSize[3]\n\n\tim2ColMatrixHeight := l.numChannels() * l.kernelWidth() * l.kernelHeight()\n\tim2ColMatrixWidth := outputWidth * outputHeight * batchSize\n\tim2ColMatrix := l.TensorOperator.CreateTensor(\n\t\t[]int{im2ColMatrixHeight, im2ColMatrixWidth})\n\tdefer l.TensorOperator.Free(im2ColMatrix)\n\n\tl.im2Col(input, im2ColMatrix,\n\t\t[2]int{l.kernelWidth(), l.kernelHeight()},\n\t\t[4]int{l.padding[0], l.padding[1], l.padding[2], l.padding[3]},\n\t\t[2]int{l.stride[0], l.stride[1]},\n\t\t[2]int{0, 0},\n\t)\n\n\tkernelMatrixWidth := l.kernelWidth() * l.kernelHeight() * l.numChannels()\n\tkernelMatrixHeight := l.numKernels()\n\tkernelMatrix := l.kernel.Reshape(\n\t\t[]int{kernelMatrixHeight, kernelMatrixWidth})\n\n\thKernelData := make([]float32, kernelMatrixWidth*kernelMatrixHeight)\n\tl.GPUDriver.MemCopyD2H(l.GPUCtx, hKernelData, kernelMatrix.ptr)\n\n\toutputMatrix := l.TensorOperator.CreateTensor(\n\t\t[]int{kernelMatrixHeight, im2ColMatrixWidth})\n\tbiasTensor := l.TensorOperator.CreateTensor(\n\t\t[]int{batchSize, l.outputSize[0], l.outputSize[1], l.outputSize[2]})\n\tbiasTensorTrans := l.TensorOperator.CreateTensor(\n\t\t[]int{l.outputSize[0], batchSize, l.outputSize[1], l.outputSize[2]})\n\tl.TensorOperator.Repeat(l.bias, biasTensor, batchSize)\n\tl.TensorOperator.TransposeTensor(biasTensor, biasTensorTrans,\n\t\t[]int{1, 0, 2, 3})\n\tbiasMatrix := biasTensorTrans.Reshape(\n\t\t[]int{l.numKernels(), im2ColMatrixWidth})\n\n\tl.TensorOperator.Gemm(\n\t\tfalse, false,\n\t\tkernelMatrixHeight,\n\t\tim2ColMatrixWidth,\n\t\tkernelMatrixWidth,\n\t\t1.0, 1.0,\n\t\tkernelMatrix, im2ColMatrix, biasMatrix, outputMatrix)\n\n\toutput := &Tensor{\n\t\tdriver: l.GPUDriver,\n\t\tctx: l.GPUCtx,\n\t\tsize: outputSize,\n\t\tptr: outputMatrix.ptr,\n\t\tdescriptor: \"CNHW\",\n\t}\n\n\ttransposedOutput := l.TensorOperator.CreateTensor([]int{\n\t\tbatchSize,\n\t\tl.outputSize[0],\n\t\tl.outputSize[1],\n\t\tl.outputSize[2]})\n\tl.TensorOperator.TransposeTensor(\n\t\toutput, transposedOutput, []int{1, 0, 2, 3})\n\n\tl.TensorOperator.Free(biasTensor)\n\tl.TensorOperator.Free(biasTensorTrans)\n\tl.TensorOperator.Free(output)\n\n\treturn transposedOutput\n}", "func NewKalmanFilter(n int, n0, sigmaK0, sigmaK, sigmaM float64) (k *Filter) {\n\tk = new(Filter)\n\tk.n = n\n\n\tk.x = make(Matrix, 2*n)\n\tk.p = make(Matrix, 2*n)\n\tk.q = make(Matrix, 2*n)\n\n\tfor i := 0; i < n; i++ {\n\t\tk.x[2*i] = []float64{1}\n\t\tk.x[2*i+1] = []float64{0}\n\n\t\tk.p[2*i] = make([]float64, 2*n)\n\t\tk.p[2*i+1] = make([]float64, 2*n)\n\t\tk.p[2*i][2*i] = sigmaK0 * sigmaK0\n\t\tk.p[2*i+1][2*i+1] = (n0 * sigmaK0) * (n0 * sigmaK0)\n\n\t\tk.q[2*i] = make([]float64, 2*n)\n\t\tk.q[2*i+1] = make([]float64, 2*n)\n\t\tk.q[2*i][2*i] = sigmaK * sigmaK\n\t\tk.q[2*i+1][2*i+1] = (n0 * sigmaK) * (n0 * sigmaK)\n\t}\n\n\tk.r = Matrix{{(n0 * sigmaM) * (n0 * sigmaM)}}\n\n\tk.U = make(chan Matrix)\n\tk.Z = make(chan float64)\n\n\tgo k.runFilter()\n\n\treturn k\n}", "func newImageBinaryChannels(imgSrc image.Image, colorChannelTypes ...channelType) []*imageBinaryChannel {\n\tchannels := make([]*imageBinaryChannel, 3)\n\tmax := imgSrc.Bounds().Max\n\tw, h := max.X, max.Y\n\tfor i, channelType := range colorChannelTypes {\n\t\tcolorChannel := image.NewGray(image.Rectangle{Max: image.Point{w, h}})\n\t\tfor x := 0; x < w; x++ {\n\t\t\tfor y := 0; y < h; y++ {\n\t\t\t\tcolorPixel := imgSrc.At(x, y).(color.NRGBA)\n\t\t\t\tvar c uint8\n\t\t\t\tswitch channelType {\n\t\t\t\tcase red:\n\t\t\t\t\tc = colorPixel.R\n\t\t\t\tcase green:\n\t\t\t\t\tc = colorPixel.G\n\t\t\t\tcase blue:\n\t\t\t\t\tc = colorPixel.B\n\t\t\t\t}\n\t\t\t\tgrayPixel := color.Gray{Y: c}\n\t\t\t\tcolorChannel.Set(x, y, grayPixel)\n\t\t\t}\n\t\t}\n\t\tchannels[i] = newImageBinaryChannel(colorChannel, channelType)\n\t}\n\treturn channels\n}", "func NewConvolutionalLayer(\n\tinputSize, kernelSize, stride, padding []int,\n\tGPUDriver *driver.Driver,\n\tGPUCtx *driver.Context,\n\tTensorOperator *TensorOperator,\n) *Conv2D {\n\t// argumentsMustBeValid(inputSize, kernelSize, stride, padding)\n\n\tl := &Conv2D{\n\t\tinputSize: inputSize,\n\t\tkernelSize: kernelSize,\n\t\tstride: stride,\n\t\tpadding: padding,\n\t\tGPUDriver: GPUDriver,\n\t\tGPUCtx: GPUCtx,\n\t\tTensorOperator: TensorOperator,\n\t}\n\tl.calculateOutputSize()\n\tl.loadKernels()\n\tl.allocateMemory()\n\n\treturn l\n}", "func (img *FloatImage) ConvolveWrapWith(kernel *ConvKernel, px planeExtension) {\n\timg.convolveWith(kernel, wrapPlaneExtension)\n}", "func (cm *ConnectionManager) RegisterFilters(source <-chan packet.Packet,\n\tfilters ...func(packet.Packet) packet.Packet) <-chan packet.Packet {\n\tsink := make(chan packet.Packet)\n\n\tgo func() {\n\t\tfor p := range source {\n\t\t\tfor _, filter := range filters {\n\t\t\t\tif pass := filter(p); pass != nil {\n\t\t\t\t\tsink <- pass\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}()\n\n\treturn sink\n}", "func (spec *static) CreateFilter(config []interface{}) (filters.Filter, error) {\n\tif len(config) != 2 {\n\t\treturn nil, fmt.Errorf(\"invalid number of args: %d, expected 1\", len(config))\n\t}\n\n\twebRoot, ok := config[0].(string)\n\tif !ok {\n\t\treturn nil, fmt.Errorf(\"invalid parameter type, expected string for web root prefix\")\n\t}\n\n\troot, ok := config[1].(string)\n\tif !ok {\n\t\treturn nil, fmt.Errorf(\"invalid parameter type, expected string for path to root dir\")\n\t}\n\n\treturn &static{webRoot, root}, nil\n}", "func MulConstSSE32(c float32, x []float32, y []float32)", "func MulConstSSE64(c float64, x []float64, y []float64)", "func NewFilter(bitmapSize int32) Filter {\n\treturn Filter{\n\t\tbitmapSize: bitmapSize,\n\t\tbitmap: make([]bool, bitmapSize, bitmapSize),\n\t\tnumberMapper: NewNumberMapper(minInt32, maxInt32, 0, bitmapSize-1),\n\t}\n}", "func bloomFilterParams(n int64, p float64) (m, k uint) {\n\tif n <= 0 || p <= 0 || p >= 1 {\n\t\treturn 1, 0\n\t}\n\tc := 0.6185 // 0.5 ^ (m/n * ln 2) ~= 0.6185 ^ (m/n)\n\tnf := float64(n)\n\n\tmf := math.Log(p) / math.Log(c) * nf\n\tm = uint(math.Ceil(mf))\n\n\tkf := mf / nf * math.Log(2)\n\tk = uint(math.Floor(kf))\n\n\treturn\n}", "func Catnip(cfg *Config) error {\n\t// allocate as much as possible as soon as possible\n\tvar (\n\n\t\t// slowMax/fastMax\n\t\tslowMax = ((int(ScalingSlowWindow * cfg.SampleRate)) / cfg.SampleSize) * 2\n\t\tfastMax = ((int(ScalingFastWindow * cfg.SampleRate)) / cfg.SampleSize) * 2\n\n\t\ttotal = ((cfg.ChannelCount * cfg.SampleSize) * 2) + (slowMax + fastMax)\n\n\t\tfloatData = make([]float64, total)\n\t)\n\n\tvar sessConfig = input.SessionConfig{\n\t\tFrameSize: cfg.ChannelCount,\n\t\tSampleSize: cfg.SampleSize,\n\t\tSampleRate: cfg.SampleRate,\n\t}\n\n\tvis := visualizer{\n\t\tcfg: cfg,\n\t\tslowWindow: util.MovingWindow{\n\t\t\tCapacity: slowMax,\n\t\t\tData: floatData[:slowMax],\n\t\t},\n\t\tfastWindow: util.MovingWindow{\n\t\t\tCapacity: fastMax,\n\t\t\tData: floatData[slowMax : slowMax+fastMax],\n\t\t},\n\n\t\tfftBuf: make([]complex128, cfg.SampleSize/2+1),\n\t\tinputBufs: make([][]float64, cfg.ChannelCount),\n\t\tbarBufs: make([][]float64, cfg.ChannelCount),\n\n\t\tplans: make([]*fft.Plan, cfg.ChannelCount),\n\t\tspectrum: dsp.Spectrum{\n\t\t\tSampleRate: cfg.SampleRate,\n\t\t\tSampleSize: cfg.SampleSize,\n\t\t\tBins: make([]dsp.Bin, cfg.SampleSize),\n\t\t\tOldValues: make([][]float64, cfg.ChannelCount),\n\t\t},\n\n\t\tbars: 0,\n\t\tdisplay: graphic.Display{},\n\t}\n\n\tvar pos = slowMax + fastMax\n\tfor idx := range vis.barBufs {\n\n\t\tvis.barBufs[idx] = floatData[pos : pos+cfg.SampleSize]\n\t\tpos += cfg.SampleSize\n\n\t\tvis.inputBufs[idx] = floatData[pos : pos+cfg.SampleSize]\n\t\tpos += cfg.SampleSize\n\n\t\tvis.plans[idx] = &fft.Plan{\n\t\t\tInput: vis.inputBufs[idx],\n\t\t\tOutput: vis.fftBuf,\n\t\t}\n\n\t\tvis.spectrum.OldValues[idx] = make([]float64, cfg.SampleSize)\n\n\t\tvis.plans[idx].Init()\n\t}\n\n\t// INPUT SETUP\n\n\tvar backend, err = initBackend(cfg)\n\tif err != nil {\n\t\treturn err\n\t}\n\n\tif sessConfig.Device, err = getDevice(backend, cfg); err != nil {\n\t\treturn err\n\t}\n\n\taudio, err := backend.Start(sessConfig)\n\tdefer backend.Close()\n\n\tif err != nil {\n\t\treturn errors.Wrap(err, \"failed to start the input backend\")\n\t}\n\n\tvis.spectrum.SetSmoothing(cfg.SmoothFactor)\n\tvis.spectrum.SetWinVar(cfg.WinVar)\n\n\tif err = vis.display.Init(); err != nil {\n\t\treturn err\n\t}\n\tdefer vis.display.Close()\n\n\tvis.display.SetSizes(cfg.BarSize, cfg.SpaceSize)\n\tvis.display.SetBase(cfg.BaseSize)\n\tvis.display.SetDrawType(graphic.DrawType(cfg.DrawType))\n\tvis.display.SetStyles(cfg.Styles)\n\n\t// Root Context\n\tctx, cancel := context.WithCancel(context.Background())\n\tdefer cancel()\n\n\t// Start the display\n\t// replace our context so display can signal quit\n\tctx = vis.display.Start(ctx)\n\tdefer vis.display.Stop()\n\n\tif err := audio.Start(ctx, vis.inputBufs, &vis); err != nil {\n\t\treturn errors.Wrap(err, \"failed to start input session\")\n\t}\n\n\treturn nil\n}", "func (spec *static) CreateFilter(config []interface{}) (filters.Filter, error) {\n\tif len(config) != 2 {\n\t\treturn nil, fmt.Errorf(\"invalid number of args: %d, expected 2\", len(config))\n\t}\n\n\twebRoot, ok := config[0].(string)\n\tif !ok {\n\t\treturn nil, fmt.Errorf(\"invalid parameter type, expected string for web root prefix\")\n\t}\n\n\troot, ok := config[1].(string)\n\tif !ok {\n\t\tlog.Errorf(\"Invalid parameter type, expected string for path to root dir\")\n\t\treturn nil, filters.ErrInvalidFilterParameters\n\t}\n\n\tif ok, err := existsAndAccessible(root); !ok {\n\t\tlog.Errorf(\"Invalid parameter for root path. File %s does not exist or is not accessible: %v\", root, err)\n\t\treturn nil, filters.ErrInvalidFilterParameters\n\t}\n\n\treturn &static{http.StripPrefix(webRoot, http.FileServer(http.Dir(root)))}, nil\n}", "func (fd FailureDist) Convolve(other FailureDist) (FailureDist, error) {\n\tn := len(fd.prob)\n\tif n != len(other.prob) {\n\t\treturn FailureDist{},\n\t\t\tfmt.Errorf(\"size mismatch %d != %d\", n, len(other.prob))\n\t}\n\tresult := make([]float64, n)\n\n\tfor i := 0; i < n; i++ {\n\t\tfor j := 0; j < n; j++ {\n\t\t\tk := i + j\n\t\t\tif k < n {\n\t\t\t\tresult[k] += fd.prob[i] * other.prob[j]\n\t\t\t}\n\t\t}\n\t}\n\n\treturn MakeFailureDist(result)\n}", "func WideAxpy(c, b []float64, s float64, ci, bi int)", "func (spec *Filter) CreateFilter(config []interface{}) (filters.Filter, error) {\n\treturn &Filter{spec.FilterName, config}, nil\n}", "func newNodeFilterIterator(src, filter Nodes, root int64) *nodeFilterIterator {\n\tn := nodeFilterIterator{src: src, filter: map[int64]bool{root: true}}\n\tfor filter.Next() {\n\t\tn.filter[filter.Node().ID()] = true\n\t}\n\tfilter.Reset()\n\tn.src.Reset()\n\treturn &n\n}", "func Conv3DBackpropFilter(scope *Scope, input tf.Output, filter tf.Output, out_backprop tf.Output, strides []int64, padding string, optional ...Conv3DBackpropFilterAttr) (output tf.Output) {\n\tif scope.Err() != nil {\n\t\treturn\n\t}\n\tattrs := map[string]interface{}{\"strides\": strides, \"padding\": padding}\n\tfor _, a := range optional {\n\t\ta(attrs)\n\t}\n\topspec := tf.OpSpec{\n\t\tType: \"Conv3DBackpropFilter\",\n\t\tInput: []tf.Input{\n\t\t\tinput, filter, out_backprop,\n\t\t},\n\t\tAttrs: attrs,\n\t}\n\top := scope.AddOperation(opspec)\n\treturn op.Output(0)\n}", "func MakeTriangleFilter() *Filter {\n\tf := new(Filter)\n\tf.F = func(x float64, scaleFactor float64) float64 {\n\t\tif x < 1.0 {\n\t\t\treturn 1.0 - x\n\t\t}\n\t\treturn 0.0\n\t}\n\tf.Radius = func(scaleFactor float64) float64 {\n\t\treturn 1.0\n\t}\n\treturn f\n}", "func PSHUFLW(i, mx, x operand.Op) { ctx.PSHUFLW(i, mx, x) }", "func dontModifyConvolutionMatrixWeights(im ImageMatrix, imagePositionX int, imagePositionY int, kernelPixelX int, kernelPixel int, colour color.RGBA, distance float64) int {\n\treturn 1\n}", "func kwReduction(gr g.Graph, poolSize int, debug int) g.Graph {\n\tif debug % 2 == 1 {\n\t\tfmt.Printf(\"Starting KW Reduction \\n\")\n\t}\n\tdegree := gr.MaxDegree\n\tstartIndexes := make([]int, 0)\n\tsize := len(gr.Nodes)\n\tc := make(chan g.Graph)\n\t// If we can't split the graph into bins,\n\tif size < 2 * (degree + 1) {\n\t\tgr.Description = \"Color Reduced with KW\"\n\t\tgo runNaiveGoRoutine(gr, poolSize, debug, c)\n\t\treturn <- c\n\t}\n\tfor x := 0; x < size; x++ {\n\t\tif x % (2 * (degree + 1)) == 0 {\n\t\t\tstartIndexes = append(startIndexes, x)\n\t\t}\n\t}\n\n\tnumColors := g.CountColors(&gr)\n\tcolorBins := make([][]*g.Node, numColors)\n\tcolorToIndex := make(map[int]int)\n\tlatestIndex := 0\n\tfor _, node := range gr.Nodes {\n\t\tif _, ok := colorToIndex[node.Color]; ! ok {\n\t\t\tcolorToIndex[node.Color] = latestIndex\n\t\t\tlatestIndex++\n\t\t}\n\t\tcolorBins[colorToIndex[node.Color]] = append(colorBins[colorToIndex[node.Color]], node)\n\t}\n\n\tfor len(colorBins) > degree + 1 {\n\t\t//fmt.Printf(\"Number of bins: %d\\n\", len(colorBins))\n\t\td := make(chan [][]*g.Node)\n\t\tbinIndexes := make([]int, 0)\n\t\tcolors := len(colorBins)\n\n\t\tfor x := 0; x < colors; x++ {\n\t\t\tif x%(2*(degree+1)) == 0 {\n\t\t\t\tbinIndexes = append(binIndexes, x)\n\t\t\t}\n\t\t}\n\t\ttempBins := make([][]*g.Node, 0)\n\n\t\tfor i := 0; i < len(binIndexes); i++ {\n\t\t\tcurrStart := binIndexes[i]\n\t\t\tvar nextStart int\n\t\t\tif i+1 != len(binIndexes) {\n\t\t\t\tnextStart = binIndexes[i+1]\n\t\t\t} else {\n\t\t\t\tnextStart = len(colorBins)\n\t\t\t}\n\t\t\tgo combineColorsWithoutNaive(colorBins[currStart:nextStart], gr, d)\n\t\t}\n\t\tfor i := 0; i < len(binIndexes); i++ {\n\t\t\tbins := <-d\n\t\t\ttempBins = append(tempBins, bins...)\n\t\t}\n\n\t\tclose(d)\n\n\t\tcolorBins = tempBins\n\t\ttempBins = make([][]*g.Node, 0)\n\t}\n\tgraph := convertBinsToGraph(colorBins, &gr)\n\treturn *graph\n}", "func (d *dataUpdateTracker) cycleFilter(ctx context.Context, req bloomFilterRequest) (*bloomFilterResponse, error) {\n\tif req.OldestClean != \"\" {\n\t\treturn &bloomFilterResponse{OldestIdx: d.latestWithDir(req.OldestClean)}, nil\n\t}\n\tcurrent := req.Current\n\toldest := req.Oldest\n\td.mu.Lock()\n\tdefer d.mu.Unlock()\n\tif current == 0 {\n\t\tif len(d.History) == 0 {\n\t\t\treturn d.filterFrom(ctx, d.Current.idx, d.Current.idx), nil\n\t\t}\n\t\td.History.sort()\n\t\tif oldest == 0 {\n\t\t\toldest = d.History[len(d.History)-1].idx\n\t\t}\n\t\treturn d.filterFrom(ctx, oldest, d.Current.idx), nil\n\t}\n\n\t// Move current to history if new one requested\n\tif d.Current.idx != current {\n\t\td.dirty = true\n\t\tif d.debug {\n\t\t\tconsole.Debugf(color.Green(\"dataUpdateTracker:\")+\" cycle bloom filter: %v -> %v\\n\", d.Current.idx, current)\n\t\t}\n\n\t\td.History = append(d.History, d.Current)\n\t\td.Current.idx = current\n\t\td.Current.bf = d.newBloomFilter()\n\t\tselect {\n\t\tcase d.save <- struct{}{}:\n\t\tdefault:\n\t\t}\n\t}\n\td.History.removeOlderThan(oldest)\n\treturn d.filterFrom(ctx, oldest, current), nil\n}", "func KXORW(k, k1, k2 operand.Op) { ctx.KXORW(k, k1, k2) }", "func NewFilter(config *config.Config) (filter *Filter) {\n\tfilter = new(Filter)\n\tfilter.Config = config\n\treturn\n}", "func NewBloomFilter(size, hashN uint64) (*BloomFilter, error) {\n\tbitMap, _ := bitmap.NewBitMap(size)\n\tfilter := &BloomFilter{\n\t\tbitMap: bitMap,\n\t\tm: size,\n\t\tk: hashN,\n\t\thashFunc: hmacHash,\n\t}\n\n\treturn filter, nil\n}", "func NewFilter(keys []uint32, bitsPerKey int) Filter {\n\treturn Filter(appendFilter(nil, keys, bitsPerKey))\n}", "func FFT2D(scope *Scope, input tf.Output) (output tf.Output) {\n\tif scope.Err() != nil {\n\t\treturn\n\t}\n\topspec := tf.OpSpec{\n\t\tType: \"FFT2D\",\n\t\tInput: []tf.Input{\n\t\t\tinput,\n\t\t},\n\t}\n\top := scope.AddOperation(opspec)\n\treturn op.Output(0)\n}", "func (cc *ConvolutionCoder) Decode(data []byte) (output []byte) {\n\tframeBits := int64(len(data)) * 8\n\toutput = make([]byte, int(frameBits)/(8*cc.r))\n\tcorrectwrap.Correct_convolutional_decode(cc.cc, &data[0], frameBits, &output[0])\n\n\treturn output\n}", "func NewFilter(P uint8, key [KeySize]byte, data [][]byte) (*Filter, error) {\n\t// Some initial parameter checks: make sure we have data from which to\n\t// build the filter, and make sure our parameters will fit the hash\n\t// function we're using.\n\tif len(data) == 0 {\n\t\treturn nil, ErrNoData\n\t}\n\tif len(data) > math.MaxInt32 {\n\t\treturn nil, ErrNTooBig\n\t}\n\tif P > 32 {\n\t\treturn nil, ErrPTooBig\n\t}\n\n\t// Create the filter object and insert metadata.\n\tmodP := uint64(1 << P)\n\tmodPMask := modP - 1\n\tf := Filter{\n\t\tn: uint32(len(data)),\n\t\tp: P,\n\t\tmodulusNP: uint64(len(data)) * modP,\n\t}\n\n\t// Allocate filter data.\n\tvalues := make([]uint64, 0, len(data))\n\n\t// Insert the hash (modulo N*P) of each data element into a slice and\n\t// sort the slice.\n\tk0 := binary.LittleEndian.Uint64(key[0:8])\n\tk1 := binary.LittleEndian.Uint64(key[8:16])\n\tfor _, d := range data {\n\t\tv := siphash.Hash(k0, k1, d) % f.modulusNP\n\t\tvalues = append(values, v)\n\t}\n\tsort.Sort((*uint64s)(&values))\n\n\tvar b bitWriter\n\n\t// Write the sorted list of values into the filter bitstream,\n\t// compressing it using Golomb coding.\n\tvar value, lastValue, remainder uint64\n\tfor _, v := range values {\n\t\t// Calculate the difference between this value and the last,\n\t\t// modulo P.\n\t\tremainder = (v - lastValue) & modPMask\n\n\t\t// Calculate the difference between this value and the last,\n\t\t// divided by P.\n\t\tvalue = (v - lastValue - remainder) >> f.p\n\t\tlastValue = v\n\n\t\t// Write the P multiple into the bitstream in unary; the\n\t\t// average should be around 1 (2 bits - 0b10).\n\t\tfor value > 0 {\n\t\t\tb.writeOne()\n\t\t\tvalue--\n\t\t}\n\t\tb.writeZero()\n\n\t\t// Write the remainder as a big-endian integer with enough bits\n\t\t// to represent the appropriate collision probability.\n\t\tb.writeNBits(remainder, uint(f.p))\n\t}\n\n\t// Save the filter data internally as n + filter bytes\n\tndata := make([]byte, 4+len(b.bytes))\n\tbinary.BigEndian.PutUint32(ndata, f.n)\n\tcopy(ndata[4:], b.bytes)\n\tf.filterNData = ndata\n\n\treturn &f, nil\n}", "func CreateFilterRing(m *model3d.Mesh) *model3d.Mesh {\n\tcollider := model3d.MeshToCollider(m)\n\n\t// Pick a z-axis where we can slice the ring.\n\tsliceZ := 2 + m.Min().Z\n\t// Scale up the bitmap to get accurate resolution.\n\tconst scale = 20\n\n\tlog.Println(\"Tracing ring outline...\")\n\tmin := m.Min()\n\tsize := m.Max().Sub(min)\n\tbitmap := model2d.NewBitmap(int(size.X*scale), int(size.Y*scale))\n\tfor y := 0; y < bitmap.Height; y++ {\n\t\tfor x := 0; x < bitmap.Width; x++ {\n\t\t\trealX := min.X + float64(x)/scale\n\t\t\trealY := min.Y + float64(y)/scale\n\t\t\tnumColl := collider.RayCollisions(&model3d.Ray{\n\t\t\t\tOrigin: model3d.XYZ(realX, realY, sliceZ),\n\t\t\t\tDirection: model3d.X(1),\n\t\t\t}, nil)\n\t\t\tnumColl1 := collider.RayCollisions(&model3d.Ray{\n\t\t\t\tOrigin: model3d.XYZ(realX, realY, sliceZ),\n\t\t\t\tDirection: model3d.Coord3D{X: -1},\n\t\t\t}, nil)\n\t\t\tbitmap.Set(x, y, numColl == 2 && numColl1 == 2)\n\t\t}\n\t}\n\n\tsolid := NewRingSolid(bitmap, scale)\n\tsqueeze := &toolbox3d.AxisSqueeze{\n\t\tAxis: toolbox3d.AxisZ,\n\t\tMin: 1,\n\t\tMax: 4.5,\n\t\tRatio: 0.1,\n\t}\n\tlog.Println(\"Creating mesh...\")\n\tmesh := model3d.MarchingCubesConj(solid, 0.1, 8, squeeze)\n\tlog.Println(\"Done creating mesh...\")\n\tmesh = mesh.FlattenBase(0)\n\tmesh = mesh.EliminateCoplanar(1e-8)\n\treturn mesh\n}", "func (ws *webhookSpec) CreateFilter(args []interface{}) (filters.Filter, error) {\n\tif l := len(args); l == 0 || l > 2 {\n\t\treturn nil, filters.ErrInvalidFilterParameters\n\t}\n\n\tvar ok bool\n\ts, ok := args[0].(string)\n\tif !ok {\n\t\treturn nil, filters.ErrInvalidFilterParameters\n\t}\n\n\tforwardResponseHeaderKeys := make([]string, 0)\n\n\tif len(args) > 1 {\n\t\t// Capture headers that should be forwarded from webhook responses.\n\t\theaderKeysOption, ok := args[1].(string)\n\t\tif !ok {\n\t\t\treturn nil, filters.ErrInvalidFilterParameters\n\t\t}\n\n\t\theaderKeys := strings.Split(headerKeysOption, \",\")\n\n\t\tfor _, header := range headerKeys {\n\t\t\tvalid := httpguts.ValidHeaderFieldName(header)\n\t\t\tif !valid {\n\t\t\t\treturn nil, fmt.Errorf(\"header %s is invalid\", header)\n\t\t\t}\n\t\t\tforwardResponseHeaderKeys = append(forwardResponseHeaderKeys, http.CanonicalHeaderKey(header))\n\t\t}\n\t}\n\n\tvar ac *authClient\n\tvar err error\n\tif ac, ok = webhookAuthClient[s]; !ok {\n\t\tac, err = newAuthClient(s, webhookSpanName, ws.options.Timeout, ws.options.MaxIdleConns, ws.options.Tracer)\n\t\tif err != nil {\n\t\t\treturn nil, filters.ErrInvalidFilterParameters\n\t\t}\n\t\twebhookAuthClient[s] = ac\n\t}\n\n\treturn &webhookFilter{authClient: ac, forwardResponseHeaderKeys: forwardResponseHeaderKeys}, nil\n}", "func Filter(r io.Reader, w io.Writer, conf Config) error {\n\ts := bufio.NewScanner(r)\n\tfilters := compile(conf)\n\n\tfor s.Scan() {\n\t\tmetric := s.Bytes()\n\t\tparts := bytes.SplitN(metric, []byte(\"|\"), 2)\n\t\tname := parts[0]\n\n\t\tif len(name) == 0 {\n\t\t\tcontinue\n\t\t}\n\n\t\ttail := parts[1]\n\n\t\tfor regexp, v := range filters {\n\t\t\tmatches := regexp.FindAllSubmatch(name, -1)\n\n\t\t\tif matches == nil {\n\t\t\t\tcontinue\n\t\t\t}\n\n\t\t\tswitch v.(type) {\n\t\t\tcase string:\n\t\t\t\tw.Write(replace([]byte(v.(string)), matches))\n\t\t\t\tw.Write([]byte(\"|\"))\n\t\t\t\tw.Write(tail)\n\t\t\t\tw.Write([]byte(\"\\n\"))\n\t\t\tcase bool:\n\t\t\t\tw.Write(metric)\n\t\t\t\tw.Write([]byte(\"\\n\"))\n\t\t\t}\n\t\t}\n\t}\n\n\treturn s.Err()\n}", "func Conj(scope *Scope, input tf.Output) (output tf.Output) {\n\tif scope.Err() != nil {\n\t\treturn\n\t}\n\topspec := tf.OpSpec{\n\t\tType: \"Conj\",\n\t\tInput: []tf.Input{\n\t\t\tinput,\n\t\t},\n\t}\n\top := scope.AddOperation(opspec)\n\treturn op.Output(0)\n}", "func InverseBloomFilterFactory(capacity uint) func() boom.Filter {\n\treturn func() boom.Filter {\n\t\treturn boom.NewInverseBloomFilter(capacity)\n\t}\n}", "func newFiltBase(n int, mu float64, w []float64) (AdaptiveFilter, error) {\n\tvar err error\n\tp := new(filtBase)\n\tp.kind = \"Base filter\"\n\tp.n = n\n\tp.muMin = 0\n\tp.muMax = 1000\n\tp.mu, err = p.checkFloatParam(mu, p.muMin, p.muMax, \"mu\")\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\terr = p.initWeights(w, n)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\treturn p, nil\n}", "func (o NetworkPacketCaptureOutput) Filters() NetworkPacketCaptureFilterArrayOutput {\n\treturn o.ApplyT(func(v *NetworkPacketCapture) NetworkPacketCaptureFilterArrayOutput { return v.Filters }).(NetworkPacketCaptureFilterArrayOutput)\n}", "func NewBloomFilter(size uint64, hf int) (*BloomFilter, error) {\n\tvar bf BloomFilter\n\tbf.size = size\n\tif bf.size < 64 {\n\t\treturn nil, errors.New(\"Filter size must be at least 64\")\n\t} else if (bf.size & (bf.size - 1)) != 0 {\n\t\treturn nil, errors.New(\"Size must be a power of 2\")\n\t}\n\tbf.bv = make([]uint64, size/64)\n\tbf.hf = int(hf)\n\tbf.mut = &sync.RWMutex{}\n\n\tfor i := 0; i < len(bf.bv); i++ {\n\t\tbf.bv[i] = 0\n\t}\n\n\treturn &bf, nil\n}", "func MulConstAVX32(c float32, x []float32, y []float32)", "func MulConstAVX64(c float64, x []float64, y []float64)", "func (r ApiGetHyperflexWitnessConfigurationListRequest) Filter(filter string) ApiGetHyperflexWitnessConfigurationListRequest {\n\tr.filter = &filter\n\treturn r\n}", "func CBW() { ctx.CBW() }", "func NewBloomFilter(numHashFuncs, bfSize int) *BloomFilter {\n\tbf := new(BloomFilter)\n\tbf.bitmap = make([]bool, bfSize)\n\tbf.k, bf.m = numHashFuncs, bfSize\n\tbf.n = 0\n\tbf.hashfn = fnv.New64()\n\treturn bf\n}" ]
[ "0.6764273", "0.6433451", "0.625944", "0.62001973", "0.61661077", "0.6104609", "0.6010403", "0.5931696", "0.59293765", "0.58326757", "0.57719404", "0.5683592", "0.5555621", "0.55529857", "0.5445007", "0.54182565", "0.5418026", "0.5310228", "0.52937627", "0.52414465", "0.5238497", "0.5211694", "0.5118201", "0.50967693", "0.5062519", "0.5024831", "0.50247633", "0.4998366", "0.49954307", "0.49759877", "0.4953377", "0.49173617", "0.49022707", "0.48896873", "0.48679507", "0.48547646", "0.48241824", "0.47993058", "0.4797748", "0.47889113", "0.47734827", "0.47590217", "0.47562376", "0.473681", "0.46386707", "0.46272266", "0.4578344", "0.4557851", "0.4556702", "0.45392856", "0.45300812", "0.45221737", "0.44844934", "0.4448312", "0.4442962", "0.44422117", "0.44408113", "0.4435571", "0.4431742", "0.44139877", "0.44116107", "0.44078225", "0.440397", "0.4395197", "0.43906647", "0.43646297", "0.4364191", "0.4351697", "0.4349075", "0.43044242", "0.43043977", "0.42701545", "0.42668095", "0.42644426", "0.42423904", "0.42361677", "0.42358178", "0.42347947", "0.4233624", "0.42313147", "0.42224127", "0.4210607", "0.42013374", "0.41963798", "0.4182031", "0.41816834", "0.4177878", "0.41708705", "0.41636217", "0.41569415", "0.41514114", "0.41459", "0.41440415", "0.41411144", "0.4132022", "0.41312152", "0.41291332", "0.4128239", "0.41268808", "0.41226" ]
0.662493
1
copy all or part of the data store of a buffer object to the data store of another buffer object
func CopyBufferSubData(readTarget uint32, writeTarget uint32, readOffset int, writeOffset int, size int) { C.glowCopyBufferSubData(gpCopyBufferSubData, (C.GLenum)(readTarget), (C.GLenum)(writeTarget), (C.GLintptr)(readOffset), (C.GLintptr)(writeOffset), (C.GLsizeiptr)(size)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func CopyBufferSubData(readTarget uint32, writeTarget uint32, readOffset int, writeOffset int, size int) {\n\tsyscall.Syscall6(gpCopyBufferSubData, 5, uintptr(readTarget), uintptr(writeTarget), uintptr(readOffset), uintptr(writeOffset), uintptr(size), 0)\n}", "func CopyBufferSubData(readTarget uint32, writeTarget uint32, readOffset int, writeOffset int, size int) {\n C.glowCopyBufferSubData(gpCopyBufferSubData, (C.GLenum)(readTarget), (C.GLenum)(writeTarget), (C.GLintptr)(readOffset), (C.GLintptr)(writeOffset), (C.GLsizeiptr)(size))\n}", "func copyIfNeeded(bd *netBuf, b []byte) []byte {\n\tif bd.pool == -1 && sameUnderlyingStorage(b, bd.buf) {\n\t\treturn b\n\t}\n\tn := make([]byte, len(b))\n\tcopy(n, b)\n\treturn n\n}", "func (r *Relay) copyWithBuffer(dst io.Writer, src io.Reader, buf []byte) (written int64, err error) {\n\tfor {\n\t\tnr, er := src.Read(buf)\n\t\tif nr > 0 {\n\t\t\tnw, ew := dst.Write(buf[0:nr])\n\t\t\tif nw < 0 || nr < nw {\n\t\t\t\tnw = 0\n\t\t\t\tif ew == nil {\n\t\t\t\t\tew = errInvalidWrite\n\t\t\t\t}\n\t\t\t}\n\t\t\twritten += int64(nw)\n\t\t\tif ew != nil {\n\t\t\t\terr = ew\n\t\t\t\tbreak\n\t\t\t}\n\t\t\tif nr != nw {\n\t\t\t\terr = io.ErrShortWrite\n\t\t\t\tbreak\n\t\t\t}\n\t\t\tif r.metricsTracer != nil {\n\t\t\t\tr.metricsTracer.BytesTransferred(nw)\n\t\t\t}\n\t\t}\n\t\tif er != nil {\n\t\t\tif er != io.EOF {\n\t\t\t\terr = er\n\t\t\t}\n\t\t\tbreak\n\t\t}\n\t}\n\treturn written, err\n}", "func CopyNamedBufferSubData(readBuffer uint32, writeBuffer uint32, readOffset int, writeOffset int, size int) {\n\tsyscall.Syscall6(gpCopyNamedBufferSubData, 5, uintptr(readBuffer), uintptr(writeBuffer), uintptr(readOffset), uintptr(writeOffset), uintptr(size), 0)\n}", "func (d *OneToOne) Set(data GenericDataType) {\n\tidx := d.writeIndex % uint64(len(d.buffer))\n\n\tnewBucket := &bucket{\n\t\tdata: data,\n\t\tseq: d.writeIndex,\n\t}\n\td.writeIndex++\n\n\tatomic.StorePointer(&d.buffer[idx], unsafe.Pointer(newBucket))\n}", "func (b *Buffer) CopyDataFrom(src *Buffer, srcOffset, dstOffset, size int) error {\n\tif size == 0 {\n\t\treturn nil\n\t}\n\n\terrCode := cl.EnqueueCopyBuffer(\n\t\tb.device.cmdQueue,\n\t\tsrc.bufHandle,\n\t\tb.bufHandle,\n\t\tuint64(srcOffset),\n\t\tuint64(dstOffset),\n\t\tuint64(size),\n\t\t0,\n\t\tnil,\n\t\tnil,\n\t)\n\n\tif errCode != cl.SUCCESS {\n\t\treturn fmt.Errorf(\"opencl device(%s): error copying device data from buffer %s to buffer %s (errCode %d)\", b.device.Name, src.name, b.name, errCode)\n\t}\n\treturn nil\n}", "func (server *StorageServer) copyToMemory(data []byte) int32 {\n\n\t// allocate memory in wasm\n\tptr, err := server.funcs[\"alloc\"].Call(int32(len(data)))\n\tcheck(err)\n\n\t// casting pointer to int32\n\tptr32 := ptr.(int32)\n\n\t//fmt.Printf(\"This is the pointer %v\\n\", ptr32)\n\n\t// return raw memory backed by the WebAssembly memory as a byte slice\n\tbuf := server.memory.UnsafeData()\n\tfor i, v := range data {\n\t\tbuf[ptr32+int32(i)] = v\n\t}\n\t// return the pointer\n\treturn ptr32\n}", "func copyData(oldKV, newKV storage.OrderedKeyValueDB, d1, d2 dvid.Data, uuid dvid.UUID, f storage.Filter, flatten bool) error {\n\t// Get data context for this UUID.\n\tv, err := VersionFromUUID(uuid)\n\tif err != nil {\n\t\treturn err\n\t}\n\tsrcCtx := NewVersionedCtx(d1, v)\n\tvar dstCtx *VersionedCtx\n\tif d2 == nil {\n\t\td2 = d1\n\t\tdstCtx = srcCtx\n\t} else {\n\t\tdstCtx = NewVersionedCtx(d2, v)\n\t}\n\n\t// Send this instance's key-value pairs\n\tvar wg sync.WaitGroup\n\twg.Add(1)\n\n\tstats := new(txStats)\n\tstats.lastTime = time.Now()\n\tstats.name = fmt.Sprintf(\"copy of %s\", d1.DataName())\n\n\tvar kvTotal, kvSent int\n\tvar bytesTotal, bytesSent uint64\n\tkeysOnly := false\n\tif flatten {\n\t\t// Start goroutine to receive flattened key-value pairs and store them.\n\t\tch := make(chan *storage.TKeyValue, 1000)\n\t\tgo func() {\n\t\t\tfor {\n\t\t\t\ttkv := <-ch\n\t\t\t\tif tkv == nil {\n\t\t\t\t\twg.Done()\n\t\t\t\t\tdvid.Infof(\"Copied %d %q key-value pairs (%s, out of %d kv pairs, %s) [flattened]\\n\",\n\t\t\t\t\t\tkvSent, d1.DataName(), humanize.Bytes(bytesSent), kvTotal, humanize.Bytes(bytesTotal))\n\t\t\t\t\tstats.printStats()\n\t\t\t\t\treturn\n\t\t\t\t}\n\t\t\t\tkvTotal++\n\t\t\t\tcurBytes := uint64(len(tkv.V) + len(tkv.K))\n\t\t\t\tbytesTotal += curBytes\n\t\t\t\tif f != nil {\n\t\t\t\t\tskip, err := f.Check(tkv)\n\t\t\t\t\tif err != nil {\n\t\t\t\t\t\tdvid.Errorf(\"problem applying filter on data %q: %v\\n\", d1.DataName(), err)\n\t\t\t\t\t\tcontinue\n\t\t\t\t\t}\n\t\t\t\t\tif skip {\n\t\t\t\t\t\tcontinue\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tkvSent++\n\t\t\t\tbytesSent += curBytes\n\t\t\t\tif err := newKV.Put(dstCtx, tkv.K, tkv.V); err != nil {\n\t\t\t\t\tdvid.Errorf(\"can't put k/v pair to destination instance %q: %v\\n\", d2.DataName(), err)\n\t\t\t\t}\n\t\t\t\tstats.addKV(tkv.K, tkv.V)\n\t\t\t}\n\t\t}()\n\n\t\tbegKey, endKey := srcCtx.TKeyRange()\n\t\terr := oldKV.ProcessRange(srcCtx, begKey, endKey, &storage.ChunkOp{}, func(c *storage.Chunk) error {\n\t\t\tif c == nil {\n\t\t\t\treturn fmt.Errorf(\"received nil chunk in flatten push for data %s\", d1.DataName())\n\t\t\t}\n\t\t\tch <- c.TKeyValue\n\t\t\treturn nil\n\t\t})\n\t\tch <- nil\n\t\tif err != nil {\n\t\t\treturn fmt.Errorf(\"error in flatten push for data %q: %v\", d1.DataName(), err)\n\t\t}\n\t} else {\n\t\t// Start goroutine to receive all key-value pairs and store them.\n\t\tch := make(chan *storage.KeyValue, 1000)\n\t\tgo func() {\n\t\t\tfor {\n\t\t\t\tkv := <-ch\n\t\t\t\tif kv == nil {\n\t\t\t\t\twg.Done()\n\t\t\t\t\tdvid.Infof(\"Sent %d %q key-value pairs (%s, out of %d kv pairs, %s)\\n\",\n\t\t\t\t\t\tkvSent, d1.DataName(), humanize.Bytes(bytesSent), kvTotal, humanize.Bytes(bytesTotal))\n\t\t\t\t\tstats.printStats()\n\t\t\t\t\treturn\n\t\t\t\t}\n\t\t\t\ttkey, err := storage.TKeyFromKey(kv.K)\n\t\t\t\tif err != nil {\n\t\t\t\t\tdvid.Errorf(\"couldn't get %q TKey from Key %v: %v\\n\", d1.DataName(), kv.K, err)\n\t\t\t\t\tcontinue\n\t\t\t\t}\n\n\t\t\t\tkvTotal++\n\t\t\t\tcurBytes := uint64(len(kv.V) + len(kv.K))\n\t\t\t\tbytesTotal += curBytes\n\t\t\t\tif f != nil {\n\t\t\t\t\tskip, err := f.Check(&storage.TKeyValue{K: tkey, V: kv.V})\n\t\t\t\t\tif err != nil {\n\t\t\t\t\t\tdvid.Errorf(\"problem applying filter on data %q: %v\\n\", d1.DataName(), err)\n\t\t\t\t\t\tcontinue\n\t\t\t\t\t}\n\t\t\t\t\tif skip {\n\t\t\t\t\t\tcontinue\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tkvSent++\n\t\t\t\tbytesSent += curBytes\n\t\t\t\tif dstCtx != nil {\n\t\t\t\t\terr := dstCtx.UpdateInstance(kv.K)\n\t\t\t\t\tif err != nil {\n\t\t\t\t\t\tdvid.Errorf(\"can't update raw key to new data instance %q: %v\\n\", d2.DataName(), err)\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tif err := newKV.RawPut(kv.K, kv.V); err != nil {\n\t\t\t\t\tdvid.Errorf(\"can't put k/v pair to destination instance %q: %v\\n\", d2.DataName(), err)\n\t\t\t\t}\n\t\t\t\tstats.addKV(kv.K, kv.V)\n\t\t\t}\n\t\t}()\n\n\t\tbegKey, endKey := srcCtx.KeyRange()\n\t\tif err = oldKV.RawRangeQuery(begKey, endKey, keysOnly, ch, nil); err != nil {\n\t\t\treturn fmt.Errorf(\"push voxels %q range query: %v\", d1.DataName(), err)\n\t\t}\n\t}\n\twg.Wait()\n\treturn nil\n}", "func (d PacketData) MergeBuffer(b *buffer.Buffer) {\n\td.pk.buf.Merge(b)\n}", "func (q *Queue) transfer() {\n\tfor q.s1.Peek() != nil {\n\t\tq.s2.Push(q.s1.Pop())\n\t}\n}", "func putBufferMessageIntoReadStorage(s *server, ConnID int) {\n\tfor s.clientMap[ConnID].clientBufferQueue.Len() > 0 && s.clientMap[ConnID].clientSequenceMap == s.clientMap[ConnID].clientBufferQueue.Front().Value.(Message).SeqNum {\n\t\tfront := s.clientMap[ConnID].clientBufferQueue.Front()\n\t\ts.clientMap[ConnID].clientBufferQueue.Remove(front)\n\t\tmsg := front.Value.(Message)\n\t\ts.readStorage.PushBack(msg)\n\t\ts.clientMap[ConnID].clientSequenceMap = s.clientMap[ConnID].clientSequenceMap + 1\n\t}\n}", "func memcpy(dst, src unsafe.Pointer, size uintptr)", "func copyBuffer(dst io.Writer, src io.Reader, buf []byte) error {\n\tfor {\n\t\tnr, rerr := src.Read(buf)\n\t\tif nr > 0 {\n\t\t\tnw, werr := dst.Write(buf[:nr])\n\t\t\tif werr != nil {\n\t\t\t\treturn werr\n\t\t\t}\n\t\t\tif nr != nw {\n\t\t\t\treturn io.ErrShortWrite\n\t\t\t}\n\t\t}\n\t\tif rerr != nil {\n\t\t\tif rerr == io.EOF {\n\t\t\t\trerr = nil\n\t\t\t}\n\t\t\treturn rerr\n\t\t}\n\t}\n}", "func (s *syncMapInt64) copy(dst *syncMapInt64) {\n\tfor _, t := range s.keys() {\n\t\tdst.store(t, s.load(t))\n\t}\n}", "func (destination *streamDestination) copyAndResetBuffer() []byte {\n\tif len(destination.buffer) > 0 {\n\t\tmsg := make([]byte, len(destination.buffer))\n\t\tcopy(msg, destination.buffer)\n\n\t\tdestination.buffer = destination.buffer[:0]\n\t\treturn msg\n\t}\n\n\treturn []byte{}\n}", "func (b *Buffer) AttachBytes(buffer []byte, offset int, size int) {\n if len(buffer) < size {\n panic(\"invalid buffer\")\n }\n if size <= 0 {\n panic(\"invalid size\")\n }\n if offset > size {\n panic(\"invalid offset\")\n }\n\n b.data = buffer\n b.size = size\n b.offset = offset\n}", "func (bio *BinaryIO) Copy(dst int64, src int64, count int) error {\n\tbuf := makeBuf(count)\n\tfor count > 0 {\n\t\tbuf = truncBuf(buf, count)\n\t\tbio.ReadAt(src, buf)\n\t\tbio.WriteAt(dst, buf)\n\t\tcount -= len(buf)\n\t\tsrc += int64(len(buf))\n\t\tdst += int64(len(buf))\n\t}\n\treturn nil\n}", "func (h Handler) copyBuffer(dst io.Writer, src io.Reader, buf []byte) (int64, error) {\n\tif len(buf) == 0 {\n\t\tbuf = make([]byte, defaultBufferSize)\n\t}\n\tvar written int64\n\tfor {\n\t\tnr, rerr := src.Read(buf)\n\t\tif rerr != nil && rerr != io.EOF && rerr != context.Canceled {\n\t\t\t// TODO: this could be useful to know (indeed, it revealed an error in our\n\t\t\t// fastcgi PoC earlier; but it's this single error report here that necessitates\n\t\t\t// a function separate from io.CopyBuffer, since io.CopyBuffer does not distinguish\n\t\t\t// between read or write errors; in a reverse proxy situation, write errors are not\n\t\t\t// something we need to report to the client, but read errors are a problem on our\n\t\t\t// end for sure. so we need to decide what we want.)\n\t\t\t// p.logf(\"copyBuffer: ReverseProxy read error during body copy: %v\", rerr)\n\t\t\th.logger.Error(\"reading from backend\", zap.Error(rerr))\n\t\t}\n\t\tif nr > 0 {\n\t\t\tnw, werr := dst.Write(buf[:nr])\n\t\t\tif nw > 0 {\n\t\t\t\twritten += int64(nw)\n\t\t\t}\n\t\t\tif werr != nil {\n\t\t\t\treturn written, fmt.Errorf(\"writing: %w\", werr)\n\t\t\t}\n\t\t\tif nr != nw {\n\t\t\t\treturn written, io.ErrShortWrite\n\t\t\t}\n\t\t}\n\t\tif rerr != nil {\n\t\t\tif rerr == io.EOF {\n\t\t\t\treturn written, nil\n\t\t\t}\n\t\t\treturn written, fmt.Errorf(\"reading: %w\", rerr)\n\t\t}\n\t}\n}", "func copyStruct(dst *enigma, src *enigma) {\n\tdst.reflector = src.reflector\n\n\tdst.rings = make([]int, len(src.rings))\n\tcopy(dst.rings, src.rings)\n\n\tdst.positions = make([]string, len(src.positions))\n\tcopy(dst.positions, src.positions)\n\n\tdst.rotors = make([]string, len(src.rotors))\n\tcopy(dst.rotors, src.rotors)\n\n\tdst.plugboard = src.plugboard\n}", "func copyBuffer(dst io.Writer, src io.Reader, buf []byte) (written int64, err error) {\r\n\t// If the reader has a WriteTo method, use it to do the copy.\r\n\t// Avoids an allocation and a copy.\r\n\t// if wt, ok := src.(io.WriterTo); ok {\r\n\t// \treturn wt.WriteTo(dst)\r\n\t// }\r\n\r\n\t// Similarly, if the writer has a ReadFrom method, use it to do the copy.\r\n\t// if rt, ok := dst.(io.ReaderFrom); ok {\r\n\t// \treturn rt.ReadFrom(src)\r\n\t// }\r\n\r\n\tif buf == nil {\r\n\t\tbuf = make([]byte, 32*1024)\r\n\t\t//buf = make([]byte, 5*1024*1024)\r\n\t}\r\n\r\n\tfor {\r\n\t\tnr, er := src.Read(buf)\r\n\t\tif nr > 0 {\r\n\t\t\tnw, ew := dst.Write(buf[0:nr])\r\n\t\t\tif nw > 0 {\r\n\t\t\t\twritten += int64(nw)\r\n\t\t\t}\r\n\t\t\tif ew != nil {\r\n\t\t\t\terr = ew\r\n\t\t\t\tbreak\r\n\t\t\t}\r\n\t\t\tif nr != nw {\r\n\t\t\t\terr = io.ErrShortWrite\r\n\t\t\t\tbreak\r\n\t\t\t}\r\n\t\t}\r\n\t\tif er == io.EOF {\r\n\t\t\tbreak\r\n\t\t}\r\n\t\tif er != nil {\r\n\t\t\terr = er\r\n\t\t\tbreak\r\n\t\t}\r\n\t}\r\n\treturn written, err\r\n}", "func (s *Store) Copy() *Store {\n\ts.access.RLock()\n\tdefer s.access.RUnlock()\n\n\tcpy := NewStore()\n\tfor key, value := range s.data {\n\t\tcpy.data[key] = value\n\t}\n\treturn cpy\n}", "func (a DBFSAPI) Copy(src string, tgt string, client *DBApiClient, overwrite bool) error {\n\thandle, err := a.createHandle(tgt, overwrite)\n\tif err != nil {\n\t\treturn err\n\t}\n\tdefer func() {\n\t\terr = a.closeHandle(handle)\n\t}()\n\tfetchLoop := true\n\toffSet := int64(0)\n\tlength := int64(1e6)\n\tfor fetchLoop {\n\t\tvar api DBFSAPI\n\t\tif client == nil {\n\t\t\tapi = a\n\t\t} else {\n\t\t\tapi = client.DBFS()\n\t\t}\n\t\tbytesRead, b64String, err := api.ReadString(src, offSet, length)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tlog.Println(bytesRead)\n\t\tif bytesRead == 0 || bytesRead < length {\n\t\t\tfetchLoop = false\n\t\t}\n\n\t\terr = a.addBlock(b64String, handle)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\n\t\toffSet += length\n\t}\n\n\treturn err\n}", "func Copy(source KVStore, target KVStore) error {\n\n\tvar innerErr error\n\tif err := source.Iterate(EmptyPrefix, func(key, value Value) bool {\n\t\tif err := target.Set(key, value); err != nil {\n\t\t\tinnerErr = err\n\t\t}\n\n\t\treturn innerErr == nil\n\t}); err != nil {\n\t\treturn err\n\t}\n\n\tif innerErr != nil {\n\t\treturn innerErr\n\t}\n\n\treturn target.Flush()\n}", "func CopyMem(source uint64, dest uint64, size uint64)", "func deepcopy(dst, src interface{}) error {\n\tr, w, err := os.Pipe()\n\tif err != nil {\n\t\treturn err\n\t}\n\tenc := gob.NewEncoder(w)\n\terr = enc.Encode(src)\n\tif err != nil {\n\t\treturn err\n\t}\n\tdec := gob.NewDecoder(r)\n\treturn dec.Decode(dst)\n}", "func (driver *S3Driver) CopyBuffer(dst io.Writer, src io.Reader, buf []byte) (written int64, err error) {\r\n\tif buf != nil && len(buf) == 0 {\r\n\t\tpanic(\"empty buffer in io.CopyBuffer\")\r\n\t}\r\n\treturn copyBuffer(dst, src, buf)\r\n}", "func copyVersions(srcStore, dstStore dvid.Store, d1, d2 dvid.Data, uuids []dvid.UUID) error {\n\tif len(uuids) == 0 {\n\t\tdvid.Infof(\"no versions given for copy... aborting\\n\")\n\t\treturn nil\n\t}\n\tsrcDB, ok := srcStore.(rawQueryDB)\n\tif !ok {\n\t\treturn fmt.Errorf(\"source store %q doesn't have required raw range query\", srcStore)\n\t}\n\tdstDB, ok := dstStore.(rawPutDB)\n\tif !ok {\n\t\treturn fmt.Errorf(\"destination store %q doesn't have raw Put query\", dstStore)\n\t}\n\tvar dataInstanceChanged bool\n\tif d2 == nil {\n\t\td2 = d1\n\t} else {\n\t\tdataInstanceChanged = true\n\t}\n\tversionsOnPath, versionsToStore, err := calcVersionPath(uuids)\n\tif err != nil {\n\t\treturn err\n\t}\n\tvar wg sync.WaitGroup\n\twg.Add(1)\n\n\tstatsTotal := new(txStats)\n\tstatsTotal.lastTime = time.Now()\n\tstatsTotal.name = fmt.Sprintf(\"%q total\", d1.DataName())\n\tstatsStored := new(txStats)\n\tstatsStored.lastTime = time.Now()\n\tstatsStored.name = fmt.Sprintf(\"stored into %q\", d2.DataName())\n\tvar kvTotal, kvSent int\n\tvar bytesTotal, bytesSent uint64\n\n\t// Start goroutine to receive all key-value pairs, process, and store them.\n\trawCh := make(chan *storage.KeyValue, 5000)\n\tgo func() {\n\t\tvar maxVersionKey storage.Key\n\t\tvar numStoredKV int\n\t\tkvsToStore := make(map[dvid.VersionID]*storage.KeyValue, len(versionsToStore))\n\t\tfor _, v := range versionsToStore {\n\t\t\tkvsToStore[v] = nil\n\t\t}\n\t\tfor {\n\t\t\tkv := <-rawCh\n\t\t\tif kv != nil && !storage.Key(kv.K).IsDataKey() {\n\t\t\t\tdvid.Infof(\"Skipping non-data key-value %x ...\\n\", []byte(kv.K))\n\t\t\t\tcontinue\n\t\t\t}\n\t\t\tif kv == nil || maxVersionKey == nil || bytes.Compare(kv.K, maxVersionKey) > 0 {\n\t\t\t\tif numStoredKV > 0 {\n\t\t\t\t\tvar lastKV *storage.KeyValue\n\t\t\t\t\tfor _, v := range versionsToStore {\n\t\t\t\t\t\tcurKV := kvsToStore[v]\n\t\t\t\t\t\tif lastKV == nil || (curKV != nil && bytes.Compare(lastKV.V, curKV.V) != 0) {\n\t\t\t\t\t\t\tif curKV != nil {\n\t\t\t\t\t\t\t\tkeybuf := make(storage.Key, len(curKV.K))\n\t\t\t\t\t\t\t\tcopy(keybuf, curKV.K)\n\t\t\t\t\t\t\t\tif dataInstanceChanged {\n\t\t\t\t\t\t\t\t\terr = storage.ChangeDataKeyInstance(keybuf, d2.InstanceID())\n\t\t\t\t\t\t\t\t\tif err != nil {\n\t\t\t\t\t\t\t\t\t\tdvid.Errorf(\"could not change instance ID of key to %d: %v\\n\", d2.InstanceID(), err)\n\t\t\t\t\t\t\t\t\t\tcontinue\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\tstorage.ChangeDataKeyVersion(keybuf, v)\n\t\t\t\t\t\t\t\tkvSent++\n\t\t\t\t\t\t\t\tbytesSent += uint64(len(curKV.V) + len(keybuf))\n\t\t\t\t\t\t\t\tif err := dstDB.RawPut(keybuf, curKV.V); err != nil {\n\t\t\t\t\t\t\t\t\tdvid.Errorf(\"can't put k/v pair to destination instance %q: %v\\n\", d2.DataName(), err)\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\tstatsStored.addKV(keybuf, curKV.V)\n\t\t\t\t\t\t\t\tlastKV = curKV\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tif kv == nil {\n\t\t\t\t\twg.Done()\n\t\t\t\t\tdvid.Infof(\"Sent %d %q key-value pairs (%s, out of %d kv pairs, %s)\\n\",\n\t\t\t\t\t\tkvSent, d1.DataName(), humanize.Bytes(bytesSent), kvTotal, humanize.Bytes(bytesTotal))\n\t\t\t\t\tdvid.Infof(\"Total KV Stats for %q:\\n\", d1.DataName())\n\t\t\t\t\tstatsTotal.printStats()\n\t\t\t\t\tdvid.Infof(\"Total KV Stats for newly stored %q:\\n\", d2.DataName())\n\t\t\t\t\tstatsStored.printStats()\n\t\t\t\t\treturn\n\t\t\t\t}\n\t\t\t\ttk, err := storage.TKeyFromKey(kv.K)\n\t\t\t\tif err != nil {\n\t\t\t\t\tdvid.Errorf(\"couldn't get %q TKey from Key %v: %v\\n\", d1.DataName(), kv.K, err)\n\t\t\t\t\tcontinue\n\t\t\t\t}\n\t\t\t\tmaxVersionKey, err = storage.MaxVersionDataKey(d1.InstanceID(), tk)\n\t\t\t\tif err != nil {\n\t\t\t\t\tdvid.Errorf(\"couldn't get max version key from Key %v: %v\\n\", kv.K, err)\n\t\t\t\t\tcontinue\n\t\t\t\t}\n\t\t\t\tfor _, v := range versionsToStore {\n\t\t\t\t\tkvsToStore[v] = nil\n\t\t\t\t}\n\t\t\t\tnumStoredKV = 0\n\t\t\t}\n\t\t\tcurV, err := storage.VersionFromDataKey(kv.K)\n\t\t\tif err != nil {\n\t\t\t\tdvid.Errorf(\"unable to get version from key-value: %v\\n\", err)\n\t\t\t\tcontinue\n\t\t\t}\n\t\t\tcurBytes := uint64(len(kv.V) + len(kv.K))\n\t\t\tif _, onPath := versionsOnPath[curV]; onPath {\n\t\t\t\tfor _, v := range versionsToStore {\n\t\t\t\t\tif curV <= v {\n\t\t\t\t\t\tkvsToStore[v] = kv\n\t\t\t\t\t\tnumStoredKV++\n\t\t\t\t\t\tbreak\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tkvTotal++\n\t\t\tbytesTotal += curBytes\n\t\t\tstatsTotal.addKV(kv.K, kv.V)\n\t\t}\n\t}()\n\n\t// Send all kv pairs for the source data instance down the channel.\n\tbegKey, endKey := storage.DataInstanceKeyRange(d1.InstanceID())\n\tkeysOnly := false\n\tif err := srcDB.RawRangeQuery(begKey, endKey, keysOnly, rawCh, nil); err != nil {\n\t\treturn fmt.Errorf(\"push voxels %q range query: %v\", d1.DataName(), err)\n\t}\n\twg.Wait()\n\treturn nil\n}", "func (s *segment) merge(oth *segment) {\n\ts.pkt.Data().Merge(oth.pkt.Data())\n\ts.dataMemSize = s.pkt.MemSize()\n\toth.dataMemSize = oth.pkt.MemSize()\n}", "func (p *movingAverageProcessor) addBufferData(index int, data interface{}, namespace string) error {\n\tif _, ok := p.movingAverageMap[namespace]; ok {\n\t\tif index >= len(p.movingAverageMap[namespace].movingAverageBuf) {\n\t\t\treturn errors.New(\"Incorrect value of index, trying to access non-existing element of buffer\")\n\t\t}\n\t\tp.movingAverageMap[namespace].movingAverageBuf[index] = data\n\t\treturn nil\n\t} else {\n\t\treturn errors.New(\"Namespace is not present in the map\")\n\t}\n}", "func ioTransferData(env *Env, conn1, conn2 io.ReadWriteCloser) {\n\tpairs := []struct{ dst, src io.ReadWriteCloser }{{conn1, conn2}, {conn2, conn1}}\n\tfor _, p := range pairs {\n\t\tgo func(src, dst io.ReadWriteCloser) {\n\t\t\tio.Copy(dst, src)\n\t\t\tdst.Close()\n\t\t}(p.src, p.dst)\n\t}\n}", "func (allc *Allocator) putBytesTo(offset uint32, val []byte) {\n\tcopy(allc.mem[offset:], val)\n}", "func copyBuffer(dst io.Writer, src io.Reader, buf []byte) (written int64, err error) {\n\tif buf == nil {\n\t\tbuf = make([]byte, 32*1024)\n\t}\n\tfor {\n\t\tnr, er := src.Read(buf)\n\t\tif nr > 0 {\n\t\t\tnw, ew := dst.Write(buf[0:nr])\n\t\t\tif nw > 0 {\n\t\t\t\twritten += int64(nw)\n\t\t\t}\n\t\t\tif ew != nil {\n\t\t\t\terr = ew\n\t\t\t\tbreak\n\t\t\t}\n\t\t\tif nr != nw {\n\t\t\t\terr = io.ErrShortWrite\n\t\t\t\tbreak\n\t\t\t}\n\t\t}\n\t\tif er == io.EOF {\n\t\t\tbreak\n\t\t}\n\t\tif er != nil {\n\t\t\terr = er\n\t\t\tbreak\n\t\t}\n\t}\n\treturn written, err\n}", "func copyToLocation(location uintptr, data []byte) {\n\tf := rawMemoryAccess(location, len(data))\n\n\tmprotectCrossPage(location, len(data), syscall.PROT_READ|syscall.PROT_WRITE|syscall.PROT_EXEC)\n\tcopy(f, data[:])\n\tfmt.Printf(\"copy bytes len:%d, %s\\n\", len(data), hex.EncodeToString(data))\n\tmprotectCrossPage(location, len(data), syscall.PROT_READ|syscall.PROT_EXEC)\n}", "func CopyNamedBufferSubData(readBuffer uint32, writeBuffer uint32, readOffset int, writeOffset int, size int) {\n\tC.glowCopyNamedBufferSubData(gpCopyNamedBufferSubData, (C.GLuint)(readBuffer), (C.GLuint)(writeBuffer), (C.GLintptr)(readOffset), (C.GLintptr)(writeOffset), (C.GLsizeiptr)(size))\n}", "func CopyNamedBufferSubData(readBuffer uint32, writeBuffer uint32, readOffset int, writeOffset int, size int) {\n\tC.glowCopyNamedBufferSubData(gpCopyNamedBufferSubData, (C.GLuint)(readBuffer), (C.GLuint)(writeBuffer), (C.GLintptr)(readOffset), (C.GLintptr)(writeOffset), (C.GLsizeiptr)(size))\n}", "func makeslicecopy(et *_type, tolen int, fromlen int, from unsafe.Pointer) unsafe.Pointer {\n\tvar tomem, copymem uintptr\n\tif uintptr(tolen) > uintptr(fromlen) {\n\t\tvar overflow bool\n\t\ttomem, overflow = math.MulUintptr(et.size, uintptr(tolen))\n\t\tif overflow || tomem > maxAlloc || tolen < 0 {\n\t\t\tpanicmakeslicelen()\n\t\t}\n\t\tcopymem = et.size * uintptr(fromlen)\n\t} else {\n\t\t// fromlen is a known good length providing and equal or greater than tolen,\n\t\t// thereby making tolen a good slice length too as from and to slices have the\n\t\t// same element width.\n\t\ttomem = et.size * uintptr(tolen)\n\t\tcopymem = tomem\n\t}\n\n\tvar to unsafe.Pointer\n\tif et.ptrdata == 0 {\n\t\tto = mallocgc(tomem, nil, false)\n\t\tif copymem < tomem {\n\t\t\tmemclrNoHeapPointers(add(to, copymem), tomem-copymem)\n\t\t}\n\t} else {\n\t\t// Note: can't use rawmem (which avoids zeroing of memory), because then GC can scan uninitialized memory.\n\t\tto = mallocgc(tomem, et, true)\n\t\tif copymem > 0 && writeBarrier.enabled {\n\t\t\t// Only shade the pointers in old.array since we know the destination slice to\n\t\t\t// only contains nil pointers because it has been cleared during alloc.\n\t\t\tbulkBarrierPreWriteSrcOnly(uintptr(to), uintptr(from), copymem)\n\t\t}\n\t}\n\n\tif raceenabled {\n\t\tcallerpc := getcallerpc()\n\t\tpc := funcPC(makeslicecopy)\n\t\tracereadrangepc(from, copymem, callerpc, pc)\n\t}\n\tif msanenabled {\n\t\tmsanread(from, copymem)\n\t}\n\n\tmemmove(to, from, copymem)\n\n\treturn to\n}", "func (t Treasure) Mutate(b []byte) error {\n\taddr, data := t.RealAddr(), t.Bytes()\n\tfor i := 0; i < 4; i++ {\n\t\tb[addr+i] = data[i]\n\t}\n\treturn nil\n}", "func BufferStorage(target uint32, size int, data unsafe.Pointer, flags uint32) {\n\tsyscall.Syscall6(gpBufferStorage, 4, uintptr(target), uintptr(size), uintptr(data), uintptr(flags), 0, 0)\n}", "func copyBuffer(dst io.Writer, src io.Reader, buf []byte) (written int64, err error) {\n\n\tfor {\n\t\tnr, er := src.Read(buf)\n\n\t\t// break on any read error (and also on EOF)\n\t\tif er != nil {\n\t\t\terr = er\n\t\t\tbreak\n\t\t}\n\n\t\tif nr > 0 {\n\t\t\tnw, ew := dst.Write(buf[0:nr])\n\t\t\tif nw > 0 {\n\t\t\t\twritten += int64(nw)\n\t\t\t}\n\t\t\tif ew != nil {\n\t\t\t\terr = ew\n\t\t\t\tbreak\n\t\t\t}\n\t\t\tif nr != nw {\n\t\t\t\terr = io.ErrShortWrite\n\t\t\t\tbreak\n\t\t\t}\n\t\t}\n\n\t}\n\treturn written, err\n}", "func copyNonZeroFrom(src, dst *storeSnap) {\n\tif len(src.Architectures) > 0 {\n\t\tdst.Architectures = src.Architectures\n\t}\n\tif src.Base != \"\" {\n\t\tdst.Base = src.Base\n\t}\n\tif src.Confinement != \"\" {\n\t\tdst.Confinement = src.Confinement\n\t}\n\tif src.Contact != \"\" {\n\t\tdst.Contact = src.Contact\n\t}\n\tif src.CreatedAt != \"\" {\n\t\tdst.CreatedAt = src.CreatedAt\n\t}\n\tif src.Description.Clean() != \"\" {\n\t\tdst.Description = src.Description\n\t}\n\tif src.Download.URL != \"\" {\n\t\tdst.Download = src.Download\n\t}\n\tif src.Epoch.String() != \"0\" {\n\t\tdst.Epoch = src.Epoch\n\t}\n\tif src.License != \"\" {\n\t\tdst.License = src.License\n\t}\n\tif src.Name != \"\" {\n\t\tdst.Name = src.Name\n\t}\n\tif len(src.Prices) > 0 {\n\t\tdst.Prices = src.Prices\n\t}\n\tif src.Private {\n\t\tdst.Private = src.Private\n\t}\n\tif src.Publisher.ID != \"\" {\n\t\tdst.Publisher = src.Publisher\n\t}\n\tif src.Revision > 0 {\n\t\tdst.Revision = src.Revision\n\t}\n\tif src.SnapID != \"\" {\n\t\tdst.SnapID = src.SnapID\n\t}\n\tif src.SnapYAML != \"\" {\n\t\tdst.SnapYAML = src.SnapYAML\n\t}\n\tif src.Summary.Clean() != \"\" {\n\t\tdst.Summary = src.Summary\n\t}\n\tif src.Title.Clean() != \"\" {\n\t\tdst.Title = src.Title\n\t}\n\tif src.Type != \"\" {\n\t\tdst.Type = src.Type\n\t}\n\tif src.Version != \"\" {\n\t\tdst.Version = src.Version\n\t}\n\tif len(src.Media) > 0 {\n\t\tdst.Media = src.Media\n\t}\n\tif len(src.CommonIDs) > 0 {\n\t\tdst.CommonIDs = src.CommonIDs\n\t}\n}", "func putBuffer(buf *bytes.Buffer) {\n\tbuf.Reset()\n\tbufferPool.Put(buf)\n}", "func (e *genericEncoder) CloneWithBuffer(buf *buffer.Buffer) *genericEncoder {\n\treturn &genericEncoder{\n\t\tEncoderConfig: e.EncoderConfig,\n\t\tbuf: buf,\n\t\tformatTime: e.formatTime,\n\t}\n}", "func (store *Store) append(buf []byte) error {\n\t// append data uncommitted\n\t_, err := store.dataFile.Seek(store.ptr, 0)\n\tif err != nil {\n\t\treturn err\n\t}\n\tif _, err = store.dataFile.Write(buf); err != nil {\n\t\treturn err\n\t}\n\tnewptr, err := store.dataFile.Seek(0, 1)\n\tif err != nil {\n\t\treturn err\n\t}\n\n\t// start committing header\n\tif _, err = store.dataFile.Seek(0, 0); err != nil {\n\t\treturn err\n\t}\n\ttmp := [8]byte{}\n\tif _, err = store.dataFile.Read(tmp[:]); err != nil {\n\t\treturn err\n\t}\n\tflag := tmp[3]\n\tbinary.BigEndian.PutUint64(tmp[:], uint64(newptr))\n\n\tif flag == 0 {\n\t\tflag = 1\n\t\t_, err = store.dataFile.Seek(10, 0)\n\t} else {\n\t\tflag = 0\n\t\t_, err = store.dataFile.Seek(4, 0)\n\t}\n\tif err != nil {\n\t\treturn err\n\t}\n\n\tif _, err = store.dataFile.Write(tmp[2:]); err != nil {\n\t\treturn err\n\t}\n\tif _, err = store.dataFile.Seek(3, 0); err != nil {\n\t\treturn err\n\t}\n\tif _, err = store.dataFile.Write([]byte{flag}); err != nil {\n\t\treturn err\n\t}\n\n\t// all clear\n\tstore.ptr = newptr\n\treturn nil\n}", "func (adabasBuffer *Buffer) putCAbd(pabdArray *C.PABD, index int) {\n\tadatypes.Central.Log.Debugf(\"%d: receive index %c len=%d\", index, adabasBuffer.abd.Abdid, len(adabasBuffer.buffer))\n\tvar pbuffer *C.char\n\tadatypes.Central.Log.Debugf(\"Got buffer len=%d\", adabasBuffer.abd.Abdsize)\n\tif adabasBuffer.abd.Abdsize == 0 {\n\t\tpbuffer = nil\n\t} else {\n\t\tpbuffer = (*C.char)(unsafe.Pointer(&adabasBuffer.buffer[0]))\n\t}\n\tcabd := adabasBuffer.abd\n\tvar pabd C.PABD\n\tpabd = (C.PABD)(unsafe.Pointer(&cabd))\n\n\tadatypes.Central.Log.Debugf(\"Work on %c. buffer of size=%d\", cabd.Abdid, len(adabasBuffer.buffer))\n\tC.copy_from_abd(pabdArray, C.int(index), pabd,\n\t\tpbuffer, C.uint32_t(uint32(adabasBuffer.abd.Abdsize)))\n\tadabasBuffer.abd = cabd\n\tif adatypes.Central.IsDebugLevel() {\n\t\tadatypes.Central.Log.Debugf(\"C ABD %c: send=%d recv=%d\", cabd.Abdid, cabd.Abdsend, cabd.Abdrecv)\n\t\tadatypes.LogMultiLineString(true, adatypes.FormatByteBuffer(\"Buffer content:\", adabasBuffer.buffer))\n\t}\n\n}", "func copyToLocation(location uintptr, data []byte) {\n\tf := rawMemoryAccess(location, len(data))\n\n\tmprotectCrossPage(location, len(data), syscall.PROT_READ|syscall.PROT_WRITE|syscall.PROT_EXEC)\n\tcopy(f, data[:])\n\tmprotectCrossPage(location, len(data), syscall.PROT_READ|syscall.PROT_EXEC)\n}", "func (b *mpgBuff) buffer() *concBuff {\n\tif !b.cur {\n\t\treturn b.bufA\n\t}\n\treturn b.bufB\n}", "func (vm *VM) bufferPush(data string) {\n\tnewBuffer := &buffer{\n\t\tprevious: vm.buffer,\n\t\tvalue: data,\n\t}\n\tvm.buffer = newBuffer\n}", "func BufferSubData(target uint32, offset int, size int, data unsafe.Pointer) {\n\tsyscall.Syscall6(gpBufferSubData, 4, uintptr(target), uintptr(offset), uintptr(size), uintptr(data), 0, 0)\n}", "func (o *txSocketQueue) copyToHead(buf []byte) uint32 {\n\tm := o.getOrAllocIndex(&o.head)\n\tfree := o.head.getFree()\n\tz := uint16(minSpace(free, uint32(len(buf))))\n\tm.Append(buf[:z])\n\to.head.Inc(z, o.refSize)\n\treturn uint32(z)\n}", "func (bw *BufferedWriterMongo) writeBuffer() (err error) {\n\n\tif len(bw.buffer) == 0 {\n\t\treturn nil\n\t}\n\n\tcoll := bw.client.Database(bw.db).Collection(bw.collection)\n\t_, err = coll.InsertMany(bw.ctx, bw.buffer)\n\treturn err\n}", "func copyTo(dst []byte, src []byte, offset int) {\n\tfor j, k := range src {\n\t\tdst[offset+j] = k\n\t}\n}", "func Clone(source, destination interface{}) {\n\tif reflect.TypeOf(destination).Kind() != reflect.Ptr {\n\t\tlog.Error(\"storage_drivers.Clone, destination parameter must be a pointer\")\n\t}\n\n\tbuff := new(bytes.Buffer)\n\tenc := gob.NewEncoder(buff)\n\tdec := gob.NewDecoder(buff)\n\tenc.Encode(source)\n\tdec.Decode(destination)\n}", "func (r *Resources) Copy(other *Resources) {\n\tr.CPU = other.CPU\n\tr.DISK = other.DISK\n\tr.MEMORY = other.MEMORY\n\tr.GPU = other.GPU\n}", "func (b *Backend) demote(key fes.Aggregate) {\n\tevents, ok, fromStore := b.get(key)\n\tif !ok || !fromStore {\n\t\treturn\n\t}\n\tdelete(b.store, key)\n\tb.buf.Add(key, events)\n}", "func TestCopy(t *testing.T) {\n\t// Create a random state test to copy and modify \"independently\"\n\torig, _ := New(types.Hash32{}, NewDatabase(database.NewMemDatabase()))\n\n\tfor i := byte(0); i < 255; i++ {\n\t\tobj := orig.GetOrNewStateObj(types.BytesToAddress([]byte{i}))\n\t\tobj.AddBalance(uint64(i))\n\t\torig.updateStateObj(obj)\n\t}\n\n\t// Copy the state, modify both in-memory\n\tcopy := orig.Copy()\n\n\tfor i := byte(0); i < 255; i++ {\n\t\torigObj := orig.GetOrNewStateObj(types.BytesToAddress([]byte{i}))\n\t\tcopyObj := copy.GetOrNewStateObj(types.BytesToAddress([]byte{i}))\n\n\t\torigObj.AddBalance(2 * uint64(i))\n\t\tcopyObj.AddBalance(3 * uint64(i))\n\n\t\torig.updateStateObj(origObj)\n\t\tcopy.updateStateObj(copyObj)\n\t}\n\t// Finalise the changes on both concurrently\n\tdone := make(chan struct{})\n\tgo func() {\n\t\tclose(done)\n\t}()\n\t<-done\n\n\t// Verify that the two states have been updated independently\n\tfor i := byte(0); i < 255; i++ {\n\t\torigObj := orig.GetOrNewStateObj(types.BytesToAddress([]byte{i}))\n\t\tcopyObj := copy.GetOrNewStateObj(types.BytesToAddress([]byte{i}))\n\n\t\tif want := (3 * uint64(i)); origObj.Balance() != want {\n\t\t\tt.Errorf(\"orig obj %d: balance mismatch: have %v, want %v\", i, origObj.Balance(), want)\n\t\t}\n\t\tif want := (4 * uint64(i)); copyObj.Balance() != want {\n\t\t\tt.Errorf(\"copy obj %d: balance mismatch: have %v, want %v\", i, copyObj.Balance(), want)\n\t\t}\n\t}\n}", "func (b *RecordBuffer) Flush() {\n\tb.recordsInBuffer = b.recordsInBuffer[:0]\n\tb.sequencesInBuffer = b.sequencesInBuffer[:0]\n}", "func (pk PacketBuffer) Clone() PacketBuffer {\n\tpk.Data = pk.Data.Clone(nil)\n\treturn pk\n}", "func (_ BufferPtrPool2M) Put(b *[]byte) {\n\tPutBytesSlicePtr2M(b)\n}", "func (rb *RingBuffer) Clone() *RingBuffer {\n\trb.lock.RLock()\n\tdefer rb.lock.RUnlock()\n\tcp := make([]stats.Record, len(rb.data))\n\tcopy(cp, rb.data)\n\treturn &RingBuffer{seq: rb.seq, data: cp}\n}", "func (ms *MemStore) SetAll(data map[string]io.WriterTo) error {\n\tvar err error\n\tms.mu.Lock()\n\tfor k, d := range data {\n\t\tvar buf memio.Buffer\n\t\tif _, err = d.WriteTo(&buf); err != nil {\n\t\t\tbreak\n\t\t}\n\t\tms.data[k] = buf\n\t}\n\tms.mu.Unlock()\n\treturn err\n}", "func (src *Source) SetBuffer(buf []byte) {\n\tsrc.buf = buf\n}", "func storeDiffData(dbContext dbaccess.Context, w *bytes.Buffer, hash *daghash.Hash, diffData *blockUTXODiffData) error {\n\t// To avoid a ton of allocs, use the io.Writer\n\t// instead of allocating one. We expect the buffer to\n\t// already be initialized and, in most cases, to already\n\t// be large enough to accommodate the serialized data\n\t// without growing.\n\terr := serializeBlockUTXODiffData(w, diffData)\n\tif err != nil {\n\t\treturn err\n\t}\n\n\treturn dbaccess.StoreUTXODiffData(dbContext, hash, w.Bytes())\n}", "func CopyObject(srcData []byte, dst interface{}) {\n\tjsoniter.Unmarshal(srcData, dst)\n\t//var dstData, err = jsoniter.Marshal(dst)\n\t//if err != nil {\n\t//\tpanic(err)\n\t//}\n\t//fmt.Println(\"overlay:\", string(dstData))\n}", "func (m *meta) copy(dest *meta) {\n\t*dest = *m\n}", "func (m *meta) copy(dest *meta) {\n\t*dest = *m\n}", "func (m *meta) copy(dest *meta) {\n\t*dest = *m\n}", "func (d *state) copyOut(b []byte) {\n\tfor i := 0; len(b) >= 8; i++ {\n\t\tbinary.LittleEndian.PutUint64(b, d.a[i])\n\t\tb = b[8:]\n\t}\n}", "func (s SafeBuffer) Copy() payload.Safe {\n\tbin := make([]byte, s.Len())\n\tcopy(bin, s.Bytes())\n\n\tb := bytes.NewBuffer(bin)\n\treturn SafeBuffer{*b}\n}", "func deepCopy(copy, orig interface{}) error {\n\tvar buf bytes.Buffer\n\tenc := gob.NewEncoder(&buf)\n\tdec := gob.NewDecoder(&buf)\n\terr := enc.Encode(orig)\n\tif err != nil {\n\t\treturn err\n\t}\n\treturn dec.Decode(copy)\n}", "func (b *Buffer) Attach(buffer []byte) {\n b.AttachBytes(buffer, 0, len(buffer))\n}", "func (b *Buffer) Merge(bs ...Buffer) {\n\tfor _, buf := range bs {\n\t\tfor p, v := range buf.CellMap {\n\t\t\tb.Set(p.X, p.Y, v)\n\t\t}\n\t\tb.SetArea(b.Area.Union(buf.Area))\n\t}\n}", "func (s *ManagerStats) AtomicCopyTo(r *ManagerStats) {\n\trve := reflect.ValueOf(r).Elem()\n\tsve := reflect.ValueOf(s).Elem()\n\tsvet := sve.Type()\n\tfor i := 0; i < svet.NumField(); i++ {\n\t\trvef := rve.Field(i)\n\t\tsvef := sve.Field(i)\n\t\tif rvef.CanAddr() && svef.CanAddr() {\n\t\t\trvefp := rvef.Addr().Interface()\n\t\t\tsvefp := svef.Addr().Interface()\n\t\t\tatomic.StoreUint64(rvefp.(*uint64),\n\t\t\t\tatomic.LoadUint64(svefp.(*uint64)))\n\t\t}\n\t}\n}", "func (bp *bufferPool) putBuffer(b *buffer) {\n\tbp.lock.Lock()\n\tif bp.freeBufNum < 1000 {\n\t\tb.next = bp.freeList\n\t\tbp.freeList = b\n\t\tbp.freeBufNum++\n\t}\n\tbp.lock.Unlock()\n}", "func (c *Counter) Transfer(src *Counter) {\n\tif src.Count == 0 {\n\t\treturn // nothing to do\n\t}\n\tif c.Count == 0 {\n\t\t*c = *src // copy everything at once\n\t\tsrc.Reset()\n\t\treturn\n\t}\n\tc.Count += src.Count\n\tif src.Min < c.Min {\n\t\tc.Min = src.Min\n\t}\n\tif src.Max > c.Max {\n\t\tc.Max = src.Max\n\t}\n\tc.Sum += src.Sum\n\tc.sumOfSquares += src.sumOfSquares\n\tsrc.Reset()\n}", "func XorBuffer(first []byte, second []byte) ([]byte, error) {\n\tif len(first) != len(second) {\n\t\treturn nil, errors.New(\"Buffers are not equal length\")\n\t}\n\n\toutput := make([]byte, len(first))\n\n\tfor idx := range first {\n\t\t// XOR operation\n\t\toutput[idx] = first[idx] ^ second[idx]\n\t}\n\n\treturn output, nil\n}", "func (t *translator) copyBytes(\n\tirBlock *ir.Block, irPtr, irLen irvalue.Value,\n) irvalue.Value {\n\tirNewPtr := irBlock.NewCall(t.builtins.Malloc(t), irLen)\n\tirBlock.NewCall(t.builtins.Memcpy(t), irNewPtr, irPtr, irLen, irconstant.False)\n\treturn irNewPtr\n}", "func (d *DataPacket) copy() DataPacket {\n\tcopySlice := make([]byte, len(d.data))\n\tcopy(copySlice, d.data)\n\treturn DataPacket{\n\t\tdata: copySlice,\n\t\tlength: d.length,\n\t}\n}", "func (_ BufferPtrPool2K) Put(b *[]byte) {\n\tPutBytesSlicePtr2K(b)\n}", "func (o *txSocketQueue) copyFromTail(p *queuePtr, size uint32, tobuf []byte, boffset uint32) uint32 {\n\tm := o.getIndex(p)\n\tfree := p.getFree()\n\tz := uint16(minSpace(free, size))\n\tof := o.tail.getRelativeOffset(p)\n\tcopy(tobuf[boffset:boffset+uint32(z)], m.GetData()[of:of+z])\n\tp.Inc(z, o.refSize)\n\treturn uint32(z)\n}", "func Copy(dst, src interface{}) error {\n\tbuffer := new(bytes.Buffer)\n\tencoder := gob.NewEncoder(buffer)\n\tif err := encoder.Encode(src); err != nil {\n\t\treturn err\n\t}\n\tdecoder := gob.NewDecoder(buffer)\n\terr := decoder.Decode(dst)\n\treturn err\n}", "func (p *movingAverageProcessor) getBufferData(index int, namespace string) interface{} {\n\n\treturn p.movingAverageMap[namespace].movingAverageBuf[index]\n}", "func (keyRing *KeyRing) Copy() (*KeyRing, error) {\n\tnewKeyRing := &KeyRing{}\n\n\tentities := make([]*openpgp.Entity, len(keyRing.entities))\n\tfor id, entity := range keyRing.entities {\n\t\tvar buffer bytes.Buffer\n\t\tvar err error\n\n\t\tif entity.PrivateKey == nil {\n\t\t\terr = entity.Serialize(&buffer)\n\t\t} else {\n\t\t\terr = entity.SerializePrivateWithoutSigning(&buffer, nil)\n\t\t}\n\n\t\tif err != nil {\n\t\t\treturn nil, errors.Wrap(err, \"gopenpgp: unable to copy key: error in serializing entity\")\n\t\t}\n\n\t\tbt := buffer.Bytes()\n\t\tentities[id], err = openpgp.ReadEntity(packet.NewReader(bytes.NewReader(bt)))\n\n\t\tif err != nil {\n\t\t\treturn nil, errors.Wrap(err, \"gopenpgp: unable to copy key: error in reading entity\")\n\t\t}\n\t}\n\tnewKeyRing.entities = entities\n\tnewKeyRing.FirstKeyID = keyRing.FirstKeyID\n\n\treturn newKeyRing, nil\n}", "func (b *buffer) buffer() []byte {\n\treturn b.buf[b.offset:]\n}", "func (_ BufferPtrPool1M) Put(b *[]byte) {\n\tPutBytesSlicePtr1M(b)\n}", "func (s *CollectionStats) AtomicCopyTo(r *CollectionStats) {\n\trve := reflect.ValueOf(r).Elem()\n\tsve := reflect.ValueOf(s).Elem()\n\tsvet := sve.Type()\n\tfor i := 0; i < svet.NumField(); i++ {\n\t\trvef := rve.Field(i)\n\t\tsvef := sve.Field(i)\n\t\tif rvef.CanAddr() && svef.CanAddr() {\n\t\t\trvefp := rvef.Addr().Interface()\n\t\t\tsvefp := svef.Addr().Interface()\n\t\t\tatomic.StoreUint64(rvefp.(*uint64),\n\t\t\t\tatomic.LoadUint64(svefp.(*uint64)))\n\t\t}\n\t}\n}", "func (self Source) SetBuffer(buffer Buffer) {\n\tself.Seti(AlBuffer, int32(buffer))\n}", "func (g *GLTF) loadBuffer(bufIdx int) ([]byte, error) {\n\n\t// Check if provided buffer index is valid\n\tif bufIdx < 0 || bufIdx >= len(g.Buffers) {\n\t\treturn nil, fmt.Errorf(\"invalid buffer index\")\n\t}\n\tbufData := &g.Buffers[bufIdx]\n\t// Return cached if available\n\tif bufData.cache != nil {\n\t\tlog.Debug(\"Fetching Buffer %d (cached)\", bufIdx)\n\t\treturn bufData.cache, nil\n\t}\n\tlog.Debug(\"Loading Buffer %d\", bufIdx)\n\n\t// If buffer URI use the chunk data field\n\tif bufData.Uri == \"\" {\n\t\treturn g.data, nil\n\t}\n\n\t// Checks if buffer URI is a data URI\n\tvar data []byte\n\tvar err error\n\tif isDataURL(bufData.Uri) {\n\t\tdata, err = loadDataURL(bufData.Uri)\n\t} else {\n\t\t// Try to load buffer from file\n\t\tdata, err = g.loadFileBytes(bufData.Uri)\n\t}\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\n\t// Checks data length\n\tif len(data) != bufData.ByteLength {\n\t\treturn nil, fmt.Errorf(\"buffer:%d read data length:%d expected:%d\", bufIdx, len(data), bufData.ByteLength)\n\t}\n\t// Cache buffer data\n\tg.Buffers[bufIdx].cache = data\n\tlog.Debug(\"cache data:%v\", len(bufData.cache))\n\treturn data, nil\n}", "func (al *AudioListener) setBuffer(size int) {\n\tal.Lock()\n\tdefer al.Unlock()\n\n\tal.buffer = make([]gumble.AudioPacket, 0, size)\n}", "func TestDataCopy(t *testing.T) {\n\tb := bytes.Buffer{}\n\tw := NewWriter(&b)\n\tbuf := make([]byte, 8) // can only write 8 bytes at a time\n\n\terr := w.Open(\"[email protected]\", time.Now())\n\tif err != nil {\n\t\tt.Error(err)\n\t}\n\t// wrap in an anonymous struct so that WriteTo is not called. That way buf will get used\n\t_, err = io.CopyBuffer(struct{ io.Writer }{w}, struct{ io.Reader }{bytes.NewReader([]byte(test2))}, buf)\n\tif err != nil {\n\t\tt.Error(err)\n\t}\n\terr = w.Close()\n\tif err != nil {\n\t\tt.Error(err)\n\t}\n\tresult := b.String()\n\tif result[len(result)-1] != '\\n' {\n\t\tt.Error(\"expecting a new line at the end\")\n\t}\n}", "func (g *Gaffer) AddBuffer(u *Update) {\n\n\tfor _, v := range u.entities {\n\t\tg.AddEntity(v)\n\t}\n\n\tfor _, v := range u.edges {\n\t\tg.AddEdge(v)\n\t}\n\n}", "func AssignBuf(dst, src any, buf AccumulativeBuffer) (ok bool) {\n\tfor _, fn := range assignFnRegistry {\n\t\tif ok = fn(dst, src, buf); ok {\n\t\t\treturn\n\t\t}\n\t}\n\treturn\n}", "func (w *Writer) SetBuffer(raw []byte) {\n\tif w.err != nil {\n\t\treturn\n\t}\n\tw.b = w.b[:0]\n\tw.b = append(w.b, raw...)\n}", "func (t treasure) mutate(b []byte) {\n\t// fake treasure\n\tif t.addr.offset == 0 {\n\t\treturn\n\t}\n\n\taddr, data := t.addr.fullOffset(), t.bytes()\n\tfor i := 0; i < 4; i++ {\n\t\tb[addr+i] = data[i]\n\t}\n}", "func MemCopy(dst unsafe.Pointer, src unsafe.Pointer, bytes int) {\n\tfor i := 0; i < bytes; i++ {\n\t\t*(*uint8)(MemAccess(dst, i)) = *(*uint8)(MemAccess(src, i))\n\t}\n}", "func (z *Writer) newBuffers() {\n\tbSize := z.Header.BlockMaxSize\n\tbuf := getBuffer(bSize)\n\tz.data = buf[:bSize] // Uncompressed buffer is the first half.\n}", "func copyContentsLocked(ctx context.Context, upper *Inode, lower *Inode, size int64) error {\n\t// We don't support copying up for anything other than regular files.\n\tif lower.StableAttr.Type != RegularFile {\n\t\treturn nil\n\t}\n\n\t// Get a handle to the upper filesystem, which we will write to.\n\tupperFile, err := overlayFile(ctx, upper, FileFlags{Write: true})\n\tif err != nil {\n\t\treturn err\n\t}\n\tdefer upperFile.DecRef()\n\n\t// Get a handle to the lower filesystem, which we will read from.\n\tlowerFile, err := overlayFile(ctx, lower, FileFlags{Read: true})\n\tif err != nil {\n\t\treturn err\n\t}\n\tdefer lowerFile.DecRef()\n\n\t// Use a buffer pool to minimize allocations.\n\tbuf := copyUpBuffers.Get().([]byte)\n\tdefer copyUpBuffers.Put(buf)\n\n\t// Transfer the contents.\n\t//\n\t// One might be able to optimize this by doing parallel reads, parallel writes and reads, larger\n\t// buffers, etc. But we really don't know anything about the underlying implementation, so these\n\t// optimizations could be self-defeating. So we leave this as simple as possible.\n\tvar offset int64\n\tfor {\n\t\tnr, err := lowerFile.FileOperations.Read(ctx, lowerFile, usermem.BytesIOSequence(buf), offset)\n\t\tif err != nil && err != io.EOF {\n\t\t\treturn err\n\t\t}\n\t\tif nr == 0 {\n\t\t\tif offset != size {\n\t\t\t\t// Same as in cleanupUpper, we cannot live\n\t\t\t\t// with ourselves if we do anything less.\n\t\t\t\tpanic(fmt.Sprintf(\"filesystem is in an inconsistent state: wrote only %d bytes of %d sized file\", offset, size))\n\t\t\t}\n\t\t\treturn nil\n\t\t}\n\t\tnw, err := upperFile.FileOperations.Write(ctx, upperFile, usermem.BytesIOSequence(buf[:nr]), offset)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\toffset += nw\n\t}\n}", "func (pk PacketBufferPtr) DeepCopyForForwarding(reservedHeaderBytes int) PacketBufferPtr {\n\tpayload := BufferSince(pk.NetworkHeader())\n\tdefer payload.Release()\n\tnewPk := NewPacketBuffer(PacketBufferOptions{\n\t\tReserveHeaderBytes: reservedHeaderBytes,\n\t\tPayload: payload.DeepClone(),\n\t\tIsForwardedPacket: true,\n\t})\n\n\t{\n\t\tconsumeBytes := len(pk.NetworkHeader().Slice())\n\t\tif _, consumed := newPk.NetworkHeader().Consume(consumeBytes); !consumed {\n\t\t\tpanic(fmt.Sprintf(\"expected to consume network header %d bytes from new packet\", consumeBytes))\n\t\t}\n\t\tnewPk.NetworkProtocolNumber = pk.NetworkProtocolNumber\n\t}\n\n\t{\n\t\tconsumeBytes := len(pk.TransportHeader().Slice())\n\t\tif _, consumed := newPk.TransportHeader().Consume(consumeBytes); !consumed {\n\t\t\tpanic(fmt.Sprintf(\"expected to consume transport header %d bytes from new packet\", consumeBytes))\n\t\t}\n\t\tnewPk.TransportProtocolNumber = pk.TransportProtocolNumber\n\t}\n\n\tnewPk.tuple = pk.tuple\n\n\treturn newPk\n}", "func (gc gcsClient) Copy(ctx context.Context, from, to Path) (*storage.ObjectAttrs, error) {\n\tclient := gc.clientFromPath(from)\n\treturn client.Copy(ctx, from, to)\n}" ]
[ "0.57995325", "0.5721898", "0.56194115", "0.54741675", "0.54422647", "0.5383125", "0.53659135", "0.53628725", "0.532404", "0.5273952", "0.52007854", "0.51824313", "0.51795876", "0.5140712", "0.5138", "0.51334554", "0.5116495", "0.5112037", "0.51092386", "0.5105935", "0.5102549", "0.5097165", "0.5082627", "0.5080985", "0.5074875", "0.50692064", "0.50561816", "0.50543314", "0.5053029", "0.50300753", "0.5027527", "0.5025294", "0.5016952", "0.50065565", "0.50034034", "0.50034034", "0.5003097", "0.4970126", "0.49622118", "0.49556425", "0.495323", "0.49517593", "0.49488717", "0.49417198", "0.49392152", "0.49381667", "0.49338147", "0.49252927", "0.4909938", "0.49086097", "0.4907793", "0.49074373", "0.49019453", "0.4895756", "0.48885518", "0.48861372", "0.48844197", "0.48807317", "0.48794156", "0.48765597", "0.48585618", "0.4844007", "0.48368445", "0.48342094", "0.48282602", "0.48282602", "0.48282602", "0.4825349", "0.4824019", "0.4819105", "0.48183736", "0.48124075", "0.48108688", "0.48029006", "0.47985834", "0.47937912", "0.47929683", "0.47819766", "0.47791108", "0.47693926", "0.47690937", "0.47664645", "0.47652447", "0.47513777", "0.47486597", "0.47463882", "0.47451204", "0.47399727", "0.47249717", "0.47217885", "0.47142902", "0.4713315", "0.47131538", "0.4711852", "0.470883", "0.47019845", "0.46918097", "0.46770293", "0.46729022" ]
0.5447068
5
respecify a portion of a color table
func CopyColorSubTable(target uint32, start int32, x int32, y int32, width int32) { C.glowCopyColorSubTable(gpCopyColorSubTable, (C.GLenum)(target), (C.GLsizei)(start), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func ColorSubTable(target uint32, start int32, count int32, format uint32, xtype uint32, data unsafe.Pointer) {\n C.glowColorSubTable(gpColorSubTable, (C.GLenum)(target), (C.GLsizei)(start), (C.GLsizei)(count), (C.GLenum)(format), (C.GLenum)(xtype), data)\n}", "func ColorSubTable(target uint32, start int32, count int32, format uint32, xtype uint32, data unsafe.Pointer) {\n\tC.glowColorSubTable(gpColorSubTable, (C.GLenum)(target), (C.GLsizei)(start), (C.GLsizei)(count), (C.GLenum)(format), (C.GLenum)(xtype), data)\n}", "func CopyColorSubTable(target uint32, start int32, x int32, y int32, width int32) {\n C.glowCopyColorSubTable(gpCopyColorSubTable, (C.GLenum)(target), (C.GLsizei)(start), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func ColorTable(target uint32, internalformat uint32, width int32, format uint32, xtype uint32, table unsafe.Pointer) {\n C.glowColorTable(gpColorTable, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), table)\n}", "func CopyColorTable(target uint32, internalformat uint32, x int32, y int32, width int32) {\n C.glowCopyColorTable(gpCopyColorTable, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func ColorTable(target uint32, internalformat uint32, width int32, format uint32, xtype uint32, table unsafe.Pointer) {\n\tC.glowColorTable(gpColorTable, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), table)\n}", "func CopyColorTable(target uint32, internalformat uint32, x int32, y int32, width int32) {\n\tC.glowCopyColorTable(gpCopyColorTable, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func GetColorTable(target uint32, format uint32, xtype uint32, table unsafe.Pointer) {\n C.glowGetColorTable(gpGetColorTable, (C.GLenum)(target), (C.GLenum)(format), (C.GLenum)(xtype), table)\n}", "func Color(foreColor, backColor, mode gb.UINT8) {}", "func getPieceColor(square uint8) int {\n\treturn int((square & ColorMask) >> 2)\n}", "func (c Chessboard) pieceColorOnPosition(pos int) int {\n if c.boardSquares[pos] < 0 {\n return -1\n }\n\n return int(c.boardSquares[pos] / 10)\n}", "func color(r geometry.Ray, world geometry.Hitable, depth int) geometry.Vector {\n\thit, record := world.CheckForHit(r, 0.001, math.MaxFloat64)\n\n\t// if hit {\n\t// \ttarget := record.Point.Add(record.Normal).Add(RandomInUnitSphere())\n\t// \treturn color(&geometry.Ray{Origin: record.Point, Direction: target.Subtract(record.P)}, world).Scale(0.5)\n\t// }\n\n\tif hit {\n\t\tif depth < 50 {\n\t\t\tscattered, scatteredRay := record.Scatter(r, record)\n\t\t\tif scattered {\n\t\t\t\tnewColor := color(scatteredRay, world, depth+1)\n\t\t\t\treturn record.Material.Albedo().Multiply(newColor)\n\t\t\t}\n\t\t}\n\t}\n\n\t// Make unit vector so y is between -1.0 and 1.0\n\tunitDirection := r.Direction.Normalize()\n\n\tvar t float64 = 0.5 * (unitDirection.Y + 1.0)\n\n\t// The two vectors here are what creates the sky(Blue to white gradient of the background)\n\treturn geometry.Vector{X: 1.0, Y: 1.0, Z: 1.0}.Scale(1.0 - t).Add(geometry.Vector{X: 0.5, Y: 0.7, Z: 1.0}.Scale(t))\n}", "func COLORSn(n uint) Component {\n\t//aiComponent_COLORSn(n) (1u << (n+20u))\n\treturn Component(1 << (n + 20))\n}", "func (c *Color) Sub(dc Color) {\n\tr, g, b, a := c.RGBA() // uint32\n\tr = (r >> 8) - uint32(dc.R)\n\tg = (g >> 8) - uint32(dc.G)\n\tb = (b >> 8) - uint32(dc.B)\n\ta = (a >> 8) - uint32(dc.A)\n\tif r > 255 { // overflow\n\t\tr = 0\n\t}\n\tif g > 255 {\n\t\tg = 0\n\t}\n\tif b > 255 {\n\t\tb = 0\n\t}\n\tif a > 255 {\n\t\ta = 0\n\t}\n\tc.SetUInt8(uint8(r), uint8(g), uint8(b), uint8(a))\n}", "func printColored(boundaries []colored_data, data []byte) []string {\n\tgrouping := 2\n\tper_line := 16\n\t// 16 bytes per line, grouped by 2 bytes\n\tnlines := len(data) / 16\n\tif len(data) % 16 > 0 {\n\t\tnlines++\n\t}\n\t\n\tout := make([]string, nlines)\n\n\tkolo := \"\\x1B[0m\"\n\t\n\tfor line := 0; line < nlines; line++ {\n\t\ts := \"\\t0x\"\n\t\txy := make([]byte, 2)\n\t\tline_offset := line * per_line\n\t\txy[0] = byte(line_offset >> 8)\n\t\txy[1] = byte(line_offset & 0xff)\n\t\ts = s + hex.EncodeToString(xy) + \":\\t\" + kolo\n\n\n\t\tline_length := per_line\n\t\tif line == nlines - 1 && len(data) % 16 > 0 {\n\t\t\tline_length = len(data) % 16\n\t\t}\n\n\t\tfor b := 0; b < line_length; b++ {\n\t\t\ttotal_offset := line * per_line + b\n\n\t\t\t// inserting coulourings\n\t\t\tfor x := 0; x < len(boundaries); x++ {\n\t\t\t\t//fmt.Println(\"!\")\n\t\t\t\tif(boundaries[x].offset == uint16(total_offset)) {\n\t\t\t\t\ts = s + boundaries[x].color\n\t\t\t\t\tkolo = boundaries[x].color\n\t\t\t\t}\n\t\t\t}\n\t\n\t\t\t// add byte from total_offset\n\t\t\txxx := make([]byte, 1)\n\t\t\txxx[0] = data[total_offset]\n\t\t\ts = s + hex.EncodeToString(xxx)\n\t\t\t\n\t\t\t// if b > 0 && b % grouping == 0, insert space\n\t\t\t\n\t\t\tif b > 0 && (b-1) % grouping == 0 {\n\t\t\t\ts = s + \" \"\n\t\t\t}\n\t\t\t\n\t\t}\n\t\t\n\t\tout[line] = s + COLOR_NORMAL\n\t}\n\t\n\treturn out\n}", "func (x *ImgSpanner) SpanColorFunc(yi, xi0, xi1 int, ma uint32) {\n\ti0 := (yi)*x.stride + (xi0)*4\n\ti1 := i0 + (xi1-xi0)*4\n\tcx := xi0\n\n\tfor i := i0; i < i1; i += 4 {\n\t\t// uses the Porter-Duff composition operator.\n\t\trcr, rcg, rcb, rca := x.colorFunc(cx, yi).RGBA()\n\t\tif x.xpixel == true {\n\t\t\trcr, rcb = rcb, rcr\n\t\t}\n\t\tcx++\n\t\ta := (m - (rca * ma / m)) * pa\n\t\tdr := uint32(x.pix[i+0])\n\t\tdg := uint32(x.pix[i+1])\n\t\tdb := uint32(x.pix[i+2])\n\t\tda := uint32(x.pix[i+3])\n\t\tx.pix[i+0] = uint8((dr*a + rcr*ma) / mp)\n\t\tx.pix[i+1] = uint8((dg*a + rcg*ma) / mp)\n\t\tx.pix[i+2] = uint8((db*a + rcb*ma) / mp)\n\t\tx.pix[i+3] = uint8((da*a + rca*ma) / mp)\n\t}\n}", "func nextcolor(c color.RGBA) color.RGBA {\n\tswitch {\n\tcase c.R == 255 && c.G == 0 && c.B == 0:\n\t\tc.G += 5\n\tcase c.R == 255 && c.G != 255 && c.B == 0:\n\t\tc.G += 5\n\tcase c.G == 255 && c.R != 0:\n\t\tc.R -= 5\n\tcase c.R == 0 && c.B != 255:\n\t\tc.B += 5\n\tcase c.B == 255 && c.G != 0:\n\t\tc.G -= 5\n\tcase c.G == 0 && c.R != 255:\n\t\tc.R += 5\n\tdefault:\n\t\tc.B -= 5\n\t}\n\treturn c\n}", "func makeColorLookup(vals []int, length int) []int {\n\tres := make([]int, length)\n\n\tvi := 0\n\tfor i := 0; i < len(res); i++ {\n\t\tif vi+1 < len(vals) {\n\t\t\tif i <= (vals[vi]+vals[vi+1])/2 {\n\t\t\t\tres[i] = vi\n\t\t\t} else {\n\t\t\t\tvi++\n\t\t\t\tres[i] = vi\n\t\t\t}\n\t\t} else if vi < len(vals) {\n\t\t\t// only last vi is valid\n\t\t\tres[i] = vi\n\t\t}\n\t}\n\treturn res\n}", "func calcTableCap(c int) int {\n\tif c <= neighbour {\n\t\treturn c\n\t}\n\treturn c + neighbour - 1\n}", "func colorIsland(grid [][]byte, color byte, nX, nY, x, y int) {\r\n\tif x < 0 || x >= nX || y < 0 || y >= nY || grid[y][x] != '1' {\r\n\t\treturn // no island found\r\n\t}\r\n\tgrid[y][x] = '0' // + byte(color) // // useful for debugging\r\n\t// check adjacent grid squares\r\n\tcolorIsland(grid, color, nX, nY, x - 1, y)\r\n\tcolorIsland(grid, color, nX, nY, x + 1, y)\r\n\tcolorIsland(grid, color, nX, nY, x, y - 1)\r\n\tcolorIsland(grid, color, nX, nY, x, y + 1)\r\n}", "func p256Select(point, table []uint64, idx int)", "func p256Select(point, table []uint64, idx int)", "func GetColorTable(target uint32, format uint32, xtype uint32, table unsafe.Pointer) {\n\tC.glowGetColorTable(gpGetColorTable, (C.GLenum)(target), (C.GLenum)(format), (C.GLenum)(xtype), table)\n}", "func paintFill(image [][]string, c string, y, x int) [][]string {\n\t//range check\n\tif y > len(image)-1 {\n\t\treturn image\n\t}\n\tif x > len(image[y])-1 {\n\t\treturn image\n\t}\n\t//dupe color check\n\tif image[y][x] == c {\n\t\treturn image\n\t}\n\t//identify origin color\n\torig := image[y][x]\n\t//color origin\n\tmImage := image\n\tmImage[y][x] = c\n\t//check for valid left\n\tif x > 0 && mImage[y][x-1] == orig {\n\t\tmImage = paintFill(mImage, c, y, x-1)\n\t}\n\t//check for valid right\n\tif x < len(mImage[y])-1 && mImage[y][x+1] == orig {\n\t\tmImage = paintFill(mImage, c, y, x+1)\n\t}\n\t//check for valid up\n\tif y > 0 && mImage[y-1][x] == orig {\n\t\tmImage = paintFill(mImage, c, y-1, x)\n\t}\n\t//check for valid down\n\tif y < len(mImage)-1 && mImage[y+1][x] == orig {\n\t\tmImage = paintFill(mImage, c, y+1, x)\n\t}\n\treturn mImage\n}", "func RandColor(dst inter.Adder, n, m, k int) {\n\tg := RandGraph(n, m)\n\tvar mkVar = func(n, c int) z.Var {\n\t\treturn z.Var(n*c + c + 1)\n\t}\n\tfor i := range g {\n\t\tfor j := 0; j < k; j++ {\n\t\t\tm := mkVar(i, j).Pos()\n\t\t\tdst.Add(m)\n\t\t}\n\t\tdst.Add(0)\n\t}\n\tfor a, es := range g {\n\t\tfor _, b := range es {\n\t\t\tif b >= a {\n\t\t\t\tcontinue\n\t\t\t}\n\t\t\tfor c := 0; c < k; c++ {\n\t\t\t\ta := mkVar(a, c).Neg()\n\t\t\t\tb := mkVar(b, c).Neg()\n\t\t\t\tdst.Add(a)\n\t\t\t\tdst.Add(b)\n\t\t\t}\n\t\t\tdst.Add(0)\n\t\t}\n\t}\n}", "func TestConstraint(t *testing.T) {\n octant := func(lab ColorLab) bool { return lab.L <= 0.5 && lab.A <= 0.0 && lab.B <= 0.0 }\n\n pal, err := SoftPaletteEx(100, SoftPaletteSettings{octant, 50, true})\n if err != nil {\n t.Errorf(\"Error: %v\", err)\n }\n\n // Check ALL the colors!\n for icol, col := range pal {\n if !col.IsValid() {\n t.Errorf(\"Color %v in constrained palette is invalid: %v\", icol, col)\n }\n\n lab := col.Lab()\n if lab.L > 0.5 || lab.A > 0.0 || lab.B > 0.0 {\n t.Errorf(\"Color %v in constrained palette violates the constraint: %v (lab: %v)\", icol, col, [3]float64{lab.L, lab.A, lab.B})\n }\n }\n}", "func (c Chessboard) validColorPiece(pos int, color int) bool {\n return c.pieceColorOnPosition(pos) == color\n}", "func ColorSamplingPointsForStillColorsVideo(videoW, videoH int) map[string]image.Point {\n\touterCorners := map[string]image.Point{\n\t\t\"outer_top_left\": {1, 1},\n\t\t\"outer_top_right\": {(videoW - 1) - 1, 1},\n\t\t\"outer_bottom_right\": {videoW - 1, videoH - 1},\n\t\t\"outer_bottom_left\": {1, (videoH - 1) - 1},\n\t}\n\tedgeOffset := 5\n\tstencilW := 5\n\tinnerCorners := map[string]image.Point{\n\t\t\"inner_top_left_00\": {edgeOffset, edgeOffset},\n\t\t\"inner_top_left_01\": {edgeOffset, edgeOffset + stencilW},\n\t\t\"inner_top_left_10\": {edgeOffset + stencilW, edgeOffset},\n\t\t\"inner_top_left_11\": {edgeOffset + stencilW, edgeOffset + stencilW},\n\t\t\"inner_top_right_00\": {(videoW - 1) - edgeOffset, edgeOffset},\n\t\t\"inner_top_right_01\": {(videoW - 1) - edgeOffset, edgeOffset + stencilW},\n\t\t\"inner_top_right_10\": {(videoW - 1) - edgeOffset - stencilW, edgeOffset},\n\t\t\"inner_top_right_11\": {(videoW - 1) - edgeOffset - stencilW, edgeOffset + stencilW},\n\t\t\"inner_bottom_right_00\": {(videoW - 1) - edgeOffset, (videoH - 1) - edgeOffset},\n\t\t\"inner_bottom_right_01\": {(videoW - 1) - edgeOffset, (videoH - 1) - edgeOffset - stencilW},\n\t\t\"inner_bottom_right_10\": {(videoW - 1) - edgeOffset - stencilW, (videoH - 1) - edgeOffset},\n\t\t\"inner_bottom_right_11\": {(videoW - 1) - edgeOffset - stencilW, (videoH - 1) - edgeOffset - stencilW},\n\t\t\"inner_bottom_left_00\": {edgeOffset, (videoH - 1) - edgeOffset},\n\t\t\"inner_bottom_left_01\": {edgeOffset, (videoH - 1) - edgeOffset - stencilW},\n\t\t\"inner_bottom_left_10\": {edgeOffset + stencilW, (videoH - 1) - edgeOffset},\n\t\t\"inner_bottom_left_11\": {edgeOffset + stencilW, (videoH - 1) - edgeOffset - stencilW},\n\t}\n\tsamples := map[string]image.Point{}\n\tfor k, v := range innerCorners {\n\t\tsamples[k] = v\n\t}\n\tfor k, v := range outerCorners {\n\t\tsamples[k] = v\n\t}\n\treturn samples\n}", "func (x *ImgSpanner) SpanColorFuncR(yi, xi0, xi1 int, ma uint32) {\n\ti0 := (yi)*x.stride + (xi0)*4\n\ti1 := i0 + (xi1-xi0)*4\n\tcx := xi0\n\tfor i := i0; i < i1; i += 4 {\n\t\trcr, rcg, rcb, rca := x.colorFunc(cx, yi).RGBA()\n\t\tif x.xpixel == true {\n\t\t\trcr, rcb = rcb, rcr\n\t\t}\n\t\tcx++\n\t\tx.pix[i+0] = uint8(rcr * ma / mp)\n\t\tx.pix[i+1] = uint8(rcg * ma / mp)\n\t\tx.pix[i+2] = uint8(rcb * ma / mp)\n\t\tx.pix[i+3] = uint8(rca * ma / mp)\n\t}\n}", "func (r *paintingRobot) scanColor() int {\n for _, p := range r.paintedPoints {\n if p.x == r.position.x && p.y == r.position.y {\n return p.color\n }\n }\n\n return 0\n}", "func StandardTileColorer(frame []byte, stride int) TileColorFunction {\n\treturn func(hTile int, vTile int, lookupArray []byte, mask uint64, indexBitSize uint64) {\n\t\tstart := vTile*TileSideLength*stride + hTile*TileSideLength\n\t\tsingleMask := ^(^uint64(0) << indexBitSize)\n\n\t\tfor i := 0; i < PixelPerTile; i++ {\n\t\t\tpixelValue := lookupArray[(mask>>(indexBitSize*uint64(i)))&singleMask]\n\n\t\t\tif pixelValue != 0x00 {\n\t\t\t\toffset := start + (i % TileSideLength) + stride*(i/TileSideLength)\n\n\t\t\t\tframe[offset] = pixelValue\n\t\t\t}\n\t\t}\n\t}\n}", "func (s *binaryScanner) IsUniformColor(r image.Rectangle, c color.Color) bool {\n\tvar (\n\t\tok bool\n\t\tbit binimg.Bit\n\t)\n\t// ensure c is a binimg.Bit, or convert it\n\tif bit, ok = c.(binimg.Bit); !ok {\n\t\tbit = s.ColorModel().Convert(c).(binimg.Bit)\n\t}\n\n\t// in a binary image, pixel/bytes are 1 or 0, we want the other color for\n\t// bytes.IndexBytes\n\tother := bit.Other().V\n\tfor y := r.Min.Y; y < r.Max.Y; y++ {\n\t\ti := s.PixOffset(r.Min.X, y)\n\t\tj := s.PixOffset(r.Max.X, y)\n\t\t// look for the first pixel that is not c\n\t\tif bytes.IndexByte(s.Pix[i:j], other) != -1 {\n\t\t\treturn false\n\t\t}\n\t}\n\treturn true\n}", "func tableCoords(i int) (col coord, row coord) {\n\trow = (i % 3) * CardHeight\n\tcol = 1 + ((i / 3) * (CardWidth + 2))\n\treturn\n}", "func (c * Case)TakeColor(color int)int8{\n\tif color > len(c.cows){\n\t\treturn 0\n\t}\n\tnb := c.cows[color]\n\tc.cows[color] = 0\n\treturn int8(nb)\n}", "func constructColorMap(limit float64, colorized bool) ColorMap {\n\tif colorized {\n\t\treturn func(x float64) (uint8, uint8, uint8) {\n\t\t\tr, g, b, _ := colorful.Hsl(x/limit-180, saturation, luminance*(1-x/limit)).RGBA()\n\t\t\treturn uint8(r), uint8(g), uint8(b)\n\t\t}\n\t} else {\n\t\treturn func(x float64) (uint8, uint8, uint8) {\n\t\t\tc := uint8(255 * x / limit)\n\t\t\treturn c, c, c\n\t\t}\n\t}\n}", "func (pb *Pbar) ToggleColor(arg interface{}) {\n\tswitch reflect.TypeOf(arg).Kind() {\n\tcase reflect.Slice:\n\t\tcol := reflect.ValueOf(arg)\n\t\tl := col.Len()\n\n\t\tif l < 0 || l > 4 {\n\t\t\tfmt.Println(\"Error: Must provide a number of colors between 0 - 4.\\nSwitching to b/w...\")\n\t\t\tpb.isColor = false\n\t\t\treturn\n\t\t}\n\n\t\tfor i := 0; i < col.Len(); i++ {\n\t\t\tcolStr := col.Index(i).String()\n\t\t\tif _, ok := colors[colStr]; !ok {\n\t\t\t\tfmt.Printf(\"'%s' is not a valid color. Switching to b/w...\\n\\n\", colStr)\n\t\t\t\tpb.isColor = false\n\t\t\t\treturn\n\t\t\t}\n\t\t}\n\n\t\tif l == 4 {\n\t\t\tpb.LOW = colors[(col.Index(0)).String()]\n\t\t\tpb.MEDIUM = colors[(col.Index(1)).String()]\n\t\t\tpb.HIGH = colors[(col.Index(2)).String()]\n\t\t\tpb.FULL = colors[(col.Index(3)).String()]\n\t\t} else if l == 3 {\n\t\t\tpb.LOW = colors[(col.Index(0)).String()]\n\t\t\tpb.MEDIUM = colors[(col.Index(1)).String()]\n\t\t\tpb.HIGH = colors[(col.Index(2)).String()]\n\t\t\tpb.FULL = colors[(col.Index(2)).String()]\n\t\t} else if l == 2 {\n\t\t\tpb.LOW = colors[(col.Index(0)).String()]\n\t\t\tpb.MEDIUM = colors[(col.Index(0)).String()]\n\t\t\tpb.HIGH = colors[(col.Index(1)).String()]\n\t\t\tpb.FULL = colors[(col.Index(1)).String()]\n\t\t} else if l == 1 {\n\t\t\tpb.LOW = colors[(col.Index(0)).String()]\n\t\t\tpb.MEDIUM = colors[(col.Index(0)).String()]\n\t\t\tpb.HIGH = colors[(col.Index(0)).String()]\n\t\t\tpb.FULL = colors[(col.Index(0)).String()]\n\t\t} else {\n\t\t\tpb.isColor = false\n\t\t\treturn\n\t\t}\n\t\tpb.isColor = true\n\tcase reflect.String:\n\t\tcol := reflect.ValueOf(arg)\n\t\tif _, ok := colors[col.String()]; ok {\n\t\t\tpb.LOW = colors[col.String()]\n\t\t\tpb.MEDIUM = colors[col.String()]\n\t\t\tpb.HIGH = colors[col.String()]\n\t\t\tpb.FULL = colors[col.String()]\n\t\t\tpb.isColor = true\n\t\t}\n\t}\n}", "func (nv *NetView) UnitValColor(lay emer.Layer, idx1d int, raw float32, hasval bool) (scaled float32, clr gist.Color) {\n\tif nv.CurVarParams == nil || nv.CurVarParams.Var != nv.Var {\n\t\tok := false\n\t\tnv.CurVarParams, ok = nv.VarParams[nv.Var]\n\t\tif !ok {\n\t\t\treturn\n\t\t}\n\t}\n\tif !hasval {\n\t\tscaled = 0\n\t\tif lay.Name() == nv.Data.PrjnLay && idx1d == nv.Data.PrjnUnIdx {\n\t\t\tclr.SetUInt8(0x20, 0x80, 0x20, 0x80)\n\t\t} else {\n\t\t\tclr = NilColor\n\t\t}\n\t} else {\n\t\tclp := nv.CurVarParams.Range.ClipVal(raw)\n\t\tnorm := nv.CurVarParams.Range.NormVal(clp)\n\t\tvar op float32\n\t\tif nv.CurVarParams.ZeroCtr {\n\t\t\tscaled = float32(2*norm - 1)\n\t\t\top = (nv.Params.ZeroAlpha + (1-nv.Params.ZeroAlpha)*mat32.Abs(scaled))\n\t\t} else {\n\t\t\tscaled = float32(norm)\n\t\t\top = (nv.Params.ZeroAlpha + (1-nv.Params.ZeroAlpha)*0.8) // no meaningful alpha -- just set at 80\\%\n\t\t}\n\t\tclr = nv.ColorMap.Map(float64(norm))\n\t\tr, g, b, a := clr.ToNPFloat32()\n\t\tclr.SetNPFloat32(r, g, b, a*op)\n\t}\n\treturn\n}", "func (b board) at(c coord, cf colorFlags) (bool, bool) {\n\tf := b.fields[c.y][c.x]\n\treturn f&cf.color == cf.color,\n\t\tf&cf.connected == cf.connected\n}", "func colourRow(s tcell.Screen, style tcell.Style, row int) {\n\tfor x := 0; x < windowWidth; x++ {\n\t\ts.SetCell(x, row, style, ' ')\n\t}\n}", "func colFromPosition(pos int) int {\n return pos % 8\n}", "func (r *Rasterizer8BitsSample) fillEvenOdd(img *image.RGBA, c color.Color, clipBound [4]float64) {\n\tvar x, y uint32\n\n\tminX := uint32(clipBound[0])\n\tmaxX := uint32(clipBound[2])\n\n\tminY := uint32(clipBound[1]) >> SUBPIXEL_SHIFT\n\tmaxY := uint32(clipBound[3]) >> SUBPIXEL_SHIFT\n\n\trgba := convert(c)\n\tpixColor := *(*uint32)(unsafe.Pointer(&rgba))\n\n\tcs1 := pixColor & 0xff00ff\n\tcs2 := pixColor >> 8 & 0xff00ff\n\n\tstride := uint32(img.Stride)\n\tvar mask SUBPIXEL_DATA\n\tmaskY := minY * uint32(r.BufferWidth)\n\tminY *= stride\n\tmaxY *= stride\n\tvar tp []uint8\n\tvar pixelx uint32\n\tfor y = minY; y < maxY; y += stride {\n\t\ttp = img.Pix[y:]\n\t\tmask = 0\n\n\t\t//i0 := (s.Y-r.Image.Rect.Min.Y)*r.Image.Stride + (s.X0-r.Image.Rect.Min.X)*4\r\n\t\t//i1 := i0 + (s.X1-s.X0)*4\r\n\t\tpixelx = minX * 4\n\t\tfor x = minX; x <= maxX; x++ {\n\t\t\tmask ^= r.MaskBuffer[maskY+x]\n\t\t\t// 8bits\r\n\t\t\talpha := uint32(coverageTable[mask])\n\t\t\t// 16bits\r\n\t\t\t//alpha := uint32(coverageTable[mask & 0xff] + coverageTable[(mask >> 8) & 0xff])\r\n\t\t\t// 32bits\r\n\t\t\t//alpha := uint32(coverageTable[mask & 0xff] + coverageTable[(mask >> 8) & 0xff] + coverageTable[(mask >> 16) & 0xff] + coverageTable[(mask >> 24) & 0xff])\r\n\n\t\t\t// alpha is in range of 0 to SUBPIXEL_COUNT\r\n\t\t\tp := (*uint32)(unsafe.Pointer(&tp[pixelx]))\n\t\t\tif alpha == SUBPIXEL_FULL_COVERAGE {\n\t\t\t\t*p = pixColor\n\t\t\t} else if alpha != 0 {\n\t\t\t\tinvAlpha := SUBPIXEL_COUNT - alpha\n\t\t\t\tct1 := *p & 0xff00ff * invAlpha\n\t\t\t\tct2 := *p >> 8 & 0xff00ff * invAlpha\n\n\t\t\t\tct1 = (ct1 + cs1*alpha) >> SUBPIXEL_SHIFT & 0xff00ff\n\t\t\t\tct2 = (ct2 + cs2*alpha) << (8 - SUBPIXEL_SHIFT) & 0xff00ff00\n\n\t\t\t\t*p = ct1 + ct2\n\t\t\t}\n\t\t\tpixelx += 4\n\t\t}\n\t\tmaskY += uint32(r.BufferWidth)\n\t}\n}", "func (otuTable *otuTable) ColourTopN(colourStore colour.ColourSketchStore, pad bool) ([][][]color.RGBA, error) {\n\t// attach the colour store\n\totuTable.ColourSketchStore = colourStore\n\t// make the image template\n\trgbaLines := make([][][]color.RGBA, otuTable.GetNumSamples())\n\t// perform for each sample in the OTU table\n\tfor i := range otuTable.sampleNames {\n\t\trgbaLines[i] = make([][]color.RGBA, len(otuTable.topN[i]))\n\t\t// for each sample, range over the topN otus\n\t\tfor j, otu := range otuTable.topN[i] {\n\t\t\t// if OTU is has 0 abundance, add row of padding pixels if requested, else skip this OTU\n\t\t\tif otu.otu == PAD_LINE && !pad {\n\t\t\t\tcontinue\n\t\t\t}\n\t\t\t// lookup the otu in the css\n\t\t\tif cs, ok := otuTable.ColourSketchStore[otu.otu]; !ok {\n\t\t\t\t// TODO: if the topN OTUs are not present in the REFSEQ db, this error will be raised - need to work on handling this event\n\t\t\t\tcontinue\n\t\t\t\t//return nil, fmt.Errorf(\"sample %v: the genus name `%v` (abundance: %d) could not be found in the coloursketches\", string(otuTable.sampleNames[i]), otu.otu, otu.abundance)\n\t\t\t} else {\n\t\t\t\t// make a copy of the colour sketch\n\t\t\t\tcsCopy := cs.CopySketch()\n\t\t\t\t// adjust the colour sketch so that the B slot corresponds to the OTU abundance\n\t\t\t\t// first scale the abundance value to fit the uint8 slot\n\t\t\t\t// TODO: set a customisable cap for abundance values\n\t\t\t\tabunCap := 5000\n\t\t\t\tvar abunVal float32\n\t\t\t\tif otu.abundance > abunCap {\n\t\t\t\t\tabunVal = 255\n\t\t\t\t} else {\n\t\t\t\t\tabunVal = (float32(otu.abundance) / float32(abunCap)) * 255\n\t\t\t\t}\n\t\t\t\t// adjust the B slot\n\t\t\t\tif err := csCopy.Adjust('B', uint8(abunVal)); err != nil {\n\t\t\t\t\treturn nil, err\n\t\t\t\t}\n\t\t\t\t// adjust the A slot so that it is set to visible\n\t\t\t\tif err := csCopy.Adjust('A', 255); err != nil {\n\t\t\t\t\treturn nil, err\n\t\t\t\t}\n\t\t\t\tif rgba, err := csCopy.PrintPNGline(); err != nil {\n\t\t\t\t\treturn nil, err\n\t\t\t\t} else {\n\t\t\t\t\trgbaLines[i][j] = rgba\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\treturn rgbaLines, nil\n}", "func rect(img *image.NRGBA, x1, y1, x2, y2 int, col color.Color) {\r\n\thLine(img, x1, y1, x2, col)\r\n\thLine(img, x1, y2, x2, col)\r\n\tvLine(img, x1, y1, y2, col)\r\n\tvLine(img, x2, y1, y2, col)\r\n}", "func printTable(data []string, color bool) {\n\tvar listType string\n\n\ttable := tablewriter.NewWriter(os.Stdout)\n\n\tswitch color {\n\tcase true:\n\t\tlistType = \"White\"\n\tcase false:\n\t\tlistType = \"Black\"\n\t}\n\n\ttable.SetHeader([]string{\"#\", \"B/W\", \"CIDR\"})\n\n\tfor i, v := range data {\n\t\tl := make([]string, 0)\n\t\tl = append(l, strconv.Itoa(i+offset))\n\t\tl = append(l, listType)\n\t\tl = append(l, v)\n\t\ttable.Append(l)\n\t}\n\n\ttable.Render()\n}", "func combineColor(color ColorName, isBackgroundColor bool) outPutSet {\n\tif color >= COLOR_BLACK && color <= COLOR_WHITE {\n\t\tif isBackgroundColor {\n\t\t\treturn COLOR_BACKGROUND + outPutSet(color)\n\t\t}\n\t\treturn COLOR_FOREGROUND + outPutSet(color)\n\t}\n\treturn 0\n}", "func (v *mandelbrotViewer) color(m float64) color.Color {\n\t_, f := math.Modf(m)\n\tncol := len(palette.Plan9)\n\tc1, _ := colorful.MakeColor(palette.Plan9[int(m)%ncol])\n\tc2, _ := colorful.MakeColor(palette.Plan9[int(m+1)%ncol])\n\tr, g, b := c1.BlendHcl(c2, f).Clamped().RGB255()\n\treturn color.RGBA{r, g, b, 255}\n}", "func (c *Color) Sub(o *Color) *Color {\n\treturn NewColor(\n\t\tc.r-o.r,\n\t\tc.g-o.g,\n\t\tc.b-o.b,\n\t)\n}", "func (w *LDRWrapper) HDRAt(x, y int) hdrcolor.Color {\n\tr, g, b, _ := w.At(x, y).RGBA()\n\treturn hdrcolor.RGB{R: float64(r) / 0xFFFF, G: float64(g) / 0xFFFF, B: float64(b) / 0xFFFF}\n}", "func d10nodeCover(node *d10nodeT) d10rectT {\n\trect := node.branch[0].rect\n\tfor index := 1; index < node.count; index++ {\n\t\trect = d10combineRect(&rect, &(node.branch[index].rect))\n\t}\n\treturn rect\n}", "func calcMask(tableCap uint32) uint32 {\n\tif tableCap <= neighbour {\n\t\treturn tableCap - 1\n\t}\n\treturn tableCap - neighbour // Always has a virtual bucket with neigh slots.\n}", "func colorToMode(c cell.Color, colorMode terminalapi.ColorMode) cell.Color {\n\tif c == cell.ColorDefault {\n\t\treturn c\n\t}\n\tswitch colorMode {\n\tcase terminalapi.ColorModeNormal:\n\t\tc %= 16 + 1 // Add one for cell.ColorDefault.\n\tcase terminalapi.ColorMode256:\n\t\tc %= 256 + 1 // Add one for cell.ColorDefault.\n\tcase terminalapi.ColorMode216:\n\t\tif c <= 216 { // Add one for cell.ColorDefault.\n\t\t\treturn c + 16\n\t\t}\n\t\tc = c%216 + 16\n\tcase terminalapi.ColorModeGrayscale:\n\t\tif c <= 24 { // Add one for cell.ColorDefault.\n\t\t\treturn c + 232\n\t\t}\n\t\tc = c%24 + 232\n\tdefault:\n\t\tc = cell.ColorDefault\n\t}\n\treturn c\n}", "func GenColor(intr int) [][]uint8 {\n\toutput := [][]uint8{}\n\tfor i := 0; i <= 255; i += intr {\n\t\tfor j := 0; j <= 255; j += intr {\n\t\t\tfor k := 0; k <= 255; k += intr {\n\t\t\t\ta := []uint8{uint8(i), uint8(j), uint8(k)}\n\t\t\t\toutput = append(output, a)\n\n\t\t\t}\n\t\t}\n\t}\n\treturn output\n\n}", "func MakeTable(poly uint32) *Table {}", "func d16nodeCover(node *d16nodeT) d16rectT {\n\trect := node.branch[0].rect\n\tfor index := 1; index < node.count; index++ {\n\t\trect = d16combineRect(&rect, &(node.branch[index].rect))\n\t}\n\treturn rect\n}", "func getColorIndex(temp float64) int {\n\tif temp < *minTemp {\n\t\treturn 0\n\t}\n\tif temp > *maxTemp {\n\t\treturn len(colors) - 1\n\t}\n\treturn int((temp - *minTemp) * float64(len(colors)-1) / (*maxTemp - *minTemp))\n}", "func extractSwatches(src *image.RGBA, numColors int) []colorful.Color {\n\tconst (\n\t\tW = 400\n\t\tH = 75\n\t)\n\tvar swatches []colorful.Color\n\tb := src.Bounds()\n\tsw := W / numColors\n\tfor i := 0; i < numColors; i++ {\n\t\tm := src.SubImage(trimRect(image.Rect(b.Min.X+i*sw, b.Max.Y-H, b.Min.X+(i+1)*sw, b.Max.Y), 10))\n\t\tswatches = append(swatches, toColorful(averageColor(m)))\n\t\tsavePNG(strconv.Itoa(i), m) // for debugging\n\t}\n\tconst dim = 50\n\tm := image.NewRGBA(image.Rect(0, 0, dim*len(swatches), dim))\n\tfor i, c := range swatches {\n\t\tr := image.Rect(i*dim, 0, (i+1)*dim, dim)\n\t\tdraw.Draw(m, r, &image.Uniform{fromColorful(c)}, image.ZP, draw.Src)\n\t}\n\tsavePNG(\"swatches\", m) // for debugging\n\treturn swatches\n}", "func d8nodeCover(node *d8nodeT) d8rectT {\n\trect := node.branch[0].rect\n\tfor index := 1; index < node.count; index++ {\n\t\trect = d8combineRect(&rect, &(node.branch[index].rect))\n\t}\n\treturn rect\n}", "func getColor(r Ray, world HittableList, depth int) mgl64.Vec3 {\n\thits := world.Hit(r, Epsilon, math.MaxFloat64)\n\tif len(hits) > 0 {\n\t\t// HittableList makes sure the first (and only) intersection\n\t\t// is the closest one:\n\t\thit := hits[0]\n\t\t// Simulate the light response of this material.\n\t\tisScattered, attenuation, scattered := hit.Mat.Scatter(r, hit)\n\t\t// If this ray is reflected off the surface, determine the response\n\t\t// of the scattered ray:\n\t\tif isScattered && depth < MaxBounces {\n\t\t\tresponse := getColor(scattered, world, depth+1)\n\n\t\t\treturn mgl64.Vec3{response.X() * attenuation.X(),\n\t\t\t\tresponse.Y() * attenuation.Y(),\n\t\t\t\tresponse.Z() * attenuation.Z()}\n\t\t}\n\t\t// Otherwise, the ray was absorbed, or we have exceeded the\n\t\t// maximum number of light bounces:\n\t\treturn mgl64.Vec3{0.0, 0.0, 0.0}\n\t}\n\t// If we don't intersect with anything, plot a background instead:\n\tunitDirection := r.Direction().Normalize()\n\tt := 0.5*unitDirection.Y() + 1.0\n\t// Linearly interpolate between white and blue:\n\tA := mgl64.Vec3{1.0, 1.0, 1.0}.Mul(1.0 - t)\n\tB := mgl64.Vec3{0.5, 0.7, 1.0}.Mul(t)\n\treturn A.Add(B)\n}", "func d9nodeCover(node *d9nodeT) d9rectT {\n\trect := node.branch[0].rect\n\tfor index := 1; index < node.count; index++ {\n\t\trect = d9combineRect(&rect, &(node.branch[index].rect))\n\t}\n\treturn rect\n}", "func chooseColor(height int, lowColor bool) tl.Attr {\n\tif lowColor {\n\t\treturn tl.ColorGreen\n\t}\n\tidx := int(math.Sqrt(float64(height+1))) - 1\n\tif idx >= len(palette) {\n\t\tidx = len(palette) - 1\n\t}\n\treturn tl.Attr(palette[idx])\n}", "func rotateColorSpace(green_magenta, red_cyan, blue_yellow int) (red, green, blue int) {\n red = (green_magenta + blue_yellow )/2\n green = (red_cyan + blue_yellow )/2\n blue = (green_magenta + red_cyan )/2\n return\n}", "func d11nodeCover(node *d11nodeT) d11rectT {\n\trect := node.branch[0].rect\n\tfor index := 1; index < node.count; index++ {\n\t\trect = d11combineRect(&rect, &(node.branch[index].rect))\n\t}\n\treturn rect\n}", "func getTileColor(tile model.Tile) tcell.Style {\n\ttileColor := tcell.StyleDefault.Foreground(tcell.ColorBlack)\n\tswitch tile {\n\tcase 0:\n\t\ttileColor = tileColor.Background(tcell.ColorLightGrey)\n\tcase 2:\n\t\ttileColor = tileColor.Background(tcell.ColorDarkGrey)\n\tcase 4:\n\t\ttileColor = tileColor.Background(tcell.ColorSlateGrey)\n\tcase 8:\n\t\ttileColor = tileColor.Background(tcell.ColorGrey)\n\tcase 16:\n\t\ttileColor = tileColor.Background(tcell.ColorTeal)\n\tcase 32:\n\t\ttileColor = tileColor.Background(tcell.ColorTan)\n\tcase 64:\n\t\ttileColor = tileColor.Background(tcell.ColorOrange)\n\tcase 128:\n\t\ttileColor = tileColor.Background(tcell.ColorDarkOrange)\n\tcase 256:\n\t\ttileColor = tileColor.Background(tcell.ColorOrangeRed)\n\tcase 512:\n\t\ttileColor = tileColor.Background(tcell.ColorRed)\n\tcase 1024:\n\t\ttileColor = tileColor.Background(tcell.ColorDarkRed)\n\tcase 2048:\n\t\ttileColor = tileColor.Background(tcell.ColorDarkViolet)\n\tcase 4096:\n\t\ttileColor = tileColor.Background(tcell.ColorBlueViolet)\n\t// We don't have a lot of colors to work with so for now we'll make it boring\n\t// pass 4096.\n\tdefault:\n\t\ttileColor = tileColor.Background(tcell.ColorSlateGrey)\n\t}\n\treturn tileColor\n}", "func d1nodeCover(node *d1nodeT) d1rectT {\n\trect := node.branch[0].rect\n\tfor index := 1; index < node.count; index++ {\n\t\trect = d1combineRect(&rect, &(node.branch[index].rect))\n\t}\n\treturn rect\n}", "func d17nodeCover(node *d17nodeT) d17rectT {\n\trect := node.branch[0].rect\n\tfor index := 1; index < node.count; index++ {\n\t\trect = d17combineRect(&rect, &(node.branch[index].rect))\n\t}\n\treturn rect\n}", "func ClipTable(table Table, i, j, m, n int) Table {\n\tminR, minC := i, j\n\tmaxR, maxC := i+m, j+n\n\tif minR < 0 || minC < 0 || minR > maxR || minC > maxC || maxR >= table.RowCount() || maxC >= table.ColCount() {\n\t\tpanic(\"out of bound\")\n\t}\n\treturn &TableView{table, i, j, m, n}\n}", "func (c Chessboard) rookCastleKingsidePosition(color int) int {\n if color == 0 {\n return 63\n }\n\n return 7\n}", "func greedyColoringOf(g graph.Undirected, order graph.Nodes, partial map[int64]int) (k int, colors map[int64]int) {\n\tcolors = partial\n\tconstrained := false\n\tfor _, c := range colors {\n\t\tif c > k {\n\t\t\tk = c\n\t\t\tconstrained = true\n\t\t}\n\t}\n\n\t// Next nodes are chosen by the specified heuristic in order.\n\tfor order.Next() {\n\t\tuid := order.Node().ID()\n\t\tused := colorsOf(g.From(uid), colors)\n\t\tif c, ok := colors[uid]; ok {\n\t\t\tif used.Has(c) {\n\t\t\t\treturn -1, nil\n\t\t\t}\n\t\t\tcontinue\n\t\t}\n\t\t// Color the chosen vertex with the least possible\n\t\t// (lowest numbered) color.\n\t\tfor c := 0; c <= k+1; c++ {\n\t\t\tif !used.Has(c) {\n\t\t\t\tcolors[uid] = c\n\t\t\t\tif c > k {\n\t\t\t\t\tk = c\n\t\t\t\t}\n\t\t\t\tbreak\n\t\t\t}\n\t\t}\n\t}\n\n\tif !constrained {\n\t\treturn k + 1, colors\n\t}\n\tseen := make(set.Ints)\n\tfor _, c := range colors {\n\t\tseen.Add(c)\n\t}\n\treturn seen.Count(), colors\n}", "func colorizeMatches(line string, matches [][]int) string {\n\toutput := \"\"\n\tpointer := 0\n\tfor _, match := range matches {\n\t\tstart := match[0]\n\t\tend := match[1]\n\n\t\tif start >= pointer {\n\t\t\toutput += line[pointer:start]\n\t\t}\n\n\t\toutput += Bold(Red(line[start:end])).String()\n\t\tpointer = end\n\t}\n\n\tif pointer < (len(line) - 1) {\n\t\toutput += line[pointer:]\n\t}\n\treturn output\n}", "func d6nodeCover(node *d6nodeT) d6rectT {\n\trect := node.branch[0].rect\n\tfor index := 1; index < node.count; index++ {\n\t\trect = d6combineRect(&rect, &(node.branch[index].rect))\n\t}\n\treturn rect\n}", "func findEdge(numberOfColors int) int {\n //Indicating the thickness of the area around the diagonal by L, the number of nodes is found by solving the equation\n //n^3 -6Ln^2+(6L-1)n-numberOfColors = 0\n //Making the choice L=1/6 leads to a much simpler equation, and it's also a good choice for it as it leads to skipping around a third of the colors.\n delta := math.Cbrt((math.Sqrt(float64(27*27*numberOfColors*numberOfColors + 27*4*numberOfColors)) + float64(27*numberOfColors + 2))/2)\n return int(math.Ceil((delta + 1/delta + 1.)/3))\n}", "func (g grid) getRandomUnoccupiedPixelBlock() {\n\n}", "func shortestDistanceColor(colors []int, queries [][]int) []int {\n\tr := make([]int, 0)\n\t//data structure\n\t// brain storm:\n\t// 1) linked list\n\t// 2) hash\n\t// map[value int] indexes []int | ordered?\n\t// loop through colors to create map\n\t// check if the value exist\n\t// loop through indexes to find the lowest difference\n\t//\n\t// optionb) only 3 values not too much sense to hash it.\n\t//\n\t// O(1*ln(M) + N)\n\t// 3) list\n\t// brute force loop forward and backward until match\n\t// O(N)\n\t// Probably going with this\n\n\tfor _, v := range queries {\n\t\tshortest := -1\n\t\tfunc() {\n\t\t\tfor i := v[0]; i < len(colors); i++ {\n\n\t\t\t\tif v[1] == colors[i] {\n\t\t\t\t\tdistance := i - v[0]\n\t\t\t\t\tshortest = distance\n\t\t\t\t}\n\t\t\t}\n\t\t\tfor i := v[0]; i >= 0; i-- {\n\t\t\t\tdistance := v[0] - i\n\t\t\t\tif shortest != -1 {\n\t\t\t\t\tif distance < shortest {\n\t\t\t\t\t\tshortest = distance\n\t\t\t\t\t}\n\t\t\t\t} else {\n\t\t\t\t\tshortest = distance\n\t\t\t\t}\n\t\t\t}\n\t\t}()\n\t\tr = append(r, shortest)\n\t}\n\n\treturn r\n}", "func TableSetBgColorV(target TableBgTarget, color Vec4, columnN int) {\n\tcolorArg, _ := color.wrapped()\n\tC.iggTableSetBgColor(C.int(target), colorArg, C.int(columnN))\n}", "func print_color(chunks []Chunk) {\n\tc := 1\n\tfor i := range chunks {\n\t\tpayload := chunks[i].payload\n\t\ttag := chunks[i].tag\n\t\tvar x int\n\t\tif tag == \"\" {\n\t\t\tx = 7 // white\n\t\t} else {\n\t\t\tx = c\n\t\t\tc++\n\t\t\tif c > 6 {\n\t\t\t\tc = 1\n\t\t\t}\n\t\t}\n\t\tcolor := \"\\x1b[3\" + strconv.Itoa(x) + \"m\"\n\t\tfmt.Printf(\"%s%s\", color, payload)\n\t}\n\tfmt.Println()\n}", "func (table *Table) Draw(buf *Buffer) {\n\ttable.Block.Draw(buf)\n\n\ttable.drawLocation(buf)\n\ttable.drawUpdated(buf)\n\ttable.ColResizer()\n\n\tcolXPos := []int{}\n\tcur := 1 + table.PadLeft\n\tfor _, w := range table.ColWidths {\n\t\tcolXPos = append(colXPos, cur)\n\t\tcur += w\n\t\tcur += table.ColGap\n\t}\n\n\tfor i, h := range table.Header {\n\t\twidth := table.ColWidths[i]\n\t\tif width == 0 {\n\t\t\tcontinue\n\t\t}\n\n\t\tif width > (table.Inner.Dx()-colXPos[i])+1 {\n\t\t\tcontinue\n\t\t}\n\t\tbuf.SetString(\n\t\t\th,\n\t\t\tNewStyle(Theme.Default.Fg, ColorClear, ModifierBold),\n\t\t\timage.Pt(table.Inner.Min.X+colXPos[i]-1, table.Inner.Min.Y),\n\t\t)\n\t}\n\n\tif table.TopRow < 0 {\n\t\treturn\n\t}\n\n\tfor rowNum := table.TopRow; rowNum < table.TopRow+table.Inner.Dy()-1 && rowNum < len(table.Rows); rowNum++ {\n\t\trow := table.Rows[rowNum]\n\t\ty := (rowNum + 2) - table.TopRow\n\n\t\tstyle := NewStyle(Theme.Default.Fg)\n\t\tfor i, width := range table.ColWidths {\n\t\t\tif width == 0 {\n\t\t\t\tcontinue\n\t\t\t}\n\t\t\tif width > (table.Inner.Dx()-colXPos[i])+1 {\n\t\t\t\tcontinue\n\t\t\t}\n\t\t\tr := TrimString(row[i], width)\n\t\t\tif table.Styles[rowNum][i] != nil {\n\t\t\t\tbuf.SetString(\n\t\t\t\t\tr,\n\t\t\t\t\t*table.Styles[rowNum][i],\n\t\t\t\t\timage.Pt(table.Inner.Min.X+colXPos[i]-1, table.Inner.Min.Y+y-1),\n\t\t\t\t)\n\t\t\t} else {\n\t\t\t\tbuf.SetString(\n\t\t\t\t\tr,\n\t\t\t\t\tstyle,\n\t\t\t\t\timage.Pt(table.Inner.Min.X+colXPos[i]-1, table.Inner.Min.Y+y-1),\n\t\t\t\t)\n\t\t\t}\n\t\t}\n\t}\n}", "func (s *Service) setColorPairs() {\n\tswitch s.primaryColor {\n\tcase \"green\":\n\t\tgc.InitPair(1, gc.C_GREEN, gc.C_BLACK)\n\tcase \"cyan\", \"blue\":\n\t\tgc.InitPair(1, gc.C_CYAN, gc.C_BLACK)\n\tcase \"magenta\", \"pink\", \"purple\":\n\t\tgc.InitPair(1, gc.C_MAGENTA, gc.C_BLACK)\n\tcase \"white\":\n\t\tgc.InitPair(1, gc.C_WHITE, gc.C_BLACK)\n\tcase \"red\":\n\t\tgc.InitPair(1, gc.C_RED, gc.C_BLACK)\n\tcase \"yellow\", \"orange\":\n\t\tgc.InitPair(1, gc.C_YELLOW, gc.C_BLACK)\n\tdefault:\n\t\tgc.InitPair(1, gc.C_WHITE, gc.C_BLACK)\n\t}\n\n\tgc.InitPair(2, gc.C_BLACK, gc.C_BLACK)\n\tgc.InitPair(3, gc.C_BLACK, gc.C_GREEN)\n\tgc.InitPair(4, gc.C_BLACK, gc.C_CYAN)\n\tgc.InitPair(5, gc.C_WHITE, gc.C_BLUE)\n\tgc.InitPair(6, gc.C_BLACK, -1)\n}", "func d18nodeCover(node *d18nodeT) d18rectT {\n\trect := node.branch[0].rect\n\tfor index := 1; index < node.count; index++ {\n\t\trect = d18combineRect(&rect, &(node.branch[index].rect))\n\t}\n\treturn rect\n}", "func (t *table) appendBounds(cr *colReader) {\n\tbounds := []execute.Time{t.bounds.Start, t.bounds.Stop}\n\tfor j := range []int{startColIdx, stopColIdx} {\n\t\tb := arrow.NewIntBuilder(t.alloc)\n\t\tb.Reserve(cr.l)\n\t\tfor i := 0; i < cr.l; i++ {\n\t\t\tb.UnsafeAppend(int64(bounds[j]))\n\t\t}\n\t\tcr.cols[j] = b.NewArray()\n\t\tb.Release()\n\t}\n}", "func findAndIndex(abc *st.Art) (index1 int, index2 int) {\n\tsourse := abc.Flag.Color.ByIndex.Range\n\tlSourse := len(sourse)\n\n\tindex1 = sourse[0]\n\tindex2 = sourse[lSourse-1]\n\t// if wrong range, fix it\n\tif index1 > index2 {\n\t\tindex1, index2 = index2, index1\n\t}\n\treturn index1, index2\n}", "func d4nodeCover(node *d4nodeT) d4rectT {\n\trect := node.branch[0].rect\n\tfor index := 1; index < node.count; index++ {\n\t\trect = d4combineRect(&rect, &(node.branch[index].rect))\n\t}\n\treturn rect\n}", "func getTileFromColor(color *Color, tiles *[]TileImg, tolerance float64) *gmagick.MagickWand {\n\tvar matched = make([]int, 0)\n\t// compare color pixel with tolerance\n\tfor idx, tile := range *tiles {\n\t\tvar _matched = matchedPixels(color, tile.Color, tolerance)\n\t\tif _matched.Matched {\n\t\t\tmatched = append(matched, idx)\n\t\t}\n\t}\n\tif len(matched) > 0 {\n\t\tidx := getRandomItemIndex(len(matched))\n\t\tvar m = matched[idx]\n\t\treturn (*tiles)[m].Image\n\t}\n\treturn nil\n\n}", "func isGraphColouredProperly(graph [][]bool, V int, colour []int, v int, c int) bool {\n\tfor i := 0; i < V; i++ {\n\t\tif graph[v][i] && c == colour[i] {\n\t\t\treturn false\n\t\t}\n\t}\n\treturn true\n}", "func tableSetUp(m, n int) *[][]int {\n\tresult := make([][]int, m)\n\tfor i := range result {\n\t\tresult[i] = make([]int, n)\n\t}\n\tfor c := range result[0] {\n\t\tresult[0][c] = c\n\t}\n\tfor r := 0; r < len(result); r++ {\n\t\tresult[r][0] = r\n\t}\n\n\treturn &result\n}", "func (c *Colorscheme) tcellColor(name string) tcell.Color {\n\tv, ok := c.colors[name].(string)\n\tif !ok {\n\t\treturn tcell.ColorDefault\n\t}\n\n\tif color, found := TcellColorschemeColorsMap[v]; found {\n\t\treturn color\n\t}\n\n\tcolor := tcell.GetColor(v)\n\tif color != tcell.ColorDefault {\n\t\treturn color\n\t}\n\n\t// find closest X11 color to RGB\n\t// if code, ok := HexToAnsi(v); ok {\n\t// \treturn tcell.PaletteColor(int(code) & 0xff)\n\t// }\n\treturn color\n}", "func ScissorIndexed(index uint32, left int32, bottom int32, width int32, height int32) {\n C.glowScissorIndexed(gpScissorIndexed, (C.GLuint)(index), (C.GLint)(left), (C.GLint)(bottom), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func (l LCDControl) TilePatternTableAddress() mmu.Range {\n\tif binary.Bit(4, byte(l)) == 0 {\n\t\treturn mmu.Range{\n\t\t\tStart: 0x8800, End: 0x97FF,\n\t\t}\n\t}\n\treturn mmu.Range{\n\t\tStart: 0x8000, End: 0x8FFF,\n\t}\n}", "func (b box) color() color.NRGBA {\n\treturn b.col\n}", "func drawCell(rectImg *image.RGBA, x, y, size int) {\n\trectLine := image.NewRGBA(image.Rect(x, y, x+size, y+size))\n\t//COLOR\n\tgreyRect := color.RGBA{169, 169, 169, 255}\n\tblackRect := color.RGBA{0, 0, 0, 230}\n\n\tif flagColor{\n\t\tdraw.Draw(rectImg, rectLine.Bounds(), &image.Uniform{blackRect}, image.ZP, draw.Src)\n\t}else {\n\t\tdraw.Draw(rectImg, rectLine.Bounds(), &image.Uniform{greyRect}, image.ZP, draw.Src)\n\t}\n}", "func setcolor(what string, level int, str string) string {\n\tRet := \"\"\n\tswitch colors[level] {\n\tcase \"Black\":\n\t\tRet = color.Black(str)\n\tcase \"Red\":\n\t\tRet = color.Red(str)\n\tcase \"Green\":\n\t\tRet = color.Green(str)\n\tcase \"Yellow\":\n\t\tRet = color.Yellow(str)\n\tcase \"Blue\":\n\t\tRet = color.Blue(str)\n\tcase \"Purple\":\n\t\tRet = color.Purple(str)\n\tcase \"Cyan\":\n\t\tRet = color.Cyan(str)\n\tcase \"LightGray\":\n\t\tRet = color.LightGray(str)\n\tcase \"DarkGray\":\n\t\tRet = color.DarkGray(str)\n\tcase \"LightRed\":\n\t\tRet = color.LightRed(str)\n\tcase \"LightGreen\":\n\t\tRet = color.LightGreen(str)\n\tcase \"LightYellow\":\n\t\tRet = color.LightYellow(str)\n\tcase \"LightBlue\":\n\t\tRet = color.LightBlue(str)\n\tcase \"LightPurple\":\n\t\tRet = color.LightPurple(str)\n\tcase \"LightCyan\":\n\t\tRet = color.LightCyan(str)\n\tcase \"White\":\n\t\tRet = color.White(str)\n\t// bold\n\tcase \"BBlack\":\n\t\tRet = color.BBlack(str)\n\tcase \"BRed\":\n\t\tRet = color.BRed(str)\n\tcase \"BGreen\":\n\t\tRet = color.BGreen(str)\n\tcase \"BYellow\":\n\t\tRet = color.BYellow(str)\n\tcase \"BBlue\":\n\t\tRet = color.BBlue(str)\n\tcase \"BPurple\":\n\t\tRet = color.BPurple(str)\n\tcase \"BCyan\":\n\t\tRet = color.BCyan(str)\n\tcase \"BLightGray\":\n\t\tRet = color.BLightGray(str)\n\tcase \"BDarkGray\":\n\t\tRet = color.BDarkGray(str)\n\tcase \"BLightRed\":\n\t\tRet = color.BLightRed(str)\n\tcase \"BLightGreen\":\n\t\tRet = color.BLightGreen(str)\n\tcase \"BLightYellow\":\n\t\tRet = color.BLightYellow(str)\n\tcase \"BLightBlue\":\n\t\tRet = color.BLightBlue(str)\n\tcase \"BLightPurple\":\n\t\tRet = color.BLightPurple(str)\n\tcase \"BLightCyan\":\n\t\tRet = color.BLightCyan(str)\n\tcase \"BWhite\":\n\t\tRet = color.BWhite(str)\n\t// background\n\tcase \"GBlack\":\n\t\tRet = color.GBlack(str)\n\tcase \"GRed\":\n\t\tRet = color.GRed(str)\n\tcase \"GGreen\":\n\t\tRet = color.GGreen(str)\n\tcase \"GYellow\":\n\t\tRet = color.GYellow(str)\n\tcase \"GBlue\":\n\t\tRet = color.GBlue(str)\n\tcase \"GPurple\":\n\t\tRet = color.GPurple(str)\n\tcase \"GCyan\":\n\t\tRet = color.GCyan(str)\n\tcase \"GLightGray\":\n\t\tRet = color.GLightGray(str)\n\tcase \"GDarkGray\":\n\t\tRet = color.GDarkGray(str)\n\tcase \"GLightRed\":\n\t\tRet = color.GLightRed(str)\n\tcase \"GLightGreen\":\n\t\tRet = color.GLightGreen(str)\n\tcase \"GLightYellow\":\n\t\tRet = color.GLightYellow(str)\n\tcase \"GLightBlue\":\n\t\tRet = color.GLightBlue(str)\n\tcase \"GLightPurple\":\n\t\tRet = color.GLightPurple(str)\n\tcase \"GLightCyan\":\n\t\tRet = color.GLightCyan(str)\n\tcase \"GWhite\":\n\t\tRet = color.GWhite(str)\n\t// special\n\tcase \"Bold\":\n\t\tRet = color.Bold(str)\n\tcase \"Dim\":\n\t\tRet = color.Dim(str)\n\tcase \"Underline\":\n\t\tRet = color.Underline(str)\n\tcase \"Invert\":\n\t\tRet = color.Invert(str)\n\tcase \"Hide\":\n\t\tRet = color.Hide(str)\n\tcase \"Blink\":\n\t\tRet = color.Blink(str) // blinking works only on mac\n\tdefault:\n\t\tRet = str\n\t}\n\treturn Ret\n}", "func Hsl(h, s, l float64) Color {\r\n if s == 0 {\r\n return Color{l, l, l}\r\n }\r\n\r\n var r, g, b float64\r\n var t1 float64\r\n var t2 float64\r\n var tr float64\r\n var tg float64\r\n var tb float64\r\n\r\n if l < 0.5 {\r\n t1 = l * (1.0 + s)\r\n } else {\r\n t1 = l + s - l*s\r\n }\r\n\r\n t2 = 2*l - t1\r\n h = h / 360\r\n tr = h + 1.0/3.0\r\n tg = h\r\n tb = h - 1.0/3.0\r\n\r\n if tr < 0 {\r\n tr += 1\r\n }\r\n if tr > 1 {\r\n tr -= 1\r\n }\r\n if tg < 0 {\r\n tg += 1\r\n }\r\n if tg > 1 {\r\n tg -= 1\r\n }\r\n if tb < 0 {\r\n tb += 1\r\n }\r\n if tb > 1 {\r\n tb -= 1\r\n }\r\n\r\n // Red\r\n if 6*tr < 1 {\r\n r = t2 + (t1-t2)*6*tr\r\n } else if 2*tr < 1 {\r\n r = t1\r\n } else if 3*tr < 2 {\r\n r = t2 + (t1-t2)*(2.0/3.0-tr)*6\r\n } else {\r\n r = t2\r\n }\r\n\r\n // Green\r\n if 6*tg < 1 {\r\n g = t2 + (t1-t2)*6*tg\r\n } else if 2*tg < 1 {\r\n g = t1\r\n } else if 3*tg < 2 {\r\n g = t2 + (t1-t2)*(2.0/3.0-tg)*6\r\n } else {\r\n g = t2\r\n }\r\n\r\n // Blue\r\n if 6*tb < 1 {\r\n b = t2 + (t1-t2)*6*tb\r\n } else if 2*tb < 1 {\r\n b = t1\r\n } else if 3*tb < 2 {\r\n b = t2 + (t1-t2)*(2.0/3.0-tb)*6\r\n } else {\r\n b = t2\r\n }\r\n\r\n return Color{r, g, b}\r\n}", "func d20nodeCover(node *d20nodeT) d20rectT {\n\trect := node.branch[0].rect\n\tfor index := 1; index < node.count; index++ {\n\t\trect = d20combineRect(&rect, &(node.branch[index].rect))\n\t}\n\treturn rect\n}", "func (g *GMRES) hcol(j int) []float64 {\n\tldh := g.m + 1\n\treturn g.ht[j*ldh : (j+1)*ldh]\n}", "func d12nodeCover(node *d12nodeT) d12rectT {\n\trect := node.branch[0].rect\n\tfor index := 1; index < node.count; index++ {\n\t\trect = d12combineRect(&rect, &(node.branch[index].rect))\n\t}\n\treturn rect\n}", "func cellColor(c cell.Color) tcell.Color {\n\tif c == cell.ColorDefault {\n\t\treturn tcell.ColorDefault\n\t}\n\t// Subtract one, because cell.ColorBlack has value one instead of zero.\n\t// Zero is used for cell.ColorDefault instead.\n\treturn tcell.Color(c-1) + tcell.ColorValid\n}", "func (b *BoardTest) TestQuickColors(t *C) {\n\tl := new(RGBLED, 9, 10, 11)\n\tvar cs = map[string][3]byte{\n\t\t\"red\": [3]byte{0xFF, 00, 00},\n\t\t\"green\": [3]byte{00, 0xFF, 00},\n\t\t\"blue\": [3]byte{00, 00, 0xFF},\n\t\t\"black\": [3]byte{00, 00, 00},\n\t\t\"white\": [3]byte{0xFF, 0xFF, 0xFF},\n\t}\n\tfor c, v := range cs {\n\t\tl.QuickColor(c)\n\t\tt.Check(l.Red, Equals, v[0])\n\t\tt.Check(l.Green, Equals, v[1])\n\t\tt.Check(l.Blue, Equals, v[2])\n\t}\n}", "func d13nodeCover(node *d13nodeT) d13rectT {\n\trect := node.branch[0].rect\n\tfor index := 1; index < node.count; index++ {\n\t\trect = d13combineRect(&rect, &(node.branch[index].rect))\n\t}\n\treturn rect\n}", "func d5nodeCover(node *d5nodeT) d5rectT {\n\trect := node.branch[0].rect\n\tfor index := 1; index < node.count; index++ {\n\t\trect = d5combineRect(&rect, &(node.branch[index].rect))\n\t}\n\treturn rect\n}", "func colorsOf(nodes graph.Nodes, coloring map[int64]int) set.Ints {\n\tc := make(set.Ints, nodes.Len())\n\tfor nodes.Next() {\n\t\tused, ok := coloring[nodes.Node().ID()]\n\t\tif ok {\n\t\t\tc.Add(used)\n\t\t}\n\t}\n\treturn c\n}", "func (x *ImgSpanner) SpanFgColor(yi, xi0, xi1 int, ma uint32) {\n\ti0 := (yi)*x.stride + (xi0)*4\n\ti1 := i0 + (xi1-xi0)*4\n\t// uses the Porter-Duff composition operator.\n\tcr, cg, cb, ca := x.fgColor.RGBA()\n\tama := ca * ma\n\tif ama == 0xFFFF*0xFFFF { // undercolor is ignored\n\t\trmb := uint8(cr * ma / mp)\n\t\tgmb := uint8(cg * ma / mp)\n\t\tbmb := uint8(cb * ma / mp)\n\t\tamb := uint8(ama / mp)\n\t\tfor i := i0; i < i1; i += 4 {\n\t\t\tx.pix[i+0] = rmb\n\t\t\tx.pix[i+1] = gmb\n\t\t\tx.pix[i+2] = bmb\n\t\t\tx.pix[i+3] = amb\n\t\t}\n\t\treturn\n\t}\n\trma := cr * ma\n\tgma := cg * ma\n\tbma := cb * ma\n\ta := (m - (ama / m)) * pa\n\tfor i := i0; i < i1; i += 4 {\n\t\tx.pix[i+0] = uint8((uint32(x.pix[i+0])*a + rma) / mp)\n\t\tx.pix[i+1] = uint8((uint32(x.pix[i+1])*a + gma) / mp)\n\t\tx.pix[i+2] = uint8((uint32(x.pix[i+2])*a + bma) / mp)\n\t\tx.pix[i+3] = uint8((uint32(x.pix[i+3])*a + ama) / mp)\n\t}\n}" ]
[ "0.7169887", "0.6995501", "0.68756604", "0.61563814", "0.6053618", "0.5870142", "0.572057", "0.54090625", "0.5268068", "0.5217324", "0.5199247", "0.51871884", "0.5184359", "0.51665777", "0.5125286", "0.5103398", "0.509819", "0.5085142", "0.5067481", "0.50626045", "0.5054786", "0.5054786", "0.5042424", "0.50336534", "0.5008503", "0.4975407", "0.49391797", "0.49195895", "0.490381", "0.48778984", "0.4873281", "0.48655534", "0.48577544", "0.48415816", "0.4830478", "0.4826598", "0.4822823", "0.48151708", "0.4805355", "0.48027042", "0.47905463", "0.4786877", "0.47745356", "0.47678155", "0.4740655", "0.47398892", "0.4737554", "0.47304115", "0.47238773", "0.47177628", "0.47149423", "0.4707004", "0.47064972", "0.47012928", "0.46940535", "0.467435", "0.46731883", "0.46692616", "0.46688527", "0.46647125", "0.46632978", "0.46622315", "0.46577463", "0.4656629", "0.46521655", "0.4635064", "0.4599794", "0.4598576", "0.45982486", "0.4594544", "0.45940018", "0.45824838", "0.4582404", "0.45818678", "0.45813406", "0.4580641", "0.45738462", "0.45650902", "0.456462", "0.45615774", "0.4561139", "0.45605904", "0.4553223", "0.4551032", "0.4547096", "0.45452031", "0.4544669", "0.45431784", "0.45396078", "0.4536519", "0.45251036", "0.4523833", "0.45230514", "0.45203233", "0.45171833", "0.45146677", "0.4506833", "0.45035705", "0.4502162", "0.4500437" ]
0.6508021
3
copy pixels into a color table
func CopyColorTable(target uint32, internalformat uint32, x int32, y int32, width int32) { C.glowCopyColorTable(gpCopyColorTable, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func CopyColorTable(target uint32, internalformat uint32, x int32, y int32, width int32) {\n C.glowCopyColorTable(gpCopyColorTable, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func CopyColorSubTable(target uint32, start int32, x int32, y int32, width int32) {\n C.glowCopyColorSubTable(gpCopyColorSubTable, (C.GLenum)(target), (C.GLsizei)(start), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func CopyColorSubTable(target uint32, start int32, x int32, y int32, width int32) {\n\tC.glowCopyColorSubTable(gpCopyColorSubTable, (C.GLenum)(target), (C.GLsizei)(start), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func ColorSubTable(target uint32, start int32, count int32, format uint32, xtype uint32, data unsafe.Pointer) {\n C.glowColorSubTable(gpColorSubTable, (C.GLenum)(target), (C.GLsizei)(start), (C.GLsizei)(count), (C.GLenum)(format), (C.GLenum)(xtype), data)\n}", "func ColorTable(target uint32, internalformat uint32, width int32, format uint32, xtype uint32, table unsafe.Pointer) {\n C.glowColorTable(gpColorTable, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), table)\n}", "func ColorSubTable(target uint32, start int32, count int32, format uint32, xtype uint32, data unsafe.Pointer) {\n\tC.glowColorSubTable(gpColorSubTable, (C.GLenum)(target), (C.GLsizei)(start), (C.GLsizei)(count), (C.GLenum)(format), (C.GLenum)(xtype), data)\n}", "func CopyPixels(x int32, y int32, width int32, height int32, xtype uint32) {\n C.glowCopyPixels(gpCopyPixels, (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(xtype))\n}", "func ColorTable(target uint32, internalformat uint32, width int32, format uint32, xtype uint32, table unsafe.Pointer) {\n\tC.glowColorTable(gpColorTable, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), table)\n}", "func CopyPixels(x int32, y int32, width int32, height int32, xtype uint32) {\n\tsyscall.Syscall6(gpCopyPixels, 5, uintptr(x), uintptr(y), uintptr(width), uintptr(height), uintptr(xtype), 0)\n}", "func CopyPixels(x int32, y int32, width int32, height int32, xtype uint32) {\n\tC.glowCopyPixels(gpCopyPixels, (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(xtype))\n}", "func setPixel(x, y int, c color, pixels []byte) {\n\tindex := (y*windowWidth + x) * 4\n\n\tif index < len(pixels)-4 && index >= 0 {\n\t\tpixels[index] = c.r\n\t\tpixels[index+1] = c.g\n\t\tpixels[index+1] = c.b\n\t}\n}", "func (c *Canvas) copyTo(offset image.Point, dstSetCell setCellFunc) error {\n\tfor col := range c.buffer {\n\t\tfor row := range c.buffer[col] {\n\t\t\tpartial, err := c.buffer.IsPartial(image.Point{col, row})\n\t\t\tif err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\t\t\tif partial {\n\t\t\t\t// Skip over partial cells, i.e. cells that follow a cell\n\t\t\t\t// containing a full-width rune. A full-width rune takes only\n\t\t\t\t// one cell in the buffer, but two on the terminal.\n\t\t\t\t// See http://www.unicode.org/reports/tr11/.\n\t\t\t\tcontinue\n\t\t\t}\n\t\t\tcell := c.buffer[col][row]\n\t\t\tp := image.Point{col, row}.Add(offset)\n\t\t\tif err := dstSetCell(p, cell.Rune, cell.Opts); err != nil {\n\t\t\t\treturn fmt.Errorf(\"setCellFunc%v => error: %v\", p, err)\n\t\t\t}\n\t\t}\n\t}\n\treturn nil\n}", "func GetColorTable(target uint32, format uint32, xtype uint32, table unsafe.Pointer) {\n C.glowGetColorTable(gpGetColorTable, (C.GLenum)(target), (C.GLenum)(format), (C.GLenum)(xtype), table)\n}", "func putPixel(screen []byte, color color, x int, y int) {\n\tscreenX := (windowWidth / 2) + x\n\tscreenY := (windowHeight / 2) - y - 1\n\tbase := (screenY*windowWidth + screenX) * 4\n\tscreen[base] = color.r\n\tscreen[base+1] = color.g\n\tscreen[base+2] = color.b\n\tscreen[base+3] = 0xFF\n\tscreen[0] = 0xFF\n}", "func setPixel(x, y int, c color, pixels []byte) error {\n\tindex := (y*int(winWidth) + x) * 4\n\n\tif index > len(pixels) || index < 0 {\n\t\t// simple string-based error\n\t\treturn fmt.Errorf(\"the pixel index is not valid, index: %d\", index)\n\t}\n\n\tif index < len(pixels) && index >= 0 {\n\t\tpixels[index] = c.r\n\t\tpixels[index+1] = c.g\n\t\tpixels[index+2] = c.b\n\t}\n\n\treturn nil\n}", "func setPixel(x, y int, c color, pixels []byte) error {\n\tindex := (y*int(winWidth) + x) * 4\n\n\tif index > len(pixels) || index < 0 {\n\t\t// simple string-based error\n\t\treturn fmt.Errorf(\"the pixel index is not valid, index: %d\", index)\n\t}\n\n\tif index < len(pixels) && index >= 0 {\n\t\tpixels[index] = c.r\n\t\tpixels[index+1] = c.g\n\t\tpixels[index+2] = c.b\n\t}\n\n\treturn nil\n}", "func GenColor(intr int) [][]uint8 {\n\toutput := [][]uint8{}\n\tfor i := 0; i <= 255; i += intr {\n\t\tfor j := 0; j <= 255; j += intr {\n\t\t\tfor k := 0; k <= 255; k += intr {\n\t\t\t\ta := []uint8{uint8(i), uint8(j), uint8(k)}\n\t\t\t\toutput = append(output, a)\n\n\t\t\t}\n\t\t}\n\t}\n\treturn output\n\n}", "func (i *ImageBuf) CopyPixels(src *ImageBuf) error {\n\tok := bool(C.ImageBuf_copy_pixels(i.ptr, src.ptr))\n\truntime.KeepAlive(i)\n\truntime.KeepAlive(src)\n\tif !ok {\n\t\treturn i.LastError()\n\t}\n\treturn nil\n}", "func (fr *Frame) Copy(orig *Frame) {\n\tfr.Status = orig.Status\n\tfor y, row := range orig.Pix {\n\t\tcopy(fr.Pix[y][:], row)\n\t}\n}", "func drawTilePixels(image *image.RGBA, pixel [8][8]color.RGBA, xOffset int, yOffset int) *image.RGBA {\n\tfor x := 0; x < TileWidth; x++ {\n\t\tfor y := 0; y < TileHeight; y++ {\n\t\t\timage.SetRGBA(xOffset*TileWidth+x, yOffset*TileHeight+y, pixel[y][x])\n\t\t}\n\t}\n\treturn image\n}", "func GetColorTable(target uint32, format uint32, xtype uint32, table unsafe.Pointer) {\n\tC.glowGetColorTable(gpGetColorTable, (C.GLenum)(target), (C.GLenum)(format), (C.GLenum)(xtype), table)\n}", "func Copy(i ImageIr) ImageIr {\n\tc := make([][][]uint32, len(i.pixels))\n\tcopy(c, i.pixels)\n\treturn ImageIr{i.width, i.height, c}\n}", "func Copy(dst draw.Image, src image.Image) {\n\tbd := src.Bounds().Intersect(dst.Bounds())\n\tat := imageutil.NewAtFunc(src)\n\tset := imageutil.NewSetFunc(dst)\n\timageutil.Parallel1D(bd, func(bd image.Rectangle) {\n\t\tfor y := bd.Min.Y; y < bd.Max.Y; y++ {\n\t\t\tfor x := bd.Min.X; x < bd.Max.X; x++ {\n\t\t\t\tr, g, b, a := at(x, y)\n\t\t\t\tset(x, y, r, g, b, a)\n\t\t\t}\n\t\t}\n\t})\n}", "func tileToPixel(tileIndex uint8, mem *GBMem) [TileHeight][TileWidth]color.RGBA {\n\tvar pixels [TileHeight][TileWidth]color.RGBA\n\tfor y := 0; y < TileHeight; y++ {\n\t\tvar line [TileWidth]color.RGBA\n\t\tlsb := mem.vram[int(tileIndex)*16+2*y]\n\t\thsb := mem.vram[int(tileIndex)*16+2*y+1]\n\n\t\tfor x := 0; x < TileWidth; x++ {\n\t\t\tline[TileWidth-1-x] = paletteMap[compositePixel(lsb, hsb, uint8(x))]\n\t\t}\n\t\tpixels[y] = line\n\t}\n\treturn pixels\n}", "func newColorsImage(width, height int, colors []colorFreq, save bool) image.Image {\n\timg := image.NewRGBA(image.Rectangle{image.Point{0, 0}, image.Point{width, height}})\n\tvar xStart, xEnd int\n\t// for each color, calculate the start and end x positions, then fill in the column\n\tfor i, c := range colors {\n\t\tif i == 0 {\n\t\t\txStart = 0\n\t\t} else {\n\t\t\txStart = xEnd\n\t\t}\n\t\txEnd = xStart + int(c.freq*float32(width))\n\n\t\tfor x := xStart; x < xEnd; x++ {\n\t\t\tfor y := 0; y < height; y++ {\n\t\t\t\timg.Set(x, y, c.color)\n\t\t\t}\n\t\t}\n\t}\n\n\tif save {\n\t\tout, _ := os.Create(\"./newColorsImage.png\")\n\t\tjpeg.Encode(out, img, nil)\n\t}\n\n\treturn img\n}", "func CopyTexImage2D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, height int32, border int32) {\n C.glowCopyTexImage2D(gpCopyTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border))\n}", "func (c *Canvas) pixelate(data []uint8, rect image.Rectangle, noiseLevel int) []uint8 {\n\t// Converts the array buffer to an image\n\timg := pixels.PixToImage(data, rect)\n\n\t// Quantize the substracted image in order to reduce the number of colors.\n\t// This will create a new pixelated subtype image.\n\tcell := quant.Draw(img, c.numOfColors, c.cellSize, noiseLevel)\n\n\tdst := image.NewNRGBA(cell.Bounds())\n\tdraw.Draw(dst, cell.Bounds(), cell, image.Point{}, draw.Over)\n\n\treturn pixels.ImgToPix(dst)\n}", "func (i *Image) readPixelsFromGPU() error {\n\tvar err error\n\ti.basePixels, err = i.image.Pixels()\n\tif err != nil {\n\t\treturn err\n\t}\n\ti.drawImageHistory = nil\n\ti.stale = false\n\treturn nil\n}", "func SetPixel(x, y int, c [4]byte, pixels *[]byte) {\n\tindex := (y* int(cfg.COLS*cfg.CELL_SIZE) + x) * 4\n\n\tif index < len(*pixels)-4 && index >= 0 {\n\t\t(*pixels)[index] = c[0]\n\t\t(*pixels)[index+1] = c[1]\n\t\t(*pixels)[index+2] = c[2]\t\n\t\t(*pixels)[index+3] = c[3]\t\n\t}\n}", "func SetPixel(n, r, g, b uint8) {\n\tbuffer[n*3] = g\n\tbuffer[n*3+1] = r\n\tbuffer[n*3+2] = b\n}", "func clone(dst, src *image.Gray) {\n\tif dst.Stride == src.Stride {\n\t\t// no need to correct stride, simply copy pixels.\n\t\tcopy(dst.Pix, src.Pix)\n\t\treturn\n\t}\n\t// need to correct stride.\n\tfor i := 0; i < src.Rect.Dy(); i++ {\n\t\tdstH := i * dst.Stride\n\t\tsrcH := i * src.Stride\n\t\tcopy(dst.Pix[dstH:dstH+dst.Stride], src.Pix[srcH:srcH+dst.Stride])\n\t}\n}", "func PreparePic(dx, dy int) [][]uint8 {\n\trows := make([][]uint8, dy)\n\tfor i := range rows {\n\t\trows[i] = make([]uint8, dx)\n\t}\n\treturn rows\n}", "func CopyTexImage2D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, height int32, border int32) {\n\tC.glowCopyTexImage2D(gpCopyTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border))\n}", "func CopyTexImage2D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, height int32, border int32) {\n\tC.glowCopyTexImage2D(gpCopyTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border))\n}", "func (fb FrameBuffer) ColorAt(x int, y int) color.Color {\n\tc := fb.img.At(x, y)\n\treturn c\n}", "func (img *ByteImage) pixels() [][]byte {\n\tbyteIdx := 0\n\tpixels := make([][]byte, img.height)\n\tfor rowIdx := 0; rowIdx < img.height; rowIdx++ {\n\t\tpixels[rowIdx] = make([]byte, img.width)\n\t\tfor colIdx := 0; colIdx < img.width; colIdx++ {\n\t\t\tpixels[rowIdx][colIdx] = img.bytes[byteIdx]\n\t\t\tbyteIdx++\n\t\t}\n\t}\n\treturn pixels\n}", "func eachPixel(img image.Image, f func(int, int, color.Color)) {\n\tr := img.Bounds()\n\tfor y := r.Min.Y; y < r.Max.Y; y++ {\n\t\tfor x := r.Min.X; x < r.Max.X; x++ {\n\t\t\tf(x, y, img.At(x, y))\n\t\t}\n\t}\n}", "func CopyTexImage2D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, height int32, border int32) {\n\tsyscall.Syscall9(gpCopyTexImage2D, 8, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(x), uintptr(y), uintptr(width), uintptr(height), uintptr(border), 0)\n}", "func extractSwatches(src *image.RGBA, numColors int) []colorful.Color {\n\tconst (\n\t\tW = 400\n\t\tH = 75\n\t)\n\tvar swatches []colorful.Color\n\tb := src.Bounds()\n\tsw := W / numColors\n\tfor i := 0; i < numColors; i++ {\n\t\tm := src.SubImage(trimRect(image.Rect(b.Min.X+i*sw, b.Max.Y-H, b.Min.X+(i+1)*sw, b.Max.Y), 10))\n\t\tswatches = append(swatches, toColorful(averageColor(m)))\n\t\tsavePNG(strconv.Itoa(i), m) // for debugging\n\t}\n\tconst dim = 50\n\tm := image.NewRGBA(image.Rect(0, 0, dim*len(swatches), dim))\n\tfor i, c := range swatches {\n\t\tr := image.Rect(i*dim, 0, (i+1)*dim, dim)\n\t\tdraw.Draw(m, r, &image.Uniform{fromColorful(c)}, image.ZP, draw.Src)\n\t}\n\tsavePNG(\"swatches\", m) // for debugging\n\treturn swatches\n}", "func p256Select(point, table []uint64, idx int)", "func p256Select(point, table []uint64, idx int)", "func (img Image) groupPixelOverColor() map[color.Color]int {\n\tcol := img.height\n\trow := img.width\n\n\tm := make(map[color.Color]int)\n\tfor i := 0; i < col*row; i++ {\n\n\t\tr, g, b, a := getP9RGBA(img.pixels[i])\n\t\tcurrentColor := color.RGBA{r, g, b, a}\n\n\t\tif _, ok := m[currentColor]; ok {\n\t\t\tm[currentColor]++\n\t\t} else {\n\t\t\tm[currentColor] = 0\n\t\t}\n\t}\n\n\treturn m\n}", "func (c *Canvas) pixToImage(pixels []uint8, dim int) image.Image {\n\tc.frame = image.NewNRGBA(image.Rect(0, 0, dim, dim))\n\tbounds := c.frame.Bounds()\n\tdx, dy := bounds.Max.X, bounds.Max.Y\n\tcol := color.NRGBA{\n\t\tR: uint8(0),\n\t\tG: uint8(0),\n\t\tB: uint8(0),\n\t\tA: uint8(255),\n\t}\n\n\tfor y := bounds.Min.Y; y < dy; y++ {\n\t\tfor x := bounds.Min.X; x < dx*4; x += 4 {\n\t\t\tcol.R = uint8(pixels[x+y*dx*4])\n\t\t\tcol.G = uint8(pixels[x+y*dx*4+1])\n\t\t\tcol.B = uint8(pixels[x+y*dx*4+2])\n\t\t\tcol.A = uint8(pixels[x+y*dx*4+3])\n\n\t\t\tc.frame.SetNRGBA(y, int(x/4), col)\n\t\t}\n\t}\n\treturn c.frame\n}", "func ColorPointer(size int32, xtype uint32, stride int32, pointer unsafe.Pointer) {\n C.glowColorPointer(gpColorPointer, (C.GLint)(size), (C.GLenum)(xtype), (C.GLsizei)(stride), pointer)\n}", "func hLine(img *image.NRGBA, x1, y, x2 int, col color.Color) {\r\n\tfor ; x1 <= x2; x1++ {\r\n\t\timg.Set(x1, y, col)\r\n\t}\r\n}", "func SwitchData(x, y gb.UINT8, src, dst []gb.UINT8) {}", "func ReadPixels(dst []byte, x, y, width, height int, format, ty Enum) {\n\tgl.ReadPixels(int32(x), int32(y), int32(width), int32(height), uint32(format), uint32(ty), gl.Ptr(&dst[0]))\n}", "func CopyTexImage2D(target Enum, level Int, internalformat Enum, x Int, y Int, width Sizei, height Sizei, border Int) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tclevel, _ := (C.GLint)(level), cgoAllocsUnknown\n\tcinternalformat, _ := (C.GLenum)(internalformat), cgoAllocsUnknown\n\tcx, _ := (C.GLint)(x), cgoAllocsUnknown\n\tcy, _ := (C.GLint)(y), cgoAllocsUnknown\n\tcwidth, _ := (C.GLsizei)(width), cgoAllocsUnknown\n\tcheight, _ := (C.GLsizei)(height), cgoAllocsUnknown\n\tcborder, _ := (C.GLint)(border), cgoAllocsUnknown\n\tC.glCopyTexImage2D(ctarget, clevel, cinternalformat, cx, cy, cwidth, cheight, cborder)\n}", "func (fb *FrameBuffer) SetColorAt(x int, y int, c color.Color) {\n\tif x >= 0 && y >= 0 && x < fb.width && y < fb.height {\n\t\tfb.img.Set(x, y, c) // = c\n\t}\n}", "func CopyTexImage1D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, border int32) {\n C.glowCopyTexImage1D(gpCopyTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLint)(border))\n}", "func reflectPixels(pixels [7][7]bool) [7][7]bool {\n\t// Reflect over the middle line\n\tfor i := 0; i < 7; i++ {\n\t\tfor j := 0; j < 7; j++ {\n\t\t\tpixels[6-i][j] = pixels[i][j]\n\t\t}\n\t}\n\treturn pixels\n}", "func ColorPointer(size int32, xtype uint32, stride int32, pointer unsafe.Pointer) {\n\tsyscall.Syscall6(gpColorPointer, 4, uintptr(size), uintptr(xtype), uintptr(stride), uintptr(pointer), 0, 0)\n}", "func (p *RGBAf) Set(x, y int, c color.Color) {\n\tif !(image.Point{x, y}.In(p.Rect)) {\n\t\treturn\n\t}\n\ti := p.PixOffset(x, y)\n\tc1 := color.RGBAModel.Convert(c).(color.RGBA)\n\ts := p.Pix[i : i+4 : i+4] // Small cap improves performance, see https://golang.org/issue/27857\n\ts[0] = float32(c1.R)\n\ts[1] = float32(c1.G)\n\ts[2] = float32(c1.B)\n\ts[3] = float32(c1.A)\n}", "func getHistogram(src [][3]int, size float64, pixels *[HistSize][3]float64, hist *[HistSize]float64) {\n\tvar ind, r, g, b, i int\n\tvar inr, ing, inb int\n\n\tfor i = range src {\n\t\tr = src[i][0]\n\t\tg = src[i][1]\n\t\tb = src[i][2]\n\n\t\tinr = r >> Shift\n\t\ting = g >> Shift\n\t\tinb = b >> Shift\n\n\t\tind = (inr << (2 * HistBits)) + (ing << HistBits) + inb\n\t\tpixels[ind][0], pixels[ind][1], pixels[ind][2] = float64(r), float64(g), float64(b)\n\t\thist[ind]++\n\t}\n\n\t// normalize weight by the number of pixels in the image\n\tfor i = 0; i < HistSize; i++ {\n\t\thist[i] /= size\n\t}\n}", "func dHash(img image.Image) (bits [2]uint64) {\n\t// Resize the image to 9x8.\n\tscaled := resize.Resize(8, 8, img, resize.Bicubic)\n\n\t// Scan it.\n\tyPos := uint(0)\n\tcbPos := uint(0)\n\tcrPos := uint(32)\n\tfor y := 0; y < 8; y++ {\n\t\tfor x := 0; x < 8; x++ {\n\t\t\tyTR, cbTR, crTR := ycbcr(scaled.At(x, y))\n\t\t\tif x == 0 {\n\t\t\t\t// The first bit is a rough approximation of the colour value.\n\t\t\t\tif yTR&0x80 > 0 {\n\t\t\t\t\tbits[0] |= 1 << yPos\n\t\t\t\t\tyPos++\n\t\t\t\t}\n\t\t\t\tif y&1 == 0 {\n\t\t\t\t\t_, cbBR, crBR := ycbcr(scaled.At(x, y+1))\n\t\t\t\t\tif (cbBR+cbTR)>>1&0x80 > 0 {\n\t\t\t\t\t\tbits[1] |= 1 << cbPos\n\t\t\t\t\t\tcbPos++\n\t\t\t\t\t}\n\t\t\t\t\tif (crBR+crTR)>>1&0x80 > 0 {\n\t\t\t\t\t\tbits[1] |= 1 << crPos\n\t\t\t\t\t\tcrPos++\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\t// Use a rough first derivative for the other bits.\n\t\t\t\tyTL, cbTL, crTL := ycbcr(scaled.At(x-1, y))\n\t\t\t\tif yTR > yTL {\n\t\t\t\t\tbits[0] |= 1 << yPos\n\t\t\t\t\tyPos++\n\t\t\t\t}\n\t\t\t\tif y&1 == 0 {\n\t\t\t\t\t_, cbBR, crBR := ycbcr(scaled.At(x, y+1))\n\t\t\t\t\t_, cbBL, crBL := ycbcr(scaled.At(x-1, y+1))\n\t\t\t\t\tif (cbBR+cbTR)>>1 > (cbBL+cbTL)>>1 {\n\t\t\t\t\t\tbits[1] |= 1 << cbPos\n\t\t\t\t\t\tcbPos++\n\t\t\t\t\t}\n\t\t\t\t\tif (crBR+crTR)>>1 > (crBL+crTL)>>1 {\n\t\t\t\t\t\tbits[1] |= 1 << crPos\n\t\t\t\t\t\tcrPos++\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn\n}", "func GetPixels(img image.Image) [][]Pixel {\n\tbounds := img.Bounds()\n\timg_size := bounds.Size()\n\tw, h := img_size.X, img_size.Y\n\tpixels := make([][]Pixel, h)\n\tfor i := 0; i < h; i++ {\n\t\tpixels[i] = make([]Pixel, w)\n\t}\n\n\tdi := 0\n\tfor y := bounds.Min.Y; y < bounds.Max.Y; y++ {\n\t\tdj := 0\n\t\tfor x := bounds.Min.X; x < bounds.Max.X; x++ {\n\t\t\torig_color := img.At(x, y)\n\t\t\tcolor, alpha_flag := colorful.MakeColor(orig_color)\n\t\t\tif !alpha_flag {\n\t\t\t\tcolor = colorful.Color{R: 1.0, G: 1.0, B: 1.0}\n\t\t\t}\n\t\t\t_, _, _, alpha := orig_color.RGBA()\n\t\t\tpixels[di][dj] = Pixel{\n\t\t\t\tcolor: color,\n\t\t\t\talpha: alpha,\n\t\t\t}\n\t\t\tdj++\n\t\t}\n\t\tdi++\n\t}\n\n\treturn pixels\n}", "func CopyImageSubData(srcName uint32, srcTarget uint32, srcLevel int32, srcX int32, srcY int32, srcZ int32, dstName uint32, dstTarget uint32, dstLevel int32, dstX int32, dstY int32, dstZ int32, srcWidth int32, srcHeight int32, srcDepth int32) {\n C.glowCopyImageSubData(gpCopyImageSubData, (C.GLuint)(srcName), (C.GLenum)(srcTarget), (C.GLint)(srcLevel), (C.GLint)(srcX), (C.GLint)(srcY), (C.GLint)(srcZ), (C.GLuint)(dstName), (C.GLenum)(dstTarget), (C.GLint)(dstLevel), (C.GLint)(dstX), (C.GLint)(dstY), (C.GLint)(dstZ), (C.GLsizei)(srcWidth), (C.GLsizei)(srcHeight), (C.GLsizei)(srcDepth))\n}", "func (c *Container) setBitmapCopy(bitmap []uint64) {\n\tvar bitmapCopy [bitmapN]uint64\n\tcopy(bitmapCopy[:], bitmap)\n\tc.setBitmap(bitmapCopy[:])\n}", "func (c *Canvas) SetPixels(pixels []uint8) {\n\tc.gf.Dirty()\n\n\tmainthread.Call(func() {\n\t\ttex := c.Texture()\n\t\ttex.Begin()\n\t\ttex.SetPixels(0, 0, tex.Width(), tex.Height(), pixels)\n\t\ttex.End()\n\t})\n}", "func CopyTexImage1D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, border int32) {\n\tC.glowCopyTexImage1D(gpCopyTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLint)(border))\n}", "func CopyTexImage1D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, border int32) {\n\tC.glowCopyTexImage1D(gpCopyTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLint)(border))\n}", "func (a *AnAlgorithm) mapSkinPixels() () {\n\tupLeft := image.Point{0, 0}\n\tlowRight := image.Point{a.width, a.height}\n\n\ta.skinMap = image.NewRGBA(image.Rectangle{upLeft, lowRight})\n\n\tblack := color.RGBA{0,0,0, 0xff}\n\twhite := color.RGBA{255,255,255, 0xff}\n\n\ta.backgroundPixelCount = 0\n\ta.skinPixelCount = 0\n\n\tvar drawPixCol color.RGBA\n\tfor x := 0; x < a.width; x++ {\n\t\tfor y := 0; y < a.height; y++ {\n\t\t\tpixCol := a.img.At(x, y)\n\n\t\t\tdrawPixCol = white\n\t\t\tif a.yCbCrSkinDetector(pixCol) == true {\n\t\t\t\ta.skinPixelCount++\n\t\t\t\tdrawPixCol = black\n\t\t\t} else {\n\t\t\t\ta.backgroundPixelCount++\n\t\t\t}\n\n\t\t\ta.skinMap.(draw.Image).Set(x, y, drawPixCol)\n\t\t}\n\t}\n\n}", "func histogramRGBPixels(filename string) [16][4]float64 {\n\tm := openImage(filename)\n\tbounds := m.Bounds()\n\n\tvar histogram [16][4]int\n\tfor y := bounds.Min.Y; y < bounds.Max.Y; y++ {\n\t\tfor x := bounds.Min.X; x < bounds.Max.X; x++ {\n\t\t\tr, g, b, a := m.At(x, y).RGBA()\n\t\t\thistogram[r>>12][0]++\n\t\t\thistogram[g>>12][1]++\n\t\t\thistogram[b>>12][2]++\n\t\t\thistogram[a>>12][3]++\n\t\t}\n\t}\n\t//printHistogram(histogram)\n\n\t//normalize\n\tvar histogramf [16][4]float64\n\tpixels := (bounds.Max.Y - bounds.Min.Y) * (bounds.Max.X - bounds.Min.X)\n\tfor bucket := range histogram {\n\t\tfor color := range histogram[bucket] {\n\t\t\thistogramf[bucket][color] = float64(histogram[bucket][color]) / float64(pixels)\n\t\t}\n\t}\n\t//printFHistogram(histogramf)\n\treturn histogramf\n}", "func CopyTexImage1D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, border int32) {\n\tsyscall.Syscall9(gpCopyTexImage1D, 7, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(x), uintptr(y), uintptr(width), uintptr(border), 0, 0)\n}", "func vLine(img *image.NRGBA, x, y1, y2 int, col color.Color) {\r\n\tfor ; y1 <= y2; y1++ {\r\n\t\timg.Set(x, y1, col)\r\n\t}\r\n}", "func fill(pix []byte, c color.RGBA) {\n\tfor i := 0; i < len(pix); i += 4 {\n\t\tpix[i] = c.R\n\t\tpix[i+1] = c.G\n\t\tpix[i+2] = c.B\n\t\tpix[i+3] = c.A\n\t}\n}", "func hline (x1 int, x2 int, y int) {\n\tfor n := x1; n < x2; n++ {\n\t\t\timg.Set(n, y, col)\n\t}\n}", "func copyImg(filename string, rowX int, colX int) string {\n\t//Filename path\n\tpath := \"/gorpc/Images/\" + filename\n\n\t//Extract matrix of image file data\n\tpixels := gocv.IMRead(path, 1)\n\n\t//Get dimensions from picture\n\tdimensions := pixels.Size()\n\theight := dimensions[0]\n\twidth := dimensions[1]\n\n\t//Get type of mat\n\tmatType := pixels.Type()\n\n\t//Create a new mat to fill\n\tbigMat := gocv.NewMatWithSize(height * rowX, width * colX, matType)\n\n\t//Created a wait group to sync filling images\n\twg := sync.WaitGroup{}\n\twg.Add(rowX * colX)\n\n\t//Fill in image copies by relative index on matrix\n\tfor i := 0; i < rowX; i++{\n\t\tfor j := 0; j < colX; j++{\n\t\t\tgo func (i int, j int){\n\t\t\t\t//Decrement counter if an image copy is made\n\t\t\t\tdefer wg.Done()\n\n\t\t\t\t//Iterate over original image and store in new index copy\n\t\t\t\tfor x := 0; x < height; x++{\n\t\t\t\t\tfor y := 0; y < width; y++{\n\t\t\t\t\t\tval := GetVecbAt(pixels, x, y)\n\n\t\t\t\t\t\tval.SetVecbAt(bigMat, (i*height) + x, (j*width) + y)\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}(i, j)\n\t\t}\n\t}\n\n\t//Wait till all copies are filled in\n\twg.Wait()\n\n\t//Remove extension from filename\n\text := filepath.Ext(filename)\n\tname := strings.TrimSuffix(filename, ext)\n\n\t//Rename the new scaled image\n\tnewName := name + \"C\" + ext\n\n\t//New path\n\tnewPath := \"/gorpc/Images/\" + newName\n\n\t//Save the new image from matrix in local directory\n\tgocv.IMWrite(newPath, bigMat)\n\n\treturn newName\n}", "func (g *gfx) SetPixel(x, y int) {\n\tg[x][y] = COLOR_WHITE\n}", "func colorDestinationImage(\n\tdestinationImage *image.NRGBA,\n\tsourceImage image.Image,\n\tdestinationCoordinates []complex128,\n\ttransformedCoordinates []complex128,\n\tcolorValueBoundMin complex128,\n\tcolorValueBoundMax complex128,\n) {\n\tsourceImageBounds := sourceImage.Bounds()\n\tfor index, transformedCoordinate := range transformedCoordinates {\n\t\tvar sourceColorR, sourceColorG, sourceColorB, sourceColorA uint32\n\n\t\tif real(transformedCoordinate) < real(colorValueBoundMin) ||\n\t\t\timag(transformedCoordinate) < imag(colorValueBoundMin) ||\n\t\t\treal(transformedCoordinate) > real(colorValueBoundMax) ||\n\t\t\timag(transformedCoordinate) > imag(colorValueBoundMax) {\n\t\t\tsourceColorR, sourceColorG, sourceColorB, sourceColorA = 0, 0, 0, 0\n\t\t} else {\n\t\t\tsourceImagePixelX := int(mathutility.ScaleValueBetweenTwoRanges(\n\t\t\t\tfloat64(real(transformedCoordinate)),\n\t\t\t\treal(colorValueBoundMin),\n\t\t\t\treal(colorValueBoundMax),\n\t\t\t\tfloat64(sourceImageBounds.Min.X),\n\t\t\t\tfloat64(sourceImageBounds.Max.X),\n\t\t\t))\n\t\t\tsourceImagePixelY := int(mathutility.ScaleValueBetweenTwoRanges(\n\t\t\t\tfloat64(imag(transformedCoordinate)),\n\t\t\t\timag(colorValueBoundMin),\n\t\t\t\timag(colorValueBoundMax),\n\t\t\t\tfloat64(sourceImageBounds.Min.Y),\n\t\t\t\tfloat64(sourceImageBounds.Max.Y),\n\t\t\t))\n\t\t\tsourceColorR, sourceColorG, sourceColorB, sourceColorA = sourceImage.At(sourceImagePixelX, sourceImagePixelY).RGBA()\n\t\t}\n\n\t\tdestinationPixelX := int(real(destinationCoordinates[index]))\n\t\tdestinationPixelY := int(imag(destinationCoordinates[index]))\n\n\t\tdestinationImage.Set(\n\t\t\tdestinationPixelX,\n\t\t\tdestinationPixelY,\n\t\t\tcolor.NRGBA{\n\t\t\t\tR: uint8(sourceColorR >> 8),\n\t\t\t\tG: uint8(sourceColorG >> 8),\n\t\t\t\tB: uint8(sourceColorB >> 8),\n\t\t\t\tA: uint8(sourceColorA >> 8),\n\t\t\t},\n\t\t)\n\t}\n}", "func (display smallEpd) convertImage(image image.Image) (black []byte, red []byte) {\n\t// Resize image to width and height\n\t// Each pixel in image is turned into a bit\n\t// which says 1 or 0\n\t// Create two buffers of (w*h)/8 bytes\n\t// TODO: Allow for other colors. Switch to HSL mode and\n\t// calculate by hue\n\tw := display.Width()\n\th := display.Height()\n\ts := (w * h) / 8\n\tblackBuf := make([]byte, s)\n\tredBuf := make([]byte, s)\n\tfor y := 0; y < h; y++ {\n\t\tfor x := 0; x < w; x++ {\n\t\t\tpixelIdx := ((y * w) + x)\n\t\t\tbyteIdx := pixelIdx / 8\n\t\t\tbitIdx := uint(7 - pixelIdx%8)\n\t\t\tpix := image.At(x, y)\n\t\t\trgba := color.RGBAModel.Convert(pix).(color.RGBA)\n\t\t\tgray := color.GrayModel.Convert(pix).(color.Gray)\n\t\t\t// Flip all bits and mask with 0xFF. Divide by 0xFF to get 1 as last bit for black, 0 for anything else. Then XOR it.\n\t\t\t// black := (((^rgba.R ^ rgba.B ^ rgba.G) & 0xFF) / 0xFF) ^ 0x01 // Black is 1 (white) if not absolute black\n\t\t\t// red := ((rgba.R &^ rgba.B &^ rgba.G) / 0xFF) ^ 0x01 // Red is 1 if only full saturation red. Otherwise 0\n\t\t\tblack := byte(0x00)\n\t\t\tif gray.Y > 180 {\n\t\t\t\tblack = 0x01\n\t\t\t}\n\t\t\tred := byte(0x01)\n\t\t\tif rgba.B < 180 && rgba.G < 180 && rgba.R > 180 {\n\t\t\t\tred = 0x00\n\t\t\t}\n\t\t\tblackBuf[byteIdx] |= black << bitIdx\n\t\t\tredBuf[byteIdx] |= red << bitIdx\n\t\t}\n\t}\n\t// Dither and do another loop for black?\n\treturn blackBuf, redBuf\n}", "func GenerateColormap(colors []models.ColorModel) {\n\tlogger := log.ColoredLogger()\n\tdateStr := strings.ReplaceAll(time.Now().Format(time.UnixDate), \":\", \"-\")\n\tfilepath := fmt.Sprintf(\"lib/assets/images/colormap_%s.png\", dateStr)\n\t// alright, this is going to be a very long terminal command. Hopefully there aren't limits.\n\tqueryStr := fmt.Sprintf(\"convert -size %dx1 xc:white \", len(colors))\n\tfor i, c := range colors {\n\t\tqueryStr += fmt.Sprintf(\"-fill '%s' -draw 'point %d,0' \", c.Hex, i)\n\t}\n\tqueryStr += filepath\n\n\tcmd := exec.Command(queryStr)\n\tcmd.Stdout = os.Stdout\n\tcmd.Stderr = os.Stderr\n\tlogger.Error(\"error\", zap.Error(cmd.Run()))\n}", "func ImageToGraphPixels(colorMapped ColorMappedImage, args Args) Graph {\n\tbounds := colorMapped.image.Bounds()\n\tgraph := Graph{bounds: bounds}\n\tfor y := 0; y < bounds.Max.Y; y++ {\n\t\tfor x := 0; x < bounds.Max.X; x++ {\n\t\t\tgray := colorMapped.image.GrayAt(x, y)\n\t\t\tcommits := colorMapped.colorMap[int(gray.Y)]\n\t\t\tgraph.pixels = append(graph.pixels, GraphPixel{\n\t\t\t\tpixelDaysAgo(x, y, bounds.Max.X, args.weeksAgo), commits,\n\t\t\t})\n\t\t}\n\t}\n\treturn graph\n}", "func rgbaToPixel(r uint32, g uint32, b uint32, a uint32, row int, rowPos int) Pixel {\n\treturn Pixel{\n\t\trgba: Rgba{\n\t\t\tint(r / 257),\n\t\t\tint(g / 257),\n\t\t\tint(b / 257),\n\t\t\tint(a / 257),\n\t\t},\n\t\tRow: row,\n\t\tRowPos: rowPos,\n\t}\n}", "func drawBackground(image *image.RGBA, mem *GBMem) *image.RGBA {\n\tfor x := 0; x < MapWidth; x++ {\n\t\tfor y := 0; y < MapHeight; y++ {\n\t\t\t// get tile index\n\t\t\ttileIndex := mem.read(uint16(VRAMBackgroundMap + x + (y * MapHeight)))\n\n\t\t\t// get pixels corresponding to tile index\n\t\t\tpixels := tileToPixel(tileIndex, mem)\n\n\t\t\t// draw pixels\n\t\t\tdrawTilePixels(image, pixels, x, y)\n\t\t}\n\t}\n\treturn image\n}", "func ColorSamplingPointsForStillColorsVideo(videoW, videoH int) map[string]image.Point {\n\touterCorners := map[string]image.Point{\n\t\t\"outer_top_left\": {1, 1},\n\t\t\"outer_top_right\": {(videoW - 1) - 1, 1},\n\t\t\"outer_bottom_right\": {videoW - 1, videoH - 1},\n\t\t\"outer_bottom_left\": {1, (videoH - 1) - 1},\n\t}\n\tedgeOffset := 5\n\tstencilW := 5\n\tinnerCorners := map[string]image.Point{\n\t\t\"inner_top_left_00\": {edgeOffset, edgeOffset},\n\t\t\"inner_top_left_01\": {edgeOffset, edgeOffset + stencilW},\n\t\t\"inner_top_left_10\": {edgeOffset + stencilW, edgeOffset},\n\t\t\"inner_top_left_11\": {edgeOffset + stencilW, edgeOffset + stencilW},\n\t\t\"inner_top_right_00\": {(videoW - 1) - edgeOffset, edgeOffset},\n\t\t\"inner_top_right_01\": {(videoW - 1) - edgeOffset, edgeOffset + stencilW},\n\t\t\"inner_top_right_10\": {(videoW - 1) - edgeOffset - stencilW, edgeOffset},\n\t\t\"inner_top_right_11\": {(videoW - 1) - edgeOffset - stencilW, edgeOffset + stencilW},\n\t\t\"inner_bottom_right_00\": {(videoW - 1) - edgeOffset, (videoH - 1) - edgeOffset},\n\t\t\"inner_bottom_right_01\": {(videoW - 1) - edgeOffset, (videoH - 1) - edgeOffset - stencilW},\n\t\t\"inner_bottom_right_10\": {(videoW - 1) - edgeOffset - stencilW, (videoH - 1) - edgeOffset},\n\t\t\"inner_bottom_right_11\": {(videoW - 1) - edgeOffset - stencilW, (videoH - 1) - edgeOffset - stencilW},\n\t\t\"inner_bottom_left_00\": {edgeOffset, (videoH - 1) - edgeOffset},\n\t\t\"inner_bottom_left_01\": {edgeOffset, (videoH - 1) - edgeOffset - stencilW},\n\t\t\"inner_bottom_left_10\": {edgeOffset + stencilW, (videoH - 1) - edgeOffset},\n\t\t\"inner_bottom_left_11\": {edgeOffset + stencilW, (videoH - 1) - edgeOffset - stencilW},\n\t}\n\tsamples := map[string]image.Point{}\n\tfor k, v := range innerCorners {\n\t\tsamples[k] = v\n\t}\n\tfor k, v := range outerCorners {\n\t\tsamples[k] = v\n\t}\n\treturn samples\n}", "func paintFill(image [][]string, c string, y, x int) [][]string {\n\t//range check\n\tif y > len(image)-1 {\n\t\treturn image\n\t}\n\tif x > len(image[y])-1 {\n\t\treturn image\n\t}\n\t//dupe color check\n\tif image[y][x] == c {\n\t\treturn image\n\t}\n\t//identify origin color\n\torig := image[y][x]\n\t//color origin\n\tmImage := image\n\tmImage[y][x] = c\n\t//check for valid left\n\tif x > 0 && mImage[y][x-1] == orig {\n\t\tmImage = paintFill(mImage, c, y, x-1)\n\t}\n\t//check for valid right\n\tif x < len(mImage[y])-1 && mImage[y][x+1] == orig {\n\t\tmImage = paintFill(mImage, c, y, x+1)\n\t}\n\t//check for valid up\n\tif y > 0 && mImage[y-1][x] == orig {\n\t\tmImage = paintFill(mImage, c, y-1, x)\n\t}\n\t//check for valid down\n\tif y < len(mImage)-1 && mImage[y+1][x] == orig {\n\t\tmImage = paintFill(mImage, c, y+1, x)\n\t}\n\treturn mImage\n}", "func CopyTexSubImage1D(target uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n C.glowCopyTexSubImage1D(gpCopyTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func (a *PixelSubArray) set(x, y int) {\n\txByte := x/8 - a.xStartByte\n\txBit := uint(x % 8)\n\tyRow := y - a.yStart\n\n\tif yRow > len(a.bytes) {\n\t\tfmt.Println(\"Y OOB:\", len(a.bytes), yRow)\n\t}\n\n\tif xByte > len(a.bytes[0]) {\n\t\tfmt.Println(\"X OOB:\", len(a.bytes[0]), xByte)\n\t}\n\n\ta.bytes[yRow][xByte] |= (1 << xBit)\n}", "func makeTable(r, c int) Table {\n\t// Return value \"Table\" does not need to be a pointer, since it represents\n\t// a slice header that consists of len, cap, and a pointer to the actual\n\t// data. Remember the lecture on slices!\n\tt := make(Table, r, r) // set len and cap to # of rows\n\tfor i := 0; i < r; i++ {\n\t\t// Pre-allocate a row\n\t\tt[i].Hrate = make([]int, c, c) // set len and cap to # of cols\n\t}\n\treturn t\n}", "func (cs *colourSketch) CopySketch() *colourSketch {\n\tc := make([]rgba, len(cs.Colours))\n\tfor i := 0; i < len(c); i++ {\n\t\tc[i] = cs.Colours[i]\n\t}\n\treturn &colourSketch{\n\t\tColours: c,\n\t\tId: cs.Id,\n\t}\n}", "func loadImage(pattern int, data []uint8) {\n\tfor i := 0; i < rows; i++ {\n\t\tfor j := 0; j < cols; j++ {\n\t\t\tdata[(4*(i*cols+j))+0] = 0xff\n\t\t\tdata[(4*(i*cols+j))+1] = 0x00\n\t\t\tdata[(4*(i*cols+j))+2] = 0x00\n\t\t\tdata[(4*(i*cols+j))+3] = 0xff\n\t\t}\n\t}\n\tif pattern == 1 {\n\t\tvar border = cols / 4\n\t\tfor i := border; i < rows-border; i++ {\n\t\t\tfor j := border; j < cols-border; j++ {\n\t\t\t\tvalue := rand.Float64()\n\t\t\t\tif value > 0.7 {\n\t\t\t\t\tdata[(4*(i*cols+j))+2] = uint8(math.Round(255.0 * value))\n\t\t\t\t} else {\n\t\t\t\t\tdata[(4*(i*cols+j))+2] = 0xff\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t} else {\n\t\tvar checker = 40\n\t\tfor i := 0; i < rows; i++ {\n\t\t\tfor j := 0; j < cols; j++ {\n\t\t\t\tif (((i/checker)%2) == 0 && ((j/checker)%2) == 0) ||\n\t\t\t\t\t(((i/checker)%2) == 1 && ((j/checker)%2) == 1) {\n\t\t\t\t\tvalue := rand.Float64()\n\t\t\t\t\tdata[(4*(i*cols+j))+2] = uint8(math.Round(255.0 * value))\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n}", "func CopyTexImage2D(target Enum, level int, internalformat Enum, x, y, width, height, border int) {\n\tgl.CopyTexImage2D(uint32(target), int32(level), uint32(internalformat), int32(x), int32(y), int32(width), int32(height), int32(border))\n}", "func TestWritePixel(t *testing.T) {\n\t// Given\n\tc := canvas.New(10, 20)\n\tred := color.New(1.0, 0.0, 0.0)\n\n\t// When\n\tc.SetPixel(2, 3, red)\n\n\t// Then\n\tassert.True(t, c.Pixel(2, 3).Equal(red))\n}", "func nextcolor(c color.RGBA) color.RGBA {\n\tswitch {\n\tcase c.R == 255 && c.G == 0 && c.B == 0:\n\t\tc.G += 5\n\tcase c.R == 255 && c.G != 255 && c.B == 0:\n\t\tc.G += 5\n\tcase c.G == 255 && c.R != 0:\n\t\tc.R -= 5\n\tcase c.R == 0 && c.B != 255:\n\t\tc.B += 5\n\tcase c.B == 255 && c.G != 0:\n\t\tc.G -= 5\n\tcase c.G == 0 && c.R != 255:\n\t\tc.R += 5\n\tdefault:\n\t\tc.B -= 5\n\t}\n\treturn c\n}", "func ColorPointer(size int32, xtype uint32, stride int32, pointer unsafe.Pointer) {\n\tC.glowColorPointer(gpColorPointer, (C.GLint)(size), (C.GLenum)(xtype), (C.GLsizei)(stride), pointer)\n}", "func TestReadPixelsFromVolatileImage(t *testing.T) {\n\tconst w, h = 16, 16\n\tdst := restorable.NewImage(w, h, restorable.ImageTypeVolatile)\n\tsrc := restorable.NewImage(w, h, restorable.ImageTypeRegular)\n\n\t// First, make sure that dst has pixels\n\tdst.WritePixels(make([]byte, 4*w*h), image.Rect(0, 0, w, h))\n\n\t// Second, draw src to dst. If the implementation is correct, dst becomes stale.\n\tpix := make([]byte, 4*w*h)\n\tfor i := range pix {\n\t\tpix[i] = 0xff\n\t}\n\tsrc.WritePixels(pix, image.Rect(0, 0, w, h))\n\tvs := quadVertices(1, 1, 0, 0)\n\tis := graphics.QuadIndices()\n\tdr := graphicsdriver.Region{\n\t\tX: 0,\n\t\tY: 0,\n\t\tWidth: w,\n\t\tHeight: h,\n\t}\n\tdst.DrawTriangles([graphics.ShaderImageCount]*restorable.Image{src}, vs, is, graphicsdriver.BlendCopy, dr, [graphics.ShaderImageCount]graphicsdriver.Region{}, restorable.NearestFilterShader, nil, false)\n\n\t// Read the pixels. If the implementation is correct, dst tries to read its pixels from GPU due to being\n\t// stale.\n\twant := byte(0xff)\n\n\tvar result [4]byte\n\tif err := dst.ReadPixels(ui.GraphicsDriverForTesting(), result[:], image.Rect(0, 0, 1, 1)); err != nil {\n\t\tt.Fatal(err)\n\t}\n\tgot := result[0]\n\tif got != want {\n\t\tt.Errorf(\"got: %v, want: %v\", got, want)\n\t}\n}", "func (self *TraitPixbuf) Copy() (return__ *Pixbuf) {\n\tvar __cgo__return__ *C.GdkPixbuf\n\t__cgo__return__ = C.gdk_pixbuf_copy(self.CPointer)\n\tif __cgo__return__ != nil {\n\t\treturn__ = NewPixbufFromCPointer(unsafe.Pointer(reflect.ValueOf(__cgo__return__).Pointer()))\n\t}\n\treturn\n}", "func (s *Surface) PixelData(area geo.Rect) []color.RGBA {\n\tx, y, w, h := math.Floor(area.X), math.Floor(area.Y), math.Floor(area.W), math.Floor(area.H)\n\timgData := s.Ctx.Call(\"getImageData\", x, y, w, h).Get(\"data\")\n\tdata := make([]color.RGBA, int(w*h))\n\tfor i := 0; i < len(data); i++ {\n\t\tdata[i] = color.RGBA{\n\t\t\tR: uint8(imgData.Index(i * 4).Int()),\n\t\t\tG: uint8(imgData.Index(i*4 + 1).Int()),\n\t\t\tB: uint8(imgData.Index(i*4 + 2).Int()),\n\t\t\tA: uint8(imgData.Index(i*4 + 3).Int()),\n\t\t}\n\t}\n\treturn data\n}", "func square(img *image.Paletted, p squareParams) {\n\tfor x := p.from.x; x < p.to.x; x++ {\n\t\tfor y := p.from.y; y < p.to.y; y++ {\n\t\t\timg.Set(x, y, p.c)\n\t\t}\n\t}\n}", "func CopyTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n C.glowCopyTexSubImage2D(gpCopyTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func MemCopy(dst unsafe.Pointer, src unsafe.Pointer, bytes int) {\n\tfor i := 0; i < bytes; i++ {\n\t\t*(*uint8)(MemAccess(dst, i)) = *(*uint8)(MemAccess(src, i))\n\t}\n}", "func generatePalette(c0, c1 float64) [8]float64 {\n\n\t//Get signed float normalized palette (0 to 1)\n\tpal := [8]float64{}\n\tpal[0], pal[1] = c0, c1\n\tif c0 > c1 {\n\t\tpal[2] = (6*c0 + 1*c1) / 7\n\t\tpal[3] = (5*c0 + 2*c1) / 7\n\t\tpal[4] = (4*c0 + 3*c1) / 7\n\t\tpal[5] = (3*c0 + 4*c1) / 7\n\t\tpal[6] = (2*c0 + 5*c1) / 7\n\t\tpal[7] = (1*c0 + 6*c1) / 7\n\t} else {\n\t\tpal[2] = (4*c0 + 1*c1) / 5\n\t\tpal[3] = (3*c0 + 2*c1) / 5\n\t\tpal[4] = (2*c0 + 3*c1) / 5\n\t\tpal[5] = (1*c0 + 4*c1) / 5\n\t\tpal[6] = 0\n\t\tpal[7] = 1\n\t}\n\treturn pal\n}", "func (t *Texture) GetPixels() []rgb565.Rgb565Color {\n\tnewArray := make([]rgb565.Rgb565Color, len(t.pixels))\n\tcopy(newArray, t.pixels)\n\treturn newArray\n}", "func tableSetUp(m, n int) *[][]int {\n\tresult := make([][]int, m)\n\tfor i := range result {\n\t\tresult[i] = make([]int, n)\n\t}\n\tfor c := range result[0] {\n\t\tresult[0][c] = c\n\t}\n\tfor r := 0; r < len(result); r++ {\n\t\tresult[r][0] = r\n\t}\n\n\treturn &result\n}", "func Pic(dx, dy int) [][]uint8 {\n\trow := make([]uint8, dx)\n\tcanvas := make([][]uint8, dy)\n\n\tfor i := range canvas {\n\t\tcanvas[i] = row\n\t}\n\n\tfor i := range canvas {\n\t\tfor j := range canvas[i] {\n\t\t\tcanvas[i][j] = uint8((i + j) / 2)\n\t\t\t// canvas[i][j] = uint8(i * j)\n\t\t\t// canvas[i][j] = uint8(math.Pow(float64(i), float64(j)))\n\t\t}\n\t}\n\treturn canvas\n}", "func DecodePixelsFromImage(img image.Image, offsetX, offsetY int) []*Pixel {\n var pixels []*Pixel\n\n for y := 0; y <= img.Bounds().Max.Y; y++ {\n for x := 0; x <= img.Bounds().Max.X; x++ {\n p := &Pixel{\n Point: image.Point{X: x + offsetX, Y: y + offsetY},\n Color: img.At(x, y),\n }\n pixels = append(pixels, p)\n }\n }\n\n return pixels\n}", "func Pic(dx, dy int) [][]uint8 {\n\tfmt.Println(dx, dy)\n\tyy := make([][]uint8, dy)\n\tfor i, _ := range yy {\n\t\txx := make([]uint8, dx)\n\t\tfor j, _ := range xx {\n\t\t\txx[j] = uint8(10)\n\t\t}\n\t\tyy[i] = append(yy[i], xx...)\n\t\t//fmt.Println(line)\n\t}\n\treturn yy\n}", "func applyConvolutionToPixel(im ImageMatrix, x int, y int, cmSize int, column []color.RGBA, cm ConvolutionMatrix, conFunc func(ImageMatrix, int, int, int, int, color.RGBA, float64) int) {\n\tcurrentColour := im[x][y]\n\tredTotal := 0\n\tgreenTotal := 0\n\tblueTotal := 0\n\tweight := 0\n\n\tkernelMatrix := im.GetKernelMatrix(x, y, cmSize)\n\n\tfor i, kernelColumn := range kernelMatrix {\n\t\tfor j, kernelPixelColour := range kernelColumn {\n\n\t\t\t// get the distance of the current pixel compared to the centre of the kernel\n\t\t\t// the centre one is the one we are modifying and saving to a new image/matrix of course...\n\t\t\tdistance := math.Sqrt(math.Pow(float64(cmSize-i), 2) + math.Pow(float64(cmSize-j), 2))\n\n\t\t\t// Call the function the user passed and get the return weight of how much influence\n\t\t\t// it should have over the centre pixel we want to change\n\t\t\t// We are multipling it by the weight in the convolution matrix as that way you can\n\t\t\t// control an aspect of the weight through the matrix as well (as well as the function that\n\t\t\t// we pass in of course :)\n\t\t\tcmValue := conFunc(im, x, y, i, j, kernelPixelColour, distance) * int(cm[i][j])\n\n\t\t\t// apply the influence / weight ... (eg. if cmValue was 0, then the current pixel would have\n\t\t\t// no influence over the pixel we are changing, if it was large in comparision to what we return\n\t\t\t// for the other kernel pixels, then it will have a large influence)\n\t\t\tredTotal += int(kernelPixelColour.R) * cmValue\n\t\t\tgreenTotal += int(kernelPixelColour.G) * cmValue\n\t\t\tblueTotal += int(kernelPixelColour.B) * cmValue\n\t\t\tweight += cmValue\n\t\t}\n\t}\n\n\t// If the convolution matrix normalised itself; aka, say it was something like:\n\t// { 0 -1 0}\n\t// {-1 4 -1}\n\t// { 0 -1 0}\n\t// then adding the entries (4 + (-1) + (-1) + (-1) + (-1)) results in a zero, in which case we leave\n\t// the weights alone (by setting the weight to divide by to 1) (aka, the weights do not have an impact,\n\t// but the pixels with a weight more more or less than 0 still do have an impact on the pixel\n\t// we are changing of course)\n\tif weight == 0 {\n\t\tweight = 1\n\t}\n\n\t// Normalise the values (based on the weight (total's in the matrix))\n\tnewRedValue := redTotal / weight\n\tnewGreenValue := greenTotal / weight\n\tnewBlueValue := blueTotal / weight\n\n\t// If the values are \"out of range\" (outside the colour range of 0-255) then set them to 0 (absence of that\n\t// colour) if they were negative or 255 (100% of that colour) if they were greater than the max allowed.\n\tif newRedValue < 0 {\n\t\tnewRedValue = 0\n\t} else if newRedValue > 255 {\n\t\tnewRedValue = 255\n\t}\n\n\tif newGreenValue < 0 {\n\t\tnewGreenValue = 0\n\t} else if newGreenValue > 255 {\n\t\tnewGreenValue = 255\n\t}\n\n\tif newBlueValue < 0 {\n\t\tnewBlueValue = 0\n\t} else if newBlueValue > 255 {\n\t\tnewBlueValue = 255\n\t}\n\n\t// Assign the new values to the pixel in the column 'column' at position y\n\tcolumn[y] = color.RGBA{uint8(newRedValue), uint8(newGreenValue), uint8(newBlueValue), currentColour.A}\n\t// fmt.Printf(\"[%v,%v] %v => %v\\n\", x, y, currentColour, column[y])\n}", "func Image(m *image.RGBA, key string, colors []color.RGBA) {\n\tsize := m.Bounds().Size()\n\tsquares := 6\n\tquad := size.X / squares\n\tmiddle := math.Ceil(float64(squares) / float64(2))\n\tcolorMap := make(map[int]color.RGBA)\n\tvar currentYQuadrand = 0\n\tfor y := 0; y < size.Y; y++ {\n\t\tyQuadrant := y / quad\n\t\tif yQuadrant != currentYQuadrand {\n\t\t\t// when y quadrant changes, clear map\n\t\t\tcolorMap = make(map[int]color.RGBA)\n\t\t\tcurrentYQuadrand = yQuadrant\n\t\t}\n\t\tfor x := 0; x < size.X; x++ {\n\t\t\txQuadrant := x / quad\n\t\t\tif _, ok := colorMap[xQuadrant]; !ok {\n\t\t\t\tif float64(xQuadrant) < middle {\n\t\t\t\t\tcolorMap[xQuadrant] = draw.PickColor(key, colors, xQuadrant+3*yQuadrant)\n\t\t\t\t} else if xQuadrant < squares {\n\t\t\t\t\tcolorMap[xQuadrant] = colorMap[squares-xQuadrant-1]\n\t\t\t\t} else {\n\t\t\t\t\tcolorMap[xQuadrant] = colorMap[0]\n\t\t\t\t}\n\t\t\t}\n\t\t\tm.Set(x, y, colorMap[xQuadrant])\n\t\t}\n\t}\n}" ]
[ "0.7236274", "0.7012368", "0.680525", "0.627135", "0.6227392", "0.6080061", "0.60735536", "0.60356534", "0.5952416", "0.59139735", "0.5843787", "0.5701853", "0.5590321", "0.5556233", "0.54842144", "0.54842144", "0.54763526", "0.54234326", "0.54201484", "0.5406675", "0.53734493", "0.5333936", "0.53220487", "0.5252402", "0.5187752", "0.51608765", "0.51597816", "0.5157448", "0.5142194", "0.5134447", "0.51214284", "0.5097681", "0.509333", "0.509333", "0.5058054", "0.50357056", "0.50249606", "0.49674588", "0.49626556", "0.49576434", "0.49576434", "0.48932037", "0.48928496", "0.48771825", "0.4871633", "0.4862217", "0.48588812", "0.48477137", "0.48421603", "0.48309577", "0.4804104", "0.47956526", "0.4766196", "0.47598338", "0.47518393", "0.47426265", "0.47260967", "0.47258008", "0.47132674", "0.47030997", "0.47030997", "0.46983707", "0.46974888", "0.46929076", "0.4686118", "0.46752864", "0.4673603", "0.4665839", "0.46582022", "0.46338367", "0.46321288", "0.46293166", "0.46288276", "0.46271372", "0.4621921", "0.46216372", "0.46170396", "0.46159106", "0.4614012", "0.46126747", "0.46124282", "0.46078247", "0.46001825", "0.45964566", "0.45955122", "0.4592647", "0.4591248", "0.45897254", "0.45859054", "0.4584006", "0.45781636", "0.4577769", "0.45727938", "0.45723814", "0.4569663", "0.4568378", "0.45544836", "0.4552726", "0.45456916", "0.45436856" ]
0.70833987
1
copy pixels into a onedimensional convolution filter
func CopyConvolutionFilter1D(target uint32, internalformat uint32, x int32, y int32, width int32) { C.glowCopyConvolutionFilter1D(gpCopyConvolutionFilter1D, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func CopyConvolutionFilter1D(target uint32, internalformat uint32, x int32, y int32, width int32) {\n C.glowCopyConvolutionFilter1D(gpCopyConvolutionFilter1D, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func CopyConvolutionFilter2D(target uint32, internalformat uint32, x int32, y int32, width int32, height int32) {\n C.glowCopyConvolutionFilter2D(gpCopyConvolutionFilter2D, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CopyConvolutionFilter2D(target uint32, internalformat uint32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyConvolutionFilter2D(gpCopyConvolutionFilter2D, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func (img *FloatImage) convolve(kernel *ConvKernel, px planeExtension) *FloatImage {\n\n\t// convolve each plane independently:\n\tres := new([3][]float32)\n\tfor i := 0; i < 3; i++ {\n\t\tconvolvePlane(&img.Ip[i], kernel, img.Width, img.Height, px)\n\t}\n\n\treturn &FloatImage{\n\t\tIp: *res,\n\t\tWidth: img.Width,\n\t\tHeight: img.Height,\n\t}\n}", "func ConvolutionFilter2D(target uint32, internalformat uint32, width int32, height int32, format uint32, xtype uint32, image unsafe.Pointer) {\n C.glowConvolutionFilter2D(gpConvolutionFilter2D, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), image)\n}", "func ConvolutionFilter1D(target uint32, internalformat uint32, width int32, format uint32, xtype uint32, image unsafe.Pointer) {\n C.glowConvolutionFilter1D(gpConvolutionFilter1D, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), image)\n}", "func ConvolutionFilter2D(target uint32, internalformat uint32, width int32, height int32, format uint32, xtype uint32, image unsafe.Pointer) {\n\tC.glowConvolutionFilter2D(gpConvolutionFilter2D, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), image)\n}", "func Convolve(src, dst []float64, kernel []float64, border Border) {\n\twidth := len(kernel)\n\thalfWidth := width / 2\n\tfor i := range dst {\n\t\tk := i - halfWidth\n\t\tvar sum float64\n\t\tif k >= 0 && k <= len(src)-width {\n\t\t\tfor j, x := range kernel {\n\t\t\t\tsum += src[k+j] * x\n\t\t\t}\n\t\t} else {\n\t\t\tfor j, x := range kernel {\n\t\t\t\tsum += border.Interpolate(src, k+j) * x\n\t\t\t}\n\t\t}\n\t\tdst[i] = sum\n\t}\n}", "func ConvolutionFilter1D(target uint32, internalformat uint32, width int32, format uint32, xtype uint32, image unsafe.Pointer) {\n\tC.glowConvolutionFilter1D(gpConvolutionFilter1D, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), image)\n}", "func applyConvolutionToPixel(im ImageMatrix, x int, y int, cmSize int, column []color.RGBA, cm ConvolutionMatrix, conFunc func(ImageMatrix, int, int, int, int, color.RGBA, float64) int) {\n\tcurrentColour := im[x][y]\n\tredTotal := 0\n\tgreenTotal := 0\n\tblueTotal := 0\n\tweight := 0\n\n\tkernelMatrix := im.GetKernelMatrix(x, y, cmSize)\n\n\tfor i, kernelColumn := range kernelMatrix {\n\t\tfor j, kernelPixelColour := range kernelColumn {\n\n\t\t\t// get the distance of the current pixel compared to the centre of the kernel\n\t\t\t// the centre one is the one we are modifying and saving to a new image/matrix of course...\n\t\t\tdistance := math.Sqrt(math.Pow(float64(cmSize-i), 2) + math.Pow(float64(cmSize-j), 2))\n\n\t\t\t// Call the function the user passed and get the return weight of how much influence\n\t\t\t// it should have over the centre pixel we want to change\n\t\t\t// We are multipling it by the weight in the convolution matrix as that way you can\n\t\t\t// control an aspect of the weight through the matrix as well (as well as the function that\n\t\t\t// we pass in of course :)\n\t\t\tcmValue := conFunc(im, x, y, i, j, kernelPixelColour, distance) * int(cm[i][j])\n\n\t\t\t// apply the influence / weight ... (eg. if cmValue was 0, then the current pixel would have\n\t\t\t// no influence over the pixel we are changing, if it was large in comparision to what we return\n\t\t\t// for the other kernel pixels, then it will have a large influence)\n\t\t\tredTotal += int(kernelPixelColour.R) * cmValue\n\t\t\tgreenTotal += int(kernelPixelColour.G) * cmValue\n\t\t\tblueTotal += int(kernelPixelColour.B) * cmValue\n\t\t\tweight += cmValue\n\t\t}\n\t}\n\n\t// If the convolution matrix normalised itself; aka, say it was something like:\n\t// { 0 -1 0}\n\t// {-1 4 -1}\n\t// { 0 -1 0}\n\t// then adding the entries (4 + (-1) + (-1) + (-1) + (-1)) results in a zero, in which case we leave\n\t// the weights alone (by setting the weight to divide by to 1) (aka, the weights do not have an impact,\n\t// but the pixels with a weight more more or less than 0 still do have an impact on the pixel\n\t// we are changing of course)\n\tif weight == 0 {\n\t\tweight = 1\n\t}\n\n\t// Normalise the values (based on the weight (total's in the matrix))\n\tnewRedValue := redTotal / weight\n\tnewGreenValue := greenTotal / weight\n\tnewBlueValue := blueTotal / weight\n\n\t// If the values are \"out of range\" (outside the colour range of 0-255) then set them to 0 (absence of that\n\t// colour) if they were negative or 255 (100% of that colour) if they were greater than the max allowed.\n\tif newRedValue < 0 {\n\t\tnewRedValue = 0\n\t} else if newRedValue > 255 {\n\t\tnewRedValue = 255\n\t}\n\n\tif newGreenValue < 0 {\n\t\tnewGreenValue = 0\n\t} else if newGreenValue > 255 {\n\t\tnewGreenValue = 255\n\t}\n\n\tif newBlueValue < 0 {\n\t\tnewBlueValue = 0\n\t} else if newBlueValue > 255 {\n\t\tnewBlueValue = 255\n\t}\n\n\t// Assign the new values to the pixel in the column 'column' at position y\n\tcolumn[y] = color.RGBA{uint8(newRedValue), uint8(newGreenValue), uint8(newBlueValue), currentColour.A}\n\t// fmt.Printf(\"[%v,%v] %v => %v\\n\", x, y, currentColour, column[y])\n}", "func GetConvolutionFilter(target uint32, format uint32, xtype uint32, image unsafe.Pointer) {\n C.glowGetConvolutionFilter(gpGetConvolutionFilter, (C.GLenum)(target), (C.GLenum)(format), (C.GLenum)(xtype), image)\n}", "func (img *FloatImage) convolveWith(kernel *ConvKernel, px planeExtension) {\n\n\t// convolve each plane independently:\n\tfor i := 0; i < 3; i++ {\n\t\timg.Ip[i] = *convolvePlane(&img.Ip[i], kernel, img.Width, img.Height, px)\n\t}\n}", "func Copy(i ImageIr) ImageIr {\n\tc := make([][][]uint32, len(i.pixels))\n\tcopy(c, i.pixels)\n\treturn ImageIr{i.width, i.height, c}\n}", "func createFilter(img image.Image, factor [2]float32, size int, kernel func(float32) float32) (f Filter) {\n\tsizeX := size * (int(math.Ceil(float64(factor[0]))))\n\tsizeY := size * (int(math.Ceil(float64(factor[1]))))\n\n\tswitch img.(type) {\n\tdefault:\n\t\tf = &filterModel{\n\t\t\t&genericConverter{img},\n\t\t\tfactor, kernel,\n\t\t\tmake([]colorArray, sizeX), make([]colorArray, sizeY),\n\t\t}\n\tcase *image.RGBA:\n\t\tf = &filterModel{\n\t\t\t&rgbaConverter{img.(*image.RGBA)},\n\t\t\tfactor, kernel,\n\t\t\tmake([]colorArray, sizeX), make([]colorArray, sizeY),\n\t\t}\n\tcase *image.RGBA64:\n\t\tf = &filterModel{\n\t\t\t&rgba64Converter{img.(*image.RGBA64)},\n\t\t\tfactor, kernel,\n\t\t\tmake([]colorArray, sizeX), make([]colorArray, sizeY),\n\t\t}\n\tcase *image.Gray:\n\t\tf = &filterModel{\n\t\t\t&grayConverter{img.(*image.Gray)},\n\t\t\tfactor, kernel,\n\t\t\tmake([]colorArray, sizeX), make([]colorArray, sizeY),\n\t\t}\n\tcase *image.Gray16:\n\t\tf = &filterModel{\n\t\t\t&gray16Converter{img.(*image.Gray16)},\n\t\t\tfactor, kernel,\n\t\t\tmake([]colorArray, sizeX), make([]colorArray, sizeY),\n\t\t}\n\tcase *image.YCbCr:\n\t\tf = &filterModel{\n\t\t\t&ycbcrConverter{img.(*image.YCbCr)},\n\t\t\tfactor, kernel,\n\t\t\tmake([]colorArray, sizeX), make([]colorArray, sizeY),\n\t\t}\n\t}\n\treturn\n}", "func (img *ImageTask) ApplyConvulusion(neighbors *Neighbors, kernel [9]float64) *Colors{\n\n\tvar blue float64\n\tvar green float64\n\tvar red float64\n\tfor r := 0; r < 9; r++ {\n\t\tred = red + (neighbors.inputs[r].Red * kernel[r])\n\t\tgreen = green + (neighbors.inputs[r].Green * kernel[r])\n\t\tblue = blue + (neighbors.inputs[r].Blue * kernel[r])\n\t}\n\n\treturned := Colors{Red: red, Green: green, Blue: blue, Alpha: neighbors.inputs[4].Alpha}\n\treturn &returned\n}", "func ConstructedConv2D(m *Model, x tensor.Tensor, kernelH int, kernelW int, filters int) tensor.Tensor {\n\tslen := len(x.Shape())\n\tfAxis := slen - 1\n\twAxis := slen - 2\n\thAxis := slen - 3\n\tinFilters := x.Shape()[fAxis]\n\tinW := x.Shape()[wAxis]\n\tinH := x.Shape()[hAxis]\n\n\twShape := onesLike(x)\n\twShape[fAxis] = filters\n\twShape[wAxis] = inFilters * kernelH * kernelW\n\n\tbShape := onesLike(x)\n\tbShape[fAxis] = filters\n\n\tweight := m.AddWeight(wShape...)\n\tbias := m.AddBias(bShape...)\n\n\tslices := make([]tensor.Tensor, 0, kernelH*kernelW)\n\n\tfor hoff := 0; hoff < kernelH; hoff++ {\n\t\thslice := tensor.Slice(x, hAxis, hoff, inH-kernelH+1+hoff)\n\t\tfor woff := 0; woff < kernelW; woff++ {\n\t\t\twslice := tensor.Slice(hslice, wAxis, woff, inW-kernelW+1+woff)\n\t\t\tslices = append(slices, wslice)\n\t\t}\n\t}\n\n\tx = tensor.Concat(fAxis, slices...)\n\tx = tensor.MatMul(x, weight, wAxis, fAxis)\n\tx = tensor.Add(x, bias)\n\n\treturn x\n}", "func clone(dst, src *image.Gray) {\n\tif dst.Stride == src.Stride {\n\t\t// no need to correct stride, simply copy pixels.\n\t\tcopy(dst.Pix, src.Pix)\n\t\treturn\n\t}\n\t// need to correct stride.\n\tfor i := 0; i < src.Rect.Dy(); i++ {\n\t\tdstH := i * dst.Stride\n\t\tsrcH := i * src.Stride\n\t\tcopy(dst.Pix[dstH:dstH+dst.Stride], src.Pix[srcH:srcH+dst.Stride])\n\t}\n}", "func (fir *FIR) Convolve(input []float64) ([]float64, error) {\n\tkernelSize := len(fir.kernel)\n\tn := len(input)\n\n\tif n <= kernelSize {\n\t\terr := fmt.Errorf(\"input size %d is not greater than kernel size %d\", n, kernelSize)\n\t\treturn []float64{}, err\n\t}\n\n\toutput := make([]float64, n)\n\n\t//\n\tfor i := 0; i < kernelSize; i++ {\n\t\tsum := 0.0\n\n\t\t// convolve the input with the filter kernel\n\t\tfor j := 0; j < i; j++ {\n\t\t\tsum += (input[j] * fir.kernel[kernelSize-(1+i-j)])\n\t\t}\n\n\t\toutput[i] = sum\n\t}\n\n\tfor i := kernelSize; i < n; i++ {\n\t\tsum := 0.0\n\n\t\t// convolve the input with the filter kernel\n\t\tfor j := 0; j < kernelSize; j++ {\n\t\t\tsum += (input[i-j] * fir.kernel[j])\n\t\t}\n\n\t\toutput[i] = sum\n\t}\n\n\treturn output, nil\n}", "func convolvePlane(planePtr *[]float32, kernel *ConvKernel, width, height int, toPlaneCoords planeExtension) *[]float32 {\n\n\tplane := *planePtr\n\tradius := kernel.Radius\n\tdiameter := radius*2 + 1\n\tres := make([]float32, width*height)\n\n\t// for each pixel of the intensity plane:\n\tfor y := 0; y < height; y++ {\n\t\tfor x := 0; x < width; x++ {\n\t\t\tindex := y*width + x\n\n\t\t\t// compute convolved value of the pixel:\n\t\t\tresV := float32(0)\n\t\t\tfor yk := 0; yk < diameter; yk++ {\n\t\t\t\typ := toPlaneCoords(y+yk-radius, height)\n\t\t\t\tfor xk := 0; xk < diameter; xk++ {\n\t\t\t\t\txp := toPlaneCoords(x+xk-radius, width)\n\t\t\t\t\tplaneIndex := yp*width + xp\n\t\t\t\t\tkernelIndex := yk*diameter + xk\n\t\t\t\t\tresV += (plane[planeIndex] * kernel.Kernel[kernelIndex])\n\t\t\t\t}\n\t\t\t}\n\t\t\tres[index] = resV\n\t\t}\n\t}\n\n\treturn &res\n}", "func (l *Conv2D) Forward(inputTensor tensor.Tensor) tensor.Tensor {\n\tl.inputSizeMustMatch(inputTensor)\n\n\tsave := inputTensor.(*Tensor)\n\tl.saveInput(save)\n\n\tbatchSize := l.inputBatchSize(inputTensor)\n\n\tinput := save\n\toutputSize := []int{\n\t\tl.outputSize[0],\n\t\tbatchSize,\n\t\tl.outputSize[1],\n\t\tl.outputSize[2],\n\t}\n\n\toutputHeight := outputSize[2]\n\toutputWidth := outputSize[3]\n\n\tim2ColMatrixHeight := l.numChannels() * l.kernelWidth() * l.kernelHeight()\n\tim2ColMatrixWidth := outputWidth * outputHeight * batchSize\n\tim2ColMatrix := l.TensorOperator.CreateTensor(\n\t\t[]int{im2ColMatrixHeight, im2ColMatrixWidth})\n\tdefer l.TensorOperator.Free(im2ColMatrix)\n\n\tl.im2Col(input, im2ColMatrix,\n\t\t[2]int{l.kernelWidth(), l.kernelHeight()},\n\t\t[4]int{l.padding[0], l.padding[1], l.padding[2], l.padding[3]},\n\t\t[2]int{l.stride[0], l.stride[1]},\n\t\t[2]int{0, 0},\n\t)\n\n\tkernelMatrixWidth := l.kernelWidth() * l.kernelHeight() * l.numChannels()\n\tkernelMatrixHeight := l.numKernels()\n\tkernelMatrix := l.kernel.Reshape(\n\t\t[]int{kernelMatrixHeight, kernelMatrixWidth})\n\n\thKernelData := make([]float32, kernelMatrixWidth*kernelMatrixHeight)\n\tl.GPUDriver.MemCopyD2H(l.GPUCtx, hKernelData, kernelMatrix.ptr)\n\n\toutputMatrix := l.TensorOperator.CreateTensor(\n\t\t[]int{kernelMatrixHeight, im2ColMatrixWidth})\n\tbiasTensor := l.TensorOperator.CreateTensor(\n\t\t[]int{batchSize, l.outputSize[0], l.outputSize[1], l.outputSize[2]})\n\tbiasTensorTrans := l.TensorOperator.CreateTensor(\n\t\t[]int{l.outputSize[0], batchSize, l.outputSize[1], l.outputSize[2]})\n\tl.TensorOperator.Repeat(l.bias, biasTensor, batchSize)\n\tl.TensorOperator.TransposeTensor(biasTensor, biasTensorTrans,\n\t\t[]int{1, 0, 2, 3})\n\tbiasMatrix := biasTensorTrans.Reshape(\n\t\t[]int{l.numKernels(), im2ColMatrixWidth})\n\n\tl.TensorOperator.Gemm(\n\t\tfalse, false,\n\t\tkernelMatrixHeight,\n\t\tim2ColMatrixWidth,\n\t\tkernelMatrixWidth,\n\t\t1.0, 1.0,\n\t\tkernelMatrix, im2ColMatrix, biasMatrix, outputMatrix)\n\n\toutput := &Tensor{\n\t\tdriver: l.GPUDriver,\n\t\tctx: l.GPUCtx,\n\t\tsize: outputSize,\n\t\tptr: outputMatrix.ptr,\n\t\tdescriptor: \"CNHW\",\n\t}\n\n\ttransposedOutput := l.TensorOperator.CreateTensor([]int{\n\t\tbatchSize,\n\t\tl.outputSize[0],\n\t\tl.outputSize[1],\n\t\tl.outputSize[2]})\n\tl.TensorOperator.TransposeTensor(\n\t\toutput, transposedOutput, []int{1, 0, 2, 3})\n\n\tl.TensorOperator.Free(biasTensor)\n\tl.TensorOperator.Free(biasTensorTrans)\n\tl.TensorOperator.Free(output)\n\n\treturn transposedOutput\n}", "func Copy(dst draw.Image, src image.Image) {\n\tbd := src.Bounds().Intersect(dst.Bounds())\n\tat := imageutil.NewAtFunc(src)\n\tset := imageutil.NewSetFunc(dst)\n\timageutil.Parallel1D(bd, func(bd image.Rectangle) {\n\t\tfor y := bd.Min.Y; y < bd.Max.Y; y++ {\n\t\t\tfor x := bd.Min.X; x < bd.Max.X; x++ {\n\t\t\t\tr, g, b, a := at(x, y)\n\t\t\t\tset(x, y, r, g, b, a)\n\t\t\t}\n\t\t}\n\t})\n}", "func ConvDiff(geom *Geom, fltOn, fltOff *etensor.Float32, imgOn, imgOff, out *etensor.Float32, gain, gainOn float32) {\n\tfy := fltOn.Dim(0)\n\tfx := fltOn.Dim(1)\n\n\tgeom.FiltSz = image.Point{fx, fy}\n\tgeom.UpdtFilt()\n\n\timgSz := image.Point{imgOn.Dim(1), imgOn.Dim(0)}\n\tgeom.SetSize(imgSz)\n\toshp := []int{2, int(geom.Out.Y), int(geom.Out.X)}\n\tif !etensor.EqualInts(oshp, out.Shp) {\n\t\tout.SetShape(oshp, nil, []string{\"OnOff\", \"Y\", \"X\"})\n\t}\n\tncpu := nproc.NumCPU()\n\tnthrs, nper, rmdr := nproc.ThreadNs(ncpu, geom.Out.Y)\n\tvar wg sync.WaitGroup\n\tfor th := 0; th < nthrs; th++ {\n\t\twg.Add(1)\n\t\tyst := th * nper\n\t\tgo convDiffThr(&wg, geom, yst, nper, fltOn, fltOff, imgOn, imgOff, out, gain, gainOn)\n\t}\n\tif rmdr > 0 {\n\t\twg.Add(1)\n\t\tyst := nthrs * nper\n\t\tgo convDiffThr(&wg, geom, yst, rmdr, fltOn, fltOff, imgOn, imgOff, out, gain, gainOn)\n\t}\n\twg.Wait()\n}", "func GaussianFilter(src, dst []float64, width int, sigma float64, border Border) {\n\tif width <= 0 {\n\t\twidth = 1 + 2*int(math.Floor(sigma*4+0.5))\n\t}\n\tkernel := make([]float64, width)\n\tGaussianKernel(kernel, sigma)\n\tConvolve(src, dst, kernel, border)\n}", "func BoxFilter(src, dst []float64, width int, border Border) {\n\t// TODO optimize\n\talpha := 1.0 / float64(width)\n\tkernel := make([]float64, width)\n\tfor i := range kernel {\n\t\tkernel[i] = alpha\n\t}\n\tConvolve(src, dst, kernel, border)\n}", "func ConcurrentEdgeFilter(imgSrc image.Image) image.Image {\n\tngo:=runtime.NumCPU()\n\tout := make(chan portion)\n\tslices := imagetools.CropChevauchement(imgSrc, ngo, 10) //on laisse 5 pixels de chevauchement\n\n\tfor i := 0; i < ngo; i++ {\n\t\tgo edgWorker(i, out, slices[i][0])\n\t}\n\n\tfor i := 0; i < ngo; i++ {\n\t\tslice := <-out\n\t\tslices[slice.id][0] = slice.img\n\t}\n\n\timgEnd := imagetools.RebuildChevauchement(slices, 10)\n\n\treturn imgEnd\n\n}", "func MakePixelMixingFilter() *Filter {\n\tf := new(Filter)\n\tf.F = func(x float64, scaleFactor float64) float64 {\n\t\tvar p float64\n\t\tif scaleFactor < 1.0 {\n\t\t\tp = scaleFactor\n\t\t} else {\n\t\t\tp = 1.0 / scaleFactor\n\t\t}\n\t\tif x < 0.5-p/2.0 {\n\t\t\treturn 1.0\n\t\t} else if x < 0.5+p/2.0 {\n\t\t\treturn 0.5 - (x-0.5)/p\n\t\t}\n\t\treturn 0.0\n\t}\n\tf.Radius = func(scaleFactor float64) float64 {\n\t\tif scaleFactor < 1.0 {\n\t\t\treturn 0.5 + scaleFactor\n\t\t}\n\t\treturn 0.5 + 1.0/scaleFactor\n\t}\n\treturn f\n}", "func worker(threads int, doneWorker chan<- bool, imageTasks <-chan *imagetask.ImageTask, imageResults chan<- *imagetask.ImageTask) {\n\n\t// Initial placing image chunks in to a channel for filter to consume.\n\tchunkStreamGenerator := func(done <- chan interface{}, imageChunks []*imagetask.ImageTask) chan *imagetask.ImageTask {\n\t\tchunkStream := make(chan *imagetask.ImageTask)\n\t\tgo func() {\n\t\t\tdefer close(chunkStream)\n\t\t\tfor _, chunk := range imageChunks {\n\t\t\t\tselect {\n\t\t\t\tcase <-done:\n\t\t\t\t\treturn\n\t\t\t\tcase chunkStream <- chunk:\n\t\t\t\t}\n\t\t\t}\n\t\t}()\n\t\treturn chunkStream\n\t}\n\n\t// Filter applies a filter in a pipeline fashion. \n\t// A goroutine is spawned for each chunk that needs to be filtered (which is numOfThreads chunks for each filter effect)\n\tfilter := func(threads int, effect string, effectNum int, done <- chan interface{}, chunkStream chan *imagetask.ImageTask) chan *imagetask.ImageTask {\n\t\tfilterStream := make(chan *imagetask.ImageTask, threads) // Only numOfThreads image chunks should be in the local filter channel.\n\t\tdonefilterChunk := make(chan bool)\n\t\tfor chunk := range chunkStream { // For each image chunk ...\n\t\t\tif effectNum > 0 {\n\t\t\t\tchunk.Img.UpdateInImg() // Replace inImg with outImg if not the first effect to compund effects.\n\t\t\t}\t\n\t\t\tgo func(chunk *imagetask.ImageTask) { // Spawn a goroutine for each chunk, which is equal to the numOfThreads. Each goroutine works on a portion of the image.\n\t\t\t\tselect {\n\t\t\t\tcase <-done:\n\t\t\t\t\tdonefilterChunk <- true\n\t\t\t\t\treturn\n\t\t\t\tcase filterStream <- chunk:\n\t\t\t\t\tif effect != \"G\" {\n\t\t\t\t\t\tchunk.Img.ApplyConvolution(effect) // Can wait to apply effect until after chunk is in the channel because has to wait for all goroutines to finish before it can move on to the next filter for a given image.\n\t\t\t\t\t} else {\n\t\t\t\t\t\tchunk.Img.Grayscale()\n\t\t\t\t\t}\n\t\t\t\t\tdonefilterChunk <- true // Indicate that the filtering is done for the given chunk.\n\t\t\t\t}\n\t\t\t}(chunk)\n\t\t}\n\t\tfor i := 0; i < threads; i ++ { // Wait for all portions to be put through one filter because of image dependencies with convolution.\n\t\t\t<-donefilterChunk\n\t\t}\n\t\treturn filterStream\n\t}\n\n\t// While there are more image tasks to grab ...\n\tfor true {\n\t\t// Grab image task from image task channel.\t\n\t\timgTask, more := <-imageTasks\n\n\t\t// If you get an image task, split up the image in to even chunks by y-pixels.\n\t\tif more {\n\t\t\timageChunks := imgTask.SplitImage(threads)\n\t\t\t\n\t\t\t// Iterate through filters on image chunks.\n\t\t\t// Will spawn a goroutine for each chunk in each filter (n goroutines per filter)\n\t\t\tdone := make(chan interface{})\n\t\t\tdefer close(done)\n\t\t\tchunkStream := chunkStreamGenerator(done, imageChunks)\n\t\t\tfor i := 0; i < len(imgTask.Effects); i++ {\n\t\t\t\teffect := imgTask.Effects[i]\n\t\t\t\tchunkStream = filter(threads, effect, i, done, chunkStream)\n\t\t\t\tclose(chunkStream)\n\t\t\t}\n\n\t\t\t// Put the image back together.\n\t\t\treconstructedImage, _ := imgTask.Img.NewImage()\n\t\t\tfor imgChunk := range chunkStream {\n\t\t\t\treconstructedImage.ReAddChunk(imgChunk.Img, imgChunk.YPixelStart, imgChunk.ChunkPart)\n\t\t\t}\n\t\t\timgTask.Img = reconstructedImage\n\t\t\timageResults <- imgTask // Send image to results channel to be saved.\n\n\t\t} else { // Otherwise, if there are no more image tasks, then goroutine worker exits.\n\t\t\tdoneWorker <- true // Indicate that the worker is done.\n\t\t\treturn\n\t\t}\n\t}\n}", "func convolutionMatrixSampleFunction(im ImageMatrix, imagePositionX int, imagePositionY int, kernelPixelX int, kernelPixel int, colour color.RGBA, distance float64) int {\n\tif distance < 1 {\n\t\treturn 1\n\t}\n\n\tif colour.R > 150 && colour.G < 100 && colour.B < 100 {\n\t\treturn int(5 * distance)\n\t}\n\n\treturn 5\n}", "func (filter *Merge) Process(img *FilterImage) error {\n\tout := img.Image\n\tbounds := out.Bounds()\n\tinbounds := filter.Image.Bounds()\n\n\txmin := bounds.Min.X\n\tif xmin < inbounds.Min.X {\n\t\txmin = inbounds.Min.X\n\t}\n\txmax := bounds.Max.X\n\tif xmax > inbounds.Max.X {\n\t\txmax = inbounds.Max.X\n\t}\n\tymin := bounds.Min.Y\n\tif ymin < inbounds.Min.Y {\n\t\tymin = inbounds.Min.Y\n\t}\n\tymax := bounds.Max.Y\n\tif ymax > inbounds.Max.Y {\n\t\tymax = inbounds.Max.Y\n\t}\n\n\tfor x := xmin; x < xmax; x++ {\n\t\tfor y := ymin; y < ymax; y++ {\n\t\t\tr, g, b, a := out.At(x, y).RGBA()\n\t\t\tir, ig, ib, ia := filter.Image.At(x, y).RGBA()\n\n\t\t\tr = uint32(ClipInt(int(r + ir), 0, 0xFFFF))\n\t\t\tg = uint32(ClipInt(int(g + ig), 0, 0xFFFF))\n\t\t\tb = uint32(ClipInt(int(b + ib), 0, 0xFFFF))\n\t\t\ta = uint32(ClipInt(int(a + ia), 0, 0xFFFF))\n\n\t\t\tout.Set(x, y, color.NRGBA64{uint16(r), uint16(g), uint16(b), uint16(a)})\n\t\t}\n\t}\n\n\treturn nil\n}", "func (r *Ri) PixelFilter(filterfunc RtFilterFunc, xwidth, ywidth RtFloat) error {\n\treturn r.writef(\"PixelFilter\", filterfunc, xwidth, ywidth)\n}", "func GetConvolutionFilter(target uint32, format uint32, xtype uint32, image unsafe.Pointer) {\n\tC.glowGetConvolutionFilter(gpGetConvolutionFilter, (C.GLenum)(target), (C.GLenum)(format), (C.GLenum)(xtype), image)\n}", "func Contrast(percentage float32) Filter {\n\tif percentage == 0 {\n\t\treturn &copyimageFilter{}\n\t}\n\n\tp := 1 + minf32(maxf32(percentage, -100), 100)/100\n\n\treturn &colorchanFilter{\n\t\tfn: func(x float32) float32 {\n\t\t\tif 0 <= p && p <= 1 {\n\t\t\t\treturn 0.5 + (x-0.5)*p\n\t\t\t} else if 1 < p && p < 2 {\n\t\t\t\treturn 0.5 + (x-0.5)*(1/(2.0-p))\n\t\t\t} else {\n\t\t\t\tif x < 0.5 {\n\t\t\t\t\treturn 0\n\t\t\t\t}\n\t\t\t\treturn 1\n\t\t\t}\n\t\t},\n\t\tlut: false,\n\t}\n}", "func (c *Canvas) pixelate(data []uint8, rect image.Rectangle, noiseLevel int) []uint8 {\n\t// Converts the array buffer to an image\n\timg := pixels.PixToImage(data, rect)\n\n\t// Quantize the substracted image in order to reduce the number of colors.\n\t// This will create a new pixelated subtype image.\n\tcell := quant.Draw(img, c.numOfColors, c.cellSize, noiseLevel)\n\n\tdst := image.NewNRGBA(cell.Bounds())\n\tdraw.Draw(dst, cell.Bounds(), cell, image.Point{}, draw.Over)\n\n\treturn pixels.ImgToPix(dst)\n}", "func (ev *ImgEnv) FilterImg() {\n\tev.XFormRand.Gen(&ev.XForm)\n\toimg := ev.Images[ev.ImageIdx.Cur]\n\t// following logic first extracts a sub-image of 2x the ultimate filtered size of image\n\t// from original image, which greatly speeds up the xform processes, relative to working\n\t// on entire 800x600 original image\n\tinsz := ev.Vis.Geom.In.Mul(2) // target size * 2\n\tibd := oimg.Bounds()\n\tisz := ibd.Size()\n\tirng := isz.Sub(insz)\n\tvar st image.Point\n\tst.X = rand.Intn(irng.X)\n\tst.Y = rand.Intn(irng.Y)\n\ted := st.Add(insz)\n\tsimg := oimg.SubImage(image.Rectangle{Min: st, Max: ed})\n\timg := ev.XForm.Image(simg)\n\tev.Vis.Filter(img)\n}", "func (t1 *Tensor) Convolve2D(kernel *Tensor, stride int) (*Tensor, error) {\n\toutTensor := NewTensor((t1.Size.X-kernel.Size.X)/stride+1, (t1.Size.Y-kernel.Size.Y)/stride+1, t1.Size.Z)\n\tfor x := 0; x < outTensor.Size.X; x++ {\n\t\tfor y := 0; y < outTensor.Size.Y; y++ {\n\t\t\tmappedX, mappedY := x*stride, y*stride\n\t\t\tfor i := 0; i < kernel.Size.X; i++ {\n\t\t\t\tfor j := 0; j < kernel.Size.X; j++ {\n\t\t\t\t\tfor z := 0; z < t1.Size.Z; z++ {\n\t\t\t\t\t\tf := kernel.Get(i, j, z)\n\t\t\t\t\t\tv := t1.Get(mappedX+i, mappedY+j, z)\n\t\t\t\t\t\toutTensor.SetAdd(x, y, z, f*v)\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\treturn outTensor, nil\n}", "func (fr *Frame) Copy(orig *Frame) {\n\tfr.Status = orig.Status\n\tfor y, row := range orig.Pix {\n\t\tcopy(fr.Pix[y][:], row)\n\t}\n}", "func (dithering Dithering) Convert(input image.Image) image.Image {\n\tgrayInput := Gray{\n\t\tAlgorithm: GrayAlgorithms.Luminosity,\n\t}.Convert(input)\n\tbounds := grayInput.Bounds()\n\tw, h := bounds.Max.X, bounds.Max.Y\n\n\tmatrix := make([][]float32, w)\n\tfor x := 0; x < w; x++ {\n\t\tmatrix[x] = make([]float32, h)\n\t\tfor y := 0; y < h; y++ {\n\t\t\tr, _, _, _ := grayInput.At(x, y).RGBA()\n\t\t\tmatrix[x][y] = float32(r >> 8)\n\t\t}\n\t}\n\tthreshold := calculateThreshold(grayInput)\n\n\tfor y := 0; y < h-1; y++ {\n\t\tfor x := 1; x < w-1; x++ {\n\t\t\toldpixel := matrix[x][y]\n\t\t\tnewpixel := toBlackOrWhite(oldpixel, threshold)\n\t\t\tmatrix[x][y] = newpixel\n\t\t\tquantError := oldpixel - newpixel\n\t\t\tmatrix[x+1][y] = matrix[x+1][y] + quantError*7/16\n\t\t\tmatrix[x-1][y+1] = matrix[x-1][y+1] + quantError*3/16\n\t\t\tmatrix[x][y+1] = matrix[x][y+1] + quantError*5/16\n\t\t\tmatrix[x+1][y+1] = matrix[x+1][y+1] + quantError*1/16\n\t\t}\n\t}\n\n\tfor x := 0; x < w; x++ {\n\t\tfor y := 0; y < h; y++ {\n\t\t\tcol := color.Gray{Y: uint8(matrix[x][y])}\n\t\t\tgrayInput.Set(x, y, col)\n\t\t}\n\t}\n\n\treturn grayInput\n}", "func (p *p256Point) CopyConditional(src *p256Point, v int) {\r\n\tpMask := uint64(v) - 1\r\n\tsrcMask := ^pMask\r\n\r\n\tfor i, n := range p.xyz {\r\n\t\tp.xyz[i] = (n & pMask) | (src.xyz[i] & srcMask)\r\n\t}\r\n}", "func sm2P256CopyConditional(out, in *sm2P256FieldElement, mask uint32) {\n\tfor i := 0; i < 9; i++ {\n\t\ttmp := mask & (in[i] ^ out[i])\n\t\tout[i] ^= tmp\n\t}\n}", "func blendPixelOverPixel(ic_old,ic_new uint8, al_new float64)(c_res uint8) {\n\n\tal_old := float64(1); _=al_old\n\tc_old := float64(ic_old)\n\tc_new := float64(ic_new)\n\n\talgo1 := c_old*(1-al_new) + c_new*al_new\n\tc_res = uint8( util.Min( util.Round(algo1),255) )\n\t//log.Printf(\"\\t\\t %3.1f + %3.1f = %3.1f\", c_old*(1-al_new),c_new*al_new, algo1)\n\n\treturn \n}", "func (img *FloatImage) ConvolveWrap(kernel *ConvKernel) *FloatImage {\n\treturn img.convolve(kernel, wrapPlaneExtension)\n}", "func (p *Image64) Convolved(k Kernel64) *Image64 {\n\tswitch k.(type) {\n\tcase *separableKernel64:\n\t\treturn p.separableConvolution(k.(*separableKernel64))\n\tdefault:\n\t\treturn p.fullConvolution(k)\n\t}\n\tpanic(\"unreachable\")\n}", "func filter(src <-chan int, dst chan<- int, prime int) {\n\tfor i := range src { // Loop over values received from 'src'.\n\t\tif i%prime != 0 {\n\t\t\tdst <- i // Send 'i' to channel 'dst'.\n\t\t}\n\t}\n}", "func SeparableFilter2D(target uint32, internalformat uint32, width int32, height int32, format uint32, xtype uint32, row unsafe.Pointer, column unsafe.Pointer) {\n C.glowSeparableFilter2D(gpSeparableFilter2D, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), row, column)\n}", "func Filter(dst, src []float64, f func(v float64) bool) []float64 {\n\n\tif dst == nil {\n\t\tdst = make([]float64, 0, len(src))\n\t}\n\n\tdst = dst[:0]\n\tfor _, x := range src {\n\t\tif f(x) {\n\t\t\tdst = append(dst, x)\n\t\t}\n\t}\n\n\treturn dst\n}", "func CopyFiltered(slice interface{}, funcs ...FilterFunc) interface{} {\n\trv := reflect.ValueOf(slice)\n\tif rv.Kind() != reflect.Slice {\n\t\tpanic(\"not a slice\")\n\t}\n\n\tlength := rv.Len()\n\n\tptrfiltered := reflect.New(rv.Type())\n\tptrfiltered.Elem().Set(\n\t\t//reflect.MakeSlice(rv.Type(), 0, length))\n\t\treflect.MakeSlice(rv.Type(), length, length)) // copy is done by dest[j] = src[i], so it's allocated in advance\n\tfiltered := ptrfiltered.Elem()\n\n\treflect.Copy(filtered, rv)\n\n\tFilter(ptrfiltered.Interface(), funcs...)\n\n\treturn filtered.Interface()\n}", "func MakeConvolutionCoder(r, k int, poly []uint16) *ConvolutionCoder {\n\tif len(poly) != r {\n\t\tpanic(\"The number of polys should match the rate\")\n\t}\n\n\treturn &ConvolutionCoder{\n\t\tr: r,\n\t\tk: k,\n\t\tpoly: poly,\n\t\tcc: correctwrap.Correct_convolutional_create(int64(r), int64(k), &poly[0]),\n\t}\n}", "func (filter *Saturation) Process(img *FilterImage) error {\n\tout := img.Image\n\tbounds := out.Bounds()\n\tfor x := bounds.Min.X; x < bounds.Max.X; x++ {\n\t\tfor y := bounds.Min.Y; y < bounds.Max.Y; y++ {\n\t\t\tr, g, b, a := out.At(x, y).RGBA()\n\n\t\t\tgrey := (r + g + b) / 3\n\n\t\t\tnr := Trunc(r + ((Abs(int32(r-grey)) * filter.Strength) / 100))\n\t\t\tng := Trunc(g + ((Abs(int32(g-grey)) * filter.Strength) / 100))\n\t\t\tnb := Trunc(b + ((Abs(int32(b-grey)) * filter.Strength) / 100))\n\n\t\t\tnc := color.NRGBA64{nr, ng, nb, uint16(a)}\n\t\t\tout.Set(x, y, nc)\n\t\t}\n\t}\n\treturn nil\n}", "func Conv(scope *Scope, input tf.Output, filter tf.Output, strides []int64, padding string, optional ...ConvAttr) (output tf.Output) {\n\tif scope.Err() != nil {\n\t\treturn\n\t}\n\tattrs := map[string]interface{}{\"strides\": strides, \"padding\": padding}\n\tfor _, a := range optional {\n\t\ta(attrs)\n\t}\n\topspec := tf.OpSpec{\n\t\tType: \"Conv\",\n\t\tInput: []tf.Input{\n\t\t\tinput, filter,\n\t\t},\n\t\tAttrs: attrs,\n\t}\n\top := scope.AddOperation(opspec)\n\treturn op.Output(0)\n}", "func convDiffThr(wg *sync.WaitGroup, geom *Geom, yst, ny int, fltOn, fltOff *etensor.Float32, imgOn, imgOff, out *etensor.Float32, gain, gainOn float32) {\n\tist := geom.Border.Sub(geom.FiltLt)\n\tfor yi := 0; yi < ny; yi++ {\n\t\ty := yst + yi\n\t\tiy := int(ist.Y + y*geom.Spacing.Y)\n\t\tfor x := 0; x < geom.Out.X; x++ {\n\t\t\tix := ist.X + x*geom.Spacing.X\n\t\t\tvar sumOn, sumOff float32\n\t\t\tfi := 0\n\t\t\tfor fy := 0; fy < geom.FiltSz.Y; fy++ {\n\t\t\t\tfor fx := 0; fx < geom.FiltSz.X; fx++ {\n\t\t\t\t\tidx := imgOn.Offset([]int{iy + fy, ix + fx})\n\t\t\t\t\tsumOn += imgOn.Values[idx] * fltOn.Values[fi]\n\t\t\t\t\tsumOff += imgOff.Values[idx] * fltOff.Values[fi]\n\t\t\t\t\tfi++\n\t\t\t\t}\n\t\t\t}\n\t\t\tdiff := gain * (gainOn*sumOn - sumOff)\n\t\t\tif diff > 0 {\n\t\t\t\tout.Set([]int{0, y, x}, diff)\n\t\t\t\tout.Set([]int{1, y, x}, float32(0))\n\t\t\t} else {\n\t\t\t\tout.Set([]int{0, y, x}, float32(0))\n\t\t\t\tout.Set([]int{1, y, x}, -diff)\n\t\t\t}\n\t\t}\n\t}\n\twg.Done()\n}", "func PMOVZXBW(mx, x operand.Op) { ctx.PMOVZXBW(mx, x) }", "func Resize(img image.Image, width, height int, filter ResampleFilter) *image.RGBA {\n\tif width <= 0 || height <= 0 || img.Bounds().Empty() {\n\t\treturn image.NewRGBA(image.Rect(0, 0, 0, 0))\n\t}\n\n\tsrc := clone.AsRGBA(img)\n\tvar dst *image.RGBA\n\n\t// NearestNeighbor is a special case, it's faster to compute without convolution matrix.\n\tif filter.Support <= 0 {\n\t\tdst = nearestNeighbor(src, width, height)\n\t} else {\n\t\tdst = resampleHorizontal(src, width, filter)\n\t\tdst = resampleVertical(dst, height, filter)\n\t}\n\n\treturn dst\n}", "func CopyPixels(x int32, y int32, width int32, height int32, xtype uint32) {\n C.glowCopyPixels(gpCopyPixels, (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(xtype))\n}", "func StepConvolution() *Step {\n\t// TODO\n\treturn nil\n}", "func SeparableFilter2D(target uint32, internalformat uint32, width int32, height int32, format uint32, xtype uint32, row unsafe.Pointer, column unsafe.Pointer) {\n\tC.glowSeparableFilter2D(gpSeparableFilter2D, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), row, column)\n}", "func (b *Bilateral) Apply(t *Tensor) *Tensor {\n\tdistances := NewTensor(b.KernelSize, b.KernelSize, 1)\n\tcenter := b.KernelSize / 2\n\tfor i := 0; i < b.KernelSize; i++ {\n\t\tfor j := 0; j < b.KernelSize; j++ {\n\t\t\t*distances.At(i, j, 0) = float32((i-center)*(i-center) + (j-center)*(j-center))\n\t\t}\n\t}\n\n\t// Pad with very large negative numbers to prevent\n\t// the filter from incorporating the padding.\n\tpadded := t.Add(100).Pad(center, center, center, center).Add(-100)\n\tout := NewTensor(t.Height, t.Width, t.Depth)\n\tPatches(padded, b.KernelSize, 1, func(idx int, patch *Tensor) {\n\t\tb.blurPatch(distances, patch, out.Data[idx*out.Depth:(idx+1)*out.Depth])\n\t})\n\n\treturn out\n}", "func extractSwatches(src *image.RGBA, numColors int) []colorful.Color {\n\tconst (\n\t\tW = 400\n\t\tH = 75\n\t)\n\tvar swatches []colorful.Color\n\tb := src.Bounds()\n\tsw := W / numColors\n\tfor i := 0; i < numColors; i++ {\n\t\tm := src.SubImage(trimRect(image.Rect(b.Min.X+i*sw, b.Max.Y-H, b.Min.X+(i+1)*sw, b.Max.Y), 10))\n\t\tswatches = append(swatches, toColorful(averageColor(m)))\n\t\tsavePNG(strconv.Itoa(i), m) // for debugging\n\t}\n\tconst dim = 50\n\tm := image.NewRGBA(image.Rect(0, 0, dim*len(swatches), dim))\n\tfor i, c := range swatches {\n\t\tr := image.Rect(i*dim, 0, (i+1)*dim, dim)\n\t\tdraw.Draw(m, r, &image.Uniform{fromColorful(c)}, image.ZP, draw.Src)\n\t}\n\tsavePNG(\"swatches\", m) // for debugging\n\treturn swatches\n}", "func (img *FloatImage) ConvolveWrapWith(kernel *ConvKernel, px planeExtension) {\n\timg.convolveWith(kernel, wrapPlaneExtension)\n}", "func CopyPixels(x int32, y int32, width int32, height int32, xtype uint32) {\n\tC.glowCopyPixels(gpCopyPixels, (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(xtype))\n}", "func (img *FloatImage) ConvolveClampWith(kernel *ConvKernel, px planeExtension) {\n\timg.convolveWith(kernel, clampPlaneExtension)\n}", "func (s *stencilOverdraw) copyImageAspect(ctx context.Context,\n\tcb CommandBuilder,\n\tgs *api.GlobalState,\n\tst *State,\n\ta arena.Arena,\n\tdevice VkDevice,\n\tcmdBuffer VkCommandBuffer,\n\tsrcImgDesc imageDesc,\n\tdstImgDesc imageDesc,\n\textent VkExtent3D,\n\talloc func(v ...interface{}) api.AllocResult,\n\taddCleanup func(func()),\n\tout transform.Writer,\n) {\n\tsrcImg := srcImgDesc.image\n\tdstImg := dstImgDesc.image\n\tcopyBuffer := s.createDepthCopyBuffer(ctx, cb, gs, st, a, device,\n\t\tsrcImg.Info().Fmt(),\n\t\textent.Width(), extent.Height(),\n\t\talloc, addCleanup, out)\n\n\tallCommandsStage := VkPipelineStageFlags(\n\t\tVkPipelineStageFlagBits_VK_PIPELINE_STAGE_ALL_COMMANDS_BIT)\n\tallMemoryAccess := VkAccessFlags(\n\t\tVkAccessFlagBits_VK_ACCESS_MEMORY_WRITE_BIT |\n\t\t\tVkAccessFlagBits_VK_ACCESS_MEMORY_READ_BIT)\n\n\timgBarriers0 := make([]VkImageMemoryBarrier, 2)\n\timgBarriers1 := make([]VkImageMemoryBarrier, 2)\n\t// Transition the src image in and out of the required layouts\n\timgBarriers0[0] = NewVkImageMemoryBarrier(a,\n\t\tVkStructureType_VK_STRUCTURE_TYPE_IMAGE_MEMORY_BARRIER, // sType\n\t\t0, // pNext\n\t\tallMemoryAccess, // srcAccessMask\n\t\tVkAccessFlags(VkAccessFlagBits_VK_ACCESS_TRANSFER_READ_BIT), // dstAccessMask\n\t\tsrcImgDesc.layout, // oldLayout\n\t\tVkImageLayout_VK_IMAGE_LAYOUT_TRANSFER_SRC_OPTIMAL, // newLayout\n\t\t^uint32(0), // srcQueueFamilyIndex: VK_QUEUE_FAMILY_IGNORED\n\t\t^uint32(0), // dstQueueFamilyIndex\n\t\tsrcImg.VulkanHandle(), // image\n\t\tsrcImgDesc.subresource, // subresourceRange\n\t)\n\tsrcFinalLayout := srcImgDesc.layout\n\tif srcFinalLayout == VkImageLayout_VK_IMAGE_LAYOUT_UNDEFINED ||\n\t\tsrcFinalLayout == VkImageLayout_VK_IMAGE_LAYOUT_PREINITIALIZED {\n\t\tsrcFinalLayout = VkImageLayout_VK_IMAGE_LAYOUT_GENERAL\n\t}\n\timgBarriers1[0] = NewVkImageMemoryBarrier(a,\n\t\tVkStructureType_VK_STRUCTURE_TYPE_IMAGE_MEMORY_BARRIER, // sType\n\t\t0, // pNext\n\t\tVkAccessFlags(VkAccessFlagBits_VK_ACCESS_TRANSFER_READ_BIT), // srcAccessMask\n\t\tallMemoryAccess, // dstAccessMask\n\t\tVkImageLayout_VK_IMAGE_LAYOUT_TRANSFER_SRC_OPTIMAL, // oldLayout\n\t\tsrcFinalLayout, // newLayout\n\t\t^uint32(0), // srcQueueFamilyIndex: VK_QUEUE_FAMILY_IGNORED\n\t\t^uint32(0), // dstQueueFamilyIndex\n\t\tsrcImg.VulkanHandle(), // image\n\t\tsrcImgDesc.subresource, // subresourceRange\n\t)\n\n\t// Transition the new image in and out of its required layouts\n\timgBarriers0[1] = NewVkImageMemoryBarrier(a,\n\t\tVkStructureType_VK_STRUCTURE_TYPE_IMAGE_MEMORY_BARRIER, // sType\n\t\t0, // pNext\n\t\tallMemoryAccess, // srcAccessMask\n\t\tVkAccessFlags(VkAccessFlagBits_VK_ACCESS_TRANSFER_WRITE_BIT), // dstAccessMask\n\t\tdstImgDesc.layout, // oldLayout\n\t\tVkImageLayout_VK_IMAGE_LAYOUT_TRANSFER_DST_OPTIMAL, // newLayout\n\t\t^uint32(0), // srcQueueFamilyIndex: VK_QUEUE_FAMILY_IGNORED\n\t\t^uint32(0), // dstQueueFamilyIndex\n\t\tdstImg.VulkanHandle(), // image\n\t\tdstImgDesc.subresource, // subresourceRange\n\t)\n\n\tdstFinalLayout := dstImgDesc.layout\n\tif dstFinalLayout == VkImageLayout_VK_IMAGE_LAYOUT_UNDEFINED ||\n\t\tdstFinalLayout == VkImageLayout_VK_IMAGE_LAYOUT_PREINITIALIZED {\n\t\tdstFinalLayout = VkImageLayout_VK_IMAGE_LAYOUT_GENERAL\n\t}\n\timgBarriers1[1] = NewVkImageMemoryBarrier(a,\n\t\tVkStructureType_VK_STRUCTURE_TYPE_IMAGE_MEMORY_BARRIER, // sType\n\t\t0, // pNext\n\t\tVkAccessFlags(VkAccessFlagBits_VK_ACCESS_TRANSFER_WRITE_BIT), // srcAccessMask\n\t\tallMemoryAccess, // dstAccessMask\n\t\tVkImageLayout_VK_IMAGE_LAYOUT_TRANSFER_DST_OPTIMAL, // oldLayout\n\t\tdstFinalLayout, // newLayout\n\t\t^uint32(0), // srcQueueFamilyIndex: VK_QUEUE_FAMILY_IGNORED\n\t\t^uint32(0), // dstQueueFamilyIndex\n\t\tdstImg.VulkanHandle(), // image\n\t\tdstImgDesc.subresource, // subresourceRange\n\t)\n\n\tbufBarrier := NewVkBufferMemoryBarrier(a,\n\t\tVkStructureType_VK_STRUCTURE_TYPE_BUFFER_MEMORY_BARRIER, // sType\n\t\t0, // pNext\n\t\tVkAccessFlags(VkAccessFlagBits_VK_ACCESS_TRANSFER_WRITE_BIT), // srcAccessMask\n\t\tVkAccessFlags(VkAccessFlagBits_VK_ACCESS_TRANSFER_READ_BIT), // dstAccessMask\n\t\t^uint32(0), // srcQueueFamilyIndex: VK_QUEUE_FAMILY_IGNORED\n\t\t^uint32(0), // dstQueueFamilyIndex\n\t\tcopyBuffer, // buffer\n\t\t0, // offset\n\t\t^VkDeviceSize(0), // size: VK_WHOLE_SIZE\n\t)\n\n\tibCopy := NewVkBufferImageCopy(a,\n\t\t0, // bufferOffset\n\t\t0, // bufferRowLength\n\t\t0, // bufferImageHeight\n\t\tNewVkImageSubresourceLayers(a,\n\t\t\tVkImageAspectFlags(srcImgDesc.aspect), // aspectMask\n\t\t\tsrcImgDesc.subresource.BaseMipLevel(), // mipLevel\n\t\t\tsrcImgDesc.subresource.BaseArrayLayer(), // baseArrayLayer\n\t\t\t1, // layerCount\n\t\t), // srcSubresource\n\t\tNewVkOffset3D(a, 0, 0, 0), // offset\n\t\tNewVkExtent3D(a, extent.Width(), extent.Height(), 1), // extent\n\t)\n\n\tbiCopy := NewVkBufferImageCopy(a,\n\t\t0, // bufferOffset\n\t\t0, // bufferRowLength\n\t\t0, // bufferImageHeight\n\t\tNewVkImageSubresourceLayers(a,\n\t\t\tVkImageAspectFlags(dstImgDesc.aspect), // aspectMask\n\t\t\tdstImgDesc.subresource.BaseMipLevel(), // mipLevel\n\t\t\tdstImgDesc.subresource.BaseArrayLayer(), // baseArrayLayer\n\t\t\t1, // layerCount\n\t\t), // srcSubresource\n\t\tNewVkOffset3D(a, 0, 0, 0), // offset\n\t\tNewVkExtent3D(a, extent.Width(), extent.Height(), 1), // extent\n\t)\n\n\timgBarriers0Data := alloc(imgBarriers0)\n\tibCopyData := alloc(ibCopy)\n\tbufBarrierData := alloc(bufBarrier)\n\tbiCopyData := alloc(biCopy)\n\timgBarriers1Data := alloc(imgBarriers1)\n\n\twriteEach(ctx, out,\n\t\tcb.VkCmdPipelineBarrier(cmdBuffer,\n\t\t\tallCommandsStage, // srcStageMask\n\t\t\tVkPipelineStageFlags(VkPipelineStageFlagBits_VK_PIPELINE_STAGE_TRANSFER_BIT), // dstStageMask\n\t\t\t0, // dependencyFlags\n\t\t\t0, // memoryBarrierCount\n\t\t\tmemory.Nullptr, // pMemoryBarriers\n\t\t\t0, // bufferMemoryBarrierCount\n\t\t\tmemory.Nullptr, // pBufferMemoryBarriers\n\t\t\t2, // imageMemoryBarrierCount\n\t\t\timgBarriers0Data.Ptr(), // pImageMemoryBarriers\n\t\t).AddRead(imgBarriers0Data.Data()),\n\t\tcb.VkCmdCopyImageToBuffer(cmdBuffer,\n\t\t\tsrcImg.VulkanHandle(), // srcImage\n\t\t\tVkImageLayout_VK_IMAGE_LAYOUT_TRANSFER_SRC_OPTIMAL, // srcImageLayout\n\t\t\tcopyBuffer, // dstBuffer\n\t\t\t1, // regionCount\n\t\t\tibCopyData.Ptr(), // pRegions\n\t\t).AddRead(ibCopyData.Data()),\n\t\tcb.VkCmdPipelineBarrier(cmdBuffer,\n\t\t\tVkPipelineStageFlags(VkPipelineStageFlagBits_VK_PIPELINE_STAGE_TRANSFER_BIT), // srcStageMask\n\t\t\tVkPipelineStageFlags(VkPipelineStageFlagBits_VK_PIPELINE_STAGE_TRANSFER_BIT), // dstStageMask\n\t\t\t0, // dependencyFlags\n\t\t\t0, // memoryBarrierCount\n\t\t\tmemory.Nullptr, // pMemoryBarriers\n\t\t\t1, // bufferMemoryBarrierCount\n\t\t\tbufBarrierData.Ptr(), // pBufferMemoryBarriers\n\t\t\t0, // imageMemoryBarrierCount\n\t\t\tmemory.Nullptr, // pImageMemoryBarriers\n\t\t).AddRead(bufBarrierData.Data()),\n\t\tcb.VkCmdCopyBufferToImage(cmdBuffer,\n\t\t\tcopyBuffer, // srcBuffer\n\t\t\tdstImg.VulkanHandle(), // dstImage\n\t\t\tVkImageLayout_VK_IMAGE_LAYOUT_TRANSFER_DST_OPTIMAL, // dstImageLayout\n\t\t\t1, // regionCount\n\t\t\tbiCopyData.Ptr(), // pRegions\n\t\t).AddRead(biCopyData.Data()),\n\t\tcb.VkCmdPipelineBarrier(cmdBuffer,\n\t\t\tVkPipelineStageFlags(VkPipelineStageFlagBits_VK_PIPELINE_STAGE_TRANSFER_BIT), // srcStageMask\n\t\t\tallCommandsStage, // dstStageMask\n\t\t\t0, // dependencyFlags\n\t\t\t0, // memoryBarrierCount\n\t\t\tmemory.Nullptr, // pMemoryBarriers\n\t\t\t0, // bufferMemoryBarrierCount\n\t\t\tmemory.Nullptr, // pBufferMemoryBarriers\n\t\t\t2, // imageMemoryBarrierCount\n\t\t\timgBarriers1Data.Ptr(), // pImageMemoryBarriers\n\t\t).AddRead(imgBarriers1Data.Data()),\n\t)\n}", "func (f *Frame) Crop(w, h, xOffset, yOffset int) error {\n\tif w+xOffset > f.Width {\n\t\treturn fmt.Errorf(\"cropped width + x offset (%d) cannot exceed original width (%d)\",\n\t\t\tw+xOffset, f.Width)\n\t}\n\tif h+yOffset > f.Height {\n\t\treturn fmt.Errorf(\"cropped height + y offset (%d) cannot exceed original height (%d)\",\n\t\t\th+yOffset, f.Height)\n\t}\n\tnewY := make([]byte, 0, w*h)\n\tfor y := 0; y < h; y++ {\n\t\tyt := y + yOffset\n\t\tx0 := yt*f.Width + xOffset\n\t\tx1 := x0 + w\n\t\tnewY = append(newY, f.Y[x0:x1]...)\n\t}\n\tf.Y = newY\n\txss := xSubsamplingFactor[f.Chroma]\n\tyss := ySubsamplingFactor[f.Chroma]\n\tnewCb := make([]byte, 0, w/xss*h/yss)\n\tnewCr := make([]byte, 0, w/xss*h/yss)\n\tfor y := 0; y < h/yss; y++ {\n\t\tyt := y + yOffset/yss\n\t\tx0 := yt*f.Width/xss + xOffset/xss\n\t\tx1 := x0 + w/xss\n\t\tnewCb = append(newCb, f.Cb[x0:x1]...)\n\t\tnewCr = append(newCr, f.Cr[x0:x1]...)\n\t}\n\tf.Cb = newCb\n\tf.Cr = newCr\n\tif len(f.Alpha) > 0 {\n\t\tnewAlpha := make([]byte, 0, w*h)\n\t\tfor y := 0; y < h; y++ {\n\t\t\tyt := y + yOffset\n\t\t\tx0 := yt*f.Width + xOffset\n\t\t\tx1 := x0 + w\n\t\t\tnewAlpha = append(newAlpha, f.Alpha[x0:x1]...)\n\t\t}\n\t\tf.Alpha = newAlpha\n\t}\n\tf.Width = w\n\tf.Height = h\n\treturn nil\n}", "func (gs *GoShot) ApplyFilters(full bool) {\n\tglog.V(2).Infof(\"ApplyFilters: %d filters\", len(gs.Filters))\n\tfilteredImage := image.Image(gs.OriginalScreenshot)\n\tfor _, filter := range gs.Filters {\n\t\tfilteredImage = filter.Apply(filteredImage)\n\t}\n\n\tif gs.Screenshot == gs.OriginalScreenshot || gs.Screenshot.Rect.Dx() != gs.CropRect.Dx() || gs.Screenshot.Rect.Dy() != gs.CropRect.Dy() {\n\t\t// Recreate image buffer.\n\t\tcrop := image.NewRGBA(image.Rect(0, 0, gs.CropRect.Dx(), gs.CropRect.Dy()))\n\t\tgs.Screenshot = crop\n\t\tfull = true // Regenerate the full buffer.\n\t}\n\tif full {\n\t\tdraw.Src.Draw(gs.Screenshot, gs.Screenshot.Rect, filteredImage, gs.CropRect.Min)\n\t} else {\n\t\tvar tgtRect image.Rectangle\n\t\ttgtRect.Min = image.Point{X: gs.viewPort.viewX, Y: gs.viewPort.viewY}\n\t\ttgtRect.Max = tgtRect.Min.Add(image.Point{X: gs.viewPort.viewW, Y: gs.viewPort.viewH})\n\t\tsrcPoint := gs.CropRect.Min.Add(tgtRect.Min)\n\t\tdraw.Src.Draw(gs.Screenshot, tgtRect, filteredImage, srcPoint)\n\t}\n\n\tif gs.viewPort != nil {\n\t\tgs.viewPort.renderCache()\n\t\tgs.viewPort.Refresh()\n\t}\n\tif gs.miniMap != nil {\n\t\tgs.miniMap.renderCache()\n\t\tgs.miniMap.Refresh()\n\t}\n}", "func Brightness(percentage float32) Filter {\n\tif percentage == 0 {\n\t\treturn &copyimageFilter{}\n\t}\n\n\tshift := minf32(maxf32(percentage, -100), 100) / 100\n\n\treturn &colorchanFilter{\n\t\tfn: func(x float32) float32 {\n\t\t\treturn x + shift\n\t\t},\n\t\tlut: false,\n\t}\n}", "func (i *ImageBuf) CopyPixels(src *ImageBuf) error {\n\tok := bool(C.ImageBuf_copy_pixels(i.ptr, src.ptr))\n\truntime.KeepAlive(i)\n\truntime.KeepAlive(src)\n\tif !ok {\n\t\treturn i.LastError()\n\t}\n\treturn nil\n}", "func VBROADCASTI128(m, y operand.Op) { ctx.VBROADCASTI128(m, y) }", "func SpectralConvolution(spectrum []int) []int {\n\tvar convolution []int\n\tfor i := 0; i < len(spectrum)-1; i++ {\n\t\tfor j := i + 1; j < len(spectrum); j++ {\n\t\t\tval := spectrum[j] - spectrum[i]\n\t\t\tif val > 0 {\n\t\t\t\tconvolution = append(convolution, val)\n\t\t\t}\n\t\t}\n\t}\n\treturn convolution\n}", "func p256CopyConditional(out, in *[p256Limbs]uint32, mask uint32) {\n\tfor i := 0; i < p256Limbs; i++ {\n\t\ttmp := mask & (in[i] ^ out[i])\n\t\tout[i] ^= tmp\n\t}\n}", "func NewConvolutionalLayer(\n\tinputSize, kernelSize, stride, padding []int,\n\tGPUDriver *driver.Driver,\n\tGPUCtx *driver.Context,\n\tTensorOperator *TensorOperator,\n) *Conv2D {\n\t// argumentsMustBeValid(inputSize, kernelSize, stride, padding)\n\n\tl := &Conv2D{\n\t\tinputSize: inputSize,\n\t\tkernelSize: kernelSize,\n\t\tstride: stride,\n\t\tpadding: padding,\n\t\tGPUDriver: GPUDriver,\n\t\tGPUCtx: GPUCtx,\n\t\tTensorOperator: TensorOperator,\n\t}\n\tl.calculateOutputSize()\n\tl.loadKernels()\n\tl.allocateMemory()\n\n\treturn l\n}", "func CopyPixels(x int32, y int32, width int32, height int32, xtype uint32) {\n\tsyscall.Syscall6(gpCopyPixels, 5, uintptr(x), uintptr(y), uintptr(width), uintptr(height), uintptr(xtype), 0)\n}", "func (img *FloatImage) ConvolveClamp(kernel *ConvKernel) *FloatImage {\n\treturn img.convolve(kernel, clampPlaneExtension)\n}", "func newImageBinaryChannels(imgSrc image.Image, colorChannelTypes ...channelType) []*imageBinaryChannel {\n\tchannels := make([]*imageBinaryChannel, 3)\n\tmax := imgSrc.Bounds().Max\n\tw, h := max.X, max.Y\n\tfor i, channelType := range colorChannelTypes {\n\t\tcolorChannel := image.NewGray(image.Rectangle{Max: image.Point{w, h}})\n\t\tfor x := 0; x < w; x++ {\n\t\t\tfor y := 0; y < h; y++ {\n\t\t\t\tcolorPixel := imgSrc.At(x, y).(color.NRGBA)\n\t\t\t\tvar c uint8\n\t\t\t\tswitch channelType {\n\t\t\t\tcase red:\n\t\t\t\t\tc = colorPixel.R\n\t\t\t\tcase green:\n\t\t\t\t\tc = colorPixel.G\n\t\t\t\tcase blue:\n\t\t\t\t\tc = colorPixel.B\n\t\t\t\t}\n\t\t\t\tgrayPixel := color.Gray{Y: c}\n\t\t\t\tcolorChannel.Set(x, y, grayPixel)\n\t\t\t}\n\t\t}\n\t\tchannels[i] = newImageBinaryChannel(colorChannel, channelType)\n\t}\n\treturn channels\n}", "func PixelPusher() (chan<- draw.Image, <-chan *Click) {\n\taddr := fmt.Sprintf(\"localhost:%s\", os.Getenv(\"PORT\"))\n\tlog.Printf(\"Starting pixel on %s\", addr)\n\tl, err := net.Listen(\"tcp\", addr)\n\tif err != nil {\n\t\tlog.Fatalf(\"Could not open socket on %s: %s\", addr, err)\n\t}\n\n\tc, err := l.Accept()\n\tif err != nil {\n\t\tlog.Fatalf(\"Could not accept connection: %s\", err)\n\t}\n\n\treturn commitLoop(c), clickDecoder(c)\n}", "func VPMOVZXBW(ops ...operand.Op) { ctx.VPMOVZXBW(ops...) }", "func Saturation(percentage float32) Filter {\n\tp := 1 + minf32(maxf32(percentage, -100), 500)/100\n\tif p == 1 {\n\t\treturn &copyimageFilter{}\n\t}\n\n\treturn &colorFilter{\n\t\tfn: func(px pixel) pixel {\n\t\t\th, s, l := convertRGBToHSL(px.R, px.G, px.B)\n\t\t\ts *= p\n\t\t\tif s > 1 {\n\t\t\t\ts = 1\n\t\t\t}\n\t\t\tr, g, b := convertHSLToRGB(h, s, l)\n\t\t\treturn pixel{r, g, b, px.A}\n\t\t},\n\t}\n}", "func Binaryzation(src [][][]uint8, threshold int) [][][]uint8 {\n\timgMatrix := RGB2Gray(src)\n\t\n\theight:=len(imgMatrix)\n\twidth:=len(imgMatrix[0])\n\tfor i:=0; i<height; i++ {\n\t\tfor j:=0; j<width; j++ {\n\t\t\tvar rgb int = int(imgMatrix[i][j][0])+int(imgMatrix[i][j][1])+int(imgMatrix[i][j][2])\n\t\t\tif rgb > threshold {\n\t\t\t\trgb = 255\n\t\t\t}else{\n\t\t\t\trgb = 0\n\t\t\t}\n\t\t\timgMatrix[i][j][0]=uint8(rgb)\n\t\t\timgMatrix[i][j][1]=uint8(rgb)\n\t\t\timgMatrix[i][j][2]=uint8(rgb)\n\t\t}\n\t}\n\t\n\treturn imgMatrix\n}", "func dontModifyConvolutionMatrixWeights(im ImageMatrix, imagePositionX int, imagePositionY int, kernelPixelX int, kernelPixel int, colour color.RGBA, distance float64) int {\n\treturn 1\n}", "func updateFilter (filter []byte, mappedBit uint64) {\n oldFilterByte := filter[findByte(mappedBit)]\n filter[findByte(mappedBit)] = oldFilterByte | filterByte(mappedBit)\n}", "func (_Contract *ContractFilterer) FilterBuyPixel(opts *bind.FilterOpts, id [][32]byte, seller []common.Address, buyer []common.Address) (*ContractBuyPixelIterator, error) {\n\n\tvar idRule []interface{}\n\tfor _, idItem := range id {\n\t\tidRule = append(idRule, idItem)\n\t}\n\tvar sellerRule []interface{}\n\tfor _, sellerItem := range seller {\n\t\tsellerRule = append(sellerRule, sellerItem)\n\t}\n\tvar buyerRule []interface{}\n\tfor _, buyerItem := range buyer {\n\t\tbuyerRule = append(buyerRule, buyerItem)\n\t}\n\n\tlogs, sub, err := _Contract.contract.FilterLogs(opts, \"BuyPixel\", idRule, sellerRule, buyerRule)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\treturn &ContractBuyPixelIterator{contract: _Contract.contract, event: \"BuyPixel\", logs: logs, sub: sub}, nil\n}", "func square(img *image.Paletted, p squareParams) {\n\tfor x := p.from.x; x < p.to.x; x++ {\n\t\tfor y := p.from.y; y < p.to.y; y++ {\n\t\t\timg.Set(x, y, p.c)\n\t\t}\n\t}\n}", "func (img *ByteImage) pixels() [][]byte {\n\tbyteIdx := 0\n\tpixels := make([][]byte, img.height)\n\tfor rowIdx := 0; rowIdx < img.height; rowIdx++ {\n\t\tpixels[rowIdx] = make([]byte, img.width)\n\t\tfor colIdx := 0; colIdx < img.width; colIdx++ {\n\t\t\tpixels[rowIdx][colIdx] = img.bytes[byteIdx]\n\t\t\tbyteIdx++\n\t\t}\n\t}\n\treturn pixels\n}", "func colorDestinationImage(\n\tdestinationImage *image.NRGBA,\n\tsourceImage image.Image,\n\tdestinationCoordinates []complex128,\n\ttransformedCoordinates []complex128,\n\tcolorValueBoundMin complex128,\n\tcolorValueBoundMax complex128,\n) {\n\tsourceImageBounds := sourceImage.Bounds()\n\tfor index, transformedCoordinate := range transformedCoordinates {\n\t\tvar sourceColorR, sourceColorG, sourceColorB, sourceColorA uint32\n\n\t\tif real(transformedCoordinate) < real(colorValueBoundMin) ||\n\t\t\timag(transformedCoordinate) < imag(colorValueBoundMin) ||\n\t\t\treal(transformedCoordinate) > real(colorValueBoundMax) ||\n\t\t\timag(transformedCoordinate) > imag(colorValueBoundMax) {\n\t\t\tsourceColorR, sourceColorG, sourceColorB, sourceColorA = 0, 0, 0, 0\n\t\t} else {\n\t\t\tsourceImagePixelX := int(mathutility.ScaleValueBetweenTwoRanges(\n\t\t\t\tfloat64(real(transformedCoordinate)),\n\t\t\t\treal(colorValueBoundMin),\n\t\t\t\treal(colorValueBoundMax),\n\t\t\t\tfloat64(sourceImageBounds.Min.X),\n\t\t\t\tfloat64(sourceImageBounds.Max.X),\n\t\t\t))\n\t\t\tsourceImagePixelY := int(mathutility.ScaleValueBetweenTwoRanges(\n\t\t\t\tfloat64(imag(transformedCoordinate)),\n\t\t\t\timag(colorValueBoundMin),\n\t\t\t\timag(colorValueBoundMax),\n\t\t\t\tfloat64(sourceImageBounds.Min.Y),\n\t\t\t\tfloat64(sourceImageBounds.Max.Y),\n\t\t\t))\n\t\t\tsourceColorR, sourceColorG, sourceColorB, sourceColorA = sourceImage.At(sourceImagePixelX, sourceImagePixelY).RGBA()\n\t\t}\n\n\t\tdestinationPixelX := int(real(destinationCoordinates[index]))\n\t\tdestinationPixelY := int(imag(destinationCoordinates[index]))\n\n\t\tdestinationImage.Set(\n\t\t\tdestinationPixelX,\n\t\t\tdestinationPixelY,\n\t\t\tcolor.NRGBA{\n\t\t\t\tR: uint8(sourceColorR >> 8),\n\t\t\t\tG: uint8(sourceColorG >> 8),\n\t\t\t\tB: uint8(sourceColorB >> 8),\n\t\t\t\tA: uint8(sourceColorA >> 8),\n\t\t\t},\n\t\t)\n\t}\n}", "func Sigmoid(midpoint, factor float32) Filter {\n\ta := minf32(maxf32(midpoint, 0), 1)\n\tb := absf32(factor)\n\tsig0 := sigmoid(a, b, 0)\n\tsig1 := sigmoid(a, b, 1)\n\te := float32(1.0e-5)\n\n\treturn &colorchanFilter{\n\t\tfn: func(x float32) float32 {\n\t\t\tif factor == 0 {\n\t\t\t\treturn x\n\t\t\t} else if factor > 0 {\n\t\t\t\tsig := sigmoid(a, b, x)\n\t\t\t\treturn (sig - sig0) / (sig1 - sig0)\n\t\t\t} else {\n\t\t\t\targ := minf32(maxf32((sig1-sig0)*x+sig0, e), 1-e)\n\t\t\t\treturn a - logf32(1/arg-1)/b\n\t\t\t}\n\t\t},\n\t\tlut: true,\n\t}\n}", "func filter(source <-chan int, destination chan<- int, prime int) {\n\tfor i := range source {\n\t\tif i%prime != 0 {\n\t\t\tdestination <- i // Send 'i' to 'destination'.\n\t\t}\n\t}\n}", "func (v *Data) Filter(filter func(e PicData) bool) {\n\tdv := *v\n\n\tvar i int\n\tfor _, e := range dv {\n\t\tif filter(e) {\n\t\t\tdv[i] = e\n\t\t\ti++\n\t\t}\n\t}\n\n\tv.Truncate(i)\n}", "func ycbcrToGray(dst *image.Gray, src *image.YCbCr) {\n\tfor i := 0; i < src.Rect.Dy(); i++ {\n\t\tdstH := i * dst.Stride\n\t\tsrcH := i * src.YStride\n\t\tcopy(dst.Pix[dstH:dstH+dst.Stride], src.Y[srcH:srcH+dst.Stride])\n\t}\n}", "func copyNotify(dst io.Writer, src io.Reader) chan int {\n\tret := make(chan int)\n\tgo func() {\n\t\tio.Copy(dst, src)\n\t\tret <- 1\n\t}()\n\treturn ret\n}", "func (gip *GiftImageProcessor) Hipsterize(src image.Image, buf *bytes.Buffer) error {\n\n\tdst := image.NewRGBA(gip.filterChain.Bounds(src.Bounds()))\n\n\t// Use Draw func to apply the filters to src and store the result in dst:\n\tgip.filterChain.Draw(dst, src)\n\n\treturn jpeg.Encode(buf, dst, nil)\n}", "func (cc *ConvolutionCoder) Encode(data []byte) (output []byte) {\n\tframeBits := cc.EncodedSize(len(data))\n\tbl := frameBits/8 + 1\n\n\tif frameBits%8 == 0 {\n\t\tbl -= 1\n\t}\n\n\toutput = make([]byte, bl)\n\n\tcorrectwrap.Correct_convolutional_encode(cc.cc, &data[0], int64(len(data)), &output[0])\n\n\treturn output\n}", "func ImageToGraphPixels(colorMapped ColorMappedImage, args Args) Graph {\n\tbounds := colorMapped.image.Bounds()\n\tgraph := Graph{bounds: bounds}\n\tfor y := 0; y < bounds.Max.Y; y++ {\n\t\tfor x := 0; x < bounds.Max.X; x++ {\n\t\t\tgray := colorMapped.image.GrayAt(x, y)\n\t\t\tcommits := colorMapped.colorMap[int(gray.Y)]\n\t\t\tgraph.pixels = append(graph.pixels, GraphPixel{\n\t\t\t\tpixelDaysAgo(x, y, bounds.Max.X, args.weeksAgo), commits,\n\t\t\t})\n\t\t}\n\t}\n\treturn graph\n}", "func Copy(dst Mutable, src Const) {\n\tif err := errIfDimsNotEq(src, dst); err != nil {\n\t\tpanic(err)\n\t}\n\n\tm, n := src.Dims()\n\tfor i := 0; i < m; i++ {\n\t\tfor j := 0; j < n; j++ {\n\t\t\tdst.Set(i, j, src.At(i, j))\n\t\t}\n\t}\n}", "func (T triangle) rasterize( C canvas) {\n\tmask:=make([][]bool,C.yres,C.yres)\n\tfor i := 0; i < C.yres; i++ {\n\t\tmaskpre:=make([]bool,C.xres,C.xres )\n\t\tmask[i]=maskpre\n\t}\n\tp0:=[2]float64{T.p0.x/T.p0.z*C.res,T.p0.y/T.p0.z*C.res}\n\tp1:=[2]float64{T.p1.x/T.p1.z*C.res,T.p1.y/T.p1.z*C.res}\n\tp2:=[2]float64{T.p2.x/T.p2.z*C.res,T.p2.y/T.p2.z*C.res}\n\tedges:=[3][2][2]float64{[2][2]float64{p0,p1},[2][2]float64{p1,p2},[2][2]float64{p2,p0}}\n\n\tminy,maxy:=2147483647,0\n\tfor _,edge := range edges {\n\t\tif edge[0][1]>edge[1][1] {\n\t\t\tedge[0],edge[1]=edge[1],edge[0]\n\t\t}\n\t\ty0:=int( edge[0][1]-0.5)-C.y0\n\t\ty1:=int( edge[1][1]-0.5)-C.y0\n\t\tif y0 < 0 {\n\t\t\ty0=0\n\t\t} else if y0 >= C.yres {\n\t\t\ty0=C.yres-1\n\t\t}\n\t\tif y1 <0 {\n\t\t\ty1=0\n\t\t} else if y1 >= C.yres {\n\t\t\ty1=C.yres-1\n\t\t}\n\t\tif y0<miny {\n\t\t\tminy=y0\n\t\t}\n\t\tif y1>maxy {\n\t\t\tmaxy=y1\n\t\t}\n\t\tfor i := y0; i <= y1; i++ {\n\t\t\tfloati:=float64(i+C.y0)+0.5\n\t \t\tslopeinv:= (edge[0][0]-edge[1][0])/(edge[0][1]-edge[1][1])\n\t\t\tcrosx:=edge[0][0]+slopeinv*(floati-edge[0][1])\n\t\t\txindex:=int(crosx+0.5)-C.x0\n\t\t\tif xindex<C.xres {\n\t\t\t\tif xindex>=0 {\n\t\t\t\t\tmask[i][xindex]= !mask[i][xindex]\n\t\t\t\t} else{\n\t\t\t\t\tmask[i][0]= !mask[i][0]\n\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\tfor i :=miny ; i < maxy ; i++ {\n\t\tinside:=false\n\t\tfor j := 0; j < C.xres; j++ {\n\t\t\tif mask[i][j]{\n\t\t\t\tinside= !inside\n\t\t\t\tif !inside{\n\t\t\t\t\tbreak\n\t\t\t\t}\n\t\t\t}\n\t\t\tif inside {\n\t\t\t\tz:=T.p0dotn/T.n.dot(vec3{float64(j+C.x0)/C.res,float64(i+C.y0)/C.res,1.})\n\t\t\t\tif z<C.z[i][j] {\n\t\t\t\t\tC.z[i][j]=z\n\t\t\t\t\tC.pic[i][j]=T.color\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n}", "func reflectPixels(pixels [7][7]bool) [7][7]bool {\n\t// Reflect over the middle line\n\tfor i := 0; i < 7; i++ {\n\t\tfor j := 0; j < 7; j++ {\n\t\t\tpixels[6-i][j] = pixels[i][j]\n\t\t}\n\t}\n\treturn pixels\n}", "func ExampleConv2() {\n\n\tconv := cnns.NewConvLayer(&tensor.TDsize{X: 5, Y: 5, Z: 3}, 1, 3, 2)\n\trelu := cnns.NewReLULayer(conv.GetOutputSize())\n\tmaxpool := cnns.NewPoolingLayer(relu.GetOutputSize(), 2, 2, \"max\", \"valid\")\n\tfullyconnected := cnns.NewFullyConnectedLayer(maxpool.GetOutputSize(), 2)\n\n\tnet := cnns.WholeNet{\n\t\tLP: cnns.NewLearningParametersDefault(),\n\t}\n\tnet.Layers = append(net.Layers, conv)\n\tnet.Layers = append(net.Layers, relu)\n\tnet.Layers = append(net.Layers, maxpool)\n\tnet.Layers = append(net.Layers, fullyconnected)\n\n\tredChannel := mat.NewDense(5, 5, []float64{\n\t\t1, 0, 1, 0, 2,\n\t\t1, 1, 3, 2, 1,\n\t\t1, 1, 0, 1, 1,\n\t\t2, 3, 2, 1, 3,\n\t\t0, 2, 0, 1, 0,\n\t})\n\tgreenChannel := mat.NewDense(5, 5, []float64{\n\t\t1, 0, 0, 1, 0,\n\t\t2, 0, 1, 2, 0,\n\t\t3, 1, 1, 3, 0,\n\t\t0, 3, 0, 3, 2,\n\t\t1, 0, 3, 2, 1,\n\t})\n\tblueChannel := mat.NewDense(5, 5, []float64{\n\t\t2, 0, 1, 2, 1,\n\t\t3, 3, 1, 3, 2,\n\t\t2, 1, 1, 1, 0,\n\t\t3, 1, 3, 2, 0,\n\t\t1, 1, 2, 1, 1,\n\t})\n\n\tkernel1R := mat.NewDense(3, 3, []float64{\n\t\t0, 1, 0,\n\t\t0, 0, 2,\n\t\t0, 1, 0,\n\t})\n\tkernel1G := mat.NewDense(3, 3, []float64{\n\t\t2, 1, 0,\n\t\t0, 0, 0,\n\t\t0, 3, 0,\n\t})\n\tkernel1B := mat.NewDense(3, 3, []float64{\n\t\t1, 0, 0,\n\t\t1, 0, 0,\n\t\t0, 0, 2,\n\t})\n\n\tkernel2R := mat.NewDense(3, 3, []float64{\n\t\t0, -1, 0,\n\t\t0, 0, 2,\n\t\t0, 1, 0,\n\t})\n\tkernel2G := mat.NewDense(3, 3, []float64{\n\t\t2, 1, 0,\n\t\t0, 0, 0,\n\t\t0, -3, 0,\n\t})\n\tkernel2B := mat.NewDense(3, 3, []float64{\n\t\t1, 0, 0,\n\t\t1, 0, 0,\n\t\t0, 0, -2,\n\t})\n\n\timg2 := &mat.Dense{}\n\timg2.Stack(redChannel, greenChannel)\n\timage := &mat.Dense{}\n\timage.Stack(img2, blueChannel)\n\n\tkernel1 := &mat.Dense{}\n\tkernel1.Stack(kernel1R, kernel1G)\n\tconvCustomWeights1 := &mat.Dense{}\n\tconvCustomWeights1.Stack(kernel1, kernel1B)\n\n\tkernel2 := &mat.Dense{}\n\tkernel2.Stack(kernel2R, kernel2G)\n\tconvCustomWeights2 := &mat.Dense{}\n\tconvCustomWeights2.Stack(kernel2, kernel2B)\n\tconv.SetCustomWeights([]*mat.Dense{convCustomWeights1, convCustomWeights2})\n\n\tfcCustomWeights := mat.NewDense(2, maxpool.GetOutputSize().Total(), []float64{\n\t\t-0.19908814, 0.01521263,\n\t\t0.17908468, -0.28144695,\n\t})\n\tfullyconnected.SetCustomWeights([]*mat.Dense{fcCustomWeights})\n\n\tfmt.Printf(\"Layers weights:\\n\")\n\tfor i := range net.Layers {\n\t\tfmt.Printf(\"%s #%d weights:\\n\", net.Layers[i].GetType(), i)\n\t\tnet.Layers[i].PrintWeights()\n\t}\n\n\tfmt.Println(\"\\tDoing training....\")\n\tfor e := 0; e < 1; e++ {\n\t\terr := net.FeedForward(image)\n\t\tif err != nil {\n\t\t\tlog.Printf(\"Feedforward caused error: %s\", err.Error())\n\t\t\treturn\n\t\t}\n\n\t\tdesired := mat.NewDense(2, 1, []float64{0.15, 0.8})\n\t\terr = net.Backpropagate(desired)\n\t\tif err != nil {\n\t\t\tlog.Printf(\"Backpropagate caused error: %s\", err.Error())\n\t\t\treturn\n\t\t}\n\n\t\tfmt.Printf(\"Epoch #%d. New layers weights\\n\", e)\n\t\tfor i := range net.Layers {\n\t\t\tfmt.Printf(\"%s #%d weights on epoch #%d:\\n\", net.Layers[i].GetType(), i, e)\n\t\t\tnet.Layers[i].PrintWeights()\n\t\t}\n\t}\n}", "func downscaleImage(src image.Image, w, h int) image.Image {\n\tdst := image.NewRGBA(image.Rect(0, 0, w, h))\n\n\tsrcwidth := src.Bounds().Dx()\n\tsrcheight := src.Bounds().Dy()\n\tfor y := dst.Bounds().Min.Y; y < dst.Bounds().Max.Y; y++ {\n\t\tfor x := dst.Bounds().Min.X; x < dst.Bounds().Max.X; x++ {\n\t\t\t//c := src.At(x*srcwidth/w, y*srcheight/h) // nearest-neighbour interpolation\n\t\t\tc := avgInterpolateAt(src, x*srcwidth/w, y*srcheight/h, srcwidth/w, srcheight/h)\n\t\t\tdst.Set(x, y, c)\n\t\t}\n\t}\n\treturn dst\n}", "func NewFilter(bitmapSize int32) Filter {\n\treturn Filter{\n\t\tbitmapSize: bitmapSize,\n\t\tbitmap: make([]bool, bitmapSize, bitmapSize),\n\t\tnumberMapper: NewNumberMapper(minInt32, maxInt32, 0, bitmapSize-1),\n\t}\n}", "func DecodePixelsFromImage(img image.Image, offsetX, offsetY int) []*Pixel {\n var pixels []*Pixel\n\n for y := 0; y <= img.Bounds().Max.Y; y++ {\n for x := 0; x <= img.Bounds().Max.X; x++ {\n p := &Pixel{\n Point: image.Point{X: x + offsetX, Y: y + offsetY},\n Color: img.At(x, y),\n }\n pixels = append(pixels, p)\n }\n }\n\n return pixels\n}", "func PreparePic(dx, dy int) [][]uint8 {\n\trows := make([][]uint8, dy)\n\tfor i := range rows {\n\t\trows[i] = make([]uint8, dx)\n\t}\n\treturn rows\n}", "func PMOVSXBW(mx, x operand.Op) { ctx.PMOVSXBW(mx, x) }", "func drawGray(dst *image.Gray, src image.Image) {\n\tdraw.Draw(dst, dst.Bounds(), src, src.Bounds().Min, draw.Src)\n}" ]
[ "0.70984167", "0.70973545", "0.6838712", "0.6342118", "0.6339697", "0.62980014", "0.60681903", "0.6057519", "0.5994998", "0.5912075", "0.55511224", "0.5529849", "0.54788923", "0.5447513", "0.54171586", "0.54022473", "0.53360295", "0.5306004", "0.5270163", "0.522178", "0.5194609", "0.5193401", "0.5141425", "0.5115148", "0.51134753", "0.50552803", "0.49723938", "0.49520412", "0.4948905", "0.4933534", "0.4925671", "0.492449", "0.47863796", "0.477113", "0.47652638", "0.47535947", "0.47401014", "0.47190985", "0.47154763", "0.4674138", "0.46739554", "0.4669287", "0.46422282", "0.46379024", "0.46355975", "0.4592654", "0.4584696", "0.45453766", "0.45421445", "0.45229748", "0.4519891", "0.4518591", "0.45168126", "0.44901568", "0.4483658", "0.4471696", "0.44539723", "0.4449244", "0.44361475", "0.4429989", "0.4420539", "0.4420015", "0.44162628", "0.44113907", "0.4396013", "0.43916535", "0.43889552", "0.43878382", "0.43840003", "0.43821222", "0.43366012", "0.4320696", "0.4312442", "0.43038327", "0.430359", "0.42935678", "0.4282458", "0.4280435", "0.42774746", "0.427738", "0.4276239", "0.42655626", "0.42526346", "0.42514366", "0.42501774", "0.42433286", "0.42387912", "0.42378467", "0.42307916", "0.4228241", "0.42263058", "0.42251086", "0.4224782", "0.42145061", "0.42068073", "0.42049706", "0.42029288", "0.4202458", "0.41951886", "0.41855854" ]
0.6804048
3
copy pixels into a twodimensional convolution filter
func CopyConvolutionFilter2D(target uint32, internalformat uint32, x int32, y int32, width int32, height int32) { C.glowCopyConvolutionFilter2D(gpCopyConvolutionFilter2D, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func CopyConvolutionFilter2D(target uint32, internalformat uint32, x int32, y int32, width int32, height int32) {\n C.glowCopyConvolutionFilter2D(gpCopyConvolutionFilter2D, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CopyConvolutionFilter1D(target uint32, internalformat uint32, x int32, y int32, width int32) {\n C.glowCopyConvolutionFilter1D(gpCopyConvolutionFilter1D, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func ConvolutionFilter2D(target uint32, internalformat uint32, width int32, height int32, format uint32, xtype uint32, image unsafe.Pointer) {\n C.glowConvolutionFilter2D(gpConvolutionFilter2D, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), image)\n}", "func ConvolutionFilter2D(target uint32, internalformat uint32, width int32, height int32, format uint32, xtype uint32, image unsafe.Pointer) {\n\tC.glowConvolutionFilter2D(gpConvolutionFilter2D, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), image)\n}", "func CopyConvolutionFilter1D(target uint32, internalformat uint32, x int32, y int32, width int32) {\n\tC.glowCopyConvolutionFilter1D(gpCopyConvolutionFilter1D, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func Convolve(src, dst []float64, kernel []float64, border Border) {\n\twidth := len(kernel)\n\thalfWidth := width / 2\n\tfor i := range dst {\n\t\tk := i - halfWidth\n\t\tvar sum float64\n\t\tif k >= 0 && k <= len(src)-width {\n\t\t\tfor j, x := range kernel {\n\t\t\t\tsum += src[k+j] * x\n\t\t\t}\n\t\t} else {\n\t\t\tfor j, x := range kernel {\n\t\t\t\tsum += border.Interpolate(src, k+j) * x\n\t\t\t}\n\t\t}\n\t\tdst[i] = sum\n\t}\n}", "func (img *FloatImage) convolve(kernel *ConvKernel, px planeExtension) *FloatImage {\n\n\t// convolve each plane independently:\n\tres := new([3][]float32)\n\tfor i := 0; i < 3; i++ {\n\t\tconvolvePlane(&img.Ip[i], kernel, img.Width, img.Height, px)\n\t}\n\n\treturn &FloatImage{\n\t\tIp: *res,\n\t\tWidth: img.Width,\n\t\tHeight: img.Height,\n\t}\n}", "func ConstructedConv2D(m *Model, x tensor.Tensor, kernelH int, kernelW int, filters int) tensor.Tensor {\n\tslen := len(x.Shape())\n\tfAxis := slen - 1\n\twAxis := slen - 2\n\thAxis := slen - 3\n\tinFilters := x.Shape()[fAxis]\n\tinW := x.Shape()[wAxis]\n\tinH := x.Shape()[hAxis]\n\n\twShape := onesLike(x)\n\twShape[fAxis] = filters\n\twShape[wAxis] = inFilters * kernelH * kernelW\n\n\tbShape := onesLike(x)\n\tbShape[fAxis] = filters\n\n\tweight := m.AddWeight(wShape...)\n\tbias := m.AddBias(bShape...)\n\n\tslices := make([]tensor.Tensor, 0, kernelH*kernelW)\n\n\tfor hoff := 0; hoff < kernelH; hoff++ {\n\t\thslice := tensor.Slice(x, hAxis, hoff, inH-kernelH+1+hoff)\n\t\tfor woff := 0; woff < kernelW; woff++ {\n\t\t\twslice := tensor.Slice(hslice, wAxis, woff, inW-kernelW+1+woff)\n\t\t\tslices = append(slices, wslice)\n\t\t}\n\t}\n\n\tx = tensor.Concat(fAxis, slices...)\n\tx = tensor.MatMul(x, weight, wAxis, fAxis)\n\tx = tensor.Add(x, bias)\n\n\treturn x\n}", "func ConvolutionFilter1D(target uint32, internalformat uint32, width int32, format uint32, xtype uint32, image unsafe.Pointer) {\n C.glowConvolutionFilter1D(gpConvolutionFilter1D, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), image)\n}", "func applyConvolutionToPixel(im ImageMatrix, x int, y int, cmSize int, column []color.RGBA, cm ConvolutionMatrix, conFunc func(ImageMatrix, int, int, int, int, color.RGBA, float64) int) {\n\tcurrentColour := im[x][y]\n\tredTotal := 0\n\tgreenTotal := 0\n\tblueTotal := 0\n\tweight := 0\n\n\tkernelMatrix := im.GetKernelMatrix(x, y, cmSize)\n\n\tfor i, kernelColumn := range kernelMatrix {\n\t\tfor j, kernelPixelColour := range kernelColumn {\n\n\t\t\t// get the distance of the current pixel compared to the centre of the kernel\n\t\t\t// the centre one is the one we are modifying and saving to a new image/matrix of course...\n\t\t\tdistance := math.Sqrt(math.Pow(float64(cmSize-i), 2) + math.Pow(float64(cmSize-j), 2))\n\n\t\t\t// Call the function the user passed and get the return weight of how much influence\n\t\t\t// it should have over the centre pixel we want to change\n\t\t\t// We are multipling it by the weight in the convolution matrix as that way you can\n\t\t\t// control an aspect of the weight through the matrix as well (as well as the function that\n\t\t\t// we pass in of course :)\n\t\t\tcmValue := conFunc(im, x, y, i, j, kernelPixelColour, distance) * int(cm[i][j])\n\n\t\t\t// apply the influence / weight ... (eg. if cmValue was 0, then the current pixel would have\n\t\t\t// no influence over the pixel we are changing, if it was large in comparision to what we return\n\t\t\t// for the other kernel pixels, then it will have a large influence)\n\t\t\tredTotal += int(kernelPixelColour.R) * cmValue\n\t\t\tgreenTotal += int(kernelPixelColour.G) * cmValue\n\t\t\tblueTotal += int(kernelPixelColour.B) * cmValue\n\t\t\tweight += cmValue\n\t\t}\n\t}\n\n\t// If the convolution matrix normalised itself; aka, say it was something like:\n\t// { 0 -1 0}\n\t// {-1 4 -1}\n\t// { 0 -1 0}\n\t// then adding the entries (4 + (-1) + (-1) + (-1) + (-1)) results in a zero, in which case we leave\n\t// the weights alone (by setting the weight to divide by to 1) (aka, the weights do not have an impact,\n\t// but the pixels with a weight more more or less than 0 still do have an impact on the pixel\n\t// we are changing of course)\n\tif weight == 0 {\n\t\tweight = 1\n\t}\n\n\t// Normalise the values (based on the weight (total's in the matrix))\n\tnewRedValue := redTotal / weight\n\tnewGreenValue := greenTotal / weight\n\tnewBlueValue := blueTotal / weight\n\n\t// If the values are \"out of range\" (outside the colour range of 0-255) then set them to 0 (absence of that\n\t// colour) if they were negative or 255 (100% of that colour) if they were greater than the max allowed.\n\tif newRedValue < 0 {\n\t\tnewRedValue = 0\n\t} else if newRedValue > 255 {\n\t\tnewRedValue = 255\n\t}\n\n\tif newGreenValue < 0 {\n\t\tnewGreenValue = 0\n\t} else if newGreenValue > 255 {\n\t\tnewGreenValue = 255\n\t}\n\n\tif newBlueValue < 0 {\n\t\tnewBlueValue = 0\n\t} else if newBlueValue > 255 {\n\t\tnewBlueValue = 255\n\t}\n\n\t// Assign the new values to the pixel in the column 'column' at position y\n\tcolumn[y] = color.RGBA{uint8(newRedValue), uint8(newGreenValue), uint8(newBlueValue), currentColour.A}\n\t// fmt.Printf(\"[%v,%v] %v => %v\\n\", x, y, currentColour, column[y])\n}", "func GetConvolutionFilter(target uint32, format uint32, xtype uint32, image unsafe.Pointer) {\n C.glowGetConvolutionFilter(gpGetConvolutionFilter, (C.GLenum)(target), (C.GLenum)(format), (C.GLenum)(xtype), image)\n}", "func (t1 *Tensor) Convolve2D(kernel *Tensor, stride int) (*Tensor, error) {\n\toutTensor := NewTensor((t1.Size.X-kernel.Size.X)/stride+1, (t1.Size.Y-kernel.Size.Y)/stride+1, t1.Size.Z)\n\tfor x := 0; x < outTensor.Size.X; x++ {\n\t\tfor y := 0; y < outTensor.Size.Y; y++ {\n\t\t\tmappedX, mappedY := x*stride, y*stride\n\t\t\tfor i := 0; i < kernel.Size.X; i++ {\n\t\t\t\tfor j := 0; j < kernel.Size.X; j++ {\n\t\t\t\t\tfor z := 0; z < t1.Size.Z; z++ {\n\t\t\t\t\t\tf := kernel.Get(i, j, z)\n\t\t\t\t\t\tv := t1.Get(mappedX+i, mappedY+j, z)\n\t\t\t\t\t\toutTensor.SetAdd(x, y, z, f*v)\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\treturn outTensor, nil\n}", "func ConvolutionFilter1D(target uint32, internalformat uint32, width int32, format uint32, xtype uint32, image unsafe.Pointer) {\n\tC.glowConvolutionFilter1D(gpConvolutionFilter1D, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), image)\n}", "func (fir *FIR) Convolve(input []float64) ([]float64, error) {\n\tkernelSize := len(fir.kernel)\n\tn := len(input)\n\n\tif n <= kernelSize {\n\t\terr := fmt.Errorf(\"input size %d is not greater than kernel size %d\", n, kernelSize)\n\t\treturn []float64{}, err\n\t}\n\n\toutput := make([]float64, n)\n\n\t//\n\tfor i := 0; i < kernelSize; i++ {\n\t\tsum := 0.0\n\n\t\t// convolve the input with the filter kernel\n\t\tfor j := 0; j < i; j++ {\n\t\t\tsum += (input[j] * fir.kernel[kernelSize-(1+i-j)])\n\t\t}\n\n\t\toutput[i] = sum\n\t}\n\n\tfor i := kernelSize; i < n; i++ {\n\t\tsum := 0.0\n\n\t\t// convolve the input with the filter kernel\n\t\tfor j := 0; j < kernelSize; j++ {\n\t\t\tsum += (input[i-j] * fir.kernel[j])\n\t\t}\n\n\t\toutput[i] = sum\n\t}\n\n\treturn output, nil\n}", "func Copy(i ImageIr) ImageIr {\n\tc := make([][][]uint32, len(i.pixels))\n\tcopy(c, i.pixels)\n\treturn ImageIr{i.width, i.height, c}\n}", "func createFilter(img image.Image, factor [2]float32, size int, kernel func(float32) float32) (f Filter) {\n\tsizeX := size * (int(math.Ceil(float64(factor[0]))))\n\tsizeY := size * (int(math.Ceil(float64(factor[1]))))\n\n\tswitch img.(type) {\n\tdefault:\n\t\tf = &filterModel{\n\t\t\t&genericConverter{img},\n\t\t\tfactor, kernel,\n\t\t\tmake([]colorArray, sizeX), make([]colorArray, sizeY),\n\t\t}\n\tcase *image.RGBA:\n\t\tf = &filterModel{\n\t\t\t&rgbaConverter{img.(*image.RGBA)},\n\t\t\tfactor, kernel,\n\t\t\tmake([]colorArray, sizeX), make([]colorArray, sizeY),\n\t\t}\n\tcase *image.RGBA64:\n\t\tf = &filterModel{\n\t\t\t&rgba64Converter{img.(*image.RGBA64)},\n\t\t\tfactor, kernel,\n\t\t\tmake([]colorArray, sizeX), make([]colorArray, sizeY),\n\t\t}\n\tcase *image.Gray:\n\t\tf = &filterModel{\n\t\t\t&grayConverter{img.(*image.Gray)},\n\t\t\tfactor, kernel,\n\t\t\tmake([]colorArray, sizeX), make([]colorArray, sizeY),\n\t\t}\n\tcase *image.Gray16:\n\t\tf = &filterModel{\n\t\t\t&gray16Converter{img.(*image.Gray16)},\n\t\t\tfactor, kernel,\n\t\t\tmake([]colorArray, sizeX), make([]colorArray, sizeY),\n\t\t}\n\tcase *image.YCbCr:\n\t\tf = &filterModel{\n\t\t\t&ycbcrConverter{img.(*image.YCbCr)},\n\t\t\tfactor, kernel,\n\t\t\tmake([]colorArray, sizeX), make([]colorArray, sizeY),\n\t\t}\n\t}\n\treturn\n}", "func clone(dst, src *image.Gray) {\n\tif dst.Stride == src.Stride {\n\t\t// no need to correct stride, simply copy pixels.\n\t\tcopy(dst.Pix, src.Pix)\n\t\treturn\n\t}\n\t// need to correct stride.\n\tfor i := 0; i < src.Rect.Dy(); i++ {\n\t\tdstH := i * dst.Stride\n\t\tsrcH := i * src.Stride\n\t\tcopy(dst.Pix[dstH:dstH+dst.Stride], src.Pix[srcH:srcH+dst.Stride])\n\t}\n}", "func (l *Conv2D) Forward(inputTensor tensor.Tensor) tensor.Tensor {\n\tl.inputSizeMustMatch(inputTensor)\n\n\tsave := inputTensor.(*Tensor)\n\tl.saveInput(save)\n\n\tbatchSize := l.inputBatchSize(inputTensor)\n\n\tinput := save\n\toutputSize := []int{\n\t\tl.outputSize[0],\n\t\tbatchSize,\n\t\tl.outputSize[1],\n\t\tl.outputSize[2],\n\t}\n\n\toutputHeight := outputSize[2]\n\toutputWidth := outputSize[3]\n\n\tim2ColMatrixHeight := l.numChannels() * l.kernelWidth() * l.kernelHeight()\n\tim2ColMatrixWidth := outputWidth * outputHeight * batchSize\n\tim2ColMatrix := l.TensorOperator.CreateTensor(\n\t\t[]int{im2ColMatrixHeight, im2ColMatrixWidth})\n\tdefer l.TensorOperator.Free(im2ColMatrix)\n\n\tl.im2Col(input, im2ColMatrix,\n\t\t[2]int{l.kernelWidth(), l.kernelHeight()},\n\t\t[4]int{l.padding[0], l.padding[1], l.padding[2], l.padding[3]},\n\t\t[2]int{l.stride[0], l.stride[1]},\n\t\t[2]int{0, 0},\n\t)\n\n\tkernelMatrixWidth := l.kernelWidth() * l.kernelHeight() * l.numChannels()\n\tkernelMatrixHeight := l.numKernels()\n\tkernelMatrix := l.kernel.Reshape(\n\t\t[]int{kernelMatrixHeight, kernelMatrixWidth})\n\n\thKernelData := make([]float32, kernelMatrixWidth*kernelMatrixHeight)\n\tl.GPUDriver.MemCopyD2H(l.GPUCtx, hKernelData, kernelMatrix.ptr)\n\n\toutputMatrix := l.TensorOperator.CreateTensor(\n\t\t[]int{kernelMatrixHeight, im2ColMatrixWidth})\n\tbiasTensor := l.TensorOperator.CreateTensor(\n\t\t[]int{batchSize, l.outputSize[0], l.outputSize[1], l.outputSize[2]})\n\tbiasTensorTrans := l.TensorOperator.CreateTensor(\n\t\t[]int{l.outputSize[0], batchSize, l.outputSize[1], l.outputSize[2]})\n\tl.TensorOperator.Repeat(l.bias, biasTensor, batchSize)\n\tl.TensorOperator.TransposeTensor(biasTensor, biasTensorTrans,\n\t\t[]int{1, 0, 2, 3})\n\tbiasMatrix := biasTensorTrans.Reshape(\n\t\t[]int{l.numKernels(), im2ColMatrixWidth})\n\n\tl.TensorOperator.Gemm(\n\t\tfalse, false,\n\t\tkernelMatrixHeight,\n\t\tim2ColMatrixWidth,\n\t\tkernelMatrixWidth,\n\t\t1.0, 1.0,\n\t\tkernelMatrix, im2ColMatrix, biasMatrix, outputMatrix)\n\n\toutput := &Tensor{\n\t\tdriver: l.GPUDriver,\n\t\tctx: l.GPUCtx,\n\t\tsize: outputSize,\n\t\tptr: outputMatrix.ptr,\n\t\tdescriptor: \"CNHW\",\n\t}\n\n\ttransposedOutput := l.TensorOperator.CreateTensor([]int{\n\t\tbatchSize,\n\t\tl.outputSize[0],\n\t\tl.outputSize[1],\n\t\tl.outputSize[2]})\n\tl.TensorOperator.TransposeTensor(\n\t\toutput, transposedOutput, []int{1, 0, 2, 3})\n\n\tl.TensorOperator.Free(biasTensor)\n\tl.TensorOperator.Free(biasTensorTrans)\n\tl.TensorOperator.Free(output)\n\n\treturn transposedOutput\n}", "func BoxFilter(src, dst []float64, width int, border Border) {\n\t// TODO optimize\n\talpha := 1.0 / float64(width)\n\tkernel := make([]float64, width)\n\tfor i := range kernel {\n\t\tkernel[i] = alpha\n\t}\n\tConvolve(src, dst, kernel, border)\n}", "func (img *FloatImage) convolveWith(kernel *ConvKernel, px planeExtension) {\n\n\t// convolve each plane independently:\n\tfor i := 0; i < 3; i++ {\n\t\timg.Ip[i] = *convolvePlane(&img.Ip[i], kernel, img.Width, img.Height, px)\n\t}\n}", "func ConvDiff(geom *Geom, fltOn, fltOff *etensor.Float32, imgOn, imgOff, out *etensor.Float32, gain, gainOn float32) {\n\tfy := fltOn.Dim(0)\n\tfx := fltOn.Dim(1)\n\n\tgeom.FiltSz = image.Point{fx, fy}\n\tgeom.UpdtFilt()\n\n\timgSz := image.Point{imgOn.Dim(1), imgOn.Dim(0)}\n\tgeom.SetSize(imgSz)\n\toshp := []int{2, int(geom.Out.Y), int(geom.Out.X)}\n\tif !etensor.EqualInts(oshp, out.Shp) {\n\t\tout.SetShape(oshp, nil, []string{\"OnOff\", \"Y\", \"X\"})\n\t}\n\tncpu := nproc.NumCPU()\n\tnthrs, nper, rmdr := nproc.ThreadNs(ncpu, geom.Out.Y)\n\tvar wg sync.WaitGroup\n\tfor th := 0; th < nthrs; th++ {\n\t\twg.Add(1)\n\t\tyst := th * nper\n\t\tgo convDiffThr(&wg, geom, yst, nper, fltOn, fltOff, imgOn, imgOff, out, gain, gainOn)\n\t}\n\tif rmdr > 0 {\n\t\twg.Add(1)\n\t\tyst := nthrs * nper\n\t\tgo convDiffThr(&wg, geom, yst, rmdr, fltOn, fltOff, imgOn, imgOff, out, gain, gainOn)\n\t}\n\twg.Wait()\n}", "func convolvePlane(planePtr *[]float32, kernel *ConvKernel, width, height int, toPlaneCoords planeExtension) *[]float32 {\n\n\tplane := *planePtr\n\tradius := kernel.Radius\n\tdiameter := radius*2 + 1\n\tres := make([]float32, width*height)\n\n\t// for each pixel of the intensity plane:\n\tfor y := 0; y < height; y++ {\n\t\tfor x := 0; x < width; x++ {\n\t\t\tindex := y*width + x\n\n\t\t\t// compute convolved value of the pixel:\n\t\t\tresV := float32(0)\n\t\t\tfor yk := 0; yk < diameter; yk++ {\n\t\t\t\typ := toPlaneCoords(y+yk-radius, height)\n\t\t\t\tfor xk := 0; xk < diameter; xk++ {\n\t\t\t\t\txp := toPlaneCoords(x+xk-radius, width)\n\t\t\t\t\tplaneIndex := yp*width + xp\n\t\t\t\t\tkernelIndex := yk*diameter + xk\n\t\t\t\t\tresV += (plane[planeIndex] * kernel.Kernel[kernelIndex])\n\t\t\t\t}\n\t\t\t}\n\t\t\tres[index] = resV\n\t\t}\n\t}\n\n\treturn &res\n}", "func (img *ImageTask) ApplyConvulusion(neighbors *Neighbors, kernel [9]float64) *Colors{\n\n\tvar blue float64\n\tvar green float64\n\tvar red float64\n\tfor r := 0; r < 9; r++ {\n\t\tred = red + (neighbors.inputs[r].Red * kernel[r])\n\t\tgreen = green + (neighbors.inputs[r].Green * kernel[r])\n\t\tblue = blue + (neighbors.inputs[r].Blue * kernel[r])\n\t}\n\n\treturned := Colors{Red: red, Green: green, Blue: blue, Alpha: neighbors.inputs[4].Alpha}\n\treturn &returned\n}", "func GetConvolutionFilter(target uint32, format uint32, xtype uint32, image unsafe.Pointer) {\n\tC.glowGetConvolutionFilter(gpGetConvolutionFilter, (C.GLenum)(target), (C.GLenum)(format), (C.GLenum)(xtype), image)\n}", "func (r *Ri) PixelFilter(filterfunc RtFilterFunc, xwidth, ywidth RtFloat) error {\n\treturn r.writef(\"PixelFilter\", filterfunc, xwidth, ywidth)\n}", "func SeparableFilter2D(target uint32, internalformat uint32, width int32, height int32, format uint32, xtype uint32, row unsafe.Pointer, column unsafe.Pointer) {\n C.glowSeparableFilter2D(gpSeparableFilter2D, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), row, column)\n}", "func convDiffThr(wg *sync.WaitGroup, geom *Geom, yst, ny int, fltOn, fltOff *etensor.Float32, imgOn, imgOff, out *etensor.Float32, gain, gainOn float32) {\n\tist := geom.Border.Sub(geom.FiltLt)\n\tfor yi := 0; yi < ny; yi++ {\n\t\ty := yst + yi\n\t\tiy := int(ist.Y + y*geom.Spacing.Y)\n\t\tfor x := 0; x < geom.Out.X; x++ {\n\t\t\tix := ist.X + x*geom.Spacing.X\n\t\t\tvar sumOn, sumOff float32\n\t\t\tfi := 0\n\t\t\tfor fy := 0; fy < geom.FiltSz.Y; fy++ {\n\t\t\t\tfor fx := 0; fx < geom.FiltSz.X; fx++ {\n\t\t\t\t\tidx := imgOn.Offset([]int{iy + fy, ix + fx})\n\t\t\t\t\tsumOn += imgOn.Values[idx] * fltOn.Values[fi]\n\t\t\t\t\tsumOff += imgOff.Values[idx] * fltOff.Values[fi]\n\t\t\t\t\tfi++\n\t\t\t\t}\n\t\t\t}\n\t\t\tdiff := gain * (gainOn*sumOn - sumOff)\n\t\t\tif diff > 0 {\n\t\t\t\tout.Set([]int{0, y, x}, diff)\n\t\t\t\tout.Set([]int{1, y, x}, float32(0))\n\t\t\t} else {\n\t\t\t\tout.Set([]int{0, y, x}, float32(0))\n\t\t\t\tout.Set([]int{1, y, x}, -diff)\n\t\t\t}\n\t\t}\n\t}\n\twg.Done()\n}", "func ConcurrentEdgeFilter(imgSrc image.Image) image.Image {\n\tngo:=runtime.NumCPU()\n\tout := make(chan portion)\n\tslices := imagetools.CropChevauchement(imgSrc, ngo, 10) //on laisse 5 pixels de chevauchement\n\n\tfor i := 0; i < ngo; i++ {\n\t\tgo edgWorker(i, out, slices[i][0])\n\t}\n\n\tfor i := 0; i < ngo; i++ {\n\t\tslice := <-out\n\t\tslices[slice.id][0] = slice.img\n\t}\n\n\timgEnd := imagetools.RebuildChevauchement(slices, 10)\n\n\treturn imgEnd\n\n}", "func Conv2D(t Tensor, k Tensor, hAxis int, wAxis int, fAxis int) Tensor {\n\tkh, kw := k.Shape()[0], k.Shape()[1]\n\treturn &Conv2DTensor{\n\t\tbaseTensor: base(conv2d(t, k, hAxis, wAxis, fAxis), 1, t, k),\n\t\tt: t,\n\t\tk: k,\n\t\thAxis: hAxis,\n\t\twAxis: wAxis,\n\t\tfAxis: fAxis,\n\t\tpadH: kh - 1,\n\t\tpadW: kw - 1,\n\t}\n}", "func MakePixelMixingFilter() *Filter {\n\tf := new(Filter)\n\tf.F = func(x float64, scaleFactor float64) float64 {\n\t\tvar p float64\n\t\tif scaleFactor < 1.0 {\n\t\t\tp = scaleFactor\n\t\t} else {\n\t\t\tp = 1.0 / scaleFactor\n\t\t}\n\t\tif x < 0.5-p/2.0 {\n\t\t\treturn 1.0\n\t\t} else if x < 0.5+p/2.0 {\n\t\t\treturn 0.5 - (x-0.5)/p\n\t\t}\n\t\treturn 0.0\n\t}\n\tf.Radius = func(scaleFactor float64) float64 {\n\t\tif scaleFactor < 1.0 {\n\t\t\treturn 0.5 + scaleFactor\n\t\t}\n\t\treturn 0.5 + 1.0/scaleFactor\n\t}\n\treturn f\n}", "func Copy(dst draw.Image, src image.Image) {\n\tbd := src.Bounds().Intersect(dst.Bounds())\n\tat := imageutil.NewAtFunc(src)\n\tset := imageutil.NewSetFunc(dst)\n\timageutil.Parallel1D(bd, func(bd image.Rectangle) {\n\t\tfor y := bd.Min.Y; y < bd.Max.Y; y++ {\n\t\t\tfor x := bd.Min.X; x < bd.Max.X; x++ {\n\t\t\t\tr, g, b, a := at(x, y)\n\t\t\t\tset(x, y, r, g, b, a)\n\t\t\t}\n\t\t}\n\t})\n}", "func sm2P256CopyConditional(out, in *sm2P256FieldElement, mask uint32) {\n\tfor i := 0; i < 9; i++ {\n\t\ttmp := mask & (in[i] ^ out[i])\n\t\tout[i] ^= tmp\n\t}\n}", "func Contrast(percentage float32) Filter {\n\tif percentage == 0 {\n\t\treturn &copyimageFilter{}\n\t}\n\n\tp := 1 + minf32(maxf32(percentage, -100), 100)/100\n\n\treturn &colorchanFilter{\n\t\tfn: func(x float32) float32 {\n\t\t\tif 0 <= p && p <= 1 {\n\t\t\t\treturn 0.5 + (x-0.5)*p\n\t\t\t} else if 1 < p && p < 2 {\n\t\t\t\treturn 0.5 + (x-0.5)*(1/(2.0-p))\n\t\t\t} else {\n\t\t\t\tif x < 0.5 {\n\t\t\t\t\treturn 0\n\t\t\t\t}\n\t\t\t\treturn 1\n\t\t\t}\n\t\t},\n\t\tlut: false,\n\t}\n}", "func GaussianFilter(src, dst []float64, width int, sigma float64, border Border) {\n\tif width <= 0 {\n\t\twidth = 1 + 2*int(math.Floor(sigma*4+0.5))\n\t}\n\tkernel := make([]float64, width)\n\tGaussianKernel(kernel, sigma)\n\tConvolve(src, dst, kernel, border)\n}", "func SeparableFilter2D(target uint32, internalformat uint32, width int32, height int32, format uint32, xtype uint32, row unsafe.Pointer, column unsafe.Pointer) {\n\tC.glowSeparableFilter2D(gpSeparableFilter2D, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), row, column)\n}", "func CopyPixels(x int32, y int32, width int32, height int32, xtype uint32) {\n C.glowCopyPixels(gpCopyPixels, (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(xtype))\n}", "func worker(threads int, doneWorker chan<- bool, imageTasks <-chan *imagetask.ImageTask, imageResults chan<- *imagetask.ImageTask) {\n\n\t// Initial placing image chunks in to a channel for filter to consume.\n\tchunkStreamGenerator := func(done <- chan interface{}, imageChunks []*imagetask.ImageTask) chan *imagetask.ImageTask {\n\t\tchunkStream := make(chan *imagetask.ImageTask)\n\t\tgo func() {\n\t\t\tdefer close(chunkStream)\n\t\t\tfor _, chunk := range imageChunks {\n\t\t\t\tselect {\n\t\t\t\tcase <-done:\n\t\t\t\t\treturn\n\t\t\t\tcase chunkStream <- chunk:\n\t\t\t\t}\n\t\t\t}\n\t\t}()\n\t\treturn chunkStream\n\t}\n\n\t// Filter applies a filter in a pipeline fashion. \n\t// A goroutine is spawned for each chunk that needs to be filtered (which is numOfThreads chunks for each filter effect)\n\tfilter := func(threads int, effect string, effectNum int, done <- chan interface{}, chunkStream chan *imagetask.ImageTask) chan *imagetask.ImageTask {\n\t\tfilterStream := make(chan *imagetask.ImageTask, threads) // Only numOfThreads image chunks should be in the local filter channel.\n\t\tdonefilterChunk := make(chan bool)\n\t\tfor chunk := range chunkStream { // For each image chunk ...\n\t\t\tif effectNum > 0 {\n\t\t\t\tchunk.Img.UpdateInImg() // Replace inImg with outImg if not the first effect to compund effects.\n\t\t\t}\t\n\t\t\tgo func(chunk *imagetask.ImageTask) { // Spawn a goroutine for each chunk, which is equal to the numOfThreads. Each goroutine works on a portion of the image.\n\t\t\t\tselect {\n\t\t\t\tcase <-done:\n\t\t\t\t\tdonefilterChunk <- true\n\t\t\t\t\treturn\n\t\t\t\tcase filterStream <- chunk:\n\t\t\t\t\tif effect != \"G\" {\n\t\t\t\t\t\tchunk.Img.ApplyConvolution(effect) // Can wait to apply effect until after chunk is in the channel because has to wait for all goroutines to finish before it can move on to the next filter for a given image.\n\t\t\t\t\t} else {\n\t\t\t\t\t\tchunk.Img.Grayscale()\n\t\t\t\t\t}\n\t\t\t\t\tdonefilterChunk <- true // Indicate that the filtering is done for the given chunk.\n\t\t\t\t}\n\t\t\t}(chunk)\n\t\t}\n\t\tfor i := 0; i < threads; i ++ { // Wait for all portions to be put through one filter because of image dependencies with convolution.\n\t\t\t<-donefilterChunk\n\t\t}\n\t\treturn filterStream\n\t}\n\n\t// While there are more image tasks to grab ...\n\tfor true {\n\t\t// Grab image task from image task channel.\t\n\t\timgTask, more := <-imageTasks\n\n\t\t// If you get an image task, split up the image in to even chunks by y-pixels.\n\t\tif more {\n\t\t\timageChunks := imgTask.SplitImage(threads)\n\t\t\t\n\t\t\t// Iterate through filters on image chunks.\n\t\t\t// Will spawn a goroutine for each chunk in each filter (n goroutines per filter)\n\t\t\tdone := make(chan interface{})\n\t\t\tdefer close(done)\n\t\t\tchunkStream := chunkStreamGenerator(done, imageChunks)\n\t\t\tfor i := 0; i < len(imgTask.Effects); i++ {\n\t\t\t\teffect := imgTask.Effects[i]\n\t\t\t\tchunkStream = filter(threads, effect, i, done, chunkStream)\n\t\t\t\tclose(chunkStream)\n\t\t\t}\n\n\t\t\t// Put the image back together.\n\t\t\treconstructedImage, _ := imgTask.Img.NewImage()\n\t\t\tfor imgChunk := range chunkStream {\n\t\t\t\treconstructedImage.ReAddChunk(imgChunk.Img, imgChunk.YPixelStart, imgChunk.ChunkPart)\n\t\t\t}\n\t\t\timgTask.Img = reconstructedImage\n\t\t\timageResults <- imgTask // Send image to results channel to be saved.\n\n\t\t} else { // Otherwise, if there are no more image tasks, then goroutine worker exits.\n\t\t\tdoneWorker <- true // Indicate that the worker is done.\n\t\t\treturn\n\t\t}\n\t}\n}", "func CopyPixels(x int32, y int32, width int32, height int32, xtype uint32) {\n\tC.glowCopyPixels(gpCopyPixels, (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(xtype))\n}", "func MakeConvolutionCoder(r, k int, poly []uint16) *ConvolutionCoder {\n\tif len(poly) != r {\n\t\tpanic(\"The number of polys should match the rate\")\n\t}\n\n\treturn &ConvolutionCoder{\n\t\tr: r,\n\t\tk: k,\n\t\tpoly: poly,\n\t\tcc: correctwrap.Correct_convolutional_create(int64(r), int64(k), &poly[0]),\n\t}\n}", "func (img *FloatImage) ConvolveWrap(kernel *ConvKernel) *FloatImage {\n\treturn img.convolve(kernel, wrapPlaneExtension)\n}", "func SpectralConvolution(spectrum []int) []int {\n\tvar convolution []int\n\tfor i := 0; i < len(spectrum)-1; i++ {\n\t\tfor j := i + 1; j < len(spectrum); j++ {\n\t\t\tval := spectrum[j] - spectrum[i]\n\t\t\tif val > 0 {\n\t\t\t\tconvolution = append(convolution, val)\n\t\t\t}\n\t\t}\n\t}\n\treturn convolution\n}", "func blendPixelOverPixel(ic_old,ic_new uint8, al_new float64)(c_res uint8) {\n\n\tal_old := float64(1); _=al_old\n\tc_old := float64(ic_old)\n\tc_new := float64(ic_new)\n\n\talgo1 := c_old*(1-al_new) + c_new*al_new\n\tc_res = uint8( util.Min( util.Round(algo1),255) )\n\t//log.Printf(\"\\t\\t %3.1f + %3.1f = %3.1f\", c_old*(1-al_new),c_new*al_new, algo1)\n\n\treturn \n}", "func CopyPixels(x int32, y int32, width int32, height int32, xtype uint32) {\n\tsyscall.Syscall6(gpCopyPixels, 5, uintptr(x), uintptr(y), uintptr(width), uintptr(height), uintptr(xtype), 0)\n}", "func (c *Canvas) pixelate(data []uint8, rect image.Rectangle, noiseLevel int) []uint8 {\n\t// Converts the array buffer to an image\n\timg := pixels.PixToImage(data, rect)\n\n\t// Quantize the substracted image in order to reduce the number of colors.\n\t// This will create a new pixelated subtype image.\n\tcell := quant.Draw(img, c.numOfColors, c.cellSize, noiseLevel)\n\n\tdst := image.NewNRGBA(cell.Bounds())\n\tdraw.Draw(dst, cell.Bounds(), cell, image.Point{}, draw.Over)\n\n\treturn pixels.ImgToPix(dst)\n}", "func convolutionMatrixSampleFunction(im ImageMatrix, imagePositionX int, imagePositionY int, kernelPixelX int, kernelPixel int, colour color.RGBA, distance float64) int {\n\tif distance < 1 {\n\t\treturn 1\n\t}\n\n\tif colour.R > 150 && colour.G < 100 && colour.B < 100 {\n\t\treturn int(5 * distance)\n\t}\n\n\treturn 5\n}", "func PMOVZXBW(mx, x operand.Op) { ctx.PMOVZXBW(mx, x) }", "func filter(src <-chan int, dst chan<- int, prime int) {\n\tfor i := range src { // Loop over values received from 'src'.\n\t\tif i%prime != 0 {\n\t\t\tdst <- i // Send 'i' to channel 'dst'.\n\t\t}\n\t}\n}", "func (fr *Frame) Copy(orig *Frame) {\n\tfr.Status = orig.Status\n\tfor y, row := range orig.Pix {\n\t\tcopy(fr.Pix[y][:], row)\n\t}\n}", "func VPMOVZXBW(ops ...operand.Op) { ctx.VPMOVZXBW(ops...) }", "func StepConvolution() *Step {\n\t// TODO\n\treturn nil\n}", "func ExampleConv2() {\n\n\tconv := cnns.NewConvLayer(&tensor.TDsize{X: 5, Y: 5, Z: 3}, 1, 3, 2)\n\trelu := cnns.NewReLULayer(conv.GetOutputSize())\n\tmaxpool := cnns.NewPoolingLayer(relu.GetOutputSize(), 2, 2, \"max\", \"valid\")\n\tfullyconnected := cnns.NewFullyConnectedLayer(maxpool.GetOutputSize(), 2)\n\n\tnet := cnns.WholeNet{\n\t\tLP: cnns.NewLearningParametersDefault(),\n\t}\n\tnet.Layers = append(net.Layers, conv)\n\tnet.Layers = append(net.Layers, relu)\n\tnet.Layers = append(net.Layers, maxpool)\n\tnet.Layers = append(net.Layers, fullyconnected)\n\n\tredChannel := mat.NewDense(5, 5, []float64{\n\t\t1, 0, 1, 0, 2,\n\t\t1, 1, 3, 2, 1,\n\t\t1, 1, 0, 1, 1,\n\t\t2, 3, 2, 1, 3,\n\t\t0, 2, 0, 1, 0,\n\t})\n\tgreenChannel := mat.NewDense(5, 5, []float64{\n\t\t1, 0, 0, 1, 0,\n\t\t2, 0, 1, 2, 0,\n\t\t3, 1, 1, 3, 0,\n\t\t0, 3, 0, 3, 2,\n\t\t1, 0, 3, 2, 1,\n\t})\n\tblueChannel := mat.NewDense(5, 5, []float64{\n\t\t2, 0, 1, 2, 1,\n\t\t3, 3, 1, 3, 2,\n\t\t2, 1, 1, 1, 0,\n\t\t3, 1, 3, 2, 0,\n\t\t1, 1, 2, 1, 1,\n\t})\n\n\tkernel1R := mat.NewDense(3, 3, []float64{\n\t\t0, 1, 0,\n\t\t0, 0, 2,\n\t\t0, 1, 0,\n\t})\n\tkernel1G := mat.NewDense(3, 3, []float64{\n\t\t2, 1, 0,\n\t\t0, 0, 0,\n\t\t0, 3, 0,\n\t})\n\tkernel1B := mat.NewDense(3, 3, []float64{\n\t\t1, 0, 0,\n\t\t1, 0, 0,\n\t\t0, 0, 2,\n\t})\n\n\tkernel2R := mat.NewDense(3, 3, []float64{\n\t\t0, -1, 0,\n\t\t0, 0, 2,\n\t\t0, 1, 0,\n\t})\n\tkernel2G := mat.NewDense(3, 3, []float64{\n\t\t2, 1, 0,\n\t\t0, 0, 0,\n\t\t0, -3, 0,\n\t})\n\tkernel2B := mat.NewDense(3, 3, []float64{\n\t\t1, 0, 0,\n\t\t1, 0, 0,\n\t\t0, 0, -2,\n\t})\n\n\timg2 := &mat.Dense{}\n\timg2.Stack(redChannel, greenChannel)\n\timage := &mat.Dense{}\n\timage.Stack(img2, blueChannel)\n\n\tkernel1 := &mat.Dense{}\n\tkernel1.Stack(kernel1R, kernel1G)\n\tconvCustomWeights1 := &mat.Dense{}\n\tconvCustomWeights1.Stack(kernel1, kernel1B)\n\n\tkernel2 := &mat.Dense{}\n\tkernel2.Stack(kernel2R, kernel2G)\n\tconvCustomWeights2 := &mat.Dense{}\n\tconvCustomWeights2.Stack(kernel2, kernel2B)\n\tconv.SetCustomWeights([]*mat.Dense{convCustomWeights1, convCustomWeights2})\n\n\tfcCustomWeights := mat.NewDense(2, maxpool.GetOutputSize().Total(), []float64{\n\t\t-0.19908814, 0.01521263,\n\t\t0.17908468, -0.28144695,\n\t})\n\tfullyconnected.SetCustomWeights([]*mat.Dense{fcCustomWeights})\n\n\tfmt.Printf(\"Layers weights:\\n\")\n\tfor i := range net.Layers {\n\t\tfmt.Printf(\"%s #%d weights:\\n\", net.Layers[i].GetType(), i)\n\t\tnet.Layers[i].PrintWeights()\n\t}\n\n\tfmt.Println(\"\\tDoing training....\")\n\tfor e := 0; e < 1; e++ {\n\t\terr := net.FeedForward(image)\n\t\tif err != nil {\n\t\t\tlog.Printf(\"Feedforward caused error: %s\", err.Error())\n\t\t\treturn\n\t\t}\n\n\t\tdesired := mat.NewDense(2, 1, []float64{0.15, 0.8})\n\t\terr = net.Backpropagate(desired)\n\t\tif err != nil {\n\t\t\tlog.Printf(\"Backpropagate caused error: %s\", err.Error())\n\t\t\treturn\n\t\t}\n\n\t\tfmt.Printf(\"Epoch #%d. New layers weights\\n\", e)\n\t\tfor i := range net.Layers {\n\t\t\tfmt.Printf(\"%s #%d weights on epoch #%d:\\n\", net.Layers[i].GetType(), i, e)\n\t\t\tnet.Layers[i].PrintWeights()\n\t\t}\n\t}\n}", "func (i *ImageBuf) CopyPixels(src *ImageBuf) error {\n\tok := bool(C.ImageBuf_copy_pixels(i.ptr, src.ptr))\n\truntime.KeepAlive(i)\n\truntime.KeepAlive(src)\n\tif !ok {\n\t\treturn i.LastError()\n\t}\n\treturn nil\n}", "func Conv(scope *Scope, input tf.Output, filter tf.Output, strides []int64, padding string, optional ...ConvAttr) (output tf.Output) {\n\tif scope.Err() != nil {\n\t\treturn\n\t}\n\tattrs := map[string]interface{}{\"strides\": strides, \"padding\": padding}\n\tfor _, a := range optional {\n\t\ta(attrs)\n\t}\n\topspec := tf.OpSpec{\n\t\tType: \"Conv\",\n\t\tInput: []tf.Input{\n\t\t\tinput, filter,\n\t\t},\n\t\tAttrs: attrs,\n\t}\n\top := scope.AddOperation(opspec)\n\treturn op.Output(0)\n}", "func Conv2DBackpropFilter(scope *Scope, input tf.Output, filter_sizes tf.Output, out_backprop tf.Output, strides []int64, padding string, optional ...Conv2DBackpropFilterAttr) (output tf.Output) {\n\tif scope.Err() != nil {\n\t\treturn\n\t}\n\tattrs := map[string]interface{}{\"strides\": strides, \"padding\": padding}\n\tfor _, a := range optional {\n\t\ta(attrs)\n\t}\n\topspec := tf.OpSpec{\n\t\tType: \"Conv2DBackpropFilter\",\n\t\tInput: []tf.Input{\n\t\t\tinput, filter_sizes, out_backprop,\n\t\t},\n\t\tAttrs: attrs,\n\t}\n\top := scope.AddOperation(opspec)\n\treturn op.Output(0)\n}", "func (p *Image64) Convolved(k Kernel64) *Image64 {\n\tswitch k.(type) {\n\tcase *separableKernel64:\n\t\treturn p.separableConvolution(k.(*separableKernel64))\n\tdefault:\n\t\treturn p.fullConvolution(k)\n\t}\n\tpanic(\"unreachable\")\n}", "func Dilation2DBackpropFilter(scope *Scope, input tf.Output, filter tf.Output, out_backprop tf.Output, strides []int64, rates []int64, padding string) (filter_backprop tf.Output) {\n\tif scope.Err() != nil {\n\t\treturn\n\t}\n\tattrs := map[string]interface{}{\"strides\": strides, \"rates\": rates, \"padding\": padding}\n\topspec := tf.OpSpec{\n\t\tType: \"Dilation2DBackpropFilter\",\n\t\tInput: []tf.Input{\n\t\t\tinput, filter, out_backprop,\n\t\t},\n\t\tAttrs: attrs,\n\t}\n\top := scope.AddOperation(opspec)\n\treturn op.Output(0)\n}", "func extractSwatches(src *image.RGBA, numColors int) []colorful.Color {\n\tconst (\n\t\tW = 400\n\t\tH = 75\n\t)\n\tvar swatches []colorful.Color\n\tb := src.Bounds()\n\tsw := W / numColors\n\tfor i := 0; i < numColors; i++ {\n\t\tm := src.SubImage(trimRect(image.Rect(b.Min.X+i*sw, b.Max.Y-H, b.Min.X+(i+1)*sw, b.Max.Y), 10))\n\t\tswatches = append(swatches, toColorful(averageColor(m)))\n\t\tsavePNG(strconv.Itoa(i), m) // for debugging\n\t}\n\tconst dim = 50\n\tm := image.NewRGBA(image.Rect(0, 0, dim*len(swatches), dim))\n\tfor i, c := range swatches {\n\t\tr := image.Rect(i*dim, 0, (i+1)*dim, dim)\n\t\tdraw.Draw(m, r, &image.Uniform{fromColorful(c)}, image.ZP, draw.Src)\n\t}\n\tsavePNG(\"swatches\", m) // for debugging\n\treturn swatches\n}", "func (b *Bilateral) Apply(t *Tensor) *Tensor {\n\tdistances := NewTensor(b.KernelSize, b.KernelSize, 1)\n\tcenter := b.KernelSize / 2\n\tfor i := 0; i < b.KernelSize; i++ {\n\t\tfor j := 0; j < b.KernelSize; j++ {\n\t\t\t*distances.At(i, j, 0) = float32((i-center)*(i-center) + (j-center)*(j-center))\n\t\t}\n\t}\n\n\t// Pad with very large negative numbers to prevent\n\t// the filter from incorporating the padding.\n\tpadded := t.Add(100).Pad(center, center, center, center).Add(-100)\n\tout := NewTensor(t.Height, t.Width, t.Depth)\n\tPatches(padded, b.KernelSize, 1, func(idx int, patch *Tensor) {\n\t\tb.blurPatch(distances, patch, out.Data[idx*out.Depth:(idx+1)*out.Depth])\n\t})\n\n\treturn out\n}", "func CopyFiltered(slice interface{}, funcs ...FilterFunc) interface{} {\n\trv := reflect.ValueOf(slice)\n\tif rv.Kind() != reflect.Slice {\n\t\tpanic(\"not a slice\")\n\t}\n\n\tlength := rv.Len()\n\n\tptrfiltered := reflect.New(rv.Type())\n\tptrfiltered.Elem().Set(\n\t\t//reflect.MakeSlice(rv.Type(), 0, length))\n\t\treflect.MakeSlice(rv.Type(), length, length)) // copy is done by dest[j] = src[i], so it's allocated in advance\n\tfiltered := ptrfiltered.Elem()\n\n\treflect.Copy(filtered, rv)\n\n\tFilter(ptrfiltered.Interface(), funcs...)\n\n\treturn filtered.Interface()\n}", "func p256CopyConditional(out, in *[p256Limbs]uint32, mask uint32) {\n\tfor i := 0; i < p256Limbs; i++ {\n\t\ttmp := mask & (in[i] ^ out[i])\n\t\tout[i] ^= tmp\n\t}\n}", "func Saturation(percentage float32) Filter {\n\tp := 1 + minf32(maxf32(percentage, -100), 500)/100\n\tif p == 1 {\n\t\treturn &copyimageFilter{}\n\t}\n\n\treturn &colorFilter{\n\t\tfn: func(px pixel) pixel {\n\t\t\th, s, l := convertRGBToHSL(px.R, px.G, px.B)\n\t\t\ts *= p\n\t\t\tif s > 1 {\n\t\t\t\ts = 1\n\t\t\t}\n\t\t\tr, g, b := convertHSLToRGB(h, s, l)\n\t\t\treturn pixel{r, g, b, px.A}\n\t\t},\n\t}\n}", "func (dithering Dithering) Convert(input image.Image) image.Image {\n\tgrayInput := Gray{\n\t\tAlgorithm: GrayAlgorithms.Luminosity,\n\t}.Convert(input)\n\tbounds := grayInput.Bounds()\n\tw, h := bounds.Max.X, bounds.Max.Y\n\n\tmatrix := make([][]float32, w)\n\tfor x := 0; x < w; x++ {\n\t\tmatrix[x] = make([]float32, h)\n\t\tfor y := 0; y < h; y++ {\n\t\t\tr, _, _, _ := grayInput.At(x, y).RGBA()\n\t\t\tmatrix[x][y] = float32(r >> 8)\n\t\t}\n\t}\n\tthreshold := calculateThreshold(grayInput)\n\n\tfor y := 0; y < h-1; y++ {\n\t\tfor x := 1; x < w-1; x++ {\n\t\t\toldpixel := matrix[x][y]\n\t\t\tnewpixel := toBlackOrWhite(oldpixel, threshold)\n\t\t\tmatrix[x][y] = newpixel\n\t\t\tquantError := oldpixel - newpixel\n\t\t\tmatrix[x+1][y] = matrix[x+1][y] + quantError*7/16\n\t\t\tmatrix[x-1][y+1] = matrix[x-1][y+1] + quantError*3/16\n\t\t\tmatrix[x][y+1] = matrix[x][y+1] + quantError*5/16\n\t\t\tmatrix[x+1][y+1] = matrix[x+1][y+1] + quantError*1/16\n\t\t}\n\t}\n\n\tfor x := 0; x < w; x++ {\n\t\tfor y := 0; y < h; y++ {\n\t\t\tcol := color.Gray{Y: uint8(matrix[x][y])}\n\t\t\tgrayInput.Set(x, y, col)\n\t\t}\n\t}\n\n\treturn grayInput\n}", "func VPMOVSXBW(ops ...operand.Op) { ctx.VPMOVSXBW(ops...) }", "func MulConstSSE32(c float32, x []float32, y []float32)", "func newImageBinaryChannels(imgSrc image.Image, colorChannelTypes ...channelType) []*imageBinaryChannel {\n\tchannels := make([]*imageBinaryChannel, 3)\n\tmax := imgSrc.Bounds().Max\n\tw, h := max.X, max.Y\n\tfor i, channelType := range colorChannelTypes {\n\t\tcolorChannel := image.NewGray(image.Rectangle{Max: image.Point{w, h}})\n\t\tfor x := 0; x < w; x++ {\n\t\t\tfor y := 0; y < h; y++ {\n\t\t\t\tcolorPixel := imgSrc.At(x, y).(color.NRGBA)\n\t\t\t\tvar c uint8\n\t\t\t\tswitch channelType {\n\t\t\t\tcase red:\n\t\t\t\t\tc = colorPixel.R\n\t\t\t\tcase green:\n\t\t\t\t\tc = colorPixel.G\n\t\t\t\tcase blue:\n\t\t\t\t\tc = colorPixel.B\n\t\t\t\t}\n\t\t\t\tgrayPixel := color.Gray{Y: c}\n\t\t\t\tcolorChannel.Set(x, y, grayPixel)\n\t\t\t}\n\t\t}\n\t\tchannels[i] = newImageBinaryChannel(colorChannel, channelType)\n\t}\n\treturn channels\n}", "func ycbcrToGray(dst *image.Gray, src *image.YCbCr) {\n\tfor i := 0; i < src.Rect.Dy(); i++ {\n\t\tdstH := i * dst.Stride\n\t\tsrcH := i * src.YStride\n\t\tcopy(dst.Pix[dstH:dstH+dst.Stride], src.Y[srcH:srcH+dst.Stride])\n\t}\n}", "func Brightness(percentage float32) Filter {\n\tif percentage == 0 {\n\t\treturn &copyimageFilter{}\n\t}\n\n\tshift := minf32(maxf32(percentage, -100), 100) / 100\n\n\treturn &colorchanFilter{\n\t\tfn: func(x float32) float32 {\n\t\t\treturn x + shift\n\t\t},\n\t\tlut: false,\n\t}\n}", "func MulConstSSE64(c float64, x []float64, y []float64)", "func Filter(dst, src []float64, f func(v float64) bool) []float64 {\n\n\tif dst == nil {\n\t\tdst = make([]float64, 0, len(src))\n\t}\n\n\tdst = dst[:0]\n\tfor _, x := range src {\n\t\tif f(x) {\n\t\t\tdst = append(dst, x)\n\t\t}\n\t}\n\n\treturn dst\n}", "func copy2DSlice(sourceSlice [][]byte, destinationSlice [][]byte) {\n\tfor i := 0; i < len(sourceSlice); i++ {\n\t\tfor j := 0; j < len(sourceSlice[i]); j++ {\n\t\t\tdestinationSlice[i][j] = sourceSlice[i][j]\n\t\t}\n\t}\n}", "func forwardDCT64(input []float64) {\n\tvar temp [64]float64\n\tfor i := 0; i < 32; i++ {\n\t\tx, y := input[i], input[63-i]\n\t\ttemp[i] = x + y\n\t\ttemp[i+32] = (x - y) / dct64[i]\n\t}\n\tforwardDCT32(temp[:32])\n\tforwardDCT32(temp[32:])\n\tfor i := 0; i < 32-1; i++ {\n\t\tinput[i*2+0] = temp[i]\n\t\tinput[i*2+1] = temp[i+32] + temp[i+32+1]\n\t}\n\tinput[62], input[63] = temp[31], temp[63]\n}", "func DepthwiseConv2dNativeBackpropFilter(scope *Scope, input tf.Output, filter_sizes tf.Output, out_backprop tf.Output, strides []int64, padding string, optional ...DepthwiseConv2dNativeBackpropFilterAttr) (output tf.Output) {\n\tif scope.Err() != nil {\n\t\treturn\n\t}\n\tattrs := map[string]interface{}{\"strides\": strides, \"padding\": padding}\n\tfor _, a := range optional {\n\t\ta(attrs)\n\t}\n\topspec := tf.OpSpec{\n\t\tType: \"DepthwiseConv2dNativeBackpropFilter\",\n\t\tInput: []tf.Input{\n\t\t\tinput, filter_sizes, out_backprop,\n\t\t},\n\t\tAttrs: attrs,\n\t}\n\top := scope.AddOperation(opspec)\n\treturn op.Output(0)\n}", "func (img *ByteImage) pixels() [][]byte {\n\tbyteIdx := 0\n\tpixels := make([][]byte, img.height)\n\tfor rowIdx := 0; rowIdx < img.height; rowIdx++ {\n\t\tpixels[rowIdx] = make([]byte, img.width)\n\t\tfor colIdx := 0; colIdx < img.width; colIdx++ {\n\t\t\tpixels[rowIdx][colIdx] = img.bytes[byteIdx]\n\t\t\tbyteIdx++\n\t\t}\n\t}\n\treturn pixels\n}", "func (fd FailureDist) Convolve(other FailureDist) (FailureDist, error) {\n\tn := len(fd.prob)\n\tif n != len(other.prob) {\n\t\treturn FailureDist{},\n\t\t\tfmt.Errorf(\"size mismatch %d != %d\", n, len(other.prob))\n\t}\n\tresult := make([]float64, n)\n\n\tfor i := 0; i < n; i++ {\n\t\tfor j := 0; j < n; j++ {\n\t\t\tk := i + j\n\t\t\tif k < n {\n\t\t\t\tresult[k] += fd.prob[i] * other.prob[j]\n\t\t\t}\n\t\t}\n\t}\n\n\treturn MakeFailureDist(result)\n}", "func filter(source <-chan int, destination chan<- int, prime int) {\n\tfor i := range source {\n\t\tif i%prime != 0 {\n\t\t\tdestination <- i // Send 'i' to 'destination'.\n\t\t}\n\t}\n}", "func (filter *Merge) Process(img *FilterImage) error {\n\tout := img.Image\n\tbounds := out.Bounds()\n\tinbounds := filter.Image.Bounds()\n\n\txmin := bounds.Min.X\n\tif xmin < inbounds.Min.X {\n\t\txmin = inbounds.Min.X\n\t}\n\txmax := bounds.Max.X\n\tif xmax > inbounds.Max.X {\n\t\txmax = inbounds.Max.X\n\t}\n\tymin := bounds.Min.Y\n\tif ymin < inbounds.Min.Y {\n\t\tymin = inbounds.Min.Y\n\t}\n\tymax := bounds.Max.Y\n\tif ymax > inbounds.Max.Y {\n\t\tymax = inbounds.Max.Y\n\t}\n\n\tfor x := xmin; x < xmax; x++ {\n\t\tfor y := ymin; y < ymax; y++ {\n\t\t\tr, g, b, a := out.At(x, y).RGBA()\n\t\t\tir, ig, ib, ia := filter.Image.At(x, y).RGBA()\n\n\t\t\tr = uint32(ClipInt(int(r + ir), 0, 0xFFFF))\n\t\t\tg = uint32(ClipInt(int(g + ig), 0, 0xFFFF))\n\t\t\tb = uint32(ClipInt(int(b + ib), 0, 0xFFFF))\n\t\t\ta = uint32(ClipInt(int(a + ia), 0, 0xFFFF))\n\n\t\t\tout.Set(x, y, color.NRGBA64{uint16(r), uint16(g), uint16(b), uint16(a)})\n\t\t}\n\t}\n\n\treturn nil\n}", "func (pxd pixelData) MultiChannelCircles(dest string, index int) error {\n\n rgbChannels := []RGBChannel {cs.red, cs.blue, cs.green}\n\n err := pxd.pixelLooper(func(pxAddr chan pxAddress) {\n\n for pxa := range pxAddr {\n\n row := float64(pxa.row)\n col := float64(pxa.column)\n mult := float64(pxd.blockSize)\n\n // Assign RGB values\n rgb := []float64{\n pxa.pixelWand.GetRed(), \n pxa.pixelWand.GetGreen(), \n pxa.pixelWand.GetBlue(), \n }\n\n for idx, channel := range rgbChannels {\n\n // Calculate how large each cirlce should be\n circleSize := mult / (rgb[idx] * 255 / 255 * 15 + 3)\n\n pxd.wands.pw.SetColor(channel.fill)\n // TODO\n // pxd.wands.dw.SetStrokeWidth(0)\n // pxd.wands.dw.SetStrokeColor(channel.stroke)\n pxd.wands.pw.SetOpacity(channel.opacity)\n pxd.wands.dw.SetFillColor(pxd.wands.pw)\n\n ox := float64(col*mult + channel.offset)\n oy := float64(row*mult + channel.offset)\n px := ox-float64(circleSize)\n py := oy-float64(circleSize)\n\n pxd.wands.dw.Circle(ox,oy,px,py)\n }\n }\n }, dest)\n\n return err\n}", "func downsample(srcImg image.Image) image.Image {\n\tbounds := srcImg.Bounds()\n\treturn resize.Resize(bounds.Dx()/2, bounds.Dy()/2, srcImg, resize.Bilinear)\n}", "func (f *Frame) Crop(w, h, xOffset, yOffset int) error {\n\tif w+xOffset > f.Width {\n\t\treturn fmt.Errorf(\"cropped width + x offset (%d) cannot exceed original width (%d)\",\n\t\t\tw+xOffset, f.Width)\n\t}\n\tif h+yOffset > f.Height {\n\t\treturn fmt.Errorf(\"cropped height + y offset (%d) cannot exceed original height (%d)\",\n\t\t\th+yOffset, f.Height)\n\t}\n\tnewY := make([]byte, 0, w*h)\n\tfor y := 0; y < h; y++ {\n\t\tyt := y + yOffset\n\t\tx0 := yt*f.Width + xOffset\n\t\tx1 := x0 + w\n\t\tnewY = append(newY, f.Y[x0:x1]...)\n\t}\n\tf.Y = newY\n\txss := xSubsamplingFactor[f.Chroma]\n\tyss := ySubsamplingFactor[f.Chroma]\n\tnewCb := make([]byte, 0, w/xss*h/yss)\n\tnewCr := make([]byte, 0, w/xss*h/yss)\n\tfor y := 0; y < h/yss; y++ {\n\t\tyt := y + yOffset/yss\n\t\tx0 := yt*f.Width/xss + xOffset/xss\n\t\tx1 := x0 + w/xss\n\t\tnewCb = append(newCb, f.Cb[x0:x1]...)\n\t\tnewCr = append(newCr, f.Cr[x0:x1]...)\n\t}\n\tf.Cb = newCb\n\tf.Cr = newCr\n\tif len(f.Alpha) > 0 {\n\t\tnewAlpha := make([]byte, 0, w*h)\n\t\tfor y := 0; y < h; y++ {\n\t\t\tyt := y + yOffset\n\t\t\tx0 := yt*f.Width + xOffset\n\t\t\tx1 := x0 + w\n\t\t\tnewAlpha = append(newAlpha, f.Alpha[x0:x1]...)\n\t\t}\n\t\tf.Alpha = newAlpha\n\t}\n\tf.Width = w\n\tf.Height = h\n\treturn nil\n}", "func PMOVSXBW(mx, x operand.Op) { ctx.PMOVSXBW(mx, x) }", "func dewarpFisheye(b []byte) []byte {\n\timg, _, err := image.Decode(bytes.NewReader(b))\n\tif err != nil {\n\t\tpanic(err)\n\t}\n\n\td := image.NewRGBA(img.Bounds())\n\twidth := d.Bounds().Size().X\n\theight := d.Bounds().Size().Y\n\thalfY := height / 2\n\thalfX := width / 2\n\n\tstrength := 2.35\n\tcorrRad := math.Sqrt(float64(width*width+height*height)) / strength\n\tEPSILON := 0.0000000001\n\tzoom := 1.00\n\n\tfor y := 0; y < height; y++ {\n\t\tfor x := 0; x < width; x++ {\n\t\t\tabsX := float64(x - halfX)\n\t\t\tabsY := float64(y - halfY)\n\n\t\t\tdist := math.Sqrt(absX*absX + absY*absY)\n\t\t\tr := dist / corrRad\n\t\t\ttheta := 1.\n\t\t\tif r > EPSILON {\n\t\t\t\ttheta = math.Atan(r) / r\n\t\t\t}\n\n\t\t\tsrcX := float64(halfX) + theta*absX*zoom\n\t\t\tsrcY := float64(halfY) + theta*absY*zoom\n\n\t\t\t// (srcX, srcY) will point to a place between pixels; interpolate its color value by weighting its neighbors'\n\t\t\tloX := int(srcX)\n\t\t\thiX := loX + 1\n\t\t\tdX := srcX - float64(loX)\n\n\t\t\tloY := int(srcY)\n\t\t\thiY := loY + 1\n\t\t\tdY := srcY - float64(loY)\n\n\t\t\tRi, Gi, Bi, Ai := img.At(loX, loY).RGBA()\n\t\t\tR := float64(Ri) * (1 - dX) * (1 - dY)\n\t\t\tG := float64(Gi) * (1 - dX) * (1 - dY)\n\t\t\tB := float64(Bi) * (1 - dX) * (1 - dY)\n\t\t\tA := float64(Ai) * (1 - dX) * (1 - dY)\n\n\t\t\tRi, Gi, Bi, Ai = img.At(hiX, loY).RGBA()\n\t\t\tR += float64(Ri) * dX * (1 - dY)\n\t\t\tG += float64(Gi) * dX * (1 - dY)\n\t\t\tB += float64(Bi) * dX * (1 - dY)\n\t\t\tA += float64(Ai) * dX * (1 - dY)\n\n\t\t\tRi, Gi, Bi, Ai = img.At(loX, hiY).RGBA()\n\t\t\tR += float64(Ri) * (1 - dX) * dY\n\t\t\tG += float64(Gi) * (1 - dX) * dY\n\t\t\tB += float64(Bi) * (1 - dX) * dY\n\t\t\tA += float64(Ai) * (1 - dX) * dY\n\n\t\t\tRi, Gi, Bi, Ai = img.At(hiX, hiY).RGBA()\n\t\t\tR += float64(Ri) * dX * dY\n\t\t\tG += float64(Gi) * dX * dY\n\t\t\tB += float64(Bi) * dX * dY\n\t\t\tA += float64(Ai) * dX * dY\n\n\t\t\tR16 := uint16(math.Round(R))\n\t\t\tG16 := uint16(math.Round(G))\n\t\t\tB16 := uint16(math.Round(B))\n\t\t\tA16 := uint16(math.Round(A))\n\n\t\t\tc := color.RGBA64{R: R16, G: G16, B: B16, A: A16}\n\n\t\t\td.Set(x, y, c)\n\t\t}\n\t}\n\n\tvar buf bytes.Buffer\n\tjpeg.Encode(&buf, d, nil)\n\treturn buf.Bytes()\n}", "func p256MovCond(res, a, b []uint64, cond int)", "func p256MovCond(res, a, b []uint64, cond int)", "func Conv2DBackpropFilterV2(scope *Scope, input tf.Output, filter tf.Output, out_backprop tf.Output, strides []int64, padding string, optional ...Conv2DBackpropFilterV2Attr) (output tf.Output) {\n\tif scope.Err() != nil {\n\t\treturn\n\t}\n\tattrs := map[string]interface{}{\"strides\": strides, \"padding\": padding}\n\tfor _, a := range optional {\n\t\ta(attrs)\n\t}\n\topspec := tf.OpSpec{\n\t\tType: \"Conv2DBackpropFilterV2\",\n\t\tInput: []tf.Input{\n\t\t\tinput, filter, out_backprop,\n\t\t},\n\t\tAttrs: attrs,\n\t}\n\top := scope.AddOperation(opspec)\n\treturn op.Output(0)\n}", "func (img *FloatImage) ConvolveWrapWith(kernel *ConvKernel, px planeExtension) {\n\timg.convolveWith(kernel, wrapPlaneExtension)\n}", "func Pow2Image(src image.Image) image.Image {\n\tsb := src.Bounds()\n\tw, h := uint32(sb.Dx()), uint32(sb.Dy())\n\n\tif IsPow2(w) && IsPow2(h) {\n\t\treturn src // Nothing to do.\n\t}\n\n\trect := image.Rect(0, 0, int(Pow2(w)), int(Pow2(h)))\n\n\tswitch src := src.(type) {\n\tcase *image.Alpha:\n\t\treturn copyImg(src, image.NewAlpha(rect))\n\n\tcase *image.Alpha16:\n\t\treturn copyImg(src, image.NewAlpha16(rect))\n\n\tcase *image.Gray:\n\t\treturn copyImg(src, image.NewGray(rect))\n\n\tcase *image.Gray16:\n\t\treturn copyImg(src, image.NewGray16(rect))\n\n\tcase *image.NRGBA:\n\t\treturn copyImg(src, image.NewNRGBA(rect))\n\n\tcase *image.NRGBA64:\n\t\treturn copyImg(src, image.NewNRGBA64(rect))\n\n\tcase *image.Paletted:\n\t\treturn copyImg(src, image.NewPaletted(rect, src.Palette))\n\n\tcase *image.RGBA:\n\t\treturn copyImg(src, image.NewRGBA(rect))\n\n\tcase *image.RGBA64:\n\t\treturn copyImg(src, image.NewRGBA64(rect))\n\t}\n\n\tpanic(fmt.Sprintf(\"Unsupported image format: %T\", src))\n}", "func Resize(img image.Image, width, height int, filter ResampleFilter) *image.RGBA {\n\tif width <= 0 || height <= 0 || img.Bounds().Empty() {\n\t\treturn image.NewRGBA(image.Rect(0, 0, 0, 0))\n\t}\n\n\tsrc := clone.AsRGBA(img)\n\tvar dst *image.RGBA\n\n\t// NearestNeighbor is a special case, it's faster to compute without convolution matrix.\n\tif filter.Support <= 0 {\n\t\tdst = nearestNeighbor(src, width, height)\n\t} else {\n\t\tdst = resampleHorizontal(src, width, filter)\n\t\tdst = resampleVertical(dst, height, filter)\n\t}\n\n\treturn dst\n}", "func (cm *ConnectionManager) RegisterFilters(source <-chan packet.Packet,\n\tfilters ...func(packet.Packet) packet.Packet) <-chan packet.Packet {\n\tsink := make(chan packet.Packet)\n\n\tgo func() {\n\t\tfor p := range source {\n\t\t\tfor _, filter := range filters {\n\t\t\t\tif pass := filter(p); pass != nil {\n\t\t\t\t\tsink <- pass\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}()\n\n\treturn sink\n}", "func stream_copy(src io.Reader, dst io.Writer) <-chan int {\n\tbuf := make([]byte, 1024)\n\tsync_channel := make(chan int)\n\tgo func() {\n\t\tdefer func() {\n\t\t\tif con, ok := dst.(net.Conn); ok {\n\t\t\t\tcon.Close()\n\t\t\t\tlog.Printf(\"Connection from %v is closed\\n\", con.RemoteAddr())\n\t\t\t}\n\t\t\tsync_channel <- 0 // Notify that processing is finished\n\t\t}()\n\t\tfor {\n\t\t\tvar nBytes int\n\t\t\tvar err error\n\t\t\tnBytes, err = src.Read(buf)\n\t\t\tif err != nil {\n\t\t\t\tif err != io.EOF {\n\t\t\t\t\tlog.Printf(\"Read error: %s\\n\", err)\n\t\t\t\t}\n\t\t\t\tbreak\n\t\t\t}\n\t\t\t_, err = dst.Write(buf[0:nBytes])\n\t\t\tif err != nil {\n\t\t\t\tlog.Fatalf(\"Write error: %s\\n\", err)\n\t\t\t}\n\t\t}\n\t}()\n\treturn sync_channel\n}", "func (s *ImageSpec) PixelBytesChans(chanBegin, chanEnd int, native bool) int {\n\tret := int(C.ImageSpec_pixel_bytes_chans(s.ptr, C.int(chanBegin), C.int(chanEnd), C.bool(native)))\n\truntime.KeepAlive(s)\n\treturn ret\n}", "func ToBWByteSlice(imgToConvert *image.Gray, threshold uint8) (outputBytes [][]byte) {\n\tw, h := imgToConvert.Bounds().Max.X, imgToConvert.Bounds().Max.Y\n\toutputBytes = make([][]byte, h/8, h/8)\n\tfor i := 0; i < len(outputBytes); i++ {\n\t\toutputBytes[i] = make([]byte, w)\n\t}\n\tfor currentY := 0; currentY < h/8; currentY++ {\n\t\tvar CurrentPage []byte = make([]byte, w, w)\n\t\tfor currentX := 0; currentX < w; currentX++ {\n\t\t\tvar constructedVLine byte = 0\n\t\t\tif imgToConvert.GrayAt(currentX, 0+(8*currentY)).Y >= threshold {\n\t\t\t\tconstructedVLine++\n\t\t\t}\n\t\t\tif imgToConvert.GrayAt(currentX, 1+(8*currentY)).Y >= threshold {\n\t\t\t\tconstructedVLine += 2\n\t\t\t}\n\t\t\tif imgToConvert.GrayAt(currentX, 2+(8*currentY)).Y >= threshold {\n\t\t\t\tconstructedVLine += 4\n\t\t\t}\n\t\t\tif imgToConvert.GrayAt(currentX, 3+(8*currentY)).Y >= threshold {\n\t\t\t\tconstructedVLine += 8\n\t\t\t}\n\t\t\tif imgToConvert.GrayAt(currentX, 4+(8*currentY)).Y >= threshold {\n\t\t\t\tconstructedVLine += 16\n\t\t\t}\n\t\t\tif imgToConvert.GrayAt(currentX, 5+(8*currentY)).Y >= threshold {\n\t\t\t\tconstructedVLine += 32\n\t\t\t}\n\t\t\tif imgToConvert.GrayAt(currentX, 6+(8*currentY)).Y >= threshold {\n\t\t\t\tconstructedVLine += 64\n\t\t\t}\n\t\t\tif imgToConvert.GrayAt(currentX, 7+(8*currentY)).Y >= threshold {\n\t\t\t\tconstructedVLine += 128\n\t\t\t}\n\t\t\tCurrentPage[currentX] = constructedVLine\n\t\t}\n\t\toutputBytes[currentY] = CurrentPage\n\t}\n\treturn outputBytes\n}", "func SwitchData(x, y gb.UINT8, src, dst []gb.UINT8) {}", "func Copy(dst Mutable, src Const) {\n\tif err := errIfDimsNotEq(src, dst); err != nil {\n\t\tpanic(err)\n\t}\n\n\tm, n := src.Dims()\n\tfor i := 0; i < m; i++ {\n\t\tfor j := 0; j < n; j++ {\n\t\t\tdst.Set(i, j, src.At(i, j))\n\t\t}\n\t}\n}", "func (p *p256Point) CopyConditional(src *p256Point, v int) {\r\n\tpMask := uint64(v) - 1\r\n\tsrcMask := ^pMask\r\n\r\n\tfor i, n := range p.xyz {\r\n\t\tp.xyz[i] = (n & pMask) | (src.xyz[i] & srcMask)\r\n\t}\r\n}", "func (r *Rasterizer8BitsSample) fillEvenOdd(img *image.RGBA, c color.Color, clipBound [4]float64) {\n\tvar x, y uint32\n\n\tminX := uint32(clipBound[0])\n\tmaxX := uint32(clipBound[2])\n\n\tminY := uint32(clipBound[1]) >> SUBPIXEL_SHIFT\n\tmaxY := uint32(clipBound[3]) >> SUBPIXEL_SHIFT\n\n\trgba := convert(c)\n\tpixColor := *(*uint32)(unsafe.Pointer(&rgba))\n\n\tcs1 := pixColor & 0xff00ff\n\tcs2 := pixColor >> 8 & 0xff00ff\n\n\tstride := uint32(img.Stride)\n\tvar mask SUBPIXEL_DATA\n\tmaskY := minY * uint32(r.BufferWidth)\n\tminY *= stride\n\tmaxY *= stride\n\tvar tp []uint8\n\tvar pixelx uint32\n\tfor y = minY; y < maxY; y += stride {\n\t\ttp = img.Pix[y:]\n\t\tmask = 0\n\n\t\t//i0 := (s.Y-r.Image.Rect.Min.Y)*r.Image.Stride + (s.X0-r.Image.Rect.Min.X)*4\r\n\t\t//i1 := i0 + (s.X1-s.X0)*4\r\n\t\tpixelx = minX * 4\n\t\tfor x = minX; x <= maxX; x++ {\n\t\t\tmask ^= r.MaskBuffer[maskY+x]\n\t\t\t// 8bits\r\n\t\t\talpha := uint32(coverageTable[mask])\n\t\t\t// 16bits\r\n\t\t\t//alpha := uint32(coverageTable[mask & 0xff] + coverageTable[(mask >> 8) & 0xff])\r\n\t\t\t// 32bits\r\n\t\t\t//alpha := uint32(coverageTable[mask & 0xff] + coverageTable[(mask >> 8) & 0xff] + coverageTable[(mask >> 16) & 0xff] + coverageTable[(mask >> 24) & 0xff])\r\n\n\t\t\t// alpha is in range of 0 to SUBPIXEL_COUNT\r\n\t\t\tp := (*uint32)(unsafe.Pointer(&tp[pixelx]))\n\t\t\tif alpha == SUBPIXEL_FULL_COVERAGE {\n\t\t\t\t*p = pixColor\n\t\t\t} else if alpha != 0 {\n\t\t\t\tinvAlpha := SUBPIXEL_COUNT - alpha\n\t\t\t\tct1 := *p & 0xff00ff * invAlpha\n\t\t\t\tct2 := *p >> 8 & 0xff00ff * invAlpha\n\n\t\t\t\tct1 = (ct1 + cs1*alpha) >> SUBPIXEL_SHIFT & 0xff00ff\n\t\t\t\tct2 = (ct2 + cs2*alpha) << (8 - SUBPIXEL_SHIFT) & 0xff00ff00\n\n\t\t\t\t*p = ct1 + ct2\n\t\t\t}\n\t\t\tpixelx += 4\n\t\t}\n\t\tmaskY += uint32(r.BufferWidth)\n\t}\n}", "func (filter *Saturation) Process(img *FilterImage) error {\n\tout := img.Image\n\tbounds := out.Bounds()\n\tfor x := bounds.Min.X; x < bounds.Max.X; x++ {\n\t\tfor y := bounds.Min.Y; y < bounds.Max.Y; y++ {\n\t\t\tr, g, b, a := out.At(x, y).RGBA()\n\n\t\t\tgrey := (r + g + b) / 3\n\n\t\t\tnr := Trunc(r + ((Abs(int32(r-grey)) * filter.Strength) / 100))\n\t\t\tng := Trunc(g + ((Abs(int32(g-grey)) * filter.Strength) / 100))\n\t\t\tnb := Trunc(b + ((Abs(int32(b-grey)) * filter.Strength) / 100))\n\n\t\t\tnc := color.NRGBA64{nr, ng, nb, uint16(a)}\n\t\t\tout.Set(x, y, nc)\n\t\t}\n\t}\n\treturn nil\n}", "func encodeBWData(w io.Writer, img image.Image, opts *EncodeOptions) error {\n\t// In the background, write each index value into a channel.\n\trect := img.Bounds()\n\twidth := rect.Max.X - rect.Min.X\n\tsamples := make(chan uint16, width)\n\tgo func() {\n\t\tbwImage := NewBW(image.ZR)\n\t\tcm := bwImage.ColorModel().(color.Palette)\n\t\tfor y := rect.Min.Y; y < rect.Max.Y; y++ {\n\t\t\tfor x := rect.Min.X; x < rect.Max.X; x++ {\n\t\t\t\tsamples <- uint16(cm.Index(img.At(x, y)))\n\t\t\t}\n\t\t}\n\t\tclose(samples)\n\t}()\n\n\t// In the foreground, consume index values (either 0 or 1) and\n\t// write them to the image file as individual bits. Pack 8\n\t// bits to a byte, pad each row, and output.\n\tif opts.Plain {\n\t\treturn writePlainData(w, samples)\n\t}\n\twb, ok := w.(*bufio.Writer)\n\tif !ok {\n\t\twb = bufio.NewWriter(w)\n\t}\n\tvar b byte // Next byte to write\n\tvar bLen uint // Valid bits in b\n\tvar rowBits int // Bits written to the current row\n\tfor s := range samples {\n\t\tb = b<<1 | byte(s)\n\t\tbLen++\n\t\trowBits++\n\t\tif rowBits == width {\n\t\t\t// Pad the last byte in the row.\n\t\t\tb <<= 8 - bLen\n\t\t\tbLen = 8\n\t\t\trowBits = 0\n\t\t}\n\t\tif bLen == 8 {\n\t\t\t// Write a full byte to the output.\n\t\t\tif err := wb.WriteByte(b); err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\t\t\tb = 0\n\t\t\tbLen = 0\n\t\t}\n\t}\n\twb.Flush()\n\treturn nil\n}", "func MulConstAVX32(c float32, x []float32, y []float32)", "func square(img *image.Paletted, p squareParams) {\n\tfor x := p.from.x; x < p.to.x; x++ {\n\t\tfor y := p.from.y; y < p.to.y; y++ {\n\t\t\timg.Set(x, y, p.c)\n\t\t}\n\t}\n}", "func (n *Node) Convconst(con *Node, t *Type)" ]
[ "0.7410087", "0.6712185", "0.6649832", "0.64741814", "0.63578194", "0.63215214", "0.60116434", "0.5824171", "0.57838714", "0.5715813", "0.56136847", "0.5597352", "0.54525596", "0.53481835", "0.5248561", "0.5243912", "0.5227945", "0.519987", "0.5178303", "0.5174178", "0.51658684", "0.51640326", "0.5138945", "0.510374", "0.5078412", "0.50470674", "0.5040979", "0.502544", "0.5008604", "0.49861428", "0.49692625", "0.49605152", "0.49239093", "0.48906052", "0.48841786", "0.48593852", "0.48378694", "0.47637844", "0.47277978", "0.47265518", "0.46816558", "0.46541014", "0.46495754", "0.46490166", "0.46433717", "0.46374553", "0.4634919", "0.46142185", "0.46135357", "0.4598141", "0.45730522", "0.4554533", "0.45506656", "0.453461", "0.45238167", "0.4494606", "0.4479729", "0.4450312", "0.4442128", "0.44279388", "0.4418432", "0.44160232", "0.44042432", "0.43990484", "0.43884668", "0.43872827", "0.43841377", "0.43810913", "0.4368192", "0.4364542", "0.43591183", "0.4355022", "0.43544436", "0.43495566", "0.43468073", "0.43458748", "0.43453974", "0.43403178", "0.4338219", "0.43341443", "0.4331383", "0.4326496", "0.4326496", "0.4313152", "0.43099505", "0.42842475", "0.4277752", "0.42625254", "0.4260349", "0.4257632", "0.42544687", "0.4254064", "0.42495963", "0.4216882", "0.42144206", "0.4211415", "0.42107898", "0.42091486", "0.4207261", "0.42028525" ]
0.7162849
1
perform a raw data copy between two images
func CopyImageSubData(srcName uint32, srcTarget uint32, srcLevel int32, srcX int32, srcY int32, srcZ int32, dstName uint32, dstTarget uint32, dstLevel int32, dstX int32, dstY int32, dstZ int32, srcWidth int32, srcHeight int32, srcDepth int32) { C.glowCopyImageSubData(gpCopyImageSubData, (C.GLuint)(srcName), (C.GLenum)(srcTarget), (C.GLint)(srcLevel), (C.GLint)(srcX), (C.GLint)(srcY), (C.GLint)(srcZ), (C.GLuint)(dstName), (C.GLenum)(dstTarget), (C.GLint)(dstLevel), (C.GLint)(dstX), (C.GLint)(dstY), (C.GLint)(dstZ), (C.GLsizei)(srcWidth), (C.GLsizei)(srcHeight), (C.GLsizei)(srcDepth)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func CopyImageSubData(srcName uint32, srcTarget uint32, srcLevel int32, srcX int32, srcY int32, srcZ int32, dstName uint32, dstTarget uint32, dstLevel int32, dstX int32, dstY int32, dstZ int32, srcWidth int32, srcHeight int32, srcDepth int32) {\n C.glowCopyImageSubData(gpCopyImageSubData, (C.GLuint)(srcName), (C.GLenum)(srcTarget), (C.GLint)(srcLevel), (C.GLint)(srcX), (C.GLint)(srcY), (C.GLint)(srcZ), (C.GLuint)(dstName), (C.GLenum)(dstTarget), (C.GLint)(dstLevel), (C.GLint)(dstX), (C.GLint)(dstY), (C.GLint)(dstZ), (C.GLsizei)(srcWidth), (C.GLsizei)(srcHeight), (C.GLsizei)(srcDepth))\n}", "func Copy(dst draw.Image, src image.Image) {\n\tbd := src.Bounds().Intersect(dst.Bounds())\n\tat := imageutil.NewAtFunc(src)\n\tset := imageutil.NewSetFunc(dst)\n\timageutil.Parallel1D(bd, func(bd image.Rectangle) {\n\t\tfor y := bd.Min.Y; y < bd.Max.Y; y++ {\n\t\t\tfor x := bd.Min.X; x < bd.Max.X; x++ {\n\t\t\t\tr, g, b, a := at(x, y)\n\t\t\t\tset(x, y, r, g, b, a)\n\t\t\t}\n\t\t}\n\t})\n}", "func (c *Client) copyImage(src, dst string) error {\n\tctx, cancel := context.WithTimeout(context.Background(), time.Duration(c.copyTimeoutSeconds)*time.Second)\n\tdefer cancel()\n\tcmdStr := c.skopeoCopyCmd(src, dst)\n\tlogf.Log.WithName(\"registry_client\").V(1).Info(\"Command\", cmdStr)\n\tcmdSl := strings.Split(cmdStr, \" \")\n\treturn exec.CommandContext(ctx, cmdSl[0], cmdSl[1:]...).Run()\n}", "func copyImg(filename string, rowX int, colX int) string {\n\t//Filename path\n\tpath := \"/gorpc/Images/\" + filename\n\n\t//Extract matrix of image file data\n\tpixels := gocv.IMRead(path, 1)\n\n\t//Get dimensions from picture\n\tdimensions := pixels.Size()\n\theight := dimensions[0]\n\twidth := dimensions[1]\n\n\t//Get type of mat\n\tmatType := pixels.Type()\n\n\t//Create a new mat to fill\n\tbigMat := gocv.NewMatWithSize(height * rowX, width * colX, matType)\n\n\t//Created a wait group to sync filling images\n\twg := sync.WaitGroup{}\n\twg.Add(rowX * colX)\n\n\t//Fill in image copies by relative index on matrix\n\tfor i := 0; i < rowX; i++{\n\t\tfor j := 0; j < colX; j++{\n\t\t\tgo func (i int, j int){\n\t\t\t\t//Decrement counter if an image copy is made\n\t\t\t\tdefer wg.Done()\n\n\t\t\t\t//Iterate over original image and store in new index copy\n\t\t\t\tfor x := 0; x < height; x++{\n\t\t\t\t\tfor y := 0; y < width; y++{\n\t\t\t\t\t\tval := GetVecbAt(pixels, x, y)\n\n\t\t\t\t\t\tval.SetVecbAt(bigMat, (i*height) + x, (j*width) + y)\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}(i, j)\n\t\t}\n\t}\n\n\t//Wait till all copies are filled in\n\twg.Wait()\n\n\t//Remove extension from filename\n\text := filepath.Ext(filename)\n\tname := strings.TrimSuffix(filename, ext)\n\n\t//Rename the new scaled image\n\tnewName := name + \"C\" + ext\n\n\t//New path\n\tnewPath := \"/gorpc/Images/\" + newName\n\n\t//Save the new image from matrix in local directory\n\tgocv.IMWrite(newPath, bigMat)\n\n\treturn newName\n}", "func CopyImageSubData(srcName uint32, srcTarget uint32, srcLevel int32, srcX int32, srcY int32, srcZ int32, dstName uint32, dstTarget uint32, dstLevel int32, dstX int32, dstY int32, dstZ int32, srcWidth int32, srcHeight int32, srcDepth int32) {\n\tsyscall.Syscall15(gpCopyImageSubData, 15, uintptr(srcName), uintptr(srcTarget), uintptr(srcLevel), uintptr(srcX), uintptr(srcY), uintptr(srcZ), uintptr(dstName), uintptr(dstTarget), uintptr(dstLevel), uintptr(dstX), uintptr(dstY), uintptr(dstZ), uintptr(srcWidth), uintptr(srcHeight), uintptr(srcDepth))\n}", "func (a RegMan) Copy(imgSrc, imgDst string) error {\n\n\tsourceURL, err := getRegistryURL(a.Config.SourceRegistry.Type, a.Config.SourceRegistry.URL, imgSrc)\n\tif err != nil {\n\t\tlog.Error(err)\n\t}\n\n\tdestinationURL, err := getRegistryURL(a.Config.DestinationRegistry.Type, a.Config.DestinationRegistry.URL, imgDst)\n\n\tsrcRef, err := alltransports.ParseImageName(sourceURL)\n\tif err != nil {\n\t\tlog.Errorf(\"Invalid source name %s: %v\", sourceURL, err)\n\t}\n\tdestRef, err := alltransports.ParseImageName(destinationURL)\n\tif err != nil {\n\t\tlog.Errorf(\"Invalid destination name %s: %v\", destinationURL, err)\n\t}\n\n\tlog.Debugf(\"Copy %s to %s\", sourceURL, destinationURL)\n\n\t//signBy := context.String(\"sign-by\")\n\tremoveSignatures := true\n\n\tlog.Debug(\"Start copy\")\n\terr = copy.Image(a.policy, destRef, srcRef, &copy.Options{\n\t\tRemoveSignatures: removeSignatures,\n\t\tReportWriter: os.Stdout,\n\t\tSourceCtx: a.srcCtx,\n\t\tDestinationCtx: a.dstCtx,\n\t})\n\tif err != nil {\n\t\tlog.Error(err)\n\t}\n\treturn err\n}", "func (rc *RegClient) BlobCopy(ctx context.Context, refSrc ref.Ref, refTgt ref.Ref, d types.Descriptor) error {\n\ttDesc := d\n\ttDesc.URLs = []string{} // ignore URLs when pushing to target\n\t// for the same repository, there's nothing to copy\n\tif ref.EqualRepository(refSrc, refTgt) {\n\t\trc.log.WithFields(logrus.Fields{\n\t\t\t\"src\": refTgt.Reference,\n\t\t\t\"tgt\": refTgt.Reference,\n\t\t\t\"digest\": d.Digest,\n\t\t}).Debug(\"Blob copy skipped, same repo\")\n\t\treturn nil\n\t}\n\t// check if layer already exists\n\tif _, err := rc.BlobHead(ctx, refTgt, tDesc); err == nil {\n\t\trc.log.WithFields(logrus.Fields{\n\t\t\t\"tgt\": refTgt.Reference,\n\t\t\t\"digest\": d,\n\t\t}).Debug(\"Blob copy skipped, already exists\")\n\t\treturn nil\n\t}\n\t// try mounting blob from the source repo is the registry is the same\n\tif ref.EqualRegistry(refSrc, refTgt) {\n\t\terr := rc.BlobMount(ctx, refSrc, refTgt, d)\n\t\tif err == nil {\n\t\t\trc.log.WithFields(logrus.Fields{\n\t\t\t\t\"src\": refTgt.Reference,\n\t\t\t\t\"tgt\": refTgt.Reference,\n\t\t\t\t\"digest\": d,\n\t\t\t}).Debug(\"Blob copy performed server side with registry mount\")\n\t\t\treturn nil\n\t\t}\n\t\trc.log.WithFields(logrus.Fields{\n\t\t\t\"err\": err,\n\t\t\t\"src\": refSrc.Reference,\n\t\t\t\"tgt\": refTgt.Reference,\n\t\t}).Warn(\"Failed to mount blob\")\n\t}\n\t// fast options failed, download layer from source and push to target\n\tblobIO, err := rc.BlobGet(ctx, refSrc, d)\n\tif err != nil {\n\t\trc.log.WithFields(logrus.Fields{\n\t\t\t\"err\": err,\n\t\t\t\"src\": refSrc.Reference,\n\t\t\t\"digest\": d,\n\t\t}).Warn(\"Failed to retrieve blob\")\n\t\treturn err\n\t}\n\tdefer blobIO.Close()\n\tif _, err := rc.BlobPut(ctx, refTgt, blobIO.GetDescriptor(), blobIO); err != nil {\n\t\trc.log.WithFields(logrus.Fields{\n\t\t\t\"err\": err,\n\t\t\t\"src\": refSrc.Reference,\n\t\t\t\"tgt\": refTgt.Reference,\n\t\t}).Warn(\"Failed to push blob\")\n\t\treturn err\n\t}\n\treturn nil\n}", "func (s *stencilOverdraw) copyImageAspect(ctx context.Context,\n\tcb CommandBuilder,\n\tgs *api.GlobalState,\n\tst *State,\n\ta arena.Arena,\n\tdevice VkDevice,\n\tcmdBuffer VkCommandBuffer,\n\tsrcImgDesc imageDesc,\n\tdstImgDesc imageDesc,\n\textent VkExtent3D,\n\talloc func(v ...interface{}) api.AllocResult,\n\taddCleanup func(func()),\n\tout transform.Writer,\n) {\n\tsrcImg := srcImgDesc.image\n\tdstImg := dstImgDesc.image\n\tcopyBuffer := s.createDepthCopyBuffer(ctx, cb, gs, st, a, device,\n\t\tsrcImg.Info().Fmt(),\n\t\textent.Width(), extent.Height(),\n\t\talloc, addCleanup, out)\n\n\tallCommandsStage := VkPipelineStageFlags(\n\t\tVkPipelineStageFlagBits_VK_PIPELINE_STAGE_ALL_COMMANDS_BIT)\n\tallMemoryAccess := VkAccessFlags(\n\t\tVkAccessFlagBits_VK_ACCESS_MEMORY_WRITE_BIT |\n\t\t\tVkAccessFlagBits_VK_ACCESS_MEMORY_READ_BIT)\n\n\timgBarriers0 := make([]VkImageMemoryBarrier, 2)\n\timgBarriers1 := make([]VkImageMemoryBarrier, 2)\n\t// Transition the src image in and out of the required layouts\n\timgBarriers0[0] = NewVkImageMemoryBarrier(a,\n\t\tVkStructureType_VK_STRUCTURE_TYPE_IMAGE_MEMORY_BARRIER, // sType\n\t\t0, // pNext\n\t\tallMemoryAccess, // srcAccessMask\n\t\tVkAccessFlags(VkAccessFlagBits_VK_ACCESS_TRANSFER_READ_BIT), // dstAccessMask\n\t\tsrcImgDesc.layout, // oldLayout\n\t\tVkImageLayout_VK_IMAGE_LAYOUT_TRANSFER_SRC_OPTIMAL, // newLayout\n\t\t^uint32(0), // srcQueueFamilyIndex: VK_QUEUE_FAMILY_IGNORED\n\t\t^uint32(0), // dstQueueFamilyIndex\n\t\tsrcImg.VulkanHandle(), // image\n\t\tsrcImgDesc.subresource, // subresourceRange\n\t)\n\tsrcFinalLayout := srcImgDesc.layout\n\tif srcFinalLayout == VkImageLayout_VK_IMAGE_LAYOUT_UNDEFINED ||\n\t\tsrcFinalLayout == VkImageLayout_VK_IMAGE_LAYOUT_PREINITIALIZED {\n\t\tsrcFinalLayout = VkImageLayout_VK_IMAGE_LAYOUT_GENERAL\n\t}\n\timgBarriers1[0] = NewVkImageMemoryBarrier(a,\n\t\tVkStructureType_VK_STRUCTURE_TYPE_IMAGE_MEMORY_BARRIER, // sType\n\t\t0, // pNext\n\t\tVkAccessFlags(VkAccessFlagBits_VK_ACCESS_TRANSFER_READ_BIT), // srcAccessMask\n\t\tallMemoryAccess, // dstAccessMask\n\t\tVkImageLayout_VK_IMAGE_LAYOUT_TRANSFER_SRC_OPTIMAL, // oldLayout\n\t\tsrcFinalLayout, // newLayout\n\t\t^uint32(0), // srcQueueFamilyIndex: VK_QUEUE_FAMILY_IGNORED\n\t\t^uint32(0), // dstQueueFamilyIndex\n\t\tsrcImg.VulkanHandle(), // image\n\t\tsrcImgDesc.subresource, // subresourceRange\n\t)\n\n\t// Transition the new image in and out of its required layouts\n\timgBarriers0[1] = NewVkImageMemoryBarrier(a,\n\t\tVkStructureType_VK_STRUCTURE_TYPE_IMAGE_MEMORY_BARRIER, // sType\n\t\t0, // pNext\n\t\tallMemoryAccess, // srcAccessMask\n\t\tVkAccessFlags(VkAccessFlagBits_VK_ACCESS_TRANSFER_WRITE_BIT), // dstAccessMask\n\t\tdstImgDesc.layout, // oldLayout\n\t\tVkImageLayout_VK_IMAGE_LAYOUT_TRANSFER_DST_OPTIMAL, // newLayout\n\t\t^uint32(0), // srcQueueFamilyIndex: VK_QUEUE_FAMILY_IGNORED\n\t\t^uint32(0), // dstQueueFamilyIndex\n\t\tdstImg.VulkanHandle(), // image\n\t\tdstImgDesc.subresource, // subresourceRange\n\t)\n\n\tdstFinalLayout := dstImgDesc.layout\n\tif dstFinalLayout == VkImageLayout_VK_IMAGE_LAYOUT_UNDEFINED ||\n\t\tdstFinalLayout == VkImageLayout_VK_IMAGE_LAYOUT_PREINITIALIZED {\n\t\tdstFinalLayout = VkImageLayout_VK_IMAGE_LAYOUT_GENERAL\n\t}\n\timgBarriers1[1] = NewVkImageMemoryBarrier(a,\n\t\tVkStructureType_VK_STRUCTURE_TYPE_IMAGE_MEMORY_BARRIER, // sType\n\t\t0, // pNext\n\t\tVkAccessFlags(VkAccessFlagBits_VK_ACCESS_TRANSFER_WRITE_BIT), // srcAccessMask\n\t\tallMemoryAccess, // dstAccessMask\n\t\tVkImageLayout_VK_IMAGE_LAYOUT_TRANSFER_DST_OPTIMAL, // oldLayout\n\t\tdstFinalLayout, // newLayout\n\t\t^uint32(0), // srcQueueFamilyIndex: VK_QUEUE_FAMILY_IGNORED\n\t\t^uint32(0), // dstQueueFamilyIndex\n\t\tdstImg.VulkanHandle(), // image\n\t\tdstImgDesc.subresource, // subresourceRange\n\t)\n\n\tbufBarrier := NewVkBufferMemoryBarrier(a,\n\t\tVkStructureType_VK_STRUCTURE_TYPE_BUFFER_MEMORY_BARRIER, // sType\n\t\t0, // pNext\n\t\tVkAccessFlags(VkAccessFlagBits_VK_ACCESS_TRANSFER_WRITE_BIT), // srcAccessMask\n\t\tVkAccessFlags(VkAccessFlagBits_VK_ACCESS_TRANSFER_READ_BIT), // dstAccessMask\n\t\t^uint32(0), // srcQueueFamilyIndex: VK_QUEUE_FAMILY_IGNORED\n\t\t^uint32(0), // dstQueueFamilyIndex\n\t\tcopyBuffer, // buffer\n\t\t0, // offset\n\t\t^VkDeviceSize(0), // size: VK_WHOLE_SIZE\n\t)\n\n\tibCopy := NewVkBufferImageCopy(a,\n\t\t0, // bufferOffset\n\t\t0, // bufferRowLength\n\t\t0, // bufferImageHeight\n\t\tNewVkImageSubresourceLayers(a,\n\t\t\tVkImageAspectFlags(srcImgDesc.aspect), // aspectMask\n\t\t\tsrcImgDesc.subresource.BaseMipLevel(), // mipLevel\n\t\t\tsrcImgDesc.subresource.BaseArrayLayer(), // baseArrayLayer\n\t\t\t1, // layerCount\n\t\t), // srcSubresource\n\t\tNewVkOffset3D(a, 0, 0, 0), // offset\n\t\tNewVkExtent3D(a, extent.Width(), extent.Height(), 1), // extent\n\t)\n\n\tbiCopy := NewVkBufferImageCopy(a,\n\t\t0, // bufferOffset\n\t\t0, // bufferRowLength\n\t\t0, // bufferImageHeight\n\t\tNewVkImageSubresourceLayers(a,\n\t\t\tVkImageAspectFlags(dstImgDesc.aspect), // aspectMask\n\t\t\tdstImgDesc.subresource.BaseMipLevel(), // mipLevel\n\t\t\tdstImgDesc.subresource.BaseArrayLayer(), // baseArrayLayer\n\t\t\t1, // layerCount\n\t\t), // srcSubresource\n\t\tNewVkOffset3D(a, 0, 0, 0), // offset\n\t\tNewVkExtent3D(a, extent.Width(), extent.Height(), 1), // extent\n\t)\n\n\timgBarriers0Data := alloc(imgBarriers0)\n\tibCopyData := alloc(ibCopy)\n\tbufBarrierData := alloc(bufBarrier)\n\tbiCopyData := alloc(biCopy)\n\timgBarriers1Data := alloc(imgBarriers1)\n\n\twriteEach(ctx, out,\n\t\tcb.VkCmdPipelineBarrier(cmdBuffer,\n\t\t\tallCommandsStage, // srcStageMask\n\t\t\tVkPipelineStageFlags(VkPipelineStageFlagBits_VK_PIPELINE_STAGE_TRANSFER_BIT), // dstStageMask\n\t\t\t0, // dependencyFlags\n\t\t\t0, // memoryBarrierCount\n\t\t\tmemory.Nullptr, // pMemoryBarriers\n\t\t\t0, // bufferMemoryBarrierCount\n\t\t\tmemory.Nullptr, // pBufferMemoryBarriers\n\t\t\t2, // imageMemoryBarrierCount\n\t\t\timgBarriers0Data.Ptr(), // pImageMemoryBarriers\n\t\t).AddRead(imgBarriers0Data.Data()),\n\t\tcb.VkCmdCopyImageToBuffer(cmdBuffer,\n\t\t\tsrcImg.VulkanHandle(), // srcImage\n\t\t\tVkImageLayout_VK_IMAGE_LAYOUT_TRANSFER_SRC_OPTIMAL, // srcImageLayout\n\t\t\tcopyBuffer, // dstBuffer\n\t\t\t1, // regionCount\n\t\t\tibCopyData.Ptr(), // pRegions\n\t\t).AddRead(ibCopyData.Data()),\n\t\tcb.VkCmdPipelineBarrier(cmdBuffer,\n\t\t\tVkPipelineStageFlags(VkPipelineStageFlagBits_VK_PIPELINE_STAGE_TRANSFER_BIT), // srcStageMask\n\t\t\tVkPipelineStageFlags(VkPipelineStageFlagBits_VK_PIPELINE_STAGE_TRANSFER_BIT), // dstStageMask\n\t\t\t0, // dependencyFlags\n\t\t\t0, // memoryBarrierCount\n\t\t\tmemory.Nullptr, // pMemoryBarriers\n\t\t\t1, // bufferMemoryBarrierCount\n\t\t\tbufBarrierData.Ptr(), // pBufferMemoryBarriers\n\t\t\t0, // imageMemoryBarrierCount\n\t\t\tmemory.Nullptr, // pImageMemoryBarriers\n\t\t).AddRead(bufBarrierData.Data()),\n\t\tcb.VkCmdCopyBufferToImage(cmdBuffer,\n\t\t\tcopyBuffer, // srcBuffer\n\t\t\tdstImg.VulkanHandle(), // dstImage\n\t\t\tVkImageLayout_VK_IMAGE_LAYOUT_TRANSFER_DST_OPTIMAL, // dstImageLayout\n\t\t\t1, // regionCount\n\t\t\tbiCopyData.Ptr(), // pRegions\n\t\t).AddRead(biCopyData.Data()),\n\t\tcb.VkCmdPipelineBarrier(cmdBuffer,\n\t\t\tVkPipelineStageFlags(VkPipelineStageFlagBits_VK_PIPELINE_STAGE_TRANSFER_BIT), // srcStageMask\n\t\t\tallCommandsStage, // dstStageMask\n\t\t\t0, // dependencyFlags\n\t\t\t0, // memoryBarrierCount\n\t\t\tmemory.Nullptr, // pMemoryBarriers\n\t\t\t0, // bufferMemoryBarrierCount\n\t\t\tmemory.Nullptr, // pBufferMemoryBarriers\n\t\t\t2, // imageMemoryBarrierCount\n\t\t\timgBarriers1Data.Ptr(), // pImageMemoryBarriers\n\t\t).AddRead(imgBarriers1Data.Data()),\n\t)\n}", "func (a DBFSAPI) Copy(src string, tgt string, client *DBApiClient, overwrite bool) error {\n\thandle, err := a.createHandle(tgt, overwrite)\n\tif err != nil {\n\t\treturn err\n\t}\n\tdefer func() {\n\t\terr = a.closeHandle(handle)\n\t}()\n\tfetchLoop := true\n\toffSet := int64(0)\n\tlength := int64(1e6)\n\tfor fetchLoop {\n\t\tvar api DBFSAPI\n\t\tif client == nil {\n\t\t\tapi = a\n\t\t} else {\n\t\t\tapi = client.DBFS()\n\t\t}\n\t\tbytesRead, b64String, err := api.ReadString(src, offSet, length)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tlog.Println(bytesRead)\n\t\tif bytesRead == 0 || bytesRead < length {\n\t\t\tfetchLoop = false\n\t\t}\n\n\t\terr = a.addBlock(b64String, handle)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\n\t\toffSet += length\n\t}\n\n\treturn err\n}", "func clone(dst, src *image.Gray) {\n\tif dst.Stride == src.Stride {\n\t\t// no need to correct stride, simply copy pixels.\n\t\tcopy(dst.Pix, src.Pix)\n\t\treturn\n\t}\n\t// need to correct stride.\n\tfor i := 0; i < src.Rect.Dy(); i++ {\n\t\tdstH := i * dst.Stride\n\t\tsrcH := i * src.Stride\n\t\tcopy(dst.Pix[dstH:dstH+dst.Stride], src.Pix[srcH:srcH+dst.Stride])\n\t}\n}", "func (bio *BinaryIO) Copy(dst int64, src int64, count int) error {\n\tbuf := makeBuf(count)\n\tfor count > 0 {\n\t\tbuf = truncBuf(buf, count)\n\t\tbio.ReadAt(src, buf)\n\t\tbio.WriteAt(dst, buf)\n\t\tcount -= len(buf)\n\t\tsrc += int64(len(buf))\n\t\tdst += int64(len(buf))\n\t}\n\treturn nil\n}", "func (i *ImageBuf) Copy(src *ImageBuf) error {\n\tok := bool(C.ImageBuf_copy(i.ptr, src.ptr))\n\truntime.KeepAlive(i)\n\truntime.KeepAlive(src)\n\tif !ok {\n\t\treturn i.LastError()\n\t}\n\treturn nil\n}", "func (c *Container) setBitmapCopy(bitmap []uint64) {\n\tvar bitmapCopy [bitmapN]uint64\n\tcopy(bitmapCopy[:], bitmap)\n\tc.setBitmap(bitmapCopy[:])\n}", "func (r *Resources) Copy(other *Resources) {\n\tr.CPU = other.CPU\n\tr.DISK = other.DISK\n\tr.MEMORY = other.MEMORY\n\tr.GPU = other.GPU\n}", "func (fr *Frame) Copy(orig *Frame) {\n\tfr.Status = orig.Status\n\tfor y, row := range orig.Pix {\n\t\tcopy(fr.Pix[y][:], row)\n\t}\n}", "func (r *ImageRef) Copy() (*ImageRef, error) {\n\tout, err := vipsCopyImage(r.image)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\n\treturn newImageRef(out, r.format, r.originalFormat, r.buf), nil\n}", "func copy_half(backend *Backend, dst, src *net.TCPConn, wg *sync.WaitGroup) {\n\tdefer wg.Done()\n\ttransferred, err := io.Copy(dst, src)\n\tbackend.transferred += transferred\n\tif err != nil {\n\t\tlog.Printf(\"Error: %s\", err)\n\t}\n\tdst.CloseWrite()\n\tsrc.CloseRead()\n}", "func copy2DSlice(sourceSlice [][]byte, destinationSlice [][]byte) {\n\tfor i := 0; i < len(sourceSlice); i++ {\n\t\tfor j := 0; j < len(sourceSlice[i]); j++ {\n\t\t\tdestinationSlice[i][j] = sourceSlice[i][j]\n\t\t}\n\t}\n}", "func ioTransferData(env *Env, conn1, conn2 io.ReadWriteCloser) {\n\tpairs := []struct{ dst, src io.ReadWriteCloser }{{conn1, conn2}, {conn2, conn1}}\n\tfor _, p := range pairs {\n\t\tgo func(src, dst io.ReadWriteCloser) {\n\t\t\tio.Copy(dst, src)\n\t\t\tdst.Close()\n\t\t}(p.src, p.dst)\n\t}\n}", "func (d *driver) copy(ctx context.Context, sourcePath string, destPath string) error {\n\t// OBS can copy objects up to 5 GB in size with a single PUT Object - Copy\n\t// operation. For larger objects, the multipart upload API must be used.\n\t//\n\t// For each part except the last part, file size has to be in the range of\n\t//[100KB, 5GB], the last part should be at least 100KB.\n fileInfo, err := d.Stat(ctx, sourcePath)\n\tif err != nil {\n\t\treturn parseError(sourcePath, err)\n\t}\n\tif fileInfo.Size() <= d.MultipartCopyThresholdSize {\n\t\t_, err := d.Client.CopyObject(&obs.CopyObjectInput{\n\t\t\tObjectOperationInput: obs.ObjectOperationInput{\n\t\t\t\tBucket: d.Bucket,\n\t\t\t\tKey: d.obsPath(destPath),\n\t\t\t\tACL: d.getACL(),\n\t\t\t\tStorageClass: d.getStorageClass(),\n\t\t\t\t//SseHeader: obs.SseKmsHeader{Encryption: obs.DEFAULT_SSE_KMS_ENCRYPTION},\n\t\t\t},\n\t\t\tCopySourceBucket: d.Bucket,\n\t\t\tCopySourceKey: d.obsPath(sourcePath),\n\t\t\tContentType: d.getContentType(),\n\t\t})\n\n\t\tif err != nil {\n\t\t\treturn parseError(sourcePath, err)\n\t\t}\n\t\treturn nil\n\t}\n\tinitOutput, err := d.Client.InitiateMultipartUpload(&obs.InitiateMultipartUploadInput{\n\t\tObjectOperationInput: obs.ObjectOperationInput{\n\t\t\tBucket: d.Bucket,\n\t\t\tKey: d.obsPath(destPath),\n\t\t\tACL: d.getACL(),\n\t\t\tStorageClass: d.getStorageClass(),\n\t\t\t//SseHeader: obs.SseKmsHeader{Encryption: obs.DEFAULT_SSE_KMS_ENCRYPTION},\n\t\t},\n\t\tContentType: d.getContentType(),\n\t})\n\tif err != nil {\n\t\treturn err\n\t}\n\tnumParts := (fileInfo.Size() + d.MultipartCopyChunkSize - 1) / d.MultipartCopyChunkSize\n\tcompletedParts := make([]obs.Part, numParts)\n\terrChan := make(chan error, numParts)\n\tlimiter := make(chan struct{}, d.MultipartCopyMaxConcurrency)\n\tfor i := range completedParts {\n\t i := int64(i)\n\t\tgo func() {\n\t\t\tlimiter <- struct{}{}\n\t\t\tfirstByte := i * d.MultipartCopyChunkSize\n\t\t\tlastByte := firstByte + d.MultipartCopyChunkSize - 1\n\t\t\tif lastByte >= fileInfo.Size() {\n\t\t\t\tlastByte = fileInfo.Size() - 1\n\t\t\t}\n\n\t\t\tuploadOutput, err := d.Client.CopyPart(&obs.CopyPartInput{\n\t\t\t\tBucket: d.Bucket,\n\t\t\t\tKey: d.obsPath(destPath),\n UploadId: initOutput.UploadId,\n PartNumber: int(i + 1),\n CopySourceBucket: d.Bucket,\n\t\t\t\tCopySourceKey: d.obsPath(sourcePath),\n\t\t\t\tCopySourceRangeStart: firstByte,\n CopySourceRangeEnd: lastByte,\n\t\t\t})\n\t\t\tif err == nil {\n\t\t\t\tcompletedParts[i] = obs.Part{\n\t\t\t\t\tETag: uploadOutput.ETag,\n\t\t\t\t\tPartNumber: int(i + 1),\n\t\t\t\t}\n\t\t\t}\n\t\t\terrChan <- err\n\t\t\t<-limiter\n\t\t}()\n\t}\n\tfor range completedParts {\n\t\terr := <-errChan\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t}\n\t_, err = d.Client.CompleteMultipartUpload(&obs.CompleteMultipartUploadInput{\n\t\tBucket: d.Bucket,\n\t\tKey: d.obsPath(destPath),\n\t\tUploadId: initOutput.UploadId,\n\t\tParts: completedParts,\n\t})\n\treturn err\n}", "func CopyBufferSubData(readTarget uint32, writeTarget uint32, readOffset int, writeOffset int, size int) {\n C.glowCopyBufferSubData(gpCopyBufferSubData, (C.GLenum)(readTarget), (C.GLenum)(writeTarget), (C.GLintptr)(readOffset), (C.GLintptr)(writeOffset), (C.GLsizeiptr)(size))\n}", "func (s *storageCeph) copyWithSnapshots(sourceVolumeName string,\n\ttargetVolumeName string, sourceParentSnapshot string) error {\n\tlogger.Debugf(`Creating non-sparse copy of RBD storage volume \"%s to \"%s\"`, sourceVolumeName, targetVolumeName)\n\n\targs := []string{\n\t\t\"export-diff\",\n\t\t\"--id\", s.UserName,\n\t\t\"--cluster\", s.ClusterName,\n\t\tsourceVolumeName,\n\t}\n\n\tif sourceParentSnapshot != \"\" {\n\t\targs = append(args, \"--from-snap\", sourceParentSnapshot)\n\t}\n\n\t// redirect output to stdout\n\targs = append(args, \"-\")\n\n\trbdSendCmd := exec.Command(\"rbd\", args...)\n\trbdRecvCmd := exec.Command(\n\t\t\"rbd\",\n\t\t\"--id\", s.UserName,\n\t\t\"import-diff\",\n\t\t\"--cluster\", s.ClusterName,\n\t\t\"-\",\n\t\ttargetVolumeName)\n\n\trbdRecvCmd.Stdin, _ = rbdSendCmd.StdoutPipe()\n\trbdRecvCmd.Stdout = os.Stdout\n\trbdRecvCmd.Stderr = os.Stderr\n\n\terr := rbdRecvCmd.Start()\n\tif err != nil {\n\t\treturn err\n\t}\n\n\terr = rbdSendCmd.Run()\n\tif err != nil {\n\t\treturn err\n\t}\n\n\terr = rbdRecvCmd.Wait()\n\tif err != nil {\n\t\treturn err\n\t}\n\n\tlogger.Debugf(`Created non-sparse copy of RBD storage volume \"%s\" to \"%s\"`, sourceVolumeName, targetVolumeName)\n\treturn nil\n}", "func CopyImageSubDataNV(hSrcRC unsafe.Pointer, srcName uint32, srcTarget uint32, srcLevel int32, srcX int32, srcY int32, srcZ int32, hDstRC unsafe.Pointer, dstName uint32, dstTarget uint32, dstLevel int32, dstX int32, dstY int32, dstZ int32, width int32, height int32, depth int32) unsafe.Pointer {\n\tpanic(\"\\\"CopyImageSubDataNV\\\" is not implemented\")\n}", "func (m *InMemoryRepository) Copy(source, destination fyne.URI) error {\n\treturn repository.GenericCopy(source, destination)\n}", "func (self *GameObjectCreator) BitmapData2O(width int, height int) *BitmapData{\n return &BitmapData{self.Object.Call(\"bitmapData\", width, height)}\n}", "func (driver *S3Driver) Copy(dst io.Writer, src io.Reader) (written int64, err error) {\r\n\treturn copyBuffer(dst, src, nil)\r\n}", "func cephRBDVolumeCopy(clusterName string, oldVolumeName string,\n\tnewVolumeName string, userName string) error {\n\t_, err := shared.RunCommand(\n\t\t\"rbd\",\n\t\t\"--id\", userName,\n\t\t\"--cluster\", clusterName,\n\t\t\"cp\",\n\t\toldVolumeName,\n\t\tnewVolumeName)\n\tif err != nil {\n\t\treturn err\n\t}\n\n\treturn nil\n}", "func deepcopy(dst, src interface{}) error {\n\tr, w, err := os.Pipe()\n\tif err != nil {\n\t\treturn err\n\t}\n\tenc := gob.NewEncoder(w)\n\terr = enc.Encode(src)\n\tif err != nil {\n\t\treturn err\n\t}\n\tdec := gob.NewDecoder(r)\n\treturn dec.Decode(dst)\n}", "func copy(w io.WriteCloser, r io.Reader) {\n\tdefer w.Close()\n\tio.Copy(w, r)\n}", "func (this *BytesPool) Copy(dst io.Writer, src io.Reader) (nwrote int64, err error) {\n\tbb := this.Get()\n\tnwrote, err = io.CopyBuffer(dst, src, bb)\n\tthis.Put(bb)\n\treturn\n}", "func (w *windowImpl) Copy(dp image.Point, src screen.Texture, sr image.Rectangle, op draw.Op, opts *screen.DrawOptions) {\n\tpanic(\"not implemented\") // TODO: Implement\n}", "func SwitchData(x, y gb.UINT8, src, dst []gb.UINT8) {}", "func Copy(i ImageIr) ImageIr {\n\tc := make([][][]uint32, len(i.pixels))\n\tcopy(c, i.pixels)\n\treturn ImageIr{i.width, i.height, c}\n}", "func genericCopyVolume(d Driver, initVolume func(vol Volume) (func(), error), vol Volume, srcVol Volume, srcSnapshots []Volume, refresh bool, op *operations.Operation) error {\n\tif vol.contentType != srcVol.contentType {\n\t\treturn fmt.Errorf(\"Content type of source and target must be the same\")\n\t}\n\n\tbwlimit := d.Config()[\"rsync.bwlimit\"]\n\n\trevert := revert.New()\n\tdefer revert.Fail()\n\n\t// Create the main volume if not refreshing.\n\tif !refresh {\n\t\terr := d.CreateVolume(vol, nil, op)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\n\t\trevert.Add(func() { d.DeleteVolume(vol, op) })\n\t}\n\n\t// Ensure the volume is mounted.\n\terr := vol.MountTask(func(mountPath string, op *operations.Operation) error {\n\t\t// If copying snapshots is indicated, check the source isn't itself a snapshot.\n\t\tif len(srcSnapshots) > 0 && !srcVol.IsSnapshot() {\n\t\t\tfor _, srcSnapshot := range srcSnapshots {\n\t\t\t\t_, snapName, _ := shared.InstanceGetParentAndSnapshotName(srcSnapshot.name)\n\n\t\t\t\t// Mount the source snapshot.\n\t\t\t\terr := srcSnapshot.MountTask(func(srcMountPath string, op *operations.Operation) error {\n\t\t\t\t\t// Copy the snapshot.\n\t\t\t\t\t_, err := rsync.LocalCopy(srcMountPath, mountPath, bwlimit, true)\n\t\t\t\t\tif err != nil {\n\t\t\t\t\t\treturn err\n\t\t\t\t\t}\n\n\t\t\t\t\tif srcSnapshot.IsVMBlock() {\n\t\t\t\t\t\tsrcDevPath, err := d.GetVolumeDiskPath(srcSnapshot)\n\t\t\t\t\t\tif err != nil {\n\t\t\t\t\t\t\treturn err\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\ttargetDevPath, err := d.GetVolumeDiskPath(vol)\n\t\t\t\t\t\tif err != nil {\n\t\t\t\t\t\t\treturn err\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\terr = copyDevice(srcDevPath, targetDevPath)\n\t\t\t\t\t\tif err != nil {\n\t\t\t\t\t\t\treturn err\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\n\t\t\t\t\treturn nil\n\t\t\t\t}, op)\n\t\t\t\tif err != nil {\n\t\t\t\t\treturn err\n\t\t\t\t}\n\n\t\t\t\tfullSnapName := GetSnapshotVolumeName(vol.name, snapName)\n\t\t\t\tsnapVol := NewVolume(d, d.Name(), vol.volType, vol.contentType, fullSnapName, vol.config, vol.poolConfig)\n\n\t\t\t\t// Create the snapshot itself.\n\t\t\t\terr = d.CreateVolumeSnapshot(snapVol, op)\n\t\t\t\tif err != nil {\n\t\t\t\t\treturn err\n\t\t\t\t}\n\n\t\t\t\t// Setup the revert.\n\t\t\t\trevert.Add(func() {\n\t\t\t\t\td.DeleteVolumeSnapshot(snapVol, op)\n\t\t\t\t})\n\t\t\t}\n\t\t}\n\n\t\t// Run volume-specific init logic.\n\t\tif initVolume != nil {\n\t\t\t_, err := initVolume(vol)\n\t\t\tif err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\t\t}\n\n\t\t// Copy source to destination (mounting each volume if needed).\n\t\terr := srcVol.MountTask(func(srcMountPath string, op *operations.Operation) error {\n\t\t\t_, err := rsync.LocalCopy(srcMountPath, mountPath, bwlimit, true)\n\t\t\tif err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\n\t\t\tif srcVol.IsVMBlock() {\n\t\t\t\tsrcDevPath, err := d.GetVolumeDiskPath(srcVol)\n\t\t\t\tif err != nil {\n\t\t\t\t\treturn err\n\t\t\t\t}\n\n\t\t\t\ttargetDevPath, err := d.GetVolumeDiskPath(vol)\n\t\t\t\tif err != nil {\n\t\t\t\t\treturn err\n\t\t\t\t}\n\n\t\t\t\terr = copyDevice(srcDevPath, targetDevPath)\n\t\t\t\tif err != nil {\n\t\t\t\t\treturn err\n\t\t\t\t}\n\t\t\t}\n\n\t\t\treturn nil\n\t\t}, op)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\n\t\t// Run EnsureMountPath after mounting and copying to ensure the mounted directory has the\n\t\t// correct permissions set.\n\t\terr = vol.EnsureMountPath()\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\n\t\treturn nil\n\t}, op)\n\tif err != nil {\n\t\treturn err\n\t}\n\n\trevert.Success()\n\treturn nil\n}", "func CopyObject(srcData []byte, dst interface{}) {\n\tjsoniter.Unmarshal(srcData, dst)\n\t//var dstData, err = jsoniter.Marshal(dst)\n\t//if err != nil {\n\t//\tpanic(err)\n\t//}\n\t//fmt.Println(\"overlay:\", string(dstData))\n}", "func (b *Executor) copyExistingImage(ctx context.Context, cacheID string) error {\n\t// Get the destination Image Reference\n\tdest, err := b.resolveNameToImageRef()\n\tif err != nil {\n\t\treturn err\n\t}\n\n\tpolicyContext, err := util.GetPolicyContext(b.systemContext)\n\tif err != nil {\n\t\treturn err\n\t}\n\tdefer policyContext.Destroy()\n\n\t// Look up the source image, expecting it to be in local storage\n\tsrc, err := is.Transport.ParseStoreReference(b.store, cacheID)\n\tif err != nil {\n\t\treturn errors.Wrapf(err, \"error getting source imageReference for %q\", cacheID)\n\t}\n\tif _, err := cp.Image(ctx, policyContext, dest, src, nil); err != nil {\n\t\treturn errors.Wrapf(err, \"error copying image %q\", cacheID)\n\t}\n\tb.log(\"COMMIT %s\", b.output)\n\treturn nil\n}", "func CopyTexImage2D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, height int32, border int32) {\n\tsyscall.Syscall9(gpCopyTexImage2D, 8, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(x), uintptr(y), uintptr(width), uintptr(height), uintptr(border), 0)\n}", "func CopyInstance(uuid dvid.UUID, source, target dvid.InstanceName, c dvid.Config) error {\n\tif manager == nil {\n\t\treturn ErrManagerNotInitialized\n\t}\n\n\tif source == \"\" || target == \"\" {\n\t\treturn fmt.Errorf(\"both source and cloned name must be provided\")\n\t}\n\n\t// Get any filter spec\n\tfstxt, found, err := c.GetString(\"filter\")\n\tif err != nil {\n\t\treturn err\n\t}\n\tvar fs storage.FilterSpec\n\tif found {\n\t\tfs = storage.FilterSpec(fstxt)\n\t}\n\n\t// Get flatten or not\n\ttransmit, found, err := c.GetString(\"transmit\")\n\tif err != nil {\n\t\treturn err\n\t}\n\tvar flatten bool\n\tif transmit == \"flatten\" {\n\t\tflatten = true\n\t}\n\n\t// Get the source data instance.\n\td1, err := manager.getDataByUUIDName(uuid, source)\n\tif err != nil {\n\t\treturn err\n\t}\n\n\t// Create the target instance.\n\tt, err := TypeServiceByName(d1.TypeName())\n\tif err != nil {\n\t\treturn err\n\t}\n\td2, err := manager.newData(uuid, t, target, c)\n\tif err != nil {\n\t\treturn err\n\t}\n\n\t// Populate the new data instance properties from source.\n\tcopier, ok := d2.(PropertyCopier)\n\tif ok {\n\t\tif err := copier.CopyPropertiesFrom(d1, fs); err != nil {\n\t\t\treturn err\n\t\t}\n\t\tif err := SaveDataByUUID(uuid, d2); err != nil {\n\t\t\treturn err\n\t\t}\n\t}\n\n\t// We should be able to get the backing store (only ordered kv for now)\n\toldKV, err := GetOrderedKeyValueDB(d1)\n\tif err != nil {\n\t\treturn fmt.Errorf(\"unable to get backing store for data %q: %v\", d1.DataName(), err)\n\t}\n\tnewKV, err := GetOrderedKeyValueDB(d2)\n\tif err != nil {\n\t\treturn fmt.Errorf(\"unable to get backing store for data %q: %v\", d2.DataName(), err)\n\t}\n\n\tdvid.Infof(\"Copying data %q (%s) to data %q (%s)...\\n\", d1.DataName(), oldKV, d2.DataName(), newKV)\n\n\t// See if this data instance implements a Send filter.\n\tvar filter storage.Filter\n\tfilterer, ok := d1.(storage.Filterer)\n\tif ok && fs != \"\" {\n\t\tvar err error\n\t\tfilter, err = filterer.NewFilter(fs)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t}\n\n\t// copy data with optional datatype-specific filtering.\n\treturn copyData(oldKV, newKV, d1, d2, uuid, filter, flatten)\n}", "func Copy(dst, src interface{}) error {\n\tbuffer := new(bytes.Buffer)\n\tencoder := gob.NewEncoder(buffer)\n\tif err := encoder.Encode(src); err != nil {\n\t\treturn err\n\t}\n\tdecoder := gob.NewDecoder(buffer)\n\terr := decoder.Decode(dst)\n\treturn err\n}", "func blend(source string, container string, mix string, debug bool) error {\n\tlog.Println(\"Mixing\", source, \"and\", container, \"into\", mix)\n\tsourcef, err := os.Open(source)\n\tif err != nil {\n\t\treturn err\n\t}\n\tdefer sourcef.Close()\n\tbh, dh, err := canBeBlended(source, container, debug)\n\tif err != nil {\n\t\treturn err\n\t}\n\tcontainerf, err := os.Open(container)\n\tif err != nil {\n\t\treturn err\n\t}\n\tdefer containerf.Close()\n\t// skip the 54 bytes headers\n\tn, err := containerf.Seek(54, 0)\n\tif err != nil || n != 54 {\n\t\treturn errors.New(\"Cannot seek correctly\")\n\t}\n\n\trowLenInBits := dh.width * uint32(dh.bitspp)\n\tif rowLenInBits%32 != 0 {\n\t\trowLenInBits = rowLenInBits + (32 - rowLenInBits%32)\n\t}\n\trowLenInBytes := rowLenInBits / 8\n\n\tmixf, err := os.Create(mix)\n\tif err != nil {\n\t\treturn err\n\t}\n\tdefer mixf.Close()\n\t_, err = mixf.Write(bh.byteMe())\n\tif err != nil {\n\t\treturn err\n\t}\n\t_, err = mixf.Write(dh.byteMe())\n\tif err != nil {\n\t\treturn err\n\t}\n\t//_, err = mixf.Write(middle)\n\t//if err != nil {\n\t//\treturn err\n\t//}\n\trow := make([]byte, rowLenInBytes)\n\tbrow := make([]byte, rowLenInBytes/4)\n\tfor i := uint32(0); i < dh.height; i++ {\n\t\tn, err := containerf.Read(row)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tif n != int(rowLenInBytes) {\n\t\t\treturn errors.New(\"Error reading source row\")\n\t\t}\n\t\tbn, berr := sourcef.Read(brow)\n\t\tif berr != nil && berr != io.EOF {\n\t\t\treturn berr\n\t\t}\n\t\tfor bi := 0; bi < bn; bi++ {\n\t\t\tdiffuse := brow[bi]\n\t\t\tif bi == 0 && i == 0 && debug {\n\t\t\t\tlog.Printf(\"Diffusing %02X in [%02X%02X%02X%02X]\", diffuse, row[bi*4+0], row[bi*4+1], row[bi*4+2], row[bi*4+3])\n\t\t\t}\n\t\t\tfor b := 0; b <= 3; b++ {\n\t\t\t\trow[bi*4+b] &= 0XFC\n\t\t\t\trow[bi*4+b] |= diffuse & 3\n\t\t\t\t//log.Printf(\"Diffusing bits %02X\", (diffuse & 3))\n\t\t\t\tdiffuse = diffuse >> 2\n\t\t\t}\n\t\t\tif bi == 0 && i == 0 && debug {\n\t\t\t\tlog.Printf(\"Diffused %02X in [%02X%02X%02X%02X]\", brow[bi], row[bi*4+0], row[bi*4+1], row[bi*4+2], row[bi*4+3])\n\t\t\t}\n\t\t}\n\t\t_, err = mixf.Write(row)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t}\n\treturn nil\n}", "func copyMemory(dest unsafe.Pointer, src unsafe.Pointer, length uint32) {\n\tprocCopyMemory.Call(uintptr(dest), uintptr(src), uintptr(length))\n}", "func copyData(oldKV, newKV storage.OrderedKeyValueDB, d1, d2 dvid.Data, uuid dvid.UUID, f storage.Filter, flatten bool) error {\n\t// Get data context for this UUID.\n\tv, err := VersionFromUUID(uuid)\n\tif err != nil {\n\t\treturn err\n\t}\n\tsrcCtx := NewVersionedCtx(d1, v)\n\tvar dstCtx *VersionedCtx\n\tif d2 == nil {\n\t\td2 = d1\n\t\tdstCtx = srcCtx\n\t} else {\n\t\tdstCtx = NewVersionedCtx(d2, v)\n\t}\n\n\t// Send this instance's key-value pairs\n\tvar wg sync.WaitGroup\n\twg.Add(1)\n\n\tstats := new(txStats)\n\tstats.lastTime = time.Now()\n\tstats.name = fmt.Sprintf(\"copy of %s\", d1.DataName())\n\n\tvar kvTotal, kvSent int\n\tvar bytesTotal, bytesSent uint64\n\tkeysOnly := false\n\tif flatten {\n\t\t// Start goroutine to receive flattened key-value pairs and store them.\n\t\tch := make(chan *storage.TKeyValue, 1000)\n\t\tgo func() {\n\t\t\tfor {\n\t\t\t\ttkv := <-ch\n\t\t\t\tif tkv == nil {\n\t\t\t\t\twg.Done()\n\t\t\t\t\tdvid.Infof(\"Copied %d %q key-value pairs (%s, out of %d kv pairs, %s) [flattened]\\n\",\n\t\t\t\t\t\tkvSent, d1.DataName(), humanize.Bytes(bytesSent), kvTotal, humanize.Bytes(bytesTotal))\n\t\t\t\t\tstats.printStats()\n\t\t\t\t\treturn\n\t\t\t\t}\n\t\t\t\tkvTotal++\n\t\t\t\tcurBytes := uint64(len(tkv.V) + len(tkv.K))\n\t\t\t\tbytesTotal += curBytes\n\t\t\t\tif f != nil {\n\t\t\t\t\tskip, err := f.Check(tkv)\n\t\t\t\t\tif err != nil {\n\t\t\t\t\t\tdvid.Errorf(\"problem applying filter on data %q: %v\\n\", d1.DataName(), err)\n\t\t\t\t\t\tcontinue\n\t\t\t\t\t}\n\t\t\t\t\tif skip {\n\t\t\t\t\t\tcontinue\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tkvSent++\n\t\t\t\tbytesSent += curBytes\n\t\t\t\tif err := newKV.Put(dstCtx, tkv.K, tkv.V); err != nil {\n\t\t\t\t\tdvid.Errorf(\"can't put k/v pair to destination instance %q: %v\\n\", d2.DataName(), err)\n\t\t\t\t}\n\t\t\t\tstats.addKV(tkv.K, tkv.V)\n\t\t\t}\n\t\t}()\n\n\t\tbegKey, endKey := srcCtx.TKeyRange()\n\t\terr := oldKV.ProcessRange(srcCtx, begKey, endKey, &storage.ChunkOp{}, func(c *storage.Chunk) error {\n\t\t\tif c == nil {\n\t\t\t\treturn fmt.Errorf(\"received nil chunk in flatten push for data %s\", d1.DataName())\n\t\t\t}\n\t\t\tch <- c.TKeyValue\n\t\t\treturn nil\n\t\t})\n\t\tch <- nil\n\t\tif err != nil {\n\t\t\treturn fmt.Errorf(\"error in flatten push for data %q: %v\", d1.DataName(), err)\n\t\t}\n\t} else {\n\t\t// Start goroutine to receive all key-value pairs and store them.\n\t\tch := make(chan *storage.KeyValue, 1000)\n\t\tgo func() {\n\t\t\tfor {\n\t\t\t\tkv := <-ch\n\t\t\t\tif kv == nil {\n\t\t\t\t\twg.Done()\n\t\t\t\t\tdvid.Infof(\"Sent %d %q key-value pairs (%s, out of %d kv pairs, %s)\\n\",\n\t\t\t\t\t\tkvSent, d1.DataName(), humanize.Bytes(bytesSent), kvTotal, humanize.Bytes(bytesTotal))\n\t\t\t\t\tstats.printStats()\n\t\t\t\t\treturn\n\t\t\t\t}\n\t\t\t\ttkey, err := storage.TKeyFromKey(kv.K)\n\t\t\t\tif err != nil {\n\t\t\t\t\tdvid.Errorf(\"couldn't get %q TKey from Key %v: %v\\n\", d1.DataName(), kv.K, err)\n\t\t\t\t\tcontinue\n\t\t\t\t}\n\n\t\t\t\tkvTotal++\n\t\t\t\tcurBytes := uint64(len(kv.V) + len(kv.K))\n\t\t\t\tbytesTotal += curBytes\n\t\t\t\tif f != nil {\n\t\t\t\t\tskip, err := f.Check(&storage.TKeyValue{K: tkey, V: kv.V})\n\t\t\t\t\tif err != nil {\n\t\t\t\t\t\tdvid.Errorf(\"problem applying filter on data %q: %v\\n\", d1.DataName(), err)\n\t\t\t\t\t\tcontinue\n\t\t\t\t\t}\n\t\t\t\t\tif skip {\n\t\t\t\t\t\tcontinue\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tkvSent++\n\t\t\t\tbytesSent += curBytes\n\t\t\t\tif dstCtx != nil {\n\t\t\t\t\terr := dstCtx.UpdateInstance(kv.K)\n\t\t\t\t\tif err != nil {\n\t\t\t\t\t\tdvid.Errorf(\"can't update raw key to new data instance %q: %v\\n\", d2.DataName(), err)\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tif err := newKV.RawPut(kv.K, kv.V); err != nil {\n\t\t\t\t\tdvid.Errorf(\"can't put k/v pair to destination instance %q: %v\\n\", d2.DataName(), err)\n\t\t\t\t}\n\t\t\t\tstats.addKV(kv.K, kv.V)\n\t\t\t}\n\t\t}()\n\n\t\tbegKey, endKey := srcCtx.KeyRange()\n\t\tif err = oldKV.RawRangeQuery(begKey, endKey, keysOnly, ch, nil); err != nil {\n\t\t\treturn fmt.Errorf(\"push voxels %q range query: %v\", d1.DataName(), err)\n\t\t}\n\t}\n\twg.Wait()\n\treturn nil\n}", "func copyDiskImage(dst, src string) (err error) {\n\t// Open source disk image\n\tsrcImg, err := os.Open(src)\n\tif err != nil {\n\t\treturn err\n\t}\n\tdefer func() {\n\t\tif ee := srcImg.Close(); ee != nil {\n\t\t\terr = ee\n\t\t}\n\t}()\n\tdstImg, err := os.Create(dst)\n\tif err != nil {\n\t\treturn err\n\t}\n\tdefer func() {\n\t\tif ee := dstImg.Close(); ee != nil {\n\t\t\terr = ee\n\t\t}\n\t}()\n\t_, err = io.Copy(dstImg, srcImg)\n\treturn err\n}", "func CopyBufferSubData(readTarget uint32, writeTarget uint32, readOffset int, writeOffset int, size int) {\n\tsyscall.Syscall6(gpCopyBufferSubData, 5, uintptr(readTarget), uintptr(writeTarget), uintptr(readOffset), uintptr(writeOffset), uintptr(size), 0)\n}", "func newBitmapFrom(other *bitmap, size int) *bitmap {\n\tbitmap := newBitmap(size)\n\n\tif size > other.Size {\n\t\tsize = other.Size\n\t}\n\n\tdiv := size / 8\n\n\tfor i := 0; i < div; i++ {\n\t\tbitmap.data[i] = other.data[i]\n\t}\n\n\tfor i := div * 8; i < size; i++ {\n\t\tif other.Bit(i) == 1 {\n\t\t\tbitmap.Set(i)\n\t\t}\n\t}\n\n\treturn bitmap\n}", "func copyData(dbCfg *config.DbManager, srvCfg *config.Server) error {\n\tappName := dbCfg.ApplicationName\n\tsrcSt := dbCfg.SrcStartTime.Truncate(resolution)\n\tdstSt := dbCfg.DstStartTime.Truncate(resolution)\n\tdstEt := dbCfg.DstEndTime.Truncate(resolution)\n\tsrcEt := srcSt.Add(dstEt.Sub(dstSt))\n\n\tfmt.Printf(\"copying %s from %s-%s to %s-%s\\n\",\n\t\tappName,\n\t\tsrcSt.String(),\n\t\tsrcEt.String(),\n\t\tdstSt.String(),\n\t\tdstEt.String(),\n\t)\n\n\t// TODO: add more correctness checks\n\tif !srcSt.Before(srcEt) || !dstSt.Before(dstEt) {\n\t\treturn fmt.Errorf(\"Incorrect time parameters. Start time has to be before end time. \"+\n\t\t\t\"src start: %q end: %q, dst start: %q end: %q\", srcSt, srcEt, dstSt, dstEt)\n\t}\n\n\ts, err := storage.New(srvCfg)\n\tif err != nil {\n\t\treturn err\n\t}\n\n\tif dbCfg.EnableProfiling {\n\t\tupstream := direct.New(s)\n\t\tselfProfilingConfig := &agent.SessionConfig{\n\t\t\tUpstream: upstream,\n\t\t\tAppName: \"pyroscope.dbmanager.cpu{}\",\n\t\t\tProfilingTypes: types.DefaultProfileTypes,\n\t\t\tSpyName: types.GoSpy,\n\t\t\tSampleRate: 100,\n\t\t\tUploadRate: 10 * time.Second,\n\t\t}\n\t\tsession := agent.NewSession(selfProfilingConfig, logrus.StandardLogger())\n\t\tupstream.Start()\n\t\t_ = session.Start()\n\t}\n\n\tsk, err := storage.ParseKey(appName)\n\tif err != nil {\n\t\treturn err\n\t}\n\n\tcount := int(srcEt.Sub(srcSt) / (resolution))\n\tbar := pb.StartNew(count)\n\n\tdurDiff := dstSt.Sub(srcSt)\n\n\tsigc := make(chan os.Signal, 1)\n\tsignal.Notify(sigc, syscall.SIGINT, syscall.SIGTERM)\n\n\tfor srct := srcSt; srct.Before(srcEt); srct = srct.Add(resolution) {\n\t\tbar.Increment()\n\t\tselect {\n\t\tcase <-sigc:\n\t\t\tbreak\n\t\tdefault:\n\t\t}\n\n\t\tsrct2 := srct.Add(resolution)\n\t\tgOut, err := s.Get(&storage.GetInput{\n\t\t\tStartTime: srct,\n\t\t\tEndTime: srct2,\n\t\t\tKey: sk,\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\n\t\tif gOut.Tree != nil {\n\t\t\tdstt := srct.Add(durDiff)\n\t\t\tdstt2 := dstt.Add(resolution)\n\n\t\t\terr = s.Put(&storage.PutInput{\n\t\t\t\tStartTime: dstt,\n\t\t\t\tEndTime: dstt2,\n\t\t\t\tKey: sk,\n\t\t\t\tVal: gOut.Tree,\n\t\t\t\tSpyName: gOut.SpyName,\n\t\t\t\tSampleRate: gOut.SampleRate,\n\t\t\t\tUnits: gOut.Units,\n\t\t\t})\n\t\t\tif err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\t\t}\n\t}\n\n\tbar.Finish()\n\treturn s.Close()\n}", "func sampleImageAndCompare(img *image.RGBA, bounds image.Rectangle) (*image.RGBA, bool) {\n\ttmpImage, err := screenshot.CaptureRect(bounds)\n\tif err != nil {\n\t\tpanic(err)\n\t}\n\t// Calculate hashes and image sizes.\n\thashA, imgSizeA := images.Hash(img)\n\thashB, imgSizeB := images.Hash(tmpImage)\n\n\t// Image comparison.\n\tif images.Similar(hashA, hashB, imgSizeA, imgSizeB) {\n\t\treturn tmpImage, true\n\t}\n\n\treturn tmpImage, false\n}", "func (b *XMobileBackend) PutImageData(img *image.RGBA, x, y int) {\n\tb.activate()\n\n\tb.glctx.ActiveTexture(gl.TEXTURE0)\n\tif b.imageBufTex.Value == 0 {\n\t\tb.imageBufTex = b.glctx.CreateTexture()\n\t\tb.glctx.BindTexture(gl.TEXTURE_2D, b.imageBufTex)\n\t\tb.glctx.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.LINEAR)\n\t\tb.glctx.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, gl.LINEAR)\n\t\tb.glctx.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_S, gl.CLAMP_TO_EDGE)\n\t\tb.glctx.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_T, gl.CLAMP_TO_EDGE)\n\t} else {\n\t\tb.glctx.BindTexture(gl.TEXTURE_2D, b.imageBufTex)\n\t}\n\n\tw, h := img.Bounds().Dx(), img.Bounds().Dy()\n\n\tif img.Stride == img.Bounds().Dx()*4 {\n\t\tb.glctx.TexImage2D(gl.TEXTURE_2D, 0, gl.RGBA, w, h, gl.RGBA, gl.UNSIGNED_BYTE, img.Pix[0:])\n\t} else {\n\t\tdata := make([]uint8, 0, w*h*4)\n\t\tfor cy := 0; cy < h; cy++ {\n\t\t\tstart := cy * img.Stride\n\t\t\tend := start + w*4\n\t\t\tdata = append(data, img.Pix[start:end]...)\n\t\t}\n\t\tb.glctx.TexImage2D(gl.TEXTURE_2D, 0, gl.RGBA, w, h, gl.RGBA, gl.UNSIGNED_BYTE, data[0:])\n\t}\n\n\tdx, dy := float32(x), float32(y)\n\tdw, dh := float32(w), float32(h)\n\n\tb.glctx.BindBuffer(gl.ARRAY_BUFFER, b.buf)\n\tdata := [16]float32{dx, dy, dx + dw, dy, dx + dw, dy + dh, dx, dy + dh,\n\t\t0, 0, 1, 0, 1, 1, 0, 1}\n\tb.glctx.BufferData(gl.ARRAY_BUFFER, byteSlice(unsafe.Pointer(&data[0]), len(data)*4), gl.STREAM_DRAW)\n\n\tb.glctx.UseProgram(b.shd.ID)\n\tb.glctx.Uniform1i(b.shd.Image, 0)\n\tb.glctx.Uniform2f(b.shd.CanvasSize, float32(b.fw), float32(b.fh))\n\tb.glctx.UniformMatrix3fv(b.shd.Matrix, mat3identity[:])\n\tb.glctx.Uniform1f(b.shd.GlobalAlpha, 1)\n\tb.glctx.Uniform1i(b.shd.UseAlphaTex, 0)\n\tb.glctx.Uniform1i(b.shd.Func, shdFuncImage)\n\tb.glctx.VertexAttribPointer(b.shd.Vertex, 2, gl.FLOAT, false, 0, 0)\n\tb.glctx.VertexAttribPointer(b.shd.TexCoord, 2, gl.FLOAT, false, 0, 8*4)\n\tb.glctx.EnableVertexAttribArray(b.shd.Vertex)\n\tb.glctx.EnableVertexAttribArray(b.shd.TexCoord)\n\tb.glctx.DrawArrays(gl.TRIANGLE_FAN, 0, 4)\n\tb.glctx.DisableVertexAttribArray(b.shd.Vertex)\n\tb.glctx.DisableVertexAttribArray(b.shd.TexCoord)\n}", "func (f *FileUtil) copy(src, dst string) {\n\tsrc = FixPath(src)\n\tdst = FixPath(dst)\n\tif f.Verbose {\n\t\tfmt.Println(\"Copying\", src, \"to\", dst)\n\t}\n\t_, err := f.dbx.Copy(files.NewRelocationArg(src, dst))\n\tif err != nil {\n\t\tpanic(err)\n\t}\n}", "func execute(proc *caire.Processor) {\n\tvar err error\n\tproc.Spinner = spinner\n\n\t// Supported files\n\tvalidExtensions := []string{\".jpg\", \".png\", \".jpeg\", \".bmp\", \".gif\"}\n\n\t// Check if source path is a local image or URL.\n\tif utils.IsValidUrl(*source) {\n\t\tsrc, err := utils.DownloadImage(*source)\n\t\tif src != nil {\n\t\t\tdefer os.Remove(src.Name())\n\t\t}\n\t\tdefer src.Close()\n\t\tif err != nil {\n\t\t\tlog.Fatalf(\n\t\t\t\tutils.DecorateText(\"Failed to load the source image: %v\", utils.ErrorMessage),\n\t\t\t\tutils.DecorateText(err.Error(), utils.DefaultMessage),\n\t\t\t)\n\t\t}\n\t\tfs, err = src.Stat()\n\t\tif err != nil {\n\t\t\tlog.Fatalf(\n\t\t\t\tutils.DecorateText(\"Failed to load the source image: %v\", utils.ErrorMessage),\n\t\t\t\tutils.DecorateText(err.Error(), utils.DefaultMessage),\n\t\t\t)\n\t\t}\n\t\timg, err := os.Open(src.Name())\n\t\tif err != nil {\n\t\t\tlog.Fatalf(\n\t\t\t\tutils.DecorateText(\"Unable to open the temporary image file: %v\", utils.ErrorMessage),\n\t\t\t\tutils.DecorateText(err.Error(), utils.DefaultMessage),\n\t\t\t)\n\t\t}\n\t\timgfile = img\n\t} else {\n\t\t// Check if the source is a pipe name or a regular file.\n\t\tif *source == pipeName {\n\t\t\tfs, err = os.Stdin.Stat()\n\t\t} else {\n\t\t\tfs, err = os.Stat(*source)\n\t\t}\n\t\tif err != nil {\n\t\t\tlog.Fatalf(\n\t\t\t\tutils.DecorateText(\"Failed to load the source image: %v\", utils.ErrorMessage),\n\t\t\t\tutils.DecorateText(err.Error(), utils.DefaultMessage),\n\t\t\t)\n\t\t}\n\t}\n\n\tnow := time.Now()\n\n\tswitch mode := fs.Mode(); {\n\tcase mode.IsDir():\n\t\tvar wg sync.WaitGroup\n\t\t// Read destination file or directory.\n\t\t_, err := os.Stat(*destination)\n\t\tif err != nil {\n\t\t\terr = os.Mkdir(*destination, 0755)\n\t\t\tif err != nil {\n\t\t\t\tlog.Fatalf(\n\t\t\t\t\tutils.DecorateText(\"Unable to get dir stats: %v\\n\", utils.ErrorMessage),\n\t\t\t\t\tutils.DecorateText(err.Error(), utils.DefaultMessage),\n\t\t\t\t)\n\t\t\t}\n\t\t}\n\t\tproc.Preview = false\n\n\t\t// Limit the concurrently running workers to maxWorkers.\n\t\tif *workers <= 0 || *workers > maxWorkers {\n\t\t\t*workers = runtime.NumCPU()\n\t\t}\n\n\t\t// Process recursively the image files from the specified directory concurrently.\n\t\tch := make(chan result)\n\t\tdone := make(chan interface{})\n\t\tdefer close(done)\n\n\t\tpaths, errc := walkDir(done, *source, validExtensions)\n\n\t\twg.Add(*workers)\n\t\tfor i := 0; i < *workers; i++ {\n\t\t\tgo func() {\n\t\t\t\tdefer wg.Done()\n\t\t\t\tconsumer(done, paths, *destination, proc, ch)\n\t\t\t}()\n\t\t}\n\n\t\t// Close the channel after the values are consumed.\n\t\tgo func() {\n\t\t\tdefer close(ch)\n\t\t\twg.Wait()\n\t\t}()\n\n\t\t// Consume the channel values.\n\t\tfor res := range ch {\n\t\t\tif res.err != nil {\n\t\t\t\terr = res.err\n\t\t\t}\n\t\t\tprintStatus(res.path, err)\n\t\t}\n\n\t\tif err = <-errc; err != nil {\n\t\t\tfmt.Fprintf(os.Stderr, utils.DecorateText(err.Error(), utils.ErrorMessage))\n\t\t}\n\n\tcase mode.IsRegular() || mode&os.ModeNamedPipe != 0: // check for regular files or pipe names\n\t\text := filepath.Ext(*destination)\n\t\tif !isValidExtension(ext, validExtensions) && *destination != pipeName {\n\t\t\tlog.Fatalf(utils.DecorateText(fmt.Sprintf(\"%v file type not supported\", ext), utils.ErrorMessage))\n\t\t}\n\n\t\terr = processor(*source, *destination, proc)\n\t\tprintStatus(*destination, err)\n\t}\n\tif err == nil {\n\t\tfmt.Fprintf(os.Stderr, \"\\nExecution time: %s\\n\", utils.DecorateText(fmt.Sprintf(\"%s\", utils.FormatTime(time.Since(now))), utils.SuccessMessage))\n\t}\n}", "func (i *ImageBuf) CopyMetadata(src *ImageBuf) error {\n\tC.ImageBuf_copy_metadata(i.ptr, src.ptr)\n\truntime.KeepAlive(i)\n\truntime.KeepAlive(src)\n\treturn i.LastError()\n}", "func CopyProperties(src interface{}, dst interface{}) {\n\tsrcData, err := jsoniter.Marshal(src)\n\tif err != nil {\n\t\tpanic(err)\n\t}\n\tjsoniter.Unmarshal(srcData, dst)\n\n\t//dstData, err := jsoniter.Marshal(dst)\n\t//if err != nil {\n\t//\tpanic(err)\n\t//}\n\t//fmt.Println(\"overlay:\", string(dstData))\n}", "func (b *Executor) Copy(excludes []string, copies ...imagebuilder.Copy) error {\n\tfor _, copy := range copies {\n\t\tlogrus.Debugf(\"COPY %#v, %#v\", excludes, copy)\n\t\tif err := b.volumeCacheInvalidate(copy.Dest); err != nil {\n\t\t\treturn err\n\t\t}\n\t\tsources := []string{}\n\t\tfor _, src := range copy.Src {\n\t\t\tif strings.HasPrefix(src, \"http://\") || strings.HasPrefix(src, \"https://\") {\n\t\t\t\tsources = append(sources, src)\n\t\t\t} else if len(copy.From) > 0 {\n\t\t\t\tif other, ok := b.named[copy.From]; ok && other.index < b.index {\n\t\t\t\t\tsources = append(sources, filepath.Join(other.mountPoint, src))\n\t\t\t\t} else {\n\t\t\t\t\treturn errors.Errorf(\"the stage %q has not been built\", copy.From)\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\tsources = append(sources, filepath.Join(b.contextDir, src))\n\t\t\t}\n\t\t}\n\n\t\toptions := buildah.AddAndCopyOptions{\n\t\t\tChown: copy.Chown,\n\t\t}\n\n\t\tif err := b.builder.Add(copy.Dest, copy.Download, options, sources...); err != nil {\n\t\t\treturn err\n\t\t}\n\t}\n\treturn nil\n}", "func (s *storageCeph) copyWithoutSnapshotsFull(target instance.Instance, source instance.Instance) error {\n\tlogger.Debugf(`Creating non-sparse copy of RBD storage volume for container \"%s\" to \"%s\" without snapshots`, source.Name(), target.Name())\n\n\tsourceIsSnapshot := source.IsSnapshot()\n\tsourceContainerName := project.Prefix(source.Project(), source.Name())\n\ttargetContainerName := project.Prefix(target.Project(), target.Name())\n\toldVolumeName := fmt.Sprintf(\"%s/container_%s\", s.OSDPoolName,\n\t\tsourceContainerName)\n\tnewVolumeName := fmt.Sprintf(\"%s/container_%s\", s.OSDPoolName,\n\t\ttargetContainerName)\n\tif sourceIsSnapshot {\n\t\tsourceContainerOnlyName, sourceSnapshotOnlyName, _ :=\n\t\t\tshared.InstanceGetParentAndSnapshotName(sourceContainerName)\n\t\toldVolumeName = fmt.Sprintf(\"%s/container_%s@snapshot_%s\",\n\t\t\ts.OSDPoolName, sourceContainerOnlyName,\n\t\t\tsourceSnapshotOnlyName)\n\t}\n\n\terr := cephRBDVolumeCopy(s.ClusterName, oldVolumeName, newVolumeName,\n\t\ts.UserName)\n\tif err != nil {\n\t\tlogger.Debugf(`Failed to create full RBD copy \"%s\" to \"%s\": %s`, source.Name(), target.Name(), err)\n\t\treturn err\n\t}\n\n\t_, err = cephRBDVolumeMap(s.ClusterName, s.OSDPoolName, targetContainerName,\n\t\tstoragePoolVolumeTypeNameContainer, s.UserName)\n\tif err != nil {\n\t\tlogger.Errorf(`Failed to map RBD storage volume for image \"%s\" on storage pool \"%s\": %s`, targetContainerName, s.pool.Name, err)\n\t\treturn err\n\t}\n\n\t// Re-generate the UUID\n\terr = s.cephRBDGenerateUUID(project.Prefix(target.Project(), target.Name()), storagePoolVolumeTypeNameContainer)\n\tif err != nil {\n\t\treturn err\n\t}\n\n\t// Create mountpoint\n\ttargetContainerMountPoint := driver.GetContainerMountPoint(target.Project(), s.pool.Name, target.Name())\n\terr = driver.CreateContainerMountpoint(targetContainerMountPoint, target.Path(), target.IsPrivileged())\n\tif err != nil {\n\t\treturn err\n\t}\n\n\tourMount, err := target.StorageStart()\n\tif err != nil {\n\t\treturn err\n\t}\n\tif ourMount {\n\t\tdefer target.StorageStop()\n\t}\n\n\terr = target.DeferTemplateApply(\"copy\")\n\tif err != nil {\n\t\tlogger.Errorf(`Failed to apply copy template for container \"%s\": %s`, target.Name(), err)\n\t\treturn err\n\t}\n\tlogger.Debugf(`Applied copy template for container \"%s\"`, target.Name())\n\n\tlogger.Debugf(`Created non-sparse copy of RBD storage volume for container \"%s\" to \"%s\" without snapshots`, source.Name(),\n\t\ttarget.Name())\n\treturn nil\n}", "func CopyBufferSubData(readTarget uint32, writeTarget uint32, readOffset int, writeOffset int, size int) {\n\tC.glowCopyBufferSubData(gpCopyBufferSubData, (C.GLenum)(readTarget), (C.GLenum)(writeTarget), (C.GLintptr)(readOffset), (C.GLintptr)(writeOffset), (C.GLsizeiptr)(size))\n}", "func CopyBufferSubData(readTarget uint32, writeTarget uint32, readOffset int, writeOffset int, size int) {\n\tC.glowCopyBufferSubData(gpCopyBufferSubData, (C.GLenum)(readTarget), (C.GLenum)(writeTarget), (C.GLintptr)(readOffset), (C.GLintptr)(writeOffset), (C.GLsizeiptr)(size))\n}", "func (c *CancellableCopier) Copy(ctx context.Context) (nLhs, nRhs int, err error) {\n\n\tbufsz := c.IOBufsize\n\tif bufsz <= 0 {\n\t\tbufsz = 16384\n\t}\n\n\tif c.ReadTimeout <= 0 {\n\t\tc.ReadTimeout = 10 // seconds\n\t}\n\n\tif c.WriteTimeout <= 0 {\n\t\tc.WriteTimeout = 15 // seconds\n\t}\n\n\t// have to wait until both go-routines are done.\n\tvar wg sync.WaitGroup\n\n\t// this channel tells us when both go-routines have terminated.\n\t// It's a proxy for wg.Wait(); necessary since we will wait on\n\t// another channel (ctx.Done()) concurrently with this.\n\tch := make(chan bool)\n\n\twg.Add(2)\n\tgo func() {\n\t\twg.Wait()\n\t\tclose(ch)\n\t}()\n\n\tb0 := make([]byte, bufsz)\n\tb1 := make([]byte, bufsz)\n\n\t// copy #1\n\tgo func() {\n\t\tdefer wg.Done()\n\t\t_, nLhs, _ = c.copyBuf(c.LeftConn, c.RightConn, b0)\n\t}()\n\n\t// copy #2\n\tgo func() {\n\t\tdefer wg.Done()\n\t\t_, nRhs, _ = c.copyBuf(c.RightConn, c.LeftConn, b1)\n\t}()\n\n\t// Wait for parent to kill us or the copy routines to end.\n\t// If parent kills us, we wait for copy-routines to end as well.\n\tselect {\n\tcase <-ctx.Done():\n\t\t// close the sockets and force the i/o loop in copybuf to end.\n\t\tc.LeftConn.Close()\n\t\tc.RightConn.Close()\n\t\t<-ch\n\n\tcase <-ch:\n\t}\n\n\terr = nil\n\treturn\n}", "func readImage(p Params, c distributorChannels)[][]byte {\n\tnewWorld := make([][]byte, p.ImageHeight)\n\tfor i := range newWorld {\n\t\tnewWorld[i] = make([]byte, p.ImageWidth)\n\t}\n\n\t// Request the io goroutine to read in the image with the given filename.\n\tc.ioCommand <- ioInput\n\tfilename := fmt.Sprintf(\"%dx%d\",p.ImageHeight,p.ImageWidth)\n\tc.ioFilename <- filename\n\t// The io goroutine sends the requested image byte by byte, in rows.\n\tfor y := 0; y < p.ImageHeight; y++ {\n\t\tfor x := 0; x < p.ImageWidth; x++ {\n\t\t\tval := <-c.ioInput\n\t\t\tif val != 0 {\n\t\t\t\tnewWorld[y][x] = val\n\t\t\t}\n\t\t}\n\t}\n\t//fmt.Println(newWorld)\n\t//World = newWorld\n\treturn newWorld\n}", "func copyObj(f fs.Fs, dst fs.Object, remote string, src fs.Object) (newDst fs.Object, err error) {\n\tif operations.NeedTransfer(context.TODO(), dst, src) {\n\t\tnewDst, err = operations.Copy(context.TODO(), f, dst, remote, src)\n\t} else {\n\t\tnewDst = dst\n\t}\n\treturn newDst, err\n}", "func Copy(dst Writer, src Reader) (written int64, err error)", "func CopyData(fileToCopy string,fileFromCopy string) error{\n\n\tfileOrigin,_:=os.Open(fileFromCopy)\n\tdefer fileOrigin.Close()\n\n\tnewFile,err:=os.Create(fileToCopy)\n\tif err!=nil{\n\t\treturn err\n\t}\n\tdefer newFile.Close()\n\tbytesWritten,err:=io.Copy(newFile,fileOrigin)\n\tif err!=nil{\n\t\treturn err\n\t}\n\tfmt.Printf(\"Copied %d bytes.\\n\", bytesWritten)\n\terr = newFile.Sync()\n\tif err!=nil{\n\t\treturn err\n\t}\n\treturn nil\n}", "func PMOVZXBWm64byte(X1 []byte, X2 []byte)", "func copyIfNeeded(bd *netBuf, b []byte) []byte {\n\tif bd.pool == -1 && sameUnderlyingStorage(b, bd.buf) {\n\t\treturn b\n\t}\n\tn := make([]byte, len(b))\n\tcopy(n, b)\n\treturn n\n}", "func bidirCopyAndClose(t *testing.T, ctx context.Context, wg *sync.WaitGroup, c1, c2 io.ReadWriteCloser) {\n\tdefer wg.Done()\n\tgo closeWhenDone(ctx, c1)\n\tgo closeWhenDone(ctx, c2)\n\tdefer c1.Close()\n\tdefer c2.Close()\n\n\terrc := make(chan error, 2)\n\tgo func() {\n\t\t_, err := io.Copy(c1, c2)\n\t\terrc <- err\n\t}()\n\tgo func() {\n\t\t_, err := io.Copy(c2, c1)\n\t\terrc <- err\n\t}()\n\tif err := <-errc; err != nil && err != io.EOF && !isDone(ctx) {\n\t\tt.Errorf(\"copy error: %v\", err)\n\t}\n}", "func processImageBimg(logger log.Logger, filePath, srcDir, dstDir string, smallerTile bool, resize, width, height int) error {\n\tbuffer, err := bimg.Read(filePath)\n\tif err != nil {\n\t\tfmt.Fprintln(os.Stderr, err)\n\t}\n\timg := bimg.NewImage(buffer)\n\tif err != nil {\n\t\treturn fmt.Errorf(\"can't open image %s %v\", filePath, err)\n\t}\n\tsize, err := img.Size()\n\tif err != nil {\n\t\treturn fmt.Errorf(\"can't read sizego image %s %v\", filePath, err)\n\t}\n\n\tif resize > 1 {\n\t\tbuffer, err = img.Resize(size.Width/resize, size.Height/resize)\n\t\tif err != nil {\n\t\t\treturn fmt.Errorf(\"can't resize image %s %v\", filePath, err)\n\t\t}\n\t\timg = bimg.NewImage(buffer)\n\n\t\tsize, err = img.Size()\n\t\tif err != nil {\n\t\t\treturn fmt.Errorf(\"can't read resized image %s %v\", filePath, err)\n\t\t}\n\n\t\tlevel.Debug(logger).Log(\n\t\t\t\"msg\", \"resizing image\",\n\t\t\t\"sizex\", size.Width,\n\t\t\t\"sizey\", size.Height,\n\t\t\t\"src_path\", filePath,\n\t\t)\n\t}\n\n\t// generate tiles starting from the center\n\tif size.Width < width || size.Height < height {\n\t\treturn fmt.Errorf(\"too small to be tilled %s\", filePath)\n\t}\n\n\tcount := 0\n\n\t// start at the top left\n\tvar xpos, ypos int\n\n\t// find how many tiles we need\n\t// we want the tile a c if we have enough material (at least x/2)\n\t// we want the tile d e if we have enough material (at least y/2)\n\t// a | b | c\n\t// d | e | f\n\n\t// a line is the number of slice + the extra half overlap\n\tvar modx, mody int\n\n\t// do we allow repetition in tiles ?\n\tif smallerTile {\n\t\tmodx = size.Width % width\n\t\tmody = size.Height % height\n\t}\n\n\tneedx := size.Width / width\n\tneedy := size.Height / height\n\n\tif modx > width/2 {\n\t\tneedx += 2\n\t}\n\n\tif mody > height/2 {\n\t\tneedy += 2\n\t}\n\n\t// descending loop\n\tfor cuty := 0; cuty < needy; cuty++ {\n\t\tif mody < height/2 {\n\t\t\typos = cuty*height + mody/2\n\t\t} else {\n\t\t\typos = (cuty-1)*height + mody/2\n\t\t\tif cuty == 0 {\n\t\t\t\typos = 0\n\t\t\t}\n\t\t\tif cuty == needy-1 {\n\t\t\t\typos = size.Height - height\n\t\t\t}\n\t\t}\n\n\t\t// save an horizontal slice\n\t\tfor cutx := 0; cutx < needx; cutx++ {\n\t\t\tif modx < width/2 {\n\t\t\t\txpos = cutx*width + modx/2\n\t\t\t} else {\n\t\t\t\txpos = (cutx-1)*width + modx/2\n\t\t\t\tif cutx == 0 {\n\t\t\t\t\txpos = 0\n\t\t\t\t}\n\t\t\t\tif cutx == needx-1 {\n\t\t\t\t\txpos = size.Width - width\n\t\t\t\t}\n\t\t\t}\n\n\t\t\text := path.Ext(filePath)\n\t\t\twpath := filePath[:len(filePath)-len(ext)]\n\t\t\twpath = wpath[len(srcDir):]\n\t\t\toutFilename := fmt.Sprintf(\"%s-%d%s\", wpath, count, ext)\n\t\t\toutFilePath := filepath.Join(dstDir, outFilename)\n\n\t\t\tlevel.Debug(logger).Log(\n\t\t\t\t\"msg\", \"cropping image\",\n\t\t\t\t\"count\", count,\n\t\t\t\t\"modx\", modx,\n\t\t\t\t\"mody\", mody,\n\t\t\t\t\"needx\", needx,\n\t\t\t\t\"needy\", needy,\n\t\t\t\t\"xpos\", xpos,\n\t\t\t\t\"ypos\", ypos,\n\t\t\t\t\"cutx\", cutx,\n\t\t\t\t\"cuty\", cuty,\n\t\t\t\t\"width\", width,\n\t\t\t\t\"height\", height,\n\t\t\t\t\"sizex\", size.Width,\n\t\t\t\t\"sizey\", size.Height,\n\t\t\t\t\"file_path\", filePath,\n\t\t\t\t\"src_dir\", srcDir,\n\t\t\t\t\"dst_dir\", dstDir,\n\t\t\t\t\"out_file_path\", outFilePath,\n\t\t\t)\n\n\t\t\tcrop := bimg.NewImage(buffer)\n\t\t\tcropb, err := crop.Extract(ypos, xpos, width, height)\n\t\t\tif err != nil {\n\t\t\t\treturn fmt.Errorf(\"can't crop image %s %v\", filePath, err)\n\t\t\t}\n\n\t\t\terr = bimg.Write(outFilePath, cropb)\n\t\t\tif err != nil {\n\t\t\t\treturn fmt.Errorf(\"can't save image %s %v\", outFilePath, err)\n\t\t\t}\n\t\t\tatomic.AddUint64(&tileCounter, 1)\n\t\t\tcount++\n\t\t}\n\t}\n\n\treturn nil\n}", "func (a *ActiveDevice) Copy(m MetaContext, src *ActiveDevice) error {\n\n\t// Take a consistent snapshot of the src device. Be careful not to hold\n\t// locks on both devices at once.\n\tsrc.Lock()\n\tuv := src.uv\n\tdeviceID := src.deviceID\n\tsigKey := src.signingKey\n\tencKey := src.encryptionKey\n\tname := src.deviceName\n\tctime := src.deviceCtime\n\tkeychainMode := src.keychainMode\n\tsrc.Unlock()\n\n\treturn a.Set(m, uv, deviceID, sigKey, encKey, name, ctime, keychainMode)\n}", "func (b *BaseImpl) Copy(src Base, srcOff, size, dstOff, extend int) {\n\n\t// src, ok := osrc.(*BaseImpl)\n\t// if !ok {\n\t// \tlog.Log(LOG_WARN, log.Printf(\"BaseImpl.Copy() src is only BaseImpl\"))\n\n\t// \treturn\n\t// }\n\n\tif len(b.bytes) > dstOff {\n\t\tdiff := Diff{Offset: dstOff, bytes: b.bytes[dstOff:]}\n\t\tb.Diffs = append(b.Diffs, diff)\n\t\t//b.bytes = b.bytes[:dstOff]\n\t}\n\n\tfor i, diff := range b.Diffs {\n\t\tif diff.Offset >= dstOff {\n\t\t\tdiff.Offset += extend\n\t\t}\n\t\tb.Diffs[i] = diff\n\t}\n\n\tif len(src.R(0)) > srcOff {\n\t\tnSize := len(src.R(0)[srcOff:])\n\t\tif nSize > size {\n\t\t\tnSize = size\n\t\t}\n\n\t\tdiff := Diff{Offset: dstOff, bytes: src.R(0)[srcOff : srcOff+nSize]}\n\t\tb.Diffs = append(b.Diffs, diff)\n\t}\n\tfor _, diff := range src.GetDiffs() {\n\t\tif diff.Offset >= srcOff {\n\t\t\tnDiff := diff\n\t\t\tnDiff.Offset -= srcOff\n\t\t\tnDiff.Offset += dstOff\n\t\t\tb.Diffs = append(b.Diffs, nDiff)\n\t\t}\n\t}\n\treturn\n}", "func copyChart(ctx context.Context, conn *ssh.Conn, chartLocalPath, chartHostDir string) error {\n\tchartHostPath := filepath.Join(chartHostDir, filepath.Base(chartLocalPath))\n\tif _, err := linuxssh.PutFiles(\n\t\tctx, conn, map[string]string{chartLocalPath: chartHostPath}, linuxssh.DereferenceSymlinks); err != nil {\n\t\treturn errors.Wrapf(err, \"failed to send chart file in path %v to chart tablet\", chartLocalPath)\n\t}\n\treturn nil\n}", "func (t *translator) copyBytes(\n\tirBlock *ir.Block, irPtr, irLen irvalue.Value,\n) irvalue.Value {\n\tirNewPtr := irBlock.NewCall(t.builtins.Malloc(t), irLen)\n\tirBlock.NewCall(t.builtins.Memcpy(t), irNewPtr, irPtr, irLen, irconstant.False)\n\treturn irNewPtr\n}", "func doCopyNode(ctx context.Context, src content.ReadOnlyStorage, dst content.Storage, desc ocispec.Descriptor) error {\n\trc, err := src.Fetch(ctx, desc)\n\tif err != nil {\n\t\treturn err\n\t}\n\tdefer rc.Close()\n\terr = dst.Push(ctx, desc, rc)\n\tif err != nil && !errors.Is(err, errdef.ErrAlreadyExists) {\n\t\treturn err\n\t}\n\treturn nil\n}", "func TestCopyRedownload(t *testing.T) {\n\tctx := context.Background()\n\tr := fstest.NewRun(t)\n\tfile1 := r.WriteObject(ctx, \"sub dir/hello world\", \"hello world\", t1)\n\tr.CheckRemoteItems(t, file1)\n\n\terr := CopyDir(ctx, r.Flocal, r.Fremote, false)\n\trequire.NoError(t, err)\n\n\t// Test with combined precision of local and remote as we copied it there and back\n\tr.CheckLocalListing(t, []fstest.Item{file1}, nil)\n}", "func (ac *AmiCopyImpl) Copy(ui *packer.Ui) (err error) {\n\tif err = ac.input.Validate(); err != nil {\n\t\treturn err\n\t}\n\n\tif ac.output, err = ac.EC2.CopyImage(ac.input); err != nil {\n\t\treturn err\n\t}\n\n\tif err = ac.Tag(); err != nil {\n\t\treturn err\n\t}\n\n\tif ac.EnsureAvailable {\n\t\t(*ui).Say(\"Going to wait for image to be in available state\")\n\t\tfor i := 1; i <= 30; i++ {\n\t\t\timage, err := LocateSingleAMI(*ac.output.ImageId, ac.EC2)\n\t\t\tif err != nil && image == nil {\n\t\t\t\treturn err\n\t\t\t}\n\t\t\tif *image.State == ec2.ImageStateAvailable {\n\t\t\t\treturn nil\n\t\t\t}\n\t\t\t(*ui).Say(fmt.Sprintf(\"Waiting one minute (%d/30) for AMI to become available, current state: %s for image %s on account %s\", i, *image.State, *image.ImageId, ac.targetAccountID))\n\t\t\ttime.Sleep(time.Duration(1) * time.Minute)\n\t\t}\n\t\treturn fmt.Errorf(\"Timed out waiting for image %s to copy to account %s\", *ac.output.ImageId, ac.targetAccountID)\n\t}\n\n\treturn nil\n}", "func multiThreadCopy(ctx context.Context, f fs.Fs, remote string, src fs.Object, streams int, tr *accounting.Transfer) (newDst fs.Object, err error) {\n\topenWriterAt := f.Features().OpenWriterAt\n\tif openWriterAt == nil {\n\t\treturn nil, errors.New(\"multi-thread copy: OpenWriterAt not supported\")\n\t}\n\tif src.Size() < 0 {\n\t\treturn nil, errors.New(\"multi-thread copy: can't copy unknown sized file\")\n\t}\n\tif src.Size() == 0 {\n\t\treturn nil, errors.New(\"multi-thread copy: can't copy zero sized file\")\n\t}\n\n\tg, gCtx := errgroup.WithContext(ctx)\n\tmc := &multiThreadCopyState{\n\t\tctx: gCtx,\n\t\tsize: src.Size(),\n\t\tsrc: src,\n\t\tstreams: streams,\n\t}\n\tmc.calculateChunks()\n\n\t// Make accounting\n\tmc.acc = tr.Account(ctx, nil)\n\n\t// create write file handle\n\tmc.wc, err = openWriterAt(gCtx, remote, mc.size)\n\tif err != nil {\n\t\treturn nil, fmt.Errorf(\"multipart copy: failed to open destination: %w\", err)\n\t}\n\n\tfs.Debugf(src, \"Starting multi-thread copy with %d parts of size %v\", mc.streams, fs.SizeSuffix(mc.partSize))\n\tfor stream := 0; stream < mc.streams; stream++ {\n\t\tstream := stream\n\t\tg.Go(func() (err error) {\n\t\t\treturn mc.copyStream(gCtx, stream)\n\t\t})\n\t}\n\terr = g.Wait()\n\tcloseErr := mc.wc.Close()\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\tif closeErr != nil {\n\t\treturn nil, fmt.Errorf(\"multi-thread copy: failed to close object after copy: %w\", closeErr)\n\t}\n\n\tobj, err := f.NewObject(ctx, remote)\n\tif err != nil {\n\t\treturn nil, fmt.Errorf(\"multi-thread copy: failed to find object after copy: %w\", err)\n\t}\n\n\terr = obj.SetModTime(ctx, src.ModTime(ctx))\n\tswitch err {\n\tcase nil, fs.ErrorCantSetModTime, fs.ErrorCantSetModTimeWithoutDelete:\n\tdefault:\n\t\treturn nil, fmt.Errorf(\"multi-thread copy: failed to set modification time: %w\", err)\n\t}\n\n\tfs.Debugf(src, \"Finished multi-thread copy with %d parts of size %v\", mc.streams, fs.SizeSuffix(mc.partSize))\n\treturn obj, nil\n}", "func (ros RealOS) Copy(src, dst string) error {\n\tif !ros.Exists(src) {\n\t\treturn errors.New(src + \" does not exist in file system\")\n\t} else if ros.IsDirectory(src) {\n\t\treturn errors.New(src + \" is a directory\")\n\t}\n\tif ros.Exists(dst) {\n\t\treturn errors.New(dst + \" already exists in file system\")\n\t}\n\tin, err := os.Open(src)\n\tif err != nil {\n\t\treturn err\n\t}\n\tdefer in.Close()\n\n\tout, err := os.Create(dst)\n\tif err != nil {\n\t\treturn err\n\t}\n\tdefer out.Close()\n\n\t_, err = io.Copy(out, in)\n\tif err != nil {\n\t\treturn err\n\t}\n\n\terr = out.Sync()\n\tif err != nil {\n\t\treturn err\n\t}\n\n\tcerr := out.Close()\n\treturn cerr\n}", "func (gc gcsClient) Copy(ctx context.Context, from, to Path) (*storage.ObjectAttrs, error) {\n\tclient := gc.clientFromPath(from)\n\treturn client.Copy(ctx, from, to)\n}", "func copyBuffer(dst io.Writer, src io.Reader, buf []byte) (written int64, err error) {\r\n\t// If the reader has a WriteTo method, use it to do the copy.\r\n\t// Avoids an allocation and a copy.\r\n\t// if wt, ok := src.(io.WriterTo); ok {\r\n\t// \treturn wt.WriteTo(dst)\r\n\t// }\r\n\r\n\t// Similarly, if the writer has a ReadFrom method, use it to do the copy.\r\n\t// if rt, ok := dst.(io.ReaderFrom); ok {\r\n\t// \treturn rt.ReadFrom(src)\r\n\t// }\r\n\r\n\tif buf == nil {\r\n\t\tbuf = make([]byte, 32*1024)\r\n\t\t//buf = make([]byte, 5*1024*1024)\r\n\t}\r\n\r\n\tfor {\r\n\t\tnr, er := src.Read(buf)\r\n\t\tif nr > 0 {\r\n\t\t\tnw, ew := dst.Write(buf[0:nr])\r\n\t\t\tif nw > 0 {\r\n\t\t\t\twritten += int64(nw)\r\n\t\t\t}\r\n\t\t\tif ew != nil {\r\n\t\t\t\terr = ew\r\n\t\t\t\tbreak\r\n\t\t\t}\r\n\t\t\tif nr != nw {\r\n\t\t\t\terr = io.ErrShortWrite\r\n\t\t\t\tbreak\r\n\t\t\t}\r\n\t\t}\r\n\t\tif er == io.EOF {\r\n\t\t\tbreak\r\n\t\t}\r\n\t\tif er != nil {\r\n\t\t\terr = er\r\n\t\t\tbreak\r\n\t\t}\r\n\t}\r\n\treturn written, err\r\n}", "func MergeImageMap(target ComponentImageMap, source ComponentImageMap) {\n\tfor key := range source {\n\t\tif _, ok := target[key]; !ok {\n\t\t\t// we have the same image in both maps\n\t\t\t// TODO\n\t\t\ttmpComponentImage := ComponentImage{Image: source[key].Image, Components: source[key].Components}\n\n\t\t\t// join both maps\n\t\t\tfor component := range target[key].Components {\n\t\t\t\ttmpComponentImage.Components[component] = true\n\t\t\t}\n\n\t\t\ttarget[key] = tmpComponentImage\n\t\t}\n\t}\n}", "func copyBytes(dst, src []byte) int {\n\tif len(dst) != len(src) {\n\t\tpanic(fmt.Sprintf(\"copyBytes called with differing lengths %d and %d\", len(dst), len(src)))\n\t}\n\treturn copy(dst, src)\n}", "func image0(img image.Image) (Data, error) {\n\tbytes, mime, err := encodePng(img)\n\tif err != nil {\n\t\treturn Data{}, err\n\t}\n\treturn Data{\n\t\tData: BundledMIMEData{\n\t\t\tmime: bytes,\n\t\t},\n\t\tMetadata: BundledMIMEData{\n\t\t\tmime: imageMetadata(img),\n\t\t},\n\t}, nil\n}", "func copyContentsLocked(ctx context.Context, upper *Inode, lower *Inode, size int64) error {\n\t// We don't support copying up for anything other than regular files.\n\tif lower.StableAttr.Type != RegularFile {\n\t\treturn nil\n\t}\n\n\t// Get a handle to the upper filesystem, which we will write to.\n\tupperFile, err := overlayFile(ctx, upper, FileFlags{Write: true})\n\tif err != nil {\n\t\treturn err\n\t}\n\tdefer upperFile.DecRef()\n\n\t// Get a handle to the lower filesystem, which we will read from.\n\tlowerFile, err := overlayFile(ctx, lower, FileFlags{Read: true})\n\tif err != nil {\n\t\treturn err\n\t}\n\tdefer lowerFile.DecRef()\n\n\t// Use a buffer pool to minimize allocations.\n\tbuf := copyUpBuffers.Get().([]byte)\n\tdefer copyUpBuffers.Put(buf)\n\n\t// Transfer the contents.\n\t//\n\t// One might be able to optimize this by doing parallel reads, parallel writes and reads, larger\n\t// buffers, etc. But we really don't know anything about the underlying implementation, so these\n\t// optimizations could be self-defeating. So we leave this as simple as possible.\n\tvar offset int64\n\tfor {\n\t\tnr, err := lowerFile.FileOperations.Read(ctx, lowerFile, usermem.BytesIOSequence(buf), offset)\n\t\tif err != nil && err != io.EOF {\n\t\t\treturn err\n\t\t}\n\t\tif nr == 0 {\n\t\t\tif offset != size {\n\t\t\t\t// Same as in cleanupUpper, we cannot live\n\t\t\t\t// with ourselves if we do anything less.\n\t\t\t\tpanic(fmt.Sprintf(\"filesystem is in an inconsistent state: wrote only %d bytes of %d sized file\", offset, size))\n\t\t\t}\n\t\t\treturn nil\n\t\t}\n\t\tnw, err := upperFile.FileOperations.Write(ctx, upperFile, usermem.BytesIOSequence(buf[:nr]), offset)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\toffset += nw\n\t}\n}", "func (u *UFlat) CopyAndPut2(path, key string) (\n\twritten int64, hash string, err error) {\n\n\t// the temporary file MUST be created on the same device\n\t// xxx POSSIBLE RACE CONDITION\n\ttmpFileName := filepath.Join(u.tmpDir, u.rng.NextFileName(16))\n\tfound, err := xf.PathExists(tmpFileName)\n\tfor found {\n\t\ttmpFileName = filepath.Join(u.tmpDir, u.rng.NextFileName(16))\n\t\tfound, err = xf.PathExists(tmpFileName)\n\t}\n\twritten, err = CopyFile(tmpFileName, path) // dest <== src\n\tif err == nil {\n\t\twritten, hash, err = u.Put2(tmpFileName, key)\n\t}\n\treturn\n}", "func Copy(src, dst string, parallel int, bufferSize float64, skipErrorFiles bool) error {\n\tsrcPrefix, srcPath := utils.SplitInTwo(src, \"://\")\n\tdstPrefix, dstPath := utils.SplitInTwo(dst, \"://\")\n\n\terr := TestImplementationsExist(srcPrefix, dstPrefix)\n\tif err != nil {\n\t\treturn err\n\t}\n\tsrcClient, dstClient, err := GetClients(srcPrefix, dstPrefix, srcPath, dstPath)\n\tif err != nil {\n\t\treturn err\n\t}\n\tfromToPaths, err := GetFromToPaths(srcClient, srcPrefix, srcPath, dstPath)\n\tif err != nil {\n\t\treturn err\n\t}\n\terr = PerformCopy(srcClient, dstClient, srcPrefix, dstPrefix, fromToPaths, parallel, bufferSize, skipErrorFiles)\n\tif err != nil {\n\t\treturn err\n\t}\n\n\treturn nil\n}", "func TestReadPixelsFromVolatileImage(t *testing.T) {\n\tconst w, h = 16, 16\n\tdst := restorable.NewImage(w, h, restorable.ImageTypeVolatile)\n\tsrc := restorable.NewImage(w, h, restorable.ImageTypeRegular)\n\n\t// First, make sure that dst has pixels\n\tdst.WritePixels(make([]byte, 4*w*h), image.Rect(0, 0, w, h))\n\n\t// Second, draw src to dst. If the implementation is correct, dst becomes stale.\n\tpix := make([]byte, 4*w*h)\n\tfor i := range pix {\n\t\tpix[i] = 0xff\n\t}\n\tsrc.WritePixels(pix, image.Rect(0, 0, w, h))\n\tvs := quadVertices(1, 1, 0, 0)\n\tis := graphics.QuadIndices()\n\tdr := graphicsdriver.Region{\n\t\tX: 0,\n\t\tY: 0,\n\t\tWidth: w,\n\t\tHeight: h,\n\t}\n\tdst.DrawTriangles([graphics.ShaderImageCount]*restorable.Image{src}, vs, is, graphicsdriver.BlendCopy, dr, [graphics.ShaderImageCount]graphicsdriver.Region{}, restorable.NearestFilterShader, nil, false)\n\n\t// Read the pixels. If the implementation is correct, dst tries to read its pixels from GPU due to being\n\t// stale.\n\twant := byte(0xff)\n\n\tvar result [4]byte\n\tif err := dst.ReadPixels(ui.GraphicsDriverForTesting(), result[:], image.Rect(0, 0, 1, 1)); err != nil {\n\t\tt.Fatal(err)\n\t}\n\tgot := result[0]\n\tif got != want {\n\t\tt.Errorf(\"got: %v, want: %v\", got, want)\n\t}\n}", "func (bg *bufferedGroup) pushImage(nearestCityKey string, gr *geoindex.GeographicRecord) {\n // If the current image and the last-added image both have the same\n // location, curry that time-key to this image (since they are the same\n // model and location and will now have the same time-key, they'll be\n // grouped together).\n lastBi := bg.images[len(bg.images)-1]\n\n // Before we push our current image to the back of the buffer, force the\n // time-key of the current image to be inherited from the current-last image\n // (soon to be an adjacent images) if it's the same city.\n\n var effectiveTimekey time.Time\n if lastBi.nearestCityKey == nearestCityKey {\n effectiveTimekey = bg.lastTimeKey\n gr.AddComment(fmt.Sprintf(\"Inheriting time-key [%s] of previous record with same city [%s]: [%s] (%.6f, %.6f)\", effectiveTimekey, nearestCityKey, path.Base(lastBi.gr.Filepath), lastBi.gr.Latitude, lastBi.gr.Longitude))\n } else {\n gr.AddComment(fmt.Sprintf(\"Left-adjacent image in buffer is [%s] with different city [%s] at coordinates (%.6f, %.6f) and time-key [%v]\", path.Base(lastBi.gr.Filepath), lastBi.nearestCityKey, lastBi.gr.Latitude, lastBi.gr.Longitude, bg.lastTimeKey))\n }\n\n // Now, append.\n\n bi := newBufferedImage(nearestCityKey, gr, effectiveTimekey)\n\n bg.images = append(bg.images, bi)\n currentTimekey := bi.effectiveTimekey\n\n // Set this before we return in preparation for the next cycle.\n bg.lastTimeKey = currentTimekey\n\n // This uniquely identifies the current visit to the city. This will help\n // us smooth aberrations in the middle.\n locationTimekey := bi.LocationTimekey()\n\n len_ := len(bg.images)\n\n // If our city has already appeared within the current time interval, smooth\n // all of the cities of the images between then and now (which is the last\n // item in the slice) to be the same city. This could easily be caused by\n // just turning around on a walk and/or otherwise backtracking and entering\n // another city near the pivot point within the resolution of the time-key\n // interval.\n if index, found := bg.locationIndex[locationTimekey]; found == true && len_ > 2 {\n firstEncounteredBi := bg.images[index]\n\n // Sanity check.\n // TODO(dustin): !! Just while debugging.\n if firstEncounteredBi.nearestCityKey != nearestCityKey || firstEncounteredBi.effectiveTimekey != currentTimekey {\n log.Panicf(\"first encountered index of location-timekey was not recorded right: expected [%s] [%v] rather than [%s] [%v]\", nearestCityKey, currentTimekey, firstEncounteredBi.nearestCityKey, firstEncounteredBi.effectiveTimekey)\n }\n\n // Only update if the item before the item we just added is a different\n // city (but still within the same time-key of our new image. By.\n // Otherwise, we'll just update and reupdate all of the adjacent images\n // that we add that we already know to have the same city.\n previousBi := bg.images[len_-2]\n if previousBi.nearestCityKey != nearestCityKey && previousBi.effectiveTimekey == currentTimekey {\n start_index := index + 1\n n := len(bg.images) - start_index\n\n for i, bi := range bg.images[start_index:] {\n // Sanity check.\n // TODO(dustin): !! Just while debugging.\n if bi.effectiveTimekey != currentTimekey {\n log.Panicf(\"current BI during smoothing is no longer the same time-key: [%v] != [%s]\", bi.effectiveTimekey, currentTimekey)\n }\n\n if bi.nearestCityKey != nearestCityKey {\n // The amount of time elapsed between this image and the first\n // image we encountered at the same city and time-key.\n timeSinceAberration := bi.gr.Timestamp.Sub(firstEncounteredBi.gr.Timestamp)\n\n bi.gr.AddComment(fmt.Sprintf(\"Smoothed image <time-key [%v] timestamp [%v] city [%s] file [%s]> to city [%s] (from just-pushed image <time-key [%v] timestamp [%v] city [%s] file [%s]>). TIME-BETWEEN=[%s] STEP=(%d/%d)\", bi.effectiveTimekey, bi.gr.Timestamp, bi.nearestCityKey, path.Base(bi.gr.Filepath), nearestCityKey, currentTimekey, gr.Timestamp, nearestCityKey, path.Base(gr.Filepath), timeSinceAberration, i+1, n))\n bi.nearestCityKey = nearestCityKey\n }\n }\n\n bg.updateLocationIndex()\n }\n } else if found == false {\n bg.locationIndex[locationTimekey] = len(bg.images) - 1\n }\n}", "func genericCopy(ctx *context) (written int64, myerr error) {\n\t// var files []os.FileInfo\n\tfiles, err := getFiles(ctx)\n\tif err != nil {\n\t\treturn 0, err\n\t}\n\tbytes, err := fixedCopy(ctx, files)\n\tif *ctx.verbose {\n\t\telapsedtime := ctx.endtime.Sub(ctx.starttime)\n\t\tseconds := int64(elapsedtime.Seconds())\n\t\tif seconds == 0 {\n\t\t\tseconds = 1\n\t\t}\n\t\tcolor.Set(color.FgYellow)\n\t\tfmt.Printf(\"**END** (%v)\\n REPORT:\\n - Elapsed time: %v\\n - Average bandwith usage: %v/s\\n - Files: %d copied on %d\\n\",\n\t\t\tctx.endtime,\n\t\t\telapsedtime,\n\t\t\thumanize.Bytes(uint64(bytes/seconds)),\n\t\t\tctx.filecopied,\n\t\t\tctx.filecount)\n\t\tcolor.Unset() // Don't forget to unset\n\t}\n\treturn bytes, err\n}", "func (v *VolumeUpload) Copy() (written int64, err error) {\n\tdefer v.streamDst.Free()\n\n\tbuf := make([]byte, VolumeCopyBufferSize)\n\twritten, err = io.CopyBuffer(v, v.streamSrc, buf)\n\n\tif err != nil {\n\t\tv.streamSrc.Close()\n\t\tv.streamDst.Abort()\n\t\treturn written, err\n\t}\n\n\tif e := v.streamSrc.Close(); e != nil {\n\t\treturn written, e\n\t}\n\tif e := v.streamDst.Finish(); e != nil {\n\t\treturn written, e\n\t}\n\n\treturn written, err\n}", "func (image *Image2D) GetData() []uint8 {\n\tcpy := make([]uint8, len(image.data))\n\tcopy(cpy, image.data)\n\treturn cpy\n}", "func copySnapshot(to, from snap.Snapshot) error {\n\tif !to.Exists() {\n\t\t_, err := io.Copy(to, from)\n\t\tif err != nil {\n\t\t\treturn errors.WithStack(err)\n\t\t}\n\t\treturn to.Save()\n\t}\n\treturn nil\n}", "func copyFile(filename string, newfilename string) {\n of, err := os.Open(filename)\n u.ErrNil(err, \"Can't Open old file\")\n defer of.Close()\n \n nf, err2 := os.Create(newfilename)\n u.ErrNil(err2, \"Can't create new file\")\n defer nf.Close()\n \n bw, err3 := io.Copy(nf, of)\n u.ErrNil(err3, \"Can't copy from old to new\")\n log.Printf(\"Bytes written: %d\\n\", bw)\n \n if err4 := nf.Sync(); err4 != nil {\n log.Fatalln(err4)\n }\n log.Printf(\"Done copying from %s to %s\\n\", filename, newfilename)\n\n}", "func copyVersions(srcStore, dstStore dvid.Store, d1, d2 dvid.Data, uuids []dvid.UUID) error {\n\tif len(uuids) == 0 {\n\t\tdvid.Infof(\"no versions given for copy... aborting\\n\")\n\t\treturn nil\n\t}\n\tsrcDB, ok := srcStore.(rawQueryDB)\n\tif !ok {\n\t\treturn fmt.Errorf(\"source store %q doesn't have required raw range query\", srcStore)\n\t}\n\tdstDB, ok := dstStore.(rawPutDB)\n\tif !ok {\n\t\treturn fmt.Errorf(\"destination store %q doesn't have raw Put query\", dstStore)\n\t}\n\tvar dataInstanceChanged bool\n\tif d2 == nil {\n\t\td2 = d1\n\t} else {\n\t\tdataInstanceChanged = true\n\t}\n\tversionsOnPath, versionsToStore, err := calcVersionPath(uuids)\n\tif err != nil {\n\t\treturn err\n\t}\n\tvar wg sync.WaitGroup\n\twg.Add(1)\n\n\tstatsTotal := new(txStats)\n\tstatsTotal.lastTime = time.Now()\n\tstatsTotal.name = fmt.Sprintf(\"%q total\", d1.DataName())\n\tstatsStored := new(txStats)\n\tstatsStored.lastTime = time.Now()\n\tstatsStored.name = fmt.Sprintf(\"stored into %q\", d2.DataName())\n\tvar kvTotal, kvSent int\n\tvar bytesTotal, bytesSent uint64\n\n\t// Start goroutine to receive all key-value pairs, process, and store them.\n\trawCh := make(chan *storage.KeyValue, 5000)\n\tgo func() {\n\t\tvar maxVersionKey storage.Key\n\t\tvar numStoredKV int\n\t\tkvsToStore := make(map[dvid.VersionID]*storage.KeyValue, len(versionsToStore))\n\t\tfor _, v := range versionsToStore {\n\t\t\tkvsToStore[v] = nil\n\t\t}\n\t\tfor {\n\t\t\tkv := <-rawCh\n\t\t\tif kv != nil && !storage.Key(kv.K).IsDataKey() {\n\t\t\t\tdvid.Infof(\"Skipping non-data key-value %x ...\\n\", []byte(kv.K))\n\t\t\t\tcontinue\n\t\t\t}\n\t\t\tif kv == nil || maxVersionKey == nil || bytes.Compare(kv.K, maxVersionKey) > 0 {\n\t\t\t\tif numStoredKV > 0 {\n\t\t\t\t\tvar lastKV *storage.KeyValue\n\t\t\t\t\tfor _, v := range versionsToStore {\n\t\t\t\t\t\tcurKV := kvsToStore[v]\n\t\t\t\t\t\tif lastKV == nil || (curKV != nil && bytes.Compare(lastKV.V, curKV.V) != 0) {\n\t\t\t\t\t\t\tif curKV != nil {\n\t\t\t\t\t\t\t\tkeybuf := make(storage.Key, len(curKV.K))\n\t\t\t\t\t\t\t\tcopy(keybuf, curKV.K)\n\t\t\t\t\t\t\t\tif dataInstanceChanged {\n\t\t\t\t\t\t\t\t\terr = storage.ChangeDataKeyInstance(keybuf, d2.InstanceID())\n\t\t\t\t\t\t\t\t\tif err != nil {\n\t\t\t\t\t\t\t\t\t\tdvid.Errorf(\"could not change instance ID of key to %d: %v\\n\", d2.InstanceID(), err)\n\t\t\t\t\t\t\t\t\t\tcontinue\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\tstorage.ChangeDataKeyVersion(keybuf, v)\n\t\t\t\t\t\t\t\tkvSent++\n\t\t\t\t\t\t\t\tbytesSent += uint64(len(curKV.V) + len(keybuf))\n\t\t\t\t\t\t\t\tif err := dstDB.RawPut(keybuf, curKV.V); err != nil {\n\t\t\t\t\t\t\t\t\tdvid.Errorf(\"can't put k/v pair to destination instance %q: %v\\n\", d2.DataName(), err)\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\tstatsStored.addKV(keybuf, curKV.V)\n\t\t\t\t\t\t\t\tlastKV = curKV\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tif kv == nil {\n\t\t\t\t\twg.Done()\n\t\t\t\t\tdvid.Infof(\"Sent %d %q key-value pairs (%s, out of %d kv pairs, %s)\\n\",\n\t\t\t\t\t\tkvSent, d1.DataName(), humanize.Bytes(bytesSent), kvTotal, humanize.Bytes(bytesTotal))\n\t\t\t\t\tdvid.Infof(\"Total KV Stats for %q:\\n\", d1.DataName())\n\t\t\t\t\tstatsTotal.printStats()\n\t\t\t\t\tdvid.Infof(\"Total KV Stats for newly stored %q:\\n\", d2.DataName())\n\t\t\t\t\tstatsStored.printStats()\n\t\t\t\t\treturn\n\t\t\t\t}\n\t\t\t\ttk, err := storage.TKeyFromKey(kv.K)\n\t\t\t\tif err != nil {\n\t\t\t\t\tdvid.Errorf(\"couldn't get %q TKey from Key %v: %v\\n\", d1.DataName(), kv.K, err)\n\t\t\t\t\tcontinue\n\t\t\t\t}\n\t\t\t\tmaxVersionKey, err = storage.MaxVersionDataKey(d1.InstanceID(), tk)\n\t\t\t\tif err != nil {\n\t\t\t\t\tdvid.Errorf(\"couldn't get max version key from Key %v: %v\\n\", kv.K, err)\n\t\t\t\t\tcontinue\n\t\t\t\t}\n\t\t\t\tfor _, v := range versionsToStore {\n\t\t\t\t\tkvsToStore[v] = nil\n\t\t\t\t}\n\t\t\t\tnumStoredKV = 0\n\t\t\t}\n\t\t\tcurV, err := storage.VersionFromDataKey(kv.K)\n\t\t\tif err != nil {\n\t\t\t\tdvid.Errorf(\"unable to get version from key-value: %v\\n\", err)\n\t\t\t\tcontinue\n\t\t\t}\n\t\t\tcurBytes := uint64(len(kv.V) + len(kv.K))\n\t\t\tif _, onPath := versionsOnPath[curV]; onPath {\n\t\t\t\tfor _, v := range versionsToStore {\n\t\t\t\t\tif curV <= v {\n\t\t\t\t\t\tkvsToStore[v] = kv\n\t\t\t\t\t\tnumStoredKV++\n\t\t\t\t\t\tbreak\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tkvTotal++\n\t\t\tbytesTotal += curBytes\n\t\t\tstatsTotal.addKV(kv.K, kv.V)\n\t\t}\n\t}()\n\n\t// Send all kv pairs for the source data instance down the channel.\n\tbegKey, endKey := storage.DataInstanceKeyRange(d1.InstanceID())\n\tkeysOnly := false\n\tif err := srcDB.RawRangeQuery(begKey, endKey, keysOnly, rawCh, nil); err != nil {\n\t\treturn fmt.Errorf(\"push voxels %q range query: %v\", d1.DataName(), err)\n\t}\n\twg.Wait()\n\treturn nil\n}", "func copyDeviceContents(source, dest string, size int64) error {\n\tsourceFd, err := syscall.Open(source, syscall.O_RDWR, 0777)\n\tif err != nil {\n\t\treturn fmt.Errorf(\"Unable to open the file %s\", source)\n\t}\n\tdefer syscall.Close(sourceFd)\n\n\tdestFd, err := syscall.Open(dest, syscall.O_RDWR, 0777)\n\tif err != nil {\n\t\treturn fmt.Errorf(\"Unable to open the file: %s\", dest)\n\t}\n\tdefer syscall.Close(destFd)\n\n\tvar writtenSoFar int64\n\n\tbuffer := make([]byte, 1024)\n\tfor writtenSoFar < size {\n\t\tnumRead, err := syscall.Read(sourceFd, buffer)\n\t\tif err != nil {\n\t\t\treturn fmt.Errorf(\"Unable to read the the file %s\", source)\n\t\t}\n\t\tnumWritten, err := syscall.Write(destFd, buffer)\n\t\tif err != nil {\n\t\t\treturn fmt.Errorf(\"Unable to write to destination %s\", dest)\n\t\t}\n\n\t\tif numRead != numWritten {\n\t\t\tsylog.Debugf(\"numRead != numWritten\")\n\t\t}\n\t\twrittenSoFar += int64(numWritten)\n\t}\n\n\treturn nil\n}", "func (r *ImageRef) Replicate(across int, down int) error {\n\tout, err := vipsReplicate(r.image, across, down)\n\tif err != nil {\n\t\treturn err\n\t}\n\tr.setImage(out)\n\treturn nil\n}", "func (h *Histogram) copyHDataFrom(src *Histogram) {\n\tif h.Divider == src.Divider && h.Offset == src.Offset {\n\t\tfor i := 0; i < len(h.Hdata); i++ {\n\t\t\th.Hdata[i] += src.Hdata[i]\n\t\t}\n\t\treturn\n\t}\n\n\thData := src.Export()\n\tfor _, data := range hData.Data {\n\t\th.record((data.Start+data.End)/2, int(data.Count))\n\t}\n}", "func releaseImageData(img image.Image) {\n\tswitch raw := img.(type) {\n\tcase *image.Alpha:\n\t\traw.Pix = nil\n\tcase *image.Alpha16:\n\t\traw.Pix = nil\n\tcase *image.Gray:\n\t\traw.Pix = nil\n\tcase *image.Gray16:\n\t\traw.Pix = nil\n\tcase *image.NRGBA:\n\t\traw.Pix = nil\n\tcase *image.NRGBA64:\n\t\traw.Pix = nil\n\tcase *image.Paletted:\n\t\traw.Pix = nil\n\tcase *image.RGBA:\n\t\traw.Pix = nil\n\tcase *image.RGBA64:\n\t\traw.Pix = nil\n\tdefault:\n\t\treturn\n\t}\n}", "func shovel(srcconn, dstconn net.Conn) {\n fmt.Println(\"Shoveling from: \", srcconn.RemoteAddr(), \" --to--> \", dstconn.RemoteAddr())\n _,err:=io.Copy(dstconn, srcconn)\n if err!=nil {\n fmt.Println(\"ERROR: copy(): \", err)\n } else {\n fmt.Println(\"Clean Exit from Shovel()\")\n }\n}", "func (b *bufferFallbackImpl) putImage(xd xproto.Drawable, xg xproto.Gcontext, depth uint8, dp image.Point, sr image.Rectangle) {\n\twidthPerReq := b.size.X\n\trowPerReq := xPutImageReqDataSize / (widthPerReq * 4)\n\tdataPerReq := rowPerReq * widthPerReq * 4\n\tdstX := dp.X\n\tdstY := dp.Y\n\tstart := 0\n\tend := 0\n\n\tfor end < len(b.buf) {\n\t\tend = start + dataPerReq\n\t\tif end > len(b.buf) {\n\t\t\tend = len(b.buf)\n\t\t}\n\n\t\tdata := b.buf[start:end]\n\t\theightPerReq := len(data) / (widthPerReq * 4)\n\n\t\txproto.PutImage(\n\t\t\tb.xc, xproto.ImageFormatZPixmap, xd, xg,\n\t\t\tuint16(widthPerReq), uint16(heightPerReq),\n\t\t\tint16(dstX), int16(dstY),\n\t\t\t0, depth, data)\n\n\t\tstart = end\n\t\tdstY += rowPerReq\n\t}\n}", "func (m *meta) copy(dest *meta) {\n\t*dest = *m\n}", "func (m *meta) copy(dest *meta) {\n\t*dest = *m\n}", "func (m *meta) copy(dest *meta) {\n\t*dest = *m\n}" ]
[ "0.6013944", "0.5896212", "0.58863497", "0.5862755", "0.57075185", "0.56613827", "0.565777", "0.56153184", "0.5606776", "0.55278593", "0.5462111", "0.5404379", "0.5403513", "0.5392083", "0.5388897", "0.5367096", "0.5323028", "0.5318446", "0.5313176", "0.5232477", "0.52323097", "0.5224039", "0.5213626", "0.52132857", "0.5192635", "0.5182848", "0.5169678", "0.51689386", "0.5154373", "0.5143588", "0.5137678", "0.51364166", "0.5128103", "0.50971156", "0.506783", "0.50667083", "0.50620544", "0.50471634", "0.50439864", "0.5035568", "0.5019983", "0.5019587", "0.50057244", "0.4996169", "0.49958658", "0.4993283", "0.498804", "0.49854305", "0.49779943", "0.49489683", "0.49179405", "0.49164513", "0.49080282", "0.4905704", "0.49052617", "0.49052617", "0.4896853", "0.4888814", "0.48744288", "0.4873307", "0.4867188", "0.48567897", "0.48531333", "0.48403677", "0.4813509", "0.48081678", "0.4804623", "0.47859165", "0.47835472", "0.47829583", "0.47808024", "0.47806486", "0.47804546", "0.47786736", "0.4775909", "0.4775618", "0.4774573", "0.4773067", "0.47693193", "0.47690934", "0.47656453", "0.47648937", "0.47578374", "0.47546977", "0.47512573", "0.47468752", "0.47466186", "0.47465402", "0.4742396", "0.4733359", "0.47328302", "0.4727412", "0.47234398", "0.47224924", "0.47211507", "0.47156876", "0.47144347", "0.47144347", "0.47144347" ]
0.57912856
5
copy all or part of the data store of a buffer object to the data store of another buffer object
func CopyNamedBufferSubData(readBuffer uint32, writeBuffer uint32, readOffset int, writeOffset int, size int) { C.glowCopyNamedBufferSubData(gpCopyNamedBufferSubData, (C.GLuint)(readBuffer), (C.GLuint)(writeBuffer), (C.GLintptr)(readOffset), (C.GLintptr)(writeOffset), (C.GLsizeiptr)(size)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func CopyBufferSubData(readTarget uint32, writeTarget uint32, readOffset int, writeOffset int, size int) {\n\tsyscall.Syscall6(gpCopyBufferSubData, 5, uintptr(readTarget), uintptr(writeTarget), uintptr(readOffset), uintptr(writeOffset), uintptr(size), 0)\n}", "func CopyBufferSubData(readTarget uint32, writeTarget uint32, readOffset int, writeOffset int, size int) {\n C.glowCopyBufferSubData(gpCopyBufferSubData, (C.GLenum)(readTarget), (C.GLenum)(writeTarget), (C.GLintptr)(readOffset), (C.GLintptr)(writeOffset), (C.GLsizeiptr)(size))\n}", "func copyIfNeeded(bd *netBuf, b []byte) []byte {\n\tif bd.pool == -1 && sameUnderlyingStorage(b, bd.buf) {\n\t\treturn b\n\t}\n\tn := make([]byte, len(b))\n\tcopy(n, b)\n\treturn n\n}", "func (r *Relay) copyWithBuffer(dst io.Writer, src io.Reader, buf []byte) (written int64, err error) {\n\tfor {\n\t\tnr, er := src.Read(buf)\n\t\tif nr > 0 {\n\t\t\tnw, ew := dst.Write(buf[0:nr])\n\t\t\tif nw < 0 || nr < nw {\n\t\t\t\tnw = 0\n\t\t\t\tif ew == nil {\n\t\t\t\t\tew = errInvalidWrite\n\t\t\t\t}\n\t\t\t}\n\t\t\twritten += int64(nw)\n\t\t\tif ew != nil {\n\t\t\t\terr = ew\n\t\t\t\tbreak\n\t\t\t}\n\t\t\tif nr != nw {\n\t\t\t\terr = io.ErrShortWrite\n\t\t\t\tbreak\n\t\t\t}\n\t\t\tif r.metricsTracer != nil {\n\t\t\t\tr.metricsTracer.BytesTransferred(nw)\n\t\t\t}\n\t\t}\n\t\tif er != nil {\n\t\t\tif er != io.EOF {\n\t\t\t\terr = er\n\t\t\t}\n\t\t\tbreak\n\t\t}\n\t}\n\treturn written, err\n}", "func CopyBufferSubData(readTarget uint32, writeTarget uint32, readOffset int, writeOffset int, size int) {\n\tC.glowCopyBufferSubData(gpCopyBufferSubData, (C.GLenum)(readTarget), (C.GLenum)(writeTarget), (C.GLintptr)(readOffset), (C.GLintptr)(writeOffset), (C.GLsizeiptr)(size))\n}", "func CopyBufferSubData(readTarget uint32, writeTarget uint32, readOffset int, writeOffset int, size int) {\n\tC.glowCopyBufferSubData(gpCopyBufferSubData, (C.GLenum)(readTarget), (C.GLenum)(writeTarget), (C.GLintptr)(readOffset), (C.GLintptr)(writeOffset), (C.GLsizeiptr)(size))\n}", "func CopyNamedBufferSubData(readBuffer uint32, writeBuffer uint32, readOffset int, writeOffset int, size int) {\n\tsyscall.Syscall6(gpCopyNamedBufferSubData, 5, uintptr(readBuffer), uintptr(writeBuffer), uintptr(readOffset), uintptr(writeOffset), uintptr(size), 0)\n}", "func (d *OneToOne) Set(data GenericDataType) {\n\tidx := d.writeIndex % uint64(len(d.buffer))\n\n\tnewBucket := &bucket{\n\t\tdata: data,\n\t\tseq: d.writeIndex,\n\t}\n\td.writeIndex++\n\n\tatomic.StorePointer(&d.buffer[idx], unsafe.Pointer(newBucket))\n}", "func (b *Buffer) CopyDataFrom(src *Buffer, srcOffset, dstOffset, size int) error {\n\tif size == 0 {\n\t\treturn nil\n\t}\n\n\terrCode := cl.EnqueueCopyBuffer(\n\t\tb.device.cmdQueue,\n\t\tsrc.bufHandle,\n\t\tb.bufHandle,\n\t\tuint64(srcOffset),\n\t\tuint64(dstOffset),\n\t\tuint64(size),\n\t\t0,\n\t\tnil,\n\t\tnil,\n\t)\n\n\tif errCode != cl.SUCCESS {\n\t\treturn fmt.Errorf(\"opencl device(%s): error copying device data from buffer %s to buffer %s (errCode %d)\", b.device.Name, src.name, b.name, errCode)\n\t}\n\treturn nil\n}", "func (server *StorageServer) copyToMemory(data []byte) int32 {\n\n\t// allocate memory in wasm\n\tptr, err := server.funcs[\"alloc\"].Call(int32(len(data)))\n\tcheck(err)\n\n\t// casting pointer to int32\n\tptr32 := ptr.(int32)\n\n\t//fmt.Printf(\"This is the pointer %v\\n\", ptr32)\n\n\t// return raw memory backed by the WebAssembly memory as a byte slice\n\tbuf := server.memory.UnsafeData()\n\tfor i, v := range data {\n\t\tbuf[ptr32+int32(i)] = v\n\t}\n\t// return the pointer\n\treturn ptr32\n}", "func copyData(oldKV, newKV storage.OrderedKeyValueDB, d1, d2 dvid.Data, uuid dvid.UUID, f storage.Filter, flatten bool) error {\n\t// Get data context for this UUID.\n\tv, err := VersionFromUUID(uuid)\n\tif err != nil {\n\t\treturn err\n\t}\n\tsrcCtx := NewVersionedCtx(d1, v)\n\tvar dstCtx *VersionedCtx\n\tif d2 == nil {\n\t\td2 = d1\n\t\tdstCtx = srcCtx\n\t} else {\n\t\tdstCtx = NewVersionedCtx(d2, v)\n\t}\n\n\t// Send this instance's key-value pairs\n\tvar wg sync.WaitGroup\n\twg.Add(1)\n\n\tstats := new(txStats)\n\tstats.lastTime = time.Now()\n\tstats.name = fmt.Sprintf(\"copy of %s\", d1.DataName())\n\n\tvar kvTotal, kvSent int\n\tvar bytesTotal, bytesSent uint64\n\tkeysOnly := false\n\tif flatten {\n\t\t// Start goroutine to receive flattened key-value pairs and store them.\n\t\tch := make(chan *storage.TKeyValue, 1000)\n\t\tgo func() {\n\t\t\tfor {\n\t\t\t\ttkv := <-ch\n\t\t\t\tif tkv == nil {\n\t\t\t\t\twg.Done()\n\t\t\t\t\tdvid.Infof(\"Copied %d %q key-value pairs (%s, out of %d kv pairs, %s) [flattened]\\n\",\n\t\t\t\t\t\tkvSent, d1.DataName(), humanize.Bytes(bytesSent), kvTotal, humanize.Bytes(bytesTotal))\n\t\t\t\t\tstats.printStats()\n\t\t\t\t\treturn\n\t\t\t\t}\n\t\t\t\tkvTotal++\n\t\t\t\tcurBytes := uint64(len(tkv.V) + len(tkv.K))\n\t\t\t\tbytesTotal += curBytes\n\t\t\t\tif f != nil {\n\t\t\t\t\tskip, err := f.Check(tkv)\n\t\t\t\t\tif err != nil {\n\t\t\t\t\t\tdvid.Errorf(\"problem applying filter on data %q: %v\\n\", d1.DataName(), err)\n\t\t\t\t\t\tcontinue\n\t\t\t\t\t}\n\t\t\t\t\tif skip {\n\t\t\t\t\t\tcontinue\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tkvSent++\n\t\t\t\tbytesSent += curBytes\n\t\t\t\tif err := newKV.Put(dstCtx, tkv.K, tkv.V); err != nil {\n\t\t\t\t\tdvid.Errorf(\"can't put k/v pair to destination instance %q: %v\\n\", d2.DataName(), err)\n\t\t\t\t}\n\t\t\t\tstats.addKV(tkv.K, tkv.V)\n\t\t\t}\n\t\t}()\n\n\t\tbegKey, endKey := srcCtx.TKeyRange()\n\t\terr := oldKV.ProcessRange(srcCtx, begKey, endKey, &storage.ChunkOp{}, func(c *storage.Chunk) error {\n\t\t\tif c == nil {\n\t\t\t\treturn fmt.Errorf(\"received nil chunk in flatten push for data %s\", d1.DataName())\n\t\t\t}\n\t\t\tch <- c.TKeyValue\n\t\t\treturn nil\n\t\t})\n\t\tch <- nil\n\t\tif err != nil {\n\t\t\treturn fmt.Errorf(\"error in flatten push for data %q: %v\", d1.DataName(), err)\n\t\t}\n\t} else {\n\t\t// Start goroutine to receive all key-value pairs and store them.\n\t\tch := make(chan *storage.KeyValue, 1000)\n\t\tgo func() {\n\t\t\tfor {\n\t\t\t\tkv := <-ch\n\t\t\t\tif kv == nil {\n\t\t\t\t\twg.Done()\n\t\t\t\t\tdvid.Infof(\"Sent %d %q key-value pairs (%s, out of %d kv pairs, %s)\\n\",\n\t\t\t\t\t\tkvSent, d1.DataName(), humanize.Bytes(bytesSent), kvTotal, humanize.Bytes(bytesTotal))\n\t\t\t\t\tstats.printStats()\n\t\t\t\t\treturn\n\t\t\t\t}\n\t\t\t\ttkey, err := storage.TKeyFromKey(kv.K)\n\t\t\t\tif err != nil {\n\t\t\t\t\tdvid.Errorf(\"couldn't get %q TKey from Key %v: %v\\n\", d1.DataName(), kv.K, err)\n\t\t\t\t\tcontinue\n\t\t\t\t}\n\n\t\t\t\tkvTotal++\n\t\t\t\tcurBytes := uint64(len(kv.V) + len(kv.K))\n\t\t\t\tbytesTotal += curBytes\n\t\t\t\tif f != nil {\n\t\t\t\t\tskip, err := f.Check(&storage.TKeyValue{K: tkey, V: kv.V})\n\t\t\t\t\tif err != nil {\n\t\t\t\t\t\tdvid.Errorf(\"problem applying filter on data %q: %v\\n\", d1.DataName(), err)\n\t\t\t\t\t\tcontinue\n\t\t\t\t\t}\n\t\t\t\t\tif skip {\n\t\t\t\t\t\tcontinue\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tkvSent++\n\t\t\t\tbytesSent += curBytes\n\t\t\t\tif dstCtx != nil {\n\t\t\t\t\terr := dstCtx.UpdateInstance(kv.K)\n\t\t\t\t\tif err != nil {\n\t\t\t\t\t\tdvid.Errorf(\"can't update raw key to new data instance %q: %v\\n\", d2.DataName(), err)\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tif err := newKV.RawPut(kv.K, kv.V); err != nil {\n\t\t\t\t\tdvid.Errorf(\"can't put k/v pair to destination instance %q: %v\\n\", d2.DataName(), err)\n\t\t\t\t}\n\t\t\t\tstats.addKV(kv.K, kv.V)\n\t\t\t}\n\t\t}()\n\n\t\tbegKey, endKey := srcCtx.KeyRange()\n\t\tif err = oldKV.RawRangeQuery(begKey, endKey, keysOnly, ch, nil); err != nil {\n\t\t\treturn fmt.Errorf(\"push voxels %q range query: %v\", d1.DataName(), err)\n\t\t}\n\t}\n\twg.Wait()\n\treturn nil\n}", "func (d PacketData) MergeBuffer(b *buffer.Buffer) {\n\td.pk.buf.Merge(b)\n}", "func (q *Queue) transfer() {\n\tfor q.s1.Peek() != nil {\n\t\tq.s2.Push(q.s1.Pop())\n\t}\n}", "func putBufferMessageIntoReadStorage(s *server, ConnID int) {\n\tfor s.clientMap[ConnID].clientBufferQueue.Len() > 0 && s.clientMap[ConnID].clientSequenceMap == s.clientMap[ConnID].clientBufferQueue.Front().Value.(Message).SeqNum {\n\t\tfront := s.clientMap[ConnID].clientBufferQueue.Front()\n\t\ts.clientMap[ConnID].clientBufferQueue.Remove(front)\n\t\tmsg := front.Value.(Message)\n\t\ts.readStorage.PushBack(msg)\n\t\ts.clientMap[ConnID].clientSequenceMap = s.clientMap[ConnID].clientSequenceMap + 1\n\t}\n}", "func memcpy(dst, src unsafe.Pointer, size uintptr)", "func copyBuffer(dst io.Writer, src io.Reader, buf []byte) error {\n\tfor {\n\t\tnr, rerr := src.Read(buf)\n\t\tif nr > 0 {\n\t\t\tnw, werr := dst.Write(buf[:nr])\n\t\t\tif werr != nil {\n\t\t\t\treturn werr\n\t\t\t}\n\t\t\tif nr != nw {\n\t\t\t\treturn io.ErrShortWrite\n\t\t\t}\n\t\t}\n\t\tif rerr != nil {\n\t\t\tif rerr == io.EOF {\n\t\t\t\trerr = nil\n\t\t\t}\n\t\t\treturn rerr\n\t\t}\n\t}\n}", "func (s *syncMapInt64) copy(dst *syncMapInt64) {\n\tfor _, t := range s.keys() {\n\t\tdst.store(t, s.load(t))\n\t}\n}", "func (destination *streamDestination) copyAndResetBuffer() []byte {\n\tif len(destination.buffer) > 0 {\n\t\tmsg := make([]byte, len(destination.buffer))\n\t\tcopy(msg, destination.buffer)\n\n\t\tdestination.buffer = destination.buffer[:0]\n\t\treturn msg\n\t}\n\n\treturn []byte{}\n}", "func (b *Buffer) AttachBytes(buffer []byte, offset int, size int) {\n if len(buffer) < size {\n panic(\"invalid buffer\")\n }\n if size <= 0 {\n panic(\"invalid size\")\n }\n if offset > size {\n panic(\"invalid offset\")\n }\n\n b.data = buffer\n b.size = size\n b.offset = offset\n}", "func (bio *BinaryIO) Copy(dst int64, src int64, count int) error {\n\tbuf := makeBuf(count)\n\tfor count > 0 {\n\t\tbuf = truncBuf(buf, count)\n\t\tbio.ReadAt(src, buf)\n\t\tbio.WriteAt(dst, buf)\n\t\tcount -= len(buf)\n\t\tsrc += int64(len(buf))\n\t\tdst += int64(len(buf))\n\t}\n\treturn nil\n}", "func (h Handler) copyBuffer(dst io.Writer, src io.Reader, buf []byte) (int64, error) {\n\tif len(buf) == 0 {\n\t\tbuf = make([]byte, defaultBufferSize)\n\t}\n\tvar written int64\n\tfor {\n\t\tnr, rerr := src.Read(buf)\n\t\tif rerr != nil && rerr != io.EOF && rerr != context.Canceled {\n\t\t\t// TODO: this could be useful to know (indeed, it revealed an error in our\n\t\t\t// fastcgi PoC earlier; but it's this single error report here that necessitates\n\t\t\t// a function separate from io.CopyBuffer, since io.CopyBuffer does not distinguish\n\t\t\t// between read or write errors; in a reverse proxy situation, write errors are not\n\t\t\t// something we need to report to the client, but read errors are a problem on our\n\t\t\t// end for sure. so we need to decide what we want.)\n\t\t\t// p.logf(\"copyBuffer: ReverseProxy read error during body copy: %v\", rerr)\n\t\t\th.logger.Error(\"reading from backend\", zap.Error(rerr))\n\t\t}\n\t\tif nr > 0 {\n\t\t\tnw, werr := dst.Write(buf[:nr])\n\t\t\tif nw > 0 {\n\t\t\t\twritten += int64(nw)\n\t\t\t}\n\t\t\tif werr != nil {\n\t\t\t\treturn written, fmt.Errorf(\"writing: %w\", werr)\n\t\t\t}\n\t\t\tif nr != nw {\n\t\t\t\treturn written, io.ErrShortWrite\n\t\t\t}\n\t\t}\n\t\tif rerr != nil {\n\t\t\tif rerr == io.EOF {\n\t\t\t\treturn written, nil\n\t\t\t}\n\t\t\treturn written, fmt.Errorf(\"reading: %w\", rerr)\n\t\t}\n\t}\n}", "func copyStruct(dst *enigma, src *enigma) {\n\tdst.reflector = src.reflector\n\n\tdst.rings = make([]int, len(src.rings))\n\tcopy(dst.rings, src.rings)\n\n\tdst.positions = make([]string, len(src.positions))\n\tcopy(dst.positions, src.positions)\n\n\tdst.rotors = make([]string, len(src.rotors))\n\tcopy(dst.rotors, src.rotors)\n\n\tdst.plugboard = src.plugboard\n}", "func copyBuffer(dst io.Writer, src io.Reader, buf []byte) (written int64, err error) {\r\n\t// If the reader has a WriteTo method, use it to do the copy.\r\n\t// Avoids an allocation and a copy.\r\n\t// if wt, ok := src.(io.WriterTo); ok {\r\n\t// \treturn wt.WriteTo(dst)\r\n\t// }\r\n\r\n\t// Similarly, if the writer has a ReadFrom method, use it to do the copy.\r\n\t// if rt, ok := dst.(io.ReaderFrom); ok {\r\n\t// \treturn rt.ReadFrom(src)\r\n\t// }\r\n\r\n\tif buf == nil {\r\n\t\tbuf = make([]byte, 32*1024)\r\n\t\t//buf = make([]byte, 5*1024*1024)\r\n\t}\r\n\r\n\tfor {\r\n\t\tnr, er := src.Read(buf)\r\n\t\tif nr > 0 {\r\n\t\t\tnw, ew := dst.Write(buf[0:nr])\r\n\t\t\tif nw > 0 {\r\n\t\t\t\twritten += int64(nw)\r\n\t\t\t}\r\n\t\t\tif ew != nil {\r\n\t\t\t\terr = ew\r\n\t\t\t\tbreak\r\n\t\t\t}\r\n\t\t\tif nr != nw {\r\n\t\t\t\terr = io.ErrShortWrite\r\n\t\t\t\tbreak\r\n\t\t\t}\r\n\t\t}\r\n\t\tif er == io.EOF {\r\n\t\t\tbreak\r\n\t\t}\r\n\t\tif er != nil {\r\n\t\t\terr = er\r\n\t\t\tbreak\r\n\t\t}\r\n\t}\r\n\treturn written, err\r\n}", "func (s *Store) Copy() *Store {\n\ts.access.RLock()\n\tdefer s.access.RUnlock()\n\n\tcpy := NewStore()\n\tfor key, value := range s.data {\n\t\tcpy.data[key] = value\n\t}\n\treturn cpy\n}", "func (a DBFSAPI) Copy(src string, tgt string, client *DBApiClient, overwrite bool) error {\n\thandle, err := a.createHandle(tgt, overwrite)\n\tif err != nil {\n\t\treturn err\n\t}\n\tdefer func() {\n\t\terr = a.closeHandle(handle)\n\t}()\n\tfetchLoop := true\n\toffSet := int64(0)\n\tlength := int64(1e6)\n\tfor fetchLoop {\n\t\tvar api DBFSAPI\n\t\tif client == nil {\n\t\t\tapi = a\n\t\t} else {\n\t\t\tapi = client.DBFS()\n\t\t}\n\t\tbytesRead, b64String, err := api.ReadString(src, offSet, length)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tlog.Println(bytesRead)\n\t\tif bytesRead == 0 || bytesRead < length {\n\t\t\tfetchLoop = false\n\t\t}\n\n\t\terr = a.addBlock(b64String, handle)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\n\t\toffSet += length\n\t}\n\n\treturn err\n}", "func Copy(source KVStore, target KVStore) error {\n\n\tvar innerErr error\n\tif err := source.Iterate(EmptyPrefix, func(key, value Value) bool {\n\t\tif err := target.Set(key, value); err != nil {\n\t\t\tinnerErr = err\n\t\t}\n\n\t\treturn innerErr == nil\n\t}); err != nil {\n\t\treturn err\n\t}\n\n\tif innerErr != nil {\n\t\treturn innerErr\n\t}\n\n\treturn target.Flush()\n}", "func CopyMem(source uint64, dest uint64, size uint64)", "func deepcopy(dst, src interface{}) error {\n\tr, w, err := os.Pipe()\n\tif err != nil {\n\t\treturn err\n\t}\n\tenc := gob.NewEncoder(w)\n\terr = enc.Encode(src)\n\tif err != nil {\n\t\treturn err\n\t}\n\tdec := gob.NewDecoder(r)\n\treturn dec.Decode(dst)\n}", "func (driver *S3Driver) CopyBuffer(dst io.Writer, src io.Reader, buf []byte) (written int64, err error) {\r\n\tif buf != nil && len(buf) == 0 {\r\n\t\tpanic(\"empty buffer in io.CopyBuffer\")\r\n\t}\r\n\treturn copyBuffer(dst, src, buf)\r\n}", "func copyVersions(srcStore, dstStore dvid.Store, d1, d2 dvid.Data, uuids []dvid.UUID) error {\n\tif len(uuids) == 0 {\n\t\tdvid.Infof(\"no versions given for copy... aborting\\n\")\n\t\treturn nil\n\t}\n\tsrcDB, ok := srcStore.(rawQueryDB)\n\tif !ok {\n\t\treturn fmt.Errorf(\"source store %q doesn't have required raw range query\", srcStore)\n\t}\n\tdstDB, ok := dstStore.(rawPutDB)\n\tif !ok {\n\t\treturn fmt.Errorf(\"destination store %q doesn't have raw Put query\", dstStore)\n\t}\n\tvar dataInstanceChanged bool\n\tif d2 == nil {\n\t\td2 = d1\n\t} else {\n\t\tdataInstanceChanged = true\n\t}\n\tversionsOnPath, versionsToStore, err := calcVersionPath(uuids)\n\tif err != nil {\n\t\treturn err\n\t}\n\tvar wg sync.WaitGroup\n\twg.Add(1)\n\n\tstatsTotal := new(txStats)\n\tstatsTotal.lastTime = time.Now()\n\tstatsTotal.name = fmt.Sprintf(\"%q total\", d1.DataName())\n\tstatsStored := new(txStats)\n\tstatsStored.lastTime = time.Now()\n\tstatsStored.name = fmt.Sprintf(\"stored into %q\", d2.DataName())\n\tvar kvTotal, kvSent int\n\tvar bytesTotal, bytesSent uint64\n\n\t// Start goroutine to receive all key-value pairs, process, and store them.\n\trawCh := make(chan *storage.KeyValue, 5000)\n\tgo func() {\n\t\tvar maxVersionKey storage.Key\n\t\tvar numStoredKV int\n\t\tkvsToStore := make(map[dvid.VersionID]*storage.KeyValue, len(versionsToStore))\n\t\tfor _, v := range versionsToStore {\n\t\t\tkvsToStore[v] = nil\n\t\t}\n\t\tfor {\n\t\t\tkv := <-rawCh\n\t\t\tif kv != nil && !storage.Key(kv.K).IsDataKey() {\n\t\t\t\tdvid.Infof(\"Skipping non-data key-value %x ...\\n\", []byte(kv.K))\n\t\t\t\tcontinue\n\t\t\t}\n\t\t\tif kv == nil || maxVersionKey == nil || bytes.Compare(kv.K, maxVersionKey) > 0 {\n\t\t\t\tif numStoredKV > 0 {\n\t\t\t\t\tvar lastKV *storage.KeyValue\n\t\t\t\t\tfor _, v := range versionsToStore {\n\t\t\t\t\t\tcurKV := kvsToStore[v]\n\t\t\t\t\t\tif lastKV == nil || (curKV != nil && bytes.Compare(lastKV.V, curKV.V) != 0) {\n\t\t\t\t\t\t\tif curKV != nil {\n\t\t\t\t\t\t\t\tkeybuf := make(storage.Key, len(curKV.K))\n\t\t\t\t\t\t\t\tcopy(keybuf, curKV.K)\n\t\t\t\t\t\t\t\tif dataInstanceChanged {\n\t\t\t\t\t\t\t\t\terr = storage.ChangeDataKeyInstance(keybuf, d2.InstanceID())\n\t\t\t\t\t\t\t\t\tif err != nil {\n\t\t\t\t\t\t\t\t\t\tdvid.Errorf(\"could not change instance ID of key to %d: %v\\n\", d2.InstanceID(), err)\n\t\t\t\t\t\t\t\t\t\tcontinue\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\tstorage.ChangeDataKeyVersion(keybuf, v)\n\t\t\t\t\t\t\t\tkvSent++\n\t\t\t\t\t\t\t\tbytesSent += uint64(len(curKV.V) + len(keybuf))\n\t\t\t\t\t\t\t\tif err := dstDB.RawPut(keybuf, curKV.V); err != nil {\n\t\t\t\t\t\t\t\t\tdvid.Errorf(\"can't put k/v pair to destination instance %q: %v\\n\", d2.DataName(), err)\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\tstatsStored.addKV(keybuf, curKV.V)\n\t\t\t\t\t\t\t\tlastKV = curKV\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tif kv == nil {\n\t\t\t\t\twg.Done()\n\t\t\t\t\tdvid.Infof(\"Sent %d %q key-value pairs (%s, out of %d kv pairs, %s)\\n\",\n\t\t\t\t\t\tkvSent, d1.DataName(), humanize.Bytes(bytesSent), kvTotal, humanize.Bytes(bytesTotal))\n\t\t\t\t\tdvid.Infof(\"Total KV Stats for %q:\\n\", d1.DataName())\n\t\t\t\t\tstatsTotal.printStats()\n\t\t\t\t\tdvid.Infof(\"Total KV Stats for newly stored %q:\\n\", d2.DataName())\n\t\t\t\t\tstatsStored.printStats()\n\t\t\t\t\treturn\n\t\t\t\t}\n\t\t\t\ttk, err := storage.TKeyFromKey(kv.K)\n\t\t\t\tif err != nil {\n\t\t\t\t\tdvid.Errorf(\"couldn't get %q TKey from Key %v: %v\\n\", d1.DataName(), kv.K, err)\n\t\t\t\t\tcontinue\n\t\t\t\t}\n\t\t\t\tmaxVersionKey, err = storage.MaxVersionDataKey(d1.InstanceID(), tk)\n\t\t\t\tif err != nil {\n\t\t\t\t\tdvid.Errorf(\"couldn't get max version key from Key %v: %v\\n\", kv.K, err)\n\t\t\t\t\tcontinue\n\t\t\t\t}\n\t\t\t\tfor _, v := range versionsToStore {\n\t\t\t\t\tkvsToStore[v] = nil\n\t\t\t\t}\n\t\t\t\tnumStoredKV = 0\n\t\t\t}\n\t\t\tcurV, err := storage.VersionFromDataKey(kv.K)\n\t\t\tif err != nil {\n\t\t\t\tdvid.Errorf(\"unable to get version from key-value: %v\\n\", err)\n\t\t\t\tcontinue\n\t\t\t}\n\t\t\tcurBytes := uint64(len(kv.V) + len(kv.K))\n\t\t\tif _, onPath := versionsOnPath[curV]; onPath {\n\t\t\t\tfor _, v := range versionsToStore {\n\t\t\t\t\tif curV <= v {\n\t\t\t\t\t\tkvsToStore[v] = kv\n\t\t\t\t\t\tnumStoredKV++\n\t\t\t\t\t\tbreak\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tkvTotal++\n\t\t\tbytesTotal += curBytes\n\t\t\tstatsTotal.addKV(kv.K, kv.V)\n\t\t}\n\t}()\n\n\t// Send all kv pairs for the source data instance down the channel.\n\tbegKey, endKey := storage.DataInstanceKeyRange(d1.InstanceID())\n\tkeysOnly := false\n\tif err := srcDB.RawRangeQuery(begKey, endKey, keysOnly, rawCh, nil); err != nil {\n\t\treturn fmt.Errorf(\"push voxels %q range query: %v\", d1.DataName(), err)\n\t}\n\twg.Wait()\n\treturn nil\n}", "func (s *segment) merge(oth *segment) {\n\ts.pkt.Data().Merge(oth.pkt.Data())\n\ts.dataMemSize = s.pkt.MemSize()\n\toth.dataMemSize = oth.pkt.MemSize()\n}", "func (p *movingAverageProcessor) addBufferData(index int, data interface{}, namespace string) error {\n\tif _, ok := p.movingAverageMap[namespace]; ok {\n\t\tif index >= len(p.movingAverageMap[namespace].movingAverageBuf) {\n\t\t\treturn errors.New(\"Incorrect value of index, trying to access non-existing element of buffer\")\n\t\t}\n\t\tp.movingAverageMap[namespace].movingAverageBuf[index] = data\n\t\treturn nil\n\t} else {\n\t\treturn errors.New(\"Namespace is not present in the map\")\n\t}\n}", "func ioTransferData(env *Env, conn1, conn2 io.ReadWriteCloser) {\n\tpairs := []struct{ dst, src io.ReadWriteCloser }{{conn1, conn2}, {conn2, conn1}}\n\tfor _, p := range pairs {\n\t\tgo func(src, dst io.ReadWriteCloser) {\n\t\t\tio.Copy(dst, src)\n\t\t\tdst.Close()\n\t\t}(p.src, p.dst)\n\t}\n}", "func (allc *Allocator) putBytesTo(offset uint32, val []byte) {\n\tcopy(allc.mem[offset:], val)\n}", "func copyBuffer(dst io.Writer, src io.Reader, buf []byte) (written int64, err error) {\n\tif buf == nil {\n\t\tbuf = make([]byte, 32*1024)\n\t}\n\tfor {\n\t\tnr, er := src.Read(buf)\n\t\tif nr > 0 {\n\t\t\tnw, ew := dst.Write(buf[0:nr])\n\t\t\tif nw > 0 {\n\t\t\t\twritten += int64(nw)\n\t\t\t}\n\t\t\tif ew != nil {\n\t\t\t\terr = ew\n\t\t\t\tbreak\n\t\t\t}\n\t\t\tif nr != nw {\n\t\t\t\terr = io.ErrShortWrite\n\t\t\t\tbreak\n\t\t\t}\n\t\t}\n\t\tif er == io.EOF {\n\t\t\tbreak\n\t\t}\n\t\tif er != nil {\n\t\t\terr = er\n\t\t\tbreak\n\t\t}\n\t}\n\treturn written, err\n}", "func copyToLocation(location uintptr, data []byte) {\n\tf := rawMemoryAccess(location, len(data))\n\n\tmprotectCrossPage(location, len(data), syscall.PROT_READ|syscall.PROT_WRITE|syscall.PROT_EXEC)\n\tcopy(f, data[:])\n\tfmt.Printf(\"copy bytes len:%d, %s\\n\", len(data), hex.EncodeToString(data))\n\tmprotectCrossPage(location, len(data), syscall.PROT_READ|syscall.PROT_EXEC)\n}", "func makeslicecopy(et *_type, tolen int, fromlen int, from unsafe.Pointer) unsafe.Pointer {\n\tvar tomem, copymem uintptr\n\tif uintptr(tolen) > uintptr(fromlen) {\n\t\tvar overflow bool\n\t\ttomem, overflow = math.MulUintptr(et.size, uintptr(tolen))\n\t\tif overflow || tomem > maxAlloc || tolen < 0 {\n\t\t\tpanicmakeslicelen()\n\t\t}\n\t\tcopymem = et.size * uintptr(fromlen)\n\t} else {\n\t\t// fromlen is a known good length providing and equal or greater than tolen,\n\t\t// thereby making tolen a good slice length too as from and to slices have the\n\t\t// same element width.\n\t\ttomem = et.size * uintptr(tolen)\n\t\tcopymem = tomem\n\t}\n\n\tvar to unsafe.Pointer\n\tif et.ptrdata == 0 {\n\t\tto = mallocgc(tomem, nil, false)\n\t\tif copymem < tomem {\n\t\t\tmemclrNoHeapPointers(add(to, copymem), tomem-copymem)\n\t\t}\n\t} else {\n\t\t// Note: can't use rawmem (which avoids zeroing of memory), because then GC can scan uninitialized memory.\n\t\tto = mallocgc(tomem, et, true)\n\t\tif copymem > 0 && writeBarrier.enabled {\n\t\t\t// Only shade the pointers in old.array since we know the destination slice to\n\t\t\t// only contains nil pointers because it has been cleared during alloc.\n\t\t\tbulkBarrierPreWriteSrcOnly(uintptr(to), uintptr(from), copymem)\n\t\t}\n\t}\n\n\tif raceenabled {\n\t\tcallerpc := getcallerpc()\n\t\tpc := funcPC(makeslicecopy)\n\t\tracereadrangepc(from, copymem, callerpc, pc)\n\t}\n\tif msanenabled {\n\t\tmsanread(from, copymem)\n\t}\n\n\tmemmove(to, from, copymem)\n\n\treturn to\n}", "func (t Treasure) Mutate(b []byte) error {\n\taddr, data := t.RealAddr(), t.Bytes()\n\tfor i := 0; i < 4; i++ {\n\t\tb[addr+i] = data[i]\n\t}\n\treturn nil\n}", "func BufferStorage(target uint32, size int, data unsafe.Pointer, flags uint32) {\n\tsyscall.Syscall6(gpBufferStorage, 4, uintptr(target), uintptr(size), uintptr(data), uintptr(flags), 0, 0)\n}", "func copyBuffer(dst io.Writer, src io.Reader, buf []byte) (written int64, err error) {\n\n\tfor {\n\t\tnr, er := src.Read(buf)\n\n\t\t// break on any read error (and also on EOF)\n\t\tif er != nil {\n\t\t\terr = er\n\t\t\tbreak\n\t\t}\n\n\t\tif nr > 0 {\n\t\t\tnw, ew := dst.Write(buf[0:nr])\n\t\t\tif nw > 0 {\n\t\t\t\twritten += int64(nw)\n\t\t\t}\n\t\t\tif ew != nil {\n\t\t\t\terr = ew\n\t\t\t\tbreak\n\t\t\t}\n\t\t\tif nr != nw {\n\t\t\t\terr = io.ErrShortWrite\n\t\t\t\tbreak\n\t\t\t}\n\t\t}\n\n\t}\n\treturn written, err\n}", "func copyNonZeroFrom(src, dst *storeSnap) {\n\tif len(src.Architectures) > 0 {\n\t\tdst.Architectures = src.Architectures\n\t}\n\tif src.Base != \"\" {\n\t\tdst.Base = src.Base\n\t}\n\tif src.Confinement != \"\" {\n\t\tdst.Confinement = src.Confinement\n\t}\n\tif src.Contact != \"\" {\n\t\tdst.Contact = src.Contact\n\t}\n\tif src.CreatedAt != \"\" {\n\t\tdst.CreatedAt = src.CreatedAt\n\t}\n\tif src.Description.Clean() != \"\" {\n\t\tdst.Description = src.Description\n\t}\n\tif src.Download.URL != \"\" {\n\t\tdst.Download = src.Download\n\t}\n\tif src.Epoch.String() != \"0\" {\n\t\tdst.Epoch = src.Epoch\n\t}\n\tif src.License != \"\" {\n\t\tdst.License = src.License\n\t}\n\tif src.Name != \"\" {\n\t\tdst.Name = src.Name\n\t}\n\tif len(src.Prices) > 0 {\n\t\tdst.Prices = src.Prices\n\t}\n\tif src.Private {\n\t\tdst.Private = src.Private\n\t}\n\tif src.Publisher.ID != \"\" {\n\t\tdst.Publisher = src.Publisher\n\t}\n\tif src.Revision > 0 {\n\t\tdst.Revision = src.Revision\n\t}\n\tif src.SnapID != \"\" {\n\t\tdst.SnapID = src.SnapID\n\t}\n\tif src.SnapYAML != \"\" {\n\t\tdst.SnapYAML = src.SnapYAML\n\t}\n\tif src.Summary.Clean() != \"\" {\n\t\tdst.Summary = src.Summary\n\t}\n\tif src.Title.Clean() != \"\" {\n\t\tdst.Title = src.Title\n\t}\n\tif src.Type != \"\" {\n\t\tdst.Type = src.Type\n\t}\n\tif src.Version != \"\" {\n\t\tdst.Version = src.Version\n\t}\n\tif len(src.Media) > 0 {\n\t\tdst.Media = src.Media\n\t}\n\tif len(src.CommonIDs) > 0 {\n\t\tdst.CommonIDs = src.CommonIDs\n\t}\n}", "func putBuffer(buf *bytes.Buffer) {\n\tbuf.Reset()\n\tbufferPool.Put(buf)\n}", "func (e *genericEncoder) CloneWithBuffer(buf *buffer.Buffer) *genericEncoder {\n\treturn &genericEncoder{\n\t\tEncoderConfig: e.EncoderConfig,\n\t\tbuf: buf,\n\t\tformatTime: e.formatTime,\n\t}\n}", "func (store *Store) append(buf []byte) error {\n\t// append data uncommitted\n\t_, err := store.dataFile.Seek(store.ptr, 0)\n\tif err != nil {\n\t\treturn err\n\t}\n\tif _, err = store.dataFile.Write(buf); err != nil {\n\t\treturn err\n\t}\n\tnewptr, err := store.dataFile.Seek(0, 1)\n\tif err != nil {\n\t\treturn err\n\t}\n\n\t// start committing header\n\tif _, err = store.dataFile.Seek(0, 0); err != nil {\n\t\treturn err\n\t}\n\ttmp := [8]byte{}\n\tif _, err = store.dataFile.Read(tmp[:]); err != nil {\n\t\treturn err\n\t}\n\tflag := tmp[3]\n\tbinary.BigEndian.PutUint64(tmp[:], uint64(newptr))\n\n\tif flag == 0 {\n\t\tflag = 1\n\t\t_, err = store.dataFile.Seek(10, 0)\n\t} else {\n\t\tflag = 0\n\t\t_, err = store.dataFile.Seek(4, 0)\n\t}\n\tif err != nil {\n\t\treturn err\n\t}\n\n\tif _, err = store.dataFile.Write(tmp[2:]); err != nil {\n\t\treturn err\n\t}\n\tif _, err = store.dataFile.Seek(3, 0); err != nil {\n\t\treturn err\n\t}\n\tif _, err = store.dataFile.Write([]byte{flag}); err != nil {\n\t\treturn err\n\t}\n\n\t// all clear\n\tstore.ptr = newptr\n\treturn nil\n}", "func (adabasBuffer *Buffer) putCAbd(pabdArray *C.PABD, index int) {\n\tadatypes.Central.Log.Debugf(\"%d: receive index %c len=%d\", index, adabasBuffer.abd.Abdid, len(adabasBuffer.buffer))\n\tvar pbuffer *C.char\n\tadatypes.Central.Log.Debugf(\"Got buffer len=%d\", adabasBuffer.abd.Abdsize)\n\tif adabasBuffer.abd.Abdsize == 0 {\n\t\tpbuffer = nil\n\t} else {\n\t\tpbuffer = (*C.char)(unsafe.Pointer(&adabasBuffer.buffer[0]))\n\t}\n\tcabd := adabasBuffer.abd\n\tvar pabd C.PABD\n\tpabd = (C.PABD)(unsafe.Pointer(&cabd))\n\n\tadatypes.Central.Log.Debugf(\"Work on %c. buffer of size=%d\", cabd.Abdid, len(adabasBuffer.buffer))\n\tC.copy_from_abd(pabdArray, C.int(index), pabd,\n\t\tpbuffer, C.uint32_t(uint32(adabasBuffer.abd.Abdsize)))\n\tadabasBuffer.abd = cabd\n\tif adatypes.Central.IsDebugLevel() {\n\t\tadatypes.Central.Log.Debugf(\"C ABD %c: send=%d recv=%d\", cabd.Abdid, cabd.Abdsend, cabd.Abdrecv)\n\t\tadatypes.LogMultiLineString(true, adatypes.FormatByteBuffer(\"Buffer content:\", adabasBuffer.buffer))\n\t}\n\n}", "func copyToLocation(location uintptr, data []byte) {\n\tf := rawMemoryAccess(location, len(data))\n\n\tmprotectCrossPage(location, len(data), syscall.PROT_READ|syscall.PROT_WRITE|syscall.PROT_EXEC)\n\tcopy(f, data[:])\n\tmprotectCrossPage(location, len(data), syscall.PROT_READ|syscall.PROT_EXEC)\n}", "func (b *mpgBuff) buffer() *concBuff {\n\tif !b.cur {\n\t\treturn b.bufA\n\t}\n\treturn b.bufB\n}", "func (vm *VM) bufferPush(data string) {\n\tnewBuffer := &buffer{\n\t\tprevious: vm.buffer,\n\t\tvalue: data,\n\t}\n\tvm.buffer = newBuffer\n}", "func BufferSubData(target uint32, offset int, size int, data unsafe.Pointer) {\n\tsyscall.Syscall6(gpBufferSubData, 4, uintptr(target), uintptr(offset), uintptr(size), uintptr(data), 0, 0)\n}", "func (o *txSocketQueue) copyToHead(buf []byte) uint32 {\n\tm := o.getOrAllocIndex(&o.head)\n\tfree := o.head.getFree()\n\tz := uint16(minSpace(free, uint32(len(buf))))\n\tm.Append(buf[:z])\n\to.head.Inc(z, o.refSize)\n\treturn uint32(z)\n}", "func (bw *BufferedWriterMongo) writeBuffer() (err error) {\n\n\tif len(bw.buffer) == 0 {\n\t\treturn nil\n\t}\n\n\tcoll := bw.client.Database(bw.db).Collection(bw.collection)\n\t_, err = coll.InsertMany(bw.ctx, bw.buffer)\n\treturn err\n}", "func copyTo(dst []byte, src []byte, offset int) {\n\tfor j, k := range src {\n\t\tdst[offset+j] = k\n\t}\n}", "func Clone(source, destination interface{}) {\n\tif reflect.TypeOf(destination).Kind() != reflect.Ptr {\n\t\tlog.Error(\"storage_drivers.Clone, destination parameter must be a pointer\")\n\t}\n\n\tbuff := new(bytes.Buffer)\n\tenc := gob.NewEncoder(buff)\n\tdec := gob.NewDecoder(buff)\n\tenc.Encode(source)\n\tdec.Decode(destination)\n}", "func (r *Resources) Copy(other *Resources) {\n\tr.CPU = other.CPU\n\tr.DISK = other.DISK\n\tr.MEMORY = other.MEMORY\n\tr.GPU = other.GPU\n}", "func (b *Backend) demote(key fes.Aggregate) {\n\tevents, ok, fromStore := b.get(key)\n\tif !ok || !fromStore {\n\t\treturn\n\t}\n\tdelete(b.store, key)\n\tb.buf.Add(key, events)\n}", "func TestCopy(t *testing.T) {\n\t// Create a random state test to copy and modify \"independently\"\n\torig, _ := New(types.Hash32{}, NewDatabase(database.NewMemDatabase()))\n\n\tfor i := byte(0); i < 255; i++ {\n\t\tobj := orig.GetOrNewStateObj(types.BytesToAddress([]byte{i}))\n\t\tobj.AddBalance(uint64(i))\n\t\torig.updateStateObj(obj)\n\t}\n\n\t// Copy the state, modify both in-memory\n\tcopy := orig.Copy()\n\n\tfor i := byte(0); i < 255; i++ {\n\t\torigObj := orig.GetOrNewStateObj(types.BytesToAddress([]byte{i}))\n\t\tcopyObj := copy.GetOrNewStateObj(types.BytesToAddress([]byte{i}))\n\n\t\torigObj.AddBalance(2 * uint64(i))\n\t\tcopyObj.AddBalance(3 * uint64(i))\n\n\t\torig.updateStateObj(origObj)\n\t\tcopy.updateStateObj(copyObj)\n\t}\n\t// Finalise the changes on both concurrently\n\tdone := make(chan struct{})\n\tgo func() {\n\t\tclose(done)\n\t}()\n\t<-done\n\n\t// Verify that the two states have been updated independently\n\tfor i := byte(0); i < 255; i++ {\n\t\torigObj := orig.GetOrNewStateObj(types.BytesToAddress([]byte{i}))\n\t\tcopyObj := copy.GetOrNewStateObj(types.BytesToAddress([]byte{i}))\n\n\t\tif want := (3 * uint64(i)); origObj.Balance() != want {\n\t\t\tt.Errorf(\"orig obj %d: balance mismatch: have %v, want %v\", i, origObj.Balance(), want)\n\t\t}\n\t\tif want := (4 * uint64(i)); copyObj.Balance() != want {\n\t\t\tt.Errorf(\"copy obj %d: balance mismatch: have %v, want %v\", i, copyObj.Balance(), want)\n\t\t}\n\t}\n}", "func (b *RecordBuffer) Flush() {\n\tb.recordsInBuffer = b.recordsInBuffer[:0]\n\tb.sequencesInBuffer = b.sequencesInBuffer[:0]\n}", "func (pk PacketBuffer) Clone() PacketBuffer {\n\tpk.Data = pk.Data.Clone(nil)\n\treturn pk\n}", "func (_ BufferPtrPool2M) Put(b *[]byte) {\n\tPutBytesSlicePtr2M(b)\n}", "func (rb *RingBuffer) Clone() *RingBuffer {\n\trb.lock.RLock()\n\tdefer rb.lock.RUnlock()\n\tcp := make([]stats.Record, len(rb.data))\n\tcopy(cp, rb.data)\n\treturn &RingBuffer{seq: rb.seq, data: cp}\n}", "func (ms *MemStore) SetAll(data map[string]io.WriterTo) error {\n\tvar err error\n\tms.mu.Lock()\n\tfor k, d := range data {\n\t\tvar buf memio.Buffer\n\t\tif _, err = d.WriteTo(&buf); err != nil {\n\t\t\tbreak\n\t\t}\n\t\tms.data[k] = buf\n\t}\n\tms.mu.Unlock()\n\treturn err\n}", "func (src *Source) SetBuffer(buf []byte) {\n\tsrc.buf = buf\n}", "func storeDiffData(dbContext dbaccess.Context, w *bytes.Buffer, hash *daghash.Hash, diffData *blockUTXODiffData) error {\n\t// To avoid a ton of allocs, use the io.Writer\n\t// instead of allocating one. We expect the buffer to\n\t// already be initialized and, in most cases, to already\n\t// be large enough to accommodate the serialized data\n\t// without growing.\n\terr := serializeBlockUTXODiffData(w, diffData)\n\tif err != nil {\n\t\treturn err\n\t}\n\n\treturn dbaccess.StoreUTXODiffData(dbContext, hash, w.Bytes())\n}", "func CopyObject(srcData []byte, dst interface{}) {\n\tjsoniter.Unmarshal(srcData, dst)\n\t//var dstData, err = jsoniter.Marshal(dst)\n\t//if err != nil {\n\t//\tpanic(err)\n\t//}\n\t//fmt.Println(\"overlay:\", string(dstData))\n}", "func (m *meta) copy(dest *meta) {\n\t*dest = *m\n}", "func (m *meta) copy(dest *meta) {\n\t*dest = *m\n}", "func (m *meta) copy(dest *meta) {\n\t*dest = *m\n}", "func (d *state) copyOut(b []byte) {\n\tfor i := 0; len(b) >= 8; i++ {\n\t\tbinary.LittleEndian.PutUint64(b, d.a[i])\n\t\tb = b[8:]\n\t}\n}", "func (s SafeBuffer) Copy() payload.Safe {\n\tbin := make([]byte, s.Len())\n\tcopy(bin, s.Bytes())\n\n\tb := bytes.NewBuffer(bin)\n\treturn SafeBuffer{*b}\n}", "func (b *Buffer) Attach(buffer []byte) {\n b.AttachBytes(buffer, 0, len(buffer))\n}", "func deepCopy(copy, orig interface{}) error {\n\tvar buf bytes.Buffer\n\tenc := gob.NewEncoder(&buf)\n\tdec := gob.NewDecoder(&buf)\n\terr := enc.Encode(orig)\n\tif err != nil {\n\t\treturn err\n\t}\n\treturn dec.Decode(copy)\n}", "func (b *Buffer) Merge(bs ...Buffer) {\n\tfor _, buf := range bs {\n\t\tfor p, v := range buf.CellMap {\n\t\t\tb.Set(p.X, p.Y, v)\n\t\t}\n\t\tb.SetArea(b.Area.Union(buf.Area))\n\t}\n}", "func (s *ManagerStats) AtomicCopyTo(r *ManagerStats) {\n\trve := reflect.ValueOf(r).Elem()\n\tsve := reflect.ValueOf(s).Elem()\n\tsvet := sve.Type()\n\tfor i := 0; i < svet.NumField(); i++ {\n\t\trvef := rve.Field(i)\n\t\tsvef := sve.Field(i)\n\t\tif rvef.CanAddr() && svef.CanAddr() {\n\t\t\trvefp := rvef.Addr().Interface()\n\t\t\tsvefp := svef.Addr().Interface()\n\t\t\tatomic.StoreUint64(rvefp.(*uint64),\n\t\t\t\tatomic.LoadUint64(svefp.(*uint64)))\n\t\t}\n\t}\n}", "func (bp *bufferPool) putBuffer(b *buffer) {\n\tbp.lock.Lock()\n\tif bp.freeBufNum < 1000 {\n\t\tb.next = bp.freeList\n\t\tbp.freeList = b\n\t\tbp.freeBufNum++\n\t}\n\tbp.lock.Unlock()\n}", "func (c *Counter) Transfer(src *Counter) {\n\tif src.Count == 0 {\n\t\treturn // nothing to do\n\t}\n\tif c.Count == 0 {\n\t\t*c = *src // copy everything at once\n\t\tsrc.Reset()\n\t\treturn\n\t}\n\tc.Count += src.Count\n\tif src.Min < c.Min {\n\t\tc.Min = src.Min\n\t}\n\tif src.Max > c.Max {\n\t\tc.Max = src.Max\n\t}\n\tc.Sum += src.Sum\n\tc.sumOfSquares += src.sumOfSquares\n\tsrc.Reset()\n}", "func XorBuffer(first []byte, second []byte) ([]byte, error) {\n\tif len(first) != len(second) {\n\t\treturn nil, errors.New(\"Buffers are not equal length\")\n\t}\n\n\toutput := make([]byte, len(first))\n\n\tfor idx := range first {\n\t\t// XOR operation\n\t\toutput[idx] = first[idx] ^ second[idx]\n\t}\n\n\treturn output, nil\n}", "func (t *translator) copyBytes(\n\tirBlock *ir.Block, irPtr, irLen irvalue.Value,\n) irvalue.Value {\n\tirNewPtr := irBlock.NewCall(t.builtins.Malloc(t), irLen)\n\tirBlock.NewCall(t.builtins.Memcpy(t), irNewPtr, irPtr, irLen, irconstant.False)\n\treturn irNewPtr\n}", "func (d *DataPacket) copy() DataPacket {\n\tcopySlice := make([]byte, len(d.data))\n\tcopy(copySlice, d.data)\n\treturn DataPacket{\n\t\tdata: copySlice,\n\t\tlength: d.length,\n\t}\n}", "func (_ BufferPtrPool2K) Put(b *[]byte) {\n\tPutBytesSlicePtr2K(b)\n}", "func (o *txSocketQueue) copyFromTail(p *queuePtr, size uint32, tobuf []byte, boffset uint32) uint32 {\n\tm := o.getIndex(p)\n\tfree := p.getFree()\n\tz := uint16(minSpace(free, size))\n\tof := o.tail.getRelativeOffset(p)\n\tcopy(tobuf[boffset:boffset+uint32(z)], m.GetData()[of:of+z])\n\tp.Inc(z, o.refSize)\n\treturn uint32(z)\n}", "func Copy(dst, src interface{}) error {\n\tbuffer := new(bytes.Buffer)\n\tencoder := gob.NewEncoder(buffer)\n\tif err := encoder.Encode(src); err != nil {\n\t\treturn err\n\t}\n\tdecoder := gob.NewDecoder(buffer)\n\terr := decoder.Decode(dst)\n\treturn err\n}", "func (p *movingAverageProcessor) getBufferData(index int, namespace string) interface{} {\n\n\treturn p.movingAverageMap[namespace].movingAverageBuf[index]\n}", "func (keyRing *KeyRing) Copy() (*KeyRing, error) {\n\tnewKeyRing := &KeyRing{}\n\n\tentities := make([]*openpgp.Entity, len(keyRing.entities))\n\tfor id, entity := range keyRing.entities {\n\t\tvar buffer bytes.Buffer\n\t\tvar err error\n\n\t\tif entity.PrivateKey == nil {\n\t\t\terr = entity.Serialize(&buffer)\n\t\t} else {\n\t\t\terr = entity.SerializePrivateWithoutSigning(&buffer, nil)\n\t\t}\n\n\t\tif err != nil {\n\t\t\treturn nil, errors.Wrap(err, \"gopenpgp: unable to copy key: error in serializing entity\")\n\t\t}\n\n\t\tbt := buffer.Bytes()\n\t\tentities[id], err = openpgp.ReadEntity(packet.NewReader(bytes.NewReader(bt)))\n\n\t\tif err != nil {\n\t\t\treturn nil, errors.Wrap(err, \"gopenpgp: unable to copy key: error in reading entity\")\n\t\t}\n\t}\n\tnewKeyRing.entities = entities\n\tnewKeyRing.FirstKeyID = keyRing.FirstKeyID\n\n\treturn newKeyRing, nil\n}", "func (b *buffer) buffer() []byte {\n\treturn b.buf[b.offset:]\n}", "func (_ BufferPtrPool1M) Put(b *[]byte) {\n\tPutBytesSlicePtr1M(b)\n}", "func (self Source) SetBuffer(buffer Buffer) {\n\tself.Seti(AlBuffer, int32(buffer))\n}", "func (s *CollectionStats) AtomicCopyTo(r *CollectionStats) {\n\trve := reflect.ValueOf(r).Elem()\n\tsve := reflect.ValueOf(s).Elem()\n\tsvet := sve.Type()\n\tfor i := 0; i < svet.NumField(); i++ {\n\t\trvef := rve.Field(i)\n\t\tsvef := sve.Field(i)\n\t\tif rvef.CanAddr() && svef.CanAddr() {\n\t\t\trvefp := rvef.Addr().Interface()\n\t\t\tsvefp := svef.Addr().Interface()\n\t\t\tatomic.StoreUint64(rvefp.(*uint64),\n\t\t\t\tatomic.LoadUint64(svefp.(*uint64)))\n\t\t}\n\t}\n}", "func (g *GLTF) loadBuffer(bufIdx int) ([]byte, error) {\n\n\t// Check if provided buffer index is valid\n\tif bufIdx < 0 || bufIdx >= len(g.Buffers) {\n\t\treturn nil, fmt.Errorf(\"invalid buffer index\")\n\t}\n\tbufData := &g.Buffers[bufIdx]\n\t// Return cached if available\n\tif bufData.cache != nil {\n\t\tlog.Debug(\"Fetching Buffer %d (cached)\", bufIdx)\n\t\treturn bufData.cache, nil\n\t}\n\tlog.Debug(\"Loading Buffer %d\", bufIdx)\n\n\t// If buffer URI use the chunk data field\n\tif bufData.Uri == \"\" {\n\t\treturn g.data, nil\n\t}\n\n\t// Checks if buffer URI is a data URI\n\tvar data []byte\n\tvar err error\n\tif isDataURL(bufData.Uri) {\n\t\tdata, err = loadDataURL(bufData.Uri)\n\t} else {\n\t\t// Try to load buffer from file\n\t\tdata, err = g.loadFileBytes(bufData.Uri)\n\t}\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\n\t// Checks data length\n\tif len(data) != bufData.ByteLength {\n\t\treturn nil, fmt.Errorf(\"buffer:%d read data length:%d expected:%d\", bufIdx, len(data), bufData.ByteLength)\n\t}\n\t// Cache buffer data\n\tg.Buffers[bufIdx].cache = data\n\tlog.Debug(\"cache data:%v\", len(bufData.cache))\n\treturn data, nil\n}", "func (al *AudioListener) setBuffer(size int) {\n\tal.Lock()\n\tdefer al.Unlock()\n\n\tal.buffer = make([]gumble.AudioPacket, 0, size)\n}", "func TestDataCopy(t *testing.T) {\n\tb := bytes.Buffer{}\n\tw := NewWriter(&b)\n\tbuf := make([]byte, 8) // can only write 8 bytes at a time\n\n\terr := w.Open(\"[email protected]\", time.Now())\n\tif err != nil {\n\t\tt.Error(err)\n\t}\n\t// wrap in an anonymous struct so that WriteTo is not called. That way buf will get used\n\t_, err = io.CopyBuffer(struct{ io.Writer }{w}, struct{ io.Reader }{bytes.NewReader([]byte(test2))}, buf)\n\tif err != nil {\n\t\tt.Error(err)\n\t}\n\terr = w.Close()\n\tif err != nil {\n\t\tt.Error(err)\n\t}\n\tresult := b.String()\n\tif result[len(result)-1] != '\\n' {\n\t\tt.Error(\"expecting a new line at the end\")\n\t}\n}", "func (g *Gaffer) AddBuffer(u *Update) {\n\n\tfor _, v := range u.entities {\n\t\tg.AddEntity(v)\n\t}\n\n\tfor _, v := range u.edges {\n\t\tg.AddEdge(v)\n\t}\n\n}", "func AssignBuf(dst, src any, buf AccumulativeBuffer) (ok bool) {\n\tfor _, fn := range assignFnRegistry {\n\t\tif ok = fn(dst, src, buf); ok {\n\t\t\treturn\n\t\t}\n\t}\n\treturn\n}", "func (w *Writer) SetBuffer(raw []byte) {\n\tif w.err != nil {\n\t\treturn\n\t}\n\tw.b = w.b[:0]\n\tw.b = append(w.b, raw...)\n}", "func (t treasure) mutate(b []byte) {\n\t// fake treasure\n\tif t.addr.offset == 0 {\n\t\treturn\n\t}\n\n\taddr, data := t.addr.fullOffset(), t.bytes()\n\tfor i := 0; i < 4; i++ {\n\t\tb[addr+i] = data[i]\n\t}\n}", "func MemCopy(dst unsafe.Pointer, src unsafe.Pointer, bytes int) {\n\tfor i := 0; i < bytes; i++ {\n\t\t*(*uint8)(MemAccess(dst, i)) = *(*uint8)(MemAccess(src, i))\n\t}\n}", "func (z *Writer) newBuffers() {\n\tbSize := z.Header.BlockMaxSize\n\tbuf := getBuffer(bSize)\n\tz.data = buf[:bSize] // Uncompressed buffer is the first half.\n}", "func copyContentsLocked(ctx context.Context, upper *Inode, lower *Inode, size int64) error {\n\t// We don't support copying up for anything other than regular files.\n\tif lower.StableAttr.Type != RegularFile {\n\t\treturn nil\n\t}\n\n\t// Get a handle to the upper filesystem, which we will write to.\n\tupperFile, err := overlayFile(ctx, upper, FileFlags{Write: true})\n\tif err != nil {\n\t\treturn err\n\t}\n\tdefer upperFile.DecRef()\n\n\t// Get a handle to the lower filesystem, which we will read from.\n\tlowerFile, err := overlayFile(ctx, lower, FileFlags{Read: true})\n\tif err != nil {\n\t\treturn err\n\t}\n\tdefer lowerFile.DecRef()\n\n\t// Use a buffer pool to minimize allocations.\n\tbuf := copyUpBuffers.Get().([]byte)\n\tdefer copyUpBuffers.Put(buf)\n\n\t// Transfer the contents.\n\t//\n\t// One might be able to optimize this by doing parallel reads, parallel writes and reads, larger\n\t// buffers, etc. But we really don't know anything about the underlying implementation, so these\n\t// optimizations could be self-defeating. So we leave this as simple as possible.\n\tvar offset int64\n\tfor {\n\t\tnr, err := lowerFile.FileOperations.Read(ctx, lowerFile, usermem.BytesIOSequence(buf), offset)\n\t\tif err != nil && err != io.EOF {\n\t\t\treturn err\n\t\t}\n\t\tif nr == 0 {\n\t\t\tif offset != size {\n\t\t\t\t// Same as in cleanupUpper, we cannot live\n\t\t\t\t// with ourselves if we do anything less.\n\t\t\t\tpanic(fmt.Sprintf(\"filesystem is in an inconsistent state: wrote only %d bytes of %d sized file\", offset, size))\n\t\t\t}\n\t\t\treturn nil\n\t\t}\n\t\tnw, err := upperFile.FileOperations.Write(ctx, upperFile, usermem.BytesIOSequence(buf[:nr]), offset)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\toffset += nw\n\t}\n}", "func (pk PacketBufferPtr) DeepCopyForForwarding(reservedHeaderBytes int) PacketBufferPtr {\n\tpayload := BufferSince(pk.NetworkHeader())\n\tdefer payload.Release()\n\tnewPk := NewPacketBuffer(PacketBufferOptions{\n\t\tReserveHeaderBytes: reservedHeaderBytes,\n\t\tPayload: payload.DeepClone(),\n\t\tIsForwardedPacket: true,\n\t})\n\n\t{\n\t\tconsumeBytes := len(pk.NetworkHeader().Slice())\n\t\tif _, consumed := newPk.NetworkHeader().Consume(consumeBytes); !consumed {\n\t\t\tpanic(fmt.Sprintf(\"expected to consume network header %d bytes from new packet\", consumeBytes))\n\t\t}\n\t\tnewPk.NetworkProtocolNumber = pk.NetworkProtocolNumber\n\t}\n\n\t{\n\t\tconsumeBytes := len(pk.TransportHeader().Slice())\n\t\tif _, consumed := newPk.TransportHeader().Consume(consumeBytes); !consumed {\n\t\t\tpanic(fmt.Sprintf(\"expected to consume transport header %d bytes from new packet\", consumeBytes))\n\t\t}\n\t\tnewPk.TransportProtocolNumber = pk.TransportProtocolNumber\n\t}\n\n\tnewPk.tuple = pk.tuple\n\n\treturn newPk\n}", "func (gc gcsClient) Copy(ctx context.Context, from, to Path) (*storage.ObjectAttrs, error) {\n\tclient := gc.clientFromPath(from)\n\treturn client.Copy(ctx, from, to)\n}" ]
[ "0.5799516", "0.5721596", "0.5619362", "0.54738885", "0.54471415", "0.54471415", "0.544204", "0.5382559", "0.5366576", "0.536117", "0.53239393", "0.52760315", "0.5200153", "0.5183052", "0.51771307", "0.51403636", "0.5136153", "0.513369", "0.5115561", "0.51108825", "0.510889", "0.5104054", "0.51023984", "0.5095978", "0.5081903", "0.50807", "0.50730973", "0.5067664", "0.5056293", "0.5054803", "0.50526386", "0.50315213", "0.50263155", "0.50229394", "0.5016877", "0.50043523", "0.50015247", "0.49692664", "0.49615782", "0.49554422", "0.49530077", "0.49519733", "0.4949881", "0.49417964", "0.49378598", "0.4936048", "0.49340457", "0.49262136", "0.49101683", "0.49085113", "0.49077585", "0.49060124", "0.49012125", "0.48948738", "0.48898476", "0.4885725", "0.4883849", "0.48807415", "0.48784792", "0.4876762", "0.48570934", "0.48444465", "0.48366818", "0.4832649", "0.48255685", "0.48255685", "0.48255685", "0.48233542", "0.4823081", "0.4818158", "0.4816891", "0.48127782", "0.48090902", "0.48030263", "0.4797479", "0.47958344", "0.47901604", "0.47799617", "0.47787997", "0.4770037", "0.47678825", "0.47670838", "0.47651726", "0.4751532", "0.4747519", "0.4746212", "0.47442693", "0.47406995", "0.47252697", "0.47212708", "0.47154605", "0.4713264", "0.47130662", "0.47101718", "0.47067443", "0.47025695", "0.46910274", "0.46763757", "0.46717316" ]
0.50033593
37
copy pixels in the frame buffer
func CopyPixels(x int32, y int32, width int32, height int32, xtype uint32) { C.glowCopyPixels(gpCopyPixels, (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(xtype)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func (fr *Frame) Copy(orig *Frame) {\n\tfr.Status = orig.Status\n\tfor y, row := range orig.Pix {\n\t\tcopy(fr.Pix[y][:], row)\n\t}\n}", "func (i *ImageBuf) CopyPixels(src *ImageBuf) error {\n\tok := bool(C.ImageBuf_copy_pixels(i.ptr, src.ptr))\n\truntime.KeepAlive(i)\n\truntime.KeepAlive(src)\n\tif !ok {\n\t\treturn i.LastError()\n\t}\n\treturn nil\n}", "func CopyPixels(x int32, y int32, width int32, height int32, xtype uint32) {\n C.glowCopyPixels(gpCopyPixels, (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(xtype))\n}", "func CopyPixels(x int32, y int32, width int32, height int32, xtype uint32) {\n\tsyscall.Syscall6(gpCopyPixels, 5, uintptr(x), uintptr(y), uintptr(width), uintptr(height), uintptr(xtype), 0)\n}", "func (i *ImageBuf) Copy(src *ImageBuf) error {\n\tok := bool(C.ImageBuf_copy(i.ptr, src.ptr))\n\truntime.KeepAlive(i)\n\truntime.KeepAlive(src)\n\tif !ok {\n\t\treturn i.LastError()\n\t}\n\treturn nil\n}", "func CopyBufferSubData(readTarget uint32, writeTarget uint32, readOffset int, writeOffset int, size int) {\n C.glowCopyBufferSubData(gpCopyBufferSubData, (C.GLenum)(readTarget), (C.GLenum)(writeTarget), (C.GLintptr)(readOffset), (C.GLintptr)(writeOffset), (C.GLsizeiptr)(size))\n}", "func (fr *Frame) CreateCopy() *Frame {\n\tframe := new(Frame)\n\tframe.Pix = make([][]uint16, len(fr.Pix))\n\tfor i := range fr.Pix {\n\t\tframe.Pix[i] = make([]uint16, len(fr.Pix[i]))\n\t}\n\tframe.Copy(fr)\n\treturn frame\n}", "func setPixel(x, y int, c color, pixels []byte) {\n\tindex := (y*windowWidth + x) * 4\n\n\tif index < len(pixels)-4 && index >= 0 {\n\t\tpixels[index] = c.r\n\t\tpixels[index+1] = c.g\n\t\tpixels[index+1] = c.b\n\t}\n}", "func Copy(dst draw.Image, src image.Image) {\n\tbd := src.Bounds().Intersect(dst.Bounds())\n\tat := imageutil.NewAtFunc(src)\n\tset := imageutil.NewSetFunc(dst)\n\timageutil.Parallel1D(bd, func(bd image.Rectangle) {\n\t\tfor y := bd.Min.Y; y < bd.Max.Y; y++ {\n\t\t\tfor x := bd.Min.X; x < bd.Max.X; x++ {\n\t\t\t\tr, g, b, a := at(x, y)\n\t\t\t\tset(x, y, r, g, b, a)\n\t\t\t}\n\t\t}\n\t})\n}", "func (w *windowImpl) Copy(dp image.Point, src screen.Texture, sr image.Rectangle, op draw.Op, opts *screen.DrawOptions) {\n\tpanic(\"not implemented\") // TODO: Implement\n}", "func CopyBufferSubData(readTarget uint32, writeTarget uint32, readOffset int, writeOffset int, size int) {\n\tC.glowCopyBufferSubData(gpCopyBufferSubData, (C.GLenum)(readTarget), (C.GLenum)(writeTarget), (C.GLintptr)(readOffset), (C.GLintptr)(writeOffset), (C.GLsizeiptr)(size))\n}", "func CopyBufferSubData(readTarget uint32, writeTarget uint32, readOffset int, writeOffset int, size int) {\n\tC.glowCopyBufferSubData(gpCopyBufferSubData, (C.GLenum)(readTarget), (C.GLenum)(writeTarget), (C.GLintptr)(readOffset), (C.GLintptr)(writeOffset), (C.GLsizeiptr)(size))\n}", "func (i *Image) readPixelsFromGPU() error {\n\tvar err error\n\ti.basePixels, err = i.image.Pixels()\n\tif err != nil {\n\t\treturn err\n\t}\n\ti.drawImageHistory = nil\n\ti.stale = false\n\treturn nil\n}", "func Copy(i ImageIr) ImageIr {\n\tc := make([][][]uint32, len(i.pixels))\n\tcopy(c, i.pixels)\n\treturn ImageIr{i.width, i.height, c}\n}", "func (c *Container) setBitmapCopy(bitmap []uint64) {\n\tvar bitmapCopy [bitmapN]uint64\n\tcopy(bitmapCopy[:], bitmap)\n\tc.setBitmap(bitmapCopy[:])\n}", "func putPixel(screen []byte, color color, x int, y int) {\n\tscreenX := (windowWidth / 2) + x\n\tscreenY := (windowHeight / 2) - y - 1\n\tbase := (screenY*windowWidth + screenX) * 4\n\tscreen[base] = color.r\n\tscreen[base+1] = color.g\n\tscreen[base+2] = color.b\n\tscreen[base+3] = 0xFF\n\tscreen[0] = 0xFF\n}", "func SetPixel(n, r, g, b uint8) {\n\tbuffer[n*3] = g\n\tbuffer[n*3+1] = r\n\tbuffer[n*3+2] = b\n}", "func (self *TraitPixbuf) Copy() (return__ *Pixbuf) {\n\tvar __cgo__return__ *C.GdkPixbuf\n\t__cgo__return__ = C.gdk_pixbuf_copy(self.CPointer)\n\tif __cgo__return__ != nil {\n\t\treturn__ = NewPixbufFromCPointer(unsafe.Pointer(reflect.ValueOf(__cgo__return__).Pointer()))\n\t}\n\treturn\n}", "func BlitFramebuffer(srcX0 int32, srcY0 int32, srcX1 int32, srcY1 int32, dstX0 int32, dstY0 int32, dstX1 int32, dstY1 int32, mask uint32, filter uint32) {\n C.glowBlitFramebuffer(gpBlitFramebuffer, (C.GLint)(srcX0), (C.GLint)(srcY0), (C.GLint)(srcX1), (C.GLint)(srcY1), (C.GLint)(dstX0), (C.GLint)(dstY0), (C.GLint)(dstX1), (C.GLint)(dstY1), (C.GLbitfield)(mask), (C.GLenum)(filter))\n}", "func (s *Surface) Copy() *Surface {\n\tr := s.Rect()\n\tcopy := NewSurface(int(r.W), int(r.H))\n\tcopy.Blit(s, 0, 0)\n\treturn copy\n}", "func CopyBufferSubData(readTarget uint32, writeTarget uint32, readOffset int, writeOffset int, size int) {\n\tsyscall.Syscall6(gpCopyBufferSubData, 5, uintptr(readTarget), uintptr(writeTarget), uintptr(readOffset), uintptr(writeOffset), uintptr(size), 0)\n}", "func (img *ByteImage) pixels() [][]byte {\n\tbyteIdx := 0\n\tpixels := make([][]byte, img.height)\n\tfor rowIdx := 0; rowIdx < img.height; rowIdx++ {\n\t\tpixels[rowIdx] = make([]byte, img.width)\n\t\tfor colIdx := 0; colIdx < img.width; colIdx++ {\n\t\t\tpixels[rowIdx][colIdx] = img.bytes[byteIdx]\n\t\t\tbyteIdx++\n\t\t}\n\t}\n\treturn pixels\n}", "func clone(dst, src *image.Gray) {\n\tif dst.Stride == src.Stride {\n\t\t// no need to correct stride, simply copy pixels.\n\t\tcopy(dst.Pix, src.Pix)\n\t\treturn\n\t}\n\t// need to correct stride.\n\tfor i := 0; i < src.Rect.Dy(); i++ {\n\t\tdstH := i * dst.Stride\n\t\tsrcH := i * src.Stride\n\t\tcopy(dst.Pix[dstH:dstH+dst.Stride], src.Pix[srcH:srcH+dst.Stride])\n\t}\n}", "func ReadPixels(dst []byte, x, y, width, height int, format, ty Enum) {\n\tgl.ReadPixels(int32(x), int32(y), int32(width), int32(height), uint32(format), uint32(ty), gl.Ptr(&dst[0]))\n}", "func (c *Canvas) copyTo(offset image.Point, dstSetCell setCellFunc) error {\n\tfor col := range c.buffer {\n\t\tfor row := range c.buffer[col] {\n\t\t\tpartial, err := c.buffer.IsPartial(image.Point{col, row})\n\t\t\tif err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\t\t\tif partial {\n\t\t\t\t// Skip over partial cells, i.e. cells that follow a cell\n\t\t\t\t// containing a full-width rune. A full-width rune takes only\n\t\t\t\t// one cell in the buffer, but two on the terminal.\n\t\t\t\t// See http://www.unicode.org/reports/tr11/.\n\t\t\t\tcontinue\n\t\t\t}\n\t\t\tcell := c.buffer[col][row]\n\t\t\tp := image.Point{col, row}.Add(offset)\n\t\t\tif err := dstSetCell(p, cell.Rune, cell.Opts); err != nil {\n\t\t\t\treturn fmt.Errorf(\"setCellFunc%v => error: %v\", p, err)\n\t\t\t}\n\t\t}\n\t}\n\treturn nil\n}", "func (s *Surface) Blit(source *Surface, x, y float64) {\n\ts.Ctx.Call(\"drawImage\", source.Canvas, math.Floor(x), math.Floor(y))\n}", "func CopyImageSubData(srcName uint32, srcTarget uint32, srcLevel int32, srcX int32, srcY int32, srcZ int32, dstName uint32, dstTarget uint32, dstLevel int32, dstX int32, dstY int32, dstZ int32, srcWidth int32, srcHeight int32, srcDepth int32) {\n C.glowCopyImageSubData(gpCopyImageSubData, (C.GLuint)(srcName), (C.GLenum)(srcTarget), (C.GLint)(srcLevel), (C.GLint)(srcX), (C.GLint)(srcY), (C.GLint)(srcZ), (C.GLuint)(dstName), (C.GLenum)(dstTarget), (C.GLint)(dstLevel), (C.GLint)(dstX), (C.GLint)(dstY), (C.GLint)(dstZ), (C.GLsizei)(srcWidth), (C.GLsizei)(srcHeight), (C.GLsizei)(srcDepth))\n}", "func (s *stencilOverdraw) copyImageAspect(ctx context.Context,\n\tcb CommandBuilder,\n\tgs *api.GlobalState,\n\tst *State,\n\ta arena.Arena,\n\tdevice VkDevice,\n\tcmdBuffer VkCommandBuffer,\n\tsrcImgDesc imageDesc,\n\tdstImgDesc imageDesc,\n\textent VkExtent3D,\n\talloc func(v ...interface{}) api.AllocResult,\n\taddCleanup func(func()),\n\tout transform.Writer,\n) {\n\tsrcImg := srcImgDesc.image\n\tdstImg := dstImgDesc.image\n\tcopyBuffer := s.createDepthCopyBuffer(ctx, cb, gs, st, a, device,\n\t\tsrcImg.Info().Fmt(),\n\t\textent.Width(), extent.Height(),\n\t\talloc, addCleanup, out)\n\n\tallCommandsStage := VkPipelineStageFlags(\n\t\tVkPipelineStageFlagBits_VK_PIPELINE_STAGE_ALL_COMMANDS_BIT)\n\tallMemoryAccess := VkAccessFlags(\n\t\tVkAccessFlagBits_VK_ACCESS_MEMORY_WRITE_BIT |\n\t\t\tVkAccessFlagBits_VK_ACCESS_MEMORY_READ_BIT)\n\n\timgBarriers0 := make([]VkImageMemoryBarrier, 2)\n\timgBarriers1 := make([]VkImageMemoryBarrier, 2)\n\t// Transition the src image in and out of the required layouts\n\timgBarriers0[0] = NewVkImageMemoryBarrier(a,\n\t\tVkStructureType_VK_STRUCTURE_TYPE_IMAGE_MEMORY_BARRIER, // sType\n\t\t0, // pNext\n\t\tallMemoryAccess, // srcAccessMask\n\t\tVkAccessFlags(VkAccessFlagBits_VK_ACCESS_TRANSFER_READ_BIT), // dstAccessMask\n\t\tsrcImgDesc.layout, // oldLayout\n\t\tVkImageLayout_VK_IMAGE_LAYOUT_TRANSFER_SRC_OPTIMAL, // newLayout\n\t\t^uint32(0), // srcQueueFamilyIndex: VK_QUEUE_FAMILY_IGNORED\n\t\t^uint32(0), // dstQueueFamilyIndex\n\t\tsrcImg.VulkanHandle(), // image\n\t\tsrcImgDesc.subresource, // subresourceRange\n\t)\n\tsrcFinalLayout := srcImgDesc.layout\n\tif srcFinalLayout == VkImageLayout_VK_IMAGE_LAYOUT_UNDEFINED ||\n\t\tsrcFinalLayout == VkImageLayout_VK_IMAGE_LAYOUT_PREINITIALIZED {\n\t\tsrcFinalLayout = VkImageLayout_VK_IMAGE_LAYOUT_GENERAL\n\t}\n\timgBarriers1[0] = NewVkImageMemoryBarrier(a,\n\t\tVkStructureType_VK_STRUCTURE_TYPE_IMAGE_MEMORY_BARRIER, // sType\n\t\t0, // pNext\n\t\tVkAccessFlags(VkAccessFlagBits_VK_ACCESS_TRANSFER_READ_BIT), // srcAccessMask\n\t\tallMemoryAccess, // dstAccessMask\n\t\tVkImageLayout_VK_IMAGE_LAYOUT_TRANSFER_SRC_OPTIMAL, // oldLayout\n\t\tsrcFinalLayout, // newLayout\n\t\t^uint32(0), // srcQueueFamilyIndex: VK_QUEUE_FAMILY_IGNORED\n\t\t^uint32(0), // dstQueueFamilyIndex\n\t\tsrcImg.VulkanHandle(), // image\n\t\tsrcImgDesc.subresource, // subresourceRange\n\t)\n\n\t// Transition the new image in and out of its required layouts\n\timgBarriers0[1] = NewVkImageMemoryBarrier(a,\n\t\tVkStructureType_VK_STRUCTURE_TYPE_IMAGE_MEMORY_BARRIER, // sType\n\t\t0, // pNext\n\t\tallMemoryAccess, // srcAccessMask\n\t\tVkAccessFlags(VkAccessFlagBits_VK_ACCESS_TRANSFER_WRITE_BIT), // dstAccessMask\n\t\tdstImgDesc.layout, // oldLayout\n\t\tVkImageLayout_VK_IMAGE_LAYOUT_TRANSFER_DST_OPTIMAL, // newLayout\n\t\t^uint32(0), // srcQueueFamilyIndex: VK_QUEUE_FAMILY_IGNORED\n\t\t^uint32(0), // dstQueueFamilyIndex\n\t\tdstImg.VulkanHandle(), // image\n\t\tdstImgDesc.subresource, // subresourceRange\n\t)\n\n\tdstFinalLayout := dstImgDesc.layout\n\tif dstFinalLayout == VkImageLayout_VK_IMAGE_LAYOUT_UNDEFINED ||\n\t\tdstFinalLayout == VkImageLayout_VK_IMAGE_LAYOUT_PREINITIALIZED {\n\t\tdstFinalLayout = VkImageLayout_VK_IMAGE_LAYOUT_GENERAL\n\t}\n\timgBarriers1[1] = NewVkImageMemoryBarrier(a,\n\t\tVkStructureType_VK_STRUCTURE_TYPE_IMAGE_MEMORY_BARRIER, // sType\n\t\t0, // pNext\n\t\tVkAccessFlags(VkAccessFlagBits_VK_ACCESS_TRANSFER_WRITE_BIT), // srcAccessMask\n\t\tallMemoryAccess, // dstAccessMask\n\t\tVkImageLayout_VK_IMAGE_LAYOUT_TRANSFER_DST_OPTIMAL, // oldLayout\n\t\tdstFinalLayout, // newLayout\n\t\t^uint32(0), // srcQueueFamilyIndex: VK_QUEUE_FAMILY_IGNORED\n\t\t^uint32(0), // dstQueueFamilyIndex\n\t\tdstImg.VulkanHandle(), // image\n\t\tdstImgDesc.subresource, // subresourceRange\n\t)\n\n\tbufBarrier := NewVkBufferMemoryBarrier(a,\n\t\tVkStructureType_VK_STRUCTURE_TYPE_BUFFER_MEMORY_BARRIER, // sType\n\t\t0, // pNext\n\t\tVkAccessFlags(VkAccessFlagBits_VK_ACCESS_TRANSFER_WRITE_BIT), // srcAccessMask\n\t\tVkAccessFlags(VkAccessFlagBits_VK_ACCESS_TRANSFER_READ_BIT), // dstAccessMask\n\t\t^uint32(0), // srcQueueFamilyIndex: VK_QUEUE_FAMILY_IGNORED\n\t\t^uint32(0), // dstQueueFamilyIndex\n\t\tcopyBuffer, // buffer\n\t\t0, // offset\n\t\t^VkDeviceSize(0), // size: VK_WHOLE_SIZE\n\t)\n\n\tibCopy := NewVkBufferImageCopy(a,\n\t\t0, // bufferOffset\n\t\t0, // bufferRowLength\n\t\t0, // bufferImageHeight\n\t\tNewVkImageSubresourceLayers(a,\n\t\t\tVkImageAspectFlags(srcImgDesc.aspect), // aspectMask\n\t\t\tsrcImgDesc.subresource.BaseMipLevel(), // mipLevel\n\t\t\tsrcImgDesc.subresource.BaseArrayLayer(), // baseArrayLayer\n\t\t\t1, // layerCount\n\t\t), // srcSubresource\n\t\tNewVkOffset3D(a, 0, 0, 0), // offset\n\t\tNewVkExtent3D(a, extent.Width(), extent.Height(), 1), // extent\n\t)\n\n\tbiCopy := NewVkBufferImageCopy(a,\n\t\t0, // bufferOffset\n\t\t0, // bufferRowLength\n\t\t0, // bufferImageHeight\n\t\tNewVkImageSubresourceLayers(a,\n\t\t\tVkImageAspectFlags(dstImgDesc.aspect), // aspectMask\n\t\t\tdstImgDesc.subresource.BaseMipLevel(), // mipLevel\n\t\t\tdstImgDesc.subresource.BaseArrayLayer(), // baseArrayLayer\n\t\t\t1, // layerCount\n\t\t), // srcSubresource\n\t\tNewVkOffset3D(a, 0, 0, 0), // offset\n\t\tNewVkExtent3D(a, extent.Width(), extent.Height(), 1), // extent\n\t)\n\n\timgBarriers0Data := alloc(imgBarriers0)\n\tibCopyData := alloc(ibCopy)\n\tbufBarrierData := alloc(bufBarrier)\n\tbiCopyData := alloc(biCopy)\n\timgBarriers1Data := alloc(imgBarriers1)\n\n\twriteEach(ctx, out,\n\t\tcb.VkCmdPipelineBarrier(cmdBuffer,\n\t\t\tallCommandsStage, // srcStageMask\n\t\t\tVkPipelineStageFlags(VkPipelineStageFlagBits_VK_PIPELINE_STAGE_TRANSFER_BIT), // dstStageMask\n\t\t\t0, // dependencyFlags\n\t\t\t0, // memoryBarrierCount\n\t\t\tmemory.Nullptr, // pMemoryBarriers\n\t\t\t0, // bufferMemoryBarrierCount\n\t\t\tmemory.Nullptr, // pBufferMemoryBarriers\n\t\t\t2, // imageMemoryBarrierCount\n\t\t\timgBarriers0Data.Ptr(), // pImageMemoryBarriers\n\t\t).AddRead(imgBarriers0Data.Data()),\n\t\tcb.VkCmdCopyImageToBuffer(cmdBuffer,\n\t\t\tsrcImg.VulkanHandle(), // srcImage\n\t\t\tVkImageLayout_VK_IMAGE_LAYOUT_TRANSFER_SRC_OPTIMAL, // srcImageLayout\n\t\t\tcopyBuffer, // dstBuffer\n\t\t\t1, // regionCount\n\t\t\tibCopyData.Ptr(), // pRegions\n\t\t).AddRead(ibCopyData.Data()),\n\t\tcb.VkCmdPipelineBarrier(cmdBuffer,\n\t\t\tVkPipelineStageFlags(VkPipelineStageFlagBits_VK_PIPELINE_STAGE_TRANSFER_BIT), // srcStageMask\n\t\t\tVkPipelineStageFlags(VkPipelineStageFlagBits_VK_PIPELINE_STAGE_TRANSFER_BIT), // dstStageMask\n\t\t\t0, // dependencyFlags\n\t\t\t0, // memoryBarrierCount\n\t\t\tmemory.Nullptr, // pMemoryBarriers\n\t\t\t1, // bufferMemoryBarrierCount\n\t\t\tbufBarrierData.Ptr(), // pBufferMemoryBarriers\n\t\t\t0, // imageMemoryBarrierCount\n\t\t\tmemory.Nullptr, // pImageMemoryBarriers\n\t\t).AddRead(bufBarrierData.Data()),\n\t\tcb.VkCmdCopyBufferToImage(cmdBuffer,\n\t\t\tcopyBuffer, // srcBuffer\n\t\t\tdstImg.VulkanHandle(), // dstImage\n\t\t\tVkImageLayout_VK_IMAGE_LAYOUT_TRANSFER_DST_OPTIMAL, // dstImageLayout\n\t\t\t1, // regionCount\n\t\t\tbiCopyData.Ptr(), // pRegions\n\t\t).AddRead(biCopyData.Data()),\n\t\tcb.VkCmdPipelineBarrier(cmdBuffer,\n\t\t\tVkPipelineStageFlags(VkPipelineStageFlagBits_VK_PIPELINE_STAGE_TRANSFER_BIT), // srcStageMask\n\t\t\tallCommandsStage, // dstStageMask\n\t\t\t0, // dependencyFlags\n\t\t\t0, // memoryBarrierCount\n\t\t\tmemory.Nullptr, // pMemoryBarriers\n\t\t\t0, // bufferMemoryBarrierCount\n\t\t\tmemory.Nullptr, // pBufferMemoryBarriers\n\t\t\t2, // imageMemoryBarrierCount\n\t\t\timgBarriers1Data.Ptr(), // pImageMemoryBarriers\n\t\t).AddRead(imgBarriers1Data.Data()),\n\t)\n}", "func (c *Canvas) SetPixels(pixels []uint8) {\n\tc.gf.Dirty()\n\n\tmainthread.Call(func() {\n\t\ttex := c.Texture()\n\t\ttex.Begin()\n\t\ttex.SetPixels(0, 0, tex.Width(), tex.Height(), pixels)\n\t\ttex.End()\n\t})\n}", "func PMOVZXBW(mx, x operand.Op) { ctx.PMOVZXBW(mx, x) }", "func copyImg(filename string, rowX int, colX int) string {\n\t//Filename path\n\tpath := \"/gorpc/Images/\" + filename\n\n\t//Extract matrix of image file data\n\tpixels := gocv.IMRead(path, 1)\n\n\t//Get dimensions from picture\n\tdimensions := pixels.Size()\n\theight := dimensions[0]\n\twidth := dimensions[1]\n\n\t//Get type of mat\n\tmatType := pixels.Type()\n\n\t//Create a new mat to fill\n\tbigMat := gocv.NewMatWithSize(height * rowX, width * colX, matType)\n\n\t//Created a wait group to sync filling images\n\twg := sync.WaitGroup{}\n\twg.Add(rowX * colX)\n\n\t//Fill in image copies by relative index on matrix\n\tfor i := 0; i < rowX; i++{\n\t\tfor j := 0; j < colX; j++{\n\t\t\tgo func (i int, j int){\n\t\t\t\t//Decrement counter if an image copy is made\n\t\t\t\tdefer wg.Done()\n\n\t\t\t\t//Iterate over original image and store in new index copy\n\t\t\t\tfor x := 0; x < height; x++{\n\t\t\t\t\tfor y := 0; y < width; y++{\n\t\t\t\t\t\tval := GetVecbAt(pixels, x, y)\n\n\t\t\t\t\t\tval.SetVecbAt(bigMat, (i*height) + x, (j*width) + y)\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}(i, j)\n\t\t}\n\t}\n\n\t//Wait till all copies are filled in\n\twg.Wait()\n\n\t//Remove extension from filename\n\text := filepath.Ext(filename)\n\tname := strings.TrimSuffix(filename, ext)\n\n\t//Rename the new scaled image\n\tnewName := name + \"C\" + ext\n\n\t//New path\n\tnewPath := \"/gorpc/Images/\" + newName\n\n\t//Save the new image from matrix in local directory\n\tgocv.IMWrite(newPath, bigMat)\n\n\treturn newName\n}", "func qr_decoder_set_image_buffer(p _QrDecoderHandle, src *_IplImage) _QrDecoderHandle {\n\tv := C.qr_decoder_set_image_buffer(C.QrDecoderHandle(p), (*C.IplImage)(src))\n\treturn _QrDecoderHandle(v)\n}", "func MemCopy(dst unsafe.Pointer, src unsafe.Pointer, bytes int) {\n\tfor i := 0; i < bytes; i++ {\n\t\t*(*uint8)(MemAccess(dst, i)) = *(*uint8)(MemAccess(src, i))\n\t}\n}", "func (r *Relay) copyWithBuffer(dst io.Writer, src io.Reader, buf []byte) (written int64, err error) {\n\tfor {\n\t\tnr, er := src.Read(buf)\n\t\tif nr > 0 {\n\t\t\tnw, ew := dst.Write(buf[0:nr])\n\t\t\tif nw < 0 || nr < nw {\n\t\t\t\tnw = 0\n\t\t\t\tif ew == nil {\n\t\t\t\t\tew = errInvalidWrite\n\t\t\t\t}\n\t\t\t}\n\t\t\twritten += int64(nw)\n\t\t\tif ew != nil {\n\t\t\t\terr = ew\n\t\t\t\tbreak\n\t\t\t}\n\t\t\tif nr != nw {\n\t\t\t\terr = io.ErrShortWrite\n\t\t\t\tbreak\n\t\t\t}\n\t\t\tif r.metricsTracer != nil {\n\t\t\t\tr.metricsTracer.BytesTransferred(nw)\n\t\t\t}\n\t\t}\n\t\tif er != nil {\n\t\t\tif er != io.EOF {\n\t\t\t\terr = er\n\t\t\t}\n\t\t\tbreak\n\t\t}\n\t}\n\treturn written, err\n}", "func (t *translator) copyBytes(\n\tirBlock *ir.Block, irPtr, irLen irvalue.Value,\n) irvalue.Value {\n\tirNewPtr := irBlock.NewCall(t.builtins.Malloc(t), irLen)\n\tirBlock.NewCall(t.builtins.Memcpy(t), irNewPtr, irPtr, irLen, irconstant.False)\n\treturn irNewPtr\n}", "func setPixel(x, y int, c color, pixels []byte) error {\n\tindex := (y*int(winWidth) + x) * 4\n\n\tif index > len(pixels) || index < 0 {\n\t\t// simple string-based error\n\t\treturn fmt.Errorf(\"the pixel index is not valid, index: %d\", index)\n\t}\n\n\tif index < len(pixels) && index >= 0 {\n\t\tpixels[index] = c.r\n\t\tpixels[index+1] = c.g\n\t\tpixels[index+2] = c.b\n\t}\n\n\treturn nil\n}", "func setPixel(x, y int, c color, pixels []byte) error {\n\tindex := (y*int(winWidth) + x) * 4\n\n\tif index > len(pixels) || index < 0 {\n\t\t// simple string-based error\n\t\treturn fmt.Errorf(\"the pixel index is not valid, index: %d\", index)\n\t}\n\n\tif index < len(pixels) && index >= 0 {\n\t\tpixels[index] = c.r\n\t\tpixels[index+1] = c.g\n\t\tpixels[index+2] = c.b\n\t}\n\n\treturn nil\n}", "func (w *WebGLRenderTarget) Copy(source *WebGLRenderTarget) *WebGLRenderTarget {\n\tw.p.Call(\"copy\", source.p)\n\treturn w\n}", "func (fb FrameBuffer) ColorAt(x int, y int) color.Color {\n\tc := fb.img.At(x, y)\n\treturn c\n}", "func (driver *S3Driver) CopyBuffer(dst io.Writer, src io.Reader, buf []byte) (written int64, err error) {\r\n\tif buf != nil && len(buf) == 0 {\r\n\t\tpanic(\"empty buffer in io.CopyBuffer\")\r\n\t}\r\n\treturn copyBuffer(dst, src, buf)\r\n}", "func copyBuffer(dst io.Writer, src io.Reader, buf []byte) error {\n\tfor {\n\t\tnr, rerr := src.Read(buf)\n\t\tif nr > 0 {\n\t\t\tnw, werr := dst.Write(buf[:nr])\n\t\t\tif werr != nil {\n\t\t\t\treturn werr\n\t\t\t}\n\t\t\tif nr != nw {\n\t\t\t\treturn io.ErrShortWrite\n\t\t\t}\n\t\t}\n\t\tif rerr != nil {\n\t\t\tif rerr == io.EOF {\n\t\t\t\trerr = nil\n\t\t\t}\n\t\t\treturn rerr\n\t\t}\n\t}\n}", "func CopyTexImage2D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, height int32, border int32) {\n\tsyscall.Syscall9(gpCopyTexImage2D, 8, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(x), uintptr(y), uintptr(width), uintptr(height), uintptr(border), 0)\n}", "func memcpy(dst, src unsafe.Pointer, size uintptr)", "func BlitFramebuffer(srcX0 int32, srcY0 int32, srcX1 int32, srcY1 int32, dstX0 int32, dstY0 int32, dstX1 int32, dstY1 int32, mask uint32, filter uint32) {\n\tsyscall.Syscall12(gpBlitFramebuffer, 10, uintptr(srcX0), uintptr(srcY0), uintptr(srcX1), uintptr(srcY1), uintptr(dstX0), uintptr(dstY0), uintptr(dstX1), uintptr(dstY1), uintptr(mask), uintptr(filter), 0, 0)\n}", "func TestReadPixelsFromVolatileImage(t *testing.T) {\n\tconst w, h = 16, 16\n\tdst := restorable.NewImage(w, h, restorable.ImageTypeVolatile)\n\tsrc := restorable.NewImage(w, h, restorable.ImageTypeRegular)\n\n\t// First, make sure that dst has pixels\n\tdst.WritePixels(make([]byte, 4*w*h), image.Rect(0, 0, w, h))\n\n\t// Second, draw src to dst. If the implementation is correct, dst becomes stale.\n\tpix := make([]byte, 4*w*h)\n\tfor i := range pix {\n\t\tpix[i] = 0xff\n\t}\n\tsrc.WritePixels(pix, image.Rect(0, 0, w, h))\n\tvs := quadVertices(1, 1, 0, 0)\n\tis := graphics.QuadIndices()\n\tdr := graphicsdriver.Region{\n\t\tX: 0,\n\t\tY: 0,\n\t\tWidth: w,\n\t\tHeight: h,\n\t}\n\tdst.DrawTriangles([graphics.ShaderImageCount]*restorable.Image{src}, vs, is, graphicsdriver.BlendCopy, dr, [graphics.ShaderImageCount]graphicsdriver.Region{}, restorable.NearestFilterShader, nil, false)\n\n\t// Read the pixels. If the implementation is correct, dst tries to read its pixels from GPU due to being\n\t// stale.\n\twant := byte(0xff)\n\n\tvar result [4]byte\n\tif err := dst.ReadPixels(ui.GraphicsDriverForTesting(), result[:], image.Rect(0, 0, 1, 1)); err != nil {\n\t\tt.Fatal(err)\n\t}\n\tgot := result[0]\n\tif got != want {\n\t\tt.Errorf(\"got: %v, want: %v\", got, want)\n\t}\n}", "func (spr *Sprite) DrawFrame(c *Canvas, bmp *Bitmap, x, y, frame, row int32, flip Flip) {\n\n\tc.DrawBitmapRegion(bmp,\n\t\tframe*spr.width, row*spr.height,\n\t\tspr.width, spr.height,\n\t\tx, y, flip)\n}", "func (f *Frame) Crop(w, h, xOffset, yOffset int) error {\n\tif w+xOffset > f.Width {\n\t\treturn fmt.Errorf(\"cropped width + x offset (%d) cannot exceed original width (%d)\",\n\t\t\tw+xOffset, f.Width)\n\t}\n\tif h+yOffset > f.Height {\n\t\treturn fmt.Errorf(\"cropped height + y offset (%d) cannot exceed original height (%d)\",\n\t\t\th+yOffset, f.Height)\n\t}\n\tnewY := make([]byte, 0, w*h)\n\tfor y := 0; y < h; y++ {\n\t\tyt := y + yOffset\n\t\tx0 := yt*f.Width + xOffset\n\t\tx1 := x0 + w\n\t\tnewY = append(newY, f.Y[x0:x1]...)\n\t}\n\tf.Y = newY\n\txss := xSubsamplingFactor[f.Chroma]\n\tyss := ySubsamplingFactor[f.Chroma]\n\tnewCb := make([]byte, 0, w/xss*h/yss)\n\tnewCr := make([]byte, 0, w/xss*h/yss)\n\tfor y := 0; y < h/yss; y++ {\n\t\tyt := y + yOffset/yss\n\t\tx0 := yt*f.Width/xss + xOffset/xss\n\t\tx1 := x0 + w/xss\n\t\tnewCb = append(newCb, f.Cb[x0:x1]...)\n\t\tnewCr = append(newCr, f.Cr[x0:x1]...)\n\t}\n\tf.Cb = newCb\n\tf.Cr = newCr\n\tif len(f.Alpha) > 0 {\n\t\tnewAlpha := make([]byte, 0, w*h)\n\t\tfor y := 0; y < h; y++ {\n\t\t\tyt := y + yOffset\n\t\t\tx0 := yt*f.Width + xOffset\n\t\t\tx1 := x0 + w\n\t\t\tnewAlpha = append(newAlpha, f.Alpha[x0:x1]...)\n\t\t}\n\t\tf.Alpha = newAlpha\n\t}\n\tf.Width = w\n\tf.Height = h\n\treturn nil\n}", "func CopyTexImage2D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, height int32, border int32) {\n C.glowCopyTexImage2D(gpCopyTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border))\n}", "func draw(window *glfw.Window, reactProg, landProg uint32) {\n\n\tvar renderLoops = 4\n\tfor i := 0; i < renderLoops; i++ {\n\t\t// -- DRAW TO BUFFER --\n\t\t// define destination of pixels\n\t\t//gl.BindFramebuffer(gl.FRAMEBUFFER, 0)\n\t\tgl.BindFramebuffer(gl.FRAMEBUFFER, FBO[1])\n\n\t\tgl.Viewport(0, 0, width, height) // Retina display doubles the framebuffer !?!\n\n\t\tgl.Clear(gl.COLOR_BUFFER_BIT | gl.DEPTH_BUFFER_BIT)\n\t\tgl.UseProgram(reactProg)\n\n\t\t// bind Texture\n\t\tgl.ActiveTexture(gl.TEXTURE0)\n\t\tgl.BindTexture(gl.TEXTURE_2D, renderedTexture)\n\t\tgl.Uniform1i(uniTex, 0)\n\n\t\tgl.BindVertexArray(VAO)\n\t\tgl.DrawElements(gl.TRIANGLE_STRIP, int32(len(indices)), gl.UNSIGNED_INT, nil)\n\n\t\tgl.BindVertexArray(0)\n\n\t\t// -- copy back textures --\n\t\tgl.BindFramebuffer(gl.READ_FRAMEBUFFER, FBO[1]) // source is high res array\n\t\tgl.ReadBuffer(gl.COLOR_ATTACHMENT0)\n\t\tgl.BindFramebuffer(gl.DRAW_FRAMEBUFFER, FBO[0]) // destination is cells array\n\t\tgl.DrawBuffer(gl.COLOR_ATTACHMENT0)\n\t\tgl.BlitFramebuffer(0, 0, width, height,\n\t\t\t0, 0, cols, rows,\n\t\t\tgl.COLOR_BUFFER_BIT, gl.NEAREST) // downsample\n\t\tgl.BindFramebuffer(gl.READ_FRAMEBUFFER, FBO[0]) // source is low res array - put in texture\n\t\t// read pixels saves data read as unsigned bytes and then loads them in TexImage same way\n\t\tgl.ReadPixels(0, 0, cols, rows, gl.RGBA, gl.FLOAT, gl.Ptr(fData))\n\t\tgl.BindTexture(gl.TEXTURE_2D, renderedTexture)\n\t\tgl.TexImage2D(gl.TEXTURE_2D, 0, gl.RGBA, cols, rows, 0, gl.RGBA, gl.FLOAT, gl.Ptr(fData))\n\t\tCheckGLErrors()\n\t}\n\t// -- DRAW TO SCREEN --\n\tvar model glm.Mat4\n\n\t// destination 0 means screen\n\tgl.BindFramebuffer(gl.FRAMEBUFFER, 0)\n\tgl.Viewport(0, 0, width*2, height*2) // Retina display doubles the framebuffer !?!\n\tgl.Clear(gl.COLOR_BUFFER_BIT | gl.DEPTH_BUFFER_BIT)\n\tgl.UseProgram(landProg)\n\t// bind Texture\n\tgl.ActiveTexture(gl.TEXTURE0)\n\tgl.BindTexture(gl.TEXTURE_2D, drawTexture)\n\n\tvar view glm.Mat4\n\tvar brakeFactor = float64(20000.0)\n\tvar xCoord, yCoord float32\n\txCoord = float32(-3.0 * math.Sin(float64(myClock)))\n\tyCoord = float32(-3.0 * math.Cos(float64(myClock)))\n\t//xCoord = 0.0\n\t//yCoord = float32(-2.5)\n\tmyClock = math.Mod((myClock + float64(deltaTime)/brakeFactor), (math.Pi * 2))\n\tview = glm.LookAt(xCoord, yCoord, 2.0, 0.0, 0.0, 0.0, 0.0, 0.0, 1.0)\n\tgl.UniformMatrix4fv(uniView, 1, false, &view[0])\n\tmodel = glm.HomogRotate3DX(glm.DegToRad(00.0))\n\tgl.UniformMatrix4fv(uniModel, 1, false, &model[0])\n\tgl.Uniform1i(uniTex2, 0)\n\n\t// render container\n\t//gl.PolygonMode(gl.FRONT_AND_BACK, gl.FILL)\n\t//gl.PolygonMode(gl.FRONT_AND_BACK, gl.LINE)\n\n\tgl.BindVertexArray(VAO)\n\tgl.DrawElements(gl.TRIANGLE_STRIP, int32(len(indices)), gl.UNSIGNED_INT, nil)\n\tgl.BindVertexArray(0)\n\n\tCheckGLErrors()\n\n\tglfw.PollEvents()\n\twindow.SwapBuffers()\n\n\t//time.Sleep(100 * 1000 * 1000)\n}", "func BenchmarkMemcopy(b *testing.B) {\n\tlen := 1920 * 1080 * 3 / 2\n\tdst := make([]byte, len, len)\n\tb.ResetTimer()\n\tfor i := 0; i < b.N; i++ {\n\t\tfor j := 0; j < len; j++ {\n\t\t\tdst[i] = 100\n\t\t}\n\t}\n}", "func copyBuffer(dst io.Writer, src io.Reader, buf []byte) (written int64, err error) {\r\n\t// If the reader has a WriteTo method, use it to do the copy.\r\n\t// Avoids an allocation and a copy.\r\n\t// if wt, ok := src.(io.WriterTo); ok {\r\n\t// \treturn wt.WriteTo(dst)\r\n\t// }\r\n\r\n\t// Similarly, if the writer has a ReadFrom method, use it to do the copy.\r\n\t// if rt, ok := dst.(io.ReaderFrom); ok {\r\n\t// \treturn rt.ReadFrom(src)\r\n\t// }\r\n\r\n\tif buf == nil {\r\n\t\tbuf = make([]byte, 32*1024)\r\n\t\t//buf = make([]byte, 5*1024*1024)\r\n\t}\r\n\r\n\tfor {\r\n\t\tnr, er := src.Read(buf)\r\n\t\tif nr > 0 {\r\n\t\t\tnw, ew := dst.Write(buf[0:nr])\r\n\t\t\tif nw > 0 {\r\n\t\t\t\twritten += int64(nw)\r\n\t\t\t}\r\n\t\t\tif ew != nil {\r\n\t\t\t\terr = ew\r\n\t\t\t\tbreak\r\n\t\t\t}\r\n\t\t\tif nr != nw {\r\n\t\t\t\terr = io.ErrShortWrite\r\n\t\t\t\tbreak\r\n\t\t\t}\r\n\t\t}\r\n\t\tif er == io.EOF {\r\n\t\t\tbreak\r\n\t\t}\r\n\t\tif er != nil {\r\n\t\t\terr = er\r\n\t\t\tbreak\r\n\t\t}\r\n\t}\r\n\treturn written, err\r\n}", "func (b *XMobileBackend) PutImageData(img *image.RGBA, x, y int) {\n\tb.activate()\n\n\tb.glctx.ActiveTexture(gl.TEXTURE0)\n\tif b.imageBufTex.Value == 0 {\n\t\tb.imageBufTex = b.glctx.CreateTexture()\n\t\tb.glctx.BindTexture(gl.TEXTURE_2D, b.imageBufTex)\n\t\tb.glctx.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.LINEAR)\n\t\tb.glctx.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, gl.LINEAR)\n\t\tb.glctx.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_S, gl.CLAMP_TO_EDGE)\n\t\tb.glctx.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_T, gl.CLAMP_TO_EDGE)\n\t} else {\n\t\tb.glctx.BindTexture(gl.TEXTURE_2D, b.imageBufTex)\n\t}\n\n\tw, h := img.Bounds().Dx(), img.Bounds().Dy()\n\n\tif img.Stride == img.Bounds().Dx()*4 {\n\t\tb.glctx.TexImage2D(gl.TEXTURE_2D, 0, gl.RGBA, w, h, gl.RGBA, gl.UNSIGNED_BYTE, img.Pix[0:])\n\t} else {\n\t\tdata := make([]uint8, 0, w*h*4)\n\t\tfor cy := 0; cy < h; cy++ {\n\t\t\tstart := cy * img.Stride\n\t\t\tend := start + w*4\n\t\t\tdata = append(data, img.Pix[start:end]...)\n\t\t}\n\t\tb.glctx.TexImage2D(gl.TEXTURE_2D, 0, gl.RGBA, w, h, gl.RGBA, gl.UNSIGNED_BYTE, data[0:])\n\t}\n\n\tdx, dy := float32(x), float32(y)\n\tdw, dh := float32(w), float32(h)\n\n\tb.glctx.BindBuffer(gl.ARRAY_BUFFER, b.buf)\n\tdata := [16]float32{dx, dy, dx + dw, dy, dx + dw, dy + dh, dx, dy + dh,\n\t\t0, 0, 1, 0, 1, 1, 0, 1}\n\tb.glctx.BufferData(gl.ARRAY_BUFFER, byteSlice(unsafe.Pointer(&data[0]), len(data)*4), gl.STREAM_DRAW)\n\n\tb.glctx.UseProgram(b.shd.ID)\n\tb.glctx.Uniform1i(b.shd.Image, 0)\n\tb.glctx.Uniform2f(b.shd.CanvasSize, float32(b.fw), float32(b.fh))\n\tb.glctx.UniformMatrix3fv(b.shd.Matrix, mat3identity[:])\n\tb.glctx.Uniform1f(b.shd.GlobalAlpha, 1)\n\tb.glctx.Uniform1i(b.shd.UseAlphaTex, 0)\n\tb.glctx.Uniform1i(b.shd.Func, shdFuncImage)\n\tb.glctx.VertexAttribPointer(b.shd.Vertex, 2, gl.FLOAT, false, 0, 0)\n\tb.glctx.VertexAttribPointer(b.shd.TexCoord, 2, gl.FLOAT, false, 0, 8*4)\n\tb.glctx.EnableVertexAttribArray(b.shd.Vertex)\n\tb.glctx.EnableVertexAttribArray(b.shd.TexCoord)\n\tb.glctx.DrawArrays(gl.TRIANGLE_FAN, 0, 4)\n\tb.glctx.DisableVertexAttribArray(b.shd.Vertex)\n\tb.glctx.DisableVertexAttribArray(b.shd.TexCoord)\n}", "func (destination *streamDestination) copyAndResetBuffer() []byte {\n\tif len(destination.buffer) > 0 {\n\t\tmsg := make([]byte, len(destination.buffer))\n\t\tcopy(msg, destination.buffer)\n\n\t\tdestination.buffer = destination.buffer[:0]\n\t\treturn msg\n\t}\n\n\treturn []byte{}\n}", "func (c *Camera) Copy() *Camera {\n\treturn &Camera{\n\t\tObject: c.Object.Copy(),\n\t\tProjection: c.Projection,\n\t}\n}", "func (b *Bitmap) Buffer() []byte {\n\tl := b.Rows() * b.Pitch()\n\treturn C.GoBytes(unsafe.Pointer(b.handle.buffer), C.int(l))\n}", "func CopyTexImage2D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, height int32, border int32) {\n\tC.glowCopyTexImage2D(gpCopyTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border))\n}", "func CopyTexImage2D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, height int32, border int32) {\n\tC.glowCopyTexImage2D(gpCopyTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border))\n}", "func (self *TileSprite) CanvasBuffer() *PIXICanvasBuffer{\n return &PIXICanvasBuffer{self.Object.Get(\"canvasBuffer\")}\n}", "func CopyImageSubData(srcName uint32, srcTarget uint32, srcLevel int32, srcX int32, srcY int32, srcZ int32, dstName uint32, dstTarget uint32, dstLevel int32, dstX int32, dstY int32, dstZ int32, srcWidth int32, srcHeight int32, srcDepth int32) {\n\tC.glowCopyImageSubData(gpCopyImageSubData, (C.GLuint)(srcName), (C.GLenum)(srcTarget), (C.GLint)(srcLevel), (C.GLint)(srcX), (C.GLint)(srcY), (C.GLint)(srcZ), (C.GLuint)(dstName), (C.GLenum)(dstTarget), (C.GLint)(dstLevel), (C.GLint)(dstX), (C.GLint)(dstY), (C.GLint)(dstZ), (C.GLsizei)(srcWidth), (C.GLsizei)(srcHeight), (C.GLsizei)(srcDepth))\n}", "func CopyImageSubData(srcName uint32, srcTarget uint32, srcLevel int32, srcX int32, srcY int32, srcZ int32, dstName uint32, dstTarget uint32, dstLevel int32, dstX int32, dstY int32, dstZ int32, srcWidth int32, srcHeight int32, srcDepth int32) {\n\tC.glowCopyImageSubData(gpCopyImageSubData, (C.GLuint)(srcName), (C.GLenum)(srcTarget), (C.GLint)(srcLevel), (C.GLint)(srcX), (C.GLint)(srcY), (C.GLint)(srcZ), (C.GLuint)(dstName), (C.GLenum)(dstTarget), (C.GLint)(dstLevel), (C.GLint)(dstX), (C.GLint)(dstY), (C.GLint)(dstZ), (C.GLsizei)(srcWidth), (C.GLsizei)(srcHeight), (C.GLsizei)(srcDepth))\n}", "func (s *Sprite) GetPixels() []byte {\n\treturn s.surf.Pixels()\n}", "func CopyTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n C.glowCopyTexSubImage2D(gpCopyTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func (self *TileSprite) SetCanvasBufferA(member *PIXICanvasBuffer) {\n self.Object.Set(\"canvasBuffer\", member)\n}", "func (h Handler) copyBuffer(dst io.Writer, src io.Reader, buf []byte) (int64, error) {\n\tif len(buf) == 0 {\n\t\tbuf = make([]byte, defaultBufferSize)\n\t}\n\tvar written int64\n\tfor {\n\t\tnr, rerr := src.Read(buf)\n\t\tif rerr != nil && rerr != io.EOF && rerr != context.Canceled {\n\t\t\t// TODO: this could be useful to know (indeed, it revealed an error in our\n\t\t\t// fastcgi PoC earlier; but it's this single error report here that necessitates\n\t\t\t// a function separate from io.CopyBuffer, since io.CopyBuffer does not distinguish\n\t\t\t// between read or write errors; in a reverse proxy situation, write errors are not\n\t\t\t// something we need to report to the client, but read errors are a problem on our\n\t\t\t// end for sure. so we need to decide what we want.)\n\t\t\t// p.logf(\"copyBuffer: ReverseProxy read error during body copy: %v\", rerr)\n\t\t\th.logger.Error(\"reading from backend\", zap.Error(rerr))\n\t\t}\n\t\tif nr > 0 {\n\t\t\tnw, werr := dst.Write(buf[:nr])\n\t\t\tif nw > 0 {\n\t\t\t\twritten += int64(nw)\n\t\t\t}\n\t\t\tif werr != nil {\n\t\t\t\treturn written, fmt.Errorf(\"writing: %w\", werr)\n\t\t\t}\n\t\t\tif nr != nw {\n\t\t\t\treturn written, io.ErrShortWrite\n\t\t\t}\n\t\t}\n\t\tif rerr != nil {\n\t\t\tif rerr == io.EOF {\n\t\t\t\treturn written, nil\n\t\t\t}\n\t\t\treturn written, fmt.Errorf(\"reading: %w\", rerr)\n\t\t}\n\t}\n}", "func copyStreamToDMABuf(w gpiostream.Stream, dst []uint32) error {\n\tswitch v := w.(type) {\n\tcase *gpiostream.BitStream:\n\t\tif v.LSBF {\n\t\t\treturn errors.New(\"TODO(simokawa): handle BitStream.LSBF\")\n\t\t}\n\t\t// This is big-endian and MSB first.\n\t\ti := 0\n\t\tfor ; i < len(v.Bits)/4; i++ {\n\t\t\tdst[i] = binary.BigEndian.Uint32(v.Bits[i*4:])\n\t\t}\n\t\tlast := uint32(0)\n\t\tif mod := len(v.Bits) % 4; mod > 0 {\n\t\t\tfor j := 0; j < mod; j++ {\n\t\t\t\tlast |= (uint32(v.Bits[i*4+j])) << uint32(8*(3-j))\n\t\t\t}\n\t\t\tdst[i] = last\n\t\t}\n\t\treturn nil\n\tcase *gpiostream.EdgeStream:\n\t\treturn errors.New(\"TODO(simokawa): handle EdgeStream\")\n\tdefault:\n\t\treturn errors.New(\"unsupported Stream type\")\n\t}\n}", "func (c *ChromaHighlight) ClrBuffer() {\n\tswitch c.srcBuff {\n\tcase nil:\n\t\tc.txtBuff.Delete(c.txtBuff.GetStartIter(), c.txtBuff.GetEndIter())\n\tdefault:\n\t\tc.srcBuff.Delete(c.srcBuff.GetStartIter(), c.srcBuff.GetEndIter())\n\t}\n}", "func ReadPixels(x, y, width, height, format, formatType int) []byte {\n\tsize := uint32((width - x) * (height - y) * 4)\n\tgobuf = make([]byte, size+1)\n\n\tptr := (*byte)(unsafe.Pointer(&gobuf[0]))\n\tgl.ReadPixels(int32(x), int32(y), int32(width), int32(height), uint32(format), uint32(formatType), unsafe.Pointer(ptr))\n\treturn gobuf[:size]\n}", "func (cs *cpuState) Framebuffer() []byte {\n\treturn cs.LCD.framebuffer[:]\n}", "func copyBuffer(dst io.Writer, src io.Reader, buf []byte) (written int64, err error) {\n\n\tfor {\n\t\tnr, er := src.Read(buf)\n\n\t\t// break on any read error (and also on EOF)\n\t\tif er != nil {\n\t\t\terr = er\n\t\t\tbreak\n\t\t}\n\n\t\tif nr > 0 {\n\t\t\tnw, ew := dst.Write(buf[0:nr])\n\t\t\tif nw > 0 {\n\t\t\t\twritten += int64(nw)\n\t\t\t}\n\t\t\tif ew != nil {\n\t\t\t\terr = ew\n\t\t\t\tbreak\n\t\t\t}\n\t\t\tif nr != nw {\n\t\t\t\terr = io.ErrShortWrite\n\t\t\t\tbreak\n\t\t\t}\n\t\t}\n\n\t}\n\treturn written, err\n}", "func CopySource(buffer int, src <-chan data.Data, done <- chan bool)[]data.Data{\n\tout := make([]data.Data,buffer)\n\n\tfunc(){ //no go\n\t\tfor i := 0; i < buffer; i++{\n\t\t\tselect{\n\t\t\tcase <-done:\n\t\t\t\treturn\n\t\t\tcase out[i] = <-src:\n\t\t\t}\n\t\t}\n\t}()\n\treturn out\n}", "func CopyTexImage2D(target Enum, level Int, internalformat Enum, x Int, y Int, width Sizei, height Sizei, border Int) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tclevel, _ := (C.GLint)(level), cgoAllocsUnknown\n\tcinternalformat, _ := (C.GLenum)(internalformat), cgoAllocsUnknown\n\tcx, _ := (C.GLint)(x), cgoAllocsUnknown\n\tcy, _ := (C.GLint)(y), cgoAllocsUnknown\n\tcwidth, _ := (C.GLsizei)(width), cgoAllocsUnknown\n\tcheight, _ := (C.GLsizei)(height), cgoAllocsUnknown\n\tcborder, _ := (C.GLint)(border), cgoAllocsUnknown\n\tC.glCopyTexImage2D(ctarget, clevel, cinternalformat, cx, cy, cwidth, cheight, cborder)\n}", "func CopyContext(hglrcSrc unsafe.Pointer, hglrcDst unsafe.Pointer, mask unsafe.Pointer) unsafe.Pointer {\n\tret, _, _ := syscall.Syscall(gpCopyContext, 3, uintptr(hglrcSrc), uintptr(hglrcDst), uintptr(mask))\n\treturn (unsafe.Pointer)(ret)\n}", "func CopyTexSubImage1D(target uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n C.glowCopyTexSubImage1D(gpCopyTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func (native *OpenGL) BlitFramebuffer(srcX0 int32, srcY0 int32, srcX1 int32, srcY1 int32, dstX0 int32, dstY0 int32, dstX1 int32, dstY1 int32, mask uint32, filter uint32) {\n\tgl.BlitFramebuffer(srcX0, srcY0, srcX1, srcY1, dstX0, dstY0, dstX1, dstY1, mask, filter)\n}", "func copyBuffer(dst io.Writer, src io.Reader, buf []byte) (written int64, err error) {\n\tif buf == nil {\n\t\tbuf = make([]byte, 32*1024)\n\t}\n\tfor {\n\t\tnr, er := src.Read(buf)\n\t\tif nr > 0 {\n\t\t\tnw, ew := dst.Write(buf[0:nr])\n\t\t\tif nw > 0 {\n\t\t\t\twritten += int64(nw)\n\t\t\t}\n\t\t\tif ew != nil {\n\t\t\t\terr = ew\n\t\t\t\tbreak\n\t\t\t}\n\t\t\tif nr != nw {\n\t\t\t\terr = io.ErrShortWrite\n\t\t\t\tbreak\n\t\t\t}\n\t\t}\n\t\tif er == io.EOF {\n\t\t\tbreak\n\t\t}\n\t\tif er != nil {\n\t\t\terr = er\n\t\t\tbreak\n\t\t}\n\t}\n\treturn written, err\n}", "func BlitFramebuffer(srcX0 int32, srcY0 int32, srcX1 int32, srcY1 int32, dstX0 int32, dstY0 int32, dstX1 int32, dstY1 int32, mask uint32, filter uint32) {\n\tC.glowBlitFramebuffer(gpBlitFramebuffer, (C.GLint)(srcX0), (C.GLint)(srcY0), (C.GLint)(srcX1), (C.GLint)(srcY1), (C.GLint)(dstX0), (C.GLint)(dstY0), (C.GLint)(dstX1), (C.GLint)(dstY1), (C.GLbitfield)(mask), (C.GLenum)(filter))\n}", "func BlitFramebuffer(srcX0 int32, srcY0 int32, srcX1 int32, srcY1 int32, dstX0 int32, dstY0 int32, dstX1 int32, dstY1 int32, mask uint32, filter uint32) {\n\tC.glowBlitFramebuffer(gpBlitFramebuffer, (C.GLint)(srcX0), (C.GLint)(srcY0), (C.GLint)(srcX1), (C.GLint)(srcY1), (C.GLint)(dstX0), (C.GLint)(dstY0), (C.GLint)(dstX1), (C.GLint)(dstY1), (C.GLbitfield)(mask), (C.GLenum)(filter))\n}", "func (b *Buffer) Dump() {\n\ts := *b.screen\n\traster := canvas.NewRasterFromImage(b.context.Image())\n\ts.SetContent(raster)\n}", "func (i *Image) ReplacePixels(pixels []byte, x, y, width, height int) {\n\tw, h := i.image.Size()\n\tif width <= 0 || height <= 0 {\n\t\tpanic(\"restorable: width/height must be positive\")\n\t}\n\tif x < 0 || y < 0 || w <= x || h <= y || x+width <= 0 || y+height <= 0 || w < x+width || h < y+height {\n\t\tpanic(fmt.Sprintf(\"restorable: out of range x: %d, y: %d, width: %d, height: %d\", x, y, width, height))\n\t}\n\n\t// TODO: Avoid making other images stale if possible. (#514)\n\t// For this purpuse, images should remember which part of that is used for DrawImage.\n\ttheImages.makeStaleIfDependingOn(i)\n\n\tif pixels != nil {\n\t\ti.image.ReplacePixels(pixels, x, y, width, height)\n\t} else {\n\t\t// There is not 'drawImageHistoryItem' for this image and dummyImage.\n\t\t// This means dummyImage might not be restored yet when this image is restored.\n\t\t// However, that's ok since this image will be stale or have updated pixel data\n\t\t// and this image can be restored without dummyImage.\n\t\tw, h := dummyImage.Size()\n\t\tgeom := (*affine.GeoM)(nil).Scale(float64(width)/float64(w), float64(height)/float64(h))\n\t\tgeom = geom.Translate(float64(x), float64(y))\n\t\tcolorm := (*affine.ColorM)(nil).Scale(0, 0, 0, 0)\n\t\tvs := vertices(w, h, 0, 0, w, h, geom)\n\t\ti.image.DrawImage(dummyImage.image, vs, colorm, opengl.CompositeModeCopy, graphics.FilterNearest)\n\t}\n\n\tif x == 0 && y == 0 && width == w && height == h {\n\t\tif i.basePixels == nil {\n\t\t\ti.basePixels = make([]byte, 4*w*h)\n\t\t}\n\t\tcopy(i.basePixels, pixels)\n\t\ti.drawImageHistory = nil\n\t\ti.stale = false\n\t\treturn\n\t}\n\tif i.basePixels == nil {\n\t\ti.makeStale()\n\t\treturn\n\t}\n\tif len(i.drawImageHistory) > 0 {\n\t\ti.makeStale()\n\t\treturn\n\t}\n\tidx := 4 * (y*w + x)\n\tif pixels != nil {\n\t\tfor j := 0; j < height; j++ {\n\t\t\tcopy(i.basePixels[idx:idx+4*width], pixels[4*j*width:4*(j+1)*width])\n\t\t\tidx += 4 * w\n\t\t}\n\t} else {\n\t\tzeros := make([]byte, 4*width)\n\t\tfor j := 0; j < height; j++ {\n\t\t\tcopy(i.basePixels[idx:idx+4*width], zeros)\n\t\t\tidx += 4 * w\n\t\t}\n\t}\n\ti.stale = false\n}", "func (t *Texture) GetPixels() []rgb565.Rgb565Color {\n\tnewArray := make([]rgb565.Rgb565Color, len(t.pixels))\n\tcopy(newArray, t.pixels)\n\treturn newArray\n}", "func (bio *BinaryIO) Copy(dst int64, src int64, count int) error {\n\tbuf := makeBuf(count)\n\tfor count > 0 {\n\t\tbuf = truncBuf(buf, count)\n\t\tbio.ReadAt(src, buf)\n\t\tbio.WriteAt(dst, buf)\n\t\tcount -= len(buf)\n\t\tsrc += int64(len(buf))\n\t\tdst += int64(len(buf))\n\t}\n\treturn nil\n}", "func (d *Display) resetBuffer() {\n\td.width = d.device.Width()\n\td.height = d.device.Height()\n\td.buffer = make([][]byte, d.height)\n\tfor y := range d.buffer {\n\t\td.buffer[y] = make([]byte, d.width)\n\t}\n}", "func copyByte(dst io.Writer, src io.Reader, errChan chan<- error) {\n\t// If the reader has a WriteTo method, use it to do the copy.\n\t// Avoids an allocation and a copy.\n\tif wt, ok := src.(io.WriterTo); ok {\n\t\t_, err := wt.WriteTo(dst)\n\t\tif err != nil {\n\t\t\terrChan <- err\n\t\t}\n\t\treturn\n\t}\n\t// Similarly, if the writer has a ReadFrom method, use it to do the copy.\n\tif rt, ok := dst.(io.ReaderFrom); ok {\n\t\t_, err := rt.ReadFrom(src)\n\t\tif err != nil {\n\t\t\terrChan <- err\n\t\t}\n\t\treturn\n\t}\n\n\t// fallback to standard io.CopyBuffer\n\tbuf := make([]byte, bufSize)\n\t_, err := io.CopyBuffer(dst, src, buf)\n\tif err != nil {\n\t\terrChan <- err\n\t}\n}", "func GetPixel(n uint8) (r, g, b uint8) {\n\treturn buffer[n*3+1], buffer[n*3], buffer[n*3+2]\n}", "func (b *Buffer) CopyDataFrom(src *Buffer, srcOffset, dstOffset, size int) error {\n\tif size == 0 {\n\t\treturn nil\n\t}\n\n\terrCode := cl.EnqueueCopyBuffer(\n\t\tb.device.cmdQueue,\n\t\tsrc.bufHandle,\n\t\tb.bufHandle,\n\t\tuint64(srcOffset),\n\t\tuint64(dstOffset),\n\t\tuint64(size),\n\t\t0,\n\t\tnil,\n\t\tnil,\n\t)\n\n\tif errCode != cl.SUCCESS {\n\t\treturn fmt.Errorf(\"opencl device(%s): error copying device data from buffer %s to buffer %s (errCode %d)\", b.device.Name, src.name, b.name, errCode)\n\t}\n\treturn nil\n}", "func VPMOVZXBW(ops ...operand.Op) { ctx.VPMOVZXBW(ops...) }", "func (this *BytesPool) Copy(dst io.Writer, src io.Reader) (nwrote int64, err error) {\n\tbb := this.Get()\n\tnwrote, err = io.CopyBuffer(dst, src, bb)\n\tthis.Put(bb)\n\treturn\n}", "func DecodePixelsFromImage(img image.Image, offsetX, offsetY int) []*Pixel {\n var pixels []*Pixel\n\n for y := 0; y <= img.Bounds().Max.Y; y++ {\n for x := 0; x <= img.Bounds().Max.X; x++ {\n p := &Pixel{\n Point: image.Point{X: x + offsetX, Y: y + offsetY},\n Color: img.At(x, y),\n }\n pixels = append(pixels, p)\n }\n }\n\n return pixels\n}", "func CopyColorTable(target uint32, internalformat uint32, x int32, y int32, width int32) {\n C.glowCopyColorTable(gpCopyColorTable, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func BufferSubData(target uint32, offset int, size int, data unsafe.Pointer) {\n C.glowBufferSubData(gpBufferSubData, (C.GLenum)(target), (C.GLintptr)(offset), (C.GLsizeiptr)(size), data)\n}", "func CopyColorSubTable(target uint32, start int32, x int32, y int32, width int32) {\n C.glowCopyColorSubTable(gpCopyColorSubTable, (C.GLenum)(target), (C.GLsizei)(start), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func (image *Image2D) GetData() []uint8 {\n\tcpy := make([]uint8, len(image.data))\n\tcopy(cpy, image.data)\n\treturn cpy\n}", "func CopyWithBuffer(ctx context.Context, teeReader *TeeReader, buf []byte) ErrorHandle {\n\terrChan := make(chan error, 1)\n\tgo copySingle(ctx, teeReader, buf, errChan)\n\treturn func() error {\n\t\treturn <-errChan\n\t}\n}", "func (p *PdfiumImplementation) FPDFBitmap_GetBuffer(request *requests.FPDFBitmap_GetBuffer) (*responses.FPDFBitmap_GetBuffer, error) {\n\tp.Lock()\n\tdefer p.Unlock()\n\n\tbitmapHandle, err := p.getBitmapHandle(request.Bitmap)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\n\t// We need to calculate the buffer size, this is stride (bytes per bitmap line) * height.\n\tstride := C.FPDFBitmap_GetStride(bitmapHandle.handle)\n\theight := C.FPDFBitmap_GetHeight(bitmapHandle.handle)\n\tsize := int(stride * height)\n\n\t// The pointer to the first byte of the bitmap buffer.\n\tbuffer := C.FPDFBitmap_GetBuffer(bitmapHandle.handle)\n\n\t// We create a Go slice backed by a C array (without copying the original data).\n\tdata := unsafe.Slice((*byte)(unsafe.Pointer(buffer)), uint64(size))\n\n\treturn &responses.FPDFBitmap_GetBuffer{\n\t\tBuffer: data,\n\t}, nil\n}", "func CopyNamedBufferSubData(readBuffer uint32, writeBuffer uint32, readOffset int, writeOffset int, size int) {\n\tC.glowCopyNamedBufferSubData(gpCopyNamedBufferSubData, (C.GLuint)(readBuffer), (C.GLuint)(writeBuffer), (C.GLintptr)(readOffset), (C.GLintptr)(writeOffset), (C.GLsizeiptr)(size))\n}", "func CopyNamedBufferSubData(readBuffer uint32, writeBuffer uint32, readOffset int, writeOffset int, size int) {\n\tC.glowCopyNamedBufferSubData(gpCopyNamedBufferSubData, (C.GLuint)(readBuffer), (C.GLuint)(writeBuffer), (C.GLintptr)(readOffset), (C.GLintptr)(writeOffset), (C.GLsizeiptr)(size))\n}", "func CopyTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n\tsyscall.Syscall9(gpCopyTexSubImage2D, 8, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(x), uintptr(y), uintptr(width), uintptr(height), 0)\n}", "func (rr *RawVideoReader) Frame() *RGB24 {\n\trr.lock.Lock()\n\tdefer rr.lock.Unlock()\n\n\tif rr.frame == nil {\n\t\treturn nil\n\t}\n\n\t// log.Printf(\"length of frame: %d\", len(rr.frame))\n\n\tf := make([]byte, len(rr.frame))\n\tcopy(f, rr.frame)\n\n\treturn FromRaw(f, rr.Stride, rr.Cols, rr.Rows)\n}", "func (grabber *Grabber) Grab() image.Image {\n\twidth := grabber.img.Rect.Max.X\n\theight := grabber.img.Rect.Max.Y\n\n\tvar header BITMAPINFOHEADER\n\theader.BiSize = uint32(unsafe.Sizeof(header))\n\theader.BiPlanes = 1\n\theader.BiBitCount = 32\n\theader.BiWidth = int32(width)\n\theader.BiHeight = int32(-height)\n\theader.BiCompression = BI_RGB\n\theader.BiSizeImage = 0\n\n\tBitBlt(grabber.memDC, 0, 0, width, height, grabber.winDC, grabber.xVirt, grabber.yVirt, SRCCOPY)\n\n\tbufferAddr := uintptr(unsafe.Pointer(&(grabber.buffer[0])))\n\talignedAddr := ((bufferAddr + 3) / 4) * 4\n\t_, _ = SelectObject(grabber.memDC, grabber.oldBmp)\n\tGetDIBits(grabber.memDC, grabber.bmp, 0, uint32(height), unsafe.Pointer(alignedAddr), &header, DIB_RGB_COLORS)\n\t_, _ = SelectObject(grabber.memDC, HGDIOBJ(grabber.bmp))\n\ti := 0\n\tsrcBuffer := grabber.buffer[alignedAddr-bufferAddr:]\n\tfor y := 0; y < height; y++ {\n\t\tfor x := 0; x < width; x++ {\n\t\t\t// BGRA => RGBA, and set A to 255\n\t\t\tgrabber.img.Pix[i], grabber.img.Pix[i+1], grabber.img.Pix[i+2], grabber.img.Pix[i+3] =\n\t\t\t\tsrcBuffer[i+2], srcBuffer[i+1], srcBuffer[i], 255\n\t\t\ti += 4\n\t\t}\n\t}\n\n\treturn grabber.img\n}", "func (p *Plasma) Draw(screen *ebiten.Image) {\r\n\tscreen.ReplacePixels(p.buffer)\r\n}" ]
[ "0.70778525", "0.6495085", "0.6318463", "0.6159934", "0.60476214", "0.59904885", "0.583665", "0.5807401", "0.574611", "0.5655295", "0.5654111", "0.5654111", "0.56520694", "0.5638904", "0.5596805", "0.55832887", "0.54648066", "0.54232603", "0.5363651", "0.53552353", "0.5327665", "0.52783173", "0.5258699", "0.5239355", "0.52316797", "0.52100056", "0.52019364", "0.51835835", "0.5182214", "0.5168842", "0.51616865", "0.511499", "0.5103974", "0.5101651", "0.5101411", "0.5095362", "0.5095362", "0.5089908", "0.50867033", "0.5058925", "0.5047891", "0.503549", "0.5011702", "0.499644", "0.49930555", "0.49698725", "0.49675086", "0.49668178", "0.49324235", "0.49270692", "0.49158272", "0.49144793", "0.49063474", "0.48841992", "0.48727623", "0.48679987", "0.48679987", "0.4866917", "0.48667863", "0.48667863", "0.4853944", "0.484402", "0.48429248", "0.48428383", "0.48380932", "0.4833912", "0.4833277", "0.48310095", "0.48298815", "0.48183244", "0.4810056", "0.48072225", "0.48044044", "0.47930092", "0.47888747", "0.47888705", "0.47888705", "0.47784987", "0.47778964", "0.47599593", "0.4733988", "0.47322404", "0.47236443", "0.47196", "0.4715364", "0.469965", "0.46836287", "0.46777922", "0.46704218", "0.46519512", "0.46484643", "0.46478534", "0.46432877", "0.46388736", "0.463205", "0.463205", "0.46305165", "0.46215138", "0.46205983", "0.46167922" ]
0.60939634
4
copy pixels into a 1D texture image
func CopyTexImage1D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, border int32) { C.glowCopyTexImage1D(gpCopyTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLint)(border)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func CopyTextureSubImage1D(texture uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tsyscall.Syscall6(gpCopyTextureSubImage1D, 6, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(x), uintptr(y), uintptr(width))\n}", "func CopyTextureSubImage1D(texture uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tC.glowCopyTextureSubImage1D(gpCopyTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func CopyTextureSubImage1D(texture uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tC.glowCopyTextureSubImage1D(gpCopyTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func CopyTexImage1D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, border int32) {\n C.glowCopyTexImage1D(gpCopyTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLint)(border))\n}", "func CopyTexImage1D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, border int32) {\n\tsyscall.Syscall9(gpCopyTexImage1D, 7, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(x), uintptr(y), uintptr(width), uintptr(border), 0, 0)\n}", "func CopyTexSubImage1D(target uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n C.glowCopyTexSubImage1D(gpCopyTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func TexImage1D(target uint32, level int32, internalformat int32, width int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexImage1D(gpTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTextureSubImage1D, 7, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(width), uintptr(format), uintptr(xtype), uintptr(pixels), 0, 0)\n}", "func TexImage1D(target uint32, level int32, internalformat int32, width int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexImage1D(gpTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexImage1D(target uint32, level int32, internalformat int32, width int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexImage1D(gpTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexImage1D(target uint32, level int32, internalformat int32, width int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTexImage1D, 8, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(width), uintptr(border), uintptr(format), uintptr(xtype), uintptr(pixels), 0)\n}", "func TexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexSubImage1D(gpTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage1D(gpTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage1D(gpTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CopyTexImage2D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, height int32, border int32) {\n C.glowCopyTexImage2D(gpCopyTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border))\n}", "func CopyTexSubImage1D(target uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tC.glowCopyTexSubImage1D(gpCopyTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func CopyTexSubImage1D(target uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tC.glowCopyTexSubImage1D(gpCopyTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func CopyTexSubImage1D(target uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tsyscall.Syscall6(gpCopyTexSubImage1D, 6, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(x), uintptr(y), uintptr(width))\n}", "func CopyTexImage2D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, height int32, border int32) {\n\tsyscall.Syscall9(gpCopyTexImage2D, 8, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(x), uintptr(y), uintptr(width), uintptr(height), uintptr(border), 0)\n}", "func CopyTexImage2D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, height int32, border int32) {\n\tC.glowCopyTexImage2D(gpCopyTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border))\n}", "func CopyTexImage2D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, height int32, border int32) {\n\tC.glowCopyTexImage2D(gpCopyTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border))\n}", "func TexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage1D(gpTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage1D(gpTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CompressedTextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage1D(gpCompressedTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage1D(gpCompressedTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CopyPixels(x int32, y int32, width int32, height int32, xtype uint32) {\n C.glowCopyPixels(gpCopyPixels, (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(xtype))\n}", "func CopyTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n\tsyscall.Syscall9(gpCopyTextureSubImage3D, 9, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(x), uintptr(y), uintptr(width), uintptr(height))\n}", "func CopyTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTextureSubImage3D(gpCopyTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CopyTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTextureSubImage3D(gpCopyTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexImage2D(gpTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CopyImageSubData(srcName uint32, srcTarget uint32, srcLevel int32, srcX int32, srcY int32, srcZ int32, dstName uint32, dstTarget uint32, dstLevel int32, dstX int32, dstY int32, dstZ int32, srcWidth int32, srcHeight int32, srcDepth int32) {\n C.glowCopyImageSubData(gpCopyImageSubData, (C.GLuint)(srcName), (C.GLenum)(srcTarget), (C.GLint)(srcLevel), (C.GLint)(srcX), (C.GLint)(srcY), (C.GLint)(srcZ), (C.GLuint)(dstName), (C.GLenum)(dstTarget), (C.GLint)(dstLevel), (C.GLint)(dstX), (C.GLint)(dstY), (C.GLint)(dstZ), (C.GLsizei)(srcWidth), (C.GLsizei)(srcHeight), (C.GLsizei)(srcDepth))\n}", "func CompressedTextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTextureSubImage1D, 7, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(width), uintptr(format), uintptr(imageSize), uintptr(data), 0, 0)\n}", "func TexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTexSubImage1D, 7, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(width), uintptr(format), uintptr(xtype), uintptr(pixels), 0, 0)\n}", "func pixelsToTexture(renderer *sdl.Renderer, pixels []byte, w, h int) *sdl.Texture {\n\t// AGBR is backwards from way we will be filling in out bytes\n\ttex, err := renderer.CreateTexture(sdl.PIXELFORMAT_ABGR8888, sdl.TEXTUREACCESS_STREAMING, int32(w), int32(h))\n\tif err != nil {\n\t\tpanic(err)\n\t}\n\ttex.Update(nil, pixels, w*4) // Can't provide a rectangle, pitch = 4 bytes per pixel\n\treturn tex\n}", "func CopyTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTextureSubImage2D(gpCopyTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CopyTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTextureSubImage2D(gpCopyTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CopyTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n\tsyscall.Syscall9(gpCopyTextureSubImage2D, 8, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(x), uintptr(y), uintptr(width), uintptr(height), 0)\n}", "func CopyTexImage2D(target GLEnum, level int32, internalformat GLEnum, x, y, width, height, border int32) {\n\tgl.CopyTexImage2D(uint32(target), level, uint32(internalformat), x, y, width, height, border)\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexImage2D(gpTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexImage2D(gpTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CompressedTexImage1D(target uint32, level int32, internalformat uint32, width int32, border int32, imageSize int32, data unsafe.Pointer) {\n C.glowCompressedTexImage1D(gpCompressedTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func BindImageTexture(unit uint32, texture uint32, level int32, layered bool, layer int32, access uint32, format uint32) {\n C.glowBindImageTexture(gpBindImageTexture, (C.GLuint)(unit), (C.GLuint)(texture), (C.GLint)(level), (C.GLboolean)(boolToInt(layered)), (C.GLint)(layer), (C.GLenum)(access), (C.GLenum)(format))\n}", "func CopyTexImage2D(target Enum, level int, internalformat Enum, x, y, width, height, border int) {\n\tgl.CopyTexImage2D(uint32(target), int32(level), uint32(internalformat), int32(x), int32(y), int32(width), int32(height), int32(border))\n}", "func CompressedTexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n C.glowCompressedTexSubImage1D(gpCompressedTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CopyTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n C.glowCopyTexSubImage2D(gpCopyTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CopyTexImage2D(target Enum, level Int, internalformat Enum, x Int, y Int, width Sizei, height Sizei, border Int) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tclevel, _ := (C.GLint)(level), cgoAllocsUnknown\n\tcinternalformat, _ := (C.GLenum)(internalformat), cgoAllocsUnknown\n\tcx, _ := (C.GLint)(x), cgoAllocsUnknown\n\tcy, _ := (C.GLint)(y), cgoAllocsUnknown\n\tcwidth, _ := (C.GLsizei)(width), cgoAllocsUnknown\n\tcheight, _ := (C.GLsizei)(height), cgoAllocsUnknown\n\tcborder, _ := (C.GLint)(border), cgoAllocsUnknown\n\tC.glCopyTexImage2D(ctarget, clevel, cinternalformat, cx, cy, cwidth, cheight, cborder)\n}", "func CopyPixels(x int32, y int32, width int32, height int32, xtype uint32) {\n\tC.glowCopyPixels(gpCopyPixels, (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(xtype))\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTexImage2D, 9, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(width), uintptr(height), uintptr(border), uintptr(format), uintptr(xtype), uintptr(pixels))\n}", "func TexImage2D(target Enum, level int, width, height int, format Enum, ty Enum, data []byte) {\n\tp := unsafe.Pointer(nil)\n\tif len(data) > 0 {\n\t\tp = gl.Ptr(&data[0])\n\t}\n\tgl.TexImage2D(uint32(target), int32(level), int32(format), int32(width), int32(height), 0, uint32(format), uint32(ty), p)\n}", "func TexImage2D(target GLEnum, level int32, internalformat GLEnum, width, height, border int32, format, xtype GLEnum, pixels []float32) {\n\tgl.TexImage2D(uint32(target), level, int32(internalformat), width, height, border, uint32(format), uint32(xtype), unsafe.Pointer(&pixels[0]))\n}", "func CopyTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n C.glowCopyTexSubImage3D(gpCopyTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func BindImageTextures(first uint32, count int32, textures *uint32) {\n C.glowBindImageTextures(gpBindImageTextures, (C.GLuint)(first), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(textures)))\n}", "func TexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexSubImage2D(gpTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func GetTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetTextureSubImage(gpGetTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), (C.GLsizei)(bufSize), pixels)\n}", "func GetTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetTextureSubImage(gpGetTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), (C.GLsizei)(bufSize), pixels)\n}", "func (self *TileSprite) SetTexture1O(texture *Texture, destroy bool) {\n self.Object.Call(\"setTexture\", texture, destroy)\n}", "func (native *OpenGL) TexImage2D(target uint32, level int32, internalFormat uint32, width int32, height int32,\n\tborder int32, format uint32, xtype uint32, pixels interface{}) {\n\tptr, isPointer := pixels.(unsafe.Pointer)\n\tif isPointer {\n\t\tgl.TexImage2D(target, level, int32(internalFormat), width, height, border, format, xtype, ptr)\n\t} else {\n\t\tgl.TexImage2D(target, level, int32(internalFormat), width, height, border, format, xtype, gl.Ptr(pixels))\n\t}\n}", "func (debugging *debuggingOpenGL) TexImage2D(target uint32, level int32, internalFormat uint32, width int32, height int32,\n\tborder int32, format uint32, xtype uint32, pixels interface{}) {\n\tdebugging.recordEntry(\"TexImage2D\", target, level, internalFormat, width, height, border, format, xtype, pixels)\n\tdebugging.gl.TexImage2D(target, level, internalFormat, width, height, border, format, xtype, pixels)\n\tdebugging.recordExit(\"TexImage2D\")\n}", "func CopyImageSubData(srcName uint32, srcTarget uint32, srcLevel int32, srcX int32, srcY int32, srcZ int32, dstName uint32, dstTarget uint32, dstLevel int32, dstX int32, dstY int32, dstZ int32, srcWidth int32, srcHeight int32, srcDepth int32) {\n\tC.glowCopyImageSubData(gpCopyImageSubData, (C.GLuint)(srcName), (C.GLenum)(srcTarget), (C.GLint)(srcLevel), (C.GLint)(srcX), (C.GLint)(srcY), (C.GLint)(srcZ), (C.GLuint)(dstName), (C.GLenum)(dstTarget), (C.GLint)(dstLevel), (C.GLint)(dstX), (C.GLint)(dstY), (C.GLint)(dstZ), (C.GLsizei)(srcWidth), (C.GLsizei)(srcHeight), (C.GLsizei)(srcDepth))\n}", "func CopyImageSubData(srcName uint32, srcTarget uint32, srcLevel int32, srcX int32, srcY int32, srcZ int32, dstName uint32, dstTarget uint32, dstLevel int32, dstX int32, dstY int32, dstZ int32, srcWidth int32, srcHeight int32, srcDepth int32) {\n\tC.glowCopyImageSubData(gpCopyImageSubData, (C.GLuint)(srcName), (C.GLenum)(srcTarget), (C.GLint)(srcLevel), (C.GLint)(srcX), (C.GLint)(srcY), (C.GLint)(srcZ), (C.GLuint)(dstName), (C.GLenum)(dstTarget), (C.GLint)(dstLevel), (C.GLint)(dstX), (C.GLint)(dstY), (C.GLint)(dstZ), (C.GLsizei)(srcWidth), (C.GLsizei)(srcHeight), (C.GLsizei)(srcDepth))\n}", "func New(width uint16, height uint16) *Texture {\n\tt := &Texture{\n\t\twidth: width,\n\t\theight: height,\n\t\tpixels: make([]rgb565.Rgb565Color, width*height),\n\t}\n\n\tfor i := range t.pixels {\n\t\tt.pixels[i] = rgb565.New(0x00, 0x00, 0x00)\n\t}\n\n\treturn t\n}", "func Make(width, height int, internalformat int32, format, pixelType uint32,\n\tdata unsafe.Pointer, min, mag, s, t int32) Texture {\n\n\ttexture := Texture{0, gl.TEXTURE_2D, 0}\n\n\t// generate and bind texture\n\tgl.GenTextures(1, &texture.handle)\n\ttexture.Bind(0)\n\n\t// set texture properties\n\tgl.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, min)\n\tgl.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, mag)\n\tgl.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_S, s)\n\tgl.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_T, t)\n\n\t// specify a texture image\n\tgl.TexImage2D(gl.TEXTURE_2D, 0, internalformat, int32(width), int32(height),\n\t\t0, format, pixelType, data)\n\n\t// unbind texture\n\ttexture.Unbind()\n\n\treturn texture\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexSubImage3D(gpTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func (b *XMobileBackend) PutImageData(img *image.RGBA, x, y int) {\n\tb.activate()\n\n\tb.glctx.ActiveTexture(gl.TEXTURE0)\n\tif b.imageBufTex.Value == 0 {\n\t\tb.imageBufTex = b.glctx.CreateTexture()\n\t\tb.glctx.BindTexture(gl.TEXTURE_2D, b.imageBufTex)\n\t\tb.glctx.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.LINEAR)\n\t\tb.glctx.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, gl.LINEAR)\n\t\tb.glctx.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_S, gl.CLAMP_TO_EDGE)\n\t\tb.glctx.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_T, gl.CLAMP_TO_EDGE)\n\t} else {\n\t\tb.glctx.BindTexture(gl.TEXTURE_2D, b.imageBufTex)\n\t}\n\n\tw, h := img.Bounds().Dx(), img.Bounds().Dy()\n\n\tif img.Stride == img.Bounds().Dx()*4 {\n\t\tb.glctx.TexImage2D(gl.TEXTURE_2D, 0, gl.RGBA, w, h, gl.RGBA, gl.UNSIGNED_BYTE, img.Pix[0:])\n\t} else {\n\t\tdata := make([]uint8, 0, w*h*4)\n\t\tfor cy := 0; cy < h; cy++ {\n\t\t\tstart := cy * img.Stride\n\t\t\tend := start + w*4\n\t\t\tdata = append(data, img.Pix[start:end]...)\n\t\t}\n\t\tb.glctx.TexImage2D(gl.TEXTURE_2D, 0, gl.RGBA, w, h, gl.RGBA, gl.UNSIGNED_BYTE, data[0:])\n\t}\n\n\tdx, dy := float32(x), float32(y)\n\tdw, dh := float32(w), float32(h)\n\n\tb.glctx.BindBuffer(gl.ARRAY_BUFFER, b.buf)\n\tdata := [16]float32{dx, dy, dx + dw, dy, dx + dw, dy + dh, dx, dy + dh,\n\t\t0, 0, 1, 0, 1, 1, 0, 1}\n\tb.glctx.BufferData(gl.ARRAY_BUFFER, byteSlice(unsafe.Pointer(&data[0]), len(data)*4), gl.STREAM_DRAW)\n\n\tb.glctx.UseProgram(b.shd.ID)\n\tb.glctx.Uniform1i(b.shd.Image, 0)\n\tb.glctx.Uniform2f(b.shd.CanvasSize, float32(b.fw), float32(b.fh))\n\tb.glctx.UniformMatrix3fv(b.shd.Matrix, mat3identity[:])\n\tb.glctx.Uniform1f(b.shd.GlobalAlpha, 1)\n\tb.glctx.Uniform1i(b.shd.UseAlphaTex, 0)\n\tb.glctx.Uniform1i(b.shd.Func, shdFuncImage)\n\tb.glctx.VertexAttribPointer(b.shd.Vertex, 2, gl.FLOAT, false, 0, 0)\n\tb.glctx.VertexAttribPointer(b.shd.TexCoord, 2, gl.FLOAT, false, 0, 8*4)\n\tb.glctx.EnableVertexAttribArray(b.shd.Vertex)\n\tb.glctx.EnableVertexAttribArray(b.shd.TexCoord)\n\tb.glctx.DrawArrays(gl.TRIANGLE_FAN, 0, 4)\n\tb.glctx.DisableVertexAttribArray(b.shd.Vertex)\n\tb.glctx.DisableVertexAttribArray(b.shd.TexCoord)\n}", "func TexImage2DMultisample(target uint32, samples int32, internalformat uint32, width int32, height int32, fixedsamplelocations bool) {\n C.glowTexImage2DMultisample(gpTexImage2DMultisample, (C.GLenum)(target), (C.GLsizei)(samples), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLboolean)(boolToInt(fixedsamplelocations)))\n}", "func TextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTextureSubImage2D, 9, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(width), uintptr(height), uintptr(format), uintptr(xtype), uintptr(pixels))\n}", "func GetCompressedTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetCompressedTextureSubImage(gpGetCompressedTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLsizei)(bufSize), pixels)\n}", "func GetCompressedTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetCompressedTextureSubImage(gpGetCompressedTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLsizei)(bufSize), pixels)\n}", "func TextureView(texture uint32, target uint32, origtexture uint32, internalformat uint32, minlevel uint32, numlevels uint32, minlayer uint32, numlayers uint32) {\n C.glowTextureView(gpTextureView, (C.GLuint)(texture), (C.GLenum)(target), (C.GLuint)(origtexture), (C.GLenum)(internalformat), (C.GLuint)(minlevel), (C.GLuint)(numlevels), (C.GLuint)(minlayer), (C.GLuint)(numlayers))\n}", "func CompressedTexImage2D(target uint32, level int32, internalformat uint32, width int32, height int32, border int32, imageSize int32, data unsafe.Pointer) {\n C.glowCompressedTexImage2D(gpCompressedTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func CopyTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTexSubImage3D(gpCopyTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CopyTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTexSubImage3D(gpCopyTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func TextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage2D(gpTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage2D(gpTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CompressedTexImage1D(target uint32, level int32, internalformat uint32, width int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexImage1D(gpCompressedTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexImage1D(target uint32, level int32, internalformat uint32, width int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexImage1D(gpCompressedTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func CopyTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n\tsyscall.Syscall9(gpCopyTexSubImage3D, 9, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(x), uintptr(y), uintptr(width), uintptr(height))\n}", "func GetTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, bufSize int32, pixels unsafe.Pointer) {\n\tsyscall.Syscall12(gpGetTextureSubImage, 12, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(xtype), uintptr(bufSize), uintptr(pixels))\n}", "func TexImage2D(target Enum, level Int, internalformat Int, width Sizei, height Sizei, border Int, format Enum, kind Enum, pixels unsafe.Pointer) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tclevel, _ := (C.GLint)(level), cgoAllocsUnknown\n\tcinternalformat, _ := (C.GLint)(internalformat), cgoAllocsUnknown\n\tcwidth, _ := (C.GLsizei)(width), cgoAllocsUnknown\n\tcheight, _ := (C.GLsizei)(height), cgoAllocsUnknown\n\tcborder, _ := (C.GLint)(border), cgoAllocsUnknown\n\tcformat, _ := (C.GLenum)(format), cgoAllocsUnknown\n\tckind, _ := (C.GLenum)(kind), cgoAllocsUnknown\n\tcpixels, _ := (unsafe.Pointer)(unsafe.Pointer(pixels)), cgoAllocsUnknown\n\tC.glTexImage2D(ctarget, clevel, cinternalformat, cwidth, cheight, cborder, cformat, ckind, cpixels)\n}", "func BindTextures(first uint32, count int32, textures *uint32) {\n C.glowBindTextures(gpBindTextures, (C.GLuint)(first), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(textures)))\n}", "func TexImage3D(target uint32, level int32, internalformat int32, width int32, height int32, depth int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexImage3D(gpTexImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func (tex Texture) Sub(ctx gl.Context, lvl int, width int, height int, data []byte) {\n\tctx.TexSubImage2D(gl.TEXTURE_2D, lvl, 0, 0, width, height, gl.RGBA, gl.UNSIGNED_BYTE, data)\n\tif lvl > 0 {\n\t\tctx.GenerateMipmap(gl.TEXTURE_2D)\n\t}\n}", "func CompressedTexImage1D(target uint32, level int32, internalformat uint32, width int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTexImage1D, 7, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(width), uintptr(border), uintptr(imageSize), uintptr(data), 0, 0)\n}", "func draw(window *glfw.Window, reactProg, landProg uint32) {\n\n\tvar renderLoops = 4\n\tfor i := 0; i < renderLoops; i++ {\n\t\t// -- DRAW TO BUFFER --\n\t\t// define destination of pixels\n\t\t//gl.BindFramebuffer(gl.FRAMEBUFFER, 0)\n\t\tgl.BindFramebuffer(gl.FRAMEBUFFER, FBO[1])\n\n\t\tgl.Viewport(0, 0, width, height) // Retina display doubles the framebuffer !?!\n\n\t\tgl.Clear(gl.COLOR_BUFFER_BIT | gl.DEPTH_BUFFER_BIT)\n\t\tgl.UseProgram(reactProg)\n\n\t\t// bind Texture\n\t\tgl.ActiveTexture(gl.TEXTURE0)\n\t\tgl.BindTexture(gl.TEXTURE_2D, renderedTexture)\n\t\tgl.Uniform1i(uniTex, 0)\n\n\t\tgl.BindVertexArray(VAO)\n\t\tgl.DrawElements(gl.TRIANGLE_STRIP, int32(len(indices)), gl.UNSIGNED_INT, nil)\n\n\t\tgl.BindVertexArray(0)\n\n\t\t// -- copy back textures --\n\t\tgl.BindFramebuffer(gl.READ_FRAMEBUFFER, FBO[1]) // source is high res array\n\t\tgl.ReadBuffer(gl.COLOR_ATTACHMENT0)\n\t\tgl.BindFramebuffer(gl.DRAW_FRAMEBUFFER, FBO[0]) // destination is cells array\n\t\tgl.DrawBuffer(gl.COLOR_ATTACHMENT0)\n\t\tgl.BlitFramebuffer(0, 0, width, height,\n\t\t\t0, 0, cols, rows,\n\t\t\tgl.COLOR_BUFFER_BIT, gl.NEAREST) // downsample\n\t\tgl.BindFramebuffer(gl.READ_FRAMEBUFFER, FBO[0]) // source is low res array - put in texture\n\t\t// read pixels saves data read as unsigned bytes and then loads them in TexImage same way\n\t\tgl.ReadPixels(0, 0, cols, rows, gl.RGBA, gl.FLOAT, gl.Ptr(fData))\n\t\tgl.BindTexture(gl.TEXTURE_2D, renderedTexture)\n\t\tgl.TexImage2D(gl.TEXTURE_2D, 0, gl.RGBA, cols, rows, 0, gl.RGBA, gl.FLOAT, gl.Ptr(fData))\n\t\tCheckGLErrors()\n\t}\n\t// -- DRAW TO SCREEN --\n\tvar model glm.Mat4\n\n\t// destination 0 means screen\n\tgl.BindFramebuffer(gl.FRAMEBUFFER, 0)\n\tgl.Viewport(0, 0, width*2, height*2) // Retina display doubles the framebuffer !?!\n\tgl.Clear(gl.COLOR_BUFFER_BIT | gl.DEPTH_BUFFER_BIT)\n\tgl.UseProgram(landProg)\n\t// bind Texture\n\tgl.ActiveTexture(gl.TEXTURE0)\n\tgl.BindTexture(gl.TEXTURE_2D, drawTexture)\n\n\tvar view glm.Mat4\n\tvar brakeFactor = float64(20000.0)\n\tvar xCoord, yCoord float32\n\txCoord = float32(-3.0 * math.Sin(float64(myClock)))\n\tyCoord = float32(-3.0 * math.Cos(float64(myClock)))\n\t//xCoord = 0.0\n\t//yCoord = float32(-2.5)\n\tmyClock = math.Mod((myClock + float64(deltaTime)/brakeFactor), (math.Pi * 2))\n\tview = glm.LookAt(xCoord, yCoord, 2.0, 0.0, 0.0, 0.0, 0.0, 0.0, 1.0)\n\tgl.UniformMatrix4fv(uniView, 1, false, &view[0])\n\tmodel = glm.HomogRotate3DX(glm.DegToRad(00.0))\n\tgl.UniformMatrix4fv(uniModel, 1, false, &model[0])\n\tgl.Uniform1i(uniTex2, 0)\n\n\t// render container\n\t//gl.PolygonMode(gl.FRONT_AND_BACK, gl.FILL)\n\t//gl.PolygonMode(gl.FRONT_AND_BACK, gl.LINE)\n\n\tgl.BindVertexArray(VAO)\n\tgl.DrawElements(gl.TRIANGLE_STRIP, int32(len(indices)), gl.UNSIGNED_INT, nil)\n\tgl.BindVertexArray(0)\n\n\tCheckGLErrors()\n\n\tglfw.PollEvents()\n\twindow.SwapBuffers()\n\n\t//time.Sleep(100 * 1000 * 1000)\n}", "func TextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage3D(gpTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage3D(gpTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func (t *SinglePixelTexture) Draw(renderer *sdl.Renderer) {\n\trenderer.Copy(t.Texture, nil, &t.Rect)\n}", "func (self *Graphics) GenerateTexture1O(resolution int) *Texture{\n return &Texture{self.Object.Call(\"generateTexture\", resolution)}\n}", "func TexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage2D(gpTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage2D(gpTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CopyTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTexSubImage2D(gpCopyTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CopyTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTexSubImage2D(gpCopyTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func TextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall12(gpTextureSubImage3D, 11, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(xtype), uintptr(pixels), 0)\n}", "func CopyPixels(x int32, y int32, width int32, height int32, xtype uint32) {\n\tsyscall.Syscall6(gpCopyPixels, 5, uintptr(x), uintptr(y), uintptr(width), uintptr(height), uintptr(xtype), 0)\n}", "func CompressedTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage2D(gpCompressedTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage2D(gpCompressedTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func (t *Texture) Clone() *Texture {\n\tt.p.Call(\"clone\")\n\treturn t\n}", "func GetTexImage(target uint32, level int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowGetTexImage(gpGetTexImage, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func GetCompressedTexImage(target uint32, level int32, img unsafe.Pointer) {\n C.glowGetCompressedTexImage(gpGetCompressedTexImage, (C.GLenum)(target), (C.GLint)(level), img)\n}" ]
[ "0.70645934", "0.705592", "0.705592", "0.70249724", "0.70157284", "0.6721655", "0.6592131", "0.65479004", "0.6514974", "0.6514974", "0.6513513", "0.6479638", "0.6476083", "0.6476083", "0.6443299", "0.64221895", "0.64221895", "0.62778026", "0.62627196", "0.622544", "0.622544", "0.6220572", "0.6220572", "0.6165672", "0.6165672", "0.61435694", "0.61410743", "0.6132634", "0.6132634", "0.60961014", "0.6053025", "0.60423505", "0.6038784", "0.6020597", "0.5966966", "0.5966966", "0.59658283", "0.5888972", "0.5869974", "0.5869974", "0.58664316", "0.58523023", "0.5849153", "0.5843276", "0.5818565", "0.5808978", "0.57933575", "0.57891077", "0.5781222", "0.5752168", "0.5746437", "0.5740499", "0.5735526", "0.5664115", "0.5664115", "0.56544656", "0.56390053", "0.56216204", "0.5619992", "0.5619992", "0.5615392", "0.5581447", "0.5550396", "0.5532197", "0.55255514", "0.55180156", "0.5515603", "0.5515603", "0.54975885", "0.54665226", "0.54647416", "0.54647416", "0.5463237", "0.5463237", "0.5461712", "0.5461712", "0.54608107", "0.5450459", "0.54497725", "0.5448869", "0.5442921", "0.54393756", "0.5435979", "0.54285675", "0.54277927", "0.54277927", "0.5420057", "0.5419813", "0.5411237", "0.5411237", "0.5400229", "0.5400229", "0.5395964", "0.5394378", "0.5385581", "0.5385581", "0.53832656", "0.5375253", "0.5375005" ]
0.68743
6
copy pixels into a 2D texture image
func CopyTexImage2D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, height int32, border int32) { C.glowCopyTexImage2D(gpCopyTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func CopyTexImage2D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, height int32, border int32) {\n\tsyscall.Syscall9(gpCopyTexImage2D, 8, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(x), uintptr(y), uintptr(width), uintptr(height), uintptr(border), 0)\n}", "func CopyTexImage2D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, height int32, border int32) {\n C.glowCopyTexImage2D(gpCopyTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border))\n}", "func CopyTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n\tsyscall.Syscall9(gpCopyTextureSubImage2D, 8, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(x), uintptr(y), uintptr(width), uintptr(height), 0)\n}", "func CopyTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTextureSubImage2D(gpCopyTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CopyTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTextureSubImage2D(gpCopyTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CopyTexImage2D(target GLEnum, level int32, internalformat GLEnum, x, y, width, height, border int32) {\n\tgl.CopyTexImage2D(uint32(target), level, uint32(internalformat), x, y, width, height, border)\n}", "func CopyTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n C.glowCopyTexSubImage2D(gpCopyTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexImage2D(gpTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CopyTexImage2D(target Enum, level int, internalformat Enum, x, y, width, height, border int) {\n\tgl.CopyTexImage2D(uint32(target), int32(level), uint32(internalformat), int32(x), int32(y), int32(width), int32(height), int32(border))\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTexImage2D, 9, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(width), uintptr(height), uintptr(border), uintptr(format), uintptr(xtype), uintptr(pixels))\n}", "func CopyTexImage2D(target Enum, level Int, internalformat Enum, x Int, y Int, width Sizei, height Sizei, border Int) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tclevel, _ := (C.GLint)(level), cgoAllocsUnknown\n\tcinternalformat, _ := (C.GLenum)(internalformat), cgoAllocsUnknown\n\tcx, _ := (C.GLint)(x), cgoAllocsUnknown\n\tcy, _ := (C.GLint)(y), cgoAllocsUnknown\n\tcwidth, _ := (C.GLsizei)(width), cgoAllocsUnknown\n\tcheight, _ := (C.GLsizei)(height), cgoAllocsUnknown\n\tcborder, _ := (C.GLint)(border), cgoAllocsUnknown\n\tC.glCopyTexImage2D(ctarget, clevel, cinternalformat, cx, cy, cwidth, cheight, cborder)\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexImage2D(gpTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexImage2D(gpTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func (debugging *debuggingOpenGL) TexImage2D(target uint32, level int32, internalFormat uint32, width int32, height int32,\n\tborder int32, format uint32, xtype uint32, pixels interface{}) {\n\tdebugging.recordEntry(\"TexImage2D\", target, level, internalFormat, width, height, border, format, xtype, pixels)\n\tdebugging.gl.TexImage2D(target, level, internalFormat, width, height, border, format, xtype, pixels)\n\tdebugging.recordExit(\"TexImage2D\")\n}", "func CopyTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n\tsyscall.Syscall9(gpCopyTextureSubImage3D, 9, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(x), uintptr(y), uintptr(width), uintptr(height))\n}", "func TexImage2D(target GLEnum, level int32, internalformat GLEnum, width, height, border int32, format, xtype GLEnum, pixels []float32) {\n\tgl.TexImage2D(uint32(target), level, int32(internalformat), width, height, border, uint32(format), uint32(xtype), unsafe.Pointer(&pixels[0]))\n}", "func TexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexSubImage2D(gpTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTextureSubImage2D, 9, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(width), uintptr(height), uintptr(format), uintptr(xtype), uintptr(pixels))\n}", "func CopyTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTextureSubImage3D(gpCopyTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CopyTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTextureSubImage3D(gpCopyTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func (native *OpenGL) TexImage2D(target uint32, level int32, internalFormat uint32, width int32, height int32,\n\tborder int32, format uint32, xtype uint32, pixels interface{}) {\n\tptr, isPointer := pixels.(unsafe.Pointer)\n\tif isPointer {\n\t\tgl.TexImage2D(target, level, int32(internalFormat), width, height, border, format, xtype, ptr)\n\t} else {\n\t\tgl.TexImage2D(target, level, int32(internalFormat), width, height, border, format, xtype, gl.Ptr(pixels))\n\t}\n}", "func TexImage2D(target Enum, level int, width, height int, format Enum, ty Enum, data []byte) {\n\tp := unsafe.Pointer(nil)\n\tif len(data) > 0 {\n\t\tp = gl.Ptr(&data[0])\n\t}\n\tgl.TexImage2D(uint32(target), int32(level), int32(format), int32(width), int32(height), 0, uint32(format), uint32(ty), p)\n}", "func CopyTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n\tsyscall.Syscall9(gpCopyTexSubImage2D, 8, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(x), uintptr(y), uintptr(width), uintptr(height), 0)\n}", "func CopyTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTexSubImage2D(gpCopyTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CopyTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTexSubImage2D(gpCopyTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func TextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage2D(gpTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage2D(gpTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CopyTextureSubImage1D(texture uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tsyscall.Syscall6(gpCopyTextureSubImage1D, 6, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(x), uintptr(y), uintptr(width))\n}", "func TexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage2D(gpTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage2D(gpTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CopyTextureSubImage1D(texture uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tC.glowCopyTextureSubImage1D(gpCopyTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func CopyTextureSubImage1D(texture uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tC.glowCopyTextureSubImage1D(gpCopyTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func TexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTexSubImage2D, 9, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(width), uintptr(height), uintptr(format), uintptr(xtype), uintptr(pixels))\n}", "func TexImage2D(target Enum, level Int, internalformat Int, width Sizei, height Sizei, border Int, format Enum, kind Enum, pixels unsafe.Pointer) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tclevel, _ := (C.GLint)(level), cgoAllocsUnknown\n\tcinternalformat, _ := (C.GLint)(internalformat), cgoAllocsUnknown\n\tcwidth, _ := (C.GLsizei)(width), cgoAllocsUnknown\n\tcheight, _ := (C.GLsizei)(height), cgoAllocsUnknown\n\tcborder, _ := (C.GLint)(border), cgoAllocsUnknown\n\tcformat, _ := (C.GLenum)(format), cgoAllocsUnknown\n\tckind, _ := (C.GLenum)(kind), cgoAllocsUnknown\n\tcpixels, _ := (unsafe.Pointer)(unsafe.Pointer(pixels)), cgoAllocsUnknown\n\tC.glTexImage2D(ctarget, clevel, cinternalformat, cwidth, cheight, cborder, cformat, ckind, cpixels)\n}", "func (gl *WebGL) TexImage2D(target GLEnum, level int, internalFormat GLEnum, format GLEnum, texelType GLEnum, pixels interface{}) {\n\tgl.context.Call(\"texImage2D\", target, level, internalFormat, format, texelType, pixels)\n}", "func CompressedTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage2D(gpCompressedTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage2D(gpCompressedTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func TexSubImage2D(target Enum, level Int, xoffset Int, yoffset Int, width Sizei, height Sizei, format Enum, kind Enum, pixels unsafe.Pointer) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tclevel, _ := (C.GLint)(level), cgoAllocsUnknown\n\tcxoffset, _ := (C.GLint)(xoffset), cgoAllocsUnknown\n\tcyoffset, _ := (C.GLint)(yoffset), cgoAllocsUnknown\n\tcwidth, _ := (C.GLsizei)(width), cgoAllocsUnknown\n\tcheight, _ := (C.GLsizei)(height), cgoAllocsUnknown\n\tcformat, _ := (C.GLenum)(format), cgoAllocsUnknown\n\tckind, _ := (C.GLenum)(kind), cgoAllocsUnknown\n\tcpixels, _ := (unsafe.Pointer)(unsafe.Pointer(pixels)), cgoAllocsUnknown\n\tC.glTexSubImage2D(ctarget, clevel, cxoffset, cyoffset, cwidth, cheight, cformat, ckind, cpixels)\n}", "func CopyTexSubImage2D(target GLEnum, level, xoffset, yoffset, x, y, width, height int32) {\n\tgl.CopyTexSubImage2D(uint32(target), level, xoffset, yoffset, x, y, width, height)\n}", "func CopyTexSubImage2D(target Enum, level Int, xoffset Int, yoffset Int, x Int, y Int, width Sizei, height Sizei) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tclevel, _ := (C.GLint)(level), cgoAllocsUnknown\n\tcxoffset, _ := (C.GLint)(xoffset), cgoAllocsUnknown\n\tcyoffset, _ := (C.GLint)(yoffset), cgoAllocsUnknown\n\tcx, _ := (C.GLint)(x), cgoAllocsUnknown\n\tcy, _ := (C.GLint)(y), cgoAllocsUnknown\n\tcwidth, _ := (C.GLsizei)(width), cgoAllocsUnknown\n\tcheight, _ := (C.GLsizei)(height), cgoAllocsUnknown\n\tC.glCopyTexSubImage2D(ctarget, clevel, cxoffset, cyoffset, cx, cy, cwidth, cheight)\n}", "func pixelsToTexture(renderer *sdl.Renderer, pixels []byte, w, h int) *sdl.Texture {\n\t// AGBR is backwards from way we will be filling in out bytes\n\ttex, err := renderer.CreateTexture(sdl.PIXELFORMAT_ABGR8888, sdl.TEXTUREACCESS_STREAMING, int32(w), int32(h))\n\tif err != nil {\n\t\tpanic(err)\n\t}\n\ttex.Update(nil, pixels, w*4) // Can't provide a rectangle, pitch = 4 bytes per pixel\n\treturn tex\n}", "func CompressedTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTextureSubImage2D, 9, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(width), uintptr(height), uintptr(format), uintptr(imageSize), uintptr(data))\n}", "func TexSubImage2D(target GLEnum, level, xoffset, yoffset, width, height int32, format, xtype GLEnum, pixels []float32) {\n\tgl.TexSubImage2D(uint32(target), level, xoffset, yoffset, width, height, uint32(format), uint32(xtype), unsafe.Pointer(&pixels[0]))\n}", "func CopyTexSubImage2D(target Enum, level, xoffset, yoffset, x, y, width, height int) {\n\tgl.CopyTexSubImage2D(uint32(target), int32(level), int32(xoffset), int32(yoffset), int32(x), int32(y), int32(width), int32(height))\n}", "func TexSubImage2D(target Enum, level int, x, y, width, height int, format, ty Enum, data []byte) {\n\tgl.TexSubImage2D(uint32(target), int32(level), int32(x), int32(y), int32(width), int32(height), uint32(format), uint32(ty), gl.Ptr(&data[0]))\n}", "func CopyPixels(x int32, y int32, width int32, height int32, xtype uint32) {\n C.glowCopyPixels(gpCopyPixels, (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(xtype))\n}", "func CopyTexSubImage1D(target uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n C.glowCopyTexSubImage1D(gpCopyTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func GetTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetTextureSubImage(gpGetTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), (C.GLsizei)(bufSize), pixels)\n}", "func GetTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetTextureSubImage(gpGetTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), (C.GLsizei)(bufSize), pixels)\n}", "func CompressedTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n C.glowCompressedTexSubImage2D(gpCompressedTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CopyTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n C.glowCopyTexSubImage3D(gpCopyTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CopyTexImage1D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, border int32) {\n C.glowCopyTexImage1D(gpCopyTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLint)(border))\n}", "func TextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTextureSubImage1D, 7, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(width), uintptr(format), uintptr(xtype), uintptr(pixels), 0, 0)\n}", "func CopyTexImage1D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, border int32) {\n\tsyscall.Syscall9(gpCopyTexImage1D, 7, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(x), uintptr(y), uintptr(width), uintptr(border), 0, 0)\n}", "func CopyImageSubData(srcName uint32, srcTarget uint32, srcLevel int32, srcX int32, srcY int32, srcZ int32, dstName uint32, dstTarget uint32, dstLevel int32, dstX int32, dstY int32, dstZ int32, srcWidth int32, srcHeight int32, srcDepth int32) {\n C.glowCopyImageSubData(gpCopyImageSubData, (C.GLuint)(srcName), (C.GLenum)(srcTarget), (C.GLint)(srcLevel), (C.GLint)(srcX), (C.GLint)(srcY), (C.GLint)(srcZ), (C.GLuint)(dstName), (C.GLenum)(dstTarget), (C.GLint)(dstLevel), (C.GLint)(dstX), (C.GLint)(dstY), (C.GLint)(dstZ), (C.GLsizei)(srcWidth), (C.GLsizei)(srcHeight), (C.GLsizei)(srcDepth))\n}", "func (tex Texture) Sub(ctx gl.Context, lvl int, width int, height int, data []byte) {\n\tctx.TexSubImage2D(gl.TEXTURE_2D, lvl, 0, 0, width, height, gl.RGBA, gl.UNSIGNED_BYTE, data)\n\tif lvl > 0 {\n\t\tctx.GenerateMipmap(gl.TEXTURE_2D)\n\t}\n}", "func CopyTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n\tsyscall.Syscall9(gpCopyTexSubImage3D, 9, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(x), uintptr(y), uintptr(width), uintptr(height))\n}", "func GetTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, bufSize int32, pixels unsafe.Pointer) {\n\tsyscall.Syscall12(gpGetTextureSubImage, 12, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(xtype), uintptr(bufSize), uintptr(pixels))\n}", "func CompressedTexImage2D(target uint32, level int32, internalformat uint32, width int32, height int32, border int32, imageSize int32, data unsafe.Pointer) {\n C.glowCompressedTexImage2D(gpCompressedTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func TextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall12(gpTextureSubImage3D, 11, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(xtype), uintptr(pixels), 0)\n}", "func CopyTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTexSubImage3D(gpCopyTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CopyTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTexSubImage3D(gpCopyTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func TextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage3D(gpTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage3D(gpTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexSubImage1D(gpTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage1D(gpTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage1D(gpTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexSubImage3D(gpTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func BindImageTexture(unit uint32, texture uint32, level int32, layered bool, layer int32, access uint32, format uint32) {\n C.glowBindImageTexture(gpBindImageTexture, (C.GLuint)(unit), (C.GLuint)(texture), (C.GLint)(level), (C.GLboolean)(boolToInt(layered)), (C.GLint)(layer), (C.GLenum)(access), (C.GLenum)(format))\n}", "func CopyTexImage1D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, border int32) {\n\tC.glowCopyTexImage1D(gpCopyTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLint)(border))\n}", "func CopyTexImage1D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, border int32) {\n\tC.glowCopyTexImage1D(gpCopyTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLint)(border))\n}", "func CopyPixels(x int32, y int32, width int32, height int32, xtype uint32) {\n\tC.glowCopyPixels(gpCopyPixels, (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(xtype))\n}", "func CompressedTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexSubImage2D(gpCompressedTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexSubImage2D(gpCompressedTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func GetCompressedTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetCompressedTextureSubImage(gpGetCompressedTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLsizei)(bufSize), pixels)\n}", "func GetCompressedTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetCompressedTextureSubImage(gpGetCompressedTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLsizei)(bufSize), pixels)\n}", "func CopyTexSubImage1D(target uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tC.glowCopyTexSubImage1D(gpCopyTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func CopyTexSubImage1D(target uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tC.glowCopyTexSubImage1D(gpCopyTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage3D(gpTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage3D(gpTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func Make(width, height int, internalformat int32, format, pixelType uint32,\n\tdata unsafe.Pointer, min, mag, s, t int32) Texture {\n\n\ttexture := Texture{0, gl.TEXTURE_2D, 0}\n\n\t// generate and bind texture\n\tgl.GenTextures(1, &texture.handle)\n\ttexture.Bind(0)\n\n\t// set texture properties\n\tgl.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, min)\n\tgl.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, mag)\n\tgl.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_S, s)\n\tgl.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_T, t)\n\n\t// specify a texture image\n\tgl.TexImage2D(gl.TEXTURE_2D, 0, internalformat, int32(width), int32(height),\n\t\t0, format, pixelType, data)\n\n\t// unbind texture\n\ttexture.Unbind()\n\n\treturn texture\n}", "func CompressedTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage3D(gpCompressedTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage3D(gpCompressedTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall12(gpTexSubImage3D, 11, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(xtype), uintptr(pixels), 0)\n}", "func CopyBufferSubData(readTarget uint32, writeTarget uint32, readOffset int, writeOffset int, size int) {\n C.glowCopyBufferSubData(gpCopyBufferSubData, (C.GLenum)(readTarget), (C.GLenum)(writeTarget), (C.GLintptr)(readOffset), (C.GLintptr)(writeOffset), (C.GLsizeiptr)(size))\n}", "func (b *XMobileBackend) PutImageData(img *image.RGBA, x, y int) {\n\tb.activate()\n\n\tb.glctx.ActiveTexture(gl.TEXTURE0)\n\tif b.imageBufTex.Value == 0 {\n\t\tb.imageBufTex = b.glctx.CreateTexture()\n\t\tb.glctx.BindTexture(gl.TEXTURE_2D, b.imageBufTex)\n\t\tb.glctx.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.LINEAR)\n\t\tb.glctx.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, gl.LINEAR)\n\t\tb.glctx.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_S, gl.CLAMP_TO_EDGE)\n\t\tb.glctx.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_T, gl.CLAMP_TO_EDGE)\n\t} else {\n\t\tb.glctx.BindTexture(gl.TEXTURE_2D, b.imageBufTex)\n\t}\n\n\tw, h := img.Bounds().Dx(), img.Bounds().Dy()\n\n\tif img.Stride == img.Bounds().Dx()*4 {\n\t\tb.glctx.TexImage2D(gl.TEXTURE_2D, 0, gl.RGBA, w, h, gl.RGBA, gl.UNSIGNED_BYTE, img.Pix[0:])\n\t} else {\n\t\tdata := make([]uint8, 0, w*h*4)\n\t\tfor cy := 0; cy < h; cy++ {\n\t\t\tstart := cy * img.Stride\n\t\t\tend := start + w*4\n\t\t\tdata = append(data, img.Pix[start:end]...)\n\t\t}\n\t\tb.glctx.TexImage2D(gl.TEXTURE_2D, 0, gl.RGBA, w, h, gl.RGBA, gl.UNSIGNED_BYTE, data[0:])\n\t}\n\n\tdx, dy := float32(x), float32(y)\n\tdw, dh := float32(w), float32(h)\n\n\tb.glctx.BindBuffer(gl.ARRAY_BUFFER, b.buf)\n\tdata := [16]float32{dx, dy, dx + dw, dy, dx + dw, dy + dh, dx, dy + dh,\n\t\t0, 0, 1, 0, 1, 1, 0, 1}\n\tb.glctx.BufferData(gl.ARRAY_BUFFER, byteSlice(unsafe.Pointer(&data[0]), len(data)*4), gl.STREAM_DRAW)\n\n\tb.glctx.UseProgram(b.shd.ID)\n\tb.glctx.Uniform1i(b.shd.Image, 0)\n\tb.glctx.Uniform2f(b.shd.CanvasSize, float32(b.fw), float32(b.fh))\n\tb.glctx.UniformMatrix3fv(b.shd.Matrix, mat3identity[:])\n\tb.glctx.Uniform1f(b.shd.GlobalAlpha, 1)\n\tb.glctx.Uniform1i(b.shd.UseAlphaTex, 0)\n\tb.glctx.Uniform1i(b.shd.Func, shdFuncImage)\n\tb.glctx.VertexAttribPointer(b.shd.Vertex, 2, gl.FLOAT, false, 0, 0)\n\tb.glctx.VertexAttribPointer(b.shd.TexCoord, 2, gl.FLOAT, false, 0, 8*4)\n\tb.glctx.EnableVertexAttribArray(b.shd.Vertex)\n\tb.glctx.EnableVertexAttribArray(b.shd.TexCoord)\n\tb.glctx.DrawArrays(gl.TRIANGLE_FAN, 0, 4)\n\tb.glctx.DisableVertexAttribArray(b.shd.Vertex)\n\tb.glctx.DisableVertexAttribArray(b.shd.TexCoord)\n}", "func CompressedTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTexSubImage2D, 9, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(width), uintptr(height), uintptr(format), uintptr(imageSize), uintptr(data))\n}", "func CopyImageSubData(srcName uint32, srcTarget uint32, srcLevel int32, srcX int32, srcY int32, srcZ int32, dstName uint32, dstTarget uint32, dstLevel int32, dstX int32, dstY int32, dstZ int32, srcWidth int32, srcHeight int32, srcDepth int32) {\n\tC.glowCopyImageSubData(gpCopyImageSubData, (C.GLuint)(srcName), (C.GLenum)(srcTarget), (C.GLint)(srcLevel), (C.GLint)(srcX), (C.GLint)(srcY), (C.GLint)(srcZ), (C.GLuint)(dstName), (C.GLenum)(dstTarget), (C.GLint)(dstLevel), (C.GLint)(dstX), (C.GLint)(dstY), (C.GLint)(dstZ), (C.GLsizei)(srcWidth), (C.GLsizei)(srcHeight), (C.GLsizei)(srcDepth))\n}", "func CopyImageSubData(srcName uint32, srcTarget uint32, srcLevel int32, srcX int32, srcY int32, srcZ int32, dstName uint32, dstTarget uint32, dstLevel int32, dstX int32, dstY int32, dstZ int32, srcWidth int32, srcHeight int32, srcDepth int32) {\n\tC.glowCopyImageSubData(gpCopyImageSubData, (C.GLuint)(srcName), (C.GLenum)(srcTarget), (C.GLint)(srcLevel), (C.GLint)(srcX), (C.GLint)(srcY), (C.GLint)(srcZ), (C.GLuint)(dstName), (C.GLenum)(dstTarget), (C.GLint)(dstLevel), (C.GLint)(dstX), (C.GLint)(dstY), (C.GLint)(dstZ), (C.GLsizei)(srcWidth), (C.GLsizei)(srcHeight), (C.GLsizei)(srcDepth))\n}", "func (f *Framebuffer) Texture2D(attachment gfx.FramebufferAttachment, target gfx.TextureTarget, tex gfx.Texture) {\n\tf.useState()\n\tf.ctx.O.Call(\n\t\t\"framebufferTexture2D\",\n\t\tf.ctx.FRAMEBUFFER,\n\t\tf.ctx.Enums[int(attachment)],\n\t\tf.ctx.Enums[int(target)],\n\t\ttex.Object().(*js.Object),\n\t\t0,\n\t)\n}", "func draw(window *glfw.Window, reactProg, landProg uint32) {\n\n\tvar renderLoops = 4\n\tfor i := 0; i < renderLoops; i++ {\n\t\t// -- DRAW TO BUFFER --\n\t\t// define destination of pixels\n\t\t//gl.BindFramebuffer(gl.FRAMEBUFFER, 0)\n\t\tgl.BindFramebuffer(gl.FRAMEBUFFER, FBO[1])\n\n\t\tgl.Viewport(0, 0, width, height) // Retina display doubles the framebuffer !?!\n\n\t\tgl.Clear(gl.COLOR_BUFFER_BIT | gl.DEPTH_BUFFER_BIT)\n\t\tgl.UseProgram(reactProg)\n\n\t\t// bind Texture\n\t\tgl.ActiveTexture(gl.TEXTURE0)\n\t\tgl.BindTexture(gl.TEXTURE_2D, renderedTexture)\n\t\tgl.Uniform1i(uniTex, 0)\n\n\t\tgl.BindVertexArray(VAO)\n\t\tgl.DrawElements(gl.TRIANGLE_STRIP, int32(len(indices)), gl.UNSIGNED_INT, nil)\n\n\t\tgl.BindVertexArray(0)\n\n\t\t// -- copy back textures --\n\t\tgl.BindFramebuffer(gl.READ_FRAMEBUFFER, FBO[1]) // source is high res array\n\t\tgl.ReadBuffer(gl.COLOR_ATTACHMENT0)\n\t\tgl.BindFramebuffer(gl.DRAW_FRAMEBUFFER, FBO[0]) // destination is cells array\n\t\tgl.DrawBuffer(gl.COLOR_ATTACHMENT0)\n\t\tgl.BlitFramebuffer(0, 0, width, height,\n\t\t\t0, 0, cols, rows,\n\t\t\tgl.COLOR_BUFFER_BIT, gl.NEAREST) // downsample\n\t\tgl.BindFramebuffer(gl.READ_FRAMEBUFFER, FBO[0]) // source is low res array - put in texture\n\t\t// read pixels saves data read as unsigned bytes and then loads them in TexImage same way\n\t\tgl.ReadPixels(0, 0, cols, rows, gl.RGBA, gl.FLOAT, gl.Ptr(fData))\n\t\tgl.BindTexture(gl.TEXTURE_2D, renderedTexture)\n\t\tgl.TexImage2D(gl.TEXTURE_2D, 0, gl.RGBA, cols, rows, 0, gl.RGBA, gl.FLOAT, gl.Ptr(fData))\n\t\tCheckGLErrors()\n\t}\n\t// -- DRAW TO SCREEN --\n\tvar model glm.Mat4\n\n\t// destination 0 means screen\n\tgl.BindFramebuffer(gl.FRAMEBUFFER, 0)\n\tgl.Viewport(0, 0, width*2, height*2) // Retina display doubles the framebuffer !?!\n\tgl.Clear(gl.COLOR_BUFFER_BIT | gl.DEPTH_BUFFER_BIT)\n\tgl.UseProgram(landProg)\n\t// bind Texture\n\tgl.ActiveTexture(gl.TEXTURE0)\n\tgl.BindTexture(gl.TEXTURE_2D, drawTexture)\n\n\tvar view glm.Mat4\n\tvar brakeFactor = float64(20000.0)\n\tvar xCoord, yCoord float32\n\txCoord = float32(-3.0 * math.Sin(float64(myClock)))\n\tyCoord = float32(-3.0 * math.Cos(float64(myClock)))\n\t//xCoord = 0.0\n\t//yCoord = float32(-2.5)\n\tmyClock = math.Mod((myClock + float64(deltaTime)/brakeFactor), (math.Pi * 2))\n\tview = glm.LookAt(xCoord, yCoord, 2.0, 0.0, 0.0, 0.0, 0.0, 0.0, 1.0)\n\tgl.UniformMatrix4fv(uniView, 1, false, &view[0])\n\tmodel = glm.HomogRotate3DX(glm.DegToRad(00.0))\n\tgl.UniformMatrix4fv(uniModel, 1, false, &model[0])\n\tgl.Uniform1i(uniTex2, 0)\n\n\t// render container\n\t//gl.PolygonMode(gl.FRONT_AND_BACK, gl.FILL)\n\t//gl.PolygonMode(gl.FRONT_AND_BACK, gl.LINE)\n\n\tgl.BindVertexArray(VAO)\n\tgl.DrawElements(gl.TRIANGLE_STRIP, int32(len(indices)), gl.UNSIGNED_INT, nil)\n\tgl.BindVertexArray(0)\n\n\tCheckGLErrors()\n\n\tglfw.PollEvents()\n\twindow.SwapBuffers()\n\n\t//time.Sleep(100 * 1000 * 1000)\n}", "func CompressedTexSubImage2D(target GLEnum, level, xoffset, yoffset, width, height int32, format GLEnum, imageSize int32, pixels []float32) {\n\tgl.CompressedTexSubImage2D(uint32(target), level, xoffset, yoffset, width, height, uint32(format), imageSize, unsafe.Pointer(&pixels[0]))\n}", "func CopyTexSubImage1D(target uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tsyscall.Syscall6(gpCopyTexSubImage1D, 6, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(x), uintptr(y), uintptr(width))\n}", "func drawTilePixels(image *image.RGBA, pixel [8][8]color.RGBA, xOffset int, yOffset int) *image.RGBA {\n\tfor x := 0; x < TileWidth; x++ {\n\t\tfor y := 0; y < TileHeight; y++ {\n\t\t\timage.SetRGBA(xOffset*TileWidth+x, yOffset*TileHeight+y, pixel[y][x])\n\t\t}\n\t}\n\treturn image\n}", "func CompressedTexImage2D(target uint32, level int32, internalformat uint32, width int32, height int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTexImage2D, 8, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(width), uintptr(height), uintptr(border), uintptr(imageSize), uintptr(data), 0)\n}", "func CompressedTexImage2D(target uint32, level int32, internalformat uint32, width int32, height int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexImage2D(gpCompressedTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexImage2D(target uint32, level int32, internalformat uint32, width int32, height int32, border int32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTexImage2D(gpCompressedTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func (self *Graphics) GenerateTexture2O(resolution int, scaleMode int) *Texture{\n return &Texture{self.Object.Call(\"generateTexture\", resolution, scaleMode)}\n}", "func FramebufferTexture2D(target uint32, attachment uint32, textarget uint32, texture uint32, level int32) {\n\tsyscall.Syscall6(gpFramebufferTexture2D, 5, uintptr(target), uintptr(attachment), uintptr(textarget), uintptr(texture), uintptr(level), 0)\n}" ]
[ "0.7206373", "0.71991235", "0.7191726", "0.7138349", "0.7138349", "0.6910669", "0.6893222", "0.68694407", "0.68424076", "0.68146855", "0.68001497", "0.679214", "0.679214", "0.6789609", "0.6756719", "0.6743074", "0.67361367", "0.6726271", "0.67152506", "0.67152506", "0.6692911", "0.66860586", "0.66458774", "0.66404825", "0.66404825", "0.6634177", "0.6634177", "0.6598705", "0.6561276", "0.6561276", "0.65554905", "0.65554905", "0.65477014", "0.651771", "0.6485148", "0.6447101", "0.6447101", "0.6441705", "0.6439994", "0.6437125", "0.64092255", "0.6389649", "0.6344118", "0.6305351", "0.6291491", "0.61868334", "0.617096", "0.6165563", "0.6165563", "0.61435753", "0.61266696", "0.60865396", "0.607178", "0.60678196", "0.60590285", "0.60078686", "0.6002371", "0.59964746", "0.59913653", "0.5973303", "0.59581614", "0.59581614", "0.59570044", "0.59570044", "0.5939946", "0.59260505", "0.59260505", "0.5870122", "0.58606255", "0.5832203", "0.5832203", "0.57763153", "0.5775513", "0.5775513", "0.57737106", "0.57737106", "0.57729936", "0.57729936", "0.57495135", "0.57495135", "0.5746665", "0.5741304", "0.5741304", "0.5741258", "0.5725828", "0.5711542", "0.57101834", "0.5706472", "0.5706472", "0.5706365", "0.56960255", "0.5687932", "0.5664642", "0.5652844", "0.5643045", "0.5642204", "0.5642204", "0.5636825", "0.56335795" ]
0.70907384
6
copy a onedimensional texture subimage
func CopyTexSubImage1D(target uint32, level int32, xoffset int32, x int32, y int32, width int32) { C.glowCopyTexSubImage1D(gpCopyTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func CopyTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n\tsyscall.Syscall9(gpCopyTextureSubImage2D, 8, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(x), uintptr(y), uintptr(width), uintptr(height), 0)\n}", "func CopyTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTextureSubImage2D(gpCopyTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CopyTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTextureSubImage2D(gpCopyTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CopyTextureSubImage1D(texture uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tsyscall.Syscall6(gpCopyTextureSubImage1D, 6, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(x), uintptr(y), uintptr(width))\n}", "func CopyTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n\tsyscall.Syscall9(gpCopyTextureSubImage3D, 9, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(x), uintptr(y), uintptr(width), uintptr(height))\n}", "func CopyTextureSubImage1D(texture uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tC.glowCopyTextureSubImage1D(gpCopyTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func CopyTextureSubImage1D(texture uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tC.glowCopyTextureSubImage1D(gpCopyTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func CopyTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTextureSubImage3D(gpCopyTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CopyTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTextureSubImage3D(gpCopyTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func (tex Texture) Sub(ctx gl.Context, lvl int, width int, height int, data []byte) {\n\tctx.TexSubImage2D(gl.TEXTURE_2D, lvl, 0, 0, width, height, gl.RGBA, gl.UNSIGNED_BYTE, data)\n\tif lvl > 0 {\n\t\tctx.GenerateMipmap(gl.TEXTURE_2D)\n\t}\n}", "func CopyImageSubData(srcName uint32, srcTarget uint32, srcLevel int32, srcX int32, srcY int32, srcZ int32, dstName uint32, dstTarget uint32, dstLevel int32, dstX int32, dstY int32, dstZ int32, srcWidth int32, srcHeight int32, srcDepth int32) {\n C.glowCopyImageSubData(gpCopyImageSubData, (C.GLuint)(srcName), (C.GLenum)(srcTarget), (C.GLint)(srcLevel), (C.GLint)(srcX), (C.GLint)(srcY), (C.GLint)(srcZ), (C.GLuint)(dstName), (C.GLenum)(dstTarget), (C.GLint)(dstLevel), (C.GLint)(dstX), (C.GLint)(dstY), (C.GLint)(dstZ), (C.GLsizei)(srcWidth), (C.GLsizei)(srcHeight), (C.GLsizei)(srcDepth))\n}", "func CopyImageSubData(srcName uint32, srcTarget uint32, srcLevel int32, srcX int32, srcY int32, srcZ int32, dstName uint32, dstTarget uint32, dstLevel int32, dstX int32, dstY int32, dstZ int32, srcWidth int32, srcHeight int32, srcDepth int32) {\n\tC.glowCopyImageSubData(gpCopyImageSubData, (C.GLuint)(srcName), (C.GLenum)(srcTarget), (C.GLint)(srcLevel), (C.GLint)(srcX), (C.GLint)(srcY), (C.GLint)(srcZ), (C.GLuint)(dstName), (C.GLenum)(dstTarget), (C.GLint)(dstLevel), (C.GLint)(dstX), (C.GLint)(dstY), (C.GLint)(dstZ), (C.GLsizei)(srcWidth), (C.GLsizei)(srcHeight), (C.GLsizei)(srcDepth))\n}", "func CopyImageSubData(srcName uint32, srcTarget uint32, srcLevel int32, srcX int32, srcY int32, srcZ int32, dstName uint32, dstTarget uint32, dstLevel int32, dstX int32, dstY int32, dstZ int32, srcWidth int32, srcHeight int32, srcDepth int32) {\n\tC.glowCopyImageSubData(gpCopyImageSubData, (C.GLuint)(srcName), (C.GLenum)(srcTarget), (C.GLint)(srcLevel), (C.GLint)(srcX), (C.GLint)(srcY), (C.GLint)(srcZ), (C.GLuint)(dstName), (C.GLenum)(dstTarget), (C.GLint)(dstLevel), (C.GLint)(dstX), (C.GLint)(dstY), (C.GLint)(dstZ), (C.GLsizei)(srcWidth), (C.GLsizei)(srcHeight), (C.GLsizei)(srcDepth))\n}", "func CopyTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n C.glowCopyTexSubImage2D(gpCopyTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func TextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTextureSubImage2D, 9, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(width), uintptr(height), uintptr(format), uintptr(xtype), uintptr(pixels))\n}", "func TexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexSubImage2D(gpTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage2D(gpTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage2D(gpTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTextureSubImage1D, 7, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(width), uintptr(format), uintptr(xtype), uintptr(pixels), 0, 0)\n}", "func CopyTexSubImage1D(target uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n C.glowCopyTexSubImage1D(gpCopyTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func GetTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetTextureSubImage(gpGetTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), (C.GLsizei)(bufSize), pixels)\n}", "func GetTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetTextureSubImage(gpGetTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), (C.GLsizei)(bufSize), pixels)\n}", "func CopyImageSubData(srcName uint32, srcTarget uint32, srcLevel int32, srcX int32, srcY int32, srcZ int32, dstName uint32, dstTarget uint32, dstLevel int32, dstX int32, dstY int32, dstZ int32, srcWidth int32, srcHeight int32, srcDepth int32) {\n\tsyscall.Syscall15(gpCopyImageSubData, 15, uintptr(srcName), uintptr(srcTarget), uintptr(srcLevel), uintptr(srcX), uintptr(srcY), uintptr(srcZ), uintptr(dstName), uintptr(dstTarget), uintptr(dstLevel), uintptr(dstX), uintptr(dstY), uintptr(dstZ), uintptr(srcWidth), uintptr(srcHeight), uintptr(srcDepth))\n}", "func CopyTexImage2D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, height int32, border int32) {\n C.glowCopyTexImage2D(gpCopyTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border))\n}", "func CopyTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n\tsyscall.Syscall9(gpCopyTexSubImage2D, 8, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(x), uintptr(y), uintptr(width), uintptr(height), 0)\n}", "func CopyTexImage2D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, height int32, border int32) {\n\tsyscall.Syscall9(gpCopyTexImage2D, 8, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(x), uintptr(y), uintptr(width), uintptr(height), uintptr(border), 0)\n}", "func TexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTexSubImage2D, 9, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(width), uintptr(height), uintptr(format), uintptr(xtype), uintptr(pixels))\n}", "func TextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage1D(gpTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage1D(gpTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func GetTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, bufSize int32, pixels unsafe.Pointer) {\n\tsyscall.Syscall12(gpGetTextureSubImage, 12, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(xtype), uintptr(bufSize), uintptr(pixels))\n}", "func CopyTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTexSubImage2D(gpCopyTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CopyTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTexSubImage2D(gpCopyTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func TexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage2D(gpTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage2D(gpTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage2D(target Enum, level int, x, y, width, height int, format, ty Enum, data []byte) {\n\tgl.TexSubImage2D(uint32(target), int32(level), int32(x), int32(y), int32(width), int32(height), uint32(format), uint32(ty), gl.Ptr(&data[0]))\n}", "func CopyBufferSubData(readTarget uint32, writeTarget uint32, readOffset int, writeOffset int, size int) {\n C.glowCopyBufferSubData(gpCopyBufferSubData, (C.GLenum)(readTarget), (C.GLenum)(writeTarget), (C.GLintptr)(readOffset), (C.GLintptr)(writeOffset), (C.GLsizeiptr)(size))\n}", "func CopyTexImage2D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, height int32, border int32) {\n\tC.glowCopyTexImage2D(gpCopyTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border))\n}", "func CopyTexImage2D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, height int32, border int32) {\n\tC.glowCopyTexImage2D(gpCopyTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border))\n}", "func TexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexSubImage1D(gpTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CopyTexSubImage2D(target GLEnum, level, xoffset, yoffset, x, y, width, height int32) {\n\tgl.CopyTexSubImage2D(uint32(target), level, xoffset, yoffset, x, y, width, height)\n}", "func TextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall12(gpTextureSubImage3D, 11, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(xtype), uintptr(pixels), 0)\n}", "func TextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage3D(gpTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage3D(gpTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CompressedTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage2D(gpCompressedTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage2D(gpCompressedTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CopyTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n C.glowCopyTexSubImage3D(gpCopyTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func (p *Paletted) SubImage(r Rectangle) Image {\n\tr = r.Intersect(p.Rect)\n\t// If r1 and r2 are Rectangles, r1.Intersect(r2) is not guaranteed to be inside\n\t// either r1 or r2 if the intersection is empty. Without explicitly checking for\n\t// this, the Pix[i:] expression below can panic.\n\tif r.Empty() {\n\t\treturn &Paletted{\n\t\t\tPalette: p.Palette,\n\t\t}\n\t}\n\ti := p.PixOffset(r.Min.X, r.Min.Y)\n\treturn &Paletted{\n\t\tPix: p.Pix[i:],\n\t\tStride: p.Stride,\n\t\tRect: p.Rect.Intersect(r),\n\t\tPalette: p.Palette,\n\t}\n}", "func CopyTexSubImage1D(target uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tsyscall.Syscall6(gpCopyTexSubImage1D, 6, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(x), uintptr(y), uintptr(width))\n}", "func CopyTexImage2D(target GLEnum, level int32, internalformat GLEnum, x, y, width, height, border int32) {\n\tgl.CopyTexImage2D(uint32(target), level, uint32(internalformat), x, y, width, height, border)\n}", "func GetCompressedTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetCompressedTextureSubImage(gpGetCompressedTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLsizei)(bufSize), pixels)\n}", "func GetCompressedTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetCompressedTextureSubImage(gpGetCompressedTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLsizei)(bufSize), pixels)\n}", "func CompressedTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTextureSubImage2D, 9, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(width), uintptr(height), uintptr(format), uintptr(imageSize), uintptr(data))\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexSubImage3D(gpTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CopyTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n\tsyscall.Syscall9(gpCopyTexSubImage3D, 9, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(x), uintptr(y), uintptr(width), uintptr(height))\n}", "func CopyImageSubDataNV(hSrcRC unsafe.Pointer, srcName uint32, srcTarget uint32, srcLevel int32, srcX int32, srcY int32, srcZ int32, hDstRC unsafe.Pointer, dstName uint32, dstTarget uint32, dstLevel int32, dstX int32, dstY int32, dstZ int32, width int32, height int32, depth int32) unsafe.Pointer {\n\tpanic(\"\\\"CopyImageSubDataNV\\\" is not implemented\")\n}", "func TexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTexSubImage1D, 7, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(width), uintptr(format), uintptr(xtype), uintptr(pixels), 0, 0)\n}", "func TexSubImage2D(target GLEnum, level, xoffset, yoffset, width, height int32, format, xtype GLEnum, pixels []float32) {\n\tgl.TexSubImage2D(uint32(target), level, xoffset, yoffset, width, height, uint32(format), uint32(xtype), unsafe.Pointer(&pixels[0]))\n}", "func TexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage1D(gpTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage1D(gpTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall12(gpTexSubImage3D, 11, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(xtype), uintptr(pixels), 0)\n}", "func CopyTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTexSubImage3D(gpCopyTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CopyTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTexSubImage3D(gpCopyTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CopyTexSubImage2D(target Enum, level, xoffset, yoffset, x, y, width, height int) {\n\tgl.CopyTexSubImage2D(uint32(target), int32(level), int32(xoffset), int32(yoffset), int32(x), int32(y), int32(width), int32(height))\n}", "func CopyTexImage2D(target Enum, level int, internalformat Enum, x, y, width, height, border int) {\n\tgl.CopyTexImage2D(uint32(target), int32(level), uint32(internalformat), int32(x), int32(y), int32(width), int32(height), int32(border))\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage3D(gpTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage3D(gpTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func (p *Alpha16) SubImage(r Rectangle) Image {\n\tr = r.Intersect(p.Rect)\n\t// If r1 and r2 are Rectangles, r1.Intersect(r2) is not guaranteed to be inside\n\t// either r1 or r2 if the intersection is empty. Without explicitly checking for\n\t// this, the Pix[i:] expression below can panic.\n\tif r.Empty() {\n\t\treturn &Alpha16{}\n\t}\n\ti := p.PixOffset(r.Min.X, r.Min.Y)\n\treturn &Alpha16{\n\t\tPix: p.Pix[i:],\n\t\tStride: p.Stride,\n\t\tRect: r,\n\t}\n}", "func GetCompressedTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, bufSize int32, pixels unsafe.Pointer) {\n\tsyscall.Syscall12(gpGetCompressedTextureSubImage, 10, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(bufSize), uintptr(pixels), 0, 0)\n}", "func TexSubImage2D(target Enum, level Int, xoffset Int, yoffset Int, width Sizei, height Sizei, format Enum, kind Enum, pixels unsafe.Pointer) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tclevel, _ := (C.GLint)(level), cgoAllocsUnknown\n\tcxoffset, _ := (C.GLint)(xoffset), cgoAllocsUnknown\n\tcyoffset, _ := (C.GLint)(yoffset), cgoAllocsUnknown\n\tcwidth, _ := (C.GLsizei)(width), cgoAllocsUnknown\n\tcheight, _ := (C.GLsizei)(height), cgoAllocsUnknown\n\tcformat, _ := (C.GLenum)(format), cgoAllocsUnknown\n\tckind, _ := (C.GLenum)(kind), cgoAllocsUnknown\n\tcpixels, _ := (unsafe.Pointer)(unsafe.Pointer(pixels)), cgoAllocsUnknown\n\tC.glTexSubImage2D(ctarget, clevel, cxoffset, cyoffset, cwidth, cheight, cformat, ckind, cpixels)\n}", "func CopyBufferSubData(readTarget uint32, writeTarget uint32, readOffset int, writeOffset int, size int) {\n\tC.glowCopyBufferSubData(gpCopyBufferSubData, (C.GLenum)(readTarget), (C.GLenum)(writeTarget), (C.GLintptr)(readOffset), (C.GLintptr)(writeOffset), (C.GLsizeiptr)(size))\n}", "func CopyBufferSubData(readTarget uint32, writeTarget uint32, readOffset int, writeOffset int, size int) {\n\tC.glowCopyBufferSubData(gpCopyBufferSubData, (C.GLenum)(readTarget), (C.GLenum)(writeTarget), (C.GLintptr)(readOffset), (C.GLintptr)(writeOffset), (C.GLsizeiptr)(size))\n}", "func CompressedTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage3D(gpCompressedTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage3D(gpCompressedTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CopyTexSubImage2D(target Enum, level Int, xoffset Int, yoffset Int, x Int, y Int, width Sizei, height Sizei) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tclevel, _ := (C.GLint)(level), cgoAllocsUnknown\n\tcxoffset, _ := (C.GLint)(xoffset), cgoAllocsUnknown\n\tcyoffset, _ := (C.GLint)(yoffset), cgoAllocsUnknown\n\tcx, _ := (C.GLint)(x), cgoAllocsUnknown\n\tcy, _ := (C.GLint)(y), cgoAllocsUnknown\n\tcwidth, _ := (C.GLsizei)(width), cgoAllocsUnknown\n\tcheight, _ := (C.GLsizei)(height), cgoAllocsUnknown\n\tC.glCopyTexSubImage2D(ctarget, clevel, cxoffset, cyoffset, cx, cy, cwidth, cheight)\n}", "func CopyColorSubTable(target uint32, start int32, x int32, y int32, width int32) {\n C.glowCopyColorSubTable(gpCopyColorSubTable, (C.GLenum)(target), (C.GLsizei)(start), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func Copy(dst draw.Image, src image.Image) {\n\tbd := src.Bounds().Intersect(dst.Bounds())\n\tat := imageutil.NewAtFunc(src)\n\tset := imageutil.NewSetFunc(dst)\n\timageutil.Parallel1D(bd, func(bd image.Rectangle) {\n\t\tfor y := bd.Min.Y; y < bd.Max.Y; y++ {\n\t\t\tfor x := bd.Min.X; x < bd.Max.X; x++ {\n\t\t\t\tr, g, b, a := at(x, y)\n\t\t\t\tset(x, y, r, g, b, a)\n\t\t\t}\n\t\t}\n\t})\n}", "func CopyTexImage1D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, border int32) {\n C.glowCopyTexImage1D(gpCopyTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLint)(border))\n}", "func CompressedTextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage1D(gpCompressedTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage1D(gpCompressedTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func (s *stencilOverdraw) copyImageAspect(ctx context.Context,\n\tcb CommandBuilder,\n\tgs *api.GlobalState,\n\tst *State,\n\ta arena.Arena,\n\tdevice VkDevice,\n\tcmdBuffer VkCommandBuffer,\n\tsrcImgDesc imageDesc,\n\tdstImgDesc imageDesc,\n\textent VkExtent3D,\n\talloc func(v ...interface{}) api.AllocResult,\n\taddCleanup func(func()),\n\tout transform.Writer,\n) {\n\tsrcImg := srcImgDesc.image\n\tdstImg := dstImgDesc.image\n\tcopyBuffer := s.createDepthCopyBuffer(ctx, cb, gs, st, a, device,\n\t\tsrcImg.Info().Fmt(),\n\t\textent.Width(), extent.Height(),\n\t\talloc, addCleanup, out)\n\n\tallCommandsStage := VkPipelineStageFlags(\n\t\tVkPipelineStageFlagBits_VK_PIPELINE_STAGE_ALL_COMMANDS_BIT)\n\tallMemoryAccess := VkAccessFlags(\n\t\tVkAccessFlagBits_VK_ACCESS_MEMORY_WRITE_BIT |\n\t\t\tVkAccessFlagBits_VK_ACCESS_MEMORY_READ_BIT)\n\n\timgBarriers0 := make([]VkImageMemoryBarrier, 2)\n\timgBarriers1 := make([]VkImageMemoryBarrier, 2)\n\t// Transition the src image in and out of the required layouts\n\timgBarriers0[0] = NewVkImageMemoryBarrier(a,\n\t\tVkStructureType_VK_STRUCTURE_TYPE_IMAGE_MEMORY_BARRIER, // sType\n\t\t0, // pNext\n\t\tallMemoryAccess, // srcAccessMask\n\t\tVkAccessFlags(VkAccessFlagBits_VK_ACCESS_TRANSFER_READ_BIT), // dstAccessMask\n\t\tsrcImgDesc.layout, // oldLayout\n\t\tVkImageLayout_VK_IMAGE_LAYOUT_TRANSFER_SRC_OPTIMAL, // newLayout\n\t\t^uint32(0), // srcQueueFamilyIndex: VK_QUEUE_FAMILY_IGNORED\n\t\t^uint32(0), // dstQueueFamilyIndex\n\t\tsrcImg.VulkanHandle(), // image\n\t\tsrcImgDesc.subresource, // subresourceRange\n\t)\n\tsrcFinalLayout := srcImgDesc.layout\n\tif srcFinalLayout == VkImageLayout_VK_IMAGE_LAYOUT_UNDEFINED ||\n\t\tsrcFinalLayout == VkImageLayout_VK_IMAGE_LAYOUT_PREINITIALIZED {\n\t\tsrcFinalLayout = VkImageLayout_VK_IMAGE_LAYOUT_GENERAL\n\t}\n\timgBarriers1[0] = NewVkImageMemoryBarrier(a,\n\t\tVkStructureType_VK_STRUCTURE_TYPE_IMAGE_MEMORY_BARRIER, // sType\n\t\t0, // pNext\n\t\tVkAccessFlags(VkAccessFlagBits_VK_ACCESS_TRANSFER_READ_BIT), // srcAccessMask\n\t\tallMemoryAccess, // dstAccessMask\n\t\tVkImageLayout_VK_IMAGE_LAYOUT_TRANSFER_SRC_OPTIMAL, // oldLayout\n\t\tsrcFinalLayout, // newLayout\n\t\t^uint32(0), // srcQueueFamilyIndex: VK_QUEUE_FAMILY_IGNORED\n\t\t^uint32(0), // dstQueueFamilyIndex\n\t\tsrcImg.VulkanHandle(), // image\n\t\tsrcImgDesc.subresource, // subresourceRange\n\t)\n\n\t// Transition the new image in and out of its required layouts\n\timgBarriers0[1] = NewVkImageMemoryBarrier(a,\n\t\tVkStructureType_VK_STRUCTURE_TYPE_IMAGE_MEMORY_BARRIER, // sType\n\t\t0, // pNext\n\t\tallMemoryAccess, // srcAccessMask\n\t\tVkAccessFlags(VkAccessFlagBits_VK_ACCESS_TRANSFER_WRITE_BIT), // dstAccessMask\n\t\tdstImgDesc.layout, // oldLayout\n\t\tVkImageLayout_VK_IMAGE_LAYOUT_TRANSFER_DST_OPTIMAL, // newLayout\n\t\t^uint32(0), // srcQueueFamilyIndex: VK_QUEUE_FAMILY_IGNORED\n\t\t^uint32(0), // dstQueueFamilyIndex\n\t\tdstImg.VulkanHandle(), // image\n\t\tdstImgDesc.subresource, // subresourceRange\n\t)\n\n\tdstFinalLayout := dstImgDesc.layout\n\tif dstFinalLayout == VkImageLayout_VK_IMAGE_LAYOUT_UNDEFINED ||\n\t\tdstFinalLayout == VkImageLayout_VK_IMAGE_LAYOUT_PREINITIALIZED {\n\t\tdstFinalLayout = VkImageLayout_VK_IMAGE_LAYOUT_GENERAL\n\t}\n\timgBarriers1[1] = NewVkImageMemoryBarrier(a,\n\t\tVkStructureType_VK_STRUCTURE_TYPE_IMAGE_MEMORY_BARRIER, // sType\n\t\t0, // pNext\n\t\tVkAccessFlags(VkAccessFlagBits_VK_ACCESS_TRANSFER_WRITE_BIT), // srcAccessMask\n\t\tallMemoryAccess, // dstAccessMask\n\t\tVkImageLayout_VK_IMAGE_LAYOUT_TRANSFER_DST_OPTIMAL, // oldLayout\n\t\tdstFinalLayout, // newLayout\n\t\t^uint32(0), // srcQueueFamilyIndex: VK_QUEUE_FAMILY_IGNORED\n\t\t^uint32(0), // dstQueueFamilyIndex\n\t\tdstImg.VulkanHandle(), // image\n\t\tdstImgDesc.subresource, // subresourceRange\n\t)\n\n\tbufBarrier := NewVkBufferMemoryBarrier(a,\n\t\tVkStructureType_VK_STRUCTURE_TYPE_BUFFER_MEMORY_BARRIER, // sType\n\t\t0, // pNext\n\t\tVkAccessFlags(VkAccessFlagBits_VK_ACCESS_TRANSFER_WRITE_BIT), // srcAccessMask\n\t\tVkAccessFlags(VkAccessFlagBits_VK_ACCESS_TRANSFER_READ_BIT), // dstAccessMask\n\t\t^uint32(0), // srcQueueFamilyIndex: VK_QUEUE_FAMILY_IGNORED\n\t\t^uint32(0), // dstQueueFamilyIndex\n\t\tcopyBuffer, // buffer\n\t\t0, // offset\n\t\t^VkDeviceSize(0), // size: VK_WHOLE_SIZE\n\t)\n\n\tibCopy := NewVkBufferImageCopy(a,\n\t\t0, // bufferOffset\n\t\t0, // bufferRowLength\n\t\t0, // bufferImageHeight\n\t\tNewVkImageSubresourceLayers(a,\n\t\t\tVkImageAspectFlags(srcImgDesc.aspect), // aspectMask\n\t\t\tsrcImgDesc.subresource.BaseMipLevel(), // mipLevel\n\t\t\tsrcImgDesc.subresource.BaseArrayLayer(), // baseArrayLayer\n\t\t\t1, // layerCount\n\t\t), // srcSubresource\n\t\tNewVkOffset3D(a, 0, 0, 0), // offset\n\t\tNewVkExtent3D(a, extent.Width(), extent.Height(), 1), // extent\n\t)\n\n\tbiCopy := NewVkBufferImageCopy(a,\n\t\t0, // bufferOffset\n\t\t0, // bufferRowLength\n\t\t0, // bufferImageHeight\n\t\tNewVkImageSubresourceLayers(a,\n\t\t\tVkImageAspectFlags(dstImgDesc.aspect), // aspectMask\n\t\t\tdstImgDesc.subresource.BaseMipLevel(), // mipLevel\n\t\t\tdstImgDesc.subresource.BaseArrayLayer(), // baseArrayLayer\n\t\t\t1, // layerCount\n\t\t), // srcSubresource\n\t\tNewVkOffset3D(a, 0, 0, 0), // offset\n\t\tNewVkExtent3D(a, extent.Width(), extent.Height(), 1), // extent\n\t)\n\n\timgBarriers0Data := alloc(imgBarriers0)\n\tibCopyData := alloc(ibCopy)\n\tbufBarrierData := alloc(bufBarrier)\n\tbiCopyData := alloc(biCopy)\n\timgBarriers1Data := alloc(imgBarriers1)\n\n\twriteEach(ctx, out,\n\t\tcb.VkCmdPipelineBarrier(cmdBuffer,\n\t\t\tallCommandsStage, // srcStageMask\n\t\t\tVkPipelineStageFlags(VkPipelineStageFlagBits_VK_PIPELINE_STAGE_TRANSFER_BIT), // dstStageMask\n\t\t\t0, // dependencyFlags\n\t\t\t0, // memoryBarrierCount\n\t\t\tmemory.Nullptr, // pMemoryBarriers\n\t\t\t0, // bufferMemoryBarrierCount\n\t\t\tmemory.Nullptr, // pBufferMemoryBarriers\n\t\t\t2, // imageMemoryBarrierCount\n\t\t\timgBarriers0Data.Ptr(), // pImageMemoryBarriers\n\t\t).AddRead(imgBarriers0Data.Data()),\n\t\tcb.VkCmdCopyImageToBuffer(cmdBuffer,\n\t\t\tsrcImg.VulkanHandle(), // srcImage\n\t\t\tVkImageLayout_VK_IMAGE_LAYOUT_TRANSFER_SRC_OPTIMAL, // srcImageLayout\n\t\t\tcopyBuffer, // dstBuffer\n\t\t\t1, // regionCount\n\t\t\tibCopyData.Ptr(), // pRegions\n\t\t).AddRead(ibCopyData.Data()),\n\t\tcb.VkCmdPipelineBarrier(cmdBuffer,\n\t\t\tVkPipelineStageFlags(VkPipelineStageFlagBits_VK_PIPELINE_STAGE_TRANSFER_BIT), // srcStageMask\n\t\t\tVkPipelineStageFlags(VkPipelineStageFlagBits_VK_PIPELINE_STAGE_TRANSFER_BIT), // dstStageMask\n\t\t\t0, // dependencyFlags\n\t\t\t0, // memoryBarrierCount\n\t\t\tmemory.Nullptr, // pMemoryBarriers\n\t\t\t1, // bufferMemoryBarrierCount\n\t\t\tbufBarrierData.Ptr(), // pBufferMemoryBarriers\n\t\t\t0, // imageMemoryBarrierCount\n\t\t\tmemory.Nullptr, // pImageMemoryBarriers\n\t\t).AddRead(bufBarrierData.Data()),\n\t\tcb.VkCmdCopyBufferToImage(cmdBuffer,\n\t\t\tcopyBuffer, // srcBuffer\n\t\t\tdstImg.VulkanHandle(), // dstImage\n\t\t\tVkImageLayout_VK_IMAGE_LAYOUT_TRANSFER_DST_OPTIMAL, // dstImageLayout\n\t\t\t1, // regionCount\n\t\t\tbiCopyData.Ptr(), // pRegions\n\t\t).AddRead(biCopyData.Data()),\n\t\tcb.VkCmdPipelineBarrier(cmdBuffer,\n\t\t\tVkPipelineStageFlags(VkPipelineStageFlagBits_VK_PIPELINE_STAGE_TRANSFER_BIT), // srcStageMask\n\t\t\tallCommandsStage, // dstStageMask\n\t\t\t0, // dependencyFlags\n\t\t\t0, // memoryBarrierCount\n\t\t\tmemory.Nullptr, // pMemoryBarriers\n\t\t\t0, // bufferMemoryBarrierCount\n\t\t\tmemory.Nullptr, // pBufferMemoryBarriers\n\t\t\t2, // imageMemoryBarrierCount\n\t\t\timgBarriers1Data.Ptr(), // pImageMemoryBarriers\n\t\t).AddRead(imgBarriers1Data.Data()),\n\t)\n}", "func CopyTexImage1D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, border int32) {\n\tsyscall.Syscall9(gpCopyTexImage1D, 7, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(x), uintptr(y), uintptr(width), uintptr(border), 0, 0)\n}", "func CopyTexImage2D(target Enum, level Int, internalformat Enum, x Int, y Int, width Sizei, height Sizei, border Int) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tclevel, _ := (C.GLint)(level), cgoAllocsUnknown\n\tcinternalformat, _ := (C.GLenum)(internalformat), cgoAllocsUnknown\n\tcx, _ := (C.GLint)(x), cgoAllocsUnknown\n\tcy, _ := (C.GLint)(y), cgoAllocsUnknown\n\tcwidth, _ := (C.GLsizei)(width), cgoAllocsUnknown\n\tcheight, _ := (C.GLsizei)(height), cgoAllocsUnknown\n\tcborder, _ := (C.GLint)(border), cgoAllocsUnknown\n\tC.glCopyTexImage2D(ctarget, clevel, cinternalformat, cx, cy, cwidth, cheight, cborder)\n}", "func CopyColorSubTable(target uint32, start int32, x int32, y int32, width int32) {\n\tC.glowCopyColorSubTable(gpCopyColorSubTable, (C.GLenum)(target), (C.GLsizei)(start), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func CompressedTextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTextureSubImage1D, 7, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(width), uintptr(format), uintptr(imageSize), uintptr(data), 0, 0)\n}", "func CompressedTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall12(gpCompressedTextureSubImage3D, 11, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(imageSize), uintptr(data), 0)\n}", "func (p *NRGBA) SubImage(r Rectangle) Image {\n\tr = r.Intersect(p.Rect)\n\t// If r1 and r2 are Rectangles, r1.Intersect(r2) is not guaranteed to be inside\n\t// either r1 or r2 if the intersection is empty. Without explicitly checking for\n\t// this, the Pix[i:] expression below can panic.\n\tif r.Empty() {\n\t\treturn &NRGBA{}\n\t}\n\ti := p.PixOffset(r.Min.X, r.Min.Y)\n\treturn &NRGBA{\n\t\tPix: p.Pix[i:],\n\t\tStride: p.Stride,\n\t\tRect: r,\n\t}\n}", "func (p *Image64) SubImage(r image.Rectangle) image.Image {\n\tr = r.Intersect(p.Rect)\n\tif r.Empty() {\n\t\treturn &Image64{}\n\t}\n\ti := (r.Min.Y-p.Rect.Min.Y)*p.Stride + (r.Min.X - p.Rect.Min.X)\n\treturn &Image64{\n\t\tPix: p.Pix[i:],\n\t\tStride: p.Stride,\n\t\tRect: r,\n\t}\n}", "func (p *Alpha) SubImage(r Rectangle) Image {\n\tr = r.Intersect(p.Rect)\n\t// If r1 and r2 are Rectangles, r1.Intersect(r2) is not guaranteed to be inside\n\t// either r1 or r2 if the intersection is empty. Without explicitly checking for\n\t// this, the Pix[i:] expression below can panic.\n\tif r.Empty() {\n\t\treturn &Alpha{}\n\t}\n\ti := p.PixOffset(r.Min.X, r.Min.Y)\n\treturn &Alpha{\n\t\tPix: p.Pix[i:],\n\t\tStride: p.Stride,\n\t\tRect: r,\n\t}\n}", "func (t *Texture) Clone() *Texture {\n\tt.p.Call(\"clone\")\n\treturn t\n}", "func (p *NRGBA64) SubImage(r Rectangle) Image {\n\tr = r.Intersect(p.Rect)\n\t// If r1 and r2 are Rectangles, r1.Intersect(r2) is not guaranteed to be inside\n\t// either r1 or r2 if the intersection is empty. Without explicitly checking for\n\t// this, the Pix[i:] expression below can panic.\n\tif r.Empty() {\n\t\treturn &NRGBA64{}\n\t}\n\ti := p.PixOffset(r.Min.X, r.Min.Y)\n\treturn &NRGBA64{\n\t\tPix: p.Pix[i:],\n\t\tStride: p.Stride,\n\t\tRect: r,\n\t}\n}", "func (p *RGBA64) SubImage(r Rectangle) Image {\n\tr = r.Intersect(p.Rect)\n\t// If r1 and r2 are Rectangles, r1.Intersect(r2) is not guaranteed to be inside\n\t// either r1 or r2 if the intersection is empty. Without explicitly checking for\n\t// this, the Pix[i:] expression below can panic.\n\tif r.Empty() {\n\t\treturn &RGBA64{}\n\t}\n\ti := p.PixOffset(r.Min.X, r.Min.Y)\n\treturn &RGBA64{\n\t\tPix: p.Pix[i:],\n\t\tStride: p.Stride,\n\t\tRect: r,\n\t}\n}", "func (p *RGBA) SubImage(r Rectangle) Image {\n\tr = r.Intersect(p.Rect)\n\t// If r1 and r2 are Rectangles, r1.Intersect(r2) is not guaranteed to be inside\n\t// either r1 or r2 if the intersection is empty. Without explicitly checking for\n\t// this, the Pix[i:] expression below can panic.\n\tif r.Empty() {\n\t\treturn &RGBA{}\n\t}\n\ti := p.PixOffset(r.Min.X, r.Min.Y)\n\treturn &RGBA{\n\t\tPix: p.Pix[i:],\n\t\tStride: p.Stride,\n\t\tRect: r,\n\t}\n}", "func (p *CMYK) SubImage(r Rectangle) Image {\n\tr = r.Intersect(p.Rect)\n\t// If r1 and r2 are Rectangles, r1.Intersect(r2) is not guaranteed to be inside\n\t// either r1 or r2 if the intersection is empty. Without explicitly checking for\n\t// this, the Pix[i:] expression below can panic.\n\tif r.Empty() {\n\t\treturn &CMYK{}\n\t}\n\ti := p.PixOffset(r.Min.X, r.Min.Y)\n\treturn &CMYK{\n\t\tPix: p.Pix[i:],\n\t\tStride: p.Stride,\n\t\tRect: r,\n\t}\n}", "func CompressedTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n C.glowCompressedTexSubImage2D(gpCompressedTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func Copy(i ImageIr) ImageIr {\n\tc := make([][][]uint32, len(i.pixels))\n\tcopy(c, i.pixels)\n\treturn ImageIr{i.width, i.height, c}\n}", "func CopyTexImage1D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, border int32) {\n\tC.glowCopyTexImage1D(gpCopyTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLint)(border))\n}", "func CopyTexImage1D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, border int32) {\n\tC.glowCopyTexImage1D(gpCopyTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLint)(border))\n}", "func (p *Gray16) SubImage(r Rectangle) Image {\n\tr = r.Intersect(p.Rect)\n\t// If r1 and r2 are Rectangles, r1.Intersect(r2) is not guaranteed to be inside\n\t// either r1 or r2 if the intersection is empty. Without explicitly checking for\n\t// this, the Pix[i:] expression below can panic.\n\tif r.Empty() {\n\t\treturn &Gray16{}\n\t}\n\ti := p.PixOffset(r.Min.X, r.Min.Y)\n\treturn &Gray16{\n\t\tPix: p.Pix[i:],\n\t\tStride: p.Stride,\n\t\tRect: r,\n\t}\n}", "func (debugging *debuggingOpenGL) TexImage2D(target uint32, level int32, internalFormat uint32, width int32, height int32,\n\tborder int32, format uint32, xtype uint32, pixels interface{}) {\n\tdebugging.recordEntry(\"TexImage2D\", target, level, internalFormat, width, height, border, format, xtype, pixels)\n\tdebugging.gl.TexImage2D(target, level, internalFormat, width, height, border, format, xtype, pixels)\n\tdebugging.recordExit(\"TexImage2D\")\n}" ]
[ "0.7117874", "0.70963943", "0.70963943", "0.70903414", "0.70718455", "0.7063463", "0.7063463", "0.7052369", "0.7052369", "0.6940072", "0.69269633", "0.67217225", "0.67217225", "0.65369076", "0.6529039", "0.6454725", "0.64417475", "0.64417475", "0.6408693", "0.6400633", "0.63795626", "0.63795626", "0.6379457", "0.6364727", "0.632762", "0.6326077", "0.6301789", "0.6292279", "0.6292279", "0.6287277", "0.6266248", "0.6266248", "0.6240501", "0.6240501", "0.62262154", "0.62129086", "0.6209742", "0.6209742", "0.6209355", "0.61751854", "0.617211", "0.61627436", "0.61627436", "0.61595976", "0.61595976", "0.61123353", "0.6098123", "0.60957557", "0.6086926", "0.60831356", "0.60831356", "0.6067833", "0.603852", "0.6004752", "0.5981513", "0.5960467", "0.5954748", "0.5944562", "0.5944562", "0.5942289", "0.5936097", "0.5936097", "0.5926178", "0.5924572", "0.5913153", "0.5913153", "0.5887247", "0.5884108", "0.58702284", "0.5862861", "0.5862861", "0.5854172", "0.5854172", "0.58370775", "0.5826931", "0.5814022", "0.57800496", "0.5773107", "0.5773107", "0.5747387", "0.5727199", "0.5716792", "0.571413", "0.5668436", "0.564562", "0.5644912", "0.5643192", "0.56345206", "0.5595414", "0.559491", "0.55916876", "0.5574803", "0.5573312", "0.5553006", "0.55227524", "0.55146194", "0.55146194", "0.547328", "0.5427419" ]
0.60804605
52
copy a twodimensional texture subimage
func CopyTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) { C.glowCopyTexSubImage2D(gpCopyTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func CopyTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n\tsyscall.Syscall9(gpCopyTextureSubImage2D, 8, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(x), uintptr(y), uintptr(width), uintptr(height), 0)\n}", "func CopyTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTextureSubImage2D(gpCopyTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CopyTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTextureSubImage2D(gpCopyTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CopyTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTextureSubImage3D(gpCopyTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CopyTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTextureSubImage3D(gpCopyTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CopyTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n\tsyscall.Syscall9(gpCopyTextureSubImage3D, 9, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(x), uintptr(y), uintptr(width), uintptr(height))\n}", "func CopyTextureSubImage1D(texture uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tC.glowCopyTextureSubImage1D(gpCopyTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func CopyTextureSubImage1D(texture uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tC.glowCopyTextureSubImage1D(gpCopyTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func CopyTextureSubImage1D(texture uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tsyscall.Syscall6(gpCopyTextureSubImage1D, 6, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(x), uintptr(y), uintptr(width))\n}", "func (tex Texture) Sub(ctx gl.Context, lvl int, width int, height int, data []byte) {\n\tctx.TexSubImage2D(gl.TEXTURE_2D, lvl, 0, 0, width, height, gl.RGBA, gl.UNSIGNED_BYTE, data)\n\tif lvl > 0 {\n\t\tctx.GenerateMipmap(gl.TEXTURE_2D)\n\t}\n}", "func TextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTextureSubImage2D, 9, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(width), uintptr(height), uintptr(format), uintptr(xtype), uintptr(pixels))\n}", "func CopyTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n C.glowCopyTexSubImage2D(gpCopyTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func TextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage2D(gpTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage2D(gpTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexSubImage2D(gpTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CopyImageSubData(srcName uint32, srcTarget uint32, srcLevel int32, srcX int32, srcY int32, srcZ int32, dstName uint32, dstTarget uint32, dstLevel int32, dstX int32, dstY int32, dstZ int32, srcWidth int32, srcHeight int32, srcDepth int32) {\n C.glowCopyImageSubData(gpCopyImageSubData, (C.GLuint)(srcName), (C.GLenum)(srcTarget), (C.GLint)(srcLevel), (C.GLint)(srcX), (C.GLint)(srcY), (C.GLint)(srcZ), (C.GLuint)(dstName), (C.GLenum)(dstTarget), (C.GLint)(dstLevel), (C.GLint)(dstX), (C.GLint)(dstY), (C.GLint)(dstZ), (C.GLsizei)(srcWidth), (C.GLsizei)(srcHeight), (C.GLsizei)(srcDepth))\n}", "func CopyTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n\tsyscall.Syscall9(gpCopyTexSubImage2D, 8, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(x), uintptr(y), uintptr(width), uintptr(height), 0)\n}", "func TexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTexSubImage2D, 9, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(width), uintptr(height), uintptr(format), uintptr(xtype), uintptr(pixels))\n}", "func GetTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetTextureSubImage(gpGetTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), (C.GLsizei)(bufSize), pixels)\n}", "func GetTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetTextureSubImage(gpGetTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), (C.GLsizei)(bufSize), pixels)\n}", "func TexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage2D(gpTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage2D(gpTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CopyTexImage2D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, height int32, border int32) {\n C.glowCopyTexImage2D(gpCopyTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border))\n}", "func GetTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, bufSize int32, pixels unsafe.Pointer) {\n\tsyscall.Syscall12(gpGetTextureSubImage, 12, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(xtype), uintptr(bufSize), uintptr(pixels))\n}", "func CopyTexImage2D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, height int32, border int32) {\n\tsyscall.Syscall9(gpCopyTexImage2D, 8, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(x), uintptr(y), uintptr(width), uintptr(height), uintptr(border), 0)\n}", "func TexSubImage2D(target Enum, level int, x, y, width, height int, format, ty Enum, data []byte) {\n\tgl.TexSubImage2D(uint32(target), int32(level), int32(x), int32(y), int32(width), int32(height), uint32(format), uint32(ty), gl.Ptr(&data[0]))\n}", "func CopyTexSubImage2D(target GLEnum, level, xoffset, yoffset, x, y, width, height int32) {\n\tgl.CopyTexSubImage2D(uint32(target), level, xoffset, yoffset, x, y, width, height)\n}", "func CopyImageSubData(srcName uint32, srcTarget uint32, srcLevel int32, srcX int32, srcY int32, srcZ int32, dstName uint32, dstTarget uint32, dstLevel int32, dstX int32, dstY int32, dstZ int32, srcWidth int32, srcHeight int32, srcDepth int32) {\n\tC.glowCopyImageSubData(gpCopyImageSubData, (C.GLuint)(srcName), (C.GLenum)(srcTarget), (C.GLint)(srcLevel), (C.GLint)(srcX), (C.GLint)(srcY), (C.GLint)(srcZ), (C.GLuint)(dstName), (C.GLenum)(dstTarget), (C.GLint)(dstLevel), (C.GLint)(dstX), (C.GLint)(dstY), (C.GLint)(dstZ), (C.GLsizei)(srcWidth), (C.GLsizei)(srcHeight), (C.GLsizei)(srcDepth))\n}", "func CopyImageSubData(srcName uint32, srcTarget uint32, srcLevel int32, srcX int32, srcY int32, srcZ int32, dstName uint32, dstTarget uint32, dstLevel int32, dstX int32, dstY int32, dstZ int32, srcWidth int32, srcHeight int32, srcDepth int32) {\n\tC.glowCopyImageSubData(gpCopyImageSubData, (C.GLuint)(srcName), (C.GLenum)(srcTarget), (C.GLint)(srcLevel), (C.GLint)(srcX), (C.GLint)(srcY), (C.GLint)(srcZ), (C.GLuint)(dstName), (C.GLenum)(dstTarget), (C.GLint)(dstLevel), (C.GLint)(dstX), (C.GLint)(dstY), (C.GLint)(dstZ), (C.GLsizei)(srcWidth), (C.GLsizei)(srcHeight), (C.GLsizei)(srcDepth))\n}", "func CompressedTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage2D(gpCompressedTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage2D(gpCompressedTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CopyTexImage2D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, height int32, border int32) {\n\tC.glowCopyTexImage2D(gpCopyTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border))\n}", "func CopyTexImage2D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, height int32, border int32) {\n\tC.glowCopyTexImage2D(gpCopyTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border))\n}", "func CompressedTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTextureSubImage2D, 9, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(width), uintptr(height), uintptr(format), uintptr(imageSize), uintptr(data))\n}", "func TextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTextureSubImage1D, 7, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(width), uintptr(format), uintptr(xtype), uintptr(pixels), 0, 0)\n}", "func CopyTexSubImage1D(target uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n C.glowCopyTexSubImage1D(gpCopyTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func CopyTexImage2D(target GLEnum, level int32, internalformat GLEnum, x, y, width, height, border int32) {\n\tgl.CopyTexImage2D(uint32(target), level, uint32(internalformat), x, y, width, height, border)\n}", "func TexSubImage2D(target GLEnum, level, xoffset, yoffset, width, height int32, format, xtype GLEnum, pixels []float32) {\n\tgl.TexSubImage2D(uint32(target), level, xoffset, yoffset, width, height, uint32(format), uint32(xtype), unsafe.Pointer(&pixels[0]))\n}", "func CopyTexSubImage2D(target Enum, level, xoffset, yoffset, x, y, width, height int) {\n\tgl.CopyTexSubImage2D(uint32(target), int32(level), int32(xoffset), int32(yoffset), int32(x), int32(y), int32(width), int32(height))\n}", "func TextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage1D(gpTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage1D(gpTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage2D(target Enum, level Int, xoffset Int, yoffset Int, width Sizei, height Sizei, format Enum, kind Enum, pixels unsafe.Pointer) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tclevel, _ := (C.GLint)(level), cgoAllocsUnknown\n\tcxoffset, _ := (C.GLint)(xoffset), cgoAllocsUnknown\n\tcyoffset, _ := (C.GLint)(yoffset), cgoAllocsUnknown\n\tcwidth, _ := (C.GLsizei)(width), cgoAllocsUnknown\n\tcheight, _ := (C.GLsizei)(height), cgoAllocsUnknown\n\tcformat, _ := (C.GLenum)(format), cgoAllocsUnknown\n\tckind, _ := (C.GLenum)(kind), cgoAllocsUnknown\n\tcpixels, _ := (unsafe.Pointer)(unsafe.Pointer(pixels)), cgoAllocsUnknown\n\tC.glTexSubImage2D(ctarget, clevel, cxoffset, cyoffset, cwidth, cheight, cformat, ckind, cpixels)\n}", "func CopyTexSubImage2D(target Enum, level Int, xoffset Int, yoffset Int, x Int, y Int, width Sizei, height Sizei) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tclevel, _ := (C.GLint)(level), cgoAllocsUnknown\n\tcxoffset, _ := (C.GLint)(xoffset), cgoAllocsUnknown\n\tcyoffset, _ := (C.GLint)(yoffset), cgoAllocsUnknown\n\tcx, _ := (C.GLint)(x), cgoAllocsUnknown\n\tcy, _ := (C.GLint)(y), cgoAllocsUnknown\n\tcwidth, _ := (C.GLsizei)(width), cgoAllocsUnknown\n\tcheight, _ := (C.GLsizei)(height), cgoAllocsUnknown\n\tC.glCopyTexSubImage2D(ctarget, clevel, cxoffset, cyoffset, cx, cy, cwidth, cheight)\n}", "func GetCompressedTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetCompressedTextureSubImage(gpGetCompressedTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLsizei)(bufSize), pixels)\n}", "func GetCompressedTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetCompressedTextureSubImage(gpGetCompressedTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLsizei)(bufSize), pixels)\n}", "func TextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage3D(gpTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage3D(gpTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall12(gpTextureSubImage3D, 11, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(xtype), uintptr(pixels), 0)\n}", "func CopyBufferSubData(readTarget uint32, writeTarget uint32, readOffset int, writeOffset int, size int) {\n C.glowCopyBufferSubData(gpCopyBufferSubData, (C.GLenum)(readTarget), (C.GLenum)(writeTarget), (C.GLintptr)(readOffset), (C.GLintptr)(writeOffset), (C.GLsizeiptr)(size))\n}", "func CopyImageSubData(srcName uint32, srcTarget uint32, srcLevel int32, srcX int32, srcY int32, srcZ int32, dstName uint32, dstTarget uint32, dstLevel int32, dstX int32, dstY int32, dstZ int32, srcWidth int32, srcHeight int32, srcDepth int32) {\n\tsyscall.Syscall15(gpCopyImageSubData, 15, uintptr(srcName), uintptr(srcTarget), uintptr(srcLevel), uintptr(srcX), uintptr(srcY), uintptr(srcZ), uintptr(dstName), uintptr(dstTarget), uintptr(dstLevel), uintptr(dstX), uintptr(dstY), uintptr(dstZ), uintptr(srcWidth), uintptr(srcHeight), uintptr(srcDepth))\n}", "func CopyTexImage2D(target Enum, level int, internalformat Enum, x, y, width, height, border int) {\n\tgl.CopyTexImage2D(uint32(target), int32(level), uint32(internalformat), int32(x), int32(y), int32(width), int32(height), int32(border))\n}", "func TexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexSubImage1D(gpTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CopyTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n C.glowCopyTexSubImage3D(gpCopyTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func GetCompressedTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, bufSize int32, pixels unsafe.Pointer) {\n\tsyscall.Syscall12(gpGetCompressedTextureSubImage, 10, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(bufSize), uintptr(pixels), 0, 0)\n}", "func CopyTexImage2D(target Enum, level Int, internalformat Enum, x Int, y Int, width Sizei, height Sizei, border Int) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tclevel, _ := (C.GLint)(level), cgoAllocsUnknown\n\tcinternalformat, _ := (C.GLenum)(internalformat), cgoAllocsUnknown\n\tcx, _ := (C.GLint)(x), cgoAllocsUnknown\n\tcy, _ := (C.GLint)(y), cgoAllocsUnknown\n\tcwidth, _ := (C.GLsizei)(width), cgoAllocsUnknown\n\tcheight, _ := (C.GLsizei)(height), cgoAllocsUnknown\n\tcborder, _ := (C.GLint)(border), cgoAllocsUnknown\n\tC.glCopyTexImage2D(ctarget, clevel, cinternalformat, cx, cy, cwidth, cheight, cborder)\n}", "func CopyColorSubTable(target uint32, start int32, x int32, y int32, width int32) {\n C.glowCopyColorSubTable(gpCopyColorSubTable, (C.GLenum)(target), (C.GLsizei)(start), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func CopyTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n\tsyscall.Syscall9(gpCopyTexSubImage3D, 9, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(x), uintptr(y), uintptr(width), uintptr(height))\n}", "func CopyTexSubImage1D(target uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tC.glowCopyTexSubImage1D(gpCopyTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func CopyTexSubImage1D(target uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tC.glowCopyTexSubImage1D(gpCopyTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexSubImage3D(gpTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CopyTexSubImage1D(target uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tsyscall.Syscall6(gpCopyTexSubImage1D, 6, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(x), uintptr(y), uintptr(width))\n}", "func CopyTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTexSubImage3D(gpCopyTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CopyTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTexSubImage3D(gpCopyTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CopyBufferSubData(readTarget uint32, writeTarget uint32, readOffset int, writeOffset int, size int) {\n\tC.glowCopyBufferSubData(gpCopyBufferSubData, (C.GLenum)(readTarget), (C.GLenum)(writeTarget), (C.GLintptr)(readOffset), (C.GLintptr)(writeOffset), (C.GLsizeiptr)(size))\n}", "func CopyBufferSubData(readTarget uint32, writeTarget uint32, readOffset int, writeOffset int, size int) {\n\tC.glowCopyBufferSubData(gpCopyBufferSubData, (C.GLenum)(readTarget), (C.GLenum)(writeTarget), (C.GLintptr)(readOffset), (C.GLintptr)(writeOffset), (C.GLsizeiptr)(size))\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall12(gpTexSubImage3D, 11, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(xtype), uintptr(pixels), 0)\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage3D(gpTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage3D(gpTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CopyColorSubTable(target uint32, start int32, x int32, y int32, width int32) {\n\tC.glowCopyColorSubTable(gpCopyColorSubTable, (C.GLenum)(target), (C.GLsizei)(start), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func TexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage1D(gpTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage1D(gpTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTexSubImage1D, 7, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(width), uintptr(format), uintptr(xtype), uintptr(pixels), 0, 0)\n}", "func CompressedTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage3D(gpCompressedTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage3D(gpCompressedTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n C.glowCompressedTexSubImage2D(gpCompressedTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTexImage2D, 9, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(width), uintptr(height), uintptr(border), uintptr(format), uintptr(xtype), uintptr(pixels))\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexImage2D(gpTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CopyImageSubDataNV(hSrcRC unsafe.Pointer, srcName uint32, srcTarget uint32, srcLevel int32, srcX int32, srcY int32, srcZ int32, hDstRC unsafe.Pointer, dstName uint32, dstTarget uint32, dstLevel int32, dstX int32, dstY int32, dstZ int32, width int32, height int32, depth int32) unsafe.Pointer {\n\tpanic(\"\\\"CopyImageSubDataNV\\\" is not implemented\")\n}", "func (t *Texture) Clone() *Texture {\n\tt.p.Call(\"clone\")\n\treturn t\n}", "func Copy(dst draw.Image, src image.Image) {\n\tbd := src.Bounds().Intersect(dst.Bounds())\n\tat := imageutil.NewAtFunc(src)\n\tset := imageutil.NewSetFunc(dst)\n\timageutil.Parallel1D(bd, func(bd image.Rectangle) {\n\t\tfor y := bd.Min.Y; y < bd.Max.Y; y++ {\n\t\t\tfor x := bd.Min.X; x < bd.Max.X; x++ {\n\t\t\t\tr, g, b, a := at(x, y)\n\t\t\t\tset(x, y, r, g, b, a)\n\t\t\t}\n\t\t}\n\t})\n}", "func CompressedTextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage1D(gpCompressedTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage1D(gpCompressedTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func (p *Paletted) SubImage(r Rectangle) Image {\n\tr = r.Intersect(p.Rect)\n\t// If r1 and r2 are Rectangles, r1.Intersect(r2) is not guaranteed to be inside\n\t// either r1 or r2 if the intersection is empty. Without explicitly checking for\n\t// this, the Pix[i:] expression below can panic.\n\tif r.Empty() {\n\t\treturn &Paletted{\n\t\t\tPalette: p.Palette,\n\t\t}\n\t}\n\ti := p.PixOffset(r.Min.X, r.Min.Y)\n\treturn &Paletted{\n\t\tPix: p.Pix[i:],\n\t\tStride: p.Stride,\n\t\tRect: p.Rect.Intersect(r),\n\t\tPalette: p.Palette,\n\t}\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexImage2D(gpTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexImage2D(gpTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CompressedTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall12(gpCompressedTextureSubImage3D, 11, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(imageSize), uintptr(data), 0)\n}", "func (debugging *debuggingOpenGL) TexImage2D(target uint32, level int32, internalFormat uint32, width int32, height int32,\n\tborder int32, format uint32, xtype uint32, pixels interface{}) {\n\tdebugging.recordEntry(\"TexImage2D\", target, level, internalFormat, width, height, border, format, xtype, pixels)\n\tdebugging.gl.TexImage2D(target, level, internalFormat, width, height, border, format, xtype, pixels)\n\tdebugging.recordExit(\"TexImage2D\")\n}", "func TexImage2D(target Enum, level int, width, height int, format Enum, ty Enum, data []byte) {\n\tp := unsafe.Pointer(nil)\n\tif len(data) > 0 {\n\t\tp = gl.Ptr(&data[0])\n\t}\n\tgl.TexImage2D(uint32(target), int32(level), int32(format), int32(width), int32(height), 0, uint32(format), uint32(ty), p)\n}", "func CompressedTextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTextureSubImage1D, 7, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(width), uintptr(format), uintptr(imageSize), uintptr(data), 0, 0)\n}", "func TexImage2D(target GLEnum, level int32, internalformat GLEnum, width, height, border int32, format, xtype GLEnum, pixels []float32) {\n\tgl.TexImage2D(uint32(target), level, int32(internalformat), width, height, border, uint32(format), uint32(xtype), unsafe.Pointer(&pixels[0]))\n}", "func CopyTexImage1D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, border int32) {\n C.glowCopyTexImage1D(gpCopyTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLint)(border))\n}", "func (s *stencilOverdraw) copyImageAspect(ctx context.Context,\n\tcb CommandBuilder,\n\tgs *api.GlobalState,\n\tst *State,\n\ta arena.Arena,\n\tdevice VkDevice,\n\tcmdBuffer VkCommandBuffer,\n\tsrcImgDesc imageDesc,\n\tdstImgDesc imageDesc,\n\textent VkExtent3D,\n\talloc func(v ...interface{}) api.AllocResult,\n\taddCleanup func(func()),\n\tout transform.Writer,\n) {\n\tsrcImg := srcImgDesc.image\n\tdstImg := dstImgDesc.image\n\tcopyBuffer := s.createDepthCopyBuffer(ctx, cb, gs, st, a, device,\n\t\tsrcImg.Info().Fmt(),\n\t\textent.Width(), extent.Height(),\n\t\talloc, addCleanup, out)\n\n\tallCommandsStage := VkPipelineStageFlags(\n\t\tVkPipelineStageFlagBits_VK_PIPELINE_STAGE_ALL_COMMANDS_BIT)\n\tallMemoryAccess := VkAccessFlags(\n\t\tVkAccessFlagBits_VK_ACCESS_MEMORY_WRITE_BIT |\n\t\t\tVkAccessFlagBits_VK_ACCESS_MEMORY_READ_BIT)\n\n\timgBarriers0 := make([]VkImageMemoryBarrier, 2)\n\timgBarriers1 := make([]VkImageMemoryBarrier, 2)\n\t// Transition the src image in and out of the required layouts\n\timgBarriers0[0] = NewVkImageMemoryBarrier(a,\n\t\tVkStructureType_VK_STRUCTURE_TYPE_IMAGE_MEMORY_BARRIER, // sType\n\t\t0, // pNext\n\t\tallMemoryAccess, // srcAccessMask\n\t\tVkAccessFlags(VkAccessFlagBits_VK_ACCESS_TRANSFER_READ_BIT), // dstAccessMask\n\t\tsrcImgDesc.layout, // oldLayout\n\t\tVkImageLayout_VK_IMAGE_LAYOUT_TRANSFER_SRC_OPTIMAL, // newLayout\n\t\t^uint32(0), // srcQueueFamilyIndex: VK_QUEUE_FAMILY_IGNORED\n\t\t^uint32(0), // dstQueueFamilyIndex\n\t\tsrcImg.VulkanHandle(), // image\n\t\tsrcImgDesc.subresource, // subresourceRange\n\t)\n\tsrcFinalLayout := srcImgDesc.layout\n\tif srcFinalLayout == VkImageLayout_VK_IMAGE_LAYOUT_UNDEFINED ||\n\t\tsrcFinalLayout == VkImageLayout_VK_IMAGE_LAYOUT_PREINITIALIZED {\n\t\tsrcFinalLayout = VkImageLayout_VK_IMAGE_LAYOUT_GENERAL\n\t}\n\timgBarriers1[0] = NewVkImageMemoryBarrier(a,\n\t\tVkStructureType_VK_STRUCTURE_TYPE_IMAGE_MEMORY_BARRIER, // sType\n\t\t0, // pNext\n\t\tVkAccessFlags(VkAccessFlagBits_VK_ACCESS_TRANSFER_READ_BIT), // srcAccessMask\n\t\tallMemoryAccess, // dstAccessMask\n\t\tVkImageLayout_VK_IMAGE_LAYOUT_TRANSFER_SRC_OPTIMAL, // oldLayout\n\t\tsrcFinalLayout, // newLayout\n\t\t^uint32(0), // srcQueueFamilyIndex: VK_QUEUE_FAMILY_IGNORED\n\t\t^uint32(0), // dstQueueFamilyIndex\n\t\tsrcImg.VulkanHandle(), // image\n\t\tsrcImgDesc.subresource, // subresourceRange\n\t)\n\n\t// Transition the new image in and out of its required layouts\n\timgBarriers0[1] = NewVkImageMemoryBarrier(a,\n\t\tVkStructureType_VK_STRUCTURE_TYPE_IMAGE_MEMORY_BARRIER, // sType\n\t\t0, // pNext\n\t\tallMemoryAccess, // srcAccessMask\n\t\tVkAccessFlags(VkAccessFlagBits_VK_ACCESS_TRANSFER_WRITE_BIT), // dstAccessMask\n\t\tdstImgDesc.layout, // oldLayout\n\t\tVkImageLayout_VK_IMAGE_LAYOUT_TRANSFER_DST_OPTIMAL, // newLayout\n\t\t^uint32(0), // srcQueueFamilyIndex: VK_QUEUE_FAMILY_IGNORED\n\t\t^uint32(0), // dstQueueFamilyIndex\n\t\tdstImg.VulkanHandle(), // image\n\t\tdstImgDesc.subresource, // subresourceRange\n\t)\n\n\tdstFinalLayout := dstImgDesc.layout\n\tif dstFinalLayout == VkImageLayout_VK_IMAGE_LAYOUT_UNDEFINED ||\n\t\tdstFinalLayout == VkImageLayout_VK_IMAGE_LAYOUT_PREINITIALIZED {\n\t\tdstFinalLayout = VkImageLayout_VK_IMAGE_LAYOUT_GENERAL\n\t}\n\timgBarriers1[1] = NewVkImageMemoryBarrier(a,\n\t\tVkStructureType_VK_STRUCTURE_TYPE_IMAGE_MEMORY_BARRIER, // sType\n\t\t0, // pNext\n\t\tVkAccessFlags(VkAccessFlagBits_VK_ACCESS_TRANSFER_WRITE_BIT), // srcAccessMask\n\t\tallMemoryAccess, // dstAccessMask\n\t\tVkImageLayout_VK_IMAGE_LAYOUT_TRANSFER_DST_OPTIMAL, // oldLayout\n\t\tdstFinalLayout, // newLayout\n\t\t^uint32(0), // srcQueueFamilyIndex: VK_QUEUE_FAMILY_IGNORED\n\t\t^uint32(0), // dstQueueFamilyIndex\n\t\tdstImg.VulkanHandle(), // image\n\t\tdstImgDesc.subresource, // subresourceRange\n\t)\n\n\tbufBarrier := NewVkBufferMemoryBarrier(a,\n\t\tVkStructureType_VK_STRUCTURE_TYPE_BUFFER_MEMORY_BARRIER, // sType\n\t\t0, // pNext\n\t\tVkAccessFlags(VkAccessFlagBits_VK_ACCESS_TRANSFER_WRITE_BIT), // srcAccessMask\n\t\tVkAccessFlags(VkAccessFlagBits_VK_ACCESS_TRANSFER_READ_BIT), // dstAccessMask\n\t\t^uint32(0), // srcQueueFamilyIndex: VK_QUEUE_FAMILY_IGNORED\n\t\t^uint32(0), // dstQueueFamilyIndex\n\t\tcopyBuffer, // buffer\n\t\t0, // offset\n\t\t^VkDeviceSize(0), // size: VK_WHOLE_SIZE\n\t)\n\n\tibCopy := NewVkBufferImageCopy(a,\n\t\t0, // bufferOffset\n\t\t0, // bufferRowLength\n\t\t0, // bufferImageHeight\n\t\tNewVkImageSubresourceLayers(a,\n\t\t\tVkImageAspectFlags(srcImgDesc.aspect), // aspectMask\n\t\t\tsrcImgDesc.subresource.BaseMipLevel(), // mipLevel\n\t\t\tsrcImgDesc.subresource.BaseArrayLayer(), // baseArrayLayer\n\t\t\t1, // layerCount\n\t\t), // srcSubresource\n\t\tNewVkOffset3D(a, 0, 0, 0), // offset\n\t\tNewVkExtent3D(a, extent.Width(), extent.Height(), 1), // extent\n\t)\n\n\tbiCopy := NewVkBufferImageCopy(a,\n\t\t0, // bufferOffset\n\t\t0, // bufferRowLength\n\t\t0, // bufferImageHeight\n\t\tNewVkImageSubresourceLayers(a,\n\t\t\tVkImageAspectFlags(dstImgDesc.aspect), // aspectMask\n\t\t\tdstImgDesc.subresource.BaseMipLevel(), // mipLevel\n\t\t\tdstImgDesc.subresource.BaseArrayLayer(), // baseArrayLayer\n\t\t\t1, // layerCount\n\t\t), // srcSubresource\n\t\tNewVkOffset3D(a, 0, 0, 0), // offset\n\t\tNewVkExtent3D(a, extent.Width(), extent.Height(), 1), // extent\n\t)\n\n\timgBarriers0Data := alloc(imgBarriers0)\n\tibCopyData := alloc(ibCopy)\n\tbufBarrierData := alloc(bufBarrier)\n\tbiCopyData := alloc(biCopy)\n\timgBarriers1Data := alloc(imgBarriers1)\n\n\twriteEach(ctx, out,\n\t\tcb.VkCmdPipelineBarrier(cmdBuffer,\n\t\t\tallCommandsStage, // srcStageMask\n\t\t\tVkPipelineStageFlags(VkPipelineStageFlagBits_VK_PIPELINE_STAGE_TRANSFER_BIT), // dstStageMask\n\t\t\t0, // dependencyFlags\n\t\t\t0, // memoryBarrierCount\n\t\t\tmemory.Nullptr, // pMemoryBarriers\n\t\t\t0, // bufferMemoryBarrierCount\n\t\t\tmemory.Nullptr, // pBufferMemoryBarriers\n\t\t\t2, // imageMemoryBarrierCount\n\t\t\timgBarriers0Data.Ptr(), // pImageMemoryBarriers\n\t\t).AddRead(imgBarriers0Data.Data()),\n\t\tcb.VkCmdCopyImageToBuffer(cmdBuffer,\n\t\t\tsrcImg.VulkanHandle(), // srcImage\n\t\t\tVkImageLayout_VK_IMAGE_LAYOUT_TRANSFER_SRC_OPTIMAL, // srcImageLayout\n\t\t\tcopyBuffer, // dstBuffer\n\t\t\t1, // regionCount\n\t\t\tibCopyData.Ptr(), // pRegions\n\t\t).AddRead(ibCopyData.Data()),\n\t\tcb.VkCmdPipelineBarrier(cmdBuffer,\n\t\t\tVkPipelineStageFlags(VkPipelineStageFlagBits_VK_PIPELINE_STAGE_TRANSFER_BIT), // srcStageMask\n\t\t\tVkPipelineStageFlags(VkPipelineStageFlagBits_VK_PIPELINE_STAGE_TRANSFER_BIT), // dstStageMask\n\t\t\t0, // dependencyFlags\n\t\t\t0, // memoryBarrierCount\n\t\t\tmemory.Nullptr, // pMemoryBarriers\n\t\t\t1, // bufferMemoryBarrierCount\n\t\t\tbufBarrierData.Ptr(), // pBufferMemoryBarriers\n\t\t\t0, // imageMemoryBarrierCount\n\t\t\tmemory.Nullptr, // pImageMemoryBarriers\n\t\t).AddRead(bufBarrierData.Data()),\n\t\tcb.VkCmdCopyBufferToImage(cmdBuffer,\n\t\t\tcopyBuffer, // srcBuffer\n\t\t\tdstImg.VulkanHandle(), // dstImage\n\t\t\tVkImageLayout_VK_IMAGE_LAYOUT_TRANSFER_DST_OPTIMAL, // dstImageLayout\n\t\t\t1, // regionCount\n\t\t\tbiCopyData.Ptr(), // pRegions\n\t\t).AddRead(biCopyData.Data()),\n\t\tcb.VkCmdPipelineBarrier(cmdBuffer,\n\t\t\tVkPipelineStageFlags(VkPipelineStageFlagBits_VK_PIPELINE_STAGE_TRANSFER_BIT), // srcStageMask\n\t\t\tallCommandsStage, // dstStageMask\n\t\t\t0, // dependencyFlags\n\t\t\t0, // memoryBarrierCount\n\t\t\tmemory.Nullptr, // pMemoryBarriers\n\t\t\t0, // bufferMemoryBarrierCount\n\t\t\tmemory.Nullptr, // pBufferMemoryBarriers\n\t\t\t2, // imageMemoryBarrierCount\n\t\t\timgBarriers1Data.Ptr(), // pImageMemoryBarriers\n\t\t).AddRead(imgBarriers1Data.Data()),\n\t)\n}", "func CopyTexImage1D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, border int32) {\n\tsyscall.Syscall9(gpCopyTexImage1D, 7, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(x), uintptr(y), uintptr(width), uintptr(border), 0, 0)\n}", "func (p *Alpha16) SubImage(r Rectangle) Image {\n\tr = r.Intersect(p.Rect)\n\t// If r1 and r2 are Rectangles, r1.Intersect(r2) is not guaranteed to be inside\n\t// either r1 or r2 if the intersection is empty. Without explicitly checking for\n\t// this, the Pix[i:] expression below can panic.\n\tif r.Empty() {\n\t\treturn &Alpha16{}\n\t}\n\ti := p.PixOffset(r.Min.X, r.Min.Y)\n\treturn &Alpha16{\n\t\tPix: p.Pix[i:],\n\t\tStride: p.Stride,\n\t\tRect: r,\n\t}\n}", "func Transverse(img image.Image) *image.NRGBA {\n\tsrc := toNRGBA(img)\n\tsrcW := src.Bounds().Max.X\n\tsrcH := src.Bounds().Max.Y\n\tdstW := srcH\n\tdstH := srcW\n\tdst := image.NewNRGBA(image.Rect(0, 0, dstW, dstH))\n\n\tparallel(dstH, func(partStart, partEnd int) {\n\n\t\tfor dstY := partStart; dstY < partEnd; dstY++ {\n\t\t\tfor dstX := 0; dstX < dstW; dstX++ {\n\t\t\t\tsrcX := dstH - dstY - 1\n\t\t\t\tsrcY := dstW - dstX - 1\n\n\t\t\t\tsrcOff := srcY*src.Stride + srcX*4\n\t\t\t\tdstOff := dstY*dst.Stride + dstX*4\n\n\t\t\t\tcopy(dst.Pix[dstOff:dstOff+4], src.Pix[srcOff:srcOff+4])\n\t\t\t}\n\t\t}\n\n\t})\n\n\treturn dst\n}", "func (native *OpenGL) TexImage2D(target uint32, level int32, internalFormat uint32, width int32, height int32,\n\tborder int32, format uint32, xtype uint32, pixels interface{}) {\n\tptr, isPointer := pixels.(unsafe.Pointer)\n\tif isPointer {\n\t\tgl.TexImage2D(target, level, int32(internalFormat), width, height, border, format, xtype, ptr)\n\t} else {\n\t\tgl.TexImage2D(target, level, int32(internalFormat), width, height, border, format, xtype, gl.Ptr(pixels))\n\t}\n}", "func downsample(srcImg image.Image) image.Image {\n\tbounds := srcImg.Bounds()\n\treturn resize.Resize(bounds.Dx()/2, bounds.Dy()/2, srcImg, resize.Bilinear)\n}", "func Copy(i ImageIr) ImageIr {\n\tc := make([][][]uint32, len(i.pixels))\n\tcopy(c, i.pixels)\n\treturn ImageIr{i.width, i.height, c}\n}", "func (w *WebGLRenderTarget) Copy(source *WebGLRenderTarget) *WebGLRenderTarget {\n\tw.p.Call(\"copy\", source.p)\n\treturn w\n}" ]
[ "0.74930286", "0.748996", "0.748996", "0.7101118", "0.7101118", "0.708496", "0.70273286", "0.70273286", "0.70271516", "0.6888059", "0.68646353", "0.6819994", "0.6789447", "0.6789447", "0.6698773", "0.66529685", "0.6626014", "0.65730363", "0.6569772", "0.6569772", "0.6524741", "0.6524741", "0.65014005", "0.64738697", "0.64709604", "0.6463622", "0.64520264", "0.64305305", "0.64305305", "0.6424487", "0.6424487", "0.6358789", "0.6358789", "0.6330186", "0.6308607", "0.6252177", "0.62265784", "0.62242293", "0.62235093", "0.619265", "0.619265", "0.61827415", "0.6180693", "0.61696106", "0.61696106", "0.6165113", "0.6165113", "0.6157323", "0.61455667", "0.60965675", "0.6061559", "0.6054501", "0.600202", "0.59747016", "0.5929964", "0.5913897", "0.590047", "0.5897991", "0.5897991", "0.5887224", "0.5864521", "0.5861528", "0.5861528", "0.583343", "0.583343", "0.5813249", "0.57912135", "0.57912135", "0.57669395", "0.576071", "0.576071", "0.57557243", "0.5747388", "0.5747388", "0.5691585", "0.56427956", "0.5613135", "0.5610655", "0.5609311", "0.56090105", "0.55994034", "0.55994034", "0.558444", "0.5573364", "0.5573364", "0.55329484", "0.5522024", "0.55145717", "0.54934907", "0.54910535", "0.5485165", "0.5450349", "0.54150414", "0.54037076", "0.5386456", "0.5384498", "0.5370337", "0.53096336", "0.53061223" ]
0.65897524
18
copy a threedimensional texture subimage
func CopyTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) { C.glowCopyTexSubImage3D(gpCopyTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func CopyTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTextureSubImage3D(gpCopyTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CopyTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTextureSubImage3D(gpCopyTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CopyTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n\tsyscall.Syscall9(gpCopyTextureSubImage3D, 9, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(x), uintptr(y), uintptr(width), uintptr(height))\n}", "func CopyTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTextureSubImage2D(gpCopyTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CopyTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTextureSubImage2D(gpCopyTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CopyTextureSubImage1D(texture uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tC.glowCopyTextureSubImage1D(gpCopyTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func CopyTextureSubImage1D(texture uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tC.glowCopyTextureSubImage1D(gpCopyTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func CopyTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n\tsyscall.Syscall9(gpCopyTextureSubImage2D, 8, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(x), uintptr(y), uintptr(width), uintptr(height), 0)\n}", "func CopyTextureSubImage1D(texture uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tsyscall.Syscall6(gpCopyTextureSubImage1D, 6, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(x), uintptr(y), uintptr(width))\n}", "func CopyImageSubData(srcName uint32, srcTarget uint32, srcLevel int32, srcX int32, srcY int32, srcZ int32, dstName uint32, dstTarget uint32, dstLevel int32, dstX int32, dstY int32, dstZ int32, srcWidth int32, srcHeight int32, srcDepth int32) {\n C.glowCopyImageSubData(gpCopyImageSubData, (C.GLuint)(srcName), (C.GLenum)(srcTarget), (C.GLint)(srcLevel), (C.GLint)(srcX), (C.GLint)(srcY), (C.GLint)(srcZ), (C.GLuint)(dstName), (C.GLenum)(dstTarget), (C.GLint)(dstLevel), (C.GLint)(dstX), (C.GLint)(dstY), (C.GLint)(dstZ), (C.GLsizei)(srcWidth), (C.GLsizei)(srcHeight), (C.GLsizei)(srcDepth))\n}", "func (tex Texture) Sub(ctx gl.Context, lvl int, width int, height int, data []byte) {\n\tctx.TexSubImage2D(gl.TEXTURE_2D, lvl, 0, 0, width, height, gl.RGBA, gl.UNSIGNED_BYTE, data)\n\tif lvl > 0 {\n\t\tctx.GenerateMipmap(gl.TEXTURE_2D)\n\t}\n}", "func CopyImageSubData(srcName uint32, srcTarget uint32, srcLevel int32, srcX int32, srcY int32, srcZ int32, dstName uint32, dstTarget uint32, dstLevel int32, dstX int32, dstY int32, dstZ int32, srcWidth int32, srcHeight int32, srcDepth int32) {\n\tC.glowCopyImageSubData(gpCopyImageSubData, (C.GLuint)(srcName), (C.GLenum)(srcTarget), (C.GLint)(srcLevel), (C.GLint)(srcX), (C.GLint)(srcY), (C.GLint)(srcZ), (C.GLuint)(dstName), (C.GLenum)(dstTarget), (C.GLint)(dstLevel), (C.GLint)(dstX), (C.GLint)(dstY), (C.GLint)(dstZ), (C.GLsizei)(srcWidth), (C.GLsizei)(srcHeight), (C.GLsizei)(srcDepth))\n}", "func CopyImageSubData(srcName uint32, srcTarget uint32, srcLevel int32, srcX int32, srcY int32, srcZ int32, dstName uint32, dstTarget uint32, dstLevel int32, dstX int32, dstY int32, dstZ int32, srcWidth int32, srcHeight int32, srcDepth int32) {\n\tC.glowCopyImageSubData(gpCopyImageSubData, (C.GLuint)(srcName), (C.GLenum)(srcTarget), (C.GLint)(srcLevel), (C.GLint)(srcX), (C.GLint)(srcY), (C.GLint)(srcZ), (C.GLuint)(dstName), (C.GLenum)(dstTarget), (C.GLint)(dstLevel), (C.GLint)(dstX), (C.GLint)(dstY), (C.GLint)(dstZ), (C.GLsizei)(srcWidth), (C.GLsizei)(srcHeight), (C.GLsizei)(srcDepth))\n}", "func CopyTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n C.glowCopyTexSubImage2D(gpCopyTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func TextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTextureSubImage2D, 9, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(width), uintptr(height), uintptr(format), uintptr(xtype), uintptr(pixels))\n}", "func CopyTexImage2D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, height int32, border int32) {\n C.glowCopyTexImage2D(gpCopyTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border))\n}", "func TextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage2D(gpTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage2D(gpTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CopyTexSubImage1D(target uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n C.glowCopyTexSubImage1D(gpCopyTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func TexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexSubImage2D(gpTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage3D(gpTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage3D(gpTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CopyTexImage2D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, height int32, border int32) {\n\tsyscall.Syscall9(gpCopyTexImage2D, 8, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(x), uintptr(y), uintptr(width), uintptr(height), uintptr(border), 0)\n}", "func TextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTextureSubImage1D, 7, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(width), uintptr(format), uintptr(xtype), uintptr(pixels), 0, 0)\n}", "func GetTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetTextureSubImage(gpGetTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), (C.GLsizei)(bufSize), pixels)\n}", "func GetTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetTextureSubImage(gpGetTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), (C.GLsizei)(bufSize), pixels)\n}", "func TextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall12(gpTextureSubImage3D, 11, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(xtype), uintptr(pixels), 0)\n}", "func CopyTexImage2D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, height int32, border int32) {\n\tC.glowCopyTexImage2D(gpCopyTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border))\n}", "func CopyTexImage2D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, height int32, border int32) {\n\tC.glowCopyTexImage2D(gpCopyTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border))\n}", "func CopyTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTexSubImage2D(gpCopyTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CopyTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTexSubImage2D(gpCopyTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func TextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage1D(gpTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage1D(gpTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CopyTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n C.glowCopyTexSubImage3D(gpCopyTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CopyTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n\tsyscall.Syscall9(gpCopyTexSubImage2D, 8, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(x), uintptr(y), uintptr(width), uintptr(height), 0)\n}", "func TexSubImage2D(target Enum, level int, x, y, width, height int, format, ty Enum, data []byte) {\n\tgl.TexSubImage2D(uint32(target), int32(level), int32(x), int32(y), int32(width), int32(height), uint32(format), uint32(ty), gl.Ptr(&data[0]))\n}", "func TexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage2D(gpTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage2D(gpTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CopyImageSubData(srcName uint32, srcTarget uint32, srcLevel int32, srcX int32, srcY int32, srcZ int32, dstName uint32, dstTarget uint32, dstLevel int32, dstX int32, dstY int32, dstZ int32, srcWidth int32, srcHeight int32, srcDepth int32) {\n\tsyscall.Syscall15(gpCopyImageSubData, 15, uintptr(srcName), uintptr(srcTarget), uintptr(srcLevel), uintptr(srcX), uintptr(srcY), uintptr(srcZ), uintptr(dstName), uintptr(dstTarget), uintptr(dstLevel), uintptr(dstX), uintptr(dstY), uintptr(dstZ), uintptr(srcWidth), uintptr(srcHeight), uintptr(srcDepth))\n}", "func GetTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, bufSize int32, pixels unsafe.Pointer) {\n\tsyscall.Syscall12(gpGetTextureSubImage, 12, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(xtype), uintptr(bufSize), uintptr(pixels))\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexSubImage3D(gpTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTexSubImage2D, 9, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(width), uintptr(height), uintptr(format), uintptr(xtype), uintptr(pixels))\n}", "func TexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexSubImage1D(gpTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CopyTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n\tsyscall.Syscall9(gpCopyTexSubImage3D, 9, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(x), uintptr(y), uintptr(width), uintptr(height))\n}", "func CopyTexImage2D(target GLEnum, level int32, internalformat GLEnum, x, y, width, height, border int32) {\n\tgl.CopyTexImage2D(uint32(target), level, uint32(internalformat), x, y, width, height, border)\n}", "func CopyTexSubImage2D(target GLEnum, level, xoffset, yoffset, x, y, width, height int32) {\n\tgl.CopyTexSubImage2D(uint32(target), level, xoffset, yoffset, x, y, width, height)\n}", "func CompressedTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage2D(gpCompressedTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage2D(gpCompressedTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CopyTexSubImage1D(target uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tC.glowCopyTexSubImage1D(gpCopyTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func CopyTexSubImage1D(target uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tC.glowCopyTexSubImage1D(gpCopyTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage3D(gpTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage3D(gpTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CopyBufferSubData(readTarget uint32, writeTarget uint32, readOffset int, writeOffset int, size int) {\n C.glowCopyBufferSubData(gpCopyBufferSubData, (C.GLenum)(readTarget), (C.GLenum)(writeTarget), (C.GLintptr)(readOffset), (C.GLintptr)(writeOffset), (C.GLsizeiptr)(size))\n}", "func CopyColorSubTable(target uint32, start int32, x int32, y int32, width int32) {\n C.glowCopyColorSubTable(gpCopyColorSubTable, (C.GLenum)(target), (C.GLsizei)(start), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall12(gpTexSubImage3D, 11, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(xtype), uintptr(pixels), 0)\n}", "func GetCompressedTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetCompressedTextureSubImage(gpGetCompressedTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLsizei)(bufSize), pixels)\n}", "func GetCompressedTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetCompressedTextureSubImage(gpGetCompressedTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLsizei)(bufSize), pixels)\n}", "func CopyTexSubImage1D(target uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tsyscall.Syscall6(gpCopyTexSubImage1D, 6, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(x), uintptr(y), uintptr(width))\n}", "func CompressedTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTextureSubImage2D, 9, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(width), uintptr(height), uintptr(format), uintptr(imageSize), uintptr(data))\n}", "func CompressedTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage3D(gpCompressedTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage3D(gpCompressedTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CopyTexImage2D(target Enum, level int, internalformat Enum, x, y, width, height, border int) {\n\tgl.CopyTexImage2D(uint32(target), int32(level), uint32(internalformat), int32(x), int32(y), int32(width), int32(height), int32(border))\n}", "func CopyColorSubTable(target uint32, start int32, x int32, y int32, width int32) {\n\tC.glowCopyColorSubTable(gpCopyColorSubTable, (C.GLenum)(target), (C.GLsizei)(start), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func TexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage1D(gpTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage1D(gpTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage2D(target GLEnum, level, xoffset, yoffset, width, height int32, format, xtype GLEnum, pixels []float32) {\n\tgl.TexSubImage2D(uint32(target), level, xoffset, yoffset, width, height, uint32(format), uint32(xtype), unsafe.Pointer(&pixels[0]))\n}", "func CopyTexSubImage2D(target Enum, level, xoffset, yoffset, x, y, width, height int) {\n\tgl.CopyTexSubImage2D(uint32(target), int32(level), int32(xoffset), int32(yoffset), int32(x), int32(y), int32(width), int32(height))\n}", "func CopyTexImage1D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, border int32) {\n C.glowCopyTexImage1D(gpCopyTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLint)(border))\n}", "func TexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTexSubImage1D, 7, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(width), uintptr(format), uintptr(xtype), uintptr(pixels), 0, 0)\n}", "func GetCompressedTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, bufSize int32, pixels unsafe.Pointer) {\n\tsyscall.Syscall12(gpGetCompressedTextureSubImage, 10, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(bufSize), uintptr(pixels), 0, 0)\n}", "func TexSubImage2D(target Enum, level Int, xoffset Int, yoffset Int, width Sizei, height Sizei, format Enum, kind Enum, pixels unsafe.Pointer) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tclevel, _ := (C.GLint)(level), cgoAllocsUnknown\n\tcxoffset, _ := (C.GLint)(xoffset), cgoAllocsUnknown\n\tcyoffset, _ := (C.GLint)(yoffset), cgoAllocsUnknown\n\tcwidth, _ := (C.GLsizei)(width), cgoAllocsUnknown\n\tcheight, _ := (C.GLsizei)(height), cgoAllocsUnknown\n\tcformat, _ := (C.GLenum)(format), cgoAllocsUnknown\n\tckind, _ := (C.GLenum)(kind), cgoAllocsUnknown\n\tcpixels, _ := (unsafe.Pointer)(unsafe.Pointer(pixels)), cgoAllocsUnknown\n\tC.glTexSubImage2D(ctarget, clevel, cxoffset, cyoffset, cwidth, cheight, cformat, ckind, cpixels)\n}", "func CopyTexSubImage2D(target Enum, level Int, xoffset Int, yoffset Int, x Int, y Int, width Sizei, height Sizei) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tclevel, _ := (C.GLint)(level), cgoAllocsUnknown\n\tcxoffset, _ := (C.GLint)(xoffset), cgoAllocsUnknown\n\tcyoffset, _ := (C.GLint)(yoffset), cgoAllocsUnknown\n\tcx, _ := (C.GLint)(x), cgoAllocsUnknown\n\tcy, _ := (C.GLint)(y), cgoAllocsUnknown\n\tcwidth, _ := (C.GLsizei)(width), cgoAllocsUnknown\n\tcheight, _ := (C.GLsizei)(height), cgoAllocsUnknown\n\tC.glCopyTexSubImage2D(ctarget, clevel, cxoffset, cyoffset, cx, cy, cwidth, cheight)\n}", "func CopyTexImage2D(target Enum, level Int, internalformat Enum, x Int, y Int, width Sizei, height Sizei, border Int) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tclevel, _ := (C.GLint)(level), cgoAllocsUnknown\n\tcinternalformat, _ := (C.GLenum)(internalformat), cgoAllocsUnknown\n\tcx, _ := (C.GLint)(x), cgoAllocsUnknown\n\tcy, _ := (C.GLint)(y), cgoAllocsUnknown\n\tcwidth, _ := (C.GLsizei)(width), cgoAllocsUnknown\n\tcheight, _ := (C.GLsizei)(height), cgoAllocsUnknown\n\tcborder, _ := (C.GLint)(border), cgoAllocsUnknown\n\tC.glCopyTexImage2D(ctarget, clevel, cinternalformat, cx, cy, cwidth, cheight, cborder)\n}", "func CopyTexImage1D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, border int32) {\n\tsyscall.Syscall9(gpCopyTexImage1D, 7, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(x), uintptr(y), uintptr(width), uintptr(border), 0, 0)\n}", "func CopyBufferSubData(readTarget uint32, writeTarget uint32, readOffset int, writeOffset int, size int) {\n\tC.glowCopyBufferSubData(gpCopyBufferSubData, (C.GLenum)(readTarget), (C.GLenum)(writeTarget), (C.GLintptr)(readOffset), (C.GLintptr)(writeOffset), (C.GLsizeiptr)(size))\n}", "func CopyBufferSubData(readTarget uint32, writeTarget uint32, readOffset int, writeOffset int, size int) {\n\tC.glowCopyBufferSubData(gpCopyBufferSubData, (C.GLenum)(readTarget), (C.GLenum)(writeTarget), (C.GLintptr)(readOffset), (C.GLintptr)(writeOffset), (C.GLsizeiptr)(size))\n}", "func CompressedTextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage1D(gpCompressedTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage1D(gpCompressedTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall12(gpCompressedTextureSubImage3D, 11, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(imageSize), uintptr(data), 0)\n}", "func (t *Texture) Clone() *Texture {\n\tt.p.Call(\"clone\")\n\treturn t\n}", "func CopyImageSubDataNV(hSrcRC unsafe.Pointer, srcName uint32, srcTarget uint32, srcLevel int32, srcX int32, srcY int32, srcZ int32, hDstRC unsafe.Pointer, dstName uint32, dstTarget uint32, dstLevel int32, dstX int32, dstY int32, dstZ int32, width int32, height int32, depth int32) unsafe.Pointer {\n\tpanic(\"\\\"CopyImageSubDataNV\\\" is not implemented\")\n}", "func (p *Paletted) SubImage(r Rectangle) Image {\n\tr = r.Intersect(p.Rect)\n\t// If r1 and r2 are Rectangles, r1.Intersect(r2) is not guaranteed to be inside\n\t// either r1 or r2 if the intersection is empty. Without explicitly checking for\n\t// this, the Pix[i:] expression below can panic.\n\tif r.Empty() {\n\t\treturn &Paletted{\n\t\t\tPalette: p.Palette,\n\t\t}\n\t}\n\ti := p.PixOffset(r.Min.X, r.Min.Y)\n\treturn &Paletted{\n\t\tPix: p.Pix[i:],\n\t\tStride: p.Stride,\n\t\tRect: p.Rect.Intersect(r),\n\t\tPalette: p.Palette,\n\t}\n}", "func CopyTexImage1D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, border int32) {\n\tC.glowCopyTexImage1D(gpCopyTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLint)(border))\n}", "func CopyTexImage1D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, border int32) {\n\tC.glowCopyTexImage1D(gpCopyTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLint)(border))\n}", "func CompressedTextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTextureSubImage1D, 7, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(width), uintptr(format), uintptr(imageSize), uintptr(data), 0, 0)\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexImage2D(gpTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CompressedTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n C.glowCompressedTexSubImage2D(gpCompressedTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexImage2D(gpTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexImage2D(gpTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func Copy(dst draw.Image, src image.Image) {\n\tbd := src.Bounds().Intersect(dst.Bounds())\n\tat := imageutil.NewAtFunc(src)\n\tset := imageutil.NewSetFunc(dst)\n\timageutil.Parallel1D(bd, func(bd image.Rectangle) {\n\t\tfor y := bd.Min.Y; y < bd.Max.Y; y++ {\n\t\t\tfor x := bd.Min.X; x < bd.Max.X; x++ {\n\t\t\t\tr, g, b, a := at(x, y)\n\t\t\t\tset(x, y, r, g, b, a)\n\t\t\t}\n\t\t}\n\t})\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTexImage2D, 9, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(width), uintptr(height), uintptr(border), uintptr(format), uintptr(xtype), uintptr(pixels))\n}", "func TexImage2D(target Enum, level int, width, height int, format Enum, ty Enum, data []byte) {\n\tp := unsafe.Pointer(nil)\n\tif len(data) > 0 {\n\t\tp = gl.Ptr(&data[0])\n\t}\n\tgl.TexImage2D(uint32(target), int32(level), int32(format), int32(width), int32(height), 0, uint32(format), uint32(ty), p)\n}", "func (self *TileSprite) TintedTexture() *Canvas{\n return &Canvas{self.Object.Get(\"tintedTexture\")}\n}", "func TexImage2D(target GLEnum, level int32, internalformat GLEnum, width, height, border int32, format, xtype GLEnum, pixels []float32) {\n\tgl.TexImage2D(uint32(target), level, int32(internalformat), width, height, border, uint32(format), uint32(xtype), unsafe.Pointer(&pixels[0]))\n}", "func (s *stencilOverdraw) copyImageAspect(ctx context.Context,\n\tcb CommandBuilder,\n\tgs *api.GlobalState,\n\tst *State,\n\ta arena.Arena,\n\tdevice VkDevice,\n\tcmdBuffer VkCommandBuffer,\n\tsrcImgDesc imageDesc,\n\tdstImgDesc imageDesc,\n\textent VkExtent3D,\n\talloc func(v ...interface{}) api.AllocResult,\n\taddCleanup func(func()),\n\tout transform.Writer,\n) {\n\tsrcImg := srcImgDesc.image\n\tdstImg := dstImgDesc.image\n\tcopyBuffer := s.createDepthCopyBuffer(ctx, cb, gs, st, a, device,\n\t\tsrcImg.Info().Fmt(),\n\t\textent.Width(), extent.Height(),\n\t\talloc, addCleanup, out)\n\n\tallCommandsStage := VkPipelineStageFlags(\n\t\tVkPipelineStageFlagBits_VK_PIPELINE_STAGE_ALL_COMMANDS_BIT)\n\tallMemoryAccess := VkAccessFlags(\n\t\tVkAccessFlagBits_VK_ACCESS_MEMORY_WRITE_BIT |\n\t\t\tVkAccessFlagBits_VK_ACCESS_MEMORY_READ_BIT)\n\n\timgBarriers0 := make([]VkImageMemoryBarrier, 2)\n\timgBarriers1 := make([]VkImageMemoryBarrier, 2)\n\t// Transition the src image in and out of the required layouts\n\timgBarriers0[0] = NewVkImageMemoryBarrier(a,\n\t\tVkStructureType_VK_STRUCTURE_TYPE_IMAGE_MEMORY_BARRIER, // sType\n\t\t0, // pNext\n\t\tallMemoryAccess, // srcAccessMask\n\t\tVkAccessFlags(VkAccessFlagBits_VK_ACCESS_TRANSFER_READ_BIT), // dstAccessMask\n\t\tsrcImgDesc.layout, // oldLayout\n\t\tVkImageLayout_VK_IMAGE_LAYOUT_TRANSFER_SRC_OPTIMAL, // newLayout\n\t\t^uint32(0), // srcQueueFamilyIndex: VK_QUEUE_FAMILY_IGNORED\n\t\t^uint32(0), // dstQueueFamilyIndex\n\t\tsrcImg.VulkanHandle(), // image\n\t\tsrcImgDesc.subresource, // subresourceRange\n\t)\n\tsrcFinalLayout := srcImgDesc.layout\n\tif srcFinalLayout == VkImageLayout_VK_IMAGE_LAYOUT_UNDEFINED ||\n\t\tsrcFinalLayout == VkImageLayout_VK_IMAGE_LAYOUT_PREINITIALIZED {\n\t\tsrcFinalLayout = VkImageLayout_VK_IMAGE_LAYOUT_GENERAL\n\t}\n\timgBarriers1[0] = NewVkImageMemoryBarrier(a,\n\t\tVkStructureType_VK_STRUCTURE_TYPE_IMAGE_MEMORY_BARRIER, // sType\n\t\t0, // pNext\n\t\tVkAccessFlags(VkAccessFlagBits_VK_ACCESS_TRANSFER_READ_BIT), // srcAccessMask\n\t\tallMemoryAccess, // dstAccessMask\n\t\tVkImageLayout_VK_IMAGE_LAYOUT_TRANSFER_SRC_OPTIMAL, // oldLayout\n\t\tsrcFinalLayout, // newLayout\n\t\t^uint32(0), // srcQueueFamilyIndex: VK_QUEUE_FAMILY_IGNORED\n\t\t^uint32(0), // dstQueueFamilyIndex\n\t\tsrcImg.VulkanHandle(), // image\n\t\tsrcImgDesc.subresource, // subresourceRange\n\t)\n\n\t// Transition the new image in and out of its required layouts\n\timgBarriers0[1] = NewVkImageMemoryBarrier(a,\n\t\tVkStructureType_VK_STRUCTURE_TYPE_IMAGE_MEMORY_BARRIER, // sType\n\t\t0, // pNext\n\t\tallMemoryAccess, // srcAccessMask\n\t\tVkAccessFlags(VkAccessFlagBits_VK_ACCESS_TRANSFER_WRITE_BIT), // dstAccessMask\n\t\tdstImgDesc.layout, // oldLayout\n\t\tVkImageLayout_VK_IMAGE_LAYOUT_TRANSFER_DST_OPTIMAL, // newLayout\n\t\t^uint32(0), // srcQueueFamilyIndex: VK_QUEUE_FAMILY_IGNORED\n\t\t^uint32(0), // dstQueueFamilyIndex\n\t\tdstImg.VulkanHandle(), // image\n\t\tdstImgDesc.subresource, // subresourceRange\n\t)\n\n\tdstFinalLayout := dstImgDesc.layout\n\tif dstFinalLayout == VkImageLayout_VK_IMAGE_LAYOUT_UNDEFINED ||\n\t\tdstFinalLayout == VkImageLayout_VK_IMAGE_LAYOUT_PREINITIALIZED {\n\t\tdstFinalLayout = VkImageLayout_VK_IMAGE_LAYOUT_GENERAL\n\t}\n\timgBarriers1[1] = NewVkImageMemoryBarrier(a,\n\t\tVkStructureType_VK_STRUCTURE_TYPE_IMAGE_MEMORY_BARRIER, // sType\n\t\t0, // pNext\n\t\tVkAccessFlags(VkAccessFlagBits_VK_ACCESS_TRANSFER_WRITE_BIT), // srcAccessMask\n\t\tallMemoryAccess, // dstAccessMask\n\t\tVkImageLayout_VK_IMAGE_LAYOUT_TRANSFER_DST_OPTIMAL, // oldLayout\n\t\tdstFinalLayout, // newLayout\n\t\t^uint32(0), // srcQueueFamilyIndex: VK_QUEUE_FAMILY_IGNORED\n\t\t^uint32(0), // dstQueueFamilyIndex\n\t\tdstImg.VulkanHandle(), // image\n\t\tdstImgDesc.subresource, // subresourceRange\n\t)\n\n\tbufBarrier := NewVkBufferMemoryBarrier(a,\n\t\tVkStructureType_VK_STRUCTURE_TYPE_BUFFER_MEMORY_BARRIER, // sType\n\t\t0, // pNext\n\t\tVkAccessFlags(VkAccessFlagBits_VK_ACCESS_TRANSFER_WRITE_BIT), // srcAccessMask\n\t\tVkAccessFlags(VkAccessFlagBits_VK_ACCESS_TRANSFER_READ_BIT), // dstAccessMask\n\t\t^uint32(0), // srcQueueFamilyIndex: VK_QUEUE_FAMILY_IGNORED\n\t\t^uint32(0), // dstQueueFamilyIndex\n\t\tcopyBuffer, // buffer\n\t\t0, // offset\n\t\t^VkDeviceSize(0), // size: VK_WHOLE_SIZE\n\t)\n\n\tibCopy := NewVkBufferImageCopy(a,\n\t\t0, // bufferOffset\n\t\t0, // bufferRowLength\n\t\t0, // bufferImageHeight\n\t\tNewVkImageSubresourceLayers(a,\n\t\t\tVkImageAspectFlags(srcImgDesc.aspect), // aspectMask\n\t\t\tsrcImgDesc.subresource.BaseMipLevel(), // mipLevel\n\t\t\tsrcImgDesc.subresource.BaseArrayLayer(), // baseArrayLayer\n\t\t\t1, // layerCount\n\t\t), // srcSubresource\n\t\tNewVkOffset3D(a, 0, 0, 0), // offset\n\t\tNewVkExtent3D(a, extent.Width(), extent.Height(), 1), // extent\n\t)\n\n\tbiCopy := NewVkBufferImageCopy(a,\n\t\t0, // bufferOffset\n\t\t0, // bufferRowLength\n\t\t0, // bufferImageHeight\n\t\tNewVkImageSubresourceLayers(a,\n\t\t\tVkImageAspectFlags(dstImgDesc.aspect), // aspectMask\n\t\t\tdstImgDesc.subresource.BaseMipLevel(), // mipLevel\n\t\t\tdstImgDesc.subresource.BaseArrayLayer(), // baseArrayLayer\n\t\t\t1, // layerCount\n\t\t), // srcSubresource\n\t\tNewVkOffset3D(a, 0, 0, 0), // offset\n\t\tNewVkExtent3D(a, extent.Width(), extent.Height(), 1), // extent\n\t)\n\n\timgBarriers0Data := alloc(imgBarriers0)\n\tibCopyData := alloc(ibCopy)\n\tbufBarrierData := alloc(bufBarrier)\n\tbiCopyData := alloc(biCopy)\n\timgBarriers1Data := alloc(imgBarriers1)\n\n\twriteEach(ctx, out,\n\t\tcb.VkCmdPipelineBarrier(cmdBuffer,\n\t\t\tallCommandsStage, // srcStageMask\n\t\t\tVkPipelineStageFlags(VkPipelineStageFlagBits_VK_PIPELINE_STAGE_TRANSFER_BIT), // dstStageMask\n\t\t\t0, // dependencyFlags\n\t\t\t0, // memoryBarrierCount\n\t\t\tmemory.Nullptr, // pMemoryBarriers\n\t\t\t0, // bufferMemoryBarrierCount\n\t\t\tmemory.Nullptr, // pBufferMemoryBarriers\n\t\t\t2, // imageMemoryBarrierCount\n\t\t\timgBarriers0Data.Ptr(), // pImageMemoryBarriers\n\t\t).AddRead(imgBarriers0Data.Data()),\n\t\tcb.VkCmdCopyImageToBuffer(cmdBuffer,\n\t\t\tsrcImg.VulkanHandle(), // srcImage\n\t\t\tVkImageLayout_VK_IMAGE_LAYOUT_TRANSFER_SRC_OPTIMAL, // srcImageLayout\n\t\t\tcopyBuffer, // dstBuffer\n\t\t\t1, // regionCount\n\t\t\tibCopyData.Ptr(), // pRegions\n\t\t).AddRead(ibCopyData.Data()),\n\t\tcb.VkCmdPipelineBarrier(cmdBuffer,\n\t\t\tVkPipelineStageFlags(VkPipelineStageFlagBits_VK_PIPELINE_STAGE_TRANSFER_BIT), // srcStageMask\n\t\t\tVkPipelineStageFlags(VkPipelineStageFlagBits_VK_PIPELINE_STAGE_TRANSFER_BIT), // dstStageMask\n\t\t\t0, // dependencyFlags\n\t\t\t0, // memoryBarrierCount\n\t\t\tmemory.Nullptr, // pMemoryBarriers\n\t\t\t1, // bufferMemoryBarrierCount\n\t\t\tbufBarrierData.Ptr(), // pBufferMemoryBarriers\n\t\t\t0, // imageMemoryBarrierCount\n\t\t\tmemory.Nullptr, // pImageMemoryBarriers\n\t\t).AddRead(bufBarrierData.Data()),\n\t\tcb.VkCmdCopyBufferToImage(cmdBuffer,\n\t\t\tcopyBuffer, // srcBuffer\n\t\t\tdstImg.VulkanHandle(), // dstImage\n\t\t\tVkImageLayout_VK_IMAGE_LAYOUT_TRANSFER_DST_OPTIMAL, // dstImageLayout\n\t\t\t1, // regionCount\n\t\t\tbiCopyData.Ptr(), // pRegions\n\t\t).AddRead(biCopyData.Data()),\n\t\tcb.VkCmdPipelineBarrier(cmdBuffer,\n\t\t\tVkPipelineStageFlags(VkPipelineStageFlagBits_VK_PIPELINE_STAGE_TRANSFER_BIT), // srcStageMask\n\t\t\tallCommandsStage, // dstStageMask\n\t\t\t0, // dependencyFlags\n\t\t\t0, // memoryBarrierCount\n\t\t\tmemory.Nullptr, // pMemoryBarriers\n\t\t\t0, // bufferMemoryBarrierCount\n\t\t\tmemory.Nullptr, // pBufferMemoryBarriers\n\t\t\t2, // imageMemoryBarrierCount\n\t\t\timgBarriers1Data.Ptr(), // pImageMemoryBarriers\n\t\t).AddRead(imgBarriers1Data.Data()),\n\t)\n}", "func (w *WebGLRenderTarget) Copy(source *WebGLRenderTarget) *WebGLRenderTarget {\n\tw.p.Call(\"copy\", source.p)\n\treturn w\n}", "func (debugging *debuggingOpenGL) TexImage2D(target uint32, level int32, internalFormat uint32, width int32, height int32,\n\tborder int32, format uint32, xtype uint32, pixels interface{}) {\n\tdebugging.recordEntry(\"TexImage2D\", target, level, internalFormat, width, height, border, format, xtype, pixels)\n\tdebugging.gl.TexImage2D(target, level, internalFormat, width, height, border, format, xtype, pixels)\n\tdebugging.recordExit(\"TexImage2D\")\n}", "func Copy(i ImageIr) ImageIr {\n\tc := make([][][]uint32, len(i.pixels))\n\tcopy(c, i.pixels)\n\treturn ImageIr{i.width, i.height, c}\n}", "func ClearTexSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, data unsafe.Pointer) {\n C.glowClearTexSubImage(gpClearTexSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), data)\n}" ]
[ "0.7215594", "0.7215594", "0.71876454", "0.70950466", "0.70950466", "0.70811504", "0.70811504", "0.7059603", "0.7054656", "0.6721647", "0.65954375", "0.65091", "0.65091", "0.64512765", "0.6377637", "0.6370287", "0.63596547", "0.63596547", "0.6333909", "0.6325963", "0.63115376", "0.63115376", "0.63018143", "0.627918", "0.6274888", "0.6274888", "0.6261104", "0.6256194", "0.6256194", "0.6235751", "0.6235751", "0.62317055", "0.62317055", "0.6224778", "0.61799693", "0.6171815", "0.61671144", "0.61671144", "0.6162187", "0.61466044", "0.61391276", "0.61223495", "0.6109416", "0.6092193", "0.6088593", "0.60810584", "0.60737354", "0.60737354", "0.6062833", "0.6062833", "0.6060912", "0.6060912", "0.6048682", "0.6024398", "0.6011111", "0.5984603", "0.5984603", "0.59649926", "0.59483814", "0.5931356", "0.5931356", "0.592031", "0.59107167", "0.5893602", "0.5893602", "0.5888698", "0.5841979", "0.5808763", "0.57881254", "0.5769691", "0.57668567", "0.57619274", "0.57517564", "0.5738546", "0.57229894", "0.57229894", "0.5693027", "0.5693027", "0.5691274", "0.5658196", "0.56261283", "0.5601511", "0.5571418", "0.5571418", "0.55619943", "0.5430095", "0.54258096", "0.54172117", "0.54172117", "0.54021055", "0.5402015", "0.5392931", "0.53806645", "0.5336048", "0.5335738", "0.5281995", "0.52772295", "0.5275963", "0.51662207" ]
0.6116538
43
copy a onedimensional texture subimage
func CopyTextureSubImage1D(texture uint32, level int32, xoffset int32, x int32, y int32, width int32) { C.glowCopyTextureSubImage1D(gpCopyTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func CopyTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n\tsyscall.Syscall9(gpCopyTextureSubImage2D, 8, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(x), uintptr(y), uintptr(width), uintptr(height), 0)\n}", "func CopyTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTextureSubImage2D(gpCopyTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CopyTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTextureSubImage2D(gpCopyTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CopyTextureSubImage1D(texture uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tsyscall.Syscall6(gpCopyTextureSubImage1D, 6, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(x), uintptr(y), uintptr(width))\n}", "func CopyTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n\tsyscall.Syscall9(gpCopyTextureSubImage3D, 9, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(x), uintptr(y), uintptr(width), uintptr(height))\n}", "func CopyTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTextureSubImage3D(gpCopyTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CopyTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTextureSubImage3D(gpCopyTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func (tex Texture) Sub(ctx gl.Context, lvl int, width int, height int, data []byte) {\n\tctx.TexSubImage2D(gl.TEXTURE_2D, lvl, 0, 0, width, height, gl.RGBA, gl.UNSIGNED_BYTE, data)\n\tif lvl > 0 {\n\t\tctx.GenerateMipmap(gl.TEXTURE_2D)\n\t}\n}", "func CopyImageSubData(srcName uint32, srcTarget uint32, srcLevel int32, srcX int32, srcY int32, srcZ int32, dstName uint32, dstTarget uint32, dstLevel int32, dstX int32, dstY int32, dstZ int32, srcWidth int32, srcHeight int32, srcDepth int32) {\n C.glowCopyImageSubData(gpCopyImageSubData, (C.GLuint)(srcName), (C.GLenum)(srcTarget), (C.GLint)(srcLevel), (C.GLint)(srcX), (C.GLint)(srcY), (C.GLint)(srcZ), (C.GLuint)(dstName), (C.GLenum)(dstTarget), (C.GLint)(dstLevel), (C.GLint)(dstX), (C.GLint)(dstY), (C.GLint)(dstZ), (C.GLsizei)(srcWidth), (C.GLsizei)(srcHeight), (C.GLsizei)(srcDepth))\n}", "func CopyImageSubData(srcName uint32, srcTarget uint32, srcLevel int32, srcX int32, srcY int32, srcZ int32, dstName uint32, dstTarget uint32, dstLevel int32, dstX int32, dstY int32, dstZ int32, srcWidth int32, srcHeight int32, srcDepth int32) {\n\tC.glowCopyImageSubData(gpCopyImageSubData, (C.GLuint)(srcName), (C.GLenum)(srcTarget), (C.GLint)(srcLevel), (C.GLint)(srcX), (C.GLint)(srcY), (C.GLint)(srcZ), (C.GLuint)(dstName), (C.GLenum)(dstTarget), (C.GLint)(dstLevel), (C.GLint)(dstX), (C.GLint)(dstY), (C.GLint)(dstZ), (C.GLsizei)(srcWidth), (C.GLsizei)(srcHeight), (C.GLsizei)(srcDepth))\n}", "func CopyImageSubData(srcName uint32, srcTarget uint32, srcLevel int32, srcX int32, srcY int32, srcZ int32, dstName uint32, dstTarget uint32, dstLevel int32, dstX int32, dstY int32, dstZ int32, srcWidth int32, srcHeight int32, srcDepth int32) {\n\tC.glowCopyImageSubData(gpCopyImageSubData, (C.GLuint)(srcName), (C.GLenum)(srcTarget), (C.GLint)(srcLevel), (C.GLint)(srcX), (C.GLint)(srcY), (C.GLint)(srcZ), (C.GLuint)(dstName), (C.GLenum)(dstTarget), (C.GLint)(dstLevel), (C.GLint)(dstX), (C.GLint)(dstY), (C.GLint)(dstZ), (C.GLsizei)(srcWidth), (C.GLsizei)(srcHeight), (C.GLsizei)(srcDepth))\n}", "func CopyTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n C.glowCopyTexSubImage2D(gpCopyTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func TextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTextureSubImage2D, 9, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(width), uintptr(height), uintptr(format), uintptr(xtype), uintptr(pixels))\n}", "func TexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexSubImage2D(gpTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage2D(gpTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage2D(gpTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTextureSubImage1D, 7, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(width), uintptr(format), uintptr(xtype), uintptr(pixels), 0, 0)\n}", "func CopyTexSubImage1D(target uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n C.glowCopyTexSubImage1D(gpCopyTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func GetTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetTextureSubImage(gpGetTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), (C.GLsizei)(bufSize), pixels)\n}", "func GetTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetTextureSubImage(gpGetTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), (C.GLsizei)(bufSize), pixels)\n}", "func CopyImageSubData(srcName uint32, srcTarget uint32, srcLevel int32, srcX int32, srcY int32, srcZ int32, dstName uint32, dstTarget uint32, dstLevel int32, dstX int32, dstY int32, dstZ int32, srcWidth int32, srcHeight int32, srcDepth int32) {\n\tsyscall.Syscall15(gpCopyImageSubData, 15, uintptr(srcName), uintptr(srcTarget), uintptr(srcLevel), uintptr(srcX), uintptr(srcY), uintptr(srcZ), uintptr(dstName), uintptr(dstTarget), uintptr(dstLevel), uintptr(dstX), uintptr(dstY), uintptr(dstZ), uintptr(srcWidth), uintptr(srcHeight), uintptr(srcDepth))\n}", "func CopyTexImage2D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, height int32, border int32) {\n C.glowCopyTexImage2D(gpCopyTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border))\n}", "func CopyTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n\tsyscall.Syscall9(gpCopyTexSubImage2D, 8, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(x), uintptr(y), uintptr(width), uintptr(height), 0)\n}", "func CopyTexImage2D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, height int32, border int32) {\n\tsyscall.Syscall9(gpCopyTexImage2D, 8, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(x), uintptr(y), uintptr(width), uintptr(height), uintptr(border), 0)\n}", "func TexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTexSubImage2D, 9, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(width), uintptr(height), uintptr(format), uintptr(xtype), uintptr(pixels))\n}", "func TextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage1D(gpTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage1D(gpTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func GetTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, bufSize int32, pixels unsafe.Pointer) {\n\tsyscall.Syscall12(gpGetTextureSubImage, 12, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(xtype), uintptr(bufSize), uintptr(pixels))\n}", "func CopyTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTexSubImage2D(gpCopyTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CopyTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTexSubImage2D(gpCopyTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func TexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage2D(gpTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage2D(gpTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage2D(target Enum, level int, x, y, width, height int, format, ty Enum, data []byte) {\n\tgl.TexSubImage2D(uint32(target), int32(level), int32(x), int32(y), int32(width), int32(height), uint32(format), uint32(ty), gl.Ptr(&data[0]))\n}", "func CopyBufferSubData(readTarget uint32, writeTarget uint32, readOffset int, writeOffset int, size int) {\n C.glowCopyBufferSubData(gpCopyBufferSubData, (C.GLenum)(readTarget), (C.GLenum)(writeTarget), (C.GLintptr)(readOffset), (C.GLintptr)(writeOffset), (C.GLsizeiptr)(size))\n}", "func CopyTexImage2D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, height int32, border int32) {\n\tC.glowCopyTexImage2D(gpCopyTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border))\n}", "func CopyTexImage2D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, height int32, border int32) {\n\tC.glowCopyTexImage2D(gpCopyTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border))\n}", "func TexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexSubImage1D(gpTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CopyTexSubImage2D(target GLEnum, level, xoffset, yoffset, x, y, width, height int32) {\n\tgl.CopyTexSubImage2D(uint32(target), level, xoffset, yoffset, x, y, width, height)\n}", "func TextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall12(gpTextureSubImage3D, 11, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(xtype), uintptr(pixels), 0)\n}", "func TextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage3D(gpTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage3D(gpTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CompressedTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage2D(gpCompressedTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage2D(gpCompressedTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CopyTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n C.glowCopyTexSubImage3D(gpCopyTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func (p *Paletted) SubImage(r Rectangle) Image {\n\tr = r.Intersect(p.Rect)\n\t// If r1 and r2 are Rectangles, r1.Intersect(r2) is not guaranteed to be inside\n\t// either r1 or r2 if the intersection is empty. Without explicitly checking for\n\t// this, the Pix[i:] expression below can panic.\n\tif r.Empty() {\n\t\treturn &Paletted{\n\t\t\tPalette: p.Palette,\n\t\t}\n\t}\n\ti := p.PixOffset(r.Min.X, r.Min.Y)\n\treturn &Paletted{\n\t\tPix: p.Pix[i:],\n\t\tStride: p.Stride,\n\t\tRect: p.Rect.Intersect(r),\n\t\tPalette: p.Palette,\n\t}\n}", "func CopyTexSubImage1D(target uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tsyscall.Syscall6(gpCopyTexSubImage1D, 6, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(x), uintptr(y), uintptr(width))\n}", "func CopyTexImage2D(target GLEnum, level int32, internalformat GLEnum, x, y, width, height, border int32) {\n\tgl.CopyTexImage2D(uint32(target), level, uint32(internalformat), x, y, width, height, border)\n}", "func GetCompressedTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetCompressedTextureSubImage(gpGetCompressedTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLsizei)(bufSize), pixels)\n}", "func GetCompressedTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetCompressedTextureSubImage(gpGetCompressedTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLsizei)(bufSize), pixels)\n}", "func CopyTexSubImage1D(target uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tC.glowCopyTexSubImage1D(gpCopyTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func CopyTexSubImage1D(target uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tC.glowCopyTexSubImage1D(gpCopyTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func CompressedTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTextureSubImage2D, 9, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(width), uintptr(height), uintptr(format), uintptr(imageSize), uintptr(data))\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexSubImage3D(gpTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CopyTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n\tsyscall.Syscall9(gpCopyTexSubImage3D, 9, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(x), uintptr(y), uintptr(width), uintptr(height))\n}", "func CopyImageSubDataNV(hSrcRC unsafe.Pointer, srcName uint32, srcTarget uint32, srcLevel int32, srcX int32, srcY int32, srcZ int32, hDstRC unsafe.Pointer, dstName uint32, dstTarget uint32, dstLevel int32, dstX int32, dstY int32, dstZ int32, width int32, height int32, depth int32) unsafe.Pointer {\n\tpanic(\"\\\"CopyImageSubDataNV\\\" is not implemented\")\n}", "func TexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTexSubImage1D, 7, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(width), uintptr(format), uintptr(xtype), uintptr(pixels), 0, 0)\n}", "func TexSubImage2D(target GLEnum, level, xoffset, yoffset, width, height int32, format, xtype GLEnum, pixels []float32) {\n\tgl.TexSubImage2D(uint32(target), level, xoffset, yoffset, width, height, uint32(format), uint32(xtype), unsafe.Pointer(&pixels[0]))\n}", "func TexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage1D(gpTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage1D(gpTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall12(gpTexSubImage3D, 11, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(xtype), uintptr(pixels), 0)\n}", "func CopyTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTexSubImage3D(gpCopyTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CopyTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTexSubImage3D(gpCopyTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CopyTexSubImage2D(target Enum, level, xoffset, yoffset, x, y, width, height int) {\n\tgl.CopyTexSubImage2D(uint32(target), int32(level), int32(xoffset), int32(yoffset), int32(x), int32(y), int32(width), int32(height))\n}", "func CopyTexImage2D(target Enum, level int, internalformat Enum, x, y, width, height, border int) {\n\tgl.CopyTexImage2D(uint32(target), int32(level), uint32(internalformat), int32(x), int32(y), int32(width), int32(height), int32(border))\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage3D(gpTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage3D(gpTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func (p *Alpha16) SubImage(r Rectangle) Image {\n\tr = r.Intersect(p.Rect)\n\t// If r1 and r2 are Rectangles, r1.Intersect(r2) is not guaranteed to be inside\n\t// either r1 or r2 if the intersection is empty. Without explicitly checking for\n\t// this, the Pix[i:] expression below can panic.\n\tif r.Empty() {\n\t\treturn &Alpha16{}\n\t}\n\ti := p.PixOffset(r.Min.X, r.Min.Y)\n\treturn &Alpha16{\n\t\tPix: p.Pix[i:],\n\t\tStride: p.Stride,\n\t\tRect: r,\n\t}\n}", "func GetCompressedTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, bufSize int32, pixels unsafe.Pointer) {\n\tsyscall.Syscall12(gpGetCompressedTextureSubImage, 10, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(bufSize), uintptr(pixels), 0, 0)\n}", "func TexSubImage2D(target Enum, level Int, xoffset Int, yoffset Int, width Sizei, height Sizei, format Enum, kind Enum, pixels unsafe.Pointer) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tclevel, _ := (C.GLint)(level), cgoAllocsUnknown\n\tcxoffset, _ := (C.GLint)(xoffset), cgoAllocsUnknown\n\tcyoffset, _ := (C.GLint)(yoffset), cgoAllocsUnknown\n\tcwidth, _ := (C.GLsizei)(width), cgoAllocsUnknown\n\tcheight, _ := (C.GLsizei)(height), cgoAllocsUnknown\n\tcformat, _ := (C.GLenum)(format), cgoAllocsUnknown\n\tckind, _ := (C.GLenum)(kind), cgoAllocsUnknown\n\tcpixels, _ := (unsafe.Pointer)(unsafe.Pointer(pixels)), cgoAllocsUnknown\n\tC.glTexSubImage2D(ctarget, clevel, cxoffset, cyoffset, cwidth, cheight, cformat, ckind, cpixels)\n}", "func CopyBufferSubData(readTarget uint32, writeTarget uint32, readOffset int, writeOffset int, size int) {\n\tC.glowCopyBufferSubData(gpCopyBufferSubData, (C.GLenum)(readTarget), (C.GLenum)(writeTarget), (C.GLintptr)(readOffset), (C.GLintptr)(writeOffset), (C.GLsizeiptr)(size))\n}", "func CopyBufferSubData(readTarget uint32, writeTarget uint32, readOffset int, writeOffset int, size int) {\n\tC.glowCopyBufferSubData(gpCopyBufferSubData, (C.GLenum)(readTarget), (C.GLenum)(writeTarget), (C.GLintptr)(readOffset), (C.GLintptr)(writeOffset), (C.GLsizeiptr)(size))\n}", "func CompressedTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage3D(gpCompressedTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage3D(gpCompressedTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CopyTexSubImage2D(target Enum, level Int, xoffset Int, yoffset Int, x Int, y Int, width Sizei, height Sizei) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tclevel, _ := (C.GLint)(level), cgoAllocsUnknown\n\tcxoffset, _ := (C.GLint)(xoffset), cgoAllocsUnknown\n\tcyoffset, _ := (C.GLint)(yoffset), cgoAllocsUnknown\n\tcx, _ := (C.GLint)(x), cgoAllocsUnknown\n\tcy, _ := (C.GLint)(y), cgoAllocsUnknown\n\tcwidth, _ := (C.GLsizei)(width), cgoAllocsUnknown\n\tcheight, _ := (C.GLsizei)(height), cgoAllocsUnknown\n\tC.glCopyTexSubImage2D(ctarget, clevel, cxoffset, cyoffset, cx, cy, cwidth, cheight)\n}", "func CopyColorSubTable(target uint32, start int32, x int32, y int32, width int32) {\n C.glowCopyColorSubTable(gpCopyColorSubTable, (C.GLenum)(target), (C.GLsizei)(start), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func Copy(dst draw.Image, src image.Image) {\n\tbd := src.Bounds().Intersect(dst.Bounds())\n\tat := imageutil.NewAtFunc(src)\n\tset := imageutil.NewSetFunc(dst)\n\timageutil.Parallel1D(bd, func(bd image.Rectangle) {\n\t\tfor y := bd.Min.Y; y < bd.Max.Y; y++ {\n\t\t\tfor x := bd.Min.X; x < bd.Max.X; x++ {\n\t\t\t\tr, g, b, a := at(x, y)\n\t\t\t\tset(x, y, r, g, b, a)\n\t\t\t}\n\t\t}\n\t})\n}", "func CopyTexImage1D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, border int32) {\n C.glowCopyTexImage1D(gpCopyTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLint)(border))\n}", "func CompressedTextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage1D(gpCompressedTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage1D(gpCompressedTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func (s *stencilOverdraw) copyImageAspect(ctx context.Context,\n\tcb CommandBuilder,\n\tgs *api.GlobalState,\n\tst *State,\n\ta arena.Arena,\n\tdevice VkDevice,\n\tcmdBuffer VkCommandBuffer,\n\tsrcImgDesc imageDesc,\n\tdstImgDesc imageDesc,\n\textent VkExtent3D,\n\talloc func(v ...interface{}) api.AllocResult,\n\taddCleanup func(func()),\n\tout transform.Writer,\n) {\n\tsrcImg := srcImgDesc.image\n\tdstImg := dstImgDesc.image\n\tcopyBuffer := s.createDepthCopyBuffer(ctx, cb, gs, st, a, device,\n\t\tsrcImg.Info().Fmt(),\n\t\textent.Width(), extent.Height(),\n\t\talloc, addCleanup, out)\n\n\tallCommandsStage := VkPipelineStageFlags(\n\t\tVkPipelineStageFlagBits_VK_PIPELINE_STAGE_ALL_COMMANDS_BIT)\n\tallMemoryAccess := VkAccessFlags(\n\t\tVkAccessFlagBits_VK_ACCESS_MEMORY_WRITE_BIT |\n\t\t\tVkAccessFlagBits_VK_ACCESS_MEMORY_READ_BIT)\n\n\timgBarriers0 := make([]VkImageMemoryBarrier, 2)\n\timgBarriers1 := make([]VkImageMemoryBarrier, 2)\n\t// Transition the src image in and out of the required layouts\n\timgBarriers0[0] = NewVkImageMemoryBarrier(a,\n\t\tVkStructureType_VK_STRUCTURE_TYPE_IMAGE_MEMORY_BARRIER, // sType\n\t\t0, // pNext\n\t\tallMemoryAccess, // srcAccessMask\n\t\tVkAccessFlags(VkAccessFlagBits_VK_ACCESS_TRANSFER_READ_BIT), // dstAccessMask\n\t\tsrcImgDesc.layout, // oldLayout\n\t\tVkImageLayout_VK_IMAGE_LAYOUT_TRANSFER_SRC_OPTIMAL, // newLayout\n\t\t^uint32(0), // srcQueueFamilyIndex: VK_QUEUE_FAMILY_IGNORED\n\t\t^uint32(0), // dstQueueFamilyIndex\n\t\tsrcImg.VulkanHandle(), // image\n\t\tsrcImgDesc.subresource, // subresourceRange\n\t)\n\tsrcFinalLayout := srcImgDesc.layout\n\tif srcFinalLayout == VkImageLayout_VK_IMAGE_LAYOUT_UNDEFINED ||\n\t\tsrcFinalLayout == VkImageLayout_VK_IMAGE_LAYOUT_PREINITIALIZED {\n\t\tsrcFinalLayout = VkImageLayout_VK_IMAGE_LAYOUT_GENERAL\n\t}\n\timgBarriers1[0] = NewVkImageMemoryBarrier(a,\n\t\tVkStructureType_VK_STRUCTURE_TYPE_IMAGE_MEMORY_BARRIER, // sType\n\t\t0, // pNext\n\t\tVkAccessFlags(VkAccessFlagBits_VK_ACCESS_TRANSFER_READ_BIT), // srcAccessMask\n\t\tallMemoryAccess, // dstAccessMask\n\t\tVkImageLayout_VK_IMAGE_LAYOUT_TRANSFER_SRC_OPTIMAL, // oldLayout\n\t\tsrcFinalLayout, // newLayout\n\t\t^uint32(0), // srcQueueFamilyIndex: VK_QUEUE_FAMILY_IGNORED\n\t\t^uint32(0), // dstQueueFamilyIndex\n\t\tsrcImg.VulkanHandle(), // image\n\t\tsrcImgDesc.subresource, // subresourceRange\n\t)\n\n\t// Transition the new image in and out of its required layouts\n\timgBarriers0[1] = NewVkImageMemoryBarrier(a,\n\t\tVkStructureType_VK_STRUCTURE_TYPE_IMAGE_MEMORY_BARRIER, // sType\n\t\t0, // pNext\n\t\tallMemoryAccess, // srcAccessMask\n\t\tVkAccessFlags(VkAccessFlagBits_VK_ACCESS_TRANSFER_WRITE_BIT), // dstAccessMask\n\t\tdstImgDesc.layout, // oldLayout\n\t\tVkImageLayout_VK_IMAGE_LAYOUT_TRANSFER_DST_OPTIMAL, // newLayout\n\t\t^uint32(0), // srcQueueFamilyIndex: VK_QUEUE_FAMILY_IGNORED\n\t\t^uint32(0), // dstQueueFamilyIndex\n\t\tdstImg.VulkanHandle(), // image\n\t\tdstImgDesc.subresource, // subresourceRange\n\t)\n\n\tdstFinalLayout := dstImgDesc.layout\n\tif dstFinalLayout == VkImageLayout_VK_IMAGE_LAYOUT_UNDEFINED ||\n\t\tdstFinalLayout == VkImageLayout_VK_IMAGE_LAYOUT_PREINITIALIZED {\n\t\tdstFinalLayout = VkImageLayout_VK_IMAGE_LAYOUT_GENERAL\n\t}\n\timgBarriers1[1] = NewVkImageMemoryBarrier(a,\n\t\tVkStructureType_VK_STRUCTURE_TYPE_IMAGE_MEMORY_BARRIER, // sType\n\t\t0, // pNext\n\t\tVkAccessFlags(VkAccessFlagBits_VK_ACCESS_TRANSFER_WRITE_BIT), // srcAccessMask\n\t\tallMemoryAccess, // dstAccessMask\n\t\tVkImageLayout_VK_IMAGE_LAYOUT_TRANSFER_DST_OPTIMAL, // oldLayout\n\t\tdstFinalLayout, // newLayout\n\t\t^uint32(0), // srcQueueFamilyIndex: VK_QUEUE_FAMILY_IGNORED\n\t\t^uint32(0), // dstQueueFamilyIndex\n\t\tdstImg.VulkanHandle(), // image\n\t\tdstImgDesc.subresource, // subresourceRange\n\t)\n\n\tbufBarrier := NewVkBufferMemoryBarrier(a,\n\t\tVkStructureType_VK_STRUCTURE_TYPE_BUFFER_MEMORY_BARRIER, // sType\n\t\t0, // pNext\n\t\tVkAccessFlags(VkAccessFlagBits_VK_ACCESS_TRANSFER_WRITE_BIT), // srcAccessMask\n\t\tVkAccessFlags(VkAccessFlagBits_VK_ACCESS_TRANSFER_READ_BIT), // dstAccessMask\n\t\t^uint32(0), // srcQueueFamilyIndex: VK_QUEUE_FAMILY_IGNORED\n\t\t^uint32(0), // dstQueueFamilyIndex\n\t\tcopyBuffer, // buffer\n\t\t0, // offset\n\t\t^VkDeviceSize(0), // size: VK_WHOLE_SIZE\n\t)\n\n\tibCopy := NewVkBufferImageCopy(a,\n\t\t0, // bufferOffset\n\t\t0, // bufferRowLength\n\t\t0, // bufferImageHeight\n\t\tNewVkImageSubresourceLayers(a,\n\t\t\tVkImageAspectFlags(srcImgDesc.aspect), // aspectMask\n\t\t\tsrcImgDesc.subresource.BaseMipLevel(), // mipLevel\n\t\t\tsrcImgDesc.subresource.BaseArrayLayer(), // baseArrayLayer\n\t\t\t1, // layerCount\n\t\t), // srcSubresource\n\t\tNewVkOffset3D(a, 0, 0, 0), // offset\n\t\tNewVkExtent3D(a, extent.Width(), extent.Height(), 1), // extent\n\t)\n\n\tbiCopy := NewVkBufferImageCopy(a,\n\t\t0, // bufferOffset\n\t\t0, // bufferRowLength\n\t\t0, // bufferImageHeight\n\t\tNewVkImageSubresourceLayers(a,\n\t\t\tVkImageAspectFlags(dstImgDesc.aspect), // aspectMask\n\t\t\tdstImgDesc.subresource.BaseMipLevel(), // mipLevel\n\t\t\tdstImgDesc.subresource.BaseArrayLayer(), // baseArrayLayer\n\t\t\t1, // layerCount\n\t\t), // srcSubresource\n\t\tNewVkOffset3D(a, 0, 0, 0), // offset\n\t\tNewVkExtent3D(a, extent.Width(), extent.Height(), 1), // extent\n\t)\n\n\timgBarriers0Data := alloc(imgBarriers0)\n\tibCopyData := alloc(ibCopy)\n\tbufBarrierData := alloc(bufBarrier)\n\tbiCopyData := alloc(biCopy)\n\timgBarriers1Data := alloc(imgBarriers1)\n\n\twriteEach(ctx, out,\n\t\tcb.VkCmdPipelineBarrier(cmdBuffer,\n\t\t\tallCommandsStage, // srcStageMask\n\t\t\tVkPipelineStageFlags(VkPipelineStageFlagBits_VK_PIPELINE_STAGE_TRANSFER_BIT), // dstStageMask\n\t\t\t0, // dependencyFlags\n\t\t\t0, // memoryBarrierCount\n\t\t\tmemory.Nullptr, // pMemoryBarriers\n\t\t\t0, // bufferMemoryBarrierCount\n\t\t\tmemory.Nullptr, // pBufferMemoryBarriers\n\t\t\t2, // imageMemoryBarrierCount\n\t\t\timgBarriers0Data.Ptr(), // pImageMemoryBarriers\n\t\t).AddRead(imgBarriers0Data.Data()),\n\t\tcb.VkCmdCopyImageToBuffer(cmdBuffer,\n\t\t\tsrcImg.VulkanHandle(), // srcImage\n\t\t\tVkImageLayout_VK_IMAGE_LAYOUT_TRANSFER_SRC_OPTIMAL, // srcImageLayout\n\t\t\tcopyBuffer, // dstBuffer\n\t\t\t1, // regionCount\n\t\t\tibCopyData.Ptr(), // pRegions\n\t\t).AddRead(ibCopyData.Data()),\n\t\tcb.VkCmdPipelineBarrier(cmdBuffer,\n\t\t\tVkPipelineStageFlags(VkPipelineStageFlagBits_VK_PIPELINE_STAGE_TRANSFER_BIT), // srcStageMask\n\t\t\tVkPipelineStageFlags(VkPipelineStageFlagBits_VK_PIPELINE_STAGE_TRANSFER_BIT), // dstStageMask\n\t\t\t0, // dependencyFlags\n\t\t\t0, // memoryBarrierCount\n\t\t\tmemory.Nullptr, // pMemoryBarriers\n\t\t\t1, // bufferMemoryBarrierCount\n\t\t\tbufBarrierData.Ptr(), // pBufferMemoryBarriers\n\t\t\t0, // imageMemoryBarrierCount\n\t\t\tmemory.Nullptr, // pImageMemoryBarriers\n\t\t).AddRead(bufBarrierData.Data()),\n\t\tcb.VkCmdCopyBufferToImage(cmdBuffer,\n\t\t\tcopyBuffer, // srcBuffer\n\t\t\tdstImg.VulkanHandle(), // dstImage\n\t\t\tVkImageLayout_VK_IMAGE_LAYOUT_TRANSFER_DST_OPTIMAL, // dstImageLayout\n\t\t\t1, // regionCount\n\t\t\tbiCopyData.Ptr(), // pRegions\n\t\t).AddRead(biCopyData.Data()),\n\t\tcb.VkCmdPipelineBarrier(cmdBuffer,\n\t\t\tVkPipelineStageFlags(VkPipelineStageFlagBits_VK_PIPELINE_STAGE_TRANSFER_BIT), // srcStageMask\n\t\t\tallCommandsStage, // dstStageMask\n\t\t\t0, // dependencyFlags\n\t\t\t0, // memoryBarrierCount\n\t\t\tmemory.Nullptr, // pMemoryBarriers\n\t\t\t0, // bufferMemoryBarrierCount\n\t\t\tmemory.Nullptr, // pBufferMemoryBarriers\n\t\t\t2, // imageMemoryBarrierCount\n\t\t\timgBarriers1Data.Ptr(), // pImageMemoryBarriers\n\t\t).AddRead(imgBarriers1Data.Data()),\n\t)\n}", "func CopyTexImage1D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, border int32) {\n\tsyscall.Syscall9(gpCopyTexImage1D, 7, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(x), uintptr(y), uintptr(width), uintptr(border), 0, 0)\n}", "func CopyTexImage2D(target Enum, level Int, internalformat Enum, x Int, y Int, width Sizei, height Sizei, border Int) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tclevel, _ := (C.GLint)(level), cgoAllocsUnknown\n\tcinternalformat, _ := (C.GLenum)(internalformat), cgoAllocsUnknown\n\tcx, _ := (C.GLint)(x), cgoAllocsUnknown\n\tcy, _ := (C.GLint)(y), cgoAllocsUnknown\n\tcwidth, _ := (C.GLsizei)(width), cgoAllocsUnknown\n\tcheight, _ := (C.GLsizei)(height), cgoAllocsUnknown\n\tcborder, _ := (C.GLint)(border), cgoAllocsUnknown\n\tC.glCopyTexImage2D(ctarget, clevel, cinternalformat, cx, cy, cwidth, cheight, cborder)\n}", "func CopyColorSubTable(target uint32, start int32, x int32, y int32, width int32) {\n\tC.glowCopyColorSubTable(gpCopyColorSubTable, (C.GLenum)(target), (C.GLsizei)(start), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func CompressedTextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTextureSubImage1D, 7, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(width), uintptr(format), uintptr(imageSize), uintptr(data), 0, 0)\n}", "func CompressedTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall12(gpCompressedTextureSubImage3D, 11, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(imageSize), uintptr(data), 0)\n}", "func (p *NRGBA) SubImage(r Rectangle) Image {\n\tr = r.Intersect(p.Rect)\n\t// If r1 and r2 are Rectangles, r1.Intersect(r2) is not guaranteed to be inside\n\t// either r1 or r2 if the intersection is empty. Without explicitly checking for\n\t// this, the Pix[i:] expression below can panic.\n\tif r.Empty() {\n\t\treturn &NRGBA{}\n\t}\n\ti := p.PixOffset(r.Min.X, r.Min.Y)\n\treturn &NRGBA{\n\t\tPix: p.Pix[i:],\n\t\tStride: p.Stride,\n\t\tRect: r,\n\t}\n}", "func (p *Image64) SubImage(r image.Rectangle) image.Image {\n\tr = r.Intersect(p.Rect)\n\tif r.Empty() {\n\t\treturn &Image64{}\n\t}\n\ti := (r.Min.Y-p.Rect.Min.Y)*p.Stride + (r.Min.X - p.Rect.Min.X)\n\treturn &Image64{\n\t\tPix: p.Pix[i:],\n\t\tStride: p.Stride,\n\t\tRect: r,\n\t}\n}", "func (p *Alpha) SubImage(r Rectangle) Image {\n\tr = r.Intersect(p.Rect)\n\t// If r1 and r2 are Rectangles, r1.Intersect(r2) is not guaranteed to be inside\n\t// either r1 or r2 if the intersection is empty. Without explicitly checking for\n\t// this, the Pix[i:] expression below can panic.\n\tif r.Empty() {\n\t\treturn &Alpha{}\n\t}\n\ti := p.PixOffset(r.Min.X, r.Min.Y)\n\treturn &Alpha{\n\t\tPix: p.Pix[i:],\n\t\tStride: p.Stride,\n\t\tRect: r,\n\t}\n}", "func (t *Texture) Clone() *Texture {\n\tt.p.Call(\"clone\")\n\treturn t\n}", "func (p *NRGBA64) SubImage(r Rectangle) Image {\n\tr = r.Intersect(p.Rect)\n\t// If r1 and r2 are Rectangles, r1.Intersect(r2) is not guaranteed to be inside\n\t// either r1 or r2 if the intersection is empty. Without explicitly checking for\n\t// this, the Pix[i:] expression below can panic.\n\tif r.Empty() {\n\t\treturn &NRGBA64{}\n\t}\n\ti := p.PixOffset(r.Min.X, r.Min.Y)\n\treturn &NRGBA64{\n\t\tPix: p.Pix[i:],\n\t\tStride: p.Stride,\n\t\tRect: r,\n\t}\n}", "func (p *RGBA64) SubImage(r Rectangle) Image {\n\tr = r.Intersect(p.Rect)\n\t// If r1 and r2 are Rectangles, r1.Intersect(r2) is not guaranteed to be inside\n\t// either r1 or r2 if the intersection is empty. Without explicitly checking for\n\t// this, the Pix[i:] expression below can panic.\n\tif r.Empty() {\n\t\treturn &RGBA64{}\n\t}\n\ti := p.PixOffset(r.Min.X, r.Min.Y)\n\treturn &RGBA64{\n\t\tPix: p.Pix[i:],\n\t\tStride: p.Stride,\n\t\tRect: r,\n\t}\n}", "func (p *RGBA) SubImage(r Rectangle) Image {\n\tr = r.Intersect(p.Rect)\n\t// If r1 and r2 are Rectangles, r1.Intersect(r2) is not guaranteed to be inside\n\t// either r1 or r2 if the intersection is empty. Without explicitly checking for\n\t// this, the Pix[i:] expression below can panic.\n\tif r.Empty() {\n\t\treturn &RGBA{}\n\t}\n\ti := p.PixOffset(r.Min.X, r.Min.Y)\n\treturn &RGBA{\n\t\tPix: p.Pix[i:],\n\t\tStride: p.Stride,\n\t\tRect: r,\n\t}\n}", "func (p *CMYK) SubImage(r Rectangle) Image {\n\tr = r.Intersect(p.Rect)\n\t// If r1 and r2 are Rectangles, r1.Intersect(r2) is not guaranteed to be inside\n\t// either r1 or r2 if the intersection is empty. Without explicitly checking for\n\t// this, the Pix[i:] expression below can panic.\n\tif r.Empty() {\n\t\treturn &CMYK{}\n\t}\n\ti := p.PixOffset(r.Min.X, r.Min.Y)\n\treturn &CMYK{\n\t\tPix: p.Pix[i:],\n\t\tStride: p.Stride,\n\t\tRect: r,\n\t}\n}", "func CompressedTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n C.glowCompressedTexSubImage2D(gpCompressedTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func Copy(i ImageIr) ImageIr {\n\tc := make([][][]uint32, len(i.pixels))\n\tcopy(c, i.pixels)\n\treturn ImageIr{i.width, i.height, c}\n}", "func CopyTexImage1D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, border int32) {\n\tC.glowCopyTexImage1D(gpCopyTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLint)(border))\n}", "func CopyTexImage1D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, border int32) {\n\tC.glowCopyTexImage1D(gpCopyTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLint)(border))\n}", "func (p *Gray16) SubImage(r Rectangle) Image {\n\tr = r.Intersect(p.Rect)\n\t// If r1 and r2 are Rectangles, r1.Intersect(r2) is not guaranteed to be inside\n\t// either r1 or r2 if the intersection is empty. Without explicitly checking for\n\t// this, the Pix[i:] expression below can panic.\n\tif r.Empty() {\n\t\treturn &Gray16{}\n\t}\n\ti := p.PixOffset(r.Min.X, r.Min.Y)\n\treturn &Gray16{\n\t\tPix: p.Pix[i:],\n\t\tStride: p.Stride,\n\t\tRect: r,\n\t}\n}", "func (debugging *debuggingOpenGL) TexImage2D(target uint32, level int32, internalFormat uint32, width int32, height int32,\n\tborder int32, format uint32, xtype uint32, pixels interface{}) {\n\tdebugging.recordEntry(\"TexImage2D\", target, level, internalFormat, width, height, border, format, xtype, pixels)\n\tdebugging.gl.TexImage2D(target, level, internalFormat, width, height, border, format, xtype, pixels)\n\tdebugging.recordExit(\"TexImage2D\")\n}" ]
[ "0.7117874", "0.70963943", "0.70963943", "0.70903414", "0.70718455", "0.7052369", "0.7052369", "0.6940072", "0.69269633", "0.67217225", "0.67217225", "0.65369076", "0.6529039", "0.6454725", "0.64417475", "0.64417475", "0.6408693", "0.6400633", "0.63795626", "0.63795626", "0.6379457", "0.6364727", "0.632762", "0.6326077", "0.6301789", "0.6292279", "0.6292279", "0.6287277", "0.6266248", "0.6266248", "0.6240501", "0.6240501", "0.62262154", "0.62129086", "0.6209742", "0.6209742", "0.6209355", "0.61751854", "0.617211", "0.61627436", "0.61627436", "0.61595976", "0.61595976", "0.61123353", "0.6098123", "0.60957557", "0.6086926", "0.60831356", "0.60831356", "0.60804605", "0.60804605", "0.6067833", "0.603852", "0.6004752", "0.5981513", "0.5960467", "0.5954748", "0.5944562", "0.5944562", "0.5942289", "0.5936097", "0.5936097", "0.5926178", "0.5924572", "0.5913153", "0.5913153", "0.5887247", "0.5884108", "0.58702284", "0.5862861", "0.5862861", "0.5854172", "0.5854172", "0.58370775", "0.5826931", "0.5814022", "0.57800496", "0.5773107", "0.5773107", "0.5747387", "0.5727199", "0.5716792", "0.571413", "0.5668436", "0.564562", "0.5644912", "0.5643192", "0.56345206", "0.5595414", "0.559491", "0.55916876", "0.5574803", "0.5573312", "0.5553006", "0.55227524", "0.55146194", "0.55146194", "0.547328", "0.5427419" ]
0.7063463
6
copy a twodimensional texture subimage
func CopyTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) { C.glowCopyTextureSubImage2D(gpCopyTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func CopyTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n\tsyscall.Syscall9(gpCopyTextureSubImage2D, 8, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(x), uintptr(y), uintptr(width), uintptr(height), 0)\n}", "func CopyTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTextureSubImage3D(gpCopyTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CopyTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTextureSubImage3D(gpCopyTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CopyTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n\tsyscall.Syscall9(gpCopyTextureSubImage3D, 9, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(x), uintptr(y), uintptr(width), uintptr(height))\n}", "func CopyTextureSubImage1D(texture uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tC.glowCopyTextureSubImage1D(gpCopyTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func CopyTextureSubImage1D(texture uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tC.glowCopyTextureSubImage1D(gpCopyTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func CopyTextureSubImage1D(texture uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tsyscall.Syscall6(gpCopyTextureSubImage1D, 6, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(x), uintptr(y), uintptr(width))\n}", "func (tex Texture) Sub(ctx gl.Context, lvl int, width int, height int, data []byte) {\n\tctx.TexSubImage2D(gl.TEXTURE_2D, lvl, 0, 0, width, height, gl.RGBA, gl.UNSIGNED_BYTE, data)\n\tif lvl > 0 {\n\t\tctx.GenerateMipmap(gl.TEXTURE_2D)\n\t}\n}", "func TextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTextureSubImage2D, 9, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(width), uintptr(height), uintptr(format), uintptr(xtype), uintptr(pixels))\n}", "func CopyTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n C.glowCopyTexSubImage2D(gpCopyTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func TextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage2D(gpTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage2D(gpTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexSubImage2D(gpTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CopyImageSubData(srcName uint32, srcTarget uint32, srcLevel int32, srcX int32, srcY int32, srcZ int32, dstName uint32, dstTarget uint32, dstLevel int32, dstX int32, dstY int32, dstZ int32, srcWidth int32, srcHeight int32, srcDepth int32) {\n C.glowCopyImageSubData(gpCopyImageSubData, (C.GLuint)(srcName), (C.GLenum)(srcTarget), (C.GLint)(srcLevel), (C.GLint)(srcX), (C.GLint)(srcY), (C.GLint)(srcZ), (C.GLuint)(dstName), (C.GLenum)(dstTarget), (C.GLint)(dstLevel), (C.GLint)(dstX), (C.GLint)(dstY), (C.GLint)(dstZ), (C.GLsizei)(srcWidth), (C.GLsizei)(srcHeight), (C.GLsizei)(srcDepth))\n}", "func CopyTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n\tsyscall.Syscall9(gpCopyTexSubImage2D, 8, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(x), uintptr(y), uintptr(width), uintptr(height), 0)\n}", "func CopyTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTexSubImage2D(gpCopyTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CopyTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTexSubImage2D(gpCopyTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func TexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTexSubImage2D, 9, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(width), uintptr(height), uintptr(format), uintptr(xtype), uintptr(pixels))\n}", "func GetTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetTextureSubImage(gpGetTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), (C.GLsizei)(bufSize), pixels)\n}", "func GetTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetTextureSubImage(gpGetTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), (C.GLsizei)(bufSize), pixels)\n}", "func TexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage2D(gpTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage2D(gpTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CopyTexImage2D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, height int32, border int32) {\n C.glowCopyTexImage2D(gpCopyTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border))\n}", "func GetTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, bufSize int32, pixels unsafe.Pointer) {\n\tsyscall.Syscall12(gpGetTextureSubImage, 12, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(xtype), uintptr(bufSize), uintptr(pixels))\n}", "func CopyTexImage2D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, height int32, border int32) {\n\tsyscall.Syscall9(gpCopyTexImage2D, 8, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(x), uintptr(y), uintptr(width), uintptr(height), uintptr(border), 0)\n}", "func TexSubImage2D(target Enum, level int, x, y, width, height int, format, ty Enum, data []byte) {\n\tgl.TexSubImage2D(uint32(target), int32(level), int32(x), int32(y), int32(width), int32(height), uint32(format), uint32(ty), gl.Ptr(&data[0]))\n}", "func CopyTexSubImage2D(target GLEnum, level, xoffset, yoffset, x, y, width, height int32) {\n\tgl.CopyTexSubImage2D(uint32(target), level, xoffset, yoffset, x, y, width, height)\n}", "func CopyImageSubData(srcName uint32, srcTarget uint32, srcLevel int32, srcX int32, srcY int32, srcZ int32, dstName uint32, dstTarget uint32, dstLevel int32, dstX int32, dstY int32, dstZ int32, srcWidth int32, srcHeight int32, srcDepth int32) {\n\tC.glowCopyImageSubData(gpCopyImageSubData, (C.GLuint)(srcName), (C.GLenum)(srcTarget), (C.GLint)(srcLevel), (C.GLint)(srcX), (C.GLint)(srcY), (C.GLint)(srcZ), (C.GLuint)(dstName), (C.GLenum)(dstTarget), (C.GLint)(dstLevel), (C.GLint)(dstX), (C.GLint)(dstY), (C.GLint)(dstZ), (C.GLsizei)(srcWidth), (C.GLsizei)(srcHeight), (C.GLsizei)(srcDepth))\n}", "func CopyImageSubData(srcName uint32, srcTarget uint32, srcLevel int32, srcX int32, srcY int32, srcZ int32, dstName uint32, dstTarget uint32, dstLevel int32, dstX int32, dstY int32, dstZ int32, srcWidth int32, srcHeight int32, srcDepth int32) {\n\tC.glowCopyImageSubData(gpCopyImageSubData, (C.GLuint)(srcName), (C.GLenum)(srcTarget), (C.GLint)(srcLevel), (C.GLint)(srcX), (C.GLint)(srcY), (C.GLint)(srcZ), (C.GLuint)(dstName), (C.GLenum)(dstTarget), (C.GLint)(dstLevel), (C.GLint)(dstX), (C.GLint)(dstY), (C.GLint)(dstZ), (C.GLsizei)(srcWidth), (C.GLsizei)(srcHeight), (C.GLsizei)(srcDepth))\n}", "func CompressedTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage2D(gpCompressedTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage2D(gpCompressedTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CopyTexImage2D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, height int32, border int32) {\n\tC.glowCopyTexImage2D(gpCopyTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border))\n}", "func CopyTexImage2D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, height int32, border int32) {\n\tC.glowCopyTexImage2D(gpCopyTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border))\n}", "func CompressedTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTextureSubImage2D, 9, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(width), uintptr(height), uintptr(format), uintptr(imageSize), uintptr(data))\n}", "func TextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTextureSubImage1D, 7, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(width), uintptr(format), uintptr(xtype), uintptr(pixels), 0, 0)\n}", "func CopyTexSubImage1D(target uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n C.glowCopyTexSubImage1D(gpCopyTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func CopyTexImage2D(target GLEnum, level int32, internalformat GLEnum, x, y, width, height, border int32) {\n\tgl.CopyTexImage2D(uint32(target), level, uint32(internalformat), x, y, width, height, border)\n}", "func TexSubImage2D(target GLEnum, level, xoffset, yoffset, width, height int32, format, xtype GLEnum, pixels []float32) {\n\tgl.TexSubImage2D(uint32(target), level, xoffset, yoffset, width, height, uint32(format), uint32(xtype), unsafe.Pointer(&pixels[0]))\n}", "func CopyTexSubImage2D(target Enum, level, xoffset, yoffset, x, y, width, height int) {\n\tgl.CopyTexSubImage2D(uint32(target), int32(level), int32(xoffset), int32(yoffset), int32(x), int32(y), int32(width), int32(height))\n}", "func TextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage1D(gpTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage1D(gpTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage2D(target Enum, level Int, xoffset Int, yoffset Int, width Sizei, height Sizei, format Enum, kind Enum, pixels unsafe.Pointer) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tclevel, _ := (C.GLint)(level), cgoAllocsUnknown\n\tcxoffset, _ := (C.GLint)(xoffset), cgoAllocsUnknown\n\tcyoffset, _ := (C.GLint)(yoffset), cgoAllocsUnknown\n\tcwidth, _ := (C.GLsizei)(width), cgoAllocsUnknown\n\tcheight, _ := (C.GLsizei)(height), cgoAllocsUnknown\n\tcformat, _ := (C.GLenum)(format), cgoAllocsUnknown\n\tckind, _ := (C.GLenum)(kind), cgoAllocsUnknown\n\tcpixels, _ := (unsafe.Pointer)(unsafe.Pointer(pixels)), cgoAllocsUnknown\n\tC.glTexSubImage2D(ctarget, clevel, cxoffset, cyoffset, cwidth, cheight, cformat, ckind, cpixels)\n}", "func CopyTexSubImage2D(target Enum, level Int, xoffset Int, yoffset Int, x Int, y Int, width Sizei, height Sizei) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tclevel, _ := (C.GLint)(level), cgoAllocsUnknown\n\tcxoffset, _ := (C.GLint)(xoffset), cgoAllocsUnknown\n\tcyoffset, _ := (C.GLint)(yoffset), cgoAllocsUnknown\n\tcx, _ := (C.GLint)(x), cgoAllocsUnknown\n\tcy, _ := (C.GLint)(y), cgoAllocsUnknown\n\tcwidth, _ := (C.GLsizei)(width), cgoAllocsUnknown\n\tcheight, _ := (C.GLsizei)(height), cgoAllocsUnknown\n\tC.glCopyTexSubImage2D(ctarget, clevel, cxoffset, cyoffset, cx, cy, cwidth, cheight)\n}", "func GetCompressedTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetCompressedTextureSubImage(gpGetCompressedTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLsizei)(bufSize), pixels)\n}", "func GetCompressedTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetCompressedTextureSubImage(gpGetCompressedTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLsizei)(bufSize), pixels)\n}", "func TextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage3D(gpTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage3D(gpTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall12(gpTextureSubImage3D, 11, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(xtype), uintptr(pixels), 0)\n}", "func CopyBufferSubData(readTarget uint32, writeTarget uint32, readOffset int, writeOffset int, size int) {\n C.glowCopyBufferSubData(gpCopyBufferSubData, (C.GLenum)(readTarget), (C.GLenum)(writeTarget), (C.GLintptr)(readOffset), (C.GLintptr)(writeOffset), (C.GLsizeiptr)(size))\n}", "func CopyImageSubData(srcName uint32, srcTarget uint32, srcLevel int32, srcX int32, srcY int32, srcZ int32, dstName uint32, dstTarget uint32, dstLevel int32, dstX int32, dstY int32, dstZ int32, srcWidth int32, srcHeight int32, srcDepth int32) {\n\tsyscall.Syscall15(gpCopyImageSubData, 15, uintptr(srcName), uintptr(srcTarget), uintptr(srcLevel), uintptr(srcX), uintptr(srcY), uintptr(srcZ), uintptr(dstName), uintptr(dstTarget), uintptr(dstLevel), uintptr(dstX), uintptr(dstY), uintptr(dstZ), uintptr(srcWidth), uintptr(srcHeight), uintptr(srcDepth))\n}", "func CopyTexImage2D(target Enum, level int, internalformat Enum, x, y, width, height, border int) {\n\tgl.CopyTexImage2D(uint32(target), int32(level), uint32(internalformat), int32(x), int32(y), int32(width), int32(height), int32(border))\n}", "func TexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexSubImage1D(gpTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CopyTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n C.glowCopyTexSubImage3D(gpCopyTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func GetCompressedTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, bufSize int32, pixels unsafe.Pointer) {\n\tsyscall.Syscall12(gpGetCompressedTextureSubImage, 10, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(bufSize), uintptr(pixels), 0, 0)\n}", "func CopyTexImage2D(target Enum, level Int, internalformat Enum, x Int, y Int, width Sizei, height Sizei, border Int) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tclevel, _ := (C.GLint)(level), cgoAllocsUnknown\n\tcinternalformat, _ := (C.GLenum)(internalformat), cgoAllocsUnknown\n\tcx, _ := (C.GLint)(x), cgoAllocsUnknown\n\tcy, _ := (C.GLint)(y), cgoAllocsUnknown\n\tcwidth, _ := (C.GLsizei)(width), cgoAllocsUnknown\n\tcheight, _ := (C.GLsizei)(height), cgoAllocsUnknown\n\tcborder, _ := (C.GLint)(border), cgoAllocsUnknown\n\tC.glCopyTexImage2D(ctarget, clevel, cinternalformat, cx, cy, cwidth, cheight, cborder)\n}", "func CopyColorSubTable(target uint32, start int32, x int32, y int32, width int32) {\n C.glowCopyColorSubTable(gpCopyColorSubTable, (C.GLenum)(target), (C.GLsizei)(start), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func CopyTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n\tsyscall.Syscall9(gpCopyTexSubImage3D, 9, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(x), uintptr(y), uintptr(width), uintptr(height))\n}", "func CopyTexSubImage1D(target uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tC.glowCopyTexSubImage1D(gpCopyTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func CopyTexSubImage1D(target uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tC.glowCopyTexSubImage1D(gpCopyTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexSubImage3D(gpTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CopyTexSubImage1D(target uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tsyscall.Syscall6(gpCopyTexSubImage1D, 6, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(x), uintptr(y), uintptr(width))\n}", "func CopyTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTexSubImage3D(gpCopyTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CopyTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTexSubImage3D(gpCopyTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CopyBufferSubData(readTarget uint32, writeTarget uint32, readOffset int, writeOffset int, size int) {\n\tC.glowCopyBufferSubData(gpCopyBufferSubData, (C.GLenum)(readTarget), (C.GLenum)(writeTarget), (C.GLintptr)(readOffset), (C.GLintptr)(writeOffset), (C.GLsizeiptr)(size))\n}", "func CopyBufferSubData(readTarget uint32, writeTarget uint32, readOffset int, writeOffset int, size int) {\n\tC.glowCopyBufferSubData(gpCopyBufferSubData, (C.GLenum)(readTarget), (C.GLenum)(writeTarget), (C.GLintptr)(readOffset), (C.GLintptr)(writeOffset), (C.GLsizeiptr)(size))\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall12(gpTexSubImage3D, 11, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(xtype), uintptr(pixels), 0)\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage3D(gpTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage3D(gpTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CopyColorSubTable(target uint32, start int32, x int32, y int32, width int32) {\n\tC.glowCopyColorSubTable(gpCopyColorSubTable, (C.GLenum)(target), (C.GLsizei)(start), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func TexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage1D(gpTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage1D(gpTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTexSubImage1D, 7, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(width), uintptr(format), uintptr(xtype), uintptr(pixels), 0, 0)\n}", "func CompressedTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage3D(gpCompressedTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage3D(gpCompressedTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n C.glowCompressedTexSubImage2D(gpCompressedTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTexImage2D, 9, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(width), uintptr(height), uintptr(border), uintptr(format), uintptr(xtype), uintptr(pixels))\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexImage2D(gpTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CopyImageSubDataNV(hSrcRC unsafe.Pointer, srcName uint32, srcTarget uint32, srcLevel int32, srcX int32, srcY int32, srcZ int32, hDstRC unsafe.Pointer, dstName uint32, dstTarget uint32, dstLevel int32, dstX int32, dstY int32, dstZ int32, width int32, height int32, depth int32) unsafe.Pointer {\n\tpanic(\"\\\"CopyImageSubDataNV\\\" is not implemented\")\n}", "func (t *Texture) Clone() *Texture {\n\tt.p.Call(\"clone\")\n\treturn t\n}", "func Copy(dst draw.Image, src image.Image) {\n\tbd := src.Bounds().Intersect(dst.Bounds())\n\tat := imageutil.NewAtFunc(src)\n\tset := imageutil.NewSetFunc(dst)\n\timageutil.Parallel1D(bd, func(bd image.Rectangle) {\n\t\tfor y := bd.Min.Y; y < bd.Max.Y; y++ {\n\t\t\tfor x := bd.Min.X; x < bd.Max.X; x++ {\n\t\t\t\tr, g, b, a := at(x, y)\n\t\t\t\tset(x, y, r, g, b, a)\n\t\t\t}\n\t\t}\n\t})\n}", "func CompressedTextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage1D(gpCompressedTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage1D(gpCompressedTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func (p *Paletted) SubImage(r Rectangle) Image {\n\tr = r.Intersect(p.Rect)\n\t// If r1 and r2 are Rectangles, r1.Intersect(r2) is not guaranteed to be inside\n\t// either r1 or r2 if the intersection is empty. Without explicitly checking for\n\t// this, the Pix[i:] expression below can panic.\n\tif r.Empty() {\n\t\treturn &Paletted{\n\t\t\tPalette: p.Palette,\n\t\t}\n\t}\n\ti := p.PixOffset(r.Min.X, r.Min.Y)\n\treturn &Paletted{\n\t\tPix: p.Pix[i:],\n\t\tStride: p.Stride,\n\t\tRect: p.Rect.Intersect(r),\n\t\tPalette: p.Palette,\n\t}\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexImage2D(gpTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexImage2D(gpTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CompressedTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall12(gpCompressedTextureSubImage3D, 11, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(imageSize), uintptr(data), 0)\n}", "func (debugging *debuggingOpenGL) TexImage2D(target uint32, level int32, internalFormat uint32, width int32, height int32,\n\tborder int32, format uint32, xtype uint32, pixels interface{}) {\n\tdebugging.recordEntry(\"TexImage2D\", target, level, internalFormat, width, height, border, format, xtype, pixels)\n\tdebugging.gl.TexImage2D(target, level, internalFormat, width, height, border, format, xtype, pixels)\n\tdebugging.recordExit(\"TexImage2D\")\n}", "func TexImage2D(target Enum, level int, width, height int, format Enum, ty Enum, data []byte) {\n\tp := unsafe.Pointer(nil)\n\tif len(data) > 0 {\n\t\tp = gl.Ptr(&data[0])\n\t}\n\tgl.TexImage2D(uint32(target), int32(level), int32(format), int32(width), int32(height), 0, uint32(format), uint32(ty), p)\n}", "func CompressedTextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTextureSubImage1D, 7, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(width), uintptr(format), uintptr(imageSize), uintptr(data), 0, 0)\n}", "func TexImage2D(target GLEnum, level int32, internalformat GLEnum, width, height, border int32, format, xtype GLEnum, pixels []float32) {\n\tgl.TexImage2D(uint32(target), level, int32(internalformat), width, height, border, uint32(format), uint32(xtype), unsafe.Pointer(&pixels[0]))\n}", "func CopyTexImage1D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, border int32) {\n C.glowCopyTexImage1D(gpCopyTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLint)(border))\n}", "func (s *stencilOverdraw) copyImageAspect(ctx context.Context,\n\tcb CommandBuilder,\n\tgs *api.GlobalState,\n\tst *State,\n\ta arena.Arena,\n\tdevice VkDevice,\n\tcmdBuffer VkCommandBuffer,\n\tsrcImgDesc imageDesc,\n\tdstImgDesc imageDesc,\n\textent VkExtent3D,\n\talloc func(v ...interface{}) api.AllocResult,\n\taddCleanup func(func()),\n\tout transform.Writer,\n) {\n\tsrcImg := srcImgDesc.image\n\tdstImg := dstImgDesc.image\n\tcopyBuffer := s.createDepthCopyBuffer(ctx, cb, gs, st, a, device,\n\t\tsrcImg.Info().Fmt(),\n\t\textent.Width(), extent.Height(),\n\t\talloc, addCleanup, out)\n\n\tallCommandsStage := VkPipelineStageFlags(\n\t\tVkPipelineStageFlagBits_VK_PIPELINE_STAGE_ALL_COMMANDS_BIT)\n\tallMemoryAccess := VkAccessFlags(\n\t\tVkAccessFlagBits_VK_ACCESS_MEMORY_WRITE_BIT |\n\t\t\tVkAccessFlagBits_VK_ACCESS_MEMORY_READ_BIT)\n\n\timgBarriers0 := make([]VkImageMemoryBarrier, 2)\n\timgBarriers1 := make([]VkImageMemoryBarrier, 2)\n\t// Transition the src image in and out of the required layouts\n\timgBarriers0[0] = NewVkImageMemoryBarrier(a,\n\t\tVkStructureType_VK_STRUCTURE_TYPE_IMAGE_MEMORY_BARRIER, // sType\n\t\t0, // pNext\n\t\tallMemoryAccess, // srcAccessMask\n\t\tVkAccessFlags(VkAccessFlagBits_VK_ACCESS_TRANSFER_READ_BIT), // dstAccessMask\n\t\tsrcImgDesc.layout, // oldLayout\n\t\tVkImageLayout_VK_IMAGE_LAYOUT_TRANSFER_SRC_OPTIMAL, // newLayout\n\t\t^uint32(0), // srcQueueFamilyIndex: VK_QUEUE_FAMILY_IGNORED\n\t\t^uint32(0), // dstQueueFamilyIndex\n\t\tsrcImg.VulkanHandle(), // image\n\t\tsrcImgDesc.subresource, // subresourceRange\n\t)\n\tsrcFinalLayout := srcImgDesc.layout\n\tif srcFinalLayout == VkImageLayout_VK_IMAGE_LAYOUT_UNDEFINED ||\n\t\tsrcFinalLayout == VkImageLayout_VK_IMAGE_LAYOUT_PREINITIALIZED {\n\t\tsrcFinalLayout = VkImageLayout_VK_IMAGE_LAYOUT_GENERAL\n\t}\n\timgBarriers1[0] = NewVkImageMemoryBarrier(a,\n\t\tVkStructureType_VK_STRUCTURE_TYPE_IMAGE_MEMORY_BARRIER, // sType\n\t\t0, // pNext\n\t\tVkAccessFlags(VkAccessFlagBits_VK_ACCESS_TRANSFER_READ_BIT), // srcAccessMask\n\t\tallMemoryAccess, // dstAccessMask\n\t\tVkImageLayout_VK_IMAGE_LAYOUT_TRANSFER_SRC_OPTIMAL, // oldLayout\n\t\tsrcFinalLayout, // newLayout\n\t\t^uint32(0), // srcQueueFamilyIndex: VK_QUEUE_FAMILY_IGNORED\n\t\t^uint32(0), // dstQueueFamilyIndex\n\t\tsrcImg.VulkanHandle(), // image\n\t\tsrcImgDesc.subresource, // subresourceRange\n\t)\n\n\t// Transition the new image in and out of its required layouts\n\timgBarriers0[1] = NewVkImageMemoryBarrier(a,\n\t\tVkStructureType_VK_STRUCTURE_TYPE_IMAGE_MEMORY_BARRIER, // sType\n\t\t0, // pNext\n\t\tallMemoryAccess, // srcAccessMask\n\t\tVkAccessFlags(VkAccessFlagBits_VK_ACCESS_TRANSFER_WRITE_BIT), // dstAccessMask\n\t\tdstImgDesc.layout, // oldLayout\n\t\tVkImageLayout_VK_IMAGE_LAYOUT_TRANSFER_DST_OPTIMAL, // newLayout\n\t\t^uint32(0), // srcQueueFamilyIndex: VK_QUEUE_FAMILY_IGNORED\n\t\t^uint32(0), // dstQueueFamilyIndex\n\t\tdstImg.VulkanHandle(), // image\n\t\tdstImgDesc.subresource, // subresourceRange\n\t)\n\n\tdstFinalLayout := dstImgDesc.layout\n\tif dstFinalLayout == VkImageLayout_VK_IMAGE_LAYOUT_UNDEFINED ||\n\t\tdstFinalLayout == VkImageLayout_VK_IMAGE_LAYOUT_PREINITIALIZED {\n\t\tdstFinalLayout = VkImageLayout_VK_IMAGE_LAYOUT_GENERAL\n\t}\n\timgBarriers1[1] = NewVkImageMemoryBarrier(a,\n\t\tVkStructureType_VK_STRUCTURE_TYPE_IMAGE_MEMORY_BARRIER, // sType\n\t\t0, // pNext\n\t\tVkAccessFlags(VkAccessFlagBits_VK_ACCESS_TRANSFER_WRITE_BIT), // srcAccessMask\n\t\tallMemoryAccess, // dstAccessMask\n\t\tVkImageLayout_VK_IMAGE_LAYOUT_TRANSFER_DST_OPTIMAL, // oldLayout\n\t\tdstFinalLayout, // newLayout\n\t\t^uint32(0), // srcQueueFamilyIndex: VK_QUEUE_FAMILY_IGNORED\n\t\t^uint32(0), // dstQueueFamilyIndex\n\t\tdstImg.VulkanHandle(), // image\n\t\tdstImgDesc.subresource, // subresourceRange\n\t)\n\n\tbufBarrier := NewVkBufferMemoryBarrier(a,\n\t\tVkStructureType_VK_STRUCTURE_TYPE_BUFFER_MEMORY_BARRIER, // sType\n\t\t0, // pNext\n\t\tVkAccessFlags(VkAccessFlagBits_VK_ACCESS_TRANSFER_WRITE_BIT), // srcAccessMask\n\t\tVkAccessFlags(VkAccessFlagBits_VK_ACCESS_TRANSFER_READ_BIT), // dstAccessMask\n\t\t^uint32(0), // srcQueueFamilyIndex: VK_QUEUE_FAMILY_IGNORED\n\t\t^uint32(0), // dstQueueFamilyIndex\n\t\tcopyBuffer, // buffer\n\t\t0, // offset\n\t\t^VkDeviceSize(0), // size: VK_WHOLE_SIZE\n\t)\n\n\tibCopy := NewVkBufferImageCopy(a,\n\t\t0, // bufferOffset\n\t\t0, // bufferRowLength\n\t\t0, // bufferImageHeight\n\t\tNewVkImageSubresourceLayers(a,\n\t\t\tVkImageAspectFlags(srcImgDesc.aspect), // aspectMask\n\t\t\tsrcImgDesc.subresource.BaseMipLevel(), // mipLevel\n\t\t\tsrcImgDesc.subresource.BaseArrayLayer(), // baseArrayLayer\n\t\t\t1, // layerCount\n\t\t), // srcSubresource\n\t\tNewVkOffset3D(a, 0, 0, 0), // offset\n\t\tNewVkExtent3D(a, extent.Width(), extent.Height(), 1), // extent\n\t)\n\n\tbiCopy := NewVkBufferImageCopy(a,\n\t\t0, // bufferOffset\n\t\t0, // bufferRowLength\n\t\t0, // bufferImageHeight\n\t\tNewVkImageSubresourceLayers(a,\n\t\t\tVkImageAspectFlags(dstImgDesc.aspect), // aspectMask\n\t\t\tdstImgDesc.subresource.BaseMipLevel(), // mipLevel\n\t\t\tdstImgDesc.subresource.BaseArrayLayer(), // baseArrayLayer\n\t\t\t1, // layerCount\n\t\t), // srcSubresource\n\t\tNewVkOffset3D(a, 0, 0, 0), // offset\n\t\tNewVkExtent3D(a, extent.Width(), extent.Height(), 1), // extent\n\t)\n\n\timgBarriers0Data := alloc(imgBarriers0)\n\tibCopyData := alloc(ibCopy)\n\tbufBarrierData := alloc(bufBarrier)\n\tbiCopyData := alloc(biCopy)\n\timgBarriers1Data := alloc(imgBarriers1)\n\n\twriteEach(ctx, out,\n\t\tcb.VkCmdPipelineBarrier(cmdBuffer,\n\t\t\tallCommandsStage, // srcStageMask\n\t\t\tVkPipelineStageFlags(VkPipelineStageFlagBits_VK_PIPELINE_STAGE_TRANSFER_BIT), // dstStageMask\n\t\t\t0, // dependencyFlags\n\t\t\t0, // memoryBarrierCount\n\t\t\tmemory.Nullptr, // pMemoryBarriers\n\t\t\t0, // bufferMemoryBarrierCount\n\t\t\tmemory.Nullptr, // pBufferMemoryBarriers\n\t\t\t2, // imageMemoryBarrierCount\n\t\t\timgBarriers0Data.Ptr(), // pImageMemoryBarriers\n\t\t).AddRead(imgBarriers0Data.Data()),\n\t\tcb.VkCmdCopyImageToBuffer(cmdBuffer,\n\t\t\tsrcImg.VulkanHandle(), // srcImage\n\t\t\tVkImageLayout_VK_IMAGE_LAYOUT_TRANSFER_SRC_OPTIMAL, // srcImageLayout\n\t\t\tcopyBuffer, // dstBuffer\n\t\t\t1, // regionCount\n\t\t\tibCopyData.Ptr(), // pRegions\n\t\t).AddRead(ibCopyData.Data()),\n\t\tcb.VkCmdPipelineBarrier(cmdBuffer,\n\t\t\tVkPipelineStageFlags(VkPipelineStageFlagBits_VK_PIPELINE_STAGE_TRANSFER_BIT), // srcStageMask\n\t\t\tVkPipelineStageFlags(VkPipelineStageFlagBits_VK_PIPELINE_STAGE_TRANSFER_BIT), // dstStageMask\n\t\t\t0, // dependencyFlags\n\t\t\t0, // memoryBarrierCount\n\t\t\tmemory.Nullptr, // pMemoryBarriers\n\t\t\t1, // bufferMemoryBarrierCount\n\t\t\tbufBarrierData.Ptr(), // pBufferMemoryBarriers\n\t\t\t0, // imageMemoryBarrierCount\n\t\t\tmemory.Nullptr, // pImageMemoryBarriers\n\t\t).AddRead(bufBarrierData.Data()),\n\t\tcb.VkCmdCopyBufferToImage(cmdBuffer,\n\t\t\tcopyBuffer, // srcBuffer\n\t\t\tdstImg.VulkanHandle(), // dstImage\n\t\t\tVkImageLayout_VK_IMAGE_LAYOUT_TRANSFER_DST_OPTIMAL, // dstImageLayout\n\t\t\t1, // regionCount\n\t\t\tbiCopyData.Ptr(), // pRegions\n\t\t).AddRead(biCopyData.Data()),\n\t\tcb.VkCmdPipelineBarrier(cmdBuffer,\n\t\t\tVkPipelineStageFlags(VkPipelineStageFlagBits_VK_PIPELINE_STAGE_TRANSFER_BIT), // srcStageMask\n\t\t\tallCommandsStage, // dstStageMask\n\t\t\t0, // dependencyFlags\n\t\t\t0, // memoryBarrierCount\n\t\t\tmemory.Nullptr, // pMemoryBarriers\n\t\t\t0, // bufferMemoryBarrierCount\n\t\t\tmemory.Nullptr, // pBufferMemoryBarriers\n\t\t\t2, // imageMemoryBarrierCount\n\t\t\timgBarriers1Data.Ptr(), // pImageMemoryBarriers\n\t\t).AddRead(imgBarriers1Data.Data()),\n\t)\n}", "func CopyTexImage1D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, border int32) {\n\tsyscall.Syscall9(gpCopyTexImage1D, 7, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(x), uintptr(y), uintptr(width), uintptr(border), 0, 0)\n}", "func (p *Alpha16) SubImage(r Rectangle) Image {\n\tr = r.Intersect(p.Rect)\n\t// If r1 and r2 are Rectangles, r1.Intersect(r2) is not guaranteed to be inside\n\t// either r1 or r2 if the intersection is empty. Without explicitly checking for\n\t// this, the Pix[i:] expression below can panic.\n\tif r.Empty() {\n\t\treturn &Alpha16{}\n\t}\n\ti := p.PixOffset(r.Min.X, r.Min.Y)\n\treturn &Alpha16{\n\t\tPix: p.Pix[i:],\n\t\tStride: p.Stride,\n\t\tRect: r,\n\t}\n}", "func Transverse(img image.Image) *image.NRGBA {\n\tsrc := toNRGBA(img)\n\tsrcW := src.Bounds().Max.X\n\tsrcH := src.Bounds().Max.Y\n\tdstW := srcH\n\tdstH := srcW\n\tdst := image.NewNRGBA(image.Rect(0, 0, dstW, dstH))\n\n\tparallel(dstH, func(partStart, partEnd int) {\n\n\t\tfor dstY := partStart; dstY < partEnd; dstY++ {\n\t\t\tfor dstX := 0; dstX < dstW; dstX++ {\n\t\t\t\tsrcX := dstH - dstY - 1\n\t\t\t\tsrcY := dstW - dstX - 1\n\n\t\t\t\tsrcOff := srcY*src.Stride + srcX*4\n\t\t\t\tdstOff := dstY*dst.Stride + dstX*4\n\n\t\t\t\tcopy(dst.Pix[dstOff:dstOff+4], src.Pix[srcOff:srcOff+4])\n\t\t\t}\n\t\t}\n\n\t})\n\n\treturn dst\n}", "func (native *OpenGL) TexImage2D(target uint32, level int32, internalFormat uint32, width int32, height int32,\n\tborder int32, format uint32, xtype uint32, pixels interface{}) {\n\tptr, isPointer := pixels.(unsafe.Pointer)\n\tif isPointer {\n\t\tgl.TexImage2D(target, level, int32(internalFormat), width, height, border, format, xtype, ptr)\n\t} else {\n\t\tgl.TexImage2D(target, level, int32(internalFormat), width, height, border, format, xtype, gl.Ptr(pixels))\n\t}\n}", "func downsample(srcImg image.Image) image.Image {\n\tbounds := srcImg.Bounds()\n\treturn resize.Resize(bounds.Dx()/2, bounds.Dy()/2, srcImg, resize.Bilinear)\n}", "func Copy(i ImageIr) ImageIr {\n\tc := make([][][]uint32, len(i.pixels))\n\tcopy(c, i.pixels)\n\treturn ImageIr{i.width, i.height, c}\n}", "func (w *WebGLRenderTarget) Copy(source *WebGLRenderTarget) *WebGLRenderTarget {\n\tw.p.Call(\"copy\", source.p)\n\treturn w\n}" ]
[ "0.74930286", "0.7101118", "0.7101118", "0.708496", "0.70273286", "0.70273286", "0.70271516", "0.6888059", "0.68646353", "0.6819994", "0.6789447", "0.6789447", "0.6698773", "0.66529685", "0.6626014", "0.65897524", "0.65897524", "0.65730363", "0.6569772", "0.6569772", "0.6524741", "0.6524741", "0.65014005", "0.64738697", "0.64709604", "0.6463622", "0.64520264", "0.64305305", "0.64305305", "0.6424487", "0.6424487", "0.6358789", "0.6358789", "0.6330186", "0.6308607", "0.6252177", "0.62265784", "0.62242293", "0.62235093", "0.619265", "0.619265", "0.61827415", "0.6180693", "0.61696106", "0.61696106", "0.6165113", "0.6165113", "0.6157323", "0.61455667", "0.60965675", "0.6061559", "0.6054501", "0.600202", "0.59747016", "0.5929964", "0.5913897", "0.590047", "0.5897991", "0.5897991", "0.5887224", "0.5864521", "0.5861528", "0.5861528", "0.583343", "0.583343", "0.5813249", "0.57912135", "0.57912135", "0.57669395", "0.576071", "0.576071", "0.57557243", "0.5747388", "0.5747388", "0.5691585", "0.56427956", "0.5613135", "0.5610655", "0.5609311", "0.56090105", "0.55994034", "0.55994034", "0.558444", "0.5573364", "0.5573364", "0.55329484", "0.5522024", "0.55145717", "0.54934907", "0.54910535", "0.5485165", "0.5450349", "0.54150414", "0.54037076", "0.5386456", "0.5384498", "0.5370337", "0.53096336", "0.53061223" ]
0.748996
2
copy a threedimensional texture subimage
func CopyTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) { C.glowCopyTextureSubImage3D(gpCopyTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func CopyTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n\tsyscall.Syscall9(gpCopyTextureSubImage3D, 9, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(x), uintptr(y), uintptr(width), uintptr(height))\n}", "func CopyTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTextureSubImage2D(gpCopyTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CopyTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTextureSubImage2D(gpCopyTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CopyTextureSubImage1D(texture uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tC.glowCopyTextureSubImage1D(gpCopyTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func CopyTextureSubImage1D(texture uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tC.glowCopyTextureSubImage1D(gpCopyTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func CopyTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n\tsyscall.Syscall9(gpCopyTextureSubImage2D, 8, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(x), uintptr(y), uintptr(width), uintptr(height), 0)\n}", "func CopyTextureSubImage1D(texture uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tsyscall.Syscall6(gpCopyTextureSubImage1D, 6, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(x), uintptr(y), uintptr(width))\n}", "func CopyImageSubData(srcName uint32, srcTarget uint32, srcLevel int32, srcX int32, srcY int32, srcZ int32, dstName uint32, dstTarget uint32, dstLevel int32, dstX int32, dstY int32, dstZ int32, srcWidth int32, srcHeight int32, srcDepth int32) {\n C.glowCopyImageSubData(gpCopyImageSubData, (C.GLuint)(srcName), (C.GLenum)(srcTarget), (C.GLint)(srcLevel), (C.GLint)(srcX), (C.GLint)(srcY), (C.GLint)(srcZ), (C.GLuint)(dstName), (C.GLenum)(dstTarget), (C.GLint)(dstLevel), (C.GLint)(dstX), (C.GLint)(dstY), (C.GLint)(dstZ), (C.GLsizei)(srcWidth), (C.GLsizei)(srcHeight), (C.GLsizei)(srcDepth))\n}", "func (tex Texture) Sub(ctx gl.Context, lvl int, width int, height int, data []byte) {\n\tctx.TexSubImage2D(gl.TEXTURE_2D, lvl, 0, 0, width, height, gl.RGBA, gl.UNSIGNED_BYTE, data)\n\tif lvl > 0 {\n\t\tctx.GenerateMipmap(gl.TEXTURE_2D)\n\t}\n}", "func CopyImageSubData(srcName uint32, srcTarget uint32, srcLevel int32, srcX int32, srcY int32, srcZ int32, dstName uint32, dstTarget uint32, dstLevel int32, dstX int32, dstY int32, dstZ int32, srcWidth int32, srcHeight int32, srcDepth int32) {\n\tC.glowCopyImageSubData(gpCopyImageSubData, (C.GLuint)(srcName), (C.GLenum)(srcTarget), (C.GLint)(srcLevel), (C.GLint)(srcX), (C.GLint)(srcY), (C.GLint)(srcZ), (C.GLuint)(dstName), (C.GLenum)(dstTarget), (C.GLint)(dstLevel), (C.GLint)(dstX), (C.GLint)(dstY), (C.GLint)(dstZ), (C.GLsizei)(srcWidth), (C.GLsizei)(srcHeight), (C.GLsizei)(srcDepth))\n}", "func CopyImageSubData(srcName uint32, srcTarget uint32, srcLevel int32, srcX int32, srcY int32, srcZ int32, dstName uint32, dstTarget uint32, dstLevel int32, dstX int32, dstY int32, dstZ int32, srcWidth int32, srcHeight int32, srcDepth int32) {\n\tC.glowCopyImageSubData(gpCopyImageSubData, (C.GLuint)(srcName), (C.GLenum)(srcTarget), (C.GLint)(srcLevel), (C.GLint)(srcX), (C.GLint)(srcY), (C.GLint)(srcZ), (C.GLuint)(dstName), (C.GLenum)(dstTarget), (C.GLint)(dstLevel), (C.GLint)(dstX), (C.GLint)(dstY), (C.GLint)(dstZ), (C.GLsizei)(srcWidth), (C.GLsizei)(srcHeight), (C.GLsizei)(srcDepth))\n}", "func CopyTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n C.glowCopyTexSubImage2D(gpCopyTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func TextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTextureSubImage2D, 9, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(width), uintptr(height), uintptr(format), uintptr(xtype), uintptr(pixels))\n}", "func CopyTexImage2D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, height int32, border int32) {\n C.glowCopyTexImage2D(gpCopyTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border))\n}", "func TextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage2D(gpTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage2D(gpTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CopyTexSubImage1D(target uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n C.glowCopyTexSubImage1D(gpCopyTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func TexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexSubImage2D(gpTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage3D(gpTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage3D(gpTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CopyTexImage2D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, height int32, border int32) {\n\tsyscall.Syscall9(gpCopyTexImage2D, 8, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(x), uintptr(y), uintptr(width), uintptr(height), uintptr(border), 0)\n}", "func TextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTextureSubImage1D, 7, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(width), uintptr(format), uintptr(xtype), uintptr(pixels), 0, 0)\n}", "func GetTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetTextureSubImage(gpGetTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), (C.GLsizei)(bufSize), pixels)\n}", "func GetTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetTextureSubImage(gpGetTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), (C.GLsizei)(bufSize), pixels)\n}", "func TextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall12(gpTextureSubImage3D, 11, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(xtype), uintptr(pixels), 0)\n}", "func CopyTexImage2D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, height int32, border int32) {\n\tC.glowCopyTexImage2D(gpCopyTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border))\n}", "func CopyTexImage2D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, height int32, border int32) {\n\tC.glowCopyTexImage2D(gpCopyTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border))\n}", "func CopyTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTexSubImage2D(gpCopyTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CopyTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTexSubImage2D(gpCopyTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func TextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage1D(gpTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTextureSubImage1D(gpTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CopyTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n C.glowCopyTexSubImage3D(gpCopyTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CopyTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, x int32, y int32, width int32, height int32) {\n\tsyscall.Syscall9(gpCopyTexSubImage2D, 8, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(x), uintptr(y), uintptr(width), uintptr(height), 0)\n}", "func TexSubImage2D(target Enum, level int, x, y, width, height int, format, ty Enum, data []byte) {\n\tgl.TexSubImage2D(uint32(target), int32(level), int32(x), int32(y), int32(width), int32(height), uint32(format), uint32(ty), gl.Ptr(&data[0]))\n}", "func TexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage2D(gpTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage2D(gpTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CopyImageSubData(srcName uint32, srcTarget uint32, srcLevel int32, srcX int32, srcY int32, srcZ int32, dstName uint32, dstTarget uint32, dstLevel int32, dstX int32, dstY int32, dstZ int32, srcWidth int32, srcHeight int32, srcDepth int32) {\n\tsyscall.Syscall15(gpCopyImageSubData, 15, uintptr(srcName), uintptr(srcTarget), uintptr(srcLevel), uintptr(srcX), uintptr(srcY), uintptr(srcZ), uintptr(dstName), uintptr(dstTarget), uintptr(dstLevel), uintptr(dstX), uintptr(dstY), uintptr(dstZ), uintptr(srcWidth), uintptr(srcHeight), uintptr(srcDepth))\n}", "func GetTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, bufSize int32, pixels unsafe.Pointer) {\n\tsyscall.Syscall12(gpGetTextureSubImage, 12, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(xtype), uintptr(bufSize), uintptr(pixels))\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexSubImage3D(gpTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTexSubImage2D, 9, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(width), uintptr(height), uintptr(format), uintptr(xtype), uintptr(pixels))\n}", "func CopyTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTexSubImage3D(gpCopyTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func CopyTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n\tC.glowCopyTexSubImage3D(gpCopyTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func TexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexSubImage1D(gpTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CopyTexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, x int32, y int32, width int32, height int32) {\n\tsyscall.Syscall9(gpCopyTexSubImage3D, 9, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(x), uintptr(y), uintptr(width), uintptr(height))\n}", "func CopyTexImage2D(target GLEnum, level int32, internalformat GLEnum, x, y, width, height, border int32) {\n\tgl.CopyTexImage2D(uint32(target), level, uint32(internalformat), x, y, width, height, border)\n}", "func CopyTexSubImage2D(target GLEnum, level, xoffset, yoffset, x, y, width, height int32) {\n\tgl.CopyTexSubImage2D(uint32(target), level, xoffset, yoffset, x, y, width, height)\n}", "func CompressedTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage2D(gpCompressedTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage2D(gpCompressedTextureSubImage2D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CopyTexSubImage1D(target uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tC.glowCopyTexSubImage1D(gpCopyTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func CopyTexSubImage1D(target uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tC.glowCopyTexSubImage1D(gpCopyTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage3D(gpTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage3D(gpTexSubImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CopyBufferSubData(readTarget uint32, writeTarget uint32, readOffset int, writeOffset int, size int) {\n C.glowCopyBufferSubData(gpCopyBufferSubData, (C.GLenum)(readTarget), (C.GLenum)(writeTarget), (C.GLintptr)(readOffset), (C.GLintptr)(writeOffset), (C.GLsizeiptr)(size))\n}", "func CopyColorSubTable(target uint32, start int32, x int32, y int32, width int32) {\n C.glowCopyColorSubTable(gpCopyColorSubTable, (C.GLenum)(target), (C.GLsizei)(start), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func TexSubImage3D(target uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall12(gpTexSubImage3D, 11, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(xtype), uintptr(pixels), 0)\n}", "func GetCompressedTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetCompressedTextureSubImage(gpGetCompressedTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLsizei)(bufSize), pixels)\n}", "func GetCompressedTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetCompressedTextureSubImage(gpGetCompressedTextureSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLsizei)(bufSize), pixels)\n}", "func CopyTexSubImage1D(target uint32, level int32, xoffset int32, x int32, y int32, width int32) {\n\tsyscall.Syscall6(gpCopyTexSubImage1D, 6, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(x), uintptr(y), uintptr(width))\n}", "func CompressedTextureSubImage2D(texture uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTextureSubImage2D, 9, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(width), uintptr(height), uintptr(format), uintptr(imageSize), uintptr(data))\n}", "func CompressedTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage3D(gpCompressedTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage3D(gpCompressedTextureSubImage3D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CopyTexImage2D(target Enum, level int, internalformat Enum, x, y, width, height, border int) {\n\tgl.CopyTexImage2D(uint32(target), int32(level), uint32(internalformat), int32(x), int32(y), int32(width), int32(height), int32(border))\n}", "func CopyColorSubTable(target uint32, start int32, x int32, y int32, width int32) {\n\tC.glowCopyColorSubTable(gpCopyColorSubTable, (C.GLenum)(target), (C.GLsizei)(start), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width))\n}", "func TexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage1D(gpTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexSubImage1D(gpTexSubImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexSubImage2D(target GLEnum, level, xoffset, yoffset, width, height int32, format, xtype GLEnum, pixels []float32) {\n\tgl.TexSubImage2D(uint32(target), level, xoffset, yoffset, width, height, uint32(format), uint32(xtype), unsafe.Pointer(&pixels[0]))\n}", "func CopyTexSubImage2D(target Enum, level, xoffset, yoffset, x, y, width, height int) {\n\tgl.CopyTexSubImage2D(uint32(target), int32(level), int32(xoffset), int32(yoffset), int32(x), int32(y), int32(width), int32(height))\n}", "func CopyTexImage1D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, border int32) {\n C.glowCopyTexImage1D(gpCopyTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLint)(border))\n}", "func TexSubImage1D(target uint32, level int32, xoffset int32, width int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTexSubImage1D, 7, uintptr(target), uintptr(level), uintptr(xoffset), uintptr(width), uintptr(format), uintptr(xtype), uintptr(pixels), 0, 0)\n}", "func GetCompressedTextureSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, bufSize int32, pixels unsafe.Pointer) {\n\tsyscall.Syscall12(gpGetCompressedTextureSubImage, 10, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(bufSize), uintptr(pixels), 0, 0)\n}", "func TexSubImage2D(target Enum, level Int, xoffset Int, yoffset Int, width Sizei, height Sizei, format Enum, kind Enum, pixels unsafe.Pointer) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tclevel, _ := (C.GLint)(level), cgoAllocsUnknown\n\tcxoffset, _ := (C.GLint)(xoffset), cgoAllocsUnknown\n\tcyoffset, _ := (C.GLint)(yoffset), cgoAllocsUnknown\n\tcwidth, _ := (C.GLsizei)(width), cgoAllocsUnknown\n\tcheight, _ := (C.GLsizei)(height), cgoAllocsUnknown\n\tcformat, _ := (C.GLenum)(format), cgoAllocsUnknown\n\tckind, _ := (C.GLenum)(kind), cgoAllocsUnknown\n\tcpixels, _ := (unsafe.Pointer)(unsafe.Pointer(pixels)), cgoAllocsUnknown\n\tC.glTexSubImage2D(ctarget, clevel, cxoffset, cyoffset, cwidth, cheight, cformat, ckind, cpixels)\n}", "func CopyTexSubImage2D(target Enum, level Int, xoffset Int, yoffset Int, x Int, y Int, width Sizei, height Sizei) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tclevel, _ := (C.GLint)(level), cgoAllocsUnknown\n\tcxoffset, _ := (C.GLint)(xoffset), cgoAllocsUnknown\n\tcyoffset, _ := (C.GLint)(yoffset), cgoAllocsUnknown\n\tcx, _ := (C.GLint)(x), cgoAllocsUnknown\n\tcy, _ := (C.GLint)(y), cgoAllocsUnknown\n\tcwidth, _ := (C.GLsizei)(width), cgoAllocsUnknown\n\tcheight, _ := (C.GLsizei)(height), cgoAllocsUnknown\n\tC.glCopyTexSubImage2D(ctarget, clevel, cxoffset, cyoffset, cx, cy, cwidth, cheight)\n}", "func CopyTexImage2D(target Enum, level Int, internalformat Enum, x Int, y Int, width Sizei, height Sizei, border Int) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tclevel, _ := (C.GLint)(level), cgoAllocsUnknown\n\tcinternalformat, _ := (C.GLenum)(internalformat), cgoAllocsUnknown\n\tcx, _ := (C.GLint)(x), cgoAllocsUnknown\n\tcy, _ := (C.GLint)(y), cgoAllocsUnknown\n\tcwidth, _ := (C.GLsizei)(width), cgoAllocsUnknown\n\tcheight, _ := (C.GLsizei)(height), cgoAllocsUnknown\n\tcborder, _ := (C.GLint)(border), cgoAllocsUnknown\n\tC.glCopyTexImage2D(ctarget, clevel, cinternalformat, cx, cy, cwidth, cheight, cborder)\n}", "func CopyTexImage1D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, border int32) {\n\tsyscall.Syscall9(gpCopyTexImage1D, 7, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(x), uintptr(y), uintptr(width), uintptr(border), 0, 0)\n}", "func CopyBufferSubData(readTarget uint32, writeTarget uint32, readOffset int, writeOffset int, size int) {\n\tC.glowCopyBufferSubData(gpCopyBufferSubData, (C.GLenum)(readTarget), (C.GLenum)(writeTarget), (C.GLintptr)(readOffset), (C.GLintptr)(writeOffset), (C.GLsizeiptr)(size))\n}", "func CopyBufferSubData(readTarget uint32, writeTarget uint32, readOffset int, writeOffset int, size int) {\n\tC.glowCopyBufferSubData(gpCopyBufferSubData, (C.GLenum)(readTarget), (C.GLenum)(writeTarget), (C.GLintptr)(readOffset), (C.GLintptr)(writeOffset), (C.GLsizeiptr)(size))\n}", "func CompressedTextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage1D(gpCompressedTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tC.glowCompressedTextureSubImage1D(gpCompressedTextureSubImage1D, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLsizei)(width), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func CompressedTextureSubImage3D(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall12(gpCompressedTextureSubImage3D, 11, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(yoffset), uintptr(zoffset), uintptr(width), uintptr(height), uintptr(depth), uintptr(format), uintptr(imageSize), uintptr(data), 0)\n}", "func (t *Texture) Clone() *Texture {\n\tt.p.Call(\"clone\")\n\treturn t\n}", "func CopyImageSubDataNV(hSrcRC unsafe.Pointer, srcName uint32, srcTarget uint32, srcLevel int32, srcX int32, srcY int32, srcZ int32, hDstRC unsafe.Pointer, dstName uint32, dstTarget uint32, dstLevel int32, dstX int32, dstY int32, dstZ int32, width int32, height int32, depth int32) unsafe.Pointer {\n\tpanic(\"\\\"CopyImageSubDataNV\\\" is not implemented\")\n}", "func (p *Paletted) SubImage(r Rectangle) Image {\n\tr = r.Intersect(p.Rect)\n\t// If r1 and r2 are Rectangles, r1.Intersect(r2) is not guaranteed to be inside\n\t// either r1 or r2 if the intersection is empty. Without explicitly checking for\n\t// this, the Pix[i:] expression below can panic.\n\tif r.Empty() {\n\t\treturn &Paletted{\n\t\t\tPalette: p.Palette,\n\t\t}\n\t}\n\ti := p.PixOffset(r.Min.X, r.Min.Y)\n\treturn &Paletted{\n\t\tPix: p.Pix[i:],\n\t\tStride: p.Stride,\n\t\tRect: p.Rect.Intersect(r),\n\t\tPalette: p.Palette,\n\t}\n}", "func CopyTexImage1D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, border int32) {\n\tC.glowCopyTexImage1D(gpCopyTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLint)(border))\n}", "func CopyTexImage1D(target uint32, level int32, internalformat uint32, x int32, y int32, width int32, border int32) {\n\tC.glowCopyTexImage1D(gpCopyTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLint)(border))\n}", "func CompressedTextureSubImage1D(texture uint32, level int32, xoffset int32, width int32, format uint32, imageSize int32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpCompressedTextureSubImage1D, 7, uintptr(texture), uintptr(level), uintptr(xoffset), uintptr(width), uintptr(format), uintptr(imageSize), uintptr(data), 0, 0)\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexImage2D(gpTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CompressedTexSubImage2D(target uint32, level int32, xoffset int32, yoffset int32, width int32, height int32, format uint32, imageSize int32, data unsafe.Pointer) {\n C.glowCompressedTexSubImage2D(gpCompressedTexSubImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLsizei)(imageSize), data)\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexImage2D(gpTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexImage2D(gpTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTexImage2D, 9, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(width), uintptr(height), uintptr(border), uintptr(format), uintptr(xtype), uintptr(pixels))\n}", "func Copy(dst draw.Image, src image.Image) {\n\tbd := src.Bounds().Intersect(dst.Bounds())\n\tat := imageutil.NewAtFunc(src)\n\tset := imageutil.NewSetFunc(dst)\n\timageutil.Parallel1D(bd, func(bd image.Rectangle) {\n\t\tfor y := bd.Min.Y; y < bd.Max.Y; y++ {\n\t\t\tfor x := bd.Min.X; x < bd.Max.X; x++ {\n\t\t\t\tr, g, b, a := at(x, y)\n\t\t\t\tset(x, y, r, g, b, a)\n\t\t\t}\n\t\t}\n\t})\n}", "func TexImage2D(target Enum, level int, width, height int, format Enum, ty Enum, data []byte) {\n\tp := unsafe.Pointer(nil)\n\tif len(data) > 0 {\n\t\tp = gl.Ptr(&data[0])\n\t}\n\tgl.TexImage2D(uint32(target), int32(level), int32(format), int32(width), int32(height), 0, uint32(format), uint32(ty), p)\n}", "func (self *TileSprite) TintedTexture() *Canvas{\n return &Canvas{self.Object.Get(\"tintedTexture\")}\n}", "func TexImage2D(target GLEnum, level int32, internalformat GLEnum, width, height, border int32, format, xtype GLEnum, pixels []float32) {\n\tgl.TexImage2D(uint32(target), level, int32(internalformat), width, height, border, uint32(format), uint32(xtype), unsafe.Pointer(&pixels[0]))\n}", "func (s *stencilOverdraw) copyImageAspect(ctx context.Context,\n\tcb CommandBuilder,\n\tgs *api.GlobalState,\n\tst *State,\n\ta arena.Arena,\n\tdevice VkDevice,\n\tcmdBuffer VkCommandBuffer,\n\tsrcImgDesc imageDesc,\n\tdstImgDesc imageDesc,\n\textent VkExtent3D,\n\talloc func(v ...interface{}) api.AllocResult,\n\taddCleanup func(func()),\n\tout transform.Writer,\n) {\n\tsrcImg := srcImgDesc.image\n\tdstImg := dstImgDesc.image\n\tcopyBuffer := s.createDepthCopyBuffer(ctx, cb, gs, st, a, device,\n\t\tsrcImg.Info().Fmt(),\n\t\textent.Width(), extent.Height(),\n\t\talloc, addCleanup, out)\n\n\tallCommandsStage := VkPipelineStageFlags(\n\t\tVkPipelineStageFlagBits_VK_PIPELINE_STAGE_ALL_COMMANDS_BIT)\n\tallMemoryAccess := VkAccessFlags(\n\t\tVkAccessFlagBits_VK_ACCESS_MEMORY_WRITE_BIT |\n\t\t\tVkAccessFlagBits_VK_ACCESS_MEMORY_READ_BIT)\n\n\timgBarriers0 := make([]VkImageMemoryBarrier, 2)\n\timgBarriers1 := make([]VkImageMemoryBarrier, 2)\n\t// Transition the src image in and out of the required layouts\n\timgBarriers0[0] = NewVkImageMemoryBarrier(a,\n\t\tVkStructureType_VK_STRUCTURE_TYPE_IMAGE_MEMORY_BARRIER, // sType\n\t\t0, // pNext\n\t\tallMemoryAccess, // srcAccessMask\n\t\tVkAccessFlags(VkAccessFlagBits_VK_ACCESS_TRANSFER_READ_BIT), // dstAccessMask\n\t\tsrcImgDesc.layout, // oldLayout\n\t\tVkImageLayout_VK_IMAGE_LAYOUT_TRANSFER_SRC_OPTIMAL, // newLayout\n\t\t^uint32(0), // srcQueueFamilyIndex: VK_QUEUE_FAMILY_IGNORED\n\t\t^uint32(0), // dstQueueFamilyIndex\n\t\tsrcImg.VulkanHandle(), // image\n\t\tsrcImgDesc.subresource, // subresourceRange\n\t)\n\tsrcFinalLayout := srcImgDesc.layout\n\tif srcFinalLayout == VkImageLayout_VK_IMAGE_LAYOUT_UNDEFINED ||\n\t\tsrcFinalLayout == VkImageLayout_VK_IMAGE_LAYOUT_PREINITIALIZED {\n\t\tsrcFinalLayout = VkImageLayout_VK_IMAGE_LAYOUT_GENERAL\n\t}\n\timgBarriers1[0] = NewVkImageMemoryBarrier(a,\n\t\tVkStructureType_VK_STRUCTURE_TYPE_IMAGE_MEMORY_BARRIER, // sType\n\t\t0, // pNext\n\t\tVkAccessFlags(VkAccessFlagBits_VK_ACCESS_TRANSFER_READ_BIT), // srcAccessMask\n\t\tallMemoryAccess, // dstAccessMask\n\t\tVkImageLayout_VK_IMAGE_LAYOUT_TRANSFER_SRC_OPTIMAL, // oldLayout\n\t\tsrcFinalLayout, // newLayout\n\t\t^uint32(0), // srcQueueFamilyIndex: VK_QUEUE_FAMILY_IGNORED\n\t\t^uint32(0), // dstQueueFamilyIndex\n\t\tsrcImg.VulkanHandle(), // image\n\t\tsrcImgDesc.subresource, // subresourceRange\n\t)\n\n\t// Transition the new image in and out of its required layouts\n\timgBarriers0[1] = NewVkImageMemoryBarrier(a,\n\t\tVkStructureType_VK_STRUCTURE_TYPE_IMAGE_MEMORY_BARRIER, // sType\n\t\t0, // pNext\n\t\tallMemoryAccess, // srcAccessMask\n\t\tVkAccessFlags(VkAccessFlagBits_VK_ACCESS_TRANSFER_WRITE_BIT), // dstAccessMask\n\t\tdstImgDesc.layout, // oldLayout\n\t\tVkImageLayout_VK_IMAGE_LAYOUT_TRANSFER_DST_OPTIMAL, // newLayout\n\t\t^uint32(0), // srcQueueFamilyIndex: VK_QUEUE_FAMILY_IGNORED\n\t\t^uint32(0), // dstQueueFamilyIndex\n\t\tdstImg.VulkanHandle(), // image\n\t\tdstImgDesc.subresource, // subresourceRange\n\t)\n\n\tdstFinalLayout := dstImgDesc.layout\n\tif dstFinalLayout == VkImageLayout_VK_IMAGE_LAYOUT_UNDEFINED ||\n\t\tdstFinalLayout == VkImageLayout_VK_IMAGE_LAYOUT_PREINITIALIZED {\n\t\tdstFinalLayout = VkImageLayout_VK_IMAGE_LAYOUT_GENERAL\n\t}\n\timgBarriers1[1] = NewVkImageMemoryBarrier(a,\n\t\tVkStructureType_VK_STRUCTURE_TYPE_IMAGE_MEMORY_BARRIER, // sType\n\t\t0, // pNext\n\t\tVkAccessFlags(VkAccessFlagBits_VK_ACCESS_TRANSFER_WRITE_BIT), // srcAccessMask\n\t\tallMemoryAccess, // dstAccessMask\n\t\tVkImageLayout_VK_IMAGE_LAYOUT_TRANSFER_DST_OPTIMAL, // oldLayout\n\t\tdstFinalLayout, // newLayout\n\t\t^uint32(0), // srcQueueFamilyIndex: VK_QUEUE_FAMILY_IGNORED\n\t\t^uint32(0), // dstQueueFamilyIndex\n\t\tdstImg.VulkanHandle(), // image\n\t\tdstImgDesc.subresource, // subresourceRange\n\t)\n\n\tbufBarrier := NewVkBufferMemoryBarrier(a,\n\t\tVkStructureType_VK_STRUCTURE_TYPE_BUFFER_MEMORY_BARRIER, // sType\n\t\t0, // pNext\n\t\tVkAccessFlags(VkAccessFlagBits_VK_ACCESS_TRANSFER_WRITE_BIT), // srcAccessMask\n\t\tVkAccessFlags(VkAccessFlagBits_VK_ACCESS_TRANSFER_READ_BIT), // dstAccessMask\n\t\t^uint32(0), // srcQueueFamilyIndex: VK_QUEUE_FAMILY_IGNORED\n\t\t^uint32(0), // dstQueueFamilyIndex\n\t\tcopyBuffer, // buffer\n\t\t0, // offset\n\t\t^VkDeviceSize(0), // size: VK_WHOLE_SIZE\n\t)\n\n\tibCopy := NewVkBufferImageCopy(a,\n\t\t0, // bufferOffset\n\t\t0, // bufferRowLength\n\t\t0, // bufferImageHeight\n\t\tNewVkImageSubresourceLayers(a,\n\t\t\tVkImageAspectFlags(srcImgDesc.aspect), // aspectMask\n\t\t\tsrcImgDesc.subresource.BaseMipLevel(), // mipLevel\n\t\t\tsrcImgDesc.subresource.BaseArrayLayer(), // baseArrayLayer\n\t\t\t1, // layerCount\n\t\t), // srcSubresource\n\t\tNewVkOffset3D(a, 0, 0, 0), // offset\n\t\tNewVkExtent3D(a, extent.Width(), extent.Height(), 1), // extent\n\t)\n\n\tbiCopy := NewVkBufferImageCopy(a,\n\t\t0, // bufferOffset\n\t\t0, // bufferRowLength\n\t\t0, // bufferImageHeight\n\t\tNewVkImageSubresourceLayers(a,\n\t\t\tVkImageAspectFlags(dstImgDesc.aspect), // aspectMask\n\t\t\tdstImgDesc.subresource.BaseMipLevel(), // mipLevel\n\t\t\tdstImgDesc.subresource.BaseArrayLayer(), // baseArrayLayer\n\t\t\t1, // layerCount\n\t\t), // srcSubresource\n\t\tNewVkOffset3D(a, 0, 0, 0), // offset\n\t\tNewVkExtent3D(a, extent.Width(), extent.Height(), 1), // extent\n\t)\n\n\timgBarriers0Data := alloc(imgBarriers0)\n\tibCopyData := alloc(ibCopy)\n\tbufBarrierData := alloc(bufBarrier)\n\tbiCopyData := alloc(biCopy)\n\timgBarriers1Data := alloc(imgBarriers1)\n\n\twriteEach(ctx, out,\n\t\tcb.VkCmdPipelineBarrier(cmdBuffer,\n\t\t\tallCommandsStage, // srcStageMask\n\t\t\tVkPipelineStageFlags(VkPipelineStageFlagBits_VK_PIPELINE_STAGE_TRANSFER_BIT), // dstStageMask\n\t\t\t0, // dependencyFlags\n\t\t\t0, // memoryBarrierCount\n\t\t\tmemory.Nullptr, // pMemoryBarriers\n\t\t\t0, // bufferMemoryBarrierCount\n\t\t\tmemory.Nullptr, // pBufferMemoryBarriers\n\t\t\t2, // imageMemoryBarrierCount\n\t\t\timgBarriers0Data.Ptr(), // pImageMemoryBarriers\n\t\t).AddRead(imgBarriers0Data.Data()),\n\t\tcb.VkCmdCopyImageToBuffer(cmdBuffer,\n\t\t\tsrcImg.VulkanHandle(), // srcImage\n\t\t\tVkImageLayout_VK_IMAGE_LAYOUT_TRANSFER_SRC_OPTIMAL, // srcImageLayout\n\t\t\tcopyBuffer, // dstBuffer\n\t\t\t1, // regionCount\n\t\t\tibCopyData.Ptr(), // pRegions\n\t\t).AddRead(ibCopyData.Data()),\n\t\tcb.VkCmdPipelineBarrier(cmdBuffer,\n\t\t\tVkPipelineStageFlags(VkPipelineStageFlagBits_VK_PIPELINE_STAGE_TRANSFER_BIT), // srcStageMask\n\t\t\tVkPipelineStageFlags(VkPipelineStageFlagBits_VK_PIPELINE_STAGE_TRANSFER_BIT), // dstStageMask\n\t\t\t0, // dependencyFlags\n\t\t\t0, // memoryBarrierCount\n\t\t\tmemory.Nullptr, // pMemoryBarriers\n\t\t\t1, // bufferMemoryBarrierCount\n\t\t\tbufBarrierData.Ptr(), // pBufferMemoryBarriers\n\t\t\t0, // imageMemoryBarrierCount\n\t\t\tmemory.Nullptr, // pImageMemoryBarriers\n\t\t).AddRead(bufBarrierData.Data()),\n\t\tcb.VkCmdCopyBufferToImage(cmdBuffer,\n\t\t\tcopyBuffer, // srcBuffer\n\t\t\tdstImg.VulkanHandle(), // dstImage\n\t\t\tVkImageLayout_VK_IMAGE_LAYOUT_TRANSFER_DST_OPTIMAL, // dstImageLayout\n\t\t\t1, // regionCount\n\t\t\tbiCopyData.Ptr(), // pRegions\n\t\t).AddRead(biCopyData.Data()),\n\t\tcb.VkCmdPipelineBarrier(cmdBuffer,\n\t\t\tVkPipelineStageFlags(VkPipelineStageFlagBits_VK_PIPELINE_STAGE_TRANSFER_BIT), // srcStageMask\n\t\t\tallCommandsStage, // dstStageMask\n\t\t\t0, // dependencyFlags\n\t\t\t0, // memoryBarrierCount\n\t\t\tmemory.Nullptr, // pMemoryBarriers\n\t\t\t0, // bufferMemoryBarrierCount\n\t\t\tmemory.Nullptr, // pBufferMemoryBarriers\n\t\t\t2, // imageMemoryBarrierCount\n\t\t\timgBarriers1Data.Ptr(), // pImageMemoryBarriers\n\t\t).AddRead(imgBarriers1Data.Data()),\n\t)\n}", "func (w *WebGLRenderTarget) Copy(source *WebGLRenderTarget) *WebGLRenderTarget {\n\tw.p.Call(\"copy\", source.p)\n\treturn w\n}", "func (debugging *debuggingOpenGL) TexImage2D(target uint32, level int32, internalFormat uint32, width int32, height int32,\n\tborder int32, format uint32, xtype uint32, pixels interface{}) {\n\tdebugging.recordEntry(\"TexImage2D\", target, level, internalFormat, width, height, border, format, xtype, pixels)\n\tdebugging.gl.TexImage2D(target, level, internalFormat, width, height, border, format, xtype, pixels)\n\tdebugging.recordExit(\"TexImage2D\")\n}", "func Copy(i ImageIr) ImageIr {\n\tc := make([][][]uint32, len(i.pixels))\n\tcopy(c, i.pixels)\n\treturn ImageIr{i.width, i.height, c}\n}", "func ClearTexSubImage(texture uint32, level int32, xoffset int32, yoffset int32, zoffset int32, width int32, height int32, depth int32, format uint32, xtype uint32, data unsafe.Pointer) {\n C.glowClearTexSubImage(gpClearTexSubImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLint)(xoffset), (C.GLint)(yoffset), (C.GLint)(zoffset), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLenum)(format), (C.GLenum)(xtype), data)\n}" ]
[ "0.7187993", "0.70949566", "0.70949566", "0.708144", "0.708144", "0.70596516", "0.7054913", "0.67202014", "0.6595204", "0.65076804", "0.65076804", "0.64512175", "0.63771796", "0.63712007", "0.6359094", "0.6359094", "0.6334243", "0.6325183", "0.63112533", "0.63112533", "0.6302705", "0.62790334", "0.6275056", "0.6275056", "0.62609875", "0.6257258", "0.6257258", "0.62356967", "0.62356967", "0.6231525", "0.6231525", "0.6225208", "0.6179596", "0.6171186", "0.61664397", "0.61664397", "0.6160316", "0.6146657", "0.61387587", "0.61212903", "0.61169785", "0.61169785", "0.6108922", "0.60923976", "0.60897774", "0.6081194", "0.6072792", "0.6072792", "0.60632414", "0.60632414", "0.60605687", "0.60605687", "0.60472995", "0.60226524", "0.6010495", "0.5983922", "0.5983922", "0.5964952", "0.59475", "0.59307337", "0.59307337", "0.59211874", "0.59087914", "0.589313", "0.589313", "0.5888336", "0.58417827", "0.58100647", "0.5787175", "0.57688576", "0.57660896", "0.5761601", "0.575254", "0.5739825", "0.57214755", "0.57214755", "0.5692504", "0.5692504", "0.56906873", "0.5661127", "0.5624166", "0.5599978", "0.5572948", "0.5572948", "0.5561408", "0.54319286", "0.5425427", "0.54194856", "0.54194856", "0.5403998", "0.54017115", "0.5395289", "0.53816503", "0.53387606", "0.53362775", "0.52835846", "0.52802545", "0.5277008", "0.516684" ]
0.72157633
1
Creates a program object
func CreateProgram() uint32 { ret := C.glowCreateProgram(gpCreateProgram) return (uint32)(ret) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func NewProgram(cfg *client.Config, parentName string) *tea.Program {\n\tm := NewModel(cfg)\n\tm.standalone = true\n\tm.parentName = parentName\n\treturn tea.NewProgram(m)\n}", "func NewProgram() *Program {\n\treturn &Program{\n\t\tframe: EmptyFrame(),\n\t}\n}", "func NewProgram(data []byte) *Program {\n\tp := new(Program)\n\tp.data = make([]byte, len(data))\n\tcopy(data, p.data)\n\tp.Pc = 0\n\treturn p\n}", "func NewProgram() Program {\n\treturn &program{\n\t\tstatements: make([]Statement, 0, 5),\n\t}\n}", "func NewProgram(lessons []*LessonPgm) *Program {\n\treturn &Program{base.WildCardLabel, lessons}\n}", "func NewProgram(params *utils.Params, in, out circuit.IO,\n\tconsts map[string]ConstantInst, steps []Step) (*Program, error) {\n\n\tprog := &Program{\n\t\tParams: params,\n\t\tInputs: in,\n\t\tOutputs: out,\n\t\tConstants: consts,\n\t\tSteps: steps,\n\t\twires: make(map[string]*wireAlloc),\n\t\tfreeWires: make(map[types.Size][][]*circuits.Wire),\n\t}\n\n\t// Inputs into wires.\n\tfor idx, arg := range in {\n\t\tif len(arg.Name) == 0 {\n\t\t\targ.Name = fmt.Sprintf(\"arg{%d}\", idx)\n\t\t}\n\t\twires, err := prog.Wires(arg.Name, types.Size(arg.Size))\n\t\tif err != nil {\n\t\t\treturn nil, err\n\t\t}\n\t\tprog.InputWires = append(prog.InputWires, wires...)\n\t}\n\n\treturn prog, nil\n}", "func NewProgram() (p *Program) {\n\tdefer func() {\n\t\t// Need for \"stdbool.h\"\n\t\tp.TypedefType[\"_Bool\"] = \"int\"\n\t\t// Initialization c4go implementation of CSTD structs\n\t\tp.initializationStructs()\n\t}()\n\treturn &Program{\n\t\timports: []string{},\n\t\ttypesAlreadyDefined: []string{},\n\t\tstartupStatements: []goast.Stmt{},\n\t\tStructs: StructRegistry(map[string]*Struct{\n\t\t\t// Structs without implementations inside system C headers\n\t\t\t// Example node for adding:\n\t\t\t// &ast.TypedefDecl{ ... Type:\"struct __locale_struct *\" ... }\n\t\t}),\n\t\tUnions: make(StructRegistry),\n\t\tVerbose: false,\n\t\tmessages: []string{},\n\t\tGlobalVariables: map[string]string{},\n\t\tEnumConstantToEnum: map[string]string{},\n\t\tEnumTypedefName: map[string]bool{},\n\t\tTypedefType: map[string]string{},\n\t\tcommentLine: map[string]commentPos{},\n\t\tfunctionDefinitions: map[string]DefinitionFunction{},\n\t\tbuiltInFunctionDefinitionsHaveBeenLoaded: false,\n\t\tUnsafeConvertValueToPointer: map[string]bool{},\n\t\tUnsafeConvertPointerArith: map[string]bool{},\n\t}\n}", "func Program(name string, env []string) Runner {\n\treturn &program{\n\t\tname: name,\n\t\tenv: append(os.Environ(), env...),\n\t}\n}", "func NewProgram(cfg Config) *tea.Program {\n\tif cfg.Logfile != \"\" {\n\t\tlog.Println(\"-- Starting Glow ----------------\")\n\t\tlog.Printf(\"High performance pager: %v\", cfg.HighPerformancePager)\n\t\tlog.Printf(\"Glamour rendering: %v\", cfg.GlamourEnabled)\n\t\tlog.Println(\"Bubble Tea now initializing...\")\n\t\tdebug = true\n\t}\n\tconfig = cfg\n\topts := []tea.ProgramOption{tea.WithAltScreen()}\n\tif cfg.EnableMouse {\n\t\topts = append(opts, tea.WithMouseCellMotion())\n\t}\n\treturn tea.NewProgram(newModel(cfg), opts...)\n}", "func TestNewProgram(t *testing.T) {\n\tp, err := NewProgram()\n\tif err != nil {\n\t\tt.Errorf(\"New program failed : %s\", fmt.Sprint(err))\n\t}\n\n\tdefer p.Close()\n\n\tif p.IsRunning == true {\n\t\tt.Error(\"New program failed : IsRunning is true\")\n\t}\n\n\tif p.windows == nil {\n\t\tt.Error(\"New program failed : windows's map not init\")\n\t}\n\n\tif p.showed == nil {\n\t\tt.Error(\"New program failed : showed windows map not init\")\n\t}\n}", "func (c *DetaClient) NewProgram(r *NewProgramRequest) (*NewProgramResponse, error) {\n\ti := &requestInput{\n\t\tPath: fmt.Sprintf(\"/%s/\", \"programs\"),\n\t\tMethod: \"POST\",\n\t\tNeedsAuth: true,\n\t\tBody: *r,\n\t}\n\n\to, err := c.request(i)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\n\tif o.Status != 200 {\n\t\tmsg := o.Error.Message\n\t\tif msg == \"\" {\n\t\t\tmsg = o.Error.Errors[0]\n\t\t}\n\t\treturn nil, fmt.Errorf(\"failed to create new program: %v\", msg)\n\t}\n\n\tvar resp NewProgramResponse\n\terr = json.Unmarshal(o.Body, &resp)\n\tif err != nil {\n\t\treturn nil, fmt.Errorf(\"failed to create new program: %v\", err)\n\t}\n\treturn &resp, nil\n}", "func createProgram(packages ...string) (*loader.Program, error) {\n\tvar conf loader.Config\n\n\tfor _, name := range packages {\n\t\tconf.CreateFromFilenames(name, getFileNames(name)...)\n\t}\n\treturn conf.Load()\n}", "func CreateProgram() Program {\n\treturn Program{Value: uint32(gl.CreateProgram())}\n}", "func newProgGen(factory progFactory) (Program, error) {\n\t// Test the factory to make sure that configuration errors are spotted at config\n\t_, err := factory(interpreter.NewEvalState(), &interpreter.CostTracker{})\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\treturn &progGen{factory: factory}, nil\n}", "func newProgram(e *Env, ast *Ast, opts []ProgramOption) (Program, error) {\n\t// Build the dispatcher, interpreter, and default program value.\n\tdisp := interpreter.NewDispatcher()\n\n\t// Ensure the default attribute factory is set after the adapter and provider are\n\t// configured.\n\tp := &prog{\n\t\tEnv: e,\n\t\tdecorators: []interpreter.InterpretableDecorator{},\n\t\tdispatcher: disp,\n\t}\n\n\t// Configure the program via the ProgramOption values.\n\tvar err error\n\tfor _, opt := range opts {\n\t\tp, err = opt(p)\n\t\tif err != nil {\n\t\t\treturn nil, err\n\t\t}\n\t}\n\n\t// Add the function bindings created via Function() options.\n\tfor _, fn := range e.functions {\n\t\tbindings, err := fn.bindings()\n\t\tif err != nil {\n\t\t\treturn nil, err\n\t\t}\n\t\terr = disp.Add(bindings...)\n\t\tif err != nil {\n\t\t\treturn nil, err\n\t\t}\n\t}\n\n\t// Set the attribute factory after the options have been set.\n\tvar attrFactory interpreter.AttributeFactory\n\tif p.evalOpts&OptPartialEval == OptPartialEval {\n\t\tattrFactory = interpreter.NewPartialAttributeFactory(e.Container, e.adapter, e.provider)\n\t} else {\n\t\tattrFactory = interpreter.NewAttributeFactory(e.Container, e.adapter, e.provider)\n\t}\n\tinterp := interpreter.NewInterpreter(disp, e.Container, e.provider, e.adapter, attrFactory)\n\tp.interpreter = interp\n\n\t// Translate the EvalOption flags into InterpretableDecorator instances.\n\tdecorators := make([]interpreter.InterpretableDecorator, len(p.decorators))\n\tcopy(decorators, p.decorators)\n\n\t// Enable interrupt checking if there's a non-zero check frequency\n\tif p.interruptCheckFrequency > 0 {\n\t\tdecorators = append(decorators, interpreter.InterruptableEval())\n\t}\n\t// Enable constant folding first.\n\tif p.evalOpts&OptOptimize == OptOptimize {\n\t\tdecorators = append(decorators, interpreter.Optimize())\n\t\tp.regexOptimizations = append(p.regexOptimizations, interpreter.MatchesRegexOptimization)\n\t}\n\t// Enable regex compilation of constants immediately after folding constants.\n\tif len(p.regexOptimizations) > 0 {\n\t\tdecorators = append(decorators, interpreter.CompileRegexConstants(p.regexOptimizations...))\n\t}\n\t// Enable compile-time checking of syntax/cardinality for string.format calls.\n\tif p.evalOpts&OptCheckStringFormat == OptCheckStringFormat {\n\t\tvar isValidType func(id int64, validTypes ...*types.TypeValue) (bool, error)\n\t\tif ast.IsChecked() {\n\t\t\tisValidType = func(id int64, validTypes ...*types.TypeValue) (bool, error) {\n\t\t\t\tt, err := ExprTypeToType(ast.typeMap[id])\n\t\t\t\tif err != nil {\n\t\t\t\t\treturn false, err\n\t\t\t\t}\n\t\t\t\tif t.kind == DynKind {\n\t\t\t\t\treturn true, nil\n\t\t\t\t}\n\t\t\t\tfor _, vt := range validTypes {\n\t\t\t\t\tk, err := typeValueToKind(vt)\n\t\t\t\t\tif err != nil {\n\t\t\t\t\t\treturn false, err\n\t\t\t\t\t}\n\t\t\t\t\tif k == t.kind {\n\t\t\t\t\t\treturn true, nil\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\treturn false, nil\n\t\t\t}\n\t\t} else {\n\t\t\t// if the AST isn't type-checked, short-circuit validation\n\t\t\tisValidType = func(id int64, validTypes ...*types.TypeValue) (bool, error) {\n\t\t\t\treturn true, nil\n\t\t\t}\n\t\t}\n\t\tdecorators = append(decorators, interpreter.InterpolateFormattedString(isValidType))\n\t}\n\n\t// Enable exhaustive eval, state tracking and cost tracking last since they require a factory.\n\tif p.evalOpts&(OptExhaustiveEval|OptTrackState|OptTrackCost) != 0 {\n\t\tfactory := func(state interpreter.EvalState, costTracker *interpreter.CostTracker) (Program, error) {\n\t\t\tcostTracker.Estimator = p.callCostEstimator\n\t\t\tcostTracker.Limit = p.costLimit\n\t\t\t// Limit capacity to guarantee a reallocation when calling 'append(decs, ...)' below. This\n\t\t\t// prevents the underlying memory from being shared between factory function calls causing\n\t\t\t// undesired mutations.\n\t\t\tdecs := decorators[:len(decorators):len(decorators)]\n\t\t\tvar observers []interpreter.EvalObserver\n\n\t\t\tif p.evalOpts&(OptExhaustiveEval|OptTrackState) != 0 {\n\t\t\t\t// EvalStateObserver is required for OptExhaustiveEval.\n\t\t\t\tobservers = append(observers, interpreter.EvalStateObserver(state))\n\t\t\t}\n\t\t\tif p.evalOpts&OptTrackCost == OptTrackCost {\n\t\t\t\tobservers = append(observers, interpreter.CostObserver(costTracker))\n\t\t\t}\n\n\t\t\t// Enable exhaustive eval over a basic observer since it offers a superset of features.\n\t\t\tif p.evalOpts&OptExhaustiveEval == OptExhaustiveEval {\n\t\t\t\tdecs = append(decs, interpreter.ExhaustiveEval(), interpreter.Observe(observers...))\n\t\t\t} else if len(observers) > 0 {\n\t\t\t\tdecs = append(decs, interpreter.Observe(observers...))\n\t\t\t}\n\n\t\t\treturn p.clone().initInterpretable(ast, decs)\n\t\t}\n\t\treturn newProgGen(factory)\n\t}\n\treturn p.initInterpretable(ast, decorators)\n}", "func createGoProgram(t *testing.T, dir string) {\n\tfileName := dir + \"/testprogram.go\"\n\tcontents := getGoSourceProgram()\n\terr := ioutil.WriteFile(fileName, []byte(contents), 0644)\n\tif err != nil {\n\t\tt.Fatalf(\"failed to create test file: %s\", err)\n\t}\n}", "func CreateProgram() Program {\n\treturn Program(gl.CreateProgram())\n}", "func New(prj *project.Project) *Application {\n\tcli := &Application{\n\t\tLog: log.NewStdout(log.NOTICE),\n\t\tProject: prj,\n\t\tcommands: make(map[string]Command),\n\t\tflags: make(map[int]flags.Interface),\n\t\tflagAliases: make(map[string]int),\n\t\tosArgs: os.Args[1:],\n\t}\n\t// set initial startup time\n\tcli.started = time.Now()\n\tcli.Log.TsDisabled()\n\tif prj.Config.InitTerm {\n\t\tcli.Log.InitTerm()\n\t}\n\tcli.Log.SetPrimaryColor(prj.Config.Color)\n\tcli.Log.SetLogLevel(prj.Config.LogLevel)\n\tcli.addInternalFlags()\n\tif prj.Config.Color != \"\" {\n\t\tcli.Log.Colors()\n\t}\n\n\t// Set log level to debug and lock the log level, but only if --debug\n\t// flag was found before any command. If --debug flag was found later\n\t// then we want to set debugging later for that command only.\n\tif cli.flag(\"debug\").IsGlobal() && cli.flag(\"debug\").Present() {\n\t\tcli.Log.SetLogLevel(log.DEBUG)\n\t\tcli.Log.LockLevel()\n\t\tcli.flag(\"verbose\").Unset()\n\t}\n\n\t// Only lock log level to verbose if no --debug flag was set\n\tif !cli.flag(\"debug\").Present() && cli.flag(\"verbose\").Present() {\n\t\tcli.Log.SetLogLevel(log.INFO)\n\t\tcli.Log.LockLevel()\n\t}\n\n\tcli.Log.Debugf(\"CLI:Create - accepting configuration changes debugging(%t)\",\n\t\tcli.flag(\"debug\").Present())\n\n\t// Add internal commands besides help\n\tcli.AddCommand(cmdAbout())\n\tcli.rootCmd = NewCommand(prj.Name)\n\tcli.Header.Defaults()\n\tcli.Footer.Defaults()\n\treturn cli\n}", "func New(data []byte, filename string) (*Exec, error) {\n\tlog.Tracef(\"Creating new at %v\", filename)\n\treturn loadExecutable(filename, data)\n}", "func NewProgramEnv() *ProgramEnv {\n\tretval := ProgramEnv{}\n\n\t// all done\n\treturn &retval\n}", "func procProgram(t *testing.T, name string, testCommand string) Program {\n\tpath, procPath := procTestPath(name)\n\terr := util.CopyFile(path, procPath, testLog)\n\trequire.NoError(t, err)\n\terr = os.Chmod(procPath, 0777)\n\trequire.NoError(t, err)\n\t// Temp dir might have symlinks in which case we need the eval'ed path\n\tprocPath, err = filepath.EvalSymlinks(procPath)\n\trequire.NoError(t, err)\n\treturn Program{\n\t\tPath: procPath,\n\t\tArgs: []string{testCommand},\n\t}\n}", "func create(s string) (p program) {\n\tre := regexp.MustCompile(`\\w+`)\n\tt := re.FindAllStringSubmatch(s, -1)\n\tp.name = t[0][0]\n\tp.weight, _ = strconv.Atoi(string(t[1][0]))\n\tfor _, r := range t[2:] {\n\t\tp.children = append(p.children, program{r[0], 0, nil})\n\t}\n\treturn\n}", "func New(descr string) App {\n\treturn &app{descr: descr}\n}", "func CreateProgram() uint32 {\n\tret, _, _ := syscall.Syscall(gpCreateProgram, 0, 0, 0, 0)\n\treturn (uint32)(ret)\n}", "func newApp(desc string) *cli.App {\n\tapp := cli.NewApp()\n\tapp.Name = name\n\tapp.HelpName = filepath.Base(os.Args[0])\n\tapp.Author = author\n\tapp.Version = version\n\tapp.Description = desc\n\tapp.Writer = os.Stdout\n\treturn app\n}", "func New() App {\n\tapp := App{\n\t\tparser: cliparser.New(),\n\n\t\tCliTag: \"cli\",\n\t\tHelpTag: \"help\",\n\t\tUsageTag: \"usage\",\n\t\tDefaultTag: \"default\",\n\t\tDefDescTag: \"defdesc\",\n\t\tEnvTag: \"env\",\n\t\tRequiredTag: \"required\",\n\n\t\tHyphenedCommandName: false,\n\t\tHyphenedOptionName: false,\n\t\tOptionsGrouped: true,\n\t\tAutoNoBoolOptions: true,\n\t\tDoubleHyphen: true,\n\n\t\tStdout: os.Stdout,\n\t\tStderr: os.Stderr,\n\t}\n\n\t//HINT\n\tapp.parser.HintCommand(\"help\")\n\tapp.parser.HintCommand(\"version\")\n\tapp.parser.HintLongName(\"help\")\n\tapp.parser.HintLongName(\"version\")\n\n\tif exe, err := os.Executable(); err == nil {\n\t\tapp.Name = filepath.Base(exe)\n\t}\n\n\treturn app\n}", "func NewExecutable(cli string) Executable {\n\treturn &executable{\n\t\tcli: cli,\n\t}\n}", "func main() {\n\tvar app = cli.NewApp()\n\n\tapp.Name = \"Amity\"\n\tapp.Usage = \"Room allocation app\"\n\tapp.Description = \"A golang application written to help room allocation in amity \"\n\tapp.Version = \"1.0.0\"\n\tapp.Commands = getCommands()\n\n\tapp.Run(os.Args)\n}", "func CreateProgram() uint32 {\n ret := C.glowCreateProgram(gpCreateProgram)\n return (uint32)(ret)\n}", "func main() {\n\tdefer contracts.ShowHelp(help)\n\tnProd, nCons, bufferSize := parseArguments()\n\n\tprogram(nProd, nCons, bufferSize)\n}", "func New(\n\tfactories config.Factories,\n\tappInfo ApplicationStartInfo,\n) (*Application, error) {\n\n\tif err := configcheck.ValidateConfigFromFactories(factories); err != nil {\n\t\treturn nil, err\n\t}\n\n\tapp := &Application{\n\t\tinfo: appInfo,\n\t\tv: viper.New(),\n\t\treadyChan: make(chan struct{}),\n\t\tfactories: factories,\n\t}\n\n\trootCmd := &cobra.Command{\n\t\tUse: appInfo.ExeName,\n\t\tLong: appInfo.LongName,\n\t\tRun: func(cmd *cobra.Command, args []string) {\n\t\t\tapp.init()\n\t\t\tapp.execute()\n\t\t},\n\t}\n\n\t// TODO: coalesce this code and expose this information to other components.\n\tflagSet := new(flag.FlagSet)\n\taddFlagsFns := []func(*flag.FlagSet){\n\t\ttelemetryFlags,\n\t\tbuilder.Flags,\n\t\tloggerFlags,\n\t}\n\tfor _, addFlags := range addFlagsFns {\n\t\taddFlags(flagSet)\n\t}\n\trootCmd.Flags().AddGoFlagSet(flagSet)\n\n\tapp.rootCmd = rootCmd\n\n\treturn app, nil\n}", "func CreateApplication() *Alpha {\n app := &Alpha{}\n app.Request = &Request{}\n app.Response = &Response{}\n app.init()\n return app\n}", "func newProgramCode() programCode {\n\tvar code programCode\n\tcode.intMap = make(map[string]int64)\n\tcode.stringMap = make(map[string]string)\n\tcode.strCounter = 0\n\tcode.funcSlice = make([]string, 100) // TODO: Make this more dynamic e.g.: zero-length slice with dynamic append()\n\tcode.lastLabel = make([]string, 100) // TODO: Make this more dynamic e.g.: zero-length slice with dynamic append()\n\tcode.labelCounter = 0\n\n\tcode.indentLevel = 0\n\tcode.labelFlag = false\n\tcode.forLoopFlag = false\n\tcode.code = \"\"\n\tcode.funcCode = make([]string, 100) // TODO: Make this more dynamic e.g.: zero-length slice with dynamic append()\n\n\treturn code\n}", "func (debugging *debuggingOpenGL) CreateProgram() uint32 {\n\tdebugging.recordEntry(\"CreateProgram\")\n\tresult := debugging.gl.CreateProgram()\n\tdebugging.recordExit(\"CreateProgram\", result)\n\treturn result\n}", "func NewApp(gitCommit, usage string) *cli.App {\r\n\tapp := cli.NewApp()\r\n\tapp.Name = filepath.Base(os.Args[0])\r\n\tapp.Author = \"\"\r\n\t//app.Authors = nil\r\n\tapp.Email = \"\"\r\n\tapp.Version = params.Version\r\n\tif len(gitCommit) >= 8 {\r\n\t\tapp.Version += \"-\" + gitCommit[:8]\r\n\t}\r\n\tapp.Usage = usage\r\n\treturn app\r\n}", "func NewApp() *App {\n\treturn &App{\n\t\tName: filepath.Base(os.Args[0]),\n\t\tUsage: \"A new cli application\",\n\t\tVersion: \"0.0.0\",\n\t\tShowHelp: showHelp,\n\t\tShowVersion: showVersion,\n\t}\n}", "func (gl *WebGL) NewProgram(shaders []WebGLShader) (WebGLShaderProgram, error) {\n\tprogram := gl.CreateProgram()\n\tfor _, shader := range shaders {\n\t\tgl.AttachShader(program, shader)\n\t}\n\n\terr := gl.LinkProgram(program)\n\treturn program, err\n}", "func (p *ProgramData) Create() (err error) {\n\tlogging.Debugf(\"Creating server %s\", p.Id())\n\tp.Environment.DisplayToConsole(\"Allocating server\\n\")\n\terr = p.Environment.Create()\n\tp.Environment.DisplayToConsole(\"Server allocated\\n\")\n\tp.Environment.DisplayToConsole(\"Ready to be installed\\n\")\n\treturn\n}", "func (p *ProgramData) Create() (err error) {\n\tlogging.Debugf(\"Creating server %s\", p.Id())\n\tp.Environment.DisplayToConsole(\"Allocating server\\n\")\n\terr = p.Environment.Create()\n\tp.Environment.DisplayToConsole(\"Server allocated\\n\")\n\tp.Environment.DisplayToConsole(\"Ready to be installed\\n\")\n\treturn\n}", "func (parser *Parser) program() (*Program, error) {\n\tparser.trace(\"PROGRAM\")\n\tdefer parser.untrace()\n\tparser.symbEnvs.PushEnv()\n\tdefer parser.symbEnvs.PopEnv()\n\tfuncs, err := parser.funcsDeclars()\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\tif _, _, found := parser.match(fxsymbols.EOF); !found {\n\t\treturn nil, parser.Errorf(ErrNoEof)\n\t}\n\treturn NewProgram(funcs), nil\n}", "func NewApp(gitCommit, usage string) *cli.App {\n\tapp := cli.NewApp()\n\tapp.Name = filepath.Base(os.Args[0])\n\tapp.Author = \"\"\n\tapp.Email = \"\"\n\tapp.Version = Version\n\tapp.Usage = usage\n\treturn app\n}", "func ConstructProgram(lines []Line) ([]machine.Operation, error) {\n\tconstructor := newConstructor()\n\tfor _, line := range lines {\n\t\tconstructor.processLine(line)\n\t}\n\treturn constructor.operations, constructor.err\n}", "func execNew(_ int, p *gop.Context) {\n\targs := p.GetArgs(3)\n\tret := doc.New(args[0].(*ast.Package), args[1].(string), doc.Mode(args[2].(int)))\n\tp.Ret(3, ret)\n}", "func NewProgramControl()(*ProgramControl) {\n m := &ProgramControl{\n Entity: *NewEntity(),\n }\n return m\n}", "func New() QuizPractice {\n\treturn &quizPractice{\n\t\tArgs: os.Args,\n\t}\n}", "func NewCreateProgramOK() *CreateProgramOK {\n\n\treturn &CreateProgramOK{}\n}", "func main() {\n\tif len(os.Args) == 1 {\n\t\tlog.Fatal(\"There are no arguments!!!\")\n\t}\n\tif os.Args[1] == \"create\" {\n\t\tif len(os.Args[2]) == 0 || len(os.Args[3]) == 0 {\n\t\t\tlog.Fatal(\"Empty path or file name!!!\")\n\t\t}\n\t\tcreateProgram(os.Args[2], os.Args[3])\n\t\treturn\n\t}\n\tif os.Args[1] == \"search\" {\n\t\tif len(os.Args[3:]) == 0 {\n\t\t\treturn\n\t\t}\n\t\tsearchProgram(os.Args[2], os.Args[3:])\n\t\treturn\n\t}\n\n\tif os.Args[1] == \"searchAndBuild\" {\n\t\tif len(os.Args[2]) == 0 || len(os.Args[3]) == 0 || len(os.Args[4:]) == 0 {\n\t\t\tlog.Fatal(\"Empty path, file name or searching string!!!\")\n\t\t}\n\t\tcreateProgram(os.Args[2], os.Args[3])\n\t\tsearchProgram(os.Args[3]+\".txt\", os.Args[4:])\n\t\treturn\n\t}\n}", "func New() App {\n\treturn App{}\n}", "func New(version string, command *command.Cmd) CLI {\n\tapp := app.App{\n\t\tName: path.Base(os.Args[0]),\n\t\tDescription: command.Description,\n\t\tVersionString: version,\n\t\tHasSubCmds: false,\n\t}\n\treturn mkNew(app, command)\n}", "func newCliApp() *cli.App {\n\tapp := cli.NewApp()\n\tapp.Usage = \"A little gopher companion for andOTP\"\n\tapp.Version = gotpher.Version\n\tapp.Commands = commands\n\treturn app\n}", "func New(name string) *Application {\n\tif name == \"\" {\n\t\tpanic(\"can't construct an app without a name\")\n\t}\n\n\treturn &Application{Name: name}\n}", "func (gui *GUI) createProgram() (uint32, error) {\n\tif err := gl.Init(); err != nil {\n\t\treturn 0, fmt.Errorf(\"Failed to initialise OpenGL: %s\", err)\n\t}\n\tgui.logger.Infof(\"OpenGL version %s\", gl.GoStr(gl.GetString(gl.VERSION)))\n\n\tgui.logger.Debugf(\"Compiling shaders...\")\n\n\tvertexShader, err := compileShader(vertexShaderSource, gl.VERTEX_SHADER)\n\tif err != nil {\n\t\treturn 0, err\n\t}\n\n\tfragmentShader, err := compileShader(fragmentShaderSource, gl.FRAGMENT_SHADER)\n\tif err != nil {\n\t\treturn 0, err\n\t}\n\n\tprog := gl.CreateProgram()\n\tgl.AttachShader(prog, vertexShader)\n\tgl.AttachShader(prog, fragmentShader)\n\tgl.LinkProgram(prog)\n\n\treturn prog, nil\n}", "func NewApp(f interface{}, args Arguments, info *debug.Info) App {\n\treturn App{f, args, info}\n}", "func NewApplication(id int32, name string, order int32, type_ string, group ApplicationGroup, workspace ApplicationWorkspace) *Application {\n\tthis := Application{}\n\tthis.Id = id\n\tthis.Name = name\n\tthis.Order = order\n\tthis.Type = type_\n\tthis.Group = group\n\tthis.Workspace = workspace\n\treturn &this\n}", "func newApp(name string) (app *App, err error) {\n\tapp = &App{\n\t\tName: name,\n\t\tID: uuid.NewV5(namespace, \"org.homealone.\"+name).String(),\n\t\thandler: make(map[queue.Topic]message.Handler),\n\t\tdebug: *debug,\n\t\tfilterMessages: true,\n\t}\n\tapp.Log = log.NewLogger().With(log.Fields{\"app\": name, \"id\": app.ID})\n\treturn app, errors.Wrap(err, \"newApp failed\")\n}", "func New(opts ...Option) *App {\n\toptions := options{\n\t\tctx: context.Background(),\n\t\tsigns: []os.Signal{syscall.SIGTERM, syscall.SIGQUIT, syscall.SIGINT},\n\t}\n\n\tif id, err := uuid.NewUUID(); err == nil {\n\t\toptions.id = id.String()\n\t}\n\n\tfor _, o := range opts {\n\t\to(&options)\n\t}\n\tctx, cancel := context.WithCancel(options.ctx)\n\treturn &App{\n\t\tctx: ctx,\n\t\tcancel: cancel,\n\t\topts: options,\n\t}\n}", "func newApp(infile, outfile string) *App {\n\treturn &App{\n\t\tAddressFile: infile,\n\t\tGeoDecodeFile: outfile,\n\t\tClient: &http.Client{},\n\t}\n}", "func NewApp() *App {\n\tv := new(App)\n\tv.opened = false\n\tv.simType = \"runreset\"\n\tv.status = \"Stopped\"\n\tv.mode = \"Main\"\n\tv.incSize = 10.0\n\tv.decSize = 10.0\n\tv.keyMaps = make([]IKeyMap, 10)\n\tv.keyMaps[0] = NewKeyMap0(v)\n\tv.keyMaps[1] = NewKeyMap1(v)\n\n\treturn v\n}", "func (p *Parser)program() {\n\tp.declarations()\n\tp.begin()\n}", "func New(home, line string) Package {\n\tproj := project.New(home, line)\n\tswitch kind(line) {\n\tcase \"binary\":\n\t\treturn binaryPackage{Project: proj}\n\tcase \"path\":\n\t\treturn pathPackage{Project: proj}\n\tcase \"dummy\":\n\t\treturn dummyPackage{Project: proj}\n\tdefault:\n\t\treturn shPkg{Project: proj}\n\t}\n}", "func New(components ...Component) Main {\n\treturn Main{\n\t\tcomponents: components,\n\t\tshutdownDeadline: defaultShutdownDeadline,\n\t}\n}", "func (gl *WebGL) CreateProgram() WebGLShaderProgram {\n\treturn gl.context.Call(\"createProgram\")\n}", "func makeApp(def pchannel.App, data pchannel.Data) perun.App {\n\treturn perun.App{\n\t\tDef: def,\n\t\tData: data,\n\t}\n}", "func NewCompilerFromString(inProgram string) *Compiler {\n\tvar inpProgram []string\n\t// remove all tabs chars\n\tinProgram = strings.Replace(inProgram, \"\\t\", \"\", -1)\n\tinpProgram = strings.Split(inProgram, \"\\n\")\n\t// build the inputProgram array with all instructions and vars right here\n\treturn &Compiler{\n\t\tinputProgram: inpProgram,\n\t\tOutputProgram: initOutputProgram(),\n\t}\n}", "func CreateProgram(vertexSource string, fragmentSource string) (gl.Uint, error) {\n\t// Vertex shader\n\tvs := gl.CreateShader(gl.VERTEX_SHADER)\n\tvsSource := gl.GLStringArray(vertexSource)\n\tdefer gl.GLStringArrayFree(vsSource)\n\tgl.ShaderSource(vs, 1, &vsSource[0], nil)\n\n\tgl.CompileShader(vs)\n\n\tstatus, err := compileStatus(vs)\n\tif err != nil {\n\t\treturn status, err\n\t}\n\n\t// Fragment shader\n\tfs := gl.CreateShader(gl.FRAGMENT_SHADER)\n\tfsSource := gl.GLStringArray(fragmentSource)\n\tdefer gl.GLStringArrayFree(fsSource)\n\tgl.ShaderSource(fs, 1, &fsSource[0], nil)\n\tgl.CompileShader(fs)\n\n\tstatus, err = compileStatus(fs)\n\tif err != nil {\n\t\treturn status, err\n\t}\n\n\t// create program\n\tprogram := gl.CreateProgram()\n\tgl.AttachShader(program, vs)\n\tgl.AttachShader(program, fs)\n\n\tgl.LinkProgram(program)\n\tvar linkstatus gl.Int\n\tgl.GetProgramiv(program, gl.LINK_STATUS, &linkstatus)\n\tif linkstatus == gl.FALSE {\n\t\treturn gl.FALSE, errors.New(\"Program link failed\")\n\t}\n\n\treturn program, nil\n}", "func NewApplication()(*Application) {\n m := &Application{\n DirectoryObject: *NewDirectoryObject(),\n }\n odataTypeValue := \"#microsoft.graph.application\";\n m.SetOdataType(&odataTypeValue);\n return m\n}", "func serializeProgram(prgrm *CXProgram, s *SerializedCXProgram) {\n\ts.Program = serializedProgram{}\n\tsPrgrm := &s.Program\n\tsPrgrm.PackagesOffset = int64(0)\n\tsPrgrm.PackagesSize = int64(len(prgrm.Packages))\n\n\tif pkgOff, found := s.PackagesMap[prgrm.CurrentPackage.Name]; found {\n\t\tsPrgrm.CurrentPackageOffset = int64(pkgOff)\n\t} else {\n\t\tpanic(\"package reference not found\")\n\t}\n\n\tsPrgrm.InputsOffset, sPrgrm.InputsSize = serializeSliceOfArguments(prgrm.ProgramInput, s)\n\tsPrgrm.OutputsOffset, sPrgrm.OutputsSize = serializeSliceOfArguments(prgrm.ProgramOutput, s)\n\n\tsPrgrm.CallStackOffset, sPrgrm.CallStackSize = serializeCalls(prgrm.CallStack[:prgrm.CallCounter], s)\n\n\tsPrgrm.CallCounter = int64(prgrm.CallCounter)\n\n\tsPrgrm.MemoryOffset = int64(0)\n\tsPrgrm.MemorySize = int64(len(PROGRAM.Memory))\n\n\tsPrgrm.HeapPointer = int64(prgrm.HeapPointer)\n\tsPrgrm.StackPointer = int64(prgrm.StackPointer)\n\tsPrgrm.StackSize = int64(prgrm.StackSize)\n\tsPrgrm.DataSegmentSize = int64(prgrm.DataSegmentSize)\n\tsPrgrm.DataSegmentStartsAt = int64(prgrm.DataSegmentStartsAt)\n\tsPrgrm.HeapSize = int64(prgrm.HeapSize)\n\tsPrgrm.HeapStartsAt = int64(prgrm.HeapStartsAt)\n\n\tsPrgrm.Terminated = serializeBoolean(prgrm.Terminated)\n\tsPrgrm.VersionOffset, sPrgrm.VersionSize = serializeString(prgrm.Version, s)\n}", "func New(pattern io.Reader) (*App, error) {\n\tbs, err := ioutil.ReadAll(pattern)\n\tif err != nil {\n\t\treturn nil, errors.Wrap(err, \"template read\")\n\t}\n\tfuncMap := template.FuncMap{\n\t\t\"add\": func(a, b int) int { return a + b },\n\t\t\"sub\": func(a, b int) int { return a - b },\n\t\t\"mul\": func(a, b int) int { return a * b },\n\t\t\"div\": func(a, b int) int { return a / b },\n\t}\n\tt, err := template.New(\"yaml2text\").Funcs(funcMap).Parse(string(bs))\n\tif err != nil {\n\t\treturn nil, errors.Wrap(err, \"template parse\")\n\t}\n\n\tapp := &App{\n\t\tt: t,\n\t}\n\treturn app, nil\n}", "func NewRuntime(conf Config) (r *Runtime, e error) {\n\tr = &Runtime{}\n\tr.ctx, r.cancel = context.WithCancel(context.Background())\n\tr.cmd = exec.CommandContext(r.ctx, runtimeExePath)\n\n\t// set env\n\t{\n\t\tenv := os.Environ()\n\t\tenv = append(env,\n\t\t\tapi.AgentHostEnvKey+\"=\"+conf.AgentHost,\n\t\t\tapi.AgentPortEnvKey+\"=\"+strconv.Itoa(int(conf.AgentPort)),\n\t\t)\n\t\tr.cmd.Env = env\n\t}\n\n\treturn\n}", "func NewMain() *Main {\n\tm := &Main{\n\t\tnexter: pdk.NewNexter(),\n\t\ttotalRecs: &Counter{},\n\t}\n\treturn m\n}", "func New(b []byte) *LazyExe {\n\tle := &LazyExe{\n\t\tbytes: b,\n\t}\n\treturn le\n}", "func (native *OpenGL) CreateProgram() uint32 {\n\treturn gl.CreateProgram()\n}", "func New(appName, version string) *App {\n\treturn createApp(appName, version)\n}", "func execNew(_ int, p *gop.Context) {\n\targs := p.GetArgs(1)\n\tret := errors.New(args[0].(string))\n\tp.Ret(1, ret)\n}", "func App(name, desc string) *Cli {\n\treturn &Cli{\n\t\t&Cmd{\n\t\t\tname: name,\n\t\t\tdesc: desc,\n\t\t\toptionsIdx: map[string]*opt{},\n\t\t\targsIdx: map[string]*arg{},\n\t\t\tErrorHandling: flag.ExitOnError,\n\t\t},\n\t}\n}", "func NewMain() *Main {\n\tpath, err := ioutil.TempDir(\"\", \"pilosa-\")\n\tif err != nil {\n\t\tpanic(err)\n\t}\n\n\tm := &Main{Command: server.NewCommand(os.Stdin, os.Stdout, os.Stderr)}\n\tm.Config.DataDir = path\n\tm.Config.Host = \"localhost:0\"\n\tm.Command.Stdin = &m.Stdin\n\tm.Command.Stdout = &m.Stdout\n\tm.Command.Stderr = &m.Stderr\n\n\tif testing.Verbose() {\n\t\tm.Command.Stdout = io.MultiWriter(os.Stdout, m.Command.Stdout)\n\t\tm.Command.Stderr = io.MultiWriter(os.Stderr, m.Command.Stderr)\n\t}\n\n\treturn m\n}", "func CreateCli(version string) *cli.App {\n\tapp := cli.NewApp()\n\n\tapp.CustomAppHelpTemplate = ` NAME:\n {{.Name}} - {{.Usage}}\n\n USAGE:\n {{.HelpName}} {{if .Flags}}[options]{{end}}\n {{if .Commands}}\n OPTIONS:\n {{range .Flags}}{{.}}\n {{end}}{{end}}{{if .Copyright }}\n COPYRIGHT:\n {{.Copyright}}\n {{end}}{{if .Version}}\n VERSION:\n {{.Version}}\n {{end}}{{if len .Authors}}\n AUTHOR(S):\n {{range .Authors}}{{ . }}{{end}}\n\t{{end}}\n`\n\n\tapp.Name = \"health-checker\"\n\tapp.HelpName = app.Name\n\tapp.Author = \"Gruntwork, Inc. <www.gruntwork.io> | https://github.com/gruntwork-io/health-checker\"\n\tapp.Version = version\n\tapp.Usage = \"A simple HTTP server that will return 200 OK if the configured checks are all successful.\"\n\tapp.Commands = nil\n\tapp.Flags = defaultFlags\n\tapp.Action = runHealthChecker\n\n\treturn app\n}", "func New() *Cli {\n\t// init long arguments\n\tvar (\n\t\tinput = flag.String(\"input\", \"./\", \"Input path\")\n\t\toutput = flag.String(\"output\", \"\", \"Output path\")\n\t\ttemplate = flag.String(\"template\", string(entity.JSON), \"Input path\")\n\t\ttypes = flag.String(\"type\", \"query,mutation\", \"Input path\")\n\t\tquiet = flag.Bool(\"quiet\", false, \"Input path\")\n\t\thelp = flag.Bool(\"help\", false, \"Input path\")\n\t\tnoExample = flag.Bool(\"no-example\", false, \"do not generate query example\")\n\t)\n\n\t// init shorthand arguments\n\tflag.StringVar(input, \"i\", \"./\", \"Input path (shorthand)\")\n\tflag.StringVar(output, \"o\", \"\", \"Output path (shorthand)\")\n\tflag.BoolVar(quiet, \"q\", false, \"\")\n\tflag.BoolVar(help, \"h\", false, \"\")\n\n\treturn &Cli{\n\t\tinput: input,\n\t\toutput: output,\n\t\ttemplate: template,\n\t\ttypes: types,\n\t\tquiet: quiet,\n\t\thelp: help,\n\t\tnoExample: noExample,\n\t}\n}", "func New(cmd *cobra.Command, args []string) {\n\t// Create object for current working directory\n\tpwd, err := teflon.NewTeflonObject(\".\")\n\tif err != nil {\n\t\tlog.Fatalln(\"Couldn't create object for '.' :\", err)\n\t}\n\n\t// Create a show.\n\tif showFlag {\n\t\tnshws, err := pwd.CreateShow(args[0], newShowProtoFlag)\n\t\tif err != nil {\n\t\t\tlog.Fatalln(\"ABORT: Couldnt create show:\", err)\n\t\t}\n\t\tfor _, shw := range nshws {\n\t\t\tfmt.Println(shw.Path)\n\t\t}\n\t\treturn\n\t}\n\n\t// If nothing else commands otherwise new will create an ordinary file-system\n\t// object.\n\tnobjs, err := pwd.CreateObject(args[0], newFileFlag)\n\tif err != nil {\n\t\tlog.Fatalln(\"ABORT: Couldn't create objects:\", err)\n\t}\n\tclose(teflon.Events)\n\tfor _, obj := range nobjs {\n\t\tfmt.Println(obj.Path)\n\t}\n}", "func main() {\n\t// define commands for execution\n\tinFile := flag.String(\"source\", \"\", \"source\")\n\toutFile := flag.String(\"target\", \"\", \"target\")\n\tpkg := flag.String(\"package\", \"main\", \"package name\")\n\tname := flag.String(\"name\", \"File\", \"identifier to use for the embedded data\")\n\tflag.Parse()\n\terr := genConf(*inFile, *outFile, *pkg, *name)\n\thandleError(err)\n}", "func New(options ...Option) Application {\n\topts := &Options{}\n\tfor _, opt := range options {\n\t\topt(opts)\n\t}\n\n\tif opts.StartupTimeout == 0 {\n\t\topts.StartupTimeout = 1000\n\t}\n\tif opts.ShutdownTimeout == 0 {\n\t\topts.ShutdownTimeout = 5000\n\t}\n\n\tif opts.AutoMaxProcs == nil || *opts.AutoMaxProcs {\n\t\tprocsutil.EnableAutoMaxProcs()\n\t}\n\n\tconfig.AppendServiceTag(opts.Tags...)\n\n\tapp := &application{\n\t\tquit: make(chan os.Signal),\n\t\tstartupTimeout: opts.StartupTimeout,\n\t\tshutdownTimeout: opts.ShutdownTimeout,\n\t\tboxes: append(opts.Boxes, &boxMetric{}),\n\t}\n\n\tsignal.Notify(app.quit, syscall.SIGINT, syscall.SIGTERM)\n\n\treturn app\n}", "func NewApp(name string) (*App, error) {\n\tvar (\n\t\tconfig Config\n\t\tflagset = flag.NewFlagSet(name, flagErrorHandling)\n\t)\n\tif err := flagset.Parse(os.Args[1:]); err != nil {\n\t\tif err == flag.ErrHelp {\n\t\t\treturn &App{pass: true}, nil\n\t\t}\n\t\treturn nil, errors.Wrap(err, \"parsing flags\")\n\t}\n\treturn NewAppFrom(name, config)\n}", "func New() *cli.App {\n\tapp := cli.NewApp()\n\tapp.ErrWriter = cli.ErrWriter\n\tapp.Name = \"thracia\"\n\tapp.Usage = \"Make fonts with SFMono + others\"\n\tapp.Version = version\n\tapp.Flags = flags()\n\tapp.Action = action\n\treturn app\n}", "func NewApp(database string) *Application {\n\tfolder := filepath.Dir(os.Args[0]) /* go 1.7.5 */\n\tconn, err := sql.Open(\"sqlite3\", folder+\"/\"+database)\n\n\tif err != nil {\n\t\tlog.Fatal(\"SQLite open; \", err)\n\t\treturn &Application{}\n\t}\n\n\tlog.Println(\"Database:\", folder+\"/\"+database)\n\n\tquery := `\n\tCREATE TABLE IF NOT EXISTS reviews (\n\t\tid INTEGER PRIMARY KEY,\n\t\tuid TEXT,\n\t\tname TEXT,\n\t\temail TEXT,\n\t\trating INTEGER,\n\t\tcomment TEXT,\n\t\tapproved INTEGER,\n\t\ttimestamp TIMESTAMP\n\t);\n\t`\n\n\tif _, err := conn.Exec(query); err != nil {\n\t\tlog.Fatal(\"Database setup; \", err)\n\t\treturn &Application{}\n\t}\n\n\treturn &Application{db: conn}\n}", "func main() {\n cli := CLI{}\n cli.Run()\n}", "func NewApp(useMBTS, useSpecialEBmods bool) *App {\n\tapp := &App{\n\t\tworkers: []Worker{},\n\t\tdetector: nil,\n\t}\n\tapp.msg(\"Welcome to Go-TUCS (pid=%d). Building detector tree...\\n\", os.Getpid())\n\tapp.detector = TileCal(useMBTS, useSpecialEBmods)\n\tapp.msg(\"done.\\n\")\n\treturn app\n}", "func main() {\n\tmodule.Create(\"init\", 0)\n\tmodule.Log()\n\tReadLine(\"D:/input.txt\", processLine)\n\tmodule.Show_pcb(\"r\")\n\tfmt.Println()\n\tmodule.List_all_process()\n\tfmt.Println()\n\tmodule.List_all_resource()\n}", "func New() *App {\n\treturn NewApp(newDefaultApp())\n}", "func CreateProgram() Uint {\n\t__ret := C.glCreateProgram()\n\t__v := (Uint)(__ret)\n\treturn __v\n}", "func NewProgramChangeEvent(deltaTime *deltatime.DeltaTime, channel uint8, program constant.GM) (*ProgramChangeEvent, error) {\n\tvar err error\n\n\tevent := &ProgramChangeEvent{}\n\tevent.deltaTime = deltaTime\n\n\terr = event.SetChannel(channel)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\terr = event.SetProgram(program)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\treturn event, nil\n}", "func newManifestApp() *types.App {\n\treturn &types.App{\n\t\tUser: \"0\",\n\t\tGroup: \"0\",\n\t}\n}", "func newManifestApp() *types.App {\n\treturn &types.App{\n\t\tUser: \"0\",\n\t\tGroup: \"0\",\n\t}\n}", "func CreateProgramPipelines(n int32, pipelines *uint32) {\n\tsyscall.Syscall(gpCreateProgramPipelines, 2, uintptr(n), uintptr(unsafe.Pointer(pipelines)), 0)\n}", "func New() *App {\n\treturn &App{}\n}", "func New(c Config) *App {\n\treturn &App{\n\t\tName: c.Name,\n\t}\n}", "func New(logger log.Logger) Main {\n\t// Init flags.\n\tflgs := &utils.CMDFlags{}\n\tflgs.Init()\n\n\treturn Main{\n\t\tlogger: logger,\n\t\tflags: flgs,\n\t}\n}", "func (c Chain) Program() (Program, error) {\n\t// Sanity checks.\n\tif len(c) == 0 {\n\t\treturn nil, errors.New(\"chain empty\")\n\t}\n\n\tif c[0].Cmp(big.NewInt(1)) != 0 {\n\t\treturn nil, errors.New(\"chain must start with 1\")\n\t}\n\n\tif bigints.Contains(bigint.Zero(), c) {\n\t\treturn nil, errors.New(\"chain contains zero\")\n\t}\n\n\tfor i := 0; i < len(c); i++ {\n\t\tfor j := i + 1; j < len(c); j++ {\n\t\t\tif bigint.Equal(c[i], c[j]) {\n\t\t\t\treturn nil, fmt.Errorf(\"chain contains duplicate: %v at positions %d and %d\", c[i], i, j)\n\t\t\t}\n\t\t}\n\t}\n\n\t// Produce the program.\n\tp := Program{}\n\tfor k := 1; k < len(c); k++ {\n\t\top, err := c.Op(k)\n\t\tif err != nil {\n\t\t\treturn nil, err\n\t\t}\n\t\tp = append(p, op)\n\t}\n\n\treturn p, nil\n}", "func Create (appName string) {\n\n checkGopath ()\n checkContainer (appName)\n\n app := Application { Name: appName }\n\n app.createContainer ()\n\n err := app.copyFileTree (\n GOPATH + slash + applicationTemplatesPath,\n GOPATH_SRC + app.Name,\n )\n\n if err != nil {\n log.Fatal (err)\n }\n}", "func New(id string, runtime *runsc.Runsc, stdio stdio.Stdio) *Init {\n\tp := &Init{\n\t\tid: id,\n\t\truntime: runtime,\n\t\tstdio: stdio,\n\t\tstatus: 0,\n\t\twaitBlock: make(chan struct{}),\n\t}\n\tp.initState = &createdState{p: p}\n\treturn p\n}" ]
[ "0.754594", "0.74776906", "0.737721", "0.7287907", "0.7166263", "0.6921965", "0.6902829", "0.67759985", "0.6758172", "0.6675605", "0.663532", "0.6624037", "0.65911716", "0.65763915", "0.65724933", "0.655264", "0.6488179", "0.62225133", "0.6178267", "0.61091566", "0.6095275", "0.60630673", "0.60184586", "0.5984617", "0.59573644", "0.59303766", "0.59261423", "0.59247285", "0.59227794", "0.5915168", "0.59051514", "0.5888806", "0.58844984", "0.583958", "0.5793162", "0.5785513", "0.5769177", "0.5736552", "0.5736552", "0.572916", "0.5712179", "0.57074577", "0.5705663", "0.57055223", "0.5636294", "0.5615873", "0.56013", "0.55979896", "0.55919844", "0.55905235", "0.5568636", "0.5566715", "0.5552853", "0.55508494", "0.5500687", "0.54963946", "0.54809487", "0.5469181", "0.5468393", "0.5463602", "0.5460933", "0.5459929", "0.54395694", "0.54350245", "0.5430189", "0.5428041", "0.538131", "0.53726405", "0.5367005", "0.5361321", "0.5355961", "0.53412694", "0.53375244", "0.53363836", "0.5328176", "0.5315538", "0.5315106", "0.5313426", "0.5311843", "0.5309679", "0.53096247", "0.530432", "0.52993035", "0.52978045", "0.52671456", "0.5265338", "0.52632076", "0.52556914", "0.5254023", "0.52535385", "0.524939", "0.524939", "0.5244842", "0.5234315", "0.52321804", "0.52280045", "0.5227016", "0.52257323", "0.5218529" ]
0.5645864
45
create program pipeline objects
func CreateProgramPipelines(n int32, pipelines *uint32) { C.glowCreateProgramPipelines(gpCreateProgramPipelines, (C.GLsizei)(n), (*C.GLuint)(unsafe.Pointer(pipelines))) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func New(stdin io.Reader, stdout io.Writer, stderr io.Writer) *Pipeline {\n pl := &Pipeline{}\n pl.input = stdin\n pl.output = stdout\n pl.err = stderr\n pl.tasks = []*exec.Cmd{}\n return pl\n}", "func createPipeline(\n\tconfig Config, mgr types.Manager, logger log.Modular, stats metrics.Type,\n) (*util.ClosablePool, error) {\n\tpool := util.NewClosablePool()\n\n\t// Create our input pipe\n\tinputPipe, err := input.New(config.Input, mgr, logger, stats)\n\tif err != nil {\n\t\tlogger.Errorf(\"Input error (%s): %v\\n\", config.Input.Type, err)\n\t\treturn nil, err\n\t}\n\tpool.Add(1, inputPipe)\n\n\t// Create our benchmarking output pipe\n\toutputPipe := test.NewBenchOutput(\n\t\ttime.Duration(config.ReportPeriodMS)*time.Millisecond, logger, stats,\n\t)\n\tpool.Add(10, outputPipe)\n\n\toutputPipe.StartReceiving(inputPipe.TransactionChan())\n\treturn pool, nil\n}", "func NewPipeline(ls ...interface{}) (*Pipe, error) {\n\tvar pipe []interface{}\n\n\tp := &Pipe{\n\t\tls: pipe,\n\t}\n\n\tfor _, f := range ls {\n\t\tif err := p.Add(f); err != nil {\n\t\t\treturn nil, err\n\t\t}\n\t}\n\n\treturn p, nil\n}", "func newBuildPipeline(t gaia.PipelineType) BuildPipeline {\n\tvar bP BuildPipeline\n\n\t// Create build pipeline for given pipeline type\n\tswitch t {\n\tcase gaia.PTypeGolang:\n\t\tbP = &BuildPipelineGolang{\n\t\t\tType: t,\n\t\t}\n\tcase gaia.PTypeJava:\n\t\tbP = &BuildPipelineJava{\n\t\t\tType: t,\n\t\t}\n\tcase gaia.PTypePython:\n\t\tbP = &BuildPipelinePython{\n\t\t\tType: t,\n\t\t}\n\tcase gaia.PTypeCpp:\n\t\tbP = &BuildPipelineCpp{\n\t\t\tType: t,\n\t\t}\n\tcase gaia.PTypeRuby:\n\t\tbP = &BuildPipelineRuby{\n\t\t\tType: t,\n\t\t}\n\tcase gaia.PTypeNodeJS:\n\t\tbP = &BuildPipelineNodeJS{\n\t\t\tType: t,\n\t\t}\n\t}\n\n\treturn bP\n}", "func CreateProgramPipelines(n int32, pipelines *uint32) {\n\tsyscall.Syscall(gpCreateProgramPipelines, 2, uintptr(n), uintptr(unsafe.Pointer(pipelines)), 0)\n}", "func createProgram(packages ...string) (*loader.Program, error) {\n\tvar conf loader.Config\n\n\tfor _, name := range packages {\n\t\tconf.CreateFromFilenames(name, getFileNames(name)...)\n\t}\n\treturn conf.Load()\n}", "func CreatePipeline(dsl Pipeline) pipeline.GroovePipeline {\n\t// Register the sources used in the groove pipeline.\n\tRegisterSources()\n\n\t// Create a groove pipeline from the boogie dsl.\n\tg := pipeline.GroovePipeline{}\n\tif s, ok := querySourceMapping[dsl.Query.Format]; ok {\n\t\tg.QueriesSource = s\n\t} else {\n\t\tlog.Fatalf(\"%v is not a known query source\", dsl.Query.Format)\n\t}\n\n\tif len(dsl.Statistic.Source) > 0 {\n\t\tif s, ok := statisticSourceMapping[dsl.Statistic.Source]; ok {\n\t\t\tg.StatisticsSource = s\n\t\t} else {\n\t\t\tlog.Fatalf(\"%v is not a known statistics source\", dsl.Statistic.Source)\n\t\t}\n\t}\n\n\tif len(dsl.Statistic.Source) == 0 && len(dsl.Measurements) > 0 {\n\t\tlog.Fatal(\"A statistic source is required for measurements\")\n\t}\n\n\tif len(dsl.Measurements) > 0 && len(dsl.Output.Measurements) == 0 {\n\t\tlog.Fatal(\"At least one output format must be supplied when using analysis measurements\")\n\t}\n\n\tif len(dsl.Output.Measurements) > 0 && len(dsl.Measurements) == 0 {\n\t\tlog.Fatal(\"At least one analysis measurement must be supplied for the output formats\")\n\t}\n\n\tif len(dsl.Evaluations) > 0 && len(dsl.Output.Evaluations.Measurements) == 0 {\n\t\tlog.Fatal(\"At least one output format must be supplied when using evaluation measurements\")\n\t}\n\n\tif len(dsl.Output.Evaluations.Measurements) > 0 && len(dsl.Evaluations) == 0 {\n\t\tlog.Fatal(\"At least one evaluation measurement must be supplied for the output formats\")\n\t}\n\n\tg.Measurements = []analysis.Measurement{}\n\tfor _, measurementName := range dsl.Measurements {\n\t\tif m, ok := measurementMapping[measurementName]; ok {\n\t\t\tg.Measurements = append(g.Measurements, m)\n\t\t} else {\n\t\t\tlog.Fatalf(\"%v is not a known measurement\", measurementName)\n\t\t}\n\t}\n\n\tg.Evaluations = []eval.Evaluator{}\n\tfor _, evaluationMeasurement := range dsl.Evaluations {\n\t\tif m, ok := evaluationMapping[evaluationMeasurement.Evaluation]; ok {\n\t\t\tg.Evaluations = append(g.Evaluations, m)\n\t\t} else {\n\t\t\tlog.Fatalf(\"%v is not a known evaluation measurement\", evaluationMeasurement.Evaluation)\n\t\t}\n\t}\n\n\tif len(dsl.Output.Evaluations.Qrels) > 0 {\n\t\tb, err := ioutil.ReadFile(dsl.Output.Evaluations.Qrels)\n\t\tif err != nil {\n\t\t\tlog.Fatalln(err)\n\t\t}\n\t\tqrels, err := trecresults.QrelsFromReader(bytes.NewReader(b))\n\t\tif err != nil {\n\t\t\tlog.Fatalln(err)\n\t\t}\n\t\tg.EvaluationQrels = qrels\n\t}\n\n\tg.MeasurementFormatters = []output.MeasurementFormatter{}\n\tfor _, formatter := range dsl.Output.Measurements {\n\t\tif o, ok := measurementFormatters[formatter.Format]; ok {\n\t\t\tg.MeasurementFormatters = append(g.MeasurementFormatters, o)\n\t\t} else {\n\t\t\tlog.Fatalf(\"%v is not a known measurement output format\", formatter.Format)\n\t\t}\n\t}\n\n\tg.EvaluationFormatters = []output.EvaluationFormatter{}\n\tfor _, formatter := range dsl.Output.Evaluations.Measurements {\n\t\tif o, ok := evaluationFormatters[formatter.Format]; ok {\n\t\t\tg.EvaluationFormatters = append(g.EvaluationFormatters, o)\n\t\t} else {\n\t\t\tlog.Fatalf(\"%v is not a known evaluation output format\", formatter.Format)\n\t\t}\n\t}\n\n\tg.Preprocess = []preprocess.QueryProcessor{}\n\tfor _, p := range dsl.Preprocess {\n\t\tif processor, ok := preprocessorMapping[p]; ok {\n\t\t\tg.Preprocess = append(g.Preprocess, processor)\n\t\t} else {\n\t\t\tlog.Fatalf(\"%v is not a known preprocessor\", p)\n\t\t}\n\t}\n\n\tg.Transformations = preprocess.QueryTransformations{}\n\tfor _, t := range dsl.Transformations.Operations {\n\t\tif transformation, ok := transformationMappingBoolean[t]; ok {\n\t\t\tg.Transformations.BooleanTransformations = append(g.Transformations.BooleanTransformations, transformation)\n\t\t} else if transformation, ok := transformationMappingElasticsearch[t]; ok {\n\t\t\tg.Transformations.ElasticsearchTransformations = append(g.Transformations.ElasticsearchTransformations, transformation)\n\t\t} else {\n\t\t\tlog.Fatalf(\"%v is not a known preprocessing transformation\", t)\n\t\t}\n\t}\n\n\t//g.QueryChain\n\tif len(dsl.Rewrite.Chain) > 0 && len(dsl.Rewrite.Transformations) > 0 {\n\t\tvar transformations []rewrite.Transformation\n\t\tfor _, transformation := range dsl.Rewrite.Transformations {\n\t\t\tif t, ok := rewriteTransformationMapping[transformation]; ok {\n\t\t\t\ttransformations = append(transformations, t)\n\t\t\t} else {\n\t\t\t\tlog.Fatalf(\"%v is not a known rewrite transformation\", transformation)\n\t\t\t}\n\t\t}\n\n\t\tif qc, ok := queryChainCandidateSelectorMapping[dsl.Rewrite.Chain]; ok {\n\t\t\tg.QueryChain = rewrite.NewQueryChain(qc, transformations...)\n\t\t} else {\n\t\t\tlog.Fatalf(\"%v is not a known query chain candidate selector\", dsl.Rewrite.Chain)\n\t\t}\n\n\t}\n\n\tg.Transformations.Output = dsl.Transformations.Output\n\tg.OutputTrec.Path = dsl.Output.Trec.Output\n\treturn g\n}", "func createPipeline(params CRDCreationParameters) (*syntax.ParsedPipeline, error) {\n\tsteps, err := buildSteps(params)\n\tif err != nil {\n\t\treturn nil, errors.Wrap(err, \"unable to create app extending pipeline steps\")\n\t}\n\n\tstage := syntax.Stage{\n\t\tName: appExtensionStageName,\n\t\tSteps: steps,\n\t\tAgent: &syntax.Agent{\n\t\t\tImage: determineDefaultStepImage(params.DefaultImage),\n\t\t},\n\t}\n\n\tparsedPipeline := &syntax.ParsedPipeline{\n\t\tStages: []syntax.Stage{stage},\n\t}\n\n\tenv := buildEnvParams(params)\n\tparsedPipeline.AddContainerEnvVarsToPipeline(env)\n\n\treturn parsedPipeline, nil\n}", "func NewPipeline(factories []component.Factory) *Pipeline {\n\tpipeline := &Pipeline{}\n\n\tfor i, factory := range factories {\n\t\tpool := pool{\n\t\t\tfactory: factory,\n\t\t\tterminate: make(chan struct{}),\n\t\t\tdone: &sync.WaitGroup{},\n\t\t\tworkers: make(chan component.Component, factory.PoolSize()),\n\t\t}\n\n\t\tpool.produce = make(chan component.Message, factory.ChannelSize())\n\t\tpool.output = make(chan component.Message, factory.ChannelSize())\n\t\tif i > 0 {\n\t\t\tpool.input = pipeline.pools[i-1].output\n\t\t}\n\n\t\tfor j := 0; j < factory.PoolSize(); j++ {\n\t\t\tspawnWorker(factory, pool)\n\t\t}\n\n\t\tpipeline.pools = append(pipeline.pools, &pool)\n\t}\n\n\tgo func() {\n\t\tfor msg := range pipeline.pools[len(factories)-1].output {\n\t\t\tmsg.Release()\n\t\t}\n\t}()\n\n\treturn pipeline\n}", "func Pipeline(g *graph.Graph, id string, factory *Factory, top Values) executor.Pipeline {\n\tp := pipelineGen{Graph: g, RenderingPlant: factory, Top: top, ID: id}\n\treturn executor.NewPipeline().\n\t\tAndThen(p.maybeTransformRoot).\n\t\tAndThen(p.prepareNode).\n\t\tAndThen(p.wrapTask)\n}", "func GenProgramPipelines(n int32, pipelines *uint32) {\n\tsyscall.Syscall(gpGenProgramPipelines, 2, uintptr(n), uintptr(unsafe.Pointer(pipelines)), 0)\n}", "func NewPipeline(ops []OpUnion) Pipeline {\n\treturn Pipeline{Operations: ops}\n}", "func ConstructProgram(lines []Line) ([]machine.Operation, error) {\n\tconstructor := newConstructor()\n\tfor _, line := range lines {\n\t\tconstructor.processLine(line)\n\t}\n\treturn constructor.operations, constructor.err\n}", "func NewPipeline(stages ...Stage) *Pipeline {\n\treturn &Pipeline{stages: stages}\n}", "func NewPipeline() *Pipeline {\n\treturn &Pipeline{\n\t\tSerializablePipeline: NewSerializablePipeline(),\n\t}\n}", "func NewPipeline(definitionPath, environmentPath string, environment types.StringMap, ignoredSteps types.StringSet, selectedSteps types.StringSet) (*Pipeline, error) {\n\tp := &Pipeline{}\n\tvar err error\n\t// Load environment\n\tp.Environment, err = NewPipelineEnvironment(environmentPath, environment, ignoredSteps, selectedSteps)\n\tif err != nil {\n\t\t// As environment files are optional, handle if non is accessible\n\t\tif e, ok := err.(*os.PathError); ok && e.Err == syscall.ENOENT {\n\t\t\tlog.Print(\"No environment file is used\")\n\t\t} else {\n\t\t\treturn nil, err\n\t\t}\n\t}\n\t// Load definition\n\tp.Definition, err = NewPipelineDefinition(definitionPath, p.Environment)\n\tp.localRunner = NewLocalRunner(\"pipeline\", os.Stdout, os.Stderr)\n\tp.noopRunner = NewNoopRunner(false)\n\treturn p, err\n}", "func CreatePipeline(codecName string, tracks []*webrtc.Track) *Pipeline {\n\tfmt.Printf(\"In create pipeline\")\n\tpipelineStr := \"\"\n\tswitch codecName {\n\tcase \"VP8\":\n\t\tpipelineStr += \", encoding-name=VP8-DRAFT-IETF-01 ! rtpvp8depay ! decodebin ! autovideosink\"\n\tcase \"Opus\":\n\t\tpipelineStr += \"appsrc name=src ! decodebin ! audioconvert ! audioresample ! audio/x-raw, rate=8000 ! mulawenc ! appsink name=appsink max-buffers=1\"\n\t// case webrtc.VP9:\n\t// \tpipelineStr += \" ! rtpvp9depay ! decodebin ! autovideosink\"\n\t// case webrtc.H264:\n\t// \tpipelineStr += \" ! rtph264depay ! decodebin ! autovideosink\"\n\t// case webrtc.G722:\n\t// \tpipelineStr += \" clock-rate=8000 ! rtpg722depay ! decodebin ! autoaudiosink\"\n\tdefault:\n\t\tpanic(\"Unhandled codec \" + codecName)\n\t}\n\n\tpipelineStrUnsafe := C.CString(pipelineStr)\n\tdefer C.free(unsafe.Pointer(pipelineStrUnsafe))\n\treturn &Pipeline{\n\t\tPipeline: C.gstreamer_receive_create_pipeline(pipelineStrUnsafe),\n\t\ttracks: tracks,\n\t}\n}", "func (p *Parser) parsePipeline() (*AstPipeline, error) {\n var firstPr *AstProcess = nil\n var currPr *AstProcess = nil\n\n for p.Scanner.Token != scanner.EOF {\n pr, err := p.parseProcess()\n if err != nil {\n return nil, err\n }\n\n if firstPr == nil {\n firstPr = pr\n }\n if currPr != nil {\n currPr.Next = pr\n }\n currPr = pr\n\n // If the next token is not '|' then break\n if (p.Scanner.Token != '|') {\n break\n } else {\n p.Scanner.Scan()\n }\n }\n\n return &AstPipeline{firstPr}, nil\n}", "func NewPipeline() Pipeline {\n\n\tp := &pipeline{}\n\tp.head = newHandlerContext(p, headHandler{}, nil, nil)\n\tp.tail = newHandlerContext(p, tailHandler{}, nil, nil)\n\n\tp.head.next = p.tail\n\tp.tail.prev = p.head\n\n\t// head + tail\n\tp.size = 2\n\treturn p\n}", "func BuildPipeline(name,age string) {\n\tvar doc bytes.Buffer\n\n\tf, err := os.Create(outputDirPath + name + \".py\")\n\tcheck(err)\n\tdefer f.Close()\n\n\tm := map[string]interface{}{\"name\": name, \"age\": age}\n\tt := template.Must(template.New(\"\").Parse(scaffold.Pipeline))\n\tt.Execute(&doc, m)\n\n\tfmt.Println(doc.String())\n\twrittenValue, err := f.WriteString(doc.String())\n\tcheck(err)\n\tfmt.Printf(\"wrote %d bytes\\n\", writtenValue)\n\tf.Sync()\n}", "func New() *Pipeline {\n\treturn &Pipeline{}\n}", "func New(stages ...StageRunner) *Pipeline {\n\treturn &Pipeline{\n\t\tstages: stages,\n\t}\n}", "func NewPipeline() *Pipeline {\n\treturn &Pipeline{\n\t\tmake(chan struct{}),\n\t\tsync.WaitGroup{},\n\t\tsync.Mutex{},\n\t\tnil,\n\t}\n}", "func main() {\n\n\tapp := &cli.App{\n\t\tName: \"pipeline\",\n\t\tUsage: \"Scans a directory path for image files and injects them into a pipeline for processing.\",\n\t\tCommands: []*cli.Command{\n\t\t\t&cmd.Start,\n\t\t},\n\t\tFlags: []cli.Flag{\n\t\t\t&cli.BoolFlag{\n\t\t\t\tName: \"debug\",\n\t\t\t\tUsage: \"enables debug logging\",\n\t\t\t},\n\t\t},\n\t}\n\n\terr := app.Run(os.Args)\n\tif IsError(err, func(err error) {\n\t\tfmt.Printf(\"The application encountered an error: %v\", err)\n\t\tos.Exit(kApplicationFailure)\n\t}) {\n\t\tfmt.Println(\"The application has completed successfully.\")\n\t\tos.Exit(kApplicationSuccess)\n\t}\n}", "func createPipeStages(commandList *[]exec.Cmd, stages []string) error {\n\n\tfor _, stage := range stages {\n\t\tcmd, err := createCommand(stage)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t*commandList = append(*commandList, *cmd)\n\t}\n\treturn nil\n}", "func New(opt ...Option) (p *Pipeline, err error) {\n\toptions := Options{}\n\tfor _, v := range opt {\n\t\tv(&options)\n\t}\n\tp = &Pipeline{\n\t\tOptions: options,\n\t\trunMutex: sync.Mutex{},\n\t\tstatus: STATUS_STOP,\n\t}\n\terr = p.init()\n\treturn\n}", "func NewProgram(params *utils.Params, in, out circuit.IO,\n\tconsts map[string]ConstantInst, steps []Step) (*Program, error) {\n\n\tprog := &Program{\n\t\tParams: params,\n\t\tInputs: in,\n\t\tOutputs: out,\n\t\tConstants: consts,\n\t\tSteps: steps,\n\t\twires: make(map[string]*wireAlloc),\n\t\tfreeWires: make(map[types.Size][][]*circuits.Wire),\n\t}\n\n\t// Inputs into wires.\n\tfor idx, arg := range in {\n\t\tif len(arg.Name) == 0 {\n\t\t\targ.Name = fmt.Sprintf(\"arg{%d}\", idx)\n\t\t}\n\t\twires, err := prog.Wires(arg.Name, types.Size(arg.Size))\n\t\tif err != nil {\n\t\t\treturn nil, err\n\t\t}\n\t\tprog.InputWires = append(prog.InputWires, wires...)\n\t}\n\n\treturn prog, nil\n}", "func GenProgramPipelines(n int32, pipelines *uint32) {\n\tC.glowGenProgramPipelines(gpGenProgramPipelines, (C.GLsizei)(n), (*C.GLuint)(unsafe.Pointer(pipelines)))\n}", "func GenProgramPipelines(n int32, pipelines *uint32) {\n\tC.glowGenProgramPipelines(gpGenProgramPipelines, (C.GLsizei)(n), (*C.GLuint)(unsafe.Pointer(pipelines)))\n}", "func NewPipe(opt Opition) (*Pipe, error) {\n\tp := &Pipe{\n\t\tOpition: opt,\n\t\tApps: []*Context{},\n\n\t\tdata: map[string]interface{}{},\n\t}\n\n\tfor _, source := range p.Sources {\n\t\tif _, ok := sourceLoaders[source]; !ok {\n\t\t\treturn nil, fmt.Errorf(\"source %s not exist\", source)\n\t\t}\n\t}\n\n\tfor _, handler := range p.Handlers {\n\t\tif _, ok := sourceHandlers[handler]; !ok {\n\t\t\treturn nil, fmt.Errorf(\"handler %s not exist\", handler)\n\t\t}\n\t}\n\n\treturn p, nil\n}", "func GenProgramPipelines(n int32, pipelines *uint32) {\n C.glowGenProgramPipelines(gpGenProgramPipelines, (C.GLsizei)(n), (*C.GLuint)(unsafe.Pointer(pipelines)))\n}", "func New() *Pipeline {\n\treturn &Pipeline{\n\t\tconfig: DefaultConfig(),\n\t}\n}", "func (p *Parallel) NewPipeline() *Pipeline {\n\tpipe := NewPipeline()\n\tp.Add(pipe)\n\treturn pipe\n}", "func NewProcessPipeline(pipes ...ProcessPipe) *ProcessPipeline {\n\thead := make(chan data.ParsedResponse)\n\tvar next_chan chan data.ParsedResponse\n\tfor _, pipe := range pipes {\n\t\tif next_chan == nil {\n\t\t\tnext_chan = pipe.Process(head)\n\t\t} else {\n\t\t\tnext_chan = pipe.Process(next_chan)\n\t\t}\n\t}\n\treturn &ProcessPipeline{head: head, tail: next_chan}\n}", "func main() {\n\tPipeline1()\n\t// Pipeline2()\n\t// RunDirectionalChannel()\n\tfmt.Println(\"YYY\")\n}", "func Program(name string, env []string) Runner {\n\treturn &program{\n\t\tname: name,\n\t\tenv: append(os.Environ(), env...),\n\t}\n}", "func testPipeline() *Pipeline {\n\treturn &Pipeline{\n\t\tID: sql.NullInt64{Int64: 1, Valid: true},\n\t\tRepoID: sql.NullInt64{Int64: 1, Valid: true},\n\t\tCommit: sql.NullString{String: \"48afb5bdc41ad69bf22588491333f7cf71135163\", Valid: true},\n\t\tFlavor: sql.NullString{String: \"large\", Valid: true},\n\t\tPlatform: sql.NullString{String: \"docker\", Valid: true},\n\t\tRef: sql.NullString{String: \"refs/heads/master\", Valid: true},\n\t\tType: sql.NullString{String: constants.PipelineTypeYAML, Valid: true},\n\t\tVersion: sql.NullString{String: \"1\", Valid: true},\n\t\tExternalSecrets: sql.NullBool{Bool: false, Valid: true},\n\t\tInternalSecrets: sql.NullBool{Bool: false, Valid: true},\n\t\tServices: sql.NullBool{Bool: true, Valid: true},\n\t\tStages: sql.NullBool{Bool: false, Valid: true},\n\t\tSteps: sql.NullBool{Bool: true, Valid: true},\n\t\tTemplates: sql.NullBool{Bool: false, Valid: true},\n\t\tData: testPipelineData(),\n\t}\n}", "func NewPipeline(ctx *pulumi.Context,\n\tname string, args *PipelineArgs, opts ...pulumi.ResourceOption) (*Pipeline, error) {\n\tif args == nil {\n\t\treturn nil, errors.New(\"missing one or more required arguments\")\n\t}\n\n\tif args.BootstrapConfiguration == nil {\n\t\treturn nil, errors.New(\"invalid value for required argument 'BootstrapConfiguration'\")\n\t}\n\tif args.PipelineType == nil {\n\t\treturn nil, errors.New(\"invalid value for required argument 'PipelineType'\")\n\t}\n\tif args.ResourceGroupName == nil {\n\t\treturn nil, errors.New(\"invalid value for required argument 'ResourceGroupName'\")\n\t}\n\taliases := pulumi.Aliases([]pulumi.Alias{\n\t\t{\n\t\t\tType: pulumi.String(\"azure-nextgen:devops/v20200713preview:Pipeline\"),\n\t\t},\n\t\t{\n\t\t\tType: pulumi.String(\"azure-native:devops:Pipeline\"),\n\t\t},\n\t\t{\n\t\t\tType: pulumi.String(\"azure-nextgen:devops:Pipeline\"),\n\t\t},\n\t\t{\n\t\t\tType: pulumi.String(\"azure-native:devops/v20190701preview:Pipeline\"),\n\t\t},\n\t\t{\n\t\t\tType: pulumi.String(\"azure-nextgen:devops/v20190701preview:Pipeline\"),\n\t\t},\n\t})\n\topts = append(opts, aliases)\n\tvar resource Pipeline\n\terr := ctx.RegisterResource(\"azure-native:devops/v20200713preview:Pipeline\", name, args, &resource, opts...)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\treturn &resource, nil\n}", "func newProgram(e *Env, ast *Ast, opts []ProgramOption) (Program, error) {\n\t// Build the dispatcher, interpreter, and default program value.\n\tdisp := interpreter.NewDispatcher()\n\n\t// Ensure the default attribute factory is set after the adapter and provider are\n\t// configured.\n\tp := &prog{\n\t\tEnv: e,\n\t\tdecorators: []interpreter.InterpretableDecorator{},\n\t\tdispatcher: disp,\n\t}\n\n\t// Configure the program via the ProgramOption values.\n\tvar err error\n\tfor _, opt := range opts {\n\t\tp, err = opt(p)\n\t\tif err != nil {\n\t\t\treturn nil, err\n\t\t}\n\t}\n\n\t// Add the function bindings created via Function() options.\n\tfor _, fn := range e.functions {\n\t\tbindings, err := fn.bindings()\n\t\tif err != nil {\n\t\t\treturn nil, err\n\t\t}\n\t\terr = disp.Add(bindings...)\n\t\tif err != nil {\n\t\t\treturn nil, err\n\t\t}\n\t}\n\n\t// Set the attribute factory after the options have been set.\n\tvar attrFactory interpreter.AttributeFactory\n\tif p.evalOpts&OptPartialEval == OptPartialEval {\n\t\tattrFactory = interpreter.NewPartialAttributeFactory(e.Container, e.adapter, e.provider)\n\t} else {\n\t\tattrFactory = interpreter.NewAttributeFactory(e.Container, e.adapter, e.provider)\n\t}\n\tinterp := interpreter.NewInterpreter(disp, e.Container, e.provider, e.adapter, attrFactory)\n\tp.interpreter = interp\n\n\t// Translate the EvalOption flags into InterpretableDecorator instances.\n\tdecorators := make([]interpreter.InterpretableDecorator, len(p.decorators))\n\tcopy(decorators, p.decorators)\n\n\t// Enable interrupt checking if there's a non-zero check frequency\n\tif p.interruptCheckFrequency > 0 {\n\t\tdecorators = append(decorators, interpreter.InterruptableEval())\n\t}\n\t// Enable constant folding first.\n\tif p.evalOpts&OptOptimize == OptOptimize {\n\t\tdecorators = append(decorators, interpreter.Optimize())\n\t\tp.regexOptimizations = append(p.regexOptimizations, interpreter.MatchesRegexOptimization)\n\t}\n\t// Enable regex compilation of constants immediately after folding constants.\n\tif len(p.regexOptimizations) > 0 {\n\t\tdecorators = append(decorators, interpreter.CompileRegexConstants(p.regexOptimizations...))\n\t}\n\t// Enable compile-time checking of syntax/cardinality for string.format calls.\n\tif p.evalOpts&OptCheckStringFormat == OptCheckStringFormat {\n\t\tvar isValidType func(id int64, validTypes ...*types.TypeValue) (bool, error)\n\t\tif ast.IsChecked() {\n\t\t\tisValidType = func(id int64, validTypes ...*types.TypeValue) (bool, error) {\n\t\t\t\tt, err := ExprTypeToType(ast.typeMap[id])\n\t\t\t\tif err != nil {\n\t\t\t\t\treturn false, err\n\t\t\t\t}\n\t\t\t\tif t.kind == DynKind {\n\t\t\t\t\treturn true, nil\n\t\t\t\t}\n\t\t\t\tfor _, vt := range validTypes {\n\t\t\t\t\tk, err := typeValueToKind(vt)\n\t\t\t\t\tif err != nil {\n\t\t\t\t\t\treturn false, err\n\t\t\t\t\t}\n\t\t\t\t\tif k == t.kind {\n\t\t\t\t\t\treturn true, nil\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\treturn false, nil\n\t\t\t}\n\t\t} else {\n\t\t\t// if the AST isn't type-checked, short-circuit validation\n\t\t\tisValidType = func(id int64, validTypes ...*types.TypeValue) (bool, error) {\n\t\t\t\treturn true, nil\n\t\t\t}\n\t\t}\n\t\tdecorators = append(decorators, interpreter.InterpolateFormattedString(isValidType))\n\t}\n\n\t// Enable exhaustive eval, state tracking and cost tracking last since they require a factory.\n\tif p.evalOpts&(OptExhaustiveEval|OptTrackState|OptTrackCost) != 0 {\n\t\tfactory := func(state interpreter.EvalState, costTracker *interpreter.CostTracker) (Program, error) {\n\t\t\tcostTracker.Estimator = p.callCostEstimator\n\t\t\tcostTracker.Limit = p.costLimit\n\t\t\t// Limit capacity to guarantee a reallocation when calling 'append(decs, ...)' below. This\n\t\t\t// prevents the underlying memory from being shared between factory function calls causing\n\t\t\t// undesired mutations.\n\t\t\tdecs := decorators[:len(decorators):len(decorators)]\n\t\t\tvar observers []interpreter.EvalObserver\n\n\t\t\tif p.evalOpts&(OptExhaustiveEval|OptTrackState) != 0 {\n\t\t\t\t// EvalStateObserver is required for OptExhaustiveEval.\n\t\t\t\tobservers = append(observers, interpreter.EvalStateObserver(state))\n\t\t\t}\n\t\t\tif p.evalOpts&OptTrackCost == OptTrackCost {\n\t\t\t\tobservers = append(observers, interpreter.CostObserver(costTracker))\n\t\t\t}\n\n\t\t\t// Enable exhaustive eval over a basic observer since it offers a superset of features.\n\t\t\tif p.evalOpts&OptExhaustiveEval == OptExhaustiveEval {\n\t\t\t\tdecs = append(decs, interpreter.ExhaustiveEval(), interpreter.Observe(observers...))\n\t\t\t} else if len(observers) > 0 {\n\t\t\t\tdecs = append(decs, interpreter.Observe(observers...))\n\t\t\t}\n\n\t\t\treturn p.clone().initInterpretable(ast, decs)\n\t\t}\n\t\treturn newProgGen(factory)\n\t}\n\treturn p.initInterpretable(ast, decorators)\n}", "func Pipeline(\n\tctx context.Context,\n\tin chan interface{},\n\n\t// newAccumulator will be used to produce a single accumulator object for\n\t// each Go routine withine the pipeline.\n\tnewAccumulator func() Accumulator,\n) Accumulator {\n\t//uid := fmt.Sprintf(\"%8X\", rand.Uint32())\n\n\t// Keep track of GOMAXPROCS accumulators using a slice.\n\tgomaxprocs := runtime.GOMAXPROCS(-1)\n\taccumulators := make([]Accumulator, gomaxprocs)\n\n\t// Start GOMAXPROCS Go routines to read values from the input channel; we'll\n\t// track their execution using a sync.WaitGroup instance.\n\tvar waitGroup sync.WaitGroup\n\twaitGroup.Add(gomaxprocs)\n\tfor i := 0; i < gomaxprocs; i++ {\n\n\t\t// Use the provided newAccumulator function to produce an accumulator\n\t\t// value for this Go routine and add it to a new context.Context instance.\n\t\taccumulator := newAccumulator()\n\t\taccumulators[i] = accumulator\n\n\t\t// Start a new Go routine passing the index value for logging.\n\t\tgo func(i int) {\n\n\t\t\t// Process values until the input channel is closed, then signal this go\n\t\t\t// routine has finished processing.\n\t\t\tfor object := range in {\n\t\t\t\taccumulator.Accumulate(ctx, object)\n\t\t\t}\n\t\t\twaitGroup.Done()\n\t\t}(i)\n\t}\n\n\t// Wait for the processors to exit.\n\twaitGroup.Wait()\n\n\t// Combine the accumulators.\n\taccumulator := accumulators[0]\n\tfor i := 1; i < len(accumulators); i++ {\n\t\taccumulator.Combine(accumulators[i])\n\t}\n\n\t// Return a single accumulator.\n\treturn accumulator\n}", "func NewPipeline(logger log.Logger, stgs PipelineStages, jobName *string, registerer prometheus.Registerer) (*Pipeline, error) {\n\thist := prometheus.NewHistogramVec(prometheus.HistogramOpts{\n\t\tNamespace: \"logentry\",\n\t\tName: \"pipeline_duration_seconds\",\n\t\tHelp: \"Label and metric extraction pipeline processing time, in seconds\",\n\t\tBuckets: []float64{.000005, .000010, .000025, .000050, .000100, .000250, .000500, .001000, .002500, .005000, .010000, .025000},\n\t}, []string{\"job_name\"})\n\terr := registerer.Register(hist)\n\tif err != nil {\n\t\tif existing, ok := err.(prometheus.AlreadyRegisteredError); ok {\n\t\t\thist = existing.ExistingCollector.(*prometheus.HistogramVec)\n\t\t} else {\n\t\t\t// Same behavior as MustRegister if the error is not for AlreadyRegistered\n\t\t\tpanic(err)\n\t\t}\n\t}\n\n\tst := []Stage{}\n\tfor _, s := range stgs {\n\t\tstage, ok := s.(PipelineStage)\n\t\tif !ok {\n\t\t\treturn nil, errors.Errorf(\"invalid YAML config, \"+\n\t\t\t\t\"make sure each stage of your pipeline is a YAML object (must end with a `:`), check stage `- %s`\", s)\n\t\t}\n\t\tif len(stage) > 1 {\n\t\t\treturn nil, errors.New(\"pipeline stage must contain only one key\")\n\t\t}\n\t\tfor key, config := range stage {\n\t\t\tname, ok := key.(string)\n\t\t\tif !ok {\n\t\t\t\treturn nil, errors.New(\"pipeline stage key must be a string\")\n\t\t\t}\n\t\t\tnewStage, err := New(logger, jobName, name, config, registerer)\n\t\t\tif err != nil {\n\t\t\t\treturn nil, errors.Wrapf(err, \"invalid %s stage config\", name)\n\t\t\t}\n\t\t\tst = append(st, newStage)\n\t\t}\n\t}\n\treturn &Pipeline{\n\t\tlogger: log.With(logger, \"component\", \"pipeline\"),\n\t\tstages: st,\n\t\tjobName: jobName,\n\t\tplDuration: hist,\n\t}, nil\n}", "func NewPipeline(transformer Transformer, classifier Classifier, filterer Filterer, encoder Encoder, compressor Compressor, storer Storer) *Pipeline {\n\tp := &Pipeline{\n\t\tTransformer: transformer,\n\t\tClassifier: classifier,\n\t\tFilterer: filterer,\n\t\tEncoder: encoder,\n\t\tCompressor: compressor,\n\t\tStorer: storer,\n\t}\n\tstorer.SetPipeline(p)\n\treturn p\n}", "func CreatePipeline(codecName string, pipelineStr string, clockRate float32) *Pipeline {\n\t// Generate C String from Input\n\tpipelineStrUnsafe := C.CString(pipelineStr)\n\tdefer C.free(unsafe.Pointer(pipelineStrUnsafe))\n\n\t// Lock Pipelines\n\tpipelinesLock.Lock()\n\tdefer pipelinesLock.Unlock()\n\n\t// Create new Pipeline\n\tpipeline := &Pipeline{\n\t\tPipeline: C.gstreamer_create_pipeline(pipelineStrUnsafe),\n\t\tid: utils.RandSeq(5),\n\t\tcodecName: codecName,\n\t\tclockRate: clockRate,\n\t}\n\tpipeline.outputTracks = []*webrtc.Track{}\n\t// Add new Pipeline\n\tpipelines[pipeline.id] = pipeline\n\treturn pipeline\n}", "func New(input *bytes.Buffer, command ...Execute) *commandPipeline {\n\treturn &commandPipeline{\n\t\tcommands: append([]Execute{}, command...),\n\t\tinput: input,\n\t}\n}", "func main() {\n\tmodule.Create(\"init\", 0)\n\tmodule.Log()\n\tReadLine(\"D:/input.txt\", processLine)\n\tmodule.Show_pcb(\"r\")\n\tfmt.Println()\n\tmodule.List_all_process()\n\tfmt.Println()\n\tmodule.List_all_resource()\n}", "func PipelineFromLibrary(p *library.Pipeline) *Pipeline {\n\tpipeline := &Pipeline{\n\t\tID: sql.NullInt64{Int64: p.GetID(), Valid: true},\n\t\tRepoID: sql.NullInt64{Int64: p.GetRepoID(), Valid: true},\n\t\tCommit: sql.NullString{String: p.GetCommit(), Valid: true},\n\t\tFlavor: sql.NullString{String: p.GetFlavor(), Valid: true},\n\t\tPlatform: sql.NullString{String: p.GetPlatform(), Valid: true},\n\t\tRef: sql.NullString{String: p.GetRef(), Valid: true},\n\t\tType: sql.NullString{String: p.GetType(), Valid: true},\n\t\tVersion: sql.NullString{String: p.GetVersion(), Valid: true},\n\t\tExternalSecrets: sql.NullBool{Bool: p.GetExternalSecrets(), Valid: true},\n\t\tInternalSecrets: sql.NullBool{Bool: p.GetInternalSecrets(), Valid: true},\n\t\tServices: sql.NullBool{Bool: p.GetServices(), Valid: true},\n\t\tStages: sql.NullBool{Bool: p.GetStages(), Valid: true},\n\t\tSteps: sql.NullBool{Bool: p.GetSteps(), Valid: true},\n\t\tTemplates: sql.NullBool{Bool: p.GetTemplates(), Valid: true},\n\t\tData: p.GetData(),\n\t}\n\n\treturn pipeline.Nullify()\n}", "func (pl *Pipeline) Exec() error {\n link, linkerr := pl.linkPipes()\n\n if linkerr != nil {\n return linkerr\n }\n\n starterr := pl.start()\n if starterr != nil {\n return starterr\n }\n\n setuperr := pl.copyPipes(link)\n if setuperr != nil {\n return setuperr\n }\n\n waiterr := pl.wait()\n if waiterr != nil {\n return waiterr\n }\n\n return nil\n}", "func buildPipeline(req *backend.QueryDataRequest) (DataPipeline, error) {\n\tgraph, err := buildDependencyGraph(req)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\n\tnodes, err := buildExecutionOrder(graph)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\n\treturn nodes, nil\n}", "func NewProgram(lessons []*LessonPgm) *Program {\n\treturn &Program{base.WildCardLabel, lessons}\n}", "func main() {\n\tprocessor.RegisterProcessors(Process)\n}", "func NewPipeline(module, version string, cred azcore.TokenCredential, options *arm.ClientOptions) pipeline.Pipeline {\n\tif options == nil {\n\t\toptions = &arm.ClientOptions{}\n\t}\n\tep := options.Host\n\tif len(ep) == 0 {\n\t\tep = arm.AzurePublicCloud\n\t}\n\tperCallPolicies := []azpolicy.Policy{}\n\tif !options.DisableRPRegistration {\n\t\tregRPOpts := armpolicy.RegistrationOptions{ClientOptions: options.ClientOptions}\n\t\tperCallPolicies = append(perCallPolicies, NewRPRegistrationPolicy(string(ep), cred, &regRPOpts))\n\t}\n\tperRetryPolicies := []azpolicy.Policy{\n\t\tNewBearerTokenPolicy(cred, &armpolicy.BearerTokenOptions{\n\t\t\tScopes: []string{shared.EndpointToScope(string(ep))},\n\t\t\tAuxiliaryTenants: options.AuxiliaryTenants,\n\t\t}),\n\t}\n\treturn azruntime.NewPipeline(module, version, perCallPolicies, perRetryPolicies, &options.ClientOptions)\n}", "func Build(ctx context.Context, set Settings) (*Pipelines, error) {\n\texps := &Pipelines{\n\t\ttelemetry: set.Telemetry,\n\t\tallReceivers: make(map[config.DataType]map[config.ComponentID]component.Receiver),\n\t\tallExporters: make(map[config.DataType]map[config.ComponentID]component.Exporter),\n\t\tpipelines: make(map[config.ComponentID]*builtPipeline, len(set.PipelineConfigs)),\n\t}\n\n\treceiversConsumers := make(map[config.DataType]map[config.ComponentID][]baseConsumer)\n\n\t// Iterate over all pipelines, and create exporters, then processors.\n\t// Receivers cannot be created since we need to know all consumers, a.k.a. we need all pipelines build up to the\n\t// first processor.\n\tfor pipelineID, pipeline := range set.PipelineConfigs {\n\t\t// The data type of the pipeline defines what data type each exporter is expected to receive.\n\t\tif _, ok := exps.allExporters[pipelineID.Type()]; !ok {\n\t\t\texps.allExporters[pipelineID.Type()] = make(map[config.ComponentID]component.Exporter)\n\t\t}\n\t\texpByID := exps.allExporters[pipelineID.Type()]\n\n\t\tbp := &builtPipeline{\n\t\t\treceivers: make([]builtComponent, len(pipeline.Receivers)),\n\t\t\tprocessors: make([]builtComponent, len(pipeline.Processors)),\n\t\t\texporters: make([]builtComponent, len(pipeline.Exporters)),\n\t\t}\n\t\texps.pipelines[pipelineID] = bp\n\n\t\t// Iterate over all Exporters for this pipeline.\n\t\tfor i, expID := range pipeline.Exporters {\n\t\t\t// If already created an exporter for this [DataType, ComponentID] nothing to do, will reuse this instance.\n\t\t\tif exp, ok := expByID[expID]; ok {\n\t\t\t\tbp.exporters[i] = builtComponent{id: expID, comp: exp}\n\t\t\t\tcontinue\n\t\t\t}\n\n\t\t\texp, err := buildExporter(ctx, set.Telemetry, set.BuildInfo, set.ExporterConfigs, set.ExporterFactories, expID, pipelineID)\n\t\t\tif err != nil {\n\t\t\t\treturn nil, err\n\t\t\t}\n\n\t\t\tbp.exporters[i] = builtComponent{id: expID, comp: exp}\n\t\t\texpByID[expID] = exp\n\t\t}\n\n\t\t// Build a fan out consumer to all exporters.\n\t\tswitch pipelineID.Type() {\n\t\tcase config.TracesDataType:\n\t\t\tbp.lastConsumer = buildFanOutExportersTracesConsumer(bp.exporters)\n\t\tcase config.MetricsDataType:\n\t\t\tbp.lastConsumer = buildFanOutExportersMetricsConsumer(bp.exporters)\n\t\tcase config.LogsDataType:\n\t\t\tbp.lastConsumer = buildFanOutExportersLogsConsumer(bp.exporters)\n\t\tdefault:\n\t\t\treturn nil, fmt.Errorf(\"create fan-out exporter in pipeline %q, data type %q is not supported\", pipelineID, pipelineID.Type())\n\t\t}\n\n\t\tmutatesConsumedData := bp.lastConsumer.Capabilities().MutatesData\n\t\t// Build the processors backwards, starting from the last one.\n\t\t// The last processor points to fan out consumer to all Exporters, then the processor itself becomes a\n\t\t// consumer for the one that precedes it in the pipeline and so on.\n\t\tfor i := len(pipeline.Processors) - 1; i >= 0; i-- {\n\t\t\tprocID := pipeline.Processors[i]\n\n\t\t\tproc, err := buildProcessor(ctx, set.Telemetry, set.BuildInfo, set.ProcessorConfigs, set.ProcessorFactories, procID, pipelineID, bp.lastConsumer)\n\t\t\tif err != nil {\n\t\t\t\treturn nil, err\n\t\t\t}\n\n\t\t\tbp.processors[i] = builtComponent{id: procID, comp: proc}\n\t\t\tbp.lastConsumer = proc.(baseConsumer)\n\t\t\tmutatesConsumedData = mutatesConsumedData || bp.lastConsumer.Capabilities().MutatesData\n\t\t}\n\n\t\t// Some consumers may not correctly implement the Capabilities, and ignore the next consumer when calculated the Capabilities.\n\t\t// Because of this wrap the first consumer if any consumers in the pipeline mutate the data and the first says that it doesn't.\n\t\tswitch pipelineID.Type() {\n\t\tcase config.TracesDataType:\n\t\t\tbp.lastConsumer = capTraces{Traces: bp.lastConsumer.(consumer.Traces), cap: consumer.Capabilities{MutatesData: mutatesConsumedData}}\n\t\tcase config.MetricsDataType:\n\t\t\tbp.lastConsumer = capMetrics{Metrics: bp.lastConsumer.(consumer.Metrics), cap: consumer.Capabilities{MutatesData: mutatesConsumedData}}\n\t\tcase config.LogsDataType:\n\t\t\tbp.lastConsumer = capLogs{Logs: bp.lastConsumer.(consumer.Logs), cap: consumer.Capabilities{MutatesData: mutatesConsumedData}}\n\t\tdefault:\n\t\t\treturn nil, fmt.Errorf(\"create cap consumer in pipeline %q, data type %q is not supported\", pipelineID, pipelineID.Type())\n\t\t}\n\n\t\t// The data type of the pipeline defines what data type each exporter is expected to receive.\n\t\tif _, ok := receiversConsumers[pipelineID.Type()]; !ok {\n\t\t\treceiversConsumers[pipelineID.Type()] = make(map[config.ComponentID][]baseConsumer)\n\t\t}\n\t\trecvConsByID := receiversConsumers[pipelineID.Type()]\n\t\t// Iterate over all Receivers for this pipeline and just append the lastConsumer as a consumer for the receiver.\n\t\tfor _, recvID := range pipeline.Receivers {\n\t\t\trecvConsByID[recvID] = append(recvConsByID[recvID], bp.lastConsumer)\n\t\t}\n\t}\n\n\t// Now that we built the `receiversConsumers` map, we can build the receivers as well.\n\tfor pipelineID, pipeline := range set.PipelineConfigs {\n\t\t// The data type of the pipeline defines what data type each exporter is expected to receive.\n\t\tif _, ok := exps.allReceivers[pipelineID.Type()]; !ok {\n\t\t\texps.allReceivers[pipelineID.Type()] = make(map[config.ComponentID]component.Receiver)\n\t\t}\n\t\trecvByID := exps.allReceivers[pipelineID.Type()]\n\t\tbp := exps.pipelines[pipelineID]\n\n\t\t// Iterate over all Receivers for this pipeline.\n\t\tfor i, recvID := range pipeline.Receivers {\n\t\t\t// If already created a receiver for this [DataType, ComponentID] nothing to do.\n\t\t\tif exp, ok := recvByID[recvID]; ok {\n\t\t\t\tbp.receivers[i] = builtComponent{id: recvID, comp: exp}\n\t\t\t\tcontinue\n\t\t\t}\n\n\t\t\trecv, err := buildReceiver(ctx, set.Telemetry, set.BuildInfo, set.ReceiverConfigs, set.ReceiverFactories, recvID, pipelineID, receiversConsumers[pipelineID.Type()][recvID])\n\t\t\tif err != nil {\n\t\t\t\treturn nil, err\n\t\t\t}\n\n\t\t\tbp.receivers[i] = builtComponent{id: recvID, comp: recv}\n\t\t\trecvByID[recvID] = recv\n\t\t}\n\t}\n\treturn exps, nil\n}", "func (wa *WebAPI) buildPipelines(p Push, rawPush []byte, f dinghyfile.Downloader, w http.ResponseWriter, dinghyLog dinghylog.DinghyLog) {\n\t// see if we have any configurations for this repo.\n\t// if we do have configurations, see if this is the branch we want to use. If it's not, skip and return.\n\tvar validation bool\n\tif rc := wa.Config.GetRepoConfig(p.Name(), p.Repo()); rc != nil {\n\t\tif !p.IsBranch(rc.Branch) {\n\t\t\tdinghyLog.Infof(\"Received request from branch %s. Does not match configured branch %s. Proceeding as validation.\", p.Branch(), rc.Branch)\n\t\t\tvalidation = true\n\t\t}\n\t} else {\n\t\t// if we didn't find any configurations for this repo, proceed with master\n\t\tdinghyLog.Infof(\"Found no custom configuration for repo: %s, proceeding with master\", p.Repo())\n\t\tif !p.IsMaster() {\n\t\t\tdinghyLog.Infof(\"Skipping Spinnaker pipeline update because this branch (%s) is not master. Proceeding as validation.\", p.Branch())\n\t\t\tvalidation = true\n\t\t}\n\t}\n\n\tdinghyLog.Infof(\"Processing request for branch: %s\", p.Branch())\n\n\t// deserialze push data to a map. used in template logic later\n\trawPushData := make(map[string]interface{})\n\tif err := json.Unmarshal(rawPush, &rawPushData); err != nil {\n\t\tdinghyLog.Errorf(\"unable to deserialze raw data to map\")\n\t}\n\n\t// Construct a pipeline builder using provided downloader\n\tbuilder := &dinghyfile.PipelineBuilder{\n\t\tDownloader: f,\n\t\tDepman: wa.Cache,\n\t\tTemplateRepo: wa.Config.TemplateRepo,\n\t\tTemplateOrg: wa.Config.TemplateOrg,\n\t\tDinghyfileName: wa.Config.DinghyFilename,\n\t\tDeleteStalePipelines: false,\n\t\tAutolockPipelines: wa.Config.AutoLockPipelines,\n\t\tClient: wa.Client,\n\t\tEventClient: wa.EventClient,\n\t\tLogger: dinghyLog,\n\t\tUms: wa.Ums,\n\t\tNotifiers: wa.Notifiers,\n\t\tPushRaw: rawPushData,\n\t\tRepositoryRawdataProcessing: wa.Config.RepositoryRawdataProcessing,\n\t\tAction: pipebuilder.Process,\n\t}\n\n\tif validation {\n\t\tbuilder.Client = wa.ClientReadOnly\n\t\tbuilder.Depman = wa.CacheReadOnly\n\t\tbuilder.Action = pipebuilder.Validate\n\t}\n\n\tbuilder.Parser = wa.Parser\n\tbuilder.Parser.SetBuilder(builder)\n\n\t// Process the push.\n\tdinghyLog.Info(\"Processing Push\")\n\terr := wa.ProcessPush(p, builder)\n\tif err == dinghyfile.ErrMalformedJSON {\n\t\tutil.WriteHTTPError(w, http.StatusUnprocessableEntity, err)\n\t\tdinghyLog.Errorf(\"ProcessPush Failed (malformed JSON): %s\", err.Error())\n\t\tsaveLogEventError(wa.LogEventsClient, p, dinghyLog, logevents.LogEvent{RawData: string(rawPush)})\n\t\treturn\n\t} else if err != nil {\n\t\tdinghyLog.Errorf(\"ProcessPush Failed (other): %s\", err.Error())\n\t\tutil.WriteHTTPError(w, http.StatusInternalServerError, err)\n\t\tsaveLogEventError(wa.LogEventsClient, p, dinghyLog, logevents.LogEvent{RawData: string(rawPush)})\n\t\treturn\n\t}\n\n\t// Check if we're in a template repo\n\tif p.Repo() == wa.Config.TemplateRepo {\n\t\t// Set status to pending while we process modules\n\t\tp.SetCommitStatus(git.StatusPending, git.DefaultMessagesByBuilderAction[builder.Action][git.StatusPending])\n\n\t\t// For each module pushed, rebuild dependent dinghyfiles\n\t\tfor _, file := range p.Files() {\n\t\t\tif err := builder.RebuildModuleRoots(p.Org(), p.Repo(), file, p.Branch()); err != nil {\n\t\t\t\tswitch err.(type) {\n\t\t\t\tcase *util.GitHubFileNotFoundErr:\n\t\t\t\t\tutil.WriteHTTPError(w, http.StatusNotFound, err)\n\t\t\t\tdefault:\n\t\t\t\t\tutil.WriteHTTPError(w, http.StatusInternalServerError, err)\n\t\t\t\t}\n\t\t\t\tp.SetCommitStatus(git.StatusError, \"Rebuilding dependent dinghyfiles Failed\")\n\t\t\t\tdinghyLog.Errorf(\"RebuildModuleRoots Failed: %s\", err.Error())\n\t\t\t\tsaveLogEventError(wa.LogEventsClient, p, dinghyLog, logevents.LogEvent{RawData: string(rawPush)})\n\t\t\t\treturn\n\t\t\t}\n\t\t}\n\t\tp.SetCommitStatus(git.StatusSuccess, git.DefaultMessagesByBuilderAction[builder.Action][git.StatusSuccess])\n\t}\n\n\t// Only save event if changed files were in repo or it was having a dinghyfile\n\t// TODO: If a template repo is having files not related with dinghy an event will be saved\n\tif p.Repo() == wa.Config.TemplateRepo {\n\t\tif len(p.Files()) > 0 {\n\t\t\tsaveLogEventSuccess(wa.LogEventsClient, p, dinghyLog, logevents.LogEvent{RawData: string(rawPush)})\n\t\t}\n\t} else {\n\t\tdinghyfiles := []string{}\n\t\tfor _, currfile := range p.Files() {\n\t\t\tif filepath.Base(currfile) == builder.DinghyfileName {\n\t\t\t\tdinghyfiles = append(dinghyfiles, currfile)\n\t\t\t}\n\t\t}\n\t\tif len(dinghyfiles) > 0 {\n\t\t\tsaveLogEventSuccess(wa.LogEventsClient, p, dinghyLog, logevents.LogEvent{RawData: string(rawPush), Files: dinghyfiles})\n\t\t}\n\t}\n\tw.Write([]byte(`{\"status\":\"accepted\"}`))\n}", "func main() {\n\tdefer contracts.ShowHelp(help)\n\tnProd, nCons, bufferSize := parseArguments()\n\n\tprogram(nProd, nCons, bufferSize)\n}", "func NewProgram(data []byte) *Program {\n\tp := new(Program)\n\tp.data = make([]byte, len(data))\n\tcopy(data, p.data)\n\tp.Pc = 0\n\treturn p\n}", "func New(ruleGetter ChannelRuleGetter) (*Pipeline, error) {\n\tp := &Pipeline{\n\t\truleGetter: ruleGetter,\n\t}\n\n\tif os.Getenv(\"GF_LIVE_PIPELINE_TRACE\") != \"\" {\n\t\t// Traces for development only at the moment.\n\t\t// Start local Jaeger and then run Grafana with GF_LIVE_PIPELINE_TRACE:\n\t\t// docker run --rm -it --name jaeger -e COLLECTOR_ZIPKIN_HOST_PORT=:9411 -p 5775:5775/udp -p 6831:6831/udp -p 6832:6832/udp -p 5778:5778 -p 16686:16686 -p 14268:14268 -p 14250:14250 -p 9411:9411 jaegertracing/all-in-one:1.26\n\t\t// Then visit http://localhost:16686/ where Jaeger UI is served.\n\t\ttp, err := tracerProvider(\"http://localhost:14268/api/traces\")\n\t\tif err != nil {\n\t\t\treturn nil, err\n\t\t}\n\t\ttracer := tp.Tracer(\"gf.live.pipeline\")\n\t\tp.tracer = tracer\n\t}\n\n\tif os.Getenv(\"GF_LIVE_PIPELINE_DEV\") != \"\" {\n\t\tgo postTestData() // TODO: temporary for development, remove before merge.\n\t}\n\n\treturn p, nil\n}", "func ExampleNewPipeline() {\n\t// This example shows how to wire in your own logging mechanism (this example uses\n\t// Go's standard logger to write log information to standard error)\n\tlogger := log.New(os.Stderr, \"\", log.Ldate|log.Lmicroseconds)\n\n\t// Create/configure a request pipeline options object.\n\t// All PipelineOptions' fields are optional; reasonable defaults are set for anything you do not specify\n\tpo := azfile.PipelineOptions{\n\t\t// Set RetryOptions to control how HTTP request are retried when retryable failures occur\n\t\tRetry: azfile.RetryOptions{\n\t\t\tPolicy: azfile.RetryPolicyExponential, // Use exponential backoff as opposed to linear\n\t\t\tMaxTries: 3, // Try at most 3 times to perform the operation (set to 1 to disable retries)\n\t\t\tTryTimeout: time.Second * 3, // Maximum time allowed for any single try\n\t\t\tRetryDelay: time.Second * 1, // Backoff amount for each retry (exponential or linear)\n\t\t\tMaxRetryDelay: time.Second * 3, // Max delay between retries\n\t\t},\n\n\t\t// Set RequestLogOptions to control how each HTTP request & its response is logged\n\t\tRequestLog: azfile.RequestLogOptions{\n\t\t\tLogWarningIfTryOverThreshold: time.Millisecond * 200, // A successful response taking more than this time to arrive is logged as a warning\n\t\t},\n\n\t\t// Set LogOptions to control what & where all pipeline log events go\n\t\tLog: pipeline.LogOptions{\n\t\t\tLog: func(s pipeline.LogLevel, m string) { // This func is called to log each event\n\t\t\t\t// This method is not called for filtered-out severities.\n\t\t\t\tlogger.Output(2, m) // This example uses Go's standard logger\n\t\t\t},\n\t\t\tShouldLog: func(level pipeline.LogLevel) bool {\n\t\t\t\treturn level <= pipeline.LogInfo // Log all events from informational to more severe\n\t\t\t},\n\t\t},\n\t}\n\n\t// Create a request pipeline object configured with credentials and with pipeline options. Once created,\n\t// a pipeline object is goroutine-safe and can be safely used with many XxxURL objects simultaneously.\n\tp := azfile.NewPipeline(azfile.NewAnonymousCredential(), po) // A pipeline always requires some credential object\n\n\t// Once you've created a pipeline object, associate it with an XxxURL object so that you can perform HTTP requests with it.\n\tu, _ := url.Parse(\"https://myaccount.file.core.windows.net\")\n\tserviceURL := azfile.NewServiceURL(*u, p)\n\t// Use the serviceURL as desired...\n\n\t// NOTE: When you use an XxxURL object to create another XxxURL object, the new XxxURL object inherits the\n\t// same pipeline object as its parent. For example, the shareURL and fileURL objects (created below)\n\t// all share the same pipeline. Any HTTP operations you perform with these objects share the behavior (retry, logging, etc.)\n\tshareURL := serviceURL.NewShareURL(\"myshare\")\n\tdirectoryURL := shareURL.NewDirectoryURL(\"mydirectory\")\n\tfileURL := directoryURL.NewFileURL(\"ReadMe.txt\")\n\n\t// If you'd like to perform some operations with different behavior, create a new pipeline object and\n\t// associate it with a new XxxURL object by passing the new pipeline to the XxxURL object's WithPipeline method.\n\n\t// In this example, I reconfigure the retry policies, create a new pipeline, and then create a new\n\t// ShareURL object that has the same URL as its parent.\n\tpo.Retry = azfile.RetryOptions{\n\t\tPolicy: azfile.RetryPolicyFixed, // Use linear backoff\n\t\tMaxTries: 4, // Try at most 3 times to perform the operation (set to 1 to disable retries)\n\t\tTryTimeout: time.Minute * 1, // Maximum time allowed for any single try\n\t\tRetryDelay: time.Second * 5, // Backoff amount for each retry (exponential or linear)\n\t\tMaxRetryDelay: time.Second * 10, // Max delay between retries\n\t}\n\tnewShareURL := shareURL.WithPipeline(azfile.NewPipeline(azfile.NewAnonymousCredential(), po))\n\n\t// Now, any XxxDirectoryURL object created using newShareURL inherits the pipeline with the new retry policy.\n\tnewDirectoryURL := newShareURL.NewDirectoryURL(\"mynewdirectory\")\n\t_, _, _ = fileURL, directoryURL, newDirectoryURL // Avoid compiler's \"declared and not used\" error\n}", "func NewProgram() Program {\n\treturn &program{\n\t\tstatements: make([]Statement, 0, 5),\n\t}\n}", "func newProgram(filter []bpf.Instruction, action xdpAction, perfMap *ebpf.Map) (*program, error) {\n\tmetricsMap, err := ebpf.NewMap(&metricsSpec)\n\tif err != nil {\n\t\treturn nil, errors.Wrap(err, \"creating metrics map\")\n\t}\n\n\tif perfMap.Type() != ebpf.PerfEventArray {\n\t\treturn nil, errors.Errorf(\"invalid perf map ABI, expected type %s, have %s\", ebpf.PerfEventArray, perfMap.Type())\n\t}\n\n\t// Labels of blocks\n\tconst result = \"result\"\n\tconst exit = \"exit\"\n\n\tebpfFilter, err := cbpfc.ToEBPF(filter, cbpfc.EBPFOpts{\n\t\tPacketStart: asm.R0,\n\t\tPacketEnd: asm.R1,\n\n\t\tResult: asm.R2,\n\t\tResultLabel: result,\n\n\t\tWorking: [4]asm.Register{asm.R2, asm.R3, asm.R4, asm.R5},\n\n\t\tStackOffset: 0,\n\t\tLabelPrefix: \"filter\",\n\t})\n\tif err != nil {\n\t\treturn nil, errors.Wrap(err, \"converting cBPF to eBPF\")\n\t}\n\n\tinsns := asm.Instructions{\n\t\t// Save ctx\n\t\tasm.Mov.Reg(asm.R6, asm.R1),\n\n\t\t// Get the metrics struct\n\t\t// map fd\n\t\tasm.LoadMapPtr(asm.R1, metricsMap.FD()),\n\t\t// index\n\t\tasm.Mov.Reg(asm.R2, asm.R10),\n\t\tasm.Add.Imm(asm.R2, -4),\n\t\tasm.StoreImm(asm.R2, 0, 0, asm.Word),\n\t\t// call\n\t\tasm.FnMapLookupElem.Call(),\n\n\t\t// Check metrics aren't nil\n\t\tasm.JEq.Imm(asm.R0, 0, exit),\n\n\t\t// Save metrics\n\t\tasm.Mov.Reg(asm.R7, asm.R0),\n\n\t\t// Packet start\n\t\tasm.LoadMem(asm.R0, asm.R6, 0, asm.Word),\n\n\t\t// Packet end\n\t\tasm.LoadMem(asm.R1, asm.R6, 4, asm.Word),\n\n\t\t// Packet length\n\t\tasm.Mov.Reg(asm.R8, asm.R1),\n\t\tasm.Sub.Reg(asm.R8, asm.R0),\n\n\t\t// Received packets\n\t\tasm.LoadMem(asm.R2, asm.R7, int16(8*receivedPackets), asm.DWord),\n\t\tasm.Add.Imm(asm.R2, 1),\n\t\tasm.StoreMem(asm.R7, int16(8*receivedPackets), asm.R2, asm.DWord),\n\n\t\t// Fall through to filter\n\t}\n\n\tinsns = append(insns, ebpfFilter...)\n\n\tinsns = append(insns,\n\t\t// Packet didn't match filter\n\t\tasm.JEq.Imm(asm.R2, 0, exit).Sym(result),\n\n\t\t// Matched packets\n\t\tasm.LoadMem(asm.R0, asm.R7, int16(8*matchedPackets), asm.DWord),\n\t\tasm.Add.Imm(asm.R0, 1),\n\t\tasm.StoreMem(asm.R7, int16(8*matchedPackets), asm.R0, asm.DWord),\n\n\t\t// Perf output\n\t\t// ctx\n\t\tasm.Mov.Reg(asm.R1, asm.R6),\n\t\t// perf map\n\t\tasm.LoadMapPtr(asm.R2, perfMap.FD()),\n\t\t// flags (len << 32 | BPF_F_CURRENT_CPU)\n\t\tasm.Mov.Reg(asm.R3, asm.R8),\n\t\tasm.LSh.Imm(asm.R3, 32),\n\t\tasm.LoadImm(asm.R0, BPF_F_CURRENT_CPU, asm.DWord),\n\t\tasm.Or.Reg(asm.R3, asm.R0),\n\t\t// perf output data\n\t\tasm.Mov.Reg(asm.R4, asm.R10),\n\t\t// <u64 packet length>\n\t\tasm.Add.Imm(asm.R4, -8),\n\t\tasm.StoreMem(asm.R4, 0, asm.R8, asm.DWord),\n\t\t// <u64 action>\n\t\tasm.Add.Imm(asm.R4, -8),\n\t\tasm.StoreImm(asm.R4, 0, int64(action), asm.DWord),\n\t\t// sizeof(data)\n\t\tasm.Mov.Imm(asm.R5, 2*8),\n\t\t// call\n\t\tasm.FnPerfEventOutput.Call(),\n\n\t\t// Perf success\n\t\tasm.JEq.Imm(asm.R0, 0, exit),\n\n\t\t// Perf output errors\n\t\tasm.LoadMem(asm.R0, asm.R7, int16(8*perfOutputErrors), asm.DWord),\n\t\tasm.Add.Imm(asm.R0, 1),\n\t\tasm.StoreMem(asm.R7, int16(8*perfOutputErrors), asm.R0, asm.DWord),\n\n\t\t// Fall through to exit\n\t)\n\n\t// Exit with original action - always referred to\n\tinsns = append(insns,\n\t\tasm.Mov.Imm(asm.R0, int32(action)).Sym(exit),\n\t\tasm.Return(),\n\t)\n\n\tprog, err := ebpf.NewProgram(\n\t\t&ebpf.ProgramSpec{\n\t\t\tName: \"xdpcap_filter\",\n\t\t\tType: ebpf.XDP,\n\t\t\tInstructions: insns,\n\t\t\tLicense: \"GPL\",\n\t\t},\n\t)\n\tif err != nil {\n\t\treturn nil, errors.Wrap(err, \"loading filter\")\n\t}\n\n\treturn &program{\n\t\tprogram: prog,\n\t\tmetricsMap: metricsMap,\n\t}, nil\n}", "func (xdcrf *XDCRFactory) NewPipeline(topic string, progress_recorder common.PipelineProgressRecorder) (common.Pipeline, error) {\n\tspec, err := xdcrf.repl_spec_svc.ReplicationSpec(topic)\n\tif err != nil {\n\t\txdcrf.logger.Errorf(\"Failed to get replication specification for pipeline %v, err=%v\\n\", topic, err)\n\t\treturn nil, err\n\t}\n\txdcrf.logger.Debugf(\"replication specification = %v\\n\", spec)\n\n\tlogger_ctx := log.CopyCtx(xdcrf.default_logger_ctx)\n\tlogger_ctx.SetLogLevel(spec.Settings.LogLevel)\n\n\ttargetClusterRef, err := xdcrf.remote_cluster_svc.RemoteClusterByUuid(spec.TargetClusterUUID, false)\n\tif err != nil {\n\t\txdcrf.logger.Errorf(\"Error getting remote cluster with uuid=%v for pipeline %v, err=%v\\n\", spec.TargetClusterUUID, spec.Id, err)\n\t\treturn nil, err\n\t}\n\n\tnozzleType, err := xdcrf.getOutNozzleType(targetClusterRef, spec)\n\tif err != nil {\n\t\txdcrf.logger.Errorf(\"Failed to get the nozzle type for %v, err=%v\\n\", spec.Id, err)\n\t\treturn nil, err\n\t}\n\tisCapiReplication := (nozzleType == base.Capi)\n\n\tconnStr, err := xdcrf.remote_cluster_svc.GetConnectionStringForRemoteCluster(targetClusterRef, isCapiReplication)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\n\tusername, password, httpAuthMech, certificate, sanInCertificate, clientCertificate, clientKey, err := targetClusterRef.MyCredentials()\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\n\ttargetBucketInfo, err := xdcrf.utils.GetBucketInfo(connStr, spec.TargetBucketName, username, password, httpAuthMech, certificate, sanInCertificate, clientCertificate, clientKey, xdcrf.logger)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\n\tisTargetES := xdcrf.utils.CheckWhetherClusterIsESBasedOnBucketInfo(targetBucketInfo)\n\n\tconflictResolutionType, err := xdcrf.utils.GetConflictResolutionTypeFromBucketInfo(spec.TargetBucketName, targetBucketInfo)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\n\t// sourceCRMode is the conflict resolution mode to use when resolving conflicts for big documents at source side\n\t// capi replication always uses rev id based conflict resolution\n\tsourceCRMode := base.CRMode_RevId\n\tif !isCapiReplication {\n\t\t// for xmem replication, sourceCRMode is LWW if and only if target bucket is LWW enabled, so as to ensure that source side conflict\n\t\t// resolution and target side conflict resolution yield consistent results\n\t\tsourceCRMode = base.GetCRModeFromConflictResolutionTypeSetting(conflictResolutionType)\n\t}\n\n\txdcrf.logger.Infof(\"%v sourceCRMode=%v httpAuthMech=%v isCapiReplication=%v isTargetES=%v\\n\", topic, sourceCRMode, httpAuthMech, isCapiReplication, isTargetES)\n\n\t/**\n\t * Construct the Source nozzles\n\t * sourceNozzles - a map of DCPNozzleID -> *DCPNozzle\n\t * kv_vb_map - Map of SourceKVNode -> list of vbucket#'s that it's responsible for\n\t */\n\tsourceNozzles, kv_vb_map, err := xdcrf.constructSourceNozzles(spec, topic, isCapiReplication, logger_ctx)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\tif len(sourceNozzles) == 0 {\n\t\t// no pipeline is constructed if there is no source nozzle\n\t\treturn nil, base.ErrorNoSourceNozzle\n\t}\n\n\tprogress_recorder(fmt.Sprintf(\"%v source nozzles have been constructed\", len(sourceNozzles)))\n\n\txdcrf.logger.Infof(\"%v kv_vb_map=%v\\n\", topic, kv_vb_map)\n\t/**\n\t * Construct the outgoing (Destination) nozzles\n\t * 1. outNozzles - map of ID -> actual nozzle\n\t * 2. vbNozzleMap - map of VBucket# -> nozzle to be used (to be used by router)\n\t * 3. kvVBMap - map of remote KVNodes -> vbucket# responsible for per node\n\t */\n\toutNozzles, vbNozzleMap, target_kv_vb_map, targetUserName, targetPassword, targetClusterVersion, err :=\n\t\txdcrf.constructOutgoingNozzles(spec, kv_vb_map, sourceCRMode, targetBucketInfo, targetClusterRef, isCapiReplication, isTargetES, logger_ctx)\n\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\tprogress_recorder(fmt.Sprintf(\"%v target nozzles have been constructed\", len(outNozzles)))\n\n\t// TODO construct queue parts. This will affect vbMap in router. may need an additional outNozzle -> downStreamPart/queue map in constructRouter\n\n\t// construct routers to be able to connect the nozzles\n\tfor _, sourceNozzle := range sourceNozzles {\n\t\tvblist := sourceNozzle.(*parts.DcpNozzle).GetVBList()\n\t\tdownStreamParts := make(map[string]common.Part)\n\t\tfor _, vb := range vblist {\n\t\t\ttargetNozzleId, ok := vbNozzleMap[vb]\n\t\t\tif !ok {\n\t\t\t\treturn nil, fmt.Errorf(\"Error constructing pipeline %v since there is no target nozzle for vb=%v\", topic, vb)\n\t\t\t}\n\n\t\t\toutNozzle, ok := outNozzles[targetNozzleId]\n\t\t\tif !ok {\n\t\t\t\treturn nil, fmt.Errorf(\"%v There is no corresponding target nozzle for vb=%v, targetNozzleId=%v\", topic, vb, targetNozzleId)\n\t\t\t}\n\t\t\tdownStreamParts[targetNozzleId] = outNozzle\n\t\t}\n\n\t\t// Construct a router - each Source nozzle has a router.\n\t\trouter, err := xdcrf.constructRouter(sourceNozzle.Id(), spec, downStreamParts, vbNozzleMap, sourceCRMode, logger_ctx)\n\t\tif err != nil {\n\t\t\treturn nil, err\n\t\t}\n\t\tsourceNozzle.SetConnector(router)\n\t}\n\tprogress_recorder(\"Source nozzles have been wired to target nozzles\")\n\n\t// construct and initializes the pipeline\n\tpipeline := pp.NewPipelineWithSettingConstructor(topic, sourceNozzles, outNozzles, spec, targetClusterRef,\n\t\txdcrf.ConstructSettingsForPart, xdcrf.ConstructSettingsForConnector, xdcrf.ConstructSSLPortMap, xdcrf.ConstructUpdateSettingsForPart,\n\t\txdcrf.ConstructUpdateSettingsForConnector, xdcrf.SetStartSeqno, xdcrf.CheckpointBeforeStop, logger_ctx)\n\n\t// These listeners are the driving factors of the pipeline\n\txdcrf.registerAsyncListenersOnSources(pipeline, logger_ctx)\n\txdcrf.registerAsyncListenersOnTargets(pipeline, logger_ctx)\n\n\t// initialize component event listener map in pipeline\n\tpp.GetAllAsyncComponentEventListeners(pipeline)\n\n\t// Create PipelineContext\n\tif pipelineContext, err := pctx.NewWithSettingConstructor(pipeline, xdcrf.ConstructSettingsForService, xdcrf.ConstructUpdateSettingsForService, logger_ctx); err != nil {\n\n\t\treturn nil, err\n\t} else {\n\t\t//register services to the pipeline context, so when pipeline context starts as part of the pipeline starting, these services will start as well\n\t\tpipeline.SetRuntimeContext(pipelineContext)\n\t\terr = xdcrf.registerServices(pipeline, logger_ctx, kv_vb_map, targetUserName, targetPassword, spec.TargetBucketName, target_kv_vb_map, targetClusterRef, targetClusterVersion, isCapiReplication, isTargetES)\n\t\tif err != nil {\n\t\t\treturn nil, err\n\t\t}\n\t}\n\n\tprogress_recorder(\"Pipeline has been constructed\")\n\n\txdcrf.logger.Infof(\"Pipeline %v has been constructed\", topic)\n\treturn pipeline, nil\n}", "func newProcessRunner(pipeID string, p phono.Processor) (*processRunner, error) {\n\tfn, err := p.Process(pipeID)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\tr := processRunner{\n\t\tfn: fn,\n\t\tProcessor: p,\n\t\thooks: bindHooks(p),\n\t}\n\treturn &r, nil\n}", "func (g *Gitlab) CreatePipeline(pid, ref string) (*Pipeline, error) {\n\tvar pl Pipeline\n\tdata, err := g.buildAndExecRequest(\n\t\thttp.MethodPost,\n\t\tg.ResourceUrlWithQuery(\n\t\t\tpipelineCreationUrl,\n\t\t\tmap[string]string{\":id\": pid},\n\t\t\tmap[string]string{\"ref\": ref},\n\t\t),\n\t\tnil,\n\t)\n\tif nil != err {\n\t\treturn nil, fmt.Errorf(\"Request create pipeline API error: %v\", err)\n\t}\n\n\tif err := json.Unmarshal(data, &pl); nil != err {\n\t\treturn nil, fmt.Errorf(\"Decode response error: %v\", err)\n\t}\n\n\treturn &pl, nil\n}", "func Pipeline(cmds ...*exec.Cmd) (pipeLineOutput, collectedStandardError []byte, pipeLineError error) {\n\t// Require at least one command\n\tif len(cmds) < 1 {\n\t\treturn nil, nil, nil\n\t}\n\n\t// Collect the output from the command(s)\n\tvar output bytes.Buffer\n\tvar stderr bytes.Buffer\n\n\tlast := len(cmds) - 1\n\tfor i, cmd := range cmds[:last] {\n\t\tvar err error\n\t\t// Connect each command's stdin to the previous command's stdout\n\t\tif cmds[i+1].Stdin, err = cmd.StdoutPipe(); err != nil {\n\t\t\treturn nil, nil, err\n\t\t}\n\t\t// Connect each command's stderr to a buffer\n\t\tcmd.Stderr = &stderr\n\t}\n\n\t// Connect the output and error for the last command\n\tcmds[last].Stdout, cmds[last].Stderr = &output, &stderr\n\n\t// Start each command\n\tfor _, cmd := range cmds {\n\t\tif err := cmd.Start(); err != nil {\n\t\t\treturn output.Bytes(), stderr.Bytes(), err\n\t\t}\n\t}\n\n\t// Wait for each command to complete\n\tfor _, cmd := range cmds {\n\t\tif err := cmd.Wait(); err != nil {\n\t\t\treturn output.Bytes(), stderr.Bytes(), err\n\t\t}\n\t}\n\n\t// Return the pipeline output and the collected standard error\n\treturn output.Bytes(), stderr.Bytes(), nil\n}", "func Pipeline(cmds ...*exec.Cmd) (pipeLineOutput, collectedStandardError []byte, pipeLineError error) {\n\t// Require at least one command\n\tif len(cmds) < 1 {\n\t\treturn nil, nil, nil\n\t}\n\n\t// Collect the output from the command(s)\n\tvar output bytes.Buffer\n\tvar stderr bytes.Buffer\n\n\tlast := len(cmds) - 1\n\tfor i, cmd := range cmds[:last] {\n\t\tvar err error\n\t\t// Connect each command's stdin to the previous command's stdout\n\t\tif cmds[i+1].Stdin, err = cmd.StdoutPipe(); err != nil {\n\t\t\treturn nil, nil, err\n\t\t}\n\t\t// Connect each command's stderr to a buffer\n\t\tcmd.Stderr = &stderr\n\t}\n\n\t// Connect the output and error for the last command\n\tcmds[last].Stdout, cmds[last].Stderr = &output, &stderr\n\n\t// Start each command\n\tfor _, cmd := range cmds {\n\t\tif err := cmd.Start(); err != nil {\n\t\t\treturn output.Bytes(), stderr.Bytes(), err\n\t\t}\n\t}\n\n\t// Wait for each command to complete\n\tfor _, cmd := range cmds {\n\t\tif err := cmd.Wait(); err != nil {\n\t\t\treturn output.Bytes(), stderr.Bytes(), err\n\t\t}\n\t}\n\n\t// Return the pipeline output and the collected standard error\n\treturn output.Bytes(), stderr.Bytes(), nil\n}", "func Pipeline(cmds ...*exec.Cmd) (pipeLineOutput, collectedStandardError []byte, pipeLineError error) {\n\t// Require at least one command\n\tif len(cmds) < 1 {\n\t\treturn nil, nil, nil\n\t}\n\n\t// Collect the output from the command(s)\n\tvar output bytes.Buffer\n\tvar stderr bytes.Buffer\n\n\tlast := len(cmds) - 1\n\tfor i, cmd := range cmds[:last] {\n\t\tvar err error\n\t\t// Connect each command's stdin to the previous command's stdout\n\t\tif cmds[i+1].Stdin, err = cmd.StdoutPipe(); err != nil {\n\t\t\treturn nil, nil, err\n\t\t}\n\t\t// Connect each command's stderr to a buffer\n\t\tcmd.Stderr = &stderr\n\t}\n\n\t// Connect the output and error for the last command\n\tcmds[last].Stdout, cmds[last].Stderr = &output, &stderr\n\n\t// Start each command\n\tfor _, cmd := range cmds {\n\t\tif err := cmd.Start(); err != nil {\n\t\t\treturn output.Bytes(), stderr.Bytes(), err\n\t\t}\n\t}\n\n\t// Wait for each command to complete\n\tfor _, cmd := range cmds {\n\t\tif err := cmd.Wait(); err != nil {\n\t\t\treturn output.Bytes(), stderr.Bytes(), err\n\t\t}\n\t}\n\n\t// Return the pipeline output and the collected standard error\n\treturn output.Bytes(), stderr.Bytes(), nil\n}", "func StartPipeline(service *app.Service, stages ...Stage) *Pipeline {\n\tstartPipelineMutex.Lock()\n\tdefer startPipelineMutex.Unlock()\n\n\tif pipeline := GetPipeline(PipelineID(service.ID())); pipeline != nil {\n\t\treturn pipeline\n\t}\n\n\tcheckArgs := func() {\n\t\tif service == nil {\n\t\t\tpanic(\"A pipeline requires a service to run\")\n\t\t}\n\t\tif !service.Alive() {\n\t\t\tpanic(app.ServiceNotAliveError(service.ID()))\n\t\t}\n\t\tif len(stages) == 0 {\n\t\t\tpanic(\"A pipeline must have at least 1 stage\")\n\t\t}\n\t\tfor _, stage := range stages {\n\t\t\tif stage.Command().run == nil {\n\t\t\t\tpanic(fmt.Sprintf(\"Stage Command run function was nil for : ServiceID(0x%x)\", service.ID()))\n\t\t\t}\n\t\t}\n\n\t\tserviceID := service.ID()\n\t\tfor _, metricID := range COUNTER_METRIC_IDS {\n\t\t\tif app.MetricRegistry.Counter(serviceID, metricID) == nil {\n\t\t\t\tpanic(fmt.Sprintf(\"Counter metric is missing : MetricID(0x%x)\", metricID))\n\t\t\t}\n\t\t}\n\t\tfor _, metricID := range COUNTER_VECTOR_METRIC_IDS {\n\t\t\tif app.MetricRegistry.CounterVector(serviceID, metricID) == nil {\n\t\t\t\tpanic(fmt.Sprintf(\"Counter vector metric is missing : MetricID(0x%x)\", metricID))\n\t\t\t}\n\t\t}\n\t\tfor _, metricID := range GAUGE_METRIC_IDS {\n\t\t\tif app.MetricRegistry.Gauge(serviceID, metricID) == nil {\n\t\t\t\tpanic(fmt.Sprintf(\"Gauge metric is missing : MetricID(0x%x)\", metricID))\n\t\t\t}\n\t\t}\n\t}\n\n\tcheckArgs()\n\n\tserviceID := service.ID()\n\n\tpipeline := &Pipeline{\n\t\tService: service,\n\t\tstartedOn: time.Now(),\n\t\tin: make(chan context.Context),\n\t\tout: make(chan context.Context),\n\t\tstages: stages,\n\n\t\trunCounter: app.MetricRegistry.Counter(serviceID, PIPELINE_RUN_COUNT),\n\t\tfailedCounter: app.MetricRegistry.Counter(serviceID, PIPELINE_FAILED_COUNT),\n\t\tcontextExpiredCounter: app.MetricRegistry.Counter(serviceID, PIPELINE_CONTEXT_EXPIRED_COUNT),\n\t\tprocessingTime: app.MetricRegistry.Counter(serviceID, PIPELINE_PROCESSING_TIME_SEC),\n\t\tprocessingFailedTime: app.MetricRegistry.Counter(serviceID, PIPELINE_PROCESSING_TIME_SEC_FAILED),\n\t\tchannelDeliveryTime: app.MetricRegistry.Counter(serviceID, PIPELINE_CHANNEL_DELIVERY_TIME_SEC),\n\n\t\tpingPongCounter: app.MetricRegistry.Counter(serviceID, PIPELINE_PING_PONG_COUNT),\n\t\tpingPongTime: app.MetricRegistry.Counter(serviceID, PIPELINE_PING_PONG_TIME_SEC),\n\t\tpingExpiredCounter: app.MetricRegistry.Counter(serviceID, PIPELINE_PING_EXPIRED_COUNT),\n\t\tpingExpiredTime: app.MetricRegistry.Counter(serviceID, PIPELINE_PING_EXPIRED_TIME_SEC),\n\n\t\tconsecutiveSuccessCounter: app.MetricRegistry.Gauge(serviceID, PIPELINE_CONSECUTIVE_SUCCESS_COUNT),\n\t\tconsecutiveFailureCounter: app.MetricRegistry.Gauge(serviceID, PIPELINE_CONSECUTIVE_FAILURE_COUNT),\n\t\tconsecutiveExpiredCounter: app.MetricRegistry.Gauge(serviceID, PIPELINE_CONSECUTIVE_EXPIRED_COUNT),\n\n\t\tlastSuccessTime: app.MetricRegistry.Gauge(serviceID, PIPELINE_LAST_SUCCESS_TIME),\n\t\tlastFailureTime: app.MetricRegistry.Gauge(serviceID, PIPELINE_LAST_FAILURE_TIME),\n\t\tlastExpiredTime: app.MetricRegistry.Gauge(serviceID, PIPELINE_LAST_EXPIRED_TIME),\n\t\tlastPingSuccessTime: app.MetricRegistry.Gauge(serviceID, PIPELINE_LAST_PING_SUCCESS_TIME),\n\t\tlastPingExpiredTime: app.MetricRegistry.Gauge(serviceID, PIPELINE_LAST_PING_EXPIRED_TIME),\n\t}\n\n\tfirstStageCommandID := pipeline.stages[0].cmd.id\n\tvar build func(stages []Stage, in, out chan context.Context)\n\tbuild = func(stages []Stage, in, out chan context.Context) {\n\t\tcreateStageWorkers := func(stage Stage, process func(ctx context.Context)) {\n\t\t\tfor i := 0; i < int(stage.PoolSize()); i++ {\n\t\t\t\tif stage.cmd.id == firstStageCommandID {\n\t\t\t\t\tservice.Go(func() error {\n\t\t\t\t\t\tfor {\n\t\t\t\t\t\t\tselect {\n\t\t\t\t\t\t\tcase <-service.Dying():\n\t\t\t\t\t\t\t\treturn nil\n\t\t\t\t\t\t\tcase ctx := <-in:\n\t\t\t\t\t\t\t\tselect {\n\t\t\t\t\t\t\t\tcase <-ctx.Done():\n\t\t\t\t\t\t\t\t\tpipelineContextExpired(ctx, pipeline, stage.Command().CommandID()).Log(pipeline.Service.Logger())\n\t\t\t\t\t\t\t\tdefault:\n\t\t\t\t\t\t\t\t\t// record the time when the context started the workflow, i.e., entered the first stage of the pipeline\n\t\t\t\t\t\t\t\t\tctx = startWorkflowTimer(ctx)\n\t\t\t\t\t\t\t\t\tpipeline.runCounter.Inc()\n\t\t\t\t\t\t\t\t\tprocess(ctx)\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t})\n\t\t\t\t} else {\n\t\t\t\t\tservice.Go(func() error {\n\t\t\t\t\t\tfor {\n\t\t\t\t\t\t\tselect {\n\t\t\t\t\t\t\tcase <-service.Dying():\n\t\t\t\t\t\t\t\treturn nil\n\t\t\t\t\t\t\tcase ctx := <-in:\n\t\t\t\t\t\t\t\tselect {\n\t\t\t\t\t\t\t\tcase <-ctx.Done():\n\t\t\t\t\t\t\t\t\tpipelineContextExpired(ctx, pipeline, stage.Command().CommandID()).Log(pipeline.Service.Logger())\n\t\t\t\t\t\t\t\tdefault:\n\t\t\t\t\t\t\t\t\tprocess(ctx)\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t})\n\t\t\t\t}\n\n\t\t\t}\n\t\t}\n\t\tstage := stages[0]\n\t\tif len(stages) == 1 {\n\t\t\tcreateStageWorkers(stage, func(ctx context.Context) {\n\t\t\t\tif IsPing(ctx) {\n\t\t\t\t\t// reply with pong\n\t\t\t\t\tctx = withPong(ctx)\n\t\t\t\t\tout, ok := OutputChannel(ctx)\n\t\t\t\t\tif !ok {\n\t\t\t\t\t\tout = pipeline.out\n\t\t\t\t\t}\n\n\t\t\t\t\tselect {\n\t\t\t\t\tcase <-service.Dying():\n\t\t\t\t\tcase <-ctx.Done():\n\t\t\t\t\t\tpipelineContextExpired(ctx, pipeline, stage.Command().CommandID()).Log(pipeline.Service.Logger())\n\t\t\t\t\tcase out <- ctx:\n\t\t\t\t\t\tpipeline.lastPingSuccessTime.Set(float64(time.Now().Unix()))\n\t\t\t\t\t}\n\t\t\t\t\treturn\n\t\t\t\t}\n\n\t\t\t\tresult := stage.run(ctx)\n\t\t\t\tprocessedTime := time.Now()\n\t\t\t\tprocessingDuration := time.Now().Sub(WorkflowStartTime(ctx))\n\t\t\t\tworkflowTime := processingDuration.Seconds()\n\t\t\t\tpipeline.processingTime.Add(workflowTime)\n\t\t\t\tif err := Error(result); err != nil {\n\t\t\t\t\tcontextFailed(pipeline, ctx)\n\t\t\t\t\tpipeline.failedCounter.Inc()\n\t\t\t\t\tpipeline.processingFailedTime.Add(workflowTime)\n\t\t\t\t\tresult = WithError(result, stage.Command().id, err)\n\t\t\t\t\tpipeline.lastFailureTime.Set(float64(time.Now().Unix()))\n\t\t\t\t\tpipeline.consecutiveFailureCounter.Inc()\n\t\t\t\t\tpipeline.consecutiveSuccessCounter.Set(0)\n\t\t\t\t}\n\n\t\t\t\tout, ok := OutputChannel(result)\n\t\t\t\tif !ok {\n\t\t\t\t\tout = pipeline.out\n\t\t\t\t}\n\n\t\t\t\tselect {\n\t\t\t\tcase <-service.Dying():\n\t\t\t\t\treturn\n\t\t\t\tcase <-result.Done():\n\t\t\t\t\tpipelineContextExpired(result, pipeline, stage.Command().CommandID()).Log(pipeline.Service.Logger())\n\t\t\t\tcase out <- result:\n\t\t\t\t\tdeliveryTime := time.Now().Sub(processedTime).Seconds()\n\t\t\t\t\tpipeline.channelDeliveryTime.Add(deliveryTime)\n\n\t\t\t\t\tif Error(result) == nil {\n\t\t\t\t\t\tpipeline.lastSuccessTime.Set(float64(time.Now().Unix()))\n\t\t\t\t\t\tpipeline.consecutiveSuccessCounter.Inc()\n\t\t\t\t\t\tpipeline.consecutiveFailureCounter.Set(0)\n\t\t\t\t\t\tpipeline.consecutiveExpiredCounter.Set(0)\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t})\n\t\t\treturn\n\t\t}\n\n\t\tcreateStageWorkers(stage, func(ctx context.Context) {\n\t\t\tif IsPing(ctx) {\n\t\t\t\t// send the context downstream, i.e., to the next stage\n\t\t\t\tselect {\n\t\t\t\tcase <-service.Dying():\n\t\t\t\tcase <-ctx.Done():\n\t\t\t\t\tpipelineContextExpired(ctx, pipeline, stage.Command().CommandID()).Log(pipeline.Service.Logger())\n\t\t\t\tcase out <- ctx:\n\t\t\t\t}\n\t\t\t\treturn\n\t\t\t}\n\n\t\t\tresult := stage.run(ctx)\n\t\t\tprocessedTime := time.Now()\n\t\t\tif err := Error(result); err != nil {\n\t\t\t\tcontextFailed(pipeline, ctx)\n\t\t\t\tpipeline.failedCounter.Inc()\n\t\t\t\tresult = WithError(result, stage.Command().id, err)\n\t\t\t\tpipeline.lastFailureTime.Set(float64(time.Now().Unix()))\n\t\t\t\tselect {\n\t\t\t\tcase <-service.Dying():\n\t\t\t\t\treturn\n\t\t\t\tcase <-result.Done():\n\t\t\t\t\tpipelineContextExpired(result, pipeline, stage.Command().CommandID()).Log(pipeline.Service.Logger())\n\t\t\t\tcase pipeline.out <- result:\n\t\t\t\t\tdeliveryTime := time.Now().Sub(processedTime).Seconds()\n\t\t\t\t\tpipeline.channelDeliveryTime.Add(deliveryTime)\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\tselect {\n\t\t\t\tcase <-service.Dying():\n\t\t\t\t\treturn\n\t\t\t\tcase <-result.Done():\n\t\t\t\t\tpipelineContextExpired(result, pipeline, stage.Command().CommandID()).Log(pipeline.Service.Logger())\n\t\t\t\tcase out <- result:\n\t\t\t\t\tdeliveryTime := time.Now().Sub(processedTime).Seconds()\n\t\t\t\t\tpipeline.channelDeliveryTime.Add(deliveryTime)\n\t\t\t\t}\n\t\t\t}\n\t\t})\n\n\t\tbuild(stages[1:], out, make(chan context.Context))\n\t}\n\n\tbuild(stages, pipeline.in, make(chan context.Context))\n\n\tgo func() {\n\t\tdefer unregisterPipeline(pipeline.ID())\n\t\tselect {\n\t\tcase <-service.Dying():\n\t\tcase <-app.Dying():\n\t\t}\n\t}()\n\n\tregisterPipeline(pipeline)\n\tapp.SERVICE_STARTED.Log(service.Logger().Info()).Msg(\"Pipeline started\")\n\n\treturn pipeline\n}", "func NewProgram(cfg *client.Config, parentName string) *tea.Program {\n\tm := NewModel(cfg)\n\tm.standalone = true\n\tm.parentName = parentName\n\treturn tea.NewProgram(m)\n}", "func main() {\n\tadapter.RunStage(split, chunk, join)\n}", "func InitPipeline(pipelineType *pipeline.Definition,\n\tpipelineArguments *PipelineArguments,\n\tstepImplementations ...Step) (*PipelineInfo, error) {\n\n\ttimestamp := time.Now().Format(\"20060102150405\")\n\thash := strings.ToLower(utils.RandStringStrSeed(5, pipelineArguments.JobName))\n\tradixConfigMapName := fmt.Sprintf(\"radix-config-2-map-%s-%s-%s\", timestamp, pipelineArguments.ImageTag, hash)\n\tgitConfigFileName := fmt.Sprintf(\"radix-git-information-%s-%s-%s\", timestamp, pipelineArguments.ImageTag, hash)\n\n\tpodSecContext := securitycontext.Pod(securitycontext.WithPodFSGroup(fsGroup),\n\t\tsecuritycontext.WithPodSeccompProfile(corev1.SeccompProfileTypeRuntimeDefault))\n\tcontainerSecContext := securitycontext.Container(securitycontext.WithContainerDropAllCapabilities(),\n\t\tsecuritycontext.WithContainerSeccompProfile(corev1.SeccompProfileTypeRuntimeDefault),\n\t\tsecuritycontext.WithContainerRunAsGroup(runAsGroup),\n\t\tsecuritycontext.WithContainerRunAsUser(runAsUser))\n\n\tpipelineArguments.ContainerSecurityContext = *containerSecContext\n\tpipelineArguments.PodSecurityContext = *podSecContext\n\n\tstepImplementationsForType, err := getStepStepImplementationsFromType(pipelineType, stepImplementations...)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\n\treturn &PipelineInfo{\n\t\tDefinition: pipelineType,\n\t\tPipelineArguments: *pipelineArguments,\n\t\tSteps: stepImplementationsForType,\n\t\tRadixConfigMapName: radixConfigMapName,\n\t\tGitConfigMapName: gitConfigFileName,\n\t}, nil\n}", "func PipelineFromContext(ctx *cli.Context) drone.Pipeline {\n\treturn drone.Pipeline{\n\t\tBuild: buildFromContext(ctx),\n\t\tRepo: repoFromContext(ctx),\n\t\tCommit: commitFromContext(ctx),\n\t\tStage: stageFromContext(ctx),\n\t\tStep: stepFromContext(ctx),\n\t\tSemVer: semVerFromContext(ctx),\n\t\tCalVer: calVerFromContext(ctx),\n\t\tSystem: systemFromContext(ctx),\n\t}\n}", "func Pipeline(runners ...Runner) Runner {\n\tif len(runners) == 0 {\n\t\tpanic(\"at least 1 runner is required for pipelining\")\n\t}\n\n\t// flatten nested pipelines. note we should examine only first level, as any\n\t// pre-created pipeline was already flatten during its creation\n\tvar flat pipeline\n\tfor _, r := range runners {\n\t\tp, isPipe := r.(pipeline)\n\t\tif isPipe {\n\t\t\tflat = append(flat, p...)\n\t\t} else {\n\t\t\tflat = append(flat, r)\n\t\t}\n\t}\n\n\t// filter out passThrough runners as they don't affect the pipe\n\tfiltered := flat[:0]\n\tfor _, r := range flat {\n\t\tif r != passThroughSingleton {\n\t\t\tfiltered = append(filtered, r)\n\t\t}\n\t}\n\n\tif len(filtered) == 0 {\n\t\t// all runners were filtered, pipe should simply return its output as is\n\t\treturn PassThrough()\n\t} else if len(filtered) == 1 {\n\t\treturn filtered[0] // only one runner left, no need for a pipeline\n\t}\n\n\tif cmp, ok := createComposeRunner(runners); ok {\n\t\treturn cmp\n\t}\n\treturn filtered\n}", "func NewPar(P, Q Process) *Par { return &Par{Procs: []Process{P, Q}} }", "func main() {\n\tfmt.Println(\"Start Test....!\")\n\tinputDB := setupDB(\"mysql\", \"root:root123@tcp(127.0.0.1:13306)/srcDB\")\n\textractDP := processors.NewSQLReader(inputDB, mypkg.Query(5))\n\n\ttransformDP := mypkg.NewMyTransformer()\n\tfmt.Println(transformDP)\n\n\toutputDB := setupDB(\"mysql\", \"root:root123@tcp(127.0.0.1:13306)/dstDB\")\n\toutputTable := \"krew_info\"\n\tloadDP := processors.NewSQLWriter(outputDB, outputTable)\n\n\tpipeline := ratchet.NewPipeline(extractDP, transformDP, loadDP)\n\tpipeline.Name = \"My Pipeline\"\n\n\terr := <-pipeline.Run()\n\tif err != nil {\n\t\tlogger.ErrorWithoutTrace(pipeline.Name, \":\", err)\n\t\tlogger.ErrorWithoutTrace(pipeline.Stats())\n\t} else {\n\t\tlogger.Info(pipeline.Name, \": Completed successfully.\")\n\t}\n}", "func main() {\n\tb := specs.MustNewTasksCfgBuilder()\n\n\t// Create Tasks and Jobs.\n\tfor _, name := range JOBS {\n\t\tprocess(b, name)\n\t}\n\n\tb.MustFinish()\n}", "func newProgGen(factory progFactory) (Program, error) {\n\t// Test the factory to make sure that configuration errors are spotted at config\n\t_, err := factory(interpreter.NewEvalState(), &interpreter.CostTracker{})\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\treturn &progGen{factory: factory}, nil\n}", "func CICreate(pid interface{}, opts *gitlab.CreatePipelineOptions) (*gitlab.Pipeline, error) {\n\tp, _, err := lab.Pipelines.CreatePipeline(pid, opts)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\treturn p, nil\n}", "func (p *PipelineDefinition) Pipelines() (*Pipelines, error) {\n\tif p.pipelines == nil {\n\t\t// Collect ignored and selected step names\n\t\tignoredSteps := types.StringSet{}\n\t\tselectedSteps := types.StringSet{}\n\t\tfor name, step := range p.Steps {\n\t\t\tif step.Meta.Ignore {\n\t\t\t\tignoredSteps[name] = true\n\t\t\t}\n\t\t\tif step.Meta.Selected {\n\t\t\t\tselectedSteps[name] = true\n\t\t\t\tif step.Meta.Ignore {\n\t\t\t\t\treturn nil, fmt.Errorf(\"instructed to ignore selected step '%s'\", step.Name)\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\t// If steps or services are marked es selected, expand the selection\n\t\tqueue := make([]string, 0)\n\t\tfor name := range selectedSteps {\n\t\t\tqueue = append(queue, name)\n\t\t}\n\t\tfor len(queue) > 0 {\n\t\t\tname := queue[0]\n\t\t\tqueue = queue[1:]\n\t\t\tif s, ok := p.Steps[name]; ok {\n\t\t\t\tif s.Meta.Ignore {\n\t\t\t\t\tcontinue\n\t\t\t\t}\n\t\t\t\tfor dep := range s.Dependencies() {\n\t\t\t\t\tqueue = append(queue, dep)\n\t\t\t\t}\n\t\t\t\tif s.Meta.Selected {\n\t\t\t\t\tcontinue\n\t\t\t\t}\n\t\t\t\ts.Meta.Selected = true\n\t\t\t\tselectedSteps[name] = true\n\t\t\t\tp.Steps[name] = s\n\t\t\t}\n\t\t}\n\t\tif len(selectedSteps) > 0 {\n\t\t\t// Ignore all not selected steps\n\t\t\tfor name, step := range p.Steps {\n\t\t\t\tif step.Meta.Selected {\n\t\t\t\t\tcontinue\n\t\t\t\t}\n\t\t\t\tstep.Meta.Ignore = true\n\t\t\t\tp.Steps[name] = step\n\t\t\t\tignoredSteps[name] = true\n\t\t\t}\n\t\t}\n\n\t\t// Build list of active steps\n\t\tsteps := make(map[string]Step)\n\t\tfor name, step := range p.Steps {\n\t\t\tsteps[name] = step\n\t\t}\n\t\t// Calculate order and indepenence\n\t\tpipelines, err := NewTarjan(steps)\n\t\tif err != nil {\n\t\t\treturn nil, err\n\t\t}\n\t\t// Verify pipelines\n\t\terr = pipelines.Check()\n\t\tif err != nil {\n\t\t\treturn nil, err\n\t\t}\n\t\tp.pipelines = pipelines\n\t}\n\treturn p.pipelines, nil\n}", "func (p *Pipeline) Run() error {\n\n\tif p.generator == nil {\n\t\tif p.config.Logger != nil {\n\t\t\tp.config.Logger.Println(\"source=pipeline, error='generator cannot be nil'\")\n\t\t}\n\t\treturn ErrNilGenerator\n\t}\n\n\tif len(p.stages) == 0 {\n\t\tif p.config.Logger != nil {\n\t\t\tp.config.Logger.Println(\"source=pipeline, error='there are no stages defined'\")\n\t\t}\n\t\treturn ErrNoStages\n\t}\n\n\tif p.config.Logger != nil {\n\t\tp.config.Logger.Printf(\"source=pipeline, notice=config, generator='%v', buffered=%v, concurrency=%v, verbose=%v\\n\", p.generator.Name(), p.config.Buffered, !p.config.NoConcurrency, p.config.Verbose)\n\t\tfor _, s := range p.stages {\n\t\t\tp.config.Logger.Printf(\"source=pipeline, notice=config, stage='%v', concurrency=%v\\n\", s.Name(), p.concurrency(s))\n\t\t}\n\t}\n\n\tif p.config.Logger != nil && p.config.Verbose {\n\t\tp.config.Logger.Println(\"source=pipeline, action=starting\")\n\t}\n\n\tgo func() {\n\t\tdefer close(p.channels[0])\n\t\tfor {\n\t\t\tjob := p.generator.Next()\n\t\t\tif job != nil {\n\t\t\t\tp.channels[0] <- job\n\t\t\t} else {\n\t\t\t\tif p.config.Logger != nil && p.config.Verbose {\n\t\t\t\t\tp.config.Logger.Println(\"source=pipeline, action=closing\")\n\t\t\t\t}\n\t\t\t\tbreak // will execute the deferred close of the channel\n\t\t\t}\n\t\t}\n\t}()\n\n\t// launch all the stages\n\t// read from the previous stage\n\t// write to the next\n\tfor idx, s := range p.stages {\n\t\tif p.config.Logger != nil && p.config.Verbose {\n\t\t\tp.config.Logger.Printf(\"source=pipeline, action=launching, stage='%v', concurrency=%v\\n\", s.Name(), p.concurrency(s))\n\t\t}\n\n\t\twg := &sync.WaitGroup{}\n\t\t// set cfg.NoConcurrency = true if you want 1 goroutine each; helps w/ debugging\n\t\tfor id := 0; id < p.concurrency(s); id++ {\n\t\t\twg.Add(1)\n\t\t\tgo stage(p.channels[idx], p.channels[idx+1], id, wg, s, p.config.Logger, p.config.Verbose)\n\t\t}\n\t}\n\n\t// drain the last channel\n\tfor range p.channels[len(p.channels)-1] {\n\t}\n\n\tif p.config.Logger != nil && p.config.Verbose {\n\t\tp.config.Logger.Println(\"source=pipeline, action=terminating\")\n\t}\n\n\treturn nil\n}", "func NewProgram() *Program {\n\treturn &Program{\n\t\tframe: EmptyFrame(),\n\t}\n}", "func New(sqsSvc *sqs.SQS, lambdaSvc *lambda.Lambda, db *dynamodb.DynamoDB, envName string) *PipelineManager {\n\treturn &PipelineManager{\n\t\tsqsSvc: sqsSvc,\n\t\tlambdaSvc: lambdaSvc,\n\t\tdb: db,\n\t\tenvName: envName,\n\t}\n}", "func main() {\n\tlines := util.ReadLines()\n\n\tansP1, ansP2 := Exec(lines)\n\tfmt.Printf(\"Part1: %v\\n\", ansP1)\n\tfmt.Printf(\"Part2: %v\\n\", ansP2)\n}", "func create(s string) (p program) {\n\tre := regexp.MustCompile(`\\w+`)\n\tt := re.FindAllStringSubmatch(s, -1)\n\tp.name = t[0][0]\n\tp.weight, _ = strconv.Atoi(string(t[1][0]))\n\tfor _, r := range t[2:] {\n\t\tp.children = append(p.children, program{r[0], 0, nil})\n\t}\n\treturn\n}", "func (b *Builder) Pipeline() (*types.SpinnakerPipeline, error) {\n\tsp := &types.SpinnakerPipeline{\n\t\tLimitConcurrent: b.pipeline.DisableConcurrentExecutions,\n\t\tKeepWaitingPipelines: b.pipeline.KeepQueuedPipelines,\n\t\tDescription: b.pipeline.Description,\n\t\tAppConfig: map[string]interface{}{},\n\t}\n\n\tsp.Notifications = buildNotifications(b.pipeline.Notifications)\n\tsp.Triggers = make([]types.Trigger, 0)\n\n\tfor _, trigger := range b.pipeline.Triggers {\n\t\tif jt := trigger.Jenkins; jt != nil {\n\t\t\tsp.Triggers = append(sp.Triggers, &types.JenkinsTrigger{\n\t\t\t\tTriggerObject: types.TriggerObject{\n\t\t\t\t\tEnabled: newDefaultTrue(jt.Enabled),\n\t\t\t\t\tType: JenkinsTrigger,\n\t\t\t\t},\n\n\t\t\t\tJob: jt.Job,\n\t\t\t\tMaster: jt.Master,\n\t\t\t\tPropertyFile: jt.PropertyFile,\n\t\t\t})\n\t\t}\n\n\t\tif wh := trigger.Webhook; wh != nil {\n\t\t\tsp.Triggers = append(sp.Triggers, &types.WebhookTrigger{\n\t\t\t\tTriggerObject: types.TriggerObject{\n\t\t\t\t\tEnabled: wh.Enabled,\n\t\t\t\t\tType: WebhookTrigger,\n\t\t\t\t},\n\t\t\t\tSource: wh.Source,\n\t\t\t})\n\t\t}\n\t}\n\n\tsp.Parameters = make([]types.Parameter, len(b.pipeline.Parameters))\n\tfor i, param := range b.pipeline.Parameters {\n\t\tsp.Parameters[i] = types.Parameter{\n\t\t\tName: param.Name,\n\t\t\tDescription: param.Description,\n\t\t\tDefault: param.Default,\n\t\t\tRequired: param.Required,\n\t\t}\n\n\t\tif len(param.Options) > 0 {\n\t\t\tsp.Parameters[i].HasOptions = true\n\t\t\tfoundDefaultValue := param.Default == \"\"\n\t\t\tfor _, val := range param.Options {\n\t\t\t\tfoundDefaultValue = foundDefaultValue || param.Default == val.Value\n\t\t\t\tsp.Parameters[i].Options = append(sp.Parameters[i].Options, types.Option{\n\t\t\t\t\tValue: val.Value,\n\t\t\t\t})\n\t\t\t}\n\t\t\tif !foundDefaultValue {\n\t\t\t\treturn sp, errors.New(\"builder: the specified default value is not one of the options\")\n\t\t\t}\n\t\t}\n\t}\n\n\tvar stageIndex = 0\n\tfor _, stage := range b.pipeline.Stages {\n\t\tvar s types.Stage\n\t\tvar err error\n\n\t\t// if the account has an override, switch the account name\n\t\tif account, ok := b.overrideAccounts[stage.Account]; ok {\n\t\t\tstage.Account = account\n\t\t}\n\n\t\tif stage.RunJob != nil {\n\t\t\ts, err = b.buildRunJobStage(stageIndex, stage)\n\t\t\tif err != nil {\n\t\t\t\treturn sp, fmt.Errorf(\"Failed to b.buildRunJobStage with error: %v\", err)\n\t\t\t}\n\t\t\tstageIndex = stageIndex + 1\n\t\t}\n\t\tif stage.Deploy != nil {\n\t\t\ts, err = b.buildDeployStage(stageIndex, stage)\n\t\t\tif err != nil {\n\t\t\t\treturn sp, fmt.Errorf(\"Failed to b.buildDeployStage with error: %v\", err)\n\t\t\t}\n\t\t\tstageIndex = stageIndex + 1\n\t\t}\n\n\t\tif stage.ManualJudgement != nil {\n\t\t\ts, err = b.buildManualJudgementStage(stageIndex, stage)\n\t\t\tif err != nil {\n\t\t\t\treturn sp, fmt.Errorf(\"Failed to buildManualJudgementStage with error: %v\", err)\n\t\t\t}\n\t\t\tstageIndex = stageIndex + 1\n\t\t}\n\n\t\tif stage.DeployEmbeddedManifests != nil {\n\t\t\ts, err = b.buildDeployEmbeddedManifestStage(stageIndex, stage)\n\t\t\tif err != nil {\n\t\t\t\treturn sp, fmt.Errorf(\"Failed to buildDeployEmbeddedManifestStage with error: %s\", err)\n\t\t\t}\n\t\t\tstageIndex = stageIndex + 1\n\t\t}\n\n\t\tif stage.DeleteEmbeddedManifest != nil {\n\t\t\ts, err = b.buildDeleteEmbeddedManifestStage(stageIndex, stage)\n\t\t\tif err != nil {\n\t\t\t\treturn sp, fmt.Errorf(\"Failed to buildDeleteEmbeddedManifestStage with error: %v\", err)\n\t\t\t}\n\t\t\tstageIndex = stageIndex + 1\n\t\t}\n\n\t\tif stage.ScaleManifest != nil {\n\t\t\ts, err = b.buildScaleManifestStage(stageIndex, stage)\n\t\t\tif err != nil {\n\t\t\t\treturn sp, fmt.Errorf(\"Failed to buildScaleManifestStage with error: %v\", err)\n\t\t\t}\n\t\t\tstageIndex = stageIndex + 1\n\t\t}\n\n\t\tif stage.WebHook != nil {\n\t\t\ts, err = b.buildWebHookStage(stageIndex, stage)\n\t\t\tif err != nil {\n\t\t\t\treturn sp, fmt.Errorf(\"Failed to webhook stage with error: %v\", err)\n\t\t\t}\n\t\t\tstageIndex = stageIndex + 1\n\t\t}\n\n\t\tif stage.Jenkins != nil {\n\t\t\ts, err = b.buildJenkinsStage(stageIndex, stage)\n\t\t\tif err != nil {\n\t\t\t\treturn sp, fmt.Errorf(\"Failed to build jenkins stage with error: %v\", err)\n\t\t\t}\n\t\t\tstageIndex = stageIndex + 1\n\t\t}\n\n\t\tif stage.EvaluateVariables != nil {\n\t\t\ts, err = b.buildEvaluateVariablesStage(stageIndex, stage)\n\t\t\tif err != nil {\n\t\t\t\treturn sp, fmt.Errorf(\"failed to build evaluate variables stage with error: %v\", err)\n\t\t\t}\n\t\t\tstageIndex++\n\t\t}\n\n\t\tif stage.RunSpinnakerPipeline != nil {\n\t\t\ts, err = b.buildRunSpinnakerPipelineStage(stageIndex, stage)\n\t\t\tif err != nil {\n\t\t\t\treturn sp, fmt.Errorf(\"Failed to build spinnaker pipeline stage with error: %v\", err)\n\t\t\t}\n\t\t\tstageIndex = stageIndex + 1\n\t\t}\n\n\t\tsp.Stages = append(sp.Stages, s)\n\t}\n\n\treturn sp, nil\n}", "func (c *client) compileStages(p *yaml.Build, _pipeline *library.Pipeline, tmpls map[string]*yaml.Template, r *pipeline.RuleData) (*pipeline.Build, *library.Pipeline, error) {\n\tvar err error\n\n\t// check if the pipeline disabled the clone\n\tif p.Metadata.Clone == nil || *p.Metadata.Clone {\n\t\t// inject the clone stage\n\t\tp, err = c.CloneStage(p)\n\t\tif err != nil {\n\t\t\treturn nil, _pipeline, err\n\t\t}\n\t}\n\n\t// inject the init stage\n\tp, err = c.InitStage(p)\n\tif err != nil {\n\t\treturn nil, _pipeline, err\n\t}\n\n\t// inject the templates into the stages\n\tp, err = c.ExpandStages(p, tmpls, r)\n\tif err != nil {\n\t\treturn nil, _pipeline, err\n\t}\n\n\tif c.ModificationService.Endpoint != \"\" {\n\t\t// send config to external endpoint for modification\n\t\tp, err = c.modifyConfig(p, c.build, c.repo)\n\t\tif err != nil {\n\t\t\treturn nil, _pipeline, err\n\t\t}\n\t}\n\n\t// validate the yaml configuration\n\terr = c.Validate(p)\n\tif err != nil {\n\t\treturn nil, _pipeline, err\n\t}\n\n\t// Create some default global environment inject vars\n\t// these are used below to overwrite to an empty\n\t// map if they should not be injected into a container\n\tenvGlobalServices, envGlobalSecrets, envGlobalSteps := p.Environment, p.Environment, p.Environment\n\n\tif !p.Metadata.HasEnvironment(\"services\") {\n\t\tenvGlobalServices = make(raw.StringSliceMap)\n\t}\n\n\tif !p.Metadata.HasEnvironment(\"secrets\") {\n\t\tenvGlobalSecrets = make(raw.StringSliceMap)\n\t}\n\n\tif !p.Metadata.HasEnvironment(\"steps\") {\n\t\tenvGlobalSteps = make(raw.StringSliceMap)\n\t}\n\n\t// inject the environment variables into the services\n\tp.Services, err = c.EnvironmentServices(p.Services, envGlobalServices)\n\tif err != nil {\n\t\treturn nil, _pipeline, err\n\t}\n\n\t// inject the environment variables into the secrets\n\tp.Secrets, err = c.EnvironmentSecrets(p.Secrets, envGlobalSecrets)\n\tif err != nil {\n\t\treturn nil, _pipeline, err\n\t}\n\n\t// inject the environment variables into the stages\n\tp.Stages, err = c.EnvironmentStages(p.Stages, envGlobalSteps)\n\tif err != nil {\n\t\treturn nil, _pipeline, err\n\t}\n\n\t// inject the substituted environment variables into the stages\n\tp.Stages, err = c.SubstituteStages(p.Stages)\n\tif err != nil {\n\t\treturn nil, _pipeline, err\n\t}\n\n\t// inject the scripts into the stages\n\tp.Stages, err = c.ScriptStages(p.Stages)\n\tif err != nil {\n\t\treturn nil, _pipeline, err\n\t}\n\n\t// create executable representation\n\tbuild, err := c.TransformStages(r, p)\n\tif err != nil {\n\t\treturn nil, _pipeline, err\n\t}\n\n\treturn build, _pipeline, nil\n}", "func Pipeline(list ...*Cmd) (string, string, error) {\n\tvar output bytes.Buffer\n\tvar stderr bytes.Buffer\n\tvar err error\n\n\t// Require at least one command\n\tif len(list) < 1 {\n\t\treturn \"\", \"\", nil\n\t}\n\n\tvar newCmd *exec.Cmd\n\tcmds := make([]*exec.Cmd, 0, 4)\n\n\t// Convert into an exec.Cmd\n\tfor _, cmd := range list {\n\t\tnewCmd = exec.Command(cmd.Name, cmd.Args...)\n\t\tcmds = append(cmds, newCmd)\n\t}\n\n\t// Collect the output from the command(s)\n\tlast := len(cmds) - 1\n\tfor i, cmd := range cmds[:last] {\n\t\t// Connect each command's stdin to the previous command's stdout\n\t\tif cmds[i+1].Stdin, err = cmd.StdoutPipe(); err != nil {\n\t\t\treturn \"\", \"\", err\n\t\t}\n\t\t// Connect each command's stderr to a buffer\n\t\tcmd.Stderr = &stderr\n\t}\n\n\t// Connect the output and error for the last command\n\tcmds[last].Stdout, cmds[last].Stderr = &output, &stderr\n\n\t// Start each command\n\tfor _, cmd := range cmds {\n\t\tif err = cmd.Start(); err != nil {\n\t\t\treturn output.String(), stderr.String(), err\n\t\t}\n\t}\n\n\t// Wait for each command to complete\n\tfor _, cmd := range cmds {\n\t\tif err := cmd.Wait(); err != nil {\n\t\t\treturn output.String(), stderr.String(), err\n\t\t}\n\t}\n\n\t// Return the pipeline output and the collected standard error\n\treturn output.String(), stderr.String(), nil\n}", "func connectPipeline(commandList []exec.Cmd) error {\n\tvar err error\n\n\tfor i := range commandList {\n\t\tif i == len(commandList)-1 {\n\t\t\tbreak\n\t\t}\n\t\tif commandList[i+1].Stdin != nil || commandList[i].Stdout != nil {\n\t\t\treturn errors.New(\"Ambiguous input for file redirection and pipe\")\n\t\t}\n\t\tcommandList[i+1].Stdin, err = commandList[i].StdoutPipe()\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t}\n\tif commandList[0].Stdin == nil {\n\t\tcommandList[0].Stdin = os.Stdin\n\t}\n\tif commandList[len(commandList)-1].Stdout == nil {\n\t\tcommandList[len(commandList)-1].Stdout = os.Stdout\n\t}\n\treturn nil\n}", "func BindProgramPipeline(pipeline uint32) {\n\tsyscall.Syscall(gpBindProgramPipeline, 1, uintptr(pipeline), 0, 0)\n}", "func (es *Connection) CreatePipeline(\n\tid string,\n\tparams map[string]string,\n\tbody interface{},\n) (int, *QueryResult, error) {\n\treturn withQueryResult(es.apiCall(\"PUT\", \"_ingest\", \"pipeline\", id, \"\", params, body))\n}", "func main() {\n\tfmt.Println(\"Start Test....!\")\n\tinputDB := setupDB(\"mysql\", \"root:root123@tcp(127.0.0.1:13306)/srcDB\")\n\textractDP := processors.NewSQLReader(inputDB, mypkg.Query(5))\n\n\toutputDB := setupDB(\"mysql\", \"root:root123@tcp(127.0.0.1:13306)/dstDB\")\n\toutputTable := \"users2\"\n\tloadDP := processors.NewSQLWriter(outputDB, outputTable)\n\n\tpipeline := ratchet.NewPipeline(extractDP, loadDP)\n\tpipeline.Name = \"My Pipeline\"\n\n\t// To see debugging output, uncomment the following lines:\n\t// logger.LogLevel = logger.LevelDebug\n\t// pipeline.PrintData = true\n\n\terr := <-pipeline.Run()\n\tif err != nil {\n\t\tlogger.ErrorWithoutTrace(pipeline.Name, \":\", err)\n\t\tlogger.ErrorWithoutTrace(pipeline.Stats())\n\t} else {\n\t\tlogger.Info(pipeline.Name, \": Completed successfully.\")\n\t}\n}", "func CreateCIPipeline(name types.NamespacedName, stageNamespace string) *pipelinev1.Pipeline {\n\treturn &pipelinev1.Pipeline{\n\t\tTypeMeta: pipelineTypeMeta,\n\t\tObjectMeta: meta.ObjectMeta(name),\n\t\tSpec: pipelinev1.PipelineSpec{\n\n\t\t\tResources: []pipelinev1.PipelineDeclaredResource{\n\t\t\t\tcreatePipelineDeclaredResource(\"source-repo\", \"git\"),\n\t\t\t},\n\n\t\t\tTasks: []pipelinev1.PipelineTask{\n\t\t\t\tcreateCommitStatusPipelineTask(PendingCommitStatusTask, \"pending\", \"The build has started\"),\n\t\t\t\tcreateCIPipelineTask(\"apply-source\"),\n\t\t\t},\n\t\t\tParams: paramSpecs(\"REPO\", \"COMMIT_SHA\", \"GIT_REPO\"),\n\t\t\tFinally: []pipelinev1.PipelineTask{\n\t\t\t\tcreateCommitStatusPipelineTask(\"set-final-status\", \"$(tasks.apply-source.status)\", \"The build is complete\"),\n\t\t\t},\n\t\t},\n\t}\n}", "func NewFromString(exp string) *Pipeline {\n\tcmds := ParseCommand(exp)\n\treturn NewPipeline(cmds...)\n}", "func (c *client) CompileLite(v interface{}, template, substitute bool) (*yaml.Build, *library.Pipeline, error) {\n\tp, data, err := c.Parse(v, c.repo.GetPipelineType(), new(yaml.Template))\n\tif err != nil {\n\t\treturn nil, nil, err\n\t}\n\n\t// create the library pipeline object from the yaml configuration\n\t_pipeline := p.ToPipelineLibrary()\n\t_pipeline.SetData(data)\n\t_pipeline.SetType(c.repo.GetPipelineType())\n\n\tif p.Metadata.RenderInline {\n\t\tnewPipeline, err := c.compileInline(p, c.TemplateDepth)\n\t\tif err != nil {\n\t\t\treturn nil, _pipeline, err\n\t\t}\n\t\t// validate the yaml configuration\n\t\terr = c.Validate(newPipeline)\n\t\tif err != nil {\n\t\t\treturn nil, _pipeline, err\n\t\t}\n\n\t\tp = newPipeline\n\t}\n\n\tif template {\n\t\t// create map of templates for easy lookup\n\t\ttemplates := mapFromTemplates(p.Templates)\n\n\t\tswitch {\n\t\tcase len(p.Stages) > 0:\n\t\t\t// inject the templates into the steps\n\t\t\tp, err = c.ExpandStages(p, templates, nil)\n\t\t\tif err != nil {\n\t\t\t\treturn nil, _pipeline, err\n\t\t\t}\n\n\t\t\tif substitute {\n\t\t\t\t// inject the substituted environment variables into the steps\n\t\t\t\tp.Stages, err = c.SubstituteStages(p.Stages)\n\t\t\t\tif err != nil {\n\t\t\t\t\treturn nil, _pipeline, err\n\t\t\t\t}\n\t\t\t}\n\t\tcase len(p.Steps) > 0:\n\t\t\t// inject the templates into the steps\n\t\t\tp, err = c.ExpandSteps(p, templates, nil, c.TemplateDepth)\n\t\t\tif err != nil {\n\t\t\t\treturn nil, _pipeline, err\n\t\t\t}\n\n\t\t\tif substitute {\n\t\t\t\t// inject the substituted environment variables into the steps\n\t\t\t\tp.Steps, err = c.SubstituteSteps(p.Steps)\n\t\t\t\tif err != nil {\n\t\t\t\t\treturn nil, _pipeline, err\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\t// validate the yaml configuration\n\terr = c.Validate(p)\n\tif err != nil {\n\t\treturn nil, _pipeline, err\n\t}\n\n\treturn p, _pipeline, nil\n}", "func (c *Cmd) createPipeScanners() error {\n\t// set prefix for pipe scanners\n\tprefix := c.Cmd.Path\n\tif c.OutputPrefix != \"\" {\n\t\tprefix = c.OutputPrefix\n\t}\n\n\tstdout, err := c.Cmd.StdoutPipe()\n\tif err != nil {\n\t\treturn fmt.Errorf(bold(\"ERROR:\")+\"\\n Error: %s\", err.Error())\n\t}\n\n\tstderr, err := c.Cmd.StderrPipe()\n\tif err != nil {\n\t\treturn fmt.Errorf(bold(\"ERROR:\")+\"\\n Error: %s\", err.Error())\n\t}\n\n\t// Created scanners for in, out, and err pipes\n\toutScanner := bufio.NewScanner(stdout)\n\terrScanner := bufio.NewScanner(stderr)\n\n\t// Scan for text\n\tgo func() {\n\t\tfor errScanner.Scan() {\n\t\t\tc.scannerOutput(prefix, errScanner.Text())\n\t\t}\n\t}()\n\n\tgo func() {\n\t\tfor outScanner.Scan() {\n\t\t\tc.scannerOutput(prefix, outScanner.Text())\n\t\t}\n\t}()\n\n\treturn nil\n}", "func (c *client) Compile(v interface{}) (*pipeline.Build, *library.Pipeline, error) {\n\tp, data, err := c.Parse(v, c.repo.GetPipelineType(), new(yaml.Template))\n\tif err != nil {\n\t\treturn nil, nil, err\n\t}\n\n\t// create the library pipeline object from the yaml configuration\n\t_pipeline := p.ToPipelineLibrary()\n\t_pipeline.SetData(data)\n\t_pipeline.SetType(c.repo.GetPipelineType())\n\n\t// validate the yaml configuration\n\terr = c.Validate(p)\n\tif err != nil {\n\t\treturn nil, _pipeline, err\n\t}\n\n\t// create map of templates for easy lookup\n\ttemplates := mapFromTemplates(p.Templates)\n\n\tevent := c.build.GetEvent()\n\taction := c.build.GetEventAction()\n\n\t// if the build has an event action, concatenate event and event action for matching\n\tif !strings.EqualFold(action, \"\") {\n\t\tevent = event + \":\" + action\n\t}\n\n\t// create the ruledata to purge steps\n\tr := &pipeline.RuleData{\n\t\tBranch: c.build.GetBranch(),\n\t\tComment: c.comment,\n\t\tEvent: event,\n\t\tPath: c.files,\n\t\tRepo: c.repo.GetFullName(),\n\t\tTag: strings.TrimPrefix(c.build.GetRef(), \"refs/tags/\"),\n\t\tTarget: c.build.GetDeploy(),\n\t}\n\n\tswitch {\n\tcase p.Metadata.RenderInline:\n\t\tnewPipeline, err := c.compileInline(p, c.TemplateDepth)\n\t\tif err != nil {\n\t\t\treturn nil, _pipeline, err\n\t\t}\n\t\t// validate the yaml configuration\n\t\terr = c.Validate(newPipeline)\n\t\tif err != nil {\n\t\t\treturn nil, _pipeline, err\n\t\t}\n\n\t\tif len(newPipeline.Stages) > 0 {\n\t\t\treturn c.compileStages(newPipeline, _pipeline, map[string]*yaml.Template{}, r)\n\t\t}\n\n\t\treturn c.compileSteps(newPipeline, _pipeline, map[string]*yaml.Template{}, r)\n\tcase len(p.Stages) > 0:\n\t\treturn c.compileStages(p, _pipeline, templates, r)\n\tdefault:\n\t\treturn c.compileSteps(p, _pipeline, templates, r)\n\t}\n}", "func GenCreateByReleasePipelineYaml(releaseID string, workspaces []string) apistructs.PipelineYml {\n\tyml := apistructs.PipelineYml{\n\t\tVersion: \"1.1\",\n\t\tStages: [][]*apistructs.PipelineYmlAction{\n\t\t\t{},\n\t\t\t{},\n\t\t\t{},\n\t\t\t{},\n\t\t},\n\t}\n\tfor _, workspace := range workspaces {\n\t\tyml.Stages[0] = append(yml.Stages[0], &apistructs.PipelineYmlAction{\n\t\t\tType: \"dice-deploy-release\",\n\t\t\tAlias: fmt.Sprintf(\"dice-deploy-release-%s\", workspace),\n\t\t\tVersion: \"1.0\",\n\t\t\tParams: map[string]interface{}{\n\t\t\t\t\"release_id\": releaseID,\n\t\t\t\t\"workspace\": workspace,\n\t\t\t},\n\t\t})\n\t\tyml.Stages[1] = append(yml.Stages[1], &apistructs.PipelineYmlAction{\n\t\t\tType: \"dice-deploy-addon\",\n\t\t\tAlias: fmt.Sprintf(\"dice-deploy-addon-%s\", workspace),\n\t\t\tVersion: \"1.0\",\n\t\t\tParams: map[string]interface{}{\n\t\t\t\t\"deployment_id\": fmt.Sprintf(\"${dice-deploy-release-%s:OUTPUT:deployment_id}\", workspace),\n\t\t\t},\n\t\t})\n\t\tyml.Stages[2] = append(yml.Stages[2], &apistructs.PipelineYmlAction{\n\t\t\tType: \"dice-deploy-service\",\n\t\t\tAlias: fmt.Sprintf(\"dice-deploy-service-%s\", workspace),\n\t\t\tVersion: \"1.0\",\n\t\t\tParams: map[string]interface{}{\n\t\t\t\t\"deployment_id\": fmt.Sprintf(\"${dice-deploy-release-%s:OUTPUT:deployment_id}\", workspace),\n\t\t\t},\n\t\t})\n\t\tyml.Stages[3] = append(yml.Stages[3], &apistructs.PipelineYmlAction{\n\t\t\tType: \"dice-deploy-domain\",\n\t\t\tAlias: fmt.Sprintf(\"dice-deploy-domain-%s\", workspace),\n\t\t\tVersion: \"1.0\",\n\t\t\tParams: map[string]interface{}{\n\t\t\t\t\"deployment_id\": fmt.Sprintf(\"${dice-deploy-release-%s:OUTPUT:deployment_id}\", workspace),\n\t\t\t},\n\t\t})\n\t}\n\n\treturn yml\n}", "func NewPipelineUpserter(ctx *common.Context, tokenProvider func(bool) string) Executor {\n\n\tworkflow := new(pipelineWorkflow)\n\tworkflow.codeRevision = ctx.Config.Repo.Revision\n\tworkflow.repoName = ctx.Config.Repo.Slug\n\n\tif ctx.Config.Repo.Branch != \"\" {\n\t\tworkflow.codeBranch = ctx.Config.Repo.Branch\n\t} else {\n\t\tworkflow.codeBranch = ctx.Config.Service.Pipeline.Source.Branch\n\t}\n\n\tstackParams := make(map[string]string)\n\n\treturn newPipelineExecutor(\n\t\tworkflow.serviceFinder(\"\", ctx),\n\t\tworkflow.pipelineToken(ctx.Config.Namespace, tokenProvider, ctx.StackManager, stackParams),\n\t\tnewConditionalExecutor(\n\t\t\tworkflow.isFromCatalog(&ctx.Config.Service.Pipeline),\n\t\t\tworkflow.pipelineCatalogUpserter(ctx.Config.Namespace, &ctx.Config.Service.Pipeline, stackParams, ctx.CatalogManager, ctx.StackManager),\n\t\t\tnewPipelineExecutor(\n\t\t\t\tnewParallelExecutor(\n\t\t\t\t\tworkflow.pipelineBucket(ctx.Config.Namespace, stackParams, ctx.StackManager, ctx.StackManager),\n\t\t\t\t\tworkflow.codedeployBucket(ctx.Config.Namespace, &ctx.Config.Service, ctx.StackManager, ctx.StackManager),\n\t\t\t\t),\n\t\t\t\tworkflow.pipelineRolesetUpserter(ctx.RolesetManager, ctx.RolesetManager, stackParams),\n\t\t\t\tworkflow.pipelineUpserter(ctx.Config.Namespace, ctx.StackManager, ctx.StackManager, stackParams),\n\t\t\t),\n\t\t),\n\t\tworkflow.pipelineNotifyUpserter(ctx.Config.Namespace, &ctx.Config.Service.Pipeline, ctx.SubscriptionManager))\n\n}", "func createCommand(pipeStage string) (*exec.Cmd, error) {\n\targs := strings.Fields(pipeStage)\n\texecutionArgs := make([]string, 0)\n\tvar cmd *exec.Cmd\n\n\t// Deliminating by pipes exposed an empty command\n\tif len(args) == 0 {\n\t\treturn nil, errors.New(\"Pipeline stage cannot be empty\")\n\t}\n\n\tvar inRedirectFile, outRedirectFile string\n\n\t// Any redirection specifiers (</>) will get parsed and saved\n\ti := 0\n\tfor i < len(args) {\n\t\tif strings.HasPrefix(args[i], inRedirectChar) {\n\t\t\tif i == 0 {\n\t\t\t\treturn nil, errors.New(\"Command must precede input redirection\")\n\t\t\t}\n\t\t\tif len(args[i]) > 1 {\n\t\t\t\tinRedirectFile = args[i][1:]\n\t\t\t\ti++\n\t\t\t} else if i == (len(args) - 1) {\n\t\t\t\treturn nil, errors.New(\"Redirection must include input file name\")\n\t\t\t} else {\n\t\t\t\tinRedirectFile = args[i+1]\n\t\t\t\ti += 2\n\t\t\t}\n\t\t} else if strings.HasPrefix(args[i], outRedirectChar) {\n\t\t\tif i == 0 {\n\t\t\t\treturn nil, errors.New(\"Command must precede output redirection\")\n\t\t\t}\n\t\t\tif len(args[i]) > 1 {\n\t\t\t\toutRedirectFile = args[i][1:]\n\t\t\t\ti++\n\t\t\t} else if i == (len(args) - 1) {\n\t\t\t\treturn nil, errors.New(\"Redirection must include output file name\")\n\t\t\t} else {\n\t\t\t\toutRedirectFile = args[i+1]\n\t\t\t\ti += 2\n\t\t\t}\n\t\t} else if i < len(args) {\n\t\t\t// Save command arguments only if they arent references to redirection\n\t\t\texecutionArgs = append(executionArgs, args[i])\n\t\t\ti++\n\t\t}\n\t}\n\t// Create a command using only the command name and arguments\n\tcmd = exec.Command(executionArgs[0], executionArgs[1:]...)\n\n\t// Set the redirect output files from the data we parsed\n\terr := setRedirects(cmd, inRedirectFile, outRedirectFile)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\n\treturn cmd, nil\n}", "func (pool *Pool) Pipeline() *Pipeline {\n\treturn BlankPipeline(int64(pool.DB))\n}", "func NewPipelineSpec(spec *pipeline.Spec) PipelineSpec {\n\treturn PipelineSpec{\n\t\tID: spec.ID,\n\t\tDotDAGSource: spec.DotDagSource,\n\t}\n}" ]
[ "0.7164634", "0.6616013", "0.6575863", "0.6569872", "0.6457084", "0.6410301", "0.63916916", "0.63585705", "0.63339573", "0.63170236", "0.62751275", "0.62524223", "0.6211996", "0.6203643", "0.61647236", "0.6147871", "0.6141217", "0.6131004", "0.6121805", "0.6106428", "0.60779154", "0.6047845", "0.6031182", "0.6029012", "0.5943345", "0.5930646", "0.5928195", "0.59214264", "0.59214264", "0.59128976", "0.591172", "0.5910832", "0.5907884", "0.58602154", "0.5851264", "0.5849726", "0.5848576", "0.58468777", "0.58130115", "0.57959896", "0.5790075", "0.57837725", "0.57626224", "0.5751698", "0.5750713", "0.57181954", "0.5716456", "0.5690213", "0.5673736", "0.5672498", "0.56691474", "0.56219375", "0.558573", "0.5580341", "0.55573773", "0.5554539", "0.5545207", "0.5525359", "0.5512822", "0.5510134", "0.55012816", "0.5497461", "0.54817224", "0.54817224", "0.54817224", "0.54632634", "0.54609007", "0.5445732", "0.5445654", "0.54406136", "0.5426907", "0.5416279", "0.54105854", "0.5386967", "0.53849655", "0.53813493", "0.53784025", "0.53752553", "0.5374281", "0.53375626", "0.53357136", "0.5333329", "0.5330854", "0.5330775", "0.53272855", "0.5322959", "0.5306895", "0.52996373", "0.5296158", "0.52932596", "0.52789336", "0.52787447", "0.5275831", "0.5275644", "0.5273726", "0.5261189", "0.52535456", "0.52310413", "0.5217107" ]
0.63951606
7
Creates a shader object
func CreateShader(xtype uint32) uint32 { ret := C.glowCreateShader(gpCreateShader, (C.GLenum)(xtype)) return (uint32)(ret) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func CreateShader(ty Enum) Shader {\n\treturn Shader{Value: uint32(gl.CreateShader(uint32(ty)))}\n}", "func NewShader(vertexFmt, uniformFmt AttrFormat, vertexShader, fragmentShader string) (*Shader, error) {\n\tshader := &Shader{\n\t\tprogram: binder{\n\t\t\trestoreLoc: gl.CURRENT_PROGRAM,\n\t\t\tbindFunc: func(obj uint32) {\n\t\t\t\tgl.UseProgram(obj)\n\t\t\t},\n\t\t},\n\t\tvertexFmt: vertexFmt,\n\t\tuniformFmt: uniformFmt,\n\t\tuniformLoc: make([]int32, len(uniformFmt)),\n\t}\n\n\tvar vshader, fshader uint32\n\n\t// vertex shader\n\t{\n\t\tvshader = gl.CreateShader(gl.VERTEX_SHADER)\n\t\tsrc, free := gl.Strs(vertexShader)\n\t\tdefer free()\n\t\tlength := int32(len(vertexShader))\n\t\tgl.ShaderSource(vshader, 1, src, &length)\n\t\tgl.CompileShader(vshader)\n\n\t\tvar success int32\n\t\tgl.GetShaderiv(vshader, gl.COMPILE_STATUS, &success)\n\t\tif success == gl.FALSE {\n\t\t\tvar logLen int32\n\t\t\tgl.GetShaderiv(vshader, gl.INFO_LOG_LENGTH, &logLen)\n\n\t\t\tinfoLog := make([]byte, logLen)\n\t\t\tgl.GetShaderInfoLog(vshader, logLen, nil, &infoLog[0])\n\t\t\treturn nil, fmt.Errorf(\"error compiling vertex shader: %s\", string(infoLog))\n\t\t}\n\n\t\tdefer gl.DeleteShader(vshader)\n\t}\n\n\t// fragment shader\n\t{\n\t\tfshader = gl.CreateShader(gl.FRAGMENT_SHADER)\n\t\tsrc, free := gl.Strs(fragmentShader)\n\t\tdefer free()\n\t\tlength := int32(len(fragmentShader))\n\t\tgl.ShaderSource(fshader, 1, src, &length)\n\t\tgl.CompileShader(fshader)\n\n\t\tvar success int32\n\t\tgl.GetShaderiv(fshader, gl.COMPILE_STATUS, &success)\n\t\tif success == gl.FALSE {\n\t\t\tvar logLen int32\n\t\t\tgl.GetShaderiv(fshader, gl.INFO_LOG_LENGTH, &logLen)\n\n\t\t\tinfoLog := make([]byte, logLen)\n\t\t\tgl.GetShaderInfoLog(fshader, logLen, nil, &infoLog[0])\n\t\t\treturn nil, fmt.Errorf(\"error compiling fragment shader: %s\", string(infoLog))\n\t\t}\n\n\t\tdefer gl.DeleteShader(fshader)\n\t}\n\n\t// shader program\n\t{\n\t\tshader.program.obj = gl.CreateProgram()\n\t\tgl.AttachShader(shader.program.obj, vshader)\n\t\tgl.AttachShader(shader.program.obj, fshader)\n\t\tgl.LinkProgram(shader.program.obj)\n\n\t\tvar success int32\n\t\tgl.GetProgramiv(shader.program.obj, gl.LINK_STATUS, &success)\n\t\tif success == gl.FALSE {\n\t\t\tvar logLen int32\n\t\t\tgl.GetProgramiv(shader.program.obj, gl.INFO_LOG_LENGTH, &logLen)\n\n\t\t\tinfoLog := make([]byte, logLen)\n\t\t\tgl.GetProgramInfoLog(shader.program.obj, logLen, nil, &infoLog[0])\n\t\t\treturn nil, fmt.Errorf(\"error linking shader program: %s\", string(infoLog))\n\t\t}\n\t}\n\n\t// uniforms\n\tfor i, uniform := range uniformFmt {\n\t\tloc := gl.GetUniformLocation(shader.program.obj, gl.Str(uniform.Name+\"\\x00\"))\n\t\tshader.uniformLoc[i] = loc\n\t}\n\n\truntime.SetFinalizer(shader, (*Shader).delete)\n\n\treturn shader, nil\n}", "func CreateShader(xtype uint32) uint32 {\n ret := C.glowCreateShader(gpCreateShader, (C.GLenum)(xtype))\n return (uint32)(ret)\n}", "func CreateShader(xtype GLEnum) Shader {\n\treturn Shader(gl.CreateShader(uint32(xtype)))\n}", "func CreateShader(kind Enum) Uint {\n\tckind, _ := (C.GLenum)(kind), cgoAllocsUnknown\n\t__ret := C.glCreateShader(ckind)\n\t__v := (Uint)(__ret)\n\treturn __v\n}", "func (debugging *debuggingOpenGL) CreateShader(shaderType uint32) uint32 {\n\tdebugging.recordEntry(\"CreateShader\", shaderType)\n\tresult := debugging.gl.CreateShader(shaderType)\n\tdebugging.recordExit(\"CreateShader\", result)\n\treturn result\n}", "func (native *OpenGL) CreateShader(shaderType uint32) uint32 {\n\treturn gl.CreateShader(shaderType)\n}", "func (gl *WebGL) CreateShader(shaderType GLEnum) WebGLShader {\n\treturn gl.context.Call(\"createShader\", shaderType)\n}", "func (gl *WebGL) NewShader(shaderType GLEnum, sourceCode string) (WebGLShader, error) {\n\tshader := gl.CreateShader(shaderType)\n\tgl.ShaderSource(shader, sourceCode)\n\terr := gl.CompileShader(shader)\n\treturn shader, err\n}", "func CreateShader(xtype uint32) uint32 {\n\tret, _, _ := syscall.Syscall(gpCreateShader, 1, uintptr(xtype), 0, 0)\n\treturn (uint32)(ret)\n}", "func CreateShaderProgramv(xtype uint32, count int32, strings **int8) uint32 {\n ret := C.glowCreateShaderProgramv(gpCreateShaderProgramv, (C.GLenum)(xtype), (C.GLsizei)(count), (**C.GLchar)(unsafe.Pointer(strings)))\n return (uint32)(ret)\n}", "func newShaderManager() ShaderManager {\n\tsm := shaderManager{\n\t\tshaders: make(map[string]Shader),\n\t}\n\treturn &sm\n}", "func (s *Shader) Init(shader io.Reader) (err error) {\n\ts.uniformLocs = make(map[string]int32)\n\ts.uniformBIndices = make(map[string]uint32)\n\ts.uniformBOs = make(map[string]uint32)\n\tshaders := []uint32{}\n\n\treader := bufio.NewReader(shader)\n\n\tshaderTypeLine, err := reader.ReadString('\\n')\n\tif err != nil {\n\t\treturn err\n\t}\n\n\t// eof gets set to true if we reached the end of the file\n\teof := false\n\n\tfor {\n\t\tshader := \"\"\n\n\t\t// decide on the shader type\n\t\tvar shaderType uint32\n\t\ttypeStr := strings.Split(shaderTypeLine, \" \")[1]\n\t\tswitch strings.ToLower(typeStr) {\n\t\tcase \"vertex\\n\":\n\t\t\tshaderType = gl.VERTEX_SHADER\n\t\tcase \"fragment\\n\":\n\t\t\tshaderType = gl.FRAGMENT_SHADER\n\t\tdefault:\n\t\t\terr = errors.New(\"Shader type \" + typeStr + \" not known.\")\n\t\t\treturn err\n\t\t}\n\n\t\tfor {\n\t\t\tline, err := reader.ReadString('\\n')\n\t\t\tif err == io.EOF {\n\t\t\t\teof = true\n\t\t\t\tbreak\n\t\t\t}\n\t\t\tif err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\n\t\t\t// start a new shader string with a new type if the line starts with \"#shader\"\n\t\t\tif strings.HasPrefix(line, \"#shader\") {\n\t\t\t\t// tell the next iteration the information on shader type we read\n\t\t\t\tshaderTypeLine = line\n\t\t\t\tbreak\n\t\t\t} else {\n\t\t\t\tshader += line\n\t\t\t}\n\t\t}\n\n\t\t// if the shader is not empty, compile it\n\t\tif len(shader) > 0 {\n\t\t\tshaderptr, err := s.compile(shader+\"\\x00\", shaderType)\n\t\t\tif err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\n\t\t\tshaders = append(shaders, shaderptr)\n\t\t} else {\n\t\t\tbreak\n\t\t}\n\n\t\tif eof {\n\t\t\tbreak\n\t\t}\n\t}\n\n\t// link shaders\n\ts.Program = gl.CreateProgram()\n\tfor _, shader := range shaders {\n\t\tgl.AttachShader(s.Program, shader)\n\t}\n\tgl.LinkProgram(s.Program)\n\n\t// delete the singke shaders. we won't need them anymore\n\tfor _, shader := range shaders {\n\t\tgl.DeleteShader(shader)\n\t}\n\n\treturn\n}", "func MakeShader() *Shader {\n\treturn &Shader{\n\t\tuniforms: make(map[string]*Uniform),\n\t}\n}", "func CreateShaderProgramv(xtype uint32, count int32, strings **uint8) uint32 {\n\tret := C.glowCreateShaderProgramv(gpCreateShaderProgramv, (C.GLenum)(xtype), (C.GLsizei)(count), (**C.GLchar)(unsafe.Pointer(strings)))\n\treturn (uint32)(ret)\n}", "func CreateShaderProgramv(xtype uint32, count int32, strings **uint8) uint32 {\n\tret := C.glowCreateShaderProgramv(gpCreateShaderProgramv, (C.GLenum)(xtype), (C.GLsizei)(count), (**C.GLchar)(unsafe.Pointer(strings)))\n\treturn (uint32)(ret)\n}", "func CompileShader(shader uint32) {\n C.glowCompileShader(gpCompileShader, (C.GLuint)(shader))\n}", "func CreateProgram(vertexSource string, fragmentSource string) (gl.Uint, error) {\n\t// Vertex shader\n\tvs := gl.CreateShader(gl.VERTEX_SHADER)\n\tvsSource := gl.GLStringArray(vertexSource)\n\tdefer gl.GLStringArrayFree(vsSource)\n\tgl.ShaderSource(vs, 1, &vsSource[0], nil)\n\n\tgl.CompileShader(vs)\n\n\tstatus, err := compileStatus(vs)\n\tif err != nil {\n\t\treturn status, err\n\t}\n\n\t// Fragment shader\n\tfs := gl.CreateShader(gl.FRAGMENT_SHADER)\n\tfsSource := gl.GLStringArray(fragmentSource)\n\tdefer gl.GLStringArrayFree(fsSource)\n\tgl.ShaderSource(fs, 1, &fsSource[0], nil)\n\tgl.CompileShader(fs)\n\n\tstatus, err = compileStatus(fs)\n\tif err != nil {\n\t\treturn status, err\n\t}\n\n\t// create program\n\tprogram := gl.CreateProgram()\n\tgl.AttachShader(program, vs)\n\tgl.AttachShader(program, fs)\n\n\tgl.LinkProgram(program)\n\tvar linkstatus gl.Int\n\tgl.GetProgramiv(program, gl.LINK_STATUS, &linkstatus)\n\tif linkstatus == gl.FALSE {\n\t\treturn gl.FALSE, errors.New(\"Program link failed\")\n\t}\n\n\treturn program, nil\n}", "func (r *device) LoadShader(s *gfx.Shader, done chan *gfx.Shader) {\n\t// If we are sharing assets with another renderer, allow it to load the\n\t// shader instead.\n\tr.shared.RLock()\n\tif r.shared.device != nil {\n\t\tr.shared.device.LoadShader(s, done)\n\t\tr.shared.RUnlock()\n\t\treturn\n\t}\n\tr.shared.RUnlock()\n\n\t// Perform pre-load checks on the shader.\n\tdoLoad, err := glutil.PreLoadShader(s, done)\n\tif err != nil {\n\t\tr.warner.Warnf(\"%v\\n\", err)\n\t\treturn\n\t}\n\tif !doLoad {\n\t\treturn\n\t}\n\n\tr.renderExec <- func() bool {\n\t\tnative := &nativeShader{\n\t\t\tr: r.rsrcManager,\n\t\t}\n\n\t\t// Compile vertex shader.\n\t\tnative.vertex = gl.CreateShader(gl.VERTEX_SHADER)\n\t\tsources, free := gl.Strs(string(s.GLSL.Vertex) + \"\\x00\")\n\t\tgl.ShaderSource(native.vertex, 1, sources, nil) // TODO(slimsag): use length parameter instead of null terminator\n\t\tgl.CompileShader(native.vertex)\n\t\tfree()\n\n\t\t// Check if the shader compiled or not.\n\t\tlog, compiled := shaderCompilerLog(native.vertex)\n\t\tif !compiled {\n\t\t\t// Just for sanity.\n\t\t\tnative.vertex = 0\n\n\t\t\t// Append the errors.\n\t\t\ts.Error = append(s.Error, []byte(s.Name+\" | Vertex shader errors:\\n\")...)\n\t\t\ts.Error = append(s.Error, log...)\n\t\t}\n\t\tif len(log) > 0 {\n\t\t\t// Send the compiler log to the debug writer.\n\t\t\tr.warner.Warnf(\"%s | Vertex shader errors:\\n\", s.Name)\n\t\t\tr.warner.Warnf(string(log))\n\t\t}\n\n\t\t// Compile fragment shader.\n\t\tnative.fragment = gl.CreateShader(gl.FRAGMENT_SHADER)\n\t\tsources, free = gl.Strs(string(s.GLSL.Fragment) + \"\\x00\")\n\t\tgl.ShaderSource(native.fragment, 1, sources, nil) // TODO(slimsag): use length parameter instead of null terminator\n\t\tgl.CompileShader(native.fragment)\n\t\tfree()\n\n\t\t// Check if the shader compiled or not.\n\t\tlog, compiled = shaderCompilerLog(native.fragment)\n\t\tif !compiled {\n\t\t\t// Just for sanity.\n\t\t\tnative.fragment = 0\n\n\t\t\t// Append the errors.\n\t\t\ts.Error = append(s.Error, []byte(s.Name+\" | Fragment shader errors:\\n\")...)\n\t\t\ts.Error = append(s.Error, log...)\n\t\t}\n\t\tif len(log) > 0 {\n\t\t\t// Send the compiler log to the debug writer.\n\t\t\tr.warner.Warnf(\"%s | Fragment shader errors:\\n\", s.Name)\n\t\t\tr.warner.Warnf(string(log))\n\t\t}\n\n\t\t// Create the shader program if all went well with the vertex and\n\t\t// fragment shaders.\n\t\tif native.vertex != 0 && native.fragment != 0 {\n\t\t\tnative.program = gl.CreateProgram()\n\t\t\tgl.AttachShader(native.program, native.vertex)\n\t\t\tgl.AttachShader(native.program, native.fragment)\n\t\t\tgl.LinkProgram(native.program)\n\n\t\t\t// Grab the linker's log.\n\t\t\tvar (\n\t\t\t\tlogSize int32\n\t\t\t\tlog []byte\n\t\t\t)\n\t\t\tgl.GetProgramiv(native.program, gl.INFO_LOG_LENGTH, &logSize)\n\n\t\t\tif logSize > 0 {\n\t\t\t\tlog = make([]byte, logSize)\n\t\t\t\tgl.GetProgramInfoLog(native.program, logSize, nil, &log[0])\n\n\t\t\t\t// Strip the null-termination byte.\n\t\t\t\tlog = log[:len(log)-1]\n\t\t\t}\n\n\t\t\t// Check for linker errors.\n\t\t\tvar ok int32\n\t\t\tgl.GetProgramiv(native.program, gl.LINK_STATUS, &ok)\n\t\t\tif ok == 0 {\n\t\t\t\t// Just for sanity.\n\t\t\t\tnative.program = 0\n\n\t\t\t\t// Append the errors.\n\t\t\t\ts.Error = append(s.Error, []byte(s.Name+\" | Linker errors:\\n\")...)\n\t\t\t\ts.Error = append(s.Error, log...)\n\t\t\t}\n\t\t\tif len(log) > 0 {\n\t\t\t\t// Send the linker log to the debug writer.\n\t\t\t\tr.warner.Warnf(\"%s | Linker errors:\\n\", s.Name)\n\t\t\t\tr.warner.Warnf(string(log))\n\t\t\t}\n\t\t}\n\n\t\t// Mark the shader as loaded if there were no errors.\n\t\tif len(s.Error) == 0 {\n\t\t\tnative.LocationCache = &glutil.LocationCache{\n\t\t\t\tGetAttribLocation: func(name string) int {\n\t\t\t\t\treturn int(gl.GetAttribLocation(native.program, gl.Str(name+\"\\x00\")))\n\t\t\t\t},\n\t\t\t\tGetUniformLocation: func(name string) int {\n\t\t\t\t\treturn int(gl.GetUniformLocation(native.program, gl.Str(name+\"\\x00\")))\n\t\t\t\t},\n\t\t\t}\n\n\t\t\ts.Loaded = true\n\t\t\ts.NativeShader = native\n\t\t\ts.ClearData()\n\n\t\t\t// Attach a finalizer to the shader that will later free it.\n\t\t\truntime.SetFinalizer(native, finalizeShader)\n\t\t}\n\n\t\t// Finish not Flush, see http://higherorderfun.com/blog/2011/05/26/multi-thread-opengl-texture-loading/\n\t\tgl.Finish()\n\n\t\t// Signal completion and return.\n\t\tselect {\n\t\tcase done <- s:\n\t\tdefault:\n\t\t}\n\t\treturn false // no frame rendered.\n\t}\n}", "func CreateShaderProgramv(xtype uint32, count int32, strings **uint8) uint32 {\n\tret, _, _ := syscall.Syscall(gpCreateShaderProgramv, 3, uintptr(xtype), uintptr(count), uintptr(unsafe.Pointer(strings)))\n\treturn (uint32)(ret)\n}", "func (shader Shader) Compile() {\n\tgl.CompileShader(uint32(shader))\n}", "func (gl *WebGL) CreateProgram() WebGLShaderProgram {\n\treturn gl.context.Call(\"createProgram\")\n}", "func GLShader(shaderType uint32, source string) (uint32, error) {\n\t// Create shader based on shaderType\n\tshader := gl.CreateShader(shaderType)\n\t// Compile the Shader with the source\n\tcsources, free := gl.Strs(source)\n\tgl.ShaderSource(shader, 1, csources, nil)\n\tfree()\n\tgl.CompileShader(shader)\n\n\tvar status int32\n\tgl.GetShaderiv(shader, gl.COMPILE_STATUS, &status)\n\tif status == gl.FALSE {\n\t\tvar logLen int32\n\t\tgl.GetShaderiv(shader, gl.INFO_LOG_LENGTH, &logLen)\n\t\tlog := strings.Repeat(\"\\x00\", int(logLen+1))\n\t\tgl.GetShaderInfoLog(shader, logLen, nil, gl.Str(log))\n\n\t\treturn 0, fmt.Errorf(\"Failed to compile %v: %v\", source, log)\n\t}\n\n\treturn shader, nil\n}", "func CompileShader(s Shader) {\n\tgl.CompileShader(s.Value)\n}", "func CreateProgram() Program {\n\treturn Program(gl.CreateProgram())\n}", "func (self *TileSprite) Shader() *AbstractFilter{\n return &AbstractFilter{self.Object.Get(\"shader\")}\n}", "func (gl *WebGL) NewProgram(shaders []WebGLShader) (WebGLShaderProgram, error) {\n\tprogram := gl.CreateProgram()\n\tfor _, shader := range shaders {\n\t\tgl.AttachShader(program, shader)\n\t}\n\n\terr := gl.LinkProgram(program)\n\treturn program, err\n}", "func (shader Shader) Source(source string) {\n\tcstrs, free := gl.Strs(source + \"\\x00\")\n\tgl.ShaderSource(uint32(shader), 1, cstrs, nil)\n\tfree()\n}", "func initOpenGL() uint32 {\n\tif err := gl.Init(); err != nil {\n\t\tpanic(err)\n\t}\n\tversion := gl.GoStr(gl.GetString(gl.VERSION))\n\tlog.Println(\"OpenGL version\", version)\n\n\tvar vertexShaderSource string\n\tvar fragmentShaderSource string\n\n\tvertexShaderSource = `\n\t#version 410\n\tlayout (location=0) in vec3 position;\n\tlayout (location=1) in vec2 texcoord;\n\tout vec2 tCoord;\n\tuniform mat4 projection;\n\tuniform mat4 world;\n\tuniform mat4 view;\n\tuniform vec2 texScale;\n\tuniform vec2 texOffset;\n\tvoid main() {\n\t\tgl_Position = projection * world * vec4(position, 1.0);\n\t\ttCoord = (texcoord+texOffset) * texScale;\n\t}\n\t` + \"\\x00\"\n\t//gl_Position = vec4(position, 10.0, 1.0) * camera * projection;\n\n\tfragmentShaderSource = `\n\t#version 410\n\tin vec2 tCoord;\n\tout vec4 frag_colour;\n\tuniform sampler2D ourTexture;\n\tuniform vec4 color;\n\tvoid main() {\n\t\t\tfrag_colour = texture(ourTexture, tCoord) * color;\n\t}\n\t` + \"\\x00\"\n\n\tprog := CreateProgram(vertexShaderSource, fragmentShaderSource)\n\n\tgl.UseProgram(prog)\n\tgl.Uniform2f(\n\t\tgl.GetUniformLocation(prog, gl.Str(\"texScale\\x00\")),\n\t\t1.0, 1.0,\n\t)\n\tgl.Uniform4f(\n\t\tgl.GetUniformLocation(prog, gl.Str(\"color\\x00\")),\n\t\t1, 1, 1, 1,\n\t)\n\n\t// line opengl program\n\tvertexShaderSource = `\n\t#version 330 core\n\tlayout (location = 0) in vec3 aPos;\n\tuniform mat4 uProjection;\n\tuniform mat4 uWorld;\n\n\tvoid main()\n\t{\n\t gl_Position = uProjection * vec4(aPos, 1.0);\n\t}` + \"\\x00\"\n\n\tfragmentShaderSource = `\n\t#version 330 core\n\tout vec4 FragColor;\n\tuniform vec3 uColor;\n\n\tvoid main()\n\t{\n\t FragColor = vec4(uColor, 1.0f);\n\t}` + \"\\x00\"\n\n\tlineProgram = CreateProgram(vertexShaderSource, fragmentShaderSource)\n\n\treturn prog\n}", "func ShaderSource(shader uint32, count int32, xstring **int8, length *int32) {\n C.glowShaderSource(gpShaderSource, (C.GLuint)(shader), (C.GLsizei)(count), (**C.GLchar)(unsafe.Pointer(xstring)), (*C.GLint)(unsafe.Pointer(length)))\n}", "func ShaderBinary(count int32, shaders *uint32, binaryformat uint32, binary unsafe.Pointer, length int32) {\n C.glowShaderBinary(gpShaderBinary, (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(shaders)), (C.GLenum)(binaryformat), binary, (C.GLsizei)(length))\n}", "func compileShader(shaderType wasm.GLenum, shaderSrc string) (wasm.WebGLShader, error) {\n\tvar shader = gl.CreateShader(shaderType)\n\tgl.ShaderSource(shader, shaderSrc)\n\tgl.CompileShader(shader)\n\n\tif !gl.GetShaderParameter(shader, wasm.COMPILE_STATUS).(bool) {\n\t\treturn nil, fmt.Errorf(\"could not compile shader: %s\", gl.GetShaderInfoLog(shader))\n\t}\n\treturn shader, nil\n}", "func AttachShader(program uint32, shader uint32) {\n C.glowAttachShader(gpAttachShader, (C.GLuint)(program), (C.GLuint)(shader))\n}", "func (s *Shader) Use() {\n\tgl.UseProgram(s.programID)\n}", "func (gl *WebGL) ShaderSource(shader WebGLShader, source string) {\n\tgl.context.Call(\"shaderSource\", shader, source)\n}", "func CreateProgram() Program {\n\treturn Program{Value: uint32(gl.CreateProgram())}\n}", "func (gui *GUI) createProgram() (uint32, error) {\n\tif err := gl.Init(); err != nil {\n\t\treturn 0, fmt.Errorf(\"Failed to initialise OpenGL: %s\", err)\n\t}\n\tgui.logger.Infof(\"OpenGL version %s\", gl.GoStr(gl.GetString(gl.VERSION)))\n\n\tgui.logger.Debugf(\"Compiling shaders...\")\n\n\tvertexShader, err := compileShader(vertexShaderSource, gl.VERTEX_SHADER)\n\tif err != nil {\n\t\treturn 0, err\n\t}\n\n\tfragmentShader, err := compileShader(fragmentShaderSource, gl.FRAGMENT_SHADER)\n\tif err != nil {\n\t\treturn 0, err\n\t}\n\n\tprog := gl.CreateProgram()\n\tgl.AttachShader(prog, vertexShader)\n\tgl.AttachShader(prog, fragmentShader)\n\tgl.LinkProgram(prog)\n\n\treturn prog, nil\n}", "func (am *Manager) LoadShader(typ uint32, name string) (uint32, error) {\n\tif shader, ok := am.GetShader(name); ok {\n\t\treturn shader, nil\n\t}\n\n\tLogger.Printf(\"asset.Manager.LoadShader: loading Shader '%s'\\n\", name)\n\n\tvar shader, err = newShader(\"assets/shaders/\"+name, typ)\n\tif err != nil {\n\t\tLogger.Print(\"asset.Manager.LoadShader: failed\")\n\t\treturn 0, err\n\t}\n\n\tLogger.Print(\"asset.Manager.LoadShader: shader loaded\")\n\n\tam.AddShader(name, shader)\n\n\treturn shader, nil\n}", "func (shader Shader) Delete() {\n\tgl.DeleteShader(uint32(shader))\n}", "func (debugging *debuggingOpenGL) ShaderSource(shader uint32, source string) {\n\tdebugging.recordEntry(\"ShaderSource\", shader, source)\n\tdebugging.gl.ShaderSource(shader, source)\n\tdebugging.recordExit(\"ShaderSource\")\n}", "func ShaderSource(shader uint32, count int32, xstring **uint8, length *int32) {\n\tsyscall.Syscall6(gpShaderSource, 4, uintptr(shader), uintptr(count), uintptr(unsafe.Pointer(xstring)), uintptr(unsafe.Pointer(length)), 0, 0)\n}", "func (native *OpenGL) CompileShader(shader uint32) {\n\tgl.CompileShader(shader)\n}", "func Make(mode uint32) VAO {\n\tvao := VAO{0, mode, nil, nil}\n\tgl.GenVertexArrays(1, &vao.handle)\n\treturn vao\n}", "func CompileNewShader(gl interfaces.OpenGL, shaderType uint32, source string) (shader uint32, err error) {\n\tshader = gl.CreateShader(shaderType)\n\n\tgl.ShaderSource(shader, source)\n\tgl.CompileShader(shader)\n\n\tcompileStatus := gl.GetShaderParameter(shader, oglconsts.COMPILE_STATUS)\n\tif compileStatus == 0 {\n\t\terr = fmt.Errorf(\"%s\", gl.GetShaderInfoLog(shader))\n\t\tgl.DeleteShader(shader)\n\t\tshader = 0\n\t}\n\n\treturn\n}", "func (s *Shader) compile(source string, shaderType uint32) (shader uint32, err error) {\n\t// create a shader from source (returns shader ID)\n\tshader = gl.CreateShader(shaderType)\n\tcsource, free := gl.Strs(source) // returns a C String and a function to free the memory\n\t//\t\t\t\tshader, count, source string, length (unused)\n\tgl.ShaderSource(shader, 1, csource, nil)\n\tfree() // frees the memory used by csource\n\tgl.CompileShader(shader) // compile the shader\n\n\t// check if compiling failed\n\tvar status int32\n\t//\t\t\t shader info type\t\t pointer\n\tgl.GetShaderiv(shader, gl.COMPILE_STATUS, &status) // returns shader info\n\tif status == gl.FALSE {\n\t\tvar logLength int32\n\t\tgl.GetShaderiv(shader, gl.INFO_LOG_LENGTH, &logLength)\n\n\t\t// create empty string that can hold the log content\n\t\tlog := strings.Repeat(\"\\x00\", int(logLength+1))\n\t\tgl.GetShaderInfoLog(shader, logLength, nil, gl.Str(log)) // returns the shader compile log\n\n\t\t// set error message\n\t\terr = errors.New(\"Failed to compile OpenGL shader:\\n\" + log)\n\t}\n\n\treturn\n}", "func (obj *Device) CreateVertexShader(function uintptr) (*VertexShader, Error) {\n\tvar shader *VertexShader\n\tret, _, _ := syscall.Syscall(\n\t\tobj.vtbl.CreateVertexShader,\n\t\t3,\n\t\tuintptr(unsafe.Pointer(obj)),\n\t\tfunction,\n\t\tuintptr(unsafe.Pointer(&shader)),\n\t)\n\treturn shader, toErr(ret)\n}", "func CompileShader(shader Uint) {\n\tcshader, _ := (C.GLuint)(shader), cgoAllocsUnknown\n\tC.glCompileShader(cshader)\n}", "func CompileNewShader(gl OpenGL, shaderType uint32, source string) (shader uint32, err error) {\n\tshader = gl.CreateShader(shaderType)\n\n\tgl.ShaderSource(shader, source)\n\tgl.CompileShader(shader)\n\n\tcompileStatus := gl.GetShaderParameter(shader, COMPILE_STATUS)\n\tif compileStatus == 0 {\n\t\terr = ShaderError{Log: gl.GetShaderInfoLog(shader)}\n\t\tgl.DeleteShader(shader)\n\t\tshader = 0\n\t}\n\n\treturn\n}", "func (native *OpenGL) ShaderSource(shader uint32, source string) {\n\tcsources, free := gl.Strs(source + \"\\x00\")\n\tdefer free()\n\n\tgl.ShaderSource(shader, 1, csources, nil)\n}", "func CompileShader(shader uint32) {\n\tsyscall.Syscall(gpCompileShader, 1, uintptr(shader), 0, 0)\n}", "func DeleteShader(shader uint32) {\n C.glowDeleteShader(gpDeleteShader, (C.GLuint)(shader))\n}", "func CompileShader(shader uint32) {\n\tC.glowCompileShader(gpCompileShader, (C.GLuint)(shader))\n}", "func CompileShader(shader uint32) {\n\tC.glowCompileShader(gpCompileShader, (C.GLuint)(shader))\n}", "func ShaderBinary(count int32, shaders *uint32, binaryFormat uint32, binary unsafe.Pointer, length int32) {\n\tC.glowShaderBinary(gpShaderBinary, (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(shaders)), (C.GLenum)(binaryFormat), binary, (C.GLsizei)(length))\n}", "func ShaderBinary(count int32, shaders *uint32, binaryFormat uint32, binary unsafe.Pointer, length int32) {\n\tC.glowShaderBinary(gpShaderBinary, (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(shaders)), (C.GLenum)(binaryFormat), binary, (C.GLsizei)(length))\n}", "func (p *Plane) Setup(mat Material, mod Model, name string, collide bool, reflective int, refractionIndex float32) error {\n\n\tp.vertexValues.Vertices = []float32{\n\t\t0.0, 0.5, 0.5,\n\t\t0.0, 0.5, 0.0,\n\t\t0.5, 0.5, 0.0,\n\t\t0.5, 0.5, 0.5,\n\t}\n\n\tp.vertexValues.Faces = []uint32{\n\t\t0, 2, 1, 2, 0, 3,\n\t}\n\n\tp.vertexValues.Normals = []float32{\n\t\t0.0, -1.0, 0.0,\n\t\t0.0, -1.0, 0.0,\n\t\t0.0, -1.0, 0.0,\n\t\t0.0, -1.0, 0.0,\n\t}\n\tp.vertexValues.Uvs = []float32{\n\t\t0.0, 0.0,\n\t\t5.0, 0.0,\n\t\t5.0, 5.0,\n\t\t0.0, 5.0,\n\t}\n\n\tp.name = name\n\tp.programInfo = ProgramInfo{}\n\tp.material = mat\n\n\tvar shaderVals map[string]bool\n\tshaderVals = make(map[string]bool)\n\n\tif mat.ShaderType == 0 {\n\t\tshaderVals[\"aPosition\"] = true\n\t\tbS := &shader.BasicShader{}\n\t\tbS.Setup()\n\t\tp.shaderVal = bS\n\t\tp.programInfo.Program = InitOpenGL(p.shaderVal.GetVertShader(), p.shaderVal.GetFragShader(), p.shaderVal.GetGeometryShader())\n\t\tp.programInfo.attributes = Attributes{\n\t\t\tposition: 0,\n\t\t\tnormal: 1,\n\t\t}\n\n\t\tSetupAttributesMap(&p.programInfo, shaderVals)\n\n\t\tp.buffers.Vao = CreateTriangleVAO(&p.programInfo, p.vertexValues.Vertices, nil, nil, nil, nil, p.vertexValues.Faces)\n\n\t} else if mat.ShaderType == 1 {\n\t\tshaderVals[\"aPosition\"] = true\n\t\tshaderVals[\"aNormal\"] = true\n\t\tshaderVals[\"diffuseVal\"] = true\n\t\tshaderVals[\"ambientVal\"] = true\n\t\tshaderVals[\"specularVal\"] = true\n\t\tshaderVals[\"nVal\"] = true\n\t\tshaderVals[\"uProjectionMatrix\"] = true\n\t\tshaderVals[\"uViewMatrix\"] = true\n\t\tshaderVals[\"uModelMatrix\"] = true\n\t\tshaderVals[\"pointLights\"] = true\n\t\tshaderVals[\"cameraPosition\"] = true\n\n\t\tbS := &shader.BlinnNoTexture{}\n\t\tbS.Setup()\n\t\tp.shaderVal = bS\n\t\tp.programInfo.Program = InitOpenGL(p.shaderVal.GetVertShader(), p.shaderVal.GetFragShader(), p.shaderVal.GetGeometryShader())\n\t\tp.programInfo.attributes = Attributes{\n\t\t\tposition: 0,\n\t\t\tnormal: 1,\n\t\t}\n\n\t\tSetupAttributesMap(&p.programInfo, shaderVals)\n\n\t\tp.buffers.Vao = CreateTriangleVAO(&p.programInfo, p.vertexValues.Vertices, p.vertexValues.Normals, nil, nil, nil, p.vertexValues.Faces)\n\n\t} else if mat.ShaderType == 2 {\n\t\tp.programInfo.Program = InitOpenGL(p.shaderVal.GetVertShader(), p.shaderVal.GetFragShader(), p.shaderVal.GetGeometryShader())\n\t\tp.programInfo.attributes = Attributes{\n\t\t\tposition: 0,\n\t\t\tnormal: 1,\n\t\t\tuv: 2,\n\t\t}\n\n\t} else if mat.ShaderType == 3 {\n\t\tshaderVals[\"aPosition\"] = true\n\t\tshaderVals[\"aNormal\"] = true\n\t\tshaderVals[\"aUV\"] = true\n\t\tshaderVals[\"diffuseVal\"] = true\n\t\tshaderVals[\"ambientVal\"] = true\n\t\tshaderVals[\"specularVal\"] = true\n\t\tshaderVals[\"nVal\"] = true\n\t\tshaderVals[\"uProjectionMatrix\"] = true\n\t\tshaderVals[\"uViewMatrix\"] = true\n\t\tshaderVals[\"uModelMatrix\"] = true\n\t\tshaderVals[\"pointLights\"] = true\n\t\tshaderVals[\"cameraPosition\"] = true\n\t\tshaderVals[\"uDiffuseTexture\"] = true\n\n\t\tbS := &shader.BlinnDiffuseTexture{}\n\t\tbS.Setup()\n\t\tp.shaderVal = bS\n\t\tp.programInfo.Program = InitOpenGL(p.shaderVal.GetVertShader(), p.shaderVal.GetFragShader(), p.shaderVal.GetGeometryShader())\n\t\tp.programInfo.attributes = Attributes{\n\t\t\tposition: 0,\n\t\t\tnormal: 1,\n\t\t\tuv: 2,\n\t\t}\n\t\ttexture0, err := texture.NewTextureFromFile(\"../Editor/materials/\"+p.material.DiffuseTexture,\n\t\t\tgl.REPEAT, gl.REPEAT)\n\n\t\tif err != nil {\n\t\t\tpanic(err)\n\t\t}\n\t\tp.diffuseTexture = texture0\n\n\t\tSetupAttributesMap(&p.programInfo, shaderVals)\n\t\tp.buffers.Vao = CreateTriangleVAO(&p.programInfo, p.vertexValues.Vertices, p.vertexValues.Normals, p.vertexValues.Uvs, nil, nil, p.vertexValues.Faces)\n\n\t} else if mat.ShaderType == 4 {\n\t\tshaderVals[\"aPosition\"] = true\n\t\tshaderVals[\"aNormal\"] = true\n\t\tshaderVals[\"aUV\"] = true\n\t\tshaderVals[\"diffuseVal\"] = true\n\t\tshaderVals[\"ambientVal\"] = true\n\t\tshaderVals[\"specularVal\"] = true\n\t\tshaderVals[\"nVal\"] = true\n\t\tshaderVals[\"uProjectionMatrix\"] = true\n\t\tshaderVals[\"uViewMatrix\"] = true\n\t\tshaderVals[\"uModelMatrix\"] = true\n\t\tshaderVals[\"pointLights\"] = true\n\t\tshaderVals[\"cameraPosition\"] = true\n\t\tshaderVals[\"uDiffuseTexture\"] = true\n\n\t\t//calculate tangents and bitangents\n\t\ttangents, bitangents := CalculateBitangents(p.vertexValues.Vertices, p.vertexValues.Uvs)\n\n\t\tbS := &shader.BlinnDiffuseAndNormal{}\n\t\tbS.Setup()\n\t\tp.shaderVal = bS\n\t\tp.programInfo.Program = InitOpenGL(p.shaderVal.GetVertShader(), p.shaderVal.GetFragShader(), p.shaderVal.GetGeometryShader())\n\t\tp.programInfo.attributes = Attributes{\n\t\t\tposition: 0,\n\t\t\tnormal: 1,\n\t\t\tuv: 2,\n\t\t\ttangent: 3,\n\t\t\tbitangent: 4,\n\t\t}\n\t\t//load diffuse texture\n\t\ttexture0, err := texture.NewTextureFromFile(\"../Editor/materials/\"+p.material.DiffuseTexture,\n\t\t\tgl.REPEAT, gl.REPEAT)\n\n\t\tif err != nil {\n\t\t\tpanic(err)\n\t\t}\n\t\t//load normal texture\n\t\ttexture1, err := texture.NewTextureFromFile(\"../Editor/materials/\"+p.material.NormalTexture,\n\t\t\tgl.REPEAT, gl.REPEAT)\n\n\t\tif err != nil {\n\t\t\tpanic(err)\n\t\t}\n\n\t\tp.diffuseTexture = texture0\n\t\tp.normalTexture = texture1\n\n\t\tSetupAttributesMap(&p.programInfo, shaderVals)\n\t\tp.buffers.Vao = CreateTriangleVAO(&p.programInfo, p.vertexValues.Vertices, p.vertexValues.Normals, p.vertexValues.Uvs, tangents, bitangents, p.vertexValues.Faces)\n\n\t}\n\n\tp.boundingBox = GetBoundingBox(p.vertexValues.Vertices)\n\n\tif collide {\n\t\tp.boundingBox.Collide = true\n\t} else {\n\t\tp.boundingBox.Collide = false\n\t}\n\tp.Scale(mod.Scale)\n\tp.boundingBox = ScaleBoundingBox(p.boundingBox, mod.Scale)\n\tp.model.Position = mod.Position\n\tp.boundingBox = TranslateBoundingBox(p.boundingBox, mod.Position)\n\tp.model.Rotation = mod.Rotation\n\tp.centroid = CalculateCentroid(p.vertexValues.Vertices, p.model.Scale)\n\tp.onCollide = func(box BoundingBox) {}\n\tp.reflective = reflective\n\tp.refractionIndex = refractionIndex\n\n\treturn nil\n}", "func (p *Prog) BuildProgram() {\n\tvar (\n\t\tprogram gl.Program\n\t\tvshader gl.Shader\n\t\tfshader gl.Shader\n\t)\n\tprogram = gl.CreateProgram()\n\t//vertex shader\n\tvshader = gl.CreateShader(gl.VERTEX_SHADER)\n\tgl.ShaderSource(vshader, p.Vs)\n\tgl.CompileShader(vshader)\n\tif gl.GetShaderi(vshader, gl.COMPILE_STATUS) == gl.FALSE {\n\t\tlog.Printf(\"glprog: VS compilation failed: %v\", gl.GetShaderInfoLog(vshader))\n\t}\n\t//fragment shader\n\tfshader = gl.CreateShader(gl.FRAGMENT_SHADER)\n\tgl.ShaderSource(fshader, p.Fs)\n\tgl.CompileShader(fshader)\n\tif gl.GetShaderi(fshader, gl.COMPILE_STATUS) == gl.FALSE {\n\t\tlog.Printf(\"glprog: FS compilation failed: %v\", gl.GetShaderInfoLog(fshader))\n\t}\n\t//link program\n\tgl.AttachShader(program, vshader)\n\tgl.AttachShader(program, fshader)\n\tgl.LinkProgram(program)\n\tif gl.GetProgrami(program, gl.LINK_STATUS) == gl.FALSE {\n\t\tlog.Printf(\"glprog: LinkProgram failed: %v\", gl.GetProgramInfoLog(program))\n\t\tgl.DeleteProgram(program)\n\t}\n\t//mark shaders for deletion when program is unlinked\n\tgl.DeleteShader(vshader)\n\tgl.DeleteShader(fshader)\n\n\tp.P = program\n\tfor i := range p.Uniforms {\n\t\tp.Uniforms[i].Location = gl.GetUniformLocation(p.P, p.Uniforms[i].Name)\n\t}\n}", "func ShaderSource(shader Uint, count Sizei, string []string, length []Int) {\n\tcshader, _ := (C.GLuint)(shader), cgoAllocsUnknown\n\tccount, _ := (C.GLsizei)(count), cgoAllocsUnknown\n\tcstring, _ := unpackArgSString(string)\n\tclength, _ := (*C.GLint)(unsafe.Pointer((*sliceHeader)(unsafe.Pointer(&length)).Data)), cgoAllocsUnknown\n\tC.glShaderSource(cshader, ccount, cstring, clength)\n\tpackSString(string, cstring)\n}", "func ActiveShaderProgram(pipeline uint32, program uint32) {\n C.glowActiveShaderProgram(gpActiveShaderProgram, (C.GLuint)(pipeline), (C.GLuint)(program))\n}", "func (self *TileSprite) SetShaderA(member *AbstractFilter) {\n self.Object.Set(\"shader\", member)\n}", "func ShaderSource(shader uint32, count int32, xstring **uint8, length *int32) {\n\tC.glowShaderSource(gpShaderSource, (C.GLuint)(shader), (C.GLsizei)(count), (**C.GLchar)(unsafe.Pointer(xstring)), (*C.GLint)(unsafe.Pointer(length)))\n}", "func ShaderSource(shader uint32, count int32, xstring **uint8, length *int32) {\n\tC.glowShaderSource(gpShaderSource, (C.GLuint)(shader), (C.GLsizei)(count), (**C.GLchar)(unsafe.Pointer(xstring)), (*C.GLint)(unsafe.Pointer(length)))\n}", "func ShaderSource(s Shader, src string) {\n\tglsource, free := gl.Strs(src + \"\\x00\")\n\tgl.ShaderSource(s.Value, 1, glsource, nil)\n\tfree()\n}", "func AttachShader(p Program, s Shader) {\n\tgl.AttachShader(p.Value, s.Value)\n}", "func ShaderBinary(count int32, shaders *uint32, binaryformat uint32, binary unsafe.Pointer, length int32) {\n\tsyscall.Syscall6(gpShaderBinary, 5, uintptr(count), uintptr(unsafe.Pointer(shaders)), uintptr(binaryformat), uintptr(binary), uintptr(length), 0)\n}", "func initOpenGL() uint32 {\n\tif err := gl.Init(); err != nil {\n\t\tpanic(err)\n\t}\n\tversion := gl.GoStr(gl.GetString(gl.VERSION))\n\tlog.Println(\"OpenGL version\", version)\n\n\tvertexShaderSource, err := files.ReadTextFile(vertexShaderFile)\n\tmust(err)\n\n\tvertexShaderSource += \"\\x00\"\n\n\tfragmentShaderSource, err := files.ReadTextFile(fragmentShaderFile)\n\tmust(err)\n\n\tfragmentShaderSource += \"\\x00\"\n\n\tvertexShader, err := compileShader(vertexShaderSource, gl.VERTEX_SHADER)\n\tmust(err)\n\n\tfragmentShader, err := compileShader(fragmentShaderSource, gl.FRAGMENT_SHADER)\n\tmust(err)\n\n\tprogram := gl.CreateProgram()\n\tgl.AttachShader(program, vertexShader)\n\tgl.AttachShader(program, fragmentShader)\n\tgl.LinkProgram(program)\n\n\tvar status int32\n\tgl.GetProgramiv(program, gl.LINK_STATUS, &status)\n\tif status == gl.FALSE {\n\t\tvar logLength int32\n\t\tgl.GetProgramiv(program, gl.INFO_LOG_LENGTH, &logLength)\n\n\t\tlog := strings.Repeat(\"\\x00\", int(logLength+1))\n\t\tgl.GetProgramInfoLog(program, logLength, nil, gl.Str(log))\n\n\t\terr := fmt.Errorf(\"failed to link program: %v\", log)\n\t\tpanic(err)\n\t}\n\n\tgl.DeleteShader(vertexShader)\n\tgl.DeleteShader(fragmentShader)\n\n\treturn program\n}", "func (am *Manager) AddShader(name string, shader uint32) error {\n\tif _, ok := am.GetShader(name); ok {\n\t\treturn fmt.Errorf(\"asset.Manager.AddShader error: Shader '%s' already exists\", name)\n\t}\n\n\tLogger.Printf(\"Manager: adding Shader '%s'\\n\", name)\n\tam.Shaders[name] = shader\n\n\treturn nil\n}", "func (debugging *debuggingOpenGL) CompileShader(shader uint32) {\n\tdebugging.recordEntry(\"CompileShader\", shader)\n\tdebugging.gl.CompileShader(shader)\n\tdebugging.recordExit(\"CompileShader\")\n}", "func Make(width, height int, internalformat int32, format, pixelType uint32,\n\tdata unsafe.Pointer, min, mag, s, t int32) Texture {\n\n\ttexture := Texture{0, gl.TEXTURE_2D, 0}\n\n\t// generate and bind texture\n\tgl.GenTextures(1, &texture.handle)\n\ttexture.Bind(0)\n\n\t// set texture properties\n\tgl.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, min)\n\tgl.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, mag)\n\tgl.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_S, s)\n\tgl.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_T, t)\n\n\t// specify a texture image\n\tgl.TexImage2D(gl.TEXTURE_2D, 0, internalformat, int32(width), int32(height),\n\t\t0, format, pixelType, data)\n\n\t// unbind texture\n\ttexture.Unbind()\n\n\treturn texture\n}", "func (native *OpenGL) CreateProgram() uint32 {\n\treturn gl.CreateProgram()\n}", "func makeVao(data []float32) uint32 {\n\tvar vbo uint32\n\tgl.GenBuffers(1, &vbo)\n\tgl.BindBuffer(gl.ARRAY_BUFFER, vbo)\n\tgl.BufferData(gl.ARRAY_BUFFER, 4*len(data), gl.Ptr(data), gl.STATIC_DRAW)\n\n\tvar vao uint32\n\tgl.GenVertexArrays(1, &vao)\n\tgl.BindVertexArray(vao)\n\tgl.BindBuffer(gl.ARRAY_BUFFER, vbo)\n\tvar offset int\n\n\t// position attribute\n\tgl.VertexAttribPointer(0, 3, gl.FLOAT, false, 8*4, gl.PtrOffset(offset))\n\tgl.EnableVertexAttribArray(0)\n\toffset += 3 * 4\n\n\t// color attribute\n\tgl.VertexAttribPointer(1, 3, gl.FLOAT, false, 8*4, gl.PtrOffset(offset))\n\tgl.EnableVertexAttribArray(1)\n\toffset += 3 * 4\n\n\t// texture coord attribute\n\tgl.VertexAttribPointer(2, 2, gl.FLOAT, false, 8*4, gl.PtrOffset(offset))\n\tgl.EnableVertexAttribArray(2)\n\toffset += 2 * 4\n\n\treturn vao\n}", "func CreateProgram() Uint {\n\t__ret := C.glCreateProgram()\n\t__v := (Uint)(__ret)\n\treturn __v\n}", "func (s *Shader) Destroy() {\n\ts.destroyVertexShader()\n\ts.destroyFragmentShader()\n\tif s.programID != 0 {\n\t\tgl.DeleteProgram(s.programID)\n\t\ts.programID = 0\n\t}\n}", "func ReleaseShaderCompiler() {\n C.glowReleaseShaderCompiler(gpReleaseShaderCompiler)\n}", "func ShaderProgramFill(r, g, b, a byte) *shaderir.Program {\n\tir, err := graphics.CompileShader([]byte(fmt.Sprintf(`//kage:unit pixels\n\npackage main\n\nfunc Fragment(position vec4, texCoord vec2, color vec4) vec4 {\n\treturn vec4(%0.9f, %0.9f, %0.9f, %0.9f)\n}\n`, float64(r)/0xff, float64(g)/0xff, float64(b)/0xff, float64(a)/0xff)))\n\tif err != nil {\n\t\tpanic(err)\n\t}\n\treturn ir\n}", "func ShaderBinary(count Sizei, shaders []Uint, binaryformat Enum, binary unsafe.Pointer, length Sizei) {\n\tccount, _ := (C.GLsizei)(count), cgoAllocsUnknown\n\tcshaders, _ := (*C.GLuint)(unsafe.Pointer((*sliceHeader)(unsafe.Pointer(&shaders)).Data)), cgoAllocsUnknown\n\tcbinaryformat, _ := (C.GLenum)(binaryformat), cgoAllocsUnknown\n\tcbinary, _ := (unsafe.Pointer)(unsafe.Pointer(binary)), cgoAllocsUnknown\n\tclength, _ := (C.GLsizei)(length), cgoAllocsUnknown\n\tC.glShaderBinary(ccount, cshaders, cbinaryformat, cbinary, clength)\n}", "func (debugging *debuggingOpenGL) CreateProgram() uint32 {\n\tdebugging.recordEntry(\"CreateProgram\")\n\tresult := debugging.gl.CreateProgram()\n\tdebugging.recordExit(\"CreateProgram\", result)\n\treturn result\n}", "func (obj *Device) CreatePixelShader(\n\tfunction uintptr,\n) (shader *PixelShader, err Error) {\n\tret, _, _ := syscall.Syscall(\n\t\tobj.vtbl.CreatePixelShader,\n\t\t3,\n\t\tuintptr(unsafe.Pointer(obj)),\n\t\tfunction,\n\t\tuintptr(unsafe.Pointer(&shader)),\n\t)\n\terr = toErr(ret)\n\treturn\n}", "func DeleteShader(s Shader) {\n\tgl.DeleteShader(s.Value)\n}", "func GetShaderiv(shader uint32, pname uint32, params *int32) {\n C.glowGetShaderiv(gpGetShaderiv, (C.GLuint)(shader), (C.GLenum)(pname), (*C.GLint)(unsafe.Pointer(params)))\n}", "func DetachShader(program uint32, shader uint32) {\n C.glowDetachShader(gpDetachShader, (C.GLuint)(program), (C.GLuint)(shader))\n}", "func (gl *WebGL) NewBuffer(target GLEnum, data interface{}, usage GLEnum) WebGLBuffer {\n\tbuffer := gl.CreateBuffer()\n\tgl.BindBuffer(target, buffer)\n\tgl.BufferData(target, data, usage)\n\treturn buffer\n}", "func IsShader(shader uint32) bool {\n ret := C.glowIsShader(gpIsShader, (C.GLuint)(shader))\n return ret == TRUE\n}", "func (native *OpenGL) GLShaderSource(shader uint32, count int32, xstring **uint8, length *int32) {\n\tgl.ShaderSource(shader, count, xstring, length)\n}", "func (am *Manager) LoadProgram(vfile, ffile, gfile string) (uint32, error) {\n\tvar (\n\t\tset ShaderSet\n\t\terr error\n\t)\n\n\tif set.Vs, err = am.LoadShader(gl.VERTEX_SHADER, vfile); err != nil {\n\t\treturn 0, err\n\t}\n\tif set.Fs, err = am.LoadShader(gl.FRAGMENT_SHADER, ffile); err != nil {\n\t\treturn 0, err\n\t}\n\tif len(gfile) > 0 {\n\t\tif set.Gs, err = am.LoadShader(gl.GEOMETRY_SHADER, gfile); err != nil {\n\t\t\treturn 0, err\n\t\t}\n\t}\n\n\tif prog, ok := am.GetProgram(set); ok {\n\t\treturn prog, nil\n\t}\n\n\tLogger.Printf(\"Manager: loading Program '%v'\\n\", set)\n\n\tvar prog = gl.CreateProgram()\n\tgl.AttachShader(prog, set.Vs)\n\tgl.AttachShader(prog, set.Fs)\n\tif set.Gs > 0 {\n\t\tgl.AttachShader(prog, set.Gs)\n\t}\n\tgl.LinkProgram(prog)\n\n\tvar infoLogLen int32\n\tgl.GetProgramiv(prog, gl.INFO_LOG_LENGTH, &infoLogLen)\n\n\tif infoLogLen > 1 {\n\t\tvar log = make([]uint8, infoLogLen)\n\t\tgl.GetProgramInfoLog(prog, infoLogLen, nil, &log[0])\n\t\treturn 0, errors.New(string(log))\n\t}\n\n\tam.AddProgram(set, prog)\n\n\treturn prog, nil\n}", "func NewHealth() *Health {\n\tconst vertexShader = `\n\t\t#version 410\n\n\t\tin vec4 coord;\n\t\tout vec2 tcoord;\n\n\t\tvoid main(void) {\n\t\t\tgl_Position = vec4(coord.xy, 0, 1);\n\t\t\ttcoord = coord.zw;\n\t\t}\n\t`\n\n\tconst fragmentShader = `\n\t\t#version 410\n\n\t\tin vec2 tcoord;\n\t\tuniform sampler2D tex;\n\t\tout vec4 frag_color;\n\n\t\tvoid main(void) {\n\t\t\tvec4 texel = texture(tex, tcoord);\n\t\t\tfrag_color = texel;\n\t\t}\n\t`\n\n\th := Health{}\n\n\th.program = createProgram(vertexShader, fragmentShader)\n\tbindAttribute(h.program, 0, \"coord\")\n\n\th.textureUniform = uniformLocation(h.program, \"tex\")\n\th.pointsVBO = newVBO()\n\th.drawableVAO = newPointsVAO(h.pointsVBO, 4)\n\n\trgba, _ := LoadImages([]string{\"textures/health.png\", \"textures/health-empty.png\"}, 16)\n\th.textureUnit = 4\n\tgl.ActiveTexture(uint32(gl.TEXTURE0 + h.textureUnit))\n\tgl.GenTextures(1, &h.texture)\n\tgl.BindTexture(gl.TEXTURE_2D, h.texture)\n\n\tgl.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_S, gl.CLAMP_TO_EDGE)\n\tgl.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_T, gl.CLAMP_TO_EDGE)\n\tgl.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.LINEAR)\n\tgl.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, gl.NEAREST)\n\n\tgl.TexImage2D(\n\t\tgl.TEXTURE_2D,\n\t\t0,\n\t\tgl.RGBA,\n\t\tint32(rgba.Rect.Size().X),\n\t\tint32(rgba.Rect.Size().Y),\n\t\t0,\n\t\tgl.RGBA,\n\t\tgl.UNSIGNED_BYTE,\n\t\tgl.Ptr(rgba.Pix),\n\t)\n\n\tgl.GenerateMipmap(gl.TEXTURE_2D)\n\treturn &h\n}", "func (program Program) AttachShader(shader Shader) {\n\tgl.AttachShader(uint32(program), uint32(shader))\n}", "func ShadeModel(mode uint32) {\n C.glowShadeModel(gpShadeModel, (C.GLenum)(mode))\n}", "func GetShaderSource(shader uint32, bufSize int32, length *int32, source *int8) {\n C.glowGetShaderSource(gpGetShaderSource, (C.GLuint)(shader), (C.GLsizei)(bufSize), (*C.GLsizei)(unsafe.Pointer(length)), (*C.GLchar)(unsafe.Pointer(source)))\n}", "func AttachShader(program uint32, shader uint32) {\n\tsyscall.Syscall(gpAttachShader, 2, uintptr(program), uintptr(shader), 0)\n}", "func AttachShader(program Uint, shader Uint) {\n\tcprogram, _ := (C.GLuint)(program), cgoAllocsUnknown\n\tcshader, _ := (C.GLuint)(shader), cgoAllocsUnknown\n\tC.glAttachShader(cprogram, cshader)\n}", "func UseProgram() gl.Uint {\n\tprogram, err := CreateProgram(\n\t\tReadVertexShader(\"Demo.glsl\"),\n\t\tReadFragmentShader(\"Demo.glsl\"))\n\tif err != nil {\n\t\tpanic(err)\n\t}\n\n\tgl.UseProgram(program)\n\n\treturn program\n}", "func CreateProgram() uint32 {\n ret := C.glowCreateProgram(gpCreateProgram)\n return (uint32)(ret)\n}", "func (s *s2d) Pre() error {\n\treturn Exec(func() error {\n\t\tflush_errors(\"pre: start\")\n\t\ts.vao = gl.GenVertexArray()\n\t\ts.vao.Bind()\n\n\t\ts.vertvbo = gl.GenBuffer()\n\t\ts.vertvbo.Bind(gl.ARRAY_BUFFER)\n\t\ts.quad = []float32{\n\t\t\t0.9, 0.9,\n\t\t\t0.9, -0.9,\n\t\t\t-0.9, -0.9,\n\t\t\t-0.9, 0.9,\n\t\t}\n\t\t// unsafe.Sizeof(quad) seems to think quad is 24 bytes, which is absurd.\n\t\t// so we just calculate the size manually.\n\t\tgl.BufferData(gl.ARRAY_BUFFER, len(s.quad)*4, s.quad, gl.STATIC_DRAW)\n\n\t\tflush_errors(\"creating program\")\n\t\ts.program = s2dprogram()\n\t\tflush_errors(\"program created, gen'ing texturing\")\n\n\t\ts.texture = gl.GenTexture()\n\t\tgl.ActiveTexture(gl.TEXTURE0)\n\t\ts.texture.Bind(gl.TEXTURE_2D)\n\n\t\tgl.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.LINEAR)\n\t\tgl.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, gl.LINEAR)\n\t\t// never ever use anything but clamp to edge; others do not make any sense.\n\t\tgl.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_R, gl.CLAMP_TO_EDGE)\n\t\tgl.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_S, gl.CLAMP_TO_EDGE)\n\t\tgl.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_T, gl.CLAMP_TO_EDGE)\n\t\ttxs2d := s.program.GetUniformLocation(tex2dname)\n\t\ttxs2d.Uniform1i(0)\n\t\tflush_errors(\"setting '\" + tex2dname + \"' uniform.\")\n\n\t\ts.fldmaxloc = s.program.GetUniformLocation(\"fieldmax\")\n\t\tgfx.Trace(\"field max loc is: %v\\n\", s.fldmaxloc)\n\t\treturn nil\n\t})\n}", "func (sm *shaderManager) LoadProgramFromSrc(vertSrc string, fragSrc string, name string, shouldBeDefault bool) (Shader, error) {\n\tif program, alreadyLoaded := sm.GetShader(name); alreadyLoaded {\n\t\treturn program, nil\n\t}\n\n\tif !strings.HasSuffix(vertSrc, \"\\x00\") {\n\t\tvertSrc = vertSrc + \"\\x00\"\n\t}\n\n\tif !strings.HasSuffix(fragSrc, \"\\x00\") {\n\t\tfragSrc = fragSrc + \"\\x00\"\n\t}\n\n\tprogram, err := newProgram(vertSrc, fragSrc)\n\tif err != nil {\n\t\tfmt.Println(err)\n\t\treturn nil, err\n\t}\n\n\tsm.programLock.Lock()\n\tdefer sm.programLock.Unlock()\n\n\tshader := newShader(name, program)\n\tsm.shaders[name] = shader\n\n\tif len(sm.shaders) == 1 || shouldBeDefault {\n\t\tsm.DefaultShader = name\n\t}\n\n\treturn shader, nil\n}", "func (sh *ShaderStd) PostRender() error { return nil }", "func finalizeShader(n *nativeShader) {\n\tn.r.Lock()\n\n\t// If the shader program is zero, it has already been free'd.\n\tif n.program == 0 {\n\t\tn.r.Unlock()\n\t\treturn\n\t}\n\tn.r.shaders = append(n.r.shaders, n)\n\tn.r.Unlock()\n}", "func (gl *WebGL) CompileShader(shader WebGLShader) error {\n\tgl.context.Call(\"compileShader\", shader)\n\n\tif !gl.GetShaderParameter(shader, GlCompileStatus).Bool() {\n\t\terr := errors.New(gl.GetShaderInfoLog(shader))\n\t\tlog.Println(\"Failed to compile shader\", err)\n\t\treturn err\n\t}\n\n\treturn nil\n}", "func (native *OpenGL) AttachShader(program uint32, shader uint32) {\n\tgl.AttachShader(program, shader)\n}" ]
[ "0.7346397", "0.71875364", "0.7007328", "0.700519", "0.68544656", "0.6846669", "0.6674217", "0.6651398", "0.6651065", "0.6644338", "0.65123326", "0.64587116", "0.6447906", "0.6428075", "0.63679135", "0.63679135", "0.6272525", "0.62461555", "0.61304414", "0.61302114", "0.6056366", "0.60419303", "0.60346395", "0.60304946", "0.5971145", "0.59301484", "0.5911027", "0.5910693", "0.58917683", "0.5887909", "0.58874756", "0.5862201", "0.58467484", "0.5828114", "0.58272517", "0.57857734", "0.57841015", "0.5783781", "0.5766003", "0.5754314", "0.5727654", "0.57208264", "0.5713479", "0.5712083", "0.5677418", "0.566438", "0.56502163", "0.5639766", "0.56220967", "0.5621257", "0.55975616", "0.5577677", "0.5577677", "0.5570512", "0.5570512", "0.5560725", "0.5555267", "0.55551434", "0.55540776", "0.5550227", "0.55122167", "0.55122167", "0.5498875", "0.54919195", "0.547052", "0.54675543", "0.54632324", "0.54600453", "0.54213953", "0.54067177", "0.54043543", "0.54005915", "0.53997374", "0.5392455", "0.5390785", "0.53577185", "0.53479236", "0.53257036", "0.53247905", "0.5318524", "0.5305829", "0.5303599", "0.53022385", "0.5288513", "0.5281678", "0.5266182", "0.52386594", "0.5238239", "0.52321386", "0.5216272", "0.5204353", "0.51936406", "0.5187775", "0.5185806", "0.5182182", "0.5180872", "0.51806957", "0.51800305", "0.51785195" ]
0.6703814
7
create a standalone program from an array of nullterminated source code strings
func CreateShaderProgramv(xtype uint32, count int32, strings **uint8) uint32 { ret := C.glowCreateShaderProgramv(gpCreateShaderProgramv, (C.GLenum)(xtype), (C.GLsizei)(count), (**C.GLchar)(unsafe.Pointer(strings))) return (uint32)(ret) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func NewCompilerFromString(inProgram string) *Compiler {\n\tvar inpProgram []string\n\t// remove all tabs chars\n\tinProgram = strings.Replace(inProgram, \"\\t\", \"\", -1)\n\tinpProgram = strings.Split(inProgram, \"\\n\")\n\t// build the inputProgram array with all instructions and vars right here\n\treturn &Compiler{\n\t\tinputProgram: inpProgram,\n\t\tOutputProgram: initOutputProgram(),\n\t}\n}", "func createProgram(packages ...string) (*loader.Program, error) {\n\tvar conf loader.Config\n\n\tfor _, name := range packages {\n\t\tconf.CreateFromFilenames(name, getFileNames(name)...)\n\t}\n\treturn conf.Load()\n}", "func NewBootCodeFromStringInstructions(input []string) BootCode {\n\treturn NewBootCode(mustParseInstructions(input))\n}", "func NewProgram(data []byte) *Program {\n\tp := new(Program)\n\tp.data = make([]byte, len(data))\n\tcopy(data, p.data)\n\tp.Pc = 0\n\treturn p\n}", "func newProgramCode() programCode {\n\tvar code programCode\n\tcode.intMap = make(map[string]int64)\n\tcode.stringMap = make(map[string]string)\n\tcode.strCounter = 0\n\tcode.funcSlice = make([]string, 100) // TODO: Make this more dynamic e.g.: zero-length slice with dynamic append()\n\tcode.lastLabel = make([]string, 100) // TODO: Make this more dynamic e.g.: zero-length slice with dynamic append()\n\tcode.labelCounter = 0\n\n\tcode.indentLevel = 0\n\tcode.labelFlag = false\n\tcode.forLoopFlag = false\n\tcode.code = \"\"\n\tcode.funcCode = make([]string, 100) // TODO: Make this more dynamic e.g.: zero-length slice with dynamic append()\n\n\treturn code\n}", "func generate_code(inFile *C.char, outFile *C.char, tags **C.char, tags_length C.size_t) *C.char {\n\t_tags := []string{}\n\tfor i := 0; i < int(tags_length); i++ {\n\t\tp := C.get_p(tags, C.int(i))\n\t\t_tags = append(_tags, C.GoString(p))\n\t}\n\n\terr := GenerateCode(C.GoString(inFile), C.GoString(outFile), _tags, \"main\")\n\tif err == nil {\n\t\treturn renderData(\"ok\")\n\t} else {\n\t\treturn renderError(err)\n\t}\n}", "func getGoSourceProgram() string {\n\tcontents := `\npackage main\n\nimport \"time\"\nimport \"io/ioutil\"\n\nfunc main() {\n\tioutil.WriteFile(\"STARTED\", []byte(\"STARTED\\n\"), 0644)\n\t// Ensure it wont exit immediately\n\ttime.Sleep(10 * time.Minute)\n\tioutil.WriteFile(\"FINISHED\", []byte(\"FINISHED\\n\"), 0644)\n\n}\n\t`\n\treturn contents\n}", "func main() {\n\tdefer contracts.ShowHelp(help)\n\tnProd, nCons, bufferSize := parseArguments()\n\n\tprogram(nProd, nCons, bufferSize)\n}", "func parseInput(input string) (program, error) {\n lines := strings.Split(input, \"\\n\")\n retval := NewProgram()\n hasDataRegex := regexp.MustCompile(\"[^[:space:]]\")\n lineRegex := regexp.MustCompile(\"(nop|acc|jmp)[[:space:]]+((?:\\\\+|-)?[[:digit:]]+)\")\n for _, line := range lines {\n if hasDataRegex.MatchString(line) {\n lineMatch := lineRegex.FindStringSubmatch(line)\n if len(lineMatch) != 3 {\n return retval, fmt.Errorf(\"Could not parse line [%s].\", line)\n }\n err := retval.addInstruction(lineMatch[1], lineMatch[2])\n if err != nil {\n return retval, err\n }\n }\n }\n return retval, nil\n}", "func NewProgram() Program {\n\treturn &program{\n\t\tstatements: make([]Statement, 0, 5),\n\t}\n}", "func execNewArray(_ int, p *gop.Context) {\n\targs := p.GetArgs(2)\n\tret := types.NewArray(args[0].(types.Type), args[1].(int64))\n\tp.Ret(2, ret)\n}", "func system_program(code []byte, fileName string, num *int, args []string) []byte {\n\n\tvar output []byte\n\n\tif num != nil {\n\t\targs = append([]string{strconv.Itoa(*num)}, args...)\n\t}\n\n\toutput = run(fileName, args...)\n\n\treturn output\n}", "func buildAndCopyProgram(src io.Reader) error {\n\t// FIXME: BuildProgram should probably be in some other package,\n\t// so that it can be used by both the compiler tests and the\n\t// command line client.\n\td, err := ioutil.TempDir(\"\", \"langbuild\")\n\tif err != nil {\n\t\treturn err\n\t}\n\tif debug {\n\t\tlog.Println(\"Using temporary directory\", d, \"(WARNING: will not automatically delete in debug mode)\")\n\t}\n\tif !debug {\n\t\tdefer os.RemoveAll(d)\n\t}\n\texe, err := codegen.BuildProgram(d, src)\n\tif err != nil {\n\t\treturn err\n\t}\n\tif exe == \"\" {\n\t\treturn fmt.Errorf(\"No executable built.\")\n\t}\n\tcwd, err := os.Getwd()\n\tif err != nil {\n\t\treturn err\n\t}\n\tname := path.Base(cwd)\n\tif name == \".\" || name == \"\" || name == \"/\" {\n\t\tlog.Fatal(\"Could not determine appropriate executable name.\")\n\t}\n\treturn copyFile(d+\"/\"+exe, \"./\"+name)\n}", "func main() {\n\tInitVars()\n\ttfmBins := InitTfmBins(&OsPath)\n\tverConstraints, err := ParseTfmConfigs(\"./\")\n\tif err != nil {\n\t\tfmt.Fprintf(os.Stderr, \"[ERROR] %s\", err.Error())\n\t\tos.Exit(1)\n\t}\n\ttfmBinFile := SelectTfmBin(verConstraints, tfmBins)\n\tmyDebug(\"Calling: %s\", tfmBinFile)\n\tif tfmBinFile == \"\" {\n\t\tfmt.Println(\"[ERROR] there is no file to execute\")\n\t\tos.Exit(1)\n\t}\n\tout, err := exec.Command(tfmBinFile, os.Args[1:]...).CombinedOutput()\n\tfmt.Println(string(out[:]))\n\tif err != nil {\n\t\tos.Exit(1)\n\t}\n}", "func NewCompilerFromFile(inProgramFile io.Reader) *Compiler {\n\tvar inpProgram []string\n\tscn := bufio.NewScanner(inProgramFile)\n\tfor scn.Scan() {\n\t\tline := scn.Text()\n\t\t// remove all tabs and new lines chars\n\t\tline = strings.Replace(strings.Replace(line, \"\\t\", \"\", -1), \"\\n\", \"\", -1)\n\t\tinpProgram = append(inpProgram, line)\n\t}\n\treturn &Compiler{\n\t\tinputProgram: inpProgram,\n\t\tOutputProgram: initOutputProgram(),\n\t}\n}", "func New(data ...Instr) *Code {\n\n\treturn &Code{data, nil}\n}", "func Executable() (string, error)", "func main() {\n\tlines := util.ReadLines()\n\n\tansP1, ansP2 := Exec(lines)\n\tfmt.Printf(\"Part1: %v\\n\", ansP1)\n\tfmt.Printf(\"Part2: %v\\n\", ansP2)\n}", "func progFromArgs(args []string) (prog *loader.Program, rest []string, err error) {\n\t// Configure type checker.\n\tvar conf loader.Config\n\trest, err = conf.FromArgs(args, false)\n\tif err != nil {\n\t\treturn nil, nil, err\n\t}\n\n\t// Load Go package.\n\tprog, err = conf.Load()\n\tif err != nil {\n\t\treturn nil, nil, err\n\t}\n\treturn prog, rest, nil\n}", "func Main(matchString func(pat, str string) (bool, error), tests []InternalTest, benchmarks []InternalBenchmark, examples []InternalExample)", "func Main(matchString func(pat, str string) (bool, error), tests []InternalTest, benchmarks []InternalBenchmark, examples []InternalExample) {}", "func IntcodeProgram() ([]int) {\n\treturn []int{3,225,1,225,6,6,1100,1,238,225,104,0,1002,114,46,224,1001,224,-736,224,4,224,1002,223,8,223,1001,224,3,224,1,223,224,223,1,166,195,224,1001,224,-137,224,4,224,102,8,223,223,101,5,224,224,1,223,224,223,1001,169,83,224,1001,224,-90,224,4,224,102,8,223,223,1001,224,2,224,1,224,223,223,101,44,117,224,101,-131,224,224,4,224,1002,223,8,223,101,5,224,224,1,224,223,223,1101,80,17,225,1101,56,51,225,1101,78,89,225,1102,48,16,225,1101,87,78,225,1102,34,33,224,101,-1122,224,224,4,224,1002,223,8,223,101,7,224,224,1,223,224,223,1101,66,53,224,101,-119,224,224,4,224,102,8,223,223,1001,224,5,224,1,223,224,223,1102,51,49,225,1101,7,15,225,2,110,106,224,1001,224,-4539,224,4,224,102,8,223,223,101,3,224,224,1,223,224,223,1102,88,78,225,102,78,101,224,101,-6240,224,224,4,224,1002,223,8,223,101,5,224,224,1,224,223,223,4,223,99,0,0,0,677,0,0,0,0,0,0,0,0,0,0,0,1105,0,99999,1105,227,247,1105,1,99999,1005,227,99999,1005,0,256,1105,1,99999,1106,227,99999,1106,0,265,1105,1,99999,1006,0,99999,1006,227,274,1105,1,99999,1105,1,280,1105,1,99999,1,225,225,225,1101,294,0,0,105,1,0,1105,1,99999,1106,0,300,1105,1,99999,1,225,225,225,1101,314,0,0,106,0,0,1105,1,99999,1107,226,677,224,102,2,223,223,1006,224,329,101,1,223,223,1108,226,677,224,1002,223,2,223,1005,224,344,101,1,223,223,8,226,677,224,102,2,223,223,1006,224,359,1001,223,1,223,1007,226,677,224,1002,223,2,223,1005,224,374,101,1,223,223,1008,677,677,224,1002,223,2,223,1005,224,389,1001,223,1,223,1108,677,226,224,1002,223,2,223,1006,224,404,1001,223,1,223,1007,226,226,224,1002,223,2,223,1005,224,419,1001,223,1,223,1107,677,226,224,1002,223,2,223,1006,224,434,101,1,223,223,108,677,677,224,1002,223,2,223,1005,224,449,1001,223,1,223,1107,677,677,224,102,2,223,223,1005,224,464,1001,223,1,223,108,226,226,224,1002,223,2,223,1006,224,479,1001,223,1,223,1008,226,226,224,102,2,223,223,1005,224,494,101,1,223,223,108,677,226,224,102,2,223,223,1005,224,509,1001,223,1,223,8,677,226,224,1002,223,2,223,1006,224,524,101,1,223,223,7,226,677,224,1002,223,2,223,1006,224,539,101,1,223,223,7,677,226,224,102,2,223,223,1006,224,554,1001,223,1,223,7,226,226,224,1002,223,2,223,1006,224,569,101,1,223,223,107,677,677,224,102,2,223,223,1006,224,584,101,1,223,223,1108,677,677,224,102,2,223,223,1006,224,599,1001,223,1,223,1008,677,226,224,1002,223,2,223,1005,224,614,1001,223,1,223,8,677,677,224,1002,223,2,223,1006,224,629,1001,223,1,223,107,226,677,224,1002,223,2,223,1006,224,644,101,1,223,223,1007,677,677,224,102,2,223,223,1006,224,659,101,1,223,223,107,226,226,224,1002,223,2,223,1006,224,674,1001,223,1,223,4,223,99,226}\n}", "func ConstructProgram(lines []Line) ([]machine.Operation, error) {\n\tconstructor := newConstructor()\n\tfor _, line := range lines {\n\t\tconstructor.processLine(line)\n\t}\n\treturn constructor.operations, constructor.err\n}", "func run(src string, tags string) error {\n\t// Create a temp folder.\n\ttempDir, err := ioutil.TempDir(\"\", \"vfsgendev_\")\n\tif err != nil {\n\t\treturn err\n\t}\n\tdefer func() {\n\t\terr := os.RemoveAll(tempDir)\n\t\tif err != nil {\n\t\t\tfmt.Fprintln(os.Stderr, \"warning: error removing temp dir:\", err)\n\t\t}\n\t}()\n\n\t// Write the source code file.\n\ttempFile := filepath.Join(tempDir, \"generate.go\")\n\terr = ioutil.WriteFile(tempFile, []byte(src), 0600)\n\tif err != nil {\n\t\treturn err\n\t}\n\n\t// Compile and run the program.\n\tcmd := exec.Command(\"go\", \"run\", \"-tags=\"+tags, tempFile)\n\tcmd.Stdout = os.Stdout\n\tcmd.Stderr = os.Stderr\n\treturn cmd.Run()\n}", "func NewProgram(params *utils.Params, in, out circuit.IO,\n\tconsts map[string]ConstantInst, steps []Step) (*Program, error) {\n\n\tprog := &Program{\n\t\tParams: params,\n\t\tInputs: in,\n\t\tOutputs: out,\n\t\tConstants: consts,\n\t\tSteps: steps,\n\t\twires: make(map[string]*wireAlloc),\n\t\tfreeWires: make(map[types.Size][][]*circuits.Wire),\n\t}\n\n\t// Inputs into wires.\n\tfor idx, arg := range in {\n\t\tif len(arg.Name) == 0 {\n\t\t\targ.Name = fmt.Sprintf(\"arg{%d}\", idx)\n\t\t}\n\t\twires, err := prog.Wires(arg.Name, types.Size(arg.Size))\n\t\tif err != nil {\n\t\t\treturn nil, err\n\t\t}\n\t\tprog.InputWires = append(prog.InputWires, wires...)\n\t}\n\n\treturn prog, nil\n}", "func Program(name string, env []string) Runner {\n\treturn &program{\n\t\tname: name,\n\t\tenv: append(os.Environ(), env...),\n\t}\n}", "func main() {\n\t\tif len(os.Args) < 2 {\n\t\t\tfmt.Println(\"Please select a shellcode file. (E.g.: hideit beacon.bin)\")\n\t\t\treturn\n\t\t}\n\t\tfilename := os.Args[1]\n\t\tpayload, err := ioutil.ReadFile(filename)\n\t\tif err != nil {\n\t\t\tfmt.Println(err)\n\t\t}\n\n\t\tencode := b64.StdEncoding.EncodeToString(payload)\n\t\thexencode := hex.EncodeToString([]byte(encode))\n\t\tciphertext := useful.Encrypt([]byte(hexencode), \"D00mfist\")\n\t\thexcipher := hex.EncodeToString(ciphertext)\n\n\t\tf, err := os.Create(\"shelly.go\")\n\t\tif err != nil {\n\t\t\tfmt.Println(err)\n\t\t\treturn\n\t\t}\n\t\tdefer f.Close()\n\t\ta, err := os.OpenFile(\"shelly.go\", os.O_WRONLY|os.O_APPEND, 0644)\n\t\ta.WriteString(\"package shelly\\n\" + \"var Sc =\" + strconv.Quote(hexcipher))\n\t\tif err != nil {\n\t\t\tfmt.Println(err)\n\t\t\treturn\n\t\t}\n\t\tuseful.MoveFile(\"shelly.go\", \"../../pkg/shelly/shelly.go\")\n\n\t\tfmt.Println(\"Encrypted Shellcode Written to shelly.go. It should be already placed at Go4aRun\\\\pkg\\\\shelly\\\\shelly.go \\nIf not then manually place there before building Go4it\")\n\n}", "func Run(filepath string) (int, error) {\n\n\tf := common.OpenFile(filepath)\n\tdefer common.CloseFile(f)\n\n\ts := bufio.NewScanner(f)\n\ts.Scan()\n\n\tparts := strings.Split(s.Text(), \",\")\n\terr := s.Err()\n\tif err != nil {\n\t\treturn 0, err\n\t}\n\n\tseq := make([]int, 0)\n\tfor _, elt := range parts {\n\t\tcode, err := strconv.Atoi(elt)\n\t\tif err != nil {\n\t\t\treturn 0, err\n\t\t}\n\n\t\tseq = append(seq, code)\n\t}\n\n\t// create a program instance to get the map and compute commands from it\n\tcreateProgram := intcode.ProgramCreator(seq)\n\tp := createProgram()\n\tout := make(chan int)\n\tquit := make(chan int)\n\tgo p.Run(nil, out, quit)\n\n\tspacemap := SpaceMap{}\n\tspacemap.PopulateFrom(out)\n\t<-quit\n\n\t// prepare functions A B C\n\tcds := spacemap.robotCommands()\n\tfmt.Printf(\"Commands(%v):\\n %v\\n\", len(cds.String()), cds)\n\tres := splitCommands(cds)\n\tfmt.Printf(\"Splitted:\\nA:%v\\nB:%v\\nC:%v\\nRoutine:%v\\n\", res.A, res.B, res.C, res.mainRoutine)\n\n\t// now create the real instance to send\n\tmanual := createProgram()\n\t// override movement logic\n\tmanual.SetMemory(0, 2)\n\n\tin2 := make(chan int)\n\tout2 := make(chan int)\n\tquit2 := make(chan int)\n\tgo manual.Run(in2, out2, quit2)\n\n\t// stack commands to send to the program\n\tgo send([]string{\n\t\t// Main:\n\t\tstrings.Join(res.mainRoutine, \",\"),\n\t\t// Function A:\n\t\tres.A.String(),\n\t\t// Function B:\n\t\tres.B.String(),\n\t\t// Function C:\n\t\tres.C.String(),\n\t\t// Continuous video feed?\n\t\t\"n\",\n\t}, in2)\n\n\t// output everything the program send to us\n\tgo output(out2)\n\t// make the main goroutine wait for termination of second program to stop\n\t<-quit2\n\n\treturn 0, nil\n}", "func New(data []byte, filename string) (*Exec, error) {\n\tlog.Tracef(\"Creating new at %v\", filename)\n\treturn loadExecutable(filename, data)\n}", "func main() {\n\tif len(os.Args) == 1 {\n\t\tlog.Fatal(\"There are no arguments!!!\")\n\t}\n\tif os.Args[1] == \"create\" {\n\t\tif len(os.Args[2]) == 0 || len(os.Args[3]) == 0 {\n\t\t\tlog.Fatal(\"Empty path or file name!!!\")\n\t\t}\n\t\tcreateProgram(os.Args[2], os.Args[3])\n\t\treturn\n\t}\n\tif os.Args[1] == \"search\" {\n\t\tif len(os.Args[3:]) == 0 {\n\t\t\treturn\n\t\t}\n\t\tsearchProgram(os.Args[2], os.Args[3:])\n\t\treturn\n\t}\n\n\tif os.Args[1] == \"searchAndBuild\" {\n\t\tif len(os.Args[2]) == 0 || len(os.Args[3]) == 0 || len(os.Args[4:]) == 0 {\n\t\t\tlog.Fatal(\"Empty path, file name or searching string!!!\")\n\t\t}\n\t\tcreateProgram(os.Args[2], os.Args[3])\n\t\tsearchProgram(os.Args[3]+\".txt\", os.Args[4:])\n\t\treturn\n\t}\n}", "func main() {\n\t// test mode\n\tif len(os.Args) >= 2 && os.Args[1] == \"test\" {\n\t\ttestCmdSet.Parse(os.Args[2:])\n\t\tif path := testCmdSet.Arg(0); path != \"\" {\n\t\t\texitCode := runTest(path)\n\t\t\tos.Exit(exitCode)\n\t\t}\n\t}\n\n\t// normal mode\n\tflag.Parse()\n\n\t// show version\n\tif *version {\n\t\tshowVersion()\n\t\tos.Exit(0)\n\t}\n\n\tsrc := \"\"\n\tif *jargon {\n\t\tsrc = readJargon()\n\t}\n\n\t// run one-liner\n\tif *oneLiner != \"\" {\n\t\tsrc += wrapSource(*oneLiner, *readsLines, *readsAndWritesLines)\n\t\texitCode := run(src, object.StrFileName)\n\t\tos.Exit(exitCode)\n\t}\n\n\tif srcFileName := flag.Arg(0); srcFileName != \"\" {\n\t\tfileSrc, exitCode := runscript.ReadFile(srcFileName)\n\t\tif exitCode != 0 {\n\t\t\tos.Exit(exitCode)\n\t\t}\n\t\tsrc += fileSrc\n\n\t\texitCode = run(src, srcFileName)\n\t\tos.Exit(exitCode)\n\t}\n\n\trunRepl(src)\n}", "func (p *Program) String() string {\n\tvar buf bytes.Buffer\n\n\tbuf.WriteString(fmt.Sprintf(`//\n//\tPackage - transpiled by c4go\n//\n//\tIf you have found any issues, please raise an issue at:\n//\thttps://github.com/Konstantin8105/c4go/\n//\n\n`))\n\n\t// Simplification from :\n\t//\tvar cc int32 = int32(uint8((func() []byte {\n\t//\t\tdefer func() {\n\t//\t\t\tfunc() []byte {\n\t//\t\t\t\ttempVarUnary := ss\n\t//\t\t\t\tdefer func() {\n\t//\t\t\t\t\tss = ss[0+1:]\n\t//\t\t\t\t}()\n\t//\t\t\t\treturn tempVarUnary\n\t//\t\t\t}()\n\t//\t\t}()\n\t//\t\treturn ss\n\t//\t}())[0]))\n\t//\n\t// to:\n\t//\tvar cc int32 = int32(uint8((func() []byte {\n\t//\t\tdefer func() {\n\t//\t\t\tss = ss[0+1:]\n\t//\t\t}()\n\t//\t\treturn ss\n\t//\t}())[0]))\n\tgoast.Walk(new(simpleDefer), p.File)\n\n\t// Only for debugging\n\t// goast.Walk(new(nilWalker), p.File)\n\n\t// First write all the messages. The double newline afterwards is important\n\t// so that the package statement has a newline above it so that the warnings\n\t// are not part of the documentation for the package.\n\tbuf.WriteString(strings.Join(p.messages, \"\\n\") + \"\\n\\n\")\n\n\tif err := format.Node(&buf, p.FileSet, p.File); err != nil {\n\t\t// Printing the entire AST will generate a lot of output. However, it is\n\t\t// the only way to debug this type of error. Hopefully the error\n\t\t// (printed immediately afterwards) will give a clue.\n\t\t//\n\t\t// You may see an error like:\n\t\t//\n\t\t// panic: format.Node internal error (692:23: expected selector or\n\t\t// type assertion, found '[')\n\t\t//\n\t\t// This means that when Go was trying to convert the Go AST to source\n\t\t// code it has come across a value or attribute that is illegal.\n\t\t//\n\t\t// The line number it is referring to (in this case, 692) is not helpful\n\t\t// as it references the internal line number of the Go code which you\n\t\t// will never see.\n\t\t//\n\t\t// The \"[\" means that there is a bracket in the wrong place. Almost\n\t\t// certainly in an identifer, like:\n\t\t//\n\t\t// noarch.IntTo[]byte(\"foo\")\n\t\t//\n\t\t// The \"[]\" which is obviously not supposed to be in the function name\n\t\t// is causing the syntax error. However, finding the original code that\n\t\t// produced this can be tricky.\n\t\t//\n\t\t// The first step is to filter down the AST output to probably lines.\n\t\t// In the error message it said that there was a misplaced \"[\" so that's\n\t\t// what we will search for. Using the original command (that generated\n\t\t// thousands of lines) we will add two grep filters:\n\t\t//\n\t\t// go test ... | grep \"\\[\" | grep -v '{$'\n\t\t// # | |\n\t\t// # | ^ This excludes lines that end with \"{\"\n\t\t// # | which almost certainly won't be what\n\t\t// # | we are looking for.\n\t\t// # |\n\t\t// # ^ This is the character we are looking for.\n\t\t//\n\t\t// Hopefully in the output you should see some lines, like (some lines\n\t\t// removed for brevity):\n\t\t//\n\t\t// 9083 . . . . . . . . . . Name: \"noarch.[]byteTo[]int\"\n\t\t// 9190 . . . . . . . . . Name: \"noarch.[]intTo[]byte\"\n\t\t//\n\t\t// These two lines are clearly the error because a name should not look\n\t\t// like this.\n\t\t//\n\t\t// Looking at the full output of the AST (thousands of lines) and\n\t\t// looking at those line numbers should give you a good idea where the\n\t\t// error is coming from; by looking at the parents of the bad lines.\n\t\t_ = goast.Print(p.FileSet, p.File)\n\n\t\tpanic(err)\n\t}\n\n\t// Add comments at the end C file\n\tfor file, beginLine := range p.commentLine {\n\t\tfor i := range p.PreprocessorFile.GetComments() {\n\t\t\tif p.PreprocessorFile.GetComments()[i].File == file {\n\t\t\t\tif beginLine.line < p.PreprocessorFile.GetComments()[i].Line {\n\t\t\t\t\tbuf.WriteString(\n\t\t\t\t\t\tfmt.Sprintln(\n\t\t\t\t\t\t\tp.PreprocessorFile.GetComments()[i].Comment))\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\t// simplify Go code. Example :\n\t// Before:\n\t// func compare(a interface {\n\t// }, b interface {\n\t// }) (c4goDefaultReturn int) {\n\t// After :\n\t// func compare(a interface {}, b interface {}) (c4goDefaultReturn int) {\n\treg := util.GetRegex(\"interface( )?{(\\r*)\\n(\\t*)}\")\n\ts := string(reg.ReplaceAll(buf.Bytes(), []byte(\"interface {}\")))\n\n\tsp := strings.Split(s, \"\\n\")\n\tfor i := range sp {\n\t\tif strings.HasSuffix(sp[i], \"-= 1\") {\n\t\t\tsp[i] = strings.TrimSuffix(sp[i], \"-= 1\") + \"--\"\n\t\t}\n\t\tif strings.HasSuffix(sp[i], \"+= 1\") {\n\t\t\tsp[i] = strings.TrimSuffix(sp[i], \"+= 1\") + \"++\"\n\t\t}\n\t}\n\n\treturn strings.Join(sp, \"\\n\")\n}", "func create(s string) (p program) {\n\tre := regexp.MustCompile(`\\w+`)\n\tt := re.FindAllStringSubmatch(s, -1)\n\tp.name = t[0][0]\n\tp.weight, _ = strconv.Atoi(string(t[1][0]))\n\tfor _, r := range t[2:] {\n\t\tp.children = append(p.children, program{r[0], 0, nil})\n\t}\n\treturn\n}", "func (i *Interpreter) run(w *eval.World, path_orEmpty string, sourceCode string) error {\n\tvar code eval.Code\n\tvar vars []string\n\tvar err error\n\n\tfileSet := token.NewFileSet()\n\tif len(path_orEmpty) > 0 {\n\t\tfileSet.AddFile(path_orEmpty, fileSet.Base(), len(sourceCode))\n\t}\n\n\tcode, vars, err = i.compile(w, fileSet, sourceCode)\n\ti.tryToAddVars(w, fileSet, vars)\n\tif err != nil {\n\t\treturn err\n\t}\n\n\tresult, err := code.Run()\n\tif err != nil {\n\t\treturn err\n\t}\n\n\tif result != nil {\n\t\tfmt.Fprintf(stdout, \"%s\\n\", result)\n\t}\n\n\treturn nil\n}", "func createGoProgram(t *testing.T, dir string) {\n\tfileName := dir + \"/testprogram.go\"\n\tcontents := getGoSourceProgram()\n\terr := ioutil.WriteFile(fileName, []byte(contents), 0644)\n\tif err != nil {\n\t\tt.Fatalf(\"failed to create test file: %s\", err)\n\t}\n}", "func SourceFromString(s string) *Source {\n return &Source{ Path: \"str\", Text: []byte(s) }\n}", "func NewProgram(lessons []*LessonPgm) *Program {\n\treturn &Program{base.WildCardLabel, lessons}\n}", "func main() {\n\tvar infile, outfile string\n\n\tflag.StringVar(&infile, \"infile\", \"\", \"HACK assembly filename\")\n\tflag.Parse()\n\n\tif err := validateInfile(infile); err != nil {\n\t\tfmt.Println(err)\n\t\tos.Exit(1)\n\t}\n\n\toutfile = makeOutfileName(infile)\n\n\tif err := assembler.Assemble(infile, outfile); err != nil {\n\t\tfmt.Println(err)\n\t}\n}", "func FromScripts(workspace string, scripts []string, prepareVM VMPrepareFunc) (*Helper, error) {\n\th := &Helper{\n\t\tScriptNames: scripts,\n\t\tScripts: make([]string, len(scripts)),\n\t\tVariableTranslations: make([]map[string]string, len(scripts)),\n\t\tVms: make([]*vm.VM, len(scripts)),\n\t\tCurrentScript: 0,\n\t\tCoordinator: vm.NewCoordinator(),\n\t\tWorspace: normalizePath(workspace),\n\t\tFinishedVMs: make(map[int]bool),\n\t\tValidBreakpoints: make(map[int]map[int]bool),\n\t\tCompiledCode: make(map[int]string),\n\t\tLocalVars: make([][]string, len(scripts)),\n\t\tGlobalVars: make([]string, 0, 10),\n\t}\n\n\tfor i, inputFileName := range h.ScriptNames {\n\t\tfilecontent, err := ioutil.ReadFile(JoinPath(workspace, inputFileName))\n\t\tif err != nil {\n\t\t\treturn nil, err\n\t\t}\n\n\t\th.Scripts[i] = string(filecontent)\n\n\t\tvar thisVM *vm.VM\n\n\t\tif strings.HasSuffix(inputFileName, \".yolol\") {\n\t\t\tthisVM, err = vm.CreateFromSource(h.Scripts[i])\n\t\t\tif err != nil {\n\t\t\t\treturn nil, err\n\t\t\t}\n\t\t} else if strings.HasSuffix(inputFileName, \".nolol\") {\n\t\t\tconverter := nolol.NewConverter().LoadFile(inputFileName).RunConversion()\n\t\t\tyololcode, err := converter.Get()\n\t\t\tif err != nil {\n\t\t\t\treturn nil, err\n\t\t\t}\n\t\t\th.ValidBreakpoints[i] = findValidBreakpoints(yololcode)\n\t\t\th.VariableTranslations[i] = converter.GetVariableTranslations()\n\t\t\tpri := parser.Printer{\n\t\t\t\tMode: parser.PrintermodeReadable,\n\t\t\t}\n\t\t\tyololcodestr, _ := pri.Print(yololcode)\n\t\t\th.CompiledCode[i] = yololcodestr\n\t\t\tthisVM = vm.Create(yololcode)\n\t\t} else {\n\t\t\treturn nil, fmt.Errorf(\"Invalid file extension on: %s\", inputFileName)\n\t\t}\n\n\t\th.Vms[i] = thisVM\n\t\tthisVM.SetCoordinator(h.Coordinator)\n\n\t\tprepareVM(thisVM, inputFileName)\n\t\tthisVM.Resume()\n\t}\n\th.findReferencedVariables()\n\treturn h, nil\n}", "func main() {\n\tswitch len(os.Args) {\n\tcase 2:\n\t\treplacer.Produce(os.Args[1])\n\tcase 3:\n\t\treplacer.Produce(os.Args[2])\n\tdefault:\n\t\tpanic(\"Bad usage. Pass 1 or 2 arguments. The last one should be path to file, estimated arguments will be ignored.\")\n\t}\n}", "func source(lines [][]byte, n int) []byte {\n\tn-- // in stack trace, lines are 1-indexed but our array is 0-indexed\n\tif n < 0 || n >= len(lines) {\n\t\treturn dunno\n\t}\n\treturn bytes.TrimSpace(lines[n])\n}", "func main() {\n\ttemplate := `// Copyright 2016-2022, Pulumi Corporation.\n//\n// Licensed under the Apache License, Version 2.0 (the \"License\");\n// you may not use this file except in compliance with the License.\n// You may obtain a copy of the License at\n//\n// http://www.apache.org/licenses/LICENSE-2.0\n//\n// Unless required by applicable law or agreed to in writing, software\n// distributed under the License is distributed on an \"AS IS\" BASIS,\n// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n// See the License for the specific language governing permissions and\n// limitations under the License.\n\n// Code generated by \"codegen/gen_program_test/generate.go\"; DO NOT EDIT.\n\npackage %s\n\nimport (\n \"os\"\n \"testing\"\n\n codegen \"github.com/pulumi/pulumi/pkg/v3/codegen/%s\"\n \"github.com/pulumi/pulumi/pkg/v3/codegen/testing/test\"\n)\n\nfunc TestGenerateProgram(t *testing.T) {\n os.Chdir(\"../../../%[2]s\") // chdir into codegen/%[2]s\n codegen.GenerateProgramBatchTest(t, test.ProgramTestBatch(%d, %d))\n}`\n\n\tn := 6\n\tfor _, lang := range []string{\"dotnet\", \"go\", \"nodejs\", \"python\"} {\n\t\tos.RemoveAll(filepath.Join(\"../\", lang, \"gen_program_test\"))\n\t\tfor i := 1; i <= n; i++ {\n\t\t\tpackageName := fmt.Sprintf(\"batch%d\", i)\n\t\t\tdir := filepath.Join(\"../\", lang, \"gen_program_test\", packageName)\n\t\t\terr := os.MkdirAll(dir, 0o755)\n\t\t\tif err != nil {\n\t\t\t\tpanic(fmt.Sprintf(\"unexpected error generating codegen tests: %v\", err))\n\t\t\t}\n\t\t\ttestPath := filepath.Join(dir, \"gen_program_test.go\")\n\n\t\t\tsourceCode := fmt.Sprintf(template, packageName, lang, i, n)\n\t\t\terr = os.WriteFile(testPath, []byte(sourceCode), 0o755) //nolint:gosec\n\t\t\tif err != nil {\n\t\t\t\tpanic(fmt.Sprintf(\"unexpected error generating codegen tests: %v\", err))\n\t\t\t}\n\t\t}\n\t}\n}", "func MainStart(matchString func(pat, str string) (bool, error), tests []InternalTest, benchmarks []InternalBenchmark, examples []InternalExample) *M", "func main() {\n\t// define commands for execution\n\tinFile := flag.String(\"source\", \"\", \"source\")\n\toutFile := flag.String(\"target\", \"\", \"target\")\n\tpkg := flag.String(\"package\", \"main\", \"package name\")\n\tname := flag.String(\"name\", \"File\", \"identifier to use for the embedded data\")\n\tflag.Parse()\n\terr := genConf(*inFile, *outFile, *pkg, *name)\n\thandleError(err)\n}", "func generateInstructionList(instrs string) ([]instruction, error) {\n\tresult := make([]instruction, 0)\n\tfor _, line := range aoc.SplitLines(instrs) {\n\t\tinstr, err := readInstruction(line)\n\t\tif err != nil {\n\t\t\treturn nil, errors.Wrapf(err, \"could not generate list of instructions\")\n\t\t}\n\t\tresult = append(result, instr)\n\t}\n\treturn result, nil\n}", "func main() {\n\tf, err := os.Open(\"main.go\")\n\tif err != nil {\n\t\tpanic(err)\n\t}\n\tdefer f.Close()\n\ts, err := ReadAllStringFromReader(f)\n\tif err != nil {\n\t\tpanic(err)\n\t}\n\tfmt.Printf(\"%s\\n\", s)\n\n\ts, err = ReadAllStringFromTestReader(&test.TestReader{})\n\tif err != nil {\n\t\tpanic(err)\n\t}\n\tfmt.Printf(\"%s\\n\", s)\n}", "func createSrcs(modules []string, tag string) []string {\n\treturn transformArray(modules, \":\", tag)\n}", "func (u *userApp) loadRaw(filename string, x []uint8) (string, error) {\n\n\t// copy the code to the load address\n\tvar loadAdr uint16\n\tfor i, v := range x {\n\t\tu.mem.Write8(loadAdr+uint16(i), v)\n\t}\n\tendAdr := loadAdr + uint16(len(x)) - 1\n\n\treturn fmt.Sprintf(\"%s code %04x-%04x\", filename, loadAdr, endAdr), nil\n}", "func buildCmd(args [][]byte) []byte {\n buf := bytes.NewBuffer(nil)\n\n buf.WriteByte(star)\n buf.WriteString(strconv.Itoa(len(args)))\n buf.Write(delim)\n\n for _, arg := range args {\n buf.WriteByte(dollar)\n buf.WriteString(strconv.Itoa(len(arg)))\n buf.Write(delim)\n buf.Write(arg)\n buf.Write(delim)\n }\n\n if debug {\n log.Printf(\"GODIS: %q\", string(buf.Bytes()))\n }\n\n return buf.Bytes()\n}", "func FromStrings(values []string) Source {\n\tvar sink Source\n\tvar isPumping bool\n\tvar done bool\n\n\tpump := func() {\n\t\tfor _, value := range values {\n\t\t\tsink(NewData(value))\n\t\t}\n\t\tdone = true\n\t\tsink(NewTerminate(nil))\n\t}\n\n\treturn func(p Payload) {\n\t\tswitch v := p.(type) {\n\t\tcase Greets:\n\t\t\tsink = v.Source()\n\n\t\t\tsink(NewGreets(func(p Payload) {\n\t\t\t\tswitch p.(type) {\n\t\t\t\tcase Data:\n\t\t\t\t\tif !isPumping && !done {\n\t\t\t\t\t\tisPumping = true\n\t\t\t\t\t\tpump()\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}))\n\n\t\tdefault:\n\t\t\treturn\n\t\t}\n\t}\n}", "func New(b []byte) *LazyExe {\n\tle := &LazyExe{\n\t\tbytes: b,\n\t}\n\treturn le\n}", "func NewScriptFromBytes(scriptBytes []byte) *Script {\n\tscript := Script(scriptBytes)\n\treturn &script\n}", "func main() {\n\tif len(os.Args) != 2 {\n\t\tfmt.Println(\"Usage: flyweight.exe digits\")\n\t\tfmt.Println(\"Ex. : flyweight.exe 1212123\")\n\t} else {\n\t\tbs := NewLargeSizeString(os.Args[1])\n\t\tbs.Display()\n\t}\n}", "func procProgram(t *testing.T, name string, testCommand string) Program {\n\tpath, procPath := procTestPath(name)\n\terr := util.CopyFile(path, procPath, testLog)\n\trequire.NoError(t, err)\n\terr = os.Chmod(procPath, 0777)\n\trequire.NoError(t, err)\n\t// Temp dir might have symlinks in which case we need the eval'ed path\n\tprocPath, err = filepath.EvalSymlinks(procPath)\n\trequire.NoError(t, err)\n\treturn Program{\n\t\tPath: procPath,\n\t\tArgs: []string{testCommand},\n\t}\n}", "func main() {\n\tvar x = \"Hallo, bin Marcell Davis\";\n}", "func TestParseAndString(t *testing.T) {\n\t// This program should have one of every AST element to ensure\n\t// we can parse and String()ify each.\n\tsource := strings.TrimSpace(`\nBEGIN {\n print \"begin one\"\n}\n\nBEGIN {\n print \"begin two\"\n}\n\n{\n print \"empty pattern\"\n}\n\n$0 {\n print \"normal pattern\"\n print 1, 2, 3\n printf \"%.3f\", 3.14159\n print \"x\" >\"file\"\n print \"x\" >>\"append\"\n print \"y\" |\"prog\"\n delete a\n delete a[k]\n if (c) {\n get(a, k)\n }\n if (1 + 2) {\n get(a, k)\n } else {\n set(a, k, v)\n }\n for (i = 0; i < 10; i++) {\n print i\n continue\n }\n for (k in a) {\n break\n }\n while (0) {\n print \"x\"\n }\n do {\n print \"y\"\n exit status\n } while (x)\n next\n nextfile\n \"cmd\" |getline\n \"cmd\" |getline x\n \"cmd\" |getline a[1]\n \"cmd\" |getline $1\n getline\n getline x\n (getline x + 1)\n getline $1\n getline a[1]\n getline <\"file\"\n getline x <\"file\"\n (getline x <\"file\" \"x\")\n getline $1 <\"file\"\n getline a[1] <\"file\"\n x = 0\n y = z = 0\n b += 1\n c -= 2\n d *= 3\n e /= 4\n g ^= 5\n h %= 6\n (x ? \"t\" : \"f\")\n ((b && c) || d)\n (k in a)\n ((x, y, z) in a)\n (s ~ \"foo\")\n (b < 1)\n (c <= 2)\n (d > 3)\n (e >= 4)\n (g == 5)\n (h != 6)\n ((x y) z)\n ((b + c) + d)\n ((b * c) * d)\n ((b - c) - d)\n ((b / c) / d)\n (b ^ (c ^ d))\n x++\n x--\n ++y\n --y\n 1234\n 1.5\n \"This is a string\"\n if (/a.b/) {\n print \"match\"\n }\n $1\n $(1 + 2)\n !x\n +x\n -x\n var\n a[key]\n a[x, y, z]\n f()\n set(a, k, v)\n sub(regex, repl)\n sub(regex, repl, s)\n gsub(regex, repl)\n gsub(regex, repl, s)\n split(s, a)\n split(s, a, regex)\n match(s, regex)\n rand()\n srand()\n srand(1)\n length()\n length($1)\n sprintf(\"\")\n sprintf(\"%.3f\", 3.14159)\n sprintf(\"%.3f %d\", 3.14159, 42)\n cos(1)\n sin(1)\n exp(1)\n log(1)\n sqrt(1)\n int(\"42\")\n tolower(\"FOO\")\n toupper(\"foo\")\n system(\"ls\")\n close(\"file\")\n atan2(x, y)\n index(haystack, needle)\n {\n print \"block statement\"\n f()\n }\n}\n\n(NR == 1), (NR == 2) {\n print \"range pattern\"\n}\n\n($1 == \"foo\")\n\nEND {\n print \"end one\"\n}\n\nEND {\n print \"end two\"\n}\n\nfunction f() {\n}\n\nfunction get(a, k) {\n return a[k]\n}\n\nfunction set(a, k, v) {\n a[k] = v\n return\n}\n`)\n\tprog, err := parser.ParseProgram([]byte(source), nil)\n\tif err != nil {\n\t\tt.Fatalf(\"error parsing program: %v\", err)\n\t}\n\tprogStr := prog.String()\n\tif progStr != source {\n\t\tt.Fatalf(\"expected first, got second:\\n%s\\n----------\\n%s\", source, progStr)\n\t}\n}", "func NewBootCode(instructions []Instruction) BootCode {\n\treturn BootCode{\n\t\tinstructions: instructions,\n\t\tposExecuted: map[int]bool{},\n\t\tpos: 0,\n\t\tacc: 0,\n\t}\n}", "func newProgram(e *Env, ast *Ast, opts []ProgramOption) (Program, error) {\n\t// Build the dispatcher, interpreter, and default program value.\n\tdisp := interpreter.NewDispatcher()\n\n\t// Ensure the default attribute factory is set after the adapter and provider are\n\t// configured.\n\tp := &prog{\n\t\tEnv: e,\n\t\tdecorators: []interpreter.InterpretableDecorator{},\n\t\tdispatcher: disp,\n\t}\n\n\t// Configure the program via the ProgramOption values.\n\tvar err error\n\tfor _, opt := range opts {\n\t\tp, err = opt(p)\n\t\tif err != nil {\n\t\t\treturn nil, err\n\t\t}\n\t}\n\n\t// Add the function bindings created via Function() options.\n\tfor _, fn := range e.functions {\n\t\tbindings, err := fn.bindings()\n\t\tif err != nil {\n\t\t\treturn nil, err\n\t\t}\n\t\terr = disp.Add(bindings...)\n\t\tif err != nil {\n\t\t\treturn nil, err\n\t\t}\n\t}\n\n\t// Set the attribute factory after the options have been set.\n\tvar attrFactory interpreter.AttributeFactory\n\tif p.evalOpts&OptPartialEval == OptPartialEval {\n\t\tattrFactory = interpreter.NewPartialAttributeFactory(e.Container, e.adapter, e.provider)\n\t} else {\n\t\tattrFactory = interpreter.NewAttributeFactory(e.Container, e.adapter, e.provider)\n\t}\n\tinterp := interpreter.NewInterpreter(disp, e.Container, e.provider, e.adapter, attrFactory)\n\tp.interpreter = interp\n\n\t// Translate the EvalOption flags into InterpretableDecorator instances.\n\tdecorators := make([]interpreter.InterpretableDecorator, len(p.decorators))\n\tcopy(decorators, p.decorators)\n\n\t// Enable interrupt checking if there's a non-zero check frequency\n\tif p.interruptCheckFrequency > 0 {\n\t\tdecorators = append(decorators, interpreter.InterruptableEval())\n\t}\n\t// Enable constant folding first.\n\tif p.evalOpts&OptOptimize == OptOptimize {\n\t\tdecorators = append(decorators, interpreter.Optimize())\n\t\tp.regexOptimizations = append(p.regexOptimizations, interpreter.MatchesRegexOptimization)\n\t}\n\t// Enable regex compilation of constants immediately after folding constants.\n\tif len(p.regexOptimizations) > 0 {\n\t\tdecorators = append(decorators, interpreter.CompileRegexConstants(p.regexOptimizations...))\n\t}\n\t// Enable compile-time checking of syntax/cardinality for string.format calls.\n\tif p.evalOpts&OptCheckStringFormat == OptCheckStringFormat {\n\t\tvar isValidType func(id int64, validTypes ...*types.TypeValue) (bool, error)\n\t\tif ast.IsChecked() {\n\t\t\tisValidType = func(id int64, validTypes ...*types.TypeValue) (bool, error) {\n\t\t\t\tt, err := ExprTypeToType(ast.typeMap[id])\n\t\t\t\tif err != nil {\n\t\t\t\t\treturn false, err\n\t\t\t\t}\n\t\t\t\tif t.kind == DynKind {\n\t\t\t\t\treturn true, nil\n\t\t\t\t}\n\t\t\t\tfor _, vt := range validTypes {\n\t\t\t\t\tk, err := typeValueToKind(vt)\n\t\t\t\t\tif err != nil {\n\t\t\t\t\t\treturn false, err\n\t\t\t\t\t}\n\t\t\t\t\tif k == t.kind {\n\t\t\t\t\t\treturn true, nil\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\treturn false, nil\n\t\t\t}\n\t\t} else {\n\t\t\t// if the AST isn't type-checked, short-circuit validation\n\t\t\tisValidType = func(id int64, validTypes ...*types.TypeValue) (bool, error) {\n\t\t\t\treturn true, nil\n\t\t\t}\n\t\t}\n\t\tdecorators = append(decorators, interpreter.InterpolateFormattedString(isValidType))\n\t}\n\n\t// Enable exhaustive eval, state tracking and cost tracking last since they require a factory.\n\tif p.evalOpts&(OptExhaustiveEval|OptTrackState|OptTrackCost) != 0 {\n\t\tfactory := func(state interpreter.EvalState, costTracker *interpreter.CostTracker) (Program, error) {\n\t\t\tcostTracker.Estimator = p.callCostEstimator\n\t\t\tcostTracker.Limit = p.costLimit\n\t\t\t// Limit capacity to guarantee a reallocation when calling 'append(decs, ...)' below. This\n\t\t\t// prevents the underlying memory from being shared between factory function calls causing\n\t\t\t// undesired mutations.\n\t\t\tdecs := decorators[:len(decorators):len(decorators)]\n\t\t\tvar observers []interpreter.EvalObserver\n\n\t\t\tif p.evalOpts&(OptExhaustiveEval|OptTrackState) != 0 {\n\t\t\t\t// EvalStateObserver is required for OptExhaustiveEval.\n\t\t\t\tobservers = append(observers, interpreter.EvalStateObserver(state))\n\t\t\t}\n\t\t\tif p.evalOpts&OptTrackCost == OptTrackCost {\n\t\t\t\tobservers = append(observers, interpreter.CostObserver(costTracker))\n\t\t\t}\n\n\t\t\t// Enable exhaustive eval over a basic observer since it offers a superset of features.\n\t\t\tif p.evalOpts&OptExhaustiveEval == OptExhaustiveEval {\n\t\t\t\tdecs = append(decs, interpreter.ExhaustiveEval(), interpreter.Observe(observers...))\n\t\t\t} else if len(observers) > 0 {\n\t\t\t\tdecs = append(decs, interpreter.Observe(observers...))\n\t\t\t}\n\n\t\t\treturn p.clone().initInterpretable(ast, decs)\n\t\t}\n\t\treturn newProgGen(factory)\n\t}\n\treturn p.initInterpretable(ast, decorators)\n}", "func execNewSlice(_ int, p *gop.Context) {\n\targs := p.GetArgs(1)\n\tret := types.NewSlice(args[0].(types.Type))\n\tp.Ret(1, ret)\n}", "func execNew(_ int, p *gop.Context) {\n\targs := p.GetArgs(3)\n\tret := doc.New(args[0].(*ast.Package), args[1].(string), doc.Mode(args[2].(int)))\n\tp.Ret(3, ret)\n}", "func compileAndRun(code []byte) (string, error) {\n\tconst name = \"tmp\"\n\tos.RemoveAll(name)\n\terr := os.Mkdir(name, 0700)\n\tif err != nil {\n\t\treturn \"\", err\n\t}\n\n\t// write src\n\terr = ioutil.WriteFile(name+\"/main.go\", code, 0700)\n\tif err != nil {\n\t\treturn \"\", err\n\t}\n\n\t// compile\n\tcmd := exec.Command(\"sh\", \"-c\", \"go build\")\n\tcmd.Dir = name\n\tout, err := cmd.CombinedOutput()\n\tif err != nil {\n\t\treturn \"\", fmt.Errorf(\"%v: %s\", err, out)\n\t}\n\n\t// execute\n\tcmd = exec.Command(\"sh\", \"-c\", \"./\"+name)\n\tcmd.Dir = name\n\tout, err = cmd.CombinedOutput()\n\tif err != nil {\n\t\treturn \"\", fmt.Errorf(\"%v: %s\", err, out)\n\t}\n\n\tos.RemoveAll(name)\n\treturn string(out), nil\n}", "func Main() {\n\t// var s string\n\t// s = \"hello\"\n\t// s = \"\\xE4\"\n\t// s = \"中华\"\n\t// s[1] = \"3\" // string 是不可变的byte数组\n\t// fmt.Println(s)\n\t// fmt.Println(len(s))\n\n\t// c := []rune(s)\n\t// fmt.Println(len(c))\n\t// fmt.Printf(\"中 unicode %x\", c[0])\n\t// fmt.Printf(\"中 UTF8 %x\", s)\n\n\t// for _, v := range s {\n\t// \t// fmt.Println(v)\n\t// \tfmt.Printf(\"%[1]c %[1]d\", v)\n\t// }\n\t// s := \"a,b,c\"\n\t// parts := strings.Split(s, \",\")\n\t// for _, v := range parts {\n\t// \tfmt.Println(v)\n\t// }\n\t// fmt.Println(strings.Join(parts, \"-\"))\n\n\t// n := strconv.Itoa(10)\n\t// fmt.Println(\"s\" + n)\n\n\t// fmt.Println(strconv.Atoi(\"10\"))\n\n\t// if i, err := strconv.Atoi(\"10\"); err == nil {\n\t// \tfmt.Println(10 + i)\n\t// }\n}", "func NewProgram() *Program {\n\treturn &Program{\n\t\tframe: EmptyFrame(),\n\t}\n}", "func (s *BaseSyslParserListener) EnterArray_of_strings(ctx *Array_of_stringsContext) {}", "func main() {\n\tapp := &cli.App{\n\t\tName: \"grrs\",\n\t\tUsage: \"like a grep, but written in go\",\n\t\tAction: func(c *cli.Context) error {\n\t\t\targs, err := cl.InitArgs(c.Args())\n\t\t\tcheck(err)\n\t\t\tlines, err := matches.InFile(args)\n\t\t\tcheck(err)\n\t\t\tfor _, line := range lines {\n\t\t\t\tfmt.Println(line)\n\t\t\t}\n\t\t\treturn nil\n\t\t},\n\t}\n\n\terr := app.Run(os.Args)\n\tcheck(errors.Wrap(err, strings.Join(os.Args, \", \")))\n}", "func newScript(scriptPath string, source []byte) (*Script, error) {\n script := &Script{\n Name: path.Base(scriptPath),\n Path: scriptPath,\n ParamDefs: make([]ScriptDef, 0),\n OutputDefs: make([]ScriptDef, 0),\n }\n\n // Define regexes\n descRe := regexp.MustCompile(`(?m)^#\\s+@desc\\s*(.*)$`)\n paramRe := regexp.MustCompile(fmt.Sprintf(\n `(?m)^#\\s+@param\\s+([^\\s]+)\\s+(int|float|string|bool|unsafe)\\s+%s([^%s]*)%s\\s+(.*)$`, \"`\", \"`\", \"`\"))\n outputRe := regexp.MustCompile(`(?m)^#\\s+@output\\s+([^\\s]+)\\s+(a|w)$`)\n\n // Read source line by line\n reader := bufio.NewReader(bytes.NewBuffer(source))\n var templateBuf bytes.Buffer\n var helpBuf bytes.Buffer\n afterLeadingComments := false\n for {\n line, readErr := reader.ReadString('\\n')\n if readErr == io.EOF {\n // End of source\n break\n } else if !afterLeadingComments && !strings.HasPrefix(line, \"#\") {\n // End of leading comments\n // Insert _clear, _timeout, and output var fds\n if _, writeErr := templateBuf.WriteString(\"_clear=3\\n_timeout=4\\n\"); writeErr != nil {\n return nil, writeErr\n }\n for outputDefIdx, outputDef := range script.OutputDefs {\n if _, writeErr := templateBuf.WriteString(fmt.Sprintf(\"%s=%d\\n\", outputDef.Name, 5+outputDefIdx)); writeErr != nil {\n return nil, writeErr\n }\n }\n afterLeadingComments = true\n } else if readErr != nil {\n // Some other error reading source\n errLog.Printf(\"reader.ReadString err=%v\\n\", readErr)\n return nil, readErr\n }\n if _, writeErr := templateBuf.WriteString(line); writeErr != nil {\n return nil, writeErr\n }\n matchedEntry := true\n if afterLeadingComments {\n // After leading comments, so do nothing\n continue\n } else if matches := descRe.FindStringSubmatch(line); len(matches) > 0 {\n // Matched a @desc entry\n script.Desc += strings.TrimSpace(matches[1])\n } else if matches := paramRe.FindStringSubmatch(line); len(matches) > 0 {\n // Matched a @param entry\n paramDef := &ScriptDef{\n Name: matches[1],\n Type: matches[2],\n DefaultStr: matches[3],\n Desc: matches[4],\n }\n if valErr := paramDef.makeDefault(); valErr != nil {\n errLog.Printf(\"paramDef.makeDefault err=%v\\n\", valErr)\n return nil, valErr\n }\n script.ParamDefs = append(script.ParamDefs, *paramDef)\n } else if matches := outputRe.FindStringSubmatch(line); len(matches) > 0 {\n // Mached an @output entry\n script.OutputDefs = append(script.OutputDefs, ScriptDef{\n Name: matches[1],\n Type: matches[2],\n })\n } else {\n matchedEntry = false\n }\n if matchedEntry {\n helpBuf.WriteString(line)\n }\n }\n\n // Make help\n script.Help = helpBuf.String()\n\n // Compile template\n if tpl, tplErr := template.New(script.Name).Parse(templateBuf.String()); tplErr != nil {\n return nil, tplErr\n } else {\n script.Template = tpl\n }\n\n // Done!\n script.ParsedTs = time.Now().Unix()\n return script, nil\n}", "func main() {\n\tmyMessage := `Hello! I'm a raw-string!\n I can do this, and it's pretty\n cool!`\n\n\tfmt.Println(myMessage)\n}", "func Compile(input []byte) Program {\n\ttokens := Tokenize(input)\n\t//remove whitespace tokens - they're unnecessary past this point\n\tvar newTokens []Token\n\tfor _, token := range tokens {\n\t\tif token.tokType != Whitespace {\n\t\t\tnewTokens = append(newTokens, token)\n\t\t}\n\t}\n\ttokens = newTokens\n\n\t//TokenDebugPrint(tokens)\n\n\t//Split the stream of tokens into statements\n\tvar curStatement Statement\n\tvar statements []Statement\n\tfor _, token := range tokens {\n\t\tif token.tokType == Punctuation && token.value == \".\" {\n\t\t\tstatements = append(statements, curStatement)\n\t\t\tcurStatement = Statement{}\n\t\t} else {\n\t\t\t//no need to carry the period past here\n\t\t\tcurStatement = append(curStatement, token)\n\t\t}\n\t}\n\treturn statements\n}", "func main() {\n\t// os.Args provides access to raw command-line arguments. Note that the first value in this\n\t// slice is the path to the program, and os.Args[1:] holds the arguments to the program.\n\targsWithProg := os.Args\n\targsWithoutProg := os.Args[1:]\n\n\t// You can get individual args with normal indexing.\n\targ := os.Args[3]\n\n\tfmt.Println(argsWithProg)\n\tfmt.Println(argsWithoutProg)\n\tfmt.Println(arg)\n}", "func runProgram(program []int) (result []int, err error) {\n\tif len(program) <= 0 {\n\t\treturn nil, errors.New(\"program is empty\")\n\t}\n\n\tresult = program\n\tinstructionPointer := 0\n\n\tfor instructionPointer < len(result) {\n\t\topcode, err := parseOpcode(result[instructionPointer])\n\t\tif err != nil {\n\t\t\treturn result, err\n\t\t}\n\n\t\tif opcode.value == 99 {\n\t\t\treturn result, nil\n\t\t} else {\n\t\t\t// We have read the opcode. Advance the instruction pointer by one.\n\t\t\tinstructionPointer += 1\n\n\t\t\tif opcode.value == 1 {\n\t\t\t\targs, err := readArguments(program, instructionPointer, opcode)\n\t\t\t\tif err != nil {\n\t\t\t\t\treturn nil, err\n\t\t\t\t}\n\n\t\t\t\tresult[args.argument3] = args.argument1 + args.argument2\n\t\t\t\tinstructionPointer += 3\n\t\t\t} else if opcode.value == 2 {\n\t\t\t\targs, err := readArguments(program, instructionPointer, opcode)\n\t\t\t\tif err != nil {\n\t\t\t\t\treturn nil, err\n\t\t\t\t}\n\n\t\t\t\tresult[args.argument3] = args.argument1 * args.argument2\n\t\t\t\tinstructionPointer += 3\n\t\t\t} else if opcode.value == 3 {\n\t\t\t\targs, err := readArguments(program, instructionPointer, opcode)\n\t\t\t\tif err != nil {\n\t\t\t\t\treturn nil, err\n\t\t\t\t}\n\n\t\t\t\tvar input int\n\t\t\t\tprint(\"ID? \")\n\t\t\t\tif _, err := fmt.Scan(&input); err != nil {\n\t\t\t\t\tlog.Fatal(\"Please input a valid integer \", err)\n\t\t\t\t}\n\n\t\t\t\tprogram[args.argument1] = input\n\t\t\t\tinstructionPointer += 1\n\t\t\t} else if opcode.value == 4 {\n\t\t\t\targs, err := readArguments(program, instructionPointer, opcode)\n\t\t\t\tif err != nil {\n\t\t\t\t\treturn nil, err\n\t\t\t\t}\n\n\t\t\t\tprintln(args.argument1)\n\t\t\t\tinstructionPointer += 1\n\t\t\t} else if opcode.value == 5 {\n\t\t\t\targs, err := readArguments(program, instructionPointer, opcode)\n\t\t\t\tif err != nil {\n\t\t\t\t\treturn nil, err\n\t\t\t\t}\n\n\t\t\t\tif args.argument1 != 0 {\n\t\t\t\t\tinstructionPointer = args.argument2\n\t\t\t\t} else {\n\t\t\t\t\tinstructionPointer += 2\n\t\t\t\t}\n\t\t\t} else if opcode.value == 6 {\n\t\t\t\targs, err := readArguments(program, instructionPointer, opcode)\n\t\t\t\tif err != nil {\n\t\t\t\t\treturn nil, err\n\t\t\t\t}\n\n\t\t\t\tif args.argument1 == 0 {\n\t\t\t\t\tinstructionPointer = args.argument2\n\t\t\t\t} else {\n\t\t\t\t\tinstructionPointer += 2\n\t\t\t\t}\n\t\t\t} else if opcode.value == 7 {\n\t\t\t\targs, err := readArguments(program, instructionPointer, opcode)\n\t\t\t\tif err != nil {\n\t\t\t\t\treturn nil, err\n\t\t\t\t}\n\n\t\t\t\tif args.argument1 < args.argument2 {\n\t\t\t\t\tprogram[args.argument3] = 1\n\t\t\t\t} else {\n\t\t\t\t\tprogram[args.argument3] = 0\n\t\t\t\t}\n\n\t\t\t\tinstructionPointer += 3\n\t\t\t} else if opcode.value == 8 {\n\t\t\t\targs, err := readArguments(program, instructionPointer, opcode)\n\t\t\t\tif err != nil {\n\t\t\t\t\treturn nil, err\n\t\t\t\t}\n\n\t\t\t\tif args.argument1 == args.argument2 {\n\t\t\t\t\tprogram[args.argument3] = 1\n\t\t\t\t} else {\n\t\t\t\t\tprogram[args.argument3] = 0\n\t\t\t\t}\n\n\t\t\t\tinstructionPointer += 3\n\t\t\t} else {\n\t\t\t\treturn nil, errors.New(fmt.Sprintf(\"unknown opcode detected: %d\", opcode))\n\t\t\t}\n\t\t}\n\t}\n\n\treturn nil, errors.New(\"no terminating opcode (99) found in program\")\n}", "func NewFromString(exp string) *Pipeline {\n\tcmds := ParseCommand(exp)\n\treturn NewPipeline(cmds...)\n}", "func NewCode(codeRep CodeStr) Code {\n\tcode := Code{codeStr: codeRep}\n\tif err := code.checkCodePath(); err != nil {\n\t\tpanic(err)\n\t}\n\treturn code\n}", "func TestEmptyPosition(t *testing.T) {\n\tvar predeclared starlark.StringDict\n\tfor _, content := range []string{\"\", \"empty = False\"} {\n\t\t_, prog, err := starlark.SourceProgram(\"hello.star\", content, predeclared.Has)\n\t\tif err != nil {\n\t\t\tt.Fatal(err)\n\t\t}\n\t\tif got, want := prog.Filename(), \"hello.star\"; got != want {\n\t\t\tt.Errorf(\"Program.Filename() = %q, want %q\", got, want)\n\t\t}\n\t}\n}", "func NewIntCode(prog []int, in io.Reader, out io.Writer) *IntCode {\n\t// please don't mutate my input\n\tb := make([]int, len(prog))\n\tcopy(b, prog)\n\t// ok thanks\n\tres := IntCode{\n\t\tprog: b,\n\t\tpos: 0,\n\t\tin: os.Stdin,\n\t\tout: os.Stdout,\n\t}\n\treturn &res\n}", "func main() {\n\tvar dir string\n\tvar b *bytes.Buffer\n\n\tdir, err := os.Getwd()\n\tif err != nil {\n\t\tpanic(err)\n\t}\n\tb = &bytes.Buffer{}\n\tCodegen(dir, b, \"./local/generated.go\")\n}", "func Asm(asm string)", "func Run(input, executableName string) {\n\tcode := generator.Generate(input)\n\twriteCode(code)\n\n\t// Generate the executable using gcc\n\tcmd := exec.Command(\"gcc\", \"main.c\", \"-L.\", \"-lpaco\", \"-o\", executableName)\n\tcmd.Dir = \"core\"\n\tif err := cmd.Run(); err != nil {\n\t\tlog.Fatalf(\"Run() failed with %s\\n\", err)\n\t}\n\n\t// Moves the executable and deletes the source file\n\tmovesExecutable(executableName)\n\tdeleteFile(\"main.c\")\n}", "func newParser(pcidbs []string) *parser {\n\n\tfor _, db := range pcidbs {\n\t\tfile, err := os.ReadFile(db)\n\t\tif err != nil {\n\t\t\tcontinue\n\t\t}\n\t\treturn newParserFromReader(bufio.NewReader(bytes.NewReader(file)))\n\n\t}\n\t// We're using go embed above to have the byte array\n\t// correctly initialized with the internal shipped db\n\t// if we cannot find an up to date in the filesystem\n\treturn newParserFromReader(bufio.NewReader(bytes.NewReader(defaultPCIdb)))\n}", "func toSSA(source io.Reader, fileName, packageName string, debug bool) ([]byte, error) {\n\t// adopted from saa package example\n\n\tconf := loader.Config{\n\t\tBuild: &build.Default,\n\t}\n\n\tfile, err := conf.ParseFile(fileName, source)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\n\tconf.CreateFromFiles(\"main.go\", file)\n\n\tprog, err := conf.Load()\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\n\tssaProg := ssautil.CreateProgram(prog, ssa.NaiveForm|ssa.BuildSerially)\n\tssaProg.Build()\n\tmainPkg := ssaProg.Package(prog.InitialPackages()[0].Pkg)\n\n\tout := new(bytes.Buffer)\n\tmainPkg.SetDebugMode(debug)\n\tmainPkg.WriteTo(out)\n\tmainPkg.Build()\n\n\t// grab just the functions\n\tfuncs := members([]ssa.Member{})\n\tfor _, obj := range mainPkg.Members {\n\t\tif obj.Token() == token.FUNC {\n\t\t\tfuncs = append(funcs, obj)\n\t\t}\n\t}\n\t// sort by Pos()\n\tsort.Sort(funcs)\n\tfor _, f := range funcs {\n\t\tmainPkg.Func(f.Name()).WriteTo(out)\n\t}\n\treturn out.Bytes(), nil\n}", "func ExpandArrayIntoScript(script *io.BinWriter, slice []Param) error {\n\tfor j := len(slice) - 1; j >= 0; j-- {\n\t\tfp, err := slice[j].GetFuncParam()\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tswitch fp.Type {\n\t\tcase smartcontract.ByteArrayType:\n\t\t\tstr, err := fp.Value.GetBytesBase64()\n\t\t\tif err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\t\t\temit.Bytes(script, str)\n\t\tcase smartcontract.SignatureType:\n\t\t\tstr, err := fp.Value.GetBytesHex()\n\t\t\tif err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\t\t\temit.Bytes(script, str)\n\t\tcase smartcontract.StringType:\n\t\t\tstr, err := fp.Value.GetString()\n\t\t\tif err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\t\t\temit.String(script, str)\n\t\tcase smartcontract.Hash160Type:\n\t\t\thash, err := fp.Value.GetUint160FromHex()\n\t\t\tif err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\t\t\temit.Bytes(script, hash.BytesBE())\n\t\tcase smartcontract.Hash256Type:\n\t\t\thash, err := fp.Value.GetUint256()\n\t\t\tif err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\t\t\temit.Bytes(script, hash.BytesBE())\n\t\tcase smartcontract.PublicKeyType:\n\t\t\tstr, err := fp.Value.GetString()\n\t\t\tif err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\t\t\tkey, err := keys.NewPublicKeyFromString(string(str))\n\t\t\tif err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\t\t\temit.Bytes(script, key.Bytes())\n\t\tcase smartcontract.IntegerType:\n\t\t\tval, err := fp.Value.GetInt()\n\t\t\tif err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\t\t\temit.Int(script, int64(val))\n\t\tcase smartcontract.BoolType:\n\t\t\tval, err := fp.Value.GetBoolean() // not GetBooleanStrict(), because that's the way C# code works\n\t\t\tif err != nil {\n\t\t\t\treturn errors.New(\"not a bool\")\n\t\t\t}\n\t\t\tif val {\n\t\t\t\temit.Int(script, 1)\n\t\t\t} else {\n\t\t\t\temit.Int(script, 0)\n\t\t\t}\n\t\tcase smartcontract.ArrayType:\n\t\t\tval, err := fp.Value.GetArray()\n\t\t\tif err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\t\t\terr = ExpandArrayIntoScript(script, val)\n\t\t\tif err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\t\t\temit.Int(script, int64(len(val)))\n\t\t\temit.Opcodes(script, opcode.PACK)\n\t\tcase smartcontract.AnyType:\n\t\t\tif fp.Value.IsNull() {\n\t\t\t\temit.Opcodes(script, opcode.PUSHNULL)\n\t\t\t}\n\t\tdefault:\n\t\t\treturn fmt.Errorf(\"parameter type %v is not supported\", fp.Type)\n\t\t}\n\t}\n\treturn nil\n}", "func newProgram(filter []bpf.Instruction, action xdpAction, perfMap *ebpf.Map) (*program, error) {\n\tmetricsMap, err := ebpf.NewMap(&metricsSpec)\n\tif err != nil {\n\t\treturn nil, errors.Wrap(err, \"creating metrics map\")\n\t}\n\n\tif perfMap.Type() != ebpf.PerfEventArray {\n\t\treturn nil, errors.Errorf(\"invalid perf map ABI, expected type %s, have %s\", ebpf.PerfEventArray, perfMap.Type())\n\t}\n\n\t// Labels of blocks\n\tconst result = \"result\"\n\tconst exit = \"exit\"\n\n\tebpfFilter, err := cbpfc.ToEBPF(filter, cbpfc.EBPFOpts{\n\t\tPacketStart: asm.R0,\n\t\tPacketEnd: asm.R1,\n\n\t\tResult: asm.R2,\n\t\tResultLabel: result,\n\n\t\tWorking: [4]asm.Register{asm.R2, asm.R3, asm.R4, asm.R5},\n\n\t\tStackOffset: 0,\n\t\tLabelPrefix: \"filter\",\n\t})\n\tif err != nil {\n\t\treturn nil, errors.Wrap(err, \"converting cBPF to eBPF\")\n\t}\n\n\tinsns := asm.Instructions{\n\t\t// Save ctx\n\t\tasm.Mov.Reg(asm.R6, asm.R1),\n\n\t\t// Get the metrics struct\n\t\t// map fd\n\t\tasm.LoadMapPtr(asm.R1, metricsMap.FD()),\n\t\t// index\n\t\tasm.Mov.Reg(asm.R2, asm.R10),\n\t\tasm.Add.Imm(asm.R2, -4),\n\t\tasm.StoreImm(asm.R2, 0, 0, asm.Word),\n\t\t// call\n\t\tasm.FnMapLookupElem.Call(),\n\n\t\t// Check metrics aren't nil\n\t\tasm.JEq.Imm(asm.R0, 0, exit),\n\n\t\t// Save metrics\n\t\tasm.Mov.Reg(asm.R7, asm.R0),\n\n\t\t// Packet start\n\t\tasm.LoadMem(asm.R0, asm.R6, 0, asm.Word),\n\n\t\t// Packet end\n\t\tasm.LoadMem(asm.R1, asm.R6, 4, asm.Word),\n\n\t\t// Packet length\n\t\tasm.Mov.Reg(asm.R8, asm.R1),\n\t\tasm.Sub.Reg(asm.R8, asm.R0),\n\n\t\t// Received packets\n\t\tasm.LoadMem(asm.R2, asm.R7, int16(8*receivedPackets), asm.DWord),\n\t\tasm.Add.Imm(asm.R2, 1),\n\t\tasm.StoreMem(asm.R7, int16(8*receivedPackets), asm.R2, asm.DWord),\n\n\t\t// Fall through to filter\n\t}\n\n\tinsns = append(insns, ebpfFilter...)\n\n\tinsns = append(insns,\n\t\t// Packet didn't match filter\n\t\tasm.JEq.Imm(asm.R2, 0, exit).Sym(result),\n\n\t\t// Matched packets\n\t\tasm.LoadMem(asm.R0, asm.R7, int16(8*matchedPackets), asm.DWord),\n\t\tasm.Add.Imm(asm.R0, 1),\n\t\tasm.StoreMem(asm.R7, int16(8*matchedPackets), asm.R0, asm.DWord),\n\n\t\t// Perf output\n\t\t// ctx\n\t\tasm.Mov.Reg(asm.R1, asm.R6),\n\t\t// perf map\n\t\tasm.LoadMapPtr(asm.R2, perfMap.FD()),\n\t\t// flags (len << 32 | BPF_F_CURRENT_CPU)\n\t\tasm.Mov.Reg(asm.R3, asm.R8),\n\t\tasm.LSh.Imm(asm.R3, 32),\n\t\tasm.LoadImm(asm.R0, BPF_F_CURRENT_CPU, asm.DWord),\n\t\tasm.Or.Reg(asm.R3, asm.R0),\n\t\t// perf output data\n\t\tasm.Mov.Reg(asm.R4, asm.R10),\n\t\t// <u64 packet length>\n\t\tasm.Add.Imm(asm.R4, -8),\n\t\tasm.StoreMem(asm.R4, 0, asm.R8, asm.DWord),\n\t\t// <u64 action>\n\t\tasm.Add.Imm(asm.R4, -8),\n\t\tasm.StoreImm(asm.R4, 0, int64(action), asm.DWord),\n\t\t// sizeof(data)\n\t\tasm.Mov.Imm(asm.R5, 2*8),\n\t\t// call\n\t\tasm.FnPerfEventOutput.Call(),\n\n\t\t// Perf success\n\t\tasm.JEq.Imm(asm.R0, 0, exit),\n\n\t\t// Perf output errors\n\t\tasm.LoadMem(asm.R0, asm.R7, int16(8*perfOutputErrors), asm.DWord),\n\t\tasm.Add.Imm(asm.R0, 1),\n\t\tasm.StoreMem(asm.R7, int16(8*perfOutputErrors), asm.R0, asm.DWord),\n\n\t\t// Fall through to exit\n\t)\n\n\t// Exit with original action - always referred to\n\tinsns = append(insns,\n\t\tasm.Mov.Imm(asm.R0, int32(action)).Sym(exit),\n\t\tasm.Return(),\n\t)\n\n\tprog, err := ebpf.NewProgram(\n\t\t&ebpf.ProgramSpec{\n\t\t\tName: \"xdpcap_filter\",\n\t\t\tType: ebpf.XDP,\n\t\t\tInstructions: insns,\n\t\t\tLicense: \"GPL\",\n\t\t},\n\t)\n\tif err != nil {\n\t\treturn nil, errors.Wrap(err, \"loading filter\")\n\t}\n\n\treturn &program{\n\t\tprogram: prog,\n\t\tmetricsMap: metricsMap,\n\t}, nil\n}", "func Assemble(sigil string, input io.Reader) ([]byte, error) {\n\tinBuf := bufio.NewScanner(input)\n\tresult := bytes.NewBuffer(nil)\n\toutput := bufio.NewWriter(result)\n\n\tvar line, sigilb []byte\n\tif sigil == \"\" {\n\t\tsigilb = []byte(\"// @\")\n\t} else {\n\t\tsigilb = []byte(sigil)\n\t}\n\tfor ln := 1; inBuf.Scan(); ln++ {\n\t\tline = inBuf.Bytes()\n\t\tstart := bytes.Index(line, sigilb)\n\t\tif start == -1 {\n\t\t\tfmt.Fprintf(output, \"%s\\n\", line)\n\t\t\tcontinue\n\t\t}\n\t\tinstr := bytes.SplitN(line[start+len(sigil):], []byte(\"//\"), 2)[0]\n\t\tinstr = bytes.TrimSpace(bytes.SplitN(instr, []byte(\"/*\"), 2)[0])\n\t\tif idx := bytes.Index(line[:start], []byte(`\\`)); idx != -1 {\n\t\t\tstart = idx // Adjust for in-macro lines\n\t\t}\n\t\tif idx := bytes.Index(line[:start], []byte(\"#define\")); idx != -1 {\n\t\t\tspl := bytes.Fields(line[idx:start])\n\t\t\tfmt.Fprintf(output, \"%s %s\", spl[0], spl[1])\n\t\t}\n\t\tbyteCode, err := yasm(convertInstr(instr))\n\t\tif err != nil {\n\t\t\treturn nil, errors.Wrapf(err, \"Line %d\", ln)\n\t\t}\n\n\t\ttoPlan9s(byteCode, output)\n\t\tfmt.Fprintf(output, \"%s\\n\", line[start:])\n\t}\n\n\tif err := output.Flush(); err != nil {\n\t\treturn nil, errors.Wrapf(err, \"Bufio error\")\n\t}\n\treturn result.Bytes(), nil\n}", "func main() {\n\tfmt.Println(getCommandsFromFile(\"resources/not_enough_lines\"))\n\tfmt.Println(getCommandsFromFile(\"resources/version_not_a_number\"))\n\tfmt.Println(getCommandsFromFile(\"resources/invalid_json\"))\n\tfmt.Println(getCommandsFromFile(\"resources/incorrect_version\"))\n\tfmt.Println(getCommandsFromFile(\"resources/incorrect_mode\"))\n\tfmt.Println(getCommandsFromFile(\"resources/valid\"))\n}", "func Run(program []byte, input io.ByteReader, output io.ByteWriter) error {\n\tvar i int // instruction pointer\n\tvar marks []int // loop start markers\n\n\tvar d int // data pointer\n\tvar data [memorySize]byte\n\n\tfor i = 0; i < len(program); i++ {\n\t\tvar err error\n\t\tswitch program[i] {\n\t\tcase '>':\n\t\t\td++\n\t\tcase '<':\n\t\t\td--\n\t\tcase '+':\n\t\t\tdata[d]++\n\t\tcase '-':\n\t\t\tdata[d]--\n\t\tcase '.':\n\t\t\terr = output.WriteByte(data[d])\n\t\tcase ',':\n\t\t\tvar b byte\n\t\t\tb, err = input.ReadByte()\n\t\t\tif err == io.EOF {\n\t\t\t\treturn nil\n\t\t\t}\n\t\t\tdata[d] = b\n\t\tcase '[':\n\t\t\tif data[d] == 0 {\n\t\t\t\t// Jump forward to end of loop:\n\t\t\t\tdepth := 1\n\t\t\t\tfor depth > 0 {\n\t\t\t\t\ti++\n\t\t\t\t\tswitch program[i] {\n\t\t\t\t\tcase '[':\n\t\t\t\t\t\t// Nested loop, so skip the next closing bracket:\n\t\t\t\t\t\tdepth++\n\t\t\t\t\tcase ']':\n\t\t\t\t\t\tdepth--\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\t// Remember this so we can jump back:\n\t\t\t\tmarks = append(marks, i)\n\t\t\t}\n\t\tcase ']':\n\t\t\tif data[d] != 0 {\n\t\t\t\t// Jump back to beginning of loop:\n\t\t\t\ti = marks[len(marks)-1]\n\t\t\t} else {\n\t\t\t\t// We're done with this loop, so forget the matching mark:\n\t\t\t\tmarks = marks[:len(marks)-1]\n\t\t\t}\n\t\t}\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t}\n\treturn nil\n}", "func (s *BaseAspidaListener) EnterStr_array(ctx *Str_arrayContext) {}", "func execNew(_ int, p *gop.Context) {\n\targs := p.GetArgs(1)\n\tret := errors.New(args[0].(string))\n\tp.Ret(1, ret)\n}", "func NewProgram(cfg *client.Config, parentName string) *tea.Program {\n\tm := NewModel(cfg)\n\tm.standalone = true\n\tm.parentName = parentName\n\treturn tea.NewProgram(m)\n}", "func main() {\n\tvar res string\n\tvar err error\n\tvar inputJsons []string\n\n\t// 1. Run one program with one input.\n\tres, err = Jq().Program(\".foo\").Run(`{\"foo\":\"bar\"}`)\n\tif err != nil {\n\t\tpanic(err)\n\t}\n\tfmt.Printf(\"1. %s\\n\", res)\n\t// Should print\n\t// 1. \"bar\"\n\n\t// 2. Use directory with jq modules.\n\tprepareJqLib()\n\tres, err = Jq().WithLibPath(\"./jq_lib\").\n\t\tProgram(`include \"mylibrary\"; .foo|mymethod`).\n\t\tRun(`{\"foo\":\"kebab-string-here\"}`)\n\tfmt.Printf(\"2. %s %s\\n\", \"kebab-string-here\", res)\n\tremoveJqLib()\n\t// Should print\n\t// 2. kebab-string-here \"kebabStringHere\"\n\n\t// 3. Use program text as a key for a cache.\n\tinputJsons = []string{\n\t\t`{ \"foo\":\"bar-quux\" }`,\n\t\t`{ \"foo\":\"baz-baz\" }`,\n\t\t// ...\n\t}\n\tfor _, data := range inputJsons {\n\t\tres, err = Jq().Program(\".foo\").Cached().Run(data)\n\t\tif err != nil {\n\t\t\tpanic(err)\n\t\t}\n\t\t// Now do something with filter result ...\n\t\tfmt.Printf(\"3. %s\\n\", res)\n\t}\n\t// Should print\n\t// 3. \"bar-quux\"\n\t// 3. \"baz-baz\"\n\n\t// 4. Explicitly precompile jq expression.\n\tinputJsons = []string{\n\t\t`{ \"bar\":\"Foo quux\" }`,\n\t\t`{ \"bar\":\"Foo baz\" }`,\n\t\t// ...\n\t}\n\tprg, err := Jq().Program(\".bar\").Precompile()\n\tif err != nil {\n\t\tpanic(err)\n\t}\n\tfor _, data := range inputJsons {\n\t\tres, err = prg.Run(data)\n\t\tif err != nil {\n\t\t\tpanic(err)\n\t\t}\n\t\t// Now do something with filter result ...\n\t\tfmt.Printf(\"4. %s\\n\", res)\n\t}\n\t// Should print\n\t// 4. \"Foo quux\"\n\t// 4. \"Foo baz\"\n\n\t// 5. It is safe to use Jq() from multiple go-routines.\n\t// Note however that programs are executed synchronously.\n\twg := sync.WaitGroup{}\n\twg.Add(3)\n\tgo func() {\n\t\tres, err = Jq().Program(\".foo\").Run(`{\"foo\":\"bar\"}`)\n\t\tif err != nil {\n\t\t\tpanic(err)\n\t\t}\n\t\tfmt.Printf(\"5. %s\\n\", res)\n\t\twg.Done()\n\t}()\n\tgo func() {\n\t\tres, err = Jq().Program(\".foo\").Cached().Run(`{\"foo\":\"bar\"}`)\n\t\tif err != nil {\n\t\t\tpanic(err)\n\t\t}\n\t\tfmt.Printf(\"5. %s\\n\", res)\n\t\twg.Done()\n\t}()\n\tgo func() {\n\t\tres, err = Jq().Program(\".foo\").Cached().Run(`{\"foo\":\"bar\"}`)\n\t\tif err != nil {\n\t\t\tpanic(err)\n\t\t}\n\t\tfmt.Printf(\"5. %s\\n\", res)\n\t\twg.Done()\n\t}()\n\twg.Wait()\n\t// Should print\n\t// 5. \"bar\"\n\t// 5. \"bar\"\n\t// 5. \"bar\"\n}", "func main() {\n\tfmt.Println(strings.Join(os.Args, \" \"))\n}", "func main() {\n\tapp := cli.NewApp()\n\tapp.Version = \"0.0.1\"\n\tapp.Name = \"sub\"\n\tapp.Usage = \"A command-line tool for substituting patterns from a stream.\"\n\tapp.UsageText = \"sub [pattern] [replacement]\"\n\tapp.Author = \"Kevin Cantwell\"\n\tapp.Email = \"[email protected]\"\n\tapp.Action = func(c *cli.Context) error {\n\t\tpattern := c.Args().Get(0)\n\t\treplacement := []byte(c.Args().Get(1))\n\n\t\tregex, err := regexp.Compile(pattern)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tscanner := bufio.NewScanner(os.Stdin)\n\t\tfor scanner.Scan() {\n\t\t\tmatches := regex.FindAllSubmatch(scanner.Bytes(), -1)\n\t\t\tfor _, submatches := range matches {\n\t\t\t\treplaced, err := replace(replacement, submatches)\n\t\t\t\tif err != nil {\n\t\t\t\t\treturn err\n\t\t\t\t}\n\t\t\t\tos.Stdout.Write(replaced)\n\t\t\t\tos.Stdout.Write([]byte(\"\\n\"))\n\t\t\t}\n\t\t}\n\t\tif err := scanner.Err(); err != nil {\n\t\t\treturn err\n\t\t}\n\n\t\treturn nil\n\t}\n\tif err := app.Run(os.Args); err != nil {\n\t\texit(err.Error(), 1)\n\t}\n}", "func main() {\n\thexStrs := os.Args[1:]\n\tif len(hexStrs) != 2 {\n\t\tlog.Fatalf(\"can only xor 2 strings. provided %d\", len(hexStrs))\n\t}\n\n\txor, err := bits.XorHexStrs(hexStrs[0], hexStrs[1])\n\tif err != nil {\n\t\tlog.Fatalf(\"cannot xor byte arrays: %v\", err)\n\t}\n\n\tfmt.Println(xor)\n}", "func ExecProgram(file string) {\n\tctx := exec.NewContext()\n\tscope := exec.NewRootScope()\n\tin, errF := lex.NewFileStream(file)\n\tif errF != nil {\n\t\tfmt.Println(errF.Display())\n\t\treturn\n\t}\n\n\tresult := ctx.ExecuteCode(in, scope)\n\t// when exec program, unlike REPL, it's not necessary to print last executed value\n\tif result.HasError {\n\t\tfmt.Println(result.Error.Display())\n\t}\n}", "func main() {\n\tfset := token.NewFileSet()\n\tf, err := parser.ParseFile(fset, \"hello.go\", src, 0)\n\tif err != nil {\n\t\tlog.Fatal(err)\n\t}\n\tfmt.Println(\"=== CheckInstances ===\")\n\tpkg, err := CheckInstances(fset, f)\n\tif err != nil {\n\t\tlog.Fatal(err)\n\t}\n\tfmt.Println(\"=== Instantiate ===\")\n\tif err := Instantiate(pkg); err != nil {\n\t\tlog.Fatal(err)\n\t}\n}", "func generateFromString(fullpath, src string) {\n\tfullpath = filepath.FromSlash(fullpath)\n\tfile, err := os.Create(fullpath)\n\tif err != nil {\n\t\tlog.Fatalf(\"Error: cannot generate file from string %s.\\n\"+\n\t\t\t\"The error is: %v\", fullpath, err)\n\t}\n\n\t_, err = file.WriteString(src)\n\tif err != nil {\n\t\tlog.Fatalf(\"Error: cannot write from string %s.\\n\"+\n\t\t\t\"The error is: %v\", fullpath, err)\n\t}\n\n\tlog.Successf(\"Created %v\\n\", fullpath)\n}", "func executeRequestFromStrings(s []string) *command.ExecuteRequest {\n\tstmts := make([]*command.Statement, len(s))\n\tfor i := range s {\n\t\tstmts[i] = &command.Statement{\n\t\t\tSql: s[i],\n\t\t}\n\t}\n\treturn &command.ExecuteRequest{\n\t\tRequest: &command.Request{\n\t\t\tStatements: stmts,\n\t\t\tTransaction: false,\n\t\t},\n\t\tTimings: false,\n\t}\n}", "func New(instructions *tk.Instructions) (*Interpreter, error) {\r\n\terr := ps.Parse(instructions)\r\n\r\n\tif err != nil {\r\n\t\treturn nil, err\r\n\t}\r\n\r\n\tmin := -1\r\n\tmax := 0\r\n\r\n\tfor index := range *instructions {\r\n\t\tif min == -1 || int(index) < min {\r\n\t\t\tmin = int(index)\r\n\t\t}\r\n\t\tif int(index) > max {\r\n\t\t\tmax = int(index)\r\n\t\t}\r\n\t}\r\n\r\n\treturn &Interpreter{\r\n\t\tinstructions: instructions,\r\n\t\tindex: uint32(min),\r\n\t\tlenght: uint32(max) + 1,\r\n\t\tstack: stack.New(),\r\n\t}, nil\r\n}", "func main() {\n\terr := shim.Start(new(SimpleChaincode))\n\tif err != nil {\n\t\tfmt.Printf(\"Error starting Simple chaincode: %s\", err)\n\t}\n}", "func main() {\n\terr := shim.Start(new(SimpleChaincode))\n\tif err != nil {\n\t\tfmt.Printf(\"Error starting Simple chaincode: %s\", err)\n\t}\n}", "func (pc *programCode) createParams(argSlice []string) {\n\tcode := \"\"\n\tregisterSlice := []string{\"rdi\", \"rsi\", \"rdx\", \"rcx\", \"r8\", \"r9\"} // SysV ABI calling register for parameters\n\tfor i := 0; i < len(argSlice) && i < 6; i++ {\n\t\tif _, err := strconv.Atoi(argSlice[i]); err == nil {\n\t\t\tcode += \"\\tmov \" + registerSlice[i] + argSlice[i] + \"\\n\"\n\t\t} else {\n\t\t\tcode += \"\\tmov \" + registerSlice[i] + \"[\" + argSlice[i] + \"]\\n\"\n\t\t}\n\t}\n\tpc.appendCode(code)\n}", "func main() {\n\tm := Matrix{}\n\ts := \"1 2 3\\n4 5 6\"\n", "func makeCmdLine(args []string) string {\n\tvar s string\n\tfor _, v := range args {\n\t\tif s != \"\" {\n\t\t\ts += \" \"\n\t\t}\n\t\ts += windows.EscapeArg(v)\n\t}\n\treturn s\n}" ]
[ "0.618819", "0.5657133", "0.55985", "0.5487285", "0.5245269", "0.51279694", "0.50902253", "0.5087321", "0.50806254", "0.5008299", "0.500511", "0.4995785", "0.49896026", "0.49355313", "0.49339277", "0.49303636", "0.49126962", "0.49057707", "0.4903192", "0.489664", "0.48895085", "0.48843318", "0.48761564", "0.48760563", "0.4873613", "0.48705393", "0.4868134", "0.48631996", "0.4860122", "0.48580435", "0.48390648", "0.48369366", "0.48268166", "0.4820201", "0.48169813", "0.48122072", "0.4809662", "0.48056838", "0.4802042", "0.47992963", "0.47984263", "0.47972617", "0.47961396", "0.47775307", "0.47771615", "0.47760484", "0.4769248", "0.47557178", "0.47541213", "0.47488284", "0.47481874", "0.47192508", "0.4718214", "0.47094253", "0.46970245", "0.46870494", "0.46732667", "0.4664284", "0.46599457", "0.46558538", "0.46366853", "0.46284008", "0.46169528", "0.46135232", "0.45929968", "0.4592315", "0.4591135", "0.45859453", "0.45791933", "0.4572617", "0.4560072", "0.45593932", "0.45575732", "0.4549145", "0.45362586", "0.45221066", "0.45124435", "0.45113355", "0.45082447", "0.45062295", "0.4501894", "0.4499378", "0.4493432", "0.44920912", "0.4489324", "0.44786412", "0.4478273", "0.4477423", "0.44759795", "0.44695038", "0.44690332", "0.44640884", "0.4458139", "0.44570532", "0.4453625", "0.44525996", "0.44524047", "0.44524047", "0.44503322", "0.44484743", "0.44466782" ]
0.0
-1
Parameter context has type C.struct__cl_context. Parameter event has type C.struct__cl_event.
func CreateSyncFromCLeventARB(context unsafe.Pointer, event unsafe.Pointer, flags uint32) uintptr { ret := C.glowCreateSyncFromCLeventARB(gpCreateSyncFromCLeventARB, (*C.struct__cl_context)(context), (*C.struct__cl_event)(event), (C.GLbitfield)(flags)) return (uintptr)(ret) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func (s *BasevhdlListener) EnterContext_item(ctx *Context_itemContext) {}", "func (s *BasevhdlListener) EnterContext_clause(ctx *Context_clauseContext) {}", "func (s *BasecluListener) EnterParam(ctx *ParamContext) {}", "func (p *paramConf) eventProcess(ev *EventData) {\n\tif p == nil {\n\t\treturn\n\t}\n\t// Process event #3: New peer connected to this host\n\tif ev.Event == EventConnected && ev.Data.From() == \"teo-cdb\" {\n\t\tfmt.Printf(\"Teo-cdb peer connectd. Read config...\\n\")\n\t\tif err := p.ReadBoth(); err != nil {\n\t\t\tfmt.Printf(\"Error: %s\\n\", err)\n\t\t}\n\t\tvar v = p.Value().(*param)\n\t\tfmt.Printf(\"Descr: %s\\n\", v.Descr)\n\t}\n\n\t// // Process event #4: Peer disconnected to this host\n\t// if ev.Event == EventDisconnected && ev.Data.From() == \"teo-cdb\" {\n\t// \tp.l0.teo.ev.unsubscribe(p.chanEvent)\n\t// \tfmt.Printf(\"!!! Unsubscribed - peer disconnected !!!\\n\")\n\t// }\n}", "func C(tag string, fields ...interface{}) *Context {\n\tvar buf bytes.Buffer\n\twriteFields(&buf, fields...)\n\temitter := &Emitter{\n\t\tLevel: Default.Level,\n\t\tOutput: Default.Output,\n\t\tTimeFormat: Default.TimeFormat,\n\t\tHook: Default.Hook,\n\t\tcontext: buf.Bytes(),\n\t}\n\treturn &Context{Emitter: emitter, Tag: tag}\n}", "func (self *PhysicsP2) CallbackContext() interface{}{\n return self.Object.Get(\"callbackContext\")\n}", "func (s *BaseAspidaListener) EnterComp_op(ctx *Comp_opContext) {}", "func (eventMessage EventMessage) Context() Context {\n\treturn Context{\n\t\tCorrelationID: eventMessage.Header.CorrelationID,\n\t\tTimestamp: eventMessage.Header.Timestamp,\n\t\tApplication: eventMessage.Header.Application,\n\t\tPlatform: eventMessage.Header.Platform,\n\t}\n}", "func (s *BaseConcertoListener) EnterFuncArg(ctx *FuncArgContext) {}", "func (s *BasevhdlListener) EnterActual_parameter_part(ctx *Actual_parameter_partContext) {}", "func (l eventlog) Log(context interface{}, name string, message string, data ...interface{}) {}", "func (s *BasevhdlListener) EnterParameter_specification(ctx *Parameter_specificationContext) {}", "func (c *OutputEventContext) Put(event *protocol.Event) {\n\tc.Context[event.GetName()] = event\n}", "func (s *BasePlSqlParserListener) EnterC_parameters_clause(ctx *C_parameters_clauseContext) {}", "func (s *BasevhdlListener) EnterComponent_configuration(ctx *Component_configurationContext) {}", "func (c *Context) C(fields ...interface{}) *Context {\n\tvar buf bytes.Buffer\n\tbuf.Write(c.Emitter.context)\n\twriteFields(&buf, fields...)\n\temitter := &Emitter{\n\t\tLevel: c.Emitter.Level,\n\t\tOutput: c.Emitter.Output,\n\t\tTimeFormat: c.Emitter.TimeFormat,\n\t\tHook: c.Emitter.Hook,\n\t\tcontext: buf.Bytes(),\n\t}\n\treturn &Context{Emitter: emitter, Tag: c.Tag}\n}", "func CommandContext(conf Config, state State, ctx, query Query) error {\n\tif len(os.Args) < 3 {\n\t\tfmt.Println(ctx)\n\t} else if os.Args[2] == \"none\" {\n\t\tif err := state.SetContext(Query{}); err != nil {\n\t\t\treturn err\n\t\t}\n\t} else {\n\t\tif err := state.SetContext(query); err != nil {\n\t\t\treturn err\n\t\t}\n\t}\n\n\tstate.Save(conf.StateFile)\n\treturn nil\n}", "func (s *BasecluListener) EnterParms(ctx *ParmsContext) {}", "func (e *Event) Context() context.Context {\n\treturn e.ctx\n}", "func (store *context) Apply(event trace.Event) (trace.Event, error) {\n\tcontextID, err := parse.ArgVal[uint64](event.Args, ContextArgName)\n\tif err != nil {\n\t\treturn trace.Event{}, errfmt.Errorf(\"error parsing caller_context_id arg: %v\", err)\n\t}\n\tinvoking, ok := store.Load(contextID)\n\tif !ok {\n\t\treturn trace.Event{}, NoEventContextError(contextID)\n\t}\n\n\t// Apply the invoking event data on top of the argument event. This is done in the opposite\n\t// \"direction\" because we only need the uint64, name, etc., from the argument event.\n\n\t// same logic as derive.newEvent\n\tinvoking.EventName = event.EventName\n\tinvoking.EventID = event.EventID\n\tinvoking.ReturnValue = 0\n\tinvoking.Args = make([]trace.Argument, len(event.Args))\n\tinvoking.MatchedPoliciesKernel = event.MatchedPoliciesKernel\n\tinvoking.MatchedPoliciesUser = event.MatchedPoliciesUser\n\tcopied := copy(invoking.Args, event.Args)\n\tif copied != len(event.Args) {\n\t\treturn trace.Event{}, errfmt.Errorf(\"failed to apply event's args\")\n\t}\n\tinvoking.ArgsNum = event.ArgsNum\n\n\treturn invoking, nil\n}", "func (s *BaseednListener) EnterVector(ctx *VectorContext) {}", "func handleConfigurationChangeEvent(event cloudevents.Event, shkeptncontext string, data *keptnevents.ConfigurationChangeEventData, logger *keptnutils.Logger) error {\n\tlogger.Info(fmt.Sprintf(\"Handling Configuration Changed Event: %s\", event.Context.GetID()));\n\n\treturn nil\n}", "func (p *PointerCallback) LoadContext(v *vm.VM, args []stackitem.Item) {\n\tv.Call(p.context, p.offset)\n\tfor i := len(args) - 1; i >= 0; i-- {\n\t\tv.Estack().PushVal(args[i])\n\t}\n}", "func (s *BaseConcertoListener) EnterFuncCallArg(ctx *FuncCallArgContext) {}", "func (s *BaseCGListener) EnterCr(ctx *CrContext) {}", "func (e EventListener) Event(event *core.Event) {\n\tvalue := e.Factory.GetConfigurationByKey(event.Key)\n\tlager.Logger.Infof(\"config value after change %s | %s\", event.Key, value)\n}", "func (s *BaseLittleDuckListener) EnterCondicion(ctx *CondicionContext) {}", "func (z *zpoolctl) Event(ctx context.Context, options string) *execute {\n\targs := []string{\"event\"}\n\tif len(options) > 0 {\n\t\targs = append(args, options)\n\t}\n\treturn &execute{ctx: ctx, name: z.cmd, args: args}\n}", "func (oc *OutputConfig) Event(ctx context.Context, event utils.LogEvent) (err error) {\n\tcommand := event.Message\n\tif command == \"\" {\n\t\treturn errors.New(\"message is null.\")\n\t}\n\targs := event.Extra[\"args\"].([]string)\n\t// run the proc and get all the cmd info.\n\tCmd := exec.CommandContext(ctx, command, args...)\n\n\t// start the commd.\n\tif err = Cmd.Start(); err != nil {\n\t\treturn err\n\t}\n\t// Wait for the proc done and reset cmd = nil.\n\tCmd.Wait()\n\treturn\n}", "func onEventCallback(e event.Event, ctx interface{}) {\n\tservice := ctx.(*metadataService)\n\tservice.eventChan <- e\n}", "func (s *BasevhdlListener) ExitContext_item(ctx *Context_itemContext) {}", "func (s *BasevhdlListener) EnterGeneric_list(ctx *Generic_listContext) {}", "func (self *SinglePad) CallbackContext() interface{}{\n return self.Object.Get(\"callbackContext\")\n}", "func (API) Context(s *api.State, thread uint64) api.Context {\n\treturn nil\n}", "func onEventCallback(e event.Event, ctx interface{}) {\n\tservice := ctx.(*qutoService)\n\tservice.eventChan <- e\n}", "func (s *BasecluListener) EnterArgs(ctx *ArgsContext) {}", "func Event(ctx context.Context, scope EventScope, name string, args ...interface{}) {\n\tt := GetTask(ctx)\n\tonEvent(ctx, t, scope, name, args)\n}", "func (s *BasejossListener) EnterFuncCos(ctx *FuncCosContext) {}", "func (s *BaseCGListener) EnterAttribute(ctx *AttributeContext) {}", "func Event(ctx context.Context, msg string) {\n\teventInternal(ctx, false /* isErr */, true /* withTags */, msg)\n}", "func (p *EventPolicy) Context() Context {\n\treturn p.context\n}", "func (s *BaseCGListener) EnterConceptid(ctx *ConceptidContext) {}", "func Context(sc jaeger.SpanContext) zapcore.Field {\n\treturn zap.Object(\"context\", spanContext(sc))\n}", "func (s *BasemumpsListener) EnterParam(ctx *ParamContext) {}", "func (g *Group) CtContext(ctx context.Context, new uint16) error {\n\tupdate := State{On: true, Ct: new}\n\t_, err := g.bridge.SetGroupStateContext(ctx, g.ID, update)\n\tif err != nil {\n\t\treturn err\n\t}\n\tg.State.Ct = new\n\tg.State.On = true\n\treturn nil\n}", "func CCtx(ctx context.Context, format string, args ...interface{}) {\n\tif hub := sentry.GetHubFromContext(ctx); hub != nil {\n\t\tcreticaldeps(hub.CaptureMessage, 3, format, args...)\n\t\treturn\n\t}\n\n\tcreticaldeps(sentry.CaptureMessage, 3, format, args...)\n}", "func (s *BasevhdlListener) EnterProcedure_call(ctx *Procedure_callContext) {}", "func TestEmitContextEvents(t *testing.T) {\n\tassert := asserts.NewTesting(t, asserts.FailStop)\n\tmsh := mesh.New()\n\n\terr := msh.SpawnCells(NewTestBehavior(\"foo\"))\n\tassert.NoError(err)\n\n\tctxA := context.Background()\n\tctxB, cancel := context.WithTimeout(ctxA, 5*time.Millisecond)\n\tdefer cancel()\n\n\tmsh.Emit(\"foo\", event.WithContext(ctxA, \"set\", \"a\", 5))\n\tmsh.Emit(\"foo\", event.WithContext(ctxA, \"set\", \"b\", 5))\n\n\ttime.Sleep(20 * time.Millisecond)\n\n\tmsh.Emit(\"foo\", event.WithContext(ctxB, \"set\", \"b\", 10))\n\n\tpl, plc := event.NewReplyPayload()\n\n\tmsh.Emit(\"foo\", event.New(\"send\", pl))\n\n\tplr, err := plc.Wait(waitTimeout)\n\n\tassert.NoError(err)\n\tassert.Equal(plr.At(\"a\").AsInt(0), 5)\n\tassert.Equal(plr.At(\"b\").AsInt(0), 5)\n\n\terr = msh.Stop()\n\tassert.NoError(err)\n}", "func (c *EventTagsUpdateCall) Context(ctx context.Context) *EventTagsUpdateCall {\n\tc.ctx_ = ctx\n\treturn c\n}", "func (s *BasevhdlListener) EnterEntity_tag(ctx *Entity_tagContext) {}", "func contextOf(cfg api.Config, clusterID string) string {\n\tfor name, context := range cfg.Contexts {\n\t\tif clusterID == context.Cluster {\n\t\t\treturn name\n\t\t}\n\t}\n\treturn \"\"\n}", "func (s *BasevhdlListener) EnterConcurrent_procedure_call_statement(ctx *Concurrent_procedure_call_statementContext) {\n}", "func ProcessEvent(ctx context.Context, event *greeter.HelloRequest) error {\n\tfmt.Printf(\"Got event with name %s\\n\", event.Name)\n\treturn nil\n}", "func (o *SystemEventsParams) SetContext(ctx context.Context) {\n\to.Context = ctx\n}", "func (t *TrudyPipe) AddContext(key string, value interface{}) {\n\tt.pipeMutex.Lock()\n\tt.KV[key] = value\n\tt.pipeMutex.Unlock()\n}", "func (m *Parameter) ContextValidate(ctx context.Context, formats strfmt.Registry) error {\n\treturn nil\n}", "func InitContext(cfg ConfigT, ctx *ContextT) {\n\tctx.raw = uintptr(unsafe.Pointer(C.yices_new_context(ycfg(cfg))))\n}", "func (ct *ctrlerCtx) handleCredentialsEventParallel(evt *kvstore.WatchEvent) error {\n\n\tif ct.objResolver == nil {\n\t\treturn ct.handleCredentialsEventParallelWithNoResolver(evt)\n\t}\n\n\tswitch tp := evt.Object.(type) {\n\tcase *cluster.Credentials:\n\t\teobj := evt.Object.(*cluster.Credentials)\n\t\tkind := \"Credentials\"\n\n\t\teobj.ApplyStorageTransformer(context.Background(), true /*encrypt*/)\n\t\tlog.Infof(\"Watcher: Got %s watch event(%s): {%+v}\", kind, evt.Type, eobj)\n\t\teobj.ApplyStorageTransformer(context.Background(), false /*decrypt*/)\n\n\t\tctx := &credentialsCtx{event: evt.Type, obj: &Credentials{Credentials: *eobj, ctrler: ct}}\n\t\tctx.SetWatchTs(evt.WatchTS)\n\n\t\tvar err error\n\t\tswitch evt.Type {\n\t\tcase kvstore.Created:\n\t\t\terr = ct.processAdd(ctx)\n\t\tcase kvstore.Updated:\n\t\t\terr = ct.processUpdate(ctx)\n\t\tcase kvstore.Deleted:\n\t\t\terr = ct.processDelete(ctx)\n\t\t}\n\t\treturn err\n\tdefault:\n\t\tct.logger.Fatalf(\"API watcher Found object of invalid type: %v on Credentials watch channel\", tp)\n\t}\n\n\treturn nil\n}", "func (s *BasePlSqlParserListener) EnterOdci_parameters(ctx *Odci_parametersContext) {}", "func (s *BaseCymbolListener) EnterFormalParameter(ctx *FormalParameterContext) {}", "func STC() { ctx.STC() }", "func (ct *ctrlerCtx) handleDistributedServiceCardEventParallel(evt *kvstore.WatchEvent) error {\n\n\tif ct.objResolver == nil {\n\t\treturn ct.handleDistributedServiceCardEventParallelWithNoResolver(evt)\n\t}\n\n\tswitch tp := evt.Object.(type) {\n\tcase *cluster.DistributedServiceCard:\n\t\teobj := evt.Object.(*cluster.DistributedServiceCard)\n\t\tkind := \"DistributedServiceCard\"\n\n\t\tlog.Infof(\"Watcher: Got %s watch event(%s): {%+v}\", kind, evt.Type, eobj)\n\n\t\tctx := &distributedservicecardCtx{event: evt.Type, obj: &DistributedServiceCard{DistributedServiceCard: *eobj, ctrler: ct}}\n\t\tctx.SetWatchTs(evt.WatchTS)\n\n\t\tvar err error\n\t\tswitch evt.Type {\n\t\tcase kvstore.Created:\n\t\t\terr = ct.processAdd(ctx)\n\t\tcase kvstore.Updated:\n\t\t\terr = ct.processUpdate(ctx)\n\t\tcase kvstore.Deleted:\n\t\t\terr = ct.processDelete(ctx)\n\t\t}\n\t\treturn err\n\tdefault:\n\t\tct.logger.Fatalf(\"API watcher Found object of invalid type: %v on DistributedServiceCard watch channel\", tp)\n\t}\n\n\treturn nil\n}", "func configCurrentContextFunc(cmd *cobra.Command, args []string) {\n\tlog.Info(options.GetCurrentContextName())\n}", "func (ct *ctrlerCtx) handleClusterEventParallel(evt *kvstore.WatchEvent) error {\n\n\tif ct.objResolver == nil {\n\t\treturn ct.handleClusterEventParallelWithNoResolver(evt)\n\t}\n\n\tswitch tp := evt.Object.(type) {\n\tcase *cluster.Cluster:\n\t\teobj := evt.Object.(*cluster.Cluster)\n\t\tkind := \"Cluster\"\n\n\t\teobj.ApplyStorageTransformer(context.Background(), true /*encrypt*/)\n\t\tlog.Infof(\"Watcher: Got %s watch event(%s): {%+v}\", kind, evt.Type, eobj)\n\t\teobj.ApplyStorageTransformer(context.Background(), false /*decrypt*/)\n\n\t\tctx := &clusterCtx{event: evt.Type, obj: &Cluster{Cluster: *eobj, ctrler: ct}}\n\t\tctx.SetWatchTs(evt.WatchTS)\n\n\t\tvar err error\n\t\tswitch evt.Type {\n\t\tcase kvstore.Created:\n\t\t\terr = ct.processAdd(ctx)\n\t\tcase kvstore.Updated:\n\t\t\terr = ct.processUpdate(ctx)\n\t\tcase kvstore.Deleted:\n\t\t\terr = ct.processDelete(ctx)\n\t\t}\n\t\treturn err\n\tdefault:\n\t\tct.logger.Fatalf(\"API watcher Found object of invalid type: %v on Cluster watch channel\", tp)\n\t}\n\n\treturn nil\n}", "func (o *PluginIgmpClient) OnEvent(msg string, a, b interface{}) {\n\n}", "func (s *BasevhdlListener) EnterOpts(ctx *OptsContext) {}", "func (v *FlagshipVisitor) UpdateContext(newContext map[string]interface{}) (err error) {\n\tdefer func() {\n\t\tif r := recover(); r != nil {\n\t\t\terr = utils.HandleRecovered(r, visitorLogger)\n\t\t}\n\t}()\n\n\terrs := validateContext(newContext)\n\tif len(errs) > 0 {\n\t\terrorStrings := []string{}\n\t\tfor _, e := range errs {\n\t\t\tvisitorLogger.Error(\"Context error\", e)\n\t\t\terrorStrings = append(errorStrings, e.Error())\n\t\t}\n\t\treturn fmt.Errorf(\"Invalid context : %s\", strings.Join(errorStrings, \", \"))\n\t}\n\n\tv.Context = newContext\n\treturn nil\n}", "func (s *BasePCREListener) EnterCc_atom(ctx *Cc_atomContext) {}", "func (s *BaseSyslParserListener) EnterParam(ctx *ParamContext) {}", "func (l *LogDebugger) Event(e *Event) {\r\n\ti := atomic.AddInt32(&l.counter, 1)\r\n\tl.logger.Printf(\"[%06d] %d [%6d - %s] %q (%s)\\n\", i, e.CollectorID, e.RequestID, e.Type, e.Values, time.Since(l.start))\r\n}", "func (s *BaseRFC5424Listener) EnterParam(ctx *ParamContext) {}", "func FeatureContext(s *godog.Suite) {\n\tconfigFilePath := flag.String(\"config\", \"\", \"Path to configuration file\")\n\n\tflag.Parse()\n\n\tif *configFilePath == \"\" {\n\t\t*configFilePath = \"./config/config.development.json\"\n\t}\n\n\tconfiguration := &config.Configuration{}\n\terr := configuration.Load(\n\t\t*configFilePath,\n\t\t&config.Configuration{\n\t\t\tLogFilePath: \"stderr\",\n\t\t\tLogLevel: \"debug\",\n\t\t},\n\t)\n\tif err != nil {\n\t\tlog.Fatalf(\"failed to load configuration: %v\", err)\n\t}\n\n\teventTest, err := event.NewEvent(context.Background(), configuration)\n\tif err != nil {\n\t\tlog.Fatalf(\"faile to create test: %v\", err)\n\t}\n\n\ts.BeforeScenario(eventTest.Start)\n\n\ts.Step(`^User creates today event:$`, eventTest.CreateFirstFromTable)\n\ts.Step(`^User receives notification with title \"([^\"]*)\"$`, eventTest.WaitForNotification)\n\n\ts.Step(`^User creates day event:$`, eventTest.CreateAllFromTable)\n\ts.Step(`^User\\'s daily schedule contains an event that has been created:$`, eventTest.VerifyDayByTable)\n\n\ts.Step(`^User creates events for week:$`, eventTest.CreateAllFromTable)\n\ts.Step(`^User\\'s weekly schedule contains all events that has been created:$`, eventTest.VerifyWeekByTable)\n\n\ts.Step(`^User creates events for month:$`, eventTest.CreateAllFromTable)\n\ts.Step(`^User\\'s monthly schedule contains all events that has been created:$`, eventTest.VerifyMonthByTable)\n\n\ts.AfterScenario(eventTest.Stop)\n}", "func (p *ContextPlugin) Execute(event *types.Event) *types.Event {\n\tif event.Time == 0 {\n\t\tevent.Time = time.Now().UnixMilli()\n\t}\n\n\tif event.InsertID == \"\" {\n\t\tevent.InsertID = uuid.NewString()\n\t}\n\n\tevent.Library = p.contextString\n\n\treturn event\n}", "func (s *BasePlSqlParserListener) EnterCreate_context(ctx *Create_contextContext) {}", "func (s *BasevhdlListener) EnterFormal_parameter_list(ctx *Formal_parameter_listContext) {}", "func (bas *BaseService) OnRequest(ctx context.Context, args Args) {}", "func bindContext(address common.Address, caller bind.ContractCaller, transactor bind.ContractTransactor, filterer bind.ContractFilterer) (*bind.BoundContract, error) {\n\tparsed, err := abi.JSON(strings.NewReader(ContextABI))\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\treturn bind.NewBoundContract(address, parsed, caller, transactor, filterer), nil\n}", "func bindContext(address common.Address, caller bind.ContractCaller, transactor bind.ContractTransactor, filterer bind.ContractFilterer) (*bind.BoundContract, error) {\n\tparsed, err := abi.JSON(strings.NewReader(ContextABI))\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\treturn bind.NewBoundContract(address, parsed, caller, transactor, filterer), nil\n}", "func bindContext(address common.Address, caller bind.ContractCaller, transactor bind.ContractTransactor, filterer bind.ContractFilterer) (*bind.BoundContract, error) {\n\tparsed, err := abi.JSON(strings.NewReader(ContextABI))\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\treturn bind.NewBoundContract(address, parsed, caller, transactor, filterer), nil\n}", "func bindContext(address common.Address, caller bind.ContractCaller, transactor bind.ContractTransactor, filterer bind.ContractFilterer) (*bind.BoundContract, error) {\n\tparsed, err := abi.JSON(strings.NewReader(ContextABI))\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\treturn bind.NewBoundContract(address, parsed, caller, transactor, filterer), nil\n}", "func (s *BaseCGListener) EnterSctid(ctx *SctidContext) {}", "func (s *BasevhdlListener) EnterGeneric_clause(ctx *Generic_clauseContext) {}", "func (e LocalService) OnEvent(ctx context.Context, event models.KeptnContextExtendedCE) error {\n\t// You can grab handle the event and grab a sender to send back started / finished events to keptn\n\t// eventSender := ctx.Value(controlplane.EventSenderKeyType{}).(types.EventSender)\n\treturn nil\n}", "func (s *BasePlSqlParserListener) EnterModify_lob_parameters(ctx *Modify_lob_parametersContext) {}", "func (s *Basegff3Listener) EnterAttributes(ctx *AttributesContext) {}", "func (self *ComponentScaleMinMax) TransformCallbackContext() interface{}{\n return self.Object.Get(\"transformCallbackContext\")\n}", "func (s *BasecluListener) EnterConstant(ctx *ConstantContext) {}", "func init() {\n\tctx_notify = make(map[unsafe.Pointer]CL_ctx_notify)\n}", "func (object Object) Context(value interface{}) Object {\n\t// TODO: incomplete\n\treturn object\n}", "func (s *BaseCymbolListener) EnterStat(ctx *StatContext) {}", "func InitContext(params pgs.Parameters) Context {\n\treturn context{params}\n}", "func (h *Handler) Context() *snow.Context { return h.engine.Context() }", "func (s *Basegff3Listener) EnterType_(ctx *Type_Context) {}", "func (s *BasevhdlListener) EnterComponent_specification(ctx *Component_specificationContext) {}", "func (gm GlobalManager) RegisterParamChangeEvent(ctx sdk.Context, event types.Event) sdk.Error {\n\t// param will be changed in one day\n\tproposalParam, err := gm.paramHolder.GetProposalParam(ctx)\n\tif err != nil {\n\t\treturn err\n\t}\n\tif ctx.BlockHeader().Height > types.LinoBlockchainFirstUpdateHeight {\n\t\tif err := gm.registerEventAtTime(\n\t\t\tctx, ctx.BlockHeader().Time.Unix()+3600, event); err != nil {\n\t\t\treturn err\n\t\t}\n\t} else {\n\t\tif err := gm.registerEventAtTime(\n\t\t\tctx, ctx.BlockHeader().Time.Unix()+proposalParam.ChangeParamExecutionSec, event); err != nil {\n\t\t\treturn err\n\t\t}\n\t}\n\treturn nil\n}", "func (s *BaseSyslParserListener) EnterCollector_query_param(ctx *Collector_query_paramContext) {}", "func (m *ChangeEventSlimEntity) ContextValidate(ctx context.Context, formats strfmt.Registry) error {\n\tvar res []error\n\n\tif err := m.contextValidateAuthors(ctx, formats); err != nil {\n\t\tres = append(res, err)\n\t}\n\n\tif err := m.contextValidateEnvironments(ctx, formats); err != nil {\n\t\tres = append(res, err)\n\t}\n\n\tif err := m.contextValidateServices(ctx, formats); err != nil {\n\t\tres = append(res, err)\n\t}\n\n\tif len(res) > 0 {\n\t\treturn errors.CompositeValidationError(res...)\n\t}\n\treturn nil\n}", "func (c *NATSTestClient) ConnEvent(cid string, event string, payload interface{}) {\n\tc.event(\"conn.\"+cid, event, payload)\n}", "func (s *BasePlSqlParserListener) EnterC_spec(ctx *C_specContext) {}", "func (decoder *EbpfDecoder) DecodeContext(ctx *Context) error {\n\toffset := decoder.cursor\n\tif len(decoder.buffer[offset:]) < 120 {\n\t\treturn fmt.Errorf(\"can't read context from buffer: buffer too short\")\n\t}\n\tctx.Ts = binary.LittleEndian.Uint64(decoder.buffer[offset : offset+8])\n\tctx.StartTime = binary.LittleEndian.Uint64(decoder.buffer[offset+8 : offset+16])\n\tctx.CgroupID = binary.LittleEndian.Uint64(decoder.buffer[offset+16 : offset+24])\n\tctx.Pid = binary.LittleEndian.Uint32(decoder.buffer[offset+24 : offset+28])\n\tctx.Tid = binary.LittleEndian.Uint32(decoder.buffer[offset+28 : offset+32])\n\tctx.Ppid = binary.LittleEndian.Uint32(decoder.buffer[offset+32 : offset+36])\n\tctx.HostPid = binary.LittleEndian.Uint32(decoder.buffer[offset+36 : offset+40])\n\tctx.HostTid = binary.LittleEndian.Uint32(decoder.buffer[offset+40 : offset+44])\n\tctx.HostPpid = binary.LittleEndian.Uint32(decoder.buffer[offset+44 : offset+48])\n\tctx.Uid = binary.LittleEndian.Uint32(decoder.buffer[offset+48 : offset+52])\n\tctx.MntID = binary.LittleEndian.Uint32(decoder.buffer[offset+52 : offset+56])\n\tctx.PidID = binary.LittleEndian.Uint32(decoder.buffer[offset+56 : offset+60])\n\t_ = copy(ctx.Comm[:], decoder.buffer[offset+60:offset+76])\n\t_ = copy(ctx.UtsName[:], decoder.buffer[offset+76:offset+92])\n\tctx.Flags = binary.LittleEndian.Uint32(decoder.buffer[offset+92 : offset+96])\n\tctx.EventID = events.ID(int32(binary.LittleEndian.Uint32(decoder.buffer[offset+96 : offset+100])))\n\t// offset 100:103 is used for padding\n\tctx.Retval = int64(binary.LittleEndian.Uint64(decoder.buffer[offset+104 : offset+112]))\n\tctx.StackID = binary.LittleEndian.Uint32(decoder.buffer[offset+112 : offset+116])\n\tctx.ProcessorId = binary.LittleEndian.Uint16(decoder.buffer[offset+116 : offset+118])\n\tctx.Argnum = uint8(binary.LittleEndian.Uint16(decoder.buffer[offset+118 : offset+120]))\n\tdecoder.cursor += int(ctx.GetSizeBytes())\n\treturn nil\n}", "func (ct *ctrlerCtx) handleVersionEventParallel(evt *kvstore.WatchEvent) error {\n\n\tif ct.objResolver == nil {\n\t\treturn ct.handleVersionEventParallelWithNoResolver(evt)\n\t}\n\n\tswitch tp := evt.Object.(type) {\n\tcase *cluster.Version:\n\t\teobj := evt.Object.(*cluster.Version)\n\t\tkind := \"Version\"\n\n\t\tlog.Infof(\"Watcher: Got %s watch event(%s): {%+v}\", kind, evt.Type, eobj)\n\n\t\tctx := &versionCtx{event: evt.Type, obj: &Version{Version: *eobj, ctrler: ct}}\n\t\tctx.SetWatchTs(evt.WatchTS)\n\n\t\tvar err error\n\t\tswitch evt.Type {\n\t\tcase kvstore.Created:\n\t\t\terr = ct.processAdd(ctx)\n\t\tcase kvstore.Updated:\n\t\t\terr = ct.processUpdate(ctx)\n\t\tcase kvstore.Deleted:\n\t\t\terr = ct.processDelete(ctx)\n\t\t}\n\t\treturn err\n\tdefault:\n\t\tct.logger.Fatalf(\"API watcher Found object of invalid type: %v on Version watch channel\", tp)\n\t}\n\n\treturn nil\n}" ]
[ "0.58962584", "0.5505896", "0.54211545", "0.53614587", "0.5330028", "0.5248324", "0.52421916", "0.5169795", "0.51675516", "0.5145184", "0.50820357", "0.5064712", "0.5052316", "0.5040894", "0.5038933", "0.5033511", "0.5027897", "0.49973547", "0.49964768", "0.497986", "0.4973747", "0.4973487", "0.4971835", "0.4959269", "0.49428388", "0.4920476", "0.48979807", "0.48881066", "0.4856621", "0.48449916", "0.48419264", "0.48147553", "0.4813967", "0.48120615", "0.48119935", "0.48022053", "0.48010364", "0.47918338", "0.47846237", "0.478459", "0.4760532", "0.47468448", "0.47465575", "0.4746224", "0.47449186", "0.47384575", "0.47376063", "0.47355586", "0.4714393", "0.47106707", "0.47078502", "0.47030804", "0.46923658", "0.46908072", "0.46884888", "0.46858552", "0.46839955", "0.4682524", "0.46800599", "0.4672891", "0.4670441", "0.46682277", "0.4665605", "0.46620095", "0.46567595", "0.46517003", "0.46501336", "0.46488786", "0.46478298", "0.46464437", "0.4645243", "0.4642288", "0.4641847", "0.46309212", "0.46300995", "0.4627154", "0.4627002", "0.4627002", "0.4627002", "0.4627002", "0.46182516", "0.46176618", "0.4614059", "0.4612053", "0.4604378", "0.4602088", "0.4593079", "0.45790547", "0.457532", "0.4573784", "0.4572654", "0.4570028", "0.45696524", "0.45594335", "0.4554362", "0.45539612", "0.45484576", "0.4547698", "0.45447898", "0.45389655", "0.45332605" ]
0.0
-1
create transform feedback objects
func CreateTransformFeedbacks(n int32, ids *uint32) { C.glowCreateTransformFeedbacks(gpCreateTransformFeedbacks, (C.GLsizei)(n), (*C.GLuint)(unsafe.Pointer(ids))) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func TransformFeedbackBufferBase(xfb uint32, index uint32, buffer uint32) {\n\tsyscall.Syscall(gpTransformFeedbackBufferBase, 3, uintptr(xfb), uintptr(index), uintptr(buffer))\n}", "func transformationFeature(transformer Transformer) Feature {\n\ttransformationType := NewFeature(TransformationTypeFeature, -1)\n\tswitch transformer.(type) {\n\tcase logicalOperatorReplacement:\n\t\ttransformationType.Score = LogicalOperatorTransformation\n\tcase *adjacencyRange:\n\t\ttransformationType.Score = AdjacencyRangeTransformation\n\tcase meshExplosion:\n\t\ttransformationType.Score = MeshExplosionTransformation\n\tcase fieldRestrictions:\n\t\ttransformationType.Score = FieldRestrictionsTransformation\n\tcase adjacencyReplacement:\n\t\ttransformationType.Score = AdjacencyReplacementTransformation\n\tcase clauseRemoval:\n\t\ttransformationType.Score = ClauseRemovalTransformation\n\tcase cui2vecExpansion:\n\t\ttransformationType.Score = Cui2vecExpansionTransformation\n\tcase meshParent:\n\t\ttransformationType.Score = MeshParentTransformation\n\t}\n\treturn transformationType\n}", "func NewTransform() *Transform {\n\treturn &Transform{}\n}", "func TransformFeedbackBufferBase(xfb uint32, index uint32, buffer uint32) {\n\tC.glowTransformFeedbackBufferBase(gpTransformFeedbackBufferBase, (C.GLuint)(xfb), (C.GLuint)(index), (C.GLuint)(buffer))\n}", "func TransformFeedbackBufferBase(xfb uint32, index uint32, buffer uint32) {\n\tC.glowTransformFeedbackBufferBase(gpTransformFeedbackBufferBase, (C.GLuint)(xfb), (C.GLuint)(index), (C.GLuint)(buffer))\n}", "func Transform(ctx context.Context, input <-chan CrawlResult, worker TransformFunc, parallelism int) <-chan TransformResult {\n\tt := &transformer{\n\t\tinput: input,\n\t\toutput: make(chan TransformResult, 1000),\n\t\tworkerBody: worker,\n\t\tparallelism: parallelism,\n\t}\n\tgo t.runWorkersToCompletion(ctx)\n\treturn t.output\n}", "func NewTransform(cfg *viper.Viper) (interface{}, error) {\n\tgremlinClient, err := client.NewGremlinQueryHelperFromConfig(core.CfgAuthOpts(cfg))\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\treturn &vpclogsFlowTransformer{\n\t\tinterfaceIpCache: cache.New(10*time.Minute, 10*time.Minute),\n\t\tgremlinClient: gremlinClient,\n\t}, nil\n}", "func (wc *watchChan) transform(e *event) (res *watch.Event) {\n\tcurObj, oldObj, err := wc.prepareObjs(e)\n\tif err != nil {\n\t\tlogrus.Errorf(\"failed to prepare current and previous objects: %v\", err)\n\t\twc.sendError(err)\n\t\treturn nil\n\t}\n\tswitch {\n\tcase e.isProgressNotify:\n\t\tobj := wc.watcher.newFunc()\n\t\t// todo: update object version\n\t\tres = &watch.Event{\n\t\t\tType: watch.Bookmark,\n\t\t\tObject: obj,\n\t\t}\n\tcase e.isDeleted:\n\t\tres = &watch.Event{\n\t\t\tType: watch.Deleted,\n\t\t\tObject: oldObj,\n\t\t}\n\tcase e.isCreated:\n\t\tres = &watch.Event{\n\t\t\tType: watch.Added,\n\t\t\tObject: curObj,\n\t\t}\n\tdefault:\n\t\t// TODO: emit ADDED if the modified object causes it to actually pass the filter but the previous one did not\n\t\tres = &watch.Event{\n\t\t\tType: watch.Modified,\n\t\t\tObject: curObj,\n\t\t}\n\t}\n\treturn res\n}", "func (self *ComponentScaleMinMax) TransformCallbackContext() interface{}{\n return self.Object.Get(\"transformCallbackContext\")\n}", "func TransformFeedbackBufferRange(xfb uint32, index uint32, buffer uint32, offset int, size int) {\n\tsyscall.Syscall6(gpTransformFeedbackBufferRange, 5, uintptr(xfb), uintptr(index), uintptr(buffer), uintptr(offset), uintptr(size), 0)\n}", "func (h *pardo) PrepareTransform(tid string, t *pipepb.PTransform, comps *pipepb.Components) (*pipepb.Components, []string) {\n\n\t// ParDos are a pain in the butt.\n\t// Combines, by comparison, are dramatically simpler.\n\t// This is because for ParDos, how they are handled, and what kinds of transforms are in\n\t// and around the ParDo, the actual shape of the graph will change.\n\t// At their simplest, it's something a DoFn will handle on their own.\n\t// At their most complex, they require intimate interaction with the subgraph\n\t// bundling process, the data layer, state layers, and control layers.\n\t// But unlike combines, which have a clear urn for composite + special payload,\n\t// ParDos have the standard URN for composites with the standard payload.\n\t// So always, we need to first unmarshal the payload.\n\n\tpardoPayload := t.GetSpec().GetPayload()\n\tpdo := &pipepb.ParDoPayload{}\n\tif err := (proto.UnmarshalOptions{}).Unmarshal(pardoPayload, pdo); err != nil {\n\t\tpanic(fmt.Sprintf(\"unable to decode ParDoPayload for transform[%v]\", t.GetUniqueName()))\n\t}\n\n\t// Lets check for and remove anything that makes things less simple.\n\tif pdo.OnWindowExpirationTimerFamilySpec == \"\" &&\n\t\t!pdo.RequestsFinalization &&\n\t\t!pdo.RequiresStableInput &&\n\t\t!pdo.RequiresTimeSortedInput &&\n\t\tlen(pdo.StateSpecs) == 0 &&\n\t\tlen(pdo.TimerFamilySpecs) == 0 &&\n\t\tpdo.RestrictionCoderId == \"\" {\n\t\t// Which inputs are Side inputs don't change the graph further,\n\t\t// so they're not included here. Any nearly any ParDo can have them.\n\n\t\t// At their simplest, we don't need to do anything special at pre-processing time, and simply pass through as normal.\n\t\treturn &pipepb.Components{\n\t\t\tTransforms: map[string]*pipepb.PTransform{\n\t\t\t\ttid: t,\n\t\t\t},\n\t\t}, nil\n\t}\n\n\t// Side inputs add to topology and make fusion harder to deal with\n\t// (side input producers can't be in the same stage as their consumers)\n\t// But we don't have fusion yet, so no worries.\n\n\t// State, Timers, Stable Input, Time Sorted Input, and some parts of SDF\n\t// Are easier to deal including a fusion break. But We can do that with a\n\t// runner specific transform for stable input, and another for timesorted\n\t// input.\n\n\t// SplittableDoFns have 3 required phases and a 4th optional phase.\n\t//\n\t// PAIR_WITH_RESTRICTION which pairs elements with their restrictions\n\t// Input: element; := INPUT\n\t// Output: KV(element, restriction) := PWR\n\t//\n\t// SPLIT_AND_SIZE_RESTRICTIONS splits the pairs into sub element ranges\n\t// and a relative size for each, in a float64 format.\n\t// Input: KV(element, restriction) := PWR\n\t// Output: KV(KV(element, restriction), float64) := SPLITnSIZED\n\t//\n\t// PROCESS_SIZED_ELEMENTS_AND_RESTRICTIONS actually processes the\n\t// elements. This is also where splits need to be handled.\n\t// In particular, primary and residual splits have the same format as the input.\n\t// Input: KV(KV(element, restriction), size) := SPLITnSIZED\n\t// Output: DoFn's output. := OUTPUT\n\t//\n\t// TRUNCATE_SIZED_RESTRICTION is how the runner has an SDK turn an\n\t// unbounded transform into a bound one. Not needed until the pipeline\n\t// is told to drain.\n\t// Input: KV(KV(element, restriction), float64) := synthetic split results from above\n\t// Output: KV(KV(element, restriction), float64). := synthetic, truncated results sent as Split n Sized\n\t//\n\t// So with that, we can figure out the coders we need.\n\t//\n\t// cE - Element Coder (same as input coder)\n\t// cR - Restriction Coder\n\t// cS - Size Coder (float64)\n\t// ckvER - KV<Element, Restriction>\n\t// ckvERS - KV<KV<Element, Restriction>, Size>\n\t//\n\t// There could be a few output coders, but the outputs can be copied from\n\t// the original transform directly.\n\n\t// First lets get the parallel input coder ID.\n\tvar pcolInID, inputLocalID string\n\tfor localID, globalID := range t.GetInputs() {\n\t\t// The parallel input is the one that isn't a side input.\n\t\tif _, ok := pdo.SideInputs[localID]; !ok {\n\t\t\tinputLocalID = localID\n\t\t\tpcolInID = globalID\n\t\t\tbreak\n\t\t}\n\t}\n\tinputPCol := comps.GetPcollections()[pcolInID]\n\tcEID := inputPCol.GetCoderId()\n\tcRID := pdo.RestrictionCoderId\n\tcSID := \"c\" + tid + \"size\"\n\tckvERID := \"c\" + tid + \"kv_ele_rest\"\n\tckvERSID := ckvERID + \"_size\"\n\n\tcoder := func(urn string, componentIDs ...string) *pipepb.Coder {\n\t\treturn &pipepb.Coder{\n\t\t\tSpec: &pipepb.FunctionSpec{\n\t\t\t\tUrn: urn,\n\t\t\t},\n\t\t\tComponentCoderIds: componentIDs,\n\t\t}\n\t}\n\n\tcoders := map[string]*pipepb.Coder{\n\t\tckvERID: coder(urns.CoderKV, cEID, cRID),\n\t\tcSID: coder(urns.CoderDouble),\n\t\tckvERSID: coder(urns.CoderKV, ckvERID, cSID),\n\t}\n\n\t// PCollections only have two new ones.\n\t// INPUT -> same as ordinary DoFn\n\t// PWR, uses ckvER\n\t// SPLITnSIZED, uses ckvERS\n\t// OUTPUT -> same as ordinary outputs\n\n\tnPWRID := \"n\" + tid + \"_pwr\"\n\tnSPLITnSIZEDID := \"n\" + tid + \"_splitnsized\"\n\n\tpcol := func(name, coderID string) *pipepb.PCollection {\n\t\treturn &pipepb.PCollection{\n\t\t\tUniqueName: name,\n\t\t\tCoderId: coderID,\n\t\t\tIsBounded: inputPCol.GetIsBounded(),\n\t\t\tWindowingStrategyId: inputPCol.GetWindowingStrategyId(),\n\t\t}\n\t}\n\n\tpcols := map[string]*pipepb.PCollection{\n\t\tnPWRID: pcol(nPWRID, ckvERID),\n\t\tnSPLITnSIZEDID: pcol(nSPLITnSIZEDID, ckvERSID),\n\t}\n\n\t// PTransforms have 3 new ones, with process sized elements and restrictions\n\t// taking the brunt of the complexity, consuming the inputs\n\n\tePWRID := \"e\" + tid + \"_pwr\"\n\teSPLITnSIZEDID := \"e\" + tid + \"_splitnsize\"\n\teProcessID := \"e\" + tid + \"_processandsplit\"\n\n\ttform := func(name, urn, in, out string) *pipepb.PTransform {\n\t\treturn &pipepb.PTransform{\n\t\t\tUniqueName: name,\n\t\t\tSpec: &pipepb.FunctionSpec{\n\t\t\t\tUrn: urn,\n\t\t\t\tPayload: pardoPayload,\n\t\t\t},\n\t\t\tInputs: map[string]string{\n\t\t\t\tinputLocalID: in,\n\t\t\t},\n\t\t\tOutputs: map[string]string{\n\t\t\t\t\"i0\": out,\n\t\t\t},\n\t\t\tEnvironmentId: t.GetEnvironmentId(),\n\t\t}\n\t}\n\n\tnewInputs := maps.Clone(t.GetInputs())\n\tnewInputs[inputLocalID] = nSPLITnSIZEDID\n\n\ttforms := map[string]*pipepb.PTransform{\n\t\tePWRID: tform(ePWRID, urns.TransformPairWithRestriction, pcolInID, nPWRID),\n\t\teSPLITnSIZEDID: tform(eSPLITnSIZEDID, urns.TransformSplitAndSize, nPWRID, nSPLITnSIZEDID),\n\t\teProcessID: {\n\t\t\tUniqueName: eProcessID,\n\t\t\tSpec: &pipepb.FunctionSpec{\n\t\t\t\tUrn: urns.TransformProcessSizedElements,\n\t\t\t\tPayload: pardoPayload,\n\t\t\t},\n\t\t\tInputs: newInputs,\n\t\t\tOutputs: t.GetOutputs(),\n\t\t\tEnvironmentId: t.GetEnvironmentId(),\n\t\t},\n\t}\n\n\treturn &pipepb.Components{\n\t\tCoders: coders,\n\t\tPcollections: pcols,\n\t\tTransforms: tforms,\n\t}, t.GetSubtransforms()\n}", "func (t *JarAnalyser) Transform(newArtifacts []transformertypes.Artifact, oldArtifacts []transformertypes.Artifact) ([]transformertypes.PathMapping, []transformertypes.Artifact, error) {\n\tpathMappings := []transformertypes.PathMapping{}\n\tcreatedArtifacts := []transformertypes.Artifact{}\n\tfor _, a := range newArtifacts {\n\t\tvar sConfig artifacts.ServiceConfig\n\t\terr := a.GetConfig(artifacts.ServiceConfigType, &sConfig)\n\t\tif err != nil {\n\t\t\tlogrus.Errorf(\"unable to load config for Transformer into %T : %s\", sConfig, err)\n\t\t\tcontinue\n\t\t}\n\t\tsImageName := artifacts.ImageName{}\n\t\terr = a.GetConfig(artifacts.ImageNameConfigType, &sImageName)\n\t\tif err != nil {\n\t\t\tlogrus.Debugf(\"unable to load config for Transformer into %T : %s\", sImageName, err)\n\t\t}\n\t\trelSrcPath, err := filepath.Rel(t.Env.GetEnvironmentSource(), a.Paths[artifacts.ProjectPathPathType][0])\n\t\tif err != nil {\n\t\t\tlogrus.Errorf(\"Unable to convert source path %s to be relative : %s\", a.Paths[artifacts.ProjectPathPathType][0], err)\n\t\t}\n\t\tjarRunDockerfile, err := ioutil.ReadFile(filepath.Join(t.Env.GetEnvironmentContext(), t.Env.RelTemplatesDir, \"Dockerfile.embedded\"))\n\t\tif err != nil {\n\t\t\tlogrus.Errorf(\"Unable to read Dockerfile embedded template : %s\", err)\n\t\t}\n\t\tdockerfileBuildDockerfile := a.Paths[artifacts.BuildContainerFileType][0]\n\t\tbuildDockerfile, err := ioutil.ReadFile(dockerfileBuildDockerfile)\n\t\tif err != nil {\n\t\t\tlogrus.Errorf(\"Unable to read build Dockerfile template : %s\", err)\n\t\t}\n\t\ttempDir := filepath.Join(t.Env.TempPath, a.Name)\n\t\tos.MkdirAll(tempDir, common.DefaultDirectoryPermission)\n\t\tdockerfileTemplate := filepath.Join(tempDir, \"Dockerfile\")\n\t\ttemplate := string(buildDockerfile) + \"\\n\" + string(jarRunDockerfile)\n\t\terr = ioutil.WriteFile(dockerfileTemplate, []byte(template), common.DefaultFilePermission)\n\t\tif err != nil {\n\t\t\tlogrus.Errorf(\"Could not write the generated Build Dockerfile template: %s\", err)\n\t\t}\n\t\tjarArtifactConfig := artifacts.JarArtifactConfig{}\n\t\terr = a.GetConfig(artifacts.JarConfigType, &jarArtifactConfig)\n\t\tif err != nil {\n\t\t\tlogrus.Debugf(\"unable to load config for Transformer into %T : %s\", jarArtifactConfig, err)\n\t\t}\n\t\tif jarArtifactConfig.JavaVersion == \"\" {\n\t\t\tjarArtifactConfig.JavaVersion = t.JarConfig.JavaVersion\n\t\t}\n\t\tjavaPackage, err := getJavaPackage(filepath.Join(t.Env.GetEnvironmentContext(), \"mappings/javapackageversions.yaml\"), jarArtifactConfig.JavaVersion)\n\t\tif err != nil {\n\t\t\tlogrus.Errorf(\"Unable to find mapping version for java version %s : %s\", jarArtifactConfig.JavaVersion, err)\n\t\t\tjavaPackage = \"java-1.8.0-openjdk-devel\"\n\t\t}\n\t\tpathMappings = append(pathMappings, transformertypes.PathMapping{\n\t\t\tType: transformertypes.SourcePathMappingType,\n\t\t\tDestPath: common.DefaultSourceDir,\n\t\t}, transformertypes.PathMapping{\n\t\t\tType: transformertypes.TemplatePathMappingType,\n\t\t\tSrcPath: dockerfileTemplate,\n\t\t\tDestPath: filepath.Join(common.DefaultSourceDir, relSrcPath),\n\t\t\tTemplateConfig: JarDockerfileTemplate{\n\t\t\t\tJavaVersion: jarArtifactConfig.JavaVersion,\n\t\t\t\tJavaPackageName: javaPackage,\n\t\t\t\tDeploymentFile: jarArtifactConfig.DeploymentFile,\n\t\t\t\tDeploymentFileDir: jarArtifactConfig.DeploymentFileDir,\n\t\t\t\tPort: \"8080\",\n\t\t\t\tPortConfigureEnvName: \"SERVER_PORT\",\n\t\t\t\tEnvVariables: jarArtifactConfig.EnvVariables,\n\t\t\t},\n\t\t})\n\t\tpaths := a.Paths\n\t\tpaths[artifacts.DockerfilePathType] = []string{filepath.Join(common.DefaultSourceDir, relSrcPath, \"Dockerfile\")}\n\t\tp := transformertypes.Artifact{\n\t\t\tName: sImageName.ImageName,\n\t\t\tArtifact: artifacts.DockerfileArtifactType,\n\t\t\tPaths: paths,\n\t\t\tConfigs: map[string]interface{}{\n\t\t\t\tartifacts.ImageNameConfigType: sImageName,\n\t\t\t},\n\t\t}\n\t\tdfs := transformertypes.Artifact{\n\t\t\tName: sConfig.ServiceName,\n\t\t\tArtifact: artifacts.DockerfileForServiceArtifactType,\n\t\t\tPaths: a.Paths,\n\t\t\tConfigs: map[string]interface{}{\n\t\t\t\tartifacts.ImageNameConfigType: sImageName,\n\t\t\t\tartifacts.ServiceConfigType: sConfig,\n\t\t\t},\n\t\t}\n\t\tcreatedArtifacts = append(createdArtifacts, p, dfs)\n\t}\n\treturn pathMappings, createdArtifacts, nil\n}", "func Transform(eChan chan []string, tChan chan *models.Order) {\n\tfor record := range eChan {\n\t\to := new(models.Order)\n\t\to.Cpf = utils.ConvertOnlyNumber(record[0])\n\n\t\t//ValidaCPF\n\t\to.DocucmentoValido = brdoc.IsCPF(o.Cpf)\n\n\t\to.Private, _ = strconv.Atoi(record[1])\n\t\to.Incompleto, _ = strconv.Atoi(record[2])\n\t\to.DataUltimaCompra = utils.ConvertStringToDate(record[3])\n\t\to.TicketMedio, _ = strconv.ParseFloat(record[4], 64)\n\t\to.TicketUltimaCompra, _ = strconv.ParseFloat(record[5], 64)\n\t\to.LojaMaisFrequente = utils.ConvertOnlyNumber(record[6])\n\t\to.LojaUltimaCompra = utils.ConvertOnlyNumber(record[7])\n\t\ttChan <- o\n\t}\n\tclose(tChan)\n}", "func (t *Transform) Transform() *Transform {\n\treturn t\n}", "func (a *API) CreateTransformation(ctx context.Context, params CreateTransformationParams) (*TransformationResult, error) {\n\tres := &TransformationResult{}\n\t_, err := a.post(ctx, api.BuildPath(transformations), params, res)\n\n\treturn res, err\n}", "func (s *Surface) Transform(a, b, c, d, e, f float64) {\n\ts.Ctx.Call(\"transform\", a, b, c, d, e, f)\n}", "func NewTransformations(tr ...*Transformation) (trs *Transformations) {\n\tif len(tr) != 3 {\n\t\ttrs = nil\n\t} else {\n\t\ttrc := make([]Transformation, len(tr))\n\n\t\t// Make a copy of the transformations.\n\t\tfor i := range tr {\n\t\t\tif tr[i] != nil {\n\t\t\t\ttrans := tr[i]\n\t\t\t\tfunction := trans.Function()\n\t\t\t\tparams := trans.Parameters()\n\t\t\t\tntr := NewTransformation(function, params...)\n\t\t\t\ttrc[i] = ntr\n\t\t\t} else {\n\t\t\t\ttrc[i] = Transformation{}\n\t\t\t}\n\t\t}\n\n\t\ttrs = &Transformations{Tmpl: trc[0], Mtch: trc[1], Rslt: trc[2]}\n\t}\n\n\treturn trs\n}", "func makeTransformImageGraph(imageFormat string) (graph *tf.Graph, input, output tf.Output, err error) {\n\tconst (\n\t\tH, W = 224, 224\n\t\tMean = float32(117)\n\t\tScale = float32(1)\n\t)\n\ts := op.NewScope()\n\tinput = op.Placeholder(s, tf.String)\n\t// Decode PNG or JPEG\n\tvar decode tf.Output\n\tif imageFormat == \"png\" {\n\t\tdecode = op.DecodePng(s, input, op.DecodePngChannels(3))\n\t} else {\n\t\tdecode = op.DecodeJpeg(s, input, op.DecodeJpegChannels(3))\n\t}\n\t// Div and Sub perform (value-Mean)/Scale for each pixel\n\toutput = op.Div(s,\n\t\top.Sub(s,\n\t\t\t// Resize to 224x224 with bilinear interpolation\n\t\t\top.ResizeBilinear(s,\n\t\t\t\t// Create a batch containing a single image\n\t\t\t\top.ExpandDims(s,\n\t\t\t\t\t// Use decoded pixel values\n\t\t\t\t\top.Cast(s, decode, tf.Float),\n\t\t\t\t\top.Const(s.SubScope(\"make_batch\"), int32(0))),\n\t\t\t\top.Const(s.SubScope(\"size\"), []int32{H, W})),\n\t\t\top.Const(s.SubScope(\"mean\"), Mean)),\n\t\top.Const(s.SubScope(\"scale\"), Scale))\n\tgraph, err = s.Finalize()\n\treturn graph, input, output, err\n}", "func Transformation(r io.Reader) (transform.Transformation, error) {\n\tvar t transform.Transformation\n\tscanner := bufio.NewScanner(r)\n\tfor scanner.Scan() {\n\t\tname, args, err := split(scanner.Text())\n\t\tif err != nil {\n\t\t\treturn nil, err\n\t\t}\n\t\tvar nt transform.Transformation\n\t\tswitch name {\n\t\tcase \"NoTransformation\":\n\t\t\tnt, err = noTransformation(args)\n\t\tcase \"LineReflection\":\n\t\t\tnt, err = lineReflection(args)\n\t\tcase \"Translation\":\n\t\t\tnt, err = translation(args)\n\t\tcase \"Rotation\":\n\t\t\tnt, err = rotation(args)\n\t\tcase \"GlideReflection\":\n\t\t\tnt, err = glideReflection(args)\n\t\t}\n\t\tif nt == nil {\n\t\t\treturn nil, ErrBadTransformation\n\t\t}\n\t\tif err != nil {\n\t\t\treturn nil, err\n\t\t}\n\t\tt = transform.Compose(t, nt)\n\t}\n\tif scanner.Err() != nil {\n\t\treturn nil, scanner.Err()\n\t}\n\treturn t, nil\n}", "func (track *VideoTrack) Transform(fns ...video.TransformFunc) {\n\tsrc := track.Broadcaster.Source()\n\ttrack.Broadcaster.ReplaceSource(video.Merge(fns...)(src))\n}", "func CreateTransformFeedbacks(n int32, ids *uint32) {\n\tsyscall.Syscall(gpCreateTransformFeedbacks, 2, uintptr(n), uintptr(unsafe.Pointer(ids)), 0)\n}", "func TransformFeedbackVaryings(program uint32, count int32, varyings **uint8, bufferMode uint32) {\n\tC.glowTransformFeedbackVaryings(gpTransformFeedbackVaryings, (C.GLuint)(program), (C.GLsizei)(count), (**C.GLchar)(unsafe.Pointer(varyings)), (C.GLenum)(bufferMode))\n}", "func TransformFeedbackVaryings(program uint32, count int32, varyings **uint8, bufferMode uint32) {\n\tC.glowTransformFeedbackVaryings(gpTransformFeedbackVaryings, (C.GLuint)(program), (C.GLsizei)(count), (**C.GLchar)(unsafe.Pointer(varyings)), (C.GLenum)(bufferMode))\n}", "func TestBasicTransform(t *testing.T) {\n\td := Tadpole{Name: \"Kermit\", Leglets: 4, Species: \"Muppet\"}\n\n\t//define the type inline\n\tvar lApopotosis func(Tadpole) Frog\n\tCreate(&lApopotosis)\n\n\tf := lApopotosis(d) //Apopotosis is the process that transforms a tadpole to a frog\n\n\tdtype := strings.TrimSpace(reflect.TypeOf(d).String())\n\tftype := strings.TrimSpace(reflect.TypeOf(f).String())\n\n\tif dtype == ftype {\n\t\tt.Error(\"Types are the same\", ftype, dtype)\n\t}\n\tif dtype != \"mutator.Tadpole\" {\n\t\tt.Error(\"Wrong type tadpole\")\n\t}\n\tif ftype != \"mutator.Frog\" {\n\t\tt.Error(\"Wrong type frog\")\n\t}\n\tif f.Name != d.Name {\n\t\tt.Error(\"Names do not match\", f.Name, d.Name)\n\t}\n\tif f.Species != d.Species {\n\t\tt.Error(\"Species do not match\", f.Species, d.Species)\n\t}\n\tif f.Legs != d.Leglets {\n\t\tt.Error(\"Leg count does not match\", f.Legs, d.Leglets)\n\t}\n}", "func (a *Application) newTransformer(patches []*resource.Resource) (transformers.Transformer, error) {\n\tvar r []transformers.Transformer\n\tt, err := transformers.NewPatchTransformer(patches)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\tr = append(r, t)\n\tr = append(r, transformers.NewNamespaceTransformer(string(a.kustomization.Namespace)))\n\tt, err = transformers.NewDefaultingNamePrefixTransformer(string(a.kustomization.NamePrefix))\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\tr = append(r, t)\n\tt, err = transformers.NewDefaultingLabelsMapTransformer(a.kustomization.CommonLabels)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\tr = append(r, t)\n\tt, err = transformers.NewDefaultingAnnotationsMapTransformer(a.kustomization.CommonAnnotations)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\tr = append(r, t)\n\treturn transformers.NewMultiTransformer(r), nil\n}", "func TransformFeedbackBufferRange(xfb uint32, index uint32, buffer uint32, offset int, size int) {\n\tC.glowTransformFeedbackBufferRange(gpTransformFeedbackBufferRange, (C.GLuint)(xfb), (C.GLuint)(index), (C.GLuint)(buffer), (C.GLintptr)(offset), (C.GLsizeiptr)(size))\n}", "func TransformFeedbackBufferRange(xfb uint32, index uint32, buffer uint32, offset int, size int) {\n\tC.glowTransformFeedbackBufferRange(gpTransformFeedbackBufferRange, (C.GLuint)(xfb), (C.GLuint)(index), (C.GLuint)(buffer), (C.GLintptr)(offset), (C.GLsizeiptr)(size))\n}", "func (self Text) Transform() Transform {\n\tt := C.sfText_getTransform(self.Cref)\n\treturn Transform{&t}\n}", "func (track *AudioTrack) Transform(fns ...audio.TransformFunc) {\n\tsrc := track.Broadcaster.Source()\n\ttrack.Broadcaster.ReplaceSource(audio.Merge(fns...)(src))\n}", "func (self *ComponentScaleMinMax) TransformCallback() interface{}{\n return self.Object.Get(\"transformCallback\")\n}", "func transform(c *gin.Context, data interface{}) interface{} {\n\tswitch reflect.TypeOf(data) {\n\t// Multiple\n\tcase reflect.TypeOf([]*models.Event{}):\n\t\treturn TransformEvents(c, data.([]*models.Event))\n\tcase reflect.TypeOf([]*models.Ticket{}):\n\t\treturn TransformTickets(c, data.([]*models.Ticket))\n\tcase reflect.TypeOf([]*models.Question{}):\n\t\treturn TransformQuestions(c, data.([]*models.Question))\n\tcase reflect.TypeOf([]*models.Attribute{}):\n\t\treturn TransformAttributes(c, data.([]*models.Attribute))\n\n\t\t// Single\n\tcase reflect.TypeOf(&models.Event{}):\n\t\treturn TransformEvent(c, data.(*models.Event))\n\tcase reflect.TypeOf(&models.Ticket{}):\n\t\treturn TransformTicket(c, data.(*models.Ticket))\n\tcase reflect.TypeOf(&models.Question{}):\n\t\treturn TransformQuestion(c, data.(*models.Question))\n\t}\n\n\treturn data\n}", "func (ff *fftag) Create(eng vu.Eng, s *vu.State) {\n\trand.Seed(time.Now().UTC().UnixNano())\n\n\t// create the overlay\n\tff.top = eng.Root().NewPov()\n\tview := ff.top.NewView()\n\tview.SetUI()\n\tff.cam = view.Cam()\n\tff.mmap = ff.top.NewPov().SetScale(10, 10, 0)\n\tff.mmap.SetLocation(30, 30, 0)\n\n\t// populate the map\n\tff.msize = 69\n\tff.plan = grid.New(grid.ROOMS_SKIRMISH)\n\tff.plan.Generate(ff.msize, ff.msize)\n\twidth, height := ff.plan.Size()\n\tfor x := 0; x < width; x++ {\n\t\tfor y := 0; y < height; y++ {\n\t\t\tif ff.plan.IsOpen(x, y) {\n\t\t\t\tblock := ff.mmap.NewPov()\n\t\t\t\tblock.SetLocation(float64(x), float64(y), 0)\n\t\t\t\tblock.NewModel(\"uv\").LoadMesh(\"icon\").AddTex(\"wall\")\n\t\t\t\tff.spots = append(ff.spots, ff.id(x, y))\n\t\t\t}\n\t\t}\n\t}\n\n\t// populate chasers and a goal.\n\tnumChasers := 30\n\tfor cnt := 0; cnt < numChasers; cnt++ {\n\t\tchaser := ff.mmap.NewPov()\n\t\tchaser.NewModel(\"uv\").LoadMesh(\"icon\").AddTex(\"token\")\n\t\tff.chasers = append(ff.chasers, chaser)\n\t}\n\tff.goal = ff.mmap.NewPov()\n\tff.goal.NewModel(\"uv\").LoadMesh(\"icon\").AddTex(\"goal\")\n\tff.flow = grid.NewFlow(ff.plan) // flow field for the given plan.\n\tff.resetLocations()\n\n\t// set non default engine state.\n\teng.SetColor(0.15, 0.15, 0.15, 1)\n\tff.resize(s.W, s.H)\n}", "func Transform(image io.Reader, extension string, numberOfShapes int, opts ...func() []string) (io.Reader, error) {\n\tvar args []string\n\n\tfor _, opt := range opts {\n\t\targs = append(args, opt()...)\n\t}\n\n\tinputTempFile, err := createTempFile(\"input_\", extension)\n\n\tif err != nil {\n\t\treturn nil, fmt.Errorf(\"primitive: failed to create temp input file:: %v\", err)\n\t}\n\n\toutputTempFile, err := createTempFile(\"output_\", extension)\n\n\tif err != nil {\n\t\treturn nil, fmt.Errorf(\"primitive: failed to create temp output file:: %v\", err)\n\t}\n\n\t// Read image\n\t_, err = io.Copy(inputTempFile, image)\n\n\tif err != nil {\n\t\treturn nil, fmt.Errorf(\"primitive: failed to copy temp input file:: %v\", err)\n\t}\n\n\t// Run primitive\n\tstdCombo, err := primitive(inputTempFile.Name(), outputTempFile.Name(), numberOfShapes, args...)\n\n\tif err != nil {\n\t\treturn nil, fmt.Errorf(\"primitive: failed to run the primitive command: %v, std combo: %s\", err, stdCombo)\n\t}\n\t// Read out into a reader, return reader and delete out\n\tb := bytes.NewBuffer(nil)\n\n\t_, err = io.Copy(b, outputTempFile)\n\n\tif err != nil {\n\t\treturn nil, fmt.Errorf(\"primitive: failed to copy temp output file:: %v\", err)\n\t}\n\n\treturn b, nil\n}", "func Transform() TRANSFORM {\n\treturn TRANSFORM{\n\t\ttags: []ONETRANSFORM{},\n\t}\n}", "func (s *Stream) Transform(op api.UnOperation) *Stream {\n\toperator := unary.New(s.ctx)\n\toperator.SetOperation(op)\n\ts.ops = append(s.ops, operator)\n\treturn s\n}", "func CreateTransform(lowerLeft, upperRight *Point, width, height int,\n\tgd *GridDef) *PointTransform {\n\tworldNx := math.Abs(lowerLeft.X() - upperRight.X())\n\tworldNy := math.Abs(lowerLeft.Y() - upperRight.Y())\n\tdx := worldNx / float64(width)\n\tdy := worldNy / float64(height)\n\tmaxx := math.Max(lowerLeft.X(), upperRight.X())\n\tmaxy := math.Max(lowerLeft.Y(), upperRight.Y())\n\tmax := NewPoint2D(maxx, maxy)\n\treturn &PointTransform{dx, dy, max, width, height, gd}\n}", "func NewTransformer() *Transformer {\n\treturn &Transformer{\n\t\tprevReqs: NewPrevReqPool(5),\n\t}\n}", "func (c *Patch) applyTransforms(input interface{}) (interface{}, error) {\n\tvar err error\n\tfor i, t := range c.Transforms {\n\t\tif input, err = t.Transform(input); err != nil {\n\t\t\treturn nil, errors.Wrapf(err, errFmtTransformAtIndex, i)\n\t\t}\n\t}\n\treturn input, nil\n}", "func NewTransform() *Transform {\n\treturn transformPool.Get().(*Transform)\n}", "func (CreateMultisigDataResource) Transform(txData interface{}, context *state.CheckState) TxDataResource {\n\tdata := txData.(*transaction.CreateMultisigData)\n\n\tvar weights []string\n\tfor _, weight := range data.Weights {\n\t\tweights = append(weights, strconv.Itoa(int(weight)))\n\t}\n\n\treturn CreateMultisigDataResource{\n\t\tThreshold: strconv.Itoa(int(data.Threshold)),\n\t\tWeights: weights,\n\t\tAddresses: data.Addresses,\n\t}\n}", "func MakeTransformFeedbackObject() TransformFeedbackObject {\n\tvar tfb uint32\n\tgl.GenTransformFeedbacks(1, &tfb)\n\treturn TransformFeedbackObject(tfb)\n}", "func fnTransform(ctx Context, doc *JDoc, params []string) interface{} {\n\tstats := ctx.Value(EelTotalStats).(*ServiceStats)\n\tif params == nil || len(params) == 0 || len(params) > 4 {\n\t\tctx.Log().Error(\"error_type\", \"func_transform\", \"op\", \"transform\", \"cause\", \"wrong_number_of_parameters\", \"params\", params)\n\t\tstats.IncErrors()\n\t\tAddError(ctx, SyntaxError{fmt.Sprintf(\"wrong number of parameters in call to transform function\"), \"transform\", params})\n\t\treturn nil\n\t}\n\th := GetCurrentHandlerConfig(ctx)\n\tif h == nil {\n\t\tctx.Log().Error(\"error_type\", \"func_transform\", \"op\", \"transform\", \"cause\", \"no_handler\", \"params\", params)\n\t\tstats.IncErrors()\n\t\tAddError(ctx, RuntimeError{fmt.Sprintf(\"current handler not found in call to transform function\"), \"transform\", params})\n\t\treturn nil\n\t}\n\tif h.Transformations == nil {\n\t\tctx.Log().Error(\"error_type\", \"func_transform\", \"op\", \"transform\", \"cause\", \"no_named_transformations\", \"params\", params)\n\t\tstats.IncErrors()\n\t\tAddError(ctx, RuntimeError{fmt.Sprintf(\"no named transformations found in call to transform function\"), \"transform\", params})\n\t\treturn nil\n\t}\n\tt := h.Transformations[extractStringParam(params[0])]\n\tif t == nil {\n\t\tctx.Log().Error(\"error_type\", \"func_transform\", \"op\", \"transform\", \"cause\", \"unknown_transformation\", \"params\", params)\n\t\tstats.IncErrors()\n\t\tAddError(ctx, RuntimeError{fmt.Sprintf(\"no named transformation %s found in call to transform function\", extractStringParam(params[0])), \"transform\", params})\n\t\treturn nil\n\t}\n\tvar section interface{}\n\tsection = doc.GetOriginalObject()\n\tif len(params) >= 2 {\n\t\terr := json.Unmarshal([]byte(extractStringParam(params[1])), &section)\n\t\tif err != nil {\n\t\t\tctx.Log().Error(\"error_type\", \"func_transform\", \"op\", \"transform\", \"cause\", \"invalid_json\", \"params\", params, \"error\", err.Error())\n\t\t\tstats.IncErrors()\n\t\t\tAddError(ctx, SyntaxError{fmt.Sprintf(\"non json parameters in call to transform function\"), \"transform\", params})\n\t\t\treturn nil\n\t\t}\n\t}\n\tvar pattern *JDoc\n\tif len(params) >= 3 && extractStringParam(params[2]) != \"\" {\n\t\tvar err error\n\t\tpattern, err = NewJDocFromString(extractStringParam(params[2]))\n\t\tif err != nil {\n\t\t\tctx.Log().Error(\"error_type\", \"func_transform\", \"op\", \"transform\", \"cause\", \"non_json_parameter\", \"params\", params, \"error\", err.Error())\n\t\t\tstats.IncErrors()\n\t\t\tAddError(ctx, SyntaxError{fmt.Sprintf(\"non json parameters in call to transform function\"), \"transform\", params})\n\t\t\treturn nil\n\t\t}\n\t}\n\tvar join *JDoc\n\tif len(params) == 4 && extractStringParam(params[3]) != \"\" {\n\t\tvar err error\n\t\tjoin, err = NewJDocFromString(extractStringParam(params[3]))\n\t\tif err != nil {\n\t\t\tctx.Log().Error(\"error_type\", \"func_transform\", \"op\", \"transform\", \"cause\", \"non_json_parameter\", \"params\", params, \"error\", err.Error())\n\t\t\tstats.IncErrors()\n\t\t\tAddError(ctx, SyntaxError{fmt.Sprintf(\"non json parameters in call to transform function\"), \"transform\", params})\n\t\t\treturn nil\n\t\t}\n\t}\n\tif pattern != nil {\n\t\tc, _ := doc.contains(section, pattern.GetOriginalObject(), 0)\n\t\tif !c {\n\t\t\treturn section\n\t\t}\n\t}\n\tif join != nil {\n\t\tsection = doc.merge(join.GetOriginalObject(), section)\n\t}\n\tlittleDoc, err := NewJDocFromInterface(section)\n\tif err != nil {\n\t\tctx.Log().Error(\"error_type\", \"func_transform\", \"cause\", \"json_parse_error\", \"op\", \"transform\", \"error\", err.Error(), \"params\", params)\n\t\tstats.IncErrors()\n\t\tAddError(ctx, RuntimeError{fmt.Sprintf(\"transformation error in call to transform function\"), \"transform\", params})\n\t\treturn nil\n\t}\n\tvar littleRes *JDoc\n\tif t.IsTransformationByExample {\n\t\tlittleRes = littleDoc.ApplyTransformationByExample(ctx, t.t)\n\t} else {\n\t\tlittleRes = littleDoc.ApplyTransformation(ctx, t.t)\n\t}\n\treturn littleRes.GetOriginalObject()\n}", "func (t *GolangDockerfileGenerator) Transform(newArtifacts []transformertypes.Artifact, oldArtifacts []transformertypes.Artifact) ([]transformertypes.PathMapping, []transformertypes.Artifact, error) {\n\tpathMappings := []transformertypes.PathMapping{}\n\tartifactsCreated := []transformertypes.Artifact{}\n\tfor _, a := range newArtifacts {\n\t\tif a.Artifact != artifacts.ServiceArtifactType {\n\t\t\tcontinue\n\t\t}\n\t\trelSrcPath, err := filepath.Rel(t.Env.GetEnvironmentSource(), a.Paths[artifacts.ProjectPathPathType][0])\n\t\tif err != nil {\n\t\t\tlogrus.Errorf(\"Unable to convert source path %s to be relative : %s\", a.Paths[artifacts.ProjectPathPathType][0], err)\n\t\t}\n\t\tvar sConfig artifacts.ServiceConfig\n\t\terr = a.GetConfig(artifacts.ServiceConfigType, &sConfig)\n\t\tif err != nil {\n\t\t\tlogrus.Errorf(\"unable to load config for Transformer into %T : %s\", sConfig, err)\n\t\t\tcontinue\n\t\t}\n\t\tsImageName := artifacts.ImageName{}\n\t\terr = a.GetConfig(artifacts.ImageNameConfigType, &sImageName)\n\t\tif err != nil {\n\t\t\tlogrus.Debugf(\"unable to load config for Transformer into %T : %s\", sImageName, err)\n\t\t}\n\t\tdata, err := ioutil.ReadFile(a.Paths[GolangModFilePathType][0])\n\t\tif err != nil {\n\t\t\tlogrus.Errorf(\"Error while reading the go.mod file : %s\", err)\n\t\t\treturn nil, nil, nil\n\t\t}\n\t\tmodFile, err := modfile.Parse(a.Paths[GolangModFilePathType][0], data, nil)\n\t\tif err != nil {\n\t\t\tlogrus.Errorf(\"Error while parsing the go.mod file : %s\", err)\n\t\t\treturn nil, nil, nil\n\t\t}\n\t\tif modFile.Go == nil {\n\t\t\tlogrus.Debugf(\"Didn't find the Go version in the go.mod file at path %s, selecting Go version %s\", a.Paths[GolangModFilePathType][0], t.GolangConfig.DefaultGoVersion)\n\t\t\tmodFile.Go.Version = t.GolangConfig.DefaultGoVersion\n\t\t}\n\t\tvar detectedPorts []int32\n\t\tdetectedPorts = append(detectedPorts, 8080) //TODO: Write parser to parse and identify port\n\t\tdetectedPorts = commonqa.GetPortsForService(detectedPorts, a.Name)\n\t\tvar golangConfig GolangTemplateConfig\n\t\tgolangConfig.AppName = a.Name\n\t\tgolangConfig.Ports = detectedPorts\n\t\tgolangConfig.GoVersion = modFile.Go.Version\n\n\t\tif sImageName.ImageName == \"\" {\n\t\t\tsImageName.ImageName = common.MakeStringContainerImageNameCompliant(sConfig.ServiceName)\n\t\t}\n\t\tpathMappings = append(pathMappings, transformertypes.PathMapping{\n\t\t\tType: transformertypes.SourcePathMappingType,\n\t\t\tDestPath: common.DefaultSourceDir,\n\t\t}, transformertypes.PathMapping{\n\t\t\tType: transformertypes.TemplatePathMappingType,\n\t\t\tSrcPath: filepath.Join(t.Env.Context, t.Config.Spec.TemplatesDir),\n\t\t\tDestPath: filepath.Join(common.DefaultSourceDir, relSrcPath),\n\t\t\tTemplateConfig: golangConfig,\n\t\t})\n\t\tpaths := a.Paths\n\t\tpaths[artifacts.DockerfilePathType] = []string{filepath.Join(common.DefaultSourceDir, relSrcPath, \"Dockerfile\")}\n\t\tp := transformertypes.Artifact{\n\t\t\tName: sImageName.ImageName,\n\t\t\tArtifact: artifacts.DockerfileArtifactType,\n\t\t\tPaths: paths,\n\t\t\tConfigs: map[string]interface{}{\n\t\t\t\tartifacts.ImageNameConfigType: sImageName,\n\t\t\t},\n\t\t}\n\t\tdfs := transformertypes.Artifact{\n\t\t\tName: sConfig.ServiceName,\n\t\t\tArtifact: artifacts.DockerfileForServiceArtifactType,\n\t\t\tPaths: a.Paths,\n\t\t\tConfigs: map[string]interface{}{\n\t\t\t\tartifacts.ImageNameConfigType: sImageName,\n\t\t\t\tartifacts.ServiceConfigType: sConfig,\n\t\t\t},\n\t\t}\n\t\tartifactsCreated = append(artifactsCreated, p, dfs)\n\t}\n\treturn pathMappings, artifactsCreated, nil\n}", "func (*Transformations) Descriptor() ([]byte, []int) {\n\treturn file_github_com_solo_io_gloo_projects_gloo_api_v1_options_transformation_transformation_proto_rawDescGZIP(), []int{2}\n}", "func New() *Transformer {\n\treturn &Transformer{}\n}", "func (coll *FeatureCollection) Transform(t Transformer) {\n\tfor _, feat := range *coll {\n\t\tfeat.Transform(t)\n\t}\n}", "func (c *Curl) transform() {\n\tvar tmp [StateSize]int8\n\ttransform(&tmp, &c.state, uint(c.rounds))\n\t// for odd number of rounds we need to copy the buffer into the state\n\tif c.rounds%2 != 0 {\n\t\tcopy(c.state[:], tmp[:])\n\t}\n}", "func TransformFeedbackVaryings(program uint32, count int32, varyings **int8, bufferMode uint32) {\n C.glowTransformFeedbackVaryings(gpTransformFeedbackVaryings, (C.GLuint)(program), (C.GLsizei)(count), (**C.GLchar)(unsafe.Pointer(varyings)), (C.GLenum)(bufferMode))\n}", "func (v *Vectorizer) FitTranform() *FeatureMatrix {\n\n}", "func setupTransformableItems(c *cli.Context,\n\tctxOpts *terrahelp.TransformOpts,\n\tnoBackup bool, bkpExt string) {\n\tfiles := c.StringSlice(\"file\")\n\n\tif files == nil || len(files) == 0 {\n\t\tctxOpts.TransformItems = []terrahelp.Transformable{terrahelp.NewStdStreamTransformable()}\n\t\treturn\n\t}\n\tctxOpts.TransformItems = []terrahelp.Transformable{}\n\tfor _, f := range files {\n\t\tctxOpts.TransformItems = append(ctxOpts.TransformItems,\n\t\t\tterrahelp.NewFileTransformable(f, !noBackup, bkpExt))\n\t}\n}", "func (app *Configurable) Transform(parameters map[string]string) interfaces.AppFunction {\n\ttransformType, ok := parameters[TransformType]\n\tif !ok {\n\t\tapp.lc.Errorf(\"Could not find '%s' parameter for Transform\", TransformType)\n\t\treturn nil\n\t}\n\n\ttransform := transforms.Conversion{}\n\n\tswitch strings.ToLower(transformType) {\n\tcase TransformXml:\n\t\treturn transform.TransformToXML\n\tcase TransformJson:\n\t\treturn transform.TransformToJSON\n\tdefault:\n\t\tapp.lc.Errorf(\n\t\t\t\"Invalid transform type '%s'. Must be '%s' or '%s'\",\n\t\t\ttransformType,\n\t\t\tTransformXml,\n\t\t\tTransformJson)\n\t\treturn nil\n\t}\n}", "func (complexShaperThai) preprocessText(plan *otShapePlan, buffer *Buffer, font *Font) {\n\t/* The following is NOT specified in the MS OT Thai spec, however, it seems\n\t* to be what Uniscribe and other engines implement. According to Eric Muller:\n\t*\n\t* When you have a SARA AM, decompose it in NIKHAHIT + SARA AA, *and* move the\n\t* NIKHAHIT backwards over any tone mark (0E48-0E4B).\n\t*\n\t* <0E14, 0E4B, 0E33> . <0E14, 0E4D, 0E4B, 0E32>\n\t*\n\t* This reordering is legit only when the NIKHAHIT comes from a SARA AM, not\n\t* when it's there to start with. The string <0E14, 0E4B, 0E4D> is probably\n\t* not what a user wanted, but the rendering is nevertheless nikhahit above\n\t* chattawa.\n\t*\n\t* Same for Lao.\n\t*\n\t* Note:\n\t*\n\t* Uniscribe also does some below-marks reordering. Namely, it positions U+0E3A\n\t* after U+0E38 and U+0E39. We do that by modifying the ccc for U+0E3A.\n\t* See unicode.modified_combining_class (). Lao does NOT have a U+0E3A\n\t* equivalent.\n\t */\n\n\t/*\n\t* Here are the characters of significance:\n\t*\n\t*\t\t\tThai\tLao\n\t* SARA AM:\t\tU+0E33\tU+0EB3\n\t* SARA AA:\t\tU+0E32\tU+0EB2\n\t* Nikhahit:\t\tU+0E4D\tU+0ECD\n\t*\n\t* Testing shows that Uniscribe reorder the following marks:\n\t* Thai:\t<0E31,0E34..0E37,0E47..0E4E>\n\t* Lao:\t<0EB1,0EB4..0EB7,0EC7..0ECE>\n\t*\n\t* Note how the Lao versions are the same as Thai + 0x80.\n\t */\n\n\tbuffer.clearOutput()\n\tcount := len(buffer.Info)\n\tfor buffer.idx = 0; buffer.idx < count; {\n\t\tu := buffer.cur(0).codepoint\n\t\tif !isSaraAm(u) {\n\t\t\tbuffer.nextGlyph()\n\t\t\tcontinue\n\t\t}\n\n\t\t/* Is SARA AM. Decompose and reorder. */\n\t\tbuffer.outputRune(nikhahitFromSaraAm(u))\n\t\tbuffer.prev().setContinuation()\n\t\tbuffer.replaceGlyph(saraAaFromSaraAm(u))\n\n\t\t/* Make Nikhahit be recognized as a ccc=0 mark when zeroing widths. */\n\t\tend := len(buffer.outInfo)\n\t\tbuffer.outInfo[end-2].setGeneralCategory(nonSpacingMark)\n\n\t\t/* Ok, let's see... */\n\t\tstart := end - 2\n\t\tfor start > 0 && isToneMark(buffer.outInfo[start-1].codepoint) {\n\t\t\tstart--\n\t\t}\n\n\t\tif start+2 < end {\n\t\t\t/* Move Nikhahit (end-2) to the beginning */\n\t\t\tbuffer.mergeOutClusters(start, end)\n\t\t\tt := buffer.outInfo[end-2]\n\t\t\tcopy(buffer.outInfo[start+1:], buffer.outInfo[start:end-2])\n\t\t\tbuffer.outInfo[start] = t\n\t\t} else {\n\t\t\t/* Since we decomposed, and NIKHAHIT is combining, merge clusters with the\n\t\t\t* previous cluster. */\n\t\t\tif start != 0 && buffer.ClusterLevel == MonotoneGraphemes {\n\t\t\t\tbuffer.mergeOutClusters(start-1, end)\n\t\t\t}\n\t\t}\n\t}\n\tbuffer.swapBuffers()\n\n\t/* If font has Thai GSUB, we are done. */\n\tif plan.props.Script == language.Thai && !plan.map_.foundScript[0] {\n\t\tdoThaiPuaShaping(buffer, font)\n\t}\n}", "func MakeTransformFor(archiveID int64, transform transforms.RequestTransform) (*Transform, error) {\n\t// e.g. 'ConstantTransform' or 'HeaderInjectionTransform'\n\ttransformType := strings.Split(reflect.TypeOf(transform).String(), \".\")[1]\n\tmarshaled, err := json.MarshalIndent(transform, \"\", \" \")\n\treturn &Transform{\n\t\tArchiveID: archiveID,\n\t\tMarshaledJSON: string(marshaled),\n\t\tType: transformType,\n\t}, err\n}", "func noTransformation(xs []string) (transform.Transformation, error) {\n\tif len(xs) != 0 {\n\t\treturn nil, ErrBadTransformation\n\t}\n\treturn transform.NoTransformation(), nil\n}", "func NewTransformation(ctx *pulumi.Context,\n\tname string, args *TransformationArgs, opts ...pulumi.ResourceOption) (*Transformation, error) {\n\tif args == nil {\n\t\treturn nil, errors.New(\"missing one or more required arguments\")\n\t}\n\n\tif args.Path == nil {\n\t\treturn nil, errors.New(\"invalid value for required argument 'Path'\")\n\t}\n\tvar resource Transformation\n\terr := ctx.RegisterResource(\"vault:transform/transformation:Transformation\", name, args, &resource, opts...)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\treturn &resource, nil\n}", "func (t *Tuple) Transform(transformations ...Matrix) *Tuple {\n\n\tif len(transformations) < 1 {\n\t\treturn t\n\t}\n\n\tcurrent := transformations[0]\n\n\tfor i := 1; i < len(transformations); i++ {\n\t\tcurrent = transformations[i].MulMatrix(current)\n\t}\n\n\treturn current.MulTuple(t)\n\n}", "func Transform(imgFile io.Reader, extension string, numberOfShapes int, mode PrimitiveMode) (io.Reader, error) {\n\n\t// Create temp input file.\n\tinputName := \"tempinput\" + extension\n\ti, err := os.Create(inputName)\n\tif err != nil {\n\t\treturn nil, fmt.Errorf(\"primitive.Transform: cannot create temp input - %v\", err)\n\t}\n\n\t// Remember defer is a stack so close needs to happen before remove.\n\tdefer os.Remove(inputName)\n\tdefer i.Close()\n\n\t// Write imgFile into a tempfile.\n\t_, err = io.Copy(i, imgFile)\n\tif err != nil {\n\t\treturn nil, fmt.Errorf(\"primitive.Transform: cannot populate input file - %v\", err)\n\t}\n\n\toutputName := \"tempoutput\" + extension\n\n\trunOutput, err := primCLI(inputName, outputName, numberOfShapes, mode)\n\tif err != nil {\n\t\treturn nil, fmt.Errorf(\"primitive.Transform: error running primitive command - %v\\nOutput: %s\", err, runOutput)\n\t}\n\n\t// Open output file.\n\to, err := os.Open(outputName)\n\tif err != nil {\n\t\treturn nil, fmt.Errorf(\"primitive.Transform: cannot open output file - %v\", err)\n\t}\n\n\t// Read all of outputName to a buffer, create a reader and send it out.\n\tb, err := ioutil.ReadAll(o)\n\tif err != nil {\n\t\treturn nil, fmt.Errorf(\"primitive.Transform: cannot read output file - %v\", err)\n\t}\n\tdefer os.Remove(outputName)\n\tdefer o.Close()\n\n\t// Otherwise the files will not be deleted.\n\tr := bytes.NewReader(b)\n\n\treturn r, nil\n}", "func (*Transformation) Descriptor() ([]byte, []int) {\n\treturn file_github_com_solo_io_gloo_projects_gloo_api_v1_options_transformation_transformation_proto_rawDescGZIP(), []int{5}\n}", "func (mock *ProcessorPipelineMock) TransformCalls() []struct {\n\tIn1 image.Image\n} {\n\tvar calls []struct {\n\t\tIn1 image.Image\n\t}\n\tlockProcessorPipelineMockTransform.RLock()\n\tcalls = mock.calls.Transform\n\tlockProcessorPipelineMockTransform.RUnlock()\n\treturn calls\n}", "func TestSimplestTransform(t *testing.T) {\n\tassert := assert.New(t)\n\tmessage := map[string]interface{}{\n\t\t\"a\": \"b\",\n\t}\n\ttransform := map[string]interface{}{\n\t\t\"x\": \"y\",\n\t}\n\ttransformErr := Transform(&message, transform)\n\tassert.Nil(transformErr)\n\tassert.Equal(message[\"a\"], \"b\")\n\tassert.NotNil(message[\"x\"])\n\tassert.Equal(message[\"x\"], \"y\")\n}", "func (g *Graph) Transform(f func(interface{}) ([]Event, error)) {\n\tg.transform = f\n}", "func NewTransformable() *Transformable {\n\ttransformable := &Transformable{C.sfTransformable_create()}\n\truntime.SetFinalizer(transformable, (*Transformable).destroy)\n\n\treturn transformable\n}", "func (canvas *Canvas) Transform(a, b, c, d, e, f float32) {\n\twriteCommand(canvas.contents, \"cm\", a, b, c, d, e, f)\n}", "func pipelineTransform(arg *interface{}, container **[]interface{}) {\n\tswitch value := (*arg).(type) {\n\tcase []interface{}:\n\t\t*container = &value\n\tcase interface{}:\n\t\t*container = &[]interface{}{value}\n\tdefault:\n\t\t**container = nil\n\t}\n}", "func Transform(m string, d R) string {\n\tcleanLines := regexp.MustCompile(\"[\\\\n\\\\r\\\\t]+\")\n\t//KLUDGE: Salsa wants to see supporter.supporter_KEY/supporter.Email\n\t// in the conditions and included fields. However, the data is stored\n\t// simply as \"supporter_KEY\" or \"Email\"...\n\ti := strings.Index(m, \".\")\n\tif i != -1 {\n\t\tm = strings.Split(m, \".\")[1]\n\t}\n\ts, ok := d[m]\n\tif !ok {\n\t\ts = \"\"\n\t}\n\t//Transform fields as needed. This includes making pretty dates,\n\t//setting the Engage transaction type and putting Engage text into\n\t//Receive_Email.\n\tswitch m {\n\tcase \"Contact_Date\":\n\t\ts = godig.EngageDate(s)\n\tcase \"Contact_Due_Date\":\n\t\ts = godig.EngageDate(s)\n\tcase \"Date_Created\":\n\t\ts = godig.EngageDate(s)\n\tcase \"Email\":\n\t\ts = strings.TrimSpace(strings.ToLower(s))\n\tcase \"End\":\n\t\ts = godig.EngageDate(s)\n\tcase \"First_Email_Time\":\n\t\ts = godig.EngageDate(s)\n\tcase \"last_click\":\n\t\ts = godig.EngageDate(s)\n\tcase \"Last_Email_Time\":\n\t\ts = godig.EngageDate(s)\n\tcase \"Last_Modified\":\n\t\ts = godig.EngageDate(s)\n\tcase \"last_open\":\n\t\ts = godig.EngageDate(s)\n\tcase \"Receive_Email\":\n\t\tt := \"Unsubscribed\"\n\t\tx, err := strconv.ParseInt(s, 10, 32)\n\t\tif err == nil && x > 0 {\n\t\t\tt = \"Subscribed\"\n\t\t}\n\t\ts = t\n\tcase \"Start\":\n\t\ts = godig.EngageDate(s)\n\tcase \"State\":\n\t\ts = strings.ToUpper(s)\n\tcase \"Transaction_Date\":\n\t\ts = godig.EngageDate(s)\n\tcase \"Transaction_Type\":\n\t\tif s != \"Recurring\" {\n\t\t\ts = \"OneTime\"\n\t\t}\n\t}\n\t// Convert tabs to spaces. Remove leading/trailing spaces.\n\t// Remove any quotation marks.\n\t// Append the cleaned-up value to the output.\n\ts = strings.Replace(s, \"\\\"\", \"\", -1)\n\ts = cleanLines.ReplaceAllString(s, \" \")\n\ts = strings.TrimSpace(s)\n\treturn s\n}", "func Transform(ctx context.Context, parallelism int, bufferSize int, in chan OutResult,\n\ttransformer func(interface{}) (interface{}, error), errhandler func(error),\n) chan InOutResult {\n\t// TODO: can we have a channel factory to do this?\n\toutChan := make(chan InOutResult, bufferSize)\n\tvar wg sync.WaitGroup\n\tif parallelism < 1 {\n\t\tparallelism = 1\n\t}\n\twg.Add(parallelism)\n\ti := func() {\n\t\tdefer wg.Done()\n\t\tfor {\n\t\t\tselect {\n\t\t\tcase <-ctx.Done():\n\t\t\t\tout := simpleInOut{\n\t\t\t\t\tsimpleOut: simpleOut{err: ctx.Err()},\n\t\t\t\t}\n\t\t\t\tselect {\n\t\t\t\tcase outChan <- out:\n\t\t\t\tdefault:\n\t\t\t\t\treturn\n\t\t\t\t}\n\t\t\tcase sr, ok := <-in:\n\t\t\t\t// do stuff, write to out maybe\n\t\t\t\tif !ok {\n\t\t\t\t\t// channel is closed, time to exit\n\t\t\t\t\treturn\n\t\t\t\t}\n\t\t\t\tif sr.Err() != nil {\n\t\t\t\t\tif errhandler != nil {\n\t\t\t\t\t\terrhandler(sr.Err())\n\t\t\t\t\t}\n\t\t\t\t\tcontinue\n\t\t\t\t}\n\t\t\t\tres, err := transformer(sr.Output())\n\t\t\t\tif err == ErrSkip {\n\t\t\t\t\tcontinue\n\t\t\t\t}\n\t\t\t\tout := simpleInOut{\n\t\t\t\t\tsimpleOut: simpleOut{err: err, out: res},\n\t\t\t\t\tin: sr.Output(),\n\t\t\t\t}\n\t\t\t\t// TODO: this section will never cancel if this write blocks. Problem?\n\t\t\t\toutChan <- out\n\t\t\t}\n\t\t}\n\t}\n\tfor x := 0; x < parallelism; x++ {\n\t\tgo i()\n\t}\n\tgo func() {\n\t\twg.Wait()\n\t\tclose(outChan)\n\t}()\n\treturn outChan\n}", "func T(obj SDF3, x, y, z float64) SDF3 {\n\tm := Translate3d(V3{X: x, Y: y, Z: z})\n\treturn Transform3D(obj, m)\n}", "func NewTransformer() Transformer {\n\treturn &execFigletTransformer{}\n}", "func fnITransform(ctx Context, doc *JDoc, params []string) interface{} {\n\tstats := ctx.Value(EelTotalStats).(*ServiceStats)\n\tif params == nil || len(params) == 0 || len(params) > 4 {\n\t\tctx.Log().Error(\"error_type\", \"func_itransform\", \"op\", \"itransform\", \"cause\", \"wrong_number_of_parameters\", \"params\", params)\n\t\tstats.IncErrors()\n\t\tAddError(ctx, SyntaxError{fmt.Sprintf(\"wrong number of parameters in call to itransform function\"), \"itransform\", params})\n\t\treturn nil\n\t}\n\th := GetCurrentHandlerConfig(ctx)\n\tif h == nil {\n\t\tctx.Log().Error(\"error_type\", \"func_itransform\", \"op\", \"itransform\", \"cause\", \"no_handler\", \"params\", params)\n\t\tstats.IncErrors()\n\t\tAddError(ctx, RuntimeError{fmt.Sprintf(\"current handler not found in call to itransform function\"), \"itransform\", params})\n\t\treturn nil\n\t}\n\tif h.Transformations == nil {\n\t\tctx.Log().Error(\"error_type\", \"func_itransform\", \"op\", \"itransform\", \"cause\", \"no_named_transformations\", \"params\", params)\n\t\tstats.IncErrors()\n\t\tAddError(ctx, RuntimeError{fmt.Sprintf(\"no named transformations found in call to itransform function\"), \"itransform\", params})\n\t\treturn nil\n\t}\n\tt := h.Transformations[extractStringParam(params[0])]\n\tif t == nil {\n\t\tctx.Log().Error(\"error_type\", \"func_itransform\", \"op\", \"itransform\", \"cause\", \"unknown_transformation\", \"params\", params)\n\t\tstats.IncErrors()\n\t\tAddError(ctx, RuntimeError{fmt.Sprintf(\"no named transformation %s found in call to itransform function\", extractStringParam(params[0])), \"itransform\", params})\n\t\treturn nil\n\t}\n\tvar section interface{}\n\tsection = doc.GetOriginalObject()\n\tif len(params) >= 2 {\n\t\terr := json.Unmarshal([]byte(extractStringParam(params[1])), &section)\n\t\tif err != nil {\n\t\t\tctx.Log().Error(\"error_type\", \"func_itransform\", \"op\", \"itransform\", \"cause\", \"invalid_json\", \"params\", params, \"error\", err.Error())\n\t\t\tstats.IncErrors()\n\t\t\tAddError(ctx, SyntaxError{fmt.Sprintf(\"non json parameters in call to itransform function\"), \"itransform\", params})\n\t\t\treturn nil\n\t\t}\n\t}\n\tvar pattern *JDoc\n\tif len(params) >= 3 && extractStringParam(params[2]) != \"\" {\n\t\tvar err error\n\t\tpattern, err = NewJDocFromString(extractStringParam(params[2]))\n\t\tif err != nil {\n\t\t\tctx.Log().Error(\"error_type\", \"func_itransform\", \"op\", \"itransform\", \"cause\", \"non_json_parameter\", \"params\", params, \"error\", err.Error())\n\t\t\tstats.IncErrors()\n\t\t\tAddError(ctx, SyntaxError{fmt.Sprintf(\"non json parameters in call to itransform function\"), \"itransform\", params})\n\t\t\treturn nil\n\t\t}\n\t}\n\tvar join *JDoc\n\tif len(params) == 4 && extractStringParam(params[3]) != \"\" {\n\t\tvar err error\n\t\tjoin, err = NewJDocFromString(extractStringParam(params[3]))\n\t\tif err != nil {\n\t\t\tctx.Log().Error(\"error_type\", \"func_itransform\", \"op\", \"itransform\", \"cause\", \"non_json_parameter\", \"params\", params, \"error\", err.Error())\n\t\t\tstats.IncErrors()\n\t\t\tAddError(ctx, SyntaxError{fmt.Sprintf(\"non json parameters in call to itransform function\"), \"itransform\", params})\n\t\t\treturn nil\n\t\t}\n\t}\n\tswitch section.(type) {\n\t// apply sub-transformation iteratively to all array elements\n\tcase []interface{}:\n\t\tfor i, a := range section.([]interface{}) {\n\t\t\tif pattern != nil {\n\t\t\t\tc, _ := doc.contains(a, pattern.GetOriginalObject(), 0)\n\t\t\t\tif !c {\n\t\t\t\t\tcontinue\n\t\t\t\t}\n\t\t\t}\n\t\t\tif join != nil {\n\t\t\t\ta = doc.merge(join.GetOriginalObject(), a)\n\t\t\t}\n\t\t\t//ctx.Log().Info(\"A\", a, \"MERGED\", amerged, \"JOIN\", join.GetOriginalObject())\n\t\t\tlittleDoc, err := NewJDocFromInterface(a)\n\t\t\tif err != nil {\n\t\t\t\tctx.Log().Error(\"error_type\", \"func_itransform\", \"op\", \"itransform\", \"cause\", \"json_parse_error\", \"error\", err.Error(), \"params\", params)\n\t\t\t\tstats.IncErrors()\n\t\t\t\tAddError(ctx, RuntimeError{fmt.Sprintf(\"transformation error in call to itransform function\"), \"itransform\", params})\n\t\t\t\treturn nil\n\t\t\t}\n\t\t\tvar littleRes *JDoc\n\t\t\tif t.IsTransformationByExample {\n\t\t\t\tlittleRes = littleDoc.ApplyTransformationByExample(ctx, t.t)\n\t\t\t} else {\n\t\t\t\tlittleRes = littleDoc.ApplyTransformation(ctx, t.t)\n\t\t\t}\n\t\t\t//ctx.Log().Info(\"item_in\", a, \"item_out\", littleRes.StringPretty(), \"path\", extractStringParam(params[2]), \"idx\", i)\n\t\t\tsection.([]interface{})[i] = littleRes.GetOriginalObject()\n\t\t}\n\t\treturn section\n\t/*case map[string]interface{}:\n\tfor k, v := range section.(map[string]interface{}) {\n\t\tif pattern != nil {\n\t\t\tc, _ := doc.contains(v, pattern.GetOriginalObject(), 0)\n\t\t\tif !c {\n\t\t\t\tcontinue\n\t\t\t}\n\t\t}\n\t\tif join != nil {\n\t\t\tv = doc.merge(join.GetOriginalObject(), v)\n\t\t}\n\t\t//ctx.Log().Info(\"A\", a, \"MERGED\", amerged, \"JOIN\", join.GetOriginalObject())\n\t\tlittleDoc, err := NewJDocFromInterface(v)\n\t\tif err != nil {\n\t\t\tctx.Log().Error(\"error_type\", \"func_itransform\", \"op\", \"itransform\", \"error\", err.Error(), \"params\", params)\n\t\t\tstats.IncErrors()\n\t\t\treturn \"\"\n\t\t}\n\t\tvar littleRes *JDoc\n\t\tif t.IsTransformationByExample {\n\t\t\tlittleRes = littleDoc.ApplyTransformationByExample(ctx, t.t)\n\t\t} else {\n\t\t\tlittleRes = littleDoc.ApplyTransformation(ctx, t.t)\n\t\t}\n\t\t//ctx.Log().Info(\"item_in\", a, \"item_out\", littleRes.StringPretty(), \"path\", extractStringParam(params[2]), \"idx\", i)\n\t\tsection.(map[string]interface{})[k] = littleRes.GetOriginalObject()\n\t}\n\treturn section*/\n\t// apply sub-transformation to single sub-section of document\n\tdefault:\n\t\tif pattern != nil {\n\t\t\tc, _ := doc.contains(section, pattern.GetOriginalObject(), 0)\n\t\t\tif !c {\n\t\t\t\treturn section\n\t\t\t}\n\t\t}\n\t\tif join != nil {\n\t\t\tsection = doc.merge(join.GetOriginalObject(), section)\n\t\t}\n\t\tlittleDoc, err := NewJDocFromInterface(section)\n\t\tif err != nil {\n\t\t\tctx.Log().Error(\"error_type\", \"func_itransform\", \"op\", \"itransform\", \"cause\", \"json_parse_error\", \"error\", err.Error(), \"params\", params)\n\t\t\tstats.IncErrors()\n\t\t\tAddError(ctx, RuntimeError{fmt.Sprintf(\"transformation error in call to itransform function: %s\", err.Error()), \"itransform\", params})\n\t\t\treturn nil\n\t\t}\n\t\tvar littleRes *JDoc\n\t\tif t.IsTransformationByExample {\n\t\t\tlittleRes = littleDoc.ApplyTransformationByExample(ctx, t.t)\n\t\t} else {\n\t\t\tlittleRes = littleDoc.ApplyTransformation(ctx, t.t)\n\t\t}\n\t\treturn littleRes.GetOriginalObject()\n\t}\n}", "func (t merged) Transform(spec *specs.Spec) error {\n\tfor _, transformer := range t {\n\t\tif err := transformer.Transform(spec); err != nil {\n\t\t\treturn err\n\t\t}\n\t}\n\treturn nil\n}", "func (a anchoreClient) transform(fromType interface{}, toType interface{}) error {\n\tif err := mapstructure.Decode(fromType, toType); err != nil {\n\t\treturn errors.WrapIf(err, \"failed to unmarshal to 'toType' type\")\n\t}\n\n\treturn nil\n}", "func (def *Definition) Transform(v interface{}) ([]Event, error) {\n\treturn def.g.transform(v)\n}", "func NewTransform() Transform {\n\tt := transform{\n\t\tmodelView: mgl32.Ident4(),\n\t\trotation: mgl32.Vec3{0, 0, 0},\n\t\ttranslation: mgl32.Vec3{0, 0, 0},\n\t}\n\treturn &t\n}", "func (*AutoMlForecastingInputs_Transformation_TextTransformation) Descriptor() ([]byte, []int) {\n\treturn file_google_cloud_aiplatform_v1_schema_trainingjob_definition_automl_time_series_forecasting_proto_rawDescGZIP(), []int{1, 0, 4}\n}", "func (t *Transform) Destroy() {\n\tt.Reset()\n\ttransformPool.Put(t)\n}", "func Transform(t Text, transformer string) Text {\n\tf := FindTransformer(transformer)\n\tif f == nil {\n\t\treturn t\n\t}\n\tt = t.Clone()\n\tfor _, seg := range t {\n\t\tf(seg)\n\t}\n\treturn t\n}", "func (f *Font) CreateTextAdv(pos mgl.Vec3, color mgl.Vec4, maxWidth float32, charOffset int, cursorPosition int, msg string) TextRenderData {\n\t// this is the texture ID of the font to use in the shader; by default\n\t// the library always binds the font to the first texture sampler.\n\tconst floatTexturePosition = 0.0\n\n\t// sanity checks\n\toriginalLen := len(msg)\n\ttrimmedMsg := msg\n\tif originalLen == 0 {\n\t\treturn TextRenderData{\n\t\t\tComboBuffer: nil,\n\t\t\tIndexBuffer: nil,\n\t\t\tFaces: 0,\n\t\t\tWidth: 0.0,\n\t\t\tHeight: 0.0,\n\t\t\tAdvanceHeight: 0.0,\n\t\t\tCursorOverflowRight: false,\n\t\t}\n\t}\n\tif charOffset > 0 && charOffset < originalLen {\n\t\t// trim the string based on incoming character offset\n\t\ttrimmedMsg = trimmedMsg[charOffset:]\n\t}\n\n\t// get the length of our message\n\tmsgLength := len(trimmedMsg)\n\n\t// create the arrays to hold the data to buffer to OpenGL\n\tcomboBuffer := make([]float32, 0, msgLength*(2+2+4)*4) // pos, uv, color4\n\tindexBuffer := make([]uint32, 0, msgLength*6) // two faces * three indexes\n\n\t// do a preliminary test to see how much room the message will take up\n\tdimX, dimY, advH := f.GetRenderSize(trimmedMsg)\n\n\t// see how much to scale the size based on current resolution vs desgin resolution\n\tfontScale := f.GetCurrentScale()\n\n\t// loop through the message\n\tvar totalChars = 0\n\tvar scaledSize float32 = 0.0\n\tvar cursorOverflowRight bool\n\tvar penX = pos[0]\n\tvar penY = pos[1] - float32(advH)\n\tfor chi, ch := range trimmedMsg {\n\t\t// get the rune data\n\t\tchData := f.locations[ch]\n\n\t\t/*\n\t\t\tbounds, _, _ := f.face.GlyphBounds(ch)\n\t\t\tglyphD := bounds.Max.Sub(bounds.Min)\n\t\t\tglyphAdvW, _ := f.face.GlyphAdvance(ch)\n\t\t\tmetrics := f.face.Metrics()\n\t\t\tglyphAdvH := float32(metrics.Ascent.Round())\n\n\t\t\tglyphH := float32(glyphD.Y.Round())\n\t\t\tglyphW := float32(glyphD.X.Round())\n\t\t\tadvHeight := glyphAdvH\n\t\t\tadvWidth := float32(glyphAdvW.Round())\n\t\t*/\n\n\t\tglyphH := f.GlyphHeight\n\t\tglyphW := f.GlyphWidth\n\t\tadvHeight := chData.advanceHeight\n\t\tadvWidth := chData.advanceWidth\n\n\t\t// possibly stop here if we're going to overflow the max width\n\t\tif maxWidth > 0.0 && scaledSize+(advWidth*fontScale) > maxWidth {\n\t\t\t// we overflowed the size of the string, now check to see if\n\t\t\t// the cursor position is covered within this string or if that hasn't\n\t\t\t// been reached yet.\n\t\t\tif cursorPosition >= 0 && cursorPosition-charOffset > chi {\n\t\t\t\tcursorOverflowRight = true\n\t\t\t}\n\n\t\t\t// adjust the dimX here since we shortened the string\n\t\t\tdimX = scaledSize\n\t\t\tbreak\n\t\t}\n\t\tscaledSize += advWidth * fontScale\n\n\t\t// setup the coordinates for ther vetexes\n\t\tx0 := penX\n\t\ty0 := penY - (glyphH-advHeight)*fontScale\n\t\tx1 := x0 + glyphW*fontScale\n\t\ty1 := y0 + glyphH*fontScale\n\t\ts0 := chData.uvMinX\n\t\tt0 := chData.uvMinY\n\t\ts1 := chData.uvMaxX\n\t\tt1 := chData.uvMaxY\n\n\t\t// set the vertex data\n\t\tcomboBuffer = append(comboBuffer, x1)\n\t\tcomboBuffer = append(comboBuffer, y0)\n\t\tcomboBuffer = append(comboBuffer, s1)\n\t\tcomboBuffer = append(comboBuffer, t0)\n\t\tcomboBuffer = append(comboBuffer, floatTexturePosition)\n\t\tcomboBuffer = append(comboBuffer, color[:]...)\n\n\t\tcomboBuffer = append(comboBuffer, x1)\n\t\tcomboBuffer = append(comboBuffer, y1)\n\t\tcomboBuffer = append(comboBuffer, s1)\n\t\tcomboBuffer = append(comboBuffer, t1)\n\t\tcomboBuffer = append(comboBuffer, floatTexturePosition)\n\t\tcomboBuffer = append(comboBuffer, color[:]...)\n\n\t\tcomboBuffer = append(comboBuffer, x0)\n\t\tcomboBuffer = append(comboBuffer, y1)\n\t\tcomboBuffer = append(comboBuffer, s0)\n\t\tcomboBuffer = append(comboBuffer, t1)\n\t\tcomboBuffer = append(comboBuffer, floatTexturePosition)\n\t\tcomboBuffer = append(comboBuffer, color[:]...)\n\n\t\tcomboBuffer = append(comboBuffer, x0)\n\t\tcomboBuffer = append(comboBuffer, y0)\n\t\tcomboBuffer = append(comboBuffer, s0)\n\t\tcomboBuffer = append(comboBuffer, t0)\n\t\tcomboBuffer = append(comboBuffer, floatTexturePosition)\n\t\tcomboBuffer = append(comboBuffer, color[:]...)\n\n\t\tstartIndex := uint32(chi) * 4\n\t\tindexBuffer = append(indexBuffer, startIndex)\n\t\tindexBuffer = append(indexBuffer, startIndex+1)\n\t\tindexBuffer = append(indexBuffer, startIndex+2)\n\n\t\tindexBuffer = append(indexBuffer, startIndex+2)\n\t\tindexBuffer = append(indexBuffer, startIndex+3)\n\t\tindexBuffer = append(indexBuffer, startIndex)\n\n\t\t// advance the pen\n\t\tpenX += advWidth * fontScale\n\t\ttotalChars++\n\t}\n\n\treturn TextRenderData{\n\t\tComboBuffer: comboBuffer,\n\t\tIndexBuffer: indexBuffer,\n\t\tFaces: uint32(totalChars * 2),\n\t\tWidth: float32(dimX),\n\t\tHeight: float32(dimY),\n\t\tAdvanceHeight: float32(advH),\n\t\tCursorOverflowRight: cursorOverflowRight,\n\t}\n}", "func fnPTransform(ctx Context, doc *JDoc, params []string) interface{} {\n\t// note: calling ptransform in sync or debug mode does not make sense - should we raise an error in such a scenario?\n\tstats := ctx.Value(EelTotalStats).(*ServiceStats)\n\tif params == nil || len(params) == 0 || len(params) > 1 {\n\t\tctx.Log().Error(\"error_type\", \"func_ptransform\", \"op\", \"etransform\", \"cause\", \"wrong_number_of_parameters\", \"params\", params)\n\t\tstats.IncErrors()\n\t\tAddError(ctx, SyntaxError{fmt.Sprintf(\"wrong number of parameters in call to ptransform function\"), \"etransform\", params})\n\t\treturn nil\n\t}\n\t// prepare event\n\trawEvent := extractStringParam(params[0])\n\tevent, err := NewJDocFromString(rawEvent)\n\tif err != nil {\n\t\tctx.Log().Error(\"error_type\", \"func_ptransform\", \"op\", \"etransform\", \"cause\", \"invalid_json\", \"params\", params, \"error\", err.Error())\n\t\tstats.IncErrors()\n\t\tAddError(ctx, SyntaxError{fmt.Sprintf(\"non json parameters in call to ptransform function\"), \"etransform\", params})\n\t\treturn nil\n\t}\n\t// apply debug logs\n\tlogParams := GetConfig(ctx).LogParams\n\tif logParams != nil {\n\t\tfor k, v := range logParams {\n\t\t\tev := event.ParseExpression(ctx, v)\n\t\t\tctx.AddLogValue(k, ev)\n\t\t}\n\t}\n\t// handle event and execute publisher(s)\n\t// both sync=true or debug=true would not make sense here\n\thandleEvent(ctx, stats, event, rawEvent, false, false)\n\treturn nil\n}", "func constructInputsCopyTo(ctx *Context, inputs map[string]interface{}, args interface{}) error {\n\tif args == nil {\n\t\treturn errors.New(\"args must not be nil\")\n\t}\n\targsV := reflect.ValueOf(args)\n\ttyp := argsV.Type()\n\tif typ.Kind() != reflect.Ptr || typ.Elem().Kind() != reflect.Struct {\n\t\treturn errors.New(\"args must be a pointer to a struct\")\n\t}\n\targsV, typ = argsV.Elem(), typ.Elem()\n\n\tfor k, v := range inputs {\n\t\tci := v.(*constructInput)\n\t\tfor i := 0; i < typ.NumField(); i++ {\n\t\t\tfieldV := argsV.Field(i)\n\t\t\tif !fieldV.CanSet() {\n\t\t\t\tcontinue\n\t\t\t}\n\t\t\tfield := typ.Field(i)\n\t\t\ttag, has := field.Tag.Lookup(\"pulumi\")\n\t\t\tif !has || tag != k {\n\t\t\t\tcontinue\n\t\t\t}\n\n\t\t\thandleField := func(typ reflect.Type, value resource.PropertyValue, deps []Resource) (reflect.Value, error) {\n\t\t\t\tresultType := anyOutputType\n\t\t\t\tif typ.Implements(outputType) {\n\t\t\t\t\tresultType = typ\n\t\t\t\t} else if typ.Implements(inputType) {\n\t\t\t\t\ttoOutputMethodName := \"To\" + strings.TrimSuffix(typ.Name(), \"Input\") + \"Output\"\n\t\t\t\t\tif toOutputMethod, found := typ.MethodByName(toOutputMethodName); found {\n\t\t\t\t\t\tmt := toOutputMethod.Type\n\t\t\t\t\t\tif mt.NumIn() == 0 && mt.NumOut() == 1 && mt.Out(0).Implements(outputType) {\n\t\t\t\t\t\t\tresultType = mt.Out(0)\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\toutput := ctx.newOutput(resultType, deps...)\n\t\t\t\tdest := reflect.New(output.ElementType()).Elem()\n\t\t\t\tknown := !ci.value.ContainsUnknowns()\n\t\t\t\tsecret, err := unmarshalOutput(ctx, value, dest)\n\t\t\t\tif err != nil {\n\t\t\t\t\treturn reflect.Value{}, err\n\t\t\t\t}\n\t\t\t\toutput.getState().resolve(dest.Interface(), known, secret, nil)\n\t\t\t\treturn reflect.ValueOf(output), nil\n\t\t\t}\n\n\t\t\tisInputType := func(typ reflect.Type) bool {\n\t\t\t\treturn typ.Implements(outputType) || typ.Implements(inputType)\n\t\t\t}\n\n\t\t\tif isInputType(field.Type) {\n\t\t\t\tval, err := handleField(field.Type, ci.value, ci.deps)\n\t\t\t\tif err != nil {\n\t\t\t\t\treturn err\n\t\t\t\t}\n\t\t\t\tfieldV.Set(val)\n\t\t\t\tcontinue\n\t\t\t}\n\n\t\t\tif field.Type.Kind() == reflect.Slice && isInputType(field.Type.Elem()) {\n\t\t\t\telemType := field.Type.Elem()\n\t\t\t\tlength := len(ci.value.ArrayValue())\n\t\t\t\tdest := reflect.MakeSlice(field.Type, length, length)\n\t\t\t\tfor i := 0; i < length; i++ {\n\t\t\t\t\tval, err := handleField(elemType, ci.value.ArrayValue()[i], ci.deps)\n\t\t\t\t\tif err != nil {\n\t\t\t\t\t\treturn err\n\t\t\t\t\t}\n\t\t\t\t\tdest.Index(i).Set(val)\n\t\t\t\t}\n\t\t\t\tfieldV.Set(dest)\n\t\t\t\tcontinue\n\t\t\t}\n\n\t\t\tif field.Type.Kind() == reflect.Map && isInputType(field.Type.Elem()) {\n\t\t\t\telemType := field.Type.Elem()\n\t\t\t\tlength := len(ci.value.ObjectValue())\n\t\t\t\tdest := reflect.MakeMapWithSize(field.Type, length)\n\t\t\t\tfor k, v := range ci.value.ObjectValue() {\n\t\t\t\t\tkey := reflect.ValueOf(string(k))\n\t\t\t\t\tval, err := handleField(elemType, v, ci.deps)\n\t\t\t\t\tif err != nil {\n\t\t\t\t\t\treturn err\n\t\t\t\t\t}\n\t\t\t\t\tdest.SetMapIndex(key, val)\n\t\t\t\t}\n\t\t\t\tfieldV.Set(dest)\n\t\t\t\tcontinue\n\t\t\t}\n\n\t\t\tif len(ci.deps) > 0 {\n\t\t\t\treturn errors.Errorf(\n\t\t\t\t\t\"%s.%s is typed as %v but must be typed as Input or Output for input %q with dependencies\",\n\t\t\t\t\ttyp, field.Name, field.Type, k)\n\t\t\t}\n\t\t\tdest := reflect.New(field.Type).Elem()\n\t\t\tsecret, err := unmarshalOutput(ctx, ci.value, dest)\n\t\t\tif err != nil {\n\t\t\t\treturn errors.Wrapf(err, \"unmarshaling input %s\", k)\n\t\t\t}\n\t\t\tif secret {\n\t\t\t\treturn errors.Errorf(\n\t\t\t\t\t\"%s.%s is typed as %v but must be typed as Input or Output for secret input %q\",\n\t\t\t\t\ttyp, field.Name, field.Type, k)\n\t\t\t}\n\t\t\tfieldV.Set(reflect.ValueOf(dest.Interface()))\n\t\t}\n\t}\n\n\treturn nil\n}", "func (ren *RenderComponent) generateBufferContent() []float32 {\n\tscaleX := ren.scale.X\n\tscaleY := ren.scale.Y\n\trotation := float32(0.0)\n\ttransparency := float32(1.0)\n\tc := ren.Color\n\n\tfx := float32(0)\n\tfy := float32(0)\n\tfx2 := ren.drawable.Width()\n\tfy2 := ren.drawable.Height()\n\n\tif scaleX != 1 || scaleY != 1 {\n\t\t//fx *= scaleX\n\t\t//fy *= scaleY\n\t\tfx2 *= scaleX\n\t\tfy2 *= scaleY\n\t}\n\n\tp1x := fx\n\tp1y := fy\n\tp2x := fx\n\tp2y := fy2\n\tp3x := fx2\n\tp3y := fy2\n\tp4x := fx2\n\tp4y := fy\n\n\tvar x1 float32\n\tvar y1 float32\n\tvar x2 float32\n\tvar y2 float32\n\tvar x3 float32\n\tvar y3 float32\n\tvar x4 float32\n\tvar y4 float32\n\n\tif rotation != 0 {\n\t\trot := rotation * (math.Pi / 180.0)\n\n\t\tcos := math.Cos(rot)\n\t\tsin := math.Sin(rot)\n\n\t\tx1 = cos*p1x - sin*p1y\n\t\ty1 = sin*p1x + cos*p1y\n\n\t\tx2 = cos*p2x - sin*p2y\n\t\ty2 = sin*p2x + cos*p2y\n\n\t\tx3 = cos*p3x - sin*p3y\n\t\ty3 = sin*p3x + cos*p3y\n\n\t\tx4 = x1 + (x3 - x2)\n\t\ty4 = y3 - (y2 - y1)\n\t} else {\n\t\tx1 = p1x\n\t\ty1 = p1y\n\n\t\tx2 = p2x\n\t\ty2 = p2y\n\n\t\tx3 = p3x\n\t\ty3 = p3y\n\n\t\tx4 = p4x\n\t\ty4 = p4y\n\t}\n\n\tcolorR, colorG, colorB, _ := c.RGBA()\n\n\tred := colorR\n\tgreen := colorG << 8\n\tblue := colorB << 16\n\talpha := uint32(transparency*255.0) << 24\n\n\ttint := math.Float32frombits((alpha | blue | green | red) & 0xfeffffff)\n\n\tu, v, u2, v2 := ren.drawable.View()\n\n\treturn []float32{x1, y1, u, v, tint, x4, y4, u2, v, tint, x3, y3, u2, v2, tint, x2, y2, u, v2, tint}\n}", "func (t *Transform) New() *Transform {\n\tret := NewTransform()\n\tret.SetParent(t)\n\treturn ret\n}", "func NewTransformComponent(parent *Entity, position Vector3, size Vector3, origin Vector3, rotation float64) *TransformComponent {\n\ttransformComponent := &TransformComponent{\n\t\tID: \"transform\",\n\t\tParent: parent,\n\t\tPosition: position,\n\t\tSize: size,\n\t\tOrigin: origin,\n\t\tRotation: rotation,\n\t}\n\treturn transformComponent\n}", "func kongReqTransformerConvert(option *register.HeaderOption, ID string, tys string) *gokong.PluginRequest {\n\tpr := &gokong.PluginRequest{\n\t\tName: \"request-transformer\",\n\t}\n\tif tys == \"service\" {\n\t\tpr.ServiceId = gokong.ToId(ID)\n\t} else {\n\t\tpr.RouteId = gokong.ToId(ID)\n\t}\n\t//setting clean operation\n\tpr.Config = make(map[string]interface{})\n\tif len(option.Clean) != 0 {\n\t\tpr.Config[\"remove\"] = &httpTransformer{\n\t\t\tBody: []*string{},\n\t\t\tHeaders: gokong.StringSlice(option.Clean),\n\t\t\tQueryStr: []*string{},\n\t\t}\n\t}\n\t//add operation\n\tif len(option.Add) != 0 {\n\t\tvar values []string\n\t\tfor k, v := range option.Add {\n\t\t\tvalue := fmt.Sprintf(\"%s: %s\", k, v)\n\t\t\tvalues = append(values, value)\n\t\t}\n\t\tpr.Config[\"add\"] = &httpTransformer{\n\t\t\tBody: []*string{},\n\t\t\tHeaders: gokong.StringSlice(values),\n\t\t\tQueryStr: []*string{},\n\t\t}\n\t}\n\t//replace operation\n\tif len(option.Replace) != 0 {\n\t\tvar values []string\n\t\tfor k, v := range option.Replace {\n\t\t\tvalue := fmt.Sprintf(\"%s: %s\", k, v)\n\t\t\tvalues = append(values, value)\n\t\t}\n\t\tpr.Config[\"replace\"] = &httpTransformer{\n\t\t\tBody: []*string{},\n\t\t\tHeaders: gokong.StringSlice(values),\n\t\t\tQueryStr: []*string{},\n\t\t}\n\t}\n\treturn pr\n}", "func (p Profile) NewTransformer() *Transformer {\n\tvar ts []transform.Transformer\n\n\tif p.options.allowwidechars {\n\t\tts = append(ts, width.Fold)\n\t}\n\n\tts = append(ts, checker{p: p})\n\n\tif p.options.width != nil {\n\t\tts = append(ts, width.Fold)\n\t}\n\n\tfor _, f := range p.options.additional {\n\t\tts = append(ts, f())\n\t}\n\n\tif p.options.cases != nil {\n\t\tts = append(ts, p.options.cases)\n\t}\n\n\tts = append(ts, p.options.norm)\n\n\t// TODO: Apply directionality rule (blocking on the Bidi package)\n\t// TODO: Add the disallow empty rule with a dummy transformer?\n\n\treturn &Transformer{transform.Chain(ts...)}\n}", "func (a *AddLabels) Transform(mfs []*dto.MetricFamily) []*dto.MetricFamily {\n\tfor i := range mfs {\n\t\tfor j, m := range mfs[i].Metric {\n\t\t\t// Filter out labels to add\n\t\t\tlabels := m.Label[:0]\n\t\t\tfor _, l := range m.Label {\n\t\t\t\tif _, ok := a.Labels[l.GetName()]; !ok {\n\t\t\t\t\tlabels = append(labels, l)\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t// Add all new labels to the metric\n\t\t\tfor k, v := range a.Labels {\n\t\t\t\tlabels = append(labels, L(k, v))\n\t\t\t}\n\t\t\tsort.Sort(labelPairSorter(labels))\n\t\t\tmfs[i].Metric[j].Label = labels\n\t\t}\n\t}\n\treturn mfs\n}", "func (*TransformationTemplate) Descriptor() ([]byte, []int) {\n\treturn file_github_com_solo_io_gloo_projects_gloo_api_v1_options_transformation_transformation_proto_rawDescGZIP(), []int{7}\n}", "func (v *Vectorizer) Tranform() *FeatureMatrix {\n\n}", "func main() {\n\tfmt.Println(\"Start Test....!\")\n\tinputDB := setupDB(\"mysql\", \"root:root123@tcp(127.0.0.1:13306)/srcDB\")\n\textractDP := processors.NewSQLReader(inputDB, mypkg.Query(5))\n\n\ttransformDP := mypkg.NewMyTransformer()\n\tfmt.Println(transformDP)\n\n\toutputDB := setupDB(\"mysql\", \"root:root123@tcp(127.0.0.1:13306)/dstDB\")\n\toutputTable := \"krew_info\"\n\tloadDP := processors.NewSQLWriter(outputDB, outputTable)\n\n\tpipeline := ratchet.NewPipeline(extractDP, transformDP, loadDP)\n\tpipeline.Name = \"My Pipeline\"\n\n\terr := <-pipeline.Run()\n\tif err != nil {\n\t\tlogger.ErrorWithoutTrace(pipeline.Name, \":\", err)\n\t\tlogger.ErrorWithoutTrace(pipeline.Stats())\n\t} else {\n\t\tlogger.Info(pipeline.Name, \": Completed successfully.\")\n\t}\n}", "func NewTransformer(feastClient feast.Client, config *transformer.StandardTransformerConfig, options *Options, logger *zap.Logger) (*Transformer, error) {\n\tdefaultValues := make(map[string]*types.Value)\n\t// populate default values\n\tfor _, ft := range config.TransformerConfig.Feast {\n\t\tfor _, f := range ft.Features {\n\t\t\tif len(f.DefaultValue) != 0 {\n\t\t\t\tfeastValType := types.ValueType_Enum(types.ValueType_Enum_value[f.ValueType])\n\t\t\t\tdefVal, err := getValue(f.DefaultValue, feastValType)\n\t\t\t\tif err != nil {\n\t\t\t\t\tlogger.Warn(fmt.Sprintf(\"invalid default value for %s : %v, %v\", f.Name, f.DefaultValue, err))\n\t\t\t\t\tcontinue\n\t\t\t\t}\n\t\t\t\tdefaultValues[f.Name] = defVal\n\t\t\t}\n\t\t}\n\t}\n\n\tcompiledJsonPath := make(map[string]*jsonpath.Compiled)\n\tcompiledUdf := make(map[string]*vm.Program)\n\tfor _, ft := range config.TransformerConfig.Feast {\n\t\tfor _, configEntity := range ft.Entities {\n\t\t\tswitch configEntity.Extractor.(type) {\n\t\t\tcase *transformer.Entity_JsonPath:\n\t\t\t\tc, err := jsonpath.Compile(configEntity.GetJsonPath())\n\t\t\t\tif err != nil {\n\t\t\t\t\treturn nil, fmt.Errorf(\"unable to compile jsonpath for entity %s: %s\", configEntity.Name, configEntity.GetJsonPath())\n\t\t\t\t}\n\t\t\t\tcompiledJsonPath[configEntity.GetJsonPath()] = c\n\t\t\tcase *transformer.Entity_Udf:\n\t\t\t\tc, err := expr.Compile(configEntity.GetUdf(), expr.Env(UdfEnv{}))\n\t\t\t\tif err != nil {\n\t\t\t\t\treturn nil, err\n\t\t\t\t}\n\t\t\t\tcompiledUdf[configEntity.GetUdf()] = c\n\t\t\t}\n\n\t\t}\n\t}\n\n\treturn &Transformer{\n\t\tfeastClient: feastClient,\n\t\tconfig: config,\n\t\toptions: options,\n\t\tlogger: logger,\n\t\tdefaultValues: defaultValues,\n\t\tcompiledJsonPath: compiledJsonPath,\n\t\tcompiledUdf: compiledUdf,\n\t}, nil\n}", "func (eval *evaluator) LinearTransformNew(ctIn *Ciphertext, linearTransform interface{}) (ctOut []*Ciphertext) {\n\n\tswitch element := linearTransform.(type) {\n\tcase []PtDiagMatrix:\n\t\tctOut = make([]*Ciphertext, len(element))\n\n\t\tvar maxLevel int\n\t\tfor _, matrix := range element {\n\t\t\tmaxLevel = utils.MaxInt(maxLevel, matrix.Level)\n\t\t}\n\n\t\tminLevel := utils.MinInt(maxLevel, ctIn.Level())\n\n\t\teval.DecomposeNTT(minLevel, eval.params.PCount()-1, eval.params.PCount(), ctIn.Value[1], eval.PoolDecompQP)\n\n\t\tfor i, matrix := range element {\n\t\t\tctOut[i] = NewCiphertext(eval.params, 1, minLevel, ctIn.Scale)\n\n\t\t\tif matrix.Naive {\n\t\t\t\teval.MultiplyByDiagMatrix(ctIn, matrix, eval.PoolDecompQP, ctOut[i])\n\t\t\t} else {\n\t\t\t\teval.MultiplyByDiagMatrixBSGS(ctIn, matrix, eval.PoolDecompQP, ctOut[i])\n\t\t\t}\n\t\t}\n\n\tcase PtDiagMatrix:\n\n\t\tminLevel := utils.MinInt(element.Level, ctIn.Level())\n\t\teval.DecomposeNTT(minLevel, eval.params.PCount()-1, eval.params.PCount(), ctIn.Value[1], eval.PoolDecompQP)\n\n\t\tctOut = []*Ciphertext{NewCiphertext(eval.params, 1, minLevel, ctIn.Scale)}\n\n\t\tif element.Naive {\n\t\t\teval.MultiplyByDiagMatrix(ctIn, element, eval.PoolDecompQP, ctOut[0])\n\t\t} else {\n\t\t\teval.MultiplyByDiagMatrixBSGS(ctIn, element, eval.PoolDecompQP, ctOut[0])\n\t\t}\n\t}\n\treturn\n}", "func CreatePipeline(dsl Pipeline) pipeline.GroovePipeline {\n\t// Register the sources used in the groove pipeline.\n\tRegisterSources()\n\n\t// Create a groove pipeline from the boogie dsl.\n\tg := pipeline.GroovePipeline{}\n\tif s, ok := querySourceMapping[dsl.Query.Format]; ok {\n\t\tg.QueriesSource = s\n\t} else {\n\t\tlog.Fatalf(\"%v is not a known query source\", dsl.Query.Format)\n\t}\n\n\tif len(dsl.Statistic.Source) > 0 {\n\t\tif s, ok := statisticSourceMapping[dsl.Statistic.Source]; ok {\n\t\t\tg.StatisticsSource = s\n\t\t} else {\n\t\t\tlog.Fatalf(\"%v is not a known statistics source\", dsl.Statistic.Source)\n\t\t}\n\t}\n\n\tif len(dsl.Statistic.Source) == 0 && len(dsl.Measurements) > 0 {\n\t\tlog.Fatal(\"A statistic source is required for measurements\")\n\t}\n\n\tif len(dsl.Measurements) > 0 && len(dsl.Output.Measurements) == 0 {\n\t\tlog.Fatal(\"At least one output format must be supplied when using analysis measurements\")\n\t}\n\n\tif len(dsl.Output.Measurements) > 0 && len(dsl.Measurements) == 0 {\n\t\tlog.Fatal(\"At least one analysis measurement must be supplied for the output formats\")\n\t}\n\n\tif len(dsl.Evaluations) > 0 && len(dsl.Output.Evaluations.Measurements) == 0 {\n\t\tlog.Fatal(\"At least one output format must be supplied when using evaluation measurements\")\n\t}\n\n\tif len(dsl.Output.Evaluations.Measurements) > 0 && len(dsl.Evaluations) == 0 {\n\t\tlog.Fatal(\"At least one evaluation measurement must be supplied for the output formats\")\n\t}\n\n\tg.Measurements = []analysis.Measurement{}\n\tfor _, measurementName := range dsl.Measurements {\n\t\tif m, ok := measurementMapping[measurementName]; ok {\n\t\t\tg.Measurements = append(g.Measurements, m)\n\t\t} else {\n\t\t\tlog.Fatalf(\"%v is not a known measurement\", measurementName)\n\t\t}\n\t}\n\n\tg.Evaluations = []eval.Evaluator{}\n\tfor _, evaluationMeasurement := range dsl.Evaluations {\n\t\tif m, ok := evaluationMapping[evaluationMeasurement.Evaluation]; ok {\n\t\t\tg.Evaluations = append(g.Evaluations, m)\n\t\t} else {\n\t\t\tlog.Fatalf(\"%v is not a known evaluation measurement\", evaluationMeasurement.Evaluation)\n\t\t}\n\t}\n\n\tif len(dsl.Output.Evaluations.Qrels) > 0 {\n\t\tb, err := ioutil.ReadFile(dsl.Output.Evaluations.Qrels)\n\t\tif err != nil {\n\t\t\tlog.Fatalln(err)\n\t\t}\n\t\tqrels, err := trecresults.QrelsFromReader(bytes.NewReader(b))\n\t\tif err != nil {\n\t\t\tlog.Fatalln(err)\n\t\t}\n\t\tg.EvaluationQrels = qrels\n\t}\n\n\tg.MeasurementFormatters = []output.MeasurementFormatter{}\n\tfor _, formatter := range dsl.Output.Measurements {\n\t\tif o, ok := measurementFormatters[formatter.Format]; ok {\n\t\t\tg.MeasurementFormatters = append(g.MeasurementFormatters, o)\n\t\t} else {\n\t\t\tlog.Fatalf(\"%v is not a known measurement output format\", formatter.Format)\n\t\t}\n\t}\n\n\tg.EvaluationFormatters = []output.EvaluationFormatter{}\n\tfor _, formatter := range dsl.Output.Evaluations.Measurements {\n\t\tif o, ok := evaluationFormatters[formatter.Format]; ok {\n\t\t\tg.EvaluationFormatters = append(g.EvaluationFormatters, o)\n\t\t} else {\n\t\t\tlog.Fatalf(\"%v is not a known evaluation output format\", formatter.Format)\n\t\t}\n\t}\n\n\tg.Preprocess = []preprocess.QueryProcessor{}\n\tfor _, p := range dsl.Preprocess {\n\t\tif processor, ok := preprocessorMapping[p]; ok {\n\t\t\tg.Preprocess = append(g.Preprocess, processor)\n\t\t} else {\n\t\t\tlog.Fatalf(\"%v is not a known preprocessor\", p)\n\t\t}\n\t}\n\n\tg.Transformations = preprocess.QueryTransformations{}\n\tfor _, t := range dsl.Transformations.Operations {\n\t\tif transformation, ok := transformationMappingBoolean[t]; ok {\n\t\t\tg.Transformations.BooleanTransformations = append(g.Transformations.BooleanTransformations, transformation)\n\t\t} else if transformation, ok := transformationMappingElasticsearch[t]; ok {\n\t\t\tg.Transformations.ElasticsearchTransformations = append(g.Transformations.ElasticsearchTransformations, transformation)\n\t\t} else {\n\t\t\tlog.Fatalf(\"%v is not a known preprocessing transformation\", t)\n\t\t}\n\t}\n\n\t//g.QueryChain\n\tif len(dsl.Rewrite.Chain) > 0 && len(dsl.Rewrite.Transformations) > 0 {\n\t\tvar transformations []rewrite.Transformation\n\t\tfor _, transformation := range dsl.Rewrite.Transformations {\n\t\t\tif t, ok := rewriteTransformationMapping[transformation]; ok {\n\t\t\t\ttransformations = append(transformations, t)\n\t\t\t} else {\n\t\t\t\tlog.Fatalf(\"%v is not a known rewrite transformation\", transformation)\n\t\t\t}\n\t\t}\n\n\t\tif qc, ok := queryChainCandidateSelectorMapping[dsl.Rewrite.Chain]; ok {\n\t\t\tg.QueryChain = rewrite.NewQueryChain(qc, transformations...)\n\t\t} else {\n\t\t\tlog.Fatalf(\"%v is not a known query chain candidate selector\", dsl.Rewrite.Chain)\n\t\t}\n\n\t}\n\n\tg.Transformations.Output = dsl.Transformations.Output\n\tg.OutputTrec.Path = dsl.Output.Trec.Output\n\treturn g\n}", "func (*TimestampTransform) Descriptor() ([]byte, []int) {\n\treturn file_org_apache_beam_model_pipeline_v1_beam_runner_api_proto_rawDescGZIP(), []int{38}\n}", "func (t *Transformer) Transform(logRecord *InputRecord, recType string, tzShiftMin int, anonymousUsers []int) (*OutputRecord, error) {\n\tuserID := -1\n\n\tr := &OutputRecord{\n\t\tType: recType,\n\t\ttime: logRecord.GetTime(),\n\t\tDatetime: logRecord.GetTime().Add(time.Minute * time.Duration(tzShiftMin)).Format(time.RFC3339),\n\t\tIPAddress: logRecord.Request.RemoteAddr,\n\t\tUserAgent: logRecord.Request.HTTPUserAgent,\n\t\tIsAnonymous: userID == -1 || conversion.UserBelongsToList(userID, anonymousUsers),\n\t\tIsQuery: false,\n\t\tUserID: strconv.Itoa(userID),\n\t\tAction: logRecord.Action,\n\t\tPath: logRecord.Path,\n\t\tProcTime: logRecord.ProcTime,\n\t\tParams: logRecord.Params,\n\t}\n\tr.ID = createID(r)\n\tif t.prevReqs.ContainsSimilar(r) && r.Action == \"overlay\" ||\n\t\t!t.prevReqs.ContainsSimilar(r) && r.Action == \"text\" {\n\t\tr.IsQuery = true\n\t}\n\tt.prevReqs.AddItem(r)\n\treturn r, nil\n}", "func (DeclareCandidacyDataResource) Transform(txData interface{}, context *state.CheckState) TxDataResource {\n\tdata := txData.(*transaction.DeclareCandidacyData)\n\tcoin := context.Coins().GetCoin(data.Coin)\n\n\treturn DeclareCandidacyDataResource{\n\t\tAddress: data.Address.String(),\n\t\tPubKey: data.PubKey.String(),\n\t\tCommission: strconv.Itoa(int(data.Commission)),\n\t\tStake: data.Stake.String(),\n\t\tCoin: CoinResource{coin.ID().Uint32(), coin.GetFullSymbol()},\n\t}\n}", "func NewTransactor(m I2CMaster) Transactor {\n\tvar t transactor\n\tt.Transactor8x8 = NewTransact8x8(m)\n\tt.Transactor16x8 = NewTransact16x8(m)\n\n\treturn &t\n}", "func (*AutoMlForecastingInputs_Transformation_TextArrayTransformation) Descriptor() ([]byte, []int) {\n\treturn file_google_cloud_aiplatform_v1_schema_trainingjob_definition_automl_time_series_forecasting_proto_rawDescGZIP(), []int{1, 0, 7}\n}", "func (resource MultiSendDataResource) Transform(txData interface{}, context *state.CheckState) TxDataResource {\n\tdata := txData.(*transaction.MultisendData)\n\n\tfor _, v := range data.List {\n\t\tcoin := context.Coins().GetCoin(v.Coin)\n\n\t\tresource.List = append(resource.List, SendDataResource{\n\t\t\tCoin: CoinResource{coin.ID().Uint32(), coin.GetFullSymbol()},\n\t\t\tTo: v.To.String(),\n\t\t\tValue: v.Value.String(),\n\t\t})\n\t}\n\n\treturn resource\n}", "func (mp *MetricTranslator) TranslateDataPoints(logger *zap.Logger, sfxDataPoints []*sfxpb.DataPoint) []*sfxpb.DataPoint {\n\tprocessedDataPoints := sfxDataPoints\n\n\tfor _, tr := range mp.rules {\n\t\tswitch tr.Action {\n\t\tcase ActionRenameDimensionKeys:\n\t\t\tfor _, dp := range processedDataPoints {\n\t\t\t\tfor _, d := range dp.Dimensions {\n\t\t\t\t\tif newKey, ok := tr.Mapping[d.Key]; ok {\n\t\t\t\t\t\td.Key = newKey\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\tcase ActionRenameMetrics:\n\t\t\tfor _, dp := range processedDataPoints {\n\t\t\t\tif newKey, ok := tr.Mapping[dp.Metric]; ok {\n\t\t\t\t\tdp.Metric = newKey\n\t\t\t\t}\n\t\t\t}\n\t\tcase ActionMultiplyInt:\n\t\t\tfor _, dp := range processedDataPoints {\n\t\t\t\tif multiplier, ok := tr.ScaleFactorsInt[dp.Metric]; ok {\n\t\t\t\t\tv := dp.GetValue().IntValue\n\t\t\t\t\tif v != nil {\n\t\t\t\t\t\t*v = *v * multiplier\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\tcase ActionDivideInt:\n\t\t\tfor _, dp := range processedDataPoints {\n\t\t\t\tif divisor, ok := tr.ScaleFactorsInt[dp.Metric]; ok {\n\t\t\t\t\tv := dp.GetValue().IntValue\n\t\t\t\t\tif v != nil {\n\t\t\t\t\t\t*v = *v / divisor\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\tcase ActionMultiplyFloat:\n\t\t\tfor _, dp := range processedDataPoints {\n\t\t\t\tif multiplier, ok := tr.ScaleFactorsFloat[dp.Metric]; ok {\n\t\t\t\t\tv := dp.GetValue().DoubleValue\n\t\t\t\t\tif v != nil {\n\t\t\t\t\t\t*v = *v * multiplier\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\tcase ActionCopyMetrics:\n\t\t\tfor _, dp := range processedDataPoints {\n\t\t\t\tif newMetric, ok := tr.Mapping[dp.Metric]; ok {\n\t\t\t\t\tnewDataPoint := copyMetric(tr, dp, newMetric)\n\t\t\t\t\tif newDataPoint != nil {\n\t\t\t\t\t\tprocessedDataPoints = append(processedDataPoints, newDataPoint)\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\tcase ActionSplitMetric:\n\t\t\tfor _, dp := range processedDataPoints {\n\t\t\t\tif tr.MetricName == dp.Metric {\n\t\t\t\t\tsplitMetric(dp, tr.DimensionKey, tr.Mapping)\n\t\t\t\t}\n\t\t\t}\n\t\tcase ActionConvertValues:\n\t\t\tfor _, dp := range processedDataPoints {\n\t\t\t\tif newType, ok := tr.TypesMapping[dp.Metric]; ok {\n\t\t\t\t\tconvertMetricValue(logger, dp, newType)\n\t\t\t\t}\n\t\t\t}\n\t\tcase ActionCalculateNewMetric:\n\t\t\tvar operand1, operand2 *sfxpb.DataPoint\n\t\t\tfor _, dp := range processedDataPoints {\n\t\t\t\tif dp.Metric == tr.Operand1Metric {\n\t\t\t\t\toperand1 = dp\n\t\t\t\t} else if dp.Metric == tr.Operand2Metric {\n\t\t\t\t\toperand2 = dp\n\t\t\t\t}\n\t\t\t}\n\t\t\tnewPt := calculateNewMetric(logger, operand1, operand2, tr)\n\t\t\tif newPt == nil {\n\t\t\t\tcontinue\n\t\t\t}\n\t\t\tprocessedDataPoints = append(processedDataPoints, newPt)\n\n\t\tcase ActionAggregateMetric:\n\t\t\t// NOTE: Based on the usage of TranslateDataPoints we can assume that the datapoints batch []*sfxpb.DataPoint\n\t\t\t// represents only one metric and all the datapoints can be aggregated together.\n\t\t\tvar dpsToAggregate []*sfxpb.DataPoint\n\t\t\tvar otherDps []*sfxpb.DataPoint\n\t\t\tfor i, dp := range processedDataPoints {\n\t\t\t\tif dp.Metric == tr.MetricName {\n\t\t\t\t\tif dpsToAggregate == nil {\n\t\t\t\t\t\tdpsToAggregate = make([]*sfxpb.DataPoint, 0, len(processedDataPoints)-i)\n\t\t\t\t\t}\n\t\t\t\t\tdpsToAggregate = append(dpsToAggregate, dp)\n\t\t\t\t} else {\n\t\t\t\t\tif otherDps == nil {\n\t\t\t\t\t\totherDps = make([]*sfxpb.DataPoint, 0, len(processedDataPoints)-i)\n\t\t\t\t\t}\n\t\t\t\t\t// This slice can contain additional datapoints from a different metric\n\t\t\t\t\t// for example copied in a translation step before\n\t\t\t\t\totherDps = append(otherDps, dp)\n\t\t\t\t}\n\t\t\t}\n\t\t\taggregatedDps := aggregateDatapoints(logger, dpsToAggregate, tr.Dimensions, tr.AggregationMethod)\n\t\t\tprocessedDataPoints = append(otherDps, aggregatedDps...)\n\t\t}\n\t}\n\n\treturn processedDataPoints\n}", "func transformArgs(n ir.InitNode) {\n\tvar list []ir.Node\n\tswitch n := n.(type) {\n\tdefault:\n\t\tbase.Fatalf(\"transformArgs %+v\", n.Op())\n\tcase *ir.CallExpr:\n\t\tlist = n.Args\n\t\tif n.IsDDD {\n\t\t\treturn\n\t\t}\n\tcase *ir.ReturnStmt:\n\t\tlist = n.Results\n\t}\n\tif len(list) != 1 {\n\t\treturn\n\t}\n\n\tt := list[0].Type()\n\tif t == nil || !t.IsFuncArgStruct() {\n\t\treturn\n\t}\n\n\t// Save n as n.Orig for fmt.go.\n\tif ir.Orig(n) == n {\n\t\tn.(ir.OrigNode).SetOrig(ir.SepCopy(n))\n\t}\n\n\t// Rewrite f(g()) into t1, t2, ... = g(); f(t1, t2, ...).\n\ttypecheck.RewriteMultiValueCall(n, list[0])\n}" ]
[ "0.5351817", "0.52744895", "0.5228354", "0.51837265", "0.51837265", "0.5156473", "0.5147383", "0.5144394", "0.5119867", "0.51156515", "0.5083896", "0.50515765", "0.4960884", "0.49533263", "0.4951437", "0.49473682", "0.493895", "0.49282476", "0.49245748", "0.48988372", "0.48664278", "0.48655504", "0.48655504", "0.48583296", "0.48553824", "0.4851222", "0.4851222", "0.4833826", "0.48268637", "0.48162958", "0.48161182", "0.48120806", "0.48115972", "0.47923332", "0.47730255", "0.47343266", "0.47097334", "0.4706806", "0.4693189", "0.4692855", "0.4688673", "0.46857202", "0.46801654", "0.46754572", "0.4662589", "0.4659843", "0.4655695", "0.46548685", "0.4652971", "0.4651314", "0.464246", "0.46387228", "0.46276766", "0.4616766", "0.4608976", "0.46021026", "0.45740718", "0.45678544", "0.4557736", "0.4522726", "0.45159587", "0.4512059", "0.4507381", "0.45051175", "0.44875917", "0.44835487", "0.44767314", "0.44741255", "0.44687837", "0.446622", "0.4452753", "0.44520256", "0.44392127", "0.4437423", "0.4433932", "0.44282156", "0.4426514", "0.44217512", "0.4418522", "0.44180605", "0.44127482", "0.44111553", "0.44091913", "0.44025922", "0.44008702", "0.4392691", "0.4391312", "0.43839726", "0.4381657", "0.43773597", "0.4376626", "0.4374306", "0.4372596", "0.43716648", "0.4367754", "0.43616313", "0.43615475", "0.43614265", "0.43562177" ]
0.47264865
37
create vertex array objects
func CreateVertexArrays(n int32, arrays *uint32) { C.glowCreateVertexArrays(gpCreateVertexArrays, (C.GLsizei)(n), (*C.GLuint)(unsafe.Pointer(arrays))) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func CreateVertexArrays(n int32, arrays *uint32) {\n\tsyscall.Syscall(gpCreateVertexArrays, 2, uintptr(n), uintptr(unsafe.Pointer(arrays)), 0)\n}", "func GenVertexArrays(n int32, arrays *uint32) {\n\tsyscall.Syscall(gpGenVertexArrays, 2, uintptr(n), uintptr(unsafe.Pointer(arrays)), 0)\n}", "func createVertex(children []string, name string) (NodeG) {\n if len(children) == 0 {\n // this is wrong...\n // you can't this return a nil.\n // you can declare a var and return it but that seems weird...\n return NodeG{name, nil}\n }\n\n // this has to be a make cant declare a slice...\n result := make([]NodeG, len(children))\n for i:= 0 ; i<len(children) ; i++ {\n n := NodeG{children[i], nil}\n result[i] = n\n }\n\n return NodeG{name, result}\n}", "func GenVertexArrays(n int32, arrays *uint32) {\n C.glowGenVertexArrays(gpGenVertexArrays, (C.GLsizei)(n), (*C.GLuint)(unsafe.Pointer(arrays)))\n}", "func init_vertex(x, y int) Vertex {\n return Vertex{x, y}\n}", "func NewPrimitives() Primitives {\n\treturn Primitives{\n\t\t\"vtxs\": NewAttributes(Int, 0),\n\t}\n}", "func makeVao(points []float32) uint32 {\n\tvar vbo uint32\n\tgl.GenBuffers(1, &vbo)\n\tgl.BindBuffer(gl.ARRAY_BUFFER, vbo)\n\tgl.BufferData(gl.ARRAY_BUFFER, 4*len(points), gl.Ptr(points), gl.STATIC_DRAW)\n\n\tvar vao uint32\n\tgl.GenVertexArrays(1, &vao)\n\tgl.BindVertexArray(vao)\n\tgl.BindBuffer(gl.ARRAY_BUFFER, vbo)\n\tvar offset int = 6 * 4\n\tgl.VertexAttribPointer(0, 2, gl.FLOAT, false, 8*4, gl.PtrOffset(offset))\n\tgl.EnableVertexAttribArray(0)\n\t//gl.VertexAttribPointer(0, 3, gl.FLOAT, false, 0, nil)\n\n\treturn vao\n}", "func GenerateVertexArray(n int32) uint32 {\n\tvar vao uint32\n\t//gl.GenVertexArraysAPPLE(n, &vao)\n\tgl.GenVertexArrays(n, &vao)\n\t/*if err := gl.GetError(); err != 0 {\n\t\tlog.Println(\"Error in GenVertexArrays!\", err)\n\t}*/\n\n\treturn vao\n}", "func MakeVertexArray(points []float32) uint32 {\n\tvar vbo uint32\n\tgl.GenBuffers(1, &vbo)\n\tgl.BindBuffer(gl.ARRAY_BUFFER, vbo)\n\tgl.BufferData(gl.ARRAY_BUFFER, 4*len(points), gl.Ptr(points), gl.STATIC_DRAW)\n\n\tvar vao uint32\n\tgl.GenVertexArrays(1, &vao)\n\tgl.BindVertexArray(vao)\n\tgl.EnableVertexAttribArray(0)\n\tgl.BindBuffer(gl.ARRAY_BUFFER, vbo)\n\tgl.VertexAttribPointer(0, 3, gl.FLOAT, false, 0, nil)\n\n\treturn vao\n}", "func makeVao(data []float32) uint32 {\n\tvar vbo uint32\n\tgl.GenBuffers(1, &vbo)\n\tgl.BindBuffer(gl.ARRAY_BUFFER, vbo)\n\tgl.BufferData(gl.ARRAY_BUFFER, 4*len(data), gl.Ptr(data), gl.STATIC_DRAW)\n\n\tvar vao uint32\n\tgl.GenVertexArrays(1, &vao)\n\tgl.BindVertexArray(vao)\n\tgl.BindBuffer(gl.ARRAY_BUFFER, vbo)\n\tvar offset int\n\n\t// position attribute\n\tgl.VertexAttribPointer(0, 3, gl.FLOAT, false, 8*4, gl.PtrOffset(offset))\n\tgl.EnableVertexAttribArray(0)\n\toffset += 3 * 4\n\n\t// color attribute\n\tgl.VertexAttribPointer(1, 3, gl.FLOAT, false, 8*4, gl.PtrOffset(offset))\n\tgl.EnableVertexAttribArray(1)\n\toffset += 3 * 4\n\n\t// texture coord attribute\n\tgl.VertexAttribPointer(2, 2, gl.FLOAT, false, 8*4, gl.PtrOffset(offset))\n\tgl.EnableVertexAttribArray(2)\n\toffset += 2 * 4\n\n\treturn vao\n}", "func (g *Graph) init(numVertex int) {\n if g.vertex == nil {\n g.vertex = make([]*NodeG, numVertex)\n }\n}", "func parseVertex(t []string) []float32 {\n\tx, _ := strconv.ParseFloat(t[0], 32)\n\ty, _ := strconv.ParseFloat(t[1], 32)\n\tz, _ := strconv.ParseFloat(t[2], 32)\n\n\treturn []float32{float32(x), float32(y), float32(z)}\n}", "func makeVao(points []float32) uint32 {\n\tvar vbo uint32\n\tgl.GenBuffers(1, &vbo)\n\tgl.BindBuffer(gl.ARRAY_BUFFER, vbo)\n\tgl.BufferData(gl.ARRAY_BUFFER, 4*len(points), gl.Ptr(points), gl.STATIC_DRAW)\n\n\tvar vao uint32\n\tgl.GenVertexArrays(1, &vao)\n\tgl.BindVertexArray(vao)\n\tgl.EnableVertexAttribArray(0)\n\tgl.BindBuffer(gl.ARRAY_BUFFER, vbo)\n\tgl.VertexAttribPointer(0, 3, gl.FLOAT, false, 0, nil)\n\n\treturn vao\n}", "func (g *Graph) init(numVertex int) {\n if g.vertex == nil {\n g.vertex = make([]*NodeG, numVertex+1)\n }\n}", "func makeVao(points []float32) uint32 {\n\tvar vbo uint32\n\tvar vao uint32\n\tvar stride int32\n\n\t//points only 9\n\t//points and colors 18\n\tstride = int32(4 * len(points) / 3)\n\tprintln(\"stride: \", stride)\n\n\tgl.GenVertexArrays(1, &vao)\n\tgl.GenBuffers(1, &vbo)\n\tgl.BindVertexArray(vao)\n\n\tgl.BindBuffer(gl.ARRAY_BUFFER, vbo)\n\tgl.BufferData(gl.ARRAY_BUFFER, 4*len(points), gl.Ptr(points), gl.STATIC_DRAW)\n\n\tgl.EnableVertexAttribArray(0)\n\tgl.VertexAttribPointer(0, 3, gl.FLOAT, false, stride, gl.PtrOffset(0))\n\tprintln(\"triangle length: \", len(points))\n\tif len(points) >= 18 {\n\t\tlog.Println(\"In if\")\n\t\tgl.EnableVertexAttribArray(1)\n\t\tgl.VertexAttribPointer(1, 3, gl.FLOAT, false, stride, gl.PtrOffset(3*4))\n\t}\n\treturn vao\n}", "func GenVertexArrays(n int32, arrays *uint32) {\n\tC.glowGenVertexArrays(gpGenVertexArrays, (C.GLsizei)(n), (*C.GLuint)(unsafe.Pointer(arrays)))\n}", "func GenVertexArrays(n int32, arrays *uint32) {\n\tC.glowGenVertexArrays(gpGenVertexArrays, (C.GLsizei)(n), (*C.GLuint)(unsafe.Pointer(arrays)))\n}", "func VertexArrayVertexBuffers(vaobj uint32, first uint32, count int32, buffers *uint32, offsets *int, strides *int32) {\n\tsyscall.Syscall6(gpVertexArrayVertexBuffers, 6, uintptr(vaobj), uintptr(first), uintptr(count), uintptr(unsafe.Pointer(buffers)), uintptr(unsafe.Pointer(offsets)), uintptr(unsafe.Pointer(strides)))\n}", "func (debugging *debuggingOpenGL) GenVertexArrays(n int32) []uint32 {\n\tdebugging.recordEntry(\"GenVertexArrays\", n)\n\tresult := debugging.gl.GenVertexArrays(n)\n\tdebugging.recordExit(\"GenVertexArrays\", result)\n\treturn result\n}", "func (native *OpenGL) GenVertexArrays(n int32) []uint32 {\n\tids := make([]uint32, n)\n\tgl.GenVertexArrays(n, &ids[0])\n\treturn ids\n}", "func packSFzVertex(v []FzVertex, ptr0 *C.fz_vertex) {\n\tconst m = 0x7fffffff\n\tfor i0 := range v {\n\t\tptr1 := (*(*[m / sizeOfFzVertexValue]C.fz_vertex)(unsafe.Pointer(ptr0)))[i0]\n\t\tv[i0] = *NewFzVertexRef(unsafe.Pointer(&ptr1))\n\t}\n}", "func NewVertex(path []Cube, moves []Move) *Vertex {\n\treturn &Vertex{path, moves}\n}", "func Make(mode uint32) VAO {\n\tvao := VAO{0, mode, nil, nil}\n\tgl.GenVertexArrays(1, &vao.handle)\n\treturn vao\n}", "func makeVao(vertices []float32, textureCoords []float32) uint32 {\n\tvbos := make([]uint32, 2)\n\t// vertices\n\tgl.GenBuffers(1, &vbos[0])\n\tgl.BindBuffer(gl.ARRAY_BUFFER, vbos[0])\n\tgl.BufferData(gl.ARRAY_BUFFER, 4*len(vertices), gl.Ptr(vertices), gl.STATIC_DRAW)\n\n\t// texture coords\n\ttexInvertY(textureCoords)\n\tgl.GenBuffers(1, &vbos[1])\n\tgl.BindBuffer(gl.ARRAY_BUFFER, vbos[1])\n\tgl.BufferData(gl.ARRAY_BUFFER, 4*len(textureCoords), gl.Ptr(textureCoords), gl.STATIC_DRAW)\n\n\t// create vao\n\tvar vao uint32\n\tgl.GenVertexArrays(1, &vao)\n\tgl.BindVertexArray(vao)\n\n\t// bind vertices\n\tgl.BindBuffer(gl.ARRAY_BUFFER, vbos[0])\n\tgl.VertexAttribPointer(0, 3, gl.FLOAT, false, 0, nil)\n\tgl.EnableVertexAttribArray(0)\n\n\t// bind textures\n\tgl.BindBuffer(gl.ARRAY_BUFFER, vbos[1])\n\tgl.VertexAttribPointer(1, 2, gl.FLOAT, false, 0, nil)\n\tgl.EnableVertexAttribArray(1)\n\n\treturn vao\n}", "func LoadFromFile(filename string) *Object {\n\t//initialize data arrays\n\tVertexPositions := make([]float32, 0)\n\tVertexIndices := make([]int, 0)\n\n\t//load the file\n\tfile, err := os.Open(filename)\n\tif err != nil {\n\t\tlog.Fatal(err)\n\t}\n\tdefer file.Close()\n\n\tscanner := bufio.NewScanner(file)\n\tvar line string\n\t//scan the file line by line and parse appropriately\n\tfor scanner.Scan() {\n\t\tline = scanner.Text()\n\t\tfields := strings.Fields(line)\n\t\t//vertex positions data\n\t\tif fields[0] == \"v\" {\n\t\t\tfor i := 1; i < 4; i++ {\n\t\t\t\tvPos, _ := strconv.ParseFloat(fields[i], 32)\n\t\t\t\tVertexPositions = append(VertexPositions, float32(vPos))\n\t\t\t}\n\t\t}\n\t\t//vertex indices data\n\t\tvIndices := make([]int, 6)\n\t\tif fields[0] == \"f\" {\n\t\t\tfor i := 0; i < 4; i++ {\n\t\t\t\t//subtracting one from each index in order to zero index\n\t\t\t\tvIndices[i], _ = strconv.Atoi(strings.Split(fields[i+1], \"//\")[0])\n\t\t\t\tvIndices[i]--\n\t\t\t}\n\t\t\tvIndices[5] = vIndices[3]\n\t\t\tvIndices[3], vIndices[4] = vIndices[0], vIndices[2]\n\t\t\tVertexIndices = append(VertexIndices, vIndices...)\n\t\t}\n\t}\n\n\tobj := &Object{VertexPositions, VertexIndices}\n\n\tif err := scanner.Err(); err != nil {\n\t\tlog.Fatal(err)\n\t}\n\n\treturn obj\n}", "func PackVertex(v *gdbi.Vertex) map[string]interface{} {\n\treturn map[string]interface{}{\n\t\t\"gid\": v.ID,\n\t\t\"label\": v.Label,\n\t\t\"data\": v.Data,\n\t}\n}", "func VertexArrayVertexBuffers(vaobj uint32, first uint32, count int32, buffers *uint32, offsets *int, strides *int32) {\n\tC.glowVertexArrayVertexBuffers(gpVertexArrayVertexBuffers, (C.GLuint)(vaobj), (C.GLuint)(first), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(buffers)), (*C.GLintptr)(unsafe.Pointer(offsets)), (*C.GLsizei)(unsafe.Pointer(strides)))\n}", "func VertexArrayVertexBuffers(vaobj uint32, first uint32, count int32, buffers *uint32, offsets *int, strides *int32) {\n\tC.glowVertexArrayVertexBuffers(gpVertexArrayVertexBuffers, (C.GLuint)(vaobj), (C.GLuint)(first), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(buffers)), (*C.GLintptr)(unsafe.Pointer(offsets)), (*C.GLsizei)(unsafe.Pointer(strides)))\n}", "func initFontVbo() {\n\tvar vertexAttributes = make([]float32, 5*6*len(charDatas))\n\ti := 0\n\tfor _, charData := range charDatas {\n\t\ttop := float32(charData.ty+charData.h) / 256\n\t\tbottom := float32(charData.ty) / 256\n\t\tright := float32(charData.tx+charData.w) / 256\n\t\tleft := float32(charData.tx) / 256\n\n\t\tw := float32(charData.w) / 256\n\t\th := float32(charData.h) / 256\n\n\t\t// tri 1\n\t\tvertexAttributes[i] = w\n\t\tvertexAttributes[i+1] = h\n\t\tvertexAttributes[i+2] = 0\n\t\tvertexAttributes[i+3] = right\n\t\tvertexAttributes[i+4] = bottom\n\t\ti += 5\n\n\t\tvertexAttributes[i] = w\n\t\tvertexAttributes[i+1] = 0\n\t\tvertexAttributes[i+2] = 0\n\t\tvertexAttributes[i+3] = right\n\t\tvertexAttributes[i+4] = top\n\t\ti += 5\n\n\t\tvertexAttributes[i] = 0\n\t\tvertexAttributes[i+1] = h\n\t\tvertexAttributes[i+2] = 0\n\t\tvertexAttributes[i+3] = left\n\t\tvertexAttributes[i+4] = bottom\n\t\ti += 5\n\n\t\t// tri 2\n\t\tvertexAttributes[i] = w\n\t\tvertexAttributes[i+1] = 0\n\t\tvertexAttributes[i+2] = 0\n\t\tvertexAttributes[i+3] = right\n\t\tvertexAttributes[i+4] = top\n\t\ti += 5\n\n\t\tvertexAttributes[i] = 0\n\t\tvertexAttributes[i+1] = 0\n\t\tvertexAttributes[i+2] = 0\n\t\tvertexAttributes[i+3] = left\n\t\tvertexAttributes[i+4] = top\n\t\ti += 5\n\n\t\tvertexAttributes[i] = 0\n\t\tvertexAttributes[i+1] = h\n\t\tvertexAttributes[i+2] = 0\n\t\tvertexAttributes[i+3] = left\n\t\tvertexAttributes[i+4] = bottom\n\t\ti += 5\n\t}\n\n\tgl.GenBuffers(1, &vbo)\n\tgl.GenVertexArrays(1, &vao)\n\tgl.BindVertexArray(vao)\n\tgl.EnableVertexAttribArray(0)\n\tgl.BindBuffer(gl.ARRAY_BUFFER, vbo)\n\tgl.BufferData(\n\t\tgl.ARRAY_BUFFER,\n\t\t4*len(vertexAttributes),\n\t\tgl.Ptr(vertexAttributes),\n\t\tgl.STATIC_DRAW,\n\t)\n\tgl.VertexAttribPointer(0, 3, gl.FLOAT, false, 5*4, gl.PtrOffset(0))\n\tgl.EnableVertexAttribArray(0)\n\tgl.VertexAttribPointer(1, 2, gl.FLOAT, false, 5*4, gl.PtrOffset(4*3))\n\tgl.EnableVertexAttribArray(1)\n\t//unbind\n\tgl.BindVertexArray(0)\n\n}", "func VertexArrayVertexBuffer(vaobj uint32, bindingindex uint32, buffer uint32, offset int, stride int32) {\n\tsyscall.Syscall6(gpVertexArrayVertexBuffer, 5, uintptr(vaobj), uintptr(bindingindex), uintptr(buffer), uintptr(offset), uintptr(stride), 0)\n}", "func newVerticesFromLump(lump *wad.Lump) ([]utils.Vec2, error) {\n\tvar verts []utils.Vec2\n\tswitch string(lump.Data[0:4]) {\n\tcase glMagicV5:\n\t\tverts = readGLVertsV5(lump.Data[4:])\n\tdefault:\n\t\tverts = readNormalVerts(lump.Data)\n\t}\n\n\treturn verts, nil\n}", "func newVertex(x, y, theta, v, w float64, parent *Vertex) *Vertex {\n\treturn &Vertex{Point{X: x, Y: y, Theta: theta, V: v, W: w}, parent, nil}\n}", "func MakeVertexArrayObject() VertexArrayObject {\n\tvar vao uint32\n\tgl.GenVertexArrays(1, &vao)\n\treturn VertexArrayObject(vao)\n}", "func (g *Graph) addVertices(vertices int) ([]Vertex, error) {\n\ti := 1\n\tvar arr []Vertex\n\tarr = make([]Vertex, vertices)\n\n\tfor i <= vertices {\n\t\tv, err := g.addVertex()\n\t\tif err != nil {\n\t\t\tlog.Fatal(err)\n\t\t}\n\t\tarr[i-1] = v\n\t\ti++\n\t}\n\n\treturn nil, nil\n}", "func newVertexCollection(name string, g *graph) (Collection, error) {\n\tif name == \"\" {\n\t\treturn nil, WithStack(InvalidArgumentError{Message: \"name is empty\"})\n\t}\n\tif g == nil {\n\t\treturn nil, WithStack(InvalidArgumentError{Message: \"g is nil\"})\n\t}\n\treturn &vertexCollection{\n\t\tname: name,\n\t\tg: g,\n\t\tconn: g.db.conn,\n\t}, nil\n}", "func MakeVertexBufferObject(sizeBytes int, data unsafe.Pointer) VertexBufferObject {\n\tvar vbo uint32\n\tgl.GenBuffers(1, &vbo)\n\tif sizeBytes > 0 {\n\t\tgl.NamedBufferData(vbo, sizeBytes, data, gl.DYNAMIC_DRAW)\n\t}\n\treturn VertexBufferObject(vbo)\n}", "func (o BoundingPolyOutput) Vertices() VertexArrayOutput {\n\treturn o.ApplyT(func(v BoundingPoly) []Vertex { return v.Vertices }).(VertexArrayOutput)\n}", "func init_triangle(A, B, C Vertex) Triangle {\n // Initialize structs using curly braces\n return Triangle{A, B, C}\n}", "func makeVertex(vertexType string) graphson.Vertex {\n\tvertexValue := graphson.VertexValue{\n\t\tID: \"unused_vertex_value_ID\",\n\t\tLabel: vertexType,\n\t\tProperties: map[string][]graphson.VertexProperty{},\n\t}\n\tvertex := graphson.Vertex{Type: vertexType, Value: vertexValue}\n\treturn vertex\n}", "func VertexArrayAttribFormat(vaobj uint32, attribindex uint32, size int32, xtype uint32, normalized bool, relativeoffset uint32) {\n\tsyscall.Syscall6(gpVertexArrayAttribFormat, 6, uintptr(vaobj), uintptr(attribindex), uintptr(size), uintptr(xtype), boolToUintptr(normalized), uintptr(relativeoffset))\n}", "func main() {\n //Leemos el archivo\n data, err := ioutil.ReadFile(\"g.txt\")\n if err != nil {\n fmt.Println(\"File reading error\", err)\n return\n }\n rows := strings.Split(string(data), \"\\n\")\n //Inicializamos los vertices\n numOfVertexes, _ := strconv.Atoi(rows[0])\n vertexesG := make([]Vertex, numOfVertexes)\n count := 0;\n for count < numOfVertexes {\n vertexesG[count] = Vertex{count, 0.1, 0.2}\n count = count + 1\n }\n\n //Inicializamos las aristas con los valores del archivo\n numOfEdges := len(rows)-2\n edgesG := make([]Edge, numOfEdges)\n count = 0;\n for count < numOfEdges {\n vertIndx := strings.Split(rows[count+1], \",\") \n vertex1, _ := strconv.Atoi(vertIndx[0])\n vertex2, _ := strconv.Atoi(vertIndx[1])\n edgesG[count] = Edge{vertex1,vertex2,1}\n count = count + 1\n }\n\n //De lo anterior tenemos el conjuinto de vertices vertexesG y el conjunto de aristas edgesG\n //El apuntador a estos dos conjuntos se les pasara a todas las hormigas para que los compartan\n //Y todas tengan los mismos conjuntos\n\n\n //VARIABLE QUE NOS DIRA CUANTAS VECES SE HA ENCONTRADO UNA SOLUCION CON EL MISMO TAMAÑO DE MANERA CONSECUTIVA \n numSinCambios := 0\n //Variable que nos dice el numero de veces que si se encuentra la solcucion con el mismo tamaño se detendra el algoritmo\n numIteracionSeguidasParaParar := 200\n //Defefine el numero de hormigas que tendremos\n numberOfAnts := 20\n //Calculamos la cantidad de aristas que debe de tener la greafica comompleta dada la cantidad de vertices que tenemos\n numOfEdgesFull := (numOfVertexes*(numOfVertexes-1))/2\n\n //VARIABLES QUE DEFINE LOS PARAMETROS DEL ALGORITMO\n q := 0.5\n evaporation_rate := 0.2\n pheromone_adjust := 0.12\n //beta := 1\n //VARIABLES QUE DEFINE LOS PARAMETROS DEL ALGORITMO\n\n //Semilla para la funcion de numeros aleatorios\n randomSeed := 1\n //La funcion para generar los numeros aletarios que usaremos\n randomFun := rand.New(rand.NewSource(int64(randomSeed)))\n min_sol := make([]int, numOfVertexes)\n \n //Inicializamos un slice de hormigas con la cantida de hormigas definida\n ants := make([]Ant, numberOfAnts)\n\n antCount := 0\n //Para cada hormiga le vamos a crear su slice de edgesFull, una grafica con el apuntaos a los vertifces\n //el aputnador a las aristas y sus aristas que rempresentaran a la grafica completa\n //Depues vamos a crear ala hormiga con los parametros\n //La grafica que le creamos, un slice de enteros para sus soluciones, la funcion aleatorio y los parametros \n for antCount < numberOfAnts {\n edgesFull := make([]Edge, numOfEdgesFull)\n graphG := Graph{&vertexesG,&edgesG,&edgesFull}\n slice := make([]int, 0)\n ants[antCount] = Ant{antCount,&graphG,randomFun, &slice,q,evaporation_rate,pheromone_adjust}\n antCount = antCount +1\n }\n \n ///////////////////////////////////\n //////////ALGORITMO ACO////////////\n ///////////////////////////////////\n //Mientras no se tengan numIteracionSeguidasParaParar sin cambios en la solucion\n //Ejecutaremos el siguiente ciclo\n\n////////////////////////CICLO////////////////////////////\n for numSinCambios <= numIteracionSeguidasParaParar{\n\n //fmt.Printf(\"Sin cambios: %d\\n\", numSinCambios)\n\n //Inicializamos a cada una de las hormigas estos es \n //Inicializar la grafica full\n //Inicialar el slice de soluciones\n //no necesitamos poner a la hormiga en un vertice arbitratio en un principio por que desde todos los vertices tenemos conexion a todos por ser grafica\n //a todos por ser grafica completa\n antCount = 0\n for antCount < numberOfAnts {\n (*ants[antCount].graph).initFull()\n ants[antCount].BorraSolucion()\n antCount = antCount +1\n } \n \n //Mientras alguno de las hormigas pueda dar un paso\n sePuedeDarPaso := true\n for sePuedeDarPaso != false {\n\n otroPaso := false\n antCount = 0\n //Verificamos si alguna de las hormigas todavia puede dar un paso\n for antCount < numberOfAnts {\n if ants[antCount].PuedeDarUnPaso(){\n otroPaso = true\n }\n antCount = antCount +1\n }\n \n //Si alguna hormiga todavia puede dar un paso\n sePuedeDarPaso = otroPaso\n if sePuedeDarPaso{\n antCount = 0\n for antCount < numberOfAnts {\n //Verificamos si la hormiga con index antCount puede dar un paso y si es asi\n //Esta damos el paso con esta hormiga\n if ants[antCount].PuedeDarUnPaso(){\n\n////////////////////////PASO//////////////////////////// (VER EL LA FUNCION)\n ants[antCount].Paso() \n }\n antCount = antCount +1\n }\n }\n }\n\n///////////TODAS LAS HORMIGAS COMPLETAN SU TRAYECTO/////\n //Una vez que ya se dieron todos los pasos posibles debemo encontrar la mejor solucion guardarla y actualziar la feromona\n antCount = 0\n //El tamaño de la solucion minima\n minSolLen := -1\n //El indice de la hormiga que tiene la solucion minima\n minSolIndex := -1\n //Buscamos la solucion minima entre todas las hormigas\n for antCount < numberOfAnts {\n solLen := len((*ants[antCount].solution))\n if minSolLen > solLen || minSolLen < 0{\n minSolLen = solLen\n minSolIndex = antCount\n }\n antCount = antCount +1\n }\n ants[minSolIndex].PrintSolution()\n\n //Verificamos que la solucioon mejor encontrada en este ciclo sea mejor que minima solucion actual\n if len(min_sol) >= len((*ants[minSolIndex].solution)){\n //Si la solucion tiene el mismo tamaño entonces sumaos 1 al contador de ciclos sin con el mismo \n //Tamaño de solucion\n if len(min_sol) == len((*ants[minSolIndex].solution)){\n numSinCambios = numSinCambios+1\n //Si la solucion es mas pequeña regreamos el contador a 0 \n }else{\n numSinCambios = 0\n }\n\n //Borramos la mejor solucion anterior\n min_sol = make([]int, len((*ants[minSolIndex].solution)))\n countSolIndex := 0\n //Copiamos la nueva solucion minima\n for countSolIndex < len(min_sol){\n min_sol[countSolIndex] = (*ants[minSolIndex].solution)[countSolIndex]\n countSolIndex = countSolIndex +1\n }\n }\n\n countSolIndex := 0\n //Imprimimos la mejor solucion hasta el momento\n fmt.Printf(\"MejorSolucion: \")\n for countSolIndex < len(min_sol){\n fmt.Printf(\"%d \", min_sol[countSolIndex])\n countSolIndex = countSolIndex +1\n }\n fmt.Printf(\"\\n\")\n\n////////////////////////ACTUALIZACION GLOBAL////////////////////////////\n //Por ultimo vamos a hacer la actualizacion de la feromona de manera GLOBAL\n countVertexIndex := 0\n //Para cada uno de los vertices calculamos el nuevo valor de la hormona considerando la evaporacion\n for countVertexIndex < len(vertexesG){\n vertexIndex := vertexesG[countVertexIndex].index\n vertexPheromone := vertexesG[countVertexIndex].pheromone\n newPheromoneValue := (1-evaporation_rate)*vertexPheromone\n addedPheromone := 0.0\n countSolIndex := 0\n //Si el vertice es parte de la solucion minima actual entonces tambien calculamos la feromona extra que se le sumara\n for countSolIndex < len(min_sol){\n if vertexIndex == min_sol[countSolIndex]{\n addedPheromone = evaporation_rate*(1.0/float64((len(min_sol))))\n //fmt.Printf(\"AddedPhero %f\\n\",addedPheromone)\n }\n countSolIndex = countSolIndex +1\n } \n //Actualizamos el valor de la feromona\n vertexesG[countVertexIndex].pheromone = newPheromoneValue + addedPheromone\n countVertexIndex = countVertexIndex +1\n }\n\n }\n\n}", "func VertexArrayElementBuffer(vaobj uint32, buffer uint32) {\n\tsyscall.Syscall(gpVertexArrayElementBuffer, 2, uintptr(vaobj), uintptr(buffer), 0)\n}", "func VertexArrayVertexBuffer(vaobj uint32, bindingindex uint32, buffer uint32, offset int, stride int32) {\n\tC.glowVertexArrayVertexBuffer(gpVertexArrayVertexBuffer, (C.GLuint)(vaobj), (C.GLuint)(bindingindex), (C.GLuint)(buffer), (C.GLintptr)(offset), (C.GLsizei)(stride))\n}", "func VertexArrayVertexBuffer(vaobj uint32, bindingindex uint32, buffer uint32, offset int, stride int32) {\n\tC.glowVertexArrayVertexBuffer(gpVertexArrayVertexBuffer, (C.GLuint)(vaobj), (C.GLuint)(bindingindex), (C.GLuint)(buffer), (C.GLintptr)(offset), (C.GLsizei)(stride))\n}", "func NewMesh(vertices []vector.Vector) Mesh {\n\t// Check size of the polygon, there should be at least three points\n\tif len(vertices) != 3 {\n\t\tlog.Fatalf(\"Model.NewMesh: expected 3 points, got %d\", len(vertices))\n\t}\n\n\tvar mesh Mesh\n\tfor i, point := range vertices {\n\t\tif point.Len() != 3 {\n\t\t\tlog.Fatalf(\"Model.NewMesh: expected 3D point, got %d\", point.Len())\n\t\t}\n\t\tmesh.vertices[i] = point\n\t}\n\n\treturn mesh\n}", "func CollectVertices(g VertexEnumerator) (vertices []Vertex) {\n\tif c, ok := g.(VertexCounter); ok {\n\t\t// If possible, size the slice based on the number of vertices the graph reports it has\n\t\tvertices = make([]Vertex, 0, c.Order())\n\t} else {\n\t\t// Otherwise just pick something...reasonable?\n\t\tvertices = make([]Vertex, 0, 32)\n\t}\n\n\tg.Vertices(func(v Vertex) (terminate bool) {\n\t\tvertices = append(vertices, v)\n\t\treturn\n\t})\n\n\treturn vertices\n}", "func (g Graph) initFull(){\n numVertex := len(*g.vertexes)\n count := 0\n i := 0\n for i < numVertex{\n j := i+1\n for j < numVertex{\n if g.ExisteEnEdges(i,j){\n (*g.full)[count] = Edge{i,j,1}\n }else{\n (*g.full)[count] = Edge{i,j,0}\n }\n count = count +1\n j = j +1\n }\n i = i +1\n }\n}", "func NewVerticies() Verticies {\n\treturn Verticies{\n\t\t\"pt\": NewAttributes(Int, 1),\n\t}\n}", "func MultiDrawElementsBaseVertex(mode uint32, count *int32, xtype uint32, indices *unsafe.Pointer, drawcount int32, basevertex *int32) {\n\tsyscall.Syscall6(gpMultiDrawElementsBaseVertex, 6, uintptr(mode), uintptr(unsafe.Pointer(count)), uintptr(xtype), uintptr(unsafe.Pointer(indices)), uintptr(drawcount), uintptr(unsafe.Pointer(basevertex)))\n}", "func (g *Graph) getVertices() ([]Vertex, error) {\n\tvar arr []Vertex\n\tarr = make([]Vertex, g.numvert)\n\n\ti := 0\n\tfor node, value := range g.vertices {\n\t\tif value {\n\t\t\tarr[i] = node\n\t\t\ti++\n\t\t}\n\t}\n\n\treturn arr, nil\n}", "func qr_decoder_get_coderegion_vertexes(p _QrDecoderHandle) *_CvPoint {\n\tv := C.qr_decoder_get_coderegion_vertexes(C.QrDecoderHandle(p))\n\treturn (*_CvPoint)(v)\n}", "func New[V comparable](vertices ...V) *Graph[V] {\n\tadj := make(map[V]neighbors[V])\n\tinDegrees := make(map[V]int)\n\tfor _, vertex := range vertices {\n\t\tadj[vertex] = make(neighbors[V])\n\t\tinDegrees[vertex] = 0\n\t}\n\treturn &Graph[V]{\n\t\tvertices: adj,\n\t\tinDegrees: inDegrees,\n\t}\n}", "func (obj *Device) CreateVertexDeclaration(\n\tvertexElements []VERTEXELEMENT,\n) (*VertexDeclaration, Error) {\n\tvar elems uintptr\n\tif len(vertexElements) > 0 {\n\t\telems = uintptr(unsafe.Pointer(&vertexElements[0]))\n\t}\n\tvar decl *VertexDeclaration\n\tret, _, _ := syscall.Syscall(\n\t\tobj.vtbl.CreateVertexDeclaration,\n\t\t3,\n\t\tuintptr(unsafe.Pointer(obj)),\n\t\telems,\n\t\tuintptr(unsafe.Pointer(&decl)),\n\t)\n\treturn decl, toErr(ret)\n}", "func (va *VertexArray) SetLayout(layout VertexLayout) {\n\tif len(va.layout.layout) != 0 {\n\t\treturn\n\t}\n\n\tva.layout = layout\n\n\t// generate and bind the vertex array\n\tgl.GenVertexArrays(1, &va.vao) // generates the vertex array (or multiple)\n\tgl.BindVertexArray(va.vao) // binds the vertex array\n\n\t// make vertex array pointer attributes\n\t// offset is the offset in bytes to the first attribute\n\toffset := 0\n\n\t// calculate vertex stride\n\tstride := 0\n\tfor _, elem := range va.layout.layout {\n\t\tstride += elem.getByteSize()\n\n\t}\n\n\t// Vertex Buffer Object\n\tgl.GenBuffers(1, &va.vbo) // generates the buffer (or multiple)\n\tgl.BindBuffer(gl.ARRAY_BUFFER, va.vbo)\n\n\tfor i, elem := range va.layout.layout {\n\n\t\t// define an array of generic vertex attribute data\n\t\t// index, size, type, normalized, stride of vertex (in bytes), pointer (offset)\n\t\t// point positions\n\t\tgl.VertexAttribPointer(uint32(i), int32(elem.getSize()),\n\t\t\telem.getGLType(), false, int32(stride), gl.PtrOffset(offset))\n\t\tgl.EnableVertexAttribArray(uint32(i))\n\t\toffset += elem.getByteSize()\n\t}\n\n}", "func MultiDrawElementsBaseVertex(mode uint32, count *int32, xtype uint32, indices *unsafe.Pointer, drawcount int32, basevertex *int32) {\n C.glowMultiDrawElementsBaseVertex(gpMultiDrawElementsBaseVertex, (C.GLenum)(mode), (*C.GLsizei)(unsafe.Pointer(count)), (C.GLenum)(xtype), indices, (C.GLsizei)(drawcount), (*C.GLint)(unsafe.Pointer(basevertex)))\n}", "func DeleteVertexArrary(n int32, arrays *uint32) {\n\t//gl.DeleteVertexArraysAPPLE(n, arrays)\n\tgl.DeleteVertexArrays(n, arrays)\n}", "func (v Vec3i) ToArray(array []int32, offset int) {\n\tarray[offset] = v.X\n\tarray[offset+1] = v.Y\n\tarray[offset+2] = v.Z\n}", "func GenerateShapes() {\r\n\t// Square\r\n\tShapes[0].vertices = []gl.GLfloat{-1, -1, 1, -1, -1, 1, 1, 1}\r\n\tShapes[0].elements = []gl.GLushort{0, 1, 2, 2, 3, 1}\r\n\r\n\t// ___|\r\n\tShapes[1].vertices = []gl.GLfloat{-2, 0, -2, -1, 2, -1, 2, 0, 2, 1, 1, 1, 1, 0}\r\n\tShapes[1].elements = []gl.GLushort{0, 1, 2, 2, 3, 0, 3, 4, 5, 5, 6, 3}\r\n\r\n\t// _|_\r\n\tShapes[2].vertices = []gl.GLfloat{-1.5, 0, -0.5, 0, -0.5, 1, 0.5, 1, 0.5, 0, 1.5, 0, 1.5, -1, -1.5, -1}\r\n\tShapes[2].elements = []gl.GLushort{1, 2, 3, 3, 4, 1, 0, 7, 6, 6, 0, 5}\r\n\r\n\t// Snake\r\n\tShapes[3].vertices = []gl.GLfloat{-1.5, -1, -1.5, 0, -0.5, 0, -0.5, 1, 1.5, 1, 1.5, 0, 0.5, 0, 0.5, -1}\r\n\tShapes[3].elements = []gl.GLushort{0, 1, 6, 6, 7, 0, 2, 3, 4, 4, 5, 2}\r\n\r\n\t// Now fill out the rest automatically.\r\n\t// FIXME why doesn't using _, shape in this loop work ?\r\n\tfor i := range Shapes {\r\n\t\tShapes[i].vao = gl.GenVertexArray()\r\n\t\tShapes[i].vao.Bind()\r\n\t\tShapes[i].vbo = gl.GenBuffer()\r\n\t\tShapes[i].vbo.Bind(gl.ARRAY_BUFFER)\r\n\t\tgl.BufferData(gl.ARRAY_BUFFER, len(Shapes[i].vertices)*4, Shapes[i].vertices, gl.STATIC_DRAW)\r\n\t\tShapes[i].elementBuffer = gl.GenBuffer()\r\n\t\tShapes[i].elementBuffer.Bind(gl.ELEMENT_ARRAY_BUFFER)\r\n\t\tgl.BufferData(gl.ELEMENT_ARRAY_BUFFER, len(Shapes[i].elements)*2, Shapes[i].elements, gl.STATIC_DRAW)\r\n\t\tShapes[i].numElements = len(Shapes[i].elements)\r\n\r\n\t\tvertexAttribArray := shaderProgram.GetAttribLocation(\"position\")\r\n\t\tvertexAttribArray.AttribPointer(2, gl.FLOAT, false, 0, uintptr(0))\r\n\t\tvertexAttribArray.EnableArray()\r\n\t}\r\n}", "func VertexArrayAttribFormat(vaobj uint32, attribindex uint32, size int32, xtype uint32, normalized bool, relativeoffset uint32) {\n\tC.glowVertexArrayAttribFormat(gpVertexArrayAttribFormat, (C.GLuint)(vaobj), (C.GLuint)(attribindex), (C.GLint)(size), (C.GLenum)(xtype), (C.GLboolean)(boolToInt(normalized)), (C.GLuint)(relativeoffset))\n}", "func VertexArrayAttribFormat(vaobj uint32, attribindex uint32, size int32, xtype uint32, normalized bool, relativeoffset uint32) {\n\tC.glowVertexArrayAttribFormat(gpVertexArrayAttribFormat, (C.GLuint)(vaobj), (C.GLuint)(attribindex), (C.GLint)(size), (C.GLenum)(xtype), (C.GLboolean)(boolToInt(normalized)), (C.GLuint)(relativeoffset))\n}", "func VertexArrayElementBuffer(vaobj uint32, buffer uint32) {\n\tC.glowVertexArrayElementBuffer(gpVertexArrayElementBuffer, (C.GLuint)(vaobj), (C.GLuint)(buffer))\n}", "func VertexArrayElementBuffer(vaobj uint32, buffer uint32) {\n\tC.glowVertexArrayElementBuffer(gpVertexArrayElementBuffer, (C.GLuint)(vaobj), (C.GLuint)(buffer))\n}", "func BindVertexArray(array uint32) {\n C.glowBindVertexArray(gpBindVertexArray, (C.GLuint)(array))\n}", "func (z *Zzz) FromArray(a A.X) *Zzz { //nolint:dupl false positive\n\tz.Id = X.ToU(a[0])\n\tz.CreatedAt = X.ToI(a[1])\n\tz.Coords = X.ToArr(a[2])\n\tz.Name = X.ToS(a[3])\n\tz.HeightMeter = X.ToF(a[4])\n\treturn z\n}", "func Structs() {\n\tfmt.Println(vertex{1, 2})\n}", "func create_triangle() Triangle {\n v1 := init_vertex(0, 1)\n v2 := init_vertex(1, 0)\n v3 := init_vertex(0, 0)\n t1 := init_triangle(v1, v2, v3)\n fmt.Println(t1)\n // Can access struct fields with a dot\n fmt.Println(t1.A)\n return t1\n}", "func GetVertexArrayiv(vaobj uint32, pname uint32, param *int32) {\n\tC.glowGetVertexArrayiv(gpGetVertexArrayiv, (C.GLuint)(vaobj), (C.GLenum)(pname), (*C.GLint)(unsafe.Pointer(param)))\n}", "func GetVertexArrayiv(vaobj uint32, pname uint32, param *int32) {\n\tC.glowGetVertexArrayiv(gpGetVertexArrayiv, (C.GLuint)(vaobj), (C.GLenum)(pname), (*C.GLint)(unsafe.Pointer(param)))\n}", "func GetVertexArrayiv(vaobj uint32, pname uint32, param *int32) {\n\tsyscall.Syscall(gpGetVertexArrayiv, 3, uintptr(vaobj), uintptr(pname), uintptr(unsafe.Pointer(param)))\n}", "func constructGraph(v int) *list.List {\n\tdegree = make([]int,v)\n\tMasterList := list.New()\n\tfor i := 0; i < v; i++ {\n\t\tvar l = list.New()\n\t\tl.PushBack(i)\n\t\tMasterList.PushBack(l)\n\t}\n\treturn MasterList\n}", "func (l loader) obj2Mesh(name string, odata *objData, faces []face) (mesh *Mesh, err error) {\n\tmesh = &Mesh{}\n\tmesh.Name = name\n\tvmap := make(map[string]int) // the unique vertex data points for this face.\n\tvcnt := -1\n\n\t// process each vertex of each face. Each one represents a combination vertex,\n\t// texture coordinate, and normal.\n\tfor _, face := range faces {\n\t\tfor pi := 0; pi < 3; pi++ {\n\t\t\tfacei := face.s[pi]\n\t\t\tv, t, n := -1, -1, -1\n\t\t\tif v, t, n, err = parseFaceIndex(facei); err != nil {\n\t\t\t\treturn mesh, fmt.Errorf(\"could not parse face data %s\", err)\n\t\t\t}\n\n\t\t\t// cut down the amount of information passed around by reusing points\n\t\t\t// where the vertex and the texture coordinate information is the same.\n\t\t\tvertexIndex := fmt.Sprintf(\"%d/%d\", v, t)\n\t\t\tif _, ok := vmap[vertexIndex]; !ok {\n\n\t\t\t\t// add a new data point.\n\t\t\t\tvcnt++\n\t\t\t\tvmap[vertexIndex] = vcnt\n\t\t\t\tmesh.V = append(mesh.V, odata.v[v].x, odata.v[v].y, odata.v[v].z, 1)\n\t\t\t\tmesh.N = append(mesh.N, odata.n[n].x, odata.n[n].y, odata.n[n].z)\n\t\t\t\tif t != -1 {\n\t\t\t\t\tmesh.T = append(mesh.T, odata.t[t].u, odata.t[t].v)\n\t\t\t\t}\n\t\t\t} else {\n\n\t\t\t\t// update the normal at the vertex to be a combination of\n\t\t\t\t// all the normals of each face that shares the vertex.\n\t\t\t\tni := vmap[vertexIndex] * 3\n\t\t\t\tn1 := &lin.V3{float64(mesh.N[ni]), float64(mesh.N[ni+1]), float64(mesh.N[ni+2])}\n\t\t\t\tn2 := &lin.V3{float64(odata.n[n].x), float64(odata.n[n].y), float64(odata.n[n].z)}\n\t\t\t\tn2.Add(n2, n1).Unit()\n\t\t\t\tmesh.N[ni], mesh.N[ni+1], mesh.N[ni+2] = float32(n2.X), float32(n2.Y), float32(n2.Z)\n\t\t\t}\n\t\t\tmesh.F = append(mesh.F, uint16(vmap[vertexIndex]))\n\t\t}\n\t}\n\treturn mesh, err\n}", "func Array(dest interface{}) interface {\n\tsql.Scanner\n\tdriver.Valuer\n} {\n\tswitch dest := dest.(type) {\n\tcase *[]GraphId:\n\t\treturn (*graphIdArray)(dest)\n\tcase []GraphId:\n\t\treturn (*graphIdArray)(&dest)\n\n\tcase *[]BasicVertex:\n\t\treturn (*basicVertexArray)(dest)\n\n\tcase *[]BasicEdge:\n\t\treturn (*basicEdgeArray)(dest)\n\t}\n\n\treturn elementArray{dest}\n}", "func (g *Geometry) Initialize() {\n\tif g.handle != 0 {\n\t\treturn\n\t}\n\n\t// Determine if geometry has an index buffer\n\tif g.IndexBuffer.ComponentType != 0 {\n\t\tg.hasIndices = true\n\t}\n\n\t// Calculate number of indices\n\tif g.hasIndices {\n\t\tcompSize := componentSizeFromType(g.IndexBuffer.ComponentType)\n\t\tg.numIndices = int32(len(g.IndexBuffer.Data)) / compSize\n\t} else {\n\t\tcompSize := componentSizeFromType(g.PositionBuffer.ComponentType)\n\t\tg.numIndices = int32(len(g.PositionBuffer.Data)) / compSize\n\t}\n\n\t// Set buffer targets\n\tg.IndexBuffer.target = gl.ELEMENT_ARRAY_BUFFER\n\tg.PositionBuffer.target = gl.ARRAY_BUFFER\n\tg.NormalBuffer.target = gl.ARRAY_BUFFER\n\tg.TexCoordBuffer.target = gl.ARRAY_BUFFER\n\tg.TangentBuffer.target = gl.ARRAY_BUFFER\n\n\t// Initialize buffers\n\tg.IndexBuffer.initialize()\n\tg.PositionBuffer.initialize()\n\tg.NormalBuffer.initialize()\n\tg.TexCoordBuffer.initialize()\n\tg.TangentBuffer.initialize()\n\n\t// Create and bind VertexArray\n\tgl.GenVertexArrays(1, &g.handle)\n\tgl.BindVertexArray(g.handle)\n\n\t// Bind/enable buffers within the VertexArray\n\tg.IndexBuffer.bind()\n\tg.PositionBuffer.enable(0)\n\tg.NormalBuffer.enable(1)\n\tg.TexCoordBuffer.enable(2)\n\tg.TangentBuffer.enable(3)\n\n\tgl.BindVertexArray(0)\n}", "func DeleteVertexArrays(n int32, arrays *uint32) {\n C.glowDeleteVertexArrays(gpDeleteVertexArrays, (C.GLsizei)(n), (*C.GLuint)(unsafe.Pointer(arrays)))\n}", "func (mesh *PolyMesh) init() error {\n\n\tfor _, t := range mesh.Transform.Elems {\n\t\tmesh.transformSRT = append(mesh.transformSRT, m.TransformDecompMatrix4(t))\n\t}\n\n\tmesh.initTransformBounds()\n\n\tif mesh.PolyCount != nil {\n\t\tbasei := uint32(0)\n\t\tfor k := range mesh.PolyCount {\n\t\t\ti := uint32(0)\n\t\t\tfor j := 0; j < int(mesh.PolyCount[k]-2); j++ {\n\t\t\t\ti++\n\t\t\t\tmesh.idxp = append(mesh.idxp, uint32(mesh.FaceIdx[basei]))\n\t\t\t\tmesh.idxp = append(mesh.idxp, uint32(mesh.FaceIdx[basei+i]))\n\t\t\t\tmesh.idxp = append(mesh.idxp, uint32(mesh.FaceIdx[basei+i+1]))\n\n\t\t\t\tV0 := mesh.Verts.Elems[mesh.FaceIdx[basei]]\n\t\t\t\tV1 := mesh.Verts.Elems[mesh.FaceIdx[basei+i]]\n\t\t\t\tV2 := mesh.Verts.Elems[mesh.FaceIdx[basei+i+1]]\n\n\t\t\t\tif V0 == V1 && V0 == V2 {\n\t\t\t\t\t//log.Printf(\"nil triangle: %v %v %v %v %v\\n\", mesh.NodeName, mesh.FaceIdx[basei], V0, V1, V2)\n\t\t\t\t}\n\n\t\t\t\tif mesh.UV.Elems != nil {\n\t\t\t\t\tif mesh.UVIdx != nil { // if UVIdx doesn't exist assume same as FaceIdx\n\t\t\t\t\t\tmesh.uvtriidx = append(mesh.uvtriidx, uint32(mesh.UVIdx[basei]))\n\t\t\t\t\t\tmesh.uvtriidx = append(mesh.uvtriidx, uint32(mesh.UVIdx[basei+i]))\n\t\t\t\t\t\tmesh.uvtriidx = append(mesh.uvtriidx, uint32(mesh.UVIdx[basei+i+1]))\n\t\t\t\t\t} else {\n\t\t\t\t\t\tmesh.uvtriidx = append(mesh.uvtriidx, uint32(mesh.FaceIdx[basei]))\n\t\t\t\t\t\tmesh.uvtriidx = append(mesh.uvtriidx, uint32(mesh.FaceIdx[basei+i]))\n\t\t\t\t\t\tmesh.uvtriidx = append(mesh.uvtriidx, uint32(mesh.FaceIdx[basei+i+1]))\n\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\tif mesh.Normals.Elems != nil {\n\t\t\t\t\tif mesh.NormalIdx != nil { // if NormalIdx doesn't exist assume same as FaceIdx\n\t\t\t\t\t\tmesh.normalidx = append(mesh.normalidx, uint32(mesh.NormalIdx[basei]))\n\t\t\t\t\t\tmesh.normalidx = append(mesh.normalidx, uint32(mesh.NormalIdx[basei+i]))\n\t\t\t\t\t\tmesh.normalidx = append(mesh.normalidx, uint32(mesh.NormalIdx[basei+i+1]))\n\t\t\t\t\t} else {\n\t\t\t\t\t\tmesh.normalidx = append(mesh.normalidx, uint32(mesh.FaceIdx[basei]))\n\t\t\t\t\t\tmesh.normalidx = append(mesh.normalidx, uint32(mesh.FaceIdx[basei+i]))\n\t\t\t\t\t\tmesh.normalidx = append(mesh.normalidx, uint32(mesh.FaceIdx[basei+i+1]))\n\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\tif mesh.ShaderIdx != nil {\n\t\t\t\t\tmesh.shaderidx = append(mesh.shaderidx, uint8(mesh.ShaderIdx[k]))\n\t\t\t\t}\n\t\t\t}\n\t\t\tbasei += uint32(mesh.PolyCount[k])\n\t\t}\n\n\t} else {\n\t\t// Assume already a triangle mesh\n\t\tif mesh.FaceIdx != nil {\n\t\t\tfor j := range mesh.FaceIdx {\n\t\t\t\tmesh.idxp = append(mesh.idxp, uint32(mesh.FaceIdx[j]))\n\n\t\t\t\tif mesh.UV.Elems != nil {\n\t\t\t\t\tif mesh.UVIdx != nil {\n\t\t\t\t\t\tmesh.uvtriidx = append(mesh.uvtriidx, uint32(mesh.UVIdx[j]))\n\t\t\t\t\t} else {\n\t\t\t\t\t\tmesh.uvtriidx = append(mesh.uvtriidx, uint32(mesh.FaceIdx[j]))\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\tif mesh.Normals.Elems != nil {\n\t\t\t\t\tif mesh.NormalIdx != nil {\n\t\t\t\t\t\tmesh.normalidx = append(mesh.normalidx, uint32(mesh.NormalIdx[j]))\n\t\t\t\t\t} else {\n\t\t\t\t\t\tmesh.normalidx = append(mesh.normalidx, uint32(mesh.FaceIdx[j]))\n\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t}\n\t\t} else {\n\t\t\t// No indexes so assume the vertex array is simply the triangle verts\n\t\t\tfor j := 0; j < mesh.Verts.ElemsPerKey; j++ {\n\t\t\t\tmesh.idxp = append(mesh.idxp, uint32(j))\n\n\t\t\t\tif mesh.UV.Elems != nil {\n\t\t\t\t\tif mesh.UVIdx != nil {\n\t\t\t\t\t\tmesh.uvtriidx = append(mesh.uvtriidx, uint32(mesh.UVIdx[j]))\n\t\t\t\t\t} else {\n\t\t\t\t\t\tmesh.uvtriidx = append(mesh.uvtriidx, uint32(j))\n\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\tif mesh.Normals.Elems != nil {\n\t\t\t\t\tif mesh.NormalIdx != nil {\n\t\t\t\t\t\tmesh.normalidx = append(mesh.normalidx, uint32(mesh.NormalIdx[j]))\n\t\t\t\t\t} else {\n\t\t\t\t\t\tmesh.normalidx = append(mesh.normalidx, uint32(j))\n\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t}\n\t\t}\n\n\t\tfor _, idx := range mesh.ShaderIdx {\n\t\t\tmesh.shaderidx = append(mesh.shaderidx, uint8(idx))\n\t\t}\n\n\t}\n\n\tmesh.FaceIdx = nil\n\tmesh.PolyCount = nil\n\tmesh.UVIdx = nil\n\tmesh.NormalIdx = nil\n\tmesh.ShaderIdx = nil\n\n\treturn nil\n}", "func DrawElementsBaseVertex(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, basevertex int32) {\n C.glowDrawElementsBaseVertex(gpDrawElementsBaseVertex, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLint)(basevertex))\n}", "func Constructor(length int) SnapshotArray {\n\ts := make([]map[int]int, 0, 128)\n\tc := make(map[int]int, 32)\n\treturn SnapshotArray{\n\t\tsnaps: s,\n\t\tcurrent: c,\n\t\tid: 0,\n\t}\n}", "func createBatch(xs []*storobj.Object) indexedBatch {\n\tvar bi indexedBatch\n\tbi.Data = xs\n\tbi.Index = make([]int, len(xs))\n\tfor i := 0; i < len(xs); i++ {\n\t\tbi.Index[i] = i\n\t}\n\treturn bi\n}", "func CreateShaderProgramv(xtype uint32, count int32, strings **int8) uint32 {\n ret := C.glowCreateShaderProgramv(gpCreateShaderProgramv, (C.GLenum)(xtype), (C.GLsizei)(count), (**C.GLchar)(unsafe.Pointer(strings)))\n return (uint32)(ret)\n}", "func DrawElementsBaseVertex(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, basevertex int32) {\n\tsyscall.Syscall6(gpDrawElementsBaseVertex, 5, uintptr(mode), uintptr(count), uintptr(xtype), uintptr(indices), uintptr(basevertex), 0)\n}", "func VertexPointer(size int32, xtype uint32, stride int32, pointer unsafe.Pointer) {\n C.glowVertexPointer(gpVertexPointer, (C.GLint)(size), (C.GLenum)(xtype), (C.GLsizei)(stride), pointer)\n}", "func Create(rows, cols int) (grid Grid) {\n\tgrid = make([][]*Point, rows)\n\tfor i := range grid {\n\t\tgrid[i] = make([]*Point, cols)\n\t}\n\tfor row := 0; row < rows; row++ {\n\t\tfor col := 0; col < cols; col++ {\n\t\t\tpoint := Point{row, col}\n\t\t\tgrid[row][col] = &point\n\t\t}\n\t}\n\treturn\n}", "func New(values ...interface{}) Array {\n\tarray := Array{}\n\tarray = array.Push(values...)\n\treturn array\n}", "func DrawElementsInstancedBaseVertex(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32, basevertex int32) {\n C.glowDrawElementsInstancedBaseVertex(gpDrawElementsInstancedBaseVertex, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLsizei)(instancecount), (C.GLint)(basevertex))\n}", "func NewDigraph(vertices int, arr []rune) *Digraph {\n\tvar digraph Digraph\n\tdigraph.nodes = vertices\n\tdigraph.edges = make([]*Bag, vertices)\n\tfor _, v := range arr {\n\t\tdigraph.edges[v] = NewBag() // arr[0] = bag{1,2,3}; arr[1] = bag{0,5};\n\t}\n\treturn &digraph\n}", "func NewVertex(key int) *Vertex {\n\treturn &Vertex{\n\t\tKey: key,\n\t\tVertices: map[int]*Vertex{},\n\t}\n}", "func NewVertex(key int) *Vertex {\n\treturn &Vertex{\n\t\tKey: key,\n\t\tVertices: map[int]*Vertex{},\n\t}\n}", "func (vao VertexArrayObject) VertexAttribPointer(attrIndex int, attrType Type, normalized bool, byteStride int, byteOffset int) {\n\tglx := vao.glx\n\tbufferType, bufferItemsPerVertex, err := attrType.asAttribute()\n\tif err != nil {\n\t\tpanic(fmt.Errorf(\"converting attribute type %s to attribute: %w\", attrType, err))\n\t}\n\tglx.constants.VertexAttribPointer(\n\t\tglx.factory.Number(float64(attrIndex)),\n\t\tglx.factory.Number(float64(bufferItemsPerVertex)),\n\t\tglx.typeConverter.ToJs(bufferType),\n\t\tglx.factory.Boolean(normalized),\n\t\tglx.factory.Number(float64(byteStride)),\n\t\tglx.factory.Number(float64(byteOffset)),\n\t)\n}", "func MakeMesh(name string, dims int, prim uint32, pos, cols, nrms interface{}, texcoords []interface{}, elems interface{}) (*Mesh, error) {\n\tvar (\n\t\tposarr, colarr, nrmarr *AttribArray\n\t\ttexcarr = make([]*AttribArray, len(texcoords))\n\t\telemarr *ElementArray\n\n\t\tmesh = NewMesh(name)\n\n\t\terr error\n\t)\n\n\tdefer func() {\n\t\tif err != nil {\n\t\t\tposarr.Clean()\n\t\t\tcolarr.Clean()\n\t\t\tnrmarr.Clean()\n\t\t\tfor _, arr := range texcarr {\n\t\t\t\tarr.Clean()\n\t\t\t}\n\t\t\telemarr.Clean()\n\t\t}\n\t}()\n\n\tif pos == nil {\n\t\tpanic(fmt.Errorf(\"MakeMesh error: Mesh '%s' must have a 'pos' attribute\", name))\n\t} else {\n\t\tcheckSlice(name, \"pos\", pos)\n\n\t\tposarr, err = NewAttribArray(\"pos\", dims, pos, gl.STATIC_DRAW)\n\t\tif err != nil {\n\t\t\treturn nil, err\n\t\t}\n\t}\n\tif cols != nil {\n\t\tcheckSlice(name, \"color\", cols)\n\n\t\tcolarr, err = NewAttribArray(\"color\", 4, cols, gl.STATIC_DRAW)\n\t\tif err != nil {\n\t\t\treturn nil, err\n\t\t}\n\t}\n\tif nrms != nil {\n\t\tcheckSlice(name, \"normal\", cols)\n\n\t\tcolarr, err = NewAttribArray(\"normal\", 3, nrms, gl.STATIC_DRAW)\n\t\tif err != nil {\n\t\t\treturn nil, err\n\t\t}\n\t}\n\tfor i, texcoord := range texcoords {\n\t\tvar texname = fmt.Sprintf(\"texcoord%d\", i)\n\t\tcheckSlice(name, texname, texcoord)\n\n\t\ttexcarr[i], err = NewAttribArray(texname, 2, texcoord, gl.STATIC_DRAW)\n\t\tif err != nil {\n\t\t\treturn nil, err\n\t\t}\n\t}\n\tif elems == nil {\n\t\tpanic(fmt.Errorf(\"MakeMesh error: no element array for Mesh '%s'\", name))\n\t} else {\n\t\tcheckSlice(name, \"elems\", elems)\n\n\t\telemarr, err = NewElementArray(elems, gl.STATIC_DRAW)\n\t\tif err != nil {\n\t\t\treturn nil, err\n\t\t}\n\t}\n\n\tif err = mesh.AddArrays(posarr, colarr, nrmarr); err != nil {\n\t\treturn nil, err\n\t}\n\tif err = mesh.AddArrays(texcarr...); err != nil {\n\t\treturn nil, err\n\t}\n\n\tmesh.Elements = elemarr\n\tmesh.Primitive = prim\n\n\treturn mesh, nil\n}", "func (m *TriangleMesh) MakeBoxVertices() (verts [8]mgl.Vec4) {\n\tbottomLeft, topRight := m.BoundingBox()\n\n\tvar i int\n\tbounds := [2]mgl.Vec4{bottomLeft, topRight}\n\tfor x := 0; x <= 1; x++ {\n\t\tfor y := 0; y <= 1; y++ {\n\t\t\tfor z := 0; z <= 1; z++ {\n\t\t\t\tverts[i][0] = bounds[x][0]\n\t\t\t\tverts[i][1] = bounds[y][1]\n\t\t\t\tverts[i][2] = bounds[z][2]\n\t\t\t\tverts[i][3] = 1\n\t\t\t\ti++\n\t\t\t}\n\t\t}\n\t}\n\treturn\n}", "func ShapeToVertexList(s string) (vertexList []shared.Point2d, length int) {\n\tvar stringArray = StringToStringArray(s)\n\tvar currentPosX = 0\n\tvar currentPosY = 0\n\tvar startPosX = 0\n\tvar startPosY = 0\n\tvar index = 0\n\tvar l float64\n\n\tfor index < len(stringArray) {\n\t\tswitch stringArray[index] {\n\t\tcase \"M\", \"L\", \"m\", \"l\":\n\t\t\ttempX, err := strconv.Atoi(stringArray[index+1])\n\t\t\ttempY, err := strconv.Atoi(stringArray[index+2])\n\t\t\tif err != nil {\n\t\t\t\tfmt.Println(\"Invalid SVG String\")\n\t\t\t\t// TODO: return InvalidShapeSvgStringError\n\t\t\t}\n\n\t\t\t// Uppercase = absolute pos, lowercase = relative pos\n\t\t\tif stringArray[index] == \"M\" {\n\t\t\t\tstartPosX = tempX\n\t\t\t\tstartPosY = tempY\n\t\t\t\tcurrentPosX = tempX\n\t\t\t\tcurrentPosY = tempY\n\t\t\t} else if stringArray[index] == \"m\" {\n\t\t\t\tstartPosX += tempX\n\t\t\t\tstartPosY += tempY\n\t\t\t\tcurrentPosX += tempX\n\t\t\t\tcurrentPosY += tempY\n\t\t\t} else if stringArray[index] == \"L\" {\n\t\t\t\t// need to calculate the length of x and y\n\t\t\t\tx := math.Abs(float64(currentPosX - tempX))\n\t\t\t\ty := math.Abs(float64(currentPosY - tempY))\n\t\t\t\tl += math.Sqrt(x*x + y*y)\n\t\t\t\tcurrentPosX = tempX\n\t\t\t\tcurrentPosY = tempY\n\t\t\t} else {\n\t\t\t\tl += math.Sqrt(float64(tempX*tempX + tempY*tempY))\n\t\t\t\tcurrentPosX += tempX\n\t\t\t\tcurrentPosY += tempY\n\t\t\t}\n\n\t\t\tindex += 3\n\t\tcase \"H\", \"h\":\n\t\t\ttempX, err := strconv.Atoi(stringArray[index+1])\n\t\t\tif err != nil {\n\t\t\t\tfmt.Println(\"Invalid SVG String\")\n\t\t\t\t// TODO: return InvalidShapeSvgStringError\n\t\t\t}\n\n\t\t\tif stringArray[index] == \"H\" {\n\t\t\t\tx := math.Abs(float64(currentPosX - tempX))\n\t\t\t\tl += x\n\t\t\t\tcurrentPosX = tempX\n\t\t\t} else {\n\t\t\t\tl += math.Abs(float64(tempX))\n\t\t\t\tcurrentPosX += tempX\n\t\t\t}\n\n\t\t\tindex += 2\n\t\tcase \"V\", \"v\":\n\t\t\ttempY, err := strconv.Atoi(stringArray[index+1])\n\t\t\tif err != nil {\n\t\t\t\tfmt.Println(\"Invalid SVG String\")\n\t\t\t\t// TODO: return InvalidShapeSvgStringError\n\t\t\t}\n\n\t\t\tif stringArray[index] == \"V\" {\n\t\t\t\ty := math.Abs(float64(currentPosY - tempY))\n\t\t\t\tl += y\n\t\t\t\tcurrentPosY = tempY\n\t\t\t} else {\n\t\t\t\tl += math.Abs(float64(tempY))\n\t\t\t\tcurrentPosY += tempY\n\t\t\t}\n\n\t\t\tindex += 2\n\t\tcase \"Z\", \"z\":\n\t\t\tx := math.Abs(float64(currentPosX - startPosX))\n\t\t\ty := math.Abs(float64(currentPosY - startPosY))\n\t\t\tl += math.Sqrt(x*x + y*y)\n\t\t\tcurrentPosX = startPosX\n\t\t\tcurrentPosY = startPosY\n\n\t\t\tindex++\n\t\tdefault:\n\t\t\tfmt.Println(\"unsupported svg command\")\n\t\t\t// TODO: return InvalidShapeSvgStringError\n\t\t\tindex++\n\t\t}\n\t\t// Adding a new vertex\n\t\tpoint := shared.Point2d{X: currentPosX, Y: currentPosY}\n\t\tvertexList = append(vertexList, point)\n\t}\n\tlength = int(math.Ceil(l))\n\treturn vertexList, length\n}", "func MultiDrawElementsBaseVertex(mode uint32, count *int32, xtype uint32, indices *unsafe.Pointer, drawcount int32, basevertex *int32) {\n\tC.glowMultiDrawElementsBaseVertex(gpMultiDrawElementsBaseVertex, (C.GLenum)(mode), (*C.GLsizei)(unsafe.Pointer(count)), (C.GLenum)(xtype), indices, (C.GLsizei)(drawcount), (*C.GLint)(unsafe.Pointer(basevertex)))\n}", "func MultiDrawElementsBaseVertex(mode uint32, count *int32, xtype uint32, indices *unsafe.Pointer, drawcount int32, basevertex *int32) {\n\tC.glowMultiDrawElementsBaseVertex(gpMultiDrawElementsBaseVertex, (C.GLenum)(mode), (*C.GLsizei)(unsafe.Pointer(count)), (C.GLenum)(xtype), indices, (C.GLsizei)(drawcount), (*C.GLint)(unsafe.Pointer(basevertex)))\n}", "func (vao *VAO) BuildBuffers(shaderProgramHandle uint32) {\n\tgl.BindVertexArray(vao.handle)\n\tfor _, vbo := range vao.vertexBuffers {\n\t\tvbo.BuildVertexAttributes(shaderProgramHandle)\n\t}\n\tgl.BindVertexArray(0)\n}", "func (p *Polygon) Vertices() []v2.Vec {\n\tif p.vlist == nil {\n\t\treturn nil\n\t}\n\tp.fixups()\n\tn := len(p.vlist)\n\tv := make([]v2.Vec, n)\n\tif p.reverse {\n\t\tfor i, pv := range p.vlist {\n\t\t\tv[n-1-i] = pv.vertex\n\t\t}\n\t} else {\n\t\tfor i, pv := range p.vlist {\n\t\t\tv[i] = pv.vertex\n\t\t}\n\t}\n\treturn v\n}", "func (p Plane) GetVertices() VertexValues {\n\treturn p.vertexValues\n}", "func createGraph3() *NodeG {\n n1 := NodeG{1, nil}\n n2 := NodeG{2, nil}\n n3 := NodeG{3, nil}\n n1.neighbors = append(n1.neighbors, &n2)\n n2.neighbors = append(n2.neighbors, &n3)\n\n return &n1\n}", "func makerectangle(i int, j int, g *Graph) error {\n\tnodes := i * j //number of vertices\n\n\tif g.numvert < nodes {\n\t\t_, err := g.addVertices(nodes - g.numvert)\n\t\tif err != nil {\n\t\t\tlog.Fatal(err)\n\t\t}\n\t}\n\tif g.numvert > nodes {\n\t\tlog.Fatal(\"Too many vertices\")\n\t}\n\n\tfrom := 1\n\tto := 2\n\trun := false\n\tdone := false\n\tfor !done {\n\t\ta := Vertex{vert: from}\n\t\tb := Vertex{vert: to}\n\t\tg.addEdge(a, b)\n\t\tfrom++\n\t\tto++\n\t\tif from%j == 0 && !run {\n\t\t\tfrom++\n\t\t\tto++\n\t\t}\n\t\tif run && to > nodes {\n\t\t\tdone = true\n\t\t}\n\t\tif to > nodes {\n\t\t\tfrom = 1\n\t\t\tto = 1 + j\n\t\t\trun = true\n\t\t}\n\t}\n\treturn nil\n}", "func (obj *Device) CreateVertexBuffer(\n\tlength uint,\n\tusage uint32,\n\tfvf uint32,\n\tpool POOL,\n\tsharedHandle uintptr,\n) (*VertexBuffer, Error) {\n\tvar buf *VertexBuffer\n\tret, _, _ := syscall.Syscall9(\n\t\tobj.vtbl.CreateVertexBuffer,\n\t\t7,\n\t\tuintptr(unsafe.Pointer(obj)),\n\t\tuintptr(length),\n\t\tuintptr(usage),\n\t\tuintptr(fvf),\n\t\tuintptr(pool),\n\t\tuintptr(unsafe.Pointer(&buf)),\n\t\tsharedHandle,\n\t\t0,\n\t\t0,\n\t)\n\treturn buf, toErr(ret)\n}" ]
[ "0.6589813", "0.6495918", "0.63804567", "0.62176603", "0.6144809", "0.61154735", "0.59852725", "0.5971669", "0.5915343", "0.58975786", "0.58973837", "0.58699673", "0.5839336", "0.5835183", "0.58284754", "0.5784197", "0.5784197", "0.5729416", "0.57243514", "0.56546414", "0.5621497", "0.5598853", "0.5592495", "0.5566303", "0.55311793", "0.55290395", "0.5465227", "0.5465227", "0.54607904", "0.5433998", "0.54067", "0.53856236", "0.5358854", "0.53431237", "0.5339447", "0.52923656", "0.5275912", "0.526508", "0.5246392", "0.5242597", "0.5220633", "0.5207332", "0.5204395", "0.5204395", "0.51890844", "0.5161302", "0.5140867", "0.5122898", "0.5113589", "0.51042604", "0.510307", "0.51017416", "0.50974905", "0.50921124", "0.50555027", "0.5050601", "0.50504667", "0.5044925", "0.5026729", "0.5026729", "0.502386", "0.502386", "0.5020095", "0.5016769", "0.50149435", "0.5013873", "0.50060743", "0.50060743", "0.49869886", "0.49587375", "0.49572727", "0.49442115", "0.49436054", "0.49419683", "0.4929146", "0.49245486", "0.49233484", "0.4905934", "0.4888466", "0.48870605", "0.4883428", "0.48800322", "0.48763695", "0.48749617", "0.48708475", "0.48656625", "0.48656625", "0.48651648", "0.48623434", "0.48584643", "0.48558384", "0.48557433", "0.48557433", "0.48514202", "0.48343608", "0.4826962", "0.48216346", "0.48158035", "0.4809817" ]
0.6113562
7
specify whether front or backfacing facets can be culled
func CullFace(mode uint32) { C.glowCullFace(gpCullFace, (C.GLenum)(mode)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func FrontFace(mode Enum) {\n\tgl.FrontFace(uint32(mode))\n}", "func FrontFace(mode GLenum) {\n\tC.glFrontFace(C.GLenum(mode))\n}", "func FrontFace(mode uint32) {\n\tsyscall.Syscall(gpFrontFace, 1, uintptr(mode), 0, 0)\n}", "func FrontFace(mode uint32) {\n C.glowFrontFace(gpFrontFace, (C.GLenum)(mode))\n}", "func (self *Graphics) AutoCull() bool{\n return self.Object.Get(\"autoCull\").Bool()\n}", "func FrontFace(mode uint32) {\n\tC.glowFrontFace(gpFrontFace, (C.GLenum)(mode))\n}", "func FrontFace(mode uint32) {\n\tC.glowFrontFace(gpFrontFace, (C.GLenum)(mode))\n}", "func SetFrontFace(mode Enum) {\n\tcmode, _ := (C.GLenum)(mode), cgoAllocsUnknown\n\tC.glFrontFace(cmode)\n}", "func (self *Graphics) FixedToCamera() bool{\n return self.Object.Get(\"fixedToCamera\").Bool()\n}", "func (me TaltitudeModeEnumType) IsClampToGround() bool { return me == \"clampToGround\" }", "func (c *Context) FrontFace(o gfx.Orientation) gfx.ContextStateValue {\n\treturn s.CSV{\n\t\tValue: c.Enums[int(o)],\n\t\tDefaultValue: c.O.Get(\"CCW\").Int(), // TODO(slimsag): verify\n\t\tKey: csFrontFace,\n\t\tGLCall: c.glFrontFace,\n\t}\n}", "func (c *Car) CanShow() bool {\n if e := os.Getenv(\"BULLETTRAIN_CAR_VIRTUALENV_SHOW\"); e == \"false\" {\n return false\n }\n\n // Show when \"VIRTUAL_ENV\" exist in environment variables\n if e := os.Getenv(\"VIRTUAL_ENV\"); e != \"\" {\n return true\n }\n\n return false\n}", "func (p *Plane3D) isBounded() bool {\n\n\treturn false\n}", "func CullFace(mode uint32) {\n C.glowCullFace(gpCullFace, (C.GLenum)(mode))\n}", "func (self *Graphics) InCamera() bool{\n return self.Object.Get(\"inCamera\").Bool()\n}", "func CullFace(mode Enum) {\n\tgl.CullFace(uint32(mode))\n}", "func (me TviewRefreshModeEnumType) IsOnRegion() bool { return me == \"onRegion\" }", "func (c *Context) CullFace(f gfx.Facet) gfx.ContextStateValue {\n\treturn s.CSV{\n\t\tValue: c.Enums[int(f)],\n\t\tDefaultValue: c.O.Get(\"FRONT\").Int(), // TODO(slimsag): verify\n\t\tKey: csCullFace,\n\t\tGLCall: c.glCullFace,\n\t}\n}", "func (i *Resource) Facet(key string) (string, bool) {\n\tval, ok := i.data.Facets[key]\n\treturn val, ok\n}", "func validTransportMode(v *validator.Validate, topStruct reflect.Value, currentStructOrField reflect.Value,\n\tfield reflect.Value, fieldType reflect.Type, fieldKind reflect.Kind, param string) bool {\n\tval := strings.ToLower(field.String())\n\tif val == \"air\" || val == \"road\" || val == \"ship\" {\n\t\treturn true\n\t}\n\treturn false\n}", "func (self *TileSprite) AutoCull() bool{\n return self.Object.Get(\"autoCull\").Bool()\n}", "func (me TaltitudeModeEnumType) IsRelativeToGround() bool { return me == \"relativeToGround\" }", "func setShowInList(infos map[string]*FeatureInfo, inclExperimental bool, gateName string) {\n\tfor _, v := range infos {\n\t\t// Only discoverable features can be listed.\n\t\tv.ShowInList = v.Discoverable\n\n\t\t// Experimental features are not listed by default, but can be listed via flag.\n\t\tif v.Stability == corev1alpha2.Experimental {\n\t\t\tv.ShowInList = inclExperimental\n\t\t}\n\n\t\t// If FeatureGate is specified, delist the Features not gated.\n\t\tif gateName != \"\" && v.FeatureGate != gateName {\n\t\t\tv.ShowInList = false\n\t\t}\n\t}\n}", "func CullFace(mode uint32) {\n\tsyscall.Syscall(gpCullFace, 1, uintptr(mode), 0, 0)\n}", "func TestTorusInterior(t *testing.T) {\n p := []float64{0, 0, 0}\n v := []float64{0, 0, 1}\n var R, r float64 = 2, 1\n\n torus := NewTorus(p, v, R, r)\n\n if torus == nil {\n t.Error(\"torus error: torus should exist but is nil!!!!\") \n return \n }\n\n if surface.SurfaceInterior(torus, p) {\n t.Error(\"torus error: torus is inside-out 1! \", torus.F(p)) \n }\n\n if !surface.SurfaceInterior(torus, []float64{2, 0, 0}) {\n t.Error(\"torus error: torus is inside-out 2! \", torus.F([]float64{2, 0, 0})) \n }\n}", "func FlyToView(value bool) *SimpleElement { return newSEBool(\"flyToView\", value) }", "func (me TshapeEnumType) IsCylinder() bool { return me == \"cylinder\" }", "func CullFace(mode GLenum) {\n\tC.glCullFace(C.GLenum(mode))\n}", "func (d Data) FaceLeft() bool {\n\treturn d.faceLeft\n}", "func (outer outer) Visible() bool {\r\n\treturn false\r\n}", "func (me TaltitudeModeEnumType) IsAbsolute() bool { return me == \"absolute\" }", "func (me TxsdFeBlendTypeMode) IsLighten() bool { return me.String() == \"lighten\" }", "func (g *G1) IsOnG1() bool { return g.isValidProjective() && g.isOnCurve() && g.isRTorsion() }", "func doUpdateVisibleCollider(colliderRenderables []*colliderRenderable, collider *component.CollisionRef, colliderIndex int) []*colliderRenderable {\n\t// is the collider index within the length of renderables we have? If so, update it.\n\tif len(colliderRenderables) > colliderIndex {\n\t\tvisCollider := colliderRenderables[colliderIndex]\n\n\t\tswitch collider.Type {\n\t\tcase component.ColliderTypeAABB:\n\t\t\tif !visCollider.Collider.Min.ApproxEqual(collider.Min) ||\n\t\t\t\t!visCollider.Collider.Max.ApproxEqual(collider.Max) ||\n\t\t\t\tvisCollider.Collider.Type != collider.Type {\n\t\t\t\tvisCollider.Collider = *collider\n\t\t\t\tvisCollider.Renderable = fizzle.CreateWireframeCube(collider.Min[0], collider.Min[1], collider.Min[2],\n\t\t\t\t\tcollider.Max[0], collider.Max[1], collider.Max[2])\n\t\t\t\tvisCollider.Renderable.Material = wireframeMaterial\n\t\t\t}\n\t\tcase component.ColliderTypeSphere:\n\t\t\tif !visCollider.Collider.Offset.ApproxEqual(collider.Offset) ||\n\t\t\t\tmath.Abs(float64(visCollider.Collider.Radius-collider.Radius)) > 0.01 ||\n\t\t\t\tvisCollider.Collider.Type != collider.Type {\n\t\t\t\tvisCollider.Collider = *collider\n\t\t\t\tvisCollider.Renderable = fizzle.CreateWireframeCircle(\n\t\t\t\t\tcollider.Offset[0], collider.Offset[1], collider.Offset[2], collider.Radius, segsInSphereWire, fizzle.X|fizzle.Y)\n\t\t\t\tvisCollider.Renderable.Material = wireframeMaterial\n\n\t\t\t\tcircle2 := fizzle.CreateWireframeCircle(\n\t\t\t\t\tcollider.Offset[0], collider.Offset[1], collider.Offset[2], collider.Radius, segsInSphereWire, fizzle.Y|fizzle.Z)\n\t\t\t\tcircle2.Material = wireframeMaterial\n\t\t\t\tvisCollider.Renderable.AddChild(circle2)\n\t\t\t\tcircle3 := fizzle.CreateWireframeCircle(\n\t\t\t\t\tcollider.Offset[0], collider.Offset[1], collider.Offset[2], collider.Radius, segsInSphereWire, fizzle.X|fizzle.Z)\n\t\t\t\tcircle3.Material = wireframeMaterial\n\t\t\t\tvisCollider.Renderable.AddChild(circle3)\n\t\t\t}\n\t\t}\n\t} else {\n\t\t// append a new visible collider\n\t\tvisCollider := new(colliderRenderable)\n\t\tvisCollider.Collider = *collider\n\n\t\tswitch collider.Type {\n\t\tcase component.ColliderTypeAABB:\n\t\t\tvisCollider.Renderable = fizzle.CreateWireframeCube(collider.Min[0], collider.Min[1], collider.Min[2],\n\t\t\t\tcollider.Max[0], collider.Max[1], collider.Max[2])\n\t\t\tvisCollider.Renderable.Material = wireframeMaterial\n\t\tcase component.ColliderTypeSphere:\n\t\t\tvisCollider.Renderable = fizzle.CreateWireframeCircle(\n\t\t\t\tcollider.Offset[0], collider.Offset[1], collider.Offset[2], collider.Radius, segsInSphereWire, fizzle.X|fizzle.Y)\n\t\t\tcircle2 := fizzle.CreateWireframeCircle(\n\t\t\t\tcollider.Offset[0], collider.Offset[1], collider.Offset[2], collider.Radius, segsInSphereWire, fizzle.Y|fizzle.Z)\n\t\t\tcircle2.Material = wireframeMaterial\n\t\t\tvisCollider.Renderable.AddChild(circle2)\n\t\t\tcircle3 := fizzle.CreateWireframeCircle(\n\t\t\t\tcollider.Offset[0], collider.Offset[1], collider.Offset[2], collider.Radius, segsInSphereWire, fizzle.X|fizzle.Z)\n\t\t\tcircle3.Material = wireframeMaterial\n\t\t\tvisCollider.Renderable.AddChild(circle3)\n\t\t}\n\n\t\tcolliderRenderables = append(colliderRenderables, visCollider)\n\t}\n\n\treturn colliderRenderables\n}", "func (p *FloatGray) Opaque() bool {\n return true\n}", "func (m *Mesh) FaceOrientations() []map[*Triangle]bool {\n\torientations := m.maybeFaceOrientations()\n\tif orientations == nil {\n\t\tpanic(\"mesh is not orientable\")\n\t}\n\treturn orientations\n}", "func (me TcolorModeEnumType) IsNormal() bool { return me == \"normal\" }", "func (me TxsdViewTypeZoomAndPan) IsDisable() bool { return me.String() == \"disable\" }", "func (me TviewRefreshModeEnumType) IsOnStop() bool { return me == \"onStop\" }", "func FIPSEnabled() bool { return true }", "func boolEncoder(e *encodeState, v reflect.Value) error {\n\tsz := e.size\n\tfactor := .25\n\tfactorD2 := factor / 2\n\th := sz * (1 - factor)\n\tcolor := \"black\"\n\n\tval := v.Bool()\n\n\t// y = sin(1/3 * pi)*h for making equilateral triangle\n\tsinY := 0.866 * h\n\n\tx1, x2, x3 := sz*factorD2, sz/2, sz*(1-factorD2)\n\thi, lo := x1, sinY+x1\n\n\tif val == false {\n\t\thi, lo = lo, hi\n\t\tcolor = \"red\"\n\t}\n\n\tpts := []gosvg.Point{{x1, lo}, {x2, hi}, {x3, lo}}\n\tp := e.Polygon(pts...)\n\tp.Style.Set(\"stroke-width\", \"0\")\n\tp.Style.Set(\"fill\", color)\n\n\treturn nil\n}", "func (self *Tween) FrameBased() bool{\n return self.Object.Get(\"frameBased\").Bool()\n}", "func SetCullFace(mode Enum) {\n\tcmode, _ := (C.GLenum)(mode), cgoAllocsUnknown\n\tC.glCullFace(cmode)\n}", "func (self *Graphics) SetAutoCullA(member bool) {\n self.Object.Set(\"autoCull\", member)\n}", "func (ref *UIElement) IsFrontmost() bool {\n\tret, _ := ref.BoolAttr(FrontmostAttribute)\n\treturn ret\n}", "func (o *Vm) HasFlavour() bool {\n\tif o != nil && o.Flavour != nil {\n\t\treturn true\n\t}\n\n\treturn false\n}", "func (self *TileSprite) FixedToCamera() bool{\n return self.Object.Get(\"fixedToCamera\").Bool()\n}", "func (e Empty) Visible(v bool) { e.visible = v }", "func (me TxsdPresentationAttributesGraphicsDisplay) IsCompact() bool { return me.String() == \"compact\" }", "func (npef NativePushEnabledFilter) AsEngageSubsetFilter() (*EngageSubsetFilter, bool) {\n\treturn nil, false\n}", "func (me TxsdFeConvolveMatrixTypeEdgeMode) IsWrap() bool { return me.String() == \"wrap\" }", "func (o *ColorPicker) ArePresetsVisible() gdnative.Bool {\n\t//log.Println(\"Calling ColorPicker.ArePresetsVisible()\")\n\n\t// Build out the method's arguments\n\tptrArguments := make([]gdnative.Pointer, 0, 0)\n\n\t// Get the method bind\n\tmethodBind := gdnative.NewMethodBind(\"ColorPicker\", \"are_presets_visible\")\n\n\t// Call the parent method.\n\t// bool\n\tretPtr := gdnative.NewEmptyBool()\n\tgdnative.MethodBindPtrCall(methodBind, o.GetBaseObject(), ptrArguments, retPtr)\n\n\t// If we have a return type, convert it from a pointer into its actual object.\n\tret := gdnative.NewBoolFromPointer(retPtr)\n\treturn ret\n}", "func (f *FlagBase[T, C, V]) IsVisible() bool {\n\treturn !f.Hidden\n}", "func (me TxsdFeBlendTypeMode) IsNormal() bool { return me.String() == \"normal\" }", "func (me TxsdComponentTransferFunctionAttributesType) IsGamma() bool { return me.String() == \"gamma\" }", "func (me TshapeEnumType) IsSphere() bool { return me == \"sphere\" }", "func (b *button) setVisible(visible bool) { b.model.Cull(!visible) }", "func (me TgridOriginEnumType) IsLowerLeft() bool { return me == \"lowerLeft\" }", "func (k Feature_Kind) IsCategorical() bool { return k == Feature_CATEGORICAL }", "func isGraphColouredProperly(graph [][]bool, V int, colour []int, v int, c int) bool {\n\tfor i := 0; i < V; i++ {\n\t\tif graph[v][i] && c == colour[i] {\n\t\t\treturn false\n\t\t}\n\t}\n\treturn true\n}", "func updateVisibleMesh(compRenderable *meshRenderable) {\n\t// push all settings from the component to the renderable\n\tcompRenderable.Renderable.Location = compRenderable.ComponentMesh.Offset\n\tcompRenderable.Renderable.Scale = compRenderable.ComponentMesh.Scale\n\tcompRenderable.Renderable.Material.DiffuseColor = compRenderable.ComponentMesh.Material.Diffuse\n\tif compRenderable.ComponentMesh.RotationDegrees != 0.0 {\n\t\tcompRenderable.Renderable.LocalRotation = mgl.QuatRotate(\n\t\t\tmgl.DegToRad(compRenderable.ComponentMesh.RotationDegrees),\n\t\t\tcompRenderable.ComponentMesh.RotationAxis)\n\t}\n\n\tcompRenderable.Renderable.Material.SpecularColor = compRenderable.ComponentMesh.Material.Specular\n\tcompRenderable.Renderable.Material.Shininess = compRenderable.ComponentMesh.Material.Shininess\n\n\t// try to find a shader\n\tshader, shaderFound := shaders[compRenderable.ComponentMesh.Material.ShaderName]\n\tif shaderFound {\n\t\tcompRenderable.Renderable.Material.Shader = shader\n\t}\n\n\t// assign textures\n\ttextures := compRenderable.ComponentMesh.Material.Textures\n\tfor i := 0; i < len(textures); i++ {\n\t\tglTex, texFound := textureMan.GetTexture(textures[i])\n\t\tif texFound && i < fizzle.MaxCustomTextures {\n\t\t\tcompRenderable.Renderable.Material.CustomTex[i] = glTex\n\t\t}\n\t}\n\tif len(compRenderable.ComponentMesh.Material.DiffuseTexture) > 0 {\n\t\tglTex, texFound := textureMan.GetTexture(compRenderable.ComponentMesh.Material.DiffuseTexture)\n\t\tif texFound {\n\t\t\tcompRenderable.Renderable.Material.DiffuseTex = glTex\n\t\t}\n\t}\n\tif len(compRenderable.ComponentMesh.Material.NormalsTexture) > 0 {\n\t\tglTex, texFound := textureMan.GetTexture(compRenderable.ComponentMesh.Material.NormalsTexture)\n\t\tif texFound {\n\t\t\tcompRenderable.Renderable.Material.NormalsTex = glTex\n\t\t}\n\t}\n\tif len(compRenderable.ComponentMesh.Material.SpecularTexture) > 0 {\n\t\tglTex, texFound := textureMan.GetTexture(compRenderable.ComponentMesh.Material.SpecularTexture)\n\t\tif texFound {\n\t\t\tcompRenderable.Renderable.Material.SpecularTex = glTex\n\t\t}\n\t}\n\n}", "func (v *Layer) IsVisible() bool {\n\treturn v != nil\n}", "func (me TdisplayModeEnumType) IsHide() bool { return me == \"hide\" }", "func (me TxsdFeCompositeTypeOperator) IsOver() bool { return me.String() == \"over\" }", "func (i *Resource) initUserFacets(in map[string]string) {\n\ti.data.Facets = in\n}", "func (self *Graphics) Fresh() bool{\n return self.Object.Get(\"fresh\").Bool()\n}", "func (self *Graphics) DestroyPhase() bool{\n return self.Object.Get(\"destroyPhase\").Bool()\n}", "func (pqf PushQuotaFilter) AsEngageSubsetFilter() (*EngageSubsetFilter, bool) {\n\treturn nil, false\n}", "func (me TstyleStateEnumType) IsHighlight() bool { return me == \"highlight\" }", "func getAbsAxis(v Vector) []bool {\n\taxes := make([]bool, 3)\n\t\n\taxes[X] = v.X == 0\n\taxes[Y] = v.Y == 0\n\taxes[Z] = v.Z == 0\n\t\n\treturn axes\n}", "func (m *Mesh) Orientable() bool {\n\treturn m.maybeFaceOrientations() != nil\n}", "func (me TgridOriginEnumType) IsUpperLeft() bool { return me == \"upperLeft\" }", "func (self *Graphics) SetFixedToCameraA(member bool) {\n self.Object.Set(\"fixedToCamera\", member)\n}", "func (aif AppInfoFilter) AsEngageSubsetFilter() (*EngageSubsetFilter, bool) {\n\treturn nil, false\n}", "func (p *Gray16) Opaque() bool {\n\treturn true\n}", "func (p *Gray16) Opaque() bool {\n\treturn true\n}", "func (p *Gray16) Opaque() bool {\n\treturn true\n}", "func (me TxsdFeBlendTypeMode) IsScreen() bool { return me.String() == \"screen\" }", "func canFeatherSoftlock(g graph.Graph) error {\n\t// first check whether hide and seek has been reached\n\thideAndSeek := g[\"hide and seek\"]\n\tif hideAndSeek.Mark != graph.MarkTrue {\n\t\treturn nil\n\t}\n\t// also test that you can jump, since you can't H&S without jumping (and it\n\t// would be beneficial if you could)\n\tif g[\"jump\"].Mark != graph.MarkTrue {\n\t\treturn nil\n\t}\n\n\tshovel := g[\"shovel\"]\n\tparents := shovel.Parents\n\n\t// check whether hide and seek is reachable if shovel is unreachable\n\n\tshovel.ClearParents()\n\tdefer shovel.AddParents(parents...)\n\tg.ClearMarks()\n\tif hideAndSeek.GetMark(hideAndSeek, nil) == graph.MarkTrue {\n\t\treturn errors.New(\"feather softlock\")\n\t}\n\n\treturn nil\n}", "func EdgeFlag(flag bool) {\n C.glowEdgeFlag(gpEdgeFlag, (C.GLboolean)(boolToInt(flag)))\n}", "func (me TxsdColorProfileTypeRenderingIntent) IsPerceptual() bool { return me.String() == \"perceptual\" }", "func (mesh *PolyMesh) init() error {\n\n\tfor _, t := range mesh.Transform.Elems {\n\t\tmesh.transformSRT = append(mesh.transformSRT, m.TransformDecompMatrix4(t))\n\t}\n\n\tmesh.initTransformBounds()\n\n\tif mesh.PolyCount != nil {\n\t\tbasei := uint32(0)\n\t\tfor k := range mesh.PolyCount {\n\t\t\ti := uint32(0)\n\t\t\tfor j := 0; j < int(mesh.PolyCount[k]-2); j++ {\n\t\t\t\ti++\n\t\t\t\tmesh.idxp = append(mesh.idxp, uint32(mesh.FaceIdx[basei]))\n\t\t\t\tmesh.idxp = append(mesh.idxp, uint32(mesh.FaceIdx[basei+i]))\n\t\t\t\tmesh.idxp = append(mesh.idxp, uint32(mesh.FaceIdx[basei+i+1]))\n\n\t\t\t\tV0 := mesh.Verts.Elems[mesh.FaceIdx[basei]]\n\t\t\t\tV1 := mesh.Verts.Elems[mesh.FaceIdx[basei+i]]\n\t\t\t\tV2 := mesh.Verts.Elems[mesh.FaceIdx[basei+i+1]]\n\n\t\t\t\tif V0 == V1 && V0 == V2 {\n\t\t\t\t\t//log.Printf(\"nil triangle: %v %v %v %v %v\\n\", mesh.NodeName, mesh.FaceIdx[basei], V0, V1, V2)\n\t\t\t\t}\n\n\t\t\t\tif mesh.UV.Elems != nil {\n\t\t\t\t\tif mesh.UVIdx != nil { // if UVIdx doesn't exist assume same as FaceIdx\n\t\t\t\t\t\tmesh.uvtriidx = append(mesh.uvtriidx, uint32(mesh.UVIdx[basei]))\n\t\t\t\t\t\tmesh.uvtriidx = append(mesh.uvtriidx, uint32(mesh.UVIdx[basei+i]))\n\t\t\t\t\t\tmesh.uvtriidx = append(mesh.uvtriidx, uint32(mesh.UVIdx[basei+i+1]))\n\t\t\t\t\t} else {\n\t\t\t\t\t\tmesh.uvtriidx = append(mesh.uvtriidx, uint32(mesh.FaceIdx[basei]))\n\t\t\t\t\t\tmesh.uvtriidx = append(mesh.uvtriidx, uint32(mesh.FaceIdx[basei+i]))\n\t\t\t\t\t\tmesh.uvtriidx = append(mesh.uvtriidx, uint32(mesh.FaceIdx[basei+i+1]))\n\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\tif mesh.Normals.Elems != nil {\n\t\t\t\t\tif mesh.NormalIdx != nil { // if NormalIdx doesn't exist assume same as FaceIdx\n\t\t\t\t\t\tmesh.normalidx = append(mesh.normalidx, uint32(mesh.NormalIdx[basei]))\n\t\t\t\t\t\tmesh.normalidx = append(mesh.normalidx, uint32(mesh.NormalIdx[basei+i]))\n\t\t\t\t\t\tmesh.normalidx = append(mesh.normalidx, uint32(mesh.NormalIdx[basei+i+1]))\n\t\t\t\t\t} else {\n\t\t\t\t\t\tmesh.normalidx = append(mesh.normalidx, uint32(mesh.FaceIdx[basei]))\n\t\t\t\t\t\tmesh.normalidx = append(mesh.normalidx, uint32(mesh.FaceIdx[basei+i]))\n\t\t\t\t\t\tmesh.normalidx = append(mesh.normalidx, uint32(mesh.FaceIdx[basei+i+1]))\n\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\tif mesh.ShaderIdx != nil {\n\t\t\t\t\tmesh.shaderidx = append(mesh.shaderidx, uint8(mesh.ShaderIdx[k]))\n\t\t\t\t}\n\t\t\t}\n\t\t\tbasei += uint32(mesh.PolyCount[k])\n\t\t}\n\n\t} else {\n\t\t// Assume already a triangle mesh\n\t\tif mesh.FaceIdx != nil {\n\t\t\tfor j := range mesh.FaceIdx {\n\t\t\t\tmesh.idxp = append(mesh.idxp, uint32(mesh.FaceIdx[j]))\n\n\t\t\t\tif mesh.UV.Elems != nil {\n\t\t\t\t\tif mesh.UVIdx != nil {\n\t\t\t\t\t\tmesh.uvtriidx = append(mesh.uvtriidx, uint32(mesh.UVIdx[j]))\n\t\t\t\t\t} else {\n\t\t\t\t\t\tmesh.uvtriidx = append(mesh.uvtriidx, uint32(mesh.FaceIdx[j]))\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\tif mesh.Normals.Elems != nil {\n\t\t\t\t\tif mesh.NormalIdx != nil {\n\t\t\t\t\t\tmesh.normalidx = append(mesh.normalidx, uint32(mesh.NormalIdx[j]))\n\t\t\t\t\t} else {\n\t\t\t\t\t\tmesh.normalidx = append(mesh.normalidx, uint32(mesh.FaceIdx[j]))\n\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t}\n\t\t} else {\n\t\t\t// No indexes so assume the vertex array is simply the triangle verts\n\t\t\tfor j := 0; j < mesh.Verts.ElemsPerKey; j++ {\n\t\t\t\tmesh.idxp = append(mesh.idxp, uint32(j))\n\n\t\t\t\tif mesh.UV.Elems != nil {\n\t\t\t\t\tif mesh.UVIdx != nil {\n\t\t\t\t\t\tmesh.uvtriidx = append(mesh.uvtriidx, uint32(mesh.UVIdx[j]))\n\t\t\t\t\t} else {\n\t\t\t\t\t\tmesh.uvtriidx = append(mesh.uvtriidx, uint32(j))\n\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\tif mesh.Normals.Elems != nil {\n\t\t\t\t\tif mesh.NormalIdx != nil {\n\t\t\t\t\t\tmesh.normalidx = append(mesh.normalidx, uint32(mesh.NormalIdx[j]))\n\t\t\t\t\t} else {\n\t\t\t\t\t\tmesh.normalidx = append(mesh.normalidx, uint32(j))\n\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t}\n\t\t}\n\n\t\tfor _, idx := range mesh.ShaderIdx {\n\t\t\tmesh.shaderidx = append(mesh.shaderidx, uint8(idx))\n\t\t}\n\n\t}\n\n\tmesh.FaceIdx = nil\n\tmesh.PolyCount = nil\n\tmesh.UVIdx = nil\n\tmesh.NormalIdx = nil\n\tmesh.ShaderIdx = nil\n\n\treturn nil\n}", "func (filter *Saturation) IsScalable() {\n}", "func (eauf EngageActiveUsersFilter) AsEngageSubsetFilter() (*EngageSubsetFilter, bool) {\n\treturn nil, false\n}", "func (k KernSubtable) IsBackwards() bool {\n\treturn k.coverage&kerxBackwards != 0\n}", "func (f Filter) AsEngageSubsetFilter() (*EngageSubsetFilter, bool) {\n\treturn nil, false\n}", "func (me TxsdViewTypeZoomAndPan) IsZoom() bool { return me.String() == \"zoom\" }", "func (esf EngageSubsetFilter) AsEngageSubsetFilter() (*EngageSubsetFilter, bool) {\n\treturn &esf, true\n}", "func (w Winding) IsColinear() bool { return w == Colinear }", "func (qh *QuickHull) addPointToFace(face *meshBuilderFace, pointIndex int) bool {\n\td := signedDistanceToPlane(qh.vertexData[pointIndex], face.plane)\n\tif d > 0 && d*d > qh.epsilonSquared*face.plane.sqrNLength {\n\t\t/* TODO: optimize\n\t\tif Face.pointsOnPositiveSide == nil {\n\t\t\tf.m_pointsOnPositiveSide = std::move(getIndexVectorFromPool());\n\t\t}\n\t\t*/\n\t\tface.pointsOnPositiveSide = append(face.pointsOnPositiveSide, pointIndex)\n\t\tif d > face.mostDistantPointDist {\n\t\t\tface.mostDistantPointDist = d\n\t\t\tface.mostDistantPoint = pointIndex\n\t\t}\n\t\treturn true\n\t}\n\treturn false\n}", "func (me *Frustum) UpdatePlanesGH(mat *unum.Mat4, normalize bool) {\n\t// Left clipping plane\n\tme.Planes[0].X = mat[12] + mat[0]\n\tme.Planes[0].Y = mat[13] + mat[1]\n\tme.Planes[0].Z = mat[14] + mat[2]\n\tme.Planes[0].W = mat[15] + mat[3]\n\t// Right clipping plane\n\tme.Planes[1].X = mat[12] - mat[0]\n\tme.Planes[1].Y = mat[13] - mat[1]\n\tme.Planes[1].Z = mat[14] - mat[2]\n\tme.Planes[1].W = mat[15] - mat[3]\n\t// Bottom clipping plane\n\tme.Planes[2].X = mat[12] + mat[4]\n\tme.Planes[2].Y = mat[13] + mat[5]\n\tme.Planes[2].Z = mat[14] + mat[6]\n\tme.Planes[2].W = mat[15] + mat[7]\n\t// Top clipping plane\n\tme.Planes[3].X = mat[12] - mat[4]\n\tme.Planes[3].Y = mat[13] - mat[5]\n\tme.Planes[3].Z = mat[14] - mat[6]\n\tme.Planes[3].W = mat[15] - mat[7]\n\t// Near clipping plane\n\tme.Planes[4].X = mat[12] + mat[8]\n\tme.Planes[4].Y = mat[13] + mat[9]\n\tme.Planes[4].Z = mat[14] + mat[10]\n\tme.Planes[4].W = mat[15] + mat[11]\n\t// Far clipping plane\n\tme.Planes[5].X = mat[12] - mat[8]\n\tme.Planes[5].Y = mat[13] - mat[9]\n\tme.Planes[5].Z = mat[14] - mat[10]\n\tme.Planes[5].W = mat[15] - mat[11]\n\tif normalize {\n\t\tfor i := 0; i < len(me.Planes); i++ {\n\t\t\tme.Planes[i].Normalize()\n\t\t}\n\t}\n}", "func (me TxsdPresentationAttributesViewportsOverflow) IsHidden() bool { return me.String() == \"hidden\" }", "func (g *G1) isOnCurve() bool {\n\tvar x3, z3, y2 ff.Fp\n\ty2.Sqr(&g.y) // y2 = y^2\n\ty2.Mul(&y2, &g.z) // y2 = y^2*z\n\tx3.Sqr(&g.x) // x3 = x^2\n\tx3.Mul(&x3, &g.x) // x3 = x^3\n\tz3.Sqr(&g.z) // z3 = z^2\n\tz3.Mul(&z3, &g.z) // z3 = z^3\n\tz3.Mul(&z3, &g1Params.b) // z3 = 4*z^3\n\tx3.Add(&x3, &z3) // x3 = x^3 + 4*z^3\n\ty2.Sub(&y2, &x3) // y2 = y^2*z - (x^3 + 4*z^3)\n\treturn y2.IsZero() == 1\n}", "func (c *Camera) FlipFlying() {\n\tc.isFlying = !c.isFlying\n}", "func (p *Gray) Opaque() bool {\n\treturn true\n}", "func (p *CMYK) Opaque() bool {\n\treturn true\n}", "func MakeAllVisible(mapSurface *gamemap.GameMap) {\n\tfor x := 0; x < mapSurface.Width; x++ {\n\t\tfor y := 0; y < mapSurface.Height; y++ {\n\t\t\tmapSurface.Tiles[x][y].Visible = true\n\t\t}\n\t}\n}", "func (self *Graphics) InputEnabled() bool{\n return self.Object.Get(\"inputEnabled\").Bool()\n}", "func (p *Alpha16) Opaque() bool {\n\tif p.Rect.Empty() {\n\t\treturn true\n\t}\n\ti0, i1 := 0, p.Rect.Dx()*2\n\tfor y := p.Rect.Min.Y; y < p.Rect.Max.Y; y++ {\n\t\tfor i := i0; i < i1; i += 2 {\n\t\t\tif p.Pix[i+0] != 0xff || p.Pix[i+1] != 0xff {\n\t\t\t\treturn false\n\t\t\t}\n\t\t}\n\t\ti0 += p.Stride\n\t\ti1 += p.Stride\n\t}\n\treturn true\n}" ]
[ "0.5808077", "0.56039584", "0.55186737", "0.5413445", "0.53621805", "0.5265268", "0.5265268", "0.5163527", "0.5139808", "0.49922162", "0.49822396", "0.49585366", "0.49336785", "0.48021102", "0.47236323", "0.4717935", "0.47027516", "0.46903217", "0.4640689", "0.46279302", "0.4609361", "0.4605033", "0.46011832", "0.45900095", "0.45627844", "0.4555541", "0.4548592", "0.45435512", "0.45416868", "0.4532676", "0.45031378", "0.4461963", "0.44591135", "0.4444259", "0.44435784", "0.44414946", "0.44215122", "0.44119123", "0.44051862", "0.43949482", "0.43849182", "0.43810114", "0.4364667", "0.43632624", "0.43314412", "0.43144256", "0.43143854", "0.43129689", "0.42908686", "0.42894918", "0.42888623", "0.42804226", "0.4273583", "0.4267561", "0.4267226", "0.4264971", "0.4248943", "0.42418185", "0.42368183", "0.4220867", "0.4216284", "0.42149094", "0.41925633", "0.4189999", "0.4186821", "0.41864115", "0.418433", "0.4179555", "0.4174462", "0.41743523", "0.41724727", "0.41596115", "0.4156786", "0.4142568", "0.41408786", "0.41408786", "0.41408786", "0.4134645", "0.41291213", "0.41248593", "0.41215473", "0.41152558", "0.41132522", "0.41131362", "0.4108369", "0.41061738", "0.40915644", "0.40905374", "0.40896505", "0.40755495", "0.40721568", "0.4072075", "0.40647355", "0.4063915", "0.40621877", "0.4061955", "0.406018", "0.40579814", "0.40543592" ]
0.44384918
37
specify a callback to receive debugging messages from the GL
func DebugMessageCallback(callback DebugProc, userParam unsafe.Pointer) { userDebugCallback = callback C.glowDebugMessageCallback(gpDebugMessageCallback, (C.GLDEBUGPROC)(unsafe.Pointer(&callback)), userParam) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func DebugMessageCallback(callback DebugProc, userParam unsafe.Pointer) {\n userDebugCallback = callback\n C.glowDebugMessageCallback(gpDebugMessageCallback, (C.GLDEBUGPROC)(unsafe.Pointer(&callback)), userParam)\n}", "func DebugMessageCallback(callback unsafe.Pointer, userParam unsafe.Pointer) {\n\tsyscall.Syscall(gpDebugMessageCallback, 2, syscall.NewCallback(callback), uintptr(userParam), 0)\n}", "func DebugMessageCallbackAMD(callback unsafe.Pointer, userParam unsafe.Pointer) {\n\tC.glowDebugMessageCallbackAMD(gpDebugMessageCallbackAMD, (C.GLDEBUGPROCAMD)(callback), userParam)\n}", "func DebugMessageCallbackARB(callback unsafe.Pointer, userParam unsafe.Pointer) {\n\tsyscall.Syscall(gpDebugMessageCallbackARB, 2, syscall.NewCallback(callback), uintptr(userParam), 0)\n}", "func (p *fakeLogger) Debug(msg string, fields ...string) {\n\tif p.callback != nil {\n\t\tp.callback(msg)\n\t}\n}", "func DebugMessageInsert(source uint32, xtype uint32, id uint32, severity uint32, length int32, buf *int8) {\n C.glowDebugMessageInsert(gpDebugMessageInsert, (C.GLenum)(source), (C.GLenum)(xtype), (C.GLuint)(id), (C.GLenum)(severity), (C.GLsizei)(length), (*C.GLchar)(unsafe.Pointer(buf)))\n}", "func DebugMessageCallbackAMD(callback unsafe.Pointer, userParam unsafe.Pointer) {\n\tsyscall.Syscall(gpDebugMessageCallbackAMD, 2, uintptr(callback), uintptr(userParam), 0)\n}", "func (l *stubLogger) Debugf(format string, args ...interface{}) {}", "func DebugMessageControl(source uint32, xtype uint32, severity uint32, count int32, ids *uint32, enabled bool) {\n C.glowDebugMessageControl(gpDebugMessageControl, (C.GLenum)(source), (C.GLenum)(xtype), (C.GLenum)(severity), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(ids)), (C.GLboolean)(boolToInt(enabled)))\n}", "func (s *BasePlSqlParserListener) EnterLibrary_debug(ctx *Library_debugContext) {}", "func DebugMessageCallbackKHR(callback unsafe.Pointer, userParam unsafe.Pointer) {\n\tsyscall.Syscall(gpDebugMessageCallbackKHR, 2, syscall.NewCallback(callback), uintptr(userParam), 0)\n}", "func Debugf(msg ...interface{}) {\n\trunAdapters(DebugLog, FormattedOut, msg...)\n}", "func (l nullLogger) Debug(msg string, ctx ...interface{}) {}", "func (d *DummyLogger) Debugf(format string, args ...interface{}) {}", "func (lgr *lager) Debugf(msg string, v ...interface{}) {\n\tlgr.logf(Debug, msg, v...)\n}", "func (StdLogger) Debugf(format string, v ...interface{}) {}", "func handleDebugSignal(_ context.Context) {\n}", "func debug(message string) {\n if DebugMode {\n fmt.Fprintln(os.Stderr, \"DEBUG:\", message)\n }\n}", "func DebugMessageInsert(source uint32, xtype uint32, id uint32, severity uint32, length int32, buf *uint8) {\n\tC.glowDebugMessageInsert(gpDebugMessageInsert, (C.GLenum)(source), (C.GLenum)(xtype), (C.GLuint)(id), (C.GLenum)(severity), (C.GLsizei)(length), (*C.GLchar)(unsafe.Pointer(buf)))\n}", "func DebugMessageInsert(source uint32, xtype uint32, id uint32, severity uint32, length int32, buf *uint8) {\n\tC.glowDebugMessageInsert(gpDebugMessageInsert, (C.GLenum)(source), (C.GLenum)(xtype), (C.GLuint)(id), (C.GLenum)(severity), (C.GLsizei)(length), (*C.GLchar)(unsafe.Pointer(buf)))\n}", "func Debugf(format string, args ...interface{}) {\n\tl.Debug().Msgf(format, args...)\n}", "func Debug(msg string) {\n log.Debug(msg)\n}", "func (s *BaseGraffleParserListener) EnterBuilt_func_print(ctx *Built_func_printContext) {}", "func (p *Provider) Debug(debug bool) {}", "func (p *Provider) Debug(debug bool) {}", "func (p *Provider) Debug(debug bool) {}", "func (p *Provider) Debug(debug bool) {}", "func (n *nopLogger) Debugf(format string, v ...interface{}) {}", "func Debug(msg ...interface{}) {\n\tCurrent.Debug(msg...)\n}", "func (c *Client) OnDebug(cb DebugFunc) {\n\tc.onDebugListeners = append(c.onDebugListeners, cb)\n}", "func debugLog(msg interface{}) {\n fmt.Fprintln(os.Stderr, msg)\n}", "func Debugf(format string, args ...interface{}) { logRaw(LevelDebug, 2, format, args...) }", "func (lc mockNotifyLogger) Debug(msg string, args ...interface{}) {\n}", "func onConnect(c *gnet.Connection, solicited bool) {\n\tfmt.Printf(\"Event Callback: connnect event \\n\")\n}", "func (a CompatLoggerAdapter) Debugf(format string, v ...interface{}) {\n\ta.Printf(\"DEBUG: \"+format, v...)\n}", "func (l *Logger) Debugf(msg string, args ...interface{}) {\n\tl.sgLogger.Debugf(msg, args...)\n\t_ = l.lg.Sync()\n}", "func _debugf(format string, args ...interface{}) {\n\tif v(1) {\n\t\targs = append([]interface{}{_caller(2)}, args...)\n\t\tfmt.Printf(\"%s: \"+format+\"\\n\", args...)\n\t}\n}", "func IfMydebug(f func()) {\n\t// f()\n}", "func Debugf(msg string, args ...interface{}) {\n log.Debugf(msg, args...)\n}", "func Debug(v ...interface{}) { std.lprint(DEBUG, v...) }", "func (l *MemoryLogger) Debug(msg string, keyvals ...interface{}) {\n\tl.println(\"DEBUG\", msg, keyvals)\n}", "func Debugf(msg string, v ...interface{}) {\n\tif lvl <= deb {\n\t\tl.Printf(\"[DEBUG]: \"+msg, v...)\n\t}\n}", "func (c *Client) debugf(format string, v ...any) {\n\tif !c.DebugLog {\n\t\treturn\n\t}\n\tc.Logger(format, v...)\n}", "func (l *Logger) Debug(v ...interface{}) { l.lprint(DEBUG, v...) }", "func (l *Logger) Debugf(format string, v ...interface{}) { l.lprintf(DEBUG, format, v...) }", "func debug(m string, v interface{}) {\n\tif DebugMode {\n\t\tlog.Printf(m+\":%+v\", v)\n\t}\n}", "func dg() {\n\tgl.Dump() // doesn't need context.\n\n\t// Also print the opengl version which does need a context.\n\tapp := device.New(\"Dump\", 400, 100, 600, 600)\n\tfmt.Printf(\"%s %s\", gl.GetString(gl.RENDERER), gl.GetString(gl.VERSION))\n\tfmt.Printf(\" GLSL %s\\n\", gl.GetString(gl.SHADING_LANGUAGE_VERSION))\n\tapp.Dispose()\n}", "func _debug(ptr uint32, size uint32)", "func (g GrcpGatewayLogger) Debug(msg string) {\n\tif g.logger.silent(DebugLevel) {\n\t\treturn\n\t}\n\te := g.logger.header(DebugLevel)\n\tif g.logger.Caller > 0 {\n\t\t_, file, line, _ := runtime.Caller(g.logger.Caller)\n\t\te.caller(file, line, g.logger.FullpathCaller)\n\t}\n\te.Context(g.context).Msg(msg)\n}", "func Debug(args ...interface{}) {\n\tif defaultLgr == nil {\n\t\treturn\n\t}\n\tdefaultLgr.Debugf(strings.TrimSpace(strings.Repeat(\"%+v \", len(args))), args...)\n}", "func (l NullLogger) Debugf(format string, params ...interface{}) {\n}", "func (d *DummyLogger) Debug(format string) {}", "func (l LoggerFunc) Debug(format string, args ...interface{}) {\n\tl(format, args...)\n}", "func (o Object) Debug(f string, a ...interface{}) {\n\tif o.DebugEnabled {\n\t\to.PrintMsg(\"DEBUG\", 2, f, a...)\n\t}\n}", "func (e *Engine) Debugf(format string, a ...interface{}) {\n\te.debug.Printf(format, a...)\n}", "func (db RDB) debugf(msg string, args ...interface{}) {\n\tif db._log != nil {\n\t\tdb._log.Printf(msg, args...)\n\t}\n}", "func (c Context) Debug(msg string) {\n\tc.Log(40, msg, GetCallingFunction())\n}", "func (l *Logger) Debugf(msg string, args ...interface{}) {\n\tif l.IsEnabledFor(DebugLevel) {\n\t\tfile, line := Caller(1)\n\t\tl.Log(DebugLevel, file, line, msg, args...)\n\t}\n}", "func (l *BasicLogger) Debugf(format string, vargs ...interface{}) {\n\tl.appendLogEvent(level.DebugLevel, fmt.Sprintf(format, vargs...))\n}", "func Debugf(template string, args ...interface{}) {\n\tL().log(2, DebugLevel, template, args, nil)\n}", "func (l *strandardHandler) Printf(msg string, args ...interface{}) {\n\tlogMsg := fmt.Sprintf(\"Third party log message: %s\", msg)\n\tl.Emit(getContext(\"DBG\", 1), logMsg, args...)\n}", "func debug(format string, args ...interface{}) {\n\tif debugOn {\n\t\tlog.Printf(\"DEBUG: \"+format, args...)\n\t}\n}", "func (fp MockProvider) Debug(b bool) {\n\tfp.faux.Debug(b)\n}", "func Debug(msg string){\n\tif IsDebug() {\n\t\tlog.Println(msg)\n\t}\n}", "func (w *Writer) Debug(m string) error {}", "func (native *OpenGL) LogOpenGLWarn() {\n\tif err := gl.GetError(); err != oglconsts.NO_ERROR {\n\t\tsettings.LogWarn(\"[OpenGL Error] Error occured: %v\", err)\n\t}\n}", "func (l *XORMLogBridge) Debugf(format string, v ...interface{}) {\n\tlog.Debugf(format, v...)\n}", "func debug(g *gocui.Gui, output interface{}) {\n\tv, err := g.View(\"debug\")\n\tif err == nil {\n\t\tt := time.Now()\n\t\ttf := t.Format(\"2006-01-02 15:04:05\")\n\t\toutput = tf + \" > \" + output.(string)\n\t\tfmt.Fprintln(v, output)\n\t}\n}", "func (m *Monitor) debugf(format string, v ...interface{}) {\n\tif !m.verbose {\n\t\treturn\n\t}\n\n\tm.logf(\"debug: %s\", fmt.Sprintf(format, v...))\n}", "func (l *logHandler) Debug(args ...interface{}) {\n\tl.Log(LogDebug, 3, args...)\n}", "func (l *Logger) Debugln(v ...interface{}) { l.lprintln(DEBUG, v...) }", "func (lh *logHandler) Debug(data ...interface{}) {\n\tif lh.debug == nil {\n\t\treturn\n\t}\n\tlh.debug.Println(data...)\n}", "func (e *Env) Debugf(format string, args ...interface{}) {\n\te.log(format, args...)\n}", "func Debugln(v ...interface{}) { std.lprintln(DEBUG, v...) }", "func (s *BasejossListener) EnterFuncLog(ctx *FuncLogContext) {}", "func (l *Logger) Debugf(msg string, v ...interface{}) {\n\tif l.debug {\n\t\terr := l.Logger.Output(callDepth, \"[DEBUG] \"+fmt.Sprintf(msg, v...))\n\t\tif err != nil {\n\t\t\tfmt.Println(\"Logger Error:\", err) //nolint:forbidigo\n\t\t}\n\t}\n}", "func (_m *Logger) Debug(msg string, additionalValues ...interface{}) {\n\tvar _ca []interface{}\n\t_ca = append(_ca, msg)\n\t_ca = append(_ca, additionalValues...)\n\t_m.Called(_ca...)\n}", "func DebugMessage(msg string, a ...interface{}) {\n\tif sliceExists(Levels, \"DEBUG\") {\n\t\tfmt.Printf(\"[FRAME DEBUG] %s\\n\", fmt.Sprintf(msg, a...))\n\t}\n}", "func (*traceLogger) Infof(msg string, args ...any) { log.Infof(msg, args...) }", "func (a *app) debugHandler(w http.ResponseWriter, r *http.Request) {\n\tgameID := a.getOrGenerateGameName(r.URL.Query().Get(\"game_id\"))\n\n\tevents := handlers.FilterGameMoveEvents(a.store.Events(), gameID)\n\tgame := handlers.MustRebuildGame(chess.NewGame(), events, gameID, -1)\n\n\tif _, err := w.Write([]byte(game.Debug())); err != nil {\n\t\tlog.Printf(\"can't write the response: %v\", err)\n\t}\n}", "func DebugMessageControl(source uint32, xtype uint32, severity uint32, count int32, ids *uint32, enabled bool) {\n\tC.glowDebugMessageControl(gpDebugMessageControl, (C.GLenum)(source), (C.GLenum)(xtype), (C.GLenum)(severity), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(ids)), (C.GLboolean)(boolToInt(enabled)))\n}", "func DebugMessageControl(source uint32, xtype uint32, severity uint32, count int32, ids *uint32, enabled bool) {\n\tC.glowDebugMessageControl(gpDebugMessageControl, (C.GLenum)(source), (C.GLenum)(xtype), (C.GLenum)(severity), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(ids)), (C.GLboolean)(boolToInt(enabled)))\n}", "func (_m *Logger) Debugf(fmt string, args ...interface{}) {\n\tvar _ca []interface{}\n\t_ca = append(_ca, fmt)\n\t_ca = append(_ca, args...)\n\t_m.Called(_ca...)\n}", "func Debugf(format string, v ...interface{}) { std.lprintf(DEBUG, format, v...) }", "func (rl *RevelLogger) Debugf(msg string, param ...interface{}) {\n\trl.Debug(fmt.Sprintf(msg, param...))\n}", "func Debugf(format string, v ...interface{}) {\n\tif Debug {\n\t\tWarnf(format, v...)\n\t}\n}", "func Debug(ctx context.Context, args ...interface{}) {\n\tglobal.Debug(ctx, args...)\n}", "func Debug(i interface{}) {\n\tl.Debug(i)\n}", "func myDebug(format string, a ...interface{}) {\n\tif FlagDebug {\n\t\tformat = fmt.Sprintf(\"[DEBUG] %s\\n\", format)\n\t\tfmt.Fprintf(os.Stderr, format, a...)\n\t}\n}", "func dmsg(level DebugLevel, f string, args ...interface{}) {\n\tif (debug & level) > 0 {\n\t\tfmt.Fprintf(os.Stderr, f, args...)\n\t}\n}", "func (w *Writer) Debugf(format string, args ...interface{}) {\n\tw.log(\"debug\", format, args...)\n}", "func (app *App) debugf(format string, args ...interface{}) {\n\tif app.Debug {\n\t\tlog.Printf(format, args...)\n\t}\n}", "func (l *Logger) Debugf(msg string, args ...interface{}) {\n\t_, file, line, _ := runtime.Caller(1)\n\tl.Log(DebugLevel, file, line, msg, args...)\n}", "func (_m *StdLogger) Debugf(format string, args ...interface{}) {\n\tvar _ca []interface{}\n\t_ca = append(_ca, format)\n\t_ca = append(_ca, args...)\n\t_m.Called(_ca...)\n}", "func (l *jsonLogger) Debug(message interface{}, params ...interface{}) {\n\tl.jsonLogParser.parse(context.Background(), l.jsonLogParser.log.Debug(), \"\", params...).Msgf(\"%s\", message)\n}", "func (s *Server) Debugf(str string, args ...interface{}) {\n\tif s.debug {\n\t\tlog.Printf(str, args...)\n\t}\n}", "func (s *Server) Debugf(str string, args ...interface{}) {\n\tif s.debug {\n\t\tlog.Printf(str, args...)\n\t}\n}", "func (l *XORMLogBridge) Debug(v ...interface{}) {\n\tlog.Debug(v...)\n}", "func (l LoggerFunc) Debugf(format string, args ...interface{}) {\n\tl(format, args...)\n}" ]
[ "0.7537775", "0.6209299", "0.61972326", "0.60274637", "0.5865196", "0.5714642", "0.56369185", "0.5558115", "0.54866415", "0.54723257", "0.5455521", "0.54135716", "0.5329175", "0.53018814", "0.5288752", "0.5270199", "0.5263286", "0.5259788", "0.52580667", "0.52580667", "0.52536017", "0.52449787", "0.52381116", "0.5227014", "0.5227014", "0.5227014", "0.5227014", "0.5218017", "0.52008444", "0.51930594", "0.51874906", "0.517835", "0.5157368", "0.5149503", "0.5148835", "0.51286453", "0.5118442", "0.51032245", "0.5094506", "0.5081602", "0.5076396", "0.50690866", "0.50523067", "0.5045844", "0.5039914", "0.50375247", "0.5037314", "0.5032086", "0.5027935", "0.50245553", "0.50217754", "0.5016022", "0.5011115", "0.49965858", "0.49924213", "0.49910235", "0.4980538", "0.49802884", "0.49779382", "0.49708828", "0.497026", "0.49701843", "0.49695963", "0.49615252", "0.4960566", "0.4946045", "0.49453184", "0.49430797", "0.494114", "0.49388427", "0.49247202", "0.49233234", "0.4922004", "0.49208722", "0.491611", "0.4914183", "0.49126264", "0.4911877", "0.49080098", "0.49045196", "0.4902804", "0.4902804", "0.4894469", "0.48913687", "0.48885524", "0.48851004", "0.48783055", "0.48781058", "0.4878073", "0.4871912", "0.4870517", "0.4870442", "0.4860332", "0.48499626", "0.48473588", "0.48414496", "0.48414496", "0.48410773", "0.48405403" ]
0.6898329
2
Parameter callback has type C.GLDEBUGPROCAMD.
func DebugMessageCallbackAMD(callback unsafe.Pointer, userParam unsafe.Pointer) { C.glowDebugMessageCallbackAMD(gpDebugMessageCallbackAMD, (C.GLDEBUGPROCAMD)(callback), userParam) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func DebugMessageCallback(callback DebugProc, userParam unsafe.Pointer) {\n userDebugCallback = callback\n C.glowDebugMessageCallback(gpDebugMessageCallback, (C.GLDEBUGPROC)(unsafe.Pointer(&callback)), userParam)\n}", "func DebugMessageCallbackAMD(callback unsafe.Pointer, userParam unsafe.Pointer) {\n\tsyscall.Syscall(gpDebugMessageCallbackAMD, 2, uintptr(callback), uintptr(userParam), 0)\n}", "func DebugMessageCallback(callback DebugProc, userParam unsafe.Pointer) {\n\tuserDebugCallback = callback\n\tC.glowDebugMessageCallback(gpDebugMessageCallback, (C.GLDEBUGPROC)(unsafe.Pointer(&callback)), userParam)\n}", "func DebugMessageCallback(callback DebugProc, userParam unsafe.Pointer) {\n\tuserDebugCallback = callback\n\tC.glowDebugMessageCallback(gpDebugMessageCallback, (C.GLDEBUGPROC)(unsafe.Pointer(&callback)), userParam)\n}", "func InitWithProcAddrFunc(getProcAddr func(name string) unsafe.Pointer) error {\n\tgpActiveProgramEXT = (C.GPACTIVEPROGRAMEXT)(getProcAddr(\"glActiveProgramEXT\"))\n\tgpActiveShaderProgram = (C.GPACTIVESHADERPROGRAM)(getProcAddr(\"glActiveShaderProgram\"))\n\tif gpActiveShaderProgram == nil {\n\t\treturn errors.New(\"glActiveShaderProgram\")\n\t}\n\tgpActiveShaderProgramEXT = (C.GPACTIVESHADERPROGRAMEXT)(getProcAddr(\"glActiveShaderProgramEXT\"))\n\tgpActiveTexture = (C.GPACTIVETEXTURE)(getProcAddr(\"glActiveTexture\"))\n\tif gpActiveTexture == nil {\n\t\treturn errors.New(\"glActiveTexture\")\n\t}\n\tgpApplyFramebufferAttachmentCMAAINTEL = (C.GPAPPLYFRAMEBUFFERATTACHMENTCMAAINTEL)(getProcAddr(\"glApplyFramebufferAttachmentCMAAINTEL\"))\n\tgpAttachShader = (C.GPATTACHSHADER)(getProcAddr(\"glAttachShader\"))\n\tif gpAttachShader == nil {\n\t\treturn errors.New(\"glAttachShader\")\n\t}\n\tgpBeginConditionalRender = (C.GPBEGINCONDITIONALRENDER)(getProcAddr(\"glBeginConditionalRender\"))\n\tif gpBeginConditionalRender == nil {\n\t\treturn errors.New(\"glBeginConditionalRender\")\n\t}\n\tgpBeginConditionalRenderNV = (C.GPBEGINCONDITIONALRENDERNV)(getProcAddr(\"glBeginConditionalRenderNV\"))\n\tgpBeginPerfMonitorAMD = (C.GPBEGINPERFMONITORAMD)(getProcAddr(\"glBeginPerfMonitorAMD\"))\n\tgpBeginPerfQueryINTEL = (C.GPBEGINPERFQUERYINTEL)(getProcAddr(\"glBeginPerfQueryINTEL\"))\n\tgpBeginQuery = (C.GPBEGINQUERY)(getProcAddr(\"glBeginQuery\"))\n\tif gpBeginQuery == nil {\n\t\treturn errors.New(\"glBeginQuery\")\n\t}\n\tgpBeginQueryIndexed = (C.GPBEGINQUERYINDEXED)(getProcAddr(\"glBeginQueryIndexed\"))\n\tif gpBeginQueryIndexed == nil {\n\t\treturn errors.New(\"glBeginQueryIndexed\")\n\t}\n\tgpBeginTransformFeedback = (C.GPBEGINTRANSFORMFEEDBACK)(getProcAddr(\"glBeginTransformFeedback\"))\n\tif gpBeginTransformFeedback == nil {\n\t\treturn errors.New(\"glBeginTransformFeedback\")\n\t}\n\tgpBindAttribLocation = (C.GPBINDATTRIBLOCATION)(getProcAddr(\"glBindAttribLocation\"))\n\tif gpBindAttribLocation == nil {\n\t\treturn errors.New(\"glBindAttribLocation\")\n\t}\n\tgpBindBuffer = (C.GPBINDBUFFER)(getProcAddr(\"glBindBuffer\"))\n\tif gpBindBuffer == nil {\n\t\treturn errors.New(\"glBindBuffer\")\n\t}\n\tgpBindBufferBase = (C.GPBINDBUFFERBASE)(getProcAddr(\"glBindBufferBase\"))\n\tif gpBindBufferBase == nil {\n\t\treturn errors.New(\"glBindBufferBase\")\n\t}\n\tgpBindBufferRange = (C.GPBINDBUFFERRANGE)(getProcAddr(\"glBindBufferRange\"))\n\tif gpBindBufferRange == nil {\n\t\treturn errors.New(\"glBindBufferRange\")\n\t}\n\tgpBindBuffersBase = (C.GPBINDBUFFERSBASE)(getProcAddr(\"glBindBuffersBase\"))\n\tgpBindBuffersRange = (C.GPBINDBUFFERSRANGE)(getProcAddr(\"glBindBuffersRange\"))\n\tgpBindFragDataLocation = (C.GPBINDFRAGDATALOCATION)(getProcAddr(\"glBindFragDataLocation\"))\n\tif gpBindFragDataLocation == nil {\n\t\treturn errors.New(\"glBindFragDataLocation\")\n\t}\n\tgpBindFragDataLocationIndexed = (C.GPBINDFRAGDATALOCATIONINDEXED)(getProcAddr(\"glBindFragDataLocationIndexed\"))\n\tif gpBindFragDataLocationIndexed == nil {\n\t\treturn errors.New(\"glBindFragDataLocationIndexed\")\n\t}\n\tgpBindFramebuffer = (C.GPBINDFRAMEBUFFER)(getProcAddr(\"glBindFramebuffer\"))\n\tif gpBindFramebuffer == nil {\n\t\treturn errors.New(\"glBindFramebuffer\")\n\t}\n\tgpBindImageTexture = (C.GPBINDIMAGETEXTURE)(getProcAddr(\"glBindImageTexture\"))\n\tif gpBindImageTexture == nil {\n\t\treturn errors.New(\"glBindImageTexture\")\n\t}\n\tgpBindImageTextures = (C.GPBINDIMAGETEXTURES)(getProcAddr(\"glBindImageTextures\"))\n\tgpBindMultiTextureEXT = (C.GPBINDMULTITEXTUREEXT)(getProcAddr(\"glBindMultiTextureEXT\"))\n\tgpBindProgramPipeline = (C.GPBINDPROGRAMPIPELINE)(getProcAddr(\"glBindProgramPipeline\"))\n\tif gpBindProgramPipeline == nil {\n\t\treturn errors.New(\"glBindProgramPipeline\")\n\t}\n\tgpBindProgramPipelineEXT = (C.GPBINDPROGRAMPIPELINEEXT)(getProcAddr(\"glBindProgramPipelineEXT\"))\n\tgpBindRenderbuffer = (C.GPBINDRENDERBUFFER)(getProcAddr(\"glBindRenderbuffer\"))\n\tif gpBindRenderbuffer == nil {\n\t\treturn errors.New(\"glBindRenderbuffer\")\n\t}\n\tgpBindSampler = (C.GPBINDSAMPLER)(getProcAddr(\"glBindSampler\"))\n\tif gpBindSampler == nil {\n\t\treturn errors.New(\"glBindSampler\")\n\t}\n\tgpBindSamplers = (C.GPBINDSAMPLERS)(getProcAddr(\"glBindSamplers\"))\n\tgpBindShadingRateImageNV = (C.GPBINDSHADINGRATEIMAGENV)(getProcAddr(\"glBindShadingRateImageNV\"))\n\tgpBindTexture = (C.GPBINDTEXTURE)(getProcAddr(\"glBindTexture\"))\n\tif gpBindTexture == nil {\n\t\treturn errors.New(\"glBindTexture\")\n\t}\n\tgpBindTextureUnit = (C.GPBINDTEXTUREUNIT)(getProcAddr(\"glBindTextureUnit\"))\n\tgpBindTextures = (C.GPBINDTEXTURES)(getProcAddr(\"glBindTextures\"))\n\tgpBindTransformFeedback = (C.GPBINDTRANSFORMFEEDBACK)(getProcAddr(\"glBindTransformFeedback\"))\n\tif gpBindTransformFeedback == nil {\n\t\treturn errors.New(\"glBindTransformFeedback\")\n\t}\n\tgpBindVertexArray = (C.GPBINDVERTEXARRAY)(getProcAddr(\"glBindVertexArray\"))\n\tif gpBindVertexArray == nil {\n\t\treturn errors.New(\"glBindVertexArray\")\n\t}\n\tgpBindVertexBuffer = (C.GPBINDVERTEXBUFFER)(getProcAddr(\"glBindVertexBuffer\"))\n\tgpBindVertexBuffers = (C.GPBINDVERTEXBUFFERS)(getProcAddr(\"glBindVertexBuffers\"))\n\tgpBlendBarrierKHR = (C.GPBLENDBARRIERKHR)(getProcAddr(\"glBlendBarrierKHR\"))\n\tgpBlendBarrierNV = (C.GPBLENDBARRIERNV)(getProcAddr(\"glBlendBarrierNV\"))\n\tgpBlendColor = (C.GPBLENDCOLOR)(getProcAddr(\"glBlendColor\"))\n\tif gpBlendColor == nil {\n\t\treturn errors.New(\"glBlendColor\")\n\t}\n\tgpBlendEquation = (C.GPBLENDEQUATION)(getProcAddr(\"glBlendEquation\"))\n\tif gpBlendEquation == nil {\n\t\treturn errors.New(\"glBlendEquation\")\n\t}\n\tgpBlendEquationSeparate = (C.GPBLENDEQUATIONSEPARATE)(getProcAddr(\"glBlendEquationSeparate\"))\n\tif gpBlendEquationSeparate == nil {\n\t\treturn errors.New(\"glBlendEquationSeparate\")\n\t}\n\tgpBlendEquationSeparatei = (C.GPBLENDEQUATIONSEPARATEI)(getProcAddr(\"glBlendEquationSeparatei\"))\n\tif gpBlendEquationSeparatei == nil {\n\t\treturn errors.New(\"glBlendEquationSeparatei\")\n\t}\n\tgpBlendEquationSeparateiARB = (C.GPBLENDEQUATIONSEPARATEIARB)(getProcAddr(\"glBlendEquationSeparateiARB\"))\n\tgpBlendEquationi = (C.GPBLENDEQUATIONI)(getProcAddr(\"glBlendEquationi\"))\n\tif gpBlendEquationi == nil {\n\t\treturn errors.New(\"glBlendEquationi\")\n\t}\n\tgpBlendEquationiARB = (C.GPBLENDEQUATIONIARB)(getProcAddr(\"glBlendEquationiARB\"))\n\tgpBlendFunc = (C.GPBLENDFUNC)(getProcAddr(\"glBlendFunc\"))\n\tif gpBlendFunc == nil {\n\t\treturn errors.New(\"glBlendFunc\")\n\t}\n\tgpBlendFuncSeparate = (C.GPBLENDFUNCSEPARATE)(getProcAddr(\"glBlendFuncSeparate\"))\n\tif gpBlendFuncSeparate == nil {\n\t\treturn errors.New(\"glBlendFuncSeparate\")\n\t}\n\tgpBlendFuncSeparatei = (C.GPBLENDFUNCSEPARATEI)(getProcAddr(\"glBlendFuncSeparatei\"))\n\tif gpBlendFuncSeparatei == nil {\n\t\treturn errors.New(\"glBlendFuncSeparatei\")\n\t}\n\tgpBlendFuncSeparateiARB = (C.GPBLENDFUNCSEPARATEIARB)(getProcAddr(\"glBlendFuncSeparateiARB\"))\n\tgpBlendFunci = (C.GPBLENDFUNCI)(getProcAddr(\"glBlendFunci\"))\n\tif gpBlendFunci == nil {\n\t\treturn errors.New(\"glBlendFunci\")\n\t}\n\tgpBlendFunciARB = (C.GPBLENDFUNCIARB)(getProcAddr(\"glBlendFunciARB\"))\n\tgpBlendParameteriNV = (C.GPBLENDPARAMETERINV)(getProcAddr(\"glBlendParameteriNV\"))\n\tgpBlitFramebuffer = (C.GPBLITFRAMEBUFFER)(getProcAddr(\"glBlitFramebuffer\"))\n\tif gpBlitFramebuffer == nil {\n\t\treturn errors.New(\"glBlitFramebuffer\")\n\t}\n\tgpBlitNamedFramebuffer = (C.GPBLITNAMEDFRAMEBUFFER)(getProcAddr(\"glBlitNamedFramebuffer\"))\n\tgpBufferAddressRangeNV = (C.GPBUFFERADDRESSRANGENV)(getProcAddr(\"glBufferAddressRangeNV\"))\n\tgpBufferAttachMemoryNV = (C.GPBUFFERATTACHMEMORYNV)(getProcAddr(\"glBufferAttachMemoryNV\"))\n\tgpBufferData = (C.GPBUFFERDATA)(getProcAddr(\"glBufferData\"))\n\tif gpBufferData == nil {\n\t\treturn errors.New(\"glBufferData\")\n\t}\n\tgpBufferPageCommitmentARB = (C.GPBUFFERPAGECOMMITMENTARB)(getProcAddr(\"glBufferPageCommitmentARB\"))\n\tgpBufferPageCommitmentMemNV = (C.GPBUFFERPAGECOMMITMENTMEMNV)(getProcAddr(\"glBufferPageCommitmentMemNV\"))\n\tgpBufferStorage = (C.GPBUFFERSTORAGE)(getProcAddr(\"glBufferStorage\"))\n\tgpBufferSubData = (C.GPBUFFERSUBDATA)(getProcAddr(\"glBufferSubData\"))\n\tif gpBufferSubData == nil {\n\t\treturn errors.New(\"glBufferSubData\")\n\t}\n\tgpCallCommandListNV = (C.GPCALLCOMMANDLISTNV)(getProcAddr(\"glCallCommandListNV\"))\n\tgpCheckFramebufferStatus = (C.GPCHECKFRAMEBUFFERSTATUS)(getProcAddr(\"glCheckFramebufferStatus\"))\n\tif gpCheckFramebufferStatus == nil {\n\t\treturn errors.New(\"glCheckFramebufferStatus\")\n\t}\n\tgpCheckNamedFramebufferStatus = (C.GPCHECKNAMEDFRAMEBUFFERSTATUS)(getProcAddr(\"glCheckNamedFramebufferStatus\"))\n\tgpCheckNamedFramebufferStatusEXT = (C.GPCHECKNAMEDFRAMEBUFFERSTATUSEXT)(getProcAddr(\"glCheckNamedFramebufferStatusEXT\"))\n\tgpClampColor = (C.GPCLAMPCOLOR)(getProcAddr(\"glClampColor\"))\n\tif gpClampColor == nil {\n\t\treturn errors.New(\"glClampColor\")\n\t}\n\tgpClear = (C.GPCLEAR)(getProcAddr(\"glClear\"))\n\tif gpClear == nil {\n\t\treturn errors.New(\"glClear\")\n\t}\n\tgpClearBufferData = (C.GPCLEARBUFFERDATA)(getProcAddr(\"glClearBufferData\"))\n\tgpClearBufferSubData = (C.GPCLEARBUFFERSUBDATA)(getProcAddr(\"glClearBufferSubData\"))\n\tgpClearBufferfi = (C.GPCLEARBUFFERFI)(getProcAddr(\"glClearBufferfi\"))\n\tif gpClearBufferfi == nil {\n\t\treturn errors.New(\"glClearBufferfi\")\n\t}\n\tgpClearBufferfv = (C.GPCLEARBUFFERFV)(getProcAddr(\"glClearBufferfv\"))\n\tif gpClearBufferfv == nil {\n\t\treturn errors.New(\"glClearBufferfv\")\n\t}\n\tgpClearBufferiv = (C.GPCLEARBUFFERIV)(getProcAddr(\"glClearBufferiv\"))\n\tif gpClearBufferiv == nil {\n\t\treturn errors.New(\"glClearBufferiv\")\n\t}\n\tgpClearBufferuiv = (C.GPCLEARBUFFERUIV)(getProcAddr(\"glClearBufferuiv\"))\n\tif gpClearBufferuiv == nil {\n\t\treturn errors.New(\"glClearBufferuiv\")\n\t}\n\tgpClearColor = (C.GPCLEARCOLOR)(getProcAddr(\"glClearColor\"))\n\tif gpClearColor == nil {\n\t\treturn errors.New(\"glClearColor\")\n\t}\n\tgpClearDepth = (C.GPCLEARDEPTH)(getProcAddr(\"glClearDepth\"))\n\tif gpClearDepth == nil {\n\t\treturn errors.New(\"glClearDepth\")\n\t}\n\tgpClearDepthdNV = (C.GPCLEARDEPTHDNV)(getProcAddr(\"glClearDepthdNV\"))\n\tgpClearDepthf = (C.GPCLEARDEPTHF)(getProcAddr(\"glClearDepthf\"))\n\tif gpClearDepthf == nil {\n\t\treturn errors.New(\"glClearDepthf\")\n\t}\n\tgpClearNamedBufferData = (C.GPCLEARNAMEDBUFFERDATA)(getProcAddr(\"glClearNamedBufferData\"))\n\tgpClearNamedBufferDataEXT = (C.GPCLEARNAMEDBUFFERDATAEXT)(getProcAddr(\"glClearNamedBufferDataEXT\"))\n\tgpClearNamedBufferSubData = (C.GPCLEARNAMEDBUFFERSUBDATA)(getProcAddr(\"glClearNamedBufferSubData\"))\n\tgpClearNamedBufferSubDataEXT = (C.GPCLEARNAMEDBUFFERSUBDATAEXT)(getProcAddr(\"glClearNamedBufferSubDataEXT\"))\n\tgpClearNamedFramebufferfi = (C.GPCLEARNAMEDFRAMEBUFFERFI)(getProcAddr(\"glClearNamedFramebufferfi\"))\n\tgpClearNamedFramebufferfv = (C.GPCLEARNAMEDFRAMEBUFFERFV)(getProcAddr(\"glClearNamedFramebufferfv\"))\n\tgpClearNamedFramebufferiv = (C.GPCLEARNAMEDFRAMEBUFFERIV)(getProcAddr(\"glClearNamedFramebufferiv\"))\n\tgpClearNamedFramebufferuiv = (C.GPCLEARNAMEDFRAMEBUFFERUIV)(getProcAddr(\"glClearNamedFramebufferuiv\"))\n\tgpClearStencil = (C.GPCLEARSTENCIL)(getProcAddr(\"glClearStencil\"))\n\tif gpClearStencil == nil {\n\t\treturn errors.New(\"glClearStencil\")\n\t}\n\tgpClearTexImage = (C.GPCLEARTEXIMAGE)(getProcAddr(\"glClearTexImage\"))\n\tgpClearTexSubImage = (C.GPCLEARTEXSUBIMAGE)(getProcAddr(\"glClearTexSubImage\"))\n\tgpClientAttribDefaultEXT = (C.GPCLIENTATTRIBDEFAULTEXT)(getProcAddr(\"glClientAttribDefaultEXT\"))\n\tgpClientWaitSync = (C.GPCLIENTWAITSYNC)(getProcAddr(\"glClientWaitSync\"))\n\tif gpClientWaitSync == nil {\n\t\treturn errors.New(\"glClientWaitSync\")\n\t}\n\tgpClipControl = (C.GPCLIPCONTROL)(getProcAddr(\"glClipControl\"))\n\tgpColorFormatNV = (C.GPCOLORFORMATNV)(getProcAddr(\"glColorFormatNV\"))\n\tgpColorMask = (C.GPCOLORMASK)(getProcAddr(\"glColorMask\"))\n\tif gpColorMask == nil {\n\t\treturn errors.New(\"glColorMask\")\n\t}\n\tgpColorMaski = (C.GPCOLORMASKI)(getProcAddr(\"glColorMaski\"))\n\tif gpColorMaski == nil {\n\t\treturn errors.New(\"glColorMaski\")\n\t}\n\tgpCommandListSegmentsNV = (C.GPCOMMANDLISTSEGMENTSNV)(getProcAddr(\"glCommandListSegmentsNV\"))\n\tgpCompileCommandListNV = (C.GPCOMPILECOMMANDLISTNV)(getProcAddr(\"glCompileCommandListNV\"))\n\tgpCompileShader = (C.GPCOMPILESHADER)(getProcAddr(\"glCompileShader\"))\n\tif gpCompileShader == nil {\n\t\treturn errors.New(\"glCompileShader\")\n\t}\n\tgpCompileShaderIncludeARB = (C.GPCOMPILESHADERINCLUDEARB)(getProcAddr(\"glCompileShaderIncludeARB\"))\n\tgpCompressedMultiTexImage1DEXT = (C.GPCOMPRESSEDMULTITEXIMAGE1DEXT)(getProcAddr(\"glCompressedMultiTexImage1DEXT\"))\n\tgpCompressedMultiTexImage2DEXT = (C.GPCOMPRESSEDMULTITEXIMAGE2DEXT)(getProcAddr(\"glCompressedMultiTexImage2DEXT\"))\n\tgpCompressedMultiTexImage3DEXT = (C.GPCOMPRESSEDMULTITEXIMAGE3DEXT)(getProcAddr(\"glCompressedMultiTexImage3DEXT\"))\n\tgpCompressedMultiTexSubImage1DEXT = (C.GPCOMPRESSEDMULTITEXSUBIMAGE1DEXT)(getProcAddr(\"glCompressedMultiTexSubImage1DEXT\"))\n\tgpCompressedMultiTexSubImage2DEXT = (C.GPCOMPRESSEDMULTITEXSUBIMAGE2DEXT)(getProcAddr(\"glCompressedMultiTexSubImage2DEXT\"))\n\tgpCompressedMultiTexSubImage3DEXT = (C.GPCOMPRESSEDMULTITEXSUBIMAGE3DEXT)(getProcAddr(\"glCompressedMultiTexSubImage3DEXT\"))\n\tgpCompressedTexImage1D = (C.GPCOMPRESSEDTEXIMAGE1D)(getProcAddr(\"glCompressedTexImage1D\"))\n\tif gpCompressedTexImage1D == nil {\n\t\treturn errors.New(\"glCompressedTexImage1D\")\n\t}\n\tgpCompressedTexImage2D = (C.GPCOMPRESSEDTEXIMAGE2D)(getProcAddr(\"glCompressedTexImage2D\"))\n\tif gpCompressedTexImage2D == nil {\n\t\treturn errors.New(\"glCompressedTexImage2D\")\n\t}\n\tgpCompressedTexImage3D = (C.GPCOMPRESSEDTEXIMAGE3D)(getProcAddr(\"glCompressedTexImage3D\"))\n\tif gpCompressedTexImage3D == nil {\n\t\treturn errors.New(\"glCompressedTexImage3D\")\n\t}\n\tgpCompressedTexSubImage1D = (C.GPCOMPRESSEDTEXSUBIMAGE1D)(getProcAddr(\"glCompressedTexSubImage1D\"))\n\tif gpCompressedTexSubImage1D == nil {\n\t\treturn errors.New(\"glCompressedTexSubImage1D\")\n\t}\n\tgpCompressedTexSubImage2D = (C.GPCOMPRESSEDTEXSUBIMAGE2D)(getProcAddr(\"glCompressedTexSubImage2D\"))\n\tif gpCompressedTexSubImage2D == nil {\n\t\treturn errors.New(\"glCompressedTexSubImage2D\")\n\t}\n\tgpCompressedTexSubImage3D = (C.GPCOMPRESSEDTEXSUBIMAGE3D)(getProcAddr(\"glCompressedTexSubImage3D\"))\n\tif gpCompressedTexSubImage3D == nil {\n\t\treturn errors.New(\"glCompressedTexSubImage3D\")\n\t}\n\tgpCompressedTextureImage1DEXT = (C.GPCOMPRESSEDTEXTUREIMAGE1DEXT)(getProcAddr(\"glCompressedTextureImage1DEXT\"))\n\tgpCompressedTextureImage2DEXT = (C.GPCOMPRESSEDTEXTUREIMAGE2DEXT)(getProcAddr(\"glCompressedTextureImage2DEXT\"))\n\tgpCompressedTextureImage3DEXT = (C.GPCOMPRESSEDTEXTUREIMAGE3DEXT)(getProcAddr(\"glCompressedTextureImage3DEXT\"))\n\tgpCompressedTextureSubImage1D = (C.GPCOMPRESSEDTEXTURESUBIMAGE1D)(getProcAddr(\"glCompressedTextureSubImage1D\"))\n\tgpCompressedTextureSubImage1DEXT = (C.GPCOMPRESSEDTEXTURESUBIMAGE1DEXT)(getProcAddr(\"glCompressedTextureSubImage1DEXT\"))\n\tgpCompressedTextureSubImage2D = (C.GPCOMPRESSEDTEXTURESUBIMAGE2D)(getProcAddr(\"glCompressedTextureSubImage2D\"))\n\tgpCompressedTextureSubImage2DEXT = (C.GPCOMPRESSEDTEXTURESUBIMAGE2DEXT)(getProcAddr(\"glCompressedTextureSubImage2DEXT\"))\n\tgpCompressedTextureSubImage3D = (C.GPCOMPRESSEDTEXTURESUBIMAGE3D)(getProcAddr(\"glCompressedTextureSubImage3D\"))\n\tgpCompressedTextureSubImage3DEXT = (C.GPCOMPRESSEDTEXTURESUBIMAGE3DEXT)(getProcAddr(\"glCompressedTextureSubImage3DEXT\"))\n\tgpConservativeRasterParameterfNV = (C.GPCONSERVATIVERASTERPARAMETERFNV)(getProcAddr(\"glConservativeRasterParameterfNV\"))\n\tgpConservativeRasterParameteriNV = (C.GPCONSERVATIVERASTERPARAMETERINV)(getProcAddr(\"glConservativeRasterParameteriNV\"))\n\tgpCopyBufferSubData = (C.GPCOPYBUFFERSUBDATA)(getProcAddr(\"glCopyBufferSubData\"))\n\tif gpCopyBufferSubData == nil {\n\t\treturn errors.New(\"glCopyBufferSubData\")\n\t}\n\tgpCopyImageSubData = (C.GPCOPYIMAGESUBDATA)(getProcAddr(\"glCopyImageSubData\"))\n\tgpCopyMultiTexImage1DEXT = (C.GPCOPYMULTITEXIMAGE1DEXT)(getProcAddr(\"glCopyMultiTexImage1DEXT\"))\n\tgpCopyMultiTexImage2DEXT = (C.GPCOPYMULTITEXIMAGE2DEXT)(getProcAddr(\"glCopyMultiTexImage2DEXT\"))\n\tgpCopyMultiTexSubImage1DEXT = (C.GPCOPYMULTITEXSUBIMAGE1DEXT)(getProcAddr(\"glCopyMultiTexSubImage1DEXT\"))\n\tgpCopyMultiTexSubImage2DEXT = (C.GPCOPYMULTITEXSUBIMAGE2DEXT)(getProcAddr(\"glCopyMultiTexSubImage2DEXT\"))\n\tgpCopyMultiTexSubImage3DEXT = (C.GPCOPYMULTITEXSUBIMAGE3DEXT)(getProcAddr(\"glCopyMultiTexSubImage3DEXT\"))\n\tgpCopyNamedBufferSubData = (C.GPCOPYNAMEDBUFFERSUBDATA)(getProcAddr(\"glCopyNamedBufferSubData\"))\n\tgpCopyPathNV = (C.GPCOPYPATHNV)(getProcAddr(\"glCopyPathNV\"))\n\tgpCopyTexImage1D = (C.GPCOPYTEXIMAGE1D)(getProcAddr(\"glCopyTexImage1D\"))\n\tif gpCopyTexImage1D == nil {\n\t\treturn errors.New(\"glCopyTexImage1D\")\n\t}\n\tgpCopyTexImage2D = (C.GPCOPYTEXIMAGE2D)(getProcAddr(\"glCopyTexImage2D\"))\n\tif gpCopyTexImage2D == nil {\n\t\treturn errors.New(\"glCopyTexImage2D\")\n\t}\n\tgpCopyTexSubImage1D = (C.GPCOPYTEXSUBIMAGE1D)(getProcAddr(\"glCopyTexSubImage1D\"))\n\tif gpCopyTexSubImage1D == nil {\n\t\treturn errors.New(\"glCopyTexSubImage1D\")\n\t}\n\tgpCopyTexSubImage2D = (C.GPCOPYTEXSUBIMAGE2D)(getProcAddr(\"glCopyTexSubImage2D\"))\n\tif gpCopyTexSubImage2D == nil {\n\t\treturn errors.New(\"glCopyTexSubImage2D\")\n\t}\n\tgpCopyTexSubImage3D = (C.GPCOPYTEXSUBIMAGE3D)(getProcAddr(\"glCopyTexSubImage3D\"))\n\tif gpCopyTexSubImage3D == nil {\n\t\treturn errors.New(\"glCopyTexSubImage3D\")\n\t}\n\tgpCopyTextureImage1DEXT = (C.GPCOPYTEXTUREIMAGE1DEXT)(getProcAddr(\"glCopyTextureImage1DEXT\"))\n\tgpCopyTextureImage2DEXT = (C.GPCOPYTEXTUREIMAGE2DEXT)(getProcAddr(\"glCopyTextureImage2DEXT\"))\n\tgpCopyTextureSubImage1D = (C.GPCOPYTEXTURESUBIMAGE1D)(getProcAddr(\"glCopyTextureSubImage1D\"))\n\tgpCopyTextureSubImage1DEXT = (C.GPCOPYTEXTURESUBIMAGE1DEXT)(getProcAddr(\"glCopyTextureSubImage1DEXT\"))\n\tgpCopyTextureSubImage2D = (C.GPCOPYTEXTURESUBIMAGE2D)(getProcAddr(\"glCopyTextureSubImage2D\"))\n\tgpCopyTextureSubImage2DEXT = (C.GPCOPYTEXTURESUBIMAGE2DEXT)(getProcAddr(\"glCopyTextureSubImage2DEXT\"))\n\tgpCopyTextureSubImage3D = (C.GPCOPYTEXTURESUBIMAGE3D)(getProcAddr(\"glCopyTextureSubImage3D\"))\n\tgpCopyTextureSubImage3DEXT = (C.GPCOPYTEXTURESUBIMAGE3DEXT)(getProcAddr(\"glCopyTextureSubImage3DEXT\"))\n\tgpCoverFillPathInstancedNV = (C.GPCOVERFILLPATHINSTANCEDNV)(getProcAddr(\"glCoverFillPathInstancedNV\"))\n\tgpCoverFillPathNV = (C.GPCOVERFILLPATHNV)(getProcAddr(\"glCoverFillPathNV\"))\n\tgpCoverStrokePathInstancedNV = (C.GPCOVERSTROKEPATHINSTANCEDNV)(getProcAddr(\"glCoverStrokePathInstancedNV\"))\n\tgpCoverStrokePathNV = (C.GPCOVERSTROKEPATHNV)(getProcAddr(\"glCoverStrokePathNV\"))\n\tgpCoverageModulationNV = (C.GPCOVERAGEMODULATIONNV)(getProcAddr(\"glCoverageModulationNV\"))\n\tgpCoverageModulationTableNV = (C.GPCOVERAGEMODULATIONTABLENV)(getProcAddr(\"glCoverageModulationTableNV\"))\n\tgpCreateBuffers = (C.GPCREATEBUFFERS)(getProcAddr(\"glCreateBuffers\"))\n\tgpCreateCommandListsNV = (C.GPCREATECOMMANDLISTSNV)(getProcAddr(\"glCreateCommandListsNV\"))\n\tgpCreateFramebuffers = (C.GPCREATEFRAMEBUFFERS)(getProcAddr(\"glCreateFramebuffers\"))\n\tgpCreatePerfQueryINTEL = (C.GPCREATEPERFQUERYINTEL)(getProcAddr(\"glCreatePerfQueryINTEL\"))\n\tgpCreateProgram = (C.GPCREATEPROGRAM)(getProcAddr(\"glCreateProgram\"))\n\tif gpCreateProgram == nil {\n\t\treturn errors.New(\"glCreateProgram\")\n\t}\n\tgpCreateProgramPipelines = (C.GPCREATEPROGRAMPIPELINES)(getProcAddr(\"glCreateProgramPipelines\"))\n\tgpCreateQueries = (C.GPCREATEQUERIES)(getProcAddr(\"glCreateQueries\"))\n\tgpCreateRenderbuffers = (C.GPCREATERENDERBUFFERS)(getProcAddr(\"glCreateRenderbuffers\"))\n\tgpCreateSamplers = (C.GPCREATESAMPLERS)(getProcAddr(\"glCreateSamplers\"))\n\tgpCreateShader = (C.GPCREATESHADER)(getProcAddr(\"glCreateShader\"))\n\tif gpCreateShader == nil {\n\t\treturn errors.New(\"glCreateShader\")\n\t}\n\tgpCreateShaderProgramEXT = (C.GPCREATESHADERPROGRAMEXT)(getProcAddr(\"glCreateShaderProgramEXT\"))\n\tgpCreateShaderProgramv = (C.GPCREATESHADERPROGRAMV)(getProcAddr(\"glCreateShaderProgramv\"))\n\tif gpCreateShaderProgramv == nil {\n\t\treturn errors.New(\"glCreateShaderProgramv\")\n\t}\n\tgpCreateShaderProgramvEXT = (C.GPCREATESHADERPROGRAMVEXT)(getProcAddr(\"glCreateShaderProgramvEXT\"))\n\tgpCreateStatesNV = (C.GPCREATESTATESNV)(getProcAddr(\"glCreateStatesNV\"))\n\tgpCreateSyncFromCLeventARB = (C.GPCREATESYNCFROMCLEVENTARB)(getProcAddr(\"glCreateSyncFromCLeventARB\"))\n\tgpCreateTextures = (C.GPCREATETEXTURES)(getProcAddr(\"glCreateTextures\"))\n\tgpCreateTransformFeedbacks = (C.GPCREATETRANSFORMFEEDBACKS)(getProcAddr(\"glCreateTransformFeedbacks\"))\n\tgpCreateVertexArrays = (C.GPCREATEVERTEXARRAYS)(getProcAddr(\"glCreateVertexArrays\"))\n\tgpCullFace = (C.GPCULLFACE)(getProcAddr(\"glCullFace\"))\n\tif gpCullFace == nil {\n\t\treturn errors.New(\"glCullFace\")\n\t}\n\tgpDebugMessageCallback = (C.GPDEBUGMESSAGECALLBACK)(getProcAddr(\"glDebugMessageCallback\"))\n\tgpDebugMessageCallbackARB = (C.GPDEBUGMESSAGECALLBACKARB)(getProcAddr(\"glDebugMessageCallbackARB\"))\n\tgpDebugMessageCallbackKHR = (C.GPDEBUGMESSAGECALLBACKKHR)(getProcAddr(\"glDebugMessageCallbackKHR\"))\n\tgpDebugMessageControl = (C.GPDEBUGMESSAGECONTROL)(getProcAddr(\"glDebugMessageControl\"))\n\tgpDebugMessageControlARB = (C.GPDEBUGMESSAGECONTROLARB)(getProcAddr(\"glDebugMessageControlARB\"))\n\tgpDebugMessageControlKHR = (C.GPDEBUGMESSAGECONTROLKHR)(getProcAddr(\"glDebugMessageControlKHR\"))\n\tgpDebugMessageInsert = (C.GPDEBUGMESSAGEINSERT)(getProcAddr(\"glDebugMessageInsert\"))\n\tgpDebugMessageInsertARB = (C.GPDEBUGMESSAGEINSERTARB)(getProcAddr(\"glDebugMessageInsertARB\"))\n\tgpDebugMessageInsertKHR = (C.GPDEBUGMESSAGEINSERTKHR)(getProcAddr(\"glDebugMessageInsertKHR\"))\n\tgpDeleteBuffers = (C.GPDELETEBUFFERS)(getProcAddr(\"glDeleteBuffers\"))\n\tif gpDeleteBuffers == nil {\n\t\treturn errors.New(\"glDeleteBuffers\")\n\t}\n\tgpDeleteCommandListsNV = (C.GPDELETECOMMANDLISTSNV)(getProcAddr(\"glDeleteCommandListsNV\"))\n\tgpDeleteFramebuffers = (C.GPDELETEFRAMEBUFFERS)(getProcAddr(\"glDeleteFramebuffers\"))\n\tif gpDeleteFramebuffers == nil {\n\t\treturn errors.New(\"glDeleteFramebuffers\")\n\t}\n\tgpDeleteNamedStringARB = (C.GPDELETENAMEDSTRINGARB)(getProcAddr(\"glDeleteNamedStringARB\"))\n\tgpDeletePathsNV = (C.GPDELETEPATHSNV)(getProcAddr(\"glDeletePathsNV\"))\n\tgpDeletePerfMonitorsAMD = (C.GPDELETEPERFMONITORSAMD)(getProcAddr(\"glDeletePerfMonitorsAMD\"))\n\tgpDeletePerfQueryINTEL = (C.GPDELETEPERFQUERYINTEL)(getProcAddr(\"glDeletePerfQueryINTEL\"))\n\tgpDeleteProgram = (C.GPDELETEPROGRAM)(getProcAddr(\"glDeleteProgram\"))\n\tif gpDeleteProgram == nil {\n\t\treturn errors.New(\"glDeleteProgram\")\n\t}\n\tgpDeleteProgramPipelines = (C.GPDELETEPROGRAMPIPELINES)(getProcAddr(\"glDeleteProgramPipelines\"))\n\tif gpDeleteProgramPipelines == nil {\n\t\treturn errors.New(\"glDeleteProgramPipelines\")\n\t}\n\tgpDeleteProgramPipelinesEXT = (C.GPDELETEPROGRAMPIPELINESEXT)(getProcAddr(\"glDeleteProgramPipelinesEXT\"))\n\tgpDeleteQueries = (C.GPDELETEQUERIES)(getProcAddr(\"glDeleteQueries\"))\n\tif gpDeleteQueries == nil {\n\t\treturn errors.New(\"glDeleteQueries\")\n\t}\n\tgpDeleteRenderbuffers = (C.GPDELETERENDERBUFFERS)(getProcAddr(\"glDeleteRenderbuffers\"))\n\tif gpDeleteRenderbuffers == nil {\n\t\treturn errors.New(\"glDeleteRenderbuffers\")\n\t}\n\tgpDeleteSamplers = (C.GPDELETESAMPLERS)(getProcAddr(\"glDeleteSamplers\"))\n\tif gpDeleteSamplers == nil {\n\t\treturn errors.New(\"glDeleteSamplers\")\n\t}\n\tgpDeleteShader = (C.GPDELETESHADER)(getProcAddr(\"glDeleteShader\"))\n\tif gpDeleteShader == nil {\n\t\treturn errors.New(\"glDeleteShader\")\n\t}\n\tgpDeleteStatesNV = (C.GPDELETESTATESNV)(getProcAddr(\"glDeleteStatesNV\"))\n\tgpDeleteSync = (C.GPDELETESYNC)(getProcAddr(\"glDeleteSync\"))\n\tif gpDeleteSync == nil {\n\t\treturn errors.New(\"glDeleteSync\")\n\t}\n\tgpDeleteTextures = (C.GPDELETETEXTURES)(getProcAddr(\"glDeleteTextures\"))\n\tif gpDeleteTextures == nil {\n\t\treturn errors.New(\"glDeleteTextures\")\n\t}\n\tgpDeleteTransformFeedbacks = (C.GPDELETETRANSFORMFEEDBACKS)(getProcAddr(\"glDeleteTransformFeedbacks\"))\n\tif gpDeleteTransformFeedbacks == nil {\n\t\treturn errors.New(\"glDeleteTransformFeedbacks\")\n\t}\n\tgpDeleteVertexArrays = (C.GPDELETEVERTEXARRAYS)(getProcAddr(\"glDeleteVertexArrays\"))\n\tif gpDeleteVertexArrays == nil {\n\t\treturn errors.New(\"glDeleteVertexArrays\")\n\t}\n\tgpDepthBoundsdNV = (C.GPDEPTHBOUNDSDNV)(getProcAddr(\"glDepthBoundsdNV\"))\n\tgpDepthFunc = (C.GPDEPTHFUNC)(getProcAddr(\"glDepthFunc\"))\n\tif gpDepthFunc == nil {\n\t\treturn errors.New(\"glDepthFunc\")\n\t}\n\tgpDepthMask = (C.GPDEPTHMASK)(getProcAddr(\"glDepthMask\"))\n\tif gpDepthMask == nil {\n\t\treturn errors.New(\"glDepthMask\")\n\t}\n\tgpDepthRange = (C.GPDEPTHRANGE)(getProcAddr(\"glDepthRange\"))\n\tif gpDepthRange == nil {\n\t\treturn errors.New(\"glDepthRange\")\n\t}\n\tgpDepthRangeArraydvNV = (C.GPDEPTHRANGEARRAYDVNV)(getProcAddr(\"glDepthRangeArraydvNV\"))\n\tgpDepthRangeArrayv = (C.GPDEPTHRANGEARRAYV)(getProcAddr(\"glDepthRangeArrayv\"))\n\tif gpDepthRangeArrayv == nil {\n\t\treturn errors.New(\"glDepthRangeArrayv\")\n\t}\n\tgpDepthRangeIndexed = (C.GPDEPTHRANGEINDEXED)(getProcAddr(\"glDepthRangeIndexed\"))\n\tif gpDepthRangeIndexed == nil {\n\t\treturn errors.New(\"glDepthRangeIndexed\")\n\t}\n\tgpDepthRangeIndexeddNV = (C.GPDEPTHRANGEINDEXEDDNV)(getProcAddr(\"glDepthRangeIndexeddNV\"))\n\tgpDepthRangedNV = (C.GPDEPTHRANGEDNV)(getProcAddr(\"glDepthRangedNV\"))\n\tgpDepthRangef = (C.GPDEPTHRANGEF)(getProcAddr(\"glDepthRangef\"))\n\tif gpDepthRangef == nil {\n\t\treturn errors.New(\"glDepthRangef\")\n\t}\n\tgpDetachShader = (C.GPDETACHSHADER)(getProcAddr(\"glDetachShader\"))\n\tif gpDetachShader == nil {\n\t\treturn errors.New(\"glDetachShader\")\n\t}\n\tgpDisable = (C.GPDISABLE)(getProcAddr(\"glDisable\"))\n\tif gpDisable == nil {\n\t\treturn errors.New(\"glDisable\")\n\t}\n\tgpDisableClientStateIndexedEXT = (C.GPDISABLECLIENTSTATEINDEXEDEXT)(getProcAddr(\"glDisableClientStateIndexedEXT\"))\n\tgpDisableClientStateiEXT = (C.GPDISABLECLIENTSTATEIEXT)(getProcAddr(\"glDisableClientStateiEXT\"))\n\tgpDisableIndexedEXT = (C.GPDISABLEINDEXEDEXT)(getProcAddr(\"glDisableIndexedEXT\"))\n\tgpDisableVertexArrayAttrib = (C.GPDISABLEVERTEXARRAYATTRIB)(getProcAddr(\"glDisableVertexArrayAttrib\"))\n\tgpDisableVertexArrayAttribEXT = (C.GPDISABLEVERTEXARRAYATTRIBEXT)(getProcAddr(\"glDisableVertexArrayAttribEXT\"))\n\tgpDisableVertexArrayEXT = (C.GPDISABLEVERTEXARRAYEXT)(getProcAddr(\"glDisableVertexArrayEXT\"))\n\tgpDisableVertexAttribArray = (C.GPDISABLEVERTEXATTRIBARRAY)(getProcAddr(\"glDisableVertexAttribArray\"))\n\tif gpDisableVertexAttribArray == nil {\n\t\treturn errors.New(\"glDisableVertexAttribArray\")\n\t}\n\tgpDisablei = (C.GPDISABLEI)(getProcAddr(\"glDisablei\"))\n\tif gpDisablei == nil {\n\t\treturn errors.New(\"glDisablei\")\n\t}\n\tgpDispatchCompute = (C.GPDISPATCHCOMPUTE)(getProcAddr(\"glDispatchCompute\"))\n\tgpDispatchComputeGroupSizeARB = (C.GPDISPATCHCOMPUTEGROUPSIZEARB)(getProcAddr(\"glDispatchComputeGroupSizeARB\"))\n\tgpDispatchComputeIndirect = (C.GPDISPATCHCOMPUTEINDIRECT)(getProcAddr(\"glDispatchComputeIndirect\"))\n\tgpDrawArrays = (C.GPDRAWARRAYS)(getProcAddr(\"glDrawArrays\"))\n\tif gpDrawArrays == nil {\n\t\treturn errors.New(\"glDrawArrays\")\n\t}\n\tgpDrawArraysIndirect = (C.GPDRAWARRAYSINDIRECT)(getProcAddr(\"glDrawArraysIndirect\"))\n\tif gpDrawArraysIndirect == nil {\n\t\treturn errors.New(\"glDrawArraysIndirect\")\n\t}\n\tgpDrawArraysInstanced = (C.GPDRAWARRAYSINSTANCED)(getProcAddr(\"glDrawArraysInstanced\"))\n\tif gpDrawArraysInstanced == nil {\n\t\treturn errors.New(\"glDrawArraysInstanced\")\n\t}\n\tgpDrawArraysInstancedARB = (C.GPDRAWARRAYSINSTANCEDARB)(getProcAddr(\"glDrawArraysInstancedARB\"))\n\tgpDrawArraysInstancedBaseInstance = (C.GPDRAWARRAYSINSTANCEDBASEINSTANCE)(getProcAddr(\"glDrawArraysInstancedBaseInstance\"))\n\tif gpDrawArraysInstancedBaseInstance == nil {\n\t\treturn errors.New(\"glDrawArraysInstancedBaseInstance\")\n\t}\n\tgpDrawArraysInstancedEXT = (C.GPDRAWARRAYSINSTANCEDEXT)(getProcAddr(\"glDrawArraysInstancedEXT\"))\n\tgpDrawBuffer = (C.GPDRAWBUFFER)(getProcAddr(\"glDrawBuffer\"))\n\tif gpDrawBuffer == nil {\n\t\treturn errors.New(\"glDrawBuffer\")\n\t}\n\tgpDrawBuffers = (C.GPDRAWBUFFERS)(getProcAddr(\"glDrawBuffers\"))\n\tif gpDrawBuffers == nil {\n\t\treturn errors.New(\"glDrawBuffers\")\n\t}\n\tgpDrawCommandsAddressNV = (C.GPDRAWCOMMANDSADDRESSNV)(getProcAddr(\"glDrawCommandsAddressNV\"))\n\tgpDrawCommandsNV = (C.GPDRAWCOMMANDSNV)(getProcAddr(\"glDrawCommandsNV\"))\n\tgpDrawCommandsStatesAddressNV = (C.GPDRAWCOMMANDSSTATESADDRESSNV)(getProcAddr(\"glDrawCommandsStatesAddressNV\"))\n\tgpDrawCommandsStatesNV = (C.GPDRAWCOMMANDSSTATESNV)(getProcAddr(\"glDrawCommandsStatesNV\"))\n\tgpDrawElements = (C.GPDRAWELEMENTS)(getProcAddr(\"glDrawElements\"))\n\tif gpDrawElements == nil {\n\t\treturn errors.New(\"glDrawElements\")\n\t}\n\tgpDrawElementsBaseVertex = (C.GPDRAWELEMENTSBASEVERTEX)(getProcAddr(\"glDrawElementsBaseVertex\"))\n\tif gpDrawElementsBaseVertex == nil {\n\t\treturn errors.New(\"glDrawElementsBaseVertex\")\n\t}\n\tgpDrawElementsIndirect = (C.GPDRAWELEMENTSINDIRECT)(getProcAddr(\"glDrawElementsIndirect\"))\n\tif gpDrawElementsIndirect == nil {\n\t\treturn errors.New(\"glDrawElementsIndirect\")\n\t}\n\tgpDrawElementsInstanced = (C.GPDRAWELEMENTSINSTANCED)(getProcAddr(\"glDrawElementsInstanced\"))\n\tif gpDrawElementsInstanced == nil {\n\t\treturn errors.New(\"glDrawElementsInstanced\")\n\t}\n\tgpDrawElementsInstancedARB = (C.GPDRAWELEMENTSINSTANCEDARB)(getProcAddr(\"glDrawElementsInstancedARB\"))\n\tgpDrawElementsInstancedBaseInstance = (C.GPDRAWELEMENTSINSTANCEDBASEINSTANCE)(getProcAddr(\"glDrawElementsInstancedBaseInstance\"))\n\tif gpDrawElementsInstancedBaseInstance == nil {\n\t\treturn errors.New(\"glDrawElementsInstancedBaseInstance\")\n\t}\n\tgpDrawElementsInstancedBaseVertex = (C.GPDRAWELEMENTSINSTANCEDBASEVERTEX)(getProcAddr(\"glDrawElementsInstancedBaseVertex\"))\n\tif gpDrawElementsInstancedBaseVertex == nil {\n\t\treturn errors.New(\"glDrawElementsInstancedBaseVertex\")\n\t}\n\tgpDrawElementsInstancedBaseVertexBaseInstance = (C.GPDRAWELEMENTSINSTANCEDBASEVERTEXBASEINSTANCE)(getProcAddr(\"glDrawElementsInstancedBaseVertexBaseInstance\"))\n\tif gpDrawElementsInstancedBaseVertexBaseInstance == nil {\n\t\treturn errors.New(\"glDrawElementsInstancedBaseVertexBaseInstance\")\n\t}\n\tgpDrawElementsInstancedEXT = (C.GPDRAWELEMENTSINSTANCEDEXT)(getProcAddr(\"glDrawElementsInstancedEXT\"))\n\tgpDrawMeshTasksIndirectNV = (C.GPDRAWMESHTASKSINDIRECTNV)(getProcAddr(\"glDrawMeshTasksIndirectNV\"))\n\tgpDrawMeshTasksNV = (C.GPDRAWMESHTASKSNV)(getProcAddr(\"glDrawMeshTasksNV\"))\n\tgpDrawRangeElements = (C.GPDRAWRANGEELEMENTS)(getProcAddr(\"glDrawRangeElements\"))\n\tif gpDrawRangeElements == nil {\n\t\treturn errors.New(\"glDrawRangeElements\")\n\t}\n\tgpDrawRangeElementsBaseVertex = (C.GPDRAWRANGEELEMENTSBASEVERTEX)(getProcAddr(\"glDrawRangeElementsBaseVertex\"))\n\tif gpDrawRangeElementsBaseVertex == nil {\n\t\treturn errors.New(\"glDrawRangeElementsBaseVertex\")\n\t}\n\tgpDrawTransformFeedback = (C.GPDRAWTRANSFORMFEEDBACK)(getProcAddr(\"glDrawTransformFeedback\"))\n\tif gpDrawTransformFeedback == nil {\n\t\treturn errors.New(\"glDrawTransformFeedback\")\n\t}\n\tgpDrawTransformFeedbackInstanced = (C.GPDRAWTRANSFORMFEEDBACKINSTANCED)(getProcAddr(\"glDrawTransformFeedbackInstanced\"))\n\tif gpDrawTransformFeedbackInstanced == nil {\n\t\treturn errors.New(\"glDrawTransformFeedbackInstanced\")\n\t}\n\tgpDrawTransformFeedbackStream = (C.GPDRAWTRANSFORMFEEDBACKSTREAM)(getProcAddr(\"glDrawTransformFeedbackStream\"))\n\tif gpDrawTransformFeedbackStream == nil {\n\t\treturn errors.New(\"glDrawTransformFeedbackStream\")\n\t}\n\tgpDrawTransformFeedbackStreamInstanced = (C.GPDRAWTRANSFORMFEEDBACKSTREAMINSTANCED)(getProcAddr(\"glDrawTransformFeedbackStreamInstanced\"))\n\tif gpDrawTransformFeedbackStreamInstanced == nil {\n\t\treturn errors.New(\"glDrawTransformFeedbackStreamInstanced\")\n\t}\n\tgpDrawVkImageNV = (C.GPDRAWVKIMAGENV)(getProcAddr(\"glDrawVkImageNV\"))\n\tgpEGLImageTargetTexStorageEXT = (C.GPEGLIMAGETARGETTEXSTORAGEEXT)(getProcAddr(\"glEGLImageTargetTexStorageEXT\"))\n\tgpEGLImageTargetTextureStorageEXT = (C.GPEGLIMAGETARGETTEXTURESTORAGEEXT)(getProcAddr(\"glEGLImageTargetTextureStorageEXT\"))\n\tgpEdgeFlagFormatNV = (C.GPEDGEFLAGFORMATNV)(getProcAddr(\"glEdgeFlagFormatNV\"))\n\tgpEnable = (C.GPENABLE)(getProcAddr(\"glEnable\"))\n\tif gpEnable == nil {\n\t\treturn errors.New(\"glEnable\")\n\t}\n\tgpEnableClientStateIndexedEXT = (C.GPENABLECLIENTSTATEINDEXEDEXT)(getProcAddr(\"glEnableClientStateIndexedEXT\"))\n\tgpEnableClientStateiEXT = (C.GPENABLECLIENTSTATEIEXT)(getProcAddr(\"glEnableClientStateiEXT\"))\n\tgpEnableIndexedEXT = (C.GPENABLEINDEXEDEXT)(getProcAddr(\"glEnableIndexedEXT\"))\n\tgpEnableVertexArrayAttrib = (C.GPENABLEVERTEXARRAYATTRIB)(getProcAddr(\"glEnableVertexArrayAttrib\"))\n\tgpEnableVertexArrayAttribEXT = (C.GPENABLEVERTEXARRAYATTRIBEXT)(getProcAddr(\"glEnableVertexArrayAttribEXT\"))\n\tgpEnableVertexArrayEXT = (C.GPENABLEVERTEXARRAYEXT)(getProcAddr(\"glEnableVertexArrayEXT\"))\n\tgpEnableVertexAttribArray = (C.GPENABLEVERTEXATTRIBARRAY)(getProcAddr(\"glEnableVertexAttribArray\"))\n\tif gpEnableVertexAttribArray == nil {\n\t\treturn errors.New(\"glEnableVertexAttribArray\")\n\t}\n\tgpEnablei = (C.GPENABLEI)(getProcAddr(\"glEnablei\"))\n\tif gpEnablei == nil {\n\t\treturn errors.New(\"glEnablei\")\n\t}\n\tgpEndConditionalRender = (C.GPENDCONDITIONALRENDER)(getProcAddr(\"glEndConditionalRender\"))\n\tif gpEndConditionalRender == nil {\n\t\treturn errors.New(\"glEndConditionalRender\")\n\t}\n\tgpEndConditionalRenderNV = (C.GPENDCONDITIONALRENDERNV)(getProcAddr(\"glEndConditionalRenderNV\"))\n\tgpEndPerfMonitorAMD = (C.GPENDPERFMONITORAMD)(getProcAddr(\"glEndPerfMonitorAMD\"))\n\tgpEndPerfQueryINTEL = (C.GPENDPERFQUERYINTEL)(getProcAddr(\"glEndPerfQueryINTEL\"))\n\tgpEndQuery = (C.GPENDQUERY)(getProcAddr(\"glEndQuery\"))\n\tif gpEndQuery == nil {\n\t\treturn errors.New(\"glEndQuery\")\n\t}\n\tgpEndQueryIndexed = (C.GPENDQUERYINDEXED)(getProcAddr(\"glEndQueryIndexed\"))\n\tif gpEndQueryIndexed == nil {\n\t\treturn errors.New(\"glEndQueryIndexed\")\n\t}\n\tgpEndTransformFeedback = (C.GPENDTRANSFORMFEEDBACK)(getProcAddr(\"glEndTransformFeedback\"))\n\tif gpEndTransformFeedback == nil {\n\t\treturn errors.New(\"glEndTransformFeedback\")\n\t}\n\tgpEvaluateDepthValuesARB = (C.GPEVALUATEDEPTHVALUESARB)(getProcAddr(\"glEvaluateDepthValuesARB\"))\n\tgpFenceSync = (C.GPFENCESYNC)(getProcAddr(\"glFenceSync\"))\n\tif gpFenceSync == nil {\n\t\treturn errors.New(\"glFenceSync\")\n\t}\n\tgpFinish = (C.GPFINISH)(getProcAddr(\"glFinish\"))\n\tif gpFinish == nil {\n\t\treturn errors.New(\"glFinish\")\n\t}\n\tgpFlush = (C.GPFLUSH)(getProcAddr(\"glFlush\"))\n\tif gpFlush == nil {\n\t\treturn errors.New(\"glFlush\")\n\t}\n\tgpFlushMappedBufferRange = (C.GPFLUSHMAPPEDBUFFERRANGE)(getProcAddr(\"glFlushMappedBufferRange\"))\n\tif gpFlushMappedBufferRange == nil {\n\t\treturn errors.New(\"glFlushMappedBufferRange\")\n\t}\n\tgpFlushMappedNamedBufferRange = (C.GPFLUSHMAPPEDNAMEDBUFFERRANGE)(getProcAddr(\"glFlushMappedNamedBufferRange\"))\n\tgpFlushMappedNamedBufferRangeEXT = (C.GPFLUSHMAPPEDNAMEDBUFFERRANGEEXT)(getProcAddr(\"glFlushMappedNamedBufferRangeEXT\"))\n\tgpFogCoordFormatNV = (C.GPFOGCOORDFORMATNV)(getProcAddr(\"glFogCoordFormatNV\"))\n\tgpFragmentCoverageColorNV = (C.GPFRAGMENTCOVERAGECOLORNV)(getProcAddr(\"glFragmentCoverageColorNV\"))\n\tgpFramebufferDrawBufferEXT = (C.GPFRAMEBUFFERDRAWBUFFEREXT)(getProcAddr(\"glFramebufferDrawBufferEXT\"))\n\tgpFramebufferDrawBuffersEXT = (C.GPFRAMEBUFFERDRAWBUFFERSEXT)(getProcAddr(\"glFramebufferDrawBuffersEXT\"))\n\tgpFramebufferFetchBarrierEXT = (C.GPFRAMEBUFFERFETCHBARRIEREXT)(getProcAddr(\"glFramebufferFetchBarrierEXT\"))\n\tgpFramebufferParameteri = (C.GPFRAMEBUFFERPARAMETERI)(getProcAddr(\"glFramebufferParameteri\"))\n\tgpFramebufferParameteriMESA = (C.GPFRAMEBUFFERPARAMETERIMESA)(getProcAddr(\"glFramebufferParameteriMESA\"))\n\tgpFramebufferReadBufferEXT = (C.GPFRAMEBUFFERREADBUFFEREXT)(getProcAddr(\"glFramebufferReadBufferEXT\"))\n\tgpFramebufferRenderbuffer = (C.GPFRAMEBUFFERRENDERBUFFER)(getProcAddr(\"glFramebufferRenderbuffer\"))\n\tif gpFramebufferRenderbuffer == nil {\n\t\treturn errors.New(\"glFramebufferRenderbuffer\")\n\t}\n\tgpFramebufferSampleLocationsfvARB = (C.GPFRAMEBUFFERSAMPLELOCATIONSFVARB)(getProcAddr(\"glFramebufferSampleLocationsfvARB\"))\n\tgpFramebufferSampleLocationsfvNV = (C.GPFRAMEBUFFERSAMPLELOCATIONSFVNV)(getProcAddr(\"glFramebufferSampleLocationsfvNV\"))\n\tgpFramebufferTexture = (C.GPFRAMEBUFFERTEXTURE)(getProcAddr(\"glFramebufferTexture\"))\n\tif gpFramebufferTexture == nil {\n\t\treturn errors.New(\"glFramebufferTexture\")\n\t}\n\tgpFramebufferTexture1D = (C.GPFRAMEBUFFERTEXTURE1D)(getProcAddr(\"glFramebufferTexture1D\"))\n\tif gpFramebufferTexture1D == nil {\n\t\treturn errors.New(\"glFramebufferTexture1D\")\n\t}\n\tgpFramebufferTexture2D = (C.GPFRAMEBUFFERTEXTURE2D)(getProcAddr(\"glFramebufferTexture2D\"))\n\tif gpFramebufferTexture2D == nil {\n\t\treturn errors.New(\"glFramebufferTexture2D\")\n\t}\n\tgpFramebufferTexture3D = (C.GPFRAMEBUFFERTEXTURE3D)(getProcAddr(\"glFramebufferTexture3D\"))\n\tif gpFramebufferTexture3D == nil {\n\t\treturn errors.New(\"glFramebufferTexture3D\")\n\t}\n\tgpFramebufferTextureARB = (C.GPFRAMEBUFFERTEXTUREARB)(getProcAddr(\"glFramebufferTextureARB\"))\n\tgpFramebufferTextureFaceARB = (C.GPFRAMEBUFFERTEXTUREFACEARB)(getProcAddr(\"glFramebufferTextureFaceARB\"))\n\tgpFramebufferTextureLayer = (C.GPFRAMEBUFFERTEXTURELAYER)(getProcAddr(\"glFramebufferTextureLayer\"))\n\tif gpFramebufferTextureLayer == nil {\n\t\treturn errors.New(\"glFramebufferTextureLayer\")\n\t}\n\tgpFramebufferTextureLayerARB = (C.GPFRAMEBUFFERTEXTURELAYERARB)(getProcAddr(\"glFramebufferTextureLayerARB\"))\n\tgpFramebufferTextureMultiviewOVR = (C.GPFRAMEBUFFERTEXTUREMULTIVIEWOVR)(getProcAddr(\"glFramebufferTextureMultiviewOVR\"))\n\tgpFrontFace = (C.GPFRONTFACE)(getProcAddr(\"glFrontFace\"))\n\tif gpFrontFace == nil {\n\t\treturn errors.New(\"glFrontFace\")\n\t}\n\tgpGenBuffers = (C.GPGENBUFFERS)(getProcAddr(\"glGenBuffers\"))\n\tif gpGenBuffers == nil {\n\t\treturn errors.New(\"glGenBuffers\")\n\t}\n\tgpGenFramebuffers = (C.GPGENFRAMEBUFFERS)(getProcAddr(\"glGenFramebuffers\"))\n\tif gpGenFramebuffers == nil {\n\t\treturn errors.New(\"glGenFramebuffers\")\n\t}\n\tgpGenPathsNV = (C.GPGENPATHSNV)(getProcAddr(\"glGenPathsNV\"))\n\tgpGenPerfMonitorsAMD = (C.GPGENPERFMONITORSAMD)(getProcAddr(\"glGenPerfMonitorsAMD\"))\n\tgpGenProgramPipelines = (C.GPGENPROGRAMPIPELINES)(getProcAddr(\"glGenProgramPipelines\"))\n\tif gpGenProgramPipelines == nil {\n\t\treturn errors.New(\"glGenProgramPipelines\")\n\t}\n\tgpGenProgramPipelinesEXT = (C.GPGENPROGRAMPIPELINESEXT)(getProcAddr(\"glGenProgramPipelinesEXT\"))\n\tgpGenQueries = (C.GPGENQUERIES)(getProcAddr(\"glGenQueries\"))\n\tif gpGenQueries == nil {\n\t\treturn errors.New(\"glGenQueries\")\n\t}\n\tgpGenRenderbuffers = (C.GPGENRENDERBUFFERS)(getProcAddr(\"glGenRenderbuffers\"))\n\tif gpGenRenderbuffers == nil {\n\t\treturn errors.New(\"glGenRenderbuffers\")\n\t}\n\tgpGenSamplers = (C.GPGENSAMPLERS)(getProcAddr(\"glGenSamplers\"))\n\tif gpGenSamplers == nil {\n\t\treturn errors.New(\"glGenSamplers\")\n\t}\n\tgpGenTextures = (C.GPGENTEXTURES)(getProcAddr(\"glGenTextures\"))\n\tif gpGenTextures == nil {\n\t\treturn errors.New(\"glGenTextures\")\n\t}\n\tgpGenTransformFeedbacks = (C.GPGENTRANSFORMFEEDBACKS)(getProcAddr(\"glGenTransformFeedbacks\"))\n\tif gpGenTransformFeedbacks == nil {\n\t\treturn errors.New(\"glGenTransformFeedbacks\")\n\t}\n\tgpGenVertexArrays = (C.GPGENVERTEXARRAYS)(getProcAddr(\"glGenVertexArrays\"))\n\tif gpGenVertexArrays == nil {\n\t\treturn errors.New(\"glGenVertexArrays\")\n\t}\n\tgpGenerateMipmap = (C.GPGENERATEMIPMAP)(getProcAddr(\"glGenerateMipmap\"))\n\tif gpGenerateMipmap == nil {\n\t\treturn errors.New(\"glGenerateMipmap\")\n\t}\n\tgpGenerateMultiTexMipmapEXT = (C.GPGENERATEMULTITEXMIPMAPEXT)(getProcAddr(\"glGenerateMultiTexMipmapEXT\"))\n\tgpGenerateTextureMipmap = (C.GPGENERATETEXTUREMIPMAP)(getProcAddr(\"glGenerateTextureMipmap\"))\n\tgpGenerateTextureMipmapEXT = (C.GPGENERATETEXTUREMIPMAPEXT)(getProcAddr(\"glGenerateTextureMipmapEXT\"))\n\tgpGetActiveAtomicCounterBufferiv = (C.GPGETACTIVEATOMICCOUNTERBUFFERIV)(getProcAddr(\"glGetActiveAtomicCounterBufferiv\"))\n\tif gpGetActiveAtomicCounterBufferiv == nil {\n\t\treturn errors.New(\"glGetActiveAtomicCounterBufferiv\")\n\t}\n\tgpGetActiveAttrib = (C.GPGETACTIVEATTRIB)(getProcAddr(\"glGetActiveAttrib\"))\n\tif gpGetActiveAttrib == nil {\n\t\treturn errors.New(\"glGetActiveAttrib\")\n\t}\n\tgpGetActiveSubroutineName = (C.GPGETACTIVESUBROUTINENAME)(getProcAddr(\"glGetActiveSubroutineName\"))\n\tif gpGetActiveSubroutineName == nil {\n\t\treturn errors.New(\"glGetActiveSubroutineName\")\n\t}\n\tgpGetActiveSubroutineUniformName = (C.GPGETACTIVESUBROUTINEUNIFORMNAME)(getProcAddr(\"glGetActiveSubroutineUniformName\"))\n\tif gpGetActiveSubroutineUniformName == nil {\n\t\treturn errors.New(\"glGetActiveSubroutineUniformName\")\n\t}\n\tgpGetActiveSubroutineUniformiv = (C.GPGETACTIVESUBROUTINEUNIFORMIV)(getProcAddr(\"glGetActiveSubroutineUniformiv\"))\n\tif gpGetActiveSubroutineUniformiv == nil {\n\t\treturn errors.New(\"glGetActiveSubroutineUniformiv\")\n\t}\n\tgpGetActiveUniform = (C.GPGETACTIVEUNIFORM)(getProcAddr(\"glGetActiveUniform\"))\n\tif gpGetActiveUniform == nil {\n\t\treturn errors.New(\"glGetActiveUniform\")\n\t}\n\tgpGetActiveUniformBlockName = (C.GPGETACTIVEUNIFORMBLOCKNAME)(getProcAddr(\"glGetActiveUniformBlockName\"))\n\tif gpGetActiveUniformBlockName == nil {\n\t\treturn errors.New(\"glGetActiveUniformBlockName\")\n\t}\n\tgpGetActiveUniformBlockiv = (C.GPGETACTIVEUNIFORMBLOCKIV)(getProcAddr(\"glGetActiveUniformBlockiv\"))\n\tif gpGetActiveUniformBlockiv == nil {\n\t\treturn errors.New(\"glGetActiveUniformBlockiv\")\n\t}\n\tgpGetActiveUniformName = (C.GPGETACTIVEUNIFORMNAME)(getProcAddr(\"glGetActiveUniformName\"))\n\tif gpGetActiveUniformName == nil {\n\t\treturn errors.New(\"glGetActiveUniformName\")\n\t}\n\tgpGetActiveUniformsiv = (C.GPGETACTIVEUNIFORMSIV)(getProcAddr(\"glGetActiveUniformsiv\"))\n\tif gpGetActiveUniformsiv == nil {\n\t\treturn errors.New(\"glGetActiveUniformsiv\")\n\t}\n\tgpGetAttachedShaders = (C.GPGETATTACHEDSHADERS)(getProcAddr(\"glGetAttachedShaders\"))\n\tif gpGetAttachedShaders == nil {\n\t\treturn errors.New(\"glGetAttachedShaders\")\n\t}\n\tgpGetAttribLocation = (C.GPGETATTRIBLOCATION)(getProcAddr(\"glGetAttribLocation\"))\n\tif gpGetAttribLocation == nil {\n\t\treturn errors.New(\"glGetAttribLocation\")\n\t}\n\tgpGetBooleanIndexedvEXT = (C.GPGETBOOLEANINDEXEDVEXT)(getProcAddr(\"glGetBooleanIndexedvEXT\"))\n\tgpGetBooleani_v = (C.GPGETBOOLEANI_V)(getProcAddr(\"glGetBooleani_v\"))\n\tif gpGetBooleani_v == nil {\n\t\treturn errors.New(\"glGetBooleani_v\")\n\t}\n\tgpGetBooleanv = (C.GPGETBOOLEANV)(getProcAddr(\"glGetBooleanv\"))\n\tif gpGetBooleanv == nil {\n\t\treturn errors.New(\"glGetBooleanv\")\n\t}\n\tgpGetBufferParameteri64v = (C.GPGETBUFFERPARAMETERI64V)(getProcAddr(\"glGetBufferParameteri64v\"))\n\tif gpGetBufferParameteri64v == nil {\n\t\treturn errors.New(\"glGetBufferParameteri64v\")\n\t}\n\tgpGetBufferParameteriv = (C.GPGETBUFFERPARAMETERIV)(getProcAddr(\"glGetBufferParameteriv\"))\n\tif gpGetBufferParameteriv == nil {\n\t\treturn errors.New(\"glGetBufferParameteriv\")\n\t}\n\tgpGetBufferParameterui64vNV = (C.GPGETBUFFERPARAMETERUI64VNV)(getProcAddr(\"glGetBufferParameterui64vNV\"))\n\tgpGetBufferPointerv = (C.GPGETBUFFERPOINTERV)(getProcAddr(\"glGetBufferPointerv\"))\n\tif gpGetBufferPointerv == nil {\n\t\treturn errors.New(\"glGetBufferPointerv\")\n\t}\n\tgpGetBufferSubData = (C.GPGETBUFFERSUBDATA)(getProcAddr(\"glGetBufferSubData\"))\n\tif gpGetBufferSubData == nil {\n\t\treturn errors.New(\"glGetBufferSubData\")\n\t}\n\tgpGetCommandHeaderNV = (C.GPGETCOMMANDHEADERNV)(getProcAddr(\"glGetCommandHeaderNV\"))\n\tgpGetCompressedMultiTexImageEXT = (C.GPGETCOMPRESSEDMULTITEXIMAGEEXT)(getProcAddr(\"glGetCompressedMultiTexImageEXT\"))\n\tgpGetCompressedTexImage = (C.GPGETCOMPRESSEDTEXIMAGE)(getProcAddr(\"glGetCompressedTexImage\"))\n\tif gpGetCompressedTexImage == nil {\n\t\treturn errors.New(\"glGetCompressedTexImage\")\n\t}\n\tgpGetCompressedTextureImage = (C.GPGETCOMPRESSEDTEXTUREIMAGE)(getProcAddr(\"glGetCompressedTextureImage\"))\n\tgpGetCompressedTextureImageEXT = (C.GPGETCOMPRESSEDTEXTUREIMAGEEXT)(getProcAddr(\"glGetCompressedTextureImageEXT\"))\n\tgpGetCompressedTextureSubImage = (C.GPGETCOMPRESSEDTEXTURESUBIMAGE)(getProcAddr(\"glGetCompressedTextureSubImage\"))\n\tgpGetCoverageModulationTableNV = (C.GPGETCOVERAGEMODULATIONTABLENV)(getProcAddr(\"glGetCoverageModulationTableNV\"))\n\tgpGetDebugMessageLog = (C.GPGETDEBUGMESSAGELOG)(getProcAddr(\"glGetDebugMessageLog\"))\n\tgpGetDebugMessageLogARB = (C.GPGETDEBUGMESSAGELOGARB)(getProcAddr(\"glGetDebugMessageLogARB\"))\n\tgpGetDebugMessageLogKHR = (C.GPGETDEBUGMESSAGELOGKHR)(getProcAddr(\"glGetDebugMessageLogKHR\"))\n\tgpGetDoubleIndexedvEXT = (C.GPGETDOUBLEINDEXEDVEXT)(getProcAddr(\"glGetDoubleIndexedvEXT\"))\n\tgpGetDoublei_v = (C.GPGETDOUBLEI_V)(getProcAddr(\"glGetDoublei_v\"))\n\tif gpGetDoublei_v == nil {\n\t\treturn errors.New(\"glGetDoublei_v\")\n\t}\n\tgpGetDoublei_vEXT = (C.GPGETDOUBLEI_VEXT)(getProcAddr(\"glGetDoublei_vEXT\"))\n\tgpGetDoublev = (C.GPGETDOUBLEV)(getProcAddr(\"glGetDoublev\"))\n\tif gpGetDoublev == nil {\n\t\treturn errors.New(\"glGetDoublev\")\n\t}\n\tgpGetError = (C.GPGETERROR)(getProcAddr(\"glGetError\"))\n\tif gpGetError == nil {\n\t\treturn errors.New(\"glGetError\")\n\t}\n\tgpGetFirstPerfQueryIdINTEL = (C.GPGETFIRSTPERFQUERYIDINTEL)(getProcAddr(\"glGetFirstPerfQueryIdINTEL\"))\n\tgpGetFloatIndexedvEXT = (C.GPGETFLOATINDEXEDVEXT)(getProcAddr(\"glGetFloatIndexedvEXT\"))\n\tgpGetFloati_v = (C.GPGETFLOATI_V)(getProcAddr(\"glGetFloati_v\"))\n\tif gpGetFloati_v == nil {\n\t\treturn errors.New(\"glGetFloati_v\")\n\t}\n\tgpGetFloati_vEXT = (C.GPGETFLOATI_VEXT)(getProcAddr(\"glGetFloati_vEXT\"))\n\tgpGetFloatv = (C.GPGETFLOATV)(getProcAddr(\"glGetFloatv\"))\n\tif gpGetFloatv == nil {\n\t\treturn errors.New(\"glGetFloatv\")\n\t}\n\tgpGetFragDataIndex = (C.GPGETFRAGDATAINDEX)(getProcAddr(\"glGetFragDataIndex\"))\n\tif gpGetFragDataIndex == nil {\n\t\treturn errors.New(\"glGetFragDataIndex\")\n\t}\n\tgpGetFragDataLocation = (C.GPGETFRAGDATALOCATION)(getProcAddr(\"glGetFragDataLocation\"))\n\tif gpGetFragDataLocation == nil {\n\t\treturn errors.New(\"glGetFragDataLocation\")\n\t}\n\tgpGetFramebufferAttachmentParameteriv = (C.GPGETFRAMEBUFFERATTACHMENTPARAMETERIV)(getProcAddr(\"glGetFramebufferAttachmentParameteriv\"))\n\tif gpGetFramebufferAttachmentParameteriv == nil {\n\t\treturn errors.New(\"glGetFramebufferAttachmentParameteriv\")\n\t}\n\tgpGetFramebufferParameteriv = (C.GPGETFRAMEBUFFERPARAMETERIV)(getProcAddr(\"glGetFramebufferParameteriv\"))\n\tgpGetFramebufferParameterivEXT = (C.GPGETFRAMEBUFFERPARAMETERIVEXT)(getProcAddr(\"glGetFramebufferParameterivEXT\"))\n\tgpGetFramebufferParameterivMESA = (C.GPGETFRAMEBUFFERPARAMETERIVMESA)(getProcAddr(\"glGetFramebufferParameterivMESA\"))\n\tgpGetGraphicsResetStatus = (C.GPGETGRAPHICSRESETSTATUS)(getProcAddr(\"glGetGraphicsResetStatus\"))\n\tgpGetGraphicsResetStatusARB = (C.GPGETGRAPHICSRESETSTATUSARB)(getProcAddr(\"glGetGraphicsResetStatusARB\"))\n\tgpGetGraphicsResetStatusKHR = (C.GPGETGRAPHICSRESETSTATUSKHR)(getProcAddr(\"glGetGraphicsResetStatusKHR\"))\n\tgpGetImageHandleARB = (C.GPGETIMAGEHANDLEARB)(getProcAddr(\"glGetImageHandleARB\"))\n\tgpGetImageHandleNV = (C.GPGETIMAGEHANDLENV)(getProcAddr(\"glGetImageHandleNV\"))\n\tgpGetInteger64i_v = (C.GPGETINTEGER64I_V)(getProcAddr(\"glGetInteger64i_v\"))\n\tif gpGetInteger64i_v == nil {\n\t\treturn errors.New(\"glGetInteger64i_v\")\n\t}\n\tgpGetInteger64v = (C.GPGETINTEGER64V)(getProcAddr(\"glGetInteger64v\"))\n\tif gpGetInteger64v == nil {\n\t\treturn errors.New(\"glGetInteger64v\")\n\t}\n\tgpGetIntegerIndexedvEXT = (C.GPGETINTEGERINDEXEDVEXT)(getProcAddr(\"glGetIntegerIndexedvEXT\"))\n\tgpGetIntegeri_v = (C.GPGETINTEGERI_V)(getProcAddr(\"glGetIntegeri_v\"))\n\tif gpGetIntegeri_v == nil {\n\t\treturn errors.New(\"glGetIntegeri_v\")\n\t}\n\tgpGetIntegerui64i_vNV = (C.GPGETINTEGERUI64I_VNV)(getProcAddr(\"glGetIntegerui64i_vNV\"))\n\tgpGetIntegerui64vNV = (C.GPGETINTEGERUI64VNV)(getProcAddr(\"glGetIntegerui64vNV\"))\n\tgpGetIntegerv = (C.GPGETINTEGERV)(getProcAddr(\"glGetIntegerv\"))\n\tif gpGetIntegerv == nil {\n\t\treturn errors.New(\"glGetIntegerv\")\n\t}\n\tgpGetInternalformatSampleivNV = (C.GPGETINTERNALFORMATSAMPLEIVNV)(getProcAddr(\"glGetInternalformatSampleivNV\"))\n\tgpGetInternalformati64v = (C.GPGETINTERNALFORMATI64V)(getProcAddr(\"glGetInternalformati64v\"))\n\tgpGetInternalformativ = (C.GPGETINTERNALFORMATIV)(getProcAddr(\"glGetInternalformativ\"))\n\tif gpGetInternalformativ == nil {\n\t\treturn errors.New(\"glGetInternalformativ\")\n\t}\n\tgpGetMemoryObjectDetachedResourcesuivNV = (C.GPGETMEMORYOBJECTDETACHEDRESOURCESUIVNV)(getProcAddr(\"glGetMemoryObjectDetachedResourcesuivNV\"))\n\tgpGetMultiTexEnvfvEXT = (C.GPGETMULTITEXENVFVEXT)(getProcAddr(\"glGetMultiTexEnvfvEXT\"))\n\tgpGetMultiTexEnvivEXT = (C.GPGETMULTITEXENVIVEXT)(getProcAddr(\"glGetMultiTexEnvivEXT\"))\n\tgpGetMultiTexGendvEXT = (C.GPGETMULTITEXGENDVEXT)(getProcAddr(\"glGetMultiTexGendvEXT\"))\n\tgpGetMultiTexGenfvEXT = (C.GPGETMULTITEXGENFVEXT)(getProcAddr(\"glGetMultiTexGenfvEXT\"))\n\tgpGetMultiTexGenivEXT = (C.GPGETMULTITEXGENIVEXT)(getProcAddr(\"glGetMultiTexGenivEXT\"))\n\tgpGetMultiTexImageEXT = (C.GPGETMULTITEXIMAGEEXT)(getProcAddr(\"glGetMultiTexImageEXT\"))\n\tgpGetMultiTexLevelParameterfvEXT = (C.GPGETMULTITEXLEVELPARAMETERFVEXT)(getProcAddr(\"glGetMultiTexLevelParameterfvEXT\"))\n\tgpGetMultiTexLevelParameterivEXT = (C.GPGETMULTITEXLEVELPARAMETERIVEXT)(getProcAddr(\"glGetMultiTexLevelParameterivEXT\"))\n\tgpGetMultiTexParameterIivEXT = (C.GPGETMULTITEXPARAMETERIIVEXT)(getProcAddr(\"glGetMultiTexParameterIivEXT\"))\n\tgpGetMultiTexParameterIuivEXT = (C.GPGETMULTITEXPARAMETERIUIVEXT)(getProcAddr(\"glGetMultiTexParameterIuivEXT\"))\n\tgpGetMultiTexParameterfvEXT = (C.GPGETMULTITEXPARAMETERFVEXT)(getProcAddr(\"glGetMultiTexParameterfvEXT\"))\n\tgpGetMultiTexParameterivEXT = (C.GPGETMULTITEXPARAMETERIVEXT)(getProcAddr(\"glGetMultiTexParameterivEXT\"))\n\tgpGetMultisamplefv = (C.GPGETMULTISAMPLEFV)(getProcAddr(\"glGetMultisamplefv\"))\n\tif gpGetMultisamplefv == nil {\n\t\treturn errors.New(\"glGetMultisamplefv\")\n\t}\n\tgpGetNamedBufferParameteri64v = (C.GPGETNAMEDBUFFERPARAMETERI64V)(getProcAddr(\"glGetNamedBufferParameteri64v\"))\n\tgpGetNamedBufferParameteriv = (C.GPGETNAMEDBUFFERPARAMETERIV)(getProcAddr(\"glGetNamedBufferParameteriv\"))\n\tgpGetNamedBufferParameterivEXT = (C.GPGETNAMEDBUFFERPARAMETERIVEXT)(getProcAddr(\"glGetNamedBufferParameterivEXT\"))\n\tgpGetNamedBufferParameterui64vNV = (C.GPGETNAMEDBUFFERPARAMETERUI64VNV)(getProcAddr(\"glGetNamedBufferParameterui64vNV\"))\n\tgpGetNamedBufferPointerv = (C.GPGETNAMEDBUFFERPOINTERV)(getProcAddr(\"glGetNamedBufferPointerv\"))\n\tgpGetNamedBufferPointervEXT = (C.GPGETNAMEDBUFFERPOINTERVEXT)(getProcAddr(\"glGetNamedBufferPointervEXT\"))\n\tgpGetNamedBufferSubData = (C.GPGETNAMEDBUFFERSUBDATA)(getProcAddr(\"glGetNamedBufferSubData\"))\n\tgpGetNamedBufferSubDataEXT = (C.GPGETNAMEDBUFFERSUBDATAEXT)(getProcAddr(\"glGetNamedBufferSubDataEXT\"))\n\tgpGetNamedFramebufferAttachmentParameteriv = (C.GPGETNAMEDFRAMEBUFFERATTACHMENTPARAMETERIV)(getProcAddr(\"glGetNamedFramebufferAttachmentParameteriv\"))\n\tgpGetNamedFramebufferAttachmentParameterivEXT = (C.GPGETNAMEDFRAMEBUFFERATTACHMENTPARAMETERIVEXT)(getProcAddr(\"glGetNamedFramebufferAttachmentParameterivEXT\"))\n\tgpGetNamedFramebufferParameteriv = (C.GPGETNAMEDFRAMEBUFFERPARAMETERIV)(getProcAddr(\"glGetNamedFramebufferParameteriv\"))\n\tgpGetNamedFramebufferParameterivEXT = (C.GPGETNAMEDFRAMEBUFFERPARAMETERIVEXT)(getProcAddr(\"glGetNamedFramebufferParameterivEXT\"))\n\tgpGetNamedProgramLocalParameterIivEXT = (C.GPGETNAMEDPROGRAMLOCALPARAMETERIIVEXT)(getProcAddr(\"glGetNamedProgramLocalParameterIivEXT\"))\n\tgpGetNamedProgramLocalParameterIuivEXT = (C.GPGETNAMEDPROGRAMLOCALPARAMETERIUIVEXT)(getProcAddr(\"glGetNamedProgramLocalParameterIuivEXT\"))\n\tgpGetNamedProgramLocalParameterdvEXT = (C.GPGETNAMEDPROGRAMLOCALPARAMETERDVEXT)(getProcAddr(\"glGetNamedProgramLocalParameterdvEXT\"))\n\tgpGetNamedProgramLocalParameterfvEXT = (C.GPGETNAMEDPROGRAMLOCALPARAMETERFVEXT)(getProcAddr(\"glGetNamedProgramLocalParameterfvEXT\"))\n\tgpGetNamedProgramStringEXT = (C.GPGETNAMEDPROGRAMSTRINGEXT)(getProcAddr(\"glGetNamedProgramStringEXT\"))\n\tgpGetNamedProgramivEXT = (C.GPGETNAMEDPROGRAMIVEXT)(getProcAddr(\"glGetNamedProgramivEXT\"))\n\tgpGetNamedRenderbufferParameteriv = (C.GPGETNAMEDRENDERBUFFERPARAMETERIV)(getProcAddr(\"glGetNamedRenderbufferParameteriv\"))\n\tgpGetNamedRenderbufferParameterivEXT = (C.GPGETNAMEDRENDERBUFFERPARAMETERIVEXT)(getProcAddr(\"glGetNamedRenderbufferParameterivEXT\"))\n\tgpGetNamedStringARB = (C.GPGETNAMEDSTRINGARB)(getProcAddr(\"glGetNamedStringARB\"))\n\tgpGetNamedStringivARB = (C.GPGETNAMEDSTRINGIVARB)(getProcAddr(\"glGetNamedStringivARB\"))\n\tgpGetNextPerfQueryIdINTEL = (C.GPGETNEXTPERFQUERYIDINTEL)(getProcAddr(\"glGetNextPerfQueryIdINTEL\"))\n\tgpGetObjectLabel = (C.GPGETOBJECTLABEL)(getProcAddr(\"glGetObjectLabel\"))\n\tgpGetObjectLabelEXT = (C.GPGETOBJECTLABELEXT)(getProcAddr(\"glGetObjectLabelEXT\"))\n\tgpGetObjectLabelKHR = (C.GPGETOBJECTLABELKHR)(getProcAddr(\"glGetObjectLabelKHR\"))\n\tgpGetObjectPtrLabel = (C.GPGETOBJECTPTRLABEL)(getProcAddr(\"glGetObjectPtrLabel\"))\n\tgpGetObjectPtrLabelKHR = (C.GPGETOBJECTPTRLABELKHR)(getProcAddr(\"glGetObjectPtrLabelKHR\"))\n\tgpGetPathCommandsNV = (C.GPGETPATHCOMMANDSNV)(getProcAddr(\"glGetPathCommandsNV\"))\n\tgpGetPathCoordsNV = (C.GPGETPATHCOORDSNV)(getProcAddr(\"glGetPathCoordsNV\"))\n\tgpGetPathDashArrayNV = (C.GPGETPATHDASHARRAYNV)(getProcAddr(\"glGetPathDashArrayNV\"))\n\tgpGetPathLengthNV = (C.GPGETPATHLENGTHNV)(getProcAddr(\"glGetPathLengthNV\"))\n\tgpGetPathMetricRangeNV = (C.GPGETPATHMETRICRANGENV)(getProcAddr(\"glGetPathMetricRangeNV\"))\n\tgpGetPathMetricsNV = (C.GPGETPATHMETRICSNV)(getProcAddr(\"glGetPathMetricsNV\"))\n\tgpGetPathParameterfvNV = (C.GPGETPATHPARAMETERFVNV)(getProcAddr(\"glGetPathParameterfvNV\"))\n\tgpGetPathParameterivNV = (C.GPGETPATHPARAMETERIVNV)(getProcAddr(\"glGetPathParameterivNV\"))\n\tgpGetPathSpacingNV = (C.GPGETPATHSPACINGNV)(getProcAddr(\"glGetPathSpacingNV\"))\n\tgpGetPerfCounterInfoINTEL = (C.GPGETPERFCOUNTERINFOINTEL)(getProcAddr(\"glGetPerfCounterInfoINTEL\"))\n\tgpGetPerfMonitorCounterDataAMD = (C.GPGETPERFMONITORCOUNTERDATAAMD)(getProcAddr(\"glGetPerfMonitorCounterDataAMD\"))\n\tgpGetPerfMonitorCounterInfoAMD = (C.GPGETPERFMONITORCOUNTERINFOAMD)(getProcAddr(\"glGetPerfMonitorCounterInfoAMD\"))\n\tgpGetPerfMonitorCounterStringAMD = (C.GPGETPERFMONITORCOUNTERSTRINGAMD)(getProcAddr(\"glGetPerfMonitorCounterStringAMD\"))\n\tgpGetPerfMonitorCountersAMD = (C.GPGETPERFMONITORCOUNTERSAMD)(getProcAddr(\"glGetPerfMonitorCountersAMD\"))\n\tgpGetPerfMonitorGroupStringAMD = (C.GPGETPERFMONITORGROUPSTRINGAMD)(getProcAddr(\"glGetPerfMonitorGroupStringAMD\"))\n\tgpGetPerfMonitorGroupsAMD = (C.GPGETPERFMONITORGROUPSAMD)(getProcAddr(\"glGetPerfMonitorGroupsAMD\"))\n\tgpGetPerfQueryDataINTEL = (C.GPGETPERFQUERYDATAINTEL)(getProcAddr(\"glGetPerfQueryDataINTEL\"))\n\tgpGetPerfQueryIdByNameINTEL = (C.GPGETPERFQUERYIDBYNAMEINTEL)(getProcAddr(\"glGetPerfQueryIdByNameINTEL\"))\n\tgpGetPerfQueryInfoINTEL = (C.GPGETPERFQUERYINFOINTEL)(getProcAddr(\"glGetPerfQueryInfoINTEL\"))\n\tgpGetPointerIndexedvEXT = (C.GPGETPOINTERINDEXEDVEXT)(getProcAddr(\"glGetPointerIndexedvEXT\"))\n\tgpGetPointeri_vEXT = (C.GPGETPOINTERI_VEXT)(getProcAddr(\"glGetPointeri_vEXT\"))\n\tgpGetPointerv = (C.GPGETPOINTERV)(getProcAddr(\"glGetPointerv\"))\n\tgpGetPointervKHR = (C.GPGETPOINTERVKHR)(getProcAddr(\"glGetPointervKHR\"))\n\tgpGetProgramBinary = (C.GPGETPROGRAMBINARY)(getProcAddr(\"glGetProgramBinary\"))\n\tif gpGetProgramBinary == nil {\n\t\treturn errors.New(\"glGetProgramBinary\")\n\t}\n\tgpGetProgramInfoLog = (C.GPGETPROGRAMINFOLOG)(getProcAddr(\"glGetProgramInfoLog\"))\n\tif gpGetProgramInfoLog == nil {\n\t\treturn errors.New(\"glGetProgramInfoLog\")\n\t}\n\tgpGetProgramInterfaceiv = (C.GPGETPROGRAMINTERFACEIV)(getProcAddr(\"glGetProgramInterfaceiv\"))\n\tgpGetProgramPipelineInfoLog = (C.GPGETPROGRAMPIPELINEINFOLOG)(getProcAddr(\"glGetProgramPipelineInfoLog\"))\n\tif gpGetProgramPipelineInfoLog == nil {\n\t\treturn errors.New(\"glGetProgramPipelineInfoLog\")\n\t}\n\tgpGetProgramPipelineInfoLogEXT = (C.GPGETPROGRAMPIPELINEINFOLOGEXT)(getProcAddr(\"glGetProgramPipelineInfoLogEXT\"))\n\tgpGetProgramPipelineiv = (C.GPGETPROGRAMPIPELINEIV)(getProcAddr(\"glGetProgramPipelineiv\"))\n\tif gpGetProgramPipelineiv == nil {\n\t\treturn errors.New(\"glGetProgramPipelineiv\")\n\t}\n\tgpGetProgramPipelineivEXT = (C.GPGETPROGRAMPIPELINEIVEXT)(getProcAddr(\"glGetProgramPipelineivEXT\"))\n\tgpGetProgramResourceIndex = (C.GPGETPROGRAMRESOURCEINDEX)(getProcAddr(\"glGetProgramResourceIndex\"))\n\tgpGetProgramResourceLocation = (C.GPGETPROGRAMRESOURCELOCATION)(getProcAddr(\"glGetProgramResourceLocation\"))\n\tgpGetProgramResourceLocationIndex = (C.GPGETPROGRAMRESOURCELOCATIONINDEX)(getProcAddr(\"glGetProgramResourceLocationIndex\"))\n\tgpGetProgramResourceName = (C.GPGETPROGRAMRESOURCENAME)(getProcAddr(\"glGetProgramResourceName\"))\n\tgpGetProgramResourcefvNV = (C.GPGETPROGRAMRESOURCEFVNV)(getProcAddr(\"glGetProgramResourcefvNV\"))\n\tgpGetProgramResourceiv = (C.GPGETPROGRAMRESOURCEIV)(getProcAddr(\"glGetProgramResourceiv\"))\n\tgpGetProgramStageiv = (C.GPGETPROGRAMSTAGEIV)(getProcAddr(\"glGetProgramStageiv\"))\n\tif gpGetProgramStageiv == nil {\n\t\treturn errors.New(\"glGetProgramStageiv\")\n\t}\n\tgpGetProgramiv = (C.GPGETPROGRAMIV)(getProcAddr(\"glGetProgramiv\"))\n\tif gpGetProgramiv == nil {\n\t\treturn errors.New(\"glGetProgramiv\")\n\t}\n\tgpGetQueryBufferObjecti64v = (C.GPGETQUERYBUFFEROBJECTI64V)(getProcAddr(\"glGetQueryBufferObjecti64v\"))\n\tgpGetQueryBufferObjectiv = (C.GPGETQUERYBUFFEROBJECTIV)(getProcAddr(\"glGetQueryBufferObjectiv\"))\n\tgpGetQueryBufferObjectui64v = (C.GPGETQUERYBUFFEROBJECTUI64V)(getProcAddr(\"glGetQueryBufferObjectui64v\"))\n\tgpGetQueryBufferObjectuiv = (C.GPGETQUERYBUFFEROBJECTUIV)(getProcAddr(\"glGetQueryBufferObjectuiv\"))\n\tgpGetQueryIndexediv = (C.GPGETQUERYINDEXEDIV)(getProcAddr(\"glGetQueryIndexediv\"))\n\tif gpGetQueryIndexediv == nil {\n\t\treturn errors.New(\"glGetQueryIndexediv\")\n\t}\n\tgpGetQueryObjecti64v = (C.GPGETQUERYOBJECTI64V)(getProcAddr(\"glGetQueryObjecti64v\"))\n\tif gpGetQueryObjecti64v == nil {\n\t\treturn errors.New(\"glGetQueryObjecti64v\")\n\t}\n\tgpGetQueryObjectiv = (C.GPGETQUERYOBJECTIV)(getProcAddr(\"glGetQueryObjectiv\"))\n\tif gpGetQueryObjectiv == nil {\n\t\treturn errors.New(\"glGetQueryObjectiv\")\n\t}\n\tgpGetQueryObjectui64v = (C.GPGETQUERYOBJECTUI64V)(getProcAddr(\"glGetQueryObjectui64v\"))\n\tif gpGetQueryObjectui64v == nil {\n\t\treturn errors.New(\"glGetQueryObjectui64v\")\n\t}\n\tgpGetQueryObjectuiv = (C.GPGETQUERYOBJECTUIV)(getProcAddr(\"glGetQueryObjectuiv\"))\n\tif gpGetQueryObjectuiv == nil {\n\t\treturn errors.New(\"glGetQueryObjectuiv\")\n\t}\n\tgpGetQueryiv = (C.GPGETQUERYIV)(getProcAddr(\"glGetQueryiv\"))\n\tif gpGetQueryiv == nil {\n\t\treturn errors.New(\"glGetQueryiv\")\n\t}\n\tgpGetRenderbufferParameteriv = (C.GPGETRENDERBUFFERPARAMETERIV)(getProcAddr(\"glGetRenderbufferParameteriv\"))\n\tif gpGetRenderbufferParameteriv == nil {\n\t\treturn errors.New(\"glGetRenderbufferParameteriv\")\n\t}\n\tgpGetSamplerParameterIiv = (C.GPGETSAMPLERPARAMETERIIV)(getProcAddr(\"glGetSamplerParameterIiv\"))\n\tif gpGetSamplerParameterIiv == nil {\n\t\treturn errors.New(\"glGetSamplerParameterIiv\")\n\t}\n\tgpGetSamplerParameterIuiv = (C.GPGETSAMPLERPARAMETERIUIV)(getProcAddr(\"glGetSamplerParameterIuiv\"))\n\tif gpGetSamplerParameterIuiv == nil {\n\t\treturn errors.New(\"glGetSamplerParameterIuiv\")\n\t}\n\tgpGetSamplerParameterfv = (C.GPGETSAMPLERPARAMETERFV)(getProcAddr(\"glGetSamplerParameterfv\"))\n\tif gpGetSamplerParameterfv == nil {\n\t\treturn errors.New(\"glGetSamplerParameterfv\")\n\t}\n\tgpGetSamplerParameteriv = (C.GPGETSAMPLERPARAMETERIV)(getProcAddr(\"glGetSamplerParameteriv\"))\n\tif gpGetSamplerParameteriv == nil {\n\t\treturn errors.New(\"glGetSamplerParameteriv\")\n\t}\n\tgpGetShaderInfoLog = (C.GPGETSHADERINFOLOG)(getProcAddr(\"glGetShaderInfoLog\"))\n\tif gpGetShaderInfoLog == nil {\n\t\treturn errors.New(\"glGetShaderInfoLog\")\n\t}\n\tgpGetShaderPrecisionFormat = (C.GPGETSHADERPRECISIONFORMAT)(getProcAddr(\"glGetShaderPrecisionFormat\"))\n\tif gpGetShaderPrecisionFormat == nil {\n\t\treturn errors.New(\"glGetShaderPrecisionFormat\")\n\t}\n\tgpGetShaderSource = (C.GPGETSHADERSOURCE)(getProcAddr(\"glGetShaderSource\"))\n\tif gpGetShaderSource == nil {\n\t\treturn errors.New(\"glGetShaderSource\")\n\t}\n\tgpGetShaderiv = (C.GPGETSHADERIV)(getProcAddr(\"glGetShaderiv\"))\n\tif gpGetShaderiv == nil {\n\t\treturn errors.New(\"glGetShaderiv\")\n\t}\n\tgpGetShadingRateImagePaletteNV = (C.GPGETSHADINGRATEIMAGEPALETTENV)(getProcAddr(\"glGetShadingRateImagePaletteNV\"))\n\tgpGetShadingRateSampleLocationivNV = (C.GPGETSHADINGRATESAMPLELOCATIONIVNV)(getProcAddr(\"glGetShadingRateSampleLocationivNV\"))\n\tgpGetStageIndexNV = (C.GPGETSTAGEINDEXNV)(getProcAddr(\"glGetStageIndexNV\"))\n\tgpGetString = (C.GPGETSTRING)(getProcAddr(\"glGetString\"))\n\tif gpGetString == nil {\n\t\treturn errors.New(\"glGetString\")\n\t}\n\tgpGetStringi = (C.GPGETSTRINGI)(getProcAddr(\"glGetStringi\"))\n\tif gpGetStringi == nil {\n\t\treturn errors.New(\"glGetStringi\")\n\t}\n\tgpGetSubroutineIndex = (C.GPGETSUBROUTINEINDEX)(getProcAddr(\"glGetSubroutineIndex\"))\n\tif gpGetSubroutineIndex == nil {\n\t\treturn errors.New(\"glGetSubroutineIndex\")\n\t}\n\tgpGetSubroutineUniformLocation = (C.GPGETSUBROUTINEUNIFORMLOCATION)(getProcAddr(\"glGetSubroutineUniformLocation\"))\n\tif gpGetSubroutineUniformLocation == nil {\n\t\treturn errors.New(\"glGetSubroutineUniformLocation\")\n\t}\n\tgpGetSynciv = (C.GPGETSYNCIV)(getProcAddr(\"glGetSynciv\"))\n\tif gpGetSynciv == nil {\n\t\treturn errors.New(\"glGetSynciv\")\n\t}\n\tgpGetTexImage = (C.GPGETTEXIMAGE)(getProcAddr(\"glGetTexImage\"))\n\tif gpGetTexImage == nil {\n\t\treturn errors.New(\"glGetTexImage\")\n\t}\n\tgpGetTexLevelParameterfv = (C.GPGETTEXLEVELPARAMETERFV)(getProcAddr(\"glGetTexLevelParameterfv\"))\n\tif gpGetTexLevelParameterfv == nil {\n\t\treturn errors.New(\"glGetTexLevelParameterfv\")\n\t}\n\tgpGetTexLevelParameteriv = (C.GPGETTEXLEVELPARAMETERIV)(getProcAddr(\"glGetTexLevelParameteriv\"))\n\tif gpGetTexLevelParameteriv == nil {\n\t\treturn errors.New(\"glGetTexLevelParameteriv\")\n\t}\n\tgpGetTexParameterIiv = (C.GPGETTEXPARAMETERIIV)(getProcAddr(\"glGetTexParameterIiv\"))\n\tif gpGetTexParameterIiv == nil {\n\t\treturn errors.New(\"glGetTexParameterIiv\")\n\t}\n\tgpGetTexParameterIuiv = (C.GPGETTEXPARAMETERIUIV)(getProcAddr(\"glGetTexParameterIuiv\"))\n\tif gpGetTexParameterIuiv == nil {\n\t\treturn errors.New(\"glGetTexParameterIuiv\")\n\t}\n\tgpGetTexParameterfv = (C.GPGETTEXPARAMETERFV)(getProcAddr(\"glGetTexParameterfv\"))\n\tif gpGetTexParameterfv == nil {\n\t\treturn errors.New(\"glGetTexParameterfv\")\n\t}\n\tgpGetTexParameteriv = (C.GPGETTEXPARAMETERIV)(getProcAddr(\"glGetTexParameteriv\"))\n\tif gpGetTexParameteriv == nil {\n\t\treturn errors.New(\"glGetTexParameteriv\")\n\t}\n\tgpGetTextureHandleARB = (C.GPGETTEXTUREHANDLEARB)(getProcAddr(\"glGetTextureHandleARB\"))\n\tgpGetTextureHandleNV = (C.GPGETTEXTUREHANDLENV)(getProcAddr(\"glGetTextureHandleNV\"))\n\tgpGetTextureImage = (C.GPGETTEXTUREIMAGE)(getProcAddr(\"glGetTextureImage\"))\n\tgpGetTextureImageEXT = (C.GPGETTEXTUREIMAGEEXT)(getProcAddr(\"glGetTextureImageEXT\"))\n\tgpGetTextureLevelParameterfv = (C.GPGETTEXTURELEVELPARAMETERFV)(getProcAddr(\"glGetTextureLevelParameterfv\"))\n\tgpGetTextureLevelParameterfvEXT = (C.GPGETTEXTURELEVELPARAMETERFVEXT)(getProcAddr(\"glGetTextureLevelParameterfvEXT\"))\n\tgpGetTextureLevelParameteriv = (C.GPGETTEXTURELEVELPARAMETERIV)(getProcAddr(\"glGetTextureLevelParameteriv\"))\n\tgpGetTextureLevelParameterivEXT = (C.GPGETTEXTURELEVELPARAMETERIVEXT)(getProcAddr(\"glGetTextureLevelParameterivEXT\"))\n\tgpGetTextureParameterIiv = (C.GPGETTEXTUREPARAMETERIIV)(getProcAddr(\"glGetTextureParameterIiv\"))\n\tgpGetTextureParameterIivEXT = (C.GPGETTEXTUREPARAMETERIIVEXT)(getProcAddr(\"glGetTextureParameterIivEXT\"))\n\tgpGetTextureParameterIuiv = (C.GPGETTEXTUREPARAMETERIUIV)(getProcAddr(\"glGetTextureParameterIuiv\"))\n\tgpGetTextureParameterIuivEXT = (C.GPGETTEXTUREPARAMETERIUIVEXT)(getProcAddr(\"glGetTextureParameterIuivEXT\"))\n\tgpGetTextureParameterfv = (C.GPGETTEXTUREPARAMETERFV)(getProcAddr(\"glGetTextureParameterfv\"))\n\tgpGetTextureParameterfvEXT = (C.GPGETTEXTUREPARAMETERFVEXT)(getProcAddr(\"glGetTextureParameterfvEXT\"))\n\tgpGetTextureParameteriv = (C.GPGETTEXTUREPARAMETERIV)(getProcAddr(\"glGetTextureParameteriv\"))\n\tgpGetTextureParameterivEXT = (C.GPGETTEXTUREPARAMETERIVEXT)(getProcAddr(\"glGetTextureParameterivEXT\"))\n\tgpGetTextureSamplerHandleARB = (C.GPGETTEXTURESAMPLERHANDLEARB)(getProcAddr(\"glGetTextureSamplerHandleARB\"))\n\tgpGetTextureSamplerHandleNV = (C.GPGETTEXTURESAMPLERHANDLENV)(getProcAddr(\"glGetTextureSamplerHandleNV\"))\n\tgpGetTextureSubImage = (C.GPGETTEXTURESUBIMAGE)(getProcAddr(\"glGetTextureSubImage\"))\n\tgpGetTransformFeedbackVarying = (C.GPGETTRANSFORMFEEDBACKVARYING)(getProcAddr(\"glGetTransformFeedbackVarying\"))\n\tif gpGetTransformFeedbackVarying == nil {\n\t\treturn errors.New(\"glGetTransformFeedbackVarying\")\n\t}\n\tgpGetTransformFeedbacki64_v = (C.GPGETTRANSFORMFEEDBACKI64_V)(getProcAddr(\"glGetTransformFeedbacki64_v\"))\n\tgpGetTransformFeedbacki_v = (C.GPGETTRANSFORMFEEDBACKI_V)(getProcAddr(\"glGetTransformFeedbacki_v\"))\n\tgpGetTransformFeedbackiv = (C.GPGETTRANSFORMFEEDBACKIV)(getProcAddr(\"glGetTransformFeedbackiv\"))\n\tgpGetUniformBlockIndex = (C.GPGETUNIFORMBLOCKINDEX)(getProcAddr(\"glGetUniformBlockIndex\"))\n\tif gpGetUniformBlockIndex == nil {\n\t\treturn errors.New(\"glGetUniformBlockIndex\")\n\t}\n\tgpGetUniformIndices = (C.GPGETUNIFORMINDICES)(getProcAddr(\"glGetUniformIndices\"))\n\tif gpGetUniformIndices == nil {\n\t\treturn errors.New(\"glGetUniformIndices\")\n\t}\n\tgpGetUniformLocation = (C.GPGETUNIFORMLOCATION)(getProcAddr(\"glGetUniformLocation\"))\n\tif gpGetUniformLocation == nil {\n\t\treturn errors.New(\"glGetUniformLocation\")\n\t}\n\tgpGetUniformSubroutineuiv = (C.GPGETUNIFORMSUBROUTINEUIV)(getProcAddr(\"glGetUniformSubroutineuiv\"))\n\tif gpGetUniformSubroutineuiv == nil {\n\t\treturn errors.New(\"glGetUniformSubroutineuiv\")\n\t}\n\tgpGetUniformdv = (C.GPGETUNIFORMDV)(getProcAddr(\"glGetUniformdv\"))\n\tif gpGetUniformdv == nil {\n\t\treturn errors.New(\"glGetUniformdv\")\n\t}\n\tgpGetUniformfv = (C.GPGETUNIFORMFV)(getProcAddr(\"glGetUniformfv\"))\n\tif gpGetUniformfv == nil {\n\t\treturn errors.New(\"glGetUniformfv\")\n\t}\n\tgpGetUniformi64vARB = (C.GPGETUNIFORMI64VARB)(getProcAddr(\"glGetUniformi64vARB\"))\n\tgpGetUniformi64vNV = (C.GPGETUNIFORMI64VNV)(getProcAddr(\"glGetUniformi64vNV\"))\n\tgpGetUniformiv = (C.GPGETUNIFORMIV)(getProcAddr(\"glGetUniformiv\"))\n\tif gpGetUniformiv == nil {\n\t\treturn errors.New(\"glGetUniformiv\")\n\t}\n\tgpGetUniformui64vARB = (C.GPGETUNIFORMUI64VARB)(getProcAddr(\"glGetUniformui64vARB\"))\n\tgpGetUniformui64vNV = (C.GPGETUNIFORMUI64VNV)(getProcAddr(\"glGetUniformui64vNV\"))\n\tgpGetUniformuiv = (C.GPGETUNIFORMUIV)(getProcAddr(\"glGetUniformuiv\"))\n\tif gpGetUniformuiv == nil {\n\t\treturn errors.New(\"glGetUniformuiv\")\n\t}\n\tgpGetVertexArrayIndexed64iv = (C.GPGETVERTEXARRAYINDEXED64IV)(getProcAddr(\"glGetVertexArrayIndexed64iv\"))\n\tgpGetVertexArrayIndexediv = (C.GPGETVERTEXARRAYINDEXEDIV)(getProcAddr(\"glGetVertexArrayIndexediv\"))\n\tgpGetVertexArrayIntegeri_vEXT = (C.GPGETVERTEXARRAYINTEGERI_VEXT)(getProcAddr(\"glGetVertexArrayIntegeri_vEXT\"))\n\tgpGetVertexArrayIntegervEXT = (C.GPGETVERTEXARRAYINTEGERVEXT)(getProcAddr(\"glGetVertexArrayIntegervEXT\"))\n\tgpGetVertexArrayPointeri_vEXT = (C.GPGETVERTEXARRAYPOINTERI_VEXT)(getProcAddr(\"glGetVertexArrayPointeri_vEXT\"))\n\tgpGetVertexArrayPointervEXT = (C.GPGETVERTEXARRAYPOINTERVEXT)(getProcAddr(\"glGetVertexArrayPointervEXT\"))\n\tgpGetVertexArrayiv = (C.GPGETVERTEXARRAYIV)(getProcAddr(\"glGetVertexArrayiv\"))\n\tgpGetVertexAttribIiv = (C.GPGETVERTEXATTRIBIIV)(getProcAddr(\"glGetVertexAttribIiv\"))\n\tif gpGetVertexAttribIiv == nil {\n\t\treturn errors.New(\"glGetVertexAttribIiv\")\n\t}\n\tgpGetVertexAttribIuiv = (C.GPGETVERTEXATTRIBIUIV)(getProcAddr(\"glGetVertexAttribIuiv\"))\n\tif gpGetVertexAttribIuiv == nil {\n\t\treturn errors.New(\"glGetVertexAttribIuiv\")\n\t}\n\tgpGetVertexAttribLdv = (C.GPGETVERTEXATTRIBLDV)(getProcAddr(\"glGetVertexAttribLdv\"))\n\tif gpGetVertexAttribLdv == nil {\n\t\treturn errors.New(\"glGetVertexAttribLdv\")\n\t}\n\tgpGetVertexAttribLi64vNV = (C.GPGETVERTEXATTRIBLI64VNV)(getProcAddr(\"glGetVertexAttribLi64vNV\"))\n\tgpGetVertexAttribLui64vARB = (C.GPGETVERTEXATTRIBLUI64VARB)(getProcAddr(\"glGetVertexAttribLui64vARB\"))\n\tgpGetVertexAttribLui64vNV = (C.GPGETVERTEXATTRIBLUI64VNV)(getProcAddr(\"glGetVertexAttribLui64vNV\"))\n\tgpGetVertexAttribPointerv = (C.GPGETVERTEXATTRIBPOINTERV)(getProcAddr(\"glGetVertexAttribPointerv\"))\n\tif gpGetVertexAttribPointerv == nil {\n\t\treturn errors.New(\"glGetVertexAttribPointerv\")\n\t}\n\tgpGetVertexAttribdv = (C.GPGETVERTEXATTRIBDV)(getProcAddr(\"glGetVertexAttribdv\"))\n\tif gpGetVertexAttribdv == nil {\n\t\treturn errors.New(\"glGetVertexAttribdv\")\n\t}\n\tgpGetVertexAttribfv = (C.GPGETVERTEXATTRIBFV)(getProcAddr(\"glGetVertexAttribfv\"))\n\tif gpGetVertexAttribfv == nil {\n\t\treturn errors.New(\"glGetVertexAttribfv\")\n\t}\n\tgpGetVertexAttribiv = (C.GPGETVERTEXATTRIBIV)(getProcAddr(\"glGetVertexAttribiv\"))\n\tif gpGetVertexAttribiv == nil {\n\t\treturn errors.New(\"glGetVertexAttribiv\")\n\t}\n\tgpGetVkProcAddrNV = (C.GPGETVKPROCADDRNV)(getProcAddr(\"glGetVkProcAddrNV\"))\n\tgpGetnCompressedTexImageARB = (C.GPGETNCOMPRESSEDTEXIMAGEARB)(getProcAddr(\"glGetnCompressedTexImageARB\"))\n\tgpGetnTexImageARB = (C.GPGETNTEXIMAGEARB)(getProcAddr(\"glGetnTexImageARB\"))\n\tgpGetnUniformdvARB = (C.GPGETNUNIFORMDVARB)(getProcAddr(\"glGetnUniformdvARB\"))\n\tgpGetnUniformfv = (C.GPGETNUNIFORMFV)(getProcAddr(\"glGetnUniformfv\"))\n\tgpGetnUniformfvARB = (C.GPGETNUNIFORMFVARB)(getProcAddr(\"glGetnUniformfvARB\"))\n\tgpGetnUniformfvKHR = (C.GPGETNUNIFORMFVKHR)(getProcAddr(\"glGetnUniformfvKHR\"))\n\tgpGetnUniformi64vARB = (C.GPGETNUNIFORMI64VARB)(getProcAddr(\"glGetnUniformi64vARB\"))\n\tgpGetnUniformiv = (C.GPGETNUNIFORMIV)(getProcAddr(\"glGetnUniformiv\"))\n\tgpGetnUniformivARB = (C.GPGETNUNIFORMIVARB)(getProcAddr(\"glGetnUniformivARB\"))\n\tgpGetnUniformivKHR = (C.GPGETNUNIFORMIVKHR)(getProcAddr(\"glGetnUniformivKHR\"))\n\tgpGetnUniformui64vARB = (C.GPGETNUNIFORMUI64VARB)(getProcAddr(\"glGetnUniformui64vARB\"))\n\tgpGetnUniformuiv = (C.GPGETNUNIFORMUIV)(getProcAddr(\"glGetnUniformuiv\"))\n\tgpGetnUniformuivARB = (C.GPGETNUNIFORMUIVARB)(getProcAddr(\"glGetnUniformuivARB\"))\n\tgpGetnUniformuivKHR = (C.GPGETNUNIFORMUIVKHR)(getProcAddr(\"glGetnUniformuivKHR\"))\n\tgpHint = (C.GPHINT)(getProcAddr(\"glHint\"))\n\tif gpHint == nil {\n\t\treturn errors.New(\"glHint\")\n\t}\n\tgpIndexFormatNV = (C.GPINDEXFORMATNV)(getProcAddr(\"glIndexFormatNV\"))\n\tgpInsertEventMarkerEXT = (C.GPINSERTEVENTMARKEREXT)(getProcAddr(\"glInsertEventMarkerEXT\"))\n\tgpInterpolatePathsNV = (C.GPINTERPOLATEPATHSNV)(getProcAddr(\"glInterpolatePathsNV\"))\n\tgpInvalidateBufferData = (C.GPINVALIDATEBUFFERDATA)(getProcAddr(\"glInvalidateBufferData\"))\n\tgpInvalidateBufferSubData = (C.GPINVALIDATEBUFFERSUBDATA)(getProcAddr(\"glInvalidateBufferSubData\"))\n\tgpInvalidateFramebuffer = (C.GPINVALIDATEFRAMEBUFFER)(getProcAddr(\"glInvalidateFramebuffer\"))\n\tgpInvalidateNamedFramebufferData = (C.GPINVALIDATENAMEDFRAMEBUFFERDATA)(getProcAddr(\"glInvalidateNamedFramebufferData\"))\n\tgpInvalidateNamedFramebufferSubData = (C.GPINVALIDATENAMEDFRAMEBUFFERSUBDATA)(getProcAddr(\"glInvalidateNamedFramebufferSubData\"))\n\tgpInvalidateSubFramebuffer = (C.GPINVALIDATESUBFRAMEBUFFER)(getProcAddr(\"glInvalidateSubFramebuffer\"))\n\tgpInvalidateTexImage = (C.GPINVALIDATETEXIMAGE)(getProcAddr(\"glInvalidateTexImage\"))\n\tgpInvalidateTexSubImage = (C.GPINVALIDATETEXSUBIMAGE)(getProcAddr(\"glInvalidateTexSubImage\"))\n\tgpIsBuffer = (C.GPISBUFFER)(getProcAddr(\"glIsBuffer\"))\n\tif gpIsBuffer == nil {\n\t\treturn errors.New(\"glIsBuffer\")\n\t}\n\tgpIsBufferResidentNV = (C.GPISBUFFERRESIDENTNV)(getProcAddr(\"glIsBufferResidentNV\"))\n\tgpIsCommandListNV = (C.GPISCOMMANDLISTNV)(getProcAddr(\"glIsCommandListNV\"))\n\tgpIsEnabled = (C.GPISENABLED)(getProcAddr(\"glIsEnabled\"))\n\tif gpIsEnabled == nil {\n\t\treturn errors.New(\"glIsEnabled\")\n\t}\n\tgpIsEnabledIndexedEXT = (C.GPISENABLEDINDEXEDEXT)(getProcAddr(\"glIsEnabledIndexedEXT\"))\n\tgpIsEnabledi = (C.GPISENABLEDI)(getProcAddr(\"glIsEnabledi\"))\n\tif gpIsEnabledi == nil {\n\t\treturn errors.New(\"glIsEnabledi\")\n\t}\n\tgpIsFramebuffer = (C.GPISFRAMEBUFFER)(getProcAddr(\"glIsFramebuffer\"))\n\tif gpIsFramebuffer == nil {\n\t\treturn errors.New(\"glIsFramebuffer\")\n\t}\n\tgpIsImageHandleResidentARB = (C.GPISIMAGEHANDLERESIDENTARB)(getProcAddr(\"glIsImageHandleResidentARB\"))\n\tgpIsImageHandleResidentNV = (C.GPISIMAGEHANDLERESIDENTNV)(getProcAddr(\"glIsImageHandleResidentNV\"))\n\tgpIsNamedBufferResidentNV = (C.GPISNAMEDBUFFERRESIDENTNV)(getProcAddr(\"glIsNamedBufferResidentNV\"))\n\tgpIsNamedStringARB = (C.GPISNAMEDSTRINGARB)(getProcAddr(\"glIsNamedStringARB\"))\n\tgpIsPathNV = (C.GPISPATHNV)(getProcAddr(\"glIsPathNV\"))\n\tgpIsPointInFillPathNV = (C.GPISPOINTINFILLPATHNV)(getProcAddr(\"glIsPointInFillPathNV\"))\n\tgpIsPointInStrokePathNV = (C.GPISPOINTINSTROKEPATHNV)(getProcAddr(\"glIsPointInStrokePathNV\"))\n\tgpIsProgram = (C.GPISPROGRAM)(getProcAddr(\"glIsProgram\"))\n\tif gpIsProgram == nil {\n\t\treturn errors.New(\"glIsProgram\")\n\t}\n\tgpIsProgramPipeline = (C.GPISPROGRAMPIPELINE)(getProcAddr(\"glIsProgramPipeline\"))\n\tif gpIsProgramPipeline == nil {\n\t\treturn errors.New(\"glIsProgramPipeline\")\n\t}\n\tgpIsProgramPipelineEXT = (C.GPISPROGRAMPIPELINEEXT)(getProcAddr(\"glIsProgramPipelineEXT\"))\n\tgpIsQuery = (C.GPISQUERY)(getProcAddr(\"glIsQuery\"))\n\tif gpIsQuery == nil {\n\t\treturn errors.New(\"glIsQuery\")\n\t}\n\tgpIsRenderbuffer = (C.GPISRENDERBUFFER)(getProcAddr(\"glIsRenderbuffer\"))\n\tif gpIsRenderbuffer == nil {\n\t\treturn errors.New(\"glIsRenderbuffer\")\n\t}\n\tgpIsSampler = (C.GPISSAMPLER)(getProcAddr(\"glIsSampler\"))\n\tif gpIsSampler == nil {\n\t\treturn errors.New(\"glIsSampler\")\n\t}\n\tgpIsShader = (C.GPISSHADER)(getProcAddr(\"glIsShader\"))\n\tif gpIsShader == nil {\n\t\treturn errors.New(\"glIsShader\")\n\t}\n\tgpIsStateNV = (C.GPISSTATENV)(getProcAddr(\"glIsStateNV\"))\n\tgpIsSync = (C.GPISSYNC)(getProcAddr(\"glIsSync\"))\n\tif gpIsSync == nil {\n\t\treturn errors.New(\"glIsSync\")\n\t}\n\tgpIsTexture = (C.GPISTEXTURE)(getProcAddr(\"glIsTexture\"))\n\tif gpIsTexture == nil {\n\t\treturn errors.New(\"glIsTexture\")\n\t}\n\tgpIsTextureHandleResidentARB = (C.GPISTEXTUREHANDLERESIDENTARB)(getProcAddr(\"glIsTextureHandleResidentARB\"))\n\tgpIsTextureHandleResidentNV = (C.GPISTEXTUREHANDLERESIDENTNV)(getProcAddr(\"glIsTextureHandleResidentNV\"))\n\tgpIsTransformFeedback = (C.GPISTRANSFORMFEEDBACK)(getProcAddr(\"glIsTransformFeedback\"))\n\tif gpIsTransformFeedback == nil {\n\t\treturn errors.New(\"glIsTransformFeedback\")\n\t}\n\tgpIsVertexArray = (C.GPISVERTEXARRAY)(getProcAddr(\"glIsVertexArray\"))\n\tif gpIsVertexArray == nil {\n\t\treturn errors.New(\"glIsVertexArray\")\n\t}\n\tgpLabelObjectEXT = (C.GPLABELOBJECTEXT)(getProcAddr(\"glLabelObjectEXT\"))\n\tgpLineWidth = (C.GPLINEWIDTH)(getProcAddr(\"glLineWidth\"))\n\tif gpLineWidth == nil {\n\t\treturn errors.New(\"glLineWidth\")\n\t}\n\tgpLinkProgram = (C.GPLINKPROGRAM)(getProcAddr(\"glLinkProgram\"))\n\tif gpLinkProgram == nil {\n\t\treturn errors.New(\"glLinkProgram\")\n\t}\n\tgpListDrawCommandsStatesClientNV = (C.GPLISTDRAWCOMMANDSSTATESCLIENTNV)(getProcAddr(\"glListDrawCommandsStatesClientNV\"))\n\tgpLogicOp = (C.GPLOGICOP)(getProcAddr(\"glLogicOp\"))\n\tif gpLogicOp == nil {\n\t\treturn errors.New(\"glLogicOp\")\n\t}\n\tgpMakeBufferNonResidentNV = (C.GPMAKEBUFFERNONRESIDENTNV)(getProcAddr(\"glMakeBufferNonResidentNV\"))\n\tgpMakeBufferResidentNV = (C.GPMAKEBUFFERRESIDENTNV)(getProcAddr(\"glMakeBufferResidentNV\"))\n\tgpMakeImageHandleNonResidentARB = (C.GPMAKEIMAGEHANDLENONRESIDENTARB)(getProcAddr(\"glMakeImageHandleNonResidentARB\"))\n\tgpMakeImageHandleNonResidentNV = (C.GPMAKEIMAGEHANDLENONRESIDENTNV)(getProcAddr(\"glMakeImageHandleNonResidentNV\"))\n\tgpMakeImageHandleResidentARB = (C.GPMAKEIMAGEHANDLERESIDENTARB)(getProcAddr(\"glMakeImageHandleResidentARB\"))\n\tgpMakeImageHandleResidentNV = (C.GPMAKEIMAGEHANDLERESIDENTNV)(getProcAddr(\"glMakeImageHandleResidentNV\"))\n\tgpMakeNamedBufferNonResidentNV = (C.GPMAKENAMEDBUFFERNONRESIDENTNV)(getProcAddr(\"glMakeNamedBufferNonResidentNV\"))\n\tgpMakeNamedBufferResidentNV = (C.GPMAKENAMEDBUFFERRESIDENTNV)(getProcAddr(\"glMakeNamedBufferResidentNV\"))\n\tgpMakeTextureHandleNonResidentARB = (C.GPMAKETEXTUREHANDLENONRESIDENTARB)(getProcAddr(\"glMakeTextureHandleNonResidentARB\"))\n\tgpMakeTextureHandleNonResidentNV = (C.GPMAKETEXTUREHANDLENONRESIDENTNV)(getProcAddr(\"glMakeTextureHandleNonResidentNV\"))\n\tgpMakeTextureHandleResidentARB = (C.GPMAKETEXTUREHANDLERESIDENTARB)(getProcAddr(\"glMakeTextureHandleResidentARB\"))\n\tgpMakeTextureHandleResidentNV = (C.GPMAKETEXTUREHANDLERESIDENTNV)(getProcAddr(\"glMakeTextureHandleResidentNV\"))\n\tgpMapBuffer = (C.GPMAPBUFFER)(getProcAddr(\"glMapBuffer\"))\n\tif gpMapBuffer == nil {\n\t\treturn errors.New(\"glMapBuffer\")\n\t}\n\tgpMapBufferRange = (C.GPMAPBUFFERRANGE)(getProcAddr(\"glMapBufferRange\"))\n\tif gpMapBufferRange == nil {\n\t\treturn errors.New(\"glMapBufferRange\")\n\t}\n\tgpMapNamedBuffer = (C.GPMAPNAMEDBUFFER)(getProcAddr(\"glMapNamedBuffer\"))\n\tgpMapNamedBufferEXT = (C.GPMAPNAMEDBUFFEREXT)(getProcAddr(\"glMapNamedBufferEXT\"))\n\tgpMapNamedBufferRange = (C.GPMAPNAMEDBUFFERRANGE)(getProcAddr(\"glMapNamedBufferRange\"))\n\tgpMapNamedBufferRangeEXT = (C.GPMAPNAMEDBUFFERRANGEEXT)(getProcAddr(\"glMapNamedBufferRangeEXT\"))\n\tgpMatrixFrustumEXT = (C.GPMATRIXFRUSTUMEXT)(getProcAddr(\"glMatrixFrustumEXT\"))\n\tgpMatrixLoad3x2fNV = (C.GPMATRIXLOAD3X2FNV)(getProcAddr(\"glMatrixLoad3x2fNV\"))\n\tgpMatrixLoad3x3fNV = (C.GPMATRIXLOAD3X3FNV)(getProcAddr(\"glMatrixLoad3x3fNV\"))\n\tgpMatrixLoadIdentityEXT = (C.GPMATRIXLOADIDENTITYEXT)(getProcAddr(\"glMatrixLoadIdentityEXT\"))\n\tgpMatrixLoadTranspose3x3fNV = (C.GPMATRIXLOADTRANSPOSE3X3FNV)(getProcAddr(\"glMatrixLoadTranspose3x3fNV\"))\n\tgpMatrixLoadTransposedEXT = (C.GPMATRIXLOADTRANSPOSEDEXT)(getProcAddr(\"glMatrixLoadTransposedEXT\"))\n\tgpMatrixLoadTransposefEXT = (C.GPMATRIXLOADTRANSPOSEFEXT)(getProcAddr(\"glMatrixLoadTransposefEXT\"))\n\tgpMatrixLoaddEXT = (C.GPMATRIXLOADDEXT)(getProcAddr(\"glMatrixLoaddEXT\"))\n\tgpMatrixLoadfEXT = (C.GPMATRIXLOADFEXT)(getProcAddr(\"glMatrixLoadfEXT\"))\n\tgpMatrixMult3x2fNV = (C.GPMATRIXMULT3X2FNV)(getProcAddr(\"glMatrixMult3x2fNV\"))\n\tgpMatrixMult3x3fNV = (C.GPMATRIXMULT3X3FNV)(getProcAddr(\"glMatrixMult3x3fNV\"))\n\tgpMatrixMultTranspose3x3fNV = (C.GPMATRIXMULTTRANSPOSE3X3FNV)(getProcAddr(\"glMatrixMultTranspose3x3fNV\"))\n\tgpMatrixMultTransposedEXT = (C.GPMATRIXMULTTRANSPOSEDEXT)(getProcAddr(\"glMatrixMultTransposedEXT\"))\n\tgpMatrixMultTransposefEXT = (C.GPMATRIXMULTTRANSPOSEFEXT)(getProcAddr(\"glMatrixMultTransposefEXT\"))\n\tgpMatrixMultdEXT = (C.GPMATRIXMULTDEXT)(getProcAddr(\"glMatrixMultdEXT\"))\n\tgpMatrixMultfEXT = (C.GPMATRIXMULTFEXT)(getProcAddr(\"glMatrixMultfEXT\"))\n\tgpMatrixOrthoEXT = (C.GPMATRIXORTHOEXT)(getProcAddr(\"glMatrixOrthoEXT\"))\n\tgpMatrixPopEXT = (C.GPMATRIXPOPEXT)(getProcAddr(\"glMatrixPopEXT\"))\n\tgpMatrixPushEXT = (C.GPMATRIXPUSHEXT)(getProcAddr(\"glMatrixPushEXT\"))\n\tgpMatrixRotatedEXT = (C.GPMATRIXROTATEDEXT)(getProcAddr(\"glMatrixRotatedEXT\"))\n\tgpMatrixRotatefEXT = (C.GPMATRIXROTATEFEXT)(getProcAddr(\"glMatrixRotatefEXT\"))\n\tgpMatrixScaledEXT = (C.GPMATRIXSCALEDEXT)(getProcAddr(\"glMatrixScaledEXT\"))\n\tgpMatrixScalefEXT = (C.GPMATRIXSCALEFEXT)(getProcAddr(\"glMatrixScalefEXT\"))\n\tgpMatrixTranslatedEXT = (C.GPMATRIXTRANSLATEDEXT)(getProcAddr(\"glMatrixTranslatedEXT\"))\n\tgpMatrixTranslatefEXT = (C.GPMATRIXTRANSLATEFEXT)(getProcAddr(\"glMatrixTranslatefEXT\"))\n\tgpMaxShaderCompilerThreadsARB = (C.GPMAXSHADERCOMPILERTHREADSARB)(getProcAddr(\"glMaxShaderCompilerThreadsARB\"))\n\tgpMaxShaderCompilerThreadsKHR = (C.GPMAXSHADERCOMPILERTHREADSKHR)(getProcAddr(\"glMaxShaderCompilerThreadsKHR\"))\n\tgpMemoryBarrier = (C.GPMEMORYBARRIER)(getProcAddr(\"glMemoryBarrier\"))\n\tif gpMemoryBarrier == nil {\n\t\treturn errors.New(\"glMemoryBarrier\")\n\t}\n\tgpMemoryBarrierByRegion = (C.GPMEMORYBARRIERBYREGION)(getProcAddr(\"glMemoryBarrierByRegion\"))\n\tgpMinSampleShading = (C.GPMINSAMPLESHADING)(getProcAddr(\"glMinSampleShading\"))\n\tif gpMinSampleShading == nil {\n\t\treturn errors.New(\"glMinSampleShading\")\n\t}\n\tgpMinSampleShadingARB = (C.GPMINSAMPLESHADINGARB)(getProcAddr(\"glMinSampleShadingARB\"))\n\tgpMultiDrawArrays = (C.GPMULTIDRAWARRAYS)(getProcAddr(\"glMultiDrawArrays\"))\n\tif gpMultiDrawArrays == nil {\n\t\treturn errors.New(\"glMultiDrawArrays\")\n\t}\n\tgpMultiDrawArraysIndirect = (C.GPMULTIDRAWARRAYSINDIRECT)(getProcAddr(\"glMultiDrawArraysIndirect\"))\n\tgpMultiDrawArraysIndirectBindlessCountNV = (C.GPMULTIDRAWARRAYSINDIRECTBINDLESSCOUNTNV)(getProcAddr(\"glMultiDrawArraysIndirectBindlessCountNV\"))\n\tgpMultiDrawArraysIndirectBindlessNV = (C.GPMULTIDRAWARRAYSINDIRECTBINDLESSNV)(getProcAddr(\"glMultiDrawArraysIndirectBindlessNV\"))\n\tgpMultiDrawArraysIndirectCountARB = (C.GPMULTIDRAWARRAYSINDIRECTCOUNTARB)(getProcAddr(\"glMultiDrawArraysIndirectCountARB\"))\n\tgpMultiDrawElements = (C.GPMULTIDRAWELEMENTS)(getProcAddr(\"glMultiDrawElements\"))\n\tif gpMultiDrawElements == nil {\n\t\treturn errors.New(\"glMultiDrawElements\")\n\t}\n\tgpMultiDrawElementsBaseVertex = (C.GPMULTIDRAWELEMENTSBASEVERTEX)(getProcAddr(\"glMultiDrawElementsBaseVertex\"))\n\tif gpMultiDrawElementsBaseVertex == nil {\n\t\treturn errors.New(\"glMultiDrawElementsBaseVertex\")\n\t}\n\tgpMultiDrawElementsIndirect = (C.GPMULTIDRAWELEMENTSINDIRECT)(getProcAddr(\"glMultiDrawElementsIndirect\"))\n\tgpMultiDrawElementsIndirectBindlessCountNV = (C.GPMULTIDRAWELEMENTSINDIRECTBINDLESSCOUNTNV)(getProcAddr(\"glMultiDrawElementsIndirectBindlessCountNV\"))\n\tgpMultiDrawElementsIndirectBindlessNV = (C.GPMULTIDRAWELEMENTSINDIRECTBINDLESSNV)(getProcAddr(\"glMultiDrawElementsIndirectBindlessNV\"))\n\tgpMultiDrawElementsIndirectCountARB = (C.GPMULTIDRAWELEMENTSINDIRECTCOUNTARB)(getProcAddr(\"glMultiDrawElementsIndirectCountARB\"))\n\tgpMultiDrawMeshTasksIndirectCountNV = (C.GPMULTIDRAWMESHTASKSINDIRECTCOUNTNV)(getProcAddr(\"glMultiDrawMeshTasksIndirectCountNV\"))\n\tgpMultiDrawMeshTasksIndirectNV = (C.GPMULTIDRAWMESHTASKSINDIRECTNV)(getProcAddr(\"glMultiDrawMeshTasksIndirectNV\"))\n\tgpMultiTexBufferEXT = (C.GPMULTITEXBUFFEREXT)(getProcAddr(\"glMultiTexBufferEXT\"))\n\tgpMultiTexCoordPointerEXT = (C.GPMULTITEXCOORDPOINTEREXT)(getProcAddr(\"glMultiTexCoordPointerEXT\"))\n\tgpMultiTexEnvfEXT = (C.GPMULTITEXENVFEXT)(getProcAddr(\"glMultiTexEnvfEXT\"))\n\tgpMultiTexEnvfvEXT = (C.GPMULTITEXENVFVEXT)(getProcAddr(\"glMultiTexEnvfvEXT\"))\n\tgpMultiTexEnviEXT = (C.GPMULTITEXENVIEXT)(getProcAddr(\"glMultiTexEnviEXT\"))\n\tgpMultiTexEnvivEXT = (C.GPMULTITEXENVIVEXT)(getProcAddr(\"glMultiTexEnvivEXT\"))\n\tgpMultiTexGendEXT = (C.GPMULTITEXGENDEXT)(getProcAddr(\"glMultiTexGendEXT\"))\n\tgpMultiTexGendvEXT = (C.GPMULTITEXGENDVEXT)(getProcAddr(\"glMultiTexGendvEXT\"))\n\tgpMultiTexGenfEXT = (C.GPMULTITEXGENFEXT)(getProcAddr(\"glMultiTexGenfEXT\"))\n\tgpMultiTexGenfvEXT = (C.GPMULTITEXGENFVEXT)(getProcAddr(\"glMultiTexGenfvEXT\"))\n\tgpMultiTexGeniEXT = (C.GPMULTITEXGENIEXT)(getProcAddr(\"glMultiTexGeniEXT\"))\n\tgpMultiTexGenivEXT = (C.GPMULTITEXGENIVEXT)(getProcAddr(\"glMultiTexGenivEXT\"))\n\tgpMultiTexImage1DEXT = (C.GPMULTITEXIMAGE1DEXT)(getProcAddr(\"glMultiTexImage1DEXT\"))\n\tgpMultiTexImage2DEXT = (C.GPMULTITEXIMAGE2DEXT)(getProcAddr(\"glMultiTexImage2DEXT\"))\n\tgpMultiTexImage3DEXT = (C.GPMULTITEXIMAGE3DEXT)(getProcAddr(\"glMultiTexImage3DEXT\"))\n\tgpMultiTexParameterIivEXT = (C.GPMULTITEXPARAMETERIIVEXT)(getProcAddr(\"glMultiTexParameterIivEXT\"))\n\tgpMultiTexParameterIuivEXT = (C.GPMULTITEXPARAMETERIUIVEXT)(getProcAddr(\"glMultiTexParameterIuivEXT\"))\n\tgpMultiTexParameterfEXT = (C.GPMULTITEXPARAMETERFEXT)(getProcAddr(\"glMultiTexParameterfEXT\"))\n\tgpMultiTexParameterfvEXT = (C.GPMULTITEXPARAMETERFVEXT)(getProcAddr(\"glMultiTexParameterfvEXT\"))\n\tgpMultiTexParameteriEXT = (C.GPMULTITEXPARAMETERIEXT)(getProcAddr(\"glMultiTexParameteriEXT\"))\n\tgpMultiTexParameterivEXT = (C.GPMULTITEXPARAMETERIVEXT)(getProcAddr(\"glMultiTexParameterivEXT\"))\n\tgpMultiTexRenderbufferEXT = (C.GPMULTITEXRENDERBUFFEREXT)(getProcAddr(\"glMultiTexRenderbufferEXT\"))\n\tgpMultiTexSubImage1DEXT = (C.GPMULTITEXSUBIMAGE1DEXT)(getProcAddr(\"glMultiTexSubImage1DEXT\"))\n\tgpMultiTexSubImage2DEXT = (C.GPMULTITEXSUBIMAGE2DEXT)(getProcAddr(\"glMultiTexSubImage2DEXT\"))\n\tgpMultiTexSubImage3DEXT = (C.GPMULTITEXSUBIMAGE3DEXT)(getProcAddr(\"glMultiTexSubImage3DEXT\"))\n\tgpNamedBufferAttachMemoryNV = (C.GPNAMEDBUFFERATTACHMEMORYNV)(getProcAddr(\"glNamedBufferAttachMemoryNV\"))\n\tgpNamedBufferData = (C.GPNAMEDBUFFERDATA)(getProcAddr(\"glNamedBufferData\"))\n\tgpNamedBufferDataEXT = (C.GPNAMEDBUFFERDATAEXT)(getProcAddr(\"glNamedBufferDataEXT\"))\n\tgpNamedBufferPageCommitmentARB = (C.GPNAMEDBUFFERPAGECOMMITMENTARB)(getProcAddr(\"glNamedBufferPageCommitmentARB\"))\n\tgpNamedBufferPageCommitmentEXT = (C.GPNAMEDBUFFERPAGECOMMITMENTEXT)(getProcAddr(\"glNamedBufferPageCommitmentEXT\"))\n\tgpNamedBufferPageCommitmentMemNV = (C.GPNAMEDBUFFERPAGECOMMITMENTMEMNV)(getProcAddr(\"glNamedBufferPageCommitmentMemNV\"))\n\tgpNamedBufferStorage = (C.GPNAMEDBUFFERSTORAGE)(getProcAddr(\"glNamedBufferStorage\"))\n\tgpNamedBufferStorageEXT = (C.GPNAMEDBUFFERSTORAGEEXT)(getProcAddr(\"glNamedBufferStorageEXT\"))\n\tgpNamedBufferSubData = (C.GPNAMEDBUFFERSUBDATA)(getProcAddr(\"glNamedBufferSubData\"))\n\tgpNamedBufferSubDataEXT = (C.GPNAMEDBUFFERSUBDATAEXT)(getProcAddr(\"glNamedBufferSubDataEXT\"))\n\tgpNamedCopyBufferSubDataEXT = (C.GPNAMEDCOPYBUFFERSUBDATAEXT)(getProcAddr(\"glNamedCopyBufferSubDataEXT\"))\n\tgpNamedFramebufferDrawBuffer = (C.GPNAMEDFRAMEBUFFERDRAWBUFFER)(getProcAddr(\"glNamedFramebufferDrawBuffer\"))\n\tgpNamedFramebufferDrawBuffers = (C.GPNAMEDFRAMEBUFFERDRAWBUFFERS)(getProcAddr(\"glNamedFramebufferDrawBuffers\"))\n\tgpNamedFramebufferParameteri = (C.GPNAMEDFRAMEBUFFERPARAMETERI)(getProcAddr(\"glNamedFramebufferParameteri\"))\n\tgpNamedFramebufferParameteriEXT = (C.GPNAMEDFRAMEBUFFERPARAMETERIEXT)(getProcAddr(\"glNamedFramebufferParameteriEXT\"))\n\tgpNamedFramebufferReadBuffer = (C.GPNAMEDFRAMEBUFFERREADBUFFER)(getProcAddr(\"glNamedFramebufferReadBuffer\"))\n\tgpNamedFramebufferRenderbuffer = (C.GPNAMEDFRAMEBUFFERRENDERBUFFER)(getProcAddr(\"glNamedFramebufferRenderbuffer\"))\n\tgpNamedFramebufferRenderbufferEXT = (C.GPNAMEDFRAMEBUFFERRENDERBUFFEREXT)(getProcAddr(\"glNamedFramebufferRenderbufferEXT\"))\n\tgpNamedFramebufferSampleLocationsfvARB = (C.GPNAMEDFRAMEBUFFERSAMPLELOCATIONSFVARB)(getProcAddr(\"glNamedFramebufferSampleLocationsfvARB\"))\n\tgpNamedFramebufferSampleLocationsfvNV = (C.GPNAMEDFRAMEBUFFERSAMPLELOCATIONSFVNV)(getProcAddr(\"glNamedFramebufferSampleLocationsfvNV\"))\n\tgpNamedFramebufferTexture = (C.GPNAMEDFRAMEBUFFERTEXTURE)(getProcAddr(\"glNamedFramebufferTexture\"))\n\tgpNamedFramebufferTexture1DEXT = (C.GPNAMEDFRAMEBUFFERTEXTURE1DEXT)(getProcAddr(\"glNamedFramebufferTexture1DEXT\"))\n\tgpNamedFramebufferTexture2DEXT = (C.GPNAMEDFRAMEBUFFERTEXTURE2DEXT)(getProcAddr(\"glNamedFramebufferTexture2DEXT\"))\n\tgpNamedFramebufferTexture3DEXT = (C.GPNAMEDFRAMEBUFFERTEXTURE3DEXT)(getProcAddr(\"glNamedFramebufferTexture3DEXT\"))\n\tgpNamedFramebufferTextureEXT = (C.GPNAMEDFRAMEBUFFERTEXTUREEXT)(getProcAddr(\"glNamedFramebufferTextureEXT\"))\n\tgpNamedFramebufferTextureFaceEXT = (C.GPNAMEDFRAMEBUFFERTEXTUREFACEEXT)(getProcAddr(\"glNamedFramebufferTextureFaceEXT\"))\n\tgpNamedFramebufferTextureLayer = (C.GPNAMEDFRAMEBUFFERTEXTURELAYER)(getProcAddr(\"glNamedFramebufferTextureLayer\"))\n\tgpNamedFramebufferTextureLayerEXT = (C.GPNAMEDFRAMEBUFFERTEXTURELAYEREXT)(getProcAddr(\"glNamedFramebufferTextureLayerEXT\"))\n\tgpNamedProgramLocalParameter4dEXT = (C.GPNAMEDPROGRAMLOCALPARAMETER4DEXT)(getProcAddr(\"glNamedProgramLocalParameter4dEXT\"))\n\tgpNamedProgramLocalParameter4dvEXT = (C.GPNAMEDPROGRAMLOCALPARAMETER4DVEXT)(getProcAddr(\"glNamedProgramLocalParameter4dvEXT\"))\n\tgpNamedProgramLocalParameter4fEXT = (C.GPNAMEDPROGRAMLOCALPARAMETER4FEXT)(getProcAddr(\"glNamedProgramLocalParameter4fEXT\"))\n\tgpNamedProgramLocalParameter4fvEXT = (C.GPNAMEDPROGRAMLOCALPARAMETER4FVEXT)(getProcAddr(\"glNamedProgramLocalParameter4fvEXT\"))\n\tgpNamedProgramLocalParameterI4iEXT = (C.GPNAMEDPROGRAMLOCALPARAMETERI4IEXT)(getProcAddr(\"glNamedProgramLocalParameterI4iEXT\"))\n\tgpNamedProgramLocalParameterI4ivEXT = (C.GPNAMEDPROGRAMLOCALPARAMETERI4IVEXT)(getProcAddr(\"glNamedProgramLocalParameterI4ivEXT\"))\n\tgpNamedProgramLocalParameterI4uiEXT = (C.GPNAMEDPROGRAMLOCALPARAMETERI4UIEXT)(getProcAddr(\"glNamedProgramLocalParameterI4uiEXT\"))\n\tgpNamedProgramLocalParameterI4uivEXT = (C.GPNAMEDPROGRAMLOCALPARAMETERI4UIVEXT)(getProcAddr(\"glNamedProgramLocalParameterI4uivEXT\"))\n\tgpNamedProgramLocalParameters4fvEXT = (C.GPNAMEDPROGRAMLOCALPARAMETERS4FVEXT)(getProcAddr(\"glNamedProgramLocalParameters4fvEXT\"))\n\tgpNamedProgramLocalParametersI4ivEXT = (C.GPNAMEDPROGRAMLOCALPARAMETERSI4IVEXT)(getProcAddr(\"glNamedProgramLocalParametersI4ivEXT\"))\n\tgpNamedProgramLocalParametersI4uivEXT = (C.GPNAMEDPROGRAMLOCALPARAMETERSI4UIVEXT)(getProcAddr(\"glNamedProgramLocalParametersI4uivEXT\"))\n\tgpNamedProgramStringEXT = (C.GPNAMEDPROGRAMSTRINGEXT)(getProcAddr(\"glNamedProgramStringEXT\"))\n\tgpNamedRenderbufferStorage = (C.GPNAMEDRENDERBUFFERSTORAGE)(getProcAddr(\"glNamedRenderbufferStorage\"))\n\tgpNamedRenderbufferStorageEXT = (C.GPNAMEDRENDERBUFFERSTORAGEEXT)(getProcAddr(\"glNamedRenderbufferStorageEXT\"))\n\tgpNamedRenderbufferStorageMultisample = (C.GPNAMEDRENDERBUFFERSTORAGEMULTISAMPLE)(getProcAddr(\"glNamedRenderbufferStorageMultisample\"))\n\tgpNamedRenderbufferStorageMultisampleAdvancedAMD = (C.GPNAMEDRENDERBUFFERSTORAGEMULTISAMPLEADVANCEDAMD)(getProcAddr(\"glNamedRenderbufferStorageMultisampleAdvancedAMD\"))\n\tgpNamedRenderbufferStorageMultisampleCoverageEXT = (C.GPNAMEDRENDERBUFFERSTORAGEMULTISAMPLECOVERAGEEXT)(getProcAddr(\"glNamedRenderbufferStorageMultisampleCoverageEXT\"))\n\tgpNamedRenderbufferStorageMultisampleEXT = (C.GPNAMEDRENDERBUFFERSTORAGEMULTISAMPLEEXT)(getProcAddr(\"glNamedRenderbufferStorageMultisampleEXT\"))\n\tgpNamedStringARB = (C.GPNAMEDSTRINGARB)(getProcAddr(\"glNamedStringARB\"))\n\tgpNormalFormatNV = (C.GPNORMALFORMATNV)(getProcAddr(\"glNormalFormatNV\"))\n\tgpObjectLabel = (C.GPOBJECTLABEL)(getProcAddr(\"glObjectLabel\"))\n\tgpObjectLabelKHR = (C.GPOBJECTLABELKHR)(getProcAddr(\"glObjectLabelKHR\"))\n\tgpObjectPtrLabel = (C.GPOBJECTPTRLABEL)(getProcAddr(\"glObjectPtrLabel\"))\n\tgpObjectPtrLabelKHR = (C.GPOBJECTPTRLABELKHR)(getProcAddr(\"glObjectPtrLabelKHR\"))\n\tgpPatchParameterfv = (C.GPPATCHPARAMETERFV)(getProcAddr(\"glPatchParameterfv\"))\n\tif gpPatchParameterfv == nil {\n\t\treturn errors.New(\"glPatchParameterfv\")\n\t}\n\tgpPatchParameteri = (C.GPPATCHPARAMETERI)(getProcAddr(\"glPatchParameteri\"))\n\tif gpPatchParameteri == nil {\n\t\treturn errors.New(\"glPatchParameteri\")\n\t}\n\tgpPathCommandsNV = (C.GPPATHCOMMANDSNV)(getProcAddr(\"glPathCommandsNV\"))\n\tgpPathCoordsNV = (C.GPPATHCOORDSNV)(getProcAddr(\"glPathCoordsNV\"))\n\tgpPathCoverDepthFuncNV = (C.GPPATHCOVERDEPTHFUNCNV)(getProcAddr(\"glPathCoverDepthFuncNV\"))\n\tgpPathDashArrayNV = (C.GPPATHDASHARRAYNV)(getProcAddr(\"glPathDashArrayNV\"))\n\tgpPathGlyphIndexArrayNV = (C.GPPATHGLYPHINDEXARRAYNV)(getProcAddr(\"glPathGlyphIndexArrayNV\"))\n\tgpPathGlyphIndexRangeNV = (C.GPPATHGLYPHINDEXRANGENV)(getProcAddr(\"glPathGlyphIndexRangeNV\"))\n\tgpPathGlyphRangeNV = (C.GPPATHGLYPHRANGENV)(getProcAddr(\"glPathGlyphRangeNV\"))\n\tgpPathGlyphsNV = (C.GPPATHGLYPHSNV)(getProcAddr(\"glPathGlyphsNV\"))\n\tgpPathMemoryGlyphIndexArrayNV = (C.GPPATHMEMORYGLYPHINDEXARRAYNV)(getProcAddr(\"glPathMemoryGlyphIndexArrayNV\"))\n\tgpPathParameterfNV = (C.GPPATHPARAMETERFNV)(getProcAddr(\"glPathParameterfNV\"))\n\tgpPathParameterfvNV = (C.GPPATHPARAMETERFVNV)(getProcAddr(\"glPathParameterfvNV\"))\n\tgpPathParameteriNV = (C.GPPATHPARAMETERINV)(getProcAddr(\"glPathParameteriNV\"))\n\tgpPathParameterivNV = (C.GPPATHPARAMETERIVNV)(getProcAddr(\"glPathParameterivNV\"))\n\tgpPathStencilDepthOffsetNV = (C.GPPATHSTENCILDEPTHOFFSETNV)(getProcAddr(\"glPathStencilDepthOffsetNV\"))\n\tgpPathStencilFuncNV = (C.GPPATHSTENCILFUNCNV)(getProcAddr(\"glPathStencilFuncNV\"))\n\tgpPathStringNV = (C.GPPATHSTRINGNV)(getProcAddr(\"glPathStringNV\"))\n\tgpPathSubCommandsNV = (C.GPPATHSUBCOMMANDSNV)(getProcAddr(\"glPathSubCommandsNV\"))\n\tgpPathSubCoordsNV = (C.GPPATHSUBCOORDSNV)(getProcAddr(\"glPathSubCoordsNV\"))\n\tgpPauseTransformFeedback = (C.GPPAUSETRANSFORMFEEDBACK)(getProcAddr(\"glPauseTransformFeedback\"))\n\tif gpPauseTransformFeedback == nil {\n\t\treturn errors.New(\"glPauseTransformFeedback\")\n\t}\n\tgpPixelStoref = (C.GPPIXELSTOREF)(getProcAddr(\"glPixelStoref\"))\n\tif gpPixelStoref == nil {\n\t\treturn errors.New(\"glPixelStoref\")\n\t}\n\tgpPixelStorei = (C.GPPIXELSTOREI)(getProcAddr(\"glPixelStorei\"))\n\tif gpPixelStorei == nil {\n\t\treturn errors.New(\"glPixelStorei\")\n\t}\n\tgpPointAlongPathNV = (C.GPPOINTALONGPATHNV)(getProcAddr(\"glPointAlongPathNV\"))\n\tgpPointParameterf = (C.GPPOINTPARAMETERF)(getProcAddr(\"glPointParameterf\"))\n\tif gpPointParameterf == nil {\n\t\treturn errors.New(\"glPointParameterf\")\n\t}\n\tgpPointParameterfv = (C.GPPOINTPARAMETERFV)(getProcAddr(\"glPointParameterfv\"))\n\tif gpPointParameterfv == nil {\n\t\treturn errors.New(\"glPointParameterfv\")\n\t}\n\tgpPointParameteri = (C.GPPOINTPARAMETERI)(getProcAddr(\"glPointParameteri\"))\n\tif gpPointParameteri == nil {\n\t\treturn errors.New(\"glPointParameteri\")\n\t}\n\tgpPointParameteriv = (C.GPPOINTPARAMETERIV)(getProcAddr(\"glPointParameteriv\"))\n\tif gpPointParameteriv == nil {\n\t\treturn errors.New(\"glPointParameteriv\")\n\t}\n\tgpPointSize = (C.GPPOINTSIZE)(getProcAddr(\"glPointSize\"))\n\tif gpPointSize == nil {\n\t\treturn errors.New(\"glPointSize\")\n\t}\n\tgpPolygonMode = (C.GPPOLYGONMODE)(getProcAddr(\"glPolygonMode\"))\n\tif gpPolygonMode == nil {\n\t\treturn errors.New(\"glPolygonMode\")\n\t}\n\tgpPolygonOffset = (C.GPPOLYGONOFFSET)(getProcAddr(\"glPolygonOffset\"))\n\tif gpPolygonOffset == nil {\n\t\treturn errors.New(\"glPolygonOffset\")\n\t}\n\tgpPolygonOffsetClamp = (C.GPPOLYGONOFFSETCLAMP)(getProcAddr(\"glPolygonOffsetClamp\"))\n\tgpPolygonOffsetClampEXT = (C.GPPOLYGONOFFSETCLAMPEXT)(getProcAddr(\"glPolygonOffsetClampEXT\"))\n\tgpPopDebugGroup = (C.GPPOPDEBUGGROUP)(getProcAddr(\"glPopDebugGroup\"))\n\tgpPopDebugGroupKHR = (C.GPPOPDEBUGGROUPKHR)(getProcAddr(\"glPopDebugGroupKHR\"))\n\tgpPopGroupMarkerEXT = (C.GPPOPGROUPMARKEREXT)(getProcAddr(\"glPopGroupMarkerEXT\"))\n\tgpPrimitiveBoundingBoxARB = (C.GPPRIMITIVEBOUNDINGBOXARB)(getProcAddr(\"glPrimitiveBoundingBoxARB\"))\n\tgpPrimitiveRestartIndex = (C.GPPRIMITIVERESTARTINDEX)(getProcAddr(\"glPrimitiveRestartIndex\"))\n\tif gpPrimitiveRestartIndex == nil {\n\t\treturn errors.New(\"glPrimitiveRestartIndex\")\n\t}\n\tgpProgramBinary = (C.GPPROGRAMBINARY)(getProcAddr(\"glProgramBinary\"))\n\tif gpProgramBinary == nil {\n\t\treturn errors.New(\"glProgramBinary\")\n\t}\n\tgpProgramParameteri = (C.GPPROGRAMPARAMETERI)(getProcAddr(\"glProgramParameteri\"))\n\tif gpProgramParameteri == nil {\n\t\treturn errors.New(\"glProgramParameteri\")\n\t}\n\tgpProgramParameteriARB = (C.GPPROGRAMPARAMETERIARB)(getProcAddr(\"glProgramParameteriARB\"))\n\tgpProgramParameteriEXT = (C.GPPROGRAMPARAMETERIEXT)(getProcAddr(\"glProgramParameteriEXT\"))\n\tgpProgramPathFragmentInputGenNV = (C.GPPROGRAMPATHFRAGMENTINPUTGENNV)(getProcAddr(\"glProgramPathFragmentInputGenNV\"))\n\tgpProgramUniform1d = (C.GPPROGRAMUNIFORM1D)(getProcAddr(\"glProgramUniform1d\"))\n\tif gpProgramUniform1d == nil {\n\t\treturn errors.New(\"glProgramUniform1d\")\n\t}\n\tgpProgramUniform1dEXT = (C.GPPROGRAMUNIFORM1DEXT)(getProcAddr(\"glProgramUniform1dEXT\"))\n\tgpProgramUniform1dv = (C.GPPROGRAMUNIFORM1DV)(getProcAddr(\"glProgramUniform1dv\"))\n\tif gpProgramUniform1dv == nil {\n\t\treturn errors.New(\"glProgramUniform1dv\")\n\t}\n\tgpProgramUniform1dvEXT = (C.GPPROGRAMUNIFORM1DVEXT)(getProcAddr(\"glProgramUniform1dvEXT\"))\n\tgpProgramUniform1f = (C.GPPROGRAMUNIFORM1F)(getProcAddr(\"glProgramUniform1f\"))\n\tif gpProgramUniform1f == nil {\n\t\treturn errors.New(\"glProgramUniform1f\")\n\t}\n\tgpProgramUniform1fEXT = (C.GPPROGRAMUNIFORM1FEXT)(getProcAddr(\"glProgramUniform1fEXT\"))\n\tgpProgramUniform1fv = (C.GPPROGRAMUNIFORM1FV)(getProcAddr(\"glProgramUniform1fv\"))\n\tif gpProgramUniform1fv == nil {\n\t\treturn errors.New(\"glProgramUniform1fv\")\n\t}\n\tgpProgramUniform1fvEXT = (C.GPPROGRAMUNIFORM1FVEXT)(getProcAddr(\"glProgramUniform1fvEXT\"))\n\tgpProgramUniform1i = (C.GPPROGRAMUNIFORM1I)(getProcAddr(\"glProgramUniform1i\"))\n\tif gpProgramUniform1i == nil {\n\t\treturn errors.New(\"glProgramUniform1i\")\n\t}\n\tgpProgramUniform1i64ARB = (C.GPPROGRAMUNIFORM1I64ARB)(getProcAddr(\"glProgramUniform1i64ARB\"))\n\tgpProgramUniform1i64NV = (C.GPPROGRAMUNIFORM1I64NV)(getProcAddr(\"glProgramUniform1i64NV\"))\n\tgpProgramUniform1i64vARB = (C.GPPROGRAMUNIFORM1I64VARB)(getProcAddr(\"glProgramUniform1i64vARB\"))\n\tgpProgramUniform1i64vNV = (C.GPPROGRAMUNIFORM1I64VNV)(getProcAddr(\"glProgramUniform1i64vNV\"))\n\tgpProgramUniform1iEXT = (C.GPPROGRAMUNIFORM1IEXT)(getProcAddr(\"glProgramUniform1iEXT\"))\n\tgpProgramUniform1iv = (C.GPPROGRAMUNIFORM1IV)(getProcAddr(\"glProgramUniform1iv\"))\n\tif gpProgramUniform1iv == nil {\n\t\treturn errors.New(\"glProgramUniform1iv\")\n\t}\n\tgpProgramUniform1ivEXT = (C.GPPROGRAMUNIFORM1IVEXT)(getProcAddr(\"glProgramUniform1ivEXT\"))\n\tgpProgramUniform1ui = (C.GPPROGRAMUNIFORM1UI)(getProcAddr(\"glProgramUniform1ui\"))\n\tif gpProgramUniform1ui == nil {\n\t\treturn errors.New(\"glProgramUniform1ui\")\n\t}\n\tgpProgramUniform1ui64ARB = (C.GPPROGRAMUNIFORM1UI64ARB)(getProcAddr(\"glProgramUniform1ui64ARB\"))\n\tgpProgramUniform1ui64NV = (C.GPPROGRAMUNIFORM1UI64NV)(getProcAddr(\"glProgramUniform1ui64NV\"))\n\tgpProgramUniform1ui64vARB = (C.GPPROGRAMUNIFORM1UI64VARB)(getProcAddr(\"glProgramUniform1ui64vARB\"))\n\tgpProgramUniform1ui64vNV = (C.GPPROGRAMUNIFORM1UI64VNV)(getProcAddr(\"glProgramUniform1ui64vNV\"))\n\tgpProgramUniform1uiEXT = (C.GPPROGRAMUNIFORM1UIEXT)(getProcAddr(\"glProgramUniform1uiEXT\"))\n\tgpProgramUniform1uiv = (C.GPPROGRAMUNIFORM1UIV)(getProcAddr(\"glProgramUniform1uiv\"))\n\tif gpProgramUniform1uiv == nil {\n\t\treturn errors.New(\"glProgramUniform1uiv\")\n\t}\n\tgpProgramUniform1uivEXT = (C.GPPROGRAMUNIFORM1UIVEXT)(getProcAddr(\"glProgramUniform1uivEXT\"))\n\tgpProgramUniform2d = (C.GPPROGRAMUNIFORM2D)(getProcAddr(\"glProgramUniform2d\"))\n\tif gpProgramUniform2d == nil {\n\t\treturn errors.New(\"glProgramUniform2d\")\n\t}\n\tgpProgramUniform2dEXT = (C.GPPROGRAMUNIFORM2DEXT)(getProcAddr(\"glProgramUniform2dEXT\"))\n\tgpProgramUniform2dv = (C.GPPROGRAMUNIFORM2DV)(getProcAddr(\"glProgramUniform2dv\"))\n\tif gpProgramUniform2dv == nil {\n\t\treturn errors.New(\"glProgramUniform2dv\")\n\t}\n\tgpProgramUniform2dvEXT = (C.GPPROGRAMUNIFORM2DVEXT)(getProcAddr(\"glProgramUniform2dvEXT\"))\n\tgpProgramUniform2f = (C.GPPROGRAMUNIFORM2F)(getProcAddr(\"glProgramUniform2f\"))\n\tif gpProgramUniform2f == nil {\n\t\treturn errors.New(\"glProgramUniform2f\")\n\t}\n\tgpProgramUniform2fEXT = (C.GPPROGRAMUNIFORM2FEXT)(getProcAddr(\"glProgramUniform2fEXT\"))\n\tgpProgramUniform2fv = (C.GPPROGRAMUNIFORM2FV)(getProcAddr(\"glProgramUniform2fv\"))\n\tif gpProgramUniform2fv == nil {\n\t\treturn errors.New(\"glProgramUniform2fv\")\n\t}\n\tgpProgramUniform2fvEXT = (C.GPPROGRAMUNIFORM2FVEXT)(getProcAddr(\"glProgramUniform2fvEXT\"))\n\tgpProgramUniform2i = (C.GPPROGRAMUNIFORM2I)(getProcAddr(\"glProgramUniform2i\"))\n\tif gpProgramUniform2i == nil {\n\t\treturn errors.New(\"glProgramUniform2i\")\n\t}\n\tgpProgramUniform2i64ARB = (C.GPPROGRAMUNIFORM2I64ARB)(getProcAddr(\"glProgramUniform2i64ARB\"))\n\tgpProgramUniform2i64NV = (C.GPPROGRAMUNIFORM2I64NV)(getProcAddr(\"glProgramUniform2i64NV\"))\n\tgpProgramUniform2i64vARB = (C.GPPROGRAMUNIFORM2I64VARB)(getProcAddr(\"glProgramUniform2i64vARB\"))\n\tgpProgramUniform2i64vNV = (C.GPPROGRAMUNIFORM2I64VNV)(getProcAddr(\"glProgramUniform2i64vNV\"))\n\tgpProgramUniform2iEXT = (C.GPPROGRAMUNIFORM2IEXT)(getProcAddr(\"glProgramUniform2iEXT\"))\n\tgpProgramUniform2iv = (C.GPPROGRAMUNIFORM2IV)(getProcAddr(\"glProgramUniform2iv\"))\n\tif gpProgramUniform2iv == nil {\n\t\treturn errors.New(\"glProgramUniform2iv\")\n\t}\n\tgpProgramUniform2ivEXT = (C.GPPROGRAMUNIFORM2IVEXT)(getProcAddr(\"glProgramUniform2ivEXT\"))\n\tgpProgramUniform2ui = (C.GPPROGRAMUNIFORM2UI)(getProcAddr(\"glProgramUniform2ui\"))\n\tif gpProgramUniform2ui == nil {\n\t\treturn errors.New(\"glProgramUniform2ui\")\n\t}\n\tgpProgramUniform2ui64ARB = (C.GPPROGRAMUNIFORM2UI64ARB)(getProcAddr(\"glProgramUniform2ui64ARB\"))\n\tgpProgramUniform2ui64NV = (C.GPPROGRAMUNIFORM2UI64NV)(getProcAddr(\"glProgramUniform2ui64NV\"))\n\tgpProgramUniform2ui64vARB = (C.GPPROGRAMUNIFORM2UI64VARB)(getProcAddr(\"glProgramUniform2ui64vARB\"))\n\tgpProgramUniform2ui64vNV = (C.GPPROGRAMUNIFORM2UI64VNV)(getProcAddr(\"glProgramUniform2ui64vNV\"))\n\tgpProgramUniform2uiEXT = (C.GPPROGRAMUNIFORM2UIEXT)(getProcAddr(\"glProgramUniform2uiEXT\"))\n\tgpProgramUniform2uiv = (C.GPPROGRAMUNIFORM2UIV)(getProcAddr(\"glProgramUniform2uiv\"))\n\tif gpProgramUniform2uiv == nil {\n\t\treturn errors.New(\"glProgramUniform2uiv\")\n\t}\n\tgpProgramUniform2uivEXT = (C.GPPROGRAMUNIFORM2UIVEXT)(getProcAddr(\"glProgramUniform2uivEXT\"))\n\tgpProgramUniform3d = (C.GPPROGRAMUNIFORM3D)(getProcAddr(\"glProgramUniform3d\"))\n\tif gpProgramUniform3d == nil {\n\t\treturn errors.New(\"glProgramUniform3d\")\n\t}\n\tgpProgramUniform3dEXT = (C.GPPROGRAMUNIFORM3DEXT)(getProcAddr(\"glProgramUniform3dEXT\"))\n\tgpProgramUniform3dv = (C.GPPROGRAMUNIFORM3DV)(getProcAddr(\"glProgramUniform3dv\"))\n\tif gpProgramUniform3dv == nil {\n\t\treturn errors.New(\"glProgramUniform3dv\")\n\t}\n\tgpProgramUniform3dvEXT = (C.GPPROGRAMUNIFORM3DVEXT)(getProcAddr(\"glProgramUniform3dvEXT\"))\n\tgpProgramUniform3f = (C.GPPROGRAMUNIFORM3F)(getProcAddr(\"glProgramUniform3f\"))\n\tif gpProgramUniform3f == nil {\n\t\treturn errors.New(\"glProgramUniform3f\")\n\t}\n\tgpProgramUniform3fEXT = (C.GPPROGRAMUNIFORM3FEXT)(getProcAddr(\"glProgramUniform3fEXT\"))\n\tgpProgramUniform3fv = (C.GPPROGRAMUNIFORM3FV)(getProcAddr(\"glProgramUniform3fv\"))\n\tif gpProgramUniform3fv == nil {\n\t\treturn errors.New(\"glProgramUniform3fv\")\n\t}\n\tgpProgramUniform3fvEXT = (C.GPPROGRAMUNIFORM3FVEXT)(getProcAddr(\"glProgramUniform3fvEXT\"))\n\tgpProgramUniform3i = (C.GPPROGRAMUNIFORM3I)(getProcAddr(\"glProgramUniform3i\"))\n\tif gpProgramUniform3i == nil {\n\t\treturn errors.New(\"glProgramUniform3i\")\n\t}\n\tgpProgramUniform3i64ARB = (C.GPPROGRAMUNIFORM3I64ARB)(getProcAddr(\"glProgramUniform3i64ARB\"))\n\tgpProgramUniform3i64NV = (C.GPPROGRAMUNIFORM3I64NV)(getProcAddr(\"glProgramUniform3i64NV\"))\n\tgpProgramUniform3i64vARB = (C.GPPROGRAMUNIFORM3I64VARB)(getProcAddr(\"glProgramUniform3i64vARB\"))\n\tgpProgramUniform3i64vNV = (C.GPPROGRAMUNIFORM3I64VNV)(getProcAddr(\"glProgramUniform3i64vNV\"))\n\tgpProgramUniform3iEXT = (C.GPPROGRAMUNIFORM3IEXT)(getProcAddr(\"glProgramUniform3iEXT\"))\n\tgpProgramUniform3iv = (C.GPPROGRAMUNIFORM3IV)(getProcAddr(\"glProgramUniform3iv\"))\n\tif gpProgramUniform3iv == nil {\n\t\treturn errors.New(\"glProgramUniform3iv\")\n\t}\n\tgpProgramUniform3ivEXT = (C.GPPROGRAMUNIFORM3IVEXT)(getProcAddr(\"glProgramUniform3ivEXT\"))\n\tgpProgramUniform3ui = (C.GPPROGRAMUNIFORM3UI)(getProcAddr(\"glProgramUniform3ui\"))\n\tif gpProgramUniform3ui == nil {\n\t\treturn errors.New(\"glProgramUniform3ui\")\n\t}\n\tgpProgramUniform3ui64ARB = (C.GPPROGRAMUNIFORM3UI64ARB)(getProcAddr(\"glProgramUniform3ui64ARB\"))\n\tgpProgramUniform3ui64NV = (C.GPPROGRAMUNIFORM3UI64NV)(getProcAddr(\"glProgramUniform3ui64NV\"))\n\tgpProgramUniform3ui64vARB = (C.GPPROGRAMUNIFORM3UI64VARB)(getProcAddr(\"glProgramUniform3ui64vARB\"))\n\tgpProgramUniform3ui64vNV = (C.GPPROGRAMUNIFORM3UI64VNV)(getProcAddr(\"glProgramUniform3ui64vNV\"))\n\tgpProgramUniform3uiEXT = (C.GPPROGRAMUNIFORM3UIEXT)(getProcAddr(\"glProgramUniform3uiEXT\"))\n\tgpProgramUniform3uiv = (C.GPPROGRAMUNIFORM3UIV)(getProcAddr(\"glProgramUniform3uiv\"))\n\tif gpProgramUniform3uiv == nil {\n\t\treturn errors.New(\"glProgramUniform3uiv\")\n\t}\n\tgpProgramUniform3uivEXT = (C.GPPROGRAMUNIFORM3UIVEXT)(getProcAddr(\"glProgramUniform3uivEXT\"))\n\tgpProgramUniform4d = (C.GPPROGRAMUNIFORM4D)(getProcAddr(\"glProgramUniform4d\"))\n\tif gpProgramUniform4d == nil {\n\t\treturn errors.New(\"glProgramUniform4d\")\n\t}\n\tgpProgramUniform4dEXT = (C.GPPROGRAMUNIFORM4DEXT)(getProcAddr(\"glProgramUniform4dEXT\"))\n\tgpProgramUniform4dv = (C.GPPROGRAMUNIFORM4DV)(getProcAddr(\"glProgramUniform4dv\"))\n\tif gpProgramUniform4dv == nil {\n\t\treturn errors.New(\"glProgramUniform4dv\")\n\t}\n\tgpProgramUniform4dvEXT = (C.GPPROGRAMUNIFORM4DVEXT)(getProcAddr(\"glProgramUniform4dvEXT\"))\n\tgpProgramUniform4f = (C.GPPROGRAMUNIFORM4F)(getProcAddr(\"glProgramUniform4f\"))\n\tif gpProgramUniform4f == nil {\n\t\treturn errors.New(\"glProgramUniform4f\")\n\t}\n\tgpProgramUniform4fEXT = (C.GPPROGRAMUNIFORM4FEXT)(getProcAddr(\"glProgramUniform4fEXT\"))\n\tgpProgramUniform4fv = (C.GPPROGRAMUNIFORM4FV)(getProcAddr(\"glProgramUniform4fv\"))\n\tif gpProgramUniform4fv == nil {\n\t\treturn errors.New(\"glProgramUniform4fv\")\n\t}\n\tgpProgramUniform4fvEXT = (C.GPPROGRAMUNIFORM4FVEXT)(getProcAddr(\"glProgramUniform4fvEXT\"))\n\tgpProgramUniform4i = (C.GPPROGRAMUNIFORM4I)(getProcAddr(\"glProgramUniform4i\"))\n\tif gpProgramUniform4i == nil {\n\t\treturn errors.New(\"glProgramUniform4i\")\n\t}\n\tgpProgramUniform4i64ARB = (C.GPPROGRAMUNIFORM4I64ARB)(getProcAddr(\"glProgramUniform4i64ARB\"))\n\tgpProgramUniform4i64NV = (C.GPPROGRAMUNIFORM4I64NV)(getProcAddr(\"glProgramUniform4i64NV\"))\n\tgpProgramUniform4i64vARB = (C.GPPROGRAMUNIFORM4I64VARB)(getProcAddr(\"glProgramUniform4i64vARB\"))\n\tgpProgramUniform4i64vNV = (C.GPPROGRAMUNIFORM4I64VNV)(getProcAddr(\"glProgramUniform4i64vNV\"))\n\tgpProgramUniform4iEXT = (C.GPPROGRAMUNIFORM4IEXT)(getProcAddr(\"glProgramUniform4iEXT\"))\n\tgpProgramUniform4iv = (C.GPPROGRAMUNIFORM4IV)(getProcAddr(\"glProgramUniform4iv\"))\n\tif gpProgramUniform4iv == nil {\n\t\treturn errors.New(\"glProgramUniform4iv\")\n\t}\n\tgpProgramUniform4ivEXT = (C.GPPROGRAMUNIFORM4IVEXT)(getProcAddr(\"glProgramUniform4ivEXT\"))\n\tgpProgramUniform4ui = (C.GPPROGRAMUNIFORM4UI)(getProcAddr(\"glProgramUniform4ui\"))\n\tif gpProgramUniform4ui == nil {\n\t\treturn errors.New(\"glProgramUniform4ui\")\n\t}\n\tgpProgramUniform4ui64ARB = (C.GPPROGRAMUNIFORM4UI64ARB)(getProcAddr(\"glProgramUniform4ui64ARB\"))\n\tgpProgramUniform4ui64NV = (C.GPPROGRAMUNIFORM4UI64NV)(getProcAddr(\"glProgramUniform4ui64NV\"))\n\tgpProgramUniform4ui64vARB = (C.GPPROGRAMUNIFORM4UI64VARB)(getProcAddr(\"glProgramUniform4ui64vARB\"))\n\tgpProgramUniform4ui64vNV = (C.GPPROGRAMUNIFORM4UI64VNV)(getProcAddr(\"glProgramUniform4ui64vNV\"))\n\tgpProgramUniform4uiEXT = (C.GPPROGRAMUNIFORM4UIEXT)(getProcAddr(\"glProgramUniform4uiEXT\"))\n\tgpProgramUniform4uiv = (C.GPPROGRAMUNIFORM4UIV)(getProcAddr(\"glProgramUniform4uiv\"))\n\tif gpProgramUniform4uiv == nil {\n\t\treturn errors.New(\"glProgramUniform4uiv\")\n\t}\n\tgpProgramUniform4uivEXT = (C.GPPROGRAMUNIFORM4UIVEXT)(getProcAddr(\"glProgramUniform4uivEXT\"))\n\tgpProgramUniformHandleui64ARB = (C.GPPROGRAMUNIFORMHANDLEUI64ARB)(getProcAddr(\"glProgramUniformHandleui64ARB\"))\n\tgpProgramUniformHandleui64NV = (C.GPPROGRAMUNIFORMHANDLEUI64NV)(getProcAddr(\"glProgramUniformHandleui64NV\"))\n\tgpProgramUniformHandleui64vARB = (C.GPPROGRAMUNIFORMHANDLEUI64VARB)(getProcAddr(\"glProgramUniformHandleui64vARB\"))\n\tgpProgramUniformHandleui64vNV = (C.GPPROGRAMUNIFORMHANDLEUI64VNV)(getProcAddr(\"glProgramUniformHandleui64vNV\"))\n\tgpProgramUniformMatrix2dv = (C.GPPROGRAMUNIFORMMATRIX2DV)(getProcAddr(\"glProgramUniformMatrix2dv\"))\n\tif gpProgramUniformMatrix2dv == nil {\n\t\treturn errors.New(\"glProgramUniformMatrix2dv\")\n\t}\n\tgpProgramUniformMatrix2dvEXT = (C.GPPROGRAMUNIFORMMATRIX2DVEXT)(getProcAddr(\"glProgramUniformMatrix2dvEXT\"))\n\tgpProgramUniformMatrix2fv = (C.GPPROGRAMUNIFORMMATRIX2FV)(getProcAddr(\"glProgramUniformMatrix2fv\"))\n\tif gpProgramUniformMatrix2fv == nil {\n\t\treturn errors.New(\"glProgramUniformMatrix2fv\")\n\t}\n\tgpProgramUniformMatrix2fvEXT = (C.GPPROGRAMUNIFORMMATRIX2FVEXT)(getProcAddr(\"glProgramUniformMatrix2fvEXT\"))\n\tgpProgramUniformMatrix2x3dv = (C.GPPROGRAMUNIFORMMATRIX2X3DV)(getProcAddr(\"glProgramUniformMatrix2x3dv\"))\n\tif gpProgramUniformMatrix2x3dv == nil {\n\t\treturn errors.New(\"glProgramUniformMatrix2x3dv\")\n\t}\n\tgpProgramUniformMatrix2x3dvEXT = (C.GPPROGRAMUNIFORMMATRIX2X3DVEXT)(getProcAddr(\"glProgramUniformMatrix2x3dvEXT\"))\n\tgpProgramUniformMatrix2x3fv = (C.GPPROGRAMUNIFORMMATRIX2X3FV)(getProcAddr(\"glProgramUniformMatrix2x3fv\"))\n\tif gpProgramUniformMatrix2x3fv == nil {\n\t\treturn errors.New(\"glProgramUniformMatrix2x3fv\")\n\t}\n\tgpProgramUniformMatrix2x3fvEXT = (C.GPPROGRAMUNIFORMMATRIX2X3FVEXT)(getProcAddr(\"glProgramUniformMatrix2x3fvEXT\"))\n\tgpProgramUniformMatrix2x4dv = (C.GPPROGRAMUNIFORMMATRIX2X4DV)(getProcAddr(\"glProgramUniformMatrix2x4dv\"))\n\tif gpProgramUniformMatrix2x4dv == nil {\n\t\treturn errors.New(\"glProgramUniformMatrix2x4dv\")\n\t}\n\tgpProgramUniformMatrix2x4dvEXT = (C.GPPROGRAMUNIFORMMATRIX2X4DVEXT)(getProcAddr(\"glProgramUniformMatrix2x4dvEXT\"))\n\tgpProgramUniformMatrix2x4fv = (C.GPPROGRAMUNIFORMMATRIX2X4FV)(getProcAddr(\"glProgramUniformMatrix2x4fv\"))\n\tif gpProgramUniformMatrix2x4fv == nil {\n\t\treturn errors.New(\"glProgramUniformMatrix2x4fv\")\n\t}\n\tgpProgramUniformMatrix2x4fvEXT = (C.GPPROGRAMUNIFORMMATRIX2X4FVEXT)(getProcAddr(\"glProgramUniformMatrix2x4fvEXT\"))\n\tgpProgramUniformMatrix3dv = (C.GPPROGRAMUNIFORMMATRIX3DV)(getProcAddr(\"glProgramUniformMatrix3dv\"))\n\tif gpProgramUniformMatrix3dv == nil {\n\t\treturn errors.New(\"glProgramUniformMatrix3dv\")\n\t}\n\tgpProgramUniformMatrix3dvEXT = (C.GPPROGRAMUNIFORMMATRIX3DVEXT)(getProcAddr(\"glProgramUniformMatrix3dvEXT\"))\n\tgpProgramUniformMatrix3fv = (C.GPPROGRAMUNIFORMMATRIX3FV)(getProcAddr(\"glProgramUniformMatrix3fv\"))\n\tif gpProgramUniformMatrix3fv == nil {\n\t\treturn errors.New(\"glProgramUniformMatrix3fv\")\n\t}\n\tgpProgramUniformMatrix3fvEXT = (C.GPPROGRAMUNIFORMMATRIX3FVEXT)(getProcAddr(\"glProgramUniformMatrix3fvEXT\"))\n\tgpProgramUniformMatrix3x2dv = (C.GPPROGRAMUNIFORMMATRIX3X2DV)(getProcAddr(\"glProgramUniformMatrix3x2dv\"))\n\tif gpProgramUniformMatrix3x2dv == nil {\n\t\treturn errors.New(\"glProgramUniformMatrix3x2dv\")\n\t}\n\tgpProgramUniformMatrix3x2dvEXT = (C.GPPROGRAMUNIFORMMATRIX3X2DVEXT)(getProcAddr(\"glProgramUniformMatrix3x2dvEXT\"))\n\tgpProgramUniformMatrix3x2fv = (C.GPPROGRAMUNIFORMMATRIX3X2FV)(getProcAddr(\"glProgramUniformMatrix3x2fv\"))\n\tif gpProgramUniformMatrix3x2fv == nil {\n\t\treturn errors.New(\"glProgramUniformMatrix3x2fv\")\n\t}\n\tgpProgramUniformMatrix3x2fvEXT = (C.GPPROGRAMUNIFORMMATRIX3X2FVEXT)(getProcAddr(\"glProgramUniformMatrix3x2fvEXT\"))\n\tgpProgramUniformMatrix3x4dv = (C.GPPROGRAMUNIFORMMATRIX3X4DV)(getProcAddr(\"glProgramUniformMatrix3x4dv\"))\n\tif gpProgramUniformMatrix3x4dv == nil {\n\t\treturn errors.New(\"glProgramUniformMatrix3x4dv\")\n\t}\n\tgpProgramUniformMatrix3x4dvEXT = (C.GPPROGRAMUNIFORMMATRIX3X4DVEXT)(getProcAddr(\"glProgramUniformMatrix3x4dvEXT\"))\n\tgpProgramUniformMatrix3x4fv = (C.GPPROGRAMUNIFORMMATRIX3X4FV)(getProcAddr(\"glProgramUniformMatrix3x4fv\"))\n\tif gpProgramUniformMatrix3x4fv == nil {\n\t\treturn errors.New(\"glProgramUniformMatrix3x4fv\")\n\t}\n\tgpProgramUniformMatrix3x4fvEXT = (C.GPPROGRAMUNIFORMMATRIX3X4FVEXT)(getProcAddr(\"glProgramUniformMatrix3x4fvEXT\"))\n\tgpProgramUniformMatrix4dv = (C.GPPROGRAMUNIFORMMATRIX4DV)(getProcAddr(\"glProgramUniformMatrix4dv\"))\n\tif gpProgramUniformMatrix4dv == nil {\n\t\treturn errors.New(\"glProgramUniformMatrix4dv\")\n\t}\n\tgpProgramUniformMatrix4dvEXT = (C.GPPROGRAMUNIFORMMATRIX4DVEXT)(getProcAddr(\"glProgramUniformMatrix4dvEXT\"))\n\tgpProgramUniformMatrix4fv = (C.GPPROGRAMUNIFORMMATRIX4FV)(getProcAddr(\"glProgramUniformMatrix4fv\"))\n\tif gpProgramUniformMatrix4fv == nil {\n\t\treturn errors.New(\"glProgramUniformMatrix4fv\")\n\t}\n\tgpProgramUniformMatrix4fvEXT = (C.GPPROGRAMUNIFORMMATRIX4FVEXT)(getProcAddr(\"glProgramUniformMatrix4fvEXT\"))\n\tgpProgramUniformMatrix4x2dv = (C.GPPROGRAMUNIFORMMATRIX4X2DV)(getProcAddr(\"glProgramUniformMatrix4x2dv\"))\n\tif gpProgramUniformMatrix4x2dv == nil {\n\t\treturn errors.New(\"glProgramUniformMatrix4x2dv\")\n\t}\n\tgpProgramUniformMatrix4x2dvEXT = (C.GPPROGRAMUNIFORMMATRIX4X2DVEXT)(getProcAddr(\"glProgramUniformMatrix4x2dvEXT\"))\n\tgpProgramUniformMatrix4x2fv = (C.GPPROGRAMUNIFORMMATRIX4X2FV)(getProcAddr(\"glProgramUniformMatrix4x2fv\"))\n\tif gpProgramUniformMatrix4x2fv == nil {\n\t\treturn errors.New(\"glProgramUniformMatrix4x2fv\")\n\t}\n\tgpProgramUniformMatrix4x2fvEXT = (C.GPPROGRAMUNIFORMMATRIX4X2FVEXT)(getProcAddr(\"glProgramUniformMatrix4x2fvEXT\"))\n\tgpProgramUniformMatrix4x3dv = (C.GPPROGRAMUNIFORMMATRIX4X3DV)(getProcAddr(\"glProgramUniformMatrix4x3dv\"))\n\tif gpProgramUniformMatrix4x3dv == nil {\n\t\treturn errors.New(\"glProgramUniformMatrix4x3dv\")\n\t}\n\tgpProgramUniformMatrix4x3dvEXT = (C.GPPROGRAMUNIFORMMATRIX4X3DVEXT)(getProcAddr(\"glProgramUniformMatrix4x3dvEXT\"))\n\tgpProgramUniformMatrix4x3fv = (C.GPPROGRAMUNIFORMMATRIX4X3FV)(getProcAddr(\"glProgramUniformMatrix4x3fv\"))\n\tif gpProgramUniformMatrix4x3fv == nil {\n\t\treturn errors.New(\"glProgramUniformMatrix4x3fv\")\n\t}\n\tgpProgramUniformMatrix4x3fvEXT = (C.GPPROGRAMUNIFORMMATRIX4X3FVEXT)(getProcAddr(\"glProgramUniformMatrix4x3fvEXT\"))\n\tgpProgramUniformui64NV = (C.GPPROGRAMUNIFORMUI64NV)(getProcAddr(\"glProgramUniformui64NV\"))\n\tgpProgramUniformui64vNV = (C.GPPROGRAMUNIFORMUI64VNV)(getProcAddr(\"glProgramUniformui64vNV\"))\n\tgpProvokingVertex = (C.GPPROVOKINGVERTEX)(getProcAddr(\"glProvokingVertex\"))\n\tif gpProvokingVertex == nil {\n\t\treturn errors.New(\"glProvokingVertex\")\n\t}\n\tgpPushClientAttribDefaultEXT = (C.GPPUSHCLIENTATTRIBDEFAULTEXT)(getProcAddr(\"glPushClientAttribDefaultEXT\"))\n\tgpPushDebugGroup = (C.GPPUSHDEBUGGROUP)(getProcAddr(\"glPushDebugGroup\"))\n\tgpPushDebugGroupKHR = (C.GPPUSHDEBUGGROUPKHR)(getProcAddr(\"glPushDebugGroupKHR\"))\n\tgpPushGroupMarkerEXT = (C.GPPUSHGROUPMARKEREXT)(getProcAddr(\"glPushGroupMarkerEXT\"))\n\tgpQueryCounter = (C.GPQUERYCOUNTER)(getProcAddr(\"glQueryCounter\"))\n\tif gpQueryCounter == nil {\n\t\treturn errors.New(\"glQueryCounter\")\n\t}\n\tgpRasterSamplesEXT = (C.GPRASTERSAMPLESEXT)(getProcAddr(\"glRasterSamplesEXT\"))\n\tgpReadBuffer = (C.GPREADBUFFER)(getProcAddr(\"glReadBuffer\"))\n\tif gpReadBuffer == nil {\n\t\treturn errors.New(\"glReadBuffer\")\n\t}\n\tgpReadPixels = (C.GPREADPIXELS)(getProcAddr(\"glReadPixels\"))\n\tif gpReadPixels == nil {\n\t\treturn errors.New(\"glReadPixels\")\n\t}\n\tgpReadnPixels = (C.GPREADNPIXELS)(getProcAddr(\"glReadnPixels\"))\n\tgpReadnPixelsARB = (C.GPREADNPIXELSARB)(getProcAddr(\"glReadnPixelsARB\"))\n\tgpReadnPixelsKHR = (C.GPREADNPIXELSKHR)(getProcAddr(\"glReadnPixelsKHR\"))\n\tgpReleaseShaderCompiler = (C.GPRELEASESHADERCOMPILER)(getProcAddr(\"glReleaseShaderCompiler\"))\n\tif gpReleaseShaderCompiler == nil {\n\t\treturn errors.New(\"glReleaseShaderCompiler\")\n\t}\n\tgpRenderbufferStorage = (C.GPRENDERBUFFERSTORAGE)(getProcAddr(\"glRenderbufferStorage\"))\n\tif gpRenderbufferStorage == nil {\n\t\treturn errors.New(\"glRenderbufferStorage\")\n\t}\n\tgpRenderbufferStorageMultisample = (C.GPRENDERBUFFERSTORAGEMULTISAMPLE)(getProcAddr(\"glRenderbufferStorageMultisample\"))\n\tif gpRenderbufferStorageMultisample == nil {\n\t\treturn errors.New(\"glRenderbufferStorageMultisample\")\n\t}\n\tgpRenderbufferStorageMultisampleAdvancedAMD = (C.GPRENDERBUFFERSTORAGEMULTISAMPLEADVANCEDAMD)(getProcAddr(\"glRenderbufferStorageMultisampleAdvancedAMD\"))\n\tgpRenderbufferStorageMultisampleCoverageNV = (C.GPRENDERBUFFERSTORAGEMULTISAMPLECOVERAGENV)(getProcAddr(\"glRenderbufferStorageMultisampleCoverageNV\"))\n\tgpResetMemoryObjectParameterNV = (C.GPRESETMEMORYOBJECTPARAMETERNV)(getProcAddr(\"glResetMemoryObjectParameterNV\"))\n\tgpResolveDepthValuesNV = (C.GPRESOLVEDEPTHVALUESNV)(getProcAddr(\"glResolveDepthValuesNV\"))\n\tgpResumeTransformFeedback = (C.GPRESUMETRANSFORMFEEDBACK)(getProcAddr(\"glResumeTransformFeedback\"))\n\tif gpResumeTransformFeedback == nil {\n\t\treturn errors.New(\"glResumeTransformFeedback\")\n\t}\n\tgpSampleCoverage = (C.GPSAMPLECOVERAGE)(getProcAddr(\"glSampleCoverage\"))\n\tif gpSampleCoverage == nil {\n\t\treturn errors.New(\"glSampleCoverage\")\n\t}\n\tgpSampleMaski = (C.GPSAMPLEMASKI)(getProcAddr(\"glSampleMaski\"))\n\tif gpSampleMaski == nil {\n\t\treturn errors.New(\"glSampleMaski\")\n\t}\n\tgpSamplerParameterIiv = (C.GPSAMPLERPARAMETERIIV)(getProcAddr(\"glSamplerParameterIiv\"))\n\tif gpSamplerParameterIiv == nil {\n\t\treturn errors.New(\"glSamplerParameterIiv\")\n\t}\n\tgpSamplerParameterIuiv = (C.GPSAMPLERPARAMETERIUIV)(getProcAddr(\"glSamplerParameterIuiv\"))\n\tif gpSamplerParameterIuiv == nil {\n\t\treturn errors.New(\"glSamplerParameterIuiv\")\n\t}\n\tgpSamplerParameterf = (C.GPSAMPLERPARAMETERF)(getProcAddr(\"glSamplerParameterf\"))\n\tif gpSamplerParameterf == nil {\n\t\treturn errors.New(\"glSamplerParameterf\")\n\t}\n\tgpSamplerParameterfv = (C.GPSAMPLERPARAMETERFV)(getProcAddr(\"glSamplerParameterfv\"))\n\tif gpSamplerParameterfv == nil {\n\t\treturn errors.New(\"glSamplerParameterfv\")\n\t}\n\tgpSamplerParameteri = (C.GPSAMPLERPARAMETERI)(getProcAddr(\"glSamplerParameteri\"))\n\tif gpSamplerParameteri == nil {\n\t\treturn errors.New(\"glSamplerParameteri\")\n\t}\n\tgpSamplerParameteriv = (C.GPSAMPLERPARAMETERIV)(getProcAddr(\"glSamplerParameteriv\"))\n\tif gpSamplerParameteriv == nil {\n\t\treturn errors.New(\"glSamplerParameteriv\")\n\t}\n\tgpScissor = (C.GPSCISSOR)(getProcAddr(\"glScissor\"))\n\tif gpScissor == nil {\n\t\treturn errors.New(\"glScissor\")\n\t}\n\tgpScissorArrayv = (C.GPSCISSORARRAYV)(getProcAddr(\"glScissorArrayv\"))\n\tif gpScissorArrayv == nil {\n\t\treturn errors.New(\"glScissorArrayv\")\n\t}\n\tgpScissorExclusiveArrayvNV = (C.GPSCISSOREXCLUSIVEARRAYVNV)(getProcAddr(\"glScissorExclusiveArrayvNV\"))\n\tgpScissorExclusiveNV = (C.GPSCISSOREXCLUSIVENV)(getProcAddr(\"glScissorExclusiveNV\"))\n\tgpScissorIndexed = (C.GPSCISSORINDEXED)(getProcAddr(\"glScissorIndexed\"))\n\tif gpScissorIndexed == nil {\n\t\treturn errors.New(\"glScissorIndexed\")\n\t}\n\tgpScissorIndexedv = (C.GPSCISSORINDEXEDV)(getProcAddr(\"glScissorIndexedv\"))\n\tif gpScissorIndexedv == nil {\n\t\treturn errors.New(\"glScissorIndexedv\")\n\t}\n\tgpSecondaryColorFormatNV = (C.GPSECONDARYCOLORFORMATNV)(getProcAddr(\"glSecondaryColorFormatNV\"))\n\tgpSelectPerfMonitorCountersAMD = (C.GPSELECTPERFMONITORCOUNTERSAMD)(getProcAddr(\"glSelectPerfMonitorCountersAMD\"))\n\tgpShaderBinary = (C.GPSHADERBINARY)(getProcAddr(\"glShaderBinary\"))\n\tif gpShaderBinary == nil {\n\t\treturn errors.New(\"glShaderBinary\")\n\t}\n\tgpShaderSource = (C.GPSHADERSOURCE)(getProcAddr(\"glShaderSource\"))\n\tif gpShaderSource == nil {\n\t\treturn errors.New(\"glShaderSource\")\n\t}\n\tgpShaderStorageBlockBinding = (C.GPSHADERSTORAGEBLOCKBINDING)(getProcAddr(\"glShaderStorageBlockBinding\"))\n\tgpShadingRateImageBarrierNV = (C.GPSHADINGRATEIMAGEBARRIERNV)(getProcAddr(\"glShadingRateImageBarrierNV\"))\n\tgpShadingRateImagePaletteNV = (C.GPSHADINGRATEIMAGEPALETTENV)(getProcAddr(\"glShadingRateImagePaletteNV\"))\n\tgpShadingRateSampleOrderCustomNV = (C.GPSHADINGRATESAMPLEORDERCUSTOMNV)(getProcAddr(\"glShadingRateSampleOrderCustomNV\"))\n\tgpShadingRateSampleOrderNV = (C.GPSHADINGRATESAMPLEORDERNV)(getProcAddr(\"glShadingRateSampleOrderNV\"))\n\tgpSignalVkFenceNV = (C.GPSIGNALVKFENCENV)(getProcAddr(\"glSignalVkFenceNV\"))\n\tgpSignalVkSemaphoreNV = (C.GPSIGNALVKSEMAPHORENV)(getProcAddr(\"glSignalVkSemaphoreNV\"))\n\tgpSpecializeShaderARB = (C.GPSPECIALIZESHADERARB)(getProcAddr(\"glSpecializeShaderARB\"))\n\tgpStateCaptureNV = (C.GPSTATECAPTURENV)(getProcAddr(\"glStateCaptureNV\"))\n\tgpStencilFillPathInstancedNV = (C.GPSTENCILFILLPATHINSTANCEDNV)(getProcAddr(\"glStencilFillPathInstancedNV\"))\n\tgpStencilFillPathNV = (C.GPSTENCILFILLPATHNV)(getProcAddr(\"glStencilFillPathNV\"))\n\tgpStencilFunc = (C.GPSTENCILFUNC)(getProcAddr(\"glStencilFunc\"))\n\tif gpStencilFunc == nil {\n\t\treturn errors.New(\"glStencilFunc\")\n\t}\n\tgpStencilFuncSeparate = (C.GPSTENCILFUNCSEPARATE)(getProcAddr(\"glStencilFuncSeparate\"))\n\tif gpStencilFuncSeparate == nil {\n\t\treturn errors.New(\"glStencilFuncSeparate\")\n\t}\n\tgpStencilMask = (C.GPSTENCILMASK)(getProcAddr(\"glStencilMask\"))\n\tif gpStencilMask == nil {\n\t\treturn errors.New(\"glStencilMask\")\n\t}\n\tgpStencilMaskSeparate = (C.GPSTENCILMASKSEPARATE)(getProcAddr(\"glStencilMaskSeparate\"))\n\tif gpStencilMaskSeparate == nil {\n\t\treturn errors.New(\"glStencilMaskSeparate\")\n\t}\n\tgpStencilOp = (C.GPSTENCILOP)(getProcAddr(\"glStencilOp\"))\n\tif gpStencilOp == nil {\n\t\treturn errors.New(\"glStencilOp\")\n\t}\n\tgpStencilOpSeparate = (C.GPSTENCILOPSEPARATE)(getProcAddr(\"glStencilOpSeparate\"))\n\tif gpStencilOpSeparate == nil {\n\t\treturn errors.New(\"glStencilOpSeparate\")\n\t}\n\tgpStencilStrokePathInstancedNV = (C.GPSTENCILSTROKEPATHINSTANCEDNV)(getProcAddr(\"glStencilStrokePathInstancedNV\"))\n\tgpStencilStrokePathNV = (C.GPSTENCILSTROKEPATHNV)(getProcAddr(\"glStencilStrokePathNV\"))\n\tgpStencilThenCoverFillPathInstancedNV = (C.GPSTENCILTHENCOVERFILLPATHINSTANCEDNV)(getProcAddr(\"glStencilThenCoverFillPathInstancedNV\"))\n\tgpStencilThenCoverFillPathNV = (C.GPSTENCILTHENCOVERFILLPATHNV)(getProcAddr(\"glStencilThenCoverFillPathNV\"))\n\tgpStencilThenCoverStrokePathInstancedNV = (C.GPSTENCILTHENCOVERSTROKEPATHINSTANCEDNV)(getProcAddr(\"glStencilThenCoverStrokePathInstancedNV\"))\n\tgpStencilThenCoverStrokePathNV = (C.GPSTENCILTHENCOVERSTROKEPATHNV)(getProcAddr(\"glStencilThenCoverStrokePathNV\"))\n\tgpSubpixelPrecisionBiasNV = (C.GPSUBPIXELPRECISIONBIASNV)(getProcAddr(\"glSubpixelPrecisionBiasNV\"))\n\tgpTexAttachMemoryNV = (C.GPTEXATTACHMEMORYNV)(getProcAddr(\"glTexAttachMemoryNV\"))\n\tgpTexBuffer = (C.GPTEXBUFFER)(getProcAddr(\"glTexBuffer\"))\n\tif gpTexBuffer == nil {\n\t\treturn errors.New(\"glTexBuffer\")\n\t}\n\tgpTexBufferARB = (C.GPTEXBUFFERARB)(getProcAddr(\"glTexBufferARB\"))\n\tgpTexBufferRange = (C.GPTEXBUFFERRANGE)(getProcAddr(\"glTexBufferRange\"))\n\tgpTexCoordFormatNV = (C.GPTEXCOORDFORMATNV)(getProcAddr(\"glTexCoordFormatNV\"))\n\tgpTexImage1D = (C.GPTEXIMAGE1D)(getProcAddr(\"glTexImage1D\"))\n\tif gpTexImage1D == nil {\n\t\treturn errors.New(\"glTexImage1D\")\n\t}\n\tgpTexImage2D = (C.GPTEXIMAGE2D)(getProcAddr(\"glTexImage2D\"))\n\tif gpTexImage2D == nil {\n\t\treturn errors.New(\"glTexImage2D\")\n\t}\n\tgpTexImage2DMultisample = (C.GPTEXIMAGE2DMULTISAMPLE)(getProcAddr(\"glTexImage2DMultisample\"))\n\tif gpTexImage2DMultisample == nil {\n\t\treturn errors.New(\"glTexImage2DMultisample\")\n\t}\n\tgpTexImage3D = (C.GPTEXIMAGE3D)(getProcAddr(\"glTexImage3D\"))\n\tif gpTexImage3D == nil {\n\t\treturn errors.New(\"glTexImage3D\")\n\t}\n\tgpTexImage3DMultisample = (C.GPTEXIMAGE3DMULTISAMPLE)(getProcAddr(\"glTexImage3DMultisample\"))\n\tif gpTexImage3DMultisample == nil {\n\t\treturn errors.New(\"glTexImage3DMultisample\")\n\t}\n\tgpTexPageCommitmentARB = (C.GPTEXPAGECOMMITMENTARB)(getProcAddr(\"glTexPageCommitmentARB\"))\n\tgpTexPageCommitmentMemNV = (C.GPTEXPAGECOMMITMENTMEMNV)(getProcAddr(\"glTexPageCommitmentMemNV\"))\n\tgpTexParameterIiv = (C.GPTEXPARAMETERIIV)(getProcAddr(\"glTexParameterIiv\"))\n\tif gpTexParameterIiv == nil {\n\t\treturn errors.New(\"glTexParameterIiv\")\n\t}\n\tgpTexParameterIuiv = (C.GPTEXPARAMETERIUIV)(getProcAddr(\"glTexParameterIuiv\"))\n\tif gpTexParameterIuiv == nil {\n\t\treturn errors.New(\"glTexParameterIuiv\")\n\t}\n\tgpTexParameterf = (C.GPTEXPARAMETERF)(getProcAddr(\"glTexParameterf\"))\n\tif gpTexParameterf == nil {\n\t\treturn errors.New(\"glTexParameterf\")\n\t}\n\tgpTexParameterfv = (C.GPTEXPARAMETERFV)(getProcAddr(\"glTexParameterfv\"))\n\tif gpTexParameterfv == nil {\n\t\treturn errors.New(\"glTexParameterfv\")\n\t}\n\tgpTexParameteri = (C.GPTEXPARAMETERI)(getProcAddr(\"glTexParameteri\"))\n\tif gpTexParameteri == nil {\n\t\treturn errors.New(\"glTexParameteri\")\n\t}\n\tgpTexParameteriv = (C.GPTEXPARAMETERIV)(getProcAddr(\"glTexParameteriv\"))\n\tif gpTexParameteriv == nil {\n\t\treturn errors.New(\"glTexParameteriv\")\n\t}\n\tgpTexStorage1D = (C.GPTEXSTORAGE1D)(getProcAddr(\"glTexStorage1D\"))\n\tif gpTexStorage1D == nil {\n\t\treturn errors.New(\"glTexStorage1D\")\n\t}\n\tgpTexStorage2D = (C.GPTEXSTORAGE2D)(getProcAddr(\"glTexStorage2D\"))\n\tif gpTexStorage2D == nil {\n\t\treturn errors.New(\"glTexStorage2D\")\n\t}\n\tgpTexStorage2DMultisample = (C.GPTEXSTORAGE2DMULTISAMPLE)(getProcAddr(\"glTexStorage2DMultisample\"))\n\tgpTexStorage3D = (C.GPTEXSTORAGE3D)(getProcAddr(\"glTexStorage3D\"))\n\tif gpTexStorage3D == nil {\n\t\treturn errors.New(\"glTexStorage3D\")\n\t}\n\tgpTexStorage3DMultisample = (C.GPTEXSTORAGE3DMULTISAMPLE)(getProcAddr(\"glTexStorage3DMultisample\"))\n\tgpTexSubImage1D = (C.GPTEXSUBIMAGE1D)(getProcAddr(\"glTexSubImage1D\"))\n\tif gpTexSubImage1D == nil {\n\t\treturn errors.New(\"glTexSubImage1D\")\n\t}\n\tgpTexSubImage2D = (C.GPTEXSUBIMAGE2D)(getProcAddr(\"glTexSubImage2D\"))\n\tif gpTexSubImage2D == nil {\n\t\treturn errors.New(\"glTexSubImage2D\")\n\t}\n\tgpTexSubImage3D = (C.GPTEXSUBIMAGE3D)(getProcAddr(\"glTexSubImage3D\"))\n\tif gpTexSubImage3D == nil {\n\t\treturn errors.New(\"glTexSubImage3D\")\n\t}\n\tgpTextureAttachMemoryNV = (C.GPTEXTUREATTACHMEMORYNV)(getProcAddr(\"glTextureAttachMemoryNV\"))\n\tgpTextureBarrier = (C.GPTEXTUREBARRIER)(getProcAddr(\"glTextureBarrier\"))\n\tgpTextureBarrierNV = (C.GPTEXTUREBARRIERNV)(getProcAddr(\"glTextureBarrierNV\"))\n\tgpTextureBuffer = (C.GPTEXTUREBUFFER)(getProcAddr(\"glTextureBuffer\"))\n\tgpTextureBufferEXT = (C.GPTEXTUREBUFFEREXT)(getProcAddr(\"glTextureBufferEXT\"))\n\tgpTextureBufferRange = (C.GPTEXTUREBUFFERRANGE)(getProcAddr(\"glTextureBufferRange\"))\n\tgpTextureBufferRangeEXT = (C.GPTEXTUREBUFFERRANGEEXT)(getProcAddr(\"glTextureBufferRangeEXT\"))\n\tgpTextureImage1DEXT = (C.GPTEXTUREIMAGE1DEXT)(getProcAddr(\"glTextureImage1DEXT\"))\n\tgpTextureImage2DEXT = (C.GPTEXTUREIMAGE2DEXT)(getProcAddr(\"glTextureImage2DEXT\"))\n\tgpTextureImage3DEXT = (C.GPTEXTUREIMAGE3DEXT)(getProcAddr(\"glTextureImage3DEXT\"))\n\tgpTexturePageCommitmentEXT = (C.GPTEXTUREPAGECOMMITMENTEXT)(getProcAddr(\"glTexturePageCommitmentEXT\"))\n\tgpTexturePageCommitmentMemNV = (C.GPTEXTUREPAGECOMMITMENTMEMNV)(getProcAddr(\"glTexturePageCommitmentMemNV\"))\n\tgpTextureParameterIiv = (C.GPTEXTUREPARAMETERIIV)(getProcAddr(\"glTextureParameterIiv\"))\n\tgpTextureParameterIivEXT = (C.GPTEXTUREPARAMETERIIVEXT)(getProcAddr(\"glTextureParameterIivEXT\"))\n\tgpTextureParameterIuiv = (C.GPTEXTUREPARAMETERIUIV)(getProcAddr(\"glTextureParameterIuiv\"))\n\tgpTextureParameterIuivEXT = (C.GPTEXTUREPARAMETERIUIVEXT)(getProcAddr(\"glTextureParameterIuivEXT\"))\n\tgpTextureParameterf = (C.GPTEXTUREPARAMETERF)(getProcAddr(\"glTextureParameterf\"))\n\tgpTextureParameterfEXT = (C.GPTEXTUREPARAMETERFEXT)(getProcAddr(\"glTextureParameterfEXT\"))\n\tgpTextureParameterfv = (C.GPTEXTUREPARAMETERFV)(getProcAddr(\"glTextureParameterfv\"))\n\tgpTextureParameterfvEXT = (C.GPTEXTUREPARAMETERFVEXT)(getProcAddr(\"glTextureParameterfvEXT\"))\n\tgpTextureParameteri = (C.GPTEXTUREPARAMETERI)(getProcAddr(\"glTextureParameteri\"))\n\tgpTextureParameteriEXT = (C.GPTEXTUREPARAMETERIEXT)(getProcAddr(\"glTextureParameteriEXT\"))\n\tgpTextureParameteriv = (C.GPTEXTUREPARAMETERIV)(getProcAddr(\"glTextureParameteriv\"))\n\tgpTextureParameterivEXT = (C.GPTEXTUREPARAMETERIVEXT)(getProcAddr(\"glTextureParameterivEXT\"))\n\tgpTextureRenderbufferEXT = (C.GPTEXTURERENDERBUFFEREXT)(getProcAddr(\"glTextureRenderbufferEXT\"))\n\tgpTextureStorage1D = (C.GPTEXTURESTORAGE1D)(getProcAddr(\"glTextureStorage1D\"))\n\tgpTextureStorage1DEXT = (C.GPTEXTURESTORAGE1DEXT)(getProcAddr(\"glTextureStorage1DEXT\"))\n\tgpTextureStorage2D = (C.GPTEXTURESTORAGE2D)(getProcAddr(\"glTextureStorage2D\"))\n\tgpTextureStorage2DEXT = (C.GPTEXTURESTORAGE2DEXT)(getProcAddr(\"glTextureStorage2DEXT\"))\n\tgpTextureStorage2DMultisample = (C.GPTEXTURESTORAGE2DMULTISAMPLE)(getProcAddr(\"glTextureStorage2DMultisample\"))\n\tgpTextureStorage2DMultisampleEXT = (C.GPTEXTURESTORAGE2DMULTISAMPLEEXT)(getProcAddr(\"glTextureStorage2DMultisampleEXT\"))\n\tgpTextureStorage3D = (C.GPTEXTURESTORAGE3D)(getProcAddr(\"glTextureStorage3D\"))\n\tgpTextureStorage3DEXT = (C.GPTEXTURESTORAGE3DEXT)(getProcAddr(\"glTextureStorage3DEXT\"))\n\tgpTextureStorage3DMultisample = (C.GPTEXTURESTORAGE3DMULTISAMPLE)(getProcAddr(\"glTextureStorage3DMultisample\"))\n\tgpTextureStorage3DMultisampleEXT = (C.GPTEXTURESTORAGE3DMULTISAMPLEEXT)(getProcAddr(\"glTextureStorage3DMultisampleEXT\"))\n\tgpTextureSubImage1D = (C.GPTEXTURESUBIMAGE1D)(getProcAddr(\"glTextureSubImage1D\"))\n\tgpTextureSubImage1DEXT = (C.GPTEXTURESUBIMAGE1DEXT)(getProcAddr(\"glTextureSubImage1DEXT\"))\n\tgpTextureSubImage2D = (C.GPTEXTURESUBIMAGE2D)(getProcAddr(\"glTextureSubImage2D\"))\n\tgpTextureSubImage2DEXT = (C.GPTEXTURESUBIMAGE2DEXT)(getProcAddr(\"glTextureSubImage2DEXT\"))\n\tgpTextureSubImage3D = (C.GPTEXTURESUBIMAGE3D)(getProcAddr(\"glTextureSubImage3D\"))\n\tgpTextureSubImage3DEXT = (C.GPTEXTURESUBIMAGE3DEXT)(getProcAddr(\"glTextureSubImage3DEXT\"))\n\tgpTextureView = (C.GPTEXTUREVIEW)(getProcAddr(\"glTextureView\"))\n\tgpTransformFeedbackBufferBase = (C.GPTRANSFORMFEEDBACKBUFFERBASE)(getProcAddr(\"glTransformFeedbackBufferBase\"))\n\tgpTransformFeedbackBufferRange = (C.GPTRANSFORMFEEDBACKBUFFERRANGE)(getProcAddr(\"glTransformFeedbackBufferRange\"))\n\tgpTransformFeedbackVaryings = (C.GPTRANSFORMFEEDBACKVARYINGS)(getProcAddr(\"glTransformFeedbackVaryings\"))\n\tif gpTransformFeedbackVaryings == nil {\n\t\treturn errors.New(\"glTransformFeedbackVaryings\")\n\t}\n\tgpTransformPathNV = (C.GPTRANSFORMPATHNV)(getProcAddr(\"glTransformPathNV\"))\n\tgpUniform1d = (C.GPUNIFORM1D)(getProcAddr(\"glUniform1d\"))\n\tif gpUniform1d == nil {\n\t\treturn errors.New(\"glUniform1d\")\n\t}\n\tgpUniform1dv = (C.GPUNIFORM1DV)(getProcAddr(\"glUniform1dv\"))\n\tif gpUniform1dv == nil {\n\t\treturn errors.New(\"glUniform1dv\")\n\t}\n\tgpUniform1f = (C.GPUNIFORM1F)(getProcAddr(\"glUniform1f\"))\n\tif gpUniform1f == nil {\n\t\treturn errors.New(\"glUniform1f\")\n\t}\n\tgpUniform1fv = (C.GPUNIFORM1FV)(getProcAddr(\"glUniform1fv\"))\n\tif gpUniform1fv == nil {\n\t\treturn errors.New(\"glUniform1fv\")\n\t}\n\tgpUniform1i = (C.GPUNIFORM1I)(getProcAddr(\"glUniform1i\"))\n\tif gpUniform1i == nil {\n\t\treturn errors.New(\"glUniform1i\")\n\t}\n\tgpUniform1i64ARB = (C.GPUNIFORM1I64ARB)(getProcAddr(\"glUniform1i64ARB\"))\n\tgpUniform1i64NV = (C.GPUNIFORM1I64NV)(getProcAddr(\"glUniform1i64NV\"))\n\tgpUniform1i64vARB = (C.GPUNIFORM1I64VARB)(getProcAddr(\"glUniform1i64vARB\"))\n\tgpUniform1i64vNV = (C.GPUNIFORM1I64VNV)(getProcAddr(\"glUniform1i64vNV\"))\n\tgpUniform1iv = (C.GPUNIFORM1IV)(getProcAddr(\"glUniform1iv\"))\n\tif gpUniform1iv == nil {\n\t\treturn errors.New(\"glUniform1iv\")\n\t}\n\tgpUniform1ui = (C.GPUNIFORM1UI)(getProcAddr(\"glUniform1ui\"))\n\tif gpUniform1ui == nil {\n\t\treturn errors.New(\"glUniform1ui\")\n\t}\n\tgpUniform1ui64ARB = (C.GPUNIFORM1UI64ARB)(getProcAddr(\"glUniform1ui64ARB\"))\n\tgpUniform1ui64NV = (C.GPUNIFORM1UI64NV)(getProcAddr(\"glUniform1ui64NV\"))\n\tgpUniform1ui64vARB = (C.GPUNIFORM1UI64VARB)(getProcAddr(\"glUniform1ui64vARB\"))\n\tgpUniform1ui64vNV = (C.GPUNIFORM1UI64VNV)(getProcAddr(\"glUniform1ui64vNV\"))\n\tgpUniform1uiv = (C.GPUNIFORM1UIV)(getProcAddr(\"glUniform1uiv\"))\n\tif gpUniform1uiv == nil {\n\t\treturn errors.New(\"glUniform1uiv\")\n\t}\n\tgpUniform2d = (C.GPUNIFORM2D)(getProcAddr(\"glUniform2d\"))\n\tif gpUniform2d == nil {\n\t\treturn errors.New(\"glUniform2d\")\n\t}\n\tgpUniform2dv = (C.GPUNIFORM2DV)(getProcAddr(\"glUniform2dv\"))\n\tif gpUniform2dv == nil {\n\t\treturn errors.New(\"glUniform2dv\")\n\t}\n\tgpUniform2f = (C.GPUNIFORM2F)(getProcAddr(\"glUniform2f\"))\n\tif gpUniform2f == nil {\n\t\treturn errors.New(\"glUniform2f\")\n\t}\n\tgpUniform2fv = (C.GPUNIFORM2FV)(getProcAddr(\"glUniform2fv\"))\n\tif gpUniform2fv == nil {\n\t\treturn errors.New(\"glUniform2fv\")\n\t}\n\tgpUniform2i = (C.GPUNIFORM2I)(getProcAddr(\"glUniform2i\"))\n\tif gpUniform2i == nil {\n\t\treturn errors.New(\"glUniform2i\")\n\t}\n\tgpUniform2i64ARB = (C.GPUNIFORM2I64ARB)(getProcAddr(\"glUniform2i64ARB\"))\n\tgpUniform2i64NV = (C.GPUNIFORM2I64NV)(getProcAddr(\"glUniform2i64NV\"))\n\tgpUniform2i64vARB = (C.GPUNIFORM2I64VARB)(getProcAddr(\"glUniform2i64vARB\"))\n\tgpUniform2i64vNV = (C.GPUNIFORM2I64VNV)(getProcAddr(\"glUniform2i64vNV\"))\n\tgpUniform2iv = (C.GPUNIFORM2IV)(getProcAddr(\"glUniform2iv\"))\n\tif gpUniform2iv == nil {\n\t\treturn errors.New(\"glUniform2iv\")\n\t}\n\tgpUniform2ui = (C.GPUNIFORM2UI)(getProcAddr(\"glUniform2ui\"))\n\tif gpUniform2ui == nil {\n\t\treturn errors.New(\"glUniform2ui\")\n\t}\n\tgpUniform2ui64ARB = (C.GPUNIFORM2UI64ARB)(getProcAddr(\"glUniform2ui64ARB\"))\n\tgpUniform2ui64NV = (C.GPUNIFORM2UI64NV)(getProcAddr(\"glUniform2ui64NV\"))\n\tgpUniform2ui64vARB = (C.GPUNIFORM2UI64VARB)(getProcAddr(\"glUniform2ui64vARB\"))\n\tgpUniform2ui64vNV = (C.GPUNIFORM2UI64VNV)(getProcAddr(\"glUniform2ui64vNV\"))\n\tgpUniform2uiv = (C.GPUNIFORM2UIV)(getProcAddr(\"glUniform2uiv\"))\n\tif gpUniform2uiv == nil {\n\t\treturn errors.New(\"glUniform2uiv\")\n\t}\n\tgpUniform3d = (C.GPUNIFORM3D)(getProcAddr(\"glUniform3d\"))\n\tif gpUniform3d == nil {\n\t\treturn errors.New(\"glUniform3d\")\n\t}\n\tgpUniform3dv = (C.GPUNIFORM3DV)(getProcAddr(\"glUniform3dv\"))\n\tif gpUniform3dv == nil {\n\t\treturn errors.New(\"glUniform3dv\")\n\t}\n\tgpUniform3f = (C.GPUNIFORM3F)(getProcAddr(\"glUniform3f\"))\n\tif gpUniform3f == nil {\n\t\treturn errors.New(\"glUniform3f\")\n\t}\n\tgpUniform3fv = (C.GPUNIFORM3FV)(getProcAddr(\"glUniform3fv\"))\n\tif gpUniform3fv == nil {\n\t\treturn errors.New(\"glUniform3fv\")\n\t}\n\tgpUniform3i = (C.GPUNIFORM3I)(getProcAddr(\"glUniform3i\"))\n\tif gpUniform3i == nil {\n\t\treturn errors.New(\"glUniform3i\")\n\t}\n\tgpUniform3i64ARB = (C.GPUNIFORM3I64ARB)(getProcAddr(\"glUniform3i64ARB\"))\n\tgpUniform3i64NV = (C.GPUNIFORM3I64NV)(getProcAddr(\"glUniform3i64NV\"))\n\tgpUniform3i64vARB = (C.GPUNIFORM3I64VARB)(getProcAddr(\"glUniform3i64vARB\"))\n\tgpUniform3i64vNV = (C.GPUNIFORM3I64VNV)(getProcAddr(\"glUniform3i64vNV\"))\n\tgpUniform3iv = (C.GPUNIFORM3IV)(getProcAddr(\"glUniform3iv\"))\n\tif gpUniform3iv == nil {\n\t\treturn errors.New(\"glUniform3iv\")\n\t}\n\tgpUniform3ui = (C.GPUNIFORM3UI)(getProcAddr(\"glUniform3ui\"))\n\tif gpUniform3ui == nil {\n\t\treturn errors.New(\"glUniform3ui\")\n\t}\n\tgpUniform3ui64ARB = (C.GPUNIFORM3UI64ARB)(getProcAddr(\"glUniform3ui64ARB\"))\n\tgpUniform3ui64NV = (C.GPUNIFORM3UI64NV)(getProcAddr(\"glUniform3ui64NV\"))\n\tgpUniform3ui64vARB = (C.GPUNIFORM3UI64VARB)(getProcAddr(\"glUniform3ui64vARB\"))\n\tgpUniform3ui64vNV = (C.GPUNIFORM3UI64VNV)(getProcAddr(\"glUniform3ui64vNV\"))\n\tgpUniform3uiv = (C.GPUNIFORM3UIV)(getProcAddr(\"glUniform3uiv\"))\n\tif gpUniform3uiv == nil {\n\t\treturn errors.New(\"glUniform3uiv\")\n\t}\n\tgpUniform4d = (C.GPUNIFORM4D)(getProcAddr(\"glUniform4d\"))\n\tif gpUniform4d == nil {\n\t\treturn errors.New(\"glUniform4d\")\n\t}\n\tgpUniform4dv = (C.GPUNIFORM4DV)(getProcAddr(\"glUniform4dv\"))\n\tif gpUniform4dv == nil {\n\t\treturn errors.New(\"glUniform4dv\")\n\t}\n\tgpUniform4f = (C.GPUNIFORM4F)(getProcAddr(\"glUniform4f\"))\n\tif gpUniform4f == nil {\n\t\treturn errors.New(\"glUniform4f\")\n\t}\n\tgpUniform4fv = (C.GPUNIFORM4FV)(getProcAddr(\"glUniform4fv\"))\n\tif gpUniform4fv == nil {\n\t\treturn errors.New(\"glUniform4fv\")\n\t}\n\tgpUniform4i = (C.GPUNIFORM4I)(getProcAddr(\"glUniform4i\"))\n\tif gpUniform4i == nil {\n\t\treturn errors.New(\"glUniform4i\")\n\t}\n\tgpUniform4i64ARB = (C.GPUNIFORM4I64ARB)(getProcAddr(\"glUniform4i64ARB\"))\n\tgpUniform4i64NV = (C.GPUNIFORM4I64NV)(getProcAddr(\"glUniform4i64NV\"))\n\tgpUniform4i64vARB = (C.GPUNIFORM4I64VARB)(getProcAddr(\"glUniform4i64vARB\"))\n\tgpUniform4i64vNV = (C.GPUNIFORM4I64VNV)(getProcAddr(\"glUniform4i64vNV\"))\n\tgpUniform4iv = (C.GPUNIFORM4IV)(getProcAddr(\"glUniform4iv\"))\n\tif gpUniform4iv == nil {\n\t\treturn errors.New(\"glUniform4iv\")\n\t}\n\tgpUniform4ui = (C.GPUNIFORM4UI)(getProcAddr(\"glUniform4ui\"))\n\tif gpUniform4ui == nil {\n\t\treturn errors.New(\"glUniform4ui\")\n\t}\n\tgpUniform4ui64ARB = (C.GPUNIFORM4UI64ARB)(getProcAddr(\"glUniform4ui64ARB\"))\n\tgpUniform4ui64NV = (C.GPUNIFORM4UI64NV)(getProcAddr(\"glUniform4ui64NV\"))\n\tgpUniform4ui64vARB = (C.GPUNIFORM4UI64VARB)(getProcAddr(\"glUniform4ui64vARB\"))\n\tgpUniform4ui64vNV = (C.GPUNIFORM4UI64VNV)(getProcAddr(\"glUniform4ui64vNV\"))\n\tgpUniform4uiv = (C.GPUNIFORM4UIV)(getProcAddr(\"glUniform4uiv\"))\n\tif gpUniform4uiv == nil {\n\t\treturn errors.New(\"glUniform4uiv\")\n\t}\n\tgpUniformBlockBinding = (C.GPUNIFORMBLOCKBINDING)(getProcAddr(\"glUniformBlockBinding\"))\n\tif gpUniformBlockBinding == nil {\n\t\treturn errors.New(\"glUniformBlockBinding\")\n\t}\n\tgpUniformHandleui64ARB = (C.GPUNIFORMHANDLEUI64ARB)(getProcAddr(\"glUniformHandleui64ARB\"))\n\tgpUniformHandleui64NV = (C.GPUNIFORMHANDLEUI64NV)(getProcAddr(\"glUniformHandleui64NV\"))\n\tgpUniformHandleui64vARB = (C.GPUNIFORMHANDLEUI64VARB)(getProcAddr(\"glUniformHandleui64vARB\"))\n\tgpUniformHandleui64vNV = (C.GPUNIFORMHANDLEUI64VNV)(getProcAddr(\"glUniformHandleui64vNV\"))\n\tgpUniformMatrix2dv = (C.GPUNIFORMMATRIX2DV)(getProcAddr(\"glUniformMatrix2dv\"))\n\tif gpUniformMatrix2dv == nil {\n\t\treturn errors.New(\"glUniformMatrix2dv\")\n\t}\n\tgpUniformMatrix2fv = (C.GPUNIFORMMATRIX2FV)(getProcAddr(\"glUniformMatrix2fv\"))\n\tif gpUniformMatrix2fv == nil {\n\t\treturn errors.New(\"glUniformMatrix2fv\")\n\t}\n\tgpUniformMatrix2x3dv = (C.GPUNIFORMMATRIX2X3DV)(getProcAddr(\"glUniformMatrix2x3dv\"))\n\tif gpUniformMatrix2x3dv == nil {\n\t\treturn errors.New(\"glUniformMatrix2x3dv\")\n\t}\n\tgpUniformMatrix2x3fv = (C.GPUNIFORMMATRIX2X3FV)(getProcAddr(\"glUniformMatrix2x3fv\"))\n\tif gpUniformMatrix2x3fv == nil {\n\t\treturn errors.New(\"glUniformMatrix2x3fv\")\n\t}\n\tgpUniformMatrix2x4dv = (C.GPUNIFORMMATRIX2X4DV)(getProcAddr(\"glUniformMatrix2x4dv\"))\n\tif gpUniformMatrix2x4dv == nil {\n\t\treturn errors.New(\"glUniformMatrix2x4dv\")\n\t}\n\tgpUniformMatrix2x4fv = (C.GPUNIFORMMATRIX2X4FV)(getProcAddr(\"glUniformMatrix2x4fv\"))\n\tif gpUniformMatrix2x4fv == nil {\n\t\treturn errors.New(\"glUniformMatrix2x4fv\")\n\t}\n\tgpUniformMatrix3dv = (C.GPUNIFORMMATRIX3DV)(getProcAddr(\"glUniformMatrix3dv\"))\n\tif gpUniformMatrix3dv == nil {\n\t\treturn errors.New(\"glUniformMatrix3dv\")\n\t}\n\tgpUniformMatrix3fv = (C.GPUNIFORMMATRIX3FV)(getProcAddr(\"glUniformMatrix3fv\"))\n\tif gpUniformMatrix3fv == nil {\n\t\treturn errors.New(\"glUniformMatrix3fv\")\n\t}\n\tgpUniformMatrix3x2dv = (C.GPUNIFORMMATRIX3X2DV)(getProcAddr(\"glUniformMatrix3x2dv\"))\n\tif gpUniformMatrix3x2dv == nil {\n\t\treturn errors.New(\"glUniformMatrix3x2dv\")\n\t}\n\tgpUniformMatrix3x2fv = (C.GPUNIFORMMATRIX3X2FV)(getProcAddr(\"glUniformMatrix3x2fv\"))\n\tif gpUniformMatrix3x2fv == nil {\n\t\treturn errors.New(\"glUniformMatrix3x2fv\")\n\t}\n\tgpUniformMatrix3x4dv = (C.GPUNIFORMMATRIX3X4DV)(getProcAddr(\"glUniformMatrix3x4dv\"))\n\tif gpUniformMatrix3x4dv == nil {\n\t\treturn errors.New(\"glUniformMatrix3x4dv\")\n\t}\n\tgpUniformMatrix3x4fv = (C.GPUNIFORMMATRIX3X4FV)(getProcAddr(\"glUniformMatrix3x4fv\"))\n\tif gpUniformMatrix3x4fv == nil {\n\t\treturn errors.New(\"glUniformMatrix3x4fv\")\n\t}\n\tgpUniformMatrix4dv = (C.GPUNIFORMMATRIX4DV)(getProcAddr(\"glUniformMatrix4dv\"))\n\tif gpUniformMatrix4dv == nil {\n\t\treturn errors.New(\"glUniformMatrix4dv\")\n\t}\n\tgpUniformMatrix4fv = (C.GPUNIFORMMATRIX4FV)(getProcAddr(\"glUniformMatrix4fv\"))\n\tif gpUniformMatrix4fv == nil {\n\t\treturn errors.New(\"glUniformMatrix4fv\")\n\t}\n\tgpUniformMatrix4x2dv = (C.GPUNIFORMMATRIX4X2DV)(getProcAddr(\"glUniformMatrix4x2dv\"))\n\tif gpUniformMatrix4x2dv == nil {\n\t\treturn errors.New(\"glUniformMatrix4x2dv\")\n\t}\n\tgpUniformMatrix4x2fv = (C.GPUNIFORMMATRIX4X2FV)(getProcAddr(\"glUniformMatrix4x2fv\"))\n\tif gpUniformMatrix4x2fv == nil {\n\t\treturn errors.New(\"glUniformMatrix4x2fv\")\n\t}\n\tgpUniformMatrix4x3dv = (C.GPUNIFORMMATRIX4X3DV)(getProcAddr(\"glUniformMatrix4x3dv\"))\n\tif gpUniformMatrix4x3dv == nil {\n\t\treturn errors.New(\"glUniformMatrix4x3dv\")\n\t}\n\tgpUniformMatrix4x3fv = (C.GPUNIFORMMATRIX4X3FV)(getProcAddr(\"glUniformMatrix4x3fv\"))\n\tif gpUniformMatrix4x3fv == nil {\n\t\treturn errors.New(\"glUniformMatrix4x3fv\")\n\t}\n\tgpUniformSubroutinesuiv = (C.GPUNIFORMSUBROUTINESUIV)(getProcAddr(\"glUniformSubroutinesuiv\"))\n\tif gpUniformSubroutinesuiv == nil {\n\t\treturn errors.New(\"glUniformSubroutinesuiv\")\n\t}\n\tgpUniformui64NV = (C.GPUNIFORMUI64NV)(getProcAddr(\"glUniformui64NV\"))\n\tgpUniformui64vNV = (C.GPUNIFORMUI64VNV)(getProcAddr(\"glUniformui64vNV\"))\n\tgpUnmapBuffer = (C.GPUNMAPBUFFER)(getProcAddr(\"glUnmapBuffer\"))\n\tif gpUnmapBuffer == nil {\n\t\treturn errors.New(\"glUnmapBuffer\")\n\t}\n\tgpUnmapNamedBuffer = (C.GPUNMAPNAMEDBUFFER)(getProcAddr(\"glUnmapNamedBuffer\"))\n\tgpUnmapNamedBufferEXT = (C.GPUNMAPNAMEDBUFFEREXT)(getProcAddr(\"glUnmapNamedBufferEXT\"))\n\tgpUseProgram = (C.GPUSEPROGRAM)(getProcAddr(\"glUseProgram\"))\n\tif gpUseProgram == nil {\n\t\treturn errors.New(\"glUseProgram\")\n\t}\n\tgpUseProgramStages = (C.GPUSEPROGRAMSTAGES)(getProcAddr(\"glUseProgramStages\"))\n\tif gpUseProgramStages == nil {\n\t\treturn errors.New(\"glUseProgramStages\")\n\t}\n\tgpUseProgramStagesEXT = (C.GPUSEPROGRAMSTAGESEXT)(getProcAddr(\"glUseProgramStagesEXT\"))\n\tgpUseShaderProgramEXT = (C.GPUSESHADERPROGRAMEXT)(getProcAddr(\"glUseShaderProgramEXT\"))\n\tgpValidateProgram = (C.GPVALIDATEPROGRAM)(getProcAddr(\"glValidateProgram\"))\n\tif gpValidateProgram == nil {\n\t\treturn errors.New(\"glValidateProgram\")\n\t}\n\tgpValidateProgramPipeline = (C.GPVALIDATEPROGRAMPIPELINE)(getProcAddr(\"glValidateProgramPipeline\"))\n\tif gpValidateProgramPipeline == nil {\n\t\treturn errors.New(\"glValidateProgramPipeline\")\n\t}\n\tgpValidateProgramPipelineEXT = (C.GPVALIDATEPROGRAMPIPELINEEXT)(getProcAddr(\"glValidateProgramPipelineEXT\"))\n\tgpVertexArrayAttribBinding = (C.GPVERTEXARRAYATTRIBBINDING)(getProcAddr(\"glVertexArrayAttribBinding\"))\n\tgpVertexArrayAttribFormat = (C.GPVERTEXARRAYATTRIBFORMAT)(getProcAddr(\"glVertexArrayAttribFormat\"))\n\tgpVertexArrayAttribIFormat = (C.GPVERTEXARRAYATTRIBIFORMAT)(getProcAddr(\"glVertexArrayAttribIFormat\"))\n\tgpVertexArrayAttribLFormat = (C.GPVERTEXARRAYATTRIBLFORMAT)(getProcAddr(\"glVertexArrayAttribLFormat\"))\n\tgpVertexArrayBindVertexBufferEXT = (C.GPVERTEXARRAYBINDVERTEXBUFFEREXT)(getProcAddr(\"glVertexArrayBindVertexBufferEXT\"))\n\tgpVertexArrayBindingDivisor = (C.GPVERTEXARRAYBINDINGDIVISOR)(getProcAddr(\"glVertexArrayBindingDivisor\"))\n\tgpVertexArrayColorOffsetEXT = (C.GPVERTEXARRAYCOLOROFFSETEXT)(getProcAddr(\"glVertexArrayColorOffsetEXT\"))\n\tgpVertexArrayEdgeFlagOffsetEXT = (C.GPVERTEXARRAYEDGEFLAGOFFSETEXT)(getProcAddr(\"glVertexArrayEdgeFlagOffsetEXT\"))\n\tgpVertexArrayElementBuffer = (C.GPVERTEXARRAYELEMENTBUFFER)(getProcAddr(\"glVertexArrayElementBuffer\"))\n\tgpVertexArrayFogCoordOffsetEXT = (C.GPVERTEXARRAYFOGCOORDOFFSETEXT)(getProcAddr(\"glVertexArrayFogCoordOffsetEXT\"))\n\tgpVertexArrayIndexOffsetEXT = (C.GPVERTEXARRAYINDEXOFFSETEXT)(getProcAddr(\"glVertexArrayIndexOffsetEXT\"))\n\tgpVertexArrayMultiTexCoordOffsetEXT = (C.GPVERTEXARRAYMULTITEXCOORDOFFSETEXT)(getProcAddr(\"glVertexArrayMultiTexCoordOffsetEXT\"))\n\tgpVertexArrayNormalOffsetEXT = (C.GPVERTEXARRAYNORMALOFFSETEXT)(getProcAddr(\"glVertexArrayNormalOffsetEXT\"))\n\tgpVertexArraySecondaryColorOffsetEXT = (C.GPVERTEXARRAYSECONDARYCOLOROFFSETEXT)(getProcAddr(\"glVertexArraySecondaryColorOffsetEXT\"))\n\tgpVertexArrayTexCoordOffsetEXT = (C.GPVERTEXARRAYTEXCOORDOFFSETEXT)(getProcAddr(\"glVertexArrayTexCoordOffsetEXT\"))\n\tgpVertexArrayVertexAttribBindingEXT = (C.GPVERTEXARRAYVERTEXATTRIBBINDINGEXT)(getProcAddr(\"glVertexArrayVertexAttribBindingEXT\"))\n\tgpVertexArrayVertexAttribDivisorEXT = (C.GPVERTEXARRAYVERTEXATTRIBDIVISOREXT)(getProcAddr(\"glVertexArrayVertexAttribDivisorEXT\"))\n\tgpVertexArrayVertexAttribFormatEXT = (C.GPVERTEXARRAYVERTEXATTRIBFORMATEXT)(getProcAddr(\"glVertexArrayVertexAttribFormatEXT\"))\n\tgpVertexArrayVertexAttribIFormatEXT = (C.GPVERTEXARRAYVERTEXATTRIBIFORMATEXT)(getProcAddr(\"glVertexArrayVertexAttribIFormatEXT\"))\n\tgpVertexArrayVertexAttribIOffsetEXT = (C.GPVERTEXARRAYVERTEXATTRIBIOFFSETEXT)(getProcAddr(\"glVertexArrayVertexAttribIOffsetEXT\"))\n\tgpVertexArrayVertexAttribLFormatEXT = (C.GPVERTEXARRAYVERTEXATTRIBLFORMATEXT)(getProcAddr(\"glVertexArrayVertexAttribLFormatEXT\"))\n\tgpVertexArrayVertexAttribLOffsetEXT = (C.GPVERTEXARRAYVERTEXATTRIBLOFFSETEXT)(getProcAddr(\"glVertexArrayVertexAttribLOffsetEXT\"))\n\tgpVertexArrayVertexAttribOffsetEXT = (C.GPVERTEXARRAYVERTEXATTRIBOFFSETEXT)(getProcAddr(\"glVertexArrayVertexAttribOffsetEXT\"))\n\tgpVertexArrayVertexBindingDivisorEXT = (C.GPVERTEXARRAYVERTEXBINDINGDIVISOREXT)(getProcAddr(\"glVertexArrayVertexBindingDivisorEXT\"))\n\tgpVertexArrayVertexBuffer = (C.GPVERTEXARRAYVERTEXBUFFER)(getProcAddr(\"glVertexArrayVertexBuffer\"))\n\tgpVertexArrayVertexBuffers = (C.GPVERTEXARRAYVERTEXBUFFERS)(getProcAddr(\"glVertexArrayVertexBuffers\"))\n\tgpVertexArrayVertexOffsetEXT = (C.GPVERTEXARRAYVERTEXOFFSETEXT)(getProcAddr(\"glVertexArrayVertexOffsetEXT\"))\n\tgpVertexAttrib1d = (C.GPVERTEXATTRIB1D)(getProcAddr(\"glVertexAttrib1d\"))\n\tif gpVertexAttrib1d == nil {\n\t\treturn errors.New(\"glVertexAttrib1d\")\n\t}\n\tgpVertexAttrib1dv = (C.GPVERTEXATTRIB1DV)(getProcAddr(\"glVertexAttrib1dv\"))\n\tif gpVertexAttrib1dv == nil {\n\t\treturn errors.New(\"glVertexAttrib1dv\")\n\t}\n\tgpVertexAttrib1f = (C.GPVERTEXATTRIB1F)(getProcAddr(\"glVertexAttrib1f\"))\n\tif gpVertexAttrib1f == nil {\n\t\treturn errors.New(\"glVertexAttrib1f\")\n\t}\n\tgpVertexAttrib1fv = (C.GPVERTEXATTRIB1FV)(getProcAddr(\"glVertexAttrib1fv\"))\n\tif gpVertexAttrib1fv == nil {\n\t\treturn errors.New(\"glVertexAttrib1fv\")\n\t}\n\tgpVertexAttrib1s = (C.GPVERTEXATTRIB1S)(getProcAddr(\"glVertexAttrib1s\"))\n\tif gpVertexAttrib1s == nil {\n\t\treturn errors.New(\"glVertexAttrib1s\")\n\t}\n\tgpVertexAttrib1sv = (C.GPVERTEXATTRIB1SV)(getProcAddr(\"glVertexAttrib1sv\"))\n\tif gpVertexAttrib1sv == nil {\n\t\treturn errors.New(\"glVertexAttrib1sv\")\n\t}\n\tgpVertexAttrib2d = (C.GPVERTEXATTRIB2D)(getProcAddr(\"glVertexAttrib2d\"))\n\tif gpVertexAttrib2d == nil {\n\t\treturn errors.New(\"glVertexAttrib2d\")\n\t}\n\tgpVertexAttrib2dv = (C.GPVERTEXATTRIB2DV)(getProcAddr(\"glVertexAttrib2dv\"))\n\tif gpVertexAttrib2dv == nil {\n\t\treturn errors.New(\"glVertexAttrib2dv\")\n\t}\n\tgpVertexAttrib2f = (C.GPVERTEXATTRIB2F)(getProcAddr(\"glVertexAttrib2f\"))\n\tif gpVertexAttrib2f == nil {\n\t\treturn errors.New(\"glVertexAttrib2f\")\n\t}\n\tgpVertexAttrib2fv = (C.GPVERTEXATTRIB2FV)(getProcAddr(\"glVertexAttrib2fv\"))\n\tif gpVertexAttrib2fv == nil {\n\t\treturn errors.New(\"glVertexAttrib2fv\")\n\t}\n\tgpVertexAttrib2s = (C.GPVERTEXATTRIB2S)(getProcAddr(\"glVertexAttrib2s\"))\n\tif gpVertexAttrib2s == nil {\n\t\treturn errors.New(\"glVertexAttrib2s\")\n\t}\n\tgpVertexAttrib2sv = (C.GPVERTEXATTRIB2SV)(getProcAddr(\"glVertexAttrib2sv\"))\n\tif gpVertexAttrib2sv == nil {\n\t\treturn errors.New(\"glVertexAttrib2sv\")\n\t}\n\tgpVertexAttrib3d = (C.GPVERTEXATTRIB3D)(getProcAddr(\"glVertexAttrib3d\"))\n\tif gpVertexAttrib3d == nil {\n\t\treturn errors.New(\"glVertexAttrib3d\")\n\t}\n\tgpVertexAttrib3dv = (C.GPVERTEXATTRIB3DV)(getProcAddr(\"glVertexAttrib3dv\"))\n\tif gpVertexAttrib3dv == nil {\n\t\treturn errors.New(\"glVertexAttrib3dv\")\n\t}\n\tgpVertexAttrib3f = (C.GPVERTEXATTRIB3F)(getProcAddr(\"glVertexAttrib3f\"))\n\tif gpVertexAttrib3f == nil {\n\t\treturn errors.New(\"glVertexAttrib3f\")\n\t}\n\tgpVertexAttrib3fv = (C.GPVERTEXATTRIB3FV)(getProcAddr(\"glVertexAttrib3fv\"))\n\tif gpVertexAttrib3fv == nil {\n\t\treturn errors.New(\"glVertexAttrib3fv\")\n\t}\n\tgpVertexAttrib3s = (C.GPVERTEXATTRIB3S)(getProcAddr(\"glVertexAttrib3s\"))\n\tif gpVertexAttrib3s == nil {\n\t\treturn errors.New(\"glVertexAttrib3s\")\n\t}\n\tgpVertexAttrib3sv = (C.GPVERTEXATTRIB3SV)(getProcAddr(\"glVertexAttrib3sv\"))\n\tif gpVertexAttrib3sv == nil {\n\t\treturn errors.New(\"glVertexAttrib3sv\")\n\t}\n\tgpVertexAttrib4Nbv = (C.GPVERTEXATTRIB4NBV)(getProcAddr(\"glVertexAttrib4Nbv\"))\n\tif gpVertexAttrib4Nbv == nil {\n\t\treturn errors.New(\"glVertexAttrib4Nbv\")\n\t}\n\tgpVertexAttrib4Niv = (C.GPVERTEXATTRIB4NIV)(getProcAddr(\"glVertexAttrib4Niv\"))\n\tif gpVertexAttrib4Niv == nil {\n\t\treturn errors.New(\"glVertexAttrib4Niv\")\n\t}\n\tgpVertexAttrib4Nsv = (C.GPVERTEXATTRIB4NSV)(getProcAddr(\"glVertexAttrib4Nsv\"))\n\tif gpVertexAttrib4Nsv == nil {\n\t\treturn errors.New(\"glVertexAttrib4Nsv\")\n\t}\n\tgpVertexAttrib4Nub = (C.GPVERTEXATTRIB4NUB)(getProcAddr(\"glVertexAttrib4Nub\"))\n\tif gpVertexAttrib4Nub == nil {\n\t\treturn errors.New(\"glVertexAttrib4Nub\")\n\t}\n\tgpVertexAttrib4Nubv = (C.GPVERTEXATTRIB4NUBV)(getProcAddr(\"glVertexAttrib4Nubv\"))\n\tif gpVertexAttrib4Nubv == nil {\n\t\treturn errors.New(\"glVertexAttrib4Nubv\")\n\t}\n\tgpVertexAttrib4Nuiv = (C.GPVERTEXATTRIB4NUIV)(getProcAddr(\"glVertexAttrib4Nuiv\"))\n\tif gpVertexAttrib4Nuiv == nil {\n\t\treturn errors.New(\"glVertexAttrib4Nuiv\")\n\t}\n\tgpVertexAttrib4Nusv = (C.GPVERTEXATTRIB4NUSV)(getProcAddr(\"glVertexAttrib4Nusv\"))\n\tif gpVertexAttrib4Nusv == nil {\n\t\treturn errors.New(\"glVertexAttrib4Nusv\")\n\t}\n\tgpVertexAttrib4bv = (C.GPVERTEXATTRIB4BV)(getProcAddr(\"glVertexAttrib4bv\"))\n\tif gpVertexAttrib4bv == nil {\n\t\treturn errors.New(\"glVertexAttrib4bv\")\n\t}\n\tgpVertexAttrib4d = (C.GPVERTEXATTRIB4D)(getProcAddr(\"glVertexAttrib4d\"))\n\tif gpVertexAttrib4d == nil {\n\t\treturn errors.New(\"glVertexAttrib4d\")\n\t}\n\tgpVertexAttrib4dv = (C.GPVERTEXATTRIB4DV)(getProcAddr(\"glVertexAttrib4dv\"))\n\tif gpVertexAttrib4dv == nil {\n\t\treturn errors.New(\"glVertexAttrib4dv\")\n\t}\n\tgpVertexAttrib4f = (C.GPVERTEXATTRIB4F)(getProcAddr(\"glVertexAttrib4f\"))\n\tif gpVertexAttrib4f == nil {\n\t\treturn errors.New(\"glVertexAttrib4f\")\n\t}\n\tgpVertexAttrib4fv = (C.GPVERTEXATTRIB4FV)(getProcAddr(\"glVertexAttrib4fv\"))\n\tif gpVertexAttrib4fv == nil {\n\t\treturn errors.New(\"glVertexAttrib4fv\")\n\t}\n\tgpVertexAttrib4iv = (C.GPVERTEXATTRIB4IV)(getProcAddr(\"glVertexAttrib4iv\"))\n\tif gpVertexAttrib4iv == nil {\n\t\treturn errors.New(\"glVertexAttrib4iv\")\n\t}\n\tgpVertexAttrib4s = (C.GPVERTEXATTRIB4S)(getProcAddr(\"glVertexAttrib4s\"))\n\tif gpVertexAttrib4s == nil {\n\t\treturn errors.New(\"glVertexAttrib4s\")\n\t}\n\tgpVertexAttrib4sv = (C.GPVERTEXATTRIB4SV)(getProcAddr(\"glVertexAttrib4sv\"))\n\tif gpVertexAttrib4sv == nil {\n\t\treturn errors.New(\"glVertexAttrib4sv\")\n\t}\n\tgpVertexAttrib4ubv = (C.GPVERTEXATTRIB4UBV)(getProcAddr(\"glVertexAttrib4ubv\"))\n\tif gpVertexAttrib4ubv == nil {\n\t\treturn errors.New(\"glVertexAttrib4ubv\")\n\t}\n\tgpVertexAttrib4uiv = (C.GPVERTEXATTRIB4UIV)(getProcAddr(\"glVertexAttrib4uiv\"))\n\tif gpVertexAttrib4uiv == nil {\n\t\treturn errors.New(\"glVertexAttrib4uiv\")\n\t}\n\tgpVertexAttrib4usv = (C.GPVERTEXATTRIB4USV)(getProcAddr(\"glVertexAttrib4usv\"))\n\tif gpVertexAttrib4usv == nil {\n\t\treturn errors.New(\"glVertexAttrib4usv\")\n\t}\n\tgpVertexAttribBinding = (C.GPVERTEXATTRIBBINDING)(getProcAddr(\"glVertexAttribBinding\"))\n\tgpVertexAttribDivisor = (C.GPVERTEXATTRIBDIVISOR)(getProcAddr(\"glVertexAttribDivisor\"))\n\tif gpVertexAttribDivisor == nil {\n\t\treturn errors.New(\"glVertexAttribDivisor\")\n\t}\n\tgpVertexAttribDivisorARB = (C.GPVERTEXATTRIBDIVISORARB)(getProcAddr(\"glVertexAttribDivisorARB\"))\n\tgpVertexAttribFormat = (C.GPVERTEXATTRIBFORMAT)(getProcAddr(\"glVertexAttribFormat\"))\n\tgpVertexAttribFormatNV = (C.GPVERTEXATTRIBFORMATNV)(getProcAddr(\"glVertexAttribFormatNV\"))\n\tgpVertexAttribI1i = (C.GPVERTEXATTRIBI1I)(getProcAddr(\"glVertexAttribI1i\"))\n\tif gpVertexAttribI1i == nil {\n\t\treturn errors.New(\"glVertexAttribI1i\")\n\t}\n\tgpVertexAttribI1iv = (C.GPVERTEXATTRIBI1IV)(getProcAddr(\"glVertexAttribI1iv\"))\n\tif gpVertexAttribI1iv == nil {\n\t\treturn errors.New(\"glVertexAttribI1iv\")\n\t}\n\tgpVertexAttribI1ui = (C.GPVERTEXATTRIBI1UI)(getProcAddr(\"glVertexAttribI1ui\"))\n\tif gpVertexAttribI1ui == nil {\n\t\treturn errors.New(\"glVertexAttribI1ui\")\n\t}\n\tgpVertexAttribI1uiv = (C.GPVERTEXATTRIBI1UIV)(getProcAddr(\"glVertexAttribI1uiv\"))\n\tif gpVertexAttribI1uiv == nil {\n\t\treturn errors.New(\"glVertexAttribI1uiv\")\n\t}\n\tgpVertexAttribI2i = (C.GPVERTEXATTRIBI2I)(getProcAddr(\"glVertexAttribI2i\"))\n\tif gpVertexAttribI2i == nil {\n\t\treturn errors.New(\"glVertexAttribI2i\")\n\t}\n\tgpVertexAttribI2iv = (C.GPVERTEXATTRIBI2IV)(getProcAddr(\"glVertexAttribI2iv\"))\n\tif gpVertexAttribI2iv == nil {\n\t\treturn errors.New(\"glVertexAttribI2iv\")\n\t}\n\tgpVertexAttribI2ui = (C.GPVERTEXATTRIBI2UI)(getProcAddr(\"glVertexAttribI2ui\"))\n\tif gpVertexAttribI2ui == nil {\n\t\treturn errors.New(\"glVertexAttribI2ui\")\n\t}\n\tgpVertexAttribI2uiv = (C.GPVERTEXATTRIBI2UIV)(getProcAddr(\"glVertexAttribI2uiv\"))\n\tif gpVertexAttribI2uiv == nil {\n\t\treturn errors.New(\"glVertexAttribI2uiv\")\n\t}\n\tgpVertexAttribI3i = (C.GPVERTEXATTRIBI3I)(getProcAddr(\"glVertexAttribI3i\"))\n\tif gpVertexAttribI3i == nil {\n\t\treturn errors.New(\"glVertexAttribI3i\")\n\t}\n\tgpVertexAttribI3iv = (C.GPVERTEXATTRIBI3IV)(getProcAddr(\"glVertexAttribI3iv\"))\n\tif gpVertexAttribI3iv == nil {\n\t\treturn errors.New(\"glVertexAttribI3iv\")\n\t}\n\tgpVertexAttribI3ui = (C.GPVERTEXATTRIBI3UI)(getProcAddr(\"glVertexAttribI3ui\"))\n\tif gpVertexAttribI3ui == nil {\n\t\treturn errors.New(\"glVertexAttribI3ui\")\n\t}\n\tgpVertexAttribI3uiv = (C.GPVERTEXATTRIBI3UIV)(getProcAddr(\"glVertexAttribI3uiv\"))\n\tif gpVertexAttribI3uiv == nil {\n\t\treturn errors.New(\"glVertexAttribI3uiv\")\n\t}\n\tgpVertexAttribI4bv = (C.GPVERTEXATTRIBI4BV)(getProcAddr(\"glVertexAttribI4bv\"))\n\tif gpVertexAttribI4bv == nil {\n\t\treturn errors.New(\"glVertexAttribI4bv\")\n\t}\n\tgpVertexAttribI4i = (C.GPVERTEXATTRIBI4I)(getProcAddr(\"glVertexAttribI4i\"))\n\tif gpVertexAttribI4i == nil {\n\t\treturn errors.New(\"glVertexAttribI4i\")\n\t}\n\tgpVertexAttribI4iv = (C.GPVERTEXATTRIBI4IV)(getProcAddr(\"glVertexAttribI4iv\"))\n\tif gpVertexAttribI4iv == nil {\n\t\treturn errors.New(\"glVertexAttribI4iv\")\n\t}\n\tgpVertexAttribI4sv = (C.GPVERTEXATTRIBI4SV)(getProcAddr(\"glVertexAttribI4sv\"))\n\tif gpVertexAttribI4sv == nil {\n\t\treturn errors.New(\"glVertexAttribI4sv\")\n\t}\n\tgpVertexAttribI4ubv = (C.GPVERTEXATTRIBI4UBV)(getProcAddr(\"glVertexAttribI4ubv\"))\n\tif gpVertexAttribI4ubv == nil {\n\t\treturn errors.New(\"glVertexAttribI4ubv\")\n\t}\n\tgpVertexAttribI4ui = (C.GPVERTEXATTRIBI4UI)(getProcAddr(\"glVertexAttribI4ui\"))\n\tif gpVertexAttribI4ui == nil {\n\t\treturn errors.New(\"glVertexAttribI4ui\")\n\t}\n\tgpVertexAttribI4uiv = (C.GPVERTEXATTRIBI4UIV)(getProcAddr(\"glVertexAttribI4uiv\"))\n\tif gpVertexAttribI4uiv == nil {\n\t\treturn errors.New(\"glVertexAttribI4uiv\")\n\t}\n\tgpVertexAttribI4usv = (C.GPVERTEXATTRIBI4USV)(getProcAddr(\"glVertexAttribI4usv\"))\n\tif gpVertexAttribI4usv == nil {\n\t\treturn errors.New(\"glVertexAttribI4usv\")\n\t}\n\tgpVertexAttribIFormat = (C.GPVERTEXATTRIBIFORMAT)(getProcAddr(\"glVertexAttribIFormat\"))\n\tgpVertexAttribIFormatNV = (C.GPVERTEXATTRIBIFORMATNV)(getProcAddr(\"glVertexAttribIFormatNV\"))\n\tgpVertexAttribIPointer = (C.GPVERTEXATTRIBIPOINTER)(getProcAddr(\"glVertexAttribIPointer\"))\n\tif gpVertexAttribIPointer == nil {\n\t\treturn errors.New(\"glVertexAttribIPointer\")\n\t}\n\tgpVertexAttribL1d = (C.GPVERTEXATTRIBL1D)(getProcAddr(\"glVertexAttribL1d\"))\n\tif gpVertexAttribL1d == nil {\n\t\treturn errors.New(\"glVertexAttribL1d\")\n\t}\n\tgpVertexAttribL1dv = (C.GPVERTEXATTRIBL1DV)(getProcAddr(\"glVertexAttribL1dv\"))\n\tif gpVertexAttribL1dv == nil {\n\t\treturn errors.New(\"glVertexAttribL1dv\")\n\t}\n\tgpVertexAttribL1i64NV = (C.GPVERTEXATTRIBL1I64NV)(getProcAddr(\"glVertexAttribL1i64NV\"))\n\tgpVertexAttribL1i64vNV = (C.GPVERTEXATTRIBL1I64VNV)(getProcAddr(\"glVertexAttribL1i64vNV\"))\n\tgpVertexAttribL1ui64ARB = (C.GPVERTEXATTRIBL1UI64ARB)(getProcAddr(\"glVertexAttribL1ui64ARB\"))\n\tgpVertexAttribL1ui64NV = (C.GPVERTEXATTRIBL1UI64NV)(getProcAddr(\"glVertexAttribL1ui64NV\"))\n\tgpVertexAttribL1ui64vARB = (C.GPVERTEXATTRIBL1UI64VARB)(getProcAddr(\"glVertexAttribL1ui64vARB\"))\n\tgpVertexAttribL1ui64vNV = (C.GPVERTEXATTRIBL1UI64VNV)(getProcAddr(\"glVertexAttribL1ui64vNV\"))\n\tgpVertexAttribL2d = (C.GPVERTEXATTRIBL2D)(getProcAddr(\"glVertexAttribL2d\"))\n\tif gpVertexAttribL2d == nil {\n\t\treturn errors.New(\"glVertexAttribL2d\")\n\t}\n\tgpVertexAttribL2dv = (C.GPVERTEXATTRIBL2DV)(getProcAddr(\"glVertexAttribL2dv\"))\n\tif gpVertexAttribL2dv == nil {\n\t\treturn errors.New(\"glVertexAttribL2dv\")\n\t}\n\tgpVertexAttribL2i64NV = (C.GPVERTEXATTRIBL2I64NV)(getProcAddr(\"glVertexAttribL2i64NV\"))\n\tgpVertexAttribL2i64vNV = (C.GPVERTEXATTRIBL2I64VNV)(getProcAddr(\"glVertexAttribL2i64vNV\"))\n\tgpVertexAttribL2ui64NV = (C.GPVERTEXATTRIBL2UI64NV)(getProcAddr(\"glVertexAttribL2ui64NV\"))\n\tgpVertexAttribL2ui64vNV = (C.GPVERTEXATTRIBL2UI64VNV)(getProcAddr(\"glVertexAttribL2ui64vNV\"))\n\tgpVertexAttribL3d = (C.GPVERTEXATTRIBL3D)(getProcAddr(\"glVertexAttribL3d\"))\n\tif gpVertexAttribL3d == nil {\n\t\treturn errors.New(\"glVertexAttribL3d\")\n\t}\n\tgpVertexAttribL3dv = (C.GPVERTEXATTRIBL3DV)(getProcAddr(\"glVertexAttribL3dv\"))\n\tif gpVertexAttribL3dv == nil {\n\t\treturn errors.New(\"glVertexAttribL3dv\")\n\t}\n\tgpVertexAttribL3i64NV = (C.GPVERTEXATTRIBL3I64NV)(getProcAddr(\"glVertexAttribL3i64NV\"))\n\tgpVertexAttribL3i64vNV = (C.GPVERTEXATTRIBL3I64VNV)(getProcAddr(\"glVertexAttribL3i64vNV\"))\n\tgpVertexAttribL3ui64NV = (C.GPVERTEXATTRIBL3UI64NV)(getProcAddr(\"glVertexAttribL3ui64NV\"))\n\tgpVertexAttribL3ui64vNV = (C.GPVERTEXATTRIBL3UI64VNV)(getProcAddr(\"glVertexAttribL3ui64vNV\"))\n\tgpVertexAttribL4d = (C.GPVERTEXATTRIBL4D)(getProcAddr(\"glVertexAttribL4d\"))\n\tif gpVertexAttribL4d == nil {\n\t\treturn errors.New(\"glVertexAttribL4d\")\n\t}\n\tgpVertexAttribL4dv = (C.GPVERTEXATTRIBL4DV)(getProcAddr(\"glVertexAttribL4dv\"))\n\tif gpVertexAttribL4dv == nil {\n\t\treturn errors.New(\"glVertexAttribL4dv\")\n\t}\n\tgpVertexAttribL4i64NV = (C.GPVERTEXATTRIBL4I64NV)(getProcAddr(\"glVertexAttribL4i64NV\"))\n\tgpVertexAttribL4i64vNV = (C.GPVERTEXATTRIBL4I64VNV)(getProcAddr(\"glVertexAttribL4i64vNV\"))\n\tgpVertexAttribL4ui64NV = (C.GPVERTEXATTRIBL4UI64NV)(getProcAddr(\"glVertexAttribL4ui64NV\"))\n\tgpVertexAttribL4ui64vNV = (C.GPVERTEXATTRIBL4UI64VNV)(getProcAddr(\"glVertexAttribL4ui64vNV\"))\n\tgpVertexAttribLFormat = (C.GPVERTEXATTRIBLFORMAT)(getProcAddr(\"glVertexAttribLFormat\"))\n\tgpVertexAttribLFormatNV = (C.GPVERTEXATTRIBLFORMATNV)(getProcAddr(\"glVertexAttribLFormatNV\"))\n\tgpVertexAttribLPointer = (C.GPVERTEXATTRIBLPOINTER)(getProcAddr(\"glVertexAttribLPointer\"))\n\tif gpVertexAttribLPointer == nil {\n\t\treturn errors.New(\"glVertexAttribLPointer\")\n\t}\n\tgpVertexAttribP1ui = (C.GPVERTEXATTRIBP1UI)(getProcAddr(\"glVertexAttribP1ui\"))\n\tif gpVertexAttribP1ui == nil {\n\t\treturn errors.New(\"glVertexAttribP1ui\")\n\t}\n\tgpVertexAttribP1uiv = (C.GPVERTEXATTRIBP1UIV)(getProcAddr(\"glVertexAttribP1uiv\"))\n\tif gpVertexAttribP1uiv == nil {\n\t\treturn errors.New(\"glVertexAttribP1uiv\")\n\t}\n\tgpVertexAttribP2ui = (C.GPVERTEXATTRIBP2UI)(getProcAddr(\"glVertexAttribP2ui\"))\n\tif gpVertexAttribP2ui == nil {\n\t\treturn errors.New(\"glVertexAttribP2ui\")\n\t}\n\tgpVertexAttribP2uiv = (C.GPVERTEXATTRIBP2UIV)(getProcAddr(\"glVertexAttribP2uiv\"))\n\tif gpVertexAttribP2uiv == nil {\n\t\treturn errors.New(\"glVertexAttribP2uiv\")\n\t}\n\tgpVertexAttribP3ui = (C.GPVERTEXATTRIBP3UI)(getProcAddr(\"glVertexAttribP3ui\"))\n\tif gpVertexAttribP3ui == nil {\n\t\treturn errors.New(\"glVertexAttribP3ui\")\n\t}\n\tgpVertexAttribP3uiv = (C.GPVERTEXATTRIBP3UIV)(getProcAddr(\"glVertexAttribP3uiv\"))\n\tif gpVertexAttribP3uiv == nil {\n\t\treturn errors.New(\"glVertexAttribP3uiv\")\n\t}\n\tgpVertexAttribP4ui = (C.GPVERTEXATTRIBP4UI)(getProcAddr(\"glVertexAttribP4ui\"))\n\tif gpVertexAttribP4ui == nil {\n\t\treturn errors.New(\"glVertexAttribP4ui\")\n\t}\n\tgpVertexAttribP4uiv = (C.GPVERTEXATTRIBP4UIV)(getProcAddr(\"glVertexAttribP4uiv\"))\n\tif gpVertexAttribP4uiv == nil {\n\t\treturn errors.New(\"glVertexAttribP4uiv\")\n\t}\n\tgpVertexAttribPointer = (C.GPVERTEXATTRIBPOINTER)(getProcAddr(\"glVertexAttribPointer\"))\n\tif gpVertexAttribPointer == nil {\n\t\treturn errors.New(\"glVertexAttribPointer\")\n\t}\n\tgpVertexBindingDivisor = (C.GPVERTEXBINDINGDIVISOR)(getProcAddr(\"glVertexBindingDivisor\"))\n\tgpVertexFormatNV = (C.GPVERTEXFORMATNV)(getProcAddr(\"glVertexFormatNV\"))\n\tgpViewport = (C.GPVIEWPORT)(getProcAddr(\"glViewport\"))\n\tif gpViewport == nil {\n\t\treturn errors.New(\"glViewport\")\n\t}\n\tgpViewportArrayv = (C.GPVIEWPORTARRAYV)(getProcAddr(\"glViewportArrayv\"))\n\tif gpViewportArrayv == nil {\n\t\treturn errors.New(\"glViewportArrayv\")\n\t}\n\tgpViewportIndexedf = (C.GPVIEWPORTINDEXEDF)(getProcAddr(\"glViewportIndexedf\"))\n\tif gpViewportIndexedf == nil {\n\t\treturn errors.New(\"glViewportIndexedf\")\n\t}\n\tgpViewportIndexedfv = (C.GPVIEWPORTINDEXEDFV)(getProcAddr(\"glViewportIndexedfv\"))\n\tif gpViewportIndexedfv == nil {\n\t\treturn errors.New(\"glViewportIndexedfv\")\n\t}\n\tgpViewportPositionWScaleNV = (C.GPVIEWPORTPOSITIONWSCALENV)(getProcAddr(\"glViewportPositionWScaleNV\"))\n\tgpViewportSwizzleNV = (C.GPVIEWPORTSWIZZLENV)(getProcAddr(\"glViewportSwizzleNV\"))\n\tgpWaitSync = (C.GPWAITSYNC)(getProcAddr(\"glWaitSync\"))\n\tif gpWaitSync == nil {\n\t\treturn errors.New(\"glWaitSync\")\n\t}\n\tgpWaitVkSemaphoreNV = (C.GPWAITVKSEMAPHORENV)(getProcAddr(\"glWaitVkSemaphoreNV\"))\n\tgpWeightPathsNV = (C.GPWEIGHTPATHSNV)(getProcAddr(\"glWeightPathsNV\"))\n\tgpWindowRectanglesEXT = (C.GPWINDOWRECTANGLESEXT)(getProcAddr(\"glWindowRectanglesEXT\"))\n\treturn nil\n}", "func DebugMessageCallbackARB(callback unsafe.Pointer, userParam unsafe.Pointer) {\n\tsyscall.Syscall(gpDebugMessageCallbackARB, 2, syscall.NewCallback(callback), uintptr(userParam), 0)\n}", "func InitWithProcAddrFunc(getProcAddr func(name string) unsafe.Pointer) error {\n\tgpAccum = uintptr(getProcAddr(\"glAccum\"))\n\tif gpAccum == 0 {\n\t\treturn errors.New(\"glAccum\")\n\t}\n\tgpAccumxOES = uintptr(getProcAddr(\"glAccumxOES\"))\n\tgpAcquireKeyedMutexWin32EXT = uintptr(getProcAddr(\"glAcquireKeyedMutexWin32EXT\"))\n\tgpActiveProgramEXT = uintptr(getProcAddr(\"glActiveProgramEXT\"))\n\tgpActiveShaderProgram = uintptr(getProcAddr(\"glActiveShaderProgram\"))\n\tgpActiveShaderProgramEXT = uintptr(getProcAddr(\"glActiveShaderProgramEXT\"))\n\tgpActiveStencilFaceEXT = uintptr(getProcAddr(\"glActiveStencilFaceEXT\"))\n\tgpActiveTexture = uintptr(getProcAddr(\"glActiveTexture\"))\n\tif gpActiveTexture == 0 {\n\t\treturn errors.New(\"glActiveTexture\")\n\t}\n\tgpActiveTextureARB = uintptr(getProcAddr(\"glActiveTextureARB\"))\n\tgpActiveVaryingNV = uintptr(getProcAddr(\"glActiveVaryingNV\"))\n\tgpAlphaFragmentOp1ATI = uintptr(getProcAddr(\"glAlphaFragmentOp1ATI\"))\n\tgpAlphaFragmentOp2ATI = uintptr(getProcAddr(\"glAlphaFragmentOp2ATI\"))\n\tgpAlphaFragmentOp3ATI = uintptr(getProcAddr(\"glAlphaFragmentOp3ATI\"))\n\tgpAlphaFunc = uintptr(getProcAddr(\"glAlphaFunc\"))\n\tif gpAlphaFunc == 0 {\n\t\treturn errors.New(\"glAlphaFunc\")\n\t}\n\tgpAlphaFuncxOES = uintptr(getProcAddr(\"glAlphaFuncxOES\"))\n\tgpAlphaToCoverageDitherControlNV = uintptr(getProcAddr(\"glAlphaToCoverageDitherControlNV\"))\n\tgpApplyFramebufferAttachmentCMAAINTEL = uintptr(getProcAddr(\"glApplyFramebufferAttachmentCMAAINTEL\"))\n\tgpApplyTextureEXT = uintptr(getProcAddr(\"glApplyTextureEXT\"))\n\tgpAreProgramsResidentNV = uintptr(getProcAddr(\"glAreProgramsResidentNV\"))\n\tgpAreTexturesResident = uintptr(getProcAddr(\"glAreTexturesResident\"))\n\tif gpAreTexturesResident == 0 {\n\t\treturn errors.New(\"glAreTexturesResident\")\n\t}\n\tgpAreTexturesResidentEXT = uintptr(getProcAddr(\"glAreTexturesResidentEXT\"))\n\tgpArrayElement = uintptr(getProcAddr(\"glArrayElement\"))\n\tif gpArrayElement == 0 {\n\t\treturn errors.New(\"glArrayElement\")\n\t}\n\tgpArrayElementEXT = uintptr(getProcAddr(\"glArrayElementEXT\"))\n\tgpArrayObjectATI = uintptr(getProcAddr(\"glArrayObjectATI\"))\n\tgpAsyncMarkerSGIX = uintptr(getProcAddr(\"glAsyncMarkerSGIX\"))\n\tgpAttachObjectARB = uintptr(getProcAddr(\"glAttachObjectARB\"))\n\tgpAttachShader = uintptr(getProcAddr(\"glAttachShader\"))\n\tif gpAttachShader == 0 {\n\t\treturn errors.New(\"glAttachShader\")\n\t}\n\tgpBegin = uintptr(getProcAddr(\"glBegin\"))\n\tif gpBegin == 0 {\n\t\treturn errors.New(\"glBegin\")\n\t}\n\tgpBeginConditionalRenderNV = uintptr(getProcAddr(\"glBeginConditionalRenderNV\"))\n\tgpBeginConditionalRenderNVX = uintptr(getProcAddr(\"glBeginConditionalRenderNVX\"))\n\tgpBeginFragmentShaderATI = uintptr(getProcAddr(\"glBeginFragmentShaderATI\"))\n\tgpBeginOcclusionQueryNV = uintptr(getProcAddr(\"glBeginOcclusionQueryNV\"))\n\tgpBeginPerfMonitorAMD = uintptr(getProcAddr(\"glBeginPerfMonitorAMD\"))\n\tgpBeginPerfQueryINTEL = uintptr(getProcAddr(\"glBeginPerfQueryINTEL\"))\n\tgpBeginQuery = uintptr(getProcAddr(\"glBeginQuery\"))\n\tif gpBeginQuery == 0 {\n\t\treturn errors.New(\"glBeginQuery\")\n\t}\n\tgpBeginQueryARB = uintptr(getProcAddr(\"glBeginQueryARB\"))\n\tgpBeginQueryIndexed = uintptr(getProcAddr(\"glBeginQueryIndexed\"))\n\tgpBeginTransformFeedbackEXT = uintptr(getProcAddr(\"glBeginTransformFeedbackEXT\"))\n\tgpBeginTransformFeedbackNV = uintptr(getProcAddr(\"glBeginTransformFeedbackNV\"))\n\tgpBeginVertexShaderEXT = uintptr(getProcAddr(\"glBeginVertexShaderEXT\"))\n\tgpBeginVideoCaptureNV = uintptr(getProcAddr(\"glBeginVideoCaptureNV\"))\n\tgpBindAttribLocation = uintptr(getProcAddr(\"glBindAttribLocation\"))\n\tif gpBindAttribLocation == 0 {\n\t\treturn errors.New(\"glBindAttribLocation\")\n\t}\n\tgpBindAttribLocationARB = uintptr(getProcAddr(\"glBindAttribLocationARB\"))\n\tgpBindBuffer = uintptr(getProcAddr(\"glBindBuffer\"))\n\tif gpBindBuffer == 0 {\n\t\treturn errors.New(\"glBindBuffer\")\n\t}\n\tgpBindBufferARB = uintptr(getProcAddr(\"glBindBufferARB\"))\n\tgpBindBufferBase = uintptr(getProcAddr(\"glBindBufferBase\"))\n\tgpBindBufferBaseEXT = uintptr(getProcAddr(\"glBindBufferBaseEXT\"))\n\tgpBindBufferBaseNV = uintptr(getProcAddr(\"glBindBufferBaseNV\"))\n\tgpBindBufferOffsetEXT = uintptr(getProcAddr(\"glBindBufferOffsetEXT\"))\n\tgpBindBufferOffsetNV = uintptr(getProcAddr(\"glBindBufferOffsetNV\"))\n\tgpBindBufferRange = uintptr(getProcAddr(\"glBindBufferRange\"))\n\tgpBindBufferRangeEXT = uintptr(getProcAddr(\"glBindBufferRangeEXT\"))\n\tgpBindBufferRangeNV = uintptr(getProcAddr(\"glBindBufferRangeNV\"))\n\tgpBindBuffersBase = uintptr(getProcAddr(\"glBindBuffersBase\"))\n\tgpBindBuffersRange = uintptr(getProcAddr(\"glBindBuffersRange\"))\n\tgpBindFragDataLocationEXT = uintptr(getProcAddr(\"glBindFragDataLocationEXT\"))\n\tgpBindFragDataLocationIndexed = uintptr(getProcAddr(\"glBindFragDataLocationIndexed\"))\n\tgpBindFragmentShaderATI = uintptr(getProcAddr(\"glBindFragmentShaderATI\"))\n\tgpBindFramebuffer = uintptr(getProcAddr(\"glBindFramebuffer\"))\n\tgpBindFramebufferEXT = uintptr(getProcAddr(\"glBindFramebufferEXT\"))\n\tgpBindImageTexture = uintptr(getProcAddr(\"glBindImageTexture\"))\n\tgpBindImageTextureEXT = uintptr(getProcAddr(\"glBindImageTextureEXT\"))\n\tgpBindImageTextures = uintptr(getProcAddr(\"glBindImageTextures\"))\n\tgpBindLightParameterEXT = uintptr(getProcAddr(\"glBindLightParameterEXT\"))\n\tgpBindMaterialParameterEXT = uintptr(getProcAddr(\"glBindMaterialParameterEXT\"))\n\tgpBindMultiTextureEXT = uintptr(getProcAddr(\"glBindMultiTextureEXT\"))\n\tgpBindParameterEXT = uintptr(getProcAddr(\"glBindParameterEXT\"))\n\tgpBindProgramARB = uintptr(getProcAddr(\"glBindProgramARB\"))\n\tgpBindProgramNV = uintptr(getProcAddr(\"glBindProgramNV\"))\n\tgpBindProgramPipeline = uintptr(getProcAddr(\"glBindProgramPipeline\"))\n\tgpBindProgramPipelineEXT = uintptr(getProcAddr(\"glBindProgramPipelineEXT\"))\n\tgpBindRenderbuffer = uintptr(getProcAddr(\"glBindRenderbuffer\"))\n\tgpBindRenderbufferEXT = uintptr(getProcAddr(\"glBindRenderbufferEXT\"))\n\tgpBindSampler = uintptr(getProcAddr(\"glBindSampler\"))\n\tgpBindSamplers = uintptr(getProcAddr(\"glBindSamplers\"))\n\tgpBindTexGenParameterEXT = uintptr(getProcAddr(\"glBindTexGenParameterEXT\"))\n\tgpBindTexture = uintptr(getProcAddr(\"glBindTexture\"))\n\tif gpBindTexture == 0 {\n\t\treturn errors.New(\"glBindTexture\")\n\t}\n\tgpBindTextureEXT = uintptr(getProcAddr(\"glBindTextureEXT\"))\n\tgpBindTextureUnit = uintptr(getProcAddr(\"glBindTextureUnit\"))\n\tgpBindTextureUnitParameterEXT = uintptr(getProcAddr(\"glBindTextureUnitParameterEXT\"))\n\tgpBindTextures = uintptr(getProcAddr(\"glBindTextures\"))\n\tgpBindTransformFeedback = uintptr(getProcAddr(\"glBindTransformFeedback\"))\n\tgpBindTransformFeedbackNV = uintptr(getProcAddr(\"glBindTransformFeedbackNV\"))\n\tgpBindVertexArray = uintptr(getProcAddr(\"glBindVertexArray\"))\n\tgpBindVertexArrayAPPLE = uintptr(getProcAddr(\"glBindVertexArrayAPPLE\"))\n\tgpBindVertexBuffer = uintptr(getProcAddr(\"glBindVertexBuffer\"))\n\tgpBindVertexBuffers = uintptr(getProcAddr(\"glBindVertexBuffers\"))\n\tgpBindVertexShaderEXT = uintptr(getProcAddr(\"glBindVertexShaderEXT\"))\n\tgpBindVideoCaptureStreamBufferNV = uintptr(getProcAddr(\"glBindVideoCaptureStreamBufferNV\"))\n\tgpBindVideoCaptureStreamTextureNV = uintptr(getProcAddr(\"glBindVideoCaptureStreamTextureNV\"))\n\tgpBinormal3bEXT = uintptr(getProcAddr(\"glBinormal3bEXT\"))\n\tgpBinormal3bvEXT = uintptr(getProcAddr(\"glBinormal3bvEXT\"))\n\tgpBinormal3dEXT = uintptr(getProcAddr(\"glBinormal3dEXT\"))\n\tgpBinormal3dvEXT = uintptr(getProcAddr(\"glBinormal3dvEXT\"))\n\tgpBinormal3fEXT = uintptr(getProcAddr(\"glBinormal3fEXT\"))\n\tgpBinormal3fvEXT = uintptr(getProcAddr(\"glBinormal3fvEXT\"))\n\tgpBinormal3iEXT = uintptr(getProcAddr(\"glBinormal3iEXT\"))\n\tgpBinormal3ivEXT = uintptr(getProcAddr(\"glBinormal3ivEXT\"))\n\tgpBinormal3sEXT = uintptr(getProcAddr(\"glBinormal3sEXT\"))\n\tgpBinormal3svEXT = uintptr(getProcAddr(\"glBinormal3svEXT\"))\n\tgpBinormalPointerEXT = uintptr(getProcAddr(\"glBinormalPointerEXT\"))\n\tgpBitmap = uintptr(getProcAddr(\"glBitmap\"))\n\tif gpBitmap == 0 {\n\t\treturn errors.New(\"glBitmap\")\n\t}\n\tgpBitmapxOES = uintptr(getProcAddr(\"glBitmapxOES\"))\n\tgpBlendBarrierKHR = uintptr(getProcAddr(\"glBlendBarrierKHR\"))\n\tgpBlendBarrierNV = uintptr(getProcAddr(\"glBlendBarrierNV\"))\n\tgpBlendColor = uintptr(getProcAddr(\"glBlendColor\"))\n\tif gpBlendColor == 0 {\n\t\treturn errors.New(\"glBlendColor\")\n\t}\n\tgpBlendColorEXT = uintptr(getProcAddr(\"glBlendColorEXT\"))\n\tgpBlendColorxOES = uintptr(getProcAddr(\"glBlendColorxOES\"))\n\tgpBlendEquation = uintptr(getProcAddr(\"glBlendEquation\"))\n\tif gpBlendEquation == 0 {\n\t\treturn errors.New(\"glBlendEquation\")\n\t}\n\tgpBlendEquationEXT = uintptr(getProcAddr(\"glBlendEquationEXT\"))\n\tgpBlendEquationIndexedAMD = uintptr(getProcAddr(\"glBlendEquationIndexedAMD\"))\n\tgpBlendEquationSeparate = uintptr(getProcAddr(\"glBlendEquationSeparate\"))\n\tif gpBlendEquationSeparate == 0 {\n\t\treturn errors.New(\"glBlendEquationSeparate\")\n\t}\n\tgpBlendEquationSeparateEXT = uintptr(getProcAddr(\"glBlendEquationSeparateEXT\"))\n\tgpBlendEquationSeparateIndexedAMD = uintptr(getProcAddr(\"glBlendEquationSeparateIndexedAMD\"))\n\tgpBlendEquationSeparateiARB = uintptr(getProcAddr(\"glBlendEquationSeparateiARB\"))\n\tgpBlendEquationiARB = uintptr(getProcAddr(\"glBlendEquationiARB\"))\n\tgpBlendFunc = uintptr(getProcAddr(\"glBlendFunc\"))\n\tif gpBlendFunc == 0 {\n\t\treturn errors.New(\"glBlendFunc\")\n\t}\n\tgpBlendFuncIndexedAMD = uintptr(getProcAddr(\"glBlendFuncIndexedAMD\"))\n\tgpBlendFuncSeparate = uintptr(getProcAddr(\"glBlendFuncSeparate\"))\n\tif gpBlendFuncSeparate == 0 {\n\t\treturn errors.New(\"glBlendFuncSeparate\")\n\t}\n\tgpBlendFuncSeparateEXT = uintptr(getProcAddr(\"glBlendFuncSeparateEXT\"))\n\tgpBlendFuncSeparateINGR = uintptr(getProcAddr(\"glBlendFuncSeparateINGR\"))\n\tgpBlendFuncSeparateIndexedAMD = uintptr(getProcAddr(\"glBlendFuncSeparateIndexedAMD\"))\n\tgpBlendFuncSeparateiARB = uintptr(getProcAddr(\"glBlendFuncSeparateiARB\"))\n\tgpBlendFunciARB = uintptr(getProcAddr(\"glBlendFunciARB\"))\n\tgpBlendParameteriNV = uintptr(getProcAddr(\"glBlendParameteriNV\"))\n\tgpBlitFramebuffer = uintptr(getProcAddr(\"glBlitFramebuffer\"))\n\tgpBlitFramebufferEXT = uintptr(getProcAddr(\"glBlitFramebufferEXT\"))\n\tgpBlitNamedFramebuffer = uintptr(getProcAddr(\"glBlitNamedFramebuffer\"))\n\tgpBufferAddressRangeNV = uintptr(getProcAddr(\"glBufferAddressRangeNV\"))\n\tgpBufferData = uintptr(getProcAddr(\"glBufferData\"))\n\tif gpBufferData == 0 {\n\t\treturn errors.New(\"glBufferData\")\n\t}\n\tgpBufferDataARB = uintptr(getProcAddr(\"glBufferDataARB\"))\n\tgpBufferPageCommitmentARB = uintptr(getProcAddr(\"glBufferPageCommitmentARB\"))\n\tgpBufferParameteriAPPLE = uintptr(getProcAddr(\"glBufferParameteriAPPLE\"))\n\tgpBufferStorage = uintptr(getProcAddr(\"glBufferStorage\"))\n\tgpBufferStorageExternalEXT = uintptr(getProcAddr(\"glBufferStorageExternalEXT\"))\n\tgpBufferStorageMemEXT = uintptr(getProcAddr(\"glBufferStorageMemEXT\"))\n\tgpBufferSubData = uintptr(getProcAddr(\"glBufferSubData\"))\n\tif gpBufferSubData == 0 {\n\t\treturn errors.New(\"glBufferSubData\")\n\t}\n\tgpBufferSubDataARB = uintptr(getProcAddr(\"glBufferSubDataARB\"))\n\tgpCallCommandListNV = uintptr(getProcAddr(\"glCallCommandListNV\"))\n\tgpCallList = uintptr(getProcAddr(\"glCallList\"))\n\tif gpCallList == 0 {\n\t\treturn errors.New(\"glCallList\")\n\t}\n\tgpCallLists = uintptr(getProcAddr(\"glCallLists\"))\n\tif gpCallLists == 0 {\n\t\treturn errors.New(\"glCallLists\")\n\t}\n\tgpCheckFramebufferStatus = uintptr(getProcAddr(\"glCheckFramebufferStatus\"))\n\tgpCheckFramebufferStatusEXT = uintptr(getProcAddr(\"glCheckFramebufferStatusEXT\"))\n\tgpCheckNamedFramebufferStatus = uintptr(getProcAddr(\"glCheckNamedFramebufferStatus\"))\n\tgpCheckNamedFramebufferStatusEXT = uintptr(getProcAddr(\"glCheckNamedFramebufferStatusEXT\"))\n\tgpClampColorARB = uintptr(getProcAddr(\"glClampColorARB\"))\n\tgpClear = uintptr(getProcAddr(\"glClear\"))\n\tif gpClear == 0 {\n\t\treturn errors.New(\"glClear\")\n\t}\n\tgpClearAccum = uintptr(getProcAddr(\"glClearAccum\"))\n\tif gpClearAccum == 0 {\n\t\treturn errors.New(\"glClearAccum\")\n\t}\n\tgpClearAccumxOES = uintptr(getProcAddr(\"glClearAccumxOES\"))\n\tgpClearBufferData = uintptr(getProcAddr(\"glClearBufferData\"))\n\tgpClearBufferSubData = uintptr(getProcAddr(\"glClearBufferSubData\"))\n\tgpClearColor = uintptr(getProcAddr(\"glClearColor\"))\n\tif gpClearColor == 0 {\n\t\treturn errors.New(\"glClearColor\")\n\t}\n\tgpClearColorIiEXT = uintptr(getProcAddr(\"glClearColorIiEXT\"))\n\tgpClearColorIuiEXT = uintptr(getProcAddr(\"glClearColorIuiEXT\"))\n\tgpClearColorxOES = uintptr(getProcAddr(\"glClearColorxOES\"))\n\tgpClearDepth = uintptr(getProcAddr(\"glClearDepth\"))\n\tif gpClearDepth == 0 {\n\t\treturn errors.New(\"glClearDepth\")\n\t}\n\tgpClearDepthdNV = uintptr(getProcAddr(\"glClearDepthdNV\"))\n\tgpClearDepthf = uintptr(getProcAddr(\"glClearDepthf\"))\n\tgpClearDepthfOES = uintptr(getProcAddr(\"glClearDepthfOES\"))\n\tgpClearDepthxOES = uintptr(getProcAddr(\"glClearDepthxOES\"))\n\tgpClearIndex = uintptr(getProcAddr(\"glClearIndex\"))\n\tif gpClearIndex == 0 {\n\t\treturn errors.New(\"glClearIndex\")\n\t}\n\tgpClearNamedBufferData = uintptr(getProcAddr(\"glClearNamedBufferData\"))\n\tgpClearNamedBufferDataEXT = uintptr(getProcAddr(\"glClearNamedBufferDataEXT\"))\n\tgpClearNamedBufferSubData = uintptr(getProcAddr(\"glClearNamedBufferSubData\"))\n\tgpClearNamedBufferSubDataEXT = uintptr(getProcAddr(\"glClearNamedBufferSubDataEXT\"))\n\tgpClearNamedFramebufferfi = uintptr(getProcAddr(\"glClearNamedFramebufferfi\"))\n\tgpClearNamedFramebufferfv = uintptr(getProcAddr(\"glClearNamedFramebufferfv\"))\n\tgpClearNamedFramebufferiv = uintptr(getProcAddr(\"glClearNamedFramebufferiv\"))\n\tgpClearNamedFramebufferuiv = uintptr(getProcAddr(\"glClearNamedFramebufferuiv\"))\n\tgpClearStencil = uintptr(getProcAddr(\"glClearStencil\"))\n\tif gpClearStencil == 0 {\n\t\treturn errors.New(\"glClearStencil\")\n\t}\n\tgpClearTexImage = uintptr(getProcAddr(\"glClearTexImage\"))\n\tgpClearTexSubImage = uintptr(getProcAddr(\"glClearTexSubImage\"))\n\tgpClientActiveTexture = uintptr(getProcAddr(\"glClientActiveTexture\"))\n\tif gpClientActiveTexture == 0 {\n\t\treturn errors.New(\"glClientActiveTexture\")\n\t}\n\tgpClientActiveTextureARB = uintptr(getProcAddr(\"glClientActiveTextureARB\"))\n\tgpClientActiveVertexStreamATI = uintptr(getProcAddr(\"glClientActiveVertexStreamATI\"))\n\tgpClientAttribDefaultEXT = uintptr(getProcAddr(\"glClientAttribDefaultEXT\"))\n\tgpClientWaitSync = uintptr(getProcAddr(\"glClientWaitSync\"))\n\tgpClipControl = uintptr(getProcAddr(\"glClipControl\"))\n\tgpClipPlane = uintptr(getProcAddr(\"glClipPlane\"))\n\tif gpClipPlane == 0 {\n\t\treturn errors.New(\"glClipPlane\")\n\t}\n\tgpClipPlanefOES = uintptr(getProcAddr(\"glClipPlanefOES\"))\n\tgpClipPlanexOES = uintptr(getProcAddr(\"glClipPlanexOES\"))\n\tgpColor3b = uintptr(getProcAddr(\"glColor3b\"))\n\tif gpColor3b == 0 {\n\t\treturn errors.New(\"glColor3b\")\n\t}\n\tgpColor3bv = uintptr(getProcAddr(\"glColor3bv\"))\n\tif gpColor3bv == 0 {\n\t\treturn errors.New(\"glColor3bv\")\n\t}\n\tgpColor3d = uintptr(getProcAddr(\"glColor3d\"))\n\tif gpColor3d == 0 {\n\t\treturn errors.New(\"glColor3d\")\n\t}\n\tgpColor3dv = uintptr(getProcAddr(\"glColor3dv\"))\n\tif gpColor3dv == 0 {\n\t\treturn errors.New(\"glColor3dv\")\n\t}\n\tgpColor3f = uintptr(getProcAddr(\"glColor3f\"))\n\tif gpColor3f == 0 {\n\t\treturn errors.New(\"glColor3f\")\n\t}\n\tgpColor3fVertex3fSUN = uintptr(getProcAddr(\"glColor3fVertex3fSUN\"))\n\tgpColor3fVertex3fvSUN = uintptr(getProcAddr(\"glColor3fVertex3fvSUN\"))\n\tgpColor3fv = uintptr(getProcAddr(\"glColor3fv\"))\n\tif gpColor3fv == 0 {\n\t\treturn errors.New(\"glColor3fv\")\n\t}\n\tgpColor3hNV = uintptr(getProcAddr(\"glColor3hNV\"))\n\tgpColor3hvNV = uintptr(getProcAddr(\"glColor3hvNV\"))\n\tgpColor3i = uintptr(getProcAddr(\"glColor3i\"))\n\tif gpColor3i == 0 {\n\t\treturn errors.New(\"glColor3i\")\n\t}\n\tgpColor3iv = uintptr(getProcAddr(\"glColor3iv\"))\n\tif gpColor3iv == 0 {\n\t\treturn errors.New(\"glColor3iv\")\n\t}\n\tgpColor3s = uintptr(getProcAddr(\"glColor3s\"))\n\tif gpColor3s == 0 {\n\t\treturn errors.New(\"glColor3s\")\n\t}\n\tgpColor3sv = uintptr(getProcAddr(\"glColor3sv\"))\n\tif gpColor3sv == 0 {\n\t\treturn errors.New(\"glColor3sv\")\n\t}\n\tgpColor3ub = uintptr(getProcAddr(\"glColor3ub\"))\n\tif gpColor3ub == 0 {\n\t\treturn errors.New(\"glColor3ub\")\n\t}\n\tgpColor3ubv = uintptr(getProcAddr(\"glColor3ubv\"))\n\tif gpColor3ubv == 0 {\n\t\treturn errors.New(\"glColor3ubv\")\n\t}\n\tgpColor3ui = uintptr(getProcAddr(\"glColor3ui\"))\n\tif gpColor3ui == 0 {\n\t\treturn errors.New(\"glColor3ui\")\n\t}\n\tgpColor3uiv = uintptr(getProcAddr(\"glColor3uiv\"))\n\tif gpColor3uiv == 0 {\n\t\treturn errors.New(\"glColor3uiv\")\n\t}\n\tgpColor3us = uintptr(getProcAddr(\"glColor3us\"))\n\tif gpColor3us == 0 {\n\t\treturn errors.New(\"glColor3us\")\n\t}\n\tgpColor3usv = uintptr(getProcAddr(\"glColor3usv\"))\n\tif gpColor3usv == 0 {\n\t\treturn errors.New(\"glColor3usv\")\n\t}\n\tgpColor3xOES = uintptr(getProcAddr(\"glColor3xOES\"))\n\tgpColor3xvOES = uintptr(getProcAddr(\"glColor3xvOES\"))\n\tgpColor4b = uintptr(getProcAddr(\"glColor4b\"))\n\tif gpColor4b == 0 {\n\t\treturn errors.New(\"glColor4b\")\n\t}\n\tgpColor4bv = uintptr(getProcAddr(\"glColor4bv\"))\n\tif gpColor4bv == 0 {\n\t\treturn errors.New(\"glColor4bv\")\n\t}\n\tgpColor4d = uintptr(getProcAddr(\"glColor4d\"))\n\tif gpColor4d == 0 {\n\t\treturn errors.New(\"glColor4d\")\n\t}\n\tgpColor4dv = uintptr(getProcAddr(\"glColor4dv\"))\n\tif gpColor4dv == 0 {\n\t\treturn errors.New(\"glColor4dv\")\n\t}\n\tgpColor4f = uintptr(getProcAddr(\"glColor4f\"))\n\tif gpColor4f == 0 {\n\t\treturn errors.New(\"glColor4f\")\n\t}\n\tgpColor4fNormal3fVertex3fSUN = uintptr(getProcAddr(\"glColor4fNormal3fVertex3fSUN\"))\n\tgpColor4fNormal3fVertex3fvSUN = uintptr(getProcAddr(\"glColor4fNormal3fVertex3fvSUN\"))\n\tgpColor4fv = uintptr(getProcAddr(\"glColor4fv\"))\n\tif gpColor4fv == 0 {\n\t\treturn errors.New(\"glColor4fv\")\n\t}\n\tgpColor4hNV = uintptr(getProcAddr(\"glColor4hNV\"))\n\tgpColor4hvNV = uintptr(getProcAddr(\"glColor4hvNV\"))\n\tgpColor4i = uintptr(getProcAddr(\"glColor4i\"))\n\tif gpColor4i == 0 {\n\t\treturn errors.New(\"glColor4i\")\n\t}\n\tgpColor4iv = uintptr(getProcAddr(\"glColor4iv\"))\n\tif gpColor4iv == 0 {\n\t\treturn errors.New(\"glColor4iv\")\n\t}\n\tgpColor4s = uintptr(getProcAddr(\"glColor4s\"))\n\tif gpColor4s == 0 {\n\t\treturn errors.New(\"glColor4s\")\n\t}\n\tgpColor4sv = uintptr(getProcAddr(\"glColor4sv\"))\n\tif gpColor4sv == 0 {\n\t\treturn errors.New(\"glColor4sv\")\n\t}\n\tgpColor4ub = uintptr(getProcAddr(\"glColor4ub\"))\n\tif gpColor4ub == 0 {\n\t\treturn errors.New(\"glColor4ub\")\n\t}\n\tgpColor4ubVertex2fSUN = uintptr(getProcAddr(\"glColor4ubVertex2fSUN\"))\n\tgpColor4ubVertex2fvSUN = uintptr(getProcAddr(\"glColor4ubVertex2fvSUN\"))\n\tgpColor4ubVertex3fSUN = uintptr(getProcAddr(\"glColor4ubVertex3fSUN\"))\n\tgpColor4ubVertex3fvSUN = uintptr(getProcAddr(\"glColor4ubVertex3fvSUN\"))\n\tgpColor4ubv = uintptr(getProcAddr(\"glColor4ubv\"))\n\tif gpColor4ubv == 0 {\n\t\treturn errors.New(\"glColor4ubv\")\n\t}\n\tgpColor4ui = uintptr(getProcAddr(\"glColor4ui\"))\n\tif gpColor4ui == 0 {\n\t\treturn errors.New(\"glColor4ui\")\n\t}\n\tgpColor4uiv = uintptr(getProcAddr(\"glColor4uiv\"))\n\tif gpColor4uiv == 0 {\n\t\treturn errors.New(\"glColor4uiv\")\n\t}\n\tgpColor4us = uintptr(getProcAddr(\"glColor4us\"))\n\tif gpColor4us == 0 {\n\t\treturn errors.New(\"glColor4us\")\n\t}\n\tgpColor4usv = uintptr(getProcAddr(\"glColor4usv\"))\n\tif gpColor4usv == 0 {\n\t\treturn errors.New(\"glColor4usv\")\n\t}\n\tgpColor4xOES = uintptr(getProcAddr(\"glColor4xOES\"))\n\tgpColor4xvOES = uintptr(getProcAddr(\"glColor4xvOES\"))\n\tgpColorFormatNV = uintptr(getProcAddr(\"glColorFormatNV\"))\n\tgpColorFragmentOp1ATI = uintptr(getProcAddr(\"glColorFragmentOp1ATI\"))\n\tgpColorFragmentOp2ATI = uintptr(getProcAddr(\"glColorFragmentOp2ATI\"))\n\tgpColorFragmentOp3ATI = uintptr(getProcAddr(\"glColorFragmentOp3ATI\"))\n\tgpColorMask = uintptr(getProcAddr(\"glColorMask\"))\n\tif gpColorMask == 0 {\n\t\treturn errors.New(\"glColorMask\")\n\t}\n\tgpColorMaskIndexedEXT = uintptr(getProcAddr(\"glColorMaskIndexedEXT\"))\n\tgpColorMaterial = uintptr(getProcAddr(\"glColorMaterial\"))\n\tif gpColorMaterial == 0 {\n\t\treturn errors.New(\"glColorMaterial\")\n\t}\n\tgpColorPointer = uintptr(getProcAddr(\"glColorPointer\"))\n\tif gpColorPointer == 0 {\n\t\treturn errors.New(\"glColorPointer\")\n\t}\n\tgpColorPointerEXT = uintptr(getProcAddr(\"glColorPointerEXT\"))\n\tgpColorPointerListIBM = uintptr(getProcAddr(\"glColorPointerListIBM\"))\n\tgpColorPointervINTEL = uintptr(getProcAddr(\"glColorPointervINTEL\"))\n\tgpColorSubTableEXT = uintptr(getProcAddr(\"glColorSubTableEXT\"))\n\tgpColorTableEXT = uintptr(getProcAddr(\"glColorTableEXT\"))\n\tgpColorTableParameterfvSGI = uintptr(getProcAddr(\"glColorTableParameterfvSGI\"))\n\tgpColorTableParameterivSGI = uintptr(getProcAddr(\"glColorTableParameterivSGI\"))\n\tgpColorTableSGI = uintptr(getProcAddr(\"glColorTableSGI\"))\n\tgpCombinerInputNV = uintptr(getProcAddr(\"glCombinerInputNV\"))\n\tgpCombinerOutputNV = uintptr(getProcAddr(\"glCombinerOutputNV\"))\n\tgpCombinerParameterfNV = uintptr(getProcAddr(\"glCombinerParameterfNV\"))\n\tgpCombinerParameterfvNV = uintptr(getProcAddr(\"glCombinerParameterfvNV\"))\n\tgpCombinerParameteriNV = uintptr(getProcAddr(\"glCombinerParameteriNV\"))\n\tgpCombinerParameterivNV = uintptr(getProcAddr(\"glCombinerParameterivNV\"))\n\tgpCombinerStageParameterfvNV = uintptr(getProcAddr(\"glCombinerStageParameterfvNV\"))\n\tgpCommandListSegmentsNV = uintptr(getProcAddr(\"glCommandListSegmentsNV\"))\n\tgpCompileCommandListNV = uintptr(getProcAddr(\"glCompileCommandListNV\"))\n\tgpCompileShader = uintptr(getProcAddr(\"glCompileShader\"))\n\tif gpCompileShader == 0 {\n\t\treturn errors.New(\"glCompileShader\")\n\t}\n\tgpCompileShaderARB = uintptr(getProcAddr(\"glCompileShaderARB\"))\n\tgpCompileShaderIncludeARB = uintptr(getProcAddr(\"glCompileShaderIncludeARB\"))\n\tgpCompressedMultiTexImage1DEXT = uintptr(getProcAddr(\"glCompressedMultiTexImage1DEXT\"))\n\tgpCompressedMultiTexImage2DEXT = uintptr(getProcAddr(\"glCompressedMultiTexImage2DEXT\"))\n\tgpCompressedMultiTexImage3DEXT = uintptr(getProcAddr(\"glCompressedMultiTexImage3DEXT\"))\n\tgpCompressedMultiTexSubImage1DEXT = uintptr(getProcAddr(\"glCompressedMultiTexSubImage1DEXT\"))\n\tgpCompressedMultiTexSubImage2DEXT = uintptr(getProcAddr(\"glCompressedMultiTexSubImage2DEXT\"))\n\tgpCompressedMultiTexSubImage3DEXT = uintptr(getProcAddr(\"glCompressedMultiTexSubImage3DEXT\"))\n\tgpCompressedTexImage1D = uintptr(getProcAddr(\"glCompressedTexImage1D\"))\n\tif gpCompressedTexImage1D == 0 {\n\t\treturn errors.New(\"glCompressedTexImage1D\")\n\t}\n\tgpCompressedTexImage1DARB = uintptr(getProcAddr(\"glCompressedTexImage1DARB\"))\n\tgpCompressedTexImage2D = uintptr(getProcAddr(\"glCompressedTexImage2D\"))\n\tif gpCompressedTexImage2D == 0 {\n\t\treturn errors.New(\"glCompressedTexImage2D\")\n\t}\n\tgpCompressedTexImage2DARB = uintptr(getProcAddr(\"glCompressedTexImage2DARB\"))\n\tgpCompressedTexImage3D = uintptr(getProcAddr(\"glCompressedTexImage3D\"))\n\tif gpCompressedTexImage3D == 0 {\n\t\treturn errors.New(\"glCompressedTexImage3D\")\n\t}\n\tgpCompressedTexImage3DARB = uintptr(getProcAddr(\"glCompressedTexImage3DARB\"))\n\tgpCompressedTexSubImage1D = uintptr(getProcAddr(\"glCompressedTexSubImage1D\"))\n\tif gpCompressedTexSubImage1D == 0 {\n\t\treturn errors.New(\"glCompressedTexSubImage1D\")\n\t}\n\tgpCompressedTexSubImage1DARB = uintptr(getProcAddr(\"glCompressedTexSubImage1DARB\"))\n\tgpCompressedTexSubImage2D = uintptr(getProcAddr(\"glCompressedTexSubImage2D\"))\n\tif gpCompressedTexSubImage2D == 0 {\n\t\treturn errors.New(\"glCompressedTexSubImage2D\")\n\t}\n\tgpCompressedTexSubImage2DARB = uintptr(getProcAddr(\"glCompressedTexSubImage2DARB\"))\n\tgpCompressedTexSubImage3D = uintptr(getProcAddr(\"glCompressedTexSubImage3D\"))\n\tif gpCompressedTexSubImage3D == 0 {\n\t\treturn errors.New(\"glCompressedTexSubImage3D\")\n\t}\n\tgpCompressedTexSubImage3DARB = uintptr(getProcAddr(\"glCompressedTexSubImage3DARB\"))\n\tgpCompressedTextureImage1DEXT = uintptr(getProcAddr(\"glCompressedTextureImage1DEXT\"))\n\tgpCompressedTextureImage2DEXT = uintptr(getProcAddr(\"glCompressedTextureImage2DEXT\"))\n\tgpCompressedTextureImage3DEXT = uintptr(getProcAddr(\"glCompressedTextureImage3DEXT\"))\n\tgpCompressedTextureSubImage1D = uintptr(getProcAddr(\"glCompressedTextureSubImage1D\"))\n\tgpCompressedTextureSubImage1DEXT = uintptr(getProcAddr(\"glCompressedTextureSubImage1DEXT\"))\n\tgpCompressedTextureSubImage2D = uintptr(getProcAddr(\"glCompressedTextureSubImage2D\"))\n\tgpCompressedTextureSubImage2DEXT = uintptr(getProcAddr(\"glCompressedTextureSubImage2DEXT\"))\n\tgpCompressedTextureSubImage3D = uintptr(getProcAddr(\"glCompressedTextureSubImage3D\"))\n\tgpCompressedTextureSubImage3DEXT = uintptr(getProcAddr(\"glCompressedTextureSubImage3DEXT\"))\n\tgpConservativeRasterParameterfNV = uintptr(getProcAddr(\"glConservativeRasterParameterfNV\"))\n\tgpConservativeRasterParameteriNV = uintptr(getProcAddr(\"glConservativeRasterParameteriNV\"))\n\tgpConvolutionFilter1DEXT = uintptr(getProcAddr(\"glConvolutionFilter1DEXT\"))\n\tgpConvolutionFilter2DEXT = uintptr(getProcAddr(\"glConvolutionFilter2DEXT\"))\n\tgpConvolutionParameterfEXT = uintptr(getProcAddr(\"glConvolutionParameterfEXT\"))\n\tgpConvolutionParameterfvEXT = uintptr(getProcAddr(\"glConvolutionParameterfvEXT\"))\n\tgpConvolutionParameteriEXT = uintptr(getProcAddr(\"glConvolutionParameteriEXT\"))\n\tgpConvolutionParameterivEXT = uintptr(getProcAddr(\"glConvolutionParameterivEXT\"))\n\tgpConvolutionParameterxOES = uintptr(getProcAddr(\"glConvolutionParameterxOES\"))\n\tgpConvolutionParameterxvOES = uintptr(getProcAddr(\"glConvolutionParameterxvOES\"))\n\tgpCopyBufferSubData = uintptr(getProcAddr(\"glCopyBufferSubData\"))\n\tgpCopyColorSubTableEXT = uintptr(getProcAddr(\"glCopyColorSubTableEXT\"))\n\tgpCopyColorTableSGI = uintptr(getProcAddr(\"glCopyColorTableSGI\"))\n\tgpCopyConvolutionFilter1DEXT = uintptr(getProcAddr(\"glCopyConvolutionFilter1DEXT\"))\n\tgpCopyConvolutionFilter2DEXT = uintptr(getProcAddr(\"glCopyConvolutionFilter2DEXT\"))\n\tgpCopyImageSubData = uintptr(getProcAddr(\"glCopyImageSubData\"))\n\tgpCopyImageSubDataNV = uintptr(getProcAddr(\"glCopyImageSubDataNV\"))\n\tgpCopyMultiTexImage1DEXT = uintptr(getProcAddr(\"glCopyMultiTexImage1DEXT\"))\n\tgpCopyMultiTexImage2DEXT = uintptr(getProcAddr(\"glCopyMultiTexImage2DEXT\"))\n\tgpCopyMultiTexSubImage1DEXT = uintptr(getProcAddr(\"glCopyMultiTexSubImage1DEXT\"))\n\tgpCopyMultiTexSubImage2DEXT = uintptr(getProcAddr(\"glCopyMultiTexSubImage2DEXT\"))\n\tgpCopyMultiTexSubImage3DEXT = uintptr(getProcAddr(\"glCopyMultiTexSubImage3DEXT\"))\n\tgpCopyNamedBufferSubData = uintptr(getProcAddr(\"glCopyNamedBufferSubData\"))\n\tgpCopyPathNV = uintptr(getProcAddr(\"glCopyPathNV\"))\n\tgpCopyPixels = uintptr(getProcAddr(\"glCopyPixels\"))\n\tif gpCopyPixels == 0 {\n\t\treturn errors.New(\"glCopyPixels\")\n\t}\n\tgpCopyTexImage1D = uintptr(getProcAddr(\"glCopyTexImage1D\"))\n\tif gpCopyTexImage1D == 0 {\n\t\treturn errors.New(\"glCopyTexImage1D\")\n\t}\n\tgpCopyTexImage1DEXT = uintptr(getProcAddr(\"glCopyTexImage1DEXT\"))\n\tgpCopyTexImage2D = uintptr(getProcAddr(\"glCopyTexImage2D\"))\n\tif gpCopyTexImage2D == 0 {\n\t\treturn errors.New(\"glCopyTexImage2D\")\n\t}\n\tgpCopyTexImage2DEXT = uintptr(getProcAddr(\"glCopyTexImage2DEXT\"))\n\tgpCopyTexSubImage1D = uintptr(getProcAddr(\"glCopyTexSubImage1D\"))\n\tif gpCopyTexSubImage1D == 0 {\n\t\treturn errors.New(\"glCopyTexSubImage1D\")\n\t}\n\tgpCopyTexSubImage1DEXT = uintptr(getProcAddr(\"glCopyTexSubImage1DEXT\"))\n\tgpCopyTexSubImage2D = uintptr(getProcAddr(\"glCopyTexSubImage2D\"))\n\tif gpCopyTexSubImage2D == 0 {\n\t\treturn errors.New(\"glCopyTexSubImage2D\")\n\t}\n\tgpCopyTexSubImage2DEXT = uintptr(getProcAddr(\"glCopyTexSubImage2DEXT\"))\n\tgpCopyTexSubImage3D = uintptr(getProcAddr(\"glCopyTexSubImage3D\"))\n\tif gpCopyTexSubImage3D == 0 {\n\t\treturn errors.New(\"glCopyTexSubImage3D\")\n\t}\n\tgpCopyTexSubImage3DEXT = uintptr(getProcAddr(\"glCopyTexSubImage3DEXT\"))\n\tgpCopyTextureImage1DEXT = uintptr(getProcAddr(\"glCopyTextureImage1DEXT\"))\n\tgpCopyTextureImage2DEXT = uintptr(getProcAddr(\"glCopyTextureImage2DEXT\"))\n\tgpCopyTextureSubImage1D = uintptr(getProcAddr(\"glCopyTextureSubImage1D\"))\n\tgpCopyTextureSubImage1DEXT = uintptr(getProcAddr(\"glCopyTextureSubImage1DEXT\"))\n\tgpCopyTextureSubImage2D = uintptr(getProcAddr(\"glCopyTextureSubImage2D\"))\n\tgpCopyTextureSubImage2DEXT = uintptr(getProcAddr(\"glCopyTextureSubImage2DEXT\"))\n\tgpCopyTextureSubImage3D = uintptr(getProcAddr(\"glCopyTextureSubImage3D\"))\n\tgpCopyTextureSubImage3DEXT = uintptr(getProcAddr(\"glCopyTextureSubImage3DEXT\"))\n\tgpCoverFillPathInstancedNV = uintptr(getProcAddr(\"glCoverFillPathInstancedNV\"))\n\tgpCoverFillPathNV = uintptr(getProcAddr(\"glCoverFillPathNV\"))\n\tgpCoverStrokePathInstancedNV = uintptr(getProcAddr(\"glCoverStrokePathInstancedNV\"))\n\tgpCoverStrokePathNV = uintptr(getProcAddr(\"glCoverStrokePathNV\"))\n\tgpCoverageModulationNV = uintptr(getProcAddr(\"glCoverageModulationNV\"))\n\tgpCoverageModulationTableNV = uintptr(getProcAddr(\"glCoverageModulationTableNV\"))\n\tgpCreateBuffers = uintptr(getProcAddr(\"glCreateBuffers\"))\n\tgpCreateCommandListsNV = uintptr(getProcAddr(\"glCreateCommandListsNV\"))\n\tgpCreateFramebuffers = uintptr(getProcAddr(\"glCreateFramebuffers\"))\n\tgpCreateMemoryObjectsEXT = uintptr(getProcAddr(\"glCreateMemoryObjectsEXT\"))\n\tgpCreatePerfQueryINTEL = uintptr(getProcAddr(\"glCreatePerfQueryINTEL\"))\n\tgpCreateProgram = uintptr(getProcAddr(\"glCreateProgram\"))\n\tif gpCreateProgram == 0 {\n\t\treturn errors.New(\"glCreateProgram\")\n\t}\n\tgpCreateProgramObjectARB = uintptr(getProcAddr(\"glCreateProgramObjectARB\"))\n\tgpCreateProgramPipelines = uintptr(getProcAddr(\"glCreateProgramPipelines\"))\n\tgpCreateQueries = uintptr(getProcAddr(\"glCreateQueries\"))\n\tgpCreateRenderbuffers = uintptr(getProcAddr(\"glCreateRenderbuffers\"))\n\tgpCreateSamplers = uintptr(getProcAddr(\"glCreateSamplers\"))\n\tgpCreateShader = uintptr(getProcAddr(\"glCreateShader\"))\n\tif gpCreateShader == 0 {\n\t\treturn errors.New(\"glCreateShader\")\n\t}\n\tgpCreateShaderObjectARB = uintptr(getProcAddr(\"glCreateShaderObjectARB\"))\n\tgpCreateShaderProgramEXT = uintptr(getProcAddr(\"glCreateShaderProgramEXT\"))\n\tgpCreateShaderProgramv = uintptr(getProcAddr(\"glCreateShaderProgramv\"))\n\tgpCreateShaderProgramvEXT = uintptr(getProcAddr(\"glCreateShaderProgramvEXT\"))\n\tgpCreateStatesNV = uintptr(getProcAddr(\"glCreateStatesNV\"))\n\tgpCreateSyncFromCLeventARB = uintptr(getProcAddr(\"glCreateSyncFromCLeventARB\"))\n\tgpCreateTextures = uintptr(getProcAddr(\"glCreateTextures\"))\n\tgpCreateTransformFeedbacks = uintptr(getProcAddr(\"glCreateTransformFeedbacks\"))\n\tgpCreateVertexArrays = uintptr(getProcAddr(\"glCreateVertexArrays\"))\n\tgpCullFace = uintptr(getProcAddr(\"glCullFace\"))\n\tif gpCullFace == 0 {\n\t\treturn errors.New(\"glCullFace\")\n\t}\n\tgpCullParameterdvEXT = uintptr(getProcAddr(\"glCullParameterdvEXT\"))\n\tgpCullParameterfvEXT = uintptr(getProcAddr(\"glCullParameterfvEXT\"))\n\tgpCurrentPaletteMatrixARB = uintptr(getProcAddr(\"glCurrentPaletteMatrixARB\"))\n\tgpDebugMessageCallback = uintptr(getProcAddr(\"glDebugMessageCallback\"))\n\tgpDebugMessageCallbackAMD = uintptr(getProcAddr(\"glDebugMessageCallbackAMD\"))\n\tgpDebugMessageCallbackARB = uintptr(getProcAddr(\"glDebugMessageCallbackARB\"))\n\tgpDebugMessageCallbackKHR = uintptr(getProcAddr(\"glDebugMessageCallbackKHR\"))\n\tgpDebugMessageControl = uintptr(getProcAddr(\"glDebugMessageControl\"))\n\tgpDebugMessageControlARB = uintptr(getProcAddr(\"glDebugMessageControlARB\"))\n\tgpDebugMessageControlKHR = uintptr(getProcAddr(\"glDebugMessageControlKHR\"))\n\tgpDebugMessageEnableAMD = uintptr(getProcAddr(\"glDebugMessageEnableAMD\"))\n\tgpDebugMessageInsert = uintptr(getProcAddr(\"glDebugMessageInsert\"))\n\tgpDebugMessageInsertAMD = uintptr(getProcAddr(\"glDebugMessageInsertAMD\"))\n\tgpDebugMessageInsertARB = uintptr(getProcAddr(\"glDebugMessageInsertARB\"))\n\tgpDebugMessageInsertKHR = uintptr(getProcAddr(\"glDebugMessageInsertKHR\"))\n\tgpDeformSGIX = uintptr(getProcAddr(\"glDeformSGIX\"))\n\tgpDeformationMap3dSGIX = uintptr(getProcAddr(\"glDeformationMap3dSGIX\"))\n\tgpDeformationMap3fSGIX = uintptr(getProcAddr(\"glDeformationMap3fSGIX\"))\n\tgpDeleteAsyncMarkersSGIX = uintptr(getProcAddr(\"glDeleteAsyncMarkersSGIX\"))\n\tgpDeleteBuffers = uintptr(getProcAddr(\"glDeleteBuffers\"))\n\tif gpDeleteBuffers == 0 {\n\t\treturn errors.New(\"glDeleteBuffers\")\n\t}\n\tgpDeleteBuffersARB = uintptr(getProcAddr(\"glDeleteBuffersARB\"))\n\tgpDeleteCommandListsNV = uintptr(getProcAddr(\"glDeleteCommandListsNV\"))\n\tgpDeleteFencesAPPLE = uintptr(getProcAddr(\"glDeleteFencesAPPLE\"))\n\tgpDeleteFencesNV = uintptr(getProcAddr(\"glDeleteFencesNV\"))\n\tgpDeleteFragmentShaderATI = uintptr(getProcAddr(\"glDeleteFragmentShaderATI\"))\n\tgpDeleteFramebuffers = uintptr(getProcAddr(\"glDeleteFramebuffers\"))\n\tgpDeleteFramebuffersEXT = uintptr(getProcAddr(\"glDeleteFramebuffersEXT\"))\n\tgpDeleteLists = uintptr(getProcAddr(\"glDeleteLists\"))\n\tif gpDeleteLists == 0 {\n\t\treturn errors.New(\"glDeleteLists\")\n\t}\n\tgpDeleteMemoryObjectsEXT = uintptr(getProcAddr(\"glDeleteMemoryObjectsEXT\"))\n\tgpDeleteNamedStringARB = uintptr(getProcAddr(\"glDeleteNamedStringARB\"))\n\tgpDeleteNamesAMD = uintptr(getProcAddr(\"glDeleteNamesAMD\"))\n\tgpDeleteObjectARB = uintptr(getProcAddr(\"glDeleteObjectARB\"))\n\tgpDeleteOcclusionQueriesNV = uintptr(getProcAddr(\"glDeleteOcclusionQueriesNV\"))\n\tgpDeletePathsNV = uintptr(getProcAddr(\"glDeletePathsNV\"))\n\tgpDeletePerfMonitorsAMD = uintptr(getProcAddr(\"glDeletePerfMonitorsAMD\"))\n\tgpDeletePerfQueryINTEL = uintptr(getProcAddr(\"glDeletePerfQueryINTEL\"))\n\tgpDeleteProgram = uintptr(getProcAddr(\"glDeleteProgram\"))\n\tif gpDeleteProgram == 0 {\n\t\treturn errors.New(\"glDeleteProgram\")\n\t}\n\tgpDeleteProgramPipelines = uintptr(getProcAddr(\"glDeleteProgramPipelines\"))\n\tgpDeleteProgramPipelinesEXT = uintptr(getProcAddr(\"glDeleteProgramPipelinesEXT\"))\n\tgpDeleteProgramsARB = uintptr(getProcAddr(\"glDeleteProgramsARB\"))\n\tgpDeleteProgramsNV = uintptr(getProcAddr(\"glDeleteProgramsNV\"))\n\tgpDeleteQueries = uintptr(getProcAddr(\"glDeleteQueries\"))\n\tif gpDeleteQueries == 0 {\n\t\treturn errors.New(\"glDeleteQueries\")\n\t}\n\tgpDeleteQueriesARB = uintptr(getProcAddr(\"glDeleteQueriesARB\"))\n\tgpDeleteQueryResourceTagNV = uintptr(getProcAddr(\"glDeleteQueryResourceTagNV\"))\n\tgpDeleteRenderbuffers = uintptr(getProcAddr(\"glDeleteRenderbuffers\"))\n\tgpDeleteRenderbuffersEXT = uintptr(getProcAddr(\"glDeleteRenderbuffersEXT\"))\n\tgpDeleteSamplers = uintptr(getProcAddr(\"glDeleteSamplers\"))\n\tgpDeleteSemaphoresEXT = uintptr(getProcAddr(\"glDeleteSemaphoresEXT\"))\n\tgpDeleteShader = uintptr(getProcAddr(\"glDeleteShader\"))\n\tif gpDeleteShader == 0 {\n\t\treturn errors.New(\"glDeleteShader\")\n\t}\n\tgpDeleteStatesNV = uintptr(getProcAddr(\"glDeleteStatesNV\"))\n\tgpDeleteSync = uintptr(getProcAddr(\"glDeleteSync\"))\n\tgpDeleteTextures = uintptr(getProcAddr(\"glDeleteTextures\"))\n\tif gpDeleteTextures == 0 {\n\t\treturn errors.New(\"glDeleteTextures\")\n\t}\n\tgpDeleteTexturesEXT = uintptr(getProcAddr(\"glDeleteTexturesEXT\"))\n\tgpDeleteTransformFeedbacks = uintptr(getProcAddr(\"glDeleteTransformFeedbacks\"))\n\tgpDeleteTransformFeedbacksNV = uintptr(getProcAddr(\"glDeleteTransformFeedbacksNV\"))\n\tgpDeleteVertexArrays = uintptr(getProcAddr(\"glDeleteVertexArrays\"))\n\tgpDeleteVertexArraysAPPLE = uintptr(getProcAddr(\"glDeleteVertexArraysAPPLE\"))\n\tgpDeleteVertexShaderEXT = uintptr(getProcAddr(\"glDeleteVertexShaderEXT\"))\n\tgpDepthBoundsEXT = uintptr(getProcAddr(\"glDepthBoundsEXT\"))\n\tgpDepthBoundsdNV = uintptr(getProcAddr(\"glDepthBoundsdNV\"))\n\tgpDepthFunc = uintptr(getProcAddr(\"glDepthFunc\"))\n\tif gpDepthFunc == 0 {\n\t\treturn errors.New(\"glDepthFunc\")\n\t}\n\tgpDepthMask = uintptr(getProcAddr(\"glDepthMask\"))\n\tif gpDepthMask == 0 {\n\t\treturn errors.New(\"glDepthMask\")\n\t}\n\tgpDepthRange = uintptr(getProcAddr(\"glDepthRange\"))\n\tif gpDepthRange == 0 {\n\t\treturn errors.New(\"glDepthRange\")\n\t}\n\tgpDepthRangeArrayv = uintptr(getProcAddr(\"glDepthRangeArrayv\"))\n\tgpDepthRangeIndexed = uintptr(getProcAddr(\"glDepthRangeIndexed\"))\n\tgpDepthRangedNV = uintptr(getProcAddr(\"glDepthRangedNV\"))\n\tgpDepthRangef = uintptr(getProcAddr(\"glDepthRangef\"))\n\tgpDepthRangefOES = uintptr(getProcAddr(\"glDepthRangefOES\"))\n\tgpDepthRangexOES = uintptr(getProcAddr(\"glDepthRangexOES\"))\n\tgpDetachObjectARB = uintptr(getProcAddr(\"glDetachObjectARB\"))\n\tgpDetachShader = uintptr(getProcAddr(\"glDetachShader\"))\n\tif gpDetachShader == 0 {\n\t\treturn errors.New(\"glDetachShader\")\n\t}\n\tgpDetailTexFuncSGIS = uintptr(getProcAddr(\"glDetailTexFuncSGIS\"))\n\tgpDisable = uintptr(getProcAddr(\"glDisable\"))\n\tif gpDisable == 0 {\n\t\treturn errors.New(\"glDisable\")\n\t}\n\tgpDisableClientState = uintptr(getProcAddr(\"glDisableClientState\"))\n\tif gpDisableClientState == 0 {\n\t\treturn errors.New(\"glDisableClientState\")\n\t}\n\tgpDisableClientStateIndexedEXT = uintptr(getProcAddr(\"glDisableClientStateIndexedEXT\"))\n\tgpDisableClientStateiEXT = uintptr(getProcAddr(\"glDisableClientStateiEXT\"))\n\tgpDisableIndexedEXT = uintptr(getProcAddr(\"glDisableIndexedEXT\"))\n\tgpDisableVariantClientStateEXT = uintptr(getProcAddr(\"glDisableVariantClientStateEXT\"))\n\tgpDisableVertexArrayAttrib = uintptr(getProcAddr(\"glDisableVertexArrayAttrib\"))\n\tgpDisableVertexArrayAttribEXT = uintptr(getProcAddr(\"glDisableVertexArrayAttribEXT\"))\n\tgpDisableVertexArrayEXT = uintptr(getProcAddr(\"glDisableVertexArrayEXT\"))\n\tgpDisableVertexAttribAPPLE = uintptr(getProcAddr(\"glDisableVertexAttribAPPLE\"))\n\tgpDisableVertexAttribArray = uintptr(getProcAddr(\"glDisableVertexAttribArray\"))\n\tif gpDisableVertexAttribArray == 0 {\n\t\treturn errors.New(\"glDisableVertexAttribArray\")\n\t}\n\tgpDisableVertexAttribArrayARB = uintptr(getProcAddr(\"glDisableVertexAttribArrayARB\"))\n\tgpDispatchCompute = uintptr(getProcAddr(\"glDispatchCompute\"))\n\tgpDispatchComputeGroupSizeARB = uintptr(getProcAddr(\"glDispatchComputeGroupSizeARB\"))\n\tgpDispatchComputeIndirect = uintptr(getProcAddr(\"glDispatchComputeIndirect\"))\n\tgpDrawArrays = uintptr(getProcAddr(\"glDrawArrays\"))\n\tif gpDrawArrays == 0 {\n\t\treturn errors.New(\"glDrawArrays\")\n\t}\n\tgpDrawArraysEXT = uintptr(getProcAddr(\"glDrawArraysEXT\"))\n\tgpDrawArraysIndirect = uintptr(getProcAddr(\"glDrawArraysIndirect\"))\n\tgpDrawArraysInstancedARB = uintptr(getProcAddr(\"glDrawArraysInstancedARB\"))\n\tgpDrawArraysInstancedBaseInstance = uintptr(getProcAddr(\"glDrawArraysInstancedBaseInstance\"))\n\tgpDrawArraysInstancedEXT = uintptr(getProcAddr(\"glDrawArraysInstancedEXT\"))\n\tgpDrawBuffer = uintptr(getProcAddr(\"glDrawBuffer\"))\n\tif gpDrawBuffer == 0 {\n\t\treturn errors.New(\"glDrawBuffer\")\n\t}\n\tgpDrawBuffers = uintptr(getProcAddr(\"glDrawBuffers\"))\n\tif gpDrawBuffers == 0 {\n\t\treturn errors.New(\"glDrawBuffers\")\n\t}\n\tgpDrawBuffersARB = uintptr(getProcAddr(\"glDrawBuffersARB\"))\n\tgpDrawBuffersATI = uintptr(getProcAddr(\"glDrawBuffersATI\"))\n\tgpDrawCommandsAddressNV = uintptr(getProcAddr(\"glDrawCommandsAddressNV\"))\n\tgpDrawCommandsNV = uintptr(getProcAddr(\"glDrawCommandsNV\"))\n\tgpDrawCommandsStatesAddressNV = uintptr(getProcAddr(\"glDrawCommandsStatesAddressNV\"))\n\tgpDrawCommandsStatesNV = uintptr(getProcAddr(\"glDrawCommandsStatesNV\"))\n\tgpDrawElementArrayAPPLE = uintptr(getProcAddr(\"glDrawElementArrayAPPLE\"))\n\tgpDrawElementArrayATI = uintptr(getProcAddr(\"glDrawElementArrayATI\"))\n\tgpDrawElements = uintptr(getProcAddr(\"glDrawElements\"))\n\tif gpDrawElements == 0 {\n\t\treturn errors.New(\"glDrawElements\")\n\t}\n\tgpDrawElementsBaseVertex = uintptr(getProcAddr(\"glDrawElementsBaseVertex\"))\n\tgpDrawElementsIndirect = uintptr(getProcAddr(\"glDrawElementsIndirect\"))\n\tgpDrawElementsInstancedARB = uintptr(getProcAddr(\"glDrawElementsInstancedARB\"))\n\tgpDrawElementsInstancedBaseInstance = uintptr(getProcAddr(\"glDrawElementsInstancedBaseInstance\"))\n\tgpDrawElementsInstancedBaseVertex = uintptr(getProcAddr(\"glDrawElementsInstancedBaseVertex\"))\n\tgpDrawElementsInstancedBaseVertexBaseInstance = uintptr(getProcAddr(\"glDrawElementsInstancedBaseVertexBaseInstance\"))\n\tgpDrawElementsInstancedEXT = uintptr(getProcAddr(\"glDrawElementsInstancedEXT\"))\n\tgpDrawMeshArraysSUN = uintptr(getProcAddr(\"glDrawMeshArraysSUN\"))\n\tgpDrawPixels = uintptr(getProcAddr(\"glDrawPixels\"))\n\tif gpDrawPixels == 0 {\n\t\treturn errors.New(\"glDrawPixels\")\n\t}\n\tgpDrawRangeElementArrayAPPLE = uintptr(getProcAddr(\"glDrawRangeElementArrayAPPLE\"))\n\tgpDrawRangeElementArrayATI = uintptr(getProcAddr(\"glDrawRangeElementArrayATI\"))\n\tgpDrawRangeElements = uintptr(getProcAddr(\"glDrawRangeElements\"))\n\tif gpDrawRangeElements == 0 {\n\t\treturn errors.New(\"glDrawRangeElements\")\n\t}\n\tgpDrawRangeElementsBaseVertex = uintptr(getProcAddr(\"glDrawRangeElementsBaseVertex\"))\n\tgpDrawRangeElementsEXT = uintptr(getProcAddr(\"glDrawRangeElementsEXT\"))\n\tgpDrawTextureNV = uintptr(getProcAddr(\"glDrawTextureNV\"))\n\tgpDrawTransformFeedback = uintptr(getProcAddr(\"glDrawTransformFeedback\"))\n\tgpDrawTransformFeedbackInstanced = uintptr(getProcAddr(\"glDrawTransformFeedbackInstanced\"))\n\tgpDrawTransformFeedbackNV = uintptr(getProcAddr(\"glDrawTransformFeedbackNV\"))\n\tgpDrawTransformFeedbackStream = uintptr(getProcAddr(\"glDrawTransformFeedbackStream\"))\n\tgpDrawTransformFeedbackStreamInstanced = uintptr(getProcAddr(\"glDrawTransformFeedbackStreamInstanced\"))\n\tgpDrawVkImageNV = uintptr(getProcAddr(\"glDrawVkImageNV\"))\n\tgpEGLImageTargetTexStorageEXT = uintptr(getProcAddr(\"glEGLImageTargetTexStorageEXT\"))\n\tgpEGLImageTargetTextureStorageEXT = uintptr(getProcAddr(\"glEGLImageTargetTextureStorageEXT\"))\n\tgpEdgeFlag = uintptr(getProcAddr(\"glEdgeFlag\"))\n\tif gpEdgeFlag == 0 {\n\t\treturn errors.New(\"glEdgeFlag\")\n\t}\n\tgpEdgeFlagFormatNV = uintptr(getProcAddr(\"glEdgeFlagFormatNV\"))\n\tgpEdgeFlagPointer = uintptr(getProcAddr(\"glEdgeFlagPointer\"))\n\tif gpEdgeFlagPointer == 0 {\n\t\treturn errors.New(\"glEdgeFlagPointer\")\n\t}\n\tgpEdgeFlagPointerEXT = uintptr(getProcAddr(\"glEdgeFlagPointerEXT\"))\n\tgpEdgeFlagPointerListIBM = uintptr(getProcAddr(\"glEdgeFlagPointerListIBM\"))\n\tgpEdgeFlagv = uintptr(getProcAddr(\"glEdgeFlagv\"))\n\tif gpEdgeFlagv == 0 {\n\t\treturn errors.New(\"glEdgeFlagv\")\n\t}\n\tgpElementPointerAPPLE = uintptr(getProcAddr(\"glElementPointerAPPLE\"))\n\tgpElementPointerATI = uintptr(getProcAddr(\"glElementPointerATI\"))\n\tgpEnable = uintptr(getProcAddr(\"glEnable\"))\n\tif gpEnable == 0 {\n\t\treturn errors.New(\"glEnable\")\n\t}\n\tgpEnableClientState = uintptr(getProcAddr(\"glEnableClientState\"))\n\tif gpEnableClientState == 0 {\n\t\treturn errors.New(\"glEnableClientState\")\n\t}\n\tgpEnableClientStateIndexedEXT = uintptr(getProcAddr(\"glEnableClientStateIndexedEXT\"))\n\tgpEnableClientStateiEXT = uintptr(getProcAddr(\"glEnableClientStateiEXT\"))\n\tgpEnableIndexedEXT = uintptr(getProcAddr(\"glEnableIndexedEXT\"))\n\tgpEnableVariantClientStateEXT = uintptr(getProcAddr(\"glEnableVariantClientStateEXT\"))\n\tgpEnableVertexArrayAttrib = uintptr(getProcAddr(\"glEnableVertexArrayAttrib\"))\n\tgpEnableVertexArrayAttribEXT = uintptr(getProcAddr(\"glEnableVertexArrayAttribEXT\"))\n\tgpEnableVertexArrayEXT = uintptr(getProcAddr(\"glEnableVertexArrayEXT\"))\n\tgpEnableVertexAttribAPPLE = uintptr(getProcAddr(\"glEnableVertexAttribAPPLE\"))\n\tgpEnableVertexAttribArray = uintptr(getProcAddr(\"glEnableVertexAttribArray\"))\n\tif gpEnableVertexAttribArray == 0 {\n\t\treturn errors.New(\"glEnableVertexAttribArray\")\n\t}\n\tgpEnableVertexAttribArrayARB = uintptr(getProcAddr(\"glEnableVertexAttribArrayARB\"))\n\tgpEnd = uintptr(getProcAddr(\"glEnd\"))\n\tif gpEnd == 0 {\n\t\treturn errors.New(\"glEnd\")\n\t}\n\tgpEndConditionalRenderNV = uintptr(getProcAddr(\"glEndConditionalRenderNV\"))\n\tgpEndConditionalRenderNVX = uintptr(getProcAddr(\"glEndConditionalRenderNVX\"))\n\tgpEndFragmentShaderATI = uintptr(getProcAddr(\"glEndFragmentShaderATI\"))\n\tgpEndList = uintptr(getProcAddr(\"glEndList\"))\n\tif gpEndList == 0 {\n\t\treturn errors.New(\"glEndList\")\n\t}\n\tgpEndOcclusionQueryNV = uintptr(getProcAddr(\"glEndOcclusionQueryNV\"))\n\tgpEndPerfMonitorAMD = uintptr(getProcAddr(\"glEndPerfMonitorAMD\"))\n\tgpEndPerfQueryINTEL = uintptr(getProcAddr(\"glEndPerfQueryINTEL\"))\n\tgpEndQuery = uintptr(getProcAddr(\"glEndQuery\"))\n\tif gpEndQuery == 0 {\n\t\treturn errors.New(\"glEndQuery\")\n\t}\n\tgpEndQueryARB = uintptr(getProcAddr(\"glEndQueryARB\"))\n\tgpEndQueryIndexed = uintptr(getProcAddr(\"glEndQueryIndexed\"))\n\tgpEndTransformFeedbackEXT = uintptr(getProcAddr(\"glEndTransformFeedbackEXT\"))\n\tgpEndTransformFeedbackNV = uintptr(getProcAddr(\"glEndTransformFeedbackNV\"))\n\tgpEndVertexShaderEXT = uintptr(getProcAddr(\"glEndVertexShaderEXT\"))\n\tgpEndVideoCaptureNV = uintptr(getProcAddr(\"glEndVideoCaptureNV\"))\n\tgpEvalCoord1d = uintptr(getProcAddr(\"glEvalCoord1d\"))\n\tif gpEvalCoord1d == 0 {\n\t\treturn errors.New(\"glEvalCoord1d\")\n\t}\n\tgpEvalCoord1dv = uintptr(getProcAddr(\"glEvalCoord1dv\"))\n\tif gpEvalCoord1dv == 0 {\n\t\treturn errors.New(\"glEvalCoord1dv\")\n\t}\n\tgpEvalCoord1f = uintptr(getProcAddr(\"glEvalCoord1f\"))\n\tif gpEvalCoord1f == 0 {\n\t\treturn errors.New(\"glEvalCoord1f\")\n\t}\n\tgpEvalCoord1fv = uintptr(getProcAddr(\"glEvalCoord1fv\"))\n\tif gpEvalCoord1fv == 0 {\n\t\treturn errors.New(\"glEvalCoord1fv\")\n\t}\n\tgpEvalCoord1xOES = uintptr(getProcAddr(\"glEvalCoord1xOES\"))\n\tgpEvalCoord1xvOES = uintptr(getProcAddr(\"glEvalCoord1xvOES\"))\n\tgpEvalCoord2d = uintptr(getProcAddr(\"glEvalCoord2d\"))\n\tif gpEvalCoord2d == 0 {\n\t\treturn errors.New(\"glEvalCoord2d\")\n\t}\n\tgpEvalCoord2dv = uintptr(getProcAddr(\"glEvalCoord2dv\"))\n\tif gpEvalCoord2dv == 0 {\n\t\treturn errors.New(\"glEvalCoord2dv\")\n\t}\n\tgpEvalCoord2f = uintptr(getProcAddr(\"glEvalCoord2f\"))\n\tif gpEvalCoord2f == 0 {\n\t\treturn errors.New(\"glEvalCoord2f\")\n\t}\n\tgpEvalCoord2fv = uintptr(getProcAddr(\"glEvalCoord2fv\"))\n\tif gpEvalCoord2fv == 0 {\n\t\treturn errors.New(\"glEvalCoord2fv\")\n\t}\n\tgpEvalCoord2xOES = uintptr(getProcAddr(\"glEvalCoord2xOES\"))\n\tgpEvalCoord2xvOES = uintptr(getProcAddr(\"glEvalCoord2xvOES\"))\n\tgpEvalMapsNV = uintptr(getProcAddr(\"glEvalMapsNV\"))\n\tgpEvalMesh1 = uintptr(getProcAddr(\"glEvalMesh1\"))\n\tif gpEvalMesh1 == 0 {\n\t\treturn errors.New(\"glEvalMesh1\")\n\t}\n\tgpEvalMesh2 = uintptr(getProcAddr(\"glEvalMesh2\"))\n\tif gpEvalMesh2 == 0 {\n\t\treturn errors.New(\"glEvalMesh2\")\n\t}\n\tgpEvalPoint1 = uintptr(getProcAddr(\"glEvalPoint1\"))\n\tif gpEvalPoint1 == 0 {\n\t\treturn errors.New(\"glEvalPoint1\")\n\t}\n\tgpEvalPoint2 = uintptr(getProcAddr(\"glEvalPoint2\"))\n\tif gpEvalPoint2 == 0 {\n\t\treturn errors.New(\"glEvalPoint2\")\n\t}\n\tgpEvaluateDepthValuesARB = uintptr(getProcAddr(\"glEvaluateDepthValuesARB\"))\n\tgpExecuteProgramNV = uintptr(getProcAddr(\"glExecuteProgramNV\"))\n\tgpExtractComponentEXT = uintptr(getProcAddr(\"glExtractComponentEXT\"))\n\tgpFeedbackBuffer = uintptr(getProcAddr(\"glFeedbackBuffer\"))\n\tif gpFeedbackBuffer == 0 {\n\t\treturn errors.New(\"glFeedbackBuffer\")\n\t}\n\tgpFeedbackBufferxOES = uintptr(getProcAddr(\"glFeedbackBufferxOES\"))\n\tgpFenceSync = uintptr(getProcAddr(\"glFenceSync\"))\n\tgpFinalCombinerInputNV = uintptr(getProcAddr(\"glFinalCombinerInputNV\"))\n\tgpFinish = uintptr(getProcAddr(\"glFinish\"))\n\tif gpFinish == 0 {\n\t\treturn errors.New(\"glFinish\")\n\t}\n\tgpFinishAsyncSGIX = uintptr(getProcAddr(\"glFinishAsyncSGIX\"))\n\tgpFinishFenceAPPLE = uintptr(getProcAddr(\"glFinishFenceAPPLE\"))\n\tgpFinishFenceNV = uintptr(getProcAddr(\"glFinishFenceNV\"))\n\tgpFinishObjectAPPLE = uintptr(getProcAddr(\"glFinishObjectAPPLE\"))\n\tgpFinishTextureSUNX = uintptr(getProcAddr(\"glFinishTextureSUNX\"))\n\tgpFlush = uintptr(getProcAddr(\"glFlush\"))\n\tif gpFlush == 0 {\n\t\treturn errors.New(\"glFlush\")\n\t}\n\tgpFlushMappedBufferRange = uintptr(getProcAddr(\"glFlushMappedBufferRange\"))\n\tgpFlushMappedBufferRangeAPPLE = uintptr(getProcAddr(\"glFlushMappedBufferRangeAPPLE\"))\n\tgpFlushMappedNamedBufferRange = uintptr(getProcAddr(\"glFlushMappedNamedBufferRange\"))\n\tgpFlushMappedNamedBufferRangeEXT = uintptr(getProcAddr(\"glFlushMappedNamedBufferRangeEXT\"))\n\tgpFlushPixelDataRangeNV = uintptr(getProcAddr(\"glFlushPixelDataRangeNV\"))\n\tgpFlushRasterSGIX = uintptr(getProcAddr(\"glFlushRasterSGIX\"))\n\tgpFlushStaticDataIBM = uintptr(getProcAddr(\"glFlushStaticDataIBM\"))\n\tgpFlushVertexArrayRangeAPPLE = uintptr(getProcAddr(\"glFlushVertexArrayRangeAPPLE\"))\n\tgpFlushVertexArrayRangeNV = uintptr(getProcAddr(\"glFlushVertexArrayRangeNV\"))\n\tgpFogCoordFormatNV = uintptr(getProcAddr(\"glFogCoordFormatNV\"))\n\tgpFogCoordPointer = uintptr(getProcAddr(\"glFogCoordPointer\"))\n\tif gpFogCoordPointer == 0 {\n\t\treturn errors.New(\"glFogCoordPointer\")\n\t}\n\tgpFogCoordPointerEXT = uintptr(getProcAddr(\"glFogCoordPointerEXT\"))\n\tgpFogCoordPointerListIBM = uintptr(getProcAddr(\"glFogCoordPointerListIBM\"))\n\tgpFogCoordd = uintptr(getProcAddr(\"glFogCoordd\"))\n\tif gpFogCoordd == 0 {\n\t\treturn errors.New(\"glFogCoordd\")\n\t}\n\tgpFogCoorddEXT = uintptr(getProcAddr(\"glFogCoorddEXT\"))\n\tgpFogCoorddv = uintptr(getProcAddr(\"glFogCoorddv\"))\n\tif gpFogCoorddv == 0 {\n\t\treturn errors.New(\"glFogCoorddv\")\n\t}\n\tgpFogCoorddvEXT = uintptr(getProcAddr(\"glFogCoorddvEXT\"))\n\tgpFogCoordf = uintptr(getProcAddr(\"glFogCoordf\"))\n\tif gpFogCoordf == 0 {\n\t\treturn errors.New(\"glFogCoordf\")\n\t}\n\tgpFogCoordfEXT = uintptr(getProcAddr(\"glFogCoordfEXT\"))\n\tgpFogCoordfv = uintptr(getProcAddr(\"glFogCoordfv\"))\n\tif gpFogCoordfv == 0 {\n\t\treturn errors.New(\"glFogCoordfv\")\n\t}\n\tgpFogCoordfvEXT = uintptr(getProcAddr(\"glFogCoordfvEXT\"))\n\tgpFogCoordhNV = uintptr(getProcAddr(\"glFogCoordhNV\"))\n\tgpFogCoordhvNV = uintptr(getProcAddr(\"glFogCoordhvNV\"))\n\tgpFogFuncSGIS = uintptr(getProcAddr(\"glFogFuncSGIS\"))\n\tgpFogf = uintptr(getProcAddr(\"glFogf\"))\n\tif gpFogf == 0 {\n\t\treturn errors.New(\"glFogf\")\n\t}\n\tgpFogfv = uintptr(getProcAddr(\"glFogfv\"))\n\tif gpFogfv == 0 {\n\t\treturn errors.New(\"glFogfv\")\n\t}\n\tgpFogi = uintptr(getProcAddr(\"glFogi\"))\n\tif gpFogi == 0 {\n\t\treturn errors.New(\"glFogi\")\n\t}\n\tgpFogiv = uintptr(getProcAddr(\"glFogiv\"))\n\tif gpFogiv == 0 {\n\t\treturn errors.New(\"glFogiv\")\n\t}\n\tgpFogxOES = uintptr(getProcAddr(\"glFogxOES\"))\n\tgpFogxvOES = uintptr(getProcAddr(\"glFogxvOES\"))\n\tgpFragmentColorMaterialSGIX = uintptr(getProcAddr(\"glFragmentColorMaterialSGIX\"))\n\tgpFragmentCoverageColorNV = uintptr(getProcAddr(\"glFragmentCoverageColorNV\"))\n\tgpFragmentLightModelfSGIX = uintptr(getProcAddr(\"glFragmentLightModelfSGIX\"))\n\tgpFragmentLightModelfvSGIX = uintptr(getProcAddr(\"glFragmentLightModelfvSGIX\"))\n\tgpFragmentLightModeliSGIX = uintptr(getProcAddr(\"glFragmentLightModeliSGIX\"))\n\tgpFragmentLightModelivSGIX = uintptr(getProcAddr(\"glFragmentLightModelivSGIX\"))\n\tgpFragmentLightfSGIX = uintptr(getProcAddr(\"glFragmentLightfSGIX\"))\n\tgpFragmentLightfvSGIX = uintptr(getProcAddr(\"glFragmentLightfvSGIX\"))\n\tgpFragmentLightiSGIX = uintptr(getProcAddr(\"glFragmentLightiSGIX\"))\n\tgpFragmentLightivSGIX = uintptr(getProcAddr(\"glFragmentLightivSGIX\"))\n\tgpFragmentMaterialfSGIX = uintptr(getProcAddr(\"glFragmentMaterialfSGIX\"))\n\tgpFragmentMaterialfvSGIX = uintptr(getProcAddr(\"glFragmentMaterialfvSGIX\"))\n\tgpFragmentMaterialiSGIX = uintptr(getProcAddr(\"glFragmentMaterialiSGIX\"))\n\tgpFragmentMaterialivSGIX = uintptr(getProcAddr(\"glFragmentMaterialivSGIX\"))\n\tgpFrameTerminatorGREMEDY = uintptr(getProcAddr(\"glFrameTerminatorGREMEDY\"))\n\tgpFrameZoomSGIX = uintptr(getProcAddr(\"glFrameZoomSGIX\"))\n\tgpFramebufferDrawBufferEXT = uintptr(getProcAddr(\"glFramebufferDrawBufferEXT\"))\n\tgpFramebufferDrawBuffersEXT = uintptr(getProcAddr(\"glFramebufferDrawBuffersEXT\"))\n\tgpFramebufferFetchBarrierEXT = uintptr(getProcAddr(\"glFramebufferFetchBarrierEXT\"))\n\tgpFramebufferParameteri = uintptr(getProcAddr(\"glFramebufferParameteri\"))\n\tgpFramebufferReadBufferEXT = uintptr(getProcAddr(\"glFramebufferReadBufferEXT\"))\n\tgpFramebufferRenderbuffer = uintptr(getProcAddr(\"glFramebufferRenderbuffer\"))\n\tgpFramebufferRenderbufferEXT = uintptr(getProcAddr(\"glFramebufferRenderbufferEXT\"))\n\tgpFramebufferSampleLocationsfvARB = uintptr(getProcAddr(\"glFramebufferSampleLocationsfvARB\"))\n\tgpFramebufferSampleLocationsfvNV = uintptr(getProcAddr(\"glFramebufferSampleLocationsfvNV\"))\n\tgpFramebufferSamplePositionsfvAMD = uintptr(getProcAddr(\"glFramebufferSamplePositionsfvAMD\"))\n\tgpFramebufferTexture1D = uintptr(getProcAddr(\"glFramebufferTexture1D\"))\n\tgpFramebufferTexture1DEXT = uintptr(getProcAddr(\"glFramebufferTexture1DEXT\"))\n\tgpFramebufferTexture2D = uintptr(getProcAddr(\"glFramebufferTexture2D\"))\n\tgpFramebufferTexture2DEXT = uintptr(getProcAddr(\"glFramebufferTexture2DEXT\"))\n\tgpFramebufferTexture3D = uintptr(getProcAddr(\"glFramebufferTexture3D\"))\n\tgpFramebufferTexture3DEXT = uintptr(getProcAddr(\"glFramebufferTexture3DEXT\"))\n\tgpFramebufferTextureARB = uintptr(getProcAddr(\"glFramebufferTextureARB\"))\n\tgpFramebufferTextureEXT = uintptr(getProcAddr(\"glFramebufferTextureEXT\"))\n\tgpFramebufferTextureFaceARB = uintptr(getProcAddr(\"glFramebufferTextureFaceARB\"))\n\tgpFramebufferTextureFaceEXT = uintptr(getProcAddr(\"glFramebufferTextureFaceEXT\"))\n\tgpFramebufferTextureLayer = uintptr(getProcAddr(\"glFramebufferTextureLayer\"))\n\tgpFramebufferTextureLayerARB = uintptr(getProcAddr(\"glFramebufferTextureLayerARB\"))\n\tgpFramebufferTextureLayerEXT = uintptr(getProcAddr(\"glFramebufferTextureLayerEXT\"))\n\tgpFramebufferTextureMultiviewOVR = uintptr(getProcAddr(\"glFramebufferTextureMultiviewOVR\"))\n\tgpFreeObjectBufferATI = uintptr(getProcAddr(\"glFreeObjectBufferATI\"))\n\tgpFrontFace = uintptr(getProcAddr(\"glFrontFace\"))\n\tif gpFrontFace == 0 {\n\t\treturn errors.New(\"glFrontFace\")\n\t}\n\tgpFrustum = uintptr(getProcAddr(\"glFrustum\"))\n\tif gpFrustum == 0 {\n\t\treturn errors.New(\"glFrustum\")\n\t}\n\tgpFrustumfOES = uintptr(getProcAddr(\"glFrustumfOES\"))\n\tgpFrustumxOES = uintptr(getProcAddr(\"glFrustumxOES\"))\n\tgpGenAsyncMarkersSGIX = uintptr(getProcAddr(\"glGenAsyncMarkersSGIX\"))\n\tgpGenBuffers = uintptr(getProcAddr(\"glGenBuffers\"))\n\tif gpGenBuffers == 0 {\n\t\treturn errors.New(\"glGenBuffers\")\n\t}\n\tgpGenBuffersARB = uintptr(getProcAddr(\"glGenBuffersARB\"))\n\tgpGenFencesAPPLE = uintptr(getProcAddr(\"glGenFencesAPPLE\"))\n\tgpGenFencesNV = uintptr(getProcAddr(\"glGenFencesNV\"))\n\tgpGenFragmentShadersATI = uintptr(getProcAddr(\"glGenFragmentShadersATI\"))\n\tgpGenFramebuffers = uintptr(getProcAddr(\"glGenFramebuffers\"))\n\tgpGenFramebuffersEXT = uintptr(getProcAddr(\"glGenFramebuffersEXT\"))\n\tgpGenLists = uintptr(getProcAddr(\"glGenLists\"))\n\tif gpGenLists == 0 {\n\t\treturn errors.New(\"glGenLists\")\n\t}\n\tgpGenNamesAMD = uintptr(getProcAddr(\"glGenNamesAMD\"))\n\tgpGenOcclusionQueriesNV = uintptr(getProcAddr(\"glGenOcclusionQueriesNV\"))\n\tgpGenPathsNV = uintptr(getProcAddr(\"glGenPathsNV\"))\n\tgpGenPerfMonitorsAMD = uintptr(getProcAddr(\"glGenPerfMonitorsAMD\"))\n\tgpGenProgramPipelines = uintptr(getProcAddr(\"glGenProgramPipelines\"))\n\tgpGenProgramPipelinesEXT = uintptr(getProcAddr(\"glGenProgramPipelinesEXT\"))\n\tgpGenProgramsARB = uintptr(getProcAddr(\"glGenProgramsARB\"))\n\tgpGenProgramsNV = uintptr(getProcAddr(\"glGenProgramsNV\"))\n\tgpGenQueries = uintptr(getProcAddr(\"glGenQueries\"))\n\tif gpGenQueries == 0 {\n\t\treturn errors.New(\"glGenQueries\")\n\t}\n\tgpGenQueriesARB = uintptr(getProcAddr(\"glGenQueriesARB\"))\n\tgpGenQueryResourceTagNV = uintptr(getProcAddr(\"glGenQueryResourceTagNV\"))\n\tgpGenRenderbuffers = uintptr(getProcAddr(\"glGenRenderbuffers\"))\n\tgpGenRenderbuffersEXT = uintptr(getProcAddr(\"glGenRenderbuffersEXT\"))\n\tgpGenSamplers = uintptr(getProcAddr(\"glGenSamplers\"))\n\tgpGenSemaphoresEXT = uintptr(getProcAddr(\"glGenSemaphoresEXT\"))\n\tgpGenSymbolsEXT = uintptr(getProcAddr(\"glGenSymbolsEXT\"))\n\tgpGenTextures = uintptr(getProcAddr(\"glGenTextures\"))\n\tif gpGenTextures == 0 {\n\t\treturn errors.New(\"glGenTextures\")\n\t}\n\tgpGenTexturesEXT = uintptr(getProcAddr(\"glGenTexturesEXT\"))\n\tgpGenTransformFeedbacks = uintptr(getProcAddr(\"glGenTransformFeedbacks\"))\n\tgpGenTransformFeedbacksNV = uintptr(getProcAddr(\"glGenTransformFeedbacksNV\"))\n\tgpGenVertexArrays = uintptr(getProcAddr(\"glGenVertexArrays\"))\n\tgpGenVertexArraysAPPLE = uintptr(getProcAddr(\"glGenVertexArraysAPPLE\"))\n\tgpGenVertexShadersEXT = uintptr(getProcAddr(\"glGenVertexShadersEXT\"))\n\tgpGenerateMipmap = uintptr(getProcAddr(\"glGenerateMipmap\"))\n\tgpGenerateMipmapEXT = uintptr(getProcAddr(\"glGenerateMipmapEXT\"))\n\tgpGenerateMultiTexMipmapEXT = uintptr(getProcAddr(\"glGenerateMultiTexMipmapEXT\"))\n\tgpGenerateTextureMipmap = uintptr(getProcAddr(\"glGenerateTextureMipmap\"))\n\tgpGenerateTextureMipmapEXT = uintptr(getProcAddr(\"glGenerateTextureMipmapEXT\"))\n\tgpGetActiveAtomicCounterBufferiv = uintptr(getProcAddr(\"glGetActiveAtomicCounterBufferiv\"))\n\tgpGetActiveAttrib = uintptr(getProcAddr(\"glGetActiveAttrib\"))\n\tif gpGetActiveAttrib == 0 {\n\t\treturn errors.New(\"glGetActiveAttrib\")\n\t}\n\tgpGetActiveAttribARB = uintptr(getProcAddr(\"glGetActiveAttribARB\"))\n\tgpGetActiveSubroutineName = uintptr(getProcAddr(\"glGetActiveSubroutineName\"))\n\tgpGetActiveSubroutineUniformName = uintptr(getProcAddr(\"glGetActiveSubroutineUniformName\"))\n\tgpGetActiveSubroutineUniformiv = uintptr(getProcAddr(\"glGetActiveSubroutineUniformiv\"))\n\tgpGetActiveUniform = uintptr(getProcAddr(\"glGetActiveUniform\"))\n\tif gpGetActiveUniform == 0 {\n\t\treturn errors.New(\"glGetActiveUniform\")\n\t}\n\tgpGetActiveUniformARB = uintptr(getProcAddr(\"glGetActiveUniformARB\"))\n\tgpGetActiveUniformBlockName = uintptr(getProcAddr(\"glGetActiveUniformBlockName\"))\n\tgpGetActiveUniformBlockiv = uintptr(getProcAddr(\"glGetActiveUniformBlockiv\"))\n\tgpGetActiveUniformName = uintptr(getProcAddr(\"glGetActiveUniformName\"))\n\tgpGetActiveUniformsiv = uintptr(getProcAddr(\"glGetActiveUniformsiv\"))\n\tgpGetActiveVaryingNV = uintptr(getProcAddr(\"glGetActiveVaryingNV\"))\n\tgpGetArrayObjectfvATI = uintptr(getProcAddr(\"glGetArrayObjectfvATI\"))\n\tgpGetArrayObjectivATI = uintptr(getProcAddr(\"glGetArrayObjectivATI\"))\n\tgpGetAttachedObjectsARB = uintptr(getProcAddr(\"glGetAttachedObjectsARB\"))\n\tgpGetAttachedShaders = uintptr(getProcAddr(\"glGetAttachedShaders\"))\n\tif gpGetAttachedShaders == 0 {\n\t\treturn errors.New(\"glGetAttachedShaders\")\n\t}\n\tgpGetAttribLocation = uintptr(getProcAddr(\"glGetAttribLocation\"))\n\tif gpGetAttribLocation == 0 {\n\t\treturn errors.New(\"glGetAttribLocation\")\n\t}\n\tgpGetAttribLocationARB = uintptr(getProcAddr(\"glGetAttribLocationARB\"))\n\tgpGetBooleanIndexedvEXT = uintptr(getProcAddr(\"glGetBooleanIndexedvEXT\"))\n\tgpGetBooleanv = uintptr(getProcAddr(\"glGetBooleanv\"))\n\tif gpGetBooleanv == 0 {\n\t\treturn errors.New(\"glGetBooleanv\")\n\t}\n\tgpGetBufferParameteriv = uintptr(getProcAddr(\"glGetBufferParameteriv\"))\n\tif gpGetBufferParameteriv == 0 {\n\t\treturn errors.New(\"glGetBufferParameteriv\")\n\t}\n\tgpGetBufferParameterivARB = uintptr(getProcAddr(\"glGetBufferParameterivARB\"))\n\tgpGetBufferParameterui64vNV = uintptr(getProcAddr(\"glGetBufferParameterui64vNV\"))\n\tgpGetBufferPointerv = uintptr(getProcAddr(\"glGetBufferPointerv\"))\n\tif gpGetBufferPointerv == 0 {\n\t\treturn errors.New(\"glGetBufferPointerv\")\n\t}\n\tgpGetBufferPointervARB = uintptr(getProcAddr(\"glGetBufferPointervARB\"))\n\tgpGetBufferSubData = uintptr(getProcAddr(\"glGetBufferSubData\"))\n\tif gpGetBufferSubData == 0 {\n\t\treturn errors.New(\"glGetBufferSubData\")\n\t}\n\tgpGetBufferSubDataARB = uintptr(getProcAddr(\"glGetBufferSubDataARB\"))\n\tgpGetClipPlane = uintptr(getProcAddr(\"glGetClipPlane\"))\n\tif gpGetClipPlane == 0 {\n\t\treturn errors.New(\"glGetClipPlane\")\n\t}\n\tgpGetClipPlanefOES = uintptr(getProcAddr(\"glGetClipPlanefOES\"))\n\tgpGetClipPlanexOES = uintptr(getProcAddr(\"glGetClipPlanexOES\"))\n\tgpGetColorTableEXT = uintptr(getProcAddr(\"glGetColorTableEXT\"))\n\tgpGetColorTableParameterfvEXT = uintptr(getProcAddr(\"glGetColorTableParameterfvEXT\"))\n\tgpGetColorTableParameterfvSGI = uintptr(getProcAddr(\"glGetColorTableParameterfvSGI\"))\n\tgpGetColorTableParameterivEXT = uintptr(getProcAddr(\"glGetColorTableParameterivEXT\"))\n\tgpGetColorTableParameterivSGI = uintptr(getProcAddr(\"glGetColorTableParameterivSGI\"))\n\tgpGetColorTableSGI = uintptr(getProcAddr(\"glGetColorTableSGI\"))\n\tgpGetCombinerInputParameterfvNV = uintptr(getProcAddr(\"glGetCombinerInputParameterfvNV\"))\n\tgpGetCombinerInputParameterivNV = uintptr(getProcAddr(\"glGetCombinerInputParameterivNV\"))\n\tgpGetCombinerOutputParameterfvNV = uintptr(getProcAddr(\"glGetCombinerOutputParameterfvNV\"))\n\tgpGetCombinerOutputParameterivNV = uintptr(getProcAddr(\"glGetCombinerOutputParameterivNV\"))\n\tgpGetCombinerStageParameterfvNV = uintptr(getProcAddr(\"glGetCombinerStageParameterfvNV\"))\n\tgpGetCommandHeaderNV = uintptr(getProcAddr(\"glGetCommandHeaderNV\"))\n\tgpGetCompressedMultiTexImageEXT = uintptr(getProcAddr(\"glGetCompressedMultiTexImageEXT\"))\n\tgpGetCompressedTexImage = uintptr(getProcAddr(\"glGetCompressedTexImage\"))\n\tif gpGetCompressedTexImage == 0 {\n\t\treturn errors.New(\"glGetCompressedTexImage\")\n\t}\n\tgpGetCompressedTexImageARB = uintptr(getProcAddr(\"glGetCompressedTexImageARB\"))\n\tgpGetCompressedTextureImage = uintptr(getProcAddr(\"glGetCompressedTextureImage\"))\n\tgpGetCompressedTextureImageEXT = uintptr(getProcAddr(\"glGetCompressedTextureImageEXT\"))\n\tgpGetCompressedTextureSubImage = uintptr(getProcAddr(\"glGetCompressedTextureSubImage\"))\n\tgpGetConvolutionFilterEXT = uintptr(getProcAddr(\"glGetConvolutionFilterEXT\"))\n\tgpGetConvolutionParameterfvEXT = uintptr(getProcAddr(\"glGetConvolutionParameterfvEXT\"))\n\tgpGetConvolutionParameterivEXT = uintptr(getProcAddr(\"glGetConvolutionParameterivEXT\"))\n\tgpGetConvolutionParameterxvOES = uintptr(getProcAddr(\"glGetConvolutionParameterxvOES\"))\n\tgpGetCoverageModulationTableNV = uintptr(getProcAddr(\"glGetCoverageModulationTableNV\"))\n\tgpGetDebugMessageLog = uintptr(getProcAddr(\"glGetDebugMessageLog\"))\n\tgpGetDebugMessageLogAMD = uintptr(getProcAddr(\"glGetDebugMessageLogAMD\"))\n\tgpGetDebugMessageLogARB = uintptr(getProcAddr(\"glGetDebugMessageLogARB\"))\n\tgpGetDebugMessageLogKHR = uintptr(getProcAddr(\"glGetDebugMessageLogKHR\"))\n\tgpGetDetailTexFuncSGIS = uintptr(getProcAddr(\"glGetDetailTexFuncSGIS\"))\n\tgpGetDoubleIndexedvEXT = uintptr(getProcAddr(\"glGetDoubleIndexedvEXT\"))\n\tgpGetDoublei_v = uintptr(getProcAddr(\"glGetDoublei_v\"))\n\tgpGetDoublei_vEXT = uintptr(getProcAddr(\"glGetDoublei_vEXT\"))\n\tgpGetDoublev = uintptr(getProcAddr(\"glGetDoublev\"))\n\tif gpGetDoublev == 0 {\n\t\treturn errors.New(\"glGetDoublev\")\n\t}\n\tgpGetError = uintptr(getProcAddr(\"glGetError\"))\n\tif gpGetError == 0 {\n\t\treturn errors.New(\"glGetError\")\n\t}\n\tgpGetFenceivNV = uintptr(getProcAddr(\"glGetFenceivNV\"))\n\tgpGetFinalCombinerInputParameterfvNV = uintptr(getProcAddr(\"glGetFinalCombinerInputParameterfvNV\"))\n\tgpGetFinalCombinerInputParameterivNV = uintptr(getProcAddr(\"glGetFinalCombinerInputParameterivNV\"))\n\tgpGetFirstPerfQueryIdINTEL = uintptr(getProcAddr(\"glGetFirstPerfQueryIdINTEL\"))\n\tgpGetFixedvOES = uintptr(getProcAddr(\"glGetFixedvOES\"))\n\tgpGetFloatIndexedvEXT = uintptr(getProcAddr(\"glGetFloatIndexedvEXT\"))\n\tgpGetFloati_v = uintptr(getProcAddr(\"glGetFloati_v\"))\n\tgpGetFloati_vEXT = uintptr(getProcAddr(\"glGetFloati_vEXT\"))\n\tgpGetFloatv = uintptr(getProcAddr(\"glGetFloatv\"))\n\tif gpGetFloatv == 0 {\n\t\treturn errors.New(\"glGetFloatv\")\n\t}\n\tgpGetFogFuncSGIS = uintptr(getProcAddr(\"glGetFogFuncSGIS\"))\n\tgpGetFragDataIndex = uintptr(getProcAddr(\"glGetFragDataIndex\"))\n\tgpGetFragDataLocationEXT = uintptr(getProcAddr(\"glGetFragDataLocationEXT\"))\n\tgpGetFragmentLightfvSGIX = uintptr(getProcAddr(\"glGetFragmentLightfvSGIX\"))\n\tgpGetFragmentLightivSGIX = uintptr(getProcAddr(\"glGetFragmentLightivSGIX\"))\n\tgpGetFragmentMaterialfvSGIX = uintptr(getProcAddr(\"glGetFragmentMaterialfvSGIX\"))\n\tgpGetFragmentMaterialivSGIX = uintptr(getProcAddr(\"glGetFragmentMaterialivSGIX\"))\n\tgpGetFramebufferAttachmentParameteriv = uintptr(getProcAddr(\"glGetFramebufferAttachmentParameteriv\"))\n\tgpGetFramebufferAttachmentParameterivEXT = uintptr(getProcAddr(\"glGetFramebufferAttachmentParameterivEXT\"))\n\tgpGetFramebufferParameterfvAMD = uintptr(getProcAddr(\"glGetFramebufferParameterfvAMD\"))\n\tgpGetFramebufferParameteriv = uintptr(getProcAddr(\"glGetFramebufferParameteriv\"))\n\tgpGetFramebufferParameterivEXT = uintptr(getProcAddr(\"glGetFramebufferParameterivEXT\"))\n\tgpGetGraphicsResetStatus = uintptr(getProcAddr(\"glGetGraphicsResetStatus\"))\n\tgpGetGraphicsResetStatusARB = uintptr(getProcAddr(\"glGetGraphicsResetStatusARB\"))\n\tgpGetGraphicsResetStatusKHR = uintptr(getProcAddr(\"glGetGraphicsResetStatusKHR\"))\n\tgpGetHandleARB = uintptr(getProcAddr(\"glGetHandleARB\"))\n\tgpGetHistogramEXT = uintptr(getProcAddr(\"glGetHistogramEXT\"))\n\tgpGetHistogramParameterfvEXT = uintptr(getProcAddr(\"glGetHistogramParameterfvEXT\"))\n\tgpGetHistogramParameterivEXT = uintptr(getProcAddr(\"glGetHistogramParameterivEXT\"))\n\tgpGetHistogramParameterxvOES = uintptr(getProcAddr(\"glGetHistogramParameterxvOES\"))\n\tgpGetImageHandleARB = uintptr(getProcAddr(\"glGetImageHandleARB\"))\n\tgpGetImageHandleNV = uintptr(getProcAddr(\"glGetImageHandleNV\"))\n\tgpGetImageTransformParameterfvHP = uintptr(getProcAddr(\"glGetImageTransformParameterfvHP\"))\n\tgpGetImageTransformParameterivHP = uintptr(getProcAddr(\"glGetImageTransformParameterivHP\"))\n\tgpGetInfoLogARB = uintptr(getProcAddr(\"glGetInfoLogARB\"))\n\tgpGetInstrumentsSGIX = uintptr(getProcAddr(\"glGetInstrumentsSGIX\"))\n\tgpGetInteger64v = uintptr(getProcAddr(\"glGetInteger64v\"))\n\tgpGetIntegerIndexedvEXT = uintptr(getProcAddr(\"glGetIntegerIndexedvEXT\"))\n\tgpGetIntegeri_v = uintptr(getProcAddr(\"glGetIntegeri_v\"))\n\tgpGetIntegerui64i_vNV = uintptr(getProcAddr(\"glGetIntegerui64i_vNV\"))\n\tgpGetIntegerui64vNV = uintptr(getProcAddr(\"glGetIntegerui64vNV\"))\n\tgpGetIntegerv = uintptr(getProcAddr(\"glGetIntegerv\"))\n\tif gpGetIntegerv == 0 {\n\t\treturn errors.New(\"glGetIntegerv\")\n\t}\n\tgpGetInternalformatSampleivNV = uintptr(getProcAddr(\"glGetInternalformatSampleivNV\"))\n\tgpGetInternalformati64v = uintptr(getProcAddr(\"glGetInternalformati64v\"))\n\tgpGetInternalformativ = uintptr(getProcAddr(\"glGetInternalformativ\"))\n\tgpGetInvariantBooleanvEXT = uintptr(getProcAddr(\"glGetInvariantBooleanvEXT\"))\n\tgpGetInvariantFloatvEXT = uintptr(getProcAddr(\"glGetInvariantFloatvEXT\"))\n\tgpGetInvariantIntegervEXT = uintptr(getProcAddr(\"glGetInvariantIntegervEXT\"))\n\tgpGetLightfv = uintptr(getProcAddr(\"glGetLightfv\"))\n\tif gpGetLightfv == 0 {\n\t\treturn errors.New(\"glGetLightfv\")\n\t}\n\tgpGetLightiv = uintptr(getProcAddr(\"glGetLightiv\"))\n\tif gpGetLightiv == 0 {\n\t\treturn errors.New(\"glGetLightiv\")\n\t}\n\tgpGetLightxOES = uintptr(getProcAddr(\"glGetLightxOES\"))\n\tgpGetLightxvOES = uintptr(getProcAddr(\"glGetLightxvOES\"))\n\tgpGetListParameterfvSGIX = uintptr(getProcAddr(\"glGetListParameterfvSGIX\"))\n\tgpGetListParameterivSGIX = uintptr(getProcAddr(\"glGetListParameterivSGIX\"))\n\tgpGetLocalConstantBooleanvEXT = uintptr(getProcAddr(\"glGetLocalConstantBooleanvEXT\"))\n\tgpGetLocalConstantFloatvEXT = uintptr(getProcAddr(\"glGetLocalConstantFloatvEXT\"))\n\tgpGetLocalConstantIntegervEXT = uintptr(getProcAddr(\"glGetLocalConstantIntegervEXT\"))\n\tgpGetMapAttribParameterfvNV = uintptr(getProcAddr(\"glGetMapAttribParameterfvNV\"))\n\tgpGetMapAttribParameterivNV = uintptr(getProcAddr(\"glGetMapAttribParameterivNV\"))\n\tgpGetMapControlPointsNV = uintptr(getProcAddr(\"glGetMapControlPointsNV\"))\n\tgpGetMapParameterfvNV = uintptr(getProcAddr(\"glGetMapParameterfvNV\"))\n\tgpGetMapParameterivNV = uintptr(getProcAddr(\"glGetMapParameterivNV\"))\n\tgpGetMapdv = uintptr(getProcAddr(\"glGetMapdv\"))\n\tif gpGetMapdv == 0 {\n\t\treturn errors.New(\"glGetMapdv\")\n\t}\n\tgpGetMapfv = uintptr(getProcAddr(\"glGetMapfv\"))\n\tif gpGetMapfv == 0 {\n\t\treturn errors.New(\"glGetMapfv\")\n\t}\n\tgpGetMapiv = uintptr(getProcAddr(\"glGetMapiv\"))\n\tif gpGetMapiv == 0 {\n\t\treturn errors.New(\"glGetMapiv\")\n\t}\n\tgpGetMapxvOES = uintptr(getProcAddr(\"glGetMapxvOES\"))\n\tgpGetMaterialfv = uintptr(getProcAddr(\"glGetMaterialfv\"))\n\tif gpGetMaterialfv == 0 {\n\t\treturn errors.New(\"glGetMaterialfv\")\n\t}\n\tgpGetMaterialiv = uintptr(getProcAddr(\"glGetMaterialiv\"))\n\tif gpGetMaterialiv == 0 {\n\t\treturn errors.New(\"glGetMaterialiv\")\n\t}\n\tgpGetMaterialxOES = uintptr(getProcAddr(\"glGetMaterialxOES\"))\n\tgpGetMaterialxvOES = uintptr(getProcAddr(\"glGetMaterialxvOES\"))\n\tgpGetMemoryObjectParameterivEXT = uintptr(getProcAddr(\"glGetMemoryObjectParameterivEXT\"))\n\tgpGetMinmaxEXT = uintptr(getProcAddr(\"glGetMinmaxEXT\"))\n\tgpGetMinmaxParameterfvEXT = uintptr(getProcAddr(\"glGetMinmaxParameterfvEXT\"))\n\tgpGetMinmaxParameterivEXT = uintptr(getProcAddr(\"glGetMinmaxParameterivEXT\"))\n\tgpGetMultiTexEnvfvEXT = uintptr(getProcAddr(\"glGetMultiTexEnvfvEXT\"))\n\tgpGetMultiTexEnvivEXT = uintptr(getProcAddr(\"glGetMultiTexEnvivEXT\"))\n\tgpGetMultiTexGendvEXT = uintptr(getProcAddr(\"glGetMultiTexGendvEXT\"))\n\tgpGetMultiTexGenfvEXT = uintptr(getProcAddr(\"glGetMultiTexGenfvEXT\"))\n\tgpGetMultiTexGenivEXT = uintptr(getProcAddr(\"glGetMultiTexGenivEXT\"))\n\tgpGetMultiTexImageEXT = uintptr(getProcAddr(\"glGetMultiTexImageEXT\"))\n\tgpGetMultiTexLevelParameterfvEXT = uintptr(getProcAddr(\"glGetMultiTexLevelParameterfvEXT\"))\n\tgpGetMultiTexLevelParameterivEXT = uintptr(getProcAddr(\"glGetMultiTexLevelParameterivEXT\"))\n\tgpGetMultiTexParameterIivEXT = uintptr(getProcAddr(\"glGetMultiTexParameterIivEXT\"))\n\tgpGetMultiTexParameterIuivEXT = uintptr(getProcAddr(\"glGetMultiTexParameterIuivEXT\"))\n\tgpGetMultiTexParameterfvEXT = uintptr(getProcAddr(\"glGetMultiTexParameterfvEXT\"))\n\tgpGetMultiTexParameterivEXT = uintptr(getProcAddr(\"glGetMultiTexParameterivEXT\"))\n\tgpGetMultisamplefv = uintptr(getProcAddr(\"glGetMultisamplefv\"))\n\tgpGetMultisamplefvNV = uintptr(getProcAddr(\"glGetMultisamplefvNV\"))\n\tgpGetNamedBufferParameteri64v = uintptr(getProcAddr(\"glGetNamedBufferParameteri64v\"))\n\tgpGetNamedBufferParameteriv = uintptr(getProcAddr(\"glGetNamedBufferParameteriv\"))\n\tgpGetNamedBufferParameterivEXT = uintptr(getProcAddr(\"glGetNamedBufferParameterivEXT\"))\n\tgpGetNamedBufferParameterui64vNV = uintptr(getProcAddr(\"glGetNamedBufferParameterui64vNV\"))\n\tgpGetNamedBufferPointerv = uintptr(getProcAddr(\"glGetNamedBufferPointerv\"))\n\tgpGetNamedBufferPointervEXT = uintptr(getProcAddr(\"glGetNamedBufferPointervEXT\"))\n\tgpGetNamedBufferSubData = uintptr(getProcAddr(\"glGetNamedBufferSubData\"))\n\tgpGetNamedBufferSubDataEXT = uintptr(getProcAddr(\"glGetNamedBufferSubDataEXT\"))\n\tgpGetNamedFramebufferAttachmentParameteriv = uintptr(getProcAddr(\"glGetNamedFramebufferAttachmentParameteriv\"))\n\tgpGetNamedFramebufferAttachmentParameterivEXT = uintptr(getProcAddr(\"glGetNamedFramebufferAttachmentParameterivEXT\"))\n\tgpGetNamedFramebufferParameterfvAMD = uintptr(getProcAddr(\"glGetNamedFramebufferParameterfvAMD\"))\n\tgpGetNamedFramebufferParameteriv = uintptr(getProcAddr(\"glGetNamedFramebufferParameteriv\"))\n\tgpGetNamedFramebufferParameterivEXT = uintptr(getProcAddr(\"glGetNamedFramebufferParameterivEXT\"))\n\tgpGetNamedProgramLocalParameterIivEXT = uintptr(getProcAddr(\"glGetNamedProgramLocalParameterIivEXT\"))\n\tgpGetNamedProgramLocalParameterIuivEXT = uintptr(getProcAddr(\"glGetNamedProgramLocalParameterIuivEXT\"))\n\tgpGetNamedProgramLocalParameterdvEXT = uintptr(getProcAddr(\"glGetNamedProgramLocalParameterdvEXT\"))\n\tgpGetNamedProgramLocalParameterfvEXT = uintptr(getProcAddr(\"glGetNamedProgramLocalParameterfvEXT\"))\n\tgpGetNamedProgramStringEXT = uintptr(getProcAddr(\"glGetNamedProgramStringEXT\"))\n\tgpGetNamedProgramivEXT = uintptr(getProcAddr(\"glGetNamedProgramivEXT\"))\n\tgpGetNamedRenderbufferParameteriv = uintptr(getProcAddr(\"glGetNamedRenderbufferParameteriv\"))\n\tgpGetNamedRenderbufferParameterivEXT = uintptr(getProcAddr(\"glGetNamedRenderbufferParameterivEXT\"))\n\tgpGetNamedStringARB = uintptr(getProcAddr(\"glGetNamedStringARB\"))\n\tgpGetNamedStringivARB = uintptr(getProcAddr(\"glGetNamedStringivARB\"))\n\tgpGetNextPerfQueryIdINTEL = uintptr(getProcAddr(\"glGetNextPerfQueryIdINTEL\"))\n\tgpGetObjectBufferfvATI = uintptr(getProcAddr(\"glGetObjectBufferfvATI\"))\n\tgpGetObjectBufferivATI = uintptr(getProcAddr(\"glGetObjectBufferivATI\"))\n\tgpGetObjectLabel = uintptr(getProcAddr(\"glGetObjectLabel\"))\n\tgpGetObjectLabelEXT = uintptr(getProcAddr(\"glGetObjectLabelEXT\"))\n\tgpGetObjectLabelKHR = uintptr(getProcAddr(\"glGetObjectLabelKHR\"))\n\tgpGetObjectParameterfvARB = uintptr(getProcAddr(\"glGetObjectParameterfvARB\"))\n\tgpGetObjectParameterivAPPLE = uintptr(getProcAddr(\"glGetObjectParameterivAPPLE\"))\n\tgpGetObjectParameterivARB = uintptr(getProcAddr(\"glGetObjectParameterivARB\"))\n\tgpGetObjectPtrLabel = uintptr(getProcAddr(\"glGetObjectPtrLabel\"))\n\tgpGetObjectPtrLabelKHR = uintptr(getProcAddr(\"glGetObjectPtrLabelKHR\"))\n\tgpGetOcclusionQueryivNV = uintptr(getProcAddr(\"glGetOcclusionQueryivNV\"))\n\tgpGetOcclusionQueryuivNV = uintptr(getProcAddr(\"glGetOcclusionQueryuivNV\"))\n\tgpGetPathCommandsNV = uintptr(getProcAddr(\"glGetPathCommandsNV\"))\n\tgpGetPathCoordsNV = uintptr(getProcAddr(\"glGetPathCoordsNV\"))\n\tgpGetPathDashArrayNV = uintptr(getProcAddr(\"glGetPathDashArrayNV\"))\n\tgpGetPathLengthNV = uintptr(getProcAddr(\"glGetPathLengthNV\"))\n\tgpGetPathMetricRangeNV = uintptr(getProcAddr(\"glGetPathMetricRangeNV\"))\n\tgpGetPathMetricsNV = uintptr(getProcAddr(\"glGetPathMetricsNV\"))\n\tgpGetPathParameterfvNV = uintptr(getProcAddr(\"glGetPathParameterfvNV\"))\n\tgpGetPathParameterivNV = uintptr(getProcAddr(\"glGetPathParameterivNV\"))\n\tgpGetPathSpacingNV = uintptr(getProcAddr(\"glGetPathSpacingNV\"))\n\tgpGetPerfCounterInfoINTEL = uintptr(getProcAddr(\"glGetPerfCounterInfoINTEL\"))\n\tgpGetPerfMonitorCounterDataAMD = uintptr(getProcAddr(\"glGetPerfMonitorCounterDataAMD\"))\n\tgpGetPerfMonitorCounterInfoAMD = uintptr(getProcAddr(\"glGetPerfMonitorCounterInfoAMD\"))\n\tgpGetPerfMonitorCounterStringAMD = uintptr(getProcAddr(\"glGetPerfMonitorCounterStringAMD\"))\n\tgpGetPerfMonitorCountersAMD = uintptr(getProcAddr(\"glGetPerfMonitorCountersAMD\"))\n\tgpGetPerfMonitorGroupStringAMD = uintptr(getProcAddr(\"glGetPerfMonitorGroupStringAMD\"))\n\tgpGetPerfMonitorGroupsAMD = uintptr(getProcAddr(\"glGetPerfMonitorGroupsAMD\"))\n\tgpGetPerfQueryDataINTEL = uintptr(getProcAddr(\"glGetPerfQueryDataINTEL\"))\n\tgpGetPerfQueryIdByNameINTEL = uintptr(getProcAddr(\"glGetPerfQueryIdByNameINTEL\"))\n\tgpGetPerfQueryInfoINTEL = uintptr(getProcAddr(\"glGetPerfQueryInfoINTEL\"))\n\tgpGetPixelMapfv = uintptr(getProcAddr(\"glGetPixelMapfv\"))\n\tif gpGetPixelMapfv == 0 {\n\t\treturn errors.New(\"glGetPixelMapfv\")\n\t}\n\tgpGetPixelMapuiv = uintptr(getProcAddr(\"glGetPixelMapuiv\"))\n\tif gpGetPixelMapuiv == 0 {\n\t\treturn errors.New(\"glGetPixelMapuiv\")\n\t}\n\tgpGetPixelMapusv = uintptr(getProcAddr(\"glGetPixelMapusv\"))\n\tif gpGetPixelMapusv == 0 {\n\t\treturn errors.New(\"glGetPixelMapusv\")\n\t}\n\tgpGetPixelMapxv = uintptr(getProcAddr(\"glGetPixelMapxv\"))\n\tgpGetPixelTexGenParameterfvSGIS = uintptr(getProcAddr(\"glGetPixelTexGenParameterfvSGIS\"))\n\tgpGetPixelTexGenParameterivSGIS = uintptr(getProcAddr(\"glGetPixelTexGenParameterivSGIS\"))\n\tgpGetPixelTransformParameterfvEXT = uintptr(getProcAddr(\"glGetPixelTransformParameterfvEXT\"))\n\tgpGetPixelTransformParameterivEXT = uintptr(getProcAddr(\"glGetPixelTransformParameterivEXT\"))\n\tgpGetPointerIndexedvEXT = uintptr(getProcAddr(\"glGetPointerIndexedvEXT\"))\n\tgpGetPointeri_vEXT = uintptr(getProcAddr(\"glGetPointeri_vEXT\"))\n\tgpGetPointerv = uintptr(getProcAddr(\"glGetPointerv\"))\n\tif gpGetPointerv == 0 {\n\t\treturn errors.New(\"glGetPointerv\")\n\t}\n\tgpGetPointervEXT = uintptr(getProcAddr(\"glGetPointervEXT\"))\n\tgpGetPointervKHR = uintptr(getProcAddr(\"glGetPointervKHR\"))\n\tgpGetPolygonStipple = uintptr(getProcAddr(\"glGetPolygonStipple\"))\n\tif gpGetPolygonStipple == 0 {\n\t\treturn errors.New(\"glGetPolygonStipple\")\n\t}\n\tgpGetProgramBinary = uintptr(getProcAddr(\"glGetProgramBinary\"))\n\tgpGetProgramEnvParameterIivNV = uintptr(getProcAddr(\"glGetProgramEnvParameterIivNV\"))\n\tgpGetProgramEnvParameterIuivNV = uintptr(getProcAddr(\"glGetProgramEnvParameterIuivNV\"))\n\tgpGetProgramEnvParameterdvARB = uintptr(getProcAddr(\"glGetProgramEnvParameterdvARB\"))\n\tgpGetProgramEnvParameterfvARB = uintptr(getProcAddr(\"glGetProgramEnvParameterfvARB\"))\n\tgpGetProgramInfoLog = uintptr(getProcAddr(\"glGetProgramInfoLog\"))\n\tif gpGetProgramInfoLog == 0 {\n\t\treturn errors.New(\"glGetProgramInfoLog\")\n\t}\n\tgpGetProgramInterfaceiv = uintptr(getProcAddr(\"glGetProgramInterfaceiv\"))\n\tgpGetProgramLocalParameterIivNV = uintptr(getProcAddr(\"glGetProgramLocalParameterIivNV\"))\n\tgpGetProgramLocalParameterIuivNV = uintptr(getProcAddr(\"glGetProgramLocalParameterIuivNV\"))\n\tgpGetProgramLocalParameterdvARB = uintptr(getProcAddr(\"glGetProgramLocalParameterdvARB\"))\n\tgpGetProgramLocalParameterfvARB = uintptr(getProcAddr(\"glGetProgramLocalParameterfvARB\"))\n\tgpGetProgramNamedParameterdvNV = uintptr(getProcAddr(\"glGetProgramNamedParameterdvNV\"))\n\tgpGetProgramNamedParameterfvNV = uintptr(getProcAddr(\"glGetProgramNamedParameterfvNV\"))\n\tgpGetProgramParameterdvNV = uintptr(getProcAddr(\"glGetProgramParameterdvNV\"))\n\tgpGetProgramParameterfvNV = uintptr(getProcAddr(\"glGetProgramParameterfvNV\"))\n\tgpGetProgramPipelineInfoLog = uintptr(getProcAddr(\"glGetProgramPipelineInfoLog\"))\n\tgpGetProgramPipelineInfoLogEXT = uintptr(getProcAddr(\"glGetProgramPipelineInfoLogEXT\"))\n\tgpGetProgramPipelineiv = uintptr(getProcAddr(\"glGetProgramPipelineiv\"))\n\tgpGetProgramPipelineivEXT = uintptr(getProcAddr(\"glGetProgramPipelineivEXT\"))\n\tgpGetProgramResourceIndex = uintptr(getProcAddr(\"glGetProgramResourceIndex\"))\n\tgpGetProgramResourceLocation = uintptr(getProcAddr(\"glGetProgramResourceLocation\"))\n\tgpGetProgramResourceLocationIndex = uintptr(getProcAddr(\"glGetProgramResourceLocationIndex\"))\n\tgpGetProgramResourceName = uintptr(getProcAddr(\"glGetProgramResourceName\"))\n\tgpGetProgramResourcefvNV = uintptr(getProcAddr(\"glGetProgramResourcefvNV\"))\n\tgpGetProgramResourceiv = uintptr(getProcAddr(\"glGetProgramResourceiv\"))\n\tgpGetProgramStageiv = uintptr(getProcAddr(\"glGetProgramStageiv\"))\n\tgpGetProgramStringARB = uintptr(getProcAddr(\"glGetProgramStringARB\"))\n\tgpGetProgramStringNV = uintptr(getProcAddr(\"glGetProgramStringNV\"))\n\tgpGetProgramSubroutineParameteruivNV = uintptr(getProcAddr(\"glGetProgramSubroutineParameteruivNV\"))\n\tgpGetProgramiv = uintptr(getProcAddr(\"glGetProgramiv\"))\n\tif gpGetProgramiv == 0 {\n\t\treturn errors.New(\"glGetProgramiv\")\n\t}\n\tgpGetProgramivARB = uintptr(getProcAddr(\"glGetProgramivARB\"))\n\tgpGetProgramivNV = uintptr(getProcAddr(\"glGetProgramivNV\"))\n\tgpGetQueryBufferObjecti64v = uintptr(getProcAddr(\"glGetQueryBufferObjecti64v\"))\n\tgpGetQueryBufferObjectiv = uintptr(getProcAddr(\"glGetQueryBufferObjectiv\"))\n\tgpGetQueryBufferObjectui64v = uintptr(getProcAddr(\"glGetQueryBufferObjectui64v\"))\n\tgpGetQueryBufferObjectuiv = uintptr(getProcAddr(\"glGetQueryBufferObjectuiv\"))\n\tgpGetQueryIndexediv = uintptr(getProcAddr(\"glGetQueryIndexediv\"))\n\tgpGetQueryObjecti64v = uintptr(getProcAddr(\"glGetQueryObjecti64v\"))\n\tgpGetQueryObjecti64vEXT = uintptr(getProcAddr(\"glGetQueryObjecti64vEXT\"))\n\tgpGetQueryObjectiv = uintptr(getProcAddr(\"glGetQueryObjectiv\"))\n\tif gpGetQueryObjectiv == 0 {\n\t\treturn errors.New(\"glGetQueryObjectiv\")\n\t}\n\tgpGetQueryObjectivARB = uintptr(getProcAddr(\"glGetQueryObjectivARB\"))\n\tgpGetQueryObjectui64v = uintptr(getProcAddr(\"glGetQueryObjectui64v\"))\n\tgpGetQueryObjectui64vEXT = uintptr(getProcAddr(\"glGetQueryObjectui64vEXT\"))\n\tgpGetQueryObjectuiv = uintptr(getProcAddr(\"glGetQueryObjectuiv\"))\n\tif gpGetQueryObjectuiv == 0 {\n\t\treturn errors.New(\"glGetQueryObjectuiv\")\n\t}\n\tgpGetQueryObjectuivARB = uintptr(getProcAddr(\"glGetQueryObjectuivARB\"))\n\tgpGetQueryiv = uintptr(getProcAddr(\"glGetQueryiv\"))\n\tif gpGetQueryiv == 0 {\n\t\treturn errors.New(\"glGetQueryiv\")\n\t}\n\tgpGetQueryivARB = uintptr(getProcAddr(\"glGetQueryivARB\"))\n\tgpGetRenderbufferParameteriv = uintptr(getProcAddr(\"glGetRenderbufferParameteriv\"))\n\tgpGetRenderbufferParameterivEXT = uintptr(getProcAddr(\"glGetRenderbufferParameterivEXT\"))\n\tgpGetSamplerParameterIiv = uintptr(getProcAddr(\"glGetSamplerParameterIiv\"))\n\tgpGetSamplerParameterIuiv = uintptr(getProcAddr(\"glGetSamplerParameterIuiv\"))\n\tgpGetSamplerParameterfv = uintptr(getProcAddr(\"glGetSamplerParameterfv\"))\n\tgpGetSamplerParameteriv = uintptr(getProcAddr(\"glGetSamplerParameteriv\"))\n\tgpGetSemaphoreParameterui64vEXT = uintptr(getProcAddr(\"glGetSemaphoreParameterui64vEXT\"))\n\tgpGetSeparableFilterEXT = uintptr(getProcAddr(\"glGetSeparableFilterEXT\"))\n\tgpGetShaderInfoLog = uintptr(getProcAddr(\"glGetShaderInfoLog\"))\n\tif gpGetShaderInfoLog == 0 {\n\t\treturn errors.New(\"glGetShaderInfoLog\")\n\t}\n\tgpGetShaderPrecisionFormat = uintptr(getProcAddr(\"glGetShaderPrecisionFormat\"))\n\tgpGetShaderSource = uintptr(getProcAddr(\"glGetShaderSource\"))\n\tif gpGetShaderSource == 0 {\n\t\treturn errors.New(\"glGetShaderSource\")\n\t}\n\tgpGetShaderSourceARB = uintptr(getProcAddr(\"glGetShaderSourceARB\"))\n\tgpGetShaderiv = uintptr(getProcAddr(\"glGetShaderiv\"))\n\tif gpGetShaderiv == 0 {\n\t\treturn errors.New(\"glGetShaderiv\")\n\t}\n\tgpGetSharpenTexFuncSGIS = uintptr(getProcAddr(\"glGetSharpenTexFuncSGIS\"))\n\tgpGetStageIndexNV = uintptr(getProcAddr(\"glGetStageIndexNV\"))\n\tgpGetString = uintptr(getProcAddr(\"glGetString\"))\n\tif gpGetString == 0 {\n\t\treturn errors.New(\"glGetString\")\n\t}\n\tgpGetSubroutineIndex = uintptr(getProcAddr(\"glGetSubroutineIndex\"))\n\tgpGetSubroutineUniformLocation = uintptr(getProcAddr(\"glGetSubroutineUniformLocation\"))\n\tgpGetSynciv = uintptr(getProcAddr(\"glGetSynciv\"))\n\tgpGetTexBumpParameterfvATI = uintptr(getProcAddr(\"glGetTexBumpParameterfvATI\"))\n\tgpGetTexBumpParameterivATI = uintptr(getProcAddr(\"glGetTexBumpParameterivATI\"))\n\tgpGetTexEnvfv = uintptr(getProcAddr(\"glGetTexEnvfv\"))\n\tif gpGetTexEnvfv == 0 {\n\t\treturn errors.New(\"glGetTexEnvfv\")\n\t}\n\tgpGetTexEnviv = uintptr(getProcAddr(\"glGetTexEnviv\"))\n\tif gpGetTexEnviv == 0 {\n\t\treturn errors.New(\"glGetTexEnviv\")\n\t}\n\tgpGetTexEnvxvOES = uintptr(getProcAddr(\"glGetTexEnvxvOES\"))\n\tgpGetTexFilterFuncSGIS = uintptr(getProcAddr(\"glGetTexFilterFuncSGIS\"))\n\tgpGetTexGendv = uintptr(getProcAddr(\"glGetTexGendv\"))\n\tif gpGetTexGendv == 0 {\n\t\treturn errors.New(\"glGetTexGendv\")\n\t}\n\tgpGetTexGenfv = uintptr(getProcAddr(\"glGetTexGenfv\"))\n\tif gpGetTexGenfv == 0 {\n\t\treturn errors.New(\"glGetTexGenfv\")\n\t}\n\tgpGetTexGeniv = uintptr(getProcAddr(\"glGetTexGeniv\"))\n\tif gpGetTexGeniv == 0 {\n\t\treturn errors.New(\"glGetTexGeniv\")\n\t}\n\tgpGetTexGenxvOES = uintptr(getProcAddr(\"glGetTexGenxvOES\"))\n\tgpGetTexImage = uintptr(getProcAddr(\"glGetTexImage\"))\n\tif gpGetTexImage == 0 {\n\t\treturn errors.New(\"glGetTexImage\")\n\t}\n\tgpGetTexLevelParameterfv = uintptr(getProcAddr(\"glGetTexLevelParameterfv\"))\n\tif gpGetTexLevelParameterfv == 0 {\n\t\treturn errors.New(\"glGetTexLevelParameterfv\")\n\t}\n\tgpGetTexLevelParameteriv = uintptr(getProcAddr(\"glGetTexLevelParameteriv\"))\n\tif gpGetTexLevelParameteriv == 0 {\n\t\treturn errors.New(\"glGetTexLevelParameteriv\")\n\t}\n\tgpGetTexLevelParameterxvOES = uintptr(getProcAddr(\"glGetTexLevelParameterxvOES\"))\n\tgpGetTexParameterIivEXT = uintptr(getProcAddr(\"glGetTexParameterIivEXT\"))\n\tgpGetTexParameterIuivEXT = uintptr(getProcAddr(\"glGetTexParameterIuivEXT\"))\n\tgpGetTexParameterPointervAPPLE = uintptr(getProcAddr(\"glGetTexParameterPointervAPPLE\"))\n\tgpGetTexParameterfv = uintptr(getProcAddr(\"glGetTexParameterfv\"))\n\tif gpGetTexParameterfv == 0 {\n\t\treturn errors.New(\"glGetTexParameterfv\")\n\t}\n\tgpGetTexParameteriv = uintptr(getProcAddr(\"glGetTexParameteriv\"))\n\tif gpGetTexParameteriv == 0 {\n\t\treturn errors.New(\"glGetTexParameteriv\")\n\t}\n\tgpGetTexParameterxvOES = uintptr(getProcAddr(\"glGetTexParameterxvOES\"))\n\tgpGetTextureHandleARB = uintptr(getProcAddr(\"glGetTextureHandleARB\"))\n\tgpGetTextureHandleNV = uintptr(getProcAddr(\"glGetTextureHandleNV\"))\n\tgpGetTextureImage = uintptr(getProcAddr(\"glGetTextureImage\"))\n\tgpGetTextureImageEXT = uintptr(getProcAddr(\"glGetTextureImageEXT\"))\n\tgpGetTextureLevelParameterfv = uintptr(getProcAddr(\"glGetTextureLevelParameterfv\"))\n\tgpGetTextureLevelParameterfvEXT = uintptr(getProcAddr(\"glGetTextureLevelParameterfvEXT\"))\n\tgpGetTextureLevelParameteriv = uintptr(getProcAddr(\"glGetTextureLevelParameteriv\"))\n\tgpGetTextureLevelParameterivEXT = uintptr(getProcAddr(\"glGetTextureLevelParameterivEXT\"))\n\tgpGetTextureParameterIiv = uintptr(getProcAddr(\"glGetTextureParameterIiv\"))\n\tgpGetTextureParameterIivEXT = uintptr(getProcAddr(\"glGetTextureParameterIivEXT\"))\n\tgpGetTextureParameterIuiv = uintptr(getProcAddr(\"glGetTextureParameterIuiv\"))\n\tgpGetTextureParameterIuivEXT = uintptr(getProcAddr(\"glGetTextureParameterIuivEXT\"))\n\tgpGetTextureParameterfv = uintptr(getProcAddr(\"glGetTextureParameterfv\"))\n\tgpGetTextureParameterfvEXT = uintptr(getProcAddr(\"glGetTextureParameterfvEXT\"))\n\tgpGetTextureParameteriv = uintptr(getProcAddr(\"glGetTextureParameteriv\"))\n\tgpGetTextureParameterivEXT = uintptr(getProcAddr(\"glGetTextureParameterivEXT\"))\n\tgpGetTextureSamplerHandleARB = uintptr(getProcAddr(\"glGetTextureSamplerHandleARB\"))\n\tgpGetTextureSamplerHandleNV = uintptr(getProcAddr(\"glGetTextureSamplerHandleNV\"))\n\tgpGetTextureSubImage = uintptr(getProcAddr(\"glGetTextureSubImage\"))\n\tgpGetTrackMatrixivNV = uintptr(getProcAddr(\"glGetTrackMatrixivNV\"))\n\tgpGetTransformFeedbackVaryingEXT = uintptr(getProcAddr(\"glGetTransformFeedbackVaryingEXT\"))\n\tgpGetTransformFeedbackVaryingNV = uintptr(getProcAddr(\"glGetTransformFeedbackVaryingNV\"))\n\tgpGetTransformFeedbacki64_v = uintptr(getProcAddr(\"glGetTransformFeedbacki64_v\"))\n\tgpGetTransformFeedbacki_v = uintptr(getProcAddr(\"glGetTransformFeedbacki_v\"))\n\tgpGetTransformFeedbackiv = uintptr(getProcAddr(\"glGetTransformFeedbackiv\"))\n\tgpGetUniformBlockIndex = uintptr(getProcAddr(\"glGetUniformBlockIndex\"))\n\tgpGetUniformBufferSizeEXT = uintptr(getProcAddr(\"glGetUniformBufferSizeEXT\"))\n\tgpGetUniformIndices = uintptr(getProcAddr(\"glGetUniformIndices\"))\n\tgpGetUniformLocation = uintptr(getProcAddr(\"glGetUniformLocation\"))\n\tif gpGetUniformLocation == 0 {\n\t\treturn errors.New(\"glGetUniformLocation\")\n\t}\n\tgpGetUniformLocationARB = uintptr(getProcAddr(\"glGetUniformLocationARB\"))\n\tgpGetUniformOffsetEXT = uintptr(getProcAddr(\"glGetUniformOffsetEXT\"))\n\tgpGetUniformSubroutineuiv = uintptr(getProcAddr(\"glGetUniformSubroutineuiv\"))\n\tgpGetUniformdv = uintptr(getProcAddr(\"glGetUniformdv\"))\n\tgpGetUniformfv = uintptr(getProcAddr(\"glGetUniformfv\"))\n\tif gpGetUniformfv == 0 {\n\t\treturn errors.New(\"glGetUniformfv\")\n\t}\n\tgpGetUniformfvARB = uintptr(getProcAddr(\"glGetUniformfvARB\"))\n\tgpGetUniformi64vARB = uintptr(getProcAddr(\"glGetUniformi64vARB\"))\n\tgpGetUniformi64vNV = uintptr(getProcAddr(\"glGetUniformi64vNV\"))\n\tgpGetUniformiv = uintptr(getProcAddr(\"glGetUniformiv\"))\n\tif gpGetUniformiv == 0 {\n\t\treturn errors.New(\"glGetUniformiv\")\n\t}\n\tgpGetUniformivARB = uintptr(getProcAddr(\"glGetUniformivARB\"))\n\tgpGetUniformui64vARB = uintptr(getProcAddr(\"glGetUniformui64vARB\"))\n\tgpGetUniformui64vNV = uintptr(getProcAddr(\"glGetUniformui64vNV\"))\n\tgpGetUniformuivEXT = uintptr(getProcAddr(\"glGetUniformuivEXT\"))\n\tgpGetUnsignedBytei_vEXT = uintptr(getProcAddr(\"glGetUnsignedBytei_vEXT\"))\n\tgpGetUnsignedBytevEXT = uintptr(getProcAddr(\"glGetUnsignedBytevEXT\"))\n\tgpGetVariantArrayObjectfvATI = uintptr(getProcAddr(\"glGetVariantArrayObjectfvATI\"))\n\tgpGetVariantArrayObjectivATI = uintptr(getProcAddr(\"glGetVariantArrayObjectivATI\"))\n\tgpGetVariantBooleanvEXT = uintptr(getProcAddr(\"glGetVariantBooleanvEXT\"))\n\tgpGetVariantFloatvEXT = uintptr(getProcAddr(\"glGetVariantFloatvEXT\"))\n\tgpGetVariantIntegervEXT = uintptr(getProcAddr(\"glGetVariantIntegervEXT\"))\n\tgpGetVariantPointervEXT = uintptr(getProcAddr(\"glGetVariantPointervEXT\"))\n\tgpGetVaryingLocationNV = uintptr(getProcAddr(\"glGetVaryingLocationNV\"))\n\tgpGetVertexArrayIndexed64iv = uintptr(getProcAddr(\"glGetVertexArrayIndexed64iv\"))\n\tgpGetVertexArrayIndexediv = uintptr(getProcAddr(\"glGetVertexArrayIndexediv\"))\n\tgpGetVertexArrayIntegeri_vEXT = uintptr(getProcAddr(\"glGetVertexArrayIntegeri_vEXT\"))\n\tgpGetVertexArrayIntegervEXT = uintptr(getProcAddr(\"glGetVertexArrayIntegervEXT\"))\n\tgpGetVertexArrayPointeri_vEXT = uintptr(getProcAddr(\"glGetVertexArrayPointeri_vEXT\"))\n\tgpGetVertexArrayPointervEXT = uintptr(getProcAddr(\"glGetVertexArrayPointervEXT\"))\n\tgpGetVertexArrayiv = uintptr(getProcAddr(\"glGetVertexArrayiv\"))\n\tgpGetVertexAttribArrayObjectfvATI = uintptr(getProcAddr(\"glGetVertexAttribArrayObjectfvATI\"))\n\tgpGetVertexAttribArrayObjectivATI = uintptr(getProcAddr(\"glGetVertexAttribArrayObjectivATI\"))\n\tgpGetVertexAttribIivEXT = uintptr(getProcAddr(\"glGetVertexAttribIivEXT\"))\n\tgpGetVertexAttribIuivEXT = uintptr(getProcAddr(\"glGetVertexAttribIuivEXT\"))\n\tgpGetVertexAttribLdv = uintptr(getProcAddr(\"glGetVertexAttribLdv\"))\n\tgpGetVertexAttribLdvEXT = uintptr(getProcAddr(\"glGetVertexAttribLdvEXT\"))\n\tgpGetVertexAttribLi64vNV = uintptr(getProcAddr(\"glGetVertexAttribLi64vNV\"))\n\tgpGetVertexAttribLui64vARB = uintptr(getProcAddr(\"glGetVertexAttribLui64vARB\"))\n\tgpGetVertexAttribLui64vNV = uintptr(getProcAddr(\"glGetVertexAttribLui64vNV\"))\n\tgpGetVertexAttribPointerv = uintptr(getProcAddr(\"glGetVertexAttribPointerv\"))\n\tif gpGetVertexAttribPointerv == 0 {\n\t\treturn errors.New(\"glGetVertexAttribPointerv\")\n\t}\n\tgpGetVertexAttribPointervARB = uintptr(getProcAddr(\"glGetVertexAttribPointervARB\"))\n\tgpGetVertexAttribPointervNV = uintptr(getProcAddr(\"glGetVertexAttribPointervNV\"))\n\tgpGetVertexAttribdv = uintptr(getProcAddr(\"glGetVertexAttribdv\"))\n\tif gpGetVertexAttribdv == 0 {\n\t\treturn errors.New(\"glGetVertexAttribdv\")\n\t}\n\tgpGetVertexAttribdvARB = uintptr(getProcAddr(\"glGetVertexAttribdvARB\"))\n\tgpGetVertexAttribdvNV = uintptr(getProcAddr(\"glGetVertexAttribdvNV\"))\n\tgpGetVertexAttribfv = uintptr(getProcAddr(\"glGetVertexAttribfv\"))\n\tif gpGetVertexAttribfv == 0 {\n\t\treturn errors.New(\"glGetVertexAttribfv\")\n\t}\n\tgpGetVertexAttribfvARB = uintptr(getProcAddr(\"glGetVertexAttribfvARB\"))\n\tgpGetVertexAttribfvNV = uintptr(getProcAddr(\"glGetVertexAttribfvNV\"))\n\tgpGetVertexAttribiv = uintptr(getProcAddr(\"glGetVertexAttribiv\"))\n\tif gpGetVertexAttribiv == 0 {\n\t\treturn errors.New(\"glGetVertexAttribiv\")\n\t}\n\tgpGetVertexAttribivARB = uintptr(getProcAddr(\"glGetVertexAttribivARB\"))\n\tgpGetVertexAttribivNV = uintptr(getProcAddr(\"glGetVertexAttribivNV\"))\n\tgpGetVideoCaptureStreamdvNV = uintptr(getProcAddr(\"glGetVideoCaptureStreamdvNV\"))\n\tgpGetVideoCaptureStreamfvNV = uintptr(getProcAddr(\"glGetVideoCaptureStreamfvNV\"))\n\tgpGetVideoCaptureStreamivNV = uintptr(getProcAddr(\"glGetVideoCaptureStreamivNV\"))\n\tgpGetVideoCaptureivNV = uintptr(getProcAddr(\"glGetVideoCaptureivNV\"))\n\tgpGetVideoi64vNV = uintptr(getProcAddr(\"glGetVideoi64vNV\"))\n\tgpGetVideoivNV = uintptr(getProcAddr(\"glGetVideoivNV\"))\n\tgpGetVideoui64vNV = uintptr(getProcAddr(\"glGetVideoui64vNV\"))\n\tgpGetVideouivNV = uintptr(getProcAddr(\"glGetVideouivNV\"))\n\tgpGetVkProcAddrNV = uintptr(getProcAddr(\"glGetVkProcAddrNV\"))\n\tgpGetnCompressedTexImageARB = uintptr(getProcAddr(\"glGetnCompressedTexImageARB\"))\n\tgpGetnTexImageARB = uintptr(getProcAddr(\"glGetnTexImageARB\"))\n\tgpGetnUniformdvARB = uintptr(getProcAddr(\"glGetnUniformdvARB\"))\n\tgpGetnUniformfv = uintptr(getProcAddr(\"glGetnUniformfv\"))\n\tgpGetnUniformfvARB = uintptr(getProcAddr(\"glGetnUniformfvARB\"))\n\tgpGetnUniformfvKHR = uintptr(getProcAddr(\"glGetnUniformfvKHR\"))\n\tgpGetnUniformi64vARB = uintptr(getProcAddr(\"glGetnUniformi64vARB\"))\n\tgpGetnUniformiv = uintptr(getProcAddr(\"glGetnUniformiv\"))\n\tgpGetnUniformivARB = uintptr(getProcAddr(\"glGetnUniformivARB\"))\n\tgpGetnUniformivKHR = uintptr(getProcAddr(\"glGetnUniformivKHR\"))\n\tgpGetnUniformui64vARB = uintptr(getProcAddr(\"glGetnUniformui64vARB\"))\n\tgpGetnUniformuiv = uintptr(getProcAddr(\"glGetnUniformuiv\"))\n\tgpGetnUniformuivARB = uintptr(getProcAddr(\"glGetnUniformuivARB\"))\n\tgpGetnUniformuivKHR = uintptr(getProcAddr(\"glGetnUniformuivKHR\"))\n\tgpGlobalAlphaFactorbSUN = uintptr(getProcAddr(\"glGlobalAlphaFactorbSUN\"))\n\tgpGlobalAlphaFactordSUN = uintptr(getProcAddr(\"glGlobalAlphaFactordSUN\"))\n\tgpGlobalAlphaFactorfSUN = uintptr(getProcAddr(\"glGlobalAlphaFactorfSUN\"))\n\tgpGlobalAlphaFactoriSUN = uintptr(getProcAddr(\"glGlobalAlphaFactoriSUN\"))\n\tgpGlobalAlphaFactorsSUN = uintptr(getProcAddr(\"glGlobalAlphaFactorsSUN\"))\n\tgpGlobalAlphaFactorubSUN = uintptr(getProcAddr(\"glGlobalAlphaFactorubSUN\"))\n\tgpGlobalAlphaFactoruiSUN = uintptr(getProcAddr(\"glGlobalAlphaFactoruiSUN\"))\n\tgpGlobalAlphaFactorusSUN = uintptr(getProcAddr(\"glGlobalAlphaFactorusSUN\"))\n\tgpHint = uintptr(getProcAddr(\"glHint\"))\n\tif gpHint == 0 {\n\t\treturn errors.New(\"glHint\")\n\t}\n\tgpHintPGI = uintptr(getProcAddr(\"glHintPGI\"))\n\tgpHistogramEXT = uintptr(getProcAddr(\"glHistogramEXT\"))\n\tgpIglooInterfaceSGIX = uintptr(getProcAddr(\"glIglooInterfaceSGIX\"))\n\tgpImageTransformParameterfHP = uintptr(getProcAddr(\"glImageTransformParameterfHP\"))\n\tgpImageTransformParameterfvHP = uintptr(getProcAddr(\"glImageTransformParameterfvHP\"))\n\tgpImageTransformParameteriHP = uintptr(getProcAddr(\"glImageTransformParameteriHP\"))\n\tgpImageTransformParameterivHP = uintptr(getProcAddr(\"glImageTransformParameterivHP\"))\n\tgpImportMemoryFdEXT = uintptr(getProcAddr(\"glImportMemoryFdEXT\"))\n\tgpImportMemoryWin32HandleEXT = uintptr(getProcAddr(\"glImportMemoryWin32HandleEXT\"))\n\tgpImportMemoryWin32NameEXT = uintptr(getProcAddr(\"glImportMemoryWin32NameEXT\"))\n\tgpImportSemaphoreFdEXT = uintptr(getProcAddr(\"glImportSemaphoreFdEXT\"))\n\tgpImportSemaphoreWin32HandleEXT = uintptr(getProcAddr(\"glImportSemaphoreWin32HandleEXT\"))\n\tgpImportSemaphoreWin32NameEXT = uintptr(getProcAddr(\"glImportSemaphoreWin32NameEXT\"))\n\tgpImportSyncEXT = uintptr(getProcAddr(\"glImportSyncEXT\"))\n\tgpIndexFormatNV = uintptr(getProcAddr(\"glIndexFormatNV\"))\n\tgpIndexFuncEXT = uintptr(getProcAddr(\"glIndexFuncEXT\"))\n\tgpIndexMask = uintptr(getProcAddr(\"glIndexMask\"))\n\tif gpIndexMask == 0 {\n\t\treturn errors.New(\"glIndexMask\")\n\t}\n\tgpIndexMaterialEXT = uintptr(getProcAddr(\"glIndexMaterialEXT\"))\n\tgpIndexPointer = uintptr(getProcAddr(\"glIndexPointer\"))\n\tif gpIndexPointer == 0 {\n\t\treturn errors.New(\"glIndexPointer\")\n\t}\n\tgpIndexPointerEXT = uintptr(getProcAddr(\"glIndexPointerEXT\"))\n\tgpIndexPointerListIBM = uintptr(getProcAddr(\"glIndexPointerListIBM\"))\n\tgpIndexd = uintptr(getProcAddr(\"glIndexd\"))\n\tif gpIndexd == 0 {\n\t\treturn errors.New(\"glIndexd\")\n\t}\n\tgpIndexdv = uintptr(getProcAddr(\"glIndexdv\"))\n\tif gpIndexdv == 0 {\n\t\treturn errors.New(\"glIndexdv\")\n\t}\n\tgpIndexf = uintptr(getProcAddr(\"glIndexf\"))\n\tif gpIndexf == 0 {\n\t\treturn errors.New(\"glIndexf\")\n\t}\n\tgpIndexfv = uintptr(getProcAddr(\"glIndexfv\"))\n\tif gpIndexfv == 0 {\n\t\treturn errors.New(\"glIndexfv\")\n\t}\n\tgpIndexi = uintptr(getProcAddr(\"glIndexi\"))\n\tif gpIndexi == 0 {\n\t\treturn errors.New(\"glIndexi\")\n\t}\n\tgpIndexiv = uintptr(getProcAddr(\"glIndexiv\"))\n\tif gpIndexiv == 0 {\n\t\treturn errors.New(\"glIndexiv\")\n\t}\n\tgpIndexs = uintptr(getProcAddr(\"glIndexs\"))\n\tif gpIndexs == 0 {\n\t\treturn errors.New(\"glIndexs\")\n\t}\n\tgpIndexsv = uintptr(getProcAddr(\"glIndexsv\"))\n\tif gpIndexsv == 0 {\n\t\treturn errors.New(\"glIndexsv\")\n\t}\n\tgpIndexub = uintptr(getProcAddr(\"glIndexub\"))\n\tif gpIndexub == 0 {\n\t\treturn errors.New(\"glIndexub\")\n\t}\n\tgpIndexubv = uintptr(getProcAddr(\"glIndexubv\"))\n\tif gpIndexubv == 0 {\n\t\treturn errors.New(\"glIndexubv\")\n\t}\n\tgpIndexxOES = uintptr(getProcAddr(\"glIndexxOES\"))\n\tgpIndexxvOES = uintptr(getProcAddr(\"glIndexxvOES\"))\n\tgpInitNames = uintptr(getProcAddr(\"glInitNames\"))\n\tif gpInitNames == 0 {\n\t\treturn errors.New(\"glInitNames\")\n\t}\n\tgpInsertComponentEXT = uintptr(getProcAddr(\"glInsertComponentEXT\"))\n\tgpInsertEventMarkerEXT = uintptr(getProcAddr(\"glInsertEventMarkerEXT\"))\n\tgpInstrumentsBufferSGIX = uintptr(getProcAddr(\"glInstrumentsBufferSGIX\"))\n\tgpInterleavedArrays = uintptr(getProcAddr(\"glInterleavedArrays\"))\n\tif gpInterleavedArrays == 0 {\n\t\treturn errors.New(\"glInterleavedArrays\")\n\t}\n\tgpInterpolatePathsNV = uintptr(getProcAddr(\"glInterpolatePathsNV\"))\n\tgpInvalidateBufferData = uintptr(getProcAddr(\"glInvalidateBufferData\"))\n\tgpInvalidateBufferSubData = uintptr(getProcAddr(\"glInvalidateBufferSubData\"))\n\tgpInvalidateFramebuffer = uintptr(getProcAddr(\"glInvalidateFramebuffer\"))\n\tgpInvalidateNamedFramebufferData = uintptr(getProcAddr(\"glInvalidateNamedFramebufferData\"))\n\tgpInvalidateNamedFramebufferSubData = uintptr(getProcAddr(\"glInvalidateNamedFramebufferSubData\"))\n\tgpInvalidateSubFramebuffer = uintptr(getProcAddr(\"glInvalidateSubFramebuffer\"))\n\tgpInvalidateTexImage = uintptr(getProcAddr(\"glInvalidateTexImage\"))\n\tgpInvalidateTexSubImage = uintptr(getProcAddr(\"glInvalidateTexSubImage\"))\n\tgpIsAsyncMarkerSGIX = uintptr(getProcAddr(\"glIsAsyncMarkerSGIX\"))\n\tgpIsBuffer = uintptr(getProcAddr(\"glIsBuffer\"))\n\tif gpIsBuffer == 0 {\n\t\treturn errors.New(\"glIsBuffer\")\n\t}\n\tgpIsBufferARB = uintptr(getProcAddr(\"glIsBufferARB\"))\n\tgpIsBufferResidentNV = uintptr(getProcAddr(\"glIsBufferResidentNV\"))\n\tgpIsCommandListNV = uintptr(getProcAddr(\"glIsCommandListNV\"))\n\tgpIsEnabled = uintptr(getProcAddr(\"glIsEnabled\"))\n\tif gpIsEnabled == 0 {\n\t\treturn errors.New(\"glIsEnabled\")\n\t}\n\tgpIsEnabledIndexedEXT = uintptr(getProcAddr(\"glIsEnabledIndexedEXT\"))\n\tgpIsFenceAPPLE = uintptr(getProcAddr(\"glIsFenceAPPLE\"))\n\tgpIsFenceNV = uintptr(getProcAddr(\"glIsFenceNV\"))\n\tgpIsFramebuffer = uintptr(getProcAddr(\"glIsFramebuffer\"))\n\tgpIsFramebufferEXT = uintptr(getProcAddr(\"glIsFramebufferEXT\"))\n\tgpIsImageHandleResidentARB = uintptr(getProcAddr(\"glIsImageHandleResidentARB\"))\n\tgpIsImageHandleResidentNV = uintptr(getProcAddr(\"glIsImageHandleResidentNV\"))\n\tgpIsList = uintptr(getProcAddr(\"glIsList\"))\n\tif gpIsList == 0 {\n\t\treturn errors.New(\"glIsList\")\n\t}\n\tgpIsMemoryObjectEXT = uintptr(getProcAddr(\"glIsMemoryObjectEXT\"))\n\tgpIsNameAMD = uintptr(getProcAddr(\"glIsNameAMD\"))\n\tgpIsNamedBufferResidentNV = uintptr(getProcAddr(\"glIsNamedBufferResidentNV\"))\n\tgpIsNamedStringARB = uintptr(getProcAddr(\"glIsNamedStringARB\"))\n\tgpIsObjectBufferATI = uintptr(getProcAddr(\"glIsObjectBufferATI\"))\n\tgpIsOcclusionQueryNV = uintptr(getProcAddr(\"glIsOcclusionQueryNV\"))\n\tgpIsPathNV = uintptr(getProcAddr(\"glIsPathNV\"))\n\tgpIsPointInFillPathNV = uintptr(getProcAddr(\"glIsPointInFillPathNV\"))\n\tgpIsPointInStrokePathNV = uintptr(getProcAddr(\"glIsPointInStrokePathNV\"))\n\tgpIsProgram = uintptr(getProcAddr(\"glIsProgram\"))\n\tif gpIsProgram == 0 {\n\t\treturn errors.New(\"glIsProgram\")\n\t}\n\tgpIsProgramARB = uintptr(getProcAddr(\"glIsProgramARB\"))\n\tgpIsProgramNV = uintptr(getProcAddr(\"glIsProgramNV\"))\n\tgpIsProgramPipeline = uintptr(getProcAddr(\"glIsProgramPipeline\"))\n\tgpIsProgramPipelineEXT = uintptr(getProcAddr(\"glIsProgramPipelineEXT\"))\n\tgpIsQuery = uintptr(getProcAddr(\"glIsQuery\"))\n\tif gpIsQuery == 0 {\n\t\treturn errors.New(\"glIsQuery\")\n\t}\n\tgpIsQueryARB = uintptr(getProcAddr(\"glIsQueryARB\"))\n\tgpIsRenderbuffer = uintptr(getProcAddr(\"glIsRenderbuffer\"))\n\tgpIsRenderbufferEXT = uintptr(getProcAddr(\"glIsRenderbufferEXT\"))\n\tgpIsSampler = uintptr(getProcAddr(\"glIsSampler\"))\n\tgpIsSemaphoreEXT = uintptr(getProcAddr(\"glIsSemaphoreEXT\"))\n\tgpIsShader = uintptr(getProcAddr(\"glIsShader\"))\n\tif gpIsShader == 0 {\n\t\treturn errors.New(\"glIsShader\")\n\t}\n\tgpIsStateNV = uintptr(getProcAddr(\"glIsStateNV\"))\n\tgpIsSync = uintptr(getProcAddr(\"glIsSync\"))\n\tgpIsTexture = uintptr(getProcAddr(\"glIsTexture\"))\n\tif gpIsTexture == 0 {\n\t\treturn errors.New(\"glIsTexture\")\n\t}\n\tgpIsTextureEXT = uintptr(getProcAddr(\"glIsTextureEXT\"))\n\tgpIsTextureHandleResidentARB = uintptr(getProcAddr(\"glIsTextureHandleResidentARB\"))\n\tgpIsTextureHandleResidentNV = uintptr(getProcAddr(\"glIsTextureHandleResidentNV\"))\n\tgpIsTransformFeedback = uintptr(getProcAddr(\"glIsTransformFeedback\"))\n\tgpIsTransformFeedbackNV = uintptr(getProcAddr(\"glIsTransformFeedbackNV\"))\n\tgpIsVariantEnabledEXT = uintptr(getProcAddr(\"glIsVariantEnabledEXT\"))\n\tgpIsVertexArray = uintptr(getProcAddr(\"glIsVertexArray\"))\n\tgpIsVertexArrayAPPLE = uintptr(getProcAddr(\"glIsVertexArrayAPPLE\"))\n\tgpIsVertexAttribEnabledAPPLE = uintptr(getProcAddr(\"glIsVertexAttribEnabledAPPLE\"))\n\tgpLGPUCopyImageSubDataNVX = uintptr(getProcAddr(\"glLGPUCopyImageSubDataNVX\"))\n\tgpLGPUInterlockNVX = uintptr(getProcAddr(\"glLGPUInterlockNVX\"))\n\tgpLGPUNamedBufferSubDataNVX = uintptr(getProcAddr(\"glLGPUNamedBufferSubDataNVX\"))\n\tgpLabelObjectEXT = uintptr(getProcAddr(\"glLabelObjectEXT\"))\n\tgpLightEnviSGIX = uintptr(getProcAddr(\"glLightEnviSGIX\"))\n\tgpLightModelf = uintptr(getProcAddr(\"glLightModelf\"))\n\tif gpLightModelf == 0 {\n\t\treturn errors.New(\"glLightModelf\")\n\t}\n\tgpLightModelfv = uintptr(getProcAddr(\"glLightModelfv\"))\n\tif gpLightModelfv == 0 {\n\t\treturn errors.New(\"glLightModelfv\")\n\t}\n\tgpLightModeli = uintptr(getProcAddr(\"glLightModeli\"))\n\tif gpLightModeli == 0 {\n\t\treturn errors.New(\"glLightModeli\")\n\t}\n\tgpLightModeliv = uintptr(getProcAddr(\"glLightModeliv\"))\n\tif gpLightModeliv == 0 {\n\t\treturn errors.New(\"glLightModeliv\")\n\t}\n\tgpLightModelxOES = uintptr(getProcAddr(\"glLightModelxOES\"))\n\tgpLightModelxvOES = uintptr(getProcAddr(\"glLightModelxvOES\"))\n\tgpLightf = uintptr(getProcAddr(\"glLightf\"))\n\tif gpLightf == 0 {\n\t\treturn errors.New(\"glLightf\")\n\t}\n\tgpLightfv = uintptr(getProcAddr(\"glLightfv\"))\n\tif gpLightfv == 0 {\n\t\treturn errors.New(\"glLightfv\")\n\t}\n\tgpLighti = uintptr(getProcAddr(\"glLighti\"))\n\tif gpLighti == 0 {\n\t\treturn errors.New(\"glLighti\")\n\t}\n\tgpLightiv = uintptr(getProcAddr(\"glLightiv\"))\n\tif gpLightiv == 0 {\n\t\treturn errors.New(\"glLightiv\")\n\t}\n\tgpLightxOES = uintptr(getProcAddr(\"glLightxOES\"))\n\tgpLightxvOES = uintptr(getProcAddr(\"glLightxvOES\"))\n\tgpLineStipple = uintptr(getProcAddr(\"glLineStipple\"))\n\tif gpLineStipple == 0 {\n\t\treturn errors.New(\"glLineStipple\")\n\t}\n\tgpLineWidth = uintptr(getProcAddr(\"glLineWidth\"))\n\tif gpLineWidth == 0 {\n\t\treturn errors.New(\"glLineWidth\")\n\t}\n\tgpLineWidthxOES = uintptr(getProcAddr(\"glLineWidthxOES\"))\n\tgpLinkProgram = uintptr(getProcAddr(\"glLinkProgram\"))\n\tif gpLinkProgram == 0 {\n\t\treturn errors.New(\"glLinkProgram\")\n\t}\n\tgpLinkProgramARB = uintptr(getProcAddr(\"glLinkProgramARB\"))\n\tgpListBase = uintptr(getProcAddr(\"glListBase\"))\n\tif gpListBase == 0 {\n\t\treturn errors.New(\"glListBase\")\n\t}\n\tgpListDrawCommandsStatesClientNV = uintptr(getProcAddr(\"glListDrawCommandsStatesClientNV\"))\n\tgpListParameterfSGIX = uintptr(getProcAddr(\"glListParameterfSGIX\"))\n\tgpListParameterfvSGIX = uintptr(getProcAddr(\"glListParameterfvSGIX\"))\n\tgpListParameteriSGIX = uintptr(getProcAddr(\"glListParameteriSGIX\"))\n\tgpListParameterivSGIX = uintptr(getProcAddr(\"glListParameterivSGIX\"))\n\tgpLoadIdentity = uintptr(getProcAddr(\"glLoadIdentity\"))\n\tif gpLoadIdentity == 0 {\n\t\treturn errors.New(\"glLoadIdentity\")\n\t}\n\tgpLoadIdentityDeformationMapSGIX = uintptr(getProcAddr(\"glLoadIdentityDeformationMapSGIX\"))\n\tgpLoadMatrixd = uintptr(getProcAddr(\"glLoadMatrixd\"))\n\tif gpLoadMatrixd == 0 {\n\t\treturn errors.New(\"glLoadMatrixd\")\n\t}\n\tgpLoadMatrixf = uintptr(getProcAddr(\"glLoadMatrixf\"))\n\tif gpLoadMatrixf == 0 {\n\t\treturn errors.New(\"glLoadMatrixf\")\n\t}\n\tgpLoadMatrixxOES = uintptr(getProcAddr(\"glLoadMatrixxOES\"))\n\tgpLoadName = uintptr(getProcAddr(\"glLoadName\"))\n\tif gpLoadName == 0 {\n\t\treturn errors.New(\"glLoadName\")\n\t}\n\tgpLoadProgramNV = uintptr(getProcAddr(\"glLoadProgramNV\"))\n\tgpLoadTransposeMatrixd = uintptr(getProcAddr(\"glLoadTransposeMatrixd\"))\n\tif gpLoadTransposeMatrixd == 0 {\n\t\treturn errors.New(\"glLoadTransposeMatrixd\")\n\t}\n\tgpLoadTransposeMatrixdARB = uintptr(getProcAddr(\"glLoadTransposeMatrixdARB\"))\n\tgpLoadTransposeMatrixf = uintptr(getProcAddr(\"glLoadTransposeMatrixf\"))\n\tif gpLoadTransposeMatrixf == 0 {\n\t\treturn errors.New(\"glLoadTransposeMatrixf\")\n\t}\n\tgpLoadTransposeMatrixfARB = uintptr(getProcAddr(\"glLoadTransposeMatrixfARB\"))\n\tgpLoadTransposeMatrixxOES = uintptr(getProcAddr(\"glLoadTransposeMatrixxOES\"))\n\tgpLockArraysEXT = uintptr(getProcAddr(\"glLockArraysEXT\"))\n\tgpLogicOp = uintptr(getProcAddr(\"glLogicOp\"))\n\tif gpLogicOp == 0 {\n\t\treturn errors.New(\"glLogicOp\")\n\t}\n\tgpMakeBufferNonResidentNV = uintptr(getProcAddr(\"glMakeBufferNonResidentNV\"))\n\tgpMakeBufferResidentNV = uintptr(getProcAddr(\"glMakeBufferResidentNV\"))\n\tgpMakeImageHandleNonResidentARB = uintptr(getProcAddr(\"glMakeImageHandleNonResidentARB\"))\n\tgpMakeImageHandleNonResidentNV = uintptr(getProcAddr(\"glMakeImageHandleNonResidentNV\"))\n\tgpMakeImageHandleResidentARB = uintptr(getProcAddr(\"glMakeImageHandleResidentARB\"))\n\tgpMakeImageHandleResidentNV = uintptr(getProcAddr(\"glMakeImageHandleResidentNV\"))\n\tgpMakeNamedBufferNonResidentNV = uintptr(getProcAddr(\"glMakeNamedBufferNonResidentNV\"))\n\tgpMakeNamedBufferResidentNV = uintptr(getProcAddr(\"glMakeNamedBufferResidentNV\"))\n\tgpMakeTextureHandleNonResidentARB = uintptr(getProcAddr(\"glMakeTextureHandleNonResidentARB\"))\n\tgpMakeTextureHandleNonResidentNV = uintptr(getProcAddr(\"glMakeTextureHandleNonResidentNV\"))\n\tgpMakeTextureHandleResidentARB = uintptr(getProcAddr(\"glMakeTextureHandleResidentARB\"))\n\tgpMakeTextureHandleResidentNV = uintptr(getProcAddr(\"glMakeTextureHandleResidentNV\"))\n\tgpMap1d = uintptr(getProcAddr(\"glMap1d\"))\n\tif gpMap1d == 0 {\n\t\treturn errors.New(\"glMap1d\")\n\t}\n\tgpMap1f = uintptr(getProcAddr(\"glMap1f\"))\n\tif gpMap1f == 0 {\n\t\treturn errors.New(\"glMap1f\")\n\t}\n\tgpMap1xOES = uintptr(getProcAddr(\"glMap1xOES\"))\n\tgpMap2d = uintptr(getProcAddr(\"glMap2d\"))\n\tif gpMap2d == 0 {\n\t\treturn errors.New(\"glMap2d\")\n\t}\n\tgpMap2f = uintptr(getProcAddr(\"glMap2f\"))\n\tif gpMap2f == 0 {\n\t\treturn errors.New(\"glMap2f\")\n\t}\n\tgpMap2xOES = uintptr(getProcAddr(\"glMap2xOES\"))\n\tgpMapBuffer = uintptr(getProcAddr(\"glMapBuffer\"))\n\tif gpMapBuffer == 0 {\n\t\treturn errors.New(\"glMapBuffer\")\n\t}\n\tgpMapBufferARB = uintptr(getProcAddr(\"glMapBufferARB\"))\n\tgpMapBufferRange = uintptr(getProcAddr(\"glMapBufferRange\"))\n\tgpMapControlPointsNV = uintptr(getProcAddr(\"glMapControlPointsNV\"))\n\tgpMapGrid1d = uintptr(getProcAddr(\"glMapGrid1d\"))\n\tif gpMapGrid1d == 0 {\n\t\treturn errors.New(\"glMapGrid1d\")\n\t}\n\tgpMapGrid1f = uintptr(getProcAddr(\"glMapGrid1f\"))\n\tif gpMapGrid1f == 0 {\n\t\treturn errors.New(\"glMapGrid1f\")\n\t}\n\tgpMapGrid1xOES = uintptr(getProcAddr(\"glMapGrid1xOES\"))\n\tgpMapGrid2d = uintptr(getProcAddr(\"glMapGrid2d\"))\n\tif gpMapGrid2d == 0 {\n\t\treturn errors.New(\"glMapGrid2d\")\n\t}\n\tgpMapGrid2f = uintptr(getProcAddr(\"glMapGrid2f\"))\n\tif gpMapGrid2f == 0 {\n\t\treturn errors.New(\"glMapGrid2f\")\n\t}\n\tgpMapGrid2xOES = uintptr(getProcAddr(\"glMapGrid2xOES\"))\n\tgpMapNamedBuffer = uintptr(getProcAddr(\"glMapNamedBuffer\"))\n\tgpMapNamedBufferEXT = uintptr(getProcAddr(\"glMapNamedBufferEXT\"))\n\tgpMapNamedBufferRange = uintptr(getProcAddr(\"glMapNamedBufferRange\"))\n\tgpMapNamedBufferRangeEXT = uintptr(getProcAddr(\"glMapNamedBufferRangeEXT\"))\n\tgpMapObjectBufferATI = uintptr(getProcAddr(\"glMapObjectBufferATI\"))\n\tgpMapParameterfvNV = uintptr(getProcAddr(\"glMapParameterfvNV\"))\n\tgpMapParameterivNV = uintptr(getProcAddr(\"glMapParameterivNV\"))\n\tgpMapTexture2DINTEL = uintptr(getProcAddr(\"glMapTexture2DINTEL\"))\n\tgpMapVertexAttrib1dAPPLE = uintptr(getProcAddr(\"glMapVertexAttrib1dAPPLE\"))\n\tgpMapVertexAttrib1fAPPLE = uintptr(getProcAddr(\"glMapVertexAttrib1fAPPLE\"))\n\tgpMapVertexAttrib2dAPPLE = uintptr(getProcAddr(\"glMapVertexAttrib2dAPPLE\"))\n\tgpMapVertexAttrib2fAPPLE = uintptr(getProcAddr(\"glMapVertexAttrib2fAPPLE\"))\n\tgpMaterialf = uintptr(getProcAddr(\"glMaterialf\"))\n\tif gpMaterialf == 0 {\n\t\treturn errors.New(\"glMaterialf\")\n\t}\n\tgpMaterialfv = uintptr(getProcAddr(\"glMaterialfv\"))\n\tif gpMaterialfv == 0 {\n\t\treturn errors.New(\"glMaterialfv\")\n\t}\n\tgpMateriali = uintptr(getProcAddr(\"glMateriali\"))\n\tif gpMateriali == 0 {\n\t\treturn errors.New(\"glMateriali\")\n\t}\n\tgpMaterialiv = uintptr(getProcAddr(\"glMaterialiv\"))\n\tif gpMaterialiv == 0 {\n\t\treturn errors.New(\"glMaterialiv\")\n\t}\n\tgpMaterialxOES = uintptr(getProcAddr(\"glMaterialxOES\"))\n\tgpMaterialxvOES = uintptr(getProcAddr(\"glMaterialxvOES\"))\n\tgpMatrixFrustumEXT = uintptr(getProcAddr(\"glMatrixFrustumEXT\"))\n\tgpMatrixIndexPointerARB = uintptr(getProcAddr(\"glMatrixIndexPointerARB\"))\n\tgpMatrixIndexubvARB = uintptr(getProcAddr(\"glMatrixIndexubvARB\"))\n\tgpMatrixIndexuivARB = uintptr(getProcAddr(\"glMatrixIndexuivARB\"))\n\tgpMatrixIndexusvARB = uintptr(getProcAddr(\"glMatrixIndexusvARB\"))\n\tgpMatrixLoad3x2fNV = uintptr(getProcAddr(\"glMatrixLoad3x2fNV\"))\n\tgpMatrixLoad3x3fNV = uintptr(getProcAddr(\"glMatrixLoad3x3fNV\"))\n\tgpMatrixLoadIdentityEXT = uintptr(getProcAddr(\"glMatrixLoadIdentityEXT\"))\n\tgpMatrixLoadTranspose3x3fNV = uintptr(getProcAddr(\"glMatrixLoadTranspose3x3fNV\"))\n\tgpMatrixLoadTransposedEXT = uintptr(getProcAddr(\"glMatrixLoadTransposedEXT\"))\n\tgpMatrixLoadTransposefEXT = uintptr(getProcAddr(\"glMatrixLoadTransposefEXT\"))\n\tgpMatrixLoaddEXT = uintptr(getProcAddr(\"glMatrixLoaddEXT\"))\n\tgpMatrixLoadfEXT = uintptr(getProcAddr(\"glMatrixLoadfEXT\"))\n\tgpMatrixMode = uintptr(getProcAddr(\"glMatrixMode\"))\n\tif gpMatrixMode == 0 {\n\t\treturn errors.New(\"glMatrixMode\")\n\t}\n\tgpMatrixMult3x2fNV = uintptr(getProcAddr(\"glMatrixMult3x2fNV\"))\n\tgpMatrixMult3x3fNV = uintptr(getProcAddr(\"glMatrixMult3x3fNV\"))\n\tgpMatrixMultTranspose3x3fNV = uintptr(getProcAddr(\"glMatrixMultTranspose3x3fNV\"))\n\tgpMatrixMultTransposedEXT = uintptr(getProcAddr(\"glMatrixMultTransposedEXT\"))\n\tgpMatrixMultTransposefEXT = uintptr(getProcAddr(\"glMatrixMultTransposefEXT\"))\n\tgpMatrixMultdEXT = uintptr(getProcAddr(\"glMatrixMultdEXT\"))\n\tgpMatrixMultfEXT = uintptr(getProcAddr(\"glMatrixMultfEXT\"))\n\tgpMatrixOrthoEXT = uintptr(getProcAddr(\"glMatrixOrthoEXT\"))\n\tgpMatrixPopEXT = uintptr(getProcAddr(\"glMatrixPopEXT\"))\n\tgpMatrixPushEXT = uintptr(getProcAddr(\"glMatrixPushEXT\"))\n\tgpMatrixRotatedEXT = uintptr(getProcAddr(\"glMatrixRotatedEXT\"))\n\tgpMatrixRotatefEXT = uintptr(getProcAddr(\"glMatrixRotatefEXT\"))\n\tgpMatrixScaledEXT = uintptr(getProcAddr(\"glMatrixScaledEXT\"))\n\tgpMatrixScalefEXT = uintptr(getProcAddr(\"glMatrixScalefEXT\"))\n\tgpMatrixTranslatedEXT = uintptr(getProcAddr(\"glMatrixTranslatedEXT\"))\n\tgpMatrixTranslatefEXT = uintptr(getProcAddr(\"glMatrixTranslatefEXT\"))\n\tgpMaxShaderCompilerThreadsARB = uintptr(getProcAddr(\"glMaxShaderCompilerThreadsARB\"))\n\tgpMaxShaderCompilerThreadsKHR = uintptr(getProcAddr(\"glMaxShaderCompilerThreadsKHR\"))\n\tgpMemoryBarrier = uintptr(getProcAddr(\"glMemoryBarrier\"))\n\tgpMemoryBarrierByRegion = uintptr(getProcAddr(\"glMemoryBarrierByRegion\"))\n\tgpMemoryBarrierEXT = uintptr(getProcAddr(\"glMemoryBarrierEXT\"))\n\tgpMemoryObjectParameterivEXT = uintptr(getProcAddr(\"glMemoryObjectParameterivEXT\"))\n\tgpMinSampleShadingARB = uintptr(getProcAddr(\"glMinSampleShadingARB\"))\n\tgpMinmaxEXT = uintptr(getProcAddr(\"glMinmaxEXT\"))\n\tgpMultMatrixd = uintptr(getProcAddr(\"glMultMatrixd\"))\n\tif gpMultMatrixd == 0 {\n\t\treturn errors.New(\"glMultMatrixd\")\n\t}\n\tgpMultMatrixf = uintptr(getProcAddr(\"glMultMatrixf\"))\n\tif gpMultMatrixf == 0 {\n\t\treturn errors.New(\"glMultMatrixf\")\n\t}\n\tgpMultMatrixxOES = uintptr(getProcAddr(\"glMultMatrixxOES\"))\n\tgpMultTransposeMatrixd = uintptr(getProcAddr(\"glMultTransposeMatrixd\"))\n\tif gpMultTransposeMatrixd == 0 {\n\t\treturn errors.New(\"glMultTransposeMatrixd\")\n\t}\n\tgpMultTransposeMatrixdARB = uintptr(getProcAddr(\"glMultTransposeMatrixdARB\"))\n\tgpMultTransposeMatrixf = uintptr(getProcAddr(\"glMultTransposeMatrixf\"))\n\tif gpMultTransposeMatrixf == 0 {\n\t\treturn errors.New(\"glMultTransposeMatrixf\")\n\t}\n\tgpMultTransposeMatrixfARB = uintptr(getProcAddr(\"glMultTransposeMatrixfARB\"))\n\tgpMultTransposeMatrixxOES = uintptr(getProcAddr(\"glMultTransposeMatrixxOES\"))\n\tgpMultiDrawArrays = uintptr(getProcAddr(\"glMultiDrawArrays\"))\n\tif gpMultiDrawArrays == 0 {\n\t\treturn errors.New(\"glMultiDrawArrays\")\n\t}\n\tgpMultiDrawArraysEXT = uintptr(getProcAddr(\"glMultiDrawArraysEXT\"))\n\tgpMultiDrawArraysIndirect = uintptr(getProcAddr(\"glMultiDrawArraysIndirect\"))\n\tgpMultiDrawArraysIndirectAMD = uintptr(getProcAddr(\"glMultiDrawArraysIndirectAMD\"))\n\tgpMultiDrawArraysIndirectBindlessCountNV = uintptr(getProcAddr(\"glMultiDrawArraysIndirectBindlessCountNV\"))\n\tgpMultiDrawArraysIndirectBindlessNV = uintptr(getProcAddr(\"glMultiDrawArraysIndirectBindlessNV\"))\n\tgpMultiDrawArraysIndirectCountARB = uintptr(getProcAddr(\"glMultiDrawArraysIndirectCountARB\"))\n\tgpMultiDrawElementArrayAPPLE = uintptr(getProcAddr(\"glMultiDrawElementArrayAPPLE\"))\n\tgpMultiDrawElements = uintptr(getProcAddr(\"glMultiDrawElements\"))\n\tif gpMultiDrawElements == 0 {\n\t\treturn errors.New(\"glMultiDrawElements\")\n\t}\n\tgpMultiDrawElementsBaseVertex = uintptr(getProcAddr(\"glMultiDrawElementsBaseVertex\"))\n\tgpMultiDrawElementsEXT = uintptr(getProcAddr(\"glMultiDrawElementsEXT\"))\n\tgpMultiDrawElementsIndirect = uintptr(getProcAddr(\"glMultiDrawElementsIndirect\"))\n\tgpMultiDrawElementsIndirectAMD = uintptr(getProcAddr(\"glMultiDrawElementsIndirectAMD\"))\n\tgpMultiDrawElementsIndirectBindlessCountNV = uintptr(getProcAddr(\"glMultiDrawElementsIndirectBindlessCountNV\"))\n\tgpMultiDrawElementsIndirectBindlessNV = uintptr(getProcAddr(\"glMultiDrawElementsIndirectBindlessNV\"))\n\tgpMultiDrawElementsIndirectCountARB = uintptr(getProcAddr(\"glMultiDrawElementsIndirectCountARB\"))\n\tgpMultiDrawRangeElementArrayAPPLE = uintptr(getProcAddr(\"glMultiDrawRangeElementArrayAPPLE\"))\n\tgpMultiModeDrawArraysIBM = uintptr(getProcAddr(\"glMultiModeDrawArraysIBM\"))\n\tgpMultiModeDrawElementsIBM = uintptr(getProcAddr(\"glMultiModeDrawElementsIBM\"))\n\tgpMultiTexBufferEXT = uintptr(getProcAddr(\"glMultiTexBufferEXT\"))\n\tgpMultiTexCoord1bOES = uintptr(getProcAddr(\"glMultiTexCoord1bOES\"))\n\tgpMultiTexCoord1bvOES = uintptr(getProcAddr(\"glMultiTexCoord1bvOES\"))\n\tgpMultiTexCoord1d = uintptr(getProcAddr(\"glMultiTexCoord1d\"))\n\tif gpMultiTexCoord1d == 0 {\n\t\treturn errors.New(\"glMultiTexCoord1d\")\n\t}\n\tgpMultiTexCoord1dARB = uintptr(getProcAddr(\"glMultiTexCoord1dARB\"))\n\tgpMultiTexCoord1dv = uintptr(getProcAddr(\"glMultiTexCoord1dv\"))\n\tif gpMultiTexCoord1dv == 0 {\n\t\treturn errors.New(\"glMultiTexCoord1dv\")\n\t}\n\tgpMultiTexCoord1dvARB = uintptr(getProcAddr(\"glMultiTexCoord1dvARB\"))\n\tgpMultiTexCoord1f = uintptr(getProcAddr(\"glMultiTexCoord1f\"))\n\tif gpMultiTexCoord1f == 0 {\n\t\treturn errors.New(\"glMultiTexCoord1f\")\n\t}\n\tgpMultiTexCoord1fARB = uintptr(getProcAddr(\"glMultiTexCoord1fARB\"))\n\tgpMultiTexCoord1fv = uintptr(getProcAddr(\"glMultiTexCoord1fv\"))\n\tif gpMultiTexCoord1fv == 0 {\n\t\treturn errors.New(\"glMultiTexCoord1fv\")\n\t}\n\tgpMultiTexCoord1fvARB = uintptr(getProcAddr(\"glMultiTexCoord1fvARB\"))\n\tgpMultiTexCoord1hNV = uintptr(getProcAddr(\"glMultiTexCoord1hNV\"))\n\tgpMultiTexCoord1hvNV = uintptr(getProcAddr(\"glMultiTexCoord1hvNV\"))\n\tgpMultiTexCoord1i = uintptr(getProcAddr(\"glMultiTexCoord1i\"))\n\tif gpMultiTexCoord1i == 0 {\n\t\treturn errors.New(\"glMultiTexCoord1i\")\n\t}\n\tgpMultiTexCoord1iARB = uintptr(getProcAddr(\"glMultiTexCoord1iARB\"))\n\tgpMultiTexCoord1iv = uintptr(getProcAddr(\"glMultiTexCoord1iv\"))\n\tif gpMultiTexCoord1iv == 0 {\n\t\treturn errors.New(\"glMultiTexCoord1iv\")\n\t}\n\tgpMultiTexCoord1ivARB = uintptr(getProcAddr(\"glMultiTexCoord1ivARB\"))\n\tgpMultiTexCoord1s = uintptr(getProcAddr(\"glMultiTexCoord1s\"))\n\tif gpMultiTexCoord1s == 0 {\n\t\treturn errors.New(\"glMultiTexCoord1s\")\n\t}\n\tgpMultiTexCoord1sARB = uintptr(getProcAddr(\"glMultiTexCoord1sARB\"))\n\tgpMultiTexCoord1sv = uintptr(getProcAddr(\"glMultiTexCoord1sv\"))\n\tif gpMultiTexCoord1sv == 0 {\n\t\treturn errors.New(\"glMultiTexCoord1sv\")\n\t}\n\tgpMultiTexCoord1svARB = uintptr(getProcAddr(\"glMultiTexCoord1svARB\"))\n\tgpMultiTexCoord1xOES = uintptr(getProcAddr(\"glMultiTexCoord1xOES\"))\n\tgpMultiTexCoord1xvOES = uintptr(getProcAddr(\"glMultiTexCoord1xvOES\"))\n\tgpMultiTexCoord2bOES = uintptr(getProcAddr(\"glMultiTexCoord2bOES\"))\n\tgpMultiTexCoord2bvOES = uintptr(getProcAddr(\"glMultiTexCoord2bvOES\"))\n\tgpMultiTexCoord2d = uintptr(getProcAddr(\"glMultiTexCoord2d\"))\n\tif gpMultiTexCoord2d == 0 {\n\t\treturn errors.New(\"glMultiTexCoord2d\")\n\t}\n\tgpMultiTexCoord2dARB = uintptr(getProcAddr(\"glMultiTexCoord2dARB\"))\n\tgpMultiTexCoord2dv = uintptr(getProcAddr(\"glMultiTexCoord2dv\"))\n\tif gpMultiTexCoord2dv == 0 {\n\t\treturn errors.New(\"glMultiTexCoord2dv\")\n\t}\n\tgpMultiTexCoord2dvARB = uintptr(getProcAddr(\"glMultiTexCoord2dvARB\"))\n\tgpMultiTexCoord2f = uintptr(getProcAddr(\"glMultiTexCoord2f\"))\n\tif gpMultiTexCoord2f == 0 {\n\t\treturn errors.New(\"glMultiTexCoord2f\")\n\t}\n\tgpMultiTexCoord2fARB = uintptr(getProcAddr(\"glMultiTexCoord2fARB\"))\n\tgpMultiTexCoord2fv = uintptr(getProcAddr(\"glMultiTexCoord2fv\"))\n\tif gpMultiTexCoord2fv == 0 {\n\t\treturn errors.New(\"glMultiTexCoord2fv\")\n\t}\n\tgpMultiTexCoord2fvARB = uintptr(getProcAddr(\"glMultiTexCoord2fvARB\"))\n\tgpMultiTexCoord2hNV = uintptr(getProcAddr(\"glMultiTexCoord2hNV\"))\n\tgpMultiTexCoord2hvNV = uintptr(getProcAddr(\"glMultiTexCoord2hvNV\"))\n\tgpMultiTexCoord2i = uintptr(getProcAddr(\"glMultiTexCoord2i\"))\n\tif gpMultiTexCoord2i == 0 {\n\t\treturn errors.New(\"glMultiTexCoord2i\")\n\t}\n\tgpMultiTexCoord2iARB = uintptr(getProcAddr(\"glMultiTexCoord2iARB\"))\n\tgpMultiTexCoord2iv = uintptr(getProcAddr(\"glMultiTexCoord2iv\"))\n\tif gpMultiTexCoord2iv == 0 {\n\t\treturn errors.New(\"glMultiTexCoord2iv\")\n\t}\n\tgpMultiTexCoord2ivARB = uintptr(getProcAddr(\"glMultiTexCoord2ivARB\"))\n\tgpMultiTexCoord2s = uintptr(getProcAddr(\"glMultiTexCoord2s\"))\n\tif gpMultiTexCoord2s == 0 {\n\t\treturn errors.New(\"glMultiTexCoord2s\")\n\t}\n\tgpMultiTexCoord2sARB = uintptr(getProcAddr(\"glMultiTexCoord2sARB\"))\n\tgpMultiTexCoord2sv = uintptr(getProcAddr(\"glMultiTexCoord2sv\"))\n\tif gpMultiTexCoord2sv == 0 {\n\t\treturn errors.New(\"glMultiTexCoord2sv\")\n\t}\n\tgpMultiTexCoord2svARB = uintptr(getProcAddr(\"glMultiTexCoord2svARB\"))\n\tgpMultiTexCoord2xOES = uintptr(getProcAddr(\"glMultiTexCoord2xOES\"))\n\tgpMultiTexCoord2xvOES = uintptr(getProcAddr(\"glMultiTexCoord2xvOES\"))\n\tgpMultiTexCoord3bOES = uintptr(getProcAddr(\"glMultiTexCoord3bOES\"))\n\tgpMultiTexCoord3bvOES = uintptr(getProcAddr(\"glMultiTexCoord3bvOES\"))\n\tgpMultiTexCoord3d = uintptr(getProcAddr(\"glMultiTexCoord3d\"))\n\tif gpMultiTexCoord3d == 0 {\n\t\treturn errors.New(\"glMultiTexCoord3d\")\n\t}\n\tgpMultiTexCoord3dARB = uintptr(getProcAddr(\"glMultiTexCoord3dARB\"))\n\tgpMultiTexCoord3dv = uintptr(getProcAddr(\"glMultiTexCoord3dv\"))\n\tif gpMultiTexCoord3dv == 0 {\n\t\treturn errors.New(\"glMultiTexCoord3dv\")\n\t}\n\tgpMultiTexCoord3dvARB = uintptr(getProcAddr(\"glMultiTexCoord3dvARB\"))\n\tgpMultiTexCoord3f = uintptr(getProcAddr(\"glMultiTexCoord3f\"))\n\tif gpMultiTexCoord3f == 0 {\n\t\treturn errors.New(\"glMultiTexCoord3f\")\n\t}\n\tgpMultiTexCoord3fARB = uintptr(getProcAddr(\"glMultiTexCoord3fARB\"))\n\tgpMultiTexCoord3fv = uintptr(getProcAddr(\"glMultiTexCoord3fv\"))\n\tif gpMultiTexCoord3fv == 0 {\n\t\treturn errors.New(\"glMultiTexCoord3fv\")\n\t}\n\tgpMultiTexCoord3fvARB = uintptr(getProcAddr(\"glMultiTexCoord3fvARB\"))\n\tgpMultiTexCoord3hNV = uintptr(getProcAddr(\"glMultiTexCoord3hNV\"))\n\tgpMultiTexCoord3hvNV = uintptr(getProcAddr(\"glMultiTexCoord3hvNV\"))\n\tgpMultiTexCoord3i = uintptr(getProcAddr(\"glMultiTexCoord3i\"))\n\tif gpMultiTexCoord3i == 0 {\n\t\treturn errors.New(\"glMultiTexCoord3i\")\n\t}\n\tgpMultiTexCoord3iARB = uintptr(getProcAddr(\"glMultiTexCoord3iARB\"))\n\tgpMultiTexCoord3iv = uintptr(getProcAddr(\"glMultiTexCoord3iv\"))\n\tif gpMultiTexCoord3iv == 0 {\n\t\treturn errors.New(\"glMultiTexCoord3iv\")\n\t}\n\tgpMultiTexCoord3ivARB = uintptr(getProcAddr(\"glMultiTexCoord3ivARB\"))\n\tgpMultiTexCoord3s = uintptr(getProcAddr(\"glMultiTexCoord3s\"))\n\tif gpMultiTexCoord3s == 0 {\n\t\treturn errors.New(\"glMultiTexCoord3s\")\n\t}\n\tgpMultiTexCoord3sARB = uintptr(getProcAddr(\"glMultiTexCoord3sARB\"))\n\tgpMultiTexCoord3sv = uintptr(getProcAddr(\"glMultiTexCoord3sv\"))\n\tif gpMultiTexCoord3sv == 0 {\n\t\treturn errors.New(\"glMultiTexCoord3sv\")\n\t}\n\tgpMultiTexCoord3svARB = uintptr(getProcAddr(\"glMultiTexCoord3svARB\"))\n\tgpMultiTexCoord3xOES = uintptr(getProcAddr(\"glMultiTexCoord3xOES\"))\n\tgpMultiTexCoord3xvOES = uintptr(getProcAddr(\"glMultiTexCoord3xvOES\"))\n\tgpMultiTexCoord4bOES = uintptr(getProcAddr(\"glMultiTexCoord4bOES\"))\n\tgpMultiTexCoord4bvOES = uintptr(getProcAddr(\"glMultiTexCoord4bvOES\"))\n\tgpMultiTexCoord4d = uintptr(getProcAddr(\"glMultiTexCoord4d\"))\n\tif gpMultiTexCoord4d == 0 {\n\t\treturn errors.New(\"glMultiTexCoord4d\")\n\t}\n\tgpMultiTexCoord4dARB = uintptr(getProcAddr(\"glMultiTexCoord4dARB\"))\n\tgpMultiTexCoord4dv = uintptr(getProcAddr(\"glMultiTexCoord4dv\"))\n\tif gpMultiTexCoord4dv == 0 {\n\t\treturn errors.New(\"glMultiTexCoord4dv\")\n\t}\n\tgpMultiTexCoord4dvARB = uintptr(getProcAddr(\"glMultiTexCoord4dvARB\"))\n\tgpMultiTexCoord4f = uintptr(getProcAddr(\"glMultiTexCoord4f\"))\n\tif gpMultiTexCoord4f == 0 {\n\t\treturn errors.New(\"glMultiTexCoord4f\")\n\t}\n\tgpMultiTexCoord4fARB = uintptr(getProcAddr(\"glMultiTexCoord4fARB\"))\n\tgpMultiTexCoord4fv = uintptr(getProcAddr(\"glMultiTexCoord4fv\"))\n\tif gpMultiTexCoord4fv == 0 {\n\t\treturn errors.New(\"glMultiTexCoord4fv\")\n\t}\n\tgpMultiTexCoord4fvARB = uintptr(getProcAddr(\"glMultiTexCoord4fvARB\"))\n\tgpMultiTexCoord4hNV = uintptr(getProcAddr(\"glMultiTexCoord4hNV\"))\n\tgpMultiTexCoord4hvNV = uintptr(getProcAddr(\"glMultiTexCoord4hvNV\"))\n\tgpMultiTexCoord4i = uintptr(getProcAddr(\"glMultiTexCoord4i\"))\n\tif gpMultiTexCoord4i == 0 {\n\t\treturn errors.New(\"glMultiTexCoord4i\")\n\t}\n\tgpMultiTexCoord4iARB = uintptr(getProcAddr(\"glMultiTexCoord4iARB\"))\n\tgpMultiTexCoord4iv = uintptr(getProcAddr(\"glMultiTexCoord4iv\"))\n\tif gpMultiTexCoord4iv == 0 {\n\t\treturn errors.New(\"glMultiTexCoord4iv\")\n\t}\n\tgpMultiTexCoord4ivARB = uintptr(getProcAddr(\"glMultiTexCoord4ivARB\"))\n\tgpMultiTexCoord4s = uintptr(getProcAddr(\"glMultiTexCoord4s\"))\n\tif gpMultiTexCoord4s == 0 {\n\t\treturn errors.New(\"glMultiTexCoord4s\")\n\t}\n\tgpMultiTexCoord4sARB = uintptr(getProcAddr(\"glMultiTexCoord4sARB\"))\n\tgpMultiTexCoord4sv = uintptr(getProcAddr(\"glMultiTexCoord4sv\"))\n\tif gpMultiTexCoord4sv == 0 {\n\t\treturn errors.New(\"glMultiTexCoord4sv\")\n\t}\n\tgpMultiTexCoord4svARB = uintptr(getProcAddr(\"glMultiTexCoord4svARB\"))\n\tgpMultiTexCoord4xOES = uintptr(getProcAddr(\"glMultiTexCoord4xOES\"))\n\tgpMultiTexCoord4xvOES = uintptr(getProcAddr(\"glMultiTexCoord4xvOES\"))\n\tgpMultiTexCoordPointerEXT = uintptr(getProcAddr(\"glMultiTexCoordPointerEXT\"))\n\tgpMultiTexEnvfEXT = uintptr(getProcAddr(\"glMultiTexEnvfEXT\"))\n\tgpMultiTexEnvfvEXT = uintptr(getProcAddr(\"glMultiTexEnvfvEXT\"))\n\tgpMultiTexEnviEXT = uintptr(getProcAddr(\"glMultiTexEnviEXT\"))\n\tgpMultiTexEnvivEXT = uintptr(getProcAddr(\"glMultiTexEnvivEXT\"))\n\tgpMultiTexGendEXT = uintptr(getProcAddr(\"glMultiTexGendEXT\"))\n\tgpMultiTexGendvEXT = uintptr(getProcAddr(\"glMultiTexGendvEXT\"))\n\tgpMultiTexGenfEXT = uintptr(getProcAddr(\"glMultiTexGenfEXT\"))\n\tgpMultiTexGenfvEXT = uintptr(getProcAddr(\"glMultiTexGenfvEXT\"))\n\tgpMultiTexGeniEXT = uintptr(getProcAddr(\"glMultiTexGeniEXT\"))\n\tgpMultiTexGenivEXT = uintptr(getProcAddr(\"glMultiTexGenivEXT\"))\n\tgpMultiTexImage1DEXT = uintptr(getProcAddr(\"glMultiTexImage1DEXT\"))\n\tgpMultiTexImage2DEXT = uintptr(getProcAddr(\"glMultiTexImage2DEXT\"))\n\tgpMultiTexImage3DEXT = uintptr(getProcAddr(\"glMultiTexImage3DEXT\"))\n\tgpMultiTexParameterIivEXT = uintptr(getProcAddr(\"glMultiTexParameterIivEXT\"))\n\tgpMultiTexParameterIuivEXT = uintptr(getProcAddr(\"glMultiTexParameterIuivEXT\"))\n\tgpMultiTexParameterfEXT = uintptr(getProcAddr(\"glMultiTexParameterfEXT\"))\n\tgpMultiTexParameterfvEXT = uintptr(getProcAddr(\"glMultiTexParameterfvEXT\"))\n\tgpMultiTexParameteriEXT = uintptr(getProcAddr(\"glMultiTexParameteriEXT\"))\n\tgpMultiTexParameterivEXT = uintptr(getProcAddr(\"glMultiTexParameterivEXT\"))\n\tgpMultiTexRenderbufferEXT = uintptr(getProcAddr(\"glMultiTexRenderbufferEXT\"))\n\tgpMultiTexSubImage1DEXT = uintptr(getProcAddr(\"glMultiTexSubImage1DEXT\"))\n\tgpMultiTexSubImage2DEXT = uintptr(getProcAddr(\"glMultiTexSubImage2DEXT\"))\n\tgpMultiTexSubImage3DEXT = uintptr(getProcAddr(\"glMultiTexSubImage3DEXT\"))\n\tgpMulticastBarrierNV = uintptr(getProcAddr(\"glMulticastBarrierNV\"))\n\tgpMulticastBlitFramebufferNV = uintptr(getProcAddr(\"glMulticastBlitFramebufferNV\"))\n\tgpMulticastBufferSubDataNV = uintptr(getProcAddr(\"glMulticastBufferSubDataNV\"))\n\tgpMulticastCopyBufferSubDataNV = uintptr(getProcAddr(\"glMulticastCopyBufferSubDataNV\"))\n\tgpMulticastCopyImageSubDataNV = uintptr(getProcAddr(\"glMulticastCopyImageSubDataNV\"))\n\tgpMulticastFramebufferSampleLocationsfvNV = uintptr(getProcAddr(\"glMulticastFramebufferSampleLocationsfvNV\"))\n\tgpMulticastGetQueryObjecti64vNV = uintptr(getProcAddr(\"glMulticastGetQueryObjecti64vNV\"))\n\tgpMulticastGetQueryObjectivNV = uintptr(getProcAddr(\"glMulticastGetQueryObjectivNV\"))\n\tgpMulticastGetQueryObjectui64vNV = uintptr(getProcAddr(\"glMulticastGetQueryObjectui64vNV\"))\n\tgpMulticastGetQueryObjectuivNV = uintptr(getProcAddr(\"glMulticastGetQueryObjectuivNV\"))\n\tgpMulticastWaitSyncNV = uintptr(getProcAddr(\"glMulticastWaitSyncNV\"))\n\tgpNamedBufferData = uintptr(getProcAddr(\"glNamedBufferData\"))\n\tgpNamedBufferDataEXT = uintptr(getProcAddr(\"glNamedBufferDataEXT\"))\n\tgpNamedBufferPageCommitmentARB = uintptr(getProcAddr(\"glNamedBufferPageCommitmentARB\"))\n\tgpNamedBufferPageCommitmentEXT = uintptr(getProcAddr(\"glNamedBufferPageCommitmentEXT\"))\n\tgpNamedBufferStorage = uintptr(getProcAddr(\"glNamedBufferStorage\"))\n\tgpNamedBufferStorageEXT = uintptr(getProcAddr(\"glNamedBufferStorageEXT\"))\n\tgpNamedBufferStorageExternalEXT = uintptr(getProcAddr(\"glNamedBufferStorageExternalEXT\"))\n\tgpNamedBufferStorageMemEXT = uintptr(getProcAddr(\"glNamedBufferStorageMemEXT\"))\n\tgpNamedBufferSubData = uintptr(getProcAddr(\"glNamedBufferSubData\"))\n\tgpNamedBufferSubDataEXT = uintptr(getProcAddr(\"glNamedBufferSubDataEXT\"))\n\tgpNamedCopyBufferSubDataEXT = uintptr(getProcAddr(\"glNamedCopyBufferSubDataEXT\"))\n\tgpNamedFramebufferDrawBuffer = uintptr(getProcAddr(\"glNamedFramebufferDrawBuffer\"))\n\tgpNamedFramebufferDrawBuffers = uintptr(getProcAddr(\"glNamedFramebufferDrawBuffers\"))\n\tgpNamedFramebufferParameteri = uintptr(getProcAddr(\"glNamedFramebufferParameteri\"))\n\tgpNamedFramebufferParameteriEXT = uintptr(getProcAddr(\"glNamedFramebufferParameteriEXT\"))\n\tgpNamedFramebufferReadBuffer = uintptr(getProcAddr(\"glNamedFramebufferReadBuffer\"))\n\tgpNamedFramebufferRenderbuffer = uintptr(getProcAddr(\"glNamedFramebufferRenderbuffer\"))\n\tgpNamedFramebufferRenderbufferEXT = uintptr(getProcAddr(\"glNamedFramebufferRenderbufferEXT\"))\n\tgpNamedFramebufferSampleLocationsfvARB = uintptr(getProcAddr(\"glNamedFramebufferSampleLocationsfvARB\"))\n\tgpNamedFramebufferSampleLocationsfvNV = uintptr(getProcAddr(\"glNamedFramebufferSampleLocationsfvNV\"))\n\tgpNamedFramebufferSamplePositionsfvAMD = uintptr(getProcAddr(\"glNamedFramebufferSamplePositionsfvAMD\"))\n\tgpNamedFramebufferTexture = uintptr(getProcAddr(\"glNamedFramebufferTexture\"))\n\tgpNamedFramebufferTexture1DEXT = uintptr(getProcAddr(\"glNamedFramebufferTexture1DEXT\"))\n\tgpNamedFramebufferTexture2DEXT = uintptr(getProcAddr(\"glNamedFramebufferTexture2DEXT\"))\n\tgpNamedFramebufferTexture3DEXT = uintptr(getProcAddr(\"glNamedFramebufferTexture3DEXT\"))\n\tgpNamedFramebufferTextureEXT = uintptr(getProcAddr(\"glNamedFramebufferTextureEXT\"))\n\tgpNamedFramebufferTextureFaceEXT = uintptr(getProcAddr(\"glNamedFramebufferTextureFaceEXT\"))\n\tgpNamedFramebufferTextureLayer = uintptr(getProcAddr(\"glNamedFramebufferTextureLayer\"))\n\tgpNamedFramebufferTextureLayerEXT = uintptr(getProcAddr(\"glNamedFramebufferTextureLayerEXT\"))\n\tgpNamedProgramLocalParameter4dEXT = uintptr(getProcAddr(\"glNamedProgramLocalParameter4dEXT\"))\n\tgpNamedProgramLocalParameter4dvEXT = uintptr(getProcAddr(\"glNamedProgramLocalParameter4dvEXT\"))\n\tgpNamedProgramLocalParameter4fEXT = uintptr(getProcAddr(\"glNamedProgramLocalParameter4fEXT\"))\n\tgpNamedProgramLocalParameter4fvEXT = uintptr(getProcAddr(\"glNamedProgramLocalParameter4fvEXT\"))\n\tgpNamedProgramLocalParameterI4iEXT = uintptr(getProcAddr(\"glNamedProgramLocalParameterI4iEXT\"))\n\tgpNamedProgramLocalParameterI4ivEXT = uintptr(getProcAddr(\"glNamedProgramLocalParameterI4ivEXT\"))\n\tgpNamedProgramLocalParameterI4uiEXT = uintptr(getProcAddr(\"glNamedProgramLocalParameterI4uiEXT\"))\n\tgpNamedProgramLocalParameterI4uivEXT = uintptr(getProcAddr(\"glNamedProgramLocalParameterI4uivEXT\"))\n\tgpNamedProgramLocalParameters4fvEXT = uintptr(getProcAddr(\"glNamedProgramLocalParameters4fvEXT\"))\n\tgpNamedProgramLocalParametersI4ivEXT = uintptr(getProcAddr(\"glNamedProgramLocalParametersI4ivEXT\"))\n\tgpNamedProgramLocalParametersI4uivEXT = uintptr(getProcAddr(\"glNamedProgramLocalParametersI4uivEXT\"))\n\tgpNamedProgramStringEXT = uintptr(getProcAddr(\"glNamedProgramStringEXT\"))\n\tgpNamedRenderbufferStorage = uintptr(getProcAddr(\"glNamedRenderbufferStorage\"))\n\tgpNamedRenderbufferStorageEXT = uintptr(getProcAddr(\"glNamedRenderbufferStorageEXT\"))\n\tgpNamedRenderbufferStorageMultisample = uintptr(getProcAddr(\"glNamedRenderbufferStorageMultisample\"))\n\tgpNamedRenderbufferStorageMultisampleCoverageEXT = uintptr(getProcAddr(\"glNamedRenderbufferStorageMultisampleCoverageEXT\"))\n\tgpNamedRenderbufferStorageMultisampleEXT = uintptr(getProcAddr(\"glNamedRenderbufferStorageMultisampleEXT\"))\n\tgpNamedStringARB = uintptr(getProcAddr(\"glNamedStringARB\"))\n\tgpNewList = uintptr(getProcAddr(\"glNewList\"))\n\tif gpNewList == 0 {\n\t\treturn errors.New(\"glNewList\")\n\t}\n\tgpNewObjectBufferATI = uintptr(getProcAddr(\"glNewObjectBufferATI\"))\n\tgpNormal3b = uintptr(getProcAddr(\"glNormal3b\"))\n\tif gpNormal3b == 0 {\n\t\treturn errors.New(\"glNormal3b\")\n\t}\n\tgpNormal3bv = uintptr(getProcAddr(\"glNormal3bv\"))\n\tif gpNormal3bv == 0 {\n\t\treturn errors.New(\"glNormal3bv\")\n\t}\n\tgpNormal3d = uintptr(getProcAddr(\"glNormal3d\"))\n\tif gpNormal3d == 0 {\n\t\treturn errors.New(\"glNormal3d\")\n\t}\n\tgpNormal3dv = uintptr(getProcAddr(\"glNormal3dv\"))\n\tif gpNormal3dv == 0 {\n\t\treturn errors.New(\"glNormal3dv\")\n\t}\n\tgpNormal3f = uintptr(getProcAddr(\"glNormal3f\"))\n\tif gpNormal3f == 0 {\n\t\treturn errors.New(\"glNormal3f\")\n\t}\n\tgpNormal3fVertex3fSUN = uintptr(getProcAddr(\"glNormal3fVertex3fSUN\"))\n\tgpNormal3fVertex3fvSUN = uintptr(getProcAddr(\"glNormal3fVertex3fvSUN\"))\n\tgpNormal3fv = uintptr(getProcAddr(\"glNormal3fv\"))\n\tif gpNormal3fv == 0 {\n\t\treturn errors.New(\"glNormal3fv\")\n\t}\n\tgpNormal3hNV = uintptr(getProcAddr(\"glNormal3hNV\"))\n\tgpNormal3hvNV = uintptr(getProcAddr(\"glNormal3hvNV\"))\n\tgpNormal3i = uintptr(getProcAddr(\"glNormal3i\"))\n\tif gpNormal3i == 0 {\n\t\treturn errors.New(\"glNormal3i\")\n\t}\n\tgpNormal3iv = uintptr(getProcAddr(\"glNormal3iv\"))\n\tif gpNormal3iv == 0 {\n\t\treturn errors.New(\"glNormal3iv\")\n\t}\n\tgpNormal3s = uintptr(getProcAddr(\"glNormal3s\"))\n\tif gpNormal3s == 0 {\n\t\treturn errors.New(\"glNormal3s\")\n\t}\n\tgpNormal3sv = uintptr(getProcAddr(\"glNormal3sv\"))\n\tif gpNormal3sv == 0 {\n\t\treturn errors.New(\"glNormal3sv\")\n\t}\n\tgpNormal3xOES = uintptr(getProcAddr(\"glNormal3xOES\"))\n\tgpNormal3xvOES = uintptr(getProcAddr(\"glNormal3xvOES\"))\n\tgpNormalFormatNV = uintptr(getProcAddr(\"glNormalFormatNV\"))\n\tgpNormalPointer = uintptr(getProcAddr(\"glNormalPointer\"))\n\tif gpNormalPointer == 0 {\n\t\treturn errors.New(\"glNormalPointer\")\n\t}\n\tgpNormalPointerEXT = uintptr(getProcAddr(\"glNormalPointerEXT\"))\n\tgpNormalPointerListIBM = uintptr(getProcAddr(\"glNormalPointerListIBM\"))\n\tgpNormalPointervINTEL = uintptr(getProcAddr(\"glNormalPointervINTEL\"))\n\tgpNormalStream3bATI = uintptr(getProcAddr(\"glNormalStream3bATI\"))\n\tgpNormalStream3bvATI = uintptr(getProcAddr(\"glNormalStream3bvATI\"))\n\tgpNormalStream3dATI = uintptr(getProcAddr(\"glNormalStream3dATI\"))\n\tgpNormalStream3dvATI = uintptr(getProcAddr(\"glNormalStream3dvATI\"))\n\tgpNormalStream3fATI = uintptr(getProcAddr(\"glNormalStream3fATI\"))\n\tgpNormalStream3fvATI = uintptr(getProcAddr(\"glNormalStream3fvATI\"))\n\tgpNormalStream3iATI = uintptr(getProcAddr(\"glNormalStream3iATI\"))\n\tgpNormalStream3ivATI = uintptr(getProcAddr(\"glNormalStream3ivATI\"))\n\tgpNormalStream3sATI = uintptr(getProcAddr(\"glNormalStream3sATI\"))\n\tgpNormalStream3svATI = uintptr(getProcAddr(\"glNormalStream3svATI\"))\n\tgpObjectLabel = uintptr(getProcAddr(\"glObjectLabel\"))\n\tgpObjectLabelKHR = uintptr(getProcAddr(\"glObjectLabelKHR\"))\n\tgpObjectPtrLabel = uintptr(getProcAddr(\"glObjectPtrLabel\"))\n\tgpObjectPtrLabelKHR = uintptr(getProcAddr(\"glObjectPtrLabelKHR\"))\n\tgpObjectPurgeableAPPLE = uintptr(getProcAddr(\"glObjectPurgeableAPPLE\"))\n\tgpObjectUnpurgeableAPPLE = uintptr(getProcAddr(\"glObjectUnpurgeableAPPLE\"))\n\tgpOrtho = uintptr(getProcAddr(\"glOrtho\"))\n\tif gpOrtho == 0 {\n\t\treturn errors.New(\"glOrtho\")\n\t}\n\tgpOrthofOES = uintptr(getProcAddr(\"glOrthofOES\"))\n\tgpOrthoxOES = uintptr(getProcAddr(\"glOrthoxOES\"))\n\tgpPNTrianglesfATI = uintptr(getProcAddr(\"glPNTrianglesfATI\"))\n\tgpPNTrianglesiATI = uintptr(getProcAddr(\"glPNTrianglesiATI\"))\n\tgpPassTexCoordATI = uintptr(getProcAddr(\"glPassTexCoordATI\"))\n\tgpPassThrough = uintptr(getProcAddr(\"glPassThrough\"))\n\tif gpPassThrough == 0 {\n\t\treturn errors.New(\"glPassThrough\")\n\t}\n\tgpPassThroughxOES = uintptr(getProcAddr(\"glPassThroughxOES\"))\n\tgpPatchParameterfv = uintptr(getProcAddr(\"glPatchParameterfv\"))\n\tgpPatchParameteri = uintptr(getProcAddr(\"glPatchParameteri\"))\n\tgpPathCommandsNV = uintptr(getProcAddr(\"glPathCommandsNV\"))\n\tgpPathCoordsNV = uintptr(getProcAddr(\"glPathCoordsNV\"))\n\tgpPathCoverDepthFuncNV = uintptr(getProcAddr(\"glPathCoverDepthFuncNV\"))\n\tgpPathDashArrayNV = uintptr(getProcAddr(\"glPathDashArrayNV\"))\n\tgpPathGlyphIndexArrayNV = uintptr(getProcAddr(\"glPathGlyphIndexArrayNV\"))\n\tgpPathGlyphIndexRangeNV = uintptr(getProcAddr(\"glPathGlyphIndexRangeNV\"))\n\tgpPathGlyphRangeNV = uintptr(getProcAddr(\"glPathGlyphRangeNV\"))\n\tgpPathGlyphsNV = uintptr(getProcAddr(\"glPathGlyphsNV\"))\n\tgpPathMemoryGlyphIndexArrayNV = uintptr(getProcAddr(\"glPathMemoryGlyphIndexArrayNV\"))\n\tgpPathParameterfNV = uintptr(getProcAddr(\"glPathParameterfNV\"))\n\tgpPathParameterfvNV = uintptr(getProcAddr(\"glPathParameterfvNV\"))\n\tgpPathParameteriNV = uintptr(getProcAddr(\"glPathParameteriNV\"))\n\tgpPathParameterivNV = uintptr(getProcAddr(\"glPathParameterivNV\"))\n\tgpPathStencilDepthOffsetNV = uintptr(getProcAddr(\"glPathStencilDepthOffsetNV\"))\n\tgpPathStencilFuncNV = uintptr(getProcAddr(\"glPathStencilFuncNV\"))\n\tgpPathStringNV = uintptr(getProcAddr(\"glPathStringNV\"))\n\tgpPathSubCommandsNV = uintptr(getProcAddr(\"glPathSubCommandsNV\"))\n\tgpPathSubCoordsNV = uintptr(getProcAddr(\"glPathSubCoordsNV\"))\n\tgpPauseTransformFeedback = uintptr(getProcAddr(\"glPauseTransformFeedback\"))\n\tgpPauseTransformFeedbackNV = uintptr(getProcAddr(\"glPauseTransformFeedbackNV\"))\n\tgpPixelDataRangeNV = uintptr(getProcAddr(\"glPixelDataRangeNV\"))\n\tgpPixelMapfv = uintptr(getProcAddr(\"glPixelMapfv\"))\n\tif gpPixelMapfv == 0 {\n\t\treturn errors.New(\"glPixelMapfv\")\n\t}\n\tgpPixelMapuiv = uintptr(getProcAddr(\"glPixelMapuiv\"))\n\tif gpPixelMapuiv == 0 {\n\t\treturn errors.New(\"glPixelMapuiv\")\n\t}\n\tgpPixelMapusv = uintptr(getProcAddr(\"glPixelMapusv\"))\n\tif gpPixelMapusv == 0 {\n\t\treturn errors.New(\"glPixelMapusv\")\n\t}\n\tgpPixelMapx = uintptr(getProcAddr(\"glPixelMapx\"))\n\tgpPixelStoref = uintptr(getProcAddr(\"glPixelStoref\"))\n\tif gpPixelStoref == 0 {\n\t\treturn errors.New(\"glPixelStoref\")\n\t}\n\tgpPixelStorei = uintptr(getProcAddr(\"glPixelStorei\"))\n\tif gpPixelStorei == 0 {\n\t\treturn errors.New(\"glPixelStorei\")\n\t}\n\tgpPixelStorex = uintptr(getProcAddr(\"glPixelStorex\"))\n\tgpPixelTexGenParameterfSGIS = uintptr(getProcAddr(\"glPixelTexGenParameterfSGIS\"))\n\tgpPixelTexGenParameterfvSGIS = uintptr(getProcAddr(\"glPixelTexGenParameterfvSGIS\"))\n\tgpPixelTexGenParameteriSGIS = uintptr(getProcAddr(\"glPixelTexGenParameteriSGIS\"))\n\tgpPixelTexGenParameterivSGIS = uintptr(getProcAddr(\"glPixelTexGenParameterivSGIS\"))\n\tgpPixelTexGenSGIX = uintptr(getProcAddr(\"glPixelTexGenSGIX\"))\n\tgpPixelTransferf = uintptr(getProcAddr(\"glPixelTransferf\"))\n\tif gpPixelTransferf == 0 {\n\t\treturn errors.New(\"glPixelTransferf\")\n\t}\n\tgpPixelTransferi = uintptr(getProcAddr(\"glPixelTransferi\"))\n\tif gpPixelTransferi == 0 {\n\t\treturn errors.New(\"glPixelTransferi\")\n\t}\n\tgpPixelTransferxOES = uintptr(getProcAddr(\"glPixelTransferxOES\"))\n\tgpPixelTransformParameterfEXT = uintptr(getProcAddr(\"glPixelTransformParameterfEXT\"))\n\tgpPixelTransformParameterfvEXT = uintptr(getProcAddr(\"glPixelTransformParameterfvEXT\"))\n\tgpPixelTransformParameteriEXT = uintptr(getProcAddr(\"glPixelTransformParameteriEXT\"))\n\tgpPixelTransformParameterivEXT = uintptr(getProcAddr(\"glPixelTransformParameterivEXT\"))\n\tgpPixelZoom = uintptr(getProcAddr(\"glPixelZoom\"))\n\tif gpPixelZoom == 0 {\n\t\treturn errors.New(\"glPixelZoom\")\n\t}\n\tgpPixelZoomxOES = uintptr(getProcAddr(\"glPixelZoomxOES\"))\n\tgpPointAlongPathNV = uintptr(getProcAddr(\"glPointAlongPathNV\"))\n\tgpPointParameterf = uintptr(getProcAddr(\"glPointParameterf\"))\n\tif gpPointParameterf == 0 {\n\t\treturn errors.New(\"glPointParameterf\")\n\t}\n\tgpPointParameterfARB = uintptr(getProcAddr(\"glPointParameterfARB\"))\n\tgpPointParameterfEXT = uintptr(getProcAddr(\"glPointParameterfEXT\"))\n\tgpPointParameterfSGIS = uintptr(getProcAddr(\"glPointParameterfSGIS\"))\n\tgpPointParameterfv = uintptr(getProcAddr(\"glPointParameterfv\"))\n\tif gpPointParameterfv == 0 {\n\t\treturn errors.New(\"glPointParameterfv\")\n\t}\n\tgpPointParameterfvARB = uintptr(getProcAddr(\"glPointParameterfvARB\"))\n\tgpPointParameterfvEXT = uintptr(getProcAddr(\"glPointParameterfvEXT\"))\n\tgpPointParameterfvSGIS = uintptr(getProcAddr(\"glPointParameterfvSGIS\"))\n\tgpPointParameteri = uintptr(getProcAddr(\"glPointParameteri\"))\n\tif gpPointParameteri == 0 {\n\t\treturn errors.New(\"glPointParameteri\")\n\t}\n\tgpPointParameteriNV = uintptr(getProcAddr(\"glPointParameteriNV\"))\n\tgpPointParameteriv = uintptr(getProcAddr(\"glPointParameteriv\"))\n\tif gpPointParameteriv == 0 {\n\t\treturn errors.New(\"glPointParameteriv\")\n\t}\n\tgpPointParameterivNV = uintptr(getProcAddr(\"glPointParameterivNV\"))\n\tgpPointParameterxOES = uintptr(getProcAddr(\"glPointParameterxOES\"))\n\tgpPointParameterxvOES = uintptr(getProcAddr(\"glPointParameterxvOES\"))\n\tgpPointSize = uintptr(getProcAddr(\"glPointSize\"))\n\tif gpPointSize == 0 {\n\t\treturn errors.New(\"glPointSize\")\n\t}\n\tgpPointSizexOES = uintptr(getProcAddr(\"glPointSizexOES\"))\n\tgpPollAsyncSGIX = uintptr(getProcAddr(\"glPollAsyncSGIX\"))\n\tgpPollInstrumentsSGIX = uintptr(getProcAddr(\"glPollInstrumentsSGIX\"))\n\tgpPolygonMode = uintptr(getProcAddr(\"glPolygonMode\"))\n\tif gpPolygonMode == 0 {\n\t\treturn errors.New(\"glPolygonMode\")\n\t}\n\tgpPolygonOffset = uintptr(getProcAddr(\"glPolygonOffset\"))\n\tif gpPolygonOffset == 0 {\n\t\treturn errors.New(\"glPolygonOffset\")\n\t}\n\tgpPolygonOffsetClamp = uintptr(getProcAddr(\"glPolygonOffsetClamp\"))\n\tgpPolygonOffsetClampEXT = uintptr(getProcAddr(\"glPolygonOffsetClampEXT\"))\n\tgpPolygonOffsetEXT = uintptr(getProcAddr(\"glPolygonOffsetEXT\"))\n\tgpPolygonOffsetxOES = uintptr(getProcAddr(\"glPolygonOffsetxOES\"))\n\tgpPolygonStipple = uintptr(getProcAddr(\"glPolygonStipple\"))\n\tif gpPolygonStipple == 0 {\n\t\treturn errors.New(\"glPolygonStipple\")\n\t}\n\tgpPopAttrib = uintptr(getProcAddr(\"glPopAttrib\"))\n\tif gpPopAttrib == 0 {\n\t\treturn errors.New(\"glPopAttrib\")\n\t}\n\tgpPopClientAttrib = uintptr(getProcAddr(\"glPopClientAttrib\"))\n\tif gpPopClientAttrib == 0 {\n\t\treturn errors.New(\"glPopClientAttrib\")\n\t}\n\tgpPopDebugGroup = uintptr(getProcAddr(\"glPopDebugGroup\"))\n\tgpPopDebugGroupKHR = uintptr(getProcAddr(\"glPopDebugGroupKHR\"))\n\tgpPopGroupMarkerEXT = uintptr(getProcAddr(\"glPopGroupMarkerEXT\"))\n\tgpPopMatrix = uintptr(getProcAddr(\"glPopMatrix\"))\n\tif gpPopMatrix == 0 {\n\t\treturn errors.New(\"glPopMatrix\")\n\t}\n\tgpPopName = uintptr(getProcAddr(\"glPopName\"))\n\tif gpPopName == 0 {\n\t\treturn errors.New(\"glPopName\")\n\t}\n\tgpPresentFrameDualFillNV = uintptr(getProcAddr(\"glPresentFrameDualFillNV\"))\n\tgpPresentFrameKeyedNV = uintptr(getProcAddr(\"glPresentFrameKeyedNV\"))\n\tgpPrimitiveBoundingBoxARB = uintptr(getProcAddr(\"glPrimitiveBoundingBoxARB\"))\n\tgpPrimitiveRestartIndexNV = uintptr(getProcAddr(\"glPrimitiveRestartIndexNV\"))\n\tgpPrimitiveRestartNV = uintptr(getProcAddr(\"glPrimitiveRestartNV\"))\n\tgpPrioritizeTextures = uintptr(getProcAddr(\"glPrioritizeTextures\"))\n\tif gpPrioritizeTextures == 0 {\n\t\treturn errors.New(\"glPrioritizeTextures\")\n\t}\n\tgpPrioritizeTexturesEXT = uintptr(getProcAddr(\"glPrioritizeTexturesEXT\"))\n\tgpPrioritizeTexturesxOES = uintptr(getProcAddr(\"glPrioritizeTexturesxOES\"))\n\tgpProgramBinary = uintptr(getProcAddr(\"glProgramBinary\"))\n\tgpProgramBufferParametersIivNV = uintptr(getProcAddr(\"glProgramBufferParametersIivNV\"))\n\tgpProgramBufferParametersIuivNV = uintptr(getProcAddr(\"glProgramBufferParametersIuivNV\"))\n\tgpProgramBufferParametersfvNV = uintptr(getProcAddr(\"glProgramBufferParametersfvNV\"))\n\tgpProgramEnvParameter4dARB = uintptr(getProcAddr(\"glProgramEnvParameter4dARB\"))\n\tgpProgramEnvParameter4dvARB = uintptr(getProcAddr(\"glProgramEnvParameter4dvARB\"))\n\tgpProgramEnvParameter4fARB = uintptr(getProcAddr(\"glProgramEnvParameter4fARB\"))\n\tgpProgramEnvParameter4fvARB = uintptr(getProcAddr(\"glProgramEnvParameter4fvARB\"))\n\tgpProgramEnvParameterI4iNV = uintptr(getProcAddr(\"glProgramEnvParameterI4iNV\"))\n\tgpProgramEnvParameterI4ivNV = uintptr(getProcAddr(\"glProgramEnvParameterI4ivNV\"))\n\tgpProgramEnvParameterI4uiNV = uintptr(getProcAddr(\"glProgramEnvParameterI4uiNV\"))\n\tgpProgramEnvParameterI4uivNV = uintptr(getProcAddr(\"glProgramEnvParameterI4uivNV\"))\n\tgpProgramEnvParameters4fvEXT = uintptr(getProcAddr(\"glProgramEnvParameters4fvEXT\"))\n\tgpProgramEnvParametersI4ivNV = uintptr(getProcAddr(\"glProgramEnvParametersI4ivNV\"))\n\tgpProgramEnvParametersI4uivNV = uintptr(getProcAddr(\"glProgramEnvParametersI4uivNV\"))\n\tgpProgramLocalParameter4dARB = uintptr(getProcAddr(\"glProgramLocalParameter4dARB\"))\n\tgpProgramLocalParameter4dvARB = uintptr(getProcAddr(\"glProgramLocalParameter4dvARB\"))\n\tgpProgramLocalParameter4fARB = uintptr(getProcAddr(\"glProgramLocalParameter4fARB\"))\n\tgpProgramLocalParameter4fvARB = uintptr(getProcAddr(\"glProgramLocalParameter4fvARB\"))\n\tgpProgramLocalParameterI4iNV = uintptr(getProcAddr(\"glProgramLocalParameterI4iNV\"))\n\tgpProgramLocalParameterI4ivNV = uintptr(getProcAddr(\"glProgramLocalParameterI4ivNV\"))\n\tgpProgramLocalParameterI4uiNV = uintptr(getProcAddr(\"glProgramLocalParameterI4uiNV\"))\n\tgpProgramLocalParameterI4uivNV = uintptr(getProcAddr(\"glProgramLocalParameterI4uivNV\"))\n\tgpProgramLocalParameters4fvEXT = uintptr(getProcAddr(\"glProgramLocalParameters4fvEXT\"))\n\tgpProgramLocalParametersI4ivNV = uintptr(getProcAddr(\"glProgramLocalParametersI4ivNV\"))\n\tgpProgramLocalParametersI4uivNV = uintptr(getProcAddr(\"glProgramLocalParametersI4uivNV\"))\n\tgpProgramNamedParameter4dNV = uintptr(getProcAddr(\"glProgramNamedParameter4dNV\"))\n\tgpProgramNamedParameter4dvNV = uintptr(getProcAddr(\"glProgramNamedParameter4dvNV\"))\n\tgpProgramNamedParameter4fNV = uintptr(getProcAddr(\"glProgramNamedParameter4fNV\"))\n\tgpProgramNamedParameter4fvNV = uintptr(getProcAddr(\"glProgramNamedParameter4fvNV\"))\n\tgpProgramParameter4dNV = uintptr(getProcAddr(\"glProgramParameter4dNV\"))\n\tgpProgramParameter4dvNV = uintptr(getProcAddr(\"glProgramParameter4dvNV\"))\n\tgpProgramParameter4fNV = uintptr(getProcAddr(\"glProgramParameter4fNV\"))\n\tgpProgramParameter4fvNV = uintptr(getProcAddr(\"glProgramParameter4fvNV\"))\n\tgpProgramParameteri = uintptr(getProcAddr(\"glProgramParameteri\"))\n\tgpProgramParameteriARB = uintptr(getProcAddr(\"glProgramParameteriARB\"))\n\tgpProgramParameteriEXT = uintptr(getProcAddr(\"glProgramParameteriEXT\"))\n\tgpProgramParameters4dvNV = uintptr(getProcAddr(\"glProgramParameters4dvNV\"))\n\tgpProgramParameters4fvNV = uintptr(getProcAddr(\"glProgramParameters4fvNV\"))\n\tgpProgramPathFragmentInputGenNV = uintptr(getProcAddr(\"glProgramPathFragmentInputGenNV\"))\n\tgpProgramStringARB = uintptr(getProcAddr(\"glProgramStringARB\"))\n\tgpProgramSubroutineParametersuivNV = uintptr(getProcAddr(\"glProgramSubroutineParametersuivNV\"))\n\tgpProgramUniform1d = uintptr(getProcAddr(\"glProgramUniform1d\"))\n\tgpProgramUniform1dEXT = uintptr(getProcAddr(\"glProgramUniform1dEXT\"))\n\tgpProgramUniform1dv = uintptr(getProcAddr(\"glProgramUniform1dv\"))\n\tgpProgramUniform1dvEXT = uintptr(getProcAddr(\"glProgramUniform1dvEXT\"))\n\tgpProgramUniform1f = uintptr(getProcAddr(\"glProgramUniform1f\"))\n\tgpProgramUniform1fEXT = uintptr(getProcAddr(\"glProgramUniform1fEXT\"))\n\tgpProgramUniform1fv = uintptr(getProcAddr(\"glProgramUniform1fv\"))\n\tgpProgramUniform1fvEXT = uintptr(getProcAddr(\"glProgramUniform1fvEXT\"))\n\tgpProgramUniform1i = uintptr(getProcAddr(\"glProgramUniform1i\"))\n\tgpProgramUniform1i64ARB = uintptr(getProcAddr(\"glProgramUniform1i64ARB\"))\n\tgpProgramUniform1i64NV = uintptr(getProcAddr(\"glProgramUniform1i64NV\"))\n\tgpProgramUniform1i64vARB = uintptr(getProcAddr(\"glProgramUniform1i64vARB\"))\n\tgpProgramUniform1i64vNV = uintptr(getProcAddr(\"glProgramUniform1i64vNV\"))\n\tgpProgramUniform1iEXT = uintptr(getProcAddr(\"glProgramUniform1iEXT\"))\n\tgpProgramUniform1iv = uintptr(getProcAddr(\"glProgramUniform1iv\"))\n\tgpProgramUniform1ivEXT = uintptr(getProcAddr(\"glProgramUniform1ivEXT\"))\n\tgpProgramUniform1ui = uintptr(getProcAddr(\"glProgramUniform1ui\"))\n\tgpProgramUniform1ui64ARB = uintptr(getProcAddr(\"glProgramUniform1ui64ARB\"))\n\tgpProgramUniform1ui64NV = uintptr(getProcAddr(\"glProgramUniform1ui64NV\"))\n\tgpProgramUniform1ui64vARB = uintptr(getProcAddr(\"glProgramUniform1ui64vARB\"))\n\tgpProgramUniform1ui64vNV = uintptr(getProcAddr(\"glProgramUniform1ui64vNV\"))\n\tgpProgramUniform1uiEXT = uintptr(getProcAddr(\"glProgramUniform1uiEXT\"))\n\tgpProgramUniform1uiv = uintptr(getProcAddr(\"glProgramUniform1uiv\"))\n\tgpProgramUniform1uivEXT = uintptr(getProcAddr(\"glProgramUniform1uivEXT\"))\n\tgpProgramUniform2d = uintptr(getProcAddr(\"glProgramUniform2d\"))\n\tgpProgramUniform2dEXT = uintptr(getProcAddr(\"glProgramUniform2dEXT\"))\n\tgpProgramUniform2dv = uintptr(getProcAddr(\"glProgramUniform2dv\"))\n\tgpProgramUniform2dvEXT = uintptr(getProcAddr(\"glProgramUniform2dvEXT\"))\n\tgpProgramUniform2f = uintptr(getProcAddr(\"glProgramUniform2f\"))\n\tgpProgramUniform2fEXT = uintptr(getProcAddr(\"glProgramUniform2fEXT\"))\n\tgpProgramUniform2fv = uintptr(getProcAddr(\"glProgramUniform2fv\"))\n\tgpProgramUniform2fvEXT = uintptr(getProcAddr(\"glProgramUniform2fvEXT\"))\n\tgpProgramUniform2i = uintptr(getProcAddr(\"glProgramUniform2i\"))\n\tgpProgramUniform2i64ARB = uintptr(getProcAddr(\"glProgramUniform2i64ARB\"))\n\tgpProgramUniform2i64NV = uintptr(getProcAddr(\"glProgramUniform2i64NV\"))\n\tgpProgramUniform2i64vARB = uintptr(getProcAddr(\"glProgramUniform2i64vARB\"))\n\tgpProgramUniform2i64vNV = uintptr(getProcAddr(\"glProgramUniform2i64vNV\"))\n\tgpProgramUniform2iEXT = uintptr(getProcAddr(\"glProgramUniform2iEXT\"))\n\tgpProgramUniform2iv = uintptr(getProcAddr(\"glProgramUniform2iv\"))\n\tgpProgramUniform2ivEXT = uintptr(getProcAddr(\"glProgramUniform2ivEXT\"))\n\tgpProgramUniform2ui = uintptr(getProcAddr(\"glProgramUniform2ui\"))\n\tgpProgramUniform2ui64ARB = uintptr(getProcAddr(\"glProgramUniform2ui64ARB\"))\n\tgpProgramUniform2ui64NV = uintptr(getProcAddr(\"glProgramUniform2ui64NV\"))\n\tgpProgramUniform2ui64vARB = uintptr(getProcAddr(\"glProgramUniform2ui64vARB\"))\n\tgpProgramUniform2ui64vNV = uintptr(getProcAddr(\"glProgramUniform2ui64vNV\"))\n\tgpProgramUniform2uiEXT = uintptr(getProcAddr(\"glProgramUniform2uiEXT\"))\n\tgpProgramUniform2uiv = uintptr(getProcAddr(\"glProgramUniform2uiv\"))\n\tgpProgramUniform2uivEXT = uintptr(getProcAddr(\"glProgramUniform2uivEXT\"))\n\tgpProgramUniform3d = uintptr(getProcAddr(\"glProgramUniform3d\"))\n\tgpProgramUniform3dEXT = uintptr(getProcAddr(\"glProgramUniform3dEXT\"))\n\tgpProgramUniform3dv = uintptr(getProcAddr(\"glProgramUniform3dv\"))\n\tgpProgramUniform3dvEXT = uintptr(getProcAddr(\"glProgramUniform3dvEXT\"))\n\tgpProgramUniform3f = uintptr(getProcAddr(\"glProgramUniform3f\"))\n\tgpProgramUniform3fEXT = uintptr(getProcAddr(\"glProgramUniform3fEXT\"))\n\tgpProgramUniform3fv = uintptr(getProcAddr(\"glProgramUniform3fv\"))\n\tgpProgramUniform3fvEXT = uintptr(getProcAddr(\"glProgramUniform3fvEXT\"))\n\tgpProgramUniform3i = uintptr(getProcAddr(\"glProgramUniform3i\"))\n\tgpProgramUniform3i64ARB = uintptr(getProcAddr(\"glProgramUniform3i64ARB\"))\n\tgpProgramUniform3i64NV = uintptr(getProcAddr(\"glProgramUniform3i64NV\"))\n\tgpProgramUniform3i64vARB = uintptr(getProcAddr(\"glProgramUniform3i64vARB\"))\n\tgpProgramUniform3i64vNV = uintptr(getProcAddr(\"glProgramUniform3i64vNV\"))\n\tgpProgramUniform3iEXT = uintptr(getProcAddr(\"glProgramUniform3iEXT\"))\n\tgpProgramUniform3iv = uintptr(getProcAddr(\"glProgramUniform3iv\"))\n\tgpProgramUniform3ivEXT = uintptr(getProcAddr(\"glProgramUniform3ivEXT\"))\n\tgpProgramUniform3ui = uintptr(getProcAddr(\"glProgramUniform3ui\"))\n\tgpProgramUniform3ui64ARB = uintptr(getProcAddr(\"glProgramUniform3ui64ARB\"))\n\tgpProgramUniform3ui64NV = uintptr(getProcAddr(\"glProgramUniform3ui64NV\"))\n\tgpProgramUniform3ui64vARB = uintptr(getProcAddr(\"glProgramUniform3ui64vARB\"))\n\tgpProgramUniform3ui64vNV = uintptr(getProcAddr(\"glProgramUniform3ui64vNV\"))\n\tgpProgramUniform3uiEXT = uintptr(getProcAddr(\"glProgramUniform3uiEXT\"))\n\tgpProgramUniform3uiv = uintptr(getProcAddr(\"glProgramUniform3uiv\"))\n\tgpProgramUniform3uivEXT = uintptr(getProcAddr(\"glProgramUniform3uivEXT\"))\n\tgpProgramUniform4d = uintptr(getProcAddr(\"glProgramUniform4d\"))\n\tgpProgramUniform4dEXT = uintptr(getProcAddr(\"glProgramUniform4dEXT\"))\n\tgpProgramUniform4dv = uintptr(getProcAddr(\"glProgramUniform4dv\"))\n\tgpProgramUniform4dvEXT = uintptr(getProcAddr(\"glProgramUniform4dvEXT\"))\n\tgpProgramUniform4f = uintptr(getProcAddr(\"glProgramUniform4f\"))\n\tgpProgramUniform4fEXT = uintptr(getProcAddr(\"glProgramUniform4fEXT\"))\n\tgpProgramUniform4fv = uintptr(getProcAddr(\"glProgramUniform4fv\"))\n\tgpProgramUniform4fvEXT = uintptr(getProcAddr(\"glProgramUniform4fvEXT\"))\n\tgpProgramUniform4i = uintptr(getProcAddr(\"glProgramUniform4i\"))\n\tgpProgramUniform4i64ARB = uintptr(getProcAddr(\"glProgramUniform4i64ARB\"))\n\tgpProgramUniform4i64NV = uintptr(getProcAddr(\"glProgramUniform4i64NV\"))\n\tgpProgramUniform4i64vARB = uintptr(getProcAddr(\"glProgramUniform4i64vARB\"))\n\tgpProgramUniform4i64vNV = uintptr(getProcAddr(\"glProgramUniform4i64vNV\"))\n\tgpProgramUniform4iEXT = uintptr(getProcAddr(\"glProgramUniform4iEXT\"))\n\tgpProgramUniform4iv = uintptr(getProcAddr(\"glProgramUniform4iv\"))\n\tgpProgramUniform4ivEXT = uintptr(getProcAddr(\"glProgramUniform4ivEXT\"))\n\tgpProgramUniform4ui = uintptr(getProcAddr(\"glProgramUniform4ui\"))\n\tgpProgramUniform4ui64ARB = uintptr(getProcAddr(\"glProgramUniform4ui64ARB\"))\n\tgpProgramUniform4ui64NV = uintptr(getProcAddr(\"glProgramUniform4ui64NV\"))\n\tgpProgramUniform4ui64vARB = uintptr(getProcAddr(\"glProgramUniform4ui64vARB\"))\n\tgpProgramUniform4ui64vNV = uintptr(getProcAddr(\"glProgramUniform4ui64vNV\"))\n\tgpProgramUniform4uiEXT = uintptr(getProcAddr(\"glProgramUniform4uiEXT\"))\n\tgpProgramUniform4uiv = uintptr(getProcAddr(\"glProgramUniform4uiv\"))\n\tgpProgramUniform4uivEXT = uintptr(getProcAddr(\"glProgramUniform4uivEXT\"))\n\tgpProgramUniformHandleui64ARB = uintptr(getProcAddr(\"glProgramUniformHandleui64ARB\"))\n\tgpProgramUniformHandleui64NV = uintptr(getProcAddr(\"glProgramUniformHandleui64NV\"))\n\tgpProgramUniformHandleui64vARB = uintptr(getProcAddr(\"glProgramUniformHandleui64vARB\"))\n\tgpProgramUniformHandleui64vNV = uintptr(getProcAddr(\"glProgramUniformHandleui64vNV\"))\n\tgpProgramUniformMatrix2dv = uintptr(getProcAddr(\"glProgramUniformMatrix2dv\"))\n\tgpProgramUniformMatrix2dvEXT = uintptr(getProcAddr(\"glProgramUniformMatrix2dvEXT\"))\n\tgpProgramUniformMatrix2fv = uintptr(getProcAddr(\"glProgramUniformMatrix2fv\"))\n\tgpProgramUniformMatrix2fvEXT = uintptr(getProcAddr(\"glProgramUniformMatrix2fvEXT\"))\n\tgpProgramUniformMatrix2x3dv = uintptr(getProcAddr(\"glProgramUniformMatrix2x3dv\"))\n\tgpProgramUniformMatrix2x3dvEXT = uintptr(getProcAddr(\"glProgramUniformMatrix2x3dvEXT\"))\n\tgpProgramUniformMatrix2x3fv = uintptr(getProcAddr(\"glProgramUniformMatrix2x3fv\"))\n\tgpProgramUniformMatrix2x3fvEXT = uintptr(getProcAddr(\"glProgramUniformMatrix2x3fvEXT\"))\n\tgpProgramUniformMatrix2x4dv = uintptr(getProcAddr(\"glProgramUniformMatrix2x4dv\"))\n\tgpProgramUniformMatrix2x4dvEXT = uintptr(getProcAddr(\"glProgramUniformMatrix2x4dvEXT\"))\n\tgpProgramUniformMatrix2x4fv = uintptr(getProcAddr(\"glProgramUniformMatrix2x4fv\"))\n\tgpProgramUniformMatrix2x4fvEXT = uintptr(getProcAddr(\"glProgramUniformMatrix2x4fvEXT\"))\n\tgpProgramUniformMatrix3dv = uintptr(getProcAddr(\"glProgramUniformMatrix3dv\"))\n\tgpProgramUniformMatrix3dvEXT = uintptr(getProcAddr(\"glProgramUniformMatrix3dvEXT\"))\n\tgpProgramUniformMatrix3fv = uintptr(getProcAddr(\"glProgramUniformMatrix3fv\"))\n\tgpProgramUniformMatrix3fvEXT = uintptr(getProcAddr(\"glProgramUniformMatrix3fvEXT\"))\n\tgpProgramUniformMatrix3x2dv = uintptr(getProcAddr(\"glProgramUniformMatrix3x2dv\"))\n\tgpProgramUniformMatrix3x2dvEXT = uintptr(getProcAddr(\"glProgramUniformMatrix3x2dvEXT\"))\n\tgpProgramUniformMatrix3x2fv = uintptr(getProcAddr(\"glProgramUniformMatrix3x2fv\"))\n\tgpProgramUniformMatrix3x2fvEXT = uintptr(getProcAddr(\"glProgramUniformMatrix3x2fvEXT\"))\n\tgpProgramUniformMatrix3x4dv = uintptr(getProcAddr(\"glProgramUniformMatrix3x4dv\"))\n\tgpProgramUniformMatrix3x4dvEXT = uintptr(getProcAddr(\"glProgramUniformMatrix3x4dvEXT\"))\n\tgpProgramUniformMatrix3x4fv = uintptr(getProcAddr(\"glProgramUniformMatrix3x4fv\"))\n\tgpProgramUniformMatrix3x4fvEXT = uintptr(getProcAddr(\"glProgramUniformMatrix3x4fvEXT\"))\n\tgpProgramUniformMatrix4dv = uintptr(getProcAddr(\"glProgramUniformMatrix4dv\"))\n\tgpProgramUniformMatrix4dvEXT = uintptr(getProcAddr(\"glProgramUniformMatrix4dvEXT\"))\n\tgpProgramUniformMatrix4fv = uintptr(getProcAddr(\"glProgramUniformMatrix4fv\"))\n\tgpProgramUniformMatrix4fvEXT = uintptr(getProcAddr(\"glProgramUniformMatrix4fvEXT\"))\n\tgpProgramUniformMatrix4x2dv = uintptr(getProcAddr(\"glProgramUniformMatrix4x2dv\"))\n\tgpProgramUniformMatrix4x2dvEXT = uintptr(getProcAddr(\"glProgramUniformMatrix4x2dvEXT\"))\n\tgpProgramUniformMatrix4x2fv = uintptr(getProcAddr(\"glProgramUniformMatrix4x2fv\"))\n\tgpProgramUniformMatrix4x2fvEXT = uintptr(getProcAddr(\"glProgramUniformMatrix4x2fvEXT\"))\n\tgpProgramUniformMatrix4x3dv = uintptr(getProcAddr(\"glProgramUniformMatrix4x3dv\"))\n\tgpProgramUniformMatrix4x3dvEXT = uintptr(getProcAddr(\"glProgramUniformMatrix4x3dvEXT\"))\n\tgpProgramUniformMatrix4x3fv = uintptr(getProcAddr(\"glProgramUniformMatrix4x3fv\"))\n\tgpProgramUniformMatrix4x3fvEXT = uintptr(getProcAddr(\"glProgramUniformMatrix4x3fvEXT\"))\n\tgpProgramUniformui64NV = uintptr(getProcAddr(\"glProgramUniformui64NV\"))\n\tgpProgramUniformui64vNV = uintptr(getProcAddr(\"glProgramUniformui64vNV\"))\n\tgpProgramVertexLimitNV = uintptr(getProcAddr(\"glProgramVertexLimitNV\"))\n\tgpProvokingVertex = uintptr(getProcAddr(\"glProvokingVertex\"))\n\tgpProvokingVertexEXT = uintptr(getProcAddr(\"glProvokingVertexEXT\"))\n\tgpPushAttrib = uintptr(getProcAddr(\"glPushAttrib\"))\n\tif gpPushAttrib == 0 {\n\t\treturn errors.New(\"glPushAttrib\")\n\t}\n\tgpPushClientAttrib = uintptr(getProcAddr(\"glPushClientAttrib\"))\n\tif gpPushClientAttrib == 0 {\n\t\treturn errors.New(\"glPushClientAttrib\")\n\t}\n\tgpPushClientAttribDefaultEXT = uintptr(getProcAddr(\"glPushClientAttribDefaultEXT\"))\n\tgpPushDebugGroup = uintptr(getProcAddr(\"glPushDebugGroup\"))\n\tgpPushDebugGroupKHR = uintptr(getProcAddr(\"glPushDebugGroupKHR\"))\n\tgpPushGroupMarkerEXT = uintptr(getProcAddr(\"glPushGroupMarkerEXT\"))\n\tgpPushMatrix = uintptr(getProcAddr(\"glPushMatrix\"))\n\tif gpPushMatrix == 0 {\n\t\treturn errors.New(\"glPushMatrix\")\n\t}\n\tgpPushName = uintptr(getProcAddr(\"glPushName\"))\n\tif gpPushName == 0 {\n\t\treturn errors.New(\"glPushName\")\n\t}\n\tgpQueryCounter = uintptr(getProcAddr(\"glQueryCounter\"))\n\tgpQueryMatrixxOES = uintptr(getProcAddr(\"glQueryMatrixxOES\"))\n\tgpQueryObjectParameteruiAMD = uintptr(getProcAddr(\"glQueryObjectParameteruiAMD\"))\n\tgpQueryResourceNV = uintptr(getProcAddr(\"glQueryResourceNV\"))\n\tgpQueryResourceTagNV = uintptr(getProcAddr(\"glQueryResourceTagNV\"))\n\tgpRasterPos2d = uintptr(getProcAddr(\"glRasterPos2d\"))\n\tif gpRasterPos2d == 0 {\n\t\treturn errors.New(\"glRasterPos2d\")\n\t}\n\tgpRasterPos2dv = uintptr(getProcAddr(\"glRasterPos2dv\"))\n\tif gpRasterPos2dv == 0 {\n\t\treturn errors.New(\"glRasterPos2dv\")\n\t}\n\tgpRasterPos2f = uintptr(getProcAddr(\"glRasterPos2f\"))\n\tif gpRasterPos2f == 0 {\n\t\treturn errors.New(\"glRasterPos2f\")\n\t}\n\tgpRasterPos2fv = uintptr(getProcAddr(\"glRasterPos2fv\"))\n\tif gpRasterPos2fv == 0 {\n\t\treturn errors.New(\"glRasterPos2fv\")\n\t}\n\tgpRasterPos2i = uintptr(getProcAddr(\"glRasterPos2i\"))\n\tif gpRasterPos2i == 0 {\n\t\treturn errors.New(\"glRasterPos2i\")\n\t}\n\tgpRasterPos2iv = uintptr(getProcAddr(\"glRasterPos2iv\"))\n\tif gpRasterPos2iv == 0 {\n\t\treturn errors.New(\"glRasterPos2iv\")\n\t}\n\tgpRasterPos2s = uintptr(getProcAddr(\"glRasterPos2s\"))\n\tif gpRasterPos2s == 0 {\n\t\treturn errors.New(\"glRasterPos2s\")\n\t}\n\tgpRasterPos2sv = uintptr(getProcAddr(\"glRasterPos2sv\"))\n\tif gpRasterPos2sv == 0 {\n\t\treturn errors.New(\"glRasterPos2sv\")\n\t}\n\tgpRasterPos2xOES = uintptr(getProcAddr(\"glRasterPos2xOES\"))\n\tgpRasterPos2xvOES = uintptr(getProcAddr(\"glRasterPos2xvOES\"))\n\tgpRasterPos3d = uintptr(getProcAddr(\"glRasterPos3d\"))\n\tif gpRasterPos3d == 0 {\n\t\treturn errors.New(\"glRasterPos3d\")\n\t}\n\tgpRasterPos3dv = uintptr(getProcAddr(\"glRasterPos3dv\"))\n\tif gpRasterPos3dv == 0 {\n\t\treturn errors.New(\"glRasterPos3dv\")\n\t}\n\tgpRasterPos3f = uintptr(getProcAddr(\"glRasterPos3f\"))\n\tif gpRasterPos3f == 0 {\n\t\treturn errors.New(\"glRasterPos3f\")\n\t}\n\tgpRasterPos3fv = uintptr(getProcAddr(\"glRasterPos3fv\"))\n\tif gpRasterPos3fv == 0 {\n\t\treturn errors.New(\"glRasterPos3fv\")\n\t}\n\tgpRasterPos3i = uintptr(getProcAddr(\"glRasterPos3i\"))\n\tif gpRasterPos3i == 0 {\n\t\treturn errors.New(\"glRasterPos3i\")\n\t}\n\tgpRasterPos3iv = uintptr(getProcAddr(\"glRasterPos3iv\"))\n\tif gpRasterPos3iv == 0 {\n\t\treturn errors.New(\"glRasterPos3iv\")\n\t}\n\tgpRasterPos3s = uintptr(getProcAddr(\"glRasterPos3s\"))\n\tif gpRasterPos3s == 0 {\n\t\treturn errors.New(\"glRasterPos3s\")\n\t}\n\tgpRasterPos3sv = uintptr(getProcAddr(\"glRasterPos3sv\"))\n\tif gpRasterPos3sv == 0 {\n\t\treturn errors.New(\"glRasterPos3sv\")\n\t}\n\tgpRasterPos3xOES = uintptr(getProcAddr(\"glRasterPos3xOES\"))\n\tgpRasterPos3xvOES = uintptr(getProcAddr(\"glRasterPos3xvOES\"))\n\tgpRasterPos4d = uintptr(getProcAddr(\"glRasterPos4d\"))\n\tif gpRasterPos4d == 0 {\n\t\treturn errors.New(\"glRasterPos4d\")\n\t}\n\tgpRasterPos4dv = uintptr(getProcAddr(\"glRasterPos4dv\"))\n\tif gpRasterPos4dv == 0 {\n\t\treturn errors.New(\"glRasterPos4dv\")\n\t}\n\tgpRasterPos4f = uintptr(getProcAddr(\"glRasterPos4f\"))\n\tif gpRasterPos4f == 0 {\n\t\treturn errors.New(\"glRasterPos4f\")\n\t}\n\tgpRasterPos4fv = uintptr(getProcAddr(\"glRasterPos4fv\"))\n\tif gpRasterPos4fv == 0 {\n\t\treturn errors.New(\"glRasterPos4fv\")\n\t}\n\tgpRasterPos4i = uintptr(getProcAddr(\"glRasterPos4i\"))\n\tif gpRasterPos4i == 0 {\n\t\treturn errors.New(\"glRasterPos4i\")\n\t}\n\tgpRasterPos4iv = uintptr(getProcAddr(\"glRasterPos4iv\"))\n\tif gpRasterPos4iv == 0 {\n\t\treturn errors.New(\"glRasterPos4iv\")\n\t}\n\tgpRasterPos4s = uintptr(getProcAddr(\"glRasterPos4s\"))\n\tif gpRasterPos4s == 0 {\n\t\treturn errors.New(\"glRasterPos4s\")\n\t}\n\tgpRasterPos4sv = uintptr(getProcAddr(\"glRasterPos4sv\"))\n\tif gpRasterPos4sv == 0 {\n\t\treturn errors.New(\"glRasterPos4sv\")\n\t}\n\tgpRasterPos4xOES = uintptr(getProcAddr(\"glRasterPos4xOES\"))\n\tgpRasterPos4xvOES = uintptr(getProcAddr(\"glRasterPos4xvOES\"))\n\tgpRasterSamplesEXT = uintptr(getProcAddr(\"glRasterSamplesEXT\"))\n\tgpReadBuffer = uintptr(getProcAddr(\"glReadBuffer\"))\n\tif gpReadBuffer == 0 {\n\t\treturn errors.New(\"glReadBuffer\")\n\t}\n\tgpReadInstrumentsSGIX = uintptr(getProcAddr(\"glReadInstrumentsSGIX\"))\n\tgpReadPixels = uintptr(getProcAddr(\"glReadPixels\"))\n\tif gpReadPixels == 0 {\n\t\treturn errors.New(\"glReadPixels\")\n\t}\n\tgpReadnPixels = uintptr(getProcAddr(\"glReadnPixels\"))\n\tgpReadnPixelsARB = uintptr(getProcAddr(\"glReadnPixelsARB\"))\n\tgpReadnPixelsKHR = uintptr(getProcAddr(\"glReadnPixelsKHR\"))\n\tgpRectd = uintptr(getProcAddr(\"glRectd\"))\n\tif gpRectd == 0 {\n\t\treturn errors.New(\"glRectd\")\n\t}\n\tgpRectdv = uintptr(getProcAddr(\"glRectdv\"))\n\tif gpRectdv == 0 {\n\t\treturn errors.New(\"glRectdv\")\n\t}\n\tgpRectf = uintptr(getProcAddr(\"glRectf\"))\n\tif gpRectf == 0 {\n\t\treturn errors.New(\"glRectf\")\n\t}\n\tgpRectfv = uintptr(getProcAddr(\"glRectfv\"))\n\tif gpRectfv == 0 {\n\t\treturn errors.New(\"glRectfv\")\n\t}\n\tgpRecti = uintptr(getProcAddr(\"glRecti\"))\n\tif gpRecti == 0 {\n\t\treturn errors.New(\"glRecti\")\n\t}\n\tgpRectiv = uintptr(getProcAddr(\"glRectiv\"))\n\tif gpRectiv == 0 {\n\t\treturn errors.New(\"glRectiv\")\n\t}\n\tgpRects = uintptr(getProcAddr(\"glRects\"))\n\tif gpRects == 0 {\n\t\treturn errors.New(\"glRects\")\n\t}\n\tgpRectsv = uintptr(getProcAddr(\"glRectsv\"))\n\tif gpRectsv == 0 {\n\t\treturn errors.New(\"glRectsv\")\n\t}\n\tgpRectxOES = uintptr(getProcAddr(\"glRectxOES\"))\n\tgpRectxvOES = uintptr(getProcAddr(\"glRectxvOES\"))\n\tgpReferencePlaneSGIX = uintptr(getProcAddr(\"glReferencePlaneSGIX\"))\n\tgpReleaseKeyedMutexWin32EXT = uintptr(getProcAddr(\"glReleaseKeyedMutexWin32EXT\"))\n\tgpReleaseShaderCompiler = uintptr(getProcAddr(\"glReleaseShaderCompiler\"))\n\tgpRenderGpuMaskNV = uintptr(getProcAddr(\"glRenderGpuMaskNV\"))\n\tgpRenderMode = uintptr(getProcAddr(\"glRenderMode\"))\n\tif gpRenderMode == 0 {\n\t\treturn errors.New(\"glRenderMode\")\n\t}\n\tgpRenderbufferStorage = uintptr(getProcAddr(\"glRenderbufferStorage\"))\n\tgpRenderbufferStorageEXT = uintptr(getProcAddr(\"glRenderbufferStorageEXT\"))\n\tgpRenderbufferStorageMultisample = uintptr(getProcAddr(\"glRenderbufferStorageMultisample\"))\n\tgpRenderbufferStorageMultisampleCoverageNV = uintptr(getProcAddr(\"glRenderbufferStorageMultisampleCoverageNV\"))\n\tgpRenderbufferStorageMultisampleEXT = uintptr(getProcAddr(\"glRenderbufferStorageMultisampleEXT\"))\n\tgpReplacementCodePointerSUN = uintptr(getProcAddr(\"glReplacementCodePointerSUN\"))\n\tgpReplacementCodeubSUN = uintptr(getProcAddr(\"glReplacementCodeubSUN\"))\n\tgpReplacementCodeubvSUN = uintptr(getProcAddr(\"glReplacementCodeubvSUN\"))\n\tgpReplacementCodeuiColor3fVertex3fSUN = uintptr(getProcAddr(\"glReplacementCodeuiColor3fVertex3fSUN\"))\n\tgpReplacementCodeuiColor3fVertex3fvSUN = uintptr(getProcAddr(\"glReplacementCodeuiColor3fVertex3fvSUN\"))\n\tgpReplacementCodeuiColor4fNormal3fVertex3fSUN = uintptr(getProcAddr(\"glReplacementCodeuiColor4fNormal3fVertex3fSUN\"))\n\tgpReplacementCodeuiColor4fNormal3fVertex3fvSUN = uintptr(getProcAddr(\"glReplacementCodeuiColor4fNormal3fVertex3fvSUN\"))\n\tgpReplacementCodeuiColor4ubVertex3fSUN = uintptr(getProcAddr(\"glReplacementCodeuiColor4ubVertex3fSUN\"))\n\tgpReplacementCodeuiColor4ubVertex3fvSUN = uintptr(getProcAddr(\"glReplacementCodeuiColor4ubVertex3fvSUN\"))\n\tgpReplacementCodeuiNormal3fVertex3fSUN = uintptr(getProcAddr(\"glReplacementCodeuiNormal3fVertex3fSUN\"))\n\tgpReplacementCodeuiNormal3fVertex3fvSUN = uintptr(getProcAddr(\"glReplacementCodeuiNormal3fVertex3fvSUN\"))\n\tgpReplacementCodeuiSUN = uintptr(getProcAddr(\"glReplacementCodeuiSUN\"))\n\tgpReplacementCodeuiTexCoord2fColor4fNormal3fVertex3fSUN = uintptr(getProcAddr(\"glReplacementCodeuiTexCoord2fColor4fNormal3fVertex3fSUN\"))\n\tgpReplacementCodeuiTexCoord2fColor4fNormal3fVertex3fvSUN = uintptr(getProcAddr(\"glReplacementCodeuiTexCoord2fColor4fNormal3fVertex3fvSUN\"))\n\tgpReplacementCodeuiTexCoord2fNormal3fVertex3fSUN = uintptr(getProcAddr(\"glReplacementCodeuiTexCoord2fNormal3fVertex3fSUN\"))\n\tgpReplacementCodeuiTexCoord2fNormal3fVertex3fvSUN = uintptr(getProcAddr(\"glReplacementCodeuiTexCoord2fNormal3fVertex3fvSUN\"))\n\tgpReplacementCodeuiTexCoord2fVertex3fSUN = uintptr(getProcAddr(\"glReplacementCodeuiTexCoord2fVertex3fSUN\"))\n\tgpReplacementCodeuiTexCoord2fVertex3fvSUN = uintptr(getProcAddr(\"glReplacementCodeuiTexCoord2fVertex3fvSUN\"))\n\tgpReplacementCodeuiVertex3fSUN = uintptr(getProcAddr(\"glReplacementCodeuiVertex3fSUN\"))\n\tgpReplacementCodeuiVertex3fvSUN = uintptr(getProcAddr(\"glReplacementCodeuiVertex3fvSUN\"))\n\tgpReplacementCodeuivSUN = uintptr(getProcAddr(\"glReplacementCodeuivSUN\"))\n\tgpReplacementCodeusSUN = uintptr(getProcAddr(\"glReplacementCodeusSUN\"))\n\tgpReplacementCodeusvSUN = uintptr(getProcAddr(\"glReplacementCodeusvSUN\"))\n\tgpRequestResidentProgramsNV = uintptr(getProcAddr(\"glRequestResidentProgramsNV\"))\n\tgpResetHistogramEXT = uintptr(getProcAddr(\"glResetHistogramEXT\"))\n\tgpResetMinmaxEXT = uintptr(getProcAddr(\"glResetMinmaxEXT\"))\n\tgpResizeBuffersMESA = uintptr(getProcAddr(\"glResizeBuffersMESA\"))\n\tgpResolveDepthValuesNV = uintptr(getProcAddr(\"glResolveDepthValuesNV\"))\n\tgpResumeTransformFeedback = uintptr(getProcAddr(\"glResumeTransformFeedback\"))\n\tgpResumeTransformFeedbackNV = uintptr(getProcAddr(\"glResumeTransformFeedbackNV\"))\n\tgpRotated = uintptr(getProcAddr(\"glRotated\"))\n\tif gpRotated == 0 {\n\t\treturn errors.New(\"glRotated\")\n\t}\n\tgpRotatef = uintptr(getProcAddr(\"glRotatef\"))\n\tif gpRotatef == 0 {\n\t\treturn errors.New(\"glRotatef\")\n\t}\n\tgpRotatexOES = uintptr(getProcAddr(\"glRotatexOES\"))\n\tgpSampleCoverage = uintptr(getProcAddr(\"glSampleCoverage\"))\n\tif gpSampleCoverage == 0 {\n\t\treturn errors.New(\"glSampleCoverage\")\n\t}\n\tgpSampleCoverageARB = uintptr(getProcAddr(\"glSampleCoverageARB\"))\n\tgpSampleCoveragexOES = uintptr(getProcAddr(\"glSampleCoveragexOES\"))\n\tgpSampleMapATI = uintptr(getProcAddr(\"glSampleMapATI\"))\n\tgpSampleMaskEXT = uintptr(getProcAddr(\"glSampleMaskEXT\"))\n\tgpSampleMaskIndexedNV = uintptr(getProcAddr(\"glSampleMaskIndexedNV\"))\n\tgpSampleMaskSGIS = uintptr(getProcAddr(\"glSampleMaskSGIS\"))\n\tgpSampleMaski = uintptr(getProcAddr(\"glSampleMaski\"))\n\tgpSamplePatternEXT = uintptr(getProcAddr(\"glSamplePatternEXT\"))\n\tgpSamplePatternSGIS = uintptr(getProcAddr(\"glSamplePatternSGIS\"))\n\tgpSamplerParameterIiv = uintptr(getProcAddr(\"glSamplerParameterIiv\"))\n\tgpSamplerParameterIuiv = uintptr(getProcAddr(\"glSamplerParameterIuiv\"))\n\tgpSamplerParameterf = uintptr(getProcAddr(\"glSamplerParameterf\"))\n\tgpSamplerParameterfv = uintptr(getProcAddr(\"glSamplerParameterfv\"))\n\tgpSamplerParameteri = uintptr(getProcAddr(\"glSamplerParameteri\"))\n\tgpSamplerParameteriv = uintptr(getProcAddr(\"glSamplerParameteriv\"))\n\tgpScaled = uintptr(getProcAddr(\"glScaled\"))\n\tif gpScaled == 0 {\n\t\treturn errors.New(\"glScaled\")\n\t}\n\tgpScalef = uintptr(getProcAddr(\"glScalef\"))\n\tif gpScalef == 0 {\n\t\treturn errors.New(\"glScalef\")\n\t}\n\tgpScalexOES = uintptr(getProcAddr(\"glScalexOES\"))\n\tgpScissor = uintptr(getProcAddr(\"glScissor\"))\n\tif gpScissor == 0 {\n\t\treturn errors.New(\"glScissor\")\n\t}\n\tgpScissorArrayv = uintptr(getProcAddr(\"glScissorArrayv\"))\n\tgpScissorIndexed = uintptr(getProcAddr(\"glScissorIndexed\"))\n\tgpScissorIndexedv = uintptr(getProcAddr(\"glScissorIndexedv\"))\n\tgpSecondaryColor3b = uintptr(getProcAddr(\"glSecondaryColor3b\"))\n\tif gpSecondaryColor3b == 0 {\n\t\treturn errors.New(\"glSecondaryColor3b\")\n\t}\n\tgpSecondaryColor3bEXT = uintptr(getProcAddr(\"glSecondaryColor3bEXT\"))\n\tgpSecondaryColor3bv = uintptr(getProcAddr(\"glSecondaryColor3bv\"))\n\tif gpSecondaryColor3bv == 0 {\n\t\treturn errors.New(\"glSecondaryColor3bv\")\n\t}\n\tgpSecondaryColor3bvEXT = uintptr(getProcAddr(\"glSecondaryColor3bvEXT\"))\n\tgpSecondaryColor3d = uintptr(getProcAddr(\"glSecondaryColor3d\"))\n\tif gpSecondaryColor3d == 0 {\n\t\treturn errors.New(\"glSecondaryColor3d\")\n\t}\n\tgpSecondaryColor3dEXT = uintptr(getProcAddr(\"glSecondaryColor3dEXT\"))\n\tgpSecondaryColor3dv = uintptr(getProcAddr(\"glSecondaryColor3dv\"))\n\tif gpSecondaryColor3dv == 0 {\n\t\treturn errors.New(\"glSecondaryColor3dv\")\n\t}\n\tgpSecondaryColor3dvEXT = uintptr(getProcAddr(\"glSecondaryColor3dvEXT\"))\n\tgpSecondaryColor3f = uintptr(getProcAddr(\"glSecondaryColor3f\"))\n\tif gpSecondaryColor3f == 0 {\n\t\treturn errors.New(\"glSecondaryColor3f\")\n\t}\n\tgpSecondaryColor3fEXT = uintptr(getProcAddr(\"glSecondaryColor3fEXT\"))\n\tgpSecondaryColor3fv = uintptr(getProcAddr(\"glSecondaryColor3fv\"))\n\tif gpSecondaryColor3fv == 0 {\n\t\treturn errors.New(\"glSecondaryColor3fv\")\n\t}\n\tgpSecondaryColor3fvEXT = uintptr(getProcAddr(\"glSecondaryColor3fvEXT\"))\n\tgpSecondaryColor3hNV = uintptr(getProcAddr(\"glSecondaryColor3hNV\"))\n\tgpSecondaryColor3hvNV = uintptr(getProcAddr(\"glSecondaryColor3hvNV\"))\n\tgpSecondaryColor3i = uintptr(getProcAddr(\"glSecondaryColor3i\"))\n\tif gpSecondaryColor3i == 0 {\n\t\treturn errors.New(\"glSecondaryColor3i\")\n\t}\n\tgpSecondaryColor3iEXT = uintptr(getProcAddr(\"glSecondaryColor3iEXT\"))\n\tgpSecondaryColor3iv = uintptr(getProcAddr(\"glSecondaryColor3iv\"))\n\tif gpSecondaryColor3iv == 0 {\n\t\treturn errors.New(\"glSecondaryColor3iv\")\n\t}\n\tgpSecondaryColor3ivEXT = uintptr(getProcAddr(\"glSecondaryColor3ivEXT\"))\n\tgpSecondaryColor3s = uintptr(getProcAddr(\"glSecondaryColor3s\"))\n\tif gpSecondaryColor3s == 0 {\n\t\treturn errors.New(\"glSecondaryColor3s\")\n\t}\n\tgpSecondaryColor3sEXT = uintptr(getProcAddr(\"glSecondaryColor3sEXT\"))\n\tgpSecondaryColor3sv = uintptr(getProcAddr(\"glSecondaryColor3sv\"))\n\tif gpSecondaryColor3sv == 0 {\n\t\treturn errors.New(\"glSecondaryColor3sv\")\n\t}\n\tgpSecondaryColor3svEXT = uintptr(getProcAddr(\"glSecondaryColor3svEXT\"))\n\tgpSecondaryColor3ub = uintptr(getProcAddr(\"glSecondaryColor3ub\"))\n\tif gpSecondaryColor3ub == 0 {\n\t\treturn errors.New(\"glSecondaryColor3ub\")\n\t}\n\tgpSecondaryColor3ubEXT = uintptr(getProcAddr(\"glSecondaryColor3ubEXT\"))\n\tgpSecondaryColor3ubv = uintptr(getProcAddr(\"glSecondaryColor3ubv\"))\n\tif gpSecondaryColor3ubv == 0 {\n\t\treturn errors.New(\"glSecondaryColor3ubv\")\n\t}\n\tgpSecondaryColor3ubvEXT = uintptr(getProcAddr(\"glSecondaryColor3ubvEXT\"))\n\tgpSecondaryColor3ui = uintptr(getProcAddr(\"glSecondaryColor3ui\"))\n\tif gpSecondaryColor3ui == 0 {\n\t\treturn errors.New(\"glSecondaryColor3ui\")\n\t}\n\tgpSecondaryColor3uiEXT = uintptr(getProcAddr(\"glSecondaryColor3uiEXT\"))\n\tgpSecondaryColor3uiv = uintptr(getProcAddr(\"glSecondaryColor3uiv\"))\n\tif gpSecondaryColor3uiv == 0 {\n\t\treturn errors.New(\"glSecondaryColor3uiv\")\n\t}\n\tgpSecondaryColor3uivEXT = uintptr(getProcAddr(\"glSecondaryColor3uivEXT\"))\n\tgpSecondaryColor3us = uintptr(getProcAddr(\"glSecondaryColor3us\"))\n\tif gpSecondaryColor3us == 0 {\n\t\treturn errors.New(\"glSecondaryColor3us\")\n\t}\n\tgpSecondaryColor3usEXT = uintptr(getProcAddr(\"glSecondaryColor3usEXT\"))\n\tgpSecondaryColor3usv = uintptr(getProcAddr(\"glSecondaryColor3usv\"))\n\tif gpSecondaryColor3usv == 0 {\n\t\treturn errors.New(\"glSecondaryColor3usv\")\n\t}\n\tgpSecondaryColor3usvEXT = uintptr(getProcAddr(\"glSecondaryColor3usvEXT\"))\n\tgpSecondaryColorFormatNV = uintptr(getProcAddr(\"glSecondaryColorFormatNV\"))\n\tgpSecondaryColorPointer = uintptr(getProcAddr(\"glSecondaryColorPointer\"))\n\tif gpSecondaryColorPointer == 0 {\n\t\treturn errors.New(\"glSecondaryColorPointer\")\n\t}\n\tgpSecondaryColorPointerEXT = uintptr(getProcAddr(\"glSecondaryColorPointerEXT\"))\n\tgpSecondaryColorPointerListIBM = uintptr(getProcAddr(\"glSecondaryColorPointerListIBM\"))\n\tgpSelectBuffer = uintptr(getProcAddr(\"glSelectBuffer\"))\n\tif gpSelectBuffer == 0 {\n\t\treturn errors.New(\"glSelectBuffer\")\n\t}\n\tgpSelectPerfMonitorCountersAMD = uintptr(getProcAddr(\"glSelectPerfMonitorCountersAMD\"))\n\tgpSemaphoreParameterui64vEXT = uintptr(getProcAddr(\"glSemaphoreParameterui64vEXT\"))\n\tgpSeparableFilter2DEXT = uintptr(getProcAddr(\"glSeparableFilter2DEXT\"))\n\tgpSetFenceAPPLE = uintptr(getProcAddr(\"glSetFenceAPPLE\"))\n\tgpSetFenceNV = uintptr(getProcAddr(\"glSetFenceNV\"))\n\tgpSetFragmentShaderConstantATI = uintptr(getProcAddr(\"glSetFragmentShaderConstantATI\"))\n\tgpSetInvariantEXT = uintptr(getProcAddr(\"glSetInvariantEXT\"))\n\tgpSetLocalConstantEXT = uintptr(getProcAddr(\"glSetLocalConstantEXT\"))\n\tgpSetMultisamplefvAMD = uintptr(getProcAddr(\"glSetMultisamplefvAMD\"))\n\tgpShadeModel = uintptr(getProcAddr(\"glShadeModel\"))\n\tif gpShadeModel == 0 {\n\t\treturn errors.New(\"glShadeModel\")\n\t}\n\tgpShaderBinary = uintptr(getProcAddr(\"glShaderBinary\"))\n\tgpShaderOp1EXT = uintptr(getProcAddr(\"glShaderOp1EXT\"))\n\tgpShaderOp2EXT = uintptr(getProcAddr(\"glShaderOp2EXT\"))\n\tgpShaderOp3EXT = uintptr(getProcAddr(\"glShaderOp3EXT\"))\n\tgpShaderSource = uintptr(getProcAddr(\"glShaderSource\"))\n\tif gpShaderSource == 0 {\n\t\treturn errors.New(\"glShaderSource\")\n\t}\n\tgpShaderSourceARB = uintptr(getProcAddr(\"glShaderSourceARB\"))\n\tgpShaderStorageBlockBinding = uintptr(getProcAddr(\"glShaderStorageBlockBinding\"))\n\tgpSharpenTexFuncSGIS = uintptr(getProcAddr(\"glSharpenTexFuncSGIS\"))\n\tgpSignalSemaphoreEXT = uintptr(getProcAddr(\"glSignalSemaphoreEXT\"))\n\tgpSignalVkFenceNV = uintptr(getProcAddr(\"glSignalVkFenceNV\"))\n\tgpSignalVkSemaphoreNV = uintptr(getProcAddr(\"glSignalVkSemaphoreNV\"))\n\tgpSpecializeShaderARB = uintptr(getProcAddr(\"glSpecializeShaderARB\"))\n\tgpSpriteParameterfSGIX = uintptr(getProcAddr(\"glSpriteParameterfSGIX\"))\n\tgpSpriteParameterfvSGIX = uintptr(getProcAddr(\"glSpriteParameterfvSGIX\"))\n\tgpSpriteParameteriSGIX = uintptr(getProcAddr(\"glSpriteParameteriSGIX\"))\n\tgpSpriteParameterivSGIX = uintptr(getProcAddr(\"glSpriteParameterivSGIX\"))\n\tgpStartInstrumentsSGIX = uintptr(getProcAddr(\"glStartInstrumentsSGIX\"))\n\tgpStateCaptureNV = uintptr(getProcAddr(\"glStateCaptureNV\"))\n\tgpStencilClearTagEXT = uintptr(getProcAddr(\"glStencilClearTagEXT\"))\n\tgpStencilFillPathInstancedNV = uintptr(getProcAddr(\"glStencilFillPathInstancedNV\"))\n\tgpStencilFillPathNV = uintptr(getProcAddr(\"glStencilFillPathNV\"))\n\tgpStencilFunc = uintptr(getProcAddr(\"glStencilFunc\"))\n\tif gpStencilFunc == 0 {\n\t\treturn errors.New(\"glStencilFunc\")\n\t}\n\tgpStencilFuncSeparate = uintptr(getProcAddr(\"glStencilFuncSeparate\"))\n\tif gpStencilFuncSeparate == 0 {\n\t\treturn errors.New(\"glStencilFuncSeparate\")\n\t}\n\tgpStencilFuncSeparateATI = uintptr(getProcAddr(\"glStencilFuncSeparateATI\"))\n\tgpStencilMask = uintptr(getProcAddr(\"glStencilMask\"))\n\tif gpStencilMask == 0 {\n\t\treturn errors.New(\"glStencilMask\")\n\t}\n\tgpStencilMaskSeparate = uintptr(getProcAddr(\"glStencilMaskSeparate\"))\n\tif gpStencilMaskSeparate == 0 {\n\t\treturn errors.New(\"glStencilMaskSeparate\")\n\t}\n\tgpStencilOp = uintptr(getProcAddr(\"glStencilOp\"))\n\tif gpStencilOp == 0 {\n\t\treturn errors.New(\"glStencilOp\")\n\t}\n\tgpStencilOpSeparate = uintptr(getProcAddr(\"glStencilOpSeparate\"))\n\tif gpStencilOpSeparate == 0 {\n\t\treturn errors.New(\"glStencilOpSeparate\")\n\t}\n\tgpStencilOpSeparateATI = uintptr(getProcAddr(\"glStencilOpSeparateATI\"))\n\tgpStencilOpValueAMD = uintptr(getProcAddr(\"glStencilOpValueAMD\"))\n\tgpStencilStrokePathInstancedNV = uintptr(getProcAddr(\"glStencilStrokePathInstancedNV\"))\n\tgpStencilStrokePathNV = uintptr(getProcAddr(\"glStencilStrokePathNV\"))\n\tgpStencilThenCoverFillPathInstancedNV = uintptr(getProcAddr(\"glStencilThenCoverFillPathInstancedNV\"))\n\tgpStencilThenCoverFillPathNV = uintptr(getProcAddr(\"glStencilThenCoverFillPathNV\"))\n\tgpStencilThenCoverStrokePathInstancedNV = uintptr(getProcAddr(\"glStencilThenCoverStrokePathInstancedNV\"))\n\tgpStencilThenCoverStrokePathNV = uintptr(getProcAddr(\"glStencilThenCoverStrokePathNV\"))\n\tgpStopInstrumentsSGIX = uintptr(getProcAddr(\"glStopInstrumentsSGIX\"))\n\tgpStringMarkerGREMEDY = uintptr(getProcAddr(\"glStringMarkerGREMEDY\"))\n\tgpSubpixelPrecisionBiasNV = uintptr(getProcAddr(\"glSubpixelPrecisionBiasNV\"))\n\tgpSwizzleEXT = uintptr(getProcAddr(\"glSwizzleEXT\"))\n\tgpSyncTextureINTEL = uintptr(getProcAddr(\"glSyncTextureINTEL\"))\n\tgpTagSampleBufferSGIX = uintptr(getProcAddr(\"glTagSampleBufferSGIX\"))\n\tgpTangent3bEXT = uintptr(getProcAddr(\"glTangent3bEXT\"))\n\tgpTangent3bvEXT = uintptr(getProcAddr(\"glTangent3bvEXT\"))\n\tgpTangent3dEXT = uintptr(getProcAddr(\"glTangent3dEXT\"))\n\tgpTangent3dvEXT = uintptr(getProcAddr(\"glTangent3dvEXT\"))\n\tgpTangent3fEXT = uintptr(getProcAddr(\"glTangent3fEXT\"))\n\tgpTangent3fvEXT = uintptr(getProcAddr(\"glTangent3fvEXT\"))\n\tgpTangent3iEXT = uintptr(getProcAddr(\"glTangent3iEXT\"))\n\tgpTangent3ivEXT = uintptr(getProcAddr(\"glTangent3ivEXT\"))\n\tgpTangent3sEXT = uintptr(getProcAddr(\"glTangent3sEXT\"))\n\tgpTangent3svEXT = uintptr(getProcAddr(\"glTangent3svEXT\"))\n\tgpTangentPointerEXT = uintptr(getProcAddr(\"glTangentPointerEXT\"))\n\tgpTbufferMask3DFX = uintptr(getProcAddr(\"glTbufferMask3DFX\"))\n\tgpTessellationFactorAMD = uintptr(getProcAddr(\"glTessellationFactorAMD\"))\n\tgpTessellationModeAMD = uintptr(getProcAddr(\"glTessellationModeAMD\"))\n\tgpTestFenceAPPLE = uintptr(getProcAddr(\"glTestFenceAPPLE\"))\n\tgpTestFenceNV = uintptr(getProcAddr(\"glTestFenceNV\"))\n\tgpTestObjectAPPLE = uintptr(getProcAddr(\"glTestObjectAPPLE\"))\n\tgpTexBufferARB = uintptr(getProcAddr(\"glTexBufferARB\"))\n\tgpTexBufferEXT = uintptr(getProcAddr(\"glTexBufferEXT\"))\n\tgpTexBufferRange = uintptr(getProcAddr(\"glTexBufferRange\"))\n\tgpTexBumpParameterfvATI = uintptr(getProcAddr(\"glTexBumpParameterfvATI\"))\n\tgpTexBumpParameterivATI = uintptr(getProcAddr(\"glTexBumpParameterivATI\"))\n\tgpTexCoord1bOES = uintptr(getProcAddr(\"glTexCoord1bOES\"))\n\tgpTexCoord1bvOES = uintptr(getProcAddr(\"glTexCoord1bvOES\"))\n\tgpTexCoord1d = uintptr(getProcAddr(\"glTexCoord1d\"))\n\tif gpTexCoord1d == 0 {\n\t\treturn errors.New(\"glTexCoord1d\")\n\t}\n\tgpTexCoord1dv = uintptr(getProcAddr(\"glTexCoord1dv\"))\n\tif gpTexCoord1dv == 0 {\n\t\treturn errors.New(\"glTexCoord1dv\")\n\t}\n\tgpTexCoord1f = uintptr(getProcAddr(\"glTexCoord1f\"))\n\tif gpTexCoord1f == 0 {\n\t\treturn errors.New(\"glTexCoord1f\")\n\t}\n\tgpTexCoord1fv = uintptr(getProcAddr(\"glTexCoord1fv\"))\n\tif gpTexCoord1fv == 0 {\n\t\treturn errors.New(\"glTexCoord1fv\")\n\t}\n\tgpTexCoord1hNV = uintptr(getProcAddr(\"glTexCoord1hNV\"))\n\tgpTexCoord1hvNV = uintptr(getProcAddr(\"glTexCoord1hvNV\"))\n\tgpTexCoord1i = uintptr(getProcAddr(\"glTexCoord1i\"))\n\tif gpTexCoord1i == 0 {\n\t\treturn errors.New(\"glTexCoord1i\")\n\t}\n\tgpTexCoord1iv = uintptr(getProcAddr(\"glTexCoord1iv\"))\n\tif gpTexCoord1iv == 0 {\n\t\treturn errors.New(\"glTexCoord1iv\")\n\t}\n\tgpTexCoord1s = uintptr(getProcAddr(\"glTexCoord1s\"))\n\tif gpTexCoord1s == 0 {\n\t\treturn errors.New(\"glTexCoord1s\")\n\t}\n\tgpTexCoord1sv = uintptr(getProcAddr(\"glTexCoord1sv\"))\n\tif gpTexCoord1sv == 0 {\n\t\treturn errors.New(\"glTexCoord1sv\")\n\t}\n\tgpTexCoord1xOES = uintptr(getProcAddr(\"glTexCoord1xOES\"))\n\tgpTexCoord1xvOES = uintptr(getProcAddr(\"glTexCoord1xvOES\"))\n\tgpTexCoord2bOES = uintptr(getProcAddr(\"glTexCoord2bOES\"))\n\tgpTexCoord2bvOES = uintptr(getProcAddr(\"glTexCoord2bvOES\"))\n\tgpTexCoord2d = uintptr(getProcAddr(\"glTexCoord2d\"))\n\tif gpTexCoord2d == 0 {\n\t\treturn errors.New(\"glTexCoord2d\")\n\t}\n\tgpTexCoord2dv = uintptr(getProcAddr(\"glTexCoord2dv\"))\n\tif gpTexCoord2dv == 0 {\n\t\treturn errors.New(\"glTexCoord2dv\")\n\t}\n\tgpTexCoord2f = uintptr(getProcAddr(\"glTexCoord2f\"))\n\tif gpTexCoord2f == 0 {\n\t\treturn errors.New(\"glTexCoord2f\")\n\t}\n\tgpTexCoord2fColor3fVertex3fSUN = uintptr(getProcAddr(\"glTexCoord2fColor3fVertex3fSUN\"))\n\tgpTexCoord2fColor3fVertex3fvSUN = uintptr(getProcAddr(\"glTexCoord2fColor3fVertex3fvSUN\"))\n\tgpTexCoord2fColor4fNormal3fVertex3fSUN = uintptr(getProcAddr(\"glTexCoord2fColor4fNormal3fVertex3fSUN\"))\n\tgpTexCoord2fColor4fNormal3fVertex3fvSUN = uintptr(getProcAddr(\"glTexCoord2fColor4fNormal3fVertex3fvSUN\"))\n\tgpTexCoord2fColor4ubVertex3fSUN = uintptr(getProcAddr(\"glTexCoord2fColor4ubVertex3fSUN\"))\n\tgpTexCoord2fColor4ubVertex3fvSUN = uintptr(getProcAddr(\"glTexCoord2fColor4ubVertex3fvSUN\"))\n\tgpTexCoord2fNormal3fVertex3fSUN = uintptr(getProcAddr(\"glTexCoord2fNormal3fVertex3fSUN\"))\n\tgpTexCoord2fNormal3fVertex3fvSUN = uintptr(getProcAddr(\"glTexCoord2fNormal3fVertex3fvSUN\"))\n\tgpTexCoord2fVertex3fSUN = uintptr(getProcAddr(\"glTexCoord2fVertex3fSUN\"))\n\tgpTexCoord2fVertex3fvSUN = uintptr(getProcAddr(\"glTexCoord2fVertex3fvSUN\"))\n\tgpTexCoord2fv = uintptr(getProcAddr(\"glTexCoord2fv\"))\n\tif gpTexCoord2fv == 0 {\n\t\treturn errors.New(\"glTexCoord2fv\")\n\t}\n\tgpTexCoord2hNV = uintptr(getProcAddr(\"glTexCoord2hNV\"))\n\tgpTexCoord2hvNV = uintptr(getProcAddr(\"glTexCoord2hvNV\"))\n\tgpTexCoord2i = uintptr(getProcAddr(\"glTexCoord2i\"))\n\tif gpTexCoord2i == 0 {\n\t\treturn errors.New(\"glTexCoord2i\")\n\t}\n\tgpTexCoord2iv = uintptr(getProcAddr(\"glTexCoord2iv\"))\n\tif gpTexCoord2iv == 0 {\n\t\treturn errors.New(\"glTexCoord2iv\")\n\t}\n\tgpTexCoord2s = uintptr(getProcAddr(\"glTexCoord2s\"))\n\tif gpTexCoord2s == 0 {\n\t\treturn errors.New(\"glTexCoord2s\")\n\t}\n\tgpTexCoord2sv = uintptr(getProcAddr(\"glTexCoord2sv\"))\n\tif gpTexCoord2sv == 0 {\n\t\treturn errors.New(\"glTexCoord2sv\")\n\t}\n\tgpTexCoord2xOES = uintptr(getProcAddr(\"glTexCoord2xOES\"))\n\tgpTexCoord2xvOES = uintptr(getProcAddr(\"glTexCoord2xvOES\"))\n\tgpTexCoord3bOES = uintptr(getProcAddr(\"glTexCoord3bOES\"))\n\tgpTexCoord3bvOES = uintptr(getProcAddr(\"glTexCoord3bvOES\"))\n\tgpTexCoord3d = uintptr(getProcAddr(\"glTexCoord3d\"))\n\tif gpTexCoord3d == 0 {\n\t\treturn errors.New(\"glTexCoord3d\")\n\t}\n\tgpTexCoord3dv = uintptr(getProcAddr(\"glTexCoord3dv\"))\n\tif gpTexCoord3dv == 0 {\n\t\treturn errors.New(\"glTexCoord3dv\")\n\t}\n\tgpTexCoord3f = uintptr(getProcAddr(\"glTexCoord3f\"))\n\tif gpTexCoord3f == 0 {\n\t\treturn errors.New(\"glTexCoord3f\")\n\t}\n\tgpTexCoord3fv = uintptr(getProcAddr(\"glTexCoord3fv\"))\n\tif gpTexCoord3fv == 0 {\n\t\treturn errors.New(\"glTexCoord3fv\")\n\t}\n\tgpTexCoord3hNV = uintptr(getProcAddr(\"glTexCoord3hNV\"))\n\tgpTexCoord3hvNV = uintptr(getProcAddr(\"glTexCoord3hvNV\"))\n\tgpTexCoord3i = uintptr(getProcAddr(\"glTexCoord3i\"))\n\tif gpTexCoord3i == 0 {\n\t\treturn errors.New(\"glTexCoord3i\")\n\t}\n\tgpTexCoord3iv = uintptr(getProcAddr(\"glTexCoord3iv\"))\n\tif gpTexCoord3iv == 0 {\n\t\treturn errors.New(\"glTexCoord3iv\")\n\t}\n\tgpTexCoord3s = uintptr(getProcAddr(\"glTexCoord3s\"))\n\tif gpTexCoord3s == 0 {\n\t\treturn errors.New(\"glTexCoord3s\")\n\t}\n\tgpTexCoord3sv = uintptr(getProcAddr(\"glTexCoord3sv\"))\n\tif gpTexCoord3sv == 0 {\n\t\treturn errors.New(\"glTexCoord3sv\")\n\t}\n\tgpTexCoord3xOES = uintptr(getProcAddr(\"glTexCoord3xOES\"))\n\tgpTexCoord3xvOES = uintptr(getProcAddr(\"glTexCoord3xvOES\"))\n\tgpTexCoord4bOES = uintptr(getProcAddr(\"glTexCoord4bOES\"))\n\tgpTexCoord4bvOES = uintptr(getProcAddr(\"glTexCoord4bvOES\"))\n\tgpTexCoord4d = uintptr(getProcAddr(\"glTexCoord4d\"))\n\tif gpTexCoord4d == 0 {\n\t\treturn errors.New(\"glTexCoord4d\")\n\t}\n\tgpTexCoord4dv = uintptr(getProcAddr(\"glTexCoord4dv\"))\n\tif gpTexCoord4dv == 0 {\n\t\treturn errors.New(\"glTexCoord4dv\")\n\t}\n\tgpTexCoord4f = uintptr(getProcAddr(\"glTexCoord4f\"))\n\tif gpTexCoord4f == 0 {\n\t\treturn errors.New(\"glTexCoord4f\")\n\t}\n\tgpTexCoord4fColor4fNormal3fVertex4fSUN = uintptr(getProcAddr(\"glTexCoord4fColor4fNormal3fVertex4fSUN\"))\n\tgpTexCoord4fColor4fNormal3fVertex4fvSUN = uintptr(getProcAddr(\"glTexCoord4fColor4fNormal3fVertex4fvSUN\"))\n\tgpTexCoord4fVertex4fSUN = uintptr(getProcAddr(\"glTexCoord4fVertex4fSUN\"))\n\tgpTexCoord4fVertex4fvSUN = uintptr(getProcAddr(\"glTexCoord4fVertex4fvSUN\"))\n\tgpTexCoord4fv = uintptr(getProcAddr(\"glTexCoord4fv\"))\n\tif gpTexCoord4fv == 0 {\n\t\treturn errors.New(\"glTexCoord4fv\")\n\t}\n\tgpTexCoord4hNV = uintptr(getProcAddr(\"glTexCoord4hNV\"))\n\tgpTexCoord4hvNV = uintptr(getProcAddr(\"glTexCoord4hvNV\"))\n\tgpTexCoord4i = uintptr(getProcAddr(\"glTexCoord4i\"))\n\tif gpTexCoord4i == 0 {\n\t\treturn errors.New(\"glTexCoord4i\")\n\t}\n\tgpTexCoord4iv = uintptr(getProcAddr(\"glTexCoord4iv\"))\n\tif gpTexCoord4iv == 0 {\n\t\treturn errors.New(\"glTexCoord4iv\")\n\t}\n\tgpTexCoord4s = uintptr(getProcAddr(\"glTexCoord4s\"))\n\tif gpTexCoord4s == 0 {\n\t\treturn errors.New(\"glTexCoord4s\")\n\t}\n\tgpTexCoord4sv = uintptr(getProcAddr(\"glTexCoord4sv\"))\n\tif gpTexCoord4sv == 0 {\n\t\treturn errors.New(\"glTexCoord4sv\")\n\t}\n\tgpTexCoord4xOES = uintptr(getProcAddr(\"glTexCoord4xOES\"))\n\tgpTexCoord4xvOES = uintptr(getProcAddr(\"glTexCoord4xvOES\"))\n\tgpTexCoordFormatNV = uintptr(getProcAddr(\"glTexCoordFormatNV\"))\n\tgpTexCoordPointer = uintptr(getProcAddr(\"glTexCoordPointer\"))\n\tif gpTexCoordPointer == 0 {\n\t\treturn errors.New(\"glTexCoordPointer\")\n\t}\n\tgpTexCoordPointerEXT = uintptr(getProcAddr(\"glTexCoordPointerEXT\"))\n\tgpTexCoordPointerListIBM = uintptr(getProcAddr(\"glTexCoordPointerListIBM\"))\n\tgpTexCoordPointervINTEL = uintptr(getProcAddr(\"glTexCoordPointervINTEL\"))\n\tgpTexEnvf = uintptr(getProcAddr(\"glTexEnvf\"))\n\tif gpTexEnvf == 0 {\n\t\treturn errors.New(\"glTexEnvf\")\n\t}\n\tgpTexEnvfv = uintptr(getProcAddr(\"glTexEnvfv\"))\n\tif gpTexEnvfv == 0 {\n\t\treturn errors.New(\"glTexEnvfv\")\n\t}\n\tgpTexEnvi = uintptr(getProcAddr(\"glTexEnvi\"))\n\tif gpTexEnvi == 0 {\n\t\treturn errors.New(\"glTexEnvi\")\n\t}\n\tgpTexEnviv = uintptr(getProcAddr(\"glTexEnviv\"))\n\tif gpTexEnviv == 0 {\n\t\treturn errors.New(\"glTexEnviv\")\n\t}\n\tgpTexEnvxOES = uintptr(getProcAddr(\"glTexEnvxOES\"))\n\tgpTexEnvxvOES = uintptr(getProcAddr(\"glTexEnvxvOES\"))\n\tgpTexFilterFuncSGIS = uintptr(getProcAddr(\"glTexFilterFuncSGIS\"))\n\tgpTexGend = uintptr(getProcAddr(\"glTexGend\"))\n\tif gpTexGend == 0 {\n\t\treturn errors.New(\"glTexGend\")\n\t}\n\tgpTexGendv = uintptr(getProcAddr(\"glTexGendv\"))\n\tif gpTexGendv == 0 {\n\t\treturn errors.New(\"glTexGendv\")\n\t}\n\tgpTexGenf = uintptr(getProcAddr(\"glTexGenf\"))\n\tif gpTexGenf == 0 {\n\t\treturn errors.New(\"glTexGenf\")\n\t}\n\tgpTexGenfv = uintptr(getProcAddr(\"glTexGenfv\"))\n\tif gpTexGenfv == 0 {\n\t\treturn errors.New(\"glTexGenfv\")\n\t}\n\tgpTexGeni = uintptr(getProcAddr(\"glTexGeni\"))\n\tif gpTexGeni == 0 {\n\t\treturn errors.New(\"glTexGeni\")\n\t}\n\tgpTexGeniv = uintptr(getProcAddr(\"glTexGeniv\"))\n\tif gpTexGeniv == 0 {\n\t\treturn errors.New(\"glTexGeniv\")\n\t}\n\tgpTexGenxOES = uintptr(getProcAddr(\"glTexGenxOES\"))\n\tgpTexGenxvOES = uintptr(getProcAddr(\"glTexGenxvOES\"))\n\tgpTexImage1D = uintptr(getProcAddr(\"glTexImage1D\"))\n\tif gpTexImage1D == 0 {\n\t\treturn errors.New(\"glTexImage1D\")\n\t}\n\tgpTexImage2D = uintptr(getProcAddr(\"glTexImage2D\"))\n\tif gpTexImage2D == 0 {\n\t\treturn errors.New(\"glTexImage2D\")\n\t}\n\tgpTexImage2DMultisample = uintptr(getProcAddr(\"glTexImage2DMultisample\"))\n\tgpTexImage2DMultisampleCoverageNV = uintptr(getProcAddr(\"glTexImage2DMultisampleCoverageNV\"))\n\tgpTexImage3D = uintptr(getProcAddr(\"glTexImage3D\"))\n\tif gpTexImage3D == 0 {\n\t\treturn errors.New(\"glTexImage3D\")\n\t}\n\tgpTexImage3DEXT = uintptr(getProcAddr(\"glTexImage3DEXT\"))\n\tgpTexImage3DMultisample = uintptr(getProcAddr(\"glTexImage3DMultisample\"))\n\tgpTexImage3DMultisampleCoverageNV = uintptr(getProcAddr(\"glTexImage3DMultisampleCoverageNV\"))\n\tgpTexImage4DSGIS = uintptr(getProcAddr(\"glTexImage4DSGIS\"))\n\tgpTexPageCommitmentARB = uintptr(getProcAddr(\"glTexPageCommitmentARB\"))\n\tgpTexParameterIivEXT = uintptr(getProcAddr(\"glTexParameterIivEXT\"))\n\tgpTexParameterIuivEXT = uintptr(getProcAddr(\"glTexParameterIuivEXT\"))\n\tgpTexParameterf = uintptr(getProcAddr(\"glTexParameterf\"))\n\tif gpTexParameterf == 0 {\n\t\treturn errors.New(\"glTexParameterf\")\n\t}\n\tgpTexParameterfv = uintptr(getProcAddr(\"glTexParameterfv\"))\n\tif gpTexParameterfv == 0 {\n\t\treturn errors.New(\"glTexParameterfv\")\n\t}\n\tgpTexParameteri = uintptr(getProcAddr(\"glTexParameteri\"))\n\tif gpTexParameteri == 0 {\n\t\treturn errors.New(\"glTexParameteri\")\n\t}\n\tgpTexParameteriv = uintptr(getProcAddr(\"glTexParameteriv\"))\n\tif gpTexParameteriv == 0 {\n\t\treturn errors.New(\"glTexParameteriv\")\n\t}\n\tgpTexParameterxOES = uintptr(getProcAddr(\"glTexParameterxOES\"))\n\tgpTexParameterxvOES = uintptr(getProcAddr(\"glTexParameterxvOES\"))\n\tgpTexRenderbufferNV = uintptr(getProcAddr(\"glTexRenderbufferNV\"))\n\tgpTexStorage1D = uintptr(getProcAddr(\"glTexStorage1D\"))\n\tgpTexStorage2D = uintptr(getProcAddr(\"glTexStorage2D\"))\n\tgpTexStorage2DMultisample = uintptr(getProcAddr(\"glTexStorage2DMultisample\"))\n\tgpTexStorage3D = uintptr(getProcAddr(\"glTexStorage3D\"))\n\tgpTexStorage3DMultisample = uintptr(getProcAddr(\"glTexStorage3DMultisample\"))\n\tgpTexStorageMem1DEXT = uintptr(getProcAddr(\"glTexStorageMem1DEXT\"))\n\tgpTexStorageMem2DEXT = uintptr(getProcAddr(\"glTexStorageMem2DEXT\"))\n\tgpTexStorageMem2DMultisampleEXT = uintptr(getProcAddr(\"glTexStorageMem2DMultisampleEXT\"))\n\tgpTexStorageMem3DEXT = uintptr(getProcAddr(\"glTexStorageMem3DEXT\"))\n\tgpTexStorageMem3DMultisampleEXT = uintptr(getProcAddr(\"glTexStorageMem3DMultisampleEXT\"))\n\tgpTexStorageSparseAMD = uintptr(getProcAddr(\"glTexStorageSparseAMD\"))\n\tgpTexSubImage1D = uintptr(getProcAddr(\"glTexSubImage1D\"))\n\tif gpTexSubImage1D == 0 {\n\t\treturn errors.New(\"glTexSubImage1D\")\n\t}\n\tgpTexSubImage1DEXT = uintptr(getProcAddr(\"glTexSubImage1DEXT\"))\n\tgpTexSubImage2D = uintptr(getProcAddr(\"glTexSubImage2D\"))\n\tif gpTexSubImage2D == 0 {\n\t\treturn errors.New(\"glTexSubImage2D\")\n\t}\n\tgpTexSubImage2DEXT = uintptr(getProcAddr(\"glTexSubImage2DEXT\"))\n\tgpTexSubImage3D = uintptr(getProcAddr(\"glTexSubImage3D\"))\n\tif gpTexSubImage3D == 0 {\n\t\treturn errors.New(\"glTexSubImage3D\")\n\t}\n\tgpTexSubImage3DEXT = uintptr(getProcAddr(\"glTexSubImage3DEXT\"))\n\tgpTexSubImage4DSGIS = uintptr(getProcAddr(\"glTexSubImage4DSGIS\"))\n\tgpTextureBarrier = uintptr(getProcAddr(\"glTextureBarrier\"))\n\tgpTextureBarrierNV = uintptr(getProcAddr(\"glTextureBarrierNV\"))\n\tgpTextureBuffer = uintptr(getProcAddr(\"glTextureBuffer\"))\n\tgpTextureBufferEXT = uintptr(getProcAddr(\"glTextureBufferEXT\"))\n\tgpTextureBufferRange = uintptr(getProcAddr(\"glTextureBufferRange\"))\n\tgpTextureBufferRangeEXT = uintptr(getProcAddr(\"glTextureBufferRangeEXT\"))\n\tgpTextureColorMaskSGIS = uintptr(getProcAddr(\"glTextureColorMaskSGIS\"))\n\tgpTextureImage1DEXT = uintptr(getProcAddr(\"glTextureImage1DEXT\"))\n\tgpTextureImage2DEXT = uintptr(getProcAddr(\"glTextureImage2DEXT\"))\n\tgpTextureImage2DMultisampleCoverageNV = uintptr(getProcAddr(\"glTextureImage2DMultisampleCoverageNV\"))\n\tgpTextureImage2DMultisampleNV = uintptr(getProcAddr(\"glTextureImage2DMultisampleNV\"))\n\tgpTextureImage3DEXT = uintptr(getProcAddr(\"glTextureImage3DEXT\"))\n\tgpTextureImage3DMultisampleCoverageNV = uintptr(getProcAddr(\"glTextureImage3DMultisampleCoverageNV\"))\n\tgpTextureImage3DMultisampleNV = uintptr(getProcAddr(\"glTextureImage3DMultisampleNV\"))\n\tgpTextureLightEXT = uintptr(getProcAddr(\"glTextureLightEXT\"))\n\tgpTextureMaterialEXT = uintptr(getProcAddr(\"glTextureMaterialEXT\"))\n\tgpTextureNormalEXT = uintptr(getProcAddr(\"glTextureNormalEXT\"))\n\tgpTexturePageCommitmentEXT = uintptr(getProcAddr(\"glTexturePageCommitmentEXT\"))\n\tgpTextureParameterIiv = uintptr(getProcAddr(\"glTextureParameterIiv\"))\n\tgpTextureParameterIivEXT = uintptr(getProcAddr(\"glTextureParameterIivEXT\"))\n\tgpTextureParameterIuiv = uintptr(getProcAddr(\"glTextureParameterIuiv\"))\n\tgpTextureParameterIuivEXT = uintptr(getProcAddr(\"glTextureParameterIuivEXT\"))\n\tgpTextureParameterf = uintptr(getProcAddr(\"glTextureParameterf\"))\n\tgpTextureParameterfEXT = uintptr(getProcAddr(\"glTextureParameterfEXT\"))\n\tgpTextureParameterfv = uintptr(getProcAddr(\"glTextureParameterfv\"))\n\tgpTextureParameterfvEXT = uintptr(getProcAddr(\"glTextureParameterfvEXT\"))\n\tgpTextureParameteri = uintptr(getProcAddr(\"glTextureParameteri\"))\n\tgpTextureParameteriEXT = uintptr(getProcAddr(\"glTextureParameteriEXT\"))\n\tgpTextureParameteriv = uintptr(getProcAddr(\"glTextureParameteriv\"))\n\tgpTextureParameterivEXT = uintptr(getProcAddr(\"glTextureParameterivEXT\"))\n\tgpTextureRangeAPPLE = uintptr(getProcAddr(\"glTextureRangeAPPLE\"))\n\tgpTextureRenderbufferEXT = uintptr(getProcAddr(\"glTextureRenderbufferEXT\"))\n\tgpTextureStorage1D = uintptr(getProcAddr(\"glTextureStorage1D\"))\n\tgpTextureStorage1DEXT = uintptr(getProcAddr(\"glTextureStorage1DEXT\"))\n\tgpTextureStorage2D = uintptr(getProcAddr(\"glTextureStorage2D\"))\n\tgpTextureStorage2DEXT = uintptr(getProcAddr(\"glTextureStorage2DEXT\"))\n\tgpTextureStorage2DMultisample = uintptr(getProcAddr(\"glTextureStorage2DMultisample\"))\n\tgpTextureStorage2DMultisampleEXT = uintptr(getProcAddr(\"glTextureStorage2DMultisampleEXT\"))\n\tgpTextureStorage3D = uintptr(getProcAddr(\"glTextureStorage3D\"))\n\tgpTextureStorage3DEXT = uintptr(getProcAddr(\"glTextureStorage3DEXT\"))\n\tgpTextureStorage3DMultisample = uintptr(getProcAddr(\"glTextureStorage3DMultisample\"))\n\tgpTextureStorage3DMultisampleEXT = uintptr(getProcAddr(\"glTextureStorage3DMultisampleEXT\"))\n\tgpTextureStorageMem1DEXT = uintptr(getProcAddr(\"glTextureStorageMem1DEXT\"))\n\tgpTextureStorageMem2DEXT = uintptr(getProcAddr(\"glTextureStorageMem2DEXT\"))\n\tgpTextureStorageMem2DMultisampleEXT = uintptr(getProcAddr(\"glTextureStorageMem2DMultisampleEXT\"))\n\tgpTextureStorageMem3DEXT = uintptr(getProcAddr(\"glTextureStorageMem3DEXT\"))\n\tgpTextureStorageMem3DMultisampleEXT = uintptr(getProcAddr(\"glTextureStorageMem3DMultisampleEXT\"))\n\tgpTextureStorageSparseAMD = uintptr(getProcAddr(\"glTextureStorageSparseAMD\"))\n\tgpTextureSubImage1D = uintptr(getProcAddr(\"glTextureSubImage1D\"))\n\tgpTextureSubImage1DEXT = uintptr(getProcAddr(\"glTextureSubImage1DEXT\"))\n\tgpTextureSubImage2D = uintptr(getProcAddr(\"glTextureSubImage2D\"))\n\tgpTextureSubImage2DEXT = uintptr(getProcAddr(\"glTextureSubImage2DEXT\"))\n\tgpTextureSubImage3D = uintptr(getProcAddr(\"glTextureSubImage3D\"))\n\tgpTextureSubImage3DEXT = uintptr(getProcAddr(\"glTextureSubImage3DEXT\"))\n\tgpTextureView = uintptr(getProcAddr(\"glTextureView\"))\n\tgpTrackMatrixNV = uintptr(getProcAddr(\"glTrackMatrixNV\"))\n\tgpTransformFeedbackAttribsNV = uintptr(getProcAddr(\"glTransformFeedbackAttribsNV\"))\n\tgpTransformFeedbackBufferBase = uintptr(getProcAddr(\"glTransformFeedbackBufferBase\"))\n\tgpTransformFeedbackBufferRange = uintptr(getProcAddr(\"glTransformFeedbackBufferRange\"))\n\tgpTransformFeedbackStreamAttribsNV = uintptr(getProcAddr(\"glTransformFeedbackStreamAttribsNV\"))\n\tgpTransformFeedbackVaryingsEXT = uintptr(getProcAddr(\"glTransformFeedbackVaryingsEXT\"))\n\tgpTransformFeedbackVaryingsNV = uintptr(getProcAddr(\"glTransformFeedbackVaryingsNV\"))\n\tgpTransformPathNV = uintptr(getProcAddr(\"glTransformPathNV\"))\n\tgpTranslated = uintptr(getProcAddr(\"glTranslated\"))\n\tif gpTranslated == 0 {\n\t\treturn errors.New(\"glTranslated\")\n\t}\n\tgpTranslatef = uintptr(getProcAddr(\"glTranslatef\"))\n\tif gpTranslatef == 0 {\n\t\treturn errors.New(\"glTranslatef\")\n\t}\n\tgpTranslatexOES = uintptr(getProcAddr(\"glTranslatexOES\"))\n\tgpUniform1d = uintptr(getProcAddr(\"glUniform1d\"))\n\tgpUniform1dv = uintptr(getProcAddr(\"glUniform1dv\"))\n\tgpUniform1f = uintptr(getProcAddr(\"glUniform1f\"))\n\tif gpUniform1f == 0 {\n\t\treturn errors.New(\"glUniform1f\")\n\t}\n\tgpUniform1fARB = uintptr(getProcAddr(\"glUniform1fARB\"))\n\tgpUniform1fv = uintptr(getProcAddr(\"glUniform1fv\"))\n\tif gpUniform1fv == 0 {\n\t\treturn errors.New(\"glUniform1fv\")\n\t}\n\tgpUniform1fvARB = uintptr(getProcAddr(\"glUniform1fvARB\"))\n\tgpUniform1i = uintptr(getProcAddr(\"glUniform1i\"))\n\tif gpUniform1i == 0 {\n\t\treturn errors.New(\"glUniform1i\")\n\t}\n\tgpUniform1i64ARB = uintptr(getProcAddr(\"glUniform1i64ARB\"))\n\tgpUniform1i64NV = uintptr(getProcAddr(\"glUniform1i64NV\"))\n\tgpUniform1i64vARB = uintptr(getProcAddr(\"glUniform1i64vARB\"))\n\tgpUniform1i64vNV = uintptr(getProcAddr(\"glUniform1i64vNV\"))\n\tgpUniform1iARB = uintptr(getProcAddr(\"glUniform1iARB\"))\n\tgpUniform1iv = uintptr(getProcAddr(\"glUniform1iv\"))\n\tif gpUniform1iv == 0 {\n\t\treturn errors.New(\"glUniform1iv\")\n\t}\n\tgpUniform1ivARB = uintptr(getProcAddr(\"glUniform1ivARB\"))\n\tgpUniform1ui64ARB = uintptr(getProcAddr(\"glUniform1ui64ARB\"))\n\tgpUniform1ui64NV = uintptr(getProcAddr(\"glUniform1ui64NV\"))\n\tgpUniform1ui64vARB = uintptr(getProcAddr(\"glUniform1ui64vARB\"))\n\tgpUniform1ui64vNV = uintptr(getProcAddr(\"glUniform1ui64vNV\"))\n\tgpUniform1uiEXT = uintptr(getProcAddr(\"glUniform1uiEXT\"))\n\tgpUniform1uivEXT = uintptr(getProcAddr(\"glUniform1uivEXT\"))\n\tgpUniform2d = uintptr(getProcAddr(\"glUniform2d\"))\n\tgpUniform2dv = uintptr(getProcAddr(\"glUniform2dv\"))\n\tgpUniform2f = uintptr(getProcAddr(\"glUniform2f\"))\n\tif gpUniform2f == 0 {\n\t\treturn errors.New(\"glUniform2f\")\n\t}\n\tgpUniform2fARB = uintptr(getProcAddr(\"glUniform2fARB\"))\n\tgpUniform2fv = uintptr(getProcAddr(\"glUniform2fv\"))\n\tif gpUniform2fv == 0 {\n\t\treturn errors.New(\"glUniform2fv\")\n\t}\n\tgpUniform2fvARB = uintptr(getProcAddr(\"glUniform2fvARB\"))\n\tgpUniform2i = uintptr(getProcAddr(\"glUniform2i\"))\n\tif gpUniform2i == 0 {\n\t\treturn errors.New(\"glUniform2i\")\n\t}\n\tgpUniform2i64ARB = uintptr(getProcAddr(\"glUniform2i64ARB\"))\n\tgpUniform2i64NV = uintptr(getProcAddr(\"glUniform2i64NV\"))\n\tgpUniform2i64vARB = uintptr(getProcAddr(\"glUniform2i64vARB\"))\n\tgpUniform2i64vNV = uintptr(getProcAddr(\"glUniform2i64vNV\"))\n\tgpUniform2iARB = uintptr(getProcAddr(\"glUniform2iARB\"))\n\tgpUniform2iv = uintptr(getProcAddr(\"glUniform2iv\"))\n\tif gpUniform2iv == 0 {\n\t\treturn errors.New(\"glUniform2iv\")\n\t}\n\tgpUniform2ivARB = uintptr(getProcAddr(\"glUniform2ivARB\"))\n\tgpUniform2ui64ARB = uintptr(getProcAddr(\"glUniform2ui64ARB\"))\n\tgpUniform2ui64NV = uintptr(getProcAddr(\"glUniform2ui64NV\"))\n\tgpUniform2ui64vARB = uintptr(getProcAddr(\"glUniform2ui64vARB\"))\n\tgpUniform2ui64vNV = uintptr(getProcAddr(\"glUniform2ui64vNV\"))\n\tgpUniform2uiEXT = uintptr(getProcAddr(\"glUniform2uiEXT\"))\n\tgpUniform2uivEXT = uintptr(getProcAddr(\"glUniform2uivEXT\"))\n\tgpUniform3d = uintptr(getProcAddr(\"glUniform3d\"))\n\tgpUniform3dv = uintptr(getProcAddr(\"glUniform3dv\"))\n\tgpUniform3f = uintptr(getProcAddr(\"glUniform3f\"))\n\tif gpUniform3f == 0 {\n\t\treturn errors.New(\"glUniform3f\")\n\t}\n\tgpUniform3fARB = uintptr(getProcAddr(\"glUniform3fARB\"))\n\tgpUniform3fv = uintptr(getProcAddr(\"glUniform3fv\"))\n\tif gpUniform3fv == 0 {\n\t\treturn errors.New(\"glUniform3fv\")\n\t}\n\tgpUniform3fvARB = uintptr(getProcAddr(\"glUniform3fvARB\"))\n\tgpUniform3i = uintptr(getProcAddr(\"glUniform3i\"))\n\tif gpUniform3i == 0 {\n\t\treturn errors.New(\"glUniform3i\")\n\t}\n\tgpUniform3i64ARB = uintptr(getProcAddr(\"glUniform3i64ARB\"))\n\tgpUniform3i64NV = uintptr(getProcAddr(\"glUniform3i64NV\"))\n\tgpUniform3i64vARB = uintptr(getProcAddr(\"glUniform3i64vARB\"))\n\tgpUniform3i64vNV = uintptr(getProcAddr(\"glUniform3i64vNV\"))\n\tgpUniform3iARB = uintptr(getProcAddr(\"glUniform3iARB\"))\n\tgpUniform3iv = uintptr(getProcAddr(\"glUniform3iv\"))\n\tif gpUniform3iv == 0 {\n\t\treturn errors.New(\"glUniform3iv\")\n\t}\n\tgpUniform3ivARB = uintptr(getProcAddr(\"glUniform3ivARB\"))\n\tgpUniform3ui64ARB = uintptr(getProcAddr(\"glUniform3ui64ARB\"))\n\tgpUniform3ui64NV = uintptr(getProcAddr(\"glUniform3ui64NV\"))\n\tgpUniform3ui64vARB = uintptr(getProcAddr(\"glUniform3ui64vARB\"))\n\tgpUniform3ui64vNV = uintptr(getProcAddr(\"glUniform3ui64vNV\"))\n\tgpUniform3uiEXT = uintptr(getProcAddr(\"glUniform3uiEXT\"))\n\tgpUniform3uivEXT = uintptr(getProcAddr(\"glUniform3uivEXT\"))\n\tgpUniform4d = uintptr(getProcAddr(\"glUniform4d\"))\n\tgpUniform4dv = uintptr(getProcAddr(\"glUniform4dv\"))\n\tgpUniform4f = uintptr(getProcAddr(\"glUniform4f\"))\n\tif gpUniform4f == 0 {\n\t\treturn errors.New(\"glUniform4f\")\n\t}\n\tgpUniform4fARB = uintptr(getProcAddr(\"glUniform4fARB\"))\n\tgpUniform4fv = uintptr(getProcAddr(\"glUniform4fv\"))\n\tif gpUniform4fv == 0 {\n\t\treturn errors.New(\"glUniform4fv\")\n\t}\n\tgpUniform4fvARB = uintptr(getProcAddr(\"glUniform4fvARB\"))\n\tgpUniform4i = uintptr(getProcAddr(\"glUniform4i\"))\n\tif gpUniform4i == 0 {\n\t\treturn errors.New(\"glUniform4i\")\n\t}\n\tgpUniform4i64ARB = uintptr(getProcAddr(\"glUniform4i64ARB\"))\n\tgpUniform4i64NV = uintptr(getProcAddr(\"glUniform4i64NV\"))\n\tgpUniform4i64vARB = uintptr(getProcAddr(\"glUniform4i64vARB\"))\n\tgpUniform4i64vNV = uintptr(getProcAddr(\"glUniform4i64vNV\"))\n\tgpUniform4iARB = uintptr(getProcAddr(\"glUniform4iARB\"))\n\tgpUniform4iv = uintptr(getProcAddr(\"glUniform4iv\"))\n\tif gpUniform4iv == 0 {\n\t\treturn errors.New(\"glUniform4iv\")\n\t}\n\tgpUniform4ivARB = uintptr(getProcAddr(\"glUniform4ivARB\"))\n\tgpUniform4ui64ARB = uintptr(getProcAddr(\"glUniform4ui64ARB\"))\n\tgpUniform4ui64NV = uintptr(getProcAddr(\"glUniform4ui64NV\"))\n\tgpUniform4ui64vARB = uintptr(getProcAddr(\"glUniform4ui64vARB\"))\n\tgpUniform4ui64vNV = uintptr(getProcAddr(\"glUniform4ui64vNV\"))\n\tgpUniform4uiEXT = uintptr(getProcAddr(\"glUniform4uiEXT\"))\n\tgpUniform4uivEXT = uintptr(getProcAddr(\"glUniform4uivEXT\"))\n\tgpUniformBlockBinding = uintptr(getProcAddr(\"glUniformBlockBinding\"))\n\tgpUniformBufferEXT = uintptr(getProcAddr(\"glUniformBufferEXT\"))\n\tgpUniformHandleui64ARB = uintptr(getProcAddr(\"glUniformHandleui64ARB\"))\n\tgpUniformHandleui64NV = uintptr(getProcAddr(\"glUniformHandleui64NV\"))\n\tgpUniformHandleui64vARB = uintptr(getProcAddr(\"glUniformHandleui64vARB\"))\n\tgpUniformHandleui64vNV = uintptr(getProcAddr(\"glUniformHandleui64vNV\"))\n\tgpUniformMatrix2dv = uintptr(getProcAddr(\"glUniformMatrix2dv\"))\n\tgpUniformMatrix2fv = uintptr(getProcAddr(\"glUniformMatrix2fv\"))\n\tif gpUniformMatrix2fv == 0 {\n\t\treturn errors.New(\"glUniformMatrix2fv\")\n\t}\n\tgpUniformMatrix2fvARB = uintptr(getProcAddr(\"glUniformMatrix2fvARB\"))\n\tgpUniformMatrix2x3dv = uintptr(getProcAddr(\"glUniformMatrix2x3dv\"))\n\tgpUniformMatrix2x3fv = uintptr(getProcAddr(\"glUniformMatrix2x3fv\"))\n\tif gpUniformMatrix2x3fv == 0 {\n\t\treturn errors.New(\"glUniformMatrix2x3fv\")\n\t}\n\tgpUniformMatrix2x4dv = uintptr(getProcAddr(\"glUniformMatrix2x4dv\"))\n\tgpUniformMatrix2x4fv = uintptr(getProcAddr(\"glUniformMatrix2x4fv\"))\n\tif gpUniformMatrix2x4fv == 0 {\n\t\treturn errors.New(\"glUniformMatrix2x4fv\")\n\t}\n\tgpUniformMatrix3dv = uintptr(getProcAddr(\"glUniformMatrix3dv\"))\n\tgpUniformMatrix3fv = uintptr(getProcAddr(\"glUniformMatrix3fv\"))\n\tif gpUniformMatrix3fv == 0 {\n\t\treturn errors.New(\"glUniformMatrix3fv\")\n\t}\n\tgpUniformMatrix3fvARB = uintptr(getProcAddr(\"glUniformMatrix3fvARB\"))\n\tgpUniformMatrix3x2dv = uintptr(getProcAddr(\"glUniformMatrix3x2dv\"))\n\tgpUniformMatrix3x2fv = uintptr(getProcAddr(\"glUniformMatrix3x2fv\"))\n\tif gpUniformMatrix3x2fv == 0 {\n\t\treturn errors.New(\"glUniformMatrix3x2fv\")\n\t}\n\tgpUniformMatrix3x4dv = uintptr(getProcAddr(\"glUniformMatrix3x4dv\"))\n\tgpUniformMatrix3x4fv = uintptr(getProcAddr(\"glUniformMatrix3x4fv\"))\n\tif gpUniformMatrix3x4fv == 0 {\n\t\treturn errors.New(\"glUniformMatrix3x4fv\")\n\t}\n\tgpUniformMatrix4dv = uintptr(getProcAddr(\"glUniformMatrix4dv\"))\n\tgpUniformMatrix4fv = uintptr(getProcAddr(\"glUniformMatrix4fv\"))\n\tif gpUniformMatrix4fv == 0 {\n\t\treturn errors.New(\"glUniformMatrix4fv\")\n\t}\n\tgpUniformMatrix4fvARB = uintptr(getProcAddr(\"glUniformMatrix4fvARB\"))\n\tgpUniformMatrix4x2dv = uintptr(getProcAddr(\"glUniformMatrix4x2dv\"))\n\tgpUniformMatrix4x2fv = uintptr(getProcAddr(\"glUniformMatrix4x2fv\"))\n\tif gpUniformMatrix4x2fv == 0 {\n\t\treturn errors.New(\"glUniformMatrix4x2fv\")\n\t}\n\tgpUniformMatrix4x3dv = uintptr(getProcAddr(\"glUniformMatrix4x3dv\"))\n\tgpUniformMatrix4x3fv = uintptr(getProcAddr(\"glUniformMatrix4x3fv\"))\n\tif gpUniformMatrix4x3fv == 0 {\n\t\treturn errors.New(\"glUniformMatrix4x3fv\")\n\t}\n\tgpUniformSubroutinesuiv = uintptr(getProcAddr(\"glUniformSubroutinesuiv\"))\n\tgpUniformui64NV = uintptr(getProcAddr(\"glUniformui64NV\"))\n\tgpUniformui64vNV = uintptr(getProcAddr(\"glUniformui64vNV\"))\n\tgpUnlockArraysEXT = uintptr(getProcAddr(\"glUnlockArraysEXT\"))\n\tgpUnmapBuffer = uintptr(getProcAddr(\"glUnmapBuffer\"))\n\tif gpUnmapBuffer == 0 {\n\t\treturn errors.New(\"glUnmapBuffer\")\n\t}\n\tgpUnmapBufferARB = uintptr(getProcAddr(\"glUnmapBufferARB\"))\n\tgpUnmapNamedBuffer = uintptr(getProcAddr(\"glUnmapNamedBuffer\"))\n\tgpUnmapNamedBufferEXT = uintptr(getProcAddr(\"glUnmapNamedBufferEXT\"))\n\tgpUnmapObjectBufferATI = uintptr(getProcAddr(\"glUnmapObjectBufferATI\"))\n\tgpUnmapTexture2DINTEL = uintptr(getProcAddr(\"glUnmapTexture2DINTEL\"))\n\tgpUpdateObjectBufferATI = uintptr(getProcAddr(\"glUpdateObjectBufferATI\"))\n\tgpUseProgram = uintptr(getProcAddr(\"glUseProgram\"))\n\tif gpUseProgram == 0 {\n\t\treturn errors.New(\"glUseProgram\")\n\t}\n\tgpUseProgramObjectARB = uintptr(getProcAddr(\"glUseProgramObjectARB\"))\n\tgpUseProgramStages = uintptr(getProcAddr(\"glUseProgramStages\"))\n\tgpUseProgramStagesEXT = uintptr(getProcAddr(\"glUseProgramStagesEXT\"))\n\tgpUseShaderProgramEXT = uintptr(getProcAddr(\"glUseShaderProgramEXT\"))\n\tgpVDPAUFiniNV = uintptr(getProcAddr(\"glVDPAUFiniNV\"))\n\tgpVDPAUGetSurfaceivNV = uintptr(getProcAddr(\"glVDPAUGetSurfaceivNV\"))\n\tgpVDPAUInitNV = uintptr(getProcAddr(\"glVDPAUInitNV\"))\n\tgpVDPAUIsSurfaceNV = uintptr(getProcAddr(\"glVDPAUIsSurfaceNV\"))\n\tgpVDPAUMapSurfacesNV = uintptr(getProcAddr(\"glVDPAUMapSurfacesNV\"))\n\tgpVDPAURegisterOutputSurfaceNV = uintptr(getProcAddr(\"glVDPAURegisterOutputSurfaceNV\"))\n\tgpVDPAURegisterVideoSurfaceNV = uintptr(getProcAddr(\"glVDPAURegisterVideoSurfaceNV\"))\n\tgpVDPAUSurfaceAccessNV = uintptr(getProcAddr(\"glVDPAUSurfaceAccessNV\"))\n\tgpVDPAUUnmapSurfacesNV = uintptr(getProcAddr(\"glVDPAUUnmapSurfacesNV\"))\n\tgpVDPAUUnregisterSurfaceNV = uintptr(getProcAddr(\"glVDPAUUnregisterSurfaceNV\"))\n\tgpValidateProgram = uintptr(getProcAddr(\"glValidateProgram\"))\n\tif gpValidateProgram == 0 {\n\t\treturn errors.New(\"glValidateProgram\")\n\t}\n\tgpValidateProgramARB = uintptr(getProcAddr(\"glValidateProgramARB\"))\n\tgpValidateProgramPipeline = uintptr(getProcAddr(\"glValidateProgramPipeline\"))\n\tgpValidateProgramPipelineEXT = uintptr(getProcAddr(\"glValidateProgramPipelineEXT\"))\n\tgpVariantArrayObjectATI = uintptr(getProcAddr(\"glVariantArrayObjectATI\"))\n\tgpVariantPointerEXT = uintptr(getProcAddr(\"glVariantPointerEXT\"))\n\tgpVariantbvEXT = uintptr(getProcAddr(\"glVariantbvEXT\"))\n\tgpVariantdvEXT = uintptr(getProcAddr(\"glVariantdvEXT\"))\n\tgpVariantfvEXT = uintptr(getProcAddr(\"glVariantfvEXT\"))\n\tgpVariantivEXT = uintptr(getProcAddr(\"glVariantivEXT\"))\n\tgpVariantsvEXT = uintptr(getProcAddr(\"glVariantsvEXT\"))\n\tgpVariantubvEXT = uintptr(getProcAddr(\"glVariantubvEXT\"))\n\tgpVariantuivEXT = uintptr(getProcAddr(\"glVariantuivEXT\"))\n\tgpVariantusvEXT = uintptr(getProcAddr(\"glVariantusvEXT\"))\n\tgpVertex2bOES = uintptr(getProcAddr(\"glVertex2bOES\"))\n\tgpVertex2bvOES = uintptr(getProcAddr(\"glVertex2bvOES\"))\n\tgpVertex2d = uintptr(getProcAddr(\"glVertex2d\"))\n\tif gpVertex2d == 0 {\n\t\treturn errors.New(\"glVertex2d\")\n\t}\n\tgpVertex2dv = uintptr(getProcAddr(\"glVertex2dv\"))\n\tif gpVertex2dv == 0 {\n\t\treturn errors.New(\"glVertex2dv\")\n\t}\n\tgpVertex2f = uintptr(getProcAddr(\"glVertex2f\"))\n\tif gpVertex2f == 0 {\n\t\treturn errors.New(\"glVertex2f\")\n\t}\n\tgpVertex2fv = uintptr(getProcAddr(\"glVertex2fv\"))\n\tif gpVertex2fv == 0 {\n\t\treturn errors.New(\"glVertex2fv\")\n\t}\n\tgpVertex2hNV = uintptr(getProcAddr(\"glVertex2hNV\"))\n\tgpVertex2hvNV = uintptr(getProcAddr(\"glVertex2hvNV\"))\n\tgpVertex2i = uintptr(getProcAddr(\"glVertex2i\"))\n\tif gpVertex2i == 0 {\n\t\treturn errors.New(\"glVertex2i\")\n\t}\n\tgpVertex2iv = uintptr(getProcAddr(\"glVertex2iv\"))\n\tif gpVertex2iv == 0 {\n\t\treturn errors.New(\"glVertex2iv\")\n\t}\n\tgpVertex2s = uintptr(getProcAddr(\"glVertex2s\"))\n\tif gpVertex2s == 0 {\n\t\treturn errors.New(\"glVertex2s\")\n\t}\n\tgpVertex2sv = uintptr(getProcAddr(\"glVertex2sv\"))\n\tif gpVertex2sv == 0 {\n\t\treturn errors.New(\"glVertex2sv\")\n\t}\n\tgpVertex2xOES = uintptr(getProcAddr(\"glVertex2xOES\"))\n\tgpVertex2xvOES = uintptr(getProcAddr(\"glVertex2xvOES\"))\n\tgpVertex3bOES = uintptr(getProcAddr(\"glVertex3bOES\"))\n\tgpVertex3bvOES = uintptr(getProcAddr(\"glVertex3bvOES\"))\n\tgpVertex3d = uintptr(getProcAddr(\"glVertex3d\"))\n\tif gpVertex3d == 0 {\n\t\treturn errors.New(\"glVertex3d\")\n\t}\n\tgpVertex3dv = uintptr(getProcAddr(\"glVertex3dv\"))\n\tif gpVertex3dv == 0 {\n\t\treturn errors.New(\"glVertex3dv\")\n\t}\n\tgpVertex3f = uintptr(getProcAddr(\"glVertex3f\"))\n\tif gpVertex3f == 0 {\n\t\treturn errors.New(\"glVertex3f\")\n\t}\n\tgpVertex3fv = uintptr(getProcAddr(\"glVertex3fv\"))\n\tif gpVertex3fv == 0 {\n\t\treturn errors.New(\"glVertex3fv\")\n\t}\n\tgpVertex3hNV = uintptr(getProcAddr(\"glVertex3hNV\"))\n\tgpVertex3hvNV = uintptr(getProcAddr(\"glVertex3hvNV\"))\n\tgpVertex3i = uintptr(getProcAddr(\"glVertex3i\"))\n\tif gpVertex3i == 0 {\n\t\treturn errors.New(\"glVertex3i\")\n\t}\n\tgpVertex3iv = uintptr(getProcAddr(\"glVertex3iv\"))\n\tif gpVertex3iv == 0 {\n\t\treturn errors.New(\"glVertex3iv\")\n\t}\n\tgpVertex3s = uintptr(getProcAddr(\"glVertex3s\"))\n\tif gpVertex3s == 0 {\n\t\treturn errors.New(\"glVertex3s\")\n\t}\n\tgpVertex3sv = uintptr(getProcAddr(\"glVertex3sv\"))\n\tif gpVertex3sv == 0 {\n\t\treturn errors.New(\"glVertex3sv\")\n\t}\n\tgpVertex3xOES = uintptr(getProcAddr(\"glVertex3xOES\"))\n\tgpVertex3xvOES = uintptr(getProcAddr(\"glVertex3xvOES\"))\n\tgpVertex4bOES = uintptr(getProcAddr(\"glVertex4bOES\"))\n\tgpVertex4bvOES = uintptr(getProcAddr(\"glVertex4bvOES\"))\n\tgpVertex4d = uintptr(getProcAddr(\"glVertex4d\"))\n\tif gpVertex4d == 0 {\n\t\treturn errors.New(\"glVertex4d\")\n\t}\n\tgpVertex4dv = uintptr(getProcAddr(\"glVertex4dv\"))\n\tif gpVertex4dv == 0 {\n\t\treturn errors.New(\"glVertex4dv\")\n\t}\n\tgpVertex4f = uintptr(getProcAddr(\"glVertex4f\"))\n\tif gpVertex4f == 0 {\n\t\treturn errors.New(\"glVertex4f\")\n\t}\n\tgpVertex4fv = uintptr(getProcAddr(\"glVertex4fv\"))\n\tif gpVertex4fv == 0 {\n\t\treturn errors.New(\"glVertex4fv\")\n\t}\n\tgpVertex4hNV = uintptr(getProcAddr(\"glVertex4hNV\"))\n\tgpVertex4hvNV = uintptr(getProcAddr(\"glVertex4hvNV\"))\n\tgpVertex4i = uintptr(getProcAddr(\"glVertex4i\"))\n\tif gpVertex4i == 0 {\n\t\treturn errors.New(\"glVertex4i\")\n\t}\n\tgpVertex4iv = uintptr(getProcAddr(\"glVertex4iv\"))\n\tif gpVertex4iv == 0 {\n\t\treturn errors.New(\"glVertex4iv\")\n\t}\n\tgpVertex4s = uintptr(getProcAddr(\"glVertex4s\"))\n\tif gpVertex4s == 0 {\n\t\treturn errors.New(\"glVertex4s\")\n\t}\n\tgpVertex4sv = uintptr(getProcAddr(\"glVertex4sv\"))\n\tif gpVertex4sv == 0 {\n\t\treturn errors.New(\"glVertex4sv\")\n\t}\n\tgpVertex4xOES = uintptr(getProcAddr(\"glVertex4xOES\"))\n\tgpVertex4xvOES = uintptr(getProcAddr(\"glVertex4xvOES\"))\n\tgpVertexArrayAttribBinding = uintptr(getProcAddr(\"glVertexArrayAttribBinding\"))\n\tgpVertexArrayAttribFormat = uintptr(getProcAddr(\"glVertexArrayAttribFormat\"))\n\tgpVertexArrayAttribIFormat = uintptr(getProcAddr(\"glVertexArrayAttribIFormat\"))\n\tgpVertexArrayAttribLFormat = uintptr(getProcAddr(\"glVertexArrayAttribLFormat\"))\n\tgpVertexArrayBindVertexBufferEXT = uintptr(getProcAddr(\"glVertexArrayBindVertexBufferEXT\"))\n\tgpVertexArrayBindingDivisor = uintptr(getProcAddr(\"glVertexArrayBindingDivisor\"))\n\tgpVertexArrayColorOffsetEXT = uintptr(getProcAddr(\"glVertexArrayColorOffsetEXT\"))\n\tgpVertexArrayEdgeFlagOffsetEXT = uintptr(getProcAddr(\"glVertexArrayEdgeFlagOffsetEXT\"))\n\tgpVertexArrayElementBuffer = uintptr(getProcAddr(\"glVertexArrayElementBuffer\"))\n\tgpVertexArrayFogCoordOffsetEXT = uintptr(getProcAddr(\"glVertexArrayFogCoordOffsetEXT\"))\n\tgpVertexArrayIndexOffsetEXT = uintptr(getProcAddr(\"glVertexArrayIndexOffsetEXT\"))\n\tgpVertexArrayMultiTexCoordOffsetEXT = uintptr(getProcAddr(\"glVertexArrayMultiTexCoordOffsetEXT\"))\n\tgpVertexArrayNormalOffsetEXT = uintptr(getProcAddr(\"glVertexArrayNormalOffsetEXT\"))\n\tgpVertexArrayParameteriAPPLE = uintptr(getProcAddr(\"glVertexArrayParameteriAPPLE\"))\n\tgpVertexArrayRangeAPPLE = uintptr(getProcAddr(\"glVertexArrayRangeAPPLE\"))\n\tgpVertexArrayRangeNV = uintptr(getProcAddr(\"glVertexArrayRangeNV\"))\n\tgpVertexArraySecondaryColorOffsetEXT = uintptr(getProcAddr(\"glVertexArraySecondaryColorOffsetEXT\"))\n\tgpVertexArrayTexCoordOffsetEXT = uintptr(getProcAddr(\"glVertexArrayTexCoordOffsetEXT\"))\n\tgpVertexArrayVertexAttribBindingEXT = uintptr(getProcAddr(\"glVertexArrayVertexAttribBindingEXT\"))\n\tgpVertexArrayVertexAttribDivisorEXT = uintptr(getProcAddr(\"glVertexArrayVertexAttribDivisorEXT\"))\n\tgpVertexArrayVertexAttribFormatEXT = uintptr(getProcAddr(\"glVertexArrayVertexAttribFormatEXT\"))\n\tgpVertexArrayVertexAttribIFormatEXT = uintptr(getProcAddr(\"glVertexArrayVertexAttribIFormatEXT\"))\n\tgpVertexArrayVertexAttribIOffsetEXT = uintptr(getProcAddr(\"glVertexArrayVertexAttribIOffsetEXT\"))\n\tgpVertexArrayVertexAttribLFormatEXT = uintptr(getProcAddr(\"glVertexArrayVertexAttribLFormatEXT\"))\n\tgpVertexArrayVertexAttribLOffsetEXT = uintptr(getProcAddr(\"glVertexArrayVertexAttribLOffsetEXT\"))\n\tgpVertexArrayVertexAttribOffsetEXT = uintptr(getProcAddr(\"glVertexArrayVertexAttribOffsetEXT\"))\n\tgpVertexArrayVertexBindingDivisorEXT = uintptr(getProcAddr(\"glVertexArrayVertexBindingDivisorEXT\"))\n\tgpVertexArrayVertexBuffer = uintptr(getProcAddr(\"glVertexArrayVertexBuffer\"))\n\tgpVertexArrayVertexBuffers = uintptr(getProcAddr(\"glVertexArrayVertexBuffers\"))\n\tgpVertexArrayVertexOffsetEXT = uintptr(getProcAddr(\"glVertexArrayVertexOffsetEXT\"))\n\tgpVertexAttrib1d = uintptr(getProcAddr(\"glVertexAttrib1d\"))\n\tif gpVertexAttrib1d == 0 {\n\t\treturn errors.New(\"glVertexAttrib1d\")\n\t}\n\tgpVertexAttrib1dARB = uintptr(getProcAddr(\"glVertexAttrib1dARB\"))\n\tgpVertexAttrib1dNV = uintptr(getProcAddr(\"glVertexAttrib1dNV\"))\n\tgpVertexAttrib1dv = uintptr(getProcAddr(\"glVertexAttrib1dv\"))\n\tif gpVertexAttrib1dv == 0 {\n\t\treturn errors.New(\"glVertexAttrib1dv\")\n\t}\n\tgpVertexAttrib1dvARB = uintptr(getProcAddr(\"glVertexAttrib1dvARB\"))\n\tgpVertexAttrib1dvNV = uintptr(getProcAddr(\"glVertexAttrib1dvNV\"))\n\tgpVertexAttrib1f = uintptr(getProcAddr(\"glVertexAttrib1f\"))\n\tif gpVertexAttrib1f == 0 {\n\t\treturn errors.New(\"glVertexAttrib1f\")\n\t}\n\tgpVertexAttrib1fARB = uintptr(getProcAddr(\"glVertexAttrib1fARB\"))\n\tgpVertexAttrib1fNV = uintptr(getProcAddr(\"glVertexAttrib1fNV\"))\n\tgpVertexAttrib1fv = uintptr(getProcAddr(\"glVertexAttrib1fv\"))\n\tif gpVertexAttrib1fv == 0 {\n\t\treturn errors.New(\"glVertexAttrib1fv\")\n\t}\n\tgpVertexAttrib1fvARB = uintptr(getProcAddr(\"glVertexAttrib1fvARB\"))\n\tgpVertexAttrib1fvNV = uintptr(getProcAddr(\"glVertexAttrib1fvNV\"))\n\tgpVertexAttrib1hNV = uintptr(getProcAddr(\"glVertexAttrib1hNV\"))\n\tgpVertexAttrib1hvNV = uintptr(getProcAddr(\"glVertexAttrib1hvNV\"))\n\tgpVertexAttrib1s = uintptr(getProcAddr(\"glVertexAttrib1s\"))\n\tif gpVertexAttrib1s == 0 {\n\t\treturn errors.New(\"glVertexAttrib1s\")\n\t}\n\tgpVertexAttrib1sARB = uintptr(getProcAddr(\"glVertexAttrib1sARB\"))\n\tgpVertexAttrib1sNV = uintptr(getProcAddr(\"glVertexAttrib1sNV\"))\n\tgpVertexAttrib1sv = uintptr(getProcAddr(\"glVertexAttrib1sv\"))\n\tif gpVertexAttrib1sv == 0 {\n\t\treturn errors.New(\"glVertexAttrib1sv\")\n\t}\n\tgpVertexAttrib1svARB = uintptr(getProcAddr(\"glVertexAttrib1svARB\"))\n\tgpVertexAttrib1svNV = uintptr(getProcAddr(\"glVertexAttrib1svNV\"))\n\tgpVertexAttrib2d = uintptr(getProcAddr(\"glVertexAttrib2d\"))\n\tif gpVertexAttrib2d == 0 {\n\t\treturn errors.New(\"glVertexAttrib2d\")\n\t}\n\tgpVertexAttrib2dARB = uintptr(getProcAddr(\"glVertexAttrib2dARB\"))\n\tgpVertexAttrib2dNV = uintptr(getProcAddr(\"glVertexAttrib2dNV\"))\n\tgpVertexAttrib2dv = uintptr(getProcAddr(\"glVertexAttrib2dv\"))\n\tif gpVertexAttrib2dv == 0 {\n\t\treturn errors.New(\"glVertexAttrib2dv\")\n\t}\n\tgpVertexAttrib2dvARB = uintptr(getProcAddr(\"glVertexAttrib2dvARB\"))\n\tgpVertexAttrib2dvNV = uintptr(getProcAddr(\"glVertexAttrib2dvNV\"))\n\tgpVertexAttrib2f = uintptr(getProcAddr(\"glVertexAttrib2f\"))\n\tif gpVertexAttrib2f == 0 {\n\t\treturn errors.New(\"glVertexAttrib2f\")\n\t}\n\tgpVertexAttrib2fARB = uintptr(getProcAddr(\"glVertexAttrib2fARB\"))\n\tgpVertexAttrib2fNV = uintptr(getProcAddr(\"glVertexAttrib2fNV\"))\n\tgpVertexAttrib2fv = uintptr(getProcAddr(\"glVertexAttrib2fv\"))\n\tif gpVertexAttrib2fv == 0 {\n\t\treturn errors.New(\"glVertexAttrib2fv\")\n\t}\n\tgpVertexAttrib2fvARB = uintptr(getProcAddr(\"glVertexAttrib2fvARB\"))\n\tgpVertexAttrib2fvNV = uintptr(getProcAddr(\"glVertexAttrib2fvNV\"))\n\tgpVertexAttrib2hNV = uintptr(getProcAddr(\"glVertexAttrib2hNV\"))\n\tgpVertexAttrib2hvNV = uintptr(getProcAddr(\"glVertexAttrib2hvNV\"))\n\tgpVertexAttrib2s = uintptr(getProcAddr(\"glVertexAttrib2s\"))\n\tif gpVertexAttrib2s == 0 {\n\t\treturn errors.New(\"glVertexAttrib2s\")\n\t}\n\tgpVertexAttrib2sARB = uintptr(getProcAddr(\"glVertexAttrib2sARB\"))\n\tgpVertexAttrib2sNV = uintptr(getProcAddr(\"glVertexAttrib2sNV\"))\n\tgpVertexAttrib2sv = uintptr(getProcAddr(\"glVertexAttrib2sv\"))\n\tif gpVertexAttrib2sv == 0 {\n\t\treturn errors.New(\"glVertexAttrib2sv\")\n\t}\n\tgpVertexAttrib2svARB = uintptr(getProcAddr(\"glVertexAttrib2svARB\"))\n\tgpVertexAttrib2svNV = uintptr(getProcAddr(\"glVertexAttrib2svNV\"))\n\tgpVertexAttrib3d = uintptr(getProcAddr(\"glVertexAttrib3d\"))\n\tif gpVertexAttrib3d == 0 {\n\t\treturn errors.New(\"glVertexAttrib3d\")\n\t}\n\tgpVertexAttrib3dARB = uintptr(getProcAddr(\"glVertexAttrib3dARB\"))\n\tgpVertexAttrib3dNV = uintptr(getProcAddr(\"glVertexAttrib3dNV\"))\n\tgpVertexAttrib3dv = uintptr(getProcAddr(\"glVertexAttrib3dv\"))\n\tif gpVertexAttrib3dv == 0 {\n\t\treturn errors.New(\"glVertexAttrib3dv\")\n\t}\n\tgpVertexAttrib3dvARB = uintptr(getProcAddr(\"glVertexAttrib3dvARB\"))\n\tgpVertexAttrib3dvNV = uintptr(getProcAddr(\"glVertexAttrib3dvNV\"))\n\tgpVertexAttrib3f = uintptr(getProcAddr(\"glVertexAttrib3f\"))\n\tif gpVertexAttrib3f == 0 {\n\t\treturn errors.New(\"glVertexAttrib3f\")\n\t}\n\tgpVertexAttrib3fARB = uintptr(getProcAddr(\"glVertexAttrib3fARB\"))\n\tgpVertexAttrib3fNV = uintptr(getProcAddr(\"glVertexAttrib3fNV\"))\n\tgpVertexAttrib3fv = uintptr(getProcAddr(\"glVertexAttrib3fv\"))\n\tif gpVertexAttrib3fv == 0 {\n\t\treturn errors.New(\"glVertexAttrib3fv\")\n\t}\n\tgpVertexAttrib3fvARB = uintptr(getProcAddr(\"glVertexAttrib3fvARB\"))\n\tgpVertexAttrib3fvNV = uintptr(getProcAddr(\"glVertexAttrib3fvNV\"))\n\tgpVertexAttrib3hNV = uintptr(getProcAddr(\"glVertexAttrib3hNV\"))\n\tgpVertexAttrib3hvNV = uintptr(getProcAddr(\"glVertexAttrib3hvNV\"))\n\tgpVertexAttrib3s = uintptr(getProcAddr(\"glVertexAttrib3s\"))\n\tif gpVertexAttrib3s == 0 {\n\t\treturn errors.New(\"glVertexAttrib3s\")\n\t}\n\tgpVertexAttrib3sARB = uintptr(getProcAddr(\"glVertexAttrib3sARB\"))\n\tgpVertexAttrib3sNV = uintptr(getProcAddr(\"glVertexAttrib3sNV\"))\n\tgpVertexAttrib3sv = uintptr(getProcAddr(\"glVertexAttrib3sv\"))\n\tif gpVertexAttrib3sv == 0 {\n\t\treturn errors.New(\"glVertexAttrib3sv\")\n\t}\n\tgpVertexAttrib3svARB = uintptr(getProcAddr(\"glVertexAttrib3svARB\"))\n\tgpVertexAttrib3svNV = uintptr(getProcAddr(\"glVertexAttrib3svNV\"))\n\tgpVertexAttrib4Nbv = uintptr(getProcAddr(\"glVertexAttrib4Nbv\"))\n\tif gpVertexAttrib4Nbv == 0 {\n\t\treturn errors.New(\"glVertexAttrib4Nbv\")\n\t}\n\tgpVertexAttrib4NbvARB = uintptr(getProcAddr(\"glVertexAttrib4NbvARB\"))\n\tgpVertexAttrib4Niv = uintptr(getProcAddr(\"glVertexAttrib4Niv\"))\n\tif gpVertexAttrib4Niv == 0 {\n\t\treturn errors.New(\"glVertexAttrib4Niv\")\n\t}\n\tgpVertexAttrib4NivARB = uintptr(getProcAddr(\"glVertexAttrib4NivARB\"))\n\tgpVertexAttrib4Nsv = uintptr(getProcAddr(\"glVertexAttrib4Nsv\"))\n\tif gpVertexAttrib4Nsv == 0 {\n\t\treturn errors.New(\"glVertexAttrib4Nsv\")\n\t}\n\tgpVertexAttrib4NsvARB = uintptr(getProcAddr(\"glVertexAttrib4NsvARB\"))\n\tgpVertexAttrib4Nub = uintptr(getProcAddr(\"glVertexAttrib4Nub\"))\n\tif gpVertexAttrib4Nub == 0 {\n\t\treturn errors.New(\"glVertexAttrib4Nub\")\n\t}\n\tgpVertexAttrib4NubARB = uintptr(getProcAddr(\"glVertexAttrib4NubARB\"))\n\tgpVertexAttrib4Nubv = uintptr(getProcAddr(\"glVertexAttrib4Nubv\"))\n\tif gpVertexAttrib4Nubv == 0 {\n\t\treturn errors.New(\"glVertexAttrib4Nubv\")\n\t}\n\tgpVertexAttrib4NubvARB = uintptr(getProcAddr(\"glVertexAttrib4NubvARB\"))\n\tgpVertexAttrib4Nuiv = uintptr(getProcAddr(\"glVertexAttrib4Nuiv\"))\n\tif gpVertexAttrib4Nuiv == 0 {\n\t\treturn errors.New(\"glVertexAttrib4Nuiv\")\n\t}\n\tgpVertexAttrib4NuivARB = uintptr(getProcAddr(\"glVertexAttrib4NuivARB\"))\n\tgpVertexAttrib4Nusv = uintptr(getProcAddr(\"glVertexAttrib4Nusv\"))\n\tif gpVertexAttrib4Nusv == 0 {\n\t\treturn errors.New(\"glVertexAttrib4Nusv\")\n\t}\n\tgpVertexAttrib4NusvARB = uintptr(getProcAddr(\"glVertexAttrib4NusvARB\"))\n\tgpVertexAttrib4bv = uintptr(getProcAddr(\"glVertexAttrib4bv\"))\n\tif gpVertexAttrib4bv == 0 {\n\t\treturn errors.New(\"glVertexAttrib4bv\")\n\t}\n\tgpVertexAttrib4bvARB = uintptr(getProcAddr(\"glVertexAttrib4bvARB\"))\n\tgpVertexAttrib4d = uintptr(getProcAddr(\"glVertexAttrib4d\"))\n\tif gpVertexAttrib4d == 0 {\n\t\treturn errors.New(\"glVertexAttrib4d\")\n\t}\n\tgpVertexAttrib4dARB = uintptr(getProcAddr(\"glVertexAttrib4dARB\"))\n\tgpVertexAttrib4dNV = uintptr(getProcAddr(\"glVertexAttrib4dNV\"))\n\tgpVertexAttrib4dv = uintptr(getProcAddr(\"glVertexAttrib4dv\"))\n\tif gpVertexAttrib4dv == 0 {\n\t\treturn errors.New(\"glVertexAttrib4dv\")\n\t}\n\tgpVertexAttrib4dvARB = uintptr(getProcAddr(\"glVertexAttrib4dvARB\"))\n\tgpVertexAttrib4dvNV = uintptr(getProcAddr(\"glVertexAttrib4dvNV\"))\n\tgpVertexAttrib4f = uintptr(getProcAddr(\"glVertexAttrib4f\"))\n\tif gpVertexAttrib4f == 0 {\n\t\treturn errors.New(\"glVertexAttrib4f\")\n\t}\n\tgpVertexAttrib4fARB = uintptr(getProcAddr(\"glVertexAttrib4fARB\"))\n\tgpVertexAttrib4fNV = uintptr(getProcAddr(\"glVertexAttrib4fNV\"))\n\tgpVertexAttrib4fv = uintptr(getProcAddr(\"glVertexAttrib4fv\"))\n\tif gpVertexAttrib4fv == 0 {\n\t\treturn errors.New(\"glVertexAttrib4fv\")\n\t}\n\tgpVertexAttrib4fvARB = uintptr(getProcAddr(\"glVertexAttrib4fvARB\"))\n\tgpVertexAttrib4fvNV = uintptr(getProcAddr(\"glVertexAttrib4fvNV\"))\n\tgpVertexAttrib4hNV = uintptr(getProcAddr(\"glVertexAttrib4hNV\"))\n\tgpVertexAttrib4hvNV = uintptr(getProcAddr(\"glVertexAttrib4hvNV\"))\n\tgpVertexAttrib4iv = uintptr(getProcAddr(\"glVertexAttrib4iv\"))\n\tif gpVertexAttrib4iv == 0 {\n\t\treturn errors.New(\"glVertexAttrib4iv\")\n\t}\n\tgpVertexAttrib4ivARB = uintptr(getProcAddr(\"glVertexAttrib4ivARB\"))\n\tgpVertexAttrib4s = uintptr(getProcAddr(\"glVertexAttrib4s\"))\n\tif gpVertexAttrib4s == 0 {\n\t\treturn errors.New(\"glVertexAttrib4s\")\n\t}\n\tgpVertexAttrib4sARB = uintptr(getProcAddr(\"glVertexAttrib4sARB\"))\n\tgpVertexAttrib4sNV = uintptr(getProcAddr(\"glVertexAttrib4sNV\"))\n\tgpVertexAttrib4sv = uintptr(getProcAddr(\"glVertexAttrib4sv\"))\n\tif gpVertexAttrib4sv == 0 {\n\t\treturn errors.New(\"glVertexAttrib4sv\")\n\t}\n\tgpVertexAttrib4svARB = uintptr(getProcAddr(\"glVertexAttrib4svARB\"))\n\tgpVertexAttrib4svNV = uintptr(getProcAddr(\"glVertexAttrib4svNV\"))\n\tgpVertexAttrib4ubNV = uintptr(getProcAddr(\"glVertexAttrib4ubNV\"))\n\tgpVertexAttrib4ubv = uintptr(getProcAddr(\"glVertexAttrib4ubv\"))\n\tif gpVertexAttrib4ubv == 0 {\n\t\treturn errors.New(\"glVertexAttrib4ubv\")\n\t}\n\tgpVertexAttrib4ubvARB = uintptr(getProcAddr(\"glVertexAttrib4ubvARB\"))\n\tgpVertexAttrib4ubvNV = uintptr(getProcAddr(\"glVertexAttrib4ubvNV\"))\n\tgpVertexAttrib4uiv = uintptr(getProcAddr(\"glVertexAttrib4uiv\"))\n\tif gpVertexAttrib4uiv == 0 {\n\t\treturn errors.New(\"glVertexAttrib4uiv\")\n\t}\n\tgpVertexAttrib4uivARB = uintptr(getProcAddr(\"glVertexAttrib4uivARB\"))\n\tgpVertexAttrib4usv = uintptr(getProcAddr(\"glVertexAttrib4usv\"))\n\tif gpVertexAttrib4usv == 0 {\n\t\treturn errors.New(\"glVertexAttrib4usv\")\n\t}\n\tgpVertexAttrib4usvARB = uintptr(getProcAddr(\"glVertexAttrib4usvARB\"))\n\tgpVertexAttribArrayObjectATI = uintptr(getProcAddr(\"glVertexAttribArrayObjectATI\"))\n\tgpVertexAttribBinding = uintptr(getProcAddr(\"glVertexAttribBinding\"))\n\tgpVertexAttribDivisorARB = uintptr(getProcAddr(\"glVertexAttribDivisorARB\"))\n\tgpVertexAttribFormat = uintptr(getProcAddr(\"glVertexAttribFormat\"))\n\tgpVertexAttribFormatNV = uintptr(getProcAddr(\"glVertexAttribFormatNV\"))\n\tgpVertexAttribI1iEXT = uintptr(getProcAddr(\"glVertexAttribI1iEXT\"))\n\tgpVertexAttribI1ivEXT = uintptr(getProcAddr(\"glVertexAttribI1ivEXT\"))\n\tgpVertexAttribI1uiEXT = uintptr(getProcAddr(\"glVertexAttribI1uiEXT\"))\n\tgpVertexAttribI1uivEXT = uintptr(getProcAddr(\"glVertexAttribI1uivEXT\"))\n\tgpVertexAttribI2iEXT = uintptr(getProcAddr(\"glVertexAttribI2iEXT\"))\n\tgpVertexAttribI2ivEXT = uintptr(getProcAddr(\"glVertexAttribI2ivEXT\"))\n\tgpVertexAttribI2uiEXT = uintptr(getProcAddr(\"glVertexAttribI2uiEXT\"))\n\tgpVertexAttribI2uivEXT = uintptr(getProcAddr(\"glVertexAttribI2uivEXT\"))\n\tgpVertexAttribI3iEXT = uintptr(getProcAddr(\"glVertexAttribI3iEXT\"))\n\tgpVertexAttribI3ivEXT = uintptr(getProcAddr(\"glVertexAttribI3ivEXT\"))\n\tgpVertexAttribI3uiEXT = uintptr(getProcAddr(\"glVertexAttribI3uiEXT\"))\n\tgpVertexAttribI3uivEXT = uintptr(getProcAddr(\"glVertexAttribI3uivEXT\"))\n\tgpVertexAttribI4bvEXT = uintptr(getProcAddr(\"glVertexAttribI4bvEXT\"))\n\tgpVertexAttribI4iEXT = uintptr(getProcAddr(\"glVertexAttribI4iEXT\"))\n\tgpVertexAttribI4ivEXT = uintptr(getProcAddr(\"glVertexAttribI4ivEXT\"))\n\tgpVertexAttribI4svEXT = uintptr(getProcAddr(\"glVertexAttribI4svEXT\"))\n\tgpVertexAttribI4ubvEXT = uintptr(getProcAddr(\"glVertexAttribI4ubvEXT\"))\n\tgpVertexAttribI4uiEXT = uintptr(getProcAddr(\"glVertexAttribI4uiEXT\"))\n\tgpVertexAttribI4uivEXT = uintptr(getProcAddr(\"glVertexAttribI4uivEXT\"))\n\tgpVertexAttribI4usvEXT = uintptr(getProcAddr(\"glVertexAttribI4usvEXT\"))\n\tgpVertexAttribIFormat = uintptr(getProcAddr(\"glVertexAttribIFormat\"))\n\tgpVertexAttribIFormatNV = uintptr(getProcAddr(\"glVertexAttribIFormatNV\"))\n\tgpVertexAttribIPointerEXT = uintptr(getProcAddr(\"glVertexAttribIPointerEXT\"))\n\tgpVertexAttribL1d = uintptr(getProcAddr(\"glVertexAttribL1d\"))\n\tgpVertexAttribL1dEXT = uintptr(getProcAddr(\"glVertexAttribL1dEXT\"))\n\tgpVertexAttribL1dv = uintptr(getProcAddr(\"glVertexAttribL1dv\"))\n\tgpVertexAttribL1dvEXT = uintptr(getProcAddr(\"glVertexAttribL1dvEXT\"))\n\tgpVertexAttribL1i64NV = uintptr(getProcAddr(\"glVertexAttribL1i64NV\"))\n\tgpVertexAttribL1i64vNV = uintptr(getProcAddr(\"glVertexAttribL1i64vNV\"))\n\tgpVertexAttribL1ui64ARB = uintptr(getProcAddr(\"glVertexAttribL1ui64ARB\"))\n\tgpVertexAttribL1ui64NV = uintptr(getProcAddr(\"glVertexAttribL1ui64NV\"))\n\tgpVertexAttribL1ui64vARB = uintptr(getProcAddr(\"glVertexAttribL1ui64vARB\"))\n\tgpVertexAttribL1ui64vNV = uintptr(getProcAddr(\"glVertexAttribL1ui64vNV\"))\n\tgpVertexAttribL2d = uintptr(getProcAddr(\"glVertexAttribL2d\"))\n\tgpVertexAttribL2dEXT = uintptr(getProcAddr(\"glVertexAttribL2dEXT\"))\n\tgpVertexAttribL2dv = uintptr(getProcAddr(\"glVertexAttribL2dv\"))\n\tgpVertexAttribL2dvEXT = uintptr(getProcAddr(\"glVertexAttribL2dvEXT\"))\n\tgpVertexAttribL2i64NV = uintptr(getProcAddr(\"glVertexAttribL2i64NV\"))\n\tgpVertexAttribL2i64vNV = uintptr(getProcAddr(\"glVertexAttribL2i64vNV\"))\n\tgpVertexAttribL2ui64NV = uintptr(getProcAddr(\"glVertexAttribL2ui64NV\"))\n\tgpVertexAttribL2ui64vNV = uintptr(getProcAddr(\"glVertexAttribL2ui64vNV\"))\n\tgpVertexAttribL3d = uintptr(getProcAddr(\"glVertexAttribL3d\"))\n\tgpVertexAttribL3dEXT = uintptr(getProcAddr(\"glVertexAttribL3dEXT\"))\n\tgpVertexAttribL3dv = uintptr(getProcAddr(\"glVertexAttribL3dv\"))\n\tgpVertexAttribL3dvEXT = uintptr(getProcAddr(\"glVertexAttribL3dvEXT\"))\n\tgpVertexAttribL3i64NV = uintptr(getProcAddr(\"glVertexAttribL3i64NV\"))\n\tgpVertexAttribL3i64vNV = uintptr(getProcAddr(\"glVertexAttribL3i64vNV\"))\n\tgpVertexAttribL3ui64NV = uintptr(getProcAddr(\"glVertexAttribL3ui64NV\"))\n\tgpVertexAttribL3ui64vNV = uintptr(getProcAddr(\"glVertexAttribL3ui64vNV\"))\n\tgpVertexAttribL4d = uintptr(getProcAddr(\"glVertexAttribL4d\"))\n\tgpVertexAttribL4dEXT = uintptr(getProcAddr(\"glVertexAttribL4dEXT\"))\n\tgpVertexAttribL4dv = uintptr(getProcAddr(\"glVertexAttribL4dv\"))\n\tgpVertexAttribL4dvEXT = uintptr(getProcAddr(\"glVertexAttribL4dvEXT\"))\n\tgpVertexAttribL4i64NV = uintptr(getProcAddr(\"glVertexAttribL4i64NV\"))\n\tgpVertexAttribL4i64vNV = uintptr(getProcAddr(\"glVertexAttribL4i64vNV\"))\n\tgpVertexAttribL4ui64NV = uintptr(getProcAddr(\"glVertexAttribL4ui64NV\"))\n\tgpVertexAttribL4ui64vNV = uintptr(getProcAddr(\"glVertexAttribL4ui64vNV\"))\n\tgpVertexAttribLFormat = uintptr(getProcAddr(\"glVertexAttribLFormat\"))\n\tgpVertexAttribLFormatNV = uintptr(getProcAddr(\"glVertexAttribLFormatNV\"))\n\tgpVertexAttribLPointer = uintptr(getProcAddr(\"glVertexAttribLPointer\"))\n\tgpVertexAttribLPointerEXT = uintptr(getProcAddr(\"glVertexAttribLPointerEXT\"))\n\tgpVertexAttribP1ui = uintptr(getProcAddr(\"glVertexAttribP1ui\"))\n\tgpVertexAttribP1uiv = uintptr(getProcAddr(\"glVertexAttribP1uiv\"))\n\tgpVertexAttribP2ui = uintptr(getProcAddr(\"glVertexAttribP2ui\"))\n\tgpVertexAttribP2uiv = uintptr(getProcAddr(\"glVertexAttribP2uiv\"))\n\tgpVertexAttribP3ui = uintptr(getProcAddr(\"glVertexAttribP3ui\"))\n\tgpVertexAttribP3uiv = uintptr(getProcAddr(\"glVertexAttribP3uiv\"))\n\tgpVertexAttribP4ui = uintptr(getProcAddr(\"glVertexAttribP4ui\"))\n\tgpVertexAttribP4uiv = uintptr(getProcAddr(\"glVertexAttribP4uiv\"))\n\tgpVertexAttribParameteriAMD = uintptr(getProcAddr(\"glVertexAttribParameteriAMD\"))\n\tgpVertexAttribPointer = uintptr(getProcAddr(\"glVertexAttribPointer\"))\n\tif gpVertexAttribPointer == 0 {\n\t\treturn errors.New(\"glVertexAttribPointer\")\n\t}\n\tgpVertexAttribPointerARB = uintptr(getProcAddr(\"glVertexAttribPointerARB\"))\n\tgpVertexAttribPointerNV = uintptr(getProcAddr(\"glVertexAttribPointerNV\"))\n\tgpVertexAttribs1dvNV = uintptr(getProcAddr(\"glVertexAttribs1dvNV\"))\n\tgpVertexAttribs1fvNV = uintptr(getProcAddr(\"glVertexAttribs1fvNV\"))\n\tgpVertexAttribs1hvNV = uintptr(getProcAddr(\"glVertexAttribs1hvNV\"))\n\tgpVertexAttribs1svNV = uintptr(getProcAddr(\"glVertexAttribs1svNV\"))\n\tgpVertexAttribs2dvNV = uintptr(getProcAddr(\"glVertexAttribs2dvNV\"))\n\tgpVertexAttribs2fvNV = uintptr(getProcAddr(\"glVertexAttribs2fvNV\"))\n\tgpVertexAttribs2hvNV = uintptr(getProcAddr(\"glVertexAttribs2hvNV\"))\n\tgpVertexAttribs2svNV = uintptr(getProcAddr(\"glVertexAttribs2svNV\"))\n\tgpVertexAttribs3dvNV = uintptr(getProcAddr(\"glVertexAttribs3dvNV\"))\n\tgpVertexAttribs3fvNV = uintptr(getProcAddr(\"glVertexAttribs3fvNV\"))\n\tgpVertexAttribs3hvNV = uintptr(getProcAddr(\"glVertexAttribs3hvNV\"))\n\tgpVertexAttribs3svNV = uintptr(getProcAddr(\"glVertexAttribs3svNV\"))\n\tgpVertexAttribs4dvNV = uintptr(getProcAddr(\"glVertexAttribs4dvNV\"))\n\tgpVertexAttribs4fvNV = uintptr(getProcAddr(\"glVertexAttribs4fvNV\"))\n\tgpVertexAttribs4hvNV = uintptr(getProcAddr(\"glVertexAttribs4hvNV\"))\n\tgpVertexAttribs4svNV = uintptr(getProcAddr(\"glVertexAttribs4svNV\"))\n\tgpVertexAttribs4ubvNV = uintptr(getProcAddr(\"glVertexAttribs4ubvNV\"))\n\tgpVertexBindingDivisor = uintptr(getProcAddr(\"glVertexBindingDivisor\"))\n\tgpVertexBlendARB = uintptr(getProcAddr(\"glVertexBlendARB\"))\n\tgpVertexBlendEnvfATI = uintptr(getProcAddr(\"glVertexBlendEnvfATI\"))\n\tgpVertexBlendEnviATI = uintptr(getProcAddr(\"glVertexBlendEnviATI\"))\n\tgpVertexFormatNV = uintptr(getProcAddr(\"glVertexFormatNV\"))\n\tgpVertexPointer = uintptr(getProcAddr(\"glVertexPointer\"))\n\tif gpVertexPointer == 0 {\n\t\treturn errors.New(\"glVertexPointer\")\n\t}\n\tgpVertexPointerEXT = uintptr(getProcAddr(\"glVertexPointerEXT\"))\n\tgpVertexPointerListIBM = uintptr(getProcAddr(\"glVertexPointerListIBM\"))\n\tgpVertexPointervINTEL = uintptr(getProcAddr(\"glVertexPointervINTEL\"))\n\tgpVertexStream1dATI = uintptr(getProcAddr(\"glVertexStream1dATI\"))\n\tgpVertexStream1dvATI = uintptr(getProcAddr(\"glVertexStream1dvATI\"))\n\tgpVertexStream1fATI = uintptr(getProcAddr(\"glVertexStream1fATI\"))\n\tgpVertexStream1fvATI = uintptr(getProcAddr(\"glVertexStream1fvATI\"))\n\tgpVertexStream1iATI = uintptr(getProcAddr(\"glVertexStream1iATI\"))\n\tgpVertexStream1ivATI = uintptr(getProcAddr(\"glVertexStream1ivATI\"))\n\tgpVertexStream1sATI = uintptr(getProcAddr(\"glVertexStream1sATI\"))\n\tgpVertexStream1svATI = uintptr(getProcAddr(\"glVertexStream1svATI\"))\n\tgpVertexStream2dATI = uintptr(getProcAddr(\"glVertexStream2dATI\"))\n\tgpVertexStream2dvATI = uintptr(getProcAddr(\"glVertexStream2dvATI\"))\n\tgpVertexStream2fATI = uintptr(getProcAddr(\"glVertexStream2fATI\"))\n\tgpVertexStream2fvATI = uintptr(getProcAddr(\"glVertexStream2fvATI\"))\n\tgpVertexStream2iATI = uintptr(getProcAddr(\"glVertexStream2iATI\"))\n\tgpVertexStream2ivATI = uintptr(getProcAddr(\"glVertexStream2ivATI\"))\n\tgpVertexStream2sATI = uintptr(getProcAddr(\"glVertexStream2sATI\"))\n\tgpVertexStream2svATI = uintptr(getProcAddr(\"glVertexStream2svATI\"))\n\tgpVertexStream3dATI = uintptr(getProcAddr(\"glVertexStream3dATI\"))\n\tgpVertexStream3dvATI = uintptr(getProcAddr(\"glVertexStream3dvATI\"))\n\tgpVertexStream3fATI = uintptr(getProcAddr(\"glVertexStream3fATI\"))\n\tgpVertexStream3fvATI = uintptr(getProcAddr(\"glVertexStream3fvATI\"))\n\tgpVertexStream3iATI = uintptr(getProcAddr(\"glVertexStream3iATI\"))\n\tgpVertexStream3ivATI = uintptr(getProcAddr(\"glVertexStream3ivATI\"))\n\tgpVertexStream3sATI = uintptr(getProcAddr(\"glVertexStream3sATI\"))\n\tgpVertexStream3svATI = uintptr(getProcAddr(\"glVertexStream3svATI\"))\n\tgpVertexStream4dATI = uintptr(getProcAddr(\"glVertexStream4dATI\"))\n\tgpVertexStream4dvATI = uintptr(getProcAddr(\"glVertexStream4dvATI\"))\n\tgpVertexStream4fATI = uintptr(getProcAddr(\"glVertexStream4fATI\"))\n\tgpVertexStream4fvATI = uintptr(getProcAddr(\"glVertexStream4fvATI\"))\n\tgpVertexStream4iATI = uintptr(getProcAddr(\"glVertexStream4iATI\"))\n\tgpVertexStream4ivATI = uintptr(getProcAddr(\"glVertexStream4ivATI\"))\n\tgpVertexStream4sATI = uintptr(getProcAddr(\"glVertexStream4sATI\"))\n\tgpVertexStream4svATI = uintptr(getProcAddr(\"glVertexStream4svATI\"))\n\tgpVertexWeightPointerEXT = uintptr(getProcAddr(\"glVertexWeightPointerEXT\"))\n\tgpVertexWeightfEXT = uintptr(getProcAddr(\"glVertexWeightfEXT\"))\n\tgpVertexWeightfvEXT = uintptr(getProcAddr(\"glVertexWeightfvEXT\"))\n\tgpVertexWeighthNV = uintptr(getProcAddr(\"glVertexWeighthNV\"))\n\tgpVertexWeighthvNV = uintptr(getProcAddr(\"glVertexWeighthvNV\"))\n\tgpVideoCaptureNV = uintptr(getProcAddr(\"glVideoCaptureNV\"))\n\tgpVideoCaptureStreamParameterdvNV = uintptr(getProcAddr(\"glVideoCaptureStreamParameterdvNV\"))\n\tgpVideoCaptureStreamParameterfvNV = uintptr(getProcAddr(\"glVideoCaptureStreamParameterfvNV\"))\n\tgpVideoCaptureStreamParameterivNV = uintptr(getProcAddr(\"glVideoCaptureStreamParameterivNV\"))\n\tgpViewport = uintptr(getProcAddr(\"glViewport\"))\n\tif gpViewport == 0 {\n\t\treturn errors.New(\"glViewport\")\n\t}\n\tgpViewportArrayv = uintptr(getProcAddr(\"glViewportArrayv\"))\n\tgpViewportIndexedf = uintptr(getProcAddr(\"glViewportIndexedf\"))\n\tgpViewportIndexedfv = uintptr(getProcAddr(\"glViewportIndexedfv\"))\n\tgpViewportPositionWScaleNV = uintptr(getProcAddr(\"glViewportPositionWScaleNV\"))\n\tgpViewportSwizzleNV = uintptr(getProcAddr(\"glViewportSwizzleNV\"))\n\tgpWaitSemaphoreEXT = uintptr(getProcAddr(\"glWaitSemaphoreEXT\"))\n\tgpWaitSync = uintptr(getProcAddr(\"glWaitSync\"))\n\tgpWaitVkSemaphoreNV = uintptr(getProcAddr(\"glWaitVkSemaphoreNV\"))\n\tgpWeightPathsNV = uintptr(getProcAddr(\"glWeightPathsNV\"))\n\tgpWeightPointerARB = uintptr(getProcAddr(\"glWeightPointerARB\"))\n\tgpWeightbvARB = uintptr(getProcAddr(\"glWeightbvARB\"))\n\tgpWeightdvARB = uintptr(getProcAddr(\"glWeightdvARB\"))\n\tgpWeightfvARB = uintptr(getProcAddr(\"glWeightfvARB\"))\n\tgpWeightivARB = uintptr(getProcAddr(\"glWeightivARB\"))\n\tgpWeightsvARB = uintptr(getProcAddr(\"glWeightsvARB\"))\n\tgpWeightubvARB = uintptr(getProcAddr(\"glWeightubvARB\"))\n\tgpWeightuivARB = uintptr(getProcAddr(\"glWeightuivARB\"))\n\tgpWeightusvARB = uintptr(getProcAddr(\"glWeightusvARB\"))\n\tgpWindowPos2d = uintptr(getProcAddr(\"glWindowPos2d\"))\n\tif gpWindowPos2d == 0 {\n\t\treturn errors.New(\"glWindowPos2d\")\n\t}\n\tgpWindowPos2dARB = uintptr(getProcAddr(\"glWindowPos2dARB\"))\n\tgpWindowPos2dMESA = uintptr(getProcAddr(\"glWindowPos2dMESA\"))\n\tgpWindowPos2dv = uintptr(getProcAddr(\"glWindowPos2dv\"))\n\tif gpWindowPos2dv == 0 {\n\t\treturn errors.New(\"glWindowPos2dv\")\n\t}\n\tgpWindowPos2dvARB = uintptr(getProcAddr(\"glWindowPos2dvARB\"))\n\tgpWindowPos2dvMESA = uintptr(getProcAddr(\"glWindowPos2dvMESA\"))\n\tgpWindowPos2f = uintptr(getProcAddr(\"glWindowPos2f\"))\n\tif gpWindowPos2f == 0 {\n\t\treturn errors.New(\"glWindowPos2f\")\n\t}\n\tgpWindowPos2fARB = uintptr(getProcAddr(\"glWindowPos2fARB\"))\n\tgpWindowPos2fMESA = uintptr(getProcAddr(\"glWindowPos2fMESA\"))\n\tgpWindowPos2fv = uintptr(getProcAddr(\"glWindowPos2fv\"))\n\tif gpWindowPos2fv == 0 {\n\t\treturn errors.New(\"glWindowPos2fv\")\n\t}\n\tgpWindowPos2fvARB = uintptr(getProcAddr(\"glWindowPos2fvARB\"))\n\tgpWindowPos2fvMESA = uintptr(getProcAddr(\"glWindowPos2fvMESA\"))\n\tgpWindowPos2i = uintptr(getProcAddr(\"glWindowPos2i\"))\n\tif gpWindowPos2i == 0 {\n\t\treturn errors.New(\"glWindowPos2i\")\n\t}\n\tgpWindowPos2iARB = uintptr(getProcAddr(\"glWindowPos2iARB\"))\n\tgpWindowPos2iMESA = uintptr(getProcAddr(\"glWindowPos2iMESA\"))\n\tgpWindowPos2iv = uintptr(getProcAddr(\"glWindowPos2iv\"))\n\tif gpWindowPos2iv == 0 {\n\t\treturn errors.New(\"glWindowPos2iv\")\n\t}\n\tgpWindowPos2ivARB = uintptr(getProcAddr(\"glWindowPos2ivARB\"))\n\tgpWindowPos2ivMESA = uintptr(getProcAddr(\"glWindowPos2ivMESA\"))\n\tgpWindowPos2s = uintptr(getProcAddr(\"glWindowPos2s\"))\n\tif gpWindowPos2s == 0 {\n\t\treturn errors.New(\"glWindowPos2s\")\n\t}\n\tgpWindowPos2sARB = uintptr(getProcAddr(\"glWindowPos2sARB\"))\n\tgpWindowPos2sMESA = uintptr(getProcAddr(\"glWindowPos2sMESA\"))\n\tgpWindowPos2sv = uintptr(getProcAddr(\"glWindowPos2sv\"))\n\tif gpWindowPos2sv == 0 {\n\t\treturn errors.New(\"glWindowPos2sv\")\n\t}\n\tgpWindowPos2svARB = uintptr(getProcAddr(\"glWindowPos2svARB\"))\n\tgpWindowPos2svMESA = uintptr(getProcAddr(\"glWindowPos2svMESA\"))\n\tgpWindowPos3d = uintptr(getProcAddr(\"glWindowPos3d\"))\n\tif gpWindowPos3d == 0 {\n\t\treturn errors.New(\"glWindowPos3d\")\n\t}\n\tgpWindowPos3dARB = uintptr(getProcAddr(\"glWindowPos3dARB\"))\n\tgpWindowPos3dMESA = uintptr(getProcAddr(\"glWindowPos3dMESA\"))\n\tgpWindowPos3dv = uintptr(getProcAddr(\"glWindowPos3dv\"))\n\tif gpWindowPos3dv == 0 {\n\t\treturn errors.New(\"glWindowPos3dv\")\n\t}\n\tgpWindowPos3dvARB = uintptr(getProcAddr(\"glWindowPos3dvARB\"))\n\tgpWindowPos3dvMESA = uintptr(getProcAddr(\"glWindowPos3dvMESA\"))\n\tgpWindowPos3f = uintptr(getProcAddr(\"glWindowPos3f\"))\n\tif gpWindowPos3f == 0 {\n\t\treturn errors.New(\"glWindowPos3f\")\n\t}\n\tgpWindowPos3fARB = uintptr(getProcAddr(\"glWindowPos3fARB\"))\n\tgpWindowPos3fMESA = uintptr(getProcAddr(\"glWindowPos3fMESA\"))\n\tgpWindowPos3fv = uintptr(getProcAddr(\"glWindowPos3fv\"))\n\tif gpWindowPos3fv == 0 {\n\t\treturn errors.New(\"glWindowPos3fv\")\n\t}\n\tgpWindowPos3fvARB = uintptr(getProcAddr(\"glWindowPos3fvARB\"))\n\tgpWindowPos3fvMESA = uintptr(getProcAddr(\"glWindowPos3fvMESA\"))\n\tgpWindowPos3i = uintptr(getProcAddr(\"glWindowPos3i\"))\n\tif gpWindowPos3i == 0 {\n\t\treturn errors.New(\"glWindowPos3i\")\n\t}\n\tgpWindowPos3iARB = uintptr(getProcAddr(\"glWindowPos3iARB\"))\n\tgpWindowPos3iMESA = uintptr(getProcAddr(\"glWindowPos3iMESA\"))\n\tgpWindowPos3iv = uintptr(getProcAddr(\"glWindowPos3iv\"))\n\tif gpWindowPos3iv == 0 {\n\t\treturn errors.New(\"glWindowPos3iv\")\n\t}\n\tgpWindowPos3ivARB = uintptr(getProcAddr(\"glWindowPos3ivARB\"))\n\tgpWindowPos3ivMESA = uintptr(getProcAddr(\"glWindowPos3ivMESA\"))\n\tgpWindowPos3s = uintptr(getProcAddr(\"glWindowPos3s\"))\n\tif gpWindowPos3s == 0 {\n\t\treturn errors.New(\"glWindowPos3s\")\n\t}\n\tgpWindowPos3sARB = uintptr(getProcAddr(\"glWindowPos3sARB\"))\n\tgpWindowPos3sMESA = uintptr(getProcAddr(\"glWindowPos3sMESA\"))\n\tgpWindowPos3sv = uintptr(getProcAddr(\"glWindowPos3sv\"))\n\tif gpWindowPos3sv == 0 {\n\t\treturn errors.New(\"glWindowPos3sv\")\n\t}\n\tgpWindowPos3svARB = uintptr(getProcAddr(\"glWindowPos3svARB\"))\n\tgpWindowPos3svMESA = uintptr(getProcAddr(\"glWindowPos3svMESA\"))\n\tgpWindowPos4dMESA = uintptr(getProcAddr(\"glWindowPos4dMESA\"))\n\tgpWindowPos4dvMESA = uintptr(getProcAddr(\"glWindowPos4dvMESA\"))\n\tgpWindowPos4fMESA = uintptr(getProcAddr(\"glWindowPos4fMESA\"))\n\tgpWindowPos4fvMESA = uintptr(getProcAddr(\"glWindowPos4fvMESA\"))\n\tgpWindowPos4iMESA = uintptr(getProcAddr(\"glWindowPos4iMESA\"))\n\tgpWindowPos4ivMESA = uintptr(getProcAddr(\"glWindowPos4ivMESA\"))\n\tgpWindowPos4sMESA = uintptr(getProcAddr(\"glWindowPos4sMESA\"))\n\tgpWindowPos4svMESA = uintptr(getProcAddr(\"glWindowPos4svMESA\"))\n\tgpWindowRectanglesEXT = uintptr(getProcAddr(\"glWindowRectanglesEXT\"))\n\tgpWriteMaskEXT = uintptr(getProcAddr(\"glWriteMaskEXT\"))\n\treturn nil\n}", "func InitWithProcAddrFunc(getProcAddr func(name string) unsafe.Pointer) error {\n\tgpAccum = (C.GPACCUM)(getProcAddr(\"glAccum\"))\n\tif gpAccum == nil {\n\t\treturn errors.New(\"glAccum\")\n\t}\n\tgpAccumxOES = (C.GPACCUMXOES)(getProcAddr(\"glAccumxOES\"))\n\tgpAcquireKeyedMutexWin32EXT = (C.GPACQUIREKEYEDMUTEXWIN32EXT)(getProcAddr(\"glAcquireKeyedMutexWin32EXT\"))\n\tgpActiveProgramEXT = (C.GPACTIVEPROGRAMEXT)(getProcAddr(\"glActiveProgramEXT\"))\n\tgpActiveShaderProgram = (C.GPACTIVESHADERPROGRAM)(getProcAddr(\"glActiveShaderProgram\"))\n\tif gpActiveShaderProgram == nil {\n\t\treturn errors.New(\"glActiveShaderProgram\")\n\t}\n\tgpActiveShaderProgramEXT = (C.GPACTIVESHADERPROGRAMEXT)(getProcAddr(\"glActiveShaderProgramEXT\"))\n\tgpActiveStencilFaceEXT = (C.GPACTIVESTENCILFACEEXT)(getProcAddr(\"glActiveStencilFaceEXT\"))\n\tgpActiveTexture = (C.GPACTIVETEXTURE)(getProcAddr(\"glActiveTexture\"))\n\tif gpActiveTexture == nil {\n\t\treturn errors.New(\"glActiveTexture\")\n\t}\n\tgpActiveTextureARB = (C.GPACTIVETEXTUREARB)(getProcAddr(\"glActiveTextureARB\"))\n\tgpActiveVaryingNV = (C.GPACTIVEVARYINGNV)(getProcAddr(\"glActiveVaryingNV\"))\n\tgpAlphaFragmentOp1ATI = (C.GPALPHAFRAGMENTOP1ATI)(getProcAddr(\"glAlphaFragmentOp1ATI\"))\n\tgpAlphaFragmentOp2ATI = (C.GPALPHAFRAGMENTOP2ATI)(getProcAddr(\"glAlphaFragmentOp2ATI\"))\n\tgpAlphaFragmentOp3ATI = (C.GPALPHAFRAGMENTOP3ATI)(getProcAddr(\"glAlphaFragmentOp3ATI\"))\n\tgpAlphaFunc = (C.GPALPHAFUNC)(getProcAddr(\"glAlphaFunc\"))\n\tif gpAlphaFunc == nil {\n\t\treturn errors.New(\"glAlphaFunc\")\n\t}\n\tgpAlphaFuncxOES = (C.GPALPHAFUNCXOES)(getProcAddr(\"glAlphaFuncxOES\"))\n\tgpAlphaToCoverageDitherControlNV = (C.GPALPHATOCOVERAGEDITHERCONTROLNV)(getProcAddr(\"glAlphaToCoverageDitherControlNV\"))\n\tgpApplyFramebufferAttachmentCMAAINTEL = (C.GPAPPLYFRAMEBUFFERATTACHMENTCMAAINTEL)(getProcAddr(\"glApplyFramebufferAttachmentCMAAINTEL\"))\n\tgpApplyTextureEXT = (C.GPAPPLYTEXTUREEXT)(getProcAddr(\"glApplyTextureEXT\"))\n\tgpAreProgramsResidentNV = (C.GPAREPROGRAMSRESIDENTNV)(getProcAddr(\"glAreProgramsResidentNV\"))\n\tgpAreTexturesResident = (C.GPARETEXTURESRESIDENT)(getProcAddr(\"glAreTexturesResident\"))\n\tif gpAreTexturesResident == nil {\n\t\treturn errors.New(\"glAreTexturesResident\")\n\t}\n\tgpAreTexturesResidentEXT = (C.GPARETEXTURESRESIDENTEXT)(getProcAddr(\"glAreTexturesResidentEXT\"))\n\tgpArrayElement = (C.GPARRAYELEMENT)(getProcAddr(\"glArrayElement\"))\n\tif gpArrayElement == nil {\n\t\treturn errors.New(\"glArrayElement\")\n\t}\n\tgpArrayElementEXT = (C.GPARRAYELEMENTEXT)(getProcAddr(\"glArrayElementEXT\"))\n\tgpArrayObjectATI = (C.GPARRAYOBJECTATI)(getProcAddr(\"glArrayObjectATI\"))\n\tgpAsyncCopyBufferSubDataNVX = (C.GPASYNCCOPYBUFFERSUBDATANVX)(getProcAddr(\"glAsyncCopyBufferSubDataNVX\"))\n\tgpAsyncCopyImageSubDataNVX = (C.GPASYNCCOPYIMAGESUBDATANVX)(getProcAddr(\"glAsyncCopyImageSubDataNVX\"))\n\tgpAsyncMarkerSGIX = (C.GPASYNCMARKERSGIX)(getProcAddr(\"glAsyncMarkerSGIX\"))\n\tgpAttachObjectARB = (C.GPATTACHOBJECTARB)(getProcAddr(\"glAttachObjectARB\"))\n\tgpAttachShader = (C.GPATTACHSHADER)(getProcAddr(\"glAttachShader\"))\n\tif gpAttachShader == nil {\n\t\treturn errors.New(\"glAttachShader\")\n\t}\n\tgpBegin = (C.GPBEGIN)(getProcAddr(\"glBegin\"))\n\tif gpBegin == nil {\n\t\treturn errors.New(\"glBegin\")\n\t}\n\tgpBeginConditionalRender = (C.GPBEGINCONDITIONALRENDER)(getProcAddr(\"glBeginConditionalRender\"))\n\tif gpBeginConditionalRender == nil {\n\t\treturn errors.New(\"glBeginConditionalRender\")\n\t}\n\tgpBeginConditionalRenderNV = (C.GPBEGINCONDITIONALRENDERNV)(getProcAddr(\"glBeginConditionalRenderNV\"))\n\tgpBeginConditionalRenderNVX = (C.GPBEGINCONDITIONALRENDERNVX)(getProcAddr(\"glBeginConditionalRenderNVX\"))\n\tgpBeginFragmentShaderATI = (C.GPBEGINFRAGMENTSHADERATI)(getProcAddr(\"glBeginFragmentShaderATI\"))\n\tgpBeginOcclusionQueryNV = (C.GPBEGINOCCLUSIONQUERYNV)(getProcAddr(\"glBeginOcclusionQueryNV\"))\n\tgpBeginPerfMonitorAMD = (C.GPBEGINPERFMONITORAMD)(getProcAddr(\"glBeginPerfMonitorAMD\"))\n\tgpBeginPerfQueryINTEL = (C.GPBEGINPERFQUERYINTEL)(getProcAddr(\"glBeginPerfQueryINTEL\"))\n\tgpBeginQuery = (C.GPBEGINQUERY)(getProcAddr(\"glBeginQuery\"))\n\tif gpBeginQuery == nil {\n\t\treturn errors.New(\"glBeginQuery\")\n\t}\n\tgpBeginQueryARB = (C.GPBEGINQUERYARB)(getProcAddr(\"glBeginQueryARB\"))\n\tgpBeginQueryIndexed = (C.GPBEGINQUERYINDEXED)(getProcAddr(\"glBeginQueryIndexed\"))\n\tif gpBeginQueryIndexed == nil {\n\t\treturn errors.New(\"glBeginQueryIndexed\")\n\t}\n\tgpBeginTransformFeedback = (C.GPBEGINTRANSFORMFEEDBACK)(getProcAddr(\"glBeginTransformFeedback\"))\n\tif gpBeginTransformFeedback == nil {\n\t\treturn errors.New(\"glBeginTransformFeedback\")\n\t}\n\tgpBeginTransformFeedbackEXT = (C.GPBEGINTRANSFORMFEEDBACKEXT)(getProcAddr(\"glBeginTransformFeedbackEXT\"))\n\tgpBeginTransformFeedbackNV = (C.GPBEGINTRANSFORMFEEDBACKNV)(getProcAddr(\"glBeginTransformFeedbackNV\"))\n\tgpBeginVertexShaderEXT = (C.GPBEGINVERTEXSHADEREXT)(getProcAddr(\"glBeginVertexShaderEXT\"))\n\tgpBeginVideoCaptureNV = (C.GPBEGINVIDEOCAPTURENV)(getProcAddr(\"glBeginVideoCaptureNV\"))\n\tgpBindAttribLocation = (C.GPBINDATTRIBLOCATION)(getProcAddr(\"glBindAttribLocation\"))\n\tif gpBindAttribLocation == nil {\n\t\treturn errors.New(\"glBindAttribLocation\")\n\t}\n\tgpBindAttribLocationARB = (C.GPBINDATTRIBLOCATIONARB)(getProcAddr(\"glBindAttribLocationARB\"))\n\tgpBindBuffer = (C.GPBINDBUFFER)(getProcAddr(\"glBindBuffer\"))\n\tif gpBindBuffer == nil {\n\t\treturn errors.New(\"glBindBuffer\")\n\t}\n\tgpBindBufferARB = (C.GPBINDBUFFERARB)(getProcAddr(\"glBindBufferARB\"))\n\tgpBindBufferBase = (C.GPBINDBUFFERBASE)(getProcAddr(\"glBindBufferBase\"))\n\tif gpBindBufferBase == nil {\n\t\treturn errors.New(\"glBindBufferBase\")\n\t}\n\tgpBindBufferBaseEXT = (C.GPBINDBUFFERBASEEXT)(getProcAddr(\"glBindBufferBaseEXT\"))\n\tgpBindBufferBaseNV = (C.GPBINDBUFFERBASENV)(getProcAddr(\"glBindBufferBaseNV\"))\n\tgpBindBufferOffsetEXT = (C.GPBINDBUFFEROFFSETEXT)(getProcAddr(\"glBindBufferOffsetEXT\"))\n\tgpBindBufferOffsetNV = (C.GPBINDBUFFEROFFSETNV)(getProcAddr(\"glBindBufferOffsetNV\"))\n\tgpBindBufferRange = (C.GPBINDBUFFERRANGE)(getProcAddr(\"glBindBufferRange\"))\n\tif gpBindBufferRange == nil {\n\t\treturn errors.New(\"glBindBufferRange\")\n\t}\n\tgpBindBufferRangeEXT = (C.GPBINDBUFFERRANGEEXT)(getProcAddr(\"glBindBufferRangeEXT\"))\n\tgpBindBufferRangeNV = (C.GPBINDBUFFERRANGENV)(getProcAddr(\"glBindBufferRangeNV\"))\n\tgpBindBuffersBase = (C.GPBINDBUFFERSBASE)(getProcAddr(\"glBindBuffersBase\"))\n\tif gpBindBuffersBase == nil {\n\t\treturn errors.New(\"glBindBuffersBase\")\n\t}\n\tgpBindBuffersRange = (C.GPBINDBUFFERSRANGE)(getProcAddr(\"glBindBuffersRange\"))\n\tif gpBindBuffersRange == nil {\n\t\treturn errors.New(\"glBindBuffersRange\")\n\t}\n\tgpBindFragDataLocation = (C.GPBINDFRAGDATALOCATION)(getProcAddr(\"glBindFragDataLocation\"))\n\tif gpBindFragDataLocation == nil {\n\t\treturn errors.New(\"glBindFragDataLocation\")\n\t}\n\tgpBindFragDataLocationEXT = (C.GPBINDFRAGDATALOCATIONEXT)(getProcAddr(\"glBindFragDataLocationEXT\"))\n\tgpBindFragDataLocationIndexed = (C.GPBINDFRAGDATALOCATIONINDEXED)(getProcAddr(\"glBindFragDataLocationIndexed\"))\n\tif gpBindFragDataLocationIndexed == nil {\n\t\treturn errors.New(\"glBindFragDataLocationIndexed\")\n\t}\n\tgpBindFragmentShaderATI = (C.GPBINDFRAGMENTSHADERATI)(getProcAddr(\"glBindFragmentShaderATI\"))\n\tgpBindFramebuffer = (C.GPBINDFRAMEBUFFER)(getProcAddr(\"glBindFramebuffer\"))\n\tif gpBindFramebuffer == nil {\n\t\treturn errors.New(\"glBindFramebuffer\")\n\t}\n\tgpBindFramebufferEXT = (C.GPBINDFRAMEBUFFEREXT)(getProcAddr(\"glBindFramebufferEXT\"))\n\tgpBindImageTexture = (C.GPBINDIMAGETEXTURE)(getProcAddr(\"glBindImageTexture\"))\n\tif gpBindImageTexture == nil {\n\t\treturn errors.New(\"glBindImageTexture\")\n\t}\n\tgpBindImageTextureEXT = (C.GPBINDIMAGETEXTUREEXT)(getProcAddr(\"glBindImageTextureEXT\"))\n\tgpBindImageTextures = (C.GPBINDIMAGETEXTURES)(getProcAddr(\"glBindImageTextures\"))\n\tif gpBindImageTextures == nil {\n\t\treturn errors.New(\"glBindImageTextures\")\n\t}\n\tgpBindLightParameterEXT = (C.GPBINDLIGHTPARAMETEREXT)(getProcAddr(\"glBindLightParameterEXT\"))\n\tgpBindMaterialParameterEXT = (C.GPBINDMATERIALPARAMETEREXT)(getProcAddr(\"glBindMaterialParameterEXT\"))\n\tgpBindMultiTextureEXT = (C.GPBINDMULTITEXTUREEXT)(getProcAddr(\"glBindMultiTextureEXT\"))\n\tgpBindParameterEXT = (C.GPBINDPARAMETEREXT)(getProcAddr(\"glBindParameterEXT\"))\n\tgpBindProgramARB = (C.GPBINDPROGRAMARB)(getProcAddr(\"glBindProgramARB\"))\n\tgpBindProgramNV = (C.GPBINDPROGRAMNV)(getProcAddr(\"glBindProgramNV\"))\n\tgpBindProgramPipeline = (C.GPBINDPROGRAMPIPELINE)(getProcAddr(\"glBindProgramPipeline\"))\n\tif gpBindProgramPipeline == nil {\n\t\treturn errors.New(\"glBindProgramPipeline\")\n\t}\n\tgpBindProgramPipelineEXT = (C.GPBINDPROGRAMPIPELINEEXT)(getProcAddr(\"glBindProgramPipelineEXT\"))\n\tgpBindRenderbuffer = (C.GPBINDRENDERBUFFER)(getProcAddr(\"glBindRenderbuffer\"))\n\tif gpBindRenderbuffer == nil {\n\t\treturn errors.New(\"glBindRenderbuffer\")\n\t}\n\tgpBindRenderbufferEXT = (C.GPBINDRENDERBUFFEREXT)(getProcAddr(\"glBindRenderbufferEXT\"))\n\tgpBindSampler = (C.GPBINDSAMPLER)(getProcAddr(\"glBindSampler\"))\n\tif gpBindSampler == nil {\n\t\treturn errors.New(\"glBindSampler\")\n\t}\n\tgpBindSamplers = (C.GPBINDSAMPLERS)(getProcAddr(\"glBindSamplers\"))\n\tif gpBindSamplers == nil {\n\t\treturn errors.New(\"glBindSamplers\")\n\t}\n\tgpBindShadingRateImageNV = (C.GPBINDSHADINGRATEIMAGENV)(getProcAddr(\"glBindShadingRateImageNV\"))\n\tgpBindTexGenParameterEXT = (C.GPBINDTEXGENPARAMETEREXT)(getProcAddr(\"glBindTexGenParameterEXT\"))\n\tgpBindTexture = (C.GPBINDTEXTURE)(getProcAddr(\"glBindTexture\"))\n\tif gpBindTexture == nil {\n\t\treturn errors.New(\"glBindTexture\")\n\t}\n\tgpBindTextureEXT = (C.GPBINDTEXTUREEXT)(getProcAddr(\"glBindTextureEXT\"))\n\tgpBindTextureUnit = (C.GPBINDTEXTUREUNIT)(getProcAddr(\"glBindTextureUnit\"))\n\tgpBindTextureUnitParameterEXT = (C.GPBINDTEXTUREUNITPARAMETEREXT)(getProcAddr(\"glBindTextureUnitParameterEXT\"))\n\tgpBindTextures = (C.GPBINDTEXTURES)(getProcAddr(\"glBindTextures\"))\n\tif gpBindTextures == nil {\n\t\treturn errors.New(\"glBindTextures\")\n\t}\n\tgpBindTransformFeedback = (C.GPBINDTRANSFORMFEEDBACK)(getProcAddr(\"glBindTransformFeedback\"))\n\tif gpBindTransformFeedback == nil {\n\t\treturn errors.New(\"glBindTransformFeedback\")\n\t}\n\tgpBindTransformFeedbackNV = (C.GPBINDTRANSFORMFEEDBACKNV)(getProcAddr(\"glBindTransformFeedbackNV\"))\n\tgpBindVertexArray = (C.GPBINDVERTEXARRAY)(getProcAddr(\"glBindVertexArray\"))\n\tif gpBindVertexArray == nil {\n\t\treturn errors.New(\"glBindVertexArray\")\n\t}\n\tgpBindVertexArrayAPPLE = (C.GPBINDVERTEXARRAYAPPLE)(getProcAddr(\"glBindVertexArrayAPPLE\"))\n\tgpBindVertexBuffer = (C.GPBINDVERTEXBUFFER)(getProcAddr(\"glBindVertexBuffer\"))\n\tif gpBindVertexBuffer == nil {\n\t\treturn errors.New(\"glBindVertexBuffer\")\n\t}\n\tgpBindVertexBuffers = (C.GPBINDVERTEXBUFFERS)(getProcAddr(\"glBindVertexBuffers\"))\n\tif gpBindVertexBuffers == nil {\n\t\treturn errors.New(\"glBindVertexBuffers\")\n\t}\n\tgpBindVertexShaderEXT = (C.GPBINDVERTEXSHADEREXT)(getProcAddr(\"glBindVertexShaderEXT\"))\n\tgpBindVideoCaptureStreamBufferNV = (C.GPBINDVIDEOCAPTURESTREAMBUFFERNV)(getProcAddr(\"glBindVideoCaptureStreamBufferNV\"))\n\tgpBindVideoCaptureStreamTextureNV = (C.GPBINDVIDEOCAPTURESTREAMTEXTURENV)(getProcAddr(\"glBindVideoCaptureStreamTextureNV\"))\n\tgpBinormal3bEXT = (C.GPBINORMAL3BEXT)(getProcAddr(\"glBinormal3bEXT\"))\n\tgpBinormal3bvEXT = (C.GPBINORMAL3BVEXT)(getProcAddr(\"glBinormal3bvEXT\"))\n\tgpBinormal3dEXT = (C.GPBINORMAL3DEXT)(getProcAddr(\"glBinormal3dEXT\"))\n\tgpBinormal3dvEXT = (C.GPBINORMAL3DVEXT)(getProcAddr(\"glBinormal3dvEXT\"))\n\tgpBinormal3fEXT = (C.GPBINORMAL3FEXT)(getProcAddr(\"glBinormal3fEXT\"))\n\tgpBinormal3fvEXT = (C.GPBINORMAL3FVEXT)(getProcAddr(\"glBinormal3fvEXT\"))\n\tgpBinormal3iEXT = (C.GPBINORMAL3IEXT)(getProcAddr(\"glBinormal3iEXT\"))\n\tgpBinormal3ivEXT = (C.GPBINORMAL3IVEXT)(getProcAddr(\"glBinormal3ivEXT\"))\n\tgpBinormal3sEXT = (C.GPBINORMAL3SEXT)(getProcAddr(\"glBinormal3sEXT\"))\n\tgpBinormal3svEXT = (C.GPBINORMAL3SVEXT)(getProcAddr(\"glBinormal3svEXT\"))\n\tgpBinormalPointerEXT = (C.GPBINORMALPOINTEREXT)(getProcAddr(\"glBinormalPointerEXT\"))\n\tgpBitmap = (C.GPBITMAP)(getProcAddr(\"glBitmap\"))\n\tif gpBitmap == nil {\n\t\treturn errors.New(\"glBitmap\")\n\t}\n\tgpBitmapxOES = (C.GPBITMAPXOES)(getProcAddr(\"glBitmapxOES\"))\n\tgpBlendBarrierKHR = (C.GPBLENDBARRIERKHR)(getProcAddr(\"glBlendBarrierKHR\"))\n\tgpBlendBarrierNV = (C.GPBLENDBARRIERNV)(getProcAddr(\"glBlendBarrierNV\"))\n\tgpBlendColor = (C.GPBLENDCOLOR)(getProcAddr(\"glBlendColor\"))\n\tif gpBlendColor == nil {\n\t\treturn errors.New(\"glBlendColor\")\n\t}\n\tgpBlendColorEXT = (C.GPBLENDCOLOREXT)(getProcAddr(\"glBlendColorEXT\"))\n\tgpBlendColorxOES = (C.GPBLENDCOLORXOES)(getProcAddr(\"glBlendColorxOES\"))\n\tgpBlendEquation = (C.GPBLENDEQUATION)(getProcAddr(\"glBlendEquation\"))\n\tif gpBlendEquation == nil {\n\t\treturn errors.New(\"glBlendEquation\")\n\t}\n\tgpBlendEquationEXT = (C.GPBLENDEQUATIONEXT)(getProcAddr(\"glBlendEquationEXT\"))\n\tgpBlendEquationIndexedAMD = (C.GPBLENDEQUATIONINDEXEDAMD)(getProcAddr(\"glBlendEquationIndexedAMD\"))\n\tgpBlendEquationSeparate = (C.GPBLENDEQUATIONSEPARATE)(getProcAddr(\"glBlendEquationSeparate\"))\n\tif gpBlendEquationSeparate == nil {\n\t\treturn errors.New(\"glBlendEquationSeparate\")\n\t}\n\tgpBlendEquationSeparateEXT = (C.GPBLENDEQUATIONSEPARATEEXT)(getProcAddr(\"glBlendEquationSeparateEXT\"))\n\tgpBlendEquationSeparateIndexedAMD = (C.GPBLENDEQUATIONSEPARATEINDEXEDAMD)(getProcAddr(\"glBlendEquationSeparateIndexedAMD\"))\n\tgpBlendEquationSeparatei = (C.GPBLENDEQUATIONSEPARATEI)(getProcAddr(\"glBlendEquationSeparatei\"))\n\tif gpBlendEquationSeparatei == nil {\n\t\treturn errors.New(\"glBlendEquationSeparatei\")\n\t}\n\tgpBlendEquationSeparateiARB = (C.GPBLENDEQUATIONSEPARATEIARB)(getProcAddr(\"glBlendEquationSeparateiARB\"))\n\tgpBlendEquationi = (C.GPBLENDEQUATIONI)(getProcAddr(\"glBlendEquationi\"))\n\tif gpBlendEquationi == nil {\n\t\treturn errors.New(\"glBlendEquationi\")\n\t}\n\tgpBlendEquationiARB = (C.GPBLENDEQUATIONIARB)(getProcAddr(\"glBlendEquationiARB\"))\n\tgpBlendFunc = (C.GPBLENDFUNC)(getProcAddr(\"glBlendFunc\"))\n\tif gpBlendFunc == nil {\n\t\treturn errors.New(\"glBlendFunc\")\n\t}\n\tgpBlendFuncIndexedAMD = (C.GPBLENDFUNCINDEXEDAMD)(getProcAddr(\"glBlendFuncIndexedAMD\"))\n\tgpBlendFuncSeparate = (C.GPBLENDFUNCSEPARATE)(getProcAddr(\"glBlendFuncSeparate\"))\n\tif gpBlendFuncSeparate == nil {\n\t\treturn errors.New(\"glBlendFuncSeparate\")\n\t}\n\tgpBlendFuncSeparateEXT = (C.GPBLENDFUNCSEPARATEEXT)(getProcAddr(\"glBlendFuncSeparateEXT\"))\n\tgpBlendFuncSeparateINGR = (C.GPBLENDFUNCSEPARATEINGR)(getProcAddr(\"glBlendFuncSeparateINGR\"))\n\tgpBlendFuncSeparateIndexedAMD = (C.GPBLENDFUNCSEPARATEINDEXEDAMD)(getProcAddr(\"glBlendFuncSeparateIndexedAMD\"))\n\tgpBlendFuncSeparatei = (C.GPBLENDFUNCSEPARATEI)(getProcAddr(\"glBlendFuncSeparatei\"))\n\tif gpBlendFuncSeparatei == nil {\n\t\treturn errors.New(\"glBlendFuncSeparatei\")\n\t}\n\tgpBlendFuncSeparateiARB = (C.GPBLENDFUNCSEPARATEIARB)(getProcAddr(\"glBlendFuncSeparateiARB\"))\n\tgpBlendFunci = (C.GPBLENDFUNCI)(getProcAddr(\"glBlendFunci\"))\n\tif gpBlendFunci == nil {\n\t\treturn errors.New(\"glBlendFunci\")\n\t}\n\tgpBlendFunciARB = (C.GPBLENDFUNCIARB)(getProcAddr(\"glBlendFunciARB\"))\n\tgpBlendParameteriNV = (C.GPBLENDPARAMETERINV)(getProcAddr(\"glBlendParameteriNV\"))\n\tgpBlitFramebuffer = (C.GPBLITFRAMEBUFFER)(getProcAddr(\"glBlitFramebuffer\"))\n\tif gpBlitFramebuffer == nil {\n\t\treturn errors.New(\"glBlitFramebuffer\")\n\t}\n\tgpBlitFramebufferEXT = (C.GPBLITFRAMEBUFFEREXT)(getProcAddr(\"glBlitFramebufferEXT\"))\n\tgpBlitNamedFramebuffer = (C.GPBLITNAMEDFRAMEBUFFER)(getProcAddr(\"glBlitNamedFramebuffer\"))\n\tgpBufferAddressRangeNV = (C.GPBUFFERADDRESSRANGENV)(getProcAddr(\"glBufferAddressRangeNV\"))\n\tgpBufferAttachMemoryNV = (C.GPBUFFERATTACHMEMORYNV)(getProcAddr(\"glBufferAttachMemoryNV\"))\n\tgpBufferData = (C.GPBUFFERDATA)(getProcAddr(\"glBufferData\"))\n\tif gpBufferData == nil {\n\t\treturn errors.New(\"glBufferData\")\n\t}\n\tgpBufferDataARB = (C.GPBUFFERDATAARB)(getProcAddr(\"glBufferDataARB\"))\n\tgpBufferPageCommitmentARB = (C.GPBUFFERPAGECOMMITMENTARB)(getProcAddr(\"glBufferPageCommitmentARB\"))\n\tgpBufferPageCommitmentMemNV = (C.GPBUFFERPAGECOMMITMENTMEMNV)(getProcAddr(\"glBufferPageCommitmentMemNV\"))\n\tgpBufferParameteriAPPLE = (C.GPBUFFERPARAMETERIAPPLE)(getProcAddr(\"glBufferParameteriAPPLE\"))\n\tgpBufferStorage = (C.GPBUFFERSTORAGE)(getProcAddr(\"glBufferStorage\"))\n\tif gpBufferStorage == nil {\n\t\treturn errors.New(\"glBufferStorage\")\n\t}\n\tgpBufferStorageExternalEXT = (C.GPBUFFERSTORAGEEXTERNALEXT)(getProcAddr(\"glBufferStorageExternalEXT\"))\n\tgpBufferStorageMemEXT = (C.GPBUFFERSTORAGEMEMEXT)(getProcAddr(\"glBufferStorageMemEXT\"))\n\tgpBufferSubData = (C.GPBUFFERSUBDATA)(getProcAddr(\"glBufferSubData\"))\n\tif gpBufferSubData == nil {\n\t\treturn errors.New(\"glBufferSubData\")\n\t}\n\tgpBufferSubDataARB = (C.GPBUFFERSUBDATAARB)(getProcAddr(\"glBufferSubDataARB\"))\n\tgpCallCommandListNV = (C.GPCALLCOMMANDLISTNV)(getProcAddr(\"glCallCommandListNV\"))\n\tgpCallList = (C.GPCALLLIST)(getProcAddr(\"glCallList\"))\n\tif gpCallList == nil {\n\t\treturn errors.New(\"glCallList\")\n\t}\n\tgpCallLists = (C.GPCALLLISTS)(getProcAddr(\"glCallLists\"))\n\tif gpCallLists == nil {\n\t\treturn errors.New(\"glCallLists\")\n\t}\n\tgpCheckFramebufferStatus = (C.GPCHECKFRAMEBUFFERSTATUS)(getProcAddr(\"glCheckFramebufferStatus\"))\n\tif gpCheckFramebufferStatus == nil {\n\t\treturn errors.New(\"glCheckFramebufferStatus\")\n\t}\n\tgpCheckFramebufferStatusEXT = (C.GPCHECKFRAMEBUFFERSTATUSEXT)(getProcAddr(\"glCheckFramebufferStatusEXT\"))\n\tgpCheckNamedFramebufferStatus = (C.GPCHECKNAMEDFRAMEBUFFERSTATUS)(getProcAddr(\"glCheckNamedFramebufferStatus\"))\n\tgpCheckNamedFramebufferStatusEXT = (C.GPCHECKNAMEDFRAMEBUFFERSTATUSEXT)(getProcAddr(\"glCheckNamedFramebufferStatusEXT\"))\n\tgpClampColor = (C.GPCLAMPCOLOR)(getProcAddr(\"glClampColor\"))\n\tif gpClampColor == nil {\n\t\treturn errors.New(\"glClampColor\")\n\t}\n\tgpClampColorARB = (C.GPCLAMPCOLORARB)(getProcAddr(\"glClampColorARB\"))\n\tgpClear = (C.GPCLEAR)(getProcAddr(\"glClear\"))\n\tif gpClear == nil {\n\t\treturn errors.New(\"glClear\")\n\t}\n\tgpClearAccum = (C.GPCLEARACCUM)(getProcAddr(\"glClearAccum\"))\n\tif gpClearAccum == nil {\n\t\treturn errors.New(\"glClearAccum\")\n\t}\n\tgpClearAccumxOES = (C.GPCLEARACCUMXOES)(getProcAddr(\"glClearAccumxOES\"))\n\tgpClearBufferData = (C.GPCLEARBUFFERDATA)(getProcAddr(\"glClearBufferData\"))\n\tif gpClearBufferData == nil {\n\t\treturn errors.New(\"glClearBufferData\")\n\t}\n\tgpClearBufferSubData = (C.GPCLEARBUFFERSUBDATA)(getProcAddr(\"glClearBufferSubData\"))\n\tif gpClearBufferSubData == nil {\n\t\treturn errors.New(\"glClearBufferSubData\")\n\t}\n\tgpClearBufferfi = (C.GPCLEARBUFFERFI)(getProcAddr(\"glClearBufferfi\"))\n\tif gpClearBufferfi == nil {\n\t\treturn errors.New(\"glClearBufferfi\")\n\t}\n\tgpClearBufferfv = (C.GPCLEARBUFFERFV)(getProcAddr(\"glClearBufferfv\"))\n\tif gpClearBufferfv == nil {\n\t\treturn errors.New(\"glClearBufferfv\")\n\t}\n\tgpClearBufferiv = (C.GPCLEARBUFFERIV)(getProcAddr(\"glClearBufferiv\"))\n\tif gpClearBufferiv == nil {\n\t\treturn errors.New(\"glClearBufferiv\")\n\t}\n\tgpClearBufferuiv = (C.GPCLEARBUFFERUIV)(getProcAddr(\"glClearBufferuiv\"))\n\tif gpClearBufferuiv == nil {\n\t\treturn errors.New(\"glClearBufferuiv\")\n\t}\n\tgpClearColor = (C.GPCLEARCOLOR)(getProcAddr(\"glClearColor\"))\n\tif gpClearColor == nil {\n\t\treturn errors.New(\"glClearColor\")\n\t}\n\tgpClearColorIiEXT = (C.GPCLEARCOLORIIEXT)(getProcAddr(\"glClearColorIiEXT\"))\n\tgpClearColorIuiEXT = (C.GPCLEARCOLORIUIEXT)(getProcAddr(\"glClearColorIuiEXT\"))\n\tgpClearColorxOES = (C.GPCLEARCOLORXOES)(getProcAddr(\"glClearColorxOES\"))\n\tgpClearDepth = (C.GPCLEARDEPTH)(getProcAddr(\"glClearDepth\"))\n\tif gpClearDepth == nil {\n\t\treturn errors.New(\"glClearDepth\")\n\t}\n\tgpClearDepthdNV = (C.GPCLEARDEPTHDNV)(getProcAddr(\"glClearDepthdNV\"))\n\tgpClearDepthf = (C.GPCLEARDEPTHF)(getProcAddr(\"glClearDepthf\"))\n\tif gpClearDepthf == nil {\n\t\treturn errors.New(\"glClearDepthf\")\n\t}\n\tgpClearDepthfOES = (C.GPCLEARDEPTHFOES)(getProcAddr(\"glClearDepthfOES\"))\n\tgpClearDepthxOES = (C.GPCLEARDEPTHXOES)(getProcAddr(\"glClearDepthxOES\"))\n\tgpClearIndex = (C.GPCLEARINDEX)(getProcAddr(\"glClearIndex\"))\n\tif gpClearIndex == nil {\n\t\treturn errors.New(\"glClearIndex\")\n\t}\n\tgpClearNamedBufferData = (C.GPCLEARNAMEDBUFFERDATA)(getProcAddr(\"glClearNamedBufferData\"))\n\tgpClearNamedBufferDataEXT = (C.GPCLEARNAMEDBUFFERDATAEXT)(getProcAddr(\"glClearNamedBufferDataEXT\"))\n\tgpClearNamedBufferSubData = (C.GPCLEARNAMEDBUFFERSUBDATA)(getProcAddr(\"glClearNamedBufferSubData\"))\n\tgpClearNamedBufferSubDataEXT = (C.GPCLEARNAMEDBUFFERSUBDATAEXT)(getProcAddr(\"glClearNamedBufferSubDataEXT\"))\n\tgpClearNamedFramebufferfi = (C.GPCLEARNAMEDFRAMEBUFFERFI)(getProcAddr(\"glClearNamedFramebufferfi\"))\n\tgpClearNamedFramebufferfv = (C.GPCLEARNAMEDFRAMEBUFFERFV)(getProcAddr(\"glClearNamedFramebufferfv\"))\n\tgpClearNamedFramebufferiv = (C.GPCLEARNAMEDFRAMEBUFFERIV)(getProcAddr(\"glClearNamedFramebufferiv\"))\n\tgpClearNamedFramebufferuiv = (C.GPCLEARNAMEDFRAMEBUFFERUIV)(getProcAddr(\"glClearNamedFramebufferuiv\"))\n\tgpClearStencil = (C.GPCLEARSTENCIL)(getProcAddr(\"glClearStencil\"))\n\tif gpClearStencil == nil {\n\t\treturn errors.New(\"glClearStencil\")\n\t}\n\tgpClearTexImage = (C.GPCLEARTEXIMAGE)(getProcAddr(\"glClearTexImage\"))\n\tif gpClearTexImage == nil {\n\t\treturn errors.New(\"glClearTexImage\")\n\t}\n\tgpClearTexSubImage = (C.GPCLEARTEXSUBIMAGE)(getProcAddr(\"glClearTexSubImage\"))\n\tif gpClearTexSubImage == nil {\n\t\treturn errors.New(\"glClearTexSubImage\")\n\t}\n\tgpClientActiveTexture = (C.GPCLIENTACTIVETEXTURE)(getProcAddr(\"glClientActiveTexture\"))\n\tif gpClientActiveTexture == nil {\n\t\treturn errors.New(\"glClientActiveTexture\")\n\t}\n\tgpClientActiveTextureARB = (C.GPCLIENTACTIVETEXTUREARB)(getProcAddr(\"glClientActiveTextureARB\"))\n\tgpClientActiveVertexStreamATI = (C.GPCLIENTACTIVEVERTEXSTREAMATI)(getProcAddr(\"glClientActiveVertexStreamATI\"))\n\tgpClientAttribDefaultEXT = (C.GPCLIENTATTRIBDEFAULTEXT)(getProcAddr(\"glClientAttribDefaultEXT\"))\n\tgpClientWaitSemaphoreui64NVX = (C.GPCLIENTWAITSEMAPHOREUI64NVX)(getProcAddr(\"glClientWaitSemaphoreui64NVX\"))\n\tgpClientWaitSync = (C.GPCLIENTWAITSYNC)(getProcAddr(\"glClientWaitSync\"))\n\tif gpClientWaitSync == nil {\n\t\treturn errors.New(\"glClientWaitSync\")\n\t}\n\tgpClipControl = (C.GPCLIPCONTROL)(getProcAddr(\"glClipControl\"))\n\tgpClipPlane = (C.GPCLIPPLANE)(getProcAddr(\"glClipPlane\"))\n\tif gpClipPlane == nil {\n\t\treturn errors.New(\"glClipPlane\")\n\t}\n\tgpClipPlanefOES = (C.GPCLIPPLANEFOES)(getProcAddr(\"glClipPlanefOES\"))\n\tgpClipPlanexOES = (C.GPCLIPPLANEXOES)(getProcAddr(\"glClipPlanexOES\"))\n\tgpColor3b = (C.GPCOLOR3B)(getProcAddr(\"glColor3b\"))\n\tif gpColor3b == nil {\n\t\treturn errors.New(\"glColor3b\")\n\t}\n\tgpColor3bv = (C.GPCOLOR3BV)(getProcAddr(\"glColor3bv\"))\n\tif gpColor3bv == nil {\n\t\treturn errors.New(\"glColor3bv\")\n\t}\n\tgpColor3d = (C.GPCOLOR3D)(getProcAddr(\"glColor3d\"))\n\tif gpColor3d == nil {\n\t\treturn errors.New(\"glColor3d\")\n\t}\n\tgpColor3dv = (C.GPCOLOR3DV)(getProcAddr(\"glColor3dv\"))\n\tif gpColor3dv == nil {\n\t\treturn errors.New(\"glColor3dv\")\n\t}\n\tgpColor3f = (C.GPCOLOR3F)(getProcAddr(\"glColor3f\"))\n\tif gpColor3f == nil {\n\t\treturn errors.New(\"glColor3f\")\n\t}\n\tgpColor3fVertex3fSUN = (C.GPCOLOR3FVERTEX3FSUN)(getProcAddr(\"glColor3fVertex3fSUN\"))\n\tgpColor3fVertex3fvSUN = (C.GPCOLOR3FVERTEX3FVSUN)(getProcAddr(\"glColor3fVertex3fvSUN\"))\n\tgpColor3fv = (C.GPCOLOR3FV)(getProcAddr(\"glColor3fv\"))\n\tif gpColor3fv == nil {\n\t\treturn errors.New(\"glColor3fv\")\n\t}\n\tgpColor3hNV = (C.GPCOLOR3HNV)(getProcAddr(\"glColor3hNV\"))\n\tgpColor3hvNV = (C.GPCOLOR3HVNV)(getProcAddr(\"glColor3hvNV\"))\n\tgpColor3i = (C.GPCOLOR3I)(getProcAddr(\"glColor3i\"))\n\tif gpColor3i == nil {\n\t\treturn errors.New(\"glColor3i\")\n\t}\n\tgpColor3iv = (C.GPCOLOR3IV)(getProcAddr(\"glColor3iv\"))\n\tif gpColor3iv == nil {\n\t\treturn errors.New(\"glColor3iv\")\n\t}\n\tgpColor3s = (C.GPCOLOR3S)(getProcAddr(\"glColor3s\"))\n\tif gpColor3s == nil {\n\t\treturn errors.New(\"glColor3s\")\n\t}\n\tgpColor3sv = (C.GPCOLOR3SV)(getProcAddr(\"glColor3sv\"))\n\tif gpColor3sv == nil {\n\t\treturn errors.New(\"glColor3sv\")\n\t}\n\tgpColor3ub = (C.GPCOLOR3UB)(getProcAddr(\"glColor3ub\"))\n\tif gpColor3ub == nil {\n\t\treturn errors.New(\"glColor3ub\")\n\t}\n\tgpColor3ubv = (C.GPCOLOR3UBV)(getProcAddr(\"glColor3ubv\"))\n\tif gpColor3ubv == nil {\n\t\treturn errors.New(\"glColor3ubv\")\n\t}\n\tgpColor3ui = (C.GPCOLOR3UI)(getProcAddr(\"glColor3ui\"))\n\tif gpColor3ui == nil {\n\t\treturn errors.New(\"glColor3ui\")\n\t}\n\tgpColor3uiv = (C.GPCOLOR3UIV)(getProcAddr(\"glColor3uiv\"))\n\tif gpColor3uiv == nil {\n\t\treturn errors.New(\"glColor3uiv\")\n\t}\n\tgpColor3us = (C.GPCOLOR3US)(getProcAddr(\"glColor3us\"))\n\tif gpColor3us == nil {\n\t\treturn errors.New(\"glColor3us\")\n\t}\n\tgpColor3usv = (C.GPCOLOR3USV)(getProcAddr(\"glColor3usv\"))\n\tif gpColor3usv == nil {\n\t\treturn errors.New(\"glColor3usv\")\n\t}\n\tgpColor3xOES = (C.GPCOLOR3XOES)(getProcAddr(\"glColor3xOES\"))\n\tgpColor3xvOES = (C.GPCOLOR3XVOES)(getProcAddr(\"glColor3xvOES\"))\n\tgpColor4b = (C.GPCOLOR4B)(getProcAddr(\"glColor4b\"))\n\tif gpColor4b == nil {\n\t\treturn errors.New(\"glColor4b\")\n\t}\n\tgpColor4bv = (C.GPCOLOR4BV)(getProcAddr(\"glColor4bv\"))\n\tif gpColor4bv == nil {\n\t\treturn errors.New(\"glColor4bv\")\n\t}\n\tgpColor4d = (C.GPCOLOR4D)(getProcAddr(\"glColor4d\"))\n\tif gpColor4d == nil {\n\t\treturn errors.New(\"glColor4d\")\n\t}\n\tgpColor4dv = (C.GPCOLOR4DV)(getProcAddr(\"glColor4dv\"))\n\tif gpColor4dv == nil {\n\t\treturn errors.New(\"glColor4dv\")\n\t}\n\tgpColor4f = (C.GPCOLOR4F)(getProcAddr(\"glColor4f\"))\n\tif gpColor4f == nil {\n\t\treturn errors.New(\"glColor4f\")\n\t}\n\tgpColor4fNormal3fVertex3fSUN = (C.GPCOLOR4FNORMAL3FVERTEX3FSUN)(getProcAddr(\"glColor4fNormal3fVertex3fSUN\"))\n\tgpColor4fNormal3fVertex3fvSUN = (C.GPCOLOR4FNORMAL3FVERTEX3FVSUN)(getProcAddr(\"glColor4fNormal3fVertex3fvSUN\"))\n\tgpColor4fv = (C.GPCOLOR4FV)(getProcAddr(\"glColor4fv\"))\n\tif gpColor4fv == nil {\n\t\treturn errors.New(\"glColor4fv\")\n\t}\n\tgpColor4hNV = (C.GPCOLOR4HNV)(getProcAddr(\"glColor4hNV\"))\n\tgpColor4hvNV = (C.GPCOLOR4HVNV)(getProcAddr(\"glColor4hvNV\"))\n\tgpColor4i = (C.GPCOLOR4I)(getProcAddr(\"glColor4i\"))\n\tif gpColor4i == nil {\n\t\treturn errors.New(\"glColor4i\")\n\t}\n\tgpColor4iv = (C.GPCOLOR4IV)(getProcAddr(\"glColor4iv\"))\n\tif gpColor4iv == nil {\n\t\treturn errors.New(\"glColor4iv\")\n\t}\n\tgpColor4s = (C.GPCOLOR4S)(getProcAddr(\"glColor4s\"))\n\tif gpColor4s == nil {\n\t\treturn errors.New(\"glColor4s\")\n\t}\n\tgpColor4sv = (C.GPCOLOR4SV)(getProcAddr(\"glColor4sv\"))\n\tif gpColor4sv == nil {\n\t\treturn errors.New(\"glColor4sv\")\n\t}\n\tgpColor4ub = (C.GPCOLOR4UB)(getProcAddr(\"glColor4ub\"))\n\tif gpColor4ub == nil {\n\t\treturn errors.New(\"glColor4ub\")\n\t}\n\tgpColor4ubVertex2fSUN = (C.GPCOLOR4UBVERTEX2FSUN)(getProcAddr(\"glColor4ubVertex2fSUN\"))\n\tgpColor4ubVertex2fvSUN = (C.GPCOLOR4UBVERTEX2FVSUN)(getProcAddr(\"glColor4ubVertex2fvSUN\"))\n\tgpColor4ubVertex3fSUN = (C.GPCOLOR4UBVERTEX3FSUN)(getProcAddr(\"glColor4ubVertex3fSUN\"))\n\tgpColor4ubVertex3fvSUN = (C.GPCOLOR4UBVERTEX3FVSUN)(getProcAddr(\"glColor4ubVertex3fvSUN\"))\n\tgpColor4ubv = (C.GPCOLOR4UBV)(getProcAddr(\"glColor4ubv\"))\n\tif gpColor4ubv == nil {\n\t\treturn errors.New(\"glColor4ubv\")\n\t}\n\tgpColor4ui = (C.GPCOLOR4UI)(getProcAddr(\"glColor4ui\"))\n\tif gpColor4ui == nil {\n\t\treturn errors.New(\"glColor4ui\")\n\t}\n\tgpColor4uiv = (C.GPCOLOR4UIV)(getProcAddr(\"glColor4uiv\"))\n\tif gpColor4uiv == nil {\n\t\treturn errors.New(\"glColor4uiv\")\n\t}\n\tgpColor4us = (C.GPCOLOR4US)(getProcAddr(\"glColor4us\"))\n\tif gpColor4us == nil {\n\t\treturn errors.New(\"glColor4us\")\n\t}\n\tgpColor4usv = (C.GPCOLOR4USV)(getProcAddr(\"glColor4usv\"))\n\tif gpColor4usv == nil {\n\t\treturn errors.New(\"glColor4usv\")\n\t}\n\tgpColor4xOES = (C.GPCOLOR4XOES)(getProcAddr(\"glColor4xOES\"))\n\tgpColor4xvOES = (C.GPCOLOR4XVOES)(getProcAddr(\"glColor4xvOES\"))\n\tgpColorFormatNV = (C.GPCOLORFORMATNV)(getProcAddr(\"glColorFormatNV\"))\n\tgpColorFragmentOp1ATI = (C.GPCOLORFRAGMENTOP1ATI)(getProcAddr(\"glColorFragmentOp1ATI\"))\n\tgpColorFragmentOp2ATI = (C.GPCOLORFRAGMENTOP2ATI)(getProcAddr(\"glColorFragmentOp2ATI\"))\n\tgpColorFragmentOp3ATI = (C.GPCOLORFRAGMENTOP3ATI)(getProcAddr(\"glColorFragmentOp3ATI\"))\n\tgpColorMask = (C.GPCOLORMASK)(getProcAddr(\"glColorMask\"))\n\tif gpColorMask == nil {\n\t\treturn errors.New(\"glColorMask\")\n\t}\n\tgpColorMaskIndexedEXT = (C.GPCOLORMASKINDEXEDEXT)(getProcAddr(\"glColorMaskIndexedEXT\"))\n\tgpColorMaski = (C.GPCOLORMASKI)(getProcAddr(\"glColorMaski\"))\n\tif gpColorMaski == nil {\n\t\treturn errors.New(\"glColorMaski\")\n\t}\n\tgpColorMaterial = (C.GPCOLORMATERIAL)(getProcAddr(\"glColorMaterial\"))\n\tif gpColorMaterial == nil {\n\t\treturn errors.New(\"glColorMaterial\")\n\t}\n\tgpColorP3ui = (C.GPCOLORP3UI)(getProcAddr(\"glColorP3ui\"))\n\tif gpColorP3ui == nil {\n\t\treturn errors.New(\"glColorP3ui\")\n\t}\n\tgpColorP3uiv = (C.GPCOLORP3UIV)(getProcAddr(\"glColorP3uiv\"))\n\tif gpColorP3uiv == nil {\n\t\treturn errors.New(\"glColorP3uiv\")\n\t}\n\tgpColorP4ui = (C.GPCOLORP4UI)(getProcAddr(\"glColorP4ui\"))\n\tif gpColorP4ui == nil {\n\t\treturn errors.New(\"glColorP4ui\")\n\t}\n\tgpColorP4uiv = (C.GPCOLORP4UIV)(getProcAddr(\"glColorP4uiv\"))\n\tif gpColorP4uiv == nil {\n\t\treturn errors.New(\"glColorP4uiv\")\n\t}\n\tgpColorPointer = (C.GPCOLORPOINTER)(getProcAddr(\"glColorPointer\"))\n\tif gpColorPointer == nil {\n\t\treturn errors.New(\"glColorPointer\")\n\t}\n\tgpColorPointerEXT = (C.GPCOLORPOINTEREXT)(getProcAddr(\"glColorPointerEXT\"))\n\tgpColorPointerListIBM = (C.GPCOLORPOINTERLISTIBM)(getProcAddr(\"glColorPointerListIBM\"))\n\tgpColorPointervINTEL = (C.GPCOLORPOINTERVINTEL)(getProcAddr(\"glColorPointervINTEL\"))\n\tgpColorSubTable = (C.GPCOLORSUBTABLE)(getProcAddr(\"glColorSubTable\"))\n\tgpColorSubTableEXT = (C.GPCOLORSUBTABLEEXT)(getProcAddr(\"glColorSubTableEXT\"))\n\tgpColorTable = (C.GPCOLORTABLE)(getProcAddr(\"glColorTable\"))\n\tgpColorTableEXT = (C.GPCOLORTABLEEXT)(getProcAddr(\"glColorTableEXT\"))\n\tgpColorTableParameterfv = (C.GPCOLORTABLEPARAMETERFV)(getProcAddr(\"glColorTableParameterfv\"))\n\tgpColorTableParameterfvSGI = (C.GPCOLORTABLEPARAMETERFVSGI)(getProcAddr(\"glColorTableParameterfvSGI\"))\n\tgpColorTableParameteriv = (C.GPCOLORTABLEPARAMETERIV)(getProcAddr(\"glColorTableParameteriv\"))\n\tgpColorTableParameterivSGI = (C.GPCOLORTABLEPARAMETERIVSGI)(getProcAddr(\"glColorTableParameterivSGI\"))\n\tgpColorTableSGI = (C.GPCOLORTABLESGI)(getProcAddr(\"glColorTableSGI\"))\n\tgpCombinerInputNV = (C.GPCOMBINERINPUTNV)(getProcAddr(\"glCombinerInputNV\"))\n\tgpCombinerOutputNV = (C.GPCOMBINEROUTPUTNV)(getProcAddr(\"glCombinerOutputNV\"))\n\tgpCombinerParameterfNV = (C.GPCOMBINERPARAMETERFNV)(getProcAddr(\"glCombinerParameterfNV\"))\n\tgpCombinerParameterfvNV = (C.GPCOMBINERPARAMETERFVNV)(getProcAddr(\"glCombinerParameterfvNV\"))\n\tgpCombinerParameteriNV = (C.GPCOMBINERPARAMETERINV)(getProcAddr(\"glCombinerParameteriNV\"))\n\tgpCombinerParameterivNV = (C.GPCOMBINERPARAMETERIVNV)(getProcAddr(\"glCombinerParameterivNV\"))\n\tgpCombinerStageParameterfvNV = (C.GPCOMBINERSTAGEPARAMETERFVNV)(getProcAddr(\"glCombinerStageParameterfvNV\"))\n\tgpCommandListSegmentsNV = (C.GPCOMMANDLISTSEGMENTSNV)(getProcAddr(\"glCommandListSegmentsNV\"))\n\tgpCompileCommandListNV = (C.GPCOMPILECOMMANDLISTNV)(getProcAddr(\"glCompileCommandListNV\"))\n\tgpCompileShader = (C.GPCOMPILESHADER)(getProcAddr(\"glCompileShader\"))\n\tif gpCompileShader == nil {\n\t\treturn errors.New(\"glCompileShader\")\n\t}\n\tgpCompileShaderARB = (C.GPCOMPILESHADERARB)(getProcAddr(\"glCompileShaderARB\"))\n\tgpCompileShaderIncludeARB = (C.GPCOMPILESHADERINCLUDEARB)(getProcAddr(\"glCompileShaderIncludeARB\"))\n\tgpCompressedMultiTexImage1DEXT = (C.GPCOMPRESSEDMULTITEXIMAGE1DEXT)(getProcAddr(\"glCompressedMultiTexImage1DEXT\"))\n\tgpCompressedMultiTexImage2DEXT = (C.GPCOMPRESSEDMULTITEXIMAGE2DEXT)(getProcAddr(\"glCompressedMultiTexImage2DEXT\"))\n\tgpCompressedMultiTexImage3DEXT = (C.GPCOMPRESSEDMULTITEXIMAGE3DEXT)(getProcAddr(\"glCompressedMultiTexImage3DEXT\"))\n\tgpCompressedMultiTexSubImage1DEXT = (C.GPCOMPRESSEDMULTITEXSUBIMAGE1DEXT)(getProcAddr(\"glCompressedMultiTexSubImage1DEXT\"))\n\tgpCompressedMultiTexSubImage2DEXT = (C.GPCOMPRESSEDMULTITEXSUBIMAGE2DEXT)(getProcAddr(\"glCompressedMultiTexSubImage2DEXT\"))\n\tgpCompressedMultiTexSubImage3DEXT = (C.GPCOMPRESSEDMULTITEXSUBIMAGE3DEXT)(getProcAddr(\"glCompressedMultiTexSubImage3DEXT\"))\n\tgpCompressedTexImage1D = (C.GPCOMPRESSEDTEXIMAGE1D)(getProcAddr(\"glCompressedTexImage1D\"))\n\tif gpCompressedTexImage1D == nil {\n\t\treturn errors.New(\"glCompressedTexImage1D\")\n\t}\n\tgpCompressedTexImage1DARB = (C.GPCOMPRESSEDTEXIMAGE1DARB)(getProcAddr(\"glCompressedTexImage1DARB\"))\n\tgpCompressedTexImage2D = (C.GPCOMPRESSEDTEXIMAGE2D)(getProcAddr(\"glCompressedTexImage2D\"))\n\tif gpCompressedTexImage2D == nil {\n\t\treturn errors.New(\"glCompressedTexImage2D\")\n\t}\n\tgpCompressedTexImage2DARB = (C.GPCOMPRESSEDTEXIMAGE2DARB)(getProcAddr(\"glCompressedTexImage2DARB\"))\n\tgpCompressedTexImage3D = (C.GPCOMPRESSEDTEXIMAGE3D)(getProcAddr(\"glCompressedTexImage3D\"))\n\tif gpCompressedTexImage3D == nil {\n\t\treturn errors.New(\"glCompressedTexImage3D\")\n\t}\n\tgpCompressedTexImage3DARB = (C.GPCOMPRESSEDTEXIMAGE3DARB)(getProcAddr(\"glCompressedTexImage3DARB\"))\n\tgpCompressedTexSubImage1D = (C.GPCOMPRESSEDTEXSUBIMAGE1D)(getProcAddr(\"glCompressedTexSubImage1D\"))\n\tif gpCompressedTexSubImage1D == nil {\n\t\treturn errors.New(\"glCompressedTexSubImage1D\")\n\t}\n\tgpCompressedTexSubImage1DARB = (C.GPCOMPRESSEDTEXSUBIMAGE1DARB)(getProcAddr(\"glCompressedTexSubImage1DARB\"))\n\tgpCompressedTexSubImage2D = (C.GPCOMPRESSEDTEXSUBIMAGE2D)(getProcAddr(\"glCompressedTexSubImage2D\"))\n\tif gpCompressedTexSubImage2D == nil {\n\t\treturn errors.New(\"glCompressedTexSubImage2D\")\n\t}\n\tgpCompressedTexSubImage2DARB = (C.GPCOMPRESSEDTEXSUBIMAGE2DARB)(getProcAddr(\"glCompressedTexSubImage2DARB\"))\n\tgpCompressedTexSubImage3D = (C.GPCOMPRESSEDTEXSUBIMAGE3D)(getProcAddr(\"glCompressedTexSubImage3D\"))\n\tif gpCompressedTexSubImage3D == nil {\n\t\treturn errors.New(\"glCompressedTexSubImage3D\")\n\t}\n\tgpCompressedTexSubImage3DARB = (C.GPCOMPRESSEDTEXSUBIMAGE3DARB)(getProcAddr(\"glCompressedTexSubImage3DARB\"))\n\tgpCompressedTextureImage1DEXT = (C.GPCOMPRESSEDTEXTUREIMAGE1DEXT)(getProcAddr(\"glCompressedTextureImage1DEXT\"))\n\tgpCompressedTextureImage2DEXT = (C.GPCOMPRESSEDTEXTUREIMAGE2DEXT)(getProcAddr(\"glCompressedTextureImage2DEXT\"))\n\tgpCompressedTextureImage3DEXT = (C.GPCOMPRESSEDTEXTUREIMAGE3DEXT)(getProcAddr(\"glCompressedTextureImage3DEXT\"))\n\tgpCompressedTextureSubImage1D = (C.GPCOMPRESSEDTEXTURESUBIMAGE1D)(getProcAddr(\"glCompressedTextureSubImage1D\"))\n\tgpCompressedTextureSubImage1DEXT = (C.GPCOMPRESSEDTEXTURESUBIMAGE1DEXT)(getProcAddr(\"glCompressedTextureSubImage1DEXT\"))\n\tgpCompressedTextureSubImage2D = (C.GPCOMPRESSEDTEXTURESUBIMAGE2D)(getProcAddr(\"glCompressedTextureSubImage2D\"))\n\tgpCompressedTextureSubImage2DEXT = (C.GPCOMPRESSEDTEXTURESUBIMAGE2DEXT)(getProcAddr(\"glCompressedTextureSubImage2DEXT\"))\n\tgpCompressedTextureSubImage3D = (C.GPCOMPRESSEDTEXTURESUBIMAGE3D)(getProcAddr(\"glCompressedTextureSubImage3D\"))\n\tgpCompressedTextureSubImage3DEXT = (C.GPCOMPRESSEDTEXTURESUBIMAGE3DEXT)(getProcAddr(\"glCompressedTextureSubImage3DEXT\"))\n\tgpConservativeRasterParameterfNV = (C.GPCONSERVATIVERASTERPARAMETERFNV)(getProcAddr(\"glConservativeRasterParameterfNV\"))\n\tgpConservativeRasterParameteriNV = (C.GPCONSERVATIVERASTERPARAMETERINV)(getProcAddr(\"glConservativeRasterParameteriNV\"))\n\tgpConvolutionFilter1D = (C.GPCONVOLUTIONFILTER1D)(getProcAddr(\"glConvolutionFilter1D\"))\n\tgpConvolutionFilter1DEXT = (C.GPCONVOLUTIONFILTER1DEXT)(getProcAddr(\"glConvolutionFilter1DEXT\"))\n\tgpConvolutionFilter2D = (C.GPCONVOLUTIONFILTER2D)(getProcAddr(\"glConvolutionFilter2D\"))\n\tgpConvolutionFilter2DEXT = (C.GPCONVOLUTIONFILTER2DEXT)(getProcAddr(\"glConvolutionFilter2DEXT\"))\n\tgpConvolutionParameterf = (C.GPCONVOLUTIONPARAMETERF)(getProcAddr(\"glConvolutionParameterf\"))\n\tgpConvolutionParameterfEXT = (C.GPCONVOLUTIONPARAMETERFEXT)(getProcAddr(\"glConvolutionParameterfEXT\"))\n\tgpConvolutionParameterfv = (C.GPCONVOLUTIONPARAMETERFV)(getProcAddr(\"glConvolutionParameterfv\"))\n\tgpConvolutionParameterfvEXT = (C.GPCONVOLUTIONPARAMETERFVEXT)(getProcAddr(\"glConvolutionParameterfvEXT\"))\n\tgpConvolutionParameteri = (C.GPCONVOLUTIONPARAMETERI)(getProcAddr(\"glConvolutionParameteri\"))\n\tgpConvolutionParameteriEXT = (C.GPCONVOLUTIONPARAMETERIEXT)(getProcAddr(\"glConvolutionParameteriEXT\"))\n\tgpConvolutionParameteriv = (C.GPCONVOLUTIONPARAMETERIV)(getProcAddr(\"glConvolutionParameteriv\"))\n\tgpConvolutionParameterivEXT = (C.GPCONVOLUTIONPARAMETERIVEXT)(getProcAddr(\"glConvolutionParameterivEXT\"))\n\tgpConvolutionParameterxOES = (C.GPCONVOLUTIONPARAMETERXOES)(getProcAddr(\"glConvolutionParameterxOES\"))\n\tgpConvolutionParameterxvOES = (C.GPCONVOLUTIONPARAMETERXVOES)(getProcAddr(\"glConvolutionParameterxvOES\"))\n\tgpCopyBufferSubData = (C.GPCOPYBUFFERSUBDATA)(getProcAddr(\"glCopyBufferSubData\"))\n\tif gpCopyBufferSubData == nil {\n\t\treturn errors.New(\"glCopyBufferSubData\")\n\t}\n\tgpCopyColorSubTable = (C.GPCOPYCOLORSUBTABLE)(getProcAddr(\"glCopyColorSubTable\"))\n\tgpCopyColorSubTableEXT = (C.GPCOPYCOLORSUBTABLEEXT)(getProcAddr(\"glCopyColorSubTableEXT\"))\n\tgpCopyColorTable = (C.GPCOPYCOLORTABLE)(getProcAddr(\"glCopyColorTable\"))\n\tgpCopyColorTableSGI = (C.GPCOPYCOLORTABLESGI)(getProcAddr(\"glCopyColorTableSGI\"))\n\tgpCopyConvolutionFilter1D = (C.GPCOPYCONVOLUTIONFILTER1D)(getProcAddr(\"glCopyConvolutionFilter1D\"))\n\tgpCopyConvolutionFilter1DEXT = (C.GPCOPYCONVOLUTIONFILTER1DEXT)(getProcAddr(\"glCopyConvolutionFilter1DEXT\"))\n\tgpCopyConvolutionFilter2D = (C.GPCOPYCONVOLUTIONFILTER2D)(getProcAddr(\"glCopyConvolutionFilter2D\"))\n\tgpCopyConvolutionFilter2DEXT = (C.GPCOPYCONVOLUTIONFILTER2DEXT)(getProcAddr(\"glCopyConvolutionFilter2DEXT\"))\n\tgpCopyImageSubData = (C.GPCOPYIMAGESUBDATA)(getProcAddr(\"glCopyImageSubData\"))\n\tif gpCopyImageSubData == nil {\n\t\treturn errors.New(\"glCopyImageSubData\")\n\t}\n\tgpCopyImageSubDataNV = (C.GPCOPYIMAGESUBDATANV)(getProcAddr(\"glCopyImageSubDataNV\"))\n\tgpCopyMultiTexImage1DEXT = (C.GPCOPYMULTITEXIMAGE1DEXT)(getProcAddr(\"glCopyMultiTexImage1DEXT\"))\n\tgpCopyMultiTexImage2DEXT = (C.GPCOPYMULTITEXIMAGE2DEXT)(getProcAddr(\"glCopyMultiTexImage2DEXT\"))\n\tgpCopyMultiTexSubImage1DEXT = (C.GPCOPYMULTITEXSUBIMAGE1DEXT)(getProcAddr(\"glCopyMultiTexSubImage1DEXT\"))\n\tgpCopyMultiTexSubImage2DEXT = (C.GPCOPYMULTITEXSUBIMAGE2DEXT)(getProcAddr(\"glCopyMultiTexSubImage2DEXT\"))\n\tgpCopyMultiTexSubImage3DEXT = (C.GPCOPYMULTITEXSUBIMAGE3DEXT)(getProcAddr(\"glCopyMultiTexSubImage3DEXT\"))\n\tgpCopyNamedBufferSubData = (C.GPCOPYNAMEDBUFFERSUBDATA)(getProcAddr(\"glCopyNamedBufferSubData\"))\n\tgpCopyPathNV = (C.GPCOPYPATHNV)(getProcAddr(\"glCopyPathNV\"))\n\tgpCopyPixels = (C.GPCOPYPIXELS)(getProcAddr(\"glCopyPixels\"))\n\tif gpCopyPixels == nil {\n\t\treturn errors.New(\"glCopyPixels\")\n\t}\n\tgpCopyTexImage1D = (C.GPCOPYTEXIMAGE1D)(getProcAddr(\"glCopyTexImage1D\"))\n\tif gpCopyTexImage1D == nil {\n\t\treturn errors.New(\"glCopyTexImage1D\")\n\t}\n\tgpCopyTexImage1DEXT = (C.GPCOPYTEXIMAGE1DEXT)(getProcAddr(\"glCopyTexImage1DEXT\"))\n\tgpCopyTexImage2D = (C.GPCOPYTEXIMAGE2D)(getProcAddr(\"glCopyTexImage2D\"))\n\tif gpCopyTexImage2D == nil {\n\t\treturn errors.New(\"glCopyTexImage2D\")\n\t}\n\tgpCopyTexImage2DEXT = (C.GPCOPYTEXIMAGE2DEXT)(getProcAddr(\"glCopyTexImage2DEXT\"))\n\tgpCopyTexSubImage1D = (C.GPCOPYTEXSUBIMAGE1D)(getProcAddr(\"glCopyTexSubImage1D\"))\n\tif gpCopyTexSubImage1D == nil {\n\t\treturn errors.New(\"glCopyTexSubImage1D\")\n\t}\n\tgpCopyTexSubImage1DEXT = (C.GPCOPYTEXSUBIMAGE1DEXT)(getProcAddr(\"glCopyTexSubImage1DEXT\"))\n\tgpCopyTexSubImage2D = (C.GPCOPYTEXSUBIMAGE2D)(getProcAddr(\"glCopyTexSubImage2D\"))\n\tif gpCopyTexSubImage2D == nil {\n\t\treturn errors.New(\"glCopyTexSubImage2D\")\n\t}\n\tgpCopyTexSubImage2DEXT = (C.GPCOPYTEXSUBIMAGE2DEXT)(getProcAddr(\"glCopyTexSubImage2DEXT\"))\n\tgpCopyTexSubImage3D = (C.GPCOPYTEXSUBIMAGE3D)(getProcAddr(\"glCopyTexSubImage3D\"))\n\tif gpCopyTexSubImage3D == nil {\n\t\treturn errors.New(\"glCopyTexSubImage3D\")\n\t}\n\tgpCopyTexSubImage3DEXT = (C.GPCOPYTEXSUBIMAGE3DEXT)(getProcAddr(\"glCopyTexSubImage3DEXT\"))\n\tgpCopyTextureImage1DEXT = (C.GPCOPYTEXTUREIMAGE1DEXT)(getProcAddr(\"glCopyTextureImage1DEXT\"))\n\tgpCopyTextureImage2DEXT = (C.GPCOPYTEXTUREIMAGE2DEXT)(getProcAddr(\"glCopyTextureImage2DEXT\"))\n\tgpCopyTextureSubImage1D = (C.GPCOPYTEXTURESUBIMAGE1D)(getProcAddr(\"glCopyTextureSubImage1D\"))\n\tgpCopyTextureSubImage1DEXT = (C.GPCOPYTEXTURESUBIMAGE1DEXT)(getProcAddr(\"glCopyTextureSubImage1DEXT\"))\n\tgpCopyTextureSubImage2D = (C.GPCOPYTEXTURESUBIMAGE2D)(getProcAddr(\"glCopyTextureSubImage2D\"))\n\tgpCopyTextureSubImage2DEXT = (C.GPCOPYTEXTURESUBIMAGE2DEXT)(getProcAddr(\"glCopyTextureSubImage2DEXT\"))\n\tgpCopyTextureSubImage3D = (C.GPCOPYTEXTURESUBIMAGE3D)(getProcAddr(\"glCopyTextureSubImage3D\"))\n\tgpCopyTextureSubImage3DEXT = (C.GPCOPYTEXTURESUBIMAGE3DEXT)(getProcAddr(\"glCopyTextureSubImage3DEXT\"))\n\tgpCoverFillPathInstancedNV = (C.GPCOVERFILLPATHINSTANCEDNV)(getProcAddr(\"glCoverFillPathInstancedNV\"))\n\tgpCoverFillPathNV = (C.GPCOVERFILLPATHNV)(getProcAddr(\"glCoverFillPathNV\"))\n\tgpCoverStrokePathInstancedNV = (C.GPCOVERSTROKEPATHINSTANCEDNV)(getProcAddr(\"glCoverStrokePathInstancedNV\"))\n\tgpCoverStrokePathNV = (C.GPCOVERSTROKEPATHNV)(getProcAddr(\"glCoverStrokePathNV\"))\n\tgpCoverageModulationNV = (C.GPCOVERAGEMODULATIONNV)(getProcAddr(\"glCoverageModulationNV\"))\n\tgpCoverageModulationTableNV = (C.GPCOVERAGEMODULATIONTABLENV)(getProcAddr(\"glCoverageModulationTableNV\"))\n\tgpCreateBuffers = (C.GPCREATEBUFFERS)(getProcAddr(\"glCreateBuffers\"))\n\tgpCreateCommandListsNV = (C.GPCREATECOMMANDLISTSNV)(getProcAddr(\"glCreateCommandListsNV\"))\n\tgpCreateFramebuffers = (C.GPCREATEFRAMEBUFFERS)(getProcAddr(\"glCreateFramebuffers\"))\n\tgpCreateMemoryObjectsEXT = (C.GPCREATEMEMORYOBJECTSEXT)(getProcAddr(\"glCreateMemoryObjectsEXT\"))\n\tgpCreatePerfQueryINTEL = (C.GPCREATEPERFQUERYINTEL)(getProcAddr(\"glCreatePerfQueryINTEL\"))\n\tgpCreateProgram = (C.GPCREATEPROGRAM)(getProcAddr(\"glCreateProgram\"))\n\tif gpCreateProgram == nil {\n\t\treturn errors.New(\"glCreateProgram\")\n\t}\n\tgpCreateProgramObjectARB = (C.GPCREATEPROGRAMOBJECTARB)(getProcAddr(\"glCreateProgramObjectARB\"))\n\tgpCreateProgramPipelines = (C.GPCREATEPROGRAMPIPELINES)(getProcAddr(\"glCreateProgramPipelines\"))\n\tgpCreateProgressFenceNVX = (C.GPCREATEPROGRESSFENCENVX)(getProcAddr(\"glCreateProgressFenceNVX\"))\n\tgpCreateQueries = (C.GPCREATEQUERIES)(getProcAddr(\"glCreateQueries\"))\n\tgpCreateRenderbuffers = (C.GPCREATERENDERBUFFERS)(getProcAddr(\"glCreateRenderbuffers\"))\n\tgpCreateSamplers = (C.GPCREATESAMPLERS)(getProcAddr(\"glCreateSamplers\"))\n\tgpCreateSemaphoresNV = (C.GPCREATESEMAPHORESNV)(getProcAddr(\"glCreateSemaphoresNV\"))\n\tgpCreateShader = (C.GPCREATESHADER)(getProcAddr(\"glCreateShader\"))\n\tif gpCreateShader == nil {\n\t\treturn errors.New(\"glCreateShader\")\n\t}\n\tgpCreateShaderObjectARB = (C.GPCREATESHADEROBJECTARB)(getProcAddr(\"glCreateShaderObjectARB\"))\n\tgpCreateShaderProgramEXT = (C.GPCREATESHADERPROGRAMEXT)(getProcAddr(\"glCreateShaderProgramEXT\"))\n\tgpCreateShaderProgramv = (C.GPCREATESHADERPROGRAMV)(getProcAddr(\"glCreateShaderProgramv\"))\n\tif gpCreateShaderProgramv == nil {\n\t\treturn errors.New(\"glCreateShaderProgramv\")\n\t}\n\tgpCreateShaderProgramvEXT = (C.GPCREATESHADERPROGRAMVEXT)(getProcAddr(\"glCreateShaderProgramvEXT\"))\n\tgpCreateStatesNV = (C.GPCREATESTATESNV)(getProcAddr(\"glCreateStatesNV\"))\n\tgpCreateSyncFromCLeventARB = (C.GPCREATESYNCFROMCLEVENTARB)(getProcAddr(\"glCreateSyncFromCLeventARB\"))\n\tgpCreateTextures = (C.GPCREATETEXTURES)(getProcAddr(\"glCreateTextures\"))\n\tgpCreateTransformFeedbacks = (C.GPCREATETRANSFORMFEEDBACKS)(getProcAddr(\"glCreateTransformFeedbacks\"))\n\tgpCreateVertexArrays = (C.GPCREATEVERTEXARRAYS)(getProcAddr(\"glCreateVertexArrays\"))\n\tgpCullFace = (C.GPCULLFACE)(getProcAddr(\"glCullFace\"))\n\tif gpCullFace == nil {\n\t\treturn errors.New(\"glCullFace\")\n\t}\n\tgpCullParameterdvEXT = (C.GPCULLPARAMETERDVEXT)(getProcAddr(\"glCullParameterdvEXT\"))\n\tgpCullParameterfvEXT = (C.GPCULLPARAMETERFVEXT)(getProcAddr(\"glCullParameterfvEXT\"))\n\tgpCurrentPaletteMatrixARB = (C.GPCURRENTPALETTEMATRIXARB)(getProcAddr(\"glCurrentPaletteMatrixARB\"))\n\tgpDebugMessageCallback = (C.GPDEBUGMESSAGECALLBACK)(getProcAddr(\"glDebugMessageCallback\"))\n\tif gpDebugMessageCallback == nil {\n\t\treturn errors.New(\"glDebugMessageCallback\")\n\t}\n\tgpDebugMessageCallbackAMD = (C.GPDEBUGMESSAGECALLBACKAMD)(getProcAddr(\"glDebugMessageCallbackAMD\"))\n\tgpDebugMessageCallbackARB = (C.GPDEBUGMESSAGECALLBACKARB)(getProcAddr(\"glDebugMessageCallbackARB\"))\n\tgpDebugMessageCallbackKHR = (C.GPDEBUGMESSAGECALLBACKKHR)(getProcAddr(\"glDebugMessageCallbackKHR\"))\n\tgpDebugMessageControl = (C.GPDEBUGMESSAGECONTROL)(getProcAddr(\"glDebugMessageControl\"))\n\tif gpDebugMessageControl == nil {\n\t\treturn errors.New(\"glDebugMessageControl\")\n\t}\n\tgpDebugMessageControlARB = (C.GPDEBUGMESSAGECONTROLARB)(getProcAddr(\"glDebugMessageControlARB\"))\n\tgpDebugMessageControlKHR = (C.GPDEBUGMESSAGECONTROLKHR)(getProcAddr(\"glDebugMessageControlKHR\"))\n\tgpDebugMessageEnableAMD = (C.GPDEBUGMESSAGEENABLEAMD)(getProcAddr(\"glDebugMessageEnableAMD\"))\n\tgpDebugMessageInsert = (C.GPDEBUGMESSAGEINSERT)(getProcAddr(\"glDebugMessageInsert\"))\n\tif gpDebugMessageInsert == nil {\n\t\treturn errors.New(\"glDebugMessageInsert\")\n\t}\n\tgpDebugMessageInsertAMD = (C.GPDEBUGMESSAGEINSERTAMD)(getProcAddr(\"glDebugMessageInsertAMD\"))\n\tgpDebugMessageInsertARB = (C.GPDEBUGMESSAGEINSERTARB)(getProcAddr(\"glDebugMessageInsertARB\"))\n\tgpDebugMessageInsertKHR = (C.GPDEBUGMESSAGEINSERTKHR)(getProcAddr(\"glDebugMessageInsertKHR\"))\n\tgpDeformSGIX = (C.GPDEFORMSGIX)(getProcAddr(\"glDeformSGIX\"))\n\tgpDeformationMap3dSGIX = (C.GPDEFORMATIONMAP3DSGIX)(getProcAddr(\"glDeformationMap3dSGIX\"))\n\tgpDeformationMap3fSGIX = (C.GPDEFORMATIONMAP3FSGIX)(getProcAddr(\"glDeformationMap3fSGIX\"))\n\tgpDeleteAsyncMarkersSGIX = (C.GPDELETEASYNCMARKERSSGIX)(getProcAddr(\"glDeleteAsyncMarkersSGIX\"))\n\tgpDeleteBuffers = (C.GPDELETEBUFFERS)(getProcAddr(\"glDeleteBuffers\"))\n\tif gpDeleteBuffers == nil {\n\t\treturn errors.New(\"glDeleteBuffers\")\n\t}\n\tgpDeleteBuffersARB = (C.GPDELETEBUFFERSARB)(getProcAddr(\"glDeleteBuffersARB\"))\n\tgpDeleteCommandListsNV = (C.GPDELETECOMMANDLISTSNV)(getProcAddr(\"glDeleteCommandListsNV\"))\n\tgpDeleteFencesAPPLE = (C.GPDELETEFENCESAPPLE)(getProcAddr(\"glDeleteFencesAPPLE\"))\n\tgpDeleteFencesNV = (C.GPDELETEFENCESNV)(getProcAddr(\"glDeleteFencesNV\"))\n\tgpDeleteFragmentShaderATI = (C.GPDELETEFRAGMENTSHADERATI)(getProcAddr(\"glDeleteFragmentShaderATI\"))\n\tgpDeleteFramebuffers = (C.GPDELETEFRAMEBUFFERS)(getProcAddr(\"glDeleteFramebuffers\"))\n\tif gpDeleteFramebuffers == nil {\n\t\treturn errors.New(\"glDeleteFramebuffers\")\n\t}\n\tgpDeleteFramebuffersEXT = (C.GPDELETEFRAMEBUFFERSEXT)(getProcAddr(\"glDeleteFramebuffersEXT\"))\n\tgpDeleteLists = (C.GPDELETELISTS)(getProcAddr(\"glDeleteLists\"))\n\tif gpDeleteLists == nil {\n\t\treturn errors.New(\"glDeleteLists\")\n\t}\n\tgpDeleteMemoryObjectsEXT = (C.GPDELETEMEMORYOBJECTSEXT)(getProcAddr(\"glDeleteMemoryObjectsEXT\"))\n\tgpDeleteNamedStringARB = (C.GPDELETENAMEDSTRINGARB)(getProcAddr(\"glDeleteNamedStringARB\"))\n\tgpDeleteNamesAMD = (C.GPDELETENAMESAMD)(getProcAddr(\"glDeleteNamesAMD\"))\n\tgpDeleteObjectARB = (C.GPDELETEOBJECTARB)(getProcAddr(\"glDeleteObjectARB\"))\n\tgpDeleteOcclusionQueriesNV = (C.GPDELETEOCCLUSIONQUERIESNV)(getProcAddr(\"glDeleteOcclusionQueriesNV\"))\n\tgpDeletePathsNV = (C.GPDELETEPATHSNV)(getProcAddr(\"glDeletePathsNV\"))\n\tgpDeletePerfMonitorsAMD = (C.GPDELETEPERFMONITORSAMD)(getProcAddr(\"glDeletePerfMonitorsAMD\"))\n\tgpDeletePerfQueryINTEL = (C.GPDELETEPERFQUERYINTEL)(getProcAddr(\"glDeletePerfQueryINTEL\"))\n\tgpDeleteProgram = (C.GPDELETEPROGRAM)(getProcAddr(\"glDeleteProgram\"))\n\tif gpDeleteProgram == nil {\n\t\treturn errors.New(\"glDeleteProgram\")\n\t}\n\tgpDeleteProgramPipelines = (C.GPDELETEPROGRAMPIPELINES)(getProcAddr(\"glDeleteProgramPipelines\"))\n\tif gpDeleteProgramPipelines == nil {\n\t\treturn errors.New(\"glDeleteProgramPipelines\")\n\t}\n\tgpDeleteProgramPipelinesEXT = (C.GPDELETEPROGRAMPIPELINESEXT)(getProcAddr(\"glDeleteProgramPipelinesEXT\"))\n\tgpDeleteProgramsARB = (C.GPDELETEPROGRAMSARB)(getProcAddr(\"glDeleteProgramsARB\"))\n\tgpDeleteProgramsNV = (C.GPDELETEPROGRAMSNV)(getProcAddr(\"glDeleteProgramsNV\"))\n\tgpDeleteQueries = (C.GPDELETEQUERIES)(getProcAddr(\"glDeleteQueries\"))\n\tif gpDeleteQueries == nil {\n\t\treturn errors.New(\"glDeleteQueries\")\n\t}\n\tgpDeleteQueriesARB = (C.GPDELETEQUERIESARB)(getProcAddr(\"glDeleteQueriesARB\"))\n\tgpDeleteQueryResourceTagNV = (C.GPDELETEQUERYRESOURCETAGNV)(getProcAddr(\"glDeleteQueryResourceTagNV\"))\n\tgpDeleteRenderbuffers = (C.GPDELETERENDERBUFFERS)(getProcAddr(\"glDeleteRenderbuffers\"))\n\tif gpDeleteRenderbuffers == nil {\n\t\treturn errors.New(\"glDeleteRenderbuffers\")\n\t}\n\tgpDeleteRenderbuffersEXT = (C.GPDELETERENDERBUFFERSEXT)(getProcAddr(\"glDeleteRenderbuffersEXT\"))\n\tgpDeleteSamplers = (C.GPDELETESAMPLERS)(getProcAddr(\"glDeleteSamplers\"))\n\tif gpDeleteSamplers == nil {\n\t\treturn errors.New(\"glDeleteSamplers\")\n\t}\n\tgpDeleteSemaphoresEXT = (C.GPDELETESEMAPHORESEXT)(getProcAddr(\"glDeleteSemaphoresEXT\"))\n\tgpDeleteShader = (C.GPDELETESHADER)(getProcAddr(\"glDeleteShader\"))\n\tif gpDeleteShader == nil {\n\t\treturn errors.New(\"glDeleteShader\")\n\t}\n\tgpDeleteStatesNV = (C.GPDELETESTATESNV)(getProcAddr(\"glDeleteStatesNV\"))\n\tgpDeleteSync = (C.GPDELETESYNC)(getProcAddr(\"glDeleteSync\"))\n\tif gpDeleteSync == nil {\n\t\treturn errors.New(\"glDeleteSync\")\n\t}\n\tgpDeleteTextures = (C.GPDELETETEXTURES)(getProcAddr(\"glDeleteTextures\"))\n\tif gpDeleteTextures == nil {\n\t\treturn errors.New(\"glDeleteTextures\")\n\t}\n\tgpDeleteTexturesEXT = (C.GPDELETETEXTURESEXT)(getProcAddr(\"glDeleteTexturesEXT\"))\n\tgpDeleteTransformFeedbacks = (C.GPDELETETRANSFORMFEEDBACKS)(getProcAddr(\"glDeleteTransformFeedbacks\"))\n\tif gpDeleteTransformFeedbacks == nil {\n\t\treturn errors.New(\"glDeleteTransformFeedbacks\")\n\t}\n\tgpDeleteTransformFeedbacksNV = (C.GPDELETETRANSFORMFEEDBACKSNV)(getProcAddr(\"glDeleteTransformFeedbacksNV\"))\n\tgpDeleteVertexArrays = (C.GPDELETEVERTEXARRAYS)(getProcAddr(\"glDeleteVertexArrays\"))\n\tif gpDeleteVertexArrays == nil {\n\t\treturn errors.New(\"glDeleteVertexArrays\")\n\t}\n\tgpDeleteVertexArraysAPPLE = (C.GPDELETEVERTEXARRAYSAPPLE)(getProcAddr(\"glDeleteVertexArraysAPPLE\"))\n\tgpDeleteVertexShaderEXT = (C.GPDELETEVERTEXSHADEREXT)(getProcAddr(\"glDeleteVertexShaderEXT\"))\n\tgpDepthBoundsEXT = (C.GPDEPTHBOUNDSEXT)(getProcAddr(\"glDepthBoundsEXT\"))\n\tgpDepthBoundsdNV = (C.GPDEPTHBOUNDSDNV)(getProcAddr(\"glDepthBoundsdNV\"))\n\tgpDepthFunc = (C.GPDEPTHFUNC)(getProcAddr(\"glDepthFunc\"))\n\tif gpDepthFunc == nil {\n\t\treturn errors.New(\"glDepthFunc\")\n\t}\n\tgpDepthMask = (C.GPDEPTHMASK)(getProcAddr(\"glDepthMask\"))\n\tif gpDepthMask == nil {\n\t\treturn errors.New(\"glDepthMask\")\n\t}\n\tgpDepthRange = (C.GPDEPTHRANGE)(getProcAddr(\"glDepthRange\"))\n\tif gpDepthRange == nil {\n\t\treturn errors.New(\"glDepthRange\")\n\t}\n\tgpDepthRangeArraydvNV = (C.GPDEPTHRANGEARRAYDVNV)(getProcAddr(\"glDepthRangeArraydvNV\"))\n\tgpDepthRangeArrayv = (C.GPDEPTHRANGEARRAYV)(getProcAddr(\"glDepthRangeArrayv\"))\n\tif gpDepthRangeArrayv == nil {\n\t\treturn errors.New(\"glDepthRangeArrayv\")\n\t}\n\tgpDepthRangeIndexed = (C.GPDEPTHRANGEINDEXED)(getProcAddr(\"glDepthRangeIndexed\"))\n\tif gpDepthRangeIndexed == nil {\n\t\treturn errors.New(\"glDepthRangeIndexed\")\n\t}\n\tgpDepthRangeIndexeddNV = (C.GPDEPTHRANGEINDEXEDDNV)(getProcAddr(\"glDepthRangeIndexeddNV\"))\n\tgpDepthRangedNV = (C.GPDEPTHRANGEDNV)(getProcAddr(\"glDepthRangedNV\"))\n\tgpDepthRangef = (C.GPDEPTHRANGEF)(getProcAddr(\"glDepthRangef\"))\n\tif gpDepthRangef == nil {\n\t\treturn errors.New(\"glDepthRangef\")\n\t}\n\tgpDepthRangefOES = (C.GPDEPTHRANGEFOES)(getProcAddr(\"glDepthRangefOES\"))\n\tgpDepthRangexOES = (C.GPDEPTHRANGEXOES)(getProcAddr(\"glDepthRangexOES\"))\n\tgpDetachObjectARB = (C.GPDETACHOBJECTARB)(getProcAddr(\"glDetachObjectARB\"))\n\tgpDetachShader = (C.GPDETACHSHADER)(getProcAddr(\"glDetachShader\"))\n\tif gpDetachShader == nil {\n\t\treturn errors.New(\"glDetachShader\")\n\t}\n\tgpDetailTexFuncSGIS = (C.GPDETAILTEXFUNCSGIS)(getProcAddr(\"glDetailTexFuncSGIS\"))\n\tgpDisable = (C.GPDISABLE)(getProcAddr(\"glDisable\"))\n\tif gpDisable == nil {\n\t\treturn errors.New(\"glDisable\")\n\t}\n\tgpDisableClientState = (C.GPDISABLECLIENTSTATE)(getProcAddr(\"glDisableClientState\"))\n\tif gpDisableClientState == nil {\n\t\treturn errors.New(\"glDisableClientState\")\n\t}\n\tgpDisableClientStateIndexedEXT = (C.GPDISABLECLIENTSTATEINDEXEDEXT)(getProcAddr(\"glDisableClientStateIndexedEXT\"))\n\tgpDisableClientStateiEXT = (C.GPDISABLECLIENTSTATEIEXT)(getProcAddr(\"glDisableClientStateiEXT\"))\n\tgpDisableIndexedEXT = (C.GPDISABLEINDEXEDEXT)(getProcAddr(\"glDisableIndexedEXT\"))\n\tgpDisableVariantClientStateEXT = (C.GPDISABLEVARIANTCLIENTSTATEEXT)(getProcAddr(\"glDisableVariantClientStateEXT\"))\n\tgpDisableVertexArrayAttrib = (C.GPDISABLEVERTEXARRAYATTRIB)(getProcAddr(\"glDisableVertexArrayAttrib\"))\n\tgpDisableVertexArrayAttribEXT = (C.GPDISABLEVERTEXARRAYATTRIBEXT)(getProcAddr(\"glDisableVertexArrayAttribEXT\"))\n\tgpDisableVertexArrayEXT = (C.GPDISABLEVERTEXARRAYEXT)(getProcAddr(\"glDisableVertexArrayEXT\"))\n\tgpDisableVertexAttribAPPLE = (C.GPDISABLEVERTEXATTRIBAPPLE)(getProcAddr(\"glDisableVertexAttribAPPLE\"))\n\tgpDisableVertexAttribArray = (C.GPDISABLEVERTEXATTRIBARRAY)(getProcAddr(\"glDisableVertexAttribArray\"))\n\tif gpDisableVertexAttribArray == nil {\n\t\treturn errors.New(\"glDisableVertexAttribArray\")\n\t}\n\tgpDisableVertexAttribArrayARB = (C.GPDISABLEVERTEXATTRIBARRAYARB)(getProcAddr(\"glDisableVertexAttribArrayARB\"))\n\tgpDisablei = (C.GPDISABLEI)(getProcAddr(\"glDisablei\"))\n\tif gpDisablei == nil {\n\t\treturn errors.New(\"glDisablei\")\n\t}\n\tgpDispatchCompute = (C.GPDISPATCHCOMPUTE)(getProcAddr(\"glDispatchCompute\"))\n\tif gpDispatchCompute == nil {\n\t\treturn errors.New(\"glDispatchCompute\")\n\t}\n\tgpDispatchComputeGroupSizeARB = (C.GPDISPATCHCOMPUTEGROUPSIZEARB)(getProcAddr(\"glDispatchComputeGroupSizeARB\"))\n\tgpDispatchComputeIndirect = (C.GPDISPATCHCOMPUTEINDIRECT)(getProcAddr(\"glDispatchComputeIndirect\"))\n\tif gpDispatchComputeIndirect == nil {\n\t\treturn errors.New(\"glDispatchComputeIndirect\")\n\t}\n\tgpDrawArrays = (C.GPDRAWARRAYS)(getProcAddr(\"glDrawArrays\"))\n\tif gpDrawArrays == nil {\n\t\treturn errors.New(\"glDrawArrays\")\n\t}\n\tgpDrawArraysEXT = (C.GPDRAWARRAYSEXT)(getProcAddr(\"glDrawArraysEXT\"))\n\tgpDrawArraysIndirect = (C.GPDRAWARRAYSINDIRECT)(getProcAddr(\"glDrawArraysIndirect\"))\n\tif gpDrawArraysIndirect == nil {\n\t\treturn errors.New(\"glDrawArraysIndirect\")\n\t}\n\tgpDrawArraysInstanced = (C.GPDRAWARRAYSINSTANCED)(getProcAddr(\"glDrawArraysInstanced\"))\n\tif gpDrawArraysInstanced == nil {\n\t\treturn errors.New(\"glDrawArraysInstanced\")\n\t}\n\tgpDrawArraysInstancedARB = (C.GPDRAWARRAYSINSTANCEDARB)(getProcAddr(\"glDrawArraysInstancedARB\"))\n\tgpDrawArraysInstancedBaseInstance = (C.GPDRAWARRAYSINSTANCEDBASEINSTANCE)(getProcAddr(\"glDrawArraysInstancedBaseInstance\"))\n\tif gpDrawArraysInstancedBaseInstance == nil {\n\t\treturn errors.New(\"glDrawArraysInstancedBaseInstance\")\n\t}\n\tgpDrawArraysInstancedEXT = (C.GPDRAWARRAYSINSTANCEDEXT)(getProcAddr(\"glDrawArraysInstancedEXT\"))\n\tgpDrawBuffer = (C.GPDRAWBUFFER)(getProcAddr(\"glDrawBuffer\"))\n\tif gpDrawBuffer == nil {\n\t\treturn errors.New(\"glDrawBuffer\")\n\t}\n\tgpDrawBuffers = (C.GPDRAWBUFFERS)(getProcAddr(\"glDrawBuffers\"))\n\tif gpDrawBuffers == nil {\n\t\treturn errors.New(\"glDrawBuffers\")\n\t}\n\tgpDrawBuffersARB = (C.GPDRAWBUFFERSARB)(getProcAddr(\"glDrawBuffersARB\"))\n\tgpDrawBuffersATI = (C.GPDRAWBUFFERSATI)(getProcAddr(\"glDrawBuffersATI\"))\n\tgpDrawCommandsAddressNV = (C.GPDRAWCOMMANDSADDRESSNV)(getProcAddr(\"glDrawCommandsAddressNV\"))\n\tgpDrawCommandsNV = (C.GPDRAWCOMMANDSNV)(getProcAddr(\"glDrawCommandsNV\"))\n\tgpDrawCommandsStatesAddressNV = (C.GPDRAWCOMMANDSSTATESADDRESSNV)(getProcAddr(\"glDrawCommandsStatesAddressNV\"))\n\tgpDrawCommandsStatesNV = (C.GPDRAWCOMMANDSSTATESNV)(getProcAddr(\"glDrawCommandsStatesNV\"))\n\tgpDrawElementArrayAPPLE = (C.GPDRAWELEMENTARRAYAPPLE)(getProcAddr(\"glDrawElementArrayAPPLE\"))\n\tgpDrawElementArrayATI = (C.GPDRAWELEMENTARRAYATI)(getProcAddr(\"glDrawElementArrayATI\"))\n\tgpDrawElements = (C.GPDRAWELEMENTS)(getProcAddr(\"glDrawElements\"))\n\tif gpDrawElements == nil {\n\t\treturn errors.New(\"glDrawElements\")\n\t}\n\tgpDrawElementsBaseVertex = (C.GPDRAWELEMENTSBASEVERTEX)(getProcAddr(\"glDrawElementsBaseVertex\"))\n\tif gpDrawElementsBaseVertex == nil {\n\t\treturn errors.New(\"glDrawElementsBaseVertex\")\n\t}\n\tgpDrawElementsIndirect = (C.GPDRAWELEMENTSINDIRECT)(getProcAddr(\"glDrawElementsIndirect\"))\n\tif gpDrawElementsIndirect == nil {\n\t\treturn errors.New(\"glDrawElementsIndirect\")\n\t}\n\tgpDrawElementsInstanced = (C.GPDRAWELEMENTSINSTANCED)(getProcAddr(\"glDrawElementsInstanced\"))\n\tif gpDrawElementsInstanced == nil {\n\t\treturn errors.New(\"glDrawElementsInstanced\")\n\t}\n\tgpDrawElementsInstancedARB = (C.GPDRAWELEMENTSINSTANCEDARB)(getProcAddr(\"glDrawElementsInstancedARB\"))\n\tgpDrawElementsInstancedBaseInstance = (C.GPDRAWELEMENTSINSTANCEDBASEINSTANCE)(getProcAddr(\"glDrawElementsInstancedBaseInstance\"))\n\tif gpDrawElementsInstancedBaseInstance == nil {\n\t\treturn errors.New(\"glDrawElementsInstancedBaseInstance\")\n\t}\n\tgpDrawElementsInstancedBaseVertex = (C.GPDRAWELEMENTSINSTANCEDBASEVERTEX)(getProcAddr(\"glDrawElementsInstancedBaseVertex\"))\n\tif gpDrawElementsInstancedBaseVertex == nil {\n\t\treturn errors.New(\"glDrawElementsInstancedBaseVertex\")\n\t}\n\tgpDrawElementsInstancedBaseVertexBaseInstance = (C.GPDRAWELEMENTSINSTANCEDBASEVERTEXBASEINSTANCE)(getProcAddr(\"glDrawElementsInstancedBaseVertexBaseInstance\"))\n\tif gpDrawElementsInstancedBaseVertexBaseInstance == nil {\n\t\treturn errors.New(\"glDrawElementsInstancedBaseVertexBaseInstance\")\n\t}\n\tgpDrawElementsInstancedEXT = (C.GPDRAWELEMENTSINSTANCEDEXT)(getProcAddr(\"glDrawElementsInstancedEXT\"))\n\tgpDrawMeshArraysSUN = (C.GPDRAWMESHARRAYSSUN)(getProcAddr(\"glDrawMeshArraysSUN\"))\n\tgpDrawMeshTasksIndirectNV = (C.GPDRAWMESHTASKSINDIRECTNV)(getProcAddr(\"glDrawMeshTasksIndirectNV\"))\n\tgpDrawMeshTasksNV = (C.GPDRAWMESHTASKSNV)(getProcAddr(\"glDrawMeshTasksNV\"))\n\tgpDrawPixels = (C.GPDRAWPIXELS)(getProcAddr(\"glDrawPixels\"))\n\tif gpDrawPixels == nil {\n\t\treturn errors.New(\"glDrawPixels\")\n\t}\n\tgpDrawRangeElementArrayAPPLE = (C.GPDRAWRANGEELEMENTARRAYAPPLE)(getProcAddr(\"glDrawRangeElementArrayAPPLE\"))\n\tgpDrawRangeElementArrayATI = (C.GPDRAWRANGEELEMENTARRAYATI)(getProcAddr(\"glDrawRangeElementArrayATI\"))\n\tgpDrawRangeElements = (C.GPDRAWRANGEELEMENTS)(getProcAddr(\"glDrawRangeElements\"))\n\tif gpDrawRangeElements == nil {\n\t\treturn errors.New(\"glDrawRangeElements\")\n\t}\n\tgpDrawRangeElementsBaseVertex = (C.GPDRAWRANGEELEMENTSBASEVERTEX)(getProcAddr(\"glDrawRangeElementsBaseVertex\"))\n\tif gpDrawRangeElementsBaseVertex == nil {\n\t\treturn errors.New(\"glDrawRangeElementsBaseVertex\")\n\t}\n\tgpDrawRangeElementsEXT = (C.GPDRAWRANGEELEMENTSEXT)(getProcAddr(\"glDrawRangeElementsEXT\"))\n\tgpDrawTextureNV = (C.GPDRAWTEXTURENV)(getProcAddr(\"glDrawTextureNV\"))\n\tgpDrawTransformFeedback = (C.GPDRAWTRANSFORMFEEDBACK)(getProcAddr(\"glDrawTransformFeedback\"))\n\tif gpDrawTransformFeedback == nil {\n\t\treturn errors.New(\"glDrawTransformFeedback\")\n\t}\n\tgpDrawTransformFeedbackInstanced = (C.GPDRAWTRANSFORMFEEDBACKINSTANCED)(getProcAddr(\"glDrawTransformFeedbackInstanced\"))\n\tif gpDrawTransformFeedbackInstanced == nil {\n\t\treturn errors.New(\"glDrawTransformFeedbackInstanced\")\n\t}\n\tgpDrawTransformFeedbackNV = (C.GPDRAWTRANSFORMFEEDBACKNV)(getProcAddr(\"glDrawTransformFeedbackNV\"))\n\tgpDrawTransformFeedbackStream = (C.GPDRAWTRANSFORMFEEDBACKSTREAM)(getProcAddr(\"glDrawTransformFeedbackStream\"))\n\tif gpDrawTransformFeedbackStream == nil {\n\t\treturn errors.New(\"glDrawTransformFeedbackStream\")\n\t}\n\tgpDrawTransformFeedbackStreamInstanced = (C.GPDRAWTRANSFORMFEEDBACKSTREAMINSTANCED)(getProcAddr(\"glDrawTransformFeedbackStreamInstanced\"))\n\tif gpDrawTransformFeedbackStreamInstanced == nil {\n\t\treturn errors.New(\"glDrawTransformFeedbackStreamInstanced\")\n\t}\n\tgpDrawVkImageNV = (C.GPDRAWVKIMAGENV)(getProcAddr(\"glDrawVkImageNV\"))\n\tgpEGLImageTargetTexStorageEXT = (C.GPEGLIMAGETARGETTEXSTORAGEEXT)(getProcAddr(\"glEGLImageTargetTexStorageEXT\"))\n\tgpEGLImageTargetTextureStorageEXT = (C.GPEGLIMAGETARGETTEXTURESTORAGEEXT)(getProcAddr(\"glEGLImageTargetTextureStorageEXT\"))\n\tgpEdgeFlag = (C.GPEDGEFLAG)(getProcAddr(\"glEdgeFlag\"))\n\tif gpEdgeFlag == nil {\n\t\treturn errors.New(\"glEdgeFlag\")\n\t}\n\tgpEdgeFlagFormatNV = (C.GPEDGEFLAGFORMATNV)(getProcAddr(\"glEdgeFlagFormatNV\"))\n\tgpEdgeFlagPointer = (C.GPEDGEFLAGPOINTER)(getProcAddr(\"glEdgeFlagPointer\"))\n\tif gpEdgeFlagPointer == nil {\n\t\treturn errors.New(\"glEdgeFlagPointer\")\n\t}\n\tgpEdgeFlagPointerEXT = (C.GPEDGEFLAGPOINTEREXT)(getProcAddr(\"glEdgeFlagPointerEXT\"))\n\tgpEdgeFlagPointerListIBM = (C.GPEDGEFLAGPOINTERLISTIBM)(getProcAddr(\"glEdgeFlagPointerListIBM\"))\n\tgpEdgeFlagv = (C.GPEDGEFLAGV)(getProcAddr(\"glEdgeFlagv\"))\n\tif gpEdgeFlagv == nil {\n\t\treturn errors.New(\"glEdgeFlagv\")\n\t}\n\tgpElementPointerAPPLE = (C.GPELEMENTPOINTERAPPLE)(getProcAddr(\"glElementPointerAPPLE\"))\n\tgpElementPointerATI = (C.GPELEMENTPOINTERATI)(getProcAddr(\"glElementPointerATI\"))\n\tgpEnable = (C.GPENABLE)(getProcAddr(\"glEnable\"))\n\tif gpEnable == nil {\n\t\treturn errors.New(\"glEnable\")\n\t}\n\tgpEnableClientState = (C.GPENABLECLIENTSTATE)(getProcAddr(\"glEnableClientState\"))\n\tif gpEnableClientState == nil {\n\t\treturn errors.New(\"glEnableClientState\")\n\t}\n\tgpEnableClientStateIndexedEXT = (C.GPENABLECLIENTSTATEINDEXEDEXT)(getProcAddr(\"glEnableClientStateIndexedEXT\"))\n\tgpEnableClientStateiEXT = (C.GPENABLECLIENTSTATEIEXT)(getProcAddr(\"glEnableClientStateiEXT\"))\n\tgpEnableIndexedEXT = (C.GPENABLEINDEXEDEXT)(getProcAddr(\"glEnableIndexedEXT\"))\n\tgpEnableVariantClientStateEXT = (C.GPENABLEVARIANTCLIENTSTATEEXT)(getProcAddr(\"glEnableVariantClientStateEXT\"))\n\tgpEnableVertexArrayAttrib = (C.GPENABLEVERTEXARRAYATTRIB)(getProcAddr(\"glEnableVertexArrayAttrib\"))\n\tgpEnableVertexArrayAttribEXT = (C.GPENABLEVERTEXARRAYATTRIBEXT)(getProcAddr(\"glEnableVertexArrayAttribEXT\"))\n\tgpEnableVertexArrayEXT = (C.GPENABLEVERTEXARRAYEXT)(getProcAddr(\"glEnableVertexArrayEXT\"))\n\tgpEnableVertexAttribAPPLE = (C.GPENABLEVERTEXATTRIBAPPLE)(getProcAddr(\"glEnableVertexAttribAPPLE\"))\n\tgpEnableVertexAttribArray = (C.GPENABLEVERTEXATTRIBARRAY)(getProcAddr(\"glEnableVertexAttribArray\"))\n\tif gpEnableVertexAttribArray == nil {\n\t\treturn errors.New(\"glEnableVertexAttribArray\")\n\t}\n\tgpEnableVertexAttribArrayARB = (C.GPENABLEVERTEXATTRIBARRAYARB)(getProcAddr(\"glEnableVertexAttribArrayARB\"))\n\tgpEnablei = (C.GPENABLEI)(getProcAddr(\"glEnablei\"))\n\tif gpEnablei == nil {\n\t\treturn errors.New(\"glEnablei\")\n\t}\n\tgpEnd = (C.GPEND)(getProcAddr(\"glEnd\"))\n\tif gpEnd == nil {\n\t\treturn errors.New(\"glEnd\")\n\t}\n\tgpEndConditionalRender = (C.GPENDCONDITIONALRENDER)(getProcAddr(\"glEndConditionalRender\"))\n\tif gpEndConditionalRender == nil {\n\t\treturn errors.New(\"glEndConditionalRender\")\n\t}\n\tgpEndConditionalRenderNV = (C.GPENDCONDITIONALRENDERNV)(getProcAddr(\"glEndConditionalRenderNV\"))\n\tgpEndConditionalRenderNVX = (C.GPENDCONDITIONALRENDERNVX)(getProcAddr(\"glEndConditionalRenderNVX\"))\n\tgpEndFragmentShaderATI = (C.GPENDFRAGMENTSHADERATI)(getProcAddr(\"glEndFragmentShaderATI\"))\n\tgpEndList = (C.GPENDLIST)(getProcAddr(\"glEndList\"))\n\tif gpEndList == nil {\n\t\treturn errors.New(\"glEndList\")\n\t}\n\tgpEndOcclusionQueryNV = (C.GPENDOCCLUSIONQUERYNV)(getProcAddr(\"glEndOcclusionQueryNV\"))\n\tgpEndPerfMonitorAMD = (C.GPENDPERFMONITORAMD)(getProcAddr(\"glEndPerfMonitorAMD\"))\n\tgpEndPerfQueryINTEL = (C.GPENDPERFQUERYINTEL)(getProcAddr(\"glEndPerfQueryINTEL\"))\n\tgpEndQuery = (C.GPENDQUERY)(getProcAddr(\"glEndQuery\"))\n\tif gpEndQuery == nil {\n\t\treturn errors.New(\"glEndQuery\")\n\t}\n\tgpEndQueryARB = (C.GPENDQUERYARB)(getProcAddr(\"glEndQueryARB\"))\n\tgpEndQueryIndexed = (C.GPENDQUERYINDEXED)(getProcAddr(\"glEndQueryIndexed\"))\n\tif gpEndQueryIndexed == nil {\n\t\treturn errors.New(\"glEndQueryIndexed\")\n\t}\n\tgpEndTransformFeedback = (C.GPENDTRANSFORMFEEDBACK)(getProcAddr(\"glEndTransformFeedback\"))\n\tif gpEndTransformFeedback == nil {\n\t\treturn errors.New(\"glEndTransformFeedback\")\n\t}\n\tgpEndTransformFeedbackEXT = (C.GPENDTRANSFORMFEEDBACKEXT)(getProcAddr(\"glEndTransformFeedbackEXT\"))\n\tgpEndTransformFeedbackNV = (C.GPENDTRANSFORMFEEDBACKNV)(getProcAddr(\"glEndTransformFeedbackNV\"))\n\tgpEndVertexShaderEXT = (C.GPENDVERTEXSHADEREXT)(getProcAddr(\"glEndVertexShaderEXT\"))\n\tgpEndVideoCaptureNV = (C.GPENDVIDEOCAPTURENV)(getProcAddr(\"glEndVideoCaptureNV\"))\n\tgpEvalCoord1d = (C.GPEVALCOORD1D)(getProcAddr(\"glEvalCoord1d\"))\n\tif gpEvalCoord1d == nil {\n\t\treturn errors.New(\"glEvalCoord1d\")\n\t}\n\tgpEvalCoord1dv = (C.GPEVALCOORD1DV)(getProcAddr(\"glEvalCoord1dv\"))\n\tif gpEvalCoord1dv == nil {\n\t\treturn errors.New(\"glEvalCoord1dv\")\n\t}\n\tgpEvalCoord1f = (C.GPEVALCOORD1F)(getProcAddr(\"glEvalCoord1f\"))\n\tif gpEvalCoord1f == nil {\n\t\treturn errors.New(\"glEvalCoord1f\")\n\t}\n\tgpEvalCoord1fv = (C.GPEVALCOORD1FV)(getProcAddr(\"glEvalCoord1fv\"))\n\tif gpEvalCoord1fv == nil {\n\t\treturn errors.New(\"glEvalCoord1fv\")\n\t}\n\tgpEvalCoord1xOES = (C.GPEVALCOORD1XOES)(getProcAddr(\"glEvalCoord1xOES\"))\n\tgpEvalCoord1xvOES = (C.GPEVALCOORD1XVOES)(getProcAddr(\"glEvalCoord1xvOES\"))\n\tgpEvalCoord2d = (C.GPEVALCOORD2D)(getProcAddr(\"glEvalCoord2d\"))\n\tif gpEvalCoord2d == nil {\n\t\treturn errors.New(\"glEvalCoord2d\")\n\t}\n\tgpEvalCoord2dv = (C.GPEVALCOORD2DV)(getProcAddr(\"glEvalCoord2dv\"))\n\tif gpEvalCoord2dv == nil {\n\t\treturn errors.New(\"glEvalCoord2dv\")\n\t}\n\tgpEvalCoord2f = (C.GPEVALCOORD2F)(getProcAddr(\"glEvalCoord2f\"))\n\tif gpEvalCoord2f == nil {\n\t\treturn errors.New(\"glEvalCoord2f\")\n\t}\n\tgpEvalCoord2fv = (C.GPEVALCOORD2FV)(getProcAddr(\"glEvalCoord2fv\"))\n\tif gpEvalCoord2fv == nil {\n\t\treturn errors.New(\"glEvalCoord2fv\")\n\t}\n\tgpEvalCoord2xOES = (C.GPEVALCOORD2XOES)(getProcAddr(\"glEvalCoord2xOES\"))\n\tgpEvalCoord2xvOES = (C.GPEVALCOORD2XVOES)(getProcAddr(\"glEvalCoord2xvOES\"))\n\tgpEvalMapsNV = (C.GPEVALMAPSNV)(getProcAddr(\"glEvalMapsNV\"))\n\tgpEvalMesh1 = (C.GPEVALMESH1)(getProcAddr(\"glEvalMesh1\"))\n\tif gpEvalMesh1 == nil {\n\t\treturn errors.New(\"glEvalMesh1\")\n\t}\n\tgpEvalMesh2 = (C.GPEVALMESH2)(getProcAddr(\"glEvalMesh2\"))\n\tif gpEvalMesh2 == nil {\n\t\treturn errors.New(\"glEvalMesh2\")\n\t}\n\tgpEvalPoint1 = (C.GPEVALPOINT1)(getProcAddr(\"glEvalPoint1\"))\n\tif gpEvalPoint1 == nil {\n\t\treturn errors.New(\"glEvalPoint1\")\n\t}\n\tgpEvalPoint2 = (C.GPEVALPOINT2)(getProcAddr(\"glEvalPoint2\"))\n\tif gpEvalPoint2 == nil {\n\t\treturn errors.New(\"glEvalPoint2\")\n\t}\n\tgpEvaluateDepthValuesARB = (C.GPEVALUATEDEPTHVALUESARB)(getProcAddr(\"glEvaluateDepthValuesARB\"))\n\tgpExecuteProgramNV = (C.GPEXECUTEPROGRAMNV)(getProcAddr(\"glExecuteProgramNV\"))\n\tgpExtractComponentEXT = (C.GPEXTRACTCOMPONENTEXT)(getProcAddr(\"glExtractComponentEXT\"))\n\tgpFeedbackBuffer = (C.GPFEEDBACKBUFFER)(getProcAddr(\"glFeedbackBuffer\"))\n\tif gpFeedbackBuffer == nil {\n\t\treturn errors.New(\"glFeedbackBuffer\")\n\t}\n\tgpFeedbackBufferxOES = (C.GPFEEDBACKBUFFERXOES)(getProcAddr(\"glFeedbackBufferxOES\"))\n\tgpFenceSync = (C.GPFENCESYNC)(getProcAddr(\"glFenceSync\"))\n\tif gpFenceSync == nil {\n\t\treturn errors.New(\"glFenceSync\")\n\t}\n\tgpFinalCombinerInputNV = (C.GPFINALCOMBINERINPUTNV)(getProcAddr(\"glFinalCombinerInputNV\"))\n\tgpFinish = (C.GPFINISH)(getProcAddr(\"glFinish\"))\n\tif gpFinish == nil {\n\t\treturn errors.New(\"glFinish\")\n\t}\n\tgpFinishAsyncSGIX = (C.GPFINISHASYNCSGIX)(getProcAddr(\"glFinishAsyncSGIX\"))\n\tgpFinishFenceAPPLE = (C.GPFINISHFENCEAPPLE)(getProcAddr(\"glFinishFenceAPPLE\"))\n\tgpFinishFenceNV = (C.GPFINISHFENCENV)(getProcAddr(\"glFinishFenceNV\"))\n\tgpFinishObjectAPPLE = (C.GPFINISHOBJECTAPPLE)(getProcAddr(\"glFinishObjectAPPLE\"))\n\tgpFinishTextureSUNX = (C.GPFINISHTEXTURESUNX)(getProcAddr(\"glFinishTextureSUNX\"))\n\tgpFlush = (C.GPFLUSH)(getProcAddr(\"glFlush\"))\n\tif gpFlush == nil {\n\t\treturn errors.New(\"glFlush\")\n\t}\n\tgpFlushMappedBufferRange = (C.GPFLUSHMAPPEDBUFFERRANGE)(getProcAddr(\"glFlushMappedBufferRange\"))\n\tif gpFlushMappedBufferRange == nil {\n\t\treturn errors.New(\"glFlushMappedBufferRange\")\n\t}\n\tgpFlushMappedBufferRangeAPPLE = (C.GPFLUSHMAPPEDBUFFERRANGEAPPLE)(getProcAddr(\"glFlushMappedBufferRangeAPPLE\"))\n\tgpFlushMappedNamedBufferRange = (C.GPFLUSHMAPPEDNAMEDBUFFERRANGE)(getProcAddr(\"glFlushMappedNamedBufferRange\"))\n\tgpFlushMappedNamedBufferRangeEXT = (C.GPFLUSHMAPPEDNAMEDBUFFERRANGEEXT)(getProcAddr(\"glFlushMappedNamedBufferRangeEXT\"))\n\tgpFlushPixelDataRangeNV = (C.GPFLUSHPIXELDATARANGENV)(getProcAddr(\"glFlushPixelDataRangeNV\"))\n\tgpFlushRasterSGIX = (C.GPFLUSHRASTERSGIX)(getProcAddr(\"glFlushRasterSGIX\"))\n\tgpFlushStaticDataIBM = (C.GPFLUSHSTATICDATAIBM)(getProcAddr(\"glFlushStaticDataIBM\"))\n\tgpFlushVertexArrayRangeAPPLE = (C.GPFLUSHVERTEXARRAYRANGEAPPLE)(getProcAddr(\"glFlushVertexArrayRangeAPPLE\"))\n\tgpFlushVertexArrayRangeNV = (C.GPFLUSHVERTEXARRAYRANGENV)(getProcAddr(\"glFlushVertexArrayRangeNV\"))\n\tgpFogCoordFormatNV = (C.GPFOGCOORDFORMATNV)(getProcAddr(\"glFogCoordFormatNV\"))\n\tgpFogCoordPointer = (C.GPFOGCOORDPOINTER)(getProcAddr(\"glFogCoordPointer\"))\n\tif gpFogCoordPointer == nil {\n\t\treturn errors.New(\"glFogCoordPointer\")\n\t}\n\tgpFogCoordPointerEXT = (C.GPFOGCOORDPOINTEREXT)(getProcAddr(\"glFogCoordPointerEXT\"))\n\tgpFogCoordPointerListIBM = (C.GPFOGCOORDPOINTERLISTIBM)(getProcAddr(\"glFogCoordPointerListIBM\"))\n\tgpFogCoordd = (C.GPFOGCOORDD)(getProcAddr(\"glFogCoordd\"))\n\tif gpFogCoordd == nil {\n\t\treturn errors.New(\"glFogCoordd\")\n\t}\n\tgpFogCoorddEXT = (C.GPFOGCOORDDEXT)(getProcAddr(\"glFogCoorddEXT\"))\n\tgpFogCoorddv = (C.GPFOGCOORDDV)(getProcAddr(\"glFogCoorddv\"))\n\tif gpFogCoorddv == nil {\n\t\treturn errors.New(\"glFogCoorddv\")\n\t}\n\tgpFogCoorddvEXT = (C.GPFOGCOORDDVEXT)(getProcAddr(\"glFogCoorddvEXT\"))\n\tgpFogCoordf = (C.GPFOGCOORDF)(getProcAddr(\"glFogCoordf\"))\n\tif gpFogCoordf == nil {\n\t\treturn errors.New(\"glFogCoordf\")\n\t}\n\tgpFogCoordfEXT = (C.GPFOGCOORDFEXT)(getProcAddr(\"glFogCoordfEXT\"))\n\tgpFogCoordfv = (C.GPFOGCOORDFV)(getProcAddr(\"glFogCoordfv\"))\n\tif gpFogCoordfv == nil {\n\t\treturn errors.New(\"glFogCoordfv\")\n\t}\n\tgpFogCoordfvEXT = (C.GPFOGCOORDFVEXT)(getProcAddr(\"glFogCoordfvEXT\"))\n\tgpFogCoordhNV = (C.GPFOGCOORDHNV)(getProcAddr(\"glFogCoordhNV\"))\n\tgpFogCoordhvNV = (C.GPFOGCOORDHVNV)(getProcAddr(\"glFogCoordhvNV\"))\n\tgpFogFuncSGIS = (C.GPFOGFUNCSGIS)(getProcAddr(\"glFogFuncSGIS\"))\n\tgpFogf = (C.GPFOGF)(getProcAddr(\"glFogf\"))\n\tif gpFogf == nil {\n\t\treturn errors.New(\"glFogf\")\n\t}\n\tgpFogfv = (C.GPFOGFV)(getProcAddr(\"glFogfv\"))\n\tif gpFogfv == nil {\n\t\treturn errors.New(\"glFogfv\")\n\t}\n\tgpFogi = (C.GPFOGI)(getProcAddr(\"glFogi\"))\n\tif gpFogi == nil {\n\t\treturn errors.New(\"glFogi\")\n\t}\n\tgpFogiv = (C.GPFOGIV)(getProcAddr(\"glFogiv\"))\n\tif gpFogiv == nil {\n\t\treturn errors.New(\"glFogiv\")\n\t}\n\tgpFogxOES = (C.GPFOGXOES)(getProcAddr(\"glFogxOES\"))\n\tgpFogxvOES = (C.GPFOGXVOES)(getProcAddr(\"glFogxvOES\"))\n\tgpFragmentColorMaterialSGIX = (C.GPFRAGMENTCOLORMATERIALSGIX)(getProcAddr(\"glFragmentColorMaterialSGIX\"))\n\tgpFragmentCoverageColorNV = (C.GPFRAGMENTCOVERAGECOLORNV)(getProcAddr(\"glFragmentCoverageColorNV\"))\n\tgpFragmentLightModelfSGIX = (C.GPFRAGMENTLIGHTMODELFSGIX)(getProcAddr(\"glFragmentLightModelfSGIX\"))\n\tgpFragmentLightModelfvSGIX = (C.GPFRAGMENTLIGHTMODELFVSGIX)(getProcAddr(\"glFragmentLightModelfvSGIX\"))\n\tgpFragmentLightModeliSGIX = (C.GPFRAGMENTLIGHTMODELISGIX)(getProcAddr(\"glFragmentLightModeliSGIX\"))\n\tgpFragmentLightModelivSGIX = (C.GPFRAGMENTLIGHTMODELIVSGIX)(getProcAddr(\"glFragmentLightModelivSGIX\"))\n\tgpFragmentLightfSGIX = (C.GPFRAGMENTLIGHTFSGIX)(getProcAddr(\"glFragmentLightfSGIX\"))\n\tgpFragmentLightfvSGIX = (C.GPFRAGMENTLIGHTFVSGIX)(getProcAddr(\"glFragmentLightfvSGIX\"))\n\tgpFragmentLightiSGIX = (C.GPFRAGMENTLIGHTISGIX)(getProcAddr(\"glFragmentLightiSGIX\"))\n\tgpFragmentLightivSGIX = (C.GPFRAGMENTLIGHTIVSGIX)(getProcAddr(\"glFragmentLightivSGIX\"))\n\tgpFragmentMaterialfSGIX = (C.GPFRAGMENTMATERIALFSGIX)(getProcAddr(\"glFragmentMaterialfSGIX\"))\n\tgpFragmentMaterialfvSGIX = (C.GPFRAGMENTMATERIALFVSGIX)(getProcAddr(\"glFragmentMaterialfvSGIX\"))\n\tgpFragmentMaterialiSGIX = (C.GPFRAGMENTMATERIALISGIX)(getProcAddr(\"glFragmentMaterialiSGIX\"))\n\tgpFragmentMaterialivSGIX = (C.GPFRAGMENTMATERIALIVSGIX)(getProcAddr(\"glFragmentMaterialivSGIX\"))\n\tgpFrameTerminatorGREMEDY = (C.GPFRAMETERMINATORGREMEDY)(getProcAddr(\"glFrameTerminatorGREMEDY\"))\n\tgpFrameZoomSGIX = (C.GPFRAMEZOOMSGIX)(getProcAddr(\"glFrameZoomSGIX\"))\n\tgpFramebufferDrawBufferEXT = (C.GPFRAMEBUFFERDRAWBUFFEREXT)(getProcAddr(\"glFramebufferDrawBufferEXT\"))\n\tgpFramebufferDrawBuffersEXT = (C.GPFRAMEBUFFERDRAWBUFFERSEXT)(getProcAddr(\"glFramebufferDrawBuffersEXT\"))\n\tgpFramebufferFetchBarrierEXT = (C.GPFRAMEBUFFERFETCHBARRIEREXT)(getProcAddr(\"glFramebufferFetchBarrierEXT\"))\n\tgpFramebufferParameteri = (C.GPFRAMEBUFFERPARAMETERI)(getProcAddr(\"glFramebufferParameteri\"))\n\tif gpFramebufferParameteri == nil {\n\t\treturn errors.New(\"glFramebufferParameteri\")\n\t}\n\tgpFramebufferParameteriMESA = (C.GPFRAMEBUFFERPARAMETERIMESA)(getProcAddr(\"glFramebufferParameteriMESA\"))\n\tgpFramebufferReadBufferEXT = (C.GPFRAMEBUFFERREADBUFFEREXT)(getProcAddr(\"glFramebufferReadBufferEXT\"))\n\tgpFramebufferRenderbuffer = (C.GPFRAMEBUFFERRENDERBUFFER)(getProcAddr(\"glFramebufferRenderbuffer\"))\n\tif gpFramebufferRenderbuffer == nil {\n\t\treturn errors.New(\"glFramebufferRenderbuffer\")\n\t}\n\tgpFramebufferRenderbufferEXT = (C.GPFRAMEBUFFERRENDERBUFFEREXT)(getProcAddr(\"glFramebufferRenderbufferEXT\"))\n\tgpFramebufferSampleLocationsfvARB = (C.GPFRAMEBUFFERSAMPLELOCATIONSFVARB)(getProcAddr(\"glFramebufferSampleLocationsfvARB\"))\n\tgpFramebufferSampleLocationsfvNV = (C.GPFRAMEBUFFERSAMPLELOCATIONSFVNV)(getProcAddr(\"glFramebufferSampleLocationsfvNV\"))\n\tgpFramebufferSamplePositionsfvAMD = (C.GPFRAMEBUFFERSAMPLEPOSITIONSFVAMD)(getProcAddr(\"glFramebufferSamplePositionsfvAMD\"))\n\tgpFramebufferTexture = (C.GPFRAMEBUFFERTEXTURE)(getProcAddr(\"glFramebufferTexture\"))\n\tif gpFramebufferTexture == nil {\n\t\treturn errors.New(\"glFramebufferTexture\")\n\t}\n\tgpFramebufferTexture1D = (C.GPFRAMEBUFFERTEXTURE1D)(getProcAddr(\"glFramebufferTexture1D\"))\n\tif gpFramebufferTexture1D == nil {\n\t\treturn errors.New(\"glFramebufferTexture1D\")\n\t}\n\tgpFramebufferTexture1DEXT = (C.GPFRAMEBUFFERTEXTURE1DEXT)(getProcAddr(\"glFramebufferTexture1DEXT\"))\n\tgpFramebufferTexture2D = (C.GPFRAMEBUFFERTEXTURE2D)(getProcAddr(\"glFramebufferTexture2D\"))\n\tif gpFramebufferTexture2D == nil {\n\t\treturn errors.New(\"glFramebufferTexture2D\")\n\t}\n\tgpFramebufferTexture2DEXT = (C.GPFRAMEBUFFERTEXTURE2DEXT)(getProcAddr(\"glFramebufferTexture2DEXT\"))\n\tgpFramebufferTexture3D = (C.GPFRAMEBUFFERTEXTURE3D)(getProcAddr(\"glFramebufferTexture3D\"))\n\tif gpFramebufferTexture3D == nil {\n\t\treturn errors.New(\"glFramebufferTexture3D\")\n\t}\n\tgpFramebufferTexture3DEXT = (C.GPFRAMEBUFFERTEXTURE3DEXT)(getProcAddr(\"glFramebufferTexture3DEXT\"))\n\tgpFramebufferTextureARB = (C.GPFRAMEBUFFERTEXTUREARB)(getProcAddr(\"glFramebufferTextureARB\"))\n\tgpFramebufferTextureEXT = (C.GPFRAMEBUFFERTEXTUREEXT)(getProcAddr(\"glFramebufferTextureEXT\"))\n\tgpFramebufferTextureFaceARB = (C.GPFRAMEBUFFERTEXTUREFACEARB)(getProcAddr(\"glFramebufferTextureFaceARB\"))\n\tgpFramebufferTextureFaceEXT = (C.GPFRAMEBUFFERTEXTUREFACEEXT)(getProcAddr(\"glFramebufferTextureFaceEXT\"))\n\tgpFramebufferTextureLayer = (C.GPFRAMEBUFFERTEXTURELAYER)(getProcAddr(\"glFramebufferTextureLayer\"))\n\tif gpFramebufferTextureLayer == nil {\n\t\treturn errors.New(\"glFramebufferTextureLayer\")\n\t}\n\tgpFramebufferTextureLayerARB = (C.GPFRAMEBUFFERTEXTURELAYERARB)(getProcAddr(\"glFramebufferTextureLayerARB\"))\n\tgpFramebufferTextureLayerEXT = (C.GPFRAMEBUFFERTEXTURELAYEREXT)(getProcAddr(\"glFramebufferTextureLayerEXT\"))\n\tgpFramebufferTextureMultiviewOVR = (C.GPFRAMEBUFFERTEXTUREMULTIVIEWOVR)(getProcAddr(\"glFramebufferTextureMultiviewOVR\"))\n\tgpFreeObjectBufferATI = (C.GPFREEOBJECTBUFFERATI)(getProcAddr(\"glFreeObjectBufferATI\"))\n\tgpFrontFace = (C.GPFRONTFACE)(getProcAddr(\"glFrontFace\"))\n\tif gpFrontFace == nil {\n\t\treturn errors.New(\"glFrontFace\")\n\t}\n\tgpFrustum = (C.GPFRUSTUM)(getProcAddr(\"glFrustum\"))\n\tif gpFrustum == nil {\n\t\treturn errors.New(\"glFrustum\")\n\t}\n\tgpFrustumfOES = (C.GPFRUSTUMFOES)(getProcAddr(\"glFrustumfOES\"))\n\tgpFrustumxOES = (C.GPFRUSTUMXOES)(getProcAddr(\"glFrustumxOES\"))\n\tgpGenAsyncMarkersSGIX = (C.GPGENASYNCMARKERSSGIX)(getProcAddr(\"glGenAsyncMarkersSGIX\"))\n\tgpGenBuffers = (C.GPGENBUFFERS)(getProcAddr(\"glGenBuffers\"))\n\tif gpGenBuffers == nil {\n\t\treturn errors.New(\"glGenBuffers\")\n\t}\n\tgpGenBuffersARB = (C.GPGENBUFFERSARB)(getProcAddr(\"glGenBuffersARB\"))\n\tgpGenFencesAPPLE = (C.GPGENFENCESAPPLE)(getProcAddr(\"glGenFencesAPPLE\"))\n\tgpGenFencesNV = (C.GPGENFENCESNV)(getProcAddr(\"glGenFencesNV\"))\n\tgpGenFragmentShadersATI = (C.GPGENFRAGMENTSHADERSATI)(getProcAddr(\"glGenFragmentShadersATI\"))\n\tgpGenFramebuffers = (C.GPGENFRAMEBUFFERS)(getProcAddr(\"glGenFramebuffers\"))\n\tif gpGenFramebuffers == nil {\n\t\treturn errors.New(\"glGenFramebuffers\")\n\t}\n\tgpGenFramebuffersEXT = (C.GPGENFRAMEBUFFERSEXT)(getProcAddr(\"glGenFramebuffersEXT\"))\n\tgpGenLists = (C.GPGENLISTS)(getProcAddr(\"glGenLists\"))\n\tif gpGenLists == nil {\n\t\treturn errors.New(\"glGenLists\")\n\t}\n\tgpGenNamesAMD = (C.GPGENNAMESAMD)(getProcAddr(\"glGenNamesAMD\"))\n\tgpGenOcclusionQueriesNV = (C.GPGENOCCLUSIONQUERIESNV)(getProcAddr(\"glGenOcclusionQueriesNV\"))\n\tgpGenPathsNV = (C.GPGENPATHSNV)(getProcAddr(\"glGenPathsNV\"))\n\tgpGenPerfMonitorsAMD = (C.GPGENPERFMONITORSAMD)(getProcAddr(\"glGenPerfMonitorsAMD\"))\n\tgpGenProgramPipelines = (C.GPGENPROGRAMPIPELINES)(getProcAddr(\"glGenProgramPipelines\"))\n\tif gpGenProgramPipelines == nil {\n\t\treturn errors.New(\"glGenProgramPipelines\")\n\t}\n\tgpGenProgramPipelinesEXT = (C.GPGENPROGRAMPIPELINESEXT)(getProcAddr(\"glGenProgramPipelinesEXT\"))\n\tgpGenProgramsARB = (C.GPGENPROGRAMSARB)(getProcAddr(\"glGenProgramsARB\"))\n\tgpGenProgramsNV = (C.GPGENPROGRAMSNV)(getProcAddr(\"glGenProgramsNV\"))\n\tgpGenQueries = (C.GPGENQUERIES)(getProcAddr(\"glGenQueries\"))\n\tif gpGenQueries == nil {\n\t\treturn errors.New(\"glGenQueries\")\n\t}\n\tgpGenQueriesARB = (C.GPGENQUERIESARB)(getProcAddr(\"glGenQueriesARB\"))\n\tgpGenQueryResourceTagNV = (C.GPGENQUERYRESOURCETAGNV)(getProcAddr(\"glGenQueryResourceTagNV\"))\n\tgpGenRenderbuffers = (C.GPGENRENDERBUFFERS)(getProcAddr(\"glGenRenderbuffers\"))\n\tif gpGenRenderbuffers == nil {\n\t\treturn errors.New(\"glGenRenderbuffers\")\n\t}\n\tgpGenRenderbuffersEXT = (C.GPGENRENDERBUFFERSEXT)(getProcAddr(\"glGenRenderbuffersEXT\"))\n\tgpGenSamplers = (C.GPGENSAMPLERS)(getProcAddr(\"glGenSamplers\"))\n\tif gpGenSamplers == nil {\n\t\treturn errors.New(\"glGenSamplers\")\n\t}\n\tgpGenSemaphoresEXT = (C.GPGENSEMAPHORESEXT)(getProcAddr(\"glGenSemaphoresEXT\"))\n\tgpGenSymbolsEXT = (C.GPGENSYMBOLSEXT)(getProcAddr(\"glGenSymbolsEXT\"))\n\tgpGenTextures = (C.GPGENTEXTURES)(getProcAddr(\"glGenTextures\"))\n\tif gpGenTextures == nil {\n\t\treturn errors.New(\"glGenTextures\")\n\t}\n\tgpGenTexturesEXT = (C.GPGENTEXTURESEXT)(getProcAddr(\"glGenTexturesEXT\"))\n\tgpGenTransformFeedbacks = (C.GPGENTRANSFORMFEEDBACKS)(getProcAddr(\"glGenTransformFeedbacks\"))\n\tif gpGenTransformFeedbacks == nil {\n\t\treturn errors.New(\"glGenTransformFeedbacks\")\n\t}\n\tgpGenTransformFeedbacksNV = (C.GPGENTRANSFORMFEEDBACKSNV)(getProcAddr(\"glGenTransformFeedbacksNV\"))\n\tgpGenVertexArrays = (C.GPGENVERTEXARRAYS)(getProcAddr(\"glGenVertexArrays\"))\n\tif gpGenVertexArrays == nil {\n\t\treturn errors.New(\"glGenVertexArrays\")\n\t}\n\tgpGenVertexArraysAPPLE = (C.GPGENVERTEXARRAYSAPPLE)(getProcAddr(\"glGenVertexArraysAPPLE\"))\n\tgpGenVertexShadersEXT = (C.GPGENVERTEXSHADERSEXT)(getProcAddr(\"glGenVertexShadersEXT\"))\n\tgpGenerateMipmap = (C.GPGENERATEMIPMAP)(getProcAddr(\"glGenerateMipmap\"))\n\tif gpGenerateMipmap == nil {\n\t\treturn errors.New(\"glGenerateMipmap\")\n\t}\n\tgpGenerateMipmapEXT = (C.GPGENERATEMIPMAPEXT)(getProcAddr(\"glGenerateMipmapEXT\"))\n\tgpGenerateMultiTexMipmapEXT = (C.GPGENERATEMULTITEXMIPMAPEXT)(getProcAddr(\"glGenerateMultiTexMipmapEXT\"))\n\tgpGenerateTextureMipmap = (C.GPGENERATETEXTUREMIPMAP)(getProcAddr(\"glGenerateTextureMipmap\"))\n\tgpGenerateTextureMipmapEXT = (C.GPGENERATETEXTUREMIPMAPEXT)(getProcAddr(\"glGenerateTextureMipmapEXT\"))\n\tgpGetActiveAtomicCounterBufferiv = (C.GPGETACTIVEATOMICCOUNTERBUFFERIV)(getProcAddr(\"glGetActiveAtomicCounterBufferiv\"))\n\tif gpGetActiveAtomicCounterBufferiv == nil {\n\t\treturn errors.New(\"glGetActiveAtomicCounterBufferiv\")\n\t}\n\tgpGetActiveAttrib = (C.GPGETACTIVEATTRIB)(getProcAddr(\"glGetActiveAttrib\"))\n\tif gpGetActiveAttrib == nil {\n\t\treturn errors.New(\"glGetActiveAttrib\")\n\t}\n\tgpGetActiveAttribARB = (C.GPGETACTIVEATTRIBARB)(getProcAddr(\"glGetActiveAttribARB\"))\n\tgpGetActiveSubroutineName = (C.GPGETACTIVESUBROUTINENAME)(getProcAddr(\"glGetActiveSubroutineName\"))\n\tif gpGetActiveSubroutineName == nil {\n\t\treturn errors.New(\"glGetActiveSubroutineName\")\n\t}\n\tgpGetActiveSubroutineUniformName = (C.GPGETACTIVESUBROUTINEUNIFORMNAME)(getProcAddr(\"glGetActiveSubroutineUniformName\"))\n\tif gpGetActiveSubroutineUniformName == nil {\n\t\treturn errors.New(\"glGetActiveSubroutineUniformName\")\n\t}\n\tgpGetActiveSubroutineUniformiv = (C.GPGETACTIVESUBROUTINEUNIFORMIV)(getProcAddr(\"glGetActiveSubroutineUniformiv\"))\n\tif gpGetActiveSubroutineUniformiv == nil {\n\t\treturn errors.New(\"glGetActiveSubroutineUniformiv\")\n\t}\n\tgpGetActiveUniform = (C.GPGETACTIVEUNIFORM)(getProcAddr(\"glGetActiveUniform\"))\n\tif gpGetActiveUniform == nil {\n\t\treturn errors.New(\"glGetActiveUniform\")\n\t}\n\tgpGetActiveUniformARB = (C.GPGETACTIVEUNIFORMARB)(getProcAddr(\"glGetActiveUniformARB\"))\n\tgpGetActiveUniformBlockName = (C.GPGETACTIVEUNIFORMBLOCKNAME)(getProcAddr(\"glGetActiveUniformBlockName\"))\n\tif gpGetActiveUniformBlockName == nil {\n\t\treturn errors.New(\"glGetActiveUniformBlockName\")\n\t}\n\tgpGetActiveUniformBlockiv = (C.GPGETACTIVEUNIFORMBLOCKIV)(getProcAddr(\"glGetActiveUniformBlockiv\"))\n\tif gpGetActiveUniformBlockiv == nil {\n\t\treturn errors.New(\"glGetActiveUniformBlockiv\")\n\t}\n\tgpGetActiveUniformName = (C.GPGETACTIVEUNIFORMNAME)(getProcAddr(\"glGetActiveUniformName\"))\n\tif gpGetActiveUniformName == nil {\n\t\treturn errors.New(\"glGetActiveUniformName\")\n\t}\n\tgpGetActiveUniformsiv = (C.GPGETACTIVEUNIFORMSIV)(getProcAddr(\"glGetActiveUniformsiv\"))\n\tif gpGetActiveUniformsiv == nil {\n\t\treturn errors.New(\"glGetActiveUniformsiv\")\n\t}\n\tgpGetActiveVaryingNV = (C.GPGETACTIVEVARYINGNV)(getProcAddr(\"glGetActiveVaryingNV\"))\n\tgpGetArrayObjectfvATI = (C.GPGETARRAYOBJECTFVATI)(getProcAddr(\"glGetArrayObjectfvATI\"))\n\tgpGetArrayObjectivATI = (C.GPGETARRAYOBJECTIVATI)(getProcAddr(\"glGetArrayObjectivATI\"))\n\tgpGetAttachedObjectsARB = (C.GPGETATTACHEDOBJECTSARB)(getProcAddr(\"glGetAttachedObjectsARB\"))\n\tgpGetAttachedShaders = (C.GPGETATTACHEDSHADERS)(getProcAddr(\"glGetAttachedShaders\"))\n\tif gpGetAttachedShaders == nil {\n\t\treturn errors.New(\"glGetAttachedShaders\")\n\t}\n\tgpGetAttribLocation = (C.GPGETATTRIBLOCATION)(getProcAddr(\"glGetAttribLocation\"))\n\tif gpGetAttribLocation == nil {\n\t\treturn errors.New(\"glGetAttribLocation\")\n\t}\n\tgpGetAttribLocationARB = (C.GPGETATTRIBLOCATIONARB)(getProcAddr(\"glGetAttribLocationARB\"))\n\tgpGetBooleanIndexedvEXT = (C.GPGETBOOLEANINDEXEDVEXT)(getProcAddr(\"glGetBooleanIndexedvEXT\"))\n\tgpGetBooleani_v = (C.GPGETBOOLEANI_V)(getProcAddr(\"glGetBooleani_v\"))\n\tif gpGetBooleani_v == nil {\n\t\treturn errors.New(\"glGetBooleani_v\")\n\t}\n\tgpGetBooleanv = (C.GPGETBOOLEANV)(getProcAddr(\"glGetBooleanv\"))\n\tif gpGetBooleanv == nil {\n\t\treturn errors.New(\"glGetBooleanv\")\n\t}\n\tgpGetBufferParameteri64v = (C.GPGETBUFFERPARAMETERI64V)(getProcAddr(\"glGetBufferParameteri64v\"))\n\tif gpGetBufferParameteri64v == nil {\n\t\treturn errors.New(\"glGetBufferParameteri64v\")\n\t}\n\tgpGetBufferParameteriv = (C.GPGETBUFFERPARAMETERIV)(getProcAddr(\"glGetBufferParameteriv\"))\n\tif gpGetBufferParameteriv == nil {\n\t\treturn errors.New(\"glGetBufferParameteriv\")\n\t}\n\tgpGetBufferParameterivARB = (C.GPGETBUFFERPARAMETERIVARB)(getProcAddr(\"glGetBufferParameterivARB\"))\n\tgpGetBufferParameterui64vNV = (C.GPGETBUFFERPARAMETERUI64VNV)(getProcAddr(\"glGetBufferParameterui64vNV\"))\n\tgpGetBufferPointerv = (C.GPGETBUFFERPOINTERV)(getProcAddr(\"glGetBufferPointerv\"))\n\tif gpGetBufferPointerv == nil {\n\t\treturn errors.New(\"glGetBufferPointerv\")\n\t}\n\tgpGetBufferPointervARB = (C.GPGETBUFFERPOINTERVARB)(getProcAddr(\"glGetBufferPointervARB\"))\n\tgpGetBufferSubData = (C.GPGETBUFFERSUBDATA)(getProcAddr(\"glGetBufferSubData\"))\n\tif gpGetBufferSubData == nil {\n\t\treturn errors.New(\"glGetBufferSubData\")\n\t}\n\tgpGetBufferSubDataARB = (C.GPGETBUFFERSUBDATAARB)(getProcAddr(\"glGetBufferSubDataARB\"))\n\tgpGetClipPlane = (C.GPGETCLIPPLANE)(getProcAddr(\"glGetClipPlane\"))\n\tif gpGetClipPlane == nil {\n\t\treturn errors.New(\"glGetClipPlane\")\n\t}\n\tgpGetClipPlanefOES = (C.GPGETCLIPPLANEFOES)(getProcAddr(\"glGetClipPlanefOES\"))\n\tgpGetClipPlanexOES = (C.GPGETCLIPPLANEXOES)(getProcAddr(\"glGetClipPlanexOES\"))\n\tgpGetColorTable = (C.GPGETCOLORTABLE)(getProcAddr(\"glGetColorTable\"))\n\tgpGetColorTableEXT = (C.GPGETCOLORTABLEEXT)(getProcAddr(\"glGetColorTableEXT\"))\n\tgpGetColorTableParameterfv = (C.GPGETCOLORTABLEPARAMETERFV)(getProcAddr(\"glGetColorTableParameterfv\"))\n\tgpGetColorTableParameterfvEXT = (C.GPGETCOLORTABLEPARAMETERFVEXT)(getProcAddr(\"glGetColorTableParameterfvEXT\"))\n\tgpGetColorTableParameterfvSGI = (C.GPGETCOLORTABLEPARAMETERFVSGI)(getProcAddr(\"glGetColorTableParameterfvSGI\"))\n\tgpGetColorTableParameteriv = (C.GPGETCOLORTABLEPARAMETERIV)(getProcAddr(\"glGetColorTableParameteriv\"))\n\tgpGetColorTableParameterivEXT = (C.GPGETCOLORTABLEPARAMETERIVEXT)(getProcAddr(\"glGetColorTableParameterivEXT\"))\n\tgpGetColorTableParameterivSGI = (C.GPGETCOLORTABLEPARAMETERIVSGI)(getProcAddr(\"glGetColorTableParameterivSGI\"))\n\tgpGetColorTableSGI = (C.GPGETCOLORTABLESGI)(getProcAddr(\"glGetColorTableSGI\"))\n\tgpGetCombinerInputParameterfvNV = (C.GPGETCOMBINERINPUTPARAMETERFVNV)(getProcAddr(\"glGetCombinerInputParameterfvNV\"))\n\tgpGetCombinerInputParameterivNV = (C.GPGETCOMBINERINPUTPARAMETERIVNV)(getProcAddr(\"glGetCombinerInputParameterivNV\"))\n\tgpGetCombinerOutputParameterfvNV = (C.GPGETCOMBINEROUTPUTPARAMETERFVNV)(getProcAddr(\"glGetCombinerOutputParameterfvNV\"))\n\tgpGetCombinerOutputParameterivNV = (C.GPGETCOMBINEROUTPUTPARAMETERIVNV)(getProcAddr(\"glGetCombinerOutputParameterivNV\"))\n\tgpGetCombinerStageParameterfvNV = (C.GPGETCOMBINERSTAGEPARAMETERFVNV)(getProcAddr(\"glGetCombinerStageParameterfvNV\"))\n\tgpGetCommandHeaderNV = (C.GPGETCOMMANDHEADERNV)(getProcAddr(\"glGetCommandHeaderNV\"))\n\tgpGetCompressedMultiTexImageEXT = (C.GPGETCOMPRESSEDMULTITEXIMAGEEXT)(getProcAddr(\"glGetCompressedMultiTexImageEXT\"))\n\tgpGetCompressedTexImage = (C.GPGETCOMPRESSEDTEXIMAGE)(getProcAddr(\"glGetCompressedTexImage\"))\n\tif gpGetCompressedTexImage == nil {\n\t\treturn errors.New(\"glGetCompressedTexImage\")\n\t}\n\tgpGetCompressedTexImageARB = (C.GPGETCOMPRESSEDTEXIMAGEARB)(getProcAddr(\"glGetCompressedTexImageARB\"))\n\tgpGetCompressedTextureImage = (C.GPGETCOMPRESSEDTEXTUREIMAGE)(getProcAddr(\"glGetCompressedTextureImage\"))\n\tgpGetCompressedTextureImageEXT = (C.GPGETCOMPRESSEDTEXTUREIMAGEEXT)(getProcAddr(\"glGetCompressedTextureImageEXT\"))\n\tgpGetCompressedTextureSubImage = (C.GPGETCOMPRESSEDTEXTURESUBIMAGE)(getProcAddr(\"glGetCompressedTextureSubImage\"))\n\tgpGetConvolutionFilter = (C.GPGETCONVOLUTIONFILTER)(getProcAddr(\"glGetConvolutionFilter\"))\n\tgpGetConvolutionFilterEXT = (C.GPGETCONVOLUTIONFILTEREXT)(getProcAddr(\"glGetConvolutionFilterEXT\"))\n\tgpGetConvolutionParameterfv = (C.GPGETCONVOLUTIONPARAMETERFV)(getProcAddr(\"glGetConvolutionParameterfv\"))\n\tgpGetConvolutionParameterfvEXT = (C.GPGETCONVOLUTIONPARAMETERFVEXT)(getProcAddr(\"glGetConvolutionParameterfvEXT\"))\n\tgpGetConvolutionParameteriv = (C.GPGETCONVOLUTIONPARAMETERIV)(getProcAddr(\"glGetConvolutionParameteriv\"))\n\tgpGetConvolutionParameterivEXT = (C.GPGETCONVOLUTIONPARAMETERIVEXT)(getProcAddr(\"glGetConvolutionParameterivEXT\"))\n\tgpGetConvolutionParameterxvOES = (C.GPGETCONVOLUTIONPARAMETERXVOES)(getProcAddr(\"glGetConvolutionParameterxvOES\"))\n\tgpGetCoverageModulationTableNV = (C.GPGETCOVERAGEMODULATIONTABLENV)(getProcAddr(\"glGetCoverageModulationTableNV\"))\n\tgpGetDebugMessageLog = (C.GPGETDEBUGMESSAGELOG)(getProcAddr(\"glGetDebugMessageLog\"))\n\tif gpGetDebugMessageLog == nil {\n\t\treturn errors.New(\"glGetDebugMessageLog\")\n\t}\n\tgpGetDebugMessageLogAMD = (C.GPGETDEBUGMESSAGELOGAMD)(getProcAddr(\"glGetDebugMessageLogAMD\"))\n\tgpGetDebugMessageLogARB = (C.GPGETDEBUGMESSAGELOGARB)(getProcAddr(\"glGetDebugMessageLogARB\"))\n\tgpGetDebugMessageLogKHR = (C.GPGETDEBUGMESSAGELOGKHR)(getProcAddr(\"glGetDebugMessageLogKHR\"))\n\tgpGetDetailTexFuncSGIS = (C.GPGETDETAILTEXFUNCSGIS)(getProcAddr(\"glGetDetailTexFuncSGIS\"))\n\tgpGetDoubleIndexedvEXT = (C.GPGETDOUBLEINDEXEDVEXT)(getProcAddr(\"glGetDoubleIndexedvEXT\"))\n\tgpGetDoublei_v = (C.GPGETDOUBLEI_V)(getProcAddr(\"glGetDoublei_v\"))\n\tif gpGetDoublei_v == nil {\n\t\treturn errors.New(\"glGetDoublei_v\")\n\t}\n\tgpGetDoublei_vEXT = (C.GPGETDOUBLEI_VEXT)(getProcAddr(\"glGetDoublei_vEXT\"))\n\tgpGetDoublev = (C.GPGETDOUBLEV)(getProcAddr(\"glGetDoublev\"))\n\tif gpGetDoublev == nil {\n\t\treturn errors.New(\"glGetDoublev\")\n\t}\n\tgpGetError = (C.GPGETERROR)(getProcAddr(\"glGetError\"))\n\tif gpGetError == nil {\n\t\treturn errors.New(\"glGetError\")\n\t}\n\tgpGetFenceivNV = (C.GPGETFENCEIVNV)(getProcAddr(\"glGetFenceivNV\"))\n\tgpGetFinalCombinerInputParameterfvNV = (C.GPGETFINALCOMBINERINPUTPARAMETERFVNV)(getProcAddr(\"glGetFinalCombinerInputParameterfvNV\"))\n\tgpGetFinalCombinerInputParameterivNV = (C.GPGETFINALCOMBINERINPUTPARAMETERIVNV)(getProcAddr(\"glGetFinalCombinerInputParameterivNV\"))\n\tgpGetFirstPerfQueryIdINTEL = (C.GPGETFIRSTPERFQUERYIDINTEL)(getProcAddr(\"glGetFirstPerfQueryIdINTEL\"))\n\tgpGetFixedvOES = (C.GPGETFIXEDVOES)(getProcAddr(\"glGetFixedvOES\"))\n\tgpGetFloatIndexedvEXT = (C.GPGETFLOATINDEXEDVEXT)(getProcAddr(\"glGetFloatIndexedvEXT\"))\n\tgpGetFloati_v = (C.GPGETFLOATI_V)(getProcAddr(\"glGetFloati_v\"))\n\tif gpGetFloati_v == nil {\n\t\treturn errors.New(\"glGetFloati_v\")\n\t}\n\tgpGetFloati_vEXT = (C.GPGETFLOATI_VEXT)(getProcAddr(\"glGetFloati_vEXT\"))\n\tgpGetFloatv = (C.GPGETFLOATV)(getProcAddr(\"glGetFloatv\"))\n\tif gpGetFloatv == nil {\n\t\treturn errors.New(\"glGetFloatv\")\n\t}\n\tgpGetFogFuncSGIS = (C.GPGETFOGFUNCSGIS)(getProcAddr(\"glGetFogFuncSGIS\"))\n\tgpGetFragDataIndex = (C.GPGETFRAGDATAINDEX)(getProcAddr(\"glGetFragDataIndex\"))\n\tif gpGetFragDataIndex == nil {\n\t\treturn errors.New(\"glGetFragDataIndex\")\n\t}\n\tgpGetFragDataLocation = (C.GPGETFRAGDATALOCATION)(getProcAddr(\"glGetFragDataLocation\"))\n\tif gpGetFragDataLocation == nil {\n\t\treturn errors.New(\"glGetFragDataLocation\")\n\t}\n\tgpGetFragDataLocationEXT = (C.GPGETFRAGDATALOCATIONEXT)(getProcAddr(\"glGetFragDataLocationEXT\"))\n\tgpGetFragmentLightfvSGIX = (C.GPGETFRAGMENTLIGHTFVSGIX)(getProcAddr(\"glGetFragmentLightfvSGIX\"))\n\tgpGetFragmentLightivSGIX = (C.GPGETFRAGMENTLIGHTIVSGIX)(getProcAddr(\"glGetFragmentLightivSGIX\"))\n\tgpGetFragmentMaterialfvSGIX = (C.GPGETFRAGMENTMATERIALFVSGIX)(getProcAddr(\"glGetFragmentMaterialfvSGIX\"))\n\tgpGetFragmentMaterialivSGIX = (C.GPGETFRAGMENTMATERIALIVSGIX)(getProcAddr(\"glGetFragmentMaterialivSGIX\"))\n\tgpGetFramebufferAttachmentParameteriv = (C.GPGETFRAMEBUFFERATTACHMENTPARAMETERIV)(getProcAddr(\"glGetFramebufferAttachmentParameteriv\"))\n\tif gpGetFramebufferAttachmentParameteriv == nil {\n\t\treturn errors.New(\"glGetFramebufferAttachmentParameteriv\")\n\t}\n\tgpGetFramebufferAttachmentParameterivEXT = (C.GPGETFRAMEBUFFERATTACHMENTPARAMETERIVEXT)(getProcAddr(\"glGetFramebufferAttachmentParameterivEXT\"))\n\tgpGetFramebufferParameterfvAMD = (C.GPGETFRAMEBUFFERPARAMETERFVAMD)(getProcAddr(\"glGetFramebufferParameterfvAMD\"))\n\tgpGetFramebufferParameteriv = (C.GPGETFRAMEBUFFERPARAMETERIV)(getProcAddr(\"glGetFramebufferParameteriv\"))\n\tif gpGetFramebufferParameteriv == nil {\n\t\treturn errors.New(\"glGetFramebufferParameteriv\")\n\t}\n\tgpGetFramebufferParameterivEXT = (C.GPGETFRAMEBUFFERPARAMETERIVEXT)(getProcAddr(\"glGetFramebufferParameterivEXT\"))\n\tgpGetFramebufferParameterivMESA = (C.GPGETFRAMEBUFFERPARAMETERIVMESA)(getProcAddr(\"glGetFramebufferParameterivMESA\"))\n\tgpGetGraphicsResetStatus = (C.GPGETGRAPHICSRESETSTATUS)(getProcAddr(\"glGetGraphicsResetStatus\"))\n\tgpGetGraphicsResetStatusARB = (C.GPGETGRAPHICSRESETSTATUSARB)(getProcAddr(\"glGetGraphicsResetStatusARB\"))\n\tgpGetGraphicsResetStatusKHR = (C.GPGETGRAPHICSRESETSTATUSKHR)(getProcAddr(\"glGetGraphicsResetStatusKHR\"))\n\tgpGetHandleARB = (C.GPGETHANDLEARB)(getProcAddr(\"glGetHandleARB\"))\n\tgpGetHistogram = (C.GPGETHISTOGRAM)(getProcAddr(\"glGetHistogram\"))\n\tgpGetHistogramEXT = (C.GPGETHISTOGRAMEXT)(getProcAddr(\"glGetHistogramEXT\"))\n\tgpGetHistogramParameterfv = (C.GPGETHISTOGRAMPARAMETERFV)(getProcAddr(\"glGetHistogramParameterfv\"))\n\tgpGetHistogramParameterfvEXT = (C.GPGETHISTOGRAMPARAMETERFVEXT)(getProcAddr(\"glGetHistogramParameterfvEXT\"))\n\tgpGetHistogramParameteriv = (C.GPGETHISTOGRAMPARAMETERIV)(getProcAddr(\"glGetHistogramParameteriv\"))\n\tgpGetHistogramParameterivEXT = (C.GPGETHISTOGRAMPARAMETERIVEXT)(getProcAddr(\"glGetHistogramParameterivEXT\"))\n\tgpGetHistogramParameterxvOES = (C.GPGETHISTOGRAMPARAMETERXVOES)(getProcAddr(\"glGetHistogramParameterxvOES\"))\n\tgpGetImageHandleARB = (C.GPGETIMAGEHANDLEARB)(getProcAddr(\"glGetImageHandleARB\"))\n\tgpGetImageHandleNV = (C.GPGETIMAGEHANDLENV)(getProcAddr(\"glGetImageHandleNV\"))\n\tgpGetImageTransformParameterfvHP = (C.GPGETIMAGETRANSFORMPARAMETERFVHP)(getProcAddr(\"glGetImageTransformParameterfvHP\"))\n\tgpGetImageTransformParameterivHP = (C.GPGETIMAGETRANSFORMPARAMETERIVHP)(getProcAddr(\"glGetImageTransformParameterivHP\"))\n\tgpGetInfoLogARB = (C.GPGETINFOLOGARB)(getProcAddr(\"glGetInfoLogARB\"))\n\tgpGetInstrumentsSGIX = (C.GPGETINSTRUMENTSSGIX)(getProcAddr(\"glGetInstrumentsSGIX\"))\n\tgpGetInteger64i_v = (C.GPGETINTEGER64I_V)(getProcAddr(\"glGetInteger64i_v\"))\n\tif gpGetInteger64i_v == nil {\n\t\treturn errors.New(\"glGetInteger64i_v\")\n\t}\n\tgpGetInteger64v = (C.GPGETINTEGER64V)(getProcAddr(\"glGetInteger64v\"))\n\tif gpGetInteger64v == nil {\n\t\treturn errors.New(\"glGetInteger64v\")\n\t}\n\tgpGetIntegerIndexedvEXT = (C.GPGETINTEGERINDEXEDVEXT)(getProcAddr(\"glGetIntegerIndexedvEXT\"))\n\tgpGetIntegeri_v = (C.GPGETINTEGERI_V)(getProcAddr(\"glGetIntegeri_v\"))\n\tif gpGetIntegeri_v == nil {\n\t\treturn errors.New(\"glGetIntegeri_v\")\n\t}\n\tgpGetIntegerui64i_vNV = (C.GPGETINTEGERUI64I_VNV)(getProcAddr(\"glGetIntegerui64i_vNV\"))\n\tgpGetIntegerui64vNV = (C.GPGETINTEGERUI64VNV)(getProcAddr(\"glGetIntegerui64vNV\"))\n\tgpGetIntegerv = (C.GPGETINTEGERV)(getProcAddr(\"glGetIntegerv\"))\n\tif gpGetIntegerv == nil {\n\t\treturn errors.New(\"glGetIntegerv\")\n\t}\n\tgpGetInternalformatSampleivNV = (C.GPGETINTERNALFORMATSAMPLEIVNV)(getProcAddr(\"glGetInternalformatSampleivNV\"))\n\tgpGetInternalformati64v = (C.GPGETINTERNALFORMATI64V)(getProcAddr(\"glGetInternalformati64v\"))\n\tif gpGetInternalformati64v == nil {\n\t\treturn errors.New(\"glGetInternalformati64v\")\n\t}\n\tgpGetInternalformativ = (C.GPGETINTERNALFORMATIV)(getProcAddr(\"glGetInternalformativ\"))\n\tif gpGetInternalformativ == nil {\n\t\treturn errors.New(\"glGetInternalformativ\")\n\t}\n\tgpGetInvariantBooleanvEXT = (C.GPGETINVARIANTBOOLEANVEXT)(getProcAddr(\"glGetInvariantBooleanvEXT\"))\n\tgpGetInvariantFloatvEXT = (C.GPGETINVARIANTFLOATVEXT)(getProcAddr(\"glGetInvariantFloatvEXT\"))\n\tgpGetInvariantIntegervEXT = (C.GPGETINVARIANTINTEGERVEXT)(getProcAddr(\"glGetInvariantIntegervEXT\"))\n\tgpGetLightfv = (C.GPGETLIGHTFV)(getProcAddr(\"glGetLightfv\"))\n\tif gpGetLightfv == nil {\n\t\treturn errors.New(\"glGetLightfv\")\n\t}\n\tgpGetLightiv = (C.GPGETLIGHTIV)(getProcAddr(\"glGetLightiv\"))\n\tif gpGetLightiv == nil {\n\t\treturn errors.New(\"glGetLightiv\")\n\t}\n\tgpGetLightxOES = (C.GPGETLIGHTXOES)(getProcAddr(\"glGetLightxOES\"))\n\tgpGetLightxvOES = (C.GPGETLIGHTXVOES)(getProcAddr(\"glGetLightxvOES\"))\n\tgpGetListParameterfvSGIX = (C.GPGETLISTPARAMETERFVSGIX)(getProcAddr(\"glGetListParameterfvSGIX\"))\n\tgpGetListParameterivSGIX = (C.GPGETLISTPARAMETERIVSGIX)(getProcAddr(\"glGetListParameterivSGIX\"))\n\tgpGetLocalConstantBooleanvEXT = (C.GPGETLOCALCONSTANTBOOLEANVEXT)(getProcAddr(\"glGetLocalConstantBooleanvEXT\"))\n\tgpGetLocalConstantFloatvEXT = (C.GPGETLOCALCONSTANTFLOATVEXT)(getProcAddr(\"glGetLocalConstantFloatvEXT\"))\n\tgpGetLocalConstantIntegervEXT = (C.GPGETLOCALCONSTANTINTEGERVEXT)(getProcAddr(\"glGetLocalConstantIntegervEXT\"))\n\tgpGetMapAttribParameterfvNV = (C.GPGETMAPATTRIBPARAMETERFVNV)(getProcAddr(\"glGetMapAttribParameterfvNV\"))\n\tgpGetMapAttribParameterivNV = (C.GPGETMAPATTRIBPARAMETERIVNV)(getProcAddr(\"glGetMapAttribParameterivNV\"))\n\tgpGetMapControlPointsNV = (C.GPGETMAPCONTROLPOINTSNV)(getProcAddr(\"glGetMapControlPointsNV\"))\n\tgpGetMapParameterfvNV = (C.GPGETMAPPARAMETERFVNV)(getProcAddr(\"glGetMapParameterfvNV\"))\n\tgpGetMapParameterivNV = (C.GPGETMAPPARAMETERIVNV)(getProcAddr(\"glGetMapParameterivNV\"))\n\tgpGetMapdv = (C.GPGETMAPDV)(getProcAddr(\"glGetMapdv\"))\n\tif gpGetMapdv == nil {\n\t\treturn errors.New(\"glGetMapdv\")\n\t}\n\tgpGetMapfv = (C.GPGETMAPFV)(getProcAddr(\"glGetMapfv\"))\n\tif gpGetMapfv == nil {\n\t\treturn errors.New(\"glGetMapfv\")\n\t}\n\tgpGetMapiv = (C.GPGETMAPIV)(getProcAddr(\"glGetMapiv\"))\n\tif gpGetMapiv == nil {\n\t\treturn errors.New(\"glGetMapiv\")\n\t}\n\tgpGetMapxvOES = (C.GPGETMAPXVOES)(getProcAddr(\"glGetMapxvOES\"))\n\tgpGetMaterialfv = (C.GPGETMATERIALFV)(getProcAddr(\"glGetMaterialfv\"))\n\tif gpGetMaterialfv == nil {\n\t\treturn errors.New(\"glGetMaterialfv\")\n\t}\n\tgpGetMaterialiv = (C.GPGETMATERIALIV)(getProcAddr(\"glGetMaterialiv\"))\n\tif gpGetMaterialiv == nil {\n\t\treturn errors.New(\"glGetMaterialiv\")\n\t}\n\tgpGetMaterialxOES = (C.GPGETMATERIALXOES)(getProcAddr(\"glGetMaterialxOES\"))\n\tgpGetMaterialxvOES = (C.GPGETMATERIALXVOES)(getProcAddr(\"glGetMaterialxvOES\"))\n\tgpGetMemoryObjectDetachedResourcesuivNV = (C.GPGETMEMORYOBJECTDETACHEDRESOURCESUIVNV)(getProcAddr(\"glGetMemoryObjectDetachedResourcesuivNV\"))\n\tgpGetMemoryObjectParameterivEXT = (C.GPGETMEMORYOBJECTPARAMETERIVEXT)(getProcAddr(\"glGetMemoryObjectParameterivEXT\"))\n\tgpGetMinmax = (C.GPGETMINMAX)(getProcAddr(\"glGetMinmax\"))\n\tgpGetMinmaxEXT = (C.GPGETMINMAXEXT)(getProcAddr(\"glGetMinmaxEXT\"))\n\tgpGetMinmaxParameterfv = (C.GPGETMINMAXPARAMETERFV)(getProcAddr(\"glGetMinmaxParameterfv\"))\n\tgpGetMinmaxParameterfvEXT = (C.GPGETMINMAXPARAMETERFVEXT)(getProcAddr(\"glGetMinmaxParameterfvEXT\"))\n\tgpGetMinmaxParameteriv = (C.GPGETMINMAXPARAMETERIV)(getProcAddr(\"glGetMinmaxParameteriv\"))\n\tgpGetMinmaxParameterivEXT = (C.GPGETMINMAXPARAMETERIVEXT)(getProcAddr(\"glGetMinmaxParameterivEXT\"))\n\tgpGetMultiTexEnvfvEXT = (C.GPGETMULTITEXENVFVEXT)(getProcAddr(\"glGetMultiTexEnvfvEXT\"))\n\tgpGetMultiTexEnvivEXT = (C.GPGETMULTITEXENVIVEXT)(getProcAddr(\"glGetMultiTexEnvivEXT\"))\n\tgpGetMultiTexGendvEXT = (C.GPGETMULTITEXGENDVEXT)(getProcAddr(\"glGetMultiTexGendvEXT\"))\n\tgpGetMultiTexGenfvEXT = (C.GPGETMULTITEXGENFVEXT)(getProcAddr(\"glGetMultiTexGenfvEXT\"))\n\tgpGetMultiTexGenivEXT = (C.GPGETMULTITEXGENIVEXT)(getProcAddr(\"glGetMultiTexGenivEXT\"))\n\tgpGetMultiTexImageEXT = (C.GPGETMULTITEXIMAGEEXT)(getProcAddr(\"glGetMultiTexImageEXT\"))\n\tgpGetMultiTexLevelParameterfvEXT = (C.GPGETMULTITEXLEVELPARAMETERFVEXT)(getProcAddr(\"glGetMultiTexLevelParameterfvEXT\"))\n\tgpGetMultiTexLevelParameterivEXT = (C.GPGETMULTITEXLEVELPARAMETERIVEXT)(getProcAddr(\"glGetMultiTexLevelParameterivEXT\"))\n\tgpGetMultiTexParameterIivEXT = (C.GPGETMULTITEXPARAMETERIIVEXT)(getProcAddr(\"glGetMultiTexParameterIivEXT\"))\n\tgpGetMultiTexParameterIuivEXT = (C.GPGETMULTITEXPARAMETERIUIVEXT)(getProcAddr(\"glGetMultiTexParameterIuivEXT\"))\n\tgpGetMultiTexParameterfvEXT = (C.GPGETMULTITEXPARAMETERFVEXT)(getProcAddr(\"glGetMultiTexParameterfvEXT\"))\n\tgpGetMultiTexParameterivEXT = (C.GPGETMULTITEXPARAMETERIVEXT)(getProcAddr(\"glGetMultiTexParameterivEXT\"))\n\tgpGetMultisamplefv = (C.GPGETMULTISAMPLEFV)(getProcAddr(\"glGetMultisamplefv\"))\n\tif gpGetMultisamplefv == nil {\n\t\treturn errors.New(\"glGetMultisamplefv\")\n\t}\n\tgpGetMultisamplefvNV = (C.GPGETMULTISAMPLEFVNV)(getProcAddr(\"glGetMultisamplefvNV\"))\n\tgpGetNamedBufferParameteri64v = (C.GPGETNAMEDBUFFERPARAMETERI64V)(getProcAddr(\"glGetNamedBufferParameteri64v\"))\n\tgpGetNamedBufferParameteriv = (C.GPGETNAMEDBUFFERPARAMETERIV)(getProcAddr(\"glGetNamedBufferParameteriv\"))\n\tgpGetNamedBufferParameterivEXT = (C.GPGETNAMEDBUFFERPARAMETERIVEXT)(getProcAddr(\"glGetNamedBufferParameterivEXT\"))\n\tgpGetNamedBufferParameterui64vNV = (C.GPGETNAMEDBUFFERPARAMETERUI64VNV)(getProcAddr(\"glGetNamedBufferParameterui64vNV\"))\n\tgpGetNamedBufferPointerv = (C.GPGETNAMEDBUFFERPOINTERV)(getProcAddr(\"glGetNamedBufferPointerv\"))\n\tgpGetNamedBufferPointervEXT = (C.GPGETNAMEDBUFFERPOINTERVEXT)(getProcAddr(\"glGetNamedBufferPointervEXT\"))\n\tgpGetNamedBufferSubData = (C.GPGETNAMEDBUFFERSUBDATA)(getProcAddr(\"glGetNamedBufferSubData\"))\n\tgpGetNamedBufferSubDataEXT = (C.GPGETNAMEDBUFFERSUBDATAEXT)(getProcAddr(\"glGetNamedBufferSubDataEXT\"))\n\tgpGetNamedFramebufferAttachmentParameteriv = (C.GPGETNAMEDFRAMEBUFFERATTACHMENTPARAMETERIV)(getProcAddr(\"glGetNamedFramebufferAttachmentParameteriv\"))\n\tgpGetNamedFramebufferAttachmentParameterivEXT = (C.GPGETNAMEDFRAMEBUFFERATTACHMENTPARAMETERIVEXT)(getProcAddr(\"glGetNamedFramebufferAttachmentParameterivEXT\"))\n\tgpGetNamedFramebufferParameterfvAMD = (C.GPGETNAMEDFRAMEBUFFERPARAMETERFVAMD)(getProcAddr(\"glGetNamedFramebufferParameterfvAMD\"))\n\tgpGetNamedFramebufferParameteriv = (C.GPGETNAMEDFRAMEBUFFERPARAMETERIV)(getProcAddr(\"glGetNamedFramebufferParameteriv\"))\n\tgpGetNamedFramebufferParameterivEXT = (C.GPGETNAMEDFRAMEBUFFERPARAMETERIVEXT)(getProcAddr(\"glGetNamedFramebufferParameterivEXT\"))\n\tgpGetNamedProgramLocalParameterIivEXT = (C.GPGETNAMEDPROGRAMLOCALPARAMETERIIVEXT)(getProcAddr(\"glGetNamedProgramLocalParameterIivEXT\"))\n\tgpGetNamedProgramLocalParameterIuivEXT = (C.GPGETNAMEDPROGRAMLOCALPARAMETERIUIVEXT)(getProcAddr(\"glGetNamedProgramLocalParameterIuivEXT\"))\n\tgpGetNamedProgramLocalParameterdvEXT = (C.GPGETNAMEDPROGRAMLOCALPARAMETERDVEXT)(getProcAddr(\"glGetNamedProgramLocalParameterdvEXT\"))\n\tgpGetNamedProgramLocalParameterfvEXT = (C.GPGETNAMEDPROGRAMLOCALPARAMETERFVEXT)(getProcAddr(\"glGetNamedProgramLocalParameterfvEXT\"))\n\tgpGetNamedProgramStringEXT = (C.GPGETNAMEDPROGRAMSTRINGEXT)(getProcAddr(\"glGetNamedProgramStringEXT\"))\n\tgpGetNamedProgramivEXT = (C.GPGETNAMEDPROGRAMIVEXT)(getProcAddr(\"glGetNamedProgramivEXT\"))\n\tgpGetNamedRenderbufferParameteriv = (C.GPGETNAMEDRENDERBUFFERPARAMETERIV)(getProcAddr(\"glGetNamedRenderbufferParameteriv\"))\n\tgpGetNamedRenderbufferParameterivEXT = (C.GPGETNAMEDRENDERBUFFERPARAMETERIVEXT)(getProcAddr(\"glGetNamedRenderbufferParameterivEXT\"))\n\tgpGetNamedStringARB = (C.GPGETNAMEDSTRINGARB)(getProcAddr(\"glGetNamedStringARB\"))\n\tgpGetNamedStringivARB = (C.GPGETNAMEDSTRINGIVARB)(getProcAddr(\"glGetNamedStringivARB\"))\n\tgpGetNextPerfQueryIdINTEL = (C.GPGETNEXTPERFQUERYIDINTEL)(getProcAddr(\"glGetNextPerfQueryIdINTEL\"))\n\tgpGetObjectBufferfvATI = (C.GPGETOBJECTBUFFERFVATI)(getProcAddr(\"glGetObjectBufferfvATI\"))\n\tgpGetObjectBufferivATI = (C.GPGETOBJECTBUFFERIVATI)(getProcAddr(\"glGetObjectBufferivATI\"))\n\tgpGetObjectLabel = (C.GPGETOBJECTLABEL)(getProcAddr(\"glGetObjectLabel\"))\n\tif gpGetObjectLabel == nil {\n\t\treturn errors.New(\"glGetObjectLabel\")\n\t}\n\tgpGetObjectLabelEXT = (C.GPGETOBJECTLABELEXT)(getProcAddr(\"glGetObjectLabelEXT\"))\n\tgpGetObjectLabelKHR = (C.GPGETOBJECTLABELKHR)(getProcAddr(\"glGetObjectLabelKHR\"))\n\tgpGetObjectParameterfvARB = (C.GPGETOBJECTPARAMETERFVARB)(getProcAddr(\"glGetObjectParameterfvARB\"))\n\tgpGetObjectParameterivAPPLE = (C.GPGETOBJECTPARAMETERIVAPPLE)(getProcAddr(\"glGetObjectParameterivAPPLE\"))\n\tgpGetObjectParameterivARB = (C.GPGETOBJECTPARAMETERIVARB)(getProcAddr(\"glGetObjectParameterivARB\"))\n\tgpGetObjectPtrLabel = (C.GPGETOBJECTPTRLABEL)(getProcAddr(\"glGetObjectPtrLabel\"))\n\tif gpGetObjectPtrLabel == nil {\n\t\treturn errors.New(\"glGetObjectPtrLabel\")\n\t}\n\tgpGetObjectPtrLabelKHR = (C.GPGETOBJECTPTRLABELKHR)(getProcAddr(\"glGetObjectPtrLabelKHR\"))\n\tgpGetOcclusionQueryivNV = (C.GPGETOCCLUSIONQUERYIVNV)(getProcAddr(\"glGetOcclusionQueryivNV\"))\n\tgpGetOcclusionQueryuivNV = (C.GPGETOCCLUSIONQUERYUIVNV)(getProcAddr(\"glGetOcclusionQueryuivNV\"))\n\tgpGetPathColorGenfvNV = (C.GPGETPATHCOLORGENFVNV)(getProcAddr(\"glGetPathColorGenfvNV\"))\n\tgpGetPathColorGenivNV = (C.GPGETPATHCOLORGENIVNV)(getProcAddr(\"glGetPathColorGenivNV\"))\n\tgpGetPathCommandsNV = (C.GPGETPATHCOMMANDSNV)(getProcAddr(\"glGetPathCommandsNV\"))\n\tgpGetPathCoordsNV = (C.GPGETPATHCOORDSNV)(getProcAddr(\"glGetPathCoordsNV\"))\n\tgpGetPathDashArrayNV = (C.GPGETPATHDASHARRAYNV)(getProcAddr(\"glGetPathDashArrayNV\"))\n\tgpGetPathLengthNV = (C.GPGETPATHLENGTHNV)(getProcAddr(\"glGetPathLengthNV\"))\n\tgpGetPathMetricRangeNV = (C.GPGETPATHMETRICRANGENV)(getProcAddr(\"glGetPathMetricRangeNV\"))\n\tgpGetPathMetricsNV = (C.GPGETPATHMETRICSNV)(getProcAddr(\"glGetPathMetricsNV\"))\n\tgpGetPathParameterfvNV = (C.GPGETPATHPARAMETERFVNV)(getProcAddr(\"glGetPathParameterfvNV\"))\n\tgpGetPathParameterivNV = (C.GPGETPATHPARAMETERIVNV)(getProcAddr(\"glGetPathParameterivNV\"))\n\tgpGetPathSpacingNV = (C.GPGETPATHSPACINGNV)(getProcAddr(\"glGetPathSpacingNV\"))\n\tgpGetPathTexGenfvNV = (C.GPGETPATHTEXGENFVNV)(getProcAddr(\"glGetPathTexGenfvNV\"))\n\tgpGetPathTexGenivNV = (C.GPGETPATHTEXGENIVNV)(getProcAddr(\"glGetPathTexGenivNV\"))\n\tgpGetPerfCounterInfoINTEL = (C.GPGETPERFCOUNTERINFOINTEL)(getProcAddr(\"glGetPerfCounterInfoINTEL\"))\n\tgpGetPerfMonitorCounterDataAMD = (C.GPGETPERFMONITORCOUNTERDATAAMD)(getProcAddr(\"glGetPerfMonitorCounterDataAMD\"))\n\tgpGetPerfMonitorCounterInfoAMD = (C.GPGETPERFMONITORCOUNTERINFOAMD)(getProcAddr(\"glGetPerfMonitorCounterInfoAMD\"))\n\tgpGetPerfMonitorCounterStringAMD = (C.GPGETPERFMONITORCOUNTERSTRINGAMD)(getProcAddr(\"glGetPerfMonitorCounterStringAMD\"))\n\tgpGetPerfMonitorCountersAMD = (C.GPGETPERFMONITORCOUNTERSAMD)(getProcAddr(\"glGetPerfMonitorCountersAMD\"))\n\tgpGetPerfMonitorGroupStringAMD = (C.GPGETPERFMONITORGROUPSTRINGAMD)(getProcAddr(\"glGetPerfMonitorGroupStringAMD\"))\n\tgpGetPerfMonitorGroupsAMD = (C.GPGETPERFMONITORGROUPSAMD)(getProcAddr(\"glGetPerfMonitorGroupsAMD\"))\n\tgpGetPerfQueryDataINTEL = (C.GPGETPERFQUERYDATAINTEL)(getProcAddr(\"glGetPerfQueryDataINTEL\"))\n\tgpGetPerfQueryIdByNameINTEL = (C.GPGETPERFQUERYIDBYNAMEINTEL)(getProcAddr(\"glGetPerfQueryIdByNameINTEL\"))\n\tgpGetPerfQueryInfoINTEL = (C.GPGETPERFQUERYINFOINTEL)(getProcAddr(\"glGetPerfQueryInfoINTEL\"))\n\tgpGetPixelMapfv = (C.GPGETPIXELMAPFV)(getProcAddr(\"glGetPixelMapfv\"))\n\tif gpGetPixelMapfv == nil {\n\t\treturn errors.New(\"glGetPixelMapfv\")\n\t}\n\tgpGetPixelMapuiv = (C.GPGETPIXELMAPUIV)(getProcAddr(\"glGetPixelMapuiv\"))\n\tif gpGetPixelMapuiv == nil {\n\t\treturn errors.New(\"glGetPixelMapuiv\")\n\t}\n\tgpGetPixelMapusv = (C.GPGETPIXELMAPUSV)(getProcAddr(\"glGetPixelMapusv\"))\n\tif gpGetPixelMapusv == nil {\n\t\treturn errors.New(\"glGetPixelMapusv\")\n\t}\n\tgpGetPixelMapxv = (C.GPGETPIXELMAPXV)(getProcAddr(\"glGetPixelMapxv\"))\n\tgpGetPixelTexGenParameterfvSGIS = (C.GPGETPIXELTEXGENPARAMETERFVSGIS)(getProcAddr(\"glGetPixelTexGenParameterfvSGIS\"))\n\tgpGetPixelTexGenParameterivSGIS = (C.GPGETPIXELTEXGENPARAMETERIVSGIS)(getProcAddr(\"glGetPixelTexGenParameterivSGIS\"))\n\tgpGetPixelTransformParameterfvEXT = (C.GPGETPIXELTRANSFORMPARAMETERFVEXT)(getProcAddr(\"glGetPixelTransformParameterfvEXT\"))\n\tgpGetPixelTransformParameterivEXT = (C.GPGETPIXELTRANSFORMPARAMETERIVEXT)(getProcAddr(\"glGetPixelTransformParameterivEXT\"))\n\tgpGetPointerIndexedvEXT = (C.GPGETPOINTERINDEXEDVEXT)(getProcAddr(\"glGetPointerIndexedvEXT\"))\n\tgpGetPointeri_vEXT = (C.GPGETPOINTERI_VEXT)(getProcAddr(\"glGetPointeri_vEXT\"))\n\tgpGetPointerv = (C.GPGETPOINTERV)(getProcAddr(\"glGetPointerv\"))\n\tif gpGetPointerv == nil {\n\t\treturn errors.New(\"glGetPointerv\")\n\t}\n\tgpGetPointervEXT = (C.GPGETPOINTERVEXT)(getProcAddr(\"glGetPointervEXT\"))\n\tgpGetPointervKHR = (C.GPGETPOINTERVKHR)(getProcAddr(\"glGetPointervKHR\"))\n\tgpGetPolygonStipple = (C.GPGETPOLYGONSTIPPLE)(getProcAddr(\"glGetPolygonStipple\"))\n\tif gpGetPolygonStipple == nil {\n\t\treturn errors.New(\"glGetPolygonStipple\")\n\t}\n\tgpGetProgramBinary = (C.GPGETPROGRAMBINARY)(getProcAddr(\"glGetProgramBinary\"))\n\tif gpGetProgramBinary == nil {\n\t\treturn errors.New(\"glGetProgramBinary\")\n\t}\n\tgpGetProgramEnvParameterIivNV = (C.GPGETPROGRAMENVPARAMETERIIVNV)(getProcAddr(\"glGetProgramEnvParameterIivNV\"))\n\tgpGetProgramEnvParameterIuivNV = (C.GPGETPROGRAMENVPARAMETERIUIVNV)(getProcAddr(\"glGetProgramEnvParameterIuivNV\"))\n\tgpGetProgramEnvParameterdvARB = (C.GPGETPROGRAMENVPARAMETERDVARB)(getProcAddr(\"glGetProgramEnvParameterdvARB\"))\n\tgpGetProgramEnvParameterfvARB = (C.GPGETPROGRAMENVPARAMETERFVARB)(getProcAddr(\"glGetProgramEnvParameterfvARB\"))\n\tgpGetProgramInfoLog = (C.GPGETPROGRAMINFOLOG)(getProcAddr(\"glGetProgramInfoLog\"))\n\tif gpGetProgramInfoLog == nil {\n\t\treturn errors.New(\"glGetProgramInfoLog\")\n\t}\n\tgpGetProgramInterfaceiv = (C.GPGETPROGRAMINTERFACEIV)(getProcAddr(\"glGetProgramInterfaceiv\"))\n\tif gpGetProgramInterfaceiv == nil {\n\t\treturn errors.New(\"glGetProgramInterfaceiv\")\n\t}\n\tgpGetProgramLocalParameterIivNV = (C.GPGETPROGRAMLOCALPARAMETERIIVNV)(getProcAddr(\"glGetProgramLocalParameterIivNV\"))\n\tgpGetProgramLocalParameterIuivNV = (C.GPGETPROGRAMLOCALPARAMETERIUIVNV)(getProcAddr(\"glGetProgramLocalParameterIuivNV\"))\n\tgpGetProgramLocalParameterdvARB = (C.GPGETPROGRAMLOCALPARAMETERDVARB)(getProcAddr(\"glGetProgramLocalParameterdvARB\"))\n\tgpGetProgramLocalParameterfvARB = (C.GPGETPROGRAMLOCALPARAMETERFVARB)(getProcAddr(\"glGetProgramLocalParameterfvARB\"))\n\tgpGetProgramNamedParameterdvNV = (C.GPGETPROGRAMNAMEDPARAMETERDVNV)(getProcAddr(\"glGetProgramNamedParameterdvNV\"))\n\tgpGetProgramNamedParameterfvNV = (C.GPGETPROGRAMNAMEDPARAMETERFVNV)(getProcAddr(\"glGetProgramNamedParameterfvNV\"))\n\tgpGetProgramParameterdvNV = (C.GPGETPROGRAMPARAMETERDVNV)(getProcAddr(\"glGetProgramParameterdvNV\"))\n\tgpGetProgramParameterfvNV = (C.GPGETPROGRAMPARAMETERFVNV)(getProcAddr(\"glGetProgramParameterfvNV\"))\n\tgpGetProgramPipelineInfoLog = (C.GPGETPROGRAMPIPELINEINFOLOG)(getProcAddr(\"glGetProgramPipelineInfoLog\"))\n\tif gpGetProgramPipelineInfoLog == nil {\n\t\treturn errors.New(\"glGetProgramPipelineInfoLog\")\n\t}\n\tgpGetProgramPipelineInfoLogEXT = (C.GPGETPROGRAMPIPELINEINFOLOGEXT)(getProcAddr(\"glGetProgramPipelineInfoLogEXT\"))\n\tgpGetProgramPipelineiv = (C.GPGETPROGRAMPIPELINEIV)(getProcAddr(\"glGetProgramPipelineiv\"))\n\tif gpGetProgramPipelineiv == nil {\n\t\treturn errors.New(\"glGetProgramPipelineiv\")\n\t}\n\tgpGetProgramPipelineivEXT = (C.GPGETPROGRAMPIPELINEIVEXT)(getProcAddr(\"glGetProgramPipelineivEXT\"))\n\tgpGetProgramResourceIndex = (C.GPGETPROGRAMRESOURCEINDEX)(getProcAddr(\"glGetProgramResourceIndex\"))\n\tif gpGetProgramResourceIndex == nil {\n\t\treturn errors.New(\"glGetProgramResourceIndex\")\n\t}\n\tgpGetProgramResourceLocation = (C.GPGETPROGRAMRESOURCELOCATION)(getProcAddr(\"glGetProgramResourceLocation\"))\n\tif gpGetProgramResourceLocation == nil {\n\t\treturn errors.New(\"glGetProgramResourceLocation\")\n\t}\n\tgpGetProgramResourceLocationIndex = (C.GPGETPROGRAMRESOURCELOCATIONINDEX)(getProcAddr(\"glGetProgramResourceLocationIndex\"))\n\tif gpGetProgramResourceLocationIndex == nil {\n\t\treturn errors.New(\"glGetProgramResourceLocationIndex\")\n\t}\n\tgpGetProgramResourceName = (C.GPGETPROGRAMRESOURCENAME)(getProcAddr(\"glGetProgramResourceName\"))\n\tif gpGetProgramResourceName == nil {\n\t\treturn errors.New(\"glGetProgramResourceName\")\n\t}\n\tgpGetProgramResourcefvNV = (C.GPGETPROGRAMRESOURCEFVNV)(getProcAddr(\"glGetProgramResourcefvNV\"))\n\tgpGetProgramResourceiv = (C.GPGETPROGRAMRESOURCEIV)(getProcAddr(\"glGetProgramResourceiv\"))\n\tif gpGetProgramResourceiv == nil {\n\t\treturn errors.New(\"glGetProgramResourceiv\")\n\t}\n\tgpGetProgramStageiv = (C.GPGETPROGRAMSTAGEIV)(getProcAddr(\"glGetProgramStageiv\"))\n\tif gpGetProgramStageiv == nil {\n\t\treturn errors.New(\"glGetProgramStageiv\")\n\t}\n\tgpGetProgramStringARB = (C.GPGETPROGRAMSTRINGARB)(getProcAddr(\"glGetProgramStringARB\"))\n\tgpGetProgramStringNV = (C.GPGETPROGRAMSTRINGNV)(getProcAddr(\"glGetProgramStringNV\"))\n\tgpGetProgramSubroutineParameteruivNV = (C.GPGETPROGRAMSUBROUTINEPARAMETERUIVNV)(getProcAddr(\"glGetProgramSubroutineParameteruivNV\"))\n\tgpGetProgramiv = (C.GPGETPROGRAMIV)(getProcAddr(\"glGetProgramiv\"))\n\tif gpGetProgramiv == nil {\n\t\treturn errors.New(\"glGetProgramiv\")\n\t}\n\tgpGetProgramivARB = (C.GPGETPROGRAMIVARB)(getProcAddr(\"glGetProgramivARB\"))\n\tgpGetProgramivNV = (C.GPGETPROGRAMIVNV)(getProcAddr(\"glGetProgramivNV\"))\n\tgpGetQueryBufferObjecti64v = (C.GPGETQUERYBUFFEROBJECTI64V)(getProcAddr(\"glGetQueryBufferObjecti64v\"))\n\tgpGetQueryBufferObjectiv = (C.GPGETQUERYBUFFEROBJECTIV)(getProcAddr(\"glGetQueryBufferObjectiv\"))\n\tgpGetQueryBufferObjectui64v = (C.GPGETQUERYBUFFEROBJECTUI64V)(getProcAddr(\"glGetQueryBufferObjectui64v\"))\n\tgpGetQueryBufferObjectuiv = (C.GPGETQUERYBUFFEROBJECTUIV)(getProcAddr(\"glGetQueryBufferObjectuiv\"))\n\tgpGetQueryIndexediv = (C.GPGETQUERYINDEXEDIV)(getProcAddr(\"glGetQueryIndexediv\"))\n\tif gpGetQueryIndexediv == nil {\n\t\treturn errors.New(\"glGetQueryIndexediv\")\n\t}\n\tgpGetQueryObjecti64v = (C.GPGETQUERYOBJECTI64V)(getProcAddr(\"glGetQueryObjecti64v\"))\n\tif gpGetQueryObjecti64v == nil {\n\t\treturn errors.New(\"glGetQueryObjecti64v\")\n\t}\n\tgpGetQueryObjecti64vEXT = (C.GPGETQUERYOBJECTI64VEXT)(getProcAddr(\"glGetQueryObjecti64vEXT\"))\n\tgpGetQueryObjectiv = (C.GPGETQUERYOBJECTIV)(getProcAddr(\"glGetQueryObjectiv\"))\n\tif gpGetQueryObjectiv == nil {\n\t\treturn errors.New(\"glGetQueryObjectiv\")\n\t}\n\tgpGetQueryObjectivARB = (C.GPGETQUERYOBJECTIVARB)(getProcAddr(\"glGetQueryObjectivARB\"))\n\tgpGetQueryObjectui64v = (C.GPGETQUERYOBJECTUI64V)(getProcAddr(\"glGetQueryObjectui64v\"))\n\tif gpGetQueryObjectui64v == nil {\n\t\treturn errors.New(\"glGetQueryObjectui64v\")\n\t}\n\tgpGetQueryObjectui64vEXT = (C.GPGETQUERYOBJECTUI64VEXT)(getProcAddr(\"glGetQueryObjectui64vEXT\"))\n\tgpGetQueryObjectuiv = (C.GPGETQUERYOBJECTUIV)(getProcAddr(\"glGetQueryObjectuiv\"))\n\tif gpGetQueryObjectuiv == nil {\n\t\treturn errors.New(\"glGetQueryObjectuiv\")\n\t}\n\tgpGetQueryObjectuivARB = (C.GPGETQUERYOBJECTUIVARB)(getProcAddr(\"glGetQueryObjectuivARB\"))\n\tgpGetQueryiv = (C.GPGETQUERYIV)(getProcAddr(\"glGetQueryiv\"))\n\tif gpGetQueryiv == nil {\n\t\treturn errors.New(\"glGetQueryiv\")\n\t}\n\tgpGetQueryivARB = (C.GPGETQUERYIVARB)(getProcAddr(\"glGetQueryivARB\"))\n\tgpGetRenderbufferParameteriv = (C.GPGETRENDERBUFFERPARAMETERIV)(getProcAddr(\"glGetRenderbufferParameteriv\"))\n\tif gpGetRenderbufferParameteriv == nil {\n\t\treturn errors.New(\"glGetRenderbufferParameteriv\")\n\t}\n\tgpGetRenderbufferParameterivEXT = (C.GPGETRENDERBUFFERPARAMETERIVEXT)(getProcAddr(\"glGetRenderbufferParameterivEXT\"))\n\tgpGetSamplerParameterIiv = (C.GPGETSAMPLERPARAMETERIIV)(getProcAddr(\"glGetSamplerParameterIiv\"))\n\tif gpGetSamplerParameterIiv == nil {\n\t\treturn errors.New(\"glGetSamplerParameterIiv\")\n\t}\n\tgpGetSamplerParameterIuiv = (C.GPGETSAMPLERPARAMETERIUIV)(getProcAddr(\"glGetSamplerParameterIuiv\"))\n\tif gpGetSamplerParameterIuiv == nil {\n\t\treturn errors.New(\"glGetSamplerParameterIuiv\")\n\t}\n\tgpGetSamplerParameterfv = (C.GPGETSAMPLERPARAMETERFV)(getProcAddr(\"glGetSamplerParameterfv\"))\n\tif gpGetSamplerParameterfv == nil {\n\t\treturn errors.New(\"glGetSamplerParameterfv\")\n\t}\n\tgpGetSamplerParameteriv = (C.GPGETSAMPLERPARAMETERIV)(getProcAddr(\"glGetSamplerParameteriv\"))\n\tif gpGetSamplerParameteriv == nil {\n\t\treturn errors.New(\"glGetSamplerParameteriv\")\n\t}\n\tgpGetSemaphoreParameterivNV = (C.GPGETSEMAPHOREPARAMETERIVNV)(getProcAddr(\"glGetSemaphoreParameterivNV\"))\n\tgpGetSemaphoreParameterui64vEXT = (C.GPGETSEMAPHOREPARAMETERUI64VEXT)(getProcAddr(\"glGetSemaphoreParameterui64vEXT\"))\n\tgpGetSeparableFilter = (C.GPGETSEPARABLEFILTER)(getProcAddr(\"glGetSeparableFilter\"))\n\tgpGetSeparableFilterEXT = (C.GPGETSEPARABLEFILTEREXT)(getProcAddr(\"glGetSeparableFilterEXT\"))\n\tgpGetShaderInfoLog = (C.GPGETSHADERINFOLOG)(getProcAddr(\"glGetShaderInfoLog\"))\n\tif gpGetShaderInfoLog == nil {\n\t\treturn errors.New(\"glGetShaderInfoLog\")\n\t}\n\tgpGetShaderPrecisionFormat = (C.GPGETSHADERPRECISIONFORMAT)(getProcAddr(\"glGetShaderPrecisionFormat\"))\n\tif gpGetShaderPrecisionFormat == nil {\n\t\treturn errors.New(\"glGetShaderPrecisionFormat\")\n\t}\n\tgpGetShaderSource = (C.GPGETSHADERSOURCE)(getProcAddr(\"glGetShaderSource\"))\n\tif gpGetShaderSource == nil {\n\t\treturn errors.New(\"glGetShaderSource\")\n\t}\n\tgpGetShaderSourceARB = (C.GPGETSHADERSOURCEARB)(getProcAddr(\"glGetShaderSourceARB\"))\n\tgpGetShaderiv = (C.GPGETSHADERIV)(getProcAddr(\"glGetShaderiv\"))\n\tif gpGetShaderiv == nil {\n\t\treturn errors.New(\"glGetShaderiv\")\n\t}\n\tgpGetShadingRateImagePaletteNV = (C.GPGETSHADINGRATEIMAGEPALETTENV)(getProcAddr(\"glGetShadingRateImagePaletteNV\"))\n\tgpGetShadingRateSampleLocationivNV = (C.GPGETSHADINGRATESAMPLELOCATIONIVNV)(getProcAddr(\"glGetShadingRateSampleLocationivNV\"))\n\tgpGetSharpenTexFuncSGIS = (C.GPGETSHARPENTEXFUNCSGIS)(getProcAddr(\"glGetSharpenTexFuncSGIS\"))\n\tgpGetStageIndexNV = (C.GPGETSTAGEINDEXNV)(getProcAddr(\"glGetStageIndexNV\"))\n\tgpGetString = (C.GPGETSTRING)(getProcAddr(\"glGetString\"))\n\tif gpGetString == nil {\n\t\treturn errors.New(\"glGetString\")\n\t}\n\tgpGetStringi = (C.GPGETSTRINGI)(getProcAddr(\"glGetStringi\"))\n\tif gpGetStringi == nil {\n\t\treturn errors.New(\"glGetStringi\")\n\t}\n\tgpGetSubroutineIndex = (C.GPGETSUBROUTINEINDEX)(getProcAddr(\"glGetSubroutineIndex\"))\n\tif gpGetSubroutineIndex == nil {\n\t\treturn errors.New(\"glGetSubroutineIndex\")\n\t}\n\tgpGetSubroutineUniformLocation = (C.GPGETSUBROUTINEUNIFORMLOCATION)(getProcAddr(\"glGetSubroutineUniformLocation\"))\n\tif gpGetSubroutineUniformLocation == nil {\n\t\treturn errors.New(\"glGetSubroutineUniformLocation\")\n\t}\n\tgpGetSynciv = (C.GPGETSYNCIV)(getProcAddr(\"glGetSynciv\"))\n\tif gpGetSynciv == nil {\n\t\treturn errors.New(\"glGetSynciv\")\n\t}\n\tgpGetTexBumpParameterfvATI = (C.GPGETTEXBUMPPARAMETERFVATI)(getProcAddr(\"glGetTexBumpParameterfvATI\"))\n\tgpGetTexBumpParameterivATI = (C.GPGETTEXBUMPPARAMETERIVATI)(getProcAddr(\"glGetTexBumpParameterivATI\"))\n\tgpGetTexEnvfv = (C.GPGETTEXENVFV)(getProcAddr(\"glGetTexEnvfv\"))\n\tif gpGetTexEnvfv == nil {\n\t\treturn errors.New(\"glGetTexEnvfv\")\n\t}\n\tgpGetTexEnviv = (C.GPGETTEXENVIV)(getProcAddr(\"glGetTexEnviv\"))\n\tif gpGetTexEnviv == nil {\n\t\treturn errors.New(\"glGetTexEnviv\")\n\t}\n\tgpGetTexEnvxvOES = (C.GPGETTEXENVXVOES)(getProcAddr(\"glGetTexEnvxvOES\"))\n\tgpGetTexFilterFuncSGIS = (C.GPGETTEXFILTERFUNCSGIS)(getProcAddr(\"glGetTexFilterFuncSGIS\"))\n\tgpGetTexGendv = (C.GPGETTEXGENDV)(getProcAddr(\"glGetTexGendv\"))\n\tif gpGetTexGendv == nil {\n\t\treturn errors.New(\"glGetTexGendv\")\n\t}\n\tgpGetTexGenfv = (C.GPGETTEXGENFV)(getProcAddr(\"glGetTexGenfv\"))\n\tif gpGetTexGenfv == nil {\n\t\treturn errors.New(\"glGetTexGenfv\")\n\t}\n\tgpGetTexGeniv = (C.GPGETTEXGENIV)(getProcAddr(\"glGetTexGeniv\"))\n\tif gpGetTexGeniv == nil {\n\t\treturn errors.New(\"glGetTexGeniv\")\n\t}\n\tgpGetTexGenxvOES = (C.GPGETTEXGENXVOES)(getProcAddr(\"glGetTexGenxvOES\"))\n\tgpGetTexImage = (C.GPGETTEXIMAGE)(getProcAddr(\"glGetTexImage\"))\n\tif gpGetTexImage == nil {\n\t\treturn errors.New(\"glGetTexImage\")\n\t}\n\tgpGetTexLevelParameterfv = (C.GPGETTEXLEVELPARAMETERFV)(getProcAddr(\"glGetTexLevelParameterfv\"))\n\tif gpGetTexLevelParameterfv == nil {\n\t\treturn errors.New(\"glGetTexLevelParameterfv\")\n\t}\n\tgpGetTexLevelParameteriv = (C.GPGETTEXLEVELPARAMETERIV)(getProcAddr(\"glGetTexLevelParameteriv\"))\n\tif gpGetTexLevelParameteriv == nil {\n\t\treturn errors.New(\"glGetTexLevelParameteriv\")\n\t}\n\tgpGetTexLevelParameterxvOES = (C.GPGETTEXLEVELPARAMETERXVOES)(getProcAddr(\"glGetTexLevelParameterxvOES\"))\n\tgpGetTexParameterIiv = (C.GPGETTEXPARAMETERIIV)(getProcAddr(\"glGetTexParameterIiv\"))\n\tif gpGetTexParameterIiv == nil {\n\t\treturn errors.New(\"glGetTexParameterIiv\")\n\t}\n\tgpGetTexParameterIivEXT = (C.GPGETTEXPARAMETERIIVEXT)(getProcAddr(\"glGetTexParameterIivEXT\"))\n\tgpGetTexParameterIuiv = (C.GPGETTEXPARAMETERIUIV)(getProcAddr(\"glGetTexParameterIuiv\"))\n\tif gpGetTexParameterIuiv == nil {\n\t\treturn errors.New(\"glGetTexParameterIuiv\")\n\t}\n\tgpGetTexParameterIuivEXT = (C.GPGETTEXPARAMETERIUIVEXT)(getProcAddr(\"glGetTexParameterIuivEXT\"))\n\tgpGetTexParameterPointervAPPLE = (C.GPGETTEXPARAMETERPOINTERVAPPLE)(getProcAddr(\"glGetTexParameterPointervAPPLE\"))\n\tgpGetTexParameterfv = (C.GPGETTEXPARAMETERFV)(getProcAddr(\"glGetTexParameterfv\"))\n\tif gpGetTexParameterfv == nil {\n\t\treturn errors.New(\"glGetTexParameterfv\")\n\t}\n\tgpGetTexParameteriv = (C.GPGETTEXPARAMETERIV)(getProcAddr(\"glGetTexParameteriv\"))\n\tif gpGetTexParameteriv == nil {\n\t\treturn errors.New(\"glGetTexParameteriv\")\n\t}\n\tgpGetTexParameterxvOES = (C.GPGETTEXPARAMETERXVOES)(getProcAddr(\"glGetTexParameterxvOES\"))\n\tgpGetTextureHandleARB = (C.GPGETTEXTUREHANDLEARB)(getProcAddr(\"glGetTextureHandleARB\"))\n\tgpGetTextureHandleNV = (C.GPGETTEXTUREHANDLENV)(getProcAddr(\"glGetTextureHandleNV\"))\n\tgpGetTextureImage = (C.GPGETTEXTUREIMAGE)(getProcAddr(\"glGetTextureImage\"))\n\tgpGetTextureImageEXT = (C.GPGETTEXTUREIMAGEEXT)(getProcAddr(\"glGetTextureImageEXT\"))\n\tgpGetTextureLevelParameterfv = (C.GPGETTEXTURELEVELPARAMETERFV)(getProcAddr(\"glGetTextureLevelParameterfv\"))\n\tgpGetTextureLevelParameterfvEXT = (C.GPGETTEXTURELEVELPARAMETERFVEXT)(getProcAddr(\"glGetTextureLevelParameterfvEXT\"))\n\tgpGetTextureLevelParameteriv = (C.GPGETTEXTURELEVELPARAMETERIV)(getProcAddr(\"glGetTextureLevelParameteriv\"))\n\tgpGetTextureLevelParameterivEXT = (C.GPGETTEXTURELEVELPARAMETERIVEXT)(getProcAddr(\"glGetTextureLevelParameterivEXT\"))\n\tgpGetTextureParameterIiv = (C.GPGETTEXTUREPARAMETERIIV)(getProcAddr(\"glGetTextureParameterIiv\"))\n\tgpGetTextureParameterIivEXT = (C.GPGETTEXTUREPARAMETERIIVEXT)(getProcAddr(\"glGetTextureParameterIivEXT\"))\n\tgpGetTextureParameterIuiv = (C.GPGETTEXTUREPARAMETERIUIV)(getProcAddr(\"glGetTextureParameterIuiv\"))\n\tgpGetTextureParameterIuivEXT = (C.GPGETTEXTUREPARAMETERIUIVEXT)(getProcAddr(\"glGetTextureParameterIuivEXT\"))\n\tgpGetTextureParameterfv = (C.GPGETTEXTUREPARAMETERFV)(getProcAddr(\"glGetTextureParameterfv\"))\n\tgpGetTextureParameterfvEXT = (C.GPGETTEXTUREPARAMETERFVEXT)(getProcAddr(\"glGetTextureParameterfvEXT\"))\n\tgpGetTextureParameteriv = (C.GPGETTEXTUREPARAMETERIV)(getProcAddr(\"glGetTextureParameteriv\"))\n\tgpGetTextureParameterivEXT = (C.GPGETTEXTUREPARAMETERIVEXT)(getProcAddr(\"glGetTextureParameterivEXT\"))\n\tgpGetTextureSamplerHandleARB = (C.GPGETTEXTURESAMPLERHANDLEARB)(getProcAddr(\"glGetTextureSamplerHandleARB\"))\n\tgpGetTextureSamplerHandleNV = (C.GPGETTEXTURESAMPLERHANDLENV)(getProcAddr(\"glGetTextureSamplerHandleNV\"))\n\tgpGetTextureSubImage = (C.GPGETTEXTURESUBIMAGE)(getProcAddr(\"glGetTextureSubImage\"))\n\tgpGetTrackMatrixivNV = (C.GPGETTRACKMATRIXIVNV)(getProcAddr(\"glGetTrackMatrixivNV\"))\n\tgpGetTransformFeedbackVarying = (C.GPGETTRANSFORMFEEDBACKVARYING)(getProcAddr(\"glGetTransformFeedbackVarying\"))\n\tif gpGetTransformFeedbackVarying == nil {\n\t\treturn errors.New(\"glGetTransformFeedbackVarying\")\n\t}\n\tgpGetTransformFeedbackVaryingEXT = (C.GPGETTRANSFORMFEEDBACKVARYINGEXT)(getProcAddr(\"glGetTransformFeedbackVaryingEXT\"))\n\tgpGetTransformFeedbackVaryingNV = (C.GPGETTRANSFORMFEEDBACKVARYINGNV)(getProcAddr(\"glGetTransformFeedbackVaryingNV\"))\n\tgpGetTransformFeedbacki64_v = (C.GPGETTRANSFORMFEEDBACKI64_V)(getProcAddr(\"glGetTransformFeedbacki64_v\"))\n\tgpGetTransformFeedbacki_v = (C.GPGETTRANSFORMFEEDBACKI_V)(getProcAddr(\"glGetTransformFeedbacki_v\"))\n\tgpGetTransformFeedbackiv = (C.GPGETTRANSFORMFEEDBACKIV)(getProcAddr(\"glGetTransformFeedbackiv\"))\n\tgpGetUniformBlockIndex = (C.GPGETUNIFORMBLOCKINDEX)(getProcAddr(\"glGetUniformBlockIndex\"))\n\tif gpGetUniformBlockIndex == nil {\n\t\treturn errors.New(\"glGetUniformBlockIndex\")\n\t}\n\tgpGetUniformBufferSizeEXT = (C.GPGETUNIFORMBUFFERSIZEEXT)(getProcAddr(\"glGetUniformBufferSizeEXT\"))\n\tgpGetUniformIndices = (C.GPGETUNIFORMINDICES)(getProcAddr(\"glGetUniformIndices\"))\n\tif gpGetUniformIndices == nil {\n\t\treturn errors.New(\"glGetUniformIndices\")\n\t}\n\tgpGetUniformLocation = (C.GPGETUNIFORMLOCATION)(getProcAddr(\"glGetUniformLocation\"))\n\tif gpGetUniformLocation == nil {\n\t\treturn errors.New(\"glGetUniformLocation\")\n\t}\n\tgpGetUniformLocationARB = (C.GPGETUNIFORMLOCATIONARB)(getProcAddr(\"glGetUniformLocationARB\"))\n\tgpGetUniformOffsetEXT = (C.GPGETUNIFORMOFFSETEXT)(getProcAddr(\"glGetUniformOffsetEXT\"))\n\tgpGetUniformSubroutineuiv = (C.GPGETUNIFORMSUBROUTINEUIV)(getProcAddr(\"glGetUniformSubroutineuiv\"))\n\tif gpGetUniformSubroutineuiv == nil {\n\t\treturn errors.New(\"glGetUniformSubroutineuiv\")\n\t}\n\tgpGetUniformdv = (C.GPGETUNIFORMDV)(getProcAddr(\"glGetUniformdv\"))\n\tif gpGetUniformdv == nil {\n\t\treturn errors.New(\"glGetUniformdv\")\n\t}\n\tgpGetUniformfv = (C.GPGETUNIFORMFV)(getProcAddr(\"glGetUniformfv\"))\n\tif gpGetUniformfv == nil {\n\t\treturn errors.New(\"glGetUniformfv\")\n\t}\n\tgpGetUniformfvARB = (C.GPGETUNIFORMFVARB)(getProcAddr(\"glGetUniformfvARB\"))\n\tgpGetUniformi64vARB = (C.GPGETUNIFORMI64VARB)(getProcAddr(\"glGetUniformi64vARB\"))\n\tgpGetUniformi64vNV = (C.GPGETUNIFORMI64VNV)(getProcAddr(\"glGetUniformi64vNV\"))\n\tgpGetUniformiv = (C.GPGETUNIFORMIV)(getProcAddr(\"glGetUniformiv\"))\n\tif gpGetUniformiv == nil {\n\t\treturn errors.New(\"glGetUniformiv\")\n\t}\n\tgpGetUniformivARB = (C.GPGETUNIFORMIVARB)(getProcAddr(\"glGetUniformivARB\"))\n\tgpGetUniformui64vARB = (C.GPGETUNIFORMUI64VARB)(getProcAddr(\"glGetUniformui64vARB\"))\n\tgpGetUniformui64vNV = (C.GPGETUNIFORMUI64VNV)(getProcAddr(\"glGetUniformui64vNV\"))\n\tgpGetUniformuiv = (C.GPGETUNIFORMUIV)(getProcAddr(\"glGetUniformuiv\"))\n\tif gpGetUniformuiv == nil {\n\t\treturn errors.New(\"glGetUniformuiv\")\n\t}\n\tgpGetUniformuivEXT = (C.GPGETUNIFORMUIVEXT)(getProcAddr(\"glGetUniformuivEXT\"))\n\tgpGetUnsignedBytei_vEXT = (C.GPGETUNSIGNEDBYTEI_VEXT)(getProcAddr(\"glGetUnsignedBytei_vEXT\"))\n\tgpGetUnsignedBytevEXT = (C.GPGETUNSIGNEDBYTEVEXT)(getProcAddr(\"glGetUnsignedBytevEXT\"))\n\tgpGetVariantArrayObjectfvATI = (C.GPGETVARIANTARRAYOBJECTFVATI)(getProcAddr(\"glGetVariantArrayObjectfvATI\"))\n\tgpGetVariantArrayObjectivATI = (C.GPGETVARIANTARRAYOBJECTIVATI)(getProcAddr(\"glGetVariantArrayObjectivATI\"))\n\tgpGetVariantBooleanvEXT = (C.GPGETVARIANTBOOLEANVEXT)(getProcAddr(\"glGetVariantBooleanvEXT\"))\n\tgpGetVariantFloatvEXT = (C.GPGETVARIANTFLOATVEXT)(getProcAddr(\"glGetVariantFloatvEXT\"))\n\tgpGetVariantIntegervEXT = (C.GPGETVARIANTINTEGERVEXT)(getProcAddr(\"glGetVariantIntegervEXT\"))\n\tgpGetVariantPointervEXT = (C.GPGETVARIANTPOINTERVEXT)(getProcAddr(\"glGetVariantPointervEXT\"))\n\tgpGetVaryingLocationNV = (C.GPGETVARYINGLOCATIONNV)(getProcAddr(\"glGetVaryingLocationNV\"))\n\tgpGetVertexArrayIndexed64iv = (C.GPGETVERTEXARRAYINDEXED64IV)(getProcAddr(\"glGetVertexArrayIndexed64iv\"))\n\tgpGetVertexArrayIndexediv = (C.GPGETVERTEXARRAYINDEXEDIV)(getProcAddr(\"glGetVertexArrayIndexediv\"))\n\tgpGetVertexArrayIntegeri_vEXT = (C.GPGETVERTEXARRAYINTEGERI_VEXT)(getProcAddr(\"glGetVertexArrayIntegeri_vEXT\"))\n\tgpGetVertexArrayIntegervEXT = (C.GPGETVERTEXARRAYINTEGERVEXT)(getProcAddr(\"glGetVertexArrayIntegervEXT\"))\n\tgpGetVertexArrayPointeri_vEXT = (C.GPGETVERTEXARRAYPOINTERI_VEXT)(getProcAddr(\"glGetVertexArrayPointeri_vEXT\"))\n\tgpGetVertexArrayPointervEXT = (C.GPGETVERTEXARRAYPOINTERVEXT)(getProcAddr(\"glGetVertexArrayPointervEXT\"))\n\tgpGetVertexArrayiv = (C.GPGETVERTEXARRAYIV)(getProcAddr(\"glGetVertexArrayiv\"))\n\tgpGetVertexAttribArrayObjectfvATI = (C.GPGETVERTEXATTRIBARRAYOBJECTFVATI)(getProcAddr(\"glGetVertexAttribArrayObjectfvATI\"))\n\tgpGetVertexAttribArrayObjectivATI = (C.GPGETVERTEXATTRIBARRAYOBJECTIVATI)(getProcAddr(\"glGetVertexAttribArrayObjectivATI\"))\n\tgpGetVertexAttribIiv = (C.GPGETVERTEXATTRIBIIV)(getProcAddr(\"glGetVertexAttribIiv\"))\n\tif gpGetVertexAttribIiv == nil {\n\t\treturn errors.New(\"glGetVertexAttribIiv\")\n\t}\n\tgpGetVertexAttribIivEXT = (C.GPGETVERTEXATTRIBIIVEXT)(getProcAddr(\"glGetVertexAttribIivEXT\"))\n\tgpGetVertexAttribIuiv = (C.GPGETVERTEXATTRIBIUIV)(getProcAddr(\"glGetVertexAttribIuiv\"))\n\tif gpGetVertexAttribIuiv == nil {\n\t\treturn errors.New(\"glGetVertexAttribIuiv\")\n\t}\n\tgpGetVertexAttribIuivEXT = (C.GPGETVERTEXATTRIBIUIVEXT)(getProcAddr(\"glGetVertexAttribIuivEXT\"))\n\tgpGetVertexAttribLdv = (C.GPGETVERTEXATTRIBLDV)(getProcAddr(\"glGetVertexAttribLdv\"))\n\tif gpGetVertexAttribLdv == nil {\n\t\treturn errors.New(\"glGetVertexAttribLdv\")\n\t}\n\tgpGetVertexAttribLdvEXT = (C.GPGETVERTEXATTRIBLDVEXT)(getProcAddr(\"glGetVertexAttribLdvEXT\"))\n\tgpGetVertexAttribLi64vNV = (C.GPGETVERTEXATTRIBLI64VNV)(getProcAddr(\"glGetVertexAttribLi64vNV\"))\n\tgpGetVertexAttribLui64vARB = (C.GPGETVERTEXATTRIBLUI64VARB)(getProcAddr(\"glGetVertexAttribLui64vARB\"))\n\tgpGetVertexAttribLui64vNV = (C.GPGETVERTEXATTRIBLUI64VNV)(getProcAddr(\"glGetVertexAttribLui64vNV\"))\n\tgpGetVertexAttribPointerv = (C.GPGETVERTEXATTRIBPOINTERV)(getProcAddr(\"glGetVertexAttribPointerv\"))\n\tif gpGetVertexAttribPointerv == nil {\n\t\treturn errors.New(\"glGetVertexAttribPointerv\")\n\t}\n\tgpGetVertexAttribPointervARB = (C.GPGETVERTEXATTRIBPOINTERVARB)(getProcAddr(\"glGetVertexAttribPointervARB\"))\n\tgpGetVertexAttribPointervNV = (C.GPGETVERTEXATTRIBPOINTERVNV)(getProcAddr(\"glGetVertexAttribPointervNV\"))\n\tgpGetVertexAttribdv = (C.GPGETVERTEXATTRIBDV)(getProcAddr(\"glGetVertexAttribdv\"))\n\tif gpGetVertexAttribdv == nil {\n\t\treturn errors.New(\"glGetVertexAttribdv\")\n\t}\n\tgpGetVertexAttribdvARB = (C.GPGETVERTEXATTRIBDVARB)(getProcAddr(\"glGetVertexAttribdvARB\"))\n\tgpGetVertexAttribdvNV = (C.GPGETVERTEXATTRIBDVNV)(getProcAddr(\"glGetVertexAttribdvNV\"))\n\tgpGetVertexAttribfv = (C.GPGETVERTEXATTRIBFV)(getProcAddr(\"glGetVertexAttribfv\"))\n\tif gpGetVertexAttribfv == nil {\n\t\treturn errors.New(\"glGetVertexAttribfv\")\n\t}\n\tgpGetVertexAttribfvARB = (C.GPGETVERTEXATTRIBFVARB)(getProcAddr(\"glGetVertexAttribfvARB\"))\n\tgpGetVertexAttribfvNV = (C.GPGETVERTEXATTRIBFVNV)(getProcAddr(\"glGetVertexAttribfvNV\"))\n\tgpGetVertexAttribiv = (C.GPGETVERTEXATTRIBIV)(getProcAddr(\"glGetVertexAttribiv\"))\n\tif gpGetVertexAttribiv == nil {\n\t\treturn errors.New(\"glGetVertexAttribiv\")\n\t}\n\tgpGetVertexAttribivARB = (C.GPGETVERTEXATTRIBIVARB)(getProcAddr(\"glGetVertexAttribivARB\"))\n\tgpGetVertexAttribivNV = (C.GPGETVERTEXATTRIBIVNV)(getProcAddr(\"glGetVertexAttribivNV\"))\n\tgpGetVideoCaptureStreamdvNV = (C.GPGETVIDEOCAPTURESTREAMDVNV)(getProcAddr(\"glGetVideoCaptureStreamdvNV\"))\n\tgpGetVideoCaptureStreamfvNV = (C.GPGETVIDEOCAPTURESTREAMFVNV)(getProcAddr(\"glGetVideoCaptureStreamfvNV\"))\n\tgpGetVideoCaptureStreamivNV = (C.GPGETVIDEOCAPTURESTREAMIVNV)(getProcAddr(\"glGetVideoCaptureStreamivNV\"))\n\tgpGetVideoCaptureivNV = (C.GPGETVIDEOCAPTUREIVNV)(getProcAddr(\"glGetVideoCaptureivNV\"))\n\tgpGetVideoi64vNV = (C.GPGETVIDEOI64VNV)(getProcAddr(\"glGetVideoi64vNV\"))\n\tgpGetVideoivNV = (C.GPGETVIDEOIVNV)(getProcAddr(\"glGetVideoivNV\"))\n\tgpGetVideoui64vNV = (C.GPGETVIDEOUI64VNV)(getProcAddr(\"glGetVideoui64vNV\"))\n\tgpGetVideouivNV = (C.GPGETVIDEOUIVNV)(getProcAddr(\"glGetVideouivNV\"))\n\tgpGetVkProcAddrNV = (C.GPGETVKPROCADDRNV)(getProcAddr(\"glGetVkProcAddrNV\"))\n\tgpGetnColorTableARB = (C.GPGETNCOLORTABLEARB)(getProcAddr(\"glGetnColorTableARB\"))\n\tgpGetnCompressedTexImageARB = (C.GPGETNCOMPRESSEDTEXIMAGEARB)(getProcAddr(\"glGetnCompressedTexImageARB\"))\n\tgpGetnConvolutionFilterARB = (C.GPGETNCONVOLUTIONFILTERARB)(getProcAddr(\"glGetnConvolutionFilterARB\"))\n\tgpGetnHistogramARB = (C.GPGETNHISTOGRAMARB)(getProcAddr(\"glGetnHistogramARB\"))\n\tgpGetnMapdvARB = (C.GPGETNMAPDVARB)(getProcAddr(\"glGetnMapdvARB\"))\n\tgpGetnMapfvARB = (C.GPGETNMAPFVARB)(getProcAddr(\"glGetnMapfvARB\"))\n\tgpGetnMapivARB = (C.GPGETNMAPIVARB)(getProcAddr(\"glGetnMapivARB\"))\n\tgpGetnMinmaxARB = (C.GPGETNMINMAXARB)(getProcAddr(\"glGetnMinmaxARB\"))\n\tgpGetnPixelMapfvARB = (C.GPGETNPIXELMAPFVARB)(getProcAddr(\"glGetnPixelMapfvARB\"))\n\tgpGetnPixelMapuivARB = (C.GPGETNPIXELMAPUIVARB)(getProcAddr(\"glGetnPixelMapuivARB\"))\n\tgpGetnPixelMapusvARB = (C.GPGETNPIXELMAPUSVARB)(getProcAddr(\"glGetnPixelMapusvARB\"))\n\tgpGetnPolygonStippleARB = (C.GPGETNPOLYGONSTIPPLEARB)(getProcAddr(\"glGetnPolygonStippleARB\"))\n\tgpGetnSeparableFilterARB = (C.GPGETNSEPARABLEFILTERARB)(getProcAddr(\"glGetnSeparableFilterARB\"))\n\tgpGetnTexImageARB = (C.GPGETNTEXIMAGEARB)(getProcAddr(\"glGetnTexImageARB\"))\n\tgpGetnUniformdvARB = (C.GPGETNUNIFORMDVARB)(getProcAddr(\"glGetnUniformdvARB\"))\n\tgpGetnUniformfv = (C.GPGETNUNIFORMFV)(getProcAddr(\"glGetnUniformfv\"))\n\tgpGetnUniformfvARB = (C.GPGETNUNIFORMFVARB)(getProcAddr(\"glGetnUniformfvARB\"))\n\tgpGetnUniformfvKHR = (C.GPGETNUNIFORMFVKHR)(getProcAddr(\"glGetnUniformfvKHR\"))\n\tgpGetnUniformi64vARB = (C.GPGETNUNIFORMI64VARB)(getProcAddr(\"glGetnUniformi64vARB\"))\n\tgpGetnUniformiv = (C.GPGETNUNIFORMIV)(getProcAddr(\"glGetnUniformiv\"))\n\tgpGetnUniformivARB = (C.GPGETNUNIFORMIVARB)(getProcAddr(\"glGetnUniformivARB\"))\n\tgpGetnUniformivKHR = (C.GPGETNUNIFORMIVKHR)(getProcAddr(\"glGetnUniformivKHR\"))\n\tgpGetnUniformui64vARB = (C.GPGETNUNIFORMUI64VARB)(getProcAddr(\"glGetnUniformui64vARB\"))\n\tgpGetnUniformuiv = (C.GPGETNUNIFORMUIV)(getProcAddr(\"glGetnUniformuiv\"))\n\tgpGetnUniformuivARB = (C.GPGETNUNIFORMUIVARB)(getProcAddr(\"glGetnUniformuivARB\"))\n\tgpGetnUniformuivKHR = (C.GPGETNUNIFORMUIVKHR)(getProcAddr(\"glGetnUniformuivKHR\"))\n\tgpGlobalAlphaFactorbSUN = (C.GPGLOBALALPHAFACTORBSUN)(getProcAddr(\"glGlobalAlphaFactorbSUN\"))\n\tgpGlobalAlphaFactordSUN = (C.GPGLOBALALPHAFACTORDSUN)(getProcAddr(\"glGlobalAlphaFactordSUN\"))\n\tgpGlobalAlphaFactorfSUN = (C.GPGLOBALALPHAFACTORFSUN)(getProcAddr(\"glGlobalAlphaFactorfSUN\"))\n\tgpGlobalAlphaFactoriSUN = (C.GPGLOBALALPHAFACTORISUN)(getProcAddr(\"glGlobalAlphaFactoriSUN\"))\n\tgpGlobalAlphaFactorsSUN = (C.GPGLOBALALPHAFACTORSSUN)(getProcAddr(\"glGlobalAlphaFactorsSUN\"))\n\tgpGlobalAlphaFactorubSUN = (C.GPGLOBALALPHAFACTORUBSUN)(getProcAddr(\"glGlobalAlphaFactorubSUN\"))\n\tgpGlobalAlphaFactoruiSUN = (C.GPGLOBALALPHAFACTORUISUN)(getProcAddr(\"glGlobalAlphaFactoruiSUN\"))\n\tgpGlobalAlphaFactorusSUN = (C.GPGLOBALALPHAFACTORUSSUN)(getProcAddr(\"glGlobalAlphaFactorusSUN\"))\n\tgpHint = (C.GPHINT)(getProcAddr(\"glHint\"))\n\tif gpHint == nil {\n\t\treturn errors.New(\"glHint\")\n\t}\n\tgpHintPGI = (C.GPHINTPGI)(getProcAddr(\"glHintPGI\"))\n\tgpHistogram = (C.GPHISTOGRAM)(getProcAddr(\"glHistogram\"))\n\tgpHistogramEXT = (C.GPHISTOGRAMEXT)(getProcAddr(\"glHistogramEXT\"))\n\tgpIglooInterfaceSGIX = (C.GPIGLOOINTERFACESGIX)(getProcAddr(\"glIglooInterfaceSGIX\"))\n\tgpImageTransformParameterfHP = (C.GPIMAGETRANSFORMPARAMETERFHP)(getProcAddr(\"glImageTransformParameterfHP\"))\n\tgpImageTransformParameterfvHP = (C.GPIMAGETRANSFORMPARAMETERFVHP)(getProcAddr(\"glImageTransformParameterfvHP\"))\n\tgpImageTransformParameteriHP = (C.GPIMAGETRANSFORMPARAMETERIHP)(getProcAddr(\"glImageTransformParameteriHP\"))\n\tgpImageTransformParameterivHP = (C.GPIMAGETRANSFORMPARAMETERIVHP)(getProcAddr(\"glImageTransformParameterivHP\"))\n\tgpImportMemoryFdEXT = (C.GPIMPORTMEMORYFDEXT)(getProcAddr(\"glImportMemoryFdEXT\"))\n\tgpImportMemoryWin32HandleEXT = (C.GPIMPORTMEMORYWIN32HANDLEEXT)(getProcAddr(\"glImportMemoryWin32HandleEXT\"))\n\tgpImportMemoryWin32NameEXT = (C.GPIMPORTMEMORYWIN32NAMEEXT)(getProcAddr(\"glImportMemoryWin32NameEXT\"))\n\tgpImportSemaphoreFdEXT = (C.GPIMPORTSEMAPHOREFDEXT)(getProcAddr(\"glImportSemaphoreFdEXT\"))\n\tgpImportSemaphoreWin32HandleEXT = (C.GPIMPORTSEMAPHOREWIN32HANDLEEXT)(getProcAddr(\"glImportSemaphoreWin32HandleEXT\"))\n\tgpImportSemaphoreWin32NameEXT = (C.GPIMPORTSEMAPHOREWIN32NAMEEXT)(getProcAddr(\"glImportSemaphoreWin32NameEXT\"))\n\tgpImportSyncEXT = (C.GPIMPORTSYNCEXT)(getProcAddr(\"glImportSyncEXT\"))\n\tgpIndexFormatNV = (C.GPINDEXFORMATNV)(getProcAddr(\"glIndexFormatNV\"))\n\tgpIndexFuncEXT = (C.GPINDEXFUNCEXT)(getProcAddr(\"glIndexFuncEXT\"))\n\tgpIndexMask = (C.GPINDEXMASK)(getProcAddr(\"glIndexMask\"))\n\tif gpIndexMask == nil {\n\t\treturn errors.New(\"glIndexMask\")\n\t}\n\tgpIndexMaterialEXT = (C.GPINDEXMATERIALEXT)(getProcAddr(\"glIndexMaterialEXT\"))\n\tgpIndexPointer = (C.GPINDEXPOINTER)(getProcAddr(\"glIndexPointer\"))\n\tif gpIndexPointer == nil {\n\t\treturn errors.New(\"glIndexPointer\")\n\t}\n\tgpIndexPointerEXT = (C.GPINDEXPOINTEREXT)(getProcAddr(\"glIndexPointerEXT\"))\n\tgpIndexPointerListIBM = (C.GPINDEXPOINTERLISTIBM)(getProcAddr(\"glIndexPointerListIBM\"))\n\tgpIndexd = (C.GPINDEXD)(getProcAddr(\"glIndexd\"))\n\tif gpIndexd == nil {\n\t\treturn errors.New(\"glIndexd\")\n\t}\n\tgpIndexdv = (C.GPINDEXDV)(getProcAddr(\"glIndexdv\"))\n\tif gpIndexdv == nil {\n\t\treturn errors.New(\"glIndexdv\")\n\t}\n\tgpIndexf = (C.GPINDEXF)(getProcAddr(\"glIndexf\"))\n\tif gpIndexf == nil {\n\t\treturn errors.New(\"glIndexf\")\n\t}\n\tgpIndexfv = (C.GPINDEXFV)(getProcAddr(\"glIndexfv\"))\n\tif gpIndexfv == nil {\n\t\treturn errors.New(\"glIndexfv\")\n\t}\n\tgpIndexi = (C.GPINDEXI)(getProcAddr(\"glIndexi\"))\n\tif gpIndexi == nil {\n\t\treturn errors.New(\"glIndexi\")\n\t}\n\tgpIndexiv = (C.GPINDEXIV)(getProcAddr(\"glIndexiv\"))\n\tif gpIndexiv == nil {\n\t\treturn errors.New(\"glIndexiv\")\n\t}\n\tgpIndexs = (C.GPINDEXS)(getProcAddr(\"glIndexs\"))\n\tif gpIndexs == nil {\n\t\treturn errors.New(\"glIndexs\")\n\t}\n\tgpIndexsv = (C.GPINDEXSV)(getProcAddr(\"glIndexsv\"))\n\tif gpIndexsv == nil {\n\t\treturn errors.New(\"glIndexsv\")\n\t}\n\tgpIndexub = (C.GPINDEXUB)(getProcAddr(\"glIndexub\"))\n\tif gpIndexub == nil {\n\t\treturn errors.New(\"glIndexub\")\n\t}\n\tgpIndexubv = (C.GPINDEXUBV)(getProcAddr(\"glIndexubv\"))\n\tif gpIndexubv == nil {\n\t\treturn errors.New(\"glIndexubv\")\n\t}\n\tgpIndexxOES = (C.GPINDEXXOES)(getProcAddr(\"glIndexxOES\"))\n\tgpIndexxvOES = (C.GPINDEXXVOES)(getProcAddr(\"glIndexxvOES\"))\n\tgpInitNames = (C.GPINITNAMES)(getProcAddr(\"glInitNames\"))\n\tif gpInitNames == nil {\n\t\treturn errors.New(\"glInitNames\")\n\t}\n\tgpInsertComponentEXT = (C.GPINSERTCOMPONENTEXT)(getProcAddr(\"glInsertComponentEXT\"))\n\tgpInsertEventMarkerEXT = (C.GPINSERTEVENTMARKEREXT)(getProcAddr(\"glInsertEventMarkerEXT\"))\n\tgpInstrumentsBufferSGIX = (C.GPINSTRUMENTSBUFFERSGIX)(getProcAddr(\"glInstrumentsBufferSGIX\"))\n\tgpInterleavedArrays = (C.GPINTERLEAVEDARRAYS)(getProcAddr(\"glInterleavedArrays\"))\n\tif gpInterleavedArrays == nil {\n\t\treturn errors.New(\"glInterleavedArrays\")\n\t}\n\tgpInterpolatePathsNV = (C.GPINTERPOLATEPATHSNV)(getProcAddr(\"glInterpolatePathsNV\"))\n\tgpInvalidateBufferData = (C.GPINVALIDATEBUFFERDATA)(getProcAddr(\"glInvalidateBufferData\"))\n\tif gpInvalidateBufferData == nil {\n\t\treturn errors.New(\"glInvalidateBufferData\")\n\t}\n\tgpInvalidateBufferSubData = (C.GPINVALIDATEBUFFERSUBDATA)(getProcAddr(\"glInvalidateBufferSubData\"))\n\tif gpInvalidateBufferSubData == nil {\n\t\treturn errors.New(\"glInvalidateBufferSubData\")\n\t}\n\tgpInvalidateFramebuffer = (C.GPINVALIDATEFRAMEBUFFER)(getProcAddr(\"glInvalidateFramebuffer\"))\n\tif gpInvalidateFramebuffer == nil {\n\t\treturn errors.New(\"glInvalidateFramebuffer\")\n\t}\n\tgpInvalidateNamedFramebufferData = (C.GPINVALIDATENAMEDFRAMEBUFFERDATA)(getProcAddr(\"glInvalidateNamedFramebufferData\"))\n\tgpInvalidateNamedFramebufferSubData = (C.GPINVALIDATENAMEDFRAMEBUFFERSUBDATA)(getProcAddr(\"glInvalidateNamedFramebufferSubData\"))\n\tgpInvalidateSubFramebuffer = (C.GPINVALIDATESUBFRAMEBUFFER)(getProcAddr(\"glInvalidateSubFramebuffer\"))\n\tif gpInvalidateSubFramebuffer == nil {\n\t\treturn errors.New(\"glInvalidateSubFramebuffer\")\n\t}\n\tgpInvalidateTexImage = (C.GPINVALIDATETEXIMAGE)(getProcAddr(\"glInvalidateTexImage\"))\n\tif gpInvalidateTexImage == nil {\n\t\treturn errors.New(\"glInvalidateTexImage\")\n\t}\n\tgpInvalidateTexSubImage = (C.GPINVALIDATETEXSUBIMAGE)(getProcAddr(\"glInvalidateTexSubImage\"))\n\tif gpInvalidateTexSubImage == nil {\n\t\treturn errors.New(\"glInvalidateTexSubImage\")\n\t}\n\tgpIsAsyncMarkerSGIX = (C.GPISASYNCMARKERSGIX)(getProcAddr(\"glIsAsyncMarkerSGIX\"))\n\tgpIsBuffer = (C.GPISBUFFER)(getProcAddr(\"glIsBuffer\"))\n\tif gpIsBuffer == nil {\n\t\treturn errors.New(\"glIsBuffer\")\n\t}\n\tgpIsBufferARB = (C.GPISBUFFERARB)(getProcAddr(\"glIsBufferARB\"))\n\tgpIsBufferResidentNV = (C.GPISBUFFERRESIDENTNV)(getProcAddr(\"glIsBufferResidentNV\"))\n\tgpIsCommandListNV = (C.GPISCOMMANDLISTNV)(getProcAddr(\"glIsCommandListNV\"))\n\tgpIsEnabled = (C.GPISENABLED)(getProcAddr(\"glIsEnabled\"))\n\tif gpIsEnabled == nil {\n\t\treturn errors.New(\"glIsEnabled\")\n\t}\n\tgpIsEnabledIndexedEXT = (C.GPISENABLEDINDEXEDEXT)(getProcAddr(\"glIsEnabledIndexedEXT\"))\n\tgpIsEnabledi = (C.GPISENABLEDI)(getProcAddr(\"glIsEnabledi\"))\n\tif gpIsEnabledi == nil {\n\t\treturn errors.New(\"glIsEnabledi\")\n\t}\n\tgpIsFenceAPPLE = (C.GPISFENCEAPPLE)(getProcAddr(\"glIsFenceAPPLE\"))\n\tgpIsFenceNV = (C.GPISFENCENV)(getProcAddr(\"glIsFenceNV\"))\n\tgpIsFramebuffer = (C.GPISFRAMEBUFFER)(getProcAddr(\"glIsFramebuffer\"))\n\tif gpIsFramebuffer == nil {\n\t\treturn errors.New(\"glIsFramebuffer\")\n\t}\n\tgpIsFramebufferEXT = (C.GPISFRAMEBUFFEREXT)(getProcAddr(\"glIsFramebufferEXT\"))\n\tgpIsImageHandleResidentARB = (C.GPISIMAGEHANDLERESIDENTARB)(getProcAddr(\"glIsImageHandleResidentARB\"))\n\tgpIsImageHandleResidentNV = (C.GPISIMAGEHANDLERESIDENTNV)(getProcAddr(\"glIsImageHandleResidentNV\"))\n\tgpIsList = (C.GPISLIST)(getProcAddr(\"glIsList\"))\n\tif gpIsList == nil {\n\t\treturn errors.New(\"glIsList\")\n\t}\n\tgpIsMemoryObjectEXT = (C.GPISMEMORYOBJECTEXT)(getProcAddr(\"glIsMemoryObjectEXT\"))\n\tgpIsNameAMD = (C.GPISNAMEAMD)(getProcAddr(\"glIsNameAMD\"))\n\tgpIsNamedBufferResidentNV = (C.GPISNAMEDBUFFERRESIDENTNV)(getProcAddr(\"glIsNamedBufferResidentNV\"))\n\tgpIsNamedStringARB = (C.GPISNAMEDSTRINGARB)(getProcAddr(\"glIsNamedStringARB\"))\n\tgpIsObjectBufferATI = (C.GPISOBJECTBUFFERATI)(getProcAddr(\"glIsObjectBufferATI\"))\n\tgpIsOcclusionQueryNV = (C.GPISOCCLUSIONQUERYNV)(getProcAddr(\"glIsOcclusionQueryNV\"))\n\tgpIsPathNV = (C.GPISPATHNV)(getProcAddr(\"glIsPathNV\"))\n\tgpIsPointInFillPathNV = (C.GPISPOINTINFILLPATHNV)(getProcAddr(\"glIsPointInFillPathNV\"))\n\tgpIsPointInStrokePathNV = (C.GPISPOINTINSTROKEPATHNV)(getProcAddr(\"glIsPointInStrokePathNV\"))\n\tgpIsProgram = (C.GPISPROGRAM)(getProcAddr(\"glIsProgram\"))\n\tif gpIsProgram == nil {\n\t\treturn errors.New(\"glIsProgram\")\n\t}\n\tgpIsProgramARB = (C.GPISPROGRAMARB)(getProcAddr(\"glIsProgramARB\"))\n\tgpIsProgramNV = (C.GPISPROGRAMNV)(getProcAddr(\"glIsProgramNV\"))\n\tgpIsProgramPipeline = (C.GPISPROGRAMPIPELINE)(getProcAddr(\"glIsProgramPipeline\"))\n\tif gpIsProgramPipeline == nil {\n\t\treturn errors.New(\"glIsProgramPipeline\")\n\t}\n\tgpIsProgramPipelineEXT = (C.GPISPROGRAMPIPELINEEXT)(getProcAddr(\"glIsProgramPipelineEXT\"))\n\tgpIsQuery = (C.GPISQUERY)(getProcAddr(\"glIsQuery\"))\n\tif gpIsQuery == nil {\n\t\treturn errors.New(\"glIsQuery\")\n\t}\n\tgpIsQueryARB = (C.GPISQUERYARB)(getProcAddr(\"glIsQueryARB\"))\n\tgpIsRenderbuffer = (C.GPISRENDERBUFFER)(getProcAddr(\"glIsRenderbuffer\"))\n\tif gpIsRenderbuffer == nil {\n\t\treturn errors.New(\"glIsRenderbuffer\")\n\t}\n\tgpIsRenderbufferEXT = (C.GPISRENDERBUFFEREXT)(getProcAddr(\"glIsRenderbufferEXT\"))\n\tgpIsSampler = (C.GPISSAMPLER)(getProcAddr(\"glIsSampler\"))\n\tif gpIsSampler == nil {\n\t\treturn errors.New(\"glIsSampler\")\n\t}\n\tgpIsSemaphoreEXT = (C.GPISSEMAPHOREEXT)(getProcAddr(\"glIsSemaphoreEXT\"))\n\tgpIsShader = (C.GPISSHADER)(getProcAddr(\"glIsShader\"))\n\tif gpIsShader == nil {\n\t\treturn errors.New(\"glIsShader\")\n\t}\n\tgpIsStateNV = (C.GPISSTATENV)(getProcAddr(\"glIsStateNV\"))\n\tgpIsSync = (C.GPISSYNC)(getProcAddr(\"glIsSync\"))\n\tif gpIsSync == nil {\n\t\treturn errors.New(\"glIsSync\")\n\t}\n\tgpIsTexture = (C.GPISTEXTURE)(getProcAddr(\"glIsTexture\"))\n\tif gpIsTexture == nil {\n\t\treturn errors.New(\"glIsTexture\")\n\t}\n\tgpIsTextureEXT = (C.GPISTEXTUREEXT)(getProcAddr(\"glIsTextureEXT\"))\n\tgpIsTextureHandleResidentARB = (C.GPISTEXTUREHANDLERESIDENTARB)(getProcAddr(\"glIsTextureHandleResidentARB\"))\n\tgpIsTextureHandleResidentNV = (C.GPISTEXTUREHANDLERESIDENTNV)(getProcAddr(\"glIsTextureHandleResidentNV\"))\n\tgpIsTransformFeedback = (C.GPISTRANSFORMFEEDBACK)(getProcAddr(\"glIsTransformFeedback\"))\n\tif gpIsTransformFeedback == nil {\n\t\treturn errors.New(\"glIsTransformFeedback\")\n\t}\n\tgpIsTransformFeedbackNV = (C.GPISTRANSFORMFEEDBACKNV)(getProcAddr(\"glIsTransformFeedbackNV\"))\n\tgpIsVariantEnabledEXT = (C.GPISVARIANTENABLEDEXT)(getProcAddr(\"glIsVariantEnabledEXT\"))\n\tgpIsVertexArray = (C.GPISVERTEXARRAY)(getProcAddr(\"glIsVertexArray\"))\n\tif gpIsVertexArray == nil {\n\t\treturn errors.New(\"glIsVertexArray\")\n\t}\n\tgpIsVertexArrayAPPLE = (C.GPISVERTEXARRAYAPPLE)(getProcAddr(\"glIsVertexArrayAPPLE\"))\n\tgpIsVertexAttribEnabledAPPLE = (C.GPISVERTEXATTRIBENABLEDAPPLE)(getProcAddr(\"glIsVertexAttribEnabledAPPLE\"))\n\tgpLGPUCopyImageSubDataNVX = (C.GPLGPUCOPYIMAGESUBDATANVX)(getProcAddr(\"glLGPUCopyImageSubDataNVX\"))\n\tgpLGPUInterlockNVX = (C.GPLGPUINTERLOCKNVX)(getProcAddr(\"glLGPUInterlockNVX\"))\n\tgpLGPUNamedBufferSubDataNVX = (C.GPLGPUNAMEDBUFFERSUBDATANVX)(getProcAddr(\"glLGPUNamedBufferSubDataNVX\"))\n\tgpLabelObjectEXT = (C.GPLABELOBJECTEXT)(getProcAddr(\"glLabelObjectEXT\"))\n\tgpLightEnviSGIX = (C.GPLIGHTENVISGIX)(getProcAddr(\"glLightEnviSGIX\"))\n\tgpLightModelf = (C.GPLIGHTMODELF)(getProcAddr(\"glLightModelf\"))\n\tif gpLightModelf == nil {\n\t\treturn errors.New(\"glLightModelf\")\n\t}\n\tgpLightModelfv = (C.GPLIGHTMODELFV)(getProcAddr(\"glLightModelfv\"))\n\tif gpLightModelfv == nil {\n\t\treturn errors.New(\"glLightModelfv\")\n\t}\n\tgpLightModeli = (C.GPLIGHTMODELI)(getProcAddr(\"glLightModeli\"))\n\tif gpLightModeli == nil {\n\t\treturn errors.New(\"glLightModeli\")\n\t}\n\tgpLightModeliv = (C.GPLIGHTMODELIV)(getProcAddr(\"glLightModeliv\"))\n\tif gpLightModeliv == nil {\n\t\treturn errors.New(\"glLightModeliv\")\n\t}\n\tgpLightModelxOES = (C.GPLIGHTMODELXOES)(getProcAddr(\"glLightModelxOES\"))\n\tgpLightModelxvOES = (C.GPLIGHTMODELXVOES)(getProcAddr(\"glLightModelxvOES\"))\n\tgpLightf = (C.GPLIGHTF)(getProcAddr(\"glLightf\"))\n\tif gpLightf == nil {\n\t\treturn errors.New(\"glLightf\")\n\t}\n\tgpLightfv = (C.GPLIGHTFV)(getProcAddr(\"glLightfv\"))\n\tif gpLightfv == nil {\n\t\treturn errors.New(\"glLightfv\")\n\t}\n\tgpLighti = (C.GPLIGHTI)(getProcAddr(\"glLighti\"))\n\tif gpLighti == nil {\n\t\treturn errors.New(\"glLighti\")\n\t}\n\tgpLightiv = (C.GPLIGHTIV)(getProcAddr(\"glLightiv\"))\n\tif gpLightiv == nil {\n\t\treturn errors.New(\"glLightiv\")\n\t}\n\tgpLightxOES = (C.GPLIGHTXOES)(getProcAddr(\"glLightxOES\"))\n\tgpLightxvOES = (C.GPLIGHTXVOES)(getProcAddr(\"glLightxvOES\"))\n\tgpLineStipple = (C.GPLINESTIPPLE)(getProcAddr(\"glLineStipple\"))\n\tif gpLineStipple == nil {\n\t\treturn errors.New(\"glLineStipple\")\n\t}\n\tgpLineWidth = (C.GPLINEWIDTH)(getProcAddr(\"glLineWidth\"))\n\tif gpLineWidth == nil {\n\t\treturn errors.New(\"glLineWidth\")\n\t}\n\tgpLineWidthxOES = (C.GPLINEWIDTHXOES)(getProcAddr(\"glLineWidthxOES\"))\n\tgpLinkProgram = (C.GPLINKPROGRAM)(getProcAddr(\"glLinkProgram\"))\n\tif gpLinkProgram == nil {\n\t\treturn errors.New(\"glLinkProgram\")\n\t}\n\tgpLinkProgramARB = (C.GPLINKPROGRAMARB)(getProcAddr(\"glLinkProgramARB\"))\n\tgpListBase = (C.GPLISTBASE)(getProcAddr(\"glListBase\"))\n\tif gpListBase == nil {\n\t\treturn errors.New(\"glListBase\")\n\t}\n\tgpListDrawCommandsStatesClientNV = (C.GPLISTDRAWCOMMANDSSTATESCLIENTNV)(getProcAddr(\"glListDrawCommandsStatesClientNV\"))\n\tgpListParameterfSGIX = (C.GPLISTPARAMETERFSGIX)(getProcAddr(\"glListParameterfSGIX\"))\n\tgpListParameterfvSGIX = (C.GPLISTPARAMETERFVSGIX)(getProcAddr(\"glListParameterfvSGIX\"))\n\tgpListParameteriSGIX = (C.GPLISTPARAMETERISGIX)(getProcAddr(\"glListParameteriSGIX\"))\n\tgpListParameterivSGIX = (C.GPLISTPARAMETERIVSGIX)(getProcAddr(\"glListParameterivSGIX\"))\n\tgpLoadIdentity = (C.GPLOADIDENTITY)(getProcAddr(\"glLoadIdentity\"))\n\tif gpLoadIdentity == nil {\n\t\treturn errors.New(\"glLoadIdentity\")\n\t}\n\tgpLoadIdentityDeformationMapSGIX = (C.GPLOADIDENTITYDEFORMATIONMAPSGIX)(getProcAddr(\"glLoadIdentityDeformationMapSGIX\"))\n\tgpLoadMatrixd = (C.GPLOADMATRIXD)(getProcAddr(\"glLoadMatrixd\"))\n\tif gpLoadMatrixd == nil {\n\t\treturn errors.New(\"glLoadMatrixd\")\n\t}\n\tgpLoadMatrixf = (C.GPLOADMATRIXF)(getProcAddr(\"glLoadMatrixf\"))\n\tif gpLoadMatrixf == nil {\n\t\treturn errors.New(\"glLoadMatrixf\")\n\t}\n\tgpLoadMatrixxOES = (C.GPLOADMATRIXXOES)(getProcAddr(\"glLoadMatrixxOES\"))\n\tgpLoadName = (C.GPLOADNAME)(getProcAddr(\"glLoadName\"))\n\tif gpLoadName == nil {\n\t\treturn errors.New(\"glLoadName\")\n\t}\n\tgpLoadProgramNV = (C.GPLOADPROGRAMNV)(getProcAddr(\"glLoadProgramNV\"))\n\tgpLoadTransposeMatrixd = (C.GPLOADTRANSPOSEMATRIXD)(getProcAddr(\"glLoadTransposeMatrixd\"))\n\tif gpLoadTransposeMatrixd == nil {\n\t\treturn errors.New(\"glLoadTransposeMatrixd\")\n\t}\n\tgpLoadTransposeMatrixdARB = (C.GPLOADTRANSPOSEMATRIXDARB)(getProcAddr(\"glLoadTransposeMatrixdARB\"))\n\tgpLoadTransposeMatrixf = (C.GPLOADTRANSPOSEMATRIXF)(getProcAddr(\"glLoadTransposeMatrixf\"))\n\tif gpLoadTransposeMatrixf == nil {\n\t\treturn errors.New(\"glLoadTransposeMatrixf\")\n\t}\n\tgpLoadTransposeMatrixfARB = (C.GPLOADTRANSPOSEMATRIXFARB)(getProcAddr(\"glLoadTransposeMatrixfARB\"))\n\tgpLoadTransposeMatrixxOES = (C.GPLOADTRANSPOSEMATRIXXOES)(getProcAddr(\"glLoadTransposeMatrixxOES\"))\n\tgpLockArraysEXT = (C.GPLOCKARRAYSEXT)(getProcAddr(\"glLockArraysEXT\"))\n\tgpLogicOp = (C.GPLOGICOP)(getProcAddr(\"glLogicOp\"))\n\tif gpLogicOp == nil {\n\t\treturn errors.New(\"glLogicOp\")\n\t}\n\tgpMakeBufferNonResidentNV = (C.GPMAKEBUFFERNONRESIDENTNV)(getProcAddr(\"glMakeBufferNonResidentNV\"))\n\tgpMakeBufferResidentNV = (C.GPMAKEBUFFERRESIDENTNV)(getProcAddr(\"glMakeBufferResidentNV\"))\n\tgpMakeImageHandleNonResidentARB = (C.GPMAKEIMAGEHANDLENONRESIDENTARB)(getProcAddr(\"glMakeImageHandleNonResidentARB\"))\n\tgpMakeImageHandleNonResidentNV = (C.GPMAKEIMAGEHANDLENONRESIDENTNV)(getProcAddr(\"glMakeImageHandleNonResidentNV\"))\n\tgpMakeImageHandleResidentARB = (C.GPMAKEIMAGEHANDLERESIDENTARB)(getProcAddr(\"glMakeImageHandleResidentARB\"))\n\tgpMakeImageHandleResidentNV = (C.GPMAKEIMAGEHANDLERESIDENTNV)(getProcAddr(\"glMakeImageHandleResidentNV\"))\n\tgpMakeNamedBufferNonResidentNV = (C.GPMAKENAMEDBUFFERNONRESIDENTNV)(getProcAddr(\"glMakeNamedBufferNonResidentNV\"))\n\tgpMakeNamedBufferResidentNV = (C.GPMAKENAMEDBUFFERRESIDENTNV)(getProcAddr(\"glMakeNamedBufferResidentNV\"))\n\tgpMakeTextureHandleNonResidentARB = (C.GPMAKETEXTUREHANDLENONRESIDENTARB)(getProcAddr(\"glMakeTextureHandleNonResidentARB\"))\n\tgpMakeTextureHandleNonResidentNV = (C.GPMAKETEXTUREHANDLENONRESIDENTNV)(getProcAddr(\"glMakeTextureHandleNonResidentNV\"))\n\tgpMakeTextureHandleResidentARB = (C.GPMAKETEXTUREHANDLERESIDENTARB)(getProcAddr(\"glMakeTextureHandleResidentARB\"))\n\tgpMakeTextureHandleResidentNV = (C.GPMAKETEXTUREHANDLERESIDENTNV)(getProcAddr(\"glMakeTextureHandleResidentNV\"))\n\tgpMap1d = (C.GPMAP1D)(getProcAddr(\"glMap1d\"))\n\tif gpMap1d == nil {\n\t\treturn errors.New(\"glMap1d\")\n\t}\n\tgpMap1f = (C.GPMAP1F)(getProcAddr(\"glMap1f\"))\n\tif gpMap1f == nil {\n\t\treturn errors.New(\"glMap1f\")\n\t}\n\tgpMap1xOES = (C.GPMAP1XOES)(getProcAddr(\"glMap1xOES\"))\n\tgpMap2d = (C.GPMAP2D)(getProcAddr(\"glMap2d\"))\n\tif gpMap2d == nil {\n\t\treturn errors.New(\"glMap2d\")\n\t}\n\tgpMap2f = (C.GPMAP2F)(getProcAddr(\"glMap2f\"))\n\tif gpMap2f == nil {\n\t\treturn errors.New(\"glMap2f\")\n\t}\n\tgpMap2xOES = (C.GPMAP2XOES)(getProcAddr(\"glMap2xOES\"))\n\tgpMapBuffer = (C.GPMAPBUFFER)(getProcAddr(\"glMapBuffer\"))\n\tif gpMapBuffer == nil {\n\t\treturn errors.New(\"glMapBuffer\")\n\t}\n\tgpMapBufferARB = (C.GPMAPBUFFERARB)(getProcAddr(\"glMapBufferARB\"))\n\tgpMapBufferRange = (C.GPMAPBUFFERRANGE)(getProcAddr(\"glMapBufferRange\"))\n\tif gpMapBufferRange == nil {\n\t\treturn errors.New(\"glMapBufferRange\")\n\t}\n\tgpMapControlPointsNV = (C.GPMAPCONTROLPOINTSNV)(getProcAddr(\"glMapControlPointsNV\"))\n\tgpMapGrid1d = (C.GPMAPGRID1D)(getProcAddr(\"glMapGrid1d\"))\n\tif gpMapGrid1d == nil {\n\t\treturn errors.New(\"glMapGrid1d\")\n\t}\n\tgpMapGrid1f = (C.GPMAPGRID1F)(getProcAddr(\"glMapGrid1f\"))\n\tif gpMapGrid1f == nil {\n\t\treturn errors.New(\"glMapGrid1f\")\n\t}\n\tgpMapGrid1xOES = (C.GPMAPGRID1XOES)(getProcAddr(\"glMapGrid1xOES\"))\n\tgpMapGrid2d = (C.GPMAPGRID2D)(getProcAddr(\"glMapGrid2d\"))\n\tif gpMapGrid2d == nil {\n\t\treturn errors.New(\"glMapGrid2d\")\n\t}\n\tgpMapGrid2f = (C.GPMAPGRID2F)(getProcAddr(\"glMapGrid2f\"))\n\tif gpMapGrid2f == nil {\n\t\treturn errors.New(\"glMapGrid2f\")\n\t}\n\tgpMapGrid2xOES = (C.GPMAPGRID2XOES)(getProcAddr(\"glMapGrid2xOES\"))\n\tgpMapNamedBuffer = (C.GPMAPNAMEDBUFFER)(getProcAddr(\"glMapNamedBuffer\"))\n\tgpMapNamedBufferEXT = (C.GPMAPNAMEDBUFFEREXT)(getProcAddr(\"glMapNamedBufferEXT\"))\n\tgpMapNamedBufferRange = (C.GPMAPNAMEDBUFFERRANGE)(getProcAddr(\"glMapNamedBufferRange\"))\n\tgpMapNamedBufferRangeEXT = (C.GPMAPNAMEDBUFFERRANGEEXT)(getProcAddr(\"glMapNamedBufferRangeEXT\"))\n\tgpMapObjectBufferATI = (C.GPMAPOBJECTBUFFERATI)(getProcAddr(\"glMapObjectBufferATI\"))\n\tgpMapParameterfvNV = (C.GPMAPPARAMETERFVNV)(getProcAddr(\"glMapParameterfvNV\"))\n\tgpMapParameterivNV = (C.GPMAPPARAMETERIVNV)(getProcAddr(\"glMapParameterivNV\"))\n\tgpMapTexture2DINTEL = (C.GPMAPTEXTURE2DINTEL)(getProcAddr(\"glMapTexture2DINTEL\"))\n\tgpMapVertexAttrib1dAPPLE = (C.GPMAPVERTEXATTRIB1DAPPLE)(getProcAddr(\"glMapVertexAttrib1dAPPLE\"))\n\tgpMapVertexAttrib1fAPPLE = (C.GPMAPVERTEXATTRIB1FAPPLE)(getProcAddr(\"glMapVertexAttrib1fAPPLE\"))\n\tgpMapVertexAttrib2dAPPLE = (C.GPMAPVERTEXATTRIB2DAPPLE)(getProcAddr(\"glMapVertexAttrib2dAPPLE\"))\n\tgpMapVertexAttrib2fAPPLE = (C.GPMAPVERTEXATTRIB2FAPPLE)(getProcAddr(\"glMapVertexAttrib2fAPPLE\"))\n\tgpMaterialf = (C.GPMATERIALF)(getProcAddr(\"glMaterialf\"))\n\tif gpMaterialf == nil {\n\t\treturn errors.New(\"glMaterialf\")\n\t}\n\tgpMaterialfv = (C.GPMATERIALFV)(getProcAddr(\"glMaterialfv\"))\n\tif gpMaterialfv == nil {\n\t\treturn errors.New(\"glMaterialfv\")\n\t}\n\tgpMateriali = (C.GPMATERIALI)(getProcAddr(\"glMateriali\"))\n\tif gpMateriali == nil {\n\t\treturn errors.New(\"glMateriali\")\n\t}\n\tgpMaterialiv = (C.GPMATERIALIV)(getProcAddr(\"glMaterialiv\"))\n\tif gpMaterialiv == nil {\n\t\treturn errors.New(\"glMaterialiv\")\n\t}\n\tgpMaterialxOES = (C.GPMATERIALXOES)(getProcAddr(\"glMaterialxOES\"))\n\tgpMaterialxvOES = (C.GPMATERIALXVOES)(getProcAddr(\"glMaterialxvOES\"))\n\tgpMatrixFrustumEXT = (C.GPMATRIXFRUSTUMEXT)(getProcAddr(\"glMatrixFrustumEXT\"))\n\tgpMatrixIndexPointerARB = (C.GPMATRIXINDEXPOINTERARB)(getProcAddr(\"glMatrixIndexPointerARB\"))\n\tgpMatrixIndexubvARB = (C.GPMATRIXINDEXUBVARB)(getProcAddr(\"glMatrixIndexubvARB\"))\n\tgpMatrixIndexuivARB = (C.GPMATRIXINDEXUIVARB)(getProcAddr(\"glMatrixIndexuivARB\"))\n\tgpMatrixIndexusvARB = (C.GPMATRIXINDEXUSVARB)(getProcAddr(\"glMatrixIndexusvARB\"))\n\tgpMatrixLoad3x2fNV = (C.GPMATRIXLOAD3X2FNV)(getProcAddr(\"glMatrixLoad3x2fNV\"))\n\tgpMatrixLoad3x3fNV = (C.GPMATRIXLOAD3X3FNV)(getProcAddr(\"glMatrixLoad3x3fNV\"))\n\tgpMatrixLoadIdentityEXT = (C.GPMATRIXLOADIDENTITYEXT)(getProcAddr(\"glMatrixLoadIdentityEXT\"))\n\tgpMatrixLoadTranspose3x3fNV = (C.GPMATRIXLOADTRANSPOSE3X3FNV)(getProcAddr(\"glMatrixLoadTranspose3x3fNV\"))\n\tgpMatrixLoadTransposedEXT = (C.GPMATRIXLOADTRANSPOSEDEXT)(getProcAddr(\"glMatrixLoadTransposedEXT\"))\n\tgpMatrixLoadTransposefEXT = (C.GPMATRIXLOADTRANSPOSEFEXT)(getProcAddr(\"glMatrixLoadTransposefEXT\"))\n\tgpMatrixLoaddEXT = (C.GPMATRIXLOADDEXT)(getProcAddr(\"glMatrixLoaddEXT\"))\n\tgpMatrixLoadfEXT = (C.GPMATRIXLOADFEXT)(getProcAddr(\"glMatrixLoadfEXT\"))\n\tgpMatrixMode = (C.GPMATRIXMODE)(getProcAddr(\"glMatrixMode\"))\n\tif gpMatrixMode == nil {\n\t\treturn errors.New(\"glMatrixMode\")\n\t}\n\tgpMatrixMult3x2fNV = (C.GPMATRIXMULT3X2FNV)(getProcAddr(\"glMatrixMult3x2fNV\"))\n\tgpMatrixMult3x3fNV = (C.GPMATRIXMULT3X3FNV)(getProcAddr(\"glMatrixMult3x3fNV\"))\n\tgpMatrixMultTranspose3x3fNV = (C.GPMATRIXMULTTRANSPOSE3X3FNV)(getProcAddr(\"glMatrixMultTranspose3x3fNV\"))\n\tgpMatrixMultTransposedEXT = (C.GPMATRIXMULTTRANSPOSEDEXT)(getProcAddr(\"glMatrixMultTransposedEXT\"))\n\tgpMatrixMultTransposefEXT = (C.GPMATRIXMULTTRANSPOSEFEXT)(getProcAddr(\"glMatrixMultTransposefEXT\"))\n\tgpMatrixMultdEXT = (C.GPMATRIXMULTDEXT)(getProcAddr(\"glMatrixMultdEXT\"))\n\tgpMatrixMultfEXT = (C.GPMATRIXMULTFEXT)(getProcAddr(\"glMatrixMultfEXT\"))\n\tgpMatrixOrthoEXT = (C.GPMATRIXORTHOEXT)(getProcAddr(\"glMatrixOrthoEXT\"))\n\tgpMatrixPopEXT = (C.GPMATRIXPOPEXT)(getProcAddr(\"glMatrixPopEXT\"))\n\tgpMatrixPushEXT = (C.GPMATRIXPUSHEXT)(getProcAddr(\"glMatrixPushEXT\"))\n\tgpMatrixRotatedEXT = (C.GPMATRIXROTATEDEXT)(getProcAddr(\"glMatrixRotatedEXT\"))\n\tgpMatrixRotatefEXT = (C.GPMATRIXROTATEFEXT)(getProcAddr(\"glMatrixRotatefEXT\"))\n\tgpMatrixScaledEXT = (C.GPMATRIXSCALEDEXT)(getProcAddr(\"glMatrixScaledEXT\"))\n\tgpMatrixScalefEXT = (C.GPMATRIXSCALEFEXT)(getProcAddr(\"glMatrixScalefEXT\"))\n\tgpMatrixTranslatedEXT = (C.GPMATRIXTRANSLATEDEXT)(getProcAddr(\"glMatrixTranslatedEXT\"))\n\tgpMatrixTranslatefEXT = (C.GPMATRIXTRANSLATEFEXT)(getProcAddr(\"glMatrixTranslatefEXT\"))\n\tgpMaxShaderCompilerThreadsARB = (C.GPMAXSHADERCOMPILERTHREADSARB)(getProcAddr(\"glMaxShaderCompilerThreadsARB\"))\n\tgpMaxShaderCompilerThreadsKHR = (C.GPMAXSHADERCOMPILERTHREADSKHR)(getProcAddr(\"glMaxShaderCompilerThreadsKHR\"))\n\tgpMemoryBarrier = (C.GPMEMORYBARRIER)(getProcAddr(\"glMemoryBarrier\"))\n\tif gpMemoryBarrier == nil {\n\t\treturn errors.New(\"glMemoryBarrier\")\n\t}\n\tgpMemoryBarrierByRegion = (C.GPMEMORYBARRIERBYREGION)(getProcAddr(\"glMemoryBarrierByRegion\"))\n\tgpMemoryBarrierEXT = (C.GPMEMORYBARRIEREXT)(getProcAddr(\"glMemoryBarrierEXT\"))\n\tgpMemoryObjectParameterivEXT = (C.GPMEMORYOBJECTPARAMETERIVEXT)(getProcAddr(\"glMemoryObjectParameterivEXT\"))\n\tgpMinSampleShading = (C.GPMINSAMPLESHADING)(getProcAddr(\"glMinSampleShading\"))\n\tif gpMinSampleShading == nil {\n\t\treturn errors.New(\"glMinSampleShading\")\n\t}\n\tgpMinSampleShadingARB = (C.GPMINSAMPLESHADINGARB)(getProcAddr(\"glMinSampleShadingARB\"))\n\tgpMinmax = (C.GPMINMAX)(getProcAddr(\"glMinmax\"))\n\tgpMinmaxEXT = (C.GPMINMAXEXT)(getProcAddr(\"glMinmaxEXT\"))\n\tgpMultMatrixd = (C.GPMULTMATRIXD)(getProcAddr(\"glMultMatrixd\"))\n\tif gpMultMatrixd == nil {\n\t\treturn errors.New(\"glMultMatrixd\")\n\t}\n\tgpMultMatrixf = (C.GPMULTMATRIXF)(getProcAddr(\"glMultMatrixf\"))\n\tif gpMultMatrixf == nil {\n\t\treturn errors.New(\"glMultMatrixf\")\n\t}\n\tgpMultMatrixxOES = (C.GPMULTMATRIXXOES)(getProcAddr(\"glMultMatrixxOES\"))\n\tgpMultTransposeMatrixd = (C.GPMULTTRANSPOSEMATRIXD)(getProcAddr(\"glMultTransposeMatrixd\"))\n\tif gpMultTransposeMatrixd == nil {\n\t\treturn errors.New(\"glMultTransposeMatrixd\")\n\t}\n\tgpMultTransposeMatrixdARB = (C.GPMULTTRANSPOSEMATRIXDARB)(getProcAddr(\"glMultTransposeMatrixdARB\"))\n\tgpMultTransposeMatrixf = (C.GPMULTTRANSPOSEMATRIXF)(getProcAddr(\"glMultTransposeMatrixf\"))\n\tif gpMultTransposeMatrixf == nil {\n\t\treturn errors.New(\"glMultTransposeMatrixf\")\n\t}\n\tgpMultTransposeMatrixfARB = (C.GPMULTTRANSPOSEMATRIXFARB)(getProcAddr(\"glMultTransposeMatrixfARB\"))\n\tgpMultTransposeMatrixxOES = (C.GPMULTTRANSPOSEMATRIXXOES)(getProcAddr(\"glMultTransposeMatrixxOES\"))\n\tgpMultiDrawArrays = (C.GPMULTIDRAWARRAYS)(getProcAddr(\"glMultiDrawArrays\"))\n\tif gpMultiDrawArrays == nil {\n\t\treturn errors.New(\"glMultiDrawArrays\")\n\t}\n\tgpMultiDrawArraysEXT = (C.GPMULTIDRAWARRAYSEXT)(getProcAddr(\"glMultiDrawArraysEXT\"))\n\tgpMultiDrawArraysIndirect = (C.GPMULTIDRAWARRAYSINDIRECT)(getProcAddr(\"glMultiDrawArraysIndirect\"))\n\tif gpMultiDrawArraysIndirect == nil {\n\t\treturn errors.New(\"glMultiDrawArraysIndirect\")\n\t}\n\tgpMultiDrawArraysIndirectAMD = (C.GPMULTIDRAWARRAYSINDIRECTAMD)(getProcAddr(\"glMultiDrawArraysIndirectAMD\"))\n\tgpMultiDrawArraysIndirectBindlessCountNV = (C.GPMULTIDRAWARRAYSINDIRECTBINDLESSCOUNTNV)(getProcAddr(\"glMultiDrawArraysIndirectBindlessCountNV\"))\n\tgpMultiDrawArraysIndirectBindlessNV = (C.GPMULTIDRAWARRAYSINDIRECTBINDLESSNV)(getProcAddr(\"glMultiDrawArraysIndirectBindlessNV\"))\n\tgpMultiDrawArraysIndirectCountARB = (C.GPMULTIDRAWARRAYSINDIRECTCOUNTARB)(getProcAddr(\"glMultiDrawArraysIndirectCountARB\"))\n\tgpMultiDrawElementArrayAPPLE = (C.GPMULTIDRAWELEMENTARRAYAPPLE)(getProcAddr(\"glMultiDrawElementArrayAPPLE\"))\n\tgpMultiDrawElements = (C.GPMULTIDRAWELEMENTS)(getProcAddr(\"glMultiDrawElements\"))\n\tif gpMultiDrawElements == nil {\n\t\treturn errors.New(\"glMultiDrawElements\")\n\t}\n\tgpMultiDrawElementsBaseVertex = (C.GPMULTIDRAWELEMENTSBASEVERTEX)(getProcAddr(\"glMultiDrawElementsBaseVertex\"))\n\tif gpMultiDrawElementsBaseVertex == nil {\n\t\treturn errors.New(\"glMultiDrawElementsBaseVertex\")\n\t}\n\tgpMultiDrawElementsEXT = (C.GPMULTIDRAWELEMENTSEXT)(getProcAddr(\"glMultiDrawElementsEXT\"))\n\tgpMultiDrawElementsIndirect = (C.GPMULTIDRAWELEMENTSINDIRECT)(getProcAddr(\"glMultiDrawElementsIndirect\"))\n\tif gpMultiDrawElementsIndirect == nil {\n\t\treturn errors.New(\"glMultiDrawElementsIndirect\")\n\t}\n\tgpMultiDrawElementsIndirectAMD = (C.GPMULTIDRAWELEMENTSINDIRECTAMD)(getProcAddr(\"glMultiDrawElementsIndirectAMD\"))\n\tgpMultiDrawElementsIndirectBindlessCountNV = (C.GPMULTIDRAWELEMENTSINDIRECTBINDLESSCOUNTNV)(getProcAddr(\"glMultiDrawElementsIndirectBindlessCountNV\"))\n\tgpMultiDrawElementsIndirectBindlessNV = (C.GPMULTIDRAWELEMENTSINDIRECTBINDLESSNV)(getProcAddr(\"glMultiDrawElementsIndirectBindlessNV\"))\n\tgpMultiDrawElementsIndirectCountARB = (C.GPMULTIDRAWELEMENTSINDIRECTCOUNTARB)(getProcAddr(\"glMultiDrawElementsIndirectCountARB\"))\n\tgpMultiDrawMeshTasksIndirectCountNV = (C.GPMULTIDRAWMESHTASKSINDIRECTCOUNTNV)(getProcAddr(\"glMultiDrawMeshTasksIndirectCountNV\"))\n\tgpMultiDrawMeshTasksIndirectNV = (C.GPMULTIDRAWMESHTASKSINDIRECTNV)(getProcAddr(\"glMultiDrawMeshTasksIndirectNV\"))\n\tgpMultiDrawRangeElementArrayAPPLE = (C.GPMULTIDRAWRANGEELEMENTARRAYAPPLE)(getProcAddr(\"glMultiDrawRangeElementArrayAPPLE\"))\n\tgpMultiModeDrawArraysIBM = (C.GPMULTIMODEDRAWARRAYSIBM)(getProcAddr(\"glMultiModeDrawArraysIBM\"))\n\tgpMultiModeDrawElementsIBM = (C.GPMULTIMODEDRAWELEMENTSIBM)(getProcAddr(\"glMultiModeDrawElementsIBM\"))\n\tgpMultiTexBufferEXT = (C.GPMULTITEXBUFFEREXT)(getProcAddr(\"glMultiTexBufferEXT\"))\n\tgpMultiTexCoord1bOES = (C.GPMULTITEXCOORD1BOES)(getProcAddr(\"glMultiTexCoord1bOES\"))\n\tgpMultiTexCoord1bvOES = (C.GPMULTITEXCOORD1BVOES)(getProcAddr(\"glMultiTexCoord1bvOES\"))\n\tgpMultiTexCoord1d = (C.GPMULTITEXCOORD1D)(getProcAddr(\"glMultiTexCoord1d\"))\n\tif gpMultiTexCoord1d == nil {\n\t\treturn errors.New(\"glMultiTexCoord1d\")\n\t}\n\tgpMultiTexCoord1dARB = (C.GPMULTITEXCOORD1DARB)(getProcAddr(\"glMultiTexCoord1dARB\"))\n\tgpMultiTexCoord1dv = (C.GPMULTITEXCOORD1DV)(getProcAddr(\"glMultiTexCoord1dv\"))\n\tif gpMultiTexCoord1dv == nil {\n\t\treturn errors.New(\"glMultiTexCoord1dv\")\n\t}\n\tgpMultiTexCoord1dvARB = (C.GPMULTITEXCOORD1DVARB)(getProcAddr(\"glMultiTexCoord1dvARB\"))\n\tgpMultiTexCoord1f = (C.GPMULTITEXCOORD1F)(getProcAddr(\"glMultiTexCoord1f\"))\n\tif gpMultiTexCoord1f == nil {\n\t\treturn errors.New(\"glMultiTexCoord1f\")\n\t}\n\tgpMultiTexCoord1fARB = (C.GPMULTITEXCOORD1FARB)(getProcAddr(\"glMultiTexCoord1fARB\"))\n\tgpMultiTexCoord1fv = (C.GPMULTITEXCOORD1FV)(getProcAddr(\"glMultiTexCoord1fv\"))\n\tif gpMultiTexCoord1fv == nil {\n\t\treturn errors.New(\"glMultiTexCoord1fv\")\n\t}\n\tgpMultiTexCoord1fvARB = (C.GPMULTITEXCOORD1FVARB)(getProcAddr(\"glMultiTexCoord1fvARB\"))\n\tgpMultiTexCoord1hNV = (C.GPMULTITEXCOORD1HNV)(getProcAddr(\"glMultiTexCoord1hNV\"))\n\tgpMultiTexCoord1hvNV = (C.GPMULTITEXCOORD1HVNV)(getProcAddr(\"glMultiTexCoord1hvNV\"))\n\tgpMultiTexCoord1i = (C.GPMULTITEXCOORD1I)(getProcAddr(\"glMultiTexCoord1i\"))\n\tif gpMultiTexCoord1i == nil {\n\t\treturn errors.New(\"glMultiTexCoord1i\")\n\t}\n\tgpMultiTexCoord1iARB = (C.GPMULTITEXCOORD1IARB)(getProcAddr(\"glMultiTexCoord1iARB\"))\n\tgpMultiTexCoord1iv = (C.GPMULTITEXCOORD1IV)(getProcAddr(\"glMultiTexCoord1iv\"))\n\tif gpMultiTexCoord1iv == nil {\n\t\treturn errors.New(\"glMultiTexCoord1iv\")\n\t}\n\tgpMultiTexCoord1ivARB = (C.GPMULTITEXCOORD1IVARB)(getProcAddr(\"glMultiTexCoord1ivARB\"))\n\tgpMultiTexCoord1s = (C.GPMULTITEXCOORD1S)(getProcAddr(\"glMultiTexCoord1s\"))\n\tif gpMultiTexCoord1s == nil {\n\t\treturn errors.New(\"glMultiTexCoord1s\")\n\t}\n\tgpMultiTexCoord1sARB = (C.GPMULTITEXCOORD1SARB)(getProcAddr(\"glMultiTexCoord1sARB\"))\n\tgpMultiTexCoord1sv = (C.GPMULTITEXCOORD1SV)(getProcAddr(\"glMultiTexCoord1sv\"))\n\tif gpMultiTexCoord1sv == nil {\n\t\treturn errors.New(\"glMultiTexCoord1sv\")\n\t}\n\tgpMultiTexCoord1svARB = (C.GPMULTITEXCOORD1SVARB)(getProcAddr(\"glMultiTexCoord1svARB\"))\n\tgpMultiTexCoord1xOES = (C.GPMULTITEXCOORD1XOES)(getProcAddr(\"glMultiTexCoord1xOES\"))\n\tgpMultiTexCoord1xvOES = (C.GPMULTITEXCOORD1XVOES)(getProcAddr(\"glMultiTexCoord1xvOES\"))\n\tgpMultiTexCoord2bOES = (C.GPMULTITEXCOORD2BOES)(getProcAddr(\"glMultiTexCoord2bOES\"))\n\tgpMultiTexCoord2bvOES = (C.GPMULTITEXCOORD2BVOES)(getProcAddr(\"glMultiTexCoord2bvOES\"))\n\tgpMultiTexCoord2d = (C.GPMULTITEXCOORD2D)(getProcAddr(\"glMultiTexCoord2d\"))\n\tif gpMultiTexCoord2d == nil {\n\t\treturn errors.New(\"glMultiTexCoord2d\")\n\t}\n\tgpMultiTexCoord2dARB = (C.GPMULTITEXCOORD2DARB)(getProcAddr(\"glMultiTexCoord2dARB\"))\n\tgpMultiTexCoord2dv = (C.GPMULTITEXCOORD2DV)(getProcAddr(\"glMultiTexCoord2dv\"))\n\tif gpMultiTexCoord2dv == nil {\n\t\treturn errors.New(\"glMultiTexCoord2dv\")\n\t}\n\tgpMultiTexCoord2dvARB = (C.GPMULTITEXCOORD2DVARB)(getProcAddr(\"glMultiTexCoord2dvARB\"))\n\tgpMultiTexCoord2f = (C.GPMULTITEXCOORD2F)(getProcAddr(\"glMultiTexCoord2f\"))\n\tif gpMultiTexCoord2f == nil {\n\t\treturn errors.New(\"glMultiTexCoord2f\")\n\t}\n\tgpMultiTexCoord2fARB = (C.GPMULTITEXCOORD2FARB)(getProcAddr(\"glMultiTexCoord2fARB\"))\n\tgpMultiTexCoord2fv = (C.GPMULTITEXCOORD2FV)(getProcAddr(\"glMultiTexCoord2fv\"))\n\tif gpMultiTexCoord2fv == nil {\n\t\treturn errors.New(\"glMultiTexCoord2fv\")\n\t}\n\tgpMultiTexCoord2fvARB = (C.GPMULTITEXCOORD2FVARB)(getProcAddr(\"glMultiTexCoord2fvARB\"))\n\tgpMultiTexCoord2hNV = (C.GPMULTITEXCOORD2HNV)(getProcAddr(\"glMultiTexCoord2hNV\"))\n\tgpMultiTexCoord2hvNV = (C.GPMULTITEXCOORD2HVNV)(getProcAddr(\"glMultiTexCoord2hvNV\"))\n\tgpMultiTexCoord2i = (C.GPMULTITEXCOORD2I)(getProcAddr(\"glMultiTexCoord2i\"))\n\tif gpMultiTexCoord2i == nil {\n\t\treturn errors.New(\"glMultiTexCoord2i\")\n\t}\n\tgpMultiTexCoord2iARB = (C.GPMULTITEXCOORD2IARB)(getProcAddr(\"glMultiTexCoord2iARB\"))\n\tgpMultiTexCoord2iv = (C.GPMULTITEXCOORD2IV)(getProcAddr(\"glMultiTexCoord2iv\"))\n\tif gpMultiTexCoord2iv == nil {\n\t\treturn errors.New(\"glMultiTexCoord2iv\")\n\t}\n\tgpMultiTexCoord2ivARB = (C.GPMULTITEXCOORD2IVARB)(getProcAddr(\"glMultiTexCoord2ivARB\"))\n\tgpMultiTexCoord2s = (C.GPMULTITEXCOORD2S)(getProcAddr(\"glMultiTexCoord2s\"))\n\tif gpMultiTexCoord2s == nil {\n\t\treturn errors.New(\"glMultiTexCoord2s\")\n\t}\n\tgpMultiTexCoord2sARB = (C.GPMULTITEXCOORD2SARB)(getProcAddr(\"glMultiTexCoord2sARB\"))\n\tgpMultiTexCoord2sv = (C.GPMULTITEXCOORD2SV)(getProcAddr(\"glMultiTexCoord2sv\"))\n\tif gpMultiTexCoord2sv == nil {\n\t\treturn errors.New(\"glMultiTexCoord2sv\")\n\t}\n\tgpMultiTexCoord2svARB = (C.GPMULTITEXCOORD2SVARB)(getProcAddr(\"glMultiTexCoord2svARB\"))\n\tgpMultiTexCoord2xOES = (C.GPMULTITEXCOORD2XOES)(getProcAddr(\"glMultiTexCoord2xOES\"))\n\tgpMultiTexCoord2xvOES = (C.GPMULTITEXCOORD2XVOES)(getProcAddr(\"glMultiTexCoord2xvOES\"))\n\tgpMultiTexCoord3bOES = (C.GPMULTITEXCOORD3BOES)(getProcAddr(\"glMultiTexCoord3bOES\"))\n\tgpMultiTexCoord3bvOES = (C.GPMULTITEXCOORD3BVOES)(getProcAddr(\"glMultiTexCoord3bvOES\"))\n\tgpMultiTexCoord3d = (C.GPMULTITEXCOORD3D)(getProcAddr(\"glMultiTexCoord3d\"))\n\tif gpMultiTexCoord3d == nil {\n\t\treturn errors.New(\"glMultiTexCoord3d\")\n\t}\n\tgpMultiTexCoord3dARB = (C.GPMULTITEXCOORD3DARB)(getProcAddr(\"glMultiTexCoord3dARB\"))\n\tgpMultiTexCoord3dv = (C.GPMULTITEXCOORD3DV)(getProcAddr(\"glMultiTexCoord3dv\"))\n\tif gpMultiTexCoord3dv == nil {\n\t\treturn errors.New(\"glMultiTexCoord3dv\")\n\t}\n\tgpMultiTexCoord3dvARB = (C.GPMULTITEXCOORD3DVARB)(getProcAddr(\"glMultiTexCoord3dvARB\"))\n\tgpMultiTexCoord3f = (C.GPMULTITEXCOORD3F)(getProcAddr(\"glMultiTexCoord3f\"))\n\tif gpMultiTexCoord3f == nil {\n\t\treturn errors.New(\"glMultiTexCoord3f\")\n\t}\n\tgpMultiTexCoord3fARB = (C.GPMULTITEXCOORD3FARB)(getProcAddr(\"glMultiTexCoord3fARB\"))\n\tgpMultiTexCoord3fv = (C.GPMULTITEXCOORD3FV)(getProcAddr(\"glMultiTexCoord3fv\"))\n\tif gpMultiTexCoord3fv == nil {\n\t\treturn errors.New(\"glMultiTexCoord3fv\")\n\t}\n\tgpMultiTexCoord3fvARB = (C.GPMULTITEXCOORD3FVARB)(getProcAddr(\"glMultiTexCoord3fvARB\"))\n\tgpMultiTexCoord3hNV = (C.GPMULTITEXCOORD3HNV)(getProcAddr(\"glMultiTexCoord3hNV\"))\n\tgpMultiTexCoord3hvNV = (C.GPMULTITEXCOORD3HVNV)(getProcAddr(\"glMultiTexCoord3hvNV\"))\n\tgpMultiTexCoord3i = (C.GPMULTITEXCOORD3I)(getProcAddr(\"glMultiTexCoord3i\"))\n\tif gpMultiTexCoord3i == nil {\n\t\treturn errors.New(\"glMultiTexCoord3i\")\n\t}\n\tgpMultiTexCoord3iARB = (C.GPMULTITEXCOORD3IARB)(getProcAddr(\"glMultiTexCoord3iARB\"))\n\tgpMultiTexCoord3iv = (C.GPMULTITEXCOORD3IV)(getProcAddr(\"glMultiTexCoord3iv\"))\n\tif gpMultiTexCoord3iv == nil {\n\t\treturn errors.New(\"glMultiTexCoord3iv\")\n\t}\n\tgpMultiTexCoord3ivARB = (C.GPMULTITEXCOORD3IVARB)(getProcAddr(\"glMultiTexCoord3ivARB\"))\n\tgpMultiTexCoord3s = (C.GPMULTITEXCOORD3S)(getProcAddr(\"glMultiTexCoord3s\"))\n\tif gpMultiTexCoord3s == nil {\n\t\treturn errors.New(\"glMultiTexCoord3s\")\n\t}\n\tgpMultiTexCoord3sARB = (C.GPMULTITEXCOORD3SARB)(getProcAddr(\"glMultiTexCoord3sARB\"))\n\tgpMultiTexCoord3sv = (C.GPMULTITEXCOORD3SV)(getProcAddr(\"glMultiTexCoord3sv\"))\n\tif gpMultiTexCoord3sv == nil {\n\t\treturn errors.New(\"glMultiTexCoord3sv\")\n\t}\n\tgpMultiTexCoord3svARB = (C.GPMULTITEXCOORD3SVARB)(getProcAddr(\"glMultiTexCoord3svARB\"))\n\tgpMultiTexCoord3xOES = (C.GPMULTITEXCOORD3XOES)(getProcAddr(\"glMultiTexCoord3xOES\"))\n\tgpMultiTexCoord3xvOES = (C.GPMULTITEXCOORD3XVOES)(getProcAddr(\"glMultiTexCoord3xvOES\"))\n\tgpMultiTexCoord4bOES = (C.GPMULTITEXCOORD4BOES)(getProcAddr(\"glMultiTexCoord4bOES\"))\n\tgpMultiTexCoord4bvOES = (C.GPMULTITEXCOORD4BVOES)(getProcAddr(\"glMultiTexCoord4bvOES\"))\n\tgpMultiTexCoord4d = (C.GPMULTITEXCOORD4D)(getProcAddr(\"glMultiTexCoord4d\"))\n\tif gpMultiTexCoord4d == nil {\n\t\treturn errors.New(\"glMultiTexCoord4d\")\n\t}\n\tgpMultiTexCoord4dARB = (C.GPMULTITEXCOORD4DARB)(getProcAddr(\"glMultiTexCoord4dARB\"))\n\tgpMultiTexCoord4dv = (C.GPMULTITEXCOORD4DV)(getProcAddr(\"glMultiTexCoord4dv\"))\n\tif gpMultiTexCoord4dv == nil {\n\t\treturn errors.New(\"glMultiTexCoord4dv\")\n\t}\n\tgpMultiTexCoord4dvARB = (C.GPMULTITEXCOORD4DVARB)(getProcAddr(\"glMultiTexCoord4dvARB\"))\n\tgpMultiTexCoord4f = (C.GPMULTITEXCOORD4F)(getProcAddr(\"glMultiTexCoord4f\"))\n\tif gpMultiTexCoord4f == nil {\n\t\treturn errors.New(\"glMultiTexCoord4f\")\n\t}\n\tgpMultiTexCoord4fARB = (C.GPMULTITEXCOORD4FARB)(getProcAddr(\"glMultiTexCoord4fARB\"))\n\tgpMultiTexCoord4fv = (C.GPMULTITEXCOORD4FV)(getProcAddr(\"glMultiTexCoord4fv\"))\n\tif gpMultiTexCoord4fv == nil {\n\t\treturn errors.New(\"glMultiTexCoord4fv\")\n\t}\n\tgpMultiTexCoord4fvARB = (C.GPMULTITEXCOORD4FVARB)(getProcAddr(\"glMultiTexCoord4fvARB\"))\n\tgpMultiTexCoord4hNV = (C.GPMULTITEXCOORD4HNV)(getProcAddr(\"glMultiTexCoord4hNV\"))\n\tgpMultiTexCoord4hvNV = (C.GPMULTITEXCOORD4HVNV)(getProcAddr(\"glMultiTexCoord4hvNV\"))\n\tgpMultiTexCoord4i = (C.GPMULTITEXCOORD4I)(getProcAddr(\"glMultiTexCoord4i\"))\n\tif gpMultiTexCoord4i == nil {\n\t\treturn errors.New(\"glMultiTexCoord4i\")\n\t}\n\tgpMultiTexCoord4iARB = (C.GPMULTITEXCOORD4IARB)(getProcAddr(\"glMultiTexCoord4iARB\"))\n\tgpMultiTexCoord4iv = (C.GPMULTITEXCOORD4IV)(getProcAddr(\"glMultiTexCoord4iv\"))\n\tif gpMultiTexCoord4iv == nil {\n\t\treturn errors.New(\"glMultiTexCoord4iv\")\n\t}\n\tgpMultiTexCoord4ivARB = (C.GPMULTITEXCOORD4IVARB)(getProcAddr(\"glMultiTexCoord4ivARB\"))\n\tgpMultiTexCoord4s = (C.GPMULTITEXCOORD4S)(getProcAddr(\"glMultiTexCoord4s\"))\n\tif gpMultiTexCoord4s == nil {\n\t\treturn errors.New(\"glMultiTexCoord4s\")\n\t}\n\tgpMultiTexCoord4sARB = (C.GPMULTITEXCOORD4SARB)(getProcAddr(\"glMultiTexCoord4sARB\"))\n\tgpMultiTexCoord4sv = (C.GPMULTITEXCOORD4SV)(getProcAddr(\"glMultiTexCoord4sv\"))\n\tif gpMultiTexCoord4sv == nil {\n\t\treturn errors.New(\"glMultiTexCoord4sv\")\n\t}\n\tgpMultiTexCoord4svARB = (C.GPMULTITEXCOORD4SVARB)(getProcAddr(\"glMultiTexCoord4svARB\"))\n\tgpMultiTexCoord4xOES = (C.GPMULTITEXCOORD4XOES)(getProcAddr(\"glMultiTexCoord4xOES\"))\n\tgpMultiTexCoord4xvOES = (C.GPMULTITEXCOORD4XVOES)(getProcAddr(\"glMultiTexCoord4xvOES\"))\n\tgpMultiTexCoordP1ui = (C.GPMULTITEXCOORDP1UI)(getProcAddr(\"glMultiTexCoordP1ui\"))\n\tif gpMultiTexCoordP1ui == nil {\n\t\treturn errors.New(\"glMultiTexCoordP1ui\")\n\t}\n\tgpMultiTexCoordP1uiv = (C.GPMULTITEXCOORDP1UIV)(getProcAddr(\"glMultiTexCoordP1uiv\"))\n\tif gpMultiTexCoordP1uiv == nil {\n\t\treturn errors.New(\"glMultiTexCoordP1uiv\")\n\t}\n\tgpMultiTexCoordP2ui = (C.GPMULTITEXCOORDP2UI)(getProcAddr(\"glMultiTexCoordP2ui\"))\n\tif gpMultiTexCoordP2ui == nil {\n\t\treturn errors.New(\"glMultiTexCoordP2ui\")\n\t}\n\tgpMultiTexCoordP2uiv = (C.GPMULTITEXCOORDP2UIV)(getProcAddr(\"glMultiTexCoordP2uiv\"))\n\tif gpMultiTexCoordP2uiv == nil {\n\t\treturn errors.New(\"glMultiTexCoordP2uiv\")\n\t}\n\tgpMultiTexCoordP3ui = (C.GPMULTITEXCOORDP3UI)(getProcAddr(\"glMultiTexCoordP3ui\"))\n\tif gpMultiTexCoordP3ui == nil {\n\t\treturn errors.New(\"glMultiTexCoordP3ui\")\n\t}\n\tgpMultiTexCoordP3uiv = (C.GPMULTITEXCOORDP3UIV)(getProcAddr(\"glMultiTexCoordP3uiv\"))\n\tif gpMultiTexCoordP3uiv == nil {\n\t\treturn errors.New(\"glMultiTexCoordP3uiv\")\n\t}\n\tgpMultiTexCoordP4ui = (C.GPMULTITEXCOORDP4UI)(getProcAddr(\"glMultiTexCoordP4ui\"))\n\tif gpMultiTexCoordP4ui == nil {\n\t\treturn errors.New(\"glMultiTexCoordP4ui\")\n\t}\n\tgpMultiTexCoordP4uiv = (C.GPMULTITEXCOORDP4UIV)(getProcAddr(\"glMultiTexCoordP4uiv\"))\n\tif gpMultiTexCoordP4uiv == nil {\n\t\treturn errors.New(\"glMultiTexCoordP4uiv\")\n\t}\n\tgpMultiTexCoordPointerEXT = (C.GPMULTITEXCOORDPOINTEREXT)(getProcAddr(\"glMultiTexCoordPointerEXT\"))\n\tgpMultiTexEnvfEXT = (C.GPMULTITEXENVFEXT)(getProcAddr(\"glMultiTexEnvfEXT\"))\n\tgpMultiTexEnvfvEXT = (C.GPMULTITEXENVFVEXT)(getProcAddr(\"glMultiTexEnvfvEXT\"))\n\tgpMultiTexEnviEXT = (C.GPMULTITEXENVIEXT)(getProcAddr(\"glMultiTexEnviEXT\"))\n\tgpMultiTexEnvivEXT = (C.GPMULTITEXENVIVEXT)(getProcAddr(\"glMultiTexEnvivEXT\"))\n\tgpMultiTexGendEXT = (C.GPMULTITEXGENDEXT)(getProcAddr(\"glMultiTexGendEXT\"))\n\tgpMultiTexGendvEXT = (C.GPMULTITEXGENDVEXT)(getProcAddr(\"glMultiTexGendvEXT\"))\n\tgpMultiTexGenfEXT = (C.GPMULTITEXGENFEXT)(getProcAddr(\"glMultiTexGenfEXT\"))\n\tgpMultiTexGenfvEXT = (C.GPMULTITEXGENFVEXT)(getProcAddr(\"glMultiTexGenfvEXT\"))\n\tgpMultiTexGeniEXT = (C.GPMULTITEXGENIEXT)(getProcAddr(\"glMultiTexGeniEXT\"))\n\tgpMultiTexGenivEXT = (C.GPMULTITEXGENIVEXT)(getProcAddr(\"glMultiTexGenivEXT\"))\n\tgpMultiTexImage1DEXT = (C.GPMULTITEXIMAGE1DEXT)(getProcAddr(\"glMultiTexImage1DEXT\"))\n\tgpMultiTexImage2DEXT = (C.GPMULTITEXIMAGE2DEXT)(getProcAddr(\"glMultiTexImage2DEXT\"))\n\tgpMultiTexImage3DEXT = (C.GPMULTITEXIMAGE3DEXT)(getProcAddr(\"glMultiTexImage3DEXT\"))\n\tgpMultiTexParameterIivEXT = (C.GPMULTITEXPARAMETERIIVEXT)(getProcAddr(\"glMultiTexParameterIivEXT\"))\n\tgpMultiTexParameterIuivEXT = (C.GPMULTITEXPARAMETERIUIVEXT)(getProcAddr(\"glMultiTexParameterIuivEXT\"))\n\tgpMultiTexParameterfEXT = (C.GPMULTITEXPARAMETERFEXT)(getProcAddr(\"glMultiTexParameterfEXT\"))\n\tgpMultiTexParameterfvEXT = (C.GPMULTITEXPARAMETERFVEXT)(getProcAddr(\"glMultiTexParameterfvEXT\"))\n\tgpMultiTexParameteriEXT = (C.GPMULTITEXPARAMETERIEXT)(getProcAddr(\"glMultiTexParameteriEXT\"))\n\tgpMultiTexParameterivEXT = (C.GPMULTITEXPARAMETERIVEXT)(getProcAddr(\"glMultiTexParameterivEXT\"))\n\tgpMultiTexRenderbufferEXT = (C.GPMULTITEXRENDERBUFFEREXT)(getProcAddr(\"glMultiTexRenderbufferEXT\"))\n\tgpMultiTexSubImage1DEXT = (C.GPMULTITEXSUBIMAGE1DEXT)(getProcAddr(\"glMultiTexSubImage1DEXT\"))\n\tgpMultiTexSubImage2DEXT = (C.GPMULTITEXSUBIMAGE2DEXT)(getProcAddr(\"glMultiTexSubImage2DEXT\"))\n\tgpMultiTexSubImage3DEXT = (C.GPMULTITEXSUBIMAGE3DEXT)(getProcAddr(\"glMultiTexSubImage3DEXT\"))\n\tgpMulticastBarrierNV = (C.GPMULTICASTBARRIERNV)(getProcAddr(\"glMulticastBarrierNV\"))\n\tgpMulticastBlitFramebufferNV = (C.GPMULTICASTBLITFRAMEBUFFERNV)(getProcAddr(\"glMulticastBlitFramebufferNV\"))\n\tgpMulticastBufferSubDataNV = (C.GPMULTICASTBUFFERSUBDATANV)(getProcAddr(\"glMulticastBufferSubDataNV\"))\n\tgpMulticastCopyBufferSubDataNV = (C.GPMULTICASTCOPYBUFFERSUBDATANV)(getProcAddr(\"glMulticastCopyBufferSubDataNV\"))\n\tgpMulticastCopyImageSubDataNV = (C.GPMULTICASTCOPYIMAGESUBDATANV)(getProcAddr(\"glMulticastCopyImageSubDataNV\"))\n\tgpMulticastFramebufferSampleLocationsfvNV = (C.GPMULTICASTFRAMEBUFFERSAMPLELOCATIONSFVNV)(getProcAddr(\"glMulticastFramebufferSampleLocationsfvNV\"))\n\tgpMulticastGetQueryObjecti64vNV = (C.GPMULTICASTGETQUERYOBJECTI64VNV)(getProcAddr(\"glMulticastGetQueryObjecti64vNV\"))\n\tgpMulticastGetQueryObjectivNV = (C.GPMULTICASTGETQUERYOBJECTIVNV)(getProcAddr(\"glMulticastGetQueryObjectivNV\"))\n\tgpMulticastGetQueryObjectui64vNV = (C.GPMULTICASTGETQUERYOBJECTUI64VNV)(getProcAddr(\"glMulticastGetQueryObjectui64vNV\"))\n\tgpMulticastGetQueryObjectuivNV = (C.GPMULTICASTGETQUERYOBJECTUIVNV)(getProcAddr(\"glMulticastGetQueryObjectuivNV\"))\n\tgpMulticastScissorArrayvNVX = (C.GPMULTICASTSCISSORARRAYVNVX)(getProcAddr(\"glMulticastScissorArrayvNVX\"))\n\tgpMulticastViewportArrayvNVX = (C.GPMULTICASTVIEWPORTARRAYVNVX)(getProcAddr(\"glMulticastViewportArrayvNVX\"))\n\tgpMulticastViewportPositionWScaleNVX = (C.GPMULTICASTVIEWPORTPOSITIONWSCALENVX)(getProcAddr(\"glMulticastViewportPositionWScaleNVX\"))\n\tgpMulticastWaitSyncNV = (C.GPMULTICASTWAITSYNCNV)(getProcAddr(\"glMulticastWaitSyncNV\"))\n\tgpNamedBufferAttachMemoryNV = (C.GPNAMEDBUFFERATTACHMEMORYNV)(getProcAddr(\"glNamedBufferAttachMemoryNV\"))\n\tgpNamedBufferData = (C.GPNAMEDBUFFERDATA)(getProcAddr(\"glNamedBufferData\"))\n\tgpNamedBufferDataEXT = (C.GPNAMEDBUFFERDATAEXT)(getProcAddr(\"glNamedBufferDataEXT\"))\n\tgpNamedBufferPageCommitmentARB = (C.GPNAMEDBUFFERPAGECOMMITMENTARB)(getProcAddr(\"glNamedBufferPageCommitmentARB\"))\n\tgpNamedBufferPageCommitmentEXT = (C.GPNAMEDBUFFERPAGECOMMITMENTEXT)(getProcAddr(\"glNamedBufferPageCommitmentEXT\"))\n\tgpNamedBufferPageCommitmentMemNV = (C.GPNAMEDBUFFERPAGECOMMITMENTMEMNV)(getProcAddr(\"glNamedBufferPageCommitmentMemNV\"))\n\tgpNamedBufferStorage = (C.GPNAMEDBUFFERSTORAGE)(getProcAddr(\"glNamedBufferStorage\"))\n\tgpNamedBufferStorageEXT = (C.GPNAMEDBUFFERSTORAGEEXT)(getProcAddr(\"glNamedBufferStorageEXT\"))\n\tgpNamedBufferStorageExternalEXT = (C.GPNAMEDBUFFERSTORAGEEXTERNALEXT)(getProcAddr(\"glNamedBufferStorageExternalEXT\"))\n\tgpNamedBufferStorageMemEXT = (C.GPNAMEDBUFFERSTORAGEMEMEXT)(getProcAddr(\"glNamedBufferStorageMemEXT\"))\n\tgpNamedBufferSubData = (C.GPNAMEDBUFFERSUBDATA)(getProcAddr(\"glNamedBufferSubData\"))\n\tgpNamedBufferSubDataEXT = (C.GPNAMEDBUFFERSUBDATAEXT)(getProcAddr(\"glNamedBufferSubDataEXT\"))\n\tgpNamedCopyBufferSubDataEXT = (C.GPNAMEDCOPYBUFFERSUBDATAEXT)(getProcAddr(\"glNamedCopyBufferSubDataEXT\"))\n\tgpNamedFramebufferDrawBuffer = (C.GPNAMEDFRAMEBUFFERDRAWBUFFER)(getProcAddr(\"glNamedFramebufferDrawBuffer\"))\n\tgpNamedFramebufferDrawBuffers = (C.GPNAMEDFRAMEBUFFERDRAWBUFFERS)(getProcAddr(\"glNamedFramebufferDrawBuffers\"))\n\tgpNamedFramebufferParameteri = (C.GPNAMEDFRAMEBUFFERPARAMETERI)(getProcAddr(\"glNamedFramebufferParameteri\"))\n\tgpNamedFramebufferParameteriEXT = (C.GPNAMEDFRAMEBUFFERPARAMETERIEXT)(getProcAddr(\"glNamedFramebufferParameteriEXT\"))\n\tgpNamedFramebufferReadBuffer = (C.GPNAMEDFRAMEBUFFERREADBUFFER)(getProcAddr(\"glNamedFramebufferReadBuffer\"))\n\tgpNamedFramebufferRenderbuffer = (C.GPNAMEDFRAMEBUFFERRENDERBUFFER)(getProcAddr(\"glNamedFramebufferRenderbuffer\"))\n\tgpNamedFramebufferRenderbufferEXT = (C.GPNAMEDFRAMEBUFFERRENDERBUFFEREXT)(getProcAddr(\"glNamedFramebufferRenderbufferEXT\"))\n\tgpNamedFramebufferSampleLocationsfvARB = (C.GPNAMEDFRAMEBUFFERSAMPLELOCATIONSFVARB)(getProcAddr(\"glNamedFramebufferSampleLocationsfvARB\"))\n\tgpNamedFramebufferSampleLocationsfvNV = (C.GPNAMEDFRAMEBUFFERSAMPLELOCATIONSFVNV)(getProcAddr(\"glNamedFramebufferSampleLocationsfvNV\"))\n\tgpNamedFramebufferSamplePositionsfvAMD = (C.GPNAMEDFRAMEBUFFERSAMPLEPOSITIONSFVAMD)(getProcAddr(\"glNamedFramebufferSamplePositionsfvAMD\"))\n\tgpNamedFramebufferTexture = (C.GPNAMEDFRAMEBUFFERTEXTURE)(getProcAddr(\"glNamedFramebufferTexture\"))\n\tgpNamedFramebufferTexture1DEXT = (C.GPNAMEDFRAMEBUFFERTEXTURE1DEXT)(getProcAddr(\"glNamedFramebufferTexture1DEXT\"))\n\tgpNamedFramebufferTexture2DEXT = (C.GPNAMEDFRAMEBUFFERTEXTURE2DEXT)(getProcAddr(\"glNamedFramebufferTexture2DEXT\"))\n\tgpNamedFramebufferTexture3DEXT = (C.GPNAMEDFRAMEBUFFERTEXTURE3DEXT)(getProcAddr(\"glNamedFramebufferTexture3DEXT\"))\n\tgpNamedFramebufferTextureEXT = (C.GPNAMEDFRAMEBUFFERTEXTUREEXT)(getProcAddr(\"glNamedFramebufferTextureEXT\"))\n\tgpNamedFramebufferTextureFaceEXT = (C.GPNAMEDFRAMEBUFFERTEXTUREFACEEXT)(getProcAddr(\"glNamedFramebufferTextureFaceEXT\"))\n\tgpNamedFramebufferTextureLayer = (C.GPNAMEDFRAMEBUFFERTEXTURELAYER)(getProcAddr(\"glNamedFramebufferTextureLayer\"))\n\tgpNamedFramebufferTextureLayerEXT = (C.GPNAMEDFRAMEBUFFERTEXTURELAYEREXT)(getProcAddr(\"glNamedFramebufferTextureLayerEXT\"))\n\tgpNamedProgramLocalParameter4dEXT = (C.GPNAMEDPROGRAMLOCALPARAMETER4DEXT)(getProcAddr(\"glNamedProgramLocalParameter4dEXT\"))\n\tgpNamedProgramLocalParameter4dvEXT = (C.GPNAMEDPROGRAMLOCALPARAMETER4DVEXT)(getProcAddr(\"glNamedProgramLocalParameter4dvEXT\"))\n\tgpNamedProgramLocalParameter4fEXT = (C.GPNAMEDPROGRAMLOCALPARAMETER4FEXT)(getProcAddr(\"glNamedProgramLocalParameter4fEXT\"))\n\tgpNamedProgramLocalParameter4fvEXT = (C.GPNAMEDPROGRAMLOCALPARAMETER4FVEXT)(getProcAddr(\"glNamedProgramLocalParameter4fvEXT\"))\n\tgpNamedProgramLocalParameterI4iEXT = (C.GPNAMEDPROGRAMLOCALPARAMETERI4IEXT)(getProcAddr(\"glNamedProgramLocalParameterI4iEXT\"))\n\tgpNamedProgramLocalParameterI4ivEXT = (C.GPNAMEDPROGRAMLOCALPARAMETERI4IVEXT)(getProcAddr(\"glNamedProgramLocalParameterI4ivEXT\"))\n\tgpNamedProgramLocalParameterI4uiEXT = (C.GPNAMEDPROGRAMLOCALPARAMETERI4UIEXT)(getProcAddr(\"glNamedProgramLocalParameterI4uiEXT\"))\n\tgpNamedProgramLocalParameterI4uivEXT = (C.GPNAMEDPROGRAMLOCALPARAMETERI4UIVEXT)(getProcAddr(\"glNamedProgramLocalParameterI4uivEXT\"))\n\tgpNamedProgramLocalParameters4fvEXT = (C.GPNAMEDPROGRAMLOCALPARAMETERS4FVEXT)(getProcAddr(\"glNamedProgramLocalParameters4fvEXT\"))\n\tgpNamedProgramLocalParametersI4ivEXT = (C.GPNAMEDPROGRAMLOCALPARAMETERSI4IVEXT)(getProcAddr(\"glNamedProgramLocalParametersI4ivEXT\"))\n\tgpNamedProgramLocalParametersI4uivEXT = (C.GPNAMEDPROGRAMLOCALPARAMETERSI4UIVEXT)(getProcAddr(\"glNamedProgramLocalParametersI4uivEXT\"))\n\tgpNamedProgramStringEXT = (C.GPNAMEDPROGRAMSTRINGEXT)(getProcAddr(\"glNamedProgramStringEXT\"))\n\tgpNamedRenderbufferStorage = (C.GPNAMEDRENDERBUFFERSTORAGE)(getProcAddr(\"glNamedRenderbufferStorage\"))\n\tgpNamedRenderbufferStorageEXT = (C.GPNAMEDRENDERBUFFERSTORAGEEXT)(getProcAddr(\"glNamedRenderbufferStorageEXT\"))\n\tgpNamedRenderbufferStorageMultisample = (C.GPNAMEDRENDERBUFFERSTORAGEMULTISAMPLE)(getProcAddr(\"glNamedRenderbufferStorageMultisample\"))\n\tgpNamedRenderbufferStorageMultisampleAdvancedAMD = (C.GPNAMEDRENDERBUFFERSTORAGEMULTISAMPLEADVANCEDAMD)(getProcAddr(\"glNamedRenderbufferStorageMultisampleAdvancedAMD\"))\n\tgpNamedRenderbufferStorageMultisampleCoverageEXT = (C.GPNAMEDRENDERBUFFERSTORAGEMULTISAMPLECOVERAGEEXT)(getProcAddr(\"glNamedRenderbufferStorageMultisampleCoverageEXT\"))\n\tgpNamedRenderbufferStorageMultisampleEXT = (C.GPNAMEDRENDERBUFFERSTORAGEMULTISAMPLEEXT)(getProcAddr(\"glNamedRenderbufferStorageMultisampleEXT\"))\n\tgpNamedStringARB = (C.GPNAMEDSTRINGARB)(getProcAddr(\"glNamedStringARB\"))\n\tgpNewList = (C.GPNEWLIST)(getProcAddr(\"glNewList\"))\n\tif gpNewList == nil {\n\t\treturn errors.New(\"glNewList\")\n\t}\n\tgpNewObjectBufferATI = (C.GPNEWOBJECTBUFFERATI)(getProcAddr(\"glNewObjectBufferATI\"))\n\tgpNormal3b = (C.GPNORMAL3B)(getProcAddr(\"glNormal3b\"))\n\tif gpNormal3b == nil {\n\t\treturn errors.New(\"glNormal3b\")\n\t}\n\tgpNormal3bv = (C.GPNORMAL3BV)(getProcAddr(\"glNormal3bv\"))\n\tif gpNormal3bv == nil {\n\t\treturn errors.New(\"glNormal3bv\")\n\t}\n\tgpNormal3d = (C.GPNORMAL3D)(getProcAddr(\"glNormal3d\"))\n\tif gpNormal3d == nil {\n\t\treturn errors.New(\"glNormal3d\")\n\t}\n\tgpNormal3dv = (C.GPNORMAL3DV)(getProcAddr(\"glNormal3dv\"))\n\tif gpNormal3dv == nil {\n\t\treturn errors.New(\"glNormal3dv\")\n\t}\n\tgpNormal3f = (C.GPNORMAL3F)(getProcAddr(\"glNormal3f\"))\n\tif gpNormal3f == nil {\n\t\treturn errors.New(\"glNormal3f\")\n\t}\n\tgpNormal3fVertex3fSUN = (C.GPNORMAL3FVERTEX3FSUN)(getProcAddr(\"glNormal3fVertex3fSUN\"))\n\tgpNormal3fVertex3fvSUN = (C.GPNORMAL3FVERTEX3FVSUN)(getProcAddr(\"glNormal3fVertex3fvSUN\"))\n\tgpNormal3fv = (C.GPNORMAL3FV)(getProcAddr(\"glNormal3fv\"))\n\tif gpNormal3fv == nil {\n\t\treturn errors.New(\"glNormal3fv\")\n\t}\n\tgpNormal3hNV = (C.GPNORMAL3HNV)(getProcAddr(\"glNormal3hNV\"))\n\tgpNormal3hvNV = (C.GPNORMAL3HVNV)(getProcAddr(\"glNormal3hvNV\"))\n\tgpNormal3i = (C.GPNORMAL3I)(getProcAddr(\"glNormal3i\"))\n\tif gpNormal3i == nil {\n\t\treturn errors.New(\"glNormal3i\")\n\t}\n\tgpNormal3iv = (C.GPNORMAL3IV)(getProcAddr(\"glNormal3iv\"))\n\tif gpNormal3iv == nil {\n\t\treturn errors.New(\"glNormal3iv\")\n\t}\n\tgpNormal3s = (C.GPNORMAL3S)(getProcAddr(\"glNormal3s\"))\n\tif gpNormal3s == nil {\n\t\treturn errors.New(\"glNormal3s\")\n\t}\n\tgpNormal3sv = (C.GPNORMAL3SV)(getProcAddr(\"glNormal3sv\"))\n\tif gpNormal3sv == nil {\n\t\treturn errors.New(\"glNormal3sv\")\n\t}\n\tgpNormal3xOES = (C.GPNORMAL3XOES)(getProcAddr(\"glNormal3xOES\"))\n\tgpNormal3xvOES = (C.GPNORMAL3XVOES)(getProcAddr(\"glNormal3xvOES\"))\n\tgpNormalFormatNV = (C.GPNORMALFORMATNV)(getProcAddr(\"glNormalFormatNV\"))\n\tgpNormalP3ui = (C.GPNORMALP3UI)(getProcAddr(\"glNormalP3ui\"))\n\tif gpNormalP3ui == nil {\n\t\treturn errors.New(\"glNormalP3ui\")\n\t}\n\tgpNormalP3uiv = (C.GPNORMALP3UIV)(getProcAddr(\"glNormalP3uiv\"))\n\tif gpNormalP3uiv == nil {\n\t\treturn errors.New(\"glNormalP3uiv\")\n\t}\n\tgpNormalPointer = (C.GPNORMALPOINTER)(getProcAddr(\"glNormalPointer\"))\n\tif gpNormalPointer == nil {\n\t\treturn errors.New(\"glNormalPointer\")\n\t}\n\tgpNormalPointerEXT = (C.GPNORMALPOINTEREXT)(getProcAddr(\"glNormalPointerEXT\"))\n\tgpNormalPointerListIBM = (C.GPNORMALPOINTERLISTIBM)(getProcAddr(\"glNormalPointerListIBM\"))\n\tgpNormalPointervINTEL = (C.GPNORMALPOINTERVINTEL)(getProcAddr(\"glNormalPointervINTEL\"))\n\tgpNormalStream3bATI = (C.GPNORMALSTREAM3BATI)(getProcAddr(\"glNormalStream3bATI\"))\n\tgpNormalStream3bvATI = (C.GPNORMALSTREAM3BVATI)(getProcAddr(\"glNormalStream3bvATI\"))\n\tgpNormalStream3dATI = (C.GPNORMALSTREAM3DATI)(getProcAddr(\"glNormalStream3dATI\"))\n\tgpNormalStream3dvATI = (C.GPNORMALSTREAM3DVATI)(getProcAddr(\"glNormalStream3dvATI\"))\n\tgpNormalStream3fATI = (C.GPNORMALSTREAM3FATI)(getProcAddr(\"glNormalStream3fATI\"))\n\tgpNormalStream3fvATI = (C.GPNORMALSTREAM3FVATI)(getProcAddr(\"glNormalStream3fvATI\"))\n\tgpNormalStream3iATI = (C.GPNORMALSTREAM3IATI)(getProcAddr(\"glNormalStream3iATI\"))\n\tgpNormalStream3ivATI = (C.GPNORMALSTREAM3IVATI)(getProcAddr(\"glNormalStream3ivATI\"))\n\tgpNormalStream3sATI = (C.GPNORMALSTREAM3SATI)(getProcAddr(\"glNormalStream3sATI\"))\n\tgpNormalStream3svATI = (C.GPNORMALSTREAM3SVATI)(getProcAddr(\"glNormalStream3svATI\"))\n\tgpObjectLabel = (C.GPOBJECTLABEL)(getProcAddr(\"glObjectLabel\"))\n\tif gpObjectLabel == nil {\n\t\treturn errors.New(\"glObjectLabel\")\n\t}\n\tgpObjectLabelKHR = (C.GPOBJECTLABELKHR)(getProcAddr(\"glObjectLabelKHR\"))\n\tgpObjectPtrLabel = (C.GPOBJECTPTRLABEL)(getProcAddr(\"glObjectPtrLabel\"))\n\tif gpObjectPtrLabel == nil {\n\t\treturn errors.New(\"glObjectPtrLabel\")\n\t}\n\tgpObjectPtrLabelKHR = (C.GPOBJECTPTRLABELKHR)(getProcAddr(\"glObjectPtrLabelKHR\"))\n\tgpObjectPurgeableAPPLE = (C.GPOBJECTPURGEABLEAPPLE)(getProcAddr(\"glObjectPurgeableAPPLE\"))\n\tgpObjectUnpurgeableAPPLE = (C.GPOBJECTUNPURGEABLEAPPLE)(getProcAddr(\"glObjectUnpurgeableAPPLE\"))\n\tgpOrtho = (C.GPORTHO)(getProcAddr(\"glOrtho\"))\n\tif gpOrtho == nil {\n\t\treturn errors.New(\"glOrtho\")\n\t}\n\tgpOrthofOES = (C.GPORTHOFOES)(getProcAddr(\"glOrthofOES\"))\n\tgpOrthoxOES = (C.GPORTHOXOES)(getProcAddr(\"glOrthoxOES\"))\n\tgpPNTrianglesfATI = (C.GPPNTRIANGLESFATI)(getProcAddr(\"glPNTrianglesfATI\"))\n\tgpPNTrianglesiATI = (C.GPPNTRIANGLESIATI)(getProcAddr(\"glPNTrianglesiATI\"))\n\tgpPassTexCoordATI = (C.GPPASSTEXCOORDATI)(getProcAddr(\"glPassTexCoordATI\"))\n\tgpPassThrough = (C.GPPASSTHROUGH)(getProcAddr(\"glPassThrough\"))\n\tif gpPassThrough == nil {\n\t\treturn errors.New(\"glPassThrough\")\n\t}\n\tgpPassThroughxOES = (C.GPPASSTHROUGHXOES)(getProcAddr(\"glPassThroughxOES\"))\n\tgpPatchParameterfv = (C.GPPATCHPARAMETERFV)(getProcAddr(\"glPatchParameterfv\"))\n\tif gpPatchParameterfv == nil {\n\t\treturn errors.New(\"glPatchParameterfv\")\n\t}\n\tgpPatchParameteri = (C.GPPATCHPARAMETERI)(getProcAddr(\"glPatchParameteri\"))\n\tif gpPatchParameteri == nil {\n\t\treturn errors.New(\"glPatchParameteri\")\n\t}\n\tgpPathColorGenNV = (C.GPPATHCOLORGENNV)(getProcAddr(\"glPathColorGenNV\"))\n\tgpPathCommandsNV = (C.GPPATHCOMMANDSNV)(getProcAddr(\"glPathCommandsNV\"))\n\tgpPathCoordsNV = (C.GPPATHCOORDSNV)(getProcAddr(\"glPathCoordsNV\"))\n\tgpPathCoverDepthFuncNV = (C.GPPATHCOVERDEPTHFUNCNV)(getProcAddr(\"glPathCoverDepthFuncNV\"))\n\tgpPathDashArrayNV = (C.GPPATHDASHARRAYNV)(getProcAddr(\"glPathDashArrayNV\"))\n\tgpPathFogGenNV = (C.GPPATHFOGGENNV)(getProcAddr(\"glPathFogGenNV\"))\n\tgpPathGlyphIndexArrayNV = (C.GPPATHGLYPHINDEXARRAYNV)(getProcAddr(\"glPathGlyphIndexArrayNV\"))\n\tgpPathGlyphIndexRangeNV = (C.GPPATHGLYPHINDEXRANGENV)(getProcAddr(\"glPathGlyphIndexRangeNV\"))\n\tgpPathGlyphRangeNV = (C.GPPATHGLYPHRANGENV)(getProcAddr(\"glPathGlyphRangeNV\"))\n\tgpPathGlyphsNV = (C.GPPATHGLYPHSNV)(getProcAddr(\"glPathGlyphsNV\"))\n\tgpPathMemoryGlyphIndexArrayNV = (C.GPPATHMEMORYGLYPHINDEXARRAYNV)(getProcAddr(\"glPathMemoryGlyphIndexArrayNV\"))\n\tgpPathParameterfNV = (C.GPPATHPARAMETERFNV)(getProcAddr(\"glPathParameterfNV\"))\n\tgpPathParameterfvNV = (C.GPPATHPARAMETERFVNV)(getProcAddr(\"glPathParameterfvNV\"))\n\tgpPathParameteriNV = (C.GPPATHPARAMETERINV)(getProcAddr(\"glPathParameteriNV\"))\n\tgpPathParameterivNV = (C.GPPATHPARAMETERIVNV)(getProcAddr(\"glPathParameterivNV\"))\n\tgpPathStencilDepthOffsetNV = (C.GPPATHSTENCILDEPTHOFFSETNV)(getProcAddr(\"glPathStencilDepthOffsetNV\"))\n\tgpPathStencilFuncNV = (C.GPPATHSTENCILFUNCNV)(getProcAddr(\"glPathStencilFuncNV\"))\n\tgpPathStringNV = (C.GPPATHSTRINGNV)(getProcAddr(\"glPathStringNV\"))\n\tgpPathSubCommandsNV = (C.GPPATHSUBCOMMANDSNV)(getProcAddr(\"glPathSubCommandsNV\"))\n\tgpPathSubCoordsNV = (C.GPPATHSUBCOORDSNV)(getProcAddr(\"glPathSubCoordsNV\"))\n\tgpPathTexGenNV = (C.GPPATHTEXGENNV)(getProcAddr(\"glPathTexGenNV\"))\n\tgpPauseTransformFeedback = (C.GPPAUSETRANSFORMFEEDBACK)(getProcAddr(\"glPauseTransformFeedback\"))\n\tif gpPauseTransformFeedback == nil {\n\t\treturn errors.New(\"glPauseTransformFeedback\")\n\t}\n\tgpPauseTransformFeedbackNV = (C.GPPAUSETRANSFORMFEEDBACKNV)(getProcAddr(\"glPauseTransformFeedbackNV\"))\n\tgpPixelDataRangeNV = (C.GPPIXELDATARANGENV)(getProcAddr(\"glPixelDataRangeNV\"))\n\tgpPixelMapfv = (C.GPPIXELMAPFV)(getProcAddr(\"glPixelMapfv\"))\n\tif gpPixelMapfv == nil {\n\t\treturn errors.New(\"glPixelMapfv\")\n\t}\n\tgpPixelMapuiv = (C.GPPIXELMAPUIV)(getProcAddr(\"glPixelMapuiv\"))\n\tif gpPixelMapuiv == nil {\n\t\treturn errors.New(\"glPixelMapuiv\")\n\t}\n\tgpPixelMapusv = (C.GPPIXELMAPUSV)(getProcAddr(\"glPixelMapusv\"))\n\tif gpPixelMapusv == nil {\n\t\treturn errors.New(\"glPixelMapusv\")\n\t}\n\tgpPixelMapx = (C.GPPIXELMAPX)(getProcAddr(\"glPixelMapx\"))\n\tgpPixelStoref = (C.GPPIXELSTOREF)(getProcAddr(\"glPixelStoref\"))\n\tif gpPixelStoref == nil {\n\t\treturn errors.New(\"glPixelStoref\")\n\t}\n\tgpPixelStorei = (C.GPPIXELSTOREI)(getProcAddr(\"glPixelStorei\"))\n\tif gpPixelStorei == nil {\n\t\treturn errors.New(\"glPixelStorei\")\n\t}\n\tgpPixelStorex = (C.GPPIXELSTOREX)(getProcAddr(\"glPixelStorex\"))\n\tgpPixelTexGenParameterfSGIS = (C.GPPIXELTEXGENPARAMETERFSGIS)(getProcAddr(\"glPixelTexGenParameterfSGIS\"))\n\tgpPixelTexGenParameterfvSGIS = (C.GPPIXELTEXGENPARAMETERFVSGIS)(getProcAddr(\"glPixelTexGenParameterfvSGIS\"))\n\tgpPixelTexGenParameteriSGIS = (C.GPPIXELTEXGENPARAMETERISGIS)(getProcAddr(\"glPixelTexGenParameteriSGIS\"))\n\tgpPixelTexGenParameterivSGIS = (C.GPPIXELTEXGENPARAMETERIVSGIS)(getProcAddr(\"glPixelTexGenParameterivSGIS\"))\n\tgpPixelTexGenSGIX = (C.GPPIXELTEXGENSGIX)(getProcAddr(\"glPixelTexGenSGIX\"))\n\tgpPixelTransferf = (C.GPPIXELTRANSFERF)(getProcAddr(\"glPixelTransferf\"))\n\tif gpPixelTransferf == nil {\n\t\treturn errors.New(\"glPixelTransferf\")\n\t}\n\tgpPixelTransferi = (C.GPPIXELTRANSFERI)(getProcAddr(\"glPixelTransferi\"))\n\tif gpPixelTransferi == nil {\n\t\treturn errors.New(\"glPixelTransferi\")\n\t}\n\tgpPixelTransferxOES = (C.GPPIXELTRANSFERXOES)(getProcAddr(\"glPixelTransferxOES\"))\n\tgpPixelTransformParameterfEXT = (C.GPPIXELTRANSFORMPARAMETERFEXT)(getProcAddr(\"glPixelTransformParameterfEXT\"))\n\tgpPixelTransformParameterfvEXT = (C.GPPIXELTRANSFORMPARAMETERFVEXT)(getProcAddr(\"glPixelTransformParameterfvEXT\"))\n\tgpPixelTransformParameteriEXT = (C.GPPIXELTRANSFORMPARAMETERIEXT)(getProcAddr(\"glPixelTransformParameteriEXT\"))\n\tgpPixelTransformParameterivEXT = (C.GPPIXELTRANSFORMPARAMETERIVEXT)(getProcAddr(\"glPixelTransformParameterivEXT\"))\n\tgpPixelZoom = (C.GPPIXELZOOM)(getProcAddr(\"glPixelZoom\"))\n\tif gpPixelZoom == nil {\n\t\treturn errors.New(\"glPixelZoom\")\n\t}\n\tgpPixelZoomxOES = (C.GPPIXELZOOMXOES)(getProcAddr(\"glPixelZoomxOES\"))\n\tgpPointAlongPathNV = (C.GPPOINTALONGPATHNV)(getProcAddr(\"glPointAlongPathNV\"))\n\tgpPointParameterf = (C.GPPOINTPARAMETERF)(getProcAddr(\"glPointParameterf\"))\n\tif gpPointParameterf == nil {\n\t\treturn errors.New(\"glPointParameterf\")\n\t}\n\tgpPointParameterfARB = (C.GPPOINTPARAMETERFARB)(getProcAddr(\"glPointParameterfARB\"))\n\tgpPointParameterfEXT = (C.GPPOINTPARAMETERFEXT)(getProcAddr(\"glPointParameterfEXT\"))\n\tgpPointParameterfSGIS = (C.GPPOINTPARAMETERFSGIS)(getProcAddr(\"glPointParameterfSGIS\"))\n\tgpPointParameterfv = (C.GPPOINTPARAMETERFV)(getProcAddr(\"glPointParameterfv\"))\n\tif gpPointParameterfv == nil {\n\t\treturn errors.New(\"glPointParameterfv\")\n\t}\n\tgpPointParameterfvARB = (C.GPPOINTPARAMETERFVARB)(getProcAddr(\"glPointParameterfvARB\"))\n\tgpPointParameterfvEXT = (C.GPPOINTPARAMETERFVEXT)(getProcAddr(\"glPointParameterfvEXT\"))\n\tgpPointParameterfvSGIS = (C.GPPOINTPARAMETERFVSGIS)(getProcAddr(\"glPointParameterfvSGIS\"))\n\tgpPointParameteri = (C.GPPOINTPARAMETERI)(getProcAddr(\"glPointParameteri\"))\n\tif gpPointParameteri == nil {\n\t\treturn errors.New(\"glPointParameteri\")\n\t}\n\tgpPointParameteriNV = (C.GPPOINTPARAMETERINV)(getProcAddr(\"glPointParameteriNV\"))\n\tgpPointParameteriv = (C.GPPOINTPARAMETERIV)(getProcAddr(\"glPointParameteriv\"))\n\tif gpPointParameteriv == nil {\n\t\treturn errors.New(\"glPointParameteriv\")\n\t}\n\tgpPointParameterivNV = (C.GPPOINTPARAMETERIVNV)(getProcAddr(\"glPointParameterivNV\"))\n\tgpPointParameterxOES = (C.GPPOINTPARAMETERXOES)(getProcAddr(\"glPointParameterxOES\"))\n\tgpPointParameterxvOES = (C.GPPOINTPARAMETERXVOES)(getProcAddr(\"glPointParameterxvOES\"))\n\tgpPointSize = (C.GPPOINTSIZE)(getProcAddr(\"glPointSize\"))\n\tif gpPointSize == nil {\n\t\treturn errors.New(\"glPointSize\")\n\t}\n\tgpPointSizexOES = (C.GPPOINTSIZEXOES)(getProcAddr(\"glPointSizexOES\"))\n\tgpPollAsyncSGIX = (C.GPPOLLASYNCSGIX)(getProcAddr(\"glPollAsyncSGIX\"))\n\tgpPollInstrumentsSGIX = (C.GPPOLLINSTRUMENTSSGIX)(getProcAddr(\"glPollInstrumentsSGIX\"))\n\tgpPolygonMode = (C.GPPOLYGONMODE)(getProcAddr(\"glPolygonMode\"))\n\tif gpPolygonMode == nil {\n\t\treturn errors.New(\"glPolygonMode\")\n\t}\n\tgpPolygonOffset = (C.GPPOLYGONOFFSET)(getProcAddr(\"glPolygonOffset\"))\n\tif gpPolygonOffset == nil {\n\t\treturn errors.New(\"glPolygonOffset\")\n\t}\n\tgpPolygonOffsetClamp = (C.GPPOLYGONOFFSETCLAMP)(getProcAddr(\"glPolygonOffsetClamp\"))\n\tgpPolygonOffsetClampEXT = (C.GPPOLYGONOFFSETCLAMPEXT)(getProcAddr(\"glPolygonOffsetClampEXT\"))\n\tgpPolygonOffsetEXT = (C.GPPOLYGONOFFSETEXT)(getProcAddr(\"glPolygonOffsetEXT\"))\n\tgpPolygonOffsetxOES = (C.GPPOLYGONOFFSETXOES)(getProcAddr(\"glPolygonOffsetxOES\"))\n\tgpPolygonStipple = (C.GPPOLYGONSTIPPLE)(getProcAddr(\"glPolygonStipple\"))\n\tif gpPolygonStipple == nil {\n\t\treturn errors.New(\"glPolygonStipple\")\n\t}\n\tgpPopAttrib = (C.GPPOPATTRIB)(getProcAddr(\"glPopAttrib\"))\n\tif gpPopAttrib == nil {\n\t\treturn errors.New(\"glPopAttrib\")\n\t}\n\tgpPopClientAttrib = (C.GPPOPCLIENTATTRIB)(getProcAddr(\"glPopClientAttrib\"))\n\tif gpPopClientAttrib == nil {\n\t\treturn errors.New(\"glPopClientAttrib\")\n\t}\n\tgpPopDebugGroup = (C.GPPOPDEBUGGROUP)(getProcAddr(\"glPopDebugGroup\"))\n\tif gpPopDebugGroup == nil {\n\t\treturn errors.New(\"glPopDebugGroup\")\n\t}\n\tgpPopDebugGroupKHR = (C.GPPOPDEBUGGROUPKHR)(getProcAddr(\"glPopDebugGroupKHR\"))\n\tgpPopGroupMarkerEXT = (C.GPPOPGROUPMARKEREXT)(getProcAddr(\"glPopGroupMarkerEXT\"))\n\tgpPopMatrix = (C.GPPOPMATRIX)(getProcAddr(\"glPopMatrix\"))\n\tif gpPopMatrix == nil {\n\t\treturn errors.New(\"glPopMatrix\")\n\t}\n\tgpPopName = (C.GPPOPNAME)(getProcAddr(\"glPopName\"))\n\tif gpPopName == nil {\n\t\treturn errors.New(\"glPopName\")\n\t}\n\tgpPresentFrameDualFillNV = (C.GPPRESENTFRAMEDUALFILLNV)(getProcAddr(\"glPresentFrameDualFillNV\"))\n\tgpPresentFrameKeyedNV = (C.GPPRESENTFRAMEKEYEDNV)(getProcAddr(\"glPresentFrameKeyedNV\"))\n\tgpPrimitiveBoundingBoxARB = (C.GPPRIMITIVEBOUNDINGBOXARB)(getProcAddr(\"glPrimitiveBoundingBoxARB\"))\n\tgpPrimitiveRestartIndex = (C.GPPRIMITIVERESTARTINDEX)(getProcAddr(\"glPrimitiveRestartIndex\"))\n\tif gpPrimitiveRestartIndex == nil {\n\t\treturn errors.New(\"glPrimitiveRestartIndex\")\n\t}\n\tgpPrimitiveRestartIndexNV = (C.GPPRIMITIVERESTARTINDEXNV)(getProcAddr(\"glPrimitiveRestartIndexNV\"))\n\tgpPrimitiveRestartNV = (C.GPPRIMITIVERESTARTNV)(getProcAddr(\"glPrimitiveRestartNV\"))\n\tgpPrioritizeTextures = (C.GPPRIORITIZETEXTURES)(getProcAddr(\"glPrioritizeTextures\"))\n\tif gpPrioritizeTextures == nil {\n\t\treturn errors.New(\"glPrioritizeTextures\")\n\t}\n\tgpPrioritizeTexturesEXT = (C.GPPRIORITIZETEXTURESEXT)(getProcAddr(\"glPrioritizeTexturesEXT\"))\n\tgpPrioritizeTexturesxOES = (C.GPPRIORITIZETEXTURESXOES)(getProcAddr(\"glPrioritizeTexturesxOES\"))\n\tgpProgramBinary = (C.GPPROGRAMBINARY)(getProcAddr(\"glProgramBinary\"))\n\tif gpProgramBinary == nil {\n\t\treturn errors.New(\"glProgramBinary\")\n\t}\n\tgpProgramBufferParametersIivNV = (C.GPPROGRAMBUFFERPARAMETERSIIVNV)(getProcAddr(\"glProgramBufferParametersIivNV\"))\n\tgpProgramBufferParametersIuivNV = (C.GPPROGRAMBUFFERPARAMETERSIUIVNV)(getProcAddr(\"glProgramBufferParametersIuivNV\"))\n\tgpProgramBufferParametersfvNV = (C.GPPROGRAMBUFFERPARAMETERSFVNV)(getProcAddr(\"glProgramBufferParametersfvNV\"))\n\tgpProgramEnvParameter4dARB = (C.GPPROGRAMENVPARAMETER4DARB)(getProcAddr(\"glProgramEnvParameter4dARB\"))\n\tgpProgramEnvParameter4dvARB = (C.GPPROGRAMENVPARAMETER4DVARB)(getProcAddr(\"glProgramEnvParameter4dvARB\"))\n\tgpProgramEnvParameter4fARB = (C.GPPROGRAMENVPARAMETER4FARB)(getProcAddr(\"glProgramEnvParameter4fARB\"))\n\tgpProgramEnvParameter4fvARB = (C.GPPROGRAMENVPARAMETER4FVARB)(getProcAddr(\"glProgramEnvParameter4fvARB\"))\n\tgpProgramEnvParameterI4iNV = (C.GPPROGRAMENVPARAMETERI4INV)(getProcAddr(\"glProgramEnvParameterI4iNV\"))\n\tgpProgramEnvParameterI4ivNV = (C.GPPROGRAMENVPARAMETERI4IVNV)(getProcAddr(\"glProgramEnvParameterI4ivNV\"))\n\tgpProgramEnvParameterI4uiNV = (C.GPPROGRAMENVPARAMETERI4UINV)(getProcAddr(\"glProgramEnvParameterI4uiNV\"))\n\tgpProgramEnvParameterI4uivNV = (C.GPPROGRAMENVPARAMETERI4UIVNV)(getProcAddr(\"glProgramEnvParameterI4uivNV\"))\n\tgpProgramEnvParameters4fvEXT = (C.GPPROGRAMENVPARAMETERS4FVEXT)(getProcAddr(\"glProgramEnvParameters4fvEXT\"))\n\tgpProgramEnvParametersI4ivNV = (C.GPPROGRAMENVPARAMETERSI4IVNV)(getProcAddr(\"glProgramEnvParametersI4ivNV\"))\n\tgpProgramEnvParametersI4uivNV = (C.GPPROGRAMENVPARAMETERSI4UIVNV)(getProcAddr(\"glProgramEnvParametersI4uivNV\"))\n\tgpProgramLocalParameter4dARB = (C.GPPROGRAMLOCALPARAMETER4DARB)(getProcAddr(\"glProgramLocalParameter4dARB\"))\n\tgpProgramLocalParameter4dvARB = (C.GPPROGRAMLOCALPARAMETER4DVARB)(getProcAddr(\"glProgramLocalParameter4dvARB\"))\n\tgpProgramLocalParameter4fARB = (C.GPPROGRAMLOCALPARAMETER4FARB)(getProcAddr(\"glProgramLocalParameter4fARB\"))\n\tgpProgramLocalParameter4fvARB = (C.GPPROGRAMLOCALPARAMETER4FVARB)(getProcAddr(\"glProgramLocalParameter4fvARB\"))\n\tgpProgramLocalParameterI4iNV = (C.GPPROGRAMLOCALPARAMETERI4INV)(getProcAddr(\"glProgramLocalParameterI4iNV\"))\n\tgpProgramLocalParameterI4ivNV = (C.GPPROGRAMLOCALPARAMETERI4IVNV)(getProcAddr(\"glProgramLocalParameterI4ivNV\"))\n\tgpProgramLocalParameterI4uiNV = (C.GPPROGRAMLOCALPARAMETERI4UINV)(getProcAddr(\"glProgramLocalParameterI4uiNV\"))\n\tgpProgramLocalParameterI4uivNV = (C.GPPROGRAMLOCALPARAMETERI4UIVNV)(getProcAddr(\"glProgramLocalParameterI4uivNV\"))\n\tgpProgramLocalParameters4fvEXT = (C.GPPROGRAMLOCALPARAMETERS4FVEXT)(getProcAddr(\"glProgramLocalParameters4fvEXT\"))\n\tgpProgramLocalParametersI4ivNV = (C.GPPROGRAMLOCALPARAMETERSI4IVNV)(getProcAddr(\"glProgramLocalParametersI4ivNV\"))\n\tgpProgramLocalParametersI4uivNV = (C.GPPROGRAMLOCALPARAMETERSI4UIVNV)(getProcAddr(\"glProgramLocalParametersI4uivNV\"))\n\tgpProgramNamedParameter4dNV = (C.GPPROGRAMNAMEDPARAMETER4DNV)(getProcAddr(\"glProgramNamedParameter4dNV\"))\n\tgpProgramNamedParameter4dvNV = (C.GPPROGRAMNAMEDPARAMETER4DVNV)(getProcAddr(\"glProgramNamedParameter4dvNV\"))\n\tgpProgramNamedParameter4fNV = (C.GPPROGRAMNAMEDPARAMETER4FNV)(getProcAddr(\"glProgramNamedParameter4fNV\"))\n\tgpProgramNamedParameter4fvNV = (C.GPPROGRAMNAMEDPARAMETER4FVNV)(getProcAddr(\"glProgramNamedParameter4fvNV\"))\n\tgpProgramParameter4dNV = (C.GPPROGRAMPARAMETER4DNV)(getProcAddr(\"glProgramParameter4dNV\"))\n\tgpProgramParameter4dvNV = (C.GPPROGRAMPARAMETER4DVNV)(getProcAddr(\"glProgramParameter4dvNV\"))\n\tgpProgramParameter4fNV = (C.GPPROGRAMPARAMETER4FNV)(getProcAddr(\"glProgramParameter4fNV\"))\n\tgpProgramParameter4fvNV = (C.GPPROGRAMPARAMETER4FVNV)(getProcAddr(\"glProgramParameter4fvNV\"))\n\tgpProgramParameteri = (C.GPPROGRAMPARAMETERI)(getProcAddr(\"glProgramParameteri\"))\n\tif gpProgramParameteri == nil {\n\t\treturn errors.New(\"glProgramParameteri\")\n\t}\n\tgpProgramParameteriARB = (C.GPPROGRAMPARAMETERIARB)(getProcAddr(\"glProgramParameteriARB\"))\n\tgpProgramParameteriEXT = (C.GPPROGRAMPARAMETERIEXT)(getProcAddr(\"glProgramParameteriEXT\"))\n\tgpProgramParameters4dvNV = (C.GPPROGRAMPARAMETERS4DVNV)(getProcAddr(\"glProgramParameters4dvNV\"))\n\tgpProgramParameters4fvNV = (C.GPPROGRAMPARAMETERS4FVNV)(getProcAddr(\"glProgramParameters4fvNV\"))\n\tgpProgramPathFragmentInputGenNV = (C.GPPROGRAMPATHFRAGMENTINPUTGENNV)(getProcAddr(\"glProgramPathFragmentInputGenNV\"))\n\tgpProgramStringARB = (C.GPPROGRAMSTRINGARB)(getProcAddr(\"glProgramStringARB\"))\n\tgpProgramSubroutineParametersuivNV = (C.GPPROGRAMSUBROUTINEPARAMETERSUIVNV)(getProcAddr(\"glProgramSubroutineParametersuivNV\"))\n\tgpProgramUniform1d = (C.GPPROGRAMUNIFORM1D)(getProcAddr(\"glProgramUniform1d\"))\n\tif gpProgramUniform1d == nil {\n\t\treturn errors.New(\"glProgramUniform1d\")\n\t}\n\tgpProgramUniform1dEXT = (C.GPPROGRAMUNIFORM1DEXT)(getProcAddr(\"glProgramUniform1dEXT\"))\n\tgpProgramUniform1dv = (C.GPPROGRAMUNIFORM1DV)(getProcAddr(\"glProgramUniform1dv\"))\n\tif gpProgramUniform1dv == nil {\n\t\treturn errors.New(\"glProgramUniform1dv\")\n\t}\n\tgpProgramUniform1dvEXT = (C.GPPROGRAMUNIFORM1DVEXT)(getProcAddr(\"glProgramUniform1dvEXT\"))\n\tgpProgramUniform1f = (C.GPPROGRAMUNIFORM1F)(getProcAddr(\"glProgramUniform1f\"))\n\tif gpProgramUniform1f == nil {\n\t\treturn errors.New(\"glProgramUniform1f\")\n\t}\n\tgpProgramUniform1fEXT = (C.GPPROGRAMUNIFORM1FEXT)(getProcAddr(\"glProgramUniform1fEXT\"))\n\tgpProgramUniform1fv = (C.GPPROGRAMUNIFORM1FV)(getProcAddr(\"glProgramUniform1fv\"))\n\tif gpProgramUniform1fv == nil {\n\t\treturn errors.New(\"glProgramUniform1fv\")\n\t}\n\tgpProgramUniform1fvEXT = (C.GPPROGRAMUNIFORM1FVEXT)(getProcAddr(\"glProgramUniform1fvEXT\"))\n\tgpProgramUniform1i = (C.GPPROGRAMUNIFORM1I)(getProcAddr(\"glProgramUniform1i\"))\n\tif gpProgramUniform1i == nil {\n\t\treturn errors.New(\"glProgramUniform1i\")\n\t}\n\tgpProgramUniform1i64ARB = (C.GPPROGRAMUNIFORM1I64ARB)(getProcAddr(\"glProgramUniform1i64ARB\"))\n\tgpProgramUniform1i64NV = (C.GPPROGRAMUNIFORM1I64NV)(getProcAddr(\"glProgramUniform1i64NV\"))\n\tgpProgramUniform1i64vARB = (C.GPPROGRAMUNIFORM1I64VARB)(getProcAddr(\"glProgramUniform1i64vARB\"))\n\tgpProgramUniform1i64vNV = (C.GPPROGRAMUNIFORM1I64VNV)(getProcAddr(\"glProgramUniform1i64vNV\"))\n\tgpProgramUniform1iEXT = (C.GPPROGRAMUNIFORM1IEXT)(getProcAddr(\"glProgramUniform1iEXT\"))\n\tgpProgramUniform1iv = (C.GPPROGRAMUNIFORM1IV)(getProcAddr(\"glProgramUniform1iv\"))\n\tif gpProgramUniform1iv == nil {\n\t\treturn errors.New(\"glProgramUniform1iv\")\n\t}\n\tgpProgramUniform1ivEXT = (C.GPPROGRAMUNIFORM1IVEXT)(getProcAddr(\"glProgramUniform1ivEXT\"))\n\tgpProgramUniform1ui = (C.GPPROGRAMUNIFORM1UI)(getProcAddr(\"glProgramUniform1ui\"))\n\tif gpProgramUniform1ui == nil {\n\t\treturn errors.New(\"glProgramUniform1ui\")\n\t}\n\tgpProgramUniform1ui64ARB = (C.GPPROGRAMUNIFORM1UI64ARB)(getProcAddr(\"glProgramUniform1ui64ARB\"))\n\tgpProgramUniform1ui64NV = (C.GPPROGRAMUNIFORM1UI64NV)(getProcAddr(\"glProgramUniform1ui64NV\"))\n\tgpProgramUniform1ui64vARB = (C.GPPROGRAMUNIFORM1UI64VARB)(getProcAddr(\"glProgramUniform1ui64vARB\"))\n\tgpProgramUniform1ui64vNV = (C.GPPROGRAMUNIFORM1UI64VNV)(getProcAddr(\"glProgramUniform1ui64vNV\"))\n\tgpProgramUniform1uiEXT = (C.GPPROGRAMUNIFORM1UIEXT)(getProcAddr(\"glProgramUniform1uiEXT\"))\n\tgpProgramUniform1uiv = (C.GPPROGRAMUNIFORM1UIV)(getProcAddr(\"glProgramUniform1uiv\"))\n\tif gpProgramUniform1uiv == nil {\n\t\treturn errors.New(\"glProgramUniform1uiv\")\n\t}\n\tgpProgramUniform1uivEXT = (C.GPPROGRAMUNIFORM1UIVEXT)(getProcAddr(\"glProgramUniform1uivEXT\"))\n\tgpProgramUniform2d = (C.GPPROGRAMUNIFORM2D)(getProcAddr(\"glProgramUniform2d\"))\n\tif gpProgramUniform2d == nil {\n\t\treturn errors.New(\"glProgramUniform2d\")\n\t}\n\tgpProgramUniform2dEXT = (C.GPPROGRAMUNIFORM2DEXT)(getProcAddr(\"glProgramUniform2dEXT\"))\n\tgpProgramUniform2dv = (C.GPPROGRAMUNIFORM2DV)(getProcAddr(\"glProgramUniform2dv\"))\n\tif gpProgramUniform2dv == nil {\n\t\treturn errors.New(\"glProgramUniform2dv\")\n\t}\n\tgpProgramUniform2dvEXT = (C.GPPROGRAMUNIFORM2DVEXT)(getProcAddr(\"glProgramUniform2dvEXT\"))\n\tgpProgramUniform2f = (C.GPPROGRAMUNIFORM2F)(getProcAddr(\"glProgramUniform2f\"))\n\tif gpProgramUniform2f == nil {\n\t\treturn errors.New(\"glProgramUniform2f\")\n\t}\n\tgpProgramUniform2fEXT = (C.GPPROGRAMUNIFORM2FEXT)(getProcAddr(\"glProgramUniform2fEXT\"))\n\tgpProgramUniform2fv = (C.GPPROGRAMUNIFORM2FV)(getProcAddr(\"glProgramUniform2fv\"))\n\tif gpProgramUniform2fv == nil {\n\t\treturn errors.New(\"glProgramUniform2fv\")\n\t}\n\tgpProgramUniform2fvEXT = (C.GPPROGRAMUNIFORM2FVEXT)(getProcAddr(\"glProgramUniform2fvEXT\"))\n\tgpProgramUniform2i = (C.GPPROGRAMUNIFORM2I)(getProcAddr(\"glProgramUniform2i\"))\n\tif gpProgramUniform2i == nil {\n\t\treturn errors.New(\"glProgramUniform2i\")\n\t}\n\tgpProgramUniform2i64ARB = (C.GPPROGRAMUNIFORM2I64ARB)(getProcAddr(\"glProgramUniform2i64ARB\"))\n\tgpProgramUniform2i64NV = (C.GPPROGRAMUNIFORM2I64NV)(getProcAddr(\"glProgramUniform2i64NV\"))\n\tgpProgramUniform2i64vARB = (C.GPPROGRAMUNIFORM2I64VARB)(getProcAddr(\"glProgramUniform2i64vARB\"))\n\tgpProgramUniform2i64vNV = (C.GPPROGRAMUNIFORM2I64VNV)(getProcAddr(\"glProgramUniform2i64vNV\"))\n\tgpProgramUniform2iEXT = (C.GPPROGRAMUNIFORM2IEXT)(getProcAddr(\"glProgramUniform2iEXT\"))\n\tgpProgramUniform2iv = (C.GPPROGRAMUNIFORM2IV)(getProcAddr(\"glProgramUniform2iv\"))\n\tif gpProgramUniform2iv == nil {\n\t\treturn errors.New(\"glProgramUniform2iv\")\n\t}\n\tgpProgramUniform2ivEXT = (C.GPPROGRAMUNIFORM2IVEXT)(getProcAddr(\"glProgramUniform2ivEXT\"))\n\tgpProgramUniform2ui = (C.GPPROGRAMUNIFORM2UI)(getProcAddr(\"glProgramUniform2ui\"))\n\tif gpProgramUniform2ui == nil {\n\t\treturn errors.New(\"glProgramUniform2ui\")\n\t}\n\tgpProgramUniform2ui64ARB = (C.GPPROGRAMUNIFORM2UI64ARB)(getProcAddr(\"glProgramUniform2ui64ARB\"))\n\tgpProgramUniform2ui64NV = (C.GPPROGRAMUNIFORM2UI64NV)(getProcAddr(\"glProgramUniform2ui64NV\"))\n\tgpProgramUniform2ui64vARB = (C.GPPROGRAMUNIFORM2UI64VARB)(getProcAddr(\"glProgramUniform2ui64vARB\"))\n\tgpProgramUniform2ui64vNV = (C.GPPROGRAMUNIFORM2UI64VNV)(getProcAddr(\"glProgramUniform2ui64vNV\"))\n\tgpProgramUniform2uiEXT = (C.GPPROGRAMUNIFORM2UIEXT)(getProcAddr(\"glProgramUniform2uiEXT\"))\n\tgpProgramUniform2uiv = (C.GPPROGRAMUNIFORM2UIV)(getProcAddr(\"glProgramUniform2uiv\"))\n\tif gpProgramUniform2uiv == nil {\n\t\treturn errors.New(\"glProgramUniform2uiv\")\n\t}\n\tgpProgramUniform2uivEXT = (C.GPPROGRAMUNIFORM2UIVEXT)(getProcAddr(\"glProgramUniform2uivEXT\"))\n\tgpProgramUniform3d = (C.GPPROGRAMUNIFORM3D)(getProcAddr(\"glProgramUniform3d\"))\n\tif gpProgramUniform3d == nil {\n\t\treturn errors.New(\"glProgramUniform3d\")\n\t}\n\tgpProgramUniform3dEXT = (C.GPPROGRAMUNIFORM3DEXT)(getProcAddr(\"glProgramUniform3dEXT\"))\n\tgpProgramUniform3dv = (C.GPPROGRAMUNIFORM3DV)(getProcAddr(\"glProgramUniform3dv\"))\n\tif gpProgramUniform3dv == nil {\n\t\treturn errors.New(\"glProgramUniform3dv\")\n\t}\n\tgpProgramUniform3dvEXT = (C.GPPROGRAMUNIFORM3DVEXT)(getProcAddr(\"glProgramUniform3dvEXT\"))\n\tgpProgramUniform3f = (C.GPPROGRAMUNIFORM3F)(getProcAddr(\"glProgramUniform3f\"))\n\tif gpProgramUniform3f == nil {\n\t\treturn errors.New(\"glProgramUniform3f\")\n\t}\n\tgpProgramUniform3fEXT = (C.GPPROGRAMUNIFORM3FEXT)(getProcAddr(\"glProgramUniform3fEXT\"))\n\tgpProgramUniform3fv = (C.GPPROGRAMUNIFORM3FV)(getProcAddr(\"glProgramUniform3fv\"))\n\tif gpProgramUniform3fv == nil {\n\t\treturn errors.New(\"glProgramUniform3fv\")\n\t}\n\tgpProgramUniform3fvEXT = (C.GPPROGRAMUNIFORM3FVEXT)(getProcAddr(\"glProgramUniform3fvEXT\"))\n\tgpProgramUniform3i = (C.GPPROGRAMUNIFORM3I)(getProcAddr(\"glProgramUniform3i\"))\n\tif gpProgramUniform3i == nil {\n\t\treturn errors.New(\"glProgramUniform3i\")\n\t}\n\tgpProgramUniform3i64ARB = (C.GPPROGRAMUNIFORM3I64ARB)(getProcAddr(\"glProgramUniform3i64ARB\"))\n\tgpProgramUniform3i64NV = (C.GPPROGRAMUNIFORM3I64NV)(getProcAddr(\"glProgramUniform3i64NV\"))\n\tgpProgramUniform3i64vARB = (C.GPPROGRAMUNIFORM3I64VARB)(getProcAddr(\"glProgramUniform3i64vARB\"))\n\tgpProgramUniform3i64vNV = (C.GPPROGRAMUNIFORM3I64VNV)(getProcAddr(\"glProgramUniform3i64vNV\"))\n\tgpProgramUniform3iEXT = (C.GPPROGRAMUNIFORM3IEXT)(getProcAddr(\"glProgramUniform3iEXT\"))\n\tgpProgramUniform3iv = (C.GPPROGRAMUNIFORM3IV)(getProcAddr(\"glProgramUniform3iv\"))\n\tif gpProgramUniform3iv == nil {\n\t\treturn errors.New(\"glProgramUniform3iv\")\n\t}\n\tgpProgramUniform3ivEXT = (C.GPPROGRAMUNIFORM3IVEXT)(getProcAddr(\"glProgramUniform3ivEXT\"))\n\tgpProgramUniform3ui = (C.GPPROGRAMUNIFORM3UI)(getProcAddr(\"glProgramUniform3ui\"))\n\tif gpProgramUniform3ui == nil {\n\t\treturn errors.New(\"glProgramUniform3ui\")\n\t}\n\tgpProgramUniform3ui64ARB = (C.GPPROGRAMUNIFORM3UI64ARB)(getProcAddr(\"glProgramUniform3ui64ARB\"))\n\tgpProgramUniform3ui64NV = (C.GPPROGRAMUNIFORM3UI64NV)(getProcAddr(\"glProgramUniform3ui64NV\"))\n\tgpProgramUniform3ui64vARB = (C.GPPROGRAMUNIFORM3UI64VARB)(getProcAddr(\"glProgramUniform3ui64vARB\"))\n\tgpProgramUniform3ui64vNV = (C.GPPROGRAMUNIFORM3UI64VNV)(getProcAddr(\"glProgramUniform3ui64vNV\"))\n\tgpProgramUniform3uiEXT = (C.GPPROGRAMUNIFORM3UIEXT)(getProcAddr(\"glProgramUniform3uiEXT\"))\n\tgpProgramUniform3uiv = (C.GPPROGRAMUNIFORM3UIV)(getProcAddr(\"glProgramUniform3uiv\"))\n\tif gpProgramUniform3uiv == nil {\n\t\treturn errors.New(\"glProgramUniform3uiv\")\n\t}\n\tgpProgramUniform3uivEXT = (C.GPPROGRAMUNIFORM3UIVEXT)(getProcAddr(\"glProgramUniform3uivEXT\"))\n\tgpProgramUniform4d = (C.GPPROGRAMUNIFORM4D)(getProcAddr(\"glProgramUniform4d\"))\n\tif gpProgramUniform4d == nil {\n\t\treturn errors.New(\"glProgramUniform4d\")\n\t}\n\tgpProgramUniform4dEXT = (C.GPPROGRAMUNIFORM4DEXT)(getProcAddr(\"glProgramUniform4dEXT\"))\n\tgpProgramUniform4dv = (C.GPPROGRAMUNIFORM4DV)(getProcAddr(\"glProgramUniform4dv\"))\n\tif gpProgramUniform4dv == nil {\n\t\treturn errors.New(\"glProgramUniform4dv\")\n\t}\n\tgpProgramUniform4dvEXT = (C.GPPROGRAMUNIFORM4DVEXT)(getProcAddr(\"glProgramUniform4dvEXT\"))\n\tgpProgramUniform4f = (C.GPPROGRAMUNIFORM4F)(getProcAddr(\"glProgramUniform4f\"))\n\tif gpProgramUniform4f == nil {\n\t\treturn errors.New(\"glProgramUniform4f\")\n\t}\n\tgpProgramUniform4fEXT = (C.GPPROGRAMUNIFORM4FEXT)(getProcAddr(\"glProgramUniform4fEXT\"))\n\tgpProgramUniform4fv = (C.GPPROGRAMUNIFORM4FV)(getProcAddr(\"glProgramUniform4fv\"))\n\tif gpProgramUniform4fv == nil {\n\t\treturn errors.New(\"glProgramUniform4fv\")\n\t}\n\tgpProgramUniform4fvEXT = (C.GPPROGRAMUNIFORM4FVEXT)(getProcAddr(\"glProgramUniform4fvEXT\"))\n\tgpProgramUniform4i = (C.GPPROGRAMUNIFORM4I)(getProcAddr(\"glProgramUniform4i\"))\n\tif gpProgramUniform4i == nil {\n\t\treturn errors.New(\"glProgramUniform4i\")\n\t}\n\tgpProgramUniform4i64ARB = (C.GPPROGRAMUNIFORM4I64ARB)(getProcAddr(\"glProgramUniform4i64ARB\"))\n\tgpProgramUniform4i64NV = (C.GPPROGRAMUNIFORM4I64NV)(getProcAddr(\"glProgramUniform4i64NV\"))\n\tgpProgramUniform4i64vARB = (C.GPPROGRAMUNIFORM4I64VARB)(getProcAddr(\"glProgramUniform4i64vARB\"))\n\tgpProgramUniform4i64vNV = (C.GPPROGRAMUNIFORM4I64VNV)(getProcAddr(\"glProgramUniform4i64vNV\"))\n\tgpProgramUniform4iEXT = (C.GPPROGRAMUNIFORM4IEXT)(getProcAddr(\"glProgramUniform4iEXT\"))\n\tgpProgramUniform4iv = (C.GPPROGRAMUNIFORM4IV)(getProcAddr(\"glProgramUniform4iv\"))\n\tif gpProgramUniform4iv == nil {\n\t\treturn errors.New(\"glProgramUniform4iv\")\n\t}\n\tgpProgramUniform4ivEXT = (C.GPPROGRAMUNIFORM4IVEXT)(getProcAddr(\"glProgramUniform4ivEXT\"))\n\tgpProgramUniform4ui = (C.GPPROGRAMUNIFORM4UI)(getProcAddr(\"glProgramUniform4ui\"))\n\tif gpProgramUniform4ui == nil {\n\t\treturn errors.New(\"glProgramUniform4ui\")\n\t}\n\tgpProgramUniform4ui64ARB = (C.GPPROGRAMUNIFORM4UI64ARB)(getProcAddr(\"glProgramUniform4ui64ARB\"))\n\tgpProgramUniform4ui64NV = (C.GPPROGRAMUNIFORM4UI64NV)(getProcAddr(\"glProgramUniform4ui64NV\"))\n\tgpProgramUniform4ui64vARB = (C.GPPROGRAMUNIFORM4UI64VARB)(getProcAddr(\"glProgramUniform4ui64vARB\"))\n\tgpProgramUniform4ui64vNV = (C.GPPROGRAMUNIFORM4UI64VNV)(getProcAddr(\"glProgramUniform4ui64vNV\"))\n\tgpProgramUniform4uiEXT = (C.GPPROGRAMUNIFORM4UIEXT)(getProcAddr(\"glProgramUniform4uiEXT\"))\n\tgpProgramUniform4uiv = (C.GPPROGRAMUNIFORM4UIV)(getProcAddr(\"glProgramUniform4uiv\"))\n\tif gpProgramUniform4uiv == nil {\n\t\treturn errors.New(\"glProgramUniform4uiv\")\n\t}\n\tgpProgramUniform4uivEXT = (C.GPPROGRAMUNIFORM4UIVEXT)(getProcAddr(\"glProgramUniform4uivEXT\"))\n\tgpProgramUniformHandleui64ARB = (C.GPPROGRAMUNIFORMHANDLEUI64ARB)(getProcAddr(\"glProgramUniformHandleui64ARB\"))\n\tgpProgramUniformHandleui64NV = (C.GPPROGRAMUNIFORMHANDLEUI64NV)(getProcAddr(\"glProgramUniformHandleui64NV\"))\n\tgpProgramUniformHandleui64vARB = (C.GPPROGRAMUNIFORMHANDLEUI64VARB)(getProcAddr(\"glProgramUniformHandleui64vARB\"))\n\tgpProgramUniformHandleui64vNV = (C.GPPROGRAMUNIFORMHANDLEUI64VNV)(getProcAddr(\"glProgramUniformHandleui64vNV\"))\n\tgpProgramUniformMatrix2dv = (C.GPPROGRAMUNIFORMMATRIX2DV)(getProcAddr(\"glProgramUniformMatrix2dv\"))\n\tif gpProgramUniformMatrix2dv == nil {\n\t\treturn errors.New(\"glProgramUniformMatrix2dv\")\n\t}\n\tgpProgramUniformMatrix2dvEXT = (C.GPPROGRAMUNIFORMMATRIX2DVEXT)(getProcAddr(\"glProgramUniformMatrix2dvEXT\"))\n\tgpProgramUniformMatrix2fv = (C.GPPROGRAMUNIFORMMATRIX2FV)(getProcAddr(\"glProgramUniformMatrix2fv\"))\n\tif gpProgramUniformMatrix2fv == nil {\n\t\treturn errors.New(\"glProgramUniformMatrix2fv\")\n\t}\n\tgpProgramUniformMatrix2fvEXT = (C.GPPROGRAMUNIFORMMATRIX2FVEXT)(getProcAddr(\"glProgramUniformMatrix2fvEXT\"))\n\tgpProgramUniformMatrix2x3dv = (C.GPPROGRAMUNIFORMMATRIX2X3DV)(getProcAddr(\"glProgramUniformMatrix2x3dv\"))\n\tif gpProgramUniformMatrix2x3dv == nil {\n\t\treturn errors.New(\"glProgramUniformMatrix2x3dv\")\n\t}\n\tgpProgramUniformMatrix2x3dvEXT = (C.GPPROGRAMUNIFORMMATRIX2X3DVEXT)(getProcAddr(\"glProgramUniformMatrix2x3dvEXT\"))\n\tgpProgramUniformMatrix2x3fv = (C.GPPROGRAMUNIFORMMATRIX2X3FV)(getProcAddr(\"glProgramUniformMatrix2x3fv\"))\n\tif gpProgramUniformMatrix2x3fv == nil {\n\t\treturn errors.New(\"glProgramUniformMatrix2x3fv\")\n\t}\n\tgpProgramUniformMatrix2x3fvEXT = (C.GPPROGRAMUNIFORMMATRIX2X3FVEXT)(getProcAddr(\"glProgramUniformMatrix2x3fvEXT\"))\n\tgpProgramUniformMatrix2x4dv = (C.GPPROGRAMUNIFORMMATRIX2X4DV)(getProcAddr(\"glProgramUniformMatrix2x4dv\"))\n\tif gpProgramUniformMatrix2x4dv == nil {\n\t\treturn errors.New(\"glProgramUniformMatrix2x4dv\")\n\t}\n\tgpProgramUniformMatrix2x4dvEXT = (C.GPPROGRAMUNIFORMMATRIX2X4DVEXT)(getProcAddr(\"glProgramUniformMatrix2x4dvEXT\"))\n\tgpProgramUniformMatrix2x4fv = (C.GPPROGRAMUNIFORMMATRIX2X4FV)(getProcAddr(\"glProgramUniformMatrix2x4fv\"))\n\tif gpProgramUniformMatrix2x4fv == nil {\n\t\treturn errors.New(\"glProgramUniformMatrix2x4fv\")\n\t}\n\tgpProgramUniformMatrix2x4fvEXT = (C.GPPROGRAMUNIFORMMATRIX2X4FVEXT)(getProcAddr(\"glProgramUniformMatrix2x4fvEXT\"))\n\tgpProgramUniformMatrix3dv = (C.GPPROGRAMUNIFORMMATRIX3DV)(getProcAddr(\"glProgramUniformMatrix3dv\"))\n\tif gpProgramUniformMatrix3dv == nil {\n\t\treturn errors.New(\"glProgramUniformMatrix3dv\")\n\t}\n\tgpProgramUniformMatrix3dvEXT = (C.GPPROGRAMUNIFORMMATRIX3DVEXT)(getProcAddr(\"glProgramUniformMatrix3dvEXT\"))\n\tgpProgramUniformMatrix3fv = (C.GPPROGRAMUNIFORMMATRIX3FV)(getProcAddr(\"glProgramUniformMatrix3fv\"))\n\tif gpProgramUniformMatrix3fv == nil {\n\t\treturn errors.New(\"glProgramUniformMatrix3fv\")\n\t}\n\tgpProgramUniformMatrix3fvEXT = (C.GPPROGRAMUNIFORMMATRIX3FVEXT)(getProcAddr(\"glProgramUniformMatrix3fvEXT\"))\n\tgpProgramUniformMatrix3x2dv = (C.GPPROGRAMUNIFORMMATRIX3X2DV)(getProcAddr(\"glProgramUniformMatrix3x2dv\"))\n\tif gpProgramUniformMatrix3x2dv == nil {\n\t\treturn errors.New(\"glProgramUniformMatrix3x2dv\")\n\t}\n\tgpProgramUniformMatrix3x2dvEXT = (C.GPPROGRAMUNIFORMMATRIX3X2DVEXT)(getProcAddr(\"glProgramUniformMatrix3x2dvEXT\"))\n\tgpProgramUniformMatrix3x2fv = (C.GPPROGRAMUNIFORMMATRIX3X2FV)(getProcAddr(\"glProgramUniformMatrix3x2fv\"))\n\tif gpProgramUniformMatrix3x2fv == nil {\n\t\treturn errors.New(\"glProgramUniformMatrix3x2fv\")\n\t}\n\tgpProgramUniformMatrix3x2fvEXT = (C.GPPROGRAMUNIFORMMATRIX3X2FVEXT)(getProcAddr(\"glProgramUniformMatrix3x2fvEXT\"))\n\tgpProgramUniformMatrix3x4dv = (C.GPPROGRAMUNIFORMMATRIX3X4DV)(getProcAddr(\"glProgramUniformMatrix3x4dv\"))\n\tif gpProgramUniformMatrix3x4dv == nil {\n\t\treturn errors.New(\"glProgramUniformMatrix3x4dv\")\n\t}\n\tgpProgramUniformMatrix3x4dvEXT = (C.GPPROGRAMUNIFORMMATRIX3X4DVEXT)(getProcAddr(\"glProgramUniformMatrix3x4dvEXT\"))\n\tgpProgramUniformMatrix3x4fv = (C.GPPROGRAMUNIFORMMATRIX3X4FV)(getProcAddr(\"glProgramUniformMatrix3x4fv\"))\n\tif gpProgramUniformMatrix3x4fv == nil {\n\t\treturn errors.New(\"glProgramUniformMatrix3x4fv\")\n\t}\n\tgpProgramUniformMatrix3x4fvEXT = (C.GPPROGRAMUNIFORMMATRIX3X4FVEXT)(getProcAddr(\"glProgramUniformMatrix3x4fvEXT\"))\n\tgpProgramUniformMatrix4dv = (C.GPPROGRAMUNIFORMMATRIX4DV)(getProcAddr(\"glProgramUniformMatrix4dv\"))\n\tif gpProgramUniformMatrix4dv == nil {\n\t\treturn errors.New(\"glProgramUniformMatrix4dv\")\n\t}\n\tgpProgramUniformMatrix4dvEXT = (C.GPPROGRAMUNIFORMMATRIX4DVEXT)(getProcAddr(\"glProgramUniformMatrix4dvEXT\"))\n\tgpProgramUniformMatrix4fv = (C.GPPROGRAMUNIFORMMATRIX4FV)(getProcAddr(\"glProgramUniformMatrix4fv\"))\n\tif gpProgramUniformMatrix4fv == nil {\n\t\treturn errors.New(\"glProgramUniformMatrix4fv\")\n\t}\n\tgpProgramUniformMatrix4fvEXT = (C.GPPROGRAMUNIFORMMATRIX4FVEXT)(getProcAddr(\"glProgramUniformMatrix4fvEXT\"))\n\tgpProgramUniformMatrix4x2dv = (C.GPPROGRAMUNIFORMMATRIX4X2DV)(getProcAddr(\"glProgramUniformMatrix4x2dv\"))\n\tif gpProgramUniformMatrix4x2dv == nil {\n\t\treturn errors.New(\"glProgramUniformMatrix4x2dv\")\n\t}\n\tgpProgramUniformMatrix4x2dvEXT = (C.GPPROGRAMUNIFORMMATRIX4X2DVEXT)(getProcAddr(\"glProgramUniformMatrix4x2dvEXT\"))\n\tgpProgramUniformMatrix4x2fv = (C.GPPROGRAMUNIFORMMATRIX4X2FV)(getProcAddr(\"glProgramUniformMatrix4x2fv\"))\n\tif gpProgramUniformMatrix4x2fv == nil {\n\t\treturn errors.New(\"glProgramUniformMatrix4x2fv\")\n\t}\n\tgpProgramUniformMatrix4x2fvEXT = (C.GPPROGRAMUNIFORMMATRIX4X2FVEXT)(getProcAddr(\"glProgramUniformMatrix4x2fvEXT\"))\n\tgpProgramUniformMatrix4x3dv = (C.GPPROGRAMUNIFORMMATRIX4X3DV)(getProcAddr(\"glProgramUniformMatrix4x3dv\"))\n\tif gpProgramUniformMatrix4x3dv == nil {\n\t\treturn errors.New(\"glProgramUniformMatrix4x3dv\")\n\t}\n\tgpProgramUniformMatrix4x3dvEXT = (C.GPPROGRAMUNIFORMMATRIX4X3DVEXT)(getProcAddr(\"glProgramUniformMatrix4x3dvEXT\"))\n\tgpProgramUniformMatrix4x3fv = (C.GPPROGRAMUNIFORMMATRIX4X3FV)(getProcAddr(\"glProgramUniformMatrix4x3fv\"))\n\tif gpProgramUniformMatrix4x3fv == nil {\n\t\treturn errors.New(\"glProgramUniformMatrix4x3fv\")\n\t}\n\tgpProgramUniformMatrix4x3fvEXT = (C.GPPROGRAMUNIFORMMATRIX4X3FVEXT)(getProcAddr(\"glProgramUniformMatrix4x3fvEXT\"))\n\tgpProgramUniformui64NV = (C.GPPROGRAMUNIFORMUI64NV)(getProcAddr(\"glProgramUniformui64NV\"))\n\tgpProgramUniformui64vNV = (C.GPPROGRAMUNIFORMUI64VNV)(getProcAddr(\"glProgramUniformui64vNV\"))\n\tgpProgramVertexLimitNV = (C.GPPROGRAMVERTEXLIMITNV)(getProcAddr(\"glProgramVertexLimitNV\"))\n\tgpProvokingVertex = (C.GPPROVOKINGVERTEX)(getProcAddr(\"glProvokingVertex\"))\n\tif gpProvokingVertex == nil {\n\t\treturn errors.New(\"glProvokingVertex\")\n\t}\n\tgpProvokingVertexEXT = (C.GPPROVOKINGVERTEXEXT)(getProcAddr(\"glProvokingVertexEXT\"))\n\tgpPushAttrib = (C.GPPUSHATTRIB)(getProcAddr(\"glPushAttrib\"))\n\tif gpPushAttrib == nil {\n\t\treturn errors.New(\"glPushAttrib\")\n\t}\n\tgpPushClientAttrib = (C.GPPUSHCLIENTATTRIB)(getProcAddr(\"glPushClientAttrib\"))\n\tif gpPushClientAttrib == nil {\n\t\treturn errors.New(\"glPushClientAttrib\")\n\t}\n\tgpPushClientAttribDefaultEXT = (C.GPPUSHCLIENTATTRIBDEFAULTEXT)(getProcAddr(\"glPushClientAttribDefaultEXT\"))\n\tgpPushDebugGroup = (C.GPPUSHDEBUGGROUP)(getProcAddr(\"glPushDebugGroup\"))\n\tif gpPushDebugGroup == nil {\n\t\treturn errors.New(\"glPushDebugGroup\")\n\t}\n\tgpPushDebugGroupKHR = (C.GPPUSHDEBUGGROUPKHR)(getProcAddr(\"glPushDebugGroupKHR\"))\n\tgpPushGroupMarkerEXT = (C.GPPUSHGROUPMARKEREXT)(getProcAddr(\"glPushGroupMarkerEXT\"))\n\tgpPushMatrix = (C.GPPUSHMATRIX)(getProcAddr(\"glPushMatrix\"))\n\tif gpPushMatrix == nil {\n\t\treturn errors.New(\"glPushMatrix\")\n\t}\n\tgpPushName = (C.GPPUSHNAME)(getProcAddr(\"glPushName\"))\n\tif gpPushName == nil {\n\t\treturn errors.New(\"glPushName\")\n\t}\n\tgpQueryCounter = (C.GPQUERYCOUNTER)(getProcAddr(\"glQueryCounter\"))\n\tif gpQueryCounter == nil {\n\t\treturn errors.New(\"glQueryCounter\")\n\t}\n\tgpQueryMatrixxOES = (C.GPQUERYMATRIXXOES)(getProcAddr(\"glQueryMatrixxOES\"))\n\tgpQueryObjectParameteruiAMD = (C.GPQUERYOBJECTPARAMETERUIAMD)(getProcAddr(\"glQueryObjectParameteruiAMD\"))\n\tgpQueryResourceNV = (C.GPQUERYRESOURCENV)(getProcAddr(\"glQueryResourceNV\"))\n\tgpQueryResourceTagNV = (C.GPQUERYRESOURCETAGNV)(getProcAddr(\"glQueryResourceTagNV\"))\n\tgpRasterPos2d = (C.GPRASTERPOS2D)(getProcAddr(\"glRasterPos2d\"))\n\tif gpRasterPos2d == nil {\n\t\treturn errors.New(\"glRasterPos2d\")\n\t}\n\tgpRasterPos2dv = (C.GPRASTERPOS2DV)(getProcAddr(\"glRasterPos2dv\"))\n\tif gpRasterPos2dv == nil {\n\t\treturn errors.New(\"glRasterPos2dv\")\n\t}\n\tgpRasterPos2f = (C.GPRASTERPOS2F)(getProcAddr(\"glRasterPos2f\"))\n\tif gpRasterPos2f == nil {\n\t\treturn errors.New(\"glRasterPos2f\")\n\t}\n\tgpRasterPos2fv = (C.GPRASTERPOS2FV)(getProcAddr(\"glRasterPos2fv\"))\n\tif gpRasterPos2fv == nil {\n\t\treturn errors.New(\"glRasterPos2fv\")\n\t}\n\tgpRasterPos2i = (C.GPRASTERPOS2I)(getProcAddr(\"glRasterPos2i\"))\n\tif gpRasterPos2i == nil {\n\t\treturn errors.New(\"glRasterPos2i\")\n\t}\n\tgpRasterPos2iv = (C.GPRASTERPOS2IV)(getProcAddr(\"glRasterPos2iv\"))\n\tif gpRasterPos2iv == nil {\n\t\treturn errors.New(\"glRasterPos2iv\")\n\t}\n\tgpRasterPos2s = (C.GPRASTERPOS2S)(getProcAddr(\"glRasterPos2s\"))\n\tif gpRasterPos2s == nil {\n\t\treturn errors.New(\"glRasterPos2s\")\n\t}\n\tgpRasterPos2sv = (C.GPRASTERPOS2SV)(getProcAddr(\"glRasterPos2sv\"))\n\tif gpRasterPos2sv == nil {\n\t\treturn errors.New(\"glRasterPos2sv\")\n\t}\n\tgpRasterPos2xOES = (C.GPRASTERPOS2XOES)(getProcAddr(\"glRasterPos2xOES\"))\n\tgpRasterPos2xvOES = (C.GPRASTERPOS2XVOES)(getProcAddr(\"glRasterPos2xvOES\"))\n\tgpRasterPos3d = (C.GPRASTERPOS3D)(getProcAddr(\"glRasterPos3d\"))\n\tif gpRasterPos3d == nil {\n\t\treturn errors.New(\"glRasterPos3d\")\n\t}\n\tgpRasterPos3dv = (C.GPRASTERPOS3DV)(getProcAddr(\"glRasterPos3dv\"))\n\tif gpRasterPos3dv == nil {\n\t\treturn errors.New(\"glRasterPos3dv\")\n\t}\n\tgpRasterPos3f = (C.GPRASTERPOS3F)(getProcAddr(\"glRasterPos3f\"))\n\tif gpRasterPos3f == nil {\n\t\treturn errors.New(\"glRasterPos3f\")\n\t}\n\tgpRasterPos3fv = (C.GPRASTERPOS3FV)(getProcAddr(\"glRasterPos3fv\"))\n\tif gpRasterPos3fv == nil {\n\t\treturn errors.New(\"glRasterPos3fv\")\n\t}\n\tgpRasterPos3i = (C.GPRASTERPOS3I)(getProcAddr(\"glRasterPos3i\"))\n\tif gpRasterPos3i == nil {\n\t\treturn errors.New(\"glRasterPos3i\")\n\t}\n\tgpRasterPos3iv = (C.GPRASTERPOS3IV)(getProcAddr(\"glRasterPos3iv\"))\n\tif gpRasterPos3iv == nil {\n\t\treturn errors.New(\"glRasterPos3iv\")\n\t}\n\tgpRasterPos3s = (C.GPRASTERPOS3S)(getProcAddr(\"glRasterPos3s\"))\n\tif gpRasterPos3s == nil {\n\t\treturn errors.New(\"glRasterPos3s\")\n\t}\n\tgpRasterPos3sv = (C.GPRASTERPOS3SV)(getProcAddr(\"glRasterPos3sv\"))\n\tif gpRasterPos3sv == nil {\n\t\treturn errors.New(\"glRasterPos3sv\")\n\t}\n\tgpRasterPos3xOES = (C.GPRASTERPOS3XOES)(getProcAddr(\"glRasterPos3xOES\"))\n\tgpRasterPos3xvOES = (C.GPRASTERPOS3XVOES)(getProcAddr(\"glRasterPos3xvOES\"))\n\tgpRasterPos4d = (C.GPRASTERPOS4D)(getProcAddr(\"glRasterPos4d\"))\n\tif gpRasterPos4d == nil {\n\t\treturn errors.New(\"glRasterPos4d\")\n\t}\n\tgpRasterPos4dv = (C.GPRASTERPOS4DV)(getProcAddr(\"glRasterPos4dv\"))\n\tif gpRasterPos4dv == nil {\n\t\treturn errors.New(\"glRasterPos4dv\")\n\t}\n\tgpRasterPos4f = (C.GPRASTERPOS4F)(getProcAddr(\"glRasterPos4f\"))\n\tif gpRasterPos4f == nil {\n\t\treturn errors.New(\"glRasterPos4f\")\n\t}\n\tgpRasterPos4fv = (C.GPRASTERPOS4FV)(getProcAddr(\"glRasterPos4fv\"))\n\tif gpRasterPos4fv == nil {\n\t\treturn errors.New(\"glRasterPos4fv\")\n\t}\n\tgpRasterPos4i = (C.GPRASTERPOS4I)(getProcAddr(\"glRasterPos4i\"))\n\tif gpRasterPos4i == nil {\n\t\treturn errors.New(\"glRasterPos4i\")\n\t}\n\tgpRasterPos4iv = (C.GPRASTERPOS4IV)(getProcAddr(\"glRasterPos4iv\"))\n\tif gpRasterPos4iv == nil {\n\t\treturn errors.New(\"glRasterPos4iv\")\n\t}\n\tgpRasterPos4s = (C.GPRASTERPOS4S)(getProcAddr(\"glRasterPos4s\"))\n\tif gpRasterPos4s == nil {\n\t\treturn errors.New(\"glRasterPos4s\")\n\t}\n\tgpRasterPos4sv = (C.GPRASTERPOS4SV)(getProcAddr(\"glRasterPos4sv\"))\n\tif gpRasterPos4sv == nil {\n\t\treturn errors.New(\"glRasterPos4sv\")\n\t}\n\tgpRasterPos4xOES = (C.GPRASTERPOS4XOES)(getProcAddr(\"glRasterPos4xOES\"))\n\tgpRasterPos4xvOES = (C.GPRASTERPOS4XVOES)(getProcAddr(\"glRasterPos4xvOES\"))\n\tgpRasterSamplesEXT = (C.GPRASTERSAMPLESEXT)(getProcAddr(\"glRasterSamplesEXT\"))\n\tgpReadBuffer = (C.GPREADBUFFER)(getProcAddr(\"glReadBuffer\"))\n\tif gpReadBuffer == nil {\n\t\treturn errors.New(\"glReadBuffer\")\n\t}\n\tgpReadInstrumentsSGIX = (C.GPREADINSTRUMENTSSGIX)(getProcAddr(\"glReadInstrumentsSGIX\"))\n\tgpReadPixels = (C.GPREADPIXELS)(getProcAddr(\"glReadPixels\"))\n\tif gpReadPixels == nil {\n\t\treturn errors.New(\"glReadPixels\")\n\t}\n\tgpReadnPixels = (C.GPREADNPIXELS)(getProcAddr(\"glReadnPixels\"))\n\tgpReadnPixelsARB = (C.GPREADNPIXELSARB)(getProcAddr(\"glReadnPixelsARB\"))\n\tgpReadnPixelsKHR = (C.GPREADNPIXELSKHR)(getProcAddr(\"glReadnPixelsKHR\"))\n\tgpRectd = (C.GPRECTD)(getProcAddr(\"glRectd\"))\n\tif gpRectd == nil {\n\t\treturn errors.New(\"glRectd\")\n\t}\n\tgpRectdv = (C.GPRECTDV)(getProcAddr(\"glRectdv\"))\n\tif gpRectdv == nil {\n\t\treturn errors.New(\"glRectdv\")\n\t}\n\tgpRectf = (C.GPRECTF)(getProcAddr(\"glRectf\"))\n\tif gpRectf == nil {\n\t\treturn errors.New(\"glRectf\")\n\t}\n\tgpRectfv = (C.GPRECTFV)(getProcAddr(\"glRectfv\"))\n\tif gpRectfv == nil {\n\t\treturn errors.New(\"glRectfv\")\n\t}\n\tgpRecti = (C.GPRECTI)(getProcAddr(\"glRecti\"))\n\tif gpRecti == nil {\n\t\treturn errors.New(\"glRecti\")\n\t}\n\tgpRectiv = (C.GPRECTIV)(getProcAddr(\"glRectiv\"))\n\tif gpRectiv == nil {\n\t\treturn errors.New(\"glRectiv\")\n\t}\n\tgpRects = (C.GPRECTS)(getProcAddr(\"glRects\"))\n\tif gpRects == nil {\n\t\treturn errors.New(\"glRects\")\n\t}\n\tgpRectsv = (C.GPRECTSV)(getProcAddr(\"glRectsv\"))\n\tif gpRectsv == nil {\n\t\treturn errors.New(\"glRectsv\")\n\t}\n\tgpRectxOES = (C.GPRECTXOES)(getProcAddr(\"glRectxOES\"))\n\tgpRectxvOES = (C.GPRECTXVOES)(getProcAddr(\"glRectxvOES\"))\n\tgpReferencePlaneSGIX = (C.GPREFERENCEPLANESGIX)(getProcAddr(\"glReferencePlaneSGIX\"))\n\tgpReleaseKeyedMutexWin32EXT = (C.GPRELEASEKEYEDMUTEXWIN32EXT)(getProcAddr(\"glReleaseKeyedMutexWin32EXT\"))\n\tgpReleaseShaderCompiler = (C.GPRELEASESHADERCOMPILER)(getProcAddr(\"glReleaseShaderCompiler\"))\n\tif gpReleaseShaderCompiler == nil {\n\t\treturn errors.New(\"glReleaseShaderCompiler\")\n\t}\n\tgpRenderGpuMaskNV = (C.GPRENDERGPUMASKNV)(getProcAddr(\"glRenderGpuMaskNV\"))\n\tgpRenderMode = (C.GPRENDERMODE)(getProcAddr(\"glRenderMode\"))\n\tif gpRenderMode == nil {\n\t\treturn errors.New(\"glRenderMode\")\n\t}\n\tgpRenderbufferStorage = (C.GPRENDERBUFFERSTORAGE)(getProcAddr(\"glRenderbufferStorage\"))\n\tif gpRenderbufferStorage == nil {\n\t\treturn errors.New(\"glRenderbufferStorage\")\n\t}\n\tgpRenderbufferStorageEXT = (C.GPRENDERBUFFERSTORAGEEXT)(getProcAddr(\"glRenderbufferStorageEXT\"))\n\tgpRenderbufferStorageMultisample = (C.GPRENDERBUFFERSTORAGEMULTISAMPLE)(getProcAddr(\"glRenderbufferStorageMultisample\"))\n\tif gpRenderbufferStorageMultisample == nil {\n\t\treturn errors.New(\"glRenderbufferStorageMultisample\")\n\t}\n\tgpRenderbufferStorageMultisampleAdvancedAMD = (C.GPRENDERBUFFERSTORAGEMULTISAMPLEADVANCEDAMD)(getProcAddr(\"glRenderbufferStorageMultisampleAdvancedAMD\"))\n\tgpRenderbufferStorageMultisampleCoverageNV = (C.GPRENDERBUFFERSTORAGEMULTISAMPLECOVERAGENV)(getProcAddr(\"glRenderbufferStorageMultisampleCoverageNV\"))\n\tgpRenderbufferStorageMultisampleEXT = (C.GPRENDERBUFFERSTORAGEMULTISAMPLEEXT)(getProcAddr(\"glRenderbufferStorageMultisampleEXT\"))\n\tgpReplacementCodePointerSUN = (C.GPREPLACEMENTCODEPOINTERSUN)(getProcAddr(\"glReplacementCodePointerSUN\"))\n\tgpReplacementCodeubSUN = (C.GPREPLACEMENTCODEUBSUN)(getProcAddr(\"glReplacementCodeubSUN\"))\n\tgpReplacementCodeubvSUN = (C.GPREPLACEMENTCODEUBVSUN)(getProcAddr(\"glReplacementCodeubvSUN\"))\n\tgpReplacementCodeuiColor3fVertex3fSUN = (C.GPREPLACEMENTCODEUICOLOR3FVERTEX3FSUN)(getProcAddr(\"glReplacementCodeuiColor3fVertex3fSUN\"))\n\tgpReplacementCodeuiColor3fVertex3fvSUN = (C.GPREPLACEMENTCODEUICOLOR3FVERTEX3FVSUN)(getProcAddr(\"glReplacementCodeuiColor3fVertex3fvSUN\"))\n\tgpReplacementCodeuiColor4fNormal3fVertex3fSUN = (C.GPREPLACEMENTCODEUICOLOR4FNORMAL3FVERTEX3FSUN)(getProcAddr(\"glReplacementCodeuiColor4fNormal3fVertex3fSUN\"))\n\tgpReplacementCodeuiColor4fNormal3fVertex3fvSUN = (C.GPREPLACEMENTCODEUICOLOR4FNORMAL3FVERTEX3FVSUN)(getProcAddr(\"glReplacementCodeuiColor4fNormal3fVertex3fvSUN\"))\n\tgpReplacementCodeuiColor4ubVertex3fSUN = (C.GPREPLACEMENTCODEUICOLOR4UBVERTEX3FSUN)(getProcAddr(\"glReplacementCodeuiColor4ubVertex3fSUN\"))\n\tgpReplacementCodeuiColor4ubVertex3fvSUN = (C.GPREPLACEMENTCODEUICOLOR4UBVERTEX3FVSUN)(getProcAddr(\"glReplacementCodeuiColor4ubVertex3fvSUN\"))\n\tgpReplacementCodeuiNormal3fVertex3fSUN = (C.GPREPLACEMENTCODEUINORMAL3FVERTEX3FSUN)(getProcAddr(\"glReplacementCodeuiNormal3fVertex3fSUN\"))\n\tgpReplacementCodeuiNormal3fVertex3fvSUN = (C.GPREPLACEMENTCODEUINORMAL3FVERTEX3FVSUN)(getProcAddr(\"glReplacementCodeuiNormal3fVertex3fvSUN\"))\n\tgpReplacementCodeuiSUN = (C.GPREPLACEMENTCODEUISUN)(getProcAddr(\"glReplacementCodeuiSUN\"))\n\tgpReplacementCodeuiTexCoord2fColor4fNormal3fVertex3fSUN = (C.GPREPLACEMENTCODEUITEXCOORD2FCOLOR4FNORMAL3FVERTEX3FSUN)(getProcAddr(\"glReplacementCodeuiTexCoord2fColor4fNormal3fVertex3fSUN\"))\n\tgpReplacementCodeuiTexCoord2fColor4fNormal3fVertex3fvSUN = (C.GPREPLACEMENTCODEUITEXCOORD2FCOLOR4FNORMAL3FVERTEX3FVSUN)(getProcAddr(\"glReplacementCodeuiTexCoord2fColor4fNormal3fVertex3fvSUN\"))\n\tgpReplacementCodeuiTexCoord2fNormal3fVertex3fSUN = (C.GPREPLACEMENTCODEUITEXCOORD2FNORMAL3FVERTEX3FSUN)(getProcAddr(\"glReplacementCodeuiTexCoord2fNormal3fVertex3fSUN\"))\n\tgpReplacementCodeuiTexCoord2fNormal3fVertex3fvSUN = (C.GPREPLACEMENTCODEUITEXCOORD2FNORMAL3FVERTEX3FVSUN)(getProcAddr(\"glReplacementCodeuiTexCoord2fNormal3fVertex3fvSUN\"))\n\tgpReplacementCodeuiTexCoord2fVertex3fSUN = (C.GPREPLACEMENTCODEUITEXCOORD2FVERTEX3FSUN)(getProcAddr(\"glReplacementCodeuiTexCoord2fVertex3fSUN\"))\n\tgpReplacementCodeuiTexCoord2fVertex3fvSUN = (C.GPREPLACEMENTCODEUITEXCOORD2FVERTEX3FVSUN)(getProcAddr(\"glReplacementCodeuiTexCoord2fVertex3fvSUN\"))\n\tgpReplacementCodeuiVertex3fSUN = (C.GPREPLACEMENTCODEUIVERTEX3FSUN)(getProcAddr(\"glReplacementCodeuiVertex3fSUN\"))\n\tgpReplacementCodeuiVertex3fvSUN = (C.GPREPLACEMENTCODEUIVERTEX3FVSUN)(getProcAddr(\"glReplacementCodeuiVertex3fvSUN\"))\n\tgpReplacementCodeuivSUN = (C.GPREPLACEMENTCODEUIVSUN)(getProcAddr(\"glReplacementCodeuivSUN\"))\n\tgpReplacementCodeusSUN = (C.GPREPLACEMENTCODEUSSUN)(getProcAddr(\"glReplacementCodeusSUN\"))\n\tgpReplacementCodeusvSUN = (C.GPREPLACEMENTCODEUSVSUN)(getProcAddr(\"glReplacementCodeusvSUN\"))\n\tgpRequestResidentProgramsNV = (C.GPREQUESTRESIDENTPROGRAMSNV)(getProcAddr(\"glRequestResidentProgramsNV\"))\n\tgpResetHistogram = (C.GPRESETHISTOGRAM)(getProcAddr(\"glResetHistogram\"))\n\tgpResetHistogramEXT = (C.GPRESETHISTOGRAMEXT)(getProcAddr(\"glResetHistogramEXT\"))\n\tgpResetMemoryObjectParameterNV = (C.GPRESETMEMORYOBJECTPARAMETERNV)(getProcAddr(\"glResetMemoryObjectParameterNV\"))\n\tgpResetMinmax = (C.GPRESETMINMAX)(getProcAddr(\"glResetMinmax\"))\n\tgpResetMinmaxEXT = (C.GPRESETMINMAXEXT)(getProcAddr(\"glResetMinmaxEXT\"))\n\tgpResizeBuffersMESA = (C.GPRESIZEBUFFERSMESA)(getProcAddr(\"glResizeBuffersMESA\"))\n\tgpResolveDepthValuesNV = (C.GPRESOLVEDEPTHVALUESNV)(getProcAddr(\"glResolveDepthValuesNV\"))\n\tgpResumeTransformFeedback = (C.GPRESUMETRANSFORMFEEDBACK)(getProcAddr(\"glResumeTransformFeedback\"))\n\tif gpResumeTransformFeedback == nil {\n\t\treturn errors.New(\"glResumeTransformFeedback\")\n\t}\n\tgpResumeTransformFeedbackNV = (C.GPRESUMETRANSFORMFEEDBACKNV)(getProcAddr(\"glResumeTransformFeedbackNV\"))\n\tgpRotated = (C.GPROTATED)(getProcAddr(\"glRotated\"))\n\tif gpRotated == nil {\n\t\treturn errors.New(\"glRotated\")\n\t}\n\tgpRotatef = (C.GPROTATEF)(getProcAddr(\"glRotatef\"))\n\tif gpRotatef == nil {\n\t\treturn errors.New(\"glRotatef\")\n\t}\n\tgpRotatexOES = (C.GPROTATEXOES)(getProcAddr(\"glRotatexOES\"))\n\tgpSampleCoverage = (C.GPSAMPLECOVERAGE)(getProcAddr(\"glSampleCoverage\"))\n\tif gpSampleCoverage == nil {\n\t\treturn errors.New(\"glSampleCoverage\")\n\t}\n\tgpSampleCoverageARB = (C.GPSAMPLECOVERAGEARB)(getProcAddr(\"glSampleCoverageARB\"))\n\tgpSampleCoveragexOES = (C.GPSAMPLECOVERAGEXOES)(getProcAddr(\"glSampleCoveragexOES\"))\n\tgpSampleMapATI = (C.GPSAMPLEMAPATI)(getProcAddr(\"glSampleMapATI\"))\n\tgpSampleMaskEXT = (C.GPSAMPLEMASKEXT)(getProcAddr(\"glSampleMaskEXT\"))\n\tgpSampleMaskIndexedNV = (C.GPSAMPLEMASKINDEXEDNV)(getProcAddr(\"glSampleMaskIndexedNV\"))\n\tgpSampleMaskSGIS = (C.GPSAMPLEMASKSGIS)(getProcAddr(\"glSampleMaskSGIS\"))\n\tgpSampleMaski = (C.GPSAMPLEMASKI)(getProcAddr(\"glSampleMaski\"))\n\tif gpSampleMaski == nil {\n\t\treturn errors.New(\"glSampleMaski\")\n\t}\n\tgpSamplePatternEXT = (C.GPSAMPLEPATTERNEXT)(getProcAddr(\"glSamplePatternEXT\"))\n\tgpSamplePatternSGIS = (C.GPSAMPLEPATTERNSGIS)(getProcAddr(\"glSamplePatternSGIS\"))\n\tgpSamplerParameterIiv = (C.GPSAMPLERPARAMETERIIV)(getProcAddr(\"glSamplerParameterIiv\"))\n\tif gpSamplerParameterIiv == nil {\n\t\treturn errors.New(\"glSamplerParameterIiv\")\n\t}\n\tgpSamplerParameterIuiv = (C.GPSAMPLERPARAMETERIUIV)(getProcAddr(\"glSamplerParameterIuiv\"))\n\tif gpSamplerParameterIuiv == nil {\n\t\treturn errors.New(\"glSamplerParameterIuiv\")\n\t}\n\tgpSamplerParameterf = (C.GPSAMPLERPARAMETERF)(getProcAddr(\"glSamplerParameterf\"))\n\tif gpSamplerParameterf == nil {\n\t\treturn errors.New(\"glSamplerParameterf\")\n\t}\n\tgpSamplerParameterfv = (C.GPSAMPLERPARAMETERFV)(getProcAddr(\"glSamplerParameterfv\"))\n\tif gpSamplerParameterfv == nil {\n\t\treturn errors.New(\"glSamplerParameterfv\")\n\t}\n\tgpSamplerParameteri = (C.GPSAMPLERPARAMETERI)(getProcAddr(\"glSamplerParameteri\"))\n\tif gpSamplerParameteri == nil {\n\t\treturn errors.New(\"glSamplerParameteri\")\n\t}\n\tgpSamplerParameteriv = (C.GPSAMPLERPARAMETERIV)(getProcAddr(\"glSamplerParameteriv\"))\n\tif gpSamplerParameteriv == nil {\n\t\treturn errors.New(\"glSamplerParameteriv\")\n\t}\n\tgpScaled = (C.GPSCALED)(getProcAddr(\"glScaled\"))\n\tif gpScaled == nil {\n\t\treturn errors.New(\"glScaled\")\n\t}\n\tgpScalef = (C.GPSCALEF)(getProcAddr(\"glScalef\"))\n\tif gpScalef == nil {\n\t\treturn errors.New(\"glScalef\")\n\t}\n\tgpScalexOES = (C.GPSCALEXOES)(getProcAddr(\"glScalexOES\"))\n\tgpScissor = (C.GPSCISSOR)(getProcAddr(\"glScissor\"))\n\tif gpScissor == nil {\n\t\treturn errors.New(\"glScissor\")\n\t}\n\tgpScissorArrayv = (C.GPSCISSORARRAYV)(getProcAddr(\"glScissorArrayv\"))\n\tif gpScissorArrayv == nil {\n\t\treturn errors.New(\"glScissorArrayv\")\n\t}\n\tgpScissorExclusiveArrayvNV = (C.GPSCISSOREXCLUSIVEARRAYVNV)(getProcAddr(\"glScissorExclusiveArrayvNV\"))\n\tgpScissorExclusiveNV = (C.GPSCISSOREXCLUSIVENV)(getProcAddr(\"glScissorExclusiveNV\"))\n\tgpScissorIndexed = (C.GPSCISSORINDEXED)(getProcAddr(\"glScissorIndexed\"))\n\tif gpScissorIndexed == nil {\n\t\treturn errors.New(\"glScissorIndexed\")\n\t}\n\tgpScissorIndexedv = (C.GPSCISSORINDEXEDV)(getProcAddr(\"glScissorIndexedv\"))\n\tif gpScissorIndexedv == nil {\n\t\treturn errors.New(\"glScissorIndexedv\")\n\t}\n\tgpSecondaryColor3b = (C.GPSECONDARYCOLOR3B)(getProcAddr(\"glSecondaryColor3b\"))\n\tif gpSecondaryColor3b == nil {\n\t\treturn errors.New(\"glSecondaryColor3b\")\n\t}\n\tgpSecondaryColor3bEXT = (C.GPSECONDARYCOLOR3BEXT)(getProcAddr(\"glSecondaryColor3bEXT\"))\n\tgpSecondaryColor3bv = (C.GPSECONDARYCOLOR3BV)(getProcAddr(\"glSecondaryColor3bv\"))\n\tif gpSecondaryColor3bv == nil {\n\t\treturn errors.New(\"glSecondaryColor3bv\")\n\t}\n\tgpSecondaryColor3bvEXT = (C.GPSECONDARYCOLOR3BVEXT)(getProcAddr(\"glSecondaryColor3bvEXT\"))\n\tgpSecondaryColor3d = (C.GPSECONDARYCOLOR3D)(getProcAddr(\"glSecondaryColor3d\"))\n\tif gpSecondaryColor3d == nil {\n\t\treturn errors.New(\"glSecondaryColor3d\")\n\t}\n\tgpSecondaryColor3dEXT = (C.GPSECONDARYCOLOR3DEXT)(getProcAddr(\"glSecondaryColor3dEXT\"))\n\tgpSecondaryColor3dv = (C.GPSECONDARYCOLOR3DV)(getProcAddr(\"glSecondaryColor3dv\"))\n\tif gpSecondaryColor3dv == nil {\n\t\treturn errors.New(\"glSecondaryColor3dv\")\n\t}\n\tgpSecondaryColor3dvEXT = (C.GPSECONDARYCOLOR3DVEXT)(getProcAddr(\"glSecondaryColor3dvEXT\"))\n\tgpSecondaryColor3f = (C.GPSECONDARYCOLOR3F)(getProcAddr(\"glSecondaryColor3f\"))\n\tif gpSecondaryColor3f == nil {\n\t\treturn errors.New(\"glSecondaryColor3f\")\n\t}\n\tgpSecondaryColor3fEXT = (C.GPSECONDARYCOLOR3FEXT)(getProcAddr(\"glSecondaryColor3fEXT\"))\n\tgpSecondaryColor3fv = (C.GPSECONDARYCOLOR3FV)(getProcAddr(\"glSecondaryColor3fv\"))\n\tif gpSecondaryColor3fv == nil {\n\t\treturn errors.New(\"glSecondaryColor3fv\")\n\t}\n\tgpSecondaryColor3fvEXT = (C.GPSECONDARYCOLOR3FVEXT)(getProcAddr(\"glSecondaryColor3fvEXT\"))\n\tgpSecondaryColor3hNV = (C.GPSECONDARYCOLOR3HNV)(getProcAddr(\"glSecondaryColor3hNV\"))\n\tgpSecondaryColor3hvNV = (C.GPSECONDARYCOLOR3HVNV)(getProcAddr(\"glSecondaryColor3hvNV\"))\n\tgpSecondaryColor3i = (C.GPSECONDARYCOLOR3I)(getProcAddr(\"glSecondaryColor3i\"))\n\tif gpSecondaryColor3i == nil {\n\t\treturn errors.New(\"glSecondaryColor3i\")\n\t}\n\tgpSecondaryColor3iEXT = (C.GPSECONDARYCOLOR3IEXT)(getProcAddr(\"glSecondaryColor3iEXT\"))\n\tgpSecondaryColor3iv = (C.GPSECONDARYCOLOR3IV)(getProcAddr(\"glSecondaryColor3iv\"))\n\tif gpSecondaryColor3iv == nil {\n\t\treturn errors.New(\"glSecondaryColor3iv\")\n\t}\n\tgpSecondaryColor3ivEXT = (C.GPSECONDARYCOLOR3IVEXT)(getProcAddr(\"glSecondaryColor3ivEXT\"))\n\tgpSecondaryColor3s = (C.GPSECONDARYCOLOR3S)(getProcAddr(\"glSecondaryColor3s\"))\n\tif gpSecondaryColor3s == nil {\n\t\treturn errors.New(\"glSecondaryColor3s\")\n\t}\n\tgpSecondaryColor3sEXT = (C.GPSECONDARYCOLOR3SEXT)(getProcAddr(\"glSecondaryColor3sEXT\"))\n\tgpSecondaryColor3sv = (C.GPSECONDARYCOLOR3SV)(getProcAddr(\"glSecondaryColor3sv\"))\n\tif gpSecondaryColor3sv == nil {\n\t\treturn errors.New(\"glSecondaryColor3sv\")\n\t}\n\tgpSecondaryColor3svEXT = (C.GPSECONDARYCOLOR3SVEXT)(getProcAddr(\"glSecondaryColor3svEXT\"))\n\tgpSecondaryColor3ub = (C.GPSECONDARYCOLOR3UB)(getProcAddr(\"glSecondaryColor3ub\"))\n\tif gpSecondaryColor3ub == nil {\n\t\treturn errors.New(\"glSecondaryColor3ub\")\n\t}\n\tgpSecondaryColor3ubEXT = (C.GPSECONDARYCOLOR3UBEXT)(getProcAddr(\"glSecondaryColor3ubEXT\"))\n\tgpSecondaryColor3ubv = (C.GPSECONDARYCOLOR3UBV)(getProcAddr(\"glSecondaryColor3ubv\"))\n\tif gpSecondaryColor3ubv == nil {\n\t\treturn errors.New(\"glSecondaryColor3ubv\")\n\t}\n\tgpSecondaryColor3ubvEXT = (C.GPSECONDARYCOLOR3UBVEXT)(getProcAddr(\"glSecondaryColor3ubvEXT\"))\n\tgpSecondaryColor3ui = (C.GPSECONDARYCOLOR3UI)(getProcAddr(\"glSecondaryColor3ui\"))\n\tif gpSecondaryColor3ui == nil {\n\t\treturn errors.New(\"glSecondaryColor3ui\")\n\t}\n\tgpSecondaryColor3uiEXT = (C.GPSECONDARYCOLOR3UIEXT)(getProcAddr(\"glSecondaryColor3uiEXT\"))\n\tgpSecondaryColor3uiv = (C.GPSECONDARYCOLOR3UIV)(getProcAddr(\"glSecondaryColor3uiv\"))\n\tif gpSecondaryColor3uiv == nil {\n\t\treturn errors.New(\"glSecondaryColor3uiv\")\n\t}\n\tgpSecondaryColor3uivEXT = (C.GPSECONDARYCOLOR3UIVEXT)(getProcAddr(\"glSecondaryColor3uivEXT\"))\n\tgpSecondaryColor3us = (C.GPSECONDARYCOLOR3US)(getProcAddr(\"glSecondaryColor3us\"))\n\tif gpSecondaryColor3us == nil {\n\t\treturn errors.New(\"glSecondaryColor3us\")\n\t}\n\tgpSecondaryColor3usEXT = (C.GPSECONDARYCOLOR3USEXT)(getProcAddr(\"glSecondaryColor3usEXT\"))\n\tgpSecondaryColor3usv = (C.GPSECONDARYCOLOR3USV)(getProcAddr(\"glSecondaryColor3usv\"))\n\tif gpSecondaryColor3usv == nil {\n\t\treturn errors.New(\"glSecondaryColor3usv\")\n\t}\n\tgpSecondaryColor3usvEXT = (C.GPSECONDARYCOLOR3USVEXT)(getProcAddr(\"glSecondaryColor3usvEXT\"))\n\tgpSecondaryColorFormatNV = (C.GPSECONDARYCOLORFORMATNV)(getProcAddr(\"glSecondaryColorFormatNV\"))\n\tgpSecondaryColorP3ui = (C.GPSECONDARYCOLORP3UI)(getProcAddr(\"glSecondaryColorP3ui\"))\n\tif gpSecondaryColorP3ui == nil {\n\t\treturn errors.New(\"glSecondaryColorP3ui\")\n\t}\n\tgpSecondaryColorP3uiv = (C.GPSECONDARYCOLORP3UIV)(getProcAddr(\"glSecondaryColorP3uiv\"))\n\tif gpSecondaryColorP3uiv == nil {\n\t\treturn errors.New(\"glSecondaryColorP3uiv\")\n\t}\n\tgpSecondaryColorPointer = (C.GPSECONDARYCOLORPOINTER)(getProcAddr(\"glSecondaryColorPointer\"))\n\tif gpSecondaryColorPointer == nil {\n\t\treturn errors.New(\"glSecondaryColorPointer\")\n\t}\n\tgpSecondaryColorPointerEXT = (C.GPSECONDARYCOLORPOINTEREXT)(getProcAddr(\"glSecondaryColorPointerEXT\"))\n\tgpSecondaryColorPointerListIBM = (C.GPSECONDARYCOLORPOINTERLISTIBM)(getProcAddr(\"glSecondaryColorPointerListIBM\"))\n\tgpSelectBuffer = (C.GPSELECTBUFFER)(getProcAddr(\"glSelectBuffer\"))\n\tif gpSelectBuffer == nil {\n\t\treturn errors.New(\"glSelectBuffer\")\n\t}\n\tgpSelectPerfMonitorCountersAMD = (C.GPSELECTPERFMONITORCOUNTERSAMD)(getProcAddr(\"glSelectPerfMonitorCountersAMD\"))\n\tgpSemaphoreParameterivNV = (C.GPSEMAPHOREPARAMETERIVNV)(getProcAddr(\"glSemaphoreParameterivNV\"))\n\tgpSemaphoreParameterui64vEXT = (C.GPSEMAPHOREPARAMETERUI64VEXT)(getProcAddr(\"glSemaphoreParameterui64vEXT\"))\n\tgpSeparableFilter2D = (C.GPSEPARABLEFILTER2D)(getProcAddr(\"glSeparableFilter2D\"))\n\tgpSeparableFilter2DEXT = (C.GPSEPARABLEFILTER2DEXT)(getProcAddr(\"glSeparableFilter2DEXT\"))\n\tgpSetFenceAPPLE = (C.GPSETFENCEAPPLE)(getProcAddr(\"glSetFenceAPPLE\"))\n\tgpSetFenceNV = (C.GPSETFENCENV)(getProcAddr(\"glSetFenceNV\"))\n\tgpSetFragmentShaderConstantATI = (C.GPSETFRAGMENTSHADERCONSTANTATI)(getProcAddr(\"glSetFragmentShaderConstantATI\"))\n\tgpSetInvariantEXT = (C.GPSETINVARIANTEXT)(getProcAddr(\"glSetInvariantEXT\"))\n\tgpSetLocalConstantEXT = (C.GPSETLOCALCONSTANTEXT)(getProcAddr(\"glSetLocalConstantEXT\"))\n\tgpSetMultisamplefvAMD = (C.GPSETMULTISAMPLEFVAMD)(getProcAddr(\"glSetMultisamplefvAMD\"))\n\tgpShadeModel = (C.GPSHADEMODEL)(getProcAddr(\"glShadeModel\"))\n\tif gpShadeModel == nil {\n\t\treturn errors.New(\"glShadeModel\")\n\t}\n\tgpShaderBinary = (C.GPSHADERBINARY)(getProcAddr(\"glShaderBinary\"))\n\tif gpShaderBinary == nil {\n\t\treturn errors.New(\"glShaderBinary\")\n\t}\n\tgpShaderOp1EXT = (C.GPSHADEROP1EXT)(getProcAddr(\"glShaderOp1EXT\"))\n\tgpShaderOp2EXT = (C.GPSHADEROP2EXT)(getProcAddr(\"glShaderOp2EXT\"))\n\tgpShaderOp3EXT = (C.GPSHADEROP3EXT)(getProcAddr(\"glShaderOp3EXT\"))\n\tgpShaderSource = (C.GPSHADERSOURCE)(getProcAddr(\"glShaderSource\"))\n\tif gpShaderSource == nil {\n\t\treturn errors.New(\"glShaderSource\")\n\t}\n\tgpShaderSourceARB = (C.GPSHADERSOURCEARB)(getProcAddr(\"glShaderSourceARB\"))\n\tgpShaderStorageBlockBinding = (C.GPSHADERSTORAGEBLOCKBINDING)(getProcAddr(\"glShaderStorageBlockBinding\"))\n\tif gpShaderStorageBlockBinding == nil {\n\t\treturn errors.New(\"glShaderStorageBlockBinding\")\n\t}\n\tgpShadingRateImageBarrierNV = (C.GPSHADINGRATEIMAGEBARRIERNV)(getProcAddr(\"glShadingRateImageBarrierNV\"))\n\tgpShadingRateImagePaletteNV = (C.GPSHADINGRATEIMAGEPALETTENV)(getProcAddr(\"glShadingRateImagePaletteNV\"))\n\tgpShadingRateSampleOrderCustomNV = (C.GPSHADINGRATESAMPLEORDERCUSTOMNV)(getProcAddr(\"glShadingRateSampleOrderCustomNV\"))\n\tgpShadingRateSampleOrderNV = (C.GPSHADINGRATESAMPLEORDERNV)(getProcAddr(\"glShadingRateSampleOrderNV\"))\n\tgpSharpenTexFuncSGIS = (C.GPSHARPENTEXFUNCSGIS)(getProcAddr(\"glSharpenTexFuncSGIS\"))\n\tgpSignalSemaphoreEXT = (C.GPSIGNALSEMAPHOREEXT)(getProcAddr(\"glSignalSemaphoreEXT\"))\n\tgpSignalSemaphoreui64NVX = (C.GPSIGNALSEMAPHOREUI64NVX)(getProcAddr(\"glSignalSemaphoreui64NVX\"))\n\tgpSignalVkFenceNV = (C.GPSIGNALVKFENCENV)(getProcAddr(\"glSignalVkFenceNV\"))\n\tgpSignalVkSemaphoreNV = (C.GPSIGNALVKSEMAPHORENV)(getProcAddr(\"glSignalVkSemaphoreNV\"))\n\tgpSpecializeShaderARB = (C.GPSPECIALIZESHADERARB)(getProcAddr(\"glSpecializeShaderARB\"))\n\tgpSpriteParameterfSGIX = (C.GPSPRITEPARAMETERFSGIX)(getProcAddr(\"glSpriteParameterfSGIX\"))\n\tgpSpriteParameterfvSGIX = (C.GPSPRITEPARAMETERFVSGIX)(getProcAddr(\"glSpriteParameterfvSGIX\"))\n\tgpSpriteParameteriSGIX = (C.GPSPRITEPARAMETERISGIX)(getProcAddr(\"glSpriteParameteriSGIX\"))\n\tgpSpriteParameterivSGIX = (C.GPSPRITEPARAMETERIVSGIX)(getProcAddr(\"glSpriteParameterivSGIX\"))\n\tgpStartInstrumentsSGIX = (C.GPSTARTINSTRUMENTSSGIX)(getProcAddr(\"glStartInstrumentsSGIX\"))\n\tgpStateCaptureNV = (C.GPSTATECAPTURENV)(getProcAddr(\"glStateCaptureNV\"))\n\tgpStencilClearTagEXT = (C.GPSTENCILCLEARTAGEXT)(getProcAddr(\"glStencilClearTagEXT\"))\n\tgpStencilFillPathInstancedNV = (C.GPSTENCILFILLPATHINSTANCEDNV)(getProcAddr(\"glStencilFillPathInstancedNV\"))\n\tgpStencilFillPathNV = (C.GPSTENCILFILLPATHNV)(getProcAddr(\"glStencilFillPathNV\"))\n\tgpStencilFunc = (C.GPSTENCILFUNC)(getProcAddr(\"glStencilFunc\"))\n\tif gpStencilFunc == nil {\n\t\treturn errors.New(\"glStencilFunc\")\n\t}\n\tgpStencilFuncSeparate = (C.GPSTENCILFUNCSEPARATE)(getProcAddr(\"glStencilFuncSeparate\"))\n\tif gpStencilFuncSeparate == nil {\n\t\treturn errors.New(\"glStencilFuncSeparate\")\n\t}\n\tgpStencilFuncSeparateATI = (C.GPSTENCILFUNCSEPARATEATI)(getProcAddr(\"glStencilFuncSeparateATI\"))\n\tgpStencilMask = (C.GPSTENCILMASK)(getProcAddr(\"glStencilMask\"))\n\tif gpStencilMask == nil {\n\t\treturn errors.New(\"glStencilMask\")\n\t}\n\tgpStencilMaskSeparate = (C.GPSTENCILMASKSEPARATE)(getProcAddr(\"glStencilMaskSeparate\"))\n\tif gpStencilMaskSeparate == nil {\n\t\treturn errors.New(\"glStencilMaskSeparate\")\n\t}\n\tgpStencilOp = (C.GPSTENCILOP)(getProcAddr(\"glStencilOp\"))\n\tif gpStencilOp == nil {\n\t\treturn errors.New(\"glStencilOp\")\n\t}\n\tgpStencilOpSeparate = (C.GPSTENCILOPSEPARATE)(getProcAddr(\"glStencilOpSeparate\"))\n\tif gpStencilOpSeparate == nil {\n\t\treturn errors.New(\"glStencilOpSeparate\")\n\t}\n\tgpStencilOpSeparateATI = (C.GPSTENCILOPSEPARATEATI)(getProcAddr(\"glStencilOpSeparateATI\"))\n\tgpStencilOpValueAMD = (C.GPSTENCILOPVALUEAMD)(getProcAddr(\"glStencilOpValueAMD\"))\n\tgpStencilStrokePathInstancedNV = (C.GPSTENCILSTROKEPATHINSTANCEDNV)(getProcAddr(\"glStencilStrokePathInstancedNV\"))\n\tgpStencilStrokePathNV = (C.GPSTENCILSTROKEPATHNV)(getProcAddr(\"glStencilStrokePathNV\"))\n\tgpStencilThenCoverFillPathInstancedNV = (C.GPSTENCILTHENCOVERFILLPATHINSTANCEDNV)(getProcAddr(\"glStencilThenCoverFillPathInstancedNV\"))\n\tgpStencilThenCoverFillPathNV = (C.GPSTENCILTHENCOVERFILLPATHNV)(getProcAddr(\"glStencilThenCoverFillPathNV\"))\n\tgpStencilThenCoverStrokePathInstancedNV = (C.GPSTENCILTHENCOVERSTROKEPATHINSTANCEDNV)(getProcAddr(\"glStencilThenCoverStrokePathInstancedNV\"))\n\tgpStencilThenCoverStrokePathNV = (C.GPSTENCILTHENCOVERSTROKEPATHNV)(getProcAddr(\"glStencilThenCoverStrokePathNV\"))\n\tgpStopInstrumentsSGIX = (C.GPSTOPINSTRUMENTSSGIX)(getProcAddr(\"glStopInstrumentsSGIX\"))\n\tgpStringMarkerGREMEDY = (C.GPSTRINGMARKERGREMEDY)(getProcAddr(\"glStringMarkerGREMEDY\"))\n\tgpSubpixelPrecisionBiasNV = (C.GPSUBPIXELPRECISIONBIASNV)(getProcAddr(\"glSubpixelPrecisionBiasNV\"))\n\tgpSwizzleEXT = (C.GPSWIZZLEEXT)(getProcAddr(\"glSwizzleEXT\"))\n\tgpSyncTextureINTEL = (C.GPSYNCTEXTUREINTEL)(getProcAddr(\"glSyncTextureINTEL\"))\n\tgpTagSampleBufferSGIX = (C.GPTAGSAMPLEBUFFERSGIX)(getProcAddr(\"glTagSampleBufferSGIX\"))\n\tgpTangent3bEXT = (C.GPTANGENT3BEXT)(getProcAddr(\"glTangent3bEXT\"))\n\tgpTangent3bvEXT = (C.GPTANGENT3BVEXT)(getProcAddr(\"glTangent3bvEXT\"))\n\tgpTangent3dEXT = (C.GPTANGENT3DEXT)(getProcAddr(\"glTangent3dEXT\"))\n\tgpTangent3dvEXT = (C.GPTANGENT3DVEXT)(getProcAddr(\"glTangent3dvEXT\"))\n\tgpTangent3fEXT = (C.GPTANGENT3FEXT)(getProcAddr(\"glTangent3fEXT\"))\n\tgpTangent3fvEXT = (C.GPTANGENT3FVEXT)(getProcAddr(\"glTangent3fvEXT\"))\n\tgpTangent3iEXT = (C.GPTANGENT3IEXT)(getProcAddr(\"glTangent3iEXT\"))\n\tgpTangent3ivEXT = (C.GPTANGENT3IVEXT)(getProcAddr(\"glTangent3ivEXT\"))\n\tgpTangent3sEXT = (C.GPTANGENT3SEXT)(getProcAddr(\"glTangent3sEXT\"))\n\tgpTangent3svEXT = (C.GPTANGENT3SVEXT)(getProcAddr(\"glTangent3svEXT\"))\n\tgpTangentPointerEXT = (C.GPTANGENTPOINTEREXT)(getProcAddr(\"glTangentPointerEXT\"))\n\tgpTbufferMask3DFX = (C.GPTBUFFERMASK3DFX)(getProcAddr(\"glTbufferMask3DFX\"))\n\tgpTessellationFactorAMD = (C.GPTESSELLATIONFACTORAMD)(getProcAddr(\"glTessellationFactorAMD\"))\n\tgpTessellationModeAMD = (C.GPTESSELLATIONMODEAMD)(getProcAddr(\"glTessellationModeAMD\"))\n\tgpTestFenceAPPLE = (C.GPTESTFENCEAPPLE)(getProcAddr(\"glTestFenceAPPLE\"))\n\tgpTestFenceNV = (C.GPTESTFENCENV)(getProcAddr(\"glTestFenceNV\"))\n\tgpTestObjectAPPLE = (C.GPTESTOBJECTAPPLE)(getProcAddr(\"glTestObjectAPPLE\"))\n\tgpTexAttachMemoryNV = (C.GPTEXATTACHMEMORYNV)(getProcAddr(\"glTexAttachMemoryNV\"))\n\tgpTexBuffer = (C.GPTEXBUFFER)(getProcAddr(\"glTexBuffer\"))\n\tif gpTexBuffer == nil {\n\t\treturn errors.New(\"glTexBuffer\")\n\t}\n\tgpTexBufferARB = (C.GPTEXBUFFERARB)(getProcAddr(\"glTexBufferARB\"))\n\tgpTexBufferEXT = (C.GPTEXBUFFEREXT)(getProcAddr(\"glTexBufferEXT\"))\n\tgpTexBufferRange = (C.GPTEXBUFFERRANGE)(getProcAddr(\"glTexBufferRange\"))\n\tif gpTexBufferRange == nil {\n\t\treturn errors.New(\"glTexBufferRange\")\n\t}\n\tgpTexBumpParameterfvATI = (C.GPTEXBUMPPARAMETERFVATI)(getProcAddr(\"glTexBumpParameterfvATI\"))\n\tgpTexBumpParameterivATI = (C.GPTEXBUMPPARAMETERIVATI)(getProcAddr(\"glTexBumpParameterivATI\"))\n\tgpTexCoord1bOES = (C.GPTEXCOORD1BOES)(getProcAddr(\"glTexCoord1bOES\"))\n\tgpTexCoord1bvOES = (C.GPTEXCOORD1BVOES)(getProcAddr(\"glTexCoord1bvOES\"))\n\tgpTexCoord1d = (C.GPTEXCOORD1D)(getProcAddr(\"glTexCoord1d\"))\n\tif gpTexCoord1d == nil {\n\t\treturn errors.New(\"glTexCoord1d\")\n\t}\n\tgpTexCoord1dv = (C.GPTEXCOORD1DV)(getProcAddr(\"glTexCoord1dv\"))\n\tif gpTexCoord1dv == nil {\n\t\treturn errors.New(\"glTexCoord1dv\")\n\t}\n\tgpTexCoord1f = (C.GPTEXCOORD1F)(getProcAddr(\"glTexCoord1f\"))\n\tif gpTexCoord1f == nil {\n\t\treturn errors.New(\"glTexCoord1f\")\n\t}\n\tgpTexCoord1fv = (C.GPTEXCOORD1FV)(getProcAddr(\"glTexCoord1fv\"))\n\tif gpTexCoord1fv == nil {\n\t\treturn errors.New(\"glTexCoord1fv\")\n\t}\n\tgpTexCoord1hNV = (C.GPTEXCOORD1HNV)(getProcAddr(\"glTexCoord1hNV\"))\n\tgpTexCoord1hvNV = (C.GPTEXCOORD1HVNV)(getProcAddr(\"glTexCoord1hvNV\"))\n\tgpTexCoord1i = (C.GPTEXCOORD1I)(getProcAddr(\"glTexCoord1i\"))\n\tif gpTexCoord1i == nil {\n\t\treturn errors.New(\"glTexCoord1i\")\n\t}\n\tgpTexCoord1iv = (C.GPTEXCOORD1IV)(getProcAddr(\"glTexCoord1iv\"))\n\tif gpTexCoord1iv == nil {\n\t\treturn errors.New(\"glTexCoord1iv\")\n\t}\n\tgpTexCoord1s = (C.GPTEXCOORD1S)(getProcAddr(\"glTexCoord1s\"))\n\tif gpTexCoord1s == nil {\n\t\treturn errors.New(\"glTexCoord1s\")\n\t}\n\tgpTexCoord1sv = (C.GPTEXCOORD1SV)(getProcAddr(\"glTexCoord1sv\"))\n\tif gpTexCoord1sv == nil {\n\t\treturn errors.New(\"glTexCoord1sv\")\n\t}\n\tgpTexCoord1xOES = (C.GPTEXCOORD1XOES)(getProcAddr(\"glTexCoord1xOES\"))\n\tgpTexCoord1xvOES = (C.GPTEXCOORD1XVOES)(getProcAddr(\"glTexCoord1xvOES\"))\n\tgpTexCoord2bOES = (C.GPTEXCOORD2BOES)(getProcAddr(\"glTexCoord2bOES\"))\n\tgpTexCoord2bvOES = (C.GPTEXCOORD2BVOES)(getProcAddr(\"glTexCoord2bvOES\"))\n\tgpTexCoord2d = (C.GPTEXCOORD2D)(getProcAddr(\"glTexCoord2d\"))\n\tif gpTexCoord2d == nil {\n\t\treturn errors.New(\"glTexCoord2d\")\n\t}\n\tgpTexCoord2dv = (C.GPTEXCOORD2DV)(getProcAddr(\"glTexCoord2dv\"))\n\tif gpTexCoord2dv == nil {\n\t\treturn errors.New(\"glTexCoord2dv\")\n\t}\n\tgpTexCoord2f = (C.GPTEXCOORD2F)(getProcAddr(\"glTexCoord2f\"))\n\tif gpTexCoord2f == nil {\n\t\treturn errors.New(\"glTexCoord2f\")\n\t}\n\tgpTexCoord2fColor3fVertex3fSUN = (C.GPTEXCOORD2FCOLOR3FVERTEX3FSUN)(getProcAddr(\"glTexCoord2fColor3fVertex3fSUN\"))\n\tgpTexCoord2fColor3fVertex3fvSUN = (C.GPTEXCOORD2FCOLOR3FVERTEX3FVSUN)(getProcAddr(\"glTexCoord2fColor3fVertex3fvSUN\"))\n\tgpTexCoord2fColor4fNormal3fVertex3fSUN = (C.GPTEXCOORD2FCOLOR4FNORMAL3FVERTEX3FSUN)(getProcAddr(\"glTexCoord2fColor4fNormal3fVertex3fSUN\"))\n\tgpTexCoord2fColor4fNormal3fVertex3fvSUN = (C.GPTEXCOORD2FCOLOR4FNORMAL3FVERTEX3FVSUN)(getProcAddr(\"glTexCoord2fColor4fNormal3fVertex3fvSUN\"))\n\tgpTexCoord2fColor4ubVertex3fSUN = (C.GPTEXCOORD2FCOLOR4UBVERTEX3FSUN)(getProcAddr(\"glTexCoord2fColor4ubVertex3fSUN\"))\n\tgpTexCoord2fColor4ubVertex3fvSUN = (C.GPTEXCOORD2FCOLOR4UBVERTEX3FVSUN)(getProcAddr(\"glTexCoord2fColor4ubVertex3fvSUN\"))\n\tgpTexCoord2fNormal3fVertex3fSUN = (C.GPTEXCOORD2FNORMAL3FVERTEX3FSUN)(getProcAddr(\"glTexCoord2fNormal3fVertex3fSUN\"))\n\tgpTexCoord2fNormal3fVertex3fvSUN = (C.GPTEXCOORD2FNORMAL3FVERTEX3FVSUN)(getProcAddr(\"glTexCoord2fNormal3fVertex3fvSUN\"))\n\tgpTexCoord2fVertex3fSUN = (C.GPTEXCOORD2FVERTEX3FSUN)(getProcAddr(\"glTexCoord2fVertex3fSUN\"))\n\tgpTexCoord2fVertex3fvSUN = (C.GPTEXCOORD2FVERTEX3FVSUN)(getProcAddr(\"glTexCoord2fVertex3fvSUN\"))\n\tgpTexCoord2fv = (C.GPTEXCOORD2FV)(getProcAddr(\"glTexCoord2fv\"))\n\tif gpTexCoord2fv == nil {\n\t\treturn errors.New(\"glTexCoord2fv\")\n\t}\n\tgpTexCoord2hNV = (C.GPTEXCOORD2HNV)(getProcAddr(\"glTexCoord2hNV\"))\n\tgpTexCoord2hvNV = (C.GPTEXCOORD2HVNV)(getProcAddr(\"glTexCoord2hvNV\"))\n\tgpTexCoord2i = (C.GPTEXCOORD2I)(getProcAddr(\"glTexCoord2i\"))\n\tif gpTexCoord2i == nil {\n\t\treturn errors.New(\"glTexCoord2i\")\n\t}\n\tgpTexCoord2iv = (C.GPTEXCOORD2IV)(getProcAddr(\"glTexCoord2iv\"))\n\tif gpTexCoord2iv == nil {\n\t\treturn errors.New(\"glTexCoord2iv\")\n\t}\n\tgpTexCoord2s = (C.GPTEXCOORD2S)(getProcAddr(\"glTexCoord2s\"))\n\tif gpTexCoord2s == nil {\n\t\treturn errors.New(\"glTexCoord2s\")\n\t}\n\tgpTexCoord2sv = (C.GPTEXCOORD2SV)(getProcAddr(\"glTexCoord2sv\"))\n\tif gpTexCoord2sv == nil {\n\t\treturn errors.New(\"glTexCoord2sv\")\n\t}\n\tgpTexCoord2xOES = (C.GPTEXCOORD2XOES)(getProcAddr(\"glTexCoord2xOES\"))\n\tgpTexCoord2xvOES = (C.GPTEXCOORD2XVOES)(getProcAddr(\"glTexCoord2xvOES\"))\n\tgpTexCoord3bOES = (C.GPTEXCOORD3BOES)(getProcAddr(\"glTexCoord3bOES\"))\n\tgpTexCoord3bvOES = (C.GPTEXCOORD3BVOES)(getProcAddr(\"glTexCoord3bvOES\"))\n\tgpTexCoord3d = (C.GPTEXCOORD3D)(getProcAddr(\"glTexCoord3d\"))\n\tif gpTexCoord3d == nil {\n\t\treturn errors.New(\"glTexCoord3d\")\n\t}\n\tgpTexCoord3dv = (C.GPTEXCOORD3DV)(getProcAddr(\"glTexCoord3dv\"))\n\tif gpTexCoord3dv == nil {\n\t\treturn errors.New(\"glTexCoord3dv\")\n\t}\n\tgpTexCoord3f = (C.GPTEXCOORD3F)(getProcAddr(\"glTexCoord3f\"))\n\tif gpTexCoord3f == nil {\n\t\treturn errors.New(\"glTexCoord3f\")\n\t}\n\tgpTexCoord3fv = (C.GPTEXCOORD3FV)(getProcAddr(\"glTexCoord3fv\"))\n\tif gpTexCoord3fv == nil {\n\t\treturn errors.New(\"glTexCoord3fv\")\n\t}\n\tgpTexCoord3hNV = (C.GPTEXCOORD3HNV)(getProcAddr(\"glTexCoord3hNV\"))\n\tgpTexCoord3hvNV = (C.GPTEXCOORD3HVNV)(getProcAddr(\"glTexCoord3hvNV\"))\n\tgpTexCoord3i = (C.GPTEXCOORD3I)(getProcAddr(\"glTexCoord3i\"))\n\tif gpTexCoord3i == nil {\n\t\treturn errors.New(\"glTexCoord3i\")\n\t}\n\tgpTexCoord3iv = (C.GPTEXCOORD3IV)(getProcAddr(\"glTexCoord3iv\"))\n\tif gpTexCoord3iv == nil {\n\t\treturn errors.New(\"glTexCoord3iv\")\n\t}\n\tgpTexCoord3s = (C.GPTEXCOORD3S)(getProcAddr(\"glTexCoord3s\"))\n\tif gpTexCoord3s == nil {\n\t\treturn errors.New(\"glTexCoord3s\")\n\t}\n\tgpTexCoord3sv = (C.GPTEXCOORD3SV)(getProcAddr(\"glTexCoord3sv\"))\n\tif gpTexCoord3sv == nil {\n\t\treturn errors.New(\"glTexCoord3sv\")\n\t}\n\tgpTexCoord3xOES = (C.GPTEXCOORD3XOES)(getProcAddr(\"glTexCoord3xOES\"))\n\tgpTexCoord3xvOES = (C.GPTEXCOORD3XVOES)(getProcAddr(\"glTexCoord3xvOES\"))\n\tgpTexCoord4bOES = (C.GPTEXCOORD4BOES)(getProcAddr(\"glTexCoord4bOES\"))\n\tgpTexCoord4bvOES = (C.GPTEXCOORD4BVOES)(getProcAddr(\"glTexCoord4bvOES\"))\n\tgpTexCoord4d = (C.GPTEXCOORD4D)(getProcAddr(\"glTexCoord4d\"))\n\tif gpTexCoord4d == nil {\n\t\treturn errors.New(\"glTexCoord4d\")\n\t}\n\tgpTexCoord4dv = (C.GPTEXCOORD4DV)(getProcAddr(\"glTexCoord4dv\"))\n\tif gpTexCoord4dv == nil {\n\t\treturn errors.New(\"glTexCoord4dv\")\n\t}\n\tgpTexCoord4f = (C.GPTEXCOORD4F)(getProcAddr(\"glTexCoord4f\"))\n\tif gpTexCoord4f == nil {\n\t\treturn errors.New(\"glTexCoord4f\")\n\t}\n\tgpTexCoord4fColor4fNormal3fVertex4fSUN = (C.GPTEXCOORD4FCOLOR4FNORMAL3FVERTEX4FSUN)(getProcAddr(\"glTexCoord4fColor4fNormal3fVertex4fSUN\"))\n\tgpTexCoord4fColor4fNormal3fVertex4fvSUN = (C.GPTEXCOORD4FCOLOR4FNORMAL3FVERTEX4FVSUN)(getProcAddr(\"glTexCoord4fColor4fNormal3fVertex4fvSUN\"))\n\tgpTexCoord4fVertex4fSUN = (C.GPTEXCOORD4FVERTEX4FSUN)(getProcAddr(\"glTexCoord4fVertex4fSUN\"))\n\tgpTexCoord4fVertex4fvSUN = (C.GPTEXCOORD4FVERTEX4FVSUN)(getProcAddr(\"glTexCoord4fVertex4fvSUN\"))\n\tgpTexCoord4fv = (C.GPTEXCOORD4FV)(getProcAddr(\"glTexCoord4fv\"))\n\tif gpTexCoord4fv == nil {\n\t\treturn errors.New(\"glTexCoord4fv\")\n\t}\n\tgpTexCoord4hNV = (C.GPTEXCOORD4HNV)(getProcAddr(\"glTexCoord4hNV\"))\n\tgpTexCoord4hvNV = (C.GPTEXCOORD4HVNV)(getProcAddr(\"glTexCoord4hvNV\"))\n\tgpTexCoord4i = (C.GPTEXCOORD4I)(getProcAddr(\"glTexCoord4i\"))\n\tif gpTexCoord4i == nil {\n\t\treturn errors.New(\"glTexCoord4i\")\n\t}\n\tgpTexCoord4iv = (C.GPTEXCOORD4IV)(getProcAddr(\"glTexCoord4iv\"))\n\tif gpTexCoord4iv == nil {\n\t\treturn errors.New(\"glTexCoord4iv\")\n\t}\n\tgpTexCoord4s = (C.GPTEXCOORD4S)(getProcAddr(\"glTexCoord4s\"))\n\tif gpTexCoord4s == nil {\n\t\treturn errors.New(\"glTexCoord4s\")\n\t}\n\tgpTexCoord4sv = (C.GPTEXCOORD4SV)(getProcAddr(\"glTexCoord4sv\"))\n\tif gpTexCoord4sv == nil {\n\t\treturn errors.New(\"glTexCoord4sv\")\n\t}\n\tgpTexCoord4xOES = (C.GPTEXCOORD4XOES)(getProcAddr(\"glTexCoord4xOES\"))\n\tgpTexCoord4xvOES = (C.GPTEXCOORD4XVOES)(getProcAddr(\"glTexCoord4xvOES\"))\n\tgpTexCoordFormatNV = (C.GPTEXCOORDFORMATNV)(getProcAddr(\"glTexCoordFormatNV\"))\n\tgpTexCoordP1ui = (C.GPTEXCOORDP1UI)(getProcAddr(\"glTexCoordP1ui\"))\n\tif gpTexCoordP1ui == nil {\n\t\treturn errors.New(\"glTexCoordP1ui\")\n\t}\n\tgpTexCoordP1uiv = (C.GPTEXCOORDP1UIV)(getProcAddr(\"glTexCoordP1uiv\"))\n\tif gpTexCoordP1uiv == nil {\n\t\treturn errors.New(\"glTexCoordP1uiv\")\n\t}\n\tgpTexCoordP2ui = (C.GPTEXCOORDP2UI)(getProcAddr(\"glTexCoordP2ui\"))\n\tif gpTexCoordP2ui == nil {\n\t\treturn errors.New(\"glTexCoordP2ui\")\n\t}\n\tgpTexCoordP2uiv = (C.GPTEXCOORDP2UIV)(getProcAddr(\"glTexCoordP2uiv\"))\n\tif gpTexCoordP2uiv == nil {\n\t\treturn errors.New(\"glTexCoordP2uiv\")\n\t}\n\tgpTexCoordP3ui = (C.GPTEXCOORDP3UI)(getProcAddr(\"glTexCoordP3ui\"))\n\tif gpTexCoordP3ui == nil {\n\t\treturn errors.New(\"glTexCoordP3ui\")\n\t}\n\tgpTexCoordP3uiv = (C.GPTEXCOORDP3UIV)(getProcAddr(\"glTexCoordP3uiv\"))\n\tif gpTexCoordP3uiv == nil {\n\t\treturn errors.New(\"glTexCoordP3uiv\")\n\t}\n\tgpTexCoordP4ui = (C.GPTEXCOORDP4UI)(getProcAddr(\"glTexCoordP4ui\"))\n\tif gpTexCoordP4ui == nil {\n\t\treturn errors.New(\"glTexCoordP4ui\")\n\t}\n\tgpTexCoordP4uiv = (C.GPTEXCOORDP4UIV)(getProcAddr(\"glTexCoordP4uiv\"))\n\tif gpTexCoordP4uiv == nil {\n\t\treturn errors.New(\"glTexCoordP4uiv\")\n\t}\n\tgpTexCoordPointer = (C.GPTEXCOORDPOINTER)(getProcAddr(\"glTexCoordPointer\"))\n\tif gpTexCoordPointer == nil {\n\t\treturn errors.New(\"glTexCoordPointer\")\n\t}\n\tgpTexCoordPointerEXT = (C.GPTEXCOORDPOINTEREXT)(getProcAddr(\"glTexCoordPointerEXT\"))\n\tgpTexCoordPointerListIBM = (C.GPTEXCOORDPOINTERLISTIBM)(getProcAddr(\"glTexCoordPointerListIBM\"))\n\tgpTexCoordPointervINTEL = (C.GPTEXCOORDPOINTERVINTEL)(getProcAddr(\"glTexCoordPointervINTEL\"))\n\tgpTexEnvf = (C.GPTEXENVF)(getProcAddr(\"glTexEnvf\"))\n\tif gpTexEnvf == nil {\n\t\treturn errors.New(\"glTexEnvf\")\n\t}\n\tgpTexEnvfv = (C.GPTEXENVFV)(getProcAddr(\"glTexEnvfv\"))\n\tif gpTexEnvfv == nil {\n\t\treturn errors.New(\"glTexEnvfv\")\n\t}\n\tgpTexEnvi = (C.GPTEXENVI)(getProcAddr(\"glTexEnvi\"))\n\tif gpTexEnvi == nil {\n\t\treturn errors.New(\"glTexEnvi\")\n\t}\n\tgpTexEnviv = (C.GPTEXENVIV)(getProcAddr(\"glTexEnviv\"))\n\tif gpTexEnviv == nil {\n\t\treturn errors.New(\"glTexEnviv\")\n\t}\n\tgpTexEnvxOES = (C.GPTEXENVXOES)(getProcAddr(\"glTexEnvxOES\"))\n\tgpTexEnvxvOES = (C.GPTEXENVXVOES)(getProcAddr(\"glTexEnvxvOES\"))\n\tgpTexFilterFuncSGIS = (C.GPTEXFILTERFUNCSGIS)(getProcAddr(\"glTexFilterFuncSGIS\"))\n\tgpTexGend = (C.GPTEXGEND)(getProcAddr(\"glTexGend\"))\n\tif gpTexGend == nil {\n\t\treturn errors.New(\"glTexGend\")\n\t}\n\tgpTexGendv = (C.GPTEXGENDV)(getProcAddr(\"glTexGendv\"))\n\tif gpTexGendv == nil {\n\t\treturn errors.New(\"glTexGendv\")\n\t}\n\tgpTexGenf = (C.GPTEXGENF)(getProcAddr(\"glTexGenf\"))\n\tif gpTexGenf == nil {\n\t\treturn errors.New(\"glTexGenf\")\n\t}\n\tgpTexGenfv = (C.GPTEXGENFV)(getProcAddr(\"glTexGenfv\"))\n\tif gpTexGenfv == nil {\n\t\treturn errors.New(\"glTexGenfv\")\n\t}\n\tgpTexGeni = (C.GPTEXGENI)(getProcAddr(\"glTexGeni\"))\n\tif gpTexGeni == nil {\n\t\treturn errors.New(\"glTexGeni\")\n\t}\n\tgpTexGeniv = (C.GPTEXGENIV)(getProcAddr(\"glTexGeniv\"))\n\tif gpTexGeniv == nil {\n\t\treturn errors.New(\"glTexGeniv\")\n\t}\n\tgpTexGenxOES = (C.GPTEXGENXOES)(getProcAddr(\"glTexGenxOES\"))\n\tgpTexGenxvOES = (C.GPTEXGENXVOES)(getProcAddr(\"glTexGenxvOES\"))\n\tgpTexImage1D = (C.GPTEXIMAGE1D)(getProcAddr(\"glTexImage1D\"))\n\tif gpTexImage1D == nil {\n\t\treturn errors.New(\"glTexImage1D\")\n\t}\n\tgpTexImage2D = (C.GPTEXIMAGE2D)(getProcAddr(\"glTexImage2D\"))\n\tif gpTexImage2D == nil {\n\t\treturn errors.New(\"glTexImage2D\")\n\t}\n\tgpTexImage2DMultisample = (C.GPTEXIMAGE2DMULTISAMPLE)(getProcAddr(\"glTexImage2DMultisample\"))\n\tif gpTexImage2DMultisample == nil {\n\t\treturn errors.New(\"glTexImage2DMultisample\")\n\t}\n\tgpTexImage2DMultisampleCoverageNV = (C.GPTEXIMAGE2DMULTISAMPLECOVERAGENV)(getProcAddr(\"glTexImage2DMultisampleCoverageNV\"))\n\tgpTexImage3D = (C.GPTEXIMAGE3D)(getProcAddr(\"glTexImage3D\"))\n\tif gpTexImage3D == nil {\n\t\treturn errors.New(\"glTexImage3D\")\n\t}\n\tgpTexImage3DEXT = (C.GPTEXIMAGE3DEXT)(getProcAddr(\"glTexImage3DEXT\"))\n\tgpTexImage3DMultisample = (C.GPTEXIMAGE3DMULTISAMPLE)(getProcAddr(\"glTexImage3DMultisample\"))\n\tif gpTexImage3DMultisample == nil {\n\t\treturn errors.New(\"glTexImage3DMultisample\")\n\t}\n\tgpTexImage3DMultisampleCoverageNV = (C.GPTEXIMAGE3DMULTISAMPLECOVERAGENV)(getProcAddr(\"glTexImage3DMultisampleCoverageNV\"))\n\tgpTexImage4DSGIS = (C.GPTEXIMAGE4DSGIS)(getProcAddr(\"glTexImage4DSGIS\"))\n\tgpTexPageCommitmentARB = (C.GPTEXPAGECOMMITMENTARB)(getProcAddr(\"glTexPageCommitmentARB\"))\n\tgpTexPageCommitmentMemNV = (C.GPTEXPAGECOMMITMENTMEMNV)(getProcAddr(\"glTexPageCommitmentMemNV\"))\n\tgpTexParameterIiv = (C.GPTEXPARAMETERIIV)(getProcAddr(\"glTexParameterIiv\"))\n\tif gpTexParameterIiv == nil {\n\t\treturn errors.New(\"glTexParameterIiv\")\n\t}\n\tgpTexParameterIivEXT = (C.GPTEXPARAMETERIIVEXT)(getProcAddr(\"glTexParameterIivEXT\"))\n\tgpTexParameterIuiv = (C.GPTEXPARAMETERIUIV)(getProcAddr(\"glTexParameterIuiv\"))\n\tif gpTexParameterIuiv == nil {\n\t\treturn errors.New(\"glTexParameterIuiv\")\n\t}\n\tgpTexParameterIuivEXT = (C.GPTEXPARAMETERIUIVEXT)(getProcAddr(\"glTexParameterIuivEXT\"))\n\tgpTexParameterf = (C.GPTEXPARAMETERF)(getProcAddr(\"glTexParameterf\"))\n\tif gpTexParameterf == nil {\n\t\treturn errors.New(\"glTexParameterf\")\n\t}\n\tgpTexParameterfv = (C.GPTEXPARAMETERFV)(getProcAddr(\"glTexParameterfv\"))\n\tif gpTexParameterfv == nil {\n\t\treturn errors.New(\"glTexParameterfv\")\n\t}\n\tgpTexParameteri = (C.GPTEXPARAMETERI)(getProcAddr(\"glTexParameteri\"))\n\tif gpTexParameteri == nil {\n\t\treturn errors.New(\"glTexParameteri\")\n\t}\n\tgpTexParameteriv = (C.GPTEXPARAMETERIV)(getProcAddr(\"glTexParameteriv\"))\n\tif gpTexParameteriv == nil {\n\t\treturn errors.New(\"glTexParameteriv\")\n\t}\n\tgpTexParameterxOES = (C.GPTEXPARAMETERXOES)(getProcAddr(\"glTexParameterxOES\"))\n\tgpTexParameterxvOES = (C.GPTEXPARAMETERXVOES)(getProcAddr(\"glTexParameterxvOES\"))\n\tgpTexRenderbufferNV = (C.GPTEXRENDERBUFFERNV)(getProcAddr(\"glTexRenderbufferNV\"))\n\tgpTexStorage1D = (C.GPTEXSTORAGE1D)(getProcAddr(\"glTexStorage1D\"))\n\tif gpTexStorage1D == nil {\n\t\treturn errors.New(\"glTexStorage1D\")\n\t}\n\tgpTexStorage2D = (C.GPTEXSTORAGE2D)(getProcAddr(\"glTexStorage2D\"))\n\tif gpTexStorage2D == nil {\n\t\treturn errors.New(\"glTexStorage2D\")\n\t}\n\tgpTexStorage2DMultisample = (C.GPTEXSTORAGE2DMULTISAMPLE)(getProcAddr(\"glTexStorage2DMultisample\"))\n\tif gpTexStorage2DMultisample == nil {\n\t\treturn errors.New(\"glTexStorage2DMultisample\")\n\t}\n\tgpTexStorage3D = (C.GPTEXSTORAGE3D)(getProcAddr(\"glTexStorage3D\"))\n\tif gpTexStorage3D == nil {\n\t\treturn errors.New(\"glTexStorage3D\")\n\t}\n\tgpTexStorage3DMultisample = (C.GPTEXSTORAGE3DMULTISAMPLE)(getProcAddr(\"glTexStorage3DMultisample\"))\n\tif gpTexStorage3DMultisample == nil {\n\t\treturn errors.New(\"glTexStorage3DMultisample\")\n\t}\n\tgpTexStorageMem1DEXT = (C.GPTEXSTORAGEMEM1DEXT)(getProcAddr(\"glTexStorageMem1DEXT\"))\n\tgpTexStorageMem2DEXT = (C.GPTEXSTORAGEMEM2DEXT)(getProcAddr(\"glTexStorageMem2DEXT\"))\n\tgpTexStorageMem2DMultisampleEXT = (C.GPTEXSTORAGEMEM2DMULTISAMPLEEXT)(getProcAddr(\"glTexStorageMem2DMultisampleEXT\"))\n\tgpTexStorageMem3DEXT = (C.GPTEXSTORAGEMEM3DEXT)(getProcAddr(\"glTexStorageMem3DEXT\"))\n\tgpTexStorageMem3DMultisampleEXT = (C.GPTEXSTORAGEMEM3DMULTISAMPLEEXT)(getProcAddr(\"glTexStorageMem3DMultisampleEXT\"))\n\tgpTexStorageSparseAMD = (C.GPTEXSTORAGESPARSEAMD)(getProcAddr(\"glTexStorageSparseAMD\"))\n\tgpTexSubImage1D = (C.GPTEXSUBIMAGE1D)(getProcAddr(\"glTexSubImage1D\"))\n\tif gpTexSubImage1D == nil {\n\t\treturn errors.New(\"glTexSubImage1D\")\n\t}\n\tgpTexSubImage1DEXT = (C.GPTEXSUBIMAGE1DEXT)(getProcAddr(\"glTexSubImage1DEXT\"))\n\tgpTexSubImage2D = (C.GPTEXSUBIMAGE2D)(getProcAddr(\"glTexSubImage2D\"))\n\tif gpTexSubImage2D == nil {\n\t\treturn errors.New(\"glTexSubImage2D\")\n\t}\n\tgpTexSubImage2DEXT = (C.GPTEXSUBIMAGE2DEXT)(getProcAddr(\"glTexSubImage2DEXT\"))\n\tgpTexSubImage3D = (C.GPTEXSUBIMAGE3D)(getProcAddr(\"glTexSubImage3D\"))\n\tif gpTexSubImage3D == nil {\n\t\treturn errors.New(\"glTexSubImage3D\")\n\t}\n\tgpTexSubImage3DEXT = (C.GPTEXSUBIMAGE3DEXT)(getProcAddr(\"glTexSubImage3DEXT\"))\n\tgpTexSubImage4DSGIS = (C.GPTEXSUBIMAGE4DSGIS)(getProcAddr(\"glTexSubImage4DSGIS\"))\n\tgpTextureAttachMemoryNV = (C.GPTEXTUREATTACHMEMORYNV)(getProcAddr(\"glTextureAttachMemoryNV\"))\n\tgpTextureBarrier = (C.GPTEXTUREBARRIER)(getProcAddr(\"glTextureBarrier\"))\n\tgpTextureBarrierNV = (C.GPTEXTUREBARRIERNV)(getProcAddr(\"glTextureBarrierNV\"))\n\tgpTextureBuffer = (C.GPTEXTUREBUFFER)(getProcAddr(\"glTextureBuffer\"))\n\tgpTextureBufferEXT = (C.GPTEXTUREBUFFEREXT)(getProcAddr(\"glTextureBufferEXT\"))\n\tgpTextureBufferRange = (C.GPTEXTUREBUFFERRANGE)(getProcAddr(\"glTextureBufferRange\"))\n\tgpTextureBufferRangeEXT = (C.GPTEXTUREBUFFERRANGEEXT)(getProcAddr(\"glTextureBufferRangeEXT\"))\n\tgpTextureColorMaskSGIS = (C.GPTEXTURECOLORMASKSGIS)(getProcAddr(\"glTextureColorMaskSGIS\"))\n\tgpTextureImage1DEXT = (C.GPTEXTUREIMAGE1DEXT)(getProcAddr(\"glTextureImage1DEXT\"))\n\tgpTextureImage2DEXT = (C.GPTEXTUREIMAGE2DEXT)(getProcAddr(\"glTextureImage2DEXT\"))\n\tgpTextureImage2DMultisampleCoverageNV = (C.GPTEXTUREIMAGE2DMULTISAMPLECOVERAGENV)(getProcAddr(\"glTextureImage2DMultisampleCoverageNV\"))\n\tgpTextureImage2DMultisampleNV = (C.GPTEXTUREIMAGE2DMULTISAMPLENV)(getProcAddr(\"glTextureImage2DMultisampleNV\"))\n\tgpTextureImage3DEXT = (C.GPTEXTUREIMAGE3DEXT)(getProcAddr(\"glTextureImage3DEXT\"))\n\tgpTextureImage3DMultisampleCoverageNV = (C.GPTEXTUREIMAGE3DMULTISAMPLECOVERAGENV)(getProcAddr(\"glTextureImage3DMultisampleCoverageNV\"))\n\tgpTextureImage3DMultisampleNV = (C.GPTEXTUREIMAGE3DMULTISAMPLENV)(getProcAddr(\"glTextureImage3DMultisampleNV\"))\n\tgpTextureLightEXT = (C.GPTEXTURELIGHTEXT)(getProcAddr(\"glTextureLightEXT\"))\n\tgpTextureMaterialEXT = (C.GPTEXTUREMATERIALEXT)(getProcAddr(\"glTextureMaterialEXT\"))\n\tgpTextureNormalEXT = (C.GPTEXTURENORMALEXT)(getProcAddr(\"glTextureNormalEXT\"))\n\tgpTexturePageCommitmentEXT = (C.GPTEXTUREPAGECOMMITMENTEXT)(getProcAddr(\"glTexturePageCommitmentEXT\"))\n\tgpTexturePageCommitmentMemNV = (C.GPTEXTUREPAGECOMMITMENTMEMNV)(getProcAddr(\"glTexturePageCommitmentMemNV\"))\n\tgpTextureParameterIiv = (C.GPTEXTUREPARAMETERIIV)(getProcAddr(\"glTextureParameterIiv\"))\n\tgpTextureParameterIivEXT = (C.GPTEXTUREPARAMETERIIVEXT)(getProcAddr(\"glTextureParameterIivEXT\"))\n\tgpTextureParameterIuiv = (C.GPTEXTUREPARAMETERIUIV)(getProcAddr(\"glTextureParameterIuiv\"))\n\tgpTextureParameterIuivEXT = (C.GPTEXTUREPARAMETERIUIVEXT)(getProcAddr(\"glTextureParameterIuivEXT\"))\n\tgpTextureParameterf = (C.GPTEXTUREPARAMETERF)(getProcAddr(\"glTextureParameterf\"))\n\tgpTextureParameterfEXT = (C.GPTEXTUREPARAMETERFEXT)(getProcAddr(\"glTextureParameterfEXT\"))\n\tgpTextureParameterfv = (C.GPTEXTUREPARAMETERFV)(getProcAddr(\"glTextureParameterfv\"))\n\tgpTextureParameterfvEXT = (C.GPTEXTUREPARAMETERFVEXT)(getProcAddr(\"glTextureParameterfvEXT\"))\n\tgpTextureParameteri = (C.GPTEXTUREPARAMETERI)(getProcAddr(\"glTextureParameteri\"))\n\tgpTextureParameteriEXT = (C.GPTEXTUREPARAMETERIEXT)(getProcAddr(\"glTextureParameteriEXT\"))\n\tgpTextureParameteriv = (C.GPTEXTUREPARAMETERIV)(getProcAddr(\"glTextureParameteriv\"))\n\tgpTextureParameterivEXT = (C.GPTEXTUREPARAMETERIVEXT)(getProcAddr(\"glTextureParameterivEXT\"))\n\tgpTextureRangeAPPLE = (C.GPTEXTURERANGEAPPLE)(getProcAddr(\"glTextureRangeAPPLE\"))\n\tgpTextureRenderbufferEXT = (C.GPTEXTURERENDERBUFFEREXT)(getProcAddr(\"glTextureRenderbufferEXT\"))\n\tgpTextureStorage1D = (C.GPTEXTURESTORAGE1D)(getProcAddr(\"glTextureStorage1D\"))\n\tgpTextureStorage1DEXT = (C.GPTEXTURESTORAGE1DEXT)(getProcAddr(\"glTextureStorage1DEXT\"))\n\tgpTextureStorage2D = (C.GPTEXTURESTORAGE2D)(getProcAddr(\"glTextureStorage2D\"))\n\tgpTextureStorage2DEXT = (C.GPTEXTURESTORAGE2DEXT)(getProcAddr(\"glTextureStorage2DEXT\"))\n\tgpTextureStorage2DMultisample = (C.GPTEXTURESTORAGE2DMULTISAMPLE)(getProcAddr(\"glTextureStorage2DMultisample\"))\n\tgpTextureStorage2DMultisampleEXT = (C.GPTEXTURESTORAGE2DMULTISAMPLEEXT)(getProcAddr(\"glTextureStorage2DMultisampleEXT\"))\n\tgpTextureStorage3D = (C.GPTEXTURESTORAGE3D)(getProcAddr(\"glTextureStorage3D\"))\n\tgpTextureStorage3DEXT = (C.GPTEXTURESTORAGE3DEXT)(getProcAddr(\"glTextureStorage3DEXT\"))\n\tgpTextureStorage3DMultisample = (C.GPTEXTURESTORAGE3DMULTISAMPLE)(getProcAddr(\"glTextureStorage3DMultisample\"))\n\tgpTextureStorage3DMultisampleEXT = (C.GPTEXTURESTORAGE3DMULTISAMPLEEXT)(getProcAddr(\"glTextureStorage3DMultisampleEXT\"))\n\tgpTextureStorageMem1DEXT = (C.GPTEXTURESTORAGEMEM1DEXT)(getProcAddr(\"glTextureStorageMem1DEXT\"))\n\tgpTextureStorageMem2DEXT = (C.GPTEXTURESTORAGEMEM2DEXT)(getProcAddr(\"glTextureStorageMem2DEXT\"))\n\tgpTextureStorageMem2DMultisampleEXT = (C.GPTEXTURESTORAGEMEM2DMULTISAMPLEEXT)(getProcAddr(\"glTextureStorageMem2DMultisampleEXT\"))\n\tgpTextureStorageMem3DEXT = (C.GPTEXTURESTORAGEMEM3DEXT)(getProcAddr(\"glTextureStorageMem3DEXT\"))\n\tgpTextureStorageMem3DMultisampleEXT = (C.GPTEXTURESTORAGEMEM3DMULTISAMPLEEXT)(getProcAddr(\"glTextureStorageMem3DMultisampleEXT\"))\n\tgpTextureStorageSparseAMD = (C.GPTEXTURESTORAGESPARSEAMD)(getProcAddr(\"glTextureStorageSparseAMD\"))\n\tgpTextureSubImage1D = (C.GPTEXTURESUBIMAGE1D)(getProcAddr(\"glTextureSubImage1D\"))\n\tgpTextureSubImage1DEXT = (C.GPTEXTURESUBIMAGE1DEXT)(getProcAddr(\"glTextureSubImage1DEXT\"))\n\tgpTextureSubImage2D = (C.GPTEXTURESUBIMAGE2D)(getProcAddr(\"glTextureSubImage2D\"))\n\tgpTextureSubImage2DEXT = (C.GPTEXTURESUBIMAGE2DEXT)(getProcAddr(\"glTextureSubImage2DEXT\"))\n\tgpTextureSubImage3D = (C.GPTEXTURESUBIMAGE3D)(getProcAddr(\"glTextureSubImage3D\"))\n\tgpTextureSubImage3DEXT = (C.GPTEXTURESUBIMAGE3DEXT)(getProcAddr(\"glTextureSubImage3DEXT\"))\n\tgpTextureView = (C.GPTEXTUREVIEW)(getProcAddr(\"glTextureView\"))\n\tif gpTextureView == nil {\n\t\treturn errors.New(\"glTextureView\")\n\t}\n\tgpTrackMatrixNV = (C.GPTRACKMATRIXNV)(getProcAddr(\"glTrackMatrixNV\"))\n\tgpTransformFeedbackAttribsNV = (C.GPTRANSFORMFEEDBACKATTRIBSNV)(getProcAddr(\"glTransformFeedbackAttribsNV\"))\n\tgpTransformFeedbackBufferBase = (C.GPTRANSFORMFEEDBACKBUFFERBASE)(getProcAddr(\"glTransformFeedbackBufferBase\"))\n\tgpTransformFeedbackBufferRange = (C.GPTRANSFORMFEEDBACKBUFFERRANGE)(getProcAddr(\"glTransformFeedbackBufferRange\"))\n\tgpTransformFeedbackStreamAttribsNV = (C.GPTRANSFORMFEEDBACKSTREAMATTRIBSNV)(getProcAddr(\"glTransformFeedbackStreamAttribsNV\"))\n\tgpTransformFeedbackVaryings = (C.GPTRANSFORMFEEDBACKVARYINGS)(getProcAddr(\"glTransformFeedbackVaryings\"))\n\tif gpTransformFeedbackVaryings == nil {\n\t\treturn errors.New(\"glTransformFeedbackVaryings\")\n\t}\n\tgpTransformFeedbackVaryingsEXT = (C.GPTRANSFORMFEEDBACKVARYINGSEXT)(getProcAddr(\"glTransformFeedbackVaryingsEXT\"))\n\tgpTransformFeedbackVaryingsNV = (C.GPTRANSFORMFEEDBACKVARYINGSNV)(getProcAddr(\"glTransformFeedbackVaryingsNV\"))\n\tgpTransformPathNV = (C.GPTRANSFORMPATHNV)(getProcAddr(\"glTransformPathNV\"))\n\tgpTranslated = (C.GPTRANSLATED)(getProcAddr(\"glTranslated\"))\n\tif gpTranslated == nil {\n\t\treturn errors.New(\"glTranslated\")\n\t}\n\tgpTranslatef = (C.GPTRANSLATEF)(getProcAddr(\"glTranslatef\"))\n\tif gpTranslatef == nil {\n\t\treturn errors.New(\"glTranslatef\")\n\t}\n\tgpTranslatexOES = (C.GPTRANSLATEXOES)(getProcAddr(\"glTranslatexOES\"))\n\tgpUniform1d = (C.GPUNIFORM1D)(getProcAddr(\"glUniform1d\"))\n\tif gpUniform1d == nil {\n\t\treturn errors.New(\"glUniform1d\")\n\t}\n\tgpUniform1dv = (C.GPUNIFORM1DV)(getProcAddr(\"glUniform1dv\"))\n\tif gpUniform1dv == nil {\n\t\treturn errors.New(\"glUniform1dv\")\n\t}\n\tgpUniform1f = (C.GPUNIFORM1F)(getProcAddr(\"glUniform1f\"))\n\tif gpUniform1f == nil {\n\t\treturn errors.New(\"glUniform1f\")\n\t}\n\tgpUniform1fARB = (C.GPUNIFORM1FARB)(getProcAddr(\"glUniform1fARB\"))\n\tgpUniform1fv = (C.GPUNIFORM1FV)(getProcAddr(\"glUniform1fv\"))\n\tif gpUniform1fv == nil {\n\t\treturn errors.New(\"glUniform1fv\")\n\t}\n\tgpUniform1fvARB = (C.GPUNIFORM1FVARB)(getProcAddr(\"glUniform1fvARB\"))\n\tgpUniform1i = (C.GPUNIFORM1I)(getProcAddr(\"glUniform1i\"))\n\tif gpUniform1i == nil {\n\t\treturn errors.New(\"glUniform1i\")\n\t}\n\tgpUniform1i64ARB = (C.GPUNIFORM1I64ARB)(getProcAddr(\"glUniform1i64ARB\"))\n\tgpUniform1i64NV = (C.GPUNIFORM1I64NV)(getProcAddr(\"glUniform1i64NV\"))\n\tgpUniform1i64vARB = (C.GPUNIFORM1I64VARB)(getProcAddr(\"glUniform1i64vARB\"))\n\tgpUniform1i64vNV = (C.GPUNIFORM1I64VNV)(getProcAddr(\"glUniform1i64vNV\"))\n\tgpUniform1iARB = (C.GPUNIFORM1IARB)(getProcAddr(\"glUniform1iARB\"))\n\tgpUniform1iv = (C.GPUNIFORM1IV)(getProcAddr(\"glUniform1iv\"))\n\tif gpUniform1iv == nil {\n\t\treturn errors.New(\"glUniform1iv\")\n\t}\n\tgpUniform1ivARB = (C.GPUNIFORM1IVARB)(getProcAddr(\"glUniform1ivARB\"))\n\tgpUniform1ui = (C.GPUNIFORM1UI)(getProcAddr(\"glUniform1ui\"))\n\tif gpUniform1ui == nil {\n\t\treturn errors.New(\"glUniform1ui\")\n\t}\n\tgpUniform1ui64ARB = (C.GPUNIFORM1UI64ARB)(getProcAddr(\"glUniform1ui64ARB\"))\n\tgpUniform1ui64NV = (C.GPUNIFORM1UI64NV)(getProcAddr(\"glUniform1ui64NV\"))\n\tgpUniform1ui64vARB = (C.GPUNIFORM1UI64VARB)(getProcAddr(\"glUniform1ui64vARB\"))\n\tgpUniform1ui64vNV = (C.GPUNIFORM1UI64VNV)(getProcAddr(\"glUniform1ui64vNV\"))\n\tgpUniform1uiEXT = (C.GPUNIFORM1UIEXT)(getProcAddr(\"glUniform1uiEXT\"))\n\tgpUniform1uiv = (C.GPUNIFORM1UIV)(getProcAddr(\"glUniform1uiv\"))\n\tif gpUniform1uiv == nil {\n\t\treturn errors.New(\"glUniform1uiv\")\n\t}\n\tgpUniform1uivEXT = (C.GPUNIFORM1UIVEXT)(getProcAddr(\"glUniform1uivEXT\"))\n\tgpUniform2d = (C.GPUNIFORM2D)(getProcAddr(\"glUniform2d\"))\n\tif gpUniform2d == nil {\n\t\treturn errors.New(\"glUniform2d\")\n\t}\n\tgpUniform2dv = (C.GPUNIFORM2DV)(getProcAddr(\"glUniform2dv\"))\n\tif gpUniform2dv == nil {\n\t\treturn errors.New(\"glUniform2dv\")\n\t}\n\tgpUniform2f = (C.GPUNIFORM2F)(getProcAddr(\"glUniform2f\"))\n\tif gpUniform2f == nil {\n\t\treturn errors.New(\"glUniform2f\")\n\t}\n\tgpUniform2fARB = (C.GPUNIFORM2FARB)(getProcAddr(\"glUniform2fARB\"))\n\tgpUniform2fv = (C.GPUNIFORM2FV)(getProcAddr(\"glUniform2fv\"))\n\tif gpUniform2fv == nil {\n\t\treturn errors.New(\"glUniform2fv\")\n\t}\n\tgpUniform2fvARB = (C.GPUNIFORM2FVARB)(getProcAddr(\"glUniform2fvARB\"))\n\tgpUniform2i = (C.GPUNIFORM2I)(getProcAddr(\"glUniform2i\"))\n\tif gpUniform2i == nil {\n\t\treturn errors.New(\"glUniform2i\")\n\t}\n\tgpUniform2i64ARB = (C.GPUNIFORM2I64ARB)(getProcAddr(\"glUniform2i64ARB\"))\n\tgpUniform2i64NV = (C.GPUNIFORM2I64NV)(getProcAddr(\"glUniform2i64NV\"))\n\tgpUniform2i64vARB = (C.GPUNIFORM2I64VARB)(getProcAddr(\"glUniform2i64vARB\"))\n\tgpUniform2i64vNV = (C.GPUNIFORM2I64VNV)(getProcAddr(\"glUniform2i64vNV\"))\n\tgpUniform2iARB = (C.GPUNIFORM2IARB)(getProcAddr(\"glUniform2iARB\"))\n\tgpUniform2iv = (C.GPUNIFORM2IV)(getProcAddr(\"glUniform2iv\"))\n\tif gpUniform2iv == nil {\n\t\treturn errors.New(\"glUniform2iv\")\n\t}\n\tgpUniform2ivARB = (C.GPUNIFORM2IVARB)(getProcAddr(\"glUniform2ivARB\"))\n\tgpUniform2ui = (C.GPUNIFORM2UI)(getProcAddr(\"glUniform2ui\"))\n\tif gpUniform2ui == nil {\n\t\treturn errors.New(\"glUniform2ui\")\n\t}\n\tgpUniform2ui64ARB = (C.GPUNIFORM2UI64ARB)(getProcAddr(\"glUniform2ui64ARB\"))\n\tgpUniform2ui64NV = (C.GPUNIFORM2UI64NV)(getProcAddr(\"glUniform2ui64NV\"))\n\tgpUniform2ui64vARB = (C.GPUNIFORM2UI64VARB)(getProcAddr(\"glUniform2ui64vARB\"))\n\tgpUniform2ui64vNV = (C.GPUNIFORM2UI64VNV)(getProcAddr(\"glUniform2ui64vNV\"))\n\tgpUniform2uiEXT = (C.GPUNIFORM2UIEXT)(getProcAddr(\"glUniform2uiEXT\"))\n\tgpUniform2uiv = (C.GPUNIFORM2UIV)(getProcAddr(\"glUniform2uiv\"))\n\tif gpUniform2uiv == nil {\n\t\treturn errors.New(\"glUniform2uiv\")\n\t}\n\tgpUniform2uivEXT = (C.GPUNIFORM2UIVEXT)(getProcAddr(\"glUniform2uivEXT\"))\n\tgpUniform3d = (C.GPUNIFORM3D)(getProcAddr(\"glUniform3d\"))\n\tif gpUniform3d == nil {\n\t\treturn errors.New(\"glUniform3d\")\n\t}\n\tgpUniform3dv = (C.GPUNIFORM3DV)(getProcAddr(\"glUniform3dv\"))\n\tif gpUniform3dv == nil {\n\t\treturn errors.New(\"glUniform3dv\")\n\t}\n\tgpUniform3f = (C.GPUNIFORM3F)(getProcAddr(\"glUniform3f\"))\n\tif gpUniform3f == nil {\n\t\treturn errors.New(\"glUniform3f\")\n\t}\n\tgpUniform3fARB = (C.GPUNIFORM3FARB)(getProcAddr(\"glUniform3fARB\"))\n\tgpUniform3fv = (C.GPUNIFORM3FV)(getProcAddr(\"glUniform3fv\"))\n\tif gpUniform3fv == nil {\n\t\treturn errors.New(\"glUniform3fv\")\n\t}\n\tgpUniform3fvARB = (C.GPUNIFORM3FVARB)(getProcAddr(\"glUniform3fvARB\"))\n\tgpUniform3i = (C.GPUNIFORM3I)(getProcAddr(\"glUniform3i\"))\n\tif gpUniform3i == nil {\n\t\treturn errors.New(\"glUniform3i\")\n\t}\n\tgpUniform3i64ARB = (C.GPUNIFORM3I64ARB)(getProcAddr(\"glUniform3i64ARB\"))\n\tgpUniform3i64NV = (C.GPUNIFORM3I64NV)(getProcAddr(\"glUniform3i64NV\"))\n\tgpUniform3i64vARB = (C.GPUNIFORM3I64VARB)(getProcAddr(\"glUniform3i64vARB\"))\n\tgpUniform3i64vNV = (C.GPUNIFORM3I64VNV)(getProcAddr(\"glUniform3i64vNV\"))\n\tgpUniform3iARB = (C.GPUNIFORM3IARB)(getProcAddr(\"glUniform3iARB\"))\n\tgpUniform3iv = (C.GPUNIFORM3IV)(getProcAddr(\"glUniform3iv\"))\n\tif gpUniform3iv == nil {\n\t\treturn errors.New(\"glUniform3iv\")\n\t}\n\tgpUniform3ivARB = (C.GPUNIFORM3IVARB)(getProcAddr(\"glUniform3ivARB\"))\n\tgpUniform3ui = (C.GPUNIFORM3UI)(getProcAddr(\"glUniform3ui\"))\n\tif gpUniform3ui == nil {\n\t\treturn errors.New(\"glUniform3ui\")\n\t}\n\tgpUniform3ui64ARB = (C.GPUNIFORM3UI64ARB)(getProcAddr(\"glUniform3ui64ARB\"))\n\tgpUniform3ui64NV = (C.GPUNIFORM3UI64NV)(getProcAddr(\"glUniform3ui64NV\"))\n\tgpUniform3ui64vARB = (C.GPUNIFORM3UI64VARB)(getProcAddr(\"glUniform3ui64vARB\"))\n\tgpUniform3ui64vNV = (C.GPUNIFORM3UI64VNV)(getProcAddr(\"glUniform3ui64vNV\"))\n\tgpUniform3uiEXT = (C.GPUNIFORM3UIEXT)(getProcAddr(\"glUniform3uiEXT\"))\n\tgpUniform3uiv = (C.GPUNIFORM3UIV)(getProcAddr(\"glUniform3uiv\"))\n\tif gpUniform3uiv == nil {\n\t\treturn errors.New(\"glUniform3uiv\")\n\t}\n\tgpUniform3uivEXT = (C.GPUNIFORM3UIVEXT)(getProcAddr(\"glUniform3uivEXT\"))\n\tgpUniform4d = (C.GPUNIFORM4D)(getProcAddr(\"glUniform4d\"))\n\tif gpUniform4d == nil {\n\t\treturn errors.New(\"glUniform4d\")\n\t}\n\tgpUniform4dv = (C.GPUNIFORM4DV)(getProcAddr(\"glUniform4dv\"))\n\tif gpUniform4dv == nil {\n\t\treturn errors.New(\"glUniform4dv\")\n\t}\n\tgpUniform4f = (C.GPUNIFORM4F)(getProcAddr(\"glUniform4f\"))\n\tif gpUniform4f == nil {\n\t\treturn errors.New(\"glUniform4f\")\n\t}\n\tgpUniform4fARB = (C.GPUNIFORM4FARB)(getProcAddr(\"glUniform4fARB\"))\n\tgpUniform4fv = (C.GPUNIFORM4FV)(getProcAddr(\"glUniform4fv\"))\n\tif gpUniform4fv == nil {\n\t\treturn errors.New(\"glUniform4fv\")\n\t}\n\tgpUniform4fvARB = (C.GPUNIFORM4FVARB)(getProcAddr(\"glUniform4fvARB\"))\n\tgpUniform4i = (C.GPUNIFORM4I)(getProcAddr(\"glUniform4i\"))\n\tif gpUniform4i == nil {\n\t\treturn errors.New(\"glUniform4i\")\n\t}\n\tgpUniform4i64ARB = (C.GPUNIFORM4I64ARB)(getProcAddr(\"glUniform4i64ARB\"))\n\tgpUniform4i64NV = (C.GPUNIFORM4I64NV)(getProcAddr(\"glUniform4i64NV\"))\n\tgpUniform4i64vARB = (C.GPUNIFORM4I64VARB)(getProcAddr(\"glUniform4i64vARB\"))\n\tgpUniform4i64vNV = (C.GPUNIFORM4I64VNV)(getProcAddr(\"glUniform4i64vNV\"))\n\tgpUniform4iARB = (C.GPUNIFORM4IARB)(getProcAddr(\"glUniform4iARB\"))\n\tgpUniform4iv = (C.GPUNIFORM4IV)(getProcAddr(\"glUniform4iv\"))\n\tif gpUniform4iv == nil {\n\t\treturn errors.New(\"glUniform4iv\")\n\t}\n\tgpUniform4ivARB = (C.GPUNIFORM4IVARB)(getProcAddr(\"glUniform4ivARB\"))\n\tgpUniform4ui = (C.GPUNIFORM4UI)(getProcAddr(\"glUniform4ui\"))\n\tif gpUniform4ui == nil {\n\t\treturn errors.New(\"glUniform4ui\")\n\t}\n\tgpUniform4ui64ARB = (C.GPUNIFORM4UI64ARB)(getProcAddr(\"glUniform4ui64ARB\"))\n\tgpUniform4ui64NV = (C.GPUNIFORM4UI64NV)(getProcAddr(\"glUniform4ui64NV\"))\n\tgpUniform4ui64vARB = (C.GPUNIFORM4UI64VARB)(getProcAddr(\"glUniform4ui64vARB\"))\n\tgpUniform4ui64vNV = (C.GPUNIFORM4UI64VNV)(getProcAddr(\"glUniform4ui64vNV\"))\n\tgpUniform4uiEXT = (C.GPUNIFORM4UIEXT)(getProcAddr(\"glUniform4uiEXT\"))\n\tgpUniform4uiv = (C.GPUNIFORM4UIV)(getProcAddr(\"glUniform4uiv\"))\n\tif gpUniform4uiv == nil {\n\t\treturn errors.New(\"glUniform4uiv\")\n\t}\n\tgpUniform4uivEXT = (C.GPUNIFORM4UIVEXT)(getProcAddr(\"glUniform4uivEXT\"))\n\tgpUniformBlockBinding = (C.GPUNIFORMBLOCKBINDING)(getProcAddr(\"glUniformBlockBinding\"))\n\tif gpUniformBlockBinding == nil {\n\t\treturn errors.New(\"glUniformBlockBinding\")\n\t}\n\tgpUniformBufferEXT = (C.GPUNIFORMBUFFEREXT)(getProcAddr(\"glUniformBufferEXT\"))\n\tgpUniformHandleui64ARB = (C.GPUNIFORMHANDLEUI64ARB)(getProcAddr(\"glUniformHandleui64ARB\"))\n\tgpUniformHandleui64NV = (C.GPUNIFORMHANDLEUI64NV)(getProcAddr(\"glUniformHandleui64NV\"))\n\tgpUniformHandleui64vARB = (C.GPUNIFORMHANDLEUI64VARB)(getProcAddr(\"glUniformHandleui64vARB\"))\n\tgpUniformHandleui64vNV = (C.GPUNIFORMHANDLEUI64VNV)(getProcAddr(\"glUniformHandleui64vNV\"))\n\tgpUniformMatrix2dv = (C.GPUNIFORMMATRIX2DV)(getProcAddr(\"glUniformMatrix2dv\"))\n\tif gpUniformMatrix2dv == nil {\n\t\treturn errors.New(\"glUniformMatrix2dv\")\n\t}\n\tgpUniformMatrix2fv = (C.GPUNIFORMMATRIX2FV)(getProcAddr(\"glUniformMatrix2fv\"))\n\tif gpUniformMatrix2fv == nil {\n\t\treturn errors.New(\"glUniformMatrix2fv\")\n\t}\n\tgpUniformMatrix2fvARB = (C.GPUNIFORMMATRIX2FVARB)(getProcAddr(\"glUniformMatrix2fvARB\"))\n\tgpUniformMatrix2x3dv = (C.GPUNIFORMMATRIX2X3DV)(getProcAddr(\"glUniformMatrix2x3dv\"))\n\tif gpUniformMatrix2x3dv == nil {\n\t\treturn errors.New(\"glUniformMatrix2x3dv\")\n\t}\n\tgpUniformMatrix2x3fv = (C.GPUNIFORMMATRIX2X3FV)(getProcAddr(\"glUniformMatrix2x3fv\"))\n\tif gpUniformMatrix2x3fv == nil {\n\t\treturn errors.New(\"glUniformMatrix2x3fv\")\n\t}\n\tgpUniformMatrix2x4dv = (C.GPUNIFORMMATRIX2X4DV)(getProcAddr(\"glUniformMatrix2x4dv\"))\n\tif gpUniformMatrix2x4dv == nil {\n\t\treturn errors.New(\"glUniformMatrix2x4dv\")\n\t}\n\tgpUniformMatrix2x4fv = (C.GPUNIFORMMATRIX2X4FV)(getProcAddr(\"glUniformMatrix2x4fv\"))\n\tif gpUniformMatrix2x4fv == nil {\n\t\treturn errors.New(\"glUniformMatrix2x4fv\")\n\t}\n\tgpUniformMatrix3dv = (C.GPUNIFORMMATRIX3DV)(getProcAddr(\"glUniformMatrix3dv\"))\n\tif gpUniformMatrix3dv == nil {\n\t\treturn errors.New(\"glUniformMatrix3dv\")\n\t}\n\tgpUniformMatrix3fv = (C.GPUNIFORMMATRIX3FV)(getProcAddr(\"glUniformMatrix3fv\"))\n\tif gpUniformMatrix3fv == nil {\n\t\treturn errors.New(\"glUniformMatrix3fv\")\n\t}\n\tgpUniformMatrix3fvARB = (C.GPUNIFORMMATRIX3FVARB)(getProcAddr(\"glUniformMatrix3fvARB\"))\n\tgpUniformMatrix3x2dv = (C.GPUNIFORMMATRIX3X2DV)(getProcAddr(\"glUniformMatrix3x2dv\"))\n\tif gpUniformMatrix3x2dv == nil {\n\t\treturn errors.New(\"glUniformMatrix3x2dv\")\n\t}\n\tgpUniformMatrix3x2fv = (C.GPUNIFORMMATRIX3X2FV)(getProcAddr(\"glUniformMatrix3x2fv\"))\n\tif gpUniformMatrix3x2fv == nil {\n\t\treturn errors.New(\"glUniformMatrix3x2fv\")\n\t}\n\tgpUniformMatrix3x4dv = (C.GPUNIFORMMATRIX3X4DV)(getProcAddr(\"glUniformMatrix3x4dv\"))\n\tif gpUniformMatrix3x4dv == nil {\n\t\treturn errors.New(\"glUniformMatrix3x4dv\")\n\t}\n\tgpUniformMatrix3x4fv = (C.GPUNIFORMMATRIX3X4FV)(getProcAddr(\"glUniformMatrix3x4fv\"))\n\tif gpUniformMatrix3x4fv == nil {\n\t\treturn errors.New(\"glUniformMatrix3x4fv\")\n\t}\n\tgpUniformMatrix4dv = (C.GPUNIFORMMATRIX4DV)(getProcAddr(\"glUniformMatrix4dv\"))\n\tif gpUniformMatrix4dv == nil {\n\t\treturn errors.New(\"glUniformMatrix4dv\")\n\t}\n\tgpUniformMatrix4fv = (C.GPUNIFORMMATRIX4FV)(getProcAddr(\"glUniformMatrix4fv\"))\n\tif gpUniformMatrix4fv == nil {\n\t\treturn errors.New(\"glUniformMatrix4fv\")\n\t}\n\tgpUniformMatrix4fvARB = (C.GPUNIFORMMATRIX4FVARB)(getProcAddr(\"glUniformMatrix4fvARB\"))\n\tgpUniformMatrix4x2dv = (C.GPUNIFORMMATRIX4X2DV)(getProcAddr(\"glUniformMatrix4x2dv\"))\n\tif gpUniformMatrix4x2dv == nil {\n\t\treturn errors.New(\"glUniformMatrix4x2dv\")\n\t}\n\tgpUniformMatrix4x2fv = (C.GPUNIFORMMATRIX4X2FV)(getProcAddr(\"glUniformMatrix4x2fv\"))\n\tif gpUniformMatrix4x2fv == nil {\n\t\treturn errors.New(\"glUniformMatrix4x2fv\")\n\t}\n\tgpUniformMatrix4x3dv = (C.GPUNIFORMMATRIX4X3DV)(getProcAddr(\"glUniformMatrix4x3dv\"))\n\tif gpUniformMatrix4x3dv == nil {\n\t\treturn errors.New(\"glUniformMatrix4x3dv\")\n\t}\n\tgpUniformMatrix4x3fv = (C.GPUNIFORMMATRIX4X3FV)(getProcAddr(\"glUniformMatrix4x3fv\"))\n\tif gpUniformMatrix4x3fv == nil {\n\t\treturn errors.New(\"glUniformMatrix4x3fv\")\n\t}\n\tgpUniformSubroutinesuiv = (C.GPUNIFORMSUBROUTINESUIV)(getProcAddr(\"glUniformSubroutinesuiv\"))\n\tif gpUniformSubroutinesuiv == nil {\n\t\treturn errors.New(\"glUniformSubroutinesuiv\")\n\t}\n\tgpUniformui64NV = (C.GPUNIFORMUI64NV)(getProcAddr(\"glUniformui64NV\"))\n\tgpUniformui64vNV = (C.GPUNIFORMUI64VNV)(getProcAddr(\"glUniformui64vNV\"))\n\tgpUnlockArraysEXT = (C.GPUNLOCKARRAYSEXT)(getProcAddr(\"glUnlockArraysEXT\"))\n\tgpUnmapBuffer = (C.GPUNMAPBUFFER)(getProcAddr(\"glUnmapBuffer\"))\n\tif gpUnmapBuffer == nil {\n\t\treturn errors.New(\"glUnmapBuffer\")\n\t}\n\tgpUnmapBufferARB = (C.GPUNMAPBUFFERARB)(getProcAddr(\"glUnmapBufferARB\"))\n\tgpUnmapNamedBuffer = (C.GPUNMAPNAMEDBUFFER)(getProcAddr(\"glUnmapNamedBuffer\"))\n\tgpUnmapNamedBufferEXT = (C.GPUNMAPNAMEDBUFFEREXT)(getProcAddr(\"glUnmapNamedBufferEXT\"))\n\tgpUnmapObjectBufferATI = (C.GPUNMAPOBJECTBUFFERATI)(getProcAddr(\"glUnmapObjectBufferATI\"))\n\tgpUnmapTexture2DINTEL = (C.GPUNMAPTEXTURE2DINTEL)(getProcAddr(\"glUnmapTexture2DINTEL\"))\n\tgpUpdateObjectBufferATI = (C.GPUPDATEOBJECTBUFFERATI)(getProcAddr(\"glUpdateObjectBufferATI\"))\n\tgpUploadGpuMaskNVX = (C.GPUPLOADGPUMASKNVX)(getProcAddr(\"glUploadGpuMaskNVX\"))\n\tgpUseProgram = (C.GPUSEPROGRAM)(getProcAddr(\"glUseProgram\"))\n\tif gpUseProgram == nil {\n\t\treturn errors.New(\"glUseProgram\")\n\t}\n\tgpUseProgramObjectARB = (C.GPUSEPROGRAMOBJECTARB)(getProcAddr(\"glUseProgramObjectARB\"))\n\tgpUseProgramStages = (C.GPUSEPROGRAMSTAGES)(getProcAddr(\"glUseProgramStages\"))\n\tif gpUseProgramStages == nil {\n\t\treturn errors.New(\"glUseProgramStages\")\n\t}\n\tgpUseProgramStagesEXT = (C.GPUSEPROGRAMSTAGESEXT)(getProcAddr(\"glUseProgramStagesEXT\"))\n\tgpUseShaderProgramEXT = (C.GPUSESHADERPROGRAMEXT)(getProcAddr(\"glUseShaderProgramEXT\"))\n\tgpVDPAUFiniNV = (C.GPVDPAUFININV)(getProcAddr(\"glVDPAUFiniNV\"))\n\tgpVDPAUGetSurfaceivNV = (C.GPVDPAUGETSURFACEIVNV)(getProcAddr(\"glVDPAUGetSurfaceivNV\"))\n\tgpVDPAUInitNV = (C.GPVDPAUINITNV)(getProcAddr(\"glVDPAUInitNV\"))\n\tgpVDPAUIsSurfaceNV = (C.GPVDPAUISSURFACENV)(getProcAddr(\"glVDPAUIsSurfaceNV\"))\n\tgpVDPAUMapSurfacesNV = (C.GPVDPAUMAPSURFACESNV)(getProcAddr(\"glVDPAUMapSurfacesNV\"))\n\tgpVDPAURegisterOutputSurfaceNV = (C.GPVDPAUREGISTEROUTPUTSURFACENV)(getProcAddr(\"glVDPAURegisterOutputSurfaceNV\"))\n\tgpVDPAURegisterVideoSurfaceNV = (C.GPVDPAUREGISTERVIDEOSURFACENV)(getProcAddr(\"glVDPAURegisterVideoSurfaceNV\"))\n\tgpVDPAURegisterVideoSurfaceWithPictureStructureNV = (C.GPVDPAUREGISTERVIDEOSURFACEWITHPICTURESTRUCTURENV)(getProcAddr(\"glVDPAURegisterVideoSurfaceWithPictureStructureNV\"))\n\tgpVDPAUSurfaceAccessNV = (C.GPVDPAUSURFACEACCESSNV)(getProcAddr(\"glVDPAUSurfaceAccessNV\"))\n\tgpVDPAUUnmapSurfacesNV = (C.GPVDPAUUNMAPSURFACESNV)(getProcAddr(\"glVDPAUUnmapSurfacesNV\"))\n\tgpVDPAUUnregisterSurfaceNV = (C.GPVDPAUUNREGISTERSURFACENV)(getProcAddr(\"glVDPAUUnregisterSurfaceNV\"))\n\tgpValidateProgram = (C.GPVALIDATEPROGRAM)(getProcAddr(\"glValidateProgram\"))\n\tif gpValidateProgram == nil {\n\t\treturn errors.New(\"glValidateProgram\")\n\t}\n\tgpValidateProgramARB = (C.GPVALIDATEPROGRAMARB)(getProcAddr(\"glValidateProgramARB\"))\n\tgpValidateProgramPipeline = (C.GPVALIDATEPROGRAMPIPELINE)(getProcAddr(\"glValidateProgramPipeline\"))\n\tif gpValidateProgramPipeline == nil {\n\t\treturn errors.New(\"glValidateProgramPipeline\")\n\t}\n\tgpValidateProgramPipelineEXT = (C.GPVALIDATEPROGRAMPIPELINEEXT)(getProcAddr(\"glValidateProgramPipelineEXT\"))\n\tgpVariantArrayObjectATI = (C.GPVARIANTARRAYOBJECTATI)(getProcAddr(\"glVariantArrayObjectATI\"))\n\tgpVariantPointerEXT = (C.GPVARIANTPOINTEREXT)(getProcAddr(\"glVariantPointerEXT\"))\n\tgpVariantbvEXT = (C.GPVARIANTBVEXT)(getProcAddr(\"glVariantbvEXT\"))\n\tgpVariantdvEXT = (C.GPVARIANTDVEXT)(getProcAddr(\"glVariantdvEXT\"))\n\tgpVariantfvEXT = (C.GPVARIANTFVEXT)(getProcAddr(\"glVariantfvEXT\"))\n\tgpVariantivEXT = (C.GPVARIANTIVEXT)(getProcAddr(\"glVariantivEXT\"))\n\tgpVariantsvEXT = (C.GPVARIANTSVEXT)(getProcAddr(\"glVariantsvEXT\"))\n\tgpVariantubvEXT = (C.GPVARIANTUBVEXT)(getProcAddr(\"glVariantubvEXT\"))\n\tgpVariantuivEXT = (C.GPVARIANTUIVEXT)(getProcAddr(\"glVariantuivEXT\"))\n\tgpVariantusvEXT = (C.GPVARIANTUSVEXT)(getProcAddr(\"glVariantusvEXT\"))\n\tgpVertex2bOES = (C.GPVERTEX2BOES)(getProcAddr(\"glVertex2bOES\"))\n\tgpVertex2bvOES = (C.GPVERTEX2BVOES)(getProcAddr(\"glVertex2bvOES\"))\n\tgpVertex2d = (C.GPVERTEX2D)(getProcAddr(\"glVertex2d\"))\n\tif gpVertex2d == nil {\n\t\treturn errors.New(\"glVertex2d\")\n\t}\n\tgpVertex2dv = (C.GPVERTEX2DV)(getProcAddr(\"glVertex2dv\"))\n\tif gpVertex2dv == nil {\n\t\treturn errors.New(\"glVertex2dv\")\n\t}\n\tgpVertex2f = (C.GPVERTEX2F)(getProcAddr(\"glVertex2f\"))\n\tif gpVertex2f == nil {\n\t\treturn errors.New(\"glVertex2f\")\n\t}\n\tgpVertex2fv = (C.GPVERTEX2FV)(getProcAddr(\"glVertex2fv\"))\n\tif gpVertex2fv == nil {\n\t\treturn errors.New(\"glVertex2fv\")\n\t}\n\tgpVertex2hNV = (C.GPVERTEX2HNV)(getProcAddr(\"glVertex2hNV\"))\n\tgpVertex2hvNV = (C.GPVERTEX2HVNV)(getProcAddr(\"glVertex2hvNV\"))\n\tgpVertex2i = (C.GPVERTEX2I)(getProcAddr(\"glVertex2i\"))\n\tif gpVertex2i == nil {\n\t\treturn errors.New(\"glVertex2i\")\n\t}\n\tgpVertex2iv = (C.GPVERTEX2IV)(getProcAddr(\"glVertex2iv\"))\n\tif gpVertex2iv == nil {\n\t\treturn errors.New(\"glVertex2iv\")\n\t}\n\tgpVertex2s = (C.GPVERTEX2S)(getProcAddr(\"glVertex2s\"))\n\tif gpVertex2s == nil {\n\t\treturn errors.New(\"glVertex2s\")\n\t}\n\tgpVertex2sv = (C.GPVERTEX2SV)(getProcAddr(\"glVertex2sv\"))\n\tif gpVertex2sv == nil {\n\t\treturn errors.New(\"glVertex2sv\")\n\t}\n\tgpVertex2xOES = (C.GPVERTEX2XOES)(getProcAddr(\"glVertex2xOES\"))\n\tgpVertex2xvOES = (C.GPVERTEX2XVOES)(getProcAddr(\"glVertex2xvOES\"))\n\tgpVertex3bOES = (C.GPVERTEX3BOES)(getProcAddr(\"glVertex3bOES\"))\n\tgpVertex3bvOES = (C.GPVERTEX3BVOES)(getProcAddr(\"glVertex3bvOES\"))\n\tgpVertex3d = (C.GPVERTEX3D)(getProcAddr(\"glVertex3d\"))\n\tif gpVertex3d == nil {\n\t\treturn errors.New(\"glVertex3d\")\n\t}\n\tgpVertex3dv = (C.GPVERTEX3DV)(getProcAddr(\"glVertex3dv\"))\n\tif gpVertex3dv == nil {\n\t\treturn errors.New(\"glVertex3dv\")\n\t}\n\tgpVertex3f = (C.GPVERTEX3F)(getProcAddr(\"glVertex3f\"))\n\tif gpVertex3f == nil {\n\t\treturn errors.New(\"glVertex3f\")\n\t}\n\tgpVertex3fv = (C.GPVERTEX3FV)(getProcAddr(\"glVertex3fv\"))\n\tif gpVertex3fv == nil {\n\t\treturn errors.New(\"glVertex3fv\")\n\t}\n\tgpVertex3hNV = (C.GPVERTEX3HNV)(getProcAddr(\"glVertex3hNV\"))\n\tgpVertex3hvNV = (C.GPVERTEX3HVNV)(getProcAddr(\"glVertex3hvNV\"))\n\tgpVertex3i = (C.GPVERTEX3I)(getProcAddr(\"glVertex3i\"))\n\tif gpVertex3i == nil {\n\t\treturn errors.New(\"glVertex3i\")\n\t}\n\tgpVertex3iv = (C.GPVERTEX3IV)(getProcAddr(\"glVertex3iv\"))\n\tif gpVertex3iv == nil {\n\t\treturn errors.New(\"glVertex3iv\")\n\t}\n\tgpVertex3s = (C.GPVERTEX3S)(getProcAddr(\"glVertex3s\"))\n\tif gpVertex3s == nil {\n\t\treturn errors.New(\"glVertex3s\")\n\t}\n\tgpVertex3sv = (C.GPVERTEX3SV)(getProcAddr(\"glVertex3sv\"))\n\tif gpVertex3sv == nil {\n\t\treturn errors.New(\"glVertex3sv\")\n\t}\n\tgpVertex3xOES = (C.GPVERTEX3XOES)(getProcAddr(\"glVertex3xOES\"))\n\tgpVertex3xvOES = (C.GPVERTEX3XVOES)(getProcAddr(\"glVertex3xvOES\"))\n\tgpVertex4bOES = (C.GPVERTEX4BOES)(getProcAddr(\"glVertex4bOES\"))\n\tgpVertex4bvOES = (C.GPVERTEX4BVOES)(getProcAddr(\"glVertex4bvOES\"))\n\tgpVertex4d = (C.GPVERTEX4D)(getProcAddr(\"glVertex4d\"))\n\tif gpVertex4d == nil {\n\t\treturn errors.New(\"glVertex4d\")\n\t}\n\tgpVertex4dv = (C.GPVERTEX4DV)(getProcAddr(\"glVertex4dv\"))\n\tif gpVertex4dv == nil {\n\t\treturn errors.New(\"glVertex4dv\")\n\t}\n\tgpVertex4f = (C.GPVERTEX4F)(getProcAddr(\"glVertex4f\"))\n\tif gpVertex4f == nil {\n\t\treturn errors.New(\"glVertex4f\")\n\t}\n\tgpVertex4fv = (C.GPVERTEX4FV)(getProcAddr(\"glVertex4fv\"))\n\tif gpVertex4fv == nil {\n\t\treturn errors.New(\"glVertex4fv\")\n\t}\n\tgpVertex4hNV = (C.GPVERTEX4HNV)(getProcAddr(\"glVertex4hNV\"))\n\tgpVertex4hvNV = (C.GPVERTEX4HVNV)(getProcAddr(\"glVertex4hvNV\"))\n\tgpVertex4i = (C.GPVERTEX4I)(getProcAddr(\"glVertex4i\"))\n\tif gpVertex4i == nil {\n\t\treturn errors.New(\"glVertex4i\")\n\t}\n\tgpVertex4iv = (C.GPVERTEX4IV)(getProcAddr(\"glVertex4iv\"))\n\tif gpVertex4iv == nil {\n\t\treturn errors.New(\"glVertex4iv\")\n\t}\n\tgpVertex4s = (C.GPVERTEX4S)(getProcAddr(\"glVertex4s\"))\n\tif gpVertex4s == nil {\n\t\treturn errors.New(\"glVertex4s\")\n\t}\n\tgpVertex4sv = (C.GPVERTEX4SV)(getProcAddr(\"glVertex4sv\"))\n\tif gpVertex4sv == nil {\n\t\treturn errors.New(\"glVertex4sv\")\n\t}\n\tgpVertex4xOES = (C.GPVERTEX4XOES)(getProcAddr(\"glVertex4xOES\"))\n\tgpVertex4xvOES = (C.GPVERTEX4XVOES)(getProcAddr(\"glVertex4xvOES\"))\n\tgpVertexArrayAttribBinding = (C.GPVERTEXARRAYATTRIBBINDING)(getProcAddr(\"glVertexArrayAttribBinding\"))\n\tgpVertexArrayAttribFormat = (C.GPVERTEXARRAYATTRIBFORMAT)(getProcAddr(\"glVertexArrayAttribFormat\"))\n\tgpVertexArrayAttribIFormat = (C.GPVERTEXARRAYATTRIBIFORMAT)(getProcAddr(\"glVertexArrayAttribIFormat\"))\n\tgpVertexArrayAttribLFormat = (C.GPVERTEXARRAYATTRIBLFORMAT)(getProcAddr(\"glVertexArrayAttribLFormat\"))\n\tgpVertexArrayBindVertexBufferEXT = (C.GPVERTEXARRAYBINDVERTEXBUFFEREXT)(getProcAddr(\"glVertexArrayBindVertexBufferEXT\"))\n\tgpVertexArrayBindingDivisor = (C.GPVERTEXARRAYBINDINGDIVISOR)(getProcAddr(\"glVertexArrayBindingDivisor\"))\n\tgpVertexArrayColorOffsetEXT = (C.GPVERTEXARRAYCOLOROFFSETEXT)(getProcAddr(\"glVertexArrayColorOffsetEXT\"))\n\tgpVertexArrayEdgeFlagOffsetEXT = (C.GPVERTEXARRAYEDGEFLAGOFFSETEXT)(getProcAddr(\"glVertexArrayEdgeFlagOffsetEXT\"))\n\tgpVertexArrayElementBuffer = (C.GPVERTEXARRAYELEMENTBUFFER)(getProcAddr(\"glVertexArrayElementBuffer\"))\n\tgpVertexArrayFogCoordOffsetEXT = (C.GPVERTEXARRAYFOGCOORDOFFSETEXT)(getProcAddr(\"glVertexArrayFogCoordOffsetEXT\"))\n\tgpVertexArrayIndexOffsetEXT = (C.GPVERTEXARRAYINDEXOFFSETEXT)(getProcAddr(\"glVertexArrayIndexOffsetEXT\"))\n\tgpVertexArrayMultiTexCoordOffsetEXT = (C.GPVERTEXARRAYMULTITEXCOORDOFFSETEXT)(getProcAddr(\"glVertexArrayMultiTexCoordOffsetEXT\"))\n\tgpVertexArrayNormalOffsetEXT = (C.GPVERTEXARRAYNORMALOFFSETEXT)(getProcAddr(\"glVertexArrayNormalOffsetEXT\"))\n\tgpVertexArrayParameteriAPPLE = (C.GPVERTEXARRAYPARAMETERIAPPLE)(getProcAddr(\"glVertexArrayParameteriAPPLE\"))\n\tgpVertexArrayRangeAPPLE = (C.GPVERTEXARRAYRANGEAPPLE)(getProcAddr(\"glVertexArrayRangeAPPLE\"))\n\tgpVertexArrayRangeNV = (C.GPVERTEXARRAYRANGENV)(getProcAddr(\"glVertexArrayRangeNV\"))\n\tgpVertexArraySecondaryColorOffsetEXT = (C.GPVERTEXARRAYSECONDARYCOLOROFFSETEXT)(getProcAddr(\"glVertexArraySecondaryColorOffsetEXT\"))\n\tgpVertexArrayTexCoordOffsetEXT = (C.GPVERTEXARRAYTEXCOORDOFFSETEXT)(getProcAddr(\"glVertexArrayTexCoordOffsetEXT\"))\n\tgpVertexArrayVertexAttribBindingEXT = (C.GPVERTEXARRAYVERTEXATTRIBBINDINGEXT)(getProcAddr(\"glVertexArrayVertexAttribBindingEXT\"))\n\tgpVertexArrayVertexAttribDivisorEXT = (C.GPVERTEXARRAYVERTEXATTRIBDIVISOREXT)(getProcAddr(\"glVertexArrayVertexAttribDivisorEXT\"))\n\tgpVertexArrayVertexAttribFormatEXT = (C.GPVERTEXARRAYVERTEXATTRIBFORMATEXT)(getProcAddr(\"glVertexArrayVertexAttribFormatEXT\"))\n\tgpVertexArrayVertexAttribIFormatEXT = (C.GPVERTEXARRAYVERTEXATTRIBIFORMATEXT)(getProcAddr(\"glVertexArrayVertexAttribIFormatEXT\"))\n\tgpVertexArrayVertexAttribIOffsetEXT = (C.GPVERTEXARRAYVERTEXATTRIBIOFFSETEXT)(getProcAddr(\"glVertexArrayVertexAttribIOffsetEXT\"))\n\tgpVertexArrayVertexAttribLFormatEXT = (C.GPVERTEXARRAYVERTEXATTRIBLFORMATEXT)(getProcAddr(\"glVertexArrayVertexAttribLFormatEXT\"))\n\tgpVertexArrayVertexAttribLOffsetEXT = (C.GPVERTEXARRAYVERTEXATTRIBLOFFSETEXT)(getProcAddr(\"glVertexArrayVertexAttribLOffsetEXT\"))\n\tgpVertexArrayVertexAttribOffsetEXT = (C.GPVERTEXARRAYVERTEXATTRIBOFFSETEXT)(getProcAddr(\"glVertexArrayVertexAttribOffsetEXT\"))\n\tgpVertexArrayVertexBindingDivisorEXT = (C.GPVERTEXARRAYVERTEXBINDINGDIVISOREXT)(getProcAddr(\"glVertexArrayVertexBindingDivisorEXT\"))\n\tgpVertexArrayVertexBuffer = (C.GPVERTEXARRAYVERTEXBUFFER)(getProcAddr(\"glVertexArrayVertexBuffer\"))\n\tgpVertexArrayVertexBuffers = (C.GPVERTEXARRAYVERTEXBUFFERS)(getProcAddr(\"glVertexArrayVertexBuffers\"))\n\tgpVertexArrayVertexOffsetEXT = (C.GPVERTEXARRAYVERTEXOFFSETEXT)(getProcAddr(\"glVertexArrayVertexOffsetEXT\"))\n\tgpVertexAttrib1d = (C.GPVERTEXATTRIB1D)(getProcAddr(\"glVertexAttrib1d\"))\n\tif gpVertexAttrib1d == nil {\n\t\treturn errors.New(\"glVertexAttrib1d\")\n\t}\n\tgpVertexAttrib1dARB = (C.GPVERTEXATTRIB1DARB)(getProcAddr(\"glVertexAttrib1dARB\"))\n\tgpVertexAttrib1dNV = (C.GPVERTEXATTRIB1DNV)(getProcAddr(\"glVertexAttrib1dNV\"))\n\tgpVertexAttrib1dv = (C.GPVERTEXATTRIB1DV)(getProcAddr(\"glVertexAttrib1dv\"))\n\tif gpVertexAttrib1dv == nil {\n\t\treturn errors.New(\"glVertexAttrib1dv\")\n\t}\n\tgpVertexAttrib1dvARB = (C.GPVERTEXATTRIB1DVARB)(getProcAddr(\"glVertexAttrib1dvARB\"))\n\tgpVertexAttrib1dvNV = (C.GPVERTEXATTRIB1DVNV)(getProcAddr(\"glVertexAttrib1dvNV\"))\n\tgpVertexAttrib1f = (C.GPVERTEXATTRIB1F)(getProcAddr(\"glVertexAttrib1f\"))\n\tif gpVertexAttrib1f == nil {\n\t\treturn errors.New(\"glVertexAttrib1f\")\n\t}\n\tgpVertexAttrib1fARB = (C.GPVERTEXATTRIB1FARB)(getProcAddr(\"glVertexAttrib1fARB\"))\n\tgpVertexAttrib1fNV = (C.GPVERTEXATTRIB1FNV)(getProcAddr(\"glVertexAttrib1fNV\"))\n\tgpVertexAttrib1fv = (C.GPVERTEXATTRIB1FV)(getProcAddr(\"glVertexAttrib1fv\"))\n\tif gpVertexAttrib1fv == nil {\n\t\treturn errors.New(\"glVertexAttrib1fv\")\n\t}\n\tgpVertexAttrib1fvARB = (C.GPVERTEXATTRIB1FVARB)(getProcAddr(\"glVertexAttrib1fvARB\"))\n\tgpVertexAttrib1fvNV = (C.GPVERTEXATTRIB1FVNV)(getProcAddr(\"glVertexAttrib1fvNV\"))\n\tgpVertexAttrib1hNV = (C.GPVERTEXATTRIB1HNV)(getProcAddr(\"glVertexAttrib1hNV\"))\n\tgpVertexAttrib1hvNV = (C.GPVERTEXATTRIB1HVNV)(getProcAddr(\"glVertexAttrib1hvNV\"))\n\tgpVertexAttrib1s = (C.GPVERTEXATTRIB1S)(getProcAddr(\"glVertexAttrib1s\"))\n\tif gpVertexAttrib1s == nil {\n\t\treturn errors.New(\"glVertexAttrib1s\")\n\t}\n\tgpVertexAttrib1sARB = (C.GPVERTEXATTRIB1SARB)(getProcAddr(\"glVertexAttrib1sARB\"))\n\tgpVertexAttrib1sNV = (C.GPVERTEXATTRIB1SNV)(getProcAddr(\"glVertexAttrib1sNV\"))\n\tgpVertexAttrib1sv = (C.GPVERTEXATTRIB1SV)(getProcAddr(\"glVertexAttrib1sv\"))\n\tif gpVertexAttrib1sv == nil {\n\t\treturn errors.New(\"glVertexAttrib1sv\")\n\t}\n\tgpVertexAttrib1svARB = (C.GPVERTEXATTRIB1SVARB)(getProcAddr(\"glVertexAttrib1svARB\"))\n\tgpVertexAttrib1svNV = (C.GPVERTEXATTRIB1SVNV)(getProcAddr(\"glVertexAttrib1svNV\"))\n\tgpVertexAttrib2d = (C.GPVERTEXATTRIB2D)(getProcAddr(\"glVertexAttrib2d\"))\n\tif gpVertexAttrib2d == nil {\n\t\treturn errors.New(\"glVertexAttrib2d\")\n\t}\n\tgpVertexAttrib2dARB = (C.GPVERTEXATTRIB2DARB)(getProcAddr(\"glVertexAttrib2dARB\"))\n\tgpVertexAttrib2dNV = (C.GPVERTEXATTRIB2DNV)(getProcAddr(\"glVertexAttrib2dNV\"))\n\tgpVertexAttrib2dv = (C.GPVERTEXATTRIB2DV)(getProcAddr(\"glVertexAttrib2dv\"))\n\tif gpVertexAttrib2dv == nil {\n\t\treturn errors.New(\"glVertexAttrib2dv\")\n\t}\n\tgpVertexAttrib2dvARB = (C.GPVERTEXATTRIB2DVARB)(getProcAddr(\"glVertexAttrib2dvARB\"))\n\tgpVertexAttrib2dvNV = (C.GPVERTEXATTRIB2DVNV)(getProcAddr(\"glVertexAttrib2dvNV\"))\n\tgpVertexAttrib2f = (C.GPVERTEXATTRIB2F)(getProcAddr(\"glVertexAttrib2f\"))\n\tif gpVertexAttrib2f == nil {\n\t\treturn errors.New(\"glVertexAttrib2f\")\n\t}\n\tgpVertexAttrib2fARB = (C.GPVERTEXATTRIB2FARB)(getProcAddr(\"glVertexAttrib2fARB\"))\n\tgpVertexAttrib2fNV = (C.GPVERTEXATTRIB2FNV)(getProcAddr(\"glVertexAttrib2fNV\"))\n\tgpVertexAttrib2fv = (C.GPVERTEXATTRIB2FV)(getProcAddr(\"glVertexAttrib2fv\"))\n\tif gpVertexAttrib2fv == nil {\n\t\treturn errors.New(\"glVertexAttrib2fv\")\n\t}\n\tgpVertexAttrib2fvARB = (C.GPVERTEXATTRIB2FVARB)(getProcAddr(\"glVertexAttrib2fvARB\"))\n\tgpVertexAttrib2fvNV = (C.GPVERTEXATTRIB2FVNV)(getProcAddr(\"glVertexAttrib2fvNV\"))\n\tgpVertexAttrib2hNV = (C.GPVERTEXATTRIB2HNV)(getProcAddr(\"glVertexAttrib2hNV\"))\n\tgpVertexAttrib2hvNV = (C.GPVERTEXATTRIB2HVNV)(getProcAddr(\"glVertexAttrib2hvNV\"))\n\tgpVertexAttrib2s = (C.GPVERTEXATTRIB2S)(getProcAddr(\"glVertexAttrib2s\"))\n\tif gpVertexAttrib2s == nil {\n\t\treturn errors.New(\"glVertexAttrib2s\")\n\t}\n\tgpVertexAttrib2sARB = (C.GPVERTEXATTRIB2SARB)(getProcAddr(\"glVertexAttrib2sARB\"))\n\tgpVertexAttrib2sNV = (C.GPVERTEXATTRIB2SNV)(getProcAddr(\"glVertexAttrib2sNV\"))\n\tgpVertexAttrib2sv = (C.GPVERTEXATTRIB2SV)(getProcAddr(\"glVertexAttrib2sv\"))\n\tif gpVertexAttrib2sv == nil {\n\t\treturn errors.New(\"glVertexAttrib2sv\")\n\t}\n\tgpVertexAttrib2svARB = (C.GPVERTEXATTRIB2SVARB)(getProcAddr(\"glVertexAttrib2svARB\"))\n\tgpVertexAttrib2svNV = (C.GPVERTEXATTRIB2SVNV)(getProcAddr(\"glVertexAttrib2svNV\"))\n\tgpVertexAttrib3d = (C.GPVERTEXATTRIB3D)(getProcAddr(\"glVertexAttrib3d\"))\n\tif gpVertexAttrib3d == nil {\n\t\treturn errors.New(\"glVertexAttrib3d\")\n\t}\n\tgpVertexAttrib3dARB = (C.GPVERTEXATTRIB3DARB)(getProcAddr(\"glVertexAttrib3dARB\"))\n\tgpVertexAttrib3dNV = (C.GPVERTEXATTRIB3DNV)(getProcAddr(\"glVertexAttrib3dNV\"))\n\tgpVertexAttrib3dv = (C.GPVERTEXATTRIB3DV)(getProcAddr(\"glVertexAttrib3dv\"))\n\tif gpVertexAttrib3dv == nil {\n\t\treturn errors.New(\"glVertexAttrib3dv\")\n\t}\n\tgpVertexAttrib3dvARB = (C.GPVERTEXATTRIB3DVARB)(getProcAddr(\"glVertexAttrib3dvARB\"))\n\tgpVertexAttrib3dvNV = (C.GPVERTEXATTRIB3DVNV)(getProcAddr(\"glVertexAttrib3dvNV\"))\n\tgpVertexAttrib3f = (C.GPVERTEXATTRIB3F)(getProcAddr(\"glVertexAttrib3f\"))\n\tif gpVertexAttrib3f == nil {\n\t\treturn errors.New(\"glVertexAttrib3f\")\n\t}\n\tgpVertexAttrib3fARB = (C.GPVERTEXATTRIB3FARB)(getProcAddr(\"glVertexAttrib3fARB\"))\n\tgpVertexAttrib3fNV = (C.GPVERTEXATTRIB3FNV)(getProcAddr(\"glVertexAttrib3fNV\"))\n\tgpVertexAttrib3fv = (C.GPVERTEXATTRIB3FV)(getProcAddr(\"glVertexAttrib3fv\"))\n\tif gpVertexAttrib3fv == nil {\n\t\treturn errors.New(\"glVertexAttrib3fv\")\n\t}\n\tgpVertexAttrib3fvARB = (C.GPVERTEXATTRIB3FVARB)(getProcAddr(\"glVertexAttrib3fvARB\"))\n\tgpVertexAttrib3fvNV = (C.GPVERTEXATTRIB3FVNV)(getProcAddr(\"glVertexAttrib3fvNV\"))\n\tgpVertexAttrib3hNV = (C.GPVERTEXATTRIB3HNV)(getProcAddr(\"glVertexAttrib3hNV\"))\n\tgpVertexAttrib3hvNV = (C.GPVERTEXATTRIB3HVNV)(getProcAddr(\"glVertexAttrib3hvNV\"))\n\tgpVertexAttrib3s = (C.GPVERTEXATTRIB3S)(getProcAddr(\"glVertexAttrib3s\"))\n\tif gpVertexAttrib3s == nil {\n\t\treturn errors.New(\"glVertexAttrib3s\")\n\t}\n\tgpVertexAttrib3sARB = (C.GPVERTEXATTRIB3SARB)(getProcAddr(\"glVertexAttrib3sARB\"))\n\tgpVertexAttrib3sNV = (C.GPVERTEXATTRIB3SNV)(getProcAddr(\"glVertexAttrib3sNV\"))\n\tgpVertexAttrib3sv = (C.GPVERTEXATTRIB3SV)(getProcAddr(\"glVertexAttrib3sv\"))\n\tif gpVertexAttrib3sv == nil {\n\t\treturn errors.New(\"glVertexAttrib3sv\")\n\t}\n\tgpVertexAttrib3svARB = (C.GPVERTEXATTRIB3SVARB)(getProcAddr(\"glVertexAttrib3svARB\"))\n\tgpVertexAttrib3svNV = (C.GPVERTEXATTRIB3SVNV)(getProcAddr(\"glVertexAttrib3svNV\"))\n\tgpVertexAttrib4Nbv = (C.GPVERTEXATTRIB4NBV)(getProcAddr(\"glVertexAttrib4Nbv\"))\n\tif gpVertexAttrib4Nbv == nil {\n\t\treturn errors.New(\"glVertexAttrib4Nbv\")\n\t}\n\tgpVertexAttrib4NbvARB = (C.GPVERTEXATTRIB4NBVARB)(getProcAddr(\"glVertexAttrib4NbvARB\"))\n\tgpVertexAttrib4Niv = (C.GPVERTEXATTRIB4NIV)(getProcAddr(\"glVertexAttrib4Niv\"))\n\tif gpVertexAttrib4Niv == nil {\n\t\treturn errors.New(\"glVertexAttrib4Niv\")\n\t}\n\tgpVertexAttrib4NivARB = (C.GPVERTEXATTRIB4NIVARB)(getProcAddr(\"glVertexAttrib4NivARB\"))\n\tgpVertexAttrib4Nsv = (C.GPVERTEXATTRIB4NSV)(getProcAddr(\"glVertexAttrib4Nsv\"))\n\tif gpVertexAttrib4Nsv == nil {\n\t\treturn errors.New(\"glVertexAttrib4Nsv\")\n\t}\n\tgpVertexAttrib4NsvARB = (C.GPVERTEXATTRIB4NSVARB)(getProcAddr(\"glVertexAttrib4NsvARB\"))\n\tgpVertexAttrib4Nub = (C.GPVERTEXATTRIB4NUB)(getProcAddr(\"glVertexAttrib4Nub\"))\n\tif gpVertexAttrib4Nub == nil {\n\t\treturn errors.New(\"glVertexAttrib4Nub\")\n\t}\n\tgpVertexAttrib4NubARB = (C.GPVERTEXATTRIB4NUBARB)(getProcAddr(\"glVertexAttrib4NubARB\"))\n\tgpVertexAttrib4Nubv = (C.GPVERTEXATTRIB4NUBV)(getProcAddr(\"glVertexAttrib4Nubv\"))\n\tif gpVertexAttrib4Nubv == nil {\n\t\treturn errors.New(\"glVertexAttrib4Nubv\")\n\t}\n\tgpVertexAttrib4NubvARB = (C.GPVERTEXATTRIB4NUBVARB)(getProcAddr(\"glVertexAttrib4NubvARB\"))\n\tgpVertexAttrib4Nuiv = (C.GPVERTEXATTRIB4NUIV)(getProcAddr(\"glVertexAttrib4Nuiv\"))\n\tif gpVertexAttrib4Nuiv == nil {\n\t\treturn errors.New(\"glVertexAttrib4Nuiv\")\n\t}\n\tgpVertexAttrib4NuivARB = (C.GPVERTEXATTRIB4NUIVARB)(getProcAddr(\"glVertexAttrib4NuivARB\"))\n\tgpVertexAttrib4Nusv = (C.GPVERTEXATTRIB4NUSV)(getProcAddr(\"glVertexAttrib4Nusv\"))\n\tif gpVertexAttrib4Nusv == nil {\n\t\treturn errors.New(\"glVertexAttrib4Nusv\")\n\t}\n\tgpVertexAttrib4NusvARB = (C.GPVERTEXATTRIB4NUSVARB)(getProcAddr(\"glVertexAttrib4NusvARB\"))\n\tgpVertexAttrib4bv = (C.GPVERTEXATTRIB4BV)(getProcAddr(\"glVertexAttrib4bv\"))\n\tif gpVertexAttrib4bv == nil {\n\t\treturn errors.New(\"glVertexAttrib4bv\")\n\t}\n\tgpVertexAttrib4bvARB = (C.GPVERTEXATTRIB4BVARB)(getProcAddr(\"glVertexAttrib4bvARB\"))\n\tgpVertexAttrib4d = (C.GPVERTEXATTRIB4D)(getProcAddr(\"glVertexAttrib4d\"))\n\tif gpVertexAttrib4d == nil {\n\t\treturn errors.New(\"glVertexAttrib4d\")\n\t}\n\tgpVertexAttrib4dARB = (C.GPVERTEXATTRIB4DARB)(getProcAddr(\"glVertexAttrib4dARB\"))\n\tgpVertexAttrib4dNV = (C.GPVERTEXATTRIB4DNV)(getProcAddr(\"glVertexAttrib4dNV\"))\n\tgpVertexAttrib4dv = (C.GPVERTEXATTRIB4DV)(getProcAddr(\"glVertexAttrib4dv\"))\n\tif gpVertexAttrib4dv == nil {\n\t\treturn errors.New(\"glVertexAttrib4dv\")\n\t}\n\tgpVertexAttrib4dvARB = (C.GPVERTEXATTRIB4DVARB)(getProcAddr(\"glVertexAttrib4dvARB\"))\n\tgpVertexAttrib4dvNV = (C.GPVERTEXATTRIB4DVNV)(getProcAddr(\"glVertexAttrib4dvNV\"))\n\tgpVertexAttrib4f = (C.GPVERTEXATTRIB4F)(getProcAddr(\"glVertexAttrib4f\"))\n\tif gpVertexAttrib4f == nil {\n\t\treturn errors.New(\"glVertexAttrib4f\")\n\t}\n\tgpVertexAttrib4fARB = (C.GPVERTEXATTRIB4FARB)(getProcAddr(\"glVertexAttrib4fARB\"))\n\tgpVertexAttrib4fNV = (C.GPVERTEXATTRIB4FNV)(getProcAddr(\"glVertexAttrib4fNV\"))\n\tgpVertexAttrib4fv = (C.GPVERTEXATTRIB4FV)(getProcAddr(\"glVertexAttrib4fv\"))\n\tif gpVertexAttrib4fv == nil {\n\t\treturn errors.New(\"glVertexAttrib4fv\")\n\t}\n\tgpVertexAttrib4fvARB = (C.GPVERTEXATTRIB4FVARB)(getProcAddr(\"glVertexAttrib4fvARB\"))\n\tgpVertexAttrib4fvNV = (C.GPVERTEXATTRIB4FVNV)(getProcAddr(\"glVertexAttrib4fvNV\"))\n\tgpVertexAttrib4hNV = (C.GPVERTEXATTRIB4HNV)(getProcAddr(\"glVertexAttrib4hNV\"))\n\tgpVertexAttrib4hvNV = (C.GPVERTEXATTRIB4HVNV)(getProcAddr(\"glVertexAttrib4hvNV\"))\n\tgpVertexAttrib4iv = (C.GPVERTEXATTRIB4IV)(getProcAddr(\"glVertexAttrib4iv\"))\n\tif gpVertexAttrib4iv == nil {\n\t\treturn errors.New(\"glVertexAttrib4iv\")\n\t}\n\tgpVertexAttrib4ivARB = (C.GPVERTEXATTRIB4IVARB)(getProcAddr(\"glVertexAttrib4ivARB\"))\n\tgpVertexAttrib4s = (C.GPVERTEXATTRIB4S)(getProcAddr(\"glVertexAttrib4s\"))\n\tif gpVertexAttrib4s == nil {\n\t\treturn errors.New(\"glVertexAttrib4s\")\n\t}\n\tgpVertexAttrib4sARB = (C.GPVERTEXATTRIB4SARB)(getProcAddr(\"glVertexAttrib4sARB\"))\n\tgpVertexAttrib4sNV = (C.GPVERTEXATTRIB4SNV)(getProcAddr(\"glVertexAttrib4sNV\"))\n\tgpVertexAttrib4sv = (C.GPVERTEXATTRIB4SV)(getProcAddr(\"glVertexAttrib4sv\"))\n\tif gpVertexAttrib4sv == nil {\n\t\treturn errors.New(\"glVertexAttrib4sv\")\n\t}\n\tgpVertexAttrib4svARB = (C.GPVERTEXATTRIB4SVARB)(getProcAddr(\"glVertexAttrib4svARB\"))\n\tgpVertexAttrib4svNV = (C.GPVERTEXATTRIB4SVNV)(getProcAddr(\"glVertexAttrib4svNV\"))\n\tgpVertexAttrib4ubNV = (C.GPVERTEXATTRIB4UBNV)(getProcAddr(\"glVertexAttrib4ubNV\"))\n\tgpVertexAttrib4ubv = (C.GPVERTEXATTRIB4UBV)(getProcAddr(\"glVertexAttrib4ubv\"))\n\tif gpVertexAttrib4ubv == nil {\n\t\treturn errors.New(\"glVertexAttrib4ubv\")\n\t}\n\tgpVertexAttrib4ubvARB = (C.GPVERTEXATTRIB4UBVARB)(getProcAddr(\"glVertexAttrib4ubvARB\"))\n\tgpVertexAttrib4ubvNV = (C.GPVERTEXATTRIB4UBVNV)(getProcAddr(\"glVertexAttrib4ubvNV\"))\n\tgpVertexAttrib4uiv = (C.GPVERTEXATTRIB4UIV)(getProcAddr(\"glVertexAttrib4uiv\"))\n\tif gpVertexAttrib4uiv == nil {\n\t\treturn errors.New(\"glVertexAttrib4uiv\")\n\t}\n\tgpVertexAttrib4uivARB = (C.GPVERTEXATTRIB4UIVARB)(getProcAddr(\"glVertexAttrib4uivARB\"))\n\tgpVertexAttrib4usv = (C.GPVERTEXATTRIB4USV)(getProcAddr(\"glVertexAttrib4usv\"))\n\tif gpVertexAttrib4usv == nil {\n\t\treturn errors.New(\"glVertexAttrib4usv\")\n\t}\n\tgpVertexAttrib4usvARB = (C.GPVERTEXATTRIB4USVARB)(getProcAddr(\"glVertexAttrib4usvARB\"))\n\tgpVertexAttribArrayObjectATI = (C.GPVERTEXATTRIBARRAYOBJECTATI)(getProcAddr(\"glVertexAttribArrayObjectATI\"))\n\tgpVertexAttribBinding = (C.GPVERTEXATTRIBBINDING)(getProcAddr(\"glVertexAttribBinding\"))\n\tif gpVertexAttribBinding == nil {\n\t\treturn errors.New(\"glVertexAttribBinding\")\n\t}\n\tgpVertexAttribDivisor = (C.GPVERTEXATTRIBDIVISOR)(getProcAddr(\"glVertexAttribDivisor\"))\n\tif gpVertexAttribDivisor == nil {\n\t\treturn errors.New(\"glVertexAttribDivisor\")\n\t}\n\tgpVertexAttribDivisorARB = (C.GPVERTEXATTRIBDIVISORARB)(getProcAddr(\"glVertexAttribDivisorARB\"))\n\tgpVertexAttribFormat = (C.GPVERTEXATTRIBFORMAT)(getProcAddr(\"glVertexAttribFormat\"))\n\tif gpVertexAttribFormat == nil {\n\t\treturn errors.New(\"glVertexAttribFormat\")\n\t}\n\tgpVertexAttribFormatNV = (C.GPVERTEXATTRIBFORMATNV)(getProcAddr(\"glVertexAttribFormatNV\"))\n\tgpVertexAttribI1i = (C.GPVERTEXATTRIBI1I)(getProcAddr(\"glVertexAttribI1i\"))\n\tif gpVertexAttribI1i == nil {\n\t\treturn errors.New(\"glVertexAttribI1i\")\n\t}\n\tgpVertexAttribI1iEXT = (C.GPVERTEXATTRIBI1IEXT)(getProcAddr(\"glVertexAttribI1iEXT\"))\n\tgpVertexAttribI1iv = (C.GPVERTEXATTRIBI1IV)(getProcAddr(\"glVertexAttribI1iv\"))\n\tif gpVertexAttribI1iv == nil {\n\t\treturn errors.New(\"glVertexAttribI1iv\")\n\t}\n\tgpVertexAttribI1ivEXT = (C.GPVERTEXATTRIBI1IVEXT)(getProcAddr(\"glVertexAttribI1ivEXT\"))\n\tgpVertexAttribI1ui = (C.GPVERTEXATTRIBI1UI)(getProcAddr(\"glVertexAttribI1ui\"))\n\tif gpVertexAttribI1ui == nil {\n\t\treturn errors.New(\"glVertexAttribI1ui\")\n\t}\n\tgpVertexAttribI1uiEXT = (C.GPVERTEXATTRIBI1UIEXT)(getProcAddr(\"glVertexAttribI1uiEXT\"))\n\tgpVertexAttribI1uiv = (C.GPVERTEXATTRIBI1UIV)(getProcAddr(\"glVertexAttribI1uiv\"))\n\tif gpVertexAttribI1uiv == nil {\n\t\treturn errors.New(\"glVertexAttribI1uiv\")\n\t}\n\tgpVertexAttribI1uivEXT = (C.GPVERTEXATTRIBI1UIVEXT)(getProcAddr(\"glVertexAttribI1uivEXT\"))\n\tgpVertexAttribI2i = (C.GPVERTEXATTRIBI2I)(getProcAddr(\"glVertexAttribI2i\"))\n\tif gpVertexAttribI2i == nil {\n\t\treturn errors.New(\"glVertexAttribI2i\")\n\t}\n\tgpVertexAttribI2iEXT = (C.GPVERTEXATTRIBI2IEXT)(getProcAddr(\"glVertexAttribI2iEXT\"))\n\tgpVertexAttribI2iv = (C.GPVERTEXATTRIBI2IV)(getProcAddr(\"glVertexAttribI2iv\"))\n\tif gpVertexAttribI2iv == nil {\n\t\treturn errors.New(\"glVertexAttribI2iv\")\n\t}\n\tgpVertexAttribI2ivEXT = (C.GPVERTEXATTRIBI2IVEXT)(getProcAddr(\"glVertexAttribI2ivEXT\"))\n\tgpVertexAttribI2ui = (C.GPVERTEXATTRIBI2UI)(getProcAddr(\"glVertexAttribI2ui\"))\n\tif gpVertexAttribI2ui == nil {\n\t\treturn errors.New(\"glVertexAttribI2ui\")\n\t}\n\tgpVertexAttribI2uiEXT = (C.GPVERTEXATTRIBI2UIEXT)(getProcAddr(\"glVertexAttribI2uiEXT\"))\n\tgpVertexAttribI2uiv = (C.GPVERTEXATTRIBI2UIV)(getProcAddr(\"glVertexAttribI2uiv\"))\n\tif gpVertexAttribI2uiv == nil {\n\t\treturn errors.New(\"glVertexAttribI2uiv\")\n\t}\n\tgpVertexAttribI2uivEXT = (C.GPVERTEXATTRIBI2UIVEXT)(getProcAddr(\"glVertexAttribI2uivEXT\"))\n\tgpVertexAttribI3i = (C.GPVERTEXATTRIBI3I)(getProcAddr(\"glVertexAttribI3i\"))\n\tif gpVertexAttribI3i == nil {\n\t\treturn errors.New(\"glVertexAttribI3i\")\n\t}\n\tgpVertexAttribI3iEXT = (C.GPVERTEXATTRIBI3IEXT)(getProcAddr(\"glVertexAttribI3iEXT\"))\n\tgpVertexAttribI3iv = (C.GPVERTEXATTRIBI3IV)(getProcAddr(\"glVertexAttribI3iv\"))\n\tif gpVertexAttribI3iv == nil {\n\t\treturn errors.New(\"glVertexAttribI3iv\")\n\t}\n\tgpVertexAttribI3ivEXT = (C.GPVERTEXATTRIBI3IVEXT)(getProcAddr(\"glVertexAttribI3ivEXT\"))\n\tgpVertexAttribI3ui = (C.GPVERTEXATTRIBI3UI)(getProcAddr(\"glVertexAttribI3ui\"))\n\tif gpVertexAttribI3ui == nil {\n\t\treturn errors.New(\"glVertexAttribI3ui\")\n\t}\n\tgpVertexAttribI3uiEXT = (C.GPVERTEXATTRIBI3UIEXT)(getProcAddr(\"glVertexAttribI3uiEXT\"))\n\tgpVertexAttribI3uiv = (C.GPVERTEXATTRIBI3UIV)(getProcAddr(\"glVertexAttribI3uiv\"))\n\tif gpVertexAttribI3uiv == nil {\n\t\treturn errors.New(\"glVertexAttribI3uiv\")\n\t}\n\tgpVertexAttribI3uivEXT = (C.GPVERTEXATTRIBI3UIVEXT)(getProcAddr(\"glVertexAttribI3uivEXT\"))\n\tgpVertexAttribI4bv = (C.GPVERTEXATTRIBI4BV)(getProcAddr(\"glVertexAttribI4bv\"))\n\tif gpVertexAttribI4bv == nil {\n\t\treturn errors.New(\"glVertexAttribI4bv\")\n\t}\n\tgpVertexAttribI4bvEXT = (C.GPVERTEXATTRIBI4BVEXT)(getProcAddr(\"glVertexAttribI4bvEXT\"))\n\tgpVertexAttribI4i = (C.GPVERTEXATTRIBI4I)(getProcAddr(\"glVertexAttribI4i\"))\n\tif gpVertexAttribI4i == nil {\n\t\treturn errors.New(\"glVertexAttribI4i\")\n\t}\n\tgpVertexAttribI4iEXT = (C.GPVERTEXATTRIBI4IEXT)(getProcAddr(\"glVertexAttribI4iEXT\"))\n\tgpVertexAttribI4iv = (C.GPVERTEXATTRIBI4IV)(getProcAddr(\"glVertexAttribI4iv\"))\n\tif gpVertexAttribI4iv == nil {\n\t\treturn errors.New(\"glVertexAttribI4iv\")\n\t}\n\tgpVertexAttribI4ivEXT = (C.GPVERTEXATTRIBI4IVEXT)(getProcAddr(\"glVertexAttribI4ivEXT\"))\n\tgpVertexAttribI4sv = (C.GPVERTEXATTRIBI4SV)(getProcAddr(\"glVertexAttribI4sv\"))\n\tif gpVertexAttribI4sv == nil {\n\t\treturn errors.New(\"glVertexAttribI4sv\")\n\t}\n\tgpVertexAttribI4svEXT = (C.GPVERTEXATTRIBI4SVEXT)(getProcAddr(\"glVertexAttribI4svEXT\"))\n\tgpVertexAttribI4ubv = (C.GPVERTEXATTRIBI4UBV)(getProcAddr(\"glVertexAttribI4ubv\"))\n\tif gpVertexAttribI4ubv == nil {\n\t\treturn errors.New(\"glVertexAttribI4ubv\")\n\t}\n\tgpVertexAttribI4ubvEXT = (C.GPVERTEXATTRIBI4UBVEXT)(getProcAddr(\"glVertexAttribI4ubvEXT\"))\n\tgpVertexAttribI4ui = (C.GPVERTEXATTRIBI4UI)(getProcAddr(\"glVertexAttribI4ui\"))\n\tif gpVertexAttribI4ui == nil {\n\t\treturn errors.New(\"glVertexAttribI4ui\")\n\t}\n\tgpVertexAttribI4uiEXT = (C.GPVERTEXATTRIBI4UIEXT)(getProcAddr(\"glVertexAttribI4uiEXT\"))\n\tgpVertexAttribI4uiv = (C.GPVERTEXATTRIBI4UIV)(getProcAddr(\"glVertexAttribI4uiv\"))\n\tif gpVertexAttribI4uiv == nil {\n\t\treturn errors.New(\"glVertexAttribI4uiv\")\n\t}\n\tgpVertexAttribI4uivEXT = (C.GPVERTEXATTRIBI4UIVEXT)(getProcAddr(\"glVertexAttribI4uivEXT\"))\n\tgpVertexAttribI4usv = (C.GPVERTEXATTRIBI4USV)(getProcAddr(\"glVertexAttribI4usv\"))\n\tif gpVertexAttribI4usv == nil {\n\t\treturn errors.New(\"glVertexAttribI4usv\")\n\t}\n\tgpVertexAttribI4usvEXT = (C.GPVERTEXATTRIBI4USVEXT)(getProcAddr(\"glVertexAttribI4usvEXT\"))\n\tgpVertexAttribIFormat = (C.GPVERTEXATTRIBIFORMAT)(getProcAddr(\"glVertexAttribIFormat\"))\n\tif gpVertexAttribIFormat == nil {\n\t\treturn errors.New(\"glVertexAttribIFormat\")\n\t}\n\tgpVertexAttribIFormatNV = (C.GPVERTEXATTRIBIFORMATNV)(getProcAddr(\"glVertexAttribIFormatNV\"))\n\tgpVertexAttribIPointer = (C.GPVERTEXATTRIBIPOINTER)(getProcAddr(\"glVertexAttribIPointer\"))\n\tif gpVertexAttribIPointer == nil {\n\t\treturn errors.New(\"glVertexAttribIPointer\")\n\t}\n\tgpVertexAttribIPointerEXT = (C.GPVERTEXATTRIBIPOINTEREXT)(getProcAddr(\"glVertexAttribIPointerEXT\"))\n\tgpVertexAttribL1d = (C.GPVERTEXATTRIBL1D)(getProcAddr(\"glVertexAttribL1d\"))\n\tif gpVertexAttribL1d == nil {\n\t\treturn errors.New(\"glVertexAttribL1d\")\n\t}\n\tgpVertexAttribL1dEXT = (C.GPVERTEXATTRIBL1DEXT)(getProcAddr(\"glVertexAttribL1dEXT\"))\n\tgpVertexAttribL1dv = (C.GPVERTEXATTRIBL1DV)(getProcAddr(\"glVertexAttribL1dv\"))\n\tif gpVertexAttribL1dv == nil {\n\t\treturn errors.New(\"glVertexAttribL1dv\")\n\t}\n\tgpVertexAttribL1dvEXT = (C.GPVERTEXATTRIBL1DVEXT)(getProcAddr(\"glVertexAttribL1dvEXT\"))\n\tgpVertexAttribL1i64NV = (C.GPVERTEXATTRIBL1I64NV)(getProcAddr(\"glVertexAttribL1i64NV\"))\n\tgpVertexAttribL1i64vNV = (C.GPVERTEXATTRIBL1I64VNV)(getProcAddr(\"glVertexAttribL1i64vNV\"))\n\tgpVertexAttribL1ui64ARB = (C.GPVERTEXATTRIBL1UI64ARB)(getProcAddr(\"glVertexAttribL1ui64ARB\"))\n\tgpVertexAttribL1ui64NV = (C.GPVERTEXATTRIBL1UI64NV)(getProcAddr(\"glVertexAttribL1ui64NV\"))\n\tgpVertexAttribL1ui64vARB = (C.GPVERTEXATTRIBL1UI64VARB)(getProcAddr(\"glVertexAttribL1ui64vARB\"))\n\tgpVertexAttribL1ui64vNV = (C.GPVERTEXATTRIBL1UI64VNV)(getProcAddr(\"glVertexAttribL1ui64vNV\"))\n\tgpVertexAttribL2d = (C.GPVERTEXATTRIBL2D)(getProcAddr(\"glVertexAttribL2d\"))\n\tif gpVertexAttribL2d == nil {\n\t\treturn errors.New(\"glVertexAttribL2d\")\n\t}\n\tgpVertexAttribL2dEXT = (C.GPVERTEXATTRIBL2DEXT)(getProcAddr(\"glVertexAttribL2dEXT\"))\n\tgpVertexAttribL2dv = (C.GPVERTEXATTRIBL2DV)(getProcAddr(\"glVertexAttribL2dv\"))\n\tif gpVertexAttribL2dv == nil {\n\t\treturn errors.New(\"glVertexAttribL2dv\")\n\t}\n\tgpVertexAttribL2dvEXT = (C.GPVERTEXATTRIBL2DVEXT)(getProcAddr(\"glVertexAttribL2dvEXT\"))\n\tgpVertexAttribL2i64NV = (C.GPVERTEXATTRIBL2I64NV)(getProcAddr(\"glVertexAttribL2i64NV\"))\n\tgpVertexAttribL2i64vNV = (C.GPVERTEXATTRIBL2I64VNV)(getProcAddr(\"glVertexAttribL2i64vNV\"))\n\tgpVertexAttribL2ui64NV = (C.GPVERTEXATTRIBL2UI64NV)(getProcAddr(\"glVertexAttribL2ui64NV\"))\n\tgpVertexAttribL2ui64vNV = (C.GPVERTEXATTRIBL2UI64VNV)(getProcAddr(\"glVertexAttribL2ui64vNV\"))\n\tgpVertexAttribL3d = (C.GPVERTEXATTRIBL3D)(getProcAddr(\"glVertexAttribL3d\"))\n\tif gpVertexAttribL3d == nil {\n\t\treturn errors.New(\"glVertexAttribL3d\")\n\t}\n\tgpVertexAttribL3dEXT = (C.GPVERTEXATTRIBL3DEXT)(getProcAddr(\"glVertexAttribL3dEXT\"))\n\tgpVertexAttribL3dv = (C.GPVERTEXATTRIBL3DV)(getProcAddr(\"glVertexAttribL3dv\"))\n\tif gpVertexAttribL3dv == nil {\n\t\treturn errors.New(\"glVertexAttribL3dv\")\n\t}\n\tgpVertexAttribL3dvEXT = (C.GPVERTEXATTRIBL3DVEXT)(getProcAddr(\"glVertexAttribL3dvEXT\"))\n\tgpVertexAttribL3i64NV = (C.GPVERTEXATTRIBL3I64NV)(getProcAddr(\"glVertexAttribL3i64NV\"))\n\tgpVertexAttribL3i64vNV = (C.GPVERTEXATTRIBL3I64VNV)(getProcAddr(\"glVertexAttribL3i64vNV\"))\n\tgpVertexAttribL3ui64NV = (C.GPVERTEXATTRIBL3UI64NV)(getProcAddr(\"glVertexAttribL3ui64NV\"))\n\tgpVertexAttribL3ui64vNV = (C.GPVERTEXATTRIBL3UI64VNV)(getProcAddr(\"glVertexAttribL3ui64vNV\"))\n\tgpVertexAttribL4d = (C.GPVERTEXATTRIBL4D)(getProcAddr(\"glVertexAttribL4d\"))\n\tif gpVertexAttribL4d == nil {\n\t\treturn errors.New(\"glVertexAttribL4d\")\n\t}\n\tgpVertexAttribL4dEXT = (C.GPVERTEXATTRIBL4DEXT)(getProcAddr(\"glVertexAttribL4dEXT\"))\n\tgpVertexAttribL4dv = (C.GPVERTEXATTRIBL4DV)(getProcAddr(\"glVertexAttribL4dv\"))\n\tif gpVertexAttribL4dv == nil {\n\t\treturn errors.New(\"glVertexAttribL4dv\")\n\t}\n\tgpVertexAttribL4dvEXT = (C.GPVERTEXATTRIBL4DVEXT)(getProcAddr(\"glVertexAttribL4dvEXT\"))\n\tgpVertexAttribL4i64NV = (C.GPVERTEXATTRIBL4I64NV)(getProcAddr(\"glVertexAttribL4i64NV\"))\n\tgpVertexAttribL4i64vNV = (C.GPVERTEXATTRIBL4I64VNV)(getProcAddr(\"glVertexAttribL4i64vNV\"))\n\tgpVertexAttribL4ui64NV = (C.GPVERTEXATTRIBL4UI64NV)(getProcAddr(\"glVertexAttribL4ui64NV\"))\n\tgpVertexAttribL4ui64vNV = (C.GPVERTEXATTRIBL4UI64VNV)(getProcAddr(\"glVertexAttribL4ui64vNV\"))\n\tgpVertexAttribLFormat = (C.GPVERTEXATTRIBLFORMAT)(getProcAddr(\"glVertexAttribLFormat\"))\n\tif gpVertexAttribLFormat == nil {\n\t\treturn errors.New(\"glVertexAttribLFormat\")\n\t}\n\tgpVertexAttribLFormatNV = (C.GPVERTEXATTRIBLFORMATNV)(getProcAddr(\"glVertexAttribLFormatNV\"))\n\tgpVertexAttribLPointer = (C.GPVERTEXATTRIBLPOINTER)(getProcAddr(\"glVertexAttribLPointer\"))\n\tif gpVertexAttribLPointer == nil {\n\t\treturn errors.New(\"glVertexAttribLPointer\")\n\t}\n\tgpVertexAttribLPointerEXT = (C.GPVERTEXATTRIBLPOINTEREXT)(getProcAddr(\"glVertexAttribLPointerEXT\"))\n\tgpVertexAttribP1ui = (C.GPVERTEXATTRIBP1UI)(getProcAddr(\"glVertexAttribP1ui\"))\n\tif gpVertexAttribP1ui == nil {\n\t\treturn errors.New(\"glVertexAttribP1ui\")\n\t}\n\tgpVertexAttribP1uiv = (C.GPVERTEXATTRIBP1UIV)(getProcAddr(\"glVertexAttribP1uiv\"))\n\tif gpVertexAttribP1uiv == nil {\n\t\treturn errors.New(\"glVertexAttribP1uiv\")\n\t}\n\tgpVertexAttribP2ui = (C.GPVERTEXATTRIBP2UI)(getProcAddr(\"glVertexAttribP2ui\"))\n\tif gpVertexAttribP2ui == nil {\n\t\treturn errors.New(\"glVertexAttribP2ui\")\n\t}\n\tgpVertexAttribP2uiv = (C.GPVERTEXATTRIBP2UIV)(getProcAddr(\"glVertexAttribP2uiv\"))\n\tif gpVertexAttribP2uiv == nil {\n\t\treturn errors.New(\"glVertexAttribP2uiv\")\n\t}\n\tgpVertexAttribP3ui = (C.GPVERTEXATTRIBP3UI)(getProcAddr(\"glVertexAttribP3ui\"))\n\tif gpVertexAttribP3ui == nil {\n\t\treturn errors.New(\"glVertexAttribP3ui\")\n\t}\n\tgpVertexAttribP3uiv = (C.GPVERTEXATTRIBP3UIV)(getProcAddr(\"glVertexAttribP3uiv\"))\n\tif gpVertexAttribP3uiv == nil {\n\t\treturn errors.New(\"glVertexAttribP3uiv\")\n\t}\n\tgpVertexAttribP4ui = (C.GPVERTEXATTRIBP4UI)(getProcAddr(\"glVertexAttribP4ui\"))\n\tif gpVertexAttribP4ui == nil {\n\t\treturn errors.New(\"glVertexAttribP4ui\")\n\t}\n\tgpVertexAttribP4uiv = (C.GPVERTEXATTRIBP4UIV)(getProcAddr(\"glVertexAttribP4uiv\"))\n\tif gpVertexAttribP4uiv == nil {\n\t\treturn errors.New(\"glVertexAttribP4uiv\")\n\t}\n\tgpVertexAttribParameteriAMD = (C.GPVERTEXATTRIBPARAMETERIAMD)(getProcAddr(\"glVertexAttribParameteriAMD\"))\n\tgpVertexAttribPointer = (C.GPVERTEXATTRIBPOINTER)(getProcAddr(\"glVertexAttribPointer\"))\n\tif gpVertexAttribPointer == nil {\n\t\treturn errors.New(\"glVertexAttribPointer\")\n\t}\n\tgpVertexAttribPointerARB = (C.GPVERTEXATTRIBPOINTERARB)(getProcAddr(\"glVertexAttribPointerARB\"))\n\tgpVertexAttribPointerNV = (C.GPVERTEXATTRIBPOINTERNV)(getProcAddr(\"glVertexAttribPointerNV\"))\n\tgpVertexAttribs1dvNV = (C.GPVERTEXATTRIBS1DVNV)(getProcAddr(\"glVertexAttribs1dvNV\"))\n\tgpVertexAttribs1fvNV = (C.GPVERTEXATTRIBS1FVNV)(getProcAddr(\"glVertexAttribs1fvNV\"))\n\tgpVertexAttribs1hvNV = (C.GPVERTEXATTRIBS1HVNV)(getProcAddr(\"glVertexAttribs1hvNV\"))\n\tgpVertexAttribs1svNV = (C.GPVERTEXATTRIBS1SVNV)(getProcAddr(\"glVertexAttribs1svNV\"))\n\tgpVertexAttribs2dvNV = (C.GPVERTEXATTRIBS2DVNV)(getProcAddr(\"glVertexAttribs2dvNV\"))\n\tgpVertexAttribs2fvNV = (C.GPVERTEXATTRIBS2FVNV)(getProcAddr(\"glVertexAttribs2fvNV\"))\n\tgpVertexAttribs2hvNV = (C.GPVERTEXATTRIBS2HVNV)(getProcAddr(\"glVertexAttribs2hvNV\"))\n\tgpVertexAttribs2svNV = (C.GPVERTEXATTRIBS2SVNV)(getProcAddr(\"glVertexAttribs2svNV\"))\n\tgpVertexAttribs3dvNV = (C.GPVERTEXATTRIBS3DVNV)(getProcAddr(\"glVertexAttribs3dvNV\"))\n\tgpVertexAttribs3fvNV = (C.GPVERTEXATTRIBS3FVNV)(getProcAddr(\"glVertexAttribs3fvNV\"))\n\tgpVertexAttribs3hvNV = (C.GPVERTEXATTRIBS3HVNV)(getProcAddr(\"glVertexAttribs3hvNV\"))\n\tgpVertexAttribs3svNV = (C.GPVERTEXATTRIBS3SVNV)(getProcAddr(\"glVertexAttribs3svNV\"))\n\tgpVertexAttribs4dvNV = (C.GPVERTEXATTRIBS4DVNV)(getProcAddr(\"glVertexAttribs4dvNV\"))\n\tgpVertexAttribs4fvNV = (C.GPVERTEXATTRIBS4FVNV)(getProcAddr(\"glVertexAttribs4fvNV\"))\n\tgpVertexAttribs4hvNV = (C.GPVERTEXATTRIBS4HVNV)(getProcAddr(\"glVertexAttribs4hvNV\"))\n\tgpVertexAttribs4svNV = (C.GPVERTEXATTRIBS4SVNV)(getProcAddr(\"glVertexAttribs4svNV\"))\n\tgpVertexAttribs4ubvNV = (C.GPVERTEXATTRIBS4UBVNV)(getProcAddr(\"glVertexAttribs4ubvNV\"))\n\tgpVertexBindingDivisor = (C.GPVERTEXBINDINGDIVISOR)(getProcAddr(\"glVertexBindingDivisor\"))\n\tif gpVertexBindingDivisor == nil {\n\t\treturn errors.New(\"glVertexBindingDivisor\")\n\t}\n\tgpVertexBlendARB = (C.GPVERTEXBLENDARB)(getProcAddr(\"glVertexBlendARB\"))\n\tgpVertexBlendEnvfATI = (C.GPVERTEXBLENDENVFATI)(getProcAddr(\"glVertexBlendEnvfATI\"))\n\tgpVertexBlendEnviATI = (C.GPVERTEXBLENDENVIATI)(getProcAddr(\"glVertexBlendEnviATI\"))\n\tgpVertexFormatNV = (C.GPVERTEXFORMATNV)(getProcAddr(\"glVertexFormatNV\"))\n\tgpVertexP2ui = (C.GPVERTEXP2UI)(getProcAddr(\"glVertexP2ui\"))\n\tif gpVertexP2ui == nil {\n\t\treturn errors.New(\"glVertexP2ui\")\n\t}\n\tgpVertexP2uiv = (C.GPVERTEXP2UIV)(getProcAddr(\"glVertexP2uiv\"))\n\tif gpVertexP2uiv == nil {\n\t\treturn errors.New(\"glVertexP2uiv\")\n\t}\n\tgpVertexP3ui = (C.GPVERTEXP3UI)(getProcAddr(\"glVertexP3ui\"))\n\tif gpVertexP3ui == nil {\n\t\treturn errors.New(\"glVertexP3ui\")\n\t}\n\tgpVertexP3uiv = (C.GPVERTEXP3UIV)(getProcAddr(\"glVertexP3uiv\"))\n\tif gpVertexP3uiv == nil {\n\t\treturn errors.New(\"glVertexP3uiv\")\n\t}\n\tgpVertexP4ui = (C.GPVERTEXP4UI)(getProcAddr(\"glVertexP4ui\"))\n\tif gpVertexP4ui == nil {\n\t\treturn errors.New(\"glVertexP4ui\")\n\t}\n\tgpVertexP4uiv = (C.GPVERTEXP4UIV)(getProcAddr(\"glVertexP4uiv\"))\n\tif gpVertexP4uiv == nil {\n\t\treturn errors.New(\"glVertexP4uiv\")\n\t}\n\tgpVertexPointer = (C.GPVERTEXPOINTER)(getProcAddr(\"glVertexPointer\"))\n\tif gpVertexPointer == nil {\n\t\treturn errors.New(\"glVertexPointer\")\n\t}\n\tgpVertexPointerEXT = (C.GPVERTEXPOINTEREXT)(getProcAddr(\"glVertexPointerEXT\"))\n\tgpVertexPointerListIBM = (C.GPVERTEXPOINTERLISTIBM)(getProcAddr(\"glVertexPointerListIBM\"))\n\tgpVertexPointervINTEL = (C.GPVERTEXPOINTERVINTEL)(getProcAddr(\"glVertexPointervINTEL\"))\n\tgpVertexStream1dATI = (C.GPVERTEXSTREAM1DATI)(getProcAddr(\"glVertexStream1dATI\"))\n\tgpVertexStream1dvATI = (C.GPVERTEXSTREAM1DVATI)(getProcAddr(\"glVertexStream1dvATI\"))\n\tgpVertexStream1fATI = (C.GPVERTEXSTREAM1FATI)(getProcAddr(\"glVertexStream1fATI\"))\n\tgpVertexStream1fvATI = (C.GPVERTEXSTREAM1FVATI)(getProcAddr(\"glVertexStream1fvATI\"))\n\tgpVertexStream1iATI = (C.GPVERTEXSTREAM1IATI)(getProcAddr(\"glVertexStream1iATI\"))\n\tgpVertexStream1ivATI = (C.GPVERTEXSTREAM1IVATI)(getProcAddr(\"glVertexStream1ivATI\"))\n\tgpVertexStream1sATI = (C.GPVERTEXSTREAM1SATI)(getProcAddr(\"glVertexStream1sATI\"))\n\tgpVertexStream1svATI = (C.GPVERTEXSTREAM1SVATI)(getProcAddr(\"glVertexStream1svATI\"))\n\tgpVertexStream2dATI = (C.GPVERTEXSTREAM2DATI)(getProcAddr(\"glVertexStream2dATI\"))\n\tgpVertexStream2dvATI = (C.GPVERTEXSTREAM2DVATI)(getProcAddr(\"glVertexStream2dvATI\"))\n\tgpVertexStream2fATI = (C.GPVERTEXSTREAM2FATI)(getProcAddr(\"glVertexStream2fATI\"))\n\tgpVertexStream2fvATI = (C.GPVERTEXSTREAM2FVATI)(getProcAddr(\"glVertexStream2fvATI\"))\n\tgpVertexStream2iATI = (C.GPVERTEXSTREAM2IATI)(getProcAddr(\"glVertexStream2iATI\"))\n\tgpVertexStream2ivATI = (C.GPVERTEXSTREAM2IVATI)(getProcAddr(\"glVertexStream2ivATI\"))\n\tgpVertexStream2sATI = (C.GPVERTEXSTREAM2SATI)(getProcAddr(\"glVertexStream2sATI\"))\n\tgpVertexStream2svATI = (C.GPVERTEXSTREAM2SVATI)(getProcAddr(\"glVertexStream2svATI\"))\n\tgpVertexStream3dATI = (C.GPVERTEXSTREAM3DATI)(getProcAddr(\"glVertexStream3dATI\"))\n\tgpVertexStream3dvATI = (C.GPVERTEXSTREAM3DVATI)(getProcAddr(\"glVertexStream3dvATI\"))\n\tgpVertexStream3fATI = (C.GPVERTEXSTREAM3FATI)(getProcAddr(\"glVertexStream3fATI\"))\n\tgpVertexStream3fvATI = (C.GPVERTEXSTREAM3FVATI)(getProcAddr(\"glVertexStream3fvATI\"))\n\tgpVertexStream3iATI = (C.GPVERTEXSTREAM3IATI)(getProcAddr(\"glVertexStream3iATI\"))\n\tgpVertexStream3ivATI = (C.GPVERTEXSTREAM3IVATI)(getProcAddr(\"glVertexStream3ivATI\"))\n\tgpVertexStream3sATI = (C.GPVERTEXSTREAM3SATI)(getProcAddr(\"glVertexStream3sATI\"))\n\tgpVertexStream3svATI = (C.GPVERTEXSTREAM3SVATI)(getProcAddr(\"glVertexStream3svATI\"))\n\tgpVertexStream4dATI = (C.GPVERTEXSTREAM4DATI)(getProcAddr(\"glVertexStream4dATI\"))\n\tgpVertexStream4dvATI = (C.GPVERTEXSTREAM4DVATI)(getProcAddr(\"glVertexStream4dvATI\"))\n\tgpVertexStream4fATI = (C.GPVERTEXSTREAM4FATI)(getProcAddr(\"glVertexStream4fATI\"))\n\tgpVertexStream4fvATI = (C.GPVERTEXSTREAM4FVATI)(getProcAddr(\"glVertexStream4fvATI\"))\n\tgpVertexStream4iATI = (C.GPVERTEXSTREAM4IATI)(getProcAddr(\"glVertexStream4iATI\"))\n\tgpVertexStream4ivATI = (C.GPVERTEXSTREAM4IVATI)(getProcAddr(\"glVertexStream4ivATI\"))\n\tgpVertexStream4sATI = (C.GPVERTEXSTREAM4SATI)(getProcAddr(\"glVertexStream4sATI\"))\n\tgpVertexStream4svATI = (C.GPVERTEXSTREAM4SVATI)(getProcAddr(\"glVertexStream4svATI\"))\n\tgpVertexWeightPointerEXT = (C.GPVERTEXWEIGHTPOINTEREXT)(getProcAddr(\"glVertexWeightPointerEXT\"))\n\tgpVertexWeightfEXT = (C.GPVERTEXWEIGHTFEXT)(getProcAddr(\"glVertexWeightfEXT\"))\n\tgpVertexWeightfvEXT = (C.GPVERTEXWEIGHTFVEXT)(getProcAddr(\"glVertexWeightfvEXT\"))\n\tgpVertexWeighthNV = (C.GPVERTEXWEIGHTHNV)(getProcAddr(\"glVertexWeighthNV\"))\n\tgpVertexWeighthvNV = (C.GPVERTEXWEIGHTHVNV)(getProcAddr(\"glVertexWeighthvNV\"))\n\tgpVideoCaptureNV = (C.GPVIDEOCAPTURENV)(getProcAddr(\"glVideoCaptureNV\"))\n\tgpVideoCaptureStreamParameterdvNV = (C.GPVIDEOCAPTURESTREAMPARAMETERDVNV)(getProcAddr(\"glVideoCaptureStreamParameterdvNV\"))\n\tgpVideoCaptureStreamParameterfvNV = (C.GPVIDEOCAPTURESTREAMPARAMETERFVNV)(getProcAddr(\"glVideoCaptureStreamParameterfvNV\"))\n\tgpVideoCaptureStreamParameterivNV = (C.GPVIDEOCAPTURESTREAMPARAMETERIVNV)(getProcAddr(\"glVideoCaptureStreamParameterivNV\"))\n\tgpViewport = (C.GPVIEWPORT)(getProcAddr(\"glViewport\"))\n\tif gpViewport == nil {\n\t\treturn errors.New(\"glViewport\")\n\t}\n\tgpViewportArrayv = (C.GPVIEWPORTARRAYV)(getProcAddr(\"glViewportArrayv\"))\n\tif gpViewportArrayv == nil {\n\t\treturn errors.New(\"glViewportArrayv\")\n\t}\n\tgpViewportIndexedf = (C.GPVIEWPORTINDEXEDF)(getProcAddr(\"glViewportIndexedf\"))\n\tif gpViewportIndexedf == nil {\n\t\treturn errors.New(\"glViewportIndexedf\")\n\t}\n\tgpViewportIndexedfv = (C.GPVIEWPORTINDEXEDFV)(getProcAddr(\"glViewportIndexedfv\"))\n\tif gpViewportIndexedfv == nil {\n\t\treturn errors.New(\"glViewportIndexedfv\")\n\t}\n\tgpViewportPositionWScaleNV = (C.GPVIEWPORTPOSITIONWSCALENV)(getProcAddr(\"glViewportPositionWScaleNV\"))\n\tgpViewportSwizzleNV = (C.GPVIEWPORTSWIZZLENV)(getProcAddr(\"glViewportSwizzleNV\"))\n\tgpWaitSemaphoreEXT = (C.GPWAITSEMAPHOREEXT)(getProcAddr(\"glWaitSemaphoreEXT\"))\n\tgpWaitSemaphoreui64NVX = (C.GPWAITSEMAPHOREUI64NVX)(getProcAddr(\"glWaitSemaphoreui64NVX\"))\n\tgpWaitSync = (C.GPWAITSYNC)(getProcAddr(\"glWaitSync\"))\n\tif gpWaitSync == nil {\n\t\treturn errors.New(\"glWaitSync\")\n\t}\n\tgpWaitVkSemaphoreNV = (C.GPWAITVKSEMAPHORENV)(getProcAddr(\"glWaitVkSemaphoreNV\"))\n\tgpWeightPathsNV = (C.GPWEIGHTPATHSNV)(getProcAddr(\"glWeightPathsNV\"))\n\tgpWeightPointerARB = (C.GPWEIGHTPOINTERARB)(getProcAddr(\"glWeightPointerARB\"))\n\tgpWeightbvARB = (C.GPWEIGHTBVARB)(getProcAddr(\"glWeightbvARB\"))\n\tgpWeightdvARB = (C.GPWEIGHTDVARB)(getProcAddr(\"glWeightdvARB\"))\n\tgpWeightfvARB = (C.GPWEIGHTFVARB)(getProcAddr(\"glWeightfvARB\"))\n\tgpWeightivARB = (C.GPWEIGHTIVARB)(getProcAddr(\"glWeightivARB\"))\n\tgpWeightsvARB = (C.GPWEIGHTSVARB)(getProcAddr(\"glWeightsvARB\"))\n\tgpWeightubvARB = (C.GPWEIGHTUBVARB)(getProcAddr(\"glWeightubvARB\"))\n\tgpWeightuivARB = (C.GPWEIGHTUIVARB)(getProcAddr(\"glWeightuivARB\"))\n\tgpWeightusvARB = (C.GPWEIGHTUSVARB)(getProcAddr(\"glWeightusvARB\"))\n\tgpWindowPos2d = (C.GPWINDOWPOS2D)(getProcAddr(\"glWindowPos2d\"))\n\tif gpWindowPos2d == nil {\n\t\treturn errors.New(\"glWindowPos2d\")\n\t}\n\tgpWindowPos2dARB = (C.GPWINDOWPOS2DARB)(getProcAddr(\"glWindowPos2dARB\"))\n\tgpWindowPos2dMESA = (C.GPWINDOWPOS2DMESA)(getProcAddr(\"glWindowPos2dMESA\"))\n\tgpWindowPos2dv = (C.GPWINDOWPOS2DV)(getProcAddr(\"glWindowPos2dv\"))\n\tif gpWindowPos2dv == nil {\n\t\treturn errors.New(\"glWindowPos2dv\")\n\t}\n\tgpWindowPos2dvARB = (C.GPWINDOWPOS2DVARB)(getProcAddr(\"glWindowPos2dvARB\"))\n\tgpWindowPos2dvMESA = (C.GPWINDOWPOS2DVMESA)(getProcAddr(\"glWindowPos2dvMESA\"))\n\tgpWindowPos2f = (C.GPWINDOWPOS2F)(getProcAddr(\"glWindowPos2f\"))\n\tif gpWindowPos2f == nil {\n\t\treturn errors.New(\"glWindowPos2f\")\n\t}\n\tgpWindowPos2fARB = (C.GPWINDOWPOS2FARB)(getProcAddr(\"glWindowPos2fARB\"))\n\tgpWindowPos2fMESA = (C.GPWINDOWPOS2FMESA)(getProcAddr(\"glWindowPos2fMESA\"))\n\tgpWindowPos2fv = (C.GPWINDOWPOS2FV)(getProcAddr(\"glWindowPos2fv\"))\n\tif gpWindowPos2fv == nil {\n\t\treturn errors.New(\"glWindowPos2fv\")\n\t}\n\tgpWindowPos2fvARB = (C.GPWINDOWPOS2FVARB)(getProcAddr(\"glWindowPos2fvARB\"))\n\tgpWindowPos2fvMESA = (C.GPWINDOWPOS2FVMESA)(getProcAddr(\"glWindowPos2fvMESA\"))\n\tgpWindowPos2i = (C.GPWINDOWPOS2I)(getProcAddr(\"glWindowPos2i\"))\n\tif gpWindowPos2i == nil {\n\t\treturn errors.New(\"glWindowPos2i\")\n\t}\n\tgpWindowPos2iARB = (C.GPWINDOWPOS2IARB)(getProcAddr(\"glWindowPos2iARB\"))\n\tgpWindowPos2iMESA = (C.GPWINDOWPOS2IMESA)(getProcAddr(\"glWindowPos2iMESA\"))\n\tgpWindowPos2iv = (C.GPWINDOWPOS2IV)(getProcAddr(\"glWindowPos2iv\"))\n\tif gpWindowPos2iv == nil {\n\t\treturn errors.New(\"glWindowPos2iv\")\n\t}\n\tgpWindowPos2ivARB = (C.GPWINDOWPOS2IVARB)(getProcAddr(\"glWindowPos2ivARB\"))\n\tgpWindowPos2ivMESA = (C.GPWINDOWPOS2IVMESA)(getProcAddr(\"glWindowPos2ivMESA\"))\n\tgpWindowPos2s = (C.GPWINDOWPOS2S)(getProcAddr(\"glWindowPos2s\"))\n\tif gpWindowPos2s == nil {\n\t\treturn errors.New(\"glWindowPos2s\")\n\t}\n\tgpWindowPos2sARB = (C.GPWINDOWPOS2SARB)(getProcAddr(\"glWindowPos2sARB\"))\n\tgpWindowPos2sMESA = (C.GPWINDOWPOS2SMESA)(getProcAddr(\"glWindowPos2sMESA\"))\n\tgpWindowPos2sv = (C.GPWINDOWPOS2SV)(getProcAddr(\"glWindowPos2sv\"))\n\tif gpWindowPos2sv == nil {\n\t\treturn errors.New(\"glWindowPos2sv\")\n\t}\n\tgpWindowPos2svARB = (C.GPWINDOWPOS2SVARB)(getProcAddr(\"glWindowPos2svARB\"))\n\tgpWindowPos2svMESA = (C.GPWINDOWPOS2SVMESA)(getProcAddr(\"glWindowPos2svMESA\"))\n\tgpWindowPos3d = (C.GPWINDOWPOS3D)(getProcAddr(\"glWindowPos3d\"))\n\tif gpWindowPos3d == nil {\n\t\treturn errors.New(\"glWindowPos3d\")\n\t}\n\tgpWindowPos3dARB = (C.GPWINDOWPOS3DARB)(getProcAddr(\"glWindowPos3dARB\"))\n\tgpWindowPos3dMESA = (C.GPWINDOWPOS3DMESA)(getProcAddr(\"glWindowPos3dMESA\"))\n\tgpWindowPos3dv = (C.GPWINDOWPOS3DV)(getProcAddr(\"glWindowPos3dv\"))\n\tif gpWindowPos3dv == nil {\n\t\treturn errors.New(\"glWindowPos3dv\")\n\t}\n\tgpWindowPos3dvARB = (C.GPWINDOWPOS3DVARB)(getProcAddr(\"glWindowPos3dvARB\"))\n\tgpWindowPos3dvMESA = (C.GPWINDOWPOS3DVMESA)(getProcAddr(\"glWindowPos3dvMESA\"))\n\tgpWindowPos3f = (C.GPWINDOWPOS3F)(getProcAddr(\"glWindowPos3f\"))\n\tif gpWindowPos3f == nil {\n\t\treturn errors.New(\"glWindowPos3f\")\n\t}\n\tgpWindowPos3fARB = (C.GPWINDOWPOS3FARB)(getProcAddr(\"glWindowPos3fARB\"))\n\tgpWindowPos3fMESA = (C.GPWINDOWPOS3FMESA)(getProcAddr(\"glWindowPos3fMESA\"))\n\tgpWindowPos3fv = (C.GPWINDOWPOS3FV)(getProcAddr(\"glWindowPos3fv\"))\n\tif gpWindowPos3fv == nil {\n\t\treturn errors.New(\"glWindowPos3fv\")\n\t}\n\tgpWindowPos3fvARB = (C.GPWINDOWPOS3FVARB)(getProcAddr(\"glWindowPos3fvARB\"))\n\tgpWindowPos3fvMESA = (C.GPWINDOWPOS3FVMESA)(getProcAddr(\"glWindowPos3fvMESA\"))\n\tgpWindowPos3i = (C.GPWINDOWPOS3I)(getProcAddr(\"glWindowPos3i\"))\n\tif gpWindowPos3i == nil {\n\t\treturn errors.New(\"glWindowPos3i\")\n\t}\n\tgpWindowPos3iARB = (C.GPWINDOWPOS3IARB)(getProcAddr(\"glWindowPos3iARB\"))\n\tgpWindowPos3iMESA = (C.GPWINDOWPOS3IMESA)(getProcAddr(\"glWindowPos3iMESA\"))\n\tgpWindowPos3iv = (C.GPWINDOWPOS3IV)(getProcAddr(\"glWindowPos3iv\"))\n\tif gpWindowPos3iv == nil {\n\t\treturn errors.New(\"glWindowPos3iv\")\n\t}\n\tgpWindowPos3ivARB = (C.GPWINDOWPOS3IVARB)(getProcAddr(\"glWindowPos3ivARB\"))\n\tgpWindowPos3ivMESA = (C.GPWINDOWPOS3IVMESA)(getProcAddr(\"glWindowPos3ivMESA\"))\n\tgpWindowPos3s = (C.GPWINDOWPOS3S)(getProcAddr(\"glWindowPos3s\"))\n\tif gpWindowPos3s == nil {\n\t\treturn errors.New(\"glWindowPos3s\")\n\t}\n\tgpWindowPos3sARB = (C.GPWINDOWPOS3SARB)(getProcAddr(\"glWindowPos3sARB\"))\n\tgpWindowPos3sMESA = (C.GPWINDOWPOS3SMESA)(getProcAddr(\"glWindowPos3sMESA\"))\n\tgpWindowPos3sv = (C.GPWINDOWPOS3SV)(getProcAddr(\"glWindowPos3sv\"))\n\tif gpWindowPos3sv == nil {\n\t\treturn errors.New(\"glWindowPos3sv\")\n\t}\n\tgpWindowPos3svARB = (C.GPWINDOWPOS3SVARB)(getProcAddr(\"glWindowPos3svARB\"))\n\tgpWindowPos3svMESA = (C.GPWINDOWPOS3SVMESA)(getProcAddr(\"glWindowPos3svMESA\"))\n\tgpWindowPos4dMESA = (C.GPWINDOWPOS4DMESA)(getProcAddr(\"glWindowPos4dMESA\"))\n\tgpWindowPos4dvMESA = (C.GPWINDOWPOS4DVMESA)(getProcAddr(\"glWindowPos4dvMESA\"))\n\tgpWindowPos4fMESA = (C.GPWINDOWPOS4FMESA)(getProcAddr(\"glWindowPos4fMESA\"))\n\tgpWindowPos4fvMESA = (C.GPWINDOWPOS4FVMESA)(getProcAddr(\"glWindowPos4fvMESA\"))\n\tgpWindowPos4iMESA = (C.GPWINDOWPOS4IMESA)(getProcAddr(\"glWindowPos4iMESA\"))\n\tgpWindowPos4ivMESA = (C.GPWINDOWPOS4IVMESA)(getProcAddr(\"glWindowPos4ivMESA\"))\n\tgpWindowPos4sMESA = (C.GPWINDOWPOS4SMESA)(getProcAddr(\"glWindowPos4sMESA\"))\n\tgpWindowPos4svMESA = (C.GPWINDOWPOS4SVMESA)(getProcAddr(\"glWindowPos4svMESA\"))\n\tgpWindowRectanglesEXT = (C.GPWINDOWRECTANGLESEXT)(getProcAddr(\"glWindowRectanglesEXT\"))\n\tgpWriteMaskEXT = (C.GPWRITEMASKEXT)(getProcAddr(\"glWriteMaskEXT\"))\n\treturn nil\n}", "func (s *BasePlSqlParserListener) EnterLibrary_debug(ctx *Library_debugContext) {}", "func InitWithProcAddrFunc(getProcAddr func(name string) unsafe.Pointer) error {\n\tgpChoosePixelFormat = (C.GPCHOOSEPIXELFORMAT)(getProcAddr(\"ChoosePixelFormat\"))\n\tif gpChoosePixelFormat == nil {\n\t\treturn errors.New(\"ChoosePixelFormat\")\n\t}\n\tgpDescribePixelFormat = (C.GPDESCRIBEPIXELFORMAT)(getProcAddr(\"DescribePixelFormat\"))\n\tif gpDescribePixelFormat == nil {\n\t\treturn errors.New(\"DescribePixelFormat\")\n\t}\n\tgpGetEnhMetaFilePixelFormat = (C.GPGETENHMETAFILEPIXELFORMAT)(getProcAddr(\"GetEnhMetaFilePixelFormat\"))\n\tif gpGetEnhMetaFilePixelFormat == nil {\n\t\treturn errors.New(\"GetEnhMetaFilePixelFormat\")\n\t}\n\tgpGetPixelFormat = (C.GPGETPIXELFORMAT)(getProcAddr(\"GetPixelFormat\"))\n\tif gpGetPixelFormat == nil {\n\t\treturn errors.New(\"GetPixelFormat\")\n\t}\n\tgpSetPixelFormat = (C.GPSETPIXELFORMAT)(getProcAddr(\"SetPixelFormat\"))\n\tif gpSetPixelFormat == nil {\n\t\treturn errors.New(\"SetPixelFormat\")\n\t}\n\tgpSwapBuffers = (C.GPSWAPBUFFERS)(getProcAddr(\"SwapBuffers\"))\n\tif gpSwapBuffers == nil {\n\t\treturn errors.New(\"SwapBuffers\")\n\t}\n\tgpAllocateMemoryNV = (C.GPALLOCATEMEMORYNV)(getProcAddr(\"wglAllocateMemoryNV\"))\n\tgpAssociateImageBufferEventsI3D = (C.GPASSOCIATEIMAGEBUFFEREVENTSI3D)(getProcAddr(\"wglAssociateImageBufferEventsI3D\"))\n\tgpBeginFrameTrackingI3D = (C.GPBEGINFRAMETRACKINGI3D)(getProcAddr(\"wglBeginFrameTrackingI3D\"))\n\tgpBindDisplayColorTableEXT = (C.GPBINDDISPLAYCOLORTABLEEXT)(getProcAddr(\"wglBindDisplayColorTableEXT\"))\n\tgpBindSwapBarrierNV = (C.GPBINDSWAPBARRIERNV)(getProcAddr(\"wglBindSwapBarrierNV\"))\n\tgpBindTexImageARB = (C.GPBINDTEXIMAGEARB)(getProcAddr(\"wglBindTexImageARB\"))\n\tgpBindVideoCaptureDeviceNV = (C.GPBINDVIDEOCAPTUREDEVICENV)(getProcAddr(\"wglBindVideoCaptureDeviceNV\"))\n\tgpBindVideoDeviceNV = (C.GPBINDVIDEODEVICENV)(getProcAddr(\"wglBindVideoDeviceNV\"))\n\tgpBindVideoImageNV = (C.GPBINDVIDEOIMAGENV)(getProcAddr(\"wglBindVideoImageNV\"))\n\tgpBlitContextFramebufferAMD = (C.GPBLITCONTEXTFRAMEBUFFERAMD)(getProcAddr(\"wglBlitContextFramebufferAMD\"))\n\tgpChoosePixelFormatARB = (C.GPCHOOSEPIXELFORMATARB)(getProcAddr(\"wglChoosePixelFormatARB\"))\n\tgpChoosePixelFormatEXT = (C.GPCHOOSEPIXELFORMATEXT)(getProcAddr(\"wglChoosePixelFormatEXT\"))\n\tgpCopyContext = (C.GPCOPYCONTEXT)(getProcAddr(\"wglCopyContext\"))\n\tif gpCopyContext == nil {\n\t\treturn errors.New(\"wglCopyContext\")\n\t}\n\tgpCopyImageSubDataNV = (C.GPCOPYIMAGESUBDATANV)(getProcAddr(\"wglCopyImageSubDataNV\"))\n\tgpCreateAffinityDCNV = (C.GPCREATEAFFINITYDCNV)(getProcAddr(\"wglCreateAffinityDCNV\"))\n\tgpCreateAssociatedContextAMD = (C.GPCREATEASSOCIATEDCONTEXTAMD)(getProcAddr(\"wglCreateAssociatedContextAMD\"))\n\tgpCreateAssociatedContextAttribsAMD = (C.GPCREATEASSOCIATEDCONTEXTATTRIBSAMD)(getProcAddr(\"wglCreateAssociatedContextAttribsAMD\"))\n\tgpCreateBufferRegionARB = (C.GPCREATEBUFFERREGIONARB)(getProcAddr(\"wglCreateBufferRegionARB\"))\n\tgpCreateContext = (C.GPCREATECONTEXT)(getProcAddr(\"wglCreateContext\"))\n\tif gpCreateContext == nil {\n\t\treturn errors.New(\"wglCreateContext\")\n\t}\n\tgpCreateContextAttribsARB = (C.GPCREATECONTEXTATTRIBSARB)(getProcAddr(\"wglCreateContextAttribsARB\"))\n\tgpCreateDisplayColorTableEXT = (C.GPCREATEDISPLAYCOLORTABLEEXT)(getProcAddr(\"wglCreateDisplayColorTableEXT\"))\n\tgpCreateImageBufferI3D = (C.GPCREATEIMAGEBUFFERI3D)(getProcAddr(\"wglCreateImageBufferI3D\"))\n\tgpCreateLayerContext = (C.GPCREATELAYERCONTEXT)(getProcAddr(\"wglCreateLayerContext\"))\n\tif gpCreateLayerContext == nil {\n\t\treturn errors.New(\"wglCreateLayerContext\")\n\t}\n\tgpCreatePbufferARB = (C.GPCREATEPBUFFERARB)(getProcAddr(\"wglCreatePbufferARB\"))\n\tgpCreatePbufferEXT = (C.GPCREATEPBUFFEREXT)(getProcAddr(\"wglCreatePbufferEXT\"))\n\tgpDXCloseDeviceNV = (C.GPDXCLOSEDEVICENV)(getProcAddr(\"wglDXCloseDeviceNV\"))\n\tgpDXLockObjectsNV = (C.GPDXLOCKOBJECTSNV)(getProcAddr(\"wglDXLockObjectsNV\"))\n\tgpDXObjectAccessNV = (C.GPDXOBJECTACCESSNV)(getProcAddr(\"wglDXObjectAccessNV\"))\n\tgpDXOpenDeviceNV = (C.GPDXOPENDEVICENV)(getProcAddr(\"wglDXOpenDeviceNV\"))\n\tgpDXRegisterObjectNV = (C.GPDXREGISTEROBJECTNV)(getProcAddr(\"wglDXRegisterObjectNV\"))\n\tgpDXSetResourceShareHandleNV = (C.GPDXSETRESOURCESHAREHANDLENV)(getProcAddr(\"wglDXSetResourceShareHandleNV\"))\n\tgpDXUnlockObjectsNV = (C.GPDXUNLOCKOBJECTSNV)(getProcAddr(\"wglDXUnlockObjectsNV\"))\n\tgpDXUnregisterObjectNV = (C.GPDXUNREGISTEROBJECTNV)(getProcAddr(\"wglDXUnregisterObjectNV\"))\n\tgpDelayBeforeSwapNV = (C.GPDELAYBEFORESWAPNV)(getProcAddr(\"wglDelayBeforeSwapNV\"))\n\tgpDeleteAssociatedContextAMD = (C.GPDELETEASSOCIATEDCONTEXTAMD)(getProcAddr(\"wglDeleteAssociatedContextAMD\"))\n\tgpDeleteBufferRegionARB = (C.GPDELETEBUFFERREGIONARB)(getProcAddr(\"wglDeleteBufferRegionARB\"))\n\tgpDeleteContext = (C.GPDELETECONTEXT)(getProcAddr(\"wglDeleteContext\"))\n\tif gpDeleteContext == nil {\n\t\treturn errors.New(\"wglDeleteContext\")\n\t}\n\tgpDeleteDCNV = (C.GPDELETEDCNV)(getProcAddr(\"wglDeleteDCNV\"))\n\tgpDescribeLayerPlane = (C.GPDESCRIBELAYERPLANE)(getProcAddr(\"wglDescribeLayerPlane\"))\n\tif gpDescribeLayerPlane == nil {\n\t\treturn errors.New(\"wglDescribeLayerPlane\")\n\t}\n\tgpDestroyDisplayColorTableEXT = (C.GPDESTROYDISPLAYCOLORTABLEEXT)(getProcAddr(\"wglDestroyDisplayColorTableEXT\"))\n\tgpDestroyImageBufferI3D = (C.GPDESTROYIMAGEBUFFERI3D)(getProcAddr(\"wglDestroyImageBufferI3D\"))\n\tgpDestroyPbufferARB = (C.GPDESTROYPBUFFERARB)(getProcAddr(\"wglDestroyPbufferARB\"))\n\tgpDestroyPbufferEXT = (C.GPDESTROYPBUFFEREXT)(getProcAddr(\"wglDestroyPbufferEXT\"))\n\tgpDisableFrameLockI3D = (C.GPDISABLEFRAMELOCKI3D)(getProcAddr(\"wglDisableFrameLockI3D\"))\n\tgpDisableGenlockI3D = (C.GPDISABLEGENLOCKI3D)(getProcAddr(\"wglDisableGenlockI3D\"))\n\tgpEnableFrameLockI3D = (C.GPENABLEFRAMELOCKI3D)(getProcAddr(\"wglEnableFrameLockI3D\"))\n\tgpEnableGenlockI3D = (C.GPENABLEGENLOCKI3D)(getProcAddr(\"wglEnableGenlockI3D\"))\n\tgpEndFrameTrackingI3D = (C.GPENDFRAMETRACKINGI3D)(getProcAddr(\"wglEndFrameTrackingI3D\"))\n\tgpEnumGpuDevicesNV = (C.GPENUMGPUDEVICESNV)(getProcAddr(\"wglEnumGpuDevicesNV\"))\n\tgpEnumGpusFromAffinityDCNV = (C.GPENUMGPUSFROMAFFINITYDCNV)(getProcAddr(\"wglEnumGpusFromAffinityDCNV\"))\n\tgpEnumGpusNV = (C.GPENUMGPUSNV)(getProcAddr(\"wglEnumGpusNV\"))\n\tgpEnumerateVideoCaptureDevicesNV = (C.GPENUMERATEVIDEOCAPTUREDEVICESNV)(getProcAddr(\"wglEnumerateVideoCaptureDevicesNV\"))\n\tgpEnumerateVideoDevicesNV = (C.GPENUMERATEVIDEODEVICESNV)(getProcAddr(\"wglEnumerateVideoDevicesNV\"))\n\tgpFreeMemoryNV = (C.GPFREEMEMORYNV)(getProcAddr(\"wglFreeMemoryNV\"))\n\tgpGenlockSampleRateI3D = (C.GPGENLOCKSAMPLERATEI3D)(getProcAddr(\"wglGenlockSampleRateI3D\"))\n\tgpGenlockSourceDelayI3D = (C.GPGENLOCKSOURCEDELAYI3D)(getProcAddr(\"wglGenlockSourceDelayI3D\"))\n\tgpGenlockSourceEdgeI3D = (C.GPGENLOCKSOURCEEDGEI3D)(getProcAddr(\"wglGenlockSourceEdgeI3D\"))\n\tgpGenlockSourceI3D = (C.GPGENLOCKSOURCEI3D)(getProcAddr(\"wglGenlockSourceI3D\"))\n\tgpGetContextGPUIDAMD = (C.GPGETCONTEXTGPUIDAMD)(getProcAddr(\"wglGetContextGPUIDAMD\"))\n\tgpGetCurrentAssociatedContextAMD = (C.GPGETCURRENTASSOCIATEDCONTEXTAMD)(getProcAddr(\"wglGetCurrentAssociatedContextAMD\"))\n\tgpGetCurrentContext = (C.GPGETCURRENTCONTEXT)(getProcAddr(\"wglGetCurrentContext\"))\n\tif gpGetCurrentContext == nil {\n\t\treturn errors.New(\"wglGetCurrentContext\")\n\t}\n\tgpGetCurrentDC = (C.GPGETCURRENTDC)(getProcAddr(\"wglGetCurrentDC\"))\n\tif gpGetCurrentDC == nil {\n\t\treturn errors.New(\"wglGetCurrentDC\")\n\t}\n\tgpGetCurrentReadDCARB = (C.GPGETCURRENTREADDCARB)(getProcAddr(\"wglGetCurrentReadDCARB\"))\n\tgpGetCurrentReadDCEXT = (C.GPGETCURRENTREADDCEXT)(getProcAddr(\"wglGetCurrentReadDCEXT\"))\n\tgpGetDigitalVideoParametersI3D = (C.GPGETDIGITALVIDEOPARAMETERSI3D)(getProcAddr(\"wglGetDigitalVideoParametersI3D\"))\n\tgpGetExtensionsStringARB = (C.GPGETEXTENSIONSSTRINGARB)(getProcAddr(\"wglGetExtensionsStringARB\"))\n\tgpGetExtensionsStringEXT = (C.GPGETEXTENSIONSSTRINGEXT)(getProcAddr(\"wglGetExtensionsStringEXT\"))\n\tgpGetFrameUsageI3D = (C.GPGETFRAMEUSAGEI3D)(getProcAddr(\"wglGetFrameUsageI3D\"))\n\tgpGetGPUIDsAMD = (C.GPGETGPUIDSAMD)(getProcAddr(\"wglGetGPUIDsAMD\"))\n\tgpGetGPUInfoAMD = (C.GPGETGPUINFOAMD)(getProcAddr(\"wglGetGPUInfoAMD\"))\n\tgpGetGammaTableI3D = (C.GPGETGAMMATABLEI3D)(getProcAddr(\"wglGetGammaTableI3D\"))\n\tgpGetGammaTableParametersI3D = (C.GPGETGAMMATABLEPARAMETERSI3D)(getProcAddr(\"wglGetGammaTableParametersI3D\"))\n\tgpGetGenlockSampleRateI3D = (C.GPGETGENLOCKSAMPLERATEI3D)(getProcAddr(\"wglGetGenlockSampleRateI3D\"))\n\tgpGetGenlockSourceDelayI3D = (C.GPGETGENLOCKSOURCEDELAYI3D)(getProcAddr(\"wglGetGenlockSourceDelayI3D\"))\n\tgpGetGenlockSourceEdgeI3D = (C.GPGETGENLOCKSOURCEEDGEI3D)(getProcAddr(\"wglGetGenlockSourceEdgeI3D\"))\n\tgpGetGenlockSourceI3D = (C.GPGETGENLOCKSOURCEI3D)(getProcAddr(\"wglGetGenlockSourceI3D\"))\n\tgpGetLayerPaletteEntries = (C.GPGETLAYERPALETTEENTRIES)(getProcAddr(\"wglGetLayerPaletteEntries\"))\n\tif gpGetLayerPaletteEntries == nil {\n\t\treturn errors.New(\"wglGetLayerPaletteEntries\")\n\t}\n\tgpGetMscRateOML = (C.GPGETMSCRATEOML)(getProcAddr(\"wglGetMscRateOML\"))\n\tgpGetPbufferDCARB = (C.GPGETPBUFFERDCARB)(getProcAddr(\"wglGetPbufferDCARB\"))\n\tgpGetPbufferDCEXT = (C.GPGETPBUFFERDCEXT)(getProcAddr(\"wglGetPbufferDCEXT\"))\n\tgpGetPixelFormatAttribfvARB = (C.GPGETPIXELFORMATATTRIBFVARB)(getProcAddr(\"wglGetPixelFormatAttribfvARB\"))\n\tgpGetPixelFormatAttribfvEXT = (C.GPGETPIXELFORMATATTRIBFVEXT)(getProcAddr(\"wglGetPixelFormatAttribfvEXT\"))\n\tgpGetPixelFormatAttribivARB = (C.GPGETPIXELFORMATATTRIBIVARB)(getProcAddr(\"wglGetPixelFormatAttribivARB\"))\n\tgpGetPixelFormatAttribivEXT = (C.GPGETPIXELFORMATATTRIBIVEXT)(getProcAddr(\"wglGetPixelFormatAttribivEXT\"))\n\tgpGetProcAddress = (C.GPGETPROCADDRESS)(getProcAddr(\"wglGetProcAddress\"))\n\tif gpGetProcAddress == nil {\n\t\treturn errors.New(\"wglGetProcAddress\")\n\t}\n\tgpGetSwapIntervalEXT = (C.GPGETSWAPINTERVALEXT)(getProcAddr(\"wglGetSwapIntervalEXT\"))\n\tgpGetSyncValuesOML = (C.GPGETSYNCVALUESOML)(getProcAddr(\"wglGetSyncValuesOML\"))\n\tgpGetVideoDeviceNV = (C.GPGETVIDEODEVICENV)(getProcAddr(\"wglGetVideoDeviceNV\"))\n\tgpGetVideoInfoNV = (C.GPGETVIDEOINFONV)(getProcAddr(\"wglGetVideoInfoNV\"))\n\tgpIsEnabledFrameLockI3D = (C.GPISENABLEDFRAMELOCKI3D)(getProcAddr(\"wglIsEnabledFrameLockI3D\"))\n\tgpIsEnabledGenlockI3D = (C.GPISENABLEDGENLOCKI3D)(getProcAddr(\"wglIsEnabledGenlockI3D\"))\n\tgpJoinSwapGroupNV = (C.GPJOINSWAPGROUPNV)(getProcAddr(\"wglJoinSwapGroupNV\"))\n\tgpLoadDisplayColorTableEXT = (C.GPLOADDISPLAYCOLORTABLEEXT)(getProcAddr(\"wglLoadDisplayColorTableEXT\"))\n\tgpLockVideoCaptureDeviceNV = (C.GPLOCKVIDEOCAPTUREDEVICENV)(getProcAddr(\"wglLockVideoCaptureDeviceNV\"))\n\tgpMakeAssociatedContextCurrentAMD = (C.GPMAKEASSOCIATEDCONTEXTCURRENTAMD)(getProcAddr(\"wglMakeAssociatedContextCurrentAMD\"))\n\tgpMakeContextCurrentARB = (C.GPMAKECONTEXTCURRENTARB)(getProcAddr(\"wglMakeContextCurrentARB\"))\n\tgpMakeContextCurrentEXT = (C.GPMAKECONTEXTCURRENTEXT)(getProcAddr(\"wglMakeContextCurrentEXT\"))\n\tgpMakeCurrent = (C.GPMAKECURRENT)(getProcAddr(\"wglMakeCurrent\"))\n\tif gpMakeCurrent == nil {\n\t\treturn errors.New(\"wglMakeCurrent\")\n\t}\n\tgpQueryCurrentContextNV = (C.GPQUERYCURRENTCONTEXTNV)(getProcAddr(\"wglQueryCurrentContextNV\"))\n\tgpQueryFrameCountNV = (C.GPQUERYFRAMECOUNTNV)(getProcAddr(\"wglQueryFrameCountNV\"))\n\tgpQueryFrameLockMasterI3D = (C.GPQUERYFRAMELOCKMASTERI3D)(getProcAddr(\"wglQueryFrameLockMasterI3D\"))\n\tgpQueryFrameTrackingI3D = (C.GPQUERYFRAMETRACKINGI3D)(getProcAddr(\"wglQueryFrameTrackingI3D\"))\n\tgpQueryGenlockMaxSourceDelayI3D = (C.GPQUERYGENLOCKMAXSOURCEDELAYI3D)(getProcAddr(\"wglQueryGenlockMaxSourceDelayI3D\"))\n\tgpQueryMaxSwapGroupsNV = (C.GPQUERYMAXSWAPGROUPSNV)(getProcAddr(\"wglQueryMaxSwapGroupsNV\"))\n\tgpQueryPbufferARB = (C.GPQUERYPBUFFERARB)(getProcAddr(\"wglQueryPbufferARB\"))\n\tgpQueryPbufferEXT = (C.GPQUERYPBUFFEREXT)(getProcAddr(\"wglQueryPbufferEXT\"))\n\tgpQuerySwapGroupNV = (C.GPQUERYSWAPGROUPNV)(getProcAddr(\"wglQuerySwapGroupNV\"))\n\tgpQueryVideoCaptureDeviceNV = (C.GPQUERYVIDEOCAPTUREDEVICENV)(getProcAddr(\"wglQueryVideoCaptureDeviceNV\"))\n\tgpRealizeLayerPalette = (C.GPREALIZELAYERPALETTE)(getProcAddr(\"wglRealizeLayerPalette\"))\n\tif gpRealizeLayerPalette == nil {\n\t\treturn errors.New(\"wglRealizeLayerPalette\")\n\t}\n\tgpReleaseImageBufferEventsI3D = (C.GPRELEASEIMAGEBUFFEREVENTSI3D)(getProcAddr(\"wglReleaseImageBufferEventsI3D\"))\n\tgpReleasePbufferDCARB = (C.GPRELEASEPBUFFERDCARB)(getProcAddr(\"wglReleasePbufferDCARB\"))\n\tgpReleasePbufferDCEXT = (C.GPRELEASEPBUFFERDCEXT)(getProcAddr(\"wglReleasePbufferDCEXT\"))\n\tgpReleaseTexImageARB = (C.GPRELEASETEXIMAGEARB)(getProcAddr(\"wglReleaseTexImageARB\"))\n\tgpReleaseVideoCaptureDeviceNV = (C.GPRELEASEVIDEOCAPTUREDEVICENV)(getProcAddr(\"wglReleaseVideoCaptureDeviceNV\"))\n\tgpReleaseVideoDeviceNV = (C.GPRELEASEVIDEODEVICENV)(getProcAddr(\"wglReleaseVideoDeviceNV\"))\n\tgpReleaseVideoImageNV = (C.GPRELEASEVIDEOIMAGENV)(getProcAddr(\"wglReleaseVideoImageNV\"))\n\tgpResetFrameCountNV = (C.GPRESETFRAMECOUNTNV)(getProcAddr(\"wglResetFrameCountNV\"))\n\tgpRestoreBufferRegionARB = (C.GPRESTOREBUFFERREGIONARB)(getProcAddr(\"wglRestoreBufferRegionARB\"))\n\tgpSaveBufferRegionARB = (C.GPSAVEBUFFERREGIONARB)(getProcAddr(\"wglSaveBufferRegionARB\"))\n\tgpSendPbufferToVideoNV = (C.GPSENDPBUFFERTOVIDEONV)(getProcAddr(\"wglSendPbufferToVideoNV\"))\n\tgpSetDigitalVideoParametersI3D = (C.GPSETDIGITALVIDEOPARAMETERSI3D)(getProcAddr(\"wglSetDigitalVideoParametersI3D\"))\n\tgpSetGammaTableI3D = (C.GPSETGAMMATABLEI3D)(getProcAddr(\"wglSetGammaTableI3D\"))\n\tgpSetGammaTableParametersI3D = (C.GPSETGAMMATABLEPARAMETERSI3D)(getProcAddr(\"wglSetGammaTableParametersI3D\"))\n\tgpSetLayerPaletteEntries = (C.GPSETLAYERPALETTEENTRIES)(getProcAddr(\"wglSetLayerPaletteEntries\"))\n\tif gpSetLayerPaletteEntries == nil {\n\t\treturn errors.New(\"wglSetLayerPaletteEntries\")\n\t}\n\tgpSetPbufferAttribARB = (C.GPSETPBUFFERATTRIBARB)(getProcAddr(\"wglSetPbufferAttribARB\"))\n\tgpSetStereoEmitterState3DL = (C.GPSETSTEREOEMITTERSTATE3DL)(getProcAddr(\"wglSetStereoEmitterState3DL\"))\n\tgpShareLists = (C.GPSHARELISTS)(getProcAddr(\"wglShareLists\"))\n\tif gpShareLists == nil {\n\t\treturn errors.New(\"wglShareLists\")\n\t}\n\tgpSwapBuffersMscOML = (C.GPSWAPBUFFERSMSCOML)(getProcAddr(\"wglSwapBuffersMscOML\"))\n\tgpSwapIntervalEXT = (C.GPSWAPINTERVALEXT)(getProcAddr(\"wglSwapIntervalEXT\"))\n\tgpSwapLayerBuffers = (C.GPSWAPLAYERBUFFERS)(getProcAddr(\"wglSwapLayerBuffers\"))\n\tif gpSwapLayerBuffers == nil {\n\t\treturn errors.New(\"wglSwapLayerBuffers\")\n\t}\n\tgpSwapLayerBuffersMscOML = (C.GPSWAPLAYERBUFFERSMSCOML)(getProcAddr(\"wglSwapLayerBuffersMscOML\"))\n\tgpUseFontBitmaps = (C.GPUSEFONTBITMAPS)(getProcAddr(\"wglUseFontBitmaps\"))\n\tif gpUseFontBitmaps == nil {\n\t\treturn errors.New(\"wglUseFontBitmaps\")\n\t}\n\tgpUseFontBitmapsA = (C.GPUSEFONTBITMAPSA)(getProcAddr(\"wglUseFontBitmapsA\"))\n\tif gpUseFontBitmapsA == nil {\n\t\treturn errors.New(\"wglUseFontBitmapsA\")\n\t}\n\tgpUseFontBitmapsW = (C.GPUSEFONTBITMAPSW)(getProcAddr(\"wglUseFontBitmapsW\"))\n\tif gpUseFontBitmapsW == nil {\n\t\treturn errors.New(\"wglUseFontBitmapsW\")\n\t}\n\tgpUseFontOutlines = (C.GPUSEFONTOUTLINES)(getProcAddr(\"wglUseFontOutlines\"))\n\tif gpUseFontOutlines == nil {\n\t\treturn errors.New(\"wglUseFontOutlines\")\n\t}\n\tgpUseFontOutlinesA = (C.GPUSEFONTOUTLINESA)(getProcAddr(\"wglUseFontOutlinesA\"))\n\tif gpUseFontOutlinesA == nil {\n\t\treturn errors.New(\"wglUseFontOutlinesA\")\n\t}\n\tgpUseFontOutlinesW = (C.GPUSEFONTOUTLINESW)(getProcAddr(\"wglUseFontOutlinesW\"))\n\tif gpUseFontOutlinesW == nil {\n\t\treturn errors.New(\"wglUseFontOutlinesW\")\n\t}\n\tgpWaitForMscOML = (C.GPWAITFORMSCOML)(getProcAddr(\"wglWaitForMscOML\"))\n\tgpWaitForSbcOML = (C.GPWAITFORSBCOML)(getProcAddr(\"wglWaitForSbcOML\"))\n\treturn nil\n}", "func DebugMessageInsert(source uint32, xtype uint32, id uint32, severity uint32, length int32, buf *int8) {\n C.glowDebugMessageInsert(gpDebugMessageInsert, (C.GLenum)(source), (C.GLenum)(xtype), (C.GLuint)(id), (C.GLenum)(severity), (C.GLsizei)(length), (*C.GLchar)(unsafe.Pointer(buf)))\n}", "func InitWithProcAddrFunc(getProcAddr func(name string) unsafe.Pointer) error {\n\tgpActiveTexture = (C.GPACTIVETEXTURE)(getProcAddr(\"glActiveTexture\"))\n\tif gpActiveTexture == nil {\n\t\treturn errors.New(\"glActiveTexture\")\n\t}\n\tgpAttachShader = (C.GPATTACHSHADER)(getProcAddr(\"glAttachShader\"))\n\tif gpAttachShader == nil {\n\t\treturn errors.New(\"glAttachShader\")\n\t}\n\tgpBindAttribLocation = (C.GPBINDATTRIBLOCATION)(getProcAddr(\"glBindAttribLocation\"))\n\tif gpBindAttribLocation == nil {\n\t\treturn errors.New(\"glBindAttribLocation\")\n\t}\n\tgpBindBuffer = (C.GPBINDBUFFER)(getProcAddr(\"glBindBuffer\"))\n\tif gpBindBuffer == nil {\n\t\treturn errors.New(\"glBindBuffer\")\n\t}\n\tgpBindFramebuffer = (C.GPBINDFRAMEBUFFER)(getProcAddr(\"glBindFramebuffer\"))\n\tif gpBindFramebuffer == nil {\n\t\treturn errors.New(\"glBindFramebuffer\")\n\t}\n\tgpBindRenderbuffer = (C.GPBINDRENDERBUFFER)(getProcAddr(\"glBindRenderbuffer\"))\n\tif gpBindRenderbuffer == nil {\n\t\treturn errors.New(\"glBindRenderbuffer\")\n\t}\n\tgpBindTexture = (C.GPBINDTEXTURE)(getProcAddr(\"glBindTexture\"))\n\tif gpBindTexture == nil {\n\t\treturn errors.New(\"glBindTexture\")\n\t}\n\tgpBlendColor = (C.GPBLENDCOLOR)(getProcAddr(\"glBlendColor\"))\n\tif gpBlendColor == nil {\n\t\treturn errors.New(\"glBlendColor\")\n\t}\n\tgpBlendEquation = (C.GPBLENDEQUATION)(getProcAddr(\"glBlendEquation\"))\n\tif gpBlendEquation == nil {\n\t\treturn errors.New(\"glBlendEquation\")\n\t}\n\tgpBlendEquationSeparate = (C.GPBLENDEQUATIONSEPARATE)(getProcAddr(\"glBlendEquationSeparate\"))\n\tif gpBlendEquationSeparate == nil {\n\t\treturn errors.New(\"glBlendEquationSeparate\")\n\t}\n\tgpBlendFunc = (C.GPBLENDFUNC)(getProcAddr(\"glBlendFunc\"))\n\tif gpBlendFunc == nil {\n\t\treturn errors.New(\"glBlendFunc\")\n\t}\n\tgpBlendFuncSeparate = (C.GPBLENDFUNCSEPARATE)(getProcAddr(\"glBlendFuncSeparate\"))\n\tif gpBlendFuncSeparate == nil {\n\t\treturn errors.New(\"glBlendFuncSeparate\")\n\t}\n\tgpBufferData = (C.GPBUFFERDATA)(getProcAddr(\"glBufferData\"))\n\tif gpBufferData == nil {\n\t\treturn errors.New(\"glBufferData\")\n\t}\n\tgpBufferSubData = (C.GPBUFFERSUBDATA)(getProcAddr(\"glBufferSubData\"))\n\tif gpBufferSubData == nil {\n\t\treturn errors.New(\"glBufferSubData\")\n\t}\n\tgpCheckFramebufferStatus = (C.GPCHECKFRAMEBUFFERSTATUS)(getProcAddr(\"glCheckFramebufferStatus\"))\n\tif gpCheckFramebufferStatus == nil {\n\t\treturn errors.New(\"glCheckFramebufferStatus\")\n\t}\n\tgpClear = (C.GPCLEAR)(getProcAddr(\"glClear\"))\n\tif gpClear == nil {\n\t\treturn errors.New(\"glClear\")\n\t}\n\tgpClearColor = (C.GPCLEARCOLOR)(getProcAddr(\"glClearColor\"))\n\tif gpClearColor == nil {\n\t\treturn errors.New(\"glClearColor\")\n\t}\n\tgpClearStencil = (C.GPCLEARSTENCIL)(getProcAddr(\"glClearStencil\"))\n\tif gpClearStencil == nil {\n\t\treturn errors.New(\"glClearStencil\")\n\t}\n\tgpColorMask = (C.GPCOLORMASK)(getProcAddr(\"glColorMask\"))\n\tif gpColorMask == nil {\n\t\treturn errors.New(\"glColorMask\")\n\t}\n\tgpCompileShader = (C.GPCOMPILESHADER)(getProcAddr(\"glCompileShader\"))\n\tif gpCompileShader == nil {\n\t\treturn errors.New(\"glCompileShader\")\n\t}\n\tgpCompressedTexImage2D = (C.GPCOMPRESSEDTEXIMAGE2D)(getProcAddr(\"glCompressedTexImage2D\"))\n\tif gpCompressedTexImage2D == nil {\n\t\treturn errors.New(\"glCompressedTexImage2D\")\n\t}\n\tgpCompressedTexSubImage2D = (C.GPCOMPRESSEDTEXSUBIMAGE2D)(getProcAddr(\"glCompressedTexSubImage2D\"))\n\tif gpCompressedTexSubImage2D == nil {\n\t\treturn errors.New(\"glCompressedTexSubImage2D\")\n\t}\n\tgpCopyTexImage2D = (C.GPCOPYTEXIMAGE2D)(getProcAddr(\"glCopyTexImage2D\"))\n\tif gpCopyTexImage2D == nil {\n\t\treturn errors.New(\"glCopyTexImage2D\")\n\t}\n\tgpCopyTexSubImage2D = (C.GPCOPYTEXSUBIMAGE2D)(getProcAddr(\"glCopyTexSubImage2D\"))\n\tif gpCopyTexSubImage2D == nil {\n\t\treturn errors.New(\"glCopyTexSubImage2D\")\n\t}\n\tgpCreateProgram = (C.GPCREATEPROGRAM)(getProcAddr(\"glCreateProgram\"))\n\tif gpCreateProgram == nil {\n\t\treturn errors.New(\"glCreateProgram\")\n\t}\n\tgpCreateShader = (C.GPCREATESHADER)(getProcAddr(\"glCreateShader\"))\n\tif gpCreateShader == nil {\n\t\treturn errors.New(\"glCreateShader\")\n\t}\n\tgpCullFace = (C.GPCULLFACE)(getProcAddr(\"glCullFace\"))\n\tif gpCullFace == nil {\n\t\treturn errors.New(\"glCullFace\")\n\t}\n\tgpDeleteBuffers = (C.GPDELETEBUFFERS)(getProcAddr(\"glDeleteBuffers\"))\n\tif gpDeleteBuffers == nil {\n\t\treturn errors.New(\"glDeleteBuffers\")\n\t}\n\tgpDeleteFramebuffers = (C.GPDELETEFRAMEBUFFERS)(getProcAddr(\"glDeleteFramebuffers\"))\n\tif gpDeleteFramebuffers == nil {\n\t\treturn errors.New(\"glDeleteFramebuffers\")\n\t}\n\tgpDeleteProgram = (C.GPDELETEPROGRAM)(getProcAddr(\"glDeleteProgram\"))\n\tif gpDeleteProgram == nil {\n\t\treturn errors.New(\"glDeleteProgram\")\n\t}\n\tgpDeleteRenderbuffers = (C.GPDELETERENDERBUFFERS)(getProcAddr(\"glDeleteRenderbuffers\"))\n\tif gpDeleteRenderbuffers == nil {\n\t\treturn errors.New(\"glDeleteRenderbuffers\")\n\t}\n\tgpDeleteShader = (C.GPDELETESHADER)(getProcAddr(\"glDeleteShader\"))\n\tif gpDeleteShader == nil {\n\t\treturn errors.New(\"glDeleteShader\")\n\t}\n\tgpDeleteTextures = (C.GPDELETETEXTURES)(getProcAddr(\"glDeleteTextures\"))\n\tif gpDeleteTextures == nil {\n\t\treturn errors.New(\"glDeleteTextures\")\n\t}\n\tgpDepthFunc = (C.GPDEPTHFUNC)(getProcAddr(\"glDepthFunc\"))\n\tif gpDepthFunc == nil {\n\t\treturn errors.New(\"glDepthFunc\")\n\t}\n\tgpDepthMask = (C.GPDEPTHMASK)(getProcAddr(\"glDepthMask\"))\n\tif gpDepthMask == nil {\n\t\treturn errors.New(\"glDepthMask\")\n\t}\n\tgpDetachShader = (C.GPDETACHSHADER)(getProcAddr(\"glDetachShader\"))\n\tif gpDetachShader == nil {\n\t\treturn errors.New(\"glDetachShader\")\n\t}\n\tgpDisable = (C.GPDISABLE)(getProcAddr(\"glDisable\"))\n\tif gpDisable == nil {\n\t\treturn errors.New(\"glDisable\")\n\t}\n\tgpDisableVertexAttribArray = (C.GPDISABLEVERTEXATTRIBARRAY)(getProcAddr(\"glDisableVertexAttribArray\"))\n\tif gpDisableVertexAttribArray == nil {\n\t\treturn errors.New(\"glDisableVertexAttribArray\")\n\t}\n\tgpDrawArrays = (C.GPDRAWARRAYS)(getProcAddr(\"glDrawArrays\"))\n\tif gpDrawArrays == nil {\n\t\treturn errors.New(\"glDrawArrays\")\n\t}\n\tgpDrawElements = (C.GPDRAWELEMENTS)(getProcAddr(\"glDrawElements\"))\n\tif gpDrawElements == nil {\n\t\treturn errors.New(\"glDrawElements\")\n\t}\n\tgpEnable = (C.GPENABLE)(getProcAddr(\"glEnable\"))\n\tif gpEnable == nil {\n\t\treturn errors.New(\"glEnable\")\n\t}\n\tgpEnableVertexAttribArray = (C.GPENABLEVERTEXATTRIBARRAY)(getProcAddr(\"glEnableVertexAttribArray\"))\n\tif gpEnableVertexAttribArray == nil {\n\t\treturn errors.New(\"glEnableVertexAttribArray\")\n\t}\n\tgpFinish = (C.GPFINISH)(getProcAddr(\"glFinish\"))\n\tif gpFinish == nil {\n\t\treturn errors.New(\"glFinish\")\n\t}\n\tgpFlush = (C.GPFLUSH)(getProcAddr(\"glFlush\"))\n\tif gpFlush == nil {\n\t\treturn errors.New(\"glFlush\")\n\t}\n\tgpFramebufferRenderbuffer = (C.GPFRAMEBUFFERRENDERBUFFER)(getProcAddr(\"glFramebufferRenderbuffer\"))\n\tif gpFramebufferRenderbuffer == nil {\n\t\treturn errors.New(\"glFramebufferRenderbuffer\")\n\t}\n\tgpFramebufferTexture2D = (C.GPFRAMEBUFFERTEXTURE2D)(getProcAddr(\"glFramebufferTexture2D\"))\n\tif gpFramebufferTexture2D == nil {\n\t\treturn errors.New(\"glFramebufferTexture2D\")\n\t}\n\tgpFrontFace = (C.GPFRONTFACE)(getProcAddr(\"glFrontFace\"))\n\tif gpFrontFace == nil {\n\t\treturn errors.New(\"glFrontFace\")\n\t}\n\tgpGenBuffers = (C.GPGENBUFFERS)(getProcAddr(\"glGenBuffers\"))\n\tif gpGenBuffers == nil {\n\t\treturn errors.New(\"glGenBuffers\")\n\t}\n\tgpGenFramebuffers = (C.GPGENFRAMEBUFFERS)(getProcAddr(\"glGenFramebuffers\"))\n\tif gpGenFramebuffers == nil {\n\t\treturn errors.New(\"glGenFramebuffers\")\n\t}\n\tgpGenRenderbuffers = (C.GPGENRENDERBUFFERS)(getProcAddr(\"glGenRenderbuffers\"))\n\tif gpGenRenderbuffers == nil {\n\t\treturn errors.New(\"glGenRenderbuffers\")\n\t}\n\tgpGenTextures = (C.GPGENTEXTURES)(getProcAddr(\"glGenTextures\"))\n\tif gpGenTextures == nil {\n\t\treturn errors.New(\"glGenTextures\")\n\t}\n\tgpGenerateMipmap = (C.GPGENERATEMIPMAP)(getProcAddr(\"glGenerateMipmap\"))\n\tif gpGenerateMipmap == nil {\n\t\treturn errors.New(\"glGenerateMipmap\")\n\t}\n\tgpGetActiveAttrib = (C.GPGETACTIVEATTRIB)(getProcAddr(\"glGetActiveAttrib\"))\n\tif gpGetActiveAttrib == nil {\n\t\treturn errors.New(\"glGetActiveAttrib\")\n\t}\n\tgpGetActiveUniform = (C.GPGETACTIVEUNIFORM)(getProcAddr(\"glGetActiveUniform\"))\n\tif gpGetActiveUniform == nil {\n\t\treturn errors.New(\"glGetActiveUniform\")\n\t}\n\tgpGetAttachedShaders = (C.GPGETATTACHEDSHADERS)(getProcAddr(\"glGetAttachedShaders\"))\n\tif gpGetAttachedShaders == nil {\n\t\treturn errors.New(\"glGetAttachedShaders\")\n\t}\n\tgpGetAttribLocation = (C.GPGETATTRIBLOCATION)(getProcAddr(\"glGetAttribLocation\"))\n\tif gpGetAttribLocation == nil {\n\t\treturn errors.New(\"glGetAttribLocation\")\n\t}\n\tgpGetBooleanv = (C.GPGETBOOLEANV)(getProcAddr(\"glGetBooleanv\"))\n\tif gpGetBooleanv == nil {\n\t\treturn errors.New(\"glGetBooleanv\")\n\t}\n\tgpGetBufferParameteriv = (C.GPGETBUFFERPARAMETERIV)(getProcAddr(\"glGetBufferParameteriv\"))\n\tif gpGetBufferParameteriv == nil {\n\t\treturn errors.New(\"glGetBufferParameteriv\")\n\t}\n\tgpGetError = (C.GPGETERROR)(getProcAddr(\"glGetError\"))\n\tif gpGetError == nil {\n\t\treturn errors.New(\"glGetError\")\n\t}\n\tgpGetFloatv = (C.GPGETFLOATV)(getProcAddr(\"glGetFloatv\"))\n\tif gpGetFloatv == nil {\n\t\treturn errors.New(\"glGetFloatv\")\n\t}\n\tgpGetFramebufferAttachmentParameteriv = (C.GPGETFRAMEBUFFERATTACHMENTPARAMETERIV)(getProcAddr(\"glGetFramebufferAttachmentParameteriv\"))\n\tif gpGetFramebufferAttachmentParameteriv == nil {\n\t\treturn errors.New(\"glGetFramebufferAttachmentParameteriv\")\n\t}\n\tgpGetIntegerv = (C.GPGETINTEGERV)(getProcAddr(\"glGetIntegerv\"))\n\tif gpGetIntegerv == nil {\n\t\treturn errors.New(\"glGetIntegerv\")\n\t}\n\tgpGetProgramInfoLog = (C.GPGETPROGRAMINFOLOG)(getProcAddr(\"glGetProgramInfoLog\"))\n\tif gpGetProgramInfoLog == nil {\n\t\treturn errors.New(\"glGetProgramInfoLog\")\n\t}\n\tgpGetProgramiv = (C.GPGETPROGRAMIV)(getProcAddr(\"glGetProgramiv\"))\n\tif gpGetProgramiv == nil {\n\t\treturn errors.New(\"glGetProgramiv\")\n\t}\n\tgpGetRenderbufferParameteriv = (C.GPGETRENDERBUFFERPARAMETERIV)(getProcAddr(\"glGetRenderbufferParameteriv\"))\n\tif gpGetRenderbufferParameteriv == nil {\n\t\treturn errors.New(\"glGetRenderbufferParameteriv\")\n\t}\n\tgpGetShaderInfoLog = (C.GPGETSHADERINFOLOG)(getProcAddr(\"glGetShaderInfoLog\"))\n\tif gpGetShaderInfoLog == nil {\n\t\treturn errors.New(\"glGetShaderInfoLog\")\n\t}\n\tgpGetShaderSource = (C.GPGETSHADERSOURCE)(getProcAddr(\"glGetShaderSource\"))\n\tif gpGetShaderSource == nil {\n\t\treturn errors.New(\"glGetShaderSource\")\n\t}\n\tgpGetShaderiv = (C.GPGETSHADERIV)(getProcAddr(\"glGetShaderiv\"))\n\tif gpGetShaderiv == nil {\n\t\treturn errors.New(\"glGetShaderiv\")\n\t}\n\tgpGetString = (C.GPGETSTRING)(getProcAddr(\"glGetString\"))\n\tif gpGetString == nil {\n\t\treturn errors.New(\"glGetString\")\n\t}\n\tgpGetTexParameterfv = (C.GPGETTEXPARAMETERFV)(getProcAddr(\"glGetTexParameterfv\"))\n\tif gpGetTexParameterfv == nil {\n\t\treturn errors.New(\"glGetTexParameterfv\")\n\t}\n\tgpGetTexParameteriv = (C.GPGETTEXPARAMETERIV)(getProcAddr(\"glGetTexParameteriv\"))\n\tif gpGetTexParameteriv == nil {\n\t\treturn errors.New(\"glGetTexParameteriv\")\n\t}\n\tgpGetUniformLocation = (C.GPGETUNIFORMLOCATION)(getProcAddr(\"glGetUniformLocation\"))\n\tif gpGetUniformLocation == nil {\n\t\treturn errors.New(\"glGetUniformLocation\")\n\t}\n\tgpGetUniformfv = (C.GPGETUNIFORMFV)(getProcAddr(\"glGetUniformfv\"))\n\tif gpGetUniformfv == nil {\n\t\treturn errors.New(\"glGetUniformfv\")\n\t}\n\tgpGetUniformiv = (C.GPGETUNIFORMIV)(getProcAddr(\"glGetUniformiv\"))\n\tif gpGetUniformiv == nil {\n\t\treturn errors.New(\"glGetUniformiv\")\n\t}\n\tgpGetVertexAttribPointerv = (C.GPGETVERTEXATTRIBPOINTERV)(getProcAddr(\"glGetVertexAttribPointerv\"))\n\tif gpGetVertexAttribPointerv == nil {\n\t\treturn errors.New(\"glGetVertexAttribPointerv\")\n\t}\n\tgpGetVertexAttribfv = (C.GPGETVERTEXATTRIBFV)(getProcAddr(\"glGetVertexAttribfv\"))\n\tif gpGetVertexAttribfv == nil {\n\t\treturn errors.New(\"glGetVertexAttribfv\")\n\t}\n\tgpGetVertexAttribiv = (C.GPGETVERTEXATTRIBIV)(getProcAddr(\"glGetVertexAttribiv\"))\n\tif gpGetVertexAttribiv == nil {\n\t\treturn errors.New(\"glGetVertexAttribiv\")\n\t}\n\tgpHint = (C.GPHINT)(getProcAddr(\"glHint\"))\n\tif gpHint == nil {\n\t\treturn errors.New(\"glHint\")\n\t}\n\tgpIsBuffer = (C.GPISBUFFER)(getProcAddr(\"glIsBuffer\"))\n\tif gpIsBuffer == nil {\n\t\treturn errors.New(\"glIsBuffer\")\n\t}\n\tgpIsEnabled = (C.GPISENABLED)(getProcAddr(\"glIsEnabled\"))\n\tif gpIsEnabled == nil {\n\t\treturn errors.New(\"glIsEnabled\")\n\t}\n\tgpIsFramebuffer = (C.GPISFRAMEBUFFER)(getProcAddr(\"glIsFramebuffer\"))\n\tif gpIsFramebuffer == nil {\n\t\treturn errors.New(\"glIsFramebuffer\")\n\t}\n\tgpIsProgram = (C.GPISPROGRAM)(getProcAddr(\"glIsProgram\"))\n\tif gpIsProgram == nil {\n\t\treturn errors.New(\"glIsProgram\")\n\t}\n\tgpIsRenderbuffer = (C.GPISRENDERBUFFER)(getProcAddr(\"glIsRenderbuffer\"))\n\tif gpIsRenderbuffer == nil {\n\t\treturn errors.New(\"glIsRenderbuffer\")\n\t}\n\tgpIsShader = (C.GPISSHADER)(getProcAddr(\"glIsShader\"))\n\tif gpIsShader == nil {\n\t\treturn errors.New(\"glIsShader\")\n\t}\n\tgpIsTexture = (C.GPISTEXTURE)(getProcAddr(\"glIsTexture\"))\n\tif gpIsTexture == nil {\n\t\treturn errors.New(\"glIsTexture\")\n\t}\n\tgpLineWidth = (C.GPLINEWIDTH)(getProcAddr(\"glLineWidth\"))\n\tif gpLineWidth == nil {\n\t\treturn errors.New(\"glLineWidth\")\n\t}\n\tgpLinkProgram = (C.GPLINKPROGRAM)(getProcAddr(\"glLinkProgram\"))\n\tif gpLinkProgram == nil {\n\t\treturn errors.New(\"glLinkProgram\")\n\t}\n\tgpPixelStorei = (C.GPPIXELSTOREI)(getProcAddr(\"glPixelStorei\"))\n\tif gpPixelStorei == nil {\n\t\treturn errors.New(\"glPixelStorei\")\n\t}\n\tgpPolygonOffset = (C.GPPOLYGONOFFSET)(getProcAddr(\"glPolygonOffset\"))\n\tif gpPolygonOffset == nil {\n\t\treturn errors.New(\"glPolygonOffset\")\n\t}\n\tgpReadPixels = (C.GPREADPIXELS)(getProcAddr(\"glReadPixels\"))\n\tif gpReadPixels == nil {\n\t\treturn errors.New(\"glReadPixels\")\n\t}\n\tgpRenderbufferStorage = (C.GPRENDERBUFFERSTORAGE)(getProcAddr(\"glRenderbufferStorage\"))\n\tif gpRenderbufferStorage == nil {\n\t\treturn errors.New(\"glRenderbufferStorage\")\n\t}\n\tgpSampleCoverage = (C.GPSAMPLECOVERAGE)(getProcAddr(\"glSampleCoverage\"))\n\tif gpSampleCoverage == nil {\n\t\treturn errors.New(\"glSampleCoverage\")\n\t}\n\tgpScissor = (C.GPSCISSOR)(getProcAddr(\"glScissor\"))\n\tif gpScissor == nil {\n\t\treturn errors.New(\"glScissor\")\n\t}\n\tgpShaderSource = (C.GPSHADERSOURCE)(getProcAddr(\"glShaderSource\"))\n\tif gpShaderSource == nil {\n\t\treturn errors.New(\"glShaderSource\")\n\t}\n\tgpStencilFunc = (C.GPSTENCILFUNC)(getProcAddr(\"glStencilFunc\"))\n\tif gpStencilFunc == nil {\n\t\treturn errors.New(\"glStencilFunc\")\n\t}\n\tgpStencilFuncSeparate = (C.GPSTENCILFUNCSEPARATE)(getProcAddr(\"glStencilFuncSeparate\"))\n\tif gpStencilFuncSeparate == nil {\n\t\treturn errors.New(\"glStencilFuncSeparate\")\n\t}\n\tgpStencilMask = (C.GPSTENCILMASK)(getProcAddr(\"glStencilMask\"))\n\tif gpStencilMask == nil {\n\t\treturn errors.New(\"glStencilMask\")\n\t}\n\tgpStencilMaskSeparate = (C.GPSTENCILMASKSEPARATE)(getProcAddr(\"glStencilMaskSeparate\"))\n\tif gpStencilMaskSeparate == nil {\n\t\treturn errors.New(\"glStencilMaskSeparate\")\n\t}\n\tgpStencilOp = (C.GPSTENCILOP)(getProcAddr(\"glStencilOp\"))\n\tif gpStencilOp == nil {\n\t\treturn errors.New(\"glStencilOp\")\n\t}\n\tgpStencilOpSeparate = (C.GPSTENCILOPSEPARATE)(getProcAddr(\"glStencilOpSeparate\"))\n\tif gpStencilOpSeparate == nil {\n\t\treturn errors.New(\"glStencilOpSeparate\")\n\t}\n\tgpTexImage2D = (C.GPTEXIMAGE2D)(getProcAddr(\"glTexImage2D\"))\n\tif gpTexImage2D == nil {\n\t\treturn errors.New(\"glTexImage2D\")\n\t}\n\tgpTexParameterf = (C.GPTEXPARAMETERF)(getProcAddr(\"glTexParameterf\"))\n\tif gpTexParameterf == nil {\n\t\treturn errors.New(\"glTexParameterf\")\n\t}\n\tgpTexParameterfv = (C.GPTEXPARAMETERFV)(getProcAddr(\"glTexParameterfv\"))\n\tif gpTexParameterfv == nil {\n\t\treturn errors.New(\"glTexParameterfv\")\n\t}\n\tgpTexParameteri = (C.GPTEXPARAMETERI)(getProcAddr(\"glTexParameteri\"))\n\tif gpTexParameteri == nil {\n\t\treturn errors.New(\"glTexParameteri\")\n\t}\n\tgpTexParameteriv = (C.GPTEXPARAMETERIV)(getProcAddr(\"glTexParameteriv\"))\n\tif gpTexParameteriv == nil {\n\t\treturn errors.New(\"glTexParameteriv\")\n\t}\n\tgpTexSubImage2D = (C.GPTEXSUBIMAGE2D)(getProcAddr(\"glTexSubImage2D\"))\n\tif gpTexSubImage2D == nil {\n\t\treturn errors.New(\"glTexSubImage2D\")\n\t}\n\tgpUniform1f = (C.GPUNIFORM1F)(getProcAddr(\"glUniform1f\"))\n\tif gpUniform1f == nil {\n\t\treturn errors.New(\"glUniform1f\")\n\t}\n\tgpUniform1fv = (C.GPUNIFORM1FV)(getProcAddr(\"glUniform1fv\"))\n\tif gpUniform1fv == nil {\n\t\treturn errors.New(\"glUniform1fv\")\n\t}\n\tgpUniform1i = (C.GPUNIFORM1I)(getProcAddr(\"glUniform1i\"))\n\tif gpUniform1i == nil {\n\t\treturn errors.New(\"glUniform1i\")\n\t}\n\tgpUniform1iv = (C.GPUNIFORM1IV)(getProcAddr(\"glUniform1iv\"))\n\tif gpUniform1iv == nil {\n\t\treturn errors.New(\"glUniform1iv\")\n\t}\n\tgpUniform2f = (C.GPUNIFORM2F)(getProcAddr(\"glUniform2f\"))\n\tif gpUniform2f == nil {\n\t\treturn errors.New(\"glUniform2f\")\n\t}\n\tgpUniform2fv = (C.GPUNIFORM2FV)(getProcAddr(\"glUniform2fv\"))\n\tif gpUniform2fv == nil {\n\t\treturn errors.New(\"glUniform2fv\")\n\t}\n\tgpUniform2i = (C.GPUNIFORM2I)(getProcAddr(\"glUniform2i\"))\n\tif gpUniform2i == nil {\n\t\treturn errors.New(\"glUniform2i\")\n\t}\n\tgpUniform2iv = (C.GPUNIFORM2IV)(getProcAddr(\"glUniform2iv\"))\n\tif gpUniform2iv == nil {\n\t\treturn errors.New(\"glUniform2iv\")\n\t}\n\tgpUniform3f = (C.GPUNIFORM3F)(getProcAddr(\"glUniform3f\"))\n\tif gpUniform3f == nil {\n\t\treturn errors.New(\"glUniform3f\")\n\t}\n\tgpUniform3fv = (C.GPUNIFORM3FV)(getProcAddr(\"glUniform3fv\"))\n\tif gpUniform3fv == nil {\n\t\treturn errors.New(\"glUniform3fv\")\n\t}\n\tgpUniform3i = (C.GPUNIFORM3I)(getProcAddr(\"glUniform3i\"))\n\tif gpUniform3i == nil {\n\t\treturn errors.New(\"glUniform3i\")\n\t}\n\tgpUniform3iv = (C.GPUNIFORM3IV)(getProcAddr(\"glUniform3iv\"))\n\tif gpUniform3iv == nil {\n\t\treturn errors.New(\"glUniform3iv\")\n\t}\n\tgpUniform4f = (C.GPUNIFORM4F)(getProcAddr(\"glUniform4f\"))\n\tif gpUniform4f == nil {\n\t\treturn errors.New(\"glUniform4f\")\n\t}\n\tgpUniform4fv = (C.GPUNIFORM4FV)(getProcAddr(\"glUniform4fv\"))\n\tif gpUniform4fv == nil {\n\t\treturn errors.New(\"glUniform4fv\")\n\t}\n\tgpUniform4i = (C.GPUNIFORM4I)(getProcAddr(\"glUniform4i\"))\n\tif gpUniform4i == nil {\n\t\treturn errors.New(\"glUniform4i\")\n\t}\n\tgpUniform4iv = (C.GPUNIFORM4IV)(getProcAddr(\"glUniform4iv\"))\n\tif gpUniform4iv == nil {\n\t\treturn errors.New(\"glUniform4iv\")\n\t}\n\tgpUniformMatrix2fv = (C.GPUNIFORMMATRIX2FV)(getProcAddr(\"glUniformMatrix2fv\"))\n\tif gpUniformMatrix2fv == nil {\n\t\treturn errors.New(\"glUniformMatrix2fv\")\n\t}\n\tgpUniformMatrix3fv = (C.GPUNIFORMMATRIX3FV)(getProcAddr(\"glUniformMatrix3fv\"))\n\tif gpUniformMatrix3fv == nil {\n\t\treturn errors.New(\"glUniformMatrix3fv\")\n\t}\n\tgpUniformMatrix4fv = (C.GPUNIFORMMATRIX4FV)(getProcAddr(\"glUniformMatrix4fv\"))\n\tif gpUniformMatrix4fv == nil {\n\t\treturn errors.New(\"glUniformMatrix4fv\")\n\t}\n\tgpUseProgram = (C.GPUSEPROGRAM)(getProcAddr(\"glUseProgram\"))\n\tif gpUseProgram == nil {\n\t\treturn errors.New(\"glUseProgram\")\n\t}\n\tgpValidateProgram = (C.GPVALIDATEPROGRAM)(getProcAddr(\"glValidateProgram\"))\n\tif gpValidateProgram == nil {\n\t\treturn errors.New(\"glValidateProgram\")\n\t}\n\tgpVertexAttrib1f = (C.GPVERTEXATTRIB1F)(getProcAddr(\"glVertexAttrib1f\"))\n\tif gpVertexAttrib1f == nil {\n\t\treturn errors.New(\"glVertexAttrib1f\")\n\t}\n\tgpVertexAttrib1fv = (C.GPVERTEXATTRIB1FV)(getProcAddr(\"glVertexAttrib1fv\"))\n\tif gpVertexAttrib1fv == nil {\n\t\treturn errors.New(\"glVertexAttrib1fv\")\n\t}\n\tgpVertexAttrib2f = (C.GPVERTEXATTRIB2F)(getProcAddr(\"glVertexAttrib2f\"))\n\tif gpVertexAttrib2f == nil {\n\t\treturn errors.New(\"glVertexAttrib2f\")\n\t}\n\tgpVertexAttrib2fv = (C.GPVERTEXATTRIB2FV)(getProcAddr(\"glVertexAttrib2fv\"))\n\tif gpVertexAttrib2fv == nil {\n\t\treturn errors.New(\"glVertexAttrib2fv\")\n\t}\n\tgpVertexAttrib3f = (C.GPVERTEXATTRIB3F)(getProcAddr(\"glVertexAttrib3f\"))\n\tif gpVertexAttrib3f == nil {\n\t\treturn errors.New(\"glVertexAttrib3f\")\n\t}\n\tgpVertexAttrib3fv = (C.GPVERTEXATTRIB3FV)(getProcAddr(\"glVertexAttrib3fv\"))\n\tif gpVertexAttrib3fv == nil {\n\t\treturn errors.New(\"glVertexAttrib3fv\")\n\t}\n\tgpVertexAttrib4f = (C.GPVERTEXATTRIB4F)(getProcAddr(\"glVertexAttrib4f\"))\n\tif gpVertexAttrib4f == nil {\n\t\treturn errors.New(\"glVertexAttrib4f\")\n\t}\n\tgpVertexAttrib4fv = (C.GPVERTEXATTRIB4FV)(getProcAddr(\"glVertexAttrib4fv\"))\n\tif gpVertexAttrib4fv == nil {\n\t\treturn errors.New(\"glVertexAttrib4fv\")\n\t}\n\tgpVertexAttribPointer = (C.GPVERTEXATTRIBPOINTER)(getProcAddr(\"glVertexAttribPointer\"))\n\tif gpVertexAttribPointer == nil {\n\t\treturn errors.New(\"glVertexAttribPointer\")\n\t}\n\tgpViewport = (C.GPVIEWPORT)(getProcAddr(\"glViewport\"))\n\tif gpViewport == nil {\n\t\treturn errors.New(\"glViewport\")\n\t}\n\treturn nil\n}", "func InitWithProcAddrFunc(getProcAddr func(name string) unsafe.Pointer) error {\n\tgpChoosePixelFormat = uintptr(getProcAddr(\"ChoosePixelFormat\"))\n\tif gpChoosePixelFormat == 0 {\n\t\treturn errors.New(\"ChoosePixelFormat\")\n\t}\n\tgpDescribePixelFormat = uintptr(getProcAddr(\"DescribePixelFormat\"))\n\tif gpDescribePixelFormat == 0 {\n\t\treturn errors.New(\"DescribePixelFormat\")\n\t}\n\tgpGetEnhMetaFilePixelFormat = uintptr(getProcAddr(\"GetEnhMetaFilePixelFormat\"))\n\tif gpGetEnhMetaFilePixelFormat == 0 {\n\t\treturn errors.New(\"GetEnhMetaFilePixelFormat\")\n\t}\n\tgpGetPixelFormat = uintptr(getProcAddr(\"GetPixelFormat\"))\n\tif gpGetPixelFormat == 0 {\n\t\treturn errors.New(\"GetPixelFormat\")\n\t}\n\tgpSetPixelFormat = uintptr(getProcAddr(\"SetPixelFormat\"))\n\tif gpSetPixelFormat == 0 {\n\t\treturn errors.New(\"SetPixelFormat\")\n\t}\n\tgpSwapBuffers = uintptr(getProcAddr(\"SwapBuffers\"))\n\tif gpSwapBuffers == 0 {\n\t\treturn errors.New(\"SwapBuffers\")\n\t}\n\tgpAllocateMemoryNV = uintptr(getProcAddr(\"wglAllocateMemoryNV\"))\n\tgpAssociateImageBufferEventsI3D = uintptr(getProcAddr(\"wglAssociateImageBufferEventsI3D\"))\n\tgpBeginFrameTrackingI3D = uintptr(getProcAddr(\"wglBeginFrameTrackingI3D\"))\n\tgpBindDisplayColorTableEXT = uintptr(getProcAddr(\"wglBindDisplayColorTableEXT\"))\n\tgpBindSwapBarrierNV = uintptr(getProcAddr(\"wglBindSwapBarrierNV\"))\n\tgpBindTexImageARB = uintptr(getProcAddr(\"wglBindTexImageARB\"))\n\tgpBindVideoCaptureDeviceNV = uintptr(getProcAddr(\"wglBindVideoCaptureDeviceNV\"))\n\tgpBindVideoDeviceNV = uintptr(getProcAddr(\"wglBindVideoDeviceNV\"))\n\tgpBindVideoImageNV = uintptr(getProcAddr(\"wglBindVideoImageNV\"))\n\tgpBlitContextFramebufferAMD = uintptr(getProcAddr(\"wglBlitContextFramebufferAMD\"))\n\tgpChoosePixelFormatARB = uintptr(getProcAddr(\"wglChoosePixelFormatARB\"))\n\tgpChoosePixelFormatEXT = uintptr(getProcAddr(\"wglChoosePixelFormatEXT\"))\n\tgpCopyContext = uintptr(getProcAddr(\"wglCopyContext\"))\n\tif gpCopyContext == 0 {\n\t\treturn errors.New(\"wglCopyContext\")\n\t}\n\tgpCopyImageSubDataNV = uintptr(getProcAddr(\"wglCopyImageSubDataNV\"))\n\tgpCreateAffinityDCNV = uintptr(getProcAddr(\"wglCreateAffinityDCNV\"))\n\tgpCreateAssociatedContextAMD = uintptr(getProcAddr(\"wglCreateAssociatedContextAMD\"))\n\tgpCreateAssociatedContextAttribsAMD = uintptr(getProcAddr(\"wglCreateAssociatedContextAttribsAMD\"))\n\tgpCreateBufferRegionARB = uintptr(getProcAddr(\"wglCreateBufferRegionARB\"))\n\tgpCreateContext = uintptr(getProcAddr(\"wglCreateContext\"))\n\tif gpCreateContext == 0 {\n\t\treturn errors.New(\"wglCreateContext\")\n\t}\n\tgpCreateContextAttribsARB = uintptr(getProcAddr(\"wglCreateContextAttribsARB\"))\n\tgpCreateDisplayColorTableEXT = uintptr(getProcAddr(\"wglCreateDisplayColorTableEXT\"))\n\tgpCreateImageBufferI3D = uintptr(getProcAddr(\"wglCreateImageBufferI3D\"))\n\tgpCreateLayerContext = uintptr(getProcAddr(\"wglCreateLayerContext\"))\n\tif gpCreateLayerContext == 0 {\n\t\treturn errors.New(\"wglCreateLayerContext\")\n\t}\n\tgpCreatePbufferARB = uintptr(getProcAddr(\"wglCreatePbufferARB\"))\n\tgpCreatePbufferEXT = uintptr(getProcAddr(\"wglCreatePbufferEXT\"))\n\tgpDXCloseDeviceNV = uintptr(getProcAddr(\"wglDXCloseDeviceNV\"))\n\tgpDXLockObjectsNV = uintptr(getProcAddr(\"wglDXLockObjectsNV\"))\n\tgpDXObjectAccessNV = uintptr(getProcAddr(\"wglDXObjectAccessNV\"))\n\tgpDXOpenDeviceNV = uintptr(getProcAddr(\"wglDXOpenDeviceNV\"))\n\tgpDXRegisterObjectNV = uintptr(getProcAddr(\"wglDXRegisterObjectNV\"))\n\tgpDXSetResourceShareHandleNV = uintptr(getProcAddr(\"wglDXSetResourceShareHandleNV\"))\n\tgpDXUnlockObjectsNV = uintptr(getProcAddr(\"wglDXUnlockObjectsNV\"))\n\tgpDXUnregisterObjectNV = uintptr(getProcAddr(\"wglDXUnregisterObjectNV\"))\n\tgpDelayBeforeSwapNV = uintptr(getProcAddr(\"wglDelayBeforeSwapNV\"))\n\tgpDeleteAssociatedContextAMD = uintptr(getProcAddr(\"wglDeleteAssociatedContextAMD\"))\n\tgpDeleteBufferRegionARB = uintptr(getProcAddr(\"wglDeleteBufferRegionARB\"))\n\tgpDeleteContext = uintptr(getProcAddr(\"wglDeleteContext\"))\n\tif gpDeleteContext == 0 {\n\t\treturn errors.New(\"wglDeleteContext\")\n\t}\n\tgpDeleteDCNV = uintptr(getProcAddr(\"wglDeleteDCNV\"))\n\tgpDescribeLayerPlane = uintptr(getProcAddr(\"wglDescribeLayerPlane\"))\n\tif gpDescribeLayerPlane == 0 {\n\t\treturn errors.New(\"wglDescribeLayerPlane\")\n\t}\n\tgpDestroyDisplayColorTableEXT = uintptr(getProcAddr(\"wglDestroyDisplayColorTableEXT\"))\n\tgpDestroyImageBufferI3D = uintptr(getProcAddr(\"wglDestroyImageBufferI3D\"))\n\tgpDestroyPbufferARB = uintptr(getProcAddr(\"wglDestroyPbufferARB\"))\n\tgpDestroyPbufferEXT = uintptr(getProcAddr(\"wglDestroyPbufferEXT\"))\n\tgpDisableFrameLockI3D = uintptr(getProcAddr(\"wglDisableFrameLockI3D\"))\n\tgpDisableGenlockI3D = uintptr(getProcAddr(\"wglDisableGenlockI3D\"))\n\tgpEnableFrameLockI3D = uintptr(getProcAddr(\"wglEnableFrameLockI3D\"))\n\tgpEnableGenlockI3D = uintptr(getProcAddr(\"wglEnableGenlockI3D\"))\n\tgpEndFrameTrackingI3D = uintptr(getProcAddr(\"wglEndFrameTrackingI3D\"))\n\tgpEnumGpuDevicesNV = uintptr(getProcAddr(\"wglEnumGpuDevicesNV\"))\n\tgpEnumGpusFromAffinityDCNV = uintptr(getProcAddr(\"wglEnumGpusFromAffinityDCNV\"))\n\tgpEnumGpusNV = uintptr(getProcAddr(\"wglEnumGpusNV\"))\n\tgpEnumerateVideoCaptureDevicesNV = uintptr(getProcAddr(\"wglEnumerateVideoCaptureDevicesNV\"))\n\tgpEnumerateVideoDevicesNV = uintptr(getProcAddr(\"wglEnumerateVideoDevicesNV\"))\n\tgpFreeMemoryNV = uintptr(getProcAddr(\"wglFreeMemoryNV\"))\n\tgpGenlockSampleRateI3D = uintptr(getProcAddr(\"wglGenlockSampleRateI3D\"))\n\tgpGenlockSourceDelayI3D = uintptr(getProcAddr(\"wglGenlockSourceDelayI3D\"))\n\tgpGenlockSourceEdgeI3D = uintptr(getProcAddr(\"wglGenlockSourceEdgeI3D\"))\n\tgpGenlockSourceI3D = uintptr(getProcAddr(\"wglGenlockSourceI3D\"))\n\tgpGetContextGPUIDAMD = uintptr(getProcAddr(\"wglGetContextGPUIDAMD\"))\n\tgpGetCurrentAssociatedContextAMD = uintptr(getProcAddr(\"wglGetCurrentAssociatedContextAMD\"))\n\tgpGetCurrentContext = uintptr(getProcAddr(\"wglGetCurrentContext\"))\n\tif gpGetCurrentContext == 0 {\n\t\treturn errors.New(\"wglGetCurrentContext\")\n\t}\n\tgpGetCurrentDC = uintptr(getProcAddr(\"wglGetCurrentDC\"))\n\tif gpGetCurrentDC == 0 {\n\t\treturn errors.New(\"wglGetCurrentDC\")\n\t}\n\tgpGetCurrentReadDCARB = uintptr(getProcAddr(\"wglGetCurrentReadDCARB\"))\n\tgpGetCurrentReadDCEXT = uintptr(getProcAddr(\"wglGetCurrentReadDCEXT\"))\n\tgpGetDigitalVideoParametersI3D = uintptr(getProcAddr(\"wglGetDigitalVideoParametersI3D\"))\n\tgpGetExtensionsStringARB = uintptr(getProcAddr(\"wglGetExtensionsStringARB\"))\n\tgpGetExtensionsStringEXT = uintptr(getProcAddr(\"wglGetExtensionsStringEXT\"))\n\tgpGetFrameUsageI3D = uintptr(getProcAddr(\"wglGetFrameUsageI3D\"))\n\tgpGetGPUIDsAMD = uintptr(getProcAddr(\"wglGetGPUIDsAMD\"))\n\tgpGetGPUInfoAMD = uintptr(getProcAddr(\"wglGetGPUInfoAMD\"))\n\tgpGetGammaTableI3D = uintptr(getProcAddr(\"wglGetGammaTableI3D\"))\n\tgpGetGammaTableParametersI3D = uintptr(getProcAddr(\"wglGetGammaTableParametersI3D\"))\n\tgpGetGenlockSampleRateI3D = uintptr(getProcAddr(\"wglGetGenlockSampleRateI3D\"))\n\tgpGetGenlockSourceDelayI3D = uintptr(getProcAddr(\"wglGetGenlockSourceDelayI3D\"))\n\tgpGetGenlockSourceEdgeI3D = uintptr(getProcAddr(\"wglGetGenlockSourceEdgeI3D\"))\n\tgpGetGenlockSourceI3D = uintptr(getProcAddr(\"wglGetGenlockSourceI3D\"))\n\tgpGetLayerPaletteEntries = uintptr(getProcAddr(\"wglGetLayerPaletteEntries\"))\n\tif gpGetLayerPaletteEntries == 0 {\n\t\treturn errors.New(\"wglGetLayerPaletteEntries\")\n\t}\n\tgpGetMscRateOML = uintptr(getProcAddr(\"wglGetMscRateOML\"))\n\tgpGetPbufferDCARB = uintptr(getProcAddr(\"wglGetPbufferDCARB\"))\n\tgpGetPbufferDCEXT = uintptr(getProcAddr(\"wglGetPbufferDCEXT\"))\n\tgpGetPixelFormatAttribfvARB = uintptr(getProcAddr(\"wglGetPixelFormatAttribfvARB\"))\n\tgpGetPixelFormatAttribfvEXT = uintptr(getProcAddr(\"wglGetPixelFormatAttribfvEXT\"))\n\tgpGetPixelFormatAttribivARB = uintptr(getProcAddr(\"wglGetPixelFormatAttribivARB\"))\n\tgpGetPixelFormatAttribivEXT = uintptr(getProcAddr(\"wglGetPixelFormatAttribivEXT\"))\n\tgpGetProcAddress = uintptr(getProcAddr(\"wglGetProcAddress\"))\n\tif gpGetProcAddress == 0 {\n\t\treturn errors.New(\"wglGetProcAddress\")\n\t}\n\tgpGetSwapIntervalEXT = uintptr(getProcAddr(\"wglGetSwapIntervalEXT\"))\n\tgpGetSyncValuesOML = uintptr(getProcAddr(\"wglGetSyncValuesOML\"))\n\tgpGetVideoDeviceNV = uintptr(getProcAddr(\"wglGetVideoDeviceNV\"))\n\tgpGetVideoInfoNV = uintptr(getProcAddr(\"wglGetVideoInfoNV\"))\n\tgpIsEnabledFrameLockI3D = uintptr(getProcAddr(\"wglIsEnabledFrameLockI3D\"))\n\tgpIsEnabledGenlockI3D = uintptr(getProcAddr(\"wglIsEnabledGenlockI3D\"))\n\tgpJoinSwapGroupNV = uintptr(getProcAddr(\"wglJoinSwapGroupNV\"))\n\tgpLoadDisplayColorTableEXT = uintptr(getProcAddr(\"wglLoadDisplayColorTableEXT\"))\n\tgpLockVideoCaptureDeviceNV = uintptr(getProcAddr(\"wglLockVideoCaptureDeviceNV\"))\n\tgpMakeAssociatedContextCurrentAMD = uintptr(getProcAddr(\"wglMakeAssociatedContextCurrentAMD\"))\n\tgpMakeContextCurrentARB = uintptr(getProcAddr(\"wglMakeContextCurrentARB\"))\n\tgpMakeContextCurrentEXT = uintptr(getProcAddr(\"wglMakeContextCurrentEXT\"))\n\tgpMakeCurrent = uintptr(getProcAddr(\"wglMakeCurrent\"))\n\tif gpMakeCurrent == 0 {\n\t\treturn errors.New(\"wglMakeCurrent\")\n\t}\n\tgpQueryCurrentContextNV = uintptr(getProcAddr(\"wglQueryCurrentContextNV\"))\n\tgpQueryFrameCountNV = uintptr(getProcAddr(\"wglQueryFrameCountNV\"))\n\tgpQueryFrameLockMasterI3D = uintptr(getProcAddr(\"wglQueryFrameLockMasterI3D\"))\n\tgpQueryFrameTrackingI3D = uintptr(getProcAddr(\"wglQueryFrameTrackingI3D\"))\n\tgpQueryGenlockMaxSourceDelayI3D = uintptr(getProcAddr(\"wglQueryGenlockMaxSourceDelayI3D\"))\n\tgpQueryMaxSwapGroupsNV = uintptr(getProcAddr(\"wglQueryMaxSwapGroupsNV\"))\n\tgpQueryPbufferARB = uintptr(getProcAddr(\"wglQueryPbufferARB\"))\n\tgpQueryPbufferEXT = uintptr(getProcAddr(\"wglQueryPbufferEXT\"))\n\tgpQuerySwapGroupNV = uintptr(getProcAddr(\"wglQuerySwapGroupNV\"))\n\tgpQueryVideoCaptureDeviceNV = uintptr(getProcAddr(\"wglQueryVideoCaptureDeviceNV\"))\n\tgpRealizeLayerPalette = uintptr(getProcAddr(\"wglRealizeLayerPalette\"))\n\tif gpRealizeLayerPalette == 0 {\n\t\treturn errors.New(\"wglRealizeLayerPalette\")\n\t}\n\tgpReleaseImageBufferEventsI3D = uintptr(getProcAddr(\"wglReleaseImageBufferEventsI3D\"))\n\tgpReleasePbufferDCARB = uintptr(getProcAddr(\"wglReleasePbufferDCARB\"))\n\tgpReleasePbufferDCEXT = uintptr(getProcAddr(\"wglReleasePbufferDCEXT\"))\n\tgpReleaseTexImageARB = uintptr(getProcAddr(\"wglReleaseTexImageARB\"))\n\tgpReleaseVideoCaptureDeviceNV = uintptr(getProcAddr(\"wglReleaseVideoCaptureDeviceNV\"))\n\tgpReleaseVideoDeviceNV = uintptr(getProcAddr(\"wglReleaseVideoDeviceNV\"))\n\tgpReleaseVideoImageNV = uintptr(getProcAddr(\"wglReleaseVideoImageNV\"))\n\tgpResetFrameCountNV = uintptr(getProcAddr(\"wglResetFrameCountNV\"))\n\tgpRestoreBufferRegionARB = uintptr(getProcAddr(\"wglRestoreBufferRegionARB\"))\n\tgpSaveBufferRegionARB = uintptr(getProcAddr(\"wglSaveBufferRegionARB\"))\n\tgpSendPbufferToVideoNV = uintptr(getProcAddr(\"wglSendPbufferToVideoNV\"))\n\tgpSetDigitalVideoParametersI3D = uintptr(getProcAddr(\"wglSetDigitalVideoParametersI3D\"))\n\tgpSetGammaTableI3D = uintptr(getProcAddr(\"wglSetGammaTableI3D\"))\n\tgpSetGammaTableParametersI3D = uintptr(getProcAddr(\"wglSetGammaTableParametersI3D\"))\n\tgpSetLayerPaletteEntries = uintptr(getProcAddr(\"wglSetLayerPaletteEntries\"))\n\tif gpSetLayerPaletteEntries == 0 {\n\t\treturn errors.New(\"wglSetLayerPaletteEntries\")\n\t}\n\tgpSetPbufferAttribARB = uintptr(getProcAddr(\"wglSetPbufferAttribARB\"))\n\tgpSetStereoEmitterState3DL = uintptr(getProcAddr(\"wglSetStereoEmitterState3DL\"))\n\tgpShareLists = uintptr(getProcAddr(\"wglShareLists\"))\n\tif gpShareLists == 0 {\n\t\treturn errors.New(\"wglShareLists\")\n\t}\n\tgpSwapBuffersMscOML = uintptr(getProcAddr(\"wglSwapBuffersMscOML\"))\n\tgpSwapIntervalEXT = uintptr(getProcAddr(\"wglSwapIntervalEXT\"))\n\tgpSwapLayerBuffers = uintptr(getProcAddr(\"wglSwapLayerBuffers\"))\n\tif gpSwapLayerBuffers == 0 {\n\t\treturn errors.New(\"wglSwapLayerBuffers\")\n\t}\n\tgpSwapLayerBuffersMscOML = uintptr(getProcAddr(\"wglSwapLayerBuffersMscOML\"))\n\tgpUseFontBitmaps = uintptr(getProcAddr(\"wglUseFontBitmapsW\"))\n\tif gpUseFontBitmaps == 0 {\n\t\treturn errors.New(\"wglUseFontBitmaps\")\n\t}\n\tgpUseFontOutlines = uintptr(getProcAddr(\"wglUseFontOutlinesW\"))\n\tif gpUseFontOutlines == 0 {\n\t\treturn errors.New(\"wglUseFontOutlines\")\n\t}\n\tgpWaitForMscOML = uintptr(getProcAddr(\"wglWaitForMscOML\"))\n\tgpWaitForSbcOML = uintptr(getProcAddr(\"wglWaitForSbcOML\"))\n\treturn nil\n}", "func DebugMessageCallback(callback unsafe.Pointer, userParam unsafe.Pointer) {\n\tsyscall.Syscall(gpDebugMessageCallback, 2, syscall.NewCallback(callback), uintptr(userParam), 0)\n}", "func _debug(ptr uint32, size uint32)", "func DebugMessageCallbackKHR(callback unsafe.Pointer, userParam unsafe.Pointer) {\n\tsyscall.Syscall(gpDebugMessageCallbackKHR, 2, syscall.NewCallback(callback), uintptr(userParam), 0)\n}", "func PassThrough(token float32) {\n C.glowPassThrough(gpPassThrough, (C.GLfloat)(token))\n}", "func DebugMessageInsert(source uint32, xtype uint32, id uint32, severity uint32, length int32, buf *uint8) {\n\tC.glowDebugMessageInsert(gpDebugMessageInsert, (C.GLenum)(source), (C.GLenum)(xtype), (C.GLuint)(id), (C.GLenum)(severity), (C.GLsizei)(length), (*C.GLchar)(unsafe.Pointer(buf)))\n}", "func DebugMessageInsert(source uint32, xtype uint32, id uint32, severity uint32, length int32, buf *uint8) {\n\tC.glowDebugMessageInsert(gpDebugMessageInsert, (C.GLenum)(source), (C.GLenum)(xtype), (C.GLuint)(id), (C.GLenum)(severity), (C.GLsizei)(length), (*C.GLchar)(unsafe.Pointer(buf)))\n}", "func DebugMessageControl(source uint32, xtype uint32, severity uint32, count int32, ids *uint32, enabled bool) {\n C.glowDebugMessageControl(gpDebugMessageControl, (C.GLenum)(source), (C.GLenum)(xtype), (C.GLenum)(severity), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(ids)), (C.GLboolean)(boolToInt(enabled)))\n}", "func BindFragDataLocation(program uint32, color uint32, name *int8) {\n C.glowBindFragDataLocation(gpBindFragDataLocation, (C.GLuint)(program), (C.GLuint)(color), (*C.GLchar)(unsafe.Pointer(name)))\n}", "func InjectDebugCall(gp *g, fn any, regArgs *abi.RegArgs, stackArgs any, tkill func(tid int) error, returnOnUnsafePoint bool) (any, error) {\n\tif gp.lockedm == 0 {\n\t\treturn nil, plainError(\"goroutine not locked to thread\")\n\t}\n\n\ttid := int(gp.lockedm.ptr().procid)\n\tif tid == 0 {\n\t\treturn nil, plainError(\"missing tid\")\n\t}\n\n\tf := efaceOf(&fn)\n\tif f._type == nil || f._type.kind&kindMask != kindFunc {\n\t\treturn nil, plainError(\"fn must be a function\")\n\t}\n\tfv := (*funcval)(f.data)\n\n\ta := efaceOf(&stackArgs)\n\tif a._type != nil && a._type.kind&kindMask != kindPtr {\n\t\treturn nil, plainError(\"args must be a pointer or nil\")\n\t}\n\targp := a.data\n\tvar argSize uintptr\n\tif argp != nil {\n\t\targSize = (*ptrtype)(unsafe.Pointer(a._type)).elem.size\n\t}\n\n\th := new(debugCallHandler)\n\th.gp = gp\n\t// gp may not be running right now, but we can still get the M\n\t// it will run on since it's locked.\n\th.mp = gp.lockedm.ptr()\n\th.fv, h.regArgs, h.argp, h.argSize = fv, regArgs, argp, argSize\n\th.handleF = h.handle // Avoid allocating closure during signal\n\n\tdefer func() { testSigtrap = nil }()\n\tfor i := 0; ; i++ {\n\t\ttestSigtrap = h.inject\n\t\tnoteclear(&h.done)\n\t\th.err = \"\"\n\n\t\tif err := tkill(tid); err != nil {\n\t\t\treturn nil, err\n\t\t}\n\t\t// Wait for completion.\n\t\tnotetsleepg(&h.done, -1)\n\t\tif h.err != \"\" {\n\t\t\tswitch h.err {\n\t\t\tcase \"call not at safe point\":\n\t\t\t\tif returnOnUnsafePoint {\n\t\t\t\t\t// This is for TestDebugCallUnsafePoint.\n\t\t\t\t\treturn nil, h.err\n\t\t\t\t}\n\t\t\t\tfallthrough\n\t\t\tcase \"retry _Grunnable\", \"executing on Go runtime stack\", \"call from within the Go runtime\":\n\t\t\t\t// These are transient states. Try to get out of them.\n\t\t\t\tif i < 100 {\n\t\t\t\t\tusleep(100)\n\t\t\t\t\tGosched()\n\t\t\t\t\tcontinue\n\t\t\t\t}\n\t\t\t}\n\t\t\treturn nil, h.err\n\t\t}\n\t\treturn h.panic, nil\n\t}\n}", "func FramebufferParameteri(target uint32, pname uint32, param int32) {\n C.glowFramebufferParameteri(gpFramebufferParameteri, (C.GLenum)(target), (C.GLenum)(pname), (C.GLint)(param))\n}", "func GetProgramInfoLog(program uint32, bufSize int32, length *int32, infoLog *int8) {\n C.glowGetProgramInfoLog(gpGetProgramInfoLog, (C.GLuint)(program), (C.GLsizei)(bufSize), (*C.GLsizei)(unsafe.Pointer(length)), (*C.GLchar)(unsafe.Pointer(infoLog)))\n}", "func BindFragDataLocationIndexed(program uint32, colorNumber uint32, index uint32, name *int8) {\n C.glowBindFragDataLocationIndexed(gpBindFragDataLocationIndexed, (C.GLuint)(program), (C.GLuint)(colorNumber), (C.GLuint)(index), (*C.GLchar)(unsafe.Pointer(name)))\n}", "func _debugf(format string, args ...interface{}) {\n\tif v(1) {\n\t\targs = append([]interface{}{_caller(2)}, args...)\n\t\tfmt.Printf(\"%s: \"+format+\"\\n\", args...)\n\t}\n}", "func (native *OpenGL) GLGetProgramInfoLog(program uint32, bufSize int32, length *int32, infoLog *uint8) {\n\tgl.GetProgramInfoLog(program, bufSize, length, infoLog)\n}", "func GetVertexAttribLdv(index uint32, pname uint32, params *float64) {\n C.glowGetVertexAttribLdv(gpGetVertexAttribLdv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLdouble)(unsafe.Pointer(params)))\n}", "func (p *Provider) Debug(debug bool) {}", "func (p *Provider) Debug(debug bool) {}", "func (p *Provider) Debug(debug bool) {}", "func (p *Provider) Debug(debug bool) {}", "func DepthFunc(xfunc uint32) {\n C.glowDepthFunc(gpDepthFunc, (C.GLenum)(xfunc))\n}", "func AlphaFunc(xfunc uint32, ref float32) {\n C.glowAlphaFunc(gpAlphaFunc, (C.GLenum)(xfunc), (C.GLfloat)(ref))\n}", "func (native *OpenGL) LogOpenGLWarn() {\n\tif err := gl.GetError(); err != oglconsts.NO_ERROR {\n\t\tsettings.LogWarn(\"[OpenGL Error] Error occured: %v\", err)\n\t}\n}", "func (s *BasevhdlListener) EnterActual_parameter_part(ctx *Actual_parameter_partContext) {}", "func IfMydebug(f func()) {\n\t// f()\n}", "func Debug(v ...interface{}) { std.lprint(DEBUG, v...) }", "func (p *fakeLogger) Debug(msg string, fields ...string) {\n\tif p.callback != nil {\n\t\tp.callback(msg)\n\t}\n}", "func Dev(traceID string, funcName string, format string, a ...interface{}) {\n\tl.DevOffset(traceID, 1, funcName, format, a...)\n}", "func debug(m string, v interface{}) {\n\tif DebugMode {\n\t\tlog.Printf(m+\":%+v\", v)\n\t}\n}", "func GetShaderInfoLog(shader uint32, bufSize int32, length *int32, infoLog *int8) {\n C.glowGetShaderInfoLog(gpGetShaderInfoLog, (C.GLuint)(shader), (C.GLsizei)(bufSize), (*C.GLsizei)(unsafe.Pointer(length)), (*C.GLchar)(unsafe.Pointer(infoLog)))\n}", "func (s *BaseGraffleParserListener) EnterBuilt_func_print(ctx *Built_func_printContext) {}", "func (fp MockProvider) Debug(b bool) {\n\tfp.faux.Debug(b)\n}", "func Debug(v bool, m ...interface{}) {\n\tif v {\n\t\tpc := make([]uintptr, 15)\n\t\tn := runtime.Callers(2, pc)\n\t\tframes := runtime.CallersFrames(pc[:n])\n\t\tframe, _ := frames.Next()\n\t\tlog.Printf(\"DEBUG [%v] %v\", frame.Function, fmt.Sprintln(m...))\n\t}\n}", "func (l *stubLogger) Debugf(format string, args ...interface{}) {}", "func ActiveShaderProgram(pipeline uint32, program uint32) {\n C.glowActiveShaderProgram(gpActiveShaderProgram, (C.GLuint)(pipeline), (C.GLuint)(program))\n}", "func GetVertexAttribfv(index uint32, pname uint32, params *float32) {\n C.glowGetVertexAttribfv(gpGetVertexAttribfv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLfloat)(unsafe.Pointer(params)))\n}", "func (s *BaseConcertoListener) EnterFuncCallArg(ctx *FuncCallArgContext) {}", "func Bcm2835_set_debug(Debug byte) {\n\tcDebug, _ := (C.uint8_t)(Debug), cgoAllocsUnknown\n\tC.bcm2835_set_debug(cDebug)\n}", "func TexParameterf(target Enum, pname Enum, param Float) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tcpname, _ := (C.GLenum)(pname), cgoAllocsUnknown\n\tcparam, _ := (C.GLfloat)(param), cgoAllocsUnknown\n\tC.glTexParameterf(ctarget, cpname, cparam)\n}", "func (s *BasePlSqlParserListener) ExitLibrary_debug(ctx *Library_debugContext) {}", "func Debugf(format string, v ...interface{}) { std.lprintf(DEBUG, format, v...) }", "func HandleLdv(em *Emulator, a int, b int) {\n addr := em.GetWordReg(b)\n data := em.VideoMemoryLoad(addr)\n em.SetReg(a, data)\n em.LogInstruction(\"ldv %s, %s -- VMEM[0x%04X] = 0x%02X\", RegisterNames[a],\n WordRegisterNames[b >> 1], addr, data)\n \n em.timer += 7;\n}", "func TexParameteri(target Enum, pname Enum, param Int) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tcpname, _ := (C.GLenum)(pname), cgoAllocsUnknown\n\tcparam, _ := (C.GLint)(param), cgoAllocsUnknown\n\tC.glTexParameteri(ctarget, cpname, cparam)\n}", "func UseProgram(program uint32) {\n C.glowUseProgram(gpUseProgram, (C.GLuint)(program))\n}", "func (native *OpenGL) GLGetShaderInfoLog(shader uint32, bufSize int32, length *int32, infoLog *uint8) {\n\tgl.GetShaderInfoLog(shader, bufSize, length, infoLog)\n}", "func BindVertexArray(array uint32) {\n C.glowBindVertexArray(gpBindVertexArray, (C.GLuint)(array))\n}", "func DrawTransformFeedbackInstanced(mode uint32, id uint32, instancecount int32) {\n C.glowDrawTransformFeedbackInstanced(gpDrawTransformFeedbackInstanced, (C.GLenum)(mode), (C.GLuint)(id), (C.GLsizei)(instancecount))\n}", "func DrawTransformFeedback(mode uint32, id uint32) {\n C.glowDrawTransformFeedback(gpDrawTransformFeedback, (C.GLenum)(mode), (C.GLuint)(id))\n}", "func selectDebug() {\n\tDEBUG_GATE = false\n\tDEBUG_STATE = true\n}", "func (l Layout) DebugRender(win *pixelgl.Window) {\n\tfor key := range l.Panels {\n\t\tpanel := l.CreatePanel(key)\n\t\tpanel.Draw(win)\n\t}\n\n\t//temp camera matrix\n\t//cam := pixel.IM.Scaled(l.centerPos, 1.0).Moved(l.centerPos)\n\t//win.SetMatrix(cam)\n}", "func dg() {\n\tgl.Dump() // doesn't need context.\n\n\t// Also print the opengl version which does need a context.\n\tapp := device.New(\"Dump\", 400, 100, 600, 600)\n\tfmt.Printf(\"%s %s\", gl.GetString(gl.RENDERER), gl.GetString(gl.VERSION))\n\tfmt.Printf(\" GLSL %s\\n\", gl.GetString(gl.SHADING_LANGUAGE_VERSION))\n\tapp.Dispose()\n}", "func GetDebugMessageLog(count uint32, bufSize int32, sources *uint32, types *uint32, ids *uint32, severities *uint32, lengths *int32, messageLog *int8) uint32 {\n ret := C.glowGetDebugMessageLog(gpGetDebugMessageLog, (C.GLuint)(count), (C.GLsizei)(bufSize), (*C.GLenum)(unsafe.Pointer(sources)), (*C.GLenum)(unsafe.Pointer(types)), (*C.GLuint)(unsafe.Pointer(ids)), (*C.GLenum)(unsafe.Pointer(severities)), (*C.GLsizei)(unsafe.Pointer(lengths)), (*C.GLchar)(unsafe.Pointer(messageLog)))\n return (uint32)(ret)\n}", "func (native *OpenGL) GLBindFragDataLocation(program uint32, color uint32, name *uint8) {\n\tgl.BindFragDataLocation(program, color, name)\n}", "func (l *ExtendedLevelFilteredLoggerWrapper) DebugFn(format string, params ParamsFn) {\n\tif l.level >= LevelDebug {\n\t\tl.delegate.Debug(l.sprintf(format, params))\n\t}\n}", "func handleDebugSignal(_ context.Context) {\n}", "func (_m *Logger) Debug(msg string, additionalValues ...interface{}) {\n\tvar _ca []interface{}\n\t_ca = append(_ca, msg)\n\t_ca = append(_ca, additionalValues...)\n\t_m.Called(_ca...)\n}", "func Debugf(msg ...interface{}) {\n\trunAdapters(DebugLog, FormattedOut, msg...)\n}", "func DepthFunc(func_ GLenum) {\n\tC.glDepthFunc(C.GLenum(func_))\n}", "func GetVertexAttribdv(index uint32, pname uint32, params *float64) {\n C.glowGetVertexAttribdv(gpGetVertexAttribdv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLdouble)(unsafe.Pointer(params)))\n}", "func FramebufferParameteri(target uint32, pname uint32, param int32) {\n\tC.glowFramebufferParameteri(gpFramebufferParameteri, (C.GLenum)(target), (C.GLenum)(pname), (C.GLint)(param))\n}", "func FramebufferParameteri(target uint32, pname uint32, param int32) {\n\tC.glowFramebufferParameteri(gpFramebufferParameteri, (C.GLenum)(target), (C.GLenum)(pname), (C.GLint)(param))\n}", "func (l *MemoryLogger) Debug(msg string, keyvals ...interface{}) {\n\tl.println(\"DEBUG\", msg, keyvals)\n}", "func LogDebug(context string, module string, info string) {\n log.Debug().\n Str(\"Context\", context).\n Str(\"Module\", module).\n Msg(info)\n}", "func (a CompatLoggerAdapter) Debugf(format string, v ...interface{}) {\n\ta.Printf(\"DEBUG: \"+format, v...)\n}", "func runtime_procPin()", "func (*ModuleBase) OnFrameChange() {}", "func Debugf(format string, args ...interface{}) { logRaw(LevelDebug, 2, format, args...) }", "func CallList(list uint32) {\n C.glowCallList(gpCallList, (C.GLuint)(list))\n}", "func (l *XORMLogBridge) Debugf(format string, v ...interface{}) {\n\tlog.Debugf(format, v...)\n}", "func DrawBuffer(mode uint32) {\n C.glowDrawBuffer(gpDrawBuffer, (C.GLenum)(mode))\n}", "func (ml *MemoryLogger) LogDebug(m ...interface{}) {\n\tml.RingBuffer.Add(fmt.Sprintf(\"debug: %v\", fmt.Sprint(m...)))\n}", "func (_m *Logger) Debug(args ...interface{}) {\n\tvar _ca []interface{}\n\t_ca = append(_ca, args...)\n\t_m.Called(_ca...)\n}", "func (s *BaseSyslParserListener) EnterView_param(ctx *View_paramContext) {}", "func (c Context) Debug(msg string) {\n\tc.Log(40, msg, GetCallingFunction())\n}", "func DBG(f string, a ...interface{}) {\n\tLog.LLog(slog.LDBG, 1, pDBG, f, a...)\n}", "func myDebug(format string, a ...interface{}) {\n\tif FlagDebug {\n\t\tformat = fmt.Sprintf(\"[DEBUG] %s\\n\", format)\n\t\tfmt.Fprintf(os.Stderr, format, a...)\n\t}\n}", "func (l BlackHole) Debug(_ string, _ ...Field) {}", "func BindFragDataLocation(program uint32, color uint32, name *uint8) {\n\tC.glowBindFragDataLocation(gpBindFragDataLocation, (C.GLuint)(program), (C.GLuint)(color), (*C.GLchar)(unsafe.Pointer(name)))\n}", "func BindFragDataLocation(program uint32, color uint32, name *uint8) {\n\tC.glowBindFragDataLocation(gpBindFragDataLocation, (C.GLuint)(program), (C.GLuint)(color), (*C.GLchar)(unsafe.Pointer(name)))\n}", "func Debugf(format string, args ...interface{}) {\n\tl.Debug().Msgf(format, args...)\n}", "func (lgr *lager) Debugf(msg string, v ...interface{}) {\n\tlgr.logf(Debug, msg, v...)\n}", "func Debug(args ...interface{}) {\n\tif defaultLgr == nil {\n\t\treturn\n\t}\n\tdefaultLgr.Debugf(strings.TrimSpace(strings.Repeat(\"%+v \", len(args))), args...)\n}", "func Debugf(format string, params ...interface{}){\n log.Debugf(format, params)\n}", "func (l nullLogger) Debug(msg string, ctx ...interface{}) {}", "func (e *Engine) Debugf(format string, a ...interface{}) {\n\te.debug.Printf(format, a...)\n}", "func (nl *NullLogger) LogDebug(m ...interface{}) {\n}", "func Debug(fn func()) {\n\n\tSetDumpCode(\"1\")\n\tdefer SetDumpCode(\"0\")\n\tfn()\n}", "func (h *ISADebugger) Func(ctx akita.HookCtx) {\n\twf, ok := ctx.Item.(*Wavefront)\n\tif !ok {\n\t\treturn\n\t}\n\n\t// For debugging\n\t// if wf.FirstWiFlatID != 0 {\n\t// \treturn\n\t// }\n\n\th.logWholeWf(wf)\n\t// if h.prevWf == nil || h.prevWf.FirstWiFlatID != wf.FirstWiFlatID {\n\t// \th.logWholeWf(wf)\n\t// } else {\n\t// \th.logDiffWf(wf)\n\t// }\n\n\t// h.stubWf(wf)\n}" ]
[ "0.7167712", "0.6670752", "0.6367215", "0.6367215", "0.6003104", "0.5930139", "0.5875492", "0.5819321", "0.56413215", "0.55396223", "0.55020416", "0.5496406", "0.54678655", "0.5454606", "0.53230804", "0.51372975", "0.51099735", "0.50893986", "0.50893986", "0.5085339", "0.5068794", "0.5043129", "0.5029593", "0.5005768", "0.49410978", "0.48869798", "0.48801482", "0.48797652", "0.4879299", "0.4879299", "0.4879299", "0.4879299", "0.48719752", "0.48626763", "0.48529056", "0.48429805", "0.48364204", "0.4803616", "0.4800673", "0.47836533", "0.47831783", "0.47705582", "0.47685364", "0.47666517", "0.4756316", "0.47360697", "0.4724752", "0.4719106", "0.47104588", "0.47100085", "0.47073781", "0.47036326", "0.46931276", "0.46769217", "0.467113", "0.4669539", "0.46667325", "0.46576202", "0.46572834", "0.46504417", "0.46462452", "0.46434653", "0.46320903", "0.46257004", "0.46190503", "0.46042216", "0.4598307", "0.45894802", "0.45842323", "0.45809287", "0.4579737", "0.45694348", "0.45694348", "0.45630613", "0.45557672", "0.45526826", "0.45499754", "0.4549652", "0.4543212", "0.45422256", "0.45380095", "0.4531931", "0.45310894", "0.45301014", "0.45260078", "0.4520262", "0.4519387", "0.45145577", "0.4511473", "0.45089963", "0.45089963", "0.45030308", "0.45018098", "0.45001215", "0.44922474", "0.44828737", "0.44819096", "0.4481506", "0.44804817", "0.44796103" ]
0.73665047
0
control the reporting of debug messages in a debug context
func DebugMessageControl(source uint32, xtype uint32, severity uint32, count int32, ids *uint32, enabled bool) { C.glowDebugMessageControl(gpDebugMessageControl, (C.GLenum)(source), (C.GLenum)(xtype), (C.GLenum)(severity), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(ids)), (C.GLboolean)(boolToInt(enabled))) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func (l nullLogger) Debug(msg string, ctx ...interface{}) {}", "func handleDebugSignal(_ context.Context) {\n}", "func debug(message string) {\n if DebugMode {\n fmt.Fprintln(os.Stderr, \"DEBUG:\", message)\n }\n}", "func (r *Reporter) Debug(msg string, ctx ...interface{}) {\n\tif r.Logging != nil {\n\t\tr.Logging.Debug(msg, ctx...)\n\t}\n}", "func (c Context) Debug(msg string) {\n\tc.Log(40, msg, GetCallingFunction())\n}", "func (rl *limiter) Debug(enable bool) {\n\trl.debug = enable\n}", "func selectDebug() {\n\tDEBUG_GATE = false\n\tDEBUG_STATE = true\n}", "func Debug(ctx ...interface{}) {\n\tlogNormal(debugStatus, time.Now(), ctx...)\n}", "func (conn *Connection) debug(message string) {\n\tfmt.Println(\"Connection #\", conn.ID(), \"-\", message)\n\t//conn.SendInformation(message)\n}", "func (self *Subscribe) debugPrint() {\n\tself.dprint(\"\", 0)\n}", "func (d *DummyLogger) Debug(format string) {}", "func Debug(msg string){\n\tif IsDebug() {\n\t\tlog.Println(msg)\n\t}\n}", "func (w *Writer) Debug(m string) error {}", "func (app *App) debug(msg string) {\n\tif app.Debug {\n\t\tlog.Println(msg)\n\t}\n}", "func EnableDebug(ctx context.Context) context.Context {\n\treturn context.WithValue(ctx, logContextKeyDebug, true)\n}", "func (p *Provider) Debug(debug bool) {}", "func (p *Provider) Debug(debug bool) {}", "func (p *Provider) Debug(debug bool) {}", "func (p *Provider) Debug(debug bool) {}", "func (s *Scope) Debug(msg string, fields ...zapcore.Field) {\n\tif s.GetOutputLevel() >= DebugLevel {\n\t\ts.emit(zapcore.DebugLevel, s.GetStackTraceLevel() >= ErrorLevel, msg, fields)\n\t}\n}", "func Debug(msg ...interface{}) {\n\tCurrent.Debug(msg...)\n}", "func debug(s string) {\n\tif isDebugMode {\n\t\tfmt.Printf(\"DEBUG: %s\", s)\n\t}\n}", "func EnableDebug() {\n\tisDebug = true\n}", "func debugPrint(text string) {\n\tif (debugon) {\n\t\tfmt.Println(text)\n\t}\n}", "func (g GrcpGatewayLogger) Debug(msg string) {\n\tif g.logger.silent(DebugLevel) {\n\t\treturn\n\t}\n\te := g.logger.header(DebugLevel)\n\tif g.logger.Caller > 0 {\n\t\t_, file, line, _ := runtime.Caller(g.logger.Caller)\n\t\te.caller(file, line, g.logger.FullpathCaller)\n\t}\n\te.Context(g.context).Msg(msg)\n}", "func debug(format string, args ...interface{}) {\n\tif debugOn {\n\t\tlog.Printf(\"DEBUG: \"+format, args...)\n\t}\n}", "func (l *Logger) Debug(msg string) {\n\t// check if level is in config\n\t// if not, return\n\tif DEBUG&l.levels == 0 {\n\t\treturn\n\t}\n\te := Entry{Level: DEBUG, Message: msg}\n\n\te.enc = BorrowEncoder(l.w)\n\n\t// if we do not require a context then we\n\t// format with formatter and return.\n\tif l.contextName == \"\" {\n\t\tl.beginEntry(e.Level, msg, e)\n\t\tl.runHook(e)\n\t} else {\n\t\tl.openEntry(e.enc)\n\t}\n\n\tl.closeEntry(e)\n\tl.finalizeIfContext(e)\n\n\te.enc.Release()\n}", "func Debug(ctx context.Context, msg string, fields ...zap.Field) {\n\tFromContext(ctx).WithOptions(zap.AddCallerSkip(1)).Debug(msg, fields...)\n}", "func (patchwork *Patchwork) Debug() {\n\tpatchwork.debug = true\n}", "func debug(stuff string) {\n\tif DEBUG {\n\t\tfmt.Println(stuff)\n\t}\n}", "func (lc mockNotifyLogger) Debug(msg string, args ...interface{}) {\n}", "func Debug(c *common.Context, message string) {\n\tlog.WithFields(log.Fields{\n\t\t\"eventID\": c.EventID,\n\t\t\"correlationID\": c.CorrelationID,\n\t\t\"name\": c.Name,\n\t\t\"timestamp\": time.Now(),\n\t}).Debug(message)\n}", "func debugTrace(err error) {\n\tif debug != \"enable\" {\n\t\treturn\n\t}\n\tfmt.Println(\"StackTrace =====================\")\n\tfmt.Printf(\"%+v\\n\", err)\n}", "func Debug(msg string) {\n\tif lvl <= deb {\n\t\tl.Print(\"[DEBUG]: \" + msg)\n\t}\n}", "func Debug(ctx context.Context, err error) {\n\tif err == nil {\n\t\treturn\n\t}\n\tif ctx == nil {\n\t\tctx = defaultContext\n\t}\n\tif !verbose {\n\t\tif v, _ := ctx.Value(logContextKeyDebug).(bool); !v {\n\t\t\treturn\n\t\t}\n\t}\n\tctx = addSource(ctx, err)\n\n\tgetLogger(ctx).WithError(err).Infoln()\n}", "func myDebug(format string, a ...interface{}) {\n\tif FlagDebug {\n\t\tformat = fmt.Sprintf(\"[DEBUG] %s\\n\", format)\n\t\tfmt.Fprintf(os.Stderr, format, a...)\n\t}\n}", "func Debug(dbg bool) func(*Context) {\n\treturn func(ctx *Context) {\n\t\tif dbg {\n\t\t\tctx.msg.SetLevel(logger.DEBUG)\n\t\t}\n\t}\n}", "func Debugf(msg ...interface{}) {\n\trunAdapters(DebugLog, FormattedOut, msg...)\n}", "func EnableDebugMode() {\n\tDefaultLogger.Init(os.Stderr, LogLevelDebug)\n}", "func DebugCtx(ctx context.Context, format string, v ...interface{}) {\n\tif LogLevel >= 4 {\n\t\tlc := FromContext(ctx)\n\t\tif len(lc) > 0 {\n\t\t\tformat = fmt.Sprintf(\"%s %s\", lc, format)\n\t\t}\n\t\tDoLog(3, DEBUG, fmt.Sprintf(format, v...))\n\t}\n}", "func (l *MessageLogger) Debug(msg string) { l.logger.Debug(msg) }", "func Debug(ctx context.Context, args ...interface{}) {\n\tglobal.Debug(ctx, args...)\n}", "func debugLog(msg ...interface{}) {\n\tlogLocker.Lock()\n\tdefer logLocker.Unlock()\n\tif *confVerbose {\n\t\tcolor.White(fmt.Sprint(time.Now().Format(\"02_01_06-15.04.05\"), \"[DEBUG] ->\", msg))\n\t}\n}", "func debug(m string, v interface{}) {\n\tif DebugMode {\n\t\tlog.Printf(m+\":%+v\", v)\n\t}\n}", "func (w *PgxEntry) Debug(msg string, vars ...interface{}) {\n f := logrus.Fields{}\n for i := 0; i < len(vars)/2; i++ {\n f[vars[i*2].(string)] = vars[i*2+1]\n }\n (*logrus.Entry)(w).WithFields(f).Debug(msg)\n}", "func (c testCEEwriter) Debug(m string) error { return nil }", "func (ctx *Context) Debug(level int) {\n\tif level < logNone {\n\t\tlevel = logNone\n\t} else if level > logDebug {\n\t\tlevel = logDebug\n\t}\n\n\tctx.logLevel = level\n\n\t// If the log level is set to debug, then add the file info to the flags\n\tvar flags = log.LstdFlags | log.Lmsgprefix\n\tif level == logDebug {\n\t\tflags |= log.Lshortfile\n\t}\n\tctx.logger.SetFlags(flags)\n}", "func logDebug(r *http.Request, msg string) {\n\tif Debug {\n\t\tlogEvent(r, \"debug\", msg)\n\t}\n}", "func (this *FtpsClient) debugInfo(_Message_S string) {\n\n\tif this.FtpsParam_X.Debug_B {\n\t\tlog.Println(_Message_S)\n\t}\n}", "func Debug(ctx context.Context, args ...interface{}) {\n\tGetLogger().Log(ctx, loggers.DebugLevel, 1, args...)\n}", "func (p *Poloniex) Debug() {\r\n\tp.debug = true\r\n}", "func DCtx(ctx context.Context, format string, args ...interface{}) {\n\tif hub := sentry.GetHubFromContext(ctx); hub != nil {\n\t\tdebugdeps(hub.CaptureMessage, 3, format, args...)\n\t\treturn\n\t}\n\n\tdebugdeps(sentry.CaptureMessage, 3, format, args...)\n}", "func Debug(msg string) {\n log.Debug(msg)\n}", "func handleDebugSignal(ctx context.Context) {\n\tsigCh := make(chan os.Signal, 1)\n\tsignal.Notify(sigCh, unix.SIGUSR2)\n\n\tfor {\n\t\tselect {\n\t\tcase <-sigCh:\n\t\t\tpprof.Lookup(\"goroutine\").WriteTo(os.Stderr, 1)\n\t\tcase <-ctx.Done():\n\t\t\treturn\n\t\t}\n\t}\n}", "func (c *Client) debug(str string, args ...interface{}) {\n\tif c.level >= 2 {\n\t\tc.log.Printf(str, args...)\n\t}\n}", "func enable_debug() {\n\tnfo.SetOutput(nfo.DEBUG, os.Stdout)\n\tnfo.SetFile(nfo.DEBUG, nfo.GetFile(nfo.ERROR))\n}", "func Debugf(msg string, v ...interface{}) {\n\tif lvl <= deb {\n\t\tl.Printf(\"[DEBUG]: \"+msg, v...)\n\t}\n}", "func SetDebug() {\n\tglobalDebug = true\n}", "func Debug(str string, Pairs ...Pairs) {\n\tif logLevel > DEBUG {\n\t\treturn\n\t}\n\tcontextLogger := prepareContext(Pairs)\n\tcontextLogger.Debug(str)\n}", "func D(format string, args ...interface{}) { debugdeps(sentry.CaptureMessage, 3, format, args...) }", "func (s *Server) runDebug(ctx context.Context) error {\n\td := s.cfg.Debug\n\tif d.Address == \"\" {\n\t\t// Nothing to do, don't start the server.\n\t\treturn nil\n\t}\n\n\t// Configure the HTTP debug server.\n\tl, err := net.Listen(\"tcp\", d.Address)\n\tif err != nil {\n\t\treturn fmt.Errorf(\"failed to start debug listener: %v\", err)\n\t}\n\n\ts.ll.Printf(\"starting HTTP debug listener on %q: prometheus: %v, pprof: %v\",\n\t\td.Address, d.Prometheus, d.PProf)\n\n\t// Serve requests until the context is canceled.\n\ts.eg.Go(func() error {\n\t\t<-ctx.Done()\n\t\treturn l.Close()\n\t})\n\n\ts.eg.Go(func() error {\n\t\treturn serve(http.Serve(\n\t\t\tl, newHTTPHandler(d.Prometheus, d.PProf, s.reg),\n\t\t))\n\t})\n\n\treturn nil\n}", "func (logger *Logger) Fdebug(w io.Writer, a ...any) {\n\tlogger.echo(w, level.Debug, formatPrint, a...)\n}", "func DebugMessageControl(source uint32, xtype uint32, severity uint32, count int32, ids *uint32, enabled bool) {\n C.glowDebugMessageControl(gpDebugMessageControl, (C.GLenum)(source), (C.GLenum)(xtype), (C.GLenum)(severity), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(ids)), (C.GLboolean)(boolToInt(enabled)))\n}", "func (db RDB) debugf(msg string, args ...interface{}) {\n\tif db._log != nil {\n\t\tdb._log.Printf(msg, args...)\n\t}\n}", "func Debug(ctx context.Context, msg string, args ...Args) {\n\tL(ctx).Log(NewEntry(LevelDebug, msg, args...))\n}", "func CatchDebug() {\r\n\tsigchan := make(chan os.Signal, 1)\r\n\t//signal.Notify(sigchan, syscall.SIGUSR1)\r\n\tsignal.Notify(sigchan, syscall.Signal(0xa)) // SIGUSR1 = Signal(0xa)\r\n\tfor range sigchan {\r\n\t\tPrintProgramStatus()\r\n\t}\r\n}", "func SetDebugMode(b bool) { env.SetDebugMode(b) }", "func (log *logging) debugForced() bool {\n\treturn log.forced\n}", "func (ctx *Context) DebugUSB(level int) {\n\tctx.usbContext.Debug(level)\n}", "func (l *stubLogger) Debugf(format string, args ...interface{}) {}", "func printDebug(msg string) {\n\tif Debug {\n\t\tfmt.Println(fmt.Sprintf(\"DEBUG %s: %s\", getFormattedTime(), msg))\n\t}\n}", "func printDebug(msg string) {\n\tif Debug {\n\t\tfmt.Println(fmt.Sprintf(\"DEBUG %s: %s\", getFormattedTime(), msg))\n\t}\n}", "func catchDebug() {\n\tsigchan := make(chan os.Signal, 1)\n\t//signal.Notify(sigchan, syscall.SIGUSR1)\n\tsignal.Notify(sigchan, syscall.Signal(0xa)) // SIGUSR1 = Signal(0xa)\n\n\tfor {\n\t\tselect {\n\t\tcase <-sigchan:\n\t\t\tprintProgramStatus()\n\t\t}\n\t}\n}", "func Debug(msg string, ctx ...interface{}) {\n\tmetrics.GetOrRegisterCounter(\"debug\", nil).Inc(1)\n\tl.Output(msg, l.LvlDebug, CallDepth, ctx...)\n}", "func (wfw *impl) Debug(d bool) Interface { wfw.debug = d; return wfw }", "func (d *DummyLogger) Debugf(format string, args ...interface{}) {}", "func Debug(ctx context.Context, v ...interface{}) {\n\tlog := ExtractLogger(ctx)\n\tlog.Debug(v...)\n}", "func Debug(g *types.Cmd) {\n\tg.Debug = true\n}", "func SetDebug(flag bool) {\n\tdebug = flag\n}", "func (s *BasePlSqlParserListener) EnterLibrary_debug(ctx *Library_debugContext) {}", "func Debug(v ...interface{}) {\n\tif enableDebug {\n\t\tinfoLog(v...)\n\t}\n}", "func Debug(args ...interface{}) {\n LoggerOf(default_id).Debug(args...)\n}", "func Debug(ctx context.Context, args ...interface{}) {\n\tlog.WithFields(utils.GetCommonMetaFromCtx(ctx)).Debug(args...)\n}", "func (a *Adapter) Debug(ctx context.Context, message string, options ...interface{}) {\n\ta.log(ctx, levelDebug, message, options...)\n}", "func (l BlackHole) Debug(_ string, _ ...Field) {}", "func Debugw(msg string, fields Fields) {\n\tCurrent.Debugw(msg, fields)\n}", "func SetDebug(value bool) {\n\tdebug = value\n}", "func (s SugaredLogger) Debug(message string, fields ...interface{}) {\n\ts.zapLogger.Debugw(message, fields...)\n}", "func D(message ...interface{}) {\n\tif LOG_DEBUG <= LOG_LEVEL {\n\t\tfmt.Println(message...)\n\t}\n}", "func (l BlackHole) IsDebug() bool { return l.EnableDebug }", "func SetDebug(mode bool) {\n\tdebug = mode\n}", "func Debug(msg ...interface{}) {\n\tif LevelDebug >= logLevel {\n\t\tsyslog.Println(\"D:\", msg)\n\t}\n}", "func (stimLogger *FullStimLogger) Debug(message ...interface{}) {\n\tif stimLogger.highestLevel >= DebugLevel {\n\t\tif stimLogger.setLogger == nil {\n\t\t\tif stimLogger.forceFlush {\n\t\t\t\tstimLogger.writeLogs(stimLogger.formatString(DebugLevel, debugMsg, message...))\n\t\t\t} else {\n\t\t\t\tstimLogger.formatAndLog(DebugLevel, debugMsg, message...)\n\t\t\t}\n\t\t} else {\n\t\t\tstimLogger.setLogger.Debug(message...)\n\t\t}\n\t}\n}", "func LogDebug(context string, module string, info string) {\n log.Debug().\n Str(\"Context\", context).\n Str(\"Module\", module).\n Msg(info)\n}", "func (l *jsonLogger) DebugContext(ctx context.Context, message interface{}, params ...interface{}) {\n\tl.jsonLogParser.parse(ctx, l.jsonLogParser.log.Debug(), \"\", params...).Msgf(\"%s\", message)\n}", "func SetDebug(b bool) {\n\tisDebug = b\n}", "func (l *logHandler) Debug(args ...interface{}) {\n\tl.Log(LogDebug, 3, args...)\n}", "func (testLog TestLog) Debug(msg ...interface{}) {\n\ttestLog.T.Log(\"[Debug]\", msg)\n}", "func setDebug(w io.Writer, debug bool) {\n\tif !debug {\n\t\tpp.SetDefaultOutput(ioutil.Discard)\n\t\treturn\n\t}\n\tif w == nil {\n\t\tvar err error\n\t\tw, err = os.OpenFile(filepath.Join(\".\", \"ali-debug.log\"), os.O_CREATE|os.O_WRONLY|os.O_APPEND, 0666)\n\t\tif err != nil {\n\t\t\tpanic(err)\n\t\t}\n\t}\n\tpp.SetDefaultOutput(w)\n}", "func (client *GroupMgmtClient) EnableDebug() {\n\tclient.Client.SetDebug(true)\n}", "func printDebugPage(ctx context.Context) error {\n\ts, err := retrieveDebugPage(ctx)\n\tif err != nil {\n\t\treturn err\n\t}\n\tfmt.Println(s)\n\treturn nil\n}" ]
[ "0.6803932", "0.67588556", "0.66472065", "0.6538093", "0.6506046", "0.6501536", "0.64571935", "0.64331037", "0.6344445", "0.6319582", "0.6306223", "0.62899065", "0.6287556", "0.62689173", "0.6247058", "0.62301606", "0.62301606", "0.62301606", "0.62301606", "0.6227482", "0.62156826", "0.6207376", "0.61715084", "0.61663306", "0.6156837", "0.61532706", "0.6150424", "0.61305195", "0.6120262", "0.6119118", "0.61178416", "0.6113041", "0.6111779", "0.61096525", "0.61083984", "0.6103642", "0.6102448", "0.60747397", "0.6069522", "0.60677654", "0.6066503", "0.60566276", "0.604705", "0.60465574", "0.6043977", "0.60422736", "0.6022064", "0.60210735", "0.60166997", "0.6012933", "0.6007697", "0.5978095", "0.5972717", "0.59704196", "0.596865", "0.5968361", "0.59656185", "0.5955631", "0.594258", "0.59316593", "0.59299624", "0.5929854", "0.5928968", "0.59122455", "0.59109753", "0.59019905", "0.59001637", "0.5895858", "0.58781517", "0.5876769", "0.5868572", "0.5868572", "0.5864033", "0.58606845", "0.58462566", "0.584548", "0.5843786", "0.58419275", "0.5841717", "0.583175", "0.58247143", "0.58227867", "0.5818379", "0.58136356", "0.58119285", "0.5810954", "0.580756", "0.58053905", "0.58010757", "0.57937056", "0.5793119", "0.57919335", "0.5790129", "0.5788491", "0.57837486", "0.57809407", "0.5770068", "0.57697636", "0.57623464", "0.5760509", "0.57558274" ]
0.0
-1
inject an applicationsupplied message into the debug message queue
func DebugMessageInsert(source uint32, xtype uint32, id uint32, severity uint32, length int32, buf *uint8) { C.glowDebugMessageInsert(gpDebugMessageInsert, (C.GLenum)(source), (C.GLenum)(xtype), (C.GLuint)(id), (C.GLenum)(severity), (C.GLsizei)(length), (*C.GLchar)(unsafe.Pointer(buf))) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func DebugMessageInsert(source uint32, xtype uint32, id uint32, severity uint32, length int32, buf *uint8) {\n\tsyscall.Syscall6(gpDebugMessageInsert, 6, uintptr(source), uintptr(xtype), uintptr(id), uintptr(severity), uintptr(length), uintptr(unsafe.Pointer(buf)))\n}", "func DebugMessageInsert(source uint32, xtype uint32, id uint32, severity uint32, length int32, buf *int8) {\n C.glowDebugMessageInsert(gpDebugMessageInsert, (C.GLenum)(source), (C.GLenum)(xtype), (C.GLuint)(id), (C.GLenum)(severity), (C.GLsizei)(length), (*C.GLchar)(unsafe.Pointer(buf)))\n}", "func DebugMsg(msg string) {\n\tusedLogger.Debug(msg)\n}", "func (l *MessageLogger) Debug(msg string) { l.logger.Debug(msg) }", "func DebugMessage(msg string, a ...interface{}) {\n\tif sliceExists(Levels, \"DEBUG\") {\n\t\tfmt.Printf(\"[FRAME DEBUG] %s\\n\", fmt.Sprintf(msg, a...))\n\t}\n}", "func (app *App) debug(msg string) {\n\tif app.Debug {\n\t\tlog.Println(msg)\n\t}\n}", "func (ds *fakeDebugSession) send(message dap.Message) {\n\tds.sendQueue <- message\n}", "func (conn *Connection) debug(message string) {\n\tfmt.Println(\"Connection #\", conn.ID(), \"-\", message)\n\t//conn.SendInformation(message)\n}", "func DebugMessageCallback(callback unsafe.Pointer, userParam unsafe.Pointer) {\n\tsyscall.Syscall(gpDebugMessageCallback, 2, syscall.NewCallback(callback), uintptr(userParam), 0)\n}", "func (mc *MemCache) DEBUG_MSG(msg string) {\n\n\t// XXX STUB\n\n\treturn\n}", "func DebugMessageCallback(callback DebugProc, userParam unsafe.Pointer) {\n userDebugCallback = callback\n C.glowDebugMessageCallback(gpDebugMessageCallback, (C.GLDEBUGPROC)(unsafe.Pointer(&callback)), userParam)\n}", "func Debug(msg ...interface{}) {\n\tCurrent.Debug(msg...)\n}", "func (s *SlcLogger) Debug(message interface{}, title ...string) error {\n\treturn s.sendNotification(LevelDebug, colorDebug, message, title)\n}", "func Debug(message interface{}) {\n\tglobalLogger.Debug(message)\n}", "func DebugMessageCallbackAMD(callback unsafe.Pointer, userParam unsafe.Pointer) {\n\tsyscall.Syscall(gpDebugMessageCallbackAMD, 2, uintptr(callback), uintptr(userParam), 0)\n}", "func DebugMessageCallback(callback DebugProc, userParam unsafe.Pointer) {\n\tuserDebugCallback = callback\n\tC.glowDebugMessageCallback(gpDebugMessageCallback, (C.GLDEBUGPROC)(unsafe.Pointer(&callback)), userParam)\n}", "func DebugMessageCallback(callback DebugProc, userParam unsafe.Pointer) {\n\tuserDebugCallback = callback\n\tC.glowDebugMessageCallback(gpDebugMessageCallback, (C.GLDEBUGPROC)(unsafe.Pointer(&callback)), userParam)\n}", "func Debugf(msg ...interface{}) {\n\trunAdapters(DebugLog, FormattedOut, msg...)\n}", "func (lc mockNotifyLogger) Debug(msg string, args ...interface{}) {\n}", "func (ml *MemoryLogger) LogDebug(m ...interface{}) {\n\tml.RingBuffer.Add(fmt.Sprintf(\"debug: %v\", fmt.Sprint(m...)))\n}", "func debug(message string) {\n if DebugMode {\n fmt.Fprintln(os.Stderr, \"DEBUG:\", message)\n }\n}", "func Debug(msg string){\n\tif IsDebug() {\n\t\tlog.Println(msg)\n\t}\n}", "func (g *Game) addMessage(text string) {\n\tg.Messages.PushMessage(text)\n}", "func (g GrcpGatewayLogger) Debug(msg string) {\n\tif g.logger.silent(DebugLevel) {\n\t\treturn\n\t}\n\te := g.logger.header(DebugLevel)\n\tif g.logger.Caller > 0 {\n\t\t_, file, line, _ := runtime.Caller(g.logger.Caller)\n\t\te.caller(file, line, g.logger.FullpathCaller)\n\t}\n\te.Context(g.context).Msg(msg)\n}", "func DebugMessageCallbackARB(callback unsafe.Pointer, userParam unsafe.Pointer) {\n\tsyscall.Syscall(gpDebugMessageCallbackARB, 2, syscall.NewCallback(callback), uintptr(userParam), 0)\n}", "func (_m *Logger) Debug(msg string, additionalValues ...interface{}) {\n\tvar _ca []interface{}\n\t_ca = append(_ca, msg)\n\t_ca = append(_ca, additionalValues...)\n\t_m.Called(_ca...)\n}", "func (sle *SystemLogWriter) Debug(msg string, args ...interface{}) error {\n\treturn sle.out.WriteEvent(context.Background(), sle.gen.Debug(msg, args...))\n}", "func Debug(message interface{}) {\n\tlogging.Debug(message)\n}", "func DebugMessageCallbackAMD(callback unsafe.Pointer, userParam unsafe.Pointer) {\n\tC.glowDebugMessageCallbackAMD(gpDebugMessageCallbackAMD, (C.GLDEBUGPROCAMD)(callback), userParam)\n}", "func (p *fakeLogger) Debug(msg string, fields ...string) {\n\tif p.callback != nil {\n\t\tp.callback(msg)\n\t}\n}", "func DebugMessageCallbackKHR(callback unsafe.Pointer, userParam unsafe.Pointer) {\n\tsyscall.Syscall(gpDebugMessageCallbackKHR, 2, syscall.NewCallback(callback), uintptr(userParam), 0)\n}", "func Debug(a interfaces.AssumeCredentialProcess, emoji string, prefix string, message string) {\n\ts := a.GetDestination()\n\tf := a.GetFlags()\n\tif f.Verbose {\n\t\tformatted := format(a, textColorDebug, emoji, prefix, message)\n\t\tfmt.Fprint(s, formatted)\n\t}\n}", "func (l nullLogger) Debug(msg string, ctx ...interface{}) {}", "func (l *BasicLogger) Debug(msg string) {\n\tl.appendLogEvent(level.DebugLevel, msg)\n}", "func (room *Room) AddMessage(message string) {\n\troom.queue <- message\n}", "func sentMessage(s string) {\n\tfmt.Printf(\"let me sent some msg : %#v\\n\", s)\n}", "func (ds *fakeDebugSession) sendFromQueue() {\n\tfor message := range ds.sendQueue {\n\t\tdap.WriteProtocolMessage(ds.rw.Writer, message)\n\t\tlog.Printf(\"Message sent\\n\\t%#v\\n\", message)\n\t\tds.rw.Flush()\n\t}\n}", "func D(format string, args ...interface{}) { debugdeps(sentry.CaptureMessage, 3, format, args...) }", "func (c *app) Queue(m message) {\n\tc.out <- m\n}", "func (l *logger) Debug(message lua.String) error {\n\tl.monitor.Debug(string(message))\n\treturn nil\n}", "func (l *comLogger) Debug(msg string) {\n\tl.Log(Debug, msg)\n}", "func printDebug(msg string) {\n\tif Debug {\n\t\tfmt.Println(fmt.Sprintf(\"DEBUG %s: %s\", getFormattedTime(), msg))\n\t}\n}", "func printDebug(msg string) {\n\tif Debug {\n\t\tfmt.Println(fmt.Sprintf(\"DEBUG %s: %s\", getFormattedTime(), msg))\n\t}\n}", "func Debug(msg string) {\n log.Debug(msg)\n}", "func (l *Logger) Debug(message string) {\n\tl.printLogMessage(keptnLogMessage{Timestamp: time.Now(), Message: message, LogLevel: \"DEBUG\"})\n}", "func debugMsg(rcode int, r *dns.Msg) *dns.Msg {\n\tanswer := new(dns.Msg)\n\tanswer.SetRcode(r, rcode)\n\treturn answer\n}", "func (this *FtpsClient) debugInfo(_Message_S string) {\n\n\tif this.FtpsParam_X.Debug_B {\n\t\tlog.Println(_Message_S)\n\t}\n}", "func (c Context) Debug(msg string) {\n\tc.Log(40, msg, GetCallingFunction())\n}", "func (r *Reporter) Debug(msg string, ctx ...interface{}) {\n\tif r.Logging != nil {\n\t\tr.Logging.Debug(msg, ctx...)\n\t}\n}", "func Debug(c *common.Context, message string) {\n\tlog.WithFields(log.Fields{\n\t\t\"eventID\": c.EventID,\n\t\t\"correlationID\": c.CorrelationID,\n\t\t\"name\": c.Name,\n\t\t\"timestamp\": time.Now(),\n\t}).Debug(message)\n}", "func Debugw(msg string, args ...interface{}) {\n\tl.Debug().Fields(sweetenFields(args)).Msg(msg)\n}", "func DebugMessageControl(source uint32, xtype uint32, severity uint32, count int32, ids *uint32, enabled bool) {\n C.glowDebugMessageControl(gpDebugMessageControl, (C.GLenum)(source), (C.GLenum)(xtype), (C.GLenum)(severity), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(ids)), (C.GLboolean)(boolToInt(enabled)))\n}", "func (z *Logger) Debugw(msg string, keysandvalues ...interface{}) {\n\tz.SugaredLogger.Debugw(msg, keysandvalues...)\n}", "func logDebug(r *http.Request, msg string) {\n\tif Debug {\n\t\tlogEvent(r, \"debug\", msg)\n\t}\n}", "func (p *MasterWorker) Debug(key, format string, args ...interface{}) error {\n\treturn p.Printf(false, key, format, args...)\n}", "func (s *redisRawPubSubStub) EnqueueMessage(msg interface{}) {\n\ts.messageQueue <- msg\n}", "func (q *FakeQueueDispatcher) DispatchMessage(message interface{}) (err error) {\n\tq.Messages = append(q.Messages, message)\n\treturn\n}", "func (qs *queuedSender) Enqueue(message string) {\n\tqs.queue = append(qs.queue, message)\n}", "func (d *Dry) message(message string) {\n\tselect {\n\tcase d.output <- message:\n\tdefault:\n\t}\n}", "func handleDebugSignal(_ context.Context) {\n}", "func PushDebugGroup(source uint32, id uint32, length int32, message *int8) {\n C.glowPushDebugGroup(gpPushDebugGroup, (C.GLenum)(source), (C.GLuint)(id), (C.GLsizei)(length), (*C.GLchar)(unsafe.Pointer(message)))\n}", "func (self *Subscribe) debugPrint() {\n\tself.dprint(\"\", 0)\n}", "func (w *Writer) Debug(m string) error {}", "func myDebug(format string, a ...interface{}) {\n\tif FlagDebug {\n\t\tformat = fmt.Sprintf(\"[DEBUG] %s\\n\", format)\n\t\tfmt.Fprintf(os.Stderr, format, a...)\n\t}\n}", "func DebugMessageControl(source uint32, xtype uint32, severity uint32, count int32, ids *uint32, enabled bool) {\n\tC.glowDebugMessageControl(gpDebugMessageControl, (C.GLenum)(source), (C.GLenum)(xtype), (C.GLenum)(severity), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(ids)), (C.GLboolean)(boolToInt(enabled)))\n}", "func DebugMessageControl(source uint32, xtype uint32, severity uint32, count int32, ids *uint32, enabled bool) {\n\tC.glowDebugMessageControl(gpDebugMessageControl, (C.GLenum)(source), (C.GLenum)(xtype), (C.GLenum)(severity), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(ids)), (C.GLboolean)(boolToInt(enabled)))\n}", "func DebugMessageControl(source uint32, xtype uint32, severity uint32, count int32, ids *uint32, enabled bool) {\n\tsyscall.Syscall6(gpDebugMessageControl, 6, uintptr(source), uintptr(xtype), uintptr(severity), uintptr(count), uintptr(unsafe.Pointer(ids)), boolToUintptr(enabled))\n}", "func (w *PgxEntry) Debug(msg string, vars ...interface{}) {\n f := logrus.Fields{}\n for i := 0; i < len(vars)/2; i++ {\n f[vars[i*2].(string)] = vars[i*2+1]\n }\n (*logrus.Entry)(w).WithFields(f).Debug(msg)\n}", "func (l *jsonLogger) Debug(message interface{}, params ...interface{}) {\n\tl.jsonLogParser.parse(context.Background(), l.jsonLogParser.log.Debug(), \"\", params...).Msgf(\"%s\", message)\n}", "func (s SugaredLogger) Debug(message string, fields ...interface{}) {\n\ts.zapLogger.Debugw(message, fields...)\n}", "func (dl *defaultLogger) Debug(msg string) {\n\tdl.Print(msg)\n}", "func (logger *Logger) Fdebug(w io.Writer, a ...any) {\n\tlogger.echo(w, level.Debug, formatPrint, a...)\n}", "func MessageLoggerSender(n *notif.SlackNotifier) {\n\t// for {\n\t// \tif len(messagesQueue) > 0 {\n\t// \t\tmsg := messagesQueue.Pop()\n\t// \t\tif n != nil {\n\t// \t\t\tif err := n.Notify(fmt.Sprintf(\"```%s```\", msg)); err != nil {\n\t// \t\t\t\tlog.Println(\"NOTIFY TO SLACK ERROR: \", err)\n\t// \t\t\t\tmessagesQueue = append(messagesQueue, msg)\n\t// \t\t\t}\n\t// \t\t}\n\t// \t\ttime.Sleep(10 * time.Millisecond)\n\t// \t} else {\n\t// \t\ttime.Sleep(10 * time.Second)\n\t// \t}\n\t// }\n}", "func (l *Logger) Debugw(msg string, keysAndValues ...interface{}) {\n\tl.sgLogger.Debugw(msg, keysAndValues...)\n\t_ = l.lg.Sync()\n}", "func (p *PlayScreen) AddMessage(msg string) {\n\tp.msgList = append(p.msgList, msg)\n}", "func (customLogger *CustomLogger) Debug(message string) {\n\tcustomLogger.logger.Debug(message)\n}", "func (l *MemoryLogger) Debug(msg string, keyvals ...interface{}) {\n\tl.println(\"DEBUG\", msg, keyvals)\n}", "func showMessage(w http.ResponseWriter, title string, message string, teamID string, backLink string) {\n\ttemplate.Must(template.New(\"\").Parse(tMessage)).Execute(w, map[string]string{\n\t\t\"PageTitle\": title,\n\t\t\"Message\": message,\n\t\t\"TID\": teamID,\n\t\t\"GoBack\": backLink,\n\t})\n}", "func (stimLogger *FullStimLogger) Debug(message ...interface{}) {\n\tif stimLogger.highestLevel >= DebugLevel {\n\t\tif stimLogger.setLogger == nil {\n\t\t\tif stimLogger.forceFlush {\n\t\t\t\tstimLogger.writeLogs(stimLogger.formatString(DebugLevel, debugMsg, message...))\n\t\t\t} else {\n\t\t\t\tstimLogger.formatAndLog(DebugLevel, debugMsg, message...)\n\t\t\t}\n\t\t} else {\n\t\t\tstimLogger.setLogger.Debug(message...)\n\t\t}\n\t}\n}", "func (s *Scheduler) insertHotString(message Message) error {\n\tdefer func() {\n\t\trecover()\n\t}()\n\terr := s.hot.Push(message)\n\ts.hot.Kick <- true\n\treturn err\n}", "func (s *Scope) Debug(msg string, fields ...zapcore.Field) {\n\tif s.GetOutputLevel() >= DebugLevel {\n\t\ts.emit(zapcore.DebugLevel, s.GetStackTraceLevel() >= ErrorLevel, msg, fields)\n\t}\n}", "func DebugMessage(a ...interface{}) (n int, err error) {\n\tif VerboseLogging {\n\t\tn, err = MessageWithType(MsgDebug, a...)\n\t\treturn n, err\n\t}\n\treturn 0, nil\n}", "func (l *AppLogger) Debug(tag string, message ...interface{}) {\n\tl.logging.SetFormatter(&logrus.JSONFormatter{})\n\tk := getAppFields(l.reqId, tag, l.userId)\n\tl.logging.WithFields(k).Debug(message...)\n}", "func (w *Workspace) notifyLog(message string) {\n\tw.session.log.Debugf(context.Background(), \"%s\", message)\n}", "func (_m *LoggerItf) Debug(msg string, fields ...zapcore.Field) {\n\t_va := make([]interface{}, len(fields))\n\tfor _i := range fields {\n\t\t_va[_i] = fields[_i]\n\t}\n\tvar _ca []interface{}\n\t_ca = append(_ca, msg)\n\t_ca = append(_ca, _va...)\n\t_m.Called(_ca...)\n}", "func logDebug(text string, params ...interface{}) {\n\tif !*debug {\n\t\treturn\n\t}\n\tline := fmt.Sprintf(text, params...)\n\tlog.Printf(\"DEBUG: %s\", line)\n}", "func PushDebugGroup(source uint32, id uint32, length int32, message *uint8) {\n\tC.glowPushDebugGroup(gpPushDebugGroup, (C.GLenum)(source), (C.GLuint)(id), (C.GLsizei)(length), (*C.GLchar)(unsafe.Pointer(message)))\n}", "func PushDebugGroup(source uint32, id uint32, length int32, message *uint8) {\n\tC.glowPushDebugGroup(gpPushDebugGroup, (C.GLenum)(source), (C.GLuint)(id), (C.GLsizei)(length), (*C.GLchar)(unsafe.Pointer(message)))\n}", "func (j *jobMessage) preSendMessage(key string, val string, match string) {\n\tif bytes.Contains([]byte(key), []byte(match)) {\n\t\t//j.FatalMessageChan[key] <- val\n\t}\n}", "func (l *Logger) Debug(msg string, args ...interface{}) {\n\tl.z.Debugw(msg, args...)\n}", "func SendMessageToQueue(msg interface{}, queueName string) {\n sendMessage(msg, DefaultExchange, \"\", queueName, \"\", false)\n}", "func Debug(message string) {\n\tif DebugLogFunc != nil {\n\t\tDebugLogFunc(strings.TrimRight(message, \" \\r\\n\\t\"))\n\t}\n}", "func D(w Writer, tag Tag, message string) error {\n\treturn w.Write(PriorityDebug, tag, message)\n}", "func Debug(msg string) {\n\tif lvl <= deb {\n\t\tl.Print(\"[DEBUG]: \" + msg)\n\t}\n}", "func Debugw(message string, fields ...zapcore.Field) {\n\tDefaultLogger.Debugw(message, fields...)\n}", "func LogDebug(context string, module string, info string) {\n log.Debug().\n Str(\"Context\", context).\n Str(\"Module\", module).\n Msg(info)\n}", "func (object *MQMessageHandler) OnMQMessage(raw []byte, offset int64) {\n}", "func (l *Logger) Queued(url string) {\n\tl.m.Lock()\n\tdefer l.m.Unlock()\n\tl.Log = append(l.Log, fmt.Sprintf(\"queue %s\", url))\n}", "func (f Freckle) log(msg string, data ...interface{}) {\n\tif f.debug {\n\t\tlog.Printf(\"DEBUG: %s\", fmt.Sprintf(msg, data...))\n\t}\n}" ]
[ "0.64815396", "0.62499946", "0.619437", "0.61480385", "0.60640895", "0.5917219", "0.59155756", "0.57664645", "0.5756736", "0.57101834", "0.56690884", "0.5662995", "0.565094", "0.56439376", "0.56079483", "0.557113", "0.557113", "0.5568565", "0.54993165", "0.5487376", "0.54530895", "0.5449716", "0.5421944", "0.5407695", "0.53877485", "0.5385234", "0.53554195", "0.53545374", "0.5351069", "0.5349491", "0.53476727", "0.53454745", "0.5342968", "0.53366506", "0.5335396", "0.5327281", "0.53250897", "0.5323585", "0.53131294", "0.5309906", "0.52799124", "0.5276619", "0.5276619", "0.5274791", "0.5270346", "0.5267984", "0.52606696", "0.5259442", "0.5258176", "0.52536476", "0.5247599", "0.5247111", "0.52454835", "0.5228724", "0.5228079", "0.5220753", "0.5209926", "0.5207415", "0.52031916", "0.5192031", "0.5189781", "0.5177412", "0.51761013", "0.5173552", "0.5171073", "0.5171073", "0.5166525", "0.51576126", "0.51530355", "0.5151108", "0.5144412", "0.51328456", "0.5129071", "0.5126678", "0.51219416", "0.5117698", "0.51087064", "0.5107621", "0.5104377", "0.5097418", "0.5096351", "0.5091413", "0.50822425", "0.50815713", "0.50784063", "0.5076608", "0.5073357", "0.5073357", "0.5066486", "0.5060056", "0.50574094", "0.50523686", "0.50450665", "0.50384873", "0.5037852", "0.50346917", "0.50342786", "0.5032286", "0.5022185" ]
0.63857657
2
delete named buffer objects
func DeleteBuffers(n int32, buffers *uint32) { C.glowDeleteBuffers(gpDeleteBuffers, (C.GLsizei)(n), (*C.GLuint)(unsafe.Pointer(buffers))) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func ClearNamedBufferData(buffer uint32, internalformat uint32, format uint32, xtype uint32, data unsafe.Pointer) {\n\tsyscall.Syscall6(gpClearNamedBufferData, 5, uintptr(buffer), uintptr(internalformat), uintptr(format), uintptr(xtype), uintptr(data), 0)\n}", "func ClearNamedBufferData(buffer uint32, internalformat uint32, format uint32, xtype uint32, data unsafe.Pointer) {\n\tC.glowClearNamedBufferData(gpClearNamedBufferData, (C.GLuint)(buffer), (C.GLenum)(internalformat), (C.GLenum)(format), (C.GLenum)(xtype), data)\n}", "func ClearNamedBufferData(buffer uint32, internalformat uint32, format uint32, xtype uint32, data unsafe.Pointer) {\n\tC.glowClearNamedBufferData(gpClearNamedBufferData, (C.GLuint)(buffer), (C.GLenum)(internalformat), (C.GLenum)(format), (C.GLenum)(xtype), data)\n}", "func ClearNamedBufferSubData(buffer uint32, internalformat uint32, offset int, size int, format uint32, xtype uint32, data unsafe.Pointer) {\n\tsyscall.Syscall9(gpClearNamedBufferSubData, 7, uintptr(buffer), uintptr(internalformat), uintptr(offset), uintptr(size), uintptr(format), uintptr(xtype), uintptr(data), 0, 0)\n}", "func (b *Buffer) Destroy() {\n\tfor _, buf := range b.bufs {\n\t\tb.pool.release(buf)\n\t}\n\tb.bufs = nil\n}", "func (ring *ringBuffer) destroy() {\n\t// do nothing in go\n}", "func ClearNamedBufferSubData(buffer uint32, internalformat uint32, offset int, size int, format uint32, xtype uint32, data unsafe.Pointer) {\n\tC.glowClearNamedBufferSubData(gpClearNamedBufferSubData, (C.GLuint)(buffer), (C.GLenum)(internalformat), (C.GLintptr)(offset), (C.GLsizeiptr)(size), (C.GLenum)(format), (C.GLenum)(xtype), data)\n}", "func ClearNamedBufferSubData(buffer uint32, internalformat uint32, offset int, size int, format uint32, xtype uint32, data unsafe.Pointer) {\n\tC.glowClearNamedBufferSubData(gpClearNamedBufferSubData, (C.GLuint)(buffer), (C.GLenum)(internalformat), (C.GLintptr)(offset), (C.GLsizeiptr)(size), (C.GLenum)(format), (C.GLenum)(xtype), data)\n}", "func DeleteBuffers(n int32, buffers *uint32) {\n\tsyscall.Syscall(gpDeleteBuffers, 2, uintptr(n), uintptr(unsafe.Pointer(buffers)), 0)\n}", "func freeBuffer(b []uint16) { pathPool.Put(&b) }", "func destroy() {\n\tif unique.natsconn != nil {\n\t\tunique.natsconn.Close()\n\t}\n\tfor _, dict := range unique.mdb {\n\t\tdict.Close()\n\t}\n\tunique = nil\n}", "func free_object(obj *C.Object) {\n\tif obj == nil {\n\t\treturn\n\t}\n\tdefer C.free(unsafe.Pointer(obj))\n\n\tif obj.key != nil {\n\t\tC.free(unsafe.Pointer(obj.key))\n\t}\n\n\tfreeSystemMetadata(&obj.system)\n\tfreeCustomMetadataData(&obj.custom)\n}", "func (o *WlBuffer) Destroy() error {\n\tmsg, err := wire.NewMessage(o.ID(), 0)\n\tif err != nil {\n\t\treturn err\n\t}\n\n\tif err = o.Base.Conn.Write(msg); err != nil {\n\t\treturn err\n\t}\n\n\treturn nil\n}", "func (z *Writer) freeBuffers() {\n\t// Put the buffer back into the pool, if any.\n\tputBuffer(z.Header.BlockMaxSize, z.data)\n\tz.data = nil\n}", "func DeleteBuffers(n int32, buffers *uint32) {\n C.glowDeleteBuffers(gpDeleteBuffers, (C.GLsizei)(n), (*C.GLuint)(unsafe.Pointer(buffers)))\n}", "func DeleteBuffers(buffers []Buffer) {\n\tgl.DeleteBuffers(gl.Sizei(len(buffers)), (*gl.Uint)(&buffers[0]))\n}", "func DeleteBuffers(n Sizei, buffers []Uint) {\n\tcn, _ := (C.GLsizei)(n), cgoAllocsUnknown\n\tcbuffers, _ := (*C.GLuint)(unsafe.Pointer((*sliceHeader)(unsafe.Pointer(&buffers)).Data)), cgoAllocsUnknown\n\tC.glDeleteBuffers(cn, cbuffers)\n}", "func (renderbuffer Renderbuffer) Delete() {\n\t// TODO: Is it somehow possible to get &uint32(renderbuffer) without assigning it to renderbuffers?\n\trenderbuffers := uint32(renderbuffer)\n\tgl.DeleteRenderbuffers(1, &renderbuffers)\n}", "func freeBuffer(buf *bytes.Buffer) {\n\tbuf.Reset()\n\tbufferPool.Put(buf)\n}", "func UnmapNamedBuffer(buffer uint32) bool {\n\tret, _, _ := syscall.Syscall(gpUnmapNamedBuffer, 1, uintptr(buffer), 0, 0)\n\treturn ret != 0\n}", "func CleanQ(names ...string) {\n\tvar wg sync.WaitGroup\n\tfor _, name := range names {\n\t\twg.Add(1)\n\t\tgo func(name string) {\n\t\t\tdefer wg.Done()\n\t\t\tq, _ := factory.Get(name)\n\t\t\tfor {\n\t\t\t\tmsg, err := q.Get(1e6)\n\t\t\t\tif err != nil {\n\t\t\t\t\tbreak\n\t\t\t\t}\n\t\t\t\tq.Delete(msg)\n\t\t\t}\n\t\t}(name)\n\t}\n\twg.Wait()\n}", "func CleanActionBuffer(){\n\tActionBuffer=nil //throw to garbage collector\n\tInitiateActionBuffer()\n}", "func (u *Msg) NameDelete(rr []RR) {\n\tu.Ns = make([]RR, len(rr))\n\tfor i, r := range rr {\n\t\tu.Ns[i] = &RR_ANY{Hdr: RR_Header{Name: r.Header().Name, Ttl: 0, Rrtype: TypeANY, Class: ClassANY}}\n\t}\n}", "func DeleteBuffer(v Buffer) {\n\tgl.DeleteBuffers(1, &v.Value)\n}", "func netApiBufferFree(buffer *wKSTAInfo102) {\n\tprocNetApiBufferFree.Call(uintptr(unsafe.Pointer(buffer))) //nolint:errcheck\n}", "func (native *OpenGL) DeleteBuffers(buffers []uint32) {\n\tgl.DeleteBuffers(int32(len(buffers)), &buffers[0])\n}", "func NamedBufferStorage(buffer uint32, size int, data unsafe.Pointer, flags uint32) {\n\tsyscall.Syscall6(gpNamedBufferStorage, 4, uintptr(buffer), uintptr(size), uintptr(data), uintptr(flags), 0, 0)\n}", "func (e *ObservableEditableBuffer) Delete(q0, q1 OffsetTuple) {\n\tbefore := e.getTagStatus()\n\tdefer e.notifyTagObservers(before)\n\n\te.f.Delete(q0, q1, e.seq)\n\tif e.seq < 1 {\n\t\te.f.FlattenHistory()\n\t}\n\te.deleted(q0, q1)\n}", "func (bt *Blobies) deregister(guid uuid.UUID) {\n\tdelete(bt.Objects, guid)\n}", "func destroy(ar *allocRunner) {\n\tar.Destroy()\n\t<-ar.DestroyCh()\n}", "func DeleteFramebuffers(n Sizei, framebuffers []Uint) {\n\tcn, _ := (C.GLsizei)(n), cgoAllocsUnknown\n\tcframebuffers, _ := (*C.GLuint)(unsafe.Pointer((*sliceHeader)(unsafe.Pointer(&framebuffers)).Data)), cgoAllocsUnknown\n\tC.glDeleteFramebuffers(cn, cframebuffers)\n}", "func Remove(name string) error", "func UnmapNamedBuffer(buffer uint32) bool {\n\tret := C.glowUnmapNamedBuffer(gpUnmapNamedBuffer, (C.GLuint)(buffer))\n\treturn ret == TRUE\n}", "func UnmapNamedBuffer(buffer uint32) bool {\n\tret := C.glowUnmapNamedBuffer(gpUnmapNamedBuffer, (C.GLuint)(buffer))\n\treturn ret == TRUE\n}", "func textBufferFinalizer(t *TextBuffer) {\n\truntime.SetFinalizer(t, func(t *TextBuffer) { gobject.Unref(t) })\n}", "func doDeleteMesh(componentMeshName string) {\n\tcr := visibleMeshes[componentMeshName]\n\tcr.Renderable.Destroy()\n\tcr.Renderable = nil\n\tdelete(visibleMeshes, componentMeshName)\n}", "func (mp *Mempool) Free(objs interface{}) {\n\tptr, count := cptr.ParseCptrArray(objs)\n\tif count == 0 {\n\t\treturn\n\t}\n\tC.rte_mempool_put_bulk(mp.ptr(), (*unsafe.Pointer)(ptr), C.uint(count))\n}", "func skykeydeletenamecmd(name string) {\n\terr := httpClient.SkykeyDeleteByNamePost(name)\n\tif err != nil {\n\t\tdie(err)\n\t}\n\n\tfmt.Println(\"Skykey Deleted!\")\n}", "func (b *Buffer) Close() error {\n\tb.Unmap()\n\treturn os.Remove(b.filename)\n}", "func (bs *brains) del(b *brain) {\n\tbs.m.Lock()\n\tdefer bs.m.Unlock()\n\tdelete(bs.k, b.key)\n\tdelete(bs.n, b.name)\n}", "func (b *GoGLBackendOffscreen) Delete() {\n\tgl.DeleteTextures(1, &b.offscrBuf.tex)\n\tgl.DeleteFramebuffers(1, &b.offscrBuf.frameBuf)\n\tgl.DeleteRenderbuffers(1, &b.offscrBuf.renderStencilBuf)\n}", "func destroyCTCLoss(obj *CTCLoss) { C.cudnnDestroyCTCLossDescriptor(obj.internal) }", "func destroyObjects(p *pkcs11.Ctx, session pkcs11.SessionHandle, handles []pkcs11.ObjectHandle) error {\n\tfor _, o := range handles {\n\t\terr := p.DestroyObject(session, o)\n\t\tif err != nil {\n\t\t\treturn fmt.Errorf(\"Error destroying object %d: %v\", o, err)\n\t\t}\n\t}\n\treturn nil\n}", "func (debugging *debuggingOpenGL) DeleteFramebuffers(buffers []uint32) {\n\tdebugging.recordEntry(\"DeleteFramebuffers\", buffers)\n\tdebugging.gl.DeleteFramebuffers(buffers)\n\tdebugging.recordExit(\"DeleteFramebuffers\")\n}", "func (p *proxyrunner) destroyBucketData(msg *cmn.ActionMsg, bck *cluster.Bck) error {\n\tquery := cmn.AddBckToQuery(\n\t\turl.Values{cmn.URLParamKeepBckMD: []string{\"true\"}},\n\t\tbck.Bck)\n\targs := allocBcastArgs()\n\targs.req = cmn.ReqArgs{\n\t\tMethod: http.MethodDelete,\n\t\tPath: cmn.URLPathBuckets.Join(bck.Name),\n\t\tBody: cos.MustMarshal(msg),\n\t\tQuery: query,\n\t}\n\targs.to = cluster.Targets\n\tresults := p.bcastGroup(args)\n\tfreeBcastArgs(args)\n\tfor _, res := range results {\n\t\tif res.err != nil {\n\t\t\treturn res.err\n\t\t}\n\t}\n\tfreeCallResults(results)\n\treturn nil\n}", "func (*SharedMemoryControlRequest_UnregisterAll) Descriptor() ([]byte, []int) {\n\treturn file_grpc_service_proto_rawDescGZIP(), []int{6, 2}\n}", "func (i *ImageBuf) Destroy() {\n\truntime.SetFinalizer(i, nil)\n\tdeleteImageBuf(i)\n}", "func (c *CmdBuff) Delete() {\n\tif c.Empty() {\n\t\treturn\n\t}\n\tc.SetText(string(c.buff[:len(c.buff)-1]), \"\")\n\tc.fireBufferChanged(c.GetText(), c.GetSuggestion())\n\tif c.hasCancel() {\n\t\treturn\n\t}\n\n\tctx, cancel := context.WithTimeout(context.Background(), 800*time.Millisecond)\n\tc.setCancel(cancel)\n\n\tgo func() {\n\t\t<-ctx.Done()\n\t\tc.fireBufferCompleted(c.GetText(), c.GetSuggestion())\n\t\tc.resetCancel()\n\t}()\n}", "func (blob *Blob) Free() {\n\tif blob != nil {\n\t\tblob.Owner.Reset()\n\t\tblob.Author.Reset()\n\t\tblob.Time = Time0\n\t\tblob.Name = \"\"\n\t\tblob.wo = 0\n\t\tselect {\n\t\tcase blobs.c <- blob:\n\t\tdefault:\n\t\t}\n\t}\n}", "func (pk PacketBufferPtr) DecRef() {\n\tpk.packetBufferRefs.DecRef(func() {\n\t\tif pk.onRelease != nil {\n\t\t\tpk.onRelease()\n\t\t}\n\n\t\tpk.buf.Release()\n\t\tpkPool.Put(pk)\n\t})\n}", "func closeAndRemove(f *Flamingo, conn *connection) {\n (*conn.conn).Close()\n f.cmdR.Lock()\n delete(f.cmdR.m,conn.cid)\n f.cmdR.Unlock()\n}", "func (f *FileBlob) Free() {\n\tf.blob = nil\n}", "func (w *Watcher) deleteWatch(watch *watch) {\n\tfor name, mask := range watch.names {\n\t\tif mask&provisional == 0 {\n\t\t\tw.sendEvent(filepath.Join(watch.path, name), mask&sysFSIGNORED)\n\t\t}\n\t\tdelete(watch.names, name)\n\t}\n\tif watch.mask != 0 {\n\t\tif watch.mask&provisional == 0 {\n\t\t\tw.sendEvent(watch.path, watch.mask&sysFSIGNORED)\n\t\t}\n\t\twatch.mask = 0\n\t}\n}", "func (debugging *debuggingOpenGL) DeleteBuffers(buffers []uint32) {\n\tdebugging.recordEntry(\"DeleteBuffers\", buffers)\n\tdebugging.gl.DeleteBuffers(buffers)\n\tdebugging.recordExit(\"DeleteBuffers\")\n}", "func (ep *eventsProvider) DeleteByName(name string) error {\n\tindices, _ := ep.findByName(name)\n\tif len(indices) == 0 {\n\t\treturn nil\n\t}\n\n\tfor len(indices) != 0 {\n\t\tep.mutex.Lock()\n\t\tep.Data = append(ep.Data[:indices[0]], ep.Data[indices[0]+1:]...)\n\t\tep.mutex.Unlock()\n\t\tindices, _ = ep.findByName(name)\n\t}\n\n\treturn nil\n}", "func (ans *answer) destroy(c *lockedConn, rl *releaseList) error {\n\tc.assertIs(ans.c)\n\n\trl.Add(ans.msgReleaser.Decr)\n\tdelete(c.lk.answers, ans.id)\n\tif !ans.flags.Contains(releaseResultCapsFlag) || len(ans.exportRefs) == 0 {\n\t\treturn nil\n\n\t}\n\treturn c.releaseExportRefs(rl, ans.exportRefs)\n}", "func deleteSwiftObjects(t *testing.T, osClient *gophercloud.ServiceClient, container string) {\n\t// Get a slice of object names\n\tobjectNames := getSwiftObjectNames(t, osClient, container)\n\n\tfor _, object := range objectNames {\n\t\tresult := objects.Delete(osClient, container, object, nil)\n\t\tif result.Err != nil {\n\t\t\tt.Fatalf(\"Error deleting object %s from container %s: %s\", object, container, result.Err)\n\t\t}\n\t}\n\n}", "func NamedBufferData(buffer uint32, size int, data unsafe.Pointer, usage uint32) {\n\tsyscall.Syscall6(gpNamedBufferData, 4, uintptr(buffer), uintptr(size), uintptr(data), uintptr(usage), 0, 0)\n}", "func (obj *MessengerFileCipher) delete() {\n\tC.vssq_messenger_file_cipher_delete(obj.cCtx)\n}", "func (m *MemBook) deleteAll() {\n\n\t// Reassign the Book data so it's take by the garbage collector.\n\tm.books = make(map[string]*models.Book)\n}", "func (obj *MessengerFileCipher) Delete() {\n\tif obj == nil {\n\t\treturn\n\t}\n\truntime.SetFinalizer(obj, nil)\n\tobj.delete()\n}", "func (c Claims) Del(name string) { delete(c, name) }", "func free(ptr unsafe.Pointer)", "func (x *FzBuffer) Free() {\n\tif x != nil {\n\t\tC.free(unsafe.Pointer(x))\n\t}\n}", "func (buf *Buffer) reset() {\n\tbuf.DNCReports = nil\n\tbuf.DNCReports = make([]DNCReport, 0)\n\tbuf.CNIReports = nil\n\tbuf.CNIReports = make([]CNIReport, 0)\n\tbuf.NPMReports = nil\n\tbuf.NPMReports = make([]NPMReport, 0)\n\tbuf.CNSReports = nil\n\tbuf.CNSReports = make([]CNSReport, 0)\n\tpayloadSize = 0\n}", "func (n *nativeObject) Destroy() {}", "func (enc *Encoder) FreeMemory() {\n\tfor i := 0; i < len(enc.pointerSlice); i++ {\n\t\tC.free(enc.pointerSlice[i])\n\t}\n}", "func (b *Buffer) Reset(buf []byte) {\n\tif b.parent != nil {\n\t\tb.parent.Release()\n\t\tb.parent = nil\n\t}\n\tb.buf = buf\n\tb.length = len(buf)\n}", "func (r *Receiver) Destroy() {\n\tif r.create == nil {\n\t\treturn\n\t}\n\n\tn := C.CString(r.name)\n\tdefer C.free(unsafe.Pointer(n))\n\n\tC.receiver_destroy(n)\n\n\tr.create = nil\n\tr.objects = nil\n}", "func Delete(name string) {\n\tkt.Remove(name)\n}", "func (acker *acker) Free() {\n\tfor k, _ := range acker.fmap {\n\t\tacker.fmap[k] = nil\n\t}\n\tacker.fmap = nil\n\tacker.mutex = nil\n}", "func (n *BufferView) UnfocusBuffers() {\n\t// clear focus from buffers\n\tfor _, buffPane := range n.buffers {\n\t\tbuffPane.SetFocus(false)\n\t}\n}", "func DelElsObj(url string) {\n\tif req, err := http.NewRequest(\"DELETE\", util.ELS_BASE+url, nil); err != nil {\n\t\tlog.Printf(\"Els Create Request Err: %s\\n\", err.Error())\n\t} else if resp, err := http.DefaultClient.Do(req); err != nil {\n\t\tlog.Printf(\"Els Sync Err: %s\\n\", err.Error())\n\t} else if err := resp.Body.Close(); err != nil {\n\t\tlog.Printf(\"Els Close Fp Err: %s\\n\", err.Error())\n\t}\n\n}", "func Free(mem *interface{}) {\n\tC.bson_free(unsafe.Pointer(mem))\n}", "func free(cStrs []*C.char) {\n\tfor _, str := range cStrs {\n\t\tC.free(unsafe.Pointer(str))\n\t}\n}", "func (pce *ppdCacheEntry) free() {\n\tpce.mutex.Lock()\n\tdefer pce.mutex.Unlock()\n\n\tC.free(unsafe.Pointer(pce.printername))\n}", "func Delete(name string) error {\n\tgroupsMutex.Lock()\n\tdefer groupsMutex.Unlock()\n\n\tfor i, g := range Groups {\n\t\tif g.Name == name {\n\t\t\t// Remove JSON\n\t\t\tfilePath := path.Join(Directory, g.Name+\".json\")\n\t\t\tif err := os.Remove(filePath); err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\n\t\t\tGroups = append(Groups[:i], Groups[i+1:]...)\n\t\t\treturn nil\n\t\t}\n\t}\n\treturn errors.New(\"not found\")\n}", "func (c SplitSize) Del(path string) {\n\tfor _, child := range c {\n\t\tchild.Cache.Del(path)\n\t}\n}", "func NamedBufferStorage(buffer uint32, size int, data unsafe.Pointer, flags uint32) {\n\tC.glowNamedBufferStorage(gpNamedBufferStorage, (C.GLuint)(buffer), (C.GLsizeiptr)(size), data, (C.GLbitfield)(flags))\n}", "func NamedBufferStorage(buffer uint32, size int, data unsafe.Pointer, flags uint32) {\n\tC.glowNamedBufferStorage(gpNamedBufferStorage, (C.GLuint)(buffer), (C.GLsizeiptr)(size), data, (C.GLbitfield)(flags))\n}", "func (s *Storage) Free(pooled []byte) {\n\n}", "func DelKeysonBolt(dbFileName string, bucketName string, keys []string) error {\n\tdb, err := bolt.Open(dbFileName, 0666, nil)\n\tdefer db.Close()\n\n\tif err != nil {\n\t\tlog.ErrLog(err)\n\t}\n\n\tif err = db.Update(func(tx *bolt.Tx) error {\n\t\tb := tx.Bucket([]byte(bucketName))\n\t\tfor i := 0; i < len(keys); i++ {\n\t\t\tkey := keys[i]\n\t\t\terr := b.Delete([]byte(key))\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t}); err != nil {\n\t\tlog.ErrLog(err)\n\t}\n\n\treturn err\n}", "func destructor(cmd *cobra.Command, args []string) {\n\tlog.Debug().Msgf(\"Running Destructor.\\n\")\n\tif debug {\n\t\t// Keep intermediary files, when on debug\n\t\tlog.Debug().Msgf(\"Skipping file clearance on Debug Mode.\\n\")\n\t\treturn\n\t}\n\tintermediaryFiles := []string{\"generate_pylist.py\", \"pylist.json\", \"dependencies.txt\", \"golist.json\", \"npmlist.json\"}\n\tfor _, file := range intermediaryFiles {\n\t\tfile = filepath.Join(os.TempDir(), file)\n\t\tif _, err := os.Stat(file); err != nil {\n\t\t\tif os.IsNotExist(err) {\n\t\t\t\t// If file doesn't exists, continue\n\t\t\t\tcontinue\n\t\t\t}\n\t\t}\n\t\te := os.Remove(file)\n\t\tif e != nil {\n\t\t\tlog.Fatal().Msgf(\"Error clearing files %s\", file)\n\t\t}\n\t}\n}", "func DeleteAll(){\nfor fwin!=nil{\nfwin.Del(true)\nfwin.Close()\n}\n}", "func entryBufferFinalizer(e *EntryBuffer) {\n\truntime.SetFinalizer(e, func(e *EntryBuffer) { gobject.Unref(e) })\n}", "func Del(kb KeyBucket) {\n\terr := kb.B.Del(kb.Key.Key)\n\tif err != nil {\n\t\tlog.Warnf(\"%v\\n\", err)\n\t}\n\tatomic.AddUint64(&donecounter, 1)\n}", "func (b *Builder) clearMesh() {\n\tfor _, key := range b.localInstances.Keys() {\n\t\tb.localInstances.Delete(key)\n\t}\n}", "func (wb *WriteBatch) Destroy() {\n\tC.rocksdb_writebatch_destroy(wb.c)\n\twb.c = nil\n}", "func (e *ObservableEditableBuffer) deleted(q0, q1 OffsetTuple) {\n\te.treatasclean = false\n\tfor observer := range e.observers {\n\t\tobserver.Deleted(q0, q1)\n\t}\n}", "func (c *peer) Delete(name string) error {\n\tkey := path.Join(c.prefix, name)\n\treturn c.store.Del(key)\n}", "func (n *nativeShader) free() {\n\t// Delete shader objects (in practice we should be able to do this directly\n\t// after linking, but it would just leave the driver to reference count\n\t// them anyway).\n\tgl.DeleteShader(n.vertex)\n\tgl.DeleteShader(n.fragment)\n\n\t// Delete program.\n\tgl.DeleteProgram(n.program)\n\n\t// Zero-out the nativeShader structure, only keeping the rsrcManager around.\n\t*n = nativeShader{\n\t\tr: n.r,\n\t}\n}", "func (x *PDFXobject) Free() {\n\tif x != nil {\n\t\tC.free(unsafe.Pointer(x))\n\t}\n}", "func (c *Conn) Deallocate(ctx context.Context, name string) error {\n\tdelete(c.preparedStatements, name)\n\t_, err := c.pgConn.Exec(ctx, \"deallocate \"+quoteIdentifier(name)).ReadAll()\n\treturn err\n}", "func delPatricia(ptr patricia, bucket string, cb db.CachedBatch) {\n\tkey := ptr.hash()\n\tlogger.Debug().Hex(\"key\", key[:8]).Msg(\"del\")\n\tcb.Delete(bucket, key[:], \"failed to delete key = %x\", key)\n}", "func (speech *SpeechSync) ClearBuffer() {\n\tspeech.dataInfo.ClearBuffer()\n}", "func (e *ObservableEditableBuffer) DeleteAt(rp0, rp1 int) {\n\tp0 := e.f.RuneTuple(rp0)\n\tp1 := e.f.RuneTuple(rp1)\n\n\te.Delete(p0, p1)\n}", "func (x *PDFDesignatedName) Free() {\n\tif x != nil {\n\t\tC.free(unsafe.Pointer(x))\n\t}\n}", "func (*DeleteStorageObjectsRequest) Descriptor() ([]byte, []int) {\n\treturn file_api_proto_rawDescGZIP(), []int{35}\n}", "func (c *GoGoProtobufCodec) Destroy() error {\n\treturn nil\n}" ]
[ "0.62140304", "0.59822816", "0.59822816", "0.59758705", "0.59605604", "0.58622783", "0.5784818", "0.5784818", "0.5730123", "0.5666472", "0.55977887", "0.5593384", "0.5542014", "0.5525167", "0.55219185", "0.5493203", "0.54699224", "0.54655427", "0.5446036", "0.541549", "0.5399521", "0.53993034", "0.53893304", "0.53705925", "0.5368037", "0.53413343", "0.53391296", "0.53380156", "0.5330842", "0.5319133", "0.5303004", "0.52881855", "0.52478284", "0.52478284", "0.5216921", "0.52042645", "0.51638055", "0.5148447", "0.5142688", "0.5142417", "0.5141223", "0.5134086", "0.51171976", "0.51111037", "0.5103655", "0.5099957", "0.50964034", "0.50849515", "0.5079901", "0.5079337", "0.5075016", "0.5063598", "0.5060048", "0.50584406", "0.50510335", "0.5036385", "0.5035042", "0.50324965", "0.50307465", "0.5028898", "0.5019715", "0.5018789", "0.50084454", "0.5004856", "0.50007445", "0.49917153", "0.49873936", "0.4986178", "0.49805653", "0.49800158", "0.49766314", "0.4974721", "0.49743456", "0.4956487", "0.4954768", "0.49547237", "0.49485123", "0.4945002", "0.49430543", "0.49430543", "0.49366897", "0.49337408", "0.4918315", "0.49180168", "0.49146754", "0.489653", "0.48953143", "0.48770908", "0.48757282", "0.48724508", "0.4869222", "0.48684913", "0.48663476", "0.48615137", "0.4859661", "0.48572296", "0.48566803", "0.48480362", "0.4847425" ]
0.52425784
35
delete a contiguous group of display lists
func DeleteLists(list uint32, xrange int32) { C.glowDeleteLists(gpDeleteLists, (C.GLuint)(list), (C.GLsizei)(xrange)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func DeleteLists(list uint32, xrange int32) {\n C.glowDeleteLists(gpDeleteLists, (C.GLuint)(list), (C.GLsizei)(xrange))\n}", "func DeleteLists(list uint32, xrange int32) {\n\tsyscall.Syscall(gpDeleteLists, 2, uintptr(list), uintptr(xrange), 0)\n}", "func (p *timeWheel) deleteJobList(iw, index uint32) {\n\tswitch iw {\n\tcase 0:\n\t\tif index > 255 || index < 0 {\n\t\t\treturn\n\t\t}\n\tcase 1, 2, 3, 4:\n\t\tif index > 63 || index < 0 {\n\t\t\treturn\n\t\t}\n\tdefault:\n\t\treturn\n\t}\n\tp.Lock()\n\tp.tvs[iw].vector[index] = list.New()\n\tp.Unlock()\n}", "func (b *DrawList) Clean() {\r\n\t*b = (*b)[:0]\r\n}", "func (l *list) delete(i int) {\n n := l.first\n\n j := 0\n for n.next != nil && j < i {\n n = n.next\n j++\n }\n\n if j == 0 && n != nil {\n l.first = n.next\n }\n\n tmp := n.next\n\n if (n.prev != nil) {\n n.prev.next = tmp\n }\n\n if (n.next != nil) {\n n.next.prev = n.prev\n }\n\n}", "func (s *frameSorter) deleteConsecutive(pos protocol.ByteCount) {\n\tfor {\n\t\toldEntry, ok := s.queue[pos]\n\t\tif !ok {\n\t\t\tbreak\n\t\t}\n\t\toldEntryLen := protocol.ByteCount(len(oldEntry.Data))\n\t\tdelete(s.queue, pos)\n\t\tif oldEntry.DoneCb != nil {\n\t\t\toldEntry.DoneCb()\n\t\t}\n\t\tpos += oldEntryLen\n\t}\n}", "func cleaner(listy ...int) {\n\tfor _, x := range listy {\n\t\tfmt.Println(\"Deleting\", x)\n\t\tdelete(myGreeting, x)\n\t}\n}", "func deleteOpenings() {\n setMaze(getInt(&begX) - 1, getInt(&begY), wall)\n setMaze(getInt(&endX) + 1, getInt(&endY), wall)\n}", "func DeleteFromPool(pool []Card, out []Card) []Card {\n\tvar ans []Card\n\tfor i := 0; i < len(pool); i++ {\n\t\tcheck := true\n\t\tfor j := 0; j < len(out); j++ {\n\t\t\tif (pool[i].Num == out[j].Num) && (pool[i].Color == out[j].Color) {\n\t\t\t\tcheck = false\n\t\t\t}\n\t\t}\n\t\tif check {\n\t\t\tans = append(ans, pool[i])\n\t\t}\n\t}\n\treturn ans\n}", "func (sp *Space) Remove(shapes ...Shape) {\n\n\tfor _, shape := range shapes {\n\n\t\tfor deleteIndex, s := range *sp {\n\n\t\t\tif s == shape {\n\t\t\t\ts := *sp\n\t\t\t\ts[deleteIndex] = nil\n\t\t\t\ts = append(s[:deleteIndex], s[deleteIndex+1:]...)\n\t\t\t\t*sp = s\n\t\t\t\tbreak\n\t\t\t}\n\n\t\t}\n\n\t}\n\n}", "func (p *List) RemoveMultiples() {\n\tsort.Sort(p)\n\tvar last token.Position // initial last.Line is != any legal error line\n\ti := 0\n\tfor _, e := range *p {\n\t\tpos := e.Position()\n\t\tif pos.Filename != last.Filename || pos.Line != last.Line {\n\t\t\tlast = pos\n\t\t\t(*p)[i] = e\n\t\t\ti++\n\t\t}\n\t}\n\t(*p) = (*p)[0:i]\n}", "func cleanupGroups(secretsEngine SecretsEngine, groupList map[string]string) {\n\n\t_, existing_groups := getSecretList(secretsEngine.Path + \"group/name\")\n\tfor _, v := range existing_groups {\n\t\tif _, ok := groupList[v]; ok {\n\t\t\tlog.Debug(\"Identity group [\" + v + \"] exists in configuration, no cleanup necessary\")\n\t\t} else {\n\t\t\tlog.Info(\"Identity group [\" + v + \"] does not exist in configuration, prompting to delete\")\n\t\t\tif askForConfirmation(\"Delete identity group [\"+v+\"] [y/n]?: \", 3) {\n\t\t\t\t_, err := Vault.Delete(secretsEngine.Path + \"group/name/\" + v)\n\t\t\t\tif err != nil {\n\t\t\t\t\tlog.Fatal(\"Error deleting identity group [\"+v+\"] \", err)\n\t\t\t\t}\n\t\t\t\tlog.Info(\"Identity group [\" + v + \"] deleted\")\n\t\t\t} else {\n\t\t\t\tlog.Info(\"Leaving identity group [\" + v + \"] even though it is not in config\")\n\t\t\t}\n\t\t}\n\t}\n}", "func (x *LinkListSpanner) Clear() {\n\tx.lastY, x.lastP = 0, 0\n\tx.spans = x.spans[0:0]\n\twidth := x.bounds.Dy()\n\tfor i := 0; i < width; i++ {\n\t\t// The first cells are indexed according to the y values\n\t\t// to create y separate linked lists corresponding to the\n\t\t// image y length. Since index 0 is used by the first of these sentinel cells\n\t\t// 0 can and is used for the end of list value by the spanner linked list.\n\t\tx.spans = append(x.spans, spanCell{})\n\t}\n}", "func delete(array []int8, pos int) []int8 {\r\n\tvar length = len(array)\r\n\tvar tempArray = make([]int8, length+1)\r\n\tfmt.Printf(\"\\n\")\r\n\tfor i := 0; i < length; i++ {\r\n\t\tif i < pos {\r\n\t\t\ttempArray[i] = array[i]\r\n\t\t} else {\r\n\t\t\ttempArray[i-1] = array[i]\r\n\t\t}\r\n\t}\r\n\treturn tempArray\r\n\r\n}", "func ShowListForDeletion(manuals []*model.Manual) *model.Manual {\n\tnum := len(manuals)\n\tif num > 1 {\n\t\tfmt.Println(\"Found \" + strconv.Itoa(num) + \" manuals\")\n\t} else if num == 0 {\n\t\tfmt.Println(ansi.Red + \"No manuals found\" + ansi.Reset)\n\t\treturn nil\n\t}\n\n\tvar manual *model.Manual\n\n\tif num > 1 {\n\t\t_, rows := createList(manuals)\n\t\tprompt := &survey.Select{\n\t\t\tMessage: \"Select the manual to delete\",\n\t\t\tOptions: rows,\n\t\t}\n\t\tvar row string\n\t\tif err := survey.AskOne(prompt, &row, nil); err != nil {\n\t\t\tText(err)\n\t\t\treturn nil\n\t\t}\n\n\t\tfor i, r := range rows {\n\t\t\tif row == r {\n\t\t\t\tmanual = manuals[i]\n\t\t\t\tbreak\n\t\t\t}\n\t\t}\n\t} else { // num === 1\n\t\tmanual = manuals[0]\n\t}\n\n\tif manual == nil {\n\t\treturn nil\n\t}\n\treturn manual\n}", "func (l *list) delete(i int) {\n\n\tif l.begin == nil {\n\t\tpanic(\"list empty\")\n\t}\n\n\t// List over/underflow\n\tif i > l.nodes || i < 0 {\n\t\tpanic(\"not exists\")\n\t}\n\n\t// Removing the last node\n\tif l.nodes == 1 && i == 0 {\n\t\tl.begin = nil\n\t\tl.nodes = 0\n\t\treturn\n\t}\n\n\t// Removing at the end of the list\n\tif i == l.nodes-1 {\n\t\tn := l.begin\n\n\t\tfor j := 0; j < l.nodes-1; j++ {\n\t\t\tn = n.right\n\t\t}\n\n\t\tn.left.right = nil\n\t\tn = nil\n\t\tl.nodes--\n\t\treturn\n\t}\n\n\t// Removing the first node\n\tif i == 0 {\n\t\tn := l.begin.right\n\t\tl.begin = n\n\t\tl.begin.left = nil\n\t\tl.nodes--\n\t\treturn\n\t}\n\n\n\t// Removing in somewhere between\n\tc := l.begin\n\n\tfor j := 0; j < i; j++ {\n\t\tc = c.right\n\t}\n\n\tc.left.right, c.right.left = c.right, c.left\n\tl.nodes--\n}", "func (p *panel) trash() {\n\tif p.slab != nil {\n\t\tp.slab.Dispose()\n\t\tp.slab = nil\n\t}\n\tfor _, cube := range p.cubes {\n\t\tcube.reset(0)\n\t}\n}", "func deleteMarkdown(markdowns []*stashItem, target *stashItem) ([]*stashItem, error) {\n\tindex := -1\n\n\t// Operate on a copy to avoid any pointer weirdness\n\tmds := make([]*stashItem, len(markdowns))\n\tcopy(mds, markdowns)\n\n\tfor i, v := range mds {\n\t\tif v.Identifier() == target.Identifier() {\n\t\t\tindex = i\n\t\t\tbreak\n\t\t}\n\t}\n\n\tif index == -1 {\n\t\terr := fmt.Errorf(\"could not find markdown to delete\")\n\t\tif debug {\n\t\t\tlog.Println(err)\n\t\t}\n\t\treturn nil, err\n\t}\n\n\treturn append(mds[:index], mds[index+1:]...), nil\n}", "func historyDelete(splited []string, length int) {\n if length == 2 {\n connect.DeleteGlobalMessages()\n return\n }\n connect.DeleteLocalMessages(splited[2:])\n}", "func (tr *trooper) demerge() {\n\ttr.trash()\n\ttr.addCenter()\n\tfor _, b := range tr.bits {\n\t\tb.reset(b.box().cmax)\n\t}\n\ttr.detach()\n}", "func (l *CentroidList) Clear() {\n\t*l = (*l)[:0]\n}", "func (g *Grid) Delete(n int) {\n\tg.children = append(g.children[:n], g.children[n + 1:]...)\n\t//C.uiGridDelete(g.g, C.int(n))\n}", "func collapse(units *list.List) {\n\tcurrent := units.Front()\n\tfor current != nil {\n\t\tnext := current.Next()\n\t\tif next == nil {\n\t\t\tbreak\n\t\t}\n\t\tif canCollapse(current, next) {\n\t\t\tnewCurrent := current.Prev()\n\t\t\tif newCurrent == nil {\n\t\t\t\tnewCurrent = next.Next()\n\t\t\t}\n\t\t\tunits.Remove(next)\n\t\t\tunits.Remove(current)\n\t\t\tcurrent = newCurrent\n\t\t} else {\n\t\t\tcurrent = next\n\t\t}\n\t}\n}", "func (s *sliding) deleteFrom(newStart LogPosition) {\n\tstart := s.start\n\tfor i, u := range s.log[:s.mutable-start][:newStart-start] {\n\t\tpos := start + LogPosition(i)\n\t\tblkno := u.Addr\n\t\toldPos, ok := s.addrPos[blkno]\n\t\tif ok && oldPos <= pos {\n\t\t\tutil.DPrintf(5, \"memLogMap: del %d %d\\n\", blkno, oldPos)\n\t\t\tdelete(s.addrPos, blkno)\n\t\t}\n\t}\n\ts.log = s.log[newStart-start:]\n\ts.start = newStart\n}", "func (x *FzDisplayList) Free() {\n\tif x != nil {\n\t\tC.free(unsafe.Pointer(x))\n\t}\n}", "func rmCmdAtIndex(node *parse.PipeNode, cmdAtIndex int) {\n\tif len(node.Cmds) > cmdAtIndex+1 {\n\t\tnode.Cmds = append(node.Cmds[0:cmdAtIndex], node.Cmds[cmdAtIndex+1:]...)\n\t} else {\n\t\tnode.Cmds = node.Cmds[0:cmdAtIndex]\n\t}\n}", "func delExternalClientBlackholeFromNodes(nodes []v1.Node, routingTable, externalV4, externalV6 string, useV4 bool) {\n\tfor _, node := range nodes {\n\t\tif useV4 {\n\t\t\tout, err := runCommand(containerRuntime, \"exec\", node.Name, \"ip\", \"route\", \"del\", \"blackhole\", externalV4, \"table\", routingTable)\n\t\t\tframework.ExpectNoError(err, fmt.Sprintf(\"failed to delete blackhole route to %s on node %s table %s, out: %s\", externalV4, node.Name, routingTable, out))\n\t\t\tcontinue\n\t\t}\n\t\tout, err := runCommand(containerRuntime, \"exec\", node.Name, \"ip\", \"route\", \"del\", \"blackhole\", externalV6, \"table\", routingTable)\n\t\tframework.ExpectNoError(err, fmt.Sprintf(\"failed to delete blackhole route to %s on node %s table %s, out: %s\", externalV6, node.Name, routingTable, out))\n\t}\n}", "func (sub *subState) deleteFromList(sl []*subState) ([]*subState, bool) {\n\tfor i := 0; i < len(sl); i++ {\n\t\tif sl[i] == sub {\n\t\t\tsl[i] = sl[len(sl)-1]\n\t\t\tsl[len(sl)-1] = nil\n\t\t\tsl = sl[:len(sl)-1]\n\t\t\treturn shrinkSubListIfNeeded(sl), true\n\t\t}\n\t}\n\treturn sl, false\n}", "func deleteFloorFromList(stopFloor int, e *Elevator) {\n\ti := indexOf(len(e.floorList), func(i int) bool { return e.floorList[i] == stopFloor })\n\n\tif i > -1 {\n\t\te.floorList = remove(e.floorList, i)\n\t}\n}", "func (l *leaf) del(view *View, pred func(x, y float64, e interface{}) bool, _ *subtree, _ *root) {\n\tfor i := range l.ps {\n\t\tpoint := &l.ps[i]\n\t\tif !point.zeroed() && view.contains(point.x, point.y) {\n\t\t\tdel(point, pred)\n\t\t\tif len(point.elems) == 0 {\n\t\t\t\tpoint.zeroOut()\n\t\t\t}\n\t\t}\n\t}\n\trestoreOrder(&l.ps)\n\treturn\n}", "func removeForeignLayers(descs []ocispec.Descriptor) []ocispec.Descriptor {\n\tvar j int\n\tfor i, desc := range descs {\n\t\tif !descriptor.IsForeignLayer(desc) {\n\t\t\tif i != j {\n\t\t\t\tdescs[j] = desc\n\t\t\t}\n\t\t\tj++\n\t\t}\n\t}\n\treturn descs[:j]\n}", "func removeFromSlice(rrs []dns.RR, i int) []dns.RR {\n\tif i >= len(rrs) {\n\t\treturn rrs\n\t}\n\trrs = append(rrs[:i], rrs[i+1:]...)\n\treturn rrs\n}", "func msaCleaner(msa *multi.Multi) {\n\tfor i := 0; i < msa.Rows(); i++ {\n\t\tid := msa.Row(i).Name()\n\t\tif id == \"consensus\" {\n\t\t\tmsa.Delete(i)\n\t\t}\n\t}\n}", "func (r *Rack) Remove(tiles ...Tile) {\n\tfor _, t := range tiles {\n\t\tfor i, rt := range *r {\n\t\t\tif rt == t {\n\t\t\t\t*r = append((*r)[0:i], (*r)[i+1:]...)\n\t\t\t\tbreak\n\t\t\t}\n\t\t}\n\t}\n}", "func (r *ReconciliationTask) deleteVisibilities(visibilities map[string]*platform.ServiceVisibilityEntity) error {\n\tstate := r.newVisibilityProcessingState()\n\tdefer state.StopProcessing()\n\n\tfor _, visibility := range visibilities {\n\t\texecAsync(state, visibility, r.deleteVisibility)\n\t}\n\treturn await(state)\n}", "func removeStones(stones [][]int) int {\n\t// - 2 stones are connected if they share same row or columns\n\t// - In a connected path, we can remove all but one stone\n\t// - The problem reduces to counting connected paths\n\n\trows := make(map[int]*int)\n\tcols := make(map[int]*int)\n\tpointers := make(map[int][]*int)\n\tfor _, stone := range stones {\n\t\tr := stone[0]\n\t\trp, rok := rows[r]\n\t\tc := stone[1]\n\t\tcp, cok := cols[c]\n\t\tif !rok && !cok {\n\t\t\t// new stone isn't belong to any path,\n\t\t\t// create a new path ID for it\n\t\t\tp := max(len(rows), len(cols)) + 1\n\t\t\trows[r] = &p\n\t\t\tcols[c] = &p\n\t\t\tpointers[p] = append(pointers[p], &p)\n\t\t\tcontinue\n\t\t}\n\n\t\tif !rok {\n\t\t\t// new stone belong to known path identified via its column\n\t\t\trows[r] = cp\n\t\t\tcontinue\n\t\t}\n\n\t\tif !cok {\n\t\t\tcols[c] = rp\n\t\t\tcontinue\n\t\t}\n\n\t\t// merge rp and cp, need to replace whole cp with rp, not just value\n\t\t// *cp = *rp // this won't work\n\t\tif *cp == *rp {\n\t\t\tcontinue\n\t\t}\n\n\t\ttoBeDeletedID := *cp\n\t\tfor _, p := range pointers[toBeDeletedID] {\n\t\t\t*p = *rp\n\t\t\tpointers[*rp] = append(pointers[*rp], p)\n\t\t}\n\t\tdelete(pointers, toBeDeletedID)\n\t}\n\n\tuniq := make(map[int]bool)\n\tfor _, p := range rows {\n\t\tuniq[*p] = true\n\t}\n\tfor _, p := range cols {\n\t\tuniq[*p] = true\n\t}\n\n\treturn len(stones) - len(uniq)\n}", "func (l *RandomAccessGroupLookup) Clear() {\n\tl.elements = nil\n\tl.index = make(map[string]*groupLookupElement)\n}", "func (e *Editor) Delete(runes int) {\n\tif runes == 0 {\n\t\treturn\n\t}\n\n\tif l := e.caret.end.ofs - e.caret.start.ofs; l != 0 {\n\t\te.caret.start.ofs = e.editBuffer.deleteRunes(e.caret.start.ofs, l)\n\t\trunes -= sign(runes)\n\t}\n\n\te.caret.start.ofs = e.editBuffer.deleteRunes(e.caret.start.ofs, runes)\n\te.caret.start.xoff = 0\n\te.ClearSelection()\n\te.invalidate()\n}", "func DeletePktCreators(kinds ...PktKind) {\n\tif len(kinds) == 0 {\n\t\tpktCreators = make(map[PktKind]PktCreator)\n\t\treturn\n\t}\n\tfor _, kind := range kinds {\n\t\tdelete(pktCreators, kind)\n\t}\n}", "func clean(g *Game) {\n\tfor i := range g.gameBoard {\n\t\tg.gameBoard[i] = 0\n\t}\n}", "func (g *Grid) Clear() { g.rows = []ui.GridBufferer{} }", "func delMembers(device string, members []string) error {\n\tif len(members) == 0 {\n\t\treturn nil\n\t}\n\n\targs := []string{device}\n\tfor _, member := range members {\n\t\targs = append(args, \"deletem\", member)\n\t}\n\tcmd := exec.Command(\"ifconfig\", args...)\n\tfmt.Printf(\"cmd: %s\\n\", strings.Join(cmd.Args, \" \"))\n\treturn cmd.Run()\n}", "func (il *IntList) Clear() {\n il.first.next = il.last\n il.last.prev = il.first\n il.length = 0\n}", "func BenchmarkSliceDel(b *testing.B) {\n\tfor i := 0; i < b.N; i++ {\n\t\tsliceDel([]string{\"a\", \"b\", \"c\"}, \"c\")\n\t}\n}", "func (l *list) delete(i int) {\n\tif i < 0 || i >= l.size {\n\t\tpanic(\"list index out of bounds\")\n\t}\n\n\tvar n *node\n\tmid := l.size/2\n\tif mid >= i {\n\t\tn = l.root\n\t\tfor ; i!=0; i-- {\n\t\t\tn = n.next\n\t\t}\n\t} else {\n\t\tn = l.tail\n\t\tfor i=l.size-i-1; i!=0; i-- {\n\t\t\tn = n.prev\n\t\t}\n\t}\n\tif n.prev != nil {\n\t\tn.prev.next = n.next\n\t} else {\n\t\tl.root = n.next\n\t}\n\tif n.next != nil {\n\t\tn.next.prev = n.prev\n\t} else {\n\t\tl.tail = n.prev\n\t}\n\tl.size--\t\n}", "func createDisplaysList(e *Elevator) {\n\tdisplay := newDisplay(1, displayOn, 1)\n\te.floorDisplaysList = append(e.floorDisplaysList, *display)\n\tfor i := e.column.minFloor; i <= e.column.maxFloor; i++ {\n\t\tdisplay = newDisplay(i, displayOn, i)\n\t\te.floorDisplaysList = append(e.floorDisplaysList, *display)\n\t}\n}", "func (g *Grid) Destroy() {\n\tfor len(g.children) != 0 {\n\t\tc := g.children[0]\n\t\tg.Delete(0)\n\t\tc.Destroy()\n\t}\n\tC.uiControlDestroy(g.c)\n}", "func (f *Formatter) printAsGroups(list []proto.Visitee) {\n\tgroup := []columnsPrintable{}\n\tlastGroupName := \"\"\n\tfor _, each := range list {\n\t\tgroupName := nameOfVisitee(each)\n\t\tprintable, isColumnsPrintable := typeAssertColumnsPrintable(each)\n\t\tif isColumnsPrintable {\n\t\t\tif lastGroupName != groupName {\n\t\t\t\tlastGroupName = groupName\n\t\t\t\t// print current group\n\t\t\t\tif len(group) > 0 {\n\t\t\t\t\tf.printListOfColumns(group)\n\t\t\t\t\t// begin new group\n\t\t\t\t\tgroup = []columnsPrintable{}\n\t\t\t\t}\n\t\t\t}\n\t\t\t// comment as a group entity\n\t\t\tif hasDoc, ok := each.(proto.Documented); ok {\n\t\t\t\tif doc := hasDoc.Doc(); doc != nil {\n\t\t\t\t\tf.printListOfColumns(group)\n\t\t\t\t\t// begin new group\n\t\t\t\t\tgroup = []columnsPrintable{}\n\t\t\t\t\tif len(doc.Lines) > 0 { // if comment then add newline before it\n\t\t\t\t\t\tgroup = append(group, inlineComment{line: \"\", extraSlash: false})\n\t\t\t\t\t}\n\t\t\t\t\tgroup = append(group, columnsPrintables(doc)...)\n\t\t\t\t}\n\t\t\t}\n\t\t\tgroup = append(group, printable)\n\t\t} else {\n\t\t\t// not printable in group\n\t\t\tlastGroupName = groupName\n\t\t\t// print current group\n\t\t\tif len(group) > 0 {\n\t\t\t\tf.printListOfColumns(group)\n\t\t\t\t// begin new group\n\t\t\t\tgroup = []columnsPrintable{}\n\t\t\t}\n\t\t\teach.Accept(f)\n\t\t}\n\t}\n\t// print last group\n\tf.printListOfColumns(group)\n}", "func (b *Buffer) ClearAt(o int) {\n\tif o < len(b.Tiles) {\n\t\tb.Tiles[o] = nil\n\t}\n}", "func (v view) Clear() {\n\tfor i := 0; i < len(v.screen); i++ {\n\t\tv.screen[i].Clear()\n\t}\n}", "func Compact(deltas []*Delta) (results []*Delta) {\n\tfor i := 0; i < len(deltas); {\n\t\tfirst := deltas[i]\n\t\tj := i + 1\n\t\tfor j < len(deltas) {\n\t\t\tnext := deltas[j]\n\t\t\tif first.Offset != next.Offset && first.Offset+first.Delete != next.Offset {\n\t\t\t\tbreak\n\t\t\t}\n\t\t\tfirst.Delete += next.Delete\n\t\t\tfirst.Insert = append(first.Insert, next.Insert...)\n\t\t\tj++\n\t\t}\n\t\ti = j\n\t\tresults = append(results, first)\n\t}\n\treturn\n}", "func (c *Context) EraseDrawableList() {\n\tc.primitivesToDraw = make(map[uint32][]Drawable)\n}", "func DeleteQueries(n int32, ids *uint32) {\n\tsyscall.Syscall(gpDeleteQueries, 2, uintptr(n), uintptr(unsafe.Pointer(ids)), 0)\n}", "func remove(list []*IPRange, index int) []*IPRange {\n\tfor i := index + 1; i < len(list); i++ {\n\t\tlist[i-1] = list[i]\n\t}\n\treturn list[:len(list)-1]\n}", "func (g *Group) DeleteAll() {\n\tg.Equivalents = list.New()\n\tg.Fingerprints = make(map[string]*list.Element)\n\tg.FirstExpr = make(map[Operand]*list.Element)\n\tg.SelfFingerprint = \"\"\n}", "func (p *panel) removeCell() {\n\tfor _, c := range p.cubes {\n\t\tif c.detach() {\n\t\t\treturn\n\t\t}\n\t}\n\tlogf(\"pc:panel removeCell should never reach here.\")\n}", "func DeleteAll(){\nfor fwin!=nil{\nfwin.Del(true)\nfwin.Close()\n}\n}", "func (p *List) Reset() { *p = (*p)[0:0] }", "func (p *NoOpNodeGroupListProcessor) CleanUp() {\n}", "func (c *ActiveSeries) clear() {\n\tfor s := 0; s < numActiveSeriesStripes; s++ {\n\t\tc.stripes[s].clear()\n\t}\n}", "func (tree *Tree23) deleteRec(t TreeNodeIndex, elem TreeElement) *[]TreeNodeIndex {\n\tallLeaves := true\n\n\tleafCount := 0\n\tfoundLeaf := false\n\tfor i := 0; i < tree.treeNodes[t].cCount; i++ {\n\t\tc := tree.treeNodes[t].children[i]\n\t\tisLeaf := tree.IsLeaf(c.child)\n\t\tallLeaves = allLeaves && isLeaf\n\t\tif isLeaf && (foundLeaf || !elem.Equal(tree.treeNodes[c.child].elem)) {\n\t\t\tleafCount++\n\t\t} else {\n\t\t\t// We only want to delete one node, that is equal to elem!\n\t\t\t// In case we successfully inserted multiple equal elements into our tree, we don't want to\n\t\t\t// remove all of them (tree can only handle -1 element at a time).\n\t\t\tfoundLeaf = true\n\t\t}\n\t}\n\tif allLeaves {\n\t\tvar newChildren *[]TreeNodeIndex\n\n\t\t// We cache the memory for this list!\n\t\tswitch leafCount {\n\t\tcase 1:\n\t\t\tnewChildren = &tree.oneElemTreeList\n\t\tcase 2:\n\t\t\tnewChildren = &tree.twoElemTreeList\n\t\tcase 3:\n\t\t\tnewChildren = &tree.threeElemTreeList\n\t\t}\n\n\t\tindex := 0\n\t\tfoundLeaf = false\n\t\tfor i := 0; i < tree.treeNodes[t].cCount; i++ {\n\t\t\tc := tree.treeNodes[t].children[i]\n\t\t\t// Remove the child that contains our element!\n\t\t\tif foundLeaf || !elem.Equal(tree.treeNodes[c.child].elem) {\n\t\t\t\t(*newChildren)[index] = c.child\n\t\t\t\tindex++\n\t\t\t} else {\n\t\t\t\tfoundLeaf = true\n\t\t\t\ttree.treeNodes[tree.treeNodes[c.child].prev].next = tree.treeNodes[c.child].next\n\t\t\t\ttree.treeNodes[tree.treeNodes[c.child].next].prev = tree.treeNodes[c.child].prev\n\n\t\t\t\ttree.recycleNode(c.child)\n\n\t\t\t}\n\t\t}\n\n\t\treturn newChildren\n\t}\n\n\tdeleteFrom := tree.deleteFrom(t, elem.ExtractValue())\n\t// In case we don't find an element to delete, we just return our own children.\n\t// Let's get things sorted out some other recursion level.\n\t// No node recycling possible here.\n\tif deleteFrom == -1 {\n\n\t\t//defer tree.recycleNode(t)\n\n\t\tswitch leafCount {\n\t\tcase 2:\n\t\t\ttree.twoElemTreeList[0] = tree.treeNodes[t].children[0].child\n\t\t\ttree.twoElemTreeList[1] = tree.treeNodes[t].children[1].child\n\t\t\treturn &tree.twoElemTreeList\n\t\tcase 3:\n\t\t\ttree.threeElemTreeList[0] = tree.treeNodes[t].children[0].child\n\t\t\ttree.threeElemTreeList[1] = tree.treeNodes[t].children[1].child\n\t\t\ttree.threeElemTreeList[2] = tree.treeNodes[t].children[2].child\n\t\t\treturn &tree.threeElemTreeList\n\t\t}\n\t}\n\n\t// The new children from the subtree that does not contain elem any more!\n\tchildren := tree.deleteRec(tree.treeNodes[t].children[deleteFrom].child, elem)\n\n\t// Count the number of old grandChildren before allocating\n\toGCCount := 0\n\tfor i := 0; i < tree.treeNodes[t].cCount; i++ {\n\t\tif i != deleteFrom {\n\t\t\toGCCount += tree.treeNodes[tree.treeNodes[t].children[i].child].cCount\n\t\t}\n\t}\n\n\t// Includes all grandchildren and the new nodes from the recursion!\n\tindex := 0\n\n\tfor i := 0; i < tree.treeNodes[t].cCount; i++ {\n\t\tc := tree.treeNodes[t].children[i]\n\t\tif i != deleteFrom {\n\n\t\t\tfor j := 0; j < tree.treeNodes[c.child].cCount; j++ {\n\t\t\t\tc2 := tree.treeNodes[c.child].children[j]\n\t\t\t\ttree.nineElemTreeList[index] = c2.child\n\t\t\t\tindex++\n\t\t\t}\n\t\t\t//tree.recycleNode(c.child)\n\t\t} else {\n\t\t\t// Here we insert the children from the recursion. They are now in sorted order with the rest!\n\t\t\tfor _, c2 := range *children {\n\t\t\t\ttree.nineElemTreeList[index] = c2\n\t\t\t\tindex++\n\t\t\t}\n\n\t\t}\n\t\t//fmt.Println(\"soon to be recycled:\", c.child)\n\t\ttree.recycleNode(c.child)\n\t}\n\n\t//tree.recycleNode(tree.treeNodes[t].children[deleteFrom].child)\n\n\t//defer tree.recycleNode(t)\n\n\treturn tree.multipleNodesFromChildrenList(&tree.nineElemTreeList, oGCCount+len(*children))\n}", "func (c *RpcClusterClient) clear(addrs []string) {\n\tc.Lock()\n\tvar rm []*poolWeightClient\n\tfor _, cli := range c.clients {\n\t\tvar has_cli bool\n\t\tfor _, addr := range addrs {\n\t\t\tif cli.endpoint == addr {\n\t\t\t\thas_cli = true\n\t\t\t\tbreak\n\t\t\t}\n\t\t}\n\t\tif !has_cli {\n\t\t\trm = append(rm, cli)\n\t\t} else if cli.errcnt > 0 {\n\t\t\t/*\n\t\t\t\tif cli.weight >= errWeight*uint64(cli.errcnt) {\n\t\t\t\t\tcli.weight -= errWeight * uint64(cli.errcnt)\n\t\t\t\t\tcli.errcnt = 0\n\t\t\t\t\tif c.Len() >= minHeapSize {\n\t\t\t\t\t\t// cli will and only up, so it's ok here.\n\t\t\t\t\t\theap.Fix(c, cli.index)\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t*/\n\t\t}\n\t}\n\n\tfor _, cli := range rm {\n\t\t// p will up, down, or not move, so append it to rm list.\n\t\tc.Debugf(\"remove cli: %s\", cli.endpoint)\n\n\t\theap.Remove(c, cli.index)\n\t\tcli.pool.Close()\n\t}\n\tc.Unlock()\n}", "func DeleteSamplers(count int32, samplers *uint32) {\n\tsyscall.Syscall(gpDeleteSamplers, 2, uintptr(count), uintptr(unsafe.Pointer(samplers)), 0)\n}", "func (o RecordMeasureSlice) DeleteAllP(exec boil.Executor) {\n\tif err := o.DeleteAll(exec); err != nil {\n\t\tpanic(boil.WrapErr(err))\n\t}\n}", "func removeNodeFromList(id string) {\n\ti := 0\n\tfor i < len(nodes) {\n\t\tcurrentNode := nodes[i]\n\t\tif currentNode.Id == id {\n\t\t\tnodes = append(nodes[:i], nodes[i+1:]...)\n\t\t} else {\n\t\t\ti++\n\t\t}\n\t}\n}", "func (u *UdList) Del(key string) {\n\tidx := len(u.Data)\n\tfor i, p := range u.Data {\n\t\tif p.Name == key {\n\t\t\tidx = i\n\t\t\tbreak\n\t\t}\n\t}\n\tu.Data[idx] = u.Data[len(u.Data)-1]\n\tu.Data = u.Data[:len(u.Data)-1]\n}", "func DeleteAllLMLocal(list List) {\r\n\tvar listMembers []ListMember\r\n\r\n\tdb.Where(\"ListID = ?\", list.UUID).Find(&listMembers)\r\n\r\n\tfor i, listMember := range listMembers {\r\n\t\tfmt.Print(\"Deleting: \", i, list.Title)\r\n\t\tdb.Delete(listMember)\r\n\t}\r\n\t// db.Delete(list)\r\n}", "func (b *Buffer) ClearTo(o int) {\n\tfor o = calc.MinInt(o, len(b.Tiles)); o >= 0; o-- {\n\t\tb.Tiles[o] = nil\n\t}\n}", "func qgroupDestroy(index string) {\n\tout, err := exec.Command(\"btrfs\", \"qgroup\", \"destroy\", index, config.Agent.LxcPrefix).CombinedOutput()\n\tlog.Check(log.DebugLevel, \"Destroying qgroup \"+index+\": \"+string(out), err)\n\tlog.Check(log.DebugLevel, \"Destroying qgroup of parent\", exec.Command(\"btrfs\", \"qgroup\", \"destroy\", \"1/\"+index, config.Agent.LxcPrefix).Run())\n}", "func (pm partitionMap) cleanup() {\n\tfor ns, partitions := range pm {\n\t\tfor i := range partitions.Replicas {\n\t\t\tfor j := range partitions.Replicas[i] {\n\t\t\t\tpartitions.Replicas[i][j] = nil\n\t\t\t}\n\t\t\tpartitions.Replicas[i] = nil\n\t\t}\n\n\t\tpartitions.Replicas = nil\n\t\tpartitions.regimes = nil\n\n\t\tdelete(pm, ns)\n\t}\n}", "func DeleteQueries(n int32, ids *uint32) {\n C.glowDeleteQueries(gpDeleteQueries, (C.GLsizei)(n), (*C.GLuint)(unsafe.Pointer(ids)))\n}", "func (l *GroupLookup) Clear() {\n\tl.lastIndex = -1\n\tl.nextID = 1\n\tl.groups = nil\n}", "func (p *packPlan) clear() {\n\tfor i := 0; i < len(p); i++ {\n\t\tp[i] = emptyCell\n\t}\n}", "func (o *ClusterUninstaller) destroyFloatingIPs() error {\n\tfound, err := o.listFloatingIPs()\n\tif err != nil {\n\t\treturn err\n\t}\n\n\titems := o.insertPendingItems(floatingIPTypeName, found.list())\n\n\tfor _, item := range items {\n\t\tif _, ok := found[item.key]; !ok {\n\t\t\t// This item has finished deletion.\n\t\t\to.deletePendingItems(item.typeName, []cloudResource{item})\n\t\t\to.Logger.Infof(\"Deleted floating IP %q\", item.name)\n\t\t\tcontinue\n\t\t}\n\t\terr = o.deleteFloatingIP(item)\n\t\tif err != nil {\n\t\t\to.errorTracker.suppressWarning(item.key, err, o.Logger)\n\t\t}\n\t}\n\n\tif items = o.getPendingItems(floatingIPTypeName); len(items) > 0 {\n\t\treturn errors.Errorf(\"%d items pending\", len(items))\n\t}\n\treturn nil\n}", "func placeHolderSlices() {\n\tvar s []string\n\tfmt.Println(s)\n\n\ts = []string{\"Coffee\", \"Espresso\", \"Cappuccino\"}\n\tfmt.Println(s)\n\n\ts[1] = \"Chai Tea\"\n\tfmt.Println(s)\n\n\ts2 := s\n\ts2[2] = \"Chai Latte\"\n\tfmt.Println(s, s2)\n\n\ts2 = append(s2, \"Hot Choco\", \"Hot Tea\")\n\tfmt.Println(s, s2)\n\n\ts3 := []int{1, 2, 3, 4, 5, 6, 7}\n\tslices.Delete(s3, 1, 2)\n\tfmt.Println(s3)\n}", "func (b *Buffer) ClearFrom(o int) {\n\tfor l := len(b.Tiles); o < l; o++ {\n\t\tb.Tiles[o] = nil\n\t}\n}", "func removeElFromlist(p PointStruct, listp *[]PointStruct) {\n\n\tcopyInput := *listp\n\tfor idx, val := range copyInput{\n\n\t\tif val == p{\n\t\t\ttemp1:= copyInput[:idx]\n\t\t\ttemp2:= copyInput[idx:]\n\t\t\tif len(temp2) == 1{\n\t\t\t\t*listp = temp1\n\t\t\t\treturn\n\t\t\t}else{\n\t\t\t\ttemp2 = temp2[1:]\n\t\t\t\t*listp = append(temp1, temp2...)\n\t\t\t\treturn\n\t\t\t}\n\t\t}\n\t}\n}", "func DeallocateIP(reservelist []IPReservation, containerID string) ([]IPReservation, net.IP, error) {\n\n}", "func (elems *ElementsNR) delete(pt dvid.Point3d) (deleted *ElementNR, changed bool) {\n\t// Delete any elements at point.\n\tvar cut = -1\n\tfor i, elem := range *elems {\n\t\tif pt.Equals(elem.Pos) {\n\t\t\tcut = i\n\t\t\tbreak\n\t\t}\n\t}\n\tif cut >= 0 {\n\t\tdeleted = (*elems)[cut].Copy()\n\t\tchanged = true\n\t\t(*elems)[cut] = (*elems)[len(*elems)-1] // Delete without preserving order.\n\t\t*elems = (*elems)[:len(*elems)-1]\n\t}\n\treturn\n}", "func (sl *Shortlist) Drop(c *contact.Contact) {\n\tfor i := 0; i < len(sl.Entries); i++ {\n\t\tif sl.Entries[i] != nil {\n\t\t\tif sl.Entries[i].Contact.ID.Equals(c.ID) {\n\t\t\t\tsl.Entries[i] = nil\n\t\t\t}\n\t\t}\n\t}\n}", "func (t *tableCommon) deleteBatchKeys(ctx context.Context, lvs []*tspb.ListValue, delOpts *deleteOptions) error {\n\tfor _, lv := range lvs {\n\t\tpkeys, err := t.getPrimaryKeyData(ctx, lv)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tif delOpts.RowDelete {\n\t\t\tfor _, cf := range delOpts.cfmap {\n\t\t\t\tif err := t.removeRecordWithIndex(ctx, pkeys, cf); err != nil {\n\t\t\t\t\treturn err\n\t\t\t\t}\n\t\t\t}\n\t\t\treturn nil\n\t\t}\n\t\tif err := t.removeFlexibleSparseColumn(ctx, pkeys, delOpts); err != nil {\n\t\t\treturn err\n\t\t}\n\t}\n\treturn nil\n}", "func SliceDeleteAtIndex(sl *[]Ki, idx int) error {\n\tif err := SliceIsValidIndex(sl, idx); err != nil {\n\t\treturn err\n\t}\n\t// this copy makes sure there are no memory leaks\n\tsz := len(*sl)\n\tcopy((*sl)[idx:], (*sl)[idx+1:])\n\t(*sl)[sz-1] = nil\n\t(*sl) = (*sl)[:sz-1]\n\treturn nil\n}", "func (ls *linestate) editDelete() {\n\tif len(ls.buf) > 0 && ls.pos < len(ls.buf) {\n\t\tls.buf = append(ls.buf[:ls.pos], ls.buf[ls.pos+1:]...)\n\t\tls.refreshLine()\n\t}\n}", "func (m *Memory) CleanChunksByNeed(offset int64) {\n\tfor key := range m.db.Items() {\n\t\tsepIdx := strings.LastIndex(key, \"-\")\n\t\tkeyOffset, err := strconv.ParseInt(key[sepIdx+1:], 10, 64)\n\t\tif err != nil {\n\t\t\tfs.Errorf(\"cache\", \"couldn't parse offset entry %v\", key)\n\t\t\tcontinue\n\t\t}\n\n\t\tif keyOffset < offset {\n\t\t\tm.db.Delete(key)\n\t\t}\n\t}\n}", "func DeleteSlice(source []*Instance, index int) []*Instance {\n\tif len(source) == 1 {\n\t\treturn make([]*Instance, 0)\n\t}\n\tif index == 0 {\n\t\treturn source[1:]\n\t}\n\tif index == len(source)-1 {\n\t\treturn source[:len(source)-2]\n\t}\n\treturn append(source[0:index-1], source[index+1:]...)\n}", "func (diffStore *utxoDiffStore) clearOldEntries() {\n\tdiffStore.mtx.HighPriorityWriteLock()\n\tdefer diffStore.mtx.HighPriorityWriteUnlock()\n\n\tvirtualBlueScore := diffStore.dag.VirtualBlueScore()\n\tminBlueScore := virtualBlueScore - maxBlueScoreDifferenceToKeepLoaded\n\tif maxBlueScoreDifferenceToKeepLoaded > virtualBlueScore {\n\t\tminBlueScore = 0\n\t}\n\n\ttips := diffStore.dag.virtual.tips()\n\n\ttoRemove := make(map[*blockNode]struct{})\n\tfor node := range diffStore.loaded {\n\t\tif node.blueScore < minBlueScore && !tips.contains(node) {\n\t\t\ttoRemove[node] = struct{}{}\n\t\t}\n\t}\n\tfor node := range toRemove {\n\t\tdelete(diffStore.loaded, node)\n\t}\n}", "func Fremove(lista *[]string, elema string) {\n\tlistx := *lista\n\tlisty := []string{}\n\tfor _, i := range listx {\n\t\tif elema != i {\n\t\t\tlisty = append(listy, i)\n\t\t}\n\t}\n\t*lista = listy\n}", "func removeZeroEntries(oldest, newest topicOffsets) {\n\tfor topic, partitions := range oldest {\n\t\tfor partition, offset := range partitions {\n\t\t\tif nTopic, ok := newest[topic]; ok {\n\t\t\t\tif nOffset, ok := nTopic[partition]; ok && offset == nOffset {\n\t\t\t\t\tdelete(partitions, partition)\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n}", "func remove(nodes []*DSSNode, node *DSSNode) ([]*DSSNode, bool) {\n\tfor i, n := range nodes {\n\t\tif n == node {\n\t\t\tnodes[i] = nodes[len(nodes)-1]\n\t\t\tnodes[len(nodes)-1] = nil\n\t\t\tnodes = nodes[:len(nodes)-1]\n\t\t\treturn nodes, true\n\t\t}\n\t}\n\treturn nodes, false\n}", "func (r *runestring) Del(pos ...int) {\n\tfor _, i := range pos {\n\t\tif i >= 0 && i <= len(*r) {\n\t\t\t*r = append((*r)[:i], (*r)[i+1:]...)\n\t\t}\n\t}\n}", "func (self *Graphics) RemoveChildren(beginIndex int, endIndex int) {\n self.Object.Call(\"removeChildren\", beginIndex, endIndex)\n}", "func (dump *Dump) purge(existed Int32Map, stats *ParseStatistics) {\n\tfor id, cont := range dump.ContentIndex {\n\t\tif _, ok := existed[id]; !ok {\n\t\t\tfor _, ip4 := range cont.IPv4 {\n\t\t\t\tdump.RemoveFromIPv4Index(ip4.IPv4, cont.ID)\n\t\t\t}\n\n\t\t\tfor _, ip6 := range cont.IPv6 {\n\t\t\t\tip6 := string(ip6.IPv6)\n\t\t\t\tdump.RemoveFromIPv6Index(ip6, cont.ID)\n\t\t\t}\n\n\t\t\tfor _, subnet6 := range cont.SubnetIPv6 {\n\t\t\t\tdump.RemoveFromSubnetIPv6Index(subnet6.SubnetIPv6, cont.ID)\n\t\t\t}\n\n\t\t\tfor _, subnet4 := range cont.SubnetIPv4 {\n\t\t\t\tdump.RemoveFromSubnetIPv4Index(subnet4.SubnetIPv4, cont.ID)\n\t\t\t}\n\n\t\t\tfor _, u := range cont.URL {\n\t\t\t\tdump.RemoveFromURLIndex(NormalizeURL(u.URL), cont.ID)\n\t\t\t}\n\n\t\t\tfor _, domain := range cont.Domain {\n\t\t\t\tdump.RemoveFromDomainIndex(NormalizeDomain(domain.Domain), cont.ID)\n\t\t\t}\n\n\t\t\tdump.RemoveFromDecisionIndex(cont.Decision, cont.ID)\n\t\t\tdump.RemoveFromDecisionOrgIndex(cont.DecisionOrg, cont.ID)\n\t\t\tdump.RemoveFromDecisionWithoutNoIndex(cont.ID)\n\t\t\tdump.RemoveFromEntryTypeIndex(entryTypeKey(cont.EntryType, cont.DecisionOrg), cont.ID)\n\n\t\t\tdelete(dump.ContentIndex, id)\n\n\t\t\tstats.RemoveCount++\n\t\t}\n\t}\n}", "func (pv *PixView) CleanDupes(dryRun bool) {\n\tpv.UpdtMu.Lock()\n\tdefer pv.UpdtMu.Unlock()\n\n\t// adir := filepath.Join(pv.ImageDir, \"All\")\n\tpv.UpdateFolders()\n\n\tsmap := make(map[int64]picinfo.Pics, len(pv.AllInfo))\n\n\tsmax := int64(0)\n\tfor _, pi := range pv.AllInfo {\n\t\tfi, err := os.Stat(pi.Thumb)\n\t\tif err != nil {\n\t\t\tcontinue\n\t\t}\n\t\tsz := fi.Size()\n\t\tif sz > smax {\n\t\t\tsmax = sz\n\t\t}\n\t\tpis, has := smap[sz]\n\t\tif has {\n\t\t\tpis = append(pis, pi)\n\t\t\tsmap[sz] = pis\n\t\t} else {\n\t\t\tsmap[sz] = picinfo.Pics{pi}\n\t\t}\n\t}\n\n\tmx := len(smap)\n\tpv.PProg.Start(mx)\n\n\tszs := make([]int64, mx)\n\tidx := 0\n\tfor sz := range smap {\n\t\tszs[idx] = sz\n\t\tidx++\n\t}\n\n\tncp := runtime.NumCPU()\n\tnper := mx / ncp\n\tst := 0\n\tfor i := 0; i < ncp; i++ {\n\t\ted := st + nper\n\t\tif i == ncp-1 {\n\t\t\ted = mx\n\t\t}\n\t\tgo pv.CleanDupesThr(dryRun, smax, szs, smap, st, ed)\n\t\tpv.WaitGp.Add(1)\n\t\tst = ed\n\t}\n\tpv.WaitGp.Wait()\n\tpv.SaveAllInfo()\n\tfmt.Println(\"...Done\\n\")\n\tgi.PromptDialog(nil, gi.DlgOpts{Title: \"Done\", Prompt: \"Done Cleaning Duplicates\"}, gi.AddOk, gi.NoCancel, nil, nil)\n\tpv.DirInfo(false)\n}", "func (pfmu *ParticipantFlowModuleUpdate) ClearFlowGroupList() *ParticipantFlowModuleUpdate {\n\tpfmu.mutation.ClearFlowGroupList()\n\treturn pfmu\n}", "func tabRemove(ls *LuaState) int {\n\tsize := _auxGetN(ls, 1, TAB_RW)\n\tpos := luaOptInteger(ls, 2, size)\n\tif pos != size { /* validate 'pos' if given */\n\t\tls.ArgCheck(1 <= pos && pos <= size+1, 1, \"position out of bounds\")\n\t}\n\tluaGetI(ls, 1, pos) /* result = t[pos] */\n\tfor ; pos < size; pos++ {\n\t\tluaGetI(ls, 1, pos+1)\n\t\tluaSetI(ls, 1, pos) /* t[pos] = t[pos + 1] */\n\t}\n\tls.Push(LuaNil)\n\tluaSetI(ls, 1, pos) /* t[pos] = nil */\n\treturn 1\n}", "func (l List) ClearStats() {\n\tfor i := 0; i < len(l); i++ {\n\t\tl[i].WorkingBurst = l[i].Burst\n\t\tl[i].Start = -1\n\t\tl[i].Finished = -1\n\t}\n}", "func (l *List) DeleteList(name string) {\n\n\tl.size--\n\t/* single item in list */\n \tif l.head == l.tail {\n \t\tl.head = nil\n \t \tl.tail = nil\n \t\treturn\n \t} \n\n \t/* Find the entry to delete */\n\tcurrentNode := l.head\n\tvar prev *Node = nil\n\tfor currentNode != nil && \n\t\tstrings.Compare(strings.ToUpper(name), strings.ToUpper(currentNode.emp.name)) != 0 {\n\t\tprev = currentNode\n\t\tcurrentNode = currentNode.next\n\t}\n\n\t/* If entry not found */\n\tif currentNode == nil {\n\t\tfmt.Println(\"Node not found for name: %s\", name)\n\t\tl.size++\n\t\treturn\n\t}\n\n\t/*If the last entry to be removed */\n\tif (currentNode == l.tail) {\n\t\tprev.next = nil;\n\t\tl.tail = prev\n\t}\n\n\t/* if the first entry to be removed */\n\tif (currentNode == l.head) {\n\t\tl.head = currentNode.next\n\t\tcurrentNode.next = nil\n\t} else { /* middle entry to be removed */\n\t\tprev.next = currentNode.next\n\t}\n}", "func (o BlackCardSlice) DeleteAllP(exec boil.Executor) {\n\tif err := o.DeleteAll(exec); err != nil {\n\t\tpanic(boil.WrapErr(err))\n\t}\n}", "func deleteAllStr(path string, targets []os.FileInfo, testMode bool) error {\n\tpath += string(os.PathSeparator)\n\tdays := viper.GetInt(\"duration\")\n\tsmthToDel := false\n\tif days > 1 {\n\t\t// color.HiMagenta(\"List of item to be removed:\\n\\n\")\n\t\tfmt.Println(magB(\"\\n:: List of items to be removed in:\"), path)\n\t\t// color.HiMagenta(\"Size\\tUnit\\t\\t Item\")\n\t\tfmt.Println(magB(\"Size\\tUnit\\t\\t Item\"))\n\t\tif len(targets) == 0 {\n\t\t\tsmthToDel = true\n\t\t}\n\t\tfor _, target := range targets {\n\t\t\t// Check if time is right\n\t\t\ttimeDiff := time.Now().Sub(target.ModTime()).Hours()\n\t\t\tif timeDiff >= float64(days*24) {\n\t\t\t\tsize, unit := FormatSize(float64(target.Size()))\n\n\t\t\t\t// if target.ModTime() <\n\t\t\t\tswitch {\n\t\t\t\tcase testMode:\n\t\t\t\t\t// It is in test mode\n\t\t\t\t\tfmt.Println(color.HiCyanString(fmt.Sprintf(\"%v\\t%s\", size, unit)), \"\\t\\t\", path+target.Name())\n\t\t\t\t\tsmthToDel = true\n\t\t\t\tdefault:\n\t\t\t\t\t// Then it is an actual deletion\n\t\t\t\t\t/* color.HiMagenta(\"List of item removed:\\n\")\n\t\t\t\t\tcolor.HiMagenta(\"Size\\t\\tItem\") */\n\t\t\t\t\tfmt.Println(color.HiCyanString(fmt.Sprintf(\"%v\\t%s\", size, unit)), \"\\t\\t\", path+target.Name())\n\t\t\t\t\terrRemove := os.RemoveAll(path + target.Name())\n\t\t\t\t\tif errRemove != nil {\n\t\t\t\t\t\treturn errRemove\n\t\t\t\t\t}\n\t\t\t\t\tsmthToDel = true\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\t// Comment on action\n\t\tif !smthToDel {\n\t\t\tfmt.Println(\"0\\tKB\\t\\t Forever Alone ? Nothing to remove here !\")\n\t\t}\n\t\tif testMode {\n\t\t\tfmt.Println(greenB(\"::\"), color.HiGreenString(\"Nothing got removed, it is just a recap of what would get deleted <_<\"))\n\t\t\tfmt.Println(greenB(\"::\"), color.HiGreenString(\"CHAMPAGNE !\"))\n\t\t} else {\n\t\t\tfmt.Println(greenB(\"\\n::\"), color.HiGreenString(\"All done for\"), path)\n\t\t\tfmt.Println(greenB(\"::\"), color.HiGreenString(\"CHAMPAGNE !\\n\"))\n\t\t}\n\t} else {\n\t\tfmt.Println(redB(\"::\"), color.HiRedString(\"Cannot delete files younger than 1 day!\"))\n\t\treturn errors.New(\"\")\n\t}\n\n\treturn nil\n}", "func (list *List) DeleteFromEnd() {\n // 1. Provide message to user if the list is empty and return\n if list.Size() == 0 {\n fmt.Println(\"Nothing to delete, the list is empty\")\n return\n }\n\n // 2. Get the head of the list as current iterator\n current := list.Head()\n\n // 3. Traverse the list until the second last element is reached\n for current.next.next != nil {\n current = current.next\n }\n\n // 4. Update next pointer of second last element such that last element is removed\n current.next = nil\n\n // 5. Decrement the list size\n list.size--\n\n}" ]
[ "0.6157806", "0.5867002", "0.53787464", "0.5322389", "0.5237469", "0.5180698", "0.5179926", "0.5158192", "0.51373094", "0.5069466", "0.5067466", "0.5052006", "0.5037724", "0.5034699", "0.49983966", "0.4967779", "0.49644583", "0.49512142", "0.49454904", "0.49441293", "0.49302274", "0.4909347", "0.48945206", "0.4889506", "0.48767835", "0.48663276", "0.48516765", "0.48478964", "0.48423573", "0.48383653", "0.48366815", "0.48224214", "0.48090792", "0.48041213", "0.47986925", "0.4797373", "0.47967616", "0.47905478", "0.47866875", "0.47826695", "0.4772905", "0.47726944", "0.47722086", "0.4772027", "0.4760031", "0.47529182", "0.474463", "0.47409484", "0.47191742", "0.47161385", "0.4707443", "0.47060186", "0.46916163", "0.46898112", "0.46897036", "0.46686077", "0.46532136", "0.46448645", "0.46433476", "0.4642258", "0.46408665", "0.4638889", "0.4638745", "0.46276996", "0.4619057", "0.46096522", "0.46067104", "0.46057054", "0.4600982", "0.46006683", "0.4595172", "0.45934704", "0.45876017", "0.45866594", "0.45858896", "0.45844337", "0.4582427", "0.4580378", "0.45774212", "0.45755354", "0.4574847", "0.4567141", "0.45618895", "0.45542747", "0.4553075", "0.45487255", "0.45460162", "0.4534357", "0.4527817", "0.4527002", "0.45251918", "0.45251656", "0.45237562", "0.45228755", "0.45199966", "0.45194456", "0.45188066", "0.4517312", "0.4515882", "0.45135173" ]
0.5826923
2
Deletes a program object
func DeleteProgram(program uint32) { C.glowDeleteProgram(gpDeleteProgram, (C.GLuint)(program)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func DeleteProgram(p Program) {\n\tgl.DeleteProgram(p.Value)\n}", "func (program Program) Delete() {\n\tgl.DeleteProgram(uint32(program))\n}", "func DeleteProgram(program uint32) {\n\tsyscall.Syscall(gpDeleteProgram, 1, uintptr(program), 0, 0)\n}", "func DeleteProgram(program uint32) {\n C.glowDeleteProgram(gpDeleteProgram, (C.GLuint)(program))\n}", "func DeleteProgram(program Uint) {\n\tcprogram, _ := (C.GLuint)(program), cgoAllocsUnknown\n\tC.glDeleteProgram(cprogram)\n}", "func (debugging *debuggingOpenGL) DeleteProgram(program uint32) {\n\tdebugging.recordEntry(\"DeleteProgram\", program)\n\tdebugging.gl.DeleteProgram(program)\n\tdebugging.recordExit(\"DeleteProgram\")\n}", "func (native *OpenGL) DeleteProgram(program uint32) {\n\tgl.DeleteProgram(program)\n}", "func (bh *Header) RemoveProgram(p *Program) error {\n\tif p.id < 0 || int(p.id) >= len(bh.progs) || bh.progs[p.id] != p {\n\t\treturn errInvalidProgram\n\t}\n\tbh.progs = append(bh.progs[:p.id], bh.progs[p.id+1:]...)\n\tfor i := range bh.progs[p.id:] {\n\t\tbh.progs[i+int(p.id)].id--\n\t}\n\tp.id = -1\n\tdelete(bh.seenProgs, p.uid)\n\treturn nil\n}", "func (r *ProgramControlRequest) Delete(ctx context.Context) error {\n\treturn r.JSONRequest(ctx, \"DELETE\", \"\", nil, nil)\n}", "func (hp *hdfsProvider) DeleteObj(lom *cluster.LOM) (errCode int, err error) {\n\tfilePath := filepath.Join(lom.Bck().Props.Extra.HDFS.RefDirectory, lom.ObjName)\n\tif err := hp.c.Remove(filePath); err != nil {\n\t\terrCode, err = hdfsErrorToAISError(err)\n\t\treturn errCode, err\n\t}\n\tif verbose {\n\t\tnlog.Infof(\"[delete_object] %s\", lom)\n\t}\n\treturn 0, nil\n}", "func DeleteProgramPipelines(n int32, pipelines *uint32) {\n\tsyscall.Syscall(gpDeleteProgramPipelines, 2, uintptr(n), uintptr(unsafe.Pointer(pipelines)), 0)\n}", "func (es ES) DeleteTool(documentID string) error {\n\tif documentID == \"\" {\n\t\treturn errors.New(\"cannot delete empty documentID\")\n\t}\n\n\ttool, err := es.QueryToolByID(documentID)\n\tif err != nil {\n\t\treturn err\n\t}\n\n\ttoolInAnswers, err := es.QueryAnswersByTool(tool.Name)\n\tif err != nil {\n\t\treturn err\n\t}\n\n\tif len(toolInAnswers) > 0 {\n\t\treturn errors.New(\"cannot delete tool : already in use\")\n\t}\n\n\t_, err = es.Client.Delete().\n\t\tIndex(\"tools\").\n\t\tType(\"_doc\").\n\t\tId(documentID).\n\t\tRefresh(\"true\").\n\t\tDo(es.Context)\n\n\tif err != nil {\n\t\treturn err\n\t}\n\n\treturn nil\n}", "func (p *ExperimentalPlayground) deleteObject(object engine.Object) error {\n\tp.objectsContainersMux.Lock()\n\tdefer p.objectsContainersMux.Unlock()\n\treturn p.unsafeDeleteObject(object)\n}", "func mainDelete(ctx *cli.Context) error {\n\tcheckDeleteSyntax(ctx)\n\tsrc := newGenSource(ctx)\n\n\tb := bench.Delete{\n\t\tCommon: bench.Common{\n\t\t\tClient: newClient(ctx),\n\t\t\tConcurrency: ctx.Int(\"concurrent\"),\n\t\t\tSource: src,\n\t\t\tBucket: ctx.String(\"bucket\"),\n\t\t\tLocation: \"\",\n\t\t\tPutOpts: minio.PutObjectOptions{\n\t\t\t\tServerSideEncryption: newSSE(ctx),\n\t\t\t},\n\t\t},\n\t\tCreateObjects: ctx.Int(\"objects\"),\n\t\tBatchSize: ctx.Int(\"batch\"),\n\t}\n\treturn runBench(ctx, &b)\n}", "func (db *Tool) Delete(id int) error {\n\ttools, err := db.fetchTools()\n\tif err != nil {\n\t\treturn err\n\t}\n\tfor i, v := range tools {\n\t\tif id == v.ID {\n\t\t\ttools = append(tools[:i], tools[i+1:]...)\n\t\t}\n\t}\n\n\tif err = Save(toolData, tools); err != nil {\n\t\treturn errors.New(\"problem making updates, please try again\")\n\t}\n\n\t// if tool has an associated rental, delete rental\n\tr := Rental{}\n\tif err = r.cascade(id, 0); err != nil {\n\t\treturn errors.New(\"rental not found\")\n\t}\n\n\treturn nil\n}", "func (u *App) Delete(c echo.Context, id string) error {\n\tif err := u.rbac.EnforceRole(c, model.AdminRole); err != nil {\n\t\treturn err\n\t}\n\n\tvar applications int\n\tif err := u.db.Model(&model.Application{}).Where(\"application_course_id = ?\", id).Count(&applications).Error; err == nil && applications > 0 {\n\t\treturn zaplog.ZLog(fmt.Errorf(\"Existem %d candidaturas associadas a este curso. Não é possível eliminar\", applications))\n\t}\n\n\treturn u.udb.Delete(u.db, id)\n}", "func (p *ProgramData) Destroy() (err error) {\n\tlogging.Debugf(\"Destroying server %s\", p.Id())\n\terr = p.Environment.Delete()\n\treturn\n}", "func runDel(cmd *Command, args []string) {\n\tdeleteReservation(true, args)\n}", "func runDel(cmd *Command, args []string) {\n\tdeleteReservation(true, args)\n}", "func (s Store) DeleteApplication(title string) error {\n\ts.lock.Lock()\n\tdefer s.lock.Unlock()\n\n\tif !s.isTitlePresent(title) {\n\t\treturn messages.MetadataTitleAbsent\n\t}\n\n\tdelete(s.appToDetails, title)\n\treturn nil\n}", "func DeleteProgramPipelines(n int32, pipelines *uint32) {\n\tC.glowDeleteProgramPipelines(gpDeleteProgramPipelines, (C.GLsizei)(n), (*C.GLuint)(unsafe.Pointer(pipelines)))\n}", "func DeleteProgramPipelines(n int32, pipelines *uint32) {\n\tC.glowDeleteProgramPipelines(gpDeleteProgramPipelines, (C.GLsizei)(n), (*C.GLuint)(unsafe.Pointer(pipelines)))\n}", "func (p *ProgramData) Destroy() (err error) {\n\tlogging.Debugf(\"Destroying server %s\", p.Id())\n\tprocess := operations.GenerateProcess(p.UninstallData.Operations, p.Environment, p.DataToMap(), p.RunData.EnvironmentVariables)\n\terr = process.Run(p.Environment)\n\tif err != nil {\n\t\tp.Environment.DisplayToConsole(\"Error running uninstall, check daemon logs\\n\")\n\t\treturn\n\t}\n\terr = p.Environment.Delete()\n\treturn\n}", "func unlinkedprog(as int) *obj.Prog {\n\tp := Ctxt.NewProg()\n\tClearp(p)\n\tp.As = int16(as)\n\treturn p\n}", "func (kyc *KYCChaincode) deletePerson(stub shim.ChaincodeStubInterface, args []string) ([]byte, error) {\n\tfmt.Println(\"CHAINCODE: Running deletePerson\")\n\n\tif len(args) != 1 {\n\t\treturn nil, errors.New(\"Incorrect number of arguments. Expecting 3\")\n\t}\n\n\t// Delete the key from the state in ledger\n\terr := stub.DelState(args[0])\n\tif err != nil {\n\t\treturn nil, errors.New(\"Failed to delete state\")\n\t}\n\n\treturn nil, nil\n}", "func (o *CMFPaidprogramComment) Delete(ctx context.Context, exec boil.ContextExecutor) (int64, error) {\n\tif o == nil {\n\t\treturn 0, errors.New(\"models: no CMFPaidprogramComment provided for delete\")\n\t}\n\n\tif err := o.doBeforeDeleteHooks(ctx, exec); err != nil {\n\t\treturn 0, err\n\t}\n\n\targs := queries.ValuesFromMapping(reflect.Indirect(reflect.ValueOf(o)), cmfPaidprogramCommentPrimaryKeyMapping)\n\tsql := \"DELETE FROM `cmf_paidprogram_comment` WHERE `id`=?\"\n\n\tif boil.IsDebug(ctx) {\n\t\twriter := boil.DebugWriterFrom(ctx)\n\t\tfmt.Fprintln(writer, sql)\n\t\tfmt.Fprintln(writer, args...)\n\t}\n\tresult, err := exec.ExecContext(ctx, sql, args...)\n\tif err != nil {\n\t\treturn 0, errors.Wrap(err, \"models: unable to delete from cmf_paidprogram_comment\")\n\t}\n\n\trowsAff, err := result.RowsAffected()\n\tif err != nil {\n\t\treturn 0, errors.Wrap(err, \"models: failed to get rows affected by delete for cmf_paidprogram_comment\")\n\t}\n\n\tif err := o.doAfterDeleteHooks(ctx, exec); err != nil {\n\t\treturn 0, err\n\t}\n\n\treturn rowsAff, nil\n}", "func (controller AppsController) Delete(c *gin.Context) {\n\t_, err := mongodb.DeleteByID(controller.MongoDBClient, Collections[\"apps\"], c.Params.ByName(\"id\"))\n\n\tif err != nil {\n\t\tfmt.Printf(\"error %v\", err)\n\t\tc.JSON(http.StatusBadRequest, gin.H{\"message\": \"Unable to remove object\"})\n\t\treturn\n\t}\n\n\t// Remove all versions related\n\t/*_, err := mongodb.DeleteAll(controller.MongoDBClient, Collections[\"versions\"], bson.M{\"app_id\": c.Params.ByName(\"id\")})\n\tif err != nil {\n\t\tfmt.Printf(\"error %v\", err)\n\t\tc.JSON(http.StatusBadRequest, gin.H{\"message\": \"Unable to remove object\"})\n\t\treturn\n\t}*/\n\n\tc.Status(http.StatusOK)\n}", "func (call CommandHandler) DeleteObject(objID uint16, objType uint8) error {\n\t// https://developers.yubico.com/YubiHSM2/Commands/Delete_Object.html\n\treturn call.nullResponse(CmdDeleteObject.Build(objID, objType))\n}", "func deleteClonedProject(path string) {\n\tos.RemoveAll(path)\n}", "func (c *ToolClient) DeleteOne(t *Tool) *ToolDeleteOne {\n\treturn c.DeleteOneID(t.ID)\n}", "func deleteProject(projectID int) {\n\tprepo := sqlite.NewProjectRepo()\n\n\tif err := prepo.Delete(projectID); err != nil {\n\t\tfmt.Printf(\"Error %v \\n\", err)\n\t\treturn\n\t}\n\tfmt.Println(\"Proyecto borrado correctamente\")\n}", "func DeleteObject(ctx context.Context, rootId string) (rep string, err error) {\n\t// 1. gui lenh RemoveItself toi chinh no, khi do, cac child cua no se phai tu unsubscribe\n\trep, err = sendRemoveItselfCommand(ctx, rootId)\n\tif err != nil {\n\t\tLoggingClient.Error(err.Error())\n\t}\n\t// 2. xoa Object nay trong Procols cua cac Parent. Chi can xoa trong MetaData, khong can gui lenh\n\tfor parentId := range cacheGetParents(rootId) {\n\t\tparentObject, err := clientMetaDevice.Device(parentId, ctx)\n\t\tif err == nil {\n\t\t\tdeleteElementInProtocols(parentObject.Protocols, rootId)\n\t\t\terr = clientMetaDevice.Update(parentObject, ctx)\n\t\t\tif err != nil {\n\t\t\t\tLoggingClient.Error(err.Error())\n\t\t\t}\n\t\t}\n\t}\n\t// 3. xoa cac SubObject trong MetaData & xoa rootObject\n\t// doi voi DeviceType, Sub trung voi Root nen bo qua phan xoa SubObject\n\tif cacheGetType(rootId) != DEVICETYPE {\n\t\tlistOb, _ := clientMetaDevice.DevicesByLabel(rootId, ctx)\n\t\tfor _, sub := range listOb {\n\t\t\tfmt.Println(\"delete subObject \", sub.Id)\n\t\t\tclientMetaDevice.Delete(sub.Id, ctx)\n\t\t\tcacheDeleteMapHasName(sub.Name)\n\t\t}\n\t}\n\t// xoa RootObject\n\terr = clientMetaDevice.Delete(rootId, ctx)\n\t// 4. xoa Object trong MapRoot & xoa trong MapID\n\tcacheDeleteRoot(rootId)\n\treturn\n}", "func deleteAppHelm(root, profile, unit, application string) error {\n\tparser := yaml.NewParser()\n\terr := parser.Parse(profile)\n\tif err != nil {\n\t\tlog.Fatalf(\"parser.Parse profile error: err=%s\", err)\n\t}\n\texec := exec.NewExec(root)\n\tfor _, su := range parser.Profile.ServiceUnits {\n\t\tif !strings.EqualFold(su.Name, unit) {\n\t\t\tcontinue\n\t\t}\n\t\tfor _, app := range su.Applications {\n\t\t\tif !strings.EqualFold(app.Name, application) {\n\t\t\t\tcontinue\n\t\t\t}\n\t\t\tshell := exec.Delete(app.Name)\n\t\t\tlog.Infof(\"Delete application: su=%s, app=%s, shell=%s\", su.Name, application, shell)\n\t\t\terr := exec.Do(shell)\n\t\t\tif err != nil {\n\t\t\t\tlog.Errorf(\"Helm delete error: err=%s\", err)\n\t\t\t\treturn err\n\t\t\t}\n\t\t}\n\t}\n\treturn nil\n}", "func (coll *Collection) DetachProgram(name string) *Program {\n\tp := coll.Programs[name]\n\tdelete(coll.Programs, name)\n\treturn p\n}", "func DeleteApplication(db gorp.SqlExecutor, applicationID int64) error {\n\t// Delete variables\n\tif err := DeleteAllVariables(db, applicationID); err != nil {\n\t\treturn err\n\t}\n\n\t// Delete application_key\n\tif err := DeleteAllApplicationKeys(db, applicationID); err != nil {\n\t\treturn err\n\t}\n\n\tquery := `DELETE FROM application WHERE id=$1`\n\tif _, err := db.Exec(query, applicationID); err != nil {\n\t\tif e, ok := err.(*pq.Error); ok {\n\t\t\tswitch e.Code {\n\t\t\tcase gorpmapper.ViolateForeignKeyPGCode:\n\t\t\t\terr = sdk.NewErrorWithStack(err, sdk.ErrApplicationUsedByWorkflow)\n\t\t\t}\n\t\t}\n\t\treturn sdk.WrapError(err, \"cannot delete application\")\n\t}\n\n\treturn nil\n}", "func (a *Application) DeleteObject(obj *LocalDeviceObject) error {\n\tlog.Debug().Stringer(\"obj\", obj).Msg(\"DeleteObject\")\n\n\t// extract the object name and identifier\n\tobjectName := obj.ObjectName\n\tobjectIdentifier := obj.ObjectIdentifier\n\n\t// delete it from the application\n\tdelete(a.objectName, objectName)\n\tdelete(a.objectIdentifier, objectIdentifier)\n\n\t// remove the object's identifier from the device's object list if there is one and has an object list property\n\tif a.localDevice != nil {\n\t\tfoundIndex := -1\n\t\tfor i, s := range a.localDevice.ObjectList {\n\t\t\tif s == objectIdentifier {\n\t\t\t\tfoundIndex = i\n\t\t\t}\n\t\t}\n\t\tif foundIndex >= 0 {\n\t\t\ta.localDevice.ObjectList = append(a.localDevice.ObjectList[0:foundIndex], a.localDevice.ObjectList[foundIndex+1:]...)\n\t\t}\n\t}\n\n\t// make sure the object knows it's detached from an application\n\tobj.App = nil\n\n\treturn nil\n}", "func (o *Organism) Delete(exec boil.Executor) error {\n\tif o == nil {\n\t\treturn errors.New(\"chado: no Organism provided for delete\")\n\t}\n\n\tif err := o.doBeforeDeleteHooks(exec); err != nil {\n\t\treturn err\n\t}\n\n\targs := queries.ValuesFromMapping(reflect.Indirect(reflect.ValueOf(o)), organismPrimaryKeyMapping)\n\tsql := \"DELETE FROM \\\"organism\\\" WHERE \\\"organism_id\\\"=$1\"\n\n\tif boil.DebugMode {\n\t\tfmt.Fprintln(boil.DebugWriter, sql)\n\t\tfmt.Fprintln(boil.DebugWriter, args...)\n\t}\n\n\t_, err := exec.Exec(sql, args...)\n\tif err != nil {\n\t\treturn errors.Wrap(err, \"chado: unable to delete from organism\")\n\t}\n\n\tif err := o.doAfterDeleteHooks(exec); err != nil {\n\t\treturn err\n\t}\n\n\treturn nil\n}", "func DeleteShader(shader uint32) {\n\tsyscall.Syscall(gpDeleteShader, 1, uintptr(shader), 0, 0)\n}", "func (am *ArtifactMap) DeleteApp(AppGUID string) {\n\tvar desiredApp *ArtifactEntry\n\tindex := 0\n\tfor i, app := range am.AppList {\n\t\tif app.GUID == AppGUID {\n\t\t\tdesiredApp = app\n\t\t\tindex = i\n\t\t\tbreak\n\t\t}\n\t}\n\tif desiredApp != nil {\n\t\tam.AppList = append(am.AppList[:index], am.AppList[index+1:]...)\n\t\tam.appTitleToID.Delete(desiredApp.Title)\n\t\tam.appTitleToItemID.Delete(desiredApp.Title)\n\t}\n}", "func (c *ClubapplicationClient) DeleteOne(cl *Clubapplication) *ClubapplicationDeleteOne {\n\treturn c.DeleteOneID(cl.ID)\n}", "func (l *Level) DelObject(gameObject object.GameObject) {\n\tl.mainLayer.deletedIDs[gameObject] = struct{}{}\n}", "func DeleteBinary(p gaia.Pipeline) error {\n\tbinaryFile := filepath.Join(gaia.Cfg.PipelinePath, appendTypeToName(p.Name, p.Type))\n\treturn os.Remove(binaryFile)\n}", "func DeleteApp(c echo.Context) error {\n\tid := c.Param(\"id\")\n\tsqlStatment := \"DELETE FROM apps WHERE id = $1\"\n\tres, err := d.Query(sqlStatment, id)\n\tif err != nil{\n\t\tfmt.Println(err)\n\t} else {\n\t\tfmt.Println(res)\n\t\treturn c.JSON(http.StatusOK, \"Deleted\")\n\t}\n\treturn c.JSON(http.StatusOK, \"Deleted\")\n}", "func (c *SyscallService) DeleteObject(ctx context.Context, in *pb.DeleteRequest) (*pb.DeleteResponse, error) {\n\tnctx, ok := c.ctxmgr.Context(in.GetHeader().Ctxid)\n\tif !ok {\n\t\treturn nil, fmt.Errorf(\"bad ctx id:%d\", in.Header.Ctxid)\n\t}\n\n\terr := nctx.Cache.Del(nctx.ContractName, in.Key)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\treturn &pb.DeleteResponse{}, nil\n}", "func (u *App) Delete(c echo.Context, id string) error {\n\tfile, err := u.udb.View(u.db, id)\n\tif err != nil {\n\t\treturn err\n\t}\n\n\tif err := u.rbac.EnforceUser(c, file.UserID); err != nil {\n\t\treturn err\n\t}\n\n\tif file.Type == model.ResourceApplication {\n\t\tif err = u.rbac.EnforceRole(c, model.OperatorRole); err != nil {\n\t\t\treturn err\n\t\t}\n\t}\n\n\tgo model.DeleteFiles(&[]model.File{*file})\n\treturn u.udb.Delete(u.db, id)\n}", "func DeletePerson(db *sql.DB) {}", "func (store *managerStore) DeleteApplication(runAs, appID string) error {\n\n\tpath := getApplicationRootPath() + runAs + \"/\" + appID\n\tblog.V(3).Infof(\"will delete applcation,path(%s)\", path)\n\n\tif err := store.Db.Delete(path); err != nil {\n\t\tblog.Error(\"fail to delete application, application id(%s), err:%s\", appID, err.Error())\n\t\treturn err\n\t}\n\tdeleteAppCacheNode(runAs, appID)\n\n\treturn nil\n}", "func deletePerson(w http.ResponseWriter, r *http.Request) {\r\n\tw.Header().Set(\"Content-Type\", \"application/json\")\r\n\r\n\tparams := mux.Vars(r)\r\n\tuuid, err := primitive.ObjectIDFromHex(params[\"uuid\"])\r\n\tif err != nil {\r\n\t\tlog.Fatal(err)\r\n\t}\r\n\r\n\tcollection := models.ConnectDB()\r\n\tobjectToDelete, err := collection.DeleteOne(context.TODO(), bson.M{\"_id\": uuid})\r\n\tif err != nil {\r\n\t\tlog.Fatal(err)\r\n\t}\r\n\tjson.NewEncoder(w).Encode(objectToDelete.DeletedCount)\r\n\r\n}", "func (u *App) Delete(c echo.Context, id string) error {\n\tif err := u.rbac.EnforceRole(c, model.AdminRole); err != nil {\n\t\treturn err\n\t}\n\n\tpost, err := u.udb.View(u.db, id)\n\tif err = zaplog.ZLog(err); err != nil {\n\t\treturn err\n\t}\n\n\tif post.Status != model.StatusDraft {\n\t\treturn zaplog.ZLog(errors.New(\"Apenas é possível eliminar artigos em rascunho\"))\n\t}\n\n\treturn u.udb.Delete(u.db, id)\n}", "func (r *DeviceManagementScriptRunSummaryRequest) Delete(ctx context.Context) error {\n\treturn r.JSONRequest(ctx, \"DELETE\", \"\", nil, nil)\n}", "func (r Reserve) Delete() {\n\tos.Remove(r.path)\n}", "func TestDeleteApp(t *testing.T) {\n\n\tvar err error\n\n\t// Use the configuration manager to get Algolia's keys to mock the app interactor\n\tconfigInteractor := interfaces.ConfigurationManager{}\n\tconfigInteractor.ConfigurationInteractor = infrastructure.NewViperConfig()\n\n\t// Instanciate the App interactor\n\tappInteractor := usecases.NewAppInteractor(\n\t\tinterfaces.NewAlgoliaRepository(\n\t\t\tconfigInteractor.GetConfigString(\"algolia.applicationID\", \"NOT_SET\"),\n\t\t\tconfigInteractor.GetConfigString(\"algolia.apiKey\", \"NOT_SET\"),\n\t\t\tconfigInteractor.GetConfigString(\"algolia.indexes.apps\", \"NOT_SET\"),\n\t\t),\n\t)\n\n\t// Single addition\n\t// Create a random app\n\ttestApp := domain.NewApp(\n\t\t\"Unit testing app interactor\",\n\t\t\"static.whatthetvshow.com:9000/media/snapshots/c4c3021b168ba93572d402e313f0f884_medium.png\",\n\t\t\"http://whatthetvshow.com/fe/snapshots/2205\",\n\t\t\"Quiz unit tests Benjamin\",\n\t\t223,\n\t)\n\t// Persist it\n\tres, err := appInteractor.Create(testApp)\n\n\t// Testing returns\n\t// No need to test returns here since they are already handled in TestAddApp test\n\n\t// Try to delete it\n\tres, err = appInteractor.Delete(res)\n\tif err != nil {\n\t\t// Error raised during the deletion\n\t\tt.Error(\"App was not properly delete : \", err)\n\t\treturn\n\t}\n\tif res == \"\" {\n\t\t// No identifier was passed to confirm deletion\n\t\tt.Error(\"App was not properly deleted : no identifier returned\")\n\t\treturn\n\t}\n\n\tt.Log(\"TestDeleteApp: Test Clear\")\n\treturn\n}", "func DeleteApplication(kubeClient client.Client, ns string, relativePath string) error {\n\tapp, err := parseApplicationYaml(relativePath)\n\tif err != nil {\n\t\treturn err\n\t}\n\n\tobject := &applicationsv1beta1.Application{}\n\tobjectKey := types.NamespacedName{\n\t\tNamespace: ns,\n\t\tName: app.Name,\n\t}\n\terr = kubeClient.Get(context.TODO(), objectKey, object)\n\tif err != nil {\n\t\treturn err\n\t}\n\n\treturn kubeClient.Delete(context.TODO(), object)\n}", "func DeleteDeviceInRuntime(id string) error {\n\t// Avoid modifications to devices while deleting device\n\tmutex.Lock()\n\tdefer mutex.Unlock()\n\tif dev, ok := devices[id]; ok {\n\t\t// Stop all device processes and its measurements. Once finished they will be removed\n\t\t// from the bus and node closed (snmp connections for measurements will be closed)\n\t\tdev.StopGather()\n\t\tlog.Debugf(\"Bus retuned from the exit message to the ID device %s\", id)\n\t\tdelete(devices, id)\n\t\treturn nil\n\t}\n\tlog.Errorf(\"There is no %s device in the runtime device list\", id)\n\treturn nil\n}", "func (p *process) Delete() error {\n\tvar (\n\t\targs = append(p.container.runtimeArgs, \"delete\", \"-f\", p.container.id)\n\t\tcmd = exec.Command(p.container.runtime, args...)\n\t)\n\n\tcmd.SysProcAttr = osutils.SetPDeathSig()\n\tout, err := cmd.CombinedOutput()\n\tif err != nil {\n\t\treturn fmt.Errorf(\"%s: %v\", out, err)\n\t}\n\treturn nil\n}", "func (c Client) DeleteApplication(name string) (types.TaskRef, error) {\n var taskRef types.TaskRef\n\n app, err := c.Application(name)\n if err != nil {\n return taskRef, err\n }\n\n accounts := strings.Split(app.Accounts, \",\")\n\n var jobs []types.Job\n\n for _, account := range accounts {\n jobs = append(jobs, types.Job {\n Type: \"deleteApplication\",\n Account: account,\n User: \"\",\n Application: types.DeleteApplication {\n Name: app.Name,\n Accounts: app.Accounts,\n CloudProviders: app.CloudProviders.Names,\n },\n })\n }\n\n task := types.Task {\n Application: app.Name,\n Description: \"Deleting Application: \" + app.Name,\n Job : jobs,\n }\n\n resp, err := c.post(\"/applications/\" + name + \"/tasks\", task)\n defer ensureReaderClosed(resp)\n if err != nil {\n return taskRef, err\n }\n\n err = json.NewDecoder(resp.body).Decode(&taskRef)\n return taskRef, err\n}", "func DeleteProgramPipelines(n int32, pipelines *uint32) {\n C.glowDeleteProgramPipelines(gpDeleteProgramPipelines, (C.GLsizei)(n), (*C.GLuint)(unsafe.Pointer(pipelines)))\n}", "func (o *InstrumentClass) Delete(exec boil.Executor) error {\n\tif o == nil {\n\t\treturn errors.New(\"models: no InstrumentClass provided for delete\")\n\t}\n\n\tif err := o.doBeforeDeleteHooks(exec); err != nil {\n\t\treturn err\n\t}\n\n\targs := queries.ValuesFromMapping(reflect.Indirect(reflect.ValueOf(o)), instrumentClassPrimaryKeyMapping)\n\tsql := \"DELETE FROM \\\"instruments\\\".\\\"instrument_class\\\" WHERE \\\"id\\\"=$1\"\n\n\tif boil.DebugMode {\n\t\tfmt.Fprintln(boil.DebugWriter, sql)\n\t\tfmt.Fprintln(boil.DebugWriter, args...)\n\t}\n\n\t_, err := exec.Exec(sql, args...)\n\tif err != nil {\n\t\treturn errors.Wrap(err, \"models: unable to delete from instrument_class\")\n\t}\n\n\tif err := o.doAfterDeleteHooks(exec); err != nil {\n\t\treturn err\n\t}\n\n\treturn nil\n}", "func (o *Organism) DeleteG() error {\n\tif o == nil {\n\t\treturn errors.New(\"chado: no Organism provided for deletion\")\n\t}\n\n\treturn o.Delete(boil.GetDB())\n}", "func (s Store) DeleteApplicationWithVersion(title, version string) error {\n\ts.lock.Lock()\n\tdefer s.lock.Unlock()\n\n\tif exists, err := s.isApplicationPresent(title, version); !exists {\n\t\treturn err\n\t}\n\n\tdelete(s.appToDetails[title], version)\n\treturn nil\n}", "func (gt GtwyMgr) Delete(ctx context.Context, appcontext, remoteAddress string) error {\n\tif EnvDebugOn {\n\t\tlblog.LogEvent(\"GtwyMgr\", \"Delete\", \"info\", \"start\")\n\t}\n\n\t//check the approval list\n\tq := datastore.NewQuery(gt.bc.GetConfigValue(ctx, \"EnvGtwayDsKind\")).\n\t\tNamespace(gt.bc.GetConfigValue(ctx, \"EnvGtwayDsNamespace\")).\n\t\tFilter(\"appcontext =\", appcontext).\n\t\tFilter(\"remoteaddress =\", remoteAddress).\n\t\tKeysOnly()\n\n\tvar arr []Gateway\n\tkeys, err := gt.ds.GetAll(ctx, q, &arr)\n\tif err != nil {\n\t\treturn err\n\t}\n\n\ttx, err := gt.ds.NewTransaction(ctx)\n\tif err != nil {\n\t\treturn err\n\t}\n\n\tif err := tx.DeleteMulti(keys); err != nil {\n\t\ttx.Rollback()\n\t\treturn err\n\t}\n\n\tif _, err = tx.Commit(); err != nil {\n\t\treturn err\n\t}\n\n\tif EnvDebugOn {\n\t\tlblog.LogEvent(\"GtwyMgr\", \"Delete\", \"info\", \"end\")\n\t}\n\treturn nil\n}", "func (p *Processor) DeleteManifest(account keppel.Account, repo keppel.Repository, manifestDigest digest.Digest, actx keppel.AuditContext) error {\n\tvar (\n\t\ttagResults []keppel.Tag\n\t\ttags []string\n\t)\n\n\t_, err := p.db.Select(&tagResults,\n\t\t`SELECT * FROM tags WHERE repo_id = $1 AND digest = $2`,\n\t\trepo.ID, manifestDigest)\n\tif err != nil {\n\t\treturn err\n\t}\n\tfor _, tagResult := range tagResults {\n\t\ttags = append(tags, tagResult.Name)\n\t}\n\n\tresult, err := p.db.Exec(\n\t\t//this also deletes tags referencing this manifest because of \"ON DELETE CASCADE\"\n\t\t`DELETE FROM manifests WHERE repo_id = $1 AND digest = $2`,\n\t\trepo.ID, manifestDigest)\n\tif err != nil {\n\t\totherDigest, err2 := p.db.SelectStr(\n\t\t\t`SELECT parent_digest FROM manifest_manifest_refs WHERE repo_id = $1 AND child_digest = $2`,\n\t\t\trepo.ID, manifestDigest)\n\t\t// more than one manifest is referenced by another manifest\n\t\tif otherDigest != \"\" && err2 == nil {\n\t\t\treturn fmt.Errorf(\"cannot delete a manifest which is referenced by the manifest %s\", otherDigest)\n\t\t}\n\t\t// if the SELECT failed return the previous error to not shadow it\n\t\treturn err\n\t}\n\trowsDeleted, err := result.RowsAffected()\n\tif err != nil {\n\t\treturn err\n\t}\n\tif rowsDeleted == 0 {\n\t\treturn sql.ErrNoRows\n\t}\n\n\t//We delete in the storage *after* the deletion is durable in the DB to be\n\t//extra sure that we did not break any constraints (esp. manifest-manifest\n\t//refs and manifest-blob refs) that the DB enforces. Doing things in this\n\t//order might mean that, if DeleteManifest fails, we're left with a manifest\n\t//in the backing storage that is not referenced in the DB anymore, but this\n\t//is not a huge problem since the janitor can clean those up after the fact.\n\t//What's most important is that we don't lose any data in the backing storage\n\t//while it is still referenced in the DB.\n\t//\n\t//Also, the DELETE statement could fail if some concurrent process created a\n\t//manifest reference in the meantime. If that happens, and we have already\n\t//deleted the manifest in the backing storage, we've caused an inconsistency\n\t//that we cannot recover from.\n\terr = p.sd.DeleteManifest(account, repo.Name, manifestDigest)\n\tif err != nil {\n\t\treturn err\n\t}\n\n\tif userInfo := actx.UserIdentity.UserInfo(); userInfo != nil {\n\t\tp.auditor.Record(audittools.EventParameters{\n\t\t\tTime: p.timeNow(),\n\t\t\tRequest: actx.Request,\n\t\t\tUser: userInfo,\n\t\t\tReasonCode: http.StatusOK,\n\t\t\tAction: cadf.DeleteAction,\n\t\t\tTarget: auditManifest{\n\t\t\t\tAccount: account,\n\t\t\t\tRepository: repo,\n\t\t\t\tDigest: manifestDigest,\n\t\t\t\tTags: tags,\n\t\t\t},\n\t\t})\n\t}\n\n\treturn nil\n}", "func (p *ProcessDefinition) Delete(by QueryProcessDefinitionBy, query map[string]string) error {\n\terr := p.client.doDelete(\"/process-definition/\"+by.String(), query)\n\treturn err\n}", "func (p *ExperimentalPlayground) DeleteObject(object engine.Object, location engine.Location) error {\n\tif !location.Empty() {\n\t\tcontainer, err := p.getContainerByObject(object)\n\t\tif err != nil {\n\t\t\treturn errDeleteObject(err.Error())\n\t\t}\n\t\tp.gameMap.MRemoveContainer(location, container)\n\t}\n\n\tif err := p.deleteObject(object); err != nil {\n\t\treturn errDeleteObject(err.Error())\n\t}\n\n\treturn nil\n}", "func (s *BaseAspidaListener) ExitProgram(ctx *ProgramContext) {}", "func DeleteBook(isbn string) {\n delete(books, isbn)\n}", "func cmdDel(args *skel.CmdArgs) error {\n\tconf, err := parseConfig(args.StdinData)\n\tif err != nil {\n\t\treturn err\n\t}\n\t_ = conf\n\n\t// Do your delete here\n\n\treturn nil\n}", "func (s *ApplicationsService) DeleteReservedApplicationCommand() (resp *http.Response, err error) {\n\tpath := \"/applications/reserved\"\n\trel := &url.URL{Path: fmt.Sprintf(\"%s%s\", s.client.Context, path)}\n\treq, err := s.client.newRequest(\"DELETE\", rel, nil)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\n\tresp, err = s.client.do(req, nil)\n\tif err != nil {\n\t\treturn resp, err\n\t}\n\treturn resp, nil\n\n}", "func (s *StateDB) deleteStateObject(stateObject *stateObject) {\n\tstateObject.deleted = true\n\taddr := stateObject.Address()\n\ts.setError(s.trie.Delete(addr[:]))\n}", "func DeleteTrafficJam(w http.ResponseWriter, r *http.Request) {\n\tw.Header().Set(\"Content-Type\", \"application/json; charset=UTF-8\")\n\tid, err := getID(r)\n\tif err != nil {\n\t\tw.WriteHeader(http.StatusBadRequest)\n\t\t_, _ = w.Write([]byte(\"unable to parse id\"))\n\t\treturn\n\t}\n\n\t// Check for object existence\n\t_, err = app.GlobalTrafficJamStore.GetTrafficJam(id)\n\tif err != nil {\n\t\tw.WriteHeader(http.StatusNotFound)\n\t\t_, _ = w.Write([]byte(err.Error()))\n\t\treturn\n\t}\n\n\t// Delete object\n\tapp.GlobalTrafficJamStore.DeleteTrafficJam(id)\n\tw.WriteHeader(http.StatusOK)\n\t_, _ = w.Write([]byte(fmt.Sprintf(\"TrafficJam %d deleted\", id)))\n}", "func (as *AppStorage) DeleteApp(id string) error {\n\tinput := &dynamodb.DeleteItemInput{\n\t\tKey: map[string]*dynamodb.AttributeValue{\n\t\t\t\"id\": {S: aws.String(id)},\n\t\t},\n\t\tTableName: aws.String(appsTableName),\n\t}\n\t_, err := as.db.C.DeleteItem(input)\n\treturn err\n}", "func (u teamHandler) deleteAllocation(req *restful.Request, resp *restful.Response) {\n\thandleErrors(req, resp, func() error {\n\t\tteam := req.PathParameter(\"team\")\n\t\tname := req.PathParameter(\"name\")\n\n\t\tobj, err := u.Teams().Team(team).Allocations().Delete(req.Request.Context(), name, false)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\n\t\treturn resp.WriteHeaderAndEntity(http.StatusOK, obj)\n\t})\n}", "func (db *InMemDatabase) Delete(obj contrail.IObject) error {\n\tuid := parseUID(obj.GetUuid())\n\tdata, ok := db.objectData[uid]\n\tif !ok {\n\t\treturn fmt.Errorf(\"Object %s: not in database\", obj.GetUuid())\n\t}\n\tif len(data.children) > 0 {\n\t\treturn fmt.Errorf(\"Delete %s: has children %+v\", obj.GetUuid(), data.children)\n\t}\n\tif len(data.backRefs) > 0 {\n\t\treturn fmt.Errorf(\"Delete %s: has references %+v\", obj.GetUuid(), data.backRefs)\n\t}\n\n\tif !data.parent.IsNIL() {\n\t\tdb.deleteChild(data.parent, obj)\n\t\tif parentObj, ok := db.objByIDMap[data.parent]; ok {\n\t\t\tclearReferenceMask(parentObj)\n\t\t}\n\t}\n\tdb.deleteBackReferences(obj, data.refs)\n\n\tdelete(db.objByIDMap, uid)\n\tdelete(db.objectData, uid)\n\ttypeMap, ok := db.typeDB[obj.GetType()]\n\tif !ok {\n\t\treturn fmt.Errorf(\"No objects of type %s\", obj.GetType())\n\t}\n\tfqn := strings.Join(obj.GetFQName(), \":\")\n\tdelete(typeMap, fqn)\n\treturn nil\n}", "func (r *DeviceHealthScriptRunSummaryRequest) Delete(ctx context.Context) error {\n\treturn r.JSONRequest(ctx, \"DELETE\", \"\", nil, nil)\n}", "func Del(c *cli.Context) {\n\tif len(c.Args()) != 1 {\n\t\tMaybeError(c, \"expected <interface>\")\n\t}\n\tintf := c.Args()[0]\n\tservice, _ := NewVslConfig(c.Args()[0], \"\", \"\", \"\", \"\")\t\n\tvslfile := MaybeLoadVslfile(c)\n\n\ti, found := vslfile.Services.Contains_i(service)\n\tif found {\n\t\tvslfile.Services.RemoveIndex(i)\n\t\tif AnyBool(c, \"n\") {\n\t\t\tfmt.Printf(\"%s\", vslfile.Format())\n\t\t} else {\n\t\t\tMaybeSaveVslfile(c, vslfile)\n\t\t\tMaybePrintln(c, fmt.Sprintf(\"Deleted %s\", intf))\n\t\t}\n\t} else {\n\t\tMaybePrintln(c, fmt.Sprintf(\"%s not found in %s\", intf, GetServicesPath()))\n\t}\n}", "func deleteObject(w http.ResponseWriter, r *http.Request) {\n\tvars := mux.Vars(r)\n\tkey, _ := strconv.Atoi(vars[\"id\"])\n\tfound := false\n\tlocation := 0\n\n\tfor index := range listOfObjects {\n\t\tif listOfObjects[index].ID == key {\n\t\t\tfound = true\n\t\t\tlocation = index\n\t\t\tbreak\n\t\t}\n\t}\n\n\tif found == true {\n\t\tlistOfObjects = append(listOfObjects[:location], listOfObjects[location+1:]...)\n\t\terr := json.NewEncoder(w).Encode(\"Removed\")\n\t\tif err != nil {\n\t\t\tw.WriteHeader(http.StatusInternalServerError)\n\t\t\tlog.Fatal(\"Error encoding JSON\")\n\t\t}\n\t} else {\n\t\tw.WriteHeader(http.StatusNotFound)\n\t\terr := json.NewEncoder(w).Encode(\"Could not find object\")\n\t\tif err != nil {\n\t\t\tw.WriteHeader(http.StatusInternalServerError)\n\t\t\tlog.Fatal(\"Error encoding JSON\")\n\t\t}\n\t}\n}", "func (s *server) Delete(ctx context.Context, body *pb.NameHolder) (*pb.DeletionResponse, error) {\n\tappName := body.GetName()\n\tfilter := types.M{\n\t\tmongo.NameKey: appName,\n\t\tmongo.InstanceTypeKey: mongo.AppInstance,\n\t}\n\n\tnode, _ := redis.FetchAppNode(appName)\n\tgo redis.DecrementServiceLoad(ServiceName, node)\n\tgo redis.RemoveApp(appName)\n\tgo diskCleanup(appName)\n\n\tif configs.CloudflareConfig.PlugIn {\n\t\tgo cloudflare.DeleteRecord(appName, mongo.AppInstance)\n\t}\n\n\t_, err := mongo.DeleteInstance(filter)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\treturn &pb.DeletionResponse{Success: true}, nil\n}", "func (o *Cvtermsynonym) Delete(exec boil.Executor) error {\n\tif o == nil {\n\t\treturn errors.New(\"chado: no Cvtermsynonym provided for delete\")\n\t}\n\n\tif err := o.doBeforeDeleteHooks(exec); err != nil {\n\t\treturn err\n\t}\n\n\targs := queries.ValuesFromMapping(reflect.Indirect(reflect.ValueOf(o)), cvtermsynonymPrimaryKeyMapping)\n\tsql := \"DELETE FROM \\\"cvtermsynonym\\\" WHERE \\\"cvtermsynonym_id\\\"=$1\"\n\n\tif boil.DebugMode {\n\t\tfmt.Fprintln(boil.DebugWriter, sql)\n\t\tfmt.Fprintln(boil.DebugWriter, args...)\n\t}\n\n\t_, err := exec.Exec(sql, args...)\n\tif err != nil {\n\t\treturn errors.Wrap(err, \"chado: unable to delete from cvtermsynonym\")\n\t}\n\n\tif err := o.doAfterDeleteHooks(exec); err != nil {\n\t\treturn err\n\t}\n\n\treturn nil\n}", "func (fs *Stow) DeleteObject(ctx context.Context, path string) error {\n\tlocation, err := stow.Dial(fs.kind, fs.config)\n\tif err != nil {\n\t\tlog.Errorf(\"stow.Dial fail: %v\", err)\n\t\treturn err\n\t}\n\n\tcontainer, err := location.Container(fs.bucket)\n\tif err != nil {\n\t\tlog.Errorf(\"stow.GetContainer fail: %v\", err)\n\t\treturn err\n\t}\n\n\terr = container.RemoveItem(path)\n\tif err != nil {\n\t\tlog.Errorf(\"stow.Container.RemoveItem fail: %v\", err)\n\t\treturn err\n\t}\n\n\treturn nil\n}", "func (d *swiftDriver) DeleteManifest(account keppel.Account, repoName string, manifestDigest digest.Digest) error {\n\tc, _, err := d.getBackendConnection(account)\n\tif err != nil {\n\t\treturn err\n\t}\n\to := manifestObject(c, repoName, manifestDigest)\n\treturn o.Delete(nil, nil)\n}", "func (o *Shelf) DeleteG() error {\n\tif o == nil {\n\t\treturn errors.New(\"models: no Shelf provided for deletion\")\n\t}\n\n\treturn o.Delete(boil.GetDB())\n}", "func (app *application) Delete(listHashStr string) error {\n\t// retrieve the identity:\n\tidentity, err := app.identityRepository.Retrieve(app.name, app.seed, app.password)\n\tif err != nil {\n\t\treturn err\n\t}\n\n\tlistHash, err := app.hashAdapter.FromString(listHashStr)\n\tif err != nil {\n\t\treturn err\n\t}\n\n\treturn identity.Wallet().Lists().Delete(*listHash)\n}", "func (app *frame) Delete(name string) error {\n\tif app.isStopped {\n\t\treturn nil\n\t}\n\n\tif _, ok := app.variables[name]; !ok {\n\t\tstr := fmt.Sprintf(\"variable: the name variable (%s) is not defined\", name)\n\t\treturn errors.New(str)\n\t}\n\n\tdelete(app.variables, name)\n\treturn nil\n}", "func (ds *MySQLDatastore) RemoveApp(ctx context.Context, appName string) error {\n\t_, err := ds.db.Exec(`\n\t DELETE FROM apps\n\t WHERE name = ?\n\t`, appName)\n\n\tif err != nil {\n\t\treturn err\n\t}\n\n\treturn nil\n}", "func cmdQuit(source interface{}, params [][]byte) {\n\tu, ok := source.(*core.User)\n\tif !ok {\n\t\treturn\n\t}\n\n\t// Delete the user in question.\n\tu.Delete(u.Owndata(), u, string(params[0]))\n}", "func CliS3CmdDel() *cobra.Command {\n\tcmd := &cobra.Command{\n\t\tUse: \"del BUCKET/OBJECT\",\n\t\tShort: \"Delete bucket\",\n\t\tArgs: cobra.ExactArgs(1),\n\t\tRun: S3CmdDel,\n\t\tDisableFlagsInUseLine: true,\n\t}\n\t//cmd.Flags().BoolVarP(&S3CmdRec, \"recursive\", \"r\", false, \"Recursive removal.\")\n\t//cmd.Flags().BoolVarP(&S3CmdForce, \"force\", \"f\", false, \"Force removal.\")\n\n\treturn cmd\n}", "func (o *Shelf) Delete(exec boil.Executor) error {\n\tif o == nil {\n\t\treturn errors.New(\"models: no Shelf provided for delete\")\n\t}\n\to.operation = \"DELETE\"\n\n\tif err := o.doBeforeDeleteHooks(exec); err != nil {\n\t\treturn err\n\t}\n\n\targs := queries.ValuesFromMapping(reflect.Indirect(reflect.ValueOf(o)), shelfPrimaryKeyMapping)\n\tsql := \"DELETE FROM `shelf` WHERE `id`=?\"\n\n\tif boil.DebugMode {\n\t\tfmt.Fprintln(boil.DebugWriter, sql)\n\t\tfmt.Fprintln(boil.DebugWriter, args)\n\t}\n\n\t_, err := exec.Exec(sql, args...)\n\tif err != nil {\n\t\treturn errors.Wrap(err, \"models: unable to delete from shelf\")\n\t}\n\n\tif err := o.doAfterDeleteHooks(exec); err != nil {\n\t\treturn err\n\t}\n\n\treturn nil\n}", "func DeletePrj(name string) error {\n\t// limit Project quota to zero\n\tif err := limitPrjQuota(name, \"0\"); err != nil {\n\t\treturn err\n\t}\n\n\t// TODO: remove Project directory\n\n\t// remove project info from mapping files\n\tif err := prjManager.Delete(name); err != nil {\n\t\treturn errors.Wrap(err, \"delete Project\")\n\t}\n\n\treturn nil\n}", "func (s *Scene) Delete() {\n\ts.propOctree = nil\n\ts.props = nil\n\n\ts.bodyPool = nil\n\ts.dynamicBodies = nil\n\n\ts.firstSBConstraint = nil\n\ts.lastSBConstraint = nil\n\n\ts.firstDBConstraint = nil\n\ts.lastDBConstraint = nil\n}", "func deleteFile(ctx context.Context, baseDir, hash, extension string) error {\n\t// Verify object exists.\n\tfilepath := getPathByHash(ctx, baseDir, hash, extension)\n\n\treturn os.Remove(filepath)\n}", "func (c *AcademicYearClient) DeleteOne(ay *AcademicYear) *AcademicYearDeleteOne {\n\treturn c.DeleteOneID(ay.ID)\n}", "func (s *BaselimboListener) ExitProgram(ctx *ProgramContext) {}", "func printDeleteAppInfo(client *occlient.Client, appName string, projectName string) error {\n\tcomponentList, err := component.List(client, appName)\n\tif err != nil {\n\t\treturn errors.Wrap(err, \"failed to get Component list\")\n\t}\n\n\tfor _, currentComponent := range componentList {\n\t\tcomponentDesc, err := component.GetComponentDesc(client, currentComponent.ComponentName, appName, projectName)\n\t\tif err != nil {\n\t\t\treturn errors.Wrap(err, \"unable to get component description\")\n\t\t}\n\t\tlog.Info(\"Component\", currentComponent.ComponentName, \"will be deleted.\")\n\n\t\tif len(componentDesc.URLs) != 0 {\n\t\t\tfmt.Println(\" Externally exposed URLs will be removed\")\n\t\t}\n\n\t\tfor _, store := range componentDesc.Storage {\n\t\t\tfmt.Println(\" Storage\", store.Name, \"of size\", store.Size, \"will be removed\")\n\t\t}\n\n\t}\n\treturn nil\n}", "func (r *DeviceManagementScriptRequest) Delete(ctx context.Context) error {\n\treturn r.JSONRequest(ctx, \"DELETE\", \"\", nil, nil)\n}", "func TestRemoveUnexistingWindow(t *testing.T) {\n\tp, err := NewProgram()\n\tif err != nil {\n\t\tt.Error(\"Unable to start termbox\")\n\t}\n\n\tdefer p.Close()\n\n\tw := NewWindow()\n\n\terr2 := p.RemoveWindow(w)\n\tif err2 == nil {\n\t\tt.Error(\"An error was expected\")\n\t}\n}", "func (o *Phenotypeprop) Delete(exec boil.Executor) error {\n\tif o == nil {\n\t\treturn errors.New(\"chado: no Phenotypeprop provided for delete\")\n\t}\n\n\tif err := o.doBeforeDeleteHooks(exec); err != nil {\n\t\treturn err\n\t}\n\n\targs := queries.ValuesFromMapping(reflect.Indirect(reflect.ValueOf(o)), phenotypepropPrimaryKeyMapping)\n\tsql := \"DELETE FROM \\\"phenotypeprop\\\" WHERE \\\"phenotypeprop_id\\\"=$1\"\n\n\tif boil.DebugMode {\n\t\tfmt.Fprintln(boil.DebugWriter, sql)\n\t\tfmt.Fprintln(boil.DebugWriter, args...)\n\t}\n\n\t_, err := exec.Exec(sql, args...)\n\tif err != nil {\n\t\treturn errors.Wrap(err, \"chado: unable to delete from phenotypeprop\")\n\t}\n\n\tif err := o.doAfterDeleteHooks(exec); err != nil {\n\t\treturn err\n\t}\n\n\treturn nil\n}", "func (repo GymRepository) DeleteGymByID(id uint64) {\n\trepo.db.Delete(&models.GymProfile{}, id)\n}", "func DeleteSerial() {\n\t// TODO: list token profiles?\n\tt := promptui.Prompt{\n\t\tLabel: \"Which profile?\",\n\t}\n\tname, err := t.Run()\n\tif err != nil {\n\t\tlog.Fatal(err)\n\t}\n\n\t// first check if this key exists\n\t_, err = keyring.Get(ServiceName, name)\n\tif err != nil {\n\t\tlog.Fatal(err)\n\t}\n\n\terr = keyring.Delete(ServiceName, name)\n\tif err != nil {\n\t\tlog.Fatal(err)\n\t}\n\n\tfmt.Printf(\"Token for %v deleted successfully\\n\", name)\n}", "func (p *OnPrem) DeleteInstance(ctx *Context, instancename string) error {\n\n\tpid, err := strconv.Atoi(instancename)\n\tif err != nil {\n\t\tfmt.Println(err)\n\t}\n\n\t// yolo\n\terr = sysKill(pid)\n\tif err != nil {\n\t\tfmt.Println(err)\n\t}\n\n\topshome := GetOpsHome()\n\tipath := path.Join(opshome, \"instances\", instancename)\n\terr = os.Remove(ipath)\n\tif err != nil {\n\t\treturn err\n\t}\n\n\treturn nil\n}" ]
[ "0.74283713", "0.72676706", "0.71689266", "0.69745326", "0.6885958", "0.67759204", "0.6505266", "0.6099523", "0.6004627", "0.5670174", "0.56151813", "0.552896", "0.5490562", "0.54772174", "0.5461797", "0.54362106", "0.54345506", "0.5404952", "0.5404952", "0.5381933", "0.5376429", "0.5376429", "0.53603697", "0.5352627", "0.5323323", "0.5319084", "0.5288151", "0.5272982", "0.5257436", "0.52538294", "0.52444184", "0.52369386", "0.5236623", "0.5235572", "0.5235427", "0.5232613", "0.5224916", "0.52242947", "0.5207451", "0.5204071", "0.52009904", "0.519768", "0.51488215", "0.51445985", "0.514199", "0.51377845", "0.51268834", "0.5107944", "0.5104516", "0.51007605", "0.5100486", "0.50954795", "0.50939137", "0.5091155", "0.5087346", "0.50860673", "0.5080097", "0.5078335", "0.5075121", "0.50718623", "0.506998", "0.50686496", "0.5068487", "0.50512093", "0.504706", "0.5040616", "0.5035425", "0.5033027", "0.50328416", "0.50321996", "0.5031711", "0.50268865", "0.50212216", "0.50180155", "0.5015039", "0.5008375", "0.49928093", "0.4991346", "0.49846014", "0.4979026", "0.4977898", "0.49777687", "0.49756613", "0.49655646", "0.49599093", "0.4958395", "0.49565947", "0.49526358", "0.49525717", "0.4948085", "0.4941659", "0.49369204", "0.49291244", "0.49189624", "0.4914925", "0.49128544", "0.4910776", "0.49065873", "0.49053034" ]
0.69332004
5
delete program pipeline objects
func DeleteProgramPipelines(n int32, pipelines *uint32) { C.glowDeleteProgramPipelines(gpDeleteProgramPipelines, (C.GLsizei)(n), (*C.GLuint)(unsafe.Pointer(pipelines))) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func DeleteProgramPipelines(n int32, pipelines *uint32) {\n\tsyscall.Syscall(gpDeleteProgramPipelines, 2, uintptr(n), uintptr(unsafe.Pointer(pipelines)), 0)\n}", "func DeleteProgramPipelines(n int32, pipelines *uint32) {\n C.glowDeleteProgramPipelines(gpDeleteProgramPipelines, (C.GLsizei)(n), (*C.GLuint)(unsafe.Pointer(pipelines)))\n}", "func (a *apiServer) DeletePipelines(ctx context.Context, request *pps.DeletePipelinesRequest) (response *pps.DeletePipelinesResponse, retErr error) {\n\tvar (\n\t\tprojects = make(map[string]bool)\n\t\tdr = &pps.DeletePipelineRequest{\n\t\t\tForce: request.Force,\n\t\t\tKeepRepo: request.KeepRepo,\n\t\t}\n\t\tps []*pps.Pipeline\n\t)\n\tfor _, p := range request.GetProjects() {\n\t\tprojects[p.String()] = true\n\t}\n\tdr.Pipeline = &pps.Pipeline{}\n\tpipelineInfo := &pps.PipelineInfo{}\n\tdeleted := make(map[string]struct{})\n\tif err := a.pipelines.ReadOnly(ctx).List(pipelineInfo, col.DefaultOptions(), func(string) error {\n\t\tif _, ok := deleted[pipelineInfo.Pipeline.String()]; ok {\n\t\t\t// while the delete pipeline call will delete historical versions,\n\t\t\t// they could still show up in the list. Ignore them.\n\t\t\treturn nil\n\t\t}\n\t\tif !request.GetAll() && !projects[pipelineInfo.GetPipeline().GetProject().GetName()] {\n\t\t\treturn nil\n\t\t}\n\t\tdeleted[pipelineInfo.Pipeline.String()] = struct{}{}\n\t\tps = append(ps, pipelineInfo.Pipeline)\n\t\treturn nil\n\t}); err != nil {\n\t\treturn nil, errors.EnsureStack(err)\n\t}\n\tfor _, p := range ps {\n\t\tif _, err := a.StopPipeline(ctx, &pps.StopPipelineRequest{Pipeline: p}); err != nil {\n\t\t\treturn nil, errors.Wrapf(err, \"stop pipeline %q\", p.String())\n\t\t}\n\n\t}\n\tif err := a.env.TxnEnv.WithWriteContext(ctx, func(txnCtx *txncontext.TransactionContext) error {\n\t\tvar rs []*pfs.Repo\n\t\tfor _, p := range ps {\n\t\t\tdeleteRepos, err := a.deletePipelineInTransaction(ctx, txnCtx, &pps.DeletePipelineRequest{Pipeline: p, KeepRepo: request.KeepRepo})\n\t\t\tif err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\t\t\trs = append(rs, deleteRepos...)\n\t\t}\n\t\treturn a.env.PFSServer.DeleteReposInTransaction(ctx, txnCtx, rs, request.Force)\n\t}); err != nil {\n\t\treturn nil, err\n\t}\n\treturn &pps.DeletePipelinesResponse{Pipelines: ps}, nil\n}", "func destructor(cmd *cobra.Command, args []string) {\n\tlog.Debug().Msgf(\"Running Destructor.\\n\")\n\tif debug {\n\t\t// Keep intermediary files, when on debug\n\t\tlog.Debug().Msgf(\"Skipping file clearance on Debug Mode.\\n\")\n\t\treturn\n\t}\n\tintermediaryFiles := []string{\"generate_pylist.py\", \"pylist.json\", \"dependencies.txt\", \"golist.json\", \"npmlist.json\"}\n\tfor _, file := range intermediaryFiles {\n\t\tfile = filepath.Join(os.TempDir(), file)\n\t\tif _, err := os.Stat(file); err != nil {\n\t\t\tif os.IsNotExist(err) {\n\t\t\t\t// If file doesn't exists, continue\n\t\t\t\tcontinue\n\t\t\t}\n\t\t}\n\t\te := os.Remove(file)\n\t\tif e != nil {\n\t\t\tlog.Fatal().Msgf(\"Error clearing files %s\", file)\n\t\t}\n\t}\n}", "func CleanUp(ctx context.Context, cfg *config.Config, pipeline *pipelines.Pipeline, name names.Name) error {\n\tkubectlPath, err := cfg.Tools[config.Kubectl].Resolve()\n\tif err != nil {\n\t\treturn err\n\t}\n\tcmd := proc.GracefulCommandContext(ctx, kubectlPath, \"delete\",\n\t\t\"all\",\n\t\t\"-l\", k8s.StackLabel+\"=\"+name.DNSName(),\n\t)\n\tif err := cmd.Run(); err != nil {\n\t\treturn fmt.Errorf(\"could not delete k8s resources: %v\", err)\n\t}\n\treturn nil\n}", "func (am *AssetManager) Clean() {\n\tfor name, model := range am.Models {\n\t\tmodel.Delete()\n\t\tdelete(am.Models, name)\n\t}\n\tfor name, tex := range am.Textures {\n\t\ttex.Delete()\n\t\tdelete(am.Textures, name)\n\t}\n\tfor name, prog := range am.Programs {\n\t\tprog.Delete()\n\t\tdelete(am.Programs, name)\n\t}\n}", "func DeletePipeline(key, name string) error {\n\tpath := fmt.Sprintf(\"/project/%s/pipeline/%s\", key, name)\n\n\t_, code, err := Request(\"DELETE\", path, nil)\n\tif err != nil {\n\t\treturn err\n\t}\n\tif code >= 300 {\n\t\treturn fmt.Errorf(\"HTTP %d\", code)\n\t}\n\n\treturn nil\n}", "func (am *Manager) Clean() {\n\tfor name, m := range am.Materials {\n\t\tLogger.Printf(\"Manager: deleting Material '%s'\\n\", name)\n\t\tm.Clean()\n\t\tdelete(am.Materials, name)\n\t}\n\tfor name, m := range am.Meshes {\n\t\tLogger.Printf(\"Manager: deleting Mesh '%s'\\n\", name)\n\t\tm.Clean()\n\t\tdelete(am.Meshes, name)\n\t}\n\tfor set, prog := range am.Programs {\n\t\tLogger.Printf(\"Manager: deleting Program '%v'\\n\", set)\n\t\tgl.DeleteProgram(prog)\n\t\tdelete(am.Programs, set)\n\t}\n\tfor name, shader := range am.Shaders {\n\t\tLogger.Printf(\"Manager: deleting Shader '%s'\\n\", name)\n\t\tgl.DeleteShader(shader)\n\t\tdelete(am.Shaders, name)\n\t}\n\tfor name, tex := range am.Textures {\n\t\tLogger.Printf(\"Manager: deleting Texture '%s'\\n\", name)\n\t\ttex.Clean()\n\t\tdelete(am.Textures, name)\n\t}\n}", "func cleanup() {\n\tfor _, cmd := range runningApps {\n\t\tcmd.Process.Kill()\n\t}\n}", "func (r *gui3dRenderer) cleanUp() {\n\t\tr.shader.CleanUp()\n}", "func (s *Scene) Cleanup() {\n\tvar id uint32\n\tfor i := 0; i < numPrograms; i++ {\n\t\tid = s.Programs[i]\n\t\tgl.UseProgram(id)\n\t\tgl.DeleteProgram(id)\n\t}\n}", "func Clean() error { return sh.Run(\"mage\", \"-clean\") }", "func (p *MyPipeline) Del(keys ...interface{}) client.Result {\n\treturn p.Pipeline.Del(keys)\n}", "func DeletePipeline(ctx context.Context, db gorp.SqlExecutor, pipelineID int64, userID int64) error {\n\tif err := DeleteAllStage(ctx, db, pipelineID, userID); err != nil {\n\t\treturn err\n\t}\n\n\tif err := DeleteAllParameterFromPipeline(db, pipelineID); err != nil {\n\t\treturn err\n\t}\n\n\t// Delete pipeline\n\tquery := `DELETE FROM pipeline WHERE id = $1`\n\tif _, err := db.Exec(query, pipelineID); err != nil {\n\t\treturn sdk.WithStack(err)\n\t}\n\n\treturn nil\n}", "func (e *engine) DeletePipeline(ctx context.Context, p *library.Pipeline) error {\n\te.logger.WithFields(logrus.Fields{\n\t\t\"pipeline\": p.GetCommit(),\n\t}).Tracef(\"deleting pipeline %s from the database\", p.GetCommit())\n\n\t// cast the library type to database type\n\t//\n\t// https://pkg.go.dev/github.com/go-vela/types/database#PipelineFromLibrary\n\tpipeline := database.PipelineFromLibrary(p)\n\n\t// send query to the database\n\treturn e.client.\n\t\tTable(constants.TablePipeline).\n\t\tDelete(pipeline).\n\t\tError\n}", "func (p *NoOpNodeGroupListProcessor) CleanUp() {\n}", "func (r *RealRunner) Clean() error {\n\tr.mu.Lock()\n\tdefer r.mu.Unlock()\n\tfor pid, p := range r.processes {\n\t\tif err := p.Kill(); err != nil {\n\t\t\treturn err\n\t\t}\n\t\tdelete(r.processes, pid)\n\t}\n\treturn nil\n}", "func (p *transformDataNodes) CleanUp() {}", "func (e Engine) Clean() {\n\tos.RemoveAll(e.outputFolder)\n\treturn\n}", "func cleanUp(pipelineId uuid.UUID, lc *fs_tool.LifeCycle) {\n\tlogger.Infof(\"%s: DeleteFolders() ...\\n\", pipelineId)\n\tif err := lc.DeleteFolders(); err != nil {\n\t\tlogger.Error(\"%s: DeleteFolders(): %s\\n\", pipelineId, err.Error())\n\t}\n\tlogger.Infof(\"%s: DeleteFolders() complete\\n\", pipelineId)\n\tlogger.Infof(\"%s: complete\\n\", pipelineId)\n}", "func DeleteBinary(p gaia.Pipeline) error {\n\tbinaryFile := filepath.Join(gaia.Cfg.PipelinePath, appendTypeToName(p.Name, p.Type))\n\treturn os.Remove(binaryFile)\n}", "func cleanup() {\n\tserver.Applications = []*types.ApplicationMetadata{}\n}", "func (a *apiServer) DeletePipeline(ctx context.Context, request *pps.DeletePipelineRequest) (response *emptypb.Empty, retErr error) {\n\tif request != nil && request.Pipeline != nil {\n\t\tensurePipelineProject(request.GetPipeline())\n\t}\n\tif request.All { //nolint:staticcheck\n\t\t_, err := a.DeletePipelines(ctx, &pps.DeletePipelinesRequest{\n\t\t\tKeepRepo: request.KeepRepo,\n\t\t})\n\t\treturn &emptypb.Empty{}, errors.Wrap(err, \"delete all pipelines\")\n\t} else if err := a.deletePipeline(ctx, request); err != nil {\n\t\treturn nil, err\n\t}\n\n\treturn &emptypb.Empty{}, nil\n}", "func cleanUpAfterProjects(projects []string) {\n\tfor _, p := range projects {\n\t\todoDeleteProject(p)\n\t}\n}", "func (es *Connection) DeletePipeline(\n\tid string,\n\tparams map[string]string,\n) (int, *QueryResult, error) {\n\treturn withQueryResult(es.apiCall(\"DELETE\", \"_ingest\", \"pipeline\", id, \"\", params, nil))\n}", "func Clean(c Config) {\n\n\tSetup(&c)\n\tContainers, _ := model.DockerContainerList()\n\n\tfor _, Container := range Containers {\n\t\ttarget := false\n\t\tif l := Container.Labels[\"pygmy.enable\"]; l == \"true\" || l == \"1\" {\n\t\t\ttarget = true\n\t\t}\n\t\tif l := Container.Labels[\"pygmy\"]; l == \"pygmy\" {\n\t\t\ttarget = true\n\t\t}\n\n\t\tif target {\n\t\t\terr := model.DockerKill(Container.ID)\n\t\t\tif err == nil {\n\t\t\t\tfmt.Printf(\"Successfully killed %v.\\n\", Container.Names[0])\n\t\t\t}\n\n\t\t\terr = model.DockerRemove(Container.ID)\n\t\t\tif err == nil {\n\t\t\t\tfmt.Printf(\"Successfully removed %v.\\n\", Container.Names[0])\n\t\t\t}\n\t\t}\n\t}\n\n\tfor _, network := range c.Networks {\n\t\tmodel.DockerNetworkRemove(&network)\n\t\tif s, _ := model.DockerNetworkStatus(&network); s {\n\t\t\tfmt.Printf(\"Successfully removed network %v\\n\", network.Name)\n\t\t} else {\n\t\t\tfmt.Printf(\"Network %v was not removed\\n\", network.Name)\n\t\t}\n\t}\n\n\tfor _, resolver := range c.Resolvers {\n\t\tresolver.Clean()\n\t}\n}", "func (px *Paxos) Kill() {\n px.dead = true\n if px.l != nil {\n px.l.Close()\n }\n}", "func (px *Paxos) Kill() {\n px.dead = true\n if px.l != nil {\n px.l.Close()\n }\n}", "func (p *Pipeline) CleanUp(signal os.Signal) error {\n\tvar keepNetworkAlive bool\n\t// Stop all services which are not marked as keep-running\n\tpipelines, err := p.Definition.Pipelines()\n\tif err != nil {\n\t\treturn err\n\t}\n\tfor _, pipeline := range *pipelines {\n\t\tfor _, step := range pipeline {\n\t\t\t// If services are still running, keep the network\n\t\t\tif step.Meta.Type == ServiceTypeService && step.Meta.KeepAlive != KeepAliveNo {\n\t\t\t\tif Verbose {\n\t\t\t\t\tlog.Printf(\"Keeping network as '%s' can be still alive\", step.ColoredName())\n\t\t\t\t}\n\t\t\t\tkeepNetworkAlive = true\n\t\t\t}\n\t\t\t// Remove all steps and services marked as not to keep alive\n\t\t\tif step.Meta.Type == ServiceTypeStep || step.Meta.KeepAlive == KeepAliveNo {\n\t\t\t\trunner := p.GetRunnerForMeta(step.Meta)\n\t\t\t\tif _, err := runner.ContainerKiller(step)(); err != nil {\n\t\t\t\t\tpipelineLogger.Printf(\"Error killing %s: %s\", step.ColoredName(), err)\n\t\t\t\t}\n\t\t\t\tif err := runner.ContainerRemover(step)(); err != nil {\n\t\t\t\t\tpipelineLogger.Printf(\"Error removing %s: %s\", step.ColoredName(), err)\n\t\t\t\t}\n\t\t\t}\n\t\t\tstep.Meta.Close()\n\t\t}\n\t}\n\t// If we are allowed, start a cleanup container to delete all files in the\n\t// temporary directories as deletion from outside will fail when\n\t// user-namespaces are used.\n\tif !p.Environment.TempDirNoAutoClean {\n\t\tif err := p.RemoveTempDirData(); err != nil {\n\t\t\tpipelineLogger.Printf(\"Error removing temporary directories: %s\", err)\n\t\t}\n\t}\n\t// Remove network if not needed anymore\n\tif !keepNetworkAlive {\n\t\tif err := p.RemoveNetwork(); err != nil {\n\t\t\tpipelineLogger.Printf(\"Error removing network %s: %s\", string(p.Network), err)\n\t\t}\n\t}\n\treturn p.Environment.CleanUp(signal)\n}", "func (p *panel) trash() {\n\tif p.slab != nil {\n\t\tp.slab.Dispose()\n\t\tp.slab = nil\n\t}\n\tfor _, cube := range p.cubes {\n\t\tcube.reset(0)\n\t}\n}", "func (client *Client) DeletePipeline(\n\tctx context.Context, id string,\n) (*ErrorInfo, error) {\n\treturn client.callDelete(ctx, client.Endpoints().Pipeline(id), nil, nil)\n}", "func (ap *Argument) Free(proc *process.Process, pipelineFailed bool) {\n\tif ap.ctr != nil {\n\t\tif ap.ctr.s3Writer != nil {\n\t\t\tap.ctr.s3Writer.Free(proc)\n\t\t\tap.ctr.s3Writer = nil\n\t\t}\n\n\t\t// Free the partition table S3writer object resources\n\t\tif ap.ctr.partitionS3Writers != nil {\n\t\t\tfor _, writer := range ap.ctr.partitionS3Writers {\n\t\t\t\twriter.Free(proc)\n\t\t\t}\n\t\t\tap.ctr.partitionS3Writers = nil\n\t\t}\n\t}\n}", "func (eng *Engine) Clean() {\n\tfor _, f := range eng.Junk {\n\t\tif err := os.Remove(f); err != nil {\n\t\t\teng.logf(\"clean: %v\\n\", err)\n\t\t}\n\t}\n}", "func (r *OutlineRenderer) cleanUp() {\n\tr.shader.CleanUp()\n}", "func (px *Paxos) Kill() {\n atomic.StoreInt32(&px.dead, 1)\n if px.l != nil {\n px.l.Close()\n }\n}", "func (c *PipelineDeleteCommand) deletePipeline() (*http.Response, error) {\n\tresp, err := c.ApiMeta.GateClient.PipelineControllerApi.DeletePipelineUsingDELETE(c.ApiMeta.Context,\n\t\tc.application,\n\t\tc.name)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\n\treturn resp, err\n}", "func (c *MockClient) DeletePipeline(namespace, name string) error {\n\targs := c.Called(namespace, name)\n\treturn args.Error(0)\n}", "func DeleteProgram(program uint32) {\n C.glowDeleteProgram(gpDeleteProgram, (C.GLuint)(program))\n}", "func projectCleanup(env environment.Environment, macro *model.Macro) error {\n\tpartialComparisonService := env.ServiceFactory().MustPartialComparisonService()\n\treturn partialComparisonService.DeleteFrom(macro)\n}", "func (cp *OCIConveyorPacker) CleanUp() {\n\tos.RemoveAll(cp.b.Path)\n}", "func destroy(ar *allocRunner) {\n\tar.Destroy()\n\t<-ar.DestroyCh()\n}", "func deleteClonedProject(path string) {\n\tos.RemoveAll(path)\n}", "func (pm partitionMap) cleanup() {\n\tfor ns, partitions := range pm {\n\t\tfor i := range partitions.Replicas {\n\t\t\tfor j := range partitions.Replicas[i] {\n\t\t\t\tpartitions.Replicas[i][j] = nil\n\t\t\t}\n\t\t\tpartitions.Replicas[i] = nil\n\t\t}\n\n\t\tpartitions.Replicas = nil\n\t\tpartitions.regimes = nil\n\n\t\tdelete(pm, ns)\n\t}\n}", "func (p Pipeline) KillContainers(preRun bool) error {\n\t_, _, _, err := p.runCommand(runConfig{\n\t\tselection: func(step Step) bool {\n\t\t\treturn !preRun || step.Meta.KeepAlive != KeepAliveReplace\n\t\t},\n\t\trun: func(runner Runner, step Step) func() error {\n\t\t\treturn func() error {\n\t\t\t\tif _, err := runner.ContainerKiller(step)(); err != nil {\n\t\t\t\t\tpipelineLogger.Printf(\"Error killing %s: %s\", step.ColoredName(), err)\n\t\t\t\t}\n\t\t\t\tif err := runner.ContainerRemover(step)(); err != nil {\n\t\t\t\t\tpipelineLogger.Printf(\"Error removing %s: %s\", step.ColoredName(), err)\n\t\t\t\t}\n\t\t\t\treturn nil\n\t\t\t}\n\t\t},\n\t})\n\treturn err\n}", "func (o *Objects) GC() error {\n\tfiles := map[string]bool{}\n\tdirs := map[string]bool{}\n\to.Before.visitFile(func(file string) {\n\t\tfiles[file] = true\n\t})\n\to.Before.visitDir(func(dir string) {\n\t\tdirs[dir] = true\n\t})\n\to.visitFile(func(file string) {\n\t\tdelete(files, file)\n\t\to.deleteParents(dirs, file)\n\t})\n\to.visitDir(func(dir string) {\n\t\tdelete(dirs, dir)\n\t\to.deleteParents(dirs, dir)\n\t})\n\n\tfor file := range files {\n\t\tif err := o.Remove(file); err != nil {\n\t\t\treturn err\n\t\t}\n\t}\n\tfor dir := range dirs {\n\t\tif err := o.RemoveAll(dir); err != nil {\n\t\t\treturn err\n\t\t}\n\t}\n\treturn nil\n}", "func (c *bdCommon) destroy(ctx context.Context, stack *thrapb.Stack) []*thrapb.ActionResult {\n\tar := make([]*thrapb.ActionResult, 0, len(stack.Components))\n\n\tfor _, comp := range stack.Components {\n\t\tr := &thrapb.ActionResult{\n\t\t\tAction: \"destroy\",\n\t\t\tResource: comp.ID,\n\t\t\tError: c.crt.Remove(ctx, comp.ID+\".\"+stack.ID),\n\t\t}\n\t\tar = append(ar, r)\n\t}\n\n\treturn ar\n}", "func Clean() {\n\tmg.Deps(DeleteLighthouseReports, WebApp.Prune)\n}", "func (ap *ActivePipelines) RemoveDeletedPipelines(existingPipelineNames []string) {\n\tvar deletedPipelineIndices []int\n\tfor index, pipeline := range ap.GetAll() {\n\t\tfound := false\n\t\tfor _, name := range existingPipelineNames {\n\t\t\tif pipeline.Name == name {\n\t\t\t\tfound = true\n\t\t\t\tbreak\n\t\t\t}\n\t\t}\n\t\tif !found {\n\t\t\tdeletedPipelineIndices = append(deletedPipelineIndices, index)\n\t\t}\n\t}\n\tfor _, idx := range deletedPipelineIndices {\n\t\tif err := ap.Remove(idx); err != nil {\n\t\t\tgaia.Cfg.Logger.Error(\"failed to remove pipeline with index\", \"index\", idx, \"error\", err.Error())\n\t\t\tbreak\n\t\t}\n\t}\n}", "func destroyObjects(p *pkcs11.Ctx, session pkcs11.SessionHandle, handles []pkcs11.ObjectHandle) error {\n\tfor _, o := range handles {\n\t\terr := p.DestroyObject(session, o)\n\t\tif err != nil {\n\t\t\treturn fmt.Errorf(\"Error destroying object %d: %v\", o, err)\n\t\t}\n\t}\n\treturn nil\n}", "func appFinalizer(a *Application) {\n\truntime.SetFinalizer(a, func(a *Application) { gobject.Unref(a) })\n}", "func (rl *RayLine) Dispose() {\n\tgl := rl.window.OpenGL()\n\n\tgl.DeleteVertexArrays([]uint32{rl.glVAO})\n\tgl.DeleteProgram(rl.shaderProgram)\n}", "func DeleteProgram(program Uint) {\n\tcprogram, _ := (C.GLuint)(program), cgoAllocsUnknown\n\tC.glDeleteProgram(cprogram)\n}", "func (b *Builder) clearMesh() {\n\tfor _, key := range b.localInstances.Keys() {\n\t\tb.localInstances.Delete(key)\n\t}\n}", "func (program Program) Delete() {\n\tgl.DeleteProgram(uint32(program))\n}", "func (p *filteringPodListProcessor) CleanUp() {\n\tfor _, transform := range p.transforms {\n\t\ttransform.CleanUp()\n\t}\n\tfor _, filter := range p.filters {\n\t\tfilter.CleanUp()\n\t}\n}", "func (a *PipelineControllerApiService) DeletePipelineUsingDELETE1(ctx _context.Context, id string) apiDeletePipelineUsingDELETE1Request {\n\treturn apiDeletePipelineUsingDELETE1Request{\n\t\tapiService: a,\n\t\tctx: ctx,\n\t\tid: id,\n\t}\n}", "func Clean(ctx context.Context, r runner.Runner) error {\n\titems := []struct {\n\t\tgetCmd, deleteCmd []string\n\t\twarning string\n\t}{{\n\t\tgetCmd: []string{\"docker\", \"ps\", \"-a\", \"-q\", \"--filter\", \"name=step_[0-9]+|cloudbuild_|metadata\"},\n\t\tdeleteCmd: []string{\"docker\", \"rm\", \"-f\"},\n\t\twarning: \"Warning: there are left over step containers from a previous build, cleaning them.\",\n\t}, {\n\t\tgetCmd: []string{\"docker\", \"network\", \"ls\", \"-q\", \"--filter\", \"name=cloudbuild\"},\n\t\tdeleteCmd: []string{\"docker\", \"network\", \"rm\"},\n\t\twarning: \"Warning: a network is left over from a previous build, cleaning it.\",\n\t}, {\n\t\tgetCmd: []string{\"docker\", \"volume\", \"ls\", \"-q\", \"--filter\", \"name=homevol|cloudbuild_\"},\n\t\tdeleteCmd: []string{\"docker\", \"volume\", \"rm\"},\n\t\twarning: \"Warning: there are left over step volumes from a previous build, cleaning it.\",\n\t}}\n\n\tfor _, item := range items {\n\t\tvar output bytes.Buffer\n\t\tif err := r.Run(ctx, item.getCmd, nil, &output, os.Stderr, \"\"); err != nil {\n\t\t\treturn err\n\t\t}\n\n\t\tstr := strings.TrimSpace(output.String())\n\t\tif str == \"\" {\n\t\t\tcontinue\n\t\t}\n\t\tlog.Println(item.warning)\n\n\t\targs := strings.Split(str, \"\\n\")\n\t\tdeleteCmd := append(item.deleteCmd, args...)\n\t\tif err := r.Run(ctx, deleteCmd, nil, nil, os.Stderr, \"\"); err != nil {\n\t\t\treturn err\n\t\t}\n\t}\n\n\treturn nil\n}", "func (j *TrainingJob) deleteResources() error {\n\tfor _, r := range j.Replicas {\n\t\tif err := r.Delete(); err != nil {\n\t\t\treturn err\n\t\t}\n\t}\n\n\treturn nil\n}", "func (hb *Horsebase) destroy() error {\n\tvar err error\n\n\tfmt.Print(\"All data will be deleted, is it OK?[y/n] \")\n\n\tscanner := bufio.NewScanner(os.Stdin)\n\tfor scanner.Scan() {\n\t\tinput := scanner.Text()\n\n\t\tswitch input {\n\t\tcase \"y\", \"Y\":\n\t\t\thb.DbInfo, err = hb.DbInfo.New()\n\t\t\tif err != nil {\n\t\t\t\tPrintError(hb.Stderr, \"%s\", err)\n\t\t\t\treturn err\n\t\t\t}\n\t\t\tdefer hb.DbInfo.db.Close()\n\n\t\t\tif err = hb.DbInfo.DropDB(); err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\t\t\tbreak\n\n\t\tcase \"n\", \"N\":\n\t\t\treturn err\n\n\t\tdefault:\n\t\t\treturn err\n\t\t}\n\n\t}\n\treturn err\n}", "func (e *dockerEngine) clean() {\n\tsss := map[string]map[string]attribute{}\n\tif e.LoadStats(&sss) {\n\t\tfor sn, instances := range sss {\n\t\t\tfor in, instance := range instances {\n\t\t\t\tid := instance.Container.ID\n\t\t\t\tif id == \"\" {\n\t\t\t\t\te.log.Warnf(\"[%s][%s] container id not found, maybe running mode changed\", sn, in)\n\t\t\t\t\tcontinue\n\t\t\t\t}\n\t\t\t\terr := e.stopContainer(id)\n\t\t\t\tif err != nil {\n\t\t\t\t\te.log.Warnf(\"[%s][%s] failed to stop the old container (%s)\", sn, in, id[:12])\n\t\t\t\t} else {\n\t\t\t\t\te.log.Infof(\"[%s][%s] old container (%s) stopped\", sn, in, id[:12])\n\t\t\t\t}\n\t\t\t\terr = e.removeContainer(id)\n\t\t\t\tif err != nil {\n\t\t\t\t\te.log.Warnf(\"[%s][%s] failed to remove the old container (%s)\", sn, in, id[:12])\n\t\t\t\t} else {\n\t\t\t\t\te.log.Infof(\"[%s][%s] old container (%s) removed\", sn, in, id[:12])\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n}", "func (cp *ArchConveyorPacker) CleanUp() {\n\tos.RemoveAll(cp.b.Path)\n}", "func (set HwlocCPUSet) Destroy() {\n\tset.BitMap.Destroy()\n}", "func (tr *trooper) trash() {\n\tfor _, b := range tr.bits {\n\t\tb.trash()\n\t}\n\tif tr.center != nil {\n\t\ttr.center.Dispose()\n\t\ttr.center = nil\n\t}\n\tif tr.neo != nil {\n\t\ttr.neo.Dispose()\n\t}\n\ttr.neo = nil\n}", "func cleanup(queue webhook.MessagingQueue) {\n\n\tsigChan := make(chan os.Signal)\n\tsignal.Notify(sigChan, syscall.SIGINT, syscall.SIGKILL, syscall.SIGTERM, syscall.SIGTSTP)\n\t<-sigChan\n\n\tfmt.Println(\"\\nReceived an interrupt, stopping services...\\n\")\n\tqueue.Close()\n\tiris.Close()\n\n\truntime.GC()\n\tos.Exit(0)\n\n}", "func Cleanup(monitors []models.Application) {\n\tapps := database.Applications()\n\tfor i := range apps {\n\t\tapp := apps[i]\n\n\t\tif contains(app.Name, monitors) == false {\n\t\t\tdatabase.DeleteApplication(app.ID)\n\t\t\tdatabase.DeleteChecks(app.ID)\n\t\t}\n\t}\n}", "func Teardown() {\n\tfmt.Println(\"====== Clean kubernetes testing pod ======\")\n\tres, err := kubeclient.ExecKubectl(\"kubectl delete pod -l app=nsenter\")\n\tfmt.Println(res)\n\tif err != nil {\n\t\tfmt.Println(\"Error: \" + err.Error())\n\t}\n}", "func cleanUp(topology C.hwloc_topology_t) {\n\tif topology != nil {\n\t\tC.hwloc_topology_destroy(topology)\n\t}\n}", "func (t *TestLab) Clear() error {\n\tif t.deployments == nil {\n\t\tlogrus.Info(\"no existing deployment to tear down\")\n\t\treturn nil\n\t}\n\n\tfor _, deployment := range t.deployments {\n\t\tevalID, _, err := t.nomad.Jobs().Deregister(deployment, false, nil)\n\t\tif err != nil {\n\t\t\tlogrus.Errorf(\"deregistering deployment: %s\", err)\n\t\t} else {\n\t\t\tlogrus.Infof(\"deregistered job %s in evaluation %s\", deployment, evalID)\n\t\t}\n\t}\n\n\treturn os.Remove(t.deploymentPath)\n}", "func (s *JobApiTestSuite) cleanUp() {\n\ttest.DeleteAllRuns(s.runClient, s.resourceNamespace, s.T())\n\ttest.DeleteAllJobs(s.jobClient, s.resourceNamespace, s.T())\n\ttest.DeleteAllPipelines(s.pipelineClient, s.T())\n\ttest.DeleteAllExperiments(s.experimentClient, s.resourceNamespace, s.T())\n}", "func (r *HelmRepositoryReconciler) gc(repository sourcev1.HelmRepository) error {\n\tif repository.Status.Artifact != nil {\n\t\treturn r.Storage.RemoveAllButCurrent(*repository.Status.Artifact)\n\t}\n\treturn nil\n}", "func finalizer(a *CasbinMenuAdapter) {\n}", "func deleteAllHelm(root, profile string) error {\n\tparser := yaml.NewParser()\n\terr := parser.Parse(profile)\n\tif err != nil {\n\t\tlog.Fatalf(\"parser.Parse profile error: err=%s\", err)\n\t}\n\texec := exec.NewExec(root)\n\tfor _, su := range parser.Profile.ServiceUnits {\n\t\tfor _, app := range su.Applications {\n\t\t\tshell := exec.Delete(app.Name)\n\t\t\tlog.Infof(\"DeleteAllCharts: root=%s, profile=%s, su=%s, app=%s, shell=%v\",\n\t\t\t\troot, profile, su.Name, app.Name, shell)\n\t\t\terr := exec.Do(shell)\n\t\t\tif err != nil {\n\t\t\t\tlog.Errorf(\"Helm delete error: err=%s\", err)\n\t\t\t}\n\t\t}\n\t}\n\treturn nil\n\n}", "func Free(proc *SProcess) {\n\n\t// close any open files\n\tfor _, file := range proc.files {\n\t\tfile.Close()\n\t}\n\n\t// delete the directory\n\tos.RemoveAll(\"/system/process/\" + strconv.Itoa(proc.pid))\n\n\tdelete(processes, proc.pid)\n}", "func (w *worker) deregister() {\n\tw.Lock()\n\tid := w.id\n\teid := w.eid\n\tw.active = false\n\tw.Unlock()\n\tactivePipelines.Lock()\n\tdelete(activePipelines.i, id)\n\tdelete(activePipelines.eids, eid)\n\tactivePipelines.Unlock()\n}", "func (h *TunnelHandler) Clean() {\n\th.mu.Lock()\n\tremoved := make([]string, 0, len(h.tunnels))\n\tfor id, tunnel := range h.tunnels {\n\t\tselect {\n\t\tcase <-tunnel.chDone:\n\t\t\tremoved = append(removed, id)\n\t\tdefault:\n\t\t}\n\t}\n\th.mu.Unlock()\n\n\tfor _, id := range removed {\n\t\th.remove(id)\n\t}\n}", "func (t *SubprocessTest) TearDown() {\n\terr := t.destroy()\n\tif err != nil {\n\t\tpanic(err)\n\t}\n}", "func (t *MorphTargets) Cleanup(a *app.App) {}", "func (c *common) clean() error {\n\tvar err error\n\n\tif len(c.flags.clean) == 0 {\n\t\treturn nil\n\t}\n\n\targs := append(c.flags.global, c.flags.clean...)\n\n\terr = shared.RunCommand(c.ctx, nil, nil, c.commands.clean, args...)\n\tif err != nil {\n\t\treturn err\n\t}\n\n\tif c.hooks.clean != nil {\n\t\terr = c.hooks.clean()\n\t}\n\n\treturn err\n}", "func DeleteProgram(program uint32) {\n\tsyscall.Syscall(gpDeleteProgram, 1, uintptr(program), 0, 0)\n}", "func (a *PipelineControllerApiService) DeletePipelineUsingDELETE(ctx context.Context, application string, pipelineName string) ( *http.Response, error) {\n\tvar (\n\t\tlocalVarHttpMethod = strings.ToUpper(\"Delete\")\n\t\tlocalVarPostBody interface{}\n\t\tlocalVarFileName string\n\t\tlocalVarFileBytes []byte\n\t)\n\n\t// create path and map variables\n\tlocalVarPath := a.client.cfg.BasePath + \"/pipelines/{application}/{pipelineName}\"\n\tlocalVarPath = strings.Replace(localVarPath, \"{\"+\"application\"+\"}\", fmt.Sprintf(\"%v\", application), -1)\n\tlocalVarPath = strings.Replace(localVarPath, \"{\"+\"pipelineName\"+\"}\", fmt.Sprintf(\"%v\", pipelineName), -1)\n\n\tlocalVarHeaderParams := make(map[string]string)\n\tlocalVarQueryParams := url.Values{}\n\tlocalVarFormParams := url.Values{}\n\n\n\t// to determine the Content-Type header\n\tlocalVarHttpContentTypes := []string{ \"application/json\", }\n\n\t// set Content-Type header\n\tlocalVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes)\n\tif localVarHttpContentType != \"\" {\n\t\tlocalVarHeaderParams[\"Content-Type\"] = localVarHttpContentType\n\t}\n\n\t// to determine the Accept header\n\tlocalVarHttpHeaderAccepts := []string{\n\t\t\"*/*\",\n\t\t}\n\n\t// set Accept header\n\tlocalVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts)\n\tif localVarHttpHeaderAccept != \"\" {\n\t\tlocalVarHeaderParams[\"Accept\"] = localVarHttpHeaderAccept\n\t}\n\tr, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\n\tlocalVarHttpResponse, err := a.client.callAPI(r)\n\tif err != nil || localVarHttpResponse == nil {\n\t\treturn localVarHttpResponse, err\n\t}\n\tdefer localVarHttpResponse.Body.Close()\n\tif localVarHttpResponse.StatusCode >= 300 {\n\t\tbodyBytes, _ := ioutil.ReadAll(localVarHttpResponse.Body)\n\t\treturn localVarHttpResponse, reportError(\"Status: %v, Body: %s\", localVarHttpResponse.Status, bodyBytes)\n\t}\n\n\treturn localVarHttpResponse, err\n}", "func (o *operator) GC(lastTry, wfrDeletion bool) error {\n\twg := sync.WaitGroup{}\n\tallPodsFinished := true\n\t// For each pod created, delete it.\n\tfor stg, status := range o.wfr.Status.Stages {\n\t\t// For non-terminated stage, update status to cancelled.\n\t\tif status.Status.Phase == v1alpha1.StatusPending ||\n\t\t\tstatus.Status.Phase == v1alpha1.StatusRunning ||\n\t\t\tstatus.Status.Phase == v1alpha1.StatusWaiting {\n\t\t\to.UpdateStageStatus(stg, &v1alpha1.Status{\n\t\t\t\tPhase: v1alpha1.StatusCancelled,\n\t\t\t\tReason: \"GC\",\n\t\t\t\tLastTransitionTime: metav1.Time{Time: time.Now()},\n\t\t\t})\n\t\t}\n\n\t\tif status.Pod == nil {\n\t\t\tlog.WithField(\"wfr\", o.wfr.Name).\n\t\t\t\tWithField(\"stg\", stg).\n\t\t\t\tWarn(\"Pod information is missing, can't clean the pod.\")\n\t\t\tcontinue\n\t\t}\n\t\terr := o.clusterClient.CoreV1().Pods(status.Pod.Namespace).Delete(context.TODO(), status.Pod.Name, metav1.DeleteOptions{})\n\t\tif err != nil {\n\t\t\t// If the pod not exist, just skip it without complain.\n\t\t\tif errors.IsNotFound(err) {\n\t\t\t\tcontinue\n\t\t\t}\n\t\t\tlog.WithField(\"wfr\", o.wfr.Name).\n\t\t\t\tWithField(\"stg\", stg).\n\t\t\t\tWithField(\"pod\", status.Pod.Name).\n\t\t\t\tWarn(\"Delete pod error: \", err)\n\n\t\t\tif !wfrDeletion {\n\t\t\t\to.recorder.Eventf(o.wfr, corev1.EventTypeWarning, \"GC\", \"Delete pod '%s' error: %v\", status.Pod.Name, err)\n\t\t\t}\n\t\t} else {\n\t\t\tlog.WithField(\"ns\", status.Pod.Namespace).WithField(\"pod\", status.Pod.Name).Info(\"Start to delete pod\")\n\n\t\t\twg.Add(1)\n\t\t\tgo func(namespace, podName string) {\n\t\t\t\tdefer wg.Done()\n\n\t\t\t\ttimeout := time.After(5 * time.Minute)\n\t\t\t\tticker := time.NewTicker(5 * time.Second)\n\t\t\t\tdefer ticker.Stop()\n\t\t\t\tfor {\n\t\t\t\t\tselect {\n\t\t\t\t\tcase <-timeout:\n\t\t\t\t\t\tallPodsFinished = false\n\t\t\t\t\t\tlog.WithField(\"ns\", namespace).WithField(\"pod\", podName).Warn(\"Pod deletion timeout\")\n\t\t\t\t\t\treturn\n\t\t\t\t\tcase <-ticker.C:\n\t\t\t\t\t\t_, err := o.clusterClient.CoreV1().Pods(namespace).Get(context.TODO(), podName, metav1.GetOptions{})\n\t\t\t\t\t\tif err != nil && errors.IsNotFound(err) {\n\t\t\t\t\t\t\tlog.WithField(\"ns\", namespace).WithField(\"pod\", podName).Info(\"Pod deleted\")\n\t\t\t\t\t\t\treturn\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}(status.Pod.Namespace, status.Pod.Name)\n\t\t}\n\t}\n\n\t// Wait all workflowRun related workload pods deleting completed, then start gc pod to clean data on PV.\n\t// Otherwise, if the path which is used by workload pods in the PV is deleted before workload pods deletion,\n\t// the pod deletion process will get stuck on Terminating status.\n\twg.Wait()\n\n\t// If there are pods not finished and this is not the last gc try process, we will not start gc pod to clean\n\t// data on PV. The last gc try process will ensure data could be cleaned.\n\tif !allPodsFinished && !lastTry {\n\t\tif !wfrDeletion {\n\t\t\to.recorder.Eventf(o.wfr, corev1.EventTypeWarning, \"GC\", \"There are stage pods not Finished\")\n\t\t}\n\t\treturn nil\n\t}\n\n\t// Get execution context of the WorkflowRun, namespace and PVC are defined in the context.\n\texecutionContext := GetExecutionContext(o.wfr)\n\n\t// Create a gc pod to clean data on PV if PVC is configured.\n\tif executionContext.PVC != \"\" {\n\t\tgcPod := &corev1.Pod{\n\t\t\tObjectMeta: metav1.ObjectMeta{\n\t\t\t\tName: GCPodName(o.wfr.Name),\n\t\t\t\tNamespace: executionContext.Namespace,\n\t\t\t\tLabels: map[string]string{\n\t\t\t\t\tmeta.LabelProjectName: common.ResolveProjectName(*o.wfr),\n\t\t\t\t\tmeta.LabelWorkflowName: common.ResolveWorkflowName(*o.wfr),\n\t\t\t\t\tmeta.LabelWorkflowRunName: o.wfr.Name,\n\t\t\t\t\tmeta.LabelPodKind: meta.PodKindGC.String(),\n\t\t\t\t\tmeta.LabelPodCreatedBy: meta.CycloneCreator,\n\t\t\t\t},\n\t\t\t\tAnnotations: map[string]string{\n\t\t\t\t\tmeta.AnnotationIstioInject: meta.AnnotationValueFalse,\n\t\t\t\t},\n\t\t\t},\n\t\t\tSpec: corev1.PodSpec{\n\t\t\t\tRestartPolicy: corev1.RestartPolicyNever,\n\t\t\t\tContainers: []corev1.Container{\n\t\t\t\t\t{\n\t\t\t\t\t\tName: common.GCContainerName,\n\t\t\t\t\t\tImage: controller.Config.Images[controller.GCImage],\n\t\t\t\t\t\tCommand: []string{\"rm\", \"-rf\", common.GCDataPath + \"/\" + o.wfr.Name},\n\t\t\t\t\t\tVolumeMounts: []corev1.VolumeMount{\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tName: common.DefaultPvVolumeName,\n\t\t\t\t\t\t\t\tMountPath: common.GCDataPath,\n\t\t\t\t\t\t\t\tSubPath: common.WorkflowRunsPath(),\n\t\t\t\t\t\t\t},\n\t\t\t\t\t\t},\n\t\t\t\t\t\tResources: controller.Config.GC.ResourceRequirements,\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t\tVolumes: []corev1.Volume{\n\t\t\t\t\t{\n\t\t\t\t\t\tName: common.DefaultPvVolumeName,\n\t\t\t\t\t\tVolumeSource: corev1.VolumeSource{\n\t\t\t\t\t\t\tPersistentVolumeClaim: &corev1.PersistentVolumeClaimVolumeSource{\n\t\t\t\t\t\t\t\tClaimName: executionContext.PVC,\n\t\t\t\t\t\t\t\tReadOnly: false,\n\t\t\t\t\t\t\t},\n\t\t\t\t\t\t},\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t},\n\t\t}\n\n\t\t// If controller instance name is set, add label to the pod created.\n\t\tif instance := os.Getenv(ccommon.ControllerInstanceEnvName); len(instance) != 0 {\n\t\t\tgcPod.ObjectMeta.Labels[meta.LabelControllerInstance] = instance\n\t\t}\n\n\t\t_, err := o.clusterClient.CoreV1().Pods(executionContext.Namespace).Create(context.TODO(), gcPod, metav1.CreateOptions{})\n\t\tif err != nil {\n\t\t\tlog.WithField(\"wfr\", o.wfr.Name).Warn(\"Create GC pod error: \", err)\n\t\t\tif !lastTry {\n\t\t\t\treturn err\n\t\t\t}\n\n\t\t\tif !wfrDeletion {\n\t\t\t\to.recorder.Eventf(o.wfr, corev1.EventTypeWarning, \"GC\", \"Create GC pod error: %v\", err)\n\t\t\t}\n\t\t}\n\t}\n\n\tif !wfrDeletion {\n\t\to.recorder.Event(o.wfr, corev1.EventTypeNormal, \"GC\", \"GC is performed succeed.\")\n\n\t\to.wfr.Status.Cleaned = true\n\t\terr := o.Update()\n\t\tif err != nil {\n\t\t\tlog.WithField(\"wfr\", o.wfr.Name).Warn(\"Update wfr error: \", err)\n\t\t}\n\t}\n\n\treturn nil\n}", "func (sb *SkyBox) Dispose() {\n\tgl := sb.window.OpenGL()\n\n\tgl.DeleteVertexArrays([]uint32{sb.glVAO})\n\tgl.DeleteProgram(sb.shaderProgram)\n}", "func cleanup() {\n\tos.Remove(dummyPath)\n}", "func destroyKnative() {\n\n\t//Make command options for Knative Setup\n\tco := utils.NewCommandOptions()\n\n\t//Install Openshift Serveless and Knative Serving\n\tco.Commands = append(co.Commands, \"https://raw.githubusercontent.com/redhat-iot/iot-dev/master/yamls/knative/setup/knative-eventing.yaml\")\n\n\tco.Commands = append(co.Commands, \"https://raw.githubusercontent.com/redhat-iot/iot-dev/master/yamls/knative/setup/knative-serving.yaml\")\n\tIOStreams, _, out, _ := genericclioptions.NewTestIOStreams()\n\n\tco.SwitchContext(\"knative-eventing\")\n\n\tlog.Info(\"Remove Openshift Serverless Operator and Knative Serving\")\n\tfor commandNumber, command := range co.Commands {\n\t\tif commandNumber == 1 {\n\t\t\tco.SwitchContext(\"knative-serving\")\n\t\t}\n\t\tcmd := delete.NewCmdDelete(co.CurrentFactory, IOStreams)\n\t\tcmd.Flags().Set(\"filename\", command)\n\t\tcmd.Run(cmd, []string{})\n\t\tlog.Info(out.String())\n\t\tout.Reset()\n\t\t//Allow time for Operator to distribute to all namespaces\n\t}\n\n\t/*\n\n\t\tcurrentCSV, err := exec.Command(\"bash\", \"-c\", \"./oc get subscription serverless-operator -n openshift-operators -o jsonpath='{.status.currentCSV}'\").Output()\n\t\terr = exec.Command(\"./oc\", \"delete\", \"subscription\", \"serverless-operator\", \"-n\", \"openshift-operators\").Run()\n\t\tif err != nil {\n\t\t\t//Ignore Resource Not found error and continue, but still notify the user\n\t\t\tlog.Println(err)\n\t\t}\n\t\terr = exec.Command(\"./oc\", \"delete\", \"clusterserviceversion\", string(currentCSV), \"-n\", \"openshift-operators\").Run()\n\t\tif err != nil {\n\t\t\t//Igonore Resource Not found error and continue, but still notify the user\n\t\t\tlog.Println(err)\n\t\t}\n\t\tos.Remove(\"oc\")\n\t*/\n\n}", "func (r *ReconcileGitTrack) deleteResources(leftovers map[string]farosv1alpha1.GitTrackObjectInterface) error {\n\tif len(leftovers) > 0 {\n\t\tr.log.V(0).Info(\"Found leftover resources to clean up\", \"leftover resources\", string(len(leftovers)))\n\t}\n\tfor name, obj := range leftovers {\n\t\tif err := r.Delete(context.TODO(), obj); err != nil {\n\t\t\treturn fmt.Errorf(\"failed to delete child for '%s': '%s'\", name, err)\n\t\t}\n\t\tr.log.V(0).Info(\"Child deleted\", \"child name\", name)\n\t}\n\treturn nil\n}", "func (t *AudioDoppler) Cleanup(a *app.App) {}", "func cleanUp() {\n\tc := make(chan os.Signal, 1)\n\tsignal.Notify(c, os.Interrupt)\n\tsignal.Notify(c, syscall.SIGTERM)\n\tsignal.Notify(c, syscall.SIGKILL)\n\tgo func() {\n\t\t<-c\n\t\t_ = pool.Close()\n\t\tos.Exit(0)\n\t}()\n}", "func finalizer(w *Worker) {\n\tlog.Printf(\"Destroy worker %v\\n\", w.ID)\n}", "func cleanupAssets(ctx context.Context, collection *kabanerov1alpha1.Collection, c client.Client, reqLogger logr.Logger) error {\n\townerIsController := false\n\tassetOwner := metav1.OwnerReference{\n\t\tAPIVersion: collection.APIVersion,\n\t\tKind: collection.Kind,\n\t\tName: collection.Name,\n\t\tUID: collection.UID,\n\t\tController: &ownerIsController,\n\t}\n\n\t// Run thru the status and delete everything.... we're just going to try once since it's unlikely\n\t// that anything that goes wrong here would be rectified by a retry.\n\tfor _, version := range collection.Status.Versions {\n\t\tfor _, pipeline := range version.Pipelines {\n\t\t\tfor _, asset := range pipeline.ActiveAssets {\n\t\t\t\t// Old assets may not have a namespace set - correct that now.\n\t\t\t\tif len(asset.Namespace) == 0 {\n\t\t\t\t\tasset.Namespace = collection.GetNamespace()\n\t\t\t\t}\n\n\t\t\t\tdeleteAsset(c, asset, assetOwner)\n\t\t\t}\n\t\t}\n\t}\n\n\treturn nil\n}", "func (g *Game) destroy() {\n\tg.trex.Destroy()\n\tg.cactus.Destroy()\n\tg.clouds.Destroy()\n\tg.ground.Destroy()\n}", "func (setup *SimpleTestSetup) TearDown() {\n\tsetup.harnessPool.DisposeAll()\n\tsetup.harnessWalletPool.DisposeAll()\n\t//setup.nodeGoBuilder.Dispose()\n\tsetup.WorkingDir.Dispose()\n}", "func (s *Scene) Delete() {\n\ts.propOctree = nil\n\ts.props = nil\n\n\ts.bodyPool = nil\n\ts.dynamicBodies = nil\n\n\ts.firstSBConstraint = nil\n\ts.lastSBConstraint = nil\n\n\ts.firstDBConstraint = nil\n\ts.lastDBConstraint = nil\n}", "func (c *Canary) CleanPreviousCanaryResources(region schemas.RegionConfig, completeCanary bool) error {\n\tclient, err := selectClientFromList(c.AWSClients, region.Region)\n\tif err != nil {\n\t\treturn err\n\t}\n\n\tprefix := tool.BuildPrefixName(c.AwsConfig.Name, c.Stack.Env, region.Region)\n\n\tasgList, err := client.EC2Service.GetAllMatchingAutoscalingGroupsWithPrefix(prefix)\n\tif err != nil {\n\t\treturn err\n\t}\n\n\tfor _, asg := range asgList {\n\t\tif (completeCanary && *asg.AutoScalingGroupName == c.LatestAsg[region.Region]) || !tool.IsStringInArray(*asg.AutoScalingGroupName, c.PrevAsgs[region.Region]) {\n\t\t\tcontinue\n\t\t}\n\n\t\tc.Logger.Debugf(\"[Resizing] target autoscaling group : %s\", *asg.AutoScalingGroupName)\n\t\tif err := c.ResizingAutoScalingGroupCount(client, *asg.AutoScalingGroupName, 0); err != nil {\n\t\t\tc.Logger.Errorf(err.Error())\n\t\t}\n\t\tc.Logger.Debugf(\"Resizing autoscaling group finished: %s\", *asg.AutoScalingGroupName)\n\n\t\tfor _, tg := range asg.TargetGroupARNs {\n\t\t\tif tool.IsCanaryTargetGroupArn(*tg, region.Region) {\n\t\t\t\tc.Logger.Debugf(\"Try to delete target group: %s\", *tg)\n\t\t\t\tif err := client.ELBV2Service.DeleteTargetGroup(tg); err != nil {\n\t\t\t\t\treturn err\n\t\t\t\t}\n\t\t\t\tc.Logger.Debugf(\"Deleted target group: %s\", *tg)\n\t\t\t}\n\t\t}\n\t}\n\n\tc.Logger.Debugf(\"Start to delete load balancer and security group for canary\")\n\tif completeCanary {\n\t\tif err := c.DeleteLoadBalancer(region); err != nil {\n\t\t\treturn err\n\t\t}\n\n\t\tif err := c.LoadBalancerDeletionChecking(region); err != nil {\n\t\t\treturn err\n\t\t}\n\n\t\tif err := c.DeleteEC2IngressRules(region); err != nil {\n\t\t\treturn err\n\t\t}\n\n\t\tif err := c.DeleteEC2SecurityGroup(region); err != nil {\n\t\t\treturn err\n\t\t}\n\n\t\tif err := c.DeleteLBSecurityGroup(region); err != nil {\n\t\t\treturn err\n\t\t}\n\t}\n\n\treturn nil\n}", "func delPkgs(newPath string, oldPath string, patchPath string) (err error) {\n\tif err = deleteFile(newPath); err != nil {\n\t\tlog.Error(errFormat, \"delPkgs\", \"NewPath\", err)\n\t\treturn\n\t}\n\tif err = deleteFile(oldPath); err != nil {\n\t\tlog.Error(errFormat, \"delPkgs\", \"oldPath\", err)\n\t\treturn\n\t}\n\tif err = deleteFile(patchPath); err != nil {\n\t\tlog.Error(errFormat, \"delPkgs\", \"patchPath\", err)\n\t}\n\treturn\n}", "func (px *Paxos) Kill() {\n\tpx.dead = true\n\tif px.l != nil {\n\t\tpx.l.Close()\n\t}\n}", "func (px *Paxos) Kill() {\n\tpx.dead = true\n\tif px.l != nil {\n\t\tpx.l.Close()\n\t}\n}", "func (px *Paxos) Kill() {\n\tpx.dead = true\n\tif px.l != nil {\n\t\tpx.l.Close()\n\t}\n}", "func (px *Paxos) Kill() {\n\tpx.dead = true\n\tif px.l != nil {\n\t\tpx.l.Close()\n\t}\n}", "func cleanup(t *testing.T, namespace string) {\n\targs := \"delete\"\n\tif namespace != \"\" {\n\t\targs += \" -n \" + namespace\n\t}\n\n\terr, stdout, stderr := runSonobuoyCommand(t, args)\n\n\tif err != nil {\n\t\tt.Logf(\"Error encountered during cleanup: %q\\n\", err)\n\t\tt.Log(stdout.String())\n\t\tt.Log(stderr.String())\n\t}\n}" ]
[ "0.68904364", "0.68334776", "0.62471974", "0.61384374", "0.59532994", "0.58873624", "0.5883622", "0.5878463", "0.58721143", "0.5835099", "0.57765216", "0.57669806", "0.5753911", "0.5714293", "0.5702303", "0.5634036", "0.55995226", "0.55718833", "0.5539132", "0.5535721", "0.54864126", "0.54635155", "0.5456606", "0.54547405", "0.5452449", "0.5433982", "0.5397652", "0.5397652", "0.5382126", "0.5369491", "0.5358454", "0.534985", "0.53407216", "0.5326836", "0.5316753", "0.5303052", "0.5286891", "0.5276898", "0.52707875", "0.5260288", "0.5258742", "0.52510816", "0.52225226", "0.5212078", "0.5210791", "0.52056324", "0.5192633", "0.51905775", "0.51530457", "0.514809", "0.51478744", "0.51414716", "0.5123139", "0.511971", "0.51069385", "0.5104157", "0.5084554", "0.50748426", "0.507283", "0.5064365", "0.5059805", "0.50442946", "0.5029754", "0.5020059", "0.501367", "0.50053877", "0.5004329", "0.4994983", "0.49899328", "0.49828506", "0.49770942", "0.4976497", "0.49760097", "0.49597275", "0.49586317", "0.49583188", "0.49568775", "0.49562204", "0.4954409", "0.49521014", "0.49481297", "0.4947314", "0.4943356", "0.49371165", "0.49343893", "0.4932765", "0.4932106", "0.49316803", "0.4929538", "0.49244794", "0.49230734", "0.49211714", "0.49207804", "0.4912364", "0.4908854", "0.4908854", "0.4908854", "0.4908854", "0.4904715" ]
0.67379576
3
delete named query objects
func DeleteQueries(n int32, ids *uint32) { C.glowDeleteQueries(gpDeleteQueries, (C.GLsizei)(n), (*C.GLuint)(unsafe.Pointer(ids))) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func (api *OsctrlAPI) DeleteQuery(env, identifier string) error {\n\treturn nil\n}", "func (c *Client) DeleteByQuery(query interface{}, indexList []string, typeList []string, extraArgs url.Values) (*Response, error) {\n\tversion, err := c.Version()\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\tif version > \"2\" && version < \"5\" {\n\t\treturn nil, errors.New(\"ElasticSearch 2.x does not support delete by query\")\n\t}\n\n\tr := Request{\n\t\tQuery: query,\n\t\tIndexList: indexList,\n\t\tTypeList: typeList,\n\t\tMethod: \"DELETE\",\n\t\tAPI: \"_query\",\n\t\tExtraArgs: extraArgs,\n\t}\n\n\tif version > \"5\" {\n\t\tr.API = \"_delete_by_query\"\n\t\tr.Method = \"POST\"\n\t}\n\n\treturn c.Do(&r)\n}", "func (b *QueryBuilder) Delete() {\n}", "func (q jetQuery) DeleteAll() error {\n\tif q.Query == nil {\n\t\treturn errors.New(\"models: no jetQuery provided for delete all\")\n\t}\n\n\tqueries.SetDelete(q.Query)\n\n\t_, err := q.Query.Exec()\n\tif err != nil {\n\t\treturn errors.Wrap(err, \"models: unable to delete all from jets\")\n\t}\n\n\treturn nil\n}", "func deleteQueryOptions(c *clients.Client, name string, response handle.ResponseHandle) error {\n\treq, err := util.BuildRequestFromHandle(c, \"DELETE\", \"/config/query/\"+name, nil)\n\tif err != nil {\n\t\treturn err\n\t}\n\treturn util.Execute(c, req, response)\n}", "func (s *HTTPServer) preparedQueryDelete(id string, resp http.ResponseWriter, req *http.Request) (interface{}, error) {\n\targs := structs.PreparedQueryRequest{\n\t\tOp: structs.PreparedQueryDelete,\n\t\tQuery: &structs.PreparedQuery{\n\t\t\tID: id,\n\t\t},\n\t}\n\ts.parseDC(req, &args.Datacenter)\n\ts.parseToken(req, &args.Token)\n\n\tvar reply string\n\tif err := s.agent.RPC(\"PreparedQuery.Apply\", &args, &reply); err != nil {\n\t\treturn nil, err\n\t}\n\treturn nil, nil\n}", "func ExampleDelete() {\n\tuser := q.T(\"user\")\n\tdel := q.Delete(user).Where(q.Eq(user.C(\"id\"), 1))\n\t// del := q.Delete().From(user).Where(q.Eq(user.C(\"id\"), 1)) // same\n\tfmt.Println(del)\n\n\t// Even in this case, the original name is used as a table and a column name\n\t// because Insert, Delete and Update aren't supporting \"AS\" syntax.\n\tu := q.T(\"user\", \"u\")\n\tfmt.Println(q.Delete(u).Where(q.Eq(u.C(\"id\", \"i\"), 1)))\n\t// Output:\n\t// DELETE FROM \"user\" WHERE \"id\" = ? [1]\n\t// DELETE FROM \"user\" WHERE \"id\" = ? [1]\n}", "func ExampleDelete_basic() {\n\tsql, vars := Delete().From(\"people\").Where(And(\n\t\tEqual{\"first_name\", \"Joe\"},\n\t\tEqual{\"last_name\", \"Blow\"},\n\t)).GetFullSQL()\n\n\tfmt.Println(sql, \",\", vars)\n\t// Output: DELETE FROM people WHERE (first_name = $1 AND last_name = $2) , [Joe Blow]\n}", "func deleteAllQueryOptions(c *clients.Client, response handle.ResponseHandle) error {\n\treq, err := util.BuildRequestFromHandle(c, \"DELETE\", \"/config/query\", nil)\n\tif err != nil {\n\t\treturn err\n\t}\n\treturn util.Execute(c, req, response)\n}", "func deleteEndpointByQuery(w http.ResponseWriter, r *http.Request, query elastic.Query, caller string) {\r\n\r\n\tclient, err := getElasticsearchClient()\r\n\tif err != nil {\r\n\t\tapi.LogError(api.DEBUG, err)\r\n\t\tfmt.Fprintf(w, api.HttpFailureMessage(\"Failed to initialized query. ERROR 0x40000012\"))\r\n\t\treturn\r\n\t}\r\n\r\n\tres, err := client.DeleteByQuery().\r\n\t\tIndex(config.ElasticIndex()).\r\n\t\tType(\"audit_type\").\r\n\t\tQuery(query).\r\n\t\tDo(context.Background())\r\n\r\n\tif err != nil {\r\n\t\tapi.HttpResponseReturn(w, r, \"failed\", err.Error(), nil)\r\n\t\treturn\r\n\t}\r\n\tapi.HttpResponseReturn(w, r, \"success\", \"Case/Endpoint deleted\", res)\r\n}", "func (c *HTTPClient) Delete(q *Query, timeout time.Duration) error {\n if q == nil {\n return fmt.Errorf(\"kairosdb: nil query passed\")\n }\n payload, err := json.Marshal(q)\n if err != nil {\n return fmt.Errorf(\"error unmarshalling query:%v :: %v\", q, err)\n }\n\n glog.Infof(\"deleting datapoints payload: %v\", string(payload))\n reader := ioutil.NopCloser(bytes.NewReader(payload))\n err = c.backend.Call(\"POST\", c.url+\"/api/v1/datapoints/delete\", reader,\n timeout, http.StatusNoContent, nil)\n if err != nil {\n return fmt.Errorf(\"error deleting datapoints for query: %v :: %v\",\n string(payload), err)\n }\n\n glog.Infof(\"datapoints deleted successfully for query: %+v\", q)\n return nil\n}", "func (q stockQuery) DeleteAll() error {\n\tif q.Query == nil {\n\t\treturn errors.New(\"models: no stockQuery provided for delete all\")\n\t}\n\n\tqueries.SetDelete(q.Query)\n\n\t_, err := q.Query.Exec()\n\tif err != nil {\n\t\treturn errors.Wrap(err, \"models: unable to delete all from stock\")\n\t}\n\n\treturn nil\n}", "func (q sourceQuery) DeleteAll() error {\n\tif q.Query == nil {\n\t\treturn errors.New(\"mdbmdbmodels: no sourceQuery provided for delete all\")\n\t}\n\n\tqueries.SetDelete(q.Query)\n\n\t_, err := q.Query.Exec()\n\tif err != nil {\n\t\treturn errors.Wrap(err, \"mdbmdbmodels: unable to delete all from sources\")\n\t}\n\n\treturn nil\n}", "func (c client) Delete(q Query) error {\n\treturn c.exec(q)\n}", "func (q cvtermsynonymQuery) DeleteAll() error {\n\tif q.Query == nil {\n\t\treturn errors.New(\"chado: no cvtermsynonymQuery provided for delete all\")\n\t}\n\n\tqueries.SetDelete(q.Query)\n\n\t_, err := q.Query.Exec()\n\tif err != nil {\n\t\treturn errors.Wrap(err, \"chado: unable to delete all from cvtermsynonym\")\n\t}\n\n\treturn nil\n}", "func (conn *Connection) Delete(query interface{}) error {\n\treturn conn.collection.Remove(query)\n}", "func (q phenotypepropQuery) DeleteAll() error {\n\tif q.Query == nil {\n\t\treturn errors.New(\"chado: no phenotypepropQuery provided for delete all\")\n\t}\n\n\tqueries.SetDelete(q.Query)\n\n\t_, err := q.Query.Exec()\n\tif err != nil {\n\t\treturn errors.Wrap(err, \"chado: unable to delete all from phenotypeprop\")\n\t}\n\n\treturn nil\n}", "func (q organismQuery) DeleteAll() error {\n\tif q.Query == nil {\n\t\treturn errors.New(\"chado: no organismQuery provided for delete all\")\n\t}\n\n\tqueries.SetDelete(q.Query)\n\n\t_, err := q.Query.Exec()\n\tif err != nil {\n\t\treturn errors.Wrap(err, \"chado: unable to delete all from organism\")\n\t}\n\n\treturn nil\n}", "func (q instrumentClassQuery) DeleteAll() error {\n\tif q.Query == nil {\n\t\treturn errors.New(\"models: no instrumentClassQuery provided for delete all\")\n\t}\n\n\tqueries.SetDelete(q.Query)\n\n\t_, err := q.Query.Exec()\n\tif err != nil {\n\t\treturn errors.Wrap(err, \"models: unable to delete all from instrument_class\")\n\t}\n\n\treturn nil\n}", "func del(w http.ResponseWriter, r *http.Request) {\n\tname := r.URL.Query().Get(\":name\")\n\tdelete(pets, name)\n}", "func (db *DB) DropQuery(name string) (err error) {\n\tif db.qm[name].isPrepared() {\n\t\terr = db.Pool.Deallocate(name)\n\t}\n\tmutex.Lock()\n\tdelete(db.qm, name)\n\tmutex.Unlock()\n\treturn\n}", "func DeleteAll(collection *mgo.Collection, query bson.M) bool {\n\tchangeInfo, err := collection.RemoveAll(query)\n\tfmt.Println(changeInfo)\n\treturn check(err)\n}", "func deleteAlbum(w http.ResponseWriter, r *http.Request) {\n\tw.Header().Set(\"Content-Type\",\"application/json\")\n\tparam := mux.Vars(r)\n\t//CQL Operation\n\tif err:= Session.Query(`DELETE FROM albumtable WHERE albname=? IF EXISTS;`,param[\"album\"]).Exec();err!=nil {\n\t\tfmt.Println(err)\n\t} else {\n\t\tfmt.Fprintf(w, \"Album deleted\")\n\t}\n}", "func DeletePerson(db *sql.DB) {}", "func (q braceletPhotoQuery) DeleteAll() error {\n\tif q.Query == nil {\n\t\treturn errors.New(\"models: no braceletPhotoQuery provided for delete all\")\n\t}\n\n\tqueries.SetDelete(q.Query)\n\n\t_, err := q.Query.Exec()\n\tif err != nil {\n\t\treturn errors.Wrap(err, \"models: unable to delete all from bracelet_photo\")\n\t}\n\n\treturn nil\n}", "func (q apiKeyQuery) DeleteAll() error {\n\tif q.Query == nil {\n\t\treturn errors.New(\"models: no apiKeyQuery provided for delete all\")\n\t}\n\n\tqueries.SetDelete(q.Query)\n\n\t_, err := q.Query.Exec()\n\tif err != nil {\n\t\treturn errors.Wrap(err, \"models: unable to delete all from api_keys\")\n\t}\n\n\treturn nil\n}", "func (d *Demo) DeleteAll(g *gom.Gom) {\n\ttoolkit.Println(\"===== Delete All =====\")\n\n\tvar err error\n\tif d.useParams {\n\t\t_, err = g.Set(&gom.SetParams{\n\t\t\tTableName: \"hero\",\n\t\t\tFilter: gom.EndWith(\"Name\", \"man\"),\n\t\t\tTimeout: 10,\n\t\t}).Cmd().DeleteAll()\n\t} else {\n\t\t_, err = g.Set(nil).Table(\"hero\").Timeout(10).Filter(gom.EndWith(\"Name\", \"man\")).Cmd().DeleteAll()\n\t}\n\n\tif err != nil {\n\t\ttoolkit.Println(err.Error())\n\t\treturn\n\t}\n}", "func (db *GeoDB) Delete(q *GeoQuery) error {\n\tconn := db.pool.Get()\n\tdefer conn.Close()\n\n\t_, err := conn.Do(\"ZREM\", q.Key, q.Member)\n\treturn err\n}", "func (q paymentObjectQuery) DeleteAll(ctx context.Context, exec boil.ContextExecutor) (int64, error) {\n\tif q.Query == nil {\n\t\treturn 0, errors.New(\"models: no paymentObjectQuery provided for delete all\")\n\t}\n\n\tqueries.SetDelete(q.Query)\n\n\tresult, err := q.Query.ExecContext(ctx, exec)\n\tif err != nil {\n\t\treturn 0, errors.Wrap(err, \"models: unable to delete all from payment_objects\")\n\t}\n\n\trowsAff, err := result.RowsAffected()\n\tif err != nil {\n\t\treturn 0, errors.Wrap(err, \"models: failed to get rows affected by deleteall for payment_objects\")\n\t}\n\n\treturn rowsAff, nil\n}", "func deleteEmp(id string) {\n fmt.Printf(\"Deleting Emp with id = %s\\n\", id)\n if err := Session.Query(\"DELETE FROM emps WHERE empid = ?\", id).Exec(); err != nil {\n fmt.Println(\"Error while deleting Emp\")\n fmt.Println(err)\n }\n}", "func TestDeleteSet(t *testing.T) {\n\ttests.ResetLog()\n\tdefer tests.DisplayLog()\n\n\tqsName := prefix + \"_basic\"\n\tqsBadName := prefix + \"_basic_advice\"\n\n\tconst fixture = \"basic.json\"\n\tset1, err := qfix.Get(fixture)\n\tif err != nil {\n\t\tt.Fatalf(\"\\t%s\\tShould load query record from file : %v\", tests.Failed, err)\n\t}\n\tt.Logf(\"\\t%s\\tShould load query record from file.\", tests.Success)\n\n\tdb, err := db.NewMGO(tests.Context, tests.TestSession)\n\tif err != nil {\n\t\tt.Fatalf(\"\\t%s\\tShould be able to get a Mongo session : %v\", tests.Failed, err)\n\t}\n\tdefer db.CloseMGO(tests.Context)\n\n\tdefer func() {\n\t\tif err := qfix.Remove(db, prefix); err != nil {\n\t\t\tt.Fatalf(\"\\t%s\\tShould be able to remove the query set : %v\", tests.Failed, err)\n\t\t}\n\t\tt.Logf(\"\\t%s\\tShould be able to remove the query set.\", tests.Success)\n\t}()\n\n\tt.Log(\"Given the need to delete a query set in the database.\")\n\t{\n\t\tt.Log(\"\\tWhen using fixture\", fixture)\n\t\t{\n\t\t\tif err := query.Upsert(tests.Context, db, set1); err != nil {\n\t\t\t\tt.Fatalf(\"\\t%s\\tShould be able to create a query set : %s\", tests.Failed, err)\n\t\t\t}\n\t\t\tt.Logf(\"\\t%s\\tShould be able to create a query set.\", tests.Success)\n\n\t\t\tif err := query.Delete(tests.Context, db, qsName); err != nil {\n\t\t\t\tt.Fatalf(\"\\t%s\\tShould be able to delete a query set using its name[%s]: %s\", tests.Failed, qsName, err)\n\t\t\t}\n\t\t\tt.Logf(\"\\t%s\\tShould be able to delete a query set using its name[%s]:\", tests.Success, qsName)\n\n\t\t\tif err := query.Delete(tests.Context, db, qsBadName); err == nil {\n\t\t\t\tt.Fatalf(\"\\t%s\\tShould not be able to delete a query set using wrong name name[%s]\", tests.Failed, qsBadName)\n\t\t\t}\n\t\t\tt.Logf(\"\\t%s\\tShould not be able to delete a query set using wrong name name[%s]\", tests.Success, qsBadName)\n\n\t\t\tif _, err := query.GetByName(tests.Context, db, qsName); err == nil {\n\t\t\t\tt.Fatalf(\"\\t%s\\tShould be able to validate query set with Name[%s] does not exists: %s\", tests.Failed, qsName, errors.New(\"Record Exists\"))\n\t\t\t}\n\t\t\tt.Logf(\"\\t%s\\tShould be able to validate query set with Name[%s] does not exists:\", tests.Success, qsName)\n\t\t}\n\t}\n}", "func (q skinQuery) DeleteAll() error {\n\tif q.Query == nil {\n\t\treturn errors.New(\"models: no skinQuery provided for delete all\")\n\t}\n\n\tqueries.SetDelete(q.Query)\n\n\t_, err := q.Query.Exec()\n\tif err != nil {\n\t\treturn errors.Wrap(err, \"models: unable to delete all from skin\")\n\t}\n\n\treturn nil\n}", "func (db *GeoDB) BatchDelete(qs ...*GeoQuery) error {\n\tif len(qs) == 0 {\n\t\treturn types.ErrNoBatchQueries\n\t}\n\n\tconn := db.pool.Get()\n\tdefer conn.Close()\n\n\tconn.Send(\"MULTI\")\n\tfor _, q := range qs {\n\t\tconn.Send(\"ZREM\", q.Key, q.Member)\n\t}\n\n\t_, err := conn.Do(\"EXEC\")\n\treturn err\n}", "func (q pictureQuery) DeleteAll() error {\n\tif q.Query == nil {\n\t\treturn errors.New(\"models: no pictureQuery provided for delete all\")\n\t}\n\n\tqueries.SetDelete(q.Query)\n\n\t_, err := q.Query.Exec()\n\tif err != nil {\n\t\treturn errors.Wrap(err, \"models: unable to delete all from pictures\")\n\t}\n\n\treturn nil\n}", "func (q authorQuery) DeleteAll() error {\n\tif q.Query == nil {\n\t\treturn errors.New(\"mdbmdbmodels: no authorQuery provided for delete all\")\n\t}\n\n\tqueries.SetDelete(q.Query)\n\n\t_, err := q.Query.Exec()\n\tif err != nil {\n\t\treturn errors.Wrap(err, \"mdbmdbmodels: unable to delete all from authors\")\n\t}\n\n\treturn nil\n}", "func DeleteQueries(n int32, ids *uint32) {\n C.glowDeleteQueries(gpDeleteQueries, (C.GLsizei)(n), (*C.GLuint)(unsafe.Pointer(ids)))\n}", "func del(res http.ResponseWriter, req *http.Request) {\n\tstmt, err := db.Prepare(`DELETE FROM customer WHERE name=\"mahmoud\";`)\n\tcheck(err)\n\tdefer stmt.Close()\n\tr, err := stmt.Exec()\n\tcheck(err)\n\tn, err := r.RowsAffected()\n\tcheck(err)\n\tfmt.Fprintln(res, \"RECORD IS DELETED\", n)\n}", "func (q cvtermsynonymQuery) DeleteAllP() {\n\tif err := q.DeleteAll(); err != nil {\n\t\tpanic(boil.WrapErr(err))\n\t}\n}", "func (q authQuery) DeleteAll() error {\n\tif q.Query == nil {\n\t\treturn errors.New(\"models: no authQuery provided for delete all\")\n\t}\n\n\tqueries.SetDelete(q.Query)\n\n\t_, err := q.Query.Exec()\n\tif err != nil {\n\t\treturn errors.Wrap(err, \"models: unable to delete all from auths\")\n\t}\n\n\treturn nil\n}", "func (q authorQuery) DeleteAllP() {\n\tif err := q.DeleteAll(); err != nil {\n\t\tpanic(boil.WrapErr(err))\n\t}\n}", "func DeleteQueries(n int32, ids *uint32) {\n\tsyscall.Syscall(gpDeleteQueries, 2, uintptr(n), uintptr(unsafe.Pointer(ids)), 0)\n}", "func (q authTokenQuery) DeleteAll() error {\n\tif q.Query == nil {\n\t\treturn errors.New(\"models: no authTokenQuery provided for delete all\")\n\t}\n\n\tqueries.SetDelete(q.Query)\n\n\t_, err := q.Query.Exec()\n\tif err != nil {\n\t\treturn errors.Wrap(err, \"models: unable to delete all from auth_tokens\")\n\t}\n\n\treturn nil\n}", "func (q oauthClientQuery) DeleteAll(exec boil.Executor) (int64, error) {\n\tif q.Query == nil {\n\t\treturn 0, errors.New(\"models: no oauthClientQuery provided for delete all\")\n\t}\n\n\tqueries.SetDelete(q.Query)\n\n\tresult, err := q.Query.Exec(exec)\n\tif err != nil {\n\t\treturn 0, errors.Wrap(err, \"models: unable to delete all from oauth_clients\")\n\t}\n\n\trowsAff, err := result.RowsAffected()\n\tif err != nil {\n\t\treturn 0, errors.Wrap(err, \"models: failed to get rows affected by deleteall for oauth_clients\")\n\t}\n\n\treturn rowsAff, nil\n}", "func runDeletes(t *testing.T, deletes bsonx.Arr, coll *mongo.Collection) {\n\tfor _, val := range deletes {\n\t\tdoc := val.Document() // has q and limit\n\t\tfilter := doc.Lookup(\"q\").Document()\n\n\t\t_, err := coll.DeleteOne(ctx, filter)\n\t\ttesthelpers.RequireNil(t, err, \"error running deleteOne for %s: %s\", t.Name(), err)\n\t}\n}", "func Delete(session *mgo.Session, collection *mgo.Collection, query interface{}) error {\n\tsession.Refresh()\n\treturn collection.Remove(query)\n}", "func cleanDB(t *testing.T, driver *cmneo4j.Driver) {\n\tqs := make([]*cmneo4j.Query, len(allUUIDs))\n\tfor i, uuid := range allUUIDs {\n\t\tqs[i] = &cmneo4j.Query{\n\t\t\tCypher: `MATCH (a:Thing{uuid:$uuid})\n\t\t\tOPTIONAL MATCH (a)-[:EQUIVALENT_TO]-(t:Thing)\n\t\t\tDETACH DELETE t, a`,\n\t\t\tParams: map[string]interface{}{\n\t\t\t\t\"uuid\": uuid,\n\t\t\t},\n\t\t}\n\t}\n\terr := driver.Write(qs...)\n\tassert.NoError(t, err)\n}", "func (q sourceQuery) DeleteAllP() {\n\tif err := q.DeleteAll(); err != nil {\n\t\tpanic(boil.WrapErr(err))\n\t}\n}", "func BatchDeleteToken(some map[string]interface{}) (result *gorm.DB) {\n\tfor k, v := range some {\n\t\tquery := fmt.Sprintf(\"%v like '%%%v%%'\", k, v)\n\t\tprintln(query)\n\t\tresult = DB.Where(query).Delete(&Token{})\n\t}\n\treturn result\n}", "func (q rentalQuery) DeleteAll() error {\n\tif q.Query == nil {\n\t\treturn errors.New(\"sqlboiler: no rentalQuery provided for delete all\")\n\t}\n\n\tqueries.SetDelete(q.Query)\n\n\t_, err := q.Query.Exec()\n\tif err != nil {\n\t\treturn errors.Wrap(err, \"sqlboiler: unable to delete all from rental\")\n\t}\n\n\treturn nil\n}", "func (rc *RequiredCapability) DeleteQuery() string {\n\treturn `UPDATE deliveryservice ds SET required_capabilities = ARRAY_REMOVE((select required_capabilities from deliveryservice WHERE id=:deliveryservice_id), :required_capability)\nWHERE id=:deliveryservice_id AND EXISTS(SELECT 1 FROM deliveryservice ds WHERE id=:deliveryservice_id AND :required_capability = ANY(ds.required_capabilities))`\n}", "func (q organismQuery) DeleteAllP() {\n\tif err := q.DeleteAll(); err != nil {\n\t\tpanic(boil.WrapErr(err))\n\t}\n}", "func (q addressQuery) DeleteAll() error {\n\tif q.Query == nil {\n\t\treturn errors.New(\"sqlboiler: no addressQuery provided for delete all\")\n\t}\n\n\tqueries.SetDelete(q.Query)\n\n\t_, err := q.Query.Exec()\n\tif err != nil {\n\t\treturn errors.Wrap(err, \"sqlboiler: unable to delete all from address\")\n\t}\n\n\treturn nil\n}", "func (o JetSlice) DeleteAll(exec boil.Executor) error {\n\tif o == nil {\n\t\treturn errors.New(\"models: no Jet slice provided for delete all\")\n\t}\n\n\tif len(o) == 0 {\n\t\treturn nil\n\t}\n\n\tif len(jetBeforeDeleteHooks) != 0 {\n\t\tfor _, obj := range o {\n\t\t\tif err := obj.doBeforeDeleteHooks(exec); err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\t\t}\n\t}\n\n\tvar args []interface{}\n\tfor _, obj := range o {\n\t\tpkeyArgs := queries.ValuesFromMapping(reflect.Indirect(reflect.ValueOf(obj)), jetPrimaryKeyMapping)\n\t\targs = append(args, pkeyArgs...)\n\t}\n\n\tsql := \"DELETE FROM `jets` WHERE \" +\n\t\tstrmangle.WhereClauseRepeated(string(dialect.LQ), string(dialect.RQ), 0, jetPrimaryKeyColumns, len(o))\n\n\tif boil.DebugMode {\n\t\tfmt.Fprintln(boil.DebugWriter, sql)\n\t\tfmt.Fprintln(boil.DebugWriter, args)\n\t}\n\n\t_, err := exec.Exec(sql, args...)\n\tif err != nil {\n\t\treturn errors.Wrap(err, \"models: unable to delete all from jet slice\")\n\t}\n\n\tif len(jetAfterDeleteHooks) != 0 {\n\t\tfor _, obj := range o {\n\t\t\tif err := obj.doAfterDeleteHooks(exec); err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\t\t}\n\t}\n\n\treturn nil\n}", "func (q failureQuery) DeleteAll() error {\n\tif q.Query == nil {\n\t\treturn errors.New(\"models: no failureQuery provided for delete all\")\n\t}\n\n\tqueries.SetDelete(q.Query)\n\n\t_, err := q.Query.Exec()\n\tif err != nil {\n\t\treturn errors.Wrap(err, \"models: unable to delete all from failure\")\n\t}\n\n\treturn nil\n}", "func (m *MysqlRepository) deleteAggregates(tx *sqlx.Tx, name string, t reflect.Type, rootID int) error {\n\tconfig, err := getAggregateConfig(t)\n\tif err != nil {\n\t\treturn fmt.Errorf(`unable to get config: %v`, err)\n\t}\n\n\tvar txtSQL strings.Builder\n\n\ttxtSQL.WriteString(\"UPDATE \" + config.TableName + \" SET IsDeleted = true, UpdatedBy = ?, UpdatedDate = ADDDATE(NOW(), INTERVAL 7 HOUR)\")\n\ttxtSQL.WriteString(\" WHERE \" + config.RootIDField + \" = \" + strconv.Itoa(rootID))\n\n\t_, err = tx.Exec(txtSQL.String(), name)\n\tif err != nil {\n\t\treturn fmt.Errorf(\"unable to update: %v\", err)\n\t}\n\n\treturn nil\n}", "func (o CvtermsynonymSlice) DeleteAll(exec boil.Executor) error {\n\tif o == nil {\n\t\treturn errors.New(\"chado: no Cvtermsynonym slice provided for delete all\")\n\t}\n\n\tif len(o) == 0 {\n\t\treturn nil\n\t}\n\n\tif len(cvtermsynonymBeforeDeleteHooks) != 0 {\n\t\tfor _, obj := range o {\n\t\t\tif err := obj.doBeforeDeleteHooks(exec); err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\t\t}\n\t}\n\n\tvar args []interface{}\n\tfor _, obj := range o {\n\t\tpkeyArgs := queries.ValuesFromMapping(reflect.Indirect(reflect.ValueOf(obj)), cvtermsynonymPrimaryKeyMapping)\n\t\targs = append(args, pkeyArgs...)\n\t}\n\n\tsql := fmt.Sprintf(\n\t\t\"DELETE FROM \\\"cvtermsynonym\\\" WHERE (%s) IN (%s)\",\n\t\tstrings.Join(strmangle.IdentQuoteSlice(dialect.LQ, dialect.RQ, cvtermsynonymPrimaryKeyColumns), \",\"),\n\t\tstrmangle.Placeholders(dialect.IndexPlaceholders, len(o)*len(cvtermsynonymPrimaryKeyColumns), 1, len(cvtermsynonymPrimaryKeyColumns)),\n\t)\n\n\tif boil.DebugMode {\n\t\tfmt.Fprintln(boil.DebugWriter, sql)\n\t\tfmt.Fprintln(boil.DebugWriter, args)\n\t}\n\n\t_, err := exec.Exec(sql, args...)\n\tif err != nil {\n\t\treturn errors.Wrap(err, \"chado: unable to delete all from cvtermsynonym slice\")\n\t}\n\n\tif len(cvtermsynonymAfterDeleteHooks) != 0 {\n\t\tfor _, obj := range o {\n\t\t\tif err := obj.doAfterDeleteHooks(exec); err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\t\t}\n\t}\n\n\treturn nil\n}", "func (q shelfQuery) DeleteAll() error {\n\tif q.Query == nil {\n\t\treturn errors.New(\"models: no shelfQuery provided for delete all\")\n\t}\n\n\tqueries.SetDelete(q.Query)\n\n\t_, err := q.Query.Exec()\n\tif err != nil {\n\t\treturn errors.Wrap(err, \"models: unable to delete all from shelf\")\n\t}\n\n\treturn nil\n}", "func deletePeople(id int) {\n\tsqlStatement := `\nDELETE FROM people\nWHERE id = $1;`\n\t_, err := Db.Exec(sqlStatement, 1)\n\tif err != nil {\n\t\tpanic(err)\n\t}\n\tfmt.Println(\"People Deleted\", id)\n\n}", "func (q currentChartDataMinutelyQuery) DeleteAll(exec boil.Executor) (int64, error) {\n\tif q.Query == nil {\n\t\treturn 0, errors.New(\"models: no currentChartDataMinutelyQuery provided for delete all\")\n\t}\n\n\tqueries.SetDelete(q.Query)\n\n\tresult, err := q.Query.Exec(exec)\n\tif err != nil {\n\t\treturn 0, errors.Wrap(err, \"models: unable to delete all from current_chart_data_minutely\")\n\t}\n\n\trowsAff, err := result.RowsAffected()\n\tif err != nil {\n\t\treturn 0, errors.Wrap(err, \"models: failed to get rows affected by deleteall for current_chart_data_minutely\")\n\t}\n\n\treturn rowsAff, nil\n}", "func (ds *MySQL) Delete(q QueryMap) (interface{}, error) {\n\tbuilder := ds.adapter.Builder()\n\tSQL := builder.Delete().From(ds.source).Where(q).Build()\n\tif ds.debug {\n\t\tfmt.Println(\"Delete SQL: \", SQL)\n\t}\n\n\trows, err := ds.adapter.Exec(SQL)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\treturn rows, nil\n}", "func CleanQ(names ...string) {\n\tvar wg sync.WaitGroup\n\tfor _, name := range names {\n\t\twg.Add(1)\n\t\tgo func(name string) {\n\t\t\tdefer wg.Done()\n\t\t\tq, _ := factory.Get(name)\n\t\t\tfor {\n\t\t\t\tmsg, err := q.Get(1e6)\n\t\t\t\tif err != nil {\n\t\t\t\t\tbreak\n\t\t\t\t}\n\t\t\t\tq.Delete(msg)\n\t\t\t}\n\t\t}(name)\n\t}\n\twg.Wait()\n}", "func (q apiKeyQuery) DeleteAllP() {\n\tif err := q.DeleteAll(); err != nil {\n\t\tpanic(boil.WrapErr(err))\n\t}\n}", "func (q voteQuery) DeleteAll() error {\n\tif q.Query == nil {\n\t\treturn errors.New(\"models: no voteQuery provided for delete all\")\n\t}\n\n\tqueries.SetDelete(q.Query)\n\n\t_, err := q.Query.Exec()\n\tif err != nil {\n\t\treturn errors.Wrap(err, \"models: unable to delete all from vote\")\n\t}\n\n\treturn nil\n}", "func (q authTokenQuery) DeleteAllP() {\n\tif err := q.DeleteAll(); err != nil {\n\t\tpanic(boil.WrapErr(err))\n\t}\n}", "func (w *Wrapper) buildDelete(tableNames ...string) (query string) {\n\tbeforeOptions, _ := w.buildQueryOptions()\n\tquery += fmt.Sprintf(\"DELETE %sFROM %s \", beforeOptions, strings.Join(tableNames, \", \"))\n\treturn\n}", "func delete(cl *lib.Client, list *[]extAQLFileInfo) error {\n\n\t// range over list and make delete calls to Artifactory\n\tfor _, d := range *list {\n\n\t\t//construct request\n\t\tdl := []string{\n\t\t\td.Repo,\n\t\t\td.Path,\n\t\t\td.Name,\n\t\t}\n\t\tdlj := strings.Join(dl, \"/\")\n\n\t\tvar request lib.Request\n\t\trequest.Verb = \"DELETE\"\n\t\trequest.Path = \"/\" + (dlj)\n\n\t\t// make request\n\t\t_, err := cl.HTTPRequest(request)\n\t\tif err != nil {\n\t\t\texitErrorf(\"could not delete %q: \", dlj, err)\n\t\t}\n\t\tfmt.Println(\"deleted: \", dlj)\n\t}\n\treturn nil\n}", "func delete(w http.ResponseWriter, r *http.Request) {\r\n\tid, _ := strconv.ParseInt(r.URL.Query().Get(\"id\"), 10, 64)\r\n\tquery := \"DELETE from public.item where id=$1\"\r\n\t_, err = db.Exec(query,id)\r\n\tif err != nil {\r\n\t\tpanic(err)\r\n\t}\r\n\t//json.NewEncoder(w).Encode()\t\r\n}", "func (q *gcpQuery) deleteNameServers(gcpClient gcpclient.Client, managedZone string, domain string, values sets.String) error {\n\treturn gcpClient.DeleteResourceRecordSet(managedZone, q.resourceRecordSet(domain, values))\n}", "func (q inventoryQuery) DeleteAll() error {\n\tif q.Query == nil {\n\t\treturn errors.New(\"models: no inventoryQuery provided for delete all\")\n\t}\n\n\tqueries.SetDelete(q.Query)\n\n\t_, err := q.Query.Exec()\n\tif err != nil {\n\t\treturn errors.Wrap(err, \"models: unable to delete all from inventory\")\n\t}\n\n\treturn nil\n}", "func (q recordMeasureQuery) DeleteAll() error {\n\tif q.Query == nil {\n\t\treturn errors.New(\"public: no recordMeasureQuery provided for delete all\")\n\t}\n\n\tqueries.SetDelete(q.Query)\n\n\t_, err := q.Query.Exec()\n\tif err != nil {\n\t\treturn errors.Wrap(err, \"public: unable to delete all from record_measures\")\n\t}\n\n\treturn nil\n}", "func (q authMessageQuery) DeleteAll() error {\n\tif q.Query == nil {\n\t\treturn errors.New(\"models: no authMessageQuery provided for delete all\")\n\t}\n\n\tqueries.SetDelete(q.Query)\n\n\t_, err := q.Query.Exec()\n\tif err != nil {\n\t\treturn errors.Wrap(err, \"models: unable to delete all from auth_message\")\n\t}\n\n\treturn nil\n}", "func (q shelfQuery) DeleteAllP() {\n\tif err := q.DeleteAll(); err != nil {\n\t\tpanic(boil.WrapErr(err))\n\t}\n}", "func (q blackCardQuery) DeleteAll() error {\n\tif q.Query == nil {\n\t\treturn errors.New(\"models: no blackCardQuery provided for delete all\")\n\t}\n\n\tqueries.SetDelete(q.Query)\n\n\t_, err := q.Query.Exec()\n\tif err != nil {\n\t\treturn errors.Wrap(err, \"models: unable to delete all from black_cards\")\n\t}\n\n\treturn nil\n}", "func (q stockCvtermQuery) DeleteAll() error {\n\tif q.Query == nil {\n\t\treturn errors.New(\"chado: no stockCvtermQuery provided for delete all\")\n\t}\n\n\tqueries.SetDelete(q.Query)\n\n\t_, err := q.Query.Exec()\n\tif err != nil {\n\t\treturn errors.Wrap(err, \"chado: unable to delete all from stock_cvterm\")\n\t}\n\n\treturn nil\n}", "func (r *FakeClient) DeleteAllOf(ctx context.Context, obj client.Object, opts ...client.DeleteAllOfOption) error {\n\t// TODO (covariance) implement me!\n\tpanic(\"not implemented\")\n}", "func deletePerson(w http.ResponseWriter, r *http.Request) {\n\tw.Header().Set(\"Content-Type\", \"application/json\")\n\tfmt.Println(\"DELETE HIT\")\n\tparams := mux.Vars(r)\n\tresult, err := db.Query(\"SELECT * FROM Persons WHERE pName = ?\", params[\"name\"])\n\tif err != nil {\n\t\tpanic(err.Error())\n\t}\n\tvar per Person\n\tfor result.Next() {\n\t\terrs := result.Scan(&per.Age, &per.Name)\n\t\tif errs != nil {\n\t\t\tpanic(errs.Error())\n\t\t}\n\t}\n\tcache.Set(strconv.Itoa(per.Age), []byte(per.Name))\n\n\tstmt, err := db.Prepare(\"DELETE FROM Persons WHERE pName = ?\")\n\tif err != nil {\n\t\tpanic(err.Error())\n\t}\n\t_, err = stmt.Exec(params[\"name\"])\n\tif err != nil {\n\t\tpanic(err.Error())\n\t}\n\tfmt.Fprintf(w, \"Person with name = %s was deleted\", params[\"name\"])\n}", "func (q rawVisitQuery) DeleteAll(ctx context.Context, exec boil.ContextExecutor) (int64, error) {\n\tif q.Query == nil {\n\t\treturn 0, errors.New(\"models: no rawVisitQuery provided for delete all\")\n\t}\n\n\tqueries.SetDelete(q.Query)\n\n\tresult, err := q.Query.ExecContext(ctx, exec)\n\tif err != nil {\n\t\treturn 0, errors.Wrap(err, \"models: unable to delete all from raw_visits\")\n\t}\n\n\trowsAff, err := result.RowsAffected()\n\tif err != nil {\n\t\treturn 0, errors.Wrap(err, \"models: failed to get rows affected by deleteall for raw_visits\")\n\t}\n\n\treturn rowsAff, nil\n}", "func DeleteKeyValueViaName(iName string) (err error) {\n\tvar has bool\n\tvar _KeyValue = &KeyValue{Name: iName}\n\tif has, err = Engine.Get(_KeyValue); (has == true) && (err == nil) {\n\t\tif row, err := Engine.Where(\"name = ?\", iName).Delete(new(KeyValue)); (err != nil) || (row <= 0) {\n\t\t\treturn err\n\t\t} else {\n\t\t\treturn nil\n\t\t}\n\t}\n\treturn\n}", "func (c Claims) Del(name string) { delete(c, name) }", "func (q authQuery) DeleteAllP() {\n\tif err := q.DeleteAll(); err != nil {\n\t\tpanic(boil.WrapErr(err))\n\t}\n}", "func (fkw *FakeClientWrapper) DeleteAllOf(ctx context.Context, obj runtime.Object, opts ...k8sCl.DeleteAllOfOption) error {\n\treturn fkw.client.DeleteAllOf(ctx, obj, opts...)\n}", "func (q jetQuery) DeleteAllP() {\n\tif err := q.DeleteAll(); err != nil {\n\t\tpanic(boil.WrapErr(err))\n\t}\n}", "func (s structModel)Delete(table string)(query string, err error){\n\tif s.err != nil{\n\t\treturn \"\", s.err\n\t}\n\n\tquery = \"DELETE FROM \" + table\n\treturn query, nil\n}", "func (q stockQuery) DeleteAllP() {\n\tif err := q.DeleteAll(); err != nil {\n\t\tpanic(boil.WrapErr(err))\n\t}\n}", "func (qs SysDBQuerySet) Delete() error {\n\treturn qs.db.Delete(SysDB{}).Error\n}", "func (q addressQuery) DeleteAllP() {\n\tif err := q.DeleteAll(); err != nil {\n\t\tpanic(boil.WrapErr(err))\n\t}\n}", "func (s *Store) Delete(c *gin.Context) {\n\n}", "func (q sourceQuery) DeleteAll(exec boil.Executor) (int64, error) {\n\tif q.Query == nil {\n\t\treturn 0, errors.New(\"mdbmodels: no sourceQuery provided for delete all\")\n\t}\n\n\tqueries.SetDelete(q.Query)\n\n\tresult, err := q.Query.Exec(exec)\n\tif err != nil {\n\t\treturn 0, errors.Wrap(err, \"mdbmodels: unable to delete all from sources\")\n\t}\n\n\trowsAff, err := result.RowsAffected()\n\tif err != nil {\n\t\treturn 0, errors.Wrap(err, \"mdbmodels: failed to get rows affected by deleteall for sources\")\n\t}\n\n\treturn rowsAff, nil\n}", "func (q phenotypepropQuery) DeleteAllP() {\n\tif err := q.DeleteAll(); err != nil {\n\t\tpanic(boil.WrapErr(err))\n\t}\n}", "func (q rentalQuery) DeleteAllP() {\n\tif err := q.DeleteAll(); err != nil {\n\t\tpanic(boil.WrapErr(err))\n\t}\n}", "func (u *usageCollectorService) DeleteQuery(queryID string) error {\n\tresponse, err := u.client.do(\n\t\t\"DELETE\",\n\t\tfmt.Sprintf(\"%s/orchestrators/%s\", yorcProviderRESTPrefix, queryID),\n\t\tnil,\n\t\t[]Header{\n\t\t\t{\n\t\t\t\t\"Content-Type\",\n\t\t\t\t\"application/json\",\n\t\t\t},\n\t\t},\n\t)\n\n\tif err != nil {\n\t\treturn errors.Wrap(err, \"Unable to send request to undeploy A4C application\")\n\t}\n\tdefer response.Body.Close()\n\n\tif response.StatusCode != http.StatusOK {\n\t\treturn getError(response.Body)\n\t}\n\n\treturn nil\n}", "func (o StockSlice) DeleteAll(exec boil.Executor) error {\n\tif o == nil {\n\t\treturn errors.New(\"models: no Stock slice provided for delete all\")\n\t}\n\n\tif len(o) == 0 {\n\t\treturn nil\n\t}\n\n\tvar args []interface{}\n\tfor _, obj := range o {\n\t\tpkeyArgs := queries.ValuesFromMapping(reflect.Indirect(reflect.ValueOf(obj)), stockPrimaryKeyMapping)\n\t\targs = append(args, pkeyArgs...)\n\t}\n\n\tsql := \"DELETE FROM `stock` WHERE \" +\n\t\tstrmangle.WhereClauseRepeated(string(dialect.LQ), string(dialect.RQ), 0, stockPrimaryKeyColumns, len(o))\n\n\tif boil.DebugMode {\n\t\tfmt.Fprintln(boil.DebugWriter, sql)\n\t\tfmt.Fprintln(boil.DebugWriter, args)\n\t}\n\n\t_, err := exec.Exec(sql, args...)\n\tif err != nil {\n\t\treturn errors.Wrap(err, \"models: unable to delete all from stock slice\")\n\t}\n\n\treturn nil\n}", "func (o PaymentObjectSlice) DeleteAll(ctx context.Context, exec boil.ContextExecutor) (int64, error) {\n\tif len(o) == 0 {\n\t\treturn 0, nil\n\t}\n\n\tif len(paymentObjectBeforeDeleteHooks) != 0 {\n\t\tfor _, obj := range o {\n\t\t\tif err := obj.doBeforeDeleteHooks(ctx, exec); err != nil {\n\t\t\t\treturn 0, err\n\t\t\t}\n\t\t}\n\t}\n\n\tvar args []interface{}\n\tfor _, obj := range o {\n\t\tpkeyArgs := queries.ValuesFromMapping(reflect.Indirect(reflect.ValueOf(obj)), paymentObjectPrimaryKeyMapping)\n\t\targs = append(args, pkeyArgs...)\n\t}\n\n\tsql := \"DELETE FROM `payment_objects` WHERE \" +\n\t\tstrmangle.WhereClauseRepeated(string(dialect.LQ), string(dialect.RQ), 0, paymentObjectPrimaryKeyColumns, len(o))\n\n\tif boil.IsDebug(ctx) {\n\t\twriter := boil.DebugWriterFrom(ctx)\n\t\tfmt.Fprintln(writer, sql)\n\t\tfmt.Fprintln(writer, args)\n\t}\n\tresult, err := exec.ExecContext(ctx, sql, args...)\n\tif err != nil {\n\t\treturn 0, errors.Wrap(err, \"models: unable to delete all from paymentObject slice\")\n\t}\n\n\trowsAff, err := result.RowsAffected()\n\tif err != nil {\n\t\treturn 0, errors.Wrap(err, \"models: failed to get rows affected by deleteall for payment_objects\")\n\t}\n\n\tif len(paymentObjectAfterDeleteHooks) != 0 {\n\t\tfor _, obj := range o {\n\t\t\tif err := obj.doAfterDeleteHooks(ctx, exec); err != nil {\n\t\t\t\treturn 0, err\n\t\t\t}\n\t\t}\n\t}\n\n\treturn rowsAff, nil\n}", "func Delete(db gorp.SqlExecutor, i interface{}) error {\n\treturn Mapper.Delete(db, i)\n}", "func (q featureCvtermDbxrefQuery) DeleteAllP() {\n\tif err := q.DeleteAll(); err != nil {\n\t\tpanic(boil.WrapErr(err))\n\t}\n}", "func DeleteAll(db *sql.DB, table string) error {\n if _, err := db.Exec(fmt.Sprintf(\"DELETE FROM %s\", table)); err != nil {\n return err\n }\n return nil\n}", "func (o SourceSlice) DeleteAll(exec boil.Executor) error {\n\tif o == nil {\n\t\treturn errors.New(\"mdbmdbmodels: no Source slice provided for delete all\")\n\t}\n\n\tif len(o) == 0 {\n\t\treturn nil\n\t}\n\n\tvar args []interface{}\n\tfor _, obj := range o {\n\t\tpkeyArgs := queries.ValuesFromMapping(reflect.Indirect(reflect.ValueOf(obj)), sourcePrimaryKeyMapping)\n\t\targs = append(args, pkeyArgs...)\n\t}\n\n\tsql := \"DELETE FROM \\\"sources\\\" WHERE \" +\n\t\tstrmangle.WhereClauseRepeated(string(dialect.LQ), string(dialect.RQ), 1, sourcePrimaryKeyColumns, len(o))\n\n\tif boil.DebugMode {\n\t\tfmt.Fprintln(boil.DebugWriter, sql)\n\t\tfmt.Fprintln(boil.DebugWriter, args)\n\t}\n\n\t_, err := exec.Exec(sql, args...)\n\tif err != nil {\n\t\treturn errors.Wrap(err, \"mdbmdbmodels: unable to delete all from source slice\")\n\t}\n\n\treturn nil\n}", "func (q instrumentClassQuery) DeleteAllP() {\n\tif err := q.DeleteAll(); err != nil {\n\t\tpanic(boil.WrapErr(err))\n\t}\n}", "func (o AddressSlice) DeleteAll(exec boil.Executor) error {\n\tif o == nil {\n\t\treturn errors.New(\"sqlboiler: no Address slice provided for delete all\")\n\t}\n\n\tif len(o) == 0 {\n\t\treturn nil\n\t}\n\n\tif len(addressBeforeDeleteHooks) != 0 {\n\t\tfor _, obj := range o {\n\t\t\tif err := obj.doBeforeDeleteHooks(exec); err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\t\t}\n\t}\n\n\tvar args []interface{}\n\tfor _, obj := range o {\n\t\tpkeyArgs := queries.ValuesFromMapping(reflect.Indirect(reflect.ValueOf(obj)), addressPrimaryKeyMapping)\n\t\targs = append(args, pkeyArgs...)\n\t}\n\n\tsql := \"DELETE FROM `address` WHERE \" +\n\t\tstrmangle.WhereClauseRepeated(string(dialect.LQ), string(dialect.RQ), 0, addressPrimaryKeyColumns, len(o))\n\n\tif boil.DebugMode {\n\t\tfmt.Fprintln(boil.DebugWriter, sql)\n\t\tfmt.Fprintln(boil.DebugWriter, args)\n\t}\n\n\t_, err := exec.Exec(sql, args...)\n\tif err != nil {\n\t\treturn errors.Wrap(err, \"sqlboiler: unable to delete all from address slice\")\n\t}\n\n\tif len(addressAfterDeleteHooks) != 0 {\n\t\tfor _, obj := range o {\n\t\t\tif err := obj.doAfterDeleteHooks(exec); err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\t\t}\n\t}\n\n\treturn nil\n}", "func (q assetRevisionQuery) DeleteAllP() {\n\tif err := q.DeleteAll(); err != nil {\n\t\tpanic(boil.WrapErr(err))\n\t}\n}", "func (q inventoryQuery) DeleteAllP() {\n\tif err := q.DeleteAll(); err != nil {\n\t\tpanic(boil.WrapErr(err))\n\t}\n}" ]
[ "0.65552074", "0.6499519", "0.6248495", "0.61996925", "0.60681325", "0.60112804", "0.5999195", "0.59653705", "0.5927085", "0.59224665", "0.5909219", "0.5850164", "0.5842046", "0.58302957", "0.5824605", "0.5808344", "0.5786152", "0.577982", "0.57709503", "0.57706755", "0.5767985", "0.5742542", "0.57260394", "0.5692336", "0.5674596", "0.5670566", "0.56686884", "0.5652351", "0.565229", "0.5637787", "0.563298", "0.56226957", "0.5622065", "0.5613575", "0.5607619", "0.55972177", "0.5586151", "0.5582797", "0.5576307", "0.5546593", "0.5537365", "0.5520526", "0.55034643", "0.54968315", "0.5495863", "0.54952776", "0.54939413", "0.54875666", "0.5483817", "0.548185", "0.54758143", "0.54738986", "0.5472679", "0.5467461", "0.5467265", "0.5458626", "0.5455649", "0.5455383", "0.5443614", "0.5438287", "0.5432651", "0.54324776", "0.54304427", "0.54303545", "0.5429615", "0.5425004", "0.54184747", "0.54168904", "0.5413855", "0.54119796", "0.54045516", "0.5401341", "0.5394681", "0.53872293", "0.538657", "0.53820765", "0.53772616", "0.53734845", "0.5373353", "0.53732204", "0.53726876", "0.5372149", "0.5367702", "0.5365556", "0.5360276", "0.53549945", "0.53519785", "0.5348332", "0.5346039", "0.5343865", "0.5342076", "0.5341862", "0.534159", "0.5341243", "0.5337205", "0.53322303", "0.53298634", "0.53162104", "0.53140706", "0.5313374", "0.5303182" ]
0.0
-1
delete named sampler objects
func DeleteSamplers(count int32, samplers *uint32) { C.glowDeleteSamplers(gpDeleteSamplers, (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(samplers))) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func DeleteSamplers(count int32, samplers *uint32) {\n C.glowDeleteSamplers(gpDeleteSamplers, (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(samplers)))\n}", "func DeleteSamplers(count int32, samplers *uint32) {\n\tsyscall.Syscall(gpDeleteSamplers, 2, uintptr(count), uintptr(unsafe.Pointer(samplers)), 0)\n}", "func (s *serverMetricsRecorder) DeleteNamedUtilization(name string) {\n\ts.mu.Lock()\n\tdefer s.mu.Unlock()\n\tdelete(s.state.Utilization, name)\n}", "func cleanup(handler *deployment.Handler) {\n\thandler.Delete(name)\n}", "func releaseSampler(s *Sampler) {\n\tif s.clSampler != nil {\n\t\tC.clReleaseSampler(s.clSampler)\n\t\ts.clSampler = nil\n\t}\n}", "func (s *SampleManager) Cleanup(name string) error {\n\tfmt.Println(\"Cleaning up...\")\n\n\treturn s.delete(name)\n}", "func DeleteTextures(n Sizei, textures []Uint) {\n\tcn, _ := (C.GLsizei)(n), cgoAllocsUnknown\n\tctextures, _ := (*C.GLuint)(unsafe.Pointer((*sliceHeader)(unsafe.Pointer(&textures)).Data)), cgoAllocsUnknown\n\tC.glDeleteTextures(cn, ctextures)\n}", "func cleanup(t *testing.T, namespace string) {\n\targs := \"delete\"\n\tif namespace != \"\" {\n\t\targs += \" -n \" + namespace\n\t}\n\n\terr, stdout, stderr := runSonobuoyCommand(t, args)\n\n\tif err != nil {\n\t\tt.Logf(\"Error encountered during cleanup: %q\\n\", err)\n\t\tt.Log(stdout.String())\n\t\tt.Log(stderr.String())\n\t}\n}", "func (c Claims) Del(name string) { delete(c, name) }", "func (s *Service) deleteExperiment(c *gin.Context) {}", "func (t *Track) Clean() {\n\tfor i := 0; i < len(t.samples); i++ {\n\t\tt.samples[i] = nil\n\t}\n\tt.samples = t.samples[:0]\n\tt.samples = nil\n}", "func (am *Manager) Clean() {\n\tfor name, m := range am.Materials {\n\t\tLogger.Printf(\"Manager: deleting Material '%s'\\n\", name)\n\t\tm.Clean()\n\t\tdelete(am.Materials, name)\n\t}\n\tfor name, m := range am.Meshes {\n\t\tLogger.Printf(\"Manager: deleting Mesh '%s'\\n\", name)\n\t\tm.Clean()\n\t\tdelete(am.Meshes, name)\n\t}\n\tfor set, prog := range am.Programs {\n\t\tLogger.Printf(\"Manager: deleting Program '%v'\\n\", set)\n\t\tgl.DeleteProgram(prog)\n\t\tdelete(am.Programs, set)\n\t}\n\tfor name, shader := range am.Shaders {\n\t\tLogger.Printf(\"Manager: deleting Shader '%s'\\n\", name)\n\t\tgl.DeleteShader(shader)\n\t\tdelete(am.Shaders, name)\n\t}\n\tfor name, tex := range am.Textures {\n\t\tLogger.Printf(\"Manager: deleting Texture '%s'\\n\", name)\n\t\ttex.Clean()\n\t\tdelete(am.Textures, name)\n\t}\n}", "func (bt *Blobies) deregister(guid uuid.UUID) {\n\tdelete(bt.Objects, guid)\n}", "func (native *OpenGL) DeleteTextures(textures []uint32) {\n\tgl.DeleteTextures(int32(len(textures)), &textures[0])\n}", "func (bs *brains) del(b *brain) {\n\tbs.m.Lock()\n\tdefer bs.m.Unlock()\n\tdelete(bs.k, b.key)\n\tdelete(bs.n, b.name)\n}", "func doDeleteMesh(componentMeshName string) {\n\tcr := visibleMeshes[componentMeshName]\n\tcr.Renderable.Destroy()\n\tcr.Renderable = nil\n\tdelete(visibleMeshes, componentMeshName)\n}", "func destructor(cmd *cobra.Command, args []string) {\n\tlog.Debug().Msgf(\"Running Destructor.\\n\")\n\tif debug {\n\t\t// Keep intermediary files, when on debug\n\t\tlog.Debug().Msgf(\"Skipping file clearance on Debug Mode.\\n\")\n\t\treturn\n\t}\n\tintermediaryFiles := []string{\"generate_pylist.py\", \"pylist.json\", \"dependencies.txt\", \"golist.json\", \"npmlist.json\"}\n\tfor _, file := range intermediaryFiles {\n\t\tfile = filepath.Join(os.TempDir(), file)\n\t\tif _, err := os.Stat(file); err != nil {\n\t\t\tif os.IsNotExist(err) {\n\t\t\t\t// If file doesn't exists, continue\n\t\t\t\tcontinue\n\t\t\t}\n\t\t}\n\t\te := os.Remove(file)\n\t\tif e != nil {\n\t\t\tlog.Fatal().Msgf(\"Error clearing files %s\", file)\n\t\t}\n\t}\n}", "func (am *AssetManager) Clean() {\n\tfor name, model := range am.Models {\n\t\tmodel.Delete()\n\t\tdelete(am.Models, name)\n\t}\n\tfor name, tex := range am.Textures {\n\t\ttex.Delete()\n\t\tdelete(am.Textures, name)\n\t}\n\tfor name, prog := range am.Programs {\n\t\tprog.Delete()\n\t\tdelete(am.Programs, name)\n\t}\n}", "func (b *Builder) clearMesh() {\n\tfor _, key := range b.localInstances.Keys() {\n\t\tb.localInstances.Delete(key)\n\t}\n}", "func (t *tInfo) teardown() {\n\tt.recorders.close()\n\n\tif t.apiClient != nil {\n\t\tt.apiClient.ClusterV1().Version().Delete(context.Background(), &api.ObjectMeta{Name: t.testName})\n\t\tt.apiClient.Close()\n\t\tt.apiClient = nil\n\t}\n\n\tif t.esClient != nil {\n\t\tt.esClient.Close()\n\t}\n\n\ttestutils.StopElasticsearch(t.elasticsearchName, t.elasticsearchDir)\n\n\tif t.mockCitadelQueryServer != nil {\n\t\tt.mockCitadelQueryServer.Stop()\n\t\tt.mockCitadelQueryServer = nil\n\t}\n\n\tif t.evtsMgr != nil {\n\t\tt.evtsMgr.Stop()\n\t\tt.evtsMgr = nil\n\t}\n\n\tt.evtProxyServices.Stop()\n\n\tif t.apiServer != nil {\n\t\tt.apiServer.Stop()\n\t\tt.apiServer = nil\n\t}\n\n\t// stop certificate server\n\ttestutils.CleanupIntegTLSProvider()\n\n\tif t.mockResolver != nil {\n\t\tt.mockResolver.Stop()\n\t\tt.mockResolver = nil\n\t}\n\n\t// remove the local persistent events store\n\tt.logger.Infof(\"removing events store %s\", t.storeConfig.Dir)\n\tos.RemoveAll(t.storeConfig.Dir)\n\n\tt.logger.Infof(\"completed test\")\n}", "func (d *Demo) DeleteAll(g *gom.Gom) {\n\ttoolkit.Println(\"===== Delete All =====\")\n\n\tvar err error\n\tif d.useParams {\n\t\t_, err = g.Set(&gom.SetParams{\n\t\t\tTableName: \"hero\",\n\t\t\tFilter: gom.EndWith(\"Name\", \"man\"),\n\t\t\tTimeout: 10,\n\t\t}).Cmd().DeleteAll()\n\t} else {\n\t\t_, err = g.Set(nil).Table(\"hero\").Timeout(10).Filter(gom.EndWith(\"Name\", \"man\")).Cmd().DeleteAll()\n\t}\n\n\tif err != nil {\n\t\ttoolkit.Println(err.Error())\n\t\treturn\n\t}\n}", "func (j *TrainingJob) delete() {\n\tj.gc.CollectJob(j.job.Metadata.Name, garbagecollection.NullUID)\n}", "func CleanQ(names ...string) {\n\tvar wg sync.WaitGroup\n\tfor _, name := range names {\n\t\twg.Add(1)\n\t\tgo func(name string) {\n\t\t\tdefer wg.Done()\n\t\t\tq, _ := factory.Get(name)\n\t\t\tfor {\n\t\t\t\tmsg, err := q.Get(1e6)\n\t\t\t\tif err != nil {\n\t\t\t\t\tbreak\n\t\t\t\t}\n\t\t\t\tq.Delete(msg)\n\t\t\t}\n\t\t}(name)\n\t}\n\twg.Wait()\n}", "func (rest *RestAPI) UnloadResources() {\n}", "func (p *DynamicComputationPolicy) UnregisterAll(path string) {\n\tdelete(p.capabilities, path)\n}", "func garbageCleaner() {\n\tfor _ = range time.Tick(1 * time.Minute) {\n\t\tstorage.Cleanup()\n\t}\n}", "func (s *Scene) Cleanup() {\n\tvar id uint32\n\tfor i := 0; i < numPrograms; i++ {\n\t\tid = s.Programs[i]\n\t\tgl.UseProgram(id)\n\t\tgl.DeleteProgram(id)\n\t}\n}", "func DeleteTransformFeedbacks(n int32, ids *uint32) {\n C.glowDeleteTransformFeedbacks(gpDeleteTransformFeedbacks, (C.GLsizei)(n), (*C.GLuint)(unsafe.Pointer(ids)))\n}", "func (p *MyPipeline) Del(keys ...interface{}) client.Result {\n\treturn p.Pipeline.Del(keys)\n}", "func Teardown() {\n}", "func (t Texture3D) Destroy() {\n\tgl.DeleteTextures(1, &t.id)\n}", "func unregisterViews(r *Reporter) error {\n\tif !r.initialized {\n\t\treturn errors.New(\"reporter is not initialized\")\n\t}\n\tmetricstest.Unregister(countName, latencyName, qdepthName)\n\tr.initialized = false\n\treturn nil\n}", "func (debugging *debuggingOpenGL) DeleteTextures(textures []uint32) {\n\tdebugging.recordEntry(\"DeleteTextures\", textures)\n\tdebugging.gl.DeleteTextures(textures)\n\tdebugging.recordExit(\"DeleteTextures\")\n}", "func (m *podMetrics) Destroy() {\n}", "func (texture Texture) Delete() {\n\t// TODO: Is it somehow possible to get &uint32(texture) without assigning it to textures?\n\ttextures := uint32(texture)\n\tgl.DeleteTextures(1, &textures)\n}", "func del(w http.ResponseWriter, r *http.Request) {\n\tname := r.URL.Query().Get(\":name\")\n\tdelete(pets, name)\n}", "func (r *DefaultTaggedRegistry) UnregisterAll() {\n\tr.mutex.Lock()\n\tdefer r.mutex.Unlock()\n\tfor name, _ := range r.metrics {\n\t\tdelete(r.metrics, name)\n\t}\n}", "func (g *testGenerator) Destroy() {\n\tg.Generator.Destroy()\n}", "func (setup *SimpleTestSetup) TearDown() {\n\tsetup.harnessPool.DisposeAll()\n\tsetup.harnessWalletPool.DisposeAll()\n\t//setup.nodeGoBuilder.Dispose()\n\tsetup.WorkingDir.Dispose()\n}", "func Remove(name string) error", "func (c SplitSize) Del(path string) {\n\tfor _, child := range c {\n\t\tchild.Cache.Del(path)\n\t}\n}", "func (j *TrainingJob) deleteResources() error {\n\tfor _, r := range j.Replicas {\n\t\tif err := r.Delete(); err != nil {\n\t\t\treturn err\n\t\t}\n\t}\n\n\treturn nil\n}", "func finalizer(w *Worker) {\n\tlog.Printf(\"Destroy worker %v\\n\", w.ID)\n}", "func (pm partitionMap) cleanup() {\n\tfor ns, partitions := range pm {\n\t\tfor i := range partitions.Replicas {\n\t\t\tfor j := range partitions.Replicas[i] {\n\t\t\t\tpartitions.Replicas[i][j] = nil\n\t\t\t}\n\t\t\tpartitions.Replicas[i] = nil\n\t\t}\n\n\t\tpartitions.Replicas = nil\n\t\tpartitions.regimes = nil\n\n\t\tdelete(pm, ns)\n\t}\n}", "func DelNamedLogger(name string) {\n\tl, ok := NamedLoggers.Load(name)\n\tif ok {\n\t\tNamedLoggers.Delete(name)\n\t\tl.Close()\n\t}\n}", "func (t *JobUpgradeTest) Teardown(f *framework.Framework) {\n\t// rely on the namespace deletion to clean up everything\n}", "func (s *Scene) Delete() {\n\ts.propOctree = nil\n\ts.props = nil\n\n\ts.bodyPool = nil\n\ts.dynamicBodies = nil\n\n\ts.firstSBConstraint = nil\n\ts.lastSBConstraint = nil\n\n\ts.firstDBConstraint = nil\n\ts.lastDBConstraint = nil\n}", "func (n *namest) deleteCounts(db *sql.DB) error {\n\t_, err := db.Exec(\"UPDATE names SET count=0 WHERE count>0\")\n\n\treturn err\n}", "func (k *Kloud) cleanupEventers(id string) {\n\tfor method := range states {\n\t\teventId := method + \"-\" + id\n\t\tdelete(k.Eventers, eventId)\n\t}\n}", "func (p *panel) trash() {\n\tif p.slab != nil {\n\t\tp.slab.Dispose()\n\t\tp.slab = nil\n\t}\n\tfor _, cube := range p.cubes {\n\t\tcube.reset(0)\n\t}\n}", "func DeleteTransformFeedbacks(n int32, ids *uint32) {\n\tsyscall.Syscall(gpDeleteTransformFeedbacks, 2, uintptr(n), uintptr(unsafe.Pointer(ids)), 0)\n}", "func skykeydeletenamecmd(name string) {\n\terr := httpClient.SkykeyDeleteByNamePost(name)\n\tif err != nil {\n\t\tdie(err)\n\t}\n\n\tfmt.Println(\"Skykey Deleted!\")\n}", "func Teardown(name string) {\n\t// ensure both list and diagnostic list are removed.\n\tdefer func() { delete(diagnosticTeardownLists, name) }()\n\tdefer func() { delete(teardownLists, name) }()\n\n\tlist := teardownLists[name]\n\tlist = append(list, diagnosticTeardownLists[name]...) // append any diagnostic funcs - so they are called FIRST\n\n\tfor x := len(list) - 1; x >= 0; x-- {\n\t\tlist[x]()\n\t}\n}", "func deletePerson(w http.ResponseWriter, r *http.Request) {\r\n\tw.Header().Set(\"Content-Type\", \"application/json\")\r\n\r\n\tparams := mux.Vars(r)\r\n\tuuid, err := primitive.ObjectIDFromHex(params[\"uuid\"])\r\n\tif err != nil {\r\n\t\tlog.Fatal(err)\r\n\t}\r\n\r\n\tcollection := models.ConnectDB()\r\n\tobjectToDelete, err := collection.DeleteOne(context.TODO(), bson.M{\"_id\": uuid})\r\n\tif err != nil {\r\n\t\tlog.Fatal(err)\r\n\t}\r\n\tjson.NewEncoder(w).Encode(objectToDelete.DeletedCount)\r\n\r\n}", "func (a *annotator) TearDown() {\n\ta.publisher.TearDown()\n}", "func Unload(filename string) {\n\tloadedLock.Lock()\n\tdelete(loaded, filename)\n\tloadedLock.Unlock()\n}", "func Teardown() {\n\tfmt.Println(\"====== Clean kubernetes testing pod ======\")\n\tres, err := kubeclient.ExecKubectl(\"kubectl delete pod -l app=nsenter\")\n\tfmt.Println(res)\n\tif err != nil {\n\t\tfmt.Println(\"Error: \" + err.Error())\n\t}\n}", "func (r *Transformer) removeBatch(source string) {\n\tbatch := r.batchMap[source]\n\tdelete(r.batchMap, source)\n\tr.batchPool.Put(batch)\n}", "func (t *NvidiaGPUUpgradeTest) Teardown(ctx context.Context, f *framework.Framework) {\n\t// rely on the namespace deletion to clean up everything\n}", "func BenchmarkDelete(b *testing.B) {\n\ttestingSetUp()\n\tdefer testingTearDown()\n\n\tfor i := 0; i < b.N; i++ {\n\t\tb.StopTimer()\n\t\t// Stop the timer, save a model, then start the timer again\n\t\tmodels, err := createAndSaveTestModels(1)\n\t\tif err != nil {\n\t\t\tb.Fatal(err)\n\t\t}\n\t\tb.StartTimer()\n\t\tif _, err := testModels.Delete(models[0].ModelID()); err != nil {\n\t\t\tb.Fatal(err)\n\t\t}\n\t}\n}", "func (k *k8sService) deleteModules(modules map[string]protos.Module) {\n\tfor name, module := range modules {\n\t\tswitch module.Spec.Type {\n\t\tcase protos.ModuleSpec_DaemonSet:\n\t\t\tk.deleteDaemonSet(name)\n\t\tcase protos.ModuleSpec_Deployment:\n\t\t\tk.deleteDeployment(name)\n\t\tcase protos.ModuleSpec_Job:\n\t\t\tk.deleteCronJob(name)\n\t\t}\n\t}\n}", "func destroy() {\n\tif unique.natsconn != nil {\n\t\tunique.natsconn.Close()\n\t}\n\tfor _, dict := range unique.mdb {\n\t\tdict.Close()\n\t}\n\tunique = nil\n}", "func (h *HealthCheck) cleanup() {\n\tif h.frameworkError != nil && h.namespace != nil {\n\t\tglog.V(4).Infof(\"Cleaning up. Deleting the binding, instance and test namespace %v\", h.namespace.Name)\n\t\th.serviceCatalogClientSet.ServicecatalogV1beta1().ServiceBindings(h.namespace.Name).Delete(h.bindingName, nil)\n\t\th.serviceCatalogClientSet.ServicecatalogV1beta1().ServiceInstances(h.namespace.Name).Delete(h.instanceName, nil)\n\t\tDeleteKubeNamespace(h.kubeClientSet, h.namespace.Name)\n\t\th.namespace = nil\n\t}\n}", "func teardown(dbPaths []string) int {\n\tfor _, v := range dbPaths {\n\t\terr := os.RemoveAll(v)\n\t\tif err != nil {\n\t\t\terrors.New(\"Remove test db file error\")\n\t\t}\n\t}\n\treturn 0\n}", "func deleteRegistry(w http.ResponseWriter, req *http.Request) {\n\tvar sStore SpecificStore\n\t_ = json.NewDecoder(req.Body).Decode(&sStore)\n\n\tif len(array) == 0 {\n\t\tfmt.Println(\"$$$Primero debe llenar el arreglo con informacion\")\n\t\tjson.NewEncoder(w).Encode(\"Primero debe llenar el arreglo con informacion\")\n\t\treturn\n\t}\n\n\tfmt.Println(\"$$$Buscando tienda con los parametros especificados\")\n\tfor i := 0; i < len(array); i++ {\n\t\tif array[i].Department == sStore.Departament && array[i].Rating == sStore.Rating {\n\t\t\tfor j := 0; j < array[i].List.lenght; j++ {\n\t\t\t\ttempNode, _ := array[i].List.GetNodeAt(j)\n\t\t\t\ttempName := tempNode.data.Name\n\t\t\t\tif tempName == sStore.Name {\n\t\t\t\t\tarray[i].List.DeleteNode(j)\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\tprintArray(array)\n\n}", "func Delete(name string) error {\n\tgroupsMutex.Lock()\n\tdefer groupsMutex.Unlock()\n\n\tfor i, g := range Groups {\n\t\tif g.Name == name {\n\t\t\t// Remove JSON\n\t\t\tfilePath := path.Join(Directory, g.Name+\".json\")\n\t\t\tif err := os.Remove(filePath); err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\n\t\t\tGroups = append(Groups[:i], Groups[i+1:]...)\n\t\t\treturn nil\n\t\t}\n\t}\n\treturn errors.New(\"not found\")\n}", "func Unregister(name string) {\n\tif _, ok := factories[name]; !ok {\n\t\tlog.Warningf(\"workflow %v doesn't exist, cannot remove it\", name)\n\t} else {\n\t\tdelete(factories, name)\n\t}\n}", "func (c *TrialController) Delete(w http.ResponseWriter, r *http.Request,\n\tp httprouter.Params) {\n\n\tstudy, trial := p.ByName(\"study\"), p.ByName(\"trial\")\n\n\t// delete all items with these study + trial prefixes\n\tfor _, pre := range []string{\n\t\tfmt.Sprintf(\"/studies/%s/trials/%s\", study, trial),\n\t\tfmt.Sprintf(\"/files/%s/%s\", study, trial),\n\t} {\n\t\titems, err := c.studies.PrefixItems([]byte(pre))\n\t\tif err != nil {\n\t\t\te := fmt.Sprintf(\"couldn't retrieve items with prefix %q: %v\",\n\t\t\t\tpre,\n\t\t\t\terr,\n\t\t\t)\n\t\t\thttp.Error(w, e, 500)\n\t\t\treturn\n\t\t}\n\t\tfor _, item := range items {\n\t\t\tif err := c.studies.Delete(item.Key); err != nil {\n\t\t\t\te := fmt.Sprintf(\"couldn't delete item %q: %v\", item.Key, err)\n\t\t\t\thttp.Error(w, e, 500)\n\t\t\t}\n\t\t}\n\t}\n\n\tw.Header().Set(\"Content-Type\", \"application/json\")\n\tw.WriteHeader(http.StatusOK)\n}", "func (s *Store) cleanup(name string) {\n\titer := s.client.Collection(name).DocumentRefs(context.Background())\n\tfor {\n\t\tdoc, err := iter.Next()\n\t\tif err == iterator.Done {\n\t\t\tbreak\n\t\t}\n\t\tif err != nil {\n\t\t\t// Ignore.\n\t\t}\n\t\t// Ignore errors.\n\t\tdoc.Delete(context.Background())\n\t}\n}", "func switchFinalizer(s *Switch) {\n\truntime.SetFinalizer(s, func(s *Switch) { gobject.Unref(s) })\n}", "func testRemoveMultipleObjects() {\n\t// initialize logging params\n\tstartTime := time.Now()\n\ttestName := getFuncName()\n\tfunction := \"RemoveObjects(bucketName, objectsCh)\"\n\targs := map[string]interface{}{\n\t\t\"bucketName\": \"\",\n\t}\n\n\t// Seed random based on current time.\n\trand.Seed(time.Now().Unix())\n\n\t// Instantiate new minio client object.\n\tc, err := minio.New(os.Getenv(serverEndpoint),\n\t\t&minio.Options{\n\t\t\tCreds: credentials.NewStaticV4(os.Getenv(accessKey), os.Getenv(secretKey), \"\"),\n\t\t\tSecure: mustParseBool(os.Getenv(enableHTTPS)),\n\t\t})\n\tif err != nil {\n\t\tlogError(testName, function, args, startTime, \"\", \"MinIO client object creation failed\", err)\n\t\treturn\n\t}\n\n\t// Set user agent.\n\tc.SetAppInfo(\"MinIO-go-FunctionalTest\", \"0.1.0\")\n\n\t// Enable tracing, write to stdout.\n\t// c.TraceOn(os.Stderr)\n\n\t// Generate a new random bucket name.\n\tbucketName := randString(60, rand.NewSource(time.Now().UnixNano()), \"minio-go-test-\")\n\targs[\"bucketName\"] = bucketName\n\n\t// Make a new bucket.\n\terr = c.MakeBucket(context.Background(), bucketName, minio.MakeBucketOptions{Region: \"us-east-1\"})\n\tif err != nil {\n\t\tlogError(testName, function, args, startTime, \"\", \"MakeBucket failed\", err)\n\t\treturn\n\t}\n\n\tdefer cleanupBucket(bucketName, c)\n\n\tr := bytes.NewReader(bytes.Repeat([]byte(\"a\"), 8))\n\n\t// Multi remove of 1100 objects\n\tnrObjects := 200\n\n\tobjectsCh := make(chan minio.ObjectInfo)\n\n\tgo func() {\n\t\tdefer close(objectsCh)\n\t\t// Upload objects and send them to objectsCh\n\t\tfor i := 0; i < nrObjects; i++ {\n\t\t\tobjectName := \"sample\" + strconv.Itoa(i) + \".txt\"\n\t\t\tinfo, err := c.PutObject(context.Background(), bucketName, objectName, r, 8,\n\t\t\t\tminio.PutObjectOptions{ContentType: \"application/octet-stream\"})\n\t\t\tif err != nil {\n\t\t\t\tlogError(testName, function, args, startTime, \"\", \"PutObject failed\", err)\n\t\t\t\tcontinue\n\t\t\t}\n\t\t\tobjectsCh <- minio.ObjectInfo{\n\t\t\t\tKey: info.Key,\n\t\t\t\tVersionID: info.VersionID,\n\t\t\t}\n\t\t}\n\t}()\n\n\t// Call RemoveObjects API\n\terrorCh := c.RemoveObjects(context.Background(), bucketName, objectsCh, minio.RemoveObjectsOptions{})\n\n\t// Check if errorCh doesn't receive any error\n\tselect {\n\tcase r, more := <-errorCh:\n\t\tif more {\n\t\t\tlogError(testName, function, args, startTime, \"\", \"Unexpected error\", r.Err)\n\t\t\treturn\n\t\t}\n\t}\n\n\tsuccessLogger(testName, function, args, startTime).Info()\n}", "func (spec *Spec) WipeMetrics() {\n\tSpecExpiresBeforeThreshold.DeleteLabelValues(spec.Name)\n\tSpecNextWake.DeleteLabelValues(spec.Name)\n\tSpecWriteCount.DeleteLabelValues(spec.Name)\n\tSpecWriteFailureCount.DeleteLabelValues(spec.Name)\n\tSpecRequestFailureCount.DeleteLabelValues(spec.Name)\n\tfor _, t := range []string{\"ca\", \"cert\", \"key\"} {\n\t\tSpecExpires.DeleteLabelValues(spec.Name, t)\n\t}\n}", "func (t Timers) Delete(k string) {\n\tdelete(t, k)\n}", "func clean(t *testing.T, name string) {\n\terr := os.RemoveAll(name)\n\tif err != nil {\n\t\tt.Error(fmt.Errorf(\"Error during cleanup: %e\", err))\n\t}\n}", "func (s *JobApiTestSuite) cleanUp() {\n\ttest.DeleteAllRuns(s.runClient, s.resourceNamespace, s.T())\n\ttest.DeleteAllJobs(s.jobClient, s.resourceNamespace, s.T())\n\ttest.DeleteAllPipelines(s.pipelineClient, s.T())\n\ttest.DeleteAllExperiments(s.experimentClient, s.resourceNamespace, s.T())\n}", "func (o SkinSlice) DeleteAll(exec boil.Executor) error {\n\tif o == nil {\n\t\treturn errors.New(\"models: no Skin slice provided for delete all\")\n\t}\n\n\tif len(o) == 0 {\n\t\treturn nil\n\t}\n\n\tif len(skinBeforeDeleteHooks) != 0 {\n\t\tfor _, obj := range o {\n\t\t\tif err := obj.doBeforeDeleteHooks(exec); err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\t\t}\n\t}\n\n\tvar args []interface{}\n\tfor _, obj := range o {\n\t\tpkeyArgs := queries.ValuesFromMapping(reflect.Indirect(reflect.ValueOf(obj)), skinPrimaryKeyMapping)\n\t\targs = append(args, pkeyArgs...)\n\t}\n\n\tsql := \"DELETE FROM `skin` WHERE \" +\n\t\tstrmangle.WhereClauseRepeated(string(dialect.LQ), string(dialect.RQ), 0, skinPrimaryKeyColumns, len(o))\n\n\tif boil.DebugMode {\n\t\tfmt.Fprintln(boil.DebugWriter, sql)\n\t\tfmt.Fprintln(boil.DebugWriter, args)\n\t}\n\n\t_, err := exec.Exec(sql, args...)\n\tif err != nil {\n\t\treturn errors.Wrap(err, \"models: unable to delete all from skin slice\")\n\t}\n\n\tif len(skinAfterDeleteHooks) != 0 {\n\t\tfor _, obj := range o {\n\t\t\tif err := obj.doAfterDeleteHooks(exec); err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\t\t}\n\t}\n\n\treturn nil\n}", "func (s Shaper) Destroy() {\n}", "func (b *GoGLBackendOffscreen) Delete() {\n\tgl.DeleteTextures(1, &b.offscrBuf.tex)\n\tgl.DeleteFramebuffers(1, &b.offscrBuf.frameBuf)\n\tgl.DeleteRenderbuffers(1, &b.offscrBuf.renderStencilBuf)\n}", "func (self Sources) Delete() {\n\tn := len(self)\n\tC.walDeleteSources(C.ALsizei(n), unsafe.Pointer(&self[0]))\n}", "func UnloadAll() {\n\tids := handlersStore.ListIDs()\n\tfor _, id := range ids {\n\t\terr := StopHandler(id)\n\t\tif err != nil {\n\t\t\tzap.L().Error(\"error on stopping a handler\", zap.String(\"id\", id))\n\t\t}\n\t}\n}", "func DelElsObj(url string) {\n\tif req, err := http.NewRequest(\"DELETE\", util.ELS_BASE+url, nil); err != nil {\n\t\tlog.Printf(\"Els Create Request Err: %s\\n\", err.Error())\n\t} else if resp, err := http.DefaultClient.Do(req); err != nil {\n\t\tlog.Printf(\"Els Sync Err: %s\\n\", err.Error())\n\t} else if err := resp.Body.Close(); err != nil {\n\t\tlog.Printf(\"Els Close Fp Err: %s\\n\", err.Error())\n\t}\n\n}", "func (s *sink) removeAll(id string) {\n\ts.trieq0.RemoveAll(id)\n}", "func (s *Subscriber) close() {\n for k := range s.topics {\n topic := manager.topics[k]\n delete(topic.subscribers, s.id)\n }\n delete(manager.subscribers, s.id)\n s.ws.Close()\n}", "func (m *prom) DelMetric(name string) {\n\tm.ginMet.Del(name)\n\tm.othMet.Del(name)\n}", "func (a *Aliens) kill() {\n\tfor _, alien := range *a {\n\t\talien.Status = AlienStatusDead\n\t}\n}", "func (obj *StringMap) Delete() {\n\tif obj == nil {\n\t\treturn\n\t}\n\truntime.SetFinalizer(obj, nil)\n\tobj.delete()\n}", "func (agent *SrlAgent) DelTelemetry(jsPath string) {\n\ttelemetryKey := &pb.TelemetryKey{\n\t\tJsPath: jsPath,\n\t}\n\tdeleteRequest := &pb.TelemetryDeleteRequest{\n\t\tKey: []*pb.TelemetryKey{telemetryKey},\n\t}\n\tresponse, err := agent.TelemetryStub.TelemetryDelete(agent.Ctx, deleteRequest)\n\tif err != nil {\n\t\tagent.Logger.Debug(\"Failted to delete Telemetry\")\n\t}\n\tagent.Logger.Debug(\"Response for deleting telemetry \", response.Status)\n}", "func (t *AudioDoppler) Cleanup(a *app.App) {}", "func labelFinalizer(l *Label) {\n\truntime.SetFinalizer(l, func(l *Label) { gobject.Unref(l) })\n}", "func (s *ASG) Teardown(asgc aws.ASGAPI, cwc aws.CWAPI) error {\n\t// Detach LoadBalancers and Targets\n\tif err := s.detach(asgc); err != nil {\n\t\treturn err\n\t}\n\n\t// Delete Alarms\n\talarms, err := s.alarmNames(asgc)\n\tif err != nil {\n\t\treturn err\n\t}\n\n\tif err := s.teardownAlarms(cwc, alarms); err != nil {\n\t\treturn err\n\t}\n\n\t// Delete Group\n\tif err := s.deleteGroup(asgc); err != nil {\n\t\treturn err\n\t}\n\n\t// Delete Launch Config as well\n\tif err := lc.Teardown(asgc, s.LaunchConfigurationName); err != nil {\n\t\treturn err\n\t}\n\n\treturn nil\n}", "func (shuffle *Action) UnInitialize() {}", "func (_m *ServiceBindingUsageLister) DeleteAllByUsageKind(namespace string, kind string, resourceName string) error {\n\tvar r0 error\n\tr0 = _m.err\n\n\treturn r0\n}", "func (s *OssDownloadSuite) TearDownSuite(c *C) {\n\t// Delete Part\n\tlmur, err := s.bucket.ListMultipartUploads()\n\tc.Assert(err, IsNil)\n\n\tfor _, upload := range lmur.Uploads {\n\t\tvar imur = InitiateMultipartUploadResult{Bucket: s.bucket.BucketName,\n\t\t\tKey: upload.Key, UploadID: upload.UploadID}\n\t\terr = s.bucket.AbortMultipartUpload(imur)\n\t\tc.Assert(err, IsNil)\n\t}\n\n\t// Delete Objects\n\tlor, err := s.bucket.ListObjects()\n\tc.Assert(err, IsNil)\n\n\tfor _, object := range lor.Objects {\n\t\terr = s.bucket.DeleteObject(object.Key)\n\t\tc.Assert(err, IsNil)\n\t}\n\n\ttestLogger.Println(\"test download completed\")\n}", "func (rp *ResolverPool) WipeStats() {}", "func Delete(name string) error {\n\tprofile := &performancev2.PerformanceProfile{}\n\tif err := testclient.Client.Get(context.TODO(), types.NamespacedName{Name: name}, profile); err != nil {\n\t\tif errors.IsNotFound(err) {\n\t\t\treturn nil\n\t\t}\n\t\treturn err\n\t}\n\n\tif err := testclient.Client.Delete(context.TODO(), profile); err != nil {\n\t\treturn err\n\t}\n\tkey := client.ObjectKey{\n\t\tName: name,\n\t}\n\treturn WaitForDeletion(key, 2*time.Minute)\n}", "func (r *BasicResampler) Reset() {\n\tr.sampleAggregates = r.sampleAggregates[:0]\n}", "func msaCleaner(msa *multi.Multi) {\n\tfor i := 0; i < msa.Rows(); i++ {\n\t\tid := msa.Row(i).Name()\n\t\tif id == \"consensus\" {\n\t\t\tmsa.Delete(i)\n\t\t}\n\t}\n}", "func deleteSkupperTestScenario(ctx *base.ClusterContext, prefix string) (deleteSteps cli.TestScenario) {\n\n\tdeleteSteps = cli.TestScenario{\n\n\t\tName: prefixName(prefix, \"skupper delete\"),\n\t\tTasks: []cli.SkupperTask{\n\t\t\t// skupper delete - delete and verify resources have been removed\n\t\t\t{\n\t\t\t\tCtx: ctx, Commands: []cli.SkupperCommandTester{\n\t\t\t\t\t&cli.DeleteTester{},\n\t\t\t\t\t&cli.StatusTester{\n\t\t\t\t\t\tNotEnabled: true,\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t},\n\t\t},\n\t}\n\treturn\n}", "func (s *Sampler) Release() {\n\treleaseSampler(s)\n}" ]
[ "0.6354465", "0.62698066", "0.54388016", "0.53542507", "0.5327673", "0.5321178", "0.5281586", "0.5201338", "0.51815957", "0.5168405", "0.51570797", "0.51481396", "0.5139457", "0.51155823", "0.5080379", "0.5068697", "0.5060389", "0.50415576", "0.5026142", "0.50248355", "0.50039977", "0.50009656", "0.4997086", "0.49953485", "0.49800834", "0.49764293", "0.49621114", "0.4926627", "0.4911899", "0.49018407", "0.48953667", "0.48894095", "0.48879796", "0.48832566", "0.4882684", "0.488119", "0.48799795", "0.4875317", "0.48714396", "0.48610273", "0.48566157", "0.485447", "0.48504588", "0.48256537", "0.48101676", "0.48044825", "0.47944012", "0.47930375", "0.47854397", "0.47843266", "0.47747904", "0.4773242", "0.47727537", "0.47726476", "0.47716966", "0.47692406", "0.47627136", "0.47569954", "0.47542506", "0.47539252", "0.47523907", "0.4752157", "0.47495425", "0.47478566", "0.47460085", "0.47453457", "0.47448152", "0.47438574", "0.47367668", "0.47327217", "0.4731697", "0.47242752", "0.47219598", "0.47183385", "0.4718227", "0.47139737", "0.47132477", "0.47112027", "0.4710388", "0.4709996", "0.47099012", "0.47075015", "0.46938857", "0.4692434", "0.46904108", "0.4689518", "0.4677", "0.4671894", "0.4671155", "0.46694306", "0.46573412", "0.46569714", "0.46544015", "0.46446595", "0.46414682", "0.46411723", "0.46406195", "0.46395466", "0.46392715" ]
0.60690266
3
Deletes a shader object
func DeleteShader(shader uint32) { C.glowDeleteShader(gpDeleteShader, (C.GLuint)(shader)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func (shader Shader) Delete() {\n\tgl.DeleteShader(uint32(shader))\n}", "func DeleteShader(shader uint32) {\n C.glowDeleteShader(gpDeleteShader, (C.GLuint)(shader))\n}", "func DeleteShader(s Shader) {\n\tgl.DeleteShader(s.Value)\n}", "func DeleteShader(shader uint32) {\n\tsyscall.Syscall(gpDeleteShader, 1, uintptr(shader), 0, 0)\n}", "func (gl *WebGL) DeleteShader(shader WebGLShader) {\n\tgl.context.Call(\"deleteShader\", shader)\n}", "func (debugging *debuggingOpenGL) DeleteShader(shader uint32) {\n\tdebugging.recordEntry(\"DeleteShader\", shader)\n\tdebugging.gl.DeleteShader(shader)\n\tdebugging.recordExit(\"DeleteShader\")\n}", "func (native *OpenGL) DeleteShader(shader uint32) {\n\tgl.DeleteShader(shader)\n}", "func DeleteShader(shader Uint) {\n\tcshader, _ := (C.GLuint)(shader), cgoAllocsUnknown\n\tC.glDeleteShader(cshader)\n}", "func (s *Shader) Destroy() {\n\ts.destroyVertexShader()\n\ts.destroyFragmentShader()\n\tif s.programID != 0 {\n\t\tgl.DeleteProgram(s.programID)\n\t\ts.programID = 0\n\t}\n}", "func (program Program) Delete() {\n\tgl.DeleteProgram(uint32(program))\n}", "func (n *nativeShader) free() {\n\t// Delete shader objects (in practice we should be able to do this directly\n\t// after linking, but it would just leave the driver to reference count\n\t// them anyway).\n\tgl.DeleteShader(n.vertex)\n\tgl.DeleteShader(n.fragment)\n\n\t// Delete program.\n\tgl.DeleteProgram(n.program)\n\n\t// Zero-out the nativeShader structure, only keeping the rsrcManager around.\n\t*n = nativeShader{\n\t\tr: n.r,\n\t}\n}", "func (texture Texture) Delete() {\n\t// TODO: Is it somehow possible to get &uint32(texture) without assigning it to textures?\n\ttextures := uint32(texture)\n\tgl.DeleteTextures(1, &textures)\n}", "func (t Texture3D) Destroy() {\n\tgl.DeleteTextures(1, &t.id)\n}", "func doDeleteMesh(componentMeshName string) {\n\tcr := visibleMeshes[componentMeshName]\n\tcr.Renderable.Destroy()\n\tcr.Renderable = nil\n\tdelete(visibleMeshes, componentMeshName)\n}", "func DeleteProgram(program uint32) {\n C.glowDeleteProgram(gpDeleteProgram, (C.GLuint)(program))\n}", "func (l *Level) DelObject(gameObject object.GameObject) {\n\tl.mainLayer.deletedIDs[gameObject] = struct{}{}\n}", "func DetachShader(program uint32, shader uint32) {\n C.glowDetachShader(gpDetachShader, (C.GLuint)(program), (C.GLuint)(shader))\n}", "func (renderbuffer Renderbuffer) Delete() {\n\t// TODO: Is it somehow possible to get &uint32(renderbuffer) without assigning it to renderbuffers?\n\trenderbuffers := uint32(renderbuffer)\n\tgl.DeleteRenderbuffers(1, &renderbuffers)\n}", "func DeleteTexture(v Texture) {\n\tgl.DeleteTextures(1, &v.Value)\n}", "func (tx *TextureBase) Delete(sc *Scene) {\n\tif tx.Tex != nil {\n\t\ttx.Tex.Delete()\n\t}\n\ttx.Tex = nil\n}", "func (vao *VAO) Delete() {\n\t// delete buffers\n\tif vao.vertexBuffers != nil {\n\t\tfor _, vertBuf := range vao.vertexBuffers {\n\t\t\tvertBuf.Delete()\n\t\t}\n\t}\n\tvao.indexBuffer.Delete()\n\n\t// delete vertex array\n\tgl.DeleteVertexArrays(1, &vao.handle)\n}", "func DeleteProgram(p Program) {\n\tgl.DeleteProgram(p.Value)\n}", "func DeleteBuffer(v Buffer) {\n\tgl.DeleteBuffers(1, &v.Value)\n}", "func (o *Skin) Delete(exec boil.Executor) error {\n\tif o == nil {\n\t\treturn errors.New(\"models: no Skin provided for delete\")\n\t}\n\n\tif err := o.doBeforeDeleteHooks(exec); err != nil {\n\t\treturn err\n\t}\n\n\targs := queries.ValuesFromMapping(reflect.Indirect(reflect.ValueOf(o)), skinPrimaryKeyMapping)\n\tsql := \"DELETE FROM `skin` WHERE `index`=?\"\n\n\tif boil.DebugMode {\n\t\tfmt.Fprintln(boil.DebugWriter, sql)\n\t\tfmt.Fprintln(boil.DebugWriter, args...)\n\t}\n\n\t_, err := exec.Exec(sql, args...)\n\tif err != nil {\n\t\treturn errors.Wrap(err, \"models: unable to delete from skin\")\n\t}\n\n\tif err := o.doAfterDeleteHooks(exec); err != nil {\n\t\treturn err\n\t}\n\n\treturn nil\n}", "func finalizeShader(n *nativeShader) {\n\tn.r.Lock()\n\n\t// If the shader program is zero, it has already been free'd.\n\tif n.program == 0 {\n\t\tn.r.Unlock()\n\t\treturn\n\t}\n\tn.r.shaders = append(n.r.shaders, n)\n\tn.r.Unlock()\n}", "func (hp *hdfsProvider) DeleteObj(lom *cluster.LOM) (errCode int, err error) {\n\tfilePath := filepath.Join(lom.Bck().Props.Extra.HDFS.RefDirectory, lom.ObjName)\n\tif err := hp.c.Remove(filePath); err != nil {\n\t\terrCode, err = hdfsErrorToAISError(err)\n\t\treturn errCode, err\n\t}\n\tif verbose {\n\t\tnlog.Infof(\"[delete_object] %s\", lom)\n\t}\n\treturn 0, nil\n}", "func (b *GoGLBackendOffscreen) Delete() {\n\tgl.DeleteTextures(1, &b.offscrBuf.tex)\n\tgl.DeleteFramebuffers(1, &b.offscrBuf.frameBuf)\n\tgl.DeleteRenderbuffers(1, &b.offscrBuf.renderStencilBuf)\n}", "func DeleteVertexArrary(n int32, arrays *uint32) {\n\t//gl.DeleteVertexArraysAPPLE(n, arrays)\n\tgl.DeleteVertexArrays(n, arrays)\n}", "func (rl *RayLine) Dispose() {\n\tgl := rl.window.OpenGL()\n\n\tgl.DeleteVertexArrays([]uint32{rl.glVAO})\n\tgl.DeleteProgram(rl.shaderProgram)\n}", "func (r *gui3dRenderer) cleanUp() {\n\t\tr.shader.CleanUp()\n}", "func (native *OpenGL) DeleteProgram(program uint32) {\n\tgl.DeleteProgram(program)\n}", "func (s *Scene) Delete() {\n\ts.propOctree = nil\n\ts.props = nil\n\n\ts.bodyPool = nil\n\ts.dynamicBodies = nil\n\n\ts.firstSBConstraint = nil\n\ts.lastSBConstraint = nil\n\n\ts.firstDBConstraint = nil\n\ts.lastDBConstraint = nil\n}", "func (debugging *debuggingOpenGL) DeleteVertexArrays(arrays []uint32) {\n\tdebugging.recordEntry(\"DeleteVertexArrays\", arrays)\n\tdebugging.gl.DeleteVertexArrays(arrays)\n\tdebugging.recordExit(\"DeleteVertexArrays\")\n}", "func DetachShader(p Program, s Shader) {\n\tgl.DetachShader(p.Value, s.Value)\n}", "func (program Program) DetachShader(shader Shader) {\n\tgl.DetachShader(uint32(program), uint32(shader))\n}", "func (debugging *debuggingOpenGL) DeleteProgram(program uint32) {\n\tdebugging.recordEntry(\"DeleteProgram\", program)\n\tdebugging.gl.DeleteProgram(program)\n\tdebugging.recordExit(\"DeleteProgram\")\n}", "func DetachShader(program uint32, shader uint32) {\n\tsyscall.Syscall(gpDetachShader, 2, uintptr(program), uintptr(shader), 0)\n}", "func (debugging *debuggingOpenGL) DeleteFramebuffers(buffers []uint32) {\n\tdebugging.recordEntry(\"DeleteFramebuffers\", buffers)\n\tdebugging.gl.DeleteFramebuffers(buffers)\n\tdebugging.recordExit(\"DeleteFramebuffers\")\n}", "func (f *Framebuffer) Delete() {\n\tif f.o == nil {\n\t\treturn\n\t}\n\tf.ctx.O.Call(\"deleteFramebuffer\", f.o)\n\tf.o = nil\n}", "func (call CommandHandler) DeleteObject(objID uint16, objType uint8) error {\n\t// https://developers.yubico.com/YubiHSM2/Commands/Delete_Object.html\n\treturn call.nullResponse(CmdDeleteObject.Build(objID, objType))\n}", "func DetachShader(program Uint, shader Uint) {\n\tcprogram, _ := (C.GLuint)(program), cgoAllocsUnknown\n\tcshader, _ := (C.GLuint)(shader), cgoAllocsUnknown\n\tC.glDetachShader(cprogram, cshader)\n}", "func DeleteProgram(program uint32) {\n\tC.glowDeleteProgram(gpDeleteProgram, (C.GLuint)(program))\n}", "func DeleteProgram(program uint32) {\n\tC.glowDeleteProgram(gpDeleteProgram, (C.GLuint)(program))\n}", "func (g *Geometry) Free() {\n\tgl.DeleteVertexArrays(1, &g.handle)\n\tg.IndexBuffer.free()\n\tg.PositionBuffer.free()\n\tg.NormalBuffer.free()\n\tg.TexCoordBuffer.free()\n}", "func DeleteRenderbuffer(v Renderbuffer) {\n\tgl.DeleteRenderbuffers(1, &v.Value)\n}", "func DetachShader(program uint32, shader uint32) {\n\tC.glowDetachShader(gpDetachShader, (C.GLuint)(program), (C.GLuint)(shader))\n}", "func DetachShader(program uint32, shader uint32) {\n\tC.glowDetachShader(gpDetachShader, (C.GLuint)(program), (C.GLuint)(shader))\n}", "func (material *Material) Delete() error {\n\t// Delete the material from all the books that contained it\n\tfor book := range StreamBooks() {\n\t\tif book.Remove(material.ID) {\n\t\t\tbook.Save()\n\t\t}\n\t}\n\n\t// Delete all samples for this material\n\tfor _, sample := range material.Samples() {\n\t\tsample.Delete()\n\t}\n\n\t// Delete all image files\n\tfor _, output := range materialImageOutputs {\n\t\toutput.Delete(material.ID)\n\t}\n\n\tDB.Delete(\"Material\", material.ID)\n\treturn nil\n}", "func DeleteProgram(program Uint) {\n\tcprogram, _ := (C.GLuint)(program), cgoAllocsUnknown\n\tC.glDeleteProgram(cprogram)\n}", "func ReleaseShaderCompiler() {\n C.glowReleaseShaderCompiler(gpReleaseShaderCompiler)\n}", "func (p *ExperimentalPlayground) deleteObject(object engine.Object) error {\n\tp.objectsContainersMux.Lock()\n\tdefer p.objectsContainersMux.Unlock()\n\treturn p.unsafeDeleteObject(object)\n}", "func (r *OutlineRenderer) cleanUp() {\n\tr.shader.CleanUp()\n}", "func (native *OpenGL) DeleteVertexArrays(arrays []uint32) {\n\tgl.DeleteVertexArrays(int32(len(arrays)), &arrays[0])\n}", "func (debugging *debuggingOpenGL) DeleteTextures(textures []uint32) {\n\tdebugging.recordEntry(\"DeleteTextures\", textures)\n\tdebugging.gl.DeleteTextures(textures)\n\tdebugging.recordExit(\"DeleteTextures\")\n}", "func (c *SyscallService) DeleteObject(ctx context.Context, in *pb.DeleteRequest) (*pb.DeleteResponse, error) {\n\tnctx, ok := c.ctxmgr.Context(in.GetHeader().Ctxid)\n\tif !ok {\n\t\treturn nil, fmt.Errorf(\"bad ctx id:%d\", in.Header.Ctxid)\n\t}\n\n\terr := nctx.Cache.Del(nctx.ContractName, in.Key)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\treturn &pb.DeleteResponse{}, nil\n}", "func (debugging *debuggingOpenGL) DeleteBuffers(buffers []uint32) {\n\tdebugging.recordEntry(\"DeleteBuffers\", buffers)\n\tdebugging.gl.DeleteBuffers(buffers)\n\tdebugging.recordExit(\"DeleteBuffers\")\n}", "func (h *Handler) DeleteObject(w http.ResponseWriter, r *http.Request) {\n\tid := chi.URLParam(r, \"id\")\n\n\tlog := logger.Log.WithField(\"requestID\", middleware.GetReqID(r.Context()))\n\n\terr := h.Store.Delete(r.Context(), id)\n\tif err != nil {\n\t\tif err == store.KeyNotFound {\n\t\t\tlog.WithField(\"objectID\", id).Debug(err)\n\t\t\tw.WriteHeader(http.StatusNotFound)\n\t\t} else {\n\t\t\tlog.Error(err)\n\t\t\tw.WriteHeader(http.StatusInternalServerError)\n\t\t}\n\t\treturn\n\t}\n\n\tw.WriteHeader(http.StatusNoContent)\n}", "func (x *FzVertex) Free() {\n\tif x != nil {\n\t\tC.free(unsafe.Pointer(x))\n\t}\n}", "func (c *BaseController) DeleteSingleObject(r *web.Request) (*web.Response, error) {\n\tobjectID := r.PathParams[PathParamID]\n\tctx := r.Context()\n\tlog.C(ctx).Debugf(\"Deleting %s with id %s\", c.objectType, objectID)\n\n\tbyID := query.ByField(query.EqualsOperator, \"id\", objectID)\n\tctx, err := query.AddCriteria(ctx, byID)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\tr.Request = r.WithContext(ctx)\n\n\treturn c.DeleteObjects(r)\n}", "func (w *windowImpl) DeleteTexture(t *textureImpl) {\n\tif w.textures == nil {\n\t\treturn\n\t}\n\tdelete(w.textures, t)\n}", "func DeleteFramebuffer(v Framebuffer) {\n\tgl.DeleteFramebuffers(1, &v.Value)\n}", "func (material *Material) DeleteInContext(ctx *aero.Context) error {\n\treturn material.Delete()\n}", "func deleteObject(w http.ResponseWriter, r *http.Request) {\n\tvars := mux.Vars(r)\n\tkey, _ := strconv.Atoi(vars[\"id\"])\n\tfound := false\n\tlocation := 0\n\n\tfor index := range listOfObjects {\n\t\tif listOfObjects[index].ID == key {\n\t\t\tfound = true\n\t\t\tlocation = index\n\t\t\tbreak\n\t\t}\n\t}\n\n\tif found == true {\n\t\tlistOfObjects = append(listOfObjects[:location], listOfObjects[location+1:]...)\n\t\terr := json.NewEncoder(w).Encode(\"Removed\")\n\t\tif err != nil {\n\t\t\tw.WriteHeader(http.StatusInternalServerError)\n\t\t\tlog.Fatal(\"Error encoding JSON\")\n\t\t}\n\t} else {\n\t\tw.WriteHeader(http.StatusNotFound)\n\t\terr := json.NewEncoder(w).Encode(\"Could not find object\")\n\t\tif err != nil {\n\t\t\tw.WriteHeader(http.StatusInternalServerError)\n\t\t\tlog.Fatal(\"Error encoding JSON\")\n\t\t}\n\t}\n}", "func (native *OpenGL) DeleteTextures(textures []uint32) {\n\tgl.DeleteTextures(int32(len(textures)), &textures[0])\n}", "func (x *FzShade) Free() {\n\tif x != nil {\n\t\tC.free(unsafe.Pointer(x))\n\t}\n}", "func (native *OpenGL) DeleteBuffers(buffers []uint32) {\n\tgl.DeleteBuffers(int32(len(buffers)), &buffers[0])\n}", "func (self *PhysicsP2) RemoveContactMaterial(material *PhysicsP2ContactMaterial) *PhysicsP2ContactMaterial{\n return &PhysicsP2ContactMaterial{self.Object.Call(\"removeContactMaterial\", material)}\n}", "func (o *Source) Delete(exec boil.Executor) error {\n\tif o == nil {\n\t\treturn errors.New(\"mdbmdbmodels: no Source provided for delete\")\n\t}\n\n\targs := queries.ValuesFromMapping(reflect.Indirect(reflect.ValueOf(o)), sourcePrimaryKeyMapping)\n\tsql := \"DELETE FROM \\\"sources\\\" WHERE \\\"id\\\"=$1\"\n\n\tif boil.DebugMode {\n\t\tfmt.Fprintln(boil.DebugWriter, sql)\n\t\tfmt.Fprintln(boil.DebugWriter, args...)\n\t}\n\n\t_, err := exec.Exec(sql, args...)\n\tif err != nil {\n\t\treturn errors.Wrap(err, \"mdbmdbmodels: unable to delete from sources\")\n\t}\n\n\treturn nil\n}", "func delete_asset(stub shim.ChaincodeStubInterface, args []string) ([]byte, error) {\n\tfmt.Println(\"starting delete_asset\")\n\n\tif len(args) != 1 {\n\t\treturn nil, errors.New(\"Incorrect number of arguments. Expecting 2\")\n\t}\n\n\tid := args[0]\n\t// get the asset\n\t_, err := get_asset(stub, id)\n\tif err != nil {\n\t\tfmt.Println(\"Failed to find asset by id \" + id)\n\t\treturn nil, errors.New(err.Error())\n\t}\n\n\t// remove the asset\n\terr = stub.DelState(id) //remove the key from chaincode state\n\tif err != nil {\n\t\treturn nil, errors.New(\"Failed to delete state\")\n\t}\n\n\tfmt.Println(\"- end delete_asset\")\n\treturn nil, nil\n}", "func (sb *SkyBox) Dispose() {\n\tgl := sb.window.OpenGL()\n\n\tgl.DeleteVertexArrays([]uint32{sb.glVAO})\n\tgl.DeleteProgram(sb.shaderProgram)\n}", "func (s *Shader) End() {\n\ts.program.restore()\n}", "func ReleaseShaderCompiler() {\n\tgl.ReleaseShaderCompiler()\n}", "func (fs *Stow) DeleteObject(ctx context.Context, path string) error {\n\tlocation, err := stow.Dial(fs.kind, fs.config)\n\tif err != nil {\n\t\tlog.Errorf(\"stow.Dial fail: %v\", err)\n\t\treturn err\n\t}\n\n\tcontainer, err := location.Container(fs.bucket)\n\tif err != nil {\n\t\tlog.Errorf(\"stow.GetContainer fail: %v\", err)\n\t\treturn err\n\t}\n\n\terr = container.RemoveItem(path)\n\tif err != nil {\n\t\tlog.Errorf(\"stow.Container.RemoveItem fail: %v\", err)\n\t\treturn err\n\t}\n\n\treturn nil\n}", "func ReleaseShaderCompiler() {\n\tC.glReleaseShaderCompiler()\n}", "func (db *InMemDatabase) Delete(obj contrail.IObject) error {\n\tuid := parseUID(obj.GetUuid())\n\tdata, ok := db.objectData[uid]\n\tif !ok {\n\t\treturn fmt.Errorf(\"Object %s: not in database\", obj.GetUuid())\n\t}\n\tif len(data.children) > 0 {\n\t\treturn fmt.Errorf(\"Delete %s: has children %+v\", obj.GetUuid(), data.children)\n\t}\n\tif len(data.backRefs) > 0 {\n\t\treturn fmt.Errorf(\"Delete %s: has references %+v\", obj.GetUuid(), data.backRefs)\n\t}\n\n\tif !data.parent.IsNIL() {\n\t\tdb.deleteChild(data.parent, obj)\n\t\tif parentObj, ok := db.objByIDMap[data.parent]; ok {\n\t\t\tclearReferenceMask(parentObj)\n\t\t}\n\t}\n\tdb.deleteBackReferences(obj, data.refs)\n\n\tdelete(db.objByIDMap, uid)\n\tdelete(db.objectData, uid)\n\ttypeMap, ok := db.typeDB[obj.GetType()]\n\tif !ok {\n\t\treturn fmt.Errorf(\"No objects of type %s\", obj.GetType())\n\t}\n\tfqn := strings.Join(obj.GetFQName(), \":\")\n\tdelete(typeMap, fqn)\n\treturn nil\n}", "func (obj *SObject) Delete(id ...string) error {\n\tif obj.Type() == \"\" || obj.client() == nil {\n\t\t// Sanity check\n\t\treturn ErrFailure\n\t}\n\n\toid := obj.ID()\n\tif id != nil {\n\t\toid = id[0]\n\t}\n\tif oid == \"\" {\n\t\treturn ErrFailure\n\t}\n\n\turl := obj.client().makeURL(\"sobjects/\" + obj.Type() + \"/\" + obj.ID())\n\tlog.Println(url)\n\t_, err := obj.client().httpRequest(http.MethodDelete, url, nil)\n\tif err != nil {\n\t\treturn err\n\t}\n\n\treturn nil\n}", "func (p *ExperimentalPlayground) DeleteObject(object engine.Object, location engine.Location) error {\n\tif !location.Empty() {\n\t\tcontainer, err := p.getContainerByObject(object)\n\t\tif err != nil {\n\t\t\treturn errDeleteObject(err.Error())\n\t\t}\n\t\tp.gameMap.MRemoveContainer(location, container)\n\t}\n\n\tif err := p.deleteObject(object); err != nil {\n\t\treturn errDeleteObject(err.Error())\n\t}\n\n\treturn nil\n}", "func ShadeModel(mode uint32) {\n C.glowShadeModel(gpShadeModel, (C.GLenum)(mode))\n}", "func DeleteSync(sync unsafe.Pointer) {\n C.glowDeleteSync(gpDeleteSync, (C.GLsync)(sync))\n}", "func (g *Goal) Remove(ecs.BasicEntity) {\n\tg.Drawable.Close()\n}", "func (sc *ScreenlyClient) Delete(id string) error {\n\tpath := fmt.Sprintf(\"assets/%s\", id)\n\t_, err := sc.doHttp(\"DELETE\", path, nil)\n\treturn err\n}", "func (gm *GraphicsManager) DeleteComponent(id component.GOiD) {\n\tcomps := gm.compList.Array()\n\tfor i := range comps {\n\t\tif comps[i] == id {\n\t\t\tgm.compList.Erase(i)\n\t\t}\n\t}\n\n\tfor i := range gm.modellink {\n\t\tif gm.deletelink[i] == nil {\n\t\t\tcontinue\n\t\t}\n\t\tgm.deletelink[i] <- id\n\t}\n}", "func (p *ExperimentalPlayground) unsafeDeleteObject(object engine.Object) error {\n\tif !p.unsafeObjectExists(object) {\n\t\treturn errors.New(\"delete object error: object to delete not found\")\n\t}\n\n\tdelete(p.objectsContainers, object)\n\treturn nil\n}", "func DeleteVertexArrays(n int32, arrays *uint32) {\n C.glowDeleteVertexArrays(gpDeleteVertexArrays, (C.GLsizei)(n), (*C.GLuint)(unsafe.Pointer(arrays)))\n}", "func DeleteSamplers(count int32, samplers *uint32) {\n C.glowDeleteSamplers(gpDeleteSamplers, (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(samplers)))\n}", "func (am *Manager) Clean() {\n\tfor name, m := range am.Materials {\n\t\tLogger.Printf(\"Manager: deleting Material '%s'\\n\", name)\n\t\tm.Clean()\n\t\tdelete(am.Materials, name)\n\t}\n\tfor name, m := range am.Meshes {\n\t\tLogger.Printf(\"Manager: deleting Mesh '%s'\\n\", name)\n\t\tm.Clean()\n\t\tdelete(am.Meshes, name)\n\t}\n\tfor set, prog := range am.Programs {\n\t\tLogger.Printf(\"Manager: deleting Program '%v'\\n\", set)\n\t\tgl.DeleteProgram(prog)\n\t\tdelete(am.Programs, set)\n\t}\n\tfor name, shader := range am.Shaders {\n\t\tLogger.Printf(\"Manager: deleting Shader '%s'\\n\", name)\n\t\tgl.DeleteShader(shader)\n\t\tdelete(am.Shaders, name)\n\t}\n\tfor name, tex := range am.Textures {\n\t\tLogger.Printf(\"Manager: deleting Texture '%s'\\n\", name)\n\t\ttex.Clean()\n\t\tdelete(am.Textures, name)\n\t}\n}", "func deleteObject(ctx *context, file string) error {\n\t// Setup\n\tsvc := ctx.svcS3\n\tinput := &s3.DeleteObjectInput{\n\t\tBucket: aws.String(ctx.bucket),\n\t\tKey: aws.String(file),\n\t}\n\n\toutput, err := svc.DeleteObject(input)\n\tawsOutput(output.GoString())\n\tif err != nil {\n\t\treturn handle(\"Error in deleting object.\", err)\n\t}\n\treturn err\n}", "func (asset Asset) Delete() error {\n\tres, err := asset.model.db.DB.Exec(\"delete from Assets where name = ?\", asset.Name)\n\tif err != nil {\n\t\treturn err\n\t}\n\n\trowsDeleted, rowsDeletedErr := res.RowsAffected()\n\tif rowsDeletedErr == nil && rowsDeleted != 1 {\n\t\treturn fmt.Errorf(\"Asset.Delete should delete exactly 1 row. Instead, returned %d\", rowsDeleted)\n\t}\n\n\treturn nil\n}", "func DeleteBuffers(buffers []Buffer) {\n\tgl.DeleteBuffers(gl.Sizei(len(buffers)), (*gl.Uint)(&buffers[0]))\n}", "func (self *Graphics) Destroy1O(destroyChildren bool) {\n self.Object.Call(\"destroy\", destroyChildren)\n}", "func (o ORM) Delete(ctx context.Context, tx *sql.Tx, obj *object.Object) (int64, error) {\n\tsg := o.sqlGen\n\n\tselect {\n\tcase <-ctx.Done():\n\t\treturn 0, ctx.Err()\n\tdefault:\n\t}\n\n\tobjTable := o.s.GetTable(obj.Type)\n\tif objTable == nil {\n\t\treturn 0, errors.New(\"Delete: unknown object table \" + obj.Type)\n\t}\n\tsqlStr, bindWhere, err := sg.BindingDelete(o.sqlGen, o.s, obj)\n\tif err != nil {\n\t\treturn 0, err\n\t}\n\tif sg.Tracing {\n\t\tfmt.Printf(\"Delete: sqlStr->%s, bindWhere->%v\\n\", sqlStr, bindWhere)\n\t}\n\n\tstmt, err := stmtFromDbOrTx(ctx, o, tx, sqlStr)\n\tif err != nil {\n\t\treturn 0, err\n\t}\n\n\tdefer func() {\n\t\tstmtErr := stmt.Close()\n\t\tif stmtErr != nil {\n\t\t\tfmt.Println(stmtErr) // TODO: logger implementation\n\t\t}\n\t}()\n\n\tres, err := stmt.ExecContext(ctx, bindWhere...)\n\tif err != nil {\n\t\treturn 0, errors.Wrap(err, \"Delete\")\n\t}\n\n\trowsAff, err := res.RowsAffected()\n\tif err != nil {\n\t\treturn 0, err\n\t}\n\n\tobj.MarkDirty(false) // Flag that the object has been recently saved\n\tobj.ResetChangedColumns() // Reset the 'changed fields', if any\n\n\treturn rowsAff, nil\n\n}", "func deleteFile(ctx context.Context, baseDir, hash, extension string) error {\n\t// Verify object exists.\n\tfilepath := getPathByHash(ctx, baseDir, hash, extension)\n\n\treturn os.Remove(filepath)\n}", "func DeleteSamplers(count int32, samplers *uint32) {\n\tC.glowDeleteSamplers(gpDeleteSamplers, (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(samplers)))\n}", "func DeleteSamplers(count int32, samplers *uint32) {\n\tC.glowDeleteSamplers(gpDeleteSamplers, (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(samplers)))\n}", "func (s *Shader) ID() uint32 {\n\treturn s.program.obj\n}", "func ClearStencil(s int32) {\n C.glowClearStencil(gpClearStencil, (C.GLint)(s))\n}", "func (h *Heap) Delete(obj interface{}) error {\n\tkey, err := h.data.keyFunc(obj)\n\tif err != nil {\n\t\treturn cache.KeyError{Obj: obj, Err: err}\n\t}\n\tif item, ok := h.data.items[key]; ok {\n\t\theap.Remove(h.data, item.index)\n\t\tif h.metricRecorder != nil {\n\t\t\th.metricRecorder.Dec()\n\t\t}\n\t\treturn nil\n\t}\n\treturn fmt.Errorf(\"object not found\")\n}", "func RemoveSpecificMaterialHandler(w http.ResponseWriter, r *http.Request) {\n\tvars := mux.Vars(r)\n\tvar m Material\n\tvar c Course\n\t// taking note of old material metadata so that can delete file\n\tq2 := \"Select * FROM MATERIAL WHERE MATERIAL_ID = ?\"\n\tlog.Printf(\"QUERY: %s, %s\\n\", q2, vars[\"id\"])\n\terr := DB.QueryRow(q2, vars[\"id\"]).Scan(&m.Id, &m.Sequence, &m.FileName, &c.Code)\n\tlog.Println(\"QUERY closed\")\n\tif err != nil {\n\t\tif err == sql.ErrNoRows {\n\t\t\tlog.Println(err)\n\t\t\tw.WriteHeader(http.StatusNotFound)\n\t\t} else {\n\t\t\tlog.Println(err)\n\t\t\tw.WriteHeader(http.StatusInternalServerError)\n\t\t}\n\t}\n\t// delete material files from db\n\tq := \"DELETE FROM MATERIAL WHERE MATERIAL_ID = ?\"\n\tif err := ExecQuery(w, q, vars[\"id\"]); err != nil {\n\t\treturn\n\t}\n\t// remove specified course material\n\tloc := fmt.Sprintf(\"download/%s/%d\", vars[\"code\"], m.Sequence)\n\tif err := removeLoc(loc); err != nil {\n\t\tw.WriteHeader(http.StatusInsufficientStorage)\n\t\treturn\n\t}\n\t// remove zip file\n\tloc = fmt.Sprintf(\"download/%s.zip\", vars[\"code\"])\n\tif err := removeLoc(loc); err != nil {\n\t\tw.WriteHeader(http.StatusInsufficientStorage)\n\t\treturn\n\t}\n\tzipUpMaterials(vars[\"code\"])\n\t// sends 200 OK by default\n}", "func (p *PlanetHandler) Delete(c *fiber.Ctx) error {\n\tidP := c.Params(\"id\")\n\n\tif idP == \"\" {\n\t\treturn c.Status(fiber.StatusBadRequest).JSON(domain.ErrBadParamInput.Error())\n\t}\n\n\terr := p.PUsecase.Delete(idP)\n\n\tif err != nil {\n\t\treturn c.Status(getStatusCode(err)).JSON(ResponseError{Message: err.Error()})\n\t}\n\n\treturn c.Status(fiber.StatusNoContent).JSON(\"\")\n}" ]
[ "0.7792453", "0.7540871", "0.7343394", "0.7238463", "0.71194106", "0.7069882", "0.70691085", "0.70324314", "0.6356121", "0.6150891", "0.60111976", "0.59977674", "0.5948428", "0.5945306", "0.58856833", "0.58786726", "0.58763504", "0.587515", "0.58290154", "0.569516", "0.56913936", "0.5659665", "0.5633506", "0.5610984", "0.55817276", "0.5567378", "0.55570143", "0.55431694", "0.547454", "0.54599935", "0.5453459", "0.5452233", "0.5451285", "0.54463714", "0.5446099", "0.54447955", "0.53954935", "0.5386093", "0.5369253", "0.53690207", "0.53255665", "0.53084844", "0.53084844", "0.52957505", "0.5288134", "0.5282617", "0.5282617", "0.52690446", "0.52584475", "0.5245562", "0.5226923", "0.52234846", "0.5212033", "0.51777256", "0.514411", "0.51169616", "0.5106746", "0.5051618", "0.50515205", "0.5038112", "0.5035886", "0.50240844", "0.5023645", "0.5009279", "0.49790865", "0.4976898", "0.49443612", "0.49360523", "0.49310443", "0.49129063", "0.49025062", "0.48969603", "0.4894644", "0.4894117", "0.48882067", "0.48853284", "0.48776466", "0.48770884", "0.48734653", "0.48575866", "0.4853161", "0.48522973", "0.4848525", "0.48483187", "0.48464304", "0.48381683", "0.4831754", "0.4822799", "0.48084676", "0.48054576", "0.48026422", "0.47937468", "0.47850603", "0.47850603", "0.47826767", "0.47688064", "0.47676986", "0.47647196", "0.47543353" ]
0.71381307
5
delete a sync object
func DeleteSync(sync uintptr) { C.glowDeleteSync(gpDeleteSync, (C.GLsync)(sync)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func (api *objectAPI) SyncDelete(obj *objstore.Object) error {\n\tvar writeErr error\n\tif api.ct.resolver != nil {\n\t\tapicl, err := api.ct.apiClient()\n\t\tif err != nil {\n\t\t\tapi.ct.logger.Errorf(\"Error creating API server clent. Err: %v\", err)\n\t\t\treturn err\n\t\t}\n\n\t\t_, writeErr = apicl.ObjstoreV1().Object().Delete(context.Background(), &obj.ObjectMeta)\n\t}\n\n\tif writeErr == nil {\n\t\tapi.ct.handleObjectEvent(&kvstore.WatchEvent{Object: obj, Type: kvstore.Deleted})\n\t}\n\n\treturn writeErr\n}", "func (api *snapshotrestoreAPI) SyncDelete(obj *cluster.SnapshotRestore) error {\n\tvar writeErr error\n\tif api.ct.resolver != nil {\n\t\tapicl, err := api.ct.apiClient()\n\t\tif err != nil {\n\t\t\tapi.ct.logger.Errorf(\"Error creating API server clent. Err: %v\", err)\n\t\t\treturn err\n\t\t}\n\n\t\t_, writeErr = apicl.ClusterV1().SnapshotRestore().Delete(context.Background(), &obj.ObjectMeta)\n\t}\n\n\tif writeErr == nil {\n\t\tapi.ct.handleSnapshotRestoreEvent(&kvstore.WatchEvent{Object: obj, Type: kvstore.Deleted})\n\t}\n\n\treturn writeErr\n}", "func DeleteSync(sync uintptr) {\n\tsyscall.Syscall(gpDeleteSync, 1, uintptr(sync), 0, 0)\n}", "func (api *bucketAPI) SyncDelete(obj *objstore.Bucket) error {\n\tvar writeErr error\n\tif api.ct.resolver != nil {\n\t\tapicl, err := api.ct.apiClient()\n\t\tif err != nil {\n\t\t\tapi.ct.logger.Errorf(\"Error creating API server clent. Err: %v\", err)\n\t\t\treturn err\n\t\t}\n\n\t\t_, writeErr = apicl.ObjstoreV1().Bucket().Delete(context.Background(), &obj.ObjectMeta)\n\t}\n\n\tif writeErr == nil {\n\t\tapi.ct.handleBucketEvent(&kvstore.WatchEvent{Object: obj, Type: kvstore.Deleted})\n\t}\n\n\treturn writeErr\n}", "func (api *versionAPI) SyncDelete(obj *cluster.Version) error {\n\tvar writeErr error\n\tif api.ct.resolver != nil {\n\t\tapicl, err := api.ct.apiClient()\n\t\tif err != nil {\n\t\t\tapi.ct.logger.Errorf(\"Error creating API server clent. Err: %v\", err)\n\t\t\treturn err\n\t\t}\n\n\t\t_, writeErr = apicl.ClusterV1().Version().Delete(context.Background(), &obj.ObjectMeta)\n\t}\n\n\tif writeErr == nil {\n\t\tapi.ct.handleVersionEvent(&kvstore.WatchEvent{Object: obj, Type: kvstore.Deleted})\n\t}\n\n\treturn writeErr\n}", "func (api *hostAPI) SyncDelete(obj *cluster.Host) error {\n\tvar writeErr error\n\tif api.ct.resolver != nil {\n\t\tapicl, err := api.ct.apiClient()\n\t\tif err != nil {\n\t\t\tapi.ct.logger.Errorf(\"Error creating API server clent. Err: %v\", err)\n\t\t\treturn err\n\t\t}\n\n\t\t_, writeErr = apicl.ClusterV1().Host().Delete(context.Background(), &obj.ObjectMeta)\n\t}\n\n\tif writeErr == nil {\n\t\tapi.ct.handleHostEvent(&kvstore.WatchEvent{Object: obj, Type: kvstore.Deleted})\n\t}\n\n\treturn writeErr\n}", "func (s *FederationSyncController) delete(obj pkgruntime.Object, kind string, namespacedName types.NamespacedName) error {\n\tglog.V(3).Infof(\"Handling deletion of %s %q\", kind, namespacedName)\n\t_, err := s.deletionHelper.HandleObjectInUnderlyingClusters(obj)\n\tif err != nil {\n\t\treturn err\n\t}\n\n\terr = s.adapter.FedDelete(namespacedName, nil)\n\tif err != nil {\n\t\t// Its all good if the error is not found error. That means it is deleted already and we do not have to do anything.\n\t\t// This is expected when we are processing an update as a result of finalizer deletion.\n\t\t// The process that deleted the last finalizer is also going to delete the resource and we do not have to do anything.\n\t\tif !errors.IsNotFound(err) {\n\t\t\treturn err\n\t\t}\n\t}\n\treturn nil\n}", "func (api *distributedservicecardAPI) SyncDelete(obj *cluster.DistributedServiceCard) error {\n\tvar writeErr error\n\tif api.ct.resolver != nil {\n\t\tapicl, err := api.ct.apiClient()\n\t\tif err != nil {\n\t\t\tapi.ct.logger.Errorf(\"Error creating API server clent. Err: %v\", err)\n\t\t\treturn err\n\t\t}\n\n\t\t_, writeErr = apicl.ClusterV1().DistributedServiceCard().Delete(context.Background(), &obj.ObjectMeta)\n\t}\n\n\tif writeErr == nil {\n\t\tapi.ct.handleDistributedServiceCardEvent(&kvstore.WatchEvent{Object: obj, Type: kvstore.Deleted})\n\t}\n\n\treturn writeErr\n}", "func (client StorageGatewayClient) deleteCloudSync(ctx context.Context, request common.OCIRequest) (common.OCIResponse, error) {\n\thttpRequest, err := request.HTTPRequest(http.MethodDelete, \"/storageGateways/{storageGatewayId}/cloudSyncs/{cloudSyncName}\")\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\n\tvar response DeleteCloudSyncResponse\n\tvar httpResponse *http.Response\n\thttpResponse, err = client.Call(ctx, &httpRequest)\n\tdefer common.CloseBodyIfValid(httpResponse)\n\tresponse.RawResponse = httpResponse\n\tif err != nil {\n\t\treturn response, err\n\t}\n\n\terr = common.UnmarshalResponse(httpResponse, &response)\n\treturn response, err\n}", "func (api *clusterAPI) SyncDelete(obj *cluster.Cluster) error {\n\tvar writeErr error\n\tif api.ct.resolver != nil {\n\t\tapicl, err := api.ct.apiClient()\n\t\tif err != nil {\n\t\t\tapi.ct.logger.Errorf(\"Error creating API server clent. Err: %v\", err)\n\t\t\treturn err\n\t\t}\n\n\t\t_, writeErr = apicl.ClusterV1().Cluster().Delete(context.Background(), &obj.ObjectMeta)\n\t}\n\n\tif writeErr == nil {\n\t\tapi.ct.handleClusterEvent(&kvstore.WatchEvent{Object: obj, Type: kvstore.Deleted})\n\t}\n\n\treturn writeErr\n}", "func (s *RemoveResourceSyncer) Sync(ctx context.Context) (SyncResult, error) {\n\tresult := SyncResult{}\n\tlog := logf.FromContext(ctx, \"syncer\", s.Name)\n\tkey := client.ObjectKeyFromObject(s.Obj)\n\n\tresult.Operation = controllerutil.OperationResultNone\n\n\t// fetch the resource\n\tif err := s.Client.Get(ctx, key, s.Obj); err != nil {\n\t\tif k8serrors.IsNotFound(err) {\n\t\t\treturn result, nil\n\t\t}\n\n\t\tlog.Error(err, string(result.Operation), \"key\", key, \"kind\", objectType(s.Obj, s.Client))\n\n\t\treturn result, fmt.Errorf(\"error when fetching resource: %w\", err)\n\t}\n\n\t// delete the resource\n\tif err := s.Client.Delete(ctx, s.Obj); err != nil {\n\t\tlog.Error(err, string(result.Operation), \"key\", key, \"kind\", objectType(s.Obj, s.Client))\n\n\t\treturn result, fmt.Errorf(\"error when deleting resource: %w\", err)\n\t}\n\n\tresult.Operation = controllerutil.OperationResult(\"deleted\")\n\tresult.SetEventData(eventNormal, basicEventReason(s.Name, nil), fmt.Sprintf(\"%s %s successfully deleted\", objectType(s.Obj, s.Client), key))\n\n\tlog.V(1).Info(string(result.Operation), \"key\", key, \"kind\", objectType(s.Obj, s.Client))\n\n\treturn result, nil\n}", "func (api *licenseAPI) SyncDelete(obj *cluster.License) error {\n\tvar writeErr error\n\tif api.ct.resolver != nil {\n\t\tapicl, err := api.ct.apiClient()\n\t\tif err != nil {\n\t\t\tapi.ct.logger.Errorf(\"Error creating API server clent. Err: %v\", err)\n\t\t\treturn err\n\t\t}\n\n\t\t_, writeErr = apicl.ClusterV1().License().Delete(context.Background(), &obj.ObjectMeta)\n\t}\n\n\tif writeErr == nil {\n\t\tapi.ct.handleLicenseEvent(&kvstore.WatchEvent{Object: obj, Type: kvstore.Deleted})\n\t}\n\n\treturn writeErr\n}", "func (api *nodeAPI) SyncDelete(obj *cluster.Node) error {\n\tvar writeErr error\n\tif api.ct.resolver != nil {\n\t\tapicl, err := api.ct.apiClient()\n\t\tif err != nil {\n\t\t\tapi.ct.logger.Errorf(\"Error creating API server clent. Err: %v\", err)\n\t\t\treturn err\n\t\t}\n\n\t\t_, writeErr = apicl.ClusterV1().Node().Delete(context.Background(), &obj.ObjectMeta)\n\t}\n\n\tif writeErr == nil {\n\t\tapi.ct.handleNodeEvent(&kvstore.WatchEvent{Object: obj, Type: kvstore.Deleted})\n\t}\n\n\treturn writeErr\n}", "func (api *dscprofileAPI) SyncDelete(obj *cluster.DSCProfile) error {\n\tvar writeErr error\n\tif api.ct.resolver != nil {\n\t\tapicl, err := api.ct.apiClient()\n\t\tif err != nil {\n\t\t\tapi.ct.logger.Errorf(\"Error creating API server clent. Err: %v\", err)\n\t\t\treturn err\n\t\t}\n\n\t\t_, writeErr = apicl.ClusterV1().DSCProfile().Delete(context.Background(), &obj.ObjectMeta)\n\t}\n\n\tif writeErr == nil {\n\t\tapi.ct.handleDSCProfileEvent(&kvstore.WatchEvent{Object: obj, Type: kvstore.Deleted})\n\t}\n\n\treturn writeErr\n}", "func DeleteSync(sync unsafe.Pointer) {\n C.glowDeleteSync(gpDeleteSync, (C.GLsync)(sync))\n}", "func (c *VCClient) DeleteSync(name string, options *metav1.DeleteOptions) {\n\terr := c.Delete(name, options)\n\tExpectNoError(err, \"failed to delete vc\")\n\tExpectNoError(c.f.WaitForVCNotFound(name), \"waiting virtualcluster to be completed deleted\")\n}", "func (api *configurationsnapshotAPI) SyncDelete(obj *cluster.ConfigurationSnapshot) error {\n\tvar writeErr error\n\tif api.ct.resolver != nil {\n\t\tapicl, err := api.ct.apiClient()\n\t\tif err != nil {\n\t\t\tapi.ct.logger.Errorf(\"Error creating API server clent. Err: %v\", err)\n\t\t\treturn err\n\t\t}\n\n\t\t_, writeErr = apicl.ClusterV1().ConfigurationSnapshot().Delete(context.Background(), &obj.ObjectMeta)\n\t}\n\n\tif writeErr == nil {\n\t\tapi.ct.handleConfigurationSnapshotEvent(&kvstore.WatchEvent{Object: obj, Type: kvstore.Deleted})\n\t}\n\n\treturn writeErr\n}", "func (db *TriasDB) DeleteSync(key []byte) {\n\tdb.mtx.Lock()\n\tdefer db.mtx.Unlock()\n\n\tdb.DeleteNoLock(key)\n}", "func (api *credentialsAPI) SyncDelete(obj *cluster.Credentials) error {\n\tvar writeErr error\n\tif api.ct.resolver != nil {\n\t\tapicl, err := api.ct.apiClient()\n\t\tif err != nil {\n\t\t\tapi.ct.logger.Errorf(\"Error creating API server clent. Err: %v\", err)\n\t\t\treturn err\n\t\t}\n\n\t\t_, writeErr = apicl.ClusterV1().Credentials().Delete(context.Background(), &obj.ObjectMeta)\n\t}\n\n\tif writeErr == nil {\n\t\tapi.ct.handleCredentialsEvent(&kvstore.WatchEvent{Object: obj, Type: kvstore.Deleted})\n\t}\n\n\treturn writeErr\n}", "func (c *Cache) deleteWorkload(pcacheObj interface{}) error {\n\tctrler := c.stateMgr.Controller()\n\tswitch obj := pcacheObj.(type) {\n\tcase *defs.VCHubWorkload:\n\t\tvar writeErr error\n\t\tmeta := obj.GetObjectMeta()\n\t\tif _, err := ctrler.Workload().Find(meta); err == nil {\n\t\t\t// Object exists\n\t\t\twriteErr = ctrler.Workload().SyncDelete(obj.Workload)\n\t\t}\n\t\treturn writeErr\n\t}\n\treturn fmt.Errorf(\"DeleteWorkload called for unsupported object %T\", pcacheObj)\n}", "func (client *MockClient) Delete(context ctx.Context, object ctrlClient.Object, options ...ctrlClient.DeleteOption) error {\n\tkindKey, err := buildKindKey(object)\n\tif err != nil {\n\t\treturn err\n\t}\n\n\tclient.fillInMaps(kindKey)\n\n\tobjectKey, err := buildRuntimeObjectKey(object)\n\tif err != nil {\n\t\treturn err\n\t}\n\n\terr = client.checkPresence(kindKey, objectKey)\n\tif err != nil {\n\t\treturn err\n\t}\n\n\tstuckTerminating := client.stuckTerminatingObjects != nil && client.stuckTerminatingObjects[kindKey] != nil && client.stuckTerminatingObjects[kindKey][objectKey]\n\tif !stuckTerminating {\n\t\tdelete(client.data[kindKey], objectKey)\n\t}\n\n\treturn nil\n}", "func (s *Server) objectDelete(\n\tsess *pb.Session,\n\tuuids []string,\n) error {\n\treq := &pb.ObjectDeleteByUuidsRequest{\n\t\tSession: sess,\n\t\tUuids: uuids,\n\t}\n\tmc, err := s.metaClient()\n\tif err != nil {\n\t\treturn err\n\t}\n\t_, err = mc.ObjectDeleteByUuids(context.Background(), req)\n\tif err != nil {\n\t\treturn err\n\t}\n\treturn nil\n}", "func (api *tenantAPI) SyncDelete(obj *cluster.Tenant) error {\n\tvar writeErr error\n\tif api.ct.resolver != nil {\n\t\tapicl, err := api.ct.apiClient()\n\t\tif err != nil {\n\t\t\tapi.ct.logger.Errorf(\"Error creating API server clent. Err: %v\", err)\n\t\t\treturn err\n\t\t}\n\n\t\t_, writeErr = apicl.ClusterV1().Tenant().Delete(context.Background(), &obj.ObjectMeta)\n\t}\n\n\tif writeErr == nil {\n\t\tapi.ct.handleTenantEvent(&kvstore.WatchEvent{Object: obj, Type: kvstore.Deleted})\n\t}\n\n\treturn writeErr\n}", "func DeleteObject(ctx context.Context, rootId string) (rep string, err error) {\n\t// 1. gui lenh RemoveItself toi chinh no, khi do, cac child cua no se phai tu unsubscribe\n\trep, err = sendRemoveItselfCommand(ctx, rootId)\n\tif err != nil {\n\t\tLoggingClient.Error(err.Error())\n\t}\n\t// 2. xoa Object nay trong Procols cua cac Parent. Chi can xoa trong MetaData, khong can gui lenh\n\tfor parentId := range cacheGetParents(rootId) {\n\t\tparentObject, err := clientMetaDevice.Device(parentId, ctx)\n\t\tif err == nil {\n\t\t\tdeleteElementInProtocols(parentObject.Protocols, rootId)\n\t\t\terr = clientMetaDevice.Update(parentObject, ctx)\n\t\t\tif err != nil {\n\t\t\t\tLoggingClient.Error(err.Error())\n\t\t\t}\n\t\t}\n\t}\n\t// 3. xoa cac SubObject trong MetaData & xoa rootObject\n\t// doi voi DeviceType, Sub trung voi Root nen bo qua phan xoa SubObject\n\tif cacheGetType(rootId) != DEVICETYPE {\n\t\tlistOb, _ := clientMetaDevice.DevicesByLabel(rootId, ctx)\n\t\tfor _, sub := range listOb {\n\t\t\tfmt.Println(\"delete subObject \", sub.Id)\n\t\t\tclientMetaDevice.Delete(sub.Id, ctx)\n\t\t\tcacheDeleteMapHasName(sub.Name)\n\t\t}\n\t}\n\t// xoa RootObject\n\terr = clientMetaDevice.Delete(rootId, ctx)\n\t// 4. xoa Object trong MapRoot & xoa trong MapID\n\tcacheDeleteRoot(rootId)\n\treturn\n}", "func (api *objectAPI) Delete(obj *objstore.Object) error {\n\tif api.ct.resolver != nil {\n\t\tapicl, err := api.ct.apiClient()\n\t\tif err != nil {\n\t\t\tapi.ct.logger.Errorf(\"Error creating API server clent. Err: %v\", err)\n\t\t\treturn err\n\t\t}\n\n\t\t_, err = apicl.ObjstoreV1().Object().Delete(context.Background(), &obj.ObjectMeta)\n\t\treturn err\n\t}\n\n\tapi.ct.handleObjectEvent(&kvstore.WatchEvent{Object: obj, Type: kvstore.Deleted})\n\treturn nil\n}", "func (call CommandHandler) DeleteObject(objID uint16, objType uint8) error {\n\t// https://developers.yubico.com/YubiHSM2/Commands/Delete_Object.html\n\treturn call.nullResponse(CmdDeleteObject.Build(objID, objType))\n}", "func (p *ExperimentalPlayground) deleteObject(object engine.Object) error {\n\tp.objectsContainersMux.Lock()\n\tdefer p.objectsContainersMux.Unlock()\n\treturn p.unsafeDeleteObject(object)\n}", "func (c *SyscallService) DeleteObject(ctx context.Context, in *pb.DeleteRequest) (*pb.DeleteResponse, error) {\n\tnctx, ok := c.ctxmgr.Context(in.GetHeader().Ctxid)\n\tif !ok {\n\t\treturn nil, fmt.Errorf(\"bad ctx id:%d\", in.Header.Ctxid)\n\t}\n\n\terr := nctx.Cache.Del(nctx.ContractName, in.Key)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\treturn &pb.DeleteResponse{}, nil\n}", "func (obj *MessengerFileCipher) Delete() {\n\tif obj == nil {\n\t\treturn\n\t}\n\truntime.SetFinalizer(obj, nil)\n\tobj.delete()\n}", "func deleteManagedResource(ctx context.Context, cli client.Client, key client.ObjectKey, o client.Object) error {\n\terr := cli.Get(ctx, key, o)\n\tif k8s_errors.IsNotFound(err) || !isManagedResource(o) {\n\t\treturn nil\n\t} else if err != nil {\n\t\treturn fmt.Errorf(\"failed to find stale resource %s: %w\", key, err)\n\t}\n\terr = cli.Delete(ctx, o)\n\tif err != nil {\n\t\treturn fmt.Errorf(\"failed to delete stale resource %s: %w\", key, err)\n\t}\n\treturn nil\n}", "func (obj *RawCardSigner) Delete() {\n\tif obj == nil {\n\t\treturn\n\t}\n\truntime.SetFinalizer(obj, nil)\n\tobj.delete()\n}", "func (b NeteaseNOSBackend) DeleteObject(path string) error {\n\tkey := pathutil.Join(b.Prefix, path)\n\n\tobjectRequest := &model.ObjectRequest{\n\t\tBucket: b.Bucket,\n\t\tObject: key,\n\t}\n\n\terr := b.Client.DeleteObject(objectRequest)\n\treturn err\n}", "func (r *reflectorStore) Delete(obj interface{}) error {\n\tr.mu.Lock()\n\tdefer r.mu.Unlock()\n\n\tvar kind workloadmeta.Kind\n\tvar uid types.UID\n\tif pod, ok := obj.(*corev1.Pod); ok {\n\t\tkind = workloadmeta.KindKubernetesPod\n\t\tuid = pod.UID\n\t} else if node, ok := obj.(*corev1.Node); ok {\n\t\tkind = workloadmeta.KindKubernetesNode\n\t\tuid = node.UID\n\t}\n\n\tr.hasSynced = true\n\tdelete(r.seen, string(uid))\n\n\tr.wlmetaStore.Notify([]workloadmeta.CollectorEvent{\n\t\t{\n\t\t\tType: workloadmeta.EventTypeUnset,\n\t\t\tSource: collectorID,\n\t\t\tEntity: &workloadmeta.KubernetesPod{\n\t\t\t\tEntityID: workloadmeta.EntityID{\n\t\t\t\t\tKind: kind,\n\t\t\t\t\tID: string(uid),\n\t\t\t\t},\n\t\t\t},\n\t\t},\n\t})\n\n\treturn nil\n}", "func (m *Manager) remove(vdiskID string) {\n\tm.mux.Lock()\n\tdefer m.mux.Unlock()\n\n\tdelete(m.syncers, vdiskID)\n}", "func (o *SwiftObject) Delete(metadata map[string]string) error {\n\tif _, err := o.newFile(\"ts\", 0); err != nil {\n\t\treturn err\n\t} else {\n\t\tdefer o.Close()\n\t\treturn o.Commit(metadata)\n\t}\n}", "func (c *BaseController) DeleteSingleObject(r *web.Request) (*web.Response, error) {\n\tresourceID := r.PathParams[web.PathParamResourceID]\n\tctx := r.Context()\n\tlog.C(ctx).Debugf(\"Deleting %s with id %s\", c.objectType, resourceID)\n\n\tbyID := query.ByField(query.EqualsOperator, \"id\", resourceID)\n\tctx, err := query.AddCriteria(ctx, byID)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\tr.Request = r.WithContext(ctx)\n\tcriteria := query.CriteriaForContext(ctx)\n\topCtx := c.prepareOperationContextByRequest(r)\n\n\taction := func(ctx context.Context, repository storage.Repository) (types.Object, error) {\n\t\t// At this point, the resource will be already deleted if cascade operation requested.\n\t\tif c.supportsCascadeDelete && opCtx.Cascade {\n\t\t\treturn nil, nil\n\t\t}\n\t\terr := repository.Delete(ctx, c.objectType, criteria...)\n\t\treturn nil, util.HandleStorageError(err, c.objectType.String())\n\t}\n\n\tUUID, err := uuid.NewV4()\n\tif err != nil {\n\t\treturn nil, fmt.Errorf(\"could not generate GUID for %s: %s\", c.objectType, err)\n\t}\n\tvar cascadeRootId = \"\"\n\tif opCtx.Cascade {\n\t\tif c.supportsCascadeDelete {\n\t\t\t// Scan if requested resource really exists\n\t\t\tresources, err := c.repository.List(ctx, c.objectType, criteria...)\n\t\t\tif err != nil {\n\t\t\t\treturn nil, util.HandleStorageError(err, c.objectType.String())\n\t\t\t}\n\t\t\tif resources.Len() == 0 {\n\t\t\t\treturn nil, &util.HTTPError{\n\t\t\t\t\tErrorType: \"NotFound\",\n\t\t\t\t\tDescription: \"Resource not found\",\n\t\t\t\t\tStatusCode: http.StatusNotFound,\n\t\t\t\t}\n\t\t\t}\n\t\t\tcascadeRootId = UUID.String()\n\t\t} else {\n\t\t\treturn nil, &util.HTTPError{\n\t\t\t\tErrorType: \"BadRequest\",\n\t\t\t\tDescription: \"Cascade delete is not supported for this API\",\n\t\t\t\tStatusCode: http.StatusBadRequest,\n\t\t\t}\n\t\t}\n\t}\n\tif c.supportsCascadeDelete && opCtx.Cascade {\n\t\tconcurrentOp, err := operations.FindCascadeOperationForResource(ctx, c.repository, resourceID)\n\t\tif err != nil {\n\t\t\treturn nil, err\n\t\t}\n\t\tif concurrentOp != nil {\n\t\t\treturn util.NewLocationResponse(concurrentOp.GetID(), resourceID, c.resourceBaseURL)\n\t\t}\n\t}\n\n\tisForce := r.URL.Query().Get(web.QueryParamForce) == \"true\"\n\tlabels := types.Labels{}\n\tif isForce {\n\t\tlabels[\"force\"] = []string{\"true\"}\n\t}\n\n\toperation := &types.Operation{\n\t\tBase: types.Base{\n\t\t\tID: UUID.String(),\n\t\t\tCreatedAt: time.Now(),\n\t\t\tUpdatedAt: time.Now(),\n\t\t\tLabels: labels,\n\t\t\tReady: true,\n\t\t},\n\t\tType: types.DELETE,\n\t\tState: types.IN_PROGRESS,\n\t\tResourceID: resourceID,\n\t\tResourceType: c.objectType,\n\t\tPlatformID: types.SMPlatform,\n\t\tCorrelationID: log.CorrelationIDFromContext(ctx),\n\t\tContext: opCtx,\n\t\tCascadeRootID: cascadeRootId,\n\t}\n\tif c.supportsCascadeDelete && opCtx.Cascade {\n\t\t_, err = c.scheduler.ScheduleSyncStorageAction(ctx, operation, action)\n\t\tif err != nil {\n\t\t\treturn nil, err\n\t\t}\n\t\treturn util.NewLocationResponse(operation.GetID(), operation.ResourceID, c.resourceBaseURL)\n\t}\n\t_, isAsync, err := c.scheduler.ScheduleStorageAction(ctx, operation, action, c.supportsAsync)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\n\tif isAsync {\n\t\treturn util.NewLocationResponse(operation.GetID(), operation.ResourceID, c.resourceBaseURL)\n\t}\n\n\treturn util.NewJSONResponse(http.StatusOK, map[string]string{})\n}", "func (o *FakeObject) Delete(key string) { delete(o.Properties, key) }", "func (c *BaseController) DeleteSingleObject(r *web.Request) (*web.Response, error) {\n\tobjectID := r.PathParams[PathParamID]\n\tctx := r.Context()\n\tlog.C(ctx).Debugf(\"Deleting %s with id %s\", c.objectType, objectID)\n\n\tbyID := query.ByField(query.EqualsOperator, \"id\", objectID)\n\tctx, err := query.AddCriteria(ctx, byID)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\tr.Request = r.WithContext(ctx)\n\n\treturn c.DeleteObjects(r)\n}", "func (hp *hdfsProvider) DeleteObj(lom *cluster.LOM) (errCode int, err error) {\n\tfilePath := filepath.Join(lom.Bck().Props.Extra.HDFS.RefDirectory, lom.ObjName)\n\tif err := hp.c.Remove(filePath); err != nil {\n\t\terrCode, err = hdfsErrorToAISError(err)\n\t\treturn errCode, err\n\t}\n\tif verbose {\n\t\tnlog.Infof(\"[delete_object] %s\", lom)\n\t}\n\treturn 0, nil\n}", "func (objectSet *VolumeObjectSet) DeleteObject(id string) error {\r\n\treturn objectSet.Client.Delete(volumePath, id)\r\n}", "func DeleteMeeting(c *gin.Context) {\n // Get model if exist\n var meeting models.Meeting\n if err := models.DB.First(&meeting, \"id = ?\", c.Param(\"id\")).Error; err != nil {\n c.JSON(http.StatusBadRequest, gin.H{\"error\": \"Record not found!\"})\n return\n }\n\n models.DB.Delete(&meeting)\n\n c.JSON(http.StatusOK, gin.H{\"data\": true})\n}", "func (db *InMemDatabase) Delete(obj contrail.IObject) error {\n\tuid := parseUID(obj.GetUuid())\n\tdata, ok := db.objectData[uid]\n\tif !ok {\n\t\treturn fmt.Errorf(\"Object %s: not in database\", obj.GetUuid())\n\t}\n\tif len(data.children) > 0 {\n\t\treturn fmt.Errorf(\"Delete %s: has children %+v\", obj.GetUuid(), data.children)\n\t}\n\tif len(data.backRefs) > 0 {\n\t\treturn fmt.Errorf(\"Delete %s: has references %+v\", obj.GetUuid(), data.backRefs)\n\t}\n\n\tif !data.parent.IsNIL() {\n\t\tdb.deleteChild(data.parent, obj)\n\t\tif parentObj, ok := db.objByIDMap[data.parent]; ok {\n\t\t\tclearReferenceMask(parentObj)\n\t\t}\n\t}\n\tdb.deleteBackReferences(obj, data.refs)\n\n\tdelete(db.objByIDMap, uid)\n\tdelete(db.objectData, uid)\n\ttypeMap, ok := db.typeDB[obj.GetType()]\n\tif !ok {\n\t\treturn fmt.Errorf(\"No objects of type %s\", obj.GetType())\n\t}\n\tfqn := strings.Join(obj.GetFQName(), \":\")\n\tdelete(typeMap, fqn)\n\treturn nil\n}", "func afterObjectDelete(ctx context.Context, object *storage.ObjectHandle, err error) error {\n\treturn err\n}", "func (fs *Stow) DeleteObject(ctx context.Context, path string) error {\n\tlocation, err := stow.Dial(fs.kind, fs.config)\n\tif err != nil {\n\t\tlog.Errorf(\"stow.Dial fail: %v\", err)\n\t\treturn err\n\t}\n\n\tcontainer, err := location.Container(fs.bucket)\n\tif err != nil {\n\t\tlog.Errorf(\"stow.GetContainer fail: %v\", err)\n\t\treturn err\n\t}\n\n\terr = container.RemoveItem(path)\n\tif err != nil {\n\t\tlog.Errorf(\"stow.Container.RemoveItem fail: %v\", err)\n\t\treturn err\n\t}\n\n\treturn nil\n}", "func Delete(k8sClient client.Client, obj client.Object) error {\n\treturn k8sClient.Delete(context.TODO(), obj)\n}", "func (r *ReconcilerBase) DeleteResource(obj runtime.Object) error {\n\terr := r.client.Delete(context.TODO(), obj)\n\tif err != nil {\n\t\tif !apierrors.IsNotFound(err) {\n\t\t\tlog.Error(err, \"Unable to delete object \", \"object\", obj)\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t}\n\n\tmetaObj, ok := obj.(metav1.Object)\n\tif !ok {\n\t\terr := fmt.Errorf(\"%T is not a metav1.Object\", obj)\n\t\tlog.Error(err, \"Failed to convert into metav1.Object\")\n\t\treturn err\n\t}\n\n\tvar gvk schema.GroupVersionKind\n\tgvk, err = apiutil.GVKForObject(obj, r.scheme)\n\tif err == nil {\n\t\tlog.Info(\"Reconciled\", \"Kind\", gvk.Kind, \"Name\", metaObj.GetName(), \"Status\", \"deleted\")\n\t}\n\treturn nil\n}", "func (s *StateDB) deleteStateObject(stateObject *stateObject) {\n\tstateObject.deleted = true\n\taddr := stateObject.Address()\n\ts.setError(s.trie.Delete(addr[:]))\n}", "func Delete(c client.Client, obj runtime.Object) error {\n\tif err := c.Delete(context.Background(), obj); err != nil {\n\t\tif apierrors.IsNotFound(err) {\n\t\t\treturn nil\n\t\t}\n\t\treturn err\n\t}\n\treturn nil\n}", "func (bt *Blobies) deregister(guid uuid.UUID) {\n\tdelete(bt.Objects, guid)\n}", "func delete_object(project *C.Project, bucket_name, object_key *C.char) C.ObjectResult { //nolint:golint\n\tif project == nil {\n\t\treturn C.ObjectResult{\n\t\t\terror: mallocError(ErrNull.New(\"project\")),\n\t\t}\n\t}\n\tif bucket_name == nil {\n\t\treturn C.ObjectResult{\n\t\t\terror: mallocError(ErrNull.New(\"bucket_name\")),\n\t\t}\n\t}\n\tif object_key == nil {\n\t\treturn C.ObjectResult{\n\t\t\terror: mallocError(ErrNull.New(\"object_key\")),\n\t\t}\n\t}\n\n\tproj, ok := universe.Get(project._handle).(*Project)\n\tif !ok {\n\t\treturn C.ObjectResult{\n\t\t\terror: mallocError(ErrInvalidHandle.New(\"project\")),\n\t\t}\n\t}\n\n\tdeleted, err := proj.DeleteObject(proj.scope.ctx, C.GoString(bucket_name), C.GoString(object_key))\n\treturn C.ObjectResult{\n\t\terror: mallocError(err),\n\t\tobject: mallocObject(deleted),\n\t}\n}", "func (objectSet *PoolObjectSet) DeleteObject(id string) error {\n\terr := objectSet.Client.Delete(poolPath, id)\n\tif err != nil {\n\t\treturn err\n\t}\n\treturn nil\n}", "func (obj *SObject) Delete(id ...string) error {\n\tif obj.Type() == \"\" || obj.client() == nil {\n\t\t// Sanity check\n\t\treturn ErrFailure\n\t}\n\n\toid := obj.ID()\n\tif id != nil {\n\t\toid = id[0]\n\t}\n\tif oid == \"\" {\n\t\treturn ErrFailure\n\t}\n\n\turl := obj.client().makeURL(\"sobjects/\" + obj.Type() + \"/\" + obj.ID())\n\tlog.Println(url)\n\t_, err := obj.client().httpRequest(http.MethodDelete, url, nil)\n\tif err != nil {\n\t\treturn err\n\t}\n\n\treturn nil\n}", "func deleteOneTask(task string) {\n\tfmt.Println(task)\n\tid, _ := primitive.ObjectIDFromHex(task)\n\tfilter := bson.M{\"_id\": id}\n\td, err := collection.DeleteOne(context.Background(), filter)\n\tif err != nil {\n\t\tlog.Fatal(err)\n\t}\n\tfmt.Println(\"Documento eliminado\", d.DeletedCount)\n}", "func (c *VMReplicaSet) deleteVirtualMachine(obj interface{}) {\n\tvm, ok := obj.(*virtv1.VirtualMachine)\n\n\t// When a delete is dropped, the relist will notice a vm in the store not\n\t// in the list, leading to the insertion of a tombstone object which contains\n\t// the deleted key/value. Note that this value might be stale. If the vm\n\t// changed labels the new ReplicaSet will not be woken up till the periodic resync.\n\tif !ok {\n\t\ttombstone, ok := obj.(cache.DeletedFinalStateUnknown)\n\t\tif !ok {\n\t\t\tlog.Log.Reason(fmt.Errorf(\"couldn't get object from tombstone %+v\", obj)).Error(\"Failed to process delete notification\")\n\t\t\treturn\n\t\t}\n\t\tvm, ok = tombstone.Obj.(*virtv1.VirtualMachine)\n\t\tif !ok {\n\t\t\tlog.Log.Reason(fmt.Errorf(\"tombstone contained object that is not a vm %#v\", obj)).Error(\"Failed to process delete notification\")\n\t\t\treturn\n\t\t}\n\t}\n\n\tcontrollerRef := controller.GetControllerOf(vm)\n\tif controllerRef == nil {\n\t\t// No controller should care about orphans being deleted.\n\t\treturn\n\t}\n\trs := c.resolveControllerRef(vm.Namespace, controllerRef)\n\tif rs == nil {\n\t\treturn\n\t}\n\trsKey, err := controller.KeyFunc(rs)\n\tif err != nil {\n\t\treturn\n\t}\n\tc.expectations.DeletionObserved(rsKey, controller.VirtualMachineKey(vm))\n\tc.enqueueReplicaSet(rs)\n}", "func (t *SimpleChaincode) delete(stub shim.ChaincodeStubInterface, args []string) pb.Response {\n\tfmt.Println(\"- start delete transfer\")\n\n\ttype transferDeleteTransientInput struct {\n\t\tName string `json:\"name\"`\n\t}\n\n\tif len(args) != 0 {\n\t\treturn shim.Error(\"Incorrect number of arguments. Private transfer name must be passed in transient map.\")\n\t}\n\n\ttransMap, err := stub.GetTransient()\n\tif err != nil {\n\t\treturn shim.Error(\"Error getting transient: \" + err.Error())\n\t}\n\n\tif _, ok := transMap[\"transfer_delete\"]; !ok {\n\t\treturn shim.Error(\"transfer_delete must be a key in the transient map\")\n\t}\n\n\tif len(transMap[\"transfer_delete\"]) == 0 {\n\t\treturn shim.Error(\"transfer_delete value in the transient map must be a non-empty JSON string\")\n\t}\n\n\tvar transferDeleteInput transferDeleteTransientInput\n\terr = json.Unmarshal(transMap[\"transfer_delete\"], &transferDeleteInput)\n\tif err != nil {\n\t\treturn shim.Error(\"Failed to decode JSON of: \" + string(transMap[\"transfer_delete\"]))\n\t}\n\n\tif len(transferDeleteInput.Name) == 0 {\n\t\treturn shim.Error(\"name field must be a non-empty string\")\n\t}\n\n\t// to maintain the authorization~name index, we need to read the transfer first and get its authorization\n\tvalAsbytes, err := stub.GetPrivateData(\"collectionFileTransfer\", transferDeleteInput.Name) //get the marble from chaincode state\n\tif err != nil {\n\t\treturn shim.Error(\"Failed to get state for \" + transferDeleteInput.Name)\n\t} else if valAsbytes == nil {\n\t\treturn shim.Error(\"Transfer does not exist: \" + transferDeleteInput.Name)\n\t}\n\n\tvar transferToDelete fileTransfer\n\terr = json.Unmarshal([]byte(valAsbytes), &transferToDelete)\n\tif err != nil {\n\t\treturn shim.Error(\"Failed to decode JSON of: \" + string(valAsbytes))\n\t}\n\n\t// delete the transfer from state\n\terr = stub.DelPrivateData(\"collectionFileTransfer\", transferDeleteInput.Name)\n\tif err != nil {\n\t\treturn shim.Error(\"Failed to delete state:\" + err.Error())\n\t}\n\n\t// Also delete the transfer from the authorization~name index\n\tindexName := \"authorization~name\"\n\tauthorizationNameIndexKey, err := stub.CreateCompositeKey(indexName, []string{transferToDelete.Authorization, transferToDelete.Name})\n\tif err != nil {\n\t\treturn shim.Error(err.Error())\n\t}\n\terr = stub.DelPrivateData(\"collectionFileTransfer\", authorizationNameIndexKey)\n\tif err != nil {\n\t\treturn shim.Error(\"Failed to delete state:\" + err.Error())\n\t}\n\n\t// Finally, delete private details of transfer\n\terr = stub.DelPrivateData(\"collectionFileTransferPrivateDetails\", transferDeleteInput.Name)\n\tif err != nil {\n\t\treturn shim.Error(err.Error())\n\t}\n\n\treturn shim.Success(nil)\n}", "func (h *EcrHandler) Delete(obj interface{}) error {\n\treturn nil\n}", "func (p *Peer) quitSync(po int) {\n\tlive := NewStream(\"SYNC\", FormatSyncBinKey(uint8(po)), true)\n\thistory := getHistoryStream(live)\n\terr := p.streamer.Quit(p.ID(), live)\n\tif err != nil && err != p2p.ErrShuttingDown {\n\t\tlog.Error(\"quit\", \"err\", err, \"peer\", p.ID(), \"stream\", live)\n\t}\n\terr = p.streamer.Quit(p.ID(), history)\n\tif err != nil && err != p2p.ErrShuttingDown {\n\t\tlog.Error(\"quit\", \"err\", err, \"peer\", p.ID(), \"stream\", history)\n\t}\n\n\terr = p.removeServer(live)\n\tif err != nil {\n\t\tlog.Error(\"remove server\", \"err\", err, \"peer\", p.ID(), \"stream\", live)\n\t}\n\terr = p.removeServer(history)\n\tif err != nil {\n\t\tlog.Error(\"remove server\", \"err\", err, \"peer\", p.ID(), \"stream\", live)\n\t}\n}", "func deleteObject(w http.ResponseWriter, r *http.Request) {\n\tvars := mux.Vars(r)\n\tkey, _ := strconv.Atoi(vars[\"id\"])\n\tfound := false\n\tlocation := 0\n\n\tfor index := range listOfObjects {\n\t\tif listOfObjects[index].ID == key {\n\t\t\tfound = true\n\t\t\tlocation = index\n\t\t\tbreak\n\t\t}\n\t}\n\n\tif found == true {\n\t\tlistOfObjects = append(listOfObjects[:location], listOfObjects[location+1:]...)\n\t\terr := json.NewEncoder(w).Encode(\"Removed\")\n\t\tif err != nil {\n\t\t\tw.WriteHeader(http.StatusInternalServerError)\n\t\t\tlog.Fatal(\"Error encoding JSON\")\n\t\t}\n\t} else {\n\t\tw.WriteHeader(http.StatusNotFound)\n\t\terr := json.NewEncoder(w).Encode(\"Could not find object\")\n\t\tif err != nil {\n\t\t\tw.WriteHeader(http.StatusInternalServerError)\n\t\t\tlog.Fatal(\"Error encoding JSON\")\n\t\t}\n\t}\n}", "func (r Virtual_Guest_Block_Device_Template_Group) DeleteObject() (resp datatypes.Provisioning_Version1_Transaction, err error) {\n\terr = r.Session.DoRequest(\"SoftLayer_Virtual_Guest_Block_Device_Template_Group\", \"deleteObject\", nil, &r.Options, &resp)\n\treturn\n}", "func (r *FakeClient) Delete(ctx context.Context, obj client.Object, opts ...client.DeleteOption) error {\n\tdelete(r.objects, util.NamespacedName(obj))\n\treturn nil\n}", "func (ep *EtcdClient) DelObj(key string) error {\n\tkeyName := \"/contiv.io/obj/\" + key\n\n\t// Remove it via etcd client\n\t_, err := ep.kapi.Delete(context.Background(), keyName, nil)\n\tif err != nil {\n\t\t// Retry few times if cluster is unavailable\n\t\tif err.Error() == client.ErrClusterUnavailable.Error() {\n\t\t\tfor i := 0; i < maxEtcdRetries; i++ {\n\t\t\t\t_, err = ep.kapi.Delete(context.Background(), keyName, nil)\n\t\t\t\tif err == nil {\n\t\t\t\t\tbreak\n\t\t\t\t}\n\n\t\t\t\t// Retry after a delay\n\t\t\t\ttime.Sleep(time.Second)\n\t\t\t}\n\t\t}\n\t\tif err != nil {\n\t\t\tlog.Errorf(\"Error removing key %s, Err: %v\", keyName, err)\n\t\t\treturn err\n\t\t}\n\t}\n\n\treturn nil\n}", "func (c *Controller) deleteCSPC(obj interface{}) {\n\tcspc, ok := obj.(*cstor.CStorPoolCluster)\n\tif !ok {\n\t\ttombstone, ok := obj.(cache.DeletedFinalStateUnknown)\n\t\tif !ok {\n\t\t\truntime.HandleError(fmt.Errorf(\"Couldn't get object from tombstone %#v\", obj))\n\t\t\treturn\n\t\t}\n\t\tcspc, ok = tombstone.Obj.(*cstor.CStorPoolCluster)\n\t\tif !ok {\n\t\t\truntime.HandleError(fmt.Errorf(\"Tombstone contained object that is not a cstorpoolcluster %#v\", obj))\n\t\t\treturn\n\t\t}\n\t}\n\tif cspc.Annotations[string(types.OpenEBSDisableReconcileLabelKey)] == \"true\" {\n\t\tmessage := fmt.Sprintf(\"reconcile is disabled via %q annotation\", string(types.OpenEBSDisableReconcileLabelKey))\n\t\tc.recorder.Event(cspc, corev1.EventTypeWarning, \"Delete\", message)\n\t\treturn\n\t}\n\tklog.V(4).Infof(\"Deleting cstorpoolcluster %s\", cspc.Name)\n\tc.enqueueCSPC(cspc)\n}", "func (s RPCService) Delete(ctx context.Context, req *IdRequest) (*Void, error) {\n\treturn &Void{}, s.storage.Delete(req.Id)\n}", "func (ep *EtcdClient) DelObj(key string) error {\n\tlog.Infof(`objdb: deleting \"%s\"`, key)\n\tkeyName := \"/contiv.io/obj/\" + key\n\n\t// Remove it via etcd client\n\t_, err := ep.client.KV.Delete(context.Background(), keyName)\n\tif err != nil {\n\t\t// Retry few times if cluster is unavailable\n\t\tif err.Error() == client.ErrNoAvailableEndpoints.Error() {\n\t\t\tfor i := 0; i < maxEtcdRetries; i++ {\n\t\t\t\t_, err = ep.client.KV.Delete(context.Background(), keyName)\n\t\t\t\tif err == nil {\n\t\t\t\t\tbreak\n\t\t\t\t}\n\n\t\t\t\t// Retry after a delay\n\t\t\t\ttime.Sleep(time.Second)\n\t\t\t}\n\t\t}\n\t\tif err != nil {\n\t\t\tlog.Errorf(\"Error removing key %s, Err: %v\", keyName, err)\n\t\t\treturn err\n\t\t}\n\t}\n\n\treturn nil\n}", "func (c *StackCollection) DeleteStackBySpecSync(ctx context.Context, s *Stack, errs chan error) error {\n\ti, err := c.DeleteStackBySpec(ctx, s)\n\tif err != nil {\n\t\treturn err\n\t}\n\n\tlogger.Info(\"waiting for stack %q to get deleted\", *i.StackName)\n\n\tgo c.waitUntilStackIsDeleted(ctx, i, errs)\n\n\treturn nil\n}", "func Del(id string) error {\n\treturn getC().Del(id)\n}", "func Del(id string) error {\n\treturn getC().Del(id)\n}", "func Del(id string) error {\n\treturn getC().Del(id)\n}", "func (t *FakeObjectTracker) Delete(gvr schema.GroupVersionResource, ns, name string) error {\n\treturn nil\n}", "func (client StorageGatewayClient) DeleteCloudSync(ctx context.Context, request DeleteCloudSyncRequest) (response DeleteCloudSyncResponse, err error) {\n\tvar ociResponse common.OCIResponse\n\tpolicy := common.NoRetryPolicy()\n\tif client.RetryPolicy() != nil {\n\t\tpolicy = *client.RetryPolicy()\n\t}\n\tif request.RetryPolicy() != nil {\n\t\tpolicy = *request.RetryPolicy()\n\t}\n\tociResponse, err = common.Retry(ctx, request, client.deleteCloudSync, policy)\n\tif err != nil {\n\t\tif ociResponse != nil {\n\t\t\tif httpResponse := ociResponse.HTTPResponse(); httpResponse != nil {\n\t\t\t\topcRequestId := httpResponse.Header.Get(\"opc-request-id\")\n\t\t\t\tresponse = DeleteCloudSyncResponse{RawResponse: httpResponse, OpcRequestId: &opcRequestId}\n\t\t\t} else {\n\t\t\t\tresponse = DeleteCloudSyncResponse{}\n\t\t\t}\n\t\t}\n\t\treturn\n\t}\n\tif convertedResponse, ok := ociResponse.(DeleteCloudSyncResponse); ok {\n\t\tresponse = convertedResponse\n\t} else {\n\t\terr = fmt.Errorf(\"failed to convert OCIResponse into DeleteCloudSyncResponse\")\n\t}\n\treturn\n}", "func DelElsObj(url string) {\n\tif req, err := http.NewRequest(\"DELETE\", util.ELS_BASE+url, nil); err != nil {\n\t\tlog.Printf(\"Els Create Request Err: %s\\n\", err.Error())\n\t} else if resp, err := http.DefaultClient.Do(req); err != nil {\n\t\tlog.Printf(\"Els Sync Err: %s\\n\", err.Error())\n\t} else if err := resp.Body.Close(); err != nil {\n\t\tlog.Printf(\"Els Close Fp Err: %s\\n\", err.Error())\n\t}\n\n}", "func (k *K8sStore) DeleteResource(obj interface{}) {\n\tkey := \"Unknown\"\n\tns := \"Unknown\"\n\tvar labels map[string]string\n\tswitch v := obj.(type) {\n\tcase cache.DeletedFinalStateUnknown:\n\t\tkey, ns, labels = resourceKey(v.Obj)\n\tcase unstructured.Unstructured:\n\tcase metav1.ObjectMetaAccessor:\n\t\tkey, ns, labels = resourceKey(obj)\n\tdefault:\n\t\tglog.V(6).Infof(\"Unknown object type %v\", obj)\n\t\treturn\n\t}\n\tglog.V(11).Infof(\"%s deleted: %s\", k.resourceName, key)\n\tk.dataMutex.Lock()\n\tdelete(k.data, key)\n\tk.dataMutex.Unlock()\n\tk.updateLabelMap(ns, labels, -1)\n\n\terr := k.DumpFullState()\n\tif err != nil {\n\t\tglog.Warningf(\"Error when dumping state: %v\", err)\n\t}\n}", "func (api *snapshotrestoreAPI) Delete(obj *cluster.SnapshotRestore) error {\n\tif api.ct.resolver != nil {\n\t\tapicl, err := api.ct.apiClient()\n\t\tif err != nil {\n\t\t\tapi.ct.logger.Errorf(\"Error creating API server clent. Err: %v\", err)\n\t\t\treturn err\n\t\t}\n\n\t\t_, err = apicl.ClusterV1().SnapshotRestore().Delete(context.Background(), &obj.ObjectMeta)\n\t\treturn err\n\t}\n\n\tapi.ct.handleSnapshotRestoreEvent(&kvstore.WatchEvent{Object: obj, Type: kvstore.Deleted})\n\treturn nil\n}", "func DeletePerson(c *gin.Context) {\n // Get model if exist\n var person models.Person\n if err := models.DB.First(&person, \"id = ?\", c.Param(\"id\")).Error; err != nil {\n c.JSON(http.StatusBadRequest, gin.H{\"error\": \"Record not found!\"})\n return\n }\n\n models.DB.Delete(&person)\n\n c.JSON(http.StatusOK, gin.H{\"data\": true})\n}", "func (s *Hipchat) ObjectDeleted(obj interface{}) {\n\tnotifyHipchat(s, obj, \"deleted\")\n}", "func (c *PluginContext) SyncDelete(key ContextKey) {\n\tc.Mx.Lock()\n\tdefer c.Mx.Unlock()\n\tc.Delete(key)\n}", "func (d *DBRepository) deleteOne(ctx context.Context, id string) error {\n\tobjectId, err := primitive.ObjectIDFromHex(id)\n\tif err != nil {\n\t\treturn err\n\t}\n\tif _, err := d.Collection.DeleteOne(ctx, bson.M{\"_id\": objectId}); err != nil {\n\t\treturn err\n\t}\n\treturn nil\n}", "func (api *versionAPI) Delete(obj *cluster.Version) error {\n\tif api.ct.resolver != nil {\n\t\tapicl, err := api.ct.apiClient()\n\t\tif err != nil {\n\t\t\tapi.ct.logger.Errorf(\"Error creating API server clent. Err: %v\", err)\n\t\t\treturn err\n\t\t}\n\n\t\t_, err = apicl.ClusterV1().Version().Delete(context.Background(), &obj.ObjectMeta)\n\t\treturn err\n\t}\n\n\tapi.ct.handleVersionEvent(&kvstore.WatchEvent{Object: obj, Type: kvstore.Deleted})\n\treturn nil\n}", "func (fkw *FakeClientWrapper) Delete(ctx context.Context, obj runtime.Object, opts ...k8sCl.DeleteOption) error {\n\treturn fkw.client.Delete(ctx, obj, opts...)\n}", "func (obj *MessengerUser) Delete() {\n\tif obj == nil {\n\t\treturn\n\t}\n\truntime.SetFinalizer(obj, nil)\n\tobj.delete()\n}", "func delPatricia(ptr patricia, bucket string, cb db.CachedBatch) {\n\tkey := ptr.hash()\n\tlogger.Debug().Hex(\"key\", key[:8]).Msg(\"del\")\n\tcb.Delete(bucket, key[:], \"failed to delete key = %x\", key)\n}", "func (c *RemoteClient) deleteMD5() error {\n\tif c.ddbTable == \"\" {\n\t\treturn nil\n\t}\n\n\tparams := &dynamodb.DeleteItemInput{\n\t\tKey: map[string]*dynamodb.AttributeValue{\n\t\t\t\"LockID\": {S: aws.String(c.lockPath() + stateIDSuffix)},\n\t\t},\n\t\tTableName: aws.String(c.ddbTable),\n\t}\n\tif _, err := c.dynClient.DeleteItem(params); err != nil {\n\t\treturn err\n\t}\n\treturn nil\n}", "func Delete(s *discordgo.Session, m *discordgo.MessageCreate) {\n}", "func (h *Handler) DeleteObject(w http.ResponseWriter, r *http.Request) {\n\tid := chi.URLParam(r, \"id\")\n\n\tlog := logger.Log.WithField(\"requestID\", middleware.GetReqID(r.Context()))\n\n\terr := h.Store.Delete(r.Context(), id)\n\tif err != nil {\n\t\tif err == store.KeyNotFound {\n\t\t\tlog.WithField(\"objectID\", id).Debug(err)\n\t\t\tw.WriteHeader(http.StatusNotFound)\n\t\t} else {\n\t\t\tlog.Error(err)\n\t\t\tw.WriteHeader(http.StatusInternalServerError)\n\t\t}\n\t\treturn\n\t}\n\n\tw.WriteHeader(http.StatusNoContent)\n}", "func deletePerson(w http.ResponseWriter, r *http.Request) {\r\n\tw.Header().Set(\"Content-Type\", \"application/json\")\r\n\r\n\tparams := mux.Vars(r)\r\n\tuuid, err := primitive.ObjectIDFromHex(params[\"uuid\"])\r\n\tif err != nil {\r\n\t\tlog.Fatal(err)\r\n\t}\r\n\r\n\tcollection := models.ConnectDB()\r\n\tobjectToDelete, err := collection.DeleteOne(context.TODO(), bson.M{\"_id\": uuid})\r\n\tif err != nil {\r\n\t\tlog.Fatal(err)\r\n\t}\r\n\tjson.NewEncoder(w).Encode(objectToDelete.DeletedCount)\r\n\r\n}", "func (c Client) delete(path string, params url.Values, holder interface{}) error {\n\treturn c.request(\"DELETE\", path, params, &holder)\n}", "func (a *Client) SafeObjectDelete(params *SafeObjectDeleteParams) (*SafeObjectDeleteOK, error) {\n\t// TODO: Validate the params before sending\n\tif params == nil {\n\t\tparams = NewSafeObjectDeleteParams()\n\t}\n\n\tresult, err := a.transport.Submit(&runtime.ClientOperation{\n\t\tID: \"safeObjectDelete\",\n\t\tMethod: \"DELETE\",\n\t\tPathPattern: \"/domainSafeObject/{object}/{type}\",\n\t\tProducesMediaTypes: []string{\"application/json\"},\n\t\tConsumesMediaTypes: []string{\"application/json\"},\n\t\tSchemes: []string{\"https\"},\n\t\tParams: params,\n\t\tReader: &SafeObjectDeleteReader{formats: a.formats},\n\t\tContext: params.Context,\n\t\tClient: params.HTTPClient,\n\t})\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\tsuccess, ok := result.(*SafeObjectDeleteOK)\n\tif ok {\n\t\treturn success, nil\n\t}\n\t// unexpected success response\n\t// safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue\n\tmsg := fmt.Sprintf(\"unexpected success response for safeObjectDelete: API contract not enforced by server. Client expected to get an error, but got: %T\", result)\n\tpanic(msg)\n}", "func deleteOneTask(task string) {\n\tfmt.Println(task)\n\tid, _ := primitive.ObjectIDFromHex(task)\n\tfilter := bson.M{\"_id\": id}\n\t_, err := collection.DeleteOne(context.Background(), filter)\n\tif err != nil {\n\t\tlog.Fatal(err)\n\t}\n\n\tfmt.Println(\"Deleted task\", id)\n}", "func (i *Inode) delMeta() {\n\tclient := i.redisRing.GetClient(i.keyPrefix)\n\tTry(client.Unlink(i.keyPrefix+\":children\", i.keyPrefix+\":mode\"))\n}", "func (r *ReconcilerBase) DeleteResource(obj runtime.Object) error {\n\tlogger := NewLogger(true) //log in JSON format\n\n\terr := r.client.Delete(context.TODO(), obj)\n\tif err != nil {\n\t\tif !apierrors.IsNotFound(err) {\n\t\t\tif logger.IsEnabled(LogTypeError) {\n\t\t\t\tlogger.Log(CallerName(), LogTypeError, fmt.Sprintf(\"Unable to delete object: %s, Error: %s \", obj, err), logName)\n\t\t\t}\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t}\n\n\tmetaObj, ok := obj.(metav1.Object)\n\tif !ok {\n\t\terr := fmt.Errorf(\"%T is not a runtime.Object\", obj)\n\t\tif logger.IsEnabled(LogTypeError) {\n\t\t\tlogger.Log(CallerName(), LogTypeError, fmt.Sprintf(\"Failed to convert into runtime.Object, Error: %s \", err), logName)\n\t\t}\n\t\treturn err\n\t}\n\n\tvar gvk schema.GroupVersionKind\n\tgvk, err = apiutil.GVKForObject(obj, r.scheme)\n\tif err == nil {\n\t\tif logger.IsEnabled(LogTypeInfo) {\n\t\t\tlogger.Log(CallerName(), LogTypeInfo, fmt.Sprintf(\"Reconciled, Kind: %s, Name: %s, Status: deleted\", gvk.Kind, metaObj.GetName()), logName)\n\t\t}\n\t}\n\treturn nil\n}", "func (t *SimpleChaincode) delete(stub shim.ChaincodeStubInterface, args []string) pb.Response {\n\tif len(args) != 2 {\n\t\treturn shim.Error(\"Incorrect number of arguments. Expecting 2\")\n\t}\n\n\tid := args[0]\n\tname := args[1]\n\tdata := stub.GetState(id)\n\tfmt.Printf(\"id : %s, name : %s\\n\", id, name)\n\n\t// Delete the key from the state in ledger\n\terr := stub.DelState(id)\n\tif err != nil {\n\t\treturn shim.Error(\"Failed to delete state\")\n\t}\n\terr := stub.DelState(name)\n\tif err != nil {\n\t\treturn shim.Error(\"Faild to delete state\")\n\t}\n\n\t// delete data on couchdb\n\tdb := client.Use(\"test\")\n doc := &Document{\n Id: id,\n Name : name,\n Data : data,\n }\n\tif _, err = db.Delete(doc); err != nil {\n\t\tpanic(err)\n\t}\n\n\treturn shim.Success(nil)\n}", "func DeleteCompletely(getObject func() (metav1.Object, error), deleteObject func(*metav1.DeleteOptions) error) error {\n\tobj, err := getObject()\n\tif err != nil {\n\t\tif errors.IsNotFound(err) {\n\t\t\treturn nil\n\t\t}\n\t\treturn err\n\t}\n\n\tuid := obj.GetUID()\n\n\tpolicy := metav1.DeletePropagationForeground\n\tif err := deleteObject(&metav1.DeleteOptions{\n\t\tPreconditions: &metav1.Preconditions{\n\t\t\tUID: &uid,\n\t\t},\n\t\tPropagationPolicy: &policy,\n\t}); err != nil {\n\t\tif errors.IsNotFound(err) {\n\t\t\treturn nil\n\t\t}\n\t\treturn err\n\t}\n\n\treturn wait.Poll(1*time.Second, AsyncOperationTimeout, func() (stop bool, err error) {\n\t\tobj, err = getObject()\n\t\tif err != nil {\n\t\t\tif errors.IsNotFound(err) {\n\t\t\t\treturn true, nil\n\t\t\t}\n\t\t\treturn false, err\n\t\t}\n\n\t\treturn obj.GetUID() != uid, nil\n\t})\n}", "func (p *Plugin) ObjectDeleted(obj interface{}) {\n\tp.Log.Infof(\"ObjectStore.ObjectDeleted: %s\", obj)\n\tswitch obj.(type) {\n\tcase *v1.NetworkService:\n\t\tns := obj.(*v1.NetworkService).Spec\n\t\tp.objects.networkServicesStore.Delete(meta{name: ns.Metadata.Name, namespace: ns.Metadata.Namespace})\n\tcase *v1.NetworkServiceChannel:\n\t\tnsc := obj.(*v1.NetworkServiceChannel).Spec\n\t\tp.objects.networkServiceChannelsStore.DeleteChannel(&nsc)\n\tcase *v1.NetworkServiceEndpoint:\n\t\tnse := obj.(*v1.NetworkServiceEndpoint).Spec\n\t\tp.objects.networkServiceEndpointsStore.Delete(meta{name: nse.Metadata.Name, namespace: nse.Metadata.Namespace})\n\t}\n}", "func (m *Manager) SyncObject(client *dynamicclientset.ResourceClient, obj *unstructured.Unstructured) (*unstructured.Unstructured, error) {\n\t// If the cached object passed in is already in the right state,\n\t// we'll assume we don't need to check the live object.\n\tif dynamicobject.HasFinalizer(obj, m.Name) == m.Enabled {\n\t\treturn obj, nil\n\t}\n\t// Otherwise, we may need to update the object.\n\tif m.Enabled {\n\t\t// If the object is already pending deletion, we don't add the finalizer.\n\t\t// We might have already removed it.\n\t\tif obj.GetDeletionTimestamp() != nil {\n\t\t\treturn obj, nil\n\t\t}\n\t\treturn client.Namespace(obj.GetNamespace()).AddFinalizer(obj, m.Name)\n\t} else {\n\t\treturn client.Namespace(obj.GetNamespace()).RemoveFinalizer(obj, m.Name)\n\t}\n}", "func (c *BaseController) DeleteObjects(r *web.Request) (*web.Response, error) {\n\tctx := r.Context()\n\tlog.C(ctx).Debugf(\"Deleting %ss...\", c.objectType)\n\n\tisAsync := r.URL.Query().Get(web.QueryParamAsync)\n\tif isAsync == \"true\" {\n\t\treturn nil, &util.HTTPError{\n\t\t\tErrorType: \"BadRequest\",\n\t\t\tDescription: \"Only one resource can be deleted asynchronously at a time\",\n\t\t\tStatusCode: http.StatusBadRequest,\n\t\t}\n\t}\n\n\tcriteria := query.CriteriaForContext(ctx)\n\n\tlog.C(ctx).Debugf(\"Request will be executed synchronously\")\n\tif err := c.repository.Delete(ctx, c.objectType, criteria...); err != nil {\n\t\treturn nil, util.HandleStorageError(err, c.objectType.String())\n\t}\n\n\treturn util.NewJSONResponse(http.StatusOK, map[string]string{})\n}", "func (api *distributedservicecardAPI) Delete(obj *cluster.DistributedServiceCard) error {\n\tif api.ct.resolver != nil {\n\t\tapicl, err := api.ct.apiClient()\n\t\tif err != nil {\n\t\t\tapi.ct.logger.Errorf(\"Error creating API server clent. Err: %v\", err)\n\t\t\treturn err\n\t\t}\n\n\t\t_, err = apicl.ClusterV1().DistributedServiceCard().Delete(context.Background(), &obj.ObjectMeta)\n\t\treturn err\n\t}\n\n\tapi.ct.handleDistributedServiceCardEvent(&kvstore.WatchEvent{Object: obj, Type: kvstore.Deleted})\n\treturn nil\n}", "func deleteOneTask(task string) {\n\tlog.Println(task)\n\tid, _ := primitive.ObjectIDFromHex(task)\n\tfilter := bson.M{\"_id\": id}\n\td, err := collection.DeleteOne(context.Background(), filter)\n\tif err != nil {\n\t\tlog.Fatal(err)\n\t}\n\n\tlog.Println(\"Deleted Document\", d.DeletedCount)\n}", "func (s *PublicStorageServer) Delete(ctx context.Context, url *pbs.FileURL) (*emptypb.Empty, error) {\n\tvar obj file.MinioObj\n\tif err := obj.FromURL(url.Url); err != nil {\n\t\treturn nil, err\n\t}\n\n\terr := services.MinioClient.RemoveObject(context.Background(), \"public\", obj.ObjectName, minio.RemoveObjectOptions{})\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\tlog.Printf(\"Delete from url: %s\", obj.URL)\n\n\treturn &emptypb.Empty{}, nil\n}", "func (cookie *Cookie) Unsync(key string) {\n\tdelete(cookie.uids, key)\n}" ]
[ "0.72480255", "0.6765631", "0.67138106", "0.66838896", "0.6453525", "0.6292684", "0.62832284", "0.6248952", "0.61742663", "0.6156162", "0.6150627", "0.6122636", "0.61037755", "0.6094954", "0.605976", "0.60458654", "0.6000338", "0.59551305", "0.5929669", "0.5882508", "0.5874518", "0.5865081", "0.5826598", "0.5807617", "0.5751992", "0.5747905", "0.56147426", "0.5584486", "0.5581758", "0.5578452", "0.55643934", "0.55604017", "0.55253214", "0.55203927", "0.5513732", "0.5488427", "0.5478588", "0.54624504", "0.54541063", "0.54440767", "0.543419", "0.5418495", "0.5399989", "0.5381563", "0.53784186", "0.5377704", "0.537247", "0.5370177", "0.5366353", "0.53595364", "0.5322681", "0.532156", "0.5306875", "0.53013456", "0.5297529", "0.52932596", "0.529226", "0.52872247", "0.5283374", "0.52832055", "0.5281044", "0.52803", "0.5279613", "0.5276822", "0.5272", "0.52696127", "0.52696127", "0.52696127", "0.5267262", "0.5265513", "0.52543664", "0.5250569", "0.5248937", "0.52486104", "0.52452016", "0.52425283", "0.5234798", "0.52285105", "0.5217387", "0.5210882", "0.5207491", "0.5205171", "0.5203972", "0.5196917", "0.51968473", "0.5195614", "0.5188325", "0.5187653", "0.51841676", "0.51833475", "0.5172104", "0.5165463", "0.5163888", "0.5162209", "0.51262665", "0.5121026", "0.5117014", "0.51143223", "0.51109266" ]
0.60909486
15
delete transform feedback objects
func DeleteTransformFeedbacks(n int32, ids *uint32) { C.glowDeleteTransformFeedbacks(gpDeleteTransformFeedbacks, (C.GLsizei)(n), (*C.GLuint)(unsafe.Pointer(ids))) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func (p *transformDataNodes) CleanUp() {}", "func (this *Transformable) destroy() {\n\tC.sfTransformable_destroy(this.cptr)\n}", "func (t *Track) Clean() {\n\tfor i := 0; i < len(t.samples); i++ {\n\t\tt.samples[i] = nil\n\t}\n\tt.samples = t.samples[:0]\n\tt.samples = nil\n}", "func (am *Manager) Clean() {\n\tfor name, m := range am.Materials {\n\t\tLogger.Printf(\"Manager: deleting Material '%s'\\n\", name)\n\t\tm.Clean()\n\t\tdelete(am.Materials, name)\n\t}\n\tfor name, m := range am.Meshes {\n\t\tLogger.Printf(\"Manager: deleting Mesh '%s'\\n\", name)\n\t\tm.Clean()\n\t\tdelete(am.Meshes, name)\n\t}\n\tfor set, prog := range am.Programs {\n\t\tLogger.Printf(\"Manager: deleting Program '%v'\\n\", set)\n\t\tgl.DeleteProgram(prog)\n\t\tdelete(am.Programs, set)\n\t}\n\tfor name, shader := range am.Shaders {\n\t\tLogger.Printf(\"Manager: deleting Shader '%s'\\n\", name)\n\t\tgl.DeleteShader(shader)\n\t\tdelete(am.Shaders, name)\n\t}\n\tfor name, tex := range am.Textures {\n\t\tLogger.Printf(\"Manager: deleting Texture '%s'\\n\", name)\n\t\ttex.Clean()\n\t\tdelete(am.Textures, name)\n\t}\n}", "func (t *Transform) Destroy() {\n\tt.Reset()\n\ttransformPool.Put(t)\n}", "func (am *AssetManager) Clean() {\n\tfor name, model := range am.Models {\n\t\tmodel.Delete()\n\t\tdelete(am.Models, name)\n\t}\n\tfor name, tex := range am.Textures {\n\t\ttex.Delete()\n\t\tdelete(am.Textures, name)\n\t}\n\tfor name, prog := range am.Programs {\n\t\tprog.Delete()\n\t\tdelete(am.Programs, name)\n\t}\n}", "func DeleteTransformFeedbacks(n int32, ids *uint32) {\n C.glowDeleteTransformFeedbacks(gpDeleteTransformFeedbacks, (C.GLsizei)(n), (*C.GLuint)(unsafe.Pointer(ids)))\n}", "func (pm partitionMap) cleanup() {\n\tfor ns, partitions := range pm {\n\t\tfor i := range partitions.Replicas {\n\t\t\tfor j := range partitions.Replicas[i] {\n\t\t\t\tpartitions.Replicas[i][j] = nil\n\t\t\t}\n\t\t\tpartitions.Replicas[i] = nil\n\t\t}\n\n\t\tpartitions.Replicas = nil\n\t\tpartitions.regimes = nil\n\n\t\tdelete(pm, ns)\n\t}\n}", "func DeleteTransformFeedbacks(n int32, ids *uint32) {\n\tsyscall.Syscall(gpDeleteTransformFeedbacks, 2, uintptr(n), uintptr(unsafe.Pointer(ids)), 0)\n}", "func CleanActionBuffer(){\n\tActionBuffer=nil //throw to garbage collector\n\tInitiateActionBuffer()\n}", "func (t *MorphTargets) Cleanup(a *app.App) {}", "func (r *gui3dRenderer) cleanUp() {\n\t\tr.shader.CleanUp()\n}", "func (tr *trooper) trash() {\n\tfor _, b := range tr.bits {\n\t\tb.trash()\n\t}\n\tif tr.center != nil {\n\t\ttr.center.Dispose()\n\t\ttr.center = nil\n\t}\n\tif tr.neo != nil {\n\t\ttr.neo.Dispose()\n\t}\n\ttr.neo = nil\n}", "func (s *storage) cleanExpired(sources pb.SyncMapping, actives pb.SyncMapping) {\nnext:\n\tfor _, entry := range sources {\n\t\tfor _, act := range actives {\n\t\t\tif act.CurInstanceID == entry.CurInstanceID {\n\t\t\t\tcontinue next\n\t\t\t}\n\t\t}\n\n\t\tdelOp := delMappingOp(entry.ClusterName, entry.OrgInstanceID)\n\t\tif _, err := s.engine.Do(context.Background(), delOp); err != nil {\n\t\t\tlog.Errorf(err, \"Delete instance clusterName=%s instanceID=%s failed\", entry.ClusterName, entry.OrgInstanceID)\n\t\t}\n\n\t\ts.deleteInstance(entry.CurInstanceID)\n\t}\n}", "func (p *panel) trash() {\n\tif p.slab != nil {\n\t\tp.slab.Dispose()\n\t\tp.slab = nil\n\t}\n\tfor _, cube := range p.cubes {\n\t\tcube.reset(0)\n\t}\n}", "func (p *NoOpNodeGroupListProcessor) CleanUp() {\n}", "func (tr *testTalker) erase() {\n\ttr.input = make([]string, 0)\n\ttr.output = make([]string, 0)\n}", "func (i *IntransitiveActivity) Clean() {\n\ti.BCC = nil\n\ti.Bto = nil\n}", "func (t *Points) Cleanup(a *app.App) {}", "func (t *Pitch) Cleanup(a *app.App) {}", "func (t *Pitch) Cleanup(a *app.App) {}", "func (_BaseAccessControlGroup *BaseAccessControlGroupTransactor) CleanUpContentObjects(opts *bind.TransactOpts) (*types.Transaction, error) {\n\treturn _BaseAccessControlGroup.contract.Transact(opts, \"cleanUpContentObjects\")\n}", "func (e Engine) Clean() {\n\tos.RemoveAll(e.outputFolder)\n\treturn\n}", "func (r *OutlineRenderer) cleanUp() {\n\tr.shader.CleanUp()\n}", "func (e *ObservableEditableBuffer) Clean() {\n\tbefore := e.getTagStatus()\n\n\te.treatasclean = false\n\top := e.putseq\n\te.putseq = e.seq\n\n\te.notifyTagObservers(before)\n\n\tif op != e.seq {\n\t\te.filtertagobservers = false\n\t}\n}", "func (_BaseAccessWallet *BaseAccessWalletTransactor) CleanUpContentObjects(opts *bind.TransactOpts) (*types.Transaction, error) {\n\treturn _BaseAccessWallet.contract.Transact(opts, \"cleanUpContentObjects\")\n}", "func (p *predictionDataset) CleanupTempFiles() {\n\tp.params.DatasetConstructor.CleanupTempFiles()\n}", "func (s *Scene) Delete() {\n\ts.propOctree = nil\n\ts.props = nil\n\n\ts.bodyPool = nil\n\ts.dynamicBodies = nil\n\n\ts.firstSBConstraint = nil\n\ts.lastSBConstraint = nil\n\n\ts.firstDBConstraint = nil\n\ts.lastDBConstraint = nil\n}", "func (s *Scene) Cleanup() {\n\tvar id uint32\n\tfor i := 0; i < numPrograms; i++ {\n\t\tid = s.Programs[i]\n\t\tgl.UseProgram(id)\n\t\tgl.DeleteProgram(id)\n\t}\n}", "func (t *AudioDoppler) Cleanup(a *app.App) {}", "func (t *SpriteAnim) Cleanup(a *app.App) {}", "func (recorder *TrxHistoryRecorder) Clean() {\n\trecorder.summaries.cache = list.New()\n}", "func (m *mapReact) Clean() {\n\tm.ro.Lock()\n\tm.ma = make(map[SenderDetachCloser]bool)\n\tm.ro.Unlock()\n}", "func Clean() error { return sh.Run(\"mage\", \"-clean\") }", "func (sp *Space) ClearTags() {\n\tfor _, shape := range *sp {\n\t\tshape.ClearTags()\n\t}\n}", "func (p *filteringPodListProcessor) CleanUp() {\n\tfor _, transform := range p.transforms {\n\t\ttransform.CleanUp()\n\t}\n\tfor _, filter := range p.filters {\n\t\tfilter.CleanUp()\n\t}\n}", "func (d *ResultEncoder) Clean() {\n\td.buffer = nil\n}", "func (r *ReconcileGitTrack) deleteResources(leftovers map[string]farosv1alpha1.GitTrackObjectInterface) error {\n\tif len(leftovers) > 0 {\n\t\tr.log.V(0).Info(\"Found leftover resources to clean up\", \"leftover resources\", string(len(leftovers)))\n\t}\n\tfor name, obj := range leftovers {\n\t\tif err := r.Delete(context.TODO(), obj); err != nil {\n\t\t\treturn fmt.Errorf(\"failed to delete child for '%s': '%s'\", name, err)\n\t\t}\n\t\tr.log.V(0).Info(\"Child deleted\", \"child name\", name)\n\t}\n\treturn nil\n}", "func (m *mover) cleanup() error {\n\tm.unlink(m.trashList)\n\treturn nil\n}", "func (t *Tube) Cleanup(a *app.App) {}", "func (_AccessIndexor *AccessIndexorTransactor) CleanUpContentObjects(opts *bind.TransactOpts) (*types.Transaction, error) {\n\treturn _AccessIndexor.contract.Transact(opts, \"cleanUpContentObjects\")\n}", "func (gc *GarbageCollector) deleteCandidates(ctx job.Context) error {\n\tif os.Getenv(\"UTTEST\") == \"true\" {\n\t\tgc.logger = ctx.GetLogger()\n\t}\n\t// default is not to clean trash\n\tflushTrash := false\n\tdefer func() {\n\t\tif flushTrash {\n\t\t\tgc.logger.Info(\"flush artifact trash\")\n\t\t\tif err := gc.artrashMgr.Flush(ctx.SystemContext(), 0); err != nil {\n\t\t\t\tgc.logger.Errorf(\"failed to flush artifact trash: %v\", err)\n\t\t\t}\n\t\t}\n\t}()\n\n\t// handle the optional ones, and the artifact controller will move them into trash.\n\tif gc.deleteUntagged {\n\t\tuntagged, err := gc.artCtl.List(ctx.SystemContext(), &q.Query{\n\t\t\tKeywords: map[string]interface{}{\n\t\t\t\t\"Tags\": \"nil\",\n\t\t\t},\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tgc.logger.Info(\"start to delete untagged artifact.\")\n\t\tfor _, art := range untagged {\n\t\t\tif err := gc.artCtl.Delete(ctx.SystemContext(), art.ID); err != nil {\n\t\t\t\t// the failure ones can be GCed by the next execution\n\t\t\t\tgc.logger.Errorf(\"failed to delete untagged:%d artifact in DB, error, %v\", art.ID, err)\n\t\t\t\tcontinue\n\t\t\t}\n\t\t\tgc.logger.Infof(\"delete the untagged artifact: ProjectID:(%d)-RepositoryName(%s)-MediaType:(%s)-Digest:(%s)\",\n\t\t\t\tart.ProjectID, art.RepositoryName, art.ManifestMediaType, art.Digest)\n\t\t}\n\t\tgc.logger.Info(\"end to delete untagged artifact.\")\n\t}\n\n\t// handle the trash\n\trequired, err := gc.artrashMgr.Filter(ctx.SystemContext(), 0)\n\tif err != nil {\n\t\treturn err\n\t}\n\tgc.logger.Info(\"required candidate: %+v\", required)\n\tfor _, art := range required {\n\t\tif err := deleteManifest(art.RepositoryName, art.Digest); err != nil {\n\t\t\treturn fmt.Errorf(\"failed to delete manifest, %s:%s with error: %v\", art.RepositoryName, art.Digest, err)\n\t\t}\n\t\tgc.logger.Infof(\"delete the manifest with registry v2 API: RepositoryName(%s)-MediaType:(%s)-Digest:(%s)\",\n\t\t\tart.RepositoryName, art.ManifestMediaType, art.Digest)\n\t}\n\tgc.logger.Info(\"end to delete required artifact.\")\n\tflushTrash = true\n\treturn nil\n}", "func (t Texture3D) Destroy() {\n\tgl.DeleteTextures(1, &t.id)\n}", "func (j *TrainingJob) deleteResources() error {\n\tfor _, r := range j.Replicas {\n\t\tif err := r.Delete(); err != nil {\n\t\t\treturn err\n\t\t}\n\t}\n\n\treturn nil\n}", "func (m MessageDescriptorMap) Cleanup() (deleted []string) {\n\tfor id, descriptor := range m {\n\t\tif !descriptor.Touched() {\n\t\t\tdelete(m, id)\n\t\t\tdeleted = append(deleted, id)\n\t\t}\n\t}\n\treturn\n}", "func doDeleteMesh(componentMeshName string) {\n\tcr := visibleMeshes[componentMeshName]\n\tcr.Renderable.Destroy()\n\tcr.Renderable = nil\n\tdelete(visibleMeshes, componentMeshName)\n}", "func (obj *MessengerFileCipher) Delete() {\n\tif obj == nil {\n\t\treturn\n\t}\n\truntime.SetFinalizer(obj, nil)\n\tobj.delete()\n}", "func (g *Group) DeleteAll() {\n\tg.Equivalents = list.New()\n\tg.Fingerprints = make(map[string]*list.Element)\n\tg.FirstExpr = make(map[Operand]*list.Element)\n\tg.SelfFingerprint = \"\"\n}", "func (as *AggregateStore) deleteOutput(traces ...ID) error {\n\tfor _, trace := range traces {\n\t\tif as.Keep != nil {\n\t\t\t// Find the trace in the keep store.\n\t\t\t_, err := as.Keep.Trace(trace)\n\t\t\tif err == nil {\n\t\t\t\t// We found it, and so we keep the trace.\n\t\t\t\treturn nil\n\t\t\t} else if err != ErrTraceNotFound {\n\t\t\t\treturn err\n\t\t\t}\n\t\t}\n\t\tif err := as.MemoryStore.Delete(trace); err != nil {\n\t\t\treturn err\n\t\t}\n\t}\n\treturn nil\n}", "func (e *dockerEngine) clean() {\n\tsss := map[string]map[string]attribute{}\n\tif e.LoadStats(&sss) {\n\t\tfor sn, instances := range sss {\n\t\t\tfor in, instance := range instances {\n\t\t\t\tid := instance.Container.ID\n\t\t\t\tif id == \"\" {\n\t\t\t\t\te.log.Warnf(\"[%s][%s] container id not found, maybe running mode changed\", sn, in)\n\t\t\t\t\tcontinue\n\t\t\t\t}\n\t\t\t\terr := e.stopContainer(id)\n\t\t\t\tif err != nil {\n\t\t\t\t\te.log.Warnf(\"[%s][%s] failed to stop the old container (%s)\", sn, in, id[:12])\n\t\t\t\t} else {\n\t\t\t\t\te.log.Infof(\"[%s][%s] old container (%s) stopped\", sn, in, id[:12])\n\t\t\t\t}\n\t\t\t\terr = e.removeContainer(id)\n\t\t\t\tif err != nil {\n\t\t\t\t\te.log.Warnf(\"[%s][%s] failed to remove the old container (%s)\", sn, in, id[:12])\n\t\t\t\t} else {\n\t\t\t\t\te.log.Infof(\"[%s][%s] old container (%s) removed\", sn, in, id[:12])\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n}", "func cleanup() {\n\tif integrationType == slackIntegrationType {\n\t\tif err := slack.DeleteState(); err != nil {\n\t\t\tlog.Println(err)\n\t\t}\n\t} else {\n\t\tif err := github.DeleteState(); err != nil {\n\t\t\tlog.Println(err)\n\t\t}\n\t}\n}", "func (o *Objects) GC() error {\n\tfiles := map[string]bool{}\n\tdirs := map[string]bool{}\n\to.Before.visitFile(func(file string) {\n\t\tfiles[file] = true\n\t})\n\to.Before.visitDir(func(dir string) {\n\t\tdirs[dir] = true\n\t})\n\to.visitFile(func(file string) {\n\t\tdelete(files, file)\n\t\to.deleteParents(dirs, file)\n\t})\n\to.visitDir(func(dir string) {\n\t\tdelete(dirs, dir)\n\t\to.deleteParents(dirs, dir)\n\t})\n\n\tfor file := range files {\n\t\tif err := o.Remove(file); err != nil {\n\t\t\treturn err\n\t\t}\n\t}\n\tfor dir := range dirs {\n\t\tif err := o.RemoveAll(dir); err != nil {\n\t\t\treturn err\n\t\t}\n\t}\n\treturn nil\n}", "func (p *PointsSgMutator) ClearMutations() { //nolint:dupl false positive\n\tp.mutations = []A.X{}\n}", "func (a *annotator) TearDown() {\n\ta.publisher.TearDown()\n}", "func (g *Game) destroy() {\n\tg.trex.Destroy()\n\tg.cactus.Destroy()\n\tg.clouds.Destroy()\n\tg.ground.Destroy()\n}", "func (b *Builder) clearMesh() {\n\tfor _, key := range b.localInstances.Keys() {\n\t\tb.localInstances.Delete(key)\n\t}\n}", "func destructor(cmd *cobra.Command, args []string) {\n\tlog.Debug().Msgf(\"Running Destructor.\\n\")\n\tif debug {\n\t\t// Keep intermediary files, when on debug\n\t\tlog.Debug().Msgf(\"Skipping file clearance on Debug Mode.\\n\")\n\t\treturn\n\t}\n\tintermediaryFiles := []string{\"generate_pylist.py\", \"pylist.json\", \"dependencies.txt\", \"golist.json\", \"npmlist.json\"}\n\tfor _, file := range intermediaryFiles {\n\t\tfile = filepath.Join(os.TempDir(), file)\n\t\tif _, err := os.Stat(file); err != nil {\n\t\t\tif os.IsNotExist(err) {\n\t\t\t\t// If file doesn't exists, continue\n\t\t\t\tcontinue\n\t\t\t}\n\t\t}\n\t\te := os.Remove(file)\n\t\tif e != nil {\n\t\t\tlog.Fatal().Msgf(\"Error clearing files %s\", file)\n\t\t}\n\t}\n}", "func (tr *trooper) demerge() {\n\ttr.trash()\n\ttr.addCenter()\n\tfor _, b := range tr.bits {\n\t\tb.reset(b.box().cmax)\n\t}\n\ttr.detach()\n}", "func (i *InteractiveMode) Cleanup(congress *lassie.Client, app lassie.Application, gw lassie.Gateway) {\n\tif !i.Config.KeepDevices {\n\t\tfor _, v := range i.devices {\n\t\t\tcongress.DeleteDevice(app.EUI, v.device.EUI)\n\t\t}\n\t}\n}", "func cleanToBeDeleted(nodes []*apiv1.Node, client kube_client.Interface, recorder kube_record.EventRecorder) {\n\tfor _, node := range nodes {\n\t\tcleaned, err := deletetaint.CleanToBeDeleted(node, client)\n\t\tif err != nil {\n\t\t\tglog.Warningf(\"Error while releasing taints on node %v: %v\", node.Name, err)\n\t\t\trecorder.Eventf(node, apiv1.EventTypeWarning, \"ClusterAutorepairCleanup\",\n\t\t\t\t\"failed to clean toBeDeletedTaint: %v\", err)\n\t\t} else if cleaned {\n\t\t\tglog.V(1).Infof(\"Successfully released toBeDeletedTaint on node %v\", node.Name)\n\t\t\trecorder.Eventf(node, apiv1.EventTypeNormal, \"ClusterAutorepairCleanup\", \"marking the node as schedulable\")\n\t\t}\n\t}\n}", "func (t *Test) clear() error {\n\treturn t.m3comparator.clear()\n}", "func (eng *Engine) Clean() {\n\tfor _, f := range eng.Junk {\n\t\tif err := os.Remove(f); err != nil {\n\t\t\teng.logf(\"clean: %v\\n\", err)\n\t\t}\n\t}\n}", "func (baseModel *BaseModel) ClearBase(specificModel AppliedAlgorithm) {\n for x := 0; x < baseModel.Fmx; x++ {\n for y := 0; y < baseModel.Fmy; y++ {\n for t := 0; t < baseModel.T; t++ {\n baseModel.Wave[x][y][t] = true\n }\n baseModel.Changes[x][y] = false\n }\n }\n if !baseModel.RngSet {\n baseModel.Rng = rand.New(rand.NewSource(time.Now().UnixNano())).Float64\n }\n baseModel.InitiliazedField = true\n baseModel.GenerationSuccessful = false\n}", "func treeModelFinalizer(tm *TreeModel) {\n\truntime.SetFinalizer(tm, func(tm *TreeModel) { gobject.Unref(tm) })\n}", "func textBufferFinalizer(t *TextBuffer) {\n\truntime.SetFinalizer(t, func(t *TextBuffer) { gobject.Unref(t) })\n}", "func (transport *IRCTransport) cleanUp() {\n\tclose(transport.messages)\n\tclose(transport.floodSemaphore)\n}", "func (a *AStarSolver) Clean() {\n\ta.tree = nil\n\ta.nodeGScore = make(map[*AStarNode]int)\n\ta.nodeFScore = make(map[*AStarNode]int)\n\ta.openSet = make(map[*AStarNode]interface{})\n\ta.wordList = []string{}\n\ta.usefulWords = []string{}\n}", "func (res *SendResult) clean() {\n\tres.index = 0\n\tres.err = nil\n\tres.msg = nil\n\tres.reference = nil\n}", "func (b *GoGLBackendOffscreen) Delete() {\n\tgl.DeleteTextures(1, &b.offscrBuf.tex)\n\tgl.DeleteFramebuffers(1, &b.offscrBuf.frameBuf)\n\tgl.DeleteRenderbuffers(1, &b.offscrBuf.renderStencilBuf)\n}", "func (ctx *Context) deleteConfigMaps(obj interface{}) {\n\tlog.Logger.Debug(\"configMap deleted\")\n}", "func (ridt *CFGoReadLexUnit) Clean() {\n}", "func (m *Postgres) cleanup(t time.Time) error {\n\tres, err := m.db.Exec(`DELETE FROM persist WHERE saved < $1`, t)\n\n\tif err != nil {\n\t\treturn fmt.Errorf(\"delete exec: %w\", err)\n\t}\n\n\trows, err := res.RowsAffected()\n\tif err != nil {\n\t\treturn fmt.Errorf(\"rows affected: %w\", err)\n\t}\n\n\tif rows > 0 {\n\t\tklog.Infof(\"Deleted %d rows of stale data\", rows)\n\t}\n\n\treturn nil\n}", "func (j *TrainingJob) delete() {\n\tj.gc.CollectJob(j.job.Metadata.Name, garbagecollection.NullUID)\n}", "func (e *eventsBatcher) clear() {\n\te.meta = map[string]int{}\n\te.evts = []*evtsapi.Event{}\n\te.expiredEvts = []*evtsapi.Event{}\n}", "func (g *testGenerator) Destroy() {\n\tg.Generator.Destroy()\n}", "func (t *Transform) Reset() {\n\tt.access.Lock()\n\tt.parent = nil\n\tt.built = nil\n\tt.localToWorld = nil\n\tt.worldToLocal = nil\n\tt.quat = nil\n\tt.pos = lmath.Vec3Zero\n\tt.rot = lmath.Vec3Zero\n\tt.scale = lmath.Vec3One\n\tt.shear = lmath.Vec3Zero\n\tt.access.Unlock()\n}", "func (o RecordMeasureSlice) DeleteAllGP() {\n\tif err := o.DeleteAllG(); err != nil {\n\t\tpanic(boil.WrapErr(err))\n\t}\n}", "func destroyObjects(p *pkcs11.Ctx, session pkcs11.SessionHandle, handles []pkcs11.ObjectHandle) error {\n\tfor _, o := range handles {\n\t\terr := p.DestroyObject(session, o)\n\t\tif err != nil {\n\t\t\treturn fmt.Errorf(\"Error destroying object %d: %v\", o, err)\n\t\t}\n\t}\n\treturn nil\n}", "func cleanUpPreviousData(conn mongo.Conn) {\n\tlog.Print(\"\\n\\n== Clear documents and indexes created by previous run. ==\\n\")\n\tdb := mongo.Database{conn, CFG.Main.DatabaseName, mongo.DefaultLastErrorCmd}\n\tdb.Run(mongo.D{{\"profile\", 0}}, nil)\n\tdb.C(offers).Remove(nil)\n\tdb.Run(mongo.D{{\"dropIndexes\", offers}, {\"index\", \"*\"}}, nil)\n}", "func accelGroupFinalizer(ag *AccelGroup) {\n\truntime.SetFinalizer(ag, func(ag *AccelGroup) { gobject.Unref(ag) })\n}", "func (tx *TextureBase) Delete(sc *Scene) {\n\tif tx.Tex != nil {\n\t\ttx.Tex.Delete()\n\t}\n\ttx.Tex = nil\n}", "func (material *Material) Delete() error {\n\t// Delete the material from all the books that contained it\n\tfor book := range StreamBooks() {\n\t\tif book.Remove(material.ID) {\n\t\t\tbook.Save()\n\t\t}\n\t}\n\n\t// Delete all samples for this material\n\tfor _, sample := range material.Samples() {\n\t\tsample.Delete()\n\t}\n\n\t// Delete all image files\n\tfor _, output := range materialImageOutputs {\n\t\toutput.Delete(material.ID)\n\t}\n\n\tDB.Delete(\"Material\", material.ID)\n\treturn nil\n}", "func (t *Targets) Cleanup(context context.Context, instance *iter8v1alpha2.Experiment) {\n\tif instance.Spec.Cleanup != nil && *instance.Spec.Cleanup {\n\t\tassessment := instance.Status.Assessment\n\t\ttoKeep := make(map[string]bool)\n\t\tswitch instance.Spec.GetOnTermination() {\n\t\tcase iter8v1alpha2.OnTerminationToWinner:\n\t\t\tif assessment != nil && assessment.Winner != nil && assessment.Winner.WinnerFound {\n\t\t\t\ttoKeep[assessment.Winner.Winner] = true\n\t\t\t} else {\n\t\t\t\ttoKeep[instance.Spec.Baseline] = true\n\t\t\t}\n\t\tcase iter8v1alpha2.OnTerminationToBaseline:\n\t\t\ttoKeep[instance.Spec.Baseline] = true\n\t\tcase iter8v1alpha2.OnTerminationKeepLast:\n\t\t\tif assessment != nil {\n\t\t\t\tif assessment.Baseline.Weight > 0 {\n\t\t\t\t\ttoKeep[assessment.Baseline.Name] = true\n\t\t\t\t}\n\t\t\t\tfor _, candidate := range assessment.Candidates {\n\t\t\t\t\tif candidate.Weight > 0 {\n\t\t\t\t\t\ttoKeep[candidate.Name] = true\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\tsvcNamespace := instance.ServiceNamespace()\n\t\t// delete baseline\n\t\tif ok := toKeep[instance.Spec.Baseline]; !ok {\n\t\t\terr := t.client.Delete(context, &appsv1.Deployment{\n\t\t\t\tObjectMeta: metav1.ObjectMeta{\n\t\t\t\t\tNamespace: svcNamespace,\n\t\t\t\t\tName: instance.Spec.Baseline,\n\t\t\t\t},\n\t\t\t})\n\t\t\tif err != nil {\n\t\t\t\tutil.Logger(context).Error(err, \"Error when deleting baseline\")\n\t\t\t}\n\t\t}\n\n\t\t// delete candidates\n\t\tfor _, candidate := range instance.Spec.Candidates {\n\t\t\tif ok := toKeep[candidate]; !ok {\n\t\t\t\terr := t.client.Delete(context, &appsv1.Deployment{\n\t\t\t\t\tObjectMeta: metav1.ObjectMeta{\n\t\t\t\t\t\tNamespace: svcNamespace,\n\t\t\t\t\t\tName: candidate,\n\t\t\t\t\t},\n\t\t\t\t})\n\t\t\t\tif err != nil {\n\t\t\t\t\tutil.Logger(context).Error(err, \"Error when deleting candidate\", \"name\", candidate)\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n}", "func (eng *Engine) Destroy() {\n\tfor _, rt := range eng.applied {\n\t\trt.destroy()\n\t}\n}", "func textTagTableFinalizer(t *TextTagTable) {\n\truntime.SetFinalizer(t, func(t *TextTagTable) { gobject.Unref(t) })\n}", "func (acker *acker) Free() {\n\tfor k, _ := range acker.fmap {\n\t\tacker.fmap[k] = nil\n\t}\n\tacker.fmap = nil\n\tacker.mutex = nil\n}", "func Clean(transaction string) {\n\tfor k, v := range kafkaProducer {\n\t\terr := v.clean(transaction)\n\t\tif err != nil {\n\t\t\tLogger().Error(transaction, \"kafka.producer.clean.failed\", \"Failed to clean %s producer during. Error %v\", k, err)\n\t\t}\n\t}\n}", "func (chain *B2ChainShape) Destroy() {\n\tchain.Clear()\n}", "func clean(isa *isabellebot.Bot) {\n\tisa.Service.Event.Clean()\n\tisa.Service.Trade.Clean()\n\tisa.Service.User.Clean()\n}", "func cleanUpSubmittedTxs(ctx context.Context, db pg.DB) {\n\tticker := time.NewTicker(15 * time.Minute)\n\tfor {\n\t\tselect {\n\t\tcase <-ticker.C:\n\t\t\t// TODO(jackson): We could avoid expensive bulk deletes by partitioning\n\t\t\t// the table and DROP-ing tables of expired rows. Partitioning doesn't\n\t\t\t// play well with ON CONFLICT clauses though, so we would need to rework\n\t\t\t// how we guarantee uniqueness.\n\t\t\tconst q = `DELETE FROM submitted_txs WHERE submitted_at < now() - interval '1 day'`\n\t\t\t_, err := db.Exec(ctx, q)\n\t\t\tif err != nil {\n\t\t\t\tlog.Error(ctx, err)\n\t\t\t}\n\t\tcase <-ctx.Done():\n\t\t\tticker.Stop()\n\t\t\treturn\n\t\t}\n\t}\n}", "func (n *nativeShader) free() {\n\t// Delete shader objects (in practice we should be able to do this directly\n\t// after linking, but it would just leave the driver to reference count\n\t// them anyway).\n\tgl.DeleteShader(n.vertex)\n\tgl.DeleteShader(n.fragment)\n\n\t// Delete program.\n\tgl.DeleteProgram(n.program)\n\n\t// Zero-out the nativeShader structure, only keeping the rsrcManager around.\n\t*n = nativeShader{\n\t\tr: n.r,\n\t}\n}", "func textTagFinalizer(t *TextTag) {\n\truntime.SetFinalizer(t, func(t *TextTag) { gobject.Unref(t) })\n}", "func (p *MyPipeline) Del(keys ...interface{}) client.Result {\n\treturn p.Pipeline.Del(keys)\n}", "func (r *Transformer) flushUncombined(ctx context.Context) {\n\tfor source := range r.batchMap {\n\t\tfor _, entry := range r.batchMap[source].entries {\n\t\t\tr.Write(ctx, entry)\n\t\t}\n\t\tr.removeBatch(source)\n\t}\n\tr.ticker.Reset(r.forceFlushTimeout)\n}", "func (s *atomixStore) unregisterSrcTgt(obj *topoapi.Object) {\n\tif entity := obj.GetEntity(); entity != nil {\n\t\ts.relations.lock.Lock()\n\t\tdefer s.relations.lock.Unlock()\n\t\tdelete(s.relations.sources, obj.ID)\n\t\tdelete(s.relations.targets, obj.ID)\n\n\t} else if relation := obj.GetRelation(); relation != nil {\n\t\ts.relations.lock.Lock()\n\t\tdefer s.relations.lock.Unlock()\n\t\ts.relations.sources[relation.SrcEntityID] = remove(s.relations.sources[relation.SrcEntityID], obj.ID)\n\t\ts.relations.targets[relation.TgtEntityID] = remove(s.relations.targets[relation.TgtEntityID], obj.ID)\n\t}\n}", "func (t *Tempo) Free() {\n\tif t.o == nil {\n\t\treturn\n\t}\n\tC.del_aubio_tempo(t.o)\n\tt.o = nil\n}", "func cleanup(t *testing.T, namespace string) {\n\targs := \"delete\"\n\tif namespace != \"\" {\n\t\targs += \" -n \" + namespace\n\t}\n\n\terr, stdout, stderr := runSonobuoyCommand(t, args)\n\n\tif err != nil {\n\t\tt.Logf(\"Error encountered during cleanup: %q\\n\", err)\n\t\tt.Log(stdout.String())\n\t\tt.Log(stderr.String())\n\t}\n}", "func (a *API) DeleteDerivedAssetsByTransformation(ctx context.Context, params DeleteDerivedAssetsByTransformationParams) (*DeleteAssetsResult, error) {\n\tparams.KeepOriginal = true\n\n\tres := &DeleteAssetsResult{}\n\t_, err := a.delete(ctx, api.BuildPath(assets, params.AssetType, params.DeliveryType), params, res)\n\n\treturn res, err\n}", "func (bm *OCRBatchImageManager) CleanUp() error {\n\tTRACE.Println(\"OCRBatchImageManager.CleanUp\", bm.tempfolder)\n\terr := os.RemoveAll(bm.tempfolder)\n\tif err != nil {\n\t\tERROR.Println(\"OCRBatchImageManager.CleanUp\", err)\n\t}\n\treturn err\n}" ]
[ "0.645302", "0.6008011", "0.59977126", "0.5943766", "0.5832797", "0.5782055", "0.5718664", "0.56616575", "0.5651121", "0.5597557", "0.5583479", "0.55381304", "0.55122805", "0.55047", "0.54990405", "0.54836154", "0.5415833", "0.5379488", "0.5369852", "0.5332091", "0.5332091", "0.53098696", "0.5293643", "0.52920127", "0.52472126", "0.52220654", "0.52170646", "0.5185738", "0.51689917", "0.51619595", "0.5139069", "0.5133422", "0.5131624", "0.51311916", "0.512393", "0.5123615", "0.50948894", "0.5088817", "0.5082966", "0.50815123", "0.5081369", "0.5080011", "0.50616443", "0.50556725", "0.50495386", "0.5049136", "0.50422907", "0.504183", "0.50264704", "0.502125", "0.4997895", "0.4995312", "0.49947846", "0.49943858", "0.498437", "0.49835125", "0.4981573", "0.4980485", "0.49787745", "0.49732667", "0.49611685", "0.49603733", "0.4960144", "0.49572104", "0.4943253", "0.49395254", "0.49379468", "0.49320853", "0.49304244", "0.4927065", "0.49269488", "0.49267522", "0.49221718", "0.49221", "0.49212244", "0.49120384", "0.4911658", "0.49104407", "0.4905926", "0.49024743", "0.49011156", "0.48969668", "0.48965994", "0.48926154", "0.4886822", "0.48834032", "0.48828143", "0.48821118", "0.4879219", "0.48720068", "0.48666397", "0.4866363", "0.48627064", "0.48531184", "0.4851045", "0.4849647", "0.48486948", "0.48485932", "0.48406842" ]
0.5392651
18
delete vertex array objects
func DeleteVertexArrays(n int32, arrays *uint32) { C.glowDeleteVertexArrays(gpDeleteVertexArrays, (C.GLsizei)(n), (*C.GLuint)(unsafe.Pointer(arrays))) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func DeleteVertexArrary(n int32, arrays *uint32) {\n\t//gl.DeleteVertexArraysAPPLE(n, arrays)\n\tgl.DeleteVertexArrays(n, arrays)\n}", "func DeleteVertexArrays(n int32, arrays *uint32) {\n C.glowDeleteVertexArrays(gpDeleteVertexArrays, (C.GLsizei)(n), (*C.GLuint)(unsafe.Pointer(arrays)))\n}", "func (vao *VAO) Delete() {\n\t// delete buffers\n\tif vao.vertexBuffers != nil {\n\t\tfor _, vertBuf := range vao.vertexBuffers {\n\t\t\tvertBuf.Delete()\n\t\t}\n\t}\n\tvao.indexBuffer.Delete()\n\n\t// delete vertex array\n\tgl.DeleteVertexArrays(1, &vao.handle)\n}", "func DeleteVertexArrays(n int32, arrays *uint32) {\n\tsyscall.Syscall(gpDeleteVertexArrays, 2, uintptr(n), uintptr(unsafe.Pointer(arrays)), 0)\n}", "func (debugging *debuggingOpenGL) DeleteVertexArrays(arrays []uint32) {\n\tdebugging.recordEntry(\"DeleteVertexArrays\", arrays)\n\tdebugging.gl.DeleteVertexArrays(arrays)\n\tdebugging.recordExit(\"DeleteVertexArrays\")\n}", "func (native *OpenGL) DeleteVertexArrays(arrays []uint32) {\n\tgl.DeleteVertexArrays(int32(len(arrays)), &arrays[0])\n}", "func main () {\n\tvertices := make(map[string]int)\n\n\tvertices[\"triangle\"] = 2\n\tvertices[\"square\"] = 3\n\tvertices[\"dodecagon\"] = 12\n\n delete(vertices, \"square\")\n\n\tfmt.Println(vertices)\n\tfmt.Println(vertices[\"triangle\"])\n}", "func (b *Builder) clearMesh() {\n\tfor _, key := range b.localInstances.Keys() {\n\t\tb.localInstances.Delete(key)\n\t}\n}", "func (x *FzVertex) Free() {\n\tif x != nil {\n\t\tC.free(unsafe.Pointer(x))\n\t}\n}", "func (g *Geometry) Free() {\n\tgl.DeleteVertexArrays(1, &g.handle)\n\tg.IndexBuffer.free()\n\tg.PositionBuffer.free()\n\tg.NormalBuffer.free()\n\tg.TexCoordBuffer.free()\n}", "func (s *Scene) Delete() {\n\ts.propOctree = nil\n\ts.props = nil\n\n\ts.bodyPool = nil\n\ts.dynamicBodies = nil\n\n\ts.firstSBConstraint = nil\n\ts.lastSBConstraint = nil\n\n\ts.firstDBConstraint = nil\n\ts.lastDBConstraint = nil\n}", "func doDeleteMesh(componentMeshName string) {\n\tcr := visibleMeshes[componentMeshName]\n\tcr.Renderable.Destroy()\n\tcr.Renderable = nil\n\tdelete(visibleMeshes, componentMeshName)\n}", "func (s *System) clear() {\n\ts.vertex = 0\n\ts.indice = 0\n\n\tvar i int\n\tfor j := range s.particles {\n\t\tp := &s.particles[j]\n\t\tif p.progress >= 1 {\n\t\t\tcontinue\n\t\t}\n\n\t\tp.vertex = s.vertex\n\t\tp.indice = s.indice\n\n\t\ts.vertex += p.vertexes\n\t\ts.indice += p.indices\n\n\t\ts.particles[i] = *p\n\t\ti++\n\t}\n\n\ts.particles = s.particles[:i]\n\n\treturn\n}", "func (spriteBatch *SpriteBatch) Clear() {\n\tspriteBatch.arrayBuf = newVertexBuffer(spriteBatch.size*4*8, []float32{}, spriteBatch.usage)\n\tspriteBatch.count = 0\n}", "func (ob *Obj3D) DeleteObjs(objs []string) {\n\tfor ci, _ := range ob.ObjFilesAll {\n\t\tofcat := ob.ObjFilesAll[ci]\n\t\tno := len(ofcat)\n\t\tfor oi := no - 1; oi >= 0; oi-- {\n\t\t\tofl := ofcat[oi]\n\t\t\tdel := false\n\t\t\tfor _, cs := range objs {\n\t\t\t\tif strings.Contains(ofl, cs) {\n\t\t\t\t\tdel = true\n\t\t\t\t\tbreak\n\t\t\t\t}\n\t\t\t}\n\t\t\tif del {\n\t\t\t\tofcat = append(ofcat[:oi], ofcat[oi+1:]...)\n\t\t\t}\n\t\t}\n\t\tob.ObjFilesAll[ci] = ofcat\n\t}\n\tob.Split()\n\tob.Flats()\n}", "func (o RecordMeasureSlice) DeleteAllGP() {\n\tif err := o.DeleteAllG(); err != nil {\n\t\tpanic(boil.WrapErr(err))\n\t}\n}", "func (o SkinSlice) DeleteAllGP() {\n\tif err := o.DeleteAllG(); err != nil {\n\t\tpanic(boil.WrapErr(err))\n\t}\n}", "func (o SourceSlice) DeleteAllGP() {\n\tif err := o.DeleteAllG(); err != nil {\n\t\tpanic(boil.WrapErr(err))\n\t}\n}", "func (o PhenotypepropSlice) DeleteAllGP() {\n\tif err := o.DeleteAllG(); err != nil {\n\t\tpanic(boil.WrapErr(err))\n\t}\n}", "func (elems *Elements) delete(pt dvid.Point3d) (deleted *Element, changed bool) {\n\t// Delete any elements at point.\n\tvar cut = -1\n\tfor i, elem := range *elems {\n\t\tif pt.Equals(elem.Pos) {\n\t\t\tcut = i\n\t\t\tbreak\n\t\t}\n\t}\n\tif cut >= 0 {\n\t\tdeleted = (*elems)[cut].Copy()\n\t\tchanged = true\n\t\t(*elems)[cut] = (*elems)[len(*elems)-1] // Delete without preserving order.\n\t\t*elems = (*elems)[:len(*elems)-1]\n\t}\n\n\t// Delete any relationships with the point.\n\tif elems.deleteRel(pt) {\n\t\tchanged = true\n\t}\n\treturn\n}", "func (q *QuadTree) Clear() {\n\tq.objects = make([]*Rectangle, 0)\n\tfor _, node := range q.nodes {\n\t\tnode.Clear()\n\t}\n\tq.nodes = make(map[int]*QuadTree, 4)\n}", "func (o JetSlice) DeleteAllGP() {\n\tif err := o.DeleteAllG(); err != nil {\n\t\tpanic(boil.WrapErr(err))\n\t}\n}", "func (o InstrumentClassSlice) DeleteAllGP() {\n\tif err := o.DeleteAllG(); err != nil {\n\t\tpanic(boil.WrapErr(err))\n\t}\n}", "func DeleteTransformFeedbacks(n int32, ids *uint32) {\n C.glowDeleteTransformFeedbacks(gpDeleteTransformFeedbacks, (C.GLsizei)(n), (*C.GLuint)(unsafe.Pointer(ids)))\n}", "func (o FeatureCvtermDbxrefSlice) DeleteAllP(exec boil.Executor) {\n\tif err := o.DeleteAll(exec); err != nil {\n\t\tpanic(boil.WrapErr(err))\n\t}\n}", "func (o SkinSlice) DeleteAllP(exec boil.Executor) {\n\tif err := o.DeleteAll(exec); err != nil {\n\t\tpanic(boil.WrapErr(err))\n\t}\n}", "func (c *vertexCollection) Unload(ctx context.Context) error {\n\tif err := c.rawCollection().Unload(ctx); err != nil {\n\t\treturn WithStack(err)\n\t}\n\treturn nil\n}", "func (o SourceSlice) DeleteAllP(exec boil.Executor) {\n\tif err := o.DeleteAll(exec); err != nil {\n\t\tpanic(boil.WrapErr(err))\n\t}\n}", "func (o FeatureCvtermDbxrefSlice) DeleteAllGP() {\n\tif err := o.DeleteAllG(); err != nil {\n\t\tpanic(boil.WrapErr(err))\n\t}\n}", "func (c *cube) trash() {\n\tfor len(c.cells) > 0 {\n\t\tc.removeCell()\n\t}\n}", "func (o RawVisitSlice) DeleteAll(ctx context.Context, exec boil.ContextExecutor) (int64, error) {\n\tif len(o) == 0 {\n\t\treturn 0, nil\n\t}\n\n\tif len(rawVisitBeforeDeleteHooks) != 0 {\n\t\tfor _, obj := range o {\n\t\t\tif err := obj.doBeforeDeleteHooks(ctx, exec); err != nil {\n\t\t\t\treturn 0, err\n\t\t\t}\n\t\t}\n\t}\n\n\tvar args []interface{}\n\tfor _, obj := range o {\n\t\tpkeyArgs := queries.ValuesFromMapping(reflect.Indirect(reflect.ValueOf(obj)), rawVisitPrimaryKeyMapping)\n\t\targs = append(args, pkeyArgs...)\n\t}\n\n\tsql := \"DELETE FROM \\\"raw_visits\\\" WHERE \" +\n\t\tstrmangle.WhereClauseRepeated(string(dialect.LQ), string(dialect.RQ), 1, rawVisitPrimaryKeyColumns, len(o))\n\n\tif boil.IsDebug(ctx) {\n\t\twriter := boil.DebugWriterFrom(ctx)\n\t\tfmt.Fprintln(writer, sql)\n\t\tfmt.Fprintln(writer, args)\n\t}\n\tresult, err := exec.ExecContext(ctx, sql, args...)\n\tif err != nil {\n\t\treturn 0, errors.Wrap(err, \"models: unable to delete all from rawVisit slice\")\n\t}\n\n\trowsAff, err := result.RowsAffected()\n\tif err != nil {\n\t\treturn 0, errors.Wrap(err, \"models: failed to get rows affected by deleteall for raw_visits\")\n\t}\n\n\tif len(rawVisitAfterDeleteHooks) != 0 {\n\t\tfor _, obj := range o {\n\t\t\tif err := obj.doAfterDeleteHooks(ctx, exec); err != nil {\n\t\t\t\treturn 0, err\n\t\t\t}\n\t\t}\n\t}\n\n\treturn rowsAff, nil\n}", "func (gdt *Array) Destroy() {\n\targ0 := gdt.getBase()\n\n\tC.go_godot_array_destroy(GDNative.api, arg0)\n}", "func (o AssetRevisionSlice) DeleteAllGP() {\n\tif err := o.DeleteAllG(); err != nil {\n\t\tpanic(boil.WrapErr(err))\n\t}\n}", "func (b *GoGLBackendOffscreen) Delete() {\n\tgl.DeleteTextures(1, &b.offscrBuf.tex)\n\tgl.DeleteFramebuffers(1, &b.offscrBuf.frameBuf)\n\tgl.DeleteRenderbuffers(1, &b.offscrBuf.renderStencilBuf)\n}", "func (o SkinSlice) DeleteAll(exec boil.Executor) error {\n\tif o == nil {\n\t\treturn errors.New(\"models: no Skin slice provided for delete all\")\n\t}\n\n\tif len(o) == 0 {\n\t\treturn nil\n\t}\n\n\tif len(skinBeforeDeleteHooks) != 0 {\n\t\tfor _, obj := range o {\n\t\t\tif err := obj.doBeforeDeleteHooks(exec); err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\t\t}\n\t}\n\n\tvar args []interface{}\n\tfor _, obj := range o {\n\t\tpkeyArgs := queries.ValuesFromMapping(reflect.Indirect(reflect.ValueOf(obj)), skinPrimaryKeyMapping)\n\t\targs = append(args, pkeyArgs...)\n\t}\n\n\tsql := \"DELETE FROM `skin` WHERE \" +\n\t\tstrmangle.WhereClauseRepeated(string(dialect.LQ), string(dialect.RQ), 0, skinPrimaryKeyColumns, len(o))\n\n\tif boil.DebugMode {\n\t\tfmt.Fprintln(boil.DebugWriter, sql)\n\t\tfmt.Fprintln(boil.DebugWriter, args)\n\t}\n\n\t_, err := exec.Exec(sql, args...)\n\tif err != nil {\n\t\treturn errors.Wrap(err, \"models: unable to delete all from skin slice\")\n\t}\n\n\tif len(skinAfterDeleteHooks) != 0 {\n\t\tfor _, obj := range o {\n\t\t\tif err := obj.doAfterDeleteHooks(exec); err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\t\t}\n\t}\n\n\treturn nil\n}", "func (renderbuffer Renderbuffer) Delete() {\n\t// TODO: Is it somehow possible to get &uint32(renderbuffer) without assigning it to renderbuffers?\n\trenderbuffers := uint32(renderbuffer)\n\tgl.DeleteRenderbuffers(1, &renderbuffers)\n}", "func (o InstrumentClassSlice) DeleteAllP(exec boil.Executor) {\n\tif err := o.DeleteAll(exec); err != nil {\n\t\tpanic(boil.WrapErr(err))\n\t}\n}", "func (g *Group) DeleteAll() {\n\tg.Equivalents = list.New()\n\tg.Fingerprints = make(map[string]*list.Element)\n\tg.FirstExpr = make(map[Operand]*list.Element)\n\tg.SelfFingerprint = \"\"\n}", "func (o PhenotypepropSlice) DeleteAllP(exec boil.Executor) {\n\tif err := o.DeleteAll(exec); err != nil {\n\t\tpanic(boil.WrapErr(err))\n\t}\n}", "func DeleteTransformFeedbacks(n int32, ids *uint32) {\n\tsyscall.Syscall(gpDeleteTransformFeedbacks, 2, uintptr(n), uintptr(unsafe.Pointer(ids)), 0)\n}", "func (o RecordMeasureSlice) DeleteAllP(exec boil.Executor) {\n\tif err := o.DeleteAll(exec); err != nil {\n\t\tpanic(boil.WrapErr(err))\n\t}\n}", "func (native *OpenGL) DeleteBuffers(buffers []uint32) {\n\tgl.DeleteBuffers(int32(len(buffers)), &buffers[0])\n}", "func (r Relationships) delete(todel []int) Relationships {\n\tout := make(Relationships, len(r)-len(todel))\n\tj, k := 0, 0\n\tfor i, rel := range r {\n\t\tif k >= len(todel) || i != todel[k] {\n\t\t\tout[j] = rel\n\t\t\tj++\n\t\t} else {\n\t\t\tk++\n\t\t}\n\t}\n\treturn out\n}", "func (elems *ElementsNR) delete(pt dvid.Point3d) (deleted *ElementNR, changed bool) {\n\t// Delete any elements at point.\n\tvar cut = -1\n\tfor i, elem := range *elems {\n\t\tif pt.Equals(elem.Pos) {\n\t\t\tcut = i\n\t\t\tbreak\n\t\t}\n\t}\n\tif cut >= 0 {\n\t\tdeleted = (*elems)[cut].Copy()\n\t\tchanged = true\n\t\t(*elems)[cut] = (*elems)[len(*elems)-1] // Delete without preserving order.\n\t\t*elems = (*elems)[:len(*elems)-1]\n\t}\n\treturn\n}", "func (r *OutlineRenderer) cleanUp() {\n\tr.shader.CleanUp()\n}", "func (o JetSlice) DeleteAll(exec boil.Executor) error {\n\tif o == nil {\n\t\treturn errors.New(\"models: no Jet slice provided for delete all\")\n\t}\n\n\tif len(o) == 0 {\n\t\treturn nil\n\t}\n\n\tif len(jetBeforeDeleteHooks) != 0 {\n\t\tfor _, obj := range o {\n\t\t\tif err := obj.doBeforeDeleteHooks(exec); err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\t\t}\n\t}\n\n\tvar args []interface{}\n\tfor _, obj := range o {\n\t\tpkeyArgs := queries.ValuesFromMapping(reflect.Indirect(reflect.ValueOf(obj)), jetPrimaryKeyMapping)\n\t\targs = append(args, pkeyArgs...)\n\t}\n\n\tsql := \"DELETE FROM `jets` WHERE \" +\n\t\tstrmangle.WhereClauseRepeated(string(dialect.LQ), string(dialect.RQ), 0, jetPrimaryKeyColumns, len(o))\n\n\tif boil.DebugMode {\n\t\tfmt.Fprintln(boil.DebugWriter, sql)\n\t\tfmt.Fprintln(boil.DebugWriter, args)\n\t}\n\n\t_, err := exec.Exec(sql, args...)\n\tif err != nil {\n\t\treturn errors.Wrap(err, \"models: unable to delete all from jet slice\")\n\t}\n\n\tif len(jetAfterDeleteHooks) != 0 {\n\t\tfor _, obj := range o {\n\t\t\tif err := obj.doAfterDeleteHooks(exec); err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\t\t}\n\t}\n\n\treturn nil\n}", "func (o JetSlice) DeleteAllP(exec boil.Executor) {\n\tif err := o.DeleteAll(exec); err != nil {\n\t\tpanic(boil.WrapErr(err))\n\t}\n}", "func (o StockCvtermSlice) DeleteAllGP() {\n\tif err := o.DeleteAllG(); err != nil {\n\t\tpanic(boil.WrapErr(err))\n\t}\n}", "func (t *Track) Clean() {\n\tfor i := 0; i < len(t.samples); i++ {\n\t\tt.samples[i] = nil\n\t}\n\tt.samples = t.samples[:0]\n\tt.samples = nil\n}", "func (o SegmentSlice) DeleteAll(ctx context.Context, exec boil.ContextExecutor) (int64, error) {\n\tif len(o) == 0 {\n\t\treturn 0, nil\n\t}\n\n\tif len(segmentBeforeDeleteHooks) != 0 {\n\t\tfor _, obj := range o {\n\t\t\tif err := obj.doBeforeDeleteHooks(ctx, exec); err != nil {\n\t\t\t\treturn 0, err\n\t\t\t}\n\t\t}\n\t}\n\n\tvar args []interface{}\n\tfor _, obj := range o {\n\t\tpkeyArgs := queries.ValuesFromMapping(reflect.Indirect(reflect.ValueOf(obj)), segmentPrimaryKeyMapping)\n\t\targs = append(args, pkeyArgs...)\n\t}\n\n\tsql := \"DELETE FROM \\\"segment\\\" WHERE \" +\n\t\tstrmangle.WhereClauseRepeated(string(dialect.LQ), string(dialect.RQ), 1, segmentPrimaryKeyColumns, len(o))\n\n\tif boil.IsDebug(ctx) {\n\t\twriter := boil.DebugWriterFrom(ctx)\n\t\tfmt.Fprintln(writer, sql)\n\t\tfmt.Fprintln(writer, args)\n\t}\n\tresult, err := exec.ExecContext(ctx, sql, args...)\n\tif err != nil {\n\t\treturn 0, errors.Wrap(err, \"boiler: unable to delete all from segment slice\")\n\t}\n\n\trowsAff, err := result.RowsAffected()\n\tif err != nil {\n\t\treturn 0, errors.Wrap(err, \"boiler: failed to get rows affected by deleteall for segment\")\n\t}\n\n\tif len(segmentAfterDeleteHooks) != 0 {\n\t\tfor _, obj := range o {\n\t\t\tif err := obj.doAfterDeleteHooks(ctx, exec); err != nil {\n\t\t\t\treturn 0, err\n\t\t\t}\n\t\t}\n\t}\n\n\treturn rowsAff, nil\n}", "func (gdt *Array) Erase(value Variant) {\n\targ0 := gdt.getBase()\n\targ1 := value.getBase()\n\n\tC.go_godot_array_erase(GDNative.api, arg0, arg1)\n}", "func (r *gui3dRenderer) cleanUp() {\n\t\tr.shader.CleanUp()\n}", "func (o CvtermsynonymSlice) DeleteAllGP() {\n\tif err := o.DeleteAllG(); err != nil {\n\t\tpanic(boil.WrapErr(err))\n\t}\n}", "func delete(array []int8, pos int) []int8 {\r\n\tvar length = len(array)\r\n\tvar tempArray = make([]int8, length+1)\r\n\tfmt.Printf(\"\\n\")\r\n\tfor i := 0; i < length; i++ {\r\n\t\tif i < pos {\r\n\t\t\ttempArray[i] = array[i]\r\n\t\t} else {\r\n\t\t\ttempArray[i-1] = array[i]\r\n\t\t}\r\n\t}\r\n\treturn tempArray\r\n\r\n}", "func (p *panel) trash() {\n\tif p.slab != nil {\n\t\tp.slab.Dispose()\n\t\tp.slab = nil\n\t}\n\tfor _, cube := range p.cubes {\n\t\tcube.reset(0)\n\t}\n}", "func (o DMessageEmbedSlice) DeleteAllGP() {\n\tif err := o.DeleteAllG(); err != nil {\n\t\tpanic(boil.WrapErr(err))\n\t}\n}", "func (o StockCvtermSlice) DeleteAllP(exec boil.Executor) {\n\tif err := o.DeleteAll(exec); err != nil {\n\t\tpanic(boil.WrapErr(err))\n\t}\n}", "func (am *Manager) Clean() {\n\tfor name, m := range am.Materials {\n\t\tLogger.Printf(\"Manager: deleting Material '%s'\\n\", name)\n\t\tm.Clean()\n\t\tdelete(am.Materials, name)\n\t}\n\tfor name, m := range am.Meshes {\n\t\tLogger.Printf(\"Manager: deleting Mesh '%s'\\n\", name)\n\t\tm.Clean()\n\t\tdelete(am.Meshes, name)\n\t}\n\tfor set, prog := range am.Programs {\n\t\tLogger.Printf(\"Manager: deleting Program '%v'\\n\", set)\n\t\tgl.DeleteProgram(prog)\n\t\tdelete(am.Programs, set)\n\t}\n\tfor name, shader := range am.Shaders {\n\t\tLogger.Printf(\"Manager: deleting Shader '%s'\\n\", name)\n\t\tgl.DeleteShader(shader)\n\t\tdelete(am.Shaders, name)\n\t}\n\tfor name, tex := range am.Textures {\n\t\tLogger.Printf(\"Manager: deleting Texture '%s'\\n\", name)\n\t\ttex.Clean()\n\t\tdelete(am.Textures, name)\n\t}\n}", "func (debugging *debuggingOpenGL) DeleteFramebuffers(buffers []uint32) {\n\tdebugging.recordEntry(\"DeleteFramebuffers\", buffers)\n\tdebugging.gl.DeleteFramebuffers(buffers)\n\tdebugging.recordExit(\"DeleteFramebuffers\")\n}", "func DeleteBuffers(buffers []Buffer) {\n\tgl.DeleteBuffers(gl.Sizei(len(buffers)), (*gl.Uint)(&buffers[0]))\n}", "func (debugging *debuggingOpenGL) DeleteBuffers(buffers []uint32) {\n\tdebugging.recordEntry(\"DeleteBuffers\", buffers)\n\tdebugging.gl.DeleteBuffers(buffers)\n\tdebugging.recordExit(\"DeleteBuffers\")\n}", "func (o FeatureRelationshipSlice) DeleteAllP(exec boil.Executor) {\n\tif err := o.DeleteAll(exec); err != nil {\n\t\tpanic(boil.WrapErr(err))\n\t}\n}", "func (am *AssetManager) Clean() {\n\tfor name, model := range am.Models {\n\t\tmodel.Delete()\n\t\tdelete(am.Models, name)\n\t}\n\tfor name, tex := range am.Textures {\n\t\ttex.Delete()\n\t\tdelete(am.Textures, name)\n\t}\n\tfor name, prog := range am.Programs {\n\t\tprog.Delete()\n\t\tdelete(am.Programs, name)\n\t}\n}", "func (o BraceletPhotoSlice) DeleteAllGP() {\n\tif err := o.DeleteAllG(); err != nil {\n\t\tpanic(boil.WrapErr(err))\n\t}\n}", "func (sb *SkyBox) Dispose() {\n\tgl := sb.window.OpenGL()\n\n\tgl.DeleteVertexArrays([]uint32{sb.glVAO})\n\tgl.DeleteProgram(sb.shaderProgram)\n}", "func (o VSPSlice) DeleteAll(ctx context.Context, exec boil.ContextExecutor) (int64, error) {\n\tif len(o) == 0 {\n\t\treturn 0, nil\n\t}\n\n\tvar args []interface{}\n\tfor _, obj := range o {\n\t\tpkeyArgs := queries.ValuesFromMapping(reflect.Indirect(reflect.ValueOf(obj)), vspPrimaryKeyMapping)\n\t\targs = append(args, pkeyArgs...)\n\t}\n\n\tsql := \"DELETE FROM \\\"vsp\\\" WHERE \" +\n\t\tstrmangle.WhereClauseRepeated(string(dialect.LQ), string(dialect.RQ), 1, vspPrimaryKeyColumns, len(o))\n\n\tif boil.IsDebug(ctx) {\n\t\twriter := boil.DebugWriterFrom(ctx)\n\t\tfmt.Fprintln(writer, sql)\n\t\tfmt.Fprintln(writer, args)\n\t}\n\tresult, err := exec.ExecContext(ctx, sql, args...)\n\tif err != nil {\n\t\treturn 0, errors.Wrap(err, \"models: unable to delete all from vsp slice\")\n\t}\n\n\trowsAff, err := result.RowsAffected()\n\tif err != nil {\n\t\treturn 0, errors.Wrap(err, \"models: failed to get rows affected by deleteall for vsp\")\n\t}\n\n\treturn rowsAff, nil\n}", "func (n *nativeShader) free() {\n\t// Delete shader objects (in practice we should be able to do this directly\n\t// after linking, but it would just leave the driver to reference count\n\t// them anyway).\n\tgl.DeleteShader(n.vertex)\n\tgl.DeleteShader(n.fragment)\n\n\t// Delete program.\n\tgl.DeleteProgram(n.program)\n\n\t// Zero-out the nativeShader structure, only keeping the rsrcManager around.\n\t*n = nativeShader{\n\t\tr: n.r,\n\t}\n}", "func DeleteBuffers(n int32, buffers *uint32) {\n C.glowDeleteBuffers(gpDeleteBuffers, (C.GLsizei)(n), (*C.GLuint)(unsafe.Pointer(buffers)))\n}", "func (o PhenotypepropSlice) DeleteAllG() error {\n\tif o == nil {\n\t\treturn errors.New(\"chado: no Phenotypeprop slice provided for delete all\")\n\t}\n\treturn o.DeleteAll(boil.GetDB())\n}", "func (o OrganismSlice) DeleteAllGP() {\n\tif err := o.DeleteAllG(); err != nil {\n\t\tpanic(boil.WrapErr(err))\n\t}\n}", "func (mg *Graph) DelVertex(key string) error {\n\tsession := mg.ar.session.Copy()\n\tdefer session.Close()\n\n\tvCol := mg.ar.VertexCollection(session, mg.graph)\n\terr := vCol.RemoveId(key)\n\tif err != nil {\n\t\treturn fmt.Errorf(\"failed to delete vertex %s: %s\", key, err)\n\t}\n\tmg.ts.Touch(mg.graph)\n\terr = mg.deleteConnectedEdges(key)\n\tif err != nil {\n\t\treturn err\n\t}\n\treturn nil\n}", "func (o PictureSlice) DeleteAllGP() {\n\tif err := o.DeleteAllG(); err != nil {\n\t\tpanic(boil.WrapErr(err))\n\t}\n}", "func (o InventorySlice) DeleteAllGP() {\n\tif err := o.DeleteAllG(); err != nil {\n\t\tpanic(boil.WrapErr(err))\n\t}\n}", "func deleteRegistry(w http.ResponseWriter, req *http.Request) {\n\tvar sStore SpecificStore\n\t_ = json.NewDecoder(req.Body).Decode(&sStore)\n\n\tif len(array) == 0 {\n\t\tfmt.Println(\"$$$Primero debe llenar el arreglo con informacion\")\n\t\tjson.NewEncoder(w).Encode(\"Primero debe llenar el arreglo con informacion\")\n\t\treturn\n\t}\n\n\tfmt.Println(\"$$$Buscando tienda con los parametros especificados\")\n\tfor i := 0; i < len(array); i++ {\n\t\tif array[i].Department == sStore.Departament && array[i].Rating == sStore.Rating {\n\t\t\tfor j := 0; j < array[i].List.lenght; j++ {\n\t\t\t\ttempNode, _ := array[i].List.GetNodeAt(j)\n\t\t\t\ttempName := tempNode.data.Name\n\t\t\t\tif tempName == sStore.Name {\n\t\t\t\t\tarray[i].List.DeleteNode(j)\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\tprintArray(array)\n\n}", "func (array *Array) Remove(object interface{}) {\n\tvar data []interface{}\n\n\tfor _, content := range array.data {\n\t\tif object != content {\n\t\t\tdata = append(data, content)\n\t\t}\n\t}\n\n\tarray.data = data\n}", "func (d *DAG) DeleteVertex(id string) error {\n\n\td.muDAG.Lock()\n\tdefer d.muDAG.Unlock()\n\n\tif err := d.saneID(id); err != nil {\n\t\treturn err\n\t}\n\n\tv := d.vertexIds[id]\n\n\t// get descendents and ancestors as they are now\n\tdescendants := copyMap(d.getDescendants(v))\n\tancestors := copyMap(d.getAncestors(v))\n\n\t// delete v in outbound edges of parents\n\tif _, exists := d.inboundEdge[v]; exists {\n\t\tfor parent := range d.inboundEdge[v] {\n\t\t\tdelete(d.outboundEdge[parent], v)\n\t\t}\n\t}\n\n\t// delete v in inbound edges of children\n\tif _, exists := d.outboundEdge[v]; exists {\n\t\tfor child := range d.outboundEdge[v] {\n\t\t\tdelete(d.inboundEdge[child], v)\n\t\t}\n\t}\n\n\t// delete in- and outbound of v itself\n\tdelete(d.inboundEdge, v)\n\tdelete(d.outboundEdge, v)\n\n\t// for v and all its descendants delete cached ancestors\n\tfor descendant := range descendants {\n\t\tdelete(d.ancestorsCache, descendant)\n\t}\n\tdelete(d.ancestorsCache, v)\n\n\t// for v and all its ancestors delete cached descendants\n\tfor ancestor := range ancestors {\n\t\tdelete(d.descendantsCache, ancestor)\n\t}\n\tdelete(d.descendantsCache, v)\n\n\t// delete v itself\n\tdelete(d.vertices, v)\n\tdelete(d.vertexIds, id)\n\n\treturn nil\n}", "func (o FeatureRelationshipSlice) DeleteAllGP() {\n\tif err := o.DeleteAllG(); err != nil {\n\t\tpanic(boil.WrapErr(err))\n\t}\n}", "func (fb *FlatBatch) Delete(key []byte) error { panic(\"not supported\") }", "func deleteOpenings() {\n setMaze(getInt(&begX) - 1, getInt(&begY), wall)\n setMaze(getInt(&endX) + 1, getInt(&endY), wall)\n}", "func (o CvtermsynonymSlice) DeleteAllP(exec boil.Executor) {\n\tif err := o.DeleteAll(exec); err != nil {\n\t\tpanic(boil.WrapErr(err))\n\t}\n}", "func (o DMessageEmbedSlice) DeleteAllP(exec boil.Executor) {\n\tif err := o.DeleteAll(exec); err != nil {\n\t\tpanic(boil.WrapErr(err))\n\t}\n}", "func (gdt *Array) Clear() {\n\targ0 := gdt.getBase()\n\n\tC.go_godot_array_clear(GDNative.api, arg0)\n}", "func DeleteQueries(n int32, ids *uint32) {\n C.glowDeleteQueries(gpDeleteQueries, (C.GLsizei)(n), (*C.GLuint)(unsafe.Pointer(ids)))\n}", "func (o StockSlice) DeleteAllGP() {\n\tif err := o.DeleteAllG(); err != nil {\n\t\tpanic(boil.WrapErr(err))\n\t}\n}", "func (o AssetRevisionSlice) DeleteAllP(exec boil.Executor) {\n\tif err := o.DeleteAll(exec); err != nil {\n\t\tpanic(boil.WrapErr(err))\n\t}\n}", "func (o TransactionSlice) DeleteAllGP() {\n\tif err := o.DeleteAllG(); err != nil {\n\t\tpanic(boil.WrapErr(err))\n\t}\n}", "func (o TransactionSlice) DeleteAllGP() {\n\tif err := o.DeleteAllG(); err != nil {\n\t\tpanic(boil.WrapErr(err))\n\t}\n}", "func (o ShelfSlice) DeleteAllGP() {\n\tif err := o.DeleteAllG(); err != nil {\n\t\tpanic(boil.WrapErr(err))\n\t}\n}", "func (o SourceSlice) DeleteAll(exec boil.Executor) error {\n\tif o == nil {\n\t\treturn errors.New(\"mdbmdbmodels: no Source slice provided for delete all\")\n\t}\n\n\tif len(o) == 0 {\n\t\treturn nil\n\t}\n\n\tvar args []interface{}\n\tfor _, obj := range o {\n\t\tpkeyArgs := queries.ValuesFromMapping(reflect.Indirect(reflect.ValueOf(obj)), sourcePrimaryKeyMapping)\n\t\targs = append(args, pkeyArgs...)\n\t}\n\n\tsql := \"DELETE FROM \\\"sources\\\" WHERE \" +\n\t\tstrmangle.WhereClauseRepeated(string(dialect.LQ), string(dialect.RQ), 1, sourcePrimaryKeyColumns, len(o))\n\n\tif boil.DebugMode {\n\t\tfmt.Fprintln(boil.DebugWriter, sql)\n\t\tfmt.Fprintln(boil.DebugWriter, args)\n\t}\n\n\t_, err := exec.Exec(sql, args...)\n\tif err != nil {\n\t\treturn errors.Wrap(err, \"mdbmdbmodels: unable to delete all from source slice\")\n\t}\n\n\treturn nil\n}", "func (s *Server) objectDelete(\n\tsess *pb.Session,\n\tuuids []string,\n) error {\n\treq := &pb.ObjectDeleteByUuidsRequest{\n\t\tSession: sess,\n\t\tUuids: uuids,\n\t}\n\tmc, err := s.metaClient()\n\tif err != nil {\n\t\treturn err\n\t}\n\t_, err = mc.ObjectDeleteByUuids(context.Background(), req)\n\tif err != nil {\n\t\treturn err\n\t}\n\treturn nil\n}", "func (p *IntArray) Delete_at(del_index int) {\n\ttmp := *p\n\tvar new_array IntArray\n\tfor i := 0; i < len(tmp); i++ {\n\t\tif i != del_index {\n\t\t\tnew_array = append(new_array, tmp[i])\n\t\t}\n\t}\n\t*p = new_array\n}", "func (o BraceletPhotoSlice) DeleteAllP(exec boil.Executor) {\n\tif err := o.DeleteAll(exec); err != nil {\n\t\tpanic(boil.WrapErr(err))\n\t}\n}", "func (o PhenotypepropSlice) DeleteAll(exec boil.Executor) error {\n\tif o == nil {\n\t\treturn errors.New(\"chado: no Phenotypeprop slice provided for delete all\")\n\t}\n\n\tif len(o) == 0 {\n\t\treturn nil\n\t}\n\n\tif len(phenotypepropBeforeDeleteHooks) != 0 {\n\t\tfor _, obj := range o {\n\t\t\tif err := obj.doBeforeDeleteHooks(exec); err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\t\t}\n\t}\n\n\tvar args []interface{}\n\tfor _, obj := range o {\n\t\tpkeyArgs := queries.ValuesFromMapping(reflect.Indirect(reflect.ValueOf(obj)), phenotypepropPrimaryKeyMapping)\n\t\targs = append(args, pkeyArgs...)\n\t}\n\n\tsql := fmt.Sprintf(\n\t\t\"DELETE FROM \\\"phenotypeprop\\\" WHERE (%s) IN (%s)\",\n\t\tstrings.Join(strmangle.IdentQuoteSlice(dialect.LQ, dialect.RQ, phenotypepropPrimaryKeyColumns), \",\"),\n\t\tstrmangle.Placeholders(dialect.IndexPlaceholders, len(o)*len(phenotypepropPrimaryKeyColumns), 1, len(phenotypepropPrimaryKeyColumns)),\n\t)\n\n\tif boil.DebugMode {\n\t\tfmt.Fprintln(boil.DebugWriter, sql)\n\t\tfmt.Fprintln(boil.DebugWriter, args)\n\t}\n\n\t_, err := exec.Exec(sql, args...)\n\tif err != nil {\n\t\treturn errors.Wrap(err, \"chado: unable to delete all from phenotypeprop slice\")\n\t}\n\n\tif len(phenotypepropAfterDeleteHooks) != 0 {\n\t\tfor _, obj := range o {\n\t\t\tif err := obj.doAfterDeleteHooks(exec); err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\t\t}\n\t}\n\n\treturn nil\n}", "func (o MempoolBinSlice) DeleteAll(ctx context.Context, exec boil.ContextExecutor) (int64, error) {\n\tif len(o) == 0 {\n\t\treturn 0, nil\n\t}\n\n\tvar args []interface{}\n\tfor _, obj := range o {\n\t\tpkeyArgs := queries.ValuesFromMapping(reflect.Indirect(reflect.ValueOf(obj)), mempoolBinPrimaryKeyMapping)\n\t\targs = append(args, pkeyArgs...)\n\t}\n\n\tsql := \"DELETE FROM \\\"mempool_bin\\\" WHERE \" +\n\t\tstrmangle.WhereClauseRepeated(string(dialect.LQ), string(dialect.RQ), 1, mempoolBinPrimaryKeyColumns, len(o))\n\n\tif boil.IsDebug(ctx) {\n\t\twriter := boil.DebugWriterFrom(ctx)\n\t\tfmt.Fprintln(writer, sql)\n\t\tfmt.Fprintln(writer, args)\n\t}\n\tresult, err := exec.ExecContext(ctx, sql, args...)\n\tif err != nil {\n\t\treturn 0, errors.Wrap(err, \"models: unable to delete all from mempoolBin slice\")\n\t}\n\n\trowsAff, err := result.RowsAffected()\n\tif err != nil {\n\t\treturn 0, errors.Wrap(err, \"models: failed to get rows affected by deleteall for mempool_bin\")\n\t}\n\n\treturn rowsAff, nil\n}", "func (s *AssetsStorage) Destroy() {\n\ts.Grid.Destroy()\n\tfor _, dot := range s.Dots {\n\t\tdot.Destroy()\n\t}\n\tfor _, vl := range s.VertLines {\n\t\tvl.Destroy()\n\t}\n\tfor _, hl := range s.HorizLines {\n\t\thl.Destroy()\n\t}\n}", "func (rl *RayLine) Dispose() {\n\tgl := rl.window.OpenGL()\n\n\tgl.DeleteVertexArrays([]uint32{rl.glVAO})\n\tgl.DeleteProgram(rl.shaderProgram)\n}", "func (o StockSlice) DeleteAllP(exec boil.Executor) {\n\tif err := o.DeleteAll(exec); err != nil {\n\t\tpanic(boil.WrapErr(err))\n\t}\n}", "func (o PictureSlice) DeleteAllP(exec boil.Executor) {\n\tif err := o.DeleteAll(exec); err != nil {\n\t\tpanic(boil.WrapErr(err))\n\t}\n}", "func freeCGeoPolygon(cgp *C.GeoPolygon) {\n\tC.free(unsafe.Pointer(cgp.geofence.verts))\n\tcgp.geofence.verts = nil\n\n\tph := unsafe.Pointer(cgp.holes)\n\tfor i := C.int(0); i < cgp.numHoles; i++ {\n\t\tC.free(unsafe.Pointer((*C.Geofence)(ph).verts))\n\t\t(*C.Geofence)(ph).verts = nil\n\t\tph = unsafe.Pointer(uintptr(ph) + uintptr(C.sizeof_Geofence))\n\t}\n\n\tC.free(unsafe.Pointer(cgp.holes))\n\tcgp.holes = nil\n}" ]
[ "0.701914", "0.66842765", "0.6656226", "0.66041267", "0.6423954", "0.63811654", "0.6082875", "0.5691226", "0.5612787", "0.547888", "0.54655266", "0.5417572", "0.5301518", "0.5276028", "0.52451503", "0.5235245", "0.5234327", "0.52165896", "0.5184187", "0.51493686", "0.5106114", "0.5103176", "0.5092813", "0.5090607", "0.5054612", "0.50425315", "0.5040352", "0.50385153", "0.5026652", "0.5017767", "0.5017285", "0.50166976", "0.5006945", "0.4996756", "0.4982143", "0.49759808", "0.49713612", "0.4966707", "0.49655288", "0.4961766", "0.49577928", "0.49492085", "0.49380115", "0.49367487", "0.49352157", "0.4934958", "0.4929028", "0.49275264", "0.49263823", "0.49260452", "0.4922986", "0.4921588", "0.49186498", "0.4917361", "0.49158323", "0.4914392", "0.49117038", "0.4901714", "0.48959103", "0.48955607", "0.4892001", "0.48912424", "0.48864675", "0.48805335", "0.48795903", "0.4878485", "0.4876635", "0.48584464", "0.4856471", "0.48482415", "0.4846269", "0.48363683", "0.48335984", "0.48290175", "0.48281127", "0.48271883", "0.48265684", "0.48243564", "0.48228967", "0.48217902", "0.4821785", "0.48213065", "0.4820136", "0.48182455", "0.48173067", "0.48143464", "0.48143464", "0.4809771", "0.48061597", "0.4798508", "0.47909755", "0.478045", "0.4778741", "0.4778091", "0.47773868", "0.47764328", "0.47713748", "0.47613907", "0.4745894" ]
0.6186586
7
specify the value used for depth buffer comparisons
func DepthFunc(xfunc uint32) { C.glowDepthFunc(gpDepthFunc, (C.GLenum)(xfunc)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func DepthRange(near float64, far float64) {\n C.glowDepthRange(gpDepthRange, (C.GLdouble)(near), (C.GLdouble)(far))\n}", "func (mParams *EncodingMatrixLiteral) Depth(actual bool) (depth int) {\n\tif actual {\n\t\tdepth = len(mParams.ScalingFactor)\n\t} else {\n\t\tfor i := range mParams.ScalingFactor {\n\t\t\tfor range mParams.ScalingFactor[i] {\n\t\t\t\tdepth++\n\t\t\t}\n\t\t}\n\t}\n\treturn\n}", "func DepthFunc(xfunc uint32) {\n C.glowDepthFunc(gpDepthFunc, (C.GLenum)(xfunc))\n}", "func DepthRangeIndexed(index uint32, n float64, f float64) {\n C.glowDepthRangeIndexed(gpDepthRangeIndexed, (C.GLuint)(index), (C.GLdouble)(n), (C.GLdouble)(f))\n}", "func (t *Track) BufferDepth() float64 {\n\tduration := int64(0)\n\tfor i := 0; i < len(t.chunksDuration); i++ {\n\t\tif t.chunksDuration[i] > duration {\n\t\t\tduration = t.chunksDuration[i]\n\t\t}\n\t}\n\treturn float64(duration) / float64(len(t.chunksDuration))\n}", "func DepthMask(flag bool) {\n C.glowDepthMask(gpDepthMask, (C.GLboolean)(boolToInt(flag)))\n}", "func DepthRange(n float64, f float64) {\n\tsyscall.Syscall(gpDepthRange, 2, uintptr(math.Float64bits(n)), uintptr(math.Float64bits(f)), 0)\n}", "func DepthRangef(n float32, f float32) {\n\tsyscall.Syscall(gpDepthRangef, 2, uintptr(math.Float32bits(n)), uintptr(math.Float32bits(f)), 0)\n}", "func (dev *Device) SetDepthBuffer(buf unsafe.Pointer) int {\n\treturn int(C.freenect_set_depth_buffer(dev.ptr(), buf))\n}", "func (s *stencilOverdraw) loadExistingDepthValues(ctx context.Context,\n\tcb CommandBuilder,\n\tgs *api.GlobalState,\n\tst *State,\n\ta arena.Arena,\n\tdevice VkDevice,\n\tqueue VkQueue,\n\tcmdBuffer VkCommandBuffer,\n\trenderInfo renderInfo,\n\talloc func(v ...interface{}) api.AllocResult,\n\taddCleanup func(func()),\n\tout transform.Writer,\n) error {\n\tif renderInfo.depthIdx == ^uint32(0) {\n\t\treturn nil\n\t}\n\trpInfo := st.RenderPasses().Get(renderInfo.renderPass)\n\tdaInfo := rpInfo.AttachmentDescriptions().Get(renderInfo.depthIdx)\n\n\tif daInfo.LoadOp() != VkAttachmentLoadOp_VK_ATTACHMENT_LOAD_OP_LOAD {\n\t\treturn nil\n\t}\n\n\tfbInfo := st.Framebuffers().Get(renderInfo.framebuffer)\n\n\toldImageView := fbInfo.ImageAttachments().Get(renderInfo.depthIdx)\n\tnewImageView := fbInfo.ImageAttachments().Get(uint32(fbInfo.ImageAttachments().Len() - 1))\n\n\toldImageDesc := imageDesc{\n\t\toldImageView.Image(),\n\t\toldImageView.SubresourceRange(),\n\t\tdaInfo.InitialLayout(),\n\t\tVkImageAspectFlagBits_VK_IMAGE_ASPECT_DEPTH_BIT,\n\t}\n\tnewImageDesc := imageDesc{\n\t\tnewImageView.Image(),\n\t\tnewImageView.SubresourceRange(),\n\t\tVkImageLayout_VK_IMAGE_LAYOUT_DEPTH_STENCIL_ATTACHMENT_OPTIMAL,\n\t\tVkImageAspectFlagBits_VK_IMAGE_ASPECT_DEPTH_BIT,\n\t}\n\n\treturn s.transferDepthValues(ctx, cb, gs, st, a,\n\t\tdevice, queue, cmdBuffer,\n\t\tfbInfo.Width(), fbInfo.Height(),\n\t\toldImageDesc, newImageDesc,\n\t\talloc, addCleanup, out)\n}", "func DepthFunc(fn Enum) {\n\tgl.DepthFunc(uint32(fn))\n}", "func setDepth(p0 int, pool []huffmanTree, depth []byte, max_depth int) bool {\n\tvar stack [16]int\n\tvar level int = 0\n\tvar p int = p0\n\tassert(max_depth <= 15)\n\tstack[0] = -1\n\tfor {\n\t\tif pool[p].index_left_ >= 0 {\n\t\t\tlevel++\n\t\t\tif level > max_depth {\n\t\t\t\treturn false\n\t\t\t}\n\t\t\tstack[level] = int(pool[p].index_right_or_value_)\n\t\t\tp = int(pool[p].index_left_)\n\t\t\tcontinue\n\t\t} else {\n\t\t\tdepth[pool[p].index_right_or_value_] = byte(level)\n\t\t}\n\n\t\tfor level >= 0 && stack[level] == -1 {\n\t\t\tlevel--\n\t\t}\n\t\tif level < 0 {\n\t\t\treturn true\n\t\t}\n\t\tp = stack[level]\n\t\tstack[level] = -1\n\t}\n}", "func DepthRangef(n float32, f float32) {\n\tC.glowDepthRangef(gpDepthRangef, (C.GLfloat)(n), (C.GLfloat)(f))\n}", "func DepthRangef(n float32, f float32) {\n\tC.glowDepthRangef(gpDepthRangef, (C.GLfloat)(n), (C.GLfloat)(f))\n}", "func MaxLodPixel(value int) *SimpleElement { return newSEInt(\"maxLodPixels\", value) }", "func DepthMask(flag bool) {\n\tsyscall.Syscall(gpDepthMask, 1, boolToUintptr(flag), 0, 0)\n}", "func DepthRange(n float64, f float64) {\n\tC.glowDepthRange(gpDepthRange, (C.GLdouble)(n), (C.GLdouble)(f))\n}", "func DepthRange(n float64, f float64) {\n\tC.glowDepthRange(gpDepthRange, (C.GLdouble)(n), (C.GLdouble)(f))\n}", "func DepthMask(flag Boolean) {\n\tcflag, _ := (C.GLboolean)(flag), cgoAllocsUnknown\n\tC.glDepthMask(cflag)\n}", "func DepthFunc(xfunc uint32) {\n\tsyscall.Syscall(gpDepthFunc, 1, uintptr(xfunc), 0, 0)\n}", "func MinLodPixel(value int) *SimpleElement { return newSEInt(\"minLodPixels\", value) }", "func (s *stencilOverdraw) storeNewDepthValues(ctx context.Context,\n\tcb CommandBuilder,\n\tgs *api.GlobalState,\n\tst *State,\n\ta arena.Arena,\n\tdevice VkDevice,\n\tqueue VkQueue,\n\tcmdBuffer VkCommandBuffer,\n\trenderInfo renderInfo,\n\talloc func(v ...interface{}) api.AllocResult,\n\taddCleanup func(func()),\n\tout transform.Writer,\n) error {\n\tif renderInfo.depthIdx == ^uint32(0) {\n\t\treturn nil\n\t}\n\trpInfo := st.RenderPasses().Get(renderInfo.renderPass)\n\tdaInfo := rpInfo.AttachmentDescriptions().Get(renderInfo.depthIdx)\n\n\tif daInfo.StoreOp() != VkAttachmentStoreOp_VK_ATTACHMENT_STORE_OP_STORE {\n\t\treturn nil\n\t}\n\n\tfbInfo := st.Framebuffers().Get(renderInfo.framebuffer)\n\n\toldImageView := fbInfo.ImageAttachments().Get(uint32(fbInfo.ImageAttachments().Len() - 1))\n\tnewImageView := fbInfo.ImageAttachments().Get(renderInfo.depthIdx)\n\n\toldImageDesc := imageDesc{\n\t\toldImageView.Image(),\n\t\toldImageView.SubresourceRange(),\n\t\trpInfo.AttachmentDescriptions().Get(uint32(fbInfo.ImageAttachments().Len() - 1)).FinalLayout(),\n\t\tVkImageAspectFlagBits_VK_IMAGE_ASPECT_DEPTH_BIT,\n\t}\n\tnewImageDesc := imageDesc{\n\t\tnewImageView.Image(),\n\t\tnewImageView.SubresourceRange(),\n\t\tdaInfo.FinalLayout(),\n\t\tVkImageAspectFlagBits_VK_IMAGE_ASPECT_DEPTH_BIT,\n\t}\n\treturn s.transferDepthValues(ctx, cb, gs, st, a,\n\t\tdevice, queue, cmdBuffer,\n\t\tfbInfo.Width(), fbInfo.Height(),\n\t\toldImageDesc, newImageDesc,\n\t\talloc, addCleanup, out)\n}", "func (t *Trace) LatchVal(i, depth int) bool {\n\tsz := len(t.Inputs) + len(t.Latches) + len(t.Watches)\n\toff := sz*depth + len(t.Inputs)\n\treturn t.values[off+i]\n}", "func DepthRangef(n, f float32) {\n\tgl.DepthRangef(n, f)\n}", "func GetRenderbufferDepthSize(target GLEnum) int32 {\n\tvar params int32\n\tgl.GetRenderbufferParameteriv(uint32(target), gl.RENDERBUFFER_DEPTH_SIZE, &params)\n\treturn params\n}", "func DepthRangef(n Float, f Float) {\n\tcn, _ := (C.GLfloat)(n), cgoAllocsUnknown\n\tcf, _ := (C.GLfloat)(f), cgoAllocsUnknown\n\tC.glDepthRangef(cn, cf)\n}", "func GetDepthModeCount() int {\n\treturn int(C.freenect_get_depth_mode_count())\n}", "func (p *Pit) Depth() int8 {\n\t// p.mu.RLock()\n\t// defer p.mu.RUnlock()\n\n\treturn p.depth\n}", "func (s *CountMinSketch) Depth() uint {\n\treturn s.d\n}", "func (kt KeyToken) MatchDepth(okt KeyToken) bool {\n\tif kt.Depth != okt.Depth {\n\t\treturn false\n\t}\n\treturn kt.Match(okt)\n}", "func DepthMask(flag bool) {\n\tC.glDepthMask(glBool(flag))\n}", "func DepthMask(flag bool) {\n\tgl.DepthMask(flag)\n}", "func value(player int, board [8][8]int, alpha float32, beta float32, depth int) float32 {\n\tval, _ := AlphaBeta(enemy(player), board, -beta, -alpha, depth-1)\n\n\treturn -val\n}", "func (g *Generator) atMaxDepth() bool {\n\treturn g.depth >= g.maxDepth\n}", "func VDepth(depth int, level Level) Verbose {\n\t// This function tries hard to be cheap unless there's work to do.\n\t// The fast path is two atomic loads and compares.\n\n\t// Here is a cheap but safe test to see if V logging is enabled globally.\n\tif logging.verbosity.get() >= level {\n\t\treturn newVerbose(level, true)\n\t}\n\n\t// It's off globally but vmodule may still be set.\n\t// Here is another cheap but safe test to see if vmodule is enabled.\n\tif atomic.LoadInt32(&logging.filterLength) > 0 {\n\t\t// Now we need a proper lock to use the logging structure. The pcs field\n\t\t// is shared so we must lock before accessing it. This is fairly expensive,\n\t\t// but if V logging is enabled we're slow anyway.\n\t\tlogging.mu.Lock()\n\t\tdefer logging.mu.Unlock()\n\t\tif runtime.Callers(2+depth, logging.pcs[:]) == 0 {\n\t\t\treturn newVerbose(level, false)\n\t\t}\n\t\t// runtime.Callers returns \"return PCs\", but we want\n\t\t// to look up the symbolic information for the call,\n\t\t// so subtract 1 from the PC. runtime.CallersFrames\n\t\t// would be cleaner, but allocates.\n\t\tpc := logging.pcs[0] - 1\n\t\tv, ok := logging.vmap[pc]\n\t\tif !ok {\n\t\t\tv = logging.setV(pc)\n\t\t}\n\t\treturn newVerbose(level, v >= level)\n\t}\n\treturn newVerbose(level, false)\n}", "func (o *Options) MaxDepth() int { return o.maxDepth }", "func DepthFunc(func_ GLenum) {\n\tC.glDepthFunc(C.GLenum(func_))\n}", "func (dev *Device) StartDepth() int {\n\treturn int(C.freenect_start_depth(dev.ptr()))\n}", "func Depth(index uint) (depth uint) {\n\tindex++\n\tfor (index & 1) == 0 {\n\t\tdepth++\n\t\tindex = rightShift(index)\n\t}\n\treturn\n}", "func (s *ImageSpec) Depth() int {\n\tret := int(C.ImageSpec_depth(s.ptr))\n\truntime.KeepAlive(s)\n\treturn ret\n}", "func (n *Node) Value(depth int) (v uint16) {\n\tif depth > 100 {\n\t\tfmt.Println(\"Too deep for\", n)\n\t\treturn\n\t}\n\tif n.cacheval != 0 {\n\t\treturn n.cacheval\n\t}\n\t//fmt.Printf(\"(%d) %s\\n\", depth, n)\n\tvar l, r uint16\n\tif n.Lref != \"\" {\n\t\t//fmt.Println(n.Op, \"finding value for l =\", n.Lref)\n\t\tl = n.P.NodeByKey(n.Lref).Value(depth + 1)\n\t} else {\n\t\t//fmt.Println(n.Op, \"using Lval\", n.Lval)\n\t\tl = n.Lval\n\t}\n\n\tif n.Rref != \"\" {\n\t\t//fmt.Println(n.Op, \"finding value for r =\", n.Rref)\n\t\tr = n.P.NodeByKey(n.Rref).Value(depth + 1)\n\t} else {\n\t\t//fmt.Println(n.Op, \"using Rval\", n.Rval)\n\t\tr = n.Rval\n\t}\n\n\tn.cacheval = n.F(l, r)\n\treturn n.cacheval\n}", "func DepthMask(flag bool) {\n\tC.glowDepthMask(gpDepthMask, (C.GLboolean)(boolToInt(flag)))\n}", "func DepthMask(flag bool) {\n\tC.glowDepthMask(gpDepthMask, (C.GLboolean)(boolToInt(flag)))\n}", "func Depth(e expr.Expr) uint {\n\t//fmt.Printf(\"%f\\n\",e)\n\t// TODO: implement this function\n\tswitch i:= e.(type){\n\tcase expr.Var:\n\n\tcase expr.Literal:\n\n\tcase expr.Unary:\n\t\treturn Depth(i.X) + 1\n\t\tbreak\n\tcase expr.Binary: \n\t\treturn Max(Depth(i.X),Depth(i.Y)) + 1\n\t\tbreak\n\tdefault: \n\t\tpanic(\"unrecognized character\")\n\t}\n\treturn 1\n}", "func (m *Mixer) Depth() Depth {\n\treturn Depth(C.al_get_mixer_depth((*C.ALLEGRO_MIXER)(m)))\n}", "func (ms Mounts) Less(i, j int) (result bool) { return ms.mountDepth(i) >= ms.mountDepth(j) }", "func DepthRangeIndexed(index uint32, n float64, f float64) {\n\tsyscall.Syscall(gpDepthRangeIndexed, 3, uintptr(index), uintptr(math.Float64bits(n)), uintptr(math.Float64bits(f)))\n}", "func (dev *Device) StopDepth() int {\n\treturn int(C.freenect_stop_depth(dev.ptr()))\n}", "func (native *OpenGL) DepthMask(mask bool) {\n\tgl.DepthMask(mask)\n}", "func (s *stencilOverdraw) getDepthAttachment(a arena.Arena,\n\trpInfo RenderPassObjectʳ,\n) (VkAttachmentDescription, uint32, error) {\n\tif rpInfo.SubpassDescriptions().Len() == 0 {\n\t\treturn NilVkAttachmentDescription, 0,\n\t\t\tfmt.Errorf(\"RenderPass %v has no subpasses\",\n\t\t\t\trpInfo.VulkanHandle())\n\t}\n\t// depth attachment: don't support them not all using the same one for now\n\tattachment0 := rpInfo.SubpassDescriptions().Get(0).DepthStencilAttachment()\n\tfor i := uint32(1); i < uint32(rpInfo.SubpassDescriptions().Len()); i++ {\n\t\tattachment := rpInfo.SubpassDescriptions().Get(i).DepthStencilAttachment()\n\t\tvar match bool\n\t\tif attachment0.IsNil() {\n\t\t\tmatch = attachment.IsNil()\n\t\t} else {\n\t\t\tmatch = !attachment.IsNil() &&\n\t\t\t\tattachment0.Attachment() == attachment.Attachment()\n\t\t}\n\t\tif !match {\n\t\t\t// TODO: Handle using separate depth attachments (make\n\t\t\t// a separate image for each one and combine them at\n\t\t\t// the end perhaps?)\n\t\t\treturn NilVkAttachmentDescription, 0, fmt.Errorf(\n\t\t\t\t\"The subpasses don't have matching depth attachments\")\n\t\t}\n\t}\n\tif attachment0.IsNil() ||\n\t\t// VK_ATTACHMENT_UNUSED\n\t\tattachment0.Attachment() == ^uint32(0) {\n\t\treturn NilVkAttachmentDescription, ^uint32(0), nil\n\t}\n\n\tattachmentDesc, ok := rpInfo.AttachmentDescriptions().Lookup(\n\t\tattachment0.Attachment(),\n\t)\n\tif !ok {\n\t\treturn NilVkAttachmentDescription, 0,\n\t\t\tfmt.Errorf(\"Invalid depth attachment\")\n\t}\n\n\treturn attachmentDesc, attachment0.Attachment(), nil\n}", "func minCameraCover(root *TreeNode) int {\n\tcamera, _, rootIsMonitored := helper968(root)\n\tif rootIsMonitored == false {\n\t\treturn camera + 1\n\t}\n\treturn camera\n}", "func SetDepthFunc(_func Enum) {\n\tc_func, _ := (C.GLenum)(_func), cgoAllocsUnknown\n\tC.glDepthFunc(c_func)\n}", "func maxDepth(n int) int {\n var depth int\n for i := n; i > 0; i >>= 1 {\n depth++\n }\n return depth * 2\n}", "func (f *Fuzzer) MaxDepth(d int) *Fuzzer {\n\tf.maxDepth = d\n\treturn f\n}", "func TestBoard_CalculateDepth(t *testing.T) {\n\ttype fields struct {\n\t\tGrid [3][3]int\n\t}\n\ttests := []struct {\n\t\tname string\n\t\tfields fields\n\t\twant int\n\t}{\n\t\t{name: \"Test-Empty-grid\", fields: fields{Grid: [3][3]int{\n\t\t\t{1, -1, -1}, {0, 1, -1}, {-1, 0, 1},\n\t\t}}, want: 4},\n\t}\n\tfor _, tt := range tests {\n\t\tt.Run(tt.name, func(t *testing.T) {\n\t\t\tboard := &Board{\n\t\t\t\tGrid: tt.fields.Grid,\n\t\t\t}\n\t\t\tif got := board.CalculateDepth(); got != tt.want {\n\t\t\t\tt.Errorf(\"CalculateDepth() = %v, want %v\", got, tt.want)\n\t\t\t}\n\t\t})\n\t}\n}", "func TestGetDepth(t *testing.T) {\n\tt.Parallel()\n\tcp, err := currency.NewPairFromString(\"BCHEUR\")\n\tif err != nil {\n\t\tt.Error(err)\n\t}\n\t_, err = k.GetDepth(context.Background(), cp)\n\tif err != nil {\n\t\tt.Error(\"GetDepth() error\", err)\n\t}\n}", "func parseDepth(option string) (*Option, error) {\n\tsplitoption := strings.Fields(option)\n\n\tif len(splitoption) == 0 {\n\t\treturn nil, fmt.Errorf(\"there is an unspecified depth option at an unknown line\")\n\t} else if len(splitoption) == 1 || len(splitoption) > 2 {\n\t\treturn nil, fmt.Errorf(\"there is a misconfigured depth option: %q.\\nIs it in format <option>:<whitespaces><regex><whitespaces><int>?\", option)\n\t}\n\n\tre, err := regexp.Compile(\"^\" + splitoption[0] + \"$\")\n\tif err != nil {\n\t\treturn nil, fmt.Errorf(\"an error occurred compiling the regex for a depth option: %q\\n%v\", option, err)\n\t}\n\n\tdepth, err := strconv.Atoi(splitoption[1])\n\tif err != nil {\n\t\treturn nil, fmt.Errorf(\"an error occurred parsing the integer depth value of a depth option: %q\\n%v\", option, err)\n\t}\n\n\treturn &Option{\n\t\tCategory: \"depth\",\n\t\tRegex: map[int]*regexp.Regexp{0: re},\n\t\tValue: depth,\n\t}, nil\n}", "func findMinDelay(depthRangeMap map[int]int) int {\n\tlayerOrder := (*findLayerOrder(depthRangeMap))\n\tvar layerDepthList [][]int\n\tfor _, layer := range layerOrder {\n\t\tr := depthRangeMap[layer]\n\t\tlayerDepthList = append(layerDepthList, []int{layer, (r - 1) << 1})\n\t}\n\tlenLayerDepthList := len(layerDepthList)\n\n\tfor delay := 0; ; delay += 1 {\n\t\tflagInt := 0\n\t\tfor _, item := range layerDepthList {\n\t\t\tif (delay+item[0])%(item[1]) == 0 {\n\t\t\t\tbreak\n\t\t\t}\n\t\t\tflagInt += 1\n\t\t}\n\t\tif lenLayerDepthList == flagInt {\n\t\t\treturn delay\n\t\t}\n\t}\n\treturn -1\n}", "func MinSampleShading(value float32) {\n C.glowMinSampleShading(gpMinSampleShading, (C.GLfloat)(value))\n}", "func (s *State) depth() Target {\n\treturn s.currentBlockNode().Depth\n}", "func Gte(val, min any) bool { return valueCompare(val, min, \">=\") }", "func (tree *Tree23) Depths() (int, int) {\n\treturn tree.minmaxDepth(tree.root)\n}", "func DepthRangeIndexed(index uint32, n float64, f float64) {\n\tC.glowDepthRangeIndexed(gpDepthRangeIndexed, (C.GLuint)(index), (C.GLdouble)(n), (C.GLdouble)(f))\n}", "func DepthRangeIndexed(index uint32, n float64, f float64) {\n\tC.glowDepthRangeIndexed(gpDepthRangeIndexed, (C.GLuint)(index), (C.GLdouble)(n), (C.GLdouble)(f))\n}", "func (o *Dig) GetDepthOk() (*int32, bool) {\n\tif o == nil {\n\t\treturn nil, false\n\t}\n\treturn &o.Depth, true\n}", "func maxDepth(n int) types.Depth {\r\n\tvar depth types.Depth\r\n\tfor i := n; i > 0; i >>= 1 {\r\n\t\tdepth++\r\n\t}\r\n\treturn depth * 2\r\n}", "func getDepth(x interface{}, depth int) int {\n\tswitch v := x.(type) {\n\tcase map[string]interface{}:\n\t\tdepth++\n\t\tfor _, el := range v {\n\t\t\tif d := getDepth(el, depth); d > depth {\n\t\t\t\tdepth = d\n\t\t\t}\n\t\t}\n\tcase []interface{}:\n\t\tdepth++\n\t\tfor _, el := range v {\n\t\t\tif d := getDepth(el, depth); d > depth {\n\t\t\t\tdepth = d\n\t\t\t}\n\t\t}\n\t}\n\n\treturn depth\n}", "func (w Widths) MaxDepth() (maxDepth, deepWidth int) {\n\tfor depth, width := range w {\n\t\tif depth > maxDepth {\n\t\t\tmaxDepth = depth\n\t\t\tdeepWidth = width\n\t\t}\n\t}\n\treturn\n}", "func (net *Network) Depth() int {\n\tmaxDepth := 0\n\tfor _, n := range net.All() {\n\t\tif n.distanceFromOutputNode > maxDepth {\n\t\t\tmaxDepth = n.distanceFromOutputNode\n\t\t}\n\t}\n\treturn maxDepth\n}", "func (gl *WebGL) DepthFunc(function GLEnum) {\n\tgl.context.Call(\"depthFunc\", function)\n}", "func (p *Params) FinalityDepth() uint64 {\n\treturn uint64(p.FinalityDuration / p.TargetTimePerBlock)\n}", "func trickleDepthInfo(node *h.FSNodeOverDag, maxlinks int) (depth int, repeatNumber int) {\n\tn := node.NumChildren()\n\n\tif n < maxlinks {\n\t\t// We didn't even added the initial `maxlinks` leaf nodes (`FillNodeLayer`).\n\t\treturn 0, 0\n\t}\n\n\tnonLeafChildren := n - maxlinks\n\t// The number of non-leaf child nodes added in `fillTrickleRec` (after\n\t// the `FillNodeLayer` call).\n\n\tdepth = nonLeafChildren/depthRepeat + 1\n\t// \"Deduplicate\" the added `depthRepeat` sub-graphs at each depth\n\t// (rounding it up since we may be on an unfinished depth with less\n\t// than `depthRepeat` sub-graphs).\n\n\trepeatNumber = nonLeafChildren % depthRepeat\n\t// What's left after taking full depths of `depthRepeat` sub-graphs\n\t// is the current `repeatNumber` we're at (this fractional part is\n\t// what we rounded up before).\n\n\treturn\n}", "func (node *AStarNode) Depth() int {\n\tscore := 0\n\ttmpNode := node\n\tfor tmpNode != nil {\n\t\tscore++\n\t\ttmpNode = tmpNode.previous\n\t}\n\treturn score\n}", "func (lhs VideoMode) Less(rhs VideoMode) bool {\n\tif lhs.BitsPerPixel != rhs.BitsPerPixel {\n\t\treturn lhs.BitsPerPixel < rhs.BitsPerPixel\n\t}\n\n\treturn lhs.Width*lhs.Height < rhs.Width*rhs.Height\n}", "func (native *OpenGL) DepthFunc(xfunc uint32) {\n\tgl.DepthFunc(xfunc)\n}", "func (d *diskQueue) Depth() int64 {\n\treturn atomic.LoadInt64(&d.depth)\n}", "func (c *GreaterEqual) Param() value.Value { return c.val }", "func (o *Dig) SetDepth(v int32) {\n\to.Depth = v\n}", "func (self *Graphics) BlendMode() int{\n return self.Object.Get(\"blendMode\").Int()\n}", "func (t *Trace) InputVal(i, depth int) bool {\n\tsz := len(t.Inputs) + len(t.Latches) + len(t.Watches)\n\toff := sz * depth\n\treturn t.values[off+i]\n}", "func SetMaxDepthDifference(maxDifference float64) {\n\tHeightMininum = maxDifference\n}", "func Ones(_, _ int, _ float64) float64 { return 1 }", "func (buf *CommandBuffer) SetDepthBias(constantFactor, clamp, slopeFactor float32) {\n\tC.domVkCmdSetDepthBias(buf.fps[vkCmdSetDepthBias], buf.hnd, C.float(constantFactor), C.float(clamp), C.float(slopeFactor))\n}", "func getLogDepth(ctx context.Context) int {\n\tif ctx == nil {\n\t\treturn 3\n\t}\n\tdepth := ctx.Value(\"log-depth\")\n\tif depth != nil {\n\t\tif ds, ok := depth.(int); ok {\n\t\t\treturn ds\n\t\t}\n\t}\n\treturn 3\n}", "func (sd *saturationDegree) pass() int {\n\tmaxSat, chosen := -1, -1\n\tsd.work = sd.work[:0]\n\tfor i, u := range sd.nodes {\n\t\tuid := u.ID()\n\t\tif _, ok := sd.colors[uid]; ok {\n\t\t\tcontinue\n\t\t}\n\t\ts := saturationDegreeOf(uid, sd.g, sd.colors)\n\t\tswitch {\n\t\tcase s > maxSat:\n\t\t\tmaxSat = s\n\t\t\tsd.work = sd.work[:0]\n\t\t\tfallthrough\n\t\tcase s == maxSat:\n\t\t\tsd.work = append(sd.work, i)\n\t\t}\n\t}\n\tmaxAvail := -1\n\tfor _, vs := range sd.work {\n\t\tvar avail int\n\t\tfor _, v := range sd.work {\n\t\t\tif v != vs {\n\t\t\t\tavail += sd.same(sd.adjColors[vs], sd.adjColors[v])\n\t\t\t}\n\t\t}\n\t\tswitch {\n\t\tcase avail > maxAvail, avail == maxAvail && sd.nodes[chosen].ID() < sd.nodes[vs].ID():\n\t\t\tmaxAvail = avail\n\t\t\tchosen = vs\n\t\t}\n\t}\n\treturn chosen\n}", "func FileDepth(d int) Option {\n\treturn func(opts *logOptions) {\n\t\topts.skipFrameCount = d\n\t}\n}", "func (tree *Tree23) minmaxDepth(t TreeNodeIndex) (int, int) {\n\tif tree.IsEmpty(t) {\n\t\treturn 0, 0\n\t}\n\tif tree.IsLeaf(t) {\n\t\treturn 1, 1\n\t}\n\tdepthMin := -1\n\tdepthMax := -1\n\n\tfor i := 0; i < tree.treeNodes[t].cCount; i++ {\n\t\tc := tree.treeNodes[t].children[i]\n\t\tmin, max := tree.minmaxDepth(c.child)\n\t\tif depthMin == -1 || min < depthMin {\n\t\t\tdepthMin = min + 1\n\t\t}\n\t\tif depthMax == -1 || max > depthMax {\n\t\t\tdepthMax = max + 1\n\t\t}\n\t}\n\treturn depthMin, depthMax\n}", "func ClearDepth(depth float64) {\n\tsyscall.Syscall(gpClearDepth, 1, uintptr(math.Float64bits(depth)), 0, 0)\n}", "func (this *fileStruct) BitDepth() uint16 {\n\treturn this.bitDepth\n}", "func ClearDepth(depth float64) {\n C.glowClearDepth(gpClearDepth, (C.GLdouble)(depth))\n}", "func isNodeAboveTargetUtilization(usage NodeUsage) bool {\n\tfor name, nodeValue := range usage.usage {\n\t\t// usage.highResourceThreshold[name] < nodeValue\n\t\tif usage.highResourceThreshold[name].Cmp(*nodeValue) == -1 {\n\t\t\treturn true\n\t\t}\n\t}\n\treturn false\n}", "func Frustum(left float64, right float64, bottom float64, top float64, zNear float64, zFar float64) {\n C.glowFrustum(gpFrustum, (C.GLdouble)(left), (C.GLdouble)(right), (C.GLdouble)(bottom), (C.GLdouble)(top), (C.GLdouble)(zNear), (C.GLdouble)(zFar))\n}", "func depthReached(i int, opts options.Options) bool {\n\tif opts.Depth != 0 && opts.Depth == i {\n\t\tlog.Warnf(\"Exceeded depth limit (%d)\", i)\n\t\treturn true\n\t}\n\treturn false\n}", "func (self *TileSprite) BlendMode() int{\n return self.Object.Get(\"blendMode\").Int()\n}", "func SampleCoverage(value float32, invert bool) {\n C.glowSampleCoverage(gpSampleCoverage, (C.GLfloat)(value), (C.GLboolean)(boolToInt(invert)))\n}", "func Gt(val, min any) bool { return valueCompare(val, min, \">\") }", "func ClearDepthf(d float32) {\n\tsyscall.Syscall(gpClearDepthf, 1, uintptr(math.Float32bits(d)), 0, 0)\n}", "func setDepthAndEntryCount(ds *dataset.Dataset, data qfs.File, mu *sync.Mutex, done chan error) {\n\tdefer data.Close()\n\n\ter, err := dsio.NewEntryReader(ds.Structure, data)\n\tif err != nil {\n\t\tlog.Debug(err.Error())\n\t\tdone <- fmt.Errorf(\"error reading data values: %s\", err.Error())\n\t\treturn\n\t}\n\n\tentries := 0\n\t// baseline of 1 for the original closure\n\tdepth := 1\n\tvar ent dsio.Entry\n\tfor {\n\t\tif ent, err = er.ReadEntry(); err != nil {\n\t\t\tlog.Debug(err.Error())\n\t\t\tbreak\n\t\t}\n\t\t// get the depth of this entry, update depth if larger\n\t\tif d := getDepth(ent.Value, 1); d > depth {\n\t\t\tdepth = d\n\t\t}\n\t\tentries++\n\t}\n\tif err.Error() != \"EOF\" {\n\t\tdone <- fmt.Errorf(\"error reading values at entry %d: %s\", entries, err.Error())\n\t\treturn\n\t}\n\n\tmu.Lock()\n\tds.Structure.Entries = entries\n\tds.Structure.Depth = depth\n\tmu.Unlock()\n\n\tdone <- nil\n}", "func (abi *AlphaBetaInfo) TotalDepth() int {\n\treturn abi.Depth + abi.QuiescenceDepth\n}" ]
[ "0.580869", "0.57079095", "0.5509451", "0.5491911", "0.5461934", "0.5445955", "0.5430927", "0.53659487", "0.52950096", "0.521777", "0.5163977", "0.51577175", "0.51344424", "0.51344424", "0.5053193", "0.5049034", "0.50392884", "0.50392884", "0.503589", "0.5014973", "0.5014234", "0.5009702", "0.4992581", "0.49847424", "0.4975651", "0.4969681", "0.49690655", "0.4961724", "0.4948086", "0.4926201", "0.49139208", "0.49128163", "0.48935738", "0.48872688", "0.48849624", "0.48675275", "0.48532528", "0.4804748", "0.47798973", "0.47795746", "0.47744527", "0.47704753", "0.47704753", "0.47566837", "0.4751041", "0.47444525", "0.47057733", "0.4701837", "0.46928135", "0.46899968", "0.46898293", "0.46782777", "0.46764672", "0.4671523", "0.4656112", "0.46531278", "0.46502584", "0.46202597", "0.4606486", "0.45960832", "0.45948073", "0.4587414", "0.45863104", "0.45863104", "0.45857462", "0.45840478", "0.45829007", "0.45758164", "0.457464", "0.4555771", "0.45507982", "0.45440367", "0.45425245", "0.45420432", "0.45375103", "0.45367292", "0.452869", "0.45261747", "0.45143837", "0.45083222", "0.45010427", "0.4498133", "0.44920292", "0.44905066", "0.4487009", "0.44732916", "0.4436621", "0.44219312", "0.44217622", "0.4421741", "0.44133756", "0.44098863", "0.43757784", "0.43717957", "0.43706048", "0.4362988", "0.43537372", "0.43463454", "0.43442774" ]
0.500669
23
enable or disable writing into the depth buffer
func DepthMask(flag bool) { C.glowDepthMask(gpDepthMask, (C.GLboolean)(boolToInt(flag))) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func (dev *Device) SetDepthBuffer(buf unsafe.Pointer) int {\n\treturn int(C.freenect_set_depth_buffer(dev.ptr(), buf))\n}", "func DepthMask(flag bool) {\n C.glowDepthMask(gpDepthMask, (C.GLboolean)(boolToInt(flag)))\n}", "func DepthMask(flag bool) {\n\tgl.DepthMask(flag)\n}", "func DepthMask(flag bool) {\n\tsyscall.Syscall(gpDepthMask, 1, boolToUintptr(flag), 0, 0)\n}", "func DepthMask(flag bool) {\n\tC.glDepthMask(glBool(flag))\n}", "func (native *OpenGL) DepthMask(mask bool) {\n\tgl.DepthMask(mask)\n}", "func DepthMask(flag Boolean) {\n\tcflag, _ := (C.GLboolean)(flag), cgoAllocsUnknown\n\tC.glDepthMask(cflag)\n}", "func (this *GView) Enable() {\n\ttext := ([]byte) (this.name + \"'s move (\" + this.directions + \"): \")\n\tif _, err := this.inOut.Write(text); err != nil {\n\t\tfmt.Fprintln(os.Stderr, \"Error Writing To Stream (\" + this.name + \")\")\n\t}\n}", "func (handler *ConsoleLogHandler) Enable() {\r\n atomic.StoreUint32(&handler.disabled, falseUint32)\r\n}", "func (dev *Device) SetDepthMode(mode FrameMode) int {\n\treturn int(C.freenect_set_depth_mode(dev.ptr(), *mode.ptr()))\n}", "func (s *stencilOverdraw) storeNewDepthValues(ctx context.Context,\n\tcb CommandBuilder,\n\tgs *api.GlobalState,\n\tst *State,\n\ta arena.Arena,\n\tdevice VkDevice,\n\tqueue VkQueue,\n\tcmdBuffer VkCommandBuffer,\n\trenderInfo renderInfo,\n\talloc func(v ...interface{}) api.AllocResult,\n\taddCleanup func(func()),\n\tout transform.Writer,\n) error {\n\tif renderInfo.depthIdx == ^uint32(0) {\n\t\treturn nil\n\t}\n\trpInfo := st.RenderPasses().Get(renderInfo.renderPass)\n\tdaInfo := rpInfo.AttachmentDescriptions().Get(renderInfo.depthIdx)\n\n\tif daInfo.StoreOp() != VkAttachmentStoreOp_VK_ATTACHMENT_STORE_OP_STORE {\n\t\treturn nil\n\t}\n\n\tfbInfo := st.Framebuffers().Get(renderInfo.framebuffer)\n\n\toldImageView := fbInfo.ImageAttachments().Get(uint32(fbInfo.ImageAttachments().Len() - 1))\n\tnewImageView := fbInfo.ImageAttachments().Get(renderInfo.depthIdx)\n\n\toldImageDesc := imageDesc{\n\t\toldImageView.Image(),\n\t\toldImageView.SubresourceRange(),\n\t\trpInfo.AttachmentDescriptions().Get(uint32(fbInfo.ImageAttachments().Len() - 1)).FinalLayout(),\n\t\tVkImageAspectFlagBits_VK_IMAGE_ASPECT_DEPTH_BIT,\n\t}\n\tnewImageDesc := imageDesc{\n\t\tnewImageView.Image(),\n\t\tnewImageView.SubresourceRange(),\n\t\tdaInfo.FinalLayout(),\n\t\tVkImageAspectFlagBits_VK_IMAGE_ASPECT_DEPTH_BIT,\n\t}\n\treturn s.transferDepthValues(ctx, cb, gs, st, a,\n\t\tdevice, queue, cmdBuffer,\n\t\tfbInfo.Width(), fbInfo.Height(),\n\t\toldImageDesc, newImageDesc,\n\t\talloc, addCleanup, out)\n}", "func (handler *ConsoleLogHandler) Disable() {\r\n atomic.StoreUint32(&handler.disabled, trueUint32)\r\n}", "func (w *Writer) EnableZlibLevel(lvl int) error {\n\tif w.err != nil {\n\t\treturn w.err\n\t} else if w.zlibOn {\n\t\treturn errZlibAlreadyActive\n\t}\n\tif err := w.Flush(); err != nil {\n\t\treturn err\n\t}\n\tw.zlibOn = true\n\tif w.zlibW == nil || w.zlibLvl != lvl {\n\t\tz, err := zlib.NewWriterLevel(w.w, lvl)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tw.zlibW = z\n\t\tw.zlibLvl = lvl\n\t} else {\n\t\tw.zlibW.Reset(w.w)\n\t}\n\tw.cur = w.zlibW\n\tw.bw.Reset(w.cur)\n\treturn nil\n}", "func (debugging *debuggingOpenGL) Disable(capability uint32) {\n\tdebugging.recordEntry(\"Disable\", capability)\n\tdebugging.gl.Disable(capability)\n\tdebugging.recordExit(\"Disable\")\n}", "func DrawBuffer(mode uint32) {\n C.glowDrawBuffer(gpDrawBuffer, (C.GLenum)(mode))\n}", "func (s *stencilOverdraw) loadExistingDepthValues(ctx context.Context,\n\tcb CommandBuilder,\n\tgs *api.GlobalState,\n\tst *State,\n\ta arena.Arena,\n\tdevice VkDevice,\n\tqueue VkQueue,\n\tcmdBuffer VkCommandBuffer,\n\trenderInfo renderInfo,\n\talloc func(v ...interface{}) api.AllocResult,\n\taddCleanup func(func()),\n\tout transform.Writer,\n) error {\n\tif renderInfo.depthIdx == ^uint32(0) {\n\t\treturn nil\n\t}\n\trpInfo := st.RenderPasses().Get(renderInfo.renderPass)\n\tdaInfo := rpInfo.AttachmentDescriptions().Get(renderInfo.depthIdx)\n\n\tif daInfo.LoadOp() != VkAttachmentLoadOp_VK_ATTACHMENT_LOAD_OP_LOAD {\n\t\treturn nil\n\t}\n\n\tfbInfo := st.Framebuffers().Get(renderInfo.framebuffer)\n\n\toldImageView := fbInfo.ImageAttachments().Get(renderInfo.depthIdx)\n\tnewImageView := fbInfo.ImageAttachments().Get(uint32(fbInfo.ImageAttachments().Len() - 1))\n\n\toldImageDesc := imageDesc{\n\t\toldImageView.Image(),\n\t\toldImageView.SubresourceRange(),\n\t\tdaInfo.InitialLayout(),\n\t\tVkImageAspectFlagBits_VK_IMAGE_ASPECT_DEPTH_BIT,\n\t}\n\tnewImageDesc := imageDesc{\n\t\tnewImageView.Image(),\n\t\tnewImageView.SubresourceRange(),\n\t\tVkImageLayout_VK_IMAGE_LAYOUT_DEPTH_STENCIL_ATTACHMENT_OPTIMAL,\n\t\tVkImageAspectFlagBits_VK_IMAGE_ASPECT_DEPTH_BIT,\n\t}\n\n\treturn s.transferDepthValues(ctx, cb, gs, st, a,\n\t\tdevice, queue, cmdBuffer,\n\t\tfbInfo.Width(), fbInfo.Height(),\n\t\toldImageDesc, newImageDesc,\n\t\talloc, addCleanup, out)\n}", "func (o *Dig) SetDepth(v int32) {\n\to.Depth = v\n}", "func (self *PhysicsP2) Enable2O(object interface{}, debug bool, children bool) {\n self.Object.Call(\"enable\", object, debug, children)\n}", "func (this *BufferedLog) Enable() {\n\tatomic.StoreInt32(&this.enabled, 1)\n}", "func (gl *WebGL) Disable(option GLEnum) {\n\tgl.context.Call(\"disable\", option)\n}", "func (native *OpenGL) Disable(capability uint32) {\n\tgl.Disable(capability)\n}", "func (this *BufferedLog) Disable() {\n\tatomic.StoreInt32(&this.enabled, 0)\n}", "func (c *Context) DepthMask(m bool) gfx.ContextStateValue {\n\treturn s.CSV{\n\t\tValue: m,\n\t\tDefaultValue: true, // TODO(slimsag): verify\n\t\tKey: csDepthMask,\n\t\tGLCall: c.glDepthMask,\n\t}\n}", "func (sb *shardBuffer) disabled() bool {\n\treturn sb.mode == bufferModeDisabled\n}", "func (bw *bufferedResponseWriter) Disable() {\n\tbw.disabled = true\n}", "func Enable() {\n\tdebug = true\n}", "func (this *channelMeterStruct) setEnabled(value bool) {\n\tthis.mutex.Lock()\n\tenabled := this.enabled\n\n\t/*\n\t * Check if status of meter must be changed.\n\t */\n\tif value != enabled {\n\n\t\t/*\n\t\t * If level meter should be disabled, clear state.\n\t\t */\n\t\tif !value {\n\t\t\tthis.currentValue = 0.0\n\t\t\tthis.peakValue = 0.0\n\t\t\tthis.sampleCounter = 0\n\t\t}\n\n\t\tthis.enabled = value\n\t}\n\n\tthis.mutex.Unlock()\n}", "func enableDisable(status, device int, name string) {\n\tvar request RpcRequest\n\n\tswitch status {\n\tcase 0:\n\t\trequest = RpcRequest{fmt.Sprintf(\"{\\\"command\\\":\\\"gpudisable\\\",\\\"parameter\\\":\\\"%v\\\"}\", device), make(chan []byte), name}\n\tcase 1:\n\t\trequest = RpcRequest{fmt.Sprintf(\"{\\\"command\\\":\\\"gpuenable\\\",\\\"parameter\\\":\\\"%v\\\"}\", device), make(chan []byte), name}\n\t}\n\n\trequest.Send()\n}", "func (s *Shadow) EnableAging() { s.setChange() }", "func Disable(cap GLenum) {\n\tC.glDisable(C.GLenum(cap))\n}", "func (buf *CommandBuffer) SetDepthBias(constantFactor, clamp, slopeFactor float32) {\n\tC.domVkCmdSetDepthBias(buf.fps[vkCmdSetDepthBias], buf.hnd, C.float(constantFactor), C.float(clamp), C.float(slopeFactor))\n}", "func setWriteFlag(tx *bolt.Tx) {\n}", "func (m *Mode) Enable() {\n\tm.enabled = true\n}", "func Enable() {\n\tenableOutput = true\n}", "func Disable() {\n\tdebug = false\n}", "func setDepth(p0 int, pool []huffmanTree, depth []byte, max_depth int) bool {\n\tvar stack [16]int\n\tvar level int = 0\n\tvar p int = p0\n\tassert(max_depth <= 15)\n\tstack[0] = -1\n\tfor {\n\t\tif pool[p].index_left_ >= 0 {\n\t\t\tlevel++\n\t\t\tif level > max_depth {\n\t\t\t\treturn false\n\t\t\t}\n\t\t\tstack[level] = int(pool[p].index_right_or_value_)\n\t\t\tp = int(pool[p].index_left_)\n\t\t\tcontinue\n\t\t} else {\n\t\t\tdepth[pool[p].index_right_or_value_] = byte(level)\n\t\t}\n\n\t\tfor level >= 0 && stack[level] == -1 {\n\t\t\tlevel--\n\t\t}\n\t\tif level < 0 {\n\t\t\treturn true\n\t\t}\n\t\tp = stack[level]\n\t\tstack[level] = -1\n\t}\n}", "func Disable(cap Enum) {\n\tgl.Disable(uint32(cap))\n}", "func (debugging *debuggingOpenGL) Enable(capability uint32) {\n\tdebugging.recordEntry(\"Enable\", capability)\n\tdebugging.gl.Enable(capability)\n\tdebugging.recordExit(\"Enable\")\n}", "func EnableDebugMode() {\n\tDefaultLogger.Init(os.Stderr, LogLevelDebug)\n}", "func (ca *Appender) Enabled(r *driver.Recorder) bool {\n\tif r.Level < ca.level {\n\t\treturn false\n\t}\n\n\tca.runOnce.Do(func() {\n\t\tca.waitExit = &sync.WaitGroup{}\n\t\tca.waitExit.Add(1)\n\t\tgo ca.run(ca.waitExit)\n\t})\n\n\t// Write after closed\n\tif ca.waitExit == nil {\n\t\tca.output(r)\n\t\treturn false\n\t}\n\n\tca.rec <- r\n\treturn false\n}", "func ClearDepth(depth float64) {\n\tsyscall.Syscall(gpClearDepth, 1, uintptr(math.Float64bits(depth)), 0, 0)\n}", "func (n *NodeDrainer) SetEnabled(enabled bool, state *state.StateStore) {\n\tn.l.Lock()\n\tdefer n.l.Unlock()\n\n\t// If we are starting now or have a new state, init state and start the\n\t// run loop\n\tn.enabled = enabled\n\tif enabled {\n\t\tn.flush(state)\n\t\tgo n.run(n.ctx)\n\t} else if !enabled && n.exitFn != nil {\n\t\tn.exitFn()\n\t}\n}", "func SetDebugMode(b bool) { env.SetDebugMode(b) }", "func (p *PWMPin) SetEnabled(e bool) error {\n\tif err := p.writeFile(fmt.Sprintf(\"pwm%s/enable\", p.fn), fmt.Sprintf(\"%v\", bool2int(e))); err != nil {\n\t\treturn err\n\t}\n\tp.enabled = e\n\treturn nil\n}", "func (filter *DotfileFilter) toggle() {\n\tfilter.enable = !filter.enable\n}", "func Disable(cap Enum) {\n\tccap, _ := (C.GLenum)(cap), cgoAllocsUnknown\n\tC.glDisable(ccap)\n}", "func Disable() {\n\tenableOutput = false\n}", "func ToggleDebugMode() {\n\tDEBUG = !DEBUG\n}", "func (pwm *pwmGroup) enable(enable bool) {\n\tpwm.CSR.ReplaceBits(boolToBit(enable)<<rp.PWM_CH0_CSR_EN_Pos, rp.PWM_CH0_CSR_EN_Msk, 0)\n}", "func (zw *ZerologWriter) DebugLogging(enabled bool) { zw.w.DebugLogging(enabled) }", "func (zw *ZerologWriter) DebugLogging(enabled bool) { zw.w.DebugLogging(enabled) }", "func WriteBool(buffer []byte, offset int, value bool) {\n if value {\n buffer[offset] = 1\n } else {\n buffer[offset] = 0\n }\n}", "func Enable(cap GLenum) {\n\tC.glEnable(C.GLenum(cap))\n}", "func (cpu *CPU) writeHalfcarryFlag(val bool) {\n if val {\n cpu.f = cpu.f ^ ( 1 << 5 )\n }\n}", "func EnableLogging(w io.Writer) {}", "func ClearDepth(depth float64) {\n C.glowClearDepth(gpClearDepth, (C.GLdouble)(depth))\n}", "func (native *OpenGL) Enable(capability uint32) {\n\tgl.Enable(capability)\n}", "func SetDebugMode(isEnabled bool) {\n\tdebugMode = isEnabled\n}", "func (rl *limiter) Debug(enable bool) {\n\trl.debug = enable\n}", "func DisableVertexAttribArray(index uint32) {\n C.glowDisableVertexAttribArray(gpDisableVertexAttribArray, (C.GLuint)(index))\n}", "func (gl *WebGL) Enable(option GLEnum) {\n\tgl.context.Call(\"enable\", option)\n}", "func (v *ViewView) enable(player_id string) {\n\tv.write(\"Player \" + player_id + \"'s Move: \")\n}", "func (h *handlerImpl) disableVertex(adjMatrix adjacencyMatrix, vertex int) {\n\tfor to := range adjMatrix[vertex] {\n\t\tadjMatrix[vertex][to].disabled = true\n\t}\n}", "func (p *GameTree) writeTree(w *bufio.Writer, n TreeNodeIdx, needs bool, nMov int, nMovPerLine int) (err error) {\n\tdefer u(tr(\"writeTree\"))\n\tif needs == true {\n\t\tif nMov > 0 {\n\t\t\terr = w.WriteByte('\\n')\n\t\t\tnMov = 0\n\t\t}\n\t\terr = w.WriteByte('(')\n\t}\n\tif err == nil {\n\t\tif nMov == nMovPerLine {\n\t\t\terr = w.WriteByte('\\n')\n\t\t\tnMov = 0\n\t\t}\n\t\terr = w.WriteByte(';')\n\t\t// write the node\n\t\ttyp := p.treeNodes[n].TNodType\n\t\tswitch typ {\n\t\tcase GameInfoNode:\n\t\t\t// fmt.Println(\"writing GameInfoNode\\n\")\n\t\t\terr = p.writeProperties(w, n, true)\n\t\tcase InteriorNode:\n\t\t\t// fmt.Println(\"writing InteriorNode\\n\")\n\t\t\terr = p.writeProperties(w, n, false)\n\t\tcase BlackMoveNode:\n\t\t\t_, err = w.WriteString(\"B[\")\n\t\t\t_, err = w.Write(SGFCoords(ah.NodeLoc(p.treeNodes[n].propListOrNodeLoc), p.IsFF4()))\n\t\t\terr = w.WriteByte(']')\n\t\t\tnMov += 1\n\t\tcase WhiteMoveNode:\n\t\t\t_, err = w.WriteString(\"W[\")\n\t\t\t_, err = w.Write(SGFCoords(ah.NodeLoc(p.treeNodes[n].propListOrNodeLoc), p.IsFF4()))\n\t\t\terr = w.WriteByte(']')\n\t\t\tnMov += 1\n\t\tdefault:\n\t\t\tfmt.Println(\"*** unsupported TreeNodeType in writeTree\")\n\t\t\terr = errors.New(\"writeTree: unsupported TreeNodeType\" + strconv.FormatInt(int64(typ), 10))\n\t\t\treturn err\n\t\t}\n\t\tif err == nil {\n\t\t\t// write the children\n\t\t\tlastCh := p.treeNodes[n].Children\n\t\t\tif lastCh != nilTreeNodeIdx && err == nil {\n\t\t\t\tch := p.treeNodes[lastCh].NextSib\n\t\t\t\tchNeeds := (lastCh != ch)\n\t\t\t\terr = p.writeTree(w, ch, chNeeds, nMov, nMovPerLine)\n\t\t\t\tfor ch != lastCh && err == nil {\n\t\t\t\t\tch = p.treeNodes[ch].NextSib\n\t\t\t\t\t//\t\t\t\t\tnMov += 1\n\t\t\t\t\terr = p.writeTree(w, ch, chNeeds, nMov, nMovPerLine)\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (err == nil) && (needs == true) {\n\t\t\t\terr = w.WriteByte(')')\n\t\t\t}\n\t\t}\n\t}\n\treturn err\n}", "func (c *DeviceAccess) Enable(ctx context.Context) (*gcdmessage.ChromeResponse, error) {\n\treturn c.target.SendDefaultRequest(ctx, &gcdmessage.ParamRequest{Id: c.target.GetId(), Method: \"DeviceAccess.enable\"})\n}", "func (e ChainEntry) Write() {\n\tif e.disabled {\n\t\treturn\n\t}\n\t// first find writer for level\n\t// if none, stop\n\te.Entry.l.closeEntry(e.Entry)\n\te.Entry.l.finalizeIfContext(e.Entry)\n\te.Entry.enc.Release()\n\n\tif e.exit {\n\t\te.Entry.l.exit(1)\n\t}\n}", "func SetDepthFunc(_func Enum) {\n\tc_func, _ := (C.GLenum)(_func), cgoAllocsUnknown\n\tC.glDepthFunc(c_func)\n}", "func Flush() {\n C.glowFlush(gpFlush)\n}", "func (c SpanContext) isWriteable() bool {\n\tstate := c.samplingState\n\treturn !state.isFinal() || state.isSampled()\n}", "func SetCallDepth(callDepth int) {\n\tstd.mu.Lock()\n\tdefer std.mu.Unlock()\n\tstd.callDepth = callDepth\n}", "func (self *PhysicsP2) Enable1O(object interface{}, debug bool) {\n self.Object.Call(\"enable\", object, debug)\n}", "func (e *Env) SetDebugMode(b bool) { e.debugMode = b }", "func (c *ChromeIndexedDB) Enable() (*ChromeResponse, error) {\n return sendDefaultRequest(c.target.sendCh, &ParamRequest{Id: c.target.getId(), Method: \"IndexedDB.enable\"})\n}", "func Enable(cap Enum) {\n\tgl.Enable(uint32(cap))\n}", "func Enabled() bool {\n\treturn writeKey != \"\"\n}", "func (dm *DagModifier) Sync() error {\n\t// No buffer? Nothing to do\n\tif dm.wrBuf == nil {\n\t\treturn nil\n\t}\n\n\t// If we have an active reader, kill it\n\tif dm.read != nil {\n\t\tdm.read = nil\n\t\tdm.readCancel()\n\t}\n\n\t// Number of bytes we're going to write\n\tbuflen := dm.wrBuf.Len()\n\n\tfs, err := FileSize(dm.curNode)\n\tif err != nil {\n\t\treturn err\n\t}\n\tif fs < dm.writeStart {\n\t\tif err := dm.expandSparse(int64(dm.writeStart - fs)); err != nil {\n\t\t\treturn err\n\t\t}\n\t}\n\n\t// overwrite existing dag nodes\n\tthisc, err := dm.modifyDag(dm.curNode, dm.writeStart)\n\tif err != nil {\n\t\treturn err\n\t}\n\n\tdm.curNode, err = dm.dagserv.Get(dm.ctx, thisc)\n\tif err != nil {\n\t\treturn err\n\t}\n\n\t// need to write past end of current dag\n\tif dm.wrBuf.Len() > 0 {\n\t\tdm.curNode, err = dm.appendData(dm.curNode, dm.splitter(dm.wrBuf))\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\n\t\terr = dm.dagserv.Add(dm.ctx, dm.curNode)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t}\n\n\tdm.writeStart += uint64(buflen)\n\tdm.wrBuf = nil\n\n\treturn nil\n}", "func SetTraceMode(b bool) { env.SetTraceMode(b) }", "func (w *xcWallet) setDisabled(status bool) {\n\tw.mtx.Lock()\n\tw.disabled = status\n\tw.mtx.Unlock()\n}", "func (player *Player) EnableDebug() {\n\tplayer.debug = true\n}", "func (c *Contextor) Disable() {\n\tatomic.StoreInt32(&c.enabled, 0)\n}", "func (s *Component) WriteDigital(v bool) {\n\tif v {\n\t\ts.device.On()\n\t} else {\n\t\ts.device.Off()\n\t}\n}", "func (l *XORMLogBridge) SetLevel(lvl core.LogLevel) {\n}", "func (svc *batchService) UpdateDepth(id []byte, depth uint8, normalisedBalance *big.Int) error {\n\tb, err := svc.storer.Get(id)\n\tif err != nil {\n\t\treturn fmt.Errorf(\"get: %w\", err)\n\t}\n\terr = svc.storer.Put(b, normalisedBalance, depth)\n\tif err != nil {\n\t\treturn fmt.Errorf(\"put: %w\", err)\n\t}\n\n\tsvc.logger.Debugf(\"batch service: updated depth of batch id %s from %d to %d\", hex.EncodeToString(b.ID), b.Depth, depth)\n\treturn nil\n}", "func (g *Gate) Disable() {\n\tatomic.StoreInt64(&g.DisabledFlag, 1)\n}", "func (o FolderSinkOutput) Disabled() pulumi.BoolPtrOutput {\n\treturn o.ApplyT(func(v *FolderSink) pulumi.BoolPtrOutput { return v.Disabled }).(pulumi.BoolPtrOutput)\n}", "func (o *opHistory) Enable() {\n\to.enable = true\n}", "func EnableTracing(enabled bool) {\n\ttrace = enabled\n}", "func SetDebugMode(f bool) {\n\tdebugMode = f\n}", "func EnableVertexAttribArray(index uint32) {\n C.glowEnableVertexAttribArray(gpEnableVertexAttribArray, (C.GLuint)(index))\n}", "func DisableVertexAttribArray(index uint32) {\n\tsyscall.Syscall(gpDisableVertexAttribArray, 1, uintptr(index), 0, 0)\n}", "func (s *Shadow) DisableAging() { s.changed = _DISABLE_AGING }", "func EnableGLog(enabled bool) {\r\n\tgloged = &enabled\r\n}", "func (win *window) Draw(mode bool) {\n\tif win.isExpose {\n\t\treturn\n\t}\n\tif mode {\n\t\txwin.ChangeGC(win.gc, xgb.GCForeground, []uint32{win.fore})\n\t}\n}", "func Disable() {\n\tEnable = false\n}", "func (d *Device) startWrite() {\n\tif d.csPin != machine.NoPin {\n\t\td.csPin.Low()\n\t}\n}", "func BufferPoolEnable(enable bool) {\n\tenableBufferPool = enable\n}", "func (this *meterStruct) SetEnabled(value bool) {\n\tthis.mutex.Lock()\n\tenabled := this.enabled\n\n\t/*\n\t * Check if value must be changed.\n\t */\n\tif value != enabled {\n\t\tchannelMeters := this.channelMeters\n\n\t\t/*\n\t\t * Enable or disable each channel meter.\n\t\t */\n\t\tfor _, channelMeter := range channelMeters {\n\t\t\tchannelMeter.setEnabled(value)\n\t\t}\n\n\t\tthis.enabled = value\n\t}\n\n\tthis.mutex.Unlock()\n}", "func enable_debug() {\n\tnfo.SetOutput(nfo.DEBUG, os.Stdout)\n\tnfo.SetFile(nfo.DEBUG, nfo.GetFile(nfo.ERROR))\n}", "func EdgeFlag(flag bool) {\n C.glowEdgeFlag(gpEdgeFlag, (C.GLboolean)(boolToInt(flag)))\n}" ]
[ "0.61243355", "0.58740526", "0.57638055", "0.57237315", "0.56763303", "0.5612447", "0.5556722", "0.5423485", "0.54152673", "0.5297169", "0.5296362", "0.52924144", "0.52748996", "0.5264191", "0.5188081", "0.50942665", "0.5085185", "0.50234556", "0.50067735", "0.5001658", "0.4994586", "0.49889055", "0.49797362", "0.49420413", "0.4890838", "0.488967", "0.48861745", "0.4882393", "0.48800424", "0.48568466", "0.48520026", "0.48374715", "0.48263502", "0.48026663", "0.48004946", "0.47715276", "0.4766403", "0.47659314", "0.47622135", "0.47526658", "0.47376353", "0.46829185", "0.46780765", "0.46743706", "0.46735", "0.4671223", "0.4668815", "0.4655792", "0.46440855", "0.46354425", "0.46354425", "0.46306816", "0.46304473", "0.4616842", "0.46108097", "0.4607679", "0.45988795", "0.45818993", "0.45782405", "0.4569741", "0.45657137", "0.45632523", "0.45627147", "0.4562379", "0.45610982", "0.45602512", "0.4554286", "0.4550932", "0.45354402", "0.45344305", "0.4529759", "0.4511764", "0.45087522", "0.45056233", "0.4496193", "0.4491504", "0.44842556", "0.44752038", "0.4474939", "0.4473896", "0.4462551", "0.4461846", "0.44527653", "0.4451795", "0.44484434", "0.44442424", "0.44409406", "0.4438591", "0.4428232", "0.44225726", "0.44224843", "0.44180018", "0.4416167", "0.44160637", "0.4411579", "0.44079953", "0.4401483", "0.43996906", "0.43976697" ]
0.5456156
8
specify mapping of depth values from normalized device coordinates to window coordinates
func DepthRange(n float64, f float64) { C.glowDepthRange(gpDepthRange, (C.GLdouble)(n), (C.GLdouble)(f)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func DepthRange(near float64, far float64) {\n C.glowDepthRange(gpDepthRange, (C.GLdouble)(near), (C.GLdouble)(far))\n}", "func DepthRange(n float64, f float64) {\n\tsyscall.Syscall(gpDepthRange, 2, uintptr(math.Float64bits(n)), uintptr(math.Float64bits(f)), 0)\n}", "func DepthRangeIndexed(index uint32, n float64, f float64) {\n C.glowDepthRangeIndexed(gpDepthRangeIndexed, (C.GLuint)(index), (C.GLdouble)(n), (C.GLdouble)(f))\n}", "func DepthRangef(n float32, f float32) {\n\tsyscall.Syscall(gpDepthRangef, 2, uintptr(math.Float32bits(n)), uintptr(math.Float32bits(f)), 0)\n}", "func DepthRangef(n Float, f Float) {\n\tcn, _ := (C.GLfloat)(n), cgoAllocsUnknown\n\tcf, _ := (C.GLfloat)(f), cgoAllocsUnknown\n\tC.glDepthRangef(cn, cf)\n}", "func (dev *Device) StartDepth() int {\n\treturn int(C.freenect_start_depth(dev.ptr()))\n}", "func DepthRangeIndexed(index uint32, n float64, f float64) {\n\tsyscall.Syscall(gpDepthRangeIndexed, 3, uintptr(index), uintptr(math.Float64bits(n)), uintptr(math.Float64bits(f)))\n}", "func DepthRangef(n float32, f float32) {\n\tC.glowDepthRangef(gpDepthRangef, (C.GLfloat)(n), (C.GLfloat)(f))\n}", "func DepthRangef(n float32, f float32) {\n\tC.glowDepthRangef(gpDepthRangef, (C.GLfloat)(n), (C.GLfloat)(f))\n}", "func DepthFunc(xfunc uint32) {\n\tsyscall.Syscall(gpDepthFunc, 1, uintptr(xfunc), 0, 0)\n}", "func DepthRangef(n, f float32) {\n\tgl.DepthRangef(n, f)\n}", "func DepthFunc(xfunc uint32) {\n C.glowDepthFunc(gpDepthFunc, (C.GLenum)(xfunc))\n}", "func DepthRangeIndexed(index uint32, n float64, f float64) {\n\tC.glowDepthRangeIndexed(gpDepthRangeIndexed, (C.GLuint)(index), (C.GLdouble)(n), (C.GLdouble)(f))\n}", "func DepthRangeIndexed(index uint32, n float64, f float64) {\n\tC.glowDepthRangeIndexed(gpDepthRangeIndexed, (C.GLuint)(index), (C.GLdouble)(n), (C.GLdouble)(f))\n}", "func DepthFunc(fn Enum) {\n\tgl.DepthFunc(uint32(fn))\n}", "func (dev *Device) SetDepthBuffer(buf unsafe.Pointer) int {\n\treturn int(C.freenect_set_depth_buffer(dev.ptr(), buf))\n}", "func DepthMask(flag bool) {\n\tsyscall.Syscall(gpDepthMask, 1, boolToUintptr(flag), 0, 0)\n}", "func world2screen(wx, wy float32) (sx, sy int) {\n\tsx = int((wx * pixel_per_meter) + (float32(WINDOW_X) / 2.0))\n\tsy = int((-wy * pixel_per_meter) + (float32(WINDOW_Y) / 2.0))\n\treturn\n}", "func GetRenderbufferDepthSize(target GLEnum) int32 {\n\tvar params int32\n\tgl.GetRenderbufferParameteriv(uint32(target), gl.RENDERBUFFER_DEPTH_SIZE, &params)\n\treturn params\n}", "func DepthMask(flag Boolean) {\n\tcflag, _ := (C.GLboolean)(flag), cgoAllocsUnknown\n\tC.glDepthMask(cflag)\n}", "func DepthFunc(func_ GLenum) {\n\tC.glDepthFunc(C.GLenum(func_))\n}", "func (s *stencilOverdraw) loadExistingDepthValues(ctx context.Context,\n\tcb CommandBuilder,\n\tgs *api.GlobalState,\n\tst *State,\n\ta arena.Arena,\n\tdevice VkDevice,\n\tqueue VkQueue,\n\tcmdBuffer VkCommandBuffer,\n\trenderInfo renderInfo,\n\talloc func(v ...interface{}) api.AllocResult,\n\taddCleanup func(func()),\n\tout transform.Writer,\n) error {\n\tif renderInfo.depthIdx == ^uint32(0) {\n\t\treturn nil\n\t}\n\trpInfo := st.RenderPasses().Get(renderInfo.renderPass)\n\tdaInfo := rpInfo.AttachmentDescriptions().Get(renderInfo.depthIdx)\n\n\tif daInfo.LoadOp() != VkAttachmentLoadOp_VK_ATTACHMENT_LOAD_OP_LOAD {\n\t\treturn nil\n\t}\n\n\tfbInfo := st.Framebuffers().Get(renderInfo.framebuffer)\n\n\toldImageView := fbInfo.ImageAttachments().Get(renderInfo.depthIdx)\n\tnewImageView := fbInfo.ImageAttachments().Get(uint32(fbInfo.ImageAttachments().Len() - 1))\n\n\toldImageDesc := imageDesc{\n\t\toldImageView.Image(),\n\t\toldImageView.SubresourceRange(),\n\t\tdaInfo.InitialLayout(),\n\t\tVkImageAspectFlagBits_VK_IMAGE_ASPECT_DEPTH_BIT,\n\t}\n\tnewImageDesc := imageDesc{\n\t\tnewImageView.Image(),\n\t\tnewImageView.SubresourceRange(),\n\t\tVkImageLayout_VK_IMAGE_LAYOUT_DEPTH_STENCIL_ATTACHMENT_OPTIMAL,\n\t\tVkImageAspectFlagBits_VK_IMAGE_ASPECT_DEPTH_BIT,\n\t}\n\n\treturn s.transferDepthValues(ctx, cb, gs, st, a,\n\t\tdevice, queue, cmdBuffer,\n\t\tfbInfo.Width(), fbInfo.Height(),\n\t\toldImageDesc, newImageDesc,\n\t\talloc, addCleanup, out)\n}", "func DepthMask(flag bool) {\n\tgl.DepthMask(flag)\n}", "func DepthMask(flag bool) {\n\tC.glDepthMask(glBool(flag))\n}", "func GetDepthModeCount() int {\n\treturn int(C.freenect_get_depth_mode_count())\n}", "func (s *stencilOverdraw) storeNewDepthValues(ctx context.Context,\n\tcb CommandBuilder,\n\tgs *api.GlobalState,\n\tst *State,\n\ta arena.Arena,\n\tdevice VkDevice,\n\tqueue VkQueue,\n\tcmdBuffer VkCommandBuffer,\n\trenderInfo renderInfo,\n\talloc func(v ...interface{}) api.AllocResult,\n\taddCleanup func(func()),\n\tout transform.Writer,\n) error {\n\tif renderInfo.depthIdx == ^uint32(0) {\n\t\treturn nil\n\t}\n\trpInfo := st.RenderPasses().Get(renderInfo.renderPass)\n\tdaInfo := rpInfo.AttachmentDescriptions().Get(renderInfo.depthIdx)\n\n\tif daInfo.StoreOp() != VkAttachmentStoreOp_VK_ATTACHMENT_STORE_OP_STORE {\n\t\treturn nil\n\t}\n\n\tfbInfo := st.Framebuffers().Get(renderInfo.framebuffer)\n\n\toldImageView := fbInfo.ImageAttachments().Get(uint32(fbInfo.ImageAttachments().Len() - 1))\n\tnewImageView := fbInfo.ImageAttachments().Get(renderInfo.depthIdx)\n\n\toldImageDesc := imageDesc{\n\t\toldImageView.Image(),\n\t\toldImageView.SubresourceRange(),\n\t\trpInfo.AttachmentDescriptions().Get(uint32(fbInfo.ImageAttachments().Len() - 1)).FinalLayout(),\n\t\tVkImageAspectFlagBits_VK_IMAGE_ASPECT_DEPTH_BIT,\n\t}\n\tnewImageDesc := imageDesc{\n\t\tnewImageView.Image(),\n\t\tnewImageView.SubresourceRange(),\n\t\tdaInfo.FinalLayout(),\n\t\tVkImageAspectFlagBits_VK_IMAGE_ASPECT_DEPTH_BIT,\n\t}\n\treturn s.transferDepthValues(ctx, cb, gs, st, a,\n\t\tdevice, queue, cmdBuffer,\n\t\tfbInfo.Width(), fbInfo.Height(),\n\t\toldImageDesc, newImageDesc,\n\t\talloc, addCleanup, out)\n}", "func DepthMask(flag bool) {\n C.glowDepthMask(gpDepthMask, (C.GLboolean)(boolToInt(flag)))\n}", "func DepthFunc(xfunc uint32) {\n\tC.glowDepthFunc(gpDepthFunc, (C.GLenum)(xfunc))\n}", "func DepthFunc(xfunc uint32) {\n\tC.glowDepthFunc(gpDepthFunc, (C.GLenum)(xfunc))\n}", "func (native *OpenGL) DepthMask(mask bool) {\n\tgl.DepthMask(mask)\n}", "func ScreenXY(value Vec2) *SimpleElement { return newSEVec2(\"screenXY\", value) }", "func SetDepthFunc(_func Enum) {\n\tc_func, _ := (C.GLenum)(_func), cgoAllocsUnknown\n\tC.glDepthFunc(c_func)\n}", "func (native *OpenGL) DepthFunc(xfunc uint32) {\n\tgl.DepthFunc(xfunc)\n}", "func (dev *Device) SetDepthMode(mode FrameMode) int {\n\treturn int(C.freenect_set_depth_mode(dev.ptr(), *mode.ptr()))\n}", "func GenDepthTexture(width, height int32) gl.Texture2D {\n\ttex := gl.GenTexture2D()\n\ttex.Bind()\n\ttex.MinFilter(gl.NEAREST)\n\ttex.MagFilter(gl.NEAREST)\n\ttex.WrapS(gl.CLAMP_TO_EDGE)\n\ttex.WrapT(gl.CLAMP_TO_EDGE)\n\ttex.TexImage2D(0, gl.DEPTH_COMPONENT, width, height, 0, gl.DEPTH_COMPONENT, gl.FLOAT, nil)\n\ttex.Unbind()\n\treturn tex\n}", "func (mParams *EncodingMatrixLiteral) Depth(actual bool) (depth int) {\n\tif actual {\n\t\tdepth = len(mParams.ScalingFactor)\n\t} else {\n\t\tfor i := range mParams.ScalingFactor {\n\t\t\tfor range mParams.ScalingFactor[i] {\n\t\t\t\tdepth++\n\t\t\t}\n\t\t}\n\t}\n\treturn\n}", "func Frustum(left float64, right float64, bottom float64, top float64, zNear float64, zFar float64) {\n C.glowFrustum(gpFrustum, (C.GLdouble)(left), (C.GLdouble)(right), (C.GLdouble)(bottom), (C.GLdouble)(top), (C.GLdouble)(zNear), (C.GLdouble)(zFar))\n}", "func (dev *Device) StopDepth() int {\n\treturn int(C.freenect_stop_depth(dev.ptr()))\n}", "func DepthMask(flag bool) {\n\tC.glowDepthMask(gpDepthMask, (C.GLboolean)(boolToInt(flag)))\n}", "func DepthMask(flag bool) {\n\tC.glowDepthMask(gpDepthMask, (C.GLboolean)(boolToInt(flag)))\n}", "func (device *Device) StartDepthStream(resolution Resolution, format DepthFormat) error {\n\n\terrCode := C.freenect_set_depth_mode(device.device,\n\t\tC.freenect_find_depth_mode(C.freenect_resolution(resolution), C.freenect_depth_format(format)))\n\n\tif errCode != 0 {\n\t\treturn errors.New(\"could not find depth mode\")\n\t}\n\n\terrCode = C.freenect_start_depth(device.device)\n\n\tif errCode != 0 {\n\t\treturn errors.New(\"could not start depth stream\")\n\t}\n\n\treturn nil\n}", "func (w Widths) MaxDepth() (maxDepth, deepWidth int) {\n\tfor depth, width := range w {\n\t\tif depth > maxDepth {\n\t\t\tmaxDepth = depth\n\t\t\tdeepWidth = width\n\t\t}\n\t}\n\treturn\n}", "func DepthToSpace(scope *Scope, input tf.Output, block_size int64, optional ...DepthToSpaceAttr) (output tf.Output) {\n\tif scope.Err() != nil {\n\t\treturn\n\t}\n\tattrs := map[string]interface{}{\"block_size\": block_size}\n\tfor _, a := range optional {\n\t\ta(attrs)\n\t}\n\topspec := tf.OpSpec{\n\t\tType: \"DepthToSpace\",\n\t\tInput: []tf.Input{\n\t\t\tinput,\n\t\t},\n\t\tAttrs: attrs,\n\t}\n\top := scope.AddOperation(opspec)\n\treturn op.Output(0)\n}", "func FindDepthMode(res Resolution, format DepthFormat) FrameMode {\n\tfm := C.freenect_find_depth_mode(C.freenect_resolution(res), C.freenect_depth_format(format))\n\treturn *(*FrameMode)(unsafe.Pointer(&fm))\n}", "func (bm Blendmap) View() (float32, float32, float32, float32) {\n\treturn bm.Map.viewport.Min.X, bm.Map.viewport.Min.Y, bm.Map.viewport.Max.X, bm.Map.viewport.Max.Y\n}", "func d11rectVolume(rect *d11rectT) float64 {\n\tvar volume float64 = 1\n\tfor index := 0; index < d11numDims; index++ {\n\t\tvolume *= rect.max[index] - rect.min[index]\n\t}\n\treturn volume\n}", "func MakeDepth(width, height int) Texture {\n\ttex := Make(width, height, gl.DEPTH_COMPONENT, gl.DEPTH_COMPONENT,\n\t\tgl.UNSIGNED_BYTE, nil, gl.LINEAR, gl.LINEAR, gl.CLAMP_TO_BORDER,\n\t\tgl.CLAMP_TO_BORDER)\n\treturn tex\n}", "func (c *Camera) debugUpdate() {\n\tc.State = gfx.NewState()\n\tc.Shader = shader\n\tc.State.FaceCulling = gfx.BackFaceCulling\n\n\tm := gfx.NewMesh()\n\tm.Primitive = gfx.Lines\n\n\tm.Vertices = []gfx.Vec3{}\n\tm.Colors = []gfx.Color{}\n\n\tnear := float32(c.Near)\n\tfar := float32(c.Far)\n\n\tif c.Ortho {\n\t\twidth := float32(c.View.Dx())\n\t\theight := float32(c.View.Dy())\n\n\t\tm.Vertices = []gfx.Vec3{\n\t\t\t{width / 2, 0, height / 2},\n\n\t\t\t// Near\n\t\t\t{0, near, 0},\n\t\t\t{width, near, 0},\n\t\t\t{width, near, height},\n\t\t\t{0, near, height},\n\n\t\t\t// Far\n\t\t\t{0, far, 0},\n\t\t\t{width, far, 0},\n\t\t\t{width, far, height},\n\t\t\t{0, far, height},\n\n\t\t\t{width / 2, far, height / 2},\n\n\t\t\t// Up\n\t\t\t{0, near, height},\n\t\t\t{0, near, height},\n\t\t\t{width, near, height},\n\t\t}\n\t} else {\n\t\tratio := float32(c.View.Dx()) / float32(c.View.Dy())\n\t\tfovRad := c.FOV / 180 * math.Pi\n\n\t\thNear := float32(2 * math.Tan(fovRad/2) * c.Near)\n\t\twNear := hNear * ratio\n\n\t\thFar := float32(2 * math.Tan(fovRad/2) * c.Far)\n\t\twFar := hFar * ratio\n\n\t\tm.Vertices = []gfx.Vec3{\n\t\t\t{0, 0, 0},\n\n\t\t\t// Near\n\t\t\t{-wNear / 2, near, -hNear / 2},\n\t\t\t{wNear / 2, near, -hNear / 2},\n\t\t\t{wNear / 2, near, hNear / 2},\n\t\t\t{-wNear / 2, near, hNear / 2},\n\n\t\t\t// Far\n\t\t\t{-wFar / 2, far, -hFar / 2},\n\t\t\t{wFar / 2, far, -hFar / 2},\n\t\t\t{wFar / 2, far, hFar / 2},\n\t\t\t{-wFar / 2, far, hFar / 2},\n\n\t\t\t{0, far, 0},\n\n\t\t\t// Up\n\t\t\t{0, near, hNear},\n\t\t\t{-wNear / 2 * 0.7, near, hNear / 2 * 1.1},\n\t\t\t{wNear / 2 * 0.7, near, hNear / 2 * 1.1},\n\t\t}\n\t}\n\n\tm.Colors = []gfx.Color{\n\t\t{1, 1, 1, 1},\n\t\t{1, 0.67, 0, 1},\n\t\t{1, 0.67, 0, 1},\n\t\t{1, 0.67, 0, 1},\n\t\t{1, 0.67, 0, 1},\n\n\t\t{1, 0.67, 0, 1},\n\t\t{1, 0.67, 0, 1},\n\t\t{1, 0.67, 0, 1},\n\t\t{1, 0.67, 0, 1},\n\t\t{1, 1, 1, 1},\n\n\t\t{0, 0.67, 1, 1},\n\t\t{0, 0.67, 1, 1},\n\t\t{0, 0.67, 1, 1},\n\t}\n\n\tm.Indices = []uint32{\n\t\t// From 0 to near plane\n\t\t0, 1,\n\t\t0, 2,\n\t\t0, 3,\n\t\t0, 4,\n\n\t\t// Near plane\n\t\t1, 2,\n\t\t2, 3,\n\t\t3, 4,\n\t\t4, 1,\n\n\t\t// Far plane\n\t\t5, 6,\n\t\t6, 7,\n\t\t7, 8,\n\t\t8, 5,\n\n\t\t// Lines from near to far plane\n\t\t1, 5,\n\t\t2, 6,\n\t\t3, 7,\n\t\t4, 8,\n\n\t\t0, 9,\n\n\t\t// Up\n\t\t10, 11,\n\t\t11, 12,\n\t\t12, 10,\n\t}\n\n\tc.Meshes = []*gfx.Mesh{m}\n}", "func getLightmapDimensions(faceVertices []q2file.Vertex, texInfo q2file.TexInfo) LightmapDimensions {\n\tstartUV := getTextureUV(faceVertices[0], texInfo)\n\n\t// Find the Min and Max UV's for a face\n\tstartUV0 := float64(startUV[0])\n\tstartUV1 := float64(startUV[1])\n\tminU := math.Floor(startUV0)\n\tminV := math.Floor(startUV1)\n\tmaxU := math.Floor(startUV0)\n\tmaxV := math.Floor(startUV1)\n\n\tfor i := 1; i < len(faceVertices); i++ {\n\t\tuv := getTextureUV(faceVertices[i], texInfo)\n\t\tuv0 := float64(uv[0])\n\t\tuv1 := float64(uv[1])\n\n\t\tif math.Floor(uv0) < minU {\n\t\t\tminU = math.Floor(uv0)\n\t\t}\n\t\tif math.Floor(uv1) < minV {\n\t\t\tminV = math.Floor(uv1)\n\t\t}\n\t\tif math.Floor(uv0) > maxU {\n\t\t\tmaxU = math.Floor(uv0)\n\t\t}\n\t\tif math.Floor(uv1) > maxV {\n\t\t\tmaxV = math.Floor(uv1)\n\t\t}\n\t}\n\n\t// Calculate the lightmap dimensions\n\treturn LightmapDimensions{\n\t\tWidth: int32(math.Ceil(maxU/16) - math.Floor(minU/16) + 1),\n\t\tHeight: int32(math.Ceil(maxV/16) - math.Floor(minV/16) + 1),\n\t\tMinU: float32(math.Floor(minU)),\n\t\tMinV: float32(math.Floor(minV)),\n\t}\n}", "func (s *ImageSpec) Depth() int {\n\tret := int(C.ImageSpec_depth(s.ptr))\n\truntime.KeepAlive(s)\n\treturn ret\n}", "func Frustum(left float64, right float64, bottom float64, top float64, zNear float64, zFar float64) {\n\tsyscall.Syscall6(gpFrustum, 6, uintptr(math.Float64bits(left)), uintptr(math.Float64bits(right)), uintptr(math.Float64bits(bottom)), uintptr(math.Float64bits(top)), uintptr(math.Float64bits(zNear)), uintptr(math.Float64bits(zFar)))\n}", "func Uniform2fv(location int32, count int32, value *float32) {\n C.glowUniform2fv(gpUniform2fv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func (gl *WebGL) DepthFunc(function GLEnum) {\n\tgl.context.Call(\"depthFunc\", function)\n}", "func MainDepth() int {\n\treturn int(C.g_main_depth())\n}", "func SpaceToDepth(scope *Scope, input tf.Output, block_size int64, optional ...SpaceToDepthAttr) (output tf.Output) {\n\tif scope.Err() != nil {\n\t\treturn\n\t}\n\tattrs := map[string]interface{}{\"block_size\": block_size}\n\tfor _, a := range optional {\n\t\ta(attrs)\n\t}\n\topspec := tf.OpSpec{\n\t\tType: \"SpaceToDepth\",\n\t\tInput: []tf.Input{\n\t\t\tinput,\n\t\t},\n\t\tAttrs: attrs,\n\t}\n\top := scope.AddOperation(opspec)\n\treturn op.Output(0)\n}", "func (c *imageBinaryChannel) dev2nRect(x1, y1, x2, y2 int) float64 {\n\treturn c.integralImage.dev2nRect(x1, y1, x2, y2)\n}", "func debugPrintWinSize() {\n\twindow := getWinSize()\n\tfmt.Printf(\"col: %v\\nrow: %v\\nx: %v\\ny: %v\\n\", window.col, window.row, window.unusedX, window.unusedY)\n}", "func coreRatioViewport(fbWidth int, fbHeight int) (x, y, w, h float32) {\n\t// Scale the content to fit in the viewport.\n\tfbw := float32(fbWidth)\n\tfbh := float32(fbHeight)\n\n\t// NXEngine workaround\n\taspectRatio := float32(Geom.AspectRatio)\n\tif aspectRatio == 0 {\n\t\taspectRatio = float32(Geom.BaseWidth) / float32(Geom.BaseHeight)\n\t}\n\n\th = fbh\n\tw = fbh * aspectRatio\n\tif w > fbw {\n\t\th = fbw / aspectRatio\n\t\tw = fbw\n\t}\n\n\t// Place the content in the middle of the window.\n\tx = (fbw - w) / 2\n\ty = (fbh - h) / 2\n\n\tva := vertexArray(x, y, w, h, 1.0)\n\tgl.BindBuffer(gl.ARRAY_BUFFER, vbo)\n\tgl.BufferData(gl.ARRAY_BUFFER, len(va)*4, gl.Ptr(va), gl.STATIC_DRAW)\n\n\treturn\n}", "func ClearDepthf(d float32) {\n\tsyscall.Syscall(gpClearDepthf, 1, uintptr(math.Float32bits(d)), 0, 0)\n}", "func VEventfDepth(ctx context.Context, depth int, level int32, format string, args ...interface{}) {\n\tvEventf(ctx, false /* isErr */, 1+depth, level, format, args...)\n}", "func (p *Projection) project(wx float64, wy float64) (float64, float64) {\n return ((wx / p.worldWidth) * p.canvasWidth) + (p.canvasWidth * 0.5),\n ((wy / p.worldHeight) * -p.canvasHeight) + (p.canvasHeight * 0.5)\n}", "func createCfgs() []pixelgl.WindowConfig {\n\tret := []pixelgl.WindowConfig{}\n\tfor _, m := range pixelgl.Monitors() {\n\t\tmX, mY := m.Size()\n\t\tret = append(ret, pixelgl.WindowConfig{\n\t\t\tBounds: pixel.R(0, 0, mX, mY),\n\t\t\tVSync: true,\n\t\t\tMonitor: m,\n\t\t})\n\t}\n\n\treturn ret\n}", "func (l Layout) DebugRender(win *pixelgl.Window) {\n\tfor key := range l.Panels {\n\t\tpanel := l.CreatePanel(key)\n\t\tpanel.Draw(win)\n\t}\n\n\t//temp camera matrix\n\t//cam := pixel.IM.Scaled(l.centerPos, 1.0).Moved(l.centerPos)\n\t//win.SetMatrix(cam)\n}", "func (c *Context) DepthMask(m bool) gfx.ContextStateValue {\n\treturn s.CSV{\n\t\tValue: m,\n\t\tDefaultValue: true, // TODO(slimsag): verify\n\t\tKey: csDepthMask,\n\t\tGLCall: c.glDepthMask,\n\t}\n}", "func (sm *StackedMap) Depth() int {\n\treturn len(sm.mapStack)\n}", "func (ac *Activity) SurfaceBounds(ctx context.Context) (Rect, error) {\n\tcmd := ac.a.Command(ctx, \"dumpsys\", \"window\", \"windows\")\n\toutput, err := cmd.Output()\n\tif err != nil {\n\t\treturn Rect{}, errors.Wrap(err, \"failed to launch dumpsys\")\n\t}\n\n\t// Looking for:\n\t// Window #0 Window{a486f07 u0 com.android.settings/com.android.settings.Settings}:\n\t// mDisplayId=0 stackId=2 mSession=Session{dd34b88 2586:1000} mClient=android.os.BinderProxy@705e146\n\t// mHasSurface=true isReadyForDisplay()=true mWindowRemovalAllowed=false\n\t// [...many other properties...]\n\t// mFrame=[0,0][1536,1936] last=[0,0][1536,1936]\n\t// We are interested in \"mFrame=\"\n\tregStr := `(?m)` + // Enable multiline.\n\t\t`^\\s*Window #\\d+ Window{\\S+ \\S+ ` + regexp.QuoteMeta(ac.pkgName+\"/\"+ac.pkgName+ac.activityName) + `}:$` + // Match our activity\n\t\t`(?:\\n.*?)*` + // Skip entire lines with a non-greedy search...\n\t\t`^\\s*mFrame=\\[(\\d+),(\\d+)\\]\\[(\\d+),(\\d+)\\]` // ...until we match the first mFrame=\n\tre := regexp.MustCompile(regStr)\n\tgroups := re.FindStringSubmatch(string(output))\n\tif len(groups) != 5 {\n\t\ttesting.ContextLog(ctx, string(output))\n\t\treturn Rect{}, errors.New(\"failed to parse dumpsys output; activity not running perhaps?\")\n\t}\n\tbounds, err := parseBounds(groups[1:5])\n\tif err != nil {\n\t\treturn Rect{}, err\n\t}\n\treturn bounds, nil\n}", "func (c *Camera) prepareWorldSpaceUnits() {\n\t// Compute the width of half of the canvas by taking the tangent of half of the field of view.\n\t// Cutting the field of view in half creates a right triangle on the canvas, which is 1 unit\n\t// away from the camera. The adjacent is 1 and the opposite is half of the canvas.\n\thalfView := math.Tan(c.fieldOfView / 2)\n\n\t// Compute the aspect ratio\n\tc.aspectRatio = float64(c.horizontalSizeInPixels) / float64(c.verticalSizeInPixels)\n\n\t// Compute half of the width and half of the height of the canvas.\n\t// This is different than the number of horizontal or vertical pixels.\n\tif c.aspectRatio >= 1 {\n\t\t// The horizontal size is greater than or equal to the vertical size\n\t\tc.halfWidth = halfView\n\t\tc.halfHeight = halfView / c.aspectRatio\n\t} else {\n\t\t// The vertical size is greater than the horizontal size\n\t\tc.halfWidth = halfView * c.aspectRatio\n\t\tc.halfHeight = halfView\n\t}\n\n\t// Divide half of the width * 2 by the number of horizontal pixels to get\n\t// the pixel size. Note that the assumption here is that the pixels are\n\t// square, so there is no need to compute the vertical size of the pixel.\n\tc.pixelSize = (c.halfWidth * 2) / float64(c.horizontalSizeInPixels)\n}", "func DepthToSpaceDataFormat(value string) DepthToSpaceAttr {\n\treturn func(m optionalAttr) {\n\t\tm[\"data_format\"] = value\n\t}\n}", "func GetDepthMode(mode_num int) FrameMode {\n\tfm := C.freenect_get_depth_mode(C.int(mode_num))\n\treturn *(*FrameMode)(unsafe.Pointer(&fm))\n}", "func trickleDepthInfo(node *h.FSNodeOverDag, maxlinks int) (depth int, repeatNumber int) {\n\tn := node.NumChildren()\n\n\tif n < maxlinks {\n\t\t// We didn't even added the initial `maxlinks` leaf nodes (`FillNodeLayer`).\n\t\treturn 0, 0\n\t}\n\n\tnonLeafChildren := n - maxlinks\n\t// The number of non-leaf child nodes added in `fillTrickleRec` (after\n\t// the `FillNodeLayer` call).\n\n\tdepth = nonLeafChildren/depthRepeat + 1\n\t// \"Deduplicate\" the added `depthRepeat` sub-graphs at each depth\n\t// (rounding it up since we may be on an unfinished depth with less\n\t// than `depthRepeat` sub-graphs).\n\n\trepeatNumber = nonLeafChildren % depthRepeat\n\t// What's left after taking full depths of `depthRepeat` sub-graphs\n\t// is the current `repeatNumber` we're at (this fractional part is\n\t// what we rounded up before).\n\n\treturn\n}", "func ClearDepth(depth float64) {\n\tsyscall.Syscall(gpClearDepth, 1, uintptr(math.Float64bits(depth)), 0, 0)\n}", "func SpaceToDepthDataFormat(value string) SpaceToDepthAttr {\n\treturn func(m optionalAttr) {\n\t\tm[\"data_format\"] = value\n\t}\n}", "func (c *Camera) Viewport() (x float32, y float32, width float32, height float32) {\n\tif c.x > 0 {\n\t\tx = float32(c.x) / float32(c.windowWidth)\n\t}\n\tif c.y > 0 {\n\t\ty = float32(c.y) / float32(c.worldHeight)\n\t}\n\n\tratio := math32.Min(\n\t\tfloat32(c.windowWidth)/float32(c.worldWidth),\n\t\tfloat32(c.windowHeight)/float32(c.worldHeight),\n\t)\n\twidth, height = c.relativeToWindowSize(ratio, ratio)\n\twidth /= float32(c.width) / float32(c.worldWidth)\n\theight /= float32(c.height) / float32(c.worldHeight)\n\treturn x, y, width, height\n}", "func Depth(index uint) (depth uint) {\n\tindex++\n\tfor (index & 1) == 0 {\n\t\tdepth++\n\t\tindex = rightShift(index)\n\t}\n\treturn\n}", "func PolygonOffset(factor float32, units float32) {\n C.glowPolygonOffset(gpPolygonOffset, (C.GLfloat)(factor), (C.GLfloat)(units))\n}", "func Depth(e expr.Expr) uint {\n\t//fmt.Printf(\"%f\\n\",e)\n\t// TODO: implement this function\n\tswitch i:= e.(type){\n\tcase expr.Var:\n\n\tcase expr.Literal:\n\n\tcase expr.Unary:\n\t\treturn Depth(i.X) + 1\n\t\tbreak\n\tcase expr.Binary: \n\t\treturn Max(Depth(i.X),Depth(i.Y)) + 1\n\t\tbreak\n\tdefault: \n\t\tpanic(\"unrecognized character\")\n\t}\n\treturn 1\n}", "func Uniform4fv(location int32, count int32, value *float32) {\n C.glowUniform4fv(gpUniform4fv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func MaxLodPixel(value int) *SimpleElement { return newSEInt(\"maxLodPixels\", value) }", "func createLevelMap(root *TreeNode, level int, levelMapper map[int][]int) {\n\tif root == nil {\n\t\treturn\n\t}\n\tif _, ok := levelMapper[level]; !ok {\n\t\tlevelMapper[level] = make([]int, 0)\n\t}\n\tlevelMapper[level] = append(levelMapper[level], root.Val)\n\tcreateLevelMap(root.Left, level+1, levelMapper)\n\tcreateLevelMap(root.Right, level+1, levelMapper)\n}", "func (c *Context) Viewport(x, y, width, height int) gfx.ContextStateValue {\n\treturn s.CSV{\n\t\tValue: [4]int{x, y, width, height},\n\t\tDefaultValue: [4]int{0, 0, 0, 0}, // TODO(slimsag): track real default viewport values\n\t\tKey: csViewport,\n\t\tGLCall: c.glViewport,\n\t}\n}", "func InfolnDepth(depth int, args ...interface{}) {\n\tlogging.printlnDepth(severity.InfoLog, logging.logger, logging.filter, depth, args...)\n}", "func d16rectVolume(rect *d16rectT) float64 {\n\tvar volume float64 = 1\n\tfor index := 0; index < d16numDims; index++ {\n\t\tvolume *= rect.max[index] - rect.min[index]\n\t}\n\treturn volume\n}", "func d2rectVolume(rect *d2rectT) float64 {\n\tvar volume float64 = 1\n\tfor index := 0; index < d2numDims; index++ {\n\t\tvolume *= rect.max[index] - rect.min[index]\n\t}\n\treturn volume\n}", "func normal2imageCoordinate(x, y int) (int, int) {\n\tx = x + maxX/3\n\ty = y + maxY/2\n\treturn x, y\n}", "func InfofDepth(depth int, format string, args ...interface{}) {\n\tlogging.printfDepth(severity.InfoLog, logging.logger, logging.filter, depth, format, args...)\n}", "func LRNDepthRadius(value int64) LRNAttr {\n\treturn func(m optionalAttr) {\n\t\tm[\"depth_radius\"] = value\n\t}\n}", "func (o *Grid) boundaries() {\n\tn0 := o.npts[0]\n\tn1 := o.npts[1]\n\tif o.ndim == 2 {\n\t\to.edge = make([][]int, 4) // xmin,xmax,ymin,ymax\n\t\to.edge[0] = make([]int, n1) // xmin\n\t\to.edge[1] = make([]int, n1) // xmax\n\t\to.edge[2] = make([]int, n0) // ymin\n\t\to.edge[3] = make([]int, n0) // ymax\n\t\tfor n := 0; n < n1; n++ {\n\t\t\to.edge[0][n] = n * n0 // xmin\n\t\t\to.edge[1][n] = n*n0 + n0 - 1 // xmax\n\t\t}\n\t\tfor m := 0; m < n0; m++ {\n\t\t\to.edge[2][m] = m // ymin\n\t\t\to.edge[3][m] = m + n0*(n1-1) // ymax\n\t\t}\n\t\treturn\n\t}\n\tn2 := o.npts[2]\n\to.face = make([][]int, 6) // xmin,xmax,ymin,ymax,zmin,zmax\n\to.face[0] = make([]int, n1*n2) // xmin\n\to.face[1] = make([]int, n1*n2) // xmax\n\to.face[2] = make([]int, n0*n2) // ymin\n\to.face[3] = make([]int, n0*n2) // ymax\n\to.face[4] = make([]int, n0*n1) // zmin\n\to.face[5] = make([]int, n0*n1) // zmax\n\tt := 0\n\tfor p := 0; p < n2; p++ { // loop over z\n\t\tfor n := 0; n < n1; n++ { // loop over y\n\t\t\to.face[0][t] = n*n0 + (n0*n1)*p // xmin\n\t\t\to.face[1][t] = n*n0 + (n0*n1)*p + (n0 - 1) // xmax\n\t\t\tt++\n\t\t}\n\t}\n\tt = 0\n\tfor p := 0; p < n2; p++ { // loop over z\n\t\tfor m := 0; m < n0; m++ { // loop over x\n\t\t\to.face[2][t] = m + (n0*n1)*p // ymin\n\t\t\to.face[3][t] = m + (n0*n1)*p + n0*(n1-1) // ymax\n\t\t\tt++\n\t\t}\n\t}\n\tt = 0\n\tfor n := 0; n < n1; n++ { // loop over y\n\t\tfor m := 0; m < n0; m++ { // loop over x\n\t\t\to.face[4][t] = m + n0*n // zmin\n\t\t\to.face[5][t] = m + n0*n + (n0*n1)*(n2-1) // zmax\n\t\t\tt++\n\t\t}\n\t}\n}", "func (s *ImageSpec) FullDepth() int {\n\tret := int(C.ImageSpec_full_depth(s.ptr))\n\truntime.KeepAlive(s)\n\treturn ret\n}", "func (device *Device) SetDepthCallback(callback DepthCallback) {\n\n\tif _, ok := devices[device.device]; !ok {\n\t\tdevices[device.device] = device\n\t}\n\n\tC.freenect_set_depth_callback(device.device, (*[0]byte)(C.depthCallback))\n\tdevice.depthCallback = callback\n}", "func EdgePosition(stage Stage) float32 {\n\tif stage == BATTLEFIELD {\n\t\treturn 71.3078536987\n\t}\n\tif stage == FINAL_DESTINATION {\n\t\treturn 88.4735488892\n\t}\n\tif stage == DREAMLAND {\n\t\treturn 80.1791534424\n\t}\n\tif stage == FOUNTAIN_OF_DREAMS {\n\t\treturn 66.2554016113\n\t}\n\tif stage == POKEMON_STADIUM {\n\t\treturn 90.657852\n\t}\n\tif stage == YOSHIS_STORY {\n\t\treturn 58.907848\n\t}\n\n\treturn 1000\n}", "func ProgramUniform2fv(program uint32, location int32, count int32, value *float32) {\n C.glowProgramUniform2fv(gpProgramUniform2fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func (s *CountMinSketch) Depth() uint {\n\treturn s.d\n}", "func Frustum(left float64, right float64, bottom float64, top float64, zNear float64, zFar float64) {\n\tC.glowFrustum(gpFrustum, (C.GLdouble)(left), (C.GLdouble)(right), (C.GLdouble)(bottom), (C.GLdouble)(top), (C.GLdouble)(zNear), (C.GLdouble)(zFar))\n}", "func setDepthAndEntryCount(ds *dataset.Dataset, data qfs.File, mu *sync.Mutex, done chan error) {\n\tdefer data.Close()\n\n\ter, err := dsio.NewEntryReader(ds.Structure, data)\n\tif err != nil {\n\t\tlog.Debug(err.Error())\n\t\tdone <- fmt.Errorf(\"error reading data values: %s\", err.Error())\n\t\treturn\n\t}\n\n\tentries := 0\n\t// baseline of 1 for the original closure\n\tdepth := 1\n\tvar ent dsio.Entry\n\tfor {\n\t\tif ent, err = er.ReadEntry(); err != nil {\n\t\t\tlog.Debug(err.Error())\n\t\t\tbreak\n\t\t}\n\t\t// get the depth of this entry, update depth if larger\n\t\tif d := getDepth(ent.Value, 1); d > depth {\n\t\t\tdepth = d\n\t\t}\n\t\tentries++\n\t}\n\tif err.Error() != \"EOF\" {\n\t\tdone <- fmt.Errorf(\"error reading values at entry %d: %s\", entries, err.Error())\n\t\treturn\n\t}\n\n\tmu.Lock()\n\tds.Structure.Entries = entries\n\tds.Structure.Depth = depth\n\tmu.Unlock()\n\n\tdone <- nil\n}", "func Uniform2fv(location int32, count int32, value *float32) {\n\tsyscall.Syscall(gpUniform2fv, 3, uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)))\n}", "func (buf *CommandBuffer) SetDepthBias(constantFactor, clamp, slopeFactor float32) {\n\tC.domVkCmdSetDepthBias(buf.fps[vkCmdSetDepthBias], buf.hnd, C.float(constantFactor), C.float(clamp), C.float(slopeFactor))\n}", "func DrawArraysIndirect(mode uint32, indirect unsafe.Pointer) {\n C.glowDrawArraysIndirect(gpDrawArraysIndirect, (C.GLenum)(mode), indirect)\n}", "func TestBoard_CalculateDepth(t *testing.T) {\n\ttype fields struct {\n\t\tGrid [3][3]int\n\t}\n\ttests := []struct {\n\t\tname string\n\t\tfields fields\n\t\twant int\n\t}{\n\t\t{name: \"Test-Empty-grid\", fields: fields{Grid: [3][3]int{\n\t\t\t{1, -1, -1}, {0, 1, -1}, {-1, 0, 1},\n\t\t}}, want: 4},\n\t}\n\tfor _, tt := range tests {\n\t\tt.Run(tt.name, func(t *testing.T) {\n\t\t\tboard := &Board{\n\t\t\t\tGrid: tt.fields.Grid,\n\t\t\t}\n\t\t\tif got := board.CalculateDepth(); got != tt.want {\n\t\t\t\tt.Errorf(\"CalculateDepth() = %v, want %v\", got, tt.want)\n\t\t\t}\n\t\t})\n\t}\n}", "func getLogDepth(ctx context.Context) int {\n\tif ctx == nil {\n\t\treturn 3\n\t}\n\tdepth := ctx.Value(\"log-depth\")\n\tif depth != nil {\n\t\tif ds, ok := depth.(int); ok {\n\t\t\treturn ds\n\t\t}\n\t}\n\treturn 3\n}" ]
[ "0.6349661", "0.61290014", "0.60408145", "0.5821985", "0.5722763", "0.562346", "0.5457924", "0.54241323", "0.54241323", "0.5372862", "0.5355993", "0.53275514", "0.53072464", "0.53072464", "0.5297694", "0.5277749", "0.5203261", "0.51883626", "0.51862097", "0.5184831", "0.51844174", "0.51337093", "0.5130064", "0.5116545", "0.5079078", "0.50636405", "0.50420314", "0.50367683", "0.50367683", "0.4991644", "0.49568206", "0.49056104", "0.49047646", "0.48970896", "0.48415616", "0.4807125", "0.4781219", "0.4727937", "0.47231746", "0.47231746", "0.47176132", "0.4688242", "0.46579275", "0.4628763", "0.46271637", "0.46088523", "0.4603389", "0.45622566", "0.45590076", "0.4556958", "0.4555898", "0.45516482", "0.4540139", "0.45348603", "0.45297328", "0.45292047", "0.45067874", "0.4477497", "0.44612375", "0.4458045", "0.44559398", "0.44493756", "0.44239217", "0.4423399", "0.44219807", "0.44104254", "0.438961", "0.43652594", "0.43633533", "0.43528852", "0.4346118", "0.43426943", "0.43371713", "0.4331173", "0.43216833", "0.43130395", "0.4307367", "0.43023166", "0.4293253", "0.42853963", "0.42813003", "0.42797917", "0.4264953", "0.4258063", "0.4251588", "0.42429328", "0.4241513", "0.42397743", "0.42351294", "0.4232453", "0.42311946", "0.42287365", "0.42279935", "0.42222223", "0.42167246", "0.42154834", "0.4199635", "0.4196996", "0.41934335" ]
0.56836975
6
specify mapping of depth values from normalized device coordinates to window coordinates for a specified viewport
func DepthRangeIndexed(index uint32, n float64, f float64) { C.glowDepthRangeIndexed(gpDepthRangeIndexed, (C.GLuint)(index), (C.GLdouble)(n), (C.GLdouble)(f)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func (c *Context) Viewport(x, y, width, height int) gfx.ContextStateValue {\n\treturn s.CSV{\n\t\tValue: [4]int{x, y, width, height},\n\t\tDefaultValue: [4]int{0, 0, 0, 0}, // TODO(slimsag): track real default viewport values\n\t\tKey: csViewport,\n\t\tGLCall: c.glViewport,\n\t}\n}", "func Viewport(x, y, width, height int) {\n\tgl.Viewport(int32(x), int32(y), int32(width), int32(height))\n}", "func Viewport(x int, y int, width int, height int) {\n\tC.glViewport(C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))\n}", "func (c *Camera) Viewport() (x float32, y float32, width float32, height float32) {\n\tif c.x > 0 {\n\t\tx = float32(c.x) / float32(c.windowWidth)\n\t}\n\tif c.y > 0 {\n\t\ty = float32(c.y) / float32(c.worldHeight)\n\t}\n\n\tratio := math32.Min(\n\t\tfloat32(c.windowWidth)/float32(c.worldWidth),\n\t\tfloat32(c.windowHeight)/float32(c.worldHeight),\n\t)\n\twidth, height = c.relativeToWindowSize(ratio, ratio)\n\twidth /= float32(c.width) / float32(c.worldWidth)\n\theight /= float32(c.height) / float32(c.worldHeight)\n\treturn x, y, width, height\n}", "func DepthRange(near float64, far float64) {\n C.glowDepthRange(gpDepthRange, (C.GLdouble)(near), (C.GLdouble)(far))\n}", "func (native *OpenGL) Viewport(x int32, y int32, width int32, height int32) {\n\tgl.Viewport(x, y, width, height)\n}", "func (debugging *debuggingOpenGL) Viewport(x int32, y int32, width int32, height int32) {\n\tdebugging.recordEntry(\"Viewport\", x, y, width, height)\n\tdebugging.gl.Viewport(x, y, width, height)\n\tdebugging.recordExit(\"Viewport\")\n}", "func DepthRangeIndexed(index uint32, n float64, f float64) {\n C.glowDepthRangeIndexed(gpDepthRangeIndexed, (C.GLuint)(index), (C.GLdouble)(n), (C.GLdouble)(f))\n}", "func (gl *WebGL) Viewport(x, y, width, height int) {\n\tgl.context.Call(\"viewport\", x, y, width, height)\n}", "func coreRatioViewport(fbWidth int, fbHeight int) (x, y, w, h float32) {\n\t// Scale the content to fit in the viewport.\n\tfbw := float32(fbWidth)\n\tfbh := float32(fbHeight)\n\n\t// NXEngine workaround\n\taspectRatio := float32(Geom.AspectRatio)\n\tif aspectRatio == 0 {\n\t\taspectRatio = float32(Geom.BaseWidth) / float32(Geom.BaseHeight)\n\t}\n\n\th = fbh\n\tw = fbh * aspectRatio\n\tif w > fbw {\n\t\th = fbw / aspectRatio\n\t\tw = fbw\n\t}\n\n\t// Place the content in the middle of the window.\n\tx = (fbw - w) / 2\n\ty = (fbh - h) / 2\n\n\tva := vertexArray(x, y, w, h, 1.0)\n\tgl.BindBuffer(gl.ARRAY_BUFFER, vbo)\n\tgl.BufferData(gl.ARRAY_BUFFER, len(va)*4, gl.Ptr(va), gl.STATIC_DRAW)\n\n\treturn\n}", "func DepthRange(n float64, f float64) {\n\tsyscall.Syscall(gpDepthRange, 2, uintptr(math.Float64bits(n)), uintptr(math.Float64bits(f)), 0)\n}", "func (bm Blendmap) View() (float32, float32, float32, float32) {\n\treturn bm.Map.viewport.Min.X, bm.Map.viewport.Min.Y, bm.Map.viewport.Max.X, bm.Map.viewport.Max.Y\n}", "func DepthRangef(n Float, f Float) {\n\tcn, _ := (C.GLfloat)(n), cgoAllocsUnknown\n\tcf, _ := (C.GLfloat)(f), cgoAllocsUnknown\n\tC.glDepthRangef(cn, cf)\n}", "func DepthRange(n float64, f float64) {\n\tC.glowDepthRange(gpDepthRange, (C.GLdouble)(n), (C.GLdouble)(f))\n}", "func DepthRange(n float64, f float64) {\n\tC.glowDepthRange(gpDepthRange, (C.GLdouble)(n), (C.GLdouble)(f))\n}", "func (v *Viewport) Apply() {\n\tgl.Viewport(v.x, v.y, v.width, v.height)\n}", "func (obj *material) Viewport() viewports.Viewport {\n\treturn obj.viewport\n}", "func DepthRangef(n float32, f float32) {\n\tsyscall.Syscall(gpDepthRangef, 2, uintptr(math.Float32bits(n)), uintptr(math.Float32bits(f)), 0)\n}", "func world2screen(wx, wy float32) (sx, sy int) {\n\tsx = int((wx * pixel_per_meter) + (float32(WINDOW_X) / 2.0))\n\tsy = int((-wy * pixel_per_meter) + (float32(WINDOW_Y) / 2.0))\n\treturn\n}", "func canvasToViewPort(x, y float64, c Canvas) Vector {\n\tfw, fh := float64(c.Width()), float64(c.Height())\n\treturn Vector{(x - fw/2) / fw, (y - fh/2) / fh, 1}\n}", "func DepthRangeIndexed(index uint32, n float64, f float64) {\n\tsyscall.Syscall(gpDepthRangeIndexed, 3, uintptr(index), uintptr(math.Float64bits(n)), uintptr(math.Float64bits(f)))\n}", "func (dev *Device) SetDepthBuffer(buf unsafe.Pointer) int {\n\treturn int(C.freenect_set_depth_buffer(dev.ptr(), buf))\n}", "func DepthRangef(n, f float32) {\n\tgl.DepthRangef(n, f)\n}", "func SetViewport(x Int, y Int, width Sizei, height Sizei) {\n\tcx, _ := (C.GLint)(x), cgoAllocsUnknown\n\tcy, _ := (C.GLint)(y), cgoAllocsUnknown\n\tcwidth, _ := (C.GLsizei)(width), cgoAllocsUnknown\n\tcheight, _ := (C.GLsizei)(height), cgoAllocsUnknown\n\tC.glViewport(cx, cy, cwidth, cheight)\n}", "func Frustum(left float64, right float64, bottom float64, top float64, zNear float64, zFar float64) {\n\tsyscall.Syscall6(gpFrustum, 6, uintptr(math.Float64bits(left)), uintptr(math.Float64bits(right)), uintptr(math.Float64bits(bottom)), uintptr(math.Float64bits(top)), uintptr(math.Float64bits(zNear)), uintptr(math.Float64bits(zFar)))\n}", "func Frustum(left float64, right float64, bottom float64, top float64, zNear float64, zFar float64) {\n C.glowFrustum(gpFrustum, (C.GLdouble)(left), (C.GLdouble)(right), (C.GLdouble)(bottom), (C.GLdouble)(top), (C.GLdouble)(zNear), (C.GLdouble)(zFar))\n}", "func (dev *Device) StartDepth() int {\n\treturn int(C.freenect_start_depth(dev.ptr()))\n}", "func Bounds(x, y, w, h int) {\n\tgl.Viewport(int32(x), int32(y), int32(w), int32(h))\n\tgl.Scissor(int32(x), int32(y), int32(w), int32(h))\n}", "func ScreenXY(value Vec2) *SimpleElement { return newSEVec2(\"screenXY\", value) }", "func DepthRangef(n float32, f float32) {\n\tC.glowDepthRangef(gpDepthRangef, (C.GLfloat)(n), (C.GLfloat)(f))\n}", "func DepthRangef(n float32, f float32) {\n\tC.glowDepthRangef(gpDepthRangef, (C.GLfloat)(n), (C.GLfloat)(f))\n}", "func (cam *Camera) SetupViewProjection() {\n\tx_ratio := cam.Width / cam.Height\n\tcam.View = PerspectiveFrustum(cam.YFov, x_ratio, cam.Near, cam.Far)\n\tcam.Projection = cam.View.M44()\n}", "func (m *TransposableMatrix) ViewportRestriction(vPRMx1, vPRMy1, vPRMx2, vPRMy2 int) {\n\n\tvPRBx1, vPRBy1 := m.transposeMapped2Base(vPRMx1, vPRMy1)\n\tvPRBx2, vPRBy2 := m.transposeMapped2Base(vPRMx2, vPRMy2)\n\n\tm.vPRx1 = vPRBx1\n\tm.vPRy1 = vPRBy1\n\tm.vPRx2 = vPRBx2\n\tm.vPRy2 = vPRBy2\n\n\tm.enforceVPR = true\n}", "func GetRenderbufferDepthSize(target GLEnum) int32 {\n\tvar params int32\n\tgl.GetRenderbufferParameteriv(uint32(target), gl.RENDERBUFFER_DEPTH_SIZE, &params)\n\treturn params\n}", "func (p *Projection) project(wx float64, wy float64) (float64, float64) {\n return ((wx / p.worldWidth) * p.canvasWidth) + (p.canvasWidth * 0.5),\n ((wy / p.worldHeight) * -p.canvasHeight) + (p.canvasHeight * 0.5)\n}", "func DepthFunc(func_ GLenum) {\n\tC.glDepthFunc(C.GLenum(func_))\n}", "func DepthFunc(xfunc uint32) {\n\tsyscall.Syscall(gpDepthFunc, 1, uintptr(xfunc), 0, 0)\n}", "func (l Layout) DebugRender(win *pixelgl.Window) {\n\tfor key := range l.Panels {\n\t\tpanel := l.CreatePanel(key)\n\t\tpanel.Draw(win)\n\t}\n\n\t//temp camera matrix\n\t//cam := pixel.IM.Scaled(l.centerPos, 1.0).Moved(l.centerPos)\n\t//win.SetMatrix(cam)\n}", "func DepthFunc(fn Enum) {\n\tgl.DepthFunc(uint32(fn))\n}", "func (native *OpenGL) DepthFunc(xfunc uint32) {\n\tgl.DepthFunc(xfunc)\n}", "func (native *OpenGL) DepthMask(mask bool) {\n\tgl.DepthMask(mask)\n}", "func DepthMask(flag bool) {\n\tgl.DepthMask(flag)\n}", "func Frustum(left float64, right float64, bottom float64, top float64, zNear float64, zFar float64) {\n\tC.glowFrustum(gpFrustum, (C.GLdouble)(left), (C.GLdouble)(right), (C.GLdouble)(bottom), (C.GLdouble)(top), (C.GLdouble)(zNear), (C.GLdouble)(zFar))\n}", "func (obj *Device) GetViewport() (v VIEWPORT, err Error) {\n\tret, _, _ := syscall.Syscall(\n\t\tobj.vtbl.GetViewport,\n\t\t2,\n\t\tuintptr(unsafe.Pointer(obj)),\n\t\tuintptr(unsafe.Pointer(&v)),\n\t\t0,\n\t)\n\terr = toErr(ret)\n\treturn\n}", "func DepthMask(flag bool) {\n\tC.glDepthMask(glBool(flag))\n}", "func reshape(window *glfw.Window, width, height int) {\n\tgl.Viewport(0, 0, int32(width), int32(height));\n\taspect_ratio = (float32(width) / 640.0 * 4.0) / (float32(height) / 480.0 * 3.0);\n}", "func (obj *Device) SetViewport(v VIEWPORT) Error {\n\tret, _, _ := syscall.Syscall(\n\t\tobj.vtbl.SetViewport,\n\t\t2,\n\t\tuintptr(unsafe.Pointer(obj)),\n\t\tuintptr(unsafe.Pointer(&v)),\n\t\t0,\n\t)\n\treturn toErr(ret)\n}", "func (c *Camera) debugUpdate() {\n\tc.State = gfx.NewState()\n\tc.Shader = shader\n\tc.State.FaceCulling = gfx.BackFaceCulling\n\n\tm := gfx.NewMesh()\n\tm.Primitive = gfx.Lines\n\n\tm.Vertices = []gfx.Vec3{}\n\tm.Colors = []gfx.Color{}\n\n\tnear := float32(c.Near)\n\tfar := float32(c.Far)\n\n\tif c.Ortho {\n\t\twidth := float32(c.View.Dx())\n\t\theight := float32(c.View.Dy())\n\n\t\tm.Vertices = []gfx.Vec3{\n\t\t\t{width / 2, 0, height / 2},\n\n\t\t\t// Near\n\t\t\t{0, near, 0},\n\t\t\t{width, near, 0},\n\t\t\t{width, near, height},\n\t\t\t{0, near, height},\n\n\t\t\t// Far\n\t\t\t{0, far, 0},\n\t\t\t{width, far, 0},\n\t\t\t{width, far, height},\n\t\t\t{0, far, height},\n\n\t\t\t{width / 2, far, height / 2},\n\n\t\t\t// Up\n\t\t\t{0, near, height},\n\t\t\t{0, near, height},\n\t\t\t{width, near, height},\n\t\t}\n\t} else {\n\t\tratio := float32(c.View.Dx()) / float32(c.View.Dy())\n\t\tfovRad := c.FOV / 180 * math.Pi\n\n\t\thNear := float32(2 * math.Tan(fovRad/2) * c.Near)\n\t\twNear := hNear * ratio\n\n\t\thFar := float32(2 * math.Tan(fovRad/2) * c.Far)\n\t\twFar := hFar * ratio\n\n\t\tm.Vertices = []gfx.Vec3{\n\t\t\t{0, 0, 0},\n\n\t\t\t// Near\n\t\t\t{-wNear / 2, near, -hNear / 2},\n\t\t\t{wNear / 2, near, -hNear / 2},\n\t\t\t{wNear / 2, near, hNear / 2},\n\t\t\t{-wNear / 2, near, hNear / 2},\n\n\t\t\t// Far\n\t\t\t{-wFar / 2, far, -hFar / 2},\n\t\t\t{wFar / 2, far, -hFar / 2},\n\t\t\t{wFar / 2, far, hFar / 2},\n\t\t\t{-wFar / 2, far, hFar / 2},\n\n\t\t\t{0, far, 0},\n\n\t\t\t// Up\n\t\t\t{0, near, hNear},\n\t\t\t{-wNear / 2 * 0.7, near, hNear / 2 * 1.1},\n\t\t\t{wNear / 2 * 0.7, near, hNear / 2 * 1.1},\n\t\t}\n\t}\n\n\tm.Colors = []gfx.Color{\n\t\t{1, 1, 1, 1},\n\t\t{1, 0.67, 0, 1},\n\t\t{1, 0.67, 0, 1},\n\t\t{1, 0.67, 0, 1},\n\t\t{1, 0.67, 0, 1},\n\n\t\t{1, 0.67, 0, 1},\n\t\t{1, 0.67, 0, 1},\n\t\t{1, 0.67, 0, 1},\n\t\t{1, 0.67, 0, 1},\n\t\t{1, 1, 1, 1},\n\n\t\t{0, 0.67, 1, 1},\n\t\t{0, 0.67, 1, 1},\n\t\t{0, 0.67, 1, 1},\n\t}\n\n\tm.Indices = []uint32{\n\t\t// From 0 to near plane\n\t\t0, 1,\n\t\t0, 2,\n\t\t0, 3,\n\t\t0, 4,\n\n\t\t// Near plane\n\t\t1, 2,\n\t\t2, 3,\n\t\t3, 4,\n\t\t4, 1,\n\n\t\t// Far plane\n\t\t5, 6,\n\t\t6, 7,\n\t\t7, 8,\n\t\t8, 5,\n\n\t\t// Lines from near to far plane\n\t\t1, 5,\n\t\t2, 6,\n\t\t3, 7,\n\t\t4, 8,\n\n\t\t0, 9,\n\n\t\t// Up\n\t\t10, 11,\n\t\t11, 12,\n\t\t12, 10,\n\t}\n\n\tc.Meshes = []*gfx.Mesh{m}\n}", "func DepthMask(flag Boolean) {\n\tcflag, _ := (C.GLboolean)(flag), cgoAllocsUnknown\n\tC.glDepthMask(cflag)\n}", "func (c *Camera) prepareWorldSpaceUnits() {\n\t// Compute the width of half of the canvas by taking the tangent of half of the field of view.\n\t// Cutting the field of view in half creates a right triangle on the canvas, which is 1 unit\n\t// away from the camera. The adjacent is 1 and the opposite is half of the canvas.\n\thalfView := math.Tan(c.fieldOfView / 2)\n\n\t// Compute the aspect ratio\n\tc.aspectRatio = float64(c.horizontalSizeInPixels) / float64(c.verticalSizeInPixels)\n\n\t// Compute half of the width and half of the height of the canvas.\n\t// This is different than the number of horizontal or vertical pixels.\n\tif c.aspectRatio >= 1 {\n\t\t// The horizontal size is greater than or equal to the vertical size\n\t\tc.halfWidth = halfView\n\t\tc.halfHeight = halfView / c.aspectRatio\n\t} else {\n\t\t// The vertical size is greater than the horizontal size\n\t\tc.halfWidth = halfView * c.aspectRatio\n\t\tc.halfHeight = halfView\n\t}\n\n\t// Divide half of the width * 2 by the number of horizontal pixels to get\n\t// the pixel size. Note that the assumption here is that the pixels are\n\t// square, so there is no need to compute the vertical size of the pixel.\n\tc.pixelSize = (c.halfWidth * 2) / float64(c.horizontalSizeInPixels)\n}", "func DepthMask(flag bool) {\n\tsyscall.Syscall(gpDepthMask, 1, boolToUintptr(flag), 0, 0)\n}", "func GetDepthModeCount() int {\n\treturn int(C.freenect_get_depth_mode_count())\n}", "func SetDepthFunc(_func Enum) {\n\tc_func, _ := (C.GLenum)(_func), cgoAllocsUnknown\n\tC.glDepthFunc(c_func)\n}", "func frameBufferSizeCallback(w *glfw.Window, width int, height int) {\n\t// make sure the viewport matches the new window dimensions; note that width and\n\t// height will be significantly larger than specified on retina displays.\n\tgl.Viewport(0, 0, int32(width), int32(height))\n\t// log.Printf(\"frameBufferSizeCallback (%d, %d)\", width, height)\n}", "func (dev *Device) SetDepthMode(mode FrameMode) int {\n\treturn int(C.freenect_set_depth_mode(dev.ptr(), *mode.ptr()))\n}", "func ParseViewport(d *drawing.Drawing, data [][2]string) (table.SymbolTable, error) {\n\tv := table.NewViewport(\"\")\n\tvar err error\n\tfor _, dt := range data {\n\t\tswitch dt[0] {\n\t\tcase \"2\":\n\t\t\tv.SetName(dt[1])\n\t\tcase \"10\":\n\t\t\terr = setFloat(dt, func(val float64) { v.LowerLeft[0] = val })\n\t\tcase \"20\":\n\t\t\terr = setFloat(dt, func(val float64) { v.LowerLeft[1] = val })\n\t\tcase \"11\":\n\t\t\terr = setFloat(dt, func(val float64) { v.UpperRight[0] = val })\n\t\tcase \"21\":\n\t\t\terr = setFloat(dt, func(val float64) { v.UpperRight[1] = val })\n\t\tcase \"12\":\n\t\t\terr = setFloat(dt, func(val float64) { v.ViewCenter[0] = val })\n\t\tcase \"22\":\n\t\t\terr = setFloat(dt, func(val float64) { v.ViewCenter[1] = val })\n\t\tcase \"13\":\n\t\t\terr = setFloat(dt, func(val float64) { v.SnapBase[0] = val })\n\t\tcase \"23\":\n\t\t\terr = setFloat(dt, func(val float64) { v.SnapBase[1] = val })\n\t\tcase \"14\":\n\t\t\terr = setFloat(dt, func(val float64) {\n\t\t\t\tv.SnapSpacing[0] = val\n\t\t\t\tv.SnapSpacing[1] = val\n\t\t\t})\n\t\tcase \"24\":\n\t\t\terr = setFloat(dt, func(val float64) { v.SnapSpacing[1] = val })\n\t\tcase \"15\":\n\t\t\terr = setFloat(dt, func(val float64) {\n\t\t\t\tv.GridSpacing[0] = val\n\t\t\t\tv.GridSpacing[1] = val\n\t\t\t})\n\t\tcase \"25\":\n\t\t\terr = setFloat(dt, func(val float64) { v.GridSpacing[1] = val })\n\t\tcase \"16\":\n\t\t\terr = setFloat(dt, func(val float64) { v.ViewDirection[0] = val })\n\t\tcase \"26\":\n\t\t\terr = setFloat(dt, func(val float64) { v.ViewDirection[1] = val })\n\t\tcase \"36\":\n\t\t\terr = setFloat(dt, func(val float64) { v.ViewDirection[2] = val })\n\t\tcase \"17\":\n\t\t\terr = setFloat(dt, func(val float64) { v.ViewTarget[0] = val })\n\t\tcase \"27\":\n\t\t\terr = setFloat(dt, func(val float64) { v.ViewTarget[1] = val })\n\t\tcase \"37\":\n\t\t\terr = setFloat(dt, func(val float64) { v.ViewTarget[2] = val })\n\t\tcase \"40\":\n\t\t\terr = setFloat(dt, func(val float64) { v.Height = val })\n\t\tcase \"41\":\n\t\t\terr = setFloat(dt, func(val float64) { v.AspectRatio = val })\n\t\tcase \"42\":\n\t\t\terr = setFloat(dt, func(val float64) { v.LensLength = val })\n\t\tcase \"43\":\n\t\t\terr = setFloat(dt, func(val float64) { v.FrontClip = val })\n\t\tcase \"44\":\n\t\t\terr = setFloat(dt, func(val float64) { v.BackClip = val })\n\t\tcase \"50\":\n\t\t\terr = setFloat(dt, func(val float64) { v.SnapAngle = val })\n\t\tcase \"51\":\n\t\t\terr = setFloat(dt, func(val float64) { v.TwistAngle = val })\n\t\t}\n\t\tif err != nil {\n\t\t\treturn v, err\n\t\t}\n\t}\n\treturn v, nil\n}", "func DepthFunc(xfunc uint32) {\n C.glowDepthFunc(gpDepthFunc, (C.GLenum)(xfunc))\n}", "func (c *Camera) santizeBounds() {\n\t// x and y\n\tif c.x < 0 {\n\t\tc.x = 0\n\t}\n\tif c.y < 0 {\n\t\tc.y = 0\n\t}\n\tif c.x+c.width > c.worldWidth {\n\t\tc.x = c.worldWidth - c.width\n\t}\n\tif c.y+c.height > c.worldHeight {\n\t\tc.y = c.worldHeight - c.height\n\t}\n\n\t// width and height\n\tif c.width < 100 {\n\t\tc.width = 100\n\t}\n\tif c.height < 100 {\n\t\tc.height = 100\n\t}\n\tif c.width > c.worldWidth {\n\t\tc.width = c.worldWidth\n\t}\n\tif c.height > c.worldHeight {\n\t\tc.height = c.worldHeight\n\t}\n}", "func (tb *TextBuf) ViewportFromView() *gi.Viewport2D {\n\tif len(tb.Views) > 0 {\n\t\treturn tb.Views[0].Viewport\n\t}\n\treturn nil\n}", "func (gl *WebGL) DepthFunc(function GLEnum) {\n\tgl.context.Call(\"depthFunc\", function)\n}", "func (game *Game) Layout(outsideWidth, outsideHeight int) (screenWidth, screenHeight int) {\n return 640, 480\n}", "func getLightmapDimensions(faceVertices []q2file.Vertex, texInfo q2file.TexInfo) LightmapDimensions {\n\tstartUV := getTextureUV(faceVertices[0], texInfo)\n\n\t// Find the Min and Max UV's for a face\n\tstartUV0 := float64(startUV[0])\n\tstartUV1 := float64(startUV[1])\n\tminU := math.Floor(startUV0)\n\tminV := math.Floor(startUV1)\n\tmaxU := math.Floor(startUV0)\n\tmaxV := math.Floor(startUV1)\n\n\tfor i := 1; i < len(faceVertices); i++ {\n\t\tuv := getTextureUV(faceVertices[i], texInfo)\n\t\tuv0 := float64(uv[0])\n\t\tuv1 := float64(uv[1])\n\n\t\tif math.Floor(uv0) < minU {\n\t\t\tminU = math.Floor(uv0)\n\t\t}\n\t\tif math.Floor(uv1) < minV {\n\t\t\tminV = math.Floor(uv1)\n\t\t}\n\t\tif math.Floor(uv0) > maxU {\n\t\t\tmaxU = math.Floor(uv0)\n\t\t}\n\t\tif math.Floor(uv1) > maxV {\n\t\t\tmaxV = math.Floor(uv1)\n\t\t}\n\t}\n\n\t// Calculate the lightmap dimensions\n\treturn LightmapDimensions{\n\t\tWidth: int32(math.Ceil(maxU/16) - math.Floor(minU/16) + 1),\n\t\tHeight: int32(math.Ceil(maxV/16) - math.Floor(minV/16) + 1),\n\t\tMinU: float32(math.Floor(minU)),\n\t\tMinV: float32(math.Floor(minV)),\n\t}\n}", "func DepthFunc(xfunc uint32) {\n\tC.glowDepthFunc(gpDepthFunc, (C.GLenum)(xfunc))\n}", "func DepthFunc(xfunc uint32) {\n\tC.glowDepthFunc(gpDepthFunc, (C.GLenum)(xfunc))\n}", "func ViewBoundScale(value float64) *SimpleElement { return newSEFloat(\"viewBoundScale\", value) }", "func debugPrintWinSize() {\n\twindow := getWinSize()\n\tfmt.Printf(\"col: %v\\nrow: %v\\nx: %v\\ny: %v\\n\", window.col, window.row, window.unusedX, window.unusedY)\n}", "func d11rectVolume(rect *d11rectT) float64 {\n\tvar volume float64 = 1\n\tfor index := 0; index < d11numDims; index++ {\n\t\tvolume *= rect.max[index] - rect.min[index]\n\t}\n\treturn volume\n}", "func DepthMask(flag bool) {\n C.glowDepthMask(gpDepthMask, (C.GLboolean)(boolToInt(flag)))\n}", "func (ac *Activity) SurfaceBounds(ctx context.Context) (Rect, error) {\n\tcmd := ac.a.Command(ctx, \"dumpsys\", \"window\", \"windows\")\n\toutput, err := cmd.Output()\n\tif err != nil {\n\t\treturn Rect{}, errors.Wrap(err, \"failed to launch dumpsys\")\n\t}\n\n\t// Looking for:\n\t// Window #0 Window{a486f07 u0 com.android.settings/com.android.settings.Settings}:\n\t// mDisplayId=0 stackId=2 mSession=Session{dd34b88 2586:1000} mClient=android.os.BinderProxy@705e146\n\t// mHasSurface=true isReadyForDisplay()=true mWindowRemovalAllowed=false\n\t// [...many other properties...]\n\t// mFrame=[0,0][1536,1936] last=[0,0][1536,1936]\n\t// We are interested in \"mFrame=\"\n\tregStr := `(?m)` + // Enable multiline.\n\t\t`^\\s*Window #\\d+ Window{\\S+ \\S+ ` + regexp.QuoteMeta(ac.pkgName+\"/\"+ac.pkgName+ac.activityName) + `}:$` + // Match our activity\n\t\t`(?:\\n.*?)*` + // Skip entire lines with a non-greedy search...\n\t\t`^\\s*mFrame=\\[(\\d+),(\\d+)\\]\\[(\\d+),(\\d+)\\]` // ...until we match the first mFrame=\n\tre := regexp.MustCompile(regStr)\n\tgroups := re.FindStringSubmatch(string(output))\n\tif len(groups) != 5 {\n\t\ttesting.ContextLog(ctx, string(output))\n\t\treturn Rect{}, errors.New(\"failed to parse dumpsys output; activity not running perhaps?\")\n\t}\n\tbounds, err := parseBounds(groups[1:5])\n\tif err != nil {\n\t\treturn Rect{}, err\n\t}\n\treturn bounds, nil\n}", "func (nv *NetView) ViewConfig() {\n\tvs := nv.Scene()\n\tif nv.Net == nil || nv.Net.NLayers() == 0 {\n\t\tvs.DeleteChildren(true)\n\t\tvs.Meshes.Reset()\n\t\treturn\n\t}\n\tif vs.Lights.Len() == 0 {\n\t\tnv.ViewDefaults()\n\t}\n\tvs.BgColor = gi.Prefs.Colors.Background // reset in case user changes\n\tnlay := nv.Net.NLayers()\n\tlaysGp, err := vs.ChildByNameTry(\"Layers\", 0)\n\tif err != nil {\n\t\tlaysGp = gi3d.AddNewGroup(vs, vs, \"Layers\")\n\t}\n\tlayConfig := kit.TypeAndNameList{}\n\tfor li := 0; li < nlay; li++ {\n\t\tlay := nv.Net.Layer(li)\n\t\tlmesh := vs.MeshByName(lay.Name())\n\t\tif lmesh == nil {\n\t\t\tAddNewLayMesh(vs, nv, lay)\n\t\t} else {\n\t\t\tlmesh.(*LayMesh).Lay = lay // make sure\n\t\t}\n\t\tlayConfig.Add(gi3d.KiT_Group, lay.Name())\n\t}\n\tgpConfig := kit.TypeAndNameList{}\n\tgpConfig.Add(KiT_LayObj, \"layer\")\n\tgpConfig.Add(KiT_LayName, \"name\")\n\n\t_, updt := laysGp.ConfigChildren(layConfig)\n\t// if !mods {\n\t// \tupdt = laysGp.UpdateStart()\n\t// }\n\tnmin, nmax := nv.Net.Bounds()\n\tnsz := nmax.Sub(nmin).Sub(mat32.Vec3{1, 1, 0}).Max(mat32.Vec3{1, 1, 1})\n\tnsc := mat32.Vec3{1.0 / nsz.X, 1.0 / nsz.Y, 1.0 / nsz.Z}\n\tszc := mat32.Max(nsc.X, nsc.Y)\n\tpoff := mat32.NewVec3Scalar(0.5)\n\tpoff.Y = -0.5\n\tfor li, lgi := range *laysGp.Children() {\n\t\tly := nv.Net.Layer(li)\n\t\tlg := lgi.(*gi3d.Group)\n\t\tlg.ConfigChildren(gpConfig) // won't do update b/c of above\n\t\tlp := ly.Pos()\n\t\tlp.Y = -lp.Y // reverse direction\n\t\tlp = lp.Sub(nmin).Mul(nsc).Sub(poff)\n\t\trp := ly.RelPos()\n\t\tlg.Pose.Pos.Set(lp.X, lp.Z, lp.Y)\n\t\tlg.Pose.Scale.Set(nsc.X*rp.Scale, szc, nsc.Y*rp.Scale)\n\n\t\tlo := lg.Child(0).(*LayObj)\n\t\tlo.Defaults()\n\t\tlo.LayName = ly.Name()\n\t\tlo.NetView = nv\n\t\tlo.SetMeshName(vs, ly.Name())\n\t\tlo.Mat.Color.SetUInt8(255, 100, 255, 255)\n\t\tlo.Mat.Reflective = 8\n\t\tlo.Mat.Bright = 8\n\t\tlo.Mat.Shiny = 30\n\t\t// note: would actually be better to NOT cull back so you can view underneath\n\t\t// but then the front and back fight against each other, causing flickering\n\n\t\ttxt := lg.Child(1).(*LayName)\n\t\ttxt.Nm = \"layname:\" + ly.Name()\n\t\ttxt.Defaults(vs)\n\t\ttxt.NetView = nv\n\t\ttxt.SetText(vs, ly.Name())\n\t\ttxt.Pose.Scale = mat32.NewVec3Scalar(nv.Params.LayNmSize).Div(lg.Pose.Scale)\n\t\ttxt.SetProp(\"text-align\", gist.AlignLeft)\n\t\ttxt.SetProp(\"text-vertical-align\", gist.AlignTop)\n\t}\n\tlaysGp.UpdateEnd(updt)\n}", "func onWindowResize(w *glfw.Window, width int, height int) {\n\t// uiman.AdviseResolution(int32(width), int32(height))\n\t// renderer.ChangeResolution(int32(width), int32(height))\n}", "func DepthToSpace(scope *Scope, input tf.Output, block_size int64, optional ...DepthToSpaceAttr) (output tf.Output) {\n\tif scope.Err() != nil {\n\t\treturn\n\t}\n\tattrs := map[string]interface{}{\"block_size\": block_size}\n\tfor _, a := range optional {\n\t\ta(attrs)\n\t}\n\topspec := tf.OpSpec{\n\t\tType: \"DepthToSpace\",\n\t\tInput: []tf.Input{\n\t\t\tinput,\n\t\t},\n\t\tAttrs: attrs,\n\t}\n\top := scope.AddOperation(opspec)\n\treturn op.Output(0)\n}", "func (w *GlfwWindow) ScreenResolution(p interface{}) (width, height int) {\n\n\tmon := glfw.GetPrimaryMonitor()\n\tvmode := mon.GetVideoMode()\n\treturn vmode.Width, vmode.Height\n}", "func createCfgs() []pixelgl.WindowConfig {\n\tret := []pixelgl.WindowConfig{}\n\tfor _, m := range pixelgl.Monitors() {\n\t\tmX, mY := m.Size()\n\t\tret = append(ret, pixelgl.WindowConfig{\n\t\t\tBounds: pixel.R(0, 0, mX, mY),\n\t\t\tVSync: true,\n\t\t\tMonitor: m,\n\t\t})\n\t}\n\n\treturn ret\n}", "func onWindowResize(w *glfw.Window, width int, height int) {\n\tuiman.AdviseResolution(int32(width), int32(height))\n\trenderer.ChangeResolution(int32(width), int32(height))\n}", "func Frustum(left, right, bottom, top, near, far float64) Mat4 {\n\trml, tmb, fmn := (right - left), (top - bottom), (far - near)\n\tA, B, C, D := (right+left)/rml, (top+bottom)/tmb, -(far+near)/fmn, -(2*far*near)/fmn\n\n\treturn Mat4{float64((2. * near) / rml), 0, 0, 0, 0, float64((2. * near) / tmb), 0, 0, float64(A), float64(B), float64(C), -1, 0, 0, float64(D), 0}\n}", "func (device *Device) StartDepthStream(resolution Resolution, format DepthFormat) error {\n\n\terrCode := C.freenect_set_depth_mode(device.device,\n\t\tC.freenect_find_depth_mode(C.freenect_resolution(resolution), C.freenect_depth_format(format)))\n\n\tif errCode != 0 {\n\t\treturn errors.New(\"could not find depth mode\")\n\t}\n\n\terrCode = C.freenect_start_depth(device.device)\n\n\tif errCode != 0 {\n\t\treturn errors.New(\"could not start depth stream\")\n\t}\n\n\treturn nil\n}", "func ProgramUniformMatrix2x4fv(program uint32, location int32, count int32, transpose bool, value *float32) {\n C.glowProgramUniformMatrix2x4fv(gpProgramUniformMatrix2x4fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (C.GLboolean)(boolToInt(transpose)), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func (d *Device) setWindow(x, y, w, h int16) {\n\tx += d.columnOffset\n\ty += d.rowOffset\n\tcopy(d.buf[:4], []uint8{uint8(x >> 8), uint8(x), uint8((x + w - 1) >> 8), uint8(x + w - 1)})\n\td.sendCommand(CASET, d.buf[:4])\n\tcopy(d.buf[:4], []uint8{uint8(y >> 8), uint8(y), uint8((y + h - 1) >> 8), uint8(y + h - 1)})\n\td.sendCommand(RASET, d.buf[:4])\n\td.sendCommand(RAMWR, nil)\n}", "func (s *stencilOverdraw) loadExistingDepthValues(ctx context.Context,\n\tcb CommandBuilder,\n\tgs *api.GlobalState,\n\tst *State,\n\ta arena.Arena,\n\tdevice VkDevice,\n\tqueue VkQueue,\n\tcmdBuffer VkCommandBuffer,\n\trenderInfo renderInfo,\n\talloc func(v ...interface{}) api.AllocResult,\n\taddCleanup func(func()),\n\tout transform.Writer,\n) error {\n\tif renderInfo.depthIdx == ^uint32(0) {\n\t\treturn nil\n\t}\n\trpInfo := st.RenderPasses().Get(renderInfo.renderPass)\n\tdaInfo := rpInfo.AttachmentDescriptions().Get(renderInfo.depthIdx)\n\n\tif daInfo.LoadOp() != VkAttachmentLoadOp_VK_ATTACHMENT_LOAD_OP_LOAD {\n\t\treturn nil\n\t}\n\n\tfbInfo := st.Framebuffers().Get(renderInfo.framebuffer)\n\n\toldImageView := fbInfo.ImageAttachments().Get(renderInfo.depthIdx)\n\tnewImageView := fbInfo.ImageAttachments().Get(uint32(fbInfo.ImageAttachments().Len() - 1))\n\n\toldImageDesc := imageDesc{\n\t\toldImageView.Image(),\n\t\toldImageView.SubresourceRange(),\n\t\tdaInfo.InitialLayout(),\n\t\tVkImageAspectFlagBits_VK_IMAGE_ASPECT_DEPTH_BIT,\n\t}\n\tnewImageDesc := imageDesc{\n\t\tnewImageView.Image(),\n\t\tnewImageView.SubresourceRange(),\n\t\tVkImageLayout_VK_IMAGE_LAYOUT_DEPTH_STENCIL_ATTACHMENT_OPTIMAL,\n\t\tVkImageAspectFlagBits_VK_IMAGE_ASPECT_DEPTH_BIT,\n\t}\n\n\treturn s.transferDepthValues(ctx, cb, gs, st, a,\n\t\tdevice, queue, cmdBuffer,\n\t\tfbInfo.Width(), fbInfo.Height(),\n\t\toldImageDesc, newImageDesc,\n\t\talloc, addCleanup, out)\n}", "func (s *stencilOverdraw) storeNewDepthValues(ctx context.Context,\n\tcb CommandBuilder,\n\tgs *api.GlobalState,\n\tst *State,\n\ta arena.Arena,\n\tdevice VkDevice,\n\tqueue VkQueue,\n\tcmdBuffer VkCommandBuffer,\n\trenderInfo renderInfo,\n\talloc func(v ...interface{}) api.AllocResult,\n\taddCleanup func(func()),\n\tout transform.Writer,\n) error {\n\tif renderInfo.depthIdx == ^uint32(0) {\n\t\treturn nil\n\t}\n\trpInfo := st.RenderPasses().Get(renderInfo.renderPass)\n\tdaInfo := rpInfo.AttachmentDescriptions().Get(renderInfo.depthIdx)\n\n\tif daInfo.StoreOp() != VkAttachmentStoreOp_VK_ATTACHMENT_STORE_OP_STORE {\n\t\treturn nil\n\t}\n\n\tfbInfo := st.Framebuffers().Get(renderInfo.framebuffer)\n\n\toldImageView := fbInfo.ImageAttachments().Get(uint32(fbInfo.ImageAttachments().Len() - 1))\n\tnewImageView := fbInfo.ImageAttachments().Get(renderInfo.depthIdx)\n\n\toldImageDesc := imageDesc{\n\t\toldImageView.Image(),\n\t\toldImageView.SubresourceRange(),\n\t\trpInfo.AttachmentDescriptions().Get(uint32(fbInfo.ImageAttachments().Len() - 1)).FinalLayout(),\n\t\tVkImageAspectFlagBits_VK_IMAGE_ASPECT_DEPTH_BIT,\n\t}\n\tnewImageDesc := imageDesc{\n\t\tnewImageView.Image(),\n\t\tnewImageView.SubresourceRange(),\n\t\tdaInfo.FinalLayout(),\n\t\tVkImageAspectFlagBits_VK_IMAGE_ASPECT_DEPTH_BIT,\n\t}\n\treturn s.transferDepthValues(ctx, cb, gs, st, a,\n\t\tdevice, queue, cmdBuffer,\n\t\tfbInfo.Width(), fbInfo.Height(),\n\t\toldImageDesc, newImageDesc,\n\t\talloc, addCleanup, out)\n}", "func ProgramUniformMatrix3x4fv(program uint32, location int32, count int32, transpose bool, value *float32) {\n C.glowProgramUniformMatrix3x4fv(gpProgramUniformMatrix3x4fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (C.GLboolean)(boolToInt(transpose)), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func DepthMask(flag bool) {\n\tC.glowDepthMask(gpDepthMask, (C.GLboolean)(boolToInt(flag)))\n}", "func DepthMask(flag bool) {\n\tC.glowDepthMask(gpDepthMask, (C.GLboolean)(boolToInt(flag)))\n}", "func ProgramUniformMatrix3x2fv(program uint32, location int32, count int32, transpose bool, value *float32) {\n C.glowProgramUniformMatrix3x2fv(gpProgramUniformMatrix3x2fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (C.GLboolean)(boolToInt(transpose)), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func (c *Camera) isWithinView(x, y, w, h float64) bool {\n\treturn x > 0-w/2 &&\n\t\tx < float64(c.viewportWidth)+w/2 &&\n\t\ty > 0-h/2 &&\n\t\ty < float64(c.viewportHeight)+w/2\n}", "func (c *Camera) Update(window *pixelgl.Window) {\n\tc.pixelPosition.X = c.chaseObject.GetPosition().X - window.Bounds().Max.X / 2\n\tc.pixelPosition.Y = c.chaseObject.GetPosition().Y - window.Bounds().Max.Y / 2\n\n\tc.matrixPosition = pixel.IM.Moved(c.pixelPosition.Scaled(-1))\n\twindow.SetMatrix(c.matrixPosition)\n\n\tc.zoom *= math.Pow(c.zoomSpeed, window.MouseScroll().Y)\n\n\tif c.zoom > c.maxZoom {\n\t\tc.zoom = c.maxZoom\n\t} else if c.zoom < c.minZoom {\n\t\tc.zoom = c.minZoom\n\t}\n}", "func ProgramUniform2fv(program uint32, location int32, count int32, value *float32) {\n C.glowProgramUniform2fv(gpProgramUniform2fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func SetVirtualResolution(w, h float32) {\n\tscreen.SetVirtualSize(w, h)\n}", "func ProgramUniformMatrix4x2fv(program uint32, location int32, count int32, transpose bool, value *float32) {\n C.glowProgramUniformMatrix4x2fv(gpProgramUniformMatrix4x2fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (C.GLboolean)(boolToInt(transpose)), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func Project(obj Vec3, modelview, projection Mat4, initialX, initialY, width, height int) (win Vec3) {\n\tobj4 := obj.Vec4(1)\n\n\tvpp := projection.Mul4(modelview).Mul4x1(obj4)\n\tvpp = vpp.Mul(1 / vpp.W())\n\twin[0] = float64(initialX) + (float64(width)*(vpp[0]+1))/2\n\twin[1] = float64(initialY) + (float64(height)*(vpp[1]+1))/2\n\twin[2] = (vpp[2] + 1) / 2\n\n\treturn win\n}", "func (p *Projection) grid(xInterval float64, yInterval float64) {\n l := draw2d.NewGraphicContext(p.img)\n l.SetStrokeColor(color.RGBA{0xEE, 0xEE, 0xEE, 0xFF})\n l.SetLineWidth(0.5)\n\n xCount := p.worldWidth / xInterval\n yCount := p.worldHeight / yInterval\n\n // horizontal lines\n for x := 1.0; x < xCount; x += 1 {\n xx, _ := p.project((x - (xCount / 2)) * xInterval, 0)\n l.MoveTo(xx, 0)\n l.LineTo(xx, p.canvasHeight)\n l.Stroke()\n }\n\n // vertical lines\n for y := 1.0; y < yCount; y += 1 {\n _, yy := p.project(0, (y - (yCount / 2)) * yInterval)\n l.MoveTo(0, yy)\n l.LineTo(p.canvasWidth, yy)\n l.Stroke()\n }\n\n l.SetStrokeColor(color.RGBA{0xAA, 0xAA, 0xAA, 0xFF})\n\n // horiz axis\n l.MoveTo(p.canvasWidth/2, 0)\n l.LineTo(p.canvasWidth/2, p.canvasHeight)\n l.Stroke()\n\n // vert axis\n l.MoveTo(0, p.canvasHeight/2)\n l.LineTo(p.canvasWidth, p.canvasHeight/2)\n l.Stroke()\n}", "func dcBoundVertexPosition(d sdf.SDF3, leaf *dcOctree, qefPosition v3.Vec, qefSolver *dcQefSolver) v3.Vec {\n\t// Avoid placing vertex outside node bounds\n\tmin := leaf.relToSDF(d, leaf.minOffset)\n\tmax := leaf.relToSDF(d, leaf.minOffset.Add(v3i.Vec{leaf.size, leaf.size, leaf.size}))\n\tif qefPosition.X < min.X || qefPosition.Y < min.Y || qefPosition.Z < min.Z ||\n\t\tqefPosition.X > max.X || qefPosition.Y > max.Y || qefPosition.Z > max.Z {\n\t\t//log.Println(\"Fixing vertex position\", qefPosition, \"-->\", qefSolver.massPointSum)\n\t\tqefPosition = qefSolver.MassPoint()\n\t} else {\n\t\t//log.Println(\"NOT fixing vertex position\", qefPosition)\n\t}\n\treturn qefPosition\n}", "func ProgramUniformMatrix2x3fv(program uint32, location int32, count int32, transpose bool, value *float32) {\n C.glowProgramUniformMatrix2x3fv(gpProgramUniformMatrix2x3fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (C.GLboolean)(boolToInt(transpose)), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func (c *Camera) ScreenToWorld(posX, posY int) (float64, float64) {\n\tinverseMatrix := c.worldMatrix()\n\tif inverseMatrix.IsInvertible() {\n\t\tinverseMatrix.Invert()\n\t\treturn inverseMatrix.Apply(float64(posX), float64(posY))\n\t}\n\t// When scaling it can happend that matrix is not invertable\n\treturn math.NaN(), math.NaN()\n}", "func (buf *CommandBuffer) SetViewport(firstViewport uint32, viewports []Viewport) {\n\tC.domVkCmdSetViewport(\n\t\tbuf.fps[vkCmdSetViewport],\n\t\tbuf.hnd,\n\t\tC.uint32_t(firstViewport),\n\t\tC.uint32_t(len(viewports)),\n\t\t(*C.VkViewport)(slice2ptr(uptr(&viewports))))\n}", "func Uniform2fv(location int32, count int32, value *float32) {\n C.glowUniform2fv(gpUniform2fv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func VEventfDepth(ctx context.Context, depth int, level int32, format string, args ...interface{}) {\n\tvEventf(ctx, false /* isErr */, 1+depth, level, format, args...)\n}", "func CreateMessagePipeForViewportParameterListener() (ViewportParameterListener_Request, ViewportParameterListener_Pointer) {\n r, p := bindings.CreateMessagePipeForMojoInterface()\n return ViewportParameterListener_Request(r), ViewportParameterListener_Pointer(p)\n}" ]
[ "0.59922934", "0.59079075", "0.59076226", "0.59001887", "0.5800557", "0.5738982", "0.5721392", "0.5667043", "0.5666999", "0.562695", "0.5626007", "0.53602004", "0.5342091", "0.5301649", "0.5301649", "0.52494806", "0.5241753", "0.52195865", "0.52018315", "0.51966774", "0.5117206", "0.5095992", "0.508818", "0.5080405", "0.5051455", "0.5036483", "0.5022017", "0.50014734", "0.49945784", "0.49309367", "0.49309367", "0.4927669", "0.4894125", "0.48896694", "0.48885888", "0.47840706", "0.46950006", "0.46915272", "0.46895427", "0.46830282", "0.4679083", "0.46698767", "0.46693736", "0.4662706", "0.46606356", "0.46438622", "0.46400994", "0.462272", "0.45812988", "0.4567801", "0.45252514", "0.4503343", "0.4495748", "0.44709364", "0.44481796", "0.44262296", "0.43901545", "0.438499", "0.43725938", "0.43559912", "0.4335528", "0.4330617", "0.43167365", "0.43167365", "0.43070123", "0.4279196", "0.42713252", "0.42576104", "0.4236728", "0.42326307", "0.42255497", "0.42139447", "0.42101014", "0.42092136", "0.4196078", "0.41845486", "0.4165022", "0.41647977", "0.41445652", "0.41392753", "0.4134931", "0.41145357", "0.41080454", "0.41080454", "0.4107349", "0.4094227", "0.40867817", "0.4086652", "0.40837744", "0.40813288", "0.40780333", "0.40740317", "0.4071868", "0.407156", "0.40702644", "0.40702274", "0.40678677", "0.40674844", "0.4057136" ]
0.5041937
26
specify mapping of depth values from normalized device coordinates to window coordinates
func DepthRangef(n float32, f float32) { C.glowDepthRangef(gpDepthRangef, (C.GLfloat)(n), (C.GLfloat)(f)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func DepthRange(near float64, far float64) {\n C.glowDepthRange(gpDepthRange, (C.GLdouble)(near), (C.GLdouble)(far))\n}", "func DepthRange(n float64, f float64) {\n\tsyscall.Syscall(gpDepthRange, 2, uintptr(math.Float64bits(n)), uintptr(math.Float64bits(f)), 0)\n}", "func DepthRangeIndexed(index uint32, n float64, f float64) {\n C.glowDepthRangeIndexed(gpDepthRangeIndexed, (C.GLuint)(index), (C.GLdouble)(n), (C.GLdouble)(f))\n}", "func DepthRangef(n float32, f float32) {\n\tsyscall.Syscall(gpDepthRangef, 2, uintptr(math.Float32bits(n)), uintptr(math.Float32bits(f)), 0)\n}", "func DepthRangef(n Float, f Float) {\n\tcn, _ := (C.GLfloat)(n), cgoAllocsUnknown\n\tcf, _ := (C.GLfloat)(f), cgoAllocsUnknown\n\tC.glDepthRangef(cn, cf)\n}", "func DepthRange(n float64, f float64) {\n\tC.glowDepthRange(gpDepthRange, (C.GLdouble)(n), (C.GLdouble)(f))\n}", "func DepthRange(n float64, f float64) {\n\tC.glowDepthRange(gpDepthRange, (C.GLdouble)(n), (C.GLdouble)(f))\n}", "func (dev *Device) StartDepth() int {\n\treturn int(C.freenect_start_depth(dev.ptr()))\n}", "func DepthRangeIndexed(index uint32, n float64, f float64) {\n\tsyscall.Syscall(gpDepthRangeIndexed, 3, uintptr(index), uintptr(math.Float64bits(n)), uintptr(math.Float64bits(f)))\n}", "func DepthFunc(xfunc uint32) {\n\tsyscall.Syscall(gpDepthFunc, 1, uintptr(xfunc), 0, 0)\n}", "func DepthRangef(n, f float32) {\n\tgl.DepthRangef(n, f)\n}", "func DepthFunc(xfunc uint32) {\n C.glowDepthFunc(gpDepthFunc, (C.GLenum)(xfunc))\n}", "func DepthRangeIndexed(index uint32, n float64, f float64) {\n\tC.glowDepthRangeIndexed(gpDepthRangeIndexed, (C.GLuint)(index), (C.GLdouble)(n), (C.GLdouble)(f))\n}", "func DepthRangeIndexed(index uint32, n float64, f float64) {\n\tC.glowDepthRangeIndexed(gpDepthRangeIndexed, (C.GLuint)(index), (C.GLdouble)(n), (C.GLdouble)(f))\n}", "func DepthFunc(fn Enum) {\n\tgl.DepthFunc(uint32(fn))\n}", "func (dev *Device) SetDepthBuffer(buf unsafe.Pointer) int {\n\treturn int(C.freenect_set_depth_buffer(dev.ptr(), buf))\n}", "func DepthMask(flag bool) {\n\tsyscall.Syscall(gpDepthMask, 1, boolToUintptr(flag), 0, 0)\n}", "func world2screen(wx, wy float32) (sx, sy int) {\n\tsx = int((wx * pixel_per_meter) + (float32(WINDOW_X) / 2.0))\n\tsy = int((-wy * pixel_per_meter) + (float32(WINDOW_Y) / 2.0))\n\treturn\n}", "func GetRenderbufferDepthSize(target GLEnum) int32 {\n\tvar params int32\n\tgl.GetRenderbufferParameteriv(uint32(target), gl.RENDERBUFFER_DEPTH_SIZE, &params)\n\treturn params\n}", "func DepthFunc(func_ GLenum) {\n\tC.glDepthFunc(C.GLenum(func_))\n}", "func DepthMask(flag Boolean) {\n\tcflag, _ := (C.GLboolean)(flag), cgoAllocsUnknown\n\tC.glDepthMask(cflag)\n}", "func (s *stencilOverdraw) loadExistingDepthValues(ctx context.Context,\n\tcb CommandBuilder,\n\tgs *api.GlobalState,\n\tst *State,\n\ta arena.Arena,\n\tdevice VkDevice,\n\tqueue VkQueue,\n\tcmdBuffer VkCommandBuffer,\n\trenderInfo renderInfo,\n\talloc func(v ...interface{}) api.AllocResult,\n\taddCleanup func(func()),\n\tout transform.Writer,\n) error {\n\tif renderInfo.depthIdx == ^uint32(0) {\n\t\treturn nil\n\t}\n\trpInfo := st.RenderPasses().Get(renderInfo.renderPass)\n\tdaInfo := rpInfo.AttachmentDescriptions().Get(renderInfo.depthIdx)\n\n\tif daInfo.LoadOp() != VkAttachmentLoadOp_VK_ATTACHMENT_LOAD_OP_LOAD {\n\t\treturn nil\n\t}\n\n\tfbInfo := st.Framebuffers().Get(renderInfo.framebuffer)\n\n\toldImageView := fbInfo.ImageAttachments().Get(renderInfo.depthIdx)\n\tnewImageView := fbInfo.ImageAttachments().Get(uint32(fbInfo.ImageAttachments().Len() - 1))\n\n\toldImageDesc := imageDesc{\n\t\toldImageView.Image(),\n\t\toldImageView.SubresourceRange(),\n\t\tdaInfo.InitialLayout(),\n\t\tVkImageAspectFlagBits_VK_IMAGE_ASPECT_DEPTH_BIT,\n\t}\n\tnewImageDesc := imageDesc{\n\t\tnewImageView.Image(),\n\t\tnewImageView.SubresourceRange(),\n\t\tVkImageLayout_VK_IMAGE_LAYOUT_DEPTH_STENCIL_ATTACHMENT_OPTIMAL,\n\t\tVkImageAspectFlagBits_VK_IMAGE_ASPECT_DEPTH_BIT,\n\t}\n\n\treturn s.transferDepthValues(ctx, cb, gs, st, a,\n\t\tdevice, queue, cmdBuffer,\n\t\tfbInfo.Width(), fbInfo.Height(),\n\t\toldImageDesc, newImageDesc,\n\t\talloc, addCleanup, out)\n}", "func DepthMask(flag bool) {\n\tgl.DepthMask(flag)\n}", "func DepthMask(flag bool) {\n\tC.glDepthMask(glBool(flag))\n}", "func GetDepthModeCount() int {\n\treturn int(C.freenect_get_depth_mode_count())\n}", "func (s *stencilOverdraw) storeNewDepthValues(ctx context.Context,\n\tcb CommandBuilder,\n\tgs *api.GlobalState,\n\tst *State,\n\ta arena.Arena,\n\tdevice VkDevice,\n\tqueue VkQueue,\n\tcmdBuffer VkCommandBuffer,\n\trenderInfo renderInfo,\n\talloc func(v ...interface{}) api.AllocResult,\n\taddCleanup func(func()),\n\tout transform.Writer,\n) error {\n\tif renderInfo.depthIdx == ^uint32(0) {\n\t\treturn nil\n\t}\n\trpInfo := st.RenderPasses().Get(renderInfo.renderPass)\n\tdaInfo := rpInfo.AttachmentDescriptions().Get(renderInfo.depthIdx)\n\n\tif daInfo.StoreOp() != VkAttachmentStoreOp_VK_ATTACHMENT_STORE_OP_STORE {\n\t\treturn nil\n\t}\n\n\tfbInfo := st.Framebuffers().Get(renderInfo.framebuffer)\n\n\toldImageView := fbInfo.ImageAttachments().Get(uint32(fbInfo.ImageAttachments().Len() - 1))\n\tnewImageView := fbInfo.ImageAttachments().Get(renderInfo.depthIdx)\n\n\toldImageDesc := imageDesc{\n\t\toldImageView.Image(),\n\t\toldImageView.SubresourceRange(),\n\t\trpInfo.AttachmentDescriptions().Get(uint32(fbInfo.ImageAttachments().Len() - 1)).FinalLayout(),\n\t\tVkImageAspectFlagBits_VK_IMAGE_ASPECT_DEPTH_BIT,\n\t}\n\tnewImageDesc := imageDesc{\n\t\tnewImageView.Image(),\n\t\tnewImageView.SubresourceRange(),\n\t\tdaInfo.FinalLayout(),\n\t\tVkImageAspectFlagBits_VK_IMAGE_ASPECT_DEPTH_BIT,\n\t}\n\treturn s.transferDepthValues(ctx, cb, gs, st, a,\n\t\tdevice, queue, cmdBuffer,\n\t\tfbInfo.Width(), fbInfo.Height(),\n\t\toldImageDesc, newImageDesc,\n\t\talloc, addCleanup, out)\n}", "func DepthMask(flag bool) {\n C.glowDepthMask(gpDepthMask, (C.GLboolean)(boolToInt(flag)))\n}", "func DepthFunc(xfunc uint32) {\n\tC.glowDepthFunc(gpDepthFunc, (C.GLenum)(xfunc))\n}", "func DepthFunc(xfunc uint32) {\n\tC.glowDepthFunc(gpDepthFunc, (C.GLenum)(xfunc))\n}", "func (native *OpenGL) DepthMask(mask bool) {\n\tgl.DepthMask(mask)\n}", "func ScreenXY(value Vec2) *SimpleElement { return newSEVec2(\"screenXY\", value) }", "func SetDepthFunc(_func Enum) {\n\tc_func, _ := (C.GLenum)(_func), cgoAllocsUnknown\n\tC.glDepthFunc(c_func)\n}", "func (native *OpenGL) DepthFunc(xfunc uint32) {\n\tgl.DepthFunc(xfunc)\n}", "func (dev *Device) SetDepthMode(mode FrameMode) int {\n\treturn int(C.freenect_set_depth_mode(dev.ptr(), *mode.ptr()))\n}", "func GenDepthTexture(width, height int32) gl.Texture2D {\n\ttex := gl.GenTexture2D()\n\ttex.Bind()\n\ttex.MinFilter(gl.NEAREST)\n\ttex.MagFilter(gl.NEAREST)\n\ttex.WrapS(gl.CLAMP_TO_EDGE)\n\ttex.WrapT(gl.CLAMP_TO_EDGE)\n\ttex.TexImage2D(0, gl.DEPTH_COMPONENT, width, height, 0, gl.DEPTH_COMPONENT, gl.FLOAT, nil)\n\ttex.Unbind()\n\treturn tex\n}", "func (mParams *EncodingMatrixLiteral) Depth(actual bool) (depth int) {\n\tif actual {\n\t\tdepth = len(mParams.ScalingFactor)\n\t} else {\n\t\tfor i := range mParams.ScalingFactor {\n\t\t\tfor range mParams.ScalingFactor[i] {\n\t\t\t\tdepth++\n\t\t\t}\n\t\t}\n\t}\n\treturn\n}", "func Frustum(left float64, right float64, bottom float64, top float64, zNear float64, zFar float64) {\n C.glowFrustum(gpFrustum, (C.GLdouble)(left), (C.GLdouble)(right), (C.GLdouble)(bottom), (C.GLdouble)(top), (C.GLdouble)(zNear), (C.GLdouble)(zFar))\n}", "func (dev *Device) StopDepth() int {\n\treturn int(C.freenect_stop_depth(dev.ptr()))\n}", "func DepthMask(flag bool) {\n\tC.glowDepthMask(gpDepthMask, (C.GLboolean)(boolToInt(flag)))\n}", "func DepthMask(flag bool) {\n\tC.glowDepthMask(gpDepthMask, (C.GLboolean)(boolToInt(flag)))\n}", "func (device *Device) StartDepthStream(resolution Resolution, format DepthFormat) error {\n\n\terrCode := C.freenect_set_depth_mode(device.device,\n\t\tC.freenect_find_depth_mode(C.freenect_resolution(resolution), C.freenect_depth_format(format)))\n\n\tif errCode != 0 {\n\t\treturn errors.New(\"could not find depth mode\")\n\t}\n\n\terrCode = C.freenect_start_depth(device.device)\n\n\tif errCode != 0 {\n\t\treturn errors.New(\"could not start depth stream\")\n\t}\n\n\treturn nil\n}", "func (w Widths) MaxDepth() (maxDepth, deepWidth int) {\n\tfor depth, width := range w {\n\t\tif depth > maxDepth {\n\t\t\tmaxDepth = depth\n\t\t\tdeepWidth = width\n\t\t}\n\t}\n\treturn\n}", "func DepthToSpace(scope *Scope, input tf.Output, block_size int64, optional ...DepthToSpaceAttr) (output tf.Output) {\n\tif scope.Err() != nil {\n\t\treturn\n\t}\n\tattrs := map[string]interface{}{\"block_size\": block_size}\n\tfor _, a := range optional {\n\t\ta(attrs)\n\t}\n\topspec := tf.OpSpec{\n\t\tType: \"DepthToSpace\",\n\t\tInput: []tf.Input{\n\t\t\tinput,\n\t\t},\n\t\tAttrs: attrs,\n\t}\n\top := scope.AddOperation(opspec)\n\treturn op.Output(0)\n}", "func (bm Blendmap) View() (float32, float32, float32, float32) {\n\treturn bm.Map.viewport.Min.X, bm.Map.viewport.Min.Y, bm.Map.viewport.Max.X, bm.Map.viewport.Max.Y\n}", "func FindDepthMode(res Resolution, format DepthFormat) FrameMode {\n\tfm := C.freenect_find_depth_mode(C.freenect_resolution(res), C.freenect_depth_format(format))\n\treturn *(*FrameMode)(unsafe.Pointer(&fm))\n}", "func d11rectVolume(rect *d11rectT) float64 {\n\tvar volume float64 = 1\n\tfor index := 0; index < d11numDims; index++ {\n\t\tvolume *= rect.max[index] - rect.min[index]\n\t}\n\treturn volume\n}", "func MakeDepth(width, height int) Texture {\n\ttex := Make(width, height, gl.DEPTH_COMPONENT, gl.DEPTH_COMPONENT,\n\t\tgl.UNSIGNED_BYTE, nil, gl.LINEAR, gl.LINEAR, gl.CLAMP_TO_BORDER,\n\t\tgl.CLAMP_TO_BORDER)\n\treturn tex\n}", "func (c *Camera) debugUpdate() {\n\tc.State = gfx.NewState()\n\tc.Shader = shader\n\tc.State.FaceCulling = gfx.BackFaceCulling\n\n\tm := gfx.NewMesh()\n\tm.Primitive = gfx.Lines\n\n\tm.Vertices = []gfx.Vec3{}\n\tm.Colors = []gfx.Color{}\n\n\tnear := float32(c.Near)\n\tfar := float32(c.Far)\n\n\tif c.Ortho {\n\t\twidth := float32(c.View.Dx())\n\t\theight := float32(c.View.Dy())\n\n\t\tm.Vertices = []gfx.Vec3{\n\t\t\t{width / 2, 0, height / 2},\n\n\t\t\t// Near\n\t\t\t{0, near, 0},\n\t\t\t{width, near, 0},\n\t\t\t{width, near, height},\n\t\t\t{0, near, height},\n\n\t\t\t// Far\n\t\t\t{0, far, 0},\n\t\t\t{width, far, 0},\n\t\t\t{width, far, height},\n\t\t\t{0, far, height},\n\n\t\t\t{width / 2, far, height / 2},\n\n\t\t\t// Up\n\t\t\t{0, near, height},\n\t\t\t{0, near, height},\n\t\t\t{width, near, height},\n\t\t}\n\t} else {\n\t\tratio := float32(c.View.Dx()) / float32(c.View.Dy())\n\t\tfovRad := c.FOV / 180 * math.Pi\n\n\t\thNear := float32(2 * math.Tan(fovRad/2) * c.Near)\n\t\twNear := hNear * ratio\n\n\t\thFar := float32(2 * math.Tan(fovRad/2) * c.Far)\n\t\twFar := hFar * ratio\n\n\t\tm.Vertices = []gfx.Vec3{\n\t\t\t{0, 0, 0},\n\n\t\t\t// Near\n\t\t\t{-wNear / 2, near, -hNear / 2},\n\t\t\t{wNear / 2, near, -hNear / 2},\n\t\t\t{wNear / 2, near, hNear / 2},\n\t\t\t{-wNear / 2, near, hNear / 2},\n\n\t\t\t// Far\n\t\t\t{-wFar / 2, far, -hFar / 2},\n\t\t\t{wFar / 2, far, -hFar / 2},\n\t\t\t{wFar / 2, far, hFar / 2},\n\t\t\t{-wFar / 2, far, hFar / 2},\n\n\t\t\t{0, far, 0},\n\n\t\t\t// Up\n\t\t\t{0, near, hNear},\n\t\t\t{-wNear / 2 * 0.7, near, hNear / 2 * 1.1},\n\t\t\t{wNear / 2 * 0.7, near, hNear / 2 * 1.1},\n\t\t}\n\t}\n\n\tm.Colors = []gfx.Color{\n\t\t{1, 1, 1, 1},\n\t\t{1, 0.67, 0, 1},\n\t\t{1, 0.67, 0, 1},\n\t\t{1, 0.67, 0, 1},\n\t\t{1, 0.67, 0, 1},\n\n\t\t{1, 0.67, 0, 1},\n\t\t{1, 0.67, 0, 1},\n\t\t{1, 0.67, 0, 1},\n\t\t{1, 0.67, 0, 1},\n\t\t{1, 1, 1, 1},\n\n\t\t{0, 0.67, 1, 1},\n\t\t{0, 0.67, 1, 1},\n\t\t{0, 0.67, 1, 1},\n\t}\n\n\tm.Indices = []uint32{\n\t\t// From 0 to near plane\n\t\t0, 1,\n\t\t0, 2,\n\t\t0, 3,\n\t\t0, 4,\n\n\t\t// Near plane\n\t\t1, 2,\n\t\t2, 3,\n\t\t3, 4,\n\t\t4, 1,\n\n\t\t// Far plane\n\t\t5, 6,\n\t\t6, 7,\n\t\t7, 8,\n\t\t8, 5,\n\n\t\t// Lines from near to far plane\n\t\t1, 5,\n\t\t2, 6,\n\t\t3, 7,\n\t\t4, 8,\n\n\t\t0, 9,\n\n\t\t// Up\n\t\t10, 11,\n\t\t11, 12,\n\t\t12, 10,\n\t}\n\n\tc.Meshes = []*gfx.Mesh{m}\n}", "func getLightmapDimensions(faceVertices []q2file.Vertex, texInfo q2file.TexInfo) LightmapDimensions {\n\tstartUV := getTextureUV(faceVertices[0], texInfo)\n\n\t// Find the Min and Max UV's for a face\n\tstartUV0 := float64(startUV[0])\n\tstartUV1 := float64(startUV[1])\n\tminU := math.Floor(startUV0)\n\tminV := math.Floor(startUV1)\n\tmaxU := math.Floor(startUV0)\n\tmaxV := math.Floor(startUV1)\n\n\tfor i := 1; i < len(faceVertices); i++ {\n\t\tuv := getTextureUV(faceVertices[i], texInfo)\n\t\tuv0 := float64(uv[0])\n\t\tuv1 := float64(uv[1])\n\n\t\tif math.Floor(uv0) < minU {\n\t\t\tminU = math.Floor(uv0)\n\t\t}\n\t\tif math.Floor(uv1) < minV {\n\t\t\tminV = math.Floor(uv1)\n\t\t}\n\t\tif math.Floor(uv0) > maxU {\n\t\t\tmaxU = math.Floor(uv0)\n\t\t}\n\t\tif math.Floor(uv1) > maxV {\n\t\t\tmaxV = math.Floor(uv1)\n\t\t}\n\t}\n\n\t// Calculate the lightmap dimensions\n\treturn LightmapDimensions{\n\t\tWidth: int32(math.Ceil(maxU/16) - math.Floor(minU/16) + 1),\n\t\tHeight: int32(math.Ceil(maxV/16) - math.Floor(minV/16) + 1),\n\t\tMinU: float32(math.Floor(minU)),\n\t\tMinV: float32(math.Floor(minV)),\n\t}\n}", "func Frustum(left float64, right float64, bottom float64, top float64, zNear float64, zFar float64) {\n\tsyscall.Syscall6(gpFrustum, 6, uintptr(math.Float64bits(left)), uintptr(math.Float64bits(right)), uintptr(math.Float64bits(bottom)), uintptr(math.Float64bits(top)), uintptr(math.Float64bits(zNear)), uintptr(math.Float64bits(zFar)))\n}", "func (s *ImageSpec) Depth() int {\n\tret := int(C.ImageSpec_depth(s.ptr))\n\truntime.KeepAlive(s)\n\treturn ret\n}", "func Uniform2fv(location int32, count int32, value *float32) {\n C.glowUniform2fv(gpUniform2fv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func (gl *WebGL) DepthFunc(function GLEnum) {\n\tgl.context.Call(\"depthFunc\", function)\n}", "func MainDepth() int {\n\treturn int(C.g_main_depth())\n}", "func (c *imageBinaryChannel) dev2nRect(x1, y1, x2, y2 int) float64 {\n\treturn c.integralImage.dev2nRect(x1, y1, x2, y2)\n}", "func SpaceToDepth(scope *Scope, input tf.Output, block_size int64, optional ...SpaceToDepthAttr) (output tf.Output) {\n\tif scope.Err() != nil {\n\t\treturn\n\t}\n\tattrs := map[string]interface{}{\"block_size\": block_size}\n\tfor _, a := range optional {\n\t\ta(attrs)\n\t}\n\topspec := tf.OpSpec{\n\t\tType: \"SpaceToDepth\",\n\t\tInput: []tf.Input{\n\t\t\tinput,\n\t\t},\n\t\tAttrs: attrs,\n\t}\n\top := scope.AddOperation(opspec)\n\treturn op.Output(0)\n}", "func debugPrintWinSize() {\n\twindow := getWinSize()\n\tfmt.Printf(\"col: %v\\nrow: %v\\nx: %v\\ny: %v\\n\", window.col, window.row, window.unusedX, window.unusedY)\n}", "func coreRatioViewport(fbWidth int, fbHeight int) (x, y, w, h float32) {\n\t// Scale the content to fit in the viewport.\n\tfbw := float32(fbWidth)\n\tfbh := float32(fbHeight)\n\n\t// NXEngine workaround\n\taspectRatio := float32(Geom.AspectRatio)\n\tif aspectRatio == 0 {\n\t\taspectRatio = float32(Geom.BaseWidth) / float32(Geom.BaseHeight)\n\t}\n\n\th = fbh\n\tw = fbh * aspectRatio\n\tif w > fbw {\n\t\th = fbw / aspectRatio\n\t\tw = fbw\n\t}\n\n\t// Place the content in the middle of the window.\n\tx = (fbw - w) / 2\n\ty = (fbh - h) / 2\n\n\tva := vertexArray(x, y, w, h, 1.0)\n\tgl.BindBuffer(gl.ARRAY_BUFFER, vbo)\n\tgl.BufferData(gl.ARRAY_BUFFER, len(va)*4, gl.Ptr(va), gl.STATIC_DRAW)\n\n\treturn\n}", "func ClearDepthf(d float32) {\n\tsyscall.Syscall(gpClearDepthf, 1, uintptr(math.Float32bits(d)), 0, 0)\n}", "func (p *Projection) project(wx float64, wy float64) (float64, float64) {\n return ((wx / p.worldWidth) * p.canvasWidth) + (p.canvasWidth * 0.5),\n ((wy / p.worldHeight) * -p.canvasHeight) + (p.canvasHeight * 0.5)\n}", "func VEventfDepth(ctx context.Context, depth int, level int32, format string, args ...interface{}) {\n\tvEventf(ctx, false /* isErr */, 1+depth, level, format, args...)\n}", "func createCfgs() []pixelgl.WindowConfig {\n\tret := []pixelgl.WindowConfig{}\n\tfor _, m := range pixelgl.Monitors() {\n\t\tmX, mY := m.Size()\n\t\tret = append(ret, pixelgl.WindowConfig{\n\t\t\tBounds: pixel.R(0, 0, mX, mY),\n\t\t\tVSync: true,\n\t\t\tMonitor: m,\n\t\t})\n\t}\n\n\treturn ret\n}", "func (l Layout) DebugRender(win *pixelgl.Window) {\n\tfor key := range l.Panels {\n\t\tpanel := l.CreatePanel(key)\n\t\tpanel.Draw(win)\n\t}\n\n\t//temp camera matrix\n\t//cam := pixel.IM.Scaled(l.centerPos, 1.0).Moved(l.centerPos)\n\t//win.SetMatrix(cam)\n}", "func (sm *StackedMap) Depth() int {\n\treturn len(sm.mapStack)\n}", "func (c *Context) DepthMask(m bool) gfx.ContextStateValue {\n\treturn s.CSV{\n\t\tValue: m,\n\t\tDefaultValue: true, // TODO(slimsag): verify\n\t\tKey: csDepthMask,\n\t\tGLCall: c.glDepthMask,\n\t}\n}", "func (ac *Activity) SurfaceBounds(ctx context.Context) (Rect, error) {\n\tcmd := ac.a.Command(ctx, \"dumpsys\", \"window\", \"windows\")\n\toutput, err := cmd.Output()\n\tif err != nil {\n\t\treturn Rect{}, errors.Wrap(err, \"failed to launch dumpsys\")\n\t}\n\n\t// Looking for:\n\t// Window #0 Window{a486f07 u0 com.android.settings/com.android.settings.Settings}:\n\t// mDisplayId=0 stackId=2 mSession=Session{dd34b88 2586:1000} mClient=android.os.BinderProxy@705e146\n\t// mHasSurface=true isReadyForDisplay()=true mWindowRemovalAllowed=false\n\t// [...many other properties...]\n\t// mFrame=[0,0][1536,1936] last=[0,0][1536,1936]\n\t// We are interested in \"mFrame=\"\n\tregStr := `(?m)` + // Enable multiline.\n\t\t`^\\s*Window #\\d+ Window{\\S+ \\S+ ` + regexp.QuoteMeta(ac.pkgName+\"/\"+ac.pkgName+ac.activityName) + `}:$` + // Match our activity\n\t\t`(?:\\n.*?)*` + // Skip entire lines with a non-greedy search...\n\t\t`^\\s*mFrame=\\[(\\d+),(\\d+)\\]\\[(\\d+),(\\d+)\\]` // ...until we match the first mFrame=\n\tre := regexp.MustCompile(regStr)\n\tgroups := re.FindStringSubmatch(string(output))\n\tif len(groups) != 5 {\n\t\ttesting.ContextLog(ctx, string(output))\n\t\treturn Rect{}, errors.New(\"failed to parse dumpsys output; activity not running perhaps?\")\n\t}\n\tbounds, err := parseBounds(groups[1:5])\n\tif err != nil {\n\t\treturn Rect{}, err\n\t}\n\treturn bounds, nil\n}", "func (c *Camera) prepareWorldSpaceUnits() {\n\t// Compute the width of half of the canvas by taking the tangent of half of the field of view.\n\t// Cutting the field of view in half creates a right triangle on the canvas, which is 1 unit\n\t// away from the camera. The adjacent is 1 and the opposite is half of the canvas.\n\thalfView := math.Tan(c.fieldOfView / 2)\n\n\t// Compute the aspect ratio\n\tc.aspectRatio = float64(c.horizontalSizeInPixels) / float64(c.verticalSizeInPixels)\n\n\t// Compute half of the width and half of the height of the canvas.\n\t// This is different than the number of horizontal or vertical pixels.\n\tif c.aspectRatio >= 1 {\n\t\t// The horizontal size is greater than or equal to the vertical size\n\t\tc.halfWidth = halfView\n\t\tc.halfHeight = halfView / c.aspectRatio\n\t} else {\n\t\t// The vertical size is greater than the horizontal size\n\t\tc.halfWidth = halfView * c.aspectRatio\n\t\tc.halfHeight = halfView\n\t}\n\n\t// Divide half of the width * 2 by the number of horizontal pixels to get\n\t// the pixel size. Note that the assumption here is that the pixels are\n\t// square, so there is no need to compute the vertical size of the pixel.\n\tc.pixelSize = (c.halfWidth * 2) / float64(c.horizontalSizeInPixels)\n}", "func DepthToSpaceDataFormat(value string) DepthToSpaceAttr {\n\treturn func(m optionalAttr) {\n\t\tm[\"data_format\"] = value\n\t}\n}", "func GetDepthMode(mode_num int) FrameMode {\n\tfm := C.freenect_get_depth_mode(C.int(mode_num))\n\treturn *(*FrameMode)(unsafe.Pointer(&fm))\n}", "func trickleDepthInfo(node *h.FSNodeOverDag, maxlinks int) (depth int, repeatNumber int) {\n\tn := node.NumChildren()\n\n\tif n < maxlinks {\n\t\t// We didn't even added the initial `maxlinks` leaf nodes (`FillNodeLayer`).\n\t\treturn 0, 0\n\t}\n\n\tnonLeafChildren := n - maxlinks\n\t// The number of non-leaf child nodes added in `fillTrickleRec` (after\n\t// the `FillNodeLayer` call).\n\n\tdepth = nonLeafChildren/depthRepeat + 1\n\t// \"Deduplicate\" the added `depthRepeat` sub-graphs at each depth\n\t// (rounding it up since we may be on an unfinished depth with less\n\t// than `depthRepeat` sub-graphs).\n\n\trepeatNumber = nonLeafChildren % depthRepeat\n\t// What's left after taking full depths of `depthRepeat` sub-graphs\n\t// is the current `repeatNumber` we're at (this fractional part is\n\t// what we rounded up before).\n\n\treturn\n}", "func ClearDepth(depth float64) {\n\tsyscall.Syscall(gpClearDepth, 1, uintptr(math.Float64bits(depth)), 0, 0)\n}", "func SpaceToDepthDataFormat(value string) SpaceToDepthAttr {\n\treturn func(m optionalAttr) {\n\t\tm[\"data_format\"] = value\n\t}\n}", "func (c *Camera) Viewport() (x float32, y float32, width float32, height float32) {\n\tif c.x > 0 {\n\t\tx = float32(c.x) / float32(c.windowWidth)\n\t}\n\tif c.y > 0 {\n\t\ty = float32(c.y) / float32(c.worldHeight)\n\t}\n\n\tratio := math32.Min(\n\t\tfloat32(c.windowWidth)/float32(c.worldWidth),\n\t\tfloat32(c.windowHeight)/float32(c.worldHeight),\n\t)\n\twidth, height = c.relativeToWindowSize(ratio, ratio)\n\twidth /= float32(c.width) / float32(c.worldWidth)\n\theight /= float32(c.height) / float32(c.worldHeight)\n\treturn x, y, width, height\n}", "func Depth(index uint) (depth uint) {\n\tindex++\n\tfor (index & 1) == 0 {\n\t\tdepth++\n\t\tindex = rightShift(index)\n\t}\n\treturn\n}", "func PolygonOffset(factor float32, units float32) {\n C.glowPolygonOffset(gpPolygonOffset, (C.GLfloat)(factor), (C.GLfloat)(units))\n}", "func Depth(e expr.Expr) uint {\n\t//fmt.Printf(\"%f\\n\",e)\n\t// TODO: implement this function\n\tswitch i:= e.(type){\n\tcase expr.Var:\n\n\tcase expr.Literal:\n\n\tcase expr.Unary:\n\t\treturn Depth(i.X) + 1\n\t\tbreak\n\tcase expr.Binary: \n\t\treturn Max(Depth(i.X),Depth(i.Y)) + 1\n\t\tbreak\n\tdefault: \n\t\tpanic(\"unrecognized character\")\n\t}\n\treturn 1\n}", "func Uniform4fv(location int32, count int32, value *float32) {\n C.glowUniform4fv(gpUniform4fv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func MaxLodPixel(value int) *SimpleElement { return newSEInt(\"maxLodPixels\", value) }", "func createLevelMap(root *TreeNode, level int, levelMapper map[int][]int) {\n\tif root == nil {\n\t\treturn\n\t}\n\tif _, ok := levelMapper[level]; !ok {\n\t\tlevelMapper[level] = make([]int, 0)\n\t}\n\tlevelMapper[level] = append(levelMapper[level], root.Val)\n\tcreateLevelMap(root.Left, level+1, levelMapper)\n\tcreateLevelMap(root.Right, level+1, levelMapper)\n}", "func (c *Context) Viewport(x, y, width, height int) gfx.ContextStateValue {\n\treturn s.CSV{\n\t\tValue: [4]int{x, y, width, height},\n\t\tDefaultValue: [4]int{0, 0, 0, 0}, // TODO(slimsag): track real default viewport values\n\t\tKey: csViewport,\n\t\tGLCall: c.glViewport,\n\t}\n}", "func d16rectVolume(rect *d16rectT) float64 {\n\tvar volume float64 = 1\n\tfor index := 0; index < d16numDims; index++ {\n\t\tvolume *= rect.max[index] - rect.min[index]\n\t}\n\treturn volume\n}", "func InfolnDepth(depth int, args ...interface{}) {\n\tlogging.printlnDepth(severity.InfoLog, logging.logger, logging.filter, depth, args...)\n}", "func d2rectVolume(rect *d2rectT) float64 {\n\tvar volume float64 = 1\n\tfor index := 0; index < d2numDims; index++ {\n\t\tvolume *= rect.max[index] - rect.min[index]\n\t}\n\treturn volume\n}", "func normal2imageCoordinate(x, y int) (int, int) {\n\tx = x + maxX/3\n\ty = y + maxY/2\n\treturn x, y\n}", "func InfofDepth(depth int, format string, args ...interface{}) {\n\tlogging.printfDepth(severity.InfoLog, logging.logger, logging.filter, depth, format, args...)\n}", "func (o *Grid) boundaries() {\n\tn0 := o.npts[0]\n\tn1 := o.npts[1]\n\tif o.ndim == 2 {\n\t\to.edge = make([][]int, 4) // xmin,xmax,ymin,ymax\n\t\to.edge[0] = make([]int, n1) // xmin\n\t\to.edge[1] = make([]int, n1) // xmax\n\t\to.edge[2] = make([]int, n0) // ymin\n\t\to.edge[3] = make([]int, n0) // ymax\n\t\tfor n := 0; n < n1; n++ {\n\t\t\to.edge[0][n] = n * n0 // xmin\n\t\t\to.edge[1][n] = n*n0 + n0 - 1 // xmax\n\t\t}\n\t\tfor m := 0; m < n0; m++ {\n\t\t\to.edge[2][m] = m // ymin\n\t\t\to.edge[3][m] = m + n0*(n1-1) // ymax\n\t\t}\n\t\treturn\n\t}\n\tn2 := o.npts[2]\n\to.face = make([][]int, 6) // xmin,xmax,ymin,ymax,zmin,zmax\n\to.face[0] = make([]int, n1*n2) // xmin\n\to.face[1] = make([]int, n1*n2) // xmax\n\to.face[2] = make([]int, n0*n2) // ymin\n\to.face[3] = make([]int, n0*n2) // ymax\n\to.face[4] = make([]int, n0*n1) // zmin\n\to.face[5] = make([]int, n0*n1) // zmax\n\tt := 0\n\tfor p := 0; p < n2; p++ { // loop over z\n\t\tfor n := 0; n < n1; n++ { // loop over y\n\t\t\to.face[0][t] = n*n0 + (n0*n1)*p // xmin\n\t\t\to.face[1][t] = n*n0 + (n0*n1)*p + (n0 - 1) // xmax\n\t\t\tt++\n\t\t}\n\t}\n\tt = 0\n\tfor p := 0; p < n2; p++ { // loop over z\n\t\tfor m := 0; m < n0; m++ { // loop over x\n\t\t\to.face[2][t] = m + (n0*n1)*p // ymin\n\t\t\to.face[3][t] = m + (n0*n1)*p + n0*(n1-1) // ymax\n\t\t\tt++\n\t\t}\n\t}\n\tt = 0\n\tfor n := 0; n < n1; n++ { // loop over y\n\t\tfor m := 0; m < n0; m++ { // loop over x\n\t\t\to.face[4][t] = m + n0*n // zmin\n\t\t\to.face[5][t] = m + n0*n + (n0*n1)*(n2-1) // zmax\n\t\t\tt++\n\t\t}\n\t}\n}", "func LRNDepthRadius(value int64) LRNAttr {\n\treturn func(m optionalAttr) {\n\t\tm[\"depth_radius\"] = value\n\t}\n}", "func (s *ImageSpec) FullDepth() int {\n\tret := int(C.ImageSpec_full_depth(s.ptr))\n\truntime.KeepAlive(s)\n\treturn ret\n}", "func (device *Device) SetDepthCallback(callback DepthCallback) {\n\n\tif _, ok := devices[device.device]; !ok {\n\t\tdevices[device.device] = device\n\t}\n\n\tC.freenect_set_depth_callback(device.device, (*[0]byte)(C.depthCallback))\n\tdevice.depthCallback = callback\n}", "func EdgePosition(stage Stage) float32 {\n\tif stage == BATTLEFIELD {\n\t\treturn 71.3078536987\n\t}\n\tif stage == FINAL_DESTINATION {\n\t\treturn 88.4735488892\n\t}\n\tif stage == DREAMLAND {\n\t\treturn 80.1791534424\n\t}\n\tif stage == FOUNTAIN_OF_DREAMS {\n\t\treturn 66.2554016113\n\t}\n\tif stage == POKEMON_STADIUM {\n\t\treturn 90.657852\n\t}\n\tif stage == YOSHIS_STORY {\n\t\treturn 58.907848\n\t}\n\n\treturn 1000\n}", "func ProgramUniform2fv(program uint32, location int32, count int32, value *float32) {\n C.glowProgramUniform2fv(gpProgramUniform2fv, (C.GLuint)(program), (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func Frustum(left float64, right float64, bottom float64, top float64, zNear float64, zFar float64) {\n\tC.glowFrustum(gpFrustum, (C.GLdouble)(left), (C.GLdouble)(right), (C.GLdouble)(bottom), (C.GLdouble)(top), (C.GLdouble)(zNear), (C.GLdouble)(zFar))\n}", "func (s *CountMinSketch) Depth() uint {\n\treturn s.d\n}", "func setDepthAndEntryCount(ds *dataset.Dataset, data qfs.File, mu *sync.Mutex, done chan error) {\n\tdefer data.Close()\n\n\ter, err := dsio.NewEntryReader(ds.Structure, data)\n\tif err != nil {\n\t\tlog.Debug(err.Error())\n\t\tdone <- fmt.Errorf(\"error reading data values: %s\", err.Error())\n\t\treturn\n\t}\n\n\tentries := 0\n\t// baseline of 1 for the original closure\n\tdepth := 1\n\tvar ent dsio.Entry\n\tfor {\n\t\tif ent, err = er.ReadEntry(); err != nil {\n\t\t\tlog.Debug(err.Error())\n\t\t\tbreak\n\t\t}\n\t\t// get the depth of this entry, update depth if larger\n\t\tif d := getDepth(ent.Value, 1); d > depth {\n\t\t\tdepth = d\n\t\t}\n\t\tentries++\n\t}\n\tif err.Error() != \"EOF\" {\n\t\tdone <- fmt.Errorf(\"error reading values at entry %d: %s\", entries, err.Error())\n\t\treturn\n\t}\n\n\tmu.Lock()\n\tds.Structure.Entries = entries\n\tds.Structure.Depth = depth\n\tmu.Unlock()\n\n\tdone <- nil\n}", "func Uniform2fv(location int32, count int32, value *float32) {\n\tsyscall.Syscall(gpUniform2fv, 3, uintptr(location), uintptr(count), uintptr(unsafe.Pointer(value)))\n}", "func (buf *CommandBuffer) SetDepthBias(constantFactor, clamp, slopeFactor float32) {\n\tC.domVkCmdSetDepthBias(buf.fps[vkCmdSetDepthBias], buf.hnd, C.float(constantFactor), C.float(clamp), C.float(slopeFactor))\n}", "func DrawArraysIndirect(mode uint32, indirect unsafe.Pointer) {\n C.glowDrawArraysIndirect(gpDrawArraysIndirect, (C.GLenum)(mode), indirect)\n}", "func TestBoard_CalculateDepth(t *testing.T) {\n\ttype fields struct {\n\t\tGrid [3][3]int\n\t}\n\ttests := []struct {\n\t\tname string\n\t\tfields fields\n\t\twant int\n\t}{\n\t\t{name: \"Test-Empty-grid\", fields: fields{Grid: [3][3]int{\n\t\t\t{1, -1, -1}, {0, 1, -1}, {-1, 0, 1},\n\t\t}}, want: 4},\n\t}\n\tfor _, tt := range tests {\n\t\tt.Run(tt.name, func(t *testing.T) {\n\t\t\tboard := &Board{\n\t\t\t\tGrid: tt.fields.Grid,\n\t\t\t}\n\t\t\tif got := board.CalculateDepth(); got != tt.want {\n\t\t\t\tt.Errorf(\"CalculateDepth() = %v, want %v\", got, tt.want)\n\t\t\t}\n\t\t})\n\t}\n}", "func getLogDepth(ctx context.Context) int {\n\tif ctx == nil {\n\t\treturn 3\n\t}\n\tdepth := ctx.Value(\"log-depth\")\n\tif depth != nil {\n\t\tif ds, ok := depth.(int); ok {\n\t\t\treturn ds\n\t\t}\n\t}\n\treturn 3\n}" ]
[ "0.63479275", "0.6126459", "0.60384387", "0.5819864", "0.5720777", "0.5680924", "0.5680924", "0.5623218", "0.5455378", "0.5371378", "0.53534335", "0.53263485", "0.53045225", "0.53045225", "0.52953446", "0.52767897", "0.5201082", "0.519097", "0.51846325", "0.51829845", "0.5182738", "0.513141", "0.5127818", "0.5114293", "0.50771105", "0.5061849", "0.5039915", "0.5034891", "0.5034891", "0.49890772", "0.4958679", "0.49039817", "0.49028417", "0.4895552", "0.48391756", "0.48065633", "0.4781346", "0.47273082", "0.47207075", "0.47207075", "0.47160015", "0.46868482", "0.46572784", "0.4628797", "0.4627418", "0.46103406", "0.46005175", "0.45624498", "0.45601818", "0.4556335", "0.45544896", "0.45517418", "0.45380643", "0.45340535", "0.45297632", "0.45287973", "0.45073378", "0.4479098", "0.4459743", "0.4457766", "0.44561568", "0.44489527", "0.4422977", "0.44212037", "0.44208053", "0.4410461", "0.4391172", "0.43641093", "0.43615666", "0.43521717", "0.43448713", "0.4341462", "0.43382177", "0.43289596", "0.43222117", "0.43117696", "0.43074057", "0.43008557", "0.4292515", "0.42850658", "0.42805734", "0.42803797", "0.42657486", "0.42594996", "0.42499802", "0.42423952", "0.4240723", "0.42380452", "0.42341313", "0.42325488", "0.42316866", "0.42281973", "0.42269188", "0.42200404", "0.42174885", "0.42135522", "0.41995907", "0.4196745", "0.41928947" ]
0.54216486
10
Detaches a shader object from a program object to which it is attached
func DetachShader(program uint32, shader uint32) { C.glowDetachShader(gpDetachShader, (C.GLuint)(program), (C.GLuint)(shader)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func DetachShader(program uint32, shader uint32) {\n C.glowDetachShader(gpDetachShader, (C.GLuint)(program), (C.GLuint)(shader))\n}", "func DetachShader(program uint32, shader uint32) {\n\tsyscall.Syscall(gpDetachShader, 2, uintptr(program), uintptr(shader), 0)\n}", "func (program Program) DetachShader(shader Shader) {\n\tgl.DetachShader(uint32(program), uint32(shader))\n}", "func DetachShader(p Program, s Shader) {\n\tgl.DetachShader(p.Value, s.Value)\n}", "func DetachShader(program Uint, shader Uint) {\n\tcprogram, _ := (C.GLuint)(program), cgoAllocsUnknown\n\tcshader, _ := (C.GLuint)(shader), cgoAllocsUnknown\n\tC.glDetachShader(cprogram, cshader)\n}", "func DeleteShader(shader uint32) {\n C.glowDeleteShader(gpDeleteShader, (C.GLuint)(shader))\n}", "func ReleaseShaderCompiler() {\n C.glowReleaseShaderCompiler(gpReleaseShaderCompiler)\n}", "func (s *RShader) Unbind() {\n\tif s.disposed || !s.bound {\n\t\treturn\n\t}\n\n\ts.bound = false\n\n\thandle := history.Pop(gl.CURRENT_PROGRAM)\n\tgl.UseProgram(handle)\n}", "func (n *nativeShader) free() {\n\t// Delete shader objects (in practice we should be able to do this directly\n\t// after linking, but it would just leave the driver to reference count\n\t// them anyway).\n\tgl.DeleteShader(n.vertex)\n\tgl.DeleteShader(n.fragment)\n\n\t// Delete program.\n\tgl.DeleteProgram(n.program)\n\n\t// Zero-out the nativeShader structure, only keeping the rsrcManager around.\n\t*n = nativeShader{\n\t\tr: n.r,\n\t}\n}", "func finalizeShader(n *nativeShader) {\n\tn.r.Lock()\n\n\t// If the shader program is zero, it has already been free'd.\n\tif n.program == 0 {\n\t\tn.r.Unlock()\n\t\treturn\n\t}\n\tn.r.shaders = append(n.r.shaders, n)\n\tn.r.Unlock()\n}", "func (shader Shader) Delete() {\n\tgl.DeleteShader(uint32(shader))\n}", "func DeleteProgram(program uint32) {\n C.glowDeleteProgram(gpDeleteProgram, (C.GLuint)(program))\n}", "func ReleaseShaderCompiler() {\n\tsyscall.Syscall(gpReleaseShaderCompiler, 0, 0, 0, 0)\n}", "func DeleteShader(shader uint32) {\n\tsyscall.Syscall(gpDeleteShader, 1, uintptr(shader), 0, 0)\n}", "func (t Texture3D) Unbind() {\n\tgl.BindTexture(gl.TEXTURE_3D, 0)\n}", "func ReleaseShaderCompiler() {\n\tC.glowReleaseShaderCompiler(gpReleaseShaderCompiler)\n}", "func ReleaseShaderCompiler() {\n\tC.glowReleaseShaderCompiler(gpReleaseShaderCompiler)\n}", "func (s *Shader) Destroy() {\n\ts.destroyVertexShader()\n\ts.destroyFragmentShader()\n\tif s.programID != 0 {\n\t\tgl.DeleteProgram(s.programID)\n\t\ts.programID = 0\n\t}\n}", "func (r *gui3dRenderer) cleanUp() {\n\t\tr.shader.CleanUp()\n}", "func ReleaseShaderCompiler() {\n\tgl.ReleaseShaderCompiler()\n}", "func ReleaseShaderCompiler() {\n\tC.glReleaseShaderCompiler()\n}", "func DeleteShader(shader Uint) {\n\tcshader, _ := (C.GLuint)(shader), cgoAllocsUnknown\n\tC.glDeleteShader(cshader)\n}", "func (t Texture3D) Destroy() {\n\tgl.DeleteTextures(1, &t.id)\n}", "func (debugging *debuggingOpenGL) DeleteShader(shader uint32) {\n\tdebugging.recordEntry(\"DeleteShader\", shader)\n\tdebugging.gl.DeleteShader(shader)\n\tdebugging.recordExit(\"DeleteShader\")\n}", "func DeleteShader(shader uint32) {\n\tC.glowDeleteShader(gpDeleteShader, (C.GLuint)(shader))\n}", "func DeleteShader(shader uint32) {\n\tC.glowDeleteShader(gpDeleteShader, (C.GLuint)(shader))\n}", "func (native *OpenGL) DeleteShader(shader uint32) {\n\tgl.DeleteShader(shader)\n}", "func DeleteShader(s Shader) {\n\tgl.DeleteShader(s.Value)\n}", "func unlinkedprog(as int) *obj.Prog {\n\tp := Ctxt.NewProg()\n\tClearp(p)\n\tp.As = int16(as)\n\treturn p\n}", "func (rl *RayLine) Dispose() {\n\tgl := rl.window.OpenGL()\n\n\tgl.DeleteVertexArrays([]uint32{rl.glVAO})\n\tgl.DeleteProgram(rl.shaderProgram)\n}", "func (r *OutlineRenderer) cleanUp() {\n\tr.shader.CleanUp()\n}", "func (gl *WebGL) DeleteShader(shader WebGLShader) {\n\tgl.context.Call(\"deleteShader\", shader)\n}", "func (self *PhysicsP2) RemoveContactMaterial(material *PhysicsP2ContactMaterial) *PhysicsP2ContactMaterial{\n return &PhysicsP2ContactMaterial{self.Object.Call(\"removeContactMaterial\", material)}\n}", "func (gl *WebGL) UnbindTexture(target GLEnum) {\n\tgl.context.Call(\"bindTexture\", target, nil)\n}", "func AttachShader(program uint32, shader uint32) {\n C.glowAttachShader(gpAttachShader, (C.GLuint)(program), (C.GLuint)(shader))\n}", "func (coll *Collection) DetachProgram(name string) *Program {\n\tp := coll.Programs[name]\n\tdelete(coll.Programs, name)\n\treturn p\n}", "func (self *Graphics) Revive() *DisplayObject{\n return &DisplayObject{self.Object.Call(\"revive\")}\n}", "func (o *GstObj) Unref() {\n\tC.gst_object_unref(C.gpointer(o.GetPtr()))\n}", "func (renderbuffer Renderbuffer) Delete() {\n\t// TODO: Is it somehow possible to get &uint32(renderbuffer) without assigning it to renderbuffers?\n\trenderbuffers := uint32(renderbuffer)\n\tgl.DeleteRenderbuffers(1, &renderbuffers)\n}", "func (w *WebGLRenderTarget) Dispose() *WebGLRenderTarget {\n\tw.p.Call(\"dispose\")\n\treturn w\n}", "func (v *Object) Unref() {\n\tC.g_object_unref(C.gpointer(v.ptr))\n}", "func (s *Shader) End() {\n\ts.program.restore()\n}", "func (sh *ShaderStd) PostRender() error { return nil }", "func (recv *Object) Unref() {\n\tC.g_object_unref((C.gpointer)(recv.native))\n\n\treturn\n}", "func doDeleteMesh(componentMeshName string) {\n\tcr := visibleMeshes[componentMeshName]\n\tcr.Renderable.Destroy()\n\tcr.Renderable = nil\n\tdelete(visibleMeshes, componentMeshName)\n}", "func (program Program) Delete() {\n\tgl.DeleteProgram(uint32(program))\n}", "func ClearStencil(s int32) {\n C.glowClearStencil(gpClearStencil, (C.GLint)(s))\n}", "func (d *usbDevice) unreference() {\n\tC.libusb_unref_device(d.ptr())\n}", "func (b *GoGLBackendOffscreen) Delete() {\n\tgl.DeleteTextures(1, &b.offscrBuf.tex)\n\tgl.DeleteFramebuffers(1, &b.offscrBuf.frameBuf)\n\tgl.DeleteRenderbuffers(1, &b.offscrBuf.renderStencilBuf)\n}", "func RawDetachProgram(opts RawDetachProgramOptions) error {\n\tif err := haveProgAttach(); err != nil {\n\t\treturn err\n\t}\n\n\tattr := sys.ProgDetachAttr{\n\t\tTargetFd: uint32(opts.Target),\n\t\tAttachBpfFd: uint32(opts.Program.FD()),\n\t\tAttachType: uint32(opts.Attach),\n\t}\n\tif err := sys.ProgDetach(&attr); err != nil {\n\t\treturn fmt.Errorf(\"can't detach program: %w\", err)\n\t}\n\n\treturn nil\n}", "func AttachShader(program uint32, shader uint32) {\n\tsyscall.Syscall(gpAttachShader, 2, uintptr(program), uintptr(shader), 0)\n}", "func UnmapNamedBuffer(buffer uint32) bool {\n\tret := C.glowUnmapNamedBuffer(gpUnmapNamedBuffer, (C.GLuint)(buffer))\n\treturn ret == TRUE\n}", "func UnmapNamedBuffer(buffer uint32) bool {\n\tret := C.glowUnmapNamedBuffer(gpUnmapNamedBuffer, (C.GLuint)(buffer))\n\treturn ret == TRUE\n}", "func (self *Graphics) Destroy() {\n self.Object.Call(\"destroy\")\n}", "func (c *Context) BindShader(shader *ShaderProgram) {\n\tif c.currentShaderProgram == nil || shader.id != c.currentShaderProgram.id {\n\t\tgl.UseProgram(shader.id)\n\t\tc.currentShaderProgram = shader\n\t}\n}", "func (self *Graphics) Kill() *DisplayObject{\n return &DisplayObject{self.Object.Call(\"kill\")}\n}", "func (l *Level) DelObject(gameObject object.GameObject) {\n\tl.mainLayer.deletedIDs[gameObject] = struct{}{}\n}", "func UnmapBuffer(target uint32) bool {\n\tret := C.glowUnmapBuffer(gpUnmapBuffer, (C.GLenum)(target))\n\treturn ret == TRUE\n}", "func UnmapBuffer(target uint32) bool {\n\tret := C.glowUnmapBuffer(gpUnmapBuffer, (C.GLenum)(target))\n\treturn ret == TRUE\n}", "func (self *TileSprite) SetShaderA(member *AbstractFilter) {\n self.Object.Set(\"shader\", member)\n}", "func (w *windowImpl) DeActivate() {\n\tglfw.DetachCurrentContext()\n}", "func ActiveShaderProgram(pipeline uint32, program uint32) {\n C.glowActiveShaderProgram(gpActiveShaderProgram, (C.GLuint)(pipeline), (C.GLuint)(program))\n}", "func DisableVertexAttribArray(index uint32) {\n C.glowDisableVertexAttribArray(gpDisableVertexAttribArray, (C.GLuint)(index))\n}", "func AttachShader(p Program, s Shader) {\n\tgl.AttachShader(p.Value, s.Value)\n}", "func (program Program) AttachShader(shader Shader) {\n\tgl.AttachShader(uint32(program), uint32(shader))\n}", "func AttachShader(program Uint, shader Uint) {\n\tcprogram, _ := (C.GLuint)(program), cgoAllocsUnknown\n\tcshader, _ := (C.GLuint)(shader), cgoAllocsUnknown\n\tC.glAttachShader(cprogram, cshader)\n}", "func DeleteProgram(program Uint) {\n\tcprogram, _ := (C.GLuint)(program), cgoAllocsUnknown\n\tC.glDeleteProgram(cprogram)\n}", "func UnmapBuffer(target gl.Enum) bool {\n\treturn gl.GoBool(gl.UnmapBuffer(gl.Enum(target)))\n}", "func (native *OpenGL) DeleteProgram(program uint32) {\n\tgl.DeleteProgram(program)\n}", "func (self *PhysicsP2) SetOnContactMaterialRemovedA(member *Signal) {\n self.Object.Set(\"onContactMaterialRemoved\", member)\n}", "func ClearStencil(s int32) {\n\tsyscall.Syscall(gpClearStencil, 1, uintptr(s), 0, 0)\n}", "func WebGLRenderTargetFromJSObject(p *js.Object) *WebGLRenderTarget {\n\treturn &WebGLRenderTarget{p: p}\n}", "func ResumeTransformFeedback() {\n C.glowResumeTransformFeedback(gpResumeTransformFeedback)\n}", "func DeleteProgram(p Program) {\n\tgl.DeleteProgram(p.Value)\n}", "func (s *SceneUtils) Detach(child, parent, scene float64) *SceneUtils {\n\ts.p.Call(\"detach\", child, parent, scene)\n\treturn s\n}", "func runtime_procUnpin()", "func runtime_procUnpin()", "func (s *BasevhdlListener) ExitObject_declaration(ctx *Object_declarationContext) {}", "func (self *Graphics) RemoveChild(child *DisplayObject) *DisplayObject{\n return &DisplayObject{self.Object.Call(\"removeChild\", child)}\n}", "func DisableVertexAttribArray(index Uint) {\n\tcindex, _ := (C.GLuint)(index), cgoAllocsUnknown\n\tC.glDisableVertexAttribArray(cindex)\n}", "func DisableEffects() {\n\n\tgl.UseProgram(0)\n\tpaunchEffect = nil\n}", "func (debugging *debuggingOpenGL) DeleteProgram(program uint32) {\n\tdebugging.recordEntry(\"DeleteProgram\", program)\n\tdebugging.gl.DeleteProgram(program)\n\tdebugging.recordExit(\"DeleteProgram\")\n}", "func AttachShader(program uint32, shader uint32) {\n\tC.glowAttachShader(gpAttachShader, (C.GLuint)(program), (C.GLuint)(shader))\n}", "func AttachShader(program uint32, shader uint32) {\n\tC.glowAttachShader(gpAttachShader, (C.GLuint)(program), (C.GLuint)(shader))\n}", "func DeleteSync(sync unsafe.Pointer) {\n C.glowDeleteSync(gpDeleteSync, (C.GLsync)(sync))\n}", "func (g *Geometry) Free() {\n\tgl.DeleteVertexArrays(1, &g.handle)\n\tg.IndexBuffer.free()\n\tg.PositionBuffer.free()\n\tg.NormalBuffer.free()\n\tg.TexCoordBuffer.free()\n}", "func DisableVertexAttribArray(index uint32) {\n\tsyscall.Syscall(gpDisableVertexAttribArray, 1, uintptr(index), 0, 0)\n}", "func (decoder *Decoder) Destroy() {\n\tC.NvPipe_Destroy(decoder.dec)\n\tdecoder = nil\n}", "func DeleteProgram(program uint32) {\n\tC.glowDeleteProgram(gpDeleteProgram, (C.GLuint)(program))\n}", "func DeleteProgram(program uint32) {\n\tC.glowDeleteProgram(gpDeleteProgram, (C.GLuint)(program))\n}", "func DisableVertexAttribArray(index uint32) {\n\tgl.DisableVertexAttribArray(index)\n}", "func DisableVertexAttribArray(a Attrib) {\n\tgl.DisableVertexAttribArray(uint32(a.Value))\n}", "func ClearStencil(s int) {\n\tC.glClearStencil(C.GLint(s))\n}", "func (gl *WebGL) AttachShader(shaderProgram WebGLShaderProgram, shader WebGLShader) {\n\tgl.context.Call(\"attachShader\", shaderProgram, shader)\n}", "func (debugging *debuggingOpenGL) AttachShader(program uint32, shader uint32) {\n\tdebugging.recordEntry(\"AttachShader\", program, shader)\n\tdebugging.gl.AttachShader(program, shader)\n\tdebugging.recordExit(\"AttachShader\")\n}", "func (self *AbstractFilter) SyncUniforms() {\n self.Object.Call(\"syncUniforms\")\n}", "func (r *blockRenderer) Destroy() {}", "func ClearStencil(s int32) {\n\tC.glowClearStencil(gpClearStencil, (C.GLint)(s))\n}", "func ClearStencil(s int32) {\n\tC.glowClearStencil(gpClearStencil, (C.GLint)(s))\n}" ]
[ "0.73920846", "0.6926862", "0.6914519", "0.6886721", "0.683636", "0.61227334", "0.6024483", "0.5995838", "0.58677053", "0.5745318", "0.56832993", "0.5597706", "0.5588556", "0.5547058", "0.55224663", "0.55219084", "0.55219084", "0.5521438", "0.55098546", "0.5480847", "0.5450434", "0.5403582", "0.5380502", "0.5358671", "0.5346829", "0.5346829", "0.5337235", "0.5331888", "0.5286326", "0.52863014", "0.52726793", "0.52702147", "0.52611446", "0.5248495", "0.5226779", "0.52048963", "0.519553", "0.5142611", "0.5136056", "0.5126472", "0.5074284", "0.506354", "0.5047768", "0.5044568", "0.50314397", "0.50004035", "0.49918056", "0.49658814", "0.4959067", "0.49367198", "0.49251062", "0.49094656", "0.49094656", "0.48934767", "0.48875216", "0.48625854", "0.48594403", "0.48363513", "0.48363513", "0.4834962", "0.48338306", "0.48335913", "0.48288944", "0.4827535", "0.4824536", "0.48048338", "0.4799932", "0.4782617", "0.4771743", "0.47715497", "0.4768456", "0.47668305", "0.4752484", "0.47409016", "0.4740568", "0.473953", "0.473953", "0.4738768", "0.47349295", "0.47300792", "0.47275996", "0.47253218", "0.4718445", "0.4718445", "0.47170413", "0.47026896", "0.4695574", "0.4694591", "0.4683837", "0.4683837", "0.467782", "0.4675074", "0.4673745", "0.4662813", "0.4655899", "0.46543694", "0.46523145", "0.46457323", "0.46457323" ]
0.67955106
6
Enable or disable a generic vertex attribute array
func DisableVertexArrayAttrib(vaobj uint32, index uint32) { C.glowDisableVertexArrayAttrib(gpDisableVertexArrayAttrib, (C.GLuint)(vaobj), (C.GLuint)(index)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func EnableVertexArrayAttrib(vaobj uint32, index uint32) {\n\tsyscall.Syscall(gpEnableVertexArrayAttrib, 2, uintptr(vaobj), uintptr(index), 0)\n}", "func EnableVertexArrayAttrib(vaobj uint32, index uint32) {\n\tC.glowEnableVertexArrayAttrib(gpEnableVertexArrayAttrib, (C.GLuint)(vaobj), (C.GLuint)(index))\n}", "func EnableVertexArrayAttrib(vaobj uint32, index uint32) {\n\tC.glowEnableVertexArrayAttrib(gpEnableVertexArrayAttrib, (C.GLuint)(vaobj), (C.GLuint)(index))\n}", "func DisableVertexArrayAttrib(vaobj uint32, index uint32) {\n\tsyscall.Syscall(gpDisableVertexArrayAttrib, 2, uintptr(vaobj), uintptr(index), 0)\n}", "func EnableVertexAttribArray(index uint32) {\n C.glowEnableVertexAttribArray(gpEnableVertexAttribArray, (C.GLuint)(index))\n}", "func DisableVertexAttribArray(index uint32) {\n C.glowDisableVertexAttribArray(gpDisableVertexAttribArray, (C.GLuint)(index))\n}", "func (h *handlerImpl) disableVertex(adjMatrix adjacencyMatrix, vertex int) {\n\tfor to := range adjMatrix[vertex] {\n\t\tadjMatrix[vertex][to].disabled = true\n\t}\n}", "func EnableVertexAttribArray(index uint32) {\n\tsyscall.Syscall(gpEnableVertexAttribArray, 1, uintptr(index), 0, 0)\n}", "func VertexArrayAttribFormat(vaobj uint32, attribindex uint32, size int32, xtype uint32, normalized bool, relativeoffset uint32) {\n\tC.glowVertexArrayAttribFormat(gpVertexArrayAttribFormat, (C.GLuint)(vaobj), (C.GLuint)(attribindex), (C.GLint)(size), (C.GLenum)(xtype), (C.GLboolean)(boolToInt(normalized)), (C.GLuint)(relativeoffset))\n}", "func VertexArrayAttribFormat(vaobj uint32, attribindex uint32, size int32, xtype uint32, normalized bool, relativeoffset uint32) {\n\tC.glowVertexArrayAttribFormat(gpVertexArrayAttribFormat, (C.GLuint)(vaobj), (C.GLuint)(attribindex), (C.GLint)(size), (C.GLenum)(xtype), (C.GLboolean)(boolToInt(normalized)), (C.GLuint)(relativeoffset))\n}", "func DisableVertexAttribArray(index uint32) {\n\tsyscall.Syscall(gpDisableVertexAttribArray, 1, uintptr(index), 0, 0)\n}", "func VertexArrayAttribFormat(vaobj uint32, attribindex uint32, size int32, xtype uint32, normalized bool, relativeoffset uint32) {\n\tsyscall.Syscall6(gpVertexArrayAttribFormat, 6, uintptr(vaobj), uintptr(attribindex), uintptr(size), uintptr(xtype), boolToUintptr(normalized), uintptr(relativeoffset))\n}", "func EnableVertexAttribArray(index Uint) {\n\tcindex, _ := (C.GLuint)(index), cgoAllocsUnknown\n\tC.glEnableVertexAttribArray(cindex)\n}", "func EnableVertexAttribArray(index uint32) {\n\tC.glowEnableVertexAttribArray(gpEnableVertexAttribArray, (C.GLuint)(index))\n}", "func EnableVertexAttribArray(index uint32) {\n\tC.glowEnableVertexAttribArray(gpEnableVertexAttribArray, (C.GLuint)(index))\n}", "func EnableVertexAttribArray(a Attrib) {\n\tgl.EnableVertexAttribArray(uint32(a.Value))\n}", "func EnableVertexAttribArray(index uint32) {\n\tgl.EnableVertexAttribArray(index)\n}", "func DisableVertexAttribArray(index uint32) {\n\tC.glowDisableVertexAttribArray(gpDisableVertexAttribArray, (C.GLuint)(index))\n}", "func DisableVertexAttribArray(index uint32) {\n\tC.glowDisableVertexAttribArray(gpDisableVertexAttribArray, (C.GLuint)(index))\n}", "func DisableVertexAttribArray(a Attrib) {\n\tgl.DisableVertexAttribArray(uint32(a.Value))\n}", "func DisableVertexAttribArray(index uint32) {\n\tgl.DisableVertexAttribArray(index)\n}", "func (native *OpenGL) EnableVertexAttribArray(index uint32) {\n\tgl.EnableVertexAttribArray(index)\n}", "func (c *Context) EnableVertexAttribArray(l gfx.AttribLocation) gfx.ContextStateValue {\n\treturn s.CSV{\n\t\tValue: l,\n\t\tDefaultValue: 0, // TODO(slimsag): default enable VAA values!\n\t\tKey: csEnableVertexAttribArray,\n\t\tGLCall: c.glEnableVertexAttribArray,\n\t}\n}", "func PushAttrib(mask uint32) {\n C.glowPushAttrib(gpPushAttrib, (C.GLbitfield)(mask))\n}", "func DisableVertexAttribArray(index Uint) {\n\tcindex, _ := (C.GLuint)(index), cgoAllocsUnknown\n\tC.glDisableVertexAttribArray(cindex)\n}", "func VertexAttribFormat(attribindex uint32, size int32, xtype uint32, normalized bool, relativeoffset uint32) {\n C.glowVertexAttribFormat(gpVertexAttribFormat, (C.GLuint)(attribindex), (C.GLint)(size), (C.GLenum)(xtype), (C.GLboolean)(boolToInt(normalized)), (C.GLuint)(relativeoffset))\n}", "func EnableClientState(array uint32) {\n C.glowEnableClientState(gpEnableClientState, (C.GLenum)(array))\n}", "func (g *GLTF) loadAttributes(geom *geometry.Geometry, attributes map[string]int, indices math32.ArrayU32) error {\n\n\t// Indices of buffer views\n\tinterleavedVBOs := make(map[int]*gls.VBO, 0)\n\n\t// Load primitive attributes\n\tfor name, aci := range attributes {\n\t\taccessor := g.Accessors[aci]\n\n\t\t// Validate that accessor is compatible with attribute\n\t\terr := g.validateAccessorAttribute(accessor, name)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\n\t\t// Load data and add it to geometry's VBO\n\t\tif g.isInterleaved(accessor) {\n\t\t\tbvIdx := *accessor.BufferView\n\t\t\t// Check if we already loaded this buffer view\n\t\t\tvbo, ok := interleavedVBOs[bvIdx]\n\t\t\tif ok {\n\t\t\t\t// Already created VBO for this buffer view\n\t\t\t\t// Add attribute with correct byteOffset\n\t\t\t\tg.addAttributeToVBO(vbo, name, uint32(*accessor.ByteOffset))\n\t\t\t} else {\n\t\t\t\t// Load data and create vbo\n\t\t\t\tbuf, err := g.loadBufferView(bvIdx)\n\t\t\t\tif err != nil {\n\t\t\t\t\treturn err\n\t\t\t\t}\n\t\t\t\t//\n\t\t\t\t// TODO: BUG HERE\n\t\t\t\t// If buffer view has accessors with different component type then this will have a read alignment problem!\n\t\t\t\t//\n\t\t\t\tdata, err := g.bytesToArrayF32(buf, accessor.ComponentType, accessor.Count*TypeSizes[accessor.Type])\n\t\t\t\tif err != nil {\n\t\t\t\t\treturn err\n\t\t\t\t}\n\t\t\t\tvbo := gls.NewVBO(data)\n\t\t\t\tg.addAttributeToVBO(vbo, name, 0)\n\t\t\t\t// Save reference to VBO keyed by index of the buffer view\n\t\t\t\tinterleavedVBOs[bvIdx] = vbo\n\t\t\t\t// Add VBO to geometry\n\t\t\t\tgeom.AddVBO(vbo)\n\t\t\t}\n\t\t} else {\n\t\t\tbuf, err := g.loadAccessorBytes(accessor)\n\t\t\tif err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\t\t\tdata, err := g.bytesToArrayF32(buf, accessor.ComponentType, accessor.Count*TypeSizes[accessor.Type])\n\t\t\tif err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\t\t\tvbo := gls.NewVBO(data)\n\t\t\tg.addAttributeToVBO(vbo, name, 0)\n\t\t\t// Add VBO to geometry\n\t\t\tgeom.AddVBO(vbo)\n\t\t}\n\t}\n\n\t// Set indices\n\tif len(indices) > 0 {\n\t\tgeom.SetIndices(indices)\n\t}\n\n\treturn nil\n}", "func PushAttrib(mask uint32) {\n\tsyscall.Syscall(gpPushAttrib, 1, uintptr(mask), 0, 0)\n}", "func PushAttrib(mask uint32) {\n\tC.glowPushAttrib(gpPushAttrib, (C.GLbitfield)(mask))\n}", "func (self *Graphics) SetInputEnabledA(member bool) {\n self.Object.Set(\"inputEnabled\", member)\n}", "func PushClientAttrib(mask uint32) {\n C.glowPushClientAttrib(gpPushClientAttrib, (C.GLbitfield)(mask))\n}", "func (debugging *debuggingOpenGL) EnableVertexAttribArray(index uint32) {\n\tdebugging.recordEntry(\"EnableVertexAttribArray\", index)\n\tdebugging.gl.EnableVertexAttribArray(index)\n\tdebugging.recordExit(\"EnableVertexAttribArray\")\n}", "func VertexAttribFormat(attribindex uint32, size int32, xtype uint32, normalized bool, relativeoffset uint32) {\n\tsyscall.Syscall6(gpVertexAttribFormat, 5, uintptr(attribindex), uintptr(size), uintptr(xtype), boolToUintptr(normalized), uintptr(relativeoffset), 0)\n}", "func VertexAttribPointer(index uint32, size int32, xtype uint32, normalized bool, stride int32, pointer unsafe.Pointer) {\n C.glowVertexAttribPointer(gpVertexAttribPointer, (C.GLuint)(index), (C.GLint)(size), (C.GLenum)(xtype), (C.GLboolean)(boolToInt(normalized)), (C.GLsizei)(stride), pointer)\n}", "func PushClientAttrib(mask uint32) {\n\tC.glowPushClientAttrib(gpPushClientAttrib, (C.GLbitfield)(mask))\n}", "func VertexAttribFormat(attribindex uint32, size int32, xtype uint32, normalized bool, relativeoffset uint32) {\n\tC.glowVertexAttribFormat(gpVertexAttribFormat, (C.GLuint)(attribindex), (C.GLint)(size), (C.GLenum)(xtype), (C.GLboolean)(boolToInt(normalized)), (C.GLuint)(relativeoffset))\n}", "func VertexAttribFormat(attribindex uint32, size int32, xtype uint32, normalized bool, relativeoffset uint32) {\n\tC.glowVertexAttribFormat(gpVertexAttribFormat, (C.GLuint)(attribindex), (C.GLint)(size), (C.GLenum)(xtype), (C.GLboolean)(boolToInt(normalized)), (C.GLuint)(relativeoffset))\n}", "func (self *TileSprite) SetInputEnabledA(member bool) {\n self.Object.Set(\"inputEnabled\", member)\n}", "func (l *Loader) SetAttrSpecial(i Sym, v bool) {\n\tif v {\n\t\tl.attrSpecial[i] = struct{}{}\n\t} else {\n\t\tdelete(l.attrSpecial, i)\n\t}\n}", "func VertexAttribPointer(index uint32, size int32, xtype uint32, normalized bool, stride int32, pointer unsafe.Pointer) {\n\tsyscall.Syscall6(gpVertexAttribPointer, 6, uintptr(index), uintptr(size), uintptr(xtype), boolToUintptr(normalized), uintptr(stride), uintptr(pointer))\n}", "func BindVertexArray(array uint32) {\n C.glowBindVertexArray(gpBindVertexArray, (C.GLuint)(array))\n}", "func (l *Loader) SetAttrReadOnly(i Sym, v bool) {\n\tl.attrReadOnly[i] = v\n}", "func enableForceDestroyAttributes(state cty.Value) cty.Value {\n\tstateWithDestroyAttrs := map[string]cty.Value{}\n\n\tif state.CanIterateElements() {\n\t\tfor k, v := range state.AsValueMap() {\n\t\t\tif k == \"force_detach_policies\" || k == \"force_destroy\" {\n\t\t\t\tif v.Type().Equals(cty.Bool) {\n\t\t\t\t\tstateWithDestroyAttrs[k] = cty.True\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\tstateWithDestroyAttrs[k] = v\n\t\t\t}\n\t\t}\n\t}\n\n\treturn cty.ObjectVal(stateWithDestroyAttrs)\n}", "func Enable(cap GLenum) {\n\tC.glEnable(C.GLenum(cap))\n}", "func enableDisable(status, device int, name string) {\n\tvar request RpcRequest\n\n\tswitch status {\n\tcase 0:\n\t\trequest = RpcRequest{fmt.Sprintf(\"{\\\"command\\\":\\\"gpudisable\\\",\\\"parameter\\\":\\\"%v\\\"}\", device), make(chan []byte), name}\n\tcase 1:\n\t\trequest = RpcRequest{fmt.Sprintf(\"{\\\"command\\\":\\\"gpuenable\\\",\\\"parameter\\\":\\\"%v\\\"}\", device), make(chan []byte), name}\n\t}\n\n\trequest.Send()\n}", "func (va *VertexArray) SetLayout(layout VertexLayout) {\n\tif len(va.layout.layout) != 0 {\n\t\treturn\n\t}\n\n\tva.layout = layout\n\n\t// generate and bind the vertex array\n\tgl.GenVertexArrays(1, &va.vao) // generates the vertex array (or multiple)\n\tgl.BindVertexArray(va.vao) // binds the vertex array\n\n\t// make vertex array pointer attributes\n\t// offset is the offset in bytes to the first attribute\n\toffset := 0\n\n\t// calculate vertex stride\n\tstride := 0\n\tfor _, elem := range va.layout.layout {\n\t\tstride += elem.getByteSize()\n\n\t}\n\n\t// Vertex Buffer Object\n\tgl.GenBuffers(1, &va.vbo) // generates the buffer (or multiple)\n\tgl.BindBuffer(gl.ARRAY_BUFFER, va.vbo)\n\n\tfor i, elem := range va.layout.layout {\n\n\t\t// define an array of generic vertex attribute data\n\t\t// index, size, type, normalized, stride of vertex (in bytes), pointer (offset)\n\t\t// point positions\n\t\tgl.VertexAttribPointer(uint32(i), int32(elem.getSize()),\n\t\t\telem.getGLType(), false, int32(stride), gl.PtrOffset(offset))\n\t\tgl.EnableVertexAttribArray(uint32(i))\n\t\toffset += elem.getByteSize()\n\t}\n\n}", "func GetVertexAttribfv(index uint32, pname uint32, params *float32) {\n C.glowGetVertexAttribfv(gpGetVertexAttribfv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLfloat)(unsafe.Pointer(params)))\n}", "func PushClientAttrib(mask uint32) {\n\tsyscall.Syscall(gpPushClientAttrib, 1, uintptr(mask), 0, 0)\n}", "func (gl *WebGL) EnableVertexAttribArray(position WebGLAttributeLocation) {\n\tgl.context.Call(\"enableVertexAttribArray\", position)\n}", "func VertexAttribPointer(index uint32, size int32, xtype uint32, normalized bool, stride int32, pointer unsafe.Pointer) {\n\tC.glowVertexAttribPointer(gpVertexAttribPointer, (C.GLuint)(index), (C.GLint)(size), (C.GLenum)(xtype), (C.GLboolean)(boolToInt(normalized)), (C.GLsizei)(stride), pointer)\n}", "func VertexAttribPointer(index uint32, size int32, xtype uint32, normalized bool, stride int32, pointer unsafe.Pointer) {\n\tC.glowVertexAttribPointer(gpVertexAttribPointer, (C.GLuint)(index), (C.GLint)(size), (C.GLenum)(xtype), (C.GLboolean)(boolToInt(normalized)), (C.GLsizei)(stride), pointer)\n}", "func GetVertexAttribiv(index uint32, pname uint32, params *int32) {\n C.glowGetVertexAttribiv(gpGetVertexAttribiv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLint)(unsafe.Pointer(params)))\n}", "func VertexAttribBinding(attribindex uint32, bindingindex uint32) {\n\tsyscall.Syscall(gpVertexAttribBinding, 2, uintptr(attribindex), uintptr(bindingindex), 0)\n}", "func EnableClientState(array uint32) {\n\tsyscall.Syscall(gpEnableClientState, 1, uintptr(array), 0, 0)\n}", "func VertexAttribBinding(attribindex uint32, bindingindex uint32) {\n C.glowVertexAttribBinding(gpVertexAttribBinding, (C.GLuint)(attribindex), (C.GLuint)(bindingindex))\n}", "func (h *handlerImpl) disablePath(adjMatrix adjacencyMatrix, path []int) {\n\tfor _, vertex := range path {\n\t\th.disableVertex(adjMatrix, vertex)\n\t}\n}", "func (vao VertexArrayObject) VertexAttribPointer(attrIndex int, attrType Type, normalized bool, byteStride int, byteOffset int) {\n\tglx := vao.glx\n\tbufferType, bufferItemsPerVertex, err := attrType.asAttribute()\n\tif err != nil {\n\t\tpanic(fmt.Errorf(\"converting attribute type %s to attribute: %w\", attrType, err))\n\t}\n\tglx.constants.VertexAttribPointer(\n\t\tglx.factory.Number(float64(attrIndex)),\n\t\tglx.factory.Number(float64(bufferItemsPerVertex)),\n\t\tglx.typeConverter.ToJs(bufferType),\n\t\tglx.factory.Boolean(normalized),\n\t\tglx.factory.Number(float64(byteStride)),\n\t\tglx.factory.Number(float64(byteOffset)),\n\t)\n}", "func Disable(cap Enum) {\n\tgl.Disable(uint32(cap))\n}", "func VertexAttrib1fv(index uint32, value []float32) {\n\tgl.VertexAttrib1fv(index, &value[0])\n}", "func MultiDrawElementsBaseVertex(mode uint32, count *int32, xtype uint32, indices *unsafe.Pointer, drawcount int32, basevertex *int32) {\n\tsyscall.Syscall6(gpMultiDrawElementsBaseVertex, 6, uintptr(mode), uintptr(unsafe.Pointer(count)), uintptr(xtype), uintptr(unsafe.Pointer(indices)), uintptr(drawcount), uintptr(unsafe.Pointer(basevertex)))\n}", "func GetVertexAttribdv(index uint32, pname uint32, params *float64) {\n C.glowGetVertexAttribdv(gpGetVertexAttribdv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLdouble)(unsafe.Pointer(params)))\n}", "func Disable(cap GLenum) {\n\tC.glDisable(C.GLenum(cap))\n}", "func EnableClientState(array uint32) {\n\tC.glowEnableClientState(gpEnableClientState, (C.GLenum)(array))\n}", "func (o *object) SetAttr(i uint8, val bool) {\n\tmask := byte(1 << (7 - i%8))\n\tif val {\n\t\to.Attributes[i/8] |= mask\n\t} else {\n\t\to.Attributes[i/8] &^= mask\n\t}\n}", "func MultiDrawElementsBaseVertex(mode uint32, count *int32, xtype uint32, indices *unsafe.Pointer, drawcount int32, basevertex *int32) {\n C.glowMultiDrawElementsBaseVertex(gpMultiDrawElementsBaseVertex, (C.GLenum)(mode), (*C.GLsizei)(unsafe.Pointer(count)), (C.GLenum)(xtype), indices, (C.GLsizei)(drawcount), (*C.GLint)(unsafe.Pointer(basevertex)))\n}", "func GetVertexAttribLdv(index uint32, pname uint32, params *float64) {\n C.glowGetVertexAttribLdv(gpGetVertexAttribLdv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLdouble)(unsafe.Pointer(params)))\n}", "func GetVertexAttribIiv(index uint32, pname uint32, params *int32) {\n C.glowGetVertexAttribIiv(gpGetVertexAttribIiv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLint)(unsafe.Pointer(params)))\n}", "func GetVertexAttribfv(index uint32, pname uint32, params *float32) {\n\tC.glowGetVertexAttribfv(gpGetVertexAttribfv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLfloat)(unsafe.Pointer(params)))\n}", "func GetVertexAttribfv(index uint32, pname uint32, params *float32) {\n\tC.glowGetVertexAttribfv(gpGetVertexAttribfv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLfloat)(unsafe.Pointer(params)))\n}", "func Enable(cap Enum) {\n\tgl.Enable(uint32(cap))\n}", "func GetVertexAttribiv(index uint32, pname uint32, params *int32) {\n\tC.glowGetVertexAttribiv(gpGetVertexAttribiv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLint)(unsafe.Pointer(params)))\n}", "func GetVertexAttribiv(index uint32, pname uint32, params *int32) {\n\tC.glowGetVertexAttribiv(gpGetVertexAttribiv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLint)(unsafe.Pointer(params)))\n}", "func BindVertexArray(array uint32) {\n\tC.glowBindVertexArray(gpBindVertexArray, (C.GLuint)(array))\n}", "func BindVertexArray(array uint32) {\n\tC.glowBindVertexArray(gpBindVertexArray, (C.GLuint)(array))\n}", "func GetVertexAttribIuiv(index uint32, pname uint32, params *uint32) {\n C.glowGetVertexAttribIuiv(gpGetVertexAttribIuiv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLuint)(unsafe.Pointer(params)))\n}", "func (native *OpenGL) VertexAttribPointer(index uint32, size int32, xtype uint32, normalized bool, stride int32, pointer unsafe.Pointer) {\n\tgl.VertexAttribPointer(index, size, xtype, normalized, stride, pointer)\n}", "func GenVertexArrays(n int32, arrays *uint32) {\n\tsyscall.Syscall(gpGenVertexArrays, 2, uintptr(n), uintptr(unsafe.Pointer(arrays)), 0)\n}", "func BindVertexArray(array uint32) {\n\tsyscall.Syscall(gpBindVertexArray, 1, uintptr(array), 0, 0)\n}", "func Enable(cap Enum) {\n\tccap, _ := (C.GLenum)(cap), cgoAllocsUnknown\n\tC.glEnable(ccap)\n}", "func VertexArrayElementBuffer(vaobj uint32, buffer uint32) {\n\tsyscall.Syscall(gpVertexArrayElementBuffer, 2, uintptr(vaobj), uintptr(buffer), 0)\n}", "func (f Features) attrNormal() *spotify.TrackAttributes {\n\tx := spotify.NewTrackAttributes()\n\tx.TargetAcousticness(float64(f.Acousticness))\n\tx.TargetDanceability(float64(f.Danceability))\n\tx.TargetDuration(f.Duration)\n\tx.TargetEnergy(float64(f.Energy))\n\tx.TargetInstrumentalness(float64(f.Instrumentalness))\n\tx.TargetLiveness(float64(f.Liveness))\n\tx.TargetLoudness(float64(f.Loudness))\n\tx.TargetSpeechiness(float64(f.Speechiness))\n\tx.TargetValence(float64(f.Valence))\n\treturn x\n}", "func (graph *Graph) SetAttr(x, y int, attr byte) {\n\tgraph.Tiles[y][x].Attr = attr\n}", "func DrawElementsBaseVertex(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, basevertex int32) {\n C.glowDrawElementsBaseVertex(gpDrawElementsBaseVertex, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLint)(basevertex))\n}", "func (native *OpenGL) Disable(capability uint32) {\n\tgl.Disable(capability)\n}", "func enableWeights(tags []Tag) []Tag {\n\tvar dst []Tag\n\tfor _, v := range tags {\n\t\tdst = append(dst, Tag{v.Word, 1})\n\t\tfor i := 0; i < v.Weight-1; i++ {\n\t\t\tdst = append(dst, Tag{v.Word, 1})\n\t\t}\n\t}\n\treturn dst\n}", "func VertexAttrib4fv(index uint32, value []float32) {\n\tgl.VertexAttrib4fv(index, &value[0])\n}", "func (self *TileSprite) SetShaderA(member *AbstractFilter) {\n self.Object.Set(\"shader\", member)\n}", "func Disable(cap Enum) {\n\tccap, _ := (C.GLenum)(cap), cgoAllocsUnknown\n\tC.glDisable(ccap)\n}", "func ArrayElement(i int32) {\n C.glowArrayElement(gpArrayElement, (C.GLint)(i))\n}", "func GetVertexAttribfv(index uint32, pname uint32, params *float32) {\n\tsyscall.Syscall(gpGetVertexAttribfv, 3, uintptr(index), uintptr(pname), uintptr(unsafe.Pointer(params)))\n}", "func (self *TileSprite) SetSmoothedA(member bool) {\n self.Object.Set(\"smoothed\", member)\n}", "func (h *handlerImpl) reset(adjMatrix adjacencyMatrix) {\n\tfor from := range adjMatrix {\n\t\tfor to := range adjMatrix[from] {\n\t\t\tadjMatrix[from][to].disabled = false\n\t\t}\n\t}\n}", "func GetVertexAttribdv(index uint32, pname uint32, params *float64) {\n\tC.glowGetVertexAttribdv(gpGetVertexAttribdv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLdouble)(unsafe.Pointer(params)))\n}", "func GetVertexAttribdv(index uint32, pname uint32, params *float64) {\n\tC.glowGetVertexAttribdv(gpGetVertexAttribdv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLdouble)(unsafe.Pointer(params)))\n}", "func (gl *WebGL) VertexAttribPointer(position WebGLAttributeLocation, size int, valueType GLEnum, normalized bool, stride int, offset int) {\n\tgl.context.Call(\"vertexAttribPointer\", position, size, valueType, normalized, stride, offset)\n}", "func VertexAttribPointer(index Uint, size Int, kind Enum, normalized Boolean, stride Sizei, pointer unsafe.Pointer) {\n\tcindex, _ := (C.GLuint)(index), cgoAllocsUnknown\n\tcsize, _ := (C.GLint)(size), cgoAllocsUnknown\n\tckind, _ := (C.GLenum)(kind), cgoAllocsUnknown\n\tcnormalized, _ := (C.GLboolean)(normalized), cgoAllocsUnknown\n\tcstride, _ := (C.GLsizei)(stride), cgoAllocsUnknown\n\tcpointer, _ := (unsafe.Pointer)(unsafe.Pointer(pointer)), cgoAllocsUnknown\n\tC.glVertexAttribPointer(cindex, csize, ckind, cnormalized, cstride, cpointer)\n}", "func (g *GLTF) addAttributeToVBO(vbo *gls.VBO, attribName string, byteOffset uint32) {\n\n\taType, ok := AttributeName[attribName]\n\tif !ok {\n\t\tlog.Warn(fmt.Sprintf(\"Attribute %v is not supported!\", attribName))\n\t\treturn\n\t}\n\tvbo.AddAttribOffset(aType, byteOffset)\n}", "func (self *Graphics) SetBlendModeA(member int) {\n self.Object.Set(\"blendMode\", member)\n}" ]
[ "0.7054948", "0.6961601", "0.6961601", "0.6764844", "0.636292", "0.6271076", "0.6208801", "0.6129252", "0.6005506", "0.6005506", "0.5988115", "0.5971912", "0.59454656", "0.5923633", "0.5923633", "0.5883221", "0.5882651", "0.5731005", "0.5731005", "0.57178", "0.5663524", "0.55286276", "0.54168975", "0.540357", "0.5381989", "0.5375168", "0.5366694", "0.531393", "0.52830863", "0.5239043", "0.5236888", "0.52229863", "0.5209522", "0.51910627", "0.5187136", "0.509039", "0.5080936", "0.5080936", "0.5055571", "0.5012452", "0.50046974", "0.49871853", "0.49798167", "0.495335", "0.49424696", "0.49170312", "0.49140775", "0.49053478", "0.49050945", "0.4903048", "0.4880351", "0.4880351", "0.4873434", "0.48354915", "0.48326808", "0.47918648", "0.477644", "0.47372597", "0.47369194", "0.47284093", "0.47266468", "0.47156447", "0.47082728", "0.47053084", "0.47020197", "0.46978614", "0.46916646", "0.4687597", "0.46842915", "0.46842915", "0.46791106", "0.46508664", "0.46508664", "0.46364462", "0.46364462", "0.46099815", "0.46020722", "0.4595127", "0.45933384", "0.45929688", "0.45924065", "0.45769024", "0.45685786", "0.45660663", "0.4559609", "0.4554404", "0.45344874", "0.45280042", "0.45277026", "0.45062986", "0.45046997", "0.44953692", "0.4495043", "0.4494429", "0.4494429", "0.44901422", "0.44887704", "0.4486207", "0.44793424" ]
0.66976696
5
Enable or disable a generic vertex attribute array
func DisableVertexAttribArray(index uint32) { C.glowDisableVertexAttribArray(gpDisableVertexAttribArray, (C.GLuint)(index)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func EnableVertexArrayAttrib(vaobj uint32, index uint32) {\n\tsyscall.Syscall(gpEnableVertexArrayAttrib, 2, uintptr(vaobj), uintptr(index), 0)\n}", "func EnableVertexArrayAttrib(vaobj uint32, index uint32) {\n\tC.glowEnableVertexArrayAttrib(gpEnableVertexArrayAttrib, (C.GLuint)(vaobj), (C.GLuint)(index))\n}", "func EnableVertexArrayAttrib(vaobj uint32, index uint32) {\n\tC.glowEnableVertexArrayAttrib(gpEnableVertexArrayAttrib, (C.GLuint)(vaobj), (C.GLuint)(index))\n}", "func DisableVertexArrayAttrib(vaobj uint32, index uint32) {\n\tsyscall.Syscall(gpDisableVertexArrayAttrib, 2, uintptr(vaobj), uintptr(index), 0)\n}", "func DisableVertexArrayAttrib(vaobj uint32, index uint32) {\n\tC.glowDisableVertexArrayAttrib(gpDisableVertexArrayAttrib, (C.GLuint)(vaobj), (C.GLuint)(index))\n}", "func DisableVertexArrayAttrib(vaobj uint32, index uint32) {\n\tC.glowDisableVertexArrayAttrib(gpDisableVertexArrayAttrib, (C.GLuint)(vaobj), (C.GLuint)(index))\n}", "func EnableVertexAttribArray(index uint32) {\n C.glowEnableVertexAttribArray(gpEnableVertexAttribArray, (C.GLuint)(index))\n}", "func DisableVertexAttribArray(index uint32) {\n C.glowDisableVertexAttribArray(gpDisableVertexAttribArray, (C.GLuint)(index))\n}", "func (h *handlerImpl) disableVertex(adjMatrix adjacencyMatrix, vertex int) {\n\tfor to := range adjMatrix[vertex] {\n\t\tadjMatrix[vertex][to].disabled = true\n\t}\n}", "func EnableVertexAttribArray(index uint32) {\n\tsyscall.Syscall(gpEnableVertexAttribArray, 1, uintptr(index), 0, 0)\n}", "func VertexArrayAttribFormat(vaobj uint32, attribindex uint32, size int32, xtype uint32, normalized bool, relativeoffset uint32) {\n\tC.glowVertexArrayAttribFormat(gpVertexArrayAttribFormat, (C.GLuint)(vaobj), (C.GLuint)(attribindex), (C.GLint)(size), (C.GLenum)(xtype), (C.GLboolean)(boolToInt(normalized)), (C.GLuint)(relativeoffset))\n}", "func VertexArrayAttribFormat(vaobj uint32, attribindex uint32, size int32, xtype uint32, normalized bool, relativeoffset uint32) {\n\tC.glowVertexArrayAttribFormat(gpVertexArrayAttribFormat, (C.GLuint)(vaobj), (C.GLuint)(attribindex), (C.GLint)(size), (C.GLenum)(xtype), (C.GLboolean)(boolToInt(normalized)), (C.GLuint)(relativeoffset))\n}", "func DisableVertexAttribArray(index uint32) {\n\tsyscall.Syscall(gpDisableVertexAttribArray, 1, uintptr(index), 0, 0)\n}", "func VertexArrayAttribFormat(vaobj uint32, attribindex uint32, size int32, xtype uint32, normalized bool, relativeoffset uint32) {\n\tsyscall.Syscall6(gpVertexArrayAttribFormat, 6, uintptr(vaobj), uintptr(attribindex), uintptr(size), uintptr(xtype), boolToUintptr(normalized), uintptr(relativeoffset))\n}", "func EnableVertexAttribArray(index Uint) {\n\tcindex, _ := (C.GLuint)(index), cgoAllocsUnknown\n\tC.glEnableVertexAttribArray(cindex)\n}", "func EnableVertexAttribArray(index uint32) {\n\tC.glowEnableVertexAttribArray(gpEnableVertexAttribArray, (C.GLuint)(index))\n}", "func EnableVertexAttribArray(index uint32) {\n\tC.glowEnableVertexAttribArray(gpEnableVertexAttribArray, (C.GLuint)(index))\n}", "func EnableVertexAttribArray(a Attrib) {\n\tgl.EnableVertexAttribArray(uint32(a.Value))\n}", "func EnableVertexAttribArray(index uint32) {\n\tgl.EnableVertexAttribArray(index)\n}", "func DisableVertexAttribArray(a Attrib) {\n\tgl.DisableVertexAttribArray(uint32(a.Value))\n}", "func DisableVertexAttribArray(index uint32) {\n\tgl.DisableVertexAttribArray(index)\n}", "func (native *OpenGL) EnableVertexAttribArray(index uint32) {\n\tgl.EnableVertexAttribArray(index)\n}", "func (c *Context) EnableVertexAttribArray(l gfx.AttribLocation) gfx.ContextStateValue {\n\treturn s.CSV{\n\t\tValue: l,\n\t\tDefaultValue: 0, // TODO(slimsag): default enable VAA values!\n\t\tKey: csEnableVertexAttribArray,\n\t\tGLCall: c.glEnableVertexAttribArray,\n\t}\n}", "func PushAttrib(mask uint32) {\n C.glowPushAttrib(gpPushAttrib, (C.GLbitfield)(mask))\n}", "func DisableVertexAttribArray(index Uint) {\n\tcindex, _ := (C.GLuint)(index), cgoAllocsUnknown\n\tC.glDisableVertexAttribArray(cindex)\n}", "func VertexAttribFormat(attribindex uint32, size int32, xtype uint32, normalized bool, relativeoffset uint32) {\n C.glowVertexAttribFormat(gpVertexAttribFormat, (C.GLuint)(attribindex), (C.GLint)(size), (C.GLenum)(xtype), (C.GLboolean)(boolToInt(normalized)), (C.GLuint)(relativeoffset))\n}", "func EnableClientState(array uint32) {\n C.glowEnableClientState(gpEnableClientState, (C.GLenum)(array))\n}", "func (g *GLTF) loadAttributes(geom *geometry.Geometry, attributes map[string]int, indices math32.ArrayU32) error {\n\n\t// Indices of buffer views\n\tinterleavedVBOs := make(map[int]*gls.VBO, 0)\n\n\t// Load primitive attributes\n\tfor name, aci := range attributes {\n\t\taccessor := g.Accessors[aci]\n\n\t\t// Validate that accessor is compatible with attribute\n\t\terr := g.validateAccessorAttribute(accessor, name)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\n\t\t// Load data and add it to geometry's VBO\n\t\tif g.isInterleaved(accessor) {\n\t\t\tbvIdx := *accessor.BufferView\n\t\t\t// Check if we already loaded this buffer view\n\t\t\tvbo, ok := interleavedVBOs[bvIdx]\n\t\t\tif ok {\n\t\t\t\t// Already created VBO for this buffer view\n\t\t\t\t// Add attribute with correct byteOffset\n\t\t\t\tg.addAttributeToVBO(vbo, name, uint32(*accessor.ByteOffset))\n\t\t\t} else {\n\t\t\t\t// Load data and create vbo\n\t\t\t\tbuf, err := g.loadBufferView(bvIdx)\n\t\t\t\tif err != nil {\n\t\t\t\t\treturn err\n\t\t\t\t}\n\t\t\t\t//\n\t\t\t\t// TODO: BUG HERE\n\t\t\t\t// If buffer view has accessors with different component type then this will have a read alignment problem!\n\t\t\t\t//\n\t\t\t\tdata, err := g.bytesToArrayF32(buf, accessor.ComponentType, accessor.Count*TypeSizes[accessor.Type])\n\t\t\t\tif err != nil {\n\t\t\t\t\treturn err\n\t\t\t\t}\n\t\t\t\tvbo := gls.NewVBO(data)\n\t\t\t\tg.addAttributeToVBO(vbo, name, 0)\n\t\t\t\t// Save reference to VBO keyed by index of the buffer view\n\t\t\t\tinterleavedVBOs[bvIdx] = vbo\n\t\t\t\t// Add VBO to geometry\n\t\t\t\tgeom.AddVBO(vbo)\n\t\t\t}\n\t\t} else {\n\t\t\tbuf, err := g.loadAccessorBytes(accessor)\n\t\t\tif err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\t\t\tdata, err := g.bytesToArrayF32(buf, accessor.ComponentType, accessor.Count*TypeSizes[accessor.Type])\n\t\t\tif err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\t\t\tvbo := gls.NewVBO(data)\n\t\t\tg.addAttributeToVBO(vbo, name, 0)\n\t\t\t// Add VBO to geometry\n\t\t\tgeom.AddVBO(vbo)\n\t\t}\n\t}\n\n\t// Set indices\n\tif len(indices) > 0 {\n\t\tgeom.SetIndices(indices)\n\t}\n\n\treturn nil\n}", "func PushAttrib(mask uint32) {\n\tsyscall.Syscall(gpPushAttrib, 1, uintptr(mask), 0, 0)\n}", "func PushAttrib(mask uint32) {\n\tC.glowPushAttrib(gpPushAttrib, (C.GLbitfield)(mask))\n}", "func (self *Graphics) SetInputEnabledA(member bool) {\n self.Object.Set(\"inputEnabled\", member)\n}", "func PushClientAttrib(mask uint32) {\n C.glowPushClientAttrib(gpPushClientAttrib, (C.GLbitfield)(mask))\n}", "func (debugging *debuggingOpenGL) EnableVertexAttribArray(index uint32) {\n\tdebugging.recordEntry(\"EnableVertexAttribArray\", index)\n\tdebugging.gl.EnableVertexAttribArray(index)\n\tdebugging.recordExit(\"EnableVertexAttribArray\")\n}", "func VertexAttribFormat(attribindex uint32, size int32, xtype uint32, normalized bool, relativeoffset uint32) {\n\tsyscall.Syscall6(gpVertexAttribFormat, 5, uintptr(attribindex), uintptr(size), uintptr(xtype), boolToUintptr(normalized), uintptr(relativeoffset), 0)\n}", "func VertexAttribPointer(index uint32, size int32, xtype uint32, normalized bool, stride int32, pointer unsafe.Pointer) {\n C.glowVertexAttribPointer(gpVertexAttribPointer, (C.GLuint)(index), (C.GLint)(size), (C.GLenum)(xtype), (C.GLboolean)(boolToInt(normalized)), (C.GLsizei)(stride), pointer)\n}", "func PushClientAttrib(mask uint32) {\n\tC.glowPushClientAttrib(gpPushClientAttrib, (C.GLbitfield)(mask))\n}", "func VertexAttribFormat(attribindex uint32, size int32, xtype uint32, normalized bool, relativeoffset uint32) {\n\tC.glowVertexAttribFormat(gpVertexAttribFormat, (C.GLuint)(attribindex), (C.GLint)(size), (C.GLenum)(xtype), (C.GLboolean)(boolToInt(normalized)), (C.GLuint)(relativeoffset))\n}", "func VertexAttribFormat(attribindex uint32, size int32, xtype uint32, normalized bool, relativeoffset uint32) {\n\tC.glowVertexAttribFormat(gpVertexAttribFormat, (C.GLuint)(attribindex), (C.GLint)(size), (C.GLenum)(xtype), (C.GLboolean)(boolToInt(normalized)), (C.GLuint)(relativeoffset))\n}", "func (self *TileSprite) SetInputEnabledA(member bool) {\n self.Object.Set(\"inputEnabled\", member)\n}", "func (l *Loader) SetAttrSpecial(i Sym, v bool) {\n\tif v {\n\t\tl.attrSpecial[i] = struct{}{}\n\t} else {\n\t\tdelete(l.attrSpecial, i)\n\t}\n}", "func VertexAttribPointer(index uint32, size int32, xtype uint32, normalized bool, stride int32, pointer unsafe.Pointer) {\n\tsyscall.Syscall6(gpVertexAttribPointer, 6, uintptr(index), uintptr(size), uintptr(xtype), boolToUintptr(normalized), uintptr(stride), uintptr(pointer))\n}", "func BindVertexArray(array uint32) {\n C.glowBindVertexArray(gpBindVertexArray, (C.GLuint)(array))\n}", "func (l *Loader) SetAttrReadOnly(i Sym, v bool) {\n\tl.attrReadOnly[i] = v\n}", "func enableForceDestroyAttributes(state cty.Value) cty.Value {\n\tstateWithDestroyAttrs := map[string]cty.Value{}\n\n\tif state.CanIterateElements() {\n\t\tfor k, v := range state.AsValueMap() {\n\t\t\tif k == \"force_detach_policies\" || k == \"force_destroy\" {\n\t\t\t\tif v.Type().Equals(cty.Bool) {\n\t\t\t\t\tstateWithDestroyAttrs[k] = cty.True\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\tstateWithDestroyAttrs[k] = v\n\t\t\t}\n\t\t}\n\t}\n\n\treturn cty.ObjectVal(stateWithDestroyAttrs)\n}", "func Enable(cap GLenum) {\n\tC.glEnable(C.GLenum(cap))\n}", "func enableDisable(status, device int, name string) {\n\tvar request RpcRequest\n\n\tswitch status {\n\tcase 0:\n\t\trequest = RpcRequest{fmt.Sprintf(\"{\\\"command\\\":\\\"gpudisable\\\",\\\"parameter\\\":\\\"%v\\\"}\", device), make(chan []byte), name}\n\tcase 1:\n\t\trequest = RpcRequest{fmt.Sprintf(\"{\\\"command\\\":\\\"gpuenable\\\",\\\"parameter\\\":\\\"%v\\\"}\", device), make(chan []byte), name}\n\t}\n\n\trequest.Send()\n}", "func (va *VertexArray) SetLayout(layout VertexLayout) {\n\tif len(va.layout.layout) != 0 {\n\t\treturn\n\t}\n\n\tva.layout = layout\n\n\t// generate and bind the vertex array\n\tgl.GenVertexArrays(1, &va.vao) // generates the vertex array (or multiple)\n\tgl.BindVertexArray(va.vao) // binds the vertex array\n\n\t// make vertex array pointer attributes\n\t// offset is the offset in bytes to the first attribute\n\toffset := 0\n\n\t// calculate vertex stride\n\tstride := 0\n\tfor _, elem := range va.layout.layout {\n\t\tstride += elem.getByteSize()\n\n\t}\n\n\t// Vertex Buffer Object\n\tgl.GenBuffers(1, &va.vbo) // generates the buffer (or multiple)\n\tgl.BindBuffer(gl.ARRAY_BUFFER, va.vbo)\n\n\tfor i, elem := range va.layout.layout {\n\n\t\t// define an array of generic vertex attribute data\n\t\t// index, size, type, normalized, stride of vertex (in bytes), pointer (offset)\n\t\t// point positions\n\t\tgl.VertexAttribPointer(uint32(i), int32(elem.getSize()),\n\t\t\telem.getGLType(), false, int32(stride), gl.PtrOffset(offset))\n\t\tgl.EnableVertexAttribArray(uint32(i))\n\t\toffset += elem.getByteSize()\n\t}\n\n}", "func GetVertexAttribfv(index uint32, pname uint32, params *float32) {\n C.glowGetVertexAttribfv(gpGetVertexAttribfv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLfloat)(unsafe.Pointer(params)))\n}", "func PushClientAttrib(mask uint32) {\n\tsyscall.Syscall(gpPushClientAttrib, 1, uintptr(mask), 0, 0)\n}", "func (gl *WebGL) EnableVertexAttribArray(position WebGLAttributeLocation) {\n\tgl.context.Call(\"enableVertexAttribArray\", position)\n}", "func VertexAttribPointer(index uint32, size int32, xtype uint32, normalized bool, stride int32, pointer unsafe.Pointer) {\n\tC.glowVertexAttribPointer(gpVertexAttribPointer, (C.GLuint)(index), (C.GLint)(size), (C.GLenum)(xtype), (C.GLboolean)(boolToInt(normalized)), (C.GLsizei)(stride), pointer)\n}", "func VertexAttribPointer(index uint32, size int32, xtype uint32, normalized bool, stride int32, pointer unsafe.Pointer) {\n\tC.glowVertexAttribPointer(gpVertexAttribPointer, (C.GLuint)(index), (C.GLint)(size), (C.GLenum)(xtype), (C.GLboolean)(boolToInt(normalized)), (C.GLsizei)(stride), pointer)\n}", "func GetVertexAttribiv(index uint32, pname uint32, params *int32) {\n C.glowGetVertexAttribiv(gpGetVertexAttribiv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLint)(unsafe.Pointer(params)))\n}", "func VertexAttribBinding(attribindex uint32, bindingindex uint32) {\n\tsyscall.Syscall(gpVertexAttribBinding, 2, uintptr(attribindex), uintptr(bindingindex), 0)\n}", "func EnableClientState(array uint32) {\n\tsyscall.Syscall(gpEnableClientState, 1, uintptr(array), 0, 0)\n}", "func VertexAttribBinding(attribindex uint32, bindingindex uint32) {\n C.glowVertexAttribBinding(gpVertexAttribBinding, (C.GLuint)(attribindex), (C.GLuint)(bindingindex))\n}", "func (h *handlerImpl) disablePath(adjMatrix adjacencyMatrix, path []int) {\n\tfor _, vertex := range path {\n\t\th.disableVertex(adjMatrix, vertex)\n\t}\n}", "func (vao VertexArrayObject) VertexAttribPointer(attrIndex int, attrType Type, normalized bool, byteStride int, byteOffset int) {\n\tglx := vao.glx\n\tbufferType, bufferItemsPerVertex, err := attrType.asAttribute()\n\tif err != nil {\n\t\tpanic(fmt.Errorf(\"converting attribute type %s to attribute: %w\", attrType, err))\n\t}\n\tglx.constants.VertexAttribPointer(\n\t\tglx.factory.Number(float64(attrIndex)),\n\t\tglx.factory.Number(float64(bufferItemsPerVertex)),\n\t\tglx.typeConverter.ToJs(bufferType),\n\t\tglx.factory.Boolean(normalized),\n\t\tglx.factory.Number(float64(byteStride)),\n\t\tglx.factory.Number(float64(byteOffset)),\n\t)\n}", "func Disable(cap Enum) {\n\tgl.Disable(uint32(cap))\n}", "func VertexAttrib1fv(index uint32, value []float32) {\n\tgl.VertexAttrib1fv(index, &value[0])\n}", "func MultiDrawElementsBaseVertex(mode uint32, count *int32, xtype uint32, indices *unsafe.Pointer, drawcount int32, basevertex *int32) {\n\tsyscall.Syscall6(gpMultiDrawElementsBaseVertex, 6, uintptr(mode), uintptr(unsafe.Pointer(count)), uintptr(xtype), uintptr(unsafe.Pointer(indices)), uintptr(drawcount), uintptr(unsafe.Pointer(basevertex)))\n}", "func GetVertexAttribdv(index uint32, pname uint32, params *float64) {\n C.glowGetVertexAttribdv(gpGetVertexAttribdv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLdouble)(unsafe.Pointer(params)))\n}", "func Disable(cap GLenum) {\n\tC.glDisable(C.GLenum(cap))\n}", "func EnableClientState(array uint32) {\n\tC.glowEnableClientState(gpEnableClientState, (C.GLenum)(array))\n}", "func (o *object) SetAttr(i uint8, val bool) {\n\tmask := byte(1 << (7 - i%8))\n\tif val {\n\t\to.Attributes[i/8] |= mask\n\t} else {\n\t\to.Attributes[i/8] &^= mask\n\t}\n}", "func MultiDrawElementsBaseVertex(mode uint32, count *int32, xtype uint32, indices *unsafe.Pointer, drawcount int32, basevertex *int32) {\n C.glowMultiDrawElementsBaseVertex(gpMultiDrawElementsBaseVertex, (C.GLenum)(mode), (*C.GLsizei)(unsafe.Pointer(count)), (C.GLenum)(xtype), indices, (C.GLsizei)(drawcount), (*C.GLint)(unsafe.Pointer(basevertex)))\n}", "func GetVertexAttribLdv(index uint32, pname uint32, params *float64) {\n C.glowGetVertexAttribLdv(gpGetVertexAttribLdv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLdouble)(unsafe.Pointer(params)))\n}", "func GetVertexAttribIiv(index uint32, pname uint32, params *int32) {\n C.glowGetVertexAttribIiv(gpGetVertexAttribIiv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLint)(unsafe.Pointer(params)))\n}", "func GetVertexAttribfv(index uint32, pname uint32, params *float32) {\n\tC.glowGetVertexAttribfv(gpGetVertexAttribfv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLfloat)(unsafe.Pointer(params)))\n}", "func GetVertexAttribfv(index uint32, pname uint32, params *float32) {\n\tC.glowGetVertexAttribfv(gpGetVertexAttribfv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLfloat)(unsafe.Pointer(params)))\n}", "func Enable(cap Enum) {\n\tgl.Enable(uint32(cap))\n}", "func GetVertexAttribiv(index uint32, pname uint32, params *int32) {\n\tC.glowGetVertexAttribiv(gpGetVertexAttribiv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLint)(unsafe.Pointer(params)))\n}", "func GetVertexAttribiv(index uint32, pname uint32, params *int32) {\n\tC.glowGetVertexAttribiv(gpGetVertexAttribiv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLint)(unsafe.Pointer(params)))\n}", "func BindVertexArray(array uint32) {\n\tC.glowBindVertexArray(gpBindVertexArray, (C.GLuint)(array))\n}", "func BindVertexArray(array uint32) {\n\tC.glowBindVertexArray(gpBindVertexArray, (C.GLuint)(array))\n}", "func GetVertexAttribIuiv(index uint32, pname uint32, params *uint32) {\n C.glowGetVertexAttribIuiv(gpGetVertexAttribIuiv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLuint)(unsafe.Pointer(params)))\n}", "func (native *OpenGL) VertexAttribPointer(index uint32, size int32, xtype uint32, normalized bool, stride int32, pointer unsafe.Pointer) {\n\tgl.VertexAttribPointer(index, size, xtype, normalized, stride, pointer)\n}", "func GenVertexArrays(n int32, arrays *uint32) {\n\tsyscall.Syscall(gpGenVertexArrays, 2, uintptr(n), uintptr(unsafe.Pointer(arrays)), 0)\n}", "func BindVertexArray(array uint32) {\n\tsyscall.Syscall(gpBindVertexArray, 1, uintptr(array), 0, 0)\n}", "func VertexArrayElementBuffer(vaobj uint32, buffer uint32) {\n\tsyscall.Syscall(gpVertexArrayElementBuffer, 2, uintptr(vaobj), uintptr(buffer), 0)\n}", "func Enable(cap Enum) {\n\tccap, _ := (C.GLenum)(cap), cgoAllocsUnknown\n\tC.glEnable(ccap)\n}", "func (f Features) attrNormal() *spotify.TrackAttributes {\n\tx := spotify.NewTrackAttributes()\n\tx.TargetAcousticness(float64(f.Acousticness))\n\tx.TargetDanceability(float64(f.Danceability))\n\tx.TargetDuration(f.Duration)\n\tx.TargetEnergy(float64(f.Energy))\n\tx.TargetInstrumentalness(float64(f.Instrumentalness))\n\tx.TargetLiveness(float64(f.Liveness))\n\tx.TargetLoudness(float64(f.Loudness))\n\tx.TargetSpeechiness(float64(f.Speechiness))\n\tx.TargetValence(float64(f.Valence))\n\treturn x\n}", "func (graph *Graph) SetAttr(x, y int, attr byte) {\n\tgraph.Tiles[y][x].Attr = attr\n}", "func DrawElementsBaseVertex(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, basevertex int32) {\n C.glowDrawElementsBaseVertex(gpDrawElementsBaseVertex, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLint)(basevertex))\n}", "func (native *OpenGL) Disable(capability uint32) {\n\tgl.Disable(capability)\n}", "func enableWeights(tags []Tag) []Tag {\n\tvar dst []Tag\n\tfor _, v := range tags {\n\t\tdst = append(dst, Tag{v.Word, 1})\n\t\tfor i := 0; i < v.Weight-1; i++ {\n\t\t\tdst = append(dst, Tag{v.Word, 1})\n\t\t}\n\t}\n\treturn dst\n}", "func VertexAttrib4fv(index uint32, value []float32) {\n\tgl.VertexAttrib4fv(index, &value[0])\n}", "func (self *TileSprite) SetShaderA(member *AbstractFilter) {\n self.Object.Set(\"shader\", member)\n}", "func Disable(cap Enum) {\n\tccap, _ := (C.GLenum)(cap), cgoAllocsUnknown\n\tC.glDisable(ccap)\n}", "func ArrayElement(i int32) {\n C.glowArrayElement(gpArrayElement, (C.GLint)(i))\n}", "func GetVertexAttribfv(index uint32, pname uint32, params *float32) {\n\tsyscall.Syscall(gpGetVertexAttribfv, 3, uintptr(index), uintptr(pname), uintptr(unsafe.Pointer(params)))\n}", "func GetVertexAttribdv(index uint32, pname uint32, params *float64) {\n\tC.glowGetVertexAttribdv(gpGetVertexAttribdv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLdouble)(unsafe.Pointer(params)))\n}", "func GetVertexAttribdv(index uint32, pname uint32, params *float64) {\n\tC.glowGetVertexAttribdv(gpGetVertexAttribdv, (C.GLuint)(index), (C.GLenum)(pname), (*C.GLdouble)(unsafe.Pointer(params)))\n}", "func (self *TileSprite) SetSmoothedA(member bool) {\n self.Object.Set(\"smoothed\", member)\n}", "func (h *handlerImpl) reset(adjMatrix adjacencyMatrix) {\n\tfor from := range adjMatrix {\n\t\tfor to := range adjMatrix[from] {\n\t\t\tadjMatrix[from][to].disabled = false\n\t\t}\n\t}\n}", "func (gl *WebGL) VertexAttribPointer(position WebGLAttributeLocation, size int, valueType GLEnum, normalized bool, stride int, offset int) {\n\tgl.context.Call(\"vertexAttribPointer\", position, size, valueType, normalized, stride, offset)\n}", "func VertexAttribPointer(index Uint, size Int, kind Enum, normalized Boolean, stride Sizei, pointer unsafe.Pointer) {\n\tcindex, _ := (C.GLuint)(index), cgoAllocsUnknown\n\tcsize, _ := (C.GLint)(size), cgoAllocsUnknown\n\tckind, _ := (C.GLenum)(kind), cgoAllocsUnknown\n\tcnormalized, _ := (C.GLboolean)(normalized), cgoAllocsUnknown\n\tcstride, _ := (C.GLsizei)(stride), cgoAllocsUnknown\n\tcpointer, _ := (unsafe.Pointer)(unsafe.Pointer(pointer)), cgoAllocsUnknown\n\tC.glVertexAttribPointer(cindex, csize, ckind, cnormalized, cstride, cpointer)\n}", "func (g *GLTF) addAttributeToVBO(vbo *gls.VBO, attribName string, byteOffset uint32) {\n\n\taType, ok := AttributeName[attribName]\n\tif !ok {\n\t\tlog.Warn(fmt.Sprintf(\"Attribute %v is not supported!\", attribName))\n\t\treturn\n\t}\n\tvbo.AddAttribOffset(aType, byteOffset)\n}", "func ArrayElement(i int32) {\n\tC.glowArrayElement(gpArrayElement, (C.GLint)(i))\n}" ]
[ "0.7055345", "0.6961801", "0.6961801", "0.6763308", "0.66961026", "0.66961026", "0.636282", "0.62692064", "0.6207204", "0.6129912", "0.60076565", "0.60076565", "0.5986675", "0.59745425", "0.59459025", "0.59237194", "0.59237194", "0.5883715", "0.58829445", "0.57163274", "0.5661837", "0.5528807", "0.5417643", "0.54030985", "0.53803897", "0.5376542", "0.5366338", "0.5316413", "0.528323", "0.52389705", "0.52362454", "0.5222233", "0.52097905", "0.51933604", "0.51874095", "0.50903016", "0.50826436", "0.50826436", "0.5054548", "0.5011064", "0.50056535", "0.49877772", "0.4978986", "0.4951765", "0.49414793", "0.49153906", "0.49149558", "0.49075484", "0.4905164", "0.4903222", "0.48807967", "0.48807967", "0.48748618", "0.48361167", "0.48323894", "0.47917745", "0.47743273", "0.47387168", "0.47334224", "0.4730245", "0.4728253", "0.47167465", "0.4705734", "0.47050753", "0.47008803", "0.46991977", "0.4692541", "0.4689361", "0.468658", "0.468658", "0.4677714", "0.46523362", "0.46523362", "0.46369705", "0.46369705", "0.46116647", "0.46027154", "0.4597795", "0.45944467", "0.45941335", "0.4592401", "0.45766008", "0.45678076", "0.45673418", "0.45571554", "0.4554323", "0.4536005", "0.45273304", "0.45254928", "0.45081738", "0.45072755", "0.4495387", "0.4495387", "0.44936094", "0.44925097", "0.44903523", "0.44893196", "0.44885656", "0.4478893" ]
0.5729264
20
launch one or more compute work groups
func DispatchCompute(num_groups_x uint32, num_groups_y uint32, num_groups_z uint32) { C.glowDispatchCompute(gpDispatchCompute, (C.GLuint)(num_groups_x), (C.GLuint)(num_groups_y), (C.GLuint)(num_groups_z)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func (g groupWork) Run(job Job, ctx *Ctx) (interface{}, error) {\n\tgrp := NewGroup()\n\n\tgrp.Add(ctx.Do(NewJob(\"generic\", \"first\")))\n\tgrp.Add(ctx.Do(NewJob(\"generic\", \"group work\")))\n\tgrp.Add(ctx.Do(NewJob(\"generic\", \"group work\")))\n\tgrp.Add(ctx.Do(NewJob(\"generic\", \"group work\")))\n\tgrp.Add(ctx.Do(NewJob(\"generic\", \"group work\")))\n\n\treturn grp, nil\n}", "func spawnHosts(ctx context.Context, d distro.Distro, newHostsNeeded int, pool *evergreen.ContainerPool) ([]host.Host, error) {\n\n\tstartTime := time.Now()\n\n\tif newHostsNeeded == 0 {\n\t\treturn []host.Host{}, nil\n\t}\n\n\t// loop over the distros, spawning up the appropriate number of hosts\n\t// for each distro\n\n\thostsSpawned := []host.Host{}\n\n\tdistroStartTime := time.Now()\n\n\tif ctx.Err() != nil {\n\t\treturn nil, errors.New(\"scheduling run canceled\")\n\t}\n\n\t// if distro is container distro, check if there are enough parent hosts to\n\t// support new containers\n\tif pool != nil {\n\t\t// find all running parents with the specified container pool\n\t\tcurrentParents, err := host.FindAllRunningParentsByContainerPool(pool.Id)\n\t\tif err != nil {\n\t\t\treturn nil, errors.Wrap(err, \"could not find running parents\")\n\t\t}\n\n\t\t// find all child containers running on those parents\n\t\texistingContainers, err := host.HostGroup(currentParents).FindRunningContainersOnParents()\n\t\tif err != nil {\n\t\t\treturn nil, errors.Wrap(err, \"could not find running containers\")\n\t\t}\n\n\t\t// find all uphost parent intent documents\n\t\tnumUphostParents, err := host.CountUphostParentsByContainerPool(pool.Id)\n\t\tif err != nil {\n\t\t\treturn nil, errors.Wrap(err, \"could not count uphost parents\")\n\t\t}\n\n\t\t// create numParentsNeededParams struct\n\t\tparentsParams := newParentsNeededParams{\n\t\t\tnumUphostParents: numUphostParents,\n\t\t\tnumContainersNeeded: newHostsNeeded,\n\t\t\tnumExistingContainers: len(existingContainers),\n\t\t\tmaxContainers: pool.MaxContainers,\n\t\t}\n\t\t// compute number of parents needed\n\t\tnumNewParents := numNewParentsNeeded(parentsParams)\n\n\t\t// get parent distro from pool\n\t\tparentDistro, err := distro.FindOne(distro.ById(pool.Distro))\n\t\tif err != nil {\n\t\t\treturn nil, errors.Wrap(err, \"error find parent distro\")\n\t\t}\n\n\t\t// only want to spawn amount of parents allowed based on pool size\n\t\tnumNewParentsToSpawn, err := parentCapacity(parentDistro, numNewParents, len(currentParents), pool)\n\t\tif err != nil {\n\t\t\treturn nil, errors.Wrap(err, \"could not calculate number of parents needed to spawn\")\n\t\t}\n\t\t// create parent host intent documents\n\t\tif numNewParentsToSpawn > 0 {\n\t\t\thostsSpawned = append(hostsSpawned, createParents(parentDistro, numNewParentsToSpawn, pool)...)\n\n\t\t\tgrip.Info(message.Fields{\n\t\t\t\t\"runner\": RunnerName,\n\t\t\t\t\"distro\": d.Id,\n\t\t\t\t\"pool\": pool.Id,\n\t\t\t\t\"pool_distro\": pool.Distro,\n\t\t\t\t\"num_new_parents\": numNewParentsToSpawn,\n\t\t\t\t\"operation\": \"spawning new parents\",\n\t\t\t\t\"duration_secs\": time.Since(distroStartTime).Seconds(),\n\t\t\t})\n\t\t}\n\n\t\t// only want to spawn amount of containers we can fit on currently running parents\n\t\tnewHostsNeeded = containerCapacity(len(currentParents), len(existingContainers), newHostsNeeded, pool.MaxContainers)\n\t}\n\n\t// create intent documents for container hosts\n\tif d.ContainerPool != \"\" {\n\t\tcontainerIntents, err := generateContainerHostIntents(d, newHostsNeeded)\n\t\tif err != nil {\n\t\t\treturn nil, errors.Wrap(err, \"error generating container intent hosts\")\n\t\t}\n\t\thostsSpawned = append(hostsSpawned, containerIntents...)\n\t} else { // create intent documents for regular hosts\n\t\tfor i := 0; i < newHostsNeeded; i++ {\n\t\t\tintent, err := generateIntentHost(d)\n\t\t\tif err != nil {\n\t\t\t\treturn nil, errors.Wrap(err, \"error generating intent host\")\n\t\t\t}\n\t\t\thostsSpawned = append(hostsSpawned, *intent)\n\t\t}\n\t}\n\n\tif err := host.InsertMany(hostsSpawned); err != nil {\n\t\treturn nil, errors.Wrap(err, \"problem inserting host documents\")\n\t}\n\n\tgrip.Info(message.Fields{\n\t\t\"runner\": RunnerName,\n\t\t\"distro\": d.Id,\n\t\t\"operation\": \"spawning instances\",\n\t\t\"duration_secs\": time.Since(startTime).Seconds(),\n\t\t\"num_hosts\": len(hostsSpawned),\n\t})\n\n\treturn hostsSpawned, nil\n}", "func spawnHosts(ctx context.Context, newHostsNeeded map[string]int) (map[string][]host.Host, error) {\n\tstartTime := time.Now()\n\n\t// loop over the distros, spawning up the appropriate number of hosts\n\t// for each distro\n\thostsSpawnedPerDistro := make(map[string][]host.Host)\n\tfor distroId, numHostsToSpawn := range newHostsNeeded {\n\t\tdistroStartTime := time.Now()\n\n\t\tif numHostsToSpawn == 0 {\n\t\t\tcontinue\n\t\t}\n\n\t\thostsSpawnedPerDistro[distroId] = make([]host.Host, 0, numHostsToSpawn)\n\t\tfor i := 0; i < numHostsToSpawn; i++ {\n\t\t\tif ctx.Err() != nil {\n\t\t\t\treturn nil, errors.New(\"scheduling run canceled.\")\n\t\t\t}\n\n\t\t\td, err := distro.FindOne(distro.ById(distroId))\n\t\t\tif err != nil {\n\t\t\t\tgrip.Error(message.WrapError(err, message.Fields{\n\t\t\t\t\t\"distro\": distroId,\n\t\t\t\t\t\"runner\": RunnerName,\n\t\t\t\t\t\"message\": \"failed to find distro\",\n\t\t\t\t}))\n\t\t\t\tcontinue\n\t\t\t}\n\n\t\t\tallDistroHosts, err := host.Find(host.ByDistroId(distroId))\n\t\t\tif err != nil {\n\t\t\t\tgrip.Error(message.WrapError(err, message.Fields{\n\t\t\t\t\t\"distro\": distroId,\n\t\t\t\t\t\"runner\": RunnerName,\n\t\t\t\t\t\"message\": \"problem getting hosts for distro\",\n\t\t\t\t}))\n\n\t\t\t\tcontinue\n\t\t\t}\n\n\t\t\tif len(allDistroHosts) >= d.PoolSize {\n\t\t\t\tgrip.Info(message.Fields{\n\t\t\t\t\t\"distro\": distroId,\n\t\t\t\t\t\"runner\": RunnerName,\n\t\t\t\t\t\"pool_size\": d.PoolSize,\n\t\t\t\t\t\"message\": \"max hosts running\",\n\t\t\t\t})\n\n\t\t\t\tcontinue\n\t\t\t}\n\n\t\t\thostOptions := cloud.HostOptions{\n\t\t\t\tUserName: evergreen.User,\n\t\t\t\tUserHost: false,\n\t\t\t}\n\n\t\t\tintentHost := cloud.NewIntent(d, d.GenerateName(), d.Provider, hostOptions)\n\t\t\tif err := intentHost.Insert(); err != nil {\n\t\t\t\terr = errors.Wrapf(err, \"Could not insert intent host '%s'\", intentHost.Id)\n\n\t\t\t\tgrip.Error(message.WrapError(err, message.Fields{\n\t\t\t\t\t\"distro\": distroId,\n\t\t\t\t\t\"runner\": RunnerName,\n\t\t\t\t\t\"host\": intentHost.Id,\n\t\t\t\t\t\"provider\": d.Provider,\n\t\t\t\t}))\n\n\t\t\t\treturn nil, err\n\t\t\t}\n\n\t\t\thostsSpawnedPerDistro[distroId] = append(hostsSpawnedPerDistro[distroId], *intentHost)\n\n\t\t}\n\t\t// if none were spawned successfully\n\t\tif len(hostsSpawnedPerDistro[distroId]) == 0 {\n\t\t\tdelete(hostsSpawnedPerDistro, distroId)\n\t\t}\n\n\t\tgrip.Info(message.Fields{\n\t\t\t\"runner\": RunnerName,\n\t\t\t\"distro\": distroId,\n\t\t\t\"number\": numHostsToSpawn,\n\t\t\t\"operation\": \"spawning instances\",\n\t\t\t\"span\": time.Since(distroStartTime).String(),\n\t\t\t\"duration\": time.Since(distroStartTime),\n\t\t})\n\t}\n\n\tgrip.Info(message.Fields{\n\t\t\"runner\": RunnerName,\n\t\t\"operation\": \"host query and processing\",\n\t\t\"span\": time.Since(startTime).String(),\n\t\t\"duration\": time.Since(startTime),\n\t})\n\n\treturn hostsSpawnedPerDistro, nil\n}", "func wait_group() {\n\tno := 3\n\tvar wg sync.WaitGroup\n\tfor i := 0; i < no; i++ {\n\t\twg.Add(1)\n\t\tgo process_wg(i, &wg)\n\t}\n\twg.Wait()\n\tfmt.Println(\"All go routines finished executing\")\n}", "func Execute(nbIterations int, work func(int, int), maxCpus ...int) {\n\n\tnbTasks := runtime.NumCPU()\n\tif len(maxCpus) == 1 {\n\t\tnbTasks = maxCpus[0]\n\t}\n\tnbIterationsPerCpus := nbIterations / nbTasks\n\n\t// more CPUs than tasks: a CPU will work on exactly one iteration\n\tif nbIterationsPerCpus < 1 {\n\t\tnbIterationsPerCpus = 1\n\t\tnbTasks = nbIterations\n\t}\n\n\tvar wg sync.WaitGroup\n\n\textraTasks := nbIterations - (nbTasks * nbIterationsPerCpus)\n\textraTasksOffset := 0\n\n\tfor i := 0; i < nbTasks; i++ {\n\t\twg.Add(1)\n\t\t_start := i*nbIterationsPerCpus + extraTasksOffset\n\t\t_end := _start + nbIterationsPerCpus\n\t\tif extraTasks > 0 {\n\t\t\t_end++\n\t\t\textraTasks--\n\t\t\textraTasksOffset++\n\t\t}\n\t\tgo func() {\n\t\t\twork(_start, _end)\n\t\t\twg.Done()\n\t\t}()\n\t}\n\n\twg.Wait()\n}", "func LaunchWorkers(wg *sync.WaitGroup, stop <-chan bool) {\n\t// we need to recreate the dlChan and the segChan in case we want to restart workers.\n\tDlChan = make(chan *WJob)\n\tsegChan = make(chan *WJob)\n\taudioChan = make(chan *WJob)\n\t// the master worker downloads one full m3u8 at a time but\n\t// segments are downloaded concurrently\n\tmasterW := &Worker{id: 0, wg: wg, master: true}\n\tgo masterW.Work()\n\n\tfor i := 1; i < TotalWorkers+1; i++ {\n\t\tw := &Worker{id: i, wg: wg, client: &http.Client{}}\n\t\tgo w.Work()\n\t}\n}", "func DispatchCompute(num_groups_x uint32, num_groups_y uint32, num_groups_z uint32) {\n C.glowDispatchCompute(gpDispatchCompute, (C.GLuint)(num_groups_x), (C.GLuint)(num_groups_y), (C.GLuint)(num_groups_z))\n}", "func runPool(wg sync.WaitGroup, name string) {\n\tvar err error\n\n\t//set up queue of workers\n\tcluster, err := helpers.ReadConfig(name) //TODO - ugh, naming\n\tif err != nil {\n\t\t//log the bad, do the bad, this is bad\n\t}\n\n\tStandbyQueue = cluster.Nodes\n\n\t//this is how we do graceful shutdown, waiting to close channels until all workers goroutines have stopped\n\ttotalWorkers := len(StandbyQueue)\n\tstoppedWorkers := 0\n\n\tmessages := make(chan MessageData, len(StandbyQueue))\n\tstopped := make(chan struct{}, len(StandbyQueue))\n\tstopWorkers := make(chan struct{}, len(StandbyQueue))\n\n\tgo func() {\n\t\tdefer close(stopWorkers)\n\n\t\tdefer func() {\n\t\t\twg.Done()\n\t\t}()\n\n\t\tfor {\n\t\t\tselect {\n\t\t\tcase msg := <-messages:\n\t\t\t\tif msg.RawText == \"eagle has flopped\" {\n\t\t\t\t\t//do the next worker\n\t\t\t\t\tif len(StandbyQueue) > 0 {\n\t\t\t\t\t\tnext := CreateWorker(StandbyQueue[0], messages, stopped, stopWorkers)\n\t\t\t\t\t\tStandbyQueue = StandbyQueue[1:]\n\n\t\t\t\t\t\tnext.WorkerUp()\n\t\t\t\t\t} else {\n\t\t\t\t\t\t//error, something is wrong we have spun up too many\n\t\t\t\t\t}\n\t\t\t\t} else {\n\t\t\t\t\tfmt.Printf(\"%s: %s\\n\", msg.CommandName, msg.RawText)\n\t\t\t\t}\n\t\t\tcase <-stopped:\n\t\t\t\tfmt.Println(\"stopped message received\")\n\t\t\t\tstoppedWorkers++\n\t\t\t\tif stoppedWorkers == totalWorkers {\n\t\t\t\t\tfmt.Println(\"all workers have closed, ready for restart\")\n\t\t\t\t\t//close everything down\n\t\t\t\t\treturn\n\t\t\t\t}\n\n\t\t\t}\n\t\t}\n\t}()\n\n\t//run the first worker, wait for a response to run the rest\n\tfmt.Printf(\"starting worker: %s\\n\", StandbyQueue[0].Name)\n\tnworker := CreateWorker(StandbyQueue[0], messages, stopped, stopWorkers)\n\tStandbyQueue = StandbyQueue[1:]\n\tnworker.WorkerUp()\n\n\twg.Wait()\n\n\t// return \"restart\"\n\n}", "func (mr *MapReduce) RunMaster() []int {\n\tnumMapJobs := mr.nMap\n\tnumReduceJobs := mr.nReduce\n\tvar w sync.WaitGroup\n\n\tfor mapJob := 0; mapJob < numMapJobs; mapJob++ {\n\t\tavailableWorker := <-mr.registerChannel\n\t\tfmt.Println(\"USING WORKER\", availableWorker, \"for Map Job\")\n\t\tw.Add(1)\n\t\tgo func(worker string, i int) {\n\t\t\tdefer w.Done()\n\t\t\tvar reply DoJobReply\n\t\t\targs := &DoJobArgs{mr.file, Map, i, mr.nReduce}\n\t\t\tok := call(worker, \"Worker.DoJob\", args, &reply)\n\t\t\tif !ok {\n\t\t\t\tfmt.Println(\"Map Job\", i, \"has FAILED\")\n\t\t\t} else {\n\t\t\t\tfmt.Println(\"Map Job\", i, \"is SUCCESS\")\n\t\t\t}\n\t\t\tmr.registerChannel <- worker\n\t\t}(availableWorker, mapJob)\n\t}\n\n\tw.Wait()\n\tfmt.Println(\"DONE WITH ALL MAP JOBS\")\n\n\tfor reduceJob := 0; reduceJob < numReduceJobs; reduceJob++ {\n\t\tavailableWorker := <-mr.registerChannel\n\t\tfmt.Println(\"USING WORKER\", availableWorker, \"for Reduce Job\")\n\t\tw.Add(1)\n\t\tgo func(worker string, i int) {\n\t\t\tdefer w.Done()\n\t\t\tvar reply DoJobReply\n\t\t\targs := &DoJobArgs{mr.file, Reduce, i, mr.nMap}\n\t\t\tok := call(worker, \"Worker.DoJob\", args, &reply)\n\t\t\tif !ok {\n\t\t\t\tfmt.Println(\"Reduce Job\", i, \"has FAILED\")\n\t\t\t} else {\n\t\t\t\tfmt.Println(\"Reduce Job\", i, \"is SUCCESS\")\n\t\t\t}\n\t\t\tmr.registerChannel <- worker\n\t\t}(availableWorker, reduceJob)\n\t}\n\n\tw.Wait()\n\tfmt.Println(\"DONE WITH ALL REDUCE JOBS\")\n\n\treturn mr.KillWorkers()\n}", "func (my *Driver) LaunchSuites() error {\n\tvar err error\n\n\tsem := make(chan bool, 4)\n\tresultsChannel := make(chan *ChildResult)\n\tfor _, exe := range my.executables {\n\t\tgo launchExe(my, exe, sem, resultsChannel)\n\t}\n\n\tmy.results = make([]*ChildResult, 0)\n\terr = nil\n\tfor len(my.results) < len(my.executables) {\n\t\tr := <-resultsChannel\n\t\tmy.results = append(my.results, r)\n\t}\n\n\treturn err\n}", "func groupCmd(c *cli.Context) error {\n\targs := c.Args()\n\tif !args.Present() {\n\t\tslog.Fatal(\"missing identity file to create the group.toml\")\n\t}\n\tif c.NArg() < 3 {\n\t\tslog.Fatal(\"not enough identities (\", c.NArg(), \") to create a group toml. At least 3!\")\n\t}\n\tvar threshold = key.DefaultThreshold(c.NArg())\n\tif c.IsSet(\"threshold\") {\n\t\tif c.Int(\"threshold\") < threshold {\n\t\t\tslog.Print(\"WARNING: You are using a threshold which is TOO LOW.\")\n\t\t\tslog.Print(\"\t\t It should be at least \", threshold)\n\t\t}\n\t\tthreshold = c.Int(\"threshold\")\n\t}\n\n\tpublics := make([]*key.Identity, c.NArg())\n\tfor i, str := range args {\n\t\tpub := &key.Identity{}\n\t\tslog.Print(\"Reading public identity from \", str)\n\t\tif err := key.Load(str, pub); err != nil {\n\t\t\tslog.Fatal(err)\n\t\t}\n\t\tpublics[i] = pub\n\t}\n\tgroup := key.NewGroup(publics, threshold)\n\tgroupPath := path.Join(fs.Pwd(), gname)\n\tif c.String(\"out\") != \"\" {\n\t\tgroupPath = c.String(\"out\")\n\t}\n\tif err := key.Save(groupPath, group, false); err != nil {\n\t\tslog.Fatal(err)\n\t}\n\tslog.Printf(\"Group file written in %s. Distribute it to all the participants to start the DKG\", groupPath)\n\treturn nil\n}", "func multiWork(nums []float64) {\n\tch := make(chan float64)\n\tvar wg sync.WaitGroup\n\twg.Add(len(nums))\n\n\tfor i := 0; i < runtime.NumCPU(); i++ {\n\t\tgo poolWorker(ch, &wg)\n\t}\n\n\tfor _, i := range nums {\n\t\tch <- i\n\t}\n\n\twg.Wait()\n\tclose(ch)\n}", "func workerpool() {\n\tworkers := 3\n\tworkchan := make(chan int)\n\tfor i := 0; i < workers; i++ {\n\t\tgo func() {\n\t\t\tfor i := range workchan {\n\t\t\t\ttime.Sleep(3 * time.Second)\n\t\t\t\tfmt.Println(\"Workerpool worked on \", i)\n\t\t\t}\n\t\t}()\n\t}\n\tamountOfWork := 10\n\tfor i := 0; i < amountOfWork; i++ {\n\t\tworkchan <- i\n\t}\n\tfmt.Println(\"Finished workerpool work\")\n\t//Give some time for goroutines to finish. To avoid using WaitGroup and loosing focus.\n\ttime.Sleep(5 * time.Second)\n}", "func main() {\n\tb := specs.MustNewTasksCfgBuilder()\n\n\t// Create Tasks and Jobs.\n\tfor _, name := range JOBS {\n\t\tprocess(b, name)\n\t}\n\n\tb.MustFinish()\n}", "func DispatchCompute(num_groups_x uint32, num_groups_y uint32, num_groups_z uint32) {\n\tsyscall.Syscall(gpDispatchCompute, 3, uintptr(num_groups_x), uintptr(num_groups_y), uintptr(num_groups_z))\n}", "func placeForks(ptp topology.PointToPoint, n int) {\n\tfor i := 0; i < n; i++ {\n\t\ttuplespace.Put(ptp, \"fork\", i)\n\t}\n}", "func WaitGroup() {\n\n\tfmt.Println(\"OS \\t\", runtime.GOOS)\n\tfmt.Println(\"ARCH \\t\", runtime.GOARCH)\n\tfmt.Println(\"CPUs \\t\", runtime.NumCPU())\n\tfmt.Println(\"GoRoutines \\t\", runtime.NumGoroutine())\n\tfmt.Printf(\"%T\\n\", wg)\n\n\twg.Add(1)\n\t// new goroutine\n\tgo foo()\n\tbar()\n\n\tfmt.Println(\"uno\")\n\tfmt.Println(\"dos\")\n\twg.Wait()\n}", "func makeWorkers(t *testing.T, n int, pool *string) []*types.Component {\n\tt.Helper()\n\tvar components []*types.Component\n\n\tif n < 1 {\n\t\treturn components\n\t}\n\n\tcomponents = append(components, types.NewComponent(testContainerImage, types.ServerComponent))\n\n\tfor i := n - 1; i > 0; i-- {\n\t\tcomponents = append(components, types.NewComponent(testContainerImage, types.ClientComponent))\n\t}\n\n\tif pool != nil {\n\t\tfor _, c := range components {\n\t\t\tc.PoolName = *pool\n\t\t}\n\t}\n\n\treturn components\n}", "func (c *testCluster) createGroup(groupID roachpb.RangeID, firstNode, numReplicas int) {\n\tvar replicaIDs []uint64\n\tfor i := 0; i < numReplicas; i++ {\n\t\tnodeIndex := firstNode + i\n\t\treplicaIDs = append(replicaIDs, uint64(c.nodes[nodeIndex].nodeID))\n\t\tc.groups[groupID] = append(c.groups[groupID], nodeIndex)\n\t}\n\tfor i := 0; i < numReplicas; i++ {\n\t\tgs, err := c.storages[firstNode+i].GroupStorage(groupID, 0)\n\t\tif err != nil {\n\t\t\tc.t.Fatal(err)\n\t\t}\n\t\tmemStorage := gs.(*blockableGroupStorage).s.(*raft.MemoryStorage)\n\t\tif err := memStorage.SetHardState(raftpb.HardState{\n\t\t\tCommit: 10,\n\t\t\tTerm: 5,\n\t\t}); err != nil {\n\t\t\tc.t.Fatal(err)\n\t\t}\n\t\tif err := memStorage.ApplySnapshot(raftpb.Snapshot{\n\t\t\tMetadata: raftpb.SnapshotMetadata{\n\t\t\t\tConfState: raftpb.ConfState{\n\t\t\t\t\tNodes: replicaIDs,\n\t\t\t\t},\n\t\t\t\tIndex: 10,\n\t\t\t\tTerm: 5,\n\t\t\t},\n\t\t}); err != nil {\n\t\t\tc.t.Fatal(err)\n\t\t}\n\n\t\tnode := c.nodes[firstNode+i]\n\t\tif err := node.CreateGroup(groupID); err != nil {\n\t\t\tc.t.Fatal(err)\n\t\t}\n\t}\n}", "func (mg *Groups) Start(instances int, force bool) error {\n\n\tif mg.group != nil && len(mg.group.ID) > 0 {\n\t\tif appClient := application.New(mg.client); appClient != nil {\n\n\t\t\tcallbackFunc := func(appID string) error {\n\n\t\t\t\tif err := appClient.Get(appID).Start(instances, force); err != nil {\n\t\t\t\t\treturn err\n\t\t\t\t}\n\t\t\t\treturn nil\n\t\t\t}\n\t\t\treturn mg.traverseGroupsWithAppID(mg.group, callbackFunc)\n\t\t}\n\t\treturn fmt.Errorf(\"unnable to connect\")\n\t}\n\treturn errors.New(\"group cannot be null nor empty\")\n}", "func (g *Group) Kickstart(tpGen TestPlanGen, total, offset, SecRamp int) {\n\n\tg.initialize()\n\tg.Total = total\n\n\t// Generate a Test Plan for Global Setup\n\ttestPlan := tpGen(0, nil)\n\terr := testPlan.GlobalSetup()\n\n\tif err != nil {\n\t\tpanic(err)\n\t}\n\n\tsleepIncrement := time.Duration(SecRamp) * time.Second / time.Duration(total)\n\tgo g.spinUpThreads(tpGen, total, offset, sleepIncrement)\n\n\tfor activity := range g.ActivityPipe {\n\t\tswitch activity.Status {\n\t\tcase StatusActive:\n\t\t\tg.registerThreadActive(activity)\n\t\tcase StatusInactive:\n\t\t\tg.registerThreadInactive(activity)\n\t\tcase StatusLaunching:\n\t\t\tg.registerThreadLaunching(activity)\n\t\tcase StatusLaunchFailed:\n\t\t\tg.registerLaunchFail(activity)\n\t\tcase StatusError:\n\t\t\tg.registerThreadError(activity)\n\t\tcase StatusAction:\n\t\t\tg.registerThreadAction(activity)\n\t\tcase StatusIncoming:\n\t\t\tg.registerThreadIncoming(activity)\n\t\tdefault:\n\t\t\tpanic(\"Unhandled Activity type in group\")\n\t\t}\n\t}\n}", "func (m *Manager) Exec(name string, opt ExecOptions, gOpt operator.Options) error {\n\tif err := clusterutil.ValidateClusterNameOrError(name); err != nil {\n\t\treturn err\n\t}\n\n\tmetadata, err := m.meta(name)\n\tif err != nil {\n\t\treturn err\n\t}\n\n\ttopo := metadata.GetTopology()\n\tbase := metadata.GetBaseMeta()\n\n\tfilterRoles := set.NewStringSet(gOpt.Roles...)\n\tfilterNodes := set.NewStringSet(gOpt.Nodes...)\n\n\tvar shellTasks []task.Task\n\tuniqueHosts := map[string]set.StringSet{} // host-sshPort -> {command}\n\ttopo.IterInstance(func(inst spec.Instance) {\n\t\tkey := utils.JoinHostPort(inst.GetManageHost(), inst.GetSSHPort())\n\t\tif _, found := uniqueHosts[key]; !found {\n\t\t\tif len(gOpt.Roles) > 0 && !filterRoles.Exist(inst.Role()) {\n\t\t\t\treturn\n\t\t\t}\n\n\t\t\tif len(gOpt.Nodes) > 0 && (!filterNodes.Exist(inst.GetHost()) && !filterNodes.Exist(inst.GetManageHost())) {\n\t\t\t\treturn\n\t\t\t}\n\n\t\t\tcmds, err := renderInstanceSpec(opt.Command, inst)\n\t\t\tif err != nil {\n\t\t\t\tm.logger.Debugf(\"error rendering command with spec: %s\", err)\n\t\t\t\treturn // skip\n\t\t\t}\n\t\t\tcmdSet := set.NewStringSet(cmds...)\n\t\t\tif _, ok := uniqueHosts[key]; ok {\n\t\t\t\tuniqueHosts[key].Join(cmdSet)\n\t\t\t\treturn\n\t\t\t}\n\t\t\tuniqueHosts[key] = cmdSet\n\t\t}\n\t})\n\n\tfor hostKey, i := range uniqueHosts {\n\t\thost, _ := utils.ParseHostPort(hostKey)\n\t\tfor _, cmd := range i.Slice() {\n\t\t\tshellTasks = append(shellTasks,\n\t\t\t\ttask.NewBuilder(m.logger).\n\t\t\t\t\tShell(host, cmd, hostKey+cmd, opt.Sudo).\n\t\t\t\t\tBuild())\n\t\t}\n\t}\n\n\tb, err := m.sshTaskBuilder(name, topo, base.User, gOpt)\n\tif err != nil {\n\t\treturn err\n\t}\n\n\tt := b.\n\t\tParallel(false, shellTasks...).\n\t\tBuild()\n\n\texecCtx := ctxt.New(\n\t\tcontext.Background(),\n\t\tgOpt.Concurrency,\n\t\tm.logger,\n\t)\n\tif err := t.Execute(execCtx); err != nil {\n\t\tif errorx.Cast(err) != nil {\n\t\t\t// FIXME: Map possible task errors and give suggestions.\n\t\t\treturn err\n\t\t}\n\t\treturn perrs.Trace(err)\n\t}\n\n\t// print outputs\n\tfor hostKey, i := range uniqueHosts {\n\t\thost, _ := utils.ParseHostPort(hostKey)\n\t\tfor _, cmd := range i.Slice() {\n\t\t\tstdout, stderr, ok := ctxt.GetInner(execCtx).GetOutputs(hostKey + cmd)\n\t\t\tif !ok {\n\t\t\t\tcontinue\n\t\t\t}\n\t\t\tm.logger.Infof(\"Outputs of %s on %s:\",\n\t\t\t\tcolor.CyanString(cmd),\n\t\t\t\tcolor.CyanString(host))\n\t\t\tif len(stdout) > 0 {\n\t\t\t\tm.logger.Infof(\"%s:\\n%s\", color.GreenString(\"stdout\"), stdout)\n\t\t\t}\n\t\t\tif len(stderr) > 0 {\n\t\t\t\tm.logger.Infof(\"%s:\\n%s\", color.RedString(\"stderr\"), stderr)\n\t\t\t}\n\t\t}\n\t}\n\n\treturn nil\n}", "func (m *manager) Sync(nodes []string) (err error) {\n\tklog.V(2).Infof(\"Syncing nodes %v\", nodes)\n\n\tdefer func() {\n\t\t// The node pool is only responsible for syncing nodes to instance\n\t\t// groups. It never creates/deletes, so if an instance groups is\n\t\t// not found there's nothing it can do about it anyway. Most cases\n\t\t// this will happen because the backend pool has deleted the instance\n\t\t// group, however if it happens because a user deletes the IG by mistake\n\t\t// we should just wait till the backend pool fixes it.\n\t\tif utils.IsHTTPErrorCode(err, http.StatusNotFound) {\n\t\t\tklog.Infof(\"Node pool encountered a 404, ignoring: %v\", err)\n\t\t\terr = nil\n\t\t}\n\t}()\n\n\tpool, err := m.List()\n\tif err != nil {\n\t\tklog.Errorf(\"List error: %v\", err)\n\t\treturn err\n\t}\n\n\tfor _, igName := range pool {\n\t\tgceNodes := sets.NewString()\n\t\tgceNodes, err = m.listIGInstances(igName)\n\t\tif err != nil {\n\t\t\tklog.Errorf(\"list(%q) error: %v\", igName, err)\n\t\t\treturn err\n\t\t}\n\t\tkubeNodes := sets.NewString(nodes...)\n\n\t\t// Individual InstanceGroup has a limit for 1000 instances in it.\n\t\t// As a result, it's not possible to add more to it.\n\t\tif len(kubeNodes) > m.maxIGSize {\n\t\t\t// List() will return a sorted list so the kubeNodesList truncation will have a stable set of nodes.\n\t\t\tkubeNodesList := kubeNodes.List()\n\n\t\t\t// Store first 10 truncated nodes for logging\n\t\t\ttruncateForLogs := func(nodes []string) []string {\n\t\t\t\tmaxLogsSampleSize := 10\n\t\t\t\tif len(nodes) <= maxLogsSampleSize {\n\t\t\t\t\treturn nodes\n\t\t\t\t}\n\t\t\t\treturn nodes[:maxLogsSampleSize]\n\t\t\t}\n\n\t\t\tklog.Warningf(\"Total number of kubeNodes: %d, truncating to maximum Instance Group size = %d. Instance group name: %s. First truncated instances: %v\", len(kubeNodesList), m.maxIGSize, igName, truncateForLogs(nodes[m.maxIGSize:]))\n\t\t\tkubeNodes = sets.NewString(kubeNodesList[:m.maxIGSize]...)\n\t\t}\n\n\t\t// A node deleted via kubernetes could still exist as a gce vm. We don't\n\t\t// want to route requests to it. Similarly, a node added to kubernetes\n\t\t// needs to get added to the instance group so we do route requests to it.\n\n\t\tremoveNodes := gceNodes.Difference(kubeNodes).List()\n\t\taddNodes := kubeNodes.Difference(gceNodes).List()\n\n\t\tklog.V(2).Infof(\"Removing nodes: %v\", removeNodes)\n\t\tklog.V(2).Infof(\"Adding nodes: %v\", addNodes)\n\n\t\tstart := time.Now()\n\t\tif len(removeNodes) != 0 {\n\t\t\terr = m.remove(igName, removeNodes)\n\t\t\tklog.V(2).Infof(\"Remove(%q, _) = %v (took %s); nodes = %v\", igName, err, time.Now().Sub(start), removeNodes)\n\t\t\tif err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\t\t}\n\n\t\tstart = time.Now()\n\t\tif len(addNodes) != 0 {\n\t\t\terr = m.add(igName, addNodes)\n\t\t\tklog.V(2).Infof(\"Add(%q, _) = %v (took %s); nodes = %v\", igName, err, time.Now().Sub(start), addNodes)\n\t\t\tif err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\t\t}\n\t}\n\treturn nil\n}", "func (e *Environment) start(ctx context.Context, wg *sync.WaitGroup) {\n\tos.Setenv(\"ROS_MASTER_URI\", e.addr)\n\t// Start a process:\n\tlog.Printf(\"Environment started with id %d on port %d.\\n\", e.id, e.port)\n\t// cmd := exec.Command(\"roslaunch\", \"-p\", strconv.Itoa(e.port), \"test\", \"test.launch\")\n\t// cmd := exec.Command(\"roslaunch\", \"-p\", strconv.Itoa(e.port), \"backend\", \"learning.launch\")\n\tsport := strconv.Itoa(e.port)\n\tcmd := exec.Command(\"roslaunch\", \"-p\", sport, \"backend\", \"learning.launch\", \"port:=\"+sport, \"gui:=false\")\n\n\tcmd.SysProcAttr = &syscall.SysProcAttr{Setpgid: true}\n\terr := cmd.Start()\n\tif err != nil {\n\t\tpanic(\"Critical panic env start\")\n\t}\n\tselect {\n\tcase _ = <-ctx.Done():\n\t\tlog.Printf(\"Signal to stop the simulation environment %d.\\n\", e.id)\n\t\t// kill the process on cancel\n\t\tpgid, err := syscall.Getpgid(cmd.Process.Pid)\n\t\tlog.Printf(\"DBG simulation environment %d was killed.\\n\", e.id)\n\t\tif err == nil {\n\t\t\t// NOte that minus sign is for the groupd pid.\n\t\t\tsyscall.Kill(-pgid, 15)\n\t\t}\n\t\terr = cmd.Wait()\n\t\tif err != nil {\n\t\t\tlog.Println(\"Do cmd wait did not succeed\")\n\t\t}\n\t\twg.Done()\n\t}\n}", "func main() {\n\t// add waitgroup for each goroutine\n\twaitGroup.Add(3)\n\n\tgo increment(\"yamaha\")\n\tgo increment(\"mt\")\n\tgo increment(\"25\")\n\n\t// waiting for goroutines to complete\n\twaitGroup.Wait()\n\n\tfmt.Println(c)\n}", "func RunTasks(workingDirectory string, destPlatforms []platforms.Platform, settings *config.Settings, maxProcessors int) error {\n\tif settings.IsVerbose() {\n\t\tlog.Printf(\"Using Go root: %s\", settings.GoRoot)\n\t\tlog.Printf(\"looping through each platform\")\n\t}\n\tappName := core.GetAppName(settings.AppName, workingDirectory)\n\n\toutDestRoot, err := core.GetOutDestRoot(appName, workingDirectory, settings.ArtifactsDest)\n\tif err != nil {\n\t\treturn err\n\t}\n\tdefer log.SetPrefix(\"[goxc] \")\n\texclusions := ResolveAliases(settings.TasksExclude)\n\tappends := ResolveAliases(settings.TasksAppend)\n\tmains := ResolveAliases(settings.Tasks)\n\tall := ResolveAliases(settings.TasksPrepend)\n\t//log.Printf(\"prepending %v\", all)\n\tall = append(all, mains...)\n\tall = append(all, appends...)\n\n\t//exclude by resolved task names (not by aliases)\n\ttasksToRun := []string{}\n\tfor _, taskName := range all {\n\t\tif !core.ContainsString(exclusions, taskName) {\n\t\t\ttasksToRun = append(tasksToRun, taskName)\n\t\t}\n\t}\n\t//0.6 check all tasks are valid before continuing\n\tfor _, taskName := range tasksToRun {\n\t\tif _, keyExists := allTasks[taskName]; !keyExists {\n\t\t\tif strings.HasPrefix(taskName, \".\") {\n\t\t\t\tlog.Printf(\"'%s' looks like a directory, not a task - specify 'working directory' with -wd option\", taskName)\n\t\t\t}\n\t\t\tif e, _ := core.FileExists(taskName); e {\n\t\t\t\tlog.Printf(\"'%s' looks like a directory, not a task - specify 'working directory' with -wd option\", taskName)\n\t\t\t}\n\t\t\tif settings.IsVerbose() {\n\t\t\t\tlog.Printf(\"Task '%s' does NOT exist!\", taskName)\n\t\t\t}\n\t\t\treturn errors.New(\"Task '\" + taskName + \"' does not exist\")\n\t\t}\n\t}\n\tmainDirs := []string{}\n\tallPackages := []string{}\n\tif len(tasksToRun) == 1 && tasksToRun[0] == \"toolchain\" {\n\t\tlog.Printf(\"Toolchain task only - not searching for main dirs\")\n\t\t//mainDirs = []string{workingDirectory}\n\t} else {\n\t\tvar err error\n\t\texcludes := core.ParseCommaGlobs(settings.MainDirsExclude)\n\t\texcludesSource := core.ParseCommaGlobs(settings.SourceDirsExclude)\n\t\texcludesSource = append(excludesSource, excludes...)\n\t\tallPackages, err = source.FindSourceDirs(workingDirectory, \"\", excludesSource, settings.IsVerbose())\n\t\tif err != nil || len(allPackages) == 0 {\n\t\t\tlog.Printf(\"Warning: could not establish list of source packages. Using working directory\")\n\t\t\tallPackages = []string{workingDirectory}\n\t\t}\n\t\tmainDirs, err = source.FindMainDirs(workingDirectory, excludes, settings.IsVerbose())\n\t\tif err != nil || len(mainDirs) == 0 {\n\t\t\tlog.Printf(\"Warning: could not find any main dirs: %v\", err)\n\t\t} else {\n\t\t\tif settings.IsVerbose() {\n\t\t\t\tlog.Printf(\"Found 'main package' dirs (len %d): %v\", len(mainDirs), mainDirs)\n\t\t\t}\n\t\t}\n\t}\n\tif settings.IsVerbose() {\n\t\tlog.Printf(\"Running tasks: %v\", tasksToRun)\n\t\tlog.Printf(\"All packages: %v\", allPackages)\n\t}\n\tfor _, taskName := range tasksToRun {\n\t\tlog.SetPrefix(\"[goxc:\" + taskName + \"] \")\n\t\terr := runTask(taskName, destPlatforms, allPackages, mainDirs, appName, workingDirectory, outDestRoot, settings, maxProcessors)\n\t\tif err != nil {\n\t\t\t// TODO: implement 'force' option.\n\t\t\tlog.Printf(\"Stopping after '%s' failed with error '%v'\", taskName, err)\n\t\t\treturn err\n\t\t} else {\n\t\t\tif !settings.IsQuiet() {\n\t\t\t\tlog.Printf(\"Task %s succeeded\", taskName)\n\t\t\t}\n\t\t}\n\t}\n\treturn nil\n}", "func Parallel(ctx context.Context, state *core.BuildState, labels []core.AnnotatedOutputLabel, args []string, numTasks int, outputMode process.OutputMode, remote, env, detach, inTmp bool, dir string) int {\n\tprepareRun()\n\n\tlimiter := make(chan struct{}, numTasks)\n\tvar g errgroup.Group\n\tfor _, label := range labels {\n\t\tlabel := label // capture locally\n\t\tg.Go(func() error {\n\t\t\tlimiter <- struct{}{}\n\t\t\tdefer func() { <-limiter }()\n\n\t\t\terr := runWithOutput(ctx, state, label, args, outputMode, remote, env, detach, inTmp, dir)\n\t\t\tif err != nil && ctx.Err() == nil {\n\t\t\t\tlog.Error(\"Command failed: %s\", err)\n\t\t\t}\n\t\t\treturn err\n\t\t})\n\t}\n\tif err := g.Wait(); err != nil {\n\t\tif ctx.Err() != nil { // Don't error if the context killed the process.\n\t\t\treturn 0\n\t\t}\n\t\treturn err.(*exitError).code\n\t}\n\treturn 0\n}", "func RunPool(number int, paths <-chan string) <-chan string {\n\tresults := make(chan string, 10)\n\n\tgo func() {\n\t\twg := new(sync.WaitGroup)\n\n\t\tfor i := 0; i < number; i++ {\n\t\t\twg.Add(1)\n\t\t\tgo runWorker(paths, results, wg)\n\t\t}\n\n\t\twg.Wait()\n\n\t\tclose(results)\n\t}()\n\n\treturn results\n}", "func createWorkerPool(noOfWorkers int) {\n\tvar wg sync.WaitGroup\n\tfor i := 0; i < noOfWorkers; i++ {\n\t\twg.Add(1)\n\t\tgo worker(&wg)\n\t}\n\twg.Wait()\n\tclose(results)\n}", "func RoutinesWaitGroup() {\n\tlog.Println(\"Started.\")\n\n\tvar wg sync.WaitGroup\n\twg.Add(2)\n\tgo rwg(\"a\", &wg)\n\tgo rwg(\"b\", &wg)\n\twg.Wait()\n\n\tlog.Println(\"Done.\")\n}", "func main() {\n\tvar err error\n\tagentChanSize := 300\n\tbatchMax := 100\n\tagt := agent.NewAgent(agentChanSize, batchMax)\n\tc1 := NewCollect(\"c1\", \"1\")\n\tc2 := NewCollect(\"c2\", \"2\")\n\tagt.RegisterController(\"c1\", c1)\n\tagt.RegisterController(\"c2\", c2)\n\n\t//应该不会报错\n\tif err = agt.Start(); err != nil {\n\t\tfmt.Println(\"start1() err:\",err.Error())\n\t}\n\n\tif err = agt.Start(); err != nil {\n\t\tfmt.Println(\"start2() err:\",err.Error())\n\t}\n\n\t//因为前面已经启动过了会报错\n\ttime.Sleep(time.Second *20)\n\tagt.Stop()\n\tagt.Destroy()\n}", "func (fl *FlowLauncher) Exec(p Props) {\n\n\tendParams := MakeParams()\n\tendParams.Props = p\n\n\t// make fresh chanels on each exec as they were probably closed\n\tfl.CStat = make(chan *Params)\n\tfl.iEnd = make(chan *Params)\n\n\tif fl.LastRunResult == nil {\n\t\tfl.LastRunResult = &FlowLaunchResult{}\n\t}\n\tfl.Error = \"\"\n\n\tif fl.TidyDeskPolicy(p) == false {\n\t\tendParams.Status = FAIL\n\t\tfl.iEnd <- endParams\n\t\treturn\n\t}\n\n\tglog.Info(\"workflow launcher \", fl.Name, \" with \", fl.Threads, \" threads\")\n\tvar waitGroup sync.WaitGroup\n\n\tfl.Flows = make([]*Workflow, fl.Threads, fl.Threads)\n\n\t// fire off some threads\n\tfor i := 0; i < fl.Threads; i++ {\n\n\t\t// create a new workflow\n\t\tflow := fl.FlowFunc(i)\n\n\t\t// save it for later\n\t\tfl.Flows[i] = flow\n\n\t\t// only realy need to do this once - but hey\n\t\tendParams.FlowName = flow.Name\n\n\t\tglog.Info(\"workflow launch \", flow.Name, \" with threadid \", i)\n\n\t\t// check some conditions...\n\t\tif flow == nil {\n\t\t\tglog.Error(flow.Name, \" has no flow\")\n\t\t\treturn\n\t\t}\n\n\t\tif flow.Start == nil {\n\t\t\tglog.Error(flow.Name, \" has no flow start\")\n\t\t\treturn\n\t\t}\n\n\t\tif flow.End == nil {\n\t\t\tglog.Error(flow.Name, \" has no flow end\")\n\t\t\treturn\n\t\t}\n\n\t\t// for the first thread make the results including capturing any streamed io from the tasks\n\t\tif i == 0 {\n\t\t\tfl.MakeLaunchResults(flow)\n\t\t}\n\n\t\t// TOOD - here you would inject any function to vary the params per thread\n\t\tparams := MakeParams()\n\t\tparams.Props = p\n\t\tparams.FlowName = flow.Name\n\t\tparams.ThreadId = i\n\n\t\tglog.Info(\"firing task with params \", params)\n\n\t\t// build up the thread wait group\n\t\twaitGroup.Add(1)\n\n\t\t// and fire of the workflow\n\t\tgo flow.Exec(params)\n\n\t\t// loop round forwarding status updates\n\t\tgo func() {\n\t\t\tglog.Info(\"waiting on chanel flow.C \")\n\t\t\tfor stat := range flow.C {\n\t\t\t\tglog.Info(\"got status \", stat)\n\t\t\t\tfl.LastRunResult.AddStatusOrResult(stat.TaskId, stat.Complete, stat.Status)\n\t\t\t\tfl.CStat <- stat // tiger any stats change chanel (e.g. for push messages like websockets)\n\t\t\t}\n\t\t\tglog.Info(\"launcher status loop stoppped\")\n\t\t}()\n\n\t\t// set up the flow end trigger - the end registered node will fire this\n\t\tgo func() {\n\t\t\tpar := <-flow.End.Trigger()\n\t\t\tglog.Info(\"got flow end \", par.ThreadId, \" \", flow.End.GetName())\n\t\t\t// collect all end event triggers - last par wins\n\t\t\tendParams.Status = endParams.Status + par.Status\n\n\t\t\t// update metrics\n\t\t\tnow := time.Now()\n\t\t\tfl.LastRunResult.Duration = now.Sub(fl.LastRunResult.Start)\n\n\t\t\t// close the flow status chanel\n\t\t\tclose(flow.C)\n\n\t\t\t// count down the waitgroup\n\t\t\twaitGroup.Done()\n\t\t}()\n\t}\n\n\t// now lets wait for all the threads to finish - probably TODO a timeout as well in case of bad flows...\n\tgo func() {\n\t\twaitGroup.Wait()\n\t\tglog.Info(\"completed launcher \", fl.Name, \" with \", fl.Threads, \" threads\")\n\t\t// mark status\n\t\tfl.LastRunResult.Completed = true\n\n\t\t// close the status channel\n\t\tclose(fl.CStat)\n\n\t\t// and trigger the end event\n\t\tfl.iEnd <- endParams\n\t}()\n}", "func startSingleInstance(tasks []string, name string) {\n\tfor i := 0; i < len(tasks); i++ {\n\t\tchannel <- message{\n\t\t\taction: \"start\",\n\t\t\tname: fmt.Sprintf(\"%s-%d\", name, i),\n\t\t\ttask: tasks[i],\n\t\t}\n\t}\n}", "func (p *Pool) Exec() {\n\tfor i := 0; i < p.workers; i++ {\n\t\t//creating workers to receive and execute the tasks\n\t\tgo p.work()\n\t}\n\n\tp.wg.Add(len(p.Tasks))\n\tfor _, task := range p.Tasks {\n\t\t//tasks are added in the channel.\n\t\t//workers are listening this channel and when a worker is idle\n\t\t//it will receive the task to execute\n\t\tp.queueTasks <- task\n\t}\n\n\t// close the channel when all task was executed\n\tclose(p.queueTasks)\n\n\tp.wg.Wait()\n}", "func StartWorker(mapFunc MapFunc, reduceFunc ReduceFunc, master string) error {\n\tos.Mkdir(\"/tmp/squinn\", 1777)\n\ttasks_run := 0\n\tfor {\n\t\tlogf(\"===============================\")\n\t\tlogf(\" Starting new task.\")\n\t\tlogf(\"===============================\")\n\t\t/*\n\t\t * Call master, asking for work\n\t\t */\n\n\t\tvar resp Response\n\t\tvar req Request\n\t\terr := call(master, \"GetWork\", req, &resp)\n\t\tif err != nil {\n\t\t\tfailure(\"GetWork\")\n\t\t\ttasks_run++\n\t\t\tcontinue\n\t\t}\n\t\t/*\n\t\tif resp.Message == WORK_DONE {\n\t\t\tlog.Println(\"GetWork - Finished Working\")\n\t\t\tresp.Type =\n\t\t\tbreak\n\t\t}\n\t\t*/\n\t\t//for resp.Message == WAIT {\n\t\tfor resp.Type == TYPE_WAIT {\n\t\t\ttime.Sleep(1e9)\n\t\t\terr = call(master, \"GetWork\", req, &resp)\n\t\t\tif err != nil {\n\t\t\t\tfailure(\"GetWork\")\n\t\t\t\ttasks_run++\n\t\t\t\tcontinue\n\t\t\t}\n\t\t\t/*\n\t\t\tif resp.Message == WORK_DONE {\n\t\t\t\tlog.Println(\"GetWork - Finished Working\")\n\t\t\t\tbreak\n\t\t\t}\n\t\t\t*/\n\t\t}\n\t\twork := resp.Work\n\t\toutput := resp.Output\n\t\tvar myAddress string\n\n\t\t/*\n\t\t * Do work\n\t\t */\n\t\t// Walks through the assigned sql records\n\t\t// Call the given mapper function\n\t\t// Receive from the output channel in a go routine\n\t\t// Feed them to the reducer through its own sql files\n\t\t// Close the sql files\n\n\t\tif resp.Type == TYPE_MAP {\n\t\t\tlogf(\"MAP ID: %d\", work.WorkerID)\n\t\t\tlog.Printf(\"Range: %d-%d\", work.Offset, work.Offset+work.Size)\n\t\t\tlog.Print(\"Running Map function on input data...\")\n\t\t\t// Load data\n\t\t\tdb, err := sql.Open(\"sqlite3\", work.Filename)\n\t\t\tif err != nil {\n\t\t\t\tlog.Println(err)\n\t\t\t\tfailure(\"sql.Open\")\n\t\t\t\treturn err\n\t\t\t}\n\t\t\tdefer db.Close()\n\n\n\t\t\t// Query\n\t\t\trows, err := db.Query(fmt.Sprintf(\"select key, value from %s limit %d offset %d;\", work.Table, work.Size, work.Offset))\n\t\t\tif err != nil {\n\t\t\t\tlog.Println(err)\n\t\t\t\tfailure(\"sql.Query1\")\n\t\t\t\treturn err\n\t\t\t}\n\t\t\tdefer rows.Close()\n\n\t\t\tfor rows.Next() {\n\t\t\t\tvar key string\n\t\t\t\tvar value string\n\t\t\t\trows.Scan(&key, &value)\n\n\t\t\t\t// TODO: TURN OFF JOURNALING\n\t\t\t\t//out.DB.Exec(\"pragma synchronous = off\");\n\t\t\t\t//out.DB.Exec(\"pragma journal_mode = off\")\n\n\t\t\t\t//TODO: CREATE INDEXES ON EACH DB SO ORDER BY WORKS FASTER\n\n\t\t\t\t// Temp storage\n\t\t\t\t// Each time the map function emits a key/value pair, you should figure out which reduce task that pair will go to.\n\t\t\t\treducer := big.NewInt(0)\n\t\t\t\treducer.Mod(hash(key), big.NewInt(int64(work.R)))\n\t\t\t\t//db_tmp, err := sql.Open(\"sqlite3\", fmt.Sprintf(\"/tmp/map_output/%d/map_out_%d.sql\", work.WorkerID, reducer.Int64())) //TODO: Directories don't work\n\t\t\t\tdb_tmp, err := sql.Open(\"sqlite3\", fmt.Sprintf(\"/tmp/squinn/map_%d_out_%d.sql\", work.WorkerID, reducer.Int64()))\n\t\t\t\tif err != nil {\n\t\t\t\t\tlog.Println(err)\n\t\t\t\t\tfailure(fmt.Sprintf(\"sql.Open - /tmp/map_output/%d/map_out_%d.sql\", work.WorkerID, reducer.Int64()))\n\t\t\t\t\treturn err\n\t\t\t\t}\n\n\n\t\t\t\t// Prepare tmp database\n\t\t\t\tsqls := []string{\n\t\t\t\t\t\"create table if not exists data (key text not null, value text not null)\",\n\t\t\t\t\t\"create index if not exists data_key on data (key asc, value asc);\",\n\t\t\t\t\t\"pragma synchronous = off;\",\n\t\t\t\t\t\"pragma journal_mode = off;\",\n\t\t\t\t}\n\t\t\t\tfor _, sql := range sqls {\n\t\t\t\t\t_, err = db_tmp.Exec(sql)\n\t\t\t\t\tif err != nil {\n\t\t\t\t\t\tfailure(\"sql.Exec3\")\n\t\t\t\t\t\tfmt.Printf(\"%q: %s\\n\", err, sql)\n\t\t\t\t\t\treturn err\n\t\t\t\t\t}\n\t\t\t\t}\n\n\n\t\t\t\t//type MapFunc func(key, value string, output chan<- Pair) error\n\t\t\t\toutChan := make(chan Pair)\n\t\t\t\tgo func() {\n\t\t\t\t\terr = mapFunc(key, value, outChan)\n\t\t\t\t\tif err != nil {\n\t\t\t\t\t\tfailure(\"mapFunc\")\n\t\t\t\t\t\tlog.Println(err)\n\t\t\t\t\t\t//return err\n\t\t\t\t\t}\n\t\t\t\t}()\n\n\n\t\t\t\t// Get the output from the map function's output channel\n\t\t\t\t//var pairs []Pair\n\t\t\t\tpair := <-outChan\n\t\t\t\tfor pair.Key != \"\" {\n\t\t\t\t\tkey, value = pair.Key, pair.Value\n\t\t\t\t\t// Write the data locally\n\t\t\t\t\tsql := fmt.Sprintf(\"insert into data values ('%s', '%s');\", key, value)\n\t\t\t\t\t_, err = db_tmp.Exec(sql)\n\t\t\t\t\tif err != nil {\n\t\t\t\t\t\tfailure(\"sql.Exec4\")\n\t\t\t\t\t\tfmt.Printf(\"map_%d_out_%d.sql\\n\", work.WorkerID, reducer.Int64())\n\t\t\t\t\t\tfmt.Println(key, value)\n\t\t\t\t\t\tlog.Printf(\"%q: %s\\n\", err, sql)\n\t\t\t\t\t\treturn err\n\t\t\t\t\t}\n\t\t\t\t\t//log.Println(key, value)\n\t\t\t\t\tpair = <-outChan\n\t\t\t\t}\n\t\t\t\tdb_tmp.Close()\n\t\t\t}\n\n\t\t\tmyAddress = net.JoinHostPort(GetLocalAddress(), fmt.Sprintf(\"%d\", 4000+work.WorkerID))\n\t\t\t// Serve the files so each reducer can get them\n\t\t\t// /tmp/map_output/%d/tmp_map_out_%d.sql\n\t\t\tgo func(address string) {\n\t\t\t\t// (4000 + work.WorkerID)\n\t\t\t\t//http.Handle(\"/map_out_files/\", http.FileServer(http.Dir(fmt.Sprintf(\"/tmp/map_output/%d\", work.WorkerID)))) //TODO: Directories don't work\n\t\t\t\t//fileServer := http.FileServer(http.Dir(\"/Homework/3410/mapreduce/\"))\n\t\t\t\tfileServer := http.FileServer(http.Dir(\"/tmp/squinn/\"))\n\t\t\t\tlog.Println(\"Listening on \" + address)\n\t\t\t\tlog.Fatal(http.ListenAndServe(address, fileServer))\n\t\t\t}(myAddress)\n\t\t} else if resp.Type == TYPE_REDUCE {\n\t\t\tlogf(\"REDUCE ID: %d\", work.WorkerID)\n\t\t\t//type ReduceFunc func(key string, values <-chan string, output chan<- Pair) error\n\t\t\t// Load each input file one at a time (copied from each map task)\n\t\t\tvar filenames []string\n\t\t\tfor i, mapper := range work.MapAddresses {\n\t\t\t\t//res, err := http.Get(fmt.Sprintf(\"%d:/tmp/map_output/%d/map_out_%d.sql\", 4000+i, i, work.WorkerID)) //TODO: Directories don't work\n\t\t\t\t//map_file := fmt.Sprintf(\"http://localhost:%d/map_%d_out_%d.sql\", 4000+i, i, work.WorkerID)\n\t\t\t\tmap_file := fmt.Sprintf(\"http://%s/map_%d_out_%d.sql\", mapper, i, work.WorkerID)\n\n\t\t\t\tres, err := http.Get(map_file)\n\t\t\t\tif err != nil {\n\t\t\t\t\tfailure(\"http.Get\")\n\t\t\t\t\tlog.Fatal(err)\n\t\t\t\t}\n\n\t\t\t\tfile, err := ioutil.ReadAll(res.Body)\n\t\t\t\tres.Body.Close()\n\t\t\t\tif err != nil {\n\t\t\t\t\tfailure(\"ioutil.ReadAll\")\n\t\t\t\t\tlog.Fatal(err)\n\t\t\t\t}\n\n\t\t\t\tfilename := fmt.Sprintf(\"/tmp/squinn/map_out_%d_mapper_%d.sql\", work.WorkerID, i)\n\t\t\t\tfilenames = append(filenames, filename)\n\n\t\t\t\terr = ioutil.WriteFile(filename, file, 0777)\n\t\t\t\tif err != nil {\n\t\t\t\t\tfailure(\"file.Write\")\n\t\t\t\t\tlog.Fatal(err)\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t// Combine all the rows into a single input file\n\t\t\tsqls := []string{\n\t\t\t\t\"create table if not exists data (key text not null, value text not null)\",\n\t\t\t\t\"create index if not exists data_key on data (key asc, value asc);\",\n\t\t\t\t\"pragma synchronous = off;\",\n\t\t\t\t\"pragma journal_mode = off;\",\n\t\t\t}\n\n\t\t\tfor _, file := range filenames {\n\t\t\t\tdb, err := sql.Open(\"sqlite3\", file)\n\t\t\t\tif err != nil {\n\t\t\t\t\tlog.Println(err)\n\t\t\t\t\tcontinue\n\t\t\t\t}\n\t\t\t\tdefer db.Close()\n\n\t\t\t\trows, err := db.Query(\"select key, value from data;\",)\n\t\t\t\tif err != nil {\n\t\t\t\t\tfmt.Println(err)\n\t\t\t\t\tcontinue\n\t\t\t\t}\n\t\t\t\tdefer rows.Close()\n\n\t\t\t\tfor rows.Next() {\n\t\t\t\t\tvar key string\n\t\t\t\t\tvar value string\n\t\t\t\t\trows.Scan(&key, &value)\n\t\t\t\t\tsqls = append(sqls, fmt.Sprintf(\"insert into data values ('%s', '%s');\", key, value))\n\t\t\t\t}\n\t\t\t}\n\n\t\t\treduce_db, err := sql.Open(\"sqlite3\", fmt.Sprintf(\"/tmp/squinn/reduce_aggregate_%d.sql\", work.WorkerID))\n\t\t\tfor _, sql := range sqls {\n\t\t\t\t_, err = reduce_db.Exec(sql)\n\t\t\t\tif err != nil {\n\t\t\t\t\tfmt.Printf(\"%q: %s\\n\", err, sql)\n\t\t\t\t}\n\t\t\t}\n\t\t\treduce_db.Close()\n\n\t\t\treduce_db, err = sql.Open(\"sqlite3\", fmt.Sprintf(\"/tmp/squinn/reduce_aggregate_%d.sql\", work.WorkerID))\n\t\t\tdefer reduce_db.Close()\n\t\t\trows, err := reduce_db.Query(\"select key, value from data order by key asc;\")\n\t\t\tif err != nil {\n\t\t\t\tlog.Println(err)\n\t\t\t\tfailure(\"sql.Query2\")\n\t\t\t\treturn err\n\t\t\t}\n\t\t\tdefer rows.Close()\n\n\t\t\tvar key string\n\t\t\tvar value string\n\t\t\trows.Next()\n\t\t\trows.Scan(&key, &value)\n\n\t\t\t//type ReduceFunc func(key string, values <-chan string, output chan<- Pair) error\n\t\t\tinChan := make(chan string)\n\t\t\toutChan := make(chan Pair)\n\t\t\tgo func() {\n\t\t\t\terr = reduceFunc(key, inChan, outChan)\n\t\t\t\tif err != nil {\n\t\t\t\t\tfailure(\"reduceFunc\")\n\t\t\t\t\tlog.Println(err)\n\t\t\t\t}\n\t\t\t}()\n\t\t\tinChan <- value\n\t\t\tcurrent := key\n\n\t\t\tvar outputPairs []Pair\n\t\t\t// Walk through the file's rows, performing the reduce func\n\t\t\tfor rows.Next() {\n\t\t\t\trows.Scan(&key, &value)\n\t\t\t\tif key == current {\n\t\t\t\t\tinChan <- value\n\t\t\t\t} else {\n\t\t\t\t\tclose(inChan)\n\t\t\t\t\tp := <-outChan\n\t\t\t\t\toutputPairs = append(outputPairs, p)\n\n\t\t\t\t\tinChan = make(chan string)\n\t\t\t\t\toutChan = make(chan Pair)\n\t\t\t\t\tgo func() {\n\t\t\t\t\t\terr = reduceFunc(key, inChan, outChan)\n\t\t\t\t\t\tif err != nil {\n\t\t\t\t\t\t\tfailure(\"reduceFunc\")\n\t\t\t\t\t\t\tlog.Println(err)\n\t\t\t\t\t\t}\n\t\t\t\t\t}()\n\t\t\t\t\tinChan <- value\n\t\t\t\t\tcurrent = key\n\t\t\t\t}\n\t\t\t}\n\t\t\tclose(inChan)\n\t\t\tp := <-outChan\n\t\t\toutputPairs = append(outputPairs, p)\n\n\t\t\t// Prepare tmp database\n\t\t\t// TODO: Use the command line parameter output\n\t\t\t//db_out, err := sql.Open(\"sqlite3\", fmt.Sprintf(\"/home/s/squinn/tmp/reduce_out_%d.sql\", work.WorkerID))\n\t\t\t//db_out, err := sql.Open(\"sqlite3\", fmt.Sprintf(\"/Users/Ren/tmp/reduce_out_%d.sql\", work.WorkerID))\n\t\t\tdb_out, err := sql.Open(\"sqlite3\", fmt.Sprintf(\"%s/reduce_out_%d.sql\", output, work.WorkerID))\n\t\t\tdefer db_out.Close()\n\t\t\tif err != nil {\n\t\t\t\tlog.Println(err)\n\t\t\t\tfailure(fmt.Sprintf(\"sql.Open - reduce_out_%d.sql\", work.WorkerID))\n\t\t\t\treturn err\n\t\t\t}\n\t\t\tsqls = []string{\n\t\t\t\t\"create table if not exists data (key text not null, value text not null)\",\n\t\t\t\t\"create index if not exists data_key on data (key asc, value asc);\",\n\t\t\t\t\"pragma synchronous = off;\",\n\t\t\t\t\"pragma journal_mode = off;\",\n\t\t\t}\n\t\t\tfor _, sql := range sqls {\n\t\t\t\t_, err = db_out.Exec(sql)\n\t\t\t\tif err != nil {\n\t\t\t\t\tfailure(\"sql.Exec5\")\n\t\t\t\t\tfmt.Printf(\"%q: %s\\n\", err, sql)\n\t\t\t\t\treturn err\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t// Write the data locally\n\t\t\tfor _, op := range outputPairs {\n\t\t\t\tsql := fmt.Sprintf(\"insert into data values ('%s', '%s');\", op.Key, op.Value)\n\t\t\t\t_, err = db_out.Exec(sql)\n\t\t\t\tif err != nil {\n\t\t\t\t\tfailure(\"sql.Exec6\")\n\t\t\t\t\tfmt.Printf(\"%q: %s\\n\", err, sql)\n\t\t\t\t\treturn err\n\t\t\t\t}\n\t\t\t}\n\t\t} else if resp.Type == TYPE_DONE {\n\t\t} else {\n\t\t\tlog.Println(\"INVALID WORK TYPE\")\n\t\t\tvar err error\n\t\t\treturn err\n\t\t}\n\n\n\n\t\t/*\n\t\t * Notify the master when I'm done\n\t\t */\n\n\t\treq.Type = resp.Type\n\t\treq.Address = myAddress\n\t\terr = call(master, \"Notify\", req, &resp)\n\t\tif err != nil {\n\t\t\tfailure(\"Notify\")\n\t\t\ttasks_run++\n\t\t\tcontinue\n\t\t}\n\n\t\tif resp.Message == WORK_DONE {\n\t\t\tlog.Println(\"Notified - Finished Working\")\n\t\t\tlog.Println(\"Waiting for word from master to clean up...\")\n\t\t\t// TODO: Wait for word from master\n\n\t\t\t//CleanUp\n\t\t\t/*\n\t\t\tos.Remove(\"aggregate.sql\")\n\t\t\tfor r:=0; r<work.R; r++ {\n\t\t\t\tfor m:=0; m<work.M; m++ {\n\t\t\t\t\tos.Remove(fmt.Sprintf(\"map_%d_out_%d.sql\", m, r))\n\t\t\t\t\tos.Remove(fmt.Sprintf(\"map_out_%d_mapper_%d.sql\", r, m))\n\t\t\t\t}\n\t\t\t\tos.Remove(fmt.Sprintf(\"reduce_aggregate_%d.sql\", r))\n\t\t\t}\n\t\t\t*/\n\t\t\tos.RemoveAll(\"/tmp/squinn\")\n\t\t\treturn nil\n\t\t}\n\t\ttasks_run++\n\n\t}\n\n\treturn nil\n}", "func (syncObj *Sync)JoinAllRoutines() {\n syncObj.appWaitGroups.Wait()\n\n}", "func init() {\n\tgrs = 2\n\truntime.GOMAXPROCS(runtime.NumCPU())\n}", "func main() {\n\n\t// If invalid arguments then print usage statement.\n\tif len(os.Args) < 1 || len(os.Args) > 2 {\n\n\t\tprintUsage()\n\n\t} else if len(os.Args) == 2 { // Run parallel version.\n\t\t\n\t\tthreads, _ := strconv.Atoi(strings.Split(os.Args[1],\"=\")[1])\n\t\truntime.GOMAXPROCS(threads)\n\t\timageTasks := make(chan *imagetask.ImageTask)\n\t\timageResults := make(chan *imagetask.ImageTask)\n\t\tdoneWorker := make(chan bool)\n\t\tdoneSave := make(chan bool)\n\n\t\t// Read from standard input (initial generator).\n\t\t// Image tasks go to imageTasks channel which is consumed by multiple workers (fan out).\n\t\tgo func() {\n\t\t\tscanner := bufio.NewScanner(os.Stdin)\n\t\t\tfor scanner.Scan() {\n\t\t\t\timageTaskText := scanner.Text()\n\t\t\t\timgTask := imagetask.CreateImageTask(imageTaskText)\n\t\t\t\timageTasks <- imgTask\n\t\t\t}\n\t\t\tclose(imageTasks)\n\t\t}()\n\n\t\t// Spawn worker goroutines to split up images, filter the portions, and recombine images.\n\t\tfor i := 0; i < threads; i++ {\n\t\t\tgo worker(threads, doneWorker, imageTasks, imageResults)\n\t\t}\n\n\t\t// Save results.\n\t\tgo func() {\n\t\t\tfor true { // Do while there are more images to save.\n\t\t\t\timgTask, more := <- imageResults // Reads from the image results channel.\n\t\t\t\tif more {\n\t\t\t\t\timgTask.SaveImageTaskOut()\n\t\t\t\t} else {\n\t\t\t\t\tdoneSave <- true \n\t\t\t\t\treturn\n\t\t\t\t}\n\t\t\t}\n\t\t}()\n\n\t\t// Wait for all workers to return.\n\t\tfor i := 0; i < threads; i++ {\n\t\t\t<-doneWorker\n\t\t}\n\n\t\t// Wait for all images to be saved.\n\t\tclose(imageResults)\n\t\t<- doneSave\n\n\t} else { // Run sequential version if '-p' flag not given.\n\n\t\t// Read in image tasks from standard input.\n\t\tscanner := bufio.NewScanner(os.Stdin)\n\t\tfor scanner.Scan() {\n\t\t\timageTaskText := scanner.Text()\n\t\t\timgTask := imagetask.CreateImageTask(imageTaskText)\n\n\t\t\t// Apply the specified effects to the given image.\n\t\t\tfor i, effect := range imgTask.Effects {\n\t\t\t\tif i > 0 {\n\t\t\t\t\timgTask.Img.UpdateInImg()\n\t\t\t\t}\n\t\t\t\tif effect != \"G\" {\n\t\t\t\t\timgTask.Img.ApplyConvolution(effect)\n\t\t\t\t} else {\n\t\t\t\t\timgTask.Img.Grayscale()\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t// Save filtered image.\n\t\t\timgTask.SaveImageTaskOut()\n\n\t\t}\n\n\t}\n\n}", "func (lbs *LoadBasedAlg) computeNumTasksToStart(numIdleWorkers int) {\n\n\tvar haveUnallocatedTasks bool\n\n\tnumIdleWorkers, haveUnallocatedTasks = lbs.entitlementTasksToStart(numIdleWorkers)\n\n\tif numIdleWorkers > 0 && haveUnallocatedTasks {\n\t\tlbs.workerLoanAllocation(numIdleWorkers, false)\n\t}\n}", "func testParallelismWithBeverages(bm *BeverageMachine, beverageNames []string) {\n\n\tfmt.Printf(\"\\nstarting test: testParallelismWithBeverages\\n\\n\")\n\n\twg := sync.WaitGroup{}\n\tfor i, beverageName := range beverageNames {\n\t\twg.Add(1)\n\t\tgo func(i int, beverageName string) {\n\t\t\tdefer wg.Done()\n\n\t\t\tfmt.Printf(\"thread %d-> start\\n\", i+1)\n\n\t\t\t//1. get an idle dispenser\n\t\t\tdispenser, err := bm.GetIdleDispenser()\n\t\t\tfor err != nil {\n\t\t\t\tfmt.Printf(\"thread %d-> %s, retrying in 2 seconds...\\n\", i+1, err.Error())\n\t\t\t\ttime.Sleep(2 * time.Second)\n\t\t\t\tdispenser, err = bm.GetIdleDispenser()\n\t\t\t}\n\t\t\tfmt.Printf(\"thread %d-> acquired dispenser %d\\n\", i+1, dispenser.GetId())\n\n\t\t\tfmt.Printf(\"thread %d-> starting to prepare %s on dispenser %d...\\n\", i+1, beverageName, dispenser.GetId())\n\n\t\t\t//2. request the beverage from the dispenser\n\t\t\tbeverage, err := bm.RequestBeverage(dispenser, beverageName)\n\t\t\tif err != nil {\n\t\t\t\tfmt.Printf(\"thread %d-> dispenser %d says: %s\\n\", i+1, dispenser.GetId(), err.Error())\n\t\t\t\tfmt.Printf(\"thread %d-> end\\n\", i+1)\n\t\t\t\treturn\n\t\t\t}\n\n\t\t\tfmt.Printf(\"thread %d-> successfully served %s on dispenser %d\\n\", i+1, beverage.GetName(), dispenser.GetId())\n\t\t\tfmt.Printf(\"thread %d-> end\\n\", i+1)\n\t\t}(i, beverageName)\n\t}\n\twg.Wait()\n\n\tfmt.Println(\"\\ncompleted test: testParallelismWithBeverages\\n\")\n}", "func main() {\n\tif len(os.Args) < 4 {\n\t\tfmt.Printf(\"%s: see usage comments in file\\n\", os.Args[0])\n\t} else if os.Args[1] == \"master\" {\n\t\tvar mr *mapreduce.Master\n\t\tif os.Args[2] == \"sequential\" {\n\t\t\tmr = mapreduce.Sequential(\"iiseq\", os.Args[3:], 3, mapF, reduceF)\n\t\t} else {\n\t\t\tmr = mapreduce.Distributed(\"iiseq\", os.Args[3:], 3, os.Args[2])\n\t\t}\n\t\tmr.Wait()\n\t} else {\n\t\tmapreduce.RunWorker(os.Args[2], os.Args[3], mapF, reduceF, 100)\n\t}\n}", "func main() {\n\tif len(os.Args) < 4 {\n\t\tfmt.Printf(\"%s: see usage comments in file\\n\", os.Args[0])\n\t} else if os.Args[1] == \"master\" {\n\t\tvar mr *mapreduce.Master\n\t\tif os.Args[2] == \"sequential\" {\n\t\t\tmr = mapreduce.Sequential(\"iiseq\", os.Args[3:], 3, mapF, reduceF)\n\t\t} else {\n\t\t\tmr = mapreduce.Distributed(\"iiseq\", os.Args[3:], 3, os.Args[2])\n\t\t}\n\t\tmr.Wait()\n\t} else {\n\t\tmapreduce.RunWorker(os.Args[2], os.Args[3], mapF, reduceF, 100)\n\t}\n}", "func createWorkerPool(count int, queue chan common.ServiceRegistration, done chan<- bool) {\n\tvar waitGroup sync.WaitGroup\n\twaitGroup.Add(count)\n\tfor i := 0; i < count; i++ {\n\t\tgo func(c *opslevel.Client, q chan common.ServiceRegistration, wg *sync.WaitGroup) {\n\t\t\tfor data := range q {\n\t\t\t\treconcileService(c, data)\n\t\t\t}\n\t\t\twg.Done()\n\t\t}(common.NewClient(), queue, &waitGroup)\n\t}\n\twaitGroup.Wait()\n\tdone <- true\n}", "func main() {\n\tif len(os.Args) < 4 {\n\t\tfmt.Printf(\"%s: see usage comments in file\\n\", os.Args[0])\n\t} else if os.Args[1] == \"master\" {\n\t\tvar mr *mapreduce.Master\n\t\tif os.Args[2] == \"sequential\" {\n\t\t\tmr = mapreduce.Sequential(\"iiseq\", os.Args[3:], 3, mapF, reduceF)\n\t\t} else {\n\t\t\tmr = mapreduce.Distributed(\"iiseq\", os.Args[3:], 3, os.Args[2])\n\t\t}\n\t\tmr.Wait()\n\t} else {\n\t\tmapreduce.RunWorker(os.Args[2], os.Args[3], mapF, reduceF, 100, nil)\n\t}\n}", "func newCluster(computeNames ...string) *clusteroperator.Cluster {\n\tcomputes := make([]clusteroperator.ClusterMachineSet, len(computeNames))\n\tfor i, computeName := range computeNames {\n\t\tcomputes[i] = clusteroperator.ClusterMachineSet{\n\t\t\tName: computeName,\n\t\t\tMachineSetConfig: clusteroperator.MachineSetConfig{\n\t\t\t\tSize: 1,\n\t\t\t\tNodeType: clusteroperator.NodeTypeCompute,\n\t\t\t},\n\t\t}\n\t}\n\treturn newClusterWithSizes(1, computes...)\n}", "func (s *ParallelVolumeCreateTestSuite) parallelVolumeCreation(noOfVolumes int, c *C) {\n\tvar wg sync.WaitGroup\n\tfor i := 0; i < noOfVolumes; i++ {\n\t\twg.Add(1)\n\t\tgo func(i int) {\n\t\t\tdefer wg.Done()\n\t\t\tvolName := inputparams.GetUniqueVolumeName(fmt.Sprintf(\"%s%d\", \"pVol_\", i))\n\t\t\ts.createVolCheck(volName, c)\n\t\t}(i)\n\t}\n\twg.Wait()\n}", "func bootstrap(ctx context.Context, cluster *ipfscluster.Cluster, bootstraps []ma.Multiaddr) {\n\tfor _, bstrap := range bootstraps {\n\t\tlogger.Infof(\"Bootstrapping to %s\", bstrap)\n\t\terr := cluster.Join(ctx, bstrap)\n\t\tif err != nil {\n\t\t\tlogger.Errorf(\"bootstrap to %s failed: %s\", bstrap, err)\n\t\t}\n\t}\n}", "func (g *GardenerAPI) RunAll(ctx context.Context, rSrc RunnableSource, jt *tracker.JobWithTarget) (*errgroup.Group, error) {\n\teg := &errgroup.Group{}\n\tcount := 0\n\tjob := jt.Job\n\tfor {\n\t\trun, err := rSrc.Next(ctx)\n\t\tif err != nil {\n\t\t\tif err == iterator.Done {\n\t\t\t\tdebug.Printf(\"Dispatched total of %d archives for %s\\n\", count, job.String())\n\t\t\t\treturn eg, nil\n\t\t\t} else {\n\t\t\t\tmetrics.BackendFailureCount.WithLabelValues(\n\t\t\t\t\tjob.Datatype, \"rSrc.Next\").Inc()\n\t\t\t\tlog.Println(err, \"processing\", job.String())\n\t\t\t\treturn eg, err\n\t\t\t}\n\t\t}\n\n\t\tif err := g.jobs.Heartbeat(ctx, jt.ID); err != nil {\n\t\t\tlog.Println(err, \"on heartbeat for\", job.Path())\n\t\t}\n\n\t\tdebug.Println(\"Starting func\")\n\n\t\tf := func() (err error) {\n\t\t\tmetrics.ActiveTasks.WithLabelValues(rSrc.Label()).Inc()\n\t\t\tdefer metrics.ActiveTasks.WithLabelValues(rSrc.Label()).Dec()\n\n\t\t\t// Capture any panic and convert it to an error.\n\t\t\tdefer func(tag string) {\n\t\t\t\tif err2 := metrics.PanicToErr(err, recover(), \"Runall.f: \"+tag); err2 != nil {\n\t\t\t\t\terr = err2\n\t\t\t\t}\n\t\t\t}(run.Info())\n\n\t\t\terr = run.Run(ctx)\n\t\t\tif err == nil {\n\t\t\t\tif err := g.jobs.Update(ctx, jt.ID, tracker.Parsing, run.Info()); err != nil {\n\t\t\t\t\tlog.Println(err, \"on update for\", job.Path())\n\t\t\t\t}\n\t\t\t}\n\t\t\treturn\n\t\t}\n\n\t\tcount++\n\t\teg.Go(f)\n\t}\n}", "func execTasks(parent context.Context, c TimedActuator,\n\texecFunc func(f func()), tasks ...Task) error {\n\tsize := len(tasks)\n\tif size == 0 {\n\t\treturn nil\n\t}\n\n\tctx, cancel := context.WithCancel(parent)\n\tresChan := make(chan error, size)\n\twg := &sync.WaitGroup{}\n\twg.Add(size)\n\n\t// Make sure the tasks are completed and channel is closed\n\tgo func() {\n\t\twg.Wait()\n\t\tcancel()\n\t\tclose(resChan)\n\t}()\n\n\t// Sadly we can not kill a goroutine manually\n\t// So when an error happens, the other tasks will continue\n\t// But the good news is that main progress\n\t// will know the error immediately\n\tfor _, task := range tasks {\n\t\tchild, _ := context.WithCancel(ctx)\n\t\tf := wrapperTask(child, task, wg, resChan)\n\t\texecFunc(f)\n\t}\n\n\treturn wait(ctx, c, resChan, cancel)\n}", "func (s *Services) SpawnWorkerThreads(threads int) {\n\n\tfor i := 0; i < threads; i++ {\n\t\tgo Listener(s)\n\t}\n\n\treturn\n}", "func (r *Runner) startWorkers(n int) {\n\t// Make some sessions to start\n\tfor i := 0; i < n; i++ {\n\t\tr.makeSession()\n\t}\n}", "func (b *Builder) Run() []error {\n\t//Check for prvious mesh\n\tif b.localInstances.Len() > 0 {\n\t\treturn []error{\n\t\t\tfmt.Errorf(\"mesh was already run\"),\n\t\t}\n\t}\n\n\t//Create the processors mesh and cleanup on error\n\tif err := b.createProcessorsMesh(); err != nil {\n\t\tb.clearMesh()\n\t\treturn []error{\n\t\t\terr,\n\t\t}\n\t}\n\n\t//Run the processors\n\terrors := []error{}\n\tfor entry := b.localInstances.Front(); entry != nil; entry = entry.Next() {\n\t\tif info, ok := (entry.Value).(*ProcessorInfo); !ok {\n\t\t\terrors = append(errors, fmt.Errorf(\"unexpected processor info entry in instances map\"))\n\t\t} else if err := info.instance.Run(); err != nil {\n\t\t\terrors = append(errors, err)\n\t\t}\n\t}\n\treturn errors\n}", "func (m *workerManager) startWorkers(ctx context.Context, count int) {\n\tm.logger.Debug(\"Starting %d Global Bus workers\", count)\n\tfor i := 0; i < count; i++ {\n\t\tm.startWorker(ctx)\n\t}\n}", "func TestStartAllWorkloads(t *testing.T) {\n\tctx, cancelFunc := context.WithTimeout(context.Background(), standardTimeout)\n\tdefer cancelFunc()\n\n\tworkloads, err := bat.GetAllWorkloads(ctx, \"\")\n\tif err != nil {\n\t\tt.Fatalf(\"Unable to retrieve workloads %v\", err)\n\t}\n\n\tinstances := make([]string, 0, len(workloads))\n\tfor _, wkl := range workloads {\n\t\tlaunched, err := bat.LaunchInstances(ctx, \"\", wkl.ID, 1)\n\t\tif err != nil {\n\t\t\tt.Errorf(\"Unable to launch instance for workload %s : %v\",\n\t\t\t\twkl.ID, err)\n\t\t\tcontinue\n\t\t}\n\t\tscheduled, err := bat.WaitForInstancesLaunch(ctx, \"\", launched, true)\n\t\tif err != nil {\n\t\t\tt.Errorf(\"Instance %s did not launch correctly : %v\", launched[0], err)\n\t\t}\n\t\tinstances = append(instances, scheduled...)\n\t}\n\n\t_, err = bat.DeleteInstances(ctx, \"\", instances)\n\tif err != nil {\n\t\tt.Errorf(\"Failed to delete instances: %v\", err)\n\t}\n}", "func startServers(t *testing.T) [N]*os.Process {\n\tkvsd, err := exec.LookPath(\"kvsd\")\n\tfmt.Println(\"kvsd:\" + kvsd)\n\tif err != nil {\n\t\tt.Fatal(\"kvsd not in $PATH; kvsd needs to be installed before running this test\")\n\t}\n\targv := []string{\n\t\t\"-id\",\n\t\t\"1\",\n\t\t\"-v=3\",\n\t\t\"-log_dir=\" + KVS + \"kvsd/log/\",\n\t\t\"-all-cores\",\n\t\t\"-config-file\",\n\t\tcfg,\n\t}\n\tvar proc [N]*os.Process\n\n\t// start N servers\n\tfor i := 0; i < N; i++ {\n\t\targv[1] = strconv.Itoa(i)\n\t\tcmd := exec.Command(kvsd, argv...)\n\t\t//cmd.Dir = os.Getenv(\"GOPATH\") + \"src\\\\github.com\\\\relab\\\\goxos\\\\kvs\\\\kvsd\"\n\t\terr := cmd.Start()\n\t\tif err != nil {\n\t\t\tt.Fatal(\"Failed to start kvsd:\", err)\n\t\t}\n\t\tproc[i] = cmd.Process\n\t}\n\treturn proc\n}", "func (c *Coordinator) run(ctx context.Context) error {\n\tminRemoteClientsPerGame := 1\n\tmaxRemoteClientsPerGame := 10\n\tfor {\n\t\tclients, err := c.awaitRemoteClients(ctx, minRemoteClientsPerGame, maxRemoteClientsPerGame)\n\t\tif err != nil {\n\t\t\treturn errors.Wrap(err, \"error awaiting remote clients\")\n\t\t}\n\n\t\t// Add a couple of AI clients.\n\t\tnumAIClients := 4 - len(clients)\n\t\tif numAIClients <= 0 {\n\t\t\tnumAIClients = 1\n\t\t}\n\t\tfor i := 0; i < numAIClients; i++ {\n\t\t\tvar aiClient *ai.Client\n\t\t\tvar err error\n\t\t\tif i%3 == 2 {\n\t\t\t\taiClient, err = ai.NewClient(c.logEntry.Logger, ai.RandomStrategy(rand.Int63n(30)+2))\n\t\t\t} else {\n\t\t\t\taiClient, err = ai.NewClient(c.logEntry.Logger, ai.OpportunisticStrategy())\n\t\t\t}\n\t\t\tif err != nil {\n\t\t\t\treturn errors.Wrap(err, \"error creating ai client\")\n\t\t\t}\n\t\t\tclients = append(clients, aiClient)\n\t\t}\n\n\t\tc.logEntry.Debug(\"Starting a new game\")\n\t\terr = c.startGame(ctx, clients)\n\t\tif err != nil {\n\t\t\t// As we still own the clients here, make sure we stop them\n\t\t\t// before quiting ourselves.\n\t\t\tdisconnectAll(clients)\n\t\t\treturn errors.Wrap(err, \"Error starting game\")\n\t\t}\n\t}\n}", "func (c *ComputeCollector) Collect(ch chan<- prometheus.Metric) {\n\tctx := context.Background()\n\tcomputeService, err := compute.NewService(ctx)\n\tif err != nil {\n\t\tlog.Println(err)\n\t\treturn\n\t}\n\n\t// Enumerate all of the projects\n\tvar wg sync.WaitGroup\n\tfor _, p := range c.account.Projects {\n\t\twg.Add(1)\n\t\tgo func(p *cloudresourcemanager.Project) {\n\t\t\tdefer wg.Done()\n\t\t\tlog.Printf(\"[ComputeCollector] Project: %s\", p.ProjectId)\n\n\t\t\twg.Add(1)\n\t\t\tgo func(p *cloudresourcemanager.Project) {\n\t\t\t\tdefer wg.Done()\n\t\t\t\t// Compute Engine API instances.list requires zone\n\t\t\t\t// Must repeat the call for all possible zones\n\t\t\t\tzoneList, err := computeService.Zones.List(p.ProjectId).Context(ctx).Do()\n\t\t\t\tif err != nil {\n\t\t\t\t\tif e, ok := err.(*googleapi.Error); ok {\n\t\t\t\t\t\tlog.Printf(\"[ComputeCollector] Project: %s -- Zones.List (%d)\", p.ProjectId, e.Code)\n\t\t\t\t\t}\n\t\t\t\t\treturn\n\t\t\t\t}\n\t\t\t\tfor _, z := range zoneList.Items {\n\t\t\t\t\twg.Add(1)\n\t\t\t\t\tgo func(z *compute.Zone) {\n\t\t\t\t\t\tdefer wg.Done()\n\t\t\t\t\t\trqst := computeService.Instances.List(p.ProjectId, z.Name).MaxResults(500)\n\t\t\t\t\t\tcount := 0\n\t\t\t\t\t\t// Page through more results\n\t\t\t\t\t\tif err := rqst.Pages(ctx, func(page *compute.InstanceList) error {\n\t\t\t\t\t\t\tcount += len(page.Items)\n\t\t\t\t\t\t\t// for _, instance := range page.Items {\n\t\t\t\t\t\t\t// \tinstance.\n\t\t\t\t\t\t\t// }\n\t\t\t\t\t\t\treturn nil\n\t\t\t\t\t\t}); err != nil {\n\t\t\t\t\t\t\tlog.Println(err)\n\t\t\t\t\t\t\treturn\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif count != 0 {\n\t\t\t\t\t\t\tch <- prometheus.MustNewConstMetric(\n\t\t\t\t\t\t\t\tc.Instances,\n\t\t\t\t\t\t\t\tprometheus.GaugeValue,\n\t\t\t\t\t\t\t\tfloat64(count),\n\t\t\t\t\t\t\t\t[]string{\n\t\t\t\t\t\t\t\t\tp.ProjectId,\n\t\t\t\t\t\t\t\t\tz.Name,\n\t\t\t\t\t\t\t\t}...,\n\t\t\t\t\t\t\t)\n\t\t\t\t\t\t}\n\t\t\t\t\t}(z)\n\t\t\t\t}\n\t\t\t}(p)\n\n\t\t\twg.Add(1)\n\t\t\tgo func(p *cloudresourcemanager.Project) {\n\t\t\t\tdefer wg.Done()\n\t\t\t\t// Compute Engine API forwardingrules.list requires region\n\t\t\t\t// Must repeat call for all possible regions\n\t\t\t\tregionList, err := computeService.Regions.List(p.ProjectId).Context(ctx).Do()\n\t\t\t\tif err != nil {\n\t\t\t\t\tif e, ok := err.(*googleapi.Error); ok {\n\t\t\t\t\t\tlog.Printf(\"[ComputeCollector] Project: %s -- Regions.List (%d)\", p.ProjectId, e.Code)\n\t\t\t\t\t} else {\n\t\t\t\t\t\tlog.Println(err)\n\t\t\t\t\t}\n\t\t\t\t\treturn\n\t\t\t\t}\n\t\t\t\tfor _, r := range regionList.Items {\n\t\t\t\t\twg.Add(1)\n\t\t\t\t\tgo func(r *compute.Region) {\n\t\t\t\t\t\tdefer wg.Done()\n\t\t\t\t\t\trqst := computeService.ForwardingRules.List(p.ProjectId, r.Name).MaxResults(500)\n\t\t\t\t\t\tcount := 0\n\t\t\t\t\t\tif err := rqst.Pages(ctx, func(page *compute.ForwardingRuleList) error {\n\t\t\t\t\t\t\tcount += len(page.Items)\n\t\t\t\t\t\t\treturn nil\n\t\t\t\t\t\t}); err != nil {\n\t\t\t\t\t\t\tlog.Println(err)\n\t\t\t\t\t\t\treturn\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif count != 0 {\n\t\t\t\t\t\t\tch <- prometheus.MustNewConstMetric(\n\t\t\t\t\t\t\t\tc.ForwardingRules,\n\t\t\t\t\t\t\t\tprometheus.GaugeValue,\n\t\t\t\t\t\t\t\tfloat64(count),\n\t\t\t\t\t\t\t\t[]string{\n\t\t\t\t\t\t\t\t\tp.ProjectId,\n\t\t\t\t\t\t\t\t\tr.Name,\n\t\t\t\t\t\t\t\t}...,\n\t\t\t\t\t\t\t)\n\t\t\t\t\t\t}\n\t\t\t\t\t}(r)\n\t\t\t\t}\n\t\t\t}(p)\n\t\t}(p)\n\t}\n\twg.Wait()\n}", "func (c *MultiClusterController) worker() {\n\tfor c.processNextWorkItem() {\n\t}\n}", "func mlWorker(str string, threads int, wg *sync.WaitGroup, parallel bool){\n\n\t// Convert the string to JSON format\n\tvar job MLJob\n\tjson.Unmarshal([]byte(str), &job)\n\n\n\t// Loop through the parameters to check which are numeric\n\t// We will be turning int slices like [1,4] -> [1,2,3,4]\n\tfor i:=0; i<len(job.ParameterRange); i++{\n\n\t\t// If the data is numeric\n\t\tif \"float64\" == reflect.TypeOf(job.ParameterRange[i][0]).String(){\n\n\t\t\t// Get the Min of the range\n\t\t\tmin := job.ParameterRange[i][0].(float64)\n\t\t\t// Get the Max of the range\n\t\t\ttop := job.ParameterRange[i][1].(float64)\n\n\t\t\t// Loop through all the values between min and max\n\t\t\t// and append to the array\n\t\t\tfor j := min; j<=top; j++{\n\t\t\t\tjob.ParameterRange[i] = append(job.ParameterRange[i], j)\n\n\t\t\t}\n\n\t\t\t// Get rid of the first two values (our original min/max values)\n\t\t\tjob.ParameterRange[i] = job.ParameterRange[i][2:]\n\t\t}\n\n\t}\n\n\t// Create an array that holds ML Request Objects\n\t// Each object will correspond to a specific model with specific parameters\n\tvar requests []MLRequest\n\n\t// Loop through all the parameters\n\t// The if/else blocks will dictate where to go\n\t// depending on how many parameters the user gives\n\tfor i:=0; i<len(job.ParameterRange[0]); i++{\n\n\t\t// If the user specifies more than 1 parameter\n\t\tif len(job.ParameterRange) > 1{\n\n\t\t\t// If the user Specifies 2 or more parameters\n\t\t\tfor j:=0; j<len(job.ParameterRange[1]); j++{\n\t\t\t\tif len(job.ParameterRange) > 2{\n\n\t\t\t\t\t// If the user Specifies 3 parameters\n\t\t\t\t\tfor k:=0; k<len(job.ParameterRange[2]); k++{\n\t\t\t\t\t\trequest := MLRequest{\n\t\t\t\t\t\t\tModel: job.Model,\n\t\t\t\t\t\t\tParameters: job.Parameters,\n\t\t\t\t\t\t\tParameterValues: fmt.Sprint(job.ParameterRange[0][i])+\"_\"+fmt.Sprint(job.ParameterRange[1][j])+\"_\"+fmt.Sprint(job.ParameterRange[2][k]),\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\trequests = append(requests, request)\n\n\t\t\t\t\t}\n\n\t\t\t\t// If the user Specifies 2 parameters\n\t\t\t\t}else{\n\t\t\t\t\trequest := MLRequest{\n\t\t\t\t\t\tModel: job.Model,\n\t\t\t\t\t\tParameters: job.Parameters,\n\t\t\t\t\t\tParameterValues: fmt.Sprint(job.ParameterRange[0][i])+\"_\"+fmt.Sprint(job.ParameterRange[1][j]),\n\t\t\t\t\t}\n\n\t\t\t\t\trequests = append(requests, request)\n\t\t\t\t}\n\n\t\t\t}\n\n\t\t// If the user Specifies 1 parameter\n\t\t}else{\n\t\t\trequest := MLRequest{\n\t\t\t\tModel: job.Model,\n\t\t\t\tParameters: job.Parameters,\n\t\t\t\tParameterValues: fmt.Sprint(job.ParameterRange[0][i]),\n\t\t\t}\n\n\t\t\trequests = append(requests, request)\n\t\t}\n\n\t}\n\n\t// Variable to hold best model\n\tvar globalMax float64\n\tvar bestModel MLRequest\n\n\t// If we are running in parallel\n\tif parallel{\n\t\tvar size int\n\n\t\t// Channel that will be used for synchronization\n\t\tthreadComplete := make(chan MLRequest, threads)\n\n\t\t// If there are more models to test than threads\n\t\tif len(requests) > threads{\n\n\t\t\t// Get the Partition\n\t\t\ty := len(requests)\n\t\t\tpartitions := y/threads\n\n\t\t\t// Range of first partition\n\t\t\tlo := 0\n\t\t\thi:=partitions\n\n\t\t\t// Spawn a go routine for each thread\n\t\t\tfor i:=0; i<threads; i++{\n\t\t\t\tgo mlParallel(lo, hi, requests, threadComplete)\n\n\t\t\t\t// Update the range of our partitions\n\t\t\t\tlo += partitions\n\n\t\t\t\t// For the last thread, take all remaining tasks\n\t\t\t\tif i == threads-2{\n\t\t\t\t\thi = len(requests)\n\n\t\t\t\t}else{\n\t\t\t\t\thi += partitions\n\t\t\t\t}\n\t\t\t}\n\t\t\tsize = threads\n\n\t\t// If there are more thread than requests\n\t\t}else{\n\t\t\t// Spawn go routines according the amount of request\n\t\t\tfor i:=0;i<len(requests);i++{\n\t\t\t\tgo mlParallel(i, i+1, requests, threadComplete)\n\t\t\t}\n\t\t\tsize = len(requests)\n\n\t\t}\n\n\t\t// Synchronize go routines to wait here before moving on\n\t\t// This chunk also determines the best model to use\n\t\tfor j:=0; j<size; j++{\n\n\t\t\t// Get the model accuracy\n\t\t\ttemp := <- threadComplete\n\n\t\t\t// Update max accordingly\n\t\t\tif temp.Accuracy > globalMax{\n\t\t\t\tglobalMax = temp.Accuracy\n\t\t\t\tbestModel = temp\n\t\t\t}\n\t\t}\n\n\t// Sequential Version\n\t} else{\n\t\t// Loop through requests\n\t\tfor i:=0; i<len(requests); i++{\n\n\t\t\t// Call the Python Function\n\t\t\t// Learned how to do this from:\n\t\t\t// https://stackoverflow.com/questions/27021517/go-run-external-python-script\n\t\t\tcmd,_ := exec.Command(\"python\", \"src/ml.py\", requests[i].Model, fmt.Sprint(requests[i].Parameters), requests[i].ParameterValues).Output()\n\n\t\t\t// Get the results and process them\n\t\t\tresult := strings.TrimSuffix(string(cmd), \"\\n\")\n\t\t\ttemp,_ := strconv.ParseFloat(result, 64)\n\n\t\t\t// Update max accordingly\n\t\t\tif temp > globalMax{\n\t\t\t\tglobalMax = temp\n\t\t\t\tbestModel = requests[i]\n\t\t\t}\n\n\t\t}\n\n\t}\n\n\t// Print the Best Model, along with parameters and accuracy, to the user\n\tbestModel.Accuracy = globalMax\n\tfmt.Println(\"Model: \",bestModel.Model)\n\tbest_params := strings.Split(bestModel.ParameterValues,\"_\")\n\tfor i:=0;i<len(bestModel.Parameters);i++{\n\t\tfmt.Println(bestModel.Parameters[i]+\" : \"+best_params[i])\n\t}\n\tfmt.Println(\"Accuracy: \",bestModel.Accuracy)\n\tfmt.Println()\n\n\t// If running parallel, signal done\n\tif parallel{\n\t\twg.Done()\n\t}\n\n}", "func (optr *Operator) Run(workers int, stopCh <-chan struct{}) {\n\tdefer utilruntime.HandleCrash()\n\tdefer optr.queue.ShutDown()\n\n\tapiClient := optr.apiExtClient.ApiextensionsV1beta1()\n\t_, err := apiClient.CustomResourceDefinitions().Get(\"machineconfigpools.machineconfiguration.openshift.io\", metav1.GetOptions{})\n\tif err != nil {\n\t\tif apierrors.IsNotFound(err) {\n\t\t\tglog.Infof(\"Couldn't find machineconfigpool CRD, in cluster bringup mode\")\n\t\t\toptr.inClusterBringup = true\n\t\t} else {\n\t\t\tglog.Errorf(\"While checking for cluster bringup: %v\", err)\n\t\t}\n\t}\n\n\tif !cache.WaitForCacheSync(stopCh,\n\t\toptr.crdListerSynced,\n\t\toptr.deployListerSynced,\n\t\toptr.daemonsetListerSynced,\n\t\toptr.infraListerSynced,\n\t\toptr.mcoCmListerSynced,\n\t\toptr.clusterCmListerSynced,\n\t\toptr.serviceAccountInformerSynced,\n\t\toptr.clusterRoleInformerSynced,\n\t\toptr.clusterRoleBindingInformerSynced,\n\t\toptr.networkListerSynced) {\n\t\tglog.Error(\"failed to sync caches\")\n\t\treturn\n\t}\n\n\t// these can only be synced after CRDs are installed\n\tif !optr.inClusterBringup {\n\t\tif !cache.WaitForCacheSync(stopCh,\n\t\t\toptr.mcpListerSynced,\n\t\t\toptr.ccListerSynced,\n\t\t\toptr.mcListerSynced,\n\t\t) {\n\t\t\tglog.Error(\"failed to sync caches\")\n\t\t\treturn\n\t\t}\n\t}\n\n\tglog.Info(\"Starting MachineConfigOperator\")\n\tdefer glog.Info(\"Shutting down MachineConfigOperator\")\n\n\toptr.stopCh = stopCh\n\n\tfor i := 0; i < workers; i++ {\n\t\tgo wait.Until(optr.worker, time.Second, stopCh)\n\t}\n\n\t<-stopCh\n}", "func other_wait() {\r\n\t// variabel untuk waitgroup\r\n\tvar wait sync.WaitGroup\r\n\r\n\tgoRoutines := 5\r\n\r\n\t// tambah sejumlah 5 goroutine\r\n\twait.Add(goRoutines)\r\n\r\n\tfor i := 0; i < goRoutines; i++ {\r\n\t\tgo func(goRoutineID int) {\r\n\t\t\tfmt.Printf(\"ID:%d: Hello goroutines!\\n\", goRoutineID)\r\n\t\t\twait.Done()\r\n\t\t}(i) // parameter goRoutineID\r\n\t}\r\n\r\n\twait.Wait()\r\n}", "func (b *Build) Start(c *C, tasks ...string) Waiter {\n\tvar wg sync.WaitGroup\n\n\tfor _, name := range tasks {\n\t\ttask, ok := b.tasks[name]\n\t\tif !ok {\n\t\t\tb.Printf(\"No Such Task: %s\", name)\n\t\t\tbreak\n\t\t}\n\t\twg.Add(1)\n\t\tgo func() {\n\t\t\tdefer wg.Done()\n\t\t\terr := task.run(c)\n\t\t\tif err != nil {\n\t\t\t\tb.Println(err)\n\t\t\t}\n\t\t}()\n\t}\n\n\treturn &wg\n}", "func CreateWorkGroup(workers ...*Worker) *WorkGroup {\n\treturn &WorkGroup{\n\t\tworkers: workers,\n\t}\n}", "func loadNodeGroups(ctx context.Context, cfg *Config, cluster string, queues *Queues, instances map[string][]string) (err kv.Error) {\n\tfor qName, qDetails := range *queues {\n\t\t// Use the needed instance types from the queue and find matching groups\n\t\t// The key will be an ASG nodeGroup name\n\t\tmatches, err := func() (matches map[string]*price.Instance, err kv.Error) {\n\t\t\tmatches = map[string]*price.Instance{}\n\t\t\tfor _, instance := range qDetails.Instances {\n\t\t\t\tif groups, isPresent := instances[instance.name]; isPresent {\n\t\t\t\t\tfor _, groupName := range groups {\n\t\t\t\t\t\t// If there was a match found and the group has not yet been discovered\n\t\t\t\t\t\t// then add it\n\t\t\t\t\t\tif _, isPresent := matches[groupName]; !isPresent {\n\t\t\t\t\t\t\t// Now go through and test the allocation would be successful to this instance type. This\n\t\t\t\t\t\t\t// checks we are not using an over spec machine that is over provisioned for the job.\n\t\t\t\t\t\t\t//\n\t\t\t\t\t\t\tfits, err := qDetails.Resource.Fit(instance.resource)\n\t\t\t\t\t\t\tif err != nil {\n\t\t\t\t\t\t\t\tlogger.Trace(\"error while checking fit\", \"instance\", instance.name, \"error\", err.Error())\n\t\t\t\t\t\t\t\treturn matches, err\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tif !fits {\n\t\t\t\t\t\t\t\tif logger.IsTrace() {\n\t\t\t\t\t\t\t\t\tlogger.Trace(\"failed to fit\", \"instance\", instance.name, \"node\", spew.Sdump(*instance.resource), \"queue\", spew.Sdump(qDetails.Resource), \"stack\", stack.Trace().TrimRuntime())\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\tcontinue\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tlogger.Debug(\"adding\", groupName, \"for queue\", qName)\n\t\t\t\t\t\t\tmatches[groupName] = instance.cost\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\treturn matches, nil\n\t\t}()\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\n\t\tif len(matches) == 0 {\n\t\t\tlogger.Debug(\"unable to match any of the available \", len(qDetails.Instances), \" node groups with queue workload\", \"queue\", qName)\n\t\t\tcontinue\n\t\t}\n\n\t\t// Having found a number of potential groups that we could use find the cheapest and\n\t\t// then update the queue with an assigned ASG nodeGroup\n\t\tcheapest := &price.Instance{\n\t\t\tPrice: math.MaxFloat64,\n\t\t}\n\t\tfor groupName, instance := range matches {\n\t\t\tif instance.Price < cheapest.Price {\n\t\t\t\tqDetails.NodeGroup = groupName\n\t\t\t\t(*queues)[qName] = qDetails\n\t\t\t\tcheapest = instance\n\t\t\t\tlogger.Debug(\"cheapest now\", instance.Type, \"for queue\", qName)\n\t\t\t}\n\t\t}\n\n\t}\n\treturn nil\n}", "func main() {\n\n //bring up the services\n\tmasterSrvAddr := master.StartMasterSrv(9090) //9090\n\tworkerSrvAddr1 := worker.StartWorkerSrv(9091); //9091 ,9092, 9093\n\tworkerSrvAddr2 := worker.StartWorkerSrv(9092);\n\tworker.StartWorkerCli(masterSrvAddr, []string{workerSrvAddr1,workerSrvAddr2});\n\tmaster.StartMasterCli();\n\n\t//distributed map-reduce flow\n\tmapOutput,err := master.DoOperation([]string{\"/Users/k0c00nc/go/src/MapReduce/res/input.txt\", \"/Users/k0c00nc/go/src/distributedDb\" +\n\t\t\"/res/input1.txt\"},\"Map\")\n\tif err !=nil{\n\t\tfmt.Printf(\"map phase failed with err %s \", err.Error())\n\t}\n\n\tlocalAggregation,err :=master.DoOperation(mapOutput,\"LocalAggregation\")\n\tif err !=nil{\n\t\tfmt.Printf(\"localAggregation phase failed with err %s \", err.Error())\n\t}\n\n\tshuffing,err :=master.DoOperation(localAggregation,\"Shuffing\")\n\tif err !=nil{\n\t\tfmt.Printf(\"shuffing phase failed with err %s \", err.Error())\n\t}\n\n\treduce,err :=master.DoOperation(shuffing,\"Reduce\")\n\tif err !=nil{\n\t\tfmt.Printf(\"reduce phase failed with err %s \", err.Error())\n\t}\n\n fmt.Println(\"MR output are in file\", reduce[0])\n\n}", "func (grp *ProcessGrpCmd) Run() error {\r\n\tif handle, err := NewProcessGroup(); err != nil {\r\n\t\tgrp.waitgrp.Done()\r\n\t\treturn err\r\n\t} else {\r\n\t\tgrp.handle = handle\r\n\t}\r\n\r\n\tif err := grp.Cmd.Start(); err != nil {\r\n\t\tgrp.waitgrp.Done()\r\n\t\treturn err\r\n\t}\r\n\r\n\tif err := grp.AddProcess(grp.Cmd.Process); err != nil {\r\n\t\tgrp.waitgrp.Done()\r\n\t\treturn err\r\n\t}\r\n\r\n\tgo func() {\r\n\t\tselect {\r\n\t\tcase <-grp.sigChan:\r\n\t\t\tgrp.Terminate()\r\n\t\t\treturn\r\n\t\tcase <-grp.ctx.Done():\r\n\t\t\tgrp.Terminate()\r\n\t\t\treturn\r\n\t\t}\r\n\t}()\r\n\r\n\treturn grp.Cmd.Wait()\r\n}", "func runProgFuncs(ctx context.Context) (*sync.WaitGroup, chan pull.Stats) {\n\tstatsCh := make(chan pull.Stats)\n\twg := &sync.WaitGroup{}\n\n\twg.Add(1)\n\tgo func() {\n\t\tdefer wg.Done()\n\t\tpullerProgFunc(ctx, statsCh)\n\t}()\n\n\treturn wg, statsCh\n}", "func main(){\n\tmc := master.LoadConfig()\n\terrList := master.Start(mc.Num_instances, mc.Selection_config, mc.Ports)\n\tfor i, err := range errList {\n\t\tlog.Println(\"ERR: \", i, \"th master terminated with error: \", err)\n\t}\n\n}", "func New(maxGoroutines int) *Pool {\n p := Pool{\n job: make(chan Worker),\n error: make(chan string),\n }\n\n p.job_wg.Add(maxGoroutines)\n for i := 0; i < maxGoroutines; i++ {\n go func() {\n for w := range p.job {\n w.InitTask()\n w.DoTask()\n w.ErrorTask()\n w.PostTask()\n }\n p.job_wg.Done()\n }()\n\n }\n\n return &p\n}", "func RunAllNodes(nodes []*node.Node) (chan struct{}) {\n stopChan := make(chan struct{})\n for i := range(nodes) {\n go func(i int) {\n nodes[i].Run()\n }(i)\n }\n\n go func() {\n select {\n case <- stopChan:\n for i := range(nodes) {\n nodes[i].Stop()\n }\n }\n }()\n return stopChan\n}", "func (c *myClient) batchCreateDatasetGroup(groupNameList ...string) (resultsList []map[string]interface{}, err error) {\n\tfor _, v := range groupNameList {\n\t\tif result, err := c.createDatasetGroup(v, false); err != nil {\n\t\t\treturn nil, err\n\t\t} else if result != nil && (result[\"job\"] != nil || result[\"action\"] != nil) {\n\t\t\tresultsList = append(resultsList, result)\n\t\t}\n\t}\n\tc.jobWaiter(resultsList...)\n\n\treturn resultsList, err\n}", "func startWorkers(h *common.SampleHelper, applicationName string) {\n\t// Configure worker options.\n\tworkerOptions := worker.Options{\n\t\tMetricsScope: h.Scope,\n\t\tLogger: h.Logger,\n\t}\n\th.StartWorkers(h.Config.DomainName, applicationName, workerOptions)\n}", "func schedule(jobName string, mapFiles []string, nReduce int, phase jobPhase, registerChan chan string) {\n\tvar ntasks int\n\tvar n_other int // number of inputs (for reduce) or outputs (for map)\n\tswitch phase {\n\tcase mapPhase:\n\t\tntasks = len(mapFiles)\n\t\tn_other = nReduce\n\tcase reducePhase:\n\t\tntasks = nReduce\n\t\tn_other = len(mapFiles)\n\t}\n\n\tfmt.Printf(\"Schedule: %v %v tasks (%d I/Os)\\n\", ntasks, phase, n_other)\n\n\t// All ntasks tasks have to be scheduled on workers. Once all tasks\n\t// have completed successfully, schedule() should return.\n\t//\n\t// Your code here (Part III, Part IV).\n\t//\n\n\t//Lets create a sync.WaitGroup that has as many jobs as ntasks\n\tvar forkJoinLock sync.WaitGroup\n\tforkJoinLock.Add(ntasks)\n\n\t//Now, iterate through each task\n\tfor i := 0; i < ntasks; i++{\n\t\tvar workerArgs DoTaskArgs\n\t\tworkerArgs.JobName = jobName\n\t\tworkerArgs.Phase = phase\n\t\tworkerArgs.NumOtherPhase = n_other\n\t\tworkerArgs.TaskNumber = i\n\t\t//Only mapPhase has files\n\t\t//Research into why go doesn't support one line If-else statements\n\t\tif(phase == mapPhase){\n\t\t\tworkerArgs.File = mapFiles[i]\n\t\t}\n\n\t\tgo func() {\n\t\t\tisThreadSuccessful := false\n\t\t\t//Ensure that task is definitely completed. Otherwise , major repurcussions in handling workers\n\t\t\tLoop:\n\t\t\tfor{\n\t\t\t\t//Get a fresh worker if last thread was unsuccessful. This seems to be blocked if there are no workers in channel\n\t\t\t\tworker := <-registerChan\n\t\t\t\tisThreadSuccessful = call(worker,\"Worker.DoTask\",workerArgs,nil)\n\t\t\t\tswitch isThreadSuccessful {\n\t\t\t\tcase true:\n\t\t\t\t\tgo func(){\n\t\t\t\t\t\tregisterChan <- worker\n\t\t\t\t\t}()\n\t\t\t\t\tforkJoinLock.Done()\n\t\t\t\t\tbreak Loop\n\t\t\t\tcase false:\n\t\t\t\t\tgo func(){\n\t\t\t\t\t\tregisterChan <- worker\n\t\t\t\t\t}()\n\t\t\t\t}\n\t\t\t}\n\t\t}()\n\t}\n\t//For synchronization of all tasks\n\tforkJoinLock.Wait()\n}", "func (s *Scheduler) work() {\n\t// This worker never stops working.\n\tfor {\n\t\t// We haven't picked up work yet so mark this worker as free\n\t\tatomic.AddInt32(s.freeWorkers, 1)\n\n\t\t// Take one scheduled run, block if there are no scheduled pipelines\n\t\tr := <-s.scheduledRuns\n\n\t\t// We picked up work and are from now on busy\n\t\tatomic.AddInt32(s.freeWorkers, -1)\n\n\t\t// Prepare execution and start it\n\t\ts.prepareAndExec(r)\n\t}\n}", "func startWorkers(h *common.SampleHelper) {\n\t// Configure worker options.\n\tworkerOptions := worker.Options{\n\t\tMetricsScope: h.WorkerMetricScope,\n\t\tLogger: h.Logger,\n\t\tFeatureFlags: client.FeatureFlags{\n\t\t\tWorkflowExecutionAlreadyCompletedErrorEnabled: true,\n\t\t},\n\t\tTracer: h.Tracer,\n\t}\n\th.StartWorkers(h.Config.DomainName, ApplicationName, workerOptions)\n}", "func (b *Backend) InitGroup(groupUUID string, taskUUIDs []string) error {\n\ttasks := make([]string, 0, len(taskUUIDs))\n\t// copy every task\n\tfor _, v := range taskUUIDs {\n\t\ttasks = append(tasks, v)\n\t}\n\n\tb.groups[groupUUID] = tasks\n\treturn nil\n}", "func main() {\n\n\t// Primary processing waitgroup\n\tvar wg sync.WaitGroup\n\n\t// Initialize Timers\n\tvar makesRequestTimer operationtimer.Timer\n\tvar modelRequestTimer operationtimer.Timer\n\n\t// Retrieve vehicle make list from car-common-makes.json\n\toperationtimer.StartTimer(&makesRequestTimer)\n\tfile, _ := ioutil.ReadFile(\"car-common-makes.json\")\n\tvar fileContent vehicledbhelperutils.CommonMakesFile\n\t_ = json.Unmarshal([]byte(file), &fileContent)\n\tmakes := fileContent.Makes\n\ttotalMakes := len(fileContent.Makes)\n\toperationtimer.ReportTime(&makesRequestTimer, \"Retrieving All Vehicle Models: \")\n\n\t// Divide and collect data\n\toperationtimer.StartTimer(&modelRequestTimer)\n\tDivideConquerRequests(totalMakes, makes, &wg)\n\toperationtimer.ReportTime(&modelRequestTimer, \"Retrieving All Vehicle Models: \")\n}", "func spawnInALoop() {\n\tfor i := 0; i < 10; i++ {\n\t\t// Our goroutine is a closure, and closures can\n\t\t// access variables in the outer scope, so we can\n\t\t// grab i here to give each goroutine an ID, right?\n\t\t// (Hint: wrong.)\n\t\tgo func() {\n\t\t\tfmt.Println(\"Goroutine\", i)\n\t\t}() // <- Don't forget to call () the closure\n\t}\n\ttime.Sleep(100 * time.Millisecond)\n}", "func GenerateCreateWorkGroupInput(cr *svcapitypes.WorkGroup) *svcsdk.CreateWorkGroupInput {\n\tres := &svcsdk.CreateWorkGroupInput{}\n\n\tif cr.Spec.ForProvider.Configuration != nil {\n\t\tf0 := &svcsdk.WorkGroupConfiguration{}\n\t\tif cr.Spec.ForProvider.Configuration.BytesScannedCutoffPerQuery != nil {\n\t\t\tf0.SetBytesScannedCutoffPerQuery(*cr.Spec.ForProvider.Configuration.BytesScannedCutoffPerQuery)\n\t\t}\n\t\tif cr.Spec.ForProvider.Configuration.EnforceWorkGroupConfiguration != nil {\n\t\t\tf0.SetEnforceWorkGroupConfiguration(*cr.Spec.ForProvider.Configuration.EnforceWorkGroupConfiguration)\n\t\t}\n\t\tif cr.Spec.ForProvider.Configuration.EngineVersion != nil {\n\t\t\tf0f2 := &svcsdk.EngineVersion{}\n\t\t\tif cr.Spec.ForProvider.Configuration.EngineVersion.EffectiveEngineVersion != nil {\n\t\t\t\tf0f2.SetEffectiveEngineVersion(*cr.Spec.ForProvider.Configuration.EngineVersion.EffectiveEngineVersion)\n\t\t\t}\n\t\t\tif cr.Spec.ForProvider.Configuration.EngineVersion.SelectedEngineVersion != nil {\n\t\t\t\tf0f2.SetSelectedEngineVersion(*cr.Spec.ForProvider.Configuration.EngineVersion.SelectedEngineVersion)\n\t\t\t}\n\t\t\tf0.SetEngineVersion(f0f2)\n\t\t}\n\t\tif cr.Spec.ForProvider.Configuration.PublishCloudWatchMetricsEnabled != nil {\n\t\t\tf0.SetPublishCloudWatchMetricsEnabled(*cr.Spec.ForProvider.Configuration.PublishCloudWatchMetricsEnabled)\n\t\t}\n\t\tif cr.Spec.ForProvider.Configuration.RequesterPaysEnabled != nil {\n\t\t\tf0.SetRequesterPaysEnabled(*cr.Spec.ForProvider.Configuration.RequesterPaysEnabled)\n\t\t}\n\t\tif cr.Spec.ForProvider.Configuration.ResultConfiguration != nil {\n\t\t\tf0f5 := &svcsdk.ResultConfiguration{}\n\t\t\tif cr.Spec.ForProvider.Configuration.ResultConfiguration.EncryptionConfiguration != nil {\n\t\t\t\tf0f5f0 := &svcsdk.EncryptionConfiguration{}\n\t\t\t\tif cr.Spec.ForProvider.Configuration.ResultConfiguration.EncryptionConfiguration.EncryptionOption != nil {\n\t\t\t\t\tf0f5f0.SetEncryptionOption(*cr.Spec.ForProvider.Configuration.ResultConfiguration.EncryptionConfiguration.EncryptionOption)\n\t\t\t\t}\n\t\t\t\tif cr.Spec.ForProvider.Configuration.ResultConfiguration.EncryptionConfiguration.KMSKey != nil {\n\t\t\t\t\tf0f5f0.SetKmsKey(*cr.Spec.ForProvider.Configuration.ResultConfiguration.EncryptionConfiguration.KMSKey)\n\t\t\t\t}\n\t\t\t\tf0f5.SetEncryptionConfiguration(f0f5f0)\n\t\t\t}\n\t\t\tif cr.Spec.ForProvider.Configuration.ResultConfiguration.OutputLocation != nil {\n\t\t\t\tf0f5.SetOutputLocation(*cr.Spec.ForProvider.Configuration.ResultConfiguration.OutputLocation)\n\t\t\t}\n\t\t\tf0.SetResultConfiguration(f0f5)\n\t\t}\n\t\tres.SetConfiguration(f0)\n\t}\n\tif cr.Spec.ForProvider.Description != nil {\n\t\tres.SetDescription(*cr.Spec.ForProvider.Description)\n\t}\n\tif cr.Spec.ForProvider.Tags != nil {\n\t\tf2 := []*svcsdk.Tag{}\n\t\tfor _, f2iter := range cr.Spec.ForProvider.Tags {\n\t\t\tf2elem := &svcsdk.Tag{}\n\t\t\tif f2iter.Key != nil {\n\t\t\t\tf2elem.SetKey(*f2iter.Key)\n\t\t\t}\n\t\t\tif f2iter.Value != nil {\n\t\t\t\tf2elem.SetValue(*f2iter.Value)\n\t\t\t}\n\t\t\tf2 = append(f2, f2elem)\n\t\t}\n\t\tres.SetTags(f2)\n\t}\n\n\treturn res\n}", "func (d *disp) Start() *disp {\n\n\t//pipelines_implementation_backup(d)\n\n\tl := len(d.Workers)\n\tfor i := 1; i <= l; i++ {\n\n\t\twrk := worker2.New(i, \"default\", make(worker2.PipelineChannel), d.PipelineQueue, make(worker2.JobChannel), d.Queue, make(chan struct{}))\n\t\twrk.Start()\n\t\td.Workers = append(d.Workers, wrk)\n\t}\n\tgo d.process()\n\n\treturn d\n}", "func (a *TopologySmartscapeProcessGroupApiService) GetProcessGroupsExecute(r ApiGetProcessGroupsRequest) ([]ProcessGroup, *_nethttp.Response, error) {\n\tvar (\n\t\tlocalVarHTTPMethod = _nethttp.MethodGet\n\t\tlocalVarPostBody interface{}\n\t\tlocalVarFormFileName string\n\t\tlocalVarFileName string\n\t\tlocalVarFileBytes []byte\n\t\tlocalVarReturnValue []ProcessGroup\n\t)\n\n\tlocalBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, \"TopologySmartscapeProcessGroupApiService.GetProcessGroups\")\n\tif err != nil {\n\t\treturn localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()}\n\t}\n\n\tlocalVarPath := localBasePath + \"/entity/infrastructure/process-groups\"\n\n\tlocalVarHeaderParams := make(map[string]string)\n\tlocalVarQueryParams := _neturl.Values{}\n\tlocalVarFormParams := _neturl.Values{}\n\n\tif r.startTimestamp != nil {\n\t\tlocalVarQueryParams.Add(\"startTimestamp\", parameterToString(*r.startTimestamp, \"\"))\n\t}\n\tif r.endTimestamp != nil {\n\t\tlocalVarQueryParams.Add(\"endTimestamp\", parameterToString(*r.endTimestamp, \"\"))\n\t}\n\tif r.relativeTime != nil {\n\t\tlocalVarQueryParams.Add(\"relativeTime\", parameterToString(*r.relativeTime, \"\"))\n\t}\n\tif r.tag != nil {\n\t\tt := *r.tag\n\t\tif reflect.TypeOf(t).Kind() == reflect.Slice {\n\t\t\ts := reflect.ValueOf(t)\n\t\t\tfor i := 0; i < s.Len(); i++ {\n\t\t\t\tlocalVarQueryParams.Add(\"tag\", parameterToString(s.Index(i), \"multi\"))\n\t\t\t}\n\t\t} else {\n\t\t\tlocalVarQueryParams.Add(\"tag\", parameterToString(t, \"multi\"))\n\t\t}\n\t}\n\tif r.entity != nil {\n\t\tt := *r.entity\n\t\tif reflect.TypeOf(t).Kind() == reflect.Slice {\n\t\t\ts := reflect.ValueOf(t)\n\t\t\tfor i := 0; i < s.Len(); i++ {\n\t\t\t\tlocalVarQueryParams.Add(\"entity\", parameterToString(s.Index(i), \"multi\"))\n\t\t\t}\n\t\t} else {\n\t\t\tlocalVarQueryParams.Add(\"entity\", parameterToString(t, \"multi\"))\n\t\t}\n\t}\n\tif r.host != nil {\n\t\tt := *r.host\n\t\tif reflect.TypeOf(t).Kind() == reflect.Slice {\n\t\t\ts := reflect.ValueOf(t)\n\t\t\tfor i := 0; i < s.Len(); i++ {\n\t\t\t\tlocalVarQueryParams.Add(\"host\", parameterToString(s.Index(i), \"multi\"))\n\t\t\t}\n\t\t} else {\n\t\t\tlocalVarQueryParams.Add(\"host\", parameterToString(t, \"multi\"))\n\t\t}\n\t}\n\tif r.managementZone != nil {\n\t\tlocalVarQueryParams.Add(\"managementZone\", parameterToString(*r.managementZone, \"\"))\n\t}\n\tif r.includeDetails != nil {\n\t\tlocalVarQueryParams.Add(\"includeDetails\", parameterToString(*r.includeDetails, \"\"))\n\t}\n\tif r.pageSize != nil {\n\t\tlocalVarQueryParams.Add(\"pageSize\", parameterToString(*r.pageSize, \"\"))\n\t}\n\tif r.nextPageKey != nil {\n\t\tlocalVarQueryParams.Add(\"nextPageKey\", parameterToString(*r.nextPageKey, \"\"))\n\t}\n\t// to determine the Content-Type header\n\tlocalVarHTTPContentTypes := []string{}\n\n\t// set Content-Type header\n\tlocalVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes)\n\tif localVarHTTPContentType != \"\" {\n\t\tlocalVarHeaderParams[\"Content-Type\"] = localVarHTTPContentType\n\t}\n\n\t// to determine the Accept header\n\tlocalVarHTTPHeaderAccepts := []string{\"application/json; charset=utf-8\"}\n\n\t// set Accept header\n\tlocalVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts)\n\tif localVarHTTPHeaderAccept != \"\" {\n\t\tlocalVarHeaderParams[\"Accept\"] = localVarHTTPHeaderAccept\n\t}\n\tif r.ctx != nil {\n\t\t// API Key Authentication\n\t\tif auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok {\n\t\t\tif apiKey, ok := auth[\"Api-Token\"]; ok {\n\t\t\t\tvar key string\n\t\t\t\tif apiKey.Prefix != \"\" {\n\t\t\t\t\tkey = apiKey.Prefix + \" \" + apiKey.Key\n\t\t\t\t} else {\n\t\t\t\t\tkey = apiKey.Key\n\t\t\t\t}\n\t\t\t\tlocalVarHeaderParams[\"Authorization\"] = key\n\t\t\t}\n\t\t}\n\t}\n\treq, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes)\n\tif err != nil {\n\t\treturn localVarReturnValue, nil, err\n\t}\n\n\tlocalVarHTTPResponse, err := a.client.callAPI(req)\n\tif err != nil || localVarHTTPResponse == nil {\n\t\treturn localVarReturnValue, localVarHTTPResponse, err\n\t}\n\n\tlocalVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body)\n\tlocalVarHTTPResponse.Body.Close()\n\tlocalVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody))\n\tif err != nil {\n\t\treturn localVarReturnValue, localVarHTTPResponse, err\n\t}\n\n\tif localVarHTTPResponse.StatusCode >= 300 {\n\t\tnewErr := GenericOpenAPIError{\n\t\t\tbody: localVarBody,\n\t\t\terror: localVarHTTPResponse.Status,\n\t\t}\n\t\tif localVarHTTPResponse.StatusCode == 400 {\n\t\t\tvar v ErrorEnvelope\n\t\t\terr = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get(\"Content-Type\"))\n\t\t\tif err != nil {\n\t\t\t\tnewErr.error = err.Error()\n\t\t\t\treturn localVarReturnValue, localVarHTTPResponse, newErr\n\t\t\t}\n\t\t\tnewErr.model = v\n\t\t}\n\t\treturn localVarReturnValue, localVarHTTPResponse, newErr\n\t}\n\n\terr = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get(\"Content-Type\"))\n\tif err != nil {\n\t\tnewErr := GenericOpenAPIError{\n\t\t\tbody: localVarBody,\n\t\t\terror: err.Error(),\n\t\t}\n\t\treturn localVarReturnValue, localVarHTTPResponse, newErr\n\t}\n\n\treturn localVarReturnValue, localVarHTTPResponse, nil\n}", "func bootVMs(t *testing.T, images []string, startVMID, endVMID int) {\n\tfor i := startVMID; i < endVMID; i++ {\n\t\tvmIDString := strconv.Itoa(i)\n\t\t_, err := funcPool.AddInstance(vmIDString, images[i%len(images)])\n\t\trequire.NoError(t, err, \"Function returned error\")\n\t}\n\n\tif *profileCPUID > -1 || *bindSocket > -1 {\n\t\tlog.Debugf(\"Binding VMs\")\n\t\terr := bindVMs(*bindSocket, *profileCPUID)\n\t\trequire.NoError(t, err, \"Bind Socket returned error\")\n\t}\n}", "func runInstances(message string, fn runner) {\n logger.Log(fmt.Sprintf(\"%s %v\\n\", message, process))\n for i := 0; i < cfg.Instances; i++ {\n logger.Log(fmt.Sprintf(\"...Instance %d of %d %s\\n\", i, cfg.Instances, process))\n id, _ := pid(i)\n fn(i, id)\n }\n\n}", "func (a *Aggregator) launchFeedRunners(feedNameList []string) {\n\tif len(feedNameList) == 0 {\n\t\tfor info, feedConstructor := range FeedRegistry {\n\t\t\ta.totalSources[info.Product] += 1\n\t\t\tgo a.runFeed(feedConstructor, a.retryInterval)\n\t\t}\n\t} else {\n\t\trevRegistry := make(map[string]FeedInfo)\n\t\tfor info, _ := range FeedRegistry {\n\t\t\trevRegistry[info.Name] = info\n\t\t}\n\t\tfor _, feedName := range feedNameList {\n\t\t\tif info, ok := revRegistry[feedName]; ok {\n\t\t\t\tif feedConstructor, ok := FeedRegistry[info]; ok {\n\t\t\t\t\ta.totalSources[info.Product] += 1\n\t\t\t\t\tgo a.runFeed(feedConstructor, a.retryInterval)\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n}", "func (self *BinaryPushRequestProcessor) pushWorkerGroup(psp *push.PushServiceProvider, reqChan <-chan *common.PushRequest) {\n\tresultChan := make(chan *common.APNSResult, 100)\n\t// Create a connection manager to open connections.\n\t// This will create a goroutine listening on each connection it creates, to be sent to us on resultChan.\n\tmanager := newLoggingConnManager(self.connManagerMaker(psp, (chan<- *common.APNSResult)(resultChan)), self.errChan)\n\t// There's a pool for each push endpoint.\n\tworkerpool := NewPool(manager, self.poolSize, maxWaitTime)\n\tdefer workerpool.Close()\n\n\tworkerid := fmt.Sprintf(\"workder-%v-%v\", time.Now().Unix(), rand.Int63())\n\n\tdpCache := cache.New(256, -1, 0*time.Second, nil)\n\n\t// In a background thread, connect to corresponding feedback server and listen for unsubscribe updates to send to that user.\n\tgo self.feedbackChecker(psp, dpCache, self.errChan)\n\n\t// XXX use a tree structure would be faster and more stable.\n\treqMap := make(map[uint32]*common.PushRequest, 1024)\n\n\t// Callback for handling responses - used both in processing and when shutting down.\n\thandleResponse := func(res *common.APNSResult) {\n\t\t// Process the first result that is received for each MsgId, forwarding it to the requester.\n\t\tif req, ok := reqMap[res.MsgId]; ok {\n\t\t\tdelete(reqMap, res.MsgId)\n\t\t\treq.ResChan <- res\n\t\t} else if res.Err != nil {\n\t\t\tself.errChan <- res.Err\n\t\t}\n\t}\n\tfor {\n\t\tselect {\n\t\tcase req := <-reqChan:\n\t\t\t// Accept requests from pushMux goroutine, sending pushes to APNS for each devtoken.\n\t\t\t// If a response is received from APNS for a devtoken, forward it on the channel for the corresponding request.\n\t\t\t// Otherwise, close it\n\t\t\tif req == nil {\n\t\t\t\tfmt.Printf(\"[%v][%v] I was told to stop (req == nil) - stopping\\n\", time.Now(), workerid)\n\t\t\t\t// Finish up any remaining requests to uniqush, forwarding the responses from APNS.\n\t\t\t\t// clearRequest should ensure that reqMap is eventually empty - this has also been tested under heavy load.\n\t\t\t\tfor {\n\t\t\t\t\tif len(reqMap) == 0 {\n\t\t\t\t\t\tfmt.Printf(\"[%v][%v] I was told to stop - stopped\\n\", time.Now(), workerid)\n\t\t\t\t\t\treturn\n\t\t\t\t\t}\n\t\t\t\t\tres, ok := <-resultChan\n\t\t\t\t\tif !ok || res == nil {\n\t\t\t\t\t\tfmt.Printf(\"[%v][%v] Some pending requests don't have any responses - shouldn't happen\\n\", time.Now(), workerid)\n\t\t\t\t\t\treturn\n\t\t\t\t\t}\n\t\t\t\t\thandleResponse(res)\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tfor i, _ := range req.Devtokens {\n\t\t\t\tmid := req.GetId(i)\n\t\t\t\treqMap[mid] = req\n\t\t\t}\n\n\t\t\tfor _, dp := range req.DPList {\n\t\t\t\tif key, ok := dp.FixedData[\"devtoken\"]; ok {\n\t\t\t\t\tdpCache.Set(key, dp)\n\t\t\t\t}\n\t\t\t}\n\t\t\tgo self.multiPush(req, workerpool)\n\t\t\tgo clearRequest(req, resultChan)\n\t\tcase res := <-resultChan:\n\t\t\tif res == nil {\n\t\t\t\tfmt.Printf(\"[%v][%v] I was told to stop (res == nil)\\n\", time.Now(), workerid)\n\t\t\t\treturn\n\t\t\t}\n\t\t\thandleResponse(res)\n\t\t}\n\t}\n}", "func (j *Jobs) runTasks() {\n\n\t// load ssh key\n\tk := new(keychain)\n\tkey, err := k.loadPEM(j.Pem_file)\n\n\tif err != nil {\n\t\tpanic(\"Cannot load key [\" + j.Pem_file + \"]: \" + err.Error())\n\t}\n\n\t// not ready\n\tts := time.Now().Format(time.RFC3339)\n\tfor i := 0; i < len(j.Servers); i++ {\n\t\twt.Add(1)\n\t\t// create log file\n\t\tlog_file := \"logs/provi_log__\" + j.Servers[i] + \"--\" + ts + \".log\"\n\n\t\toutfile, err := os.Create(log_file)\n\t\tif err != nil {\n\t\t\tlog.Fatal(err)\n\t\t}\n\t\tdefer outfile.Close()\n\n\t\t// create ssh session\n\t\tconfig := &ssh.ClientConfig{\n\t\t\tUser: j.User,\n\t\t\tAuth: []ssh.AuthMethod{\n\t\t\t\tssh.PublicKeys(key),\n\t\t\t},\n\t\t}\n\n\t\tclient, err := ssh.Dial(\"tcp\", j.Servers[i]+\":22\", config)\n\t\tif err != nil {\n\t\t\tlog.Fatal(\"Failed to connect to [\" + j.Servers[i] + \"] with error: \" + err.Error())\n\t\t}\n\n\t\tgo func(x int, s *ssh.Client, o *os.File) {\n\t\t\tdefer wt.Done()\n\t\t\tj.runTask(x, s, o)\n\t\t}(i, client, outfile)\n\t}\n\twt.Wait()\n}", "func runGenerals(m int, generals []bool, commOrder bool) []bool {\n\tvar wg sync.WaitGroup\n\tn := len(generals)\n\twg.Add(n)\n\n\t// Create channels used to communicate between lieutenants.\n\tchannels := []chan bool{}\n\tfor range generals {\n\t\tchannels = append(channels, make(chan bool, n))\n\t}\n\n\t//Create channels used to communicate between commander and lieutenants.\n\tcommChannels := []chan bool{}\n\tfor range generals {\n\t\tcommChannels = append(commChannels, make(chan bool, n))\n\t}\n\n\t// This stores the final command at each node by the end of the algorithm.\n\tcommands := make([]bool, n)\n\n\tfor i, loyal := range generals {\n\t\tif i == 0 {\n\t\t\t// Get the commander to send out initial commands.\n\t\t\tgo commander(n, m, i, loyal, commOrder, commChannels, &wg)\n\t\t} else {\n\t\t\t// Create a goroutine for each lieutenant.\n\t\t\tgo lieutenant(n, m, i, loyal, commChannels, channels, commands, &wg)\n\t\t}\n\t}\n\twg.Wait()\n\treturn commands\n}", "func (kgw kgWorker) start(args ...interface{}) error {\n\tgo kgw.work()\n\treturn nil\n}", "func (c *Client) StartMonitoringGroups(ctx context.Context, partnerID string, groupIDs []string, taskID gocql.UUID) error {\n\tfor _, id := range groupIDs {\n\t\tpayload := m.MonitoringDG{\n\t\t\tPartnerID: partnerID,\n\t\t\tDynamicGroupID: id,\n\t\t\tServiceID: TaskingServiceIDPrefix + taskID.String(),\n\t\t\tOperation: MessageTypeDynamicGroupStartMonitoring,\n\t\t}\n\n\t\tif err := c.client.Push(ctx, payload); err != nil {\n\t\t\treturn err\n\t\t}\n\t}\n\treturn nil\n}", "func recommendAutoscalingGroupsCmd(c *cli.Context) error {\n\ttags := parseTags(c.StringSlice(\"tags\"))\n\tlog.Printf(\"recommend optimization for autoscaling groups filtered by %v\", tags)\n\t// handle lambda or cli\n\tif lambdaMode {\n\t\tlambda.StartWithContext(mainCtx, func(ctx context.Context) error {\n\t\t\treturn recommendAutoscalingGroups(role, tags)\n\t\t})\n\t\treturn nil\n\t}\n\treturn recommendAutoscalingGroups(role, tags)\n}", "func schedule(jobName string, mapFiles []string, nReduce int, phase jobPhase, registerChan chan string) {\n\tvar ntasks int\n\tvar n_other int // number of inputs (for reduce) or outputs (for map)\n\tswitch phase {\n\tcase mapPhase:\n\t\tntasks = len(mapFiles)\n\t\tn_other = nReduce\n\tcase reducePhase:\n\t\tntasks = nReduce\n\t\tn_other = len(mapFiles)\n\t}\n\n\tfmt.Printf(\"Schedule: %v %v tasks (%d I/Os)\\n\", ntasks, phase, n_other)\n\n\t// All ntasks tasks have to be scheduled on workers. Once all tasks\n\t// have completed successfully, schedule() should return.\n\t//\n\t// Your code here (Part III, Part IV).\n\t//\n\tvar wg sync.WaitGroup\n\tfor i := 0; i < ntasks; i++ {\n\t\twg.Add(1)\n\t\tgo func(taskIndex int) {\n\t\t\tdefer wg.Done()\n\t\t\t// 1. Build DoTaskArgs entity.\n\t\t\tvar args DoTaskArgs\n\t\t\targs.Phase = phase\n\t\t\targs.JobName = jobName\n\t\t\targs.TaskNumber = taskIndex\n\t\t\targs.NumOtherPhase = n_other\n\t\t\tif phase == mapPhase {\n\t\t\t\targs.File = mapFiles[taskIndex]\n\t\t\t}\n\t\t\t// 2. Send DoTaskJob rpc.\n\t\t\tfor { // Note Loop call util success if there exists worker failure.\n\t\t\t\t// 3. Fetch worker from registerChan.\n\t\t\t\t// Note if one worker goes down, it won't be fetched from registerChan.\n\t\t\t\twork := <-registerChan\n\t\t\t\tok := call(work, \"Worker.DoTask\", &args, new(struct{}))\n\t\t\t\tif ok == false {\n\t\t\t\t\tfmt.Printf(\"Master: RPC %s schedule error for %s task %d.\\n\", work, phase, taskIndex)\n\t\t\t\t\tfmt.Printf(\"Master: Redo - RPC schedule error for %s task %d.\\n\", phase, taskIndex)\n\t\t\t\t} else {\n\t\t\t\t\tfmt.Printf(\"Master: RPC %s schedule success for %s task %d.\\n\", work, phase, taskIndex)\n\t\t\t\t\t// 4. Register worker (ready) in parallel to avoid block.\n\t\t\t\t\tgo func() {\n\t\t\t\t\t\tregisterChan <- work\n\t\t\t\t\t}()\n\t\t\t\t\tfmt.Printf(\"Master: %d tasks over!\\n\", taskIndex)\n\t\t\t\t\tbreak\n\t\t\t\t}\n\t\t\t}\n\t\t}(i)\n\t}\n\twg.Wait() // Wait for all (ntasks) task to compelete.\n\tfmt.Printf(\"Schedule: %v done\\n\", phase)\n}", "func populateRunning(aws awsECSClient, state *ecsState) error {\n\t// Collect data across all clusters being queried\n\tfor _, cluster := range state.meta.clusters {\n\t\tclusterTasks, err := getRunningTasks(aws, state, cluster)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\n\t\tif err = getContainerInstances(aws, state, cluster, clusterTasks); err != nil {\n\t\t\treturn err\n\t\t}\n\t}\n\n\t// ...then fetch any associated ec2 hosts\n\treturn getEC2Hosts(aws, state)\n}", "func (p *Pool) Start() {\n\tfor i := 0; i < p.nWorkers; i++ {\n\t\tw := newWorker(p.WorkerPool, p.jobfunc, &p.WaitGroup)\n\t\tw.Start()\n\t}\n\n\tgo func() {\n\t\tfor {\n\t\t\tselect {\n\t\t\tcase job := <-p.jobs:\n\t\t\t\tp.WaitGroup.Add(1)\n\t\t\t\tgo func(job interface{}) {\n\t\t\t\t\tjobChan := <-p.WorkerPool\n\t\t\t\t\tjobChan <- job\n\t\t\t\t}(job)\n\t\t\tcase <-p.quit:\n\t\t\t\treturn\n\t\t\t}\n\t\t}\n\t}()\n}", "func (gp *GetProjects) Execute(fed FederatorInterface) error {\n\tvar wg sync.WaitGroup\n\tvar projects hubapi.ProjectList\n\n\thubs := fed.GetHubs()\n\tlog.Debugf(\"GetProjects federator hubs: %+v\", hubs)\n\thubCount := len(hubs)\n\tprojectsListCh := make(chan *hubapi.ProjectList, hubCount)\n\n\twg.Add(hubCount)\n\tfor hubURL, client := range hubs {\n\t\tgo func(client *hub.Client, url string, id string, rt GetProjectsRequestType) {\n\t\t\tdefer wg.Done()\n\t\t\tif rt == ProjectsGetAll {\n\t\t\t\tlog.Debugf(\"querying all projects\")\n\t\t\t\tlist, err := client.ListAllProjects()\n\t\t\t\tif err != nil {\n\t\t\t\t\tlog.Warningf(\"failed to get projects from %s: %v\", url, err)\n\t\t\t\t\tprojectsListCh <- nil\n\t\t\t\t} else {\n\t\t\t\t\tprojectsListCh <- list\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\tlink := hubapi.ResourceLink{Href: fmt.Sprintf(\"https://%s/api/projects/%s\", url, id)}\n\t\t\t\tlog.Debugf(\"querying project %s\", link.Href)\n\t\t\t\tcl, err := client.GetProject(link)\n\t\t\t\tlog.Debugf(\"response to project query from %s: %+v\", link.Href, cl)\n\t\t\t\tif err != nil {\n\t\t\t\t\tprojectsListCh <- nil\n\t\t\t\t} else {\n\t\t\t\t\tlist := &hubapi.ProjectList{\n\t\t\t\t\t\tTotalCount: 1,\n\t\t\t\t\t\tItems: []hubapi.Project{*cl},\n\t\t\t\t\t}\n\t\t\t\t\tprojectsListCh <- list\n\t\t\t\t}\n\t\t\t}\n\t\t}(client, hubURL, gp.projectID, gp.requestType)\n\t}\n\n\twg.Wait()\n\tfor i := 0; i < hubCount; i++ {\n\t\tresponse := <-projectsListCh\n\t\tif response != nil {\n\t\t\tlog.Debugf(\"a hub responded with project list: %+v\", response)\n\t\t\tgp.mergeProjectList(&projects, response)\n\t\t}\n\t}\n\n\tgetResponse := GetProjectsResponse{\n\t\trequestType: gp.requestType,\n\t\tprojectID: gp.projectID,\n\t\tallProjects: &projects,\n\t}\n\n\tgp.responseCh <- &getResponse\n\treturn nil\n}", "func workers(done *int, jobs <-chan int, arrayA, arrayB, arrayF *arr) {\r\n\t// Inicia uma trhead para cada linha da matriz.\r\n\tfor job := range jobs {\r\n\t\tgo partial(job, done, arrayA, arrayB, arrayF)\r\n\t}\r\n}", "func ExecutePipeline(jobs ...job) {\r\n\twg := &sync.WaitGroup{}\r\n\tcountJobs := len(jobs)\r\n\tout := make(chan interface{})\r\n\tfor i := 0; i < countJobs; i++ {\r\n\t\tin := out\r\n\t\tout = make(chan interface{})\r\n\t\twg.Add(1)\r\n\t\tgo myGoroutine(in, out, jobs[i], wg)\r\n\t}\r\n\twg.Wait()\r\n}", "func (mg *Groups) Scale(instances int, force bool) error {\n\n\tif mg.group != nil && len(mg.group.ID) > 0 {\n\t\tif appClient := application.New(mg.client); appClient != nil {\n\n\t\t\tcallbackFunc := func(appID string) error {\n\n\t\t\t\tif err := appClient.Get(appID).Scale(instances, force); err != nil {\n\t\t\t\t\treturn err\n\t\t\t\t}\n\t\t\t\treturn nil\n\t\t\t}\n\t\t\treturn mg.traverseGroupsWithAppID(mg.group, callbackFunc)\n\t\t}\n\t\treturn fmt.Errorf(\"unnable to connect\")\n\t}\n\treturn errors.New(\"group cannot be null nor empty\")\n}", "func main() {\n\t//Concurrency party starts here with initialization. We could use the \"init\"\n\t//function but we won't be able to unit test it correctly\n\n\t//idleWorkers is an queue of goroutines workers\n\tidleWorkers := make(chan *chan int, WORKERS_SIZE)\n\n\t//A channel to communicate to the job dispatcher\n\tjobsCh := make(chan int)\n\n\t//Create the SPF dispatcher in a different process\n\tgo dispatcher(&jobsCh, &idleWorkers)\n\n\tcreateWorkers(&idleWorkers)\n\n\n\titer:=0\n\tfor {\n\t\trand.Seed(int64(iter))\n\t\twait := rand.Int31n(200)\n\t\tjobsCh <- iter\n\t\titer++\n\t\ttime.Sleep(time.Duration(wait) * time.Millisecond)\n\t}\n}", "func (pool *Pool) executor() {\n\tfor {\n\t\tif task, ok := <- pool.taskChannel; ok {\n\t\t\ttask.Run()\n\t\t\tpool.waitGroup.Done()\n\t\t} else {\n\t\t\treturn\n\t\t}\n\t}\n}" ]
[ "0.5855956", "0.5539021", "0.5518462", "0.5349718", "0.52923316", "0.52664375", "0.52058583", "0.51346374", "0.5120773", "0.5109735", "0.50071603", "0.50051606", "0.50031", "0.49959472", "0.49800986", "0.49717084", "0.4941504", "0.49303105", "0.49103543", "0.4906122", "0.48987633", "0.48964813", "0.48939574", "0.4880713", "0.48763713", "0.4873742", "0.48525512", "0.4844873", "0.48391166", "0.48379508", "0.48329207", "0.48203093", "0.480101", "0.47961742", "0.4795349", "0.47719768", "0.4761342", "0.47602692", "0.47597396", "0.47587818", "0.47502077", "0.47502077", "0.47485322", "0.47341257", "0.47320077", "0.47226122", "0.4717302", "0.47132227", "0.4698656", "0.4694779", "0.46912193", "0.46898967", "0.4684141", "0.46839452", "0.46766528", "0.4667966", "0.4667168", "0.46665826", "0.46630174", "0.46621567", "0.4655447", "0.46542245", "0.46528804", "0.4640677", "0.4627935", "0.4622577", "0.46216336", "0.46210447", "0.46167856", "0.46139443", "0.46048975", "0.46044612", "0.46021867", "0.45981947", "0.45969194", "0.45911402", "0.45856357", "0.4583382", "0.4582947", "0.4576156", "0.4575218", "0.4573922", "0.45737743", "0.45730948", "0.45727906", "0.45676285", "0.45637262", "0.45629168", "0.45628992", "0.4562256", "0.45592296", "0.4558366", "0.45549282", "0.45520404", "0.45518553", "0.45515954", "0.4550837", "0.45503134", "0.45483693" ]
0.4882078
24
launch one or more compute work groups using parameters stored in a buffer
func DispatchComputeIndirect(indirect int) { C.glowDispatchComputeIndirect(gpDispatchComputeIndirect, (C.GLintptr)(indirect)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func (g groupWork) Run(job Job, ctx *Ctx) (interface{}, error) {\n\tgrp := NewGroup()\n\n\tgrp.Add(ctx.Do(NewJob(\"generic\", \"first\")))\n\tgrp.Add(ctx.Do(NewJob(\"generic\", \"group work\")))\n\tgrp.Add(ctx.Do(NewJob(\"generic\", \"group work\")))\n\tgrp.Add(ctx.Do(NewJob(\"generic\", \"group work\")))\n\tgrp.Add(ctx.Do(NewJob(\"generic\", \"group work\")))\n\n\treturn grp, nil\n}", "func DispatchCompute(num_groups_x uint32, num_groups_y uint32, num_groups_z uint32) {\n C.glowDispatchCompute(gpDispatchCompute, (C.GLuint)(num_groups_x), (C.GLuint)(num_groups_y), (C.GLuint)(num_groups_z))\n}", "func (ep *groupbyExecutionPlan) performQueryOnBuffer() error {\n\t// reuse the allocated memory\n\toutput := ep.prevResults[0:0]\n\t// remember the previous results\n\tep.prevResults = ep.curResults\n\n\trollback := func() {\n\t\t// NB. ep.prevResults currently points to an slice with\n\t\t// results from the previous run. ep.curResults points\n\t\t// to the same slice. output points to a different slice\n\t\t// with a different underlying array.\n\t\t// in the next run, output will be reusing the underlying\n\t\t// storage of the current ep.prevResults to hold results.\n\t\t// therefore when we leave this function we must make\n\t\t// sure that ep.prevResults and ep.curResults have\n\t\t// different underlying arrays or ISTREAM/DSTREAM will\n\t\t// return wrong results.\n\t\tep.prevResults = output\n\t}\n\n\t// collect a list of all aggregate parameter evaluators in all\n\t// projections. this is necessary to avoid duplicate evaluation\n\t// if the same parameter is used in multiple aggregation funcs.\n\tallAggEvaluators := map[string]Evaluator{}\n\tfor _, proj := range ep.projections {\n\t\tfor key, agg := range proj.aggrEvals {\n\t\t\tallAggEvaluators[key] = agg\n\t\t}\n\t}\n\n\t// groups holds one item for every combination of values that\n\t// appear in the GROUP BY clause\n\tgroups := map[data.HashValue][]*tmpGroupData{}\n\t// we also keep a list of group keys so that we can still loop\n\t// over them in the order they were added\n\tgroupKeys := []data.HashValue{}\n\n\t// findOrCreateGroup looks up the group that has the given\n\t// groupValues in the `groups`map. if there is no such\n\t// group, a new one is created and a copy of the given map\n\t// is used as a representative of this group's values.\n\tfindOrCreateGroup := func(groupValues []data.Value, groupHash data.HashValue, nonGroupValues data.Map) (*tmpGroupData, error) {\n\t\tmkGroup := func() *tmpGroupData {\n\t\t\tnewGroup := &tmpGroupData{\n\t\t\t\t// the values that make up this group\n\t\t\t\tgroupValues,\n\t\t\t\t// the input values of the aggregate functions\n\t\t\t\tmap[string][]data.Value{},\n\t\t\t\t// a representative set of values for this group for later evaluation\n\t\t\t\t// TODO actually we don't need the whole map,\n\t\t\t\t// just the parts common to the whole group\n\t\t\t\tnonGroupValues.Copy(),\n\t\t\t}\n\t\t\t// initialize the map with the aggregate function inputs\n\t\t\tfor _, proj := range ep.projections {\n\t\t\t\tfor key := range proj.aggrEvals {\n\t\t\t\t\tnewGroup.aggData[key] = make([]data.Value, 0, 1)\n\t\t\t\t}\n\t\t\t}\n\t\t\treturn newGroup\n\t\t}\n\n\t\t// find the correct group\n\t\tgroupCandidates, exists := groups[groupHash]\n\t\tvar group *tmpGroupData\n\t\t// if there is no such group, create one\n\t\tif !exists {\n\t\t\tgroup = mkGroup()\n\t\t\tgroups[groupHash] = []*tmpGroupData{group}\n\t\t\tgroupKeys = append(groupKeys, groupHash)\n\t\t} else {\n\t\t\t// if we arrive here, there is a group with the same hash value\n\t\t\t// but we need to validate the data is actually the same\n\t\t\tfor _, groupCandidate := range groupCandidates {\n\t\t\t\tif data.Equal(data.Array(groupValues), groupCandidate.group) {\n\t\t\t\t\tgroup = groupCandidate\n\t\t\t\t\tbreak\n\t\t\t\t}\n\t\t\t}\n\t\t\t// no group with the same groupValues was found, so create\n\t\t\t// one and append it to the list of groups with the same hash\n\t\t\tif group == nil {\n\t\t\t\tgroup = mkGroup()\n\t\t\t\tgroups[groupHash] = append(groupCandidates, group)\n\t\t\t}\n\t\t}\n\t\t// return a pointer to the (found or created) group\n\t\treturn group, nil\n\t}\n\n\t// function to compute the grouping expressions and store the\n\t// input for aggregate functions in the correct group.\n\tevalItem := func(io *inputRowWithCachedResult) error {\n\t\tvar itemGroupValues data.Array\n\t\t// if we have a cached result, use this\n\t\tif io.cache != nil {\n\t\t\tcachedGroupValues, err := data.AsArray(io.cache)\n\t\t\tif err != nil {\n\t\t\t\treturn fmt.Errorf(\"cached data was not an array: %v\", io.cache)\n\t\t\t}\n\t\t\titemGroupValues = cachedGroupValues\n\t\t} else {\n\t\t\t// otherwise, compute the expressions in the GROUP BY to find\n\t\t\t// the correct group to append to\n\t\t\titemGroupValues = make([]data.Value, len(ep.groupList))\n\t\t\tfor i, eval := range ep.groupList {\n\t\t\t\t// ordinary \"flat\" expression\n\t\t\t\tvalue, err := eval.Eval(*io.input)\n\t\t\t\tif err != nil {\n\t\t\t\t\treturn err\n\t\t\t\t}\n\t\t\t\titemGroupValues[i] = value\n\t\t\t}\n\t\t\tio.cache = itemGroupValues\n\t\t\tio.hash = data.Hash(io.cache)\n\t\t}\n\n\t\titemGroup, err := findOrCreateGroup(itemGroupValues, io.hash, *io.input)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\n\t\t// now compute all the input data for the aggregate functions,\n\t\t// e.g. for `SELECT count(a) + max(b/2)`, compute `a` and `b/2`\n\t\tfor key, agg := range allAggEvaluators {\n\t\t\tvalue, err := agg.Eval(*io.input)\n\t\t\tif err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\t\t\t// store this value in the output map\n\t\t\titemGroup.aggData[key] = append(itemGroup.aggData[key], value)\n\t\t}\n\t\treturn nil\n\t}\n\n\tevalGroup := func(group *tmpGroupData) error {\n\t\tresult := data.Map(make(map[string]data.Value, len(ep.projections)))\n\t\t// collect input for aggregate functions into an array\n\t\t// within each group\n\t\tfor key := range allAggEvaluators {\n\t\t\tgroup.nonAggData[key] = data.Array(group.aggData[key])\n\t\t\tdelete(group.aggData, key)\n\t\t}\n\t\t// evaluate HAVING condition, if there is one\n\t\tfor _, proj := range ep.projections {\n\t\t\tif proj.alias == \":having:\" {\n\t\t\t\thavingResult, err := proj.evaluator.Eval(group.nonAggData)\n\t\t\t\tif err != nil {\n\t\t\t\t\treturn err\n\t\t\t\t}\n\t\t\t\t// a NULL value is definitely not \"true\", so since we\n\t\t\t\t// have only a binary decision, we should drop tuples\n\t\t\t\t// where the condition evaluates to NULL\n\t\t\t\thavingResultBool := false\n\t\t\t\tif havingResult.Type() != data.TypeNull {\n\t\t\t\t\thavingResultBool, err = data.AsBool(havingResult)\n\t\t\t\t\tif err != nil {\n\t\t\t\t\t\treturn err\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t// if it evaluated to false, do not further process this group\n\t\t\t\tif !havingResultBool {\n\t\t\t\t\treturn nil\n\t\t\t\t}\n\t\t\t\tbreak\n\t\t\t}\n\t\t}\n\t\t// now evaluate all other projections\n\t\tfor _, proj := range ep.projections {\n\t\t\tif proj.alias == \":having:\" {\n\t\t\t\tcontinue\n\t\t\t}\n\t\t\t// now evaluate this projection on the flattened data\n\t\t\tvalue, err := proj.evaluator.Eval(group.nonAggData)\n\t\t\tif err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\t\t\tif err := assignOutputValue(result, proj.alias, proj.aliasPath, value); err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\t\t}\n\t\toutput = append(output, resultRow{row: result, hash: data.Hash(result)})\n\t\treturn nil\n\t}\n\n\tevalNoGroup := func() error {\n\t\t// if we have an empty group list *and* a GROUP BY clause,\n\t\t// we have to return an empty result (because there are no\n\t\t// rows with \"the same values\"). but if the list is empty and\n\t\t// we *don't* have a GROUP BY clause, then we need to compute\n\t\t// all foldables and aggregates with an empty input\n\t\tif len(ep.groupList) > 0 {\n\t\t\treturn nil\n\t\t}\n\t\tinput := data.Map{}\n\t\tresult := data.Map(make(map[string]data.Value, len(ep.projections)))\n\t\tfor _, proj := range ep.projections {\n\t\t\t// collect input for aggregate functions\n\t\t\tif proj.hasAggregate {\n\t\t\t\tfor key := range proj.aggrEvals {\n\t\t\t\t\tinput[key] = data.Array{}\n\t\t\t\t}\n\t\t\t}\n\t\t\t// now evaluate this projection on the flattened data.\n\t\t\t// note that input has *only* the keys of the empty\n\t\t\t// arrays, no other columns, but we cannot have other\n\t\t\t// columns involved in the projection (since we know\n\t\t\t// that GROUP BY is empty).\n\t\t\tvalue, err := proj.evaluator.Eval(input)\n\t\t\tif err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\t\t\tif err := assignOutputValue(result, proj.alias, proj.aliasPath, value); err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\t\t}\n\t\toutput = append(output, resultRow{row: result, hash: data.Hash(result)})\n\t\treturn nil\n\t}\n\n\t// compute the output for each item in ep.filteredInputRows\n\tfor e := ep.filteredInputRows.Front(); e != nil; e = e.Next() {\n\t\titem := e.Value.(*inputRowWithCachedResult)\n\t\tif err := evalItem(item); err != nil {\n\t\t\trollback()\n\t\t\treturn err\n\t\t}\n\t}\n\n\t// if we arrive here, then the input for the aggregation functions\n\t// is in the `group` list and we need to compute aggregation and output.\n\t// NB. we do not directly loop over the `groups` map to avoid random order.\n\tfor _, groupKey := range groupKeys {\n\t\tgroupsWithSameHash := groups[groupKey]\n\t\tfor _, group := range groupsWithSameHash {\n\t\t\tif err := evalGroup(group); err != nil {\n\t\t\t\trollback()\n\t\t\t\treturn err\n\t\t\t}\n\t\t}\n\t}\n\tif len(groups) == 0 {\n\t\tif err := evalNoGroup(); err != nil {\n\t\t\trollback()\n\t\t\treturn err\n\t\t}\n\t}\n\n\tep.curResults = output\n\treturn nil\n}", "func mlWorker(str string, threads int, wg *sync.WaitGroup, parallel bool){\n\n\t// Convert the string to JSON format\n\tvar job MLJob\n\tjson.Unmarshal([]byte(str), &job)\n\n\n\t// Loop through the parameters to check which are numeric\n\t// We will be turning int slices like [1,4] -> [1,2,3,4]\n\tfor i:=0; i<len(job.ParameterRange); i++{\n\n\t\t// If the data is numeric\n\t\tif \"float64\" == reflect.TypeOf(job.ParameterRange[i][0]).String(){\n\n\t\t\t// Get the Min of the range\n\t\t\tmin := job.ParameterRange[i][0].(float64)\n\t\t\t// Get the Max of the range\n\t\t\ttop := job.ParameterRange[i][1].(float64)\n\n\t\t\t// Loop through all the values between min and max\n\t\t\t// and append to the array\n\t\t\tfor j := min; j<=top; j++{\n\t\t\t\tjob.ParameterRange[i] = append(job.ParameterRange[i], j)\n\n\t\t\t}\n\n\t\t\t// Get rid of the first two values (our original min/max values)\n\t\t\tjob.ParameterRange[i] = job.ParameterRange[i][2:]\n\t\t}\n\n\t}\n\n\t// Create an array that holds ML Request Objects\n\t// Each object will correspond to a specific model with specific parameters\n\tvar requests []MLRequest\n\n\t// Loop through all the parameters\n\t// The if/else blocks will dictate where to go\n\t// depending on how many parameters the user gives\n\tfor i:=0; i<len(job.ParameterRange[0]); i++{\n\n\t\t// If the user specifies more than 1 parameter\n\t\tif len(job.ParameterRange) > 1{\n\n\t\t\t// If the user Specifies 2 or more parameters\n\t\t\tfor j:=0; j<len(job.ParameterRange[1]); j++{\n\t\t\t\tif len(job.ParameterRange) > 2{\n\n\t\t\t\t\t// If the user Specifies 3 parameters\n\t\t\t\t\tfor k:=0; k<len(job.ParameterRange[2]); k++{\n\t\t\t\t\t\trequest := MLRequest{\n\t\t\t\t\t\t\tModel: job.Model,\n\t\t\t\t\t\t\tParameters: job.Parameters,\n\t\t\t\t\t\t\tParameterValues: fmt.Sprint(job.ParameterRange[0][i])+\"_\"+fmt.Sprint(job.ParameterRange[1][j])+\"_\"+fmt.Sprint(job.ParameterRange[2][k]),\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\trequests = append(requests, request)\n\n\t\t\t\t\t}\n\n\t\t\t\t// If the user Specifies 2 parameters\n\t\t\t\t}else{\n\t\t\t\t\trequest := MLRequest{\n\t\t\t\t\t\tModel: job.Model,\n\t\t\t\t\t\tParameters: job.Parameters,\n\t\t\t\t\t\tParameterValues: fmt.Sprint(job.ParameterRange[0][i])+\"_\"+fmt.Sprint(job.ParameterRange[1][j]),\n\t\t\t\t\t}\n\n\t\t\t\t\trequests = append(requests, request)\n\t\t\t\t}\n\n\t\t\t}\n\n\t\t// If the user Specifies 1 parameter\n\t\t}else{\n\t\t\trequest := MLRequest{\n\t\t\t\tModel: job.Model,\n\t\t\t\tParameters: job.Parameters,\n\t\t\t\tParameterValues: fmt.Sprint(job.ParameterRange[0][i]),\n\t\t\t}\n\n\t\t\trequests = append(requests, request)\n\t\t}\n\n\t}\n\n\t// Variable to hold best model\n\tvar globalMax float64\n\tvar bestModel MLRequest\n\n\t// If we are running in parallel\n\tif parallel{\n\t\tvar size int\n\n\t\t// Channel that will be used for synchronization\n\t\tthreadComplete := make(chan MLRequest, threads)\n\n\t\t// If there are more models to test than threads\n\t\tif len(requests) > threads{\n\n\t\t\t// Get the Partition\n\t\t\ty := len(requests)\n\t\t\tpartitions := y/threads\n\n\t\t\t// Range of first partition\n\t\t\tlo := 0\n\t\t\thi:=partitions\n\n\t\t\t// Spawn a go routine for each thread\n\t\t\tfor i:=0; i<threads; i++{\n\t\t\t\tgo mlParallel(lo, hi, requests, threadComplete)\n\n\t\t\t\t// Update the range of our partitions\n\t\t\t\tlo += partitions\n\n\t\t\t\t// For the last thread, take all remaining tasks\n\t\t\t\tif i == threads-2{\n\t\t\t\t\thi = len(requests)\n\n\t\t\t\t}else{\n\t\t\t\t\thi += partitions\n\t\t\t\t}\n\t\t\t}\n\t\t\tsize = threads\n\n\t\t// If there are more thread than requests\n\t\t}else{\n\t\t\t// Spawn go routines according the amount of request\n\t\t\tfor i:=0;i<len(requests);i++{\n\t\t\t\tgo mlParallel(i, i+1, requests, threadComplete)\n\t\t\t}\n\t\t\tsize = len(requests)\n\n\t\t}\n\n\t\t// Synchronize go routines to wait here before moving on\n\t\t// This chunk also determines the best model to use\n\t\tfor j:=0; j<size; j++{\n\n\t\t\t// Get the model accuracy\n\t\t\ttemp := <- threadComplete\n\n\t\t\t// Update max accordingly\n\t\t\tif temp.Accuracy > globalMax{\n\t\t\t\tglobalMax = temp.Accuracy\n\t\t\t\tbestModel = temp\n\t\t\t}\n\t\t}\n\n\t// Sequential Version\n\t} else{\n\t\t// Loop through requests\n\t\tfor i:=0; i<len(requests); i++{\n\n\t\t\t// Call the Python Function\n\t\t\t// Learned how to do this from:\n\t\t\t// https://stackoverflow.com/questions/27021517/go-run-external-python-script\n\t\t\tcmd,_ := exec.Command(\"python\", \"src/ml.py\", requests[i].Model, fmt.Sprint(requests[i].Parameters), requests[i].ParameterValues).Output()\n\n\t\t\t// Get the results and process them\n\t\t\tresult := strings.TrimSuffix(string(cmd), \"\\n\")\n\t\t\ttemp,_ := strconv.ParseFloat(result, 64)\n\n\t\t\t// Update max accordingly\n\t\t\tif temp > globalMax{\n\t\t\t\tglobalMax = temp\n\t\t\t\tbestModel = requests[i]\n\t\t\t}\n\n\t\t}\n\n\t}\n\n\t// Print the Best Model, along with parameters and accuracy, to the user\n\tbestModel.Accuracy = globalMax\n\tfmt.Println(\"Model: \",bestModel.Model)\n\tbest_params := strings.Split(bestModel.ParameterValues,\"_\")\n\tfor i:=0;i<len(bestModel.Parameters);i++{\n\t\tfmt.Println(bestModel.Parameters[i]+\" : \"+best_params[i])\n\t}\n\tfmt.Println(\"Accuracy: \",bestModel.Accuracy)\n\tfmt.Println()\n\n\t// If running parallel, signal done\n\tif parallel{\n\t\twg.Done()\n\t}\n\n}", "func workers(done *int, jobs <-chan int, arrayA, arrayB, arrayF *arr) {\r\n\t// Inicia uma trhead para cada linha da matriz.\r\n\tfor job := range jobs {\r\n\t\tgo partial(job, done, arrayA, arrayB, arrayF)\r\n\t}\r\n}", "func RunPool(number int, paths <-chan string) <-chan string {\n\tresults := make(chan string, 10)\n\n\tgo func() {\n\t\twg := new(sync.WaitGroup)\n\n\t\tfor i := 0; i < number; i++ {\n\t\t\twg.Add(1)\n\t\t\tgo runWorker(paths, results, wg)\n\t\t}\n\n\t\twg.Wait()\n\n\t\tclose(results)\n\t}()\n\n\treturn results\n}", "func DispatchCompute(num_groups_x uint32, num_groups_y uint32, num_groups_z uint32) {\n\tC.glowDispatchCompute(gpDispatchCompute, (C.GLuint)(num_groups_x), (C.GLuint)(num_groups_y), (C.GLuint)(num_groups_z))\n}", "func DispatchCompute(num_groups_x uint32, num_groups_y uint32, num_groups_z uint32) {\n\tC.glowDispatchCompute(gpDispatchCompute, (C.GLuint)(num_groups_x), (C.GLuint)(num_groups_y), (C.GLuint)(num_groups_z))\n}", "func newBatchJobPool(ctx context.Context, o ObjectLayer, workers int) *BatchJobPool {\n\tjpool := &BatchJobPool{\n\t\tctx: ctx,\n\t\tobjLayer: o,\n\t\tjobCh: make(chan *BatchJobRequest, 10000),\n\t\tworkerKillCh: make(chan struct{}, workers),\n\t}\n\tjpool.ResizeWorkers(workers)\n\tjpool.resume()\n\treturn jpool\n}", "func DispatchCompute(num_groups_x uint32, num_groups_y uint32, num_groups_z uint32) {\n\tsyscall.Syscall(gpDispatchCompute, 3, uintptr(num_groups_x), uintptr(num_groups_y), uintptr(num_groups_z))\n}", "func multiWork(nums []float64) {\n\tch := make(chan float64)\n\tvar wg sync.WaitGroup\n\twg.Add(len(nums))\n\n\tfor i := 0; i < runtime.NumCPU(); i++ {\n\t\tgo poolWorker(ch, &wg)\n\t}\n\n\tfor _, i := range nums {\n\t\tch <- i\n\t}\n\n\twg.Wait()\n\tclose(ch)\n}", "func wait_group() {\n\tno := 3\n\tvar wg sync.WaitGroup\n\tfor i := 0; i < no; i++ {\n\t\twg.Add(1)\n\t\tgo process_wg(i, &wg)\n\t}\n\twg.Wait()\n\tfmt.Println(\"All go routines finished executing\")\n}", "func main() {\n\tconnAB, K := scributil.ParseFlags()\n\tprotocol := Gather.New()\n\n\tgather.WaitConn = make(chan struct{}) // Wait for servers to be ready\n\twg := new(sync.WaitGroup)\n\twg.Add(K + 1)\n\tfor i := 1; i <= K; i++ {\n\t\tgo gather.A1toK(protocol, K, i, connAB, \"localhost\", connAB.Port(i), wg)\n\t}\n\tgo gather.B(protocol, K, 1, connAB, connAB.BasePort(), wg)\n\twg.Wait()\n}", "func workerpool() {\n\tworkers := 3\n\tworkchan := make(chan int)\n\tfor i := 0; i < workers; i++ {\n\t\tgo func() {\n\t\t\tfor i := range workchan {\n\t\t\t\ttime.Sleep(3 * time.Second)\n\t\t\t\tfmt.Println(\"Workerpool worked on \", i)\n\t\t\t}\n\t\t}()\n\t}\n\tamountOfWork := 10\n\tfor i := 0; i < amountOfWork; i++ {\n\t\tworkchan <- i\n\t}\n\tfmt.Println(\"Finished workerpool work\")\n\t//Give some time for goroutines to finish. To avoid using WaitGroup and loosing focus.\n\ttime.Sleep(5 * time.Second)\n}", "func distributor(p golParams, d distributorChans, alive chan []cell) {\n\n\t// Create the 2D slice to store the world.\n\tworld := make([][]byte, p.imageHeight)\n\n\tfor i := range world {\n\t\tworld[i] = make([]byte, p.imageWidth)\n\t}\n\n\t// Request the io goroutine to read in the image with the given filename.\n\td.io.command <- ioInput\n\tname_file := strings.Join([]string{strconv.Itoa(p.imageWidth), strconv.Itoa(p.imageHeight)}, \"x\")\n\td.io.filename <- name_file\n\n\t// The io goroutine sends the requested image byte by byte, in rows.\n\tfor y := 0; y < p.imageHeight; y++ {\n\t\tfor x := 0; x < p.imageWidth; x++ {\n\t\t\tval := <-d.io.inputVal\n\t\t\tif val != 0 {\n\t\t\t\tfmt.Println(\"Alive cell at\", x, y)\n\t\t\t\tworld[y][x] = val\n\t\t\t}\n\t\t}\n\t}\n\n\tp_pressed := make(chan bool)\n\tq_pressed := make(chan bool)\n\ts_pressed := make(chan bool)\n\tkey_chan := make(chan rune)\n\tgo key_actions(key_chan, p_pressed, s_pressed, q_pressed)\n\tgo getKeyboardCommand(key_chan)\n\twChans := commandsStruct{p_pressed, q_pressed, s_pressed}\n\n\t//Initialise a helper array to hard code the worker splits\n\tno_workers := p.threads\n\tsplits := make([]int, no_workers)\n\tif p.imageHeight%p.threads == 0 { // For worker threads equal to some power of 2\n\t\tfor i := 1; i < p.threads+1; i++ {\n\t\t\tsplits[i-1] = p.imageHeight / p.threads * i\n\t\t}\n\t} else {\n\t\tfor i := 1; i < p.threads; i++ { //Worker threads not equal to some power of 2 (works for odds)\n\t\t\tsplits[i-1] = p.imageHeight / p.threads * i\n\t\t}\n\t\tsplits[p.threads-1] = p.imageHeight\n\t}\n\n\t//Create a copy of the current world\n\toriginal_world := make([][]byte, p.imageHeight)\n\tfor i := range world {\n\t\toriginal_world[i] = make([]byte, p.imageWidth)\n\t}\n\tfor y := 0; y < p.imageHeight; y++ {\n\t\tfor x := 0; x < p.imageWidth; x++ {\n\t\t\toriginal_world[y][x] = world[y][x]\n\t\t}\n\t}\n\tvar wg sync.WaitGroup\n\twg.Add(1)\n\tgo workerManager(p, &wg, splits, original_world, world, wChans, d)\n\twg.Wait()\n\n\t// Create an empty slice to store coordinates of cells that are still alive after p.turns are done.\n\tvar finalAlive []cell\n\t// Go through the world and append the cells that are still alive.\n\tfor y := 0; y < p.imageHeight; y++ {\n\t\tfor x := 0; x < p.imageWidth; x++ {\n\t\t\tif world[y][x] != 0 {\n\t\t\t\tfinalAlive = append(finalAlive, cell{x: x, y: y})\n\t\t\t}\n\t\t}\n\t}\n\n\t// IO commands for output\n\td.io.command <- ioOutput\n\td.io.filename <- name_file\n\td.io.cells_alive <- finalAlive\n\n\t// Make sure that the Io has finished any output before exiting.\n\td.io.command <- ioCheckIdle\n\t<-d.io.idle\n\n\t// Return the coordinates of cells that are still alive.\n\talive <- finalAlive\n\n}", "func main() {\n\n\t// If invalid arguments then print usage statement.\n\tif len(os.Args) < 1 || len(os.Args) > 2 {\n\n\t\tprintUsage()\n\n\t} else if len(os.Args) == 2 { // Run parallel version.\n\t\t\n\t\tthreads, _ := strconv.Atoi(strings.Split(os.Args[1],\"=\")[1])\n\t\truntime.GOMAXPROCS(threads)\n\t\timageTasks := make(chan *imagetask.ImageTask)\n\t\timageResults := make(chan *imagetask.ImageTask)\n\t\tdoneWorker := make(chan bool)\n\t\tdoneSave := make(chan bool)\n\n\t\t// Read from standard input (initial generator).\n\t\t// Image tasks go to imageTasks channel which is consumed by multiple workers (fan out).\n\t\tgo func() {\n\t\t\tscanner := bufio.NewScanner(os.Stdin)\n\t\t\tfor scanner.Scan() {\n\t\t\t\timageTaskText := scanner.Text()\n\t\t\t\timgTask := imagetask.CreateImageTask(imageTaskText)\n\t\t\t\timageTasks <- imgTask\n\t\t\t}\n\t\t\tclose(imageTasks)\n\t\t}()\n\n\t\t// Spawn worker goroutines to split up images, filter the portions, and recombine images.\n\t\tfor i := 0; i < threads; i++ {\n\t\t\tgo worker(threads, doneWorker, imageTasks, imageResults)\n\t\t}\n\n\t\t// Save results.\n\t\tgo func() {\n\t\t\tfor true { // Do while there are more images to save.\n\t\t\t\timgTask, more := <- imageResults // Reads from the image results channel.\n\t\t\t\tif more {\n\t\t\t\t\timgTask.SaveImageTaskOut()\n\t\t\t\t} else {\n\t\t\t\t\tdoneSave <- true \n\t\t\t\t\treturn\n\t\t\t\t}\n\t\t\t}\n\t\t}()\n\n\t\t// Wait for all workers to return.\n\t\tfor i := 0; i < threads; i++ {\n\t\t\t<-doneWorker\n\t\t}\n\n\t\t// Wait for all images to be saved.\n\t\tclose(imageResults)\n\t\t<- doneSave\n\n\t} else { // Run sequential version if '-p' flag not given.\n\n\t\t// Read in image tasks from standard input.\n\t\tscanner := bufio.NewScanner(os.Stdin)\n\t\tfor scanner.Scan() {\n\t\t\timageTaskText := scanner.Text()\n\t\t\timgTask := imagetask.CreateImageTask(imageTaskText)\n\n\t\t\t// Apply the specified effects to the given image.\n\t\t\tfor i, effect := range imgTask.Effects {\n\t\t\t\tif i > 0 {\n\t\t\t\t\timgTask.Img.UpdateInImg()\n\t\t\t\t}\n\t\t\t\tif effect != \"G\" {\n\t\t\t\t\timgTask.Img.ApplyConvolution(effect)\n\t\t\t\t} else {\n\t\t\t\t\timgTask.Img.Grayscale()\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t// Save filtered image.\n\t\t\timgTask.SaveImageTaskOut()\n\n\t\t}\n\n\t}\n\n}", "func (fl *FlowLauncher) Exec(p Props) {\n\n\tendParams := MakeParams()\n\tendParams.Props = p\n\n\t// make fresh chanels on each exec as they were probably closed\n\tfl.CStat = make(chan *Params)\n\tfl.iEnd = make(chan *Params)\n\n\tif fl.LastRunResult == nil {\n\t\tfl.LastRunResult = &FlowLaunchResult{}\n\t}\n\tfl.Error = \"\"\n\n\tif fl.TidyDeskPolicy(p) == false {\n\t\tendParams.Status = FAIL\n\t\tfl.iEnd <- endParams\n\t\treturn\n\t}\n\n\tglog.Info(\"workflow launcher \", fl.Name, \" with \", fl.Threads, \" threads\")\n\tvar waitGroup sync.WaitGroup\n\n\tfl.Flows = make([]*Workflow, fl.Threads, fl.Threads)\n\n\t// fire off some threads\n\tfor i := 0; i < fl.Threads; i++ {\n\n\t\t// create a new workflow\n\t\tflow := fl.FlowFunc(i)\n\n\t\t// save it for later\n\t\tfl.Flows[i] = flow\n\n\t\t// only realy need to do this once - but hey\n\t\tendParams.FlowName = flow.Name\n\n\t\tglog.Info(\"workflow launch \", flow.Name, \" with threadid \", i)\n\n\t\t// check some conditions...\n\t\tif flow == nil {\n\t\t\tglog.Error(flow.Name, \" has no flow\")\n\t\t\treturn\n\t\t}\n\n\t\tif flow.Start == nil {\n\t\t\tglog.Error(flow.Name, \" has no flow start\")\n\t\t\treturn\n\t\t}\n\n\t\tif flow.End == nil {\n\t\t\tglog.Error(flow.Name, \" has no flow end\")\n\t\t\treturn\n\t\t}\n\n\t\t// for the first thread make the results including capturing any streamed io from the tasks\n\t\tif i == 0 {\n\t\t\tfl.MakeLaunchResults(flow)\n\t\t}\n\n\t\t// TOOD - here you would inject any function to vary the params per thread\n\t\tparams := MakeParams()\n\t\tparams.Props = p\n\t\tparams.FlowName = flow.Name\n\t\tparams.ThreadId = i\n\n\t\tglog.Info(\"firing task with params \", params)\n\n\t\t// build up the thread wait group\n\t\twaitGroup.Add(1)\n\n\t\t// and fire of the workflow\n\t\tgo flow.Exec(params)\n\n\t\t// loop round forwarding status updates\n\t\tgo func() {\n\t\t\tglog.Info(\"waiting on chanel flow.C \")\n\t\t\tfor stat := range flow.C {\n\t\t\t\tglog.Info(\"got status \", stat)\n\t\t\t\tfl.LastRunResult.AddStatusOrResult(stat.TaskId, stat.Complete, stat.Status)\n\t\t\t\tfl.CStat <- stat // tiger any stats change chanel (e.g. for push messages like websockets)\n\t\t\t}\n\t\t\tglog.Info(\"launcher status loop stoppped\")\n\t\t}()\n\n\t\t// set up the flow end trigger - the end registered node will fire this\n\t\tgo func() {\n\t\t\tpar := <-flow.End.Trigger()\n\t\t\tglog.Info(\"got flow end \", par.ThreadId, \" \", flow.End.GetName())\n\t\t\t// collect all end event triggers - last par wins\n\t\t\tendParams.Status = endParams.Status + par.Status\n\n\t\t\t// update metrics\n\t\t\tnow := time.Now()\n\t\t\tfl.LastRunResult.Duration = now.Sub(fl.LastRunResult.Start)\n\n\t\t\t// close the flow status chanel\n\t\t\tclose(flow.C)\n\n\t\t\t// count down the waitgroup\n\t\t\twaitGroup.Done()\n\t\t}()\n\t}\n\n\t// now lets wait for all the threads to finish - probably TODO a timeout as well in case of bad flows...\n\tgo func() {\n\t\twaitGroup.Wait()\n\t\tglog.Info(\"completed launcher \", fl.Name, \" with \", fl.Threads, \" threads\")\n\t\t// mark status\n\t\tfl.LastRunResult.Completed = true\n\n\t\t// close the status channel\n\t\tclose(fl.CStat)\n\n\t\t// and trigger the end event\n\t\tfl.iEnd <- endParams\n\t}()\n}", "func (e *storageExecutor) executeGroupBy(shard tsdb.Shard, rs *timeSpanResultSet, seriesIDs *roaring.Bitmap) {\n\tgroupingResult := &groupingResult{}\n\tvar groupingCtx series.GroupingContext\n\t// timespans sorted by family\n\ttimeSpans := rs.getTimeSpans()\n\tif e.ctx.query.HasGroupBy() {\n\t\t// 1. grouping, if has group by, do group by tag keys, else just split series ids as batch first,\n\t\t// get grouping context if need\n\t\ttagKeys := make([]uint32, len(e.groupByTagKeyIDs))\n\t\tfor idx, tagKeyID := range e.groupByTagKeyIDs {\n\t\t\ttagKeys[idx] = tagKeyID.ID\n\t\t}\n\t\tt := newGroupingContextFindTask(e.ctx, shard, tagKeys, seriesIDs, groupingResult)\n\t\terr := t.Run()\n\t\tif err != nil && !errors.Is(err, constants.ErrNotFound) {\n\t\t\t// maybe group by not found, so ignore not found err\n\t\t\te.queryFlow.Complete(err)\n\t\t\treturn\n\t\t}\n\t\tif groupingResult.groupingCtx == nil {\n\t\t\treturn\n\t\t}\n\t\tgroupingCtx = groupingResult.groupingCtx\n\t}\n\tseriesIDsHighKeys := seriesIDs.GetHighKeys()\n\te.pendingForGrouping.Add(int32(len(seriesIDsHighKeys)))\n\tvar groupWait atomic.Int32\n\tgroupWait.Add(int32(len(seriesIDsHighKeys)))\n\n\tfor seriesIDHighKeyIdx, seriesIDHighKey := range seriesIDsHighKeys {\n\t\tseriesIDHighKey := seriesIDHighKey\n\t\t// be carefully, need use new variable for variable scope problem\n\t\tcontainerOfSeries := seriesIDs.GetContainerAtIndex(seriesIDHighKeyIdx)\n\n\t\t// grouping based on group by tag keys for each container\n\t\te.queryFlow.Grouping(func() {\n\t\t\tdefer func() {\n\t\t\t\tgroupWait.Dec()\n\t\t\t\tif groupingCtx != nil && groupWait.Load() == 0 {\n\t\t\t\t\t// current group by query completed, need merge group by tag value ids\n\t\t\t\t\te.mergeGroupByTagValueIDs(groupingCtx.GetGroupByTagValueIDs())\n\t\t\t\t}\n\t\t\t\te.pendingForGrouping.Dec()\n\t\t\t\t// try start collect tag values for group by query\n\t\t\t\te.collectGroupByTagValues()\n\t\t\t}()\n\t\t\tgroupedResult := &groupedSeriesResult{}\n\t\t\tt := newBuildGroupTaskFunc(e.ctx, shard, groupingCtx, seriesIDHighKey, containerOfSeries, groupedResult)\n\t\t\tif err := t.Run(); err != nil {\n\t\t\t\te.queryFlow.Complete(err)\n\t\t\t\treturn\n\t\t\t}\n\n\t\t\te.queryFlow.Load(func() {\n\t\t\t\tfor _, span := range timeSpans {\n\t\t\t\t\t// 3.load data by grouped seriesIDs\n\t\t\t\t\tt := newDataLoadTaskFunc(e.ctx, shard, e.queryFlow, span,\n\t\t\t\t\t\tseriesIDHighKey, containerOfSeries)\n\t\t\t\t\tif err := t.Run(); err != nil {\n\t\t\t\t\t\te.queryFlow.Complete(err)\n\t\t\t\t\t\treturn\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tgrouped := groupedResult.groupedSeries\n\t\t\t\tfieldSeriesList := make([][]*encoding.TSDDecoder, len(e.fields))\n\t\t\t\tfieldAggList := make(aggregation.FieldAggregates, len(e.fields))\n\t\t\t\taggSpecs := e.storageExecutePlan.getAggregatorSpecs()\n\t\t\t\tfor idx := range e.fields {\n\t\t\t\t\tfieldSeriesList[idx] = make([]*encoding.TSDDecoder, rs.filterRSCount)\n\t\t\t\t\tfieldAggList[idx] = aggregation.NewSeriesAggregator(\n\t\t\t\t\t\te.ctx.query.Interval,\n\t\t\t\t\t\te.queryIntervalRatio,\n\t\t\t\t\t\te.ctx.query.TimeRange,\n\t\t\t\t\t\taggSpecs[idx])\n\t\t\t\t}\n\n\t\t\t\tdefer func() {\n\t\t\t\t\tif r := recover(); r != nil {\n\t\t\t\t\t\tstorageQueryFlowLogger.Error(\"executeGroupBy\",\n\t\t\t\t\t\t\tlogger.Error(fmt.Errorf(\"panic: %v\", e)),\n\t\t\t\t\t\t\tlogger.Stack())\n\t\t\t\t\t}\n\t\t\t\t}()\n\t\t\t\tfor tags, seriesIDs := range grouped {\n\t\t\t\t\t// scan metric data from storage(memory/file)\n\t\t\t\t\tfor _, seriesID := range seriesIDs {\n\t\t\t\t\t\tfor _, span := range timeSpans {\n\t\t\t\t\t\t\t// loads the metric data by given series id from load result.\n\t\t\t\t\t\t\tfor resultSetIdx, loader := range span.loaders {\n\t\t\t\t\t\t\t\t// load field series data by series ids\n\t\t\t\t\t\t\t\tslotRange2, fieldSpanBinary := loader.Load(seriesID)\n\t\t\t\t\t\t\t\tfor fieldIndex := range fieldSpanBinary {\n\t\t\t\t\t\t\t\t\tspanBinary := fieldSpanBinary[fieldIndex]\n\t\t\t\t\t\t\t\t\tfieldsTSDDecoders := fieldSeriesList[fieldIndex]\n\t\t\t\t\t\t\t\t\tif spanBinary != nil {\n\t\t\t\t\t\t\t\t\t\tif fieldsTSDDecoders[resultSetIdx] == nil {\n\t\t\t\t\t\t\t\t\t\t\tfieldsTSDDecoders[resultSetIdx] = encoding.GetTSDDecoder()\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\tfieldsTSDDecoders[resultSetIdx].ResetWithTimeRange(spanBinary, slotRange2.Start, slotRange2.End)\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\tfor idx, fieldSeries := range fieldSeriesList {\n\t\t\t\t\t\t\t\tvar agg aggregation.FieldAggregator\n\t\t\t\t\t\t\t\tvar ok bool\n\t\t\t\t\t\t\t\tagg, ok = fieldAggList[idx].GetAggregator(span.familyTime)\n\t\t\t\t\t\t\t\tif !ok {\n\t\t\t\t\t\t\t\t\tcontinue\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\tstart, end := agg.SlotRange()\n\t\t\t\t\t\t\t\ttarget := timeutil.SlotRange{\n\t\t\t\t\t\t\t\t\tStart: uint16(start),\n\t\t\t\t\t\t\t\t\tEnd: uint16(end),\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\taggregation.DownSamplingMultiSeriesInto(\n\t\t\t\t\t\t\t\t\ttarget, uint16(e.queryIntervalRatio),\n\t\t\t\t\t\t\t\t\te.fields[idx].Type,\n\t\t\t\t\t\t\t\t\tfieldSeries,\n\t\t\t\t\t\t\t\t\tagg.AggregateBySlot,\n\t\t\t\t\t\t\t\t)\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\te.queryFlow.Reduce(tags, fieldAggList.ResultSet(tags))\n\t\t\t\t\t// reset aggregate context\n\t\t\t\t\tfieldAggList.Reset()\n\t\t\t\t}\n\t\t\t})\n\t\t})\n\t}\n}", "func Execute(nbIterations int, work func(int, int), maxCpus ...int) {\n\n\tnbTasks := runtime.NumCPU()\n\tif len(maxCpus) == 1 {\n\t\tnbTasks = maxCpus[0]\n\t}\n\tnbIterationsPerCpus := nbIterations / nbTasks\n\n\t// more CPUs than tasks: a CPU will work on exactly one iteration\n\tif nbIterationsPerCpus < 1 {\n\t\tnbIterationsPerCpus = 1\n\t\tnbTasks = nbIterations\n\t}\n\n\tvar wg sync.WaitGroup\n\n\textraTasks := nbIterations - (nbTasks * nbIterationsPerCpus)\n\textraTasksOffset := 0\n\n\tfor i := 0; i < nbTasks; i++ {\n\t\twg.Add(1)\n\t\t_start := i*nbIterationsPerCpus + extraTasksOffset\n\t\t_end := _start + nbIterationsPerCpus\n\t\tif extraTasks > 0 {\n\t\t\t_end++\n\t\t\textraTasks--\n\t\t\textraTasksOffset++\n\t\t}\n\t\tgo func() {\n\t\t\twork(_start, _end)\n\t\t\twg.Done()\n\t\t}()\n\t}\n\n\twg.Wait()\n}", "func fetchBatched(ctx context.Context, log log.Logger, requests []rpc.BatchElem, getBatch batchCallContextFn, maxRetry int, maxPerBatch int, maxParallel int) error {\n\tbatchRequest := func(ctx context.Context, missing []rpc.BatchElem) (failed []rpc.BatchElem, err error) {\n\t\tif err := getBatch(ctx, missing); err != nil {\n\t\t\treturn nil, fmt.Errorf(\"failed batch-retrieval: %w\", err)\n\t\t}\n\t\tfor _, elem := range missing {\n\t\t\tif elem.Error != nil {\n\t\t\t\tlog.Trace(\"batch request element failed\", \"err\", elem.Error, \"elem\", elem.Args[0])\n\t\t\t\telem.Error = nil // reset, we'll try this element again\n\t\t\t\tfailed = append(failed, elem)\n\t\t\t\tcontinue\n\t\t\t}\n\t\t}\n\t\treturn failed, nil\n\t}\n\n\t// limit capacity, don't write to underlying array on retries\n\trequests = requests[:len(requests):len(requests)]\n\n\texpectedBatches := (len(requests) + maxPerBatch - 1) / maxPerBatch\n\n\t// don't need more go-routines than requests\n\tif maxParallel > expectedBatches {\n\t\tmaxParallel = expectedBatches\n\t}\n\n\t// capacity is sufficient for no go-routine to get stuck on writing\n\tcompleted := make(chan batchResult, maxParallel)\n\n\t// queue of tasks for worker go-routines\n\tbatchRequests := make(chan []rpc.BatchElem, maxParallel)\n\tdefer close(batchRequests)\n\tctx, cancel := context.WithCancel(ctx)\n\tdefer cancel()\n\n\t// starts worker go-routines. Closed when task channel closes\n\tfor i := 0; i < maxParallel; i++ {\n\t\tgo func(ctx context.Context) {\n\t\t\tfor {\n\t\t\t\tbatch, ok := <-batchRequests\n\t\t\t\tif !ok {\n\t\t\t\t\treturn // no more batches left\n\t\t\t\t}\n\t\t\t\tfailed, err := batchRequest(ctx, batch)\n\t\t\t\tcompleted <- batchResult{failed: failed, err: err, success: len(batch) - len(failed)}\n\t\t\t}\n\t\t}(ctx)\n\t}\n\n\tparallelRequests := func() int {\n\t\t// we split the requests into parallel batch requests, and count how many\n\t\ti := 0\n\t\tfor ; i < maxParallel && len(requests) > 0; i++ {\n\t\t\tnextBatch := requests\n\t\t\tif len(nextBatch) > maxPerBatch {\n\t\t\t\tnextBatch = requests[:maxPerBatch]\n\t\t\t}\n\t\t\t// don't retry this batch of requests again, unless we add them back\n\t\t\trequests = requests[len(nextBatch):]\n\n\t\t\t// schedule the batch, this may block if all workers are busy and the queue is full\n\t\t\tbatchRequests <- nextBatch\n\t\t}\n\t\treturn i\n\t}\n\n\tmaxCount := expectedBatches * maxRetry\n\n\tawaited := len(requests)\n\n\t// start initial round of parallel requests\n\tcount := parallelRequests()\n\n\t// We slow down additional batch requests to not spam the server.\n\tretryTicker := time.NewTicker(time.Millisecond * 20)\n\tdefer retryTicker.Stop()\n\n\t// The main requests slice is only ever mutated by the go-routine running this loop.\n\t// Slices of this are sent to worker go-routines, and never overwritten with different requests.\n\tfor {\n\t\t// check if we've all results back successfully\n\t\tif awaited <= 0 {\n\t\t\treturn nil\n\t\t}\n\t\tif count > maxCount {\n\t\t\treturn TooManyRetries\n\t\t}\n\t\tselect {\n\t\tcase <-retryTicker.C:\n\t\t\tcount += parallelRequests() // retry batch-requests on interval\n\t\tcase result := <-completed:\n\t\t\tif result.err != nil {\n\t\t\t\t// batch failed, RPC may be broken, abort\n\t\t\t\treturn fmt.Errorf(\"batch request failed: %w\", result.err)\n\t\t\t}\n\t\t\t// if any element failed, add it to the requests for re-attempt\n\t\t\trequests = append(requests, result.failed...)\n\t\t\tawaited -= result.success\n\t\tcase <-ctx.Done():\n\t\t\treturn ctx.Err()\n\t\t}\n\t}\n}", "func runExperiment(numberOfCalls int, wg *sync.WaitGroup, calc *utils.CalcValues, start int) {\n\tdefer wg.Done()\n\t// getting the clientproxy\n\tnamingServer := namingproxy.InitServer(\"localhost\")\n\tmanager := namingServer.Lookup(\"Manager\").(proxies.ManagerProxy)\n\t// executing\n\tfor i := 0; i < numberOfCalls; i++ {\n\t\tcurrent := i + start\n\n\t\tswitch current % 3 {\n\t\tcase 0:\n\t\t\tp := person.InitPerson(\"lucas\", 10, \"M\", 1)\n\t\t\tinitialTime := time.Now() //calculating time\n\t\t\tresult := manager.AddPerson(*p) // making the request\n\t\t\tendTime := float64(time.Now().Sub(initialTime).Milliseconds()) // RTT\n\t\t\tfmt.Println(current, result) // making the request\n\t\t\tutils.AddValue(calc, endTime) // pushing to the stored values\n\t\tcase 1:\n\t\t\tinitialTime := time.Now() //calculating time\n\t\t\tmanager.Write(\"files\") // making the request\n\t\t\tendTime := float64(time.Now().Sub(initialTime).Milliseconds()) // RTT\n\t\t\tutils.AddValue(calc, endTime)\n\t\tcase 2:\n\t\t\tinitialTime := time.Now() //calculating time\n\t\t\tname := manager.GetName(1) // making the request\n\t\t\tendTime := float64(time.Now().Sub(initialTime).Milliseconds()) // RTT\n\t\t\tutils.AddValue(calc, endTime)\n\t\t\tfmt.Println(current, name)\n\t\t}\n\n\t\ttime.Sleep(10 * time.Millisecond) // setting the sleep time\n\t}\n}", "func runPool(wg sync.WaitGroup, name string) {\n\tvar err error\n\n\t//set up queue of workers\n\tcluster, err := helpers.ReadConfig(name) //TODO - ugh, naming\n\tif err != nil {\n\t\t//log the bad, do the bad, this is bad\n\t}\n\n\tStandbyQueue = cluster.Nodes\n\n\t//this is how we do graceful shutdown, waiting to close channels until all workers goroutines have stopped\n\ttotalWorkers := len(StandbyQueue)\n\tstoppedWorkers := 0\n\n\tmessages := make(chan MessageData, len(StandbyQueue))\n\tstopped := make(chan struct{}, len(StandbyQueue))\n\tstopWorkers := make(chan struct{}, len(StandbyQueue))\n\n\tgo func() {\n\t\tdefer close(stopWorkers)\n\n\t\tdefer func() {\n\t\t\twg.Done()\n\t\t}()\n\n\t\tfor {\n\t\t\tselect {\n\t\t\tcase msg := <-messages:\n\t\t\t\tif msg.RawText == \"eagle has flopped\" {\n\t\t\t\t\t//do the next worker\n\t\t\t\t\tif len(StandbyQueue) > 0 {\n\t\t\t\t\t\tnext := CreateWorker(StandbyQueue[0], messages, stopped, stopWorkers)\n\t\t\t\t\t\tStandbyQueue = StandbyQueue[1:]\n\n\t\t\t\t\t\tnext.WorkerUp()\n\t\t\t\t\t} else {\n\t\t\t\t\t\t//error, something is wrong we have spun up too many\n\t\t\t\t\t}\n\t\t\t\t} else {\n\t\t\t\t\tfmt.Printf(\"%s: %s\\n\", msg.CommandName, msg.RawText)\n\t\t\t\t}\n\t\t\tcase <-stopped:\n\t\t\t\tfmt.Println(\"stopped message received\")\n\t\t\t\tstoppedWorkers++\n\t\t\t\tif stoppedWorkers == totalWorkers {\n\t\t\t\t\tfmt.Println(\"all workers have closed, ready for restart\")\n\t\t\t\t\t//close everything down\n\t\t\t\t\treturn\n\t\t\t\t}\n\n\t\t\t}\n\t\t}\n\t}()\n\n\t//run the first worker, wait for a response to run the rest\n\tfmt.Printf(\"starting worker: %s\\n\", StandbyQueue[0].Name)\n\tnworker := CreateWorker(StandbyQueue[0], messages, stopped, stopWorkers)\n\tStandbyQueue = StandbyQueue[1:]\n\tnworker.WorkerUp()\n\n\twg.Wait()\n\n\t// return \"restart\"\n\n}", "func PoolParameters(config azconfig.AZConfig, netStack aznetwork.NetworkStack) batch.PoolAddParameter {\n\tmountOpts := azstorage.GetMountOptions(config, \"flamenco-resources\")\n\tstartCmd := fmt.Sprintf(\"bash -exc 'sudo mkdir -p /mnt/flamenco-resources; \"+\n\t\t\"sudo groupadd --force %s; \"+\n\t\t\"grep \\\" /mnt/flamenco-resources \\\" -q /proc/mounts || sudo mount -t cifs //%s.file.core.windows.net/flamenco-resources /mnt/flamenco-resources -o %s; \"+\n\t\t\"bash -ex /mnt/flamenco-resources/flamenco-worker-startup.sh'\",\n\t\tflamenco.UnixGroupName,\n\t\tconfig.StorageCreds.Username, mountOpts,\n\t)\n\n\treturn batch.PoolAddParameter{\n\t\tID: to.StringPtr(config.Batch.PoolID),\n\n\t\tVMSize: to.StringPtr(config.Batch.VMSize),\n\t\tMaxTasksPerNode: to.Int32Ptr(1),\n\t\tTargetDedicatedNodes: to.Int32Ptr(config.Batch.TargetDedicatedNodes),\n\t\tTargetLowPriorityNodes: to.Int32Ptr(config.Batch.TargetLowPriorityNodes),\n\n\t\tVirtualMachineConfiguration: &batch.VirtualMachineConfiguration{\n\t\t\tImageReference: &batch.ImageReference{\n\t\t\t\tPublisher: to.StringPtr(\"Canonical\"),\n\t\t\t\tSku: to.StringPtr(\"18.04-LTS\"),\n\t\t\t\tOffer: to.StringPtr(\"UbuntuServer\"),\n\t\t\t\tVersion: to.StringPtr(\"latest\"),\n\t\t\t},\n\t\t\tNodeAgentSKUID: to.StringPtr(\"batch.node.ubuntu 18.04\"),\n\t\t},\n\n\t\tNetworkConfiguration: &batch.NetworkConfiguration{\n\t\t\tSubnetID: to.StringPtr(netStack.SubnetID()),\n\t\t},\n\n\t\tStartTask: &batch.StartTask{\n\t\t\tCommandLine: to.StringPtr(startCmd),\n\t\t\tWaitForSuccess: to.BoolPtr(true),\n\t\t\tUserIdentity: &batch.UserIdentity{\n\t\t\t\tAutoUser: &batch.AutoUserSpecification{\n\t\t\t\t\tElevationLevel: \"Admin\",\n\t\t\t\t\tScope: \"Pool\",\n\t\t\t\t},\n\t\t\t},\n\t\t},\n\t}\n}", "func (s *System) spawn() {\n\tfor i := range s.threads {\n\t\tt := &s.threads[i]\n\t\tfor _, sr := range t.requests {\n\t\t\tstr := len(s.particles)\n\t\t\ts.particles.Resize(str + sr.Amount)\n\t\t\tfor i := 0; i < sr.Amount; i++ {\n\t\t\t\tr := sr.Rotation.Gen()\n\t\t\t\tvel := mat.Rad(sr.Spread.Gen()+sr.Dir, sr.Velocity.Gen())\n\t\t\t\tif sr.RotationRelativeToVelocity {\n\t\t\t\t\tr += vel.Angle()\n\t\t\t\t}\n\n\t\t\t\tp := &s.particles[i+str]\n\n\t\t\t\tp.Type = sr.Type\n\n\t\t\t\tp.vel = vel\n\t\t\t\tp.orig = sr.Pos\n\t\t\t\tp.pos = sr.Pos.Add(sr.Gen(sr.Dir))\n\n\t\t\t\tp.mask = sr.Mask.Mul(sr.Type.Mask.Gen())\n\n\t\t\t\tp.scl.X = sr.ScaleX.Gen()\n\t\t\t\tp.scl.Y = sr.ScaleY.Gen()\n\t\t\t\tp.livetime = 1 / sr.Livetime.Gen()\n\t\t\t\tp.twerk = sr.Twerk.Gen()\n\t\t\t\tp.rot = r\n\t\t\t\tp.progress = 0\n\n\t\t\t\tp.vertex = s.vertex\n\t\t\t\tp.indice = s.indice\n\n\t\t\t\ts.vertex += p.vertexes\n\t\t\t\ts.indice += p.indices\n\t\t\t}\n\t\t}\n\t\tt.requests = t.requests[:0]\n\t}\n}", "func makeWorkers(t *testing.T, n int, pool *string) []*types.Component {\n\tt.Helper()\n\tvar components []*types.Component\n\n\tif n < 1 {\n\t\treturn components\n\t}\n\n\tcomponents = append(components, types.NewComponent(testContainerImage, types.ServerComponent))\n\n\tfor i := n - 1; i > 0; i-- {\n\t\tcomponents = append(components, types.NewComponent(testContainerImage, types.ClientComponent))\n\t}\n\n\tif pool != nil {\n\t\tfor _, c := range components {\n\t\t\tc.PoolName = *pool\n\t\t}\n\t}\n\n\treturn components\n}", "func (mr *MapReduce) RunMaster() []int {\n\tnumMapJobs := mr.nMap\n\tnumReduceJobs := mr.nReduce\n\tvar w sync.WaitGroup\n\n\tfor mapJob := 0; mapJob < numMapJobs; mapJob++ {\n\t\tavailableWorker := <-mr.registerChannel\n\t\tfmt.Println(\"USING WORKER\", availableWorker, \"for Map Job\")\n\t\tw.Add(1)\n\t\tgo func(worker string, i int) {\n\t\t\tdefer w.Done()\n\t\t\tvar reply DoJobReply\n\t\t\targs := &DoJobArgs{mr.file, Map, i, mr.nReduce}\n\t\t\tok := call(worker, \"Worker.DoJob\", args, &reply)\n\t\t\tif !ok {\n\t\t\t\tfmt.Println(\"Map Job\", i, \"has FAILED\")\n\t\t\t} else {\n\t\t\t\tfmt.Println(\"Map Job\", i, \"is SUCCESS\")\n\t\t\t}\n\t\t\tmr.registerChannel <- worker\n\t\t}(availableWorker, mapJob)\n\t}\n\n\tw.Wait()\n\tfmt.Println(\"DONE WITH ALL MAP JOBS\")\n\n\tfor reduceJob := 0; reduceJob < numReduceJobs; reduceJob++ {\n\t\tavailableWorker := <-mr.registerChannel\n\t\tfmt.Println(\"USING WORKER\", availableWorker, \"for Reduce Job\")\n\t\tw.Add(1)\n\t\tgo func(worker string, i int) {\n\t\t\tdefer w.Done()\n\t\t\tvar reply DoJobReply\n\t\t\targs := &DoJobArgs{mr.file, Reduce, i, mr.nMap}\n\t\t\tok := call(worker, \"Worker.DoJob\", args, &reply)\n\t\t\tif !ok {\n\t\t\t\tfmt.Println(\"Reduce Job\", i, \"has FAILED\")\n\t\t\t} else {\n\t\t\t\tfmt.Println(\"Reduce Job\", i, \"is SUCCESS\")\n\t\t\t}\n\t\t\tmr.registerChannel <- worker\n\t\t}(availableWorker, reduceJob)\n\t}\n\n\tw.Wait()\n\tfmt.Println(\"DONE WITH ALL REDUCE JOBS\")\n\n\treturn mr.KillWorkers()\n}", "func ExecutePipeline(jobs ...job) {\r\n\twg := &sync.WaitGroup{}\r\n\tcountJobs := len(jobs)\r\n\tout := make(chan interface{})\r\n\tfor i := 0; i < countJobs; i++ {\r\n\t\tin := out\r\n\t\tout = make(chan interface{})\r\n\t\twg.Add(1)\r\n\t\tgo myGoroutine(in, out, jobs[i], wg)\r\n\t}\r\n\twg.Wait()\r\n}", "func worker(sz int, results chan<- Result, quit <-chan bool, done chan<- bool, g Generator) {\n\tfor {\n\t\tvar number, mean, sumSq float64\n\t\tfor i := 0; i < sz; i++ {\n\t\t\tv := g.Generate()\n\t\t\t// update accumulates the total sample statistics\n\t\t\tnumber, mean, sumSq = update(number, mean, sumSq, 1, v, 0)\n\t\t}\n\t\tselect {\n\t\tcase results <- Result{Mean: mean, SumSq: sumSq}:\n\t\tcase <-quit:\n\t\t\treturn\n\t\t}\n\t}\n}", "func groupCmd(c *cli.Context) error {\n\targs := c.Args()\n\tif !args.Present() {\n\t\tslog.Fatal(\"missing identity file to create the group.toml\")\n\t}\n\tif c.NArg() < 3 {\n\t\tslog.Fatal(\"not enough identities (\", c.NArg(), \") to create a group toml. At least 3!\")\n\t}\n\tvar threshold = key.DefaultThreshold(c.NArg())\n\tif c.IsSet(\"threshold\") {\n\t\tif c.Int(\"threshold\") < threshold {\n\t\t\tslog.Print(\"WARNING: You are using a threshold which is TOO LOW.\")\n\t\t\tslog.Print(\"\t\t It should be at least \", threshold)\n\t\t}\n\t\tthreshold = c.Int(\"threshold\")\n\t}\n\n\tpublics := make([]*key.Identity, c.NArg())\n\tfor i, str := range args {\n\t\tpub := &key.Identity{}\n\t\tslog.Print(\"Reading public identity from \", str)\n\t\tif err := key.Load(str, pub); err != nil {\n\t\t\tslog.Fatal(err)\n\t\t}\n\t\tpublics[i] = pub\n\t}\n\tgroup := key.NewGroup(publics, threshold)\n\tgroupPath := path.Join(fs.Pwd(), gname)\n\tif c.String(\"out\") != \"\" {\n\t\tgroupPath = c.String(\"out\")\n\t}\n\tif err := key.Save(groupPath, group, false); err != nil {\n\t\tslog.Fatal(err)\n\t}\n\tslog.Printf(\"Group file written in %s. Distribute it to all the participants to start the DKG\", groupPath)\n\treturn nil\n}", "func placeForks(ptp topology.PointToPoint, n int) {\n\tfor i := 0; i < n; i++ {\n\t\ttuplespace.Put(ptp, \"fork\", i)\n\t}\n}", "func (a *TopologySmartscapeProcessGroupApiService) GetProcessGroupsExecute(r ApiGetProcessGroupsRequest) ([]ProcessGroup, *_nethttp.Response, error) {\n\tvar (\n\t\tlocalVarHTTPMethod = _nethttp.MethodGet\n\t\tlocalVarPostBody interface{}\n\t\tlocalVarFormFileName string\n\t\tlocalVarFileName string\n\t\tlocalVarFileBytes []byte\n\t\tlocalVarReturnValue []ProcessGroup\n\t)\n\n\tlocalBasePath, err := a.client.cfg.ServerURLWithContext(r.ctx, \"TopologySmartscapeProcessGroupApiService.GetProcessGroups\")\n\tif err != nil {\n\t\treturn localVarReturnValue, nil, GenericOpenAPIError{error: err.Error()}\n\t}\n\n\tlocalVarPath := localBasePath + \"/entity/infrastructure/process-groups\"\n\n\tlocalVarHeaderParams := make(map[string]string)\n\tlocalVarQueryParams := _neturl.Values{}\n\tlocalVarFormParams := _neturl.Values{}\n\n\tif r.startTimestamp != nil {\n\t\tlocalVarQueryParams.Add(\"startTimestamp\", parameterToString(*r.startTimestamp, \"\"))\n\t}\n\tif r.endTimestamp != nil {\n\t\tlocalVarQueryParams.Add(\"endTimestamp\", parameterToString(*r.endTimestamp, \"\"))\n\t}\n\tif r.relativeTime != nil {\n\t\tlocalVarQueryParams.Add(\"relativeTime\", parameterToString(*r.relativeTime, \"\"))\n\t}\n\tif r.tag != nil {\n\t\tt := *r.tag\n\t\tif reflect.TypeOf(t).Kind() == reflect.Slice {\n\t\t\ts := reflect.ValueOf(t)\n\t\t\tfor i := 0; i < s.Len(); i++ {\n\t\t\t\tlocalVarQueryParams.Add(\"tag\", parameterToString(s.Index(i), \"multi\"))\n\t\t\t}\n\t\t} else {\n\t\t\tlocalVarQueryParams.Add(\"tag\", parameterToString(t, \"multi\"))\n\t\t}\n\t}\n\tif r.entity != nil {\n\t\tt := *r.entity\n\t\tif reflect.TypeOf(t).Kind() == reflect.Slice {\n\t\t\ts := reflect.ValueOf(t)\n\t\t\tfor i := 0; i < s.Len(); i++ {\n\t\t\t\tlocalVarQueryParams.Add(\"entity\", parameterToString(s.Index(i), \"multi\"))\n\t\t\t}\n\t\t} else {\n\t\t\tlocalVarQueryParams.Add(\"entity\", parameterToString(t, \"multi\"))\n\t\t}\n\t}\n\tif r.host != nil {\n\t\tt := *r.host\n\t\tif reflect.TypeOf(t).Kind() == reflect.Slice {\n\t\t\ts := reflect.ValueOf(t)\n\t\t\tfor i := 0; i < s.Len(); i++ {\n\t\t\t\tlocalVarQueryParams.Add(\"host\", parameterToString(s.Index(i), \"multi\"))\n\t\t\t}\n\t\t} else {\n\t\t\tlocalVarQueryParams.Add(\"host\", parameterToString(t, \"multi\"))\n\t\t}\n\t}\n\tif r.managementZone != nil {\n\t\tlocalVarQueryParams.Add(\"managementZone\", parameterToString(*r.managementZone, \"\"))\n\t}\n\tif r.includeDetails != nil {\n\t\tlocalVarQueryParams.Add(\"includeDetails\", parameterToString(*r.includeDetails, \"\"))\n\t}\n\tif r.pageSize != nil {\n\t\tlocalVarQueryParams.Add(\"pageSize\", parameterToString(*r.pageSize, \"\"))\n\t}\n\tif r.nextPageKey != nil {\n\t\tlocalVarQueryParams.Add(\"nextPageKey\", parameterToString(*r.nextPageKey, \"\"))\n\t}\n\t// to determine the Content-Type header\n\tlocalVarHTTPContentTypes := []string{}\n\n\t// set Content-Type header\n\tlocalVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes)\n\tif localVarHTTPContentType != \"\" {\n\t\tlocalVarHeaderParams[\"Content-Type\"] = localVarHTTPContentType\n\t}\n\n\t// to determine the Accept header\n\tlocalVarHTTPHeaderAccepts := []string{\"application/json; charset=utf-8\"}\n\n\t// set Accept header\n\tlocalVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts)\n\tif localVarHTTPHeaderAccept != \"\" {\n\t\tlocalVarHeaderParams[\"Accept\"] = localVarHTTPHeaderAccept\n\t}\n\tif r.ctx != nil {\n\t\t// API Key Authentication\n\t\tif auth, ok := r.ctx.Value(ContextAPIKeys).(map[string]APIKey); ok {\n\t\t\tif apiKey, ok := auth[\"Api-Token\"]; ok {\n\t\t\t\tvar key string\n\t\t\t\tif apiKey.Prefix != \"\" {\n\t\t\t\t\tkey = apiKey.Prefix + \" \" + apiKey.Key\n\t\t\t\t} else {\n\t\t\t\t\tkey = apiKey.Key\n\t\t\t\t}\n\t\t\t\tlocalVarHeaderParams[\"Authorization\"] = key\n\t\t\t}\n\t\t}\n\t}\n\treq, err := a.client.prepareRequest(r.ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes)\n\tif err != nil {\n\t\treturn localVarReturnValue, nil, err\n\t}\n\n\tlocalVarHTTPResponse, err := a.client.callAPI(req)\n\tif err != nil || localVarHTTPResponse == nil {\n\t\treturn localVarReturnValue, localVarHTTPResponse, err\n\t}\n\n\tlocalVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body)\n\tlocalVarHTTPResponse.Body.Close()\n\tlocalVarHTTPResponse.Body = _ioutil.NopCloser(bytes.NewBuffer(localVarBody))\n\tif err != nil {\n\t\treturn localVarReturnValue, localVarHTTPResponse, err\n\t}\n\n\tif localVarHTTPResponse.StatusCode >= 300 {\n\t\tnewErr := GenericOpenAPIError{\n\t\t\tbody: localVarBody,\n\t\t\terror: localVarHTTPResponse.Status,\n\t\t}\n\t\tif localVarHTTPResponse.StatusCode == 400 {\n\t\t\tvar v ErrorEnvelope\n\t\t\terr = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get(\"Content-Type\"))\n\t\t\tif err != nil {\n\t\t\t\tnewErr.error = err.Error()\n\t\t\t\treturn localVarReturnValue, localVarHTTPResponse, newErr\n\t\t\t}\n\t\t\tnewErr.model = v\n\t\t}\n\t\treturn localVarReturnValue, localVarHTTPResponse, newErr\n\t}\n\n\terr = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get(\"Content-Type\"))\n\tif err != nil {\n\t\tnewErr := GenericOpenAPIError{\n\t\t\tbody: localVarBody,\n\t\t\terror: err.Error(),\n\t\t}\n\t\treturn localVarReturnValue, localVarHTTPResponse, newErr\n\t}\n\n\treturn localVarReturnValue, localVarHTTPResponse, nil\n}", "func initWorker(count int, c chan *Job, results chan Result, wg *sync.WaitGroup) {\n\t// start workers based on flag\n\tfor i := 0; i < count; i++ {\n\t\twg.Add(1)\n\t\tgo worker(c, results, wg)\n\t}\n}", "func LaunchWorkers(wg *sync.WaitGroup, stop <-chan bool) {\n\t// we need to recreate the dlChan and the segChan in case we want to restart workers.\n\tDlChan = make(chan *WJob)\n\tsegChan = make(chan *WJob)\n\taudioChan = make(chan *WJob)\n\t// the master worker downloads one full m3u8 at a time but\n\t// segments are downloaded concurrently\n\tmasterW := &Worker{id: 0, wg: wg, master: true}\n\tgo masterW.Work()\n\n\tfor i := 1; i < TotalWorkers+1; i++ {\n\t\tw := &Worker{id: i, wg: wg, client: &http.Client{}}\n\t\tgo w.Work()\n\t}\n}", "func distributor(p golParams, d distributorChans, alive chan []cell) {\n\n\t// Create the 2D slice to store the world.\n\tworld := make([][]byte, p.imageHeight)\n\tfor i := range world {\n\t\tworld[i] = make([]byte, p.imageWidth)\n\t}\n\n newWorld := make([][]byte, p.imageHeight)\n for i := range world {\n \tnewWorld[i] = make([]byte, p.imageWidth)\n }\n\t// Request the io goroutine to read in the image with the given filename.\n\td.io.command <- ioInput\n\td.io.filename <- strings.Join([]string{strconv.Itoa(p.imageWidth), strconv.Itoa(p.imageHeight)}, \"x\")\n\n workerChannels := make([]chan byte,p.threads)\n haloChannels := make([]chan byte,p.threads)\n workerCommands := make([]chan int,p.threads) //used in the distributor to tell the workers to do certain workerCommands\n //0-pause\n //1-request totalAlive\n\n for i := range workerChannels {\n workerChannels[i] = make(chan byte)\n workerCommands[i] = make(chan int,1)\n haloChannels[i] = make(chan byte,p.imageWidth)\n }\n defaultHeight := p.imageHeight/p.threads\n height := make([]int, p.threads)\n\n for i,c:=range workerChannels {\n if(i!=p.threads-1) {\n height[i] = defaultHeight\n } else {\n height[i]=p.imageHeight-(defaultHeight*(p.threads-1))\n }\n go worker(height[i]+2,p,c,haloChannels[(i-1+p.threads)%p.threads],haloChannels[i],workerCommands[i])\n }\n\n\n\t// The io goroutine sends the requested image byte by byte, in rows.\n\tfor y := 0; y < p.imageHeight; y++ {\n\t\tfor x := 0; x < p.imageWidth; x++ {\n\t\t\tval := <-d.io.inputVal\n\t\t\tif val != 0 {\n\t\t\t\tfmt.Println(\"Alive cell at\", x, y)\n\t\t\t\tworld[y][x] = val\n\t\t\t}\n\t\t}\n\t}\n for i,c:=range workerChannels {\n if(i != p.threads-1) {\n for y:=((i)*(defaultHeight));y<((i+1)*(defaultHeight));y++ {\n for x:=0;x<p.imageWidth;x++ {\n c<-world[(y+p.imageHeight)%p.imageHeight][x]\n }\n }\n } else {\n for y:=((i)*(defaultHeight));y<(p.imageHeight);y++ {\n for x:=0;x<p.imageWidth;x++ {\n c<-world[(y+p.imageHeight)%p.imageHeight][x]\n }\n }\n }\n }\n\tperiodicChan := make(chan bool)\n\tgo ticker(periodicChan)\n\n running := true\n paused := false\n aliveCount := 0\n finishedCount := 0\n\t// Calculate the new state of Game of Life after the given number of turns.\n\tfor (running) {\n for y := 0; y < p.imageHeight; y++ {\n for x := 0; x < p.imageWidth; x++ {\n world[y][x] = newWorld[y][x]\n if(world[y][x] != 0) {\n aliveCount+=1\n }\n }\n }\n select {\n case <-periodicChan:\n fmt.Println(\"TRYING TO SEND\")\n\n aliveCount = 0\n //for _,c:=range workerCommands {\n //c<-1\n // fmt.Println(\"SENT COMMAND\")\n\n //aliveCount+=<-c\n //}\n fmt.Println(aliveCount)\n default:\n }\n select{\n case currentKey := <-d.keyChan:\n switch(currentKey) {\n case 's':\n printBoard(p,d,world)\n case 'q':\n // printBoard(p,d,world)\n running=false\n\n case 'p':\n paused=true\n fmt.Println(\"PAUSED\")\n for (paused) {\n currentKey2:=<-d.keyChan\n switch(currentKey2){\n case 'p':paused = false\n }\n }\n fmt.Println(\"UNPAUSED\")\n }\n default:\n }\n for _,c:=range workerCommands {\n select{\n case command := <-c:\n switch (command) {\n case 9:\n finishedCount+=1\n\n }\n default:\n }\n\n }\n fmt.Println(finishedCount)\n if(finishedCount == p.threads){\n running =false\n }\n\t}\n\t fmt.Println(\"GOT HEREB\")\n\n for i,c:=range workerChannels {\n if(i != p.threads-1) {\n for y:=((i)*(defaultHeight));y<((i+1)*(defaultHeight));y++ {\n for x:=0;x<p.imageWidth;x++ {\n newWorld[y][x]=<-c\n }\n }\n } else {\n for y:=((i)*(defaultHeight));y<(p.imageHeight);y++ {\n for x:=0;x<p.imageWidth;x++ {\n newWorld[y][x]=<-c\n }\n }\n }\n }\n d.io.command <- ioOutput\n d.io.filename <- strings.Join([]string{strconv.Itoa(p.imageWidth), strconv.Itoa(p.imageHeight)}, \"x\")\n\n // Create an empty slice to store coordinates of cells that are still alive after p.turns are done.\n var finalAlive []cell\n // Go through the world and append the cells that are still alive.\n for y := 0; y < p.imageHeight; y++ {\n for x := 0; x < p.imageWidth; x++ {\n d.io.outputVal<-world[y][x]\n if world[y][x] != 0 {\n\n finalAlive = append(finalAlive, cell{x: x, y: y})\n }\n\n }\n }\n\n // Make sure that the Io has finished any output before exiting.\n d.io.command <- ioCheckIdle\n <-d.io.idle\n\n // Return the coordinates of cells that are still alive.\n alive <- finalAlive\n\n}", "func worker(wg *sync.WaitGroup) {\n\tfor job := range jobs {\n\t\toutput := Result{job, digits(job.randomno)}\n\t\tresults <- output\n\t}\n\twg.Done()\n}", "func spawnHosts(ctx context.Context, newHostsNeeded map[string]int) (map[string][]host.Host, error) {\n\tstartTime := time.Now()\n\n\t// loop over the distros, spawning up the appropriate number of hosts\n\t// for each distro\n\thostsSpawnedPerDistro := make(map[string][]host.Host)\n\tfor distroId, numHostsToSpawn := range newHostsNeeded {\n\t\tdistroStartTime := time.Now()\n\n\t\tif numHostsToSpawn == 0 {\n\t\t\tcontinue\n\t\t}\n\n\t\thostsSpawnedPerDistro[distroId] = make([]host.Host, 0, numHostsToSpawn)\n\t\tfor i := 0; i < numHostsToSpawn; i++ {\n\t\t\tif ctx.Err() != nil {\n\t\t\t\treturn nil, errors.New(\"scheduling run canceled.\")\n\t\t\t}\n\n\t\t\td, err := distro.FindOne(distro.ById(distroId))\n\t\t\tif err != nil {\n\t\t\t\tgrip.Error(message.WrapError(err, message.Fields{\n\t\t\t\t\t\"distro\": distroId,\n\t\t\t\t\t\"runner\": RunnerName,\n\t\t\t\t\t\"message\": \"failed to find distro\",\n\t\t\t\t}))\n\t\t\t\tcontinue\n\t\t\t}\n\n\t\t\tallDistroHosts, err := host.Find(host.ByDistroId(distroId))\n\t\t\tif err != nil {\n\t\t\t\tgrip.Error(message.WrapError(err, message.Fields{\n\t\t\t\t\t\"distro\": distroId,\n\t\t\t\t\t\"runner\": RunnerName,\n\t\t\t\t\t\"message\": \"problem getting hosts for distro\",\n\t\t\t\t}))\n\n\t\t\t\tcontinue\n\t\t\t}\n\n\t\t\tif len(allDistroHosts) >= d.PoolSize {\n\t\t\t\tgrip.Info(message.Fields{\n\t\t\t\t\t\"distro\": distroId,\n\t\t\t\t\t\"runner\": RunnerName,\n\t\t\t\t\t\"pool_size\": d.PoolSize,\n\t\t\t\t\t\"message\": \"max hosts running\",\n\t\t\t\t})\n\n\t\t\t\tcontinue\n\t\t\t}\n\n\t\t\thostOptions := cloud.HostOptions{\n\t\t\t\tUserName: evergreen.User,\n\t\t\t\tUserHost: false,\n\t\t\t}\n\n\t\t\tintentHost := cloud.NewIntent(d, d.GenerateName(), d.Provider, hostOptions)\n\t\t\tif err := intentHost.Insert(); err != nil {\n\t\t\t\terr = errors.Wrapf(err, \"Could not insert intent host '%s'\", intentHost.Id)\n\n\t\t\t\tgrip.Error(message.WrapError(err, message.Fields{\n\t\t\t\t\t\"distro\": distroId,\n\t\t\t\t\t\"runner\": RunnerName,\n\t\t\t\t\t\"host\": intentHost.Id,\n\t\t\t\t\t\"provider\": d.Provider,\n\t\t\t\t}))\n\n\t\t\t\treturn nil, err\n\t\t\t}\n\n\t\t\thostsSpawnedPerDistro[distroId] = append(hostsSpawnedPerDistro[distroId], *intentHost)\n\n\t\t}\n\t\t// if none were spawned successfully\n\t\tif len(hostsSpawnedPerDistro[distroId]) == 0 {\n\t\t\tdelete(hostsSpawnedPerDistro, distroId)\n\t\t}\n\n\t\tgrip.Info(message.Fields{\n\t\t\t\"runner\": RunnerName,\n\t\t\t\"distro\": distroId,\n\t\t\t\"number\": numHostsToSpawn,\n\t\t\t\"operation\": \"spawning instances\",\n\t\t\t\"span\": time.Since(distroStartTime).String(),\n\t\t\t\"duration\": time.Since(distroStartTime),\n\t\t})\n\t}\n\n\tgrip.Info(message.Fields{\n\t\t\"runner\": RunnerName,\n\t\t\"operation\": \"host query and processing\",\n\t\t\"span\": time.Since(startTime).String(),\n\t\t\"duration\": time.Since(startTime),\n\t})\n\n\treturn hostsSpawnedPerDistro, nil\n}", "func runExperiment(numberOfCalls int, wg *sync.WaitGroup, calc *utils.CalcValues, start int) {\n\tdefer wg.Done()\n\t// getting the clientproxy\n\tnamingServer := proxies.InitServer(\"localhost\")\n\tcalculator := namingServer.Lookup(\"Calculator\").(proxies.CalculatorProxy)\n\n\t// executing\n\tfor i := 0; i < numberOfCalls; i++ {\n\t\tinitialTime := time.Now() //calculating time\n\t\tresult := calculator.Mul(i + start)\n\t\tendTime := float64(time.Now().Sub(initialTime).Milliseconds()) // RTT\n\t\tfmt.Println(result) // making the request\n\t\tutils.AddValue(calc, endTime) // pushing to the stored values\n\t\ttime.Sleep(10 * time.Millisecond) // setting the sleep time\n\t}\n}", "func (d *disp) Start() *disp {\n\n\t//pipelines_implementation_backup(d)\n\n\tl := len(d.Workers)\n\tfor i := 1; i <= l; i++ {\n\n\t\twrk := worker2.New(i, \"default\", make(worker2.PipelineChannel), d.PipelineQueue, make(worker2.JobChannel), d.Queue, make(chan struct{}))\n\t\twrk.Start()\n\t\td.Workers = append(d.Workers, wrk)\n\t}\n\tgo d.process()\n\n\treturn d\n}", "func Run(fields []drivers.FieldDescriptor, f flags.Flags) error {\n\tnumJobs := f.Num\n\tworkers := f.Workers\n\tjobs := make(chan struct{}, numJobs)\n\twg := &sync.WaitGroup{}\n\twg.Add(workers)\n\tfor w := 0; w < workers; w++ {\n\t\tgo worker(jobs, fields, wg, f)\n\t}\n\n\tfor j := 0; j < numJobs; j++ {\n\t\tjobs <- struct{}{}\n\t}\n\tclose(jobs)\n\twg.Wait()\n\n\treturn nil\n}", "func runProgFuncs(ctx context.Context) (*sync.WaitGroup, chan pull.Stats) {\n\tstatsCh := make(chan pull.Stats)\n\twg := &sync.WaitGroup{}\n\n\twg.Add(1)\n\tgo func() {\n\t\tdefer wg.Done()\n\t\tpullerProgFunc(ctx, statsCh)\n\t}()\n\n\treturn wg, statsCh\n}", "func (z *zpoolctl) Split(ctx context.Context, name, options, altRoot, mntopts string, properties map[string]string, newName string, devs ...string) *execute {\n\targs := []string{\"split\"}\n\tif len(options) > 0 {\n\t\targs = append(args, options)\n\t}\n\tif len(altRoot) > 0 {\n\t\targs = append(args, altRoot)\n\t}\n\tif len(mntopts) > 0 {\n\t\targs = append(args, mntopts)\n\t}\n\tif properties != nil {\n\t\tkv := \"-o \"\n\t\tfor k, v := range properties {\n\t\t\tkv += fmt.Sprintf(\"%s=%s,\", k, v)\n\t\t}\n\t\tkv = strings.TrimSuffix(kv, \",\")\n\t\targs = append(args, kv)\n\t}\n\targs = append(args, name, newName)\n\tfor _, dev := range devs {\n\t\targs = append(args, dev)\n\t}\n\treturn &execute{ctx: ctx, name: z.cmd, args: args}\n}", "func startPipelineFunction(numbers chan<- int) {\n\tfor i := 1; i <= 10; i++ {\n\t\tnumbers <- i\n\t}\n\tclose(numbers)\n}", "func (c *myClient) batchCreateDatasetGroup(groupNameList ...string) (resultsList []map[string]interface{}, err error) {\n\tfor _, v := range groupNameList {\n\t\tif result, err := c.createDatasetGroup(v, false); err != nil {\n\t\t\treturn nil, err\n\t\t} else if result != nil && (result[\"job\"] != nil || result[\"action\"] != nil) {\n\t\t\tresultsList = append(resultsList, result)\n\t\t}\n\t}\n\tc.jobWaiter(resultsList...)\n\n\treturn resultsList, err\n}", "func visualizationWorker(str string, threads int, wg *sync.WaitGroup, parallel bool, shots []Shot, m map[string]int){\n\n\t// Create a new Plot Object p\n\tp, err := plot.New()\n\tif err != nil{\n\t\tlog.Fatal(err)\n\t}\n\n\t// Turn the Job String to JSON Object\n\tvar job VisualizeJob\n\t_ = json.Unmarshal([]byte(str), &job)\n\n\t// Variable that will be used to name outfile\n\tvar outfile string\n\n\t// Channel to synchronize threads\n\tplottingComplete := make(chan bool, threads)\n\n\t// If parallel Version\n\tif parallel{\n\n\t\t// All of Kobe's Shots\n\t\trecords := len(shots)\n\n\t\t// Partitions based on threads\n\t\tpartitions := records/threads\n\n\t\t// First Partition Range\n\t\tlo := 0\n\t\thi := partitions\n\n\t\t// Spawn a go routine for each thread\n\t\tfor i:=0; i<threads; i++{\n\n\t\t\t// Spawn Go Routine\n\t\t\tgo visualization(lo, hi, p, shots, job.Specs, m, plottingComplete, parallel)\n\n\n\t\t\t// Update the next partition's range\n\t\t\tlo += partitions\n\n\t\t\t// Last thread takes all remaining tasks\n\t\t\tif i == threads-2{\n\t\t\t\thi = len(shots)\n\n\t\t\t}else{\n\t\t\t\thi += partitions\n\t\t\t}\n\n\t\t}\n\n\n\t// Sequential Version\n\t} else{\n\n\t\t// Call visualization function for all the shots\n\t\tvisualization(0, len(shots),p, shots, job.Specs, m, plottingComplete, parallel)\n\n\t}\n\n\t// Loop through the Specs to get\n\t// an appropriate outfile name\n\tfor j:=0; j<len(job.Specs); j++{\n\t\tif j != len(job.Specs)-1{\n\t\t\toutfile = outfile+job.Specs[j]+\" \"\n\n\t\t} else{\n\t\t\toutfile = outfile+job.Specs[j]\n\t\t}\n\n\t}\n\n\t// In the case we want all shots to be displayed\n\tif len(outfile) == 0{\n\t\toutfile = \"All_Shots\"\n\t}\n\n\t// Add a Legend\n\tp.Legend.Add(\"X = Miss\")\n\tp.Legend.Add(\"O = Make\")\n\tp.Legend.Color = color.RGBA{R:255, G:255, B:255, A:255}\n\tp.Legend.Top = true\n\tp.Legend.Font.Size = 16\n\n\t// Background Color\n\tp.BackgroundColor = color.RGBA{R:0, G:0, B:0, A:255}\n\n\t// Title\n\tp.Title.Text = outfile\n\tp.Title.Color = color.RGBA{R:255, G:255, B:255, A:255}\n\tp.Title.Font.Size = 20\n\n\n\t// Code Inspired By justforfunc: Programming in Go (Campoy)\n\t// Youtube Video: https://www.youtube.com/watch?v=ihP7lQivA6M\n\t// Github Page: https://github.com/campoy/justforfunc/tree/master/34-gonum-plot\n\n\t// Create a file in our visualization Results Directory\n\toutfile = outfile+\".png\"\n\tdir := \"visualizationResults\"\n\tf, _ := os.Create(filepath.Join(dir, filepath.Base(outfile)))\n\n\t// If parallel, wait for all threads to finish their jobs\n\tif parallel{\n\t\tfor t:=1; t<=threads; t++{\n\t\t\t<- plottingComplete\n\t\t}\n\n\t}\n\n\t// Code Below By justforfunc: Programming in Go (Campoy)\n\t// Youtube Video: https://www.youtube.com/watch?v=ihP7lQivA6M\n\t// Github Page: https://github.com/campoy/justforfunc/tree/master/34-gonum-plot\n\n\t// Write our plot to our file and save\n\twt, _ := p.WriterTo(700, 500, \"png\")\n\t_, _ = wt.WriteTo(f)\n\n\t// If Parallel, signal that we are done\n\tif parallel{\n\t\twg.Done()\n\n\t}\n\n}", "func queryWorker(\n workerIndex int,\n in <-chan string,\n out chan<- result,\n group *sync.WaitGroup,\n client *api.BingClient) {\n\n defer group.Done()\n\n for queryString := range in {\n if queryString == \"\" { continue }\n log.Printf(\"[worker:%d] sending search string: %s\", workerIndex, queryString)\n\n currOffset := 0\n running := true\n var err error\n for running {\n params := api.CreateQuery(queryString, currOffset)\n paramsString := params.AsQueryParameters()\n log.Printf(\"[worker:%d] running query with params: %s\", workerIndex, paramsString)\n images := client.RequestImages(params)\n if images.Values == nil {\n err = fmt.Errorf(\"[worker:%d] failed to pull query: %s/%s\",\n workerIndex, client.Endpoint, paramsString)\n running = false\n } else {\n running = images.NextOffset != currOffset\n currOffset = images.NextOffset\n }\n out <- result{images, err}\n }\n }\n\n log.Printf(\"[worker:%d] terminated\", workerIndex)\n}", "func main(){\n\tjobs := make(chan int, 100) //buffered chanel of ints\n\tresult := make(chan int, 100)\n\tvar wg sync.WaitGroup //the mutex\n\twg.Add(1)\n\n\tfibo := 50 //how many numbers we want to calculate\n\n\tgo worker(jobs, result) //parallel workers\n\tgo worker(jobs, result) //parallel workers\n\tgo worker(jobs, result) //parallel workers\n\tgo worker(jobs, result) //parallel workers\n\n\tfor i:=1; i<=fibo; i++ {\n\t\tjobs <- i\n\t}\n\tclose(jobs)\n\n\tgo func() {\n\t\tfor i:=1; i<=fibo; i++ {\n\t\t\tfmt.Printf(\"Number is %v and the result: %+v\\n\", i, <-result)\n\t\t}\n\t\twg.Done()\n\t}()\n\n\twg.Wait()\n\treturn\n}", "func (b *B) RunParallel(body func(*PB))", "func makeProcMesh(rows int, cols int,\n input chan int, result chan report,\n algo func(meshinfo),\n done *sync.WaitGroup) {\n var inN []chan int\n var outN []chan int\n var inS []chan int = make([]chan int,cols)\n var outS []chan int = make([]chan int,cols)\n for proci := 0; proci < rows; proci++ {\n\n inN = outS\n outN = inS\n inS = make([]chan int,cols)\n outS = make([]chan int,cols)\n if proci != rows-1 {\n for j := 0; j < cols; j++ {\n inS[j] = make(chan int,1)\n outS[j] = make(chan int,1)\n }\n }\n\n \tvar inW chan int\n var outW chan int\n \tvar inE chan int = nil\n \tvar outE chan int = nil\n\n \tfor procj := 0; procj < cols; procj++ {\n \t\tinW = outE\n \t\toutW = inE\n if procj == cols-1 { inE = nil } else { inE = make(chan int, 1)}\n if procj == cols-1 { outE = nil } else { outE = make(chan int, 1)}\n info := meshinfo{row:proci, rows:rows,\n column:procj, columns:cols,\n inNorth:inN[procj], outNorth:outN[procj],\n inEast:inE, outEast:outE,\n inSouth:inS[procj], outSouth:outS[procj],\n inWest:inW, outWest:outW,\n input:input, result:result,\n signal:done}\n \t\tgo algo(info)\n \t}\n }\n}", "func DoBatch(ctx context.Context, op Operation, r ReadRing, keys []uint32, callback func(InstanceDesc, []int) error, cleanup func()) error {\n\tif r.InstancesCount() <= 0 {\n\t\tcleanup()\n\t\treturn fmt.Errorf(\"DoBatch: InstancesCount <= 0\")\n\t}\n\n\texpectedTrackers := len(keys) * (r.ReplicationFactor() + 1) / r.InstancesCount()\n\titemTrackers := make([]itemTracker, len(keys))\n\tinstances := make(map[string]instance, r.InstancesCount())\n\n\tvar (\n\t\tbufDescs [GetBufferSize]InstanceDesc\n\t\tbufHosts [GetBufferSize]string\n\t\tbufZones = make(map[string]int, GetZoneSize)\n\t)\n\tfor i, key := range keys {\n\t\treplicationSet, err := r.Get(key, op, bufDescs[:0], bufHosts[:0], bufZones)\n\t\tif err != nil {\n\t\t\tcleanup()\n\t\t\treturn err\n\t\t}\n\t\titemTrackers[i].minSuccess = len(replicationSet.Instances) - replicationSet.MaxErrors\n\t\titemTrackers[i].maxFailures = replicationSet.MaxErrors\n\t\titemTrackers[i].remaining.Store(int32(len(replicationSet.Instances)))\n\n\t\tfor _, desc := range replicationSet.Instances {\n\t\t\tcurr, found := instances[desc.Addr]\n\t\t\tif !found {\n\t\t\t\tcurr.itemTrackers = make([]*itemTracker, 0, expectedTrackers)\n\t\t\t\tcurr.indexes = make([]int, 0, expectedTrackers)\n\t\t\t}\n\t\t\tinstances[desc.Addr] = instance{\n\t\t\t\tdesc: desc,\n\t\t\t\titemTrackers: append(curr.itemTrackers, &itemTrackers[i]),\n\t\t\t\tindexes: append(curr.indexes, i),\n\t\t\t}\n\t\t}\n\t}\n\n\ttracker := batchTracker{\n\t\tdone: make(chan struct{}, 1),\n\t\terr: make(chan error, 1),\n\t}\n\ttracker.rpcsPending.Store(int32(len(itemTrackers)))\n\n\tvar wg sync.WaitGroup\n\n\twg.Add(len(instances))\n\tfor _, i := range instances {\n\t\tgo func(i instance) {\n\t\t\terr := callback(i.desc, i.indexes)\n\t\t\ttracker.record(i.itemTrackers, err)\n\t\t\twg.Done()\n\t\t}(i)\n\t}\n\n\t// Perform cleanup at the end.\n\tgo func() {\n\t\twg.Wait()\n\n\t\tcleanup()\n\t}()\n\n\tselect {\n\tcase err := <-tracker.err:\n\t\treturn err\n\tcase <-tracker.done:\n\t\treturn nil\n\tcase <-ctx.Done():\n\t\treturn ctx.Err()\n\t}\n}", "func (_RandomBeacon *RandomBeaconCaller) GroupCreationParameters(opts *bind.CallOpts) (struct {\n\tGroupCreationFrequency *big.Int\n\tGroupLifetime *big.Int\n\tDkgResultChallengePeriodLength *big.Int\n\tDkgResultChallengeExtraGas *big.Int\n\tDkgResultSubmissionTimeout *big.Int\n\tDkgSubmitterPrecedencePeriodLength *big.Int\n}, error) {\n\tvar out []interface{}\n\terr := _RandomBeacon.contract.Call(opts, &out, \"groupCreationParameters\")\n\n\toutstruct := new(struct {\n\t\tGroupCreationFrequency *big.Int\n\t\tGroupLifetime *big.Int\n\t\tDkgResultChallengePeriodLength *big.Int\n\t\tDkgResultChallengeExtraGas *big.Int\n\t\tDkgResultSubmissionTimeout *big.Int\n\t\tDkgSubmitterPrecedencePeriodLength *big.Int\n\t})\n\tif err != nil {\n\t\treturn *outstruct, err\n\t}\n\n\toutstruct.GroupCreationFrequency = *abi.ConvertType(out[0], new(*big.Int)).(**big.Int)\n\toutstruct.GroupLifetime = *abi.ConvertType(out[1], new(*big.Int)).(**big.Int)\n\toutstruct.DkgResultChallengePeriodLength = *abi.ConvertType(out[2], new(*big.Int)).(**big.Int)\n\toutstruct.DkgResultChallengeExtraGas = *abi.ConvertType(out[3], new(*big.Int)).(**big.Int)\n\toutstruct.DkgResultSubmissionTimeout = *abi.ConvertType(out[4], new(*big.Int)).(**big.Int)\n\toutstruct.DkgSubmitterPrecedencePeriodLength = *abi.ConvertType(out[5], new(*big.Int)).(**big.Int)\n\n\treturn *outstruct, err\n\n}", "func parallel(count int, procs int, fn func(int, int)) {\n\tvar blockSize int\n\tif count > 0 && procs > 0 {\n\t\tblockSize = count / procs\n\t} else {\n\t\tblockSize = 1\n\t}\n\tif blockSize <= 0 {\n\t\tblockSize = 1\n\t}\n\n\tidx := count\n\tvar wg sync.WaitGroup\n\tfor idx > 0 {\n\t\tstart := idx - blockSize\n\t\tend := idx\n\t\tif start < 0 {\n\t\t\tstart = 0\n\t\t}\n\t\tidx -= blockSize\n\n\t\twg.Add(1)\n\t\tgo func() {\n\t\t\tfn(start, end)\n\t\t\twg.Done()\n\t\t}()\n\t}\n\twg.Wait()\n}", "func doWithBatch(ctx context.Context, totalSize int, batchSize int, ga gate.Gate, f func(startIndex, endIndex int) error) error {\n\tif totalSize == 0 {\n\t\treturn nil\n\t}\n\tif batchSize <= 0 {\n\t\treturn f(0, totalSize)\n\t}\n\tg, ctx := errgroup.WithContext(ctx)\n\tfor i := 0; i < totalSize; i += batchSize {\n\t\tj := i + batchSize\n\t\tif j > totalSize {\n\t\t\tj = totalSize\n\t\t}\n\t\tif ga != nil {\n\t\t\tif err := ga.Start(ctx); err != nil {\n\t\t\t\treturn nil\n\t\t\t}\n\t\t}\n\t\tstartIndex, endIndex := i, j\n\t\tg.Go(func() error {\n\t\t\tif ga != nil {\n\t\t\t\tdefer ga.Done()\n\t\t\t}\n\t\t\treturn f(startIndex, endIndex)\n\t\t})\n\t}\n\treturn g.Wait()\n}", "func processRun(nRequests int, concurrency int, ch chan time.Duration, fun func()) []float64 {\n\tresults := make([]float64, 0, nRequests)\n\n\tn := nRequests\n\tfor n > 0 {\n\t\tfor i := 0; i < concurrency; i++ {\n\t\t\tif n > 0 {\n\t\t\t\tgo fun()\n\t\t\t\tn--\n\t\t\t}\n\t\t}\n\n\t\tfor i := 0; i < concurrency; i++ {\n\t\t\tif len(results) < nRequests {\n\t\t\t\tresults = append(results, float64(<-ch)/float64(time.Millisecond))\n\t\t\t}\n\t\t}\n\t}\n\n\treturn results\n}", "func (b *B) RunParallel(body func(*PB)) {}", "func main() {\n\n\t// Threads\n\tvar threads int\n\n\t// If running parallel or sequential\n\tvar parallel bool\n\n\t// Create a queue to hold the jobs\n\tqueue := NewQueue()\n\n\t// Make a directory to hold results of visualization jobs\n\tos.Mkdir(\"visualizationResults\", 0775)\n\n\t// Open the JSON File and save contents to variable shots\n\t// this will hold all the shots kove bryant has ever took\n\tdata, _ := ioutil.ReadFile(\"data/data.json\")\n\tshots := make([]Shot,0)\n\t_ = json.Unmarshal(data, &shots)\n\n\t// Create a mapping of the Shot Struct\n\t// This helps us in accessing the data in future steps\n\t// https://blog.golang.org/maps\n\tvar temp Shot\n\te := reflect.ValueOf(&temp).Elem()\n\tm := make(map[string]int)\n\n\t// Assign a number to each field for the struct\n\tfor i := 0; i < e.NumField(); i++ {\n\t\tvarName := e.Type().Field(i).Name\n\t\tm[varName] = i\n\t}\n\n\t// If the User provides parallel flag\n\tinput := os.Args\n\tif len(input) == 2{\n\n\t\t// Get the amount of threads\n\t\ttemp1 := os.Args[1]\n\t\ttemp2 := strings.Split(temp1, \"=\")\n\t\ti, err := strconv.Atoi(temp2[1])\n\t\tthreads = i\n\t\tif err != nil {\n\t\t\tfmt.Println(err)\n\t\t}\n\n\t\t// Set GOMAXPROCS\n\t\truntime.GOMAXPROCS(threads)\n\t\tparallel = true\n\t}\n\n\t// Print Usage for bad input\n\tif len(input) != 1 && len(input) != 2{\n\t\tprintUsage()\n\t\tos.Exit(3)\n\n\t}\n\n\n\t// Specify the amount of readers\n\treaders := int(math.Ceil(float64(threads)*(1.0/5.0)))\n\n\t// Create a wait group\n\twg := sync.WaitGroup{}\n\n\t// If running in parallel\n\tif parallel{\n\n\t\t// Spawn appropriate amount of readers\n\t\tfor i:=0;i<readers;i++{\n\t\t\tgo reader(threads, parallel, queue, &wg, shots, m)\n\n\t\t}\n\t\t// Wait for a couple seconds so the other threads\n\t\t// have a chance to begin working\n\t\ttime.Sleep(time.Second*2)\n\n\t// If running Sequentially\n\t}else{\n\t\treader(threads, parallel, queue, &wg, shots, m)\n\t}\n\n\t// Wait to end function until all jobs are done\n\twg.Wait()\n}", "func (p *dynamicWorkerPool) Run(ctx context.Context, params StageParams) {\nstop:\n\tfor {\n\t\tselect {\n\t\tcase <-ctx.Done():\n\t\t\tbreak stop\n\t\tcase payloadIn, ok := <-params.Input():\n\t\t\tif !ok {\n\t\t\t\tbreak stop\n\t\t\t}\n\t\t\tvar token struct{}\n\t\t\tselect {\n\t\t\tcase token = <-p.tokenPool:\n\t\t\tcase <-ctx.Done():\n\t\t\t}\n\t\t\tgo func(payloadIn Payload, token struct{}) {\n\t\t\t\tdefer func() { p.tokenPool <- token }()\n\t\t\t\tpayloadOut, err := p.proc.Process(ctx, payloadIn)\n\t\t\t\tif err != nil {\n\t\t\t\t\twrappedErr := xerrors.Errorf(\"pipeline stage: %d : %w \", params.StageIndex(), err)\n\t\t\t\t\tmaybeEmitError(wrappedErr, params.Error())\n\t\t\t\t\treturn\n\t\t\t\t}\n\t\t\t\tif payloadOut == nil {\n\t\t\t\t\tpayloadIn.MarkAsProcessed()\n\t\t\t\t\treturn\n\t\t\t\t}\n\t\t\t\tselect {\n\t\t\t\tcase params.Output() <- payloadOut:\n\t\t\t\tcase <-ctx.Done():\n\t\t\t\t}\n\t\t\t}(payloadIn, token)\n\t\t}\n\t}\n\tfor i := 0; i < cap(p.tokenPool); i++ {\n\t\t<-p.tokenPool\n\t}\n}", "func worker(id int, jobs <-chan int, results chan<- int) {\n\tfor j := range jobs {\n\t\tfmt.Println(\"worker\", id, \"processing job\", j)\n\t\t//simulate an expensive work\n\t\ttime.Sleep(time.Second)\n\t\tresults <- j * 10\n\t}\n}", "func mlParallel(lo int, hi int, requests []MLRequest, threadComplete chan MLRequest){\n\n\t// Local Max for a thread\n\tvar max float64\n\tvar bestModel MLRequest\n\n\t// Loop through the requests in the range given\n\tfor i:=lo; i<hi; i++{\n\n\t\t// Call the python function\n\t\t// Learned how to do this from:\n\t\t// https://stackoverflow.com/questions/27021517/go-run-external-python-script\n\t\tcmd,_ := exec.Command(\"python\", \"src/ml.py\", requests[i].Model, fmt.Sprint(requests[i].Parameters), requests[i].ParameterValues).Output()\n\n\t\t// Get and process the result\n\t\tresult := strings.TrimSuffix(string(cmd), \"\\n\")\n\t\ttemp,_ := strconv.ParseFloat(result, 64)\n\n\t\t// Update the max accordingly\n\t\tif temp > max{\n\t\t\tmax = temp\n\t\t\tbestModel = requests[i]\n\t\t}\n\n\t}\n\n\t// Let the main thread know this thread is done\n\t// Also send the best model found\n\tbestModel.Accuracy = max\n\tthreadComplete <- bestModel\n\n}", "func (g *Group) Kickstart(tpGen TestPlanGen, total, offset, SecRamp int) {\n\n\tg.initialize()\n\tg.Total = total\n\n\t// Generate a Test Plan for Global Setup\n\ttestPlan := tpGen(0, nil)\n\terr := testPlan.GlobalSetup()\n\n\tif err != nil {\n\t\tpanic(err)\n\t}\n\n\tsleepIncrement := time.Duration(SecRamp) * time.Second / time.Duration(total)\n\tgo g.spinUpThreads(tpGen, total, offset, sleepIncrement)\n\n\tfor activity := range g.ActivityPipe {\n\t\tswitch activity.Status {\n\t\tcase StatusActive:\n\t\t\tg.registerThreadActive(activity)\n\t\tcase StatusInactive:\n\t\t\tg.registerThreadInactive(activity)\n\t\tcase StatusLaunching:\n\t\t\tg.registerThreadLaunching(activity)\n\t\tcase StatusLaunchFailed:\n\t\t\tg.registerLaunchFail(activity)\n\t\tcase StatusError:\n\t\t\tg.registerThreadError(activity)\n\t\tcase StatusAction:\n\t\t\tg.registerThreadAction(activity)\n\t\tcase StatusIncoming:\n\t\t\tg.registerThreadIncoming(activity)\n\t\tdefault:\n\t\t\tpanic(\"Unhandled Activity type in group\")\n\t\t}\n\t}\n}", "func (m *Manager) Exec(name string, opt ExecOptions, gOpt operator.Options) error {\n\tif err := clusterutil.ValidateClusterNameOrError(name); err != nil {\n\t\treturn err\n\t}\n\n\tmetadata, err := m.meta(name)\n\tif err != nil {\n\t\treturn err\n\t}\n\n\ttopo := metadata.GetTopology()\n\tbase := metadata.GetBaseMeta()\n\n\tfilterRoles := set.NewStringSet(gOpt.Roles...)\n\tfilterNodes := set.NewStringSet(gOpt.Nodes...)\n\n\tvar shellTasks []task.Task\n\tuniqueHosts := map[string]set.StringSet{} // host-sshPort -> {command}\n\ttopo.IterInstance(func(inst spec.Instance) {\n\t\tkey := utils.JoinHostPort(inst.GetManageHost(), inst.GetSSHPort())\n\t\tif _, found := uniqueHosts[key]; !found {\n\t\t\tif len(gOpt.Roles) > 0 && !filterRoles.Exist(inst.Role()) {\n\t\t\t\treturn\n\t\t\t}\n\n\t\t\tif len(gOpt.Nodes) > 0 && (!filterNodes.Exist(inst.GetHost()) && !filterNodes.Exist(inst.GetManageHost())) {\n\t\t\t\treturn\n\t\t\t}\n\n\t\t\tcmds, err := renderInstanceSpec(opt.Command, inst)\n\t\t\tif err != nil {\n\t\t\t\tm.logger.Debugf(\"error rendering command with spec: %s\", err)\n\t\t\t\treturn // skip\n\t\t\t}\n\t\t\tcmdSet := set.NewStringSet(cmds...)\n\t\t\tif _, ok := uniqueHosts[key]; ok {\n\t\t\t\tuniqueHosts[key].Join(cmdSet)\n\t\t\t\treturn\n\t\t\t}\n\t\t\tuniqueHosts[key] = cmdSet\n\t\t}\n\t})\n\n\tfor hostKey, i := range uniqueHosts {\n\t\thost, _ := utils.ParseHostPort(hostKey)\n\t\tfor _, cmd := range i.Slice() {\n\t\t\tshellTasks = append(shellTasks,\n\t\t\t\ttask.NewBuilder(m.logger).\n\t\t\t\t\tShell(host, cmd, hostKey+cmd, opt.Sudo).\n\t\t\t\t\tBuild())\n\t\t}\n\t}\n\n\tb, err := m.sshTaskBuilder(name, topo, base.User, gOpt)\n\tif err != nil {\n\t\treturn err\n\t}\n\n\tt := b.\n\t\tParallel(false, shellTasks...).\n\t\tBuild()\n\n\texecCtx := ctxt.New(\n\t\tcontext.Background(),\n\t\tgOpt.Concurrency,\n\t\tm.logger,\n\t)\n\tif err := t.Execute(execCtx); err != nil {\n\t\tif errorx.Cast(err) != nil {\n\t\t\t// FIXME: Map possible task errors and give suggestions.\n\t\t\treturn err\n\t\t}\n\t\treturn perrs.Trace(err)\n\t}\n\n\t// print outputs\n\tfor hostKey, i := range uniqueHosts {\n\t\thost, _ := utils.ParseHostPort(hostKey)\n\t\tfor _, cmd := range i.Slice() {\n\t\t\tstdout, stderr, ok := ctxt.GetInner(execCtx).GetOutputs(hostKey + cmd)\n\t\t\tif !ok {\n\t\t\t\tcontinue\n\t\t\t}\n\t\t\tm.logger.Infof(\"Outputs of %s on %s:\",\n\t\t\t\tcolor.CyanString(cmd),\n\t\t\t\tcolor.CyanString(host))\n\t\t\tif len(stdout) > 0 {\n\t\t\t\tm.logger.Infof(\"%s:\\n%s\", color.GreenString(\"stdout\"), stdout)\n\t\t\t}\n\t\t\tif len(stderr) > 0 {\n\t\t\t\tm.logger.Infof(\"%s:\\n%s\", color.RedString(\"stderr\"), stderr)\n\t\t\t}\n\t\t}\n\t}\n\n\treturn nil\n}", "func worker(w *sync.WaitGroup, goroutineID int) {\n\tfor j := range jobs {\n\t\tdata <- Data{goroutineID, j, double(j.Value)}\n\t}\n\n\t// When no more jobs are on the jobs channel\n\t// resolve waitgroup.\n\tw.Done()\n}", "func runBatch(fn ...runBatchFunc) error {\n\teg := errgroup.Group{}\n\tfor _, f := range fn {\n\t\teg.Go(f)\n\t}\n\treturn eg.Wait()\n}", "func testParallelismWithBeverages(bm *BeverageMachine, beverageNames []string) {\n\n\tfmt.Printf(\"\\nstarting test: testParallelismWithBeverages\\n\\n\")\n\n\twg := sync.WaitGroup{}\n\tfor i, beverageName := range beverageNames {\n\t\twg.Add(1)\n\t\tgo func(i int, beverageName string) {\n\t\t\tdefer wg.Done()\n\n\t\t\tfmt.Printf(\"thread %d-> start\\n\", i+1)\n\n\t\t\t//1. get an idle dispenser\n\t\t\tdispenser, err := bm.GetIdleDispenser()\n\t\t\tfor err != nil {\n\t\t\t\tfmt.Printf(\"thread %d-> %s, retrying in 2 seconds...\\n\", i+1, err.Error())\n\t\t\t\ttime.Sleep(2 * time.Second)\n\t\t\t\tdispenser, err = bm.GetIdleDispenser()\n\t\t\t}\n\t\t\tfmt.Printf(\"thread %d-> acquired dispenser %d\\n\", i+1, dispenser.GetId())\n\n\t\t\tfmt.Printf(\"thread %d-> starting to prepare %s on dispenser %d...\\n\", i+1, beverageName, dispenser.GetId())\n\n\t\t\t//2. request the beverage from the dispenser\n\t\t\tbeverage, err := bm.RequestBeverage(dispenser, beverageName)\n\t\t\tif err != nil {\n\t\t\t\tfmt.Printf(\"thread %d-> dispenser %d says: %s\\n\", i+1, dispenser.GetId(), err.Error())\n\t\t\t\tfmt.Printf(\"thread %d-> end\\n\", i+1)\n\t\t\t\treturn\n\t\t\t}\n\n\t\t\tfmt.Printf(\"thread %d-> successfully served %s on dispenser %d\\n\", i+1, beverage.GetName(), dispenser.GetId())\n\t\t\tfmt.Printf(\"thread %d-> end\\n\", i+1)\n\t\t}(i, beverageName)\n\t}\n\twg.Wait()\n\n\tfmt.Println(\"\\ncompleted test: testParallelismWithBeverages\\n\")\n}", "func createWorkerPool(count int, queue chan common.ServiceRegistration, done chan<- bool) {\n\tvar waitGroup sync.WaitGroup\n\twaitGroup.Add(count)\n\tfor i := 0; i < count; i++ {\n\t\tgo func(c *opslevel.Client, q chan common.ServiceRegistration, wg *sync.WaitGroup) {\n\t\t\tfor data := range q {\n\t\t\t\treconcileService(c, data)\n\t\t\t}\n\t\t\twg.Done()\n\t\t}(common.NewClient(), queue, &waitGroup)\n\t}\n\twaitGroup.Wait()\n\tdone <- true\n}", "func allocate(jobArr []string) {\n\tfor i := 0; i < len(jobArr); i++ {\n\t\tjob := jobArr[i]\n\t\tjobs <- job\n\t}\n\tclose(jobs)\n}", "func (b *Builder) Run() []error {\n\t//Check for prvious mesh\n\tif b.localInstances.Len() > 0 {\n\t\treturn []error{\n\t\t\tfmt.Errorf(\"mesh was already run\"),\n\t\t}\n\t}\n\n\t//Create the processors mesh and cleanup on error\n\tif err := b.createProcessorsMesh(); err != nil {\n\t\tb.clearMesh()\n\t\treturn []error{\n\t\t\terr,\n\t\t}\n\t}\n\n\t//Run the processors\n\terrors := []error{}\n\tfor entry := b.localInstances.Front(); entry != nil; entry = entry.Next() {\n\t\tif info, ok := (entry.Value).(*ProcessorInfo); !ok {\n\t\t\terrors = append(errors, fmt.Errorf(\"unexpected processor info entry in instances map\"))\n\t\t} else if err := info.instance.Run(); err != nil {\n\t\t\terrors = append(errors, err)\n\t\t}\n\t}\n\treturn errors\n}", "func (self *BinaryPushRequestProcessor) pushWorkerGroup(psp *push.PushServiceProvider, reqChan <-chan *common.PushRequest) {\n\tresultChan := make(chan *common.APNSResult, 100)\n\t// Create a connection manager to open connections.\n\t// This will create a goroutine listening on each connection it creates, to be sent to us on resultChan.\n\tmanager := newLoggingConnManager(self.connManagerMaker(psp, (chan<- *common.APNSResult)(resultChan)), self.errChan)\n\t// There's a pool for each push endpoint.\n\tworkerpool := NewPool(manager, self.poolSize, maxWaitTime)\n\tdefer workerpool.Close()\n\n\tworkerid := fmt.Sprintf(\"workder-%v-%v\", time.Now().Unix(), rand.Int63())\n\n\tdpCache := cache.New(256, -1, 0*time.Second, nil)\n\n\t// In a background thread, connect to corresponding feedback server and listen for unsubscribe updates to send to that user.\n\tgo self.feedbackChecker(psp, dpCache, self.errChan)\n\n\t// XXX use a tree structure would be faster and more stable.\n\treqMap := make(map[uint32]*common.PushRequest, 1024)\n\n\t// Callback for handling responses - used both in processing and when shutting down.\n\thandleResponse := func(res *common.APNSResult) {\n\t\t// Process the first result that is received for each MsgId, forwarding it to the requester.\n\t\tif req, ok := reqMap[res.MsgId]; ok {\n\t\t\tdelete(reqMap, res.MsgId)\n\t\t\treq.ResChan <- res\n\t\t} else if res.Err != nil {\n\t\t\tself.errChan <- res.Err\n\t\t}\n\t}\n\tfor {\n\t\tselect {\n\t\tcase req := <-reqChan:\n\t\t\t// Accept requests from pushMux goroutine, sending pushes to APNS for each devtoken.\n\t\t\t// If a response is received from APNS for a devtoken, forward it on the channel for the corresponding request.\n\t\t\t// Otherwise, close it\n\t\t\tif req == nil {\n\t\t\t\tfmt.Printf(\"[%v][%v] I was told to stop (req == nil) - stopping\\n\", time.Now(), workerid)\n\t\t\t\t// Finish up any remaining requests to uniqush, forwarding the responses from APNS.\n\t\t\t\t// clearRequest should ensure that reqMap is eventually empty - this has also been tested under heavy load.\n\t\t\t\tfor {\n\t\t\t\t\tif len(reqMap) == 0 {\n\t\t\t\t\t\tfmt.Printf(\"[%v][%v] I was told to stop - stopped\\n\", time.Now(), workerid)\n\t\t\t\t\t\treturn\n\t\t\t\t\t}\n\t\t\t\t\tres, ok := <-resultChan\n\t\t\t\t\tif !ok || res == nil {\n\t\t\t\t\t\tfmt.Printf(\"[%v][%v] Some pending requests don't have any responses - shouldn't happen\\n\", time.Now(), workerid)\n\t\t\t\t\t\treturn\n\t\t\t\t\t}\n\t\t\t\t\thandleResponse(res)\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tfor i, _ := range req.Devtokens {\n\t\t\t\tmid := req.GetId(i)\n\t\t\t\treqMap[mid] = req\n\t\t\t}\n\n\t\t\tfor _, dp := range req.DPList {\n\t\t\t\tif key, ok := dp.FixedData[\"devtoken\"]; ok {\n\t\t\t\t\tdpCache.Set(key, dp)\n\t\t\t\t}\n\t\t\t}\n\t\t\tgo self.multiPush(req, workerpool)\n\t\t\tgo clearRequest(req, resultChan)\n\t\tcase res := <-resultChan:\n\t\t\tif res == nil {\n\t\t\t\tfmt.Printf(\"[%v][%v] I was told to stop (res == nil)\\n\", time.Now(), workerid)\n\t\t\t\treturn\n\t\t\t}\n\t\t\thandleResponse(res)\n\t\t}\n\t}\n}", "func (s *Scheduler) schedule() {\n\t// Do we have space left in our buffer?\n\tif s.CountScheduledRuns() >= schedulerBufferLimit {\n\t\t// No space left. Exit.\n\t\treturn\n\t}\n\n\t// Get scheduled pipelines but limit the returning number of elements.\n\tscheduled, err := s.storeService.PipelineGetScheduled(schedulerBufferLimit)\n\tif err != nil {\n\t\tgaia.Cfg.Logger.Debug(\"cannot get scheduled pipelines\", \"error\", err.Error())\n\t\treturn\n\t}\n\n\t// Iterate scheduled runs\n\tfor id := range scheduled {\n\t\t// If we are a server instance, we will by default give the worker the advantage.\n\t\t// Only in case all workers are busy we will schedule work on the server.\n\t\tworkers := s.memDBService.GetAllWorker()\n\t\tif gaia.Cfg.Mode == gaia.ModeServer && len(workers) > 0 {\n\t\t\t// Check if all workers are busy / inactive\n\t\t\tinvalidWorkers := 0\n\t\t\tfor _, w := range workers {\n\t\t\t\tif w.Slots == 0 || w.Status != gaia.WorkerActive {\n\t\t\t\t\tinvalidWorkers++\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t// Insert pipeline run into memdb where all workers get their work from\n\t\t\tif len(workers) > invalidWorkers {\n\t\t\t\t// Mark them as scheduled\n\t\t\t\tscheduled[id].Status = gaia.RunScheduled\n\n\t\t\t\t// Update entry in store\n\t\t\t\terr = s.storeService.PipelinePutRun(scheduled[id])\n\t\t\t\tif err != nil {\n\t\t\t\t\tgaia.Cfg.Logger.Debug(\"could not put pipeline run into store\", \"error\", err.Error())\n\t\t\t\t\tcontinue\n\t\t\t\t}\n\n\t\t\t\tif err := s.memDBService.InsertPipelineRun(scheduled[id]); err != nil {\n\t\t\t\t\tgaia.Cfg.Logger.Error(\"failed to insert pipeline run into memdb via schedule\", \"error\", err.Error())\n\t\t\t\t}\n\t\t\t\tcontinue\n\t\t\t}\n\t\t}\n\n\t\t// Check if this primary is not allowed to run work\n\t\tif gaia.Cfg.PreventPrimaryWork {\n\t\t\tcontinue\n\t\t}\n\n\t\t// Mark them as scheduled\n\t\tscheduled[id].Status = gaia.RunScheduled\n\n\t\t// Update entry in store\n\t\terr = s.storeService.PipelinePutRun(scheduled[id])\n\t\tif err != nil {\n\t\t\tgaia.Cfg.Logger.Debug(\"could not put pipeline run into store\", \"error\", err.Error())\n\t\t\tcontinue\n\t\t}\n\n\t\t// push scheduled run into our channel\n\t\ts.scheduledRuns <- *scheduled[id]\n\t}\n}", "func createWorkerPool(noOfWorkers int) {\n\tvar wg sync.WaitGroup\n\tfor i := 0; i < noOfWorkers; i++ {\n\t\twg.Add(1)\n\t\tgo worker(&wg)\n\t}\n\twg.Wait()\n\tclose(results)\n}", "func evalulatePairs(mappings map[int]map[int][]mapping, data *util.QueryDocumentSet) {\n\tconst MaxJobs int = 10\n\n\twg := &sync.WaitGroup{}\n\n\tjobs := make(chan work, MaxJobs)\n\n\tfor i := 0; i < MaxJobs; i++ {\n\t\twg.Add(1)\n\t\tgo runJob(jobs, wg)\n\t}\n\tfor k1, v1 := range mappings {\n\t\tfor k2, v2 := range v1 {\n\t\t\tjobs <- work{k1, k2, v2, data}\n\t\t}\n\t}\n\n\tclose(jobs)\n\n\twg.Wait()\n}", "func worker_pool() {\n\n}", "func Worker(mapf func(string, string) []KeyValue,\n\treducef func(string, []string) string) {\n\n\t// Your worker implementation here.\n\n\t// uncomment to send the Example RPC to the master.\n\t// CallExample()\n\tfor{\n\t\tgetNext := GetTask(mapf, reducef)\n\t\tif(!getNext){\n\t\t\tbreak\n\t\t}\n\t}\n\t\n}", "func (b *Benchmark) Run() {\n\tfor _, gpu := range b.gpus {\n\t\tb.driver.SelectGPU(b.context, gpu)\n\t\tb.queues = append(b.queues, b.driver.CreateCommandQueue(b.context))\n\t}\n\n\tif b.NumIterations == 0 || b.NumIterations > b.NumNodes {\n\t\tb.NumIterations = b.NumNodes\n\t}\n\n\tb.initMem()\n\tb.exec()\n}", "func TestGroup(t *testing.T) {\n\tn := 5\n\ttmpPath := path.Join(os.TempDir(), \"drand\")\n\tos.Mkdir(tmpPath, 0740)\n\tdefer os.RemoveAll(tmpPath)\n\n\tnames := make([]string, n, n)\n\tprivs := make([]*key.Pair, n, n)\n\tfor i := 0; i < n; i++ {\n\t\tnames[i] = path.Join(tmpPath, fmt.Sprintf(\"drand-%d.public\", i))\n\t\tprivs[i] = key.NewKeyPair(\"127.0.0.1\")\n\t\trequire.NoError(t, key.Save(names[i], privs[i].Public, false))\n\t\tif yes, err := fs.Exists(names[i]); !yes || err != nil {\n\t\t\tt.Fatal(err.Error())\n\t\t}\n\t}\n\n\t//test not enough keys\n\tcmd := exec.Command(\"drand\", \"--folder\", tmpPath, \"group\", names[0])\n\tout, err := cmd.CombinedOutput()\n\texpectedOut := \"group command take at least 3 keys as arguments\"\n\tfmt.Println(string(out))\n\trequire.Error(t, err)\n\n\t//test valid creation\n\tgroupPath := path.Join(tmpPath, key.GroupFolderName)\n\targs := []string{\"drand\", \"--folder\", tmpPath, \"group\"}\n\targs = append(args, names...)\n\tcmd = exec.Command(args[0], args[1:]...)\n\tout, err = cmd.CombinedOutput()\n\texpectedOut = \"Copy the following snippet into a new group.toml file \" +\n\t\t\"and distribute it to all the participants:\"\n\tfmt.Println(string(out))\n\trequire.True(t, strings.Contains(string(out), expectedOut))\n\trequire.Nil(t, err)\n\n\t//recreates exactly like in main and saves the group\n\tvar threshold = key.DefaultThreshold(n)\n\tpublics := make([]*key.Identity, n)\n\tfor i, str := range names {\n\t\tpub := &key.Identity{}\n\t\tif err := key.Load(str, pub); err != nil {\n\t\t\tslog.Fatal(err)\n\t\t}\n\t\tpublics[i] = pub\n\t}\n\tgroup := key.NewGroup(publics, threshold)\n\tgroup.PublicKey = &key.DistPublic{\n\t\tCoefficients: []kyber.Point{publics[0].Key},\n\t}\n\trequire.Nil(t, key.Save(groupPath, group, false))\n\n\textraName := path.Join(tmpPath, fmt.Sprintf(\"drand-%d.public\", n))\n\textraPriv := key.NewKeyPair(\"127.0.0.1\")\n\trequire.NoError(t, key.Save(extraName, extraPriv.Public, false))\n\tif yes, err := fs.Exists(extraName); !yes || err != nil {\n\t\tt.Fatal(err.Error())\n\t}\n\n\t//test valid merge\n\tcmd = exec.Command(\"drand\", \"--folder\", tmpPath, \"group\", \"--group\", groupPath, extraName)\n\tout, err = cmd.CombinedOutput()\n\tfmt.Println(string(out))\n\n\t//expectedOut = \"Copy the following snippet into a new_group.toml file and give it to the upgrade command to do the resharing.\"\n\trequire.True(t, strings.Contains(string(out), expectedOut))\n\n\t//test could not load group file\n\twrongGroupPath := \"not_here\"\n\tcmd = exec.Command(\"drand\", \"--folder\", tmpPath, \"group\", \"--group\", wrongGroupPath, names[0])\n\tout, err = cmd.CombinedOutput()\n\tfmt.Println(string(out))\n\trequire.Error(t, err)\n\n\t//test reject empty group file\n\temptyGroupPath := path.Join(tmpPath, \"empty.toml\")\n\temptyFile, err := os.Create(emptyGroupPath)\n\tif err != nil {\n\t\tslog.Fatal(err)\n\t}\n\tdefer emptyFile.Close()\n\tcmd = exec.Command(\"drand\", \"--folder\", tmpPath, \"group\", \"--group\", emptyGroupPath, names[0])\n\tout, err = cmd.CombinedOutput()\n\tfmt.Println(string(out))\n\trequire.Error(t, err)\n}", "func (e *Executor) jobs(on []Locator) jobSet {\n\tif len(on) == 0 {\n\t\treturn jobSet{}\n\t}\n\tif e.Group != nil {\n\t\treturn jobSet{e.Group(on...)}\n\t}\n\tif e.Serial != nil {\n\t\tjobs := make(jobSet, 0, len(on))\n\t\tfor i := range on {\n\t\t\tjobs = append(jobs, e.Serial(on[i]))\n\t\t}\n\t\treturn jobs\n\t}\n\treturn jobSet{}\n}", "func calcChunkWorkers(chunks <-chan chunkInput, results chan<- chunkOutput) {\n\n\tfor c := range chunks {\n\n\t\tblake := blake2.New(&blake2.Config{Size: KeySize, Tree: &blake2.Tree{Fanout: 0, MaxDepth: 2, LeafSize: config.Config.LeafSize, NodeOffset: uint64(c.part), NodeDepth: 0, InnerHashSize: KeySize, IsLastNode: c.lastChunk}})\n\n\t\t_, err := io.Copy(blake, bytes.NewBuffer(c.partBuffer))\n\t\tif err != nil {\n\t\t\t// TODO: fmt.Println(\"Failing to compute hash: \", err)\n\t\t\tresults <- chunkOutput{digest: []byte(\"\"), part: c.part}\n\t\t} else {\n\t\t\tdigest := blake.Sum(nil)\n\t\t\tresults <- chunkOutput{digest: digest, part: c.part}\n\t\t}\n\t}\n}", "func spawnHosts(ctx context.Context, d distro.Distro, newHostsNeeded int, pool *evergreen.ContainerPool) ([]host.Host, error) {\n\n\tstartTime := time.Now()\n\n\tif newHostsNeeded == 0 {\n\t\treturn []host.Host{}, nil\n\t}\n\n\t// loop over the distros, spawning up the appropriate number of hosts\n\t// for each distro\n\n\thostsSpawned := []host.Host{}\n\n\tdistroStartTime := time.Now()\n\n\tif ctx.Err() != nil {\n\t\treturn nil, errors.New(\"scheduling run canceled\")\n\t}\n\n\t// if distro is container distro, check if there are enough parent hosts to\n\t// support new containers\n\tif pool != nil {\n\t\t// find all running parents with the specified container pool\n\t\tcurrentParents, err := host.FindAllRunningParentsByContainerPool(pool.Id)\n\t\tif err != nil {\n\t\t\treturn nil, errors.Wrap(err, \"could not find running parents\")\n\t\t}\n\n\t\t// find all child containers running on those parents\n\t\texistingContainers, err := host.HostGroup(currentParents).FindRunningContainersOnParents()\n\t\tif err != nil {\n\t\t\treturn nil, errors.Wrap(err, \"could not find running containers\")\n\t\t}\n\n\t\t// find all uphost parent intent documents\n\t\tnumUphostParents, err := host.CountUphostParentsByContainerPool(pool.Id)\n\t\tif err != nil {\n\t\t\treturn nil, errors.Wrap(err, \"could not count uphost parents\")\n\t\t}\n\n\t\t// create numParentsNeededParams struct\n\t\tparentsParams := newParentsNeededParams{\n\t\t\tnumUphostParents: numUphostParents,\n\t\t\tnumContainersNeeded: newHostsNeeded,\n\t\t\tnumExistingContainers: len(existingContainers),\n\t\t\tmaxContainers: pool.MaxContainers,\n\t\t}\n\t\t// compute number of parents needed\n\t\tnumNewParents := numNewParentsNeeded(parentsParams)\n\n\t\t// get parent distro from pool\n\t\tparentDistro, err := distro.FindOne(distro.ById(pool.Distro))\n\t\tif err != nil {\n\t\t\treturn nil, errors.Wrap(err, \"error find parent distro\")\n\t\t}\n\n\t\t// only want to spawn amount of parents allowed based on pool size\n\t\tnumNewParentsToSpawn, err := parentCapacity(parentDistro, numNewParents, len(currentParents), pool)\n\t\tif err != nil {\n\t\t\treturn nil, errors.Wrap(err, \"could not calculate number of parents needed to spawn\")\n\t\t}\n\t\t// create parent host intent documents\n\t\tif numNewParentsToSpawn > 0 {\n\t\t\thostsSpawned = append(hostsSpawned, createParents(parentDistro, numNewParentsToSpawn, pool)...)\n\n\t\t\tgrip.Info(message.Fields{\n\t\t\t\t\"runner\": RunnerName,\n\t\t\t\t\"distro\": d.Id,\n\t\t\t\t\"pool\": pool.Id,\n\t\t\t\t\"pool_distro\": pool.Distro,\n\t\t\t\t\"num_new_parents\": numNewParentsToSpawn,\n\t\t\t\t\"operation\": \"spawning new parents\",\n\t\t\t\t\"duration_secs\": time.Since(distroStartTime).Seconds(),\n\t\t\t})\n\t\t}\n\n\t\t// only want to spawn amount of containers we can fit on currently running parents\n\t\tnewHostsNeeded = containerCapacity(len(currentParents), len(existingContainers), newHostsNeeded, pool.MaxContainers)\n\t}\n\n\t// create intent documents for container hosts\n\tif d.ContainerPool != \"\" {\n\t\tcontainerIntents, err := generateContainerHostIntents(d, newHostsNeeded)\n\t\tif err != nil {\n\t\t\treturn nil, errors.Wrap(err, \"error generating container intent hosts\")\n\t\t}\n\t\thostsSpawned = append(hostsSpawned, containerIntents...)\n\t} else { // create intent documents for regular hosts\n\t\tfor i := 0; i < newHostsNeeded; i++ {\n\t\t\tintent, err := generateIntentHost(d)\n\t\t\tif err != nil {\n\t\t\t\treturn nil, errors.Wrap(err, \"error generating intent host\")\n\t\t\t}\n\t\t\thostsSpawned = append(hostsSpawned, *intent)\n\t\t}\n\t}\n\n\tif err := host.InsertMany(hostsSpawned); err != nil {\n\t\treturn nil, errors.Wrap(err, \"problem inserting host documents\")\n\t}\n\n\tgrip.Info(message.Fields{\n\t\t\"runner\": RunnerName,\n\t\t\"distro\": d.Id,\n\t\t\"operation\": \"spawning instances\",\n\t\t\"duration_secs\": time.Since(startTime).Seconds(),\n\t\t\"num_hosts\": len(hostsSpawned),\n\t})\n\n\treturn hostsSpawned, nil\n}", "func init() {\n\n SendProcessMetricsCmd.Flags().StringVarP(&nodeName, \"nodename\", \"n\", \"\", \"Node Name\")\n SendProcessMetricsCmd.Flags().StringVarP(&processName, \"processname\", \"p\", \"\", \"Process Name\")\n\n SendProcessMetricsCmd.Flags().Float64VarP(&cpu, \"cpu\", \"c\", 0, \"cpu percentage\")\n SendProcessMetricsCmd.Flags().Float64VarP(&mem, \"mem\", \"m\", 0, \"memory percentage\")\n\n}", "func GenerateCreateWorkGroupInput(cr *svcapitypes.WorkGroup) *svcsdk.CreateWorkGroupInput {\n\tres := &svcsdk.CreateWorkGroupInput{}\n\n\tif cr.Spec.ForProvider.Configuration != nil {\n\t\tf0 := &svcsdk.WorkGroupConfiguration{}\n\t\tif cr.Spec.ForProvider.Configuration.BytesScannedCutoffPerQuery != nil {\n\t\t\tf0.SetBytesScannedCutoffPerQuery(*cr.Spec.ForProvider.Configuration.BytesScannedCutoffPerQuery)\n\t\t}\n\t\tif cr.Spec.ForProvider.Configuration.EnforceWorkGroupConfiguration != nil {\n\t\t\tf0.SetEnforceWorkGroupConfiguration(*cr.Spec.ForProvider.Configuration.EnforceWorkGroupConfiguration)\n\t\t}\n\t\tif cr.Spec.ForProvider.Configuration.EngineVersion != nil {\n\t\t\tf0f2 := &svcsdk.EngineVersion{}\n\t\t\tif cr.Spec.ForProvider.Configuration.EngineVersion.EffectiveEngineVersion != nil {\n\t\t\t\tf0f2.SetEffectiveEngineVersion(*cr.Spec.ForProvider.Configuration.EngineVersion.EffectiveEngineVersion)\n\t\t\t}\n\t\t\tif cr.Spec.ForProvider.Configuration.EngineVersion.SelectedEngineVersion != nil {\n\t\t\t\tf0f2.SetSelectedEngineVersion(*cr.Spec.ForProvider.Configuration.EngineVersion.SelectedEngineVersion)\n\t\t\t}\n\t\t\tf0.SetEngineVersion(f0f2)\n\t\t}\n\t\tif cr.Spec.ForProvider.Configuration.PublishCloudWatchMetricsEnabled != nil {\n\t\t\tf0.SetPublishCloudWatchMetricsEnabled(*cr.Spec.ForProvider.Configuration.PublishCloudWatchMetricsEnabled)\n\t\t}\n\t\tif cr.Spec.ForProvider.Configuration.RequesterPaysEnabled != nil {\n\t\t\tf0.SetRequesterPaysEnabled(*cr.Spec.ForProvider.Configuration.RequesterPaysEnabled)\n\t\t}\n\t\tif cr.Spec.ForProvider.Configuration.ResultConfiguration != nil {\n\t\t\tf0f5 := &svcsdk.ResultConfiguration{}\n\t\t\tif cr.Spec.ForProvider.Configuration.ResultConfiguration.EncryptionConfiguration != nil {\n\t\t\t\tf0f5f0 := &svcsdk.EncryptionConfiguration{}\n\t\t\t\tif cr.Spec.ForProvider.Configuration.ResultConfiguration.EncryptionConfiguration.EncryptionOption != nil {\n\t\t\t\t\tf0f5f0.SetEncryptionOption(*cr.Spec.ForProvider.Configuration.ResultConfiguration.EncryptionConfiguration.EncryptionOption)\n\t\t\t\t}\n\t\t\t\tif cr.Spec.ForProvider.Configuration.ResultConfiguration.EncryptionConfiguration.KMSKey != nil {\n\t\t\t\t\tf0f5f0.SetKmsKey(*cr.Spec.ForProvider.Configuration.ResultConfiguration.EncryptionConfiguration.KMSKey)\n\t\t\t\t}\n\t\t\t\tf0f5.SetEncryptionConfiguration(f0f5f0)\n\t\t\t}\n\t\t\tif cr.Spec.ForProvider.Configuration.ResultConfiguration.OutputLocation != nil {\n\t\t\t\tf0f5.SetOutputLocation(*cr.Spec.ForProvider.Configuration.ResultConfiguration.OutputLocation)\n\t\t\t}\n\t\t\tf0.SetResultConfiguration(f0f5)\n\t\t}\n\t\tres.SetConfiguration(f0)\n\t}\n\tif cr.Spec.ForProvider.Description != nil {\n\t\tres.SetDescription(*cr.Spec.ForProvider.Description)\n\t}\n\tif cr.Spec.ForProvider.Tags != nil {\n\t\tf2 := []*svcsdk.Tag{}\n\t\tfor _, f2iter := range cr.Spec.ForProvider.Tags {\n\t\t\tf2elem := &svcsdk.Tag{}\n\t\t\tif f2iter.Key != nil {\n\t\t\t\tf2elem.SetKey(*f2iter.Key)\n\t\t\t}\n\t\t\tif f2iter.Value != nil {\n\t\t\t\tf2elem.SetValue(*f2iter.Value)\n\t\t\t}\n\t\t\tf2 = append(f2, f2elem)\n\t\t}\n\t\tres.SetTags(f2)\n\t}\n\n\treturn res\n}", "func Worker(mapf func(string, string) []KeyValue,\n\treducef func(string, []string) string) {\n\n\t// init\n\ttaskId = 9999\n\n\t//\n\tfor {\n\t\ttime.Sleep(time.Second)\n\n\t\treply := CallAssign()\n\n\t\t// fmt.Println(reply)\n\n\t\tif reply.TaskId < 0 {\n\t\t\t// fmt.Println(\"Waiting for assigning a work...\")\n\t\t\tcontinue\n\t\t}\n\n\t\t// modify taskId and later will tell master who i am\n\t\ttaskId = reply.TaskId\n\n\t\tif reply.TaskType == \"map\" {\n\t\t\tfile, err := os.Open(reply.FileName)\n\t\t\tif err != nil {\n\t\t\t\tlog.Fatalf(\"cannot open %v\", reply.FileName)\n\t\t\t}\n\t\t\tcontent, err := ioutil.ReadAll(file)\n\t\t\tif err != nil {\n\t\t\t\tlog.Fatalf(\"cannot read %v\", reply.FileName)\n\t\t\t}\n\t\t\tfile.Close()\n\t\t\tkva := mapf(reply.FileName, string(content))\n\n\t\t\t// sort\n\t\t\t// sort.Sort(ByKey(kva))\n\n\t\t\t// store intermediate kvs in tempFile\n\t\t\ttempFileName := \"tmp-\" + reply.TaskType + \"-\" + strconv.Itoa(reply.TaskId)\n\n\t\t\tfile, err = os.Create(tempFileName)\n\t\t\tif err != nil {\n\t\t\t\tlog.Fatal(\"cannot create %v\", tempFileName)\n\t\t\t}\n\n\t\t\t// transform k,v into json\n\t\t\tenc := json.NewEncoder(file)\n\t\t\tfor _, kv := range kva {\n\t\t\t\terr := enc.Encode(&kv)\n\t\t\t\tif err != nil {\n\t\t\t\t\tlog.Fatal(err)\n\t\t\t\t}\n\t\t\t}\n\t\t\t//\n\t\t\tfile.Close()\n\n\t\t\t// try to delay sometime\n\t\t\t// ran := rand.Intn(4)\n\t\t\t// fmt.Printf(\"Sleep %v s\\n\", ran)\n\t\t\t// d := time.Second * time.Duration(ran)\n\t\t\t// time.Sleep(d)\n\n\t\t\t// tell the master the mapwork has done\n\t\t\tCallDoneTask(reply, tempFileName)\n\n\t\t} else if reply.TaskType == \"reduce\" {\n\t\t\t// fmt.Println(reply.TaskType)\n\n\t\t\tkva := []KeyValue{}\n\n\t\t\tfile, err := os.Open(reply.FileName)\n\t\t\tif err != nil {\n\t\t\t\tlog.Fatal(err)\n\t\t\t}\n\n\t\t\tdec := json.NewDecoder(file)\n\t\t\tfor {\n\t\t\t\tvar kv KeyValue\n\t\t\t\tif err := dec.Decode(&kv); err != nil {\n\t\t\t\t\tbreak\n\t\t\t\t}\n\t\t\t\tkva = append(kva, kv)\n\t\t\t}\n\n\t\t\toutputFileName := \"mr-out-\" + strconv.Itoa(reply.TaskIndex)\n\t\t\tofile, _ := os.Create(outputFileName)\n\n\t\t\t// sort\n\t\t\t// sort.Sort(ByKey(kva))\n\n\t\t\ti := 0\n\t\t\tfor i < len(kva) {\n\t\t\t\tj := i + 1\n\t\t\t\tfor j < len(kva) && kva[j].Key == kva[i].Key {\n\t\t\t\t\tj++\n\t\t\t\t}\n\t\t\t\tvalues := []string{}\n\t\t\t\tfor k := i; k < j; k++ {\n\t\t\t\t\tvalues = append(values, kva[k].Value)\n\t\t\t\t}\n\t\t\t\toutput := reducef(kva[i].Key, values)\n\n\t\t\t\t// fmt.Println(output)\n\n\t\t\t\tfmt.Fprintf(ofile, \"%v %v\\n\", kva[i].Key, output)\n\n\t\t\t\ti = j\n\t\t\t}\n\n\t\t\tofile.Close()\n\n\t\t\t// fmt.Printf(\"Reduce task %v has finished.\\n\", reply.TaskIndex)\n\n\t\t\t// ran := rand.Intn(4)\n\t\t\t// fmt.Printf(\"Sleep %v s\\n\", ran)\n\t\t\t// d := time.Second * time.Duration(ran)\n\t\t\t// time.Sleep(d)\n\n\t\t\tCallDoneTask(reply, outputFileName)\n\t\t} else if reply.TaskType == \"close\" {\n\t\t\t// fmt.Println(\"MapReduce has done. Exiting...\")\n\t\t\tbreak\n\t\t} else {\n\t\t\tfmt.Println(\"UnExcepted TaskType\")\n\t\t}\n\n\t}\n\n}", "func runGenerals(m int, generals []bool, commOrder bool) []bool {\n\tvar wg sync.WaitGroup\n\tn := len(generals)\n\twg.Add(n)\n\n\t// Create channels used to communicate between lieutenants.\n\tchannels := []chan bool{}\n\tfor range generals {\n\t\tchannels = append(channels, make(chan bool, n))\n\t}\n\n\t//Create channels used to communicate between commander and lieutenants.\n\tcommChannels := []chan bool{}\n\tfor range generals {\n\t\tcommChannels = append(commChannels, make(chan bool, n))\n\t}\n\n\t// This stores the final command at each node by the end of the algorithm.\n\tcommands := make([]bool, n)\n\n\tfor i, loyal := range generals {\n\t\tif i == 0 {\n\t\t\t// Get the commander to send out initial commands.\n\t\t\tgo commander(n, m, i, loyal, commOrder, commChannels, &wg)\n\t\t} else {\n\t\t\t// Create a goroutine for each lieutenant.\n\t\t\tgo lieutenant(n, m, i, loyal, commChannels, channels, commands, &wg)\n\t\t}\n\t}\n\twg.Wait()\n\treturn commands\n}", "func (g *GardenerAPI) RunAll(ctx context.Context, rSrc RunnableSource, jt *tracker.JobWithTarget) (*errgroup.Group, error) {\n\teg := &errgroup.Group{}\n\tcount := 0\n\tjob := jt.Job\n\tfor {\n\t\trun, err := rSrc.Next(ctx)\n\t\tif err != nil {\n\t\t\tif err == iterator.Done {\n\t\t\t\tdebug.Printf(\"Dispatched total of %d archives for %s\\n\", count, job.String())\n\t\t\t\treturn eg, nil\n\t\t\t} else {\n\t\t\t\tmetrics.BackendFailureCount.WithLabelValues(\n\t\t\t\t\tjob.Datatype, \"rSrc.Next\").Inc()\n\t\t\t\tlog.Println(err, \"processing\", job.String())\n\t\t\t\treturn eg, err\n\t\t\t}\n\t\t}\n\n\t\tif err := g.jobs.Heartbeat(ctx, jt.ID); err != nil {\n\t\t\tlog.Println(err, \"on heartbeat for\", job.Path())\n\t\t}\n\n\t\tdebug.Println(\"Starting func\")\n\n\t\tf := func() (err error) {\n\t\t\tmetrics.ActiveTasks.WithLabelValues(rSrc.Label()).Inc()\n\t\t\tdefer metrics.ActiveTasks.WithLabelValues(rSrc.Label()).Dec()\n\n\t\t\t// Capture any panic and convert it to an error.\n\t\t\tdefer func(tag string) {\n\t\t\t\tif err2 := metrics.PanicToErr(err, recover(), \"Runall.f: \"+tag); err2 != nil {\n\t\t\t\t\terr = err2\n\t\t\t\t}\n\t\t\t}(run.Info())\n\n\t\t\terr = run.Run(ctx)\n\t\t\tif err == nil {\n\t\t\t\tif err := g.jobs.Update(ctx, jt.ID, tracker.Parsing, run.Info()); err != nil {\n\t\t\t\t\tlog.Println(err, \"on update for\", job.Path())\n\t\t\t\t}\n\t\t\t}\n\t\t\treturn\n\t\t}\n\n\t\tcount++\n\t\teg.Go(f)\n\t}\n}", "func (p *G2Jac) MultiExpNew(curve *Curve, points []G2Affine, scalars []fr.Element) chan G2Jac {\n\tdebug.Assert(len(scalars) == len(points))\n\tchRes := make(chan G2Jac, 1)\n\t// call windowed multi exp if input not large enough\n\t// we may want to force the API user to call the proper method in the first place\n\tconst minPoints = 50 // under 50 points, the windowed multi exp performs better\n\tif len(scalars) <= minPoints {\n\t\t_points := make([]G2Jac, len(points))\n\t\tfor i := 0; i < len(points); i++ {\n\t\t\tpoints[i].ToJacobian(&_points[i])\n\t\t}\n\t\tgo func() {\n\t\t\tp.WindowedMultiExp(curve, _points, scalars)\n\t\t\tchRes <- *p\n\t\t}()\n\t\treturn chRes\n\t}\n\t// if we have m points and n cpus, m/n points per cpu\n\tnbCpus := runtime.NumCPU()\n\t// nb points processed by one cpu\n\tpointsPerCPU := len(scalars) / nbCpus\n\t// each cpu has its own bucket\n\tsharedBuckets := make([][32][255]G2Jac, nbCpus)\n\t// bucket to gather cpus work\n\tvar commonBucket [32][255]G2Jac\n\tvar emptyBucket [255]G2Jac\n\tvar almostThere [32]G2Jac\n\tfor i := 0; i < 255; i++ {\n\t\temptyBucket[i].Set(&curve.g2Infinity)\n\t}\n\n\tconst mask = 255\n\t// id: cpu id, start, end: point nb start to point nb end, chunk: i-th digit (in corresponding basis)\n\tworker := func(id, start, end int) {\n\t\t// ...[chunk*8..(chunk+1)*8-1]... -th bits\n\t\tfor chunk := 0; chunk < 32; chunk++ {\n\t\t\tlimb := chunk / 8\n\t\t\toffset := (chunk % 8) * 8\n\t\t\tsharedBuckets[id][chunk] = emptyBucket\n\t\t\tvar index uint64\n\t\t\tfor i := start; i < end; i++ {\n\t\t\t\tindex = (scalars[i][limb] >> offset)\n\t\t\t\tindex &= mask\n\t\t\t\tif index != 0 {\n\t\t\t\t\tsharedBuckets[id][chunk][index-1].AddMixed(&points[i])\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\tvar wg sync.WaitGroup\n\n\t// each cpu works on a small part of the bucket\n\tfor j := 0; j < nbCpus; j++ {\n\t\tvar nextStart, nextEnd int\n\t\tnextStart = j * pointsPerCPU\n\t\tif j < nbCpus-1 {\n\t\t\tnextEnd = nextStart + pointsPerCPU\n\t\t} else {\n\t\t\tnextEnd = len(scalars)\n\t\t}\n\t\t_j := j\n\t\twg.Add(1)\n\t\tpool.Push(func() {\n\t\t\tworker(_j, nextStart, nextEnd)\n\t\t\twg.Done()\n\t\t}, false)\n\t}\n\tgo func() {\n\t\tfor i := 0; i < 32; i++ {\n\t\t\t// initialize the common bucket for the current chunk\n\t\t\tcommonBucket[i] = emptyBucket\n\t\t}\n\t\tcopy(almostThere[:], emptyBucket[:])\n\t\twg.Wait()\n\t\t// ...[chunk*8..(chunk+1)*8-1]... -th bits\n\t\tfor i := 0; i < 32; i++ {\n\t\t\t// fill the i-th chunk of the common bucket by gathering cpus work\n\t\t\tfor j := 0; j < 255; j++ {\n\t\t\t\tfor k := 0; k < nbCpus; k++ {\n\t\t\t\t\tcommonBucket[i][j].Add(curve, &sharedBuckets[k][i][j])\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\t// ...[chunk*8..(chunk+1)*8-1]... -th bits\n\t\tvar acc G2Jac\n\t\tfor i := 0; i < 32; i++ {\n\t\t\tacc.Set(&curve.g2Infinity)\n\t\t\tfor j := 254; j >= 0; j-- {\n\t\t\t\tacc.Add(curve, &commonBucket[i][j])\n\t\t\t\talmostThere[i].Add(curve, &acc)\n\t\t\t}\n\t\t}\n\n\t\t// double and add to compute p\n\t\tp.Set(&curve.g2Infinity)\n\t\tfor i := 31; i >= 0; i-- {\n\t\t\tfor j := 0; j < 8; j++ {\n\t\t\t\tp.Double()\n\t\t\t}\n\t\t\tp.Add(curve, &almostThere[i])\n\t\t}\n\t\tchRes <- *p\n\t}()\n\n\treturn chRes\n}", "func Worker(mapf func(string, string) []KeyValue,\n\treducef func(string, []string) string) {\n\n\t\tports = Ports{ usedPorts: make(map[int]bool) }\n\t\t\n\n\t\tjob := new(Job)\n\t\tjob.MapFunc = mapf\n\t\tjob.RedFunc = reducef\n\t\tjob.JobType = Mapper\n\n\n\t\tspawnChannel := make(chan int)\n\t\tsomechan := make(chan bool)\n\t\tgo StartRPCClient(spawnChannel, somechan, job)\n\n\t\ttime.Sleep(10*time.Millisecond)\n\t\tgo SpawnReducers(somechan, job)\n\t\tSpawnMappers(spawnChannel, job)\n}", "func schedule(jobName string, mapFiles []string, nReduce int, phase jobPhase, registerChan chan string) {\n\tvar ntasks int\n\tvar n_other int // number of inputs (for reduce) or outputs (for map)\n\tswitch phase {\n\tcase mapPhase:\n\t\tntasks = len(mapFiles)\n\t\tn_other = nReduce\n\tcase reducePhase:\n\t\tntasks = nReduce\n\t\tn_other = len(mapFiles)\n\t}\n\n\tfmt.Printf(\"Schedule: %v %v tasks (%d I/Os)\\n\", ntasks, phase, n_other)\n\n\t// All ntasks tasks have to be scheduled on workers. Once all tasks\n\t// have completed successfully, schedule() should return.\n\t//\n\t// Your code here (Part III, Part IV).\n\t//\n\tvar wg sync.WaitGroup\n\tfor i := 0; i < ntasks; i++ {\n\t\twg.Add(1)\n\t\tgo func(taskIndex int) {\n\t\t\tdefer wg.Done()\n\t\t\t// 1. Build DoTaskArgs entity.\n\t\t\tvar args DoTaskArgs\n\t\t\targs.Phase = phase\n\t\t\targs.JobName = jobName\n\t\t\targs.TaskNumber = taskIndex\n\t\t\targs.NumOtherPhase = n_other\n\t\t\tif phase == mapPhase {\n\t\t\t\targs.File = mapFiles[taskIndex]\n\t\t\t}\n\t\t\t// 2. Send DoTaskJob rpc.\n\t\t\tfor { // Note Loop call util success if there exists worker failure.\n\t\t\t\t// 3. Fetch worker from registerChan.\n\t\t\t\t// Note if one worker goes down, it won't be fetched from registerChan.\n\t\t\t\twork := <-registerChan\n\t\t\t\tok := call(work, \"Worker.DoTask\", &args, new(struct{}))\n\t\t\t\tif ok == false {\n\t\t\t\t\tfmt.Printf(\"Master: RPC %s schedule error for %s task %d.\\n\", work, phase, taskIndex)\n\t\t\t\t\tfmt.Printf(\"Master: Redo - RPC schedule error for %s task %d.\\n\", phase, taskIndex)\n\t\t\t\t} else {\n\t\t\t\t\tfmt.Printf(\"Master: RPC %s schedule success for %s task %d.\\n\", work, phase, taskIndex)\n\t\t\t\t\t// 4. Register worker (ready) in parallel to avoid block.\n\t\t\t\t\tgo func() {\n\t\t\t\t\t\tregisterChan <- work\n\t\t\t\t\t}()\n\t\t\t\t\tfmt.Printf(\"Master: %d tasks over!\\n\", taskIndex)\n\t\t\t\t\tbreak\n\t\t\t\t}\n\t\t\t}\n\t\t}(i)\n\t}\n\twg.Wait() // Wait for all (ntasks) task to compelete.\n\tfmt.Printf(\"Schedule: %v done\\n\", phase)\n}", "func schedule(jobName string, mapFiles []string, nReduce int, phase jobPhase, registerChan chan string) {\n\tvar totaljobs, iolength int\n\twg := new(sync.WaitGroup)\n\tif phase == mapPhase {\n\t\ttotaljobs = len(mapFiles)\n\t\tiolength = nReduce\n\t}\n\tif phase == reducePhase {\n\t\ttotaljobs = nReduce\n\t\tiolength = len(mapFiles)\n\t}\n\tfor temp := 0; temp < totaljobs; temp++ {\n\t\twg.Add(1)\n\t\tvar dotaskargs DoTaskArgs\n\t\tif phase == mapPhase {\n\t\t\tdotaskargs = DoTaskArgs{jobName, mapFiles[temp], phase, temp, iolength}\n\t\t}\n\t\tif phase == reducePhase {\n\t\t\tdotaskargs = DoTaskArgs{jobName, \"\", phase, temp, iolength}\n\t\t}\n\t\tgo func() {\n\t\t\tfor {\n\t\t\t\twrkinf := <-registerChan\n\t\t\t\tstatus := call(wrkinf, \"Worker.DoTask\", &dotaskargs, new(struct{}))\n\t\t\t\tif status == true {\n\t\t\t\t\tgo func() {\n\t\t\t\t\t\tregisterChan <- wrkinf\n\t\t\t\t\t}()\n\t\t\t\t\tbreak\n\t\t\t\t}\n\t\t\t}\n\t\t\twg.Done()\n\t\t}()\n\t}\n\twg.Wait()\n}", "func (p *regressionDetectionProcess) run(ctx context.Context) error {\n\tctx, span := trace.StartSpan(ctx, \"regressionDetectionProcess.run\")\n\tdefer span.End()\n\n\tif p.request.Alert.Algo == \"\" {\n\t\tp.request.Alert.Algo = types.KMeansGrouping\n\t}\n\tfor p.iter.Next() {\n\t\tdf, err := p.iter.Value(ctx)\n\t\tif err != nil {\n\t\t\treturn p.reportError(err, \"Failed to get DataFrame from DataFrameIterator.\")\n\t\t}\n\t\tp.request.Progress.Message(\"Gathering\", fmt.Sprintf(\"Next dataframe: %d traces\", len(df.TraceSet)))\n\t\tsklog.Infof(\"Next dataframe: %d traces\", len(df.TraceSet))\n\t\tbefore := len(df.TraceSet)\n\t\t// Filter out Traces with insufficient data. I.e. we need 50% or more data\n\t\t// on either side of the target commit.\n\t\tdf.FilterOut(tooMuchMissingData)\n\t\tafter := len(df.TraceSet)\n\t\tmessage := fmt.Sprintf(\"Filtered Traces: Num Before: %d Num After: %d Delta: %d\", before, after, before-after)\n\t\tp.request.Progress.Message(\"Filtering\", message)\n\t\tsklog.Info(message)\n\t\tif after == 0 {\n\t\t\tcontinue\n\t\t}\n\n\t\tk := p.request.Alert.K\n\t\tif k <= 0 || k > maxK {\n\t\t\tn := len(df.TraceSet)\n\t\t\t// We want K to be around 50 when n = 30000, which has been determined via\n\t\t\t// trial and error to be a good value for the Perf data we are working in. We\n\t\t\t// want K to decrease from there as n gets smaller, but don't want K to go\n\t\t\t// below 10, so we use a simple linear relation:\n\t\t\t//\n\t\t\t// k = 40/30000 * n + 10\n\t\t\t//\n\t\t\tk = int(math.Floor((40.0/30000.0)*float64(n) + 10))\n\t\t}\n\t\tsklog.Infof(\"Clustering with K=%d\", k)\n\n\t\tvar summary *clustering2.ClusterSummaries\n\t\tswitch p.request.Alert.Algo {\n\t\tcase types.KMeansGrouping:\n\t\t\tp.request.Progress.Message(\"K\", fmt.Sprintf(\"%d\", k))\n\t\t\tsummary, err = clustering2.CalculateClusterSummaries(ctx, df, k, config.MinStdDev, p.detectionProgress, p.request.Alert.Interesting, p.request.Alert.Step)\n\t\tcase types.StepFitGrouping:\n\t\t\tsummary, err = StepFit(ctx, df, k, config.MinStdDev, p.detectionProgress, p.request.Alert.Interesting, p.request.Alert.Step)\n\t\tdefault:\n\t\t\terr = skerr.Fmt(\"Invalid type of clustering: %s\", p.request.Alert.Algo)\n\t\t}\n\t\tif err != nil {\n\t\t\treturn p.reportError(err, \"Invalid regression detection.\")\n\t\t}\n\t\tif err := p.shortcutFromKeys(summary); err != nil {\n\t\t\treturn p.reportError(err, \"Failed to write shortcut for keys.\")\n\t\t}\n\n\t\tdf.TraceSet = types.TraceSet{}\n\t\tframe, err := frame.ResponseFromDataFrame(ctx, nil, df, p.perfGit, false, p.request.Progress)\n\t\tif err != nil {\n\t\t\treturn p.reportError(err, \"Failed to convert DataFrame to FrameResponse.\")\n\t\t}\n\n\t\tcr := &RegressionDetectionResponse{\n\t\t\tSummary: summary,\n\t\t\tFrame: frame,\n\t\t}\n\t\tp.detectorResponseProcessor(p.request, []*RegressionDetectionResponse{cr}, message)\n\t}\n\t// We Finish the process, but record Results. The detectorResponseProcessor\n\t// callback should add the results to Progress if that's required.\n\treturn nil\n}", "func doWorkBSP(task *Task, threadCount int, writeTasks chan<- *writeTask, frameDone <-chan struct{}, wg *sync.WaitGroup) {\n\t// initialize simulation worker channels\n\tsimWorkerStart := make(chan bool)\n\tsimWorkerDone := make(chan struct{})\n\n\t// add 1 to wait group so main worker doesn't exit before sim worker is done\n\twg.Add(1)\n\n\t// spawn simulation worker\n\tgo simWorker(task.sg.sim, simWorkerStart, simWorkerDone, wg)\n\n\t// create barrier\n\tbar := barrier.BarrierCreate(threadCount+1, frameDone, simWorkerDone)\n\n\t// cycle through GIF frames\n\tfor i:=0; i<int(task.sg.GIF.Frames()); i++ {\n\n\t\t// initalize the current frame\n\t\ttask.sg.InitFrame()\n\n\t\t// push image chunks to write to writeTasks channel\n\t\t// image chunks will be handled by writerWorkers\n\t\tfor i:=0; i<threadCount; i++ {\n\t\t\twriteTasks <- &writeTask{task.sg, task.sg.GIF.Bounds(i), task.sg.sim.cubePrevState, i, task.id}\n\t\t}\n\t\t\n\t\t// tell sim worker to start work\n\t\tsimWorkerStart<-true\n\n\t\t// synchronize writers + simulation workers via barrier\n\t\tbar.Wait()\n\n\t\t// update prevState density values\n\t\ttask.sg.sim.UpdatePrevState()\n\n\t\t// increment simulation tick\n\t\ttask.sg.sim.NextTick()\n\t}\n\n\t// tell sim worker to stop waiting for more work\n\tclose(simWorkerStart)\n}", "func (ec *EvalCtx) fork(newContext string) *EvalCtx {\n\tnewPorts := make([]*Port, len(ec.ports))\n\tfor i, p := range ec.ports {\n\t\tnewPorts[i] = p.Fork()\n\t}\n\treturn &EvalCtx{\n\t\tec.Evaler,\n\t\tec.name, ec.text, newContext,\n\t\tec.local, ec.up,\n\t\tnewPorts, ec.begin, ec.end,\n\t}\n}", "func distributor(p golParams, d distributorChans, alive chan []cell) {\n\n\t// Create the 2D slice to store the world.\n\tworld := make([][]byte, p.imageHeight)\n\tfor i := range world {\n\t\tworld[i] = make([]byte, p.imageWidth)\n\t}\n\n\t// Request the io goroutine to read in the image with the given filename.\n\td.io.command <- ioInput\n\td.io.filename <- strings.Join([]string{strconv.Itoa(p.imageWidth), strconv.Itoa(p.imageHeight)}, \"x\")\n\n\t// The io goroutine sends the requested image byte by byte, in rows.\n\tfor y := 0; y < p.imageHeight; y++ {\n\t\tfor x := 0; x < p.imageWidth; x++ {\n\t\t\tval := <-d.io.inputVal\n\t\t\tif val != 0 {\n\t\t\t\tfmt.Println(\"Alive cell at\", x, y)\n\t\t\t\tworld[y][x] = val\n\t\t\t}\n\t\t}\n\t}\n\n\t// Calculate the new state of Game of Life after the given number of turns.\n\t//calculate the height of the world every worker get\n\t//creat the out channel\n\tout := make([]chan byte, p.threads)\n\tsendByte := make(chan byte)\n\n\tfor turns := 0; turns < p.turns; turns++ {\n\t\tsubHeight := p.imageHeight/p.threads\n\n\n\n\t\t//split the world and distribute them to workers\n\t\tfor i := 0; i < p.threads; i++{\n\t\t\tout[i] = make(chan byte)\n\t\t\tgo worker(subHeight, p.imageWidth, sendByte, out[i])\n\t\t\tbuildWorld(world, i, subHeight, p.imageWidth, p.threads, sendByte)\n\t\t}\n\n\n\t\t//receive world parts and re-gather them\n\t\tfor i := 0; i < p.threads; i++{\n\n\t\t\tnewWorldPart := make([][]byte, subHeight)\n\t\t\tfor i := range newWorldPart{\n\t\t\t\tnewWorldPart[i] = make([]byte, p.imageHeight)\n\t\t\t}\n\n\t\t\tfor y := 0 ; y < len(newWorldPart); y++{\n\t\t\t\tfor x := 0; x < p.imageWidth; x++{\n\t\t\t\t\tnewWorldPart[y][x] = <- out[i]\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tfor y := 0; y < subHeight; y++{\n\t\t\t\tfor x := 0; x < p.imageHeight; x++{\n\t\t\t\t\tworld[subHeight * i + y][x] = newWorldPart[y][x]\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\n\t// Create an empty slice to store coordinates of cells that are still alive after p.turns are done.\n\tvar finalAlive []cell\n\t// Go through the world and append the cells that are still alive.\n\tfor y := 0; y < p.imageHeight; y++ {\n\t\tfor x := 0; x < p.imageWidth; x++ {\n\t\t\tif world[y][x] != 0 {\n\t\t\t\tfinalAlive = append(finalAlive, cell{x: x, y: y})\n\t\t\t}\n\t\t}\n\t}\n\n\td.io.command <- ioOutput\n\td.io.filename <- strings.Join([]string{strconv.Itoa(p.imageWidth), strconv.Itoa(p.imageHeight)}, \"x\")\n\td.io.outputWorld <- world\n\t// Make sure that the Io has finished any output before exiting.\n\td.io.command <- ioCheckIdle\n\t<-d.io.idle\n\n\t// Return the coordinates of cells that are still alive.\n\talive <- finalAlive\n}", "func (self *GameObjectCreator) GroupI(args ...interface{}) *Group{\n return &Group{self.Object.Call(\"group\", args)}\n}", "func CreateMultiBandImageClusteringPipeline(name string, description string,\n\tgrouping *model.MultiBandImageGrouping, variables []*model.Variable, params *ClusterParams,\n\tbatchSize int, numJobs int) (*FullySpecifiedPipeline, error) {\n\n\tvar imageVar *model.Variable\n\tvar groupVar *model.Variable\n\tfor _, v := range variables {\n\t\tif v.Key == grouping.ImageCol {\n\t\t\timageVar = v\n\t\t} else if v.Key == grouping.IDCol {\n\t\t\tgroupVar = v\n\t\t}\n\t}\n\tif imageVar == nil {\n\t\treturn nil, errors.Errorf(\"image var with name '%s' not found in supplied variables\", grouping.ImageCol)\n\t}\n\tif groupVar == nil {\n\t\treturn nil, errors.Errorf(\"grouping var with name '%s' not found in supplied variables\", grouping.IDCol)\n\t}\n\n\taddGroup := &ColumnUpdate{\n\t\tSemanticTypes: []string{\"https://metadata.datadrivendiscovery.org/types/GroupingKey\"},\n\t\tIndices: []int{groupVar.Index},\n\t}\n\n\tvar steps []Step\n\tif params.UseKMeans {\n\t\tsteps = []Step{\n\t\t\tNewDenormalizeStep(map[string]DataRef{\"inputs\": &PipelineDataRef{0}}, []string{\"produce\"}),\n\t\t\tNewAddSemanticTypeStep(nil, nil, addGroup),\n\t\t\tNewDatasetWrapperStep(map[string]DataRef{\"inputs\": &StepDataRef{0, \"produce\"}}, []string{\"produce\"}, 1, \"\"),\n\t\t\tNewDatasetToDataframeStep(map[string]DataRef{\"inputs\": &StepDataRef{2, \"produce\"}}, []string{\"produce\"}),\n\t\t\tNewSatelliteImageLoaderStep(map[string]DataRef{\"inputs\": &StepDataRef{3, \"produce\"}}, []string{\"produce\"}, numJobs),\n\t\t\tNewColumnParserStep(map[string]DataRef{\"inputs\": &StepDataRef{4, \"produce\"}}, []string{\"produce\"},\n\t\t\t\t[]string{model.TA2BooleanType, model.TA2IntegerType, model.TA2RealType, model.TA2RealVectorType}),\n\t\t\tNewRemoteSensingPretrainedStep(map[string]DataRef{\"inputs\": &StepDataRef{5, \"produce\"}}, []string{\"produce\"}, batchSize, true),\n\t\t\tNewKMeansClusteringStep(map[string]DataRef{\"inputs\": &StepDataRef{6, \"produce\"}}, []string{\"produce\"}, params.ClusterCount),\n\t\t\tNewConstructPredictionStep(map[string]DataRef{\"inputs\": &StepDataRef{7, \"produce\"}}, []string{\"produce\"}, &StepDataRef{4, \"produce\"}),\n\t\t}\n\t} else {\n\t\taddImage := &ColumnUpdate{\n\t\t\tSemanticTypes: []string{\"https://metadata.datadrivendiscovery.org/types/TrueTarget\"},\n\t\t\tIndices: []int{imageVar.Index},\n\t\t}\n\n\t\tsteps = []Step{\n\t\t\tNewDenormalizeStep(map[string]DataRef{\"inputs\": &PipelineDataRef{0}}, []string{\"produce\"}),\n\t\t\tNewAddSemanticTypeStep(nil, nil, addGroup),\n\t\t\tNewDatasetWrapperStep(map[string]DataRef{\"inputs\": &StepDataRef{0, \"produce\"}}, []string{\"produce\"}, 1, \"\"),\n\t\t\tNewDatasetToDataframeStep(map[string]DataRef{\"inputs\": &StepDataRef{2, \"produce\"}}, []string{\"produce\"}),\n\t\t\tNewSatelliteImageLoaderStep(map[string]DataRef{\"inputs\": &StepDataRef{3, \"produce\"}}, []string{\"produce\"}, numJobs),\n\t\t\tNewAddSemanticTypeStep(map[string]DataRef{\"inputs\": &StepDataRef{4, \"produce\"}}, []string{\"produce\"}, addImage),\n\t\t\tNewColumnParserStep(map[string]DataRef{\"inputs\": &StepDataRef{5, \"produce\"}}, []string{\"produce\"},\n\t\t\t\t[]string{model.TA2BooleanType, model.TA2IntegerType, model.TA2RealType, model.TA2RealVectorType}),\n\t\t\tNewRemoteSensingPretrainedStep(map[string]DataRef{\"inputs\": &StepDataRef{6, \"produce\"}}, []string{\"produce\"}, batchSize, true),\n\t\t\tNewHDBScanStep(map[string]DataRef{\"inputs\": &StepDataRef{7, \"produce\"}}, []string{\"produce\"}),\n\t\t\tNewExtractColumnsStep(map[string]DataRef{\"inputs\": &StepDataRef{8, \"produce\"}}, []string{\"produce\"}, []int{-1}),\n\t\t\tNewConstructPredictionStep(map[string]DataRef{\"inputs\": &StepDataRef{9, \"produce\"}}, []string{\"produce\"}, &StepDataRef{5, \"produce\"}),\n\t\t}\n\t}\n\n\tinputs := []string{\"inputs\"}\n\toutputs := []DataRef{&StepDataRef{len(steps) - 1, \"produce\"}}\n\n\tpipeline, err := NewPipelineBuilder(name, description, inputs, outputs, steps).Compile()\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\n\tpipelineJSON, err := MarshalSteps(pipeline)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\n\tfullySpecified := &FullySpecifiedPipeline{\n\t\tPipeline: pipeline,\n\t\tEquivalentValues: []interface{}{pipelineJSON},\n\t}\n\treturn fullySpecified, nil\n}", "func split(metadata *core.Metadata) (*core.StageDefs, error) {\n\tvar args SumSquaresArgs\n\tif err := metadata.ReadInto(core.ArgsFile, &args); err != nil {\n\t\treturn nil, err\n\t}\n\tsd := &core.StageDefs{\n\t\tChunkDefs: make([]*core.ChunkDef, 0, len(args.Values)),\n\t\tJoinDef: &core.JobResources{\n\t\t\tThreads: 1,\n\t\t\tMemGB: 1,\n\t\t},\n\t}\n\tfor _, val := range args.Values {\n\t\tdef, err := (&SumSquaresChunkDef{\n\t\t\tValue: val,\n\t\t\tJobResources: &core.JobResources{\n\t\t\t\tThreads: 1,\n\t\t\t\tMemGB: 1,\n\t\t\t},\n\t\t}).ToChunkDef()\n\t\tif err != nil {\n\t\t\treturn sd, err\n\t\t}\n\t\tsd.ChunkDefs = append(sd.ChunkDefs, def)\n\t}\n\treturn sd, nil\n}", "func (h *connHandler) parallel(m *reqData, args []interface{}) {\n\th.Lock()\n\theap.Push(&h.pQueue, m)\n\th.Unlock()\n\n\tm.resp = h.srv.pool.Cmd(m.cmd, args...)\n\n\th.Lock()\n\tfor h.pQueue.Len() > 0 {\n\t\titem := heap.Pop(&h.pQueue).(*reqData)\n\t\tif item.resp == nil {\n\t\t\theap.Push(&h.pQueue, item)\n\t\t\tbreak\n\t\t}\n\t\tif item.answerCh != nil {\n\t\t\titem.answerCh <- item.resp\n\t\t}\n\t}\n\th.Unlock()\n}", "func main() {\n\n //bring up the services\n\tmasterSrvAddr := master.StartMasterSrv(9090) //9090\n\tworkerSrvAddr1 := worker.StartWorkerSrv(9091); //9091 ,9092, 9093\n\tworkerSrvAddr2 := worker.StartWorkerSrv(9092);\n\tworker.StartWorkerCli(masterSrvAddr, []string{workerSrvAddr1,workerSrvAddr2});\n\tmaster.StartMasterCli();\n\n\t//distributed map-reduce flow\n\tmapOutput,err := master.DoOperation([]string{\"/Users/k0c00nc/go/src/MapReduce/res/input.txt\", \"/Users/k0c00nc/go/src/distributedDb\" +\n\t\t\"/res/input1.txt\"},\"Map\")\n\tif err !=nil{\n\t\tfmt.Printf(\"map phase failed with err %s \", err.Error())\n\t}\n\n\tlocalAggregation,err :=master.DoOperation(mapOutput,\"LocalAggregation\")\n\tif err !=nil{\n\t\tfmt.Printf(\"localAggregation phase failed with err %s \", err.Error())\n\t}\n\n\tshuffing,err :=master.DoOperation(localAggregation,\"Shuffing\")\n\tif err !=nil{\n\t\tfmt.Printf(\"shuffing phase failed with err %s \", err.Error())\n\t}\n\n\treduce,err :=master.DoOperation(shuffing,\"Reduce\")\n\tif err !=nil{\n\t\tfmt.Printf(\"reduce phase failed with err %s \", err.Error())\n\t}\n\n fmt.Println(\"MR output are in file\", reduce[0])\n\n}", "func (f *VRFTest) createChainlinkJobs() error {\n\tjobsChan := make(chan ContractsNodesJobsMap, len(f.chainlinkClients)*len(f.contractInstances))\n\tg := NewLimitErrGroup(30)\n\tfor _, p := range f.contractInstances {\n\t\tp := p\n\t\tfor _, n := range f.chainlinkClients {\n\t\t\tn := n\n\t\t\tg.Go(func() error {\n\t\t\t\tnodeKeys, err := n.ReadVRFKeys()\n\t\t\t\tif err != nil {\n\t\t\t\t\treturn err\n\t\t\t\t}\n\t\t\t\tpubKeyCompressed := nodeKeys.Data[0].ID\n\t\t\t\tjobUUID := uuid.NewV4()\n\t\t\t\tos := &client.VRFTxPipelineSpec{\n\t\t\t\t\tAddress: p.coordinator.Address(),\n\t\t\t\t}\n\t\t\t\tost, err := os.String()\n\t\t\t\tif err != nil {\n\t\t\t\t\treturn err\n\t\t\t\t}\n\t\t\t\tjobID, err := n.CreateJob(&client.VRFJobSpec{\n\t\t\t\t\tName: \"vrf\",\n\t\t\t\t\tCoordinatorAddress: p.coordinator.Address(),\n\t\t\t\t\tPublicKey: pubKeyCompressed,\n\t\t\t\t\tConfirmations: 1,\n\t\t\t\t\tExternalJobID: jobUUID.String(),\n\t\t\t\t\tObservationSource: ost,\n\t\t\t\t})\n\t\t\t\tif err != nil {\n\t\t\t\t\treturn err\n\t\t\t\t}\n\t\t\t\toracleAddr, err := n.PrimaryEthAddress()\n\t\t\t\tif err != nil {\n\t\t\t\t\treturn err\n\t\t\t\t}\n\t\t\t\tprovingKey, err := actions.EncodeOnChainVRFProvingKey(nodeKeys.Data[0])\n\t\t\t\tif err != nil {\n\t\t\t\t\treturn err\n\t\t\t\t}\n\t\t\t\tif err = p.coordinator.RegisterProvingKey(\n\t\t\t\t\tf.Wallets.Default(),\n\t\t\t\t\tbig.NewInt(1),\n\t\t\t\t\toracleAddr,\n\t\t\t\t\tprovingKey,\n\t\t\t\t\tactions.EncodeOnChainExternalJobID(jobUUID),\n\t\t\t\t); err != nil {\n\t\t\t\t\treturn err\n\t\t\t\t}\n\t\t\t\trequestHash, err := p.coordinator.HashOfKey(context.Background(), provingKey)\n\t\t\t\tif err != nil {\n\t\t\t\t\treturn err\n\t\t\t\t}\n\t\t\t\tjobsChan <- ContractsNodesJobsMap{p: map[client.Chainlink]NodeData{n: VRFNodeData{JobID: jobID.Data.ID, ProvingKeyHash: requestHash}}}\n\t\t\t\treturn nil\n\t\t\t})\n\t\t}\n\t}\n\tif err := g.Wait(); err != nil {\n\t\treturn err\n\t}\n\tclose(jobsChan)\n\tf.jobMap.FromJobsChan(jobsChan)\n\treturn nil\n}", "func (p *WorkerPool[T, R]) Start() {\n\tif p.taskChan == nil {\n\t\tp.taskChan = make(chan T)\n\t}\n\n\tif p.resChan == nil {\n\t\tvar zero R\n\t\tvar r interface{} = zero\n\t\tif _, ok := r.(None); !ok {\n\t\t\tp.resChan = make(chan R)\n\t\t}\n\t}\n\n\tfor i := 0; i < int(p.numWorkers); i++ {\n\t\tp.runAWorker()\n\t}\n}", "func (lbs *LoadBasedAlg) computeNumTasksToStart(numIdleWorkers int) {\n\n\tvar haveUnallocatedTasks bool\n\n\tnumIdleWorkers, haveUnallocatedTasks = lbs.entitlementTasksToStart(numIdleWorkers)\n\n\tif numIdleWorkers > 0 && haveUnallocatedTasks {\n\t\tlbs.workerLoanAllocation(numIdleWorkers, false)\n\t}\n}", "func Work(ctx context.Context, mapWorker MapWorker, inputs <-chan Keyer) <-chan Keyer {\n\tc := make(chan Keyer)\n\tgo mapWorker(ctx, inputs, c)\n\treturn c\n}", "func init() {\n\tpools = make([]*sync.Pool, len(bucketSize))\n\tfor i, v := range bucketSize {\n\t\t// to use new variable inside the New function\n\t\tv1 := v\n\t\tpools[i] = &sync.Pool{\n\t\t\tNew: func() interface{} {\n\t\t\t\treturn make([]byte, v1)\n\t\t\t},\n\t\t}\n\t}\n}", "func (m *workerManager) startWorkers(ctx context.Context, count int) {\n\tm.logger.Debug(\"Starting %d Global Bus workers\", count)\n\tfor i := 0; i < count; i++ {\n\t\tm.startWorker(ctx)\n\t}\n}" ]
[ "0.55626047", "0.5562137", "0.5266236", "0.5253545", "0.51667637", "0.5161495", "0.51379347", "0.51379347", "0.5066979", "0.50624967", "0.50232434", "0.49888834", "0.4939983", "0.4909606", "0.4904584", "0.490034", "0.4868336", "0.4844424", "0.48417827", "0.4829529", "0.48286828", "0.4824439", "0.48083875", "0.47923276", "0.47891402", "0.4781574", "0.47727433", "0.47713256", "0.4768913", "0.47668287", "0.47599614", "0.47542435", "0.47508782", "0.4740215", "0.47367576", "0.47349772", "0.47210595", "0.4716497", "0.47129494", "0.47083417", "0.46965075", "0.4681149", "0.46799514", "0.4672566", "0.4650628", "0.4650289", "0.4619932", "0.46138325", "0.46134874", "0.45992348", "0.45921913", "0.4591419", "0.4583501", "0.45828992", "0.45779005", "0.45760188", "0.4574937", "0.4568793", "0.45673424", "0.4561907", "0.4559069", "0.45450652", "0.4535808", "0.4534846", "0.4531376", "0.45302916", "0.45255205", "0.45240715", "0.45184883", "0.45171317", "0.45154417", "0.45125732", "0.45112765", "0.45067906", "0.45064953", "0.45032322", "0.45020708", "0.44949442", "0.4490707", "0.44898945", "0.44859433", "0.44858998", "0.44854072", "0.4483642", "0.44829977", "0.44796243", "0.4479534", "0.44759378", "0.44734016", "0.4471142", "0.44710544", "0.4465945", "0.44654343", "0.44640973", "0.446098", "0.44601977", "0.44588357", "0.44540745", "0.445269", "0.44494763", "0.44433627" ]
0.0
-1
render primitives from array data
func DrawArrays(mode uint32, first int32, count int32) { C.glowDrawArrays(gpDrawArrays, (C.GLenum)(mode), (C.GLint)(first), (C.GLsizei)(count)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func renderResults(vals []interface{}) Data {\n\tvar nilcount int\n\tvar obj interface{}\n\tfor _, val := range vals {\n\t\tswitch val.(type) {\n\t\tcase image.Image, Data:\n\t\t\tobj = val\n\t\tcase nil:\n\t\t\tnilcount++\n\t\t}\n\t}\n\tif obj != nil && nilcount == len(vals)-1 {\n\t\tswitch val := obj.(type) {\n\t\tcase image.Image:\n\t\t\tdata, err := image0(val)\n\t\t\tif err == nil {\n\t\t\t\treturn data\n\t\t\t}\n\t\tcase Data:\n\t\t\treturn val\n\t\t}\n\t}\n\tif nilcount == len(vals) {\n\t\t// if all values are nil, return empty Data\n\t\treturn Data{}\n\t}\n\treturn MakeData(\"text/plain\", fmt.Sprint(vals...))\n}", "func (v Binary) Render(i, width int, baseStyle lipgloss.Style) string {\n\tw := dataWidth(width)\n\t_, err := v.Seek(int64(i*w), io.SeekStart)\n\tif err != nil {\n\t\treturn baseStyle.Blink(true).Render(err.Error())\n\t}\n\tif len(v.b) != w {\n\t\tv.b = make([]byte, w)\n\t}\n\tn, err := v.Read(v.b)\n\tif err != nil && !errors.Is(err, io.EOF) {\n\t\treturn baseStyle.Blink(true).Render(err.Error())\n\t}\n\ts := fmt.Sprintf(\"% X%s \", v.b[0:n], strings.Repeat(\" \", w-n))\n\tvar x strings.Builder\n\tfor i := 0; i < n; i++ {\n\t\tif unicode.IsPrint(rune(v.b[i])) {\n\t\t\tx.WriteRune(rune(v.b[i]))\n\t\t} else {\n\t\t\tx.WriteRune('.')\n\t\t}\n\t}\n\treturn baseStyle.Render(s + x.String())\n}", "func (sr scoresRenderer) Render() string {\n\tbuffer := bytes.Buffer{}\n\tlast := len(sr.scores) - 1\n\tfor i, score := range sr.scores {\n\t\tbuffer.WriteString(fmt.Sprintf(\"%d\", score))\n\t\tif i != last {\n\t\t\tbuffer.WriteString(\" / \")\n\t\t}\n\t}\n\treturn buffer.String()\n}", "func (r *Renderer) Render() {\n\tsx, sz, sy := r.c.Bounds()\n\tsxf := float64(sx - 1)\n\tsyf := float64(sy - 1)\n\tszf := float64(sz - 1)\n\tfor z := 0; z < sz; z++ {\n\t\tfor y := 0; y < sy; y++ {\n\t\t\tfor x := 0; x < sx; x++ {\n\t\t\t\tvar lr, lg, lb, _ uint32\n\t\t\t\tn := uint32(0)\n\t\t\t\tfor _, o := range r.objects {\n\t\t\t\t\tr, g, b, _ := o.At(float64(x)/sxf, float64(y)/syf, float64(z)/szf).RGBA()\n\t\t\t\t\tlr += r >> 8\n\t\t\t\t\tlg += g >> 8\n\t\t\t\t\tlb += b >> 8\n\t\t\t\t\tn++\n\t\t\t\t}\n\t\t\t\tr.c.Set(x, y, z, color.RGBA{uint8(lr/n), uint8(lg/n), uint8(lb/n), 255})\n\t\t\t}\n\t\t}\n\t}\n\tr.c.Render()\n}", "func render(fset *token.FileSet, x interface{}) string {\n\tvar buf bytes.Buffer\n\tif err := printer.Fprint(&buf, fset, x); err != nil {\n\t\tpanic(err)\n\t}\n\treturn buf.String()\n}", "func render(fset *token.FileSet, x interface{}) string {\n\tvar buf bytes.Buffer\n\tif err := printer.Fprint(&buf, fset, x); err != nil {\n\t\tpanic(err)\n\t}\n\treturn buf.String()\n}", "func (a Array) String() string {\n\tvar buf bytes.Buffer\n\tfor i, v := range a {\n\t\tbuf.WriteString(fmt.Sprintf(\"[%2d] %[2]v (%[2]T)\\n\", i, v))\n\t}\n\treturn buf.String()\n}", "func (e *rawData) Render(w io.Writer) (int, error) { return w.Write([]byte(e.content)) }", "func (sl SprintList) renderPlain(w io.Writer) error {\n\treturn renderPlain(w, sl.tableData())\n}", "func (val *float32ArrayValue) String() string {\n\tvar buffer strings.Builder\n\tfor _, v := range *val {\n\t\tif buffer.Len() != 0 {\n\t\t\tbuffer.WriteString(\", \")\n\t\t}\n\t\tfmt.Fprintf(&buffer, \"%v\", v)\n\t}\n\treturn buffer.String()\n}", "func (t *textRender) Render(w io.Writer) (err error) {\n\tif len(t.Values) > 0 {\n\t\t_, err = fmt.Fprintf(w, t.Format, t.Values...)\n\t} else {\n\t\t_, err = io.WriteString(w, t.Format)\n\t}\n\treturn\n}", "func (c *Controller) Data(data []byte) {\n ctx := c.Context()\n r := render.NewData(data)\n\n ctx.PushLog(\"status\", http.StatusOK)\n ctx.SetHeader(\"Content-Type\", r.ContentType())\n ctx.End(r.HttpCode(), r.Content())\n}", "func (a *Array) Print() {\n\tvar format string\n\tfor i := uint(0); i < a.Len(); i++ {\n\t\tformat += fmt.Sprintf(\"|%+v\", a.data[i])\n\t}\n\tfmt.Println(format)\n}", "func (val *uint8ArrayValue) String() string {\n\tvar buffer strings.Builder\n\tfor _, v := range *val {\n\t\tif buffer.Len() != 0 {\n\t\t\tbuffer.WriteString(\", \")\n\t\t}\n\t\tfmt.Fprintf(&buffer, \"%v\", v)\n\t}\n\treturn buffer.String()\n}", "func (tofu Tofu) Render(wr io.Writer, name string, obj interface{}) error {\n\tvar m data.Map\n\tif obj != nil {\n\t\tvar ok bool\n\t\tm, ok = data.New(obj).(data.Map)\n\t\tif !ok {\n\t\t\treturn fmt.Errorf(\"invalid data type. expected map/struct, got %T\", obj)\n\t\t}\n\t}\n\treturn tofu.NewRenderer(name).Execute(wr, m)\n}", "func (l LogItems) Render(showTime bool, ll [][]byte) {\n\tcolors := make(map[string]int, len(l))\n\tfor i, item := range l {\n\t\tinfo := item.ID()\n\t\tcolor, ok := colors[info]\n\t\tif !ok {\n\t\t\tcolor = colorFor(info)\n\t\t\tcolors[info] = color\n\t\t}\n\t\tll[i] = item.Render(color, showTime)\n\t}\n}", "func (o TypeResponseOutput) Primitive() pulumi.StringOutput {\n\treturn o.ApplyT(func(v TypeResponse) string { return v.Primitive }).(pulumi.StringOutput)\n}", "func (g *Game) Render() string {\n\tascii := \"\"\n\n\tm := g.generateScreen()\n\tfor _, row := range m.cells {\n\t\tascii += strings.Join(row, \"\") + \"\\n\"\n\t}\n\n\treturn ascii\n}", "func renderDisplayData(value interface{}) (data, metadata map[string]interface{}, err error) {\n\t// TODO(axw) sniff/provide a way to specify types for things that net/http does not sniff:\n\t// - SVG\n\t// - JSON\n\t// - LaTeX\n\tdata = make(map[string]interface{})\n\tmetadata = make(map[string]interface{})\n\tvar stringValue, contentType string\n\tswitch typedValue := value.(type) {\n\tcase image.Image:\n\t\t// TODO(axw) provide a way for the user to use alternative encodings?\n\t\t//\n\t\t// The current presumption is that images will be mostly used\n\t\t// for displaying graphs or illustrations where PNG produces\n\t\t// better looking images.\n\t\tvar buf bytes.Buffer\n\t\tif err := png.Encode(&buf, typedValue); err != nil {\n\t\t\treturn nil, nil, fmt.Errorf(\"encoding image: %v\", err)\n\t\t}\n\t\tbounds := typedValue.Bounds()\n\t\tdata[\"image/png\"] = buf.Bytes()\n\t\tdata[\"text/plain\"] = fmt.Sprintf(\"%dx%d image\", bounds.Dx(), bounds.Dy())\n\t\tmetadata[\"image/png\"] = map[string]interface{}{\n\t\t\t\"width\": bounds.Dx(),\n\t\t\t\"height\": bounds.Dy(),\n\t\t}\n\t\treturn data, metadata, nil\n\n\tcase []byte:\n\t\tcontentType = detectContentType(typedValue)\n\t\tstringValue = string(typedValue)\n\n\tcase string:\n\t\tcontentType = detectContentType([]byte(typedValue))\n\t\tstringValue = typedValue\n\n\tdefault:\n\t\tstringValue = fmt.Sprint(typedValue)\n\t\tvalue = stringValue\n\t\tcontentType = detectContentType([]byte(stringValue))\n\t}\n\n\tdata[\"text/plain\"] = stringValue\n\tif contentType != \"text/plain\" {\n\t\t// \"A plain text representation should always be\n\t\t// provided in the text/plain mime-type.\"\n\t\tdata[contentType] = value\n\t}\n\treturn data, metadata, nil\n}", "func (e *expression) printArray() string {\n\ta := \"\"\n\n\tfor i := 0; i < len(e.lenArray); i++ {\n\t\tvArray := string('i' + i)\n\t\ta += fmt.Sprintf(\"[%s]\", vArray)\n\t}\n\treturn a\n}", "func (Parser) Render(rawBytes []byte, urlPrefix string, metas map[string]string, isWiki bool) []byte {\n\treturn Render(rawBytes, urlPrefix, metas, isWiki)\n}", "func (s *SegmentRoot) Render() []byte {\n\tvar b bytes.Buffer\n\tb.Write(SetBackground(SegmentRootBackground))\n\tfmt.Fprint(&b, \" \")\n\tb.Write(s.Data)\n\tfmt.Fprint(&b, \" \")\n\treturn b.Bytes()\n}", "func (rf RendererFunc) Render(w io.Writer, v interface{}) error { return rf(w, v) }", "func (f Frame) Render() string {\n\tsb := strings.Builder{}\n\tfor _, row := range f {\n\t\tfor _, shade := range row {\n\t\t\tsb.WriteString(fmt.Sprintf(\"%d\", shade))\n\t\t}\n\t\tsb.WriteString(\"\\n\")\n\t}\n\tsb.WriteString(\"==============================\\n\")\n\n\treturn sb.String()\n}", "func Data(w http.ResponseWriter, r *http.Request, v []byte) {\n\trender.Data(w, r, v)\n}", "func (a *Array) Format(f fmt.State, c rune) {\n\tswitch c {\n\tcase 'z': // Private format specifier, supports Entity.Signature\n\t\tfmt.Fprintf(f, \"[%d]%z\", a.Size, a.ValueType)\n\tcase 'r': // Private format specifier, supports Type.Representation\n\t\tfmt.Fprintf(f, \"[%d]%r\", a.Size, a.ValueType)\n\tdefault:\n\t\tif a.Alias != \"\" {\n\t\t\tfmt.Fprint(f, a.Alias)\n\t\t} else {\n\t\t\tfmt.Fprintf(f, \"[%d]%v\", a.Size, a.ValueType)\n\t\t}\n\t}\n}", "func DrawArrays(mode Enum, first, count int) {\n\tgl.DrawArrays(uint32(mode), int32(first), int32(count))\n}", "func (vao *VAO) Render() {\n\tgl.BindVertexArray(vao.handle)\n\tif vao.indexBuffer != nil {\n\t\tgl.BindBuffer(gl.ELEMENT_ARRAY_BUFFER, vao.indexBuffer.GetHandle())\n\t\tgl.DrawElements(vao.mode, vao.indexBuffer.Len(), gl.UNSIGNED_SHORT, nil)\n\t\tgl.BindBuffer(gl.ELEMENT_ARRAY_BUFFER, 0)\n\t} else {\n\t\tgl.DrawArrays(vao.mode, 0, vao.vertexBuffers[0].Len())\n\t}\n\tgl.BindVertexArray(0)\n}", "func (c *cartridge) Render() {\n\tc.Cls()\n\tc.PrintAt(fmt.Sprintf(\"counter:%d\", c.counter), c.x, c.y)\n}", "func (r ConsoleTreeRenderer) RenderTree(root *ContainerNode, _ string) string {\n\n\tsb := strings.Builder{}\n\n\tfor _, node := range root.Items {\n\t\tfieldKey := node.Field().Name\n\t\tsb.WriteString(fieldKey)\n\t\tfor i := len(fieldKey); i <= root.MaxKeyLength; i++ {\n\t\t\tsb.WriteRune(' ')\n\t\t}\n\n\t\tvalueLen := 0\n\t\tpreLen := 16\n\n\t\tfield := node.Field()\n\n\t\tif r.WithValues {\n\t\t\tpreLen = 30\n\t\t\tvalueLen = r.writeNodeValue(&sb, node)\n\t\t} else {\n\t\t\t// Since no values was supplied, let's substitute the value with the type\n\t\t\ttypeName := field.Type.String()\n\n\t\t\t// If the value is an enum type, providing the name is a bit pointless\n\t\t\t// Instead, use a common string \"option\" to signify the type\n\t\t\tif field.EnumFormatter != nil {\n\t\t\t\ttypeName = \"option\"\n\t\t\t}\n\t\t\tvalueLen = len(typeName)\n\t\t\tsb.WriteString(color.CyanString(typeName))\n\t\t}\n\n\t\tsb.WriteString(strings.Repeat(\" \", util.Max(preLen-valueLen, 1)))\n\t\tsb.WriteString(ColorizeDesc(field.Description))\n\t\tsb.WriteString(strings.Repeat(\" \", util.Max(60-len(field.Description), 1)))\n\n\t\tif len(field.URLParts) > 0 && field.URLParts[0] != URLQuery {\n\t\t\tsb.WriteString(\" <URL: \")\n\t\t\tfor i, part := range field.URLParts {\n\t\t\t\tif i > 0 {\n\t\t\t\t\tsb.WriteString(\", \")\n\t\t\t\t}\n\t\t\t\tif part > URLPath {\n\t\t\t\t\tpart = URLPath\n\t\t\t\t}\n\t\t\t\tsb.WriteString(ColorizeEnum(part))\n\t\t\t}\n\t\t\tsb.WriteString(\">\")\n\t\t}\n\n\t\tif len(field.Template) > 0 {\n\t\t\tsb.WriteString(fmt.Sprintf(\" <Template: %s>\", ColorizeString(field.Template)))\n\t\t}\n\n\t\tif len(field.DefaultValue) > 0 {\n\t\t\tsb.WriteString(fmt.Sprintf(\" <Default: %s>\", ColorizeValue(field.DefaultValue, field.EnumFormatter != nil)))\n\t\t}\n\n\t\tif field.Required {\n\t\t\tsb.WriteString(fmt.Sprintf(\" <%s>\", ColorizeFalse(\"Required\")))\n\t\t}\n\n\t\tif len(field.Keys) > 1 {\n\t\t\tsb.WriteString(\" <Aliases: \")\n\t\t\tfor i, key := range field.Keys {\n\t\t\t\tif i == 0 {\n\t\t\t\t\t// Skip primary alias (as it's the same as the field name)\n\t\t\t\t\tcontinue\n\t\t\t\t}\n\t\t\t\tif i > 1 {\n\t\t\t\t\tsb.WriteString(\", \")\n\t\t\t\t}\n\t\t\t\tsb.WriteString(ColorizeString(key))\n\t\t\t}\n\t\t\tsb.WriteString(\">\")\n\t\t}\n\n\t\tif field.EnumFormatter != nil {\n\t\t\tsb.WriteString(ColorizeContainer(\" [\"))\n\t\t\tfor i, name := range field.EnumFormatter.Names() {\n\t\t\t\tif i != 0 {\n\t\t\t\t\tsb.WriteString(\", \")\n\t\t\t\t}\n\t\t\t\tsb.WriteString(ColorizeEnum(name))\n\t\t\t}\n\n\t\t\tsb.WriteString(ColorizeContainer(\"]\"))\n\t\t}\n\n\t\tsb.WriteRune('\\n')\n\t}\n\n\treturn sb.String()\n}", "func (r *Renderer) Render() {\n\tgl.DrawArrays(gl.TRIANGLES, 0, int32(len(r.RawRenderer)*4))\n}", "func (s *Square) Render() string {\n\treturn fmt.Sprintf(\"Square side %f\", s.Side)\n}", "func (renderer *SimpleMatrixRenderer) Render() {\n\trenderer.renderCharacter(\"\\n\")\n\n\tfor row := 0; row < renderer.Matrix.Height; row++ {\n\t\tfor col := 0; col < renderer.Matrix.Width; col++ {\n\t\t\tif !renderer.Matrix.IsFieldOccupied(row, col) {\n\t\t\t\trenderer.renderUnoccupiedField()\n\t\t\t} else {\n\t\t\t\trenderer.renderOccupiedFieldAtCurrentCursorPos(row, col)\n\t\t\t}\n\t\t}\n\n\t\trenderer.renderCharacter(\"\\n\")\n\t}\n\n\trenderer.renderCharacter(\"\\n\")\n}", "func (a *Array) String() string {\n\tbuf := new(bytes.Buffer)\n\tfor i := len(a.bits) - 1; i >= 0; i-- {\n\t\tbits := fmt.Sprintf(\"%16X\", a.bits[i])\n\t\tbits = strings.Replace(bits, \" \", \"0\", -1)\n\t\tfmt.Fprintf(buf, \"%s [%d-%d] \", bits, (i<<6)+63, i<<6)\n\t}\n\n\treturn buf.String()\n}", "func (h *HAProxyManager) render(ports []uint16) ([]byte, error) {\n\n\t// prepare the context\n\td := make([]templateContext, len(ports))\n\tfor i, port := range ports {\n\t\tif i == len(h.serviceAddrs) {\n\t\t\th.logger.Warnf(\"got port index %d, but only have %d service addrs. ports=%v serviceAddrs=%v\", i, len(h.serviceAddrs), ports, h.serviceAddrs)\n\t\t\tcontinue\n\t\t}\n\t\td[i] = templateContext{Port: port, Source: h.listenAddr, Dest: h.serviceAddrs[i]}\n\t}\n\n\t// render the template\n\tbuf := &bytes.Buffer{}\n\tif err := h.template.Execute(buf, d); err != nil {\n\t\treturn nil, err\n\t}\n\treturn buf.Bytes(), nil\n}", "func PrintArr(a []interface{}) {\n\tvar i int\n\tfor i < len(a) {\n\t\tfmt.Printf(\"%v\\t\", a[i])\n\t\ti++\n\t}\n\tfmt.Printf(\"\\n\")\n}", "func (a *Array) Literal() {}", "func (c *Client) ShowArrayPrism(ctx context.Context, path string, anyArray []interface{}, boolArray []bool, dateTimeArray []time.Time, intArray []int, numArray []float64, stringArray []string, uuidArray []uuid.UUID) (*http.Response, error) {\n\treq, err := c.NewShowArrayPrismRequest(ctx, path, anyArray, boolArray, dateTimeArray, intArray, numArray, stringArray, uuidArray)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\treturn c.Client.Do(ctx, req)\n}", "func (c *ConnectionSPI) Render(pixels []RGBPixel) {\r\n\tlogFields := log.Fields{\"package\": logPkg, \"conn\": \"SPI\", \"func\": \"RenderLEDs\"}\r\n\tlog.WithFields(logFields).Infof(\"Render %d LEDs\", len(pixels))\r\n\t// Fix for Raspberry Pi 3 Model B+ (5.15.84-v7+)\r\n\t// Data signal seems to be splitted sending less than 11 LEDS\r\n\tif len(pixels) < 11 {\r\n\t\tpixels = append(pixels, []RGBPixel{{}, {}, {}, {}, {}, {}, {}, {}, {}, {}}...)\r\n\t}\r\n\tvar translatedRGBs []uint8\r\n\tfor _, pixel := range pixels {\r\n\r\n\t\tcolorData := GetColorData(pixel, c.FixSPI)\r\n\t\tlog.WithFields(logFields).Tracef(\"%08b\", pixel)\r\n\r\n\t\tfor _, c := range colorData {\r\n\t\t\ttranslatedRGBs = append(translatedRGBs, c)\r\n\t\t}\r\n\t}\r\n\r\n\tc.transfer(translatedRGBs)\r\n}", "func (l *LogItems) Render(showTime bool, ll [][]byte) {\n\tindex := len(l.colors)\n\tfor i, item := range l.items {\n\t\tid := item.ID()\n\t\tcolor, ok := l.colors[id]\n\t\tif !ok {\n\t\t\tif index >= len(colorPalette) {\n\t\t\t\tindex = 0\n\t\t\t}\n\t\t\tcolor = colorPalette[index]\n\t\t\tl.colors[id] = color\n\t\t\tindex++\n\t\t}\n\t\tll[i] = item.Render(int(color-tcell.ColorValid), showTime)\n\t}\n}", "func Text(v interface{}) HTML {\n return HTML(\"\\n\" + html.EscapeString(fmt.Sprint(v)))\n}", "func (native *OpenGL) DrawElements(mode uint32, count int32, elementType uint32, indices uintptr) {\n\tgl.DrawElements(mode, count, elementType, unsafe.Pointer(indices)) // nolint: govet,gas\n}", "func Render(expr expreduceapi.Ex) (chart.Chart, error) {\n\tgraph := chart.Chart{\n\t\tWidth: 360,\n\t\tHeight: 220,\n\t\tXAxis: chart.XAxis{\n\t\t\tStyle: chart.Style{Show: true},\n\t\t},\n\t\tYAxis: chart.YAxis{\n\t\t\tStyle: chart.Style{Show: true},\n\t\t},\n\t}\n\n\tgraphics, ok := atoms.HeadAssertion(expr, \"System`Graphics\")\n\tif !ok {\n\t\treturn graph, fmt.Errorf(\"trying to render a non-Graphics[] expression: %v\", expr)\n\t}\n\n\tif graphics.Len() < 1 {\n\t\treturn graph, errors.New(\"the Graphics[] expression must have at least one argument\")\n\t}\n\n\tstyle := chart.Style{\n\t\tShow: true,\n\t\tStrokeColor: drawing.ColorBlack,\n\t}\n\terr := renderPrimitive(&graph, graphics.GetPart(1), &style)\n\tif err != nil {\n\t\treturn graph, errors.New(\"failed to render primitive\")\n\t}\n\n\treturn graph, nil\n}", "func main() {\n\t//composite literal - create different values of a type\n\t// x := type{values}\n\t//group together values OF THE SAME TYPE\n\tx := []int{4, 5, 7, 8, 42}\n\n\tfmt.Println(x)\n\tfmt.Println(x[0]) //query by index position\n\tfmt.Println(x[1])\n\tfmt.Println(x[2])\n\tfmt.Println(x[3])\n\tfmt.Println(x[4])\n\tfmt.Println(cap(x))\n\n\t//for index and value in the range of x print\n\tfor i, v := range x {\n\t\tfmt.Println(i, v)\n\t}\n}", "func (obj *Device) DrawIndexedPrimitive(\n\ttyp PRIMITIVETYPE,\n\tbaseVertexIndex int,\n\tminIndex uint,\n\tnumVertices uint,\n\tstartIndex uint,\n\tprimitiveCount uint,\n) Error {\n\tret, _, _ := syscall.Syscall9(\n\t\tobj.vtbl.DrawIndexedPrimitive,\n\t\t7,\n\t\tuintptr(unsafe.Pointer(obj)),\n\t\tuintptr(typ),\n\t\tuintptr(baseVertexIndex),\n\t\tuintptr(minIndex),\n\t\tuintptr(numVertices),\n\t\tuintptr(startIndex),\n\t\tuintptr(primitiveCount),\n\t\t0,\n\t\t0,\n\t)\n\treturn toErr(ret)\n}", "func (d *Device) Render() error {\n\tbuf := new(bytes.Buffer)\n\n\tfor _, chain := range d.LEDs {\n\t\tfor _, col := range chain {\n\t\t\tbuf.Write([]byte{col.R, col.G, col.B})\n\t\t}\n\t}\n\n\t_, err := Conn.WriteToUDP(buf.Bytes(), d.Addr)\n\treturn err\n}", "func (vl *ValueArray) String() string {\n\treturn fmt.Sprintf(\"%v\", vl.array)\n}", "func encode(buf *bytes.Buffer, v reflect.Value) error {\n\tswitch v.Kind() {\n\tcase reflect.Invalid: // ignore\n\n\tcase reflect.Float32, reflect.Float64:\n\t\tfmt.Fprintf(buf, \"%f\", v.Float())\n\n\tcase reflect.Complex128, reflect.Complex64:\n\t\tc := v.Complex()\n\t\tfmt.Fprintf(buf, \"#C(%f %f)\", real(c), imag(c))\n\n\tcase reflect.Bool:\n\t\tif v.Bool() {\n\t\t\tfmt.Fprintf(buf, \"t\")\n\t\t}\n\n\tcase reflect.Interface:\n\t\t// type output\n\t\tt := v.Elem().Type()\n\n\t\tleftBuffer := new(bytes.Buffer)\n\t\trightBuffer := new(bytes.Buffer)\n\n\t\tif t.Name() == \"\" { // 名前がつけられてないtypeはそのまま表示する\n\t\t\tfmt.Fprintf(leftBuffer, \"%q\", t)\n\t\t} else {\n\t\t\tfmt.Fprintf(leftBuffer, \"\\\"%s.%s\\\" \", t.PkgPath(), t.Name()) //一意ではないとはこういうことか?\n\t\t}\n\n\t\t// value output\n\t\tif err := encode(rightBuffer, v.Elem()); err != nil {\n\t\t\treturn err\n\t\t}\n\n\t\tif len(rightBuffer.Bytes()) != 0 {\n\t\t\tbuf.WriteByte('(')\n\t\t\tbuf.Write(leftBuffer.Bytes())\n\t\t\tbuf.WriteByte(' ')\n\t\t\tbuf.Write(rightBuffer.Bytes())\n\t\t\tbuf.WriteByte(')')\n\t\t}\n\n\tcase reflect.Int, reflect.Int8, reflect.Int16,\n\t\treflect.Int32, reflect.Int64:\n\t\tfmt.Fprintf(buf, \"%d\", v.Int())\n\n\tcase reflect.Uint, reflect.Uint8, reflect.Uint16,\n\t\treflect.Uint32, reflect.Uint64, reflect.Uintptr:\n\t\tfmt.Fprintf(buf, \"%d\", v.Uint())\n\n\tcase reflect.String:\n\t\tfmt.Fprintf(buf, \"%q\", v.String())\n\n\tcase reflect.Ptr:\n\t\treturn encode(buf, v.Elem())\n\n\tcase reflect.Array, reflect.Slice: // (value ...)\n\n\t\tcontent := new(bytes.Buffer)\n\n\t\tisFirst := true\n\n\t\tfor i := 0; i < v.Len(); i++ {\n\t\t\tif isFirst {\n\t\t\t\tisFirst = false\n\t\t\t\tcontent.WriteByte(' ')\n\t\t\t}\n\t\t\tif err := encode(content, v.Index(i)); err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\t\t}\n\n\t\tif len(content.Bytes()) != 0 {\n\t\t\tbuf.WriteByte('(')\n\t\t\tbuf.Write(content.Bytes())\n\t\t\tbuf.WriteByte(')')\n\t\t}\n\n\tcase reflect.Struct: // ((name value) ...)\n\n\t\tcontent := new(bytes.Buffer)\n\n\t\tisFirst := true\n\n\t\tfor i := 0; i < v.NumField(); i++ {\n\t\t\trightBuffer := new(bytes.Buffer)\n\t\t\tif err := encode(rightBuffer, v.Field(i)); err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\n\t\t\tif len(rightBuffer.Bytes()) != 0 {\n\t\t\t\tif isFirst {\n\t\t\t\t\tcontent.WriteByte(' ')\n\t\t\t\t\tisFirst = false\n\t\t\t\t}\n\t\t\t\tcontent.WriteByte('(')\n\t\t\t\tfmt.Fprintf(content, \"%s\", v.Type().Field(i).Name)\n\t\t\t\tcontent.WriteByte(' ')\n\t\t\t\tcontent.Write(rightBuffer.Bytes())\n\t\t\t\tcontent.WriteByte(')')\n\t\t\t}\n\t\t}\n\n\t\tif len(content.Bytes()) != 0 {\n\t\t\tbuf.WriteByte('(')\n\t\t\tbuf.Write(content.Bytes())\n\t\t\tbuf.WriteByte(')')\n\t\t}\n\n\tcase reflect.Map: // ((key value) ...)\n\t\tisFirst := true\n\t\tcontent := new(bytes.Buffer)\n\n\t\tfor _, key := range v.MapKeys() {\n\t\t\tif isFirst {\n\t\t\t\tcontent.WriteByte(' ')\n\t\t\t\tisFirst = false\n\t\t\t}\n\n\t\t\tleftBuffer := new(bytes.Buffer)\n\t\t\trightBuffer := new(bytes.Buffer)\n\n\t\t\tif err := encode(leftBuffer, key); err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\t\t\tif err := encode(rightBuffer, v.MapIndex(key)); err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\n\t\t\tif len(rightBuffer.Bytes()) != 0 {\n\t\t\t\tcontent.WriteByte('(')\n\t\t\t\tcontent.Write(leftBuffer.Bytes())\n\t\t\t\tcontent.WriteByte(' ')\n\t\t\t\tcontent.Write(rightBuffer.Bytes())\n\t\t\t\tcontent.WriteByte(')')\n\t\t\t}\n\t\t}\n\n\t\tif len(content.Bytes()) != 0 {\n\t\t\tbuf.WriteByte('(')\n\t\t\tbuf.Write(content.Bytes())\n\t\t\tbuf.WriteByte(')')\n\t\t}\n\n\tdefault: // float, complex, bool, chan, func, interface\n\t\treturn fmt.Errorf(\"unsupported type: %s\", v.Type())\n\t}\n\treturn nil\n}", "func (a *ArrayInt) String() string {\n\tx := a.a\n\tformattedInts := make([]string, len(x))\n\tfor i, v := range x {\n\t\tformattedInts[i] = strconv.Itoa(v)\n\t}\n\treturn strings.Join(formattedInts, \",\")\n}", "func ex1() {\n\tx := [5]int{1, 2, 4, 8, 16}\n\tfor i, v := range x {\n\t\tfmt.Println(i, v)\n\t}\n\tfmt.Printf(\"%T\\n\", x)\n\n}", "func (t *tag) render() string {\n tagType := t.GetType()\n tagFormat := tagsFormat[tagType]\n\n switch t.GetType() {\n case TYPE_OPEN:\n return fmt.Sprintf(tagFormat, t.GetName(), getAttrsToString(t))\n case TYPE_CLOSE:\n return fmt.Sprintf(tagFormat, t.GetName())\n case TYPE_OPEN_CLOSE:\n return fmt.Sprintf(tagFormat, t.GetName(), getAttrsToString(t), t.GetVal(), t.GetName())\n case TYPE_SELF_CLOSED_STRICT:\n if t.GetVal() != \"\" {\n t.SetAttr(\"value\", t.GetVal())\n }\n return fmt.Sprintf(tagFormat, t.GetName(), getAttrsToString(t))\n default:\n return t.GetName()\n }\n}", "func (self *Tween) GenerateData() []interface{}{\n\tarray00 := self.Object.Call(\"generateData\")\n\tlength00 := array00.Length()\n\tout00 := make([]interface{}, length00, length00)\n\tfor i00 := 0; i00 < length00; i00++ {\n\t\tout00[i00] = array00.Index(i00)\n\t}\n\treturn out00\n}", "func (h Hand) Render() string {\n\tbuffer := bytes.Buffer{}\n\tlast := len(h.Cards) - 1\n\tfor i, card := range h.Cards {\n\t\tbuffer.WriteString(card.Render())\n\t\tif i != last {\n\t\t\tbuffer.WriteString(\", \")\n\t\t}\n\t}\n\tbuffer.WriteString(fmt.Sprintf(\n\t\t\" (%s)\", scoresRenderer{h.Scores()}.Render(),\n\t))\n\treturn strings.Trim(buffer.String(), \" \")\n}", "func RenderList(w http.ResponseWriter, r *http.Request, l []Renderer) error {\n\tfor _, v := range l {\n\t\tif err := renderer(w, r, v); err != nil {\n\t\t\treturn err\n\t\t}\n\t}\n\tRespond(w, r, l)\n\treturn nil\n}", "func (me TStrokeDashArrayValueType) String() string { return xsdt.String(me).String() }", "func main() {\n\ts := []int{5, 3, 2, 6, 1, 6, 7, 10, 49, 100}\n\tfor i, v := range s {\n\t\tfmt.Println(i, v)\n\t}\n\tfmt.Printf(\"%T\\n\", s)\n}", "func (a *Array) Format() error {\n\t// todo\n\treturn nil\n}", "func (va ValueArray) String() string {\n\treturn fmt.Sprintf(\"%v\", []Value(va))\n}", "func (ctx *RecordContext) Render(v interface{}) error {\n\tctx.Renders = append(ctx.Renders, v)\n\treturn ctx.Context.Render(v)\n}", "func (s *Slice) Format(f fmt.State, c rune) {\n\tswitch c {\n\tcase 'z': // Private format specifier, supports Entity.Signature\n\t\tfmt.Fprintf(f, \"[]%z\", s.ValueType)\n\tcase 'r': // Private format specifier, supports Type.Representation\n\t\tfmt.Fprintf(f, \"[]%r\", s.ValueType)\n\tdefault:\n\t\tif s.Alias != \"\" {\n\t\t\tfmt.Fprint(f, s.Alias)\n\t\t} else {\n\t\t\tfmt.Fprintf(f, \"[]%v\", s.ValueType)\n\t\t}\n\t}\n}", "func PrintDataSlice(data interface{}) {\n\td := reflect.ValueOf(data)\n\n\tfor i := 0; i < d.Len(); i++ {\n\t\tdataItem := d.Index(i)\n\t\ttypeOfT := dataItem.Type()\n\n\t\tfor j := 0; j < dataItem.NumField(); j++ {\n\t\t\tf := dataItem.Field(j)\n\t\t\tfmt.Printf(\"%s: %v\\n\", typeOfT.Field(j).Name, f.Interface())\n\t\t}\n\t\tfmt.Printf(\"\\n\")\n\t}\n}", "func DrawElements(mode Enum, count int, ty Enum, offset int) {\n\tgl.DrawElements(uint32(mode), int32(count), uint32(ty), gl.PtrOffset(offset))\n}", "func (isf intSliceFunctorImpl) String() string {\n\treturn fmt.Sprintf(\"%#v\", isf.ints)\n}", "func (s Style) Render(raw string) string {\n\tt := NewAnstring(raw)\n\tfor i := len(s) - 1; i >= 0; i-- {\n\t\tt.meld(s[i])\n\t}\n\treturn string(t)\n}", "func (l *LogItem) Render(c int, showTime bool) []byte {\n\tbb := make([]byte, 0, 200)\n\tif showTime {\n\t\tt := l.Timestamp\n\t\tfor i := len(t); i < 30; i++ {\n\t\t\tt += \" \"\n\t\t}\n\t\tbb = append(bb, color.ANSIColorize(t, 106)...)\n\t\tbb = append(bb, ' ')\n\t}\n\n\tif l.Pod != \"\" {\n\t\tbb = append(bb, color.ANSIColorize(l.Pod, c)...)\n\t\tbb = append(bb, ':')\n\t}\n\tif !l.SingleContainer && l.Container != \"\" {\n\t\tbb = append(bb, color.ANSIColorize(l.Container, c)...)\n\t\tbb = append(bb, ' ')\n\t}\n\n\treturn append(bb, escPattern.ReplaceAll(l.Bytes, matcher)...)\n}", "func renderInteger(f float64) string {\n\tif f > math.Nextafter(float64(math.MaxInt64), 0) {\n\t\treturn fmt.Sprintf(\"%d\", int64(math.MaxInt64))\n\t}\n\tif f < math.Nextafter(float64(math.MinInt64), 0) {\n\t\treturn fmt.Sprintf(\"%d\", int64(math.MinInt64))\n\t}\n\treturn fmt.Sprintf(\"%d\", int64(f))\n}", "func (a PixelSubArray) Print() {\n\tfor y := len(a.bytes) - 1; y >= 0; y-- {\n\t\tfor x := 0; x < len(a.bytes[0]); x++ {\n\t\t\tfmt.Printf(\"%b%b%b%b%b%b%b%b\",\n\t\t\t\t(a.bytes[y][x])&1,\n\t\t\t\t(a.bytes[y][x]>>1)&1,\n\t\t\t\t(a.bytes[y][x]>>2)&1,\n\t\t\t\t(a.bytes[y][x]>>3)&1,\n\t\t\t\t(a.bytes[y][x]>>4)&1,\n\t\t\t\t(a.bytes[y][x]>>5)&1,\n\t\t\t\t(a.bytes[y][x]>>6)&1,\n\t\t\t\t(a.bytes[y][x]>>7)&1)\n\t\t}\n\n\t\tfmt.Printf(\"\\n\")\n\t}\n}", "func (l *Label) data() []byte {\n Assert(nilLabel, l != nil)\n \n bytes, _ := util.Uint64ToBytes(l.value)\n refs, _ := util.Uint64ToBytes(l.refs)\n left, _ := util.Uint16ToBytes(l.l)\n right, _ := util.Uint16ToBytes(l.r)\n \n bytes = append(bytes, append(refs, append(left, append(right, l.h)...)...)...) // TODO ??\n return bytes\n \n}", "func serialize(data interface{}) interface{} {\n\tvar buffer bytes.Buffer\n\tswitch reflect.TypeOf(data).Kind() {\n\tcase reflect.Slice:\n\t\ts := reflect.ValueOf(data)\n\t\tfor i := 0; i < s.Len(); i++ {\n\t\t\tserial := serialize(s.Index(i).Interface())\n\t\t\tif reflect.TypeOf(serial).Kind() == reflect.Float64 {\n\t\t\t\tserial = strconv.Itoa(int(serial.(float64)))\n\t\t\t}\n\t\t\tbuffer.WriteString(strconv.Itoa(i))\n\t\t\tbuffer.WriteString(serial.(string))\n\t\t}\n\t\treturn buffer.String()\n\tcase reflect.Map:\n\t\ts := reflect.ValueOf(data)\n\t\tkeys := s.MapKeys()\n\t\t//ksort\n\t\tvar sortedKeys []string\n\t\tfor _, key := range keys {\n\t\t\tsortedKeys = append(sortedKeys, key.Interface().(string))\n\t\t}\n\t\tsort.Strings(sortedKeys)\n\t\tfor _, key := range sortedKeys {\n\t\t\tserial := serialize(s.MapIndex(reflect.ValueOf(key)).Interface())\n\t\t\tif reflect.TypeOf(serial).Kind() == reflect.Float64 {\n\t\t\t\tserial = strconv.Itoa(int(serial.(float64)))\n\t\t\t}\n\t\t\tbuffer.WriteString(key)\n\t\t\tbuffer.WriteString(serial.(string))\n\t\t}\n\t\treturn buffer.String()\n\t}\n\n\treturn data\n}", "func (r renderer) Table(out *bytes.Buffer, header []byte, body []byte, columnData []int) {}", "func (self *Graphics) Data() interface{}{\n return self.Object.Get(\"data\")\n}", "func (level *Level) Render() string {\n\tresult := \"\"\n\n\tfor y := 0; y < level.size.Width; y++ {\n\t\tfor x := 0; x < level.size.Width; x++ {\n\t\t\tif level.snake.CheckHitbox(Position{x, y}) {\n\t\t\t\tresult += \"\\033[42m \\033[0m\"\n\t\t\t} else if level.apple.position.Equals(x, y) {\n\t\t\t\tresult += \"\\033[41m \\033[0m\"\n\t\t\t} else {\n\t\t\t\tresult += \"\\033[97m \\033[0m\"\n\t\t\t}\n\t\t}\n\n\t\tif y < level.size.Height-1 {\n\t\t\tresult += \"\\n\"\n\t\t}\n\t}\n\n\treturn result\n}", "func printTable(data []string, color bool) {\n\tvar listType string\n\n\ttable := tablewriter.NewWriter(os.Stdout)\n\n\tswitch color {\n\tcase true:\n\t\tlistType = \"White\"\n\tcase false:\n\t\tlistType = \"Black\"\n\t}\n\n\ttable.SetHeader([]string{\"#\", \"B/W\", \"CIDR\"})\n\n\tfor i, v := range data {\n\t\tl := make([]string, 0)\n\t\tl = append(l, strconv.Itoa(i+offset))\n\t\tl = append(l, listType)\n\t\tl = append(l, v)\n\t\ttable.Append(l)\n\t}\n\n\ttable.Render()\n}", "func Render(s api.Session, renderAs RenderName, value dgo.Value, out io.Writer) {\n\t// Convert value to rich data format without references\n\tdedupStream := func(value dgo.Value, consumer streamer.Consumer) {\n\t\topts := streamer.DefaultOptions()\n\t\topts.DedupLevel = streamer.NoDedup\n\t\tser := streamer.New(s.AliasMap(), opts)\n\t\tser.Stream(value, consumer)\n\t}\n\n\tswitch renderAs {\n\tcase JSON:\n\t\tif value.Equals(vf.Nil) {\n\t\t\tutil.WriteString(out, \"null\\n\")\n\t\t} else {\n\t\t\tdedupStream(value, streamer.JSON(out))\n\t\t\tutil.WriteByte(out, '\\n')\n\t\t}\n\n\tcase YAML:\n\t\tif value.Equals(vf.Nil) {\n\t\t\tutil.WriteString(out, \"\\n\")\n\t\t} else {\n\t\t\tdc := streamer.DataCollector()\n\t\t\tdedupStream(value, dc)\n\t\t\tbs, err := yaml.Marshal(dc.Value())\n\t\t\tif err != nil {\n\t\t\t\tpanic(err)\n\t\t\t}\n\t\t\tutil.WriteString(out, string(bs))\n\t\t}\n\tcase Binary:\n\t\tbi := vf.New(typ.Binary, value).(dgo.Binary)\n\t\t_, err := out.Write(bi.GoBytes())\n\t\tif err != nil {\n\t\t\tpanic(err)\n\t\t}\n\tcase Text:\n\t\tutil.Fprintln(out, value)\n\tdefault:\n\t\tpanic(fmt.Errorf(`unknown rendering '%s'`, renderAs))\n\t}\n}", "func (s *Ipset) Render(rType RenderType) string {\n\tvar result string\n\n\tswitch rType {\n\tcase RenderFlush:\n\t\tif len(s.Sets) == 0 {\n\t\t\treturn \"flush\\n\"\n\t\t}\n\tcase RenderDestroy:\n\t\tif len(s.Sets) == 0 {\n\t\t\treturn \"destroy\\n\"\n\t\t}\n\n\t// RenderSwap will fail when Sets < 2,\n\t// it's a duty of a caller to ensure\n\t// correctness.\n\tcase RenderSwap:\n\t\treturn fmt.Sprintf(\"swap %s %s\\n\", s.Sets[0].Name, s.Sets[1].Name)\n\n\t// RenderRename will fail when Sets < 2,\n\t// it's a duty of a caller to ensure\n\t// correctness.\n\tcase RenderRename:\n\t\treturn fmt.Sprintf(\"rename %s %s\\n\", s.Sets[0].Name, s.Sets[1].Name)\n\t}\n\n\tfor _, set := range s.Sets {\n\t\tresult += set.Render(rType)\n\t}\n\n\treturn result\n}", "func (b *Board) Render() {\n\tfmt.Println() // to breathe\n\tfmt.Println(\" | a | b | c | d | e | f | g | h |\")\n\tfmt.Println(\" - +-----+-----+-----+-----+-----+-----+-----+-----+\")\n\n\tfor i := 0; i < 8; i++ {\n\t\tfmt.Printf(\" %d |\", i)\n\t\tfor j := 0; j < 8; j++ {\n\t\t\tcell := b[i][j]\n\t\t\tfmt.Printf(\" %s |\", cell)\n\t\t}\n\t\tfmt.Println()\n\t}\n\n\tfmt.Println(\" - +-----+-----+-----+-----+-----+-----+-----+-----+\")\n\tfmt.Println() // breathe again\n}", "func (val *uint16ArrayValue) String() string {\n\tvar buffer strings.Builder\n\tfor _, v := range *val {\n\t\tif buffer.Len() != 0 {\n\t\t\tbuffer.WriteString(\", \")\n\t\t}\n\t\tfmt.Fprintf(&buffer, \"%v\", v)\n\t}\n\treturn buffer.String()\n}", "func (ctx *APIContext) Render(status int, title string, obj interface{}) {\n\tctx.JSON(status, map[string]interface{}{\n\t\t\"message\": title,\n\t\t\"status\": status,\n\t\t\"resource\": obj,\n\t})\n}", "func (gl *WebGL) DrawElements(mode GLEnum, count int, valueType GLEnum, offset int) {\n\tgl.context.Call(\"drawElements\", mode, count, valueType, offset)\n}", "func WriteASCII(w io.Writer, t []Triangle) error {\n\tvar err error\n\n\tprintf := func(format string, a ...interface{}) {\n\t\tif err != nil {\n\t\t\treturn\n\t\t}\n\t\t_, err = fmt.Fprintf(w, format, a...)\n\t}\n\tprintf(\"solid object\\n\")\n\tfor _, tt := range t {\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tprintf(\"facet normal %f %f %f\\n\", tt.N[0], tt.N[1], tt.N[2])\n\t\tprintf(\" outer loop\\n\")\n\t\tfor _, v := range tt.V {\n\t\t\tprintf(\" vertex %f %f %f\\n\", v[0], v[1], v[2])\n\t\t}\n\t\tprintf(\" endloop\\n\")\n\t\tprintf(\"endfacet\\n\")\n\t}\n\tprintf(\"endsolid object\\n\")\n\treturn nil\n}", "func WriteArray(lst []interface{}, buf *goetty.ByteBuf) {\r\n\tbuf.WriteByte('*')\r\n\tif len(lst) == 0 {\r\n\t\tbuf.Write(NullArray)\r\n\t\tbuf.Write(Delims)\r\n\t} else {\r\n\t\tbuf.Write(goetty.StringToSlice(strconv.Itoa(len(lst))))\r\n\t\tbuf.Write(Delims)\r\n\r\n\t\tfor i := 0; i < len(lst); i++ {\r\n\t\t\tswitch v := lst[i].(type) {\r\n\t\t\tcase []interface{}:\r\n\t\t\t\tWriteArray(v, buf)\r\n\t\t\tcase [][]byte:\r\n\t\t\t\tWriteSliceArray(v, buf)\r\n\t\t\tcase []byte:\r\n\t\t\t\tWriteBulk(v, buf)\r\n\t\t\tcase nil:\r\n\t\t\t\tWriteBulk(nil, buf)\r\n\t\t\tcase int64:\r\n\t\t\t\tWriteInteger(v, buf)\r\n\t\t\tcase string:\r\n\t\t\t\tWriteStatus(goetty.StringToSlice(v), buf)\r\n\t\t\tcase error:\r\n\t\t\t\tWriteError(goetty.StringToSlice(v.Error()), buf)\r\n\t\t\tdefault:\r\n\t\t\t\tpanic(fmt.Sprintf(\"invalid array type %T %v\", lst[i], v))\r\n\t\t\t}\r\n\t\t}\r\n\t}\r\n}", "func Render(typ Type, input any, urlPrefix string, metas map[string]string) []byte {\n\tvar rawBytes []byte\n\tswitch v := input.(type) {\n\tcase []byte:\n\t\trawBytes = v\n\tcase string:\n\t\trawBytes = []byte(v)\n\tdefault:\n\t\tpanic(fmt.Sprintf(\"unrecognized input content type: %T\", input))\n\t}\n\n\turlPrefix = strings.TrimRight(strings.ReplaceAll(urlPrefix, \" \", \"%20\"), \"/\")\n\tvar rawHTML []byte\n\tswitch typ {\n\tcase TypeMarkdown:\n\t\trawHTML = RawMarkdown(rawBytes, urlPrefix)\n\tcase TypeOrgMode:\n\t\trawHTML = RawOrgMode(rawBytes, urlPrefix)\n\tdefault:\n\t\treturn rawBytes // Do nothing if syntax type is not recognized\n\t}\n\n\trawHTML = postProcessHTML(rawHTML, urlPrefix, metas)\n\treturn SanitizeBytes(rawHTML)\n}", "func (d *Data) Render() error {\n\n\tvar err error\n\n\t// Read the CA certificate:\n\tif err = d.caCert(); err != nil {\n\t\treturn err\n\t}\n\n\t// Forge the Zookeeper URL:\n\td.forgeZookeeperURL()\n\n\t// REX-Ray configuration snippet:\n\td.rexraySnippet()\n\n\t// Role-based parsing:\n\tt := template.New(\"udata\")\n\n\tswitch d.Role {\n\tcase \"master\":\n\t\tt, err = t.Parse(templMaster)\n\tcase \"node\":\n\t\tt, err = t.Parse(templNode)\n\tcase \"edge\":\n\t\tt, err = t.Parse(templEdge)\n\t}\n\n\tif err != nil {\n\t\tlog.WithField(\"cmd\", \"udata\").Error(err)\n\t\treturn err\n\t}\n\n\t// Apply parsed template to data object:\n\tif d.GzipUdata {\n\t\tlog.WithFields(log.Fields{\"cmd\": \"udata\", \"id\": d.Role + \"-\" + d.HostID}).\n\t\t\tInfo(\"- Rendering gzipped cloud-config template\")\n\t\tw := gzip.NewWriter(os.Stdout)\n\t\tdefer w.Close()\n\t\tif err = t.Execute(w, d); err != nil {\n\t\t\tlog.WithField(\"cmd\", \"udata\").Error(err)\n\t\t\treturn err\n\t\t}\n\t} else {\n\t\tlog.WithField(\"cmd\", \"udata\").Info(\"- Rendering plain text cloud-config template\")\n\t\tif err = t.Execute(os.Stdout, d); err != nil {\n\t\t\tlog.WithField(\"cmd\", \"udata\").Error(err)\n\t\t\treturn err\n\t\t}\n\t}\n\n\t// Return on success:\n\treturn nil\n}", "func (p *Pprint) pprint(data interface{}) {\n\t// temp := reflect.TypeOf(data).Kind()\n\t// p.test[\"array\"] = reflect.Map\n\t// fmt.Println(p.test)\n\t// if reflect.Array == temp {\n\t// \tfmt.Println(\"scussu\")\n\t// }\n\t// p.test[temp.String()] = 0\n\tp.Typemode = reflect.TypeOf(data).Kind()\n\tif p.Typemode == reflect.Map {\n\t\tp.PrintMaps(data)\n\t} else if p.Typemode == reflect.Slice {\n\t\tp.PrintArrays(data)\n\t} else if p.Typemode == reflect.Array {\n\t\tp.PrintArrays(data)\n\t} else {\n\t\tfmt.Println(data)\n\t}\n}", "func Render(files [][]byte, maxIt uint, debug bool) (\n\t[]byte, error,\n) {\n\tinfl, debugParse, err := parseFiles(files)\n\tif err != nil {\n\t\tif debug {\n\t\t\twriteDebug(\"parsing\", debugParse)\n\t\t}\n\t\treturn []byte{}, err\n\t}\n\tres, debugRender, err := renderTmpl(infl, maxIt)\n\tif err != nil {\n\t\tif debug {\n\t\t\twriteDebug(\"render\", debugRender)\n\t\t}\n\t\treturn []byte{}, err\n\t}\n\treturn res, nil\n}", "func DrawElements(mode uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n\tsyscall.Syscall6(gpDrawElements, 4, uintptr(mode), uintptr(count), uintptr(xtype), uintptr(indices), 0, 0)\n}", "func (Empty) Render(width, height int) *term.Buffer {\n\treturn term.NewBufferBuilder(width).Buffer()\n}", "func GenerateShapes() {\r\n\t// Square\r\n\tShapes[0].vertices = []gl.GLfloat{-1, -1, 1, -1, -1, 1, 1, 1}\r\n\tShapes[0].elements = []gl.GLushort{0, 1, 2, 2, 3, 1}\r\n\r\n\t// ___|\r\n\tShapes[1].vertices = []gl.GLfloat{-2, 0, -2, -1, 2, -1, 2, 0, 2, 1, 1, 1, 1, 0}\r\n\tShapes[1].elements = []gl.GLushort{0, 1, 2, 2, 3, 0, 3, 4, 5, 5, 6, 3}\r\n\r\n\t// _|_\r\n\tShapes[2].vertices = []gl.GLfloat{-1.5, 0, -0.5, 0, -0.5, 1, 0.5, 1, 0.5, 0, 1.5, 0, 1.5, -1, -1.5, -1}\r\n\tShapes[2].elements = []gl.GLushort{1, 2, 3, 3, 4, 1, 0, 7, 6, 6, 0, 5}\r\n\r\n\t// Snake\r\n\tShapes[3].vertices = []gl.GLfloat{-1.5, -1, -1.5, 0, -0.5, 0, -0.5, 1, 1.5, 1, 1.5, 0, 0.5, 0, 0.5, -1}\r\n\tShapes[3].elements = []gl.GLushort{0, 1, 6, 6, 7, 0, 2, 3, 4, 4, 5, 2}\r\n\r\n\t// Now fill out the rest automatically.\r\n\t// FIXME why doesn't using _, shape in this loop work ?\r\n\tfor i := range Shapes {\r\n\t\tShapes[i].vao = gl.GenVertexArray()\r\n\t\tShapes[i].vao.Bind()\r\n\t\tShapes[i].vbo = gl.GenBuffer()\r\n\t\tShapes[i].vbo.Bind(gl.ARRAY_BUFFER)\r\n\t\tgl.BufferData(gl.ARRAY_BUFFER, len(Shapes[i].vertices)*4, Shapes[i].vertices, gl.STATIC_DRAW)\r\n\t\tShapes[i].elementBuffer = gl.GenBuffer()\r\n\t\tShapes[i].elementBuffer.Bind(gl.ELEMENT_ARRAY_BUFFER)\r\n\t\tgl.BufferData(gl.ELEMENT_ARRAY_BUFFER, len(Shapes[i].elements)*2, Shapes[i].elements, gl.STATIC_DRAW)\r\n\t\tShapes[i].numElements = len(Shapes[i].elements)\r\n\r\n\t\tvertexAttribArray := shaderProgram.GetAttribLocation(\"position\")\r\n\t\tvertexAttribArray.AttribPointer(2, gl.FLOAT, false, 0, uintptr(0))\r\n\t\tvertexAttribArray.EnableArray()\r\n\t}\r\n}", "func Interpret(data []byte, offset int) []byte {\n\tb:=make([]byte, len(data) * 2)\n\n\tfor i:=0; i<len(data); i++ {\n\t\tb[offset + i * 2] = hex_ascii[ (data[i] & 0XF0) >> 4]\n\t\tb[offset + i * 2 + 1] = hex_ascii[data[i] & 0x0F]\n\t}\n\treturn b\n}", "func DrawElements(mode uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n C.glowDrawElements(gpDrawElements, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices)\n}", "func (tpl *Template) RenderBytes(ctx ...interface{}) ([]byte, error) {\n\tvar buf bytes.Buffer\n\terr := tpl.Run(&buf, ctx...)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\treturn buf.Bytes(), nil\n}", "func TestRender(t *testing.T) {\n\ttestCases := []struct {\n\t\tname string\n\t\tp P\n\t\twantList []string\n\t\twantCode int\n\t}{\n\t\t{\n\t\t\t\"server error\",\n\t\t\tServerError,\n\t\t\t[]string{\"500\"},\n\t\t\t500,\n\t\t}, {\n\t\t\t\"renders the type correctly\",\n\t\t\tP{Type: \"foo\", Status: 500},\n\t\t\t[]string{\"foo\"},\n\t\t\t500,\n\t\t}, {\n\t\t\t\"renders the status correctly\",\n\t\t\tP{Status: 201},\n\t\t\t[]string{\"201\"},\n\t\t\t201,\n\t\t}, {\n\t\t\t\"renders the extras correctly\",\n\t\t\tP{Extras: map[string]interface{}{\"hello\": \"stellar\"}, Status: 500},\n\t\t\t[]string{\"hello\", \"stellar\"},\n\t\t\t500,\n\t\t},\n\t}\n\n\tfor _, kase := range testCases {\n\t\tt.Run(kase.name, func(t *testing.T) {\n\t\t\tw := testRender(context.Background(), kase.p)\n\t\t\tfor _, wantItem := range kase.wantList {\n\t\t\t\tassert.True(t, strings.Contains(w.Body.String(), wantItem), w.Body.String())\n\t\t\t\tassert.Equal(t, kase.wantCode, w.Code)\n\t\t\t}\n\t\t})\n\t}\n}", "func encodeUxArray(obj *UxArray) ([]byte, error) {\n\tn := encodeSizeUxArray(obj)\n\tbuf := make([]byte, n)\n\n\tif err := encodeUxArrayToBuffer(buf, obj); err != nil {\n\t\treturn nil, err\n\t}\n\n\treturn buf, nil\n}", "func (obj *Device) DrawIndexedPrimitiveUP(\n\ttyp PRIMITIVETYPE,\n\tminVertexIndex uint,\n\tnumVertices uint,\n\tprimitiveCount uint,\n\tindexData uintptr,\n\tindexDataFormat FORMAT,\n\tvertexStreamZeroData uintptr,\n\tvertexStreamZeroStride uint,\n) Error {\n\tret, _, _ := syscall.Syscall9(\n\t\tobj.vtbl.DrawIndexedPrimitiveUP,\n\t\t9,\n\t\tuintptr(unsafe.Pointer(obj)),\n\t\tuintptr(typ),\n\t\tuintptr(minVertexIndex),\n\t\tuintptr(numVertices),\n\t\tuintptr(primitiveCount),\n\t\tindexData,\n\t\tuintptr(indexDataFormat),\n\t\tvertexStreamZeroData,\n\t\tuintptr(vertexStreamZeroStride),\n\t)\n\treturn toErr(ret)\n}", "func (c *Plain) RenderIndexContent(content interface{}) (string, error) {\n\treturn content.(string), nil\n}", "func (r *ExcelReport) Render(ctx map[string]interface{}) {\n\tmergedCells, _ := r.f.GetMergeCells(r.sheetName)\n\n\tr.renderSingleAttribute(ctx)\n\n\t// Set nilai pada cell yang digabungkan (merge cell)\n\tfor _, mergedCell := range mergedCells {\n\t\taxis := strings.Split(mergedCell[0], \":\")[0]\n\t\tformula, _ := r.f.GetCellFormula(r.sheetName, axis)\n\t\tif formula != \"\" {\n\t\t\tr.f.SetCellFormula(r.sheetName, axis, formula)\n\t\t\tcontinue\n\t\t}\n\t\tcellValue := mergedCell[1]\n\n\t\tprop := getProp(cellValue)\n\t\tif prop != \"\" {\n\t\t\tif !isArray(ctx, prop) {\n\t\t\t\tcellValue, _ = renderContext(cellValue, ctx)\n\t\t\t}\n\t\t}\n\n\t\tsetCellValue(r.sheetName, axis, r.f, cellValue)\n\t}\n\n\tr.renderArrayAttribute(ctx)\n}", "func (t *Table) Render() string {\n\tfmt.Fprintln(t.w, \"-\")\n\tt.w.Flush()\n\n\treturn t.buf.String()\n}", "func Render(r *sdl.Renderer, w *World) {\n\twidth := float64(r.GetViewport().W)\n\theight := float64(r.GetViewport().H)\n\n\trenderedVertices := [][2]int{}\n\n\tfor _, obj := range w.Objects {\n\t\tfor _, vertex := range obj.Geometry.Vertices {\n\t\t\trenderCoordinates := AsRelativeToSystem(w.ActiveCamera.ObjSys, ToSystem(obj.ObjSys, vertex.Pos))\n\n\t\t\tZ := Clamp(renderCoordinates.Z, 0.0001, math.NaN())\n\t\t\tratio := w.ActiveCamera.FocalLength / math.Abs(Z)\n\t\t\trenderX := ratio * renderCoordinates.X\n\t\t\trenderY := ratio * renderCoordinates.Y\n\n\t\t\tnormX, normY := NormalizeScreen(\n\t\t\t\twidth,\n\t\t\t\theight,\n\t\t\t\trenderX,\n\t\t\t\trenderY,\n\t\t\t)\n\n\t\t\trasterX := int(math.Floor(normX*width) + width/2)\n\t\t\trasterY := int(math.Floor(normY*height) + height/2)\n\n\t\t\trenderedVertices = append(renderedVertices, [2]int{rasterX, rasterY})\n\n\t\t\tDrawCircle(r, rasterX, rasterY, 5)\n\t\t}\n\t\tfor _, edge := range obj.Geometry.Edges {\n\t\t\tif len(renderedVertices) > edge.From && len(renderedVertices) > edge.To {\n\t\t\t\tr.DrawLine(\n\t\t\t\t\tint32(renderedVertices[edge.From][0]),\n\t\t\t\t\tint32(renderedVertices[edge.From][1]),\n\t\t\t\t\tint32(renderedVertices[edge.To][0]),\n\t\t\t\t\tint32(renderedVertices[edge.To][1]),\n\t\t\t\t)\n\t\t\t}\n\t\t}\n\t}\n\n\tr.Present()\n}", "func (obj *Device) DrawPrimitive(\n\ttyp PRIMITIVETYPE,\n\tstartVertex uint,\n\tprimitiveCount uint,\n) Error {\n\tret, _, _ := syscall.Syscall6(\n\t\tobj.vtbl.DrawPrimitive,\n\t\t4,\n\t\tuintptr(unsafe.Pointer(obj)),\n\t\tuintptr(typ),\n\t\tuintptr(startVertex),\n\t\tuintptr(primitiveCount),\n\t\t0,\n\t\t0,\n\t)\n\treturn toErr(ret)\n}", "func (p *printer) Array(element string) {\n\tp.Formatter.Array(element)\n}", "func (ren *RenderComponent) generateBufferContent() []float32 {\n\tscaleX := ren.scale.X\n\tscaleY := ren.scale.Y\n\trotation := float32(0.0)\n\ttransparency := float32(1.0)\n\tc := ren.Color\n\n\tfx := float32(0)\n\tfy := float32(0)\n\tfx2 := ren.drawable.Width()\n\tfy2 := ren.drawable.Height()\n\n\tif scaleX != 1 || scaleY != 1 {\n\t\t//fx *= scaleX\n\t\t//fy *= scaleY\n\t\tfx2 *= scaleX\n\t\tfy2 *= scaleY\n\t}\n\n\tp1x := fx\n\tp1y := fy\n\tp2x := fx\n\tp2y := fy2\n\tp3x := fx2\n\tp3y := fy2\n\tp4x := fx2\n\tp4y := fy\n\n\tvar x1 float32\n\tvar y1 float32\n\tvar x2 float32\n\tvar y2 float32\n\tvar x3 float32\n\tvar y3 float32\n\tvar x4 float32\n\tvar y4 float32\n\n\tif rotation != 0 {\n\t\trot := rotation * (math.Pi / 180.0)\n\n\t\tcos := math.Cos(rot)\n\t\tsin := math.Sin(rot)\n\n\t\tx1 = cos*p1x - sin*p1y\n\t\ty1 = sin*p1x + cos*p1y\n\n\t\tx2 = cos*p2x - sin*p2y\n\t\ty2 = sin*p2x + cos*p2y\n\n\t\tx3 = cos*p3x - sin*p3y\n\t\ty3 = sin*p3x + cos*p3y\n\n\t\tx4 = x1 + (x3 - x2)\n\t\ty4 = y3 - (y2 - y1)\n\t} else {\n\t\tx1 = p1x\n\t\ty1 = p1y\n\n\t\tx2 = p2x\n\t\ty2 = p2y\n\n\t\tx3 = p3x\n\t\ty3 = p3y\n\n\t\tx4 = p4x\n\t\ty4 = p4y\n\t}\n\n\tcolorR, colorG, colorB, _ := c.RGBA()\n\n\tred := colorR\n\tgreen := colorG << 8\n\tblue := colorB << 16\n\talpha := uint32(transparency*255.0) << 24\n\n\ttint := math.Float32frombits((alpha | blue | green | red) & 0xfeffffff)\n\n\tu, v, u2, v2 := ren.drawable.View()\n\n\treturn []float32{x1, y1, u, v, tint, x4, y4, u2, v, tint, x3, y3, u2, v2, tint, x2, y2, u, v2, tint}\n}" ]
[ "0.5677658", "0.54087275", "0.53996444", "0.51956725", "0.5053413", "0.5053413", "0.4922043", "0.48884347", "0.48860678", "0.4875425", "0.48742798", "0.48109788", "0.47712785", "0.475496", "0.47488353", "0.4748101", "0.47426468", "0.4740473", "0.4735046", "0.47333843", "0.4724844", "0.47082457", "0.46988106", "0.4696019", "0.46941826", "0.46906078", "0.4680132", "0.46725076", "0.4672369", "0.4671669", "0.4659162", "0.46455735", "0.46362856", "0.46361992", "0.46298182", "0.46281955", "0.46172702", "0.46156463", "0.46133736", "0.45778677", "0.45627752", "0.4561714", "0.4560741", "0.45556474", "0.4547388", "0.45253253", "0.4523236", "0.45204422", "0.45194125", "0.45144084", "0.45138532", "0.4511298", "0.4509731", "0.45020247", "0.4496358", "0.44929984", "0.44882578", "0.44805005", "0.44769657", "0.44759834", "0.44745368", "0.447332", "0.44693962", "0.4467666", "0.44665867", "0.44578773", "0.44539696", "0.44527236", "0.44471157", "0.4443676", "0.44349167", "0.4431864", "0.44248906", "0.4413505", "0.4410171", "0.4409548", "0.44052348", "0.4404621", "0.4402579", "0.44018304", "0.4400044", "0.43967307", "0.4385055", "0.4374867", "0.4370944", "0.43688935", "0.43682498", "0.43635118", "0.43619254", "0.43579435", "0.4353072", "0.43503442", "0.43502656", "0.43431464", "0.4339155", "0.43360683", "0.4330927", "0.43294495", "0.43172133", "0.4312843", "0.43121243" ]
0.0
-1
render primitives from array data, taking parameters from memory
func DrawArraysIndirect(mode uint32, indirect unsafe.Pointer) { C.glowDrawArraysIndirect(gpDrawArraysIndirect, (C.GLenum)(mode), indirect) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func renderResults(vals []interface{}) Data {\n\tvar nilcount int\n\tvar obj interface{}\n\tfor _, val := range vals {\n\t\tswitch val.(type) {\n\t\tcase image.Image, Data:\n\t\t\tobj = val\n\t\tcase nil:\n\t\t\tnilcount++\n\t\t}\n\t}\n\tif obj != nil && nilcount == len(vals)-1 {\n\t\tswitch val := obj.(type) {\n\t\tcase image.Image:\n\t\t\tdata, err := image0(val)\n\t\t\tif err == nil {\n\t\t\t\treturn data\n\t\t\t}\n\t\tcase Data:\n\t\t\treturn val\n\t\t}\n\t}\n\tif nilcount == len(vals) {\n\t\t// if all values are nil, return empty Data\n\t\treturn Data{}\n\t}\n\treturn MakeData(\"text/plain\", fmt.Sprint(vals...))\n}", "func (v Binary) Render(i, width int, baseStyle lipgloss.Style) string {\n\tw := dataWidth(width)\n\t_, err := v.Seek(int64(i*w), io.SeekStart)\n\tif err != nil {\n\t\treturn baseStyle.Blink(true).Render(err.Error())\n\t}\n\tif len(v.b) != w {\n\t\tv.b = make([]byte, w)\n\t}\n\tn, err := v.Read(v.b)\n\tif err != nil && !errors.Is(err, io.EOF) {\n\t\treturn baseStyle.Blink(true).Render(err.Error())\n\t}\n\ts := fmt.Sprintf(\"% X%s \", v.b[0:n], strings.Repeat(\" \", w-n))\n\tvar x strings.Builder\n\tfor i := 0; i < n; i++ {\n\t\tif unicode.IsPrint(rune(v.b[i])) {\n\t\t\tx.WriteRune(rune(v.b[i]))\n\t\t} else {\n\t\t\tx.WriteRune('.')\n\t\t}\n\t}\n\treturn baseStyle.Render(s + x.String())\n}", "func (r *Renderer) Render() {\n\tsx, sz, sy := r.c.Bounds()\n\tsxf := float64(sx - 1)\n\tsyf := float64(sy - 1)\n\tszf := float64(sz - 1)\n\tfor z := 0; z < sz; z++ {\n\t\tfor y := 0; y < sy; y++ {\n\t\t\tfor x := 0; x < sx; x++ {\n\t\t\t\tvar lr, lg, lb, _ uint32\n\t\t\t\tn := uint32(0)\n\t\t\t\tfor _, o := range r.objects {\n\t\t\t\t\tr, g, b, _ := o.At(float64(x)/sxf, float64(y)/syf, float64(z)/szf).RGBA()\n\t\t\t\t\tlr += r >> 8\n\t\t\t\t\tlg += g >> 8\n\t\t\t\t\tlb += b >> 8\n\t\t\t\t\tn++\n\t\t\t\t}\n\t\t\t\tr.c.Set(x, y, z, color.RGBA{uint8(lr/n), uint8(lg/n), uint8(lb/n), 255})\n\t\t\t}\n\t\t}\n\t}\n\tr.c.Render()\n}", "func render(fset *token.FileSet, x interface{}) string {\n\tvar buf bytes.Buffer\n\tif err := printer.Fprint(&buf, fset, x); err != nil {\n\t\tpanic(err)\n\t}\n\treturn buf.String()\n}", "func render(fset *token.FileSet, x interface{}) string {\n\tvar buf bytes.Buffer\n\tif err := printer.Fprint(&buf, fset, x); err != nil {\n\t\tpanic(err)\n\t}\n\treturn buf.String()\n}", "func Data(w http.ResponseWriter, r *http.Request, v []byte) {\n\trender.Data(w, r, v)\n}", "func (c *Controller) Data(data []byte) {\n ctx := c.Context()\n r := render.NewData(data)\n\n ctx.PushLog(\"status\", http.StatusOK)\n ctx.SetHeader(\"Content-Type\", r.ContentType())\n ctx.End(r.HttpCode(), r.Content())\n}", "func (rf RendererFunc) Render(w io.Writer, v interface{}) error { return rf(w, v) }", "func (h *HAProxyManager) render(ports []uint16) ([]byte, error) {\n\n\t// prepare the context\n\td := make([]templateContext, len(ports))\n\tfor i, port := range ports {\n\t\tif i == len(h.serviceAddrs) {\n\t\t\th.logger.Warnf(\"got port index %d, but only have %d service addrs. ports=%v serviceAddrs=%v\", i, len(h.serviceAddrs), ports, h.serviceAddrs)\n\t\t\tcontinue\n\t\t}\n\t\td[i] = templateContext{Port: port, Source: h.listenAddr, Dest: h.serviceAddrs[i]}\n\t}\n\n\t// render the template\n\tbuf := &bytes.Buffer{}\n\tif err := h.template.Execute(buf, d); err != nil {\n\t\treturn nil, err\n\t}\n\treturn buf.Bytes(), nil\n}", "func (e *rawData) Render(w io.Writer) (int, error) { return w.Write([]byte(e.content)) }", "func (Parser) Render(rawBytes []byte, urlPrefix string, metas map[string]string, isWiki bool) []byte {\n\treturn Render(rawBytes, urlPrefix, metas, isWiki)\n}", "func (self *Graphics) _renderWebGLI(args ...interface{}) {\n self.Object.Call(\"_renderWebGL\", args)\n}", "func (sr scoresRenderer) Render() string {\n\tbuffer := bytes.Buffer{}\n\tlast := len(sr.scores) - 1\n\tfor i, score := range sr.scores {\n\t\tbuffer.WriteString(fmt.Sprintf(\"%d\", score))\n\t\tif i != last {\n\t\t\tbuffer.WriteString(\" / \")\n\t\t}\n\t}\n\treturn buffer.String()\n}", "func DrawArrays(mode Enum, first, count int) {\n\tgl.DrawArrays(uint32(mode), int32(first), int32(count))\n}", "func (t *textRender) Render(w io.Writer) (err error) {\n\tif len(t.Values) > 0 {\n\t\t_, err = fmt.Fprintf(w, t.Format, t.Values...)\n\t} else {\n\t\t_, err = io.WriteString(w, t.Format)\n\t}\n\treturn\n}", "func (native *OpenGL) DrawElements(mode uint32, count int32, elementType uint32, indices uintptr) {\n\tgl.DrawElements(mode, count, elementType, unsafe.Pointer(indices)) // nolint: govet,gas\n}", "func renderTemplateBytes(name string, data interface{}) ([]byte, error) {\n\tvar buf bytes.Buffer\n\tif err := Tmpl.Render(&buf, name, data); err != nil {\n\t\treturn nil, err\n\t}\n\treturn buf.Bytes(), nil\n}", "func renderTemplateBytes(name string, data interface{}) ([]byte, error) {\n\tvar buf bytes.Buffer\n\tif err := Tmpl.Render(&buf, name, data); err != nil {\n\t\treturn nil, err\n\t}\n\treturn buf.Bytes(), nil\n}", "func (tofu Tofu) Render(wr io.Writer, name string, obj interface{}) error {\n\tvar m data.Map\n\tif obj != nil {\n\t\tvar ok bool\n\t\tm, ok = data.New(obj).(data.Map)\n\t\tif !ok {\n\t\t\treturn fmt.Errorf(\"invalid data type. expected map/struct, got %T\", obj)\n\t\t}\n\t}\n\treturn tofu.NewRenderer(name).Execute(wr, m)\n}", "func (vao *VAO) Render() {\n\tgl.BindVertexArray(vao.handle)\n\tif vao.indexBuffer != nil {\n\t\tgl.BindBuffer(gl.ELEMENT_ARRAY_BUFFER, vao.indexBuffer.GetHandle())\n\t\tgl.DrawElements(vao.mode, vao.indexBuffer.Len(), gl.UNSIGNED_SHORT, nil)\n\t\tgl.BindBuffer(gl.ELEMENT_ARRAY_BUFFER, 0)\n\t} else {\n\t\tgl.DrawArrays(vao.mode, 0, vao.vertexBuffers[0].Len())\n\t}\n\tgl.BindVertexArray(0)\n}", "func (ren *RenderComponent) generateBufferContent() []float32 {\n\tscaleX := ren.scale.X\n\tscaleY := ren.scale.Y\n\trotation := float32(0.0)\n\ttransparency := float32(1.0)\n\tc := ren.Color\n\n\tfx := float32(0)\n\tfy := float32(0)\n\tfx2 := ren.drawable.Width()\n\tfy2 := ren.drawable.Height()\n\n\tif scaleX != 1 || scaleY != 1 {\n\t\t//fx *= scaleX\n\t\t//fy *= scaleY\n\t\tfx2 *= scaleX\n\t\tfy2 *= scaleY\n\t}\n\n\tp1x := fx\n\tp1y := fy\n\tp2x := fx\n\tp2y := fy2\n\tp3x := fx2\n\tp3y := fy2\n\tp4x := fx2\n\tp4y := fy\n\n\tvar x1 float32\n\tvar y1 float32\n\tvar x2 float32\n\tvar y2 float32\n\tvar x3 float32\n\tvar y3 float32\n\tvar x4 float32\n\tvar y4 float32\n\n\tif rotation != 0 {\n\t\trot := rotation * (math.Pi / 180.0)\n\n\t\tcos := math.Cos(rot)\n\t\tsin := math.Sin(rot)\n\n\t\tx1 = cos*p1x - sin*p1y\n\t\ty1 = sin*p1x + cos*p1y\n\n\t\tx2 = cos*p2x - sin*p2y\n\t\ty2 = sin*p2x + cos*p2y\n\n\t\tx3 = cos*p3x - sin*p3y\n\t\ty3 = sin*p3x + cos*p3y\n\n\t\tx4 = x1 + (x3 - x2)\n\t\ty4 = y3 - (y2 - y1)\n\t} else {\n\t\tx1 = p1x\n\t\ty1 = p1y\n\n\t\tx2 = p2x\n\t\ty2 = p2y\n\n\t\tx3 = p3x\n\t\ty3 = p3y\n\n\t\tx4 = p4x\n\t\ty4 = p4y\n\t}\n\n\tcolorR, colorG, colorB, _ := c.RGBA()\n\n\tred := colorR\n\tgreen := colorG << 8\n\tblue := colorB << 16\n\talpha := uint32(transparency*255.0) << 24\n\n\ttint := math.Float32frombits((alpha | blue | green | red) & 0xfeffffff)\n\n\tu, v, u2, v2 := ren.drawable.View()\n\n\treturn []float32{x1, y1, u, v, tint, x4, y4, u2, v, tint, x3, y3, u2, v2, tint, x2, y2, u, v2, tint}\n}", "func (self *TileSprite) _renderWebGLI(args ...interface{}) {\n self.Object.Call(\"_renderWebGL\", args)\n}", "func (c *ConnectionSPI) Render(pixels []RGBPixel) {\r\n\tlogFields := log.Fields{\"package\": logPkg, \"conn\": \"SPI\", \"func\": \"RenderLEDs\"}\r\n\tlog.WithFields(logFields).Infof(\"Render %d LEDs\", len(pixels))\r\n\t// Fix for Raspberry Pi 3 Model B+ (5.15.84-v7+)\r\n\t// Data signal seems to be splitted sending less than 11 LEDS\r\n\tif len(pixels) < 11 {\r\n\t\tpixels = append(pixels, []RGBPixel{{}, {}, {}, {}, {}, {}, {}, {}, {}, {}}...)\r\n\t}\r\n\tvar translatedRGBs []uint8\r\n\tfor _, pixel := range pixels {\r\n\r\n\t\tcolorData := GetColorData(pixel, c.FixSPI)\r\n\t\tlog.WithFields(logFields).Tracef(\"%08b\", pixel)\r\n\r\n\t\tfor _, c := range colorData {\r\n\t\t\ttranslatedRGBs = append(translatedRGBs, c)\r\n\t\t}\r\n\t}\r\n\r\n\tc.transfer(translatedRGBs)\r\n}", "func TemplateData(p string, data interface{}) {\n}", "func (r *Renderer) Render() {\n\tgl.DrawArrays(gl.TRIANGLES, 0, int32(len(r.RawRenderer)*4))\n}", "func renderDisplayData(value interface{}) (data, metadata map[string]interface{}, err error) {\n\t// TODO(axw) sniff/provide a way to specify types for things that net/http does not sniff:\n\t// - SVG\n\t// - JSON\n\t// - LaTeX\n\tdata = make(map[string]interface{})\n\tmetadata = make(map[string]interface{})\n\tvar stringValue, contentType string\n\tswitch typedValue := value.(type) {\n\tcase image.Image:\n\t\t// TODO(axw) provide a way for the user to use alternative encodings?\n\t\t//\n\t\t// The current presumption is that images will be mostly used\n\t\t// for displaying graphs or illustrations where PNG produces\n\t\t// better looking images.\n\t\tvar buf bytes.Buffer\n\t\tif err := png.Encode(&buf, typedValue); err != nil {\n\t\t\treturn nil, nil, fmt.Errorf(\"encoding image: %v\", err)\n\t\t}\n\t\tbounds := typedValue.Bounds()\n\t\tdata[\"image/png\"] = buf.Bytes()\n\t\tdata[\"text/plain\"] = fmt.Sprintf(\"%dx%d image\", bounds.Dx(), bounds.Dy())\n\t\tmetadata[\"image/png\"] = map[string]interface{}{\n\t\t\t\"width\": bounds.Dx(),\n\t\t\t\"height\": bounds.Dy(),\n\t\t}\n\t\treturn data, metadata, nil\n\n\tcase []byte:\n\t\tcontentType = detectContentType(typedValue)\n\t\tstringValue = string(typedValue)\n\n\tcase string:\n\t\tcontentType = detectContentType([]byte(typedValue))\n\t\tstringValue = typedValue\n\n\tdefault:\n\t\tstringValue = fmt.Sprint(typedValue)\n\t\tvalue = stringValue\n\t\tcontentType = detectContentType([]byte(stringValue))\n\t}\n\n\tdata[\"text/plain\"] = stringValue\n\tif contentType != \"text/plain\" {\n\t\t// \"A plain text representation should always be\n\t\t// provided in the text/plain mime-type.\"\n\t\tdata[contentType] = value\n\t}\n\treturn data, metadata, nil\n}", "func (obj *Device) DrawIndexedPrimitive(\n\ttyp PRIMITIVETYPE,\n\tbaseVertexIndex int,\n\tminIndex uint,\n\tnumVertices uint,\n\tstartIndex uint,\n\tprimitiveCount uint,\n) Error {\n\tret, _, _ := syscall.Syscall9(\n\t\tobj.vtbl.DrawIndexedPrimitive,\n\t\t7,\n\t\tuintptr(unsafe.Pointer(obj)),\n\t\tuintptr(typ),\n\t\tuintptr(baseVertexIndex),\n\t\tuintptr(minIndex),\n\t\tuintptr(numVertices),\n\t\tuintptr(startIndex),\n\t\tuintptr(primitiveCount),\n\t\t0,\n\t\t0,\n\t)\n\treturn toErr(ret)\n}", "func (self *Graphics) Data() interface{}{\n return self.Object.Get(\"data\")\n}", "func (gl *WebGL) DrawElements(mode GLEnum, count int, valueType GLEnum, offset int) {\n\tgl.context.Call(\"drawElements\", mode, count, valueType, offset)\n}", "func DrawElements(mode uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n\tsyscall.Syscall6(gpDrawElements, 4, uintptr(mode), uintptr(count), uintptr(xtype), uintptr(indices), 0, 0)\n}", "func (native *OpenGL) BufferData(target uint32, size int, data interface{}, usage uint32) {\n\tdataPtr, isPtr := data.(unsafe.Pointer)\n\tif isPtr {\n\t\tgl.BufferData(target, size, dataPtr, usage)\n\t} else {\n\t\tgl.BufferData(target, size, gl.Ptr(data), usage)\n\t}\n}", "func DrawElements(mode uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n C.glowDrawElements(gpDrawElements, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices)\n}", "func DrawArrays(mode uint32, first int32, count int32) {\n\tsyscall.Syscall(gpDrawArrays, 3, uintptr(mode), uintptr(first), uintptr(count))\n}", "func ArrayElement(i int32) {\n C.glowArrayElement(gpArrayElement, (C.GLint)(i))\n}", "func (native *OpenGL) DrawArrays(mode uint32, first int32, count int32) {\n\tgl.DrawArrays(mode, first, count)\n}", "func DrawElements(mode Enum, count int, ty Enum, offset int) {\n\tgl.DrawElements(uint32(mode), int32(count), uint32(ty), gl.PtrOffset(offset))\n}", "func Render(expr expreduceapi.Ex) (chart.Chart, error) {\n\tgraph := chart.Chart{\n\t\tWidth: 360,\n\t\tHeight: 220,\n\t\tXAxis: chart.XAxis{\n\t\t\tStyle: chart.Style{Show: true},\n\t\t},\n\t\tYAxis: chart.YAxis{\n\t\t\tStyle: chart.Style{Show: true},\n\t\t},\n\t}\n\n\tgraphics, ok := atoms.HeadAssertion(expr, \"System`Graphics\")\n\tif !ok {\n\t\treturn graph, fmt.Errorf(\"trying to render a non-Graphics[] expression: %v\", expr)\n\t}\n\n\tif graphics.Len() < 1 {\n\t\treturn graph, errors.New(\"the Graphics[] expression must have at least one argument\")\n\t}\n\n\tstyle := chart.Style{\n\t\tShow: true,\n\t\tStrokeColor: drawing.ColorBlack,\n\t}\n\terr := renderPrimitive(&graph, graphics.GetPart(1), &style)\n\tif err != nil {\n\t\treturn graph, errors.New(\"failed to render primitive\")\n\t}\n\n\treturn graph, nil\n}", "func (self *Tween) GenerateData() []interface{}{\n\tarray00 := self.Object.Call(\"generateData\")\n\tlength00 := array00.Length()\n\tout00 := make([]interface{}, length00, length00)\n\tfor i00 := 0; i00 < length00; i00++ {\n\t\tout00[i00] = array00.Index(i00)\n\t}\n\treturn out00\n}", "func DrawArrays(mode uint32, first int32, count int32) {\n C.glowDrawArrays(gpDrawArrays, (C.GLenum)(mode), (C.GLint)(first), (C.GLsizei)(count))\n}", "func (debugging *debuggingOpenGL) DrawArrays(mode uint32, first int32, count int32) {\n\tdebugging.recordEntry(\"DrawArrays\", first, count)\n\tdebugging.gl.DrawArrays(mode, first, count)\n\tdebugging.recordExit(\"DrawArrays\")\n}", "func (r renderer) Table(out *bytes.Buffer, header []byte, body []byte, columnData []int) {}", "func (renderer *SimpleMatrixRenderer) Render() {\n\trenderer.renderCharacter(\"\\n\")\n\n\tfor row := 0; row < renderer.Matrix.Height; row++ {\n\t\tfor col := 0; col < renderer.Matrix.Width; col++ {\n\t\t\tif !renderer.Matrix.IsFieldOccupied(row, col) {\n\t\t\t\trenderer.renderUnoccupiedField()\n\t\t\t} else {\n\t\t\t\trenderer.renderOccupiedFieldAtCurrentCursorPos(row, col)\n\t\t\t}\n\t\t}\n\n\t\trenderer.renderCharacter(\"\\n\")\n\t}\n\n\trenderer.renderCharacter(\"\\n\")\n}", "func Render(files [][]byte, maxIt uint, debug bool) (\n\t[]byte, error,\n) {\n\tinfl, debugParse, err := parseFiles(files)\n\tif err != nil {\n\t\tif debug {\n\t\t\twriteDebug(\"parsing\", debugParse)\n\t\t}\n\t\treturn []byte{}, err\n\t}\n\tres, debugRender, err := renderTmpl(infl, maxIt)\n\tif err != nil {\n\t\tif debug {\n\t\t\twriteDebug(\"render\", debugRender)\n\t\t}\n\t\treturn []byte{}, err\n\t}\n\treturn res, nil\n}", "func Interpret(data []byte, offset int) []byte {\n\tb:=make([]byte, len(data) * 2)\n\n\tfor i:=0; i<len(data); i++ {\n\t\tb[offset + i * 2] = hex_ascii[ (data[i] & 0XF0) >> 4]\n\t\tb[offset + i * 2 + 1] = hex_ascii[data[i] & 0x0F]\n\t}\n\treturn b\n}", "func (d *Device) Render() error {\n\tbuf := new(bytes.Buffer)\n\n\tfor _, chain := range d.LEDs {\n\t\tfor _, col := range chain {\n\t\t\tbuf.Write([]byte{col.R, col.G, col.B})\n\t\t}\n\t}\n\n\t_, err := Conn.WriteToUDP(buf.Bytes(), d.Addr)\n\treturn err\n}", "func (g *Game) Render() string {\n\tascii := \"\"\n\n\tm := g.generateScreen()\n\tfor _, row := range m.cells {\n\t\tascii += strings.Join(row, \"\") + \"\\n\"\n\t}\n\n\treturn ascii\n}", "func (e *expression) printArray() string {\n\ta := \"\"\n\n\tfor i := 0; i < len(e.lenArray); i++ {\n\t\tvArray := string('i' + i)\n\t\ta += fmt.Sprintf(\"[%s]\", vArray)\n\t}\n\treturn a\n}", "func (debugging *debuggingOpenGL) DrawElements(mode uint32, count int32, elementType uint32, indices uintptr) {\n\tdebugging.recordEntry(\"DrawElements\", mode, count, elementType, indices)\n\tdebugging.gl.DrawElements(mode, count, elementType, indices)\n\tdebugging.recordExit(\"DrawElements\")\n}", "func (t *TextRenderer) Print(text string, x, y float32, scale float32) error {\n\tindices := []rune(text)\n\tif len(indices) == 0 {\n\t\treturn nil\n\t}\n\tt.shader.Use()\n\n\tlowChar := rune(32)\n\n\tgl.ActiveTexture(gl.TEXTURE0)\n\tgl.BindVertexArray(t.vao)\n\n\tfor i := range indices {\n\t\truneIndex := indices[i]\n\n\t\tif int(runeIndex)-int(lowChar) > len(t.fontChar) || runeIndex < lowChar {\n\t\t\tcontinue\n\t\t}\n\n\t\tch := t.fontChar[runeIndex-lowChar]\n\n\t\txpos := x + float32(ch.bearingH)*scale\n\t\typos := y - float32(ch.height-ch.bearingV)*scale\n\t\tw := float32(ch.width) * scale\n\t\th := float32(ch.height) * scale\n\n\t\tvar vertices = []float32{\n\t\t\txpos, ypos + h, 0.0, 1.0,\n\t\t\txpos + w, ypos, 1.0, 0.0,\n\t\t\txpos, ypos, 0.0, 0.0,\n\t\t\txpos, ypos + h, 0.0, 1.0,\n\t\t\txpos + w, ypos + h, 1.0, 1.0,\n\t\t\txpos + w, ypos, 1.0, 0.0,\n\t\t}\n\n\t\tgl.BindTexture(gl.TEXTURE_2D, ch.textureID)\n\t\tgl.BindBuffer(gl.ARRAY_BUFFER, t.vbo)\n\t\tgl.BufferSubData(gl.ARRAY_BUFFER, 0, len(vertices)*4, gl.Ptr(vertices))\n\n\t\tgl.BindBuffer(gl.ARRAY_BUFFER, 0)\n\t\tgl.DrawArrays(gl.TRIANGLES, 0, 6)\n\n\t\tx += float32(ch.advance>>6) * scale\n\t}\n\tgl.BindVertexArray(0)\n\tgl.BindTexture(gl.TEXTURE_2D, 0)\n\tgl.UseProgram(0)\n\treturn nil\n}", "func (self *Tween) GenerateDataI(args ...interface{}) []interface{}{\n\tarray00 := self.Object.Call(\"generateData\", args)\n\tlength00 := array00.Length()\n\tout00 := make([]interface{}, length00, length00)\n\tfor i00 := 0; i00 < length00; i00++ {\n\t\tout00[i00] = array00.Index(i00)\n\t}\n\treturn out00\n}", "func (tpl *Template) RenderBytes(ctx ...interface{}) ([]byte, error) {\n\tvar buf bytes.Buffer\n\terr := tpl.Run(&buf, ctx...)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\treturn buf.Bytes(), nil\n}", "func (a *Array) Literal() {}", "func DrawElements(mode GLenum, count int, typ GLenum, indices interface{}) {\n\tC.glDrawElements(C.GLenum(mode), C.GLsizei(count), C.GLenum(typ),\n\t\tptr(indices))\n}", "func (va *VertexArray) SetData(data []float32) (err error) {\n\tgl.BindBuffer(gl.ARRAY_BUFFER, va.vbo) // tells OpenGL what kind of buffer this is\n\n\t// BufferData assigns data to the buffer.\n\t// there can only be one ARRAY_BUFFER bound at any time, so OpenGL knows which buffer we mean if we\n\t// tell it what type of buffer it is.\n\t//\t\t\t type\t\t\t size (in bytes) pointer to data\tusage\n\tgl.BufferData(gl.ARRAY_BUFFER, len(data)*4, gl.Ptr(data), gl.STATIC_DRAW)\n\n\treturn\n}", "func (debugging *debuggingOpenGL) BufferData(target uint32, size int, data interface{}, usage uint32) {\n\tdebugging.recordEntry(\"BufferData\", target, size, data, usage)\n\tdebugging.gl.BufferData(target, size, data, usage)\n\tdebugging.recordExit(\"BufferData\")\n}", "func (l *Label) data() []byte {\n Assert(nilLabel, l != nil)\n \n bytes, _ := util.Uint64ToBytes(l.value)\n refs, _ := util.Uint64ToBytes(l.refs)\n left, _ := util.Uint16ToBytes(l.l)\n right, _ := util.Uint16ToBytes(l.r)\n \n bytes = append(bytes, append(refs, append(left, append(right, l.h)...)...)...) // TODO ??\n return bytes\n \n}", "func (obj *Device) DrawIndexedPrimitiveUP(\n\ttyp PRIMITIVETYPE,\n\tminVertexIndex uint,\n\tnumVertices uint,\n\tprimitiveCount uint,\n\tindexData uintptr,\n\tindexDataFormat FORMAT,\n\tvertexStreamZeroData uintptr,\n\tvertexStreamZeroStride uint,\n) Error {\n\tret, _, _ := syscall.Syscall9(\n\t\tobj.vtbl.DrawIndexedPrimitiveUP,\n\t\t9,\n\t\tuintptr(unsafe.Pointer(obj)),\n\t\tuintptr(typ),\n\t\tuintptr(minVertexIndex),\n\t\tuintptr(numVertices),\n\t\tuintptr(primitiveCount),\n\t\tindexData,\n\t\tuintptr(indexDataFormat),\n\t\tvertexStreamZeroData,\n\t\tuintptr(vertexStreamZeroStride),\n\t)\n\treturn toErr(ret)\n}", "func (obj *Device) DrawPrimitive(\n\ttyp PRIMITIVETYPE,\n\tstartVertex uint,\n\tprimitiveCount uint,\n) Error {\n\tret, _, _ := syscall.Syscall6(\n\t\tobj.vtbl.DrawPrimitive,\n\t\t4,\n\t\tuintptr(unsafe.Pointer(obj)),\n\t\tuintptr(typ),\n\t\tuintptr(startVertex),\n\t\tuintptr(primitiveCount),\n\t\t0,\n\t\t0,\n\t)\n\treturn toErr(ret)\n}", "func Render(s api.Session, renderAs RenderName, value dgo.Value, out io.Writer) {\n\t// Convert value to rich data format without references\n\tdedupStream := func(value dgo.Value, consumer streamer.Consumer) {\n\t\topts := streamer.DefaultOptions()\n\t\topts.DedupLevel = streamer.NoDedup\n\t\tser := streamer.New(s.AliasMap(), opts)\n\t\tser.Stream(value, consumer)\n\t}\n\n\tswitch renderAs {\n\tcase JSON:\n\t\tif value.Equals(vf.Nil) {\n\t\t\tutil.WriteString(out, \"null\\n\")\n\t\t} else {\n\t\t\tdedupStream(value, streamer.JSON(out))\n\t\t\tutil.WriteByte(out, '\\n')\n\t\t}\n\n\tcase YAML:\n\t\tif value.Equals(vf.Nil) {\n\t\t\tutil.WriteString(out, \"\\n\")\n\t\t} else {\n\t\t\tdc := streamer.DataCollector()\n\t\t\tdedupStream(value, dc)\n\t\t\tbs, err := yaml.Marshal(dc.Value())\n\t\t\tif err != nil {\n\t\t\t\tpanic(err)\n\t\t\t}\n\t\t\tutil.WriteString(out, string(bs))\n\t\t}\n\tcase Binary:\n\t\tbi := vf.New(typ.Binary, value).(dgo.Binary)\n\t\t_, err := out.Write(bi.GoBytes())\n\t\tif err != nil {\n\t\t\tpanic(err)\n\t\t}\n\tcase Text:\n\t\tutil.Fprintln(out, value)\n\tdefault:\n\t\tpanic(fmt.Errorf(`unknown rendering '%s'`, renderAs))\n\t}\n}", "func Render(typ Type, input any, urlPrefix string, metas map[string]string) []byte {\n\tvar rawBytes []byte\n\tswitch v := input.(type) {\n\tcase []byte:\n\t\trawBytes = v\n\tcase string:\n\t\trawBytes = []byte(v)\n\tdefault:\n\t\tpanic(fmt.Sprintf(\"unrecognized input content type: %T\", input))\n\t}\n\n\turlPrefix = strings.TrimRight(strings.ReplaceAll(urlPrefix, \" \", \"%20\"), \"/\")\n\tvar rawHTML []byte\n\tswitch typ {\n\tcase TypeMarkdown:\n\t\trawHTML = RawMarkdown(rawBytes, urlPrefix)\n\tcase TypeOrgMode:\n\t\trawHTML = RawOrgMode(rawBytes, urlPrefix)\n\tdefault:\n\t\treturn rawBytes // Do nothing if syntax type is not recognized\n\t}\n\n\trawHTML = postProcessHTML(rawHTML, urlPrefix, metas)\n\treturn SanitizeBytes(rawHTML)\n}", "func Render(r *sdl.Renderer, w *World) {\n\twidth := float64(r.GetViewport().W)\n\theight := float64(r.GetViewport().H)\n\n\trenderedVertices := [][2]int{}\n\n\tfor _, obj := range w.Objects {\n\t\tfor _, vertex := range obj.Geometry.Vertices {\n\t\t\trenderCoordinates := AsRelativeToSystem(w.ActiveCamera.ObjSys, ToSystem(obj.ObjSys, vertex.Pos))\n\n\t\t\tZ := Clamp(renderCoordinates.Z, 0.0001, math.NaN())\n\t\t\tratio := w.ActiveCamera.FocalLength / math.Abs(Z)\n\t\t\trenderX := ratio * renderCoordinates.X\n\t\t\trenderY := ratio * renderCoordinates.Y\n\n\t\t\tnormX, normY := NormalizeScreen(\n\t\t\t\twidth,\n\t\t\t\theight,\n\t\t\t\trenderX,\n\t\t\t\trenderY,\n\t\t\t)\n\n\t\t\trasterX := int(math.Floor(normX*width) + width/2)\n\t\t\trasterY := int(math.Floor(normY*height) + height/2)\n\n\t\t\trenderedVertices = append(renderedVertices, [2]int{rasterX, rasterY})\n\n\t\t\tDrawCircle(r, rasterX, rasterY, 5)\n\t\t}\n\t\tfor _, edge := range obj.Geometry.Edges {\n\t\t\tif len(renderedVertices) > edge.From && len(renderedVertices) > edge.To {\n\t\t\t\tr.DrawLine(\n\t\t\t\t\tint32(renderedVertices[edge.From][0]),\n\t\t\t\t\tint32(renderedVertices[edge.From][1]),\n\t\t\t\t\tint32(renderedVertices[edge.To][0]),\n\t\t\t\t\tint32(renderedVertices[edge.To][1]),\n\t\t\t\t)\n\t\t\t}\n\t\t}\n\t}\n\n\tr.Present()\n}", "func Draw(bp *BoundProgram) {\n\t// TODO might still need the buffer contents to be pushed:\n\t/*\n\t\tgl.BufferData(gl.ARRAY_BUFFER, len(cube_vertices)*4, gl.Ptr(cube_vertices), gl.STATIC_DRAW)\n\t*/\n\t// TODO might still need textures to be bound for the call:\n\t/*\n\t\tgl.ActiveTexture(gl.TEXTURE0)\n\t\tgl.BindTexture(gl.TEXTURE_2D, tCache.Get(\"placeholder\"))\n\t*/\n\t// TODO draw calls are themselves still specialized and param'd:\n\t/*\n\t\tgl.DrawArrays(gl.TRIANGLES, 0, 6*2*3)\n\t*/\n}", "func (sl SprintList) renderPlain(w io.Writer) error {\n\treturn renderPlain(w, sl.tableData())\n}", "func (s *SegmentRoot) Render() []byte {\n\tvar b bytes.Buffer\n\tb.Write(SetBackground(SegmentRootBackground))\n\tfmt.Fprint(&b, \" \")\n\tb.Write(s.Data)\n\tfmt.Fprint(&b, \" \")\n\treturn b.Bytes()\n}", "func (l LogItems) Render(showTime bool, ll [][]byte) {\n\tcolors := make(map[string]int, len(l))\n\tfor i, item := range l {\n\t\tinfo := item.ID()\n\t\tcolor, ok := colors[info]\n\t\tif !ok {\n\t\t\tcolor = colorFor(info)\n\t\t\tcolors[info] = color\n\t\t}\n\t\tll[i] = item.Render(color, showTime)\n\t}\n}", "func RenderList(w http.ResponseWriter, r *http.Request, l []Renderer) error {\n\tfor _, v := range l {\n\t\tif err := renderer(w, r, v); err != nil {\n\t\t\treturn err\n\t\t}\n\t}\n\tRespond(w, r, l)\n\treturn nil\n}", "func (c *Context) Data(code int, contentType string, data []byte) {\n\tc.Render(code, render.Data{\n\t\tContentType: contentType,\n\t\tData: data,\n\t})\n}", "func (a *Array) Format(f fmt.State, c rune) {\n\tswitch c {\n\tcase 'z': // Private format specifier, supports Entity.Signature\n\t\tfmt.Fprintf(f, \"[%d]%z\", a.Size, a.ValueType)\n\tcase 'r': // Private format specifier, supports Type.Representation\n\t\tfmt.Fprintf(f, \"[%d]%r\", a.Size, a.ValueType)\n\tdefault:\n\t\tif a.Alias != \"\" {\n\t\t\tfmt.Fprint(f, a.Alias)\n\t\t} else {\n\t\t\tfmt.Fprintf(f, \"[%d]%v\", a.Size, a.ValueType)\n\t\t}\n\t}\n}", "func DrawArrays(mode Enum, first Int, count Sizei) {\n\tcmode, _ := (C.GLenum)(mode), cgoAllocsUnknown\n\tcfirst, _ := (C.GLint)(first), cgoAllocsUnknown\n\tccount, _ := (C.GLsizei)(count), cgoAllocsUnknown\n\tC.glDrawArrays(cmode, cfirst, ccount)\n}", "func (p *pattern) RenderString(d map[string]interface{}) string {\n\t// TODO strings.Builder\n\tbuf := p.bufPool.Get().(*bytes.Buffer)\n\tdefer func() {\n\t\tbuf.Reset()\n\t\tp.bufPool.Put(buf)\n\t}()\n\tfor _, f := range p.funcs {\n\t\tbuf.WriteString(f(d))\n\t}\n\n\treturn buf.String()\n}", "func encode(buf *bytes.Buffer, v reflect.Value) error {\n\tswitch v.Kind() {\n\tcase reflect.Invalid: // ignore\n\n\tcase reflect.Float32, reflect.Float64:\n\t\tfmt.Fprintf(buf, \"%f\", v.Float())\n\n\tcase reflect.Complex128, reflect.Complex64:\n\t\tc := v.Complex()\n\t\tfmt.Fprintf(buf, \"#C(%f %f)\", real(c), imag(c))\n\n\tcase reflect.Bool:\n\t\tif v.Bool() {\n\t\t\tfmt.Fprintf(buf, \"t\")\n\t\t}\n\n\tcase reflect.Interface:\n\t\t// type output\n\t\tt := v.Elem().Type()\n\n\t\tleftBuffer := new(bytes.Buffer)\n\t\trightBuffer := new(bytes.Buffer)\n\n\t\tif t.Name() == \"\" { // 名前がつけられてないtypeはそのまま表示する\n\t\t\tfmt.Fprintf(leftBuffer, \"%q\", t)\n\t\t} else {\n\t\t\tfmt.Fprintf(leftBuffer, \"\\\"%s.%s\\\" \", t.PkgPath(), t.Name()) //一意ではないとはこういうことか?\n\t\t}\n\n\t\t// value output\n\t\tif err := encode(rightBuffer, v.Elem()); err != nil {\n\t\t\treturn err\n\t\t}\n\n\t\tif len(rightBuffer.Bytes()) != 0 {\n\t\t\tbuf.WriteByte('(')\n\t\t\tbuf.Write(leftBuffer.Bytes())\n\t\t\tbuf.WriteByte(' ')\n\t\t\tbuf.Write(rightBuffer.Bytes())\n\t\t\tbuf.WriteByte(')')\n\t\t}\n\n\tcase reflect.Int, reflect.Int8, reflect.Int16,\n\t\treflect.Int32, reflect.Int64:\n\t\tfmt.Fprintf(buf, \"%d\", v.Int())\n\n\tcase reflect.Uint, reflect.Uint8, reflect.Uint16,\n\t\treflect.Uint32, reflect.Uint64, reflect.Uintptr:\n\t\tfmt.Fprintf(buf, \"%d\", v.Uint())\n\n\tcase reflect.String:\n\t\tfmt.Fprintf(buf, \"%q\", v.String())\n\n\tcase reflect.Ptr:\n\t\treturn encode(buf, v.Elem())\n\n\tcase reflect.Array, reflect.Slice: // (value ...)\n\n\t\tcontent := new(bytes.Buffer)\n\n\t\tisFirst := true\n\n\t\tfor i := 0; i < v.Len(); i++ {\n\t\t\tif isFirst {\n\t\t\t\tisFirst = false\n\t\t\t\tcontent.WriteByte(' ')\n\t\t\t}\n\t\t\tif err := encode(content, v.Index(i)); err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\t\t}\n\n\t\tif len(content.Bytes()) != 0 {\n\t\t\tbuf.WriteByte('(')\n\t\t\tbuf.Write(content.Bytes())\n\t\t\tbuf.WriteByte(')')\n\t\t}\n\n\tcase reflect.Struct: // ((name value) ...)\n\n\t\tcontent := new(bytes.Buffer)\n\n\t\tisFirst := true\n\n\t\tfor i := 0; i < v.NumField(); i++ {\n\t\t\trightBuffer := new(bytes.Buffer)\n\t\t\tif err := encode(rightBuffer, v.Field(i)); err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\n\t\t\tif len(rightBuffer.Bytes()) != 0 {\n\t\t\t\tif isFirst {\n\t\t\t\t\tcontent.WriteByte(' ')\n\t\t\t\t\tisFirst = false\n\t\t\t\t}\n\t\t\t\tcontent.WriteByte('(')\n\t\t\t\tfmt.Fprintf(content, \"%s\", v.Type().Field(i).Name)\n\t\t\t\tcontent.WriteByte(' ')\n\t\t\t\tcontent.Write(rightBuffer.Bytes())\n\t\t\t\tcontent.WriteByte(')')\n\t\t\t}\n\t\t}\n\n\t\tif len(content.Bytes()) != 0 {\n\t\t\tbuf.WriteByte('(')\n\t\t\tbuf.Write(content.Bytes())\n\t\t\tbuf.WriteByte(')')\n\t\t}\n\n\tcase reflect.Map: // ((key value) ...)\n\t\tisFirst := true\n\t\tcontent := new(bytes.Buffer)\n\n\t\tfor _, key := range v.MapKeys() {\n\t\t\tif isFirst {\n\t\t\t\tcontent.WriteByte(' ')\n\t\t\t\tisFirst = false\n\t\t\t}\n\n\t\t\tleftBuffer := new(bytes.Buffer)\n\t\t\trightBuffer := new(bytes.Buffer)\n\n\t\t\tif err := encode(leftBuffer, key); err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\t\t\tif err := encode(rightBuffer, v.MapIndex(key)); err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\n\t\t\tif len(rightBuffer.Bytes()) != 0 {\n\t\t\t\tcontent.WriteByte('(')\n\t\t\t\tcontent.Write(leftBuffer.Bytes())\n\t\t\t\tcontent.WriteByte(' ')\n\t\t\t\tcontent.Write(rightBuffer.Bytes())\n\t\t\t\tcontent.WriteByte(')')\n\t\t\t}\n\t\t}\n\n\t\tif len(content.Bytes()) != 0 {\n\t\t\tbuf.WriteByte('(')\n\t\t\tbuf.Write(content.Bytes())\n\t\t\tbuf.WriteByte(')')\n\t\t}\n\n\tdefault: // float, complex, bool, chan, func, interface\n\t\treturn fmt.Errorf(\"unsupported type: %s\", v.Type())\n\t}\n\treturn nil\n}", "func (gl *WebGL) BufferData(target GLEnum, data interface{}, usage GLEnum) {\n\tvalues := sliceToTypedArray(data)\n\tgl.context.Call(\"bufferData\", target, values, usage)\n}", "func (c *cartridge) Render() {\n\tc.Cls()\n\tc.PrintAt(fmt.Sprintf(\"counter:%d\", c.counter), c.x, c.y)\n}", "func makeVao(data []float32) uint32 {\n\tvar vbo uint32\n\tgl.GenBuffers(1, &vbo)\n\tgl.BindBuffer(gl.ARRAY_BUFFER, vbo)\n\tgl.BufferData(gl.ARRAY_BUFFER, 4*len(data), gl.Ptr(data), gl.STATIC_DRAW)\n\n\tvar vao uint32\n\tgl.GenVertexArrays(1, &vao)\n\tgl.BindVertexArray(vao)\n\tgl.BindBuffer(gl.ARRAY_BUFFER, vbo)\n\tvar offset int\n\n\t// position attribute\n\tgl.VertexAttribPointer(0, 3, gl.FLOAT, false, 8*4, gl.PtrOffset(offset))\n\tgl.EnableVertexAttribArray(0)\n\toffset += 3 * 4\n\n\t// color attribute\n\tgl.VertexAttribPointer(1, 3, gl.FLOAT, false, 8*4, gl.PtrOffset(offset))\n\tgl.EnableVertexAttribArray(1)\n\toffset += 3 * 4\n\n\t// texture coord attribute\n\tgl.VertexAttribPointer(2, 2, gl.FLOAT, false, 8*4, gl.PtrOffset(offset))\n\tgl.EnableVertexAttribArray(2)\n\toffset += 2 * 4\n\n\treturn vao\n}", "func PrintDataSlice(data interface{}) {\n\td := reflect.ValueOf(data)\n\n\tfor i := 0; i < d.Len(); i++ {\n\t\tdataItem := d.Index(i)\n\t\ttypeOfT := dataItem.Type()\n\n\t\tfor j := 0; j < dataItem.NumField(); j++ {\n\t\t\tf := dataItem.Field(j)\n\t\t\tfmt.Printf(\"%s: %v\\n\", typeOfT.Field(j).Name, f.Interface())\n\t\t}\n\t\tfmt.Printf(\"\\n\")\n\t}\n}", "func (self *GameObjectCreator) RenderTexture1O(width int) *RenderTexture{\n return &RenderTexture{self.Object.Call(\"renderTexture\", width)}\n}", "func (s funcRenderer) Render(w io.Writer, data Data) error {\n\treturn s.renderFunc(w, data)\n}", "func (Empty) Render(width, height int) *term.Buffer {\n\treturn term.NewBufferBuilder(width).Buffer()\n}", "func (a *Array) Print() {\n\tvar format string\n\tfor i := uint(0); i < a.Len(); i++ {\n\t\tformat += fmt.Sprintf(\"|%+v\", a.data[i])\n\t}\n\tfmt.Println(format)\n}", "func (f Frame) Render() string {\n\tsb := strings.Builder{}\n\tfor _, row := range f {\n\t\tfor _, shade := range row {\n\t\t\tsb.WriteString(fmt.Sprintf(\"%d\", shade))\n\t\t}\n\t\tsb.WriteString(\"\\n\")\n\t}\n\tsb.WriteString(\"==============================\\n\")\n\n\treturn sb.String()\n}", "func GenerateShapes() {\r\n\t// Square\r\n\tShapes[0].vertices = []gl.GLfloat{-1, -1, 1, -1, -1, 1, 1, 1}\r\n\tShapes[0].elements = []gl.GLushort{0, 1, 2, 2, 3, 1}\r\n\r\n\t// ___|\r\n\tShapes[1].vertices = []gl.GLfloat{-2, 0, -2, -1, 2, -1, 2, 0, 2, 1, 1, 1, 1, 0}\r\n\tShapes[1].elements = []gl.GLushort{0, 1, 2, 2, 3, 0, 3, 4, 5, 5, 6, 3}\r\n\r\n\t// _|_\r\n\tShapes[2].vertices = []gl.GLfloat{-1.5, 0, -0.5, 0, -0.5, 1, 0.5, 1, 0.5, 0, 1.5, 0, 1.5, -1, -1.5, -1}\r\n\tShapes[2].elements = []gl.GLushort{1, 2, 3, 3, 4, 1, 0, 7, 6, 6, 0, 5}\r\n\r\n\t// Snake\r\n\tShapes[3].vertices = []gl.GLfloat{-1.5, -1, -1.5, 0, -0.5, 0, -0.5, 1, 1.5, 1, 1.5, 0, 0.5, 0, 0.5, -1}\r\n\tShapes[3].elements = []gl.GLushort{0, 1, 6, 6, 7, 0, 2, 3, 4, 4, 5, 2}\r\n\r\n\t// Now fill out the rest automatically.\r\n\t// FIXME why doesn't using _, shape in this loop work ?\r\n\tfor i := range Shapes {\r\n\t\tShapes[i].vao = gl.GenVertexArray()\r\n\t\tShapes[i].vao.Bind()\r\n\t\tShapes[i].vbo = gl.GenBuffer()\r\n\t\tShapes[i].vbo.Bind(gl.ARRAY_BUFFER)\r\n\t\tgl.BufferData(gl.ARRAY_BUFFER, len(Shapes[i].vertices)*4, Shapes[i].vertices, gl.STATIC_DRAW)\r\n\t\tShapes[i].elementBuffer = gl.GenBuffer()\r\n\t\tShapes[i].elementBuffer.Bind(gl.ELEMENT_ARRAY_BUFFER)\r\n\t\tgl.BufferData(gl.ELEMENT_ARRAY_BUFFER, len(Shapes[i].elements)*2, Shapes[i].elements, gl.STATIC_DRAW)\r\n\t\tShapes[i].numElements = len(Shapes[i].elements)\r\n\r\n\t\tvertexAttribArray := shaderProgram.GetAttribLocation(\"position\")\r\n\t\tvertexAttribArray.AttribPointer(2, gl.FLOAT, false, 0, uintptr(0))\r\n\t\tvertexAttribArray.EnableArray()\r\n\t}\r\n}", "func (d *Data) Render() error {\n\n\tvar err error\n\n\t// Read the CA certificate:\n\tif err = d.caCert(); err != nil {\n\t\treturn err\n\t}\n\n\t// Forge the Zookeeper URL:\n\td.forgeZookeeperURL()\n\n\t// REX-Ray configuration snippet:\n\td.rexraySnippet()\n\n\t// Role-based parsing:\n\tt := template.New(\"udata\")\n\n\tswitch d.Role {\n\tcase \"master\":\n\t\tt, err = t.Parse(templMaster)\n\tcase \"node\":\n\t\tt, err = t.Parse(templNode)\n\tcase \"edge\":\n\t\tt, err = t.Parse(templEdge)\n\t}\n\n\tif err != nil {\n\t\tlog.WithField(\"cmd\", \"udata\").Error(err)\n\t\treturn err\n\t}\n\n\t// Apply parsed template to data object:\n\tif d.GzipUdata {\n\t\tlog.WithFields(log.Fields{\"cmd\": \"udata\", \"id\": d.Role + \"-\" + d.HostID}).\n\t\t\tInfo(\"- Rendering gzipped cloud-config template\")\n\t\tw := gzip.NewWriter(os.Stdout)\n\t\tdefer w.Close()\n\t\tif err = t.Execute(w, d); err != nil {\n\t\t\tlog.WithField(\"cmd\", \"udata\").Error(err)\n\t\t\treturn err\n\t\t}\n\t} else {\n\t\tlog.WithField(\"cmd\", \"udata\").Info(\"- Rendering plain text cloud-config template\")\n\t\tif err = t.Execute(os.Stdout, d); err != nil {\n\t\t\tlog.WithField(\"cmd\", \"udata\").Error(err)\n\t\t\treturn err\n\t\t}\n\t}\n\n\t// Return on success:\n\treturn nil\n}", "func DrawRangeElements(mode uint32, start uint32, end uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n C.glowDrawRangeElements(gpDrawRangeElements, (C.GLenum)(mode), (C.GLuint)(start), (C.GLuint)(end), (C.GLsizei)(count), (C.GLenum)(xtype), indices)\n}", "func (v *View) Render(w http.ResponseWriter, r *http.Request, data interface{}) {\n\tw.Header().Set(\"Content-Type\", \"text/html\")\n\tvar vd Data\n\tswitch d := data.(type) {\n\tcase Data:\n\t\tvd = d\n\tdefault:\n\t\tvd = Data{\n\t\t\tYield: data,\n\t\t}\n\t}\n\tvd.User = context.User(r.Context())\n\tvar buf bytes.Buffer\n\terr := v.Template.ExecuteTemplate(&buf, v.Layout, vd)\n\tif err != nil {\n\t\thttp.Error(w, \"Something went wrong. If the problem persists, please \"+\n\t\t\t\"email [email protected]\", http.StatusInternalServerError)\n\t\treturn\n\t}\n\t// If we get here that means our template executed correctly and we can coy\n\t// the buffer to the ResponseWriter.\n\tio.Copy(w, &buf)\n}", "func DrawElements(mode Enum, count Sizei, kind Enum, indices unsafe.Pointer) {\n\tcmode, _ := (C.GLenum)(mode), cgoAllocsUnknown\n\tccount, _ := (C.GLsizei)(count), cgoAllocsUnknown\n\tckind, _ := (C.GLenum)(kind), cgoAllocsUnknown\n\tcindices, _ := (unsafe.Pointer)(unsafe.Pointer(indices)), cgoAllocsUnknown\n\tC.glDrawElements(cmode, ccount, ckind, cindices)\n}", "func Text(v interface{}) HTML {\n return HTML(\"\\n\" + html.EscapeString(fmt.Sprint(v)))\n}", "func render(m diag.Message, colorize bool) string {\n\treturn fmt.Sprintf(\"%s%v%s [%v]%s %s\",\n\t\tcolorPrefix(m, colorize), m.Type.Level(), colorSuffix(colorize),\n\t\tm.Type.Code(), m.Origin(), fmt.Sprintf(m.Type.Template(), m.Parameters...),\n\t)\n}", "func (val *float32ArrayValue) String() string {\n\tvar buffer strings.Builder\n\tfor _, v := range *val {\n\t\tif buffer.Len() != 0 {\n\t\t\tbuffer.WriteString(\", \")\n\t\t}\n\t\tfmt.Fprintf(&buffer, \"%v\", v)\n\t}\n\treturn buffer.String()\n}", "func (c *Context) Data(data interface{}, total ...int64) {\n\tc.responseFormat.SetData(data, total...)\n}", "func Render(colorCode int, fontSize int, content string) string {\n\treturn \"\\033[\" + strconv.Itoa(fontSize) + \";\" + strconv.Itoa(colorCode) + \"m\" + content + reset\n}", "func ShaderBinary(count int32, shaders *uint32, binaryformat uint32, binary unsafe.Pointer, length int32) {\n C.glowShaderBinary(gpShaderBinary, (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(shaders)), (C.GLenum)(binaryformat), binary, (C.GLsizei)(length))\n}", "func DrawRangeElements(mode uint32, start uint32, end uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n\tsyscall.Syscall6(gpDrawRangeElements, 6, uintptr(mode), uintptr(start), uintptr(end), uintptr(count), uintptr(xtype), uintptr(indices))\n}", "func (c *curve) data(x, y *mod.Int) ([]byte, error) {\n\tb := c.encodePoint(x, y)\n\tdl := int(b[0])\n\tif dl > c.embedLen() {\n\t\treturn nil, errors.New(\"invalid embedded data length\")\n\t}\n\treturn b[1 : 1+dl], nil\n}", "func ArrayElement(i int32) {\n\tC.glowArrayElement(gpArrayElement, (C.GLint)(i))\n}", "func (c *Client) ShowArrayPrism(ctx context.Context, path string, anyArray []interface{}, boolArray []bool, dateTimeArray []time.Time, intArray []int, numArray []float64, stringArray []string, uuidArray []uuid.UUID) (*http.Response, error) {\n\treq, err := c.NewShowArrayPrismRequest(ctx, path, anyArray, boolArray, dateTimeArray, intArray, numArray, stringArray, uuidArray)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\treturn c.Client.Do(ctx, req)\n}", "func (self *Graphics) _renderCanvasI(args ...interface{}) {\n self.Object.Call(\"_renderCanvas\", args)\n}", "func (t *TemplateRenderer) Render(w io.Writer, name string, data interface{}, c echo.Context) error {\n\n\t// Add global methods if data is a map\n\tif viewContext, isMap := data.(map[string]interface{}); isMap {\n\t\tviewContext[\"reverse\"] = c.Echo().Reverse\n\t}\n\n\treturn t.templates.ExecuteTemplate(w, name, data)\n}", "func (t *TemplateRenderer) Render(w io.Writer, name string, data interface{}, c echo.Context) error {\n\n\t// Add global methods if data is a map\n\tif viewContext, isMap := data.(map[string]interface{}); isMap {\n\t\tviewContext[\"reverse\"] = c.Echo().Reverse\n\t}\n\n\treturn t.templates.ExecuteTemplate(w, name, data)\n}", "func (t *TemplateRenderer) Render(w io.Writer, name string, data interface{}, c echo.Context) error {\n\n\t// Add global methods if data is a map\n\tif viewContext, isMap := data.(map[string]interface{}); isMap {\n\t\tviewContext[\"reverse\"] = c.Echo().Reverse\n\t}\n\n\treturn t.templates.ExecuteTemplate(w, name, data)\n}", "func (t *TemplateRenderer) Render(w io.Writer, name string, data interface{}, c echo.Context) error {\n\n\t// Add global methods if data is a map\n\tif viewContext, isMap := data.(map[string]interface{}); isMap {\n\t\tviewContext[\"reverse\"] = c.Echo().Reverse\n\t}\n\n\treturn t.templates.ExecuteTemplate(w, name, data)\n}", "func (t *TemplateRenderer) Render(w io.Writer, name string, data interface{}, c echo.Context) error {\n\n\t// Add global methods if data is a map\n\tif viewContext, isMap := data.(map[string]interface{}); isMap {\n\t\tviewContext[\"reverse\"] = c.Echo().Reverse\n\t}\n\n\treturn t.templates.ExecuteTemplate(w, name, data)\n}" ]
[ "0.56156594", "0.5546596", "0.5306737", "0.5284355", "0.5284355", "0.52796394", "0.51517177", "0.5142914", "0.51102394", "0.5074229", "0.5061546", "0.5033242", "0.50011086", "0.4997596", "0.49925417", "0.49570242", "0.49398518", "0.49398518", "0.4935131", "0.4933747", "0.493295", "0.49309745", "0.49085972", "0.4904153", "0.48921916", "0.48858568", "0.48656058", "0.48571947", "0.48433802", "0.48209718", "0.48119172", "0.47872278", "0.4779039", "0.47622737", "0.47564888", "0.47521734", "0.47167233", "0.47015846", "0.4692606", "0.46852934", "0.46841973", "0.46837887", "0.46802568", "0.46718583", "0.46608126", "0.46519628", "0.46438843", "0.46420163", "0.46370393", "0.46262035", "0.46259227", "0.46255153", "0.46252993", "0.46228462", "0.4619395", "0.4603002", "0.45969155", "0.45949683", "0.45860448", "0.45839247", "0.45828092", "0.4580724", "0.4578785", "0.4577587", "0.45696667", "0.45695087", "0.45529068", "0.45435163", "0.4541337", "0.45367214", "0.45354703", "0.4531912", "0.4527208", "0.4525999", "0.45232576", "0.45231485", "0.45209008", "0.4519044", "0.4510555", "0.45094815", "0.4504615", "0.45007646", "0.4497594", "0.44961888", "0.4492909", "0.44899026", "0.44887972", "0.44851753", "0.4481842", "0.4478514", "0.4471393", "0.4470815", "0.44662407", "0.44601682", "0.44575918", "0.44536218", "0.44528934", "0.44528934", "0.44528934", "0.44528934", "0.44528934" ]
0.0
-1
draw multiple instances of a range of elements
func DrawArraysInstanced(mode uint32, first int32, count int32, instancecount int32) { C.glowDrawArraysInstanced(gpDrawArraysInstanced, (C.GLenum)(mode), (C.GLint)(first), (C.GLsizei)(count), (C.GLsizei)(instancecount)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func DrawRangeElements(mode uint32, start uint32, end uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n\tsyscall.Syscall6(gpDrawRangeElements, 6, uintptr(mode), uintptr(start), uintptr(end), uintptr(count), uintptr(xtype), uintptr(indices))\n}", "func DrawRangeElements(mode uint32, start uint32, end uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n C.glowDrawRangeElements(gpDrawRangeElements, (C.GLenum)(mode), (C.GLuint)(start), (C.GLuint)(end), (C.GLsizei)(count), (C.GLenum)(xtype), indices)\n}", "func DrawRangeElements(mode uint32, start uint32, end uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n\tC.glowDrawRangeElements(gpDrawRangeElements, (C.GLenum)(mode), (C.GLuint)(start), (C.GLuint)(end), (C.GLsizei)(count), (C.GLenum)(xtype), indices)\n}", "func DrawRangeElements(mode uint32, start uint32, end uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n\tC.glowDrawRangeElements(gpDrawRangeElements, (C.GLenum)(mode), (C.GLuint)(start), (C.GLuint)(end), (C.GLsizei)(count), (C.GLenum)(xtype), indices)\n}", "func DrawRangeElementsBaseVertex(mode uint32, start uint32, end uint32, count int32, xtype uint32, indices unsafe.Pointer, basevertex int32) {\n C.glowDrawRangeElementsBaseVertex(gpDrawRangeElementsBaseVertex, (C.GLenum)(mode), (C.GLuint)(start), (C.GLuint)(end), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLint)(basevertex))\n}", "func DrawRangeElementsBaseVertex(mode uint32, start uint32, end uint32, count int32, xtype uint32, indices unsafe.Pointer, basevertex int32) {\n\tsyscall.Syscall9(gpDrawRangeElementsBaseVertex, 7, uintptr(mode), uintptr(start), uintptr(end), uintptr(count), uintptr(xtype), uintptr(indices), uintptr(basevertex), 0, 0)\n}", "func DrawRangeElementsBaseVertex(mode uint32, start uint32, end uint32, count int32, xtype uint32, indices unsafe.Pointer, basevertex int32) {\n\tC.glowDrawRangeElementsBaseVertex(gpDrawRangeElementsBaseVertex, (C.GLenum)(mode), (C.GLuint)(start), (C.GLuint)(end), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLint)(basevertex))\n}", "func DrawRangeElementsBaseVertex(mode uint32, start uint32, end uint32, count int32, xtype uint32, indices unsafe.Pointer, basevertex int32) {\n\tC.glowDrawRangeElementsBaseVertex(gpDrawRangeElementsBaseVertex, (C.GLenum)(mode), (C.GLuint)(start), (C.GLuint)(end), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLint)(basevertex))\n}", "func MultiDrawElements(mode uint32, count *int32, xtype uint32, indices *unsafe.Pointer, drawcount int32) {\n\tsyscall.Syscall6(gpMultiDrawElements, 5, uintptr(mode), uintptr(unsafe.Pointer(count)), uintptr(xtype), uintptr(unsafe.Pointer(indices)), uintptr(drawcount), 0)\n}", "func (el *Fill) Rect() {}", "func DrawElements(mode uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n\tsyscall.Syscall6(gpDrawElements, 4, uintptr(mode), uintptr(count), uintptr(xtype), uintptr(indices), 0, 0)\n}", "func (this *Parser) Range(start, end int) *OrderedChoice {\r\n\texps := make([]Exp, (end - start)+1)\r\n\tfor i := start; i <= end; i++ {\r\n\t\texps[i-start] = &Terminal{this,i}\r\n\t}\r\n\treturn &OrderedChoice{this,exps}\r\n}", "func (rg Range) Iter(fn func(Point)) {\n\tfor y := rg.Min.Y; y < rg.Max.Y; y++ {\n\t\tfor x := rg.Min.X; x < rg.Max.X; x++ {\n\t\t\tp := Point{X: x, Y: y}\n\t\t\tfn(p)\n\t\t}\n\t}\n}", "func DrawElementsInstanced(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32) {\n C.glowDrawElementsInstanced(gpDrawElementsInstanced, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLsizei)(instancecount))\n}", "func drawFiveRectangles(ops *op.Ops) {\n\t// Record drawRedRect operations into the macro.\n\tmacro := op.Record(ops)\n\tdrawRedRect(ops)\n\tc := macro.Stop()\n\n\t// “Play back” the macro 5 times, each time\n\t// translated vertically 20px and horizontally 110 pixels.\n\tfor i := 0; i < 5; i++ {\n\t\tc.Add(ops)\n\t\top.Offset(image.Pt(110, 20)).Add(ops)\n\t}\n}", "func MultiDrawElements(mode uint32, count *int32, xtype uint32, indices *unsafe.Pointer, drawcount int32) {\n C.glowMultiDrawElements(gpMultiDrawElements, (C.GLenum)(mode), (*C.GLsizei)(unsafe.Pointer(count)), (C.GLenum)(xtype), indices, (C.GLsizei)(drawcount))\n}", "func (countIndex *CountIndex) Range(topLeft Point, bottomRight Point) []Point {\n\tcounters := countIndex.index.Range(topLeft, bottomRight)\n\n\tpoints := make([]Point, 0)\n\n\tfor _, c := range counters {\n\t\tif c.(counter).Point() != nil {\n\t\t\tpoints = append(points, c.(counter).Point())\n\t\t}\n\t}\n\n\treturn points\n}", "func DrawElements(mode uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n C.glowDrawElements(gpDrawElements, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices)\n}", "func drawOverlappingRectangles(ops *op.Ops) {\n\t// Draw a red rectangle.\n\tcl := clip.Rect{Max: image.Pt(100, 50)}.Push(ops)\n\tpaint.ColorOp{Color: color.NRGBA{R: 0x80, A: 0xFF}}.Add(ops)\n\tpaint.PaintOp{}.Add(ops)\n\tcl.Pop()\n\n\t// Draw a green rectangle.\n\tcl = clip.Rect{Max: image.Pt(50, 100)}.Push(ops)\n\tpaint.ColorOp{Color: color.NRGBA{G: 0x80, A: 0xFF}}.Add(ops)\n\tpaint.PaintOp{}.Add(ops)\n\tcl.Pop()\n}", "func DrawElements(mode Enum, count int, ty Enum, offset int) {\n\tgl.DrawElements(uint32(mode), int32(count), uint32(ty), gl.PtrOffset(offset))\n}", "func Range(min, max int) (out []Triplet) {\n\tout0 := append(out, Triplet{0, 0, 0})\n\tfor a := min; a <= max; a++ {\n\t\tfor b := a; b <= max; b++ {\n\t\t\tfor c := b; c <= max; c++ {\n\t\t\t\tif c*c == a*a+b*b {\n\t\t\t\t\tout0 = append(out0, Triplet{a, b, c})\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\tout = out0[1:]\n\treturn\n}", "func Range(min, max int) []Triplet {\n\treturn findTrippleats(min, max, []func(x, y, z int) bool{\n\t\tfunc(x, y, z int) bool { return isTriplet(x, y, z) },\n\t})\n}", "func DrawElementsInstanced(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32) {\n\tC.glowDrawElementsInstanced(gpDrawElementsInstanced, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLsizei)(instancecount))\n}", "func DrawElementsInstanced(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32) {\n\tC.glowDrawElementsInstanced(gpDrawElementsInstanced, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLsizei)(instancecount))\n}", "func MultiDrawElementsIndirect(mode uint32, xtype uint32, indirect unsafe.Pointer, drawcount int32, stride int32) {\n\tsyscall.Syscall6(gpMultiDrawElementsIndirect, 5, uintptr(mode), uintptr(xtype), uintptr(indirect), uintptr(drawcount), uintptr(stride), 0)\n}", "func MultiDrawElements(mode uint32, count *int32, xtype uint32, indices *unsafe.Pointer, drawcount int32) {\n\tC.glowMultiDrawElements(gpMultiDrawElements, (C.GLenum)(mode), (*C.GLsizei)(unsafe.Pointer(count)), (C.GLenum)(xtype), indices, (C.GLsizei)(drawcount))\n}", "func MultiDrawElements(mode uint32, count *int32, xtype uint32, indices *unsafe.Pointer, drawcount int32) {\n\tC.glowMultiDrawElements(gpMultiDrawElements, (C.GLenum)(mode), (*C.GLsizei)(unsafe.Pointer(count)), (C.GLenum)(xtype), indices, (C.GLsizei)(drawcount))\n}", "func plotfunc(deck *generate.Deck, left, right, top, bottom float64, data pf, size float64, color string) {\n\tix := left\n\tiy := bottom\n\tfor xd := data.xmin; xd <= data.xmax; xd += data.xint {\n\t\txp := vmap(xd, data.xmin, data.xmax, left, right)\n\t\typ := vmap(data.function(xd), data.ymin, data.ymax, bottom, top)\n\t\tdeck.Line(ix, iy, xp, yp, 0.2, color)\n\t\tix = xp\n\t\tiy = yp\n\t}\n}", "func (p *GIFPrinter) drawExact(target *image.Paletted, source image.Image) {\n\tbounds := source.Bounds()\n\tfor y := bounds.Min.Y; y < bounds.Max.Y; y++ {\n\t\tfor x := bounds.Min.X; x < bounds.Max.X; x++ {\n\t\t\ttarget.Set(x, y, source.At(x, y))\n\t\t}\n\t}\n}", "func (b *raftBadger) generateRanges(min, max uint64, batchSize int64) []IteratorRange {\n\tnSegments := int(math.Round(float64((max - min) / uint64(batchSize))))\n\tsegments := []IteratorRange{}\n\tif (max - min) <= uint64(batchSize) {\n\t\tsegments = append(segments, IteratorRange{from: min, to: max})\n\t\treturn segments\n\t}\n\tfor len(segments) < nSegments {\n\t\tnextMin := min + uint64(batchSize)\n\t\tsegments = append(segments, IteratorRange{from: min, to: nextMin})\n\t\tmin = nextMin + 1\n\t}\n\tsegments = append(segments, IteratorRange{from: min, to: max})\n\treturn segments\n}", "func visRangeOffsets(rng Range) string {\n\tvar buf bytes.Buffer\n\tif rng.End.Byte < rng.Start.Byte {\n\t\t// Should never happen, but we'll visualize it anyway so we can\n\t\t// more easily debug failing tests.\n\t\tfor i := 0; i < rng.End.Byte; i++ {\n\t\t\tbuf.WriteByte(' ')\n\t\t}\n\t\tfor i := rng.End.Byte; i < rng.Start.Byte; i++ {\n\t\t\tbuf.WriteByte('!')\n\t\t}\n\t\treturn buf.String()\n\t}\n\n\tfor i := 0; i < rng.Start.Byte; i++ {\n\t\tbuf.WriteByte(' ')\n\t}\n\tfor i := rng.Start.Byte; i < rng.End.Byte; i++ {\n\t\tbuf.WriteByte('#')\n\t}\n\treturn buf.String()\n}", "func (w *Walker) iterateRange(start, end uintptr) {\n\tif start%pteSize != 0 {\n\t\tpanic(\"unaligned start\")\n\t}\n\tif end < start {\n\t\tpanic(\"start > end\")\n\t}\n\tif start < lowerTop {\n\t\tif end <= lowerTop {\n\t\t\tw.iterateRangeCanonical(start, end)\n\t\t} else if end > lowerTop && end <= upperBottom {\n\t\t\tif w.visitor.requiresAlloc() {\n\t\t\t\tpanic(\"alloc spans non-canonical range\")\n\t\t\t}\n\t\t\tw.iterateRangeCanonical(start, lowerTop)\n\t\t} else {\n\t\t\tif w.visitor.requiresAlloc() {\n\t\t\t\tpanic(\"alloc spans non-canonical range\")\n\t\t\t}\n\t\t\tif !w.iterateRangeCanonical(start, lowerTop) {\n\t\t\t\treturn\n\t\t\t}\n\t\t\tw.iterateRangeCanonical(upperBottom, end)\n\t\t}\n\t} else if start < upperBottom {\n\t\tif end <= upperBottom {\n\t\t\tif w.visitor.requiresAlloc() {\n\t\t\t\tpanic(\"alloc spans non-canonical range\")\n\t\t\t}\n\t\t} else {\n\t\t\tif w.visitor.requiresAlloc() {\n\t\t\t\tpanic(\"alloc spans non-canonical range\")\n\t\t\t}\n\t\t\tw.iterateRangeCanonical(upperBottom, end)\n\t\t}\n\t} else {\n\t\tw.iterateRangeCanonical(start, end)\n\t}\n}", "func lattice(xp, yp, w, h, size, hspace, vspace, n int, bgcolor string) {\n\tif bgcolor == \"\" {\n\t\tcanvas.Rect(0, 0, w, h, randcolor())\n\t} else {\n\t\tcanvas.Rect(0, 0, w, h, \"fill:\"+bgcolor)\n\t}\n\ty := yp\n\tfor r := 0; r < n; r++ {\n\t\tfor x := xp; x < w; x += hspace {\n\t\t\trcube(x, y, size)\n\t\t}\n\t\ty += vspace\n\t}\n}", "func Test_DomRange(t *testing.T) {\n\tsetup()\n\tdefer teardown()\n\tlog(\"DomRange and AddRange\")\n\n\t//1..10 in 1..10+5\n\tdomRange_test(t, []int{1, 10}, []int{1, 10}, 5, []int{6, 10})\n\t//1..10 in 1..10+0\n\tdomRange_test(t, []int{1, 10}, []int{1, 10}, 0, []int{1, 10})\n\t//1..10 in 1..10-5\n\tdomRange_test(t, []int{1, 10}, []int{1, 10}, -5, []int{1, 5})\n\t//1..10 in 20..30+2\n\tdomRange_test(t, []int{1, 10}, []int{20, 30}, 2, []int{})\n}", "func HexRange(center hex, radius int) []hex {\n\n\tvar results = make([]hex, 0)\n\n\tif radius >= 0 {\n\t\tfor dx := -radius; dx <= radius; dx++ {\n\n\t\t\tfor dy := math.Max(float64(-radius), float64(-dx-radius)); dy <= math.Min(float64(radius), float64(-dx+radius)); dy++ {\n\t\t\t\tresults = append(results, HexAdd(center, NewHex(int(dx), int(dy))))\n\t\t\t}\n\t\t}\n\t}\n\n\treturn results\n\n}", "func grid(deck *generate.Deck, left, right, top, bottom, xinterval, yinterval, size float64, color string) {\n\tfor yp := top; yp >= bottom; yp -= xinterval {\n\t\tdeck.Line(left, yp, right, yp, size, color, 30)\n\t}\n\tfor xp := left; xp <= right; xp += yinterval {\n\t\tdeck.Line(xp, top, xp, bottom, size, color, 30)\n\t}\n}", "func DrawN(count int, opts ...options) (result []string, err error) {\n\tif count <= 0 {\n\t\tcount = 1\n\t}\n\n\tfor i := 0; i < count; i++ {\n\t\toutput, err := Draw(opts...)\n\t\tif err != nil {\n\t\t\treturn nil, err\n\t\t}\n\t\tresult = append(result, output)\n\t}\n\n\treturn\n}", "func Range(min, max int) []Triplet {\n\tvar triplets []Triplet\n\n\tfor a := min; a <= max; a++ {\n\t\tfor b := a; b <= max; b++ {\n\t\t\tc := int(math.Sqrt(float64(a*a + b*b)))\n\t\t\tif c*c == a*a+b*b && c <= max && a >= min && b >= min && c >= min {\n\t\t\t\ttriplets = append(triplets, Triplet{a, b, c})\n\t\t\t}\n\t\t}\n\t}\n\n\treturn triplets\n}", "func (c *Canvas) printElements() {\n\tfor _, es := range c.elements {\n\t\tc.Println(\"<g>\")\n\t\tfor _, e := range es {\n\t\t\tc.Println(e.Usebg())\n\t\t}\n\t\tfor _, e := range es {\n\t\t\tc.Println(e.Use())\n\t\t}\n\t\tc.Println(\"</g>\")\n\t}\n}", "func (v *VerbalExpression) Range(args ...interface{}) *VerbalExpression {\n\tif len(args)%2 != 0 {\n\t\tlog.Panicf(\"Range: not even args number\")\n\t}\n\n\tparts := make([]string, 3)\n\tapp := \"\"\n\tfor i := 0; i < len(args); i++ {\n\t\tapp += tostring(args[i])\n\t\tif i%2 != 0 {\n\t\t\tparts = append(parts, quote(app))\n\t\t\tapp = \"\"\n\t\t} else {\n\t\t\tapp += \"-\"\n\t\t}\n\t}\n\treturn v.add(\"[\" + strings.Join(parts, \"\") + \"]\")\n}", "func (bush *KDBush) Range(minX, minY, maxX, maxY float64) []int {\n\tstack := []int{0, len(bush.idxs) - 1, 0}\n\tresult := []int{}\n\tvar x, y float64\n\n\tfor len(stack) > 0 {\n\t\taxis := stack[len(stack)-1]\n\t\tstack = stack[:len(stack)-1]\n\t\tright := stack[len(stack)-1]\n\t\tstack = stack[:len(stack)-1]\n\t\tleft := stack[len(stack)-1]\n\t\tstack = stack[:len(stack)-1]\n\n\t\tif right-left <= bush.NodeSize {\n\t\t\tfor i := left; i <= right; i++ {\n\t\t\t\tx = bush.coords[2*i]\n\t\t\t\ty = bush.coords[2*i+1]\n\t\t\t\tif x >= minX && x <= maxX && y >= minY && y <= maxY {\n\t\t\t\t\tresult = append(result, bush.idxs[i])\n\t\t\t\t}\n\t\t\t}\n\t\t\tcontinue\n\t\t}\n\n\t\tm := floor(float64(left+right) / 2.0)\n\n\t\tx = bush.coords[2*m]\n\t\ty = bush.coords[2*m+1]\n\n\t\tif x >= minX && x <= maxX && y >= minY && y <= maxY {\n\t\t\tresult = append(result, bush.idxs[m])\n\t\t}\n\n\t\tnextAxis := (axis + 1) % 2\n\n\t\tif (axis == 0 && minX <= x) || (axis != 0 && minY <= y) {\n\t\t\tstack = append(stack, left)\n\t\t\tstack = append(stack, m-1)\n\t\t\tstack = append(stack, nextAxis)\n\t\t}\n\n\t\tif (axis == 0 && maxX >= x) || (axis != 0 && maxY >= y) {\n\t\t\tstack = append(stack, m+1)\n\t\t\tstack = append(stack, right)\n\t\t\tstack = append(stack, nextAxis)\n\t\t}\n\n\t}\n\treturn result\n}", "func main() {\n\trand.Seed(time.Now().Unix())\n\tcanvas.Decimals=0\n\tcanvas.Start(width, height)\n\tcanvas.Rect(0, 0, width, height)\n\n\tw, h, gutter := 24.0, 18.0, 5.0\n\trows, cols := 16.0, 16.0\n\ttop, left := 20.0, 20.0\n\n\tfor r, x := 0.0, left; r < rows; r++ {\n\t\tfor c, y := 0.0, top; c < cols; c++ {\n\t\t\tcanvas.Rect(x, y, w, h,\n\t\t\t\tcanvas.RGB(rand.Intn(255), rand.Intn(255), rand.Intn(255)))\n\t\t\ty += (h + gutter)\n\t\t}\n\t\tx += (w + gutter)\n\t}\n\tcanvas.End()\n}", "func DrawElements(mode uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n\tC.glowDrawElements(gpDrawElements, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices)\n}", "func DrawElements(mode uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n\tC.glowDrawElements(gpDrawElements, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices)\n}", "func Range(min, max int) (triplets []Triplet) {\n\tfor i := min; i <= max; i++ {\n\t\tfor j := i; j <= max; j++ {\n\t\t\tcSqr := (i * i) + (j * j)\n\t\t\tc := math.Sqrt(float64(cSqr))\n\t\t\tif math.Abs(c-math.Floor(c)) <= 0.000000001 && c <= float64(max) {\n\t\t\t\ttriplets = append(triplets, Triplet{i, j, int(c)})\n\t\t\t}\n\t\t}\n\t}\n\treturn triplets\n}", "func DrawElementsInstancedBaseInstance(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32, baseinstance uint32) {\n\tsyscall.Syscall6(gpDrawElementsInstancedBaseInstance, 6, uintptr(mode), uintptr(count), uintptr(xtype), uintptr(indices), uintptr(instancecount), uintptr(baseinstance))\n}", "func Range(min, max int) []Triplet {\n\ttriplets := []Triplet{}\n\n\tfor a := min; a < max; a++ {\n\t\tfor b := min + 1; b < max; b++ {\n\t\t\tfor c := min + 2; c <= max; c++ {\n\t\t\t\tif a*a+b*b == c*c {\n\t\t\t\t\ttriplets = SortedTriplet(a, b, c).AppendIfUniqueIn(triplets)\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn triplets\n}", "func (gd Grid) Slice(rg Range) Grid {\n\tif rg.Min.X < 0 {\n\t\trg.Min.X = 0\n\t}\n\tif rg.Min.Y < 0 {\n\t\trg.Min.Y = 0\n\t}\n\tmax := gd.Rg.Size()\n\tif rg.Max.X > max.X {\n\t\trg.Max.X = max.X\n\t}\n\tif rg.Max.Y > max.Y {\n\t\trg.Max.Y = max.Y\n\t}\n\tmin := gd.Rg.Min\n\trg.Min = rg.Min.Add(min)\n\trg.Max = rg.Max.Add(min)\n\treturn Grid{innerGrid{Ug: gd.Ug, Rg: rg}}\n}", "func DrawElementsInstancedBaseInstance(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32, baseinstance uint32) {\n C.glowDrawElementsInstancedBaseInstance(gpDrawElementsInstancedBaseInstance, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLsizei)(instancecount), (C.GLuint)(baseinstance))\n}", "func Range(min, max int) []Triplet {\n\ttriplets := make([]Triplet, 0)\n\n\tfor a := min; a <= max; a++ {\n\t\tfor b := a; b <= max; b++ {\n\t\t\tfor c := b; c <= max; c++ {\n\t\t\t\tif (a*a + b*b) == c*c {\n\t\t\t\t\ttriplets = append(triplets, Triplet{a: a, b: b, c: c})\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\treturn triplets\n}", "func (rl RangeList) Print() {\n\tfor i := 0; i < len(rl.list); i++ {\n\t\tfmt.Printf(\"%s%d, %d%s \", \"[\", rl.list[i][leftIdx], rl.list[i][rightIdx], \")\")\n\t}\n\tfmt.Println()\n}", "func (el *Fill) TSpan() {}", "func Range(min, max int) []Triplet {\n\tvar t []Triplet\n\tvar a, b, c int\n\tfor a = min; a <= max; a++ {\n\t\tfor b = a + 1; b <= max; b++ {\n\t\t\tfor c = b + 1; c <= max; c++ {\n\t\t\t\tif isPythagoreanTriangle(Triplet{a, b, c}) {\n\t\t\t\t\tt = append(t, Triplet{a, b, c})\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\treturn t\n}", "func DrawElementsInstancedBaseVertex(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32, basevertex int32) {\n C.glowDrawElementsInstancedBaseVertex(gpDrawElementsInstancedBaseVertex, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLsizei)(instancecount), (C.GLint)(basevertex))\n}", "func drawGrid(pdf *gofpdf.Fpdf) {\n w, h := pdf.GetPageSize()\n pdf.SetFont(\"courier\", \"\", 12)\n pdf.SetTextColor(80, 80, 80)\n pdf.SetDrawColor(200, 200, 200)\n for x := 0.0; x < w; x = x + (w / 20.0) {\n pdf.SetTextColor(200, 200, 200)\n pdf.Line(x, 0, x, h)\n _, lineHt := pdf.GetFontSize()\n pdf.Text(x, lineHt, fmt.Sprintf(\"%d\", int(x)))\n }\n for y := 0.0; y < h; y = y + (w / 20.0) {\n pdf.SetTextColor(80, 80, 80)\n pdf.Line(0, y, w, y)\n pdf.Text(0, y, fmt.Sprintf(\"%d\", int(y)))\n }\n}", "func (c *Container) Draw(r Region, delta float64) {\n}", "func DrawElementsInstancedBaseVertex(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32, basevertex int32) {\n\tsyscall.Syscall6(gpDrawElementsInstancedBaseVertex, 6, uintptr(mode), uintptr(count), uintptr(xtype), uintptr(indices), uintptr(instancecount), uintptr(basevertex))\n}", "func nodesAndOffsetToRange(numNodes uint64, offset int64, res []Resource) ResourceListPair {\n\tnumNodesMin := getOffsetNodeCount(numNodes, -offset, math.Floor)\n\tnumNodesMax := getOffsetNodeCount(numNodes, offset, math.Ceil)\n\treturn ResourceListPair{\n\t\tlower: calculateResources(numNodesMin, res),\n\t\tupper: calculateResources(numNodesMax, res),\n\t}\n}", "func MultiDrawElementsIndirect(mode uint32, xtype uint32, indirect unsafe.Pointer, drawcount int32, stride int32) {\n C.glowMultiDrawElementsIndirect(gpMultiDrawElementsIndirect, (C.GLenum)(mode), (C.GLenum)(xtype), indirect, (C.GLsizei)(drawcount), (C.GLsizei)(stride))\n}", "func DrawElementsIndirect(mode uint32, xtype uint32, indirect unsafe.Pointer) {\n\tsyscall.Syscall(gpDrawElementsIndirect, 3, uintptr(mode), uintptr(xtype), uintptr(indirect))\n}", "func (r Rect) Draw(s SVG, a ...string) {\n\ts.Rect(r.x0, r.y0, r.x1, r.y1, a...)\n}", "func Range(min, max int) []Triplet {\n\treturn make([]Triplet, 0)\n}", "func (s *Set) Range(start, end int) (elements []Element) {\n\t// Handle negative indices\n\tif start < 0 {\n\t\tstart = s.Length() + start\n\t}\n\n\tif end < 0 {\n\t\tend = s.Length() + end\n\t}\n\n\titer := s.Each()\n\n\tfor iter.Next() && iter.Index() <= end {\n\t\tif iter.Index() >= start {\n\t\t\telements = append(elements, *iter.Value())\n\t\t}\n\t}\n\n\treturn\n}", "func displayCoords(coords Coords) {\n\tctx := gg.NewContext(IMG_WIDTH, IMG_HEIGHT)\n\tctx.SetColor(color.White)\n\tctx.DrawRectangle(0, 0, IMG_WIDTH, IMG_HEIGHT)\n\tctx.Fill()\n\tctx.SetColor(color.Black)\n\tctx.SetLineWidth(10)\n\tsegments := make([]Coords, 0)\n\tvar segment Coords = nil\n\tfor i := 0; i < len(coords); i += 1 {\n\t\tif coords[i] == [2]float64{0, 0} {\n\t\t\tif len(segment) > 0 {\n\t\t\t\tsegments = append(segments, segment)\n\t\t\t\tsegment = nil\n\t\t\t}\n\t\t} else {\n\t\t\tsegment = append(segment, coords[i])\n\t\t}\n\t}\n\tfor i := 0; i < len(segments); i += 1 {\n\t\tif len(segments[i]) == 1 {\n\t\t\tx := scale(int(segments[i][0][0]), HRM_MAX, IMG_WIDTH)\n\t\t\ty := scale(int(segments[i][0][1]), HRM_MAX, IMG_HEIGHT)\n\t\t\tctx.DrawPoint(x, y, 1)\n\t\t\tctx.Stroke()\n\t\t} else {\n\t\t\tfor j := 1; j < len(segments[i]); j += 1 {\n\t\t\t\tpoint := segments[i][j]\n\t\t\t\tx := scale(int(point[0]), HRM_MAX, IMG_WIDTH)\n\t\t\t\ty := scale(int(point[1]), HRM_MAX, IMG_HEIGHT)\n\t\t\t\tprevX := scale(int(segments[i][j - 1][0]), HRM_MAX, IMG_WIDTH)\n\t\t\t\tprevY := scale(int(segments[i][j - 1][1]), HRM_MAX, IMG_HEIGHT)\n\t\t\t\tctx.DrawLine(prevX, prevY, x, y)\n\t\t\t\tctx.StrokePreserve()\n\t\t\t}\n\t\t}\n\t}\n\tctx.SavePNG(\"out.png\")\n}", "func ShowMultiCursor(screen tcell.Screen, x, y, i int) {\n\tif i == 0 {\n\t\tscreen.ShowCursor(x, y)\n\t} else {\n\t\tr, _, _, _ := screen.GetContent(x, y)\n\t\tscreen.SetContent(x, y, r, nil, defStyle.Reverse(true))\n\t}\n}", "func Ranges(start, stop, step int) (r []int) {\n\tif step > 0 {\n\t\tfor start < stop {\n\t\t\tr = append(r, start)\n\t\t\tstart += step\n\t\t}\n\t\treturn\n\t} else if step < 0 {\n\t\tfor start > stop {\n\t\t\tr = append(r, start)\n\t\t\tstart += step\n\t\t}\n\t\treturn\n\t}\n\n\tpanic(fmt.Errorf(\"The step must not be 0\"))\n}", "func iterateObjects1DWithIndexes() {\n\tfmt.Println(\"*** iterateObjects1DWithIndexes\")\n\n\ttype Point struct {\n\t\tX int\n\t\tY int\n\t}\n\tpoints := [5]Point{\n\t\tPoint{1, 1},\n\t\tPoint{2, 2},\n\t\tPoint{3, 3},\n\t\tPoint{4, 4},\n\t\tPoint{5, 5},\n\t}\n\n\tfor i, e := range points {\n\t\tfmt.Printf(\"ints[%d]: %+v\\n\", i, e)\n\t}\n\tfmt.Println(\"\")\n}", "func (v *VerticalContainer) Draw(dst *ebiten.Image, bounds geo.Rect) {\n\ttotalWeight := 0.0\n\tfor _, e := range v.Elements {\n\t\ttotalWeight += e.Weight()\n\t}\n\theights := make([]float64, len(v.Elements))\n\tfor i, e := range v.Elements {\n\t\theights[i] = e.Weight() / totalWeight * bounds.H\n\t}\n\tsubBounds := bounds\n\tfor i, h := range heights {\n\t\tsubBounds.H = h\n\t\tv.Elements[i].Draw(dst, subBounds)\n\t\tsubBounds.Y += h\n\t}\n}", "func draw(window *sdl.Window, renderer *sdl.Renderer, grid [][]*square) {\n\trenderer.Clear()\n\trenderer.SetDrawColor(255, 255, 255, 1) // white\n\trenderer.FillRect(&sdl.Rect{0, 0, size, size})\n\n\tfor _, row := range grid {\n\t\tfor _, square := range row {\n\t\t\tsquare.drawSquare(renderer)\n\t\t}\n\t}\n\n\tdrawGrid(renderer)\n\trenderer.Present()\n}", "func DrawArraysInstanced(mode uint32, first int32, count int32, instancecount int32) {\n C.glowDrawArraysInstanced(gpDrawArraysInstanced, (C.GLenum)(mode), (C.GLint)(first), (C.GLsizei)(count), (C.GLsizei)(instancecount))\n}", "func Range(start, stop, step int) (r []int) {\n\tif step > 0 {\n\t\tfor start < stop {\n\t\t\tr = append(r, start)\n\t\t\tstart += step\n\t\t}\n\t\treturn\n\t} else if step < 0 {\n\t\tfor start > stop {\n\t\t\tr = append(r, start)\n\t\t\tstart += step\n\t\t}\n\t\treturn\n\t}\n\n\tpanic(\"The step is 0\")\n}", "func (rg Range) Lines(y0, y1 int) Range {\n\tnrg := rg\n\tnrg.Min.Y = rg.Min.Y + y0\n\tnrg.Max.Y = rg.Min.Y + y1\n\treturn rg.Intersect(nrg)\n}", "func rect(img *image.NRGBA, x1, y1, x2, y2 int, col color.Color) {\r\n\thLine(img, x1, y1, x2, col)\r\n\thLine(img, x1, y2, x2, col)\r\n\tvLine(img, x1, y1, y2, col)\r\n\tvLine(img, x2, y1, y2, col)\r\n}", "func drawEllipsis(x, y int, fg, bg termbox.Attribute) int {\n\tfor i := 0; i < 3; i++ {\n\t\ttermbox.SetCell(x, y, '.', fg, bg)\n\t\tx++\n\t}\n\treturn x\n}", "func DrawElementsInstancedBaseInstance(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32, baseinstance uint32) {\n\tC.glowDrawElementsInstancedBaseInstance(gpDrawElementsInstancedBaseInstance, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLsizei)(instancecount), (C.GLuint)(baseinstance))\n}", "func DrawElementsInstancedBaseInstance(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32, baseinstance uint32) {\n\tC.glowDrawElementsInstancedBaseInstance(gpDrawElementsInstancedBaseInstance, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLsizei)(instancecount), (C.GLuint)(baseinstance))\n}", "func DrawElementsInstancedBaseVertex(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32, basevertex int32) {\n\tC.glowDrawElementsInstancedBaseVertex(gpDrawElementsInstancedBaseVertex, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLsizei)(instancecount), (C.GLint)(basevertex))\n}", "func DrawElementsInstancedBaseVertex(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32, basevertex int32) {\n\tC.glowDrawElementsInstancedBaseVertex(gpDrawElementsInstancedBaseVertex, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLsizei)(instancecount), (C.GLint)(basevertex))\n}", "func PrintRing(r *ring.Ring, highlight int) {\n\tfor i := 0; i < r.Len(); i++ {\n\t\tif r.Value == highlight {\n\t\t\tfmt.Printf(\"(%d)\", r.Value)\n\t\t} else {\n\t\t\tfmt.Printf(\"%d\", r.Value)\n\t\t}\n\t\tif i < r.Len()-1 {\n\t\t\tfmt.Printf(\"->\")\n\t\t} else {\n\t\t\tfmt.Printf(\"\\n\")\n\t\t}\n\t\tr = r.Next()\n\t}\n}", "func (b *Board) draw() {\n\ts := b.Game.Screen\n\n\tfor i := b.y; i < len(b.Grid); i++ {\n\t\tfor j := b.x; j < len(b.Grid[0]); j++ {\n\t\t\tvalue := b.Grid[i][j]\n\t\t\tif value == 1 {\n\t\t\t\tcellStyle := tcell.StyleDefault.Foreground(b.Game.CellColor).Background(b.Game.Background)\n\t\t\t\ts.SetContent(j*2, i, tcell.RuneBlock, nil, cellStyle)\n\t\t\t\ts.SetContent(j*2+1, i, tcell.RuneBlock, nil, cellStyle)\n\t\t\t}\n\t\t}\n\t}\n}", "func MultiDrawElementsIndirect(mode uint32, xtype uint32, indirect unsafe.Pointer, drawcount int32, stride int32) {\n\tC.glowMultiDrawElementsIndirect(gpMultiDrawElementsIndirect, (C.GLenum)(mode), (C.GLenum)(xtype), indirect, (C.GLsizei)(drawcount), (C.GLsizei)(stride))\n}", "func MultiDrawElementsIndirect(mode uint32, xtype uint32, indirect unsafe.Pointer, drawcount int32, stride int32) {\n\tC.glowMultiDrawElementsIndirect(gpMultiDrawElementsIndirect, (C.GLenum)(mode), (C.GLenum)(xtype), indirect, (C.GLsizei)(drawcount), (C.GLsizei)(stride))\n}", "func (this *BoundingBox) AddRange(points []vec3.T) *BoundingBox {\n\tif points != nil {\n\t\tfor _, pt := range points {\n\t\t\tthis.Add(&pt)\n\t\t}\n\t}\n\n\treturn this\n}", "func PaintFold(foldList, seq []string) {\n\n\t//size is 100, so we draw 100*n squares\n\tw := 500\n\th := 500\n\tpic := CreateNewCanvas(w, h)\n\t//set parameters\n\tpic.SetLineWidth(1)\n\n\t//start from the center\n\tx := float64(w / 2)\n\ty := float64(h / 2)\n\tpic.gc.ArcTo(x, y, 5, 5, 0, 2*math.Pi)\n\tif seq[0] == \"H\" {\n\t\twhite := MakeColor(255, 255, 255)\n\t\tpic.SetFillColor(white)\n\t\tpic.Stroke() //draw a white circle for H\n\t} else {\n\t\tblack := MakeColor(0, 0, 0)\n\t\tpic.SetFillColor(black)\n\t\tpic.Stroke() //black circle for P\n\t}\n\t//now start drawing\n\tpic.MoveTo(x, y)\n\t//first direction is front\n\tangle := math.Pi / 2\n\tincrement := math.Pi / 2\n\t//loop over all commands\n\tfor i := 0; i < len(foldList); i++ {\n\t\tif foldList[i] == \"l\" { //front+left=left=pi\n\t\t\tangle += increment\n\t\t} else if foldList[i] == \"r\" { //front+right=right\n\t\t\tangle -= increment\n\t\t}\n\t\t//produce next point based on angels\n\t\tx += 10 * math.Cos(angle)\n\t\ty -= 10 * math.Sin(angle)\n\t\t//conncet two points\n\t\tpic.LineTo(x, y)\n\t\t//then next point,the same as above\n\t\tif seq[i+1] == \"H\" {\n\t\t\tpic.gc.ArcTo(x, y, 5, 5, 0, 2*math.Pi)\n\t\t\twhite := MakeColor(255, 255, 255)\n\t\t\tpic.SetFillColor(white)\n\t\t\tpic.Stroke() //draw a white circle for H\n\t\t} else {\n\t\t\tpic.gc.ArcTo(x, y, 5, 5, 0, 2*math.Pi)\n\t\t\tblack := MakeColor(0, 0, 0)\n\t\t\tpic.SetFillColor(black)\n\t\t\tpic.Stroke() //black circle for P\n\t\t}\n\t}\n\tpic.Stroke()\n\tpic.SaveToPNG(\"fold.png\")\n\n}", "func Range(args ...interface{}) Term {\n\treturn constructRootTerm(\"Range\", p.Term_RANGE, args, map[string]interface{}{})\n}", "func (r Ranges) At(i int) Range {\n\treturn Range{LowerBound: int(r[2*i]), UpperBound: int(r[2*i+1])}\n}", "func NewRange(x0, y0, x1, y1 int) Range {\n\tif x1 < x0 {\n\t\tx0, x1 = x1, x0\n\t}\n\tif y1 < y0 {\n\t\ty0, y1 = y1, y0\n\t}\n\treturn Range{Min: Point{X: x0, Y: y0}, Max: Point{X: x1, Y: y1}}\n}", "func (s *IPSet) Ranges() []IPRange {\n\tvar points []point\n\tfor _, r := range s.in {\n\t\tpoints = append(points, point{r.From, true, true}, point{r.To, true, false})\n\t}\n\tfor _, r := range s.out {\n\t\tpoints = append(points, point{r.From, false, true}, point{r.To, false, false})\n\t}\n\tsort.Slice(points, func(i, j int) bool { return points[i].Less(points[j]) })\n\tconst debug = false\n\tif debug {\n\t\tdebugf(\"post-sort:\")\n\t\tdebugLogPoints(points)\n\t\tdebugf(\"merging...\")\n\t}\n\n\t// Now build 'want', like points but with \"remove\" ranges removed\n\t// and adjancent blocks merged, and all elements alternating between\n\t// start and end.\n\twant := points[:0]\n\tvar addDepth, removeDepth int\n\tfor i, p := range points {\n\t\tdepth := &addDepth\n\t\tif !p.want {\n\t\t\tdepth = &removeDepth\n\t\t}\n\t\tif p.start {\n\t\t\t*depth++\n\t\t} else {\n\t\t\t*depth--\n\t\t}\n\t\tif debug {\n\t\t\tdebugf(\"at[%d] (%+v), add=%v, remove=%v\", i, p, addDepth, removeDepth)\n\t\t}\n\t\tif p.start && *depth != 1 {\n\t\t\tcontinue\n\t\t}\n\t\tif !p.start && *depth != 0 {\n\t\t\tcontinue\n\t\t}\n\t\tif !p.want && addDepth > 0 {\n\t\t\tif p.start {\n\t\t\t\t// If we're transitioning from a range of\n\t\t\t\t// addresses we want to ones we don't, insert\n\t\t\t\t// an end marker for the IP before the one we\n\t\t\t\t// don't.\n\t\t\t\twant = append(want, point{\n\t\t\t\t\tip: p.ip.Prior(),\n\t\t\t\t\twant: true,\n\t\t\t\t\tstart: false,\n\t\t\t\t})\n\t\t\t} else {\n\t\t\t\twant = append(want, point{\n\t\t\t\t\tip: p.ip.Next(),\n\t\t\t\t\twant: true,\n\t\t\t\t\tstart: true,\n\t\t\t\t})\n\t\t\t}\n\t\t}\n\t\tif !p.want || removeDepth > 0 {\n\t\t\tcontinue\n\t\t}\n\t\t// Merge adjacent ranges. Remove prior and skip this\n\t\t// start.\n\t\tif p.start && len(want) > 0 {\n\t\t\tprior := &want[len(want)-1]\n\t\t\tif !prior.start && prior.ip == p.ip.Prior() {\n\t\t\t\twant = want[:len(want)-1]\n\t\t\t\tcontinue\n\t\t\t}\n\t\t}\n\t\twant = append(want, p)\n\t}\n\tif debug {\n\t\tdebugf(\"post-merge:\")\n\t\tdebugLogPoints(want)\n\t}\n\n\tif len(want)%2 == 1 {\n\t\tpanic(\"internal error; odd number\")\n\t}\n\n\tout := make([]IPRange, 0, len(want)/2)\n\tfor i := 0; i < len(want); i += 2 {\n\t\tif !want[i].want {\n\t\t\tpanic(\"internal error; non-want in range\")\n\t\t}\n\t\tif !want[i].start {\n\t\t\tpanic(\"internal error; odd not start\")\n\t\t}\n\t\tif want[i+1].start {\n\t\t\tpanic(\"internal error; even not end\")\n\t\t}\n\t\tout = append(out, IPRange{\n\t\t\tFrom: want[i].ip,\n\t\t\tTo: want[i+1].ip,\n\t\t})\n\t}\n\treturn out\n}", "func (r *Renderer) renderRangeStmt(node *ast.RangeStmt, w *render.BufferedWriter) error {\n\n\tw.Print(\"for \")\n\n\tif node.Key != nil {\n\t\tif err := r.renderNode(node.Key, w); err != nil {\n\t\t\treturn fmt.Errorf(\"unable to render key: %w\", err)\n\t\t}\n\t}\n\n\tif node.Val != nil {\n\t\tif node.Key == nil {\n\t\t\tw.Print(\"_, \")\n\t\t} else {\n\t\t\tw.Print(\", \")\n\t\t}\n\n\t\tif err := r.renderNode(node.Val, w); err != nil {\n\t\t\treturn fmt.Errorf(\"unable to render val: %w\", err)\n\t\t}\n\t}\n\n\tif node.Key != nil || node.Val != nil {\n\t\tw.Print(\" := \")\n\t}\n\n\tw.Print(\" range \")\n\n\tif err := r.renderNode(node.X, w); err != nil {\n\t\treturn fmt.Errorf(\"unable to render range target: %w\", err)\n\t}\n\n\tif err := r.renderNode(node.Body, w); err != nil {\n\t\treturn fmt.Errorf(\"unable to render body: %w\", err)\n\t}\n\n\treturn nil\n}", "func (r Rectangle) Inset(n int) Rectangle {\n\treturn Rectangle{Point{r.Min.X + n, r.Min.Y + n}, Point{r.Max.X - n, r.Max.Y - n}}\n}", "func (r *patternPainter) Paint(ss []raster.Span, done bool) {\n\tb := r.im.Bounds()\n\tfor _, s := range ss {\n\t\tif s.Y < b.Min.Y {\n\t\t\tcontinue\n\t\t}\n\t\tif s.Y >= b.Max.Y {\n\t\t\treturn\n\t\t}\n\t\tif s.X0 < b.Min.X {\n\t\t\ts.X0 = b.Min.X\n\t\t}\n\t\tif s.X1 > b.Max.X {\n\t\t\ts.X1 = b.Max.X\n\t\t}\n\t\tif s.X0 >= s.X1 {\n\t\t\tcontinue\n\t\t}\n\t\tconst m = 1<<16 - 1\n\t\ty := s.Y - r.im.Rect.Min.Y\n\t\tx0 := s.X0 - r.im.Rect.Min.X\n\t\t// RGBAPainter.Paint() in $GOPATH/src/github.com/golang/freetype/raster/paint.go\n\t\ti0 := (s.Y-r.im.Rect.Min.Y)*r.im.Stride + (s.X0-r.im.Rect.Min.X)*4\n\t\ti1 := i0 + (s.X1-s.X0)*4\n\t\tfor i, x := i0, x0; i < i1; i, x = i+4, x+1 {\n\t\t\tma := s.Alpha\n\t\t\tif r.mask != nil {\n\t\t\t\tma = ma * uint32(r.mask.AlphaAt(x, y).A) / 255\n\t\t\t\tif ma == 0 {\n\t\t\t\t\tcontinue\n\t\t\t\t}\n\t\t\t}\n\t\t\tc := r.p.ColorAt(x, y)\n\t\t\tcr, cg, cb, ca := c.RGBA()\n\t\t\tdr := uint32(r.im.Pix[i+0])\n\t\t\tdg := uint32(r.im.Pix[i+1])\n\t\t\tdb := uint32(r.im.Pix[i+2])\n\t\t\tda := uint32(r.im.Pix[i+3])\n\t\t\ta := (m - (ca * ma / m)) * 0x101\n\t\t\tr.im.Pix[i+0] = uint8((dr*a + cr*ma) / m >> 8)\n\t\t\tr.im.Pix[i+1] = uint8((dg*a + cg*ma) / m >> 8)\n\t\t\tr.im.Pix[i+2] = uint8((db*a + cb*ma) / m >> 8)\n\t\t\tr.im.Pix[i+3] = uint8((da*a + ca*ma) / m >> 8)\n\t\t}\n\t}\n}", "func rang(m, n int) (out []*example) {\n\tfor i := m; i <= n; i++ {\n\t\tout = append(out, newItem(spanWithEnd(i, i+1)))\n\t}\n\treturn out\n}", "func (tv *TextView) RenderAllLinesInBounds() {\n\t// fmt.Printf(\"render all: %v\\n\", tv.Nm)\n\trs := &tv.Viewport.Render\n\trs.Lock()\n\tpc := &rs.Paint\n\tsty := &tv.Sty\n\ttv.VisSizes()\n\tpos := mat32.NewVec2FmPoint(tv.VpBBox.Min)\n\tepos := mat32.NewVec2FmPoint(tv.VpBBox.Max)\n\tpc.FillBox(rs, pos, epos.Sub(pos), &sty.Font.BgColor)\n\tpos = tv.RenderStartPos()\n\tstln := -1\n\tedln := -1\n\tfor ln := 0; ln < tv.NLines; ln++ {\n\t\tlst := pos.Y + tv.Offs[ln]\n\t\tled := lst + mat32.Max(tv.Renders[ln].Size.Y, tv.LineHeight)\n\t\tif int(mat32.Ceil(led)) < tv.VpBBox.Min.Y {\n\t\t\tcontinue\n\t\t}\n\t\tif int(mat32.Floor(lst)) > tv.VpBBox.Max.Y {\n\t\t\tcontinue\n\t\t}\n\t\tif stln < 0 {\n\t\t\tstln = ln\n\t\t}\n\t\tedln = ln\n\t}\n\n\tif stln < 0 || edln < 0 { // shouldn't happen.\n\t\trs.Unlock()\n\t\treturn\n\t}\n\n\tif tv.HasLineNos() {\n\t\ttv.RenderLineNosBoxAll()\n\n\t\tfor ln := stln; ln <= edln; ln++ {\n\t\t\ttv.RenderLineNo(ln)\n\t\t}\n\t}\n\n\ttv.RenderDepthBg(stln, edln)\n\ttv.RenderHighlights(stln, edln)\n\ttv.RenderScopelights(stln, edln)\n\ttv.RenderSelect()\n\tif tv.HasLineNos() {\n\t\ttbb := tv.VpBBox\n\t\ttbb.Min.X += int(tv.LineNoOff)\n\t\trs.Unlock()\n\t\trs.PushBounds(tbb)\n\t\trs.Lock()\n\t}\n\tfor ln := stln; ln <= edln; ln++ {\n\t\tlst := pos.Y + tv.Offs[ln]\n\t\tlp := pos\n\t\tlp.Y = lst\n\t\tlp.X += tv.LineNoOff\n\t\ttv.Renders[ln].Render(rs, lp) // not top pos -- already has baseline offset\n\t}\n\trs.Unlock()\n\tif tv.HasLineNos() {\n\t\trs.PopBounds()\n\t}\n}", "func (ser *Series) PrintRange(first, last int) {\n\tser.WriteRange(os.Stdout, first, last)\n}", "func Range(start, end int) []int {\n\trng := make([]int, end-start+1)\n\tfor i := 0; i < len(rng); i++ {\n\t\trng[i] = start + i\n\t}\n\treturn rng\n}", "func Range(start, end int) []int {\n\trng := make([]int, end-start+1)\n\tfor i := 0; i < len(rng); i++ {\n\t\trng[i] = start + i\n\t}\n\treturn rng\n}", "func Test_UnionRange(t *testing.T) {\n\tsetup()\n\tdefer teardown()\n\tlog(\"UnionRange\")\n\t//1..100 in -20..5, 10..100\n\tr1 := CreateFromToRangeInts(-20, 5)\n\tr2 := CreateFromToRangeInts(10, 100)\n\tunionTest(t, [][]int{{1, 100}}, []IRange{r1, r2}, [][]int{{1, 5}, {10, 100}})\n}", "func DrawElementsInstancedBaseVertexBaseInstance(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32, basevertex int32, baseinstance uint32) {\n C.glowDrawElementsInstancedBaseVertexBaseInstance(gpDrawElementsInstancedBaseVertexBaseInstance, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLsizei)(instancecount), (C.GLint)(basevertex), (C.GLuint)(baseinstance))\n}", "func (n *node) Range() diag.Ranging { return n.Ranging }", "func (h *HorizontalContainer) Draw(dst *ebiten.Image, bounds geo.Rect) {\n\ttotalWeight := 0.0\n\tfor _, e := range h.Elements {\n\t\ttotalWeight += e.Weight()\n\t}\n\twidths := make([]float64, len(h.Elements))\n\tfor i, e := range h.Elements {\n\t\twidths[i] = e.Weight() / totalWeight * bounds.W\n\t}\n\tsubBounds := bounds\n\tfor i, w := range widths {\n\t\tsubBounds.W = w\n\t\th.Elements[i].Draw(dst, subBounds)\n\t\tsubBounds.X += w\n\t}\n}", "func Rect(img *image.RGBA, x1, y1, x2, y2, width int, col color.Color) {\n\tfor i := 0; i < width; i++ {\n\t\tHLine(img, x1, y1+i, x2, col)\n\t\tHLine(img, x1, y2+i, x2, col)\n\t\tVLine(img, x1+i, y1, y2, col)\n\t\tVLine(img, x2+i, y1, y2, col)\n\t}\n}" ]
[ "0.74719715", "0.7372992", "0.7144444", "0.7144444", "0.61725533", "0.61115545", "0.5939944", "0.5939944", "0.56722873", "0.5601583", "0.55610317", "0.5530758", "0.552006", "0.5507655", "0.54915684", "0.5479939", "0.5474564", "0.539954", "0.53972906", "0.5292056", "0.5290957", "0.5251808", "0.5234056", "0.5234056", "0.52174443", "0.52156407", "0.52156407", "0.5203864", "0.51799387", "0.5168502", "0.51662993", "0.51514286", "0.51477736", "0.5136374", "0.5129804", "0.51232237", "0.5110793", "0.5108676", "0.5092517", "0.50880927", "0.5063601", "0.5027221", "0.50229144", "0.50229144", "0.5020799", "0.50070995", "0.5002348", "0.49985826", "0.49935028", "0.49793372", "0.4976405", "0.4974294", "0.49611273", "0.49585748", "0.49308246", "0.4927021", "0.49144", "0.48972267", "0.4896758", "0.489084", "0.48907885", "0.48719344", "0.4867095", "0.4847053", "0.48381782", "0.48327193", "0.481946", "0.48182696", "0.4812448", "0.48044583", "0.47953838", "0.47893155", "0.477064", "0.47694135", "0.47628313", "0.47628313", "0.47615808", "0.47615808", "0.4752454", "0.47489095", "0.47339627", "0.47339627", "0.47300625", "0.47275338", "0.47267613", "0.47082302", "0.47064456", "0.4706391", "0.46864408", "0.46863437", "0.46834528", "0.46787798", "0.46760783", "0.46739745", "0.467087", "0.467087", "0.46664983", "0.46634528", "0.46597284", "0.46570557", "0.46564254" ]
0.0
-1
draw multiple instances of a range of elements with offset applied to instanced attributes
func DrawArraysInstancedBaseInstance(mode uint32, first int32, count int32, instancecount int32, baseinstance uint32) { C.glowDrawArraysInstancedBaseInstance(gpDrawArraysInstancedBaseInstance, (C.GLenum)(mode), (C.GLint)(first), (C.GLsizei)(count), (C.GLsizei)(instancecount), (C.GLuint)(baseinstance)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func DrawRangeElements(mode uint32, start uint32, end uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n\tsyscall.Syscall6(gpDrawRangeElements, 6, uintptr(mode), uintptr(start), uintptr(end), uintptr(count), uintptr(xtype), uintptr(indices))\n}", "func DrawRangeElements(mode uint32, start uint32, end uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n C.glowDrawRangeElements(gpDrawRangeElements, (C.GLenum)(mode), (C.GLuint)(start), (C.GLuint)(end), (C.GLsizei)(count), (C.GLenum)(xtype), indices)\n}", "func DrawRangeElements(mode uint32, start uint32, end uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n\tC.glowDrawRangeElements(gpDrawRangeElements, (C.GLenum)(mode), (C.GLuint)(start), (C.GLuint)(end), (C.GLsizei)(count), (C.GLenum)(xtype), indices)\n}", "func DrawRangeElements(mode uint32, start uint32, end uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n\tC.glowDrawRangeElements(gpDrawRangeElements, (C.GLenum)(mode), (C.GLuint)(start), (C.GLuint)(end), (C.GLsizei)(count), (C.GLenum)(xtype), indices)\n}", "func DrawRangeElementsBaseVertex(mode uint32, start uint32, end uint32, count int32, xtype uint32, indices unsafe.Pointer, basevertex int32) {\n C.glowDrawRangeElementsBaseVertex(gpDrawRangeElementsBaseVertex, (C.GLenum)(mode), (C.GLuint)(start), (C.GLuint)(end), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLint)(basevertex))\n}", "func DrawRangeElementsBaseVertex(mode uint32, start uint32, end uint32, count int32, xtype uint32, indices unsafe.Pointer, basevertex int32) {\n\tsyscall.Syscall9(gpDrawRangeElementsBaseVertex, 7, uintptr(mode), uintptr(start), uintptr(end), uintptr(count), uintptr(xtype), uintptr(indices), uintptr(basevertex), 0, 0)\n}", "func (native *OpenGL) DrawElementsOffset(mode uint32, count int32, elementType uint32, offset int) {\n\tgl.DrawElements(mode, count, elementType, gl.PtrOffset(offset))\n}", "func DrawElementsInstanced(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32) {\n C.glowDrawElementsInstanced(gpDrawElementsInstanced, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLsizei)(instancecount))\n}", "func DrawElementsInstancedBaseInstance(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32, baseinstance uint32) {\n\tsyscall.Syscall6(gpDrawElementsInstancedBaseInstance, 6, uintptr(mode), uintptr(count), uintptr(xtype), uintptr(indices), uintptr(instancecount), uintptr(baseinstance))\n}", "func DrawRangeElementsBaseVertex(mode uint32, start uint32, end uint32, count int32, xtype uint32, indices unsafe.Pointer, basevertex int32) {\n\tC.glowDrawRangeElementsBaseVertex(gpDrawRangeElementsBaseVertex, (C.GLenum)(mode), (C.GLuint)(start), (C.GLuint)(end), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLint)(basevertex))\n}", "func DrawRangeElementsBaseVertex(mode uint32, start uint32, end uint32, count int32, xtype uint32, indices unsafe.Pointer, basevertex int32) {\n\tC.glowDrawRangeElementsBaseVertex(gpDrawRangeElementsBaseVertex, (C.GLenum)(mode), (C.GLuint)(start), (C.GLuint)(end), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLint)(basevertex))\n}", "func (self *Rectangle) Offset(dx int, dy int) *Rectangle{\n return &Rectangle{self.Object.Call(\"offset\", dx, dy)}\n}", "func DrawElementsInstanced(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32) {\n\tC.glowDrawElementsInstanced(gpDrawElementsInstanced, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLsizei)(instancecount))\n}", "func DrawElementsInstanced(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32) {\n\tC.glowDrawElementsInstanced(gpDrawElementsInstanced, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLsizei)(instancecount))\n}", "func MultiDrawElements(mode uint32, count *int32, xtype uint32, indices *unsafe.Pointer, drawcount int32) {\n\tsyscall.Syscall6(gpMultiDrawElements, 5, uintptr(mode), uintptr(unsafe.Pointer(count)), uintptr(xtype), uintptr(unsafe.Pointer(indices)), uintptr(drawcount), 0)\n}", "func MultiDrawElementsIndirect(mode uint32, xtype uint32, indirect unsafe.Pointer, drawcount int32, stride int32) {\n\tsyscall.Syscall6(gpMultiDrawElementsIndirect, 5, uintptr(mode), uintptr(xtype), uintptr(indirect), uintptr(drawcount), uintptr(stride), 0)\n}", "func DrawElementsInstancedBaseInstance(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32, baseinstance uint32) {\n C.glowDrawElementsInstancedBaseInstance(gpDrawElementsInstancedBaseInstance, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLsizei)(instancecount), (C.GLuint)(baseinstance))\n}", "func DrawElements(mode uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n\tsyscall.Syscall6(gpDrawElements, 4, uintptr(mode), uintptr(count), uintptr(xtype), uintptr(indices), 0, 0)\n}", "func nodesAndOffsetToRange(numNodes uint64, offset int64, res []Resource) ResourceListPair {\n\tnumNodesMin := getOffsetNodeCount(numNodes, -offset, math.Floor)\n\tnumNodesMax := getOffsetNodeCount(numNodes, offset, math.Ceil)\n\treturn ResourceListPair{\n\t\tlower: calculateResources(numNodesMin, res),\n\t\tupper: calculateResources(numNodesMax, res),\n\t}\n}", "func DrawElementsInstancedBaseVertex(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32, basevertex int32) {\n\tsyscall.Syscall6(gpDrawElementsInstancedBaseVertex, 6, uintptr(mode), uintptr(count), uintptr(xtype), uintptr(indices), uintptr(instancecount), uintptr(basevertex))\n}", "func visRangeOffsets(rng Range) string {\n\tvar buf bytes.Buffer\n\tif rng.End.Byte < rng.Start.Byte {\n\t\t// Should never happen, but we'll visualize it anyway so we can\n\t\t// more easily debug failing tests.\n\t\tfor i := 0; i < rng.End.Byte; i++ {\n\t\t\tbuf.WriteByte(' ')\n\t\t}\n\t\tfor i := rng.End.Byte; i < rng.Start.Byte; i++ {\n\t\t\tbuf.WriteByte('!')\n\t\t}\n\t\treturn buf.String()\n\t}\n\n\tfor i := 0; i < rng.Start.Byte; i++ {\n\t\tbuf.WriteByte(' ')\n\t}\n\tfor i := rng.Start.Byte; i < rng.End.Byte; i++ {\n\t\tbuf.WriteByte('#')\n\t}\n\treturn buf.String()\n}", "func DrawElementsInstancedBaseVertex(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32, basevertex int32) {\n C.glowDrawElementsInstancedBaseVertex(gpDrawElementsInstancedBaseVertex, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLsizei)(instancecount), (C.GLint)(basevertex))\n}", "func (el *Fill) Rect() {}", "func (self *Rectangle) OffsetI(args ...interface{}) *Rectangle{\n return &Rectangle{self.Object.Call(\"offset\", args)}\n}", "func Offset(dx, dy float32) {\n\tgContext.Cursor.X += dx\n\tgContext.Cursor.Y += dy\n}", "func (ev MouseEvent) Offset(offset Vec2i) MouseEvent {\n\treturn MouseEvent{\n\t\tPos: ev.Pos.Add(offset),\n\t\tID: ev.ID,\n\t\tButton: ev.Button,\n\t}\n}", "func MultiDrawElements(mode uint32, count *int32, xtype uint32, indices *unsafe.Pointer, drawcount int32) {\n C.glowMultiDrawElements(gpMultiDrawElements, (C.GLenum)(mode), (*C.GLsizei)(unsafe.Pointer(count)), (C.GLenum)(xtype), indices, (C.GLsizei)(drawcount))\n}", "func DrawElementsIndirect(mode uint32, xtype uint32, indirect unsafe.Pointer) {\n\tsyscall.Syscall(gpDrawElementsIndirect, 3, uintptr(mode), uintptr(xtype), uintptr(indirect))\n}", "func (el *Fill) TSpan() {}", "func (this *Parser) Range(start, end int) *OrderedChoice {\r\n\texps := make([]Exp, (end - start)+1)\r\n\tfor i := start; i <= end; i++ {\r\n\t\texps[i-start] = &Terminal{this,i}\r\n\t}\r\n\treturn &OrderedChoice{this,exps}\r\n}", "func DrawElementsInstancedBaseInstance(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32, baseinstance uint32) {\n\tC.glowDrawElementsInstancedBaseInstance(gpDrawElementsInstancedBaseInstance, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLsizei)(instancecount), (C.GLuint)(baseinstance))\n}", "func DrawElementsInstancedBaseInstance(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32, baseinstance uint32) {\n\tC.glowDrawElementsInstancedBaseInstance(gpDrawElementsInstancedBaseInstance, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLsizei)(instancecount), (C.GLuint)(baseinstance))\n}", "func DrawElements(mode uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n C.glowDrawElements(gpDrawElements, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices)\n}", "func (self *Graphics) SetOffsetXA(member int) {\n self.Object.Set(\"offsetX\", member)\n}", "func drawFiveRectangles(ops *op.Ops) {\n\t// Record drawRedRect operations into the macro.\n\tmacro := op.Record(ops)\n\tdrawRedRect(ops)\n\tc := macro.Stop()\n\n\t// “Play back” the macro 5 times, each time\n\t// translated vertically 20px and horizontally 110 pixels.\n\tfor i := 0; i < 5; i++ {\n\t\tc.Add(ops)\n\t\top.Offset(image.Pt(110, 20)).Add(ops)\n\t}\n}", "func (ff *fftag) at(id int) (x, y int) { return id / ff.msize, id % ff.msize }", "func MultiDrawElementsIndirect(mode uint32, xtype uint32, indirect unsafe.Pointer, drawcount int32, stride int32) {\n C.glowMultiDrawElementsIndirect(gpMultiDrawElementsIndirect, (C.GLenum)(mode), (C.GLenum)(xtype), indirect, (C.GLsizei)(drawcount), (C.GLsizei)(stride))\n}", "func DrawElementsInstancedBaseVertexBaseInstance(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32, basevertex int32, baseinstance uint32) {\n\tsyscall.Syscall9(gpDrawElementsInstancedBaseVertexBaseInstance, 7, uintptr(mode), uintptr(count), uintptr(xtype), uintptr(indices), uintptr(instancecount), uintptr(basevertex), uintptr(baseinstance), 0, 0)\n}", "func DrawElementsInstancedBaseVertex(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32, basevertex int32) {\n\tC.glowDrawElementsInstancedBaseVertex(gpDrawElementsInstancedBaseVertex, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLsizei)(instancecount), (C.GLint)(basevertex))\n}", "func DrawElementsInstancedBaseVertex(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32, basevertex int32) {\n\tC.glowDrawElementsInstancedBaseVertex(gpDrawElementsInstancedBaseVertex, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLsizei)(instancecount), (C.GLint)(basevertex))\n}", "func DrawArraysInstanced(mode uint32, first int32, count int32, instancecount int32) {\n C.glowDrawArraysInstanced(gpDrawArraysInstanced, (C.GLenum)(mode), (C.GLint)(first), (C.GLsizei)(count), (C.GLsizei)(instancecount))\n}", "func DrawElements(mode Enum, count int, ty Enum, offset int) {\n\tgl.DrawElements(uint32(mode), int32(count), uint32(ty), gl.PtrOffset(offset))\n}", "func (c *Container) Draw(r Region, delta float64) {\n}", "func (c *Compound) DrawOffset(buff draw.Image, xOff float64, yOff float64) {\n\tc.lock.RLock()\n\tc.subRenderables[c.curRenderable].DrawOffset(buff, c.X()+xOff, c.Y()+yOff)\n\tc.lock.RUnlock()\n}", "func DrawElementsInstancedBaseVertexBaseInstance(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32, basevertex int32, baseinstance uint32) {\n C.glowDrawElementsInstancedBaseVertexBaseInstance(gpDrawElementsInstancedBaseVertexBaseInstance, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLsizei)(instancecount), (C.GLint)(basevertex), (C.GLuint)(baseinstance))\n}", "func (self *Graphics) SetOffsetYA(member int) {\n self.Object.Set(\"offsetY\", member)\n}", "func (countIndex *CountIndex) Range(topLeft Point, bottomRight Point) []Point {\n\tcounters := countIndex.index.Range(topLeft, bottomRight)\n\n\tpoints := make([]Point, 0)\n\n\tfor _, c := range counters {\n\t\tif c.(counter).Point() != nil {\n\t\t\tpoints = append(points, c.(counter).Point())\n\t\t}\n\t}\n\n\treturn points\n}", "func DrawArraysInstancedBaseInstance(mode uint32, first int32, count int32, instancecount int32, baseinstance uint32) {\n\tsyscall.Syscall6(gpDrawArraysInstancedBaseInstance, 5, uintptr(mode), uintptr(first), uintptr(count), uintptr(instancecount), uintptr(baseinstance), 0)\n}", "func (w *Walker) iterateRange(start, end uintptr) {\n\tif start%pteSize != 0 {\n\t\tpanic(\"unaligned start\")\n\t}\n\tif end < start {\n\t\tpanic(\"start > end\")\n\t}\n\tif start < lowerTop {\n\t\tif end <= lowerTop {\n\t\t\tw.iterateRangeCanonical(start, end)\n\t\t} else if end > lowerTop && end <= upperBottom {\n\t\t\tif w.visitor.requiresAlloc() {\n\t\t\t\tpanic(\"alloc spans non-canonical range\")\n\t\t\t}\n\t\t\tw.iterateRangeCanonical(start, lowerTop)\n\t\t} else {\n\t\t\tif w.visitor.requiresAlloc() {\n\t\t\t\tpanic(\"alloc spans non-canonical range\")\n\t\t\t}\n\t\t\tif !w.iterateRangeCanonical(start, lowerTop) {\n\t\t\t\treturn\n\t\t\t}\n\t\t\tw.iterateRangeCanonical(upperBottom, end)\n\t\t}\n\t} else if start < upperBottom {\n\t\tif end <= upperBottom {\n\t\t\tif w.visitor.requiresAlloc() {\n\t\t\t\tpanic(\"alloc spans non-canonical range\")\n\t\t\t}\n\t\t} else {\n\t\t\tif w.visitor.requiresAlloc() {\n\t\t\t\tpanic(\"alloc spans non-canonical range\")\n\t\t\t}\n\t\t\tw.iterateRangeCanonical(upperBottom, end)\n\t\t}\n\t} else {\n\t\tw.iterateRangeCanonical(start, end)\n\t}\n}", "func (self *Rectangle) OffsetPoint(point *Point) *Rectangle{\n return &Rectangle{self.Object.Call(\"offsetPoint\", point)}\n}", "func (self *Rectangle) OffsetPointI(args ...interface{}) *Rectangle{\n return &Rectangle{self.Object.Call(\"offsetPoint\", args)}\n}", "func Test_DomRange(t *testing.T) {\n\tsetup()\n\tdefer teardown()\n\tlog(\"DomRange and AddRange\")\n\n\t//1..10 in 1..10+5\n\tdomRange_test(t, []int{1, 10}, []int{1, 10}, 5, []int{6, 10})\n\t//1..10 in 1..10+0\n\tdomRange_test(t, []int{1, 10}, []int{1, 10}, 0, []int{1, 10})\n\t//1..10 in 1..10-5\n\tdomRange_test(t, []int{1, 10}, []int{1, 10}, -5, []int{1, 5})\n\t//1..10 in 20..30+2\n\tdomRange_test(t, []int{1, 10}, []int{20, 30}, 2, []int{})\n}", "func (ref *UIElement) RangeForPosition(p Point) Range {\n\ta := cfstr(RangeForPositionParameterizedAttribute)\n\tdefer C.CFRelease(C.CFTypeRef(a))\n\tcfPoint := C.CGPointMake(C.CGFloat(p.X), C.CGFloat(p.Y))\n\taxPointValue := C.AXValueCreate(C.kAXValueTypeCGPoint, unsafe.Pointer(&cfPoint))\n\tdefer C.CFRelease(C.CFTypeRef(axPointValue))\n\tvar value C.CFTypeRef\n\tC.AXUIElementCopyParameterizedAttributeValue(ref.obj, a, axPointValue, &value)\n\tret := convertCFType(value)\n\to, ok := ret.(Range)\n\tif !ok {\n\t\treturn Range{0, 0}\n\t}\n\treturn o\n}", "func DrawElementsIndirect(mode uint32, xtype uint32, indirect unsafe.Pointer) {\n C.glowDrawElementsIndirect(gpDrawElementsIndirect, (C.GLenum)(mode), (C.GLenum)(xtype), indirect)\n}", "func MultiDrawElements(mode uint32, count *int32, xtype uint32, indices *unsafe.Pointer, drawcount int32) {\n\tC.glowMultiDrawElements(gpMultiDrawElements, (C.GLenum)(mode), (*C.GLsizei)(unsafe.Pointer(count)), (C.GLenum)(xtype), indices, (C.GLsizei)(drawcount))\n}", "func MultiDrawElements(mode uint32, count *int32, xtype uint32, indices *unsafe.Pointer, drawcount int32) {\n\tC.glowMultiDrawElements(gpMultiDrawElements, (C.GLenum)(mode), (*C.GLsizei)(unsafe.Pointer(count)), (C.GLenum)(xtype), indices, (C.GLsizei)(drawcount))\n}", "func (el *Fill) Animate() {}", "func (w *widgetbase) allocate(x int, y int, width int, height int, d *sizing) []*allocation {\n return []*allocation{&allocation{\n x: x,\n y: y,\n width: width,\n height: height,\n this: w,\n }}\n}", "func MultiDrawElementsIndirect(mode uint32, xtype uint32, indirect unsafe.Pointer, drawcount int32, stride int32) {\n\tC.glowMultiDrawElementsIndirect(gpMultiDrawElementsIndirect, (C.GLenum)(mode), (C.GLenum)(xtype), indirect, (C.GLsizei)(drawcount), (C.GLsizei)(stride))\n}", "func MultiDrawElementsIndirect(mode uint32, xtype uint32, indirect unsafe.Pointer, drawcount int32, stride int32) {\n\tC.glowMultiDrawElementsIndirect(gpMultiDrawElementsIndirect, (C.GLenum)(mode), (C.GLenum)(xtype), indirect, (C.GLsizei)(drawcount), (C.GLsizei)(stride))\n}", "func main() {\n\trand.Seed(time.Now().Unix())\n\tcanvas.Decimals=0\n\tcanvas.Start(width, height)\n\tcanvas.Rect(0, 0, width, height)\n\n\tw, h, gutter := 24.0, 18.0, 5.0\n\trows, cols := 16.0, 16.0\n\ttop, left := 20.0, 20.0\n\n\tfor r, x := 0.0, left; r < rows; r++ {\n\t\tfor c, y := 0.0, top; c < cols; c++ {\n\t\t\tcanvas.Rect(x, y, w, h,\n\t\t\t\tcanvas.RGB(rand.Intn(255), rand.Intn(255), rand.Intn(255)))\n\t\t\ty += (h + gutter)\n\t\t}\n\t\tx += (w + gutter)\n\t}\n\tcanvas.End()\n}", "func DrawArraysInstancedBaseInstance(mode uint32, first int32, count int32, instancecount int32, baseinstance uint32) {\n C.glowDrawArraysInstancedBaseInstance(gpDrawArraysInstancedBaseInstance, (C.GLenum)(mode), (C.GLint)(first), (C.GLsizei)(count), (C.GLsizei)(instancecount), (C.GLuint)(baseinstance))\n}", "func (v *VerticalContainer) Draw(dst *ebiten.Image, bounds geo.Rect) {\n\ttotalWeight := 0.0\n\tfor _, e := range v.Elements {\n\t\ttotalWeight += e.Weight()\n\t}\n\theights := make([]float64, len(v.Elements))\n\tfor i, e := range v.Elements {\n\t\theights[i] = e.Weight() / totalWeight * bounds.H\n\t}\n\tsubBounds := bounds\n\tfor i, h := range heights {\n\t\tsubBounds.H = h\n\t\tv.Elements[i].Draw(dst, subBounds)\n\t\tsubBounds.Y += h\n\t}\n}", "func HexRange(center hex, radius int) []hex {\n\n\tvar results = make([]hex, 0)\n\n\tif radius >= 0 {\n\t\tfor dx := -radius; dx <= radius; dx++ {\n\n\t\t\tfor dy := math.Max(float64(-radius), float64(-dx-radius)); dy <= math.Min(float64(radius), float64(-dx+radius)); dy++ {\n\t\t\t\tresults = append(results, HexAdd(center, NewHex(int(dx), int(dy))))\n\t\t\t}\n\t\t}\n\t}\n\n\treturn results\n\n}", "func struct_range() {\n\t// stuc1 := stru{name: \"abc\", age: 12}\n\t// for i, v := range stuc1 {\n\t// \tfmt.Println(i, v)\n\t// }\n\tfmt.Println(\"----------------\")\n}", "func (r Ranges) At(i int) Range {\n\treturn Range{LowerBound: int(r[2*i]), UpperBound: int(r[2*i+1])}\n}", "func (c *Canvas) printElements() {\n\tfor _, es := range c.elements {\n\t\tc.Println(\"<g>\")\n\t\tfor _, e := range es {\n\t\t\tc.Println(e.Usebg())\n\t\t}\n\t\tfor _, e := range es {\n\t\t\tc.Println(e.Use())\n\t\t}\n\t\tc.Println(\"</g>\")\n\t}\n}", "func (irq *InstanceRuntimeQuery) Offset(offset int) *InstanceRuntimeQuery {\n\tirq.offset = &offset\n\treturn irq\n}", "func iterateObjects1DWithIndexes() {\n\tfmt.Println(\"*** iterateObjects1DWithIndexes\")\n\n\ttype Point struct {\n\t\tX int\n\t\tY int\n\t}\n\tpoints := [5]Point{\n\t\tPoint{1, 1},\n\t\tPoint{2, 2},\n\t\tPoint{3, 3},\n\t\tPoint{4, 4},\n\t\tPoint{5, 5},\n\t}\n\n\tfor i, e := range points {\n\t\tfmt.Printf(\"ints[%d]: %+v\\n\", i, e)\n\t}\n\tfmt.Println(\"\")\n}", "func (p *GIFPrinter) drawExact(target *image.Paletted, source image.Image) {\n\tbounds := source.Bounds()\n\tfor y := bounds.Min.Y; y < bounds.Max.Y; y++ {\n\t\tfor x := bounds.Min.X; x < bounds.Max.X; x++ {\n\t\t\ttarget.Set(x, y, source.At(x, y))\n\t\t}\n\t}\n}", "func (fn *Function) instRange() [2]int {\n\td := len(fn.Name)\n\tinst := [2]int{d, d}\n\tif strings.HasPrefix(fn.Name, \"type..\") {\n\t\treturn inst\n\t}\n\tinst[0] = strings.Index(fn.Name, \"[\")\n\tif inst[0] < 0 {\n\t\tinst[0] = d\n\t\treturn inst\n\t}\n\tinst[1] = strings.LastIndex(fn.Name, \"]\")\n\tif inst[1] < 0 {\n\t\tinst[0] = d\n\t\tinst[1] = d\n\t\treturn inst\n\t}\n\treturn inst\n}", "func (self *Graphics) OffsetX() int{\n return self.Object.Get(\"offsetX\").Int()\n}", "func (gp *GradientParticle) DrawOffsetGen(generator Generator, buff draw.Image, xOff, yOff float64) {\n\n\tgen := generator.(*GradientGenerator)\n\tprogress := gp.Life / gp.totalLife\n\tc1 := render.GradientColorAt(gp.startColor, gp.endColor, progress)\n\tc2 := render.GradientColorAt(gp.startColor2, gp.endColor2, progress)\n\n\tsize := int(((1 - progress) * gp.size) + (progress * gp.endSize))\n\n\thalfSize := float64(size) / 2\n\n\txOffi := int(xOff - halfSize)\n\tyOffi := int(yOff - halfSize)\n\n\tfor i := 0; i < size; i++ {\n\t\tfor j := 0; j < size; j++ {\n\t\t\tif gen.Shape.In(i, j, size) {\n\t\t\t\tprogress := gen.ProgressFunction(i, j, size, size)\n\t\t\t\tc := render.GradientColorAt(c1, c2, progress)\n\t\t\t\tbuff.Set(xOffi+i, yOffi+j, c)\n\t\t\t}\n\t\t}\n\t}\n}", "func DrawElementsInstancedBaseVertexBaseInstance(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32, basevertex int32, baseinstance uint32) {\n\tC.glowDrawElementsInstancedBaseVertexBaseInstance(gpDrawElementsInstancedBaseVertexBaseInstance, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLsizei)(instancecount), (C.GLint)(basevertex), (C.GLuint)(baseinstance))\n}", "func DrawElementsInstancedBaseVertexBaseInstance(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32, basevertex int32, baseinstance uint32) {\n\tC.glowDrawElementsInstancedBaseVertexBaseInstance(gpDrawElementsInstancedBaseVertexBaseInstance, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLsizei)(instancecount), (C.GLint)(basevertex), (C.GLuint)(baseinstance))\n}", "func drawOverlappingRectangles(ops *op.Ops) {\n\t// Draw a red rectangle.\n\tcl := clip.Rect{Max: image.Pt(100, 50)}.Push(ops)\n\tpaint.ColorOp{Color: color.NRGBA{R: 0x80, A: 0xFF}}.Add(ops)\n\tpaint.PaintOp{}.Add(ops)\n\tcl.Pop()\n\n\t// Draw a green rectangle.\n\tcl = clip.Rect{Max: image.Pt(50, 100)}.Push(ops)\n\tpaint.ColorOp{Color: color.NRGBA{G: 0x80, A: 0xFF}}.Add(ops)\n\tpaint.PaintOp{}.Add(ops)\n\tcl.Pop()\n}", "func (rg Range) Iter(fn func(Point)) {\n\tfor y := rg.Min.Y; y < rg.Max.Y; y++ {\n\t\tfor x := rg.Min.X; x < rg.Max.X; x++ {\n\t\t\tp := Point{X: x, Y: y}\n\t\t\tfn(p)\n\t\t}\n\t}\n}", "func (b *BarChart) GlyphBoxes(plt *plot.Plot) []plot.GlyphBox {\n\n// fmt.Println (\"GlyphBoxes start \" )\n// fmt.Println (\"GlyphBoxes plt \" ,plt )\n\n\tboxes := make([]plot.GlyphBox, len(b.Values))\n\tfor i := range b.Values {\n\t\tcat := b.XMin + float64(i)\n\t\tif !b.Horizontal {\n\t\t\tboxes[i].X = plt.X.Norm(cat)\n\t\t\tboxes[i].Rectangle = vg.Rectangle{\n\t\t\t\tMin: vg.Point{X: b.Offset - b.Width/2},\n\t\t\t\tMax: vg.Point{X: b.Offset + b.Width/2},\n\t\t\t}\n\t\t} else {\n\t\t\tboxes[i].Y = plt.Y.Norm(cat)\n\t\t\tboxes[i].Rectangle = vg.Rectangle{\n\t\t\t\tMin: vg.Point{Y: b.Offset - b.Width/2},\n\t\t\t\tMax: vg.Point{Y: b.Offset + b.Width/2},\n\t\t\t}\n\t\t}\n\t}\n\n//\tfmt.Println (\"GlyphBoxes end \" )\n\n\treturn boxes\n}", "func (x *fastReflection_EventCreateBatch) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) {\n\tif x.ClassId != \"\" {\n\t\tvalue := protoreflect.ValueOfString(x.ClassId)\n\t\tif !f(fd_EventCreateBatch_class_id, value) {\n\t\t\treturn\n\t\t}\n\t}\n\tif x.BatchDenom != \"\" {\n\t\tvalue := protoreflect.ValueOfString(x.BatchDenom)\n\t\tif !f(fd_EventCreateBatch_batch_denom, value) {\n\t\t\treturn\n\t\t}\n\t}\n\tif x.Issuer != \"\" {\n\t\tvalue := protoreflect.ValueOfString(x.Issuer)\n\t\tif !f(fd_EventCreateBatch_issuer, value) {\n\t\t\treturn\n\t\t}\n\t}\n\tif x.TotalAmount != \"\" {\n\t\tvalue := protoreflect.ValueOfString(x.TotalAmount)\n\t\tif !f(fd_EventCreateBatch_total_amount, value) {\n\t\t\treturn\n\t\t}\n\t}\n\tif x.StartDate != \"\" {\n\t\tvalue := protoreflect.ValueOfString(x.StartDate)\n\t\tif !f(fd_EventCreateBatch_start_date, value) {\n\t\t\treturn\n\t\t}\n\t}\n\tif x.EndDate != \"\" {\n\t\tvalue := protoreflect.ValueOfString(x.EndDate)\n\t\tif !f(fd_EventCreateBatch_end_date, value) {\n\t\t\treturn\n\t\t}\n\t}\n\tif x.ProjectLocation != \"\" {\n\t\tvalue := protoreflect.ValueOfString(x.ProjectLocation)\n\t\tif !f(fd_EventCreateBatch_project_location, value) {\n\t\t\treturn\n\t\t}\n\t}\n}", "func DrawElements(mode uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n\tC.glowDrawElements(gpDrawElements, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices)\n}", "func DrawElements(mode uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n\tC.glowDrawElements(gpDrawElements, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices)\n}", "func (this *BoundingBox) AddRange(points []vec3.T) *BoundingBox {\n\tif points != nil {\n\t\tfor _, pt := range points {\n\t\t\tthis.Add(&pt)\n\t\t}\n\t}\n\n\treturn this\n}", "func DrawElementsIndirect(mode uint32, xtype uint32, indirect unsafe.Pointer) {\n\tC.glowDrawElementsIndirect(gpDrawElementsIndirect, (C.GLenum)(mode), (C.GLenum)(xtype), indirect)\n}", "func DrawElementsIndirect(mode uint32, xtype uint32, indirect unsafe.Pointer) {\n\tC.glowDrawElementsIndirect(gpDrawElementsIndirect, (C.GLenum)(mode), (C.GLenum)(xtype), indirect)\n}", "func DrawArraysInstanced(mode uint32, first int32, count int32, instancecount int32) {\n\tC.glowDrawArraysInstanced(gpDrawArraysInstanced, (C.GLenum)(mode), (C.GLint)(first), (C.GLsizei)(count), (C.GLsizei)(instancecount))\n}", "func DrawArraysInstanced(mode uint32, first int32, count int32, instancecount int32) {\n\tC.glowDrawArraysInstanced(gpDrawArraysInstanced, (C.GLenum)(mode), (C.GLint)(first), (C.GLsizei)(count), (C.GLsizei)(instancecount))\n}", "func formatRange(ctx context.Context, v source.View, s span.Span) ([]protocol.TextEdit, error) {\n\tf, m, err := newColumnMap(ctx, v, s.URI())\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\trng, err := s.Range(m.Converter)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\tif rng.Start == rng.End {\n\t\t// If we have a single point, assume we want the whole file.\n\t\ttok := f.GetToken(ctx)\n\t\tif tok == nil {\n\t\t\treturn nil, fmt.Errorf(\"no file information for %s\", f.URI())\n\t\t}\n\t\trng.End = tok.Pos(tok.Size())\n\t}\n\tedits, err := source.Format(ctx, f, rng)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\treturn ToProtocolEdits(m, edits)\n}", "func plotfunc(deck *generate.Deck, left, right, top, bottom float64, data pf, size float64, color string) {\n\tix := left\n\tiy := bottom\n\tfor xd := data.xmin; xd <= data.xmax; xd += data.xint {\n\t\txp := vmap(xd, data.xmin, data.xmax, left, right)\n\t\typ := vmap(data.function(xd), data.ymin, data.ymax, bottom, top)\n\t\tdeck.Line(ix, iy, xp, yp, 0.2, color)\n\t\tix = xp\n\t\tiy = yp\n\t}\n}", "func drawGrid(pdf *gofpdf.Fpdf) {\n w, h := pdf.GetPageSize()\n pdf.SetFont(\"courier\", \"\", 12)\n pdf.SetTextColor(80, 80, 80)\n pdf.SetDrawColor(200, 200, 200)\n for x := 0.0; x < w; x = x + (w / 20.0) {\n pdf.SetTextColor(200, 200, 200)\n pdf.Line(x, 0, x, h)\n _, lineHt := pdf.GetFontSize()\n pdf.Text(x, lineHt, fmt.Sprintf(\"%d\", int(x)))\n }\n for y := 0.0; y < h; y = y + (w / 20.0) {\n pdf.SetTextColor(80, 80, 80)\n pdf.Line(0, y, w, y)\n pdf.Text(0, y, fmt.Sprintf(\"%d\", int(y)))\n }\n}", "func DrawOrder(value int) *SimpleElement { return newSEInt(\"drawOrder\", value) }", "func (el *Fill) Set() {}", "func lattice(xp, yp, w, h, size, hspace, vspace, n int, bgcolor string) {\n\tif bgcolor == \"\" {\n\t\tcanvas.Rect(0, 0, w, h, randcolor())\n\t} else {\n\t\tcanvas.Rect(0, 0, w, h, \"fill:\"+bgcolor)\n\t}\n\ty := yp\n\tfor r := 0; r < n; r++ {\n\t\tfor x := xp; x < w; x += hspace {\n\t\t\trcube(x, y, size)\n\t\t}\n\t\ty += vspace\n\t}\n}", "func (b *raftBadger) generateRanges(min, max uint64, batchSize int64) []IteratorRange {\n\tnSegments := int(math.Round(float64((max - min) / uint64(batchSize))))\n\tsegments := []IteratorRange{}\n\tif (max - min) <= uint64(batchSize) {\n\t\tsegments = append(segments, IteratorRange{from: min, to: max})\n\t\treturn segments\n\t}\n\tfor len(segments) < nSegments {\n\t\tnextMin := min + uint64(batchSize)\n\t\tsegments = append(segments, IteratorRange{from: min, to: nextMin})\n\t\tmin = nextMin + 1\n\t}\n\tsegments = append(segments, IteratorRange{from: min, to: max})\n\treturn segments\n}", "func (r *renderer) Spacing() int { return 0 }", "func (s *slice) slice(start, stop int, elemsize uintptr) slice {\n\tif start >= s.cap_ || start < 0 || stop > s.cap_ || stop < 0 {\n\t\tpanic(\"cuda4/safe: slice index out of bounds\")\n\t}\n\tif start > stop {\n\t\tpanic(\"cuda4/safe: inverted slice range\")\n\t}\n\treturn slice{cu.DevicePtr(uintptr(s.ptr_) + uintptr(start)*elemsize), stop - start, s.cap_ - start}\n}", "func (c *Switch) SetOffsets(k string, offsets physics.Vector) {\n\tc.lock.RLock()\n\tif r, ok := c.subRenderables[k]; ok {\n\t\tr.SetPos(offsets.X(), offsets.Y())\n\t}\n\tc.lock.RUnlock()\n}", "func (p pawns) arrange(start, end render.Point) {\n\t// TODO: Rotate the sprite to match the angle of the line or compute the across of the sprite at that angle\n\ttotalPawnWidth := len(p) * 128\n\tspacer := (start.Dist(end) - float64(totalPawnWidth)) / float64(len(p)+1)\n\tfor _, pawn := range p {\n\t\tstart = start.AddVec(spacer, end)\n\t\tpawn.sprite.Translate(start.X, start.Y)\n\t\tstart = start.AddVec(128, end)\n\t}\n}", "func amountRange(n int, start, stop int) string {\n\treturn fmt.Sprintf(\"%s:%d:%d:%d\", replacementPrefix, n, start, stop)\n}", "func (self *Rectangle) Aabb(points []Point) *Rectangle{\n return &Rectangle{self.Object.Call(\"aabb\", points)}\n}", "func rang(m, n int) (out []*example) {\n\tfor i := m; i <= n; i++ {\n\t\tout = append(out, newItem(spanWithEnd(i, i+1)))\n\t}\n\treturn out\n}", "func (s *Set) Range(from, to interface{}) Iterator {\n\treturn s.skiplist.Range(from, to)\n}" ]
[ "0.6728687", "0.65474373", "0.62239414", "0.62239414", "0.5633735", "0.5625187", "0.5568157", "0.5551031", "0.53338426", "0.5328232", "0.5328232", "0.5254491", "0.5203274", "0.5203274", "0.52012455", "0.5159294", "0.514889", "0.511174", "0.5052186", "0.5026192", "0.50244975", "0.5004026", "0.4975336", "0.49590707", "0.4937167", "0.49193227", "0.49099573", "0.48949498", "0.48881152", "0.48845223", "0.4880203", "0.4880203", "0.48599955", "0.48407236", "0.48281115", "0.4814981", "0.48059422", "0.47928017", "0.47504094", "0.47504094", "0.47503906", "0.4744551", "0.4733631", "0.47329307", "0.47200832", "0.47119173", "0.47104183", "0.46872705", "0.4653829", "0.46376094", "0.45903245", "0.45889592", "0.4587617", "0.45865017", "0.4585108", "0.4585108", "0.45789596", "0.4566313", "0.4553303", "0.4553303", "0.45463416", "0.45451725", "0.45409405", "0.45176518", "0.450866", "0.4506749", "0.4503577", "0.4492411", "0.44792014", "0.44714588", "0.44676226", "0.44656488", "0.44213825", "0.44125465", "0.44125465", "0.44052047", "0.4397081", "0.4385747", "0.43811196", "0.43793815", "0.43793815", "0.43736815", "0.4361124", "0.4361124", "0.43575415", "0.43575415", "0.43450603", "0.43449673", "0.43400764", "0.43271208", "0.43257537", "0.4325473", "0.43213463", "0.4308974", "0.42992133", "0.4295868", "0.4290656", "0.42898273", "0.42860654", "0.4282732", "0.42816824" ]
0.0
-1
specify which color buffers are to be drawn into
func DrawBuffer(buf uint32) { C.glowDrawBuffer(gpDrawBuffer, (C.GLenum)(buf)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func DrawBuffers(n int32, bufs *uint32) {\n C.glowDrawBuffers(gpDrawBuffers, (C.GLsizei)(n), (*C.GLenum)(unsafe.Pointer(bufs)))\n}", "func DrawBuffer(mode uint32) {\n C.glowDrawBuffer(gpDrawBuffer, (C.GLenum)(mode))\n}", "func (f *Framebuffer) Paint(r vnclib.Rectangle, colors []vnclib.Color) {\n\tif glog.V(4) {\n\t\tglog.Info(venuelib.FnNameWithArgs(r.String(), \"colors\"))\n\t}\n\t// TODO(kward): Implement double or triple buffering to reduce paint\n\t// interference.\n\tfor x := 0; x < int(r.Width); x++ {\n\t\tfor y := 0; y < int(r.Height); y++ {\n\t\t\tc := colors[x+y*int(r.Width)]\n\t\t\tf.fb.SetRGBA(x+int(r.X), y+int(r.Y), color.RGBA{uint8(c.R), uint8(c.G), uint8(c.B), 255})\n\t\t}\n\t}\n}", "func MultiDrawArrays(mode uint32, first *int32, count *int32, drawcount int32) {\n C.glowMultiDrawArrays(gpMultiDrawArrays, (C.GLenum)(mode), (*C.GLint)(unsafe.Pointer(first)), (*C.GLsizei)(unsafe.Pointer(count)), (C.GLsizei)(drawcount))\n}", "func DrawArrays(mode uint32, first int32, count int32) {\n C.glowDrawArrays(gpDrawArrays, (C.GLenum)(mode), (C.GLint)(first), (C.GLsizei)(count))\n}", "func DrawBuffers(n int32, bufs *uint32) {\n\tsyscall.Syscall(gpDrawBuffers, 2, uintptr(n), uintptr(unsafe.Pointer(bufs)), 0)\n}", "func DrawBuffers(n int32, bufs *uint32) {\n\tC.glowDrawBuffers(gpDrawBuffers, (C.GLsizei)(n), (*C.GLenum)(unsafe.Pointer(bufs)))\n}", "func DrawBuffers(n int32, bufs *uint32) {\n\tC.glowDrawBuffers(gpDrawBuffers, (C.GLsizei)(n), (*C.GLenum)(unsafe.Pointer(bufs)))\n}", "func MultiDrawArrays(mode uint32, first *int32, count *int32, drawcount int32) {\n\tsyscall.Syscall6(gpMultiDrawArrays, 4, uintptr(mode), uintptr(unsafe.Pointer(first)), uintptr(unsafe.Pointer(count)), uintptr(drawcount), 0, 0)\n}", "func DrawArrays(mode uint32, first int32, count int32) {\n\tsyscall.Syscall(gpDrawArrays, 3, uintptr(mode), uintptr(first), uintptr(count))\n}", "func Color(foreColor, backColor, mode gb.UINT8) {}", "func GenRenderbuffers(n int32, renderbuffers *uint32) {\n C.glowGenRenderbuffers(gpGenRenderbuffers, (C.GLsizei)(n), (*C.GLuint)(unsafe.Pointer(renderbuffers)))\n}", "func draw(window *glfw.Window, reactProg, landProg uint32) {\n\n\tvar renderLoops = 4\n\tfor i := 0; i < renderLoops; i++ {\n\t\t// -- DRAW TO BUFFER --\n\t\t// define destination of pixels\n\t\t//gl.BindFramebuffer(gl.FRAMEBUFFER, 0)\n\t\tgl.BindFramebuffer(gl.FRAMEBUFFER, FBO[1])\n\n\t\tgl.Viewport(0, 0, width, height) // Retina display doubles the framebuffer !?!\n\n\t\tgl.Clear(gl.COLOR_BUFFER_BIT | gl.DEPTH_BUFFER_BIT)\n\t\tgl.UseProgram(reactProg)\n\n\t\t// bind Texture\n\t\tgl.ActiveTexture(gl.TEXTURE0)\n\t\tgl.BindTexture(gl.TEXTURE_2D, renderedTexture)\n\t\tgl.Uniform1i(uniTex, 0)\n\n\t\tgl.BindVertexArray(VAO)\n\t\tgl.DrawElements(gl.TRIANGLE_STRIP, int32(len(indices)), gl.UNSIGNED_INT, nil)\n\n\t\tgl.BindVertexArray(0)\n\n\t\t// -- copy back textures --\n\t\tgl.BindFramebuffer(gl.READ_FRAMEBUFFER, FBO[1]) // source is high res array\n\t\tgl.ReadBuffer(gl.COLOR_ATTACHMENT0)\n\t\tgl.BindFramebuffer(gl.DRAW_FRAMEBUFFER, FBO[0]) // destination is cells array\n\t\tgl.DrawBuffer(gl.COLOR_ATTACHMENT0)\n\t\tgl.BlitFramebuffer(0, 0, width, height,\n\t\t\t0, 0, cols, rows,\n\t\t\tgl.COLOR_BUFFER_BIT, gl.NEAREST) // downsample\n\t\tgl.BindFramebuffer(gl.READ_FRAMEBUFFER, FBO[0]) // source is low res array - put in texture\n\t\t// read pixels saves data read as unsigned bytes and then loads them in TexImage same way\n\t\tgl.ReadPixels(0, 0, cols, rows, gl.RGBA, gl.FLOAT, gl.Ptr(fData))\n\t\tgl.BindTexture(gl.TEXTURE_2D, renderedTexture)\n\t\tgl.TexImage2D(gl.TEXTURE_2D, 0, gl.RGBA, cols, rows, 0, gl.RGBA, gl.FLOAT, gl.Ptr(fData))\n\t\tCheckGLErrors()\n\t}\n\t// -- DRAW TO SCREEN --\n\tvar model glm.Mat4\n\n\t// destination 0 means screen\n\tgl.BindFramebuffer(gl.FRAMEBUFFER, 0)\n\tgl.Viewport(0, 0, width*2, height*2) // Retina display doubles the framebuffer !?!\n\tgl.Clear(gl.COLOR_BUFFER_BIT | gl.DEPTH_BUFFER_BIT)\n\tgl.UseProgram(landProg)\n\t// bind Texture\n\tgl.ActiveTexture(gl.TEXTURE0)\n\tgl.BindTexture(gl.TEXTURE_2D, drawTexture)\n\n\tvar view glm.Mat4\n\tvar brakeFactor = float64(20000.0)\n\tvar xCoord, yCoord float32\n\txCoord = float32(-3.0 * math.Sin(float64(myClock)))\n\tyCoord = float32(-3.0 * math.Cos(float64(myClock)))\n\t//xCoord = 0.0\n\t//yCoord = float32(-2.5)\n\tmyClock = math.Mod((myClock + float64(deltaTime)/brakeFactor), (math.Pi * 2))\n\tview = glm.LookAt(xCoord, yCoord, 2.0, 0.0, 0.0, 0.0, 0.0, 0.0, 1.0)\n\tgl.UniformMatrix4fv(uniView, 1, false, &view[0])\n\tmodel = glm.HomogRotate3DX(glm.DegToRad(00.0))\n\tgl.UniformMatrix4fv(uniModel, 1, false, &model[0])\n\tgl.Uniform1i(uniTex2, 0)\n\n\t// render container\n\t//gl.PolygonMode(gl.FRONT_AND_BACK, gl.FILL)\n\t//gl.PolygonMode(gl.FRONT_AND_BACK, gl.LINE)\n\n\tgl.BindVertexArray(VAO)\n\tgl.DrawElements(gl.TRIANGLE_STRIP, int32(len(indices)), gl.UNSIGNED_INT, nil)\n\tgl.BindVertexArray(0)\n\n\tCheckGLErrors()\n\n\tglfw.PollEvents()\n\twindow.SwapBuffers()\n\n\t//time.Sleep(100 * 1000 * 1000)\n}", "func DrawArrays(mode Enum, first, count int) {\n\tgl.DrawArrays(uint32(mode), int32(first), int32(count))\n}", "func BindBuffersBase(target uint32, first uint32, count int32, buffers *uint32) {\n C.glowBindBuffersBase(gpBindBuffersBase, (C.GLenum)(target), (C.GLuint)(first), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(buffers)))\n}", "func (native *OpenGL) DrawBuffers(n int32, bufs *uint32) {\n\tgl.DrawBuffers(n, bufs)\n}", "func (debugging *debuggingOpenGL) DrawBuffers(buffers []uint32) {\n\tdebugging.recordEntry(\"DrawBuffers\", buffers)\n\tdebugging.gl.DrawBuffers(buffers)\n\tdebugging.recordExit(\"DrawBuffers\")\n}", "func DrawArrays(mode Enum, first Int, count Sizei) {\n\tcmode, _ := (C.GLenum)(mode), cgoAllocsUnknown\n\tcfirst, _ := (C.GLint)(first), cgoAllocsUnknown\n\tccount, _ := (C.GLsizei)(count), cgoAllocsUnknown\n\tC.glDrawArrays(cmode, cfirst, ccount)\n}", "func MultiDrawArrays(mode uint32, first *int32, count *int32, drawcount int32) {\n\tC.glowMultiDrawArrays(gpMultiDrawArrays, (C.GLenum)(mode), (*C.GLint)(unsafe.Pointer(first)), (*C.GLsizei)(unsafe.Pointer(count)), (C.GLsizei)(drawcount))\n}", "func MultiDrawArrays(mode uint32, first *int32, count *int32, drawcount int32) {\n\tC.glowMultiDrawArrays(gpMultiDrawArrays, (C.GLenum)(mode), (*C.GLint)(unsafe.Pointer(first)), (*C.GLsizei)(unsafe.Pointer(count)), (C.GLsizei)(drawcount))\n}", "func BindVertexBuffers(first uint32, count int32, buffers *uint32, offsets *int, strides *int32) {\n C.glowBindVertexBuffers(gpBindVertexBuffers, (C.GLuint)(first), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(buffers)), (*C.GLintptr)(unsafe.Pointer(offsets)), (*C.GLsizei)(unsafe.Pointer(strides)))\n}", "func BindBuffersRange(target uint32, first uint32, count int32, buffers *uint32, offsets *int, sizes *int) {\n C.glowBindBuffersRange(gpBindBuffersRange, (C.GLenum)(target), (C.GLuint)(first), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(buffers)), (*C.GLintptr)(unsafe.Pointer(offsets)), (*C.GLsizeiptr)(unsafe.Pointer(sizes)))\n}", "func DrawArrays(mode uint32, first int32, count int32) {\n\tC.glowDrawArrays(gpDrawArrays, (C.GLenum)(mode), (C.GLint)(first), (C.GLsizei)(count))\n}", "func DrawArrays(mode uint32, first int32, count int32) {\n\tC.glowDrawArrays(gpDrawArrays, (C.GLenum)(mode), (C.GLint)(first), (C.GLsizei)(count))\n}", "func SelectBuffer(size int32, buffer *uint32) {\n C.glowSelectBuffer(gpSelectBuffer, (C.GLsizei)(size), (*C.GLuint)(unsafe.Pointer(buffer)))\n}", "func Plot(x, y, color, mode gb.UINT8) {}", "func NamedFramebufferDrawBuffers(framebuffer uint32, n int32, bufs *uint32) {\n\tsyscall.Syscall(gpNamedFramebufferDrawBuffers, 3, uintptr(framebuffer), uintptr(n), uintptr(unsafe.Pointer(bufs)))\n}", "func (debugging *debuggingOpenGL) DrawArrays(mode uint32, first int32, count int32) {\n\tdebugging.recordEntry(\"DrawArrays\", first, count)\n\tdebugging.gl.DrawArrays(mode, first, count)\n\tdebugging.recordExit(\"DrawArrays\")\n}", "func GenBuffers(n int32, buffers *uint32) {\n C.glowGenBuffers(gpGenBuffers, (C.GLsizei)(n), (*C.GLuint)(unsafe.Pointer(buffers)))\n}", "func GenRenderbuffers(n int32, renderbuffers *uint32) {\n\tC.glowGenRenderbuffers(gpGenRenderbuffers, (C.GLsizei)(n), (*C.GLuint)(unsafe.Pointer(renderbuffers)))\n}", "func GenRenderbuffers(n int32, renderbuffers *uint32) {\n\tC.glowGenRenderbuffers(gpGenRenderbuffers, (C.GLsizei)(n), (*C.GLuint)(unsafe.Pointer(renderbuffers)))\n}", "func NamedFramebufferDrawBuffers(framebuffer uint32, n int32, bufs *uint32) {\n\tC.glowNamedFramebufferDrawBuffers(gpNamedFramebufferDrawBuffers, (C.GLuint)(framebuffer), (C.GLsizei)(n), (*C.GLenum)(unsafe.Pointer(bufs)))\n}", "func NamedFramebufferDrawBuffers(framebuffer uint32, n int32, bufs *uint32) {\n\tC.glowNamedFramebufferDrawBuffers(gpNamedFramebufferDrawBuffers, (C.GLuint)(framebuffer), (C.GLsizei)(n), (*C.GLenum)(unsafe.Pointer(bufs)))\n}", "func GenRenderbuffers(n int32, renderbuffers *uint32) {\n\tsyscall.Syscall(gpGenRenderbuffers, 2, uintptr(n), uintptr(unsafe.Pointer(renderbuffers)), 0)\n}", "func BindBuffersBase(target uint32, first uint32, count int32, buffers *uint32) {\n\tC.glowBindBuffersBase(gpBindBuffersBase, (C.GLenum)(target), (C.GLuint)(first), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(buffers)))\n}", "func BindBuffersBase(target uint32, first uint32, count int32, buffers *uint32) {\n\tC.glowBindBuffersBase(gpBindBuffersBase, (C.GLenum)(target), (C.GLuint)(first), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(buffers)))\n}", "func (c *COM) configureBuffers() {\n\t// Bit: | 7 6 | 5 | 4 | 3 | 2 | 1 | 0 |\n\t// Content: | lvl | bs | r | dma | clt | clr | e |\n\t// Value: | 1 1 | 0 | 0 | 0 | 1 | 1 | 1 | = 0xc7\n\tio.OutB(serialDataPort(c.Port), 0xc7)\n}", "func MultiDrawElements(mode uint32, count *int32, xtype uint32, indices *unsafe.Pointer, drawcount int32) {\n C.glowMultiDrawElements(gpMultiDrawElements, (C.GLenum)(mode), (*C.GLsizei)(unsafe.Pointer(count)), (C.GLenum)(xtype), indices, (C.GLsizei)(drawcount))\n}", "func DrawBuffer(buf uint32) {\n\tsyscall.Syscall(gpDrawBuffer, 1, uintptr(buf), 0, 0)\n}", "func initFontVbo() {\n\tvar vertexAttributes = make([]float32, 5*6*len(charDatas))\n\ti := 0\n\tfor _, charData := range charDatas {\n\t\ttop := float32(charData.ty+charData.h) / 256\n\t\tbottom := float32(charData.ty) / 256\n\t\tright := float32(charData.tx+charData.w) / 256\n\t\tleft := float32(charData.tx) / 256\n\n\t\tw := float32(charData.w) / 256\n\t\th := float32(charData.h) / 256\n\n\t\t// tri 1\n\t\tvertexAttributes[i] = w\n\t\tvertexAttributes[i+1] = h\n\t\tvertexAttributes[i+2] = 0\n\t\tvertexAttributes[i+3] = right\n\t\tvertexAttributes[i+4] = bottom\n\t\ti += 5\n\n\t\tvertexAttributes[i] = w\n\t\tvertexAttributes[i+1] = 0\n\t\tvertexAttributes[i+2] = 0\n\t\tvertexAttributes[i+3] = right\n\t\tvertexAttributes[i+4] = top\n\t\ti += 5\n\n\t\tvertexAttributes[i] = 0\n\t\tvertexAttributes[i+1] = h\n\t\tvertexAttributes[i+2] = 0\n\t\tvertexAttributes[i+3] = left\n\t\tvertexAttributes[i+4] = bottom\n\t\ti += 5\n\n\t\t// tri 2\n\t\tvertexAttributes[i] = w\n\t\tvertexAttributes[i+1] = 0\n\t\tvertexAttributes[i+2] = 0\n\t\tvertexAttributes[i+3] = right\n\t\tvertexAttributes[i+4] = top\n\t\ti += 5\n\n\t\tvertexAttributes[i] = 0\n\t\tvertexAttributes[i+1] = 0\n\t\tvertexAttributes[i+2] = 0\n\t\tvertexAttributes[i+3] = left\n\t\tvertexAttributes[i+4] = top\n\t\ti += 5\n\n\t\tvertexAttributes[i] = 0\n\t\tvertexAttributes[i+1] = h\n\t\tvertexAttributes[i+2] = 0\n\t\tvertexAttributes[i+3] = left\n\t\tvertexAttributes[i+4] = bottom\n\t\ti += 5\n\t}\n\n\tgl.GenBuffers(1, &vbo)\n\tgl.GenVertexArrays(1, &vao)\n\tgl.BindVertexArray(vao)\n\tgl.EnableVertexAttribArray(0)\n\tgl.BindBuffer(gl.ARRAY_BUFFER, vbo)\n\tgl.BufferData(\n\t\tgl.ARRAY_BUFFER,\n\t\t4*len(vertexAttributes),\n\t\tgl.Ptr(vertexAttributes),\n\t\tgl.STATIC_DRAW,\n\t)\n\tgl.VertexAttribPointer(0, 3, gl.FLOAT, false, 5*4, gl.PtrOffset(0))\n\tgl.EnableVertexAttribArray(0)\n\tgl.VertexAttribPointer(1, 2, gl.FLOAT, false, 5*4, gl.PtrOffset(4*3))\n\tgl.EnableVertexAttribArray(1)\n\t//unbind\n\tgl.BindVertexArray(0)\n\n}", "func BufferInit(target Enum, size int, usage Enum) {\n\tgl.BufferData(uint32(target), size, nil, uint32(usage))\n}", "func (c *ChromaHighlight) ClrBuffer() {\n\tswitch c.srcBuff {\n\tcase nil:\n\t\tc.txtBuff.Delete(c.txtBuff.GetStartIter(), c.txtBuff.GetEndIter())\n\tdefault:\n\t\tc.srcBuff.Delete(c.srcBuff.GetStartIter(), c.srcBuff.GetEndIter())\n\t}\n}", "func (b *Builder) ClearBackbuffer(ctx context.Context) (red, green, blue, black api.CmdID) {\n\tred = b.Add(\n\t\tb.CB.GlClearColor(1.0, 0.0, 0.0, 1.0),\n\t\tb.CB.GlClear(gles.GLbitfield_GL_COLOR_BUFFER_BIT),\n\t) + 1\n\tgreen = b.Add(\n\t\tb.CB.GlClearColor(0.0, 1.0, 0.0, 1.0),\n\t\tb.CB.GlClear(gles.GLbitfield_GL_COLOR_BUFFER_BIT),\n\t) + 1\n\tblue = b.Add(\n\t\tb.CB.GlClearColor(0.0, 0.0, 1.0, 1.0),\n\t\tb.CB.GlClear(gles.GLbitfield_GL_COLOR_BUFFER_BIT),\n\t) + 1\n\tblack = b.Add(\n\t\tb.CB.GlClearColor(0.0, 0.0, 0.0, 1.0),\n\t\tb.CB.GlClear(gles.GLbitfield_GL_COLOR_BUFFER_BIT),\n\t) + 1\n\treturn red, green, blue, black\n}", "func BindBuffersRange(target uint32, first uint32, count int32, buffers *uint32, offsets *int, sizes *int) {\n\tC.glowBindBuffersRange(gpBindBuffersRange, (C.GLenum)(target), (C.GLuint)(first), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(buffers)), (*C.GLintptr)(unsafe.Pointer(offsets)), (*C.GLsizeiptr)(unsafe.Pointer(sizes)))\n}", "func BindBuffersRange(target uint32, first uint32, count int32, buffers *uint32, offsets *int, sizes *int) {\n\tC.glowBindBuffersRange(gpBindBuffersRange, (C.GLenum)(target), (C.GLuint)(first), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(buffers)), (*C.GLintptr)(unsafe.Pointer(offsets)), (*C.GLsizeiptr)(unsafe.Pointer(sizes)))\n}", "func (native *OpenGL) DrawArrays(mode uint32, first int32, count int32) {\n\tgl.DrawArrays(mode, first, count)\n}", "func GenRenderbuffers(n Sizei, renderbuffers []Uint) {\n\tcn, _ := (C.GLsizei)(n), cgoAllocsUnknown\n\tcrenderbuffers, _ := (*C.GLuint)(unsafe.Pointer((*sliceHeader)(unsafe.Pointer(&renderbuffers)).Data)), cgoAllocsUnknown\n\tC.glGenRenderbuffers(cn, crenderbuffers)\n}", "func (ren *RenderComponent) generateBufferContent() []float32 {\n\tscaleX := ren.scale.X\n\tscaleY := ren.scale.Y\n\trotation := float32(0.0)\n\ttransparency := float32(1.0)\n\tc := ren.Color\n\n\tfx := float32(0)\n\tfy := float32(0)\n\tfx2 := ren.drawable.Width()\n\tfy2 := ren.drawable.Height()\n\n\tif scaleX != 1 || scaleY != 1 {\n\t\t//fx *= scaleX\n\t\t//fy *= scaleY\n\t\tfx2 *= scaleX\n\t\tfy2 *= scaleY\n\t}\n\n\tp1x := fx\n\tp1y := fy\n\tp2x := fx\n\tp2y := fy2\n\tp3x := fx2\n\tp3y := fy2\n\tp4x := fx2\n\tp4y := fy\n\n\tvar x1 float32\n\tvar y1 float32\n\tvar x2 float32\n\tvar y2 float32\n\tvar x3 float32\n\tvar y3 float32\n\tvar x4 float32\n\tvar y4 float32\n\n\tif rotation != 0 {\n\t\trot := rotation * (math.Pi / 180.0)\n\n\t\tcos := math.Cos(rot)\n\t\tsin := math.Sin(rot)\n\n\t\tx1 = cos*p1x - sin*p1y\n\t\ty1 = sin*p1x + cos*p1y\n\n\t\tx2 = cos*p2x - sin*p2y\n\t\ty2 = sin*p2x + cos*p2y\n\n\t\tx3 = cos*p3x - sin*p3y\n\t\ty3 = sin*p3x + cos*p3y\n\n\t\tx4 = x1 + (x3 - x2)\n\t\ty4 = y3 - (y2 - y1)\n\t} else {\n\t\tx1 = p1x\n\t\ty1 = p1y\n\n\t\tx2 = p2x\n\t\ty2 = p2y\n\n\t\tx3 = p3x\n\t\ty3 = p3y\n\n\t\tx4 = p4x\n\t\ty4 = p4y\n\t}\n\n\tcolorR, colorG, colorB, _ := c.RGBA()\n\n\tred := colorR\n\tgreen := colorG << 8\n\tblue := colorB << 16\n\talpha := uint32(transparency*255.0) << 24\n\n\ttint := math.Float32frombits((alpha | blue | green | red) & 0xfeffffff)\n\n\tu, v, u2, v2 := ren.drawable.View()\n\n\treturn []float32{x1, y1, u, v, tint, x4, y4, u2, v, tint, x3, y3, u2, v2, tint, x2, y2, u, v2, tint}\n}", "func BindVertexBuffers(first uint32, count int32, buffers *uint32, offsets *int, strides *int32) {\n\tC.glowBindVertexBuffers(gpBindVertexBuffers, (C.GLuint)(first), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(buffers)), (*C.GLintptr)(unsafe.Pointer(offsets)), (*C.GLsizei)(unsafe.Pointer(strides)))\n}", "func BindVertexBuffers(first uint32, count int32, buffers *uint32, offsets *int, strides *int32) {\n\tC.glowBindVertexBuffers(gpBindVertexBuffers, (C.GLuint)(first), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(buffers)), (*C.GLintptr)(unsafe.Pointer(offsets)), (*C.GLsizei)(unsafe.Pointer(strides)))\n}", "func (native *OpenGL) GenRenderbuffers(n int32) []uint32 {\n\tids := make([]uint32, n)\n\tgl.GenRenderbuffers(n, &ids[0])\n\treturn ids\n}", "func DrawArrays(mode GLenum, first int, count int) {\n\tC.glDrawArrays(C.GLenum(mode), C.GLint(first), C.GLsizei(count))\n}", "func (self *TileSprite) SetCanvasBufferA(member *PIXICanvasBuffer) {\n self.Object.Set(\"canvasBuffer\", member)\n}", "func SelectBuffer(size int32, buffer *uint32) {\n\tC.glowSelectBuffer(gpSelectBuffer, (C.GLsizei)(size), (*C.GLuint)(unsafe.Pointer(buffer)))\n}", "func Draw(bp *BoundProgram) {\n\t// TODO might still need the buffer contents to be pushed:\n\t/*\n\t\tgl.BufferData(gl.ARRAY_BUFFER, len(cube_vertices)*4, gl.Ptr(cube_vertices), gl.STATIC_DRAW)\n\t*/\n\t// TODO might still need textures to be bound for the call:\n\t/*\n\t\tgl.ActiveTexture(gl.TEXTURE0)\n\t\tgl.BindTexture(gl.TEXTURE_2D, tCache.Get(\"placeholder\"))\n\t*/\n\t// TODO draw calls are themselves still specialized and param'd:\n\t/*\n\t\tgl.DrawArrays(gl.TRIANGLES, 0, 6*2*3)\n\t*/\n}", "func GenBuffers(n int32, buffers *uint32) {\n\tC.glowGenBuffers(gpGenBuffers, (C.GLsizei)(n), (*C.GLuint)(unsafe.Pointer(buffers)))\n}", "func GenBuffers(n int32, buffers *uint32) {\n\tC.glowGenBuffers(gpGenBuffers, (C.GLsizei)(n), (*C.GLuint)(unsafe.Pointer(buffers)))\n}", "func ColorMaterial(face uint32, mode uint32) {\n\tsyscall.Syscall(gpColorMaterial, 2, uintptr(face), uintptr(mode), 0)\n}", "func (ctl *Controller) updateBuffer(position int, colour Colour) {\n\tbufferOffset := headerSize + position*ledPacketSize\n\t// Write out the brightness\n\tbrightness := colour.L\n\tif ctl.brightness != 255 {\n\t\tbrightness = uint8(float32(ctl.brightness) * float32(brightness) / 255)\n\t}\n\tif ctl.gammaFunc != nil {\n\t\t// Apply gamma correction.\n\t\tcolour = ctl.gammaFunc(colour)\n\t}\n\tctl.buffer[bufferOffset] = brightness>>3 | brightnessHeader\n\tctl.buffer[bufferOffset+ctl.rOffset] = colour.R\n\tctl.buffer[bufferOffset+ctl.bOffset] = colour.B\n\tctl.buffer[bufferOffset+ctl.gOffset] = colour.G\n}", "func BindVertexBuffers(first uint32, count int32, buffers *uint32, offsets *int, strides *int32) {\n\tsyscall.Syscall6(gpBindVertexBuffers, 5, uintptr(first), uintptr(count), uintptr(unsafe.Pointer(buffers)), uintptr(unsafe.Pointer(offsets)), uintptr(unsafe.Pointer(strides)), 0)\n}", "func BindBufferBase(target uint32, index uint32, buffer uint32) {\n C.glowBindBufferBase(gpBindBufferBase, (C.GLenum)(target), (C.GLuint)(index), (C.GLuint)(buffer))\n}", "func (debugging *debuggingOpenGL) GenRenderbuffers(n int32) []uint32 {\n\tdebugging.recordEntry(\"GenRenderbuffers\", n)\n\tresult := debugging.gl.GenRenderbuffers(n)\n\tdebugging.recordExit(\"GenRenderbuffers\", result)\n\treturn result\n}", "func (dev *Device) SetDepthBuffer(buf unsafe.Pointer) int {\n\treturn int(C.freenect_set_depth_buffer(dev.ptr(), buf))\n}", "func MultiDrawElements(mode uint32, count *int32, xtype uint32, indices *unsafe.Pointer, drawcount int32) {\n\tsyscall.Syscall6(gpMultiDrawElements, 5, uintptr(mode), uintptr(unsafe.Pointer(count)), uintptr(xtype), uintptr(unsafe.Pointer(indices)), uintptr(drawcount), 0)\n}", "func BufferData(target Enum, size Sizeiptr, data unsafe.Pointer, usage Enum) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tcsize, _ := (C.GLsizeiptr)(size), cgoAllocsUnknown\n\tcdata, _ := (unsafe.Pointer)(unsafe.Pointer(data)), cgoAllocsUnknown\n\tcusage, _ := (C.GLenum)(usage), cgoAllocsUnknown\n\tC.glBufferData(ctarget, csize, cdata, cusage)\n}", "func permuteColors(nr, ng, nb uint8) []color.Model {\n\tvar colorModels []color.Model\n\tfor _, r := range iterate(nr) {\n\t\tfor _, g := range iterate(ng) {\n\t\t\tfor _, b := range iterate(nb) {\n\t\t\t\tcolorModels = append(colorModels, clrlib.Scaled{R: r, G: g, B: b})\n\t\t\t}\n\t\t}\n\t}\n\treturn colorModels\n}", "func setBlendFunc(cmp pixel.ComposeMethod) {\n\tswitch cmp {\n\tcase pixel.ComposeOver:\n\t\tglhf.BlendFunc(glhf.One, glhf.OneMinusSrcAlpha)\n\tcase pixel.ComposeIn:\n\t\tglhf.BlendFunc(glhf.DstAlpha, glhf.Zero)\n\tcase pixel.ComposeOut:\n\t\tglhf.BlendFunc(glhf.OneMinusDstAlpha, glhf.Zero)\n\tcase pixel.ComposeAtop:\n\t\tglhf.BlendFunc(glhf.DstAlpha, glhf.OneMinusSrcAlpha)\n\tcase pixel.ComposeRover:\n\t\tglhf.BlendFunc(glhf.OneMinusDstAlpha, glhf.One)\n\tcase pixel.ComposeRin:\n\t\tglhf.BlendFunc(glhf.Zero, glhf.SrcAlpha)\n\tcase pixel.ComposeRout:\n\t\tglhf.BlendFunc(glhf.Zero, glhf.OneMinusSrcAlpha)\n\tcase pixel.ComposeRatop:\n\t\tglhf.BlendFunc(glhf.OneMinusDstAlpha, glhf.SrcAlpha)\n\tcase pixel.ComposeXor:\n\t\tglhf.BlendFunc(glhf.OneMinusDstAlpha, glhf.OneMinusSrcAlpha)\n\tcase pixel.ComposePlus:\n\t\tglhf.BlendFunc(glhf.One, glhf.One)\n\tcase pixel.ComposeCopy:\n\t\tglhf.BlendFunc(glhf.One, glhf.Zero)\n\tdefault:\n\t\tpanic(errors.New(\"Canvas: invalid compose method\"))\n\t}\n}", "func BlendColor(red float32, green float32, blue float32, alpha float32) {\n C.glowBlendColor(gpBlendColor, (C.GLfloat)(red), (C.GLfloat)(green), (C.GLfloat)(blue), (C.GLfloat)(alpha))\n}", "func BufferData(target uint32, size int, data unsafe.Pointer, usage uint32) {\n C.glowBufferData(gpBufferData, (C.GLenum)(target), (C.GLsizeiptr)(size), data, (C.GLenum)(usage))\n}", "func GenBuffers(buffers []Buffer) {\n\tgl.GenBuffers(gl.Sizei(len(buffers)), (*gl.Uint)(&buffers[0]))\n}", "func determineFormat(channels int) int {\n\tswitch channels {\n\tcase 1:\n\t\treturn gl.RED\n\tcase 2:\n\t\treturn gl.RG\n\tcase 3:\n\t\treturn gl.RGB\n\tcase 4:\n\t\treturn gl.RGBA\n\t}\n\treturn gl.RGBA\n}", "func TexBuffer(target uint32, internalformat uint32, buffer uint32) {\n C.glowTexBuffer(gpTexBuffer, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLuint)(buffer))\n}", "func BlitFramebuffer(srcX0 int32, srcY0 int32, srcX1 int32, srcY1 int32, dstX0 int32, dstY0 int32, dstX1 int32, dstY1 int32, mask uint32, filter uint32) {\n C.glowBlitFramebuffer(gpBlitFramebuffer, (C.GLint)(srcX0), (C.GLint)(srcY0), (C.GLint)(srcX1), (C.GLint)(srcY1), (C.GLint)(dstX0), (C.GLint)(dstY0), (C.GLint)(dstX1), (C.GLint)(dstY1), (C.GLbitfield)(mask), (C.GLenum)(filter))\n}", "func GenFramebuffers(n int32, framebuffers *uint32) {\n C.glowGenFramebuffers(gpGenFramebuffers, (C.GLsizei)(n), (*C.GLuint)(unsafe.Pointer(framebuffers)))\n}", "func GenBuffers(n Sizei, buffers []Uint) {\n\tcn, _ := (C.GLsizei)(n), cgoAllocsUnknown\n\tcbuffers, _ := (*C.GLuint)(unsafe.Pointer((*sliceHeader)(unsafe.Pointer(&buffers)).Data)), cgoAllocsUnknown\n\tC.glGenBuffers(cn, cbuffers)\n}", "func DrawElements(mode Enum, count Sizei, kind Enum, indices unsafe.Pointer) {\n\tcmode, _ := (C.GLenum)(mode), cgoAllocsUnknown\n\tccount, _ := (C.GLsizei)(count), cgoAllocsUnknown\n\tckind, _ := (C.GLenum)(kind), cgoAllocsUnknown\n\tcindices, _ := (unsafe.Pointer)(unsafe.Pointer(indices)), cgoAllocsUnknown\n\tC.glDrawElements(cmode, ccount, ckind, cindices)\n}", "func DrawElements(mode uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n C.glowDrawElements(gpDrawElements, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices)\n}", "func MultiDrawArraysIndirect(mode uint32, indirect unsafe.Pointer, drawcount int32, stride int32) {\n C.glowMultiDrawArraysIndirect(gpMultiDrawArraysIndirect, (C.GLenum)(mode), indirect, (C.GLsizei)(drawcount), (C.GLsizei)(stride))\n}", "func Draw(canvas *draw.RGB, opts Options) (out *draw.RGB) {\n\tw, h := 0, 0\n\tif canvas != nil {\n\t\tw, h = canvas.Size()\n\t}\n\tif w < opts.Width || h < opts.Height {\n\t\tcanvas = draw.NewRGB(opts.Width, opts.Height)\n\t}\n\n\tscale := float64(len(opts.Colors)-1) / float64(opts.Height-1)\n\tfor y := 0; y < opts.Height; y++ {\n\t\tindex := int(float64(opts.Height-1-y) * scale)\n\t\tcolor := opts.Colors[index]\n\t\tfor x := 0; x < opts.Width; x++ {\n\t\t\tcanvas.Set(x, y, color)\n\t\t}\n\t}\n\n\treturn canvas\n}", "func ColorPointer(size int32, xtype uint32, stride int32, pointer unsafe.Pointer) {\n C.glowColorPointer(gpColorPointer, (C.GLint)(size), (C.GLenum)(xtype), (C.GLsizei)(stride), pointer)\n}", "func MultiDrawElements(mode uint32, count *int32, xtype uint32, indices *unsafe.Pointer, drawcount int32) {\n\tC.glowMultiDrawElements(gpMultiDrawElements, (C.GLenum)(mode), (*C.GLsizei)(unsafe.Pointer(count)), (C.GLenum)(xtype), indices, (C.GLsizei)(drawcount))\n}", "func MultiDrawElements(mode uint32, count *int32, xtype uint32, indices *unsafe.Pointer, drawcount int32) {\n\tC.glowMultiDrawElements(gpMultiDrawElements, (C.GLenum)(mode), (*C.GLsizei)(unsafe.Pointer(count)), (C.GLenum)(xtype), indices, (C.GLsizei)(drawcount))\n}", "func BindBufferRange(target uint32, index uint32, buffer uint32, offset int, size int) {\n C.glowBindBufferRange(gpBindBufferRange, (C.GLenum)(target), (C.GLuint)(index), (C.GLuint)(buffer), (C.GLintptr)(offset), (C.GLsizeiptr)(size))\n}", "func BindBuffer(target uint32, buffer uint32) {\n C.glowBindBuffer(gpBindBuffer, (C.GLenum)(target), (C.GLuint)(buffer))\n}", "func (rs *RenderSystem) prepare() {\n\tgl.Enable(gl.CULL_FACE)\n\tgl.CullFace(gl.BACK)\n\tgl.Enable(gl.DEPTH_TEST)\n\tgl.Clear(gl.COLOR_BUFFER_BIT | gl.DEPTH_BUFFER_BIT)\n\tgl.ClearColor(rs.BaseColour.R, rs.BaseColour.G, rs.BaseColour.B, rs.BaseColour.A)\n\tif rs.drawPolygon {\n\t\tgl.PolygonMode(gl.FRONT_AND_BACK, gl.LINE)\n\t} else {\n\t\tgl.PolygonMode(gl.FRONT_AND_BACK, gl.FILL)\n\t}\n}", "func DrawElements(mode Enum, count int, ty Enum, offset int) {\n\tgl.DrawElements(uint32(mode), int32(count), uint32(ty), gl.PtrOffset(offset))\n}", "func BufferSubData(target Enum, offset Intptr, size Sizeiptr, data unsafe.Pointer) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tcoffset, _ := (C.GLintptr)(offset), cgoAllocsUnknown\n\tcsize, _ := (C.GLsizeiptr)(size), cgoAllocsUnknown\n\tcdata, _ := (unsafe.Pointer)(unsafe.Pointer(data)), cgoAllocsUnknown\n\tC.glBufferSubData(ctarget, coffset, csize, cdata)\n}", "func CopyBufferSubData(readTarget uint32, writeTarget uint32, readOffset int, writeOffset int, size int) {\n C.glowCopyBufferSubData(gpCopyBufferSubData, (C.GLenum)(readTarget), (C.GLenum)(writeTarget), (C.GLintptr)(readOffset), (C.GLintptr)(writeOffset), (C.GLsizeiptr)(size))\n}", "func ReadBuffer(mode uint32) {\n C.glowReadBuffer(gpReadBuffer, (C.GLenum)(mode))\n}", "func RenderbufferStorage(target uint32, internalformat uint32, width int32, height int32) {\n C.glowRenderbufferStorage(gpRenderbufferStorage, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func BindBuffersBase(target uint32, first uint32, count int32, buffers *uint32) {\n\tsyscall.Syscall6(gpBindBuffersBase, 4, uintptr(target), uintptr(first), uintptr(count), uintptr(unsafe.Pointer(buffers)), 0, 0)\n}", "func MultiDrawElementsBaseVertex(mode uint32, count *int32, xtype uint32, indices *unsafe.Pointer, drawcount int32, basevertex *int32) {\n C.glowMultiDrawElementsBaseVertex(gpMultiDrawElementsBaseVertex, (C.GLenum)(mode), (*C.GLsizei)(unsafe.Pointer(count)), (C.GLenum)(xtype), indices, (C.GLsizei)(drawcount), (*C.GLint)(unsafe.Pointer(basevertex)))\n}", "func SetBlendColor(red Float, green Float, blue Float, alpha Float) {\n\tcred, _ := (C.GLfloat)(red), cgoAllocsUnknown\n\tcgreen, _ := (C.GLfloat)(green), cgoAllocsUnknown\n\tcblue, _ := (C.GLfloat)(blue), cgoAllocsUnknown\n\tcalpha, _ := (C.GLfloat)(alpha), cgoAllocsUnknown\n\tC.glBlendColor(cred, cgreen, cblue, calpha)\n}", "func ColorSubTable(target uint32, start int32, count int32, format uint32, xtype uint32, data unsafe.Pointer) {\n C.glowColorSubTable(gpColorSubTable, (C.GLenum)(target), (C.GLsizei)(start), (C.GLsizei)(count), (C.GLenum)(format), (C.GLenum)(xtype), data)\n}", "func BindBufferBase(target uint32, index uint32, buffer uint32) {\n\tC.glowBindBufferBase(gpBindBufferBase, (C.GLenum)(target), (C.GLuint)(index), (C.GLuint)(buffer))\n}", "func BindBufferBase(target uint32, index uint32, buffer uint32) {\n\tC.glowBindBufferBase(gpBindBufferBase, (C.GLenum)(target), (C.GLuint)(index), (C.GLuint)(buffer))\n}", "func TexBufferRange(target uint32, internalformat uint32, buffer uint32, offset int, size int) {\n C.glowTexBufferRange(gpTexBufferRange, (C.GLenum)(target), (C.GLenum)(internalformat), (C.GLuint)(buffer), (C.GLintptr)(offset), (C.GLsizeiptr)(size))\n}", "func InvalidateBufferData(buffer uint32) {\n C.glowInvalidateBufferData(gpInvalidateBufferData, (C.GLuint)(buffer))\n}", "func appPaint(glctx gl.Context, sz size.Event, delta float32) {\n\tglctx.ClearColor(currentScene.BGColor.R, currentScene.BGColor.G, currentScene.BGColor.B, currentScene.BGColor.A)\n\tglctx.Clear(gl.COLOR_BUFFER_BIT | gl.DEPTH_BUFFER_BIT)\n\tfor _, child := range currentScene.Children {\n\t\tchild.act(delta)\n\t\tchild.draw(tempBatch, 1.0)\n\t\tif len(InputChannel) > 0 {\n\t\t\tfor e := range InputChannel {\n\t\t\t\tif child.Input != nil {\n\t\t\t\t\tchild.Input(child, e)\n\t\t\t\t}\n\t\t\t\tif len(InputChannel) == 0 {\n\t\t\t\t\tbreak\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\tglctx.UseProgram(program)\n\n\tgreen += 0.01\n\tif green > 1 {\n\t\tgreen = 0\n\t}\n\tglctx.Uniform4f(color, 0, green, 0, 1)\n\n\tglctx.Uniform2f(offset, touchX/float32(sz.WidthPx), touchY/float32(sz.HeightPx))\n\n\tglctx.BindBuffer(gl.ARRAY_BUFFER, buf)\n\tglctx.EnableVertexAttribArray(position)\n\tglctx.VertexAttribPointer(position, coordsPerVertex, gl.FLOAT, false, 0, 0)\n\tglctx.DrawArrays(gl.TRIANGLES, 0, vertexCount)\n\tglctx.DisableVertexAttribArray(position)\n\n\tfps.Draw(sz)\n}" ]
[ "0.60221946", "0.5985975", "0.5961437", "0.5902902", "0.5872059", "0.5855895", "0.58178115", "0.58178115", "0.57595015", "0.5677492", "0.56419396", "0.5636856", "0.5631684", "0.56155914", "0.55035394", "0.5503148", "0.55008405", "0.5482445", "0.54687625", "0.54687625", "0.54476786", "0.5441536", "0.5435997", "0.5435997", "0.5432256", "0.5335974", "0.5325292", "0.53233576", "0.52922684", "0.5265326", "0.5265326", "0.52612615", "0.52612615", "0.52346265", "0.5224339", "0.5224339", "0.5222619", "0.5211603", "0.5190144", "0.5189508", "0.5188342", "0.5182627", "0.51603574", "0.51594776", "0.51594776", "0.5143104", "0.51423246", "0.5132598", "0.50846547", "0.50846547", "0.50782514", "0.5073382", "0.50535023", "0.5053017", "0.5022389", "0.4999467", "0.4999467", "0.49873215", "0.4974412", "0.49742463", "0.49741742", "0.4973415", "0.4967857", "0.49658903", "0.49554762", "0.4946132", "0.494044", "0.4900943", "0.48982266", "0.48928264", "0.48847967", "0.4879419", "0.48763967", "0.4862726", "0.48531947", "0.4852143", "0.48470983", "0.48469946", "0.48455918", "0.4844155", "0.48435286", "0.48435286", "0.48425934", "0.48342687", "0.4822126", "0.48058742", "0.48000613", "0.47921562", "0.47893438", "0.47832197", "0.4782189", "0.47769707", "0.4775695", "0.47735336", "0.47679374", "0.47679374", "0.47550097", "0.47435144", "0.47399408" ]
0.5156084
46
Specifies a list of color buffers to be drawn into
func DrawBuffers(n int32, bufs *uint32) { C.glowDrawBuffers(gpDrawBuffers, (C.GLsizei)(n), (*C.GLenum)(unsafe.Pointer(bufs))) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func (f *Framebuffer) Paint(r vnclib.Rectangle, colors []vnclib.Color) {\n\tif glog.V(4) {\n\t\tglog.Info(venuelib.FnNameWithArgs(r.String(), \"colors\"))\n\t}\n\t// TODO(kward): Implement double or triple buffering to reduce paint\n\t// interference.\n\tfor x := 0; x < int(r.Width); x++ {\n\t\tfor y := 0; y < int(r.Height); y++ {\n\t\t\tc := colors[x+y*int(r.Width)]\n\t\t\tf.fb.SetRGBA(x+int(r.X), y+int(r.Y), color.RGBA{uint8(c.R), uint8(c.G), uint8(c.B), 255})\n\t\t}\n\t}\n}", "func DrawBuffers(n int32, bufs *uint32) {\n C.glowDrawBuffers(gpDrawBuffers, (C.GLsizei)(n), (*C.GLenum)(unsafe.Pointer(bufs)))\n}", "func DrawBuffers(n int32, bufs *uint32) {\n\tsyscall.Syscall(gpDrawBuffers, 2, uintptr(n), uintptr(unsafe.Pointer(bufs)), 0)\n}", "func DrawArrays(mode uint32, first int32, count int32) {\n C.glowDrawArrays(gpDrawArrays, (C.GLenum)(mode), (C.GLint)(first), (C.GLsizei)(count))\n}", "func (debugging *debuggingOpenGL) DrawBuffers(buffers []uint32) {\n\tdebugging.recordEntry(\"DrawBuffers\", buffers)\n\tdebugging.gl.DrawBuffers(buffers)\n\tdebugging.recordExit(\"DrawBuffers\")\n}", "func MultiDrawArrays(mode uint32, first *int32, count *int32, drawcount int32) {\n C.glowMultiDrawArrays(gpMultiDrawArrays, (C.GLenum)(mode), (*C.GLint)(unsafe.Pointer(first)), (*C.GLsizei)(unsafe.Pointer(count)), (C.GLsizei)(drawcount))\n}", "func DrawArrays(mode uint32, first int32, count int32) {\n\tsyscall.Syscall(gpDrawArrays, 3, uintptr(mode), uintptr(first), uintptr(count))\n}", "func MultiDrawArrays(mode uint32, first *int32, count *int32, drawcount int32) {\n\tsyscall.Syscall6(gpMultiDrawArrays, 4, uintptr(mode), uintptr(unsafe.Pointer(first)), uintptr(unsafe.Pointer(count)), uintptr(drawcount), 0, 0)\n}", "func GenRenderbuffers(n int32, renderbuffers *uint32) {\n C.glowGenRenderbuffers(gpGenRenderbuffers, (C.GLsizei)(n), (*C.GLuint)(unsafe.Pointer(renderbuffers)))\n}", "func DrawArrays(mode Enum, first, count int) {\n\tgl.DrawArrays(uint32(mode), int32(first), int32(count))\n}", "func BindVertexBuffers(first uint32, count int32, buffers *uint32, offsets *int, strides *int32) {\n C.glowBindVertexBuffers(gpBindVertexBuffers, (C.GLuint)(first), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(buffers)), (*C.GLintptr)(unsafe.Pointer(offsets)), (*C.GLsizei)(unsafe.Pointer(strides)))\n}", "func BindBuffersRange(target uint32, first uint32, count int32, buffers *uint32, offsets *int, sizes *int) {\n C.glowBindBuffersRange(gpBindBuffersRange, (C.GLenum)(target), (C.GLuint)(first), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(buffers)), (*C.GLintptr)(unsafe.Pointer(offsets)), (*C.GLsizeiptr)(unsafe.Pointer(sizes)))\n}", "func (native *OpenGL) DrawBuffers(n int32, bufs *uint32) {\n\tgl.DrawBuffers(n, bufs)\n}", "func DrawArrays(mode Enum, first Int, count Sizei) {\n\tcmode, _ := (C.GLenum)(mode), cgoAllocsUnknown\n\tcfirst, _ := (C.GLint)(first), cgoAllocsUnknown\n\tccount, _ := (C.GLsizei)(count), cgoAllocsUnknown\n\tC.glDrawArrays(cmode, cfirst, ccount)\n}", "func NamedFramebufferDrawBuffers(framebuffer uint32, n int32, bufs *uint32) {\n\tsyscall.Syscall(gpNamedFramebufferDrawBuffers, 3, uintptr(framebuffer), uintptr(n), uintptr(unsafe.Pointer(bufs)))\n}", "func DrawArrays(mode uint32, first int32, count int32) {\n\tC.glowDrawArrays(gpDrawArrays, (C.GLenum)(mode), (C.GLint)(first), (C.GLsizei)(count))\n}", "func DrawArrays(mode uint32, first int32, count int32) {\n\tC.glowDrawArrays(gpDrawArrays, (C.GLenum)(mode), (C.GLint)(first), (C.GLsizei)(count))\n}", "func MultiDrawArrays(mode uint32, first *int32, count *int32, drawcount int32) {\n\tC.glowMultiDrawArrays(gpMultiDrawArrays, (C.GLenum)(mode), (*C.GLint)(unsafe.Pointer(first)), (*C.GLsizei)(unsafe.Pointer(count)), (C.GLsizei)(drawcount))\n}", "func MultiDrawArrays(mode uint32, first *int32, count *int32, drawcount int32) {\n\tC.glowMultiDrawArrays(gpMultiDrawArrays, (C.GLenum)(mode), (*C.GLint)(unsafe.Pointer(first)), (*C.GLsizei)(unsafe.Pointer(count)), (C.GLsizei)(drawcount))\n}", "func (debugging *debuggingOpenGL) DrawArrays(mode uint32, first int32, count int32) {\n\tdebugging.recordEntry(\"DrawArrays\", first, count)\n\tdebugging.gl.DrawArrays(mode, first, count)\n\tdebugging.recordExit(\"DrawArrays\")\n}", "func BindBuffersRange(target uint32, first uint32, count int32, buffers *uint32, offsets *int, sizes *int) {\n\tC.glowBindBuffersRange(gpBindBuffersRange, (C.GLenum)(target), (C.GLuint)(first), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(buffers)), (*C.GLintptr)(unsafe.Pointer(offsets)), (*C.GLsizeiptr)(unsafe.Pointer(sizes)))\n}", "func BindBuffersRange(target uint32, first uint32, count int32, buffers *uint32, offsets *int, sizes *int) {\n\tC.glowBindBuffersRange(gpBindBuffersRange, (C.GLenum)(target), (C.GLuint)(first), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(buffers)), (*C.GLintptr)(unsafe.Pointer(offsets)), (*C.GLsizeiptr)(unsafe.Pointer(sizes)))\n}", "func NamedFramebufferDrawBuffers(framebuffer uint32, n int32, bufs *uint32) {\n\tC.glowNamedFramebufferDrawBuffers(gpNamedFramebufferDrawBuffers, (C.GLuint)(framebuffer), (C.GLsizei)(n), (*C.GLenum)(unsafe.Pointer(bufs)))\n}", "func NamedFramebufferDrawBuffers(framebuffer uint32, n int32, bufs *uint32) {\n\tC.glowNamedFramebufferDrawBuffers(gpNamedFramebufferDrawBuffers, (C.GLuint)(framebuffer), (C.GLsizei)(n), (*C.GLenum)(unsafe.Pointer(bufs)))\n}", "func GenBuffers(n int32, buffers *uint32) {\n C.glowGenBuffers(gpGenBuffers, (C.GLsizei)(n), (*C.GLuint)(unsafe.Pointer(buffers)))\n}", "func GenRenderbuffers(n int32, renderbuffers *uint32) {\n\tC.glowGenRenderbuffers(gpGenRenderbuffers, (C.GLsizei)(n), (*C.GLuint)(unsafe.Pointer(renderbuffers)))\n}", "func GenRenderbuffers(n int32, renderbuffers *uint32) {\n\tC.glowGenRenderbuffers(gpGenRenderbuffers, (C.GLsizei)(n), (*C.GLuint)(unsafe.Pointer(renderbuffers)))\n}", "func BindBuffersBase(target uint32, first uint32, count int32, buffers *uint32) {\n C.glowBindBuffersBase(gpBindBuffersBase, (C.GLenum)(target), (C.GLuint)(first), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(buffers)))\n}", "func GenRenderbuffers(n int32, renderbuffers *uint32) {\n\tsyscall.Syscall(gpGenRenderbuffers, 2, uintptr(n), uintptr(unsafe.Pointer(renderbuffers)), 0)\n}", "func GenBuffers(buffers []Buffer) {\n\tgl.GenBuffers(gl.Sizei(len(buffers)), (*gl.Uint)(&buffers[0]))\n}", "func BindVertexBuffers(first uint32, count int32, buffers *uint32, offsets *int, strides *int32) {\n\tC.glowBindVertexBuffers(gpBindVertexBuffers, (C.GLuint)(first), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(buffers)), (*C.GLintptr)(unsafe.Pointer(offsets)), (*C.GLsizei)(unsafe.Pointer(strides)))\n}", "func BindVertexBuffers(first uint32, count int32, buffers *uint32, offsets *int, strides *int32) {\n\tC.glowBindVertexBuffers(gpBindVertexBuffers, (C.GLuint)(first), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(buffers)), (*C.GLintptr)(unsafe.Pointer(offsets)), (*C.GLsizei)(unsafe.Pointer(strides)))\n}", "func (d Device) WriteColors(buf []color.RGBA) error {\n\tfor _, color := range buf {\n\t\td.WriteByte(color.G) // green\n\t\td.WriteByte(color.R) // red\n\t\td.WriteByte(color.B) // blue\n\t}\n\treturn nil\n}", "func draw(window *glfw.Window, reactProg, landProg uint32) {\n\n\tvar renderLoops = 4\n\tfor i := 0; i < renderLoops; i++ {\n\t\t// -- DRAW TO BUFFER --\n\t\t// define destination of pixels\n\t\t//gl.BindFramebuffer(gl.FRAMEBUFFER, 0)\n\t\tgl.BindFramebuffer(gl.FRAMEBUFFER, FBO[1])\n\n\t\tgl.Viewport(0, 0, width, height) // Retina display doubles the framebuffer !?!\n\n\t\tgl.Clear(gl.COLOR_BUFFER_BIT | gl.DEPTH_BUFFER_BIT)\n\t\tgl.UseProgram(reactProg)\n\n\t\t// bind Texture\n\t\tgl.ActiveTexture(gl.TEXTURE0)\n\t\tgl.BindTexture(gl.TEXTURE_2D, renderedTexture)\n\t\tgl.Uniform1i(uniTex, 0)\n\n\t\tgl.BindVertexArray(VAO)\n\t\tgl.DrawElements(gl.TRIANGLE_STRIP, int32(len(indices)), gl.UNSIGNED_INT, nil)\n\n\t\tgl.BindVertexArray(0)\n\n\t\t// -- copy back textures --\n\t\tgl.BindFramebuffer(gl.READ_FRAMEBUFFER, FBO[1]) // source is high res array\n\t\tgl.ReadBuffer(gl.COLOR_ATTACHMENT0)\n\t\tgl.BindFramebuffer(gl.DRAW_FRAMEBUFFER, FBO[0]) // destination is cells array\n\t\tgl.DrawBuffer(gl.COLOR_ATTACHMENT0)\n\t\tgl.BlitFramebuffer(0, 0, width, height,\n\t\t\t0, 0, cols, rows,\n\t\t\tgl.COLOR_BUFFER_BIT, gl.NEAREST) // downsample\n\t\tgl.BindFramebuffer(gl.READ_FRAMEBUFFER, FBO[0]) // source is low res array - put in texture\n\t\t// read pixels saves data read as unsigned bytes and then loads them in TexImage same way\n\t\tgl.ReadPixels(0, 0, cols, rows, gl.RGBA, gl.FLOAT, gl.Ptr(fData))\n\t\tgl.BindTexture(gl.TEXTURE_2D, renderedTexture)\n\t\tgl.TexImage2D(gl.TEXTURE_2D, 0, gl.RGBA, cols, rows, 0, gl.RGBA, gl.FLOAT, gl.Ptr(fData))\n\t\tCheckGLErrors()\n\t}\n\t// -- DRAW TO SCREEN --\n\tvar model glm.Mat4\n\n\t// destination 0 means screen\n\tgl.BindFramebuffer(gl.FRAMEBUFFER, 0)\n\tgl.Viewport(0, 0, width*2, height*2) // Retina display doubles the framebuffer !?!\n\tgl.Clear(gl.COLOR_BUFFER_BIT | gl.DEPTH_BUFFER_BIT)\n\tgl.UseProgram(landProg)\n\t// bind Texture\n\tgl.ActiveTexture(gl.TEXTURE0)\n\tgl.BindTexture(gl.TEXTURE_2D, drawTexture)\n\n\tvar view glm.Mat4\n\tvar brakeFactor = float64(20000.0)\n\tvar xCoord, yCoord float32\n\txCoord = float32(-3.0 * math.Sin(float64(myClock)))\n\tyCoord = float32(-3.0 * math.Cos(float64(myClock)))\n\t//xCoord = 0.0\n\t//yCoord = float32(-2.5)\n\tmyClock = math.Mod((myClock + float64(deltaTime)/brakeFactor), (math.Pi * 2))\n\tview = glm.LookAt(xCoord, yCoord, 2.0, 0.0, 0.0, 0.0, 0.0, 0.0, 1.0)\n\tgl.UniformMatrix4fv(uniView, 1, false, &view[0])\n\tmodel = glm.HomogRotate3DX(glm.DegToRad(00.0))\n\tgl.UniformMatrix4fv(uniModel, 1, false, &model[0])\n\tgl.Uniform1i(uniTex2, 0)\n\n\t// render container\n\t//gl.PolygonMode(gl.FRONT_AND_BACK, gl.FILL)\n\t//gl.PolygonMode(gl.FRONT_AND_BACK, gl.LINE)\n\n\tgl.BindVertexArray(VAO)\n\tgl.DrawElements(gl.TRIANGLE_STRIP, int32(len(indices)), gl.UNSIGNED_INT, nil)\n\tgl.BindVertexArray(0)\n\n\tCheckGLErrors()\n\n\tglfw.PollEvents()\n\twindow.SwapBuffers()\n\n\t//time.Sleep(100 * 1000 * 1000)\n}", "func GenRenderbuffers(n Sizei, renderbuffers []Uint) {\n\tcn, _ := (C.GLsizei)(n), cgoAllocsUnknown\n\tcrenderbuffers, _ := (*C.GLuint)(unsafe.Pointer((*sliceHeader)(unsafe.Pointer(&renderbuffers)).Data)), cgoAllocsUnknown\n\tC.glGenRenderbuffers(cn, crenderbuffers)\n}", "func (native *OpenGL) DrawArrays(mode uint32, first int32, count int32) {\n\tgl.DrawArrays(mode, first, count)\n}", "func DrawArrays(mode GLenum, first int, count int) {\n\tC.glDrawArrays(C.GLenum(mode), C.GLint(first), C.GLsizei(count))\n}", "func (native *OpenGL) GenRenderbuffers(n int32) []uint32 {\n\tids := make([]uint32, n)\n\tgl.GenRenderbuffers(n, &ids[0])\n\treturn ids\n}", "func DrawBuffer(mode uint32) {\n C.glowDrawBuffer(gpDrawBuffer, (C.GLenum)(mode))\n}", "func CallList(list uint32) {\n C.glowCallList(gpCallList, (C.GLuint)(list))\n}", "func BindVertexBuffers(first uint32, count int32, buffers *uint32, offsets *int, strides *int32) {\n\tsyscall.Syscall6(gpBindVertexBuffers, 5, uintptr(first), uintptr(count), uintptr(unsafe.Pointer(buffers)), uintptr(unsafe.Pointer(offsets)), uintptr(unsafe.Pointer(strides)), 0)\n}", "func MultiDrawElements(mode uint32, count *int32, xtype uint32, indices *unsafe.Pointer, drawcount int32) {\n C.glowMultiDrawElements(gpMultiDrawElements, (C.GLenum)(mode), (*C.GLsizei)(unsafe.Pointer(count)), (C.GLenum)(xtype), indices, (C.GLsizei)(drawcount))\n}", "func (c *COM) configureBuffers() {\n\t// Bit: | 7 6 | 5 | 4 | 3 | 2 | 1 | 0 |\n\t// Content: | lvl | bs | r | dma | clt | clr | e |\n\t// Value: | 1 1 | 0 | 0 | 0 | 1 | 1 | 1 | = 0xc7\n\tio.OutB(serialDataPort(c.Port), 0xc7)\n}", "func GenBuffers(n int32, buffers *uint32) {\n\tC.glowGenBuffers(gpGenBuffers, (C.GLsizei)(n), (*C.GLuint)(unsafe.Pointer(buffers)))\n}", "func GenBuffers(n int32, buffers *uint32) {\n\tC.glowGenBuffers(gpGenBuffers, (C.GLsizei)(n), (*C.GLuint)(unsafe.Pointer(buffers)))\n}", "func MultiDrawElements(mode uint32, count *int32, xtype uint32, indices *unsafe.Pointer, drawcount int32) {\n\tsyscall.Syscall6(gpMultiDrawElements, 5, uintptr(mode), uintptr(unsafe.Pointer(count)), uintptr(xtype), uintptr(unsafe.Pointer(indices)), uintptr(drawcount), 0)\n}", "func DrawElements(mode Enum, count Sizei, kind Enum, indices unsafe.Pointer) {\n\tcmode, _ := (C.GLenum)(mode), cgoAllocsUnknown\n\tccount, _ := (C.GLsizei)(count), cgoAllocsUnknown\n\tckind, _ := (C.GLenum)(kind), cgoAllocsUnknown\n\tcindices, _ := (unsafe.Pointer)(unsafe.Pointer(indices)), cgoAllocsUnknown\n\tC.glDrawElements(cmode, ccount, ckind, cindices)\n}", "func BindBuffersBase(target uint32, first uint32, count int32, buffers *uint32) {\n\tC.glowBindBuffersBase(gpBindBuffersBase, (C.GLenum)(target), (C.GLuint)(first), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(buffers)))\n}", "func BindBuffersBase(target uint32, first uint32, count int32, buffers *uint32) {\n\tC.glowBindBuffersBase(gpBindBuffersBase, (C.GLenum)(target), (C.GLuint)(first), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(buffers)))\n}", "func GenBuffers(n Sizei, buffers []Uint) {\n\tcn, _ := (C.GLsizei)(n), cgoAllocsUnknown\n\tcbuffers, _ := (*C.GLuint)(unsafe.Pointer((*sliceHeader)(unsafe.Pointer(&buffers)).Data)), cgoAllocsUnknown\n\tC.glGenBuffers(cn, cbuffers)\n}", "func DrawElements(mode uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n C.glowDrawElements(gpDrawElements, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices)\n}", "func (vao *VAO) BuildBuffers(shaderProgramHandle uint32) {\n\tgl.BindVertexArray(vao.handle)\n\tfor _, vbo := range vao.vertexBuffers {\n\t\tvbo.BuildVertexAttributes(shaderProgramHandle)\n\t}\n\tgl.BindVertexArray(0)\n}", "func CallList(list uint32) {\n\tC.glowCallList(gpCallList, (C.GLuint)(list))\n}", "func (debugging *debuggingOpenGL) GenRenderbuffers(n int32) []uint32 {\n\tdebugging.recordEntry(\"GenRenderbuffers\", n)\n\tresult := debugging.gl.GenRenderbuffers(n)\n\tdebugging.recordExit(\"GenRenderbuffers\", result)\n\treturn result\n}", "func DeleteBuffers(n int32, buffers *uint32) {\n C.glowDeleteBuffers(gpDeleteBuffers, (C.GLsizei)(n), (*C.GLuint)(unsafe.Pointer(buffers)))\n}", "func (c *Context) RenderDrawableList() {\n\t// Re-bind last texture and shader in case another context had overridden them\n\tif c.currentTexture != nil {\n\t\tgl.BindTexture(gl.TEXTURE_2D, c.currentTexture.id)\n\t}\n\tif c.currentShaderProgram != nil {\n\t\tgl.UseProgram(c.currentShaderProgram.id)\n\t}\n\n\tfor _, v := range c.primitivesToDraw {\n\t\tfor _, drawable := range v {\n\t\t\tc.BindTexture(drawable.Texture())\n\t\t\tshader := drawable.Shader()\n\t\t\tc.BindShader(shader)\n\t\t\t// TODO this should be done only once per frame via uniform buffers\n\t\t\tshader.SetUniform(\"mProjection\", &c.projectionMatrix)\n\t\t\tdrawable.DrawInBatch(c)\n\t\t}\n\t}\n}", "func BindBuffersRange(target uint32, first uint32, count int32, buffers *uint32, offsets *int, sizes *int) {\n\tsyscall.Syscall6(gpBindBuffersRange, 6, uintptr(target), uintptr(first), uintptr(count), uintptr(unsafe.Pointer(buffers)), uintptr(unsafe.Pointer(offsets)), uintptr(unsafe.Pointer(sizes)))\n}", "func BufferInit(target Enum, size int, usage Enum) {\n\tgl.BufferData(uint32(target), size, nil, uint32(usage))\n}", "func GenFramebuffers(n int32, framebuffers *uint32) {\n C.glowGenFramebuffers(gpGenFramebuffers, (C.GLsizei)(n), (*C.GLuint)(unsafe.Pointer(framebuffers)))\n}", "func DrawBuffer(buf uint32) {\n\tsyscall.Syscall(gpDrawBuffer, 1, uintptr(buf), 0, 0)\n}", "func (c *ChromaHighlight) ClrBuffer() {\n\tswitch c.srcBuff {\n\tcase nil:\n\t\tc.txtBuff.Delete(c.txtBuff.GetStartIter(), c.txtBuff.GetEndIter())\n\tdefault:\n\t\tc.srcBuff.Delete(c.srcBuff.GetStartIter(), c.srcBuff.GetEndIter())\n\t}\n}", "func MultiDrawElements(mode uint32, count *int32, xtype uint32, indices *unsafe.Pointer, drawcount int32) {\n\tC.glowMultiDrawElements(gpMultiDrawElements, (C.GLenum)(mode), (*C.GLsizei)(unsafe.Pointer(count)), (C.GLenum)(xtype), indices, (C.GLsizei)(drawcount))\n}", "func MultiDrawElements(mode uint32, count *int32, xtype uint32, indices *unsafe.Pointer, drawcount int32) {\n\tC.glowMultiDrawElements(gpMultiDrawElements, (C.GLenum)(mode), (*C.GLsizei)(unsafe.Pointer(count)), (C.GLenum)(xtype), indices, (C.GLsizei)(drawcount))\n}", "func BufferData(target Enum, size Sizeiptr, data unsafe.Pointer, usage Enum) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tcsize, _ := (C.GLsizeiptr)(size), cgoAllocsUnknown\n\tcdata, _ := (unsafe.Pointer)(unsafe.Pointer(data)), cgoAllocsUnknown\n\tcusage, _ := (C.GLenum)(usage), cgoAllocsUnknown\n\tC.glBufferData(ctarget, csize, cdata, cusage)\n}", "func DrawElements(mode Enum, count int, ty Enum, offset int) {\n\tgl.DrawElements(uint32(mode), int32(count), uint32(ty), gl.PtrOffset(offset))\n}", "func (native *OpenGL) GenBuffers(n int32) []uint32 {\n\tbuffers := make([]uint32, n)\n\tgl.GenBuffers(n, &buffers[0])\n\treturn buffers\n}", "func (b *Builder) ClearBackbuffer(ctx context.Context) (red, green, blue, black api.CmdID) {\n\tred = b.Add(\n\t\tb.CB.GlClearColor(1.0, 0.0, 0.0, 1.0),\n\t\tb.CB.GlClear(gles.GLbitfield_GL_COLOR_BUFFER_BIT),\n\t) + 1\n\tgreen = b.Add(\n\t\tb.CB.GlClearColor(0.0, 1.0, 0.0, 1.0),\n\t\tb.CB.GlClear(gles.GLbitfield_GL_COLOR_BUFFER_BIT),\n\t) + 1\n\tblue = b.Add(\n\t\tb.CB.GlClearColor(0.0, 0.0, 1.0, 1.0),\n\t\tb.CB.GlClear(gles.GLbitfield_GL_COLOR_BUFFER_BIT),\n\t) + 1\n\tblack = b.Add(\n\t\tb.CB.GlClearColor(0.0, 0.0, 0.0, 1.0),\n\t\tb.CB.GlClear(gles.GLbitfield_GL_COLOR_BUFFER_BIT),\n\t) + 1\n\treturn red, green, blue, black\n}", "func GenBuffers(n int32, buffers *uint32) {\n\tsyscall.Syscall(gpGenBuffers, 2, uintptr(n), uintptr(unsafe.Pointer(buffers)), 0)\n}", "func SelectBuffer(size int32, buffer *uint32) {\n C.glowSelectBuffer(gpSelectBuffer, (C.GLsizei)(size), (*C.GLuint)(unsafe.Pointer(buffer)))\n}", "func MultiDrawArraysIndirect(mode uint32, indirect unsafe.Pointer, drawcount int32, stride int32) {\n C.glowMultiDrawArraysIndirect(gpMultiDrawArraysIndirect, (C.GLenum)(mode), indirect, (C.GLsizei)(drawcount), (C.GLsizei)(stride))\n}", "func MultiDrawArraysIndirect(mode uint32, indirect unsafe.Pointer, drawcount int32, stride int32) {\n\tsyscall.Syscall6(gpMultiDrawArraysIndirect, 4, uintptr(mode), uintptr(indirect), uintptr(drawcount), uintptr(stride), 0, 0)\n}", "func BindSamplers(first uint32, count int32, samplers *uint32) {\n C.glowBindSamplers(gpBindSamplers, (C.GLuint)(first), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(samplers)))\n}", "func BindBufferRange(target uint32, index uint32, buffer uint32, offset int, size int) {\n C.glowBindBufferRange(gpBindBufferRange, (C.GLenum)(target), (C.GLuint)(index), (C.GLuint)(buffer), (C.GLintptr)(offset), (C.GLsizeiptr)(size))\n}", "func DeleteBuffers(n int32, buffers *uint32) {\n\tC.glowDeleteBuffers(gpDeleteBuffers, (C.GLsizei)(n), (*C.GLuint)(unsafe.Pointer(buffers)))\n}", "func DeleteBuffers(n int32, buffers *uint32) {\n\tC.glowDeleteBuffers(gpDeleteBuffers, (C.GLsizei)(n), (*C.GLuint)(unsafe.Pointer(buffers)))\n}", "func (w *Window) SetBuffersGeometry(width, height, format int) int {\n\treturn int(C.ANativeWindow_setBuffersGeometry(w.cptr(), C.int32_t(width), C.int32_t(height), C.int32_t(format)))\n}", "func DrawBuffer(buf uint32) {\n\tC.glowDrawBuffer(gpDrawBuffer, (C.GLenum)(buf))\n}", "func DrawBuffer(buf uint32) {\n\tC.glowDrawBuffer(gpDrawBuffer, (C.GLenum)(buf))\n}", "func BindTextures(first uint32, count int32, textures *uint32) {\n C.glowBindTextures(gpBindTextures, (C.GLuint)(first), (C.GLsizei)(count), (*C.GLuint)(unsafe.Pointer(textures)))\n}", "func (debugging *debuggingOpenGL) GenBuffers(n int32) []uint32 {\n\tdebugging.recordEntry(\"GenBuffers\", n)\n\tresult := debugging.gl.GenBuffers(n)\n\tdebugging.recordExit(\"GenBuffers\", result)\n\treturn result\n}", "func permuteColors(nr, ng, nb uint8) []color.Model {\n\tvar colorModels []color.Model\n\tfor _, r := range iterate(nr) {\n\t\tfor _, g := range iterate(ng) {\n\t\t\tfor _, b := range iterate(nb) {\n\t\t\t\tcolorModels = append(colorModels, clrlib.Scaled{R: r, G: g, B: b})\n\t\t\t}\n\t\t}\n\t}\n\treturn colorModels\n}", "func (native *OpenGL) DeleteBuffers(buffers []uint32) {\n\tgl.DeleteBuffers(int32(len(buffers)), &buffers[0])\n}", "func GetAttachedShaders(program uint32, maxCount int32, count *int32, shaders *uint32) {\n C.glowGetAttachedShaders(gpGetAttachedShaders, (C.GLuint)(program), (C.GLsizei)(maxCount), (*C.GLsizei)(unsafe.Pointer(count)), (*C.GLuint)(unsafe.Pointer(shaders)))\n}", "func NewList(list uint32, mode uint32) {\n C.glowNewList(gpNewList, (C.GLuint)(list), (C.GLenum)(mode))\n}", "func DeleteBuffers(buffers []Buffer) {\n\tgl.DeleteBuffers(gl.Sizei(len(buffers)), (*gl.Uint)(&buffers[0]))\n}", "func DrawElements(mode uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n\tC.glowDrawElements(gpDrawElements, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices)\n}", "func DrawElements(mode uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n\tC.glowDrawElements(gpDrawElements, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices)\n}", "func DrawElements(mode uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n\tsyscall.Syscall6(gpDrawElements, 4, uintptr(mode), uintptr(count), uintptr(xtype), uintptr(indices), 0, 0)\n}", "func GenFramebuffers(n Sizei, framebuffers []Uint) {\n\tcn, _ := (C.GLsizei)(n), cgoAllocsUnknown\n\tcframebuffers, _ := (*C.GLuint)(unsafe.Pointer((*sliceHeader)(unsafe.Pointer(&framebuffers)).Data)), cgoAllocsUnknown\n\tC.glGenFramebuffers(cn, cframebuffers)\n}", "func (debugging *debuggingOpenGL) DrawElements(mode uint32, count int32, elementType uint32, indices uintptr) {\n\tdebugging.recordEntry(\"DrawElements\", mode, count, elementType, indices)\n\tdebugging.gl.DrawElements(mode, count, elementType, indices)\n\tdebugging.recordExit(\"DrawElements\")\n}", "func (gl *WebGL) DrawElements(mode GLEnum, count int, valueType GLEnum, offset int) {\n\tgl.context.Call(\"drawElements\", mode, count, valueType, offset)\n}", "func DrawElements(mode GLenum, count int, typ GLenum, indices interface{}) {\n\tC.glDrawElements(C.GLenum(mode), C.GLsizei(count), C.GLenum(typ),\n\t\tptr(indices))\n}", "func (g *Gaffer) AddBuffer(u *Update) {\n\n\tfor _, v := range u.entities {\n\t\tg.AddEntity(v)\n\t}\n\n\tfor _, v := range u.edges {\n\t\tg.AddEdge(v)\n\t}\n\n}", "func BindBuffersBase(target uint32, first uint32, count int32, buffers *uint32) {\n\tsyscall.Syscall6(gpBindBuffersBase, 4, uintptr(target), uintptr(first), uintptr(count), uintptr(unsafe.Pointer(buffers)), 0, 0)\n}", "func BindBuffer(target uint32, buffer uint32) {\n C.glowBindBuffer(gpBindBuffer, (C.GLenum)(target), (C.GLuint)(buffer))\n}", "func GenFramebuffers(n int32, framebuffers *uint32) {\n\tsyscall.Syscall(gpGenFramebuffers, 2, uintptr(n), uintptr(unsafe.Pointer(framebuffers)), 0)\n}", "func (native *OpenGL) GenFramebuffers(n int32) []uint32 {\n\tids := make([]uint32, n)\n\tgl.GenFramebuffers(n, &ids[0])\n\treturn ids\n}", "func GenFramebuffers(n int32, framebuffers *uint32) {\n\tC.glowGenFramebuffers(gpGenFramebuffers, (C.GLsizei)(n), (*C.GLuint)(unsafe.Pointer(framebuffers)))\n}", "func GenFramebuffers(n int32, framebuffers *uint32) {\n\tC.glowGenFramebuffers(gpGenFramebuffers, (C.GLsizei)(n), (*C.GLuint)(unsafe.Pointer(framebuffers)))\n}" ]
[ "0.61454105", "0.61440235", "0.60909224", "0.59685224", "0.5965276", "0.59418094", "0.5908199", "0.5908036", "0.5782449", "0.578063", "0.57642007", "0.57231736", "0.5668462", "0.5654153", "0.56223226", "0.5614668", "0.5614668", "0.55978715", "0.55978715", "0.55281305", "0.5500989", "0.5500989", "0.5488479", "0.5488479", "0.5484349", "0.54466444", "0.54466444", "0.5444451", "0.54395133", "0.5422344", "0.5412865", "0.5412865", "0.5407735", "0.53985786", "0.53767896", "0.5375211", "0.53490543", "0.5340588", "0.5312724", "0.530108", "0.5285404", "0.5282942", "0.5259514", "0.5215135", "0.5215135", "0.51759154", "0.51564664", "0.51547056", "0.51547056", "0.512878", "0.5124405", "0.5121418", "0.51174307", "0.5106676", "0.50990283", "0.5098168", "0.5093054", "0.50890195", "0.50649214", "0.5064018", "0.50398237", "0.50117487", "0.50117487", "0.5002178", "0.496942", "0.4949326", "0.49485973", "0.4925245", "0.49232715", "0.4907616", "0.48920035", "0.48826683", "0.48680657", "0.48501664", "0.48501664", "0.484318", "0.4842627", "0.4842627", "0.48361936", "0.48349196", "0.48323572", "0.48033926", "0.48013872", "0.47910944", "0.47848624", "0.4780954", "0.4780954", "0.47804534", "0.47716454", "0.475887", "0.47477663", "0.47455913", "0.47423095", "0.47376755", "0.47203404", "0.4714679", "0.47114256", "0.4700541", "0.4700541" ]
0.5949
6
render primitives from array data
func DrawElements(mode uint32, count int32, xtype uint32, indices unsafe.Pointer) { C.glowDrawElements(gpDrawElements, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func renderResults(vals []interface{}) Data {\n\tvar nilcount int\n\tvar obj interface{}\n\tfor _, val := range vals {\n\t\tswitch val.(type) {\n\t\tcase image.Image, Data:\n\t\t\tobj = val\n\t\tcase nil:\n\t\t\tnilcount++\n\t\t}\n\t}\n\tif obj != nil && nilcount == len(vals)-1 {\n\t\tswitch val := obj.(type) {\n\t\tcase image.Image:\n\t\t\tdata, err := image0(val)\n\t\t\tif err == nil {\n\t\t\t\treturn data\n\t\t\t}\n\t\tcase Data:\n\t\t\treturn val\n\t\t}\n\t}\n\tif nilcount == len(vals) {\n\t\t// if all values are nil, return empty Data\n\t\treturn Data{}\n\t}\n\treturn MakeData(\"text/plain\", fmt.Sprint(vals...))\n}", "func (v Binary) Render(i, width int, baseStyle lipgloss.Style) string {\n\tw := dataWidth(width)\n\t_, err := v.Seek(int64(i*w), io.SeekStart)\n\tif err != nil {\n\t\treturn baseStyle.Blink(true).Render(err.Error())\n\t}\n\tif len(v.b) != w {\n\t\tv.b = make([]byte, w)\n\t}\n\tn, err := v.Read(v.b)\n\tif err != nil && !errors.Is(err, io.EOF) {\n\t\treturn baseStyle.Blink(true).Render(err.Error())\n\t}\n\ts := fmt.Sprintf(\"% X%s \", v.b[0:n], strings.Repeat(\" \", w-n))\n\tvar x strings.Builder\n\tfor i := 0; i < n; i++ {\n\t\tif unicode.IsPrint(rune(v.b[i])) {\n\t\t\tx.WriteRune(rune(v.b[i]))\n\t\t} else {\n\t\t\tx.WriteRune('.')\n\t\t}\n\t}\n\treturn baseStyle.Render(s + x.String())\n}", "func (sr scoresRenderer) Render() string {\n\tbuffer := bytes.Buffer{}\n\tlast := len(sr.scores) - 1\n\tfor i, score := range sr.scores {\n\t\tbuffer.WriteString(fmt.Sprintf(\"%d\", score))\n\t\tif i != last {\n\t\t\tbuffer.WriteString(\" / \")\n\t\t}\n\t}\n\treturn buffer.String()\n}", "func (r *Renderer) Render() {\n\tsx, sz, sy := r.c.Bounds()\n\tsxf := float64(sx - 1)\n\tsyf := float64(sy - 1)\n\tszf := float64(sz - 1)\n\tfor z := 0; z < sz; z++ {\n\t\tfor y := 0; y < sy; y++ {\n\t\t\tfor x := 0; x < sx; x++ {\n\t\t\t\tvar lr, lg, lb, _ uint32\n\t\t\t\tn := uint32(0)\n\t\t\t\tfor _, o := range r.objects {\n\t\t\t\t\tr, g, b, _ := o.At(float64(x)/sxf, float64(y)/syf, float64(z)/szf).RGBA()\n\t\t\t\t\tlr += r >> 8\n\t\t\t\t\tlg += g >> 8\n\t\t\t\t\tlb += b >> 8\n\t\t\t\t\tn++\n\t\t\t\t}\n\t\t\t\tr.c.Set(x, y, z, color.RGBA{uint8(lr/n), uint8(lg/n), uint8(lb/n), 255})\n\t\t\t}\n\t\t}\n\t}\n\tr.c.Render()\n}", "func render(fset *token.FileSet, x interface{}) string {\n\tvar buf bytes.Buffer\n\tif err := printer.Fprint(&buf, fset, x); err != nil {\n\t\tpanic(err)\n\t}\n\treturn buf.String()\n}", "func render(fset *token.FileSet, x interface{}) string {\n\tvar buf bytes.Buffer\n\tif err := printer.Fprint(&buf, fset, x); err != nil {\n\t\tpanic(err)\n\t}\n\treturn buf.String()\n}", "func (a Array) String() string {\n\tvar buf bytes.Buffer\n\tfor i, v := range a {\n\t\tbuf.WriteString(fmt.Sprintf(\"[%2d] %[2]v (%[2]T)\\n\", i, v))\n\t}\n\treturn buf.String()\n}", "func (e *rawData) Render(w io.Writer) (int, error) { return w.Write([]byte(e.content)) }", "func (sl SprintList) renderPlain(w io.Writer) error {\n\treturn renderPlain(w, sl.tableData())\n}", "func (t *textRender) Render(w io.Writer) (err error) {\n\tif len(t.Values) > 0 {\n\t\t_, err = fmt.Fprintf(w, t.Format, t.Values...)\n\t} else {\n\t\t_, err = io.WriteString(w, t.Format)\n\t}\n\treturn\n}", "func (val *float32ArrayValue) String() string {\n\tvar buffer strings.Builder\n\tfor _, v := range *val {\n\t\tif buffer.Len() != 0 {\n\t\t\tbuffer.WriteString(\", \")\n\t\t}\n\t\tfmt.Fprintf(&buffer, \"%v\", v)\n\t}\n\treturn buffer.String()\n}", "func (c *Controller) Data(data []byte) {\n ctx := c.Context()\n r := render.NewData(data)\n\n ctx.PushLog(\"status\", http.StatusOK)\n ctx.SetHeader(\"Content-Type\", r.ContentType())\n ctx.End(r.HttpCode(), r.Content())\n}", "func (a *Array) Print() {\n\tvar format string\n\tfor i := uint(0); i < a.Len(); i++ {\n\t\tformat += fmt.Sprintf(\"|%+v\", a.data[i])\n\t}\n\tfmt.Println(format)\n}", "func (val *uint8ArrayValue) String() string {\n\tvar buffer strings.Builder\n\tfor _, v := range *val {\n\t\tif buffer.Len() != 0 {\n\t\t\tbuffer.WriteString(\", \")\n\t\t}\n\t\tfmt.Fprintf(&buffer, \"%v\", v)\n\t}\n\treturn buffer.String()\n}", "func (tofu Tofu) Render(wr io.Writer, name string, obj interface{}) error {\n\tvar m data.Map\n\tif obj != nil {\n\t\tvar ok bool\n\t\tm, ok = data.New(obj).(data.Map)\n\t\tif !ok {\n\t\t\treturn fmt.Errorf(\"invalid data type. expected map/struct, got %T\", obj)\n\t\t}\n\t}\n\treturn tofu.NewRenderer(name).Execute(wr, m)\n}", "func (l LogItems) Render(showTime bool, ll [][]byte) {\n\tcolors := make(map[string]int, len(l))\n\tfor i, item := range l {\n\t\tinfo := item.ID()\n\t\tcolor, ok := colors[info]\n\t\tif !ok {\n\t\t\tcolor = colorFor(info)\n\t\t\tcolors[info] = color\n\t\t}\n\t\tll[i] = item.Render(color, showTime)\n\t}\n}", "func (o TypeResponseOutput) Primitive() pulumi.StringOutput {\n\treturn o.ApplyT(func(v TypeResponse) string { return v.Primitive }).(pulumi.StringOutput)\n}", "func (g *Game) Render() string {\n\tascii := \"\"\n\n\tm := g.generateScreen()\n\tfor _, row := range m.cells {\n\t\tascii += strings.Join(row, \"\") + \"\\n\"\n\t}\n\n\treturn ascii\n}", "func renderDisplayData(value interface{}) (data, metadata map[string]interface{}, err error) {\n\t// TODO(axw) sniff/provide a way to specify types for things that net/http does not sniff:\n\t// - SVG\n\t// - JSON\n\t// - LaTeX\n\tdata = make(map[string]interface{})\n\tmetadata = make(map[string]interface{})\n\tvar stringValue, contentType string\n\tswitch typedValue := value.(type) {\n\tcase image.Image:\n\t\t// TODO(axw) provide a way for the user to use alternative encodings?\n\t\t//\n\t\t// The current presumption is that images will be mostly used\n\t\t// for displaying graphs or illustrations where PNG produces\n\t\t// better looking images.\n\t\tvar buf bytes.Buffer\n\t\tif err := png.Encode(&buf, typedValue); err != nil {\n\t\t\treturn nil, nil, fmt.Errorf(\"encoding image: %v\", err)\n\t\t}\n\t\tbounds := typedValue.Bounds()\n\t\tdata[\"image/png\"] = buf.Bytes()\n\t\tdata[\"text/plain\"] = fmt.Sprintf(\"%dx%d image\", bounds.Dx(), bounds.Dy())\n\t\tmetadata[\"image/png\"] = map[string]interface{}{\n\t\t\t\"width\": bounds.Dx(),\n\t\t\t\"height\": bounds.Dy(),\n\t\t}\n\t\treturn data, metadata, nil\n\n\tcase []byte:\n\t\tcontentType = detectContentType(typedValue)\n\t\tstringValue = string(typedValue)\n\n\tcase string:\n\t\tcontentType = detectContentType([]byte(typedValue))\n\t\tstringValue = typedValue\n\n\tdefault:\n\t\tstringValue = fmt.Sprint(typedValue)\n\t\tvalue = stringValue\n\t\tcontentType = detectContentType([]byte(stringValue))\n\t}\n\n\tdata[\"text/plain\"] = stringValue\n\tif contentType != \"text/plain\" {\n\t\t// \"A plain text representation should always be\n\t\t// provided in the text/plain mime-type.\"\n\t\tdata[contentType] = value\n\t}\n\treturn data, metadata, nil\n}", "func (e *expression) printArray() string {\n\ta := \"\"\n\n\tfor i := 0; i < len(e.lenArray); i++ {\n\t\tvArray := string('i' + i)\n\t\ta += fmt.Sprintf(\"[%s]\", vArray)\n\t}\n\treturn a\n}", "func (Parser) Render(rawBytes []byte, urlPrefix string, metas map[string]string, isWiki bool) []byte {\n\treturn Render(rawBytes, urlPrefix, metas, isWiki)\n}", "func (s *SegmentRoot) Render() []byte {\n\tvar b bytes.Buffer\n\tb.Write(SetBackground(SegmentRootBackground))\n\tfmt.Fprint(&b, \" \")\n\tb.Write(s.Data)\n\tfmt.Fprint(&b, \" \")\n\treturn b.Bytes()\n}", "func (rf RendererFunc) Render(w io.Writer, v interface{}) error { return rf(w, v) }", "func Data(w http.ResponseWriter, r *http.Request, v []byte) {\n\trender.Data(w, r, v)\n}", "func (f Frame) Render() string {\n\tsb := strings.Builder{}\n\tfor _, row := range f {\n\t\tfor _, shade := range row {\n\t\t\tsb.WriteString(fmt.Sprintf(\"%d\", shade))\n\t\t}\n\t\tsb.WriteString(\"\\n\")\n\t}\n\tsb.WriteString(\"==============================\\n\")\n\n\treturn sb.String()\n}", "func (a *Array) Format(f fmt.State, c rune) {\n\tswitch c {\n\tcase 'z': // Private format specifier, supports Entity.Signature\n\t\tfmt.Fprintf(f, \"[%d]%z\", a.Size, a.ValueType)\n\tcase 'r': // Private format specifier, supports Type.Representation\n\t\tfmt.Fprintf(f, \"[%d]%r\", a.Size, a.ValueType)\n\tdefault:\n\t\tif a.Alias != \"\" {\n\t\t\tfmt.Fprint(f, a.Alias)\n\t\t} else {\n\t\t\tfmt.Fprintf(f, \"[%d]%v\", a.Size, a.ValueType)\n\t\t}\n\t}\n}", "func DrawArrays(mode Enum, first, count int) {\n\tgl.DrawArrays(uint32(mode), int32(first), int32(count))\n}", "func (c *cartridge) Render() {\n\tc.Cls()\n\tc.PrintAt(fmt.Sprintf(\"counter:%d\", c.counter), c.x, c.y)\n}", "func (r ConsoleTreeRenderer) RenderTree(root *ContainerNode, _ string) string {\n\n\tsb := strings.Builder{}\n\n\tfor _, node := range root.Items {\n\t\tfieldKey := node.Field().Name\n\t\tsb.WriteString(fieldKey)\n\t\tfor i := len(fieldKey); i <= root.MaxKeyLength; i++ {\n\t\t\tsb.WriteRune(' ')\n\t\t}\n\n\t\tvalueLen := 0\n\t\tpreLen := 16\n\n\t\tfield := node.Field()\n\n\t\tif r.WithValues {\n\t\t\tpreLen = 30\n\t\t\tvalueLen = r.writeNodeValue(&sb, node)\n\t\t} else {\n\t\t\t// Since no values was supplied, let's substitute the value with the type\n\t\t\ttypeName := field.Type.String()\n\n\t\t\t// If the value is an enum type, providing the name is a bit pointless\n\t\t\t// Instead, use a common string \"option\" to signify the type\n\t\t\tif field.EnumFormatter != nil {\n\t\t\t\ttypeName = \"option\"\n\t\t\t}\n\t\t\tvalueLen = len(typeName)\n\t\t\tsb.WriteString(color.CyanString(typeName))\n\t\t}\n\n\t\tsb.WriteString(strings.Repeat(\" \", util.Max(preLen-valueLen, 1)))\n\t\tsb.WriteString(ColorizeDesc(field.Description))\n\t\tsb.WriteString(strings.Repeat(\" \", util.Max(60-len(field.Description), 1)))\n\n\t\tif len(field.URLParts) > 0 && field.URLParts[0] != URLQuery {\n\t\t\tsb.WriteString(\" <URL: \")\n\t\t\tfor i, part := range field.URLParts {\n\t\t\t\tif i > 0 {\n\t\t\t\t\tsb.WriteString(\", \")\n\t\t\t\t}\n\t\t\t\tif part > URLPath {\n\t\t\t\t\tpart = URLPath\n\t\t\t\t}\n\t\t\t\tsb.WriteString(ColorizeEnum(part))\n\t\t\t}\n\t\t\tsb.WriteString(\">\")\n\t\t}\n\n\t\tif len(field.Template) > 0 {\n\t\t\tsb.WriteString(fmt.Sprintf(\" <Template: %s>\", ColorizeString(field.Template)))\n\t\t}\n\n\t\tif len(field.DefaultValue) > 0 {\n\t\t\tsb.WriteString(fmt.Sprintf(\" <Default: %s>\", ColorizeValue(field.DefaultValue, field.EnumFormatter != nil)))\n\t\t}\n\n\t\tif field.Required {\n\t\t\tsb.WriteString(fmt.Sprintf(\" <%s>\", ColorizeFalse(\"Required\")))\n\t\t}\n\n\t\tif len(field.Keys) > 1 {\n\t\t\tsb.WriteString(\" <Aliases: \")\n\t\t\tfor i, key := range field.Keys {\n\t\t\t\tif i == 0 {\n\t\t\t\t\t// Skip primary alias (as it's the same as the field name)\n\t\t\t\t\tcontinue\n\t\t\t\t}\n\t\t\t\tif i > 1 {\n\t\t\t\t\tsb.WriteString(\", \")\n\t\t\t\t}\n\t\t\t\tsb.WriteString(ColorizeString(key))\n\t\t\t}\n\t\t\tsb.WriteString(\">\")\n\t\t}\n\n\t\tif field.EnumFormatter != nil {\n\t\t\tsb.WriteString(ColorizeContainer(\" [\"))\n\t\t\tfor i, name := range field.EnumFormatter.Names() {\n\t\t\t\tif i != 0 {\n\t\t\t\t\tsb.WriteString(\", \")\n\t\t\t\t}\n\t\t\t\tsb.WriteString(ColorizeEnum(name))\n\t\t\t}\n\n\t\t\tsb.WriteString(ColorizeContainer(\"]\"))\n\t\t}\n\n\t\tsb.WriteRune('\\n')\n\t}\n\n\treturn sb.String()\n}", "func (vao *VAO) Render() {\n\tgl.BindVertexArray(vao.handle)\n\tif vao.indexBuffer != nil {\n\t\tgl.BindBuffer(gl.ELEMENT_ARRAY_BUFFER, vao.indexBuffer.GetHandle())\n\t\tgl.DrawElements(vao.mode, vao.indexBuffer.Len(), gl.UNSIGNED_SHORT, nil)\n\t\tgl.BindBuffer(gl.ELEMENT_ARRAY_BUFFER, 0)\n\t} else {\n\t\tgl.DrawArrays(vao.mode, 0, vao.vertexBuffers[0].Len())\n\t}\n\tgl.BindVertexArray(0)\n}", "func (r *Renderer) Render() {\n\tgl.DrawArrays(gl.TRIANGLES, 0, int32(len(r.RawRenderer)*4))\n}", "func (s *Square) Render() string {\n\treturn fmt.Sprintf(\"Square side %f\", s.Side)\n}", "func (renderer *SimpleMatrixRenderer) Render() {\n\trenderer.renderCharacter(\"\\n\")\n\n\tfor row := 0; row < renderer.Matrix.Height; row++ {\n\t\tfor col := 0; col < renderer.Matrix.Width; col++ {\n\t\t\tif !renderer.Matrix.IsFieldOccupied(row, col) {\n\t\t\t\trenderer.renderUnoccupiedField()\n\t\t\t} else {\n\t\t\t\trenderer.renderOccupiedFieldAtCurrentCursorPos(row, col)\n\t\t\t}\n\t\t}\n\n\t\trenderer.renderCharacter(\"\\n\")\n\t}\n\n\trenderer.renderCharacter(\"\\n\")\n}", "func (a *Array) String() string {\n\tbuf := new(bytes.Buffer)\n\tfor i := len(a.bits) - 1; i >= 0; i-- {\n\t\tbits := fmt.Sprintf(\"%16X\", a.bits[i])\n\t\tbits = strings.Replace(bits, \" \", \"0\", -1)\n\t\tfmt.Fprintf(buf, \"%s [%d-%d] \", bits, (i<<6)+63, i<<6)\n\t}\n\n\treturn buf.String()\n}", "func (h *HAProxyManager) render(ports []uint16) ([]byte, error) {\n\n\t// prepare the context\n\td := make([]templateContext, len(ports))\n\tfor i, port := range ports {\n\t\tif i == len(h.serviceAddrs) {\n\t\t\th.logger.Warnf(\"got port index %d, but only have %d service addrs. ports=%v serviceAddrs=%v\", i, len(h.serviceAddrs), ports, h.serviceAddrs)\n\t\t\tcontinue\n\t\t}\n\t\td[i] = templateContext{Port: port, Source: h.listenAddr, Dest: h.serviceAddrs[i]}\n\t}\n\n\t// render the template\n\tbuf := &bytes.Buffer{}\n\tif err := h.template.Execute(buf, d); err != nil {\n\t\treturn nil, err\n\t}\n\treturn buf.Bytes(), nil\n}", "func PrintArr(a []interface{}) {\n\tvar i int\n\tfor i < len(a) {\n\t\tfmt.Printf(\"%v\\t\", a[i])\n\t\ti++\n\t}\n\tfmt.Printf(\"\\n\")\n}", "func (a *Array) Literal() {}", "func (c *Client) ShowArrayPrism(ctx context.Context, path string, anyArray []interface{}, boolArray []bool, dateTimeArray []time.Time, intArray []int, numArray []float64, stringArray []string, uuidArray []uuid.UUID) (*http.Response, error) {\n\treq, err := c.NewShowArrayPrismRequest(ctx, path, anyArray, boolArray, dateTimeArray, intArray, numArray, stringArray, uuidArray)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\treturn c.Client.Do(ctx, req)\n}", "func (c *ConnectionSPI) Render(pixels []RGBPixel) {\r\n\tlogFields := log.Fields{\"package\": logPkg, \"conn\": \"SPI\", \"func\": \"RenderLEDs\"}\r\n\tlog.WithFields(logFields).Infof(\"Render %d LEDs\", len(pixels))\r\n\t// Fix for Raspberry Pi 3 Model B+ (5.15.84-v7+)\r\n\t// Data signal seems to be splitted sending less than 11 LEDS\r\n\tif len(pixels) < 11 {\r\n\t\tpixels = append(pixels, []RGBPixel{{}, {}, {}, {}, {}, {}, {}, {}, {}, {}}...)\r\n\t}\r\n\tvar translatedRGBs []uint8\r\n\tfor _, pixel := range pixels {\r\n\r\n\t\tcolorData := GetColorData(pixel, c.FixSPI)\r\n\t\tlog.WithFields(logFields).Tracef(\"%08b\", pixel)\r\n\r\n\t\tfor _, c := range colorData {\r\n\t\t\ttranslatedRGBs = append(translatedRGBs, c)\r\n\t\t}\r\n\t}\r\n\r\n\tc.transfer(translatedRGBs)\r\n}", "func (l *LogItems) Render(showTime bool, ll [][]byte) {\n\tindex := len(l.colors)\n\tfor i, item := range l.items {\n\t\tid := item.ID()\n\t\tcolor, ok := l.colors[id]\n\t\tif !ok {\n\t\t\tif index >= len(colorPalette) {\n\t\t\t\tindex = 0\n\t\t\t}\n\t\t\tcolor = colorPalette[index]\n\t\t\tl.colors[id] = color\n\t\t\tindex++\n\t\t}\n\t\tll[i] = item.Render(int(color-tcell.ColorValid), showTime)\n\t}\n}", "func Text(v interface{}) HTML {\n return HTML(\"\\n\" + html.EscapeString(fmt.Sprint(v)))\n}", "func Render(expr expreduceapi.Ex) (chart.Chart, error) {\n\tgraph := chart.Chart{\n\t\tWidth: 360,\n\t\tHeight: 220,\n\t\tXAxis: chart.XAxis{\n\t\t\tStyle: chart.Style{Show: true},\n\t\t},\n\t\tYAxis: chart.YAxis{\n\t\t\tStyle: chart.Style{Show: true},\n\t\t},\n\t}\n\n\tgraphics, ok := atoms.HeadAssertion(expr, \"System`Graphics\")\n\tif !ok {\n\t\treturn graph, fmt.Errorf(\"trying to render a non-Graphics[] expression: %v\", expr)\n\t}\n\n\tif graphics.Len() < 1 {\n\t\treturn graph, errors.New(\"the Graphics[] expression must have at least one argument\")\n\t}\n\n\tstyle := chart.Style{\n\t\tShow: true,\n\t\tStrokeColor: drawing.ColorBlack,\n\t}\n\terr := renderPrimitive(&graph, graphics.GetPart(1), &style)\n\tif err != nil {\n\t\treturn graph, errors.New(\"failed to render primitive\")\n\t}\n\n\treturn graph, nil\n}", "func (native *OpenGL) DrawElements(mode uint32, count int32, elementType uint32, indices uintptr) {\n\tgl.DrawElements(mode, count, elementType, unsafe.Pointer(indices)) // nolint: govet,gas\n}", "func main() {\n\t//composite literal - create different values of a type\n\t// x := type{values}\n\t//group together values OF THE SAME TYPE\n\tx := []int{4, 5, 7, 8, 42}\n\n\tfmt.Println(x)\n\tfmt.Println(x[0]) //query by index position\n\tfmt.Println(x[1])\n\tfmt.Println(x[2])\n\tfmt.Println(x[3])\n\tfmt.Println(x[4])\n\tfmt.Println(cap(x))\n\n\t//for index and value in the range of x print\n\tfor i, v := range x {\n\t\tfmt.Println(i, v)\n\t}\n}", "func (obj *Device) DrawIndexedPrimitive(\n\ttyp PRIMITIVETYPE,\n\tbaseVertexIndex int,\n\tminIndex uint,\n\tnumVertices uint,\n\tstartIndex uint,\n\tprimitiveCount uint,\n) Error {\n\tret, _, _ := syscall.Syscall9(\n\t\tobj.vtbl.DrawIndexedPrimitive,\n\t\t7,\n\t\tuintptr(unsafe.Pointer(obj)),\n\t\tuintptr(typ),\n\t\tuintptr(baseVertexIndex),\n\t\tuintptr(minIndex),\n\t\tuintptr(numVertices),\n\t\tuintptr(startIndex),\n\t\tuintptr(primitiveCount),\n\t\t0,\n\t\t0,\n\t)\n\treturn toErr(ret)\n}", "func (d *Device) Render() error {\n\tbuf := new(bytes.Buffer)\n\n\tfor _, chain := range d.LEDs {\n\t\tfor _, col := range chain {\n\t\t\tbuf.Write([]byte{col.R, col.G, col.B})\n\t\t}\n\t}\n\n\t_, err := Conn.WriteToUDP(buf.Bytes(), d.Addr)\n\treturn err\n}", "func (vl *ValueArray) String() string {\n\treturn fmt.Sprintf(\"%v\", vl.array)\n}", "func encode(buf *bytes.Buffer, v reflect.Value) error {\n\tswitch v.Kind() {\n\tcase reflect.Invalid: // ignore\n\n\tcase reflect.Float32, reflect.Float64:\n\t\tfmt.Fprintf(buf, \"%f\", v.Float())\n\n\tcase reflect.Complex128, reflect.Complex64:\n\t\tc := v.Complex()\n\t\tfmt.Fprintf(buf, \"#C(%f %f)\", real(c), imag(c))\n\n\tcase reflect.Bool:\n\t\tif v.Bool() {\n\t\t\tfmt.Fprintf(buf, \"t\")\n\t\t}\n\n\tcase reflect.Interface:\n\t\t// type output\n\t\tt := v.Elem().Type()\n\n\t\tleftBuffer := new(bytes.Buffer)\n\t\trightBuffer := new(bytes.Buffer)\n\n\t\tif t.Name() == \"\" { // 名前がつけられてないtypeはそのまま表示する\n\t\t\tfmt.Fprintf(leftBuffer, \"%q\", t)\n\t\t} else {\n\t\t\tfmt.Fprintf(leftBuffer, \"\\\"%s.%s\\\" \", t.PkgPath(), t.Name()) //一意ではないとはこういうことか?\n\t\t}\n\n\t\t// value output\n\t\tif err := encode(rightBuffer, v.Elem()); err != nil {\n\t\t\treturn err\n\t\t}\n\n\t\tif len(rightBuffer.Bytes()) != 0 {\n\t\t\tbuf.WriteByte('(')\n\t\t\tbuf.Write(leftBuffer.Bytes())\n\t\t\tbuf.WriteByte(' ')\n\t\t\tbuf.Write(rightBuffer.Bytes())\n\t\t\tbuf.WriteByte(')')\n\t\t}\n\n\tcase reflect.Int, reflect.Int8, reflect.Int16,\n\t\treflect.Int32, reflect.Int64:\n\t\tfmt.Fprintf(buf, \"%d\", v.Int())\n\n\tcase reflect.Uint, reflect.Uint8, reflect.Uint16,\n\t\treflect.Uint32, reflect.Uint64, reflect.Uintptr:\n\t\tfmt.Fprintf(buf, \"%d\", v.Uint())\n\n\tcase reflect.String:\n\t\tfmt.Fprintf(buf, \"%q\", v.String())\n\n\tcase reflect.Ptr:\n\t\treturn encode(buf, v.Elem())\n\n\tcase reflect.Array, reflect.Slice: // (value ...)\n\n\t\tcontent := new(bytes.Buffer)\n\n\t\tisFirst := true\n\n\t\tfor i := 0; i < v.Len(); i++ {\n\t\t\tif isFirst {\n\t\t\t\tisFirst = false\n\t\t\t\tcontent.WriteByte(' ')\n\t\t\t}\n\t\t\tif err := encode(content, v.Index(i)); err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\t\t}\n\n\t\tif len(content.Bytes()) != 0 {\n\t\t\tbuf.WriteByte('(')\n\t\t\tbuf.Write(content.Bytes())\n\t\t\tbuf.WriteByte(')')\n\t\t}\n\n\tcase reflect.Struct: // ((name value) ...)\n\n\t\tcontent := new(bytes.Buffer)\n\n\t\tisFirst := true\n\n\t\tfor i := 0; i < v.NumField(); i++ {\n\t\t\trightBuffer := new(bytes.Buffer)\n\t\t\tif err := encode(rightBuffer, v.Field(i)); err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\n\t\t\tif len(rightBuffer.Bytes()) != 0 {\n\t\t\t\tif isFirst {\n\t\t\t\t\tcontent.WriteByte(' ')\n\t\t\t\t\tisFirst = false\n\t\t\t\t}\n\t\t\t\tcontent.WriteByte('(')\n\t\t\t\tfmt.Fprintf(content, \"%s\", v.Type().Field(i).Name)\n\t\t\t\tcontent.WriteByte(' ')\n\t\t\t\tcontent.Write(rightBuffer.Bytes())\n\t\t\t\tcontent.WriteByte(')')\n\t\t\t}\n\t\t}\n\n\t\tif len(content.Bytes()) != 0 {\n\t\t\tbuf.WriteByte('(')\n\t\t\tbuf.Write(content.Bytes())\n\t\t\tbuf.WriteByte(')')\n\t\t}\n\n\tcase reflect.Map: // ((key value) ...)\n\t\tisFirst := true\n\t\tcontent := new(bytes.Buffer)\n\n\t\tfor _, key := range v.MapKeys() {\n\t\t\tif isFirst {\n\t\t\t\tcontent.WriteByte(' ')\n\t\t\t\tisFirst = false\n\t\t\t}\n\n\t\t\tleftBuffer := new(bytes.Buffer)\n\t\t\trightBuffer := new(bytes.Buffer)\n\n\t\t\tif err := encode(leftBuffer, key); err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\t\t\tif err := encode(rightBuffer, v.MapIndex(key)); err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\n\t\t\tif len(rightBuffer.Bytes()) != 0 {\n\t\t\t\tcontent.WriteByte('(')\n\t\t\t\tcontent.Write(leftBuffer.Bytes())\n\t\t\t\tcontent.WriteByte(' ')\n\t\t\t\tcontent.Write(rightBuffer.Bytes())\n\t\t\t\tcontent.WriteByte(')')\n\t\t\t}\n\t\t}\n\n\t\tif len(content.Bytes()) != 0 {\n\t\t\tbuf.WriteByte('(')\n\t\t\tbuf.Write(content.Bytes())\n\t\t\tbuf.WriteByte(')')\n\t\t}\n\n\tdefault: // float, complex, bool, chan, func, interface\n\t\treturn fmt.Errorf(\"unsupported type: %s\", v.Type())\n\t}\n\treturn nil\n}", "func (a *ArrayInt) String() string {\n\tx := a.a\n\tformattedInts := make([]string, len(x))\n\tfor i, v := range x {\n\t\tformattedInts[i] = strconv.Itoa(v)\n\t}\n\treturn strings.Join(formattedInts, \",\")\n}", "func (t *tag) render() string {\n tagType := t.GetType()\n tagFormat := tagsFormat[tagType]\n\n switch t.GetType() {\n case TYPE_OPEN:\n return fmt.Sprintf(tagFormat, t.GetName(), getAttrsToString(t))\n case TYPE_CLOSE:\n return fmt.Sprintf(tagFormat, t.GetName())\n case TYPE_OPEN_CLOSE:\n return fmt.Sprintf(tagFormat, t.GetName(), getAttrsToString(t), t.GetVal(), t.GetName())\n case TYPE_SELF_CLOSED_STRICT:\n if t.GetVal() != \"\" {\n t.SetAttr(\"value\", t.GetVal())\n }\n return fmt.Sprintf(tagFormat, t.GetName(), getAttrsToString(t))\n default:\n return t.GetName()\n }\n}", "func ex1() {\n\tx := [5]int{1, 2, 4, 8, 16}\n\tfor i, v := range x {\n\t\tfmt.Println(i, v)\n\t}\n\tfmt.Printf(\"%T\\n\", x)\n\n}", "func (self *Tween) GenerateData() []interface{}{\n\tarray00 := self.Object.Call(\"generateData\")\n\tlength00 := array00.Length()\n\tout00 := make([]interface{}, length00, length00)\n\tfor i00 := 0; i00 < length00; i00++ {\n\t\tout00[i00] = array00.Index(i00)\n\t}\n\treturn out00\n}", "func (h Hand) Render() string {\n\tbuffer := bytes.Buffer{}\n\tlast := len(h.Cards) - 1\n\tfor i, card := range h.Cards {\n\t\tbuffer.WriteString(card.Render())\n\t\tif i != last {\n\t\t\tbuffer.WriteString(\", \")\n\t\t}\n\t}\n\tbuffer.WriteString(fmt.Sprintf(\n\t\t\" (%s)\", scoresRenderer{h.Scores()}.Render(),\n\t))\n\treturn strings.Trim(buffer.String(), \" \")\n}", "func RenderList(w http.ResponseWriter, r *http.Request, l []Renderer) error {\n\tfor _, v := range l {\n\t\tif err := renderer(w, r, v); err != nil {\n\t\t\treturn err\n\t\t}\n\t}\n\tRespond(w, r, l)\n\treturn nil\n}", "func (me TStrokeDashArrayValueType) String() string { return xsdt.String(me).String() }", "func main() {\n\ts := []int{5, 3, 2, 6, 1, 6, 7, 10, 49, 100}\n\tfor i, v := range s {\n\t\tfmt.Println(i, v)\n\t}\n\tfmt.Printf(\"%T\\n\", s)\n}", "func (a *Array) Format() error {\n\t// todo\n\treturn nil\n}", "func (va ValueArray) String() string {\n\treturn fmt.Sprintf(\"%v\", []Value(va))\n}", "func (ctx *RecordContext) Render(v interface{}) error {\n\tctx.Renders = append(ctx.Renders, v)\n\treturn ctx.Context.Render(v)\n}", "func PrintDataSlice(data interface{}) {\n\td := reflect.ValueOf(data)\n\n\tfor i := 0; i < d.Len(); i++ {\n\t\tdataItem := d.Index(i)\n\t\ttypeOfT := dataItem.Type()\n\n\t\tfor j := 0; j < dataItem.NumField(); j++ {\n\t\t\tf := dataItem.Field(j)\n\t\t\tfmt.Printf(\"%s: %v\\n\", typeOfT.Field(j).Name, f.Interface())\n\t\t}\n\t\tfmt.Printf(\"\\n\")\n\t}\n}", "func (s *Slice) Format(f fmt.State, c rune) {\n\tswitch c {\n\tcase 'z': // Private format specifier, supports Entity.Signature\n\t\tfmt.Fprintf(f, \"[]%z\", s.ValueType)\n\tcase 'r': // Private format specifier, supports Type.Representation\n\t\tfmt.Fprintf(f, \"[]%r\", s.ValueType)\n\tdefault:\n\t\tif s.Alias != \"\" {\n\t\t\tfmt.Fprint(f, s.Alias)\n\t\t} else {\n\t\t\tfmt.Fprintf(f, \"[]%v\", s.ValueType)\n\t\t}\n\t}\n}", "func DrawElements(mode Enum, count int, ty Enum, offset int) {\n\tgl.DrawElements(uint32(mode), int32(count), uint32(ty), gl.PtrOffset(offset))\n}", "func (s Style) Render(raw string) string {\n\tt := NewAnstring(raw)\n\tfor i := len(s) - 1; i >= 0; i-- {\n\t\tt.meld(s[i])\n\t}\n\treturn string(t)\n}", "func (l *LogItem) Render(c int, showTime bool) []byte {\n\tbb := make([]byte, 0, 200)\n\tif showTime {\n\t\tt := l.Timestamp\n\t\tfor i := len(t); i < 30; i++ {\n\t\t\tt += \" \"\n\t\t}\n\t\tbb = append(bb, color.ANSIColorize(t, 106)...)\n\t\tbb = append(bb, ' ')\n\t}\n\n\tif l.Pod != \"\" {\n\t\tbb = append(bb, color.ANSIColorize(l.Pod, c)...)\n\t\tbb = append(bb, ':')\n\t}\n\tif !l.SingleContainer && l.Container != \"\" {\n\t\tbb = append(bb, color.ANSIColorize(l.Container, c)...)\n\t\tbb = append(bb, ' ')\n\t}\n\n\treturn append(bb, escPattern.ReplaceAll(l.Bytes, matcher)...)\n}", "func (isf intSliceFunctorImpl) String() string {\n\treturn fmt.Sprintf(\"%#v\", isf.ints)\n}", "func renderInteger(f float64) string {\n\tif f > math.Nextafter(float64(math.MaxInt64), 0) {\n\t\treturn fmt.Sprintf(\"%d\", int64(math.MaxInt64))\n\t}\n\tif f < math.Nextafter(float64(math.MinInt64), 0) {\n\t\treturn fmt.Sprintf(\"%d\", int64(math.MinInt64))\n\t}\n\treturn fmt.Sprintf(\"%d\", int64(f))\n}", "func (l *Label) data() []byte {\n Assert(nilLabel, l != nil)\n \n bytes, _ := util.Uint64ToBytes(l.value)\n refs, _ := util.Uint64ToBytes(l.refs)\n left, _ := util.Uint16ToBytes(l.l)\n right, _ := util.Uint16ToBytes(l.r)\n \n bytes = append(bytes, append(refs, append(left, append(right, l.h)...)...)...) // TODO ??\n return bytes\n \n}", "func (a PixelSubArray) Print() {\n\tfor y := len(a.bytes) - 1; y >= 0; y-- {\n\t\tfor x := 0; x < len(a.bytes[0]); x++ {\n\t\t\tfmt.Printf(\"%b%b%b%b%b%b%b%b\",\n\t\t\t\t(a.bytes[y][x])&1,\n\t\t\t\t(a.bytes[y][x]>>1)&1,\n\t\t\t\t(a.bytes[y][x]>>2)&1,\n\t\t\t\t(a.bytes[y][x]>>3)&1,\n\t\t\t\t(a.bytes[y][x]>>4)&1,\n\t\t\t\t(a.bytes[y][x]>>5)&1,\n\t\t\t\t(a.bytes[y][x]>>6)&1,\n\t\t\t\t(a.bytes[y][x]>>7)&1)\n\t\t}\n\n\t\tfmt.Printf(\"\\n\")\n\t}\n}", "func serialize(data interface{}) interface{} {\n\tvar buffer bytes.Buffer\n\tswitch reflect.TypeOf(data).Kind() {\n\tcase reflect.Slice:\n\t\ts := reflect.ValueOf(data)\n\t\tfor i := 0; i < s.Len(); i++ {\n\t\t\tserial := serialize(s.Index(i).Interface())\n\t\t\tif reflect.TypeOf(serial).Kind() == reflect.Float64 {\n\t\t\t\tserial = strconv.Itoa(int(serial.(float64)))\n\t\t\t}\n\t\t\tbuffer.WriteString(strconv.Itoa(i))\n\t\t\tbuffer.WriteString(serial.(string))\n\t\t}\n\t\treturn buffer.String()\n\tcase reflect.Map:\n\t\ts := reflect.ValueOf(data)\n\t\tkeys := s.MapKeys()\n\t\t//ksort\n\t\tvar sortedKeys []string\n\t\tfor _, key := range keys {\n\t\t\tsortedKeys = append(sortedKeys, key.Interface().(string))\n\t\t}\n\t\tsort.Strings(sortedKeys)\n\t\tfor _, key := range sortedKeys {\n\t\t\tserial := serialize(s.MapIndex(reflect.ValueOf(key)).Interface())\n\t\t\tif reflect.TypeOf(serial).Kind() == reflect.Float64 {\n\t\t\t\tserial = strconv.Itoa(int(serial.(float64)))\n\t\t\t}\n\t\t\tbuffer.WriteString(key)\n\t\t\tbuffer.WriteString(serial.(string))\n\t\t}\n\t\treturn buffer.String()\n\t}\n\n\treturn data\n}", "func (r renderer) Table(out *bytes.Buffer, header []byte, body []byte, columnData []int) {}", "func (self *Graphics) Data() interface{}{\n return self.Object.Get(\"data\")\n}", "func (level *Level) Render() string {\n\tresult := \"\"\n\n\tfor y := 0; y < level.size.Width; y++ {\n\t\tfor x := 0; x < level.size.Width; x++ {\n\t\t\tif level.snake.CheckHitbox(Position{x, y}) {\n\t\t\t\tresult += \"\\033[42m \\033[0m\"\n\t\t\t} else if level.apple.position.Equals(x, y) {\n\t\t\t\tresult += \"\\033[41m \\033[0m\"\n\t\t\t} else {\n\t\t\t\tresult += \"\\033[97m \\033[0m\"\n\t\t\t}\n\t\t}\n\n\t\tif y < level.size.Height-1 {\n\t\t\tresult += \"\\n\"\n\t\t}\n\t}\n\n\treturn result\n}", "func printTable(data []string, color bool) {\n\tvar listType string\n\n\ttable := tablewriter.NewWriter(os.Stdout)\n\n\tswitch color {\n\tcase true:\n\t\tlistType = \"White\"\n\tcase false:\n\t\tlistType = \"Black\"\n\t}\n\n\ttable.SetHeader([]string{\"#\", \"B/W\", \"CIDR\"})\n\n\tfor i, v := range data {\n\t\tl := make([]string, 0)\n\t\tl = append(l, strconv.Itoa(i+offset))\n\t\tl = append(l, listType)\n\t\tl = append(l, v)\n\t\ttable.Append(l)\n\t}\n\n\ttable.Render()\n}", "func Render(s api.Session, renderAs RenderName, value dgo.Value, out io.Writer) {\n\t// Convert value to rich data format without references\n\tdedupStream := func(value dgo.Value, consumer streamer.Consumer) {\n\t\topts := streamer.DefaultOptions()\n\t\topts.DedupLevel = streamer.NoDedup\n\t\tser := streamer.New(s.AliasMap(), opts)\n\t\tser.Stream(value, consumer)\n\t}\n\n\tswitch renderAs {\n\tcase JSON:\n\t\tif value.Equals(vf.Nil) {\n\t\t\tutil.WriteString(out, \"null\\n\")\n\t\t} else {\n\t\t\tdedupStream(value, streamer.JSON(out))\n\t\t\tutil.WriteByte(out, '\\n')\n\t\t}\n\n\tcase YAML:\n\t\tif value.Equals(vf.Nil) {\n\t\t\tutil.WriteString(out, \"\\n\")\n\t\t} else {\n\t\t\tdc := streamer.DataCollector()\n\t\t\tdedupStream(value, dc)\n\t\t\tbs, err := yaml.Marshal(dc.Value())\n\t\t\tif err != nil {\n\t\t\t\tpanic(err)\n\t\t\t}\n\t\t\tutil.WriteString(out, string(bs))\n\t\t}\n\tcase Binary:\n\t\tbi := vf.New(typ.Binary, value).(dgo.Binary)\n\t\t_, err := out.Write(bi.GoBytes())\n\t\tif err != nil {\n\t\t\tpanic(err)\n\t\t}\n\tcase Text:\n\t\tutil.Fprintln(out, value)\n\tdefault:\n\t\tpanic(fmt.Errorf(`unknown rendering '%s'`, renderAs))\n\t}\n}", "func (s *Ipset) Render(rType RenderType) string {\n\tvar result string\n\n\tswitch rType {\n\tcase RenderFlush:\n\t\tif len(s.Sets) == 0 {\n\t\t\treturn \"flush\\n\"\n\t\t}\n\tcase RenderDestroy:\n\t\tif len(s.Sets) == 0 {\n\t\t\treturn \"destroy\\n\"\n\t\t}\n\n\t// RenderSwap will fail when Sets < 2,\n\t// it's a duty of a caller to ensure\n\t// correctness.\n\tcase RenderSwap:\n\t\treturn fmt.Sprintf(\"swap %s %s\\n\", s.Sets[0].Name, s.Sets[1].Name)\n\n\t// RenderRename will fail when Sets < 2,\n\t// it's a duty of a caller to ensure\n\t// correctness.\n\tcase RenderRename:\n\t\treturn fmt.Sprintf(\"rename %s %s\\n\", s.Sets[0].Name, s.Sets[1].Name)\n\t}\n\n\tfor _, set := range s.Sets {\n\t\tresult += set.Render(rType)\n\t}\n\n\treturn result\n}", "func (b *Board) Render() {\n\tfmt.Println() // to breathe\n\tfmt.Println(\" | a | b | c | d | e | f | g | h |\")\n\tfmt.Println(\" - +-----+-----+-----+-----+-----+-----+-----+-----+\")\n\n\tfor i := 0; i < 8; i++ {\n\t\tfmt.Printf(\" %d |\", i)\n\t\tfor j := 0; j < 8; j++ {\n\t\t\tcell := b[i][j]\n\t\t\tfmt.Printf(\" %s |\", cell)\n\t\t}\n\t\tfmt.Println()\n\t}\n\n\tfmt.Println(\" - +-----+-----+-----+-----+-----+-----+-----+-----+\")\n\tfmt.Println() // breathe again\n}", "func (ctx *APIContext) Render(status int, title string, obj interface{}) {\n\tctx.JSON(status, map[string]interface{}{\n\t\t\"message\": title,\n\t\t\"status\": status,\n\t\t\"resource\": obj,\n\t})\n}", "func (val *uint16ArrayValue) String() string {\n\tvar buffer strings.Builder\n\tfor _, v := range *val {\n\t\tif buffer.Len() != 0 {\n\t\t\tbuffer.WriteString(\", \")\n\t\t}\n\t\tfmt.Fprintf(&buffer, \"%v\", v)\n\t}\n\treturn buffer.String()\n}", "func WriteASCII(w io.Writer, t []Triangle) error {\n\tvar err error\n\n\tprintf := func(format string, a ...interface{}) {\n\t\tif err != nil {\n\t\t\treturn\n\t\t}\n\t\t_, err = fmt.Fprintf(w, format, a...)\n\t}\n\tprintf(\"solid object\\n\")\n\tfor _, tt := range t {\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tprintf(\"facet normal %f %f %f\\n\", tt.N[0], tt.N[1], tt.N[2])\n\t\tprintf(\" outer loop\\n\")\n\t\tfor _, v := range tt.V {\n\t\t\tprintf(\" vertex %f %f %f\\n\", v[0], v[1], v[2])\n\t\t}\n\t\tprintf(\" endloop\\n\")\n\t\tprintf(\"endfacet\\n\")\n\t}\n\tprintf(\"endsolid object\\n\")\n\treturn nil\n}", "func (gl *WebGL) DrawElements(mode GLEnum, count int, valueType GLEnum, offset int) {\n\tgl.context.Call(\"drawElements\", mode, count, valueType, offset)\n}", "func Render(typ Type, input any, urlPrefix string, metas map[string]string) []byte {\n\tvar rawBytes []byte\n\tswitch v := input.(type) {\n\tcase []byte:\n\t\trawBytes = v\n\tcase string:\n\t\trawBytes = []byte(v)\n\tdefault:\n\t\tpanic(fmt.Sprintf(\"unrecognized input content type: %T\", input))\n\t}\n\n\turlPrefix = strings.TrimRight(strings.ReplaceAll(urlPrefix, \" \", \"%20\"), \"/\")\n\tvar rawHTML []byte\n\tswitch typ {\n\tcase TypeMarkdown:\n\t\trawHTML = RawMarkdown(rawBytes, urlPrefix)\n\tcase TypeOrgMode:\n\t\trawHTML = RawOrgMode(rawBytes, urlPrefix)\n\tdefault:\n\t\treturn rawBytes // Do nothing if syntax type is not recognized\n\t}\n\n\trawHTML = postProcessHTML(rawHTML, urlPrefix, metas)\n\treturn SanitizeBytes(rawHTML)\n}", "func WriteArray(lst []interface{}, buf *goetty.ByteBuf) {\r\n\tbuf.WriteByte('*')\r\n\tif len(lst) == 0 {\r\n\t\tbuf.Write(NullArray)\r\n\t\tbuf.Write(Delims)\r\n\t} else {\r\n\t\tbuf.Write(goetty.StringToSlice(strconv.Itoa(len(lst))))\r\n\t\tbuf.Write(Delims)\r\n\r\n\t\tfor i := 0; i < len(lst); i++ {\r\n\t\t\tswitch v := lst[i].(type) {\r\n\t\t\tcase []interface{}:\r\n\t\t\t\tWriteArray(v, buf)\r\n\t\t\tcase [][]byte:\r\n\t\t\t\tWriteSliceArray(v, buf)\r\n\t\t\tcase []byte:\r\n\t\t\t\tWriteBulk(v, buf)\r\n\t\t\tcase nil:\r\n\t\t\t\tWriteBulk(nil, buf)\r\n\t\t\tcase int64:\r\n\t\t\t\tWriteInteger(v, buf)\r\n\t\t\tcase string:\r\n\t\t\t\tWriteStatus(goetty.StringToSlice(v), buf)\r\n\t\t\tcase error:\r\n\t\t\t\tWriteError(goetty.StringToSlice(v.Error()), buf)\r\n\t\t\tdefault:\r\n\t\t\t\tpanic(fmt.Sprintf(\"invalid array type %T %v\", lst[i], v))\r\n\t\t\t}\r\n\t\t}\r\n\t}\r\n}", "func (d *Data) Render() error {\n\n\tvar err error\n\n\t// Read the CA certificate:\n\tif err = d.caCert(); err != nil {\n\t\treturn err\n\t}\n\n\t// Forge the Zookeeper URL:\n\td.forgeZookeeperURL()\n\n\t// REX-Ray configuration snippet:\n\td.rexraySnippet()\n\n\t// Role-based parsing:\n\tt := template.New(\"udata\")\n\n\tswitch d.Role {\n\tcase \"master\":\n\t\tt, err = t.Parse(templMaster)\n\tcase \"node\":\n\t\tt, err = t.Parse(templNode)\n\tcase \"edge\":\n\t\tt, err = t.Parse(templEdge)\n\t}\n\n\tif err != nil {\n\t\tlog.WithField(\"cmd\", \"udata\").Error(err)\n\t\treturn err\n\t}\n\n\t// Apply parsed template to data object:\n\tif d.GzipUdata {\n\t\tlog.WithFields(log.Fields{\"cmd\": \"udata\", \"id\": d.Role + \"-\" + d.HostID}).\n\t\t\tInfo(\"- Rendering gzipped cloud-config template\")\n\t\tw := gzip.NewWriter(os.Stdout)\n\t\tdefer w.Close()\n\t\tif err = t.Execute(w, d); err != nil {\n\t\t\tlog.WithField(\"cmd\", \"udata\").Error(err)\n\t\t\treturn err\n\t\t}\n\t} else {\n\t\tlog.WithField(\"cmd\", \"udata\").Info(\"- Rendering plain text cloud-config template\")\n\t\tif err = t.Execute(os.Stdout, d); err != nil {\n\t\t\tlog.WithField(\"cmd\", \"udata\").Error(err)\n\t\t\treturn err\n\t\t}\n\t}\n\n\t// Return on success:\n\treturn nil\n}", "func (p *Pprint) pprint(data interface{}) {\n\t// temp := reflect.TypeOf(data).Kind()\n\t// p.test[\"array\"] = reflect.Map\n\t// fmt.Println(p.test)\n\t// if reflect.Array == temp {\n\t// \tfmt.Println(\"scussu\")\n\t// }\n\t// p.test[temp.String()] = 0\n\tp.Typemode = reflect.TypeOf(data).Kind()\n\tif p.Typemode == reflect.Map {\n\t\tp.PrintMaps(data)\n\t} else if p.Typemode == reflect.Slice {\n\t\tp.PrintArrays(data)\n\t} else if p.Typemode == reflect.Array {\n\t\tp.PrintArrays(data)\n\t} else {\n\t\tfmt.Println(data)\n\t}\n}", "func Render(files [][]byte, maxIt uint, debug bool) (\n\t[]byte, error,\n) {\n\tinfl, debugParse, err := parseFiles(files)\n\tif err != nil {\n\t\tif debug {\n\t\t\twriteDebug(\"parsing\", debugParse)\n\t\t}\n\t\treturn []byte{}, err\n\t}\n\tres, debugRender, err := renderTmpl(infl, maxIt)\n\tif err != nil {\n\t\tif debug {\n\t\t\twriteDebug(\"render\", debugRender)\n\t\t}\n\t\treturn []byte{}, err\n\t}\n\treturn res, nil\n}", "func (Empty) Render(width, height int) *term.Buffer {\n\treturn term.NewBufferBuilder(width).Buffer()\n}", "func DrawElements(mode uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n\tsyscall.Syscall6(gpDrawElements, 4, uintptr(mode), uintptr(count), uintptr(xtype), uintptr(indices), 0, 0)\n}", "func GenerateShapes() {\r\n\t// Square\r\n\tShapes[0].vertices = []gl.GLfloat{-1, -1, 1, -1, -1, 1, 1, 1}\r\n\tShapes[0].elements = []gl.GLushort{0, 1, 2, 2, 3, 1}\r\n\r\n\t// ___|\r\n\tShapes[1].vertices = []gl.GLfloat{-2, 0, -2, -1, 2, -1, 2, 0, 2, 1, 1, 1, 1, 0}\r\n\tShapes[1].elements = []gl.GLushort{0, 1, 2, 2, 3, 0, 3, 4, 5, 5, 6, 3}\r\n\r\n\t// _|_\r\n\tShapes[2].vertices = []gl.GLfloat{-1.5, 0, -0.5, 0, -0.5, 1, 0.5, 1, 0.5, 0, 1.5, 0, 1.5, -1, -1.5, -1}\r\n\tShapes[2].elements = []gl.GLushort{1, 2, 3, 3, 4, 1, 0, 7, 6, 6, 0, 5}\r\n\r\n\t// Snake\r\n\tShapes[3].vertices = []gl.GLfloat{-1.5, -1, -1.5, 0, -0.5, 0, -0.5, 1, 1.5, 1, 1.5, 0, 0.5, 0, 0.5, -1}\r\n\tShapes[3].elements = []gl.GLushort{0, 1, 6, 6, 7, 0, 2, 3, 4, 4, 5, 2}\r\n\r\n\t// Now fill out the rest automatically.\r\n\t// FIXME why doesn't using _, shape in this loop work ?\r\n\tfor i := range Shapes {\r\n\t\tShapes[i].vao = gl.GenVertexArray()\r\n\t\tShapes[i].vao.Bind()\r\n\t\tShapes[i].vbo = gl.GenBuffer()\r\n\t\tShapes[i].vbo.Bind(gl.ARRAY_BUFFER)\r\n\t\tgl.BufferData(gl.ARRAY_BUFFER, len(Shapes[i].vertices)*4, Shapes[i].vertices, gl.STATIC_DRAW)\r\n\t\tShapes[i].elementBuffer = gl.GenBuffer()\r\n\t\tShapes[i].elementBuffer.Bind(gl.ELEMENT_ARRAY_BUFFER)\r\n\t\tgl.BufferData(gl.ELEMENT_ARRAY_BUFFER, len(Shapes[i].elements)*2, Shapes[i].elements, gl.STATIC_DRAW)\r\n\t\tShapes[i].numElements = len(Shapes[i].elements)\r\n\r\n\t\tvertexAttribArray := shaderProgram.GetAttribLocation(\"position\")\r\n\t\tvertexAttribArray.AttribPointer(2, gl.FLOAT, false, 0, uintptr(0))\r\n\t\tvertexAttribArray.EnableArray()\r\n\t}\r\n}", "func Interpret(data []byte, offset int) []byte {\n\tb:=make([]byte, len(data) * 2)\n\n\tfor i:=0; i<len(data); i++ {\n\t\tb[offset + i * 2] = hex_ascii[ (data[i] & 0XF0) >> 4]\n\t\tb[offset + i * 2 + 1] = hex_ascii[data[i] & 0x0F]\n\t}\n\treturn b\n}", "func DrawElements(mode uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n C.glowDrawElements(gpDrawElements, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices)\n}", "func (tpl *Template) RenderBytes(ctx ...interface{}) ([]byte, error) {\n\tvar buf bytes.Buffer\n\terr := tpl.Run(&buf, ctx...)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\treturn buf.Bytes(), nil\n}", "func TestRender(t *testing.T) {\n\ttestCases := []struct {\n\t\tname string\n\t\tp P\n\t\twantList []string\n\t\twantCode int\n\t}{\n\t\t{\n\t\t\t\"server error\",\n\t\t\tServerError,\n\t\t\t[]string{\"500\"},\n\t\t\t500,\n\t\t}, {\n\t\t\t\"renders the type correctly\",\n\t\t\tP{Type: \"foo\", Status: 500},\n\t\t\t[]string{\"foo\"},\n\t\t\t500,\n\t\t}, {\n\t\t\t\"renders the status correctly\",\n\t\t\tP{Status: 201},\n\t\t\t[]string{\"201\"},\n\t\t\t201,\n\t\t}, {\n\t\t\t\"renders the extras correctly\",\n\t\t\tP{Extras: map[string]interface{}{\"hello\": \"stellar\"}, Status: 500},\n\t\t\t[]string{\"hello\", \"stellar\"},\n\t\t\t500,\n\t\t},\n\t}\n\n\tfor _, kase := range testCases {\n\t\tt.Run(kase.name, func(t *testing.T) {\n\t\t\tw := testRender(context.Background(), kase.p)\n\t\t\tfor _, wantItem := range kase.wantList {\n\t\t\t\tassert.True(t, strings.Contains(w.Body.String(), wantItem), w.Body.String())\n\t\t\t\tassert.Equal(t, kase.wantCode, w.Code)\n\t\t\t}\n\t\t})\n\t}\n}", "func encodeUxArray(obj *UxArray) ([]byte, error) {\n\tn := encodeSizeUxArray(obj)\n\tbuf := make([]byte, n)\n\n\tif err := encodeUxArrayToBuffer(buf, obj); err != nil {\n\t\treturn nil, err\n\t}\n\n\treturn buf, nil\n}", "func (obj *Device) DrawIndexedPrimitiveUP(\n\ttyp PRIMITIVETYPE,\n\tminVertexIndex uint,\n\tnumVertices uint,\n\tprimitiveCount uint,\n\tindexData uintptr,\n\tindexDataFormat FORMAT,\n\tvertexStreamZeroData uintptr,\n\tvertexStreamZeroStride uint,\n) Error {\n\tret, _, _ := syscall.Syscall9(\n\t\tobj.vtbl.DrawIndexedPrimitiveUP,\n\t\t9,\n\t\tuintptr(unsafe.Pointer(obj)),\n\t\tuintptr(typ),\n\t\tuintptr(minVertexIndex),\n\t\tuintptr(numVertices),\n\t\tuintptr(primitiveCount),\n\t\tindexData,\n\t\tuintptr(indexDataFormat),\n\t\tvertexStreamZeroData,\n\t\tuintptr(vertexStreamZeroStride),\n\t)\n\treturn toErr(ret)\n}", "func (c *Plain) RenderIndexContent(content interface{}) (string, error) {\n\treturn content.(string), nil\n}", "func (r *ExcelReport) Render(ctx map[string]interface{}) {\n\tmergedCells, _ := r.f.GetMergeCells(r.sheetName)\n\n\tr.renderSingleAttribute(ctx)\n\n\t// Set nilai pada cell yang digabungkan (merge cell)\n\tfor _, mergedCell := range mergedCells {\n\t\taxis := strings.Split(mergedCell[0], \":\")[0]\n\t\tformula, _ := r.f.GetCellFormula(r.sheetName, axis)\n\t\tif formula != \"\" {\n\t\t\tr.f.SetCellFormula(r.sheetName, axis, formula)\n\t\t\tcontinue\n\t\t}\n\t\tcellValue := mergedCell[1]\n\n\t\tprop := getProp(cellValue)\n\t\tif prop != \"\" {\n\t\t\tif !isArray(ctx, prop) {\n\t\t\t\tcellValue, _ = renderContext(cellValue, ctx)\n\t\t\t}\n\t\t}\n\n\t\tsetCellValue(r.sheetName, axis, r.f, cellValue)\n\t}\n\n\tr.renderArrayAttribute(ctx)\n}", "func (t *Table) Render() string {\n\tfmt.Fprintln(t.w, \"-\")\n\tt.w.Flush()\n\n\treturn t.buf.String()\n}", "func Render(r *sdl.Renderer, w *World) {\n\twidth := float64(r.GetViewport().W)\n\theight := float64(r.GetViewport().H)\n\n\trenderedVertices := [][2]int{}\n\n\tfor _, obj := range w.Objects {\n\t\tfor _, vertex := range obj.Geometry.Vertices {\n\t\t\trenderCoordinates := AsRelativeToSystem(w.ActiveCamera.ObjSys, ToSystem(obj.ObjSys, vertex.Pos))\n\n\t\t\tZ := Clamp(renderCoordinates.Z, 0.0001, math.NaN())\n\t\t\tratio := w.ActiveCamera.FocalLength / math.Abs(Z)\n\t\t\trenderX := ratio * renderCoordinates.X\n\t\t\trenderY := ratio * renderCoordinates.Y\n\n\t\t\tnormX, normY := NormalizeScreen(\n\t\t\t\twidth,\n\t\t\t\theight,\n\t\t\t\trenderX,\n\t\t\t\trenderY,\n\t\t\t)\n\n\t\t\trasterX := int(math.Floor(normX*width) + width/2)\n\t\t\trasterY := int(math.Floor(normY*height) + height/2)\n\n\t\t\trenderedVertices = append(renderedVertices, [2]int{rasterX, rasterY})\n\n\t\t\tDrawCircle(r, rasterX, rasterY, 5)\n\t\t}\n\t\tfor _, edge := range obj.Geometry.Edges {\n\t\t\tif len(renderedVertices) > edge.From && len(renderedVertices) > edge.To {\n\t\t\t\tr.DrawLine(\n\t\t\t\t\tint32(renderedVertices[edge.From][0]),\n\t\t\t\t\tint32(renderedVertices[edge.From][1]),\n\t\t\t\t\tint32(renderedVertices[edge.To][0]),\n\t\t\t\t\tint32(renderedVertices[edge.To][1]),\n\t\t\t\t)\n\t\t\t}\n\t\t}\n\t}\n\n\tr.Present()\n}", "func (obj *Device) DrawPrimitive(\n\ttyp PRIMITIVETYPE,\n\tstartVertex uint,\n\tprimitiveCount uint,\n) Error {\n\tret, _, _ := syscall.Syscall6(\n\t\tobj.vtbl.DrawPrimitive,\n\t\t4,\n\t\tuintptr(unsafe.Pointer(obj)),\n\t\tuintptr(typ),\n\t\tuintptr(startVertex),\n\t\tuintptr(primitiveCount),\n\t\t0,\n\t\t0,\n\t)\n\treturn toErr(ret)\n}", "func renderTemplateBytes(name string, data interface{}) ([]byte, error) {\n\tvar buf bytes.Buffer\n\tif err := Tmpl.Render(&buf, name, data); err != nil {\n\t\treturn nil, err\n\t}\n\treturn buf.Bytes(), nil\n}", "func renderTemplateBytes(name string, data interface{}) ([]byte, error) {\n\tvar buf bytes.Buffer\n\tif err := Tmpl.Render(&buf, name, data); err != nil {\n\t\treturn nil, err\n\t}\n\treturn buf.Bytes(), nil\n}" ]
[ "0.56787425", "0.54101527", "0.5399384", "0.519561", "0.5053621", "0.5053621", "0.4920417", "0.48898092", "0.48869783", "0.4874677", "0.48738092", "0.4813202", "0.47689718", "0.47537965", "0.4749709", "0.47490627", "0.47416687", "0.47410572", "0.47369975", "0.4730121", "0.47264576", "0.47100666", "0.46990198", "0.46961746", "0.4696105", "0.46880925", "0.46767005", "0.46732444", "0.4672384", "0.46716732", "0.46579018", "0.46450433", "0.46363953", "0.46341535", "0.46307516", "0.46253136", "0.461411", "0.4614061", "0.4613324", "0.4578849", "0.45645848", "0.4560169", "0.45589033", "0.45529243", "0.45445886", "0.45256785", "0.45206797", "0.45191577", "0.45175895", "0.45136765", "0.45120773", "0.4511845", "0.45095196", "0.45020393", "0.44944736", "0.44915026", "0.44862324", "0.44781968", "0.44772694", "0.447416", "0.44738328", "0.44709054", "0.44687584", "0.44684634", "0.44682878", "0.4457824", "0.44531804", "0.44512594", "0.44473648", "0.4444646", "0.4436516", "0.4431991", "0.44247144", "0.44142383", "0.44101962", "0.440982", "0.44053942", "0.4403469", "0.43999562", "0.4399935", "0.43975523", "0.43952927", "0.4387458", "0.43738773", "0.4370974", "0.43695098", "0.43662947", "0.4362171", "0.43616948", "0.43552798", "0.43544373", "0.43510047", "0.43474784", "0.4340883", "0.43406615", "0.4336113", "0.43319076", "0.43293712", "0.43150315", "0.43130335", "0.43130335" ]
0.0
-1
render primitives from array data with a perelement offset
func DrawElementsBaseVertex(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, basevertex int32) { C.glowDrawElementsBaseVertex(gpDrawElementsBaseVertex, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLint)(basevertex)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func (native *OpenGL) DrawElementsOffset(mode uint32, count int32, elementType uint32, offset int) {\n\tgl.DrawElements(mode, count, elementType, gl.PtrOffset(offset))\n}", "func Interpret(data []byte, offset int) []byte {\n\tb:=make([]byte, len(data) * 2)\n\n\tfor i:=0; i<len(data); i++ {\n\t\tb[offset + i * 2] = hex_ascii[ (data[i] & 0XF0) >> 4]\n\t\tb[offset + i * 2 + 1] = hex_ascii[data[i] & 0x0F]\n\t}\n\treturn b\n}", "func (v Binary) Render(i, width int, baseStyle lipgloss.Style) string {\n\tw := dataWidth(width)\n\t_, err := v.Seek(int64(i*w), io.SeekStart)\n\tif err != nil {\n\t\treturn baseStyle.Blink(true).Render(err.Error())\n\t}\n\tif len(v.b) != w {\n\t\tv.b = make([]byte, w)\n\t}\n\tn, err := v.Read(v.b)\n\tif err != nil && !errors.Is(err, io.EOF) {\n\t\treturn baseStyle.Blink(true).Render(err.Error())\n\t}\n\ts := fmt.Sprintf(\"% X%s \", v.b[0:n], strings.Repeat(\" \", w-n))\n\tvar x strings.Builder\n\tfor i := 0; i < n; i++ {\n\t\tif unicode.IsPrint(rune(v.b[i])) {\n\t\t\tx.WriteRune(rune(v.b[i]))\n\t\t} else {\n\t\t\tx.WriteRune('.')\n\t\t}\n\t}\n\treturn baseStyle.Render(s + x.String())\n}", "func (obj *Device) DrawIndexedPrimitiveUP(\n\ttyp PRIMITIVETYPE,\n\tminVertexIndex uint,\n\tnumVertices uint,\n\tprimitiveCount uint,\n\tindexData uintptr,\n\tindexDataFormat FORMAT,\n\tvertexStreamZeroData uintptr,\n\tvertexStreamZeroStride uint,\n) Error {\n\tret, _, _ := syscall.Syscall9(\n\t\tobj.vtbl.DrawIndexedPrimitiveUP,\n\t\t9,\n\t\tuintptr(unsafe.Pointer(obj)),\n\t\tuintptr(typ),\n\t\tuintptr(minVertexIndex),\n\t\tuintptr(numVertices),\n\t\tuintptr(primitiveCount),\n\t\tindexData,\n\t\tuintptr(indexDataFormat),\n\t\tvertexStreamZeroData,\n\t\tuintptr(vertexStreamZeroStride),\n\t)\n\treturn toErr(ret)\n}", "func DrawRangeElements(mode uint32, start uint32, end uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n\tsyscall.Syscall6(gpDrawRangeElements, 6, uintptr(mode), uintptr(start), uintptr(end), uintptr(count), uintptr(xtype), uintptr(indices))\n}", "func DrawElements(mode uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n\tsyscall.Syscall6(gpDrawElements, 4, uintptr(mode), uintptr(count), uintptr(xtype), uintptr(indices), 0, 0)\n}", "func DrawRangeElements(mode uint32, start uint32, end uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n C.glowDrawRangeElements(gpDrawRangeElements, (C.GLenum)(mode), (C.GLuint)(start), (C.GLuint)(end), (C.GLsizei)(count), (C.GLenum)(xtype), indices)\n}", "func (obj *Device) DrawIndexedPrimitive(\n\ttyp PRIMITIVETYPE,\n\tbaseVertexIndex int,\n\tminIndex uint,\n\tnumVertices uint,\n\tstartIndex uint,\n\tprimitiveCount uint,\n) Error {\n\tret, _, _ := syscall.Syscall9(\n\t\tobj.vtbl.DrawIndexedPrimitive,\n\t\t7,\n\t\tuintptr(unsafe.Pointer(obj)),\n\t\tuintptr(typ),\n\t\tuintptr(baseVertexIndex),\n\t\tuintptr(minIndex),\n\t\tuintptr(numVertices),\n\t\tuintptr(startIndex),\n\t\tuintptr(primitiveCount),\n\t\t0,\n\t\t0,\n\t)\n\treturn toErr(ret)\n}", "func (native *OpenGL) DrawElements(mode uint32, count int32, elementType uint32, indices uintptr) {\n\tgl.DrawElements(mode, count, elementType, unsafe.Pointer(indices)) // nolint: govet,gas\n}", "func (a PixelSubArray) Print() {\n\tfor y := len(a.bytes) - 1; y >= 0; y-- {\n\t\tfor x := 0; x < len(a.bytes[0]); x++ {\n\t\t\tfmt.Printf(\"%b%b%b%b%b%b%b%b\",\n\t\t\t\t(a.bytes[y][x])&1,\n\t\t\t\t(a.bytes[y][x]>>1)&1,\n\t\t\t\t(a.bytes[y][x]>>2)&1,\n\t\t\t\t(a.bytes[y][x]>>3)&1,\n\t\t\t\t(a.bytes[y][x]>>4)&1,\n\t\t\t\t(a.bytes[y][x]>>5)&1,\n\t\t\t\t(a.bytes[y][x]>>6)&1,\n\t\t\t\t(a.bytes[y][x]>>7)&1)\n\t\t}\n\n\t\tfmt.Printf(\"\\n\")\n\t}\n}", "func DrawElements(mode uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n C.glowDrawElements(gpDrawElements, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices)\n}", "func (e *expression) printArray() string {\n\ta := \"\"\n\n\tfor i := 0; i < len(e.lenArray); i++ {\n\t\tvArray := string('i' + i)\n\t\ta += fmt.Sprintf(\"[%s]\", vArray)\n\t}\n\treturn a\n}", "func PrintDataSlice(data interface{}) {\n\td := reflect.ValueOf(data)\n\n\tfor i := 0; i < d.Len(); i++ {\n\t\tdataItem := d.Index(i)\n\t\ttypeOfT := dataItem.Type()\n\n\t\tfor j := 0; j < dataItem.NumField(); j++ {\n\t\t\tf := dataItem.Field(j)\n\t\t\tfmt.Printf(\"%s: %v\\n\", typeOfT.Field(j).Name, f.Interface())\n\t\t}\n\t\tfmt.Printf(\"\\n\")\n\t}\n}", "func (self *Tween) GenerateData() []interface{}{\n\tarray00 := self.Object.Call(\"generateData\")\n\tlength00 := array00.Length()\n\tout00 := make([]interface{}, length00, length00)\n\tfor i00 := 0; i00 < length00; i00++ {\n\t\tout00[i00] = array00.Index(i00)\n\t}\n\treturn out00\n}", "func ArrayElement(i int32) {\n C.glowArrayElement(gpArrayElement, (C.GLint)(i))\n}", "func DrawElements(mode Enum, count int, ty Enum, offset int) {\n\tgl.DrawElements(uint32(mode), int32(count), uint32(ty), gl.PtrOffset(offset))\n}", "func render(fset *token.FileSet, x interface{}) string {\n\tvar buf bytes.Buffer\n\tif err := printer.Fprint(&buf, fset, x); err != nil {\n\t\tpanic(err)\n\t}\n\treturn buf.String()\n}", "func render(fset *token.FileSet, x interface{}) string {\n\tvar buf bytes.Buffer\n\tif err := printer.Fprint(&buf, fset, x); err != nil {\n\t\tpanic(err)\n\t}\n\treturn buf.String()\n}", "func (r *Renderer) Render() {\n\tsx, sz, sy := r.c.Bounds()\n\tsxf := float64(sx - 1)\n\tsyf := float64(sy - 1)\n\tszf := float64(sz - 1)\n\tfor z := 0; z < sz; z++ {\n\t\tfor y := 0; y < sy; y++ {\n\t\t\tfor x := 0; x < sx; x++ {\n\t\t\t\tvar lr, lg, lb, _ uint32\n\t\t\t\tn := uint32(0)\n\t\t\t\tfor _, o := range r.objects {\n\t\t\t\t\tr, g, b, _ := o.At(float64(x)/sxf, float64(y)/syf, float64(z)/szf).RGBA()\n\t\t\t\t\tlr += r >> 8\n\t\t\t\t\tlg += g >> 8\n\t\t\t\t\tlb += b >> 8\n\t\t\t\t\tn++\n\t\t\t\t}\n\t\t\t\tr.c.Set(x, y, z, color.RGBA{uint8(lr/n), uint8(lg/n), uint8(lb/n), 255})\n\t\t\t}\n\t\t}\n\t}\n\tr.c.Render()\n}", "func main() {\n\t//composite literal - create different values of a type\n\t// x := type{values}\n\t//group together values OF THE SAME TYPE\n\tx := []int{4, 5, 7, 8, 42}\n\n\tfmt.Println(x)\n\tfmt.Println(x[0]) //query by index position\n\tfmt.Println(x[1])\n\tfmt.Println(x[2])\n\tfmt.Println(x[3])\n\tfmt.Println(x[4])\n\tfmt.Println(cap(x))\n\n\t//for index and value in the range of x print\n\tfor i, v := range x {\n\t\tfmt.Println(i, v)\n\t}\n}", "func (e *rawData) Render(w io.Writer) (int, error) { return w.Write([]byte(e.content)) }", "func DrawOrder(value int) *SimpleElement { return newSEInt(\"drawOrder\", value) }", "func renderResults(vals []interface{}) Data {\n\tvar nilcount int\n\tvar obj interface{}\n\tfor _, val := range vals {\n\t\tswitch val.(type) {\n\t\tcase image.Image, Data:\n\t\t\tobj = val\n\t\tcase nil:\n\t\t\tnilcount++\n\t\t}\n\t}\n\tif obj != nil && nilcount == len(vals)-1 {\n\t\tswitch val := obj.(type) {\n\t\tcase image.Image:\n\t\t\tdata, err := image0(val)\n\t\t\tif err == nil {\n\t\t\t\treturn data\n\t\t\t}\n\t\tcase Data:\n\t\t\treturn val\n\t\t}\n\t}\n\tif nilcount == len(vals) {\n\t\t// if all values are nil, return empty Data\n\t\treturn Data{}\n\t}\n\treturn MakeData(\"text/plain\", fmt.Sprint(vals...))\n}", "func (f genHelperDecoder) DecReadArrayElem() { f.d.arrayElem() }", "func plotdata(deck *generate.Deck, left, right, top, bottom float64, x []float64, y []float64, size float64, color string) {\n\tif len(x) != len(y) {\n\t\treturn\n\t}\n\tminx, maxx := extrema(x)\n\tminy, maxy := extrema(y)\n\n\tix := left\n\tiy := bottom\n\tfor i := 0; i < len(x); i++ {\n\t\txp := vmap(x[i], minx, maxx, left, right)\n\t\typ := vmap(y[i], miny, maxy, bottom, top)\n\t\tdeck.Circle(xp, yp, size, color)\n\t\tdeck.Line(ix, iy, xp, yp, 0.2, color)\n\t\tix = xp\n\t\tiy = yp\n\t}\n}", "func (l *Label) data() []byte {\n Assert(nilLabel, l != nil)\n \n bytes, _ := util.Uint64ToBytes(l.value)\n refs, _ := util.Uint64ToBytes(l.refs)\n left, _ := util.Uint16ToBytes(l.l)\n right, _ := util.Uint16ToBytes(l.r)\n \n bytes = append(bytes, append(refs, append(left, append(right, l.h)...)...)...) // TODO ??\n return bytes\n \n}", "func (sr scoresRenderer) Render() string {\n\tbuffer := bytes.Buffer{}\n\tlast := len(sr.scores) - 1\n\tfor i, score := range sr.scores {\n\t\tbuffer.WriteString(fmt.Sprintf(\"%d\", score))\n\t\tif i != last {\n\t\t\tbuffer.WriteString(\" / \")\n\t\t}\n\t}\n\treturn buffer.String()\n}", "func DrawElementsIndirect(mode uint32, xtype uint32, indirect unsafe.Pointer) {\n\tsyscall.Syscall(gpDrawElementsIndirect, 3, uintptr(mode), uintptr(xtype), uintptr(indirect))\n}", "func (debugging *debuggingOpenGL) DrawElements(mode uint32, count int32, elementType uint32, indices uintptr) {\n\tdebugging.recordEntry(\"DrawElements\", mode, count, elementType, indices)\n\tdebugging.gl.DrawElements(mode, count, elementType, indices)\n\tdebugging.recordExit(\"DrawElements\")\n}", "func ArrayElement(i int32) {\n\tC.glowArrayElement(gpArrayElement, (C.GLint)(i))\n}", "func ArrayElement(i int32) {\n\tsyscall.Syscall(gpArrayElement, 1, uintptr(i), 0, 0)\n}", "func DrawRangeElementsBaseVertex(mode uint32, start uint32, end uint32, count int32, xtype uint32, indices unsafe.Pointer, basevertex int32) {\n\tsyscall.Syscall9(gpDrawRangeElementsBaseVertex, 7, uintptr(mode), uintptr(start), uintptr(end), uintptr(count), uintptr(xtype), uintptr(indices), uintptr(basevertex), 0, 0)\n}", "func PlotPoint(x, y gb.UINT8) {}", "func DrawRangeElements(mode uint32, start uint32, end uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n\tC.glowDrawRangeElements(gpDrawRangeElements, (C.GLenum)(mode), (C.GLuint)(start), (C.GLuint)(end), (C.GLsizei)(count), (C.GLenum)(xtype), indices)\n}", "func DrawRangeElements(mode uint32, start uint32, end uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n\tC.glowDrawRangeElements(gpDrawRangeElements, (C.GLenum)(mode), (C.GLuint)(start), (C.GLuint)(end), (C.GLsizei)(count), (C.GLenum)(xtype), indices)\n}", "func (obj *Device) DrawIndexedPrimitiveUPuint32(\n\tprimitiveType PRIMITIVETYPE,\n\tminVertexIndex uint,\n\tnumVertices uint,\n\tprimitiveCount uint,\n\tindexData []uint32,\n\tvertexStreamZeroData uintptr,\n\tvertexStreamZeroStride uint,\n) Error {\n\treturn obj.DrawIndexedPrimitiveUP(\n\t\tprimitiveType,\n\t\tminVertexIndex,\n\t\tnumVertices,\n\t\tprimitiveCount,\n\t\tuintptr(unsafe.Pointer(&indexData[0])),\n\t\tFMT_INDEX32,\n\t\tvertexStreamZeroData,\n\t\tvertexStreamZeroStride,\n\t)\n}", "func (obj *Device) DrawIndexedPrimitiveUPuint16(\n\tprimitiveType PRIMITIVETYPE,\n\tminVertexIndex uint,\n\tnumVertices uint,\n\tprimitiveCount uint,\n\tindexData []uint16,\n\tvertexStreamZeroData uintptr,\n\tvertexStreamZeroStride uint,\n) (\n\terr Error,\n) {\n\treturn obj.DrawIndexedPrimitiveUP(\n\t\tprimitiveType,\n\t\tminVertexIndex,\n\t\tnumVertices,\n\t\tprimitiveCount,\n\t\tuintptr(unsafe.Pointer(&indexData[0])),\n\t\tFMT_INDEX16,\n\t\tvertexStreamZeroData,\n\t\tvertexStreamZeroStride,\n\t)\n}", "func printColored(boundaries []colored_data, data []byte) []string {\n\tgrouping := 2\n\tper_line := 16\n\t// 16 bytes per line, grouped by 2 bytes\n\tnlines := len(data) / 16\n\tif len(data) % 16 > 0 {\n\t\tnlines++\n\t}\n\t\n\tout := make([]string, nlines)\n\n\tkolo := \"\\x1B[0m\"\n\t\n\tfor line := 0; line < nlines; line++ {\n\t\ts := \"\\t0x\"\n\t\txy := make([]byte, 2)\n\t\tline_offset := line * per_line\n\t\txy[0] = byte(line_offset >> 8)\n\t\txy[1] = byte(line_offset & 0xff)\n\t\ts = s + hex.EncodeToString(xy) + \":\\t\" + kolo\n\n\n\t\tline_length := per_line\n\t\tif line == nlines - 1 && len(data) % 16 > 0 {\n\t\t\tline_length = len(data) % 16\n\t\t}\n\n\t\tfor b := 0; b < line_length; b++ {\n\t\t\ttotal_offset := line * per_line + b\n\n\t\t\t// inserting coulourings\n\t\t\tfor x := 0; x < len(boundaries); x++ {\n\t\t\t\t//fmt.Println(\"!\")\n\t\t\t\tif(boundaries[x].offset == uint16(total_offset)) {\n\t\t\t\t\ts = s + boundaries[x].color\n\t\t\t\t\tkolo = boundaries[x].color\n\t\t\t\t}\n\t\t\t}\n\t\n\t\t\t// add byte from total_offset\n\t\t\txxx := make([]byte, 1)\n\t\t\txxx[0] = data[total_offset]\n\t\t\ts = s + hex.EncodeToString(xxx)\n\t\t\t\n\t\t\t// if b > 0 && b % grouping == 0, insert space\n\t\t\t\n\t\t\tif b > 0 && (b-1) % grouping == 0 {\n\t\t\t\ts = s + \" \"\n\t\t\t}\n\t\t\t\n\t\t}\n\t\t\n\t\tout[line] = s + COLOR_NORMAL\n\t}\n\t\n\treturn out\n}", "func (a *Array) Print() {\n\tvar format string\n\tfor i := uint(0); i < a.Len(); i++ {\n\t\tformat += fmt.Sprintf(\"|%+v\", a.data[i])\n\t}\n\tfmt.Println(format)\n}", "func (self *Tween) GenerateDataI(args ...interface{}) []interface{}{\n\tarray00 := self.Object.Call(\"generateData\", args)\n\tlength00 := array00.Length()\n\tout00 := make([]interface{}, length00, length00)\n\tfor i00 := 0; i00 < length00; i00++ {\n\t\tout00[i00] = array00.Index(i00)\n\t}\n\treturn out00\n}", "func (v *View) ReadAt(data []byte, off int64) (int, error) { return v.data.ReadAt(data, off) }", "func NewPageBuffer(aSlice interface{}, desiredPageNo int) *PageBuffer {\n return newPageBuffer(\n sliceValue(aSlice, false),\n desiredPageNo,\n valueHandler{})\n}", "func (a *Array) Literal() {}", "func PWprint(L *lua.LState) int {\n\ttext := L.ToString(1)\n\tx := L.ToInt(2)\n\ty := L.ToInt(3)\n\tcolor := L.ToInt(4)\n\n\tc := palette[color]\n\txx := x\n\tsx := x\n\tyy := y\n\n\tfor _, ch := range text {\n\t\tchar := font[string(ch)]\n\t\tfor i := 0; i < char.Height; i++ {\n\t\t \tbin := char.Data[i]\n\n\t\t\tfor _, pix := range bin {\n\t\t\t\tif string(pix) == \"1\" { setpixel(xx + sx, char.Y + yy, int(c[0]), int(c[1]), int(c[2])) }\n\t\t\t \txx += 1\n\t\t\t}\n\t\t\tyy += 1\n\t\t\txx = x\n\t\t}\n\t\tsx += char.Width\n\t\tyy = y\n\t}\n\n\treturn 1\n}", "func DrawRangeElementsBaseVertex(mode uint32, start uint32, end uint32, count int32, xtype uint32, indices unsafe.Pointer, basevertex int32) {\n C.glowDrawRangeElementsBaseVertex(gpDrawRangeElementsBaseVertex, (C.GLenum)(mode), (C.GLuint)(start), (C.GLuint)(end), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLint)(basevertex))\n}", "func ex1() {\n\tx := [5]int{1, 2, 4, 8, 16}\n\tfor i, v := range x {\n\t\tfmt.Println(i, v)\n\t}\n\tfmt.Printf(\"%T\\n\", x)\n\n}", "func main() {\n\tslice := []int{10, 200, 35, 45, 5, 78, 98, 65, 3, 86}\n\tfmt.Println(slice)\n\tfor i, v := range slice {\n\n\t\tfmt.Println(i, \"->\", v)\n\n\t}\n\n\tfmt.Printf(\"%T\", slice)\n\n}", "func (ren *RenderComponent) generateBufferContent() []float32 {\n\tscaleX := ren.scale.X\n\tscaleY := ren.scale.Y\n\trotation := float32(0.0)\n\ttransparency := float32(1.0)\n\tc := ren.Color\n\n\tfx := float32(0)\n\tfy := float32(0)\n\tfx2 := ren.drawable.Width()\n\tfy2 := ren.drawable.Height()\n\n\tif scaleX != 1 || scaleY != 1 {\n\t\t//fx *= scaleX\n\t\t//fy *= scaleY\n\t\tfx2 *= scaleX\n\t\tfy2 *= scaleY\n\t}\n\n\tp1x := fx\n\tp1y := fy\n\tp2x := fx\n\tp2y := fy2\n\tp3x := fx2\n\tp3y := fy2\n\tp4x := fx2\n\tp4y := fy\n\n\tvar x1 float32\n\tvar y1 float32\n\tvar x2 float32\n\tvar y2 float32\n\tvar x3 float32\n\tvar y3 float32\n\tvar x4 float32\n\tvar y4 float32\n\n\tif rotation != 0 {\n\t\trot := rotation * (math.Pi / 180.0)\n\n\t\tcos := math.Cos(rot)\n\t\tsin := math.Sin(rot)\n\n\t\tx1 = cos*p1x - sin*p1y\n\t\ty1 = sin*p1x + cos*p1y\n\n\t\tx2 = cos*p2x - sin*p2y\n\t\ty2 = sin*p2x + cos*p2y\n\n\t\tx3 = cos*p3x - sin*p3y\n\t\ty3 = sin*p3x + cos*p3y\n\n\t\tx4 = x1 + (x3 - x2)\n\t\ty4 = y3 - (y2 - y1)\n\t} else {\n\t\tx1 = p1x\n\t\ty1 = p1y\n\n\t\tx2 = p2x\n\t\ty2 = p2y\n\n\t\tx3 = p3x\n\t\ty3 = p3y\n\n\t\tx4 = p4x\n\t\ty4 = p4y\n\t}\n\n\tcolorR, colorG, colorB, _ := c.RGBA()\n\n\tred := colorR\n\tgreen := colorG << 8\n\tblue := colorB << 16\n\talpha := uint32(transparency*255.0) << 24\n\n\ttint := math.Float32frombits((alpha | blue | green | red) & 0xfeffffff)\n\n\tu, v, u2, v2 := ren.drawable.View()\n\n\treturn []float32{x1, y1, u, v, tint, x4, y4, u2, v, tint, x3, y3, u2, v2, tint, x2, y2, u, v2, tint}\n}", "func makeSlice(offset dvid.Point3d, size dvid.Point2d) []byte {\n\tnumBytes := size[0] * size[1] * 8\n\tslice := make([]byte, numBytes, numBytes)\n\ti := 0\n\tmodz := offset[2] % int32(len(zdata))\n\tfor y := int32(0); y < size[1]; y++ {\n\t\tsy := y + offset[1]\n\t\tmody := sy % int32(len(ydata))\n\t\tsx := offset[0]\n\t\tfor x := int32(0); x < size[0]; x++ {\n\t\t\tmodx := sx % int32(len(xdata))\n\t\t\tbinary.BigEndian.PutUint64(slice[i:i+8], xdata[modx]+ydata[mody]+zdata[modz])\n\t\t\ti += 8\n\t\t\tsx++\n\t\t}\n\t}\n\treturn slice\n}", "func (p *Pprint) pprint(data interface{}) {\n\t// temp := reflect.TypeOf(data).Kind()\n\t// p.test[\"array\"] = reflect.Map\n\t// fmt.Println(p.test)\n\t// if reflect.Array == temp {\n\t// \tfmt.Println(\"scussu\")\n\t// }\n\t// p.test[temp.String()] = 0\n\tp.Typemode = reflect.TypeOf(data).Kind()\n\tif p.Typemode == reflect.Map {\n\t\tp.PrintMaps(data)\n\t} else if p.Typemode == reflect.Slice {\n\t\tp.PrintArrays(data)\n\t} else if p.Typemode == reflect.Array {\n\t\tp.PrintArrays(data)\n\t} else {\n\t\tfmt.Println(data)\n\t}\n}", "func (a PixelArray) Print() {\n\tfor y := len(a) - 1; y >= 0; y-- {\n\t\tfmt.Printf(\"%d\\t\", y)\n\t\tfor x := 0; x < len(a[0]); x++ {\n\t\t\tfmt.Printf(\"%b%b%b%b%b%b%b%b\",\n\t\t\t\t(a[y][x])&1,\n\t\t\t\t(a[y][x]>>1)&1,\n\t\t\t\t(a[y][x]>>2)&1,\n\t\t\t\t(a[y][x]>>3)&1,\n\t\t\t\t(a[y][x]>>4)&1,\n\t\t\t\t(a[y][x]>>5)&1,\n\t\t\t\t(a[y][x]>>6)&1,\n\t\t\t\t(a[y][x]>>7)&1)\n\t\t}\n\n\t\tfmt.Printf(\"\\n\")\n\t}\n}", "func DrawElementsIndirect(mode uint32, xtype uint32, indirect unsafe.Pointer) {\n C.glowDrawElementsIndirect(gpDrawElementsIndirect, (C.GLenum)(mode), (C.GLenum)(xtype), indirect)\n}", "func (c *Compound) DrawOffset(buff draw.Image, xOff float64, yOff float64) {\n\tc.lock.RLock()\n\tc.subRenderables[c.curRenderable].DrawOffset(buff, c.X()+xOff, c.Y()+yOff)\n\tc.lock.RUnlock()\n}", "func (gl *WebGL) DrawElements(mode GLEnum, count int, valueType GLEnum, offset int) {\n\tgl.context.Call(\"drawElements\", mode, count, valueType, offset)\n}", "func (a *Array) Format(f fmt.State, c rune) {\n\tswitch c {\n\tcase 'z': // Private format specifier, supports Entity.Signature\n\t\tfmt.Fprintf(f, \"[%d]%z\", a.Size, a.ValueType)\n\tcase 'r': // Private format specifier, supports Type.Representation\n\t\tfmt.Fprintf(f, \"[%d]%r\", a.Size, a.ValueType)\n\tdefault:\n\t\tif a.Alias != \"\" {\n\t\t\tfmt.Fprint(f, a.Alias)\n\t\t} else {\n\t\t\tfmt.Fprintf(f, \"[%d]%v\", a.Size, a.ValueType)\n\t\t}\n\t}\n}", "func main() {\n\ts := []int{5, 3, 2, 6, 1, 6, 7, 10, 49, 100}\n\tfor i, v := range s {\n\t\tfmt.Println(i, v)\n\t}\n\tfmt.Printf(\"%T\\n\", s)\n}", "func (p *IntVector) Data() []int {\n\tarr := make([]int, p.Len());\n\tfor i, v := range p.a {\n\t\tarr[i] = v.(int)\n\t}\n\treturn arr;\n}", "func (self *SinglePad) Index() int{\n return self.Object.Get(\"index\").Int()\n}", "func (c *Client) ShowArrayPrism(ctx context.Context, path string, anyArray []interface{}, boolArray []bool, dateTimeArray []time.Time, intArray []int, numArray []float64, stringArray []string, uuidArray []uuid.UUID) (*http.Response, error) {\n\treq, err := c.NewShowArrayPrismRequest(ctx, path, anyArray, boolArray, dateTimeArray, intArray, numArray, stringArray, uuidArray)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\treturn c.Client.Do(ctx, req)\n}", "func MultiDrawElements(mode uint32, count *int32, xtype uint32, indices *unsafe.Pointer, drawcount int32) {\n\tsyscall.Syscall6(gpMultiDrawElements, 5, uintptr(mode), uintptr(unsafe.Pointer(count)), uintptr(xtype), uintptr(unsafe.Pointer(indices)), uintptr(drawcount), 0)\n}", "func iterateObjects1DWithIndexes() {\n\tfmt.Println(\"*** iterateObjects1DWithIndexes\")\n\n\ttype Point struct {\n\t\tX int\n\t\tY int\n\t}\n\tpoints := [5]Point{\n\t\tPoint{1, 1},\n\t\tPoint{2, 2},\n\t\tPoint{3, 3},\n\t\tPoint{4, 4},\n\t\tPoint{5, 5},\n\t}\n\n\tfor i, e := range points {\n\t\tfmt.Printf(\"ints[%d]: %+v\\n\", i, e)\n\t}\n\tfmt.Println(\"\")\n}", "func DrawElements(mode uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n\tC.glowDrawElements(gpDrawElements, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices)\n}", "func DrawElements(mode uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n\tC.glowDrawElements(gpDrawElements, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices)\n}", "func DrawOutput(val int) {\n\tfmt.Printf(\"┌─────────┐\")\n\tfmt.Printf(\"\\n│%9d│\", val)\n\tfmt.Printf(\"\\n└─────────┘\\n\")\n}", "func (h *HAProxyManager) render(ports []uint16) ([]byte, error) {\n\n\t// prepare the context\n\td := make([]templateContext, len(ports))\n\tfor i, port := range ports {\n\t\tif i == len(h.serviceAddrs) {\n\t\t\th.logger.Warnf(\"got port index %d, but only have %d service addrs. ports=%v serviceAddrs=%v\", i, len(h.serviceAddrs), ports, h.serviceAddrs)\n\t\t\tcontinue\n\t\t}\n\t\td[i] = templateContext{Port: port, Source: h.listenAddr, Dest: h.serviceAddrs[i]}\n\t}\n\n\t// render the template\n\tbuf := &bytes.Buffer{}\n\tif err := h.template.Execute(buf, d); err != nil {\n\t\treturn nil, err\n\t}\n\treturn buf.Bytes(), nil\n}", "func traversePos(data []int, index int) []int {\n\tif bt[index] != nil {\n\t\tdata = traversePos(data, (index*2)+1)\n\t\tdata = traversePos(data, (index*2)+2)\n\t\tdata = append(data, bt[index].value)\n\t}\n\treturn data\n}", "func (Parser) Render(rawBytes []byte, urlPrefix string, metas map[string]string, isWiki bool) []byte {\n\treturn Render(rawBytes, urlPrefix, metas, isWiki)\n}", "func DrawElementsBaseVertex(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, basevertex int32) {\n\tsyscall.Syscall6(gpDrawElementsBaseVertex, 5, uintptr(mode), uintptr(count), uintptr(xtype), uintptr(indices), uintptr(basevertex), 0)\n}", "func MultiDrawElementsIndirect(mode uint32, xtype uint32, indirect unsafe.Pointer, drawcount int32, stride int32) {\n\tsyscall.Syscall6(gpMultiDrawElementsIndirect, 5, uintptr(mode), uintptr(xtype), uintptr(indirect), uintptr(drawcount), uintptr(stride), 0)\n}", "func TexCoordPointer(size int32, xtype uint32, stride int32, pointer unsafe.Pointer) {\n C.glowTexCoordPointer(gpTexCoordPointer, (C.GLint)(size), (C.GLenum)(xtype), (C.GLsizei)(stride), pointer)\n}", "func (c *curve) data(x, y *mod.Int) ([]byte, error) {\n\tb := c.encodePoint(x, y)\n\tdl := int(b[0])\n\tif dl > c.embedLen() {\n\t\treturn nil, errors.New(\"invalid embedded data length\")\n\t}\n\treturn b[1 : 1+dl], nil\n}", "func (obj *Device) DrawPrimitiveUP(\n\ttyp PRIMITIVETYPE,\n\tprimitiveCount uint,\n\tvertexStreamZeroData uintptr,\n\tvertexStreamZeroStride uint,\n) Error {\n\tret, _, _ := syscall.Syscall6(\n\t\tobj.vtbl.DrawPrimitiveUP,\n\t\t5,\n\t\tuintptr(unsafe.Pointer(obj)),\n\t\tuintptr(typ),\n\t\tuintptr(primitiveCount),\n\t\tvertexStreamZeroData,\n\t\tuintptr(vertexStreamZeroStride),\n\t\t0,\n\t)\n\treturn toErr(ret)\n}", "func (r renderer) TableCell(out *bytes.Buffer, text []byte, flags int) {}", "func (pb *PageBuffer) Values() interface{} {\n offset := pb.pageOffset(pb.page_no)\n return pb.buffer.Slice(offset, offset + pb.idx).Interface()\n}", "func (renderer *SimpleMatrixRenderer) Render() {\n\trenderer.renderCharacter(\"\\n\")\n\n\tfor row := 0; row < renderer.Matrix.Height; row++ {\n\t\tfor col := 0; col < renderer.Matrix.Width; col++ {\n\t\t\tif !renderer.Matrix.IsFieldOccupied(row, col) {\n\t\t\t\trenderer.renderUnoccupiedField()\n\t\t\t} else {\n\t\t\t\trenderer.renderOccupiedFieldAtCurrentCursorPos(row, col)\n\t\t\t}\n\t\t}\n\n\t\trenderer.renderCharacter(\"\\n\")\n\t}\n\n\trenderer.renderCharacter(\"\\n\")\n}", "func (f genHelperEncoder) EncWriteArrayStart(length int) { f.e.arrayStart(length) }", "func (t *UCharT) Pack(builder *flatbuffers.Builder) flatbuffers.UOffsetT {\n\tif t == nil {\n\t\treturn 0\n\t}\n\tinventoryOffset := flatbuffers.UOffsetT(0)\n\tif t.Inventory != nil {\n\t\tinventoryOffset = builder.CreateByteString(t.Inventory)\n\t}\n\tinventory1Offset := flatbuffers.UOffsetT(0)\n\tif t.Inventory1 != nil {\n\t\tinventory1Length := len(t.Inventory1)\n\t\tUCharStartInventory1Vector(builder, inventory1Length)\n\t\tfor j := inventory1Length - 1; j >= 0; j-- {\n\t\t\tbuilder.PrependInt8(t.Inventory1[j])\n\t\t}\n\t\tinventory1Offset = UCharEndInventory1Vector(builder, inventory1Length)\n\t}\n\tcolorListOffset := flatbuffers.UOffsetT(0)\n\tif t.ColorList != nil {\n\t\tcolorListLength := len(t.ColorList)\n\t\tUCharStartColorListVector(builder, colorListLength)\n\t\tfor j := colorListLength - 1; j >= 0; j-- {\n\t\t\tbuilder.PrependInt8(int8(t.ColorList[j]))\n\t\t}\n\t\tcolorListOffset = UCharEndColorListVector(builder, colorListLength)\n\t}\n\n\t// pack process all field\n\n\tUCharStart(builder)\n\tUCharAddInventory(builder, inventoryOffset)\n\tUCharAddInventory1(builder, inventory1Offset)\n\tUCharAddColorList(builder, colorListOffset)\n\treturn UCharEnd(builder)\n}", "func renderTemplateBytes(name string, data interface{}) ([]byte, error) {\n\tvar buf bytes.Buffer\n\tif err := Tmpl.Render(&buf, name, data); err != nil {\n\t\treturn nil, err\n\t}\n\treturn buf.Bytes(), nil\n}", "func renderTemplateBytes(name string, data interface{}) ([]byte, error) {\n\tvar buf bytes.Buffer\n\tif err := Tmpl.Render(&buf, name, data); err != nil {\n\t\treturn nil, err\n\t}\n\treturn buf.Bytes(), nil\n}", "func (c *cartridge) Render() {\n\tc.Cls()\n\tc.PrintAt(fmt.Sprintf(\"counter:%d\", c.counter), c.x, c.y)\n}", "func DrawElementsBaseVertex(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, basevertex int32) {\n C.glowDrawElementsBaseVertex(gpDrawElementsBaseVertex, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLint)(basevertex))\n}", "func (r renderer) Table(out *bytes.Buffer, header []byte, body []byte, columnData []int) {}", "func (renderer *SimpleMatrixRenderer) renderOccupiedFieldAtCurrentCursorPos(row int, col int) {\n\tpiece := renderer.Matrix.GetPieceOccupying(row, col)\n\n\tr, g, b := (*piece).GetColorAsRGB()\n\ttotal := int(r) + int(g) + int(b)\n\n\tcharacter := \"▧\"\n\tcharacterColor := black\n\n\tif total > 230*3 {\n\t\tcharacterColor = color.New(color.FgBlue)\n\t} else if total > 180*3 {\n\t\tcharacterColor = color.New(color.FgYellow)\n\t} else if total > 120*3 {\n\t\tcharacterColor = color.New(color.FgRed)\n\t} else if total > 50*3 {\n\t\tcharacterColor = color.New(color.FgGreen)\n\t} else {\n\t\tcharacterColor = color.New(color.FgMagenta)\n\t}\n\n\trenderer.renderCharacterWithColor(character, characterColor)\n}", "func (r renderer) ListItem(out *bytes.Buffer, text []byte, flags int) {}", "func (el *Fill) TSpan() {}", "func (isf intSliceFunctorImpl) String() string {\n\treturn fmt.Sprintf(\"%#v\", isf.ints)\n}", "func PrintArray(a *[]int) {\n\tvar i int\n\tfor i < len(*a) {\n\t\tfmt.Printf(\"%v\\t\", (*a)[i])\n\t\ti++\n\t}\n\tfmt.Printf(\"\\n\")\n}", "func PrintArray(a *[]int) {\n\tvar i int\n\tfor i < len(*a) {\n\t\tfmt.Printf(\"%v\\t\", (*a)[i])\n\t\ti++\n\t}\n\tfmt.Printf(\"\\n\")\n}", "func (w wireFormat) MapBySlice() {}", "func (s *SliceInt) Data() []int {\n\tif s == nil {\n\t\treturn nil\n\t}\n\treturn s.data\n}", "func (p *printer) Array(element string) {\n\tp.Formatter.Array(element)\n}", "func (this *Data) Byte(offset uintptr) []byte {\n\tvar result []byte\n\thdr := (*reflect.SliceHeader)(unsafe.Pointer(&result))\n\thdr.Data = this.buf + uintptr(offset)\n\thdr.Len = int(this.cap) - int(offset)\n\thdr.Cap = hdr.Len\n\treturn result\n}", "func (f *Font) Index(r rune) uint16 {\n\t// log.Printf(\"r %v\", r)\n\t// log.Printf(\"len %v\", len(f.cmap_entry_array))\n\tcm_len := len(f.cmap_entry_array)\n\n\tx := uint32(r)\n\tfor lo, hi := 0, cm_len; lo < hi; {\n\t\tmi := lo + (hi-lo)/2\n\t\t// log.Printf(\"lo hi mi %v %v %v\", lo, hi, mi)\n\t\tcm := &f.cmap_entry_array[mi]\n\t\t// log.Printf(\"cm %v\", cm)\n\t\tif x < cm.start_code {\n\t\t\thi = mi\n\t\t} else if cm.end_code < x {\n\t\t\tlo = mi + 1\n\t\t} else if cm.id_range_offset == 0 {\n\t\t\t// log.Printf(\"x id_delta %v %v\", x, cm.id_delta)\n\t\t\treturn uint16(x + cm.id_delta)\n\t\t} else {\n\t\t\toffset := int(cm.id_range_offset) + 2*(mi-cm_len+int(x-cm.start_code))\n\t\t\treturn uint16(octets_to_u16(f.cmap_index_array, offset))\n\t\t}\n\t}\n\n\treturn 0\n}", "func (g *interfaceGenerator) unmarshalPrimitiveScalar(accessor, typ, bufVar, typeCast string) {\n\tswitch typ {\n\tcase \"byte\":\n\t\tg.emit(\"*%s = %s(%s[0])\\n\", accessor, typeCast, bufVar)\n\tcase \"int8\", \"uint8\":\n\t\tg.emit(\"*%s = %s(%s(%s[0]))\\n\", accessor, typeCast, typ, bufVar)\n\tcase \"int16\", \"uint16\":\n\t\tg.recordUsedImport(\"usermem\")\n\t\tg.emit(\"*%s = %s(%s(usermem.ByteOrder.Uint16(%s[:2])))\\n\", accessor, typeCast, typ, bufVar)\n\tcase \"int32\", \"uint32\":\n\t\tg.recordUsedImport(\"usermem\")\n\t\tg.emit(\"*%s = %s(%s(usermem.ByteOrder.Uint32(%s[:4])))\\n\", accessor, typeCast, typ, bufVar)\n\tcase \"int64\", \"uint64\":\n\t\tg.recordUsedImport(\"usermem\")\n\t\tg.emit(\"*%s = %s(%s(usermem.ByteOrder.Uint64(%s[:8])))\\n\", accessor, typeCast, typ, bufVar)\n\tdefault:\n\t\tg.emit(\"// Explicilty cast to the underlying type before dispatching to\\n\")\n\t\tg.emit(\"// UnmarshalBytes, so we don't recursively call %s.UnmarshalBytes\\n\", accessor)\n\t\tg.emit(\"inner := (*%s)(%s)\\n\", typ, accessor)\n\t\tg.emit(\"inner.UnmarshalBytes(%s[:%s.SizeBytes()])\\n\", bufVar, accessor)\n\t}\n}", "func (cont *tuiApplicationController) drawView() {\n\tcont.Sync.Lock()\n\tif !cont.Changed || cont.TuiFileReaderWorker == nil {\n\t\tcont.Sync.Unlock()\n\t\treturn\n\t}\n\tcont.Sync.Unlock()\n\n\t// reset the elements by clearing out every one\n\ttviewApplication.QueueUpdateDraw(func() {\n\t\tfor _, t := range displayResults {\n\t\t\tt.Title.SetText(\"\")\n\t\t\tt.Body.SetText(\"\")\n\t\t\tt.SpacerOne.SetText(\"\")\n\t\t\tt.SpacerTwo.SetText(\"\")\n\t\t\tresultsFlex.ResizeItem(t.Body, 0, 0)\n\t\t}\n\t})\n\n\tcont.Sync.Lock()\n\tresultsCopy := make([]*FileJob, len(cont.Results))\n\tcopy(resultsCopy, cont.Results)\n\tcont.Sync.Unlock()\n\n\t// rank all results\n\t// then go and get the relevant portion for display\n\trankResults(int(cont.TuiFileReaderWorker.GetFileCount()), resultsCopy)\n\tdocumentTermFrequency := calculateDocumentTermFrequency(resultsCopy)\n\n\t// after ranking only get the details for as many as we actually need to\n\t// cut down on processing\n\tif len(resultsCopy) > len(displayResults) {\n\t\tresultsCopy = resultsCopy[:len(displayResults)]\n\t}\n\n\t// We use this to swap out the highlights after we escape to ensure that we don't escape\n\t// out own colours\n\tmd5Digest := md5.New()\n\tfmtBegin := hex.EncodeToString(md5Digest.Sum([]byte(fmt.Sprintf(\"begin_%d\", makeTimestampNano()))))\n\tfmtEnd := hex.EncodeToString(md5Digest.Sum([]byte(fmt.Sprintf(\"end_%d\", makeTimestampNano()))))\n\n\t// go and get the codeResults the user wants to see using selected as the offset to display from\n\tvar codeResults []codeResult\n\tfor i, res := range resultsCopy {\n\t\tif i >= cont.Offset {\n\t\t\tsnippets := extractRelevantV3(res, documentTermFrequency, int(SnippetLength), \"…\")[0]\n\n\t\t\t// now that we have the relevant portion we need to get just the bits related to highlight it correctly\n\t\t\t// which this method does. It takes in the snippet, we extract and all of the locations and then returns just\n\t\t\tl := getLocated(res, snippets)\n\t\t\tcoloredContent := str.HighlightString(snippets.Content, l, fmtBegin, fmtEnd)\n\t\t\tcoloredContent = tview.Escape(coloredContent)\n\n\t\t\tcoloredContent = strings.Replace(coloredContent, fmtBegin, \"[red]\", -1)\n\t\t\tcoloredContent = strings.Replace(coloredContent, fmtEnd, \"[white]\", -1)\n\n\t\t\tcodeResults = append(codeResults, codeResult{\n\t\t\t\tTitle: res.Location,\n\t\t\t\tContent: coloredContent,\n\t\t\t\tScore: res.Score,\n\t\t\t\tLocation: res.Location,\n\t\t\t})\n\t\t}\n\t}\n\n\t// render out what the user wants to see based on the results that have been chosen\n\ttviewApplication.QueueUpdateDraw(func() {\n\t\tfor i, t := range codeResults {\n\t\t\tdisplayResults[i].Title.SetText(fmt.Sprintf(\"[fuchsia]%s (%f)[-:-:-]\", t.Title, t.Score))\n\t\t\tdisplayResults[i].Body.SetText(t.Content)\n\t\t\tdisplayResults[i].Location = t.Location\n\n\t\t\t//we need to update the item so that it displays everything we have put in\n\t\t\tresultsFlex.ResizeItem(displayResults[i].Body, len(strings.Split(t.Content, \"\\n\")), 0)\n\t\t}\n\t})\n\n\t// we can only set that nothing\n\tcont.Changed = false\n}", "func printArray(arr [5]int) {\n\tarr[0] = 100\n\tfor i, v := range arr {\n\t\tfmt.Println(i, v)\n\t}\n}", "func DrawRangeElementsBaseVertex(mode uint32, start uint32, end uint32, count int32, xtype uint32, indices unsafe.Pointer, basevertex int32) {\n\tC.glowDrawRangeElementsBaseVertex(gpDrawRangeElementsBaseVertex, (C.GLenum)(mode), (C.GLuint)(start), (C.GLuint)(end), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLint)(basevertex))\n}", "func DrawRangeElementsBaseVertex(mode uint32, start uint32, end uint32, count int32, xtype uint32, indices unsafe.Pointer, basevertex int32) {\n\tC.glowDrawRangeElementsBaseVertex(gpDrawRangeElementsBaseVertex, (C.GLenum)(mode), (C.GLuint)(start), (C.GLuint)(end), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLint)(basevertex))\n}", "func TemplateData(p string, data interface{}) {\n}", "func (ff *fftag) at(id int) (x, y int) { return id / ff.msize, id % ff.msize }", "func (e rawEntry) value(buf []byte) rawValue { return buf[e.ptr():][:e.sz()] }" ]
[ "0.585935", "0.52075523", "0.5084374", "0.50331354", "0.49324766", "0.49158472", "0.47837278", "0.47759205", "0.47650397", "0.47415584", "0.47280264", "0.4711649", "0.46952814", "0.46948847", "0.46581078", "0.46546912", "0.4645866", "0.4645866", "0.46294165", "0.4621351", "0.46151462", "0.45862997", "0.4569046", "0.45608258", "0.45602304", "0.45508763", "0.45205447", "0.45182082", "0.45012426", "0.44990006", "0.44898683", "0.4485599", "0.44834146", "0.44771138", "0.44771138", "0.44735974", "0.4457397", "0.44468623", "0.44385836", "0.4434415", "0.4424735", "0.4406977", "0.44036135", "0.4395799", "0.43906114", "0.43863577", "0.43735808", "0.43662465", "0.4358424", "0.43466768", "0.43428254", "0.43425608", "0.43332392", "0.43324766", "0.4327725", "0.43212283", "0.4299294", "0.42948902", "0.42931882", "0.42930514", "0.42899758", "0.4288373", "0.4288373", "0.4285799", "0.42789567", "0.4278423", "0.42754033", "0.4270644", "0.42685115", "0.42660847", "0.426504", "0.42621335", "0.42607495", "0.42560473", "0.42518598", "0.42515504", "0.42440006", "0.4242743", "0.4242743", "0.42426482", "0.42423233", "0.4241733", "0.4238865", "0.4238587", "0.42337468", "0.42179447", "0.42178208", "0.42178208", "0.42153642", "0.42118526", "0.4211703", "0.42063305", "0.42050475", "0.4201446", "0.41942853", "0.41914222", "0.4187597", "0.4187597", "0.41851667", "0.41804147", "0.4160377" ]
0.0
-1
render indexed primitives from array data, taking parameters from memory
func DrawElementsIndirect(mode uint32, xtype uint32, indirect unsafe.Pointer) { C.glowDrawElementsIndirect(gpDrawElementsIndirect, (C.GLenum)(mode), (C.GLenum)(xtype), indirect) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func (obj *Device) DrawIndexedPrimitive(\n\ttyp PRIMITIVETYPE,\n\tbaseVertexIndex int,\n\tminIndex uint,\n\tnumVertices uint,\n\tstartIndex uint,\n\tprimitiveCount uint,\n) Error {\n\tret, _, _ := syscall.Syscall9(\n\t\tobj.vtbl.DrawIndexedPrimitive,\n\t\t7,\n\t\tuintptr(unsafe.Pointer(obj)),\n\t\tuintptr(typ),\n\t\tuintptr(baseVertexIndex),\n\t\tuintptr(minIndex),\n\t\tuintptr(numVertices),\n\t\tuintptr(startIndex),\n\t\tuintptr(primitiveCount),\n\t\t0,\n\t\t0,\n\t)\n\treturn toErr(ret)\n}", "func (v Binary) Render(i, width int, baseStyle lipgloss.Style) string {\n\tw := dataWidth(width)\n\t_, err := v.Seek(int64(i*w), io.SeekStart)\n\tif err != nil {\n\t\treturn baseStyle.Blink(true).Render(err.Error())\n\t}\n\tif len(v.b) != w {\n\t\tv.b = make([]byte, w)\n\t}\n\tn, err := v.Read(v.b)\n\tif err != nil && !errors.Is(err, io.EOF) {\n\t\treturn baseStyle.Blink(true).Render(err.Error())\n\t}\n\ts := fmt.Sprintf(\"% X%s \", v.b[0:n], strings.Repeat(\" \", w-n))\n\tvar x strings.Builder\n\tfor i := 0; i < n; i++ {\n\t\tif unicode.IsPrint(rune(v.b[i])) {\n\t\t\tx.WriteRune(rune(v.b[i]))\n\t\t} else {\n\t\t\tx.WriteRune('.')\n\t\t}\n\t}\n\treturn baseStyle.Render(s + x.String())\n}", "func (obj *Device) DrawIndexedPrimitiveUP(\n\ttyp PRIMITIVETYPE,\n\tminVertexIndex uint,\n\tnumVertices uint,\n\tprimitiveCount uint,\n\tindexData uintptr,\n\tindexDataFormat FORMAT,\n\tvertexStreamZeroData uintptr,\n\tvertexStreamZeroStride uint,\n) Error {\n\tret, _, _ := syscall.Syscall9(\n\t\tobj.vtbl.DrawIndexedPrimitiveUP,\n\t\t9,\n\t\tuintptr(unsafe.Pointer(obj)),\n\t\tuintptr(typ),\n\t\tuintptr(minVertexIndex),\n\t\tuintptr(numVertices),\n\t\tuintptr(primitiveCount),\n\t\tindexData,\n\t\tuintptr(indexDataFormat),\n\t\tvertexStreamZeroData,\n\t\tuintptr(vertexStreamZeroStride),\n\t)\n\treturn toErr(ret)\n}", "func (c *Plain) RenderIndexContent(content interface{}) (string, error) {\n\treturn content.(string), nil\n}", "func renderResults(vals []interface{}) Data {\n\tvar nilcount int\n\tvar obj interface{}\n\tfor _, val := range vals {\n\t\tswitch val.(type) {\n\t\tcase image.Image, Data:\n\t\t\tobj = val\n\t\tcase nil:\n\t\t\tnilcount++\n\t\t}\n\t}\n\tif obj != nil && nilcount == len(vals)-1 {\n\t\tswitch val := obj.(type) {\n\t\tcase image.Image:\n\t\t\tdata, err := image0(val)\n\t\t\tif err == nil {\n\t\t\t\treturn data\n\t\t\t}\n\t\tcase Data:\n\t\t\treturn val\n\t\t}\n\t}\n\tif nilcount == len(vals) {\n\t\t// if all values are nil, return empty Data\n\t\treturn Data{}\n\t}\n\treturn MakeData(\"text/plain\", fmt.Sprint(vals...))\n}", "func ArrayElement(i int32) {\n C.glowArrayElement(gpArrayElement, (C.GLint)(i))\n}", "func (vao *VAO) Render() {\n\tgl.BindVertexArray(vao.handle)\n\tif vao.indexBuffer != nil {\n\t\tgl.BindBuffer(gl.ELEMENT_ARRAY_BUFFER, vao.indexBuffer.GetHandle())\n\t\tgl.DrawElements(vao.mode, vao.indexBuffer.Len(), gl.UNSIGNED_SHORT, nil)\n\t\tgl.BindBuffer(gl.ELEMENT_ARRAY_BUFFER, 0)\n\t} else {\n\t\tgl.DrawArrays(vao.mode, 0, vao.vertexBuffers[0].Len())\n\t}\n\tgl.BindVertexArray(0)\n}", "func (native *OpenGL) DrawElements(mode uint32, count int32, elementType uint32, indices uintptr) {\n\tgl.DrawElements(mode, count, elementType, unsafe.Pointer(indices)) // nolint: govet,gas\n}", "func (r *Renderer) Render() {\n\tsx, sz, sy := r.c.Bounds()\n\tsxf := float64(sx - 1)\n\tsyf := float64(sy - 1)\n\tszf := float64(sz - 1)\n\tfor z := 0; z < sz; z++ {\n\t\tfor y := 0; y < sy; y++ {\n\t\t\tfor x := 0; x < sx; x++ {\n\t\t\t\tvar lr, lg, lb, _ uint32\n\t\t\t\tn := uint32(0)\n\t\t\t\tfor _, o := range r.objects {\n\t\t\t\t\tr, g, b, _ := o.At(float64(x)/sxf, float64(y)/syf, float64(z)/szf).RGBA()\n\t\t\t\t\tlr += r >> 8\n\t\t\t\t\tlg += g >> 8\n\t\t\t\t\tlb += b >> 8\n\t\t\t\t\tn++\n\t\t\t\t}\n\t\t\t\tr.c.Set(x, y, z, color.RGBA{uint8(lr/n), uint8(lg/n), uint8(lb/n), 255})\n\t\t\t}\n\t\t}\n\t}\n\tr.c.Render()\n}", "func (obj *Device) DrawIndexedPrimitiveUPuint16(\n\tprimitiveType PRIMITIVETYPE,\n\tminVertexIndex uint,\n\tnumVertices uint,\n\tprimitiveCount uint,\n\tindexData []uint16,\n\tvertexStreamZeroData uintptr,\n\tvertexStreamZeroStride uint,\n) (\n\terr Error,\n) {\n\treturn obj.DrawIndexedPrimitiveUP(\n\t\tprimitiveType,\n\t\tminVertexIndex,\n\t\tnumVertices,\n\t\tprimitiveCount,\n\t\tuintptr(unsafe.Pointer(&indexData[0])),\n\t\tFMT_INDEX16,\n\t\tvertexStreamZeroData,\n\t\tvertexStreamZeroStride,\n\t)\n}", "func iterateObjects1DWithIndexes() {\n\tfmt.Println(\"*** iterateObjects1DWithIndexes\")\n\n\ttype Point struct {\n\t\tX int\n\t\tY int\n\t}\n\tpoints := [5]Point{\n\t\tPoint{1, 1},\n\t\tPoint{2, 2},\n\t\tPoint{3, 3},\n\t\tPoint{4, 4},\n\t\tPoint{5, 5},\n\t}\n\n\tfor i, e := range points {\n\t\tfmt.Printf(\"ints[%d]: %+v\\n\", i, e)\n\t}\n\tfmt.Println(\"\")\n}", "func (self *Tween) GenerateDataI(args ...interface{}) []interface{}{\n\tarray00 := self.Object.Call(\"generateData\", args)\n\tlength00 := array00.Length()\n\tout00 := make([]interface{}, length00, length00)\n\tfor i00 := 0; i00 < length00; i00++ {\n\t\tout00[i00] = array00.Index(i00)\n\t}\n\treturn out00\n}", "func (a *ArrayObject) index(t *thread, args []Object, sourceLine int) Object {\n\tif len(args) != 1 {\n\t\treturn t.vm.initErrorObject(errors.ArgumentError, sourceLine, \"Expect 1 arguments. got=%d\", len(args))\n\t}\n\n\ti := args[0]\n\tindex, ok := i.(*IntegerObject)\n\n\tif !ok {\n\t\treturn t.vm.initErrorObject(errors.TypeError, sourceLine, errors.WrongArgumentTypeFormat, classes.IntegerClass, args[0].Class().Name)\n\t}\n\n\tnormalizedIndex := a.normalizeIndex(index)\n\n\tif normalizedIndex == -1 {\n\t\treturn NULL\n\t}\n\n\treturn a.Elements[normalizedIndex]\n}", "func ScissorIndexed(index uint32, left int32, bottom int32, width int32, height int32) {\n C.glowScissorIndexed(gpScissorIndexed, (C.GLuint)(index), (C.GLint)(left), (C.GLint)(bottom), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func render(fset *token.FileSet, x interface{}) string {\n\tvar buf bytes.Buffer\n\tif err := printer.Fprint(&buf, fset, x); err != nil {\n\t\tpanic(err)\n\t}\n\treturn buf.String()\n}", "func render(fset *token.FileSet, x interface{}) string {\n\tvar buf bytes.Buffer\n\tif err := printer.Fprint(&buf, fset, x); err != nil {\n\t\tpanic(err)\n\t}\n\treturn buf.String()\n}", "func DrawElements(mode uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n C.glowDrawElements(gpDrawElements, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices)\n}", "func DrawElements(mode uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n\tsyscall.Syscall6(gpDrawElements, 4, uintptr(mode), uintptr(count), uintptr(xtype), uintptr(indices), 0, 0)\n}", "func (obj *Device) DrawIndexedPrimitiveUPuint32(\n\tprimitiveType PRIMITIVETYPE,\n\tminVertexIndex uint,\n\tnumVertices uint,\n\tprimitiveCount uint,\n\tindexData []uint32,\n\tvertexStreamZeroData uintptr,\n\tvertexStreamZeroStride uint,\n) Error {\n\treturn obj.DrawIndexedPrimitiveUP(\n\t\tprimitiveType,\n\t\tminVertexIndex,\n\t\tnumVertices,\n\t\tprimitiveCount,\n\t\tuintptr(unsafe.Pointer(&indexData[0])),\n\t\tFMT_INDEX32,\n\t\tvertexStreamZeroData,\n\t\tvertexStreamZeroStride,\n\t)\n}", "func (s Serializer) indexValue(buf cmpbin.WriteableBytesBuffer, v any) (err error) {\n\tswitch t := v.(type) {\n\tcase nil:\n\tcase bool:\n\t\tb := byte(0)\n\t\tif t {\n\t\t\tb = 1\n\t\t}\n\t\terr = buf.WriteByte(b)\n\tcase int64:\n\t\t_, err = cmpbin.WriteInt(buf, t)\n\tcase float64:\n\t\t_, err = cmpbin.WriteFloat64(buf, t)\n\tcase string:\n\t\t_, err = cmpbin.WriteString(buf, t)\n\tcase []byte:\n\t\t_, err = cmpbin.WriteBytes(buf, t)\n\tcase GeoPoint:\n\t\terr = s.GeoPoint(buf, t)\n\tcase PropertyMap:\n\t\terr = s.PropertyMap(buf, t)\n\tcase *Key:\n\t\terr = s.Key(buf, t)\n\n\tdefault:\n\t\terr = fmt.Errorf(\"unsupported type: %T\", t)\n\t}\n\treturn\n}", "func (Parser) Render(rawBytes []byte, urlPrefix string, metas map[string]string, isWiki bool) []byte {\n\treturn Render(rawBytes, urlPrefix, metas, isWiki)\n}", "func (h *HAProxyManager) render(ports []uint16) ([]byte, error) {\n\n\t// prepare the context\n\td := make([]templateContext, len(ports))\n\tfor i, port := range ports {\n\t\tif i == len(h.serviceAddrs) {\n\t\t\th.logger.Warnf(\"got port index %d, but only have %d service addrs. ports=%v serviceAddrs=%v\", i, len(h.serviceAddrs), ports, h.serviceAddrs)\n\t\t\tcontinue\n\t\t}\n\t\td[i] = templateContext{Port: port, Source: h.listenAddr, Dest: h.serviceAddrs[i]}\n\t}\n\n\t// render the template\n\tbuf := &bytes.Buffer{}\n\tif err := h.template.Execute(buf, d); err != nil {\n\t\treturn nil, err\n\t}\n\treturn buf.Bytes(), nil\n}", "func Index(w http.ResponseWriter, data interface{}) {\n\trender(tpIndex, w, data)\n}", "func (r renderer) Table(out *bytes.Buffer, header []byte, body []byte, columnData []int) {}", "func (sr scoresRenderer) Render() string {\n\tbuffer := bytes.Buffer{}\n\tlast := len(sr.scores) - 1\n\tfor i, score := range sr.scores {\n\t\tbuffer.WriteString(fmt.Sprintf(\"%d\", score))\n\t\tif i != last {\n\t\t\tbuffer.WriteString(\" / \")\n\t\t}\n\t}\n\treturn buffer.String()\n}", "func (f *Font) Index(r rune) uint16 {\n\t// log.Printf(\"r %v\", r)\n\t// log.Printf(\"len %v\", len(f.cmap_entry_array))\n\tcm_len := len(f.cmap_entry_array)\n\n\tx := uint32(r)\n\tfor lo, hi := 0, cm_len; lo < hi; {\n\t\tmi := lo + (hi-lo)/2\n\t\t// log.Printf(\"lo hi mi %v %v %v\", lo, hi, mi)\n\t\tcm := &f.cmap_entry_array[mi]\n\t\t// log.Printf(\"cm %v\", cm)\n\t\tif x < cm.start_code {\n\t\t\thi = mi\n\t\t} else if cm.end_code < x {\n\t\t\tlo = mi + 1\n\t\t} else if cm.id_range_offset == 0 {\n\t\t\t// log.Printf(\"x id_delta %v %v\", x, cm.id_delta)\n\t\t\treturn uint16(x + cm.id_delta)\n\t\t} else {\n\t\t\toffset := int(cm.id_range_offset) + 2*(mi-cm_len+int(x-cm.start_code))\n\t\t\treturn uint16(octets_to_u16(f.cmap_index_array, offset))\n\t\t}\n\t}\n\n\treturn 0\n}", "func Data(w http.ResponseWriter, r *http.Request, v []byte) {\n\trender.Data(w, r, v)\n}", "func ArrayElement(i int32) {\n\tC.glowArrayElement(gpArrayElement, (C.GLint)(i))\n}", "func (e *rawData) Render(w io.Writer) (int, error) { return w.Write([]byte(e.content)) }", "func Interpret(data []byte, offset int) []byte {\n\tb:=make([]byte, len(data) * 2)\n\n\tfor i:=0; i<len(data); i++ {\n\t\tb[offset + i * 2] = hex_ascii[ (data[i] & 0XF0) >> 4]\n\t\tb[offset + i * 2 + 1] = hex_ascii[data[i] & 0x0F]\n\t}\n\treturn b\n}", "func (self *Tween) GenerateData() []interface{}{\n\tarray00 := self.Object.Call(\"generateData\")\n\tlength00 := array00.Length()\n\tout00 := make([]interface{}, length00, length00)\n\tfor i00 := 0; i00 < length00; i00++ {\n\t\tout00[i00] = array00.Index(i00)\n\t}\n\treturn out00\n}", "func DrawArrays(mode Enum, first, count int) {\n\tgl.DrawArrays(uint32(mode), int32(first), int32(count))\n}", "func (c *Controller) Data(data []byte) {\n ctx := c.Context()\n r := render.NewData(data)\n\n ctx.PushLog(\"status\", http.StatusOK)\n ctx.SetHeader(\"Content-Type\", r.ContentType())\n ctx.End(r.HttpCode(), r.Content())\n}", "func DrawElements(mode GLenum, count int, typ GLenum, indices interface{}) {\n\tC.glDrawElements(C.GLenum(mode), C.GLsizei(count), C.GLenum(typ),\n\t\tptr(indices))\n}", "func (rf RendererFunc) Render(w io.Writer, v interface{}) error { return rf(w, v) }", "func main() {\n\t//composite literal - create different values of a type\n\t// x := type{values}\n\t//group together values OF THE SAME TYPE\n\tx := []int{4, 5, 7, 8, 42}\n\n\tfmt.Println(x)\n\tfmt.Println(x[0]) //query by index position\n\tfmt.Println(x[1])\n\tfmt.Println(x[2])\n\tfmt.Println(x[3])\n\tfmt.Println(x[4])\n\tfmt.Println(cap(x))\n\n\t//for index and value in the range of x print\n\tfor i, v := range x {\n\t\tfmt.Println(i, v)\n\t}\n}", "func (tofu Tofu) Render(wr io.Writer, name string, obj interface{}) error {\n\tvar m data.Map\n\tif obj != nil {\n\t\tvar ok bool\n\t\tm, ok = data.New(obj).(data.Map)\n\t\tif !ok {\n\t\t\treturn fmt.Errorf(\"invalid data type. expected map/struct, got %T\", obj)\n\t\t}\n\t}\n\treturn tofu.NewRenderer(name).Execute(wr, m)\n}", "func ShowIndex() {\n\tfmt.Printf(\"%v\\n\", indexText)\n}", "func (debugging *debuggingOpenGL) DrawElements(mode uint32, count int32, elementType uint32, indices uintptr) {\n\tdebugging.recordEntry(\"DrawElements\", mode, count, elementType, indices)\n\tdebugging.gl.DrawElements(mode, count, elementType, indices)\n\tdebugging.recordExit(\"DrawElements\")\n}", "func (self *SinglePad) Index() int{\n return self.Object.Get(\"index\").Int()\n}", "func (a *Array) Literal() {}", "func (cont *tuiApplicationController) drawView() {\n\tcont.Sync.Lock()\n\tif !cont.Changed || cont.TuiFileReaderWorker == nil {\n\t\tcont.Sync.Unlock()\n\t\treturn\n\t}\n\tcont.Sync.Unlock()\n\n\t// reset the elements by clearing out every one\n\ttviewApplication.QueueUpdateDraw(func() {\n\t\tfor _, t := range displayResults {\n\t\t\tt.Title.SetText(\"\")\n\t\t\tt.Body.SetText(\"\")\n\t\t\tt.SpacerOne.SetText(\"\")\n\t\t\tt.SpacerTwo.SetText(\"\")\n\t\t\tresultsFlex.ResizeItem(t.Body, 0, 0)\n\t\t}\n\t})\n\n\tcont.Sync.Lock()\n\tresultsCopy := make([]*FileJob, len(cont.Results))\n\tcopy(resultsCopy, cont.Results)\n\tcont.Sync.Unlock()\n\n\t// rank all results\n\t// then go and get the relevant portion for display\n\trankResults(int(cont.TuiFileReaderWorker.GetFileCount()), resultsCopy)\n\tdocumentTermFrequency := calculateDocumentTermFrequency(resultsCopy)\n\n\t// after ranking only get the details for as many as we actually need to\n\t// cut down on processing\n\tif len(resultsCopy) > len(displayResults) {\n\t\tresultsCopy = resultsCopy[:len(displayResults)]\n\t}\n\n\t// We use this to swap out the highlights after we escape to ensure that we don't escape\n\t// out own colours\n\tmd5Digest := md5.New()\n\tfmtBegin := hex.EncodeToString(md5Digest.Sum([]byte(fmt.Sprintf(\"begin_%d\", makeTimestampNano()))))\n\tfmtEnd := hex.EncodeToString(md5Digest.Sum([]byte(fmt.Sprintf(\"end_%d\", makeTimestampNano()))))\n\n\t// go and get the codeResults the user wants to see using selected as the offset to display from\n\tvar codeResults []codeResult\n\tfor i, res := range resultsCopy {\n\t\tif i >= cont.Offset {\n\t\t\tsnippets := extractRelevantV3(res, documentTermFrequency, int(SnippetLength), \"…\")[0]\n\n\t\t\t// now that we have the relevant portion we need to get just the bits related to highlight it correctly\n\t\t\t// which this method does. It takes in the snippet, we extract and all of the locations and then returns just\n\t\t\tl := getLocated(res, snippets)\n\t\t\tcoloredContent := str.HighlightString(snippets.Content, l, fmtBegin, fmtEnd)\n\t\t\tcoloredContent = tview.Escape(coloredContent)\n\n\t\t\tcoloredContent = strings.Replace(coloredContent, fmtBegin, \"[red]\", -1)\n\t\t\tcoloredContent = strings.Replace(coloredContent, fmtEnd, \"[white]\", -1)\n\n\t\t\tcodeResults = append(codeResults, codeResult{\n\t\t\t\tTitle: res.Location,\n\t\t\t\tContent: coloredContent,\n\t\t\t\tScore: res.Score,\n\t\t\t\tLocation: res.Location,\n\t\t\t})\n\t\t}\n\t}\n\n\t// render out what the user wants to see based on the results that have been chosen\n\ttviewApplication.QueueUpdateDraw(func() {\n\t\tfor i, t := range codeResults {\n\t\t\tdisplayResults[i].Title.SetText(fmt.Sprintf(\"[fuchsia]%s (%f)[-:-:-]\", t.Title, t.Score))\n\t\t\tdisplayResults[i].Body.SetText(t.Content)\n\t\t\tdisplayResults[i].Location = t.Location\n\n\t\t\t//we need to update the item so that it displays everything we have put in\n\t\t\tresultsFlex.ResizeItem(displayResults[i].Body, len(strings.Split(t.Content, \"\\n\")), 0)\n\t\t}\n\t})\n\n\t// we can only set that nothing\n\tcont.Changed = false\n}", "func (vao *VAO) RenderInstanced(instancecount int32) {\n\tgl.BindVertexArray(vao.handle)\n\tif vao.indexBuffer != nil {\n\t\tgl.BindBuffer(gl.ELEMENT_ARRAY_BUFFER, vao.indexBuffer.GetHandle())\n\t\tgl.DrawElementsInstanced(vao.mode, vao.indexBuffer.Len(), gl.UNSIGNED_SHORT, nil, instancecount)\n\t\tgl.BindBuffer(gl.ELEMENT_ARRAY_BUFFER, 0)\n\t} else {\n\t\tgl.DrawArraysInstanced(vao.mode, 0, vao.vertexBuffers[0].Len(), instancecount)\n\t}\n\tgl.BindVertexArray(0)\n}", "func DrawRangeElements(mode uint32, start uint32, end uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n C.glowDrawRangeElements(gpDrawRangeElements, (C.GLenum)(mode), (C.GLuint)(start), (C.GLuint)(end), (C.GLsizei)(count), (C.GLenum)(xtype), indices)\n}", "func (c *cartridge) Render() {\n\tc.Cls()\n\tc.PrintAt(fmt.Sprintf(\"counter:%d\", c.counter), c.x, c.y)\n}", "func (i *IndexedData) Assemble() error {\n\n\ti.values = i.ValuesBuffer.Bytes()\n\ti.ValuesBuffer = bytes.Buffer{}\n\n\treturn i.assembleBlockReferences()\n}", "func Index(w http.ResponseWriter, data *IndexData) {\n\trender(tpIndex, w, data)\n}", "func Index(w http.ResponseWriter, data *IndexData) {\n\trender(tpIndex, w, data)\n}", "func (e *expression) printArray() string {\n\ta := \"\"\n\n\tfor i := 0; i < len(e.lenArray); i++ {\n\t\tvArray := string('i' + i)\n\t\ta += fmt.Sprintf(\"[%s]\", vArray)\n\t}\n\treturn a\n}", "func (self *Graphics) _renderWebGLI(args ...interface{}) {\n self.Object.Call(\"_renderWebGL\", args)\n}", "func (l LogItems) Render(showTime bool, ll [][]byte) {\n\tcolors := make(map[string]int, len(l))\n\tfor i, item := range l {\n\t\tinfo := item.ID()\n\t\tcolor, ok := colors[info]\n\t\tif !ok {\n\t\t\tcolor = colorFor(info)\n\t\t\tcolors[info] = color\n\t\t}\n\t\tll[i] = item.Render(color, showTime)\n\t}\n}", "func PrintDataSlice(data interface{}) {\n\td := reflect.ValueOf(data)\n\n\tfor i := 0; i < d.Len(); i++ {\n\t\tdataItem := d.Index(i)\n\t\ttypeOfT := dataItem.Type()\n\n\t\tfor j := 0; j < dataItem.NumField(); j++ {\n\t\t\tf := dataItem.Field(j)\n\t\t\tfmt.Printf(\"%s: %v\\n\", typeOfT.Field(j).Name, f.Interface())\n\t\t}\n\t\tfmt.Printf(\"\\n\")\n\t}\n}", "func DrawElementsInstancedBaseVertex(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32, basevertex int32) {\n C.glowDrawElementsInstancedBaseVertex(gpDrawElementsInstancedBaseVertex, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLsizei)(instancecount), (C.GLint)(basevertex))\n}", "func iterateScalars1DWithIndexes() {\n\tfmt.Println(\"*** iterateScalars1DWithIndexes\")\n\n\tints := make([]int, 5)\n\tints[0] = 1\n\tints[1] = 2\n\tints[2] = 3\n\tints[3] = 4\n\tints[4] = 5\n\n\tfor i := 0; i < len(ints); i++ {\n\t\tfmt.Printf(\"i: %d\\n\", i)\n\t}\n\tfmt.Println(\"\")\n}", "func ScissorIndexed(index uint32, left int32, bottom int32, width int32, height int32) {\n\tC.glowScissorIndexed(gpScissorIndexed, (C.GLuint)(index), (C.GLint)(left), (C.GLint)(bottom), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func ScissorIndexed(index uint32, left int32, bottom int32, width int32, height int32) {\n\tC.glowScissorIndexed(gpScissorIndexed, (C.GLuint)(index), (C.GLint)(left), (C.GLint)(bottom), (C.GLsizei)(width), (C.GLsizei)(height))\n}", "func TemplateData(p string, data interface{}) {\n}", "func (script Script) RenderHTML() {\n\tsymbols := []string{}\n\ttemplateHTML := `\n<!DOCTYPE html>\n<html>\n <head>\n <title>Writing System</title>\n <style type=\"text/css\">\n body, html { font-size: 28px; }\n div.container { display: flex; flex-wrap: wrap; width: 1600px; margin: 1rem auto; }\n div.cell { width: 100px; height: 100px; margin: 1rem; text-align: center; font-weight: 700; }\n div.cell > img { display: block; }\n </style>\n </head>\n <body>\n\t\t<div class=\"container\">\n\t\t\t{{range $index, $element := .}}\n <div class=\"cell\">\n <img src=\"{{ $element }}.png\">\n <p>{{ $element }}</p>\n </div>\n {{end}}\n </div>\n </body>\n</html>\n`\n\n\twriter, err := os.Create(\"./output/index.html\")\n\tif err != nil {\n\t\tfmt.Println(err)\n\t\treturn\n\t}\n\n\tt, err := template.New(\"htmlIndex\").Parse(templateHTML)\n\tif err != nil {\n\t\tfmt.Println(err)\n\t\treturn\n\t}\n\n\tfor _, g := range script.Glyphs {\n\t\tsymbols = append(symbols, g.Representation)\n\t}\n\n\terr = t.Execute(writer, symbols)\n\tif err != nil {\n\t\tfmt.Println(err)\n\t\treturn\n\t}\n\n\tdefer writer.Close()\n}", "func serialize(data interface{}) interface{} {\n\tvar buffer bytes.Buffer\n\tswitch reflect.TypeOf(data).Kind() {\n\tcase reflect.Slice:\n\t\ts := reflect.ValueOf(data)\n\t\tfor i := 0; i < s.Len(); i++ {\n\t\t\tserial := serialize(s.Index(i).Interface())\n\t\t\tif reflect.TypeOf(serial).Kind() == reflect.Float64 {\n\t\t\t\tserial = strconv.Itoa(int(serial.(float64)))\n\t\t\t}\n\t\t\tbuffer.WriteString(strconv.Itoa(i))\n\t\t\tbuffer.WriteString(serial.(string))\n\t\t}\n\t\treturn buffer.String()\n\tcase reflect.Map:\n\t\ts := reflect.ValueOf(data)\n\t\tkeys := s.MapKeys()\n\t\t//ksort\n\t\tvar sortedKeys []string\n\t\tfor _, key := range keys {\n\t\t\tsortedKeys = append(sortedKeys, key.Interface().(string))\n\t\t}\n\t\tsort.Strings(sortedKeys)\n\t\tfor _, key := range sortedKeys {\n\t\t\tserial := serialize(s.MapIndex(reflect.ValueOf(key)).Interface())\n\t\t\tif reflect.TypeOf(serial).Kind() == reflect.Float64 {\n\t\t\t\tserial = strconv.Itoa(int(serial.(float64)))\n\t\t\t}\n\t\t\tbuffer.WriteString(key)\n\t\t\tbuffer.WriteString(serial.(string))\n\t\t}\n\t\treturn buffer.String()\n\t}\n\n\treturn data\n}", "func (t *textRender) Render(w io.Writer) (err error) {\n\tif len(t.Values) > 0 {\n\t\t_, err = fmt.Fprintf(w, t.Format, t.Values...)\n\t} else {\n\t\t_, err = io.WriteString(w, t.Format)\n\t}\n\treturn\n}", "func DrawRangeElements(mode uint32, start uint32, end uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n\tsyscall.Syscall6(gpDrawRangeElements, 6, uintptr(mode), uintptr(start), uintptr(end), uintptr(count), uintptr(xtype), uintptr(indices))\n}", "func (gl *WebGL) DrawElements(mode GLEnum, count int, valueType GLEnum, offset int) {\n\tgl.context.Call(\"drawElements\", mode, count, valueType, offset)\n}", "func (self *TileSprite) _renderWebGLI(args ...interface{}) {\n self.Object.Call(\"_renderWebGL\", args)\n}", "func (node IndexHints) formatFast(buf *TrackedBuffer) {\n\tfor _, n := range node {\n\t\tn.formatFast(buf)\n\t}\n}", "func RenderIssueIndexPattern(rawBytes []byte, urlPrefix string, metas map[string]string) []byte {\n\turlPrefix = cutoutVerbosePrefix(urlPrefix)\n\n\tpattern := IssueNumericPattern\n\tif metas[\"style\"] == IssueNameStyleAlphanumeric {\n\t\tpattern = IssueAlphanumericPattern\n\t}\n\n\tms := pattern.FindAll(rawBytes, -1)\n\tfor _, m := range ms {\n\t\tif m[0] == ' ' || m[0] == '(' || m[0] == '[' {\n\t\t\t// ignore leading space, opening parentheses, or opening square brackets\n\t\t\tm = m[1:]\n\t\t}\n\t\tvar link string\n\t\tif metas == nil || metas[\"format\"] == \"\" {\n\t\t\tlink = fmt.Sprintf(`<a href=\"%s/issues/%s\">%s</a>`, urlPrefix, m[1:], m)\n\t\t} else {\n\t\t\t// Support for external issue tracker\n\t\t\tif metas[\"style\"] == IssueNameStyleAlphanumeric {\n\t\t\t\tmetas[\"index\"] = string(m)\n\t\t\t} else {\n\t\t\t\tmetas[\"index\"] = string(m[1:])\n\t\t\t}\n\t\t\tlink = fmt.Sprintf(`<a href=\"%s\">%s</a>`, com.Expand(metas[\"format\"], metas), m)\n\t\t}\n\t\trawBytes = bytes.Replace(rawBytes, m, []byte(link), 1)\n\t}\n\treturn rawBytes\n}", "func (r *Renderer) Render() {\n\tgl.DrawArrays(gl.TRIANGLES, 0, int32(len(r.RawRenderer)*4))\n}", "func (native *OpenGL) DrawElementsOffset(mode uint32, count int32, elementType uint32, offset int) {\n\tgl.DrawElements(mode, count, elementType, gl.PtrOffset(offset))\n}", "func DrawElements(mode Enum, count int, ty Enum, offset int) {\n\tgl.DrawElements(uint32(mode), int32(count), uint32(ty), gl.PtrOffset(offset))\n}", "func (renderer *SimpleMatrixRenderer) Render() {\n\trenderer.renderCharacter(\"\\n\")\n\n\tfor row := 0; row < renderer.Matrix.Height; row++ {\n\t\tfor col := 0; col < renderer.Matrix.Width; col++ {\n\t\t\tif !renderer.Matrix.IsFieldOccupied(row, col) {\n\t\t\t\trenderer.renderUnoccupiedField()\n\t\t\t} else {\n\t\t\t\trenderer.renderOccupiedFieldAtCurrentCursorPos(row, col)\n\t\t\t}\n\t\t}\n\n\t\trenderer.renderCharacter(\"\\n\")\n\t}\n\n\trenderer.renderCharacter(\"\\n\")\n}", "func PrimitiveRestartIndex(index uint32) {\n C.glowPrimitiveRestartIndex(gpPrimitiveRestartIndex, (C.GLuint)(index))\n}", "func (native *OpenGL) DrawArrays(mode uint32, first int32, count int32) {\n\tgl.DrawArrays(mode, first, count)\n}", "func DrawElementsBaseVertex(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, basevertex int32) {\n C.glowDrawElementsBaseVertex(gpDrawElementsBaseVertex, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLint)(basevertex))\n}", "func (cdd *CDD) indexExpr(w *bytes.Buffer, typ types.Type, xs string, idx ast.Expr, ids string) {\n\tpt, isPtr := typ.(*types.Pointer)\n\tif isPtr {\n\t\ttyp = pt.Elem()\n\t}\n\tvar indT types.Type\n\n\tswitch t := typ.Underlying().(type) {\n\tcase *types.Basic: // string\n\t\tif cdd.gtc.boundsCheck && idx != nil {\n\t\t\tw.WriteString(\"STRIDXC(\")\n\t\t} else {\n\t\t\tw.WriteString(\"STRIDX(\")\n\t\t}\n\tcase *types.Slice:\n\t\tif cdd.gtc.boundsCheck && idx != nil {\n\t\t\tw.WriteString(\"SLIDXC(\")\n\t\t} else {\n\t\t\tw.WriteString(\"SLIDX(\")\n\t\t}\n\t\tdim := cdd.Type(w, t.Elem())\n\t\tdim = append([]string{\"*\"}, dim...)\n\t\tw.WriteString(dimFuncPtr(\"\", dim))\n\t\tw.WriteString(\", \")\n\tcase *types.Array:\n\t\tif cdd.gtc.boundsCheck && idx != nil &&\n\t\t\t!cdd.isConstExpr(idx, types.Typ[types.UntypedInt]) {\n\t\t\tw.WriteString(\"AIDXC(\")\n\t\t} else {\n\t\t\tw.WriteString(\"AIDX(\")\n\t\t}\n\t\tif !isPtr {\n\t\t\tw.WriteByte('&')\n\t\t}\n\tcase *types.Map:\n\t\tindT = t.Key()\n\t\tcdd.notImplemented(&ast.IndexExpr{}, t)\n\tdefault:\n\t\tpanic(t)\n\t}\n\tw.WriteString(xs)\n\tw.WriteString(\", \")\n\tif idx != nil {\n\t\tcdd.Expr(w, idx, indT, true)\n\t} else {\n\t\tw.WriteString(ids)\n\t}\n\tw.WriteByte(')')\n}", "func (n *windowNode) IndexedVarFormat(buf *bytes.Buffer, f parser.FmtFlags, idx int) {\n\tn.ivarSourceInfo[0].FormatVar(buf, f, idx)\n}", "func DrawArrays(mode uint32, first int32, count int32) {\n\tsyscall.Syscall(gpDrawArrays, 3, uintptr(mode), uintptr(first), uintptr(count))\n}", "func renderTemplateBytes(name string, data interface{}) ([]byte, error) {\n\tvar buf bytes.Buffer\n\tif err := Tmpl.Render(&buf, name, data); err != nil {\n\t\treturn nil, err\n\t}\n\treturn buf.Bytes(), nil\n}", "func renderTemplateBytes(name string, data interface{}) ([]byte, error) {\n\tvar buf bytes.Buffer\n\tif err := Tmpl.Render(&buf, name, data); err != nil {\n\t\treturn nil, err\n\t}\n\treturn buf.Bytes(), nil\n}", "func MultiDrawElements(mode uint32, count *int32, xtype uint32, indices *unsafe.Pointer, drawcount int32) {\n\tsyscall.Syscall6(gpMultiDrawElements, 5, uintptr(mode), uintptr(unsafe.Pointer(count)), uintptr(xtype), uintptr(unsafe.Pointer(indices)), uintptr(drawcount), 0)\n}", "func (node *IndexHints) Format(buf *TrackedBuffer) {\n\tbuf.astPrintf(node, \" %sindex \", node.Type.ToString())\n\tif len(node.Indexes) == 0 {\n\t\tbuf.astPrintf(node, \"()\")\n\t} else {\n\t\tprefix := \"(\"\n\t\tfor _, n := range node.Indexes {\n\t\t\tbuf.astPrintf(node, \"%s%v\", prefix, n)\n\t\t\tprefix = \", \"\n\t\t}\n\t\tbuf.astPrintf(node, \")\")\n\t}\n}", "func (isf intSliceFunctorImpl) String() string {\n\treturn fmt.Sprintf(\"%#v\", isf.ints)\n}", "func output3d(values []int) {\n\tfor _, v := range values {\n\t\tfmt.Printf(\"%03d \",v)\n\t}\n\tfmt.Println()\n}", "func Render(files [][]byte, maxIt uint, debug bool) (\n\t[]byte, error,\n) {\n\tinfl, debugParse, err := parseFiles(files)\n\tif err != nil {\n\t\tif debug {\n\t\t\twriteDebug(\"parsing\", debugParse)\n\t\t}\n\t\treturn []byte{}, err\n\t}\n\tres, debugRender, err := renderTmpl(infl, maxIt)\n\tif err != nil {\n\t\tif debug {\n\t\t\twriteDebug(\"render\", debugRender)\n\t\t}\n\t\treturn []byte{}, err\n\t}\n\treturn res, nil\n}", "func generateIndex(textsNumber int, wordsNumber int) *Index {\n\ttitles := make([]string, textsNumber)\n\tentries := make(map[string]Set)\n\tfor i := 0; i < textsNumber; i++ {\n\t\ttitles[i] = fmt.Sprintf(\"title-with-number-%d\", i)\n\t}\n\tfor i := 0; i < wordsNumber; i++ {\n\t\tset := Set{}\n\t\tfor j := 0; j < textsNumber; j++ {\n\t\t\tset.Put(j)\n\t\t}\n\t\tentries[fmt.Sprintf(\"w%d\", i)] = set\n\t}\n\treturn &Index{\n\t\tTitles: titles,\n\t\tData: entries,\n\t}\n}", "func DrawArrays(mode uint32, first int32, count int32) {\n C.glowDrawArrays(gpDrawArrays, (C.GLenum)(mode), (C.GLint)(first), (C.GLsizei)(count))\n}", "func myVisualiseMatrix(world [][]byte, ImageWidth, ImageHeight int) {\n\tfor i := 0; i < ImageHeight; i++ {\n\t\tfor j := 0; j < ImageWidth; j++ {\n\t\t\tfmt.Print(world[i][j])\n\t\t}\n\t\tfmt.Println()\n\t}\n}", "func (c *Client) ShowArrayPrism(ctx context.Context, path string, anyArray []interface{}, boolArray []bool, dateTimeArray []time.Time, intArray []int, numArray []float64, stringArray []string, uuidArray []uuid.UUID) (*http.Response, error) {\n\treq, err := c.NewShowArrayPrismRequest(ctx, path, anyArray, boolArray, dateTimeArray, intArray, numArray, stringArray, uuidArray)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\treturn c.Client.Do(ctx, req)\n}", "func DrawElements(mode uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n\tC.glowDrawElements(gpDrawElements, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices)\n}", "func DrawElements(mode uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n\tC.glowDrawElements(gpDrawElements, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices)\n}", "func (va *VertexArray) SetIndexData(data []uint32) {\n\t// Index Buffer Object\n\tgl.GenBuffers(1, &va.ibo) // generates the buffer (or multiple)\n\tgl.BindBuffer(gl.ELEMENT_ARRAY_BUFFER, va.ibo) // tells OpenGL what kind of buffer this is\n\n\t// BufferData assigns data to the buffer.\n\tgl.BufferData(gl.ELEMENT_ARRAY_BUFFER, len(data)*4, gl.Ptr(data), gl.STATIC_DRAW)\n\n\tva.vertices = len(data)\n}", "func (f *fast) RenderKeypoints() *image.RGBA {\n kpcolor := color.RGBA{0,255,0,255}\n img := ConvertToColor(f.image)\n for i := 0; i < len(f.keypoints); i++ {\n point := f.keypoints[i].point\n img.Set(point.X, point.Y, kpcolor)\n }\n return img\n}", "func (gui *Gui) render(\n\tv *gocui.View,\n\tviewName string,\n\tcolumns []string,\n\tresultSet [][]string,\n) error {\n\tv.Rewind()\n\n\tov, err := gui.g.View(viewName)\n\tif err != nil {\n\t\treturn err\n\t}\n\n\t// Cleans the view.\n\tov.Clear()\n\n\tif err := ov.SetCursor(0, 0); err != nil {\n\t\treturn err\n\t}\n\n\trenderTable(ov, columns, resultSet)\n\n\treturn nil\n}", "func (a *Array) Format(f fmt.State, c rune) {\n\tswitch c {\n\tcase 'z': // Private format specifier, supports Entity.Signature\n\t\tfmt.Fprintf(f, \"[%d]%z\", a.Size, a.ValueType)\n\tcase 'r': // Private format specifier, supports Type.Representation\n\t\tfmt.Fprintf(f, \"[%d]%r\", a.Size, a.ValueType)\n\tdefault:\n\t\tif a.Alias != \"\" {\n\t\t\tfmt.Fprint(f, a.Alias)\n\t\t} else {\n\t\t\tfmt.Fprintf(f, \"[%d]%v\", a.Size, a.ValueType)\n\t\t}\n\t}\n}", "func (x *Index) Bytes() []byte {}", "func DrawElementsInstanced(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32) {\n C.glowDrawElementsInstanced(gpDrawElementsInstanced, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLsizei)(instancecount))\n}", "func (debugging *debuggingOpenGL) DrawArrays(mode uint32, first int32, count int32) {\n\tdebugging.recordEntry(\"DrawArrays\", first, count)\n\tdebugging.gl.DrawArrays(mode, first, count)\n\tdebugging.recordExit(\"DrawArrays\")\n}", "func (c *compiler) index(index []ast.Expr) {\n\tfor _, expr := range index {\n\t\tif e, ok := expr.(*ast.NumExpr); ok && e.Value == float64(int(e.Value)) {\n\t\t\t// If index expression is integer constant, optimize to string \"n\"\n\t\t\t// to avoid toString() at runtime.\n\t\t\ts := strconv.Itoa(int(e.Value))\n\t\t\tc.expr(&ast.StrExpr{Value: s})\n\t\t\tcontinue\n\t\t}\n\t\tc.expr(expr)\n\t}\n\tif len(index) > 1 {\n\t\tc.add(IndexMulti, opcodeInt(len(index)))\n\t}\n}", "func (node VindexParam) formatFast(buf *TrackedBuffer) {\n\tbuf.WriteString(node.Key.String())\n\tbuf.WriteByte('=')\n\tbuf.WriteString(node.Val)\n}", "func DrawArraysInstanced(mode uint32, first int32, count int32, instancecount int32) {\n C.glowDrawArraysInstanced(gpDrawArraysInstanced, (C.GLenum)(mode), (C.GLint)(first), (C.GLsizei)(count), (C.GLsizei)(instancecount))\n}", "func (node *IndexHint) formatFast(buf *TrackedBuffer) {\n\tbuf.WriteByte(' ')\n\tbuf.WriteString(node.Type.ToString())\n\tbuf.WriteString(\"index \")\n\tif node.ForType != NoForType {\n\t\tbuf.WriteString(\"for \")\n\t\tbuf.WriteString(node.ForType.ToString())\n\t\tbuf.WriteByte(' ')\n\t}\n\tif len(node.Indexes) == 0 {\n\t\tbuf.WriteString(\"()\")\n\t} else {\n\t\tprefix := \"(\"\n\t\tfor _, n := range node.Indexes {\n\t\t\tbuf.WriteString(prefix)\n\t\t\tn.formatFast(buf)\n\t\t\tprefix = \", \"\n\t\t}\n\t\tbuf.WriteByte(')')\n\t}\n}", "func MultiDrawElements(mode uint32, count *int32, xtype uint32, indices *unsafe.Pointer, drawcount int32) {\n C.glowMultiDrawElements(gpMultiDrawElements, (C.GLenum)(mode), (*C.GLsizei)(unsafe.Pointer(count)), (C.GLenum)(xtype), indices, (C.GLsizei)(drawcount))\n}", "func (c *ConnectionSPI) Render(pixels []RGBPixel) {\r\n\tlogFields := log.Fields{\"package\": logPkg, \"conn\": \"SPI\", \"func\": \"RenderLEDs\"}\r\n\tlog.WithFields(logFields).Infof(\"Render %d LEDs\", len(pixels))\r\n\t// Fix for Raspberry Pi 3 Model B+ (5.15.84-v7+)\r\n\t// Data signal seems to be splitted sending less than 11 LEDS\r\n\tif len(pixels) < 11 {\r\n\t\tpixels = append(pixels, []RGBPixel{{}, {}, {}, {}, {}, {}, {}, {}, {}, {}}...)\r\n\t}\r\n\tvar translatedRGBs []uint8\r\n\tfor _, pixel := range pixels {\r\n\r\n\t\tcolorData := GetColorData(pixel, c.FixSPI)\r\n\t\tlog.WithFields(logFields).Tracef(\"%08b\", pixel)\r\n\r\n\t\tfor _, c := range colorData {\r\n\t\t\ttranslatedRGBs = append(translatedRGBs, c)\r\n\t\t}\r\n\t}\r\n\r\n\tc.transfer(translatedRGBs)\r\n}" ]
[ "0.58143914", "0.5476799", "0.5437336", "0.5236039", "0.5156183", "0.50605226", "0.5040222", "0.5035074", "0.49717593", "0.49628866", "0.49624538", "0.49329838", "0.49272525", "0.49233818", "0.4923174", "0.4923174", "0.4904283", "0.48979342", "0.48739874", "0.48523787", "0.48398814", "0.4805674", "0.47859782", "0.4783094", "0.4778812", "0.4775266", "0.47490218", "0.47274727", "0.4713691", "0.47060537", "0.46969548", "0.46833208", "0.466524", "0.4658205", "0.46546263", "0.46511036", "0.46433824", "0.4640777", "0.46263054", "0.46259326", "0.46256015", "0.4618436", "0.46145397", "0.45805895", "0.4568701", "0.45623192", "0.4555184", "0.4555184", "0.45503843", "0.45466256", "0.45382157", "0.45355555", "0.45297322", "0.4526886", "0.45222157", "0.45222157", "0.4513744", "0.45104167", "0.45103434", "0.45010662", "0.45009324", "0.44997028", "0.44970936", "0.44895732", "0.44883415", "0.44860232", "0.4484397", "0.4481075", "0.44799632", "0.4477188", "0.4474834", "0.44740415", "0.4470215", "0.44656307", "0.44649026", "0.44561535", "0.44561535", "0.44544357", "0.44533616", "0.4450315", "0.444613", "0.44333848", "0.4429687", "0.442605", "0.44254237", "0.44235113", "0.4423466", "0.4423466", "0.44206858", "0.44161853", "0.44083008", "0.44045115", "0.43981603", "0.43976563", "0.4395573", "0.439254", "0.43904945", "0.43834272", "0.4378743", "0.4372906", "0.4367312" ]
0.0
-1
draw multiple instances of a set of elements
func DrawElementsInstanced(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32) { C.glowDrawElementsInstanced(gpDrawElementsInstanced, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLsizei)(instancecount)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func MultiDrawElements(mode uint32, count *int32, xtype uint32, indices *unsafe.Pointer, drawcount int32) {\n\tsyscall.Syscall6(gpMultiDrawElements, 5, uintptr(mode), uintptr(unsafe.Pointer(count)), uintptr(xtype), uintptr(unsafe.Pointer(indices)), uintptr(drawcount), 0)\n}", "func DrawElements(mode uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n\tsyscall.Syscall6(gpDrawElements, 4, uintptr(mode), uintptr(count), uintptr(xtype), uintptr(indices), 0, 0)\n}", "func DrawElementsInstanced(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32) {\n C.glowDrawElementsInstanced(gpDrawElementsInstanced, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLsizei)(instancecount))\n}", "func MultiDrawElements(mode uint32, count *int32, xtype uint32, indices *unsafe.Pointer, drawcount int32) {\n C.glowMultiDrawElements(gpMultiDrawElements, (C.GLenum)(mode), (*C.GLsizei)(unsafe.Pointer(count)), (C.GLenum)(xtype), indices, (C.GLsizei)(drawcount))\n}", "func DrawElements(mode Enum, count int, ty Enum, offset int) {\n\tgl.DrawElements(uint32(mode), int32(count), uint32(ty), gl.PtrOffset(offset))\n}", "func DrawElements(mode uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n C.glowDrawElements(gpDrawElements, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices)\n}", "func MultiDrawElements(mode uint32, count *int32, xtype uint32, indices *unsafe.Pointer, drawcount int32) {\n\tC.glowMultiDrawElements(gpMultiDrawElements, (C.GLenum)(mode), (*C.GLsizei)(unsafe.Pointer(count)), (C.GLenum)(xtype), indices, (C.GLsizei)(drawcount))\n}", "func MultiDrawElements(mode uint32, count *int32, xtype uint32, indices *unsafe.Pointer, drawcount int32) {\n\tC.glowMultiDrawElements(gpMultiDrawElements, (C.GLenum)(mode), (*C.GLsizei)(unsafe.Pointer(count)), (C.GLenum)(xtype), indices, (C.GLsizei)(drawcount))\n}", "func (c *Canvas) printElements() {\n\tfor _, es := range c.elements {\n\t\tc.Println(\"<g>\")\n\t\tfor _, e := range es {\n\t\t\tc.Println(e.Usebg())\n\t\t}\n\t\tfor _, e := range es {\n\t\t\tc.Println(e.Use())\n\t\t}\n\t\tc.Println(\"</g>\")\n\t}\n}", "func DrawElements(mode uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n\tC.glowDrawElements(gpDrawElements, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices)\n}", "func DrawElements(mode uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n\tC.glowDrawElements(gpDrawElements, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices)\n}", "func DrawRangeElements(mode uint32, start uint32, end uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n\tsyscall.Syscall6(gpDrawRangeElements, 6, uintptr(mode), uintptr(start), uintptr(end), uintptr(count), uintptr(xtype), uintptr(indices))\n}", "func draw(window *sdl.Window, renderer *sdl.Renderer, grid [][]*square) {\n\trenderer.Clear()\n\trenderer.SetDrawColor(255, 255, 255, 1) // white\n\trenderer.FillRect(&sdl.Rect{0, 0, size, size})\n\n\tfor _, row := range grid {\n\t\tfor _, square := range row {\n\t\t\tsquare.drawSquare(renderer)\n\t\t}\n\t}\n\n\tdrawGrid(renderer)\n\trenderer.Present()\n}", "func DrawRangeElements(mode uint32, start uint32, end uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n C.glowDrawRangeElements(gpDrawRangeElements, (C.GLenum)(mode), (C.GLuint)(start), (C.GLuint)(end), (C.GLsizei)(count), (C.GLenum)(xtype), indices)\n}", "func (debugging *debuggingOpenGL) DrawElements(mode uint32, count int32, elementType uint32, indices uintptr) {\n\tdebugging.recordEntry(\"DrawElements\", mode, count, elementType, indices)\n\tdebugging.gl.DrawElements(mode, count, elementType, indices)\n\tdebugging.recordExit(\"DrawElements\")\n}", "func DrawN(count int, opts ...options) (result []string, err error) {\n\tif count <= 0 {\n\t\tcount = 1\n\t}\n\n\tfor i := 0; i < count; i++ {\n\t\toutput, err := Draw(opts...)\n\t\tif err != nil {\n\t\t\treturn nil, err\n\t\t}\n\t\tresult = append(result, output)\n\t}\n\n\treturn\n}", "func DrawElementsInstancedBaseVertex(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32, basevertex int32) {\n\tsyscall.Syscall6(gpDrawElementsInstancedBaseVertex, 6, uintptr(mode), uintptr(count), uintptr(xtype), uintptr(indices), uintptr(instancecount), uintptr(basevertex))\n}", "func DrawRangeElements(mode uint32, start uint32, end uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n\tC.glowDrawRangeElements(gpDrawRangeElements, (C.GLenum)(mode), (C.GLuint)(start), (C.GLuint)(end), (C.GLsizei)(count), (C.GLenum)(xtype), indices)\n}", "func DrawRangeElements(mode uint32, start uint32, end uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n\tC.glowDrawRangeElements(gpDrawRangeElements, (C.GLenum)(mode), (C.GLuint)(start), (C.GLuint)(end), (C.GLsizei)(count), (C.GLenum)(xtype), indices)\n}", "func (native *OpenGL) DrawElements(mode uint32, count int32, elementType uint32, indices uintptr) {\n\tgl.DrawElements(mode, count, elementType, unsafe.Pointer(indices)) // nolint: govet,gas\n}", "func DrawElements(mode GLenum, count int, typ GLenum, indices interface{}) {\n\tC.glDrawElements(C.GLenum(mode), C.GLsizei(count), C.GLenum(typ),\n\t\tptr(indices))\n}", "func DrawElementsInstancedBaseVertex(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32, basevertex int32) {\n C.glowDrawElementsInstancedBaseVertex(gpDrawElementsInstancedBaseVertex, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLsizei)(instancecount), (C.GLint)(basevertex))\n}", "func MultiDrawElementsIndirect(mode uint32, xtype uint32, indirect unsafe.Pointer, drawcount int32, stride int32) {\n\tsyscall.Syscall6(gpMultiDrawElementsIndirect, 5, uintptr(mode), uintptr(xtype), uintptr(indirect), uintptr(drawcount), uintptr(stride), 0)\n}", "func DrawElementsInstancedBaseInstance(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32, baseinstance uint32) {\n C.glowDrawElementsInstancedBaseInstance(gpDrawElementsInstancedBaseInstance, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLsizei)(instancecount), (C.GLuint)(baseinstance))\n}", "func DrawElementsInstancedBaseVertex(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32, basevertex int32) {\n\tC.glowDrawElementsInstancedBaseVertex(gpDrawElementsInstancedBaseVertex, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLsizei)(instancecount), (C.GLint)(basevertex))\n}", "func DrawElementsInstancedBaseVertex(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32, basevertex int32) {\n\tC.glowDrawElementsInstancedBaseVertex(gpDrawElementsInstancedBaseVertex, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLsizei)(instancecount), (C.GLint)(basevertex))\n}", "func (a *aquarium) draw(c termdraw.Canvas) {\n\tfor _, fish := range a.fish {\n\t\ttermdraw.DrawSprite(c, fish.position.Sub(a.canvasOffset), fish.sprite.Current())\n\t}\n}", "func (gl *WebGL) DrawElements(mode GLEnum, count int, valueType GLEnum, offset int) {\n\tgl.context.Call(\"drawElements\", mode, count, valueType, offset)\n}", "func DrawArraysInstanced(mode uint32, first int32, count int32, instancecount int32) {\n C.glowDrawArraysInstanced(gpDrawArraysInstanced, (C.GLenum)(mode), (C.GLint)(first), (C.GLsizei)(count), (C.GLsizei)(instancecount))\n}", "func DrawElementsInstancedBaseInstance(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32, baseinstance uint32) {\n\tsyscall.Syscall6(gpDrawElementsInstancedBaseInstance, 6, uintptr(mode), uintptr(count), uintptr(xtype), uintptr(indices), uintptr(instancecount), uintptr(baseinstance))\n}", "func DrawElementsInstancedBaseInstance(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32, baseinstance uint32) {\n\tC.glowDrawElementsInstancedBaseInstance(gpDrawElementsInstancedBaseInstance, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLsizei)(instancecount), (C.GLuint)(baseinstance))\n}", "func DrawElementsInstancedBaseInstance(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32, baseinstance uint32) {\n\tC.glowDrawElementsInstancedBaseInstance(gpDrawElementsInstancedBaseInstance, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLsizei)(instancecount), (C.GLuint)(baseinstance))\n}", "func MultiDrawElementsIndirect(mode uint32, xtype uint32, indirect unsafe.Pointer, drawcount int32, stride int32) {\n C.glowMultiDrawElementsIndirect(gpMultiDrawElementsIndirect, (C.GLenum)(mode), (C.GLenum)(xtype), indirect, (C.GLsizei)(drawcount), (C.GLsizei)(stride))\n}", "func withDraw(users []*sentinel.UserReq) {\n\tvar done sync.WaitGroup\n\n\tfor _, u := range users {\n\t\tdone.Add(1)\n\t\tgo func(u *sentinel.UserReq) {\n\t\t\tdefer done.Done()\n\n\t\t\tif err := u.WithDraw(); err != nil {\n\t\t\t\tlog.Error(0, \"u.withDraw() returns error %v\", err)\n\t\t\t}\n\t\t}(u)\n\t}\n\n\tdone.Wait()\n}", "func (c *component) drawChildren(mx, my int) {\n\tfor _, child := range c.children {\n\t\tr := child.GetBounds()\n\t\timg := child.Draw(mx, my)\n\t\tif img != nil {\n\t\t\tdraw.Draw(c.Image, r, img, image.ZP, draw.Over)\n\t\t}\n\t}\n}", "func DrawArraysInstanced(mode uint32, first int32, count int32, instancecount int32) {\n\tC.glowDrawArraysInstanced(gpDrawArraysInstanced, (C.GLenum)(mode), (C.GLint)(first), (C.GLsizei)(count), (C.GLsizei)(instancecount))\n}", "func DrawArraysInstanced(mode uint32, first int32, count int32, instancecount int32) {\n\tC.glowDrawArraysInstanced(gpDrawArraysInstanced, (C.GLenum)(mode), (C.GLint)(first), (C.GLsizei)(count), (C.GLsizei)(instancecount))\n}", "func DrawElements(mode Enum, count Sizei, kind Enum, indices unsafe.Pointer) {\n\tcmode, _ := (C.GLenum)(mode), cgoAllocsUnknown\n\tccount, _ := (C.GLsizei)(count), cgoAllocsUnknown\n\tckind, _ := (C.GLenum)(kind), cgoAllocsUnknown\n\tcindices, _ := (unsafe.Pointer)(unsafe.Pointer(indices)), cgoAllocsUnknown\n\tC.glDrawElements(cmode, ccount, ckind, cindices)\n}", "func DrawElementsIndirect(mode uint32, xtype uint32, indirect unsafe.Pointer) {\n\tsyscall.Syscall(gpDrawElementsIndirect, 3, uintptr(mode), uintptr(xtype), uintptr(indirect))\n}", "func DrawElementsInstancedBaseVertexBaseInstance(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32, basevertex int32, baseinstance uint32) {\n\tsyscall.Syscall9(gpDrawElementsInstancedBaseVertexBaseInstance, 7, uintptr(mode), uintptr(count), uintptr(xtype), uintptr(indices), uintptr(instancecount), uintptr(basevertex), uintptr(baseinstance), 0, 0)\n}", "func MultiDrawElementsBaseVertex(mode uint32, count *int32, xtype uint32, indices *unsafe.Pointer, drawcount int32, basevertex *int32) {\n\tsyscall.Syscall6(gpMultiDrawElementsBaseVertex, 6, uintptr(mode), uintptr(unsafe.Pointer(count)), uintptr(xtype), uintptr(unsafe.Pointer(indices)), uintptr(drawcount), uintptr(unsafe.Pointer(basevertex)))\n}", "func DrawElementsInstancedBaseVertexBaseInstance(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32, basevertex int32, baseinstance uint32) {\n C.glowDrawElementsInstancedBaseVertexBaseInstance(gpDrawElementsInstancedBaseVertexBaseInstance, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLsizei)(instancecount), (C.GLint)(basevertex), (C.GLuint)(baseinstance))\n}", "func drawCards(game Game) {\n\tfmt.Println()\n\tfor i, c := range game.Cards {\n\t\tfmt.Println(\"Card\", i)\n\t\tfor i, r := range c.Rows {\n\t\t\tfmt.Printf(\"row %d: \", i)\n\t\t\tfor _, s := range r.Squares {\n\t\t\t\tif s.Called {\n\t\t\t\t\t// Format a 'called' number as another colour, or bold, or something.\n\t\t\t\t\tfmt.Printf(\"%s%2s%s \", \"\\u001b[32m\", s.Number, \"\\u001b[0m\")\n\t\t\t\t} else {\n\t\t\t\t\tfmt.Printf(\"%2s \", s.Number)\n\t\t\t\t}\n\t\t\t}\n\t\t\tfmt.Println()\n\t\t}\n\t\tfmt.Println()\n\t}\n\tfmt.Println()\n}", "func (native *OpenGL) DrawElementsOffset(mode uint32, count int32, elementType uint32, offset int) {\n\tgl.DrawElements(mode, count, elementType, gl.PtrOffset(offset))\n}", "func MultiDrawArrays(mode uint32, first *int32, count *int32, drawcount int32) {\n\tsyscall.Syscall6(gpMultiDrawArrays, 4, uintptr(mode), uintptr(unsafe.Pointer(first)), uintptr(unsafe.Pointer(count)), uintptr(drawcount), 0, 0)\n}", "func (p *Player) Draw(grid *Grid) {\n\tfor _, stat := range p.stats {\n\t\tstat.Draw(grid)\n\t}\n}", "func MultiDrawElementsIndirect(mode uint32, xtype uint32, indirect unsafe.Pointer, drawcount int32, stride int32) {\n\tC.glowMultiDrawElementsIndirect(gpMultiDrawElementsIndirect, (C.GLenum)(mode), (C.GLenum)(xtype), indirect, (C.GLsizei)(drawcount), (C.GLsizei)(stride))\n}", "func MultiDrawElementsIndirect(mode uint32, xtype uint32, indirect unsafe.Pointer, drawcount int32, stride int32) {\n\tC.glowMultiDrawElementsIndirect(gpMultiDrawElementsIndirect, (C.GLenum)(mode), (C.GLenum)(xtype), indirect, (C.GLsizei)(drawcount), (C.GLsizei)(stride))\n}", "func (el *Fill) Set() {}", "func (c *Container) Draw(r Region, delta float64) {\n}", "func GenerateShapes() {\r\n\t// Square\r\n\tShapes[0].vertices = []gl.GLfloat{-1, -1, 1, -1, -1, 1, 1, 1}\r\n\tShapes[0].elements = []gl.GLushort{0, 1, 2, 2, 3, 1}\r\n\r\n\t// ___|\r\n\tShapes[1].vertices = []gl.GLfloat{-2, 0, -2, -1, 2, -1, 2, 0, 2, 1, 1, 1, 1, 0}\r\n\tShapes[1].elements = []gl.GLushort{0, 1, 2, 2, 3, 0, 3, 4, 5, 5, 6, 3}\r\n\r\n\t// _|_\r\n\tShapes[2].vertices = []gl.GLfloat{-1.5, 0, -0.5, 0, -0.5, 1, 0.5, 1, 0.5, 0, 1.5, 0, 1.5, -1, -1.5, -1}\r\n\tShapes[2].elements = []gl.GLushort{1, 2, 3, 3, 4, 1, 0, 7, 6, 6, 0, 5}\r\n\r\n\t// Snake\r\n\tShapes[3].vertices = []gl.GLfloat{-1.5, -1, -1.5, 0, -0.5, 0, -0.5, 1, 1.5, 1, 1.5, 0, 0.5, 0, 0.5, -1}\r\n\tShapes[3].elements = []gl.GLushort{0, 1, 6, 6, 7, 0, 2, 3, 4, 4, 5, 2}\r\n\r\n\t// Now fill out the rest automatically.\r\n\t// FIXME why doesn't using _, shape in this loop work ?\r\n\tfor i := range Shapes {\r\n\t\tShapes[i].vao = gl.GenVertexArray()\r\n\t\tShapes[i].vao.Bind()\r\n\t\tShapes[i].vbo = gl.GenBuffer()\r\n\t\tShapes[i].vbo.Bind(gl.ARRAY_BUFFER)\r\n\t\tgl.BufferData(gl.ARRAY_BUFFER, len(Shapes[i].vertices)*4, Shapes[i].vertices, gl.STATIC_DRAW)\r\n\t\tShapes[i].elementBuffer = gl.GenBuffer()\r\n\t\tShapes[i].elementBuffer.Bind(gl.ELEMENT_ARRAY_BUFFER)\r\n\t\tgl.BufferData(gl.ELEMENT_ARRAY_BUFFER, len(Shapes[i].elements)*2, Shapes[i].elements, gl.STATIC_DRAW)\r\n\t\tShapes[i].numElements = len(Shapes[i].elements)\r\n\r\n\t\tvertexAttribArray := shaderProgram.GetAttribLocation(\"position\")\r\n\t\tvertexAttribArray.AttribPointer(2, gl.FLOAT, false, 0, uintptr(0))\r\n\t\tvertexAttribArray.EnableArray()\r\n\t}\r\n}", "func (sa ShapeAbstract) draw() {\n\t//following template methods design pattern\n\t//invoke virtual/\"abstract\" methods (defined in interface)\n\tsa.drawBoundary()\n\tfmt.Print(\"-\")\n\tsa.fillColor()\n}", "func drawFiveRectangles(ops *op.Ops) {\n\t// Record drawRedRect operations into the macro.\n\tmacro := op.Record(ops)\n\tdrawRedRect(ops)\n\tc := macro.Stop()\n\n\t// “Play back” the macro 5 times, each time\n\t// translated vertically 20px and horizontally 110 pixels.\n\tfor i := 0; i < 5; i++ {\n\t\tc.Add(ops)\n\t\top.Offset(image.Pt(110, 20)).Add(ops)\n\t}\n}", "func (b *Board) draw() {\n\ts := b.Game.Screen\n\n\tfor i := b.y; i < len(b.Grid); i++ {\n\t\tfor j := b.x; j < len(b.Grid[0]); j++ {\n\t\t\tvalue := b.Grid[i][j]\n\t\t\tif value == 1 {\n\t\t\t\tcellStyle := tcell.StyleDefault.Foreground(b.Game.CellColor).Background(b.Game.Background)\n\t\t\t\ts.SetContent(j*2, i, tcell.RuneBlock, nil, cellStyle)\n\t\t\t\ts.SetContent(j*2+1, i, tcell.RuneBlock, nil, cellStyle)\n\t\t\t}\n\t\t}\n\t}\n}", "func DrawArrays(mode uint32, first int32, count int32) {\n\tsyscall.Syscall(gpDrawArrays, 3, uintptr(mode), uintptr(first), uintptr(count))\n}", "func (c *captcha) drawLines(dc *gg.Context, W float64, H float64, strokeCount int) {\n\tfor i := 0; i < strokeCount; i++ {\n\t\tx1 := rand.Float64() * W\n\t\ty1 := rand.Float64() * H\n\t\tx2 := rand.Float64() * W\n\t\ty2 := rand.Float64() * H\n\t\tr := rand.Float64()\n\t\tg := rand.Float64()\n\t\tb := rand.Float64()\n\t\ta := rand.Float64()*0.5 + 0.5\n\t\tw := rand.Float64()*4 + 1\n\t\tdc.SetRGBA(r, g, b, a)\n\t\tdc.SetLineWidth(w)\n\t\tdc.DrawLine(x1, y1, x2, y2)\n\t\tdc.Stroke()\n\t}\n}", "func main() {\n\trand.Seed(time.Now().Unix())\n\tcanvas.Decimals=0\n\tcanvas.Start(width, height)\n\tcanvas.Rect(0, 0, width, height)\n\n\tw, h, gutter := 24.0, 18.0, 5.0\n\trows, cols := 16.0, 16.0\n\ttop, left := 20.0, 20.0\n\n\tfor r, x := 0.0, left; r < rows; r++ {\n\t\tfor c, y := 0.0, top; c < cols; c++ {\n\t\t\tcanvas.Rect(x, y, w, h,\n\t\t\t\tcanvas.RGB(rand.Intn(255), rand.Intn(255), rand.Intn(255)))\n\t\t\ty += (h + gutter)\n\t\t}\n\t\tx += (w + gutter)\n\t}\n\tcanvas.End()\n}", "func DrawElementsInstancedBaseVertexBaseInstance(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32, basevertex int32, baseinstance uint32) {\n\tC.glowDrawElementsInstancedBaseVertexBaseInstance(gpDrawElementsInstancedBaseVertexBaseInstance, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLsizei)(instancecount), (C.GLint)(basevertex), (C.GLuint)(baseinstance))\n}", "func DrawElementsInstancedBaseVertexBaseInstance(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32, basevertex int32, baseinstance uint32) {\n\tC.glowDrawElementsInstancedBaseVertexBaseInstance(gpDrawElementsInstancedBaseVertexBaseInstance, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLsizei)(instancecount), (C.GLint)(basevertex), (C.GLuint)(baseinstance))\n}", "func iterateObjects1DWithIndexes() {\n\tfmt.Println(\"*** iterateObjects1DWithIndexes\")\n\n\ttype Point struct {\n\t\tX int\n\t\tY int\n\t}\n\tpoints := [5]Point{\n\t\tPoint{1, 1},\n\t\tPoint{2, 2},\n\t\tPoint{3, 3},\n\t\tPoint{4, 4},\n\t\tPoint{5, 5},\n\t}\n\n\tfor i, e := range points {\n\t\tfmt.Printf(\"ints[%d]: %+v\\n\", i, e)\n\t}\n\tfmt.Println(\"\")\n}", "func lattice(xp, yp, w, h, size, hspace, vspace, n int, bgcolor string) {\n\tif bgcolor == \"\" {\n\t\tcanvas.Rect(0, 0, w, h, randcolor())\n\t} else {\n\t\tcanvas.Rect(0, 0, w, h, \"fill:\"+bgcolor)\n\t}\n\ty := yp\n\tfor r := 0; r < n; r++ {\n\t\tfor x := xp; x < w; x += hspace {\n\t\t\trcube(x, y, size)\n\t\t}\n\t\ty += vspace\n\t}\n}", "func draw(lines graph, title, xLabel, yLabel string) error {\n\tp, err := plot.New()\n\tif err != nil {\n\t\treturn fmt.Errorf(err.Error())\n\t}\n\n\tp.Title.Text = title\n\tp.X.Label.Text = xLabel\n\tp.Y.Label.Text = yLabel\n\n\ti := 0\n\tfor legend, data := range lines {\n\t\ti = i + 1\n\t\tl, err := plotter.NewLine(xys(data))\n\t\tif err != nil {\n\t\t\treturn fmt.Errorf(err.Error())\n\t\t}\n\n\t\tp.Add(l)\n\t\tp.Legend.Add(legend, l)\n\t\tl.LineStyle.Color = getColor(i)\n\t}\n\n\tif err != nil {\n\t\treturn fmt.Errorf(err.Error())\n\t}\n\n\tname := strings.Replace(strings.ToLower(title), \" \", \"-\", -1)\n\tfilename := fmt.Sprintf(\"strategy-%s.svg\", name)\n\tif err := p.Save(8, 8, filename); err != nil {\n\t\treturn fmt.Errorf(err.Error())\n\t}\n\n\treturn nil\n}", "func MultiDrawElementsBaseVertex(mode uint32, count *int32, xtype uint32, indices *unsafe.Pointer, drawcount int32, basevertex *int32) {\n C.glowMultiDrawElementsBaseVertex(gpMultiDrawElementsBaseVertex, (C.GLenum)(mode), (*C.GLsizei)(unsafe.Pointer(count)), (C.GLenum)(xtype), indices, (C.GLsizei)(drawcount), (*C.GLint)(unsafe.Pointer(basevertex)))\n}", "func (game *Game) Draw(num int) []Tile {\n\treturn game.Tiles.Draw(num)\n}", "func (d *DXF) Points(s v2.VecSet, r float64) {\n\td.drawing.ChangeLayer(\"Points\")\n\tfor _, p := range s {\n\t\td.drawing.Circle(p.X, p.Y, 0, r)\n\t}\n}", "func (g Grid) Draw(r *sdl.Renderer) {\n\tfor _, row := range g.cells {\n\t\tfor _, col := range row {\n\t\t\t//fmt.Printf(\"%v\\n\", col.color)\n\t\t\tr.SetDrawColor(col.color.R, col.color.G, col.color.B, col.color.A)\n\t\t\tr.FillRect(&col.rect)\n\t\t}\n\t}\n}", "func PaintFold(foldList, seq []string) {\n\n\t//size is 100, so we draw 100*n squares\n\tw := 500\n\th := 500\n\tpic := CreateNewCanvas(w, h)\n\t//set parameters\n\tpic.SetLineWidth(1)\n\n\t//start from the center\n\tx := float64(w / 2)\n\ty := float64(h / 2)\n\tpic.gc.ArcTo(x, y, 5, 5, 0, 2*math.Pi)\n\tif seq[0] == \"H\" {\n\t\twhite := MakeColor(255, 255, 255)\n\t\tpic.SetFillColor(white)\n\t\tpic.Stroke() //draw a white circle for H\n\t} else {\n\t\tblack := MakeColor(0, 0, 0)\n\t\tpic.SetFillColor(black)\n\t\tpic.Stroke() //black circle for P\n\t}\n\t//now start drawing\n\tpic.MoveTo(x, y)\n\t//first direction is front\n\tangle := math.Pi / 2\n\tincrement := math.Pi / 2\n\t//loop over all commands\n\tfor i := 0; i < len(foldList); i++ {\n\t\tif foldList[i] == \"l\" { //front+left=left=pi\n\t\t\tangle += increment\n\t\t} else if foldList[i] == \"r\" { //front+right=right\n\t\t\tangle -= increment\n\t\t}\n\t\t//produce next point based on angels\n\t\tx += 10 * math.Cos(angle)\n\t\ty -= 10 * math.Sin(angle)\n\t\t//conncet two points\n\t\tpic.LineTo(x, y)\n\t\t//then next point,the same as above\n\t\tif seq[i+1] == \"H\" {\n\t\t\tpic.gc.ArcTo(x, y, 5, 5, 0, 2*math.Pi)\n\t\t\twhite := MakeColor(255, 255, 255)\n\t\t\tpic.SetFillColor(white)\n\t\t\tpic.Stroke() //draw a white circle for H\n\t\t} else {\n\t\t\tpic.gc.ArcTo(x, y, 5, 5, 0, 2*math.Pi)\n\t\t\tblack := MakeColor(0, 0, 0)\n\t\t\tpic.SetFillColor(black)\n\t\t\tpic.Stroke() //black circle for P\n\t\t}\n\t}\n\tpic.Stroke()\n\tpic.SaveToPNG(\"fold.png\")\n\n}", "func MultiDrawArrays(mode uint32, first *int32, count *int32, drawcount int32) {\n C.glowMultiDrawArrays(gpMultiDrawArrays, (C.GLenum)(mode), (*C.GLint)(unsafe.Pointer(first)), (*C.GLsizei)(unsafe.Pointer(count)), (C.GLsizei)(drawcount))\n}", "func drawMutated(m Mutator, s string) {\n\tnewString := m.mutate(s)\n\tfmt.Println(newString)\n}", "func (r *blockRenderer) Objects() []fyne.CanvasObject {\n\t// if r.el.Name == \"mainWin\" {\n\t// \tfmt.Println(\"--blockRenderer.Objects\", len(append(r.el.obs, r.el.kids...)))\n\t// }\n\n\treturn append(r.el.obs, r.el.kids...)\n}", "func DrawElementsIndirect(mode uint32, xtype uint32, indirect unsafe.Pointer) {\n C.glowDrawElementsIndirect(gpDrawElementsIndirect, (C.GLenum)(mode), (C.GLenum)(xtype), indirect)\n}", "func DrawElementsBaseVertex(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, basevertex int32) {\n\tsyscall.Syscall6(gpDrawElementsBaseVertex, 5, uintptr(mode), uintptr(count), uintptr(xtype), uintptr(indices), uintptr(basevertex), 0)\n}", "func DrawElementsIndirect(mode uint32, xtype uint32, indirect unsafe.Pointer) {\n\tC.glowDrawElementsIndirect(gpDrawElementsIndirect, (C.GLenum)(mode), (C.GLenum)(xtype), indirect)\n}", "func DrawElementsIndirect(mode uint32, xtype uint32, indirect unsafe.Pointer) {\n\tC.glowDrawElementsIndirect(gpDrawElementsIndirect, (C.GLenum)(mode), (C.GLenum)(xtype), indirect)\n}", "func main() {\n\tpic.Show(Pic)\n\tpic.Show(Pic1)\n\tpic.Show(Pic2)\n\tpic.Show(Pic3)\n\tpic.Show(Pic4)\n\tpic.Show(Pic5)\n}", "func draw(w http.ResponseWriter, r *http.Request, which string) {\n\n\texprlist := getexprs(r) // must load data before writing anything\n\tnx := len(exprlist)\n\n\tputheader(w, r, which+\" Graph\") // write page header\n\tfmt.Fprintln(w, \"<P class=xleading>\")\n\n\ttreelist := make([]rx.Node, 0)\n\tfor i, e := range exprlist {\n\t\tif nx > 1 {\n\t\t\tfmt.Fprintf(w, \"%c. &nbsp; \", rx.AcceptLabels[i])\n\t\t}\n\t\tfmt.Fprintf(w, \"%s<BR>\\n\", hx(e))\n\t\ttree, err := rx.Parse(e)\n\t\tif !showerror(w, err) {\n\t\t\ttreelist = append(treelist, rx.Augment(tree, i))\n\t\t}\n\t}\n\n\tif nx > 0 && len(treelist) == nx { // if no errors\n\t\tdfa := rx.MultiDFA(treelist) // build combined DFA\n\t\tdmin := dfa.Minimize() // minimize it\n\n\t\tfmt.Fprintln(w, `<script type=\"text/vnd.graphviz\" id=\"graph\">`)\n\t\tif which == \"NFA\" {\n\t\t\tdmin.GraphNFA(w, \"\")\n\t\t} else if nx == 1 {\n\t\t\tdmin.ToDot(w, \"\", \"\")\n\t\t} else {\n\t\t\twhich = \"Multi\"\n\t\t\tdmin.ToDot(w, \"\", rx.AcceptLabels)\n\t\t}\n\t\tfmt.Fprintln(w, `</script>`)\n\n\t\ttDraw.Execute(w, which)\n\t}\n\tputfooter(w, r)\n}", "func (self *StraightLineTrack) Render(render chan Object) {\n\tfor _, val := range self.Childs() {\n\t\trender <- val\n\t}\n}", "func (s *Menu) Draw(screen *ebiten.Image) {\n\tscreen.Fill(colorBackground)\n\n\tfor _, d := range s.widgets {\n\t\td.Draw(screen)\n\t}\n}", "func DrawArraysInstancedBaseInstance(mode uint32, first int32, count int32, instancecount int32, baseinstance uint32) {\n C.glowDrawArraysInstancedBaseInstance(gpDrawArraysInstancedBaseInstance, (C.GLenum)(mode), (C.GLint)(first), (C.GLsizei)(count), (C.GLsizei)(instancecount), (C.GLuint)(baseinstance))\n}", "func (r Rect) Draw(s SVG, a ...string) {\n\ts.Rect(r.x0, r.y0, r.x1, r.y1, a...)\n}", "func (c *Canvas) AddElements(elements ...Element) {\n\tc.elements = append(c.elements, elements)\n\tc.Println(\"<defs>\")\n\tfor _, e := range elements {\n\t\tc.Println(e.Def())\n\t}\n\tc.Println(\"</defs>\")\n}", "func DrawElementsBaseVertex(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, basevertex int32) {\n C.glowDrawElementsBaseVertex(gpDrawElementsBaseVertex, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLint)(basevertex))\n}", "func DrawOrder(value int) *SimpleElement { return newSEInt(\"drawOrder\", value) }", "func (d *drawer) DrawUnitList(units []swgohhelp.Unit) ([]byte, error) {\n\t// 5 per row, 100px per unit, 10px padding\n\tpadding := 30\n\tportraitSize := 100\n\tunitSize := portraitSize + padding*2\n\twidth := unitSize * 5\n\theight := unitSize * int(math.Ceil((float64(len(units)) / 5.0)))\n\n\tcanvas := gg.NewContext(width, height)\n\tcanvas.SetHexColor(\"#0D1D25\")\n\tcanvas.Clear()\n\n\t// Use an asset bundle to save some disk I/O\n\tbundle := &assetBundle{\n\t\tui: make(map[string]image.Image),\n\t}\n\n\t// draw each unit portrait\n\tx, y := padding, padding\n\tfor unitCount, u := range units {\n\t\t// Draw portrait\n\t\tportrait, err := loadAsset(fmt.Sprintf(\"characters/%s_portrait.png\", u.Name))\n\t\tif err != nil {\n\t\t\tlogger.Errorf(\"Error loading character image portrait %v: %v\", u.Name, err)\n\t\t\tcontinue\n\t\t}\n\t\tcroppedPortrait := cropCircle(portrait)\n\t\tcanvas.DrawImage(croppedPortrait, x, y)\n\n\t\t// Draw gear\n\t\tgear, _ := bundle.loadUIAsset(fmt.Sprintf(\"ui/gear-icon-g%d_100x100.png\", u.Gear))\n\t\tif gear != nil {\n\t\t\tcanvas.DrawImage(gear, x, y)\n\t\t}\n\n\t\t// Draw stars\n\t\tstarYellow, _ := bundle.loadUIAsset(\"ui/ap-5r-char-portrait_star-yellow.png\")\n\t\tstarGray, _ := bundle.loadUIAsset(\"ui/ap-5r-char-portrait_star-gray.png\")\n\t\tif starYellow != nil {\n\t\t\tcx, cy := x+(unitSize/4)+10, y+(unitSize/4)\n\t\t\trotate := []float64{0, -66, -43, -21, 0, 21, 43, 66}\n\t\t\tfor i := 1; i <= 7; i++ {\n\t\t\t\tcanvas.Push()\n\t\t\t\tcanvas.Stroke()\n\t\t\t\tcanvas.Translate(0.5, 0)\n\t\t\t\tcanvas.RotateAbout(gg.Radians(rotate[i]), f(cx), f(cy))\n\t\t\t\tif u.Rarity >= i {\n\t\t\t\t\tcanvas.DrawImageAnchored(starYellow, cx, cy-26, 0.5, 0.5)\n\t\t\t\t} else {\n\t\t\t\t\tcanvas.DrawImageAnchored(starGray, cx, cy-26, 0.5, 0.5)\n\t\t\t\t}\n\t\t\t\tcanvas.Pop()\n\t\t\t}\n\t\t}\n\n\t\t// Check offset\n\t\tx += unitSize\n\t\tif (unitCount+1)%5 == 0 {\n\t\t\ty += unitSize\n\t\t\tx = padding\n\t\t}\n\t}\n\n\tvar b bytes.Buffer\n\tif err := canvas.EncodePNG(&b); err != nil {\n\t\treturn nil, err\n\t}\n\treturn b.Bytes(), nil\n}", "func DrawRangeElementsBaseVertex(mode uint32, start uint32, end uint32, count int32, xtype uint32, indices unsafe.Pointer, basevertex int32) {\n\tsyscall.Syscall9(gpDrawRangeElementsBaseVertex, 7, uintptr(mode), uintptr(start), uintptr(end), uintptr(count), uintptr(xtype), uintptr(indices), uintptr(basevertex), 0, 0)\n}", "func MultiDrawElementsBaseVertex(mode uint32, count *int32, xtype uint32, indices *unsafe.Pointer, drawcount int32, basevertex *int32) {\n\tC.glowMultiDrawElementsBaseVertex(gpMultiDrawElementsBaseVertex, (C.GLenum)(mode), (*C.GLsizei)(unsafe.Pointer(count)), (C.GLenum)(xtype), indices, (C.GLsizei)(drawcount), (*C.GLint)(unsafe.Pointer(basevertex)))\n}", "func MultiDrawElementsBaseVertex(mode uint32, count *int32, xtype uint32, indices *unsafe.Pointer, drawcount int32, basevertex *int32) {\n\tC.glowMultiDrawElementsBaseVertex(gpMultiDrawElementsBaseVertex, (C.GLenum)(mode), (*C.GLsizei)(unsafe.Pointer(count)), (C.GLenum)(xtype), indices, (C.GLsizei)(drawcount), (*C.GLint)(unsafe.Pointer(basevertex)))\n}", "func drawGrid(pdf *gofpdf.Fpdf) {\n w, h := pdf.GetPageSize()\n pdf.SetFont(\"courier\", \"\", 12)\n pdf.SetTextColor(80, 80, 80)\n pdf.SetDrawColor(200, 200, 200)\n for x := 0.0; x < w; x = x + (w / 20.0) {\n pdf.SetTextColor(200, 200, 200)\n pdf.Line(x, 0, x, h)\n _, lineHt := pdf.GetFontSize()\n pdf.Text(x, lineHt, fmt.Sprintf(\"%d\", int(x)))\n }\n for y := 0.0; y < h; y = y + (w / 20.0) {\n pdf.SetTextColor(80, 80, 80)\n pdf.Line(0, y, w, y)\n pdf.Text(0, y, fmt.Sprintf(\"%d\", int(y)))\n }\n}", "func (el *Fill) Rect() {}", "func drawBoard(b []string) {\n\tfmt.Println(b[0], \"|\", b[1], \"|\", b[2])\n\tfmt.Println(\"---------\")\n\tfmt.Println(b[3], \"|\", b[4], \"|\", b[5])\n\tfmt.Println(\"---------\")\n\tfmt.Println(b[6], \"|\", b[7], \"|\", b[8])\n}", "func (g *Gui) draw(v *View) error {\n\tif g.Cursor {\n\t\tif curview := g.currentView; curview != nil {\n\t\t\tvMaxX, vMaxY := curview.Size()\n\t\t\tif curview.cx < 0 {\n\t\t\t\tcurview.cx = 0\n\t\t\t} else if curview.cx >= vMaxX {\n\t\t\t\tcurview.cx = vMaxX - 1\n\t\t\t}\n\t\t\tif curview.cy < 0 {\n\t\t\t\tcurview.cy = 0\n\t\t\t} else if curview.cy >= vMaxY {\n\t\t\t\tcurview.cy = vMaxY - 1\n\t\t\t}\n\n\t\t\tgMaxX, gMaxY := g.Size()\n\t\t\tcx, cy := curview.x0+curview.cx+1, curview.y0+curview.cy+1\n\t\t\tif cx >= 0 && cx < gMaxX && cy >= 0 && cy < gMaxY {\n\t\t\t\tg.screen.ShowCursor(cx, cy)\n\t\t\t} else {\n\t\t\t\tg.screen.ShowCursor(-1, -1) // HideCursor\n\t\t\t}\n\t\t}\n\t} else {\n\t\tg.screen.ShowCursor(-1, -1) // HideCursor\n\t}\n\n\tv.clearRunes()\n\tif err := v.draw(); err != nil {\n\t\treturn err\n\t}\n\treturn nil\n}", "func (v *VerticalContainer) Draw(dst *ebiten.Image, bounds geo.Rect) {\n\ttotalWeight := 0.0\n\tfor _, e := range v.Elements {\n\t\ttotalWeight += e.Weight()\n\t}\n\theights := make([]float64, len(v.Elements))\n\tfor i, e := range v.Elements {\n\t\theights[i] = e.Weight() / totalWeight * bounds.H\n\t}\n\tsubBounds := bounds\n\tfor i, h := range heights {\n\t\tsubBounds.H = h\n\t\tv.Elements[i].Draw(dst, subBounds)\n\t\tsubBounds.Y += h\n\t}\n}", "func (s *HelloSystem) Draw(ctx core.DrawCtx) {\n\tfor _, v := range s.V().Matches() {\n\t\tebitenutil.DebugPrintAt(ctx.Renderer().Screen(), v.Hello.Text, v.Hello.X, v.Hello.Y)\n\t}\n}", "func DrawRangeElementsBaseVertex(mode uint32, start uint32, end uint32, count int32, xtype uint32, indices unsafe.Pointer, basevertex int32) {\n C.glowDrawRangeElementsBaseVertex(gpDrawRangeElementsBaseVertex, (C.GLenum)(mode), (C.GLuint)(start), (C.GLuint)(end), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLint)(basevertex))\n}", "func DrawArraysInstancedBaseInstance(mode uint32, first int32, count int32, instancecount int32, baseinstance uint32) {\n\tsyscall.Syscall6(gpDrawArraysInstancedBaseInstance, 5, uintptr(mode), uintptr(first), uintptr(count), uintptr(instancecount), uintptr(baseinstance), 0)\n}", "func (s *SVG) Group(elements [2]string, args map[string]interface{}) {\n\ts.svgString += fmt.Sprintf(\"<g %s>\", s.WriteArgs(args))\n\ts.svgString += elements[0] + elements[1]\n\ts.svgString += \"</g>\"\n}", "func (plot Plot) DrawAll(data []scope.ChannelData, traceParams map[scope.ChanID]scope.TraceParams, cols map[scope.ChanID]color.RGBA) error {\n\tb := plot.Bounds()\n\tfor _, chanData := range data {\n\t\tid, v := chanData.ID, chanData.Samples\n\t\tparams, exists := traceParams[id]\n\t\tif !exists {\n\t\t\tparams = scope.TraceParams{defaultZero, defaultVoltsPerDiv}\n\t\t}\n\t\tcol, exists := cols[id]\n\t\tif !exists {\n\t\t\tcol = ColorBlack\n\t\t}\n\t\tif err := plot.DrawSamples(v, params, b, col); err != nil {\n\t\t\treturn err\n\t\t}\n\t}\n\treturn nil\n}", "func (b *Board) Draw() {\n\tfor _, key := range b.bigKeys {\n\t\tkey.Draw()\n\t}\n\tfor _, key := range b.smallKeys {\n\t\tkey.Draw()\n\t}\n}", "func drawProbs(w *world.World, locs []*world.Loc, probs []float64, name string, i int) {\n\tout, err := os.Create(fmt.Sprintf(\"%s-%d-%d.png\", name, *seed, i))\n\tif err != nil {\n\t\tpanic(err)\n\t}\n\tdefer out.Close()\n\n\tps := make([]float64, w.W*w.H)\n\tmx := 0.0\n\tfor i, l := range locs {\n\t\tps[l.X*w.H+l.Y] = probs[i]\n\t\tif probs[i] > mx {\n\t\t\tmx = probs[i]\n\t\t}\n\t}\n\tpng.Encode(out, &worldImg{w, ps, mx})\n}" ]
[ "0.6490418", "0.6415478", "0.6394806", "0.63552046", "0.62872607", "0.6254875", "0.6156781", "0.6156781", "0.61106503", "0.59773797", "0.59773797", "0.59211403", "0.57765806", "0.5751231", "0.56548256", "0.56237483", "0.5605063", "0.55854434", "0.55854434", "0.5567551", "0.5534736", "0.553423", "0.5520922", "0.54762244", "0.5458111", "0.5458111", "0.5452446", "0.5444324", "0.5424779", "0.53909004", "0.53064454", "0.53064454", "0.52268183", "0.52238905", "0.5197633", "0.51929814", "0.51929814", "0.51914513", "0.5164379", "0.51592565", "0.5149356", "0.5133571", "0.5124829", "0.5110387", "0.5099563", "0.50906235", "0.50904065", "0.50904065", "0.508918", "0.507903", "0.50722474", "0.5028112", "0.50049615", "0.49902382", "0.49877962", "0.49682757", "0.49577495", "0.4956176", "0.4956176", "0.49524787", "0.49514788", "0.49439028", "0.49425408", "0.49411246", "0.49410245", "0.49193943", "0.49113524", "0.49066085", "0.4904436", "0.49033004", "0.48883554", "0.48769256", "0.487525", "0.487525", "0.48645154", "0.48374915", "0.4832495", "0.48173252", "0.48172015", "0.481571", "0.48149934", "0.4812177", "0.48118874", "0.4798875", "0.47889817", "0.47833657", "0.47833657", "0.47753322", "0.4769666", "0.47664154", "0.47461477", "0.47418958", "0.47367167", "0.47338098", "0.47323215", "0.47271717", "0.4722543", "0.47006425", "0.46982512" ]
0.62328726
7
draw multiple instances of a set of elements with offset applied to instanced attributes
func DrawElementsInstancedBaseInstance(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32, baseinstance uint32) { C.glowDrawElementsInstancedBaseInstance(gpDrawElementsInstancedBaseInstance, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLsizei)(instancecount), (C.GLuint)(baseinstance)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func DrawElementsInstanced(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32) {\n C.glowDrawElementsInstanced(gpDrawElementsInstanced, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLsizei)(instancecount))\n}", "func (native *OpenGL) DrawElementsOffset(mode uint32, count int32, elementType uint32, offset int) {\n\tgl.DrawElements(mode, count, elementType, gl.PtrOffset(offset))\n}", "func DrawElementsInstanced(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32) {\n\tC.glowDrawElementsInstanced(gpDrawElementsInstanced, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLsizei)(instancecount))\n}", "func DrawElementsInstanced(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32) {\n\tC.glowDrawElementsInstanced(gpDrawElementsInstanced, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLsizei)(instancecount))\n}", "func MultiDrawElements(mode uint32, count *int32, xtype uint32, indices *unsafe.Pointer, drawcount int32) {\n\tsyscall.Syscall6(gpMultiDrawElements, 5, uintptr(mode), uintptr(unsafe.Pointer(count)), uintptr(xtype), uintptr(unsafe.Pointer(indices)), uintptr(drawcount), 0)\n}", "func DrawRangeElements(mode uint32, start uint32, end uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n\tsyscall.Syscall6(gpDrawRangeElements, 6, uintptr(mode), uintptr(start), uintptr(end), uintptr(count), uintptr(xtype), uintptr(indices))\n}", "func DrawElementsInstancedBaseInstance(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32, baseinstance uint32) {\n\tsyscall.Syscall6(gpDrawElementsInstancedBaseInstance, 6, uintptr(mode), uintptr(count), uintptr(xtype), uintptr(indices), uintptr(instancecount), uintptr(baseinstance))\n}", "func DrawElements(mode uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n\tsyscall.Syscall6(gpDrawElements, 4, uintptr(mode), uintptr(count), uintptr(xtype), uintptr(indices), 0, 0)\n}", "func DrawElementsInstancedBaseInstance(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32, baseinstance uint32) {\n C.glowDrawElementsInstancedBaseInstance(gpDrawElementsInstancedBaseInstance, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLsizei)(instancecount), (C.GLuint)(baseinstance))\n}", "func DrawElementsInstancedBaseVertex(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32, basevertex int32) {\n\tsyscall.Syscall6(gpDrawElementsInstancedBaseVertex, 6, uintptr(mode), uintptr(count), uintptr(xtype), uintptr(indices), uintptr(instancecount), uintptr(basevertex))\n}", "func MultiDrawElements(mode uint32, count *int32, xtype uint32, indices *unsafe.Pointer, drawcount int32) {\n C.glowMultiDrawElements(gpMultiDrawElements, (C.GLenum)(mode), (*C.GLsizei)(unsafe.Pointer(count)), (C.GLenum)(xtype), indices, (C.GLsizei)(drawcount))\n}", "func DrawRangeElements(mode uint32, start uint32, end uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n C.glowDrawRangeElements(gpDrawRangeElements, (C.GLenum)(mode), (C.GLuint)(start), (C.GLuint)(end), (C.GLsizei)(count), (C.GLenum)(xtype), indices)\n}", "func MultiDrawElementsIndirect(mode uint32, xtype uint32, indirect unsafe.Pointer, drawcount int32, stride int32) {\n\tsyscall.Syscall6(gpMultiDrawElementsIndirect, 5, uintptr(mode), uintptr(xtype), uintptr(indirect), uintptr(drawcount), uintptr(stride), 0)\n}", "func DrawElementsInstancedBaseVertex(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32, basevertex int32) {\n C.glowDrawElementsInstancedBaseVertex(gpDrawElementsInstancedBaseVertex, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLsizei)(instancecount), (C.GLint)(basevertex))\n}", "func DrawElements(mode uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n C.glowDrawElements(gpDrawElements, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices)\n}", "func DrawElements(mode Enum, count int, ty Enum, offset int) {\n\tgl.DrawElements(uint32(mode), int32(count), uint32(ty), gl.PtrOffset(offset))\n}", "func DrawArraysInstanced(mode uint32, first int32, count int32, instancecount int32) {\n C.glowDrawArraysInstanced(gpDrawArraysInstanced, (C.GLenum)(mode), (C.GLint)(first), (C.GLsizei)(count), (C.GLsizei)(instancecount))\n}", "func DrawElementsInstancedBaseVertex(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32, basevertex int32) {\n\tC.glowDrawElementsInstancedBaseVertex(gpDrawElementsInstancedBaseVertex, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLsizei)(instancecount), (C.GLint)(basevertex))\n}", "func DrawElementsInstancedBaseVertex(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32, basevertex int32) {\n\tC.glowDrawElementsInstancedBaseVertex(gpDrawElementsInstancedBaseVertex, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLsizei)(instancecount), (C.GLint)(basevertex))\n}", "func MultiDrawElements(mode uint32, count *int32, xtype uint32, indices *unsafe.Pointer, drawcount int32) {\n\tC.glowMultiDrawElements(gpMultiDrawElements, (C.GLenum)(mode), (*C.GLsizei)(unsafe.Pointer(count)), (C.GLenum)(xtype), indices, (C.GLsizei)(drawcount))\n}", "func MultiDrawElements(mode uint32, count *int32, xtype uint32, indices *unsafe.Pointer, drawcount int32) {\n\tC.glowMultiDrawElements(gpMultiDrawElements, (C.GLenum)(mode), (*C.GLsizei)(unsafe.Pointer(count)), (C.GLenum)(xtype), indices, (C.GLsizei)(drawcount))\n}", "func DrawElementsInstancedBaseVertexBaseInstance(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32, basevertex int32, baseinstance uint32) {\n\tsyscall.Syscall9(gpDrawElementsInstancedBaseVertexBaseInstance, 7, uintptr(mode), uintptr(count), uintptr(xtype), uintptr(indices), uintptr(instancecount), uintptr(basevertex), uintptr(baseinstance), 0, 0)\n}", "func DrawRangeElements(mode uint32, start uint32, end uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n\tC.glowDrawRangeElements(gpDrawRangeElements, (C.GLenum)(mode), (C.GLuint)(start), (C.GLuint)(end), (C.GLsizei)(count), (C.GLenum)(xtype), indices)\n}", "func DrawRangeElements(mode uint32, start uint32, end uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n\tC.glowDrawRangeElements(gpDrawRangeElements, (C.GLenum)(mode), (C.GLuint)(start), (C.GLuint)(end), (C.GLsizei)(count), (C.GLenum)(xtype), indices)\n}", "func DrawElementsIndirect(mode uint32, xtype uint32, indirect unsafe.Pointer) {\n\tsyscall.Syscall(gpDrawElementsIndirect, 3, uintptr(mode), uintptr(xtype), uintptr(indirect))\n}", "func MultiDrawElementsIndirect(mode uint32, xtype uint32, indirect unsafe.Pointer, drawcount int32, stride int32) {\n C.glowMultiDrawElementsIndirect(gpMultiDrawElementsIndirect, (C.GLenum)(mode), (C.GLenum)(xtype), indirect, (C.GLsizei)(drawcount), (C.GLsizei)(stride))\n}", "func (c *Canvas) printElements() {\n\tfor _, es := range c.elements {\n\t\tc.Println(\"<g>\")\n\t\tfor _, e := range es {\n\t\t\tc.Println(e.Usebg())\n\t\t}\n\t\tfor _, e := range es {\n\t\t\tc.Println(e.Use())\n\t\t}\n\t\tc.Println(\"</g>\")\n\t}\n}", "func (self *Graphics) SetOffsetXA(member int) {\n self.Object.Set(\"offsetX\", member)\n}", "func DrawElementsInstancedBaseVertexBaseInstance(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32, basevertex int32, baseinstance uint32) {\n C.glowDrawElementsInstancedBaseVertexBaseInstance(gpDrawElementsInstancedBaseVertexBaseInstance, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLsizei)(instancecount), (C.GLint)(basevertex), (C.GLuint)(baseinstance))\n}", "func DrawArraysInstancedBaseInstance(mode uint32, first int32, count int32, instancecount int32, baseinstance uint32) {\n\tsyscall.Syscall6(gpDrawArraysInstancedBaseInstance, 5, uintptr(mode), uintptr(first), uintptr(count), uintptr(instancecount), uintptr(baseinstance), 0)\n}", "func (self *Graphics) SetOffsetYA(member int) {\n self.Object.Set(\"offsetY\", member)\n}", "func (c *Compound) DrawOffset(buff draw.Image, xOff float64, yOff float64) {\n\tc.lock.RLock()\n\tc.subRenderables[c.curRenderable].DrawOffset(buff, c.X()+xOff, c.Y()+yOff)\n\tc.lock.RUnlock()\n}", "func DrawElements(mode uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n\tC.glowDrawElements(gpDrawElements, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices)\n}", "func DrawElements(mode uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n\tC.glowDrawElements(gpDrawElements, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices)\n}", "func (self *Rectangle) Offset(dx int, dy int) *Rectangle{\n return &Rectangle{self.Object.Call(\"offset\", dx, dy)}\n}", "func DrawArraysInstancedBaseInstance(mode uint32, first int32, count int32, instancecount int32, baseinstance uint32) {\n C.glowDrawArraysInstancedBaseInstance(gpDrawArraysInstancedBaseInstance, (C.GLenum)(mode), (C.GLint)(first), (C.GLsizei)(count), (C.GLsizei)(instancecount), (C.GLuint)(baseinstance))\n}", "func DrawArraysInstanced(mode uint32, first int32, count int32, instancecount int32) {\n\tC.glowDrawArraysInstanced(gpDrawArraysInstanced, (C.GLenum)(mode), (C.GLint)(first), (C.GLsizei)(count), (C.GLsizei)(instancecount))\n}", "func DrawArraysInstanced(mode uint32, first int32, count int32, instancecount int32) {\n\tC.glowDrawArraysInstanced(gpDrawArraysInstanced, (C.GLenum)(mode), (C.GLint)(first), (C.GLsizei)(count), (C.GLsizei)(instancecount))\n}", "func (a *aquarium) draw(c termdraw.Canvas) {\n\tfor _, fish := range a.fish {\n\t\ttermdraw.DrawSprite(c, fish.position.Sub(a.canvasOffset), fish.sprite.Current())\n\t}\n}", "func (ev MouseEvent) Offset(offset Vec2i) MouseEvent {\n\treturn MouseEvent{\n\t\tPos: ev.Pos.Add(offset),\n\t\tID: ev.ID,\n\t\tButton: ev.Button,\n\t}\n}", "func DrawElementsIndirect(mode uint32, xtype uint32, indirect unsafe.Pointer) {\n C.glowDrawElementsIndirect(gpDrawElementsIndirect, (C.GLenum)(mode), (C.GLenum)(xtype), indirect)\n}", "func (c *Container) Draw(r Region, delta float64) {\n}", "func Offset(dx, dy float32) {\n\tgContext.Cursor.X += dx\n\tgContext.Cursor.Y += dy\n}", "func MultiDrawElementsIndirect(mode uint32, xtype uint32, indirect unsafe.Pointer, drawcount int32, stride int32) {\n\tC.glowMultiDrawElementsIndirect(gpMultiDrawElementsIndirect, (C.GLenum)(mode), (C.GLenum)(xtype), indirect, (C.GLsizei)(drawcount), (C.GLsizei)(stride))\n}", "func MultiDrawElementsIndirect(mode uint32, xtype uint32, indirect unsafe.Pointer, drawcount int32, stride int32) {\n\tC.glowMultiDrawElementsIndirect(gpMultiDrawElementsIndirect, (C.GLenum)(mode), (C.GLenum)(xtype), indirect, (C.GLsizei)(drawcount), (C.GLsizei)(stride))\n}", "func DrawElementsInstancedBaseVertexBaseInstance(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32, basevertex int32, baseinstance uint32) {\n\tC.glowDrawElementsInstancedBaseVertexBaseInstance(gpDrawElementsInstancedBaseVertexBaseInstance, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLsizei)(instancecount), (C.GLint)(basevertex), (C.GLuint)(baseinstance))\n}", "func DrawElementsInstancedBaseVertexBaseInstance(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32, basevertex int32, baseinstance uint32) {\n\tC.glowDrawElementsInstancedBaseVertexBaseInstance(gpDrawElementsInstancedBaseVertexBaseInstance, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLsizei)(instancecount), (C.GLint)(basevertex), (C.GLuint)(baseinstance))\n}", "func DrawRangeElementsBaseVertex(mode uint32, start uint32, end uint32, count int32, xtype uint32, indices unsafe.Pointer, basevertex int32) {\n\tsyscall.Syscall9(gpDrawRangeElementsBaseVertex, 7, uintptr(mode), uintptr(start), uintptr(end), uintptr(count), uintptr(xtype), uintptr(indices), uintptr(basevertex), 0, 0)\n}", "func (ff *fftag) at(id int) (x, y int) { return id / ff.msize, id % ff.msize }", "func main() {\n\trand.Seed(time.Now().Unix())\n\tcanvas.Decimals=0\n\tcanvas.Start(width, height)\n\tcanvas.Rect(0, 0, width, height)\n\n\tw, h, gutter := 24.0, 18.0, 5.0\n\trows, cols := 16.0, 16.0\n\ttop, left := 20.0, 20.0\n\n\tfor r, x := 0.0, left; r < rows; r++ {\n\t\tfor c, y := 0.0, top; c < cols; c++ {\n\t\t\tcanvas.Rect(x, y, w, h,\n\t\t\t\tcanvas.RGB(rand.Intn(255), rand.Intn(255), rand.Intn(255)))\n\t\t\ty += (h + gutter)\n\t\t}\n\t\tx += (w + gutter)\n\t}\n\tcanvas.End()\n}", "func DrawRangeElementsBaseVertex(mode uint32, start uint32, end uint32, count int32, xtype uint32, indices unsafe.Pointer, basevertex int32) {\n C.glowDrawRangeElementsBaseVertex(gpDrawRangeElementsBaseVertex, (C.GLenum)(mode), (C.GLuint)(start), (C.GLuint)(end), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLint)(basevertex))\n}", "func (self *Rectangle) OffsetI(args ...interface{}) *Rectangle{\n return &Rectangle{self.Object.Call(\"offset\", args)}\n}", "func MultiDrawElementsBaseVertex(mode uint32, count *int32, xtype uint32, indices *unsafe.Pointer, drawcount int32, basevertex *int32) {\n\tsyscall.Syscall6(gpMultiDrawElementsBaseVertex, 6, uintptr(mode), uintptr(unsafe.Pointer(count)), uintptr(xtype), uintptr(unsafe.Pointer(indices)), uintptr(drawcount), uintptr(unsafe.Pointer(basevertex)))\n}", "func (c *component) drawChildren(mx, my int) {\n\tfor _, child := range c.children {\n\t\tr := child.GetBounds()\n\t\timg := child.Draw(mx, my)\n\t\tif img != nil {\n\t\t\tdraw.Draw(c.Image, r, img, image.ZP, draw.Over)\n\t\t}\n\t}\n}", "func DrawOrder(value int) *SimpleElement { return newSEInt(\"drawOrder\", value) }", "func DrawElementsIndirect(mode uint32, xtype uint32, indirect unsafe.Pointer) {\n\tC.glowDrawElementsIndirect(gpDrawElementsIndirect, (C.GLenum)(mode), (C.GLenum)(xtype), indirect)\n}", "func DrawElementsIndirect(mode uint32, xtype uint32, indirect unsafe.Pointer) {\n\tC.glowDrawElementsIndirect(gpDrawElementsIndirect, (C.GLenum)(mode), (C.GLenum)(xtype), indirect)\n}", "func DrawArraysInstancedBaseInstance(mode uint32, first int32, count int32, instancecount int32, baseinstance uint32) {\n\tC.glowDrawArraysInstancedBaseInstance(gpDrawArraysInstancedBaseInstance, (C.GLenum)(mode), (C.GLint)(first), (C.GLsizei)(count), (C.GLsizei)(instancecount), (C.GLuint)(baseinstance))\n}", "func DrawArraysInstancedBaseInstance(mode uint32, first int32, count int32, instancecount int32, baseinstance uint32) {\n\tC.glowDrawArraysInstancedBaseInstance(gpDrawArraysInstancedBaseInstance, (C.GLenum)(mode), (C.GLint)(first), (C.GLsizei)(count), (C.GLsizei)(instancecount), (C.GLuint)(baseinstance))\n}", "func (self *TileSprite) SetOffsetYA(member int) {\n self.Object.Set(\"offsetY\", member)\n}", "func (debugging *debuggingOpenGL) DrawElements(mode uint32, count int32, elementType uint32, indices uintptr) {\n\tdebugging.recordEntry(\"DrawElements\", mode, count, elementType, indices)\n\tdebugging.gl.DrawElements(mode, count, elementType, indices)\n\tdebugging.recordExit(\"DrawElements\")\n}", "func (v *VerticalContainer) Draw(dst *ebiten.Image, bounds geo.Rect) {\n\ttotalWeight := 0.0\n\tfor _, e := range v.Elements {\n\t\ttotalWeight += e.Weight()\n\t}\n\theights := make([]float64, len(v.Elements))\n\tfor i, e := range v.Elements {\n\t\theights[i] = e.Weight() / totalWeight * bounds.H\n\t}\n\tsubBounds := bounds\n\tfor i, h := range heights {\n\t\tsubBounds.H = h\n\t\tv.Elements[i].Draw(dst, subBounds)\n\t\tsubBounds.Y += h\n\t}\n}", "func (native *OpenGL) DrawElements(mode uint32, count int32, elementType uint32, indices uintptr) {\n\tgl.DrawElements(mode, count, elementType, unsafe.Pointer(indices)) // nolint: govet,gas\n}", "func (c *Switch) SetOffsets(k string, offsets physics.Vector) {\n\tc.lock.RLock()\n\tif r, ok := c.subRenderables[k]; ok {\n\t\tr.SetPos(offsets.X(), offsets.Y())\n\t}\n\tc.lock.RUnlock()\n}", "func drawFiveRectangles(ops *op.Ops) {\n\t// Record drawRedRect operations into the macro.\n\tmacro := op.Record(ops)\n\tdrawRedRect(ops)\n\tc := macro.Stop()\n\n\t// “Play back” the macro 5 times, each time\n\t// translated vertically 20px and horizontally 110 pixels.\n\tfor i := 0; i < 5; i++ {\n\t\tc.Add(ops)\n\t\top.Offset(image.Pt(110, 20)).Add(ops)\n\t}\n}", "func (c *Compound) SetOffsets(k string, offsets physics.Vector) {\n\tc.lock.RLock()\n\tif r, ok := c.subRenderables[k]; ok {\n\t\tr.SetPos(offsets.X(), offsets.Y())\n\t}\n\tc.lock.RUnlock()\n}", "func (w *widgetbase) allocate(x int, y int, width int, height int, d *sizing) []*allocation {\n return []*allocation{&allocation{\n x: x,\n y: y,\n width: width,\n height: height,\n this: w,\n }}\n}", "func DrawElementsBaseVertex(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, basevertex int32) {\n\tsyscall.Syscall6(gpDrawElementsBaseVertex, 5, uintptr(mode), uintptr(count), uintptr(xtype), uintptr(indices), uintptr(basevertex), 0)\n}", "func iterateObjects1DWithIndexes() {\n\tfmt.Println(\"*** iterateObjects1DWithIndexes\")\n\n\ttype Point struct {\n\t\tX int\n\t\tY int\n\t}\n\tpoints := [5]Point{\n\t\tPoint{1, 1},\n\t\tPoint{2, 2},\n\t\tPoint{3, 3},\n\t\tPoint{4, 4},\n\t\tPoint{5, 5},\n\t}\n\n\tfor i, e := range points {\n\t\tfmt.Printf(\"ints[%d]: %+v\\n\", i, e)\n\t}\n\tfmt.Println(\"\")\n}", "func (self *Graphics) OffsetX() int{\n return self.Object.Get(\"offsetX\").Int()\n}", "func DrawElementsBaseVertex(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, basevertex int32) {\n C.glowDrawElementsBaseVertex(gpDrawElementsBaseVertex, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLint)(basevertex))\n}", "func labelMarkers(m []Marker, x, y int, anchor string, fontSize int, short bool, b *bytes.Buffer) {\n\tb.WriteString(`<g id=\"marker_labels\">`)\n\tfor _, mr := range m {\n\t\tb.WriteString(fmt.Sprintf(\"<text x=\\\"%d\\\" y=\\\"%d\\\" font-size=\\\"%d\\\" visibility=\\\"hidden\\\" text-anchor=\\\"%s\\\">\", x, y, fontSize, anchor))\n\t\tif short {\n\t\t\tb.WriteString(mr.shortLabel)\n\t\t} else {\n\t\t\tb.WriteString(mr.label)\n\t\t}\n\t\tb.WriteString(fmt.Sprintf(\"<set attributeName=\\\"visibility\\\" from=\\\"hidden\\\" to=\\\"visible\\\" begin=\\\"%s.mouseover\\\" end=\\\"%s.mouseout\\\" dur=\\\"2s\\\"/>\",\n\t\t\tmr.id, mr.id))\n\t\tb.WriteString(`</text>`)\n\t}\n\tb.WriteString(`</g>`)\n}", "func (r *Render) DrawOffset(buff draw.Image, xOff, yOff float64) {\n\t// If there hasn't been new mouse input, so the 3d model has not been rotated\n\t// since it was processed last, don't re-process the model's rotation.\n\tif mouse.LastMouseEvent != r.lastmouse {\n\t\t// Reset the backing Sprite's color buffer to be empty, so we avoid\n\t\t// smearing with the last drawn frame.\n\t\tbounds := r.Sprite.GetRGBA().Bounds()\n\t\tr.Sprite.SetRGBA(image.NewRGBA(bounds))\n\t\tw := bounds.Max.X\n\t\th := bounds.Max.Y\n\n\t\t// Get the mouse position and scale it down so we can use it for the\n\t\t// render's rotation.\n\t\tmouseXt := float64(mouse.LastMouseEvent.X * .005)\n\t\tmouseYt := float64(mouse.LastMouseEvent.Y * .005)\n\t\t// Set up a zbuffer so we know what pixels we should draw and which ones\n\t\t// are behind others we have already drawn. Initialize all values in the\n\t\t// buffer to be as far back as possible (-math.MaxFloat64)\n\t\tzbuff := make([][]float64, w)\n\t\tfor i := range zbuff {\n\t\t\tzbuff[i] = make([]float64, h)\n\t\t\tfor j := range zbuff[i] {\n\t\t\t\tzbuff[i][j] = -math.MaxFloat64\n\t\t\t}\n\t\t}\n\t\t// The center, or origin, is at 0,0,0\n\t\tctr := Vertex{0.0, 0.0, 0.0}\n\t\t// Which way up is, or pointing in the y direction\n\t\tup := Vertex{0.0, 1.0, 0.0}\n\t\t// Where we're looking from\n\t\teye := Vertex{math.Sin(mouseXt), math.Sin(mouseYt), math.Cos(mouseXt)}\n\t\t// (More documentation needed here)\n\t\tz := eye.Sub(ctr).Unit()\n\t\tx := up.Cross(z).Unit()\n\t\ty := z.Cross(x)\n\n\t\t// For each triangle, draw it\n\t\tfor i := 0; i < len(r.tv); i++ {\n\t\t\t// Obtain the normal and triangle values\n\t\t\t// from our view\n\t\t\t// (More documentation needed here)\n\t\t\tnrm := r.tn[i].ViewNrm(x, y, z)\n\t\t\ttri := r.tv[i].ViewTri(x, y, z, eye)\n\t\t\ttex := r.tt[i]\n\t\t\tper := tri.Perspective()\n\t\t\tvew := per.Viewport(floatgeom.Point2{float64(w), float64(h)})\n\t\t\t// Actually draw the triangle given the values we've calculated\n\t\t\tTDraw(r.Sprite.GetRGBA(), zbuff, vew, nrm, tex, r.textureData)\n\t\t}\n\t}\n\tr.lastmouse = mouse.LastMouseEvent\n\t// Instead of handling the drawing ourselves, let the embedded Sprite which\n\t// we've populated the color buffer of draw itself.\n\tr.Sprite.DrawOffset(buff, xOff, yOff)\n}", "func assignCoordinates(layers [][]*vertex, ro *renderConfig) {\n\tmaxWidth := rowWidth(layers, ro)\n\tfor _, l := range layers {\n\t\tboxCenterOffset := maxWidth / (len(l) + 1)\n\t\tfor j := 0; j < len(l); j++ {\n\t\t\tl[j].rowOffset = (j + 1) * boxCenterOffset\n\t\t}\n\t}\n}", "func (el *Fill) Animate() {}", "func MultiDrawElementsBaseVertex(mode uint32, count *int32, xtype uint32, indices *unsafe.Pointer, drawcount int32, basevertex *int32) {\n C.glowMultiDrawElementsBaseVertex(gpMultiDrawElementsBaseVertex, (C.GLenum)(mode), (*C.GLsizei)(unsafe.Pointer(count)), (C.GLenum)(xtype), indices, (C.GLsizei)(drawcount), (*C.GLint)(unsafe.Pointer(basevertex)))\n}", "func drawMutated(m Mutator, s string) {\n\tnewString := m.mutate(s)\n\tfmt.Println(newString)\n}", "func (self *TileSprite) SetOffsetXA(member int) {\n self.Object.Set(\"offsetX\", member)\n}", "func (el *Fill) TSpan() {}", "func DrawRangeElementsBaseVertex(mode uint32, start uint32, end uint32, count int32, xtype uint32, indices unsafe.Pointer, basevertex int32) {\n\tC.glowDrawRangeElementsBaseVertex(gpDrawRangeElementsBaseVertex, (C.GLenum)(mode), (C.GLuint)(start), (C.GLuint)(end), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLint)(basevertex))\n}", "func DrawRangeElementsBaseVertex(mode uint32, start uint32, end uint32, count int32, xtype uint32, indices unsafe.Pointer, basevertex int32) {\n\tC.glowDrawRangeElementsBaseVertex(gpDrawRangeElementsBaseVertex, (C.GLenum)(mode), (C.GLuint)(start), (C.GLuint)(end), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLint)(basevertex))\n}", "func (r *renderer) Spacing() int { return 0 }", "func update(pg *page.Page) {\n\tpg.Root.Iterate(func(b *page.Bubble) {\n\t\tfor i := 0; i < len(b.Children); i++ {\n\t\t\tfor j := 0; j < len(b.Children); j++ {\n\t\t\t\tb.Children[j].Iterate(func(nibling *page.Bubble) {\n\t\t\t\t\tif page.Distance(b.Children[i], nibling) < float64(30*(b.Children[i].Height+nibling.Height)+85) &&\n\t\t\t\t\t\tb.Children[i] != pg.Grabbed && nibling != pg.Grabbed && i != j {\n\t\t\t\t\t\tdx := 0\n\t\t\t\t\t\tdy := 0\n\t\t\t\t\t\tfor dx*dy == 0 {\n\t\t\t\t\t\t\tdx = int(2*math.Atan(float64(b.Children[i].X-nibling.X))) + page.Random(-2, 2)\n\t\t\t\t\t\t\tdy = int(2*math.Atan(float64(b.Children[i].Y-nibling.Y))) + page.Random(-2, 2)\n\t\t\t\t\t\t}\n\t\t\t\t\t\tb.Children[i].X += dx\n\t\t\t\t\t\tb.Children[i].Y += dy\n\t\t\t\t\t\tnibling.X -= dx\n\t\t\t\t\t\tnibling.Y -= dy\n\t\t\t\t\t}\n\t\t\t\t})\n\t\t\t}\n\t\t}\n\t\tif len(b.Children) == 1 {\n\t\t\tb.CenterAroundChildren()\n\t\t}\n\t})\n}", "func (self *Rectangle) OffsetPoint(point *Point) *Rectangle{\n return &Rectangle{self.Object.Call(\"offsetPoint\", point)}\n}", "func (el *Fill) Rect() {}", "func Point(children ...Element) *CompoundElement { return newCE(\"Point\", children) }", "func (f *YFastBilateral) offset(size ...int) (n int) {\n\tn = size[0] // x\n\tfor i, v := range size[1:] {\n\t\tn += v * xmath.Mul(f.size[0:i+1]...) // y, z\n\t}\n\treturn\n}", "func (self *Graphics) SetXA(member int) {\n self.Object.Set(\"x\", member)\n}", "func drawGrid(pdf *gofpdf.Fpdf) {\n w, h := pdf.GetPageSize()\n pdf.SetFont(\"courier\", \"\", 12)\n pdf.SetTextColor(80, 80, 80)\n pdf.SetDrawColor(200, 200, 200)\n for x := 0.0; x < w; x = x + (w / 20.0) {\n pdf.SetTextColor(200, 200, 200)\n pdf.Line(x, 0, x, h)\n _, lineHt := pdf.GetFontSize()\n pdf.Text(x, lineHt, fmt.Sprintf(\"%d\", int(x)))\n }\n for y := 0.0; y < h; y = y + (w / 20.0) {\n pdf.SetTextColor(80, 80, 80)\n pdf.Line(0, y, w, y)\n pdf.Text(0, y, fmt.Sprintf(\"%d\", int(y)))\n }\n}", "func (p pawns) arrange(start, end render.Point) {\n\t// TODO: Rotate the sprite to match the angle of the line or compute the across of the sprite at that angle\n\ttotalPawnWidth := len(p) * 128\n\tspacer := (start.Dist(end) - float64(totalPawnWidth)) / float64(len(p)+1)\n\tfor _, pawn := range p {\n\t\tstart = start.AddVec(spacer, end)\n\t\tpawn.sprite.Translate(start.X, start.Y)\n\t\tstart = start.AddVec(128, end)\n\t}\n}", "func (self *Rectangle) OffsetPointI(args ...interface{}) *Rectangle{\n return &Rectangle{self.Object.Call(\"offsetPoint\", args)}\n}", "func draw(window *sdl.Window, renderer *sdl.Renderer, grid [][]*square) {\n\trenderer.Clear()\n\trenderer.SetDrawColor(255, 255, 255, 1) // white\n\trenderer.FillRect(&sdl.Rect{0, 0, size, size})\n\n\tfor _, row := range grid {\n\t\tfor _, square := range row {\n\t\t\tsquare.drawSquare(renderer)\n\t\t}\n\t}\n\n\tdrawGrid(renderer)\n\trenderer.Present()\n}", "func drawProbs(w *world.World, locs []*world.Loc, probs []float64, name string, i int) {\n\tout, err := os.Create(fmt.Sprintf(\"%s-%d-%d.png\", name, *seed, i))\n\tif err != nil {\n\t\tpanic(err)\n\t}\n\tdefer out.Close()\n\n\tps := make([]float64, w.W*w.H)\n\tmx := 0.0\n\tfor i, l := range locs {\n\t\tps[l.X*w.H+l.Y] = probs[i]\n\t\tif probs[i] > mx {\n\t\t\tmx = probs[i]\n\t\t}\n\t}\n\tpng.Encode(out, &worldImg{w, ps, mx})\n}", "func (el *Fill) Set() {}", "func lattice(xp, yp, w, h, size, hspace, vspace, n int, bgcolor string) {\n\tif bgcolor == \"\" {\n\t\tcanvas.Rect(0, 0, w, h, randcolor())\n\t} else {\n\t\tcanvas.Rect(0, 0, w, h, \"fill:\"+bgcolor)\n\t}\n\ty := yp\n\tfor r := 0; r < n; r++ {\n\t\tfor x := xp; x < w; x += hspace {\n\t\t\trcube(x, y, size)\n\t\t}\n\t\ty += vspace\n\t}\n}", "func addDraw(home, away *team) {\n\thome.played++\n\taway.played++\n\thome.draw++\n\taway.draw++\n\thome.points++\n\taway.points++\n}", "func (gl *WebGL) DrawElements(mode GLEnum, count int, valueType GLEnum, offset int) {\n\tgl.context.Call(\"drawElements\", mode, count, valueType, offset)\n}", "func withDraw(users []*sentinel.UserReq) {\n\tvar done sync.WaitGroup\n\n\tfor _, u := range users {\n\t\tdone.Add(1)\n\t\tgo func(u *sentinel.UserReq) {\n\t\t\tdefer done.Done()\n\n\t\t\tif err := u.WithDraw(); err != nil {\n\t\t\t\tlog.Error(0, \"u.withDraw() returns error %v\", err)\n\t\t\t}\n\t\t}(u)\n\t}\n\n\tdone.Wait()\n}", "func MultiDrawArraysIndirect(mode uint32, indirect unsafe.Pointer, drawcount int32, stride int32) {\n\tsyscall.Syscall6(gpMultiDrawArraysIndirect, 4, uintptr(mode), uintptr(indirect), uintptr(drawcount), uintptr(stride), 0, 0)\n}" ]
[ "0.61038804", "0.6086155", "0.5807149", "0.5807149", "0.57068485", "0.5668647", "0.5624247", "0.56164867", "0.5479857", "0.5477363", "0.5458208", "0.544725", "0.5401758", "0.53967667", "0.5380434", "0.5312088", "0.52309155", "0.52130467", "0.52130467", "0.51633734", "0.51633734", "0.5152116", "0.5143897", "0.5143897", "0.51018816", "0.5089891", "0.5073716", "0.505179", "0.5028259", "0.5028115", "0.49941477", "0.4953354", "0.4948658", "0.4948658", "0.4939171", "0.48906383", "0.48878062", "0.48878062", "0.48873293", "0.48749208", "0.48532614", "0.4847906", "0.4835423", "0.48315108", "0.48315108", "0.4763509", "0.4763509", "0.47480795", "0.47415197", "0.47344506", "0.46959955", "0.46678147", "0.4654372", "0.4624696", "0.46199456", "0.46055987", "0.46055987", "0.45996642", "0.45996642", "0.45887828", "0.45874634", "0.4580652", "0.45629215", "0.45517573", "0.45433837", "0.4542444", "0.45414487", "0.452531", "0.45177162", "0.44975454", "0.44691253", "0.4459799", "0.44576392", "0.44575348", "0.44546816", "0.445178", "0.44368646", "0.4431094", "0.44294205", "0.4428283", "0.4428283", "0.44239467", "0.43992838", "0.43942603", "0.43923202", "0.43872294", "0.437943", "0.4370412", "0.43614295", "0.4359973", "0.43554354", "0.43481094", "0.43364537", "0.43201298", "0.43062818", "0.43021786", "0.42915976", "0.42850667", "0.42849624" ]
0.5248834
17
render multiple instances of a set of primitives from array data with a perelement offset
func DrawElementsInstancedBaseVertex(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32, basevertex int32) { C.glowDrawElementsInstancedBaseVertex(gpDrawElementsInstancedBaseVertex, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLsizei)(instancecount), (C.GLint)(basevertex)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func (native *OpenGL) DrawElementsOffset(mode uint32, count int32, elementType uint32, offset int) {\n\tgl.DrawElements(mode, count, elementType, gl.PtrOffset(offset))\n}", "func MultiDrawElements(mode uint32, count *int32, xtype uint32, indices *unsafe.Pointer, drawcount int32) {\n\tsyscall.Syscall6(gpMultiDrawElements, 5, uintptr(mode), uintptr(unsafe.Pointer(count)), uintptr(xtype), uintptr(unsafe.Pointer(indices)), uintptr(drawcount), 0)\n}", "func DrawRangeElements(mode uint32, start uint32, end uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n\tsyscall.Syscall6(gpDrawRangeElements, 6, uintptr(mode), uintptr(start), uintptr(end), uintptr(count), uintptr(xtype), uintptr(indices))\n}", "func DrawElements(mode uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n\tsyscall.Syscall6(gpDrawElements, 4, uintptr(mode), uintptr(count), uintptr(xtype), uintptr(indices), 0, 0)\n}", "func DrawRangeElements(mode uint32, start uint32, end uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n C.glowDrawRangeElements(gpDrawRangeElements, (C.GLenum)(mode), (C.GLuint)(start), (C.GLuint)(end), (C.GLsizei)(count), (C.GLenum)(xtype), indices)\n}", "func MultiDrawElementsIndirect(mode uint32, xtype uint32, indirect unsafe.Pointer, drawcount int32, stride int32) {\n\tsyscall.Syscall6(gpMultiDrawElementsIndirect, 5, uintptr(mode), uintptr(xtype), uintptr(indirect), uintptr(drawcount), uintptr(stride), 0)\n}", "func MultiDrawElements(mode uint32, count *int32, xtype uint32, indices *unsafe.Pointer, drawcount int32) {\n C.glowMultiDrawElements(gpMultiDrawElements, (C.GLenum)(mode), (*C.GLsizei)(unsafe.Pointer(count)), (C.GLenum)(xtype), indices, (C.GLsizei)(drawcount))\n}", "func DrawElements(mode uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n C.glowDrawElements(gpDrawElements, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices)\n}", "func DrawElementsInstanced(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32) {\n C.glowDrawElementsInstanced(gpDrawElementsInstanced, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLsizei)(instancecount))\n}", "func DrawElements(mode Enum, count int, ty Enum, offset int) {\n\tgl.DrawElements(uint32(mode), int32(count), uint32(ty), gl.PtrOffset(offset))\n}", "func iterateObjects1DWithIndexes() {\n\tfmt.Println(\"*** iterateObjects1DWithIndexes\")\n\n\ttype Point struct {\n\t\tX int\n\t\tY int\n\t}\n\tpoints := [5]Point{\n\t\tPoint{1, 1},\n\t\tPoint{2, 2},\n\t\tPoint{3, 3},\n\t\tPoint{4, 4},\n\t\tPoint{5, 5},\n\t}\n\n\tfor i, e := range points {\n\t\tfmt.Printf(\"ints[%d]: %+v\\n\", i, e)\n\t}\n\tfmt.Println(\"\")\n}", "func DrawRangeElements(mode uint32, start uint32, end uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n\tC.glowDrawRangeElements(gpDrawRangeElements, (C.GLenum)(mode), (C.GLuint)(start), (C.GLuint)(end), (C.GLsizei)(count), (C.GLenum)(xtype), indices)\n}", "func DrawRangeElements(mode uint32, start uint32, end uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n\tC.glowDrawRangeElements(gpDrawRangeElements, (C.GLenum)(mode), (C.GLuint)(start), (C.GLuint)(end), (C.GLsizei)(count), (C.GLenum)(xtype), indices)\n}", "func MultiDrawElementsIndirect(mode uint32, xtype uint32, indirect unsafe.Pointer, drawcount int32, stride int32) {\n C.glowMultiDrawElementsIndirect(gpMultiDrawElementsIndirect, (C.GLenum)(mode), (C.GLenum)(xtype), indirect, (C.GLsizei)(drawcount), (C.GLsizei)(stride))\n}", "func MultiDrawElements(mode uint32, count *int32, xtype uint32, indices *unsafe.Pointer, drawcount int32) {\n\tC.glowMultiDrawElements(gpMultiDrawElements, (C.GLenum)(mode), (*C.GLsizei)(unsafe.Pointer(count)), (C.GLenum)(xtype), indices, (C.GLsizei)(drawcount))\n}", "func MultiDrawElements(mode uint32, count *int32, xtype uint32, indices *unsafe.Pointer, drawcount int32) {\n\tC.glowMultiDrawElements(gpMultiDrawElements, (C.GLenum)(mode), (*C.GLsizei)(unsafe.Pointer(count)), (C.GLenum)(xtype), indices, (C.GLsizei)(drawcount))\n}", "func (native *OpenGL) DrawElements(mode uint32, count int32, elementType uint32, indices uintptr) {\n\tgl.DrawElements(mode, count, elementType, unsafe.Pointer(indices)) // nolint: govet,gas\n}", "func renderResults(vals []interface{}) Data {\n\tvar nilcount int\n\tvar obj interface{}\n\tfor _, val := range vals {\n\t\tswitch val.(type) {\n\t\tcase image.Image, Data:\n\t\t\tobj = val\n\t\tcase nil:\n\t\t\tnilcount++\n\t\t}\n\t}\n\tif obj != nil && nilcount == len(vals)-1 {\n\t\tswitch val := obj.(type) {\n\t\tcase image.Image:\n\t\t\tdata, err := image0(val)\n\t\t\tif err == nil {\n\t\t\t\treturn data\n\t\t\t}\n\t\tcase Data:\n\t\t\treturn val\n\t\t}\n\t}\n\tif nilcount == len(vals) {\n\t\t// if all values are nil, return empty Data\n\t\treturn Data{}\n\t}\n\treturn MakeData(\"text/plain\", fmt.Sprint(vals...))\n}", "func (self *Tween) GenerateData() []interface{}{\n\tarray00 := self.Object.Call(\"generateData\")\n\tlength00 := array00.Length()\n\tout00 := make([]interface{}, length00, length00)\n\tfor i00 := 0; i00 < length00; i00++ {\n\t\tout00[i00] = array00.Index(i00)\n\t}\n\treturn out00\n}", "func main() {\n\t//composite literal - create different values of a type\n\t// x := type{values}\n\t//group together values OF THE SAME TYPE\n\tx := []int{4, 5, 7, 8, 42}\n\n\tfmt.Println(x)\n\tfmt.Println(x[0]) //query by index position\n\tfmt.Println(x[1])\n\tfmt.Println(x[2])\n\tfmt.Println(x[3])\n\tfmt.Println(x[4])\n\tfmt.Println(cap(x))\n\n\t//for index and value in the range of x print\n\tfor i, v := range x {\n\t\tfmt.Println(i, v)\n\t}\n}", "func DrawElementsIndirect(mode uint32, xtype uint32, indirect unsafe.Pointer) {\n\tsyscall.Syscall(gpDrawElementsIndirect, 3, uintptr(mode), uintptr(xtype), uintptr(indirect))\n}", "func PrintDataSlice(data interface{}) {\n\td := reflect.ValueOf(data)\n\n\tfor i := 0; i < d.Len(); i++ {\n\t\tdataItem := d.Index(i)\n\t\ttypeOfT := dataItem.Type()\n\n\t\tfor j := 0; j < dataItem.NumField(); j++ {\n\t\t\tf := dataItem.Field(j)\n\t\t\tfmt.Printf(\"%s: %v\\n\", typeOfT.Field(j).Name, f.Interface())\n\t\t}\n\t\tfmt.Printf(\"\\n\")\n\t}\n}", "func MultiDrawElementsIndirect(mode uint32, xtype uint32, indirect unsafe.Pointer, drawcount int32, stride int32) {\n\tC.glowMultiDrawElementsIndirect(gpMultiDrawElementsIndirect, (C.GLenum)(mode), (C.GLenum)(xtype), indirect, (C.GLsizei)(drawcount), (C.GLsizei)(stride))\n}", "func MultiDrawElementsIndirect(mode uint32, xtype uint32, indirect unsafe.Pointer, drawcount int32, stride int32) {\n\tC.glowMultiDrawElementsIndirect(gpMultiDrawElementsIndirect, (C.GLenum)(mode), (C.GLenum)(xtype), indirect, (C.GLsizei)(drawcount), (C.GLsizei)(stride))\n}", "func renderSliceOfTpls(tpls []string, values interface{}) ([]string, error) {\n\tres := []string{}\n\n\tfor _, fragment := range tpls {\n\t\tval, err := renderTpl(fragment, values)\n\t\tif err != nil {\n\t\t\treturn []string{}, err\n\t\t}\n\n\t\tres = append(res, val)\n\t}\n\n\treturn res, nil\n}", "func DrawElements(mode uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n\tC.glowDrawElements(gpDrawElements, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices)\n}", "func DrawElements(mode uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n\tC.glowDrawElements(gpDrawElements, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices)\n}", "func DrawElementsInstancedBaseVertex(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32, basevertex int32) {\n C.glowDrawElementsInstancedBaseVertex(gpDrawElementsInstancedBaseVertex, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLsizei)(instancecount), (C.GLint)(basevertex))\n}", "func (debugging *debuggingOpenGL) DrawElements(mode uint32, count int32, elementType uint32, indices uintptr) {\n\tdebugging.recordEntry(\"DrawElements\", mode, count, elementType, indices)\n\tdebugging.gl.DrawElements(mode, count, elementType, indices)\n\tdebugging.recordExit(\"DrawElements\")\n}", "func DrawElementsInstanced(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32) {\n\tC.glowDrawElementsInstanced(gpDrawElementsInstanced, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLsizei)(instancecount))\n}", "func DrawElementsInstanced(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32) {\n\tC.glowDrawElementsInstanced(gpDrawElementsInstanced, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLsizei)(instancecount))\n}", "func DrawElementsInstancedBaseVertex(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32, basevertex int32) {\n\tsyscall.Syscall6(gpDrawElementsInstancedBaseVertex, 6, uintptr(mode), uintptr(count), uintptr(xtype), uintptr(indices), uintptr(instancecount), uintptr(basevertex))\n}", "func DrawArraysInstanced(mode uint32, first int32, count int32, instancecount int32) {\n C.glowDrawArraysInstanced(gpDrawArraysInstanced, (C.GLenum)(mode), (C.GLint)(first), (C.GLsizei)(count), (C.GLsizei)(instancecount))\n}", "func DrawRangeElementsBaseVertex(mode uint32, start uint32, end uint32, count int32, xtype uint32, indices unsafe.Pointer, basevertex int32) {\n\tsyscall.Syscall9(gpDrawRangeElementsBaseVertex, 7, uintptr(mode), uintptr(start), uintptr(end), uintptr(count), uintptr(xtype), uintptr(indices), uintptr(basevertex), 0, 0)\n}", "func (w wireFormat) MapBySlice() {}", "func (r *Renderer) Render() {\n\tsx, sz, sy := r.c.Bounds()\n\tsxf := float64(sx - 1)\n\tsyf := float64(sy - 1)\n\tszf := float64(sz - 1)\n\tfor z := 0; z < sz; z++ {\n\t\tfor y := 0; y < sy; y++ {\n\t\t\tfor x := 0; x < sx; x++ {\n\t\t\t\tvar lr, lg, lb, _ uint32\n\t\t\t\tn := uint32(0)\n\t\t\t\tfor _, o := range r.objects {\n\t\t\t\t\tr, g, b, _ := o.At(float64(x)/sxf, float64(y)/syf, float64(z)/szf).RGBA()\n\t\t\t\t\tlr += r >> 8\n\t\t\t\t\tlg += g >> 8\n\t\t\t\t\tlb += b >> 8\n\t\t\t\t\tn++\n\t\t\t\t}\n\t\t\t\tr.c.Set(x, y, z, color.RGBA{uint8(lr/n), uint8(lg/n), uint8(lb/n), 255})\n\t\t\t}\n\t\t}\n\t}\n\tr.c.Render()\n}", "func DrawRangeElementsBaseVertex(mode uint32, start uint32, end uint32, count int32, xtype uint32, indices unsafe.Pointer, basevertex int32) {\n C.glowDrawRangeElementsBaseVertex(gpDrawRangeElementsBaseVertex, (C.GLenum)(mode), (C.GLuint)(start), (C.GLuint)(end), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLint)(basevertex))\n}", "func (self *Tween) GenerateDataI(args ...interface{}) []interface{}{\n\tarray00 := self.Object.Call(\"generateData\", args)\n\tlength00 := array00.Length()\n\tout00 := make([]interface{}, length00, length00)\n\tfor i00 := 0; i00 < length00; i00++ {\n\t\tout00[i00] = array00.Index(i00)\n\t}\n\treturn out00\n}", "func DrawElementsInstancedBaseInstance(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32, baseinstance uint32) {\n C.glowDrawElementsInstancedBaseInstance(gpDrawElementsInstancedBaseInstance, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLsizei)(instancecount), (C.GLuint)(baseinstance))\n}", "func makeSlice(offset dvid.Point3d, size dvid.Point2d) []byte {\n\tnumBytes := size[0] * size[1] * 8\n\tslice := make([]byte, numBytes, numBytes)\n\ti := 0\n\tmodz := offset[2] % int32(len(zdata))\n\tfor y := int32(0); y < size[1]; y++ {\n\t\tsy := y + offset[1]\n\t\tmody := sy % int32(len(ydata))\n\t\tsx := offset[0]\n\t\tfor x := int32(0); x < size[0]; x++ {\n\t\t\tmodx := sx % int32(len(xdata))\n\t\t\tbinary.BigEndian.PutUint64(slice[i:i+8], xdata[modx]+ydata[mody]+zdata[modz])\n\t\t\ti += 8\n\t\t\tsx++\n\t\t}\n\t}\n\treturn slice\n}", "func MultiDrawElementsBaseVertex(mode uint32, count *int32, xtype uint32, indices *unsafe.Pointer, drawcount int32, basevertex *int32) {\n\tsyscall.Syscall6(gpMultiDrawElementsBaseVertex, 6, uintptr(mode), uintptr(unsafe.Pointer(count)), uintptr(xtype), uintptr(unsafe.Pointer(indices)), uintptr(drawcount), uintptr(unsafe.Pointer(basevertex)))\n}", "func (t *Dense) slice(start, end int) {\n\tswitch t.t.Kind() {\n\tcase reflect.Bool:\n\t\tdata := t.bools()[start:end]\n\t\tt.fromSlice(data)\n\tcase reflect.Int:\n\t\tdata := t.ints()[start:end]\n\t\tt.fromSlice(data)\n\tcase reflect.Int8:\n\t\tdata := t.int8s()[start:end]\n\t\tt.fromSlice(data)\n\tcase reflect.Int16:\n\t\tdata := t.int16s()[start:end]\n\t\tt.fromSlice(data)\n\tcase reflect.Int32:\n\t\tdata := t.int32s()[start:end]\n\t\tt.fromSlice(data)\n\tcase reflect.Int64:\n\t\tdata := t.int64s()[start:end]\n\t\tt.fromSlice(data)\n\tcase reflect.Uint:\n\t\tdata := t.uints()[start:end]\n\t\tt.fromSlice(data)\n\tcase reflect.Uint8:\n\t\tdata := t.uint8s()[start:end]\n\t\tt.fromSlice(data)\n\tcase reflect.Uint16:\n\t\tdata := t.uint16s()[start:end]\n\t\tt.fromSlice(data)\n\tcase reflect.Uint32:\n\t\tdata := t.uint32s()[start:end]\n\t\tt.fromSlice(data)\n\tcase reflect.Uint64:\n\t\tdata := t.uint64s()[start:end]\n\t\tt.fromSlice(data)\n\tcase reflect.Uintptr:\n\t\tdata := t.uintptrs()[start:end]\n\t\tt.fromSlice(data)\n\tcase reflect.Float32:\n\t\tdata := t.float32s()[start:end]\n\t\tt.fromSlice(data)\n\tcase reflect.Float64:\n\t\tdata := t.float64s()[start:end]\n\t\tt.fromSlice(data)\n\tcase reflect.Complex64:\n\t\tdata := t.complex64s()[start:end]\n\t\tt.fromSlice(data)\n\tcase reflect.Complex128:\n\t\tdata := t.complex128s()[start:end]\n\t\tt.fromSlice(data)\n\n\tcase reflect.String:\n\t\tdata := t.strings()[start:end]\n\t\tt.fromSlice(data)\n\n\tcase reflect.UnsafePointer:\n\t\tdata := t.unsafePointers()[start:end]\n\t\tt.fromSlice(data)\n\tdefault:\n\t\tv := reflect.ValueOf(t.v)\n\t\tv = v.Slice(start, end)\n\t\tt.fromSlice(v.Interface())\n\t}\n}", "func (cont *tuiApplicationController) drawView() {\n\tcont.Sync.Lock()\n\tif !cont.Changed || cont.TuiFileReaderWorker == nil {\n\t\tcont.Sync.Unlock()\n\t\treturn\n\t}\n\tcont.Sync.Unlock()\n\n\t// reset the elements by clearing out every one\n\ttviewApplication.QueueUpdateDraw(func() {\n\t\tfor _, t := range displayResults {\n\t\t\tt.Title.SetText(\"\")\n\t\t\tt.Body.SetText(\"\")\n\t\t\tt.SpacerOne.SetText(\"\")\n\t\t\tt.SpacerTwo.SetText(\"\")\n\t\t\tresultsFlex.ResizeItem(t.Body, 0, 0)\n\t\t}\n\t})\n\n\tcont.Sync.Lock()\n\tresultsCopy := make([]*FileJob, len(cont.Results))\n\tcopy(resultsCopy, cont.Results)\n\tcont.Sync.Unlock()\n\n\t// rank all results\n\t// then go and get the relevant portion for display\n\trankResults(int(cont.TuiFileReaderWorker.GetFileCount()), resultsCopy)\n\tdocumentTermFrequency := calculateDocumentTermFrequency(resultsCopy)\n\n\t// after ranking only get the details for as many as we actually need to\n\t// cut down on processing\n\tif len(resultsCopy) > len(displayResults) {\n\t\tresultsCopy = resultsCopy[:len(displayResults)]\n\t}\n\n\t// We use this to swap out the highlights after we escape to ensure that we don't escape\n\t// out own colours\n\tmd5Digest := md5.New()\n\tfmtBegin := hex.EncodeToString(md5Digest.Sum([]byte(fmt.Sprintf(\"begin_%d\", makeTimestampNano()))))\n\tfmtEnd := hex.EncodeToString(md5Digest.Sum([]byte(fmt.Sprintf(\"end_%d\", makeTimestampNano()))))\n\n\t// go and get the codeResults the user wants to see using selected as the offset to display from\n\tvar codeResults []codeResult\n\tfor i, res := range resultsCopy {\n\t\tif i >= cont.Offset {\n\t\t\tsnippets := extractRelevantV3(res, documentTermFrequency, int(SnippetLength), \"…\")[0]\n\n\t\t\t// now that we have the relevant portion we need to get just the bits related to highlight it correctly\n\t\t\t// which this method does. It takes in the snippet, we extract and all of the locations and then returns just\n\t\t\tl := getLocated(res, snippets)\n\t\t\tcoloredContent := str.HighlightString(snippets.Content, l, fmtBegin, fmtEnd)\n\t\t\tcoloredContent = tview.Escape(coloredContent)\n\n\t\t\tcoloredContent = strings.Replace(coloredContent, fmtBegin, \"[red]\", -1)\n\t\t\tcoloredContent = strings.Replace(coloredContent, fmtEnd, \"[white]\", -1)\n\n\t\t\tcodeResults = append(codeResults, codeResult{\n\t\t\t\tTitle: res.Location,\n\t\t\t\tContent: coloredContent,\n\t\t\t\tScore: res.Score,\n\t\t\t\tLocation: res.Location,\n\t\t\t})\n\t\t}\n\t}\n\n\t// render out what the user wants to see based on the results that have been chosen\n\ttviewApplication.QueueUpdateDraw(func() {\n\t\tfor i, t := range codeResults {\n\t\t\tdisplayResults[i].Title.SetText(fmt.Sprintf(\"[fuchsia]%s (%f)[-:-:-]\", t.Title, t.Score))\n\t\t\tdisplayResults[i].Body.SetText(t.Content)\n\t\t\tdisplayResults[i].Location = t.Location\n\n\t\t\t//we need to update the item so that it displays everything we have put in\n\t\t\tresultsFlex.ResizeItem(displayResults[i].Body, len(strings.Split(t.Content, \"\\n\")), 0)\n\t\t}\n\t})\n\n\t// we can only set that nothing\n\tcont.Changed = false\n}", "func GenerateShapes() {\r\n\t// Square\r\n\tShapes[0].vertices = []gl.GLfloat{-1, -1, 1, -1, -1, 1, 1, 1}\r\n\tShapes[0].elements = []gl.GLushort{0, 1, 2, 2, 3, 1}\r\n\r\n\t// ___|\r\n\tShapes[1].vertices = []gl.GLfloat{-2, 0, -2, -1, 2, -1, 2, 0, 2, 1, 1, 1, 1, 0}\r\n\tShapes[1].elements = []gl.GLushort{0, 1, 2, 2, 3, 0, 3, 4, 5, 5, 6, 3}\r\n\r\n\t// _|_\r\n\tShapes[2].vertices = []gl.GLfloat{-1.5, 0, -0.5, 0, -0.5, 1, 0.5, 1, 0.5, 0, 1.5, 0, 1.5, -1, -1.5, -1}\r\n\tShapes[2].elements = []gl.GLushort{1, 2, 3, 3, 4, 1, 0, 7, 6, 6, 0, 5}\r\n\r\n\t// Snake\r\n\tShapes[3].vertices = []gl.GLfloat{-1.5, -1, -1.5, 0, -0.5, 0, -0.5, 1, 1.5, 1, 1.5, 0, 0.5, 0, 0.5, -1}\r\n\tShapes[3].elements = []gl.GLushort{0, 1, 6, 6, 7, 0, 2, 3, 4, 4, 5, 2}\r\n\r\n\t// Now fill out the rest automatically.\r\n\t// FIXME why doesn't using _, shape in this loop work ?\r\n\tfor i := range Shapes {\r\n\t\tShapes[i].vao = gl.GenVertexArray()\r\n\t\tShapes[i].vao.Bind()\r\n\t\tShapes[i].vbo = gl.GenBuffer()\r\n\t\tShapes[i].vbo.Bind(gl.ARRAY_BUFFER)\r\n\t\tgl.BufferData(gl.ARRAY_BUFFER, len(Shapes[i].vertices)*4, Shapes[i].vertices, gl.STATIC_DRAW)\r\n\t\tShapes[i].elementBuffer = gl.GenBuffer()\r\n\t\tShapes[i].elementBuffer.Bind(gl.ELEMENT_ARRAY_BUFFER)\r\n\t\tgl.BufferData(gl.ELEMENT_ARRAY_BUFFER, len(Shapes[i].elements)*2, Shapes[i].elements, gl.STATIC_DRAW)\r\n\t\tShapes[i].numElements = len(Shapes[i].elements)\r\n\r\n\t\tvertexAttribArray := shaderProgram.GetAttribLocation(\"position\")\r\n\t\tvertexAttribArray.AttribPointer(2, gl.FLOAT, false, 0, uintptr(0))\r\n\t\tvertexAttribArray.EnableArray()\r\n\t}\r\n}", "func DrawElementsIndirect(mode uint32, xtype uint32, indirect unsafe.Pointer) {\n C.glowDrawElementsIndirect(gpDrawElementsIndirect, (C.GLenum)(mode), (C.GLenum)(xtype), indirect)\n}", "func (s *Slicer) RenderXSlices(materialNum int, sp XSliceProcessor, order Order) error {\n\tnumSlices := int(0.5 + (s.irmf.Max[0]-s.irmf.Min[0])/s.deltaX)\n\tvoxelRadiusX := 0.5 * s.deltaX\n\tminVal := s.irmf.Min[0] + voxelRadiusX\n\n\tvar xFunc func(n int) float32\n\n\tswitch order {\n\tcase MinToMax:\n\t\txFunc = func(n int) float32 {\n\t\t\treturn minVal + float32(n)*s.deltaX\n\t\t}\n\tcase MaxToMin:\n\t\txFunc = func(n int) float32 {\n\t\t\treturn minVal + float32(numSlices-n-1)*s.deltaX\n\t\t}\n\t}\n\n\t// log.Printf(\"RenderXSlices: numSlices=%v, startVal=%v, endVal=%v, delta=%v\", numSlices, xFunc(0), xFunc(numSlices-1), s.delta)\n\n\tfor n := 0; n < numSlices; n++ {\n\t\tx := xFunc(n)\n\n\t\timg, err := s.renderSlice(x, materialNum)\n\t\tif err != nil {\n\t\t\treturn fmt.Errorf(\"renderXSlice(%v,%v): %v\", x, materialNum, err)\n\t\t}\n\t\tif err := sp.ProcessXSlice(n, x, voxelRadiusX, img); err != nil {\n\t\t\treturn fmt.Errorf(\"ProcessSlice(%v,%v,%v): %v\", n, x, voxelRadiusX, err)\n\t\t}\n\t}\n\treturn nil\n}", "func (obj *Device) DrawIndexedPrimitiveUP(\n\ttyp PRIMITIVETYPE,\n\tminVertexIndex uint,\n\tnumVertices uint,\n\tprimitiveCount uint,\n\tindexData uintptr,\n\tindexDataFormat FORMAT,\n\tvertexStreamZeroData uintptr,\n\tvertexStreamZeroStride uint,\n) Error {\n\tret, _, _ := syscall.Syscall9(\n\t\tobj.vtbl.DrawIndexedPrimitiveUP,\n\t\t9,\n\t\tuintptr(unsafe.Pointer(obj)),\n\t\tuintptr(typ),\n\t\tuintptr(minVertexIndex),\n\t\tuintptr(numVertices),\n\t\tuintptr(primitiveCount),\n\t\tindexData,\n\t\tuintptr(indexDataFormat),\n\t\tvertexStreamZeroData,\n\t\tuintptr(vertexStreamZeroStride),\n\t)\n\treturn toErr(ret)\n}", "func (f *ParticleRenderFeature) Extract(v *gfx.View) {\n\tfor i, m := range f.et.comps[:f.et.index] {\n\t\tsid := gfx.PackSortId(m.zOrder, 0)\n\t\tv.RenderNodes = append(v.RenderNodes, gfx.SortObject{sid, uint32(i)})\n\t}\n}", "func (c *Client) ShowArrayPrism(ctx context.Context, path string, anyArray []interface{}, boolArray []bool, dateTimeArray []time.Time, intArray []int, numArray []float64, stringArray []string, uuidArray []uuid.UUID) (*http.Response, error) {\n\treq, err := c.NewShowArrayPrismRequest(ctx, path, anyArray, boolArray, dateTimeArray, intArray, numArray, stringArray, uuidArray)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\treturn c.Client.Do(ctx, req)\n}", "func (gl *WebGL) DrawElements(mode GLEnum, count int, valueType GLEnum, offset int) {\n\tgl.context.Call(\"drawElements\", mode, count, valueType, offset)\n}", "func DrawElementsInstancedBaseInstance(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32, baseinstance uint32) {\n\tsyscall.Syscall6(gpDrawElementsInstancedBaseInstance, 6, uintptr(mode), uintptr(count), uintptr(xtype), uintptr(indices), uintptr(instancecount), uintptr(baseinstance))\n}", "func NewPageBuffer(aSlice interface{}, desiredPageNo int) *PageBuffer {\n return newPageBuffer(\n sliceValue(aSlice, false),\n desiredPageNo,\n valueHandler{})\n}", "func (w Widget) Buffer() []termui.Point {\n\tvar wrappedWidget uiWidget\n\n\twrapperHeight := w.Height - 3\n\tif w.Error() != nil && !w.shouldIgnoreError() {\n\t\ttextWidget := termui.NewPar(fmt.Sprintf(\"Error: %v\", w.Error().Error()))\n\t\ttextWidget.Height = wrapperHeight\n\t\ttextWidget.HasBorder = false\n\n\t\twrappedWidget = textWidget\n\t} else if !w.Ready {\n\t\ttextWidget := termui.NewPar(\"Loading entries, please wait...\")\n\t\ttextWidget.Height = wrapperHeight\n\t\ttextWidget.HasBorder = false\n\n\t\twrappedWidget = textWidget\n\t} else {\n\t\tlistWidget := termui.NewList()\n\t\tlistWidget.Height = wrapperHeight\n\t\tlistWidget.HasBorder = false\n\n\t\titems := make([]string, w.EntriesToDisplay())\n\n\t\t// addtional width: width that needs to be added so that they're\n\t\t// formatted properly.\n\t\taddWidth := int(math.Log10(float64(w.EntriesToDisplay()))) + 1\n\t\tfor i := 0; i < w.EntriesToDisplay() && i < len(w.EntryOrder); i++ {\n\t\t\tentryID := w.EntryOrder[i]\n\t\t\tentry, hasEntry := w.Entries[entryID]\n\n\t\t\tvar message string\n\t\t\tif hasEntry {\n\t\t\t\tmessage = entry.String()\n\t\t\t} else {\n\t\t\t\tmessage = \"Loading, please wait\"\n\t\t\t}\n\n\t\t\tdwidth := int(math.Log10(float64(i+1))) + 1\n\t\t\twidth := strconv.Itoa(addWidth - dwidth)\n\t\t\tf := strings.Replace(\"[%v]%{width}v %v...\", \"{width}\", width, 1)\n\t\t\titems[i] = fmt.Sprintf(f, i+1, \"\", message)\n\t\t}\n\n\t\tlistWidget.Items = items\n\t\twrappedWidget = listWidget\n\t}\n\n\twrappedWidget.SetWidth(w.Width - 4)\n\twrappedWidget.SetX(w.X + 2)\n\twrappedWidget.SetY(w.Y + 1)\n\n\tw.Border.Label = fmt.Sprintf(\"Hacker News (%v)\", w.Type.String())\n\tbuffer := append(w.Block.Buffer(), wrappedWidget.Buffer()...)\n\n\treturn buffer\n}", "func DrawElements(mode GLenum, count int, typ GLenum, indices interface{}) {\n\tC.glDrawElements(C.GLenum(mode), C.GLsizei(count), C.GLenum(typ),\n\t\tptr(indices))\n}", "func renderAllInlineElements(ctx *renderer.Context, elements []types.InlineElements) ([]byte, error) {\n\tbuff := bytes.NewBuffer(nil)\n\tfor i, e := range elements {\n\t\trenderedElement, err := renderElement(ctx, e)\n\t\tif err != nil {\n\t\t\treturn nil, errors.Wrap(err, \"unable to render element\")\n\t\t}\n\t\tif len(renderedElement) > 0 {\n\t\t\tbuff.Write(renderedElement)\n\t\t\tif len(renderedElement) > 0 && i < len(elements)-1 {\n\t\t\t\tlog.Debugf(\"rendered element of type %T is not the last one\", e)\n\t\t\t\tbuff.WriteString(\"\\n\")\n\t\t\t}\n\t\t}\n\t}\n\treturn buff.Bytes(), nil\n}", "func DrawArrays(mode uint32, first int32, count int32) {\n\tsyscall.Syscall(gpDrawArrays, 3, uintptr(mode), uintptr(first), uintptr(count))\n}", "func MultiDrawArraysIndirect(mode uint32, indirect unsafe.Pointer, drawcount int32, stride int32) {\n\tsyscall.Syscall6(gpMultiDrawArraysIndirect, 4, uintptr(mode), uintptr(indirect), uintptr(drawcount), uintptr(stride), 0, 0)\n}", "func (l LogItems) Render(showTime bool, ll [][]byte) {\n\tcolors := make(map[string]int, len(l))\n\tfor i, item := range l {\n\t\tinfo := item.ID()\n\t\tcolor, ok := colors[info]\n\t\tif !ok {\n\t\t\tcolor = colorFor(info)\n\t\t\tcolors[info] = color\n\t\t}\n\t\tll[i] = item.Render(color, showTime)\n\t}\n}", "func MultiDrawElementsBaseVertex(mode uint32, count *int32, xtype uint32, indices *unsafe.Pointer, drawcount int32, basevertex *int32) {\n C.glowMultiDrawElementsBaseVertex(gpMultiDrawElementsBaseVertex, (C.GLenum)(mode), (*C.GLsizei)(unsafe.Pointer(count)), (C.GLenum)(xtype), indices, (C.GLsizei)(drawcount), (*C.GLint)(unsafe.Pointer(basevertex)))\n}", "func RenderList(w http.ResponseWriter, r *http.Request, l []Renderer) error {\n\tfor _, v := range l {\n\t\tif err := renderer(w, r, v); err != nil {\n\t\t\treturn err\n\t\t}\n\t}\n\tRespond(w, r, l)\n\treturn nil\n}", "func DrawArraysInstancedBaseInstance(mode uint32, first int32, count int32, instancecount int32, baseinstance uint32) {\n C.glowDrawArraysInstancedBaseInstance(gpDrawArraysInstancedBaseInstance, (C.GLenum)(mode), (C.GLint)(first), (C.GLsizei)(count), (C.GLsizei)(instancecount), (C.GLuint)(baseinstance))\n}", "func plotdata(deck *generate.Deck, left, right, top, bottom float64, x []float64, y []float64, size float64, color string) {\n\tif len(x) != len(y) {\n\t\treturn\n\t}\n\tminx, maxx := extrema(x)\n\tminy, maxy := extrema(y)\n\n\tix := left\n\tiy := bottom\n\tfor i := 0; i < len(x); i++ {\n\t\txp := vmap(x[i], minx, maxx, left, right)\n\t\typ := vmap(y[i], miny, maxy, bottom, top)\n\t\tdeck.Circle(xp, yp, size, color)\n\t\tdeck.Line(ix, iy, xp, yp, 0.2, color)\n\t\tix = xp\n\t\tiy = yp\n\t}\n}", "func Interpret(data []byte, offset int) []byte {\n\tb:=make([]byte, len(data) * 2)\n\n\tfor i:=0; i<len(data); i++ {\n\t\tb[offset + i * 2] = hex_ascii[ (data[i] & 0XF0) >> 4]\n\t\tb[offset + i * 2 + 1] = hex_ascii[data[i] & 0x0F]\n\t}\n\treturn b\n}", "func (array *Array) Map(f func(interface{}, int) interface{}) *Array {\n\tnewArray := NewArray()\n\tfor index, object := range array.data {\n\t\tnewArray.Add(f(object, index))\n\t}\n\treturn newArray\n}", "func sliceEncoder(e *encodeState, v reflect.Value) error {\n\tsz := e.size\n\n\tlength := v.Len()\n\n\t// short circuit if length is 0\n\tif length == 0 {\n\t\treturn nil\n\t}\n\n\twidth := int(math.Ceil(math.Sqrt(float64(length))))\n\tcellSz := sz / float64(width)\n\tcellPt := 1 / float64(width)\n\n\tx := 0\n\ty := 0\n\tg := e.Group.Group()\n\tfor i := 0; i < length; i++ {\n\t\txF := float64(x) * cellSz\n\t\tyF := float64(y) * cellSz\n\t\ts := g.Group()\n\t\ts.Transform.Translate(xF, yF)\n\t\ts.Transform.Scale(cellPt, cellPt)\n\n\t\tenc := &encodeState{\n\t\t\tGroup: s,\n\t\t\tsize: sz,\n\t\t}\n\n\t\terrMarshal := enc.marshal(v.Index(i))\n\t\tif errMarshal != nil {\n\t\t\treturn errMarshal\n\t\t}\n\n\t\tx++\n\t\tif x == width {\n\t\t\ty++\n\t\t\tx = 0\n\t\t}\n\t}\n\n\treturn nil\n}", "func DrawElementsBaseVertex(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, basevertex int32) {\n C.glowDrawElementsBaseVertex(gpDrawElementsBaseVertex, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLint)(basevertex))\n}", "func (l *LogItems) Render(showTime bool, ll [][]byte) {\n\tindex := len(l.colors)\n\tfor i, item := range l.items {\n\t\tid := item.ID()\n\t\tcolor, ok := l.colors[id]\n\t\tif !ok {\n\t\t\tif index >= len(colorPalette) {\n\t\t\t\tindex = 0\n\t\t\t}\n\t\t\tcolor = colorPalette[index]\n\t\t\tl.colors[id] = color\n\t\t\tindex++\n\t\t}\n\t\tll[i] = item.Render(int(color-tcell.ColorValid), showTime)\n\t}\n}", "func MapEcho(itr Iterator) interface{} {\n\tvar values []interface{}\n\n\tfor k, v := itr.Next(); k != -1; k, v = itr.Next() {\n\t\tvalues = append(values, v)\n\t}\n\treturn values\n}", "func (v *View) Renderer(matcher func(instance.Description) bool) (func(w io.Writer, v interface{}) error, error) {\n\ttagsView, err := template.NewTemplate(template.ValidURL(v.tagsTemplate), v.options)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\tpropertiesView, err := template.NewTemplate(template.ValidURL(v.propertiesTemplate), v.options)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\n\treturn func(w io.Writer, result interface{}) error {\n\n\t\tinstances, is := result.([]instance.Description)\n\t\tif !is {\n\t\t\treturn fmt.Errorf(\"not []instance.Description\")\n\t\t}\n\n\t\tif !v.quiet {\n\t\t\tif v.viewTemplate != \"\" {\n\t\t\t\tfmt.Printf(\"%-30s\\t%-30s\\n\", \"ID\", \"VIEW\")\n\t\t\t} else if v.properties {\n\t\t\t\tfmt.Printf(\"%-30s\\t%-30s\\t%-30s\\t%-s\\n\", \"ID\", \"LOGICAL\", \"TAGS\", \"PROPERTIES\")\n\n\t\t\t} else {\n\t\t\t\tfmt.Printf(\"%-30s\\t%-30s\\t%-s\\n\", \"ID\", \"LOGICAL\", \"TAGS\")\n\t\t\t}\n\t\t}\n\t\tfor _, d := range instances {\n\n\t\t\t// TODO - filter on the client side by tags\n\t\t\tif len(v.TagFilter()) > 0 {\n\t\t\t\tif hasDifferentTag(v.TagFilter(), d.Tags) {\n\t\t\t\t\tcontinue\n\t\t\t\t}\n\t\t\t}\n\t\t\tif matcher != nil {\n\t\t\t\tif !matcher(d) {\n\t\t\t\t\tcontinue\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tlogical := \" - \"\n\t\t\tif d.LogicalID != nil {\n\t\t\t\tlogical = string(*d.LogicalID)\n\t\t\t}\n\n\t\t\tif v.viewTemplate != \"\" {\n\n\t\t\t\tcolumn := \"-\"\n\t\t\t\tif view, err := d.View(v.viewTemplate); err == nil {\n\t\t\t\t\tcolumn = view\n\t\t\t\t} else {\n\t\t\t\t\tcolumn = err.Error()\n\t\t\t\t}\n\t\t\t\tfmt.Printf(\"%-30s\\t%-30s\\n\", d.ID, column)\n\n\t\t\t} else {\n\n\t\t\t\ttagViewBuff := \"\"\n\t\t\t\tif v.tagsTemplate == \"*\" {\n\t\t\t\t\t// default -- this is a hack\n\t\t\t\t\tprintTags := []string{}\n\t\t\t\t\tfor k, v := range d.Tags {\n\t\t\t\t\t\tprintTags = append(printTags, fmt.Sprintf(\"%s=%s\", k, v))\n\t\t\t\t\t}\n\t\t\t\t\tsort.Strings(printTags)\n\t\t\t\t\ttagViewBuff = strings.Join(printTags, \",\")\n\t\t\t\t} else {\n\t\t\t\t\ttagViewBuff = renderTags(d.Tags, tagsView)\n\t\t\t\t}\n\n\t\t\t\tif v.properties {\n\n\t\t\t\t\tif v.quiet {\n\t\t\t\t\t\t// special render only the properties\n\t\t\t\t\t\tfmt.Printf(\"%s\", renderProperties(d.Properties, propertiesView))\n\t\t\t\t\t} else {\n\t\t\t\t\t\tfmt.Printf(\"%-30s\\t%-30s\\t%-30s\\t%-s\\n\", d.ID, logical, tagViewBuff,\n\t\t\t\t\t\t\trenderProperties(d.Properties, propertiesView))\n\t\t\t\t\t}\n\t\t\t\t} else {\n\t\t\t\t\tfmt.Printf(\"%-30s\\t%-30s\\t%-s\\n\", d.ID, logical, tagViewBuff)\n\t\t\t\t}\n\n\t\t\t}\n\t\t}\n\t\treturn nil\n\t}, nil\n}", "func DrawElementsBaseVertex(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, basevertex int32) {\n\tsyscall.Syscall6(gpDrawElementsBaseVertex, 5, uintptr(mode), uintptr(count), uintptr(xtype), uintptr(indices), uintptr(basevertex), 0)\n}", "func DrawOrder(value int) *SimpleElement { return newSEInt(\"drawOrder\", value) }", "func DrawRangeElementsBaseVertex(mode uint32, start uint32, end uint32, count int32, xtype uint32, indices unsafe.Pointer, basevertex int32) {\n\tC.glowDrawRangeElementsBaseVertex(gpDrawRangeElementsBaseVertex, (C.GLenum)(mode), (C.GLuint)(start), (C.GLuint)(end), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLint)(basevertex))\n}", "func DrawRangeElementsBaseVertex(mode uint32, start uint32, end uint32, count int32, xtype uint32, indices unsafe.Pointer, basevertex int32) {\n\tC.glowDrawRangeElementsBaseVertex(gpDrawRangeElementsBaseVertex, (C.GLenum)(mode), (C.GLuint)(start), (C.GLuint)(end), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLint)(basevertex))\n}", "func (pb *PageBuffer) Values() interface{} {\n offset := pb.pageOffset(pb.page_no)\n return pb.buffer.Slice(offset, offset + pb.idx).Interface()\n}", "func ex1() {\n\tx := [5]int{1, 2, 4, 8, 16}\n\tfor i, v := range x {\n\t\tfmt.Println(i, v)\n\t}\n\tfmt.Printf(\"%T\\n\", x)\n\n}", "func (s Shaper) Shape(text string, ppem uint16, direction Direction, script Script, language string, features string, variations string) []Glyph {\n\tglyphs := make([]Glyph, len([]rune(text)))\n\ti := 0\n\tvar prevIndex uint16\n\tfor cluster, r := range text {\n\t\tindex := s.sfnt.GlyphIndex(r)\n\t\tglyphs[i].Text = string(r)\n\t\tglyphs[i].ID = index\n\t\tglyphs[i].Cluster = uint32(cluster)\n\t\tglyphs[i].XAdvance = int32(s.sfnt.GlyphAdvance(index))\n\t\tif 0 < i {\n\t\t\tglyphs[i-1].XAdvance += int32(s.sfnt.Kerning(prevIndex, index))\n\t\t}\n\t\tprevIndex = index\n\t\ti++\n\t}\n\treturn glyphs\n}", "func createPointArray(array [][]bool) (points []Point) {\n\theight := len(array)\n\twidth := len(array[0])\n\n\tfor y := 0; y < height; y++ {\n\t\tfor x := 0; x < width; x++ {\n\t\t\tif array[y][x] {\n\t\t\t\tpoints = append(points, Point{x % width, y})\n\t\t\t}\n\t\t}\n\t}\n\treturn points[0:]\n}", "func DrawElementsIndirect(mode uint32, xtype uint32, indirect unsafe.Pointer) {\n\tC.glowDrawElementsIndirect(gpDrawElementsIndirect, (C.GLenum)(mode), (C.GLenum)(xtype), indirect)\n}", "func DrawElementsIndirect(mode uint32, xtype uint32, indirect unsafe.Pointer) {\n\tC.glowDrawElementsIndirect(gpDrawElementsIndirect, (C.GLenum)(mode), (C.GLenum)(xtype), indirect)\n}", "func main() {\n\tslice := []int{10, 200, 35, 45, 5, 78, 98, 65, 3, 86}\n\tfmt.Println(slice)\n\tfor i, v := range slice {\n\n\t\tfmt.Println(i, \"->\", v)\n\n\t}\n\n\tfmt.Printf(\"%T\", slice)\n\n}", "func MultiDrawArrays(mode uint32, first *int32, count *int32, drawcount int32) {\n\tsyscall.Syscall6(gpMultiDrawArrays, 4, uintptr(mode), uintptr(unsafe.Pointer(first)), uintptr(unsafe.Pointer(count)), uintptr(drawcount), 0, 0)\n}", "func (h *HAProxyManager) render(ports []uint16) ([]byte, error) {\n\n\t// prepare the context\n\td := make([]templateContext, len(ports))\n\tfor i, port := range ports {\n\t\tif i == len(h.serviceAddrs) {\n\t\t\th.logger.Warnf(\"got port index %d, but only have %d service addrs. ports=%v serviceAddrs=%v\", i, len(h.serviceAddrs), ports, h.serviceAddrs)\n\t\t\tcontinue\n\t\t}\n\t\td[i] = templateContext{Port: port, Source: h.listenAddr, Dest: h.serviceAddrs[i]}\n\t}\n\n\t// render the template\n\tbuf := &bytes.Buffer{}\n\tif err := h.template.Execute(buf, d); err != nil {\n\t\treturn nil, err\n\t}\n\treturn buf.Bytes(), nil\n}", "func at[T interface{ ~[]E }, E any](x T, i int) E {\n\treturn x[i]\n}", "func DrawArraysInstancedBaseInstance(mode uint32, first int32, count int32, instancecount int32, baseinstance uint32) {\n\tsyscall.Syscall6(gpDrawArraysInstancedBaseInstance, 5, uintptr(mode), uintptr(first), uintptr(count), uintptr(instancecount), uintptr(baseinstance), 0)\n}", "func (ss MultiRenderer) Append(elements ...Renderer) MultiRenderer {\n\t// Copy ss, to make sure no memory is overlapping between input and\n\t// output. See issue #97.\n\tresult := append(MultiRenderer{}, ss...)\n\n\tresult = append(result, elements...)\n\treturn result\n}", "func ArrayElement(i int32) {\n C.glowArrayElement(gpArrayElement, (C.GLint)(i))\n}", "func (ss MultiRenderer) Extend(slices ...MultiRenderer) (ss2 MultiRenderer) {\n\tss2 = ss\n\n\tfor _, slice := range slices {\n\t\tss2 = ss2.Append(slice...)\n\t}\n\n\treturn ss2\n}", "func ArrayElement(i int32) {\n\tsyscall.Syscall(gpArrayElement, 1, uintptr(i), 0, 0)\n}", "func DrawElementsInstancedBaseVertexBaseInstance(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32, basevertex int32, baseinstance uint32) {\n C.glowDrawElementsInstancedBaseVertexBaseInstance(gpDrawElementsInstancedBaseVertexBaseInstance, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLsizei)(instancecount), (C.GLint)(basevertex), (C.GLuint)(baseinstance))\n}", "func labelMarkers(m []Marker, x, y int, anchor string, fontSize int, short bool, b *bytes.Buffer) {\n\tb.WriteString(`<g id=\"marker_labels\">`)\n\tfor _, mr := range m {\n\t\tb.WriteString(fmt.Sprintf(\"<text x=\\\"%d\\\" y=\\\"%d\\\" font-size=\\\"%d\\\" visibility=\\\"hidden\\\" text-anchor=\\\"%s\\\">\", x, y, fontSize, anchor))\n\t\tif short {\n\t\t\tb.WriteString(mr.shortLabel)\n\t\t} else {\n\t\t\tb.WriteString(mr.label)\n\t\t}\n\t\tb.WriteString(fmt.Sprintf(\"<set attributeName=\\\"visibility\\\" from=\\\"hidden\\\" to=\\\"visible\\\" begin=\\\"%s.mouseover\\\" end=\\\"%s.mouseout\\\" dur=\\\"2s\\\"/>\",\n\t\t\tmr.id, mr.id))\n\t\tb.WriteString(`</text>`)\n\t}\n\tb.WriteString(`</g>`)\n}", "func DrawElementsInstancedBaseInstance(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32, baseinstance uint32) {\n\tC.glowDrawElementsInstancedBaseInstance(gpDrawElementsInstancedBaseInstance, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLsizei)(instancecount), (C.GLuint)(baseinstance))\n}", "func DrawElementsInstancedBaseInstance(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32, baseinstance uint32) {\n\tC.glowDrawElementsInstancedBaseInstance(gpDrawElementsInstancedBaseInstance, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLsizei)(instancecount), (C.GLuint)(baseinstance))\n}", "func MiniMap(mini []string){\n fmt.Printf(\"Mini Map: \\n\")\n fmt.Printf(\" 1 2 3 4 5 \\n\")\n for i := 0; i <= 4; i ++ {\n fmt.Printf(\"%d\",(i+1))\n for j := 0; j <= 4; j ++ {\n fmt.Printf(\" %s \", mini[i*5+j])\n }\n fmt.Printf(\"\\n\")\n }\n fmt.Printf(\"*****************************************************************************\\n\")\n}", "func main() {\n\ts := []int{5, 3, 2, 6, 1, 6, 7, 10, 49, 100}\n\tfor i, v := range s {\n\t\tfmt.Println(i, v)\n\t}\n\tfmt.Printf(\"%T\\n\", s)\n}", "func (vao *VAO) RenderInstanced(instancecount int32) {\n\tgl.BindVertexArray(vao.handle)\n\tif vao.indexBuffer != nil {\n\t\tgl.BindBuffer(gl.ELEMENT_ARRAY_BUFFER, vao.indexBuffer.GetHandle())\n\t\tgl.DrawElementsInstanced(vao.mode, vao.indexBuffer.Len(), gl.UNSIGNED_SHORT, nil, instancecount)\n\t\tgl.BindBuffer(gl.ELEMENT_ARRAY_BUFFER, 0)\n\t} else {\n\t\tgl.DrawArraysInstanced(vao.mode, 0, vao.vertexBuffers[0].Len(), instancecount)\n\t}\n\tgl.BindVertexArray(0)\n}", "func render(fset *token.FileSet, x interface{}) string {\n\tvar buf bytes.Buffer\n\tif err := printer.Fprint(&buf, fset, x); err != nil {\n\t\tpanic(err)\n\t}\n\treturn buf.String()\n}", "func render(fset *token.FileSet, x interface{}) string {\n\tvar buf bytes.Buffer\n\tif err := printer.Fprint(&buf, fset, x); err != nil {\n\t\tpanic(err)\n\t}\n\treturn buf.String()\n}", "func (v Binary) Render(i, width int, baseStyle lipgloss.Style) string {\n\tw := dataWidth(width)\n\t_, err := v.Seek(int64(i*w), io.SeekStart)\n\tif err != nil {\n\t\treturn baseStyle.Blink(true).Render(err.Error())\n\t}\n\tif len(v.b) != w {\n\t\tv.b = make([]byte, w)\n\t}\n\tn, err := v.Read(v.b)\n\tif err != nil && !errors.Is(err, io.EOF) {\n\t\treturn baseStyle.Blink(true).Render(err.Error())\n\t}\n\ts := fmt.Sprintf(\"% X%s \", v.b[0:n], strings.Repeat(\" \", w-n))\n\tvar x strings.Builder\n\tfor i := 0; i < n; i++ {\n\t\tif unicode.IsPrint(rune(v.b[i])) {\n\t\t\tx.WriteRune(rune(v.b[i]))\n\t\t} else {\n\t\t\tx.WriteRune('.')\n\t\t}\n\t}\n\treturn baseStyle.Render(s + x.String())\n}", "func rang(m, n int) (out []*example) {\n\tfor i := m; i <= n; i++ {\n\t\tout = append(out, newItem(spanWithEnd(i, i+1)))\n\t}\n\treturn out\n}" ]
[ "0.58243454", "0.5544395", "0.54911256", "0.54487693", "0.53604776", "0.5310812", "0.5264226", "0.522527", "0.5085831", "0.5066126", "0.50333935", "0.5001849", "0.5001849", "0.5000811", "0.49644095", "0.49644095", "0.49198684", "0.49170095", "0.48656785", "0.4855901", "0.48252285", "0.48058775", "0.47854033", "0.47854033", "0.47550336", "0.4743869", "0.4743869", "0.47432774", "0.47080722", "0.4704364", "0.4704364", "0.4674933", "0.46388286", "0.46358177", "0.4634802", "0.46304756", "0.46263912", "0.46136066", "0.4613557", "0.46067297", "0.46063325", "0.4603987", "0.45963648", "0.45648754", "0.45550737", "0.45505336", "0.45460942", "0.45290735", "0.45288342", "0.45278877", "0.45214108", "0.4515943", "0.45056295", "0.4485279", "0.4438598", "0.4437756", "0.44319528", "0.44199196", "0.44129112", "0.44099507", "0.44033644", "0.44024304", "0.44024095", "0.438841", "0.4381708", "0.43810833", "0.43673316", "0.43653667", "0.43511805", "0.43455872", "0.4344984", "0.43420562", "0.43420562", "0.43413994", "0.4338362", "0.43310404", "0.4330262", "0.43259352", "0.43259352", "0.43253252", "0.43250594", "0.43177867", "0.43134886", "0.43118545", "0.4307926", "0.42987576", "0.42982513", "0.4287397", "0.42859685", "0.42802757", "0.4271514", "0.4271514", "0.4271286", "0.42700902", "0.42628753", "0.42619202", "0.42619202", "0.42612773", "0.4249954" ]
0.4443873
55
render multiple instances of a set of primitives from array data with a perelement offset
func DrawElementsInstancedBaseVertexBaseInstance(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32, basevertex int32, baseinstance uint32) { C.glowDrawElementsInstancedBaseVertexBaseInstance(gpDrawElementsInstancedBaseVertexBaseInstance, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLsizei)(instancecount), (C.GLint)(basevertex), (C.GLuint)(baseinstance)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func (native *OpenGL) DrawElementsOffset(mode uint32, count int32, elementType uint32, offset int) {\n\tgl.DrawElements(mode, count, elementType, gl.PtrOffset(offset))\n}", "func MultiDrawElements(mode uint32, count *int32, xtype uint32, indices *unsafe.Pointer, drawcount int32) {\n\tsyscall.Syscall6(gpMultiDrawElements, 5, uintptr(mode), uintptr(unsafe.Pointer(count)), uintptr(xtype), uintptr(unsafe.Pointer(indices)), uintptr(drawcount), 0)\n}", "func DrawRangeElements(mode uint32, start uint32, end uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n\tsyscall.Syscall6(gpDrawRangeElements, 6, uintptr(mode), uintptr(start), uintptr(end), uintptr(count), uintptr(xtype), uintptr(indices))\n}", "func DrawElements(mode uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n\tsyscall.Syscall6(gpDrawElements, 4, uintptr(mode), uintptr(count), uintptr(xtype), uintptr(indices), 0, 0)\n}", "func DrawRangeElements(mode uint32, start uint32, end uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n C.glowDrawRangeElements(gpDrawRangeElements, (C.GLenum)(mode), (C.GLuint)(start), (C.GLuint)(end), (C.GLsizei)(count), (C.GLenum)(xtype), indices)\n}", "func MultiDrawElementsIndirect(mode uint32, xtype uint32, indirect unsafe.Pointer, drawcount int32, stride int32) {\n\tsyscall.Syscall6(gpMultiDrawElementsIndirect, 5, uintptr(mode), uintptr(xtype), uintptr(indirect), uintptr(drawcount), uintptr(stride), 0)\n}", "func MultiDrawElements(mode uint32, count *int32, xtype uint32, indices *unsafe.Pointer, drawcount int32) {\n C.glowMultiDrawElements(gpMultiDrawElements, (C.GLenum)(mode), (*C.GLsizei)(unsafe.Pointer(count)), (C.GLenum)(xtype), indices, (C.GLsizei)(drawcount))\n}", "func DrawElements(mode uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n C.glowDrawElements(gpDrawElements, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices)\n}", "func DrawElementsInstanced(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32) {\n C.glowDrawElementsInstanced(gpDrawElementsInstanced, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLsizei)(instancecount))\n}", "func DrawElements(mode Enum, count int, ty Enum, offset int) {\n\tgl.DrawElements(uint32(mode), int32(count), uint32(ty), gl.PtrOffset(offset))\n}", "func iterateObjects1DWithIndexes() {\n\tfmt.Println(\"*** iterateObjects1DWithIndexes\")\n\n\ttype Point struct {\n\t\tX int\n\t\tY int\n\t}\n\tpoints := [5]Point{\n\t\tPoint{1, 1},\n\t\tPoint{2, 2},\n\t\tPoint{3, 3},\n\t\tPoint{4, 4},\n\t\tPoint{5, 5},\n\t}\n\n\tfor i, e := range points {\n\t\tfmt.Printf(\"ints[%d]: %+v\\n\", i, e)\n\t}\n\tfmt.Println(\"\")\n}", "func DrawRangeElements(mode uint32, start uint32, end uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n\tC.glowDrawRangeElements(gpDrawRangeElements, (C.GLenum)(mode), (C.GLuint)(start), (C.GLuint)(end), (C.GLsizei)(count), (C.GLenum)(xtype), indices)\n}", "func DrawRangeElements(mode uint32, start uint32, end uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n\tC.glowDrawRangeElements(gpDrawRangeElements, (C.GLenum)(mode), (C.GLuint)(start), (C.GLuint)(end), (C.GLsizei)(count), (C.GLenum)(xtype), indices)\n}", "func MultiDrawElementsIndirect(mode uint32, xtype uint32, indirect unsafe.Pointer, drawcount int32, stride int32) {\n C.glowMultiDrawElementsIndirect(gpMultiDrawElementsIndirect, (C.GLenum)(mode), (C.GLenum)(xtype), indirect, (C.GLsizei)(drawcount), (C.GLsizei)(stride))\n}", "func MultiDrawElements(mode uint32, count *int32, xtype uint32, indices *unsafe.Pointer, drawcount int32) {\n\tC.glowMultiDrawElements(gpMultiDrawElements, (C.GLenum)(mode), (*C.GLsizei)(unsafe.Pointer(count)), (C.GLenum)(xtype), indices, (C.GLsizei)(drawcount))\n}", "func MultiDrawElements(mode uint32, count *int32, xtype uint32, indices *unsafe.Pointer, drawcount int32) {\n\tC.glowMultiDrawElements(gpMultiDrawElements, (C.GLenum)(mode), (*C.GLsizei)(unsafe.Pointer(count)), (C.GLenum)(xtype), indices, (C.GLsizei)(drawcount))\n}", "func (native *OpenGL) DrawElements(mode uint32, count int32, elementType uint32, indices uintptr) {\n\tgl.DrawElements(mode, count, elementType, unsafe.Pointer(indices)) // nolint: govet,gas\n}", "func renderResults(vals []interface{}) Data {\n\tvar nilcount int\n\tvar obj interface{}\n\tfor _, val := range vals {\n\t\tswitch val.(type) {\n\t\tcase image.Image, Data:\n\t\t\tobj = val\n\t\tcase nil:\n\t\t\tnilcount++\n\t\t}\n\t}\n\tif obj != nil && nilcount == len(vals)-1 {\n\t\tswitch val := obj.(type) {\n\t\tcase image.Image:\n\t\t\tdata, err := image0(val)\n\t\t\tif err == nil {\n\t\t\t\treturn data\n\t\t\t}\n\t\tcase Data:\n\t\t\treturn val\n\t\t}\n\t}\n\tif nilcount == len(vals) {\n\t\t// if all values are nil, return empty Data\n\t\treturn Data{}\n\t}\n\treturn MakeData(\"text/plain\", fmt.Sprint(vals...))\n}", "func (self *Tween) GenerateData() []interface{}{\n\tarray00 := self.Object.Call(\"generateData\")\n\tlength00 := array00.Length()\n\tout00 := make([]interface{}, length00, length00)\n\tfor i00 := 0; i00 < length00; i00++ {\n\t\tout00[i00] = array00.Index(i00)\n\t}\n\treturn out00\n}", "func main() {\n\t//composite literal - create different values of a type\n\t// x := type{values}\n\t//group together values OF THE SAME TYPE\n\tx := []int{4, 5, 7, 8, 42}\n\n\tfmt.Println(x)\n\tfmt.Println(x[0]) //query by index position\n\tfmt.Println(x[1])\n\tfmt.Println(x[2])\n\tfmt.Println(x[3])\n\tfmt.Println(x[4])\n\tfmt.Println(cap(x))\n\n\t//for index and value in the range of x print\n\tfor i, v := range x {\n\t\tfmt.Println(i, v)\n\t}\n}", "func DrawElementsIndirect(mode uint32, xtype uint32, indirect unsafe.Pointer) {\n\tsyscall.Syscall(gpDrawElementsIndirect, 3, uintptr(mode), uintptr(xtype), uintptr(indirect))\n}", "func PrintDataSlice(data interface{}) {\n\td := reflect.ValueOf(data)\n\n\tfor i := 0; i < d.Len(); i++ {\n\t\tdataItem := d.Index(i)\n\t\ttypeOfT := dataItem.Type()\n\n\t\tfor j := 0; j < dataItem.NumField(); j++ {\n\t\t\tf := dataItem.Field(j)\n\t\t\tfmt.Printf(\"%s: %v\\n\", typeOfT.Field(j).Name, f.Interface())\n\t\t}\n\t\tfmt.Printf(\"\\n\")\n\t}\n}", "func MultiDrawElementsIndirect(mode uint32, xtype uint32, indirect unsafe.Pointer, drawcount int32, stride int32) {\n\tC.glowMultiDrawElementsIndirect(gpMultiDrawElementsIndirect, (C.GLenum)(mode), (C.GLenum)(xtype), indirect, (C.GLsizei)(drawcount), (C.GLsizei)(stride))\n}", "func MultiDrawElementsIndirect(mode uint32, xtype uint32, indirect unsafe.Pointer, drawcount int32, stride int32) {\n\tC.glowMultiDrawElementsIndirect(gpMultiDrawElementsIndirect, (C.GLenum)(mode), (C.GLenum)(xtype), indirect, (C.GLsizei)(drawcount), (C.GLsizei)(stride))\n}", "func renderSliceOfTpls(tpls []string, values interface{}) ([]string, error) {\n\tres := []string{}\n\n\tfor _, fragment := range tpls {\n\t\tval, err := renderTpl(fragment, values)\n\t\tif err != nil {\n\t\t\treturn []string{}, err\n\t\t}\n\n\t\tres = append(res, val)\n\t}\n\n\treturn res, nil\n}", "func DrawElements(mode uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n\tC.glowDrawElements(gpDrawElements, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices)\n}", "func DrawElements(mode uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n\tC.glowDrawElements(gpDrawElements, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices)\n}", "func DrawElementsInstancedBaseVertex(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32, basevertex int32) {\n C.glowDrawElementsInstancedBaseVertex(gpDrawElementsInstancedBaseVertex, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLsizei)(instancecount), (C.GLint)(basevertex))\n}", "func (debugging *debuggingOpenGL) DrawElements(mode uint32, count int32, elementType uint32, indices uintptr) {\n\tdebugging.recordEntry(\"DrawElements\", mode, count, elementType, indices)\n\tdebugging.gl.DrawElements(mode, count, elementType, indices)\n\tdebugging.recordExit(\"DrawElements\")\n}", "func DrawElementsInstanced(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32) {\n\tC.glowDrawElementsInstanced(gpDrawElementsInstanced, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLsizei)(instancecount))\n}", "func DrawElementsInstanced(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32) {\n\tC.glowDrawElementsInstanced(gpDrawElementsInstanced, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLsizei)(instancecount))\n}", "func DrawElementsInstancedBaseVertex(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32, basevertex int32) {\n\tsyscall.Syscall6(gpDrawElementsInstancedBaseVertex, 6, uintptr(mode), uintptr(count), uintptr(xtype), uintptr(indices), uintptr(instancecount), uintptr(basevertex))\n}", "func DrawArraysInstanced(mode uint32, first int32, count int32, instancecount int32) {\n C.glowDrawArraysInstanced(gpDrawArraysInstanced, (C.GLenum)(mode), (C.GLint)(first), (C.GLsizei)(count), (C.GLsizei)(instancecount))\n}", "func DrawRangeElementsBaseVertex(mode uint32, start uint32, end uint32, count int32, xtype uint32, indices unsafe.Pointer, basevertex int32) {\n\tsyscall.Syscall9(gpDrawRangeElementsBaseVertex, 7, uintptr(mode), uintptr(start), uintptr(end), uintptr(count), uintptr(xtype), uintptr(indices), uintptr(basevertex), 0, 0)\n}", "func (w wireFormat) MapBySlice() {}", "func (r *Renderer) Render() {\n\tsx, sz, sy := r.c.Bounds()\n\tsxf := float64(sx - 1)\n\tsyf := float64(sy - 1)\n\tszf := float64(sz - 1)\n\tfor z := 0; z < sz; z++ {\n\t\tfor y := 0; y < sy; y++ {\n\t\t\tfor x := 0; x < sx; x++ {\n\t\t\t\tvar lr, lg, lb, _ uint32\n\t\t\t\tn := uint32(0)\n\t\t\t\tfor _, o := range r.objects {\n\t\t\t\t\tr, g, b, _ := o.At(float64(x)/sxf, float64(y)/syf, float64(z)/szf).RGBA()\n\t\t\t\t\tlr += r >> 8\n\t\t\t\t\tlg += g >> 8\n\t\t\t\t\tlb += b >> 8\n\t\t\t\t\tn++\n\t\t\t\t}\n\t\t\t\tr.c.Set(x, y, z, color.RGBA{uint8(lr/n), uint8(lg/n), uint8(lb/n), 255})\n\t\t\t}\n\t\t}\n\t}\n\tr.c.Render()\n}", "func DrawRangeElementsBaseVertex(mode uint32, start uint32, end uint32, count int32, xtype uint32, indices unsafe.Pointer, basevertex int32) {\n C.glowDrawRangeElementsBaseVertex(gpDrawRangeElementsBaseVertex, (C.GLenum)(mode), (C.GLuint)(start), (C.GLuint)(end), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLint)(basevertex))\n}", "func (self *Tween) GenerateDataI(args ...interface{}) []interface{}{\n\tarray00 := self.Object.Call(\"generateData\", args)\n\tlength00 := array00.Length()\n\tout00 := make([]interface{}, length00, length00)\n\tfor i00 := 0; i00 < length00; i00++ {\n\t\tout00[i00] = array00.Index(i00)\n\t}\n\treturn out00\n}", "func DrawElementsInstancedBaseInstance(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32, baseinstance uint32) {\n C.glowDrawElementsInstancedBaseInstance(gpDrawElementsInstancedBaseInstance, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLsizei)(instancecount), (C.GLuint)(baseinstance))\n}", "func makeSlice(offset dvid.Point3d, size dvid.Point2d) []byte {\n\tnumBytes := size[0] * size[1] * 8\n\tslice := make([]byte, numBytes, numBytes)\n\ti := 0\n\tmodz := offset[2] % int32(len(zdata))\n\tfor y := int32(0); y < size[1]; y++ {\n\t\tsy := y + offset[1]\n\t\tmody := sy % int32(len(ydata))\n\t\tsx := offset[0]\n\t\tfor x := int32(0); x < size[0]; x++ {\n\t\t\tmodx := sx % int32(len(xdata))\n\t\t\tbinary.BigEndian.PutUint64(slice[i:i+8], xdata[modx]+ydata[mody]+zdata[modz])\n\t\t\ti += 8\n\t\t\tsx++\n\t\t}\n\t}\n\treturn slice\n}", "func MultiDrawElementsBaseVertex(mode uint32, count *int32, xtype uint32, indices *unsafe.Pointer, drawcount int32, basevertex *int32) {\n\tsyscall.Syscall6(gpMultiDrawElementsBaseVertex, 6, uintptr(mode), uintptr(unsafe.Pointer(count)), uintptr(xtype), uintptr(unsafe.Pointer(indices)), uintptr(drawcount), uintptr(unsafe.Pointer(basevertex)))\n}", "func (t *Dense) slice(start, end int) {\n\tswitch t.t.Kind() {\n\tcase reflect.Bool:\n\t\tdata := t.bools()[start:end]\n\t\tt.fromSlice(data)\n\tcase reflect.Int:\n\t\tdata := t.ints()[start:end]\n\t\tt.fromSlice(data)\n\tcase reflect.Int8:\n\t\tdata := t.int8s()[start:end]\n\t\tt.fromSlice(data)\n\tcase reflect.Int16:\n\t\tdata := t.int16s()[start:end]\n\t\tt.fromSlice(data)\n\tcase reflect.Int32:\n\t\tdata := t.int32s()[start:end]\n\t\tt.fromSlice(data)\n\tcase reflect.Int64:\n\t\tdata := t.int64s()[start:end]\n\t\tt.fromSlice(data)\n\tcase reflect.Uint:\n\t\tdata := t.uints()[start:end]\n\t\tt.fromSlice(data)\n\tcase reflect.Uint8:\n\t\tdata := t.uint8s()[start:end]\n\t\tt.fromSlice(data)\n\tcase reflect.Uint16:\n\t\tdata := t.uint16s()[start:end]\n\t\tt.fromSlice(data)\n\tcase reflect.Uint32:\n\t\tdata := t.uint32s()[start:end]\n\t\tt.fromSlice(data)\n\tcase reflect.Uint64:\n\t\tdata := t.uint64s()[start:end]\n\t\tt.fromSlice(data)\n\tcase reflect.Uintptr:\n\t\tdata := t.uintptrs()[start:end]\n\t\tt.fromSlice(data)\n\tcase reflect.Float32:\n\t\tdata := t.float32s()[start:end]\n\t\tt.fromSlice(data)\n\tcase reflect.Float64:\n\t\tdata := t.float64s()[start:end]\n\t\tt.fromSlice(data)\n\tcase reflect.Complex64:\n\t\tdata := t.complex64s()[start:end]\n\t\tt.fromSlice(data)\n\tcase reflect.Complex128:\n\t\tdata := t.complex128s()[start:end]\n\t\tt.fromSlice(data)\n\n\tcase reflect.String:\n\t\tdata := t.strings()[start:end]\n\t\tt.fromSlice(data)\n\n\tcase reflect.UnsafePointer:\n\t\tdata := t.unsafePointers()[start:end]\n\t\tt.fromSlice(data)\n\tdefault:\n\t\tv := reflect.ValueOf(t.v)\n\t\tv = v.Slice(start, end)\n\t\tt.fromSlice(v.Interface())\n\t}\n}", "func (cont *tuiApplicationController) drawView() {\n\tcont.Sync.Lock()\n\tif !cont.Changed || cont.TuiFileReaderWorker == nil {\n\t\tcont.Sync.Unlock()\n\t\treturn\n\t}\n\tcont.Sync.Unlock()\n\n\t// reset the elements by clearing out every one\n\ttviewApplication.QueueUpdateDraw(func() {\n\t\tfor _, t := range displayResults {\n\t\t\tt.Title.SetText(\"\")\n\t\t\tt.Body.SetText(\"\")\n\t\t\tt.SpacerOne.SetText(\"\")\n\t\t\tt.SpacerTwo.SetText(\"\")\n\t\t\tresultsFlex.ResizeItem(t.Body, 0, 0)\n\t\t}\n\t})\n\n\tcont.Sync.Lock()\n\tresultsCopy := make([]*FileJob, len(cont.Results))\n\tcopy(resultsCopy, cont.Results)\n\tcont.Sync.Unlock()\n\n\t// rank all results\n\t// then go and get the relevant portion for display\n\trankResults(int(cont.TuiFileReaderWorker.GetFileCount()), resultsCopy)\n\tdocumentTermFrequency := calculateDocumentTermFrequency(resultsCopy)\n\n\t// after ranking only get the details for as many as we actually need to\n\t// cut down on processing\n\tif len(resultsCopy) > len(displayResults) {\n\t\tresultsCopy = resultsCopy[:len(displayResults)]\n\t}\n\n\t// We use this to swap out the highlights after we escape to ensure that we don't escape\n\t// out own colours\n\tmd5Digest := md5.New()\n\tfmtBegin := hex.EncodeToString(md5Digest.Sum([]byte(fmt.Sprintf(\"begin_%d\", makeTimestampNano()))))\n\tfmtEnd := hex.EncodeToString(md5Digest.Sum([]byte(fmt.Sprintf(\"end_%d\", makeTimestampNano()))))\n\n\t// go and get the codeResults the user wants to see using selected as the offset to display from\n\tvar codeResults []codeResult\n\tfor i, res := range resultsCopy {\n\t\tif i >= cont.Offset {\n\t\t\tsnippets := extractRelevantV3(res, documentTermFrequency, int(SnippetLength), \"…\")[0]\n\n\t\t\t// now that we have the relevant portion we need to get just the bits related to highlight it correctly\n\t\t\t// which this method does. It takes in the snippet, we extract and all of the locations and then returns just\n\t\t\tl := getLocated(res, snippets)\n\t\t\tcoloredContent := str.HighlightString(snippets.Content, l, fmtBegin, fmtEnd)\n\t\t\tcoloredContent = tview.Escape(coloredContent)\n\n\t\t\tcoloredContent = strings.Replace(coloredContent, fmtBegin, \"[red]\", -1)\n\t\t\tcoloredContent = strings.Replace(coloredContent, fmtEnd, \"[white]\", -1)\n\n\t\t\tcodeResults = append(codeResults, codeResult{\n\t\t\t\tTitle: res.Location,\n\t\t\t\tContent: coloredContent,\n\t\t\t\tScore: res.Score,\n\t\t\t\tLocation: res.Location,\n\t\t\t})\n\t\t}\n\t}\n\n\t// render out what the user wants to see based on the results that have been chosen\n\ttviewApplication.QueueUpdateDraw(func() {\n\t\tfor i, t := range codeResults {\n\t\t\tdisplayResults[i].Title.SetText(fmt.Sprintf(\"[fuchsia]%s (%f)[-:-:-]\", t.Title, t.Score))\n\t\t\tdisplayResults[i].Body.SetText(t.Content)\n\t\t\tdisplayResults[i].Location = t.Location\n\n\t\t\t//we need to update the item so that it displays everything we have put in\n\t\t\tresultsFlex.ResizeItem(displayResults[i].Body, len(strings.Split(t.Content, \"\\n\")), 0)\n\t\t}\n\t})\n\n\t// we can only set that nothing\n\tcont.Changed = false\n}", "func GenerateShapes() {\r\n\t// Square\r\n\tShapes[0].vertices = []gl.GLfloat{-1, -1, 1, -1, -1, 1, 1, 1}\r\n\tShapes[0].elements = []gl.GLushort{0, 1, 2, 2, 3, 1}\r\n\r\n\t// ___|\r\n\tShapes[1].vertices = []gl.GLfloat{-2, 0, -2, -1, 2, -1, 2, 0, 2, 1, 1, 1, 1, 0}\r\n\tShapes[1].elements = []gl.GLushort{0, 1, 2, 2, 3, 0, 3, 4, 5, 5, 6, 3}\r\n\r\n\t// _|_\r\n\tShapes[2].vertices = []gl.GLfloat{-1.5, 0, -0.5, 0, -0.5, 1, 0.5, 1, 0.5, 0, 1.5, 0, 1.5, -1, -1.5, -1}\r\n\tShapes[2].elements = []gl.GLushort{1, 2, 3, 3, 4, 1, 0, 7, 6, 6, 0, 5}\r\n\r\n\t// Snake\r\n\tShapes[3].vertices = []gl.GLfloat{-1.5, -1, -1.5, 0, -0.5, 0, -0.5, 1, 1.5, 1, 1.5, 0, 0.5, 0, 0.5, -1}\r\n\tShapes[3].elements = []gl.GLushort{0, 1, 6, 6, 7, 0, 2, 3, 4, 4, 5, 2}\r\n\r\n\t// Now fill out the rest automatically.\r\n\t// FIXME why doesn't using _, shape in this loop work ?\r\n\tfor i := range Shapes {\r\n\t\tShapes[i].vao = gl.GenVertexArray()\r\n\t\tShapes[i].vao.Bind()\r\n\t\tShapes[i].vbo = gl.GenBuffer()\r\n\t\tShapes[i].vbo.Bind(gl.ARRAY_BUFFER)\r\n\t\tgl.BufferData(gl.ARRAY_BUFFER, len(Shapes[i].vertices)*4, Shapes[i].vertices, gl.STATIC_DRAW)\r\n\t\tShapes[i].elementBuffer = gl.GenBuffer()\r\n\t\tShapes[i].elementBuffer.Bind(gl.ELEMENT_ARRAY_BUFFER)\r\n\t\tgl.BufferData(gl.ELEMENT_ARRAY_BUFFER, len(Shapes[i].elements)*2, Shapes[i].elements, gl.STATIC_DRAW)\r\n\t\tShapes[i].numElements = len(Shapes[i].elements)\r\n\r\n\t\tvertexAttribArray := shaderProgram.GetAttribLocation(\"position\")\r\n\t\tvertexAttribArray.AttribPointer(2, gl.FLOAT, false, 0, uintptr(0))\r\n\t\tvertexAttribArray.EnableArray()\r\n\t}\r\n}", "func DrawElementsIndirect(mode uint32, xtype uint32, indirect unsafe.Pointer) {\n C.glowDrawElementsIndirect(gpDrawElementsIndirect, (C.GLenum)(mode), (C.GLenum)(xtype), indirect)\n}", "func (s *Slicer) RenderXSlices(materialNum int, sp XSliceProcessor, order Order) error {\n\tnumSlices := int(0.5 + (s.irmf.Max[0]-s.irmf.Min[0])/s.deltaX)\n\tvoxelRadiusX := 0.5 * s.deltaX\n\tminVal := s.irmf.Min[0] + voxelRadiusX\n\n\tvar xFunc func(n int) float32\n\n\tswitch order {\n\tcase MinToMax:\n\t\txFunc = func(n int) float32 {\n\t\t\treturn minVal + float32(n)*s.deltaX\n\t\t}\n\tcase MaxToMin:\n\t\txFunc = func(n int) float32 {\n\t\t\treturn minVal + float32(numSlices-n-1)*s.deltaX\n\t\t}\n\t}\n\n\t// log.Printf(\"RenderXSlices: numSlices=%v, startVal=%v, endVal=%v, delta=%v\", numSlices, xFunc(0), xFunc(numSlices-1), s.delta)\n\n\tfor n := 0; n < numSlices; n++ {\n\t\tx := xFunc(n)\n\n\t\timg, err := s.renderSlice(x, materialNum)\n\t\tif err != nil {\n\t\t\treturn fmt.Errorf(\"renderXSlice(%v,%v): %v\", x, materialNum, err)\n\t\t}\n\t\tif err := sp.ProcessXSlice(n, x, voxelRadiusX, img); err != nil {\n\t\t\treturn fmt.Errorf(\"ProcessSlice(%v,%v,%v): %v\", n, x, voxelRadiusX, err)\n\t\t}\n\t}\n\treturn nil\n}", "func (obj *Device) DrawIndexedPrimitiveUP(\n\ttyp PRIMITIVETYPE,\n\tminVertexIndex uint,\n\tnumVertices uint,\n\tprimitiveCount uint,\n\tindexData uintptr,\n\tindexDataFormat FORMAT,\n\tvertexStreamZeroData uintptr,\n\tvertexStreamZeroStride uint,\n) Error {\n\tret, _, _ := syscall.Syscall9(\n\t\tobj.vtbl.DrawIndexedPrimitiveUP,\n\t\t9,\n\t\tuintptr(unsafe.Pointer(obj)),\n\t\tuintptr(typ),\n\t\tuintptr(minVertexIndex),\n\t\tuintptr(numVertices),\n\t\tuintptr(primitiveCount),\n\t\tindexData,\n\t\tuintptr(indexDataFormat),\n\t\tvertexStreamZeroData,\n\t\tuintptr(vertexStreamZeroStride),\n\t)\n\treturn toErr(ret)\n}", "func (f *ParticleRenderFeature) Extract(v *gfx.View) {\n\tfor i, m := range f.et.comps[:f.et.index] {\n\t\tsid := gfx.PackSortId(m.zOrder, 0)\n\t\tv.RenderNodes = append(v.RenderNodes, gfx.SortObject{sid, uint32(i)})\n\t}\n}", "func (c *Client) ShowArrayPrism(ctx context.Context, path string, anyArray []interface{}, boolArray []bool, dateTimeArray []time.Time, intArray []int, numArray []float64, stringArray []string, uuidArray []uuid.UUID) (*http.Response, error) {\n\treq, err := c.NewShowArrayPrismRequest(ctx, path, anyArray, boolArray, dateTimeArray, intArray, numArray, stringArray, uuidArray)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\treturn c.Client.Do(ctx, req)\n}", "func (gl *WebGL) DrawElements(mode GLEnum, count int, valueType GLEnum, offset int) {\n\tgl.context.Call(\"drawElements\", mode, count, valueType, offset)\n}", "func DrawElementsInstancedBaseInstance(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32, baseinstance uint32) {\n\tsyscall.Syscall6(gpDrawElementsInstancedBaseInstance, 6, uintptr(mode), uintptr(count), uintptr(xtype), uintptr(indices), uintptr(instancecount), uintptr(baseinstance))\n}", "func NewPageBuffer(aSlice interface{}, desiredPageNo int) *PageBuffer {\n return newPageBuffer(\n sliceValue(aSlice, false),\n desiredPageNo,\n valueHandler{})\n}", "func (w Widget) Buffer() []termui.Point {\n\tvar wrappedWidget uiWidget\n\n\twrapperHeight := w.Height - 3\n\tif w.Error() != nil && !w.shouldIgnoreError() {\n\t\ttextWidget := termui.NewPar(fmt.Sprintf(\"Error: %v\", w.Error().Error()))\n\t\ttextWidget.Height = wrapperHeight\n\t\ttextWidget.HasBorder = false\n\n\t\twrappedWidget = textWidget\n\t} else if !w.Ready {\n\t\ttextWidget := termui.NewPar(\"Loading entries, please wait...\")\n\t\ttextWidget.Height = wrapperHeight\n\t\ttextWidget.HasBorder = false\n\n\t\twrappedWidget = textWidget\n\t} else {\n\t\tlistWidget := termui.NewList()\n\t\tlistWidget.Height = wrapperHeight\n\t\tlistWidget.HasBorder = false\n\n\t\titems := make([]string, w.EntriesToDisplay())\n\n\t\t// addtional width: width that needs to be added so that they're\n\t\t// formatted properly.\n\t\taddWidth := int(math.Log10(float64(w.EntriesToDisplay()))) + 1\n\t\tfor i := 0; i < w.EntriesToDisplay() && i < len(w.EntryOrder); i++ {\n\t\t\tentryID := w.EntryOrder[i]\n\t\t\tentry, hasEntry := w.Entries[entryID]\n\n\t\t\tvar message string\n\t\t\tif hasEntry {\n\t\t\t\tmessage = entry.String()\n\t\t\t} else {\n\t\t\t\tmessage = \"Loading, please wait\"\n\t\t\t}\n\n\t\t\tdwidth := int(math.Log10(float64(i+1))) + 1\n\t\t\twidth := strconv.Itoa(addWidth - dwidth)\n\t\t\tf := strings.Replace(\"[%v]%{width}v %v...\", \"{width}\", width, 1)\n\t\t\titems[i] = fmt.Sprintf(f, i+1, \"\", message)\n\t\t}\n\n\t\tlistWidget.Items = items\n\t\twrappedWidget = listWidget\n\t}\n\n\twrappedWidget.SetWidth(w.Width - 4)\n\twrappedWidget.SetX(w.X + 2)\n\twrappedWidget.SetY(w.Y + 1)\n\n\tw.Border.Label = fmt.Sprintf(\"Hacker News (%v)\", w.Type.String())\n\tbuffer := append(w.Block.Buffer(), wrappedWidget.Buffer()...)\n\n\treturn buffer\n}", "func DrawElements(mode GLenum, count int, typ GLenum, indices interface{}) {\n\tC.glDrawElements(C.GLenum(mode), C.GLsizei(count), C.GLenum(typ),\n\t\tptr(indices))\n}", "func DrawElementsInstancedBaseVertex(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32, basevertex int32) {\n\tC.glowDrawElementsInstancedBaseVertex(gpDrawElementsInstancedBaseVertex, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLsizei)(instancecount), (C.GLint)(basevertex))\n}", "func DrawElementsInstancedBaseVertex(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32, basevertex int32) {\n\tC.glowDrawElementsInstancedBaseVertex(gpDrawElementsInstancedBaseVertex, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLsizei)(instancecount), (C.GLint)(basevertex))\n}", "func renderAllInlineElements(ctx *renderer.Context, elements []types.InlineElements) ([]byte, error) {\n\tbuff := bytes.NewBuffer(nil)\n\tfor i, e := range elements {\n\t\trenderedElement, err := renderElement(ctx, e)\n\t\tif err != nil {\n\t\t\treturn nil, errors.Wrap(err, \"unable to render element\")\n\t\t}\n\t\tif len(renderedElement) > 0 {\n\t\t\tbuff.Write(renderedElement)\n\t\t\tif len(renderedElement) > 0 && i < len(elements)-1 {\n\t\t\t\tlog.Debugf(\"rendered element of type %T is not the last one\", e)\n\t\t\t\tbuff.WriteString(\"\\n\")\n\t\t\t}\n\t\t}\n\t}\n\treturn buff.Bytes(), nil\n}", "func DrawArrays(mode uint32, first int32, count int32) {\n\tsyscall.Syscall(gpDrawArrays, 3, uintptr(mode), uintptr(first), uintptr(count))\n}", "func MultiDrawArraysIndirect(mode uint32, indirect unsafe.Pointer, drawcount int32, stride int32) {\n\tsyscall.Syscall6(gpMultiDrawArraysIndirect, 4, uintptr(mode), uintptr(indirect), uintptr(drawcount), uintptr(stride), 0, 0)\n}", "func (l LogItems) Render(showTime bool, ll [][]byte) {\n\tcolors := make(map[string]int, len(l))\n\tfor i, item := range l {\n\t\tinfo := item.ID()\n\t\tcolor, ok := colors[info]\n\t\tif !ok {\n\t\t\tcolor = colorFor(info)\n\t\t\tcolors[info] = color\n\t\t}\n\t\tll[i] = item.Render(color, showTime)\n\t}\n}", "func MultiDrawElementsBaseVertex(mode uint32, count *int32, xtype uint32, indices *unsafe.Pointer, drawcount int32, basevertex *int32) {\n C.glowMultiDrawElementsBaseVertex(gpMultiDrawElementsBaseVertex, (C.GLenum)(mode), (*C.GLsizei)(unsafe.Pointer(count)), (C.GLenum)(xtype), indices, (C.GLsizei)(drawcount), (*C.GLint)(unsafe.Pointer(basevertex)))\n}", "func RenderList(w http.ResponseWriter, r *http.Request, l []Renderer) error {\n\tfor _, v := range l {\n\t\tif err := renderer(w, r, v); err != nil {\n\t\t\treturn err\n\t\t}\n\t}\n\tRespond(w, r, l)\n\treturn nil\n}", "func plotdata(deck *generate.Deck, left, right, top, bottom float64, x []float64, y []float64, size float64, color string) {\n\tif len(x) != len(y) {\n\t\treturn\n\t}\n\tminx, maxx := extrema(x)\n\tminy, maxy := extrema(y)\n\n\tix := left\n\tiy := bottom\n\tfor i := 0; i < len(x); i++ {\n\t\txp := vmap(x[i], minx, maxx, left, right)\n\t\typ := vmap(y[i], miny, maxy, bottom, top)\n\t\tdeck.Circle(xp, yp, size, color)\n\t\tdeck.Line(ix, iy, xp, yp, 0.2, color)\n\t\tix = xp\n\t\tiy = yp\n\t}\n}", "func Interpret(data []byte, offset int) []byte {\n\tb:=make([]byte, len(data) * 2)\n\n\tfor i:=0; i<len(data); i++ {\n\t\tb[offset + i * 2] = hex_ascii[ (data[i] & 0XF0) >> 4]\n\t\tb[offset + i * 2 + 1] = hex_ascii[data[i] & 0x0F]\n\t}\n\treturn b\n}", "func DrawArraysInstancedBaseInstance(mode uint32, first int32, count int32, instancecount int32, baseinstance uint32) {\n C.glowDrawArraysInstancedBaseInstance(gpDrawArraysInstancedBaseInstance, (C.GLenum)(mode), (C.GLint)(first), (C.GLsizei)(count), (C.GLsizei)(instancecount), (C.GLuint)(baseinstance))\n}", "func (array *Array) Map(f func(interface{}, int) interface{}) *Array {\n\tnewArray := NewArray()\n\tfor index, object := range array.data {\n\t\tnewArray.Add(f(object, index))\n\t}\n\treturn newArray\n}", "func sliceEncoder(e *encodeState, v reflect.Value) error {\n\tsz := e.size\n\n\tlength := v.Len()\n\n\t// short circuit if length is 0\n\tif length == 0 {\n\t\treturn nil\n\t}\n\n\twidth := int(math.Ceil(math.Sqrt(float64(length))))\n\tcellSz := sz / float64(width)\n\tcellPt := 1 / float64(width)\n\n\tx := 0\n\ty := 0\n\tg := e.Group.Group()\n\tfor i := 0; i < length; i++ {\n\t\txF := float64(x) * cellSz\n\t\tyF := float64(y) * cellSz\n\t\ts := g.Group()\n\t\ts.Transform.Translate(xF, yF)\n\t\ts.Transform.Scale(cellPt, cellPt)\n\n\t\tenc := &encodeState{\n\t\t\tGroup: s,\n\t\t\tsize: sz,\n\t\t}\n\n\t\terrMarshal := enc.marshal(v.Index(i))\n\t\tif errMarshal != nil {\n\t\t\treturn errMarshal\n\t\t}\n\n\t\tx++\n\t\tif x == width {\n\t\t\ty++\n\t\t\tx = 0\n\t\t}\n\t}\n\n\treturn nil\n}", "func DrawElementsBaseVertex(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, basevertex int32) {\n C.glowDrawElementsBaseVertex(gpDrawElementsBaseVertex, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLint)(basevertex))\n}", "func MapEcho(itr Iterator) interface{} {\n\tvar values []interface{}\n\n\tfor k, v := itr.Next(); k != -1; k, v = itr.Next() {\n\t\tvalues = append(values, v)\n\t}\n\treturn values\n}", "func (l *LogItems) Render(showTime bool, ll [][]byte) {\n\tindex := len(l.colors)\n\tfor i, item := range l.items {\n\t\tid := item.ID()\n\t\tcolor, ok := l.colors[id]\n\t\tif !ok {\n\t\t\tif index >= len(colorPalette) {\n\t\t\t\tindex = 0\n\t\t\t}\n\t\t\tcolor = colorPalette[index]\n\t\t\tl.colors[id] = color\n\t\t\tindex++\n\t\t}\n\t\tll[i] = item.Render(int(color-tcell.ColorValid), showTime)\n\t}\n}", "func (v *View) Renderer(matcher func(instance.Description) bool) (func(w io.Writer, v interface{}) error, error) {\n\ttagsView, err := template.NewTemplate(template.ValidURL(v.tagsTemplate), v.options)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\tpropertiesView, err := template.NewTemplate(template.ValidURL(v.propertiesTemplate), v.options)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\n\treturn func(w io.Writer, result interface{}) error {\n\n\t\tinstances, is := result.([]instance.Description)\n\t\tif !is {\n\t\t\treturn fmt.Errorf(\"not []instance.Description\")\n\t\t}\n\n\t\tif !v.quiet {\n\t\t\tif v.viewTemplate != \"\" {\n\t\t\t\tfmt.Printf(\"%-30s\\t%-30s\\n\", \"ID\", \"VIEW\")\n\t\t\t} else if v.properties {\n\t\t\t\tfmt.Printf(\"%-30s\\t%-30s\\t%-30s\\t%-s\\n\", \"ID\", \"LOGICAL\", \"TAGS\", \"PROPERTIES\")\n\n\t\t\t} else {\n\t\t\t\tfmt.Printf(\"%-30s\\t%-30s\\t%-s\\n\", \"ID\", \"LOGICAL\", \"TAGS\")\n\t\t\t}\n\t\t}\n\t\tfor _, d := range instances {\n\n\t\t\t// TODO - filter on the client side by tags\n\t\t\tif len(v.TagFilter()) > 0 {\n\t\t\t\tif hasDifferentTag(v.TagFilter(), d.Tags) {\n\t\t\t\t\tcontinue\n\t\t\t\t}\n\t\t\t}\n\t\t\tif matcher != nil {\n\t\t\t\tif !matcher(d) {\n\t\t\t\t\tcontinue\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tlogical := \" - \"\n\t\t\tif d.LogicalID != nil {\n\t\t\t\tlogical = string(*d.LogicalID)\n\t\t\t}\n\n\t\t\tif v.viewTemplate != \"\" {\n\n\t\t\t\tcolumn := \"-\"\n\t\t\t\tif view, err := d.View(v.viewTemplate); err == nil {\n\t\t\t\t\tcolumn = view\n\t\t\t\t} else {\n\t\t\t\t\tcolumn = err.Error()\n\t\t\t\t}\n\t\t\t\tfmt.Printf(\"%-30s\\t%-30s\\n\", d.ID, column)\n\n\t\t\t} else {\n\n\t\t\t\ttagViewBuff := \"\"\n\t\t\t\tif v.tagsTemplate == \"*\" {\n\t\t\t\t\t// default -- this is a hack\n\t\t\t\t\tprintTags := []string{}\n\t\t\t\t\tfor k, v := range d.Tags {\n\t\t\t\t\t\tprintTags = append(printTags, fmt.Sprintf(\"%s=%s\", k, v))\n\t\t\t\t\t}\n\t\t\t\t\tsort.Strings(printTags)\n\t\t\t\t\ttagViewBuff = strings.Join(printTags, \",\")\n\t\t\t\t} else {\n\t\t\t\t\ttagViewBuff = renderTags(d.Tags, tagsView)\n\t\t\t\t}\n\n\t\t\t\tif v.properties {\n\n\t\t\t\t\tif v.quiet {\n\t\t\t\t\t\t// special render only the properties\n\t\t\t\t\t\tfmt.Printf(\"%s\", renderProperties(d.Properties, propertiesView))\n\t\t\t\t\t} else {\n\t\t\t\t\t\tfmt.Printf(\"%-30s\\t%-30s\\t%-30s\\t%-s\\n\", d.ID, logical, tagViewBuff,\n\t\t\t\t\t\t\trenderProperties(d.Properties, propertiesView))\n\t\t\t\t\t}\n\t\t\t\t} else {\n\t\t\t\t\tfmt.Printf(\"%-30s\\t%-30s\\t%-s\\n\", d.ID, logical, tagViewBuff)\n\t\t\t\t}\n\n\t\t\t}\n\t\t}\n\t\treturn nil\n\t}, nil\n}", "func DrawElementsBaseVertex(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, basevertex int32) {\n\tsyscall.Syscall6(gpDrawElementsBaseVertex, 5, uintptr(mode), uintptr(count), uintptr(xtype), uintptr(indices), uintptr(basevertex), 0)\n}", "func DrawOrder(value int) *SimpleElement { return newSEInt(\"drawOrder\", value) }", "func DrawRangeElementsBaseVertex(mode uint32, start uint32, end uint32, count int32, xtype uint32, indices unsafe.Pointer, basevertex int32) {\n\tC.glowDrawRangeElementsBaseVertex(gpDrawRangeElementsBaseVertex, (C.GLenum)(mode), (C.GLuint)(start), (C.GLuint)(end), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLint)(basevertex))\n}", "func DrawRangeElementsBaseVertex(mode uint32, start uint32, end uint32, count int32, xtype uint32, indices unsafe.Pointer, basevertex int32) {\n\tC.glowDrawRangeElementsBaseVertex(gpDrawRangeElementsBaseVertex, (C.GLenum)(mode), (C.GLuint)(start), (C.GLuint)(end), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLint)(basevertex))\n}", "func (pb *PageBuffer) Values() interface{} {\n offset := pb.pageOffset(pb.page_no)\n return pb.buffer.Slice(offset, offset + pb.idx).Interface()\n}", "func ex1() {\n\tx := [5]int{1, 2, 4, 8, 16}\n\tfor i, v := range x {\n\t\tfmt.Println(i, v)\n\t}\n\tfmt.Printf(\"%T\\n\", x)\n\n}", "func (s Shaper) Shape(text string, ppem uint16, direction Direction, script Script, language string, features string, variations string) []Glyph {\n\tglyphs := make([]Glyph, len([]rune(text)))\n\ti := 0\n\tvar prevIndex uint16\n\tfor cluster, r := range text {\n\t\tindex := s.sfnt.GlyphIndex(r)\n\t\tglyphs[i].Text = string(r)\n\t\tglyphs[i].ID = index\n\t\tglyphs[i].Cluster = uint32(cluster)\n\t\tglyphs[i].XAdvance = int32(s.sfnt.GlyphAdvance(index))\n\t\tif 0 < i {\n\t\t\tglyphs[i-1].XAdvance += int32(s.sfnt.Kerning(prevIndex, index))\n\t\t}\n\t\tprevIndex = index\n\t\ti++\n\t}\n\treturn glyphs\n}", "func createPointArray(array [][]bool) (points []Point) {\n\theight := len(array)\n\twidth := len(array[0])\n\n\tfor y := 0; y < height; y++ {\n\t\tfor x := 0; x < width; x++ {\n\t\t\tif array[y][x] {\n\t\t\t\tpoints = append(points, Point{x % width, y})\n\t\t\t}\n\t\t}\n\t}\n\treturn points[0:]\n}", "func MultiDrawArrays(mode uint32, first *int32, count *int32, drawcount int32) {\n\tsyscall.Syscall6(gpMultiDrawArrays, 4, uintptr(mode), uintptr(unsafe.Pointer(first)), uintptr(unsafe.Pointer(count)), uintptr(drawcount), 0, 0)\n}", "func main() {\n\tslice := []int{10, 200, 35, 45, 5, 78, 98, 65, 3, 86}\n\tfmt.Println(slice)\n\tfor i, v := range slice {\n\n\t\tfmt.Println(i, \"->\", v)\n\n\t}\n\n\tfmt.Printf(\"%T\", slice)\n\n}", "func DrawElementsIndirect(mode uint32, xtype uint32, indirect unsafe.Pointer) {\n\tC.glowDrawElementsIndirect(gpDrawElementsIndirect, (C.GLenum)(mode), (C.GLenum)(xtype), indirect)\n}", "func DrawElementsIndirect(mode uint32, xtype uint32, indirect unsafe.Pointer) {\n\tC.glowDrawElementsIndirect(gpDrawElementsIndirect, (C.GLenum)(mode), (C.GLenum)(xtype), indirect)\n}", "func (h *HAProxyManager) render(ports []uint16) ([]byte, error) {\n\n\t// prepare the context\n\td := make([]templateContext, len(ports))\n\tfor i, port := range ports {\n\t\tif i == len(h.serviceAddrs) {\n\t\t\th.logger.Warnf(\"got port index %d, but only have %d service addrs. ports=%v serviceAddrs=%v\", i, len(h.serviceAddrs), ports, h.serviceAddrs)\n\t\t\tcontinue\n\t\t}\n\t\td[i] = templateContext{Port: port, Source: h.listenAddr, Dest: h.serviceAddrs[i]}\n\t}\n\n\t// render the template\n\tbuf := &bytes.Buffer{}\n\tif err := h.template.Execute(buf, d); err != nil {\n\t\treturn nil, err\n\t}\n\treturn buf.Bytes(), nil\n}", "func at[T interface{ ~[]E }, E any](x T, i int) E {\n\treturn x[i]\n}", "func DrawArraysInstancedBaseInstance(mode uint32, first int32, count int32, instancecount int32, baseinstance uint32) {\n\tsyscall.Syscall6(gpDrawArraysInstancedBaseInstance, 5, uintptr(mode), uintptr(first), uintptr(count), uintptr(instancecount), uintptr(baseinstance), 0)\n}", "func (ss MultiRenderer) Append(elements ...Renderer) MultiRenderer {\n\t// Copy ss, to make sure no memory is overlapping between input and\n\t// output. See issue #97.\n\tresult := append(MultiRenderer{}, ss...)\n\n\tresult = append(result, elements...)\n\treturn result\n}", "func (ss MultiRenderer) Extend(slices ...MultiRenderer) (ss2 MultiRenderer) {\n\tss2 = ss\n\n\tfor _, slice := range slices {\n\t\tss2 = ss2.Append(slice...)\n\t}\n\n\treturn ss2\n}", "func ArrayElement(i int32) {\n C.glowArrayElement(gpArrayElement, (C.GLint)(i))\n}", "func ArrayElement(i int32) {\n\tsyscall.Syscall(gpArrayElement, 1, uintptr(i), 0, 0)\n}", "func DrawElementsInstancedBaseVertexBaseInstance(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32, basevertex int32, baseinstance uint32) {\n C.glowDrawElementsInstancedBaseVertexBaseInstance(gpDrawElementsInstancedBaseVertexBaseInstance, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLsizei)(instancecount), (C.GLint)(basevertex), (C.GLuint)(baseinstance))\n}", "func labelMarkers(m []Marker, x, y int, anchor string, fontSize int, short bool, b *bytes.Buffer) {\n\tb.WriteString(`<g id=\"marker_labels\">`)\n\tfor _, mr := range m {\n\t\tb.WriteString(fmt.Sprintf(\"<text x=\\\"%d\\\" y=\\\"%d\\\" font-size=\\\"%d\\\" visibility=\\\"hidden\\\" text-anchor=\\\"%s\\\">\", x, y, fontSize, anchor))\n\t\tif short {\n\t\t\tb.WriteString(mr.shortLabel)\n\t\t} else {\n\t\t\tb.WriteString(mr.label)\n\t\t}\n\t\tb.WriteString(fmt.Sprintf(\"<set attributeName=\\\"visibility\\\" from=\\\"hidden\\\" to=\\\"visible\\\" begin=\\\"%s.mouseover\\\" end=\\\"%s.mouseout\\\" dur=\\\"2s\\\"/>\",\n\t\t\tmr.id, mr.id))\n\t\tb.WriteString(`</text>`)\n\t}\n\tb.WriteString(`</g>`)\n}", "func DrawElementsInstancedBaseInstance(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32, baseinstance uint32) {\n\tC.glowDrawElementsInstancedBaseInstance(gpDrawElementsInstancedBaseInstance, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLsizei)(instancecount), (C.GLuint)(baseinstance))\n}", "func DrawElementsInstancedBaseInstance(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32, baseinstance uint32) {\n\tC.glowDrawElementsInstancedBaseInstance(gpDrawElementsInstancedBaseInstance, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLsizei)(instancecount), (C.GLuint)(baseinstance))\n}", "func MiniMap(mini []string){\n fmt.Printf(\"Mini Map: \\n\")\n fmt.Printf(\" 1 2 3 4 5 \\n\")\n for i := 0; i <= 4; i ++ {\n fmt.Printf(\"%d\",(i+1))\n for j := 0; j <= 4; j ++ {\n fmt.Printf(\" %s \", mini[i*5+j])\n }\n fmt.Printf(\"\\n\")\n }\n fmt.Printf(\"*****************************************************************************\\n\")\n}", "func main() {\n\ts := []int{5, 3, 2, 6, 1, 6, 7, 10, 49, 100}\n\tfor i, v := range s {\n\t\tfmt.Println(i, v)\n\t}\n\tfmt.Printf(\"%T\\n\", s)\n}", "func (vao *VAO) RenderInstanced(instancecount int32) {\n\tgl.BindVertexArray(vao.handle)\n\tif vao.indexBuffer != nil {\n\t\tgl.BindBuffer(gl.ELEMENT_ARRAY_BUFFER, vao.indexBuffer.GetHandle())\n\t\tgl.DrawElementsInstanced(vao.mode, vao.indexBuffer.Len(), gl.UNSIGNED_SHORT, nil, instancecount)\n\t\tgl.BindBuffer(gl.ELEMENT_ARRAY_BUFFER, 0)\n\t} else {\n\t\tgl.DrawArraysInstanced(vao.mode, 0, vao.vertexBuffers[0].Len(), instancecount)\n\t}\n\tgl.BindVertexArray(0)\n}", "func render(fset *token.FileSet, x interface{}) string {\n\tvar buf bytes.Buffer\n\tif err := printer.Fprint(&buf, fset, x); err != nil {\n\t\tpanic(err)\n\t}\n\treturn buf.String()\n}", "func render(fset *token.FileSet, x interface{}) string {\n\tvar buf bytes.Buffer\n\tif err := printer.Fprint(&buf, fset, x); err != nil {\n\t\tpanic(err)\n\t}\n\treturn buf.String()\n}", "func (v Binary) Render(i, width int, baseStyle lipgloss.Style) string {\n\tw := dataWidth(width)\n\t_, err := v.Seek(int64(i*w), io.SeekStart)\n\tif err != nil {\n\t\treturn baseStyle.Blink(true).Render(err.Error())\n\t}\n\tif len(v.b) != w {\n\t\tv.b = make([]byte, w)\n\t}\n\tn, err := v.Read(v.b)\n\tif err != nil && !errors.Is(err, io.EOF) {\n\t\treturn baseStyle.Blink(true).Render(err.Error())\n\t}\n\ts := fmt.Sprintf(\"% X%s \", v.b[0:n], strings.Repeat(\" \", w-n))\n\tvar x strings.Builder\n\tfor i := 0; i < n; i++ {\n\t\tif unicode.IsPrint(rune(v.b[i])) {\n\t\t\tx.WriteRune(rune(v.b[i]))\n\t\t} else {\n\t\t\tx.WriteRune('.')\n\t\t}\n\t}\n\treturn baseStyle.Render(s + x.String())\n}", "func rang(m, n int) (out []*example) {\n\tfor i := m; i <= n; i++ {\n\t\tout = append(out, newItem(spanWithEnd(i, i+1)))\n\t}\n\treturn out\n}" ]
[ "0.58254796", "0.55457896", "0.5491724", "0.54487765", "0.53611845", "0.53119296", "0.526528", "0.5225026", "0.50852615", "0.50653845", "0.5035245", "0.5002186", "0.5002186", "0.5001671", "0.49654457", "0.49654457", "0.49188524", "0.49179405", "0.48677424", "0.48568487", "0.4824827", "0.48076743", "0.4786234", "0.4786234", "0.47552896", "0.4743362", "0.4743362", "0.4742419", "0.47077143", "0.47036007", "0.47036007", "0.46740326", "0.46384096", "0.46359047", "0.46351638", "0.46290207", "0.46265805", "0.46156052", "0.46127573", "0.46089312", "0.46068943", "0.4605835", "0.45968747", "0.45641655", "0.45543528", "0.4551818", "0.4545988", "0.45294064", "0.4528071", "0.45277217", "0.45206395", "0.45167014", "0.4505408", "0.44850153", "0.44428003", "0.44428003", "0.44382465", "0.44381514", "0.44331565", "0.44186917", "0.44131982", "0.44095194", "0.4403888", "0.44038245", "0.44027042", "0.43890396", "0.43811986", "0.43803784", "0.43666226", "0.43659952", "0.43497956", "0.4345058", "0.43428823", "0.43419963", "0.43419963", "0.43418342", "0.43384966", "0.4331563", "0.43300924", "0.43264595", "0.43251923", "0.43251157", "0.43251157", "0.43171313", "0.43162975", "0.43112722", "0.43076113", "0.4298514", "0.42973548", "0.4286317", "0.42852345", "0.42798057", "0.42705083", "0.42705083", "0.42704767", "0.4269498", "0.4261603", "0.42608654", "0.42608654", "0.42592496", "0.42507493" ]
0.0
-1
write a block of pixels to the frame buffer
func DrawPixels(width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) { C.glowDrawPixels(gpDrawPixels, (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func putPixel(screen []byte, color color, x int, y int) {\n\tscreenX := (windowWidth / 2) + x\n\tscreenY := (windowHeight / 2) - y - 1\n\tbase := (screenY*windowWidth + screenX) * 4\n\tscreen[base] = color.r\n\tscreen[base+1] = color.g\n\tscreen[base+2] = color.b\n\tscreen[base+3] = 0xFF\n\tscreen[0] = 0xFF\n}", "func SetPixel(n, r, g, b uint8) {\n\tbuffer[n*3] = g\n\tbuffer[n*3+1] = r\n\tbuffer[n*3+2] = b\n}", "func setPixel(x, y int, c color, pixels []byte) {\n\tindex := (y*windowWidth + x) * 4\n\n\tif index < len(pixels)-4 && index >= 0 {\n\t\tpixels[index] = c.r\n\t\tpixels[index+1] = c.g\n\t\tpixels[index+1] = c.b\n\t}\n}", "func PixelsWrite(format PixelFormat, geometry Geometry, data unsafe.Pointer) {\n\tcgeometry := geometry.c()\n\tdefer C.free(unsafe.Pointer(cgeometry))\n\tC.wlc_pixels_write(C.enum_wlc_pixel_format(format), cgeometry, data)\n}", "func (i *Image) WritePixels(pix []byte, region image.Rectangle) {\n\tbackendsM.Lock()\n\tdefer backendsM.Unlock()\n\ti.writePixels(pix, region)\n}", "func (i *ImageBuf) SetWriteTiles(width, height, depth int) {\n\tC.ImageBuf_set_write_tiles(i.ptr, C.int(width), C.int(height), C.int(depth))\n\truntime.KeepAlive(i)\n}", "func (c *Canvas) SetPixels(pixels []uint8) {\n\tc.gf.Dirty()\n\n\tmainthread.Call(func() {\n\t\ttex := c.Texture()\n\t\ttex.Begin()\n\t\ttex.SetPixels(0, 0, tex.Width(), tex.Height(), pixels)\n\t\ttex.End()\n\t})\n}", "func setPixel(x, y int, c color, pixels []byte) error {\n\tindex := (y*int(winWidth) + x) * 4\n\n\tif index > len(pixels) || index < 0 {\n\t\t// simple string-based error\n\t\treturn fmt.Errorf(\"the pixel index is not valid, index: %d\", index)\n\t}\n\n\tif index < len(pixels) && index >= 0 {\n\t\tpixels[index] = c.r\n\t\tpixels[index+1] = c.g\n\t\tpixels[index+2] = c.b\n\t}\n\n\treturn nil\n}", "func setPixel(x, y int, c color, pixels []byte) error {\n\tindex := (y*int(winWidth) + x) * 4\n\n\tif index > len(pixels) || index < 0 {\n\t\t// simple string-based error\n\t\treturn fmt.Errorf(\"the pixel index is not valid, index: %d\", index)\n\t}\n\n\tif index < len(pixels) && index >= 0 {\n\t\tpixels[index] = c.r\n\t\tpixels[index+1] = c.g\n\t\tpixels[index+2] = c.b\n\t}\n\n\treturn nil\n}", "func DrawPixels(width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowDrawPixels(gpDrawPixels, (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func (out *Out) Write(i int, v float64) {\n\tout.frame[i] = v\n}", "func TestWritePixel(t *testing.T) {\n\t// Given\n\tc := canvas.New(10, 20)\n\tred := color.New(1.0, 0.0, 0.0)\n\n\t// When\n\tc.SetPixel(2, 3, red)\n\n\t// Then\n\tassert.True(t, c.Pixel(2, 3).Equal(red))\n}", "func (bw *BusWrapper) WriteByteBlock(sid devices.DeviceID, reg byte, list []byte) (err error) {\n\ts, err := bw.getSensor(sid)\n\tif err != nil {\n\t\treturn\n\t}\n\n\terr = bw.switchMuxIfPresent(s.muxAddr, s.muxPort)\n\tif err != nil {\n\t\treturn err\n\t}\n\n\treturn bw.bus.WriteByteBlock(byte(s.i2cAddress), reg, list)\n}", "func SetPixel(x, y int, c [4]byte, pixels *[]byte) {\n\tindex := (y* int(cfg.COLS*cfg.CELL_SIZE) + x) * 4\n\n\tif index < len(*pixels)-4 && index >= 0 {\n\t\t(*pixels)[index] = c[0]\n\t\t(*pixels)[index+1] = c[1]\n\t\t(*pixels)[index+2] = c[2]\t\n\t\t(*pixels)[index+3] = c[3]\t\n\t}\n}", "func writeBlock(file *os.File, index int64, data *dataBlock) {\n\tfile.Seek(index, 0)\n\t//Empezamos el proceso de guardar en binario la data en memoria del struct\n\tvar binaryDisc bytes.Buffer\n\tbinary.Write(&binaryDisc, binary.BigEndian, data)\n\twriteNextBytes(file, binaryDisc.Bytes())\n}", "func DrawPixels(width int32, height int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall6(gpDrawPixels, 5, uintptr(width), uintptr(height), uintptr(format), uintptr(xtype), uintptr(pixels), 0)\n}", "func writeBitmap(file *os.File, index int64, bitMap []byte) {\n\tfile.Seek(index, 0)\n\t//Empezamos el proceso de guardar en binario la data en memoria del struct\n\tvar binaryDisc bytes.Buffer\n\tbinary.Write(&binaryDisc, binary.BigEndian, &bitMap)\n\twriteNextBytes(file, binaryDisc.Bytes())\n}", "func (d *Data) writeXYImage(v dvid.VersionID, vox *Voxels, b storage.TKeyValues) (err error) {\n\n\t// Setup concurrency in image -> block transfers.\n\tvar wg sync.WaitGroup\n\tdefer wg.Wait()\n\n\t// Iterate through index space for this data using ZYX ordering.\n\tblockSize := d.BlockSize()\n\tvar startingBlock int32\n\n\tfor it, err := vox.NewIndexIterator(blockSize); err == nil && it.Valid(); it.NextSpan() {\n\t\tindexBeg, indexEnd, err := it.IndexSpan()\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\n\t\tptBeg := indexBeg.Duplicate().(dvid.ChunkIndexer)\n\t\tptEnd := indexEnd.Duplicate().(dvid.ChunkIndexer)\n\n\t\t// Do image -> block transfers in concurrent goroutines.\n\t\tbegX := ptBeg.Value(0)\n\t\tendX := ptEnd.Value(0)\n\n\t\tserver.CheckChunkThrottling()\n\t\twg.Add(1)\n\t\tgo func(blockNum int32) {\n\t\t\tc := dvid.ChunkPoint3d{begX, ptBeg.Value(1), ptBeg.Value(2)}\n\t\t\tfor x := begX; x <= endX; x++ {\n\t\t\t\tc[0] = x\n\t\t\t\tcurIndex := dvid.IndexZYX(c)\n\t\t\t\tb[blockNum].K = NewTKey(&curIndex)\n\n\t\t\t\t// Write this slice data into the block.\n\t\t\t\tvox.WriteBlock(&(b[blockNum]), blockSize)\n\t\t\t\tblockNum++\n\t\t\t}\n\t\t\tserver.HandlerToken <- 1\n\t\t\twg.Done()\n\t\t}(startingBlock)\n\n\t\tstartingBlock += (endX - begX + 1)\n\t}\n\treturn\n}", "func (sim *DemoSimulation) WriteFrame(visitor func(Mass) bool) {\n\tfor x := -200.0; x < 200; x += 1 {\n\t\tfor ofs := 0.0; ofs < 4; ofs += 0.04 {\n\t\t\tval := math.Sin(sim.time + ofs + (x / 100.0))\n\t\t\tm := Mass{Pos: Vec2{x, val * 100}}\n\n\t\t\tif !visitor(m) {\n\t\t\t\treturn\n\t\t\t}\n\t\t}\n\t}\n}", "func draw(window *glfw.Window, reactProg, landProg uint32) {\n\n\tvar renderLoops = 4\n\tfor i := 0; i < renderLoops; i++ {\n\t\t// -- DRAW TO BUFFER --\n\t\t// define destination of pixels\n\t\t//gl.BindFramebuffer(gl.FRAMEBUFFER, 0)\n\t\tgl.BindFramebuffer(gl.FRAMEBUFFER, FBO[1])\n\n\t\tgl.Viewport(0, 0, width, height) // Retina display doubles the framebuffer !?!\n\n\t\tgl.Clear(gl.COLOR_BUFFER_BIT | gl.DEPTH_BUFFER_BIT)\n\t\tgl.UseProgram(reactProg)\n\n\t\t// bind Texture\n\t\tgl.ActiveTexture(gl.TEXTURE0)\n\t\tgl.BindTexture(gl.TEXTURE_2D, renderedTexture)\n\t\tgl.Uniform1i(uniTex, 0)\n\n\t\tgl.BindVertexArray(VAO)\n\t\tgl.DrawElements(gl.TRIANGLE_STRIP, int32(len(indices)), gl.UNSIGNED_INT, nil)\n\n\t\tgl.BindVertexArray(0)\n\n\t\t// -- copy back textures --\n\t\tgl.BindFramebuffer(gl.READ_FRAMEBUFFER, FBO[1]) // source is high res array\n\t\tgl.ReadBuffer(gl.COLOR_ATTACHMENT0)\n\t\tgl.BindFramebuffer(gl.DRAW_FRAMEBUFFER, FBO[0]) // destination is cells array\n\t\tgl.DrawBuffer(gl.COLOR_ATTACHMENT0)\n\t\tgl.BlitFramebuffer(0, 0, width, height,\n\t\t\t0, 0, cols, rows,\n\t\t\tgl.COLOR_BUFFER_BIT, gl.NEAREST) // downsample\n\t\tgl.BindFramebuffer(gl.READ_FRAMEBUFFER, FBO[0]) // source is low res array - put in texture\n\t\t// read pixels saves data read as unsigned bytes and then loads them in TexImage same way\n\t\tgl.ReadPixels(0, 0, cols, rows, gl.RGBA, gl.FLOAT, gl.Ptr(fData))\n\t\tgl.BindTexture(gl.TEXTURE_2D, renderedTexture)\n\t\tgl.TexImage2D(gl.TEXTURE_2D, 0, gl.RGBA, cols, rows, 0, gl.RGBA, gl.FLOAT, gl.Ptr(fData))\n\t\tCheckGLErrors()\n\t}\n\t// -- DRAW TO SCREEN --\n\tvar model glm.Mat4\n\n\t// destination 0 means screen\n\tgl.BindFramebuffer(gl.FRAMEBUFFER, 0)\n\tgl.Viewport(0, 0, width*2, height*2) // Retina display doubles the framebuffer !?!\n\tgl.Clear(gl.COLOR_BUFFER_BIT | gl.DEPTH_BUFFER_BIT)\n\tgl.UseProgram(landProg)\n\t// bind Texture\n\tgl.ActiveTexture(gl.TEXTURE0)\n\tgl.BindTexture(gl.TEXTURE_2D, drawTexture)\n\n\tvar view glm.Mat4\n\tvar brakeFactor = float64(20000.0)\n\tvar xCoord, yCoord float32\n\txCoord = float32(-3.0 * math.Sin(float64(myClock)))\n\tyCoord = float32(-3.0 * math.Cos(float64(myClock)))\n\t//xCoord = 0.0\n\t//yCoord = float32(-2.5)\n\tmyClock = math.Mod((myClock + float64(deltaTime)/brakeFactor), (math.Pi * 2))\n\tview = glm.LookAt(xCoord, yCoord, 2.0, 0.0, 0.0, 0.0, 0.0, 0.0, 1.0)\n\tgl.UniformMatrix4fv(uniView, 1, false, &view[0])\n\tmodel = glm.HomogRotate3DX(glm.DegToRad(00.0))\n\tgl.UniformMatrix4fv(uniModel, 1, false, &model[0])\n\tgl.Uniform1i(uniTex2, 0)\n\n\t// render container\n\t//gl.PolygonMode(gl.FRONT_AND_BACK, gl.FILL)\n\t//gl.PolygonMode(gl.FRONT_AND_BACK, gl.LINE)\n\n\tgl.BindVertexArray(VAO)\n\tgl.DrawElements(gl.TRIANGLE_STRIP, int32(len(indices)), gl.UNSIGNED_INT, nil)\n\tgl.BindVertexArray(0)\n\n\tCheckGLErrors()\n\n\tglfw.PollEvents()\n\twindow.SwapBuffers()\n\n\t//time.Sleep(100 * 1000 * 1000)\n}", "func (color *Color) writeBlockLength(w io.Writer) (err error) {\n\tblockLength, err := color.calculateBlockLength()\n\tif err != nil {\n\t\treturn\n\t}\n\tif err = binary.Write(w, binary.BigEndian, blockLength); err != nil {\n\t\treturn\n\t}\n\treturn\n}", "func (m *Mode) PutBlock(i uint64, b state.State) {\n\tbi := i % NBufferBlocks // in the current buffer\n\tm.OutBuffer[bi] = b\n\tif i > m.putMax {\n\t\tm.putMax = i\n\t}\n}", "func (spr *Sprite) DrawFrame(c *Canvas, bmp *Bitmap, x, y, frame, row int32, flip Flip) {\n\n\tc.DrawBitmapRegion(bmp,\n\t\tframe*spr.width, row*spr.height,\n\t\tspr.width, spr.height,\n\t\tx, y, flip)\n}", "func (s *Screen) SetPixel(x int, y int, bitindex int, row int, ox int, oy int) {\n\n\tfmt.Printf(\"Inside draw (setpixel) X: %d Y: %d bitindex: %d, row: %d || original x: %d y: %d\\n\", x, y, bitindex, row, ox, oy)\n\tif !s.validPixelIndex(x, y) {\n\t\treturn\n\t}\n\n\ts.Pixels[y][(x*4)+0] = PIXEL_ON\n\ts.Pixels[y][(x*4)+1] = PIXEL_ON\n\ts.Pixels[y][(x*4)+2] = PIXEL_ON\n\ts.Pixels[y][(x*4)+3] = PIXEL_ON\n}", "func encodeBWData(w io.Writer, img image.Image, opts *EncodeOptions) error {\n\t// In the background, write each index value into a channel.\n\trect := img.Bounds()\n\twidth := rect.Max.X - rect.Min.X\n\tsamples := make(chan uint16, width)\n\tgo func() {\n\t\tbwImage := NewBW(image.ZR)\n\t\tcm := bwImage.ColorModel().(color.Palette)\n\t\tfor y := rect.Min.Y; y < rect.Max.Y; y++ {\n\t\t\tfor x := rect.Min.X; x < rect.Max.X; x++ {\n\t\t\t\tsamples <- uint16(cm.Index(img.At(x, y)))\n\t\t\t}\n\t\t}\n\t\tclose(samples)\n\t}()\n\n\t// In the foreground, consume index values (either 0 or 1) and\n\t// write them to the image file as individual bits. Pack 8\n\t// bits to a byte, pad each row, and output.\n\tif opts.Plain {\n\t\treturn writePlainData(w, samples)\n\t}\n\twb, ok := w.(*bufio.Writer)\n\tif !ok {\n\t\twb = bufio.NewWriter(w)\n\t}\n\tvar b byte // Next byte to write\n\tvar bLen uint // Valid bits in b\n\tvar rowBits int // Bits written to the current row\n\tfor s := range samples {\n\t\tb = b<<1 | byte(s)\n\t\tbLen++\n\t\trowBits++\n\t\tif rowBits == width {\n\t\t\t// Pad the last byte in the row.\n\t\t\tb <<= 8 - bLen\n\t\t\tbLen = 8\n\t\t\trowBits = 0\n\t\t}\n\t\tif bLen == 8 {\n\t\t\t// Write a full byte to the output.\n\t\t\tif err := wb.WriteByte(b); err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\t\t\tb = 0\n\t\t\tbLen = 0\n\t\t}\n\t}\n\twb.Flush()\n\treturn nil\n}", "func (b *Block) WriteAt(p []byte, off int) error {\n\tif off > blockSize || off < 0 {\n\t\treturn ErrOffsetRange\n\t}\n\n\tvar size = len(p)\n\tif off+size > blockSize {\n\t\treturn ErrWriteBytes\n\t}\n\n\tif len(b.data) == 0 {\n\t\tb.data = make([]byte, blockSize)\n\t}\n\n\tcounter := 0\n\tfor i := off; i < blockSize && counter < size; i++ {\n\t\tb.data[i] = p[counter]\n\t\tcounter++\n\t}\n\tb.size += counter\n\n\treturn nil\n}", "func (b *XMobileBackend) PutImageData(img *image.RGBA, x, y int) {\n\tb.activate()\n\n\tb.glctx.ActiveTexture(gl.TEXTURE0)\n\tif b.imageBufTex.Value == 0 {\n\t\tb.imageBufTex = b.glctx.CreateTexture()\n\t\tb.glctx.BindTexture(gl.TEXTURE_2D, b.imageBufTex)\n\t\tb.glctx.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.LINEAR)\n\t\tb.glctx.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, gl.LINEAR)\n\t\tb.glctx.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_S, gl.CLAMP_TO_EDGE)\n\t\tb.glctx.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_T, gl.CLAMP_TO_EDGE)\n\t} else {\n\t\tb.glctx.BindTexture(gl.TEXTURE_2D, b.imageBufTex)\n\t}\n\n\tw, h := img.Bounds().Dx(), img.Bounds().Dy()\n\n\tif img.Stride == img.Bounds().Dx()*4 {\n\t\tb.glctx.TexImage2D(gl.TEXTURE_2D, 0, gl.RGBA, w, h, gl.RGBA, gl.UNSIGNED_BYTE, img.Pix[0:])\n\t} else {\n\t\tdata := make([]uint8, 0, w*h*4)\n\t\tfor cy := 0; cy < h; cy++ {\n\t\t\tstart := cy * img.Stride\n\t\t\tend := start + w*4\n\t\t\tdata = append(data, img.Pix[start:end]...)\n\t\t}\n\t\tb.glctx.TexImage2D(gl.TEXTURE_2D, 0, gl.RGBA, w, h, gl.RGBA, gl.UNSIGNED_BYTE, data[0:])\n\t}\n\n\tdx, dy := float32(x), float32(y)\n\tdw, dh := float32(w), float32(h)\n\n\tb.glctx.BindBuffer(gl.ARRAY_BUFFER, b.buf)\n\tdata := [16]float32{dx, dy, dx + dw, dy, dx + dw, dy + dh, dx, dy + dh,\n\t\t0, 0, 1, 0, 1, 1, 0, 1}\n\tb.glctx.BufferData(gl.ARRAY_BUFFER, byteSlice(unsafe.Pointer(&data[0]), len(data)*4), gl.STREAM_DRAW)\n\n\tb.glctx.UseProgram(b.shd.ID)\n\tb.glctx.Uniform1i(b.shd.Image, 0)\n\tb.glctx.Uniform2f(b.shd.CanvasSize, float32(b.fw), float32(b.fh))\n\tb.glctx.UniformMatrix3fv(b.shd.Matrix, mat3identity[:])\n\tb.glctx.Uniform1f(b.shd.GlobalAlpha, 1)\n\tb.glctx.Uniform1i(b.shd.UseAlphaTex, 0)\n\tb.glctx.Uniform1i(b.shd.Func, shdFuncImage)\n\tb.glctx.VertexAttribPointer(b.shd.Vertex, 2, gl.FLOAT, false, 0, 0)\n\tb.glctx.VertexAttribPointer(b.shd.TexCoord, 2, gl.FLOAT, false, 0, 8*4)\n\tb.glctx.EnableVertexAttribArray(b.shd.Vertex)\n\tb.glctx.EnableVertexAttribArray(b.shd.TexCoord)\n\tb.glctx.DrawArrays(gl.TRIANGLE_FAN, 0, 4)\n\tb.glctx.DisableVertexAttribArray(b.shd.Vertex)\n\tb.glctx.DisableVertexAttribArray(b.shd.TexCoord)\n}", "func TestTFramedMemoryBufferWrite(t *testing.T) {\n\tbuff := NewTMemoryOutputBuffer(100)\n\tassert.Equal(t, 4, buff.Len())\n\tn, err := buff.Write(make([]byte, 50))\n\tassert.Nil(t, err)\n\tassert.Equal(t, 50, n)\n\tn, err = buff.Write(make([]byte, 40))\n\tassert.Nil(t, err)\n\tassert.Equal(t, 40, n)\n\tassert.Equal(t, 94, buff.Len())\n\t_, err = buff.Write(make([]byte, 20))\n\tassert.True(t, IsErrTooLarge(err))\n\tassert.Equal(t, TRANSPORT_EXCEPTION_REQUEST_TOO_LARGE, err.(thrift.TTransportException).TypeId())\n\tassert.Equal(t, 4, buff.Len())\n}", "func WriteBytes(buffer []byte, offset int, value []byte) {\n copy(buffer[offset:offset + len(value)], value)\n}", "func (self *TraitPixbufLoader) WriteBytes(buffer *C.GBytes) (return__ bool, __err__ error) {\n\tvar __cgo_error__ *C.GError\n\tvar __cgo__return__ C.gboolean\n\t__cgo__return__ = C.gdk_pixbuf_loader_write_bytes(self.CPointer, buffer, &__cgo_error__)\n\treturn__ = __cgo__return__ == C.gboolean(1)\n\tif __cgo_error__ != nil {\n\t\t__err__ = errors.New(C.GoString((*C.char)(unsafe.Pointer(__cgo_error__.message))))\n\t}\n\treturn\n}", "func CopyPixels(x int32, y int32, width int32, height int32, xtype uint32) {\n C.glowCopyPixels(gpCopyPixels, (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(xtype))\n}", "func (e *encoder) encode(w compresserWriter) error {\n\td := e.m.Bounds().Size()\n\n\tvar err error\n\tfor y := 0; y < d.Y; y++ {\n\t\tfor x := 0; x < d.X; x++ {\n\t\t\tpixel := e.bytesAt(x, y)\n\t\t\t_, err = w.Write(pixel)\n\n\t\t\tif err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\t\t}\n\t}\n\n\treturn w.Flush()\n}", "func (i *ImageBuf) SetFull(xbegin, xend, ybegin, yend, zbegin, zend int) {\n\tC.ImageBuf_set_full(\n\t\ti.ptr,\n\t\tC.int(xbegin), C.int(xend),\n\t\tC.int(ybegin), C.int(yend),\n\t\tC.int(zbegin), C.int(zend))\n\truntime.KeepAlive(i)\n}", "func (_Contract *ContractSession) BuyPixelBlocks(_x []*big.Int, _y []*big.Int, _price []*big.Int, _contentData [][32]byte) (*types.Transaction, error) {\n\treturn _Contract.Contract.BuyPixelBlocks(&_Contract.TransactOpts, _x, _y, _price, _contentData)\n}", "func (_Contract *ContractTransactorSession) BuyPixelBlocks(_x []*big.Int, _y []*big.Int, _price []*big.Int, _contentData [][32]byte) (*types.Transaction, error) {\n\treturn _Contract.Contract.BuyPixelBlocks(&_Contract.TransactOpts, _x, _y, _price, _contentData)\n}", "func (w *writer) WriteBlock(pieceIndex, pieceOffset uint32, p []byte) (int, error) {\n\treturn w.WriteAt(p, w.info.PieceOffset(pieceIndex, pieceOffset))\n}", "func (c *digisparkI2cConnection) WriteBlockData(reg uint8, data []byte) error {\n\tc.mtx.Lock()\n\tdefer c.mtx.Unlock()\n\n\tif len(data) > 32 {\n\t\tdata = data[:32]\n\t}\n\n\tbuf := make([]byte, len(data)+1)\n\tcopy(buf[1:], data)\n\tbuf[0] = reg\n\treturn c.writeAndCheckCount(buf, true)\n}", "func (c *Canvas) WritePixel(x, y int, color color.Color) error {\n\terr := c.ValidateInCanvasBounds(x, y)\n\tif err != nil {\n\t\treturn err\n\t}\n\n\tc.Pixels[y][x] = color\n\treturn nil\n}", "func (f *FrameWriter) Write(p []byte) (n int, err error) {\n\tif len(p) == 0 {\n\t\treturn\n\t}\n\th := strconv.AppendInt(f.scratch[:0], int64(len(p)), 10)\n\tm := len(h)\n\n\th = h[:m+1]\n\th[m] = ' '\n\n\tif m += len(p) + 1; m > len(f.buf)-f.offset {\n\t\tif err = f.Flush(); err == nil && m > len(f.buf) {\n\t\t\tif n, err = f.write(h); err == nil {\n\t\t\t\ta := 0\n\t\t\t\ta, err = f.write(p)\n\t\t\t\tn += a\n\t\t\t}\n\t\t\treturn\n\t\t}\n\t}\n\tif err == nil {\n\t\tn = copy(f.buf[f.offset:], h)\n\t\tn += copy(f.buf[f.offset+n:], p)\n\t\tf.offset += n\n\t}\n\treturn\n}", "func (b *Block) Write(p []byte) {\n\tb.data = make([]byte, blockSize)\n\tb.size = copy(b.data, p)\n}", "func drawTilePixels(image *image.RGBA, pixel [8][8]color.RGBA, xOffset int, yOffset int) *image.RGBA {\n\tfor x := 0; x < TileWidth; x++ {\n\t\tfor y := 0; y < TileHeight; y++ {\n\t\t\timage.SetRGBA(xOffset*TileWidth+x, yOffset*TileHeight+y, pixel[y][x])\n\t\t}\n\t}\n\treturn image\n}", "func CopyPixels(x int32, y int32, width int32, height int32, xtype uint32) {\n\tsyscall.Syscall6(gpCopyPixels, 5, uintptr(x), uintptr(y), uintptr(width), uintptr(height), uintptr(xtype), 0)\n}", "func (b *buffer) WriteBlock() safemem.Block {\n\treturn safemem.BlockFromSafeSlice(b.WriteSlice())\n}", "func (b *Buffer) DrawPixel(x, y int, c color.Color) {\n\tb.context.SetColor(c)\n\tb.context.SetPixel(x, y)\n}", "func writeBlock(w io.Writer, pver uint32, b *MicroBlock) error {\n\tsec := uint32(bh.Timestamp.Unix())\n\treturn writeElements(w, b.Version, &b.PrevBlock, &b.MerkleRoot,\n\t\tsec, b.Bits)\n}", "func ReadPixels(x, y, width, height, format, formatType int) []byte {\n\tsize := uint32((width - x) * (height - y) * 4)\n\tgobuf = make([]byte, size+1)\n\n\tptr := (*byte)(unsafe.Pointer(&gobuf[0]))\n\tgl.ReadPixels(int32(x), int32(y), int32(width), int32(height), uint32(format), uint32(formatType), unsafe.Pointer(ptr))\n\treturn gobuf[:size]\n}", "func (f *Framebuffer) Paint(r vnclib.Rectangle, colors []vnclib.Color) {\n\tif glog.V(4) {\n\t\tglog.Info(venuelib.FnNameWithArgs(r.String(), \"colors\"))\n\t}\n\t// TODO(kward): Implement double or triple buffering to reduce paint\n\t// interference.\n\tfor x := 0; x < int(r.Width); x++ {\n\t\tfor y := 0; y < int(r.Height); y++ {\n\t\t\tc := colors[x+y*int(r.Width)]\n\t\t\tf.fb.SetRGBA(x+int(r.X), y+int(r.Y), color.RGBA{uint8(c.R), uint8(c.G), uint8(c.B), 255})\n\t\t}\n\t}\n}", "func (img *ByteImage) pixels() [][]byte {\n\tbyteIdx := 0\n\tpixels := make([][]byte, img.height)\n\tfor rowIdx := 0; rowIdx < img.height; rowIdx++ {\n\t\tpixels[rowIdx] = make([]byte, img.width)\n\t\tfor colIdx := 0; colIdx < img.width; colIdx++ {\n\t\t\tpixels[rowIdx][colIdx] = img.bytes[byteIdx]\n\t\t\tbyteIdx++\n\t\t}\n\t}\n\treturn pixels\n}", "func fill(pix []byte, c color.RGBA) {\n\tfor i := 0; i < len(pix); i += 4 {\n\t\tpix[i] = c.R\n\t\tpix[i+1] = c.G\n\t\tpix[i+2] = c.B\n\t\tpix[i+3] = c.A\n\t}\n}", "func WriteByte(buffer []byte, offset int, value byte) {\n buffer[offset] = value\n}", "func block(h *[4][16]uint32, base uintptr, offsets *[16]uint32, mask uint16)", "func (r *Dev) write(blockAddr byte, data []byte) error {\n\tread, backLen, err := r.preAccess(blockAddr, commands.PICC_WRITE)\n\tif err != nil || backLen != 4 {\n\t\treturn err\n\t}\n\tif read[0]&0x0F != 0x0A {\n\t\treturn wrapf(\"can't authorize write\")\n\t}\n\tvar newData [18]byte\n\tcopy(newData[:], data[:16])\n\tcrc, err := r.LowLevel.CRC(newData[:16])\n\tif err != nil {\n\t\treturn err\n\t}\n\tnewData[16] = crc[0]\n\tnewData[17] = crc[1]\n\tread, backLen, err = r.LowLevel.CardWrite(commands.PCD_TRANSCEIVE, newData[:])\n\tif err != nil {\n\t\treturn err\n\t}\n\tif backLen != 4 || read[0]&0x0F != 0x0A {\n\t\terr = wrapf(\"can't write data\")\n\t}\n\treturn nil\n}", "func (_Contract *ContractSession) BuyPixelBlock(_x *big.Int, _y *big.Int, _price *big.Int, _contentData [32]byte) (*types.Transaction, error) {\n\treturn _Contract.Contract.BuyPixelBlock(&_Contract.TransactOpts, _x, _y, _price, _contentData)\n}", "func (g *gfx) SetPixel(x, y int) {\n\tg[x][y] = COLOR_WHITE\n}", "func ringBufferWrite(bytes []byte, n uint, rb *ringBuffer) {\n\tif rb.pos_ == 0 && uint32(n) < rb.tail_size_ {\n\t\t/* Special case for the first write: to process the first block, we don't\n\t\t need to allocate the whole ring-buffer and we don't need the tail\n\t\t either. However, we do this memory usage optimization only if the\n\t\t first write is less than the tail size, which is also the input block\n\t\t size, otherwise it is likely that other blocks will follow and we\n\t\t will need to reallocate to the full size anyway. */\n\t\trb.pos_ = uint32(n)\n\n\t\tringBufferInitBuffer(rb.pos_, rb)\n\t\tcopy(rb.buffer_, bytes[:n])\n\t\treturn\n\t}\n\n\tif rb.cur_size_ < rb.total_size_ {\n\t\t/* Lazily allocate the full buffer. */\n\t\tringBufferInitBuffer(rb.total_size_, rb)\n\n\t\t/* Initialize the last two bytes to zero, so that we don't have to worry\n\t\t later when we copy the last two bytes to the first two positions. */\n\t\trb.buffer_[rb.size_-2] = 0\n\n\t\trb.buffer_[rb.size_-1] = 0\n\t}\n\t{\n\t\tvar masked_pos uint = uint(rb.pos_ & rb.mask_)\n\n\t\t/* The length of the writes is limited so that we do not need to worry\n\t\t about a write */\n\t\tringBufferWriteTail(bytes, n, rb)\n\n\t\tif uint32(masked_pos+n) <= rb.size_ {\n\t\t\t/* A single write fits. */\n\t\t\tcopy(rb.buffer_[masked_pos:], bytes[:n])\n\t\t} else {\n\t\t\t/* Split into two writes.\n\t\t\t Copy into the end of the buffer, including the tail buffer. */\n\t\t\tcopy(rb.buffer_[masked_pos:], bytes[:brotli_min_size_t(n, uint(rb.total_size_-uint32(masked_pos)))])\n\n\t\t\t/* Copy into the beginning of the buffer */\n\t\t\tcopy(rb.buffer_, bytes[rb.size_-uint32(masked_pos):][:uint32(n)-(rb.size_-uint32(masked_pos))])\n\t\t}\n\t}\n\t{\n\t\tvar not_first_lap bool = rb.pos_&(1<<31) != 0\n\t\tvar rb_pos_mask uint32 = (1 << 31) - 1\n\t\trb.data_[0] = rb.buffer_[rb.size_-2]\n\t\trb.data_[1] = rb.buffer_[rb.size_-1]\n\t\trb.pos_ = (rb.pos_ & rb_pos_mask) + uint32(uint32(n)&rb_pos_mask)\n\t\tif not_first_lap {\n\t\t\t/* Wrap, but preserve not-a-first-lap feature. */\n\t\t\trb.pos_ |= 1 << 31\n\t\t}\n\t}\n}", "func (_Contract *ContractTransactorSession) BuyPixelBlock(_x *big.Int, _y *big.Int, _price *big.Int, _contentData [32]byte) (*types.Transaction, error) {\n\treturn _Contract.Contract.BuyPixelBlock(&_Contract.TransactOpts, _x, _y, _price, _contentData)\n}", "func (t *Texture) Set(x uint16, y uint16, value rgb565.Rgb565Color) {\n\tt.pixels[y*t.width+x] = value\n}", "func (d *Dev) SetPixel(x, y int, active bool) {\n\toffset := (y / 8 * Width) + x\n\tpageAddress := y % 8\n\td.pixels[offset] &= ^(1 << byte(pageAddress))\n\td.pixels[offset] |= bTob(active) & 1 << byte(pageAddress)\n}", "func (vbm VolumeBitMap) Write(devicebytes []byte) error {\n\tfor i, bp := range vbm {\n\t\tif err := disk.MarshalBlock(devicebytes, bp); err != nil {\n\t\t\treturn fmt.Errorf(\"cannot write block %d (device block %d) of Volume Bit Map: %v\", i, bp.GetBlock(), err)\n\t\t}\n\t}\n\treturn nil\n}", "func (b *bufferFallbackImpl) putImage(xd xproto.Drawable, xg xproto.Gcontext, depth uint8, dp image.Point, sr image.Rectangle) {\n\twidthPerReq := b.size.X\n\trowPerReq := xPutImageReqDataSize / (widthPerReq * 4)\n\tdataPerReq := rowPerReq * widthPerReq * 4\n\tdstX := dp.X\n\tdstY := dp.Y\n\tstart := 0\n\tend := 0\n\n\tfor end < len(b.buf) {\n\t\tend = start + dataPerReq\n\t\tif end > len(b.buf) {\n\t\t\tend = len(b.buf)\n\t\t}\n\n\t\tdata := b.buf[start:end]\n\t\theightPerReq := len(data) / (widthPerReq * 4)\n\n\t\txproto.PutImage(\n\t\t\tb.xc, xproto.ImageFormatZPixmap, xd, xg,\n\t\t\tuint16(widthPerReq), uint16(heightPerReq),\n\t\t\tint16(dstX), int16(dstY),\n\t\t\t0, depth, data)\n\n\t\tstart = end\n\t\tdstY += rowPerReq\n\t}\n}", "func CopyPixels(x int32, y int32, width int32, height int32, xtype uint32) {\n\tC.glowCopyPixels(gpCopyPixels, (C.GLint)(x), (C.GLint)(y), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLenum)(xtype))\n}", "func (i *ImageBuf) CopyPixels(src *ImageBuf) error {\n\tok := bool(C.ImageBuf_copy_pixels(i.ptr, src.ptr))\n\truntime.KeepAlive(i)\n\truntime.KeepAlive(src)\n\tif !ok {\n\t\treturn i.LastError()\n\t}\n\treturn nil\n}", "func i2cWriteBytes(buf []byte) (err error) {\n\ttime.Sleep(1 * time.Millisecond) // By design, must not send more than once every 1Ms\n\treg := make([]byte, 1)\n\treg[0] = byte(len(buf))\n\treg = append(reg, buf...)\n\treturn openI2CPort.device.Tx(reg, nil)\n}", "func (s *Surface) SetPixelData(data []color.RGBA, area geo.Rect) {\n\tx, y, w, h := math.Floor(area.X), math.Floor(area.Y), math.Floor(area.W), math.Floor(area.H)\n\timgData := s.Ctx.Call(\"getImageData\", x, y, w, h)\n\tpxData := imgData.Get(\"data\")\n\tfor i := 0; i < len(data); i++ {\n\t\tpxData.SetIndex(i*4, data[i].R)\n\t\tpxData.SetIndex(i*4+1, data[i].G)\n\t\tpxData.SetIndex(i*4+2, data[i].B)\n\t\tpxData.SetIndex(i*4+3, data[i].A)\n\t}\n\ts.Ctx.Call(\"putImageData\", imgData, x, y)\n}", "func (p *Packet) putBytes(b []byte) {\n\tp.buf = append(p.buf, b...)\n}", "func PutBytes(buf *[]byte) {\n\tbbPool.give(buf)\n}", "func (self *TileSprite) SetCanvasBufferA(member *PIXICanvasBuffer) {\n self.Object.Set(\"canvasBuffer\", member)\n}", "func (b *blockWriter) Write(input []byte) (int, error) {\n\tif b.err != nil {\n\t\treturn 0, b.err\n\t}\n\n\t// fill buffer if possible\n\tn := b.buf[0] // n is block size\n\tcopied := copy(b.buf[n+1:], input)\n\tb.buf[0] = n + byte(copied)\n\n\tif n+byte(copied) < 255 {\n\t\t// buffer not full; don't write yet\n\t\treturn copied, nil\n\t}\n\n\t// loop precondition: buffer is full\n\tfor {\n\t\tvar n2 int\n\t\tn2, b.err = b.w.Write(b.buf[:])\n\t\tif n2 < 256 && b.err == nil {\n\t\t\tb.err = io.ErrShortWrite\n\t\t}\n\t\tif b.err != nil {\n\t\t\treturn copied, b.err\n\t\t}\n\n\t\tn := copy(b.buf[1:], input[copied:])\n\t\tb.buf[0] = byte(n)\n\t\tcopied += n\n\t\tif n < 255 {\n\t\t\t// buffer not full\n\t\t\treturn copied, nil\n\t\t}\n\t}\n\n\t// postcondition: b.buf contains a block with n < 255, or b.err is set\n}", "func BlitFramebuffer(srcX0 int32, srcY0 int32, srcX1 int32, srcY1 int32, dstX0 int32, dstY0 int32, dstX1 int32, dstY1 int32, mask uint32, filter uint32) {\n C.glowBlitFramebuffer(gpBlitFramebuffer, (C.GLint)(srcX0), (C.GLint)(srcY0), (C.GLint)(srcX1), (C.GLint)(srcY1), (C.GLint)(dstX0), (C.GLint)(dstY0), (C.GLint)(dstX1), (C.GLint)(dstY1), (C.GLbitfield)(mask), (C.GLenum)(filter))\n}", "func (d *Device) SetPixel(x int16, y int16, c color.RGBA) {\n\tif x < 0 || y < 0 ||\n\t\t(((d.rotation == drivers.Rotation0 || d.rotation == drivers.Rotation180) && (x >= d.width || y >= d.height)) ||\n\t\t\t((d.rotation == drivers.Rotation90 || d.rotation == drivers.Rotation270) && (x >= d.height || y >= d.width))) {\n\t\treturn\n\t}\n\td.FillRectangle(x, y, 1, 1, c)\n}", "func DrawBuffer(buf uint32) {\n\tsyscall.Syscall(gpDrawBuffer, 1, uintptr(buf), 0, 0)\n}", "func BufferData(target uint32, size int, data unsafe.Pointer, usage uint32) {\n C.glowBufferData(gpBufferData, (C.GLenum)(target), (C.GLsizeiptr)(size), data, (C.GLenum)(usage))\n}", "func (f *volatileFile) Write(buf unsafe.Pointer, n int, offset int) C.int {\n\tf.mu.Lock()\n\tdefer f.mu.Unlock()\n\n\tif offset+n >= len(f.data) {\n\t\tf.data = append(f.data, make([]byte, offset+n-len(f.data))...)\n\t}\n\n\tsize := unsafe.Sizeof(byte(0))\n\n\tfor i := 0; i < n; i++ {\n\t\tj := i + offset\n\t\tf.data[j] = *(*byte)(unsafe.Pointer(uintptr(buf) + size*uintptr(i)))\n\t}\n\n\treturn C.SQLITE_OK\n}", "func (v *mandelbrotViewer) Draw(screen *ebiten.Image) {\n\tscreen.ReplacePixels(v.screenBuffer)\n\tv.debugPrint(screen)\n}", "func (c *CircBuf) Write(buf []byte) int {\n\tvar space int\n\tvar num int\n\tfor {\n\t\tspace = c.spaceToEnd()\n\t\tif len(buf) - num < space {\n\t\t\tspace = len(buf) - num\n\t\t}\n\t\tif space <= 0 {\n\t\t\tbreak\n\t\t}\n\t\tcopy(c.buf[c.head : c.head + space], buf[num : num + space])\n\t\tc.head = (c.head + space) & (len(c.buf) - 1)\n\t\tnum += space\n\t}\n\treturn num\n}", "func (buffer *Buffer) WriteBytes(p []byte) {\n\tif buffer == nil || buffer.B == nil {\n\t\treturn\n\t}\n\n\tif _, err := buffer.B.Write(p); err != nil {\n\t\t_, _ = fmt.Fprintf(os.Stderr, \"buffer write error: %v\\n\", err)\n\t\tbuffer.Error = err\n\t}\n}", "func (s *Stream) WriteFrameData(frame *Frame) error {\n\t_, err := s.file.Write(frame.Y)\n\tif err != nil {\n\t\treturn err\n\t}\n\t_, err = s.file.Write(frame.Cb)\n\tif err != nil {\n\t\treturn err\n\t}\n\t_, err = s.file.Write(frame.Cr)\n\tif err != nil {\n\t\treturn err\n\t}\n\t_, err = s.file.Write(frame.Alpha)\n\tif err != nil {\n\t\treturn err\n\t}\n\treturn nil\n}", "func writeFrame(buf *bytes.Buffer, fr frame) error {\n\theader := frameHeader{\n\t\tSize: 0, // overwrite later\n\t\tDataOffset: 2, // see frameHeader.DataOffset comment\n\t\tFrameType: fr.typ,\n\t\tChannel: fr.channel,\n\t}\n\n\t// write header\n\terr := binary.Write(buf, binary.BigEndian, header)\n\tif err != nil {\n\t\treturn err\n\t}\n\n\t// write AMQP frame body\n\terr = marshal(buf, fr.body)\n\tif err != nil {\n\t\treturn err\n\t}\n\n\t// validate size\n\tif buf.Len() > math.MaxUint32 {\n\t\treturn errorNew(\"frame too large\")\n\t}\n\n\t// retrieve raw bytes\n\tbufBytes := buf.Bytes()\n\n\t// write correct size\n\tbinary.BigEndian.PutUint32(bufBytes, uint32(len(bufBytes)))\n\treturn nil\n}", "func writeImage(w http.ResponseWriter, img *image.Image) {\r\n\r\n\tbuffer := new(bytes.Buffer)\r\n\tif err := jpeg.Encode(buffer, *img, nil); err != nil {\r\n\t\tlog.Println(\"unable to encode image.\")\r\n\t}\r\n\r\n\tw.Header().Set(\"Content-Type\", \"image/jpeg\")\r\n\tw.Header().Set(\"Content-Length\", strconv.Itoa(len(buffer.Bytes())))\r\n\tif _, err := w.Write(buffer.Bytes()); err != nil {\r\n\t\tlog.Println(\"unable to write image.\")\r\n\t}\r\n}", "func (device *Dev) Draw(dstRect image.Rectangle, src image.Image, srcPts image.Point) error {\n\t// Use stdlib image copying functionality.\n\tdraw.Draw(device.pixels, dstRect, src, srcPts, draw.Src)\n\t// And then copy the image into the transmission buffer, where it is sent via SPI.\n\treturn device.flush()\n}", "func (fb *FrameBuffer) SetColorAt(x int, y int, c color.Color) {\n\tif x >= 0 && y >= 0 && x < fb.width && y < fb.height {\n\t\tfb.img.Set(x, y, c) // = c\n\t}\n}", "func (fb *FrameBuffer) Flush() error {\n\tfb.file.Seek(0, 0)\n\t_, err := fb.file.Write(fb.buf)\n\treturn err\n}", "func (_Contract *ContractTransactor) BuyPixelBlocks(opts *bind.TransactOpts, _x []*big.Int, _y []*big.Int, _price []*big.Int, _contentData [][32]byte) (*types.Transaction, error) {\n\treturn _Contract.contract.Transact(opts, \"buyPixelBlocks\", _x, _y, _price, _contentData)\n}", "func (m *display) WriteScratch(addr int, data []byte) (int) {\n\tdat1 := []byte{0xFE, 0xCC}\n\taddrb := make([]byte,2)\n\tsizeb := make([]byte,2)\n\tbinary.LittleEndian.PutUint16(addrb, uint16(addr))\n\tbinary.LittleEndian.PutUint16(sizeb, uint16(len(data)))\n\tdat1 = append(dat1, addrb...)\n\tdat1 = append(dat1, sizeb...)\n\tdat1 = append(dat1, data...)\n\tn := m.Send(dat1)\n\n\treturn n\n}", "func (_Contract *ContractTransactorSession) SetPixelBlockPrices(_x []*big.Int, _y []*big.Int, _price []*big.Int) (*types.Transaction, error) {\n\treturn _Contract.Contract.SetPixelBlockPrices(&_Contract.TransactOpts, _x, _y, _price)\n}", "func SaveBufferRegionARB(hRegion unsafe.Pointer, x unsafe.Pointer, y unsafe.Pointer, width unsafe.Pointer, height unsafe.Pointer) unsafe.Pointer {\n\tret, _, _ := syscall.Syscall6(gpSaveBufferRegionARB, 5, uintptr(hRegion), uintptr(x), uintptr(y), uintptr(width), uintptr(height), 0)\n\treturn (unsafe.Pointer)(ret)\n}", "func (w *win) writeData(data []byte) {\n\tconst maxWrite = 512\n\tfor len(data) > 0 {\n\t\tsz := len(data)\n\t\tif sz > maxWrite {\n\t\t\tsz = maxWrite\n\t\t}\n\t\tn, err := w.Write(\"data\", data[:sz])\n\t\tif err != nil {\n\t\t\tpanic(\"Failed to write to window: \" + err.Error())\n\t\t}\n\t\tdata = data[n:]\n\t}\n}", "func WriteCount(buffer []byte, offset int, value byte, valueCount int) {\n for i := 0; i < valueCount; i++ {\n buffer[offset + i] = value\n }\n}", "func (d *Device) DrawRGBBitmap8(x, y int16, data []uint8, w, h int16) error {\n\tk, i := d.Size()\n\tif x < 0 || y < 0 || w <= 0 || h <= 0 ||\n\t\tx >= k || (x+w) > k || y >= i || (y+h) > i {\n\t\treturn errOutOfBounds\n\t}\n\td.startWrite()\n\td.setWindow(x, y, w, h)\n\td.bus.Tx(data, nil)\n\td.endWrite()\n\treturn nil\n}", "func (pal *CGBPalette) write(value byte) {\n\tpal.palette[pal.index] = value\n\tif pal.inc {\n\t\tpal.index = (pal.index + 1) & 0x3F\n\t}\n}", "func (b *Bitmap) Buffer() []byte {\n\tl := b.Rows() * b.Pitch()\n\treturn C.GoBytes(unsafe.Pointer(b.handle.buffer), C.int(l))\n}", "func (color *Color) writeBlockType(w io.Writer) (err error) {\n\treturn binary.Write(w, binary.BigEndian, colorEntry)\n}", "func (_Contract *ContractSession) SetPixelBlockPrices(_x []*big.Int, _y []*big.Int, _price []*big.Int) (*types.Transaction, error) {\n\treturn _Contract.Contract.SetPixelBlockPrices(&_Contract.TransactOpts, _x, _y, _price)\n}", "func (b *Buffer) Dump() {\n\ts := *b.screen\n\traster := canvas.NewRasterFromImage(b.context.Image())\n\ts.SetContent(raster)\n}", "func (a *PixelSubArray) set(x, y int) {\n\txByte := x/8 - a.xStartByte\n\txBit := uint(x % 8)\n\tyRow := y - a.yStart\n\n\tif yRow > len(a.bytes) {\n\t\tfmt.Println(\"Y OOB:\", len(a.bytes), yRow)\n\t}\n\n\tif xByte > len(a.bytes[0]) {\n\t\tfmt.Println(\"X OOB:\", len(a.bytes[0]), xByte)\n\t}\n\n\ta.bytes[yRow][xByte] |= (1 << xBit)\n}", "func (p *Plasma) Draw(screen *ebiten.Image) {\r\n\tscreen.ReplacePixels(p.buffer)\r\n}", "func WriteSlice(buffer []byte, offset int, value []byte, valueOffset int, valueSize int) {\n copy(buffer[offset:offset + len(value)], value[valueOffset:valueOffset + valueSize])\n}", "func MapBuffer(target uint32, access uint32) unsafe.Pointer {\n ret := C.glowMapBuffer(gpMapBuffer, (C.GLenum)(target), (C.GLenum)(access))\n return (unsafe.Pointer)(ret)\n}", "func DrawBuffers(n int32, bufs *uint32) {\n C.glowDrawBuffers(gpDrawBuffers, (C.GLsizei)(n), (*C.GLenum)(unsafe.Pointer(bufs)))\n}", "func Write(fd uintptr, p unsafe.Pointer, n int32) int32" ]
[ "0.6357358", "0.62441885", "0.62223816", "0.6217486", "0.6097679", "0.58984864", "0.56547713", "0.5644312", "0.5644312", "0.56073695", "0.5579061", "0.5522711", "0.5476901", "0.540433", "0.5395827", "0.5359163", "0.5292596", "0.5232991", "0.52218676", "0.5205745", "0.51927984", "0.51860994", "0.5153141", "0.5146672", "0.51337165", "0.5105036", "0.50916994", "0.50804937", "0.50663", "0.50571704", "0.50559723", "0.5050416", "0.5038832", "0.5031863", "0.5027138", "0.501772", "0.50155383", "0.50119674", "0.5005985", "0.49891824", "0.49739242", "0.49117532", "0.48825118", "0.48801", "0.48744562", "0.48739493", "0.48670107", "0.48617885", "0.48565972", "0.48513728", "0.4845626", "0.48322028", "0.4831461", "0.4829569", "0.48092797", "0.4796734", "0.47761047", "0.47723204", "0.47586134", "0.47463858", "0.47430962", "0.47388217", "0.47385266", "0.4735924", "0.47325835", "0.47261187", "0.47253647", "0.47155103", "0.47152132", "0.47071865", "0.4698815", "0.4696698", "0.4687936", "0.46869758", "0.46845746", "0.46828467", "0.4644644", "0.46420237", "0.4640683", "0.46393377", "0.4638113", "0.46356627", "0.46334523", "0.4614903", "0.46134883", "0.4609968", "0.46084878", "0.45965338", "0.4595129", "0.4575369", "0.45733133", "0.45705172", "0.45602438", "0.45545074", "0.45532724", "0.45486644", "0.45437405", "0.45423946", "0.4542347", "0.4537041" ]
0.51807594
22
render primitives from array data
func DrawRangeElements(mode uint32, start uint32, end uint32, count int32, xtype uint32, indices unsafe.Pointer) { C.glowDrawRangeElements(gpDrawRangeElements, (C.GLenum)(mode), (C.GLuint)(start), (C.GLuint)(end), (C.GLsizei)(count), (C.GLenum)(xtype), indices) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func renderResults(vals []interface{}) Data {\n\tvar nilcount int\n\tvar obj interface{}\n\tfor _, val := range vals {\n\t\tswitch val.(type) {\n\t\tcase image.Image, Data:\n\t\t\tobj = val\n\t\tcase nil:\n\t\t\tnilcount++\n\t\t}\n\t}\n\tif obj != nil && nilcount == len(vals)-1 {\n\t\tswitch val := obj.(type) {\n\t\tcase image.Image:\n\t\t\tdata, err := image0(val)\n\t\t\tif err == nil {\n\t\t\t\treturn data\n\t\t\t}\n\t\tcase Data:\n\t\t\treturn val\n\t\t}\n\t}\n\tif nilcount == len(vals) {\n\t\t// if all values are nil, return empty Data\n\t\treturn Data{}\n\t}\n\treturn MakeData(\"text/plain\", fmt.Sprint(vals...))\n}", "func (v Binary) Render(i, width int, baseStyle lipgloss.Style) string {\n\tw := dataWidth(width)\n\t_, err := v.Seek(int64(i*w), io.SeekStart)\n\tif err != nil {\n\t\treturn baseStyle.Blink(true).Render(err.Error())\n\t}\n\tif len(v.b) != w {\n\t\tv.b = make([]byte, w)\n\t}\n\tn, err := v.Read(v.b)\n\tif err != nil && !errors.Is(err, io.EOF) {\n\t\treturn baseStyle.Blink(true).Render(err.Error())\n\t}\n\ts := fmt.Sprintf(\"% X%s \", v.b[0:n], strings.Repeat(\" \", w-n))\n\tvar x strings.Builder\n\tfor i := 0; i < n; i++ {\n\t\tif unicode.IsPrint(rune(v.b[i])) {\n\t\t\tx.WriteRune(rune(v.b[i]))\n\t\t} else {\n\t\t\tx.WriteRune('.')\n\t\t}\n\t}\n\treturn baseStyle.Render(s + x.String())\n}", "func (sr scoresRenderer) Render() string {\n\tbuffer := bytes.Buffer{}\n\tlast := len(sr.scores) - 1\n\tfor i, score := range sr.scores {\n\t\tbuffer.WriteString(fmt.Sprintf(\"%d\", score))\n\t\tif i != last {\n\t\t\tbuffer.WriteString(\" / \")\n\t\t}\n\t}\n\treturn buffer.String()\n}", "func (r *Renderer) Render() {\n\tsx, sz, sy := r.c.Bounds()\n\tsxf := float64(sx - 1)\n\tsyf := float64(sy - 1)\n\tszf := float64(sz - 1)\n\tfor z := 0; z < sz; z++ {\n\t\tfor y := 0; y < sy; y++ {\n\t\t\tfor x := 0; x < sx; x++ {\n\t\t\t\tvar lr, lg, lb, _ uint32\n\t\t\t\tn := uint32(0)\n\t\t\t\tfor _, o := range r.objects {\n\t\t\t\t\tr, g, b, _ := o.At(float64(x)/sxf, float64(y)/syf, float64(z)/szf).RGBA()\n\t\t\t\t\tlr += r >> 8\n\t\t\t\t\tlg += g >> 8\n\t\t\t\t\tlb += b >> 8\n\t\t\t\t\tn++\n\t\t\t\t}\n\t\t\t\tr.c.Set(x, y, z, color.RGBA{uint8(lr/n), uint8(lg/n), uint8(lb/n), 255})\n\t\t\t}\n\t\t}\n\t}\n\tr.c.Render()\n}", "func render(fset *token.FileSet, x interface{}) string {\n\tvar buf bytes.Buffer\n\tif err := printer.Fprint(&buf, fset, x); err != nil {\n\t\tpanic(err)\n\t}\n\treturn buf.String()\n}", "func render(fset *token.FileSet, x interface{}) string {\n\tvar buf bytes.Buffer\n\tif err := printer.Fprint(&buf, fset, x); err != nil {\n\t\tpanic(err)\n\t}\n\treturn buf.String()\n}", "func (a Array) String() string {\n\tvar buf bytes.Buffer\n\tfor i, v := range a {\n\t\tbuf.WriteString(fmt.Sprintf(\"[%2d] %[2]v (%[2]T)\\n\", i, v))\n\t}\n\treturn buf.String()\n}", "func (e *rawData) Render(w io.Writer) (int, error) { return w.Write([]byte(e.content)) }", "func (sl SprintList) renderPlain(w io.Writer) error {\n\treturn renderPlain(w, sl.tableData())\n}", "func (t *textRender) Render(w io.Writer) (err error) {\n\tif len(t.Values) > 0 {\n\t\t_, err = fmt.Fprintf(w, t.Format, t.Values...)\n\t} else {\n\t\t_, err = io.WriteString(w, t.Format)\n\t}\n\treturn\n}", "func (val *float32ArrayValue) String() string {\n\tvar buffer strings.Builder\n\tfor _, v := range *val {\n\t\tif buffer.Len() != 0 {\n\t\t\tbuffer.WriteString(\", \")\n\t\t}\n\t\tfmt.Fprintf(&buffer, \"%v\", v)\n\t}\n\treturn buffer.String()\n}", "func (c *Controller) Data(data []byte) {\n ctx := c.Context()\n r := render.NewData(data)\n\n ctx.PushLog(\"status\", http.StatusOK)\n ctx.SetHeader(\"Content-Type\", r.ContentType())\n ctx.End(r.HttpCode(), r.Content())\n}", "func (a *Array) Print() {\n\tvar format string\n\tfor i := uint(0); i < a.Len(); i++ {\n\t\tformat += fmt.Sprintf(\"|%+v\", a.data[i])\n\t}\n\tfmt.Println(format)\n}", "func (val *uint8ArrayValue) String() string {\n\tvar buffer strings.Builder\n\tfor _, v := range *val {\n\t\tif buffer.Len() != 0 {\n\t\t\tbuffer.WriteString(\", \")\n\t\t}\n\t\tfmt.Fprintf(&buffer, \"%v\", v)\n\t}\n\treturn buffer.String()\n}", "func (tofu Tofu) Render(wr io.Writer, name string, obj interface{}) error {\n\tvar m data.Map\n\tif obj != nil {\n\t\tvar ok bool\n\t\tm, ok = data.New(obj).(data.Map)\n\t\tif !ok {\n\t\t\treturn fmt.Errorf(\"invalid data type. expected map/struct, got %T\", obj)\n\t\t}\n\t}\n\treturn tofu.NewRenderer(name).Execute(wr, m)\n}", "func (l LogItems) Render(showTime bool, ll [][]byte) {\n\tcolors := make(map[string]int, len(l))\n\tfor i, item := range l {\n\t\tinfo := item.ID()\n\t\tcolor, ok := colors[info]\n\t\tif !ok {\n\t\t\tcolor = colorFor(info)\n\t\t\tcolors[info] = color\n\t\t}\n\t\tll[i] = item.Render(color, showTime)\n\t}\n}", "func (o TypeResponseOutput) Primitive() pulumi.StringOutput {\n\treturn o.ApplyT(func(v TypeResponse) string { return v.Primitive }).(pulumi.StringOutput)\n}", "func (g *Game) Render() string {\n\tascii := \"\"\n\n\tm := g.generateScreen()\n\tfor _, row := range m.cells {\n\t\tascii += strings.Join(row, \"\") + \"\\n\"\n\t}\n\n\treturn ascii\n}", "func renderDisplayData(value interface{}) (data, metadata map[string]interface{}, err error) {\n\t// TODO(axw) sniff/provide a way to specify types for things that net/http does not sniff:\n\t// - SVG\n\t// - JSON\n\t// - LaTeX\n\tdata = make(map[string]interface{})\n\tmetadata = make(map[string]interface{})\n\tvar stringValue, contentType string\n\tswitch typedValue := value.(type) {\n\tcase image.Image:\n\t\t// TODO(axw) provide a way for the user to use alternative encodings?\n\t\t//\n\t\t// The current presumption is that images will be mostly used\n\t\t// for displaying graphs or illustrations where PNG produces\n\t\t// better looking images.\n\t\tvar buf bytes.Buffer\n\t\tif err := png.Encode(&buf, typedValue); err != nil {\n\t\t\treturn nil, nil, fmt.Errorf(\"encoding image: %v\", err)\n\t\t}\n\t\tbounds := typedValue.Bounds()\n\t\tdata[\"image/png\"] = buf.Bytes()\n\t\tdata[\"text/plain\"] = fmt.Sprintf(\"%dx%d image\", bounds.Dx(), bounds.Dy())\n\t\tmetadata[\"image/png\"] = map[string]interface{}{\n\t\t\t\"width\": bounds.Dx(),\n\t\t\t\"height\": bounds.Dy(),\n\t\t}\n\t\treturn data, metadata, nil\n\n\tcase []byte:\n\t\tcontentType = detectContentType(typedValue)\n\t\tstringValue = string(typedValue)\n\n\tcase string:\n\t\tcontentType = detectContentType([]byte(typedValue))\n\t\tstringValue = typedValue\n\n\tdefault:\n\t\tstringValue = fmt.Sprint(typedValue)\n\t\tvalue = stringValue\n\t\tcontentType = detectContentType([]byte(stringValue))\n\t}\n\n\tdata[\"text/plain\"] = stringValue\n\tif contentType != \"text/plain\" {\n\t\t// \"A plain text representation should always be\n\t\t// provided in the text/plain mime-type.\"\n\t\tdata[contentType] = value\n\t}\n\treturn data, metadata, nil\n}", "func (e *expression) printArray() string {\n\ta := \"\"\n\n\tfor i := 0; i < len(e.lenArray); i++ {\n\t\tvArray := string('i' + i)\n\t\ta += fmt.Sprintf(\"[%s]\", vArray)\n\t}\n\treturn a\n}", "func (Parser) Render(rawBytes []byte, urlPrefix string, metas map[string]string, isWiki bool) []byte {\n\treturn Render(rawBytes, urlPrefix, metas, isWiki)\n}", "func (s *SegmentRoot) Render() []byte {\n\tvar b bytes.Buffer\n\tb.Write(SetBackground(SegmentRootBackground))\n\tfmt.Fprint(&b, \" \")\n\tb.Write(s.Data)\n\tfmt.Fprint(&b, \" \")\n\treturn b.Bytes()\n}", "func (rf RendererFunc) Render(w io.Writer, v interface{}) error { return rf(w, v) }", "func Data(w http.ResponseWriter, r *http.Request, v []byte) {\n\trender.Data(w, r, v)\n}", "func (f Frame) Render() string {\n\tsb := strings.Builder{}\n\tfor _, row := range f {\n\t\tfor _, shade := range row {\n\t\t\tsb.WriteString(fmt.Sprintf(\"%d\", shade))\n\t\t}\n\t\tsb.WriteString(\"\\n\")\n\t}\n\tsb.WriteString(\"==============================\\n\")\n\n\treturn sb.String()\n}", "func (a *Array) Format(f fmt.State, c rune) {\n\tswitch c {\n\tcase 'z': // Private format specifier, supports Entity.Signature\n\t\tfmt.Fprintf(f, \"[%d]%z\", a.Size, a.ValueType)\n\tcase 'r': // Private format specifier, supports Type.Representation\n\t\tfmt.Fprintf(f, \"[%d]%r\", a.Size, a.ValueType)\n\tdefault:\n\t\tif a.Alias != \"\" {\n\t\t\tfmt.Fprint(f, a.Alias)\n\t\t} else {\n\t\t\tfmt.Fprintf(f, \"[%d]%v\", a.Size, a.ValueType)\n\t\t}\n\t}\n}", "func DrawArrays(mode Enum, first, count int) {\n\tgl.DrawArrays(uint32(mode), int32(first), int32(count))\n}", "func (c *cartridge) Render() {\n\tc.Cls()\n\tc.PrintAt(fmt.Sprintf(\"counter:%d\", c.counter), c.x, c.y)\n}", "func (r ConsoleTreeRenderer) RenderTree(root *ContainerNode, _ string) string {\n\n\tsb := strings.Builder{}\n\n\tfor _, node := range root.Items {\n\t\tfieldKey := node.Field().Name\n\t\tsb.WriteString(fieldKey)\n\t\tfor i := len(fieldKey); i <= root.MaxKeyLength; i++ {\n\t\t\tsb.WriteRune(' ')\n\t\t}\n\n\t\tvalueLen := 0\n\t\tpreLen := 16\n\n\t\tfield := node.Field()\n\n\t\tif r.WithValues {\n\t\t\tpreLen = 30\n\t\t\tvalueLen = r.writeNodeValue(&sb, node)\n\t\t} else {\n\t\t\t// Since no values was supplied, let's substitute the value with the type\n\t\t\ttypeName := field.Type.String()\n\n\t\t\t// If the value is an enum type, providing the name is a bit pointless\n\t\t\t// Instead, use a common string \"option\" to signify the type\n\t\t\tif field.EnumFormatter != nil {\n\t\t\t\ttypeName = \"option\"\n\t\t\t}\n\t\t\tvalueLen = len(typeName)\n\t\t\tsb.WriteString(color.CyanString(typeName))\n\t\t}\n\n\t\tsb.WriteString(strings.Repeat(\" \", util.Max(preLen-valueLen, 1)))\n\t\tsb.WriteString(ColorizeDesc(field.Description))\n\t\tsb.WriteString(strings.Repeat(\" \", util.Max(60-len(field.Description), 1)))\n\n\t\tif len(field.URLParts) > 0 && field.URLParts[0] != URLQuery {\n\t\t\tsb.WriteString(\" <URL: \")\n\t\t\tfor i, part := range field.URLParts {\n\t\t\t\tif i > 0 {\n\t\t\t\t\tsb.WriteString(\", \")\n\t\t\t\t}\n\t\t\t\tif part > URLPath {\n\t\t\t\t\tpart = URLPath\n\t\t\t\t}\n\t\t\t\tsb.WriteString(ColorizeEnum(part))\n\t\t\t}\n\t\t\tsb.WriteString(\">\")\n\t\t}\n\n\t\tif len(field.Template) > 0 {\n\t\t\tsb.WriteString(fmt.Sprintf(\" <Template: %s>\", ColorizeString(field.Template)))\n\t\t}\n\n\t\tif len(field.DefaultValue) > 0 {\n\t\t\tsb.WriteString(fmt.Sprintf(\" <Default: %s>\", ColorizeValue(field.DefaultValue, field.EnumFormatter != nil)))\n\t\t}\n\n\t\tif field.Required {\n\t\t\tsb.WriteString(fmt.Sprintf(\" <%s>\", ColorizeFalse(\"Required\")))\n\t\t}\n\n\t\tif len(field.Keys) > 1 {\n\t\t\tsb.WriteString(\" <Aliases: \")\n\t\t\tfor i, key := range field.Keys {\n\t\t\t\tif i == 0 {\n\t\t\t\t\t// Skip primary alias (as it's the same as the field name)\n\t\t\t\t\tcontinue\n\t\t\t\t}\n\t\t\t\tif i > 1 {\n\t\t\t\t\tsb.WriteString(\", \")\n\t\t\t\t}\n\t\t\t\tsb.WriteString(ColorizeString(key))\n\t\t\t}\n\t\t\tsb.WriteString(\">\")\n\t\t}\n\n\t\tif field.EnumFormatter != nil {\n\t\t\tsb.WriteString(ColorizeContainer(\" [\"))\n\t\t\tfor i, name := range field.EnumFormatter.Names() {\n\t\t\t\tif i != 0 {\n\t\t\t\t\tsb.WriteString(\", \")\n\t\t\t\t}\n\t\t\t\tsb.WriteString(ColorizeEnum(name))\n\t\t\t}\n\n\t\t\tsb.WriteString(ColorizeContainer(\"]\"))\n\t\t}\n\n\t\tsb.WriteRune('\\n')\n\t}\n\n\treturn sb.String()\n}", "func (vao *VAO) Render() {\n\tgl.BindVertexArray(vao.handle)\n\tif vao.indexBuffer != nil {\n\t\tgl.BindBuffer(gl.ELEMENT_ARRAY_BUFFER, vao.indexBuffer.GetHandle())\n\t\tgl.DrawElements(vao.mode, vao.indexBuffer.Len(), gl.UNSIGNED_SHORT, nil)\n\t\tgl.BindBuffer(gl.ELEMENT_ARRAY_BUFFER, 0)\n\t} else {\n\t\tgl.DrawArrays(vao.mode, 0, vao.vertexBuffers[0].Len())\n\t}\n\tgl.BindVertexArray(0)\n}", "func (r *Renderer) Render() {\n\tgl.DrawArrays(gl.TRIANGLES, 0, int32(len(r.RawRenderer)*4))\n}", "func (s *Square) Render() string {\n\treturn fmt.Sprintf(\"Square side %f\", s.Side)\n}", "func (renderer *SimpleMatrixRenderer) Render() {\n\trenderer.renderCharacter(\"\\n\")\n\n\tfor row := 0; row < renderer.Matrix.Height; row++ {\n\t\tfor col := 0; col < renderer.Matrix.Width; col++ {\n\t\t\tif !renderer.Matrix.IsFieldOccupied(row, col) {\n\t\t\t\trenderer.renderUnoccupiedField()\n\t\t\t} else {\n\t\t\t\trenderer.renderOccupiedFieldAtCurrentCursorPos(row, col)\n\t\t\t}\n\t\t}\n\n\t\trenderer.renderCharacter(\"\\n\")\n\t}\n\n\trenderer.renderCharacter(\"\\n\")\n}", "func (a *Array) String() string {\n\tbuf := new(bytes.Buffer)\n\tfor i := len(a.bits) - 1; i >= 0; i-- {\n\t\tbits := fmt.Sprintf(\"%16X\", a.bits[i])\n\t\tbits = strings.Replace(bits, \" \", \"0\", -1)\n\t\tfmt.Fprintf(buf, \"%s [%d-%d] \", bits, (i<<6)+63, i<<6)\n\t}\n\n\treturn buf.String()\n}", "func (h *HAProxyManager) render(ports []uint16) ([]byte, error) {\n\n\t// prepare the context\n\td := make([]templateContext, len(ports))\n\tfor i, port := range ports {\n\t\tif i == len(h.serviceAddrs) {\n\t\t\th.logger.Warnf(\"got port index %d, but only have %d service addrs. ports=%v serviceAddrs=%v\", i, len(h.serviceAddrs), ports, h.serviceAddrs)\n\t\t\tcontinue\n\t\t}\n\t\td[i] = templateContext{Port: port, Source: h.listenAddr, Dest: h.serviceAddrs[i]}\n\t}\n\n\t// render the template\n\tbuf := &bytes.Buffer{}\n\tif err := h.template.Execute(buf, d); err != nil {\n\t\treturn nil, err\n\t}\n\treturn buf.Bytes(), nil\n}", "func PrintArr(a []interface{}) {\n\tvar i int\n\tfor i < len(a) {\n\t\tfmt.Printf(\"%v\\t\", a[i])\n\t\ti++\n\t}\n\tfmt.Printf(\"\\n\")\n}", "func (a *Array) Literal() {}", "func (c *Client) ShowArrayPrism(ctx context.Context, path string, anyArray []interface{}, boolArray []bool, dateTimeArray []time.Time, intArray []int, numArray []float64, stringArray []string, uuidArray []uuid.UUID) (*http.Response, error) {\n\treq, err := c.NewShowArrayPrismRequest(ctx, path, anyArray, boolArray, dateTimeArray, intArray, numArray, stringArray, uuidArray)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\treturn c.Client.Do(ctx, req)\n}", "func (c *ConnectionSPI) Render(pixels []RGBPixel) {\r\n\tlogFields := log.Fields{\"package\": logPkg, \"conn\": \"SPI\", \"func\": \"RenderLEDs\"}\r\n\tlog.WithFields(logFields).Infof(\"Render %d LEDs\", len(pixels))\r\n\t// Fix for Raspberry Pi 3 Model B+ (5.15.84-v7+)\r\n\t// Data signal seems to be splitted sending less than 11 LEDS\r\n\tif len(pixels) < 11 {\r\n\t\tpixels = append(pixels, []RGBPixel{{}, {}, {}, {}, {}, {}, {}, {}, {}, {}}...)\r\n\t}\r\n\tvar translatedRGBs []uint8\r\n\tfor _, pixel := range pixels {\r\n\r\n\t\tcolorData := GetColorData(pixel, c.FixSPI)\r\n\t\tlog.WithFields(logFields).Tracef(\"%08b\", pixel)\r\n\r\n\t\tfor _, c := range colorData {\r\n\t\t\ttranslatedRGBs = append(translatedRGBs, c)\r\n\t\t}\r\n\t}\r\n\r\n\tc.transfer(translatedRGBs)\r\n}", "func (l *LogItems) Render(showTime bool, ll [][]byte) {\n\tindex := len(l.colors)\n\tfor i, item := range l.items {\n\t\tid := item.ID()\n\t\tcolor, ok := l.colors[id]\n\t\tif !ok {\n\t\t\tif index >= len(colorPalette) {\n\t\t\t\tindex = 0\n\t\t\t}\n\t\t\tcolor = colorPalette[index]\n\t\t\tl.colors[id] = color\n\t\t\tindex++\n\t\t}\n\t\tll[i] = item.Render(int(color-tcell.ColorValid), showTime)\n\t}\n}", "func Text(v interface{}) HTML {\n return HTML(\"\\n\" + html.EscapeString(fmt.Sprint(v)))\n}", "func Render(expr expreduceapi.Ex) (chart.Chart, error) {\n\tgraph := chart.Chart{\n\t\tWidth: 360,\n\t\tHeight: 220,\n\t\tXAxis: chart.XAxis{\n\t\t\tStyle: chart.Style{Show: true},\n\t\t},\n\t\tYAxis: chart.YAxis{\n\t\t\tStyle: chart.Style{Show: true},\n\t\t},\n\t}\n\n\tgraphics, ok := atoms.HeadAssertion(expr, \"System`Graphics\")\n\tif !ok {\n\t\treturn graph, fmt.Errorf(\"trying to render a non-Graphics[] expression: %v\", expr)\n\t}\n\n\tif graphics.Len() < 1 {\n\t\treturn graph, errors.New(\"the Graphics[] expression must have at least one argument\")\n\t}\n\n\tstyle := chart.Style{\n\t\tShow: true,\n\t\tStrokeColor: drawing.ColorBlack,\n\t}\n\terr := renderPrimitive(&graph, graphics.GetPart(1), &style)\n\tif err != nil {\n\t\treturn graph, errors.New(\"failed to render primitive\")\n\t}\n\n\treturn graph, nil\n}", "func (native *OpenGL) DrawElements(mode uint32, count int32, elementType uint32, indices uintptr) {\n\tgl.DrawElements(mode, count, elementType, unsafe.Pointer(indices)) // nolint: govet,gas\n}", "func main() {\n\t//composite literal - create different values of a type\n\t// x := type{values}\n\t//group together values OF THE SAME TYPE\n\tx := []int{4, 5, 7, 8, 42}\n\n\tfmt.Println(x)\n\tfmt.Println(x[0]) //query by index position\n\tfmt.Println(x[1])\n\tfmt.Println(x[2])\n\tfmt.Println(x[3])\n\tfmt.Println(x[4])\n\tfmt.Println(cap(x))\n\n\t//for index and value in the range of x print\n\tfor i, v := range x {\n\t\tfmt.Println(i, v)\n\t}\n}", "func (obj *Device) DrawIndexedPrimitive(\n\ttyp PRIMITIVETYPE,\n\tbaseVertexIndex int,\n\tminIndex uint,\n\tnumVertices uint,\n\tstartIndex uint,\n\tprimitiveCount uint,\n) Error {\n\tret, _, _ := syscall.Syscall9(\n\t\tobj.vtbl.DrawIndexedPrimitive,\n\t\t7,\n\t\tuintptr(unsafe.Pointer(obj)),\n\t\tuintptr(typ),\n\t\tuintptr(baseVertexIndex),\n\t\tuintptr(minIndex),\n\t\tuintptr(numVertices),\n\t\tuintptr(startIndex),\n\t\tuintptr(primitiveCount),\n\t\t0,\n\t\t0,\n\t)\n\treturn toErr(ret)\n}", "func (d *Device) Render() error {\n\tbuf := new(bytes.Buffer)\n\n\tfor _, chain := range d.LEDs {\n\t\tfor _, col := range chain {\n\t\t\tbuf.Write([]byte{col.R, col.G, col.B})\n\t\t}\n\t}\n\n\t_, err := Conn.WriteToUDP(buf.Bytes(), d.Addr)\n\treturn err\n}", "func (vl *ValueArray) String() string {\n\treturn fmt.Sprintf(\"%v\", vl.array)\n}", "func encode(buf *bytes.Buffer, v reflect.Value) error {\n\tswitch v.Kind() {\n\tcase reflect.Invalid: // ignore\n\n\tcase reflect.Float32, reflect.Float64:\n\t\tfmt.Fprintf(buf, \"%f\", v.Float())\n\n\tcase reflect.Complex128, reflect.Complex64:\n\t\tc := v.Complex()\n\t\tfmt.Fprintf(buf, \"#C(%f %f)\", real(c), imag(c))\n\n\tcase reflect.Bool:\n\t\tif v.Bool() {\n\t\t\tfmt.Fprintf(buf, \"t\")\n\t\t}\n\n\tcase reflect.Interface:\n\t\t// type output\n\t\tt := v.Elem().Type()\n\n\t\tleftBuffer := new(bytes.Buffer)\n\t\trightBuffer := new(bytes.Buffer)\n\n\t\tif t.Name() == \"\" { // 名前がつけられてないtypeはそのまま表示する\n\t\t\tfmt.Fprintf(leftBuffer, \"%q\", t)\n\t\t} else {\n\t\t\tfmt.Fprintf(leftBuffer, \"\\\"%s.%s\\\" \", t.PkgPath(), t.Name()) //一意ではないとはこういうことか?\n\t\t}\n\n\t\t// value output\n\t\tif err := encode(rightBuffer, v.Elem()); err != nil {\n\t\t\treturn err\n\t\t}\n\n\t\tif len(rightBuffer.Bytes()) != 0 {\n\t\t\tbuf.WriteByte('(')\n\t\t\tbuf.Write(leftBuffer.Bytes())\n\t\t\tbuf.WriteByte(' ')\n\t\t\tbuf.Write(rightBuffer.Bytes())\n\t\t\tbuf.WriteByte(')')\n\t\t}\n\n\tcase reflect.Int, reflect.Int8, reflect.Int16,\n\t\treflect.Int32, reflect.Int64:\n\t\tfmt.Fprintf(buf, \"%d\", v.Int())\n\n\tcase reflect.Uint, reflect.Uint8, reflect.Uint16,\n\t\treflect.Uint32, reflect.Uint64, reflect.Uintptr:\n\t\tfmt.Fprintf(buf, \"%d\", v.Uint())\n\n\tcase reflect.String:\n\t\tfmt.Fprintf(buf, \"%q\", v.String())\n\n\tcase reflect.Ptr:\n\t\treturn encode(buf, v.Elem())\n\n\tcase reflect.Array, reflect.Slice: // (value ...)\n\n\t\tcontent := new(bytes.Buffer)\n\n\t\tisFirst := true\n\n\t\tfor i := 0; i < v.Len(); i++ {\n\t\t\tif isFirst {\n\t\t\t\tisFirst = false\n\t\t\t\tcontent.WriteByte(' ')\n\t\t\t}\n\t\t\tif err := encode(content, v.Index(i)); err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\t\t}\n\n\t\tif len(content.Bytes()) != 0 {\n\t\t\tbuf.WriteByte('(')\n\t\t\tbuf.Write(content.Bytes())\n\t\t\tbuf.WriteByte(')')\n\t\t}\n\n\tcase reflect.Struct: // ((name value) ...)\n\n\t\tcontent := new(bytes.Buffer)\n\n\t\tisFirst := true\n\n\t\tfor i := 0; i < v.NumField(); i++ {\n\t\t\trightBuffer := new(bytes.Buffer)\n\t\t\tif err := encode(rightBuffer, v.Field(i)); err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\n\t\t\tif len(rightBuffer.Bytes()) != 0 {\n\t\t\t\tif isFirst {\n\t\t\t\t\tcontent.WriteByte(' ')\n\t\t\t\t\tisFirst = false\n\t\t\t\t}\n\t\t\t\tcontent.WriteByte('(')\n\t\t\t\tfmt.Fprintf(content, \"%s\", v.Type().Field(i).Name)\n\t\t\t\tcontent.WriteByte(' ')\n\t\t\t\tcontent.Write(rightBuffer.Bytes())\n\t\t\t\tcontent.WriteByte(')')\n\t\t\t}\n\t\t}\n\n\t\tif len(content.Bytes()) != 0 {\n\t\t\tbuf.WriteByte('(')\n\t\t\tbuf.Write(content.Bytes())\n\t\t\tbuf.WriteByte(')')\n\t\t}\n\n\tcase reflect.Map: // ((key value) ...)\n\t\tisFirst := true\n\t\tcontent := new(bytes.Buffer)\n\n\t\tfor _, key := range v.MapKeys() {\n\t\t\tif isFirst {\n\t\t\t\tcontent.WriteByte(' ')\n\t\t\t\tisFirst = false\n\t\t\t}\n\n\t\t\tleftBuffer := new(bytes.Buffer)\n\t\t\trightBuffer := new(bytes.Buffer)\n\n\t\t\tif err := encode(leftBuffer, key); err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\t\t\tif err := encode(rightBuffer, v.MapIndex(key)); err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\n\t\t\tif len(rightBuffer.Bytes()) != 0 {\n\t\t\t\tcontent.WriteByte('(')\n\t\t\t\tcontent.Write(leftBuffer.Bytes())\n\t\t\t\tcontent.WriteByte(' ')\n\t\t\t\tcontent.Write(rightBuffer.Bytes())\n\t\t\t\tcontent.WriteByte(')')\n\t\t\t}\n\t\t}\n\n\t\tif len(content.Bytes()) != 0 {\n\t\t\tbuf.WriteByte('(')\n\t\t\tbuf.Write(content.Bytes())\n\t\t\tbuf.WriteByte(')')\n\t\t}\n\n\tdefault: // float, complex, bool, chan, func, interface\n\t\treturn fmt.Errorf(\"unsupported type: %s\", v.Type())\n\t}\n\treturn nil\n}", "func (a *ArrayInt) String() string {\n\tx := a.a\n\tformattedInts := make([]string, len(x))\n\tfor i, v := range x {\n\t\tformattedInts[i] = strconv.Itoa(v)\n\t}\n\treturn strings.Join(formattedInts, \",\")\n}", "func (t *tag) render() string {\n tagType := t.GetType()\n tagFormat := tagsFormat[tagType]\n\n switch t.GetType() {\n case TYPE_OPEN:\n return fmt.Sprintf(tagFormat, t.GetName(), getAttrsToString(t))\n case TYPE_CLOSE:\n return fmt.Sprintf(tagFormat, t.GetName())\n case TYPE_OPEN_CLOSE:\n return fmt.Sprintf(tagFormat, t.GetName(), getAttrsToString(t), t.GetVal(), t.GetName())\n case TYPE_SELF_CLOSED_STRICT:\n if t.GetVal() != \"\" {\n t.SetAttr(\"value\", t.GetVal())\n }\n return fmt.Sprintf(tagFormat, t.GetName(), getAttrsToString(t))\n default:\n return t.GetName()\n }\n}", "func ex1() {\n\tx := [5]int{1, 2, 4, 8, 16}\n\tfor i, v := range x {\n\t\tfmt.Println(i, v)\n\t}\n\tfmt.Printf(\"%T\\n\", x)\n\n}", "func (self *Tween) GenerateData() []interface{}{\n\tarray00 := self.Object.Call(\"generateData\")\n\tlength00 := array00.Length()\n\tout00 := make([]interface{}, length00, length00)\n\tfor i00 := 0; i00 < length00; i00++ {\n\t\tout00[i00] = array00.Index(i00)\n\t}\n\treturn out00\n}", "func (h Hand) Render() string {\n\tbuffer := bytes.Buffer{}\n\tlast := len(h.Cards) - 1\n\tfor i, card := range h.Cards {\n\t\tbuffer.WriteString(card.Render())\n\t\tif i != last {\n\t\t\tbuffer.WriteString(\", \")\n\t\t}\n\t}\n\tbuffer.WriteString(fmt.Sprintf(\n\t\t\" (%s)\", scoresRenderer{h.Scores()}.Render(),\n\t))\n\treturn strings.Trim(buffer.String(), \" \")\n}", "func RenderList(w http.ResponseWriter, r *http.Request, l []Renderer) error {\n\tfor _, v := range l {\n\t\tif err := renderer(w, r, v); err != nil {\n\t\t\treturn err\n\t\t}\n\t}\n\tRespond(w, r, l)\n\treturn nil\n}", "func (me TStrokeDashArrayValueType) String() string { return xsdt.String(me).String() }", "func main() {\n\ts := []int{5, 3, 2, 6, 1, 6, 7, 10, 49, 100}\n\tfor i, v := range s {\n\t\tfmt.Println(i, v)\n\t}\n\tfmt.Printf(\"%T\\n\", s)\n}", "func (a *Array) Format() error {\n\t// todo\n\treturn nil\n}", "func (va ValueArray) String() string {\n\treturn fmt.Sprintf(\"%v\", []Value(va))\n}", "func (ctx *RecordContext) Render(v interface{}) error {\n\tctx.Renders = append(ctx.Renders, v)\n\treturn ctx.Context.Render(v)\n}", "func PrintDataSlice(data interface{}) {\n\td := reflect.ValueOf(data)\n\n\tfor i := 0; i < d.Len(); i++ {\n\t\tdataItem := d.Index(i)\n\t\ttypeOfT := dataItem.Type()\n\n\t\tfor j := 0; j < dataItem.NumField(); j++ {\n\t\t\tf := dataItem.Field(j)\n\t\t\tfmt.Printf(\"%s: %v\\n\", typeOfT.Field(j).Name, f.Interface())\n\t\t}\n\t\tfmt.Printf(\"\\n\")\n\t}\n}", "func (s *Slice) Format(f fmt.State, c rune) {\n\tswitch c {\n\tcase 'z': // Private format specifier, supports Entity.Signature\n\t\tfmt.Fprintf(f, \"[]%z\", s.ValueType)\n\tcase 'r': // Private format specifier, supports Type.Representation\n\t\tfmt.Fprintf(f, \"[]%r\", s.ValueType)\n\tdefault:\n\t\tif s.Alias != \"\" {\n\t\t\tfmt.Fprint(f, s.Alias)\n\t\t} else {\n\t\t\tfmt.Fprintf(f, \"[]%v\", s.ValueType)\n\t\t}\n\t}\n}", "func DrawElements(mode Enum, count int, ty Enum, offset int) {\n\tgl.DrawElements(uint32(mode), int32(count), uint32(ty), gl.PtrOffset(offset))\n}", "func (s Style) Render(raw string) string {\n\tt := NewAnstring(raw)\n\tfor i := len(s) - 1; i >= 0; i-- {\n\t\tt.meld(s[i])\n\t}\n\treturn string(t)\n}", "func (l *LogItem) Render(c int, showTime bool) []byte {\n\tbb := make([]byte, 0, 200)\n\tif showTime {\n\t\tt := l.Timestamp\n\t\tfor i := len(t); i < 30; i++ {\n\t\t\tt += \" \"\n\t\t}\n\t\tbb = append(bb, color.ANSIColorize(t, 106)...)\n\t\tbb = append(bb, ' ')\n\t}\n\n\tif l.Pod != \"\" {\n\t\tbb = append(bb, color.ANSIColorize(l.Pod, c)...)\n\t\tbb = append(bb, ':')\n\t}\n\tif !l.SingleContainer && l.Container != \"\" {\n\t\tbb = append(bb, color.ANSIColorize(l.Container, c)...)\n\t\tbb = append(bb, ' ')\n\t}\n\n\treturn append(bb, escPattern.ReplaceAll(l.Bytes, matcher)...)\n}", "func (isf intSliceFunctorImpl) String() string {\n\treturn fmt.Sprintf(\"%#v\", isf.ints)\n}", "func renderInteger(f float64) string {\n\tif f > math.Nextafter(float64(math.MaxInt64), 0) {\n\t\treturn fmt.Sprintf(\"%d\", int64(math.MaxInt64))\n\t}\n\tif f < math.Nextafter(float64(math.MinInt64), 0) {\n\t\treturn fmt.Sprintf(\"%d\", int64(math.MinInt64))\n\t}\n\treturn fmt.Sprintf(\"%d\", int64(f))\n}", "func (l *Label) data() []byte {\n Assert(nilLabel, l != nil)\n \n bytes, _ := util.Uint64ToBytes(l.value)\n refs, _ := util.Uint64ToBytes(l.refs)\n left, _ := util.Uint16ToBytes(l.l)\n right, _ := util.Uint16ToBytes(l.r)\n \n bytes = append(bytes, append(refs, append(left, append(right, l.h)...)...)...) // TODO ??\n return bytes\n \n}", "func (a PixelSubArray) Print() {\n\tfor y := len(a.bytes) - 1; y >= 0; y-- {\n\t\tfor x := 0; x < len(a.bytes[0]); x++ {\n\t\t\tfmt.Printf(\"%b%b%b%b%b%b%b%b\",\n\t\t\t\t(a.bytes[y][x])&1,\n\t\t\t\t(a.bytes[y][x]>>1)&1,\n\t\t\t\t(a.bytes[y][x]>>2)&1,\n\t\t\t\t(a.bytes[y][x]>>3)&1,\n\t\t\t\t(a.bytes[y][x]>>4)&1,\n\t\t\t\t(a.bytes[y][x]>>5)&1,\n\t\t\t\t(a.bytes[y][x]>>6)&1,\n\t\t\t\t(a.bytes[y][x]>>7)&1)\n\t\t}\n\n\t\tfmt.Printf(\"\\n\")\n\t}\n}", "func serialize(data interface{}) interface{} {\n\tvar buffer bytes.Buffer\n\tswitch reflect.TypeOf(data).Kind() {\n\tcase reflect.Slice:\n\t\ts := reflect.ValueOf(data)\n\t\tfor i := 0; i < s.Len(); i++ {\n\t\t\tserial := serialize(s.Index(i).Interface())\n\t\t\tif reflect.TypeOf(serial).Kind() == reflect.Float64 {\n\t\t\t\tserial = strconv.Itoa(int(serial.(float64)))\n\t\t\t}\n\t\t\tbuffer.WriteString(strconv.Itoa(i))\n\t\t\tbuffer.WriteString(serial.(string))\n\t\t}\n\t\treturn buffer.String()\n\tcase reflect.Map:\n\t\ts := reflect.ValueOf(data)\n\t\tkeys := s.MapKeys()\n\t\t//ksort\n\t\tvar sortedKeys []string\n\t\tfor _, key := range keys {\n\t\t\tsortedKeys = append(sortedKeys, key.Interface().(string))\n\t\t}\n\t\tsort.Strings(sortedKeys)\n\t\tfor _, key := range sortedKeys {\n\t\t\tserial := serialize(s.MapIndex(reflect.ValueOf(key)).Interface())\n\t\t\tif reflect.TypeOf(serial).Kind() == reflect.Float64 {\n\t\t\t\tserial = strconv.Itoa(int(serial.(float64)))\n\t\t\t}\n\t\t\tbuffer.WriteString(key)\n\t\t\tbuffer.WriteString(serial.(string))\n\t\t}\n\t\treturn buffer.String()\n\t}\n\n\treturn data\n}", "func (r renderer) Table(out *bytes.Buffer, header []byte, body []byte, columnData []int) {}", "func (self *Graphics) Data() interface{}{\n return self.Object.Get(\"data\")\n}", "func (level *Level) Render() string {\n\tresult := \"\"\n\n\tfor y := 0; y < level.size.Width; y++ {\n\t\tfor x := 0; x < level.size.Width; x++ {\n\t\t\tif level.snake.CheckHitbox(Position{x, y}) {\n\t\t\t\tresult += \"\\033[42m \\033[0m\"\n\t\t\t} else if level.apple.position.Equals(x, y) {\n\t\t\t\tresult += \"\\033[41m \\033[0m\"\n\t\t\t} else {\n\t\t\t\tresult += \"\\033[97m \\033[0m\"\n\t\t\t}\n\t\t}\n\n\t\tif y < level.size.Height-1 {\n\t\t\tresult += \"\\n\"\n\t\t}\n\t}\n\n\treturn result\n}", "func printTable(data []string, color bool) {\n\tvar listType string\n\n\ttable := tablewriter.NewWriter(os.Stdout)\n\n\tswitch color {\n\tcase true:\n\t\tlistType = \"White\"\n\tcase false:\n\t\tlistType = \"Black\"\n\t}\n\n\ttable.SetHeader([]string{\"#\", \"B/W\", \"CIDR\"})\n\n\tfor i, v := range data {\n\t\tl := make([]string, 0)\n\t\tl = append(l, strconv.Itoa(i+offset))\n\t\tl = append(l, listType)\n\t\tl = append(l, v)\n\t\ttable.Append(l)\n\t}\n\n\ttable.Render()\n}", "func Render(s api.Session, renderAs RenderName, value dgo.Value, out io.Writer) {\n\t// Convert value to rich data format without references\n\tdedupStream := func(value dgo.Value, consumer streamer.Consumer) {\n\t\topts := streamer.DefaultOptions()\n\t\topts.DedupLevel = streamer.NoDedup\n\t\tser := streamer.New(s.AliasMap(), opts)\n\t\tser.Stream(value, consumer)\n\t}\n\n\tswitch renderAs {\n\tcase JSON:\n\t\tif value.Equals(vf.Nil) {\n\t\t\tutil.WriteString(out, \"null\\n\")\n\t\t} else {\n\t\t\tdedupStream(value, streamer.JSON(out))\n\t\t\tutil.WriteByte(out, '\\n')\n\t\t}\n\n\tcase YAML:\n\t\tif value.Equals(vf.Nil) {\n\t\t\tutil.WriteString(out, \"\\n\")\n\t\t} else {\n\t\t\tdc := streamer.DataCollector()\n\t\t\tdedupStream(value, dc)\n\t\t\tbs, err := yaml.Marshal(dc.Value())\n\t\t\tif err != nil {\n\t\t\t\tpanic(err)\n\t\t\t}\n\t\t\tutil.WriteString(out, string(bs))\n\t\t}\n\tcase Binary:\n\t\tbi := vf.New(typ.Binary, value).(dgo.Binary)\n\t\t_, err := out.Write(bi.GoBytes())\n\t\tif err != nil {\n\t\t\tpanic(err)\n\t\t}\n\tcase Text:\n\t\tutil.Fprintln(out, value)\n\tdefault:\n\t\tpanic(fmt.Errorf(`unknown rendering '%s'`, renderAs))\n\t}\n}", "func (s *Ipset) Render(rType RenderType) string {\n\tvar result string\n\n\tswitch rType {\n\tcase RenderFlush:\n\t\tif len(s.Sets) == 0 {\n\t\t\treturn \"flush\\n\"\n\t\t}\n\tcase RenderDestroy:\n\t\tif len(s.Sets) == 0 {\n\t\t\treturn \"destroy\\n\"\n\t\t}\n\n\t// RenderSwap will fail when Sets < 2,\n\t// it's a duty of a caller to ensure\n\t// correctness.\n\tcase RenderSwap:\n\t\treturn fmt.Sprintf(\"swap %s %s\\n\", s.Sets[0].Name, s.Sets[1].Name)\n\n\t// RenderRename will fail when Sets < 2,\n\t// it's a duty of a caller to ensure\n\t// correctness.\n\tcase RenderRename:\n\t\treturn fmt.Sprintf(\"rename %s %s\\n\", s.Sets[0].Name, s.Sets[1].Name)\n\t}\n\n\tfor _, set := range s.Sets {\n\t\tresult += set.Render(rType)\n\t}\n\n\treturn result\n}", "func (b *Board) Render() {\n\tfmt.Println() // to breathe\n\tfmt.Println(\" | a | b | c | d | e | f | g | h |\")\n\tfmt.Println(\" - +-----+-----+-----+-----+-----+-----+-----+-----+\")\n\n\tfor i := 0; i < 8; i++ {\n\t\tfmt.Printf(\" %d |\", i)\n\t\tfor j := 0; j < 8; j++ {\n\t\t\tcell := b[i][j]\n\t\t\tfmt.Printf(\" %s |\", cell)\n\t\t}\n\t\tfmt.Println()\n\t}\n\n\tfmt.Println(\" - +-----+-----+-----+-----+-----+-----+-----+-----+\")\n\tfmt.Println() // breathe again\n}", "func (ctx *APIContext) Render(status int, title string, obj interface{}) {\n\tctx.JSON(status, map[string]interface{}{\n\t\t\"message\": title,\n\t\t\"status\": status,\n\t\t\"resource\": obj,\n\t})\n}", "func (val *uint16ArrayValue) String() string {\n\tvar buffer strings.Builder\n\tfor _, v := range *val {\n\t\tif buffer.Len() != 0 {\n\t\t\tbuffer.WriteString(\", \")\n\t\t}\n\t\tfmt.Fprintf(&buffer, \"%v\", v)\n\t}\n\treturn buffer.String()\n}", "func WriteASCII(w io.Writer, t []Triangle) error {\n\tvar err error\n\n\tprintf := func(format string, a ...interface{}) {\n\t\tif err != nil {\n\t\t\treturn\n\t\t}\n\t\t_, err = fmt.Fprintf(w, format, a...)\n\t}\n\tprintf(\"solid object\\n\")\n\tfor _, tt := range t {\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tprintf(\"facet normal %f %f %f\\n\", tt.N[0], tt.N[1], tt.N[2])\n\t\tprintf(\" outer loop\\n\")\n\t\tfor _, v := range tt.V {\n\t\t\tprintf(\" vertex %f %f %f\\n\", v[0], v[1], v[2])\n\t\t}\n\t\tprintf(\" endloop\\n\")\n\t\tprintf(\"endfacet\\n\")\n\t}\n\tprintf(\"endsolid object\\n\")\n\treturn nil\n}", "func (gl *WebGL) DrawElements(mode GLEnum, count int, valueType GLEnum, offset int) {\n\tgl.context.Call(\"drawElements\", mode, count, valueType, offset)\n}", "func Render(typ Type, input any, urlPrefix string, metas map[string]string) []byte {\n\tvar rawBytes []byte\n\tswitch v := input.(type) {\n\tcase []byte:\n\t\trawBytes = v\n\tcase string:\n\t\trawBytes = []byte(v)\n\tdefault:\n\t\tpanic(fmt.Sprintf(\"unrecognized input content type: %T\", input))\n\t}\n\n\turlPrefix = strings.TrimRight(strings.ReplaceAll(urlPrefix, \" \", \"%20\"), \"/\")\n\tvar rawHTML []byte\n\tswitch typ {\n\tcase TypeMarkdown:\n\t\trawHTML = RawMarkdown(rawBytes, urlPrefix)\n\tcase TypeOrgMode:\n\t\trawHTML = RawOrgMode(rawBytes, urlPrefix)\n\tdefault:\n\t\treturn rawBytes // Do nothing if syntax type is not recognized\n\t}\n\n\trawHTML = postProcessHTML(rawHTML, urlPrefix, metas)\n\treturn SanitizeBytes(rawHTML)\n}", "func WriteArray(lst []interface{}, buf *goetty.ByteBuf) {\r\n\tbuf.WriteByte('*')\r\n\tif len(lst) == 0 {\r\n\t\tbuf.Write(NullArray)\r\n\t\tbuf.Write(Delims)\r\n\t} else {\r\n\t\tbuf.Write(goetty.StringToSlice(strconv.Itoa(len(lst))))\r\n\t\tbuf.Write(Delims)\r\n\r\n\t\tfor i := 0; i < len(lst); i++ {\r\n\t\t\tswitch v := lst[i].(type) {\r\n\t\t\tcase []interface{}:\r\n\t\t\t\tWriteArray(v, buf)\r\n\t\t\tcase [][]byte:\r\n\t\t\t\tWriteSliceArray(v, buf)\r\n\t\t\tcase []byte:\r\n\t\t\t\tWriteBulk(v, buf)\r\n\t\t\tcase nil:\r\n\t\t\t\tWriteBulk(nil, buf)\r\n\t\t\tcase int64:\r\n\t\t\t\tWriteInteger(v, buf)\r\n\t\t\tcase string:\r\n\t\t\t\tWriteStatus(goetty.StringToSlice(v), buf)\r\n\t\t\tcase error:\r\n\t\t\t\tWriteError(goetty.StringToSlice(v.Error()), buf)\r\n\t\t\tdefault:\r\n\t\t\t\tpanic(fmt.Sprintf(\"invalid array type %T %v\", lst[i], v))\r\n\t\t\t}\r\n\t\t}\r\n\t}\r\n}", "func (d *Data) Render() error {\n\n\tvar err error\n\n\t// Read the CA certificate:\n\tif err = d.caCert(); err != nil {\n\t\treturn err\n\t}\n\n\t// Forge the Zookeeper URL:\n\td.forgeZookeeperURL()\n\n\t// REX-Ray configuration snippet:\n\td.rexraySnippet()\n\n\t// Role-based parsing:\n\tt := template.New(\"udata\")\n\n\tswitch d.Role {\n\tcase \"master\":\n\t\tt, err = t.Parse(templMaster)\n\tcase \"node\":\n\t\tt, err = t.Parse(templNode)\n\tcase \"edge\":\n\t\tt, err = t.Parse(templEdge)\n\t}\n\n\tif err != nil {\n\t\tlog.WithField(\"cmd\", \"udata\").Error(err)\n\t\treturn err\n\t}\n\n\t// Apply parsed template to data object:\n\tif d.GzipUdata {\n\t\tlog.WithFields(log.Fields{\"cmd\": \"udata\", \"id\": d.Role + \"-\" + d.HostID}).\n\t\t\tInfo(\"- Rendering gzipped cloud-config template\")\n\t\tw := gzip.NewWriter(os.Stdout)\n\t\tdefer w.Close()\n\t\tif err = t.Execute(w, d); err != nil {\n\t\t\tlog.WithField(\"cmd\", \"udata\").Error(err)\n\t\t\treturn err\n\t\t}\n\t} else {\n\t\tlog.WithField(\"cmd\", \"udata\").Info(\"- Rendering plain text cloud-config template\")\n\t\tif err = t.Execute(os.Stdout, d); err != nil {\n\t\t\tlog.WithField(\"cmd\", \"udata\").Error(err)\n\t\t\treturn err\n\t\t}\n\t}\n\n\t// Return on success:\n\treturn nil\n}", "func (p *Pprint) pprint(data interface{}) {\n\t// temp := reflect.TypeOf(data).Kind()\n\t// p.test[\"array\"] = reflect.Map\n\t// fmt.Println(p.test)\n\t// if reflect.Array == temp {\n\t// \tfmt.Println(\"scussu\")\n\t// }\n\t// p.test[temp.String()] = 0\n\tp.Typemode = reflect.TypeOf(data).Kind()\n\tif p.Typemode == reflect.Map {\n\t\tp.PrintMaps(data)\n\t} else if p.Typemode == reflect.Slice {\n\t\tp.PrintArrays(data)\n\t} else if p.Typemode == reflect.Array {\n\t\tp.PrintArrays(data)\n\t} else {\n\t\tfmt.Println(data)\n\t}\n}", "func Render(files [][]byte, maxIt uint, debug bool) (\n\t[]byte, error,\n) {\n\tinfl, debugParse, err := parseFiles(files)\n\tif err != nil {\n\t\tif debug {\n\t\t\twriteDebug(\"parsing\", debugParse)\n\t\t}\n\t\treturn []byte{}, err\n\t}\n\tres, debugRender, err := renderTmpl(infl, maxIt)\n\tif err != nil {\n\t\tif debug {\n\t\t\twriteDebug(\"render\", debugRender)\n\t\t}\n\t\treturn []byte{}, err\n\t}\n\treturn res, nil\n}", "func (Empty) Render(width, height int) *term.Buffer {\n\treturn term.NewBufferBuilder(width).Buffer()\n}", "func DrawElements(mode uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n\tsyscall.Syscall6(gpDrawElements, 4, uintptr(mode), uintptr(count), uintptr(xtype), uintptr(indices), 0, 0)\n}", "func GenerateShapes() {\r\n\t// Square\r\n\tShapes[0].vertices = []gl.GLfloat{-1, -1, 1, -1, -1, 1, 1, 1}\r\n\tShapes[0].elements = []gl.GLushort{0, 1, 2, 2, 3, 1}\r\n\r\n\t// ___|\r\n\tShapes[1].vertices = []gl.GLfloat{-2, 0, -2, -1, 2, -1, 2, 0, 2, 1, 1, 1, 1, 0}\r\n\tShapes[1].elements = []gl.GLushort{0, 1, 2, 2, 3, 0, 3, 4, 5, 5, 6, 3}\r\n\r\n\t// _|_\r\n\tShapes[2].vertices = []gl.GLfloat{-1.5, 0, -0.5, 0, -0.5, 1, 0.5, 1, 0.5, 0, 1.5, 0, 1.5, -1, -1.5, -1}\r\n\tShapes[2].elements = []gl.GLushort{1, 2, 3, 3, 4, 1, 0, 7, 6, 6, 0, 5}\r\n\r\n\t// Snake\r\n\tShapes[3].vertices = []gl.GLfloat{-1.5, -1, -1.5, 0, -0.5, 0, -0.5, 1, 1.5, 1, 1.5, 0, 0.5, 0, 0.5, -1}\r\n\tShapes[3].elements = []gl.GLushort{0, 1, 6, 6, 7, 0, 2, 3, 4, 4, 5, 2}\r\n\r\n\t// Now fill out the rest automatically.\r\n\t// FIXME why doesn't using _, shape in this loop work ?\r\n\tfor i := range Shapes {\r\n\t\tShapes[i].vao = gl.GenVertexArray()\r\n\t\tShapes[i].vao.Bind()\r\n\t\tShapes[i].vbo = gl.GenBuffer()\r\n\t\tShapes[i].vbo.Bind(gl.ARRAY_BUFFER)\r\n\t\tgl.BufferData(gl.ARRAY_BUFFER, len(Shapes[i].vertices)*4, Shapes[i].vertices, gl.STATIC_DRAW)\r\n\t\tShapes[i].elementBuffer = gl.GenBuffer()\r\n\t\tShapes[i].elementBuffer.Bind(gl.ELEMENT_ARRAY_BUFFER)\r\n\t\tgl.BufferData(gl.ELEMENT_ARRAY_BUFFER, len(Shapes[i].elements)*2, Shapes[i].elements, gl.STATIC_DRAW)\r\n\t\tShapes[i].numElements = len(Shapes[i].elements)\r\n\r\n\t\tvertexAttribArray := shaderProgram.GetAttribLocation(\"position\")\r\n\t\tvertexAttribArray.AttribPointer(2, gl.FLOAT, false, 0, uintptr(0))\r\n\t\tvertexAttribArray.EnableArray()\r\n\t}\r\n}", "func Interpret(data []byte, offset int) []byte {\n\tb:=make([]byte, len(data) * 2)\n\n\tfor i:=0; i<len(data); i++ {\n\t\tb[offset + i * 2] = hex_ascii[ (data[i] & 0XF0) >> 4]\n\t\tb[offset + i * 2 + 1] = hex_ascii[data[i] & 0x0F]\n\t}\n\treturn b\n}", "func DrawElements(mode uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n C.glowDrawElements(gpDrawElements, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices)\n}", "func (tpl *Template) RenderBytes(ctx ...interface{}) ([]byte, error) {\n\tvar buf bytes.Buffer\n\terr := tpl.Run(&buf, ctx...)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\treturn buf.Bytes(), nil\n}", "func TestRender(t *testing.T) {\n\ttestCases := []struct {\n\t\tname string\n\t\tp P\n\t\twantList []string\n\t\twantCode int\n\t}{\n\t\t{\n\t\t\t\"server error\",\n\t\t\tServerError,\n\t\t\t[]string{\"500\"},\n\t\t\t500,\n\t\t}, {\n\t\t\t\"renders the type correctly\",\n\t\t\tP{Type: \"foo\", Status: 500},\n\t\t\t[]string{\"foo\"},\n\t\t\t500,\n\t\t}, {\n\t\t\t\"renders the status correctly\",\n\t\t\tP{Status: 201},\n\t\t\t[]string{\"201\"},\n\t\t\t201,\n\t\t}, {\n\t\t\t\"renders the extras correctly\",\n\t\t\tP{Extras: map[string]interface{}{\"hello\": \"stellar\"}, Status: 500},\n\t\t\t[]string{\"hello\", \"stellar\"},\n\t\t\t500,\n\t\t},\n\t}\n\n\tfor _, kase := range testCases {\n\t\tt.Run(kase.name, func(t *testing.T) {\n\t\t\tw := testRender(context.Background(), kase.p)\n\t\t\tfor _, wantItem := range kase.wantList {\n\t\t\t\tassert.True(t, strings.Contains(w.Body.String(), wantItem), w.Body.String())\n\t\t\t\tassert.Equal(t, kase.wantCode, w.Code)\n\t\t\t}\n\t\t})\n\t}\n}", "func encodeUxArray(obj *UxArray) ([]byte, error) {\n\tn := encodeSizeUxArray(obj)\n\tbuf := make([]byte, n)\n\n\tif err := encodeUxArrayToBuffer(buf, obj); err != nil {\n\t\treturn nil, err\n\t}\n\n\treturn buf, nil\n}", "func (obj *Device) DrawIndexedPrimitiveUP(\n\ttyp PRIMITIVETYPE,\n\tminVertexIndex uint,\n\tnumVertices uint,\n\tprimitiveCount uint,\n\tindexData uintptr,\n\tindexDataFormat FORMAT,\n\tvertexStreamZeroData uintptr,\n\tvertexStreamZeroStride uint,\n) Error {\n\tret, _, _ := syscall.Syscall9(\n\t\tobj.vtbl.DrawIndexedPrimitiveUP,\n\t\t9,\n\t\tuintptr(unsafe.Pointer(obj)),\n\t\tuintptr(typ),\n\t\tuintptr(minVertexIndex),\n\t\tuintptr(numVertices),\n\t\tuintptr(primitiveCount),\n\t\tindexData,\n\t\tuintptr(indexDataFormat),\n\t\tvertexStreamZeroData,\n\t\tuintptr(vertexStreamZeroStride),\n\t)\n\treturn toErr(ret)\n}", "func (c *Plain) RenderIndexContent(content interface{}) (string, error) {\n\treturn content.(string), nil\n}", "func (r *ExcelReport) Render(ctx map[string]interface{}) {\n\tmergedCells, _ := r.f.GetMergeCells(r.sheetName)\n\n\tr.renderSingleAttribute(ctx)\n\n\t// Set nilai pada cell yang digabungkan (merge cell)\n\tfor _, mergedCell := range mergedCells {\n\t\taxis := strings.Split(mergedCell[0], \":\")[0]\n\t\tformula, _ := r.f.GetCellFormula(r.sheetName, axis)\n\t\tif formula != \"\" {\n\t\t\tr.f.SetCellFormula(r.sheetName, axis, formula)\n\t\t\tcontinue\n\t\t}\n\t\tcellValue := mergedCell[1]\n\n\t\tprop := getProp(cellValue)\n\t\tif prop != \"\" {\n\t\t\tif !isArray(ctx, prop) {\n\t\t\t\tcellValue, _ = renderContext(cellValue, ctx)\n\t\t\t}\n\t\t}\n\n\t\tsetCellValue(r.sheetName, axis, r.f, cellValue)\n\t}\n\n\tr.renderArrayAttribute(ctx)\n}", "func (t *Table) Render() string {\n\tfmt.Fprintln(t.w, \"-\")\n\tt.w.Flush()\n\n\treturn t.buf.String()\n}", "func Render(r *sdl.Renderer, w *World) {\n\twidth := float64(r.GetViewport().W)\n\theight := float64(r.GetViewport().H)\n\n\trenderedVertices := [][2]int{}\n\n\tfor _, obj := range w.Objects {\n\t\tfor _, vertex := range obj.Geometry.Vertices {\n\t\t\trenderCoordinates := AsRelativeToSystem(w.ActiveCamera.ObjSys, ToSystem(obj.ObjSys, vertex.Pos))\n\n\t\t\tZ := Clamp(renderCoordinates.Z, 0.0001, math.NaN())\n\t\t\tratio := w.ActiveCamera.FocalLength / math.Abs(Z)\n\t\t\trenderX := ratio * renderCoordinates.X\n\t\t\trenderY := ratio * renderCoordinates.Y\n\n\t\t\tnormX, normY := NormalizeScreen(\n\t\t\t\twidth,\n\t\t\t\theight,\n\t\t\t\trenderX,\n\t\t\t\trenderY,\n\t\t\t)\n\n\t\t\trasterX := int(math.Floor(normX*width) + width/2)\n\t\t\trasterY := int(math.Floor(normY*height) + height/2)\n\n\t\t\trenderedVertices = append(renderedVertices, [2]int{rasterX, rasterY})\n\n\t\t\tDrawCircle(r, rasterX, rasterY, 5)\n\t\t}\n\t\tfor _, edge := range obj.Geometry.Edges {\n\t\t\tif len(renderedVertices) > edge.From && len(renderedVertices) > edge.To {\n\t\t\t\tr.DrawLine(\n\t\t\t\t\tint32(renderedVertices[edge.From][0]),\n\t\t\t\t\tint32(renderedVertices[edge.From][1]),\n\t\t\t\t\tint32(renderedVertices[edge.To][0]),\n\t\t\t\t\tint32(renderedVertices[edge.To][1]),\n\t\t\t\t)\n\t\t\t}\n\t\t}\n\t}\n\n\tr.Present()\n}", "func (obj *Device) DrawPrimitive(\n\ttyp PRIMITIVETYPE,\n\tstartVertex uint,\n\tprimitiveCount uint,\n) Error {\n\tret, _, _ := syscall.Syscall6(\n\t\tobj.vtbl.DrawPrimitive,\n\t\t4,\n\t\tuintptr(unsafe.Pointer(obj)),\n\t\tuintptr(typ),\n\t\tuintptr(startVertex),\n\t\tuintptr(primitiveCount),\n\t\t0,\n\t\t0,\n\t)\n\treturn toErr(ret)\n}", "func renderTemplateBytes(name string, data interface{}) ([]byte, error) {\n\tvar buf bytes.Buffer\n\tif err := Tmpl.Render(&buf, name, data); err != nil {\n\t\treturn nil, err\n\t}\n\treturn buf.Bytes(), nil\n}", "func renderTemplateBytes(name string, data interface{}) ([]byte, error) {\n\tvar buf bytes.Buffer\n\tif err := Tmpl.Render(&buf, name, data); err != nil {\n\t\treturn nil, err\n\t}\n\treturn buf.Bytes(), nil\n}" ]
[ "0.56787425", "0.54101527", "0.5399384", "0.519561", "0.5053621", "0.5053621", "0.4920417", "0.48898092", "0.48869783", "0.4874677", "0.48738092", "0.4813202", "0.47689718", "0.47537965", "0.4749709", "0.47490627", "0.47416687", "0.47410572", "0.47369975", "0.4730121", "0.47264576", "0.47100666", "0.46990198", "0.46961746", "0.4696105", "0.46880925", "0.46767005", "0.46732444", "0.4672384", "0.46716732", "0.46579018", "0.46450433", "0.46363953", "0.46341535", "0.46307516", "0.46253136", "0.461411", "0.4614061", "0.4613324", "0.4578849", "0.45645848", "0.4560169", "0.45589033", "0.45529243", "0.45445886", "0.45256785", "0.45206797", "0.45191577", "0.45175895", "0.45136765", "0.45120773", "0.4511845", "0.45095196", "0.45020393", "0.44944736", "0.44915026", "0.44862324", "0.44781968", "0.44772694", "0.447416", "0.44738328", "0.44709054", "0.44687584", "0.44684634", "0.44682878", "0.4457824", "0.44531804", "0.44512594", "0.44473648", "0.4444646", "0.4436516", "0.4431991", "0.44247144", "0.44142383", "0.44101962", "0.440982", "0.44053942", "0.4403469", "0.43999562", "0.4399935", "0.43975523", "0.43952927", "0.4387458", "0.43738773", "0.4370974", "0.43695098", "0.43662947", "0.4362171", "0.43616948", "0.43552798", "0.43544373", "0.43510047", "0.43474784", "0.4340883", "0.43406615", "0.4336113", "0.43319076", "0.43293712", "0.43150315", "0.43130335", "0.43130335" ]
0.0
-1
render primitives from array data with a perelement offset
func DrawRangeElementsBaseVertex(mode uint32, start uint32, end uint32, count int32, xtype uint32, indices unsafe.Pointer, basevertex int32) { C.glowDrawRangeElementsBaseVertex(gpDrawRangeElementsBaseVertex, (C.GLenum)(mode), (C.GLuint)(start), (C.GLuint)(end), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLint)(basevertex)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func (native *OpenGL) DrawElementsOffset(mode uint32, count int32, elementType uint32, offset int) {\n\tgl.DrawElements(mode, count, elementType, gl.PtrOffset(offset))\n}", "func Interpret(data []byte, offset int) []byte {\n\tb:=make([]byte, len(data) * 2)\n\n\tfor i:=0; i<len(data); i++ {\n\t\tb[offset + i * 2] = hex_ascii[ (data[i] & 0XF0) >> 4]\n\t\tb[offset + i * 2 + 1] = hex_ascii[data[i] & 0x0F]\n\t}\n\treturn b\n}", "func (v Binary) Render(i, width int, baseStyle lipgloss.Style) string {\n\tw := dataWidth(width)\n\t_, err := v.Seek(int64(i*w), io.SeekStart)\n\tif err != nil {\n\t\treturn baseStyle.Blink(true).Render(err.Error())\n\t}\n\tif len(v.b) != w {\n\t\tv.b = make([]byte, w)\n\t}\n\tn, err := v.Read(v.b)\n\tif err != nil && !errors.Is(err, io.EOF) {\n\t\treturn baseStyle.Blink(true).Render(err.Error())\n\t}\n\ts := fmt.Sprintf(\"% X%s \", v.b[0:n], strings.Repeat(\" \", w-n))\n\tvar x strings.Builder\n\tfor i := 0; i < n; i++ {\n\t\tif unicode.IsPrint(rune(v.b[i])) {\n\t\t\tx.WriteRune(rune(v.b[i]))\n\t\t} else {\n\t\t\tx.WriteRune('.')\n\t\t}\n\t}\n\treturn baseStyle.Render(s + x.String())\n}", "func (obj *Device) DrawIndexedPrimitiveUP(\n\ttyp PRIMITIVETYPE,\n\tminVertexIndex uint,\n\tnumVertices uint,\n\tprimitiveCount uint,\n\tindexData uintptr,\n\tindexDataFormat FORMAT,\n\tvertexStreamZeroData uintptr,\n\tvertexStreamZeroStride uint,\n) Error {\n\tret, _, _ := syscall.Syscall9(\n\t\tobj.vtbl.DrawIndexedPrimitiveUP,\n\t\t9,\n\t\tuintptr(unsafe.Pointer(obj)),\n\t\tuintptr(typ),\n\t\tuintptr(minVertexIndex),\n\t\tuintptr(numVertices),\n\t\tuintptr(primitiveCount),\n\t\tindexData,\n\t\tuintptr(indexDataFormat),\n\t\tvertexStreamZeroData,\n\t\tuintptr(vertexStreamZeroStride),\n\t)\n\treturn toErr(ret)\n}", "func DrawRangeElements(mode uint32, start uint32, end uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n\tsyscall.Syscall6(gpDrawRangeElements, 6, uintptr(mode), uintptr(start), uintptr(end), uintptr(count), uintptr(xtype), uintptr(indices))\n}", "func DrawElements(mode uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n\tsyscall.Syscall6(gpDrawElements, 4, uintptr(mode), uintptr(count), uintptr(xtype), uintptr(indices), 0, 0)\n}", "func DrawRangeElements(mode uint32, start uint32, end uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n C.glowDrawRangeElements(gpDrawRangeElements, (C.GLenum)(mode), (C.GLuint)(start), (C.GLuint)(end), (C.GLsizei)(count), (C.GLenum)(xtype), indices)\n}", "func (obj *Device) DrawIndexedPrimitive(\n\ttyp PRIMITIVETYPE,\n\tbaseVertexIndex int,\n\tminIndex uint,\n\tnumVertices uint,\n\tstartIndex uint,\n\tprimitiveCount uint,\n) Error {\n\tret, _, _ := syscall.Syscall9(\n\t\tobj.vtbl.DrawIndexedPrimitive,\n\t\t7,\n\t\tuintptr(unsafe.Pointer(obj)),\n\t\tuintptr(typ),\n\t\tuintptr(baseVertexIndex),\n\t\tuintptr(minIndex),\n\t\tuintptr(numVertices),\n\t\tuintptr(startIndex),\n\t\tuintptr(primitiveCount),\n\t\t0,\n\t\t0,\n\t)\n\treturn toErr(ret)\n}", "func (native *OpenGL) DrawElements(mode uint32, count int32, elementType uint32, indices uintptr) {\n\tgl.DrawElements(mode, count, elementType, unsafe.Pointer(indices)) // nolint: govet,gas\n}", "func (a PixelSubArray) Print() {\n\tfor y := len(a.bytes) - 1; y >= 0; y-- {\n\t\tfor x := 0; x < len(a.bytes[0]); x++ {\n\t\t\tfmt.Printf(\"%b%b%b%b%b%b%b%b\",\n\t\t\t\t(a.bytes[y][x])&1,\n\t\t\t\t(a.bytes[y][x]>>1)&1,\n\t\t\t\t(a.bytes[y][x]>>2)&1,\n\t\t\t\t(a.bytes[y][x]>>3)&1,\n\t\t\t\t(a.bytes[y][x]>>4)&1,\n\t\t\t\t(a.bytes[y][x]>>5)&1,\n\t\t\t\t(a.bytes[y][x]>>6)&1,\n\t\t\t\t(a.bytes[y][x]>>7)&1)\n\t\t}\n\n\t\tfmt.Printf(\"\\n\")\n\t}\n}", "func DrawElements(mode uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n C.glowDrawElements(gpDrawElements, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices)\n}", "func (e *expression) printArray() string {\n\ta := \"\"\n\n\tfor i := 0; i < len(e.lenArray); i++ {\n\t\tvArray := string('i' + i)\n\t\ta += fmt.Sprintf(\"[%s]\", vArray)\n\t}\n\treturn a\n}", "func PrintDataSlice(data interface{}) {\n\td := reflect.ValueOf(data)\n\n\tfor i := 0; i < d.Len(); i++ {\n\t\tdataItem := d.Index(i)\n\t\ttypeOfT := dataItem.Type()\n\n\t\tfor j := 0; j < dataItem.NumField(); j++ {\n\t\t\tf := dataItem.Field(j)\n\t\t\tfmt.Printf(\"%s: %v\\n\", typeOfT.Field(j).Name, f.Interface())\n\t\t}\n\t\tfmt.Printf(\"\\n\")\n\t}\n}", "func (self *Tween) GenerateData() []interface{}{\n\tarray00 := self.Object.Call(\"generateData\")\n\tlength00 := array00.Length()\n\tout00 := make([]interface{}, length00, length00)\n\tfor i00 := 0; i00 < length00; i00++ {\n\t\tout00[i00] = array00.Index(i00)\n\t}\n\treturn out00\n}", "func ArrayElement(i int32) {\n C.glowArrayElement(gpArrayElement, (C.GLint)(i))\n}", "func DrawElements(mode Enum, count int, ty Enum, offset int) {\n\tgl.DrawElements(uint32(mode), int32(count), uint32(ty), gl.PtrOffset(offset))\n}", "func render(fset *token.FileSet, x interface{}) string {\n\tvar buf bytes.Buffer\n\tif err := printer.Fprint(&buf, fset, x); err != nil {\n\t\tpanic(err)\n\t}\n\treturn buf.String()\n}", "func render(fset *token.FileSet, x interface{}) string {\n\tvar buf bytes.Buffer\n\tif err := printer.Fprint(&buf, fset, x); err != nil {\n\t\tpanic(err)\n\t}\n\treturn buf.String()\n}", "func (r *Renderer) Render() {\n\tsx, sz, sy := r.c.Bounds()\n\tsxf := float64(sx - 1)\n\tsyf := float64(sy - 1)\n\tszf := float64(sz - 1)\n\tfor z := 0; z < sz; z++ {\n\t\tfor y := 0; y < sy; y++ {\n\t\t\tfor x := 0; x < sx; x++ {\n\t\t\t\tvar lr, lg, lb, _ uint32\n\t\t\t\tn := uint32(0)\n\t\t\t\tfor _, o := range r.objects {\n\t\t\t\t\tr, g, b, _ := o.At(float64(x)/sxf, float64(y)/syf, float64(z)/szf).RGBA()\n\t\t\t\t\tlr += r >> 8\n\t\t\t\t\tlg += g >> 8\n\t\t\t\t\tlb += b >> 8\n\t\t\t\t\tn++\n\t\t\t\t}\n\t\t\t\tr.c.Set(x, y, z, color.RGBA{uint8(lr/n), uint8(lg/n), uint8(lb/n), 255})\n\t\t\t}\n\t\t}\n\t}\n\tr.c.Render()\n}", "func main() {\n\t//composite literal - create different values of a type\n\t// x := type{values}\n\t//group together values OF THE SAME TYPE\n\tx := []int{4, 5, 7, 8, 42}\n\n\tfmt.Println(x)\n\tfmt.Println(x[0]) //query by index position\n\tfmt.Println(x[1])\n\tfmt.Println(x[2])\n\tfmt.Println(x[3])\n\tfmt.Println(x[4])\n\tfmt.Println(cap(x))\n\n\t//for index and value in the range of x print\n\tfor i, v := range x {\n\t\tfmt.Println(i, v)\n\t}\n}", "func (e *rawData) Render(w io.Writer) (int, error) { return w.Write([]byte(e.content)) }", "func DrawOrder(value int) *SimpleElement { return newSEInt(\"drawOrder\", value) }", "func renderResults(vals []interface{}) Data {\n\tvar nilcount int\n\tvar obj interface{}\n\tfor _, val := range vals {\n\t\tswitch val.(type) {\n\t\tcase image.Image, Data:\n\t\t\tobj = val\n\t\tcase nil:\n\t\t\tnilcount++\n\t\t}\n\t}\n\tif obj != nil && nilcount == len(vals)-1 {\n\t\tswitch val := obj.(type) {\n\t\tcase image.Image:\n\t\t\tdata, err := image0(val)\n\t\t\tif err == nil {\n\t\t\t\treturn data\n\t\t\t}\n\t\tcase Data:\n\t\t\treturn val\n\t\t}\n\t}\n\tif nilcount == len(vals) {\n\t\t// if all values are nil, return empty Data\n\t\treturn Data{}\n\t}\n\treturn MakeData(\"text/plain\", fmt.Sprint(vals...))\n}", "func (f genHelperDecoder) DecReadArrayElem() { f.d.arrayElem() }", "func plotdata(deck *generate.Deck, left, right, top, bottom float64, x []float64, y []float64, size float64, color string) {\n\tif len(x) != len(y) {\n\t\treturn\n\t}\n\tminx, maxx := extrema(x)\n\tminy, maxy := extrema(y)\n\n\tix := left\n\tiy := bottom\n\tfor i := 0; i < len(x); i++ {\n\t\txp := vmap(x[i], minx, maxx, left, right)\n\t\typ := vmap(y[i], miny, maxy, bottom, top)\n\t\tdeck.Circle(xp, yp, size, color)\n\t\tdeck.Line(ix, iy, xp, yp, 0.2, color)\n\t\tix = xp\n\t\tiy = yp\n\t}\n}", "func (l *Label) data() []byte {\n Assert(nilLabel, l != nil)\n \n bytes, _ := util.Uint64ToBytes(l.value)\n refs, _ := util.Uint64ToBytes(l.refs)\n left, _ := util.Uint16ToBytes(l.l)\n right, _ := util.Uint16ToBytes(l.r)\n \n bytes = append(bytes, append(refs, append(left, append(right, l.h)...)...)...) // TODO ??\n return bytes\n \n}", "func (sr scoresRenderer) Render() string {\n\tbuffer := bytes.Buffer{}\n\tlast := len(sr.scores) - 1\n\tfor i, score := range sr.scores {\n\t\tbuffer.WriteString(fmt.Sprintf(\"%d\", score))\n\t\tif i != last {\n\t\t\tbuffer.WriteString(\" / \")\n\t\t}\n\t}\n\treturn buffer.String()\n}", "func DrawElementsIndirect(mode uint32, xtype uint32, indirect unsafe.Pointer) {\n\tsyscall.Syscall(gpDrawElementsIndirect, 3, uintptr(mode), uintptr(xtype), uintptr(indirect))\n}", "func (debugging *debuggingOpenGL) DrawElements(mode uint32, count int32, elementType uint32, indices uintptr) {\n\tdebugging.recordEntry(\"DrawElements\", mode, count, elementType, indices)\n\tdebugging.gl.DrawElements(mode, count, elementType, indices)\n\tdebugging.recordExit(\"DrawElements\")\n}", "func ArrayElement(i int32) {\n\tC.glowArrayElement(gpArrayElement, (C.GLint)(i))\n}", "func ArrayElement(i int32) {\n\tsyscall.Syscall(gpArrayElement, 1, uintptr(i), 0, 0)\n}", "func DrawRangeElementsBaseVertex(mode uint32, start uint32, end uint32, count int32, xtype uint32, indices unsafe.Pointer, basevertex int32) {\n\tsyscall.Syscall9(gpDrawRangeElementsBaseVertex, 7, uintptr(mode), uintptr(start), uintptr(end), uintptr(count), uintptr(xtype), uintptr(indices), uintptr(basevertex), 0, 0)\n}", "func PlotPoint(x, y gb.UINT8) {}", "func DrawRangeElements(mode uint32, start uint32, end uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n\tC.glowDrawRangeElements(gpDrawRangeElements, (C.GLenum)(mode), (C.GLuint)(start), (C.GLuint)(end), (C.GLsizei)(count), (C.GLenum)(xtype), indices)\n}", "func DrawRangeElements(mode uint32, start uint32, end uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n\tC.glowDrawRangeElements(gpDrawRangeElements, (C.GLenum)(mode), (C.GLuint)(start), (C.GLuint)(end), (C.GLsizei)(count), (C.GLenum)(xtype), indices)\n}", "func (obj *Device) DrawIndexedPrimitiveUPuint32(\n\tprimitiveType PRIMITIVETYPE,\n\tminVertexIndex uint,\n\tnumVertices uint,\n\tprimitiveCount uint,\n\tindexData []uint32,\n\tvertexStreamZeroData uintptr,\n\tvertexStreamZeroStride uint,\n) Error {\n\treturn obj.DrawIndexedPrimitiveUP(\n\t\tprimitiveType,\n\t\tminVertexIndex,\n\t\tnumVertices,\n\t\tprimitiveCount,\n\t\tuintptr(unsafe.Pointer(&indexData[0])),\n\t\tFMT_INDEX32,\n\t\tvertexStreamZeroData,\n\t\tvertexStreamZeroStride,\n\t)\n}", "func (obj *Device) DrawIndexedPrimitiveUPuint16(\n\tprimitiveType PRIMITIVETYPE,\n\tminVertexIndex uint,\n\tnumVertices uint,\n\tprimitiveCount uint,\n\tindexData []uint16,\n\tvertexStreamZeroData uintptr,\n\tvertexStreamZeroStride uint,\n) (\n\terr Error,\n) {\n\treturn obj.DrawIndexedPrimitiveUP(\n\t\tprimitiveType,\n\t\tminVertexIndex,\n\t\tnumVertices,\n\t\tprimitiveCount,\n\t\tuintptr(unsafe.Pointer(&indexData[0])),\n\t\tFMT_INDEX16,\n\t\tvertexStreamZeroData,\n\t\tvertexStreamZeroStride,\n\t)\n}", "func printColored(boundaries []colored_data, data []byte) []string {\n\tgrouping := 2\n\tper_line := 16\n\t// 16 bytes per line, grouped by 2 bytes\n\tnlines := len(data) / 16\n\tif len(data) % 16 > 0 {\n\t\tnlines++\n\t}\n\t\n\tout := make([]string, nlines)\n\n\tkolo := \"\\x1B[0m\"\n\t\n\tfor line := 0; line < nlines; line++ {\n\t\ts := \"\\t0x\"\n\t\txy := make([]byte, 2)\n\t\tline_offset := line * per_line\n\t\txy[0] = byte(line_offset >> 8)\n\t\txy[1] = byte(line_offset & 0xff)\n\t\ts = s + hex.EncodeToString(xy) + \":\\t\" + kolo\n\n\n\t\tline_length := per_line\n\t\tif line == nlines - 1 && len(data) % 16 > 0 {\n\t\t\tline_length = len(data) % 16\n\t\t}\n\n\t\tfor b := 0; b < line_length; b++ {\n\t\t\ttotal_offset := line * per_line + b\n\n\t\t\t// inserting coulourings\n\t\t\tfor x := 0; x < len(boundaries); x++ {\n\t\t\t\t//fmt.Println(\"!\")\n\t\t\t\tif(boundaries[x].offset == uint16(total_offset)) {\n\t\t\t\t\ts = s + boundaries[x].color\n\t\t\t\t\tkolo = boundaries[x].color\n\t\t\t\t}\n\t\t\t}\n\t\n\t\t\t// add byte from total_offset\n\t\t\txxx := make([]byte, 1)\n\t\t\txxx[0] = data[total_offset]\n\t\t\ts = s + hex.EncodeToString(xxx)\n\t\t\t\n\t\t\t// if b > 0 && b % grouping == 0, insert space\n\t\t\t\n\t\t\tif b > 0 && (b-1) % grouping == 0 {\n\t\t\t\ts = s + \" \"\n\t\t\t}\n\t\t\t\n\t\t}\n\t\t\n\t\tout[line] = s + COLOR_NORMAL\n\t}\n\t\n\treturn out\n}", "func (a *Array) Print() {\n\tvar format string\n\tfor i := uint(0); i < a.Len(); i++ {\n\t\tformat += fmt.Sprintf(\"|%+v\", a.data[i])\n\t}\n\tfmt.Println(format)\n}", "func (self *Tween) GenerateDataI(args ...interface{}) []interface{}{\n\tarray00 := self.Object.Call(\"generateData\", args)\n\tlength00 := array00.Length()\n\tout00 := make([]interface{}, length00, length00)\n\tfor i00 := 0; i00 < length00; i00++ {\n\t\tout00[i00] = array00.Index(i00)\n\t}\n\treturn out00\n}", "func (v *View) ReadAt(data []byte, off int64) (int, error) { return v.data.ReadAt(data, off) }", "func NewPageBuffer(aSlice interface{}, desiredPageNo int) *PageBuffer {\n return newPageBuffer(\n sliceValue(aSlice, false),\n desiredPageNo,\n valueHandler{})\n}", "func (a *Array) Literal() {}", "func PWprint(L *lua.LState) int {\n\ttext := L.ToString(1)\n\tx := L.ToInt(2)\n\ty := L.ToInt(3)\n\tcolor := L.ToInt(4)\n\n\tc := palette[color]\n\txx := x\n\tsx := x\n\tyy := y\n\n\tfor _, ch := range text {\n\t\tchar := font[string(ch)]\n\t\tfor i := 0; i < char.Height; i++ {\n\t\t \tbin := char.Data[i]\n\n\t\t\tfor _, pix := range bin {\n\t\t\t\tif string(pix) == \"1\" { setpixel(xx + sx, char.Y + yy, int(c[0]), int(c[1]), int(c[2])) }\n\t\t\t \txx += 1\n\t\t\t}\n\t\t\tyy += 1\n\t\t\txx = x\n\t\t}\n\t\tsx += char.Width\n\t\tyy = y\n\t}\n\n\treturn 1\n}", "func DrawRangeElementsBaseVertex(mode uint32, start uint32, end uint32, count int32, xtype uint32, indices unsafe.Pointer, basevertex int32) {\n C.glowDrawRangeElementsBaseVertex(gpDrawRangeElementsBaseVertex, (C.GLenum)(mode), (C.GLuint)(start), (C.GLuint)(end), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLint)(basevertex))\n}", "func ex1() {\n\tx := [5]int{1, 2, 4, 8, 16}\n\tfor i, v := range x {\n\t\tfmt.Println(i, v)\n\t}\n\tfmt.Printf(\"%T\\n\", x)\n\n}", "func main() {\n\tslice := []int{10, 200, 35, 45, 5, 78, 98, 65, 3, 86}\n\tfmt.Println(slice)\n\tfor i, v := range slice {\n\n\t\tfmt.Println(i, \"->\", v)\n\n\t}\n\n\tfmt.Printf(\"%T\", slice)\n\n}", "func (ren *RenderComponent) generateBufferContent() []float32 {\n\tscaleX := ren.scale.X\n\tscaleY := ren.scale.Y\n\trotation := float32(0.0)\n\ttransparency := float32(1.0)\n\tc := ren.Color\n\n\tfx := float32(0)\n\tfy := float32(0)\n\tfx2 := ren.drawable.Width()\n\tfy2 := ren.drawable.Height()\n\n\tif scaleX != 1 || scaleY != 1 {\n\t\t//fx *= scaleX\n\t\t//fy *= scaleY\n\t\tfx2 *= scaleX\n\t\tfy2 *= scaleY\n\t}\n\n\tp1x := fx\n\tp1y := fy\n\tp2x := fx\n\tp2y := fy2\n\tp3x := fx2\n\tp3y := fy2\n\tp4x := fx2\n\tp4y := fy\n\n\tvar x1 float32\n\tvar y1 float32\n\tvar x2 float32\n\tvar y2 float32\n\tvar x3 float32\n\tvar y3 float32\n\tvar x4 float32\n\tvar y4 float32\n\n\tif rotation != 0 {\n\t\trot := rotation * (math.Pi / 180.0)\n\n\t\tcos := math.Cos(rot)\n\t\tsin := math.Sin(rot)\n\n\t\tx1 = cos*p1x - sin*p1y\n\t\ty1 = sin*p1x + cos*p1y\n\n\t\tx2 = cos*p2x - sin*p2y\n\t\ty2 = sin*p2x + cos*p2y\n\n\t\tx3 = cos*p3x - sin*p3y\n\t\ty3 = sin*p3x + cos*p3y\n\n\t\tx4 = x1 + (x3 - x2)\n\t\ty4 = y3 - (y2 - y1)\n\t} else {\n\t\tx1 = p1x\n\t\ty1 = p1y\n\n\t\tx2 = p2x\n\t\ty2 = p2y\n\n\t\tx3 = p3x\n\t\ty3 = p3y\n\n\t\tx4 = p4x\n\t\ty4 = p4y\n\t}\n\n\tcolorR, colorG, colorB, _ := c.RGBA()\n\n\tred := colorR\n\tgreen := colorG << 8\n\tblue := colorB << 16\n\talpha := uint32(transparency*255.0) << 24\n\n\ttint := math.Float32frombits((alpha | blue | green | red) & 0xfeffffff)\n\n\tu, v, u2, v2 := ren.drawable.View()\n\n\treturn []float32{x1, y1, u, v, tint, x4, y4, u2, v, tint, x3, y3, u2, v2, tint, x2, y2, u, v2, tint}\n}", "func makeSlice(offset dvid.Point3d, size dvid.Point2d) []byte {\n\tnumBytes := size[0] * size[1] * 8\n\tslice := make([]byte, numBytes, numBytes)\n\ti := 0\n\tmodz := offset[2] % int32(len(zdata))\n\tfor y := int32(0); y < size[1]; y++ {\n\t\tsy := y + offset[1]\n\t\tmody := sy % int32(len(ydata))\n\t\tsx := offset[0]\n\t\tfor x := int32(0); x < size[0]; x++ {\n\t\t\tmodx := sx % int32(len(xdata))\n\t\t\tbinary.BigEndian.PutUint64(slice[i:i+8], xdata[modx]+ydata[mody]+zdata[modz])\n\t\t\ti += 8\n\t\t\tsx++\n\t\t}\n\t}\n\treturn slice\n}", "func (p *Pprint) pprint(data interface{}) {\n\t// temp := reflect.TypeOf(data).Kind()\n\t// p.test[\"array\"] = reflect.Map\n\t// fmt.Println(p.test)\n\t// if reflect.Array == temp {\n\t// \tfmt.Println(\"scussu\")\n\t// }\n\t// p.test[temp.String()] = 0\n\tp.Typemode = reflect.TypeOf(data).Kind()\n\tif p.Typemode == reflect.Map {\n\t\tp.PrintMaps(data)\n\t} else if p.Typemode == reflect.Slice {\n\t\tp.PrintArrays(data)\n\t} else if p.Typemode == reflect.Array {\n\t\tp.PrintArrays(data)\n\t} else {\n\t\tfmt.Println(data)\n\t}\n}", "func (a PixelArray) Print() {\n\tfor y := len(a) - 1; y >= 0; y-- {\n\t\tfmt.Printf(\"%d\\t\", y)\n\t\tfor x := 0; x < len(a[0]); x++ {\n\t\t\tfmt.Printf(\"%b%b%b%b%b%b%b%b\",\n\t\t\t\t(a[y][x])&1,\n\t\t\t\t(a[y][x]>>1)&1,\n\t\t\t\t(a[y][x]>>2)&1,\n\t\t\t\t(a[y][x]>>3)&1,\n\t\t\t\t(a[y][x]>>4)&1,\n\t\t\t\t(a[y][x]>>5)&1,\n\t\t\t\t(a[y][x]>>6)&1,\n\t\t\t\t(a[y][x]>>7)&1)\n\t\t}\n\n\t\tfmt.Printf(\"\\n\")\n\t}\n}", "func DrawElementsIndirect(mode uint32, xtype uint32, indirect unsafe.Pointer) {\n C.glowDrawElementsIndirect(gpDrawElementsIndirect, (C.GLenum)(mode), (C.GLenum)(xtype), indirect)\n}", "func (c *Compound) DrawOffset(buff draw.Image, xOff float64, yOff float64) {\n\tc.lock.RLock()\n\tc.subRenderables[c.curRenderable].DrawOffset(buff, c.X()+xOff, c.Y()+yOff)\n\tc.lock.RUnlock()\n}", "func (gl *WebGL) DrawElements(mode GLEnum, count int, valueType GLEnum, offset int) {\n\tgl.context.Call(\"drawElements\", mode, count, valueType, offset)\n}", "func (a *Array) Format(f fmt.State, c rune) {\n\tswitch c {\n\tcase 'z': // Private format specifier, supports Entity.Signature\n\t\tfmt.Fprintf(f, \"[%d]%z\", a.Size, a.ValueType)\n\tcase 'r': // Private format specifier, supports Type.Representation\n\t\tfmt.Fprintf(f, \"[%d]%r\", a.Size, a.ValueType)\n\tdefault:\n\t\tif a.Alias != \"\" {\n\t\t\tfmt.Fprint(f, a.Alias)\n\t\t} else {\n\t\t\tfmt.Fprintf(f, \"[%d]%v\", a.Size, a.ValueType)\n\t\t}\n\t}\n}", "func main() {\n\ts := []int{5, 3, 2, 6, 1, 6, 7, 10, 49, 100}\n\tfor i, v := range s {\n\t\tfmt.Println(i, v)\n\t}\n\tfmt.Printf(\"%T\\n\", s)\n}", "func (p *IntVector) Data() []int {\n\tarr := make([]int, p.Len());\n\tfor i, v := range p.a {\n\t\tarr[i] = v.(int)\n\t}\n\treturn arr;\n}", "func (self *SinglePad) Index() int{\n return self.Object.Get(\"index\").Int()\n}", "func (c *Client) ShowArrayPrism(ctx context.Context, path string, anyArray []interface{}, boolArray []bool, dateTimeArray []time.Time, intArray []int, numArray []float64, stringArray []string, uuidArray []uuid.UUID) (*http.Response, error) {\n\treq, err := c.NewShowArrayPrismRequest(ctx, path, anyArray, boolArray, dateTimeArray, intArray, numArray, stringArray, uuidArray)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\treturn c.Client.Do(ctx, req)\n}", "func MultiDrawElements(mode uint32, count *int32, xtype uint32, indices *unsafe.Pointer, drawcount int32) {\n\tsyscall.Syscall6(gpMultiDrawElements, 5, uintptr(mode), uintptr(unsafe.Pointer(count)), uintptr(xtype), uintptr(unsafe.Pointer(indices)), uintptr(drawcount), 0)\n}", "func iterateObjects1DWithIndexes() {\n\tfmt.Println(\"*** iterateObjects1DWithIndexes\")\n\n\ttype Point struct {\n\t\tX int\n\t\tY int\n\t}\n\tpoints := [5]Point{\n\t\tPoint{1, 1},\n\t\tPoint{2, 2},\n\t\tPoint{3, 3},\n\t\tPoint{4, 4},\n\t\tPoint{5, 5},\n\t}\n\n\tfor i, e := range points {\n\t\tfmt.Printf(\"ints[%d]: %+v\\n\", i, e)\n\t}\n\tfmt.Println(\"\")\n}", "func DrawElements(mode uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n\tC.glowDrawElements(gpDrawElements, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices)\n}", "func DrawElements(mode uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n\tC.glowDrawElements(gpDrawElements, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices)\n}", "func DrawOutput(val int) {\n\tfmt.Printf(\"┌─────────┐\")\n\tfmt.Printf(\"\\n│%9d│\", val)\n\tfmt.Printf(\"\\n└─────────┘\\n\")\n}", "func (h *HAProxyManager) render(ports []uint16) ([]byte, error) {\n\n\t// prepare the context\n\td := make([]templateContext, len(ports))\n\tfor i, port := range ports {\n\t\tif i == len(h.serviceAddrs) {\n\t\t\th.logger.Warnf(\"got port index %d, but only have %d service addrs. ports=%v serviceAddrs=%v\", i, len(h.serviceAddrs), ports, h.serviceAddrs)\n\t\t\tcontinue\n\t\t}\n\t\td[i] = templateContext{Port: port, Source: h.listenAddr, Dest: h.serviceAddrs[i]}\n\t}\n\n\t// render the template\n\tbuf := &bytes.Buffer{}\n\tif err := h.template.Execute(buf, d); err != nil {\n\t\treturn nil, err\n\t}\n\treturn buf.Bytes(), nil\n}", "func traversePos(data []int, index int) []int {\n\tif bt[index] != nil {\n\t\tdata = traversePos(data, (index*2)+1)\n\t\tdata = traversePos(data, (index*2)+2)\n\t\tdata = append(data, bt[index].value)\n\t}\n\treturn data\n}", "func (Parser) Render(rawBytes []byte, urlPrefix string, metas map[string]string, isWiki bool) []byte {\n\treturn Render(rawBytes, urlPrefix, metas, isWiki)\n}", "func DrawElementsBaseVertex(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, basevertex int32) {\n\tsyscall.Syscall6(gpDrawElementsBaseVertex, 5, uintptr(mode), uintptr(count), uintptr(xtype), uintptr(indices), uintptr(basevertex), 0)\n}", "func MultiDrawElementsIndirect(mode uint32, xtype uint32, indirect unsafe.Pointer, drawcount int32, stride int32) {\n\tsyscall.Syscall6(gpMultiDrawElementsIndirect, 5, uintptr(mode), uintptr(xtype), uintptr(indirect), uintptr(drawcount), uintptr(stride), 0)\n}", "func TexCoordPointer(size int32, xtype uint32, stride int32, pointer unsafe.Pointer) {\n C.glowTexCoordPointer(gpTexCoordPointer, (C.GLint)(size), (C.GLenum)(xtype), (C.GLsizei)(stride), pointer)\n}", "func (c *curve) data(x, y *mod.Int) ([]byte, error) {\n\tb := c.encodePoint(x, y)\n\tdl := int(b[0])\n\tif dl > c.embedLen() {\n\t\treturn nil, errors.New(\"invalid embedded data length\")\n\t}\n\treturn b[1 : 1+dl], nil\n}", "func (obj *Device) DrawPrimitiveUP(\n\ttyp PRIMITIVETYPE,\n\tprimitiveCount uint,\n\tvertexStreamZeroData uintptr,\n\tvertexStreamZeroStride uint,\n) Error {\n\tret, _, _ := syscall.Syscall6(\n\t\tobj.vtbl.DrawPrimitiveUP,\n\t\t5,\n\t\tuintptr(unsafe.Pointer(obj)),\n\t\tuintptr(typ),\n\t\tuintptr(primitiveCount),\n\t\tvertexStreamZeroData,\n\t\tuintptr(vertexStreamZeroStride),\n\t\t0,\n\t)\n\treturn toErr(ret)\n}", "func (r renderer) TableCell(out *bytes.Buffer, text []byte, flags int) {}", "func (pb *PageBuffer) Values() interface{} {\n offset := pb.pageOffset(pb.page_no)\n return pb.buffer.Slice(offset, offset + pb.idx).Interface()\n}", "func (renderer *SimpleMatrixRenderer) Render() {\n\trenderer.renderCharacter(\"\\n\")\n\n\tfor row := 0; row < renderer.Matrix.Height; row++ {\n\t\tfor col := 0; col < renderer.Matrix.Width; col++ {\n\t\t\tif !renderer.Matrix.IsFieldOccupied(row, col) {\n\t\t\t\trenderer.renderUnoccupiedField()\n\t\t\t} else {\n\t\t\t\trenderer.renderOccupiedFieldAtCurrentCursorPos(row, col)\n\t\t\t}\n\t\t}\n\n\t\trenderer.renderCharacter(\"\\n\")\n\t}\n\n\trenderer.renderCharacter(\"\\n\")\n}", "func (f genHelperEncoder) EncWriteArrayStart(length int) { f.e.arrayStart(length) }", "func (t *UCharT) Pack(builder *flatbuffers.Builder) flatbuffers.UOffsetT {\n\tif t == nil {\n\t\treturn 0\n\t}\n\tinventoryOffset := flatbuffers.UOffsetT(0)\n\tif t.Inventory != nil {\n\t\tinventoryOffset = builder.CreateByteString(t.Inventory)\n\t}\n\tinventory1Offset := flatbuffers.UOffsetT(0)\n\tif t.Inventory1 != nil {\n\t\tinventory1Length := len(t.Inventory1)\n\t\tUCharStartInventory1Vector(builder, inventory1Length)\n\t\tfor j := inventory1Length - 1; j >= 0; j-- {\n\t\t\tbuilder.PrependInt8(t.Inventory1[j])\n\t\t}\n\t\tinventory1Offset = UCharEndInventory1Vector(builder, inventory1Length)\n\t}\n\tcolorListOffset := flatbuffers.UOffsetT(0)\n\tif t.ColorList != nil {\n\t\tcolorListLength := len(t.ColorList)\n\t\tUCharStartColorListVector(builder, colorListLength)\n\t\tfor j := colorListLength - 1; j >= 0; j-- {\n\t\t\tbuilder.PrependInt8(int8(t.ColorList[j]))\n\t\t}\n\t\tcolorListOffset = UCharEndColorListVector(builder, colorListLength)\n\t}\n\n\t// pack process all field\n\n\tUCharStart(builder)\n\tUCharAddInventory(builder, inventoryOffset)\n\tUCharAddInventory1(builder, inventory1Offset)\n\tUCharAddColorList(builder, colorListOffset)\n\treturn UCharEnd(builder)\n}", "func renderTemplateBytes(name string, data interface{}) ([]byte, error) {\n\tvar buf bytes.Buffer\n\tif err := Tmpl.Render(&buf, name, data); err != nil {\n\t\treturn nil, err\n\t}\n\treturn buf.Bytes(), nil\n}", "func renderTemplateBytes(name string, data interface{}) ([]byte, error) {\n\tvar buf bytes.Buffer\n\tif err := Tmpl.Render(&buf, name, data); err != nil {\n\t\treturn nil, err\n\t}\n\treturn buf.Bytes(), nil\n}", "func (c *cartridge) Render() {\n\tc.Cls()\n\tc.PrintAt(fmt.Sprintf(\"counter:%d\", c.counter), c.x, c.y)\n}", "func DrawElementsBaseVertex(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, basevertex int32) {\n C.glowDrawElementsBaseVertex(gpDrawElementsBaseVertex, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLint)(basevertex))\n}", "func (r renderer) Table(out *bytes.Buffer, header []byte, body []byte, columnData []int) {}", "func (renderer *SimpleMatrixRenderer) renderOccupiedFieldAtCurrentCursorPos(row int, col int) {\n\tpiece := renderer.Matrix.GetPieceOccupying(row, col)\n\n\tr, g, b := (*piece).GetColorAsRGB()\n\ttotal := int(r) + int(g) + int(b)\n\n\tcharacter := \"▧\"\n\tcharacterColor := black\n\n\tif total > 230*3 {\n\t\tcharacterColor = color.New(color.FgBlue)\n\t} else if total > 180*3 {\n\t\tcharacterColor = color.New(color.FgYellow)\n\t} else if total > 120*3 {\n\t\tcharacterColor = color.New(color.FgRed)\n\t} else if total > 50*3 {\n\t\tcharacterColor = color.New(color.FgGreen)\n\t} else {\n\t\tcharacterColor = color.New(color.FgMagenta)\n\t}\n\n\trenderer.renderCharacterWithColor(character, characterColor)\n}", "func (r renderer) ListItem(out *bytes.Buffer, text []byte, flags int) {}", "func (el *Fill) TSpan() {}", "func (isf intSliceFunctorImpl) String() string {\n\treturn fmt.Sprintf(\"%#v\", isf.ints)\n}", "func PrintArray(a *[]int) {\n\tvar i int\n\tfor i < len(*a) {\n\t\tfmt.Printf(\"%v\\t\", (*a)[i])\n\t\ti++\n\t}\n\tfmt.Printf(\"\\n\")\n}", "func PrintArray(a *[]int) {\n\tvar i int\n\tfor i < len(*a) {\n\t\tfmt.Printf(\"%v\\t\", (*a)[i])\n\t\ti++\n\t}\n\tfmt.Printf(\"\\n\")\n}", "func (w wireFormat) MapBySlice() {}", "func (s *SliceInt) Data() []int {\n\tif s == nil {\n\t\treturn nil\n\t}\n\treturn s.data\n}", "func (p *printer) Array(element string) {\n\tp.Formatter.Array(element)\n}", "func (this *Data) Byte(offset uintptr) []byte {\n\tvar result []byte\n\thdr := (*reflect.SliceHeader)(unsafe.Pointer(&result))\n\thdr.Data = this.buf + uintptr(offset)\n\thdr.Len = int(this.cap) - int(offset)\n\thdr.Cap = hdr.Len\n\treturn result\n}", "func (f *Font) Index(r rune) uint16 {\n\t// log.Printf(\"r %v\", r)\n\t// log.Printf(\"len %v\", len(f.cmap_entry_array))\n\tcm_len := len(f.cmap_entry_array)\n\n\tx := uint32(r)\n\tfor lo, hi := 0, cm_len; lo < hi; {\n\t\tmi := lo + (hi-lo)/2\n\t\t// log.Printf(\"lo hi mi %v %v %v\", lo, hi, mi)\n\t\tcm := &f.cmap_entry_array[mi]\n\t\t// log.Printf(\"cm %v\", cm)\n\t\tif x < cm.start_code {\n\t\t\thi = mi\n\t\t} else if cm.end_code < x {\n\t\t\tlo = mi + 1\n\t\t} else if cm.id_range_offset == 0 {\n\t\t\t// log.Printf(\"x id_delta %v %v\", x, cm.id_delta)\n\t\t\treturn uint16(x + cm.id_delta)\n\t\t} else {\n\t\t\toffset := int(cm.id_range_offset) + 2*(mi-cm_len+int(x-cm.start_code))\n\t\t\treturn uint16(octets_to_u16(f.cmap_index_array, offset))\n\t\t}\n\t}\n\n\treturn 0\n}", "func (g *interfaceGenerator) unmarshalPrimitiveScalar(accessor, typ, bufVar, typeCast string) {\n\tswitch typ {\n\tcase \"byte\":\n\t\tg.emit(\"*%s = %s(%s[0])\\n\", accessor, typeCast, bufVar)\n\tcase \"int8\", \"uint8\":\n\t\tg.emit(\"*%s = %s(%s(%s[0]))\\n\", accessor, typeCast, typ, bufVar)\n\tcase \"int16\", \"uint16\":\n\t\tg.recordUsedImport(\"usermem\")\n\t\tg.emit(\"*%s = %s(%s(usermem.ByteOrder.Uint16(%s[:2])))\\n\", accessor, typeCast, typ, bufVar)\n\tcase \"int32\", \"uint32\":\n\t\tg.recordUsedImport(\"usermem\")\n\t\tg.emit(\"*%s = %s(%s(usermem.ByteOrder.Uint32(%s[:4])))\\n\", accessor, typeCast, typ, bufVar)\n\tcase \"int64\", \"uint64\":\n\t\tg.recordUsedImport(\"usermem\")\n\t\tg.emit(\"*%s = %s(%s(usermem.ByteOrder.Uint64(%s[:8])))\\n\", accessor, typeCast, typ, bufVar)\n\tdefault:\n\t\tg.emit(\"// Explicilty cast to the underlying type before dispatching to\\n\")\n\t\tg.emit(\"// UnmarshalBytes, so we don't recursively call %s.UnmarshalBytes\\n\", accessor)\n\t\tg.emit(\"inner := (*%s)(%s)\\n\", typ, accessor)\n\t\tg.emit(\"inner.UnmarshalBytes(%s[:%s.SizeBytes()])\\n\", bufVar, accessor)\n\t}\n}", "func (cont *tuiApplicationController) drawView() {\n\tcont.Sync.Lock()\n\tif !cont.Changed || cont.TuiFileReaderWorker == nil {\n\t\tcont.Sync.Unlock()\n\t\treturn\n\t}\n\tcont.Sync.Unlock()\n\n\t// reset the elements by clearing out every one\n\ttviewApplication.QueueUpdateDraw(func() {\n\t\tfor _, t := range displayResults {\n\t\t\tt.Title.SetText(\"\")\n\t\t\tt.Body.SetText(\"\")\n\t\t\tt.SpacerOne.SetText(\"\")\n\t\t\tt.SpacerTwo.SetText(\"\")\n\t\t\tresultsFlex.ResizeItem(t.Body, 0, 0)\n\t\t}\n\t})\n\n\tcont.Sync.Lock()\n\tresultsCopy := make([]*FileJob, len(cont.Results))\n\tcopy(resultsCopy, cont.Results)\n\tcont.Sync.Unlock()\n\n\t// rank all results\n\t// then go and get the relevant portion for display\n\trankResults(int(cont.TuiFileReaderWorker.GetFileCount()), resultsCopy)\n\tdocumentTermFrequency := calculateDocumentTermFrequency(resultsCopy)\n\n\t// after ranking only get the details for as many as we actually need to\n\t// cut down on processing\n\tif len(resultsCopy) > len(displayResults) {\n\t\tresultsCopy = resultsCopy[:len(displayResults)]\n\t}\n\n\t// We use this to swap out the highlights after we escape to ensure that we don't escape\n\t// out own colours\n\tmd5Digest := md5.New()\n\tfmtBegin := hex.EncodeToString(md5Digest.Sum([]byte(fmt.Sprintf(\"begin_%d\", makeTimestampNano()))))\n\tfmtEnd := hex.EncodeToString(md5Digest.Sum([]byte(fmt.Sprintf(\"end_%d\", makeTimestampNano()))))\n\n\t// go and get the codeResults the user wants to see using selected as the offset to display from\n\tvar codeResults []codeResult\n\tfor i, res := range resultsCopy {\n\t\tif i >= cont.Offset {\n\t\t\tsnippets := extractRelevantV3(res, documentTermFrequency, int(SnippetLength), \"…\")[0]\n\n\t\t\t// now that we have the relevant portion we need to get just the bits related to highlight it correctly\n\t\t\t// which this method does. It takes in the snippet, we extract and all of the locations and then returns just\n\t\t\tl := getLocated(res, snippets)\n\t\t\tcoloredContent := str.HighlightString(snippets.Content, l, fmtBegin, fmtEnd)\n\t\t\tcoloredContent = tview.Escape(coloredContent)\n\n\t\t\tcoloredContent = strings.Replace(coloredContent, fmtBegin, \"[red]\", -1)\n\t\t\tcoloredContent = strings.Replace(coloredContent, fmtEnd, \"[white]\", -1)\n\n\t\t\tcodeResults = append(codeResults, codeResult{\n\t\t\t\tTitle: res.Location,\n\t\t\t\tContent: coloredContent,\n\t\t\t\tScore: res.Score,\n\t\t\t\tLocation: res.Location,\n\t\t\t})\n\t\t}\n\t}\n\n\t// render out what the user wants to see based on the results that have been chosen\n\ttviewApplication.QueueUpdateDraw(func() {\n\t\tfor i, t := range codeResults {\n\t\t\tdisplayResults[i].Title.SetText(fmt.Sprintf(\"[fuchsia]%s (%f)[-:-:-]\", t.Title, t.Score))\n\t\t\tdisplayResults[i].Body.SetText(t.Content)\n\t\t\tdisplayResults[i].Location = t.Location\n\n\t\t\t//we need to update the item so that it displays everything we have put in\n\t\t\tresultsFlex.ResizeItem(displayResults[i].Body, len(strings.Split(t.Content, \"\\n\")), 0)\n\t\t}\n\t})\n\n\t// we can only set that nothing\n\tcont.Changed = false\n}", "func printArray(arr [5]int) {\n\tarr[0] = 100\n\tfor i, v := range arr {\n\t\tfmt.Println(i, v)\n\t}\n}", "func TemplateData(p string, data interface{}) {\n}", "func (ff *fftag) at(id int) (x, y int) { return id / ff.msize, id % ff.msize }", "func (e rawEntry) value(buf []byte) rawValue { return buf[e.ptr():][:e.sz()] }" ]
[ "0.585935", "0.52075523", "0.5084374", "0.50331354", "0.49324766", "0.49158472", "0.47837278", "0.47759205", "0.47650397", "0.47415584", "0.47280264", "0.4711649", "0.46952814", "0.46948847", "0.46581078", "0.46546912", "0.4645866", "0.4645866", "0.46294165", "0.4621351", "0.46151462", "0.45862997", "0.4569046", "0.45608258", "0.45602304", "0.45508763", "0.45205447", "0.45182082", "0.45012426", "0.44990006", "0.44898683", "0.4485599", "0.44834146", "0.44771138", "0.44771138", "0.44735974", "0.4457397", "0.44468623", "0.44385836", "0.4434415", "0.4424735", "0.4406977", "0.44036135", "0.4395799", "0.43906114", "0.43863577", "0.43735808", "0.43662465", "0.4358424", "0.43466768", "0.43428254", "0.43425608", "0.43332392", "0.43324766", "0.4327725", "0.43212283", "0.4299294", "0.42948902", "0.42931882", "0.42930514", "0.42899758", "0.4288373", "0.4288373", "0.4285799", "0.42789567", "0.4278423", "0.42754033", "0.4270644", "0.42685115", "0.42660847", "0.426504", "0.42621335", "0.42607495", "0.42560473", "0.42518598", "0.42515504", "0.42440006", "0.4242743", "0.4242743", "0.42426482", "0.42423233", "0.4241733", "0.4238865", "0.4238587", "0.42337468", "0.42179447", "0.42178208", "0.42178208", "0.42153642", "0.42118526", "0.4211703", "0.42063305", "0.42050475", "0.4201446", "0.41942853", "0.41914222", "0.41851667", "0.41804147", "0.4160377" ]
0.4187597
97
render primitives using a count derived from a transform feedback object
func DrawTransformFeedback(mode uint32, id uint32) { C.glowDrawTransformFeedback(gpDrawTransformFeedback, (C.GLenum)(mode), (C.GLuint)(id)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func (sr scoresRenderer) Render() string {\n\tbuffer := bytes.Buffer{}\n\tlast := len(sr.scores) - 1\n\tfor i, score := range sr.scores {\n\t\tbuffer.WriteString(fmt.Sprintf(\"%d\", score))\n\t\tif i != last {\n\t\t\tbuffer.WriteString(\" / \")\n\t\t}\n\t}\n\treturn buffer.String()\n}", "func (r *Renderer) Render() {\n\tsx, sz, sy := r.c.Bounds()\n\tsxf := float64(sx - 1)\n\tsyf := float64(sy - 1)\n\tszf := float64(sz - 1)\n\tfor z := 0; z < sz; z++ {\n\t\tfor y := 0; y < sy; y++ {\n\t\t\tfor x := 0; x < sx; x++ {\n\t\t\t\tvar lr, lg, lb, _ uint32\n\t\t\t\tn := uint32(0)\n\t\t\t\tfor _, o := range r.objects {\n\t\t\t\t\tr, g, b, _ := o.At(float64(x)/sxf, float64(y)/syf, float64(z)/szf).RGBA()\n\t\t\t\t\tlr += r >> 8\n\t\t\t\t\tlg += g >> 8\n\t\t\t\t\tlb += b >> 8\n\t\t\t\t\tn++\n\t\t\t\t}\n\t\t\t\tr.c.Set(x, y, z, color.RGBA{uint8(lr/n), uint8(lg/n), uint8(lb/n), 255})\n\t\t\t}\n\t\t}\n\t}\n\tr.c.Render()\n}", "func render(fset *token.FileSet, x interface{}) string {\n\tvar buf bytes.Buffer\n\tif err := printer.Fprint(&buf, fset, x); err != nil {\n\t\tpanic(err)\n\t}\n\treturn buf.String()\n}", "func render(fset *token.FileSet, x interface{}) string {\n\tvar buf bytes.Buffer\n\tif err := printer.Fprint(&buf, fset, x); err != nil {\n\t\tpanic(err)\n\t}\n\treturn buf.String()\n}", "func (rf RendererFunc) Render(w io.Writer, v interface{}) error { return rf(w, v) }", "func (c *cartridge) Render() {\n\tc.Cls()\n\tc.PrintAt(fmt.Sprintf(\"counter:%d\", c.counter), c.x, c.y)\n}", "func (ren *RenderComponent) generateBufferContent() []float32 {\n\tscaleX := ren.scale.X\n\tscaleY := ren.scale.Y\n\trotation := float32(0.0)\n\ttransparency := float32(1.0)\n\tc := ren.Color\n\n\tfx := float32(0)\n\tfy := float32(0)\n\tfx2 := ren.drawable.Width()\n\tfy2 := ren.drawable.Height()\n\n\tif scaleX != 1 || scaleY != 1 {\n\t\t//fx *= scaleX\n\t\t//fy *= scaleY\n\t\tfx2 *= scaleX\n\t\tfy2 *= scaleY\n\t}\n\n\tp1x := fx\n\tp1y := fy\n\tp2x := fx\n\tp2y := fy2\n\tp3x := fx2\n\tp3y := fy2\n\tp4x := fx2\n\tp4y := fy\n\n\tvar x1 float32\n\tvar y1 float32\n\tvar x2 float32\n\tvar y2 float32\n\tvar x3 float32\n\tvar y3 float32\n\tvar x4 float32\n\tvar y4 float32\n\n\tif rotation != 0 {\n\t\trot := rotation * (math.Pi / 180.0)\n\n\t\tcos := math.Cos(rot)\n\t\tsin := math.Sin(rot)\n\n\t\tx1 = cos*p1x - sin*p1y\n\t\ty1 = sin*p1x + cos*p1y\n\n\t\tx2 = cos*p2x - sin*p2y\n\t\ty2 = sin*p2x + cos*p2y\n\n\t\tx3 = cos*p3x - sin*p3y\n\t\ty3 = sin*p3x + cos*p3y\n\n\t\tx4 = x1 + (x3 - x2)\n\t\ty4 = y3 - (y2 - y1)\n\t} else {\n\t\tx1 = p1x\n\t\ty1 = p1y\n\n\t\tx2 = p2x\n\t\ty2 = p2y\n\n\t\tx3 = p3x\n\t\ty3 = p3y\n\n\t\tx4 = p4x\n\t\ty4 = p4y\n\t}\n\n\tcolorR, colorG, colorB, _ := c.RGBA()\n\n\tred := colorR\n\tgreen := colorG << 8\n\tblue := colorB << 16\n\talpha := uint32(transparency*255.0) << 24\n\n\ttint := math.Float32frombits((alpha | blue | green | red) & 0xfeffffff)\n\n\tu, v, u2, v2 := ren.drawable.View()\n\n\treturn []float32{x1, y1, u, v, tint, x4, y4, u2, v, tint, x3, y3, u2, v2, tint, x2, y2, u, v2, tint}\n}", "func (e *rawData) Render(w io.Writer) (int, error) { return w.Write([]byte(e.content)) }", "func (c *regularResourceComponent) Render(out io.Writer) (numLines int, err error) {\n\tc.mu.Lock()\n\tdefer c.mu.Unlock()\n\n\tcomponents := cfnLineItemComponents(c.description, c.separator, c.statuses, c.stopWatch, c.padding)\n\treturn renderComponents(out, components)\n}", "func TransformFeedbackVaryings(program uint32, count int32, varyings **int8, bufferMode uint32) {\n C.glowTransformFeedbackVaryings(gpTransformFeedbackVaryings, (C.GLuint)(program), (C.GLsizei)(count), (**C.GLchar)(unsafe.Pointer(varyings)), (C.GLenum)(bufferMode))\n}", "func CountPrintf(f string, vals ...interface{}) {\n\tcount++\n\tfmt.Printf(fmt.Sprintf(\"%d - \", count)+f, vals...)\n}", "func (p *Processor) Render() vdom.Element {\n\tmaxConnectors := p.ProcessorDefinition.MaxConnectors()\n\tprocName := p.ProcessorDefinition.Name\n\tprocDefName, procInputs, procOutputs, procParameters := p.ProcessorDefinition.Processor.Definition()\n\tif len(procName) == 0 {\n\t\tprocName = procDefName\n\t}\n\n\tprocWidth := procDefaultWidth\n\tprocHeight := (maxConnectors + 2 + len(procParameters)) * procConnWidth * 2\n\n\tcustomRenderDimentions, ok := p.ProcessorDefinition.Processor.(customRenderDimentions)\n\tif ok {\n\t\tprocWidth, procHeight = customRenderDimentions.CustomRenderDimentions()\n\t}\n\n\tprocNameLabel := vdom.MakeElement(\"text\",\n\t\t\"font-family\", \"sans-serif\",\n\t\t\"text-anchor\", \"middle\",\n\t\t\"alignment-baseline\", \"hanging\",\n\t\t\"font-size\", 10,\n\t\t\"x\", p.ProcessorDefinition.X+procWidth/2,\n\t\t\"y\", p.ProcessorDefinition.Y+4,\n\t\tvdom.MakeTextElement(procName),\n\t)\n\tprocLine := vdom.MakeElement(\"line\",\n\t\t\"stroke\", \"black\",\n\t\t\"x1\", float64(p.ProcessorDefinition.X)+0.5,\n\t\t\"y1\", float64(p.ProcessorDefinition.Y)+16+0.5,\n\t\t\"x2\", float64(p.ProcessorDefinition.X)+float64(procWidth)+0.5,\n\t\t\"y2\", float64(p.ProcessorDefinition.Y)+16+0.5,\n\t)\n\n\tinConnectors := []vdom.Element{}\n\tfor i := 0; i < len(procInputs); i++ {\n\t\tx, y := p.GetConnectorPoint(procWidth, true, i)\n\t\tconnector := vdom.MakeElement(\"rect\",\n\t\t\t\"id\", procName+\":inconn:\"+strconv.Itoa(i),\n\t\t\t\"x\", x-procConnWidth/2,\n\t\t\t\"y\", y-procConnWidth/2,\n\t\t\t\"width\", procConnWidth,\n\t\t\t\"height\", procConnWidth,\n\t\t\t\"stroke\", \"black\",\n\t\t\t\"fill\", \"none\",\n\t\t\t\"pointer-events\", \"all\",\n\t\t\t\"cursor\", \"crosshair\",\n\t\t\tvdom.MakeEventHandler(vdom.MouseDown, p.makeConnectorEventHandler(true, i)),\n\t\t\tvdom.MakeEventHandler(vdom.MouseMove, p.makeConnectorEventHandler(true, i)),\n\t\t)\n\t\tinConnectors = append(inConnectors, connector)\n\n\t\tlabel := vdom.MakeElement(\"text\",\n\t\t\t\"font-family\", \"sans-serif\",\n\t\t\t\"text-anchor\", \"start\",\n\t\t\t\"alignment-baseline\", \"middle\",\n\t\t\t\"font-size\", 10,\n\t\t\t\"x\", x+(procConnWidth/2+2),\n\t\t\t\"y\", y,\n\t\t\tvdom.MakeTextElement(procInputs[i]),\n\t\t)\n\t\tinConnectors = append(inConnectors, label)\n\t}\n\n\toutConnectors := []vdom.Element{}\n\tfor i := 0; i < len(procOutputs); i++ {\n\t\tx, y := p.GetConnectorPoint(procWidth, false, i)\n\t\tconnector := vdom.MakeElement(\"rect\",\n\t\t\t\"id\", procName+\":outconn:\"+strconv.Itoa(i),\n\t\t\t\"x\", x-procConnWidth/2,\n\t\t\t\"y\", y-procConnWidth/2,\n\t\t\t\"width\", procConnWidth,\n\t\t\t\"height\", procConnWidth,\n\t\t\t\"stroke\", \"black\",\n\t\t\t\"fill\", \"none\",\n\t\t\t\"pointer-events\", \"all\",\n\t\t\t\"cursor\", \"crosshair\",\n\t\t\tvdom.MakeEventHandler(vdom.MouseDown, p.makeConnectorEventHandler(false, i)),\n\t\t\tvdom.MakeEventHandler(vdom.MouseMove, p.makeConnectorEventHandler(false, i)),\n\t\t)\n\t\toutConnectors = append(outConnectors, connector)\n\n\t\tlabel := vdom.MakeElement(\"text\",\n\t\t\t\"font-family\", \"sans-serif\",\n\t\t\t\"text-anchor\", \"end\",\n\t\t\t\"alignment-baseline\", \"middle\",\n\t\t\t\"font-size\", 10,\n\t\t\t\"x\", x-(procConnWidth/2+4),\n\t\t\t\"y\", y,\n\t\t\tvdom.MakeTextElement(procOutputs[i]),\n\t\t)\n\t\toutConnectors = append(outConnectors, label)\n\t}\n\n\tparameters := []vdom.Element{}\n\tfor i := 0; i < len(procParameters); i++ {\n\t\t_, y := p.GetConnectorPoint(procWidth, true, i+maxConnectors)\n\n\t\twidth := procWidth - ((procConnWidth + 2) * 2)\n\t\tlevelValue := strconv.FormatFloat(float64(procParameters[i].Value), 'f', -1, 32)\n\t\tlevelWidth := int(float32(width) * (procParameters[i].Value / procParameters[i].Max))\n\t\tlevelFactor := float32(width) / procParameters[i].Max\n\n\t\tlevel := vdom.MakeElement(\"rect\",\n\t\t\t\"id\", procName+\":parameter:\"+strconv.Itoa(i),\n\t\t\t\"x\", p.ProcessorDefinition.X+procConnWidth+2,\n\t\t\t\"y\", y-2,\n\t\t\t\"width\", levelWidth,\n\t\t\t\"height\", procConnWidth+4,\n\t\t\t\"stroke\", \"none\",\n\t\t\t\"fill\", \"cyan\",\n\t\t\t\"pointer-events\", \"none\",\n\t\t)\n\t\tparameters = append(parameters, level)\n\n\t\tbound := vdom.MakeElement(\"rect\",\n\t\t\t\"id\", procName+\":parameter:\"+strconv.Itoa(i),\n\t\t\t\"x\", p.ProcessorDefinition.X+procConnWidth+2,\n\t\t\t\"y\", y-2,\n\t\t\t\"width\", width,\n\t\t\t\"height\", procConnWidth+4,\n\t\t\t\"stroke\", \"black\",\n\t\t\t\"fill\", \"none\",\n\t\t\t\"pointer-events\", \"all\",\n\t\t\t\"cursor\", \"crosshair\",\n\t\t\tvdom.MakeEventHandler(vdom.MouseDown, p.makeParameterEventHandler(i, levelFactor)),\n\t\t\tvdom.MakeEventHandler(vdom.MouseUp, p.makeParameterEventHandler(i, levelFactor)),\n\t\t\tvdom.MakeEventHandler(vdom.MouseMove, p.makeParameterEventHandler(i, levelFactor)),\n\t\t\tvdom.MakeEventHandler(vdom.MouseLeave, p.makeParameterEventHandler(i, levelFactor)),\n\t\t\tvdom.MakeElement(\"title\", vdom.MakeTextElement(levelValue)),\n\t\t)\n\t\tparameters = append(parameters, bound)\n\n\t\tname := vdom.MakeElement(\"text\",\n\t\t\t\"font-family\", \"sans-serif\",\n\t\t\t\"text-anchor\", \"middle\",\n\t\t\t\"alignment-baseline\", \"hanging\",\n\t\t\t\"font-size\", 10,\n\t\t\t\"x\", p.ProcessorDefinition.X+(procWidth/2),\n\t\t\t\"y\", y,\n\t\t\tvdom.MakeTextElement(procParameters[i].Name))\n\t\tparameters = append(parameters, name)\n\t}\n\n\telement := vdom.MakeElement(\"g\",\n\t\tvdom.MakeElement(\"rect\",\n\t\t\t\"id\", procName,\n\t\t\t\"x\", p.ProcessorDefinition.X,\n\t\t\t\"y\", p.ProcessorDefinition.Y,\n\t\t\t\"width\", procWidth,\n\t\t\t\"height\", procHeight,\n\t\t\t\"stroke\", \"black\",\n\t\t\t\"fill\", \"white\",\n\t\t\t\"cursor\", \"pointer\",\n\t\t\tvdom.MakeEventHandler(vdom.MouseDown, p.processorEventHandler),\n\t\t\tvdom.MakeEventHandler(vdom.MouseUp, p.processorEventHandler),\n\t\t\tvdom.MakeEventHandler(vdom.MouseMove, p.processorEventHandler),\n\t\t\tvdom.MakeEventHandler(vdom.ContextMenu, p.processorEventHandler),\n\t\t),\n\t\tprocNameLabel,\n\t\tprocLine,\n\t\tinConnectors,\n\t\toutConnectors,\n\t\tparameters,\n\t)\n\n\tcustom, ok := p.ProcessorDefinition.Processor.(vdom.Component)\n\tif ok {\n\t\telement.AppendChild(vdom.MakeElement(\"g\",\n\t\t\t\"transform\", \"translate(\"+strconv.Itoa(p.ProcessorDefinition.X)+\",\"+strconv.Itoa(p.ProcessorDefinition.Y)+\")\",\n\t\t\tcustom,\n\t\t))\n\t}\n\n\treturn element\n}", "func (t *textRender) Render(w io.Writer) (err error) {\n\tif len(t.Values) > 0 {\n\t\t_, err = fmt.Fprintf(w, t.Format, t.Values...)\n\t} else {\n\t\t_, err = io.WriteString(w, t.Format)\n\t}\n\treturn\n}", "func CountAndSay(n int) string {\n\tres := \"1\"\n\tfor i := 0; i < n-1; i++ {\n\t\tres = translate(res)\n\t}\n\treturn res\n}", "func (r *Renderer) Render() {\n\tgl.DrawArrays(gl.TRIANGLES, 0, int32(len(r.RawRenderer)*4))\n}", "func (o GroupContainerGpuOutput) Count() pulumi.IntPtrOutput {\n\treturn o.ApplyT(func(v GroupContainerGpu) *int { return v.Count }).(pulumi.IntPtrOutput)\n}", "func (params complexPropertyConversionParameters) countArraysAndMapsInConversionContext() int {\n\tresult := 0\n\tfor _, t := range params.conversionContext {\n\t\tswitch t.(type) {\n\t\tcase *astmodel.MapType:\n\t\t\tresult += 1\n\t\tcase *astmodel.ArrayType:\n\t\t\tresult += 1\n\t\t}\n\t}\n\n\treturn result\n}", "func renderInteger(f float64) string {\n\tif f > math.Nextafter(float64(math.MaxInt64), 0) {\n\t\treturn fmt.Sprintf(\"%d\", int64(math.MaxInt64))\n\t}\n\tif f < math.Nextafter(float64(math.MinInt64), 0) {\n\t\treturn fmt.Sprintf(\"%d\", int64(math.MinInt64))\n\t}\n\treturn fmt.Sprintf(\"%d\", int64(f))\n}", "func Render(state *model.Model) time.Duration {\n\tt := time.Now()\n\n\trenderer.SetDrawColor(255, 255, 255, 255)\n\trenderer.FillRect(fullScreenRect)\n\n\tcurrentSurface, _ := window.GetSurface()\n\n\tl := layout.New(screenWidth, screenHeight)\n\n\tinstruments := l.Row(instrumentHeight)\n\tdistanceCell := instruments.Col(columnWidth)\n\tspeedCell := instruments.Col(columnWidth)\n\theadingCell := instruments.Col(columnWidth)\n\n\tRenderHeadingCell(state, currentSurface, headingCell)\n\tRenderDistanceCell(state, currentSurface, distanceCell)\n\tRenderSpeedCell(state, currentSurface, speedCell)\n\n\trenderer.SetDrawColor(255, 255, 255, 255)\n\n\t// waypoints 1 - 3\n\tif len(state.Book) > 0 {\n\t\t//TODO: breaks if there aren't Idx + 3 remaining\n\t\tfor idx, waypoint := range state.Book[state.Idx : state.Idx+3] {\n\t\t\ty := int32(instrumentHeight + idx*waypointHeight)\n\t\t\tbg := &sdl.Rect{0, y, int32(screenWidth), int32(waypointHeight)}\n\t\t\tr, g, b, _ := waypoint.Background.RGBA()\n\n\t\t\t// box\n\t\t\trenderer.SetDrawColor(uint8(r), uint8(g), uint8(b), 255)\n\t\t\trenderer.FillRect(bg)\n\n\t\t\t// distance\n\t\t\ttextBg := sdl.Color{uint8(r), uint8(g), uint8(b), 255}\n\t\t\ttextFg := sdl.Color{0, 0, 0, 255}\n\t\t\tif waypoint.Background == color.Black {\n\t\t\t\ttextFg = sdl.Color{255, 255, 255, 255}\n\t\t\t}\n\n\t\t\tdistanceFormat := \"%0.1f\"\n\t\t\tif (appcontext.GContext.NumAfterDecimal == 2) {\n\t\t\t\tdistanceFormat = \"%0.2f\"\n\t\t\t}\n\t\t\tdistance, _ := dinMedium144.RenderUTF8Shaded(strings.Replace(fmt.Sprintf(distanceFormat, waypoint.Distance), \".\", \",\", -1), textFg, textBg)\n\n\t\t\tdistRect := distance.ClipRect\n\t\t\tdistance.Blit(nil, currentSurface, &sdl.Rect{(columnWidth - distRect.W) / 2, bg.Y + (waypointHeight-distRect.H)/2, 0, 0})\n\t\t\tdistance.Free()\n\n\t\t\t// tulip and notes\n\t\t\tpair := getTulipNotesPair(state.Idx+idx, &waypoint)\n\n\t\t\tpair.tulip.Blit(nil, currentSurface, &sdl.Rect{columnWidth, bg.Y + (waypointHeight-TulipHeight)/2, 0, 0})\n\t\t\tpair.notes.Blit(nil, currentSurface, &sdl.Rect{columnWidth * 2, bg.Y + (waypointHeight-NotesHeight)/2, 0, 0})\n\n\t\t\t// divider\n\t\t\trenderer.SetDrawColor(0, 0, 0, 255)\n\t\t\tbg.H = dividerHeight\n\t\t\trenderer.FillRect(bg)\n\t\t}\n\t\t//TODO: draw divider even when no waypoints exist\n\t}\n\n\tgc := appcontext.GContext\n\tgm := appmanager.GAppManager\n\n\tmainWindowSurface := gc.MainSurface\n\tgm.Render(mainWindowSurface)\n\n\t// display frame\n\trenderer.Present()\n\n\t// ensure we wait at least frameDuration\n\tfpsDelay := frameDuration - time.Since(t)\n\treturn fpsDelay\n}", "func (r *JSONRenderer) Render(out io.Writer, st *papers.Stats, unread, read papers.AggPapers) {\n\tr.render(out, st, unread, read)\n}", "func (tm *TreasureMap) render() {\n\tvar (\n\t\ttreasureMapDrawPerLine, treasureMapDrawComplete, treasureMapAdditional string\n\t)\n\n\tfor y := 1; y <= tm.Size[1]; y++ {\n\t\ttreasureMapDrawPerLine = \"\"\n\t\tif y < tm.Size[1] {\n\t\t\ttreasureMapDrawPerLine = \"\\n\"\n\t\t}\n\t\tfor x := 1; x <= tm.Size[0]; x++ {\n\t\t\ttreasureMapDrawPerLine = treasureMapDrawPerLine + convertIntToEntity(tm.Mapping[[2]int{x, y}])\n\t\t}\n\t\ttreasureMapDrawComplete = treasureMapDrawPerLine + treasureMapDrawComplete\n\t}\n\n\tif len(tm.ListPossibleTreasureLocation) > 0 {\n\t\tfor coordinate, possibleLocation := range tm.ListPossibleTreasureLocation {\n\t\t\tcoordinateString := strconv.Itoa(coordinate[0]) + \",\" + strconv.Itoa(coordinate[1])\n\t\t\tif possibleLocation {\n\t\t\t\ttreasureMapAdditional = treasureMapAdditional + fmt.Sprintf(\"{%s},\", coordinateString)\n\t\t\t}\n\t\t}\n\t\ttreasureMapDrawComplete = treasureMapDrawComplete + fmt.Sprintf(\"\\nPossible treasure location: %s\", treasureMapAdditional)\n\t}\n\n\tif tm.TreasureLocation != [2]int{} {\n\t\tcoordinateString := strconv.Itoa(tm.TreasureLocation[0]) + \",\" + strconv.Itoa(tm.TreasureLocation[1])\n\t\ttreasureMapDrawComplete = treasureMapDrawComplete + fmt.Sprintf(\"\\nTreasure found at location: {%s}! Congratulation!\", coordinateString)\n\t}\n\n\trenderToTerminal(treasureMapDrawComplete)\n}", "func (v Binary) Render(i, width int, baseStyle lipgloss.Style) string {\n\tw := dataWidth(width)\n\t_, err := v.Seek(int64(i*w), io.SeekStart)\n\tif err != nil {\n\t\treturn baseStyle.Blink(true).Render(err.Error())\n\t}\n\tif len(v.b) != w {\n\t\tv.b = make([]byte, w)\n\t}\n\tn, err := v.Read(v.b)\n\tif err != nil && !errors.Is(err, io.EOF) {\n\t\treturn baseStyle.Blink(true).Render(err.Error())\n\t}\n\ts := fmt.Sprintf(\"% X%s \", v.b[0:n], strings.Repeat(\" \", w-n))\n\tvar x strings.Builder\n\tfor i := 0; i < n; i++ {\n\t\tif unicode.IsPrint(rune(v.b[i])) {\n\t\t\tx.WriteRune(rune(v.b[i]))\n\t\t} else {\n\t\t\tx.WriteRune('.')\n\t\t}\n\t}\n\treturn baseStyle.Render(s + x.String())\n}", "func (ctx *RecordContext) Render(v interface{}) error {\n\tctx.Renders = append(ctx.Renders, v)\n\treturn ctx.Context.Render(v)\n}", "func (sh *ShaderStd) PostRender() error { return nil }", "func (c *stackComponent) Render(out io.Writer) (numLines int, err error) {\n\tc.mu.Lock()\n\tdefer c.mu.Unlock()\n\n\treturn renderComponents(out, c.resources)\n}", "func (h Hand) Render() string {\n\tbuffer := bytes.Buffer{}\n\tlast := len(h.Cards) - 1\n\tfor i, card := range h.Cards {\n\t\tbuffer.WriteString(card.Render())\n\t\tif i != last {\n\t\t\tbuffer.WriteString(\", \")\n\t\t}\n\t}\n\tbuffer.WriteString(fmt.Sprintf(\n\t\t\" (%s)\", scoresRenderer{h.Scores()}.Render(),\n\t))\n\treturn strings.Trim(buffer.String(), \" \")\n}", "func (e *tag) fastRender(w io.Writer, tag string, children []Element) (int, error) {\n\tif len(e.childData) == 0 {\n\t\t// Record the rendering into child data.\n\t\tbuf := new(bytes.Buffer)\n\t\t_, err := e.renderElement(buf, tag, children)\n\t\tif err != nil {\n\t\t\treturn 0, err\n\t\t}\n\t\te.childData = buf.Bytes()\n\t}\n\tn, err := w.Write(e.childData)\n\treturn n, err\n}", "func (c *Canvas) Count() int {\n\treturn len(c.paint)\n}", "func Render(r *sdl.Renderer, w *World) {\n\twidth := float64(r.GetViewport().W)\n\theight := float64(r.GetViewport().H)\n\n\trenderedVertices := [][2]int{}\n\n\tfor _, obj := range w.Objects {\n\t\tfor _, vertex := range obj.Geometry.Vertices {\n\t\t\trenderCoordinates := AsRelativeToSystem(w.ActiveCamera.ObjSys, ToSystem(obj.ObjSys, vertex.Pos))\n\n\t\t\tZ := Clamp(renderCoordinates.Z, 0.0001, math.NaN())\n\t\t\tratio := w.ActiveCamera.FocalLength / math.Abs(Z)\n\t\t\trenderX := ratio * renderCoordinates.X\n\t\t\trenderY := ratio * renderCoordinates.Y\n\n\t\t\tnormX, normY := NormalizeScreen(\n\t\t\t\twidth,\n\t\t\t\theight,\n\t\t\t\trenderX,\n\t\t\t\trenderY,\n\t\t\t)\n\n\t\t\trasterX := int(math.Floor(normX*width) + width/2)\n\t\t\trasterY := int(math.Floor(normY*height) + height/2)\n\n\t\t\trenderedVertices = append(renderedVertices, [2]int{rasterX, rasterY})\n\n\t\t\tDrawCircle(r, rasterX, rasterY, 5)\n\t\t}\n\t\tfor _, edge := range obj.Geometry.Edges {\n\t\t\tif len(renderedVertices) > edge.From && len(renderedVertices) > edge.To {\n\t\t\t\tr.DrawLine(\n\t\t\t\t\tint32(renderedVertices[edge.From][0]),\n\t\t\t\t\tint32(renderedVertices[edge.From][1]),\n\t\t\t\t\tint32(renderedVertices[edge.To][0]),\n\t\t\t\t\tint32(renderedVertices[edge.To][1]),\n\t\t\t\t)\n\t\t\t}\n\t\t}\n\t}\n\n\tr.Present()\n}", "func (self *StraightLineTrack) Render(render chan Object) {\n\tfor _, val := range self.Childs() {\n\t\trender <- val\n\t}\n}", "func (t *TransparentShape) Render() string {\n\treturn fmt.Sprintf(\"%s has %f%% transparency\", t.Shape.Render(), math.Ceil(t.Transparency * 100.0))\n}", "func render(ctx Config, com Component, gfx *dot.Graph) *dot.Node {\n\n\timg := iconPath(ctx, com)\n\n\tif fc := strings.TrimSpace(com.FontColor); len(fc) == 0 {\n\t\tcom.FontColor = \"#000000ff\"\n\t}\n\n\tif imp := strings.TrimSpace(com.Impl); len(imp) == 0 {\n\t\tcom.Impl = \"&nbsp;\"\n\t}\n\n\tvar sb strings.Builder\n\tsb.WriteString(`<table border=\"0\" cellborder=\"0\">`)\n\tif ctx.showImpl {\n\t\tfmt.Fprintf(&sb, `<tr><td><font point-size=\"8\">%s</font></td></tr>`, com.Impl)\n\t}\n\n\tsb.WriteString(\"<tr>\")\n\tfmt.Fprintf(&sb, `<td fixedsize=\"true\" width=\"50\" height=\"50\"><img src=\"%s\" /></td>`, img)\n\tsb.WriteString(\"</tr>\")\n\n\tlabel := \"&nbsp;\"\n\tif s := strings.TrimSpace(com.Label); len(s) > 0 {\n\t\tlabel = s\n\t}\n\tfmt.Fprintf(&sb, `<tr><td><font point-size=\"7\">%s</font></td></tr>`, label)\n\tsb.WriteString(\"</table>\")\n\n\treturn node.New(gfx, com.ID,\n\t\tnode.Label(sb.String(), true),\n\t\tnode.FillColor(\"transparent\"),\n\t\tnode.Shape(\"plain\"),\n\t)\n}", "func (level *Level) Render() string {\n\tresult := \"\"\n\n\tfor y := 0; y < level.size.Width; y++ {\n\t\tfor x := 0; x < level.size.Width; x++ {\n\t\t\tif level.snake.CheckHitbox(Position{x, y}) {\n\t\t\t\tresult += \"\\033[42m \\033[0m\"\n\t\t\t} else if level.apple.position.Equals(x, y) {\n\t\t\t\tresult += \"\\033[41m \\033[0m\"\n\t\t\t} else {\n\t\t\t\tresult += \"\\033[97m \\033[0m\"\n\t\t\t}\n\t\t}\n\n\t\tif y < level.size.Height-1 {\n\t\t\tresult += \"\\n\"\n\t\t}\n\t}\n\n\treturn result\n}", "func render(m diag.Message, colorize bool) string {\n\treturn fmt.Sprintf(\"%s%v%s [%v]%s %s\",\n\t\tcolorPrefix(m, colorize), m.Type.Level(), colorSuffix(colorize),\n\t\tm.Type.Code(), m.Origin(), fmt.Sprintf(m.Type.Template(), m.Parameters...),\n\t)\n}", "func Render(tag Tagger) string {\n return tag.Render()\n}", "func (f Frame) Render() string {\n\tsb := strings.Builder{}\n\tfor _, row := range f {\n\t\tfor _, shade := range row {\n\t\t\tsb.WriteString(fmt.Sprintf(\"%d\", shade))\n\t\t}\n\t\tsb.WriteString(\"\\n\")\n\t}\n\tsb.WriteString(\"==============================\\n\")\n\n\treturn sb.String()\n}", "func (d Deck) Render() string {\n\treturn fmt.Sprintf(\"🂠 ×%d\", len(d.Cards))\n}", "func _EvtRender(\n\tcontext EvtHandle,\n\tfragment EvtHandle,\n\tflags EvtRenderFlag,\n\tbufferSize uint32,\n\tbuffer *byte,\n\tbufferUsed *uint32,\n\tpropertyCount *uint32,\n) error {\n\tr1, _, e1 := syscall.SyscallN(\n\t\tprocEvtRender.Addr(),\n\t\tuintptr(context),\n\t\tuintptr(fragment),\n\t\tuintptr(flags),\n\t\tuintptr(bufferSize),\n\t\tuintptr(unsafe.Pointer(buffer)), //nolint:gosec // G103: Valid use of unsafe call to pass buffer\n\t\tuintptr(unsafe.Pointer(bufferUsed)), //nolint:gosec // G103: Valid use of unsafe call to pass bufferUsed\n\t\tuintptr(unsafe.Pointer(propertyCount)), //nolint:gosec // G103: Valid use of unsafe call to pass propertyCount\n\t)\n\n\tvar err error\n\tif r1 == 0 {\n\t\tif e1 != 0 {\n\t\t\terr = errnoErr(e1)\n\t\t} else {\n\t\t\terr = syscall.EINVAL\n\t\t}\n\t}\n\treturn err\n}", "func Render(state string, branch_length float64, branch_width float64, phase_diff float64, phase_init float64, canvas_size int, img_path string) {\n\td := gg.NewContext(canvas_size, canvas_size)\n\td.SetRGB(205, 133, 63)\n\td.SetLineWidth(branch_width)\n\t// Create a stack of branch-off points |b_stack|. |b| always points to the top of the stack.\n\tvar b_stack []Branch\n\tvar b *Branch\n\tvar b_new Branch\n\t// Initialize the stack.\n\tb_stack = append(b_stack, Branch{phase_init, complex(float64(canvas_size)/2, float64(canvas_size))})\n\tb = &b_stack[len(b_stack)-1]\n\n\t// Interpret each character of the input string as a drawing action.\n\tfor idx, c := range state {\n\t\tif c == 'F' {\n\t\t\t// Move forward from |b| to |b_new| and draw a line.\n\t\t\tb_new = Forward(*b, branch_length)\n\t\t\td.DrawLine(real(b.xy), imag(b.xy), real(b_new.xy), imag(b_new.xy))\n\t\t\td.Stroke()\n\t\t\t*b = b_new\n\t\t\td.SavePNG(img_path + \"/\" + strconv.Itoa(idx) + \".png\")\n\t\t} else if c == 'G' {\n\t\t\t// Move forward without drawing anything.\n\t\t\tb_new = Forward(*b, branch_length)\n\t\t\t*b = b_new\n\t\t} else if c == '-' {\n\t\t\t// Turn left.\n\t\t\t*b = Turn(*b, -1*phase_diff)\n\t\t} else if c == '+' {\n\t\t\t// Turn right.\n\t\t\t*b = Turn(*b, phase_diff)\n\t\t} else if c == '[' {\n\t\t\t// Store the current branch state.\n\t\t\tb_save := *b\n\t\t\tb_stack = append(b_stack, b_save)\n\t\t\tb = &b_stack[len(b_stack)-1]\n\t\t} else if c == ']' {\n\t\t\t// Return to the last saved branch state.\n\t\t\tb_stack = b_stack[:len(b_stack)-1]\n\t\t\tb = &b_stack[len(b_stack)-1]\n\t\t}\n\t}\n\tfmt.Println(\"Saved images to: \" + img_path)\n}", "func (s *Square) Render() string {\n\treturn fmt.Sprintf(\"Square side %f\", s.Side)\n}", "func (tofu Tofu) Render(wr io.Writer, name string, obj interface{}) error {\n\tvar m data.Map\n\tif obj != nil {\n\t\tvar ok bool\n\t\tm, ok = data.New(obj).(data.Map)\n\t\tif !ok {\n\t\t\treturn fmt.Errorf(\"invalid data type. expected map/struct, got %T\", obj)\n\t\t}\n\t}\n\treturn tofu.NewRenderer(name).Execute(wr, m)\n}", "func (s *Spinner) Render() error {\n\tif len(s.frames) == 0 {\n\t\treturn errors.New(\"no frames available to to render\")\n\t}\n\n\ts.step = s.step % len(s.frames)\n\tpreviousLen := len(s.previousFrame)\n\ts.previousFrame = fmt.Sprintf(\"%s%s\", s.separator, s.frames[s.step])\n\tnewLen := len(s.previousFrame)\n\n\t// We need to clean the previous message\n\tif previousLen > newLen {\n\t\tr := previousLen - newLen\n\t\tsuffix := strings.Repeat(\" \", r)\n\t\ts.previousFrame = s.previousFrame + suffix\n\t}\n\n\tfmt.Fprint(s.Writer, s.previousFrame)\n\ts.step++\n\treturn nil\n}", "func DrawElements(mode Enum, count int, ty Enum, offset int) {\n\tgl.DrawElements(uint32(mode), int32(count), uint32(ty), gl.PtrOffset(offset))\n}", "func (this *Precedence) countTemplate(temp [][][]bool) (n int) {\n\tfor _, bench := range temp {\n\t\tfor _, row := range bench {\n\t\t\tfor _, v := range row {\n\t\t\t\tif v {\n\t\t\t\t\tn++\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\treturn\n}", "func (obj *Device) DrawPrimitive(\n\ttyp PRIMITIVETYPE,\n\tstartVertex uint,\n\tprimitiveCount uint,\n) Error {\n\tret, _, _ := syscall.Syscall6(\n\t\tobj.vtbl.DrawPrimitive,\n\t\t4,\n\t\tuintptr(unsafe.Pointer(obj)),\n\t\tuintptr(typ),\n\t\tuintptr(startVertex),\n\t\tuintptr(primitiveCount),\n\t\t0,\n\t\t0,\n\t)\n\treturn toErr(ret)\n}", "func (ob *Object) Render() {\n\tob.image.Draw(ob.x, ob.y, allegro.FLIP_NONE)\n}", "func (a *World) Render(p *pic.Pic) *World {\n\th, w := p.H, p.W\n\tfh, fw := float64(h), float64(w)\n\tcx := vec.New(fw*a.Ratio/fh, 0, 0)\n\tcy := vec.Mult(vec.Norm(vec.Cross(cx, a.Cam.Direct)), a.Ratio)\n\tsample := a.Sample / 4\n\tinv := 1.0 / float64(sample)\n\n\tfmt.Printf(\"w: %v, h: %v, sample: %v, actual sample: %v, thread: %v, cpu: %v\\n\", w, h, a.Sample, sample*4, a.Thread, a.Core)\n\tbar := pb.StartNew(h * w)\n\tbar.SetRefreshRate(1000 * time.Millisecond)\n\n\truntime.GOMAXPROCS(a.Core)\n\tch := make(chan renderData, a.Thread)\n\twg := sync.WaitGroup{}\n\twg.Add(a.Thread)\n\n\tfor tid := 0; tid < a.Thread; tid++ {\n\t\tgo func() {\n\t\t\tfor {\n\t\t\t\tdata, ok := <-ch\n\t\t\t\tif !ok {\n\t\t\t\t\twg.Done()\n\t\t\t\t\treturn\n\t\t\t\t}\n\t\t\t\tsum, x, y := data.sum, data.x, data.y\n\t\t\t\tfor sy := 0.0; sy < 2.0; sy++ {\n\t\t\t\t\tfor sx := 0.0; sx < 2.0; sx++ {\n\t\t\t\t\t\tc := vec.NewZero()\n\t\t\t\t\t\tfor sp := 0; sp < sample; sp++ {\n\t\t\t\t\t\t\tccx := vec.Mult(cx, ((sx+0.5+gend())/2.0+x)/fw-0.5)\n\t\t\t\t\t\t\tccy := vec.Mult(cy, ((sy+0.5+gend())/2.0+y)/fh-0.5)\n\t\t\t\t\t\t\td := vec.Add(vec.Add(ccx, ccy), a.Cam.Direct)\n\t\t\t\t\t\t\tr := ray.New(vec.Add(a.Cam.Origin, vec.Mult(d, 130)), vec.Norm(d))\n\t\t\t\t\t\t\tc.Add(vec.Mult(a.trace(r, 0), inv))\n\t\t\t\t\t\t}\n\t\t\t\t\t\tsum.Add(vec.Mult(vec.New(pic.Clamp(c.X), pic.Clamp(c.Y), pic.Clamp(c.Z)), 0.25))\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tbar.Add(1)\n\t\t\t}\n\t\t}()\n\t}\n\n\tfor y := 0; y < h; y++ {\n\t\tfor x := 0; x < w; x++ {\n\t\t\tch <- renderData{\n\t\t\t\tsum: &p.C[(h-y-1)*w+x],\n\t\t\t\tx: float64(x),\n\t\t\t\ty: float64(y),\n\t\t\t}\n\t\t}\n\t}\n\n\tclose(ch)\n\twg.Wait()\n\n\tbar.FinishPrint(\"Rendering completed\")\n\treturn a\n}", "func (T triangle) shouldrender() (float64,float64,float64,float64){\n\treturn (T.p0.x*T.p0.x+T.p0.y*T.p0.y-T.size)/(T.p0.z*T.p0.z),T.p0.z,T.p0dotn/T.p0.Abs()/T.n.Abs(),T.size\n}", "func makeRenderablePoly(name string, n int, drawType uint, color vec4) *Renderable {\n\t// build poly verts\n\tvertex := makePoly(n)\n\tr := &Renderable{\n\t\tworld.Transform(),\n\t\tworld.Operation(name, &world.Poly{Points: vertex}),\n\t\tworld.MaterialComponent{\n\t\t\tDrawType: drawType,\n\t\t\tProps: map[string]interface{}{\n\t\t\t\t\"color\": world.Color(color),\n\t\t\t},\n\t\t},\n\t}\n\n\treturn r\n}", "func (o *FactoryContainer) CountOutput() float64 {\n\tvar output float64 = 0.0\n\tfor i, _ := range o.Factories {\n\t\toutput = output + o.Factories[i].Production*o.Factories[i].ProductionModifier\n\t}\n\treturn output\n}", "func (td TextDisplay)DrawLives(lives int, screen *ebiten.Image){\r\n\tlife := strconv.Itoa(lives)\r\n\ttext.Draw(screen, life, td.mplusNormalFont,10,30,color.White)\r\n}", "func (ctx *APIContext) Render(status int, title string, obj interface{}) {\n\tctx.JSON(status, map[string]interface{}{\n\t\t\"message\": title,\n\t\t\"status\": status,\n\t\t\"resource\": obj,\n\t})\n}", "func (pp *PostProcessor) Render(time float32) {\n\t// Set uniforms/options\n\tpp.shader.Use()\n\tpp.shader.SetFloat(\"time\", time, false)\n\tpp.shader.SetInteger(\"confuse\", boolToInt32(pp.confuse), false)\n\tpp.shader.SetInteger(\"chaos\", boolToInt32(pp.chaos), false)\n\tpp.shader.SetInteger(\"shake\", boolToInt32(pp.shake), false)\n\t// Render textured quad\n\tgl.ActiveTexture(gl.TEXTURE0)\n\tpp.texture.Bind()\n\tgl.BindVertexArray(pp.quadVao)\n\tgl.DrawArrays(gl.TRIANGLES, 0, 6)\n\tgl.BindVertexArray(0)\n}", "func defaultRender(w io.Writer, c *Component) error {\n\t_, err := w.Write([]byte(fmt.Sprintf(\"%+v\", c.State)))\n\treturn err\n}", "func createStat(votes *Vote) string {\n\n\tstats := NewStatistics(votes)\n\n\tstr := \"Total: \" + strconv.Itoa(stats.Total) + \"\\n\"\n\tfor value, users := range stats.Transformed {\n\t\tstr += value + \" (\" + strconv.Itoa(len(users)) + \"): \" + strings.Join(users, \", \") + \"\\n\"\n\t}\n\n\treturn str\n\n}", "func (t *TextRenderer) Print(text string, x, y float32, scale float32) error {\n\tindices := []rune(text)\n\tif len(indices) == 0 {\n\t\treturn nil\n\t}\n\tt.shader.Use()\n\n\tlowChar := rune(32)\n\n\tgl.ActiveTexture(gl.TEXTURE0)\n\tgl.BindVertexArray(t.vao)\n\n\tfor i := range indices {\n\t\truneIndex := indices[i]\n\n\t\tif int(runeIndex)-int(lowChar) > len(t.fontChar) || runeIndex < lowChar {\n\t\t\tcontinue\n\t\t}\n\n\t\tch := t.fontChar[runeIndex-lowChar]\n\n\t\txpos := x + float32(ch.bearingH)*scale\n\t\typos := y - float32(ch.height-ch.bearingV)*scale\n\t\tw := float32(ch.width) * scale\n\t\th := float32(ch.height) * scale\n\n\t\tvar vertices = []float32{\n\t\t\txpos, ypos + h, 0.0, 1.0,\n\t\t\txpos + w, ypos, 1.0, 0.0,\n\t\t\txpos, ypos, 0.0, 0.0,\n\t\t\txpos, ypos + h, 0.0, 1.0,\n\t\t\txpos + w, ypos + h, 1.0, 1.0,\n\t\t\txpos + w, ypos, 1.0, 0.0,\n\t\t}\n\n\t\tgl.BindTexture(gl.TEXTURE_2D, ch.textureID)\n\t\tgl.BindBuffer(gl.ARRAY_BUFFER, t.vbo)\n\t\tgl.BufferSubData(gl.ARRAY_BUFFER, 0, len(vertices)*4, gl.Ptr(vertices))\n\n\t\tgl.BindBuffer(gl.ARRAY_BUFFER, 0)\n\t\tgl.DrawArrays(gl.TRIANGLES, 0, 6)\n\n\t\tx += float32(ch.advance>>6) * scale\n\t}\n\tgl.BindVertexArray(0)\n\tgl.BindTexture(gl.TEXTURE_2D, 0)\n\tgl.UseProgram(0)\n\treturn nil\n}", "func (mm *massivemonster) render() {\n\n\trenderOutput(\"Massive Monster\", \"h1\", \"red\")\n\trenderOutput(mm.mmType, \"\", \"clear\")\n\trenderOutput(\"Class: \"+strconv.Itoa(mm.class), \"\", \"clear\")\n\trenderOutput(\"Motivation: \"+mm.motivation, \"\", \"clear\")\n\n\trenderOutput(\"Abilities\", \"h2\", \"clear\")\n\tif len(mm.abilities) > 0 {\n\t\tfor i := 0; i < len(mm.abilities); i++ {\n\t\t\trenderOutput(mm.abilities[i], \"listitem\", \"blue\")\n\t\t}\n\t}\n\n\trenderOutput(\"Natures\", \"h2\", \"clear\")\n\tif len(mm.natures) > 0 {\n\t\tfor i := 0; i < len(mm.natures); i++ {\n\t\t\trenderOutput(mm.natures[i], \"listitem\", \"green\")\n\t\t}\n\t}\n\trenderOutput(\"Weak Spot: \"+mm.weakSpot, \"\", \"yellow\")\n\trenderOutput(\"Incursion Zone Effect\", \"h2\", \"purple\")\n\trenderOutput(mm.zEffect, \"listitem\", \"clear\")\n\n}", "func TransformFeedbackVaryings(program uint32, count int32, varyings **uint8, bufferMode uint32) {\n\tC.glowTransformFeedbackVaryings(gpTransformFeedbackVaryings, (C.GLuint)(program), (C.GLsizei)(count), (**C.GLchar)(unsafe.Pointer(varyings)), (C.GLenum)(bufferMode))\n}", "func TransformFeedbackVaryings(program uint32, count int32, varyings **uint8, bufferMode uint32) {\n\tC.glowTransformFeedbackVaryings(gpTransformFeedbackVaryings, (C.GLuint)(program), (C.GLsizei)(count), (**C.GLchar)(unsafe.Pointer(varyings)), (C.GLenum)(bufferMode))\n}", "func (self *Graphics) Tint() int{\n return self.Object.Get(\"tint\").Int()\n}", "func (b *renderSystem) Render(dt float64) {\n\n\tb.renderer.Clear()\n\n\tfor i := 0; i < 100; i++ {\n\t\tl := b.layers[i]\n\t\tif l != nil {\n\t\t\tfor _, renderable := range *l {\n\t\t\t\trenderable.Paint(b.renderer)\n\t\t\t}\n\t\t}\n\t}\n\n\tb.renderer.Present()\n}", "func DrawN(count int, opts ...options) (result []string, err error) {\n\tif count <= 0 {\n\t\tcount = 1\n\t}\n\n\tfor i := 0; i < count; i++ {\n\t\toutput, err := Draw(opts...)\n\t\tif err != nil {\n\t\t\treturn nil, err\n\t\t}\n\t\tresult = append(result, output)\n\t}\n\n\treturn\n}", "func (h *HAProxyManager) render(ports []uint16) ([]byte, error) {\n\n\t// prepare the context\n\td := make([]templateContext, len(ports))\n\tfor i, port := range ports {\n\t\tif i == len(h.serviceAddrs) {\n\t\t\th.logger.Warnf(\"got port index %d, but only have %d service addrs. ports=%v serviceAddrs=%v\", i, len(h.serviceAddrs), ports, h.serviceAddrs)\n\t\t\tcontinue\n\t\t}\n\t\td[i] = templateContext{Port: port, Source: h.listenAddr, Dest: h.serviceAddrs[i]}\n\t}\n\n\t// render the template\n\tbuf := &bytes.Buffer{}\n\tif err := h.template.Execute(buf, d); err != nil {\n\t\treturn nil, err\n\t}\n\treturn buf.Bytes(), nil\n}", "func (gl *WebGL) DrawElements(mode GLEnum, count int, valueType GLEnum, offset int) {\n\tgl.context.Call(\"drawElements\", mode, count, valueType, offset)\n}", "func (c *ecsServiceResourceComponent) Render(out io.Writer) (numLines int, err error) {\n\tc.mu.Lock()\n\tdefer c.mu.Unlock()\n\n\tbuf := new(bytes.Buffer)\n\n\tnl, err := c.resourceRenderer.Render(buf)\n\tif err != nil {\n\t\treturn 0, err\n\t}\n\tnumLines += nl\n\n\tvar deploymentRenderer Renderer = &noopComponent{}\n\tif c.deploymentRenderer != nil {\n\t\tdeploymentRenderer = c.deploymentRenderer\n\t}\n\n\tsw := &suffixWriter{\n\t\tbuf: buf,\n\t\tsuffix: []byte{'\\t', '\\t'}, // Add two columns to the deployment renderer so that it aligns with resources.\n\t}\n\tnl, err = deploymentRenderer.Render(sw)\n\tif err != nil {\n\t\treturn 0, err\n\t}\n\tnumLines += nl\n\n\tif _, err = buf.WriteTo(out); err != nil {\n\t\treturn 0, err\n\t}\n\treturn numLines, nil\n}", "func (self *CircularTrack) Render(render chan Object) {\n\trender <- self\n\tfor _, val := range self.Childs() {\n\t\trender <- val\n\t}\n}", "func (r *renderer) Render(w io.Writer, m list.Model, index int, item list.Item) {\n\ti, ok := item.(candidateItem)\n\tif !ok {\n\t\treturn\n\t}\n\ts := i.Title()\n\tiw := rw.StringWidth(s)\n\tif iw < r.width {\n\t\ts += strings.Repeat(\" \", r.width-iw)\n\t}\n\tst := &r.m.Styles\n\tfn := st.Item.Render\n\tif r.m.selectedList == r.listIdx && index == m.Index() {\n\t\tfn = st.SelectedItem.Render\n\t}\n\tfmt.Fprint(w, fn(s))\n}", "func (renderer *SimpleMatrixRenderer) Render() {\n\trenderer.renderCharacter(\"\\n\")\n\n\tfor row := 0; row < renderer.Matrix.Height; row++ {\n\t\tfor col := 0; col < renderer.Matrix.Width; col++ {\n\t\t\tif !renderer.Matrix.IsFieldOccupied(row, col) {\n\t\t\t\trenderer.renderUnoccupiedField()\n\t\t\t} else {\n\t\t\t\trenderer.renderOccupiedFieldAtCurrentCursorPos(row, col)\n\t\t\t}\n\t\t}\n\n\t\trenderer.renderCharacter(\"\\n\")\n\t}\n\n\trenderer.renderCharacter(\"\\n\")\n}", "func DrawOutput(val int) {\n\tfmt.Printf(\"┌─────────┐\")\n\tfmt.Printf(\"\\n│%9d│\", val)\n\tfmt.Printf(\"\\n└─────────┘\\n\")\n}", "func (s Style) Render(raw string) string {\n\tt := NewAnstring(raw)\n\tfor i := len(s) - 1; i >= 0; i-- {\n\t\tt.meld(s[i])\n\t}\n\treturn string(t)\n}", "func (c *ColoredShape) Render() string {\n\treturn fmt.Sprintf(\"%s has the color %s\", c.Shape.Render(), c.Color)\n}", "func (t *tag) render() string {\n tagType := t.GetType()\n tagFormat := tagsFormat[tagType]\n\n switch t.GetType() {\n case TYPE_OPEN:\n return fmt.Sprintf(tagFormat, t.GetName(), getAttrsToString(t))\n case TYPE_CLOSE:\n return fmt.Sprintf(tagFormat, t.GetName())\n case TYPE_OPEN_CLOSE:\n return fmt.Sprintf(tagFormat, t.GetName(), getAttrsToString(t), t.GetVal(), t.GetName())\n case TYPE_SELF_CLOSED_STRICT:\n if t.GetVal() != \"\" {\n t.SetAttr(\"value\", t.GetVal())\n }\n return fmt.Sprintf(tagFormat, t.GetName(), getAttrsToString(t))\n default:\n return t.GetName()\n }\n}", "func GenderSpout(tuple []interface{}, result *[]interface{}, variables *[]interface{}) error {\n\t// Variables\n\tvar counterMap map[string]interface{}\n\tvar idArray interface{}\n\tvar genderArray interface{}\n\n\tif (len(*variables) == 0) {\n\t\tcounterMap = make(map[string]interface{})\n\t\t*variables = append(*variables, counterMap)\n\t\tcounterMap[\"counter\"] = float64(0)\n\n\t\tfile, _ := os.Open(\"data.json\")\n\t\tdefer file.Close()\n\n\t\tb, _ := ioutil.ReadAll(file)\n\t\tvar object interface{}\n\t\tjson.Unmarshal(b, &object)\n\t\tobjectMap := object.(map[string]interface{})\n\t\tidArray = objectMap[\"id\"].([]interface{})\n\t\tgenderArray = objectMap[\"gender\"].([]interface{})\n\n\t\t*variables = append(*variables, idArray)\n\t\t*variables = append(*variables, genderArray)\n\t}\n\tcounterMap = (*variables)[0].(map[string]interface{})\n\tidArray = (*variables)[1]\n\tgenderArray = (*variables)[2]\n\n\t// Logic\n\tif counterMap[\"counter\"].(float64) < 1000 {\n\t\t*result = []interface{}{idArray.([]interface{})[int(counterMap[\"counter\"].(float64))], genderArray.([]interface{})[int(counterMap[\"counter\"].(float64))]}\n\t\tcounterMap[\"counter\"] = counterMap[\"counter\"].(float64) + 1\n\t}\n\n\t// // Logic\n\t// if counterMap[\"counter\"].(float64) < 10 {\n\t// \tif int(counterMap[\"counter\"].(float64)) % 2 == 0 {\n\t// \t\t*result = []interface{}{strconv.Itoa(int(counterMap[\"counter\"].(float64))), \"male\"}\n\t// \t} else {\n\t// \t\t*result = []interface{}{strconv.Itoa(int(counterMap[\"counter\"].(float64))), \"female\"}\n\t// \t}\n\t// \tcounterMap[\"counter\"] = counterMap[\"counter\"].(float64) + 1\n\t// }\n\n\ttime.Sleep(1 * time.Millisecond)\n\n\t// Return value\n\tif (len(*result) > 0) {\n\t\tlog.Printf(\"Gender Spout Emit (%v)\\n\", *result)\n\t\treturn nil\n\t} else {\n\t\treturn errors.New(\"next tuple is nil\")\n\t}\n}", "func (self *Graphics) RenderOrderID() int{\n return self.Object.Get(\"renderOrderID\").Int()\n}", "func (v *View) Renderer(matcher func(instance.Description) bool) (func(w io.Writer, v interface{}) error, error) {\n\ttagsView, err := template.NewTemplate(template.ValidURL(v.tagsTemplate), v.options)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\tpropertiesView, err := template.NewTemplate(template.ValidURL(v.propertiesTemplate), v.options)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\n\treturn func(w io.Writer, result interface{}) error {\n\n\t\tinstances, is := result.([]instance.Description)\n\t\tif !is {\n\t\t\treturn fmt.Errorf(\"not []instance.Description\")\n\t\t}\n\n\t\tif !v.quiet {\n\t\t\tif v.viewTemplate != \"\" {\n\t\t\t\tfmt.Printf(\"%-30s\\t%-30s\\n\", \"ID\", \"VIEW\")\n\t\t\t} else if v.properties {\n\t\t\t\tfmt.Printf(\"%-30s\\t%-30s\\t%-30s\\t%-s\\n\", \"ID\", \"LOGICAL\", \"TAGS\", \"PROPERTIES\")\n\n\t\t\t} else {\n\t\t\t\tfmt.Printf(\"%-30s\\t%-30s\\t%-s\\n\", \"ID\", \"LOGICAL\", \"TAGS\")\n\t\t\t}\n\t\t}\n\t\tfor _, d := range instances {\n\n\t\t\t// TODO - filter on the client side by tags\n\t\t\tif len(v.TagFilter()) > 0 {\n\t\t\t\tif hasDifferentTag(v.TagFilter(), d.Tags) {\n\t\t\t\t\tcontinue\n\t\t\t\t}\n\t\t\t}\n\t\t\tif matcher != nil {\n\t\t\t\tif !matcher(d) {\n\t\t\t\t\tcontinue\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tlogical := \" - \"\n\t\t\tif d.LogicalID != nil {\n\t\t\t\tlogical = string(*d.LogicalID)\n\t\t\t}\n\n\t\t\tif v.viewTemplate != \"\" {\n\n\t\t\t\tcolumn := \"-\"\n\t\t\t\tif view, err := d.View(v.viewTemplate); err == nil {\n\t\t\t\t\tcolumn = view\n\t\t\t\t} else {\n\t\t\t\t\tcolumn = err.Error()\n\t\t\t\t}\n\t\t\t\tfmt.Printf(\"%-30s\\t%-30s\\n\", d.ID, column)\n\n\t\t\t} else {\n\n\t\t\t\ttagViewBuff := \"\"\n\t\t\t\tif v.tagsTemplate == \"*\" {\n\t\t\t\t\t// default -- this is a hack\n\t\t\t\t\tprintTags := []string{}\n\t\t\t\t\tfor k, v := range d.Tags {\n\t\t\t\t\t\tprintTags = append(printTags, fmt.Sprintf(\"%s=%s\", k, v))\n\t\t\t\t\t}\n\t\t\t\t\tsort.Strings(printTags)\n\t\t\t\t\ttagViewBuff = strings.Join(printTags, \",\")\n\t\t\t\t} else {\n\t\t\t\t\ttagViewBuff = renderTags(d.Tags, tagsView)\n\t\t\t\t}\n\n\t\t\t\tif v.properties {\n\n\t\t\t\t\tif v.quiet {\n\t\t\t\t\t\t// special render only the properties\n\t\t\t\t\t\tfmt.Printf(\"%s\", renderProperties(d.Properties, propertiesView))\n\t\t\t\t\t} else {\n\t\t\t\t\t\tfmt.Printf(\"%-30s\\t%-30s\\t%-30s\\t%-s\\n\", d.ID, logical, tagViewBuff,\n\t\t\t\t\t\t\trenderProperties(d.Properties, propertiesView))\n\t\t\t\t\t}\n\t\t\t\t} else {\n\t\t\t\t\tfmt.Printf(\"%-30s\\t%-30s\\t%-s\\n\", d.ID, logical, tagViewBuff)\n\t\t\t\t}\n\n\t\t\t}\n\t\t}\n\t\treturn nil\n\t}, nil\n}", "func (c *stackSetComponent) Render(out io.Writer) (int, error) {\n\tc.mu.Lock()\n\tdefer c.mu.Unlock()\n\n\tcomponents := cfnLineItemComponents(c.title, c.separator, c.statuses, c.stopWatch, c.style.Padding)\n\treturn renderComponents(out, components)\n}", "func ExampleRender() {\n\tconst s = `\n\tFirst Line\n\tSecond Line\n\tThird Line\n\tHello\n\tThis is go-music`\n\n\tfmt.Println(RenderText(s, Spring))\n\tfmt.Println(RenderText(s, Autumn))\n\tfmt.Println(RenderText(s, Winter))\n\tfmt.Println(RenderText(s, Rose))\n\tfmt.Println(RenderText(s, Valentine))\n}", "func (f *Font) CreateTextAdv(pos mgl.Vec3, color mgl.Vec4, maxWidth float32, charOffset int, cursorPosition int, msg string) TextRenderData {\n\t// this is the texture ID of the font to use in the shader; by default\n\t// the library always binds the font to the first texture sampler.\n\tconst floatTexturePosition = 0.0\n\n\t// sanity checks\n\toriginalLen := len(msg)\n\ttrimmedMsg := msg\n\tif originalLen == 0 {\n\t\treturn TextRenderData{\n\t\t\tComboBuffer: nil,\n\t\t\tIndexBuffer: nil,\n\t\t\tFaces: 0,\n\t\t\tWidth: 0.0,\n\t\t\tHeight: 0.0,\n\t\t\tAdvanceHeight: 0.0,\n\t\t\tCursorOverflowRight: false,\n\t\t}\n\t}\n\tif charOffset > 0 && charOffset < originalLen {\n\t\t// trim the string based on incoming character offset\n\t\ttrimmedMsg = trimmedMsg[charOffset:]\n\t}\n\n\t// get the length of our message\n\tmsgLength := len(trimmedMsg)\n\n\t// create the arrays to hold the data to buffer to OpenGL\n\tcomboBuffer := make([]float32, 0, msgLength*(2+2+4)*4) // pos, uv, color4\n\tindexBuffer := make([]uint32, 0, msgLength*6) // two faces * three indexes\n\n\t// do a preliminary test to see how much room the message will take up\n\tdimX, dimY, advH := f.GetRenderSize(trimmedMsg)\n\n\t// see how much to scale the size based on current resolution vs desgin resolution\n\tfontScale := f.GetCurrentScale()\n\n\t// loop through the message\n\tvar totalChars = 0\n\tvar scaledSize float32 = 0.0\n\tvar cursorOverflowRight bool\n\tvar penX = pos[0]\n\tvar penY = pos[1] - float32(advH)\n\tfor chi, ch := range trimmedMsg {\n\t\t// get the rune data\n\t\tchData := f.locations[ch]\n\n\t\t/*\n\t\t\tbounds, _, _ := f.face.GlyphBounds(ch)\n\t\t\tglyphD := bounds.Max.Sub(bounds.Min)\n\t\t\tglyphAdvW, _ := f.face.GlyphAdvance(ch)\n\t\t\tmetrics := f.face.Metrics()\n\t\t\tglyphAdvH := float32(metrics.Ascent.Round())\n\n\t\t\tglyphH := float32(glyphD.Y.Round())\n\t\t\tglyphW := float32(glyphD.X.Round())\n\t\t\tadvHeight := glyphAdvH\n\t\t\tadvWidth := float32(glyphAdvW.Round())\n\t\t*/\n\n\t\tglyphH := f.GlyphHeight\n\t\tglyphW := f.GlyphWidth\n\t\tadvHeight := chData.advanceHeight\n\t\tadvWidth := chData.advanceWidth\n\n\t\t// possibly stop here if we're going to overflow the max width\n\t\tif maxWidth > 0.0 && scaledSize+(advWidth*fontScale) > maxWidth {\n\t\t\t// we overflowed the size of the string, now check to see if\n\t\t\t// the cursor position is covered within this string or if that hasn't\n\t\t\t// been reached yet.\n\t\t\tif cursorPosition >= 0 && cursorPosition-charOffset > chi {\n\t\t\t\tcursorOverflowRight = true\n\t\t\t}\n\n\t\t\t// adjust the dimX here since we shortened the string\n\t\t\tdimX = scaledSize\n\t\t\tbreak\n\t\t}\n\t\tscaledSize += advWidth * fontScale\n\n\t\t// setup the coordinates for ther vetexes\n\t\tx0 := penX\n\t\ty0 := penY - (glyphH-advHeight)*fontScale\n\t\tx1 := x0 + glyphW*fontScale\n\t\ty1 := y0 + glyphH*fontScale\n\t\ts0 := chData.uvMinX\n\t\tt0 := chData.uvMinY\n\t\ts1 := chData.uvMaxX\n\t\tt1 := chData.uvMaxY\n\n\t\t// set the vertex data\n\t\tcomboBuffer = append(comboBuffer, x1)\n\t\tcomboBuffer = append(comboBuffer, y0)\n\t\tcomboBuffer = append(comboBuffer, s1)\n\t\tcomboBuffer = append(comboBuffer, t0)\n\t\tcomboBuffer = append(comboBuffer, floatTexturePosition)\n\t\tcomboBuffer = append(comboBuffer, color[:]...)\n\n\t\tcomboBuffer = append(comboBuffer, x1)\n\t\tcomboBuffer = append(comboBuffer, y1)\n\t\tcomboBuffer = append(comboBuffer, s1)\n\t\tcomboBuffer = append(comboBuffer, t1)\n\t\tcomboBuffer = append(comboBuffer, floatTexturePosition)\n\t\tcomboBuffer = append(comboBuffer, color[:]...)\n\n\t\tcomboBuffer = append(comboBuffer, x0)\n\t\tcomboBuffer = append(comboBuffer, y1)\n\t\tcomboBuffer = append(comboBuffer, s0)\n\t\tcomboBuffer = append(comboBuffer, t1)\n\t\tcomboBuffer = append(comboBuffer, floatTexturePosition)\n\t\tcomboBuffer = append(comboBuffer, color[:]...)\n\n\t\tcomboBuffer = append(comboBuffer, x0)\n\t\tcomboBuffer = append(comboBuffer, y0)\n\t\tcomboBuffer = append(comboBuffer, s0)\n\t\tcomboBuffer = append(comboBuffer, t0)\n\t\tcomboBuffer = append(comboBuffer, floatTexturePosition)\n\t\tcomboBuffer = append(comboBuffer, color[:]...)\n\n\t\tstartIndex := uint32(chi) * 4\n\t\tindexBuffer = append(indexBuffer, startIndex)\n\t\tindexBuffer = append(indexBuffer, startIndex+1)\n\t\tindexBuffer = append(indexBuffer, startIndex+2)\n\n\t\tindexBuffer = append(indexBuffer, startIndex+2)\n\t\tindexBuffer = append(indexBuffer, startIndex+3)\n\t\tindexBuffer = append(indexBuffer, startIndex)\n\n\t\t// advance the pen\n\t\tpenX += advWidth * fontScale\n\t\ttotalChars++\n\t}\n\n\treturn TextRenderData{\n\t\tComboBuffer: comboBuffer,\n\t\tIndexBuffer: indexBuffer,\n\t\tFaces: uint32(totalChars * 2),\n\t\tWidth: float32(dimX),\n\t\tHeight: float32(dimY),\n\t\tAdvanceHeight: float32(advH),\n\t\tCursorOverflowRight: cursorOverflowRight,\n\t}\n}", "func (Empty) Render(width, height int) *term.Buffer {\n\treturn term.NewBufferBuilder(width).Buffer()\n}", "func (c *ConnectionSPI) Render(pixels []RGBPixel) {\r\n\tlogFields := log.Fields{\"package\": logPkg, \"conn\": \"SPI\", \"func\": \"RenderLEDs\"}\r\n\tlog.WithFields(logFields).Infof(\"Render %d LEDs\", len(pixels))\r\n\t// Fix for Raspberry Pi 3 Model B+ (5.15.84-v7+)\r\n\t// Data signal seems to be splitted sending less than 11 LEDS\r\n\tif len(pixels) < 11 {\r\n\t\tpixels = append(pixels, []RGBPixel{{}, {}, {}, {}, {}, {}, {}, {}, {}, {}}...)\r\n\t}\r\n\tvar translatedRGBs []uint8\r\n\tfor _, pixel := range pixels {\r\n\r\n\t\tcolorData := GetColorData(pixel, c.FixSPI)\r\n\t\tlog.WithFields(logFields).Tracef(\"%08b\", pixel)\r\n\r\n\t\tfor _, c := range colorData {\r\n\t\t\ttranslatedRGBs = append(translatedRGBs, c)\r\n\t\t}\r\n\t}\r\n\r\n\tc.transfer(translatedRGBs)\r\n}", "func Render(colorCode int, fontSize int, content string) string {\n\treturn \"\\033[\" + strconv.Itoa(fontSize) + \";\" + strconv.Itoa(colorCode) + \"m\" + content + reset\n}", "func (t tag) Render() string {\n return t.render()\n}", "func (o GroupContainerGpuLimitOutput) Count() pulumi.IntPtrOutput {\n\treturn o.ApplyT(func(v GroupContainerGpuLimit) *int { return v.Count }).(pulumi.IntPtrOutput)\n}", "func (s *HelloSystem) Draw(ctx core.DrawCtx) {\n\tfor _, v := range s.V().Matches() {\n\t\tebitenutil.DebugPrintAt(ctx.Renderer().Screen(), v.Hello.Text, v.Hello.X, v.Hello.Y)\n\t}\n}", "func (self *GameObjectCreator) RenderTexture1O(width int) *RenderTexture{\n return &RenderTexture{self.Object.Call(\"renderTexture\", width)}\n}", "func NumberLamp(vs []val.Val) {\n\tfunc(vs []val.Val) {\n\t\tdraw := func(color, str string) {\n\t\t\tfmt.Print(colorstring.Color(\"[_\" + color + \"_]\" + str + \"[default]\"))\n\t\t}\n\t\tfor {\n\t\t\toff := \"black\"\n\t\t\ton := \"blue\"\n\t\t\tons := make([]string, 7)\n\t\t\tfor i := 0; i < 7; i++ {\n\t\t\t\tout := vs[i].Out()\n\t\t\t\tif out.IsNil() {\n\t\t\t\t\treturn\n\t\t\t\t}\n\t\t\t\tif out.Bool() {\n\t\t\t\t\tons[i] = on\n\t\t\t\t} else {\n\t\t\t\t\tons[i] = off\n\t\t\t\t}\n\t\t\t}\n\t\t\t//\t0\n\t\t\tdraw(off, \" \")\n\t\t\tdraw(ons[0], \" \")\n\t\t\tdraw(off, \" \")\n\t\t\tdraw(off, \"\\n\")\n\t\t\t//\t5 1\n\t\t\tdraw(ons[5], \" \")\n\t\t\tdraw(off, \" \")\n\t\t\tdraw(ons[1], \" \")\n\t\t\tdraw(off, \"\\n\")\n\t\t\tdraw(ons[5], \" \")\n\t\t\tdraw(off, \" \")\n\t\t\tdraw(ons[1], \" \")\n\t\t\tdraw(off, \"\\n\")\n\t\t\t//\t6\n\t\t\tdraw(off, \" \")\n\t\t\tdraw(ons[6], \" \")\n\t\t\tdraw(off, \" \")\n\t\t\tdraw(off, \"\\n\")\n\t\t\t//\t4 2\n\t\t\tdraw(ons[4], \" \")\n\t\t\tdraw(off, \" \")\n\t\t\tdraw(ons[2], \" \")\n\t\t\tdraw(off, \"\\n\")\n\t\t\tdraw(ons[4], \" \")\n\t\t\tdraw(off, \" \")\n\t\t\tdraw(ons[2], \" \")\n\t\t\tdraw(off, \"\\n\")\n\t\t\t//\t3\n\t\t\tdraw(off, \" \")\n\t\t\tdraw(ons[3], \" \")\n\t\t\tdraw(off, \" \")\n\t\t\tdraw(off, \"\\n\")\n\t\t\t//\tnew line\n\t\t\tdraw(off, \"\\n\")\n\t\t}\n\t}(vs)\n}", "func (a ArithmeticPage) Render(w http.ResponseWriter, req *http.Request) {\n\tRenderPage(a, w, req, true)\n}", "func DrawElements(mode uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n C.glowDrawElements(gpDrawElements, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices)\n}", "func (f *Factory) Counter(name string, tags map[string]string) metrics.Counter {\n\tcounter := &counter{\n\t\tcounters: make([]metrics.Counter, len(f.factories)),\n\t}\n\tfor i, factory := range f.factories {\n\t\tcounter.counters[i] = factory.Counter(name, tags)\n\t}\n\treturn counter\n}", "func mapCount(itr Iterator, m *mapper) {\n\tn := 0\n\tfor k, _ := itr.Next(); k != 0; k, _ = itr.Next() {\n\t\tn++\n\t}\n\tm.emit(itr.Time(), float64(n))\n}", "func (render *Renderer_impl)Unmap() fundations.Result{\n\n}", "func (cont *tuiApplicationController) drawView() {\n\tcont.Sync.Lock()\n\tif !cont.Changed || cont.TuiFileReaderWorker == nil {\n\t\tcont.Sync.Unlock()\n\t\treturn\n\t}\n\tcont.Sync.Unlock()\n\n\t// reset the elements by clearing out every one\n\ttviewApplication.QueueUpdateDraw(func() {\n\t\tfor _, t := range displayResults {\n\t\t\tt.Title.SetText(\"\")\n\t\t\tt.Body.SetText(\"\")\n\t\t\tt.SpacerOne.SetText(\"\")\n\t\t\tt.SpacerTwo.SetText(\"\")\n\t\t\tresultsFlex.ResizeItem(t.Body, 0, 0)\n\t\t}\n\t})\n\n\tcont.Sync.Lock()\n\tresultsCopy := make([]*FileJob, len(cont.Results))\n\tcopy(resultsCopy, cont.Results)\n\tcont.Sync.Unlock()\n\n\t// rank all results\n\t// then go and get the relevant portion for display\n\trankResults(int(cont.TuiFileReaderWorker.GetFileCount()), resultsCopy)\n\tdocumentTermFrequency := calculateDocumentTermFrequency(resultsCopy)\n\n\t// after ranking only get the details for as many as we actually need to\n\t// cut down on processing\n\tif len(resultsCopy) > len(displayResults) {\n\t\tresultsCopy = resultsCopy[:len(displayResults)]\n\t}\n\n\t// We use this to swap out the highlights after we escape to ensure that we don't escape\n\t// out own colours\n\tmd5Digest := md5.New()\n\tfmtBegin := hex.EncodeToString(md5Digest.Sum([]byte(fmt.Sprintf(\"begin_%d\", makeTimestampNano()))))\n\tfmtEnd := hex.EncodeToString(md5Digest.Sum([]byte(fmt.Sprintf(\"end_%d\", makeTimestampNano()))))\n\n\t// go and get the codeResults the user wants to see using selected as the offset to display from\n\tvar codeResults []codeResult\n\tfor i, res := range resultsCopy {\n\t\tif i >= cont.Offset {\n\t\t\tsnippets := extractRelevantV3(res, documentTermFrequency, int(SnippetLength), \"…\")[0]\n\n\t\t\t// now that we have the relevant portion we need to get just the bits related to highlight it correctly\n\t\t\t// which this method does. It takes in the snippet, we extract and all of the locations and then returns just\n\t\t\tl := getLocated(res, snippets)\n\t\t\tcoloredContent := str.HighlightString(snippets.Content, l, fmtBegin, fmtEnd)\n\t\t\tcoloredContent = tview.Escape(coloredContent)\n\n\t\t\tcoloredContent = strings.Replace(coloredContent, fmtBegin, \"[red]\", -1)\n\t\t\tcoloredContent = strings.Replace(coloredContent, fmtEnd, \"[white]\", -1)\n\n\t\t\tcodeResults = append(codeResults, codeResult{\n\t\t\t\tTitle: res.Location,\n\t\t\t\tContent: coloredContent,\n\t\t\t\tScore: res.Score,\n\t\t\t\tLocation: res.Location,\n\t\t\t})\n\t\t}\n\t}\n\n\t// render out what the user wants to see based on the results that have been chosen\n\ttviewApplication.QueueUpdateDraw(func() {\n\t\tfor i, t := range codeResults {\n\t\t\tdisplayResults[i].Title.SetText(fmt.Sprintf(\"[fuchsia]%s (%f)[-:-:-]\", t.Title, t.Score))\n\t\t\tdisplayResults[i].Body.SetText(t.Content)\n\t\t\tdisplayResults[i].Location = t.Location\n\n\t\t\t//we need to update the item so that it displays everything we have put in\n\t\t\tresultsFlex.ResizeItem(displayResults[i].Body, len(strings.Split(t.Content, \"\\n\")), 0)\n\t\t}\n\t})\n\n\t// we can only set that nothing\n\tcont.Changed = false\n}", "func Render(s api.Session, renderAs RenderName, value dgo.Value, out io.Writer) {\n\t// Convert value to rich data format without references\n\tdedupStream := func(value dgo.Value, consumer streamer.Consumer) {\n\t\topts := streamer.DefaultOptions()\n\t\topts.DedupLevel = streamer.NoDedup\n\t\tser := streamer.New(s.AliasMap(), opts)\n\t\tser.Stream(value, consumer)\n\t}\n\n\tswitch renderAs {\n\tcase JSON:\n\t\tif value.Equals(vf.Nil) {\n\t\t\tutil.WriteString(out, \"null\\n\")\n\t\t} else {\n\t\t\tdedupStream(value, streamer.JSON(out))\n\t\t\tutil.WriteByte(out, '\\n')\n\t\t}\n\n\tcase YAML:\n\t\tif value.Equals(vf.Nil) {\n\t\t\tutil.WriteString(out, \"\\n\")\n\t\t} else {\n\t\t\tdc := streamer.DataCollector()\n\t\t\tdedupStream(value, dc)\n\t\t\tbs, err := yaml.Marshal(dc.Value())\n\t\t\tif err != nil {\n\t\t\t\tpanic(err)\n\t\t\t}\n\t\t\tutil.WriteString(out, string(bs))\n\t\t}\n\tcase Binary:\n\t\tbi := vf.New(typ.Binary, value).(dgo.Binary)\n\t\t_, err := out.Write(bi.GoBytes())\n\t\tif err != nil {\n\t\t\tpanic(err)\n\t\t}\n\tcase Text:\n\t\tutil.Fprintln(out, value)\n\tdefault:\n\t\tpanic(fmt.Errorf(`unknown rendering '%s'`, renderAs))\n\t}\n}", "func (self *Tween) RepeatCounter() int{\n return self.Object.Get(\"repeatCounter\").Int()\n}", "func (x *Int) Text(base int) string {}", "func (ctx *Context) Render(bytes []byte) {\n\t//debug\n\t//fmt.Println(\"response msg = \", string(bytes))\n\tctx.Writer.WriteHeader(200)\n\t_, err := ctx.Writer.Write(bytes)\n\tif err != nil {\n\t\tpanic(err)\n\t}\n}", "func (t *Text) Render() *Text {\n\tt.RenderComponent.Drawable = common.Text{\n\t\tFont: t.Font,\n\t\tText: t.Text,\n\t}\n\n\tt.SpaceComponent = common.SpaceComponent{\n\t\tPosition: engo.Point{X: t.X, Y: t.Y},\n\t\tWidth: float32(t.Font.Size) * float32(len(t.Text)),\n\t\tHeight: float32(t.Font.Size),\n\t}\n\n\treturn t\n}", "func TestRender(t *testing.T) {\n\ttestCases := []struct {\n\t\tname string\n\t\tp P\n\t\twantList []string\n\t\twantCode int\n\t}{\n\t\t{\n\t\t\t\"server error\",\n\t\t\tServerError,\n\t\t\t[]string{\"500\"},\n\t\t\t500,\n\t\t}, {\n\t\t\t\"renders the type correctly\",\n\t\t\tP{Type: \"foo\", Status: 500},\n\t\t\t[]string{\"foo\"},\n\t\t\t500,\n\t\t}, {\n\t\t\t\"renders the status correctly\",\n\t\t\tP{Status: 201},\n\t\t\t[]string{\"201\"},\n\t\t\t201,\n\t\t}, {\n\t\t\t\"renders the extras correctly\",\n\t\t\tP{Extras: map[string]interface{}{\"hello\": \"stellar\"}, Status: 500},\n\t\t\t[]string{\"hello\", \"stellar\"},\n\t\t\t500,\n\t\t},\n\t}\n\n\tfor _, kase := range testCases {\n\t\tt.Run(kase.name, func(t *testing.T) {\n\t\t\tw := testRender(context.Background(), kase.p)\n\t\t\tfor _, wantItem := range kase.wantList {\n\t\t\t\tassert.True(t, strings.Contains(w.Body.String(), wantItem), w.Body.String())\n\t\t\t\tassert.Equal(t, kase.wantCode, w.Code)\n\t\t\t}\n\t\t})\n\t}\n}", "func (v *StackPanel) Render(rn Renderer) {\n\toff := 0\n\tfor _, child := range v.childs {\n\t\tif v.orientation == Vertical {\n\t\t\tif off >= v.height {\n\t\t\t\tbreak\n\t\t\t}\n\t\t\theight := v.heights[child]\n\t\t\trn.RenderChild(child, v.width, height, 0, off)\n\t\t\toff += height\n\t\t} else {\n\t\t\tif off >= v.width {\n\t\t\t\tbreak\n\t\t\t}\n\t\t\twidth := v.widths[child]\n\t\t\trn.RenderChild(child, width, v.height, off, 0)\n\t\t\toff += width\n\t\t}\n\t}\n}", "func (c *vertexCollection) Count(ctx context.Context) (int64, error) {\n\tresult, err := c.rawCollection().Count(ctx)\n\tif err != nil {\n\t\treturn 0, WithStack(err)\n\t}\n\treturn result, nil\n}", "func (obj *Device) DrawPrimitiveUP(\n\ttyp PRIMITIVETYPE,\n\tprimitiveCount uint,\n\tvertexStreamZeroData uintptr,\n\tvertexStreamZeroStride uint,\n) Error {\n\tret, _, _ := syscall.Syscall6(\n\t\tobj.vtbl.DrawPrimitiveUP,\n\t\t5,\n\t\tuintptr(unsafe.Pointer(obj)),\n\t\tuintptr(typ),\n\t\tuintptr(primitiveCount),\n\t\tvertexStreamZeroData,\n\t\tuintptr(vertexStreamZeroStride),\n\t\t0,\n\t)\n\treturn toErr(ret)\n}" ]
[ "0.5529045", "0.5277186", "0.52506244", "0.52506244", "0.5233859", "0.51651615", "0.5122963", "0.502615", "0.49615052", "0.4918426", "0.4897997", "0.48911527", "0.4891093", "0.48816442", "0.4871372", "0.48440495", "0.48364767", "0.4833455", "0.48106322", "0.47945023", "0.47796118", "0.47781917", "0.4776868", "0.4763102", "0.47587782", "0.47577655", "0.4753027", "0.4748081", "0.474565", "0.4708909", "0.47070056", "0.47055653", "0.4697648", "0.46968558", "0.46868807", "0.46708265", "0.46626472", "0.46321484", "0.4619594", "0.46148115", "0.461418", "0.4612741", "0.46066082", "0.46033615", "0.46013105", "0.45961446", "0.45953628", "0.45899203", "0.45757505", "0.45746726", "0.45715958", "0.45698974", "0.45636058", "0.45581532", "0.455771", "0.45571643", "0.4554404", "0.45485067", "0.45485067", "0.45399362", "0.45322302", "0.45234555", "0.45194513", "0.45192915", "0.45140833", "0.45083398", "0.4503474", "0.45019123", "0.44991985", "0.44960156", "0.44875616", "0.44859093", "0.4485211", "0.4484007", "0.44783774", "0.44769678", "0.4470628", "0.44633406", "0.4458448", "0.44458255", "0.44428185", "0.44427142", "0.44425166", "0.44385108", "0.44291705", "0.44255775", "0.44252822", "0.44220665", "0.44220522", "0.440643", "0.44050562", "0.43824401", "0.43712515", "0.4362738", "0.43626666", "0.4357553", "0.43496254", "0.4346778", "0.43431038", "0.4337384", "0.43357658" ]
0.0
-1
render multiple instances of primitives using a count derived from a transform feedback object
func DrawTransformFeedbackInstanced(mode uint32, id uint32, instancecount int32) { C.glowDrawTransformFeedbackInstanced(gpDrawTransformFeedbackInstanced, (C.GLenum)(mode), (C.GLuint)(id), (C.GLsizei)(instancecount)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func (r *Renderer) Render() {\n\tsx, sz, sy := r.c.Bounds()\n\tsxf := float64(sx - 1)\n\tsyf := float64(sy - 1)\n\tszf := float64(sz - 1)\n\tfor z := 0; z < sz; z++ {\n\t\tfor y := 0; y < sy; y++ {\n\t\t\tfor x := 0; x < sx; x++ {\n\t\t\t\tvar lr, lg, lb, _ uint32\n\t\t\t\tn := uint32(0)\n\t\t\t\tfor _, o := range r.objects {\n\t\t\t\t\tr, g, b, _ := o.At(float64(x)/sxf, float64(y)/syf, float64(z)/szf).RGBA()\n\t\t\t\t\tlr += r >> 8\n\t\t\t\t\tlg += g >> 8\n\t\t\t\t\tlb += b >> 8\n\t\t\t\t\tn++\n\t\t\t\t}\n\t\t\t\tr.c.Set(x, y, z, color.RGBA{uint8(lr/n), uint8(lg/n), uint8(lb/n), 255})\n\t\t\t}\n\t\t}\n\t}\n\tr.c.Render()\n}", "func (sr scoresRenderer) Render() string {\n\tbuffer := bytes.Buffer{}\n\tlast := len(sr.scores) - 1\n\tfor i, score := range sr.scores {\n\t\tbuffer.WriteString(fmt.Sprintf(\"%d\", score))\n\t\tif i != last {\n\t\t\tbuffer.WriteString(\" / \")\n\t\t}\n\t}\n\treturn buffer.String()\n}", "func (self *StraightLineTrack) Render(render chan Object) {\n\tfor _, val := range self.Childs() {\n\t\trender <- val\n\t}\n}", "func MultiDrawElements(mode uint32, count *int32, xtype uint32, indices *unsafe.Pointer, drawcount int32) {\n C.glowMultiDrawElements(gpMultiDrawElements, (C.GLenum)(mode), (*C.GLsizei)(unsafe.Pointer(count)), (C.GLenum)(xtype), indices, (C.GLsizei)(drawcount))\n}", "func (c *cartridge) Render() {\n\tc.Cls()\n\tc.PrintAt(fmt.Sprintf(\"counter:%d\", c.counter), c.x, c.y)\n}", "func Render(r *sdl.Renderer, w *World) {\n\twidth := float64(r.GetViewport().W)\n\theight := float64(r.GetViewport().H)\n\n\trenderedVertices := [][2]int{}\n\n\tfor _, obj := range w.Objects {\n\t\tfor _, vertex := range obj.Geometry.Vertices {\n\t\t\trenderCoordinates := AsRelativeToSystem(w.ActiveCamera.ObjSys, ToSystem(obj.ObjSys, vertex.Pos))\n\n\t\t\tZ := Clamp(renderCoordinates.Z, 0.0001, math.NaN())\n\t\t\tratio := w.ActiveCamera.FocalLength / math.Abs(Z)\n\t\t\trenderX := ratio * renderCoordinates.X\n\t\t\trenderY := ratio * renderCoordinates.Y\n\n\t\t\tnormX, normY := NormalizeScreen(\n\t\t\t\twidth,\n\t\t\t\theight,\n\t\t\t\trenderX,\n\t\t\t\trenderY,\n\t\t\t)\n\n\t\t\trasterX := int(math.Floor(normX*width) + width/2)\n\t\t\trasterY := int(math.Floor(normY*height) + height/2)\n\n\t\t\trenderedVertices = append(renderedVertices, [2]int{rasterX, rasterY})\n\n\t\t\tDrawCircle(r, rasterX, rasterY, 5)\n\t\t}\n\t\tfor _, edge := range obj.Geometry.Edges {\n\t\t\tif len(renderedVertices) > edge.From && len(renderedVertices) > edge.To {\n\t\t\t\tr.DrawLine(\n\t\t\t\t\tint32(renderedVertices[edge.From][0]),\n\t\t\t\t\tint32(renderedVertices[edge.From][1]),\n\t\t\t\t\tint32(renderedVertices[edge.To][0]),\n\t\t\t\t\tint32(renderedVertices[edge.To][1]),\n\t\t\t\t)\n\t\t\t}\n\t\t}\n\t}\n\n\tr.Present()\n}", "func DrawElements(mode Enum, count int, ty Enum, offset int) {\n\tgl.DrawElements(uint32(mode), int32(count), uint32(ty), gl.PtrOffset(offset))\n}", "func (p *Processor) Render() vdom.Element {\n\tmaxConnectors := p.ProcessorDefinition.MaxConnectors()\n\tprocName := p.ProcessorDefinition.Name\n\tprocDefName, procInputs, procOutputs, procParameters := p.ProcessorDefinition.Processor.Definition()\n\tif len(procName) == 0 {\n\t\tprocName = procDefName\n\t}\n\n\tprocWidth := procDefaultWidth\n\tprocHeight := (maxConnectors + 2 + len(procParameters)) * procConnWidth * 2\n\n\tcustomRenderDimentions, ok := p.ProcessorDefinition.Processor.(customRenderDimentions)\n\tif ok {\n\t\tprocWidth, procHeight = customRenderDimentions.CustomRenderDimentions()\n\t}\n\n\tprocNameLabel := vdom.MakeElement(\"text\",\n\t\t\"font-family\", \"sans-serif\",\n\t\t\"text-anchor\", \"middle\",\n\t\t\"alignment-baseline\", \"hanging\",\n\t\t\"font-size\", 10,\n\t\t\"x\", p.ProcessorDefinition.X+procWidth/2,\n\t\t\"y\", p.ProcessorDefinition.Y+4,\n\t\tvdom.MakeTextElement(procName),\n\t)\n\tprocLine := vdom.MakeElement(\"line\",\n\t\t\"stroke\", \"black\",\n\t\t\"x1\", float64(p.ProcessorDefinition.X)+0.5,\n\t\t\"y1\", float64(p.ProcessorDefinition.Y)+16+0.5,\n\t\t\"x2\", float64(p.ProcessorDefinition.X)+float64(procWidth)+0.5,\n\t\t\"y2\", float64(p.ProcessorDefinition.Y)+16+0.5,\n\t)\n\n\tinConnectors := []vdom.Element{}\n\tfor i := 0; i < len(procInputs); i++ {\n\t\tx, y := p.GetConnectorPoint(procWidth, true, i)\n\t\tconnector := vdom.MakeElement(\"rect\",\n\t\t\t\"id\", procName+\":inconn:\"+strconv.Itoa(i),\n\t\t\t\"x\", x-procConnWidth/2,\n\t\t\t\"y\", y-procConnWidth/2,\n\t\t\t\"width\", procConnWidth,\n\t\t\t\"height\", procConnWidth,\n\t\t\t\"stroke\", \"black\",\n\t\t\t\"fill\", \"none\",\n\t\t\t\"pointer-events\", \"all\",\n\t\t\t\"cursor\", \"crosshair\",\n\t\t\tvdom.MakeEventHandler(vdom.MouseDown, p.makeConnectorEventHandler(true, i)),\n\t\t\tvdom.MakeEventHandler(vdom.MouseMove, p.makeConnectorEventHandler(true, i)),\n\t\t)\n\t\tinConnectors = append(inConnectors, connector)\n\n\t\tlabel := vdom.MakeElement(\"text\",\n\t\t\t\"font-family\", \"sans-serif\",\n\t\t\t\"text-anchor\", \"start\",\n\t\t\t\"alignment-baseline\", \"middle\",\n\t\t\t\"font-size\", 10,\n\t\t\t\"x\", x+(procConnWidth/2+2),\n\t\t\t\"y\", y,\n\t\t\tvdom.MakeTextElement(procInputs[i]),\n\t\t)\n\t\tinConnectors = append(inConnectors, label)\n\t}\n\n\toutConnectors := []vdom.Element{}\n\tfor i := 0; i < len(procOutputs); i++ {\n\t\tx, y := p.GetConnectorPoint(procWidth, false, i)\n\t\tconnector := vdom.MakeElement(\"rect\",\n\t\t\t\"id\", procName+\":outconn:\"+strconv.Itoa(i),\n\t\t\t\"x\", x-procConnWidth/2,\n\t\t\t\"y\", y-procConnWidth/2,\n\t\t\t\"width\", procConnWidth,\n\t\t\t\"height\", procConnWidth,\n\t\t\t\"stroke\", \"black\",\n\t\t\t\"fill\", \"none\",\n\t\t\t\"pointer-events\", \"all\",\n\t\t\t\"cursor\", \"crosshair\",\n\t\t\tvdom.MakeEventHandler(vdom.MouseDown, p.makeConnectorEventHandler(false, i)),\n\t\t\tvdom.MakeEventHandler(vdom.MouseMove, p.makeConnectorEventHandler(false, i)),\n\t\t)\n\t\toutConnectors = append(outConnectors, connector)\n\n\t\tlabel := vdom.MakeElement(\"text\",\n\t\t\t\"font-family\", \"sans-serif\",\n\t\t\t\"text-anchor\", \"end\",\n\t\t\t\"alignment-baseline\", \"middle\",\n\t\t\t\"font-size\", 10,\n\t\t\t\"x\", x-(procConnWidth/2+4),\n\t\t\t\"y\", y,\n\t\t\tvdom.MakeTextElement(procOutputs[i]),\n\t\t)\n\t\toutConnectors = append(outConnectors, label)\n\t}\n\n\tparameters := []vdom.Element{}\n\tfor i := 0; i < len(procParameters); i++ {\n\t\t_, y := p.GetConnectorPoint(procWidth, true, i+maxConnectors)\n\n\t\twidth := procWidth - ((procConnWidth + 2) * 2)\n\t\tlevelValue := strconv.FormatFloat(float64(procParameters[i].Value), 'f', -1, 32)\n\t\tlevelWidth := int(float32(width) * (procParameters[i].Value / procParameters[i].Max))\n\t\tlevelFactor := float32(width) / procParameters[i].Max\n\n\t\tlevel := vdom.MakeElement(\"rect\",\n\t\t\t\"id\", procName+\":parameter:\"+strconv.Itoa(i),\n\t\t\t\"x\", p.ProcessorDefinition.X+procConnWidth+2,\n\t\t\t\"y\", y-2,\n\t\t\t\"width\", levelWidth,\n\t\t\t\"height\", procConnWidth+4,\n\t\t\t\"stroke\", \"none\",\n\t\t\t\"fill\", \"cyan\",\n\t\t\t\"pointer-events\", \"none\",\n\t\t)\n\t\tparameters = append(parameters, level)\n\n\t\tbound := vdom.MakeElement(\"rect\",\n\t\t\t\"id\", procName+\":parameter:\"+strconv.Itoa(i),\n\t\t\t\"x\", p.ProcessorDefinition.X+procConnWidth+2,\n\t\t\t\"y\", y-2,\n\t\t\t\"width\", width,\n\t\t\t\"height\", procConnWidth+4,\n\t\t\t\"stroke\", \"black\",\n\t\t\t\"fill\", \"none\",\n\t\t\t\"pointer-events\", \"all\",\n\t\t\t\"cursor\", \"crosshair\",\n\t\t\tvdom.MakeEventHandler(vdom.MouseDown, p.makeParameterEventHandler(i, levelFactor)),\n\t\t\tvdom.MakeEventHandler(vdom.MouseUp, p.makeParameterEventHandler(i, levelFactor)),\n\t\t\tvdom.MakeEventHandler(vdom.MouseMove, p.makeParameterEventHandler(i, levelFactor)),\n\t\t\tvdom.MakeEventHandler(vdom.MouseLeave, p.makeParameterEventHandler(i, levelFactor)),\n\t\t\tvdom.MakeElement(\"title\", vdom.MakeTextElement(levelValue)),\n\t\t)\n\t\tparameters = append(parameters, bound)\n\n\t\tname := vdom.MakeElement(\"text\",\n\t\t\t\"font-family\", \"sans-serif\",\n\t\t\t\"text-anchor\", \"middle\",\n\t\t\t\"alignment-baseline\", \"hanging\",\n\t\t\t\"font-size\", 10,\n\t\t\t\"x\", p.ProcessorDefinition.X+(procWidth/2),\n\t\t\t\"y\", y,\n\t\t\tvdom.MakeTextElement(procParameters[i].Name))\n\t\tparameters = append(parameters, name)\n\t}\n\n\telement := vdom.MakeElement(\"g\",\n\t\tvdom.MakeElement(\"rect\",\n\t\t\t\"id\", procName,\n\t\t\t\"x\", p.ProcessorDefinition.X,\n\t\t\t\"y\", p.ProcessorDefinition.Y,\n\t\t\t\"width\", procWidth,\n\t\t\t\"height\", procHeight,\n\t\t\t\"stroke\", \"black\",\n\t\t\t\"fill\", \"white\",\n\t\t\t\"cursor\", \"pointer\",\n\t\t\tvdom.MakeEventHandler(vdom.MouseDown, p.processorEventHandler),\n\t\t\tvdom.MakeEventHandler(vdom.MouseUp, p.processorEventHandler),\n\t\t\tvdom.MakeEventHandler(vdom.MouseMove, p.processorEventHandler),\n\t\t\tvdom.MakeEventHandler(vdom.ContextMenu, p.processorEventHandler),\n\t\t),\n\t\tprocNameLabel,\n\t\tprocLine,\n\t\tinConnectors,\n\t\toutConnectors,\n\t\tparameters,\n\t)\n\n\tcustom, ok := p.ProcessorDefinition.Processor.(vdom.Component)\n\tif ok {\n\t\telement.AppendChild(vdom.MakeElement(\"g\",\n\t\t\t\"transform\", \"translate(\"+strconv.Itoa(p.ProcessorDefinition.X)+\",\"+strconv.Itoa(p.ProcessorDefinition.Y)+\")\",\n\t\t\tcustom,\n\t\t))\n\t}\n\n\treturn element\n}", "func (v *View) Renderer(matcher func(instance.Description) bool) (func(w io.Writer, v interface{}) error, error) {\n\ttagsView, err := template.NewTemplate(template.ValidURL(v.tagsTemplate), v.options)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\tpropertiesView, err := template.NewTemplate(template.ValidURL(v.propertiesTemplate), v.options)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\n\treturn func(w io.Writer, result interface{}) error {\n\n\t\tinstances, is := result.([]instance.Description)\n\t\tif !is {\n\t\t\treturn fmt.Errorf(\"not []instance.Description\")\n\t\t}\n\n\t\tif !v.quiet {\n\t\t\tif v.viewTemplate != \"\" {\n\t\t\t\tfmt.Printf(\"%-30s\\t%-30s\\n\", \"ID\", \"VIEW\")\n\t\t\t} else if v.properties {\n\t\t\t\tfmt.Printf(\"%-30s\\t%-30s\\t%-30s\\t%-s\\n\", \"ID\", \"LOGICAL\", \"TAGS\", \"PROPERTIES\")\n\n\t\t\t} else {\n\t\t\t\tfmt.Printf(\"%-30s\\t%-30s\\t%-s\\n\", \"ID\", \"LOGICAL\", \"TAGS\")\n\t\t\t}\n\t\t}\n\t\tfor _, d := range instances {\n\n\t\t\t// TODO - filter on the client side by tags\n\t\t\tif len(v.TagFilter()) > 0 {\n\t\t\t\tif hasDifferentTag(v.TagFilter(), d.Tags) {\n\t\t\t\t\tcontinue\n\t\t\t\t}\n\t\t\t}\n\t\t\tif matcher != nil {\n\t\t\t\tif !matcher(d) {\n\t\t\t\t\tcontinue\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tlogical := \" - \"\n\t\t\tif d.LogicalID != nil {\n\t\t\t\tlogical = string(*d.LogicalID)\n\t\t\t}\n\n\t\t\tif v.viewTemplate != \"\" {\n\n\t\t\t\tcolumn := \"-\"\n\t\t\t\tif view, err := d.View(v.viewTemplate); err == nil {\n\t\t\t\t\tcolumn = view\n\t\t\t\t} else {\n\t\t\t\t\tcolumn = err.Error()\n\t\t\t\t}\n\t\t\t\tfmt.Printf(\"%-30s\\t%-30s\\n\", d.ID, column)\n\n\t\t\t} else {\n\n\t\t\t\ttagViewBuff := \"\"\n\t\t\t\tif v.tagsTemplate == \"*\" {\n\t\t\t\t\t// default -- this is a hack\n\t\t\t\t\tprintTags := []string{}\n\t\t\t\t\tfor k, v := range d.Tags {\n\t\t\t\t\t\tprintTags = append(printTags, fmt.Sprintf(\"%s=%s\", k, v))\n\t\t\t\t\t}\n\t\t\t\t\tsort.Strings(printTags)\n\t\t\t\t\ttagViewBuff = strings.Join(printTags, \",\")\n\t\t\t\t} else {\n\t\t\t\t\ttagViewBuff = renderTags(d.Tags, tagsView)\n\t\t\t\t}\n\n\t\t\t\tif v.properties {\n\n\t\t\t\t\tif v.quiet {\n\t\t\t\t\t\t// special render only the properties\n\t\t\t\t\t\tfmt.Printf(\"%s\", renderProperties(d.Properties, propertiesView))\n\t\t\t\t\t} else {\n\t\t\t\t\t\tfmt.Printf(\"%-30s\\t%-30s\\t%-30s\\t%-s\\n\", d.ID, logical, tagViewBuff,\n\t\t\t\t\t\t\trenderProperties(d.Properties, propertiesView))\n\t\t\t\t\t}\n\t\t\t\t} else {\n\t\t\t\t\tfmt.Printf(\"%-30s\\t%-30s\\t%-s\\n\", d.ID, logical, tagViewBuff)\n\t\t\t\t}\n\n\t\t\t}\n\t\t}\n\t\treturn nil\n\t}, nil\n}", "func (self *CircularTrack) Render(render chan Object) {\n\trender <- self\n\tfor _, val := range self.Childs() {\n\t\trender <- val\n\t}\n}", "func CountPrintf(f string, vals ...interface{}) {\n\tcount++\n\tfmt.Printf(fmt.Sprintf(\"%d - \", count)+f, vals...)\n}", "func Render(state *model.Model) time.Duration {\n\tt := time.Now()\n\n\trenderer.SetDrawColor(255, 255, 255, 255)\n\trenderer.FillRect(fullScreenRect)\n\n\tcurrentSurface, _ := window.GetSurface()\n\n\tl := layout.New(screenWidth, screenHeight)\n\n\tinstruments := l.Row(instrumentHeight)\n\tdistanceCell := instruments.Col(columnWidth)\n\tspeedCell := instruments.Col(columnWidth)\n\theadingCell := instruments.Col(columnWidth)\n\n\tRenderHeadingCell(state, currentSurface, headingCell)\n\tRenderDistanceCell(state, currentSurface, distanceCell)\n\tRenderSpeedCell(state, currentSurface, speedCell)\n\n\trenderer.SetDrawColor(255, 255, 255, 255)\n\n\t// waypoints 1 - 3\n\tif len(state.Book) > 0 {\n\t\t//TODO: breaks if there aren't Idx + 3 remaining\n\t\tfor idx, waypoint := range state.Book[state.Idx : state.Idx+3] {\n\t\t\ty := int32(instrumentHeight + idx*waypointHeight)\n\t\t\tbg := &sdl.Rect{0, y, int32(screenWidth), int32(waypointHeight)}\n\t\t\tr, g, b, _ := waypoint.Background.RGBA()\n\n\t\t\t// box\n\t\t\trenderer.SetDrawColor(uint8(r), uint8(g), uint8(b), 255)\n\t\t\trenderer.FillRect(bg)\n\n\t\t\t// distance\n\t\t\ttextBg := sdl.Color{uint8(r), uint8(g), uint8(b), 255}\n\t\t\ttextFg := sdl.Color{0, 0, 0, 255}\n\t\t\tif waypoint.Background == color.Black {\n\t\t\t\ttextFg = sdl.Color{255, 255, 255, 255}\n\t\t\t}\n\n\t\t\tdistanceFormat := \"%0.1f\"\n\t\t\tif (appcontext.GContext.NumAfterDecimal == 2) {\n\t\t\t\tdistanceFormat = \"%0.2f\"\n\t\t\t}\n\t\t\tdistance, _ := dinMedium144.RenderUTF8Shaded(strings.Replace(fmt.Sprintf(distanceFormat, waypoint.Distance), \".\", \",\", -1), textFg, textBg)\n\n\t\t\tdistRect := distance.ClipRect\n\t\t\tdistance.Blit(nil, currentSurface, &sdl.Rect{(columnWidth - distRect.W) / 2, bg.Y + (waypointHeight-distRect.H)/2, 0, 0})\n\t\t\tdistance.Free()\n\n\t\t\t// tulip and notes\n\t\t\tpair := getTulipNotesPair(state.Idx+idx, &waypoint)\n\n\t\t\tpair.tulip.Blit(nil, currentSurface, &sdl.Rect{columnWidth, bg.Y + (waypointHeight-TulipHeight)/2, 0, 0})\n\t\t\tpair.notes.Blit(nil, currentSurface, &sdl.Rect{columnWidth * 2, bg.Y + (waypointHeight-NotesHeight)/2, 0, 0})\n\n\t\t\t// divider\n\t\t\trenderer.SetDrawColor(0, 0, 0, 255)\n\t\t\tbg.H = dividerHeight\n\t\t\trenderer.FillRect(bg)\n\t\t}\n\t\t//TODO: draw divider even when no waypoints exist\n\t}\n\n\tgc := appcontext.GContext\n\tgm := appmanager.GAppManager\n\n\tmainWindowSurface := gc.MainSurface\n\tgm.Render(mainWindowSurface)\n\n\t// display frame\n\trenderer.Present()\n\n\t// ensure we wait at least frameDuration\n\tfpsDelay := frameDuration - time.Since(t)\n\treturn fpsDelay\n}", "func render(fset *token.FileSet, x interface{}) string {\n\tvar buf bytes.Buffer\n\tif err := printer.Fprint(&buf, fset, x); err != nil {\n\t\tpanic(err)\n\t}\n\treturn buf.String()\n}", "func render(fset *token.FileSet, x interface{}) string {\n\tvar buf bytes.Buffer\n\tif err := printer.Fprint(&buf, fset, x); err != nil {\n\t\tpanic(err)\n\t}\n\treturn buf.String()\n}", "func DrawElements(mode uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n C.glowDrawElements(gpDrawElements, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices)\n}", "func MultiDrawElements(mode uint32, count *int32, xtype uint32, indices *unsafe.Pointer, drawcount int32) {\n\tsyscall.Syscall6(gpMultiDrawElements, 5, uintptr(mode), uintptr(unsafe.Pointer(count)), uintptr(xtype), uintptr(unsafe.Pointer(indices)), uintptr(drawcount), 0)\n}", "func (rf RendererFunc) Render(w io.Writer, v interface{}) error { return rf(w, v) }", "func (c *regularResourceComponent) Render(out io.Writer) (numLines int, err error) {\n\tc.mu.Lock()\n\tdefer c.mu.Unlock()\n\n\tcomponents := cfnLineItemComponents(c.description, c.separator, c.statuses, c.stopWatch, c.padding)\n\treturn renderComponents(out, components)\n}", "func (params complexPropertyConversionParameters) countArraysAndMapsInConversionContext() int {\n\tresult := 0\n\tfor _, t := range params.conversionContext {\n\t\tswitch t.(type) {\n\t\tcase *astmodel.MapType:\n\t\t\tresult += 1\n\t\tcase *astmodel.ArrayType:\n\t\t\tresult += 1\n\t\t}\n\t}\n\n\treturn result\n}", "func (o GroupContainerGpuOutput) Count() pulumi.IntPtrOutput {\n\treturn o.ApplyT(func(v GroupContainerGpu) *int { return v.Count }).(pulumi.IntPtrOutput)\n}", "func (gl *WebGL) DrawElements(mode GLEnum, count int, valueType GLEnum, offset int) {\n\tgl.context.Call(\"drawElements\", mode, count, valueType, offset)\n}", "func (ren *RenderComponent) generateBufferContent() []float32 {\n\tscaleX := ren.scale.X\n\tscaleY := ren.scale.Y\n\trotation := float32(0.0)\n\ttransparency := float32(1.0)\n\tc := ren.Color\n\n\tfx := float32(0)\n\tfy := float32(0)\n\tfx2 := ren.drawable.Width()\n\tfy2 := ren.drawable.Height()\n\n\tif scaleX != 1 || scaleY != 1 {\n\t\t//fx *= scaleX\n\t\t//fy *= scaleY\n\t\tfx2 *= scaleX\n\t\tfy2 *= scaleY\n\t}\n\n\tp1x := fx\n\tp1y := fy\n\tp2x := fx\n\tp2y := fy2\n\tp3x := fx2\n\tp3y := fy2\n\tp4x := fx2\n\tp4y := fy\n\n\tvar x1 float32\n\tvar y1 float32\n\tvar x2 float32\n\tvar y2 float32\n\tvar x3 float32\n\tvar y3 float32\n\tvar x4 float32\n\tvar y4 float32\n\n\tif rotation != 0 {\n\t\trot := rotation * (math.Pi / 180.0)\n\n\t\tcos := math.Cos(rot)\n\t\tsin := math.Sin(rot)\n\n\t\tx1 = cos*p1x - sin*p1y\n\t\ty1 = sin*p1x + cos*p1y\n\n\t\tx2 = cos*p2x - sin*p2y\n\t\ty2 = sin*p2x + cos*p2y\n\n\t\tx3 = cos*p3x - sin*p3y\n\t\ty3 = sin*p3x + cos*p3y\n\n\t\tx4 = x1 + (x3 - x2)\n\t\ty4 = y3 - (y2 - y1)\n\t} else {\n\t\tx1 = p1x\n\t\ty1 = p1y\n\n\t\tx2 = p2x\n\t\ty2 = p2y\n\n\t\tx3 = p3x\n\t\ty3 = p3y\n\n\t\tx4 = p4x\n\t\ty4 = p4y\n\t}\n\n\tcolorR, colorG, colorB, _ := c.RGBA()\n\n\tred := colorR\n\tgreen := colorG << 8\n\tblue := colorB << 16\n\talpha := uint32(transparency*255.0) << 24\n\n\ttint := math.Float32frombits((alpha | blue | green | red) & 0xfeffffff)\n\n\tu, v, u2, v2 := ren.drawable.View()\n\n\treturn []float32{x1, y1, u, v, tint, x4, y4, u2, v, tint, x3, y3, u2, v2, tint, x2, y2, u, v2, tint}\n}", "func (r *Renderer) Render() {\n\tgl.DrawArrays(gl.TRIANGLES, 0, int32(len(r.RawRenderer)*4))\n}", "func DrawElementsInstanced(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32) {\n C.glowDrawElementsInstanced(gpDrawElementsInstanced, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLsizei)(instancecount))\n}", "func (f *Factory) Counter(name string, tags map[string]string) metrics.Counter {\n\tcounter := &counter{\n\t\tcounters: make([]metrics.Counter, len(f.factories)),\n\t}\n\tfor i, factory := range f.factories {\n\t\tcounter.counters[i] = factory.Counter(name, tags)\n\t}\n\treturn counter\n}", "func renderResults(vals []interface{}) Data {\n\tvar nilcount int\n\tvar obj interface{}\n\tfor _, val := range vals {\n\t\tswitch val.(type) {\n\t\tcase image.Image, Data:\n\t\t\tobj = val\n\t\tcase nil:\n\t\t\tnilcount++\n\t\t}\n\t}\n\tif obj != nil && nilcount == len(vals)-1 {\n\t\tswitch val := obj.(type) {\n\t\tcase image.Image:\n\t\t\tdata, err := image0(val)\n\t\t\tif err == nil {\n\t\t\t\treturn data\n\t\t\t}\n\t\tcase Data:\n\t\t\treturn val\n\t\t}\n\t}\n\tif nilcount == len(vals) {\n\t\t// if all values are nil, return empty Data\n\t\treturn Data{}\n\t}\n\treturn MakeData(\"text/plain\", fmt.Sprint(vals...))\n}", "func TransformFeedbackVaryings(program uint32, count int32, varyings **int8, bufferMode uint32) {\n C.glowTransformFeedbackVaryings(gpTransformFeedbackVaryings, (C.GLuint)(program), (C.GLsizei)(count), (**C.GLchar)(unsafe.Pointer(varyings)), (C.GLenum)(bufferMode))\n}", "func GenerateShapes() {\r\n\t// Square\r\n\tShapes[0].vertices = []gl.GLfloat{-1, -1, 1, -1, -1, 1, 1, 1}\r\n\tShapes[0].elements = []gl.GLushort{0, 1, 2, 2, 3, 1}\r\n\r\n\t// ___|\r\n\tShapes[1].vertices = []gl.GLfloat{-2, 0, -2, -1, 2, -1, 2, 0, 2, 1, 1, 1, 1, 0}\r\n\tShapes[1].elements = []gl.GLushort{0, 1, 2, 2, 3, 0, 3, 4, 5, 5, 6, 3}\r\n\r\n\t// _|_\r\n\tShapes[2].vertices = []gl.GLfloat{-1.5, 0, -0.5, 0, -0.5, 1, 0.5, 1, 0.5, 0, 1.5, 0, 1.5, -1, -1.5, -1}\r\n\tShapes[2].elements = []gl.GLushort{1, 2, 3, 3, 4, 1, 0, 7, 6, 6, 0, 5}\r\n\r\n\t// Snake\r\n\tShapes[3].vertices = []gl.GLfloat{-1.5, -1, -1.5, 0, -0.5, 0, -0.5, 1, 1.5, 1, 1.5, 0, 0.5, 0, 0.5, -1}\r\n\tShapes[3].elements = []gl.GLushort{0, 1, 6, 6, 7, 0, 2, 3, 4, 4, 5, 2}\r\n\r\n\t// Now fill out the rest automatically.\r\n\t// FIXME why doesn't using _, shape in this loop work ?\r\n\tfor i := range Shapes {\r\n\t\tShapes[i].vao = gl.GenVertexArray()\r\n\t\tShapes[i].vao.Bind()\r\n\t\tShapes[i].vbo = gl.GenBuffer()\r\n\t\tShapes[i].vbo.Bind(gl.ARRAY_BUFFER)\r\n\t\tgl.BufferData(gl.ARRAY_BUFFER, len(Shapes[i].vertices)*4, Shapes[i].vertices, gl.STATIC_DRAW)\r\n\t\tShapes[i].elementBuffer = gl.GenBuffer()\r\n\t\tShapes[i].elementBuffer.Bind(gl.ELEMENT_ARRAY_BUFFER)\r\n\t\tgl.BufferData(gl.ELEMENT_ARRAY_BUFFER, len(Shapes[i].elements)*2, Shapes[i].elements, gl.STATIC_DRAW)\r\n\t\tShapes[i].numElements = len(Shapes[i].elements)\r\n\r\n\t\tvertexAttribArray := shaderProgram.GetAttribLocation(\"position\")\r\n\t\tvertexAttribArray.AttribPointer(2, gl.FLOAT, false, 0, uintptr(0))\r\n\t\tvertexAttribArray.EnableArray()\r\n\t}\r\n}", "func (s *Layer) Render(ctx *RenderContext) {\n\tfor _, e := range s.entities {\n\t\te.Render(ctx)\n\t}\n}", "func (mm *massivemonster) render() {\n\n\trenderOutput(\"Massive Monster\", \"h1\", \"red\")\n\trenderOutput(mm.mmType, \"\", \"clear\")\n\trenderOutput(\"Class: \"+strconv.Itoa(mm.class), \"\", \"clear\")\n\trenderOutput(\"Motivation: \"+mm.motivation, \"\", \"clear\")\n\n\trenderOutput(\"Abilities\", \"h2\", \"clear\")\n\tif len(mm.abilities) > 0 {\n\t\tfor i := 0; i < len(mm.abilities); i++ {\n\t\t\trenderOutput(mm.abilities[i], \"listitem\", \"blue\")\n\t\t}\n\t}\n\n\trenderOutput(\"Natures\", \"h2\", \"clear\")\n\tif len(mm.natures) > 0 {\n\t\tfor i := 0; i < len(mm.natures); i++ {\n\t\t\trenderOutput(mm.natures[i], \"listitem\", \"green\")\n\t\t}\n\t}\n\trenderOutput(\"Weak Spot: \"+mm.weakSpot, \"\", \"yellow\")\n\trenderOutput(\"Incursion Zone Effect\", \"h2\", \"purple\")\n\trenderOutput(mm.zEffect, \"listitem\", \"clear\")\n\n}", "func CountAndSay(n int) string {\n\tres := \"1\"\n\tfor i := 0; i < n-1; i++ {\n\t\tres = translate(res)\n\t}\n\treturn res\n}", "func (vao *VAO) RenderInstanced(instancecount int32) {\n\tgl.BindVertexArray(vao.handle)\n\tif vao.indexBuffer != nil {\n\t\tgl.BindBuffer(gl.ELEMENT_ARRAY_BUFFER, vao.indexBuffer.GetHandle())\n\t\tgl.DrawElementsInstanced(vao.mode, vao.indexBuffer.Len(), gl.UNSIGNED_SHORT, nil, instancecount)\n\t\tgl.BindBuffer(gl.ELEMENT_ARRAY_BUFFER, 0)\n\t} else {\n\t\tgl.DrawArraysInstanced(vao.mode, 0, vao.vertexBuffers[0].Len(), instancecount)\n\t}\n\tgl.BindVertexArray(0)\n}", "func DrawN(count int, opts ...options) (result []string, err error) {\n\tif count <= 0 {\n\t\tcount = 1\n\t}\n\n\tfor i := 0; i < count; i++ {\n\t\toutput, err := Draw(opts...)\n\t\tif err != nil {\n\t\t\treturn nil, err\n\t\t}\n\t\tresult = append(result, output)\n\t}\n\n\treturn\n}", "func (ctx *RecordContext) Render(v interface{}) error {\n\tctx.Renders = append(ctx.Renders, v)\n\treturn ctx.Context.Render(v)\n}", "func (gm *GraphicsManager) RenderAll(sm component.SceneManager) (*common.Vector, *common.Vector) {\n\terrs := common.MakeVector()\n\tcompsToSend := common.MakeVector()\n\tcomps := gm.compList.Array()\n\n\tfor i := range comps {\n\t\tif comps[i] == nil {\n\t\t\tcontinue\n\t\t}\n\t\tcompsToSend.Insert(comps[i].(component.GOiD))\n\t}\n\n\treturn compsToSend, errs\n}", "func (h Hand) Render() string {\n\tbuffer := bytes.Buffer{}\n\tlast := len(h.Cards) - 1\n\tfor i, card := range h.Cards {\n\t\tbuffer.WriteString(card.Render())\n\t\tif i != last {\n\t\t\tbuffer.WriteString(\", \")\n\t\t}\n\t}\n\tbuffer.WriteString(fmt.Sprintf(\n\t\t\" (%s)\", scoresRenderer{h.Scores()}.Render(),\n\t))\n\treturn strings.Trim(buffer.String(), \" \")\n}", "func (tm *TreasureMap) render() {\n\tvar (\n\t\ttreasureMapDrawPerLine, treasureMapDrawComplete, treasureMapAdditional string\n\t)\n\n\tfor y := 1; y <= tm.Size[1]; y++ {\n\t\ttreasureMapDrawPerLine = \"\"\n\t\tif y < tm.Size[1] {\n\t\t\ttreasureMapDrawPerLine = \"\\n\"\n\t\t}\n\t\tfor x := 1; x <= tm.Size[0]; x++ {\n\t\t\ttreasureMapDrawPerLine = treasureMapDrawPerLine + convertIntToEntity(tm.Mapping[[2]int{x, y}])\n\t\t}\n\t\ttreasureMapDrawComplete = treasureMapDrawPerLine + treasureMapDrawComplete\n\t}\n\n\tif len(tm.ListPossibleTreasureLocation) > 0 {\n\t\tfor coordinate, possibleLocation := range tm.ListPossibleTreasureLocation {\n\t\t\tcoordinateString := strconv.Itoa(coordinate[0]) + \",\" + strconv.Itoa(coordinate[1])\n\t\t\tif possibleLocation {\n\t\t\t\ttreasureMapAdditional = treasureMapAdditional + fmt.Sprintf(\"{%s},\", coordinateString)\n\t\t\t}\n\t\t}\n\t\ttreasureMapDrawComplete = treasureMapDrawComplete + fmt.Sprintf(\"\\nPossible treasure location: %s\", treasureMapAdditional)\n\t}\n\n\tif tm.TreasureLocation != [2]int{} {\n\t\tcoordinateString := strconv.Itoa(tm.TreasureLocation[0]) + \",\" + strconv.Itoa(tm.TreasureLocation[1])\n\t\ttreasureMapDrawComplete = treasureMapDrawComplete + fmt.Sprintf(\"\\nTreasure found at location: {%s}! Congratulation!\", coordinateString)\n\t}\n\n\trenderToTerminal(treasureMapDrawComplete)\n}", "func (e *tag) fastRender(w io.Writer, tag string, children []Element) (int, error) {\n\tif len(e.childData) == 0 {\n\t\t// Record the rendering into child data.\n\t\tbuf := new(bytes.Buffer)\n\t\t_, err := e.renderElement(buf, tag, children)\n\t\tif err != nil {\n\t\t\treturn 0, err\n\t\t}\n\t\te.childData = buf.Bytes()\n\t}\n\tn, err := w.Write(e.childData)\n\treturn n, err\n}", "func DrawElementsInstancedBaseVertex(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32, basevertex int32) {\n C.glowDrawElementsInstancedBaseVertex(gpDrawElementsInstancedBaseVertex, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLsizei)(instancecount), (C.GLint)(basevertex))\n}", "func (l *CaptureResponseList) Render(w http.ResponseWriter, r *http.Request) error {\n\tl.Captures = make([]CaptureResponse, len(l.cs))\n\tfor i := 0; i < len(l.cs); i++ {\n\t\tl.Captures[i] = *NewCaptureResponse(&l.cs[i])\n\t\tif err := l.Captures[i].Render(nil, nil); err != nil {\n\t\t\treturn perr.NewErrInternal(errors.Wrap(err, \"could not bind PropertyResponse\"))\n\t\t}\n\t}\n\n\treturn nil\n}", "func (native *OpenGL) DrawElements(mode uint32, count int32, elementType uint32, indices uintptr) {\n\tgl.DrawElements(mode, count, elementType, unsafe.Pointer(indices)) // nolint: govet,gas\n}", "func (c *stackComponent) Render(out io.Writer) (numLines int, err error) {\n\tc.mu.Lock()\n\tdefer c.mu.Unlock()\n\n\treturn renderComponents(out, c.resources)\n}", "func DrawElements(mode uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n\tsyscall.Syscall6(gpDrawElements, 4, uintptr(mode), uintptr(count), uintptr(xtype), uintptr(indices), 0, 0)\n}", "func MultiDrawElements(mode uint32, count *int32, xtype uint32, indices *unsafe.Pointer, drawcount int32) {\n\tC.glowMultiDrawElements(gpMultiDrawElements, (C.GLenum)(mode), (*C.GLsizei)(unsafe.Pointer(count)), (C.GLenum)(xtype), indices, (C.GLsizei)(drawcount))\n}", "func MultiDrawElements(mode uint32, count *int32, xtype uint32, indices *unsafe.Pointer, drawcount int32) {\n\tC.glowMultiDrawElements(gpMultiDrawElements, (C.GLenum)(mode), (*C.GLsizei)(unsafe.Pointer(count)), (C.GLenum)(xtype), indices, (C.GLsizei)(drawcount))\n}", "func (l LogItems) Render(showTime bool, ll [][]byte) {\n\tcolors := make(map[string]int, len(l))\n\tfor i, item := range l {\n\t\tinfo := item.ID()\n\t\tcolor, ok := colors[info]\n\t\tif !ok {\n\t\t\tcolor = colorFor(info)\n\t\t\tcolors[info] = color\n\t\t}\n\t\tll[i] = item.Render(color, showTime)\n\t}\n}", "func GenderSpout(tuple []interface{}, result *[]interface{}, variables *[]interface{}) error {\n\t// Variables\n\tvar counterMap map[string]interface{}\n\tvar idArray interface{}\n\tvar genderArray interface{}\n\n\tif (len(*variables) == 0) {\n\t\tcounterMap = make(map[string]interface{})\n\t\t*variables = append(*variables, counterMap)\n\t\tcounterMap[\"counter\"] = float64(0)\n\n\t\tfile, _ := os.Open(\"data.json\")\n\t\tdefer file.Close()\n\n\t\tb, _ := ioutil.ReadAll(file)\n\t\tvar object interface{}\n\t\tjson.Unmarshal(b, &object)\n\t\tobjectMap := object.(map[string]interface{})\n\t\tidArray = objectMap[\"id\"].([]interface{})\n\t\tgenderArray = objectMap[\"gender\"].([]interface{})\n\n\t\t*variables = append(*variables, idArray)\n\t\t*variables = append(*variables, genderArray)\n\t}\n\tcounterMap = (*variables)[0].(map[string]interface{})\n\tidArray = (*variables)[1]\n\tgenderArray = (*variables)[2]\n\n\t// Logic\n\tif counterMap[\"counter\"].(float64) < 1000 {\n\t\t*result = []interface{}{idArray.([]interface{})[int(counterMap[\"counter\"].(float64))], genderArray.([]interface{})[int(counterMap[\"counter\"].(float64))]}\n\t\tcounterMap[\"counter\"] = counterMap[\"counter\"].(float64) + 1\n\t}\n\n\t// // Logic\n\t// if counterMap[\"counter\"].(float64) < 10 {\n\t// \tif int(counterMap[\"counter\"].(float64)) % 2 == 0 {\n\t// \t\t*result = []interface{}{strconv.Itoa(int(counterMap[\"counter\"].(float64))), \"male\"}\n\t// \t} else {\n\t// \t\t*result = []interface{}{strconv.Itoa(int(counterMap[\"counter\"].(float64))), \"female\"}\n\t// \t}\n\t// \tcounterMap[\"counter\"] = counterMap[\"counter\"].(float64) + 1\n\t// }\n\n\ttime.Sleep(1 * time.Millisecond)\n\n\t// Return value\n\tif (len(*result) > 0) {\n\t\tlog.Printf(\"Gender Spout Emit (%v)\\n\", *result)\n\t\treturn nil\n\t} else {\n\t\treturn errors.New(\"next tuple is nil\")\n\t}\n}", "func renderInteger(f float64) string {\n\tif f > math.Nextafter(float64(math.MaxInt64), 0) {\n\t\treturn fmt.Sprintf(\"%d\", int64(math.MaxInt64))\n\t}\n\tif f < math.Nextafter(float64(math.MinInt64), 0) {\n\t\treturn fmt.Sprintf(\"%d\", int64(math.MinInt64))\n\t}\n\treturn fmt.Sprintf(\"%d\", int64(f))\n}", "func (t *textRender) Render(w io.Writer) (err error) {\n\tif len(t.Values) > 0 {\n\t\t_, err = fmt.Fprintf(w, t.Format, t.Values...)\n\t} else {\n\t\t_, err = io.WriteString(w, t.Format)\n\t}\n\treturn\n}", "func (h *HAProxyManager) render(ports []uint16) ([]byte, error) {\n\n\t// prepare the context\n\td := make([]templateContext, len(ports))\n\tfor i, port := range ports {\n\t\tif i == len(h.serviceAddrs) {\n\t\t\th.logger.Warnf(\"got port index %d, but only have %d service addrs. ports=%v serviceAddrs=%v\", i, len(h.serviceAddrs), ports, h.serviceAddrs)\n\t\t\tcontinue\n\t\t}\n\t\td[i] = templateContext{Port: port, Source: h.listenAddr, Dest: h.serviceAddrs[i]}\n\t}\n\n\t// render the template\n\tbuf := &bytes.Buffer{}\n\tif err := h.template.Execute(buf, d); err != nil {\n\t\treturn nil, err\n\t}\n\treturn buf.Bytes(), nil\n}", "func (b *renderSystem) Render(dt float64) {\n\n\tb.renderer.Clear()\n\n\tfor i := 0; i < 100; i++ {\n\t\tl := b.layers[i]\n\t\tif l != nil {\n\t\t\tfor _, renderable := range *l {\n\t\t\t\trenderable.Paint(b.renderer)\n\t\t\t}\n\t\t}\n\t}\n\n\tb.renderer.Present()\n}", "func (o *FactoryContainer) CountOutput() float64 {\n\tvar output float64 = 0.0\n\tfor i, _ := range o.Factories {\n\t\toutput = output + o.Factories[i].Production*o.Factories[i].ProductionModifier\n\t}\n\treturn output\n}", "func (r *JSONRenderer) Render(out io.Writer, st *papers.Stats, unread, read papers.AggPapers) {\n\tr.render(out, st, unread, read)\n}", "func (self *GameObjectCreator) RenderTexture1O(width int) *RenderTexture{\n return &RenderTexture{self.Object.Call(\"renderTexture\", width)}\n}", "func DispatchCompute(num_groups_x uint32, num_groups_y uint32, num_groups_z uint32) {\n C.glowDispatchCompute(gpDispatchCompute, (C.GLuint)(num_groups_x), (C.GLuint)(num_groups_y), (C.GLuint)(num_groups_z))\n}", "func DrawElementsInstancedBaseInstance(mode uint32, count int32, xtype uint32, indices unsafe.Pointer, instancecount int32, baseinstance uint32) {\n C.glowDrawElementsInstancedBaseInstance(gpDrawElementsInstancedBaseInstance, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices, (C.GLsizei)(instancecount), (C.GLuint)(baseinstance))\n}", "func (e *rawData) Render(w io.Writer) (int, error) { return w.Write([]byte(e.content)) }", "func (v *StackPanel) Render(rn Renderer) {\n\toff := 0\n\tfor _, child := range v.childs {\n\t\tif v.orientation == Vertical {\n\t\t\tif off >= v.height {\n\t\t\t\tbreak\n\t\t\t}\n\t\t\theight := v.heights[child]\n\t\t\trn.RenderChild(child, v.width, height, 0, off)\n\t\t\toff += height\n\t\t} else {\n\t\t\tif off >= v.width {\n\t\t\t\tbreak\n\t\t\t}\n\t\t\twidth := v.widths[child]\n\t\t\trn.RenderChild(child, width, v.height, off, 0)\n\t\t\toff += width\n\t\t}\n\t}\n}", "func (c *ConnectionSPI) Render(pixels []RGBPixel) {\r\n\tlogFields := log.Fields{\"package\": logPkg, \"conn\": \"SPI\", \"func\": \"RenderLEDs\"}\r\n\tlog.WithFields(logFields).Infof(\"Render %d LEDs\", len(pixels))\r\n\t// Fix for Raspberry Pi 3 Model B+ (5.15.84-v7+)\r\n\t// Data signal seems to be splitted sending less than 11 LEDS\r\n\tif len(pixels) < 11 {\r\n\t\tpixels = append(pixels, []RGBPixel{{}, {}, {}, {}, {}, {}, {}, {}, {}, {}}...)\r\n\t}\r\n\tvar translatedRGBs []uint8\r\n\tfor _, pixel := range pixels {\r\n\r\n\t\tcolorData := GetColorData(pixel, c.FixSPI)\r\n\t\tlog.WithFields(logFields).Tracef(\"%08b\", pixel)\r\n\r\n\t\tfor _, c := range colorData {\r\n\t\t\ttranslatedRGBs = append(translatedRGBs, c)\r\n\t\t}\r\n\t}\r\n\r\n\tc.transfer(translatedRGBs)\r\n}", "func (r *templateRenderer) Render(parameters *internalParameters, chartPath string, valueRenderer ValueRenderer) (testrunner.RunList, error) {\n\tif chartPath == \"\" {\n\t\treturn make(testrunner.RunList, 0), nil\n\t}\n\n\tstate := &renderState{\n\t\ttemplateRenderer: *r,\n\t\tchartPath: chartPath,\n\t\tvalues: valueRenderer,\n\t\tparameters: parameters,\n\t}\n\n\tc, err := chartutil.Load(chartPath)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\n\t// split all found templates into separate charts\n\ttemplates, files := splitTemplates(c.GetTemplates())\n\truns := make(testrunner.RunList, 0)\n\tfor _, tmpl := range files {\n\t\tvalues, metadata, info, err := valueRenderer.Render(r.defaultValues)\n\t\tif err != nil {\n\t\t\treturn nil, err\n\t\t}\n\t\tc.Templates = append(templates, tmpl)\n\t\tfiles, err := r.RenderChart(c, parameters.Namespace, values)\n\t\tif err != nil {\n\t\t\treturn nil, err\n\t\t}\n\n\t\ttestruns := parseTestrunsFromChart(r.log, files)\n\n\t\tfor _, tr := range testruns {\n\t\t\tmeta := metadata.DeepCopy()\n\t\t\t// Add all repositories defined in the component descriptor to the testrun locations.\n\t\t\t// This gives us all dependent repositories as well as there deployed version.\n\t\t\tif err := testrun_renderer.AddLocationsToTestrun(tr, \"default\", parameters.ComponentDescriptor, true, parameters.AdditionalLocations); err != nil {\n\t\t\t\tr.log.Info(fmt.Sprintf(\"cannot add bom locations: %s\", err.Error()))\n\t\t\t\tcontinue\n\t\t\t}\n\n\t\t\t// Add runtime annotations to the testrun\n\t\t\taddAnnotationsToTestrun(tr, meta.CreateAnnotations())\n\n\t\t\t// add collect annotation\n\t\t\tmetav1.SetMetaDataAnnotation(&tr.ObjectMeta, common.AnnotationCollectTestrun, \"true\")\n\n\t\t\truns = append(runs, &testrunner.Run{\n\t\t\t\tInfo: info,\n\t\t\t\tTestrun: tr,\n\t\t\t\tMetadata: meta,\n\t\t\t\tRerenderer: state,\n\t\t\t})\n\t\t}\n\n\t}\n\n\treturn runs, nil\n}", "func (c *Canvas) Count() int {\n\treturn len(c.paint)\n}", "func (s *Ipset) Render(rType RenderType) string {\n\tvar result string\n\n\tswitch rType {\n\tcase RenderFlush:\n\t\tif len(s.Sets) == 0 {\n\t\t\treturn \"flush\\n\"\n\t\t}\n\tcase RenderDestroy:\n\t\tif len(s.Sets) == 0 {\n\t\t\treturn \"destroy\\n\"\n\t\t}\n\n\t// RenderSwap will fail when Sets < 2,\n\t// it's a duty of a caller to ensure\n\t// correctness.\n\tcase RenderSwap:\n\t\treturn fmt.Sprintf(\"swap %s %s\\n\", s.Sets[0].Name, s.Sets[1].Name)\n\n\t// RenderRename will fail when Sets < 2,\n\t// it's a duty of a caller to ensure\n\t// correctness.\n\tcase RenderRename:\n\t\treturn fmt.Sprintf(\"rename %s %s\\n\", s.Sets[0].Name, s.Sets[1].Name)\n\t}\n\n\tfor _, set := range s.Sets {\n\t\tresult += set.Render(rType)\n\t}\n\n\treturn result\n}", "func (f *ParticleRenderFeature) Extract(v *gfx.View) {\n\tfor i, m := range f.et.comps[:f.et.index] {\n\t\tsid := gfx.PackSortId(m.zOrder, 0)\n\t\tv.RenderNodes = append(v.RenderNodes, gfx.SortObject{sid, uint32(i)})\n\t}\n}", "func (renderer *SimpleMatrixRenderer) Render() {\n\trenderer.renderCharacter(\"\\n\")\n\n\tfor row := 0; row < renderer.Matrix.Height; row++ {\n\t\tfor col := 0; col < renderer.Matrix.Width; col++ {\n\t\t\tif !renderer.Matrix.IsFieldOccupied(row, col) {\n\t\t\t\trenderer.renderUnoccupiedField()\n\t\t\t} else {\n\t\t\t\trenderer.renderOccupiedFieldAtCurrentCursorPos(row, col)\n\t\t\t}\n\t\t}\n\n\t\trenderer.renderCharacter(\"\\n\")\n\t}\n\n\trenderer.renderCharacter(\"\\n\")\n}", "func (this *Precedence) countTemplate(temp [][][]bool) (n int) {\n\tfor _, bench := range temp {\n\t\tfor _, row := range bench {\n\t\t\tfor _, v := range row {\n\t\t\t\tif v {\n\t\t\t\t\tn++\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\treturn\n}", "func (obj *Device) DrawPrimitive(\n\ttyp PRIMITIVETYPE,\n\tstartVertex uint,\n\tprimitiveCount uint,\n) Error {\n\tret, _, _ := syscall.Syscall6(\n\t\tobj.vtbl.DrawPrimitive,\n\t\t4,\n\t\tuintptr(unsafe.Pointer(obj)),\n\t\tuintptr(typ),\n\t\tuintptr(startVertex),\n\t\tuintptr(primitiveCount),\n\t\t0,\n\t\t0,\n\t)\n\treturn toErr(ret)\n}", "func (r *renderer) Render(w io.Writer, m list.Model, index int, item list.Item) {\n\ti, ok := item.(candidateItem)\n\tif !ok {\n\t\treturn\n\t}\n\ts := i.Title()\n\tiw := rw.StringWidth(s)\n\tif iw < r.width {\n\t\ts += strings.Repeat(\" \", r.width-iw)\n\t}\n\tst := &r.m.Styles\n\tfn := st.Item.Render\n\tif r.m.selectedList == r.listIdx && index == m.Index() {\n\t\tfn = st.SelectedItem.Render\n\t}\n\tfmt.Fprint(w, fn(s))\n}", "func (self *Graphics) RenderOrderID() int{\n return self.Object.Get(\"renderOrderID\").Int()\n}", "func makeRenderablePoly(name string, n int, drawType uint, color vec4) *Renderable {\n\t// build poly verts\n\tvertex := makePoly(n)\n\tr := &Renderable{\n\t\tworld.Transform(),\n\t\tworld.Operation(name, &world.Poly{Points: vertex}),\n\t\tworld.MaterialComponent{\n\t\t\tDrawType: drawType,\n\t\t\tProps: map[string]interface{}{\n\t\t\t\t\"color\": world.Color(color),\n\t\t\t},\n\t\t},\n\t}\n\n\treturn r\n}", "func render(ctx aero.Context, allActivities []arn.Activity) error {\n\tuser := arn.GetUserFromContext(ctx)\n\tindex, _ := ctx.GetInt(\"index\")\n\n\t// Slice the part that we need\n\tactivities := allActivities[index:]\n\tmaxLength := activitiesFirstLoad\n\n\tif index > 0 {\n\t\tmaxLength = activitiesPerScroll\n\t}\n\n\tif len(activities) > maxLength {\n\t\tactivities = activities[:maxLength]\n\t}\n\n\t// Next index\n\tnextIndex := infinitescroll.NextIndex(ctx, len(allActivities), maxLength, index)\n\n\t// In case we're scrolling, send activities only (without the page frame)\n\tif index > 0 {\n\t\treturn ctx.HTML(components.ActivitiesScrollable(activities, user))\n\t}\n\n\t// Otherwise, send the full page\n\treturn ctx.HTML(components.ActivityFeed(activities, nextIndex, user))\n}", "func RenderList(w http.ResponseWriter, r *http.Request, l []Renderer) error {\n\tfor _, v := range l {\n\t\tif err := renderer(w, r, v); err != nil {\n\t\t\treturn err\n\t\t}\n\t}\n\tRespond(w, r, l)\n\treturn nil\n}", "func (ob *Object) Render() {\n\tob.image.Draw(ob.x, ob.y, allegro.FLIP_NONE)\n}", "func (l *LogItems) Render(showTime bool, ll [][]byte) {\n\tindex := len(l.colors)\n\tfor i, item := range l.items {\n\t\tid := item.ID()\n\t\tcolor, ok := l.colors[id]\n\t\tif !ok {\n\t\t\tif index >= len(colorPalette) {\n\t\t\t\tindex = 0\n\t\t\t}\n\t\t\tcolor = colorPalette[index]\n\t\t\tl.colors[id] = color\n\t\t\tindex++\n\t\t}\n\t\tll[i] = item.Render(int(color-tcell.ColorValid), showTime)\n\t}\n}", "func Render(tag Tagger) string {\n return tag.Render()\n}", "func (a *World) Render(p *pic.Pic) *World {\n\th, w := p.H, p.W\n\tfh, fw := float64(h), float64(w)\n\tcx := vec.New(fw*a.Ratio/fh, 0, 0)\n\tcy := vec.Mult(vec.Norm(vec.Cross(cx, a.Cam.Direct)), a.Ratio)\n\tsample := a.Sample / 4\n\tinv := 1.0 / float64(sample)\n\n\tfmt.Printf(\"w: %v, h: %v, sample: %v, actual sample: %v, thread: %v, cpu: %v\\n\", w, h, a.Sample, sample*4, a.Thread, a.Core)\n\tbar := pb.StartNew(h * w)\n\tbar.SetRefreshRate(1000 * time.Millisecond)\n\n\truntime.GOMAXPROCS(a.Core)\n\tch := make(chan renderData, a.Thread)\n\twg := sync.WaitGroup{}\n\twg.Add(a.Thread)\n\n\tfor tid := 0; tid < a.Thread; tid++ {\n\t\tgo func() {\n\t\t\tfor {\n\t\t\t\tdata, ok := <-ch\n\t\t\t\tif !ok {\n\t\t\t\t\twg.Done()\n\t\t\t\t\treturn\n\t\t\t\t}\n\t\t\t\tsum, x, y := data.sum, data.x, data.y\n\t\t\t\tfor sy := 0.0; sy < 2.0; sy++ {\n\t\t\t\t\tfor sx := 0.0; sx < 2.0; sx++ {\n\t\t\t\t\t\tc := vec.NewZero()\n\t\t\t\t\t\tfor sp := 0; sp < sample; sp++ {\n\t\t\t\t\t\t\tccx := vec.Mult(cx, ((sx+0.5+gend())/2.0+x)/fw-0.5)\n\t\t\t\t\t\t\tccy := vec.Mult(cy, ((sy+0.5+gend())/2.0+y)/fh-0.5)\n\t\t\t\t\t\t\td := vec.Add(vec.Add(ccx, ccy), a.Cam.Direct)\n\t\t\t\t\t\t\tr := ray.New(vec.Add(a.Cam.Origin, vec.Mult(d, 130)), vec.Norm(d))\n\t\t\t\t\t\t\tc.Add(vec.Mult(a.trace(r, 0), inv))\n\t\t\t\t\t\t}\n\t\t\t\t\t\tsum.Add(vec.Mult(vec.New(pic.Clamp(c.X), pic.Clamp(c.Y), pic.Clamp(c.Z)), 0.25))\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tbar.Add(1)\n\t\t\t}\n\t\t}()\n\t}\n\n\tfor y := 0; y < h; y++ {\n\t\tfor x := 0; x < w; x++ {\n\t\t\tch <- renderData{\n\t\t\t\tsum: &p.C[(h-y-1)*w+x],\n\t\t\t\tx: float64(x),\n\t\t\t\ty: float64(y),\n\t\t\t}\n\t\t}\n\t}\n\n\tclose(ch)\n\twg.Wait()\n\n\tbar.FinishPrint(\"Rendering completed\")\n\treturn a\n}", "func (tofu Tofu) Render(wr io.Writer, name string, obj interface{}) error {\n\tvar m data.Map\n\tif obj != nil {\n\t\tvar ok bool\n\t\tm, ok = data.New(obj).(data.Map)\n\t\tif !ok {\n\t\t\treturn fmt.Errorf(\"invalid data type. expected map/struct, got %T\", obj)\n\t\t}\n\t}\n\treturn tofu.NewRenderer(name).Execute(wr, m)\n}", "func (s *HelloSystem) Draw(ctx core.DrawCtx) {\n\tfor _, v := range s.V().Matches() {\n\t\tebitenutil.DebugPrintAt(ctx.Renderer().Screen(), v.Hello.Text, v.Hello.X, v.Hello.Y)\n\t}\n}", "func DrawElements(mode GLenum, count int, typ GLenum, indices interface{}) {\n\tC.glDrawElements(C.GLenum(mode), C.GLsizei(count), C.GLenum(typ),\n\t\tptr(indices))\n}", "func (td TextDisplay)DrawLives(lives int, screen *ebiten.Image){\r\n\tlife := strconv.Itoa(lives)\r\n\ttext.Draw(screen, life, td.mplusNormalFont,10,30,color.White)\r\n}", "func (c *stackSetComponent) Render(out io.Writer) (int, error) {\n\tc.mu.Lock()\n\tdefer c.mu.Unlock()\n\n\tcomponents := cfnLineItemComponents(c.title, c.separator, c.statuses, c.stopWatch, c.style.Padding)\n\treturn renderComponents(out, components)\n}", "func DrawArraysInstanced(mode uint32, first int32, count int32, instancecount int32) {\n C.glowDrawArraysInstanced(gpDrawArraysInstanced, (C.GLenum)(mode), (C.GLint)(first), (C.GLsizei)(count), (C.GLsizei)(instancecount))\n}", "func (f Frame) Render() string {\n\tsb := strings.Builder{}\n\tfor _, row := range f {\n\t\tfor _, shade := range row {\n\t\t\tsb.WriteString(fmt.Sprintf(\"%d\", shade))\n\t\t}\n\t\tsb.WriteString(\"\\n\")\n\t}\n\tsb.WriteString(\"==============================\\n\")\n\n\treturn sb.String()\n}", "func NumberLamp(vs []val.Val) {\n\tfunc(vs []val.Val) {\n\t\tdraw := func(color, str string) {\n\t\t\tfmt.Print(colorstring.Color(\"[_\" + color + \"_]\" + str + \"[default]\"))\n\t\t}\n\t\tfor {\n\t\t\toff := \"black\"\n\t\t\ton := \"blue\"\n\t\t\tons := make([]string, 7)\n\t\t\tfor i := 0; i < 7; i++ {\n\t\t\t\tout := vs[i].Out()\n\t\t\t\tif out.IsNil() {\n\t\t\t\t\treturn\n\t\t\t\t}\n\t\t\t\tif out.Bool() {\n\t\t\t\t\tons[i] = on\n\t\t\t\t} else {\n\t\t\t\t\tons[i] = off\n\t\t\t\t}\n\t\t\t}\n\t\t\t//\t0\n\t\t\tdraw(off, \" \")\n\t\t\tdraw(ons[0], \" \")\n\t\t\tdraw(off, \" \")\n\t\t\tdraw(off, \"\\n\")\n\t\t\t//\t5 1\n\t\t\tdraw(ons[5], \" \")\n\t\t\tdraw(off, \" \")\n\t\t\tdraw(ons[1], \" \")\n\t\t\tdraw(off, \"\\n\")\n\t\t\tdraw(ons[5], \" \")\n\t\t\tdraw(off, \" \")\n\t\t\tdraw(ons[1], \" \")\n\t\t\tdraw(off, \"\\n\")\n\t\t\t//\t6\n\t\t\tdraw(off, \" \")\n\t\t\tdraw(ons[6], \" \")\n\t\t\tdraw(off, \" \")\n\t\t\tdraw(off, \"\\n\")\n\t\t\t//\t4 2\n\t\t\tdraw(ons[4], \" \")\n\t\t\tdraw(off, \" \")\n\t\t\tdraw(ons[2], \" \")\n\t\t\tdraw(off, \"\\n\")\n\t\t\tdraw(ons[4], \" \")\n\t\t\tdraw(off, \" \")\n\t\t\tdraw(ons[2], \" \")\n\t\t\tdraw(off, \"\\n\")\n\t\t\t//\t3\n\t\t\tdraw(off, \" \")\n\t\t\tdraw(ons[3], \" \")\n\t\t\tdraw(off, \" \")\n\t\t\tdraw(off, \"\\n\")\n\t\t\t//\tnew line\n\t\t\tdraw(off, \"\\n\")\n\t\t}\n\t}(vs)\n}", "func (self *GameObjectCreator) Graphics1O(x int) *Graphics{\n return &Graphics{self.Object.Call(\"graphics\", x)}\n}", "func (debugging *debuggingOpenGL) DrawElements(mode uint32, count int32, elementType uint32, indices uintptr) {\n\tdebugging.recordEntry(\"DrawElements\", mode, count, elementType, indices)\n\tdebugging.gl.DrawElements(mode, count, elementType, indices)\n\tdebugging.recordExit(\"DrawElements\")\n}", "func (render *Renderer_impl)Unmap() fundations.Result{\n\n}", "func render(ctx Config, com Component, gfx *dot.Graph) *dot.Node {\n\n\timg := iconPath(ctx, com)\n\n\tif fc := strings.TrimSpace(com.FontColor); len(fc) == 0 {\n\t\tcom.FontColor = \"#000000ff\"\n\t}\n\n\tif imp := strings.TrimSpace(com.Impl); len(imp) == 0 {\n\t\tcom.Impl = \"&nbsp;\"\n\t}\n\n\tvar sb strings.Builder\n\tsb.WriteString(`<table border=\"0\" cellborder=\"0\">`)\n\tif ctx.showImpl {\n\t\tfmt.Fprintf(&sb, `<tr><td><font point-size=\"8\">%s</font></td></tr>`, com.Impl)\n\t}\n\n\tsb.WriteString(\"<tr>\")\n\tfmt.Fprintf(&sb, `<td fixedsize=\"true\" width=\"50\" height=\"50\"><img src=\"%s\" /></td>`, img)\n\tsb.WriteString(\"</tr>\")\n\n\tlabel := \"&nbsp;\"\n\tif s := strings.TrimSpace(com.Label); len(s) > 0 {\n\t\tlabel = s\n\t}\n\tfmt.Fprintf(&sb, `<tr><td><font point-size=\"7\">%s</font></td></tr>`, label)\n\tsb.WriteString(\"</table>\")\n\n\treturn node.New(gfx, com.ID,\n\t\tnode.Label(sb.String(), true),\n\t\tnode.FillColor(\"transparent\"),\n\t\tnode.Shape(\"plain\"),\n\t)\n}", "func (cont *tuiApplicationController) drawView() {\n\tcont.Sync.Lock()\n\tif !cont.Changed || cont.TuiFileReaderWorker == nil {\n\t\tcont.Sync.Unlock()\n\t\treturn\n\t}\n\tcont.Sync.Unlock()\n\n\t// reset the elements by clearing out every one\n\ttviewApplication.QueueUpdateDraw(func() {\n\t\tfor _, t := range displayResults {\n\t\t\tt.Title.SetText(\"\")\n\t\t\tt.Body.SetText(\"\")\n\t\t\tt.SpacerOne.SetText(\"\")\n\t\t\tt.SpacerTwo.SetText(\"\")\n\t\t\tresultsFlex.ResizeItem(t.Body, 0, 0)\n\t\t}\n\t})\n\n\tcont.Sync.Lock()\n\tresultsCopy := make([]*FileJob, len(cont.Results))\n\tcopy(resultsCopy, cont.Results)\n\tcont.Sync.Unlock()\n\n\t// rank all results\n\t// then go and get the relevant portion for display\n\trankResults(int(cont.TuiFileReaderWorker.GetFileCount()), resultsCopy)\n\tdocumentTermFrequency := calculateDocumentTermFrequency(resultsCopy)\n\n\t// after ranking only get the details for as many as we actually need to\n\t// cut down on processing\n\tif len(resultsCopy) > len(displayResults) {\n\t\tresultsCopy = resultsCopy[:len(displayResults)]\n\t}\n\n\t// We use this to swap out the highlights after we escape to ensure that we don't escape\n\t// out own colours\n\tmd5Digest := md5.New()\n\tfmtBegin := hex.EncodeToString(md5Digest.Sum([]byte(fmt.Sprintf(\"begin_%d\", makeTimestampNano()))))\n\tfmtEnd := hex.EncodeToString(md5Digest.Sum([]byte(fmt.Sprintf(\"end_%d\", makeTimestampNano()))))\n\n\t// go and get the codeResults the user wants to see using selected as the offset to display from\n\tvar codeResults []codeResult\n\tfor i, res := range resultsCopy {\n\t\tif i >= cont.Offset {\n\t\t\tsnippets := extractRelevantV3(res, documentTermFrequency, int(SnippetLength), \"…\")[0]\n\n\t\t\t// now that we have the relevant portion we need to get just the bits related to highlight it correctly\n\t\t\t// which this method does. It takes in the snippet, we extract and all of the locations and then returns just\n\t\t\tl := getLocated(res, snippets)\n\t\t\tcoloredContent := str.HighlightString(snippets.Content, l, fmtBegin, fmtEnd)\n\t\t\tcoloredContent = tview.Escape(coloredContent)\n\n\t\t\tcoloredContent = strings.Replace(coloredContent, fmtBegin, \"[red]\", -1)\n\t\t\tcoloredContent = strings.Replace(coloredContent, fmtEnd, \"[white]\", -1)\n\n\t\t\tcodeResults = append(codeResults, codeResult{\n\t\t\t\tTitle: res.Location,\n\t\t\t\tContent: coloredContent,\n\t\t\t\tScore: res.Score,\n\t\t\t\tLocation: res.Location,\n\t\t\t})\n\t\t}\n\t}\n\n\t// render out what the user wants to see based on the results that have been chosen\n\ttviewApplication.QueueUpdateDraw(func() {\n\t\tfor i, t := range codeResults {\n\t\t\tdisplayResults[i].Title.SetText(fmt.Sprintf(\"[fuchsia]%s (%f)[-:-:-]\", t.Title, t.Score))\n\t\t\tdisplayResults[i].Body.SetText(t.Content)\n\t\t\tdisplayResults[i].Location = t.Location\n\n\t\t\t//we need to update the item so that it displays everything we have put in\n\t\t\tresultsFlex.ResizeItem(displayResults[i].Body, len(strings.Split(t.Content, \"\\n\")), 0)\n\t\t}\n\t})\n\n\t// we can only set that nothing\n\tcont.Changed = false\n}", "func (ctx *APIContext) Render(status int, title string, obj interface{}) {\n\tctx.JSON(status, map[string]interface{}{\n\t\t\"message\": title,\n\t\t\"status\": status,\n\t\t\"resource\": obj,\n\t})\n}", "func (a ArithmeticPage) Render(w http.ResponseWriter, req *http.Request) {\n\tRenderPage(a, w, req, true)\n}", "func AgeSpout(tuple []interface{}, result *[]interface{}, variables *[]interface{}) error {\n\t// Variables\n\tvar counterMap map[string]interface{}\n\tvar idArray interface{}\n\tvar ageArray interface{}\n\n\tif (len(*variables) == 0) {\n\t\tcounterMap = make(map[string]interface{})\n\t\t*variables = append(*variables, counterMap)\n\t\tcounterMap[\"counter\"] = float64(0)\n\n\t\tfile, _ := os.Open(\"data.json\")\n\t\tdefer file.Close()\n\n\t\tb, _ := ioutil.ReadAll(file)\n\t\tvar object interface{}\n\t\tjson.Unmarshal(b, &object)\n\t\tobjectMap := object.(map[string]interface{})\n\t\tidArray = objectMap[\"id\"].([]interface{})\n\t\tageArray = objectMap[\"age\"].([]interface{})\n\n\t\t*variables = append(*variables, idArray)\n\t\t*variables = append(*variables, ageArray)\n\t}\n\tcounterMap = (*variables)[0].(map[string]interface{})\n\tidArray = (*variables)[1]\n\tageArray = (*variables)[2]\n\n\t// Logic\n\tif counterMap[\"counter\"].(float64) < 1000 {\n\t\t*result = []interface{}{idArray.([]interface{})[int(counterMap[\"counter\"].(float64))], ageArray.([]interface{})[int(counterMap[\"counter\"].(float64))]}\n\t\tcounterMap[\"counter\"] = counterMap[\"counter\"].(float64) + 1\n\t}\n\n\t// // Logic\n\t// if counterMap[\"counter\"].(float64) < 800 {\n\t// \t*result = []interface{}{strconv.Itoa(int(counterMap[\"counter\"].(float64))), strconv.Itoa(int(counterMap[\"counter\"].(float64)) + 20)}\n\t// \tcounterMap[\"counter\"] = counterMap[\"counter\"].(float64) + 1\n\t// }\n\n\ttime.Sleep(1 * time.Millisecond)\n\n\t// Return value\n\tif (len(*result) > 0) {\n\t\tlog.Printf(\"Age Spout Emit (%v)\\n\", *result)\n\t\treturn nil\n\t} else {\n\t\treturn errors.New(\"next tuple is nil\")\n\t}\n}", "func (self *Graphics) _renderWebGLI(args ...interface{}) {\n self.Object.Call(\"_renderWebGL\", args)\n}", "func (self *Tween) RepeatCounter() int{\n return self.Object.Get(\"repeatCounter\").Int()\n}", "func (c *Context) RenderDrawableList() {\n\t// Re-bind last texture and shader in case another context had overridden them\n\tif c.currentTexture != nil {\n\t\tgl.BindTexture(gl.TEXTURE_2D, c.currentTexture.id)\n\t}\n\tif c.currentShaderProgram != nil {\n\t\tgl.UseProgram(c.currentShaderProgram.id)\n\t}\n\n\tfor _, v := range c.primitivesToDraw {\n\t\tfor _, drawable := range v {\n\t\t\tc.BindTexture(drawable.Texture())\n\t\t\tshader := drawable.Shader()\n\t\t\tc.BindShader(shader)\n\t\t\t// TODO this should be done only once per frame via uniform buffers\n\t\t\tshader.SetUniform(\"mProjection\", &c.projectionMatrix)\n\t\t\tdrawable.DrawInBatch(c)\n\t\t}\n\t}\n}", "func TransformFeedbackVaryings(program uint32, count int32, varyings **uint8, bufferMode uint32) {\n\tC.glowTransformFeedbackVaryings(gpTransformFeedbackVaryings, (C.GLuint)(program), (C.GLsizei)(count), (**C.GLchar)(unsafe.Pointer(varyings)), (C.GLenum)(bufferMode))\n}", "func TransformFeedbackVaryings(program uint32, count int32, varyings **uint8, bufferMode uint32) {\n\tC.glowTransformFeedbackVaryings(gpTransformFeedbackVaryings, (C.GLuint)(program), (C.GLsizei)(count), (**C.GLchar)(unsafe.Pointer(varyings)), (C.GLenum)(bufferMode))\n}", "func (f *fast) RenderKeypoints() *image.RGBA {\n kpcolor := color.RGBA{0,255,0,255}\n img := ConvertToColor(f.image)\n for i := 0; i < len(f.keypoints); i++ {\n point := f.keypoints[i].point\n img.Set(point.X, point.Y, kpcolor)\n }\n return img\n}", "func MultiDrawElementsBaseVertex(mode uint32, count *int32, xtype uint32, indices *unsafe.Pointer, drawcount int32, basevertex *int32) {\n C.glowMultiDrawElementsBaseVertex(gpMultiDrawElementsBaseVertex, (C.GLenum)(mode), (*C.GLsizei)(unsafe.Pointer(count)), (C.GLenum)(xtype), indices, (C.GLsizei)(drawcount), (*C.GLint)(unsafe.Pointer(basevertex)))\n}", "func DrawElements(mode uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n\tC.glowDrawElements(gpDrawElements, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices)\n}", "func DrawElements(mode uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n\tC.glowDrawElements(gpDrawElements, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices)\n}", "func (vao *VAO) Render() {\n\tgl.BindVertexArray(vao.handle)\n\tif vao.indexBuffer != nil {\n\t\tgl.BindBuffer(gl.ELEMENT_ARRAY_BUFFER, vao.indexBuffer.GetHandle())\n\t\tgl.DrawElements(vao.mode, vao.indexBuffer.Len(), gl.UNSIGNED_SHORT, nil)\n\t\tgl.BindBuffer(gl.ELEMENT_ARRAY_BUFFER, 0)\n\t} else {\n\t\tgl.DrawArrays(vao.mode, 0, vao.vertexBuffers[0].Len())\n\t}\n\tgl.BindVertexArray(0)\n}" ]
[ "0.53467345", "0.52888364", "0.50767916", "0.5061459", "0.50110304", "0.49880037", "0.49360347", "0.49106398", "0.4893051", "0.48858562", "0.48646283", "0.48580134", "0.4843767", "0.4843767", "0.48125756", "0.48003402", "0.4795453", "0.47788283", "0.47759438", "0.4756125", "0.47555673", "0.47540337", "0.47469518", "0.47400573", "0.47234765", "0.47194645", "0.471153", "0.46913764", "0.46887818", "0.46851787", "0.46837643", "0.4676611", "0.4671605", "0.46713808", "0.4667198", "0.46637538", "0.4646873", "0.4629762", "0.46212426", "0.46180034", "0.4586247", "0.45848694", "0.45812926", "0.45715788", "0.45715788", "0.45664537", "0.45593923", "0.45554528", "0.45543572", "0.4543119", "0.4534229", "0.45332855", "0.4525459", "0.4524439", "0.45233467", "0.45220363", "0.4518973", "0.45070034", "0.45068172", "0.45064577", "0.45026866", "0.44935054", "0.44888443", "0.4488641", "0.44855872", "0.4479895", "0.4478667", "0.44729713", "0.44702333", "0.4459574", "0.44464844", "0.4438717", "0.4436384", "0.44283757", "0.44238108", "0.44164205", "0.44159892", "0.44106445", "0.43978897", "0.43965226", "0.4393471", "0.43932733", "0.43897742", "0.43835187", "0.4382831", "0.43811944", "0.43783203", "0.4374866", "0.43687078", "0.43685573", "0.4368138", "0.43680793", "0.43546122", "0.43532243", "0.43451202", "0.43451202", "0.43434975", "0.43402886", "0.43393657", "0.43393657", "0.43380144" ]
0.0
-1
render primitives using a count derived from a specifed stream of a transform feedback object
func DrawTransformFeedbackStream(mode uint32, id uint32, stream uint32) { C.glowDrawTransformFeedbackStream(gpDrawTransformFeedbackStream, (C.GLenum)(mode), (C.GLuint)(id), (C.GLuint)(stream)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func (e *rawData) Render(w io.Writer) (int, error) { return w.Write([]byte(e.content)) }", "func (rf RendererFunc) Render(w io.Writer, v interface{}) error { return rf(w, v) }", "func render(fset *token.FileSet, x interface{}) string {\n\tvar buf bytes.Buffer\n\tif err := printer.Fprint(&buf, fset, x); err != nil {\n\t\tpanic(err)\n\t}\n\treturn buf.String()\n}", "func render(fset *token.FileSet, x interface{}) string {\n\tvar buf bytes.Buffer\n\tif err := printer.Fprint(&buf, fset, x); err != nil {\n\t\tpanic(err)\n\t}\n\treturn buf.String()\n}", "func Count() Stream {\n return &count{0, 1}\n}", "func (sr scoresRenderer) Render() string {\n\tbuffer := bytes.Buffer{}\n\tlast := len(sr.scores) - 1\n\tfor i, score := range sr.scores {\n\t\tbuffer.WriteString(fmt.Sprintf(\"%d\", score))\n\t\tif i != last {\n\t\t\tbuffer.WriteString(\" / \")\n\t\t}\n\t}\n\treturn buffer.String()\n}", "func (v Binary) Render(i, width int, baseStyle lipgloss.Style) string {\n\tw := dataWidth(width)\n\t_, err := v.Seek(int64(i*w), io.SeekStart)\n\tif err != nil {\n\t\treturn baseStyle.Blink(true).Render(err.Error())\n\t}\n\tif len(v.b) != w {\n\t\tv.b = make([]byte, w)\n\t}\n\tn, err := v.Read(v.b)\n\tif err != nil && !errors.Is(err, io.EOF) {\n\t\treturn baseStyle.Blink(true).Render(err.Error())\n\t}\n\ts := fmt.Sprintf(\"% X%s \", v.b[0:n], strings.Repeat(\" \", w-n))\n\tvar x strings.Builder\n\tfor i := 0; i < n; i++ {\n\t\tif unicode.IsPrint(rune(v.b[i])) {\n\t\t\tx.WriteRune(rune(v.b[i]))\n\t\t} else {\n\t\t\tx.WriteRune('.')\n\t\t}\n\t}\n\treturn baseStyle.Render(s + x.String())\n}", "func (p *Processor) Render() vdom.Element {\n\tmaxConnectors := p.ProcessorDefinition.MaxConnectors()\n\tprocName := p.ProcessorDefinition.Name\n\tprocDefName, procInputs, procOutputs, procParameters := p.ProcessorDefinition.Processor.Definition()\n\tif len(procName) == 0 {\n\t\tprocName = procDefName\n\t}\n\n\tprocWidth := procDefaultWidth\n\tprocHeight := (maxConnectors + 2 + len(procParameters)) * procConnWidth * 2\n\n\tcustomRenderDimentions, ok := p.ProcessorDefinition.Processor.(customRenderDimentions)\n\tif ok {\n\t\tprocWidth, procHeight = customRenderDimentions.CustomRenderDimentions()\n\t}\n\n\tprocNameLabel := vdom.MakeElement(\"text\",\n\t\t\"font-family\", \"sans-serif\",\n\t\t\"text-anchor\", \"middle\",\n\t\t\"alignment-baseline\", \"hanging\",\n\t\t\"font-size\", 10,\n\t\t\"x\", p.ProcessorDefinition.X+procWidth/2,\n\t\t\"y\", p.ProcessorDefinition.Y+4,\n\t\tvdom.MakeTextElement(procName),\n\t)\n\tprocLine := vdom.MakeElement(\"line\",\n\t\t\"stroke\", \"black\",\n\t\t\"x1\", float64(p.ProcessorDefinition.X)+0.5,\n\t\t\"y1\", float64(p.ProcessorDefinition.Y)+16+0.5,\n\t\t\"x2\", float64(p.ProcessorDefinition.X)+float64(procWidth)+0.5,\n\t\t\"y2\", float64(p.ProcessorDefinition.Y)+16+0.5,\n\t)\n\n\tinConnectors := []vdom.Element{}\n\tfor i := 0; i < len(procInputs); i++ {\n\t\tx, y := p.GetConnectorPoint(procWidth, true, i)\n\t\tconnector := vdom.MakeElement(\"rect\",\n\t\t\t\"id\", procName+\":inconn:\"+strconv.Itoa(i),\n\t\t\t\"x\", x-procConnWidth/2,\n\t\t\t\"y\", y-procConnWidth/2,\n\t\t\t\"width\", procConnWidth,\n\t\t\t\"height\", procConnWidth,\n\t\t\t\"stroke\", \"black\",\n\t\t\t\"fill\", \"none\",\n\t\t\t\"pointer-events\", \"all\",\n\t\t\t\"cursor\", \"crosshair\",\n\t\t\tvdom.MakeEventHandler(vdom.MouseDown, p.makeConnectorEventHandler(true, i)),\n\t\t\tvdom.MakeEventHandler(vdom.MouseMove, p.makeConnectorEventHandler(true, i)),\n\t\t)\n\t\tinConnectors = append(inConnectors, connector)\n\n\t\tlabel := vdom.MakeElement(\"text\",\n\t\t\t\"font-family\", \"sans-serif\",\n\t\t\t\"text-anchor\", \"start\",\n\t\t\t\"alignment-baseline\", \"middle\",\n\t\t\t\"font-size\", 10,\n\t\t\t\"x\", x+(procConnWidth/2+2),\n\t\t\t\"y\", y,\n\t\t\tvdom.MakeTextElement(procInputs[i]),\n\t\t)\n\t\tinConnectors = append(inConnectors, label)\n\t}\n\n\toutConnectors := []vdom.Element{}\n\tfor i := 0; i < len(procOutputs); i++ {\n\t\tx, y := p.GetConnectorPoint(procWidth, false, i)\n\t\tconnector := vdom.MakeElement(\"rect\",\n\t\t\t\"id\", procName+\":outconn:\"+strconv.Itoa(i),\n\t\t\t\"x\", x-procConnWidth/2,\n\t\t\t\"y\", y-procConnWidth/2,\n\t\t\t\"width\", procConnWidth,\n\t\t\t\"height\", procConnWidth,\n\t\t\t\"stroke\", \"black\",\n\t\t\t\"fill\", \"none\",\n\t\t\t\"pointer-events\", \"all\",\n\t\t\t\"cursor\", \"crosshair\",\n\t\t\tvdom.MakeEventHandler(vdom.MouseDown, p.makeConnectorEventHandler(false, i)),\n\t\t\tvdom.MakeEventHandler(vdom.MouseMove, p.makeConnectorEventHandler(false, i)),\n\t\t)\n\t\toutConnectors = append(outConnectors, connector)\n\n\t\tlabel := vdom.MakeElement(\"text\",\n\t\t\t\"font-family\", \"sans-serif\",\n\t\t\t\"text-anchor\", \"end\",\n\t\t\t\"alignment-baseline\", \"middle\",\n\t\t\t\"font-size\", 10,\n\t\t\t\"x\", x-(procConnWidth/2+4),\n\t\t\t\"y\", y,\n\t\t\tvdom.MakeTextElement(procOutputs[i]),\n\t\t)\n\t\toutConnectors = append(outConnectors, label)\n\t}\n\n\tparameters := []vdom.Element{}\n\tfor i := 0; i < len(procParameters); i++ {\n\t\t_, y := p.GetConnectorPoint(procWidth, true, i+maxConnectors)\n\n\t\twidth := procWidth - ((procConnWidth + 2) * 2)\n\t\tlevelValue := strconv.FormatFloat(float64(procParameters[i].Value), 'f', -1, 32)\n\t\tlevelWidth := int(float32(width) * (procParameters[i].Value / procParameters[i].Max))\n\t\tlevelFactor := float32(width) / procParameters[i].Max\n\n\t\tlevel := vdom.MakeElement(\"rect\",\n\t\t\t\"id\", procName+\":parameter:\"+strconv.Itoa(i),\n\t\t\t\"x\", p.ProcessorDefinition.X+procConnWidth+2,\n\t\t\t\"y\", y-2,\n\t\t\t\"width\", levelWidth,\n\t\t\t\"height\", procConnWidth+4,\n\t\t\t\"stroke\", \"none\",\n\t\t\t\"fill\", \"cyan\",\n\t\t\t\"pointer-events\", \"none\",\n\t\t)\n\t\tparameters = append(parameters, level)\n\n\t\tbound := vdom.MakeElement(\"rect\",\n\t\t\t\"id\", procName+\":parameter:\"+strconv.Itoa(i),\n\t\t\t\"x\", p.ProcessorDefinition.X+procConnWidth+2,\n\t\t\t\"y\", y-2,\n\t\t\t\"width\", width,\n\t\t\t\"height\", procConnWidth+4,\n\t\t\t\"stroke\", \"black\",\n\t\t\t\"fill\", \"none\",\n\t\t\t\"pointer-events\", \"all\",\n\t\t\t\"cursor\", \"crosshair\",\n\t\t\tvdom.MakeEventHandler(vdom.MouseDown, p.makeParameterEventHandler(i, levelFactor)),\n\t\t\tvdom.MakeEventHandler(vdom.MouseUp, p.makeParameterEventHandler(i, levelFactor)),\n\t\t\tvdom.MakeEventHandler(vdom.MouseMove, p.makeParameterEventHandler(i, levelFactor)),\n\t\t\tvdom.MakeEventHandler(vdom.MouseLeave, p.makeParameterEventHandler(i, levelFactor)),\n\t\t\tvdom.MakeElement(\"title\", vdom.MakeTextElement(levelValue)),\n\t\t)\n\t\tparameters = append(parameters, bound)\n\n\t\tname := vdom.MakeElement(\"text\",\n\t\t\t\"font-family\", \"sans-serif\",\n\t\t\t\"text-anchor\", \"middle\",\n\t\t\t\"alignment-baseline\", \"hanging\",\n\t\t\t\"font-size\", 10,\n\t\t\t\"x\", p.ProcessorDefinition.X+(procWidth/2),\n\t\t\t\"y\", y,\n\t\t\tvdom.MakeTextElement(procParameters[i].Name))\n\t\tparameters = append(parameters, name)\n\t}\n\n\telement := vdom.MakeElement(\"g\",\n\t\tvdom.MakeElement(\"rect\",\n\t\t\t\"id\", procName,\n\t\t\t\"x\", p.ProcessorDefinition.X,\n\t\t\t\"y\", p.ProcessorDefinition.Y,\n\t\t\t\"width\", procWidth,\n\t\t\t\"height\", procHeight,\n\t\t\t\"stroke\", \"black\",\n\t\t\t\"fill\", \"white\",\n\t\t\t\"cursor\", \"pointer\",\n\t\t\tvdom.MakeEventHandler(vdom.MouseDown, p.processorEventHandler),\n\t\t\tvdom.MakeEventHandler(vdom.MouseUp, p.processorEventHandler),\n\t\t\tvdom.MakeEventHandler(vdom.MouseMove, p.processorEventHandler),\n\t\t\tvdom.MakeEventHandler(vdom.ContextMenu, p.processorEventHandler),\n\t\t),\n\t\tprocNameLabel,\n\t\tprocLine,\n\t\tinConnectors,\n\t\toutConnectors,\n\t\tparameters,\n\t)\n\n\tcustom, ok := p.ProcessorDefinition.Processor.(vdom.Component)\n\tif ok {\n\t\telement.AppendChild(vdom.MakeElement(\"g\",\n\t\t\t\"transform\", \"translate(\"+strconv.Itoa(p.ProcessorDefinition.X)+\",\"+strconv.Itoa(p.ProcessorDefinition.Y)+\")\",\n\t\t\tcustom,\n\t\t))\n\t}\n\n\treturn element\n}", "func (c *regularResourceComponent) Render(out io.Writer) (numLines int, err error) {\n\tc.mu.Lock()\n\tdefer c.mu.Unlock()\n\n\tcomponents := cfnLineItemComponents(c.description, c.separator, c.statuses, c.stopWatch, c.padding)\n\treturn renderComponents(out, components)\n}", "func (ren *RenderComponent) generateBufferContent() []float32 {\n\tscaleX := ren.scale.X\n\tscaleY := ren.scale.Y\n\trotation := float32(0.0)\n\ttransparency := float32(1.0)\n\tc := ren.Color\n\n\tfx := float32(0)\n\tfy := float32(0)\n\tfx2 := ren.drawable.Width()\n\tfy2 := ren.drawable.Height()\n\n\tif scaleX != 1 || scaleY != 1 {\n\t\t//fx *= scaleX\n\t\t//fy *= scaleY\n\t\tfx2 *= scaleX\n\t\tfy2 *= scaleY\n\t}\n\n\tp1x := fx\n\tp1y := fy\n\tp2x := fx\n\tp2y := fy2\n\tp3x := fx2\n\tp3y := fy2\n\tp4x := fx2\n\tp4y := fy\n\n\tvar x1 float32\n\tvar y1 float32\n\tvar x2 float32\n\tvar y2 float32\n\tvar x3 float32\n\tvar y3 float32\n\tvar x4 float32\n\tvar y4 float32\n\n\tif rotation != 0 {\n\t\trot := rotation * (math.Pi / 180.0)\n\n\t\tcos := math.Cos(rot)\n\t\tsin := math.Sin(rot)\n\n\t\tx1 = cos*p1x - sin*p1y\n\t\ty1 = sin*p1x + cos*p1y\n\n\t\tx2 = cos*p2x - sin*p2y\n\t\ty2 = sin*p2x + cos*p2y\n\n\t\tx3 = cos*p3x - sin*p3y\n\t\ty3 = sin*p3x + cos*p3y\n\n\t\tx4 = x1 + (x3 - x2)\n\t\ty4 = y3 - (y2 - y1)\n\t} else {\n\t\tx1 = p1x\n\t\ty1 = p1y\n\n\t\tx2 = p2x\n\t\ty2 = p2y\n\n\t\tx3 = p3x\n\t\ty3 = p3y\n\n\t\tx4 = p4x\n\t\ty4 = p4y\n\t}\n\n\tcolorR, colorG, colorB, _ := c.RGBA()\n\n\tred := colorR\n\tgreen := colorG << 8\n\tblue := colorB << 16\n\talpha := uint32(transparency*255.0) << 24\n\n\ttint := math.Float32frombits((alpha | blue | green | red) & 0xfeffffff)\n\n\tu, v, u2, v2 := ren.drawable.View()\n\n\treturn []float32{x1, y1, u, v, tint, x4, y4, u2, v, tint, x3, y3, u2, v2, tint, x2, y2, u, v2, tint}\n}", "func (r *JSONRenderer) Render(out io.Writer, st *papers.Stats, unread, read papers.AggPapers) {\n\tr.render(out, st, unread, read)\n}", "func Render(s api.Session, renderAs RenderName, value dgo.Value, out io.Writer) {\n\t// Convert value to rich data format without references\n\tdedupStream := func(value dgo.Value, consumer streamer.Consumer) {\n\t\topts := streamer.DefaultOptions()\n\t\topts.DedupLevel = streamer.NoDedup\n\t\tser := streamer.New(s.AliasMap(), opts)\n\t\tser.Stream(value, consumer)\n\t}\n\n\tswitch renderAs {\n\tcase JSON:\n\t\tif value.Equals(vf.Nil) {\n\t\t\tutil.WriteString(out, \"null\\n\")\n\t\t} else {\n\t\t\tdedupStream(value, streamer.JSON(out))\n\t\t\tutil.WriteByte(out, '\\n')\n\t\t}\n\n\tcase YAML:\n\t\tif value.Equals(vf.Nil) {\n\t\t\tutil.WriteString(out, \"\\n\")\n\t\t} else {\n\t\t\tdc := streamer.DataCollector()\n\t\t\tdedupStream(value, dc)\n\t\t\tbs, err := yaml.Marshal(dc.Value())\n\t\t\tif err != nil {\n\t\t\t\tpanic(err)\n\t\t\t}\n\t\t\tutil.WriteString(out, string(bs))\n\t\t}\n\tcase Binary:\n\t\tbi := vf.New(typ.Binary, value).(dgo.Binary)\n\t\t_, err := out.Write(bi.GoBytes())\n\t\tif err != nil {\n\t\t\tpanic(err)\n\t\t}\n\tcase Text:\n\t\tutil.Fprintln(out, value)\n\tdefault:\n\t\tpanic(fmt.Errorf(`unknown rendering '%s'`, renderAs))\n\t}\n}", "func (r *Renderer) Render() {\n\tsx, sz, sy := r.c.Bounds()\n\tsxf := float64(sx - 1)\n\tsyf := float64(sy - 1)\n\tszf := float64(sz - 1)\n\tfor z := 0; z < sz; z++ {\n\t\tfor y := 0; y < sy; y++ {\n\t\t\tfor x := 0; x < sx; x++ {\n\t\t\t\tvar lr, lg, lb, _ uint32\n\t\t\t\tn := uint32(0)\n\t\t\t\tfor _, o := range r.objects {\n\t\t\t\t\tr, g, b, _ := o.At(float64(x)/sxf, float64(y)/syf, float64(z)/szf).RGBA()\n\t\t\t\t\tlr += r >> 8\n\t\t\t\t\tlg += g >> 8\n\t\t\t\t\tlb += b >> 8\n\t\t\t\t\tn++\n\t\t\t\t}\n\t\t\t\tr.c.Set(x, y, z, color.RGBA{uint8(lr/n), uint8(lg/n), uint8(lb/n), 255})\n\t\t\t}\n\t\t}\n\t}\n\tr.c.Render()\n}", "func WriteCount(buffer []byte, offset int, value byte, valueCount int) {\n for i := 0; i < valueCount; i++ {\n buffer[offset + i] = value\n }\n}", "func (self *StraightLineTrack) Render(render chan Object) {\n\tfor _, val := range self.Childs() {\n\t\trender <- val\n\t}\n}", "func (a *World) Render(p *pic.Pic) *World {\n\th, w := p.H, p.W\n\tfh, fw := float64(h), float64(w)\n\tcx := vec.New(fw*a.Ratio/fh, 0, 0)\n\tcy := vec.Mult(vec.Norm(vec.Cross(cx, a.Cam.Direct)), a.Ratio)\n\tsample := a.Sample / 4\n\tinv := 1.0 / float64(sample)\n\n\tfmt.Printf(\"w: %v, h: %v, sample: %v, actual sample: %v, thread: %v, cpu: %v\\n\", w, h, a.Sample, sample*4, a.Thread, a.Core)\n\tbar := pb.StartNew(h * w)\n\tbar.SetRefreshRate(1000 * time.Millisecond)\n\n\truntime.GOMAXPROCS(a.Core)\n\tch := make(chan renderData, a.Thread)\n\twg := sync.WaitGroup{}\n\twg.Add(a.Thread)\n\n\tfor tid := 0; tid < a.Thread; tid++ {\n\t\tgo func() {\n\t\t\tfor {\n\t\t\t\tdata, ok := <-ch\n\t\t\t\tif !ok {\n\t\t\t\t\twg.Done()\n\t\t\t\t\treturn\n\t\t\t\t}\n\t\t\t\tsum, x, y := data.sum, data.x, data.y\n\t\t\t\tfor sy := 0.0; sy < 2.0; sy++ {\n\t\t\t\t\tfor sx := 0.0; sx < 2.0; sx++ {\n\t\t\t\t\t\tc := vec.NewZero()\n\t\t\t\t\t\tfor sp := 0; sp < sample; sp++ {\n\t\t\t\t\t\t\tccx := vec.Mult(cx, ((sx+0.5+gend())/2.0+x)/fw-0.5)\n\t\t\t\t\t\t\tccy := vec.Mult(cy, ((sy+0.5+gend())/2.0+y)/fh-0.5)\n\t\t\t\t\t\t\td := vec.Add(vec.Add(ccx, ccy), a.Cam.Direct)\n\t\t\t\t\t\t\tr := ray.New(vec.Add(a.Cam.Origin, vec.Mult(d, 130)), vec.Norm(d))\n\t\t\t\t\t\t\tc.Add(vec.Mult(a.trace(r, 0), inv))\n\t\t\t\t\t\t}\n\t\t\t\t\t\tsum.Add(vec.Mult(vec.New(pic.Clamp(c.X), pic.Clamp(c.Y), pic.Clamp(c.Z)), 0.25))\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tbar.Add(1)\n\t\t\t}\n\t\t}()\n\t}\n\n\tfor y := 0; y < h; y++ {\n\t\tfor x := 0; x < w; x++ {\n\t\t\tch <- renderData{\n\t\t\t\tsum: &p.C[(h-y-1)*w+x],\n\t\t\t\tx: float64(x),\n\t\t\t\ty: float64(y),\n\t\t\t}\n\t\t}\n\t}\n\n\tclose(ch)\n\twg.Wait()\n\n\tbar.FinishPrint(\"Rendering completed\")\n\treturn a\n}", "func CountPrintf(f string, vals ...interface{}) {\n\tcount++\n\tfmt.Printf(fmt.Sprintf(\"%d - \", count)+f, vals...)\n}", "func (c *stackComponent) Render(out io.Writer) (numLines int, err error) {\n\tc.mu.Lock()\n\tdefer c.mu.Unlock()\n\n\treturn renderComponents(out, c.resources)\n}", "func TransformFeedbackVaryings(program uint32, count int32, varyings **int8, bufferMode uint32) {\n C.glowTransformFeedbackVaryings(gpTransformFeedbackVaryings, (C.GLuint)(program), (C.GLsizei)(count), (**C.GLchar)(unsafe.Pointer(varyings)), (C.GLenum)(bufferMode))\n}", "func Render(r *sdl.Renderer, w *World) {\n\twidth := float64(r.GetViewport().W)\n\theight := float64(r.GetViewport().H)\n\n\trenderedVertices := [][2]int{}\n\n\tfor _, obj := range w.Objects {\n\t\tfor _, vertex := range obj.Geometry.Vertices {\n\t\t\trenderCoordinates := AsRelativeToSystem(w.ActiveCamera.ObjSys, ToSystem(obj.ObjSys, vertex.Pos))\n\n\t\t\tZ := Clamp(renderCoordinates.Z, 0.0001, math.NaN())\n\t\t\tratio := w.ActiveCamera.FocalLength / math.Abs(Z)\n\t\t\trenderX := ratio * renderCoordinates.X\n\t\t\trenderY := ratio * renderCoordinates.Y\n\n\t\t\tnormX, normY := NormalizeScreen(\n\t\t\t\twidth,\n\t\t\t\theight,\n\t\t\t\trenderX,\n\t\t\t\trenderY,\n\t\t\t)\n\n\t\t\trasterX := int(math.Floor(normX*width) + width/2)\n\t\t\trasterY := int(math.Floor(normY*height) + height/2)\n\n\t\t\trenderedVertices = append(renderedVertices, [2]int{rasterX, rasterY})\n\n\t\t\tDrawCircle(r, rasterX, rasterY, 5)\n\t\t}\n\t\tfor _, edge := range obj.Geometry.Edges {\n\t\t\tif len(renderedVertices) > edge.From && len(renderedVertices) > edge.To {\n\t\t\t\tr.DrawLine(\n\t\t\t\t\tint32(renderedVertices[edge.From][0]),\n\t\t\t\t\tint32(renderedVertices[edge.From][1]),\n\t\t\t\t\tint32(renderedVertices[edge.To][0]),\n\t\t\t\t\tint32(renderedVertices[edge.To][1]),\n\t\t\t\t)\n\t\t\t}\n\t\t}\n\t}\n\n\tr.Present()\n}", "func (t *textRender) Render(w io.Writer) (err error) {\n\tif len(t.Values) > 0 {\n\t\t_, err = fmt.Fprintf(w, t.Format, t.Values...)\n\t} else {\n\t\t_, err = io.WriteString(w, t.Format)\n\t}\n\treturn\n}", "func (o GroupContainerGpuOutput) Count() pulumi.IntPtrOutput {\n\treturn o.ApplyT(func(v GroupContainerGpu) *int { return v.Count }).(pulumi.IntPtrOutput)\n}", "func (c *ConnectionSPI) Render(pixels []RGBPixel) {\r\n\tlogFields := log.Fields{\"package\": logPkg, \"conn\": \"SPI\", \"func\": \"RenderLEDs\"}\r\n\tlog.WithFields(logFields).Infof(\"Render %d LEDs\", len(pixels))\r\n\t// Fix for Raspberry Pi 3 Model B+ (5.15.84-v7+)\r\n\t// Data signal seems to be splitted sending less than 11 LEDS\r\n\tif len(pixels) < 11 {\r\n\t\tpixels = append(pixels, []RGBPixel{{}, {}, {}, {}, {}, {}, {}, {}, {}, {}}...)\r\n\t}\r\n\tvar translatedRGBs []uint8\r\n\tfor _, pixel := range pixels {\r\n\r\n\t\tcolorData := GetColorData(pixel, c.FixSPI)\r\n\t\tlog.WithFields(logFields).Tracef(\"%08b\", pixel)\r\n\r\n\t\tfor _, c := range colorData {\r\n\t\t\ttranslatedRGBs = append(translatedRGBs, c)\r\n\t\t}\r\n\t}\r\n\r\n\tc.transfer(translatedRGBs)\r\n}", "func (s *Spinner) Render() error {\n\tif len(s.frames) == 0 {\n\t\treturn errors.New(\"no frames available to to render\")\n\t}\n\n\ts.step = s.step % len(s.frames)\n\tpreviousLen := len(s.previousFrame)\n\ts.previousFrame = fmt.Sprintf(\"%s%s\", s.separator, s.frames[s.step])\n\tnewLen := len(s.previousFrame)\n\n\t// We need to clean the previous message\n\tif previousLen > newLen {\n\t\tr := previousLen - newLen\n\t\tsuffix := strings.Repeat(\" \", r)\n\t\ts.previousFrame = s.previousFrame + suffix\n\t}\n\n\tfmt.Fprint(s.Writer, s.previousFrame)\n\ts.step++\n\treturn nil\n}", "func CountFrom(start, step int) Stream {\n return &count{start, step}\n}", "func (sh *ShaderStd) PostRender() error { return nil }", "func mapCount(itr Iterator, m *mapper) {\n\tn := 0\n\tfor k, _ := itr.Next(); k != 0; k, _ = itr.Next() {\n\t\tn++\n\t}\n\tm.emit(itr.Time(), float64(n))\n}", "func (c *cartridge) Render() {\n\tc.Cls()\n\tc.PrintAt(fmt.Sprintf(\"counter:%d\", c.counter), c.x, c.y)\n}", "func _EvtRender(\n\tcontext EvtHandle,\n\tfragment EvtHandle,\n\tflags EvtRenderFlag,\n\tbufferSize uint32,\n\tbuffer *byte,\n\tbufferUsed *uint32,\n\tpropertyCount *uint32,\n) error {\n\tr1, _, e1 := syscall.SyscallN(\n\t\tprocEvtRender.Addr(),\n\t\tuintptr(context),\n\t\tuintptr(fragment),\n\t\tuintptr(flags),\n\t\tuintptr(bufferSize),\n\t\tuintptr(unsafe.Pointer(buffer)), //nolint:gosec // G103: Valid use of unsafe call to pass buffer\n\t\tuintptr(unsafe.Pointer(bufferUsed)), //nolint:gosec // G103: Valid use of unsafe call to pass bufferUsed\n\t\tuintptr(unsafe.Pointer(propertyCount)), //nolint:gosec // G103: Valid use of unsafe call to pass propertyCount\n\t)\n\n\tvar err error\n\tif r1 == 0 {\n\t\tif e1 != 0 {\n\t\t\terr = errnoErr(e1)\n\t\t} else {\n\t\t\terr = syscall.EINVAL\n\t\t}\n\t}\n\treturn err\n}", "func DrawTransformFeedbackStreamInstanced(mode uint32, id uint32, stream uint32, instancecount int32) {\n C.glowDrawTransformFeedbackStreamInstanced(gpDrawTransformFeedbackStreamInstanced, (C.GLenum)(mode), (C.GLuint)(id), (C.GLuint)(stream), (C.GLsizei)(instancecount))\n}", "func CountAndSay(n int) string {\n\tres := \"1\"\n\tfor i := 0; i < n-1; i++ {\n\t\tres = translate(res)\n\t}\n\treturn res\n}", "func (ctx *Context) Render(bytes []byte) {\n\t//debug\n\t//fmt.Println(\"response msg = \", string(bytes))\n\tctx.Writer.WriteHeader(200)\n\t_, err := ctx.Writer.Write(bytes)\n\tif err != nil {\n\t\tpanic(err)\n\t}\n}", "func (c *Counter) Count(b []byte) {\n\tfor i := 0; i < len(b); i++ {\n\t\tswitch b[i] {\n\t\t// '\\' means to concat next line\n\t\tcase '\\\\':\n\t\t\t//len(b)-2 because len(b)-1 is \"\\n\", we take line-break into consideration\n\t\t\tif i == len(b)-1 || i == len(b)-2 {\n\t\t\t\tc.NextLineConcats = 1\n\t\t\t\tbreak\n\t\t\t}\n\t\tcase '{':\n\t\t\tc.CurlyBrackets++\n\t\tcase '}':\n\t\t\tc.CurlyBrackets--\n\t\tcase '(':\n\t\t\tc.Parentheses++\n\t\tcase ')':\n\t\t\tc.Parentheses--\n\t\tcase '[':\n\t\t\tc.SquareBrackets++\n\t\tcase ']':\n\t\t\tc.SquareBrackets--\n\t\t}\n\t}\n}", "func (e *tag) fastRender(w io.Writer, tag string, children []Element) (int, error) {\n\tif len(e.childData) == 0 {\n\t\t// Record the rendering into child data.\n\t\tbuf := new(bytes.Buffer)\n\t\t_, err := e.renderElement(buf, tag, children)\n\t\tif err != nil {\n\t\t\treturn 0, err\n\t\t}\n\t\te.childData = buf.Bytes()\n\t}\n\tn, err := w.Write(e.childData)\n\treturn n, err\n}", "func (g *Keyboard) Stream(samples []float64) {\n\tg.l.Lock()\n\tdefer g.l.Unlock()\n\n\tfor i := range samples {\n\t\tt := float64(g.totalSamples) / float64(g.sr)\n\t\tv := float64(0)\n\n\t\tfor _, w := range g.waves {\n\t\t\twaveV, _ := w(t)\n\t\t\tv += waveV\n\t\t}\n\t\tsamples[i] = v\n\t\tg.totalSamples++\n\t}\n\n\tt := float64(g.totalSamples) / float64(g.sr)\n\tnewWaves := []FiniteWaveFn{}\n\tfor _, w := range g.waves {\n\t\tif _, done := w(t); !done {\n\t\t\tnewWaves = append(newWaves, w)\n\t\t}\n\t}\n\tg.waves = newWaves\n}", "func emitCount() int {\n\tlogn := math.Log(float64(knownNodes.length()))\n\tmult := (lambda * logn) + 0.5\n\n\treturn int(mult)\n}", "func main() {\n\tctx := pipeliner.FirstError()\n\tsourceCh := source(ctx, 0, 9000)\n\tbatches := batchInts(ctx, 320, sourceCh)\n\tfor batch := range batches {\n\t\tfmt.Printf(\"received batch of length: %d\\n\", len(batch))\n\t}\n}", "func (r *ChromaRenderer) RenderHeader(w io.Writer, ast *blackfriday.Node) {}", "func Render(state *model.Model) time.Duration {\n\tt := time.Now()\n\n\trenderer.SetDrawColor(255, 255, 255, 255)\n\trenderer.FillRect(fullScreenRect)\n\n\tcurrentSurface, _ := window.GetSurface()\n\n\tl := layout.New(screenWidth, screenHeight)\n\n\tinstruments := l.Row(instrumentHeight)\n\tdistanceCell := instruments.Col(columnWidth)\n\tspeedCell := instruments.Col(columnWidth)\n\theadingCell := instruments.Col(columnWidth)\n\n\tRenderHeadingCell(state, currentSurface, headingCell)\n\tRenderDistanceCell(state, currentSurface, distanceCell)\n\tRenderSpeedCell(state, currentSurface, speedCell)\n\n\trenderer.SetDrawColor(255, 255, 255, 255)\n\n\t// waypoints 1 - 3\n\tif len(state.Book) > 0 {\n\t\t//TODO: breaks if there aren't Idx + 3 remaining\n\t\tfor idx, waypoint := range state.Book[state.Idx : state.Idx+3] {\n\t\t\ty := int32(instrumentHeight + idx*waypointHeight)\n\t\t\tbg := &sdl.Rect{0, y, int32(screenWidth), int32(waypointHeight)}\n\t\t\tr, g, b, _ := waypoint.Background.RGBA()\n\n\t\t\t// box\n\t\t\trenderer.SetDrawColor(uint8(r), uint8(g), uint8(b), 255)\n\t\t\trenderer.FillRect(bg)\n\n\t\t\t// distance\n\t\t\ttextBg := sdl.Color{uint8(r), uint8(g), uint8(b), 255}\n\t\t\ttextFg := sdl.Color{0, 0, 0, 255}\n\t\t\tif waypoint.Background == color.Black {\n\t\t\t\ttextFg = sdl.Color{255, 255, 255, 255}\n\t\t\t}\n\n\t\t\tdistanceFormat := \"%0.1f\"\n\t\t\tif (appcontext.GContext.NumAfterDecimal == 2) {\n\t\t\t\tdistanceFormat = \"%0.2f\"\n\t\t\t}\n\t\t\tdistance, _ := dinMedium144.RenderUTF8Shaded(strings.Replace(fmt.Sprintf(distanceFormat, waypoint.Distance), \".\", \",\", -1), textFg, textBg)\n\n\t\t\tdistRect := distance.ClipRect\n\t\t\tdistance.Blit(nil, currentSurface, &sdl.Rect{(columnWidth - distRect.W) / 2, bg.Y + (waypointHeight-distRect.H)/2, 0, 0})\n\t\t\tdistance.Free()\n\n\t\t\t// tulip and notes\n\t\t\tpair := getTulipNotesPair(state.Idx+idx, &waypoint)\n\n\t\t\tpair.tulip.Blit(nil, currentSurface, &sdl.Rect{columnWidth, bg.Y + (waypointHeight-TulipHeight)/2, 0, 0})\n\t\t\tpair.notes.Blit(nil, currentSurface, &sdl.Rect{columnWidth * 2, bg.Y + (waypointHeight-NotesHeight)/2, 0, 0})\n\n\t\t\t// divider\n\t\t\trenderer.SetDrawColor(0, 0, 0, 255)\n\t\t\tbg.H = dividerHeight\n\t\t\trenderer.FillRect(bg)\n\t\t}\n\t\t//TODO: draw divider even when no waypoints exist\n\t}\n\n\tgc := appcontext.GContext\n\tgm := appmanager.GAppManager\n\n\tmainWindowSurface := gc.MainSurface\n\tgm.Render(mainWindowSurface)\n\n\t// display frame\n\trenderer.Present()\n\n\t// ensure we wait at least frameDuration\n\tfpsDelay := frameDuration - time.Since(t)\n\treturn fpsDelay\n}", "func (h Hand) Render() string {\n\tbuffer := bytes.Buffer{}\n\tlast := len(h.Cards) - 1\n\tfor i, card := range h.Cards {\n\t\tbuffer.WriteString(card.Render())\n\t\tif i != last {\n\t\t\tbuffer.WriteString(\", \")\n\t\t}\n\t}\n\tbuffer.WriteString(fmt.Sprintf(\n\t\t\" (%s)\", scoresRenderer{h.Scores()}.Render(),\n\t))\n\treturn strings.Trim(buffer.String(), \" \")\n}", "func (self *CircularTrack) Render(render chan Object) {\n\trender <- self\n\tfor _, val := range self.Childs() {\n\t\trender <- val\n\t}\n}", "func (s *Source) Render() ([]byte, error) {\n\tvar ret bytes.Buffer\n\tfmt.Fprintf(&ret, \"<source>\")\n\tfmt.Fprintf(&ret, \"\\n @type forward\")\n\tfmt.Fprintf(&ret, \"\\n port %d\", s.port)\n\tfmt.Fprintf(&ret, \"\\n bind 0.0.0.0\")\n\tfmt.Fprintf(&ret, \"\\n</source>\")\n\n\treturn ret.Bytes(), nil\n}", "func (params complexPropertyConversionParameters) countArraysAndMapsInConversionContext() int {\n\tresult := 0\n\tfor _, t := range params.conversionContext {\n\t\tswitch t.(type) {\n\t\tcase *astmodel.MapType:\n\t\t\tresult += 1\n\t\tcase *astmodel.ArrayType:\n\t\t\tresult += 1\n\t\t}\n\t}\n\n\treturn result\n}", "func (tofu Tofu) Render(wr io.Writer, name string, obj interface{}) error {\n\tvar m data.Map\n\tif obj != nil {\n\t\tvar ok bool\n\t\tm, ok = data.New(obj).(data.Map)\n\t\tif !ok {\n\t\t\treturn fmt.Errorf(\"invalid data type. expected map/struct, got %T\", obj)\n\t\t}\n\t}\n\treturn tofu.NewRenderer(name).Execute(wr, m)\n}", "func renderInteger(f float64) string {\n\tif f > math.Nextafter(float64(math.MaxInt64), 0) {\n\t\treturn fmt.Sprintf(\"%d\", int64(math.MaxInt64))\n\t}\n\tif f < math.Nextafter(float64(math.MinInt64), 0) {\n\t\treturn fmt.Sprintf(\"%d\", int64(math.MinInt64))\n\t}\n\treturn fmt.Sprintf(\"%d\", int64(f))\n}", "func DrawTransformFeedbackStream(mode uint32, id uint32, stream uint32) {\n C.glowDrawTransformFeedbackStream(gpDrawTransformFeedbackStream, (C.GLenum)(mode), (C.GLuint)(id), (C.GLuint)(stream))\n}", "func (c *Canvas) Count() int {\n\treturn len(c.paint)\n}", "func (o *FactoryContainer) CountOutput() float64 {\n\tvar output float64 = 0.0\n\tfor i, _ := range o.Factories {\n\t\toutput = output + o.Factories[i].Production*o.Factories[i].ProductionModifier\n\t}\n\treturn output\n}", "func Transform(image io.Reader, extension string, numberOfShapes int, opts ...func() []string) (io.Reader, error) {\n\tvar args []string\n\n\tfor _, opt := range opts {\n\t\targs = append(args, opt()...)\n\t}\n\n\tinputTempFile, err := createTempFile(\"input_\", extension)\n\n\tif err != nil {\n\t\treturn nil, fmt.Errorf(\"primitive: failed to create temp input file:: %v\", err)\n\t}\n\n\toutputTempFile, err := createTempFile(\"output_\", extension)\n\n\tif err != nil {\n\t\treturn nil, fmt.Errorf(\"primitive: failed to create temp output file:: %v\", err)\n\t}\n\n\t// Read image\n\t_, err = io.Copy(inputTempFile, image)\n\n\tif err != nil {\n\t\treturn nil, fmt.Errorf(\"primitive: failed to copy temp input file:: %v\", err)\n\t}\n\n\t// Run primitive\n\tstdCombo, err := primitive(inputTempFile.Name(), outputTempFile.Name(), numberOfShapes, args...)\n\n\tif err != nil {\n\t\treturn nil, fmt.Errorf(\"primitive: failed to run the primitive command: %v, std combo: %s\", err, stdCombo)\n\t}\n\t// Read out into a reader, return reader and delete out\n\tb := bytes.NewBuffer(nil)\n\n\t_, err = io.Copy(b, outputTempFile)\n\n\tif err != nil {\n\t\treturn nil, fmt.Errorf(\"primitive: failed to copy temp output file:: %v\", err)\n\t}\n\n\treturn b, nil\n}", "func (h *HAProxyManager) render(ports []uint16) ([]byte, error) {\n\n\t// prepare the context\n\td := make([]templateContext, len(ports))\n\tfor i, port := range ports {\n\t\tif i == len(h.serviceAddrs) {\n\t\t\th.logger.Warnf(\"got port index %d, but only have %d service addrs. ports=%v serviceAddrs=%v\", i, len(h.serviceAddrs), ports, h.serviceAddrs)\n\t\t\tcontinue\n\t\t}\n\t\td[i] = templateContext{Port: port, Source: h.listenAddr, Dest: h.serviceAddrs[i]}\n\t}\n\n\t// render the template\n\tbuf := &bytes.Buffer{}\n\tif err := h.template.Execute(buf, d); err != nil {\n\t\treturn nil, err\n\t}\n\treturn buf.Bytes(), nil\n}", "func (r *Renderer) Render() {\n\tgl.DrawArrays(gl.TRIANGLES, 0, int32(len(r.RawRenderer)*4))\n}", "func (ctx *RecordContext) Render(v interface{}) error {\n\tctx.Renders = append(ctx.Renders, v)\n\treturn ctx.Context.Render(v)\n}", "func main() {\n\tfloor := surface.UnitCube().Move(0, -1, 0).Scale(100, 1, 100)\n\thalogen := material.Light(10000000, 10000000, 10000000)\n\tlight := surface.UnitSphere(halogen).Move(-50, 100, -10)\n\tbox := surface.UnitSphere(material.Gold)\n\tscene := pbr.NewScene(floor, light, box)\n\tcam := pbr.NewCamera(888, 500).MoveTo(-3, 2, 5).LookAt(box.Center(), box.Center())\n\trender := pbr.NewRender(scene, cam)\n\tinterrupt := make(chan os.Signal, 2)\n\n\trender.SetDirect(1)\n\n\tfmt.Println(\"rendering hello.png (press Ctrl+C to finish)...\")\n\tsignal.Notify(interrupt, os.Interrupt, syscall.SIGTERM)\n\trender.Start()\n\t<-interrupt\n\trender.Stop()\n\trender.WritePngs(\"hello.png\", \"hello-heat.png\", \"hello-noise.png\", 1)\n}", "func render(ctx aero.Context, allActivities []arn.Activity) error {\n\tuser := arn.GetUserFromContext(ctx)\n\tindex, _ := ctx.GetInt(\"index\")\n\n\t// Slice the part that we need\n\tactivities := allActivities[index:]\n\tmaxLength := activitiesFirstLoad\n\n\tif index > 0 {\n\t\tmaxLength = activitiesPerScroll\n\t}\n\n\tif len(activities) > maxLength {\n\t\tactivities = activities[:maxLength]\n\t}\n\n\t// Next index\n\tnextIndex := infinitescroll.NextIndex(ctx, len(allActivities), maxLength, index)\n\n\t// In case we're scrolling, send activities only (without the page frame)\n\tif index > 0 {\n\t\treturn ctx.HTML(components.ActivitiesScrollable(activities, user))\n\t}\n\n\t// Otherwise, send the full page\n\treturn ctx.HTML(components.ActivityFeed(activities, nextIndex, user))\n}", "func Render(i Image, nMax uint, fn Fractaler) Fractal {\n nCPU := runtime.GOMAXPROCS(0)\n\txStep, yStep := i.Scale()\n\tf := NewFractal(i.W, i.H)\n\n\t// points are fed through in to be computed then to d to be written to memory\n\tprein := make(chan point, nCPU)\n\tin := make(chan point, nCPU)\n\td := make(chan point, nCPU)\n\tpcount, icount, count := 0, 0, 0 // used to coordinate the closing of d\n\n\t// create the raw points\n\tgo func() {\n\t\tfor x := uint(0); x < i.W; x = x + 1 {\n\t\t\tgo func(x uint) {\n\t\t\t\tfor y := uint(0); y < i.H; y = y + 1 {\n\t\t\t\t\tprein <- point{x: x, y: y}\n\t\t\t\t}\n\t\t\t\tif pcount+1 == int(i.W) {\n\t\t\t\t\tclose(prein)\n\t\t\t\t}\n\t\t\t\tpcount = pcount + 1\n\t\t\t}(x)\n\t\t}\n\t}()\n\n\t//Create the complex numbers\n\tfor j := 0; j < nCPU; j = j + 1 {\n\t\tgo func() {\n\t\t\tfor p := range prein {\n\t\t\t\tp.c = i.P1 - complex(float64(p.x)*xStep, float64(p.y)*yStep)\n\t\t\t\tin <- p\n\t\t\t}\n\t\t\tif icount+1 == nCPU {\n\t\t\t\tclose(in)\n\t\t\t}\n\t\t\ticount = icount + 1\n\t\t}()\n\t}\n\n\t// Start the worker functions who perform the calculations\n\tfor i := 0; i < nCPU; i = i + 1 {\n\t\tgo func() {\n\t\t\tfor p := range in {\n\t\t\t\tz := complex128(0)\n\t\t\t\tfor p.n = 1; p.n < nMax && fn.CheckBounds(z); p.n = p.n + 1 {\n\t\t\t\t\tz = fn.Iterate(z, p.c)\n\t\t\t\t}\n\t\t\t\td <- p\n\t\t\t}\n\t\t\tif count+1 == nCPU {\n\t\t\t\tclose(d)\n\t\t\t}\n\t\t\tcount = count + 1\n\t\t}()\n\t}\n\n\t// Enter the data into the array as it comes out\n\tfor p := range d {\n\t\tf.Data[p.x][p.y] = p.n\n\t}\n\n\treturn f\n}", "func (dev *E36xx) OutputCount() int {\n\treturn len(dev.Channels)\n}", "func (pp *PostProcessor) Render(time float32) {\n\t// Set uniforms/options\n\tpp.shader.Use()\n\tpp.shader.SetFloat(\"time\", time, false)\n\tpp.shader.SetInteger(\"confuse\", boolToInt32(pp.confuse), false)\n\tpp.shader.SetInteger(\"chaos\", boolToInt32(pp.chaos), false)\n\tpp.shader.SetInteger(\"shake\", boolToInt32(pp.shake), false)\n\t// Render textured quad\n\tgl.ActiveTexture(gl.TEXTURE0)\n\tpp.texture.Bind()\n\tgl.BindVertexArray(pp.quadVao)\n\tgl.DrawArrays(gl.TRIANGLES, 0, 6)\n\tgl.BindVertexArray(0)\n}", "func writeSubscriptionMetrics(object *SubscriptionMetrics, stream *jsoniter.Stream) {\n\tcount := 0\n\tstream.WriteObjectStart()\n\tvar present_ bool\n\tpresent_ = object.bitmap_&1 != 0\n\tif present_ {\n\t\tif count > 0 {\n\t\t\tstream.WriteMore()\n\t\t}\n\t\tstream.WriteObjectField(\"cloud_provider\")\n\t\tstream.WriteString(object.cloudProvider)\n\t\tcount++\n\t}\n\tpresent_ = object.bitmap_&2 != 0 && object.computeNodesCpu != nil\n\tif present_ {\n\t\tif count > 0 {\n\t\t\tstream.WriteMore()\n\t\t}\n\t\tstream.WriteObjectField(\"compute_nodes_cpu\")\n\t\twriteClusterResource(object.computeNodesCpu, stream)\n\t\tcount++\n\t}\n\tpresent_ = object.bitmap_&4 != 0 && object.computeNodesMemory != nil\n\tif present_ {\n\t\tif count > 0 {\n\t\t\tstream.WriteMore()\n\t\t}\n\t\tstream.WriteObjectField(\"compute_nodes_memory\")\n\t\twriteClusterResource(object.computeNodesMemory, stream)\n\t\tcount++\n\t}\n\tpresent_ = object.bitmap_&8 != 0 && object.computeNodesSockets != nil\n\tif present_ {\n\t\tif count > 0 {\n\t\t\tstream.WriteMore()\n\t\t}\n\t\tstream.WriteObjectField(\"compute_nodes_sockets\")\n\t\twriteClusterResource(object.computeNodesSockets, stream)\n\t\tcount++\n\t}\n\tpresent_ = object.bitmap_&16 != 0\n\tif present_ {\n\t\tif count > 0 {\n\t\t\tstream.WriteMore()\n\t\t}\n\t\tstream.WriteObjectField(\"console_url\")\n\t\tstream.WriteString(object.consoleUrl)\n\t\tcount++\n\t}\n\tpresent_ = object.bitmap_&32 != 0 && object.cpu != nil\n\tif present_ {\n\t\tif count > 0 {\n\t\t\tstream.WriteMore()\n\t\t}\n\t\tstream.WriteObjectField(\"cpu\")\n\t\twriteClusterResource(object.cpu, stream)\n\t\tcount++\n\t}\n\tpresent_ = object.bitmap_&64 != 0\n\tif present_ {\n\t\tif count > 0 {\n\t\t\tstream.WriteMore()\n\t\t}\n\t\tstream.WriteObjectField(\"critical_alerts_firing\")\n\t\tstream.WriteFloat64(object.criticalAlertsFiring)\n\t\tcount++\n\t}\n\tpresent_ = object.bitmap_&128 != 0\n\tif present_ {\n\t\tif count > 0 {\n\t\t\tstream.WriteMore()\n\t\t}\n\t\tstream.WriteObjectField(\"health_state\")\n\t\tstream.WriteString(object.healthState)\n\t\tcount++\n\t}\n\tpresent_ = object.bitmap_&256 != 0 && object.memory != nil\n\tif present_ {\n\t\tif count > 0 {\n\t\t\tstream.WriteMore()\n\t\t}\n\t\tstream.WriteObjectField(\"memory\")\n\t\twriteClusterResource(object.memory, stream)\n\t\tcount++\n\t}\n\tpresent_ = object.bitmap_&512 != 0 && object.nodes != nil\n\tif present_ {\n\t\tif count > 0 {\n\t\t\tstream.WriteMore()\n\t\t}\n\t\tstream.WriteObjectField(\"nodes\")\n\t\twriteClusterMetricsNodes(object.nodes, stream)\n\t\tcount++\n\t}\n\tpresent_ = object.bitmap_&1024 != 0\n\tif present_ {\n\t\tif count > 0 {\n\t\t\tstream.WriteMore()\n\t\t}\n\t\tstream.WriteObjectField(\"openshift_version\")\n\t\tstream.WriteString(object.openshiftVersion)\n\t\tcount++\n\t}\n\tpresent_ = object.bitmap_&2048 != 0\n\tif present_ {\n\t\tif count > 0 {\n\t\t\tstream.WriteMore()\n\t\t}\n\t\tstream.WriteObjectField(\"operating_system\")\n\t\tstream.WriteString(object.operatingSystem)\n\t\tcount++\n\t}\n\tpresent_ = object.bitmap_&4096 != 0\n\tif present_ {\n\t\tif count > 0 {\n\t\t\tstream.WriteMore()\n\t\t}\n\t\tstream.WriteObjectField(\"operators_condition_failing\")\n\t\tstream.WriteFloat64(object.operatorsConditionFailing)\n\t\tcount++\n\t}\n\tpresent_ = object.bitmap_&8192 != 0\n\tif present_ {\n\t\tif count > 0 {\n\t\t\tstream.WriteMore()\n\t\t}\n\t\tstream.WriteObjectField(\"region\")\n\t\tstream.WriteString(object.region)\n\t\tcount++\n\t}\n\tpresent_ = object.bitmap_&16384 != 0 && object.sockets != nil\n\tif present_ {\n\t\tif count > 0 {\n\t\t\tstream.WriteMore()\n\t\t}\n\t\tstream.WriteObjectField(\"sockets\")\n\t\twriteClusterResource(object.sockets, stream)\n\t\tcount++\n\t}\n\tpresent_ = object.bitmap_&32768 != 0\n\tif present_ {\n\t\tif count > 0 {\n\t\t\tstream.WriteMore()\n\t\t}\n\t\tstream.WriteObjectField(\"state\")\n\t\tstream.WriteString(object.state)\n\t\tcount++\n\t}\n\tpresent_ = object.bitmap_&65536 != 0\n\tif present_ {\n\t\tif count > 0 {\n\t\t\tstream.WriteMore()\n\t\t}\n\t\tstream.WriteObjectField(\"state_description\")\n\t\tstream.WriteString(object.stateDescription)\n\t\tcount++\n\t}\n\tpresent_ = object.bitmap_&131072 != 0 && object.storage != nil\n\tif present_ {\n\t\tif count > 0 {\n\t\t\tstream.WriteMore()\n\t\t}\n\t\tstream.WriteObjectField(\"storage\")\n\t\twriteClusterResource(object.storage, stream)\n\t\tcount++\n\t}\n\tpresent_ = object.bitmap_&262144 != 0\n\tif present_ {\n\t\tif count > 0 {\n\t\t\tstream.WriteMore()\n\t\t}\n\t\tstream.WriteObjectField(\"subscription_cpu_total\")\n\t\tstream.WriteFloat64(object.subscriptionCpuTotal)\n\t\tcount++\n\t}\n\tpresent_ = object.bitmap_&524288 != 0\n\tif present_ {\n\t\tif count > 0 {\n\t\t\tstream.WriteMore()\n\t\t}\n\t\tstream.WriteObjectField(\"subscription_obligation_exists\")\n\t\tstream.WriteFloat64(object.subscriptionObligationExists)\n\t\tcount++\n\t}\n\tpresent_ = object.bitmap_&1048576 != 0\n\tif present_ {\n\t\tif count > 0 {\n\t\t\tstream.WriteMore()\n\t\t}\n\t\tstream.WriteObjectField(\"subscription_socket_total\")\n\t\tstream.WriteFloat64(object.subscriptionSocketTotal)\n\t\tcount++\n\t}\n\tpresent_ = object.bitmap_&2097152 != 0 && object.upgrade != nil\n\tif present_ {\n\t\tif count > 0 {\n\t\t\tstream.WriteMore()\n\t\t}\n\t\tstream.WriteObjectField(\"upgrade\")\n\t\twriteClusterUpgrade(object.upgrade, stream)\n\t\tcount++\n\t}\n\tstream.WriteObjectEnd()\n}", "func (o DebugSessionOutput) Count() pulumi.IntOutput {\n\treturn o.ApplyT(func(v *DebugSession) pulumi.IntOutput { return v.Count }).(pulumi.IntOutput)\n}", "func (w *WrapperClient) Produce(v int) {\n\tw.mux.Lock()\n\tdefer w.mux.Unlock()\n\tw.streamQuota += v\n}", "func (c *ecsServiceResourceComponent) Render(out io.Writer) (numLines int, err error) {\n\tc.mu.Lock()\n\tdefer c.mu.Unlock()\n\n\tbuf := new(bytes.Buffer)\n\n\tnl, err := c.resourceRenderer.Render(buf)\n\tif err != nil {\n\t\treturn 0, err\n\t}\n\tnumLines += nl\n\n\tvar deploymentRenderer Renderer = &noopComponent{}\n\tif c.deploymentRenderer != nil {\n\t\tdeploymentRenderer = c.deploymentRenderer\n\t}\n\n\tsw := &suffixWriter{\n\t\tbuf: buf,\n\t\tsuffix: []byte{'\\t', '\\t'}, // Add two columns to the deployment renderer so that it aligns with resources.\n\t}\n\tnl, err = deploymentRenderer.Render(sw)\n\tif err != nil {\n\t\treturn 0, err\n\t}\n\tnumLines += nl\n\n\tif _, err = buf.WriteTo(out); err != nil {\n\t\treturn 0, err\n\t}\n\treturn numLines, nil\n}", "func (Parser) Render(rawBytes []byte, urlPrefix string, metas map[string]string, isWiki bool) []byte {\n\treturn Render(rawBytes, urlPrefix, metas, isWiki)\n}", "func (ctx Context) Count(input chan float64) (n uint) {\n\tfor _ = range input {\n\t\tn++\n\t}\n\n\treturn n\n}", "func (d Deck) Render() string {\n\treturn fmt.Sprintf(\"🂠 ×%d\", len(d.Cards))\n}", "func parseObjectStream(osd *types.ObjectStreamDict) error {\n\n\tlog.Read.Printf(\"parseObjectStream begin: decoding %d objects.\\n\", osd.ObjCount)\n\n\tdecodedContent := osd.Content\n\tprolog := decodedContent[:osd.FirstObjOffset]\n\n\t// The separator used in the prolog shall be white space\n\t// but some PDF writers use 0x00.\n\tprolog = bytes.ReplaceAll(prolog, []byte{0x00}, []byte{0x20})\n\n\tobjs := strings.Fields(string(prolog))\n\tif len(objs)%2 > 0 {\n\t\treturn errors.New(\"pdfcpu: parseObjectStream: corrupt object stream dict\")\n\t}\n\n\t// e.g., 10 0 11 25 = 2 Objects: #10 @ offset 0, #11 @ offset 25\n\n\tvar objArray types.Array\n\n\tvar offsetOld int\n\n\tfor i := 0; i < len(objs); i += 2 {\n\n\t\toffset, err := strconv.Atoi(objs[i+1])\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\n\t\toffset += osd.FirstObjOffset\n\n\t\tif i > 0 {\n\t\t\tdstr := string(decodedContent[offsetOld:offset])\n\t\t\tlog.Read.Printf(\"parseObjectStream: objString = %s\\n\", dstr)\n\t\t\to, err := compressedObject(dstr)\n\t\t\tif err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\n\t\t\tlog.Read.Printf(\"parseObjectStream: [%d] = obj %s:\\n%s\\n\", i/2-1, objs[i-2], o)\n\t\t\tobjArray = append(objArray, o)\n\t\t}\n\n\t\tif i == len(objs)-2 {\n\t\t\tdstr := string(decodedContent[offset:])\n\t\t\tlog.Read.Printf(\"parseObjectStream: objString = %s\\n\", dstr)\n\t\t\to, err := compressedObject(dstr)\n\t\t\tif err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\n\t\t\tlog.Read.Printf(\"parseObjectStream: [%d] = obj %s:\\n%s\\n\", i/2, objs[i], o)\n\t\t\tobjArray = append(objArray, o)\n\t\t}\n\n\t\toffsetOld = offset\n\t}\n\n\tosd.ObjArray = objArray\n\n\tlog.Read.Println(\"parseObjectStream end\")\n\n\treturn nil\n}", "func (c *StepLookbackAccumulator) BufferStepCount() int {\n\treturn len(c.unconsumed)\n}", "func (s Style) Render(raw string) string {\n\tt := NewAnstring(raw)\n\tfor i := len(s) - 1; i >= 0; i-- {\n\t\tt.meld(s[i])\n\t}\n\treturn string(t)\n}", "func (complexShaperThai) preprocessText(plan *otShapePlan, buffer *Buffer, font *Font) {\n\t/* The following is NOT specified in the MS OT Thai spec, however, it seems\n\t* to be what Uniscribe and other engines implement. According to Eric Muller:\n\t*\n\t* When you have a SARA AM, decompose it in NIKHAHIT + SARA AA, *and* move the\n\t* NIKHAHIT backwards over any tone mark (0E48-0E4B).\n\t*\n\t* <0E14, 0E4B, 0E33> . <0E14, 0E4D, 0E4B, 0E32>\n\t*\n\t* This reordering is legit only when the NIKHAHIT comes from a SARA AM, not\n\t* when it's there to start with. The string <0E14, 0E4B, 0E4D> is probably\n\t* not what a user wanted, but the rendering is nevertheless nikhahit above\n\t* chattawa.\n\t*\n\t* Same for Lao.\n\t*\n\t* Note:\n\t*\n\t* Uniscribe also does some below-marks reordering. Namely, it positions U+0E3A\n\t* after U+0E38 and U+0E39. We do that by modifying the ccc for U+0E3A.\n\t* See unicode.modified_combining_class (). Lao does NOT have a U+0E3A\n\t* equivalent.\n\t */\n\n\t/*\n\t* Here are the characters of significance:\n\t*\n\t*\t\t\tThai\tLao\n\t* SARA AM:\t\tU+0E33\tU+0EB3\n\t* SARA AA:\t\tU+0E32\tU+0EB2\n\t* Nikhahit:\t\tU+0E4D\tU+0ECD\n\t*\n\t* Testing shows that Uniscribe reorder the following marks:\n\t* Thai:\t<0E31,0E34..0E37,0E47..0E4E>\n\t* Lao:\t<0EB1,0EB4..0EB7,0EC7..0ECE>\n\t*\n\t* Note how the Lao versions are the same as Thai + 0x80.\n\t */\n\n\tbuffer.clearOutput()\n\tcount := len(buffer.Info)\n\tfor buffer.idx = 0; buffer.idx < count; {\n\t\tu := buffer.cur(0).codepoint\n\t\tif !isSaraAm(u) {\n\t\t\tbuffer.nextGlyph()\n\t\t\tcontinue\n\t\t}\n\n\t\t/* Is SARA AM. Decompose and reorder. */\n\t\tbuffer.outputRune(nikhahitFromSaraAm(u))\n\t\tbuffer.prev().setContinuation()\n\t\tbuffer.replaceGlyph(saraAaFromSaraAm(u))\n\n\t\t/* Make Nikhahit be recognized as a ccc=0 mark when zeroing widths. */\n\t\tend := len(buffer.outInfo)\n\t\tbuffer.outInfo[end-2].setGeneralCategory(nonSpacingMark)\n\n\t\t/* Ok, let's see... */\n\t\tstart := end - 2\n\t\tfor start > 0 && isToneMark(buffer.outInfo[start-1].codepoint) {\n\t\t\tstart--\n\t\t}\n\n\t\tif start+2 < end {\n\t\t\t/* Move Nikhahit (end-2) to the beginning */\n\t\t\tbuffer.mergeOutClusters(start, end)\n\t\t\tt := buffer.outInfo[end-2]\n\t\t\tcopy(buffer.outInfo[start+1:], buffer.outInfo[start:end-2])\n\t\t\tbuffer.outInfo[start] = t\n\t\t} else {\n\t\t\t/* Since we decomposed, and NIKHAHIT is combining, merge clusters with the\n\t\t\t* previous cluster. */\n\t\t\tif start != 0 && buffer.ClusterLevel == MonotoneGraphemes {\n\t\t\t\tbuffer.mergeOutClusters(start-1, end)\n\t\t\t}\n\t\t}\n\t}\n\tbuffer.swapBuffers()\n\n\t/* If font has Thai GSUB, we are done. */\n\tif plan.props.Script == language.Thai && !plan.map_.foundScript[0] {\n\t\tdoThaiPuaShaping(buffer, font)\n\t}\n}", "func defaultRender(w io.Writer, c *Component) error {\n\t_, err := w.Write([]byte(fmt.Sprintf(\"%+v\", c.State)))\n\treturn err\n}", "func TransformFeedbackVaryings(program uint32, count int32, varyings **uint8, bufferMode uint32) {\n\tC.glowTransformFeedbackVaryings(gpTransformFeedbackVaryings, (C.GLuint)(program), (C.GLsizei)(count), (**C.GLchar)(unsafe.Pointer(varyings)), (C.GLenum)(bufferMode))\n}", "func TransformFeedbackVaryings(program uint32, count int32, varyings **uint8, bufferMode uint32) {\n\tC.glowTransformFeedbackVaryings(gpTransformFeedbackVaryings, (C.GLuint)(program), (C.GLsizei)(count), (**C.GLchar)(unsafe.Pointer(varyings)), (C.GLenum)(bufferMode))\n}", "func (f *Flash) Count() int {\n\treturn len(f.v)\n}", "func (p *pipe) outputAdvance(count int) {\n\tp.outPos += int32(count)\n\tif p.outPos >= p.size {\n\t\tp.outPos -= p.size\n\t}\n\tatomic.AddInt32(&p.free, int32(count))\n\n\tselect {\n\tcase p.inWake <- struct{}{}:\n\tdefault:\n\t}\n}", "func TransformFeedbackBufferRange(xfb uint32, index uint32, buffer uint32, offset int, size int) {\n\tsyscall.Syscall6(gpTransformFeedbackBufferRange, 5, uintptr(xfb), uintptr(index), uintptr(buffer), uintptr(offset), uintptr(size), 0)\n}", "func Render(w http.ResponseWriter, actions ...*Action) error {\n\tbuf := new(bytes.Buffer)\n\tfor _, a := range actions {\n\t\tif err := a.appendTo(buf); err != nil {\n\t\t\treturn err\n\t\t}\n\t\tif a != nil {\n\t\t\tbuf.WriteByte('\\n')\n\t\t}\n\t}\n\tw.Header().Set(\"Content-Type\", ContentType+\"; charset=utf-8\")\n\tw.Header().Set(\"Content-Length\", strconv.Itoa(buf.Len()))\n\tio.Copy(w, buf) // ignore errors, since we already wrote\n\treturn nil\n}", "func (c *Context) Count(stat string, count float64) {\n\tfor _, sink := range c.sinks {\n\t\tsink.Count(c, stat, count)\n\t}\n}", "func displayImageReferenceProgress(output io.Writer, isTerminal bool, msgs []jsonstream.JSONMessage, start time.Time) error {\n\tvar (\n\t\ttw = tabwriter.NewWriter(output, 1, 8, 1, ' ', 0)\n\t\tcurrent = int64(0)\n\t)\n\n\tfor _, msg := range msgs {\n\t\tif msg.Error != nil {\n\t\t\treturn fmt.Errorf(msg.Error.Message)\n\t\t}\n\n\t\tif msg.Detail != nil {\n\t\t\tcurrent += msg.Detail.Current\n\t\t}\n\n\t\tstatus := jsonstream.PullReferenceStatus(!isTerminal, msg)\n\t\tif _, err := fmt.Fprint(tw, status); err != nil {\n\t\t\treturn err\n\t\t}\n\t}\n\n\t// no need to show the total information if the stdout is not terminal\n\tif isTerminal {\n\t\t_, err := fmt.Fprintf(tw, \"elapsed: %-4.1fs\\ttotal: %7.6v\\t(%v)\\t\\n\",\n\t\t\ttime.Since(start).Seconds(),\n\t\t\tprogress.Bytes(current),\n\t\t\tprogress.NewBytesPerSecond(current, time.Since(start)))\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t}\n\treturn tw.Flush()\n}", "func (ctx *APIContext) Render(status int, title string, obj interface{}) {\n\tctx.JSON(status, map[string]interface{}{\n\t\t\"message\": title,\n\t\t\"status\": status,\n\t\t\"resource\": obj,\n\t})\n}", "func ExampleCountingSink() {\n\t// The json string would be \"[0,1,2,3,4]\\n\", so the size should be 12.\n\tobject := []int{0, 1, 2, 3, 4}\n\n\tvar sink iobp.CountingSink\n\tif err := json.NewEncoder(&sink).Encode(object); err != nil {\n\t\tpanic(err)\n\t}\n\tfmt.Printf(\"JSON size for %#v: %d\\n\", object, sink.Size())\n\n\t// Output:\n\t// JSON size for []int{0, 1, 2, 3, 4}: 12\n}", "func (s *Square) Render() string {\n\treturn fmt.Sprintf(\"Square side %f\", s.Side)\n}", "func (vhs *VHS) Render() error {\n\t// Apply Loop Offset by modifying frame sequence\n\tif err := vhs.ApplyLoopOffset(); err != nil {\n\t\treturn err\n\t}\n\n\t// Generate the video(s) with the frames.\n\tvar cmds []*exec.Cmd\n\tcmds = append(cmds, MakeGIF(vhs.Options.Video))\n\tcmds = append(cmds, MakeMP4(vhs.Options.Video))\n\tcmds = append(cmds, MakeWebM(vhs.Options.Video))\n\tcmds = append(cmds, MakeScreenshots(vhs.Options.Screenshot)...)\n\n\tfor _, cmd := range cmds {\n\t\tif cmd == nil {\n\t\t\tcontinue\n\t\t}\n\t\tout, err := cmd.CombinedOutput()\n\t\tif err != nil {\n\t\t\tlog.Println(string(out))\n\t\t}\n\t}\n\n\treturn nil\n}", "func GenderSpout(tuple []interface{}, result *[]interface{}, variables *[]interface{}) error {\n\t// Variables\n\tvar counterMap map[string]interface{}\n\tvar idArray interface{}\n\tvar genderArray interface{}\n\n\tif (len(*variables) == 0) {\n\t\tcounterMap = make(map[string]interface{})\n\t\t*variables = append(*variables, counterMap)\n\t\tcounterMap[\"counter\"] = float64(0)\n\n\t\tfile, _ := os.Open(\"data.json\")\n\t\tdefer file.Close()\n\n\t\tb, _ := ioutil.ReadAll(file)\n\t\tvar object interface{}\n\t\tjson.Unmarshal(b, &object)\n\t\tobjectMap := object.(map[string]interface{})\n\t\tidArray = objectMap[\"id\"].([]interface{})\n\t\tgenderArray = objectMap[\"gender\"].([]interface{})\n\n\t\t*variables = append(*variables, idArray)\n\t\t*variables = append(*variables, genderArray)\n\t}\n\tcounterMap = (*variables)[0].(map[string]interface{})\n\tidArray = (*variables)[1]\n\tgenderArray = (*variables)[2]\n\n\t// Logic\n\tif counterMap[\"counter\"].(float64) < 1000 {\n\t\t*result = []interface{}{idArray.([]interface{})[int(counterMap[\"counter\"].(float64))], genderArray.([]interface{})[int(counterMap[\"counter\"].(float64))]}\n\t\tcounterMap[\"counter\"] = counterMap[\"counter\"].(float64) + 1\n\t}\n\n\t// // Logic\n\t// if counterMap[\"counter\"].(float64) < 10 {\n\t// \tif int(counterMap[\"counter\"].(float64)) % 2 == 0 {\n\t// \t\t*result = []interface{}{strconv.Itoa(int(counterMap[\"counter\"].(float64))), \"male\"}\n\t// \t} else {\n\t// \t\t*result = []interface{}{strconv.Itoa(int(counterMap[\"counter\"].(float64))), \"female\"}\n\t// \t}\n\t// \tcounterMap[\"counter\"] = counterMap[\"counter\"].(float64) + 1\n\t// }\n\n\ttime.Sleep(1 * time.Millisecond)\n\n\t// Return value\n\tif (len(*result) > 0) {\n\t\tlog.Printf(\"Gender Spout Emit (%v)\\n\", *result)\n\t\treturn nil\n\t} else {\n\t\treturn errors.New(\"next tuple is nil\")\n\t}\n}", "func (*Count) Descriptor() ([]byte, []int) {\n\treturn file_proto_google_fhir_proto_stu3_datatypes_proto_rawDescGZIP(), []int{25}\n}", "func (c *stackSetComponent) Render(out io.Writer) (int, error) {\n\tc.mu.Lock()\n\tdefer c.mu.Unlock()\n\n\tcomponents := cfnLineItemComponents(c.title, c.separator, c.statuses, c.stopWatch, c.style.Padding)\n\treturn renderComponents(out, components)\n}", "func (pipe *pipe) Write(b Samples) (int, error) {\n\tif err := pipe.getErr(); err != nil {\n\t\treturn 0, err\n\t}\n\n\t// TODO(paultag): Thread safety.\n\n\tif b.Format() != pipe.format {\n\t\treturn 0, ErrSampleFormatMismatch\n\t}\n\n\tvar n int\n\n\tfor b.Length() > 0 {\n\t\tselect {\n\t\tcase pipe.samplesCh <- b:\n\t\t\tnumWritten := <-pipe.readSamplesCh\n\t\t\tb = b.Slice(numWritten, b.Length())\n\t\t\tn += numWritten\n\t\tcase <-pipe.context.Done():\n\t\t\treturn n, pipe.getErr()\n\t\t}\n\t}\n\n\treturn n, nil\n}", "func (l *Layer) Count(value int) int {\n\tcount := 0\n\tfor _, b := range l.Bytes {\n\t\tif b == value {\n\t\t\tcount++\n\t\t}\n\t}\n\n\treturn count\n}", "func readStableObjectCount(ctx context.Context, backend Backend, width, height int) (objectCount int, err error) {\n\tconst (\n\t\tpollingInterval = 1 * time.Second\n\t\t// Time to wait for the object count to be stable.\n\t\twaitTimeout = 120 * time.Second\n\t\t// Threshold (in percentage) below which the object count is considered stable.\n\t\tobjectCountThresholdBase = 0.1\n\t\t// Maximum threshold (in percentage) for the object count to be considered stable.\n\t\tobjectCountThresholdMax = 2.0\n\t\t// Maximum steps of relaxing the object count similarity threshold.\n\t\trelaxingThresholdSteps = 5\n\t)\n\n\tstartTime := time.Now()\n\tdelta := (objectCountThresholdMax - objectCountThresholdBase) / (relaxingThresholdSteps - 1)\n\ttesting.ContextLogf(ctx, \"Waiting at most %v for stable graphics object count, threshold will be gradually relaxed from %.1f%% to %.1f%%\",\n\t\twaitTimeout, objectCountThresholdBase, objectCountThresholdMax)\n\n\tfor i := 0; i < relaxingThresholdSteps; i++ {\n\t\tidlePercent := objectCountThresholdBase + (delta * float64(i))\n\t\ttimeout := waitTimeout / relaxingThresholdSteps\n\t\ttesting.ContextLogf(ctx, \"Waiting up to %v for object count to settle within %.1f%% (%d/%d)\",\n\t\t\ttimeout.Round(time.Second), idlePercent, i+1, relaxingThresholdSteps)\n\n\t\tobjectCount, err = waitForStableReadings(ctx, backend, width, height, timeout, pollingInterval, idlePercent)\n\t\tif err == nil {\n\t\t\ttesting.ContextLogf(ctx, \"Waiting for object count stabilisation took %v (value %d, threshold: %.1f%%)\",\n\t\t\t\ttime.Now().Sub(startTime).Round(time.Second), objectCount, idlePercent)\n\t\t\treturn objectCount, nil\n\t\t}\n\t}\n\treturn objectCount, err\n}", "func (t *Transport) stream(msg Message, stream *Stream, out []byte) (n int) {\n\tatomic.AddUint64(&t.nTxstream, 1)\n\tn = tag2cbor(tagCborPrefix, out) // prefix\n\tout[n] = 0xc7 // 0xc7 (stream msg, 0b110_00111 <tag,7>)\n\tn++ //\n\tn += t.framepkt(msg, stream, out[n:]) // packet\n\treturn n\n}", "func makeRenderablePoly(name string, n int, drawType uint, color vec4) *Renderable {\n\t// build poly verts\n\tvertex := makePoly(n)\n\tr := &Renderable{\n\t\tworld.Transform(),\n\t\tworld.Operation(name, &world.Poly{Points: vertex}),\n\t\tworld.MaterialComponent{\n\t\t\tDrawType: drawType,\n\t\t\tProps: map[string]interface{}{\n\t\t\t\t\"color\": world.Color(color),\n\t\t\t},\n\t\t},\n\t}\n\n\treturn r\n}", "func Render(w IWidget, size gowid.IRenderSize, focus gowid.Selector, app gowid.IApp) gowid.ICanvas {\n\tflow, isFlow := size.(gowid.IRenderFlowWith)\n\tif !isFlow {\n\t\tpanic(gowid.WidgetSizeError{Widget: w, Size: size, Required: \"gowid.IRenderFlowWith\"})\n\t}\n\tcols := flow.FlowColumns()\n\n\tdisplay := make([]rune, cols)\n\twi := w.Index()\n\tfor i := 0; i < cols; i++ {\n\t\tdisplay[i] = wave[wi]\n\t\twi += 1\n\t\tif wi == w.SpinnerLen() {\n\t\t\twi = 0\n\t\t}\n\t}\n\tbarCanvas :=\n\t\tstyled.New(\n\t\t\ttext.New(string(display)),\n\t\t\tw.Styler(),\n\t\t).Render(\n\n\t\t\tgowid.RenderBox{C: cols, R: 1}, gowid.NotSelected, app)\n\n\treturn barCanvas\n}", "func (b *renderSystem) Render(dt float64) {\n\n\tb.renderer.Clear()\n\n\tfor i := 0; i < 100; i++ {\n\t\tl := b.layers[i]\n\t\tif l != nil {\n\t\t\tfor _, renderable := range *l {\n\t\t\t\trenderable.Paint(b.renderer)\n\t\t\t}\n\t\t}\n\t}\n\n\tb.renderer.Present()\n}", "func (Empty) Render(width, height int) *term.Buffer {\n\treturn term.NewBufferBuilder(width).Buffer()\n}", "func Stats(font *sfnt.Font) error {\n\tfor _, tag := range font.Tags() {\n\t\ttable, err := font.Table(tag)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\n\t\tfmt.Printf(\"%6d %q %s\\n\", len(table.Bytes()), tag, table.Name())\n\t}\n\treturn nil\n}", "func (c CategoryCountsRaw) Transform(tileData []*GeoImage) ([]float64, error) {\n\treturn computeCounts(&c.CategoryCounts, tileData)\n}", "func TestRedactStream(t *testing.T) {\n\ttestData := []struct {\n\t\tf string\n\t\tinput interface{}\n\t\texpected string\n\t}{\n\t\t{\"%v\", \"\", \"‹›\"},\n\t\t{\"%v\", \" \", \"‹›\"},\n\t\t{\"‹› %v ›››\", \"abc\", \"?? ‹abc› ???\"},\n\t\t{\"%v\", \"abc \", \"‹abc›\"},\n\t\t{\"%q\", \"abc \", `‹\"abc \"›`},\n\t\t{\"%v\", \"abc\\n \", \"‹abc›\"},\n\t\t{\"%v\", \"abc \\n\\n\", \"‹abc›\"},\n\t\t{\"%v\", \" \\n\\nabc\", \"‹ ›\\n\\n‹abc›\"},\n\t\t{\"%v\", \"‹abc›\", \"‹?abc?›\"},\n\t\t{\"%v\", 123, \"‹123›\"},\n\t\t{\"%05d\", 123, \"‹00123›\"},\n\t\t{\"%v\", Safe(123), \"123\"},\n\t\t{\"%05d\", Safe(123), \"00123\"},\n\t\t{\"%#x\", 17, \"‹0x11›\"},\n\t\t{\"%+v\", &complexObj{\"‹›\"}, \"‹&{v:??}›\"},\n\t\t{\"%v\", &safestringer{\"as\"}, \"as\"},\n\t\t{\"%v\", &stringer{\"as\"}, \"‹as›\"},\n\t\t{\"%v\", &safefmtformatter{\"af\"}, \"af\"},\n\t\t{\"%v\", &fmtformatter{\"af\"}, \"‹af›\"},\n\t\t{\"%v\", &safemsg{\"az\"}, \"az\"},\n\t\t// Printers that cause panics during rendering.\n\t\t{\"%v\", &safepanicObj1{\"s1-x‹y›z\"}, `%!v(PANIC=String method: s1-x?y?z)`},\n\t\t{\"%v\", &safepanicObj2{\"s2-x‹y›z\"}, `%!v(PANIC=Format method: s2-x?y?z)`},\n\t\t{\"%v\", &panicObj1{\"p1-x‹y›z\"}, `‹%!v(PANIC=String method: p1-x?y?z)›`},\n\t\t{\"%v\", &panicObj2{\"p2-x‹y›z\"}, `‹%!v(PANIC=Format method: p2-x?y?z)›`},\n\t\t{\"%v\", &panicObj3{\"p3-x‹y›z\"}, `%!v(PANIC=SafeFormatter method: p3-x?y?z)`},\n\t}\n\n\tfor i, tc := range testData {\n\t\tvar buf strings.Builder\n\t\tn, _ := Fprintf(&buf, tc.f, tc.input)\n\t\tresult := buf.String()\n\t\tif result != tc.expected {\n\t\t\tt.Errorf(\"%d: expected %q, got %q\", i, tc.expected, result)\n\t\t}\n\t\tif n != len(result) {\n\t\t\tt.Errorf(\"%d: expected len %d, got %d\", i, n, len(result))\n\t\t}\n\t}\n}", "func render(m diag.Message, colorize bool) string {\n\treturn fmt.Sprintf(\"%s%v%s [%v]%s %s\",\n\t\tcolorPrefix(m, colorize), m.Type.Level(), colorSuffix(colorize),\n\t\tm.Type.Code(), m.Origin(), fmt.Sprintf(m.Type.Template(), m.Parameters...),\n\t)\n}", "func (v *View) Renderer(matcher func(instance.Description) bool) (func(w io.Writer, v interface{}) error, error) {\n\ttagsView, err := template.NewTemplate(template.ValidURL(v.tagsTemplate), v.options)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\tpropertiesView, err := template.NewTemplate(template.ValidURL(v.propertiesTemplate), v.options)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\n\treturn func(w io.Writer, result interface{}) error {\n\n\t\tinstances, is := result.([]instance.Description)\n\t\tif !is {\n\t\t\treturn fmt.Errorf(\"not []instance.Description\")\n\t\t}\n\n\t\tif !v.quiet {\n\t\t\tif v.viewTemplate != \"\" {\n\t\t\t\tfmt.Printf(\"%-30s\\t%-30s\\n\", \"ID\", \"VIEW\")\n\t\t\t} else if v.properties {\n\t\t\t\tfmt.Printf(\"%-30s\\t%-30s\\t%-30s\\t%-s\\n\", \"ID\", \"LOGICAL\", \"TAGS\", \"PROPERTIES\")\n\n\t\t\t} else {\n\t\t\t\tfmt.Printf(\"%-30s\\t%-30s\\t%-s\\n\", \"ID\", \"LOGICAL\", \"TAGS\")\n\t\t\t}\n\t\t}\n\t\tfor _, d := range instances {\n\n\t\t\t// TODO - filter on the client side by tags\n\t\t\tif len(v.TagFilter()) > 0 {\n\t\t\t\tif hasDifferentTag(v.TagFilter(), d.Tags) {\n\t\t\t\t\tcontinue\n\t\t\t\t}\n\t\t\t}\n\t\t\tif matcher != nil {\n\t\t\t\tif !matcher(d) {\n\t\t\t\t\tcontinue\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tlogical := \" - \"\n\t\t\tif d.LogicalID != nil {\n\t\t\t\tlogical = string(*d.LogicalID)\n\t\t\t}\n\n\t\t\tif v.viewTemplate != \"\" {\n\n\t\t\t\tcolumn := \"-\"\n\t\t\t\tif view, err := d.View(v.viewTemplate); err == nil {\n\t\t\t\t\tcolumn = view\n\t\t\t\t} else {\n\t\t\t\t\tcolumn = err.Error()\n\t\t\t\t}\n\t\t\t\tfmt.Printf(\"%-30s\\t%-30s\\n\", d.ID, column)\n\n\t\t\t} else {\n\n\t\t\t\ttagViewBuff := \"\"\n\t\t\t\tif v.tagsTemplate == \"*\" {\n\t\t\t\t\t// default -- this is a hack\n\t\t\t\t\tprintTags := []string{}\n\t\t\t\t\tfor k, v := range d.Tags {\n\t\t\t\t\t\tprintTags = append(printTags, fmt.Sprintf(\"%s=%s\", k, v))\n\t\t\t\t\t}\n\t\t\t\t\tsort.Strings(printTags)\n\t\t\t\t\ttagViewBuff = strings.Join(printTags, \",\")\n\t\t\t\t} else {\n\t\t\t\t\ttagViewBuff = renderTags(d.Tags, tagsView)\n\t\t\t\t}\n\n\t\t\t\tif v.properties {\n\n\t\t\t\t\tif v.quiet {\n\t\t\t\t\t\t// special render only the properties\n\t\t\t\t\t\tfmt.Printf(\"%s\", renderProperties(d.Properties, propertiesView))\n\t\t\t\t\t} else {\n\t\t\t\t\t\tfmt.Printf(\"%-30s\\t%-30s\\t%-30s\\t%-s\\n\", d.ID, logical, tagViewBuff,\n\t\t\t\t\t\t\trenderProperties(d.Properties, propertiesView))\n\t\t\t\t\t}\n\t\t\t\t} else {\n\t\t\t\t\tfmt.Printf(\"%-30s\\t%-30s\\t%-s\\n\", d.ID, logical, tagViewBuff)\n\t\t\t\t}\n\n\t\t\t}\n\t\t}\n\t\treturn nil\n\t}, nil\n}", "func AgeSpout(tuple []interface{}, result *[]interface{}, variables *[]interface{}) error {\n\t// Variables\n\tvar counterMap map[string]interface{}\n\tvar idArray interface{}\n\tvar ageArray interface{}\n\n\tif (len(*variables) == 0) {\n\t\tcounterMap = make(map[string]interface{})\n\t\t*variables = append(*variables, counterMap)\n\t\tcounterMap[\"counter\"] = float64(0)\n\n\t\tfile, _ := os.Open(\"data.json\")\n\t\tdefer file.Close()\n\n\t\tb, _ := ioutil.ReadAll(file)\n\t\tvar object interface{}\n\t\tjson.Unmarshal(b, &object)\n\t\tobjectMap := object.(map[string]interface{})\n\t\tidArray = objectMap[\"id\"].([]interface{})\n\t\tageArray = objectMap[\"age\"].([]interface{})\n\n\t\t*variables = append(*variables, idArray)\n\t\t*variables = append(*variables, ageArray)\n\t}\n\tcounterMap = (*variables)[0].(map[string]interface{})\n\tidArray = (*variables)[1]\n\tageArray = (*variables)[2]\n\n\t// Logic\n\tif counterMap[\"counter\"].(float64) < 1000 {\n\t\t*result = []interface{}{idArray.([]interface{})[int(counterMap[\"counter\"].(float64))], ageArray.([]interface{})[int(counterMap[\"counter\"].(float64))]}\n\t\tcounterMap[\"counter\"] = counterMap[\"counter\"].(float64) + 1\n\t}\n\n\t// // Logic\n\t// if counterMap[\"counter\"].(float64) < 800 {\n\t// \t*result = []interface{}{strconv.Itoa(int(counterMap[\"counter\"].(float64))), strconv.Itoa(int(counterMap[\"counter\"].(float64)) + 20)}\n\t// \tcounterMap[\"counter\"] = counterMap[\"counter\"].(float64) + 1\n\t// }\n\n\ttime.Sleep(1 * time.Millisecond)\n\n\t// Return value\n\tif (len(*result) > 0) {\n\t\tlog.Printf(\"Age Spout Emit (%v)\\n\", *result)\n\t\treturn nil\n\t} else {\n\t\treturn errors.New(\"next tuple is nil\")\n\t}\n}", "func (b *Buffer) update() {\n\tb.NumLines = len(b.lines)\n}", "func outputSamplesProg(tb testing.TB, events *ebpf.Map, sampleSizes ...byte) *ebpf.Program {\n\ttb.Helper()\n\n\t// Requires at least 4.9 (0515e5999a46 \"bpf: introduce BPF_PROG_TYPE_PERF_EVENT program type\")\n\ttestutils.SkipOnOldKernel(tb, \"4.9\", \"perf events support\")\n\n\tconst bpfFCurrentCPU = 0xffffffff\n\n\tvar maxSampleSize byte\n\tfor _, sampleSize := range sampleSizes {\n\t\tif sampleSize < 2 {\n\t\t\ttb.Fatalf(\"Sample size %d is too small to contain size and counter\", sampleSize)\n\t\t}\n\t\tif sampleSize > maxSampleSize {\n\t\t\tmaxSampleSize = sampleSize\n\t\t}\n\t}\n\n\t// Fill a buffer on the stack, and stash context somewhere\n\tinsns := asm.Instructions{\n\t\tasm.LoadImm(asm.R0, ^int64(0), asm.DWord),\n\t\tasm.Mov.Reg(asm.R9, asm.R1),\n\t}\n\n\tbufDwords := int(maxSampleSize/8) + 1\n\tfor i := 0; i < bufDwords; i++ {\n\t\tinsns = append(insns,\n\t\t\tasm.StoreMem(asm.RFP, int16(i+1)*-8, asm.R0, asm.DWord),\n\t\t)\n\t}\n\n\tfor i, sampleSize := range sampleSizes {\n\t\tinsns = append(insns,\n\t\t\t// Restore stashed context.\n\t\t\tasm.Mov.Reg(asm.R1, asm.R9),\n\t\t\t// map\n\t\t\tasm.LoadMapPtr(asm.R2, events.FD()),\n\t\t\t// flags\n\t\t\tasm.LoadImm(asm.R3, bpfFCurrentCPU, asm.DWord),\n\t\t\t// buffer\n\t\t\tasm.Mov.Reg(asm.R4, asm.RFP),\n\t\t\tasm.Add.Imm(asm.R4, int32(bufDwords*-8)),\n\t\t\t// buffer[0] = size\n\t\t\tasm.StoreImm(asm.R4, 0, int64(sampleSize), asm.Byte),\n\t\t\t// buffer[1] = i\n\t\t\tasm.StoreImm(asm.R4, 1, int64(i&math.MaxUint8), asm.Byte),\n\t\t\t// size\n\t\t\tasm.Mov.Imm(asm.R5, int32(sampleSize)),\n\t\t\tasm.FnPerfEventOutput.Call(),\n\t\t)\n\t}\n\n\tinsns = append(insns, asm.Return())\n\n\tprog, err := ebpf.NewProgram(&ebpf.ProgramSpec{\n\t\tLicense: \"GPL\",\n\t\tType: ebpf.XDP,\n\t\tInstructions: insns,\n\t})\n\tif err != nil {\n\t\ttb.Fatal(err)\n\t}\n\ttb.Cleanup(func() { prog.Close() })\n\n\treturn prog\n}", "func NumberLamp(vs []val.Val) {\n\tfunc(vs []val.Val) {\n\t\tdraw := func(color, str string) {\n\t\t\tfmt.Print(colorstring.Color(\"[_\" + color + \"_]\" + str + \"[default]\"))\n\t\t}\n\t\tfor {\n\t\t\toff := \"black\"\n\t\t\ton := \"blue\"\n\t\t\tons := make([]string, 7)\n\t\t\tfor i := 0; i < 7; i++ {\n\t\t\t\tout := vs[i].Out()\n\t\t\t\tif out.IsNil() {\n\t\t\t\t\treturn\n\t\t\t\t}\n\t\t\t\tif out.Bool() {\n\t\t\t\t\tons[i] = on\n\t\t\t\t} else {\n\t\t\t\t\tons[i] = off\n\t\t\t\t}\n\t\t\t}\n\t\t\t//\t0\n\t\t\tdraw(off, \" \")\n\t\t\tdraw(ons[0], \" \")\n\t\t\tdraw(off, \" \")\n\t\t\tdraw(off, \"\\n\")\n\t\t\t//\t5 1\n\t\t\tdraw(ons[5], \" \")\n\t\t\tdraw(off, \" \")\n\t\t\tdraw(ons[1], \" \")\n\t\t\tdraw(off, \"\\n\")\n\t\t\tdraw(ons[5], \" \")\n\t\t\tdraw(off, \" \")\n\t\t\tdraw(ons[1], \" \")\n\t\t\tdraw(off, \"\\n\")\n\t\t\t//\t6\n\t\t\tdraw(off, \" \")\n\t\t\tdraw(ons[6], \" \")\n\t\t\tdraw(off, \" \")\n\t\t\tdraw(off, \"\\n\")\n\t\t\t//\t4 2\n\t\t\tdraw(ons[4], \" \")\n\t\t\tdraw(off, \" \")\n\t\t\tdraw(ons[2], \" \")\n\t\t\tdraw(off, \"\\n\")\n\t\t\tdraw(ons[4], \" \")\n\t\t\tdraw(off, \" \")\n\t\t\tdraw(ons[2], \" \")\n\t\t\tdraw(off, \"\\n\")\n\t\t\t//\t3\n\t\t\tdraw(off, \" \")\n\t\t\tdraw(ons[3], \" \")\n\t\t\tdraw(off, \" \")\n\t\t\tdraw(off, \"\\n\")\n\t\t\t//\tnew line\n\t\t\tdraw(off, \"\\n\")\n\t\t}\n\t}(vs)\n}" ]
[ "0.54971063", "0.5156556", "0.5075233", "0.5075233", "0.5070006", "0.50181854", "0.4983393", "0.49248007", "0.48812094", "0.48550126", "0.48525667", "0.48004407", "0.4753193", "0.4732827", "0.4729256", "0.47229594", "0.47207427", "0.47133744", "0.470725", "0.47026896", "0.4677461", "0.46754235", "0.46724036", "0.46694714", "0.4634834", "0.46268016", "0.46218666", "0.46171138", "0.46123552", "0.46069193", "0.45909765", "0.45675236", "0.45488393", "0.45383146", "0.45341498", "0.4533864", "0.45248994", "0.45184126", "0.45120755", "0.45044217", "0.4502997", "0.45023152", "0.44882149", "0.4482644", "0.44670042", "0.44660237", "0.44541845", "0.44460353", "0.44380763", "0.44337225", "0.44154006", "0.44089228", "0.4404952", "0.4402559", "0.4390347", "0.4382252", "0.43795478", "0.4372112", "0.4370642", "0.4369781", "0.43686888", "0.43657526", "0.43571734", "0.43565655", "0.43524456", "0.43492284", "0.43400642", "0.4325395", "0.43227953", "0.43221065", "0.43221065", "0.4321102", "0.43147546", "0.4314334", "0.43122536", "0.43104565", "0.4309477", "0.43092093", "0.430551", "0.4296796", "0.4293946", "0.42936298", "0.42909563", "0.42906952", "0.42863494", "0.42858082", "0.42839116", "0.42830428", "0.42790383", "0.42790374", "0.4275473", "0.42735913", "0.4273241", "0.4271965", "0.4266264", "0.42662293", "0.42583546", "0.425673", "0.42522067", "0.42496225", "0.4249529" ]
0.0
-1
render multiple instances of primitives using a count derived from a specifed stream of a transform feedback object
func DrawTransformFeedbackStreamInstanced(mode uint32, id uint32, stream uint32, instancecount int32) { C.glowDrawTransformFeedbackStreamInstanced(gpDrawTransformFeedbackStreamInstanced, (C.GLenum)(mode), (C.GLuint)(id), (C.GLuint)(stream), (C.GLsizei)(instancecount)) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func (self *StraightLineTrack) Render(render chan Object) {\n\tfor _, val := range self.Childs() {\n\t\trender <- val\n\t}\n}", "func (p *Processor) Render() vdom.Element {\n\tmaxConnectors := p.ProcessorDefinition.MaxConnectors()\n\tprocName := p.ProcessorDefinition.Name\n\tprocDefName, procInputs, procOutputs, procParameters := p.ProcessorDefinition.Processor.Definition()\n\tif len(procName) == 0 {\n\t\tprocName = procDefName\n\t}\n\n\tprocWidth := procDefaultWidth\n\tprocHeight := (maxConnectors + 2 + len(procParameters)) * procConnWidth * 2\n\n\tcustomRenderDimentions, ok := p.ProcessorDefinition.Processor.(customRenderDimentions)\n\tif ok {\n\t\tprocWidth, procHeight = customRenderDimentions.CustomRenderDimentions()\n\t}\n\n\tprocNameLabel := vdom.MakeElement(\"text\",\n\t\t\"font-family\", \"sans-serif\",\n\t\t\"text-anchor\", \"middle\",\n\t\t\"alignment-baseline\", \"hanging\",\n\t\t\"font-size\", 10,\n\t\t\"x\", p.ProcessorDefinition.X+procWidth/2,\n\t\t\"y\", p.ProcessorDefinition.Y+4,\n\t\tvdom.MakeTextElement(procName),\n\t)\n\tprocLine := vdom.MakeElement(\"line\",\n\t\t\"stroke\", \"black\",\n\t\t\"x1\", float64(p.ProcessorDefinition.X)+0.5,\n\t\t\"y1\", float64(p.ProcessorDefinition.Y)+16+0.5,\n\t\t\"x2\", float64(p.ProcessorDefinition.X)+float64(procWidth)+0.5,\n\t\t\"y2\", float64(p.ProcessorDefinition.Y)+16+0.5,\n\t)\n\n\tinConnectors := []vdom.Element{}\n\tfor i := 0; i < len(procInputs); i++ {\n\t\tx, y := p.GetConnectorPoint(procWidth, true, i)\n\t\tconnector := vdom.MakeElement(\"rect\",\n\t\t\t\"id\", procName+\":inconn:\"+strconv.Itoa(i),\n\t\t\t\"x\", x-procConnWidth/2,\n\t\t\t\"y\", y-procConnWidth/2,\n\t\t\t\"width\", procConnWidth,\n\t\t\t\"height\", procConnWidth,\n\t\t\t\"stroke\", \"black\",\n\t\t\t\"fill\", \"none\",\n\t\t\t\"pointer-events\", \"all\",\n\t\t\t\"cursor\", \"crosshair\",\n\t\t\tvdom.MakeEventHandler(vdom.MouseDown, p.makeConnectorEventHandler(true, i)),\n\t\t\tvdom.MakeEventHandler(vdom.MouseMove, p.makeConnectorEventHandler(true, i)),\n\t\t)\n\t\tinConnectors = append(inConnectors, connector)\n\n\t\tlabel := vdom.MakeElement(\"text\",\n\t\t\t\"font-family\", \"sans-serif\",\n\t\t\t\"text-anchor\", \"start\",\n\t\t\t\"alignment-baseline\", \"middle\",\n\t\t\t\"font-size\", 10,\n\t\t\t\"x\", x+(procConnWidth/2+2),\n\t\t\t\"y\", y,\n\t\t\tvdom.MakeTextElement(procInputs[i]),\n\t\t)\n\t\tinConnectors = append(inConnectors, label)\n\t}\n\n\toutConnectors := []vdom.Element{}\n\tfor i := 0; i < len(procOutputs); i++ {\n\t\tx, y := p.GetConnectorPoint(procWidth, false, i)\n\t\tconnector := vdom.MakeElement(\"rect\",\n\t\t\t\"id\", procName+\":outconn:\"+strconv.Itoa(i),\n\t\t\t\"x\", x-procConnWidth/2,\n\t\t\t\"y\", y-procConnWidth/2,\n\t\t\t\"width\", procConnWidth,\n\t\t\t\"height\", procConnWidth,\n\t\t\t\"stroke\", \"black\",\n\t\t\t\"fill\", \"none\",\n\t\t\t\"pointer-events\", \"all\",\n\t\t\t\"cursor\", \"crosshair\",\n\t\t\tvdom.MakeEventHandler(vdom.MouseDown, p.makeConnectorEventHandler(false, i)),\n\t\t\tvdom.MakeEventHandler(vdom.MouseMove, p.makeConnectorEventHandler(false, i)),\n\t\t)\n\t\toutConnectors = append(outConnectors, connector)\n\n\t\tlabel := vdom.MakeElement(\"text\",\n\t\t\t\"font-family\", \"sans-serif\",\n\t\t\t\"text-anchor\", \"end\",\n\t\t\t\"alignment-baseline\", \"middle\",\n\t\t\t\"font-size\", 10,\n\t\t\t\"x\", x-(procConnWidth/2+4),\n\t\t\t\"y\", y,\n\t\t\tvdom.MakeTextElement(procOutputs[i]),\n\t\t)\n\t\toutConnectors = append(outConnectors, label)\n\t}\n\n\tparameters := []vdom.Element{}\n\tfor i := 0; i < len(procParameters); i++ {\n\t\t_, y := p.GetConnectorPoint(procWidth, true, i+maxConnectors)\n\n\t\twidth := procWidth - ((procConnWidth + 2) * 2)\n\t\tlevelValue := strconv.FormatFloat(float64(procParameters[i].Value), 'f', -1, 32)\n\t\tlevelWidth := int(float32(width) * (procParameters[i].Value / procParameters[i].Max))\n\t\tlevelFactor := float32(width) / procParameters[i].Max\n\n\t\tlevel := vdom.MakeElement(\"rect\",\n\t\t\t\"id\", procName+\":parameter:\"+strconv.Itoa(i),\n\t\t\t\"x\", p.ProcessorDefinition.X+procConnWidth+2,\n\t\t\t\"y\", y-2,\n\t\t\t\"width\", levelWidth,\n\t\t\t\"height\", procConnWidth+4,\n\t\t\t\"stroke\", \"none\",\n\t\t\t\"fill\", \"cyan\",\n\t\t\t\"pointer-events\", \"none\",\n\t\t)\n\t\tparameters = append(parameters, level)\n\n\t\tbound := vdom.MakeElement(\"rect\",\n\t\t\t\"id\", procName+\":parameter:\"+strconv.Itoa(i),\n\t\t\t\"x\", p.ProcessorDefinition.X+procConnWidth+2,\n\t\t\t\"y\", y-2,\n\t\t\t\"width\", width,\n\t\t\t\"height\", procConnWidth+4,\n\t\t\t\"stroke\", \"black\",\n\t\t\t\"fill\", \"none\",\n\t\t\t\"pointer-events\", \"all\",\n\t\t\t\"cursor\", \"crosshair\",\n\t\t\tvdom.MakeEventHandler(vdom.MouseDown, p.makeParameterEventHandler(i, levelFactor)),\n\t\t\tvdom.MakeEventHandler(vdom.MouseUp, p.makeParameterEventHandler(i, levelFactor)),\n\t\t\tvdom.MakeEventHandler(vdom.MouseMove, p.makeParameterEventHandler(i, levelFactor)),\n\t\t\tvdom.MakeEventHandler(vdom.MouseLeave, p.makeParameterEventHandler(i, levelFactor)),\n\t\t\tvdom.MakeElement(\"title\", vdom.MakeTextElement(levelValue)),\n\t\t)\n\t\tparameters = append(parameters, bound)\n\n\t\tname := vdom.MakeElement(\"text\",\n\t\t\t\"font-family\", \"sans-serif\",\n\t\t\t\"text-anchor\", \"middle\",\n\t\t\t\"alignment-baseline\", \"hanging\",\n\t\t\t\"font-size\", 10,\n\t\t\t\"x\", p.ProcessorDefinition.X+(procWidth/2),\n\t\t\t\"y\", y,\n\t\t\tvdom.MakeTextElement(procParameters[i].Name))\n\t\tparameters = append(parameters, name)\n\t}\n\n\telement := vdom.MakeElement(\"g\",\n\t\tvdom.MakeElement(\"rect\",\n\t\t\t\"id\", procName,\n\t\t\t\"x\", p.ProcessorDefinition.X,\n\t\t\t\"y\", p.ProcessorDefinition.Y,\n\t\t\t\"width\", procWidth,\n\t\t\t\"height\", procHeight,\n\t\t\t\"stroke\", \"black\",\n\t\t\t\"fill\", \"white\",\n\t\t\t\"cursor\", \"pointer\",\n\t\t\tvdom.MakeEventHandler(vdom.MouseDown, p.processorEventHandler),\n\t\t\tvdom.MakeEventHandler(vdom.MouseUp, p.processorEventHandler),\n\t\t\tvdom.MakeEventHandler(vdom.MouseMove, p.processorEventHandler),\n\t\t\tvdom.MakeEventHandler(vdom.ContextMenu, p.processorEventHandler),\n\t\t),\n\t\tprocNameLabel,\n\t\tprocLine,\n\t\tinConnectors,\n\t\toutConnectors,\n\t\tparameters,\n\t)\n\n\tcustom, ok := p.ProcessorDefinition.Processor.(vdom.Component)\n\tif ok {\n\t\telement.AppendChild(vdom.MakeElement(\"g\",\n\t\t\t\"transform\", \"translate(\"+strconv.Itoa(p.ProcessorDefinition.X)+\",\"+strconv.Itoa(p.ProcessorDefinition.Y)+\")\",\n\t\t\tcustom,\n\t\t))\n\t}\n\n\treturn element\n}", "func (e *rawData) Render(w io.Writer) (int, error) { return w.Write([]byte(e.content)) }", "func Render(r *sdl.Renderer, w *World) {\n\twidth := float64(r.GetViewport().W)\n\theight := float64(r.GetViewport().H)\n\n\trenderedVertices := [][2]int{}\n\n\tfor _, obj := range w.Objects {\n\t\tfor _, vertex := range obj.Geometry.Vertices {\n\t\t\trenderCoordinates := AsRelativeToSystem(w.ActiveCamera.ObjSys, ToSystem(obj.ObjSys, vertex.Pos))\n\n\t\t\tZ := Clamp(renderCoordinates.Z, 0.0001, math.NaN())\n\t\t\tratio := w.ActiveCamera.FocalLength / math.Abs(Z)\n\t\t\trenderX := ratio * renderCoordinates.X\n\t\t\trenderY := ratio * renderCoordinates.Y\n\n\t\t\tnormX, normY := NormalizeScreen(\n\t\t\t\twidth,\n\t\t\t\theight,\n\t\t\t\trenderX,\n\t\t\t\trenderY,\n\t\t\t)\n\n\t\t\trasterX := int(math.Floor(normX*width) + width/2)\n\t\t\trasterY := int(math.Floor(normY*height) + height/2)\n\n\t\t\trenderedVertices = append(renderedVertices, [2]int{rasterX, rasterY})\n\n\t\t\tDrawCircle(r, rasterX, rasterY, 5)\n\t\t}\n\t\tfor _, edge := range obj.Geometry.Edges {\n\t\t\tif len(renderedVertices) > edge.From && len(renderedVertices) > edge.To {\n\t\t\t\tr.DrawLine(\n\t\t\t\t\tint32(renderedVertices[edge.From][0]),\n\t\t\t\t\tint32(renderedVertices[edge.From][1]),\n\t\t\t\t\tint32(renderedVertices[edge.To][0]),\n\t\t\t\t\tint32(renderedVertices[edge.To][1]),\n\t\t\t\t)\n\t\t\t}\n\t\t}\n\t}\n\n\tr.Present()\n}", "func (r *Renderer) Render() {\n\tsx, sz, sy := r.c.Bounds()\n\tsxf := float64(sx - 1)\n\tsyf := float64(sy - 1)\n\tszf := float64(sz - 1)\n\tfor z := 0; z < sz; z++ {\n\t\tfor y := 0; y < sy; y++ {\n\t\t\tfor x := 0; x < sx; x++ {\n\t\t\t\tvar lr, lg, lb, _ uint32\n\t\t\t\tn := uint32(0)\n\t\t\t\tfor _, o := range r.objects {\n\t\t\t\t\tr, g, b, _ := o.At(float64(x)/sxf, float64(y)/syf, float64(z)/szf).RGBA()\n\t\t\t\t\tlr += r >> 8\n\t\t\t\t\tlg += g >> 8\n\t\t\t\t\tlb += b >> 8\n\t\t\t\t\tn++\n\t\t\t\t}\n\t\t\t\tr.c.Set(x, y, z, color.RGBA{uint8(lr/n), uint8(lg/n), uint8(lb/n), 255})\n\t\t\t}\n\t\t}\n\t}\n\tr.c.Render()\n}", "func (sr scoresRenderer) Render() string {\n\tbuffer := bytes.Buffer{}\n\tlast := len(sr.scores) - 1\n\tfor i, score := range sr.scores {\n\t\tbuffer.WriteString(fmt.Sprintf(\"%d\", score))\n\t\tif i != last {\n\t\t\tbuffer.WriteString(\" / \")\n\t\t}\n\t}\n\treturn buffer.String()\n}", "func (self *CircularTrack) Render(render chan Object) {\n\trender <- self\n\tfor _, val := range self.Childs() {\n\t\trender <- val\n\t}\n}", "func Count() Stream {\n return &count{0, 1}\n}", "func (rf RendererFunc) Render(w io.Writer, v interface{}) error { return rf(w, v) }", "func (c *ConnectionSPI) Render(pixels []RGBPixel) {\r\n\tlogFields := log.Fields{\"package\": logPkg, \"conn\": \"SPI\", \"func\": \"RenderLEDs\"}\r\n\tlog.WithFields(logFields).Infof(\"Render %d LEDs\", len(pixels))\r\n\t// Fix for Raspberry Pi 3 Model B+ (5.15.84-v7+)\r\n\t// Data signal seems to be splitted sending less than 11 LEDS\r\n\tif len(pixels) < 11 {\r\n\t\tpixels = append(pixels, []RGBPixel{{}, {}, {}, {}, {}, {}, {}, {}, {}, {}}...)\r\n\t}\r\n\tvar translatedRGBs []uint8\r\n\tfor _, pixel := range pixels {\r\n\r\n\t\tcolorData := GetColorData(pixel, c.FixSPI)\r\n\t\tlog.WithFields(logFields).Tracef(\"%08b\", pixel)\r\n\r\n\t\tfor _, c := range colorData {\r\n\t\t\ttranslatedRGBs = append(translatedRGBs, c)\r\n\t\t}\r\n\t}\r\n\r\n\tc.transfer(translatedRGBs)\r\n}", "func render(fset *token.FileSet, x interface{}) string {\n\tvar buf bytes.Buffer\n\tif err := printer.Fprint(&buf, fset, x); err != nil {\n\t\tpanic(err)\n\t}\n\treturn buf.String()\n}", "func render(fset *token.FileSet, x interface{}) string {\n\tvar buf bytes.Buffer\n\tif err := printer.Fprint(&buf, fset, x); err != nil {\n\t\tpanic(err)\n\t}\n\treturn buf.String()\n}", "func CountPrintf(f string, vals ...interface{}) {\n\tcount++\n\tfmt.Printf(fmt.Sprintf(\"%d - \", count)+f, vals...)\n}", "func (c *regularResourceComponent) Render(out io.Writer) (numLines int, err error) {\n\tc.mu.Lock()\n\tdefer c.mu.Unlock()\n\n\tcomponents := cfnLineItemComponents(c.description, c.separator, c.statuses, c.stopWatch, c.padding)\n\treturn renderComponents(out, components)\n}", "func renderResults(vals []interface{}) Data {\n\tvar nilcount int\n\tvar obj interface{}\n\tfor _, val := range vals {\n\t\tswitch val.(type) {\n\t\tcase image.Image, Data:\n\t\t\tobj = val\n\t\tcase nil:\n\t\t\tnilcount++\n\t\t}\n\t}\n\tif obj != nil && nilcount == len(vals)-1 {\n\t\tswitch val := obj.(type) {\n\t\tcase image.Image:\n\t\t\tdata, err := image0(val)\n\t\t\tif err == nil {\n\t\t\t\treturn data\n\t\t\t}\n\t\tcase Data:\n\t\t\treturn val\n\t\t}\n\t}\n\tif nilcount == len(vals) {\n\t\t// if all values are nil, return empty Data\n\t\treturn Data{}\n\t}\n\treturn MakeData(\"text/plain\", fmt.Sprint(vals...))\n}", "func TransformFeedbackVaryings(program uint32, count int32, varyings **int8, bufferMode uint32) {\n C.glowTransformFeedbackVaryings(gpTransformFeedbackVaryings, (C.GLuint)(program), (C.GLsizei)(count), (**C.GLchar)(unsafe.Pointer(varyings)), (C.GLenum)(bufferMode))\n}", "func DrawTransformFeedbackStreamInstanced(mode uint32, id uint32, stream uint32, instancecount int32) {\n C.glowDrawTransformFeedbackStreamInstanced(gpDrawTransformFeedbackStreamInstanced, (C.GLenum)(mode), (C.GLuint)(id), (C.GLuint)(stream), (C.GLsizei)(instancecount))\n}", "func (ren *RenderComponent) generateBufferContent() []float32 {\n\tscaleX := ren.scale.X\n\tscaleY := ren.scale.Y\n\trotation := float32(0.0)\n\ttransparency := float32(1.0)\n\tc := ren.Color\n\n\tfx := float32(0)\n\tfy := float32(0)\n\tfx2 := ren.drawable.Width()\n\tfy2 := ren.drawable.Height()\n\n\tif scaleX != 1 || scaleY != 1 {\n\t\t//fx *= scaleX\n\t\t//fy *= scaleY\n\t\tfx2 *= scaleX\n\t\tfy2 *= scaleY\n\t}\n\n\tp1x := fx\n\tp1y := fy\n\tp2x := fx\n\tp2y := fy2\n\tp3x := fx2\n\tp3y := fy2\n\tp4x := fx2\n\tp4y := fy\n\n\tvar x1 float32\n\tvar y1 float32\n\tvar x2 float32\n\tvar y2 float32\n\tvar x3 float32\n\tvar y3 float32\n\tvar x4 float32\n\tvar y4 float32\n\n\tif rotation != 0 {\n\t\trot := rotation * (math.Pi / 180.0)\n\n\t\tcos := math.Cos(rot)\n\t\tsin := math.Sin(rot)\n\n\t\tx1 = cos*p1x - sin*p1y\n\t\ty1 = sin*p1x + cos*p1y\n\n\t\tx2 = cos*p2x - sin*p2y\n\t\ty2 = sin*p2x + cos*p2y\n\n\t\tx3 = cos*p3x - sin*p3y\n\t\ty3 = sin*p3x + cos*p3y\n\n\t\tx4 = x1 + (x3 - x2)\n\t\ty4 = y3 - (y2 - y1)\n\t} else {\n\t\tx1 = p1x\n\t\ty1 = p1y\n\n\t\tx2 = p2x\n\t\ty2 = p2y\n\n\t\tx3 = p3x\n\t\ty3 = p3y\n\n\t\tx4 = p4x\n\t\ty4 = p4y\n\t}\n\n\tcolorR, colorG, colorB, _ := c.RGBA()\n\n\tred := colorR\n\tgreen := colorG << 8\n\tblue := colorB << 16\n\talpha := uint32(transparency*255.0) << 24\n\n\ttint := math.Float32frombits((alpha | blue | green | red) & 0xfeffffff)\n\n\tu, v, u2, v2 := ren.drawable.View()\n\n\treturn []float32{x1, y1, u, v, tint, x4, y4, u2, v, tint, x3, y3, u2, v2, tint, x2, y2, u, v2, tint}\n}", "func Render(s api.Session, renderAs RenderName, value dgo.Value, out io.Writer) {\n\t// Convert value to rich data format without references\n\tdedupStream := func(value dgo.Value, consumer streamer.Consumer) {\n\t\topts := streamer.DefaultOptions()\n\t\topts.DedupLevel = streamer.NoDedup\n\t\tser := streamer.New(s.AliasMap(), opts)\n\t\tser.Stream(value, consumer)\n\t}\n\n\tswitch renderAs {\n\tcase JSON:\n\t\tif value.Equals(vf.Nil) {\n\t\t\tutil.WriteString(out, \"null\\n\")\n\t\t} else {\n\t\t\tdedupStream(value, streamer.JSON(out))\n\t\t\tutil.WriteByte(out, '\\n')\n\t\t}\n\n\tcase YAML:\n\t\tif value.Equals(vf.Nil) {\n\t\t\tutil.WriteString(out, \"\\n\")\n\t\t} else {\n\t\t\tdc := streamer.DataCollector()\n\t\t\tdedupStream(value, dc)\n\t\t\tbs, err := yaml.Marshal(dc.Value())\n\t\t\tif err != nil {\n\t\t\t\tpanic(err)\n\t\t\t}\n\t\t\tutil.WriteString(out, string(bs))\n\t\t}\n\tcase Binary:\n\t\tbi := vf.New(typ.Binary, value).(dgo.Binary)\n\t\t_, err := out.Write(bi.GoBytes())\n\t\tif err != nil {\n\t\t\tpanic(err)\n\t\t}\n\tcase Text:\n\t\tutil.Fprintln(out, value)\n\tdefault:\n\t\tpanic(fmt.Errorf(`unknown rendering '%s'`, renderAs))\n\t}\n}", "func (v *View) Renderer(matcher func(instance.Description) bool) (func(w io.Writer, v interface{}) error, error) {\n\ttagsView, err := template.NewTemplate(template.ValidURL(v.tagsTemplate), v.options)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\tpropertiesView, err := template.NewTemplate(template.ValidURL(v.propertiesTemplate), v.options)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\n\treturn func(w io.Writer, result interface{}) error {\n\n\t\tinstances, is := result.([]instance.Description)\n\t\tif !is {\n\t\t\treturn fmt.Errorf(\"not []instance.Description\")\n\t\t}\n\n\t\tif !v.quiet {\n\t\t\tif v.viewTemplate != \"\" {\n\t\t\t\tfmt.Printf(\"%-30s\\t%-30s\\n\", \"ID\", \"VIEW\")\n\t\t\t} else if v.properties {\n\t\t\t\tfmt.Printf(\"%-30s\\t%-30s\\t%-30s\\t%-s\\n\", \"ID\", \"LOGICAL\", \"TAGS\", \"PROPERTIES\")\n\n\t\t\t} else {\n\t\t\t\tfmt.Printf(\"%-30s\\t%-30s\\t%-s\\n\", \"ID\", \"LOGICAL\", \"TAGS\")\n\t\t\t}\n\t\t}\n\t\tfor _, d := range instances {\n\n\t\t\t// TODO - filter on the client side by tags\n\t\t\tif len(v.TagFilter()) > 0 {\n\t\t\t\tif hasDifferentTag(v.TagFilter(), d.Tags) {\n\t\t\t\t\tcontinue\n\t\t\t\t}\n\t\t\t}\n\t\t\tif matcher != nil {\n\t\t\t\tif !matcher(d) {\n\t\t\t\t\tcontinue\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tlogical := \" - \"\n\t\t\tif d.LogicalID != nil {\n\t\t\t\tlogical = string(*d.LogicalID)\n\t\t\t}\n\n\t\t\tif v.viewTemplate != \"\" {\n\n\t\t\t\tcolumn := \"-\"\n\t\t\t\tif view, err := d.View(v.viewTemplate); err == nil {\n\t\t\t\t\tcolumn = view\n\t\t\t\t} else {\n\t\t\t\t\tcolumn = err.Error()\n\t\t\t\t}\n\t\t\t\tfmt.Printf(\"%-30s\\t%-30s\\n\", d.ID, column)\n\n\t\t\t} else {\n\n\t\t\t\ttagViewBuff := \"\"\n\t\t\t\tif v.tagsTemplate == \"*\" {\n\t\t\t\t\t// default -- this is a hack\n\t\t\t\t\tprintTags := []string{}\n\t\t\t\t\tfor k, v := range d.Tags {\n\t\t\t\t\t\tprintTags = append(printTags, fmt.Sprintf(\"%s=%s\", k, v))\n\t\t\t\t\t}\n\t\t\t\t\tsort.Strings(printTags)\n\t\t\t\t\ttagViewBuff = strings.Join(printTags, \",\")\n\t\t\t\t} else {\n\t\t\t\t\ttagViewBuff = renderTags(d.Tags, tagsView)\n\t\t\t\t}\n\n\t\t\t\tif v.properties {\n\n\t\t\t\t\tif v.quiet {\n\t\t\t\t\t\t// special render only the properties\n\t\t\t\t\t\tfmt.Printf(\"%s\", renderProperties(d.Properties, propertiesView))\n\t\t\t\t\t} else {\n\t\t\t\t\t\tfmt.Printf(\"%-30s\\t%-30s\\t%-30s\\t%-s\\n\", d.ID, logical, tagViewBuff,\n\t\t\t\t\t\t\trenderProperties(d.Properties, propertiesView))\n\t\t\t\t\t}\n\t\t\t\t} else {\n\t\t\t\t\tfmt.Printf(\"%-30s\\t%-30s\\t%-s\\n\", d.ID, logical, tagViewBuff)\n\t\t\t\t}\n\n\t\t\t}\n\t\t}\n\t\treturn nil\n\t}, nil\n}", "func (o GroupContainerGpuOutput) Count() pulumi.IntPtrOutput {\n\treturn o.ApplyT(func(v GroupContainerGpu) *int { return v.Count }).(pulumi.IntPtrOutput)\n}", "func (r *JSONRenderer) Render(out io.Writer, st *papers.Stats, unread, read papers.AggPapers) {\n\tr.render(out, st, unread, read)\n}", "func (v Binary) Render(i, width int, baseStyle lipgloss.Style) string {\n\tw := dataWidth(width)\n\t_, err := v.Seek(int64(i*w), io.SeekStart)\n\tif err != nil {\n\t\treturn baseStyle.Blink(true).Render(err.Error())\n\t}\n\tif len(v.b) != w {\n\t\tv.b = make([]byte, w)\n\t}\n\tn, err := v.Read(v.b)\n\tif err != nil && !errors.Is(err, io.EOF) {\n\t\treturn baseStyle.Blink(true).Render(err.Error())\n\t}\n\ts := fmt.Sprintf(\"% X%s \", v.b[0:n], strings.Repeat(\" \", w-n))\n\tvar x strings.Builder\n\tfor i := 0; i < n; i++ {\n\t\tif unicode.IsPrint(rune(v.b[i])) {\n\t\t\tx.WriteRune(rune(v.b[i]))\n\t\t} else {\n\t\t\tx.WriteRune('.')\n\t\t}\n\t}\n\treturn baseStyle.Render(s + x.String())\n}", "func Render(state *model.Model) time.Duration {\n\tt := time.Now()\n\n\trenderer.SetDrawColor(255, 255, 255, 255)\n\trenderer.FillRect(fullScreenRect)\n\n\tcurrentSurface, _ := window.GetSurface()\n\n\tl := layout.New(screenWidth, screenHeight)\n\n\tinstruments := l.Row(instrumentHeight)\n\tdistanceCell := instruments.Col(columnWidth)\n\tspeedCell := instruments.Col(columnWidth)\n\theadingCell := instruments.Col(columnWidth)\n\n\tRenderHeadingCell(state, currentSurface, headingCell)\n\tRenderDistanceCell(state, currentSurface, distanceCell)\n\tRenderSpeedCell(state, currentSurface, speedCell)\n\n\trenderer.SetDrawColor(255, 255, 255, 255)\n\n\t// waypoints 1 - 3\n\tif len(state.Book) > 0 {\n\t\t//TODO: breaks if there aren't Idx + 3 remaining\n\t\tfor idx, waypoint := range state.Book[state.Idx : state.Idx+3] {\n\t\t\ty := int32(instrumentHeight + idx*waypointHeight)\n\t\t\tbg := &sdl.Rect{0, y, int32(screenWidth), int32(waypointHeight)}\n\t\t\tr, g, b, _ := waypoint.Background.RGBA()\n\n\t\t\t// box\n\t\t\trenderer.SetDrawColor(uint8(r), uint8(g), uint8(b), 255)\n\t\t\trenderer.FillRect(bg)\n\n\t\t\t// distance\n\t\t\ttextBg := sdl.Color{uint8(r), uint8(g), uint8(b), 255}\n\t\t\ttextFg := sdl.Color{0, 0, 0, 255}\n\t\t\tif waypoint.Background == color.Black {\n\t\t\t\ttextFg = sdl.Color{255, 255, 255, 255}\n\t\t\t}\n\n\t\t\tdistanceFormat := \"%0.1f\"\n\t\t\tif (appcontext.GContext.NumAfterDecimal == 2) {\n\t\t\t\tdistanceFormat = \"%0.2f\"\n\t\t\t}\n\t\t\tdistance, _ := dinMedium144.RenderUTF8Shaded(strings.Replace(fmt.Sprintf(distanceFormat, waypoint.Distance), \".\", \",\", -1), textFg, textBg)\n\n\t\t\tdistRect := distance.ClipRect\n\t\t\tdistance.Blit(nil, currentSurface, &sdl.Rect{(columnWidth - distRect.W) / 2, bg.Y + (waypointHeight-distRect.H)/2, 0, 0})\n\t\t\tdistance.Free()\n\n\t\t\t// tulip and notes\n\t\t\tpair := getTulipNotesPair(state.Idx+idx, &waypoint)\n\n\t\t\tpair.tulip.Blit(nil, currentSurface, &sdl.Rect{columnWidth, bg.Y + (waypointHeight-TulipHeight)/2, 0, 0})\n\t\t\tpair.notes.Blit(nil, currentSurface, &sdl.Rect{columnWidth * 2, bg.Y + (waypointHeight-NotesHeight)/2, 0, 0})\n\n\t\t\t// divider\n\t\t\trenderer.SetDrawColor(0, 0, 0, 255)\n\t\t\tbg.H = dividerHeight\n\t\t\trenderer.FillRect(bg)\n\t\t}\n\t\t//TODO: draw divider even when no waypoints exist\n\t}\n\n\tgc := appcontext.GContext\n\tgm := appmanager.GAppManager\n\n\tmainWindowSurface := gc.MainSurface\n\tgm.Render(mainWindowSurface)\n\n\t// display frame\n\trenderer.Present()\n\n\t// ensure we wait at least frameDuration\n\tfpsDelay := frameDuration - time.Since(t)\n\treturn fpsDelay\n}", "func (a *World) Render(p *pic.Pic) *World {\n\th, w := p.H, p.W\n\tfh, fw := float64(h), float64(w)\n\tcx := vec.New(fw*a.Ratio/fh, 0, 0)\n\tcy := vec.Mult(vec.Norm(vec.Cross(cx, a.Cam.Direct)), a.Ratio)\n\tsample := a.Sample / 4\n\tinv := 1.0 / float64(sample)\n\n\tfmt.Printf(\"w: %v, h: %v, sample: %v, actual sample: %v, thread: %v, cpu: %v\\n\", w, h, a.Sample, sample*4, a.Thread, a.Core)\n\tbar := pb.StartNew(h * w)\n\tbar.SetRefreshRate(1000 * time.Millisecond)\n\n\truntime.GOMAXPROCS(a.Core)\n\tch := make(chan renderData, a.Thread)\n\twg := sync.WaitGroup{}\n\twg.Add(a.Thread)\n\n\tfor tid := 0; tid < a.Thread; tid++ {\n\t\tgo func() {\n\t\t\tfor {\n\t\t\t\tdata, ok := <-ch\n\t\t\t\tif !ok {\n\t\t\t\t\twg.Done()\n\t\t\t\t\treturn\n\t\t\t\t}\n\t\t\t\tsum, x, y := data.sum, data.x, data.y\n\t\t\t\tfor sy := 0.0; sy < 2.0; sy++ {\n\t\t\t\t\tfor sx := 0.0; sx < 2.0; sx++ {\n\t\t\t\t\t\tc := vec.NewZero()\n\t\t\t\t\t\tfor sp := 0; sp < sample; sp++ {\n\t\t\t\t\t\t\tccx := vec.Mult(cx, ((sx+0.5+gend())/2.0+x)/fw-0.5)\n\t\t\t\t\t\t\tccy := vec.Mult(cy, ((sy+0.5+gend())/2.0+y)/fh-0.5)\n\t\t\t\t\t\t\td := vec.Add(vec.Add(ccx, ccy), a.Cam.Direct)\n\t\t\t\t\t\t\tr := ray.New(vec.Add(a.Cam.Origin, vec.Mult(d, 130)), vec.Norm(d))\n\t\t\t\t\t\t\tc.Add(vec.Mult(a.trace(r, 0), inv))\n\t\t\t\t\t\t}\n\t\t\t\t\t\tsum.Add(vec.Mult(vec.New(pic.Clamp(c.X), pic.Clamp(c.Y), pic.Clamp(c.Z)), 0.25))\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tbar.Add(1)\n\t\t\t}\n\t\t}()\n\t}\n\n\tfor y := 0; y < h; y++ {\n\t\tfor x := 0; x < w; x++ {\n\t\t\tch <- renderData{\n\t\t\t\tsum: &p.C[(h-y-1)*w+x],\n\t\t\t\tx: float64(x),\n\t\t\t\ty: float64(y),\n\t\t\t}\n\t\t}\n\t}\n\n\tclose(ch)\n\twg.Wait()\n\n\tbar.FinishPrint(\"Rendering completed\")\n\treturn a\n}", "func streamMulti(client pb.RouteGuideClient) {\n\tfor i := 0; i < 10; i++ {\n\t\t// Looking for a valid feature\n\t\tprintFeatures(client, &pb.Rectangle{\n\t\t\tLo: &pb.Point{Latitude: 400000000, Longitude: -750000000},\n\t\t\tHi: &pb.Point{Latitude: 420000000, Longitude: -730000000},\n\t\t})\n\t\ttime.Sleep(3 * time.Second)\n\t}\n}", "func render(ctx aero.Context, allActivities []arn.Activity) error {\n\tuser := arn.GetUserFromContext(ctx)\n\tindex, _ := ctx.GetInt(\"index\")\n\n\t// Slice the part that we need\n\tactivities := allActivities[index:]\n\tmaxLength := activitiesFirstLoad\n\n\tif index > 0 {\n\t\tmaxLength = activitiesPerScroll\n\t}\n\n\tif len(activities) > maxLength {\n\t\tactivities = activities[:maxLength]\n\t}\n\n\t// Next index\n\tnextIndex := infinitescroll.NextIndex(ctx, len(allActivities), maxLength, index)\n\n\t// In case we're scrolling, send activities only (without the page frame)\n\tif index > 0 {\n\t\treturn ctx.HTML(components.ActivitiesScrollable(activities, user))\n\t}\n\n\t// Otherwise, send the full page\n\treturn ctx.HTML(components.ActivityFeed(activities, nextIndex, user))\n}", "func (c *stackComponent) Render(out io.Writer) (numLines int, err error) {\n\tc.mu.Lock()\n\tdefer c.mu.Unlock()\n\n\treturn renderComponents(out, c.resources)\n}", "func MultiDrawElements(mode uint32, count *int32, xtype uint32, indices *unsafe.Pointer, drawcount int32) {\n C.glowMultiDrawElements(gpMultiDrawElements, (C.GLenum)(mode), (*C.GLsizei)(unsafe.Pointer(count)), (C.GLenum)(xtype), indices, (C.GLsizei)(drawcount))\n}", "func (c *cartridge) Render() {\n\tc.Cls()\n\tc.PrintAt(fmt.Sprintf(\"counter:%d\", c.counter), c.x, c.y)\n}", "func (params complexPropertyConversionParameters) countArraysAndMapsInConversionContext() int {\n\tresult := 0\n\tfor _, t := range params.conversionContext {\n\t\tswitch t.(type) {\n\t\tcase *astmodel.MapType:\n\t\t\tresult += 1\n\t\tcase *astmodel.ArrayType:\n\t\t\tresult += 1\n\t\t}\n\t}\n\n\treturn result\n}", "func (h Hand) Render() string {\n\tbuffer := bytes.Buffer{}\n\tlast := len(h.Cards) - 1\n\tfor i, card := range h.Cards {\n\t\tbuffer.WriteString(card.Render())\n\t\tif i != last {\n\t\t\tbuffer.WriteString(\", \")\n\t\t}\n\t}\n\tbuffer.WriteString(fmt.Sprintf(\n\t\t\" (%s)\", scoresRenderer{h.Scores()}.Render(),\n\t))\n\treturn strings.Trim(buffer.String(), \" \")\n}", "func CountAndSay(n int) string {\n\tres := \"1\"\n\tfor i := 0; i < n-1; i++ {\n\t\tres = translate(res)\n\t}\n\treturn res\n}", "func (f *Factory) Counter(name string, tags map[string]string) metrics.Counter {\n\tcounter := &counter{\n\t\tcounters: make([]metrics.Counter, len(f.factories)),\n\t}\n\tfor i, factory := range f.factories {\n\t\tcounter.counters[i] = factory.Counter(name, tags)\n\t}\n\treturn counter\n}", "func AgeSpout(tuple []interface{}, result *[]interface{}, variables *[]interface{}) error {\n\t// Variables\n\tvar counterMap map[string]interface{}\n\tvar idArray interface{}\n\tvar ageArray interface{}\n\n\tif (len(*variables) == 0) {\n\t\tcounterMap = make(map[string]interface{})\n\t\t*variables = append(*variables, counterMap)\n\t\tcounterMap[\"counter\"] = float64(0)\n\n\t\tfile, _ := os.Open(\"data.json\")\n\t\tdefer file.Close()\n\n\t\tb, _ := ioutil.ReadAll(file)\n\t\tvar object interface{}\n\t\tjson.Unmarshal(b, &object)\n\t\tobjectMap := object.(map[string]interface{})\n\t\tidArray = objectMap[\"id\"].([]interface{})\n\t\tageArray = objectMap[\"age\"].([]interface{})\n\n\t\t*variables = append(*variables, idArray)\n\t\t*variables = append(*variables, ageArray)\n\t}\n\tcounterMap = (*variables)[0].(map[string]interface{})\n\tidArray = (*variables)[1]\n\tageArray = (*variables)[2]\n\n\t// Logic\n\tif counterMap[\"counter\"].(float64) < 1000 {\n\t\t*result = []interface{}{idArray.([]interface{})[int(counterMap[\"counter\"].(float64))], ageArray.([]interface{})[int(counterMap[\"counter\"].(float64))]}\n\t\tcounterMap[\"counter\"] = counterMap[\"counter\"].(float64) + 1\n\t}\n\n\t// // Logic\n\t// if counterMap[\"counter\"].(float64) < 800 {\n\t// \t*result = []interface{}{strconv.Itoa(int(counterMap[\"counter\"].(float64))), strconv.Itoa(int(counterMap[\"counter\"].(float64)) + 20)}\n\t// \tcounterMap[\"counter\"] = counterMap[\"counter\"].(float64) + 1\n\t// }\n\n\ttime.Sleep(1 * time.Millisecond)\n\n\t// Return value\n\tif (len(*result) > 0) {\n\t\tlog.Printf(\"Age Spout Emit (%v)\\n\", *result)\n\t\treturn nil\n\t} else {\n\t\treturn errors.New(\"next tuple is nil\")\n\t}\n}", "func (h *HAProxyManager) render(ports []uint16) ([]byte, error) {\n\n\t// prepare the context\n\td := make([]templateContext, len(ports))\n\tfor i, port := range ports {\n\t\tif i == len(h.serviceAddrs) {\n\t\t\th.logger.Warnf(\"got port index %d, but only have %d service addrs. ports=%v serviceAddrs=%v\", i, len(h.serviceAddrs), ports, h.serviceAddrs)\n\t\t\tcontinue\n\t\t}\n\t\td[i] = templateContext{Port: port, Source: h.listenAddr, Dest: h.serviceAddrs[i]}\n\t}\n\n\t// render the template\n\tbuf := &bytes.Buffer{}\n\tif err := h.template.Execute(buf, d); err != nil {\n\t\treturn nil, err\n\t}\n\treturn buf.Bytes(), nil\n}", "func (e *tag) fastRender(w io.Writer, tag string, children []Element) (int, error) {\n\tif len(e.childData) == 0 {\n\t\t// Record the rendering into child data.\n\t\tbuf := new(bytes.Buffer)\n\t\t_, err := e.renderElement(buf, tag, children)\n\t\tif err != nil {\n\t\t\treturn 0, err\n\t\t}\n\t\te.childData = buf.Bytes()\n\t}\n\tn, err := w.Write(e.childData)\n\treturn n, err\n}", "func Render(i Image, nMax uint, fn Fractaler) Fractal {\n nCPU := runtime.GOMAXPROCS(0)\n\txStep, yStep := i.Scale()\n\tf := NewFractal(i.W, i.H)\n\n\t// points are fed through in to be computed then to d to be written to memory\n\tprein := make(chan point, nCPU)\n\tin := make(chan point, nCPU)\n\td := make(chan point, nCPU)\n\tpcount, icount, count := 0, 0, 0 // used to coordinate the closing of d\n\n\t// create the raw points\n\tgo func() {\n\t\tfor x := uint(0); x < i.W; x = x + 1 {\n\t\t\tgo func(x uint) {\n\t\t\t\tfor y := uint(0); y < i.H; y = y + 1 {\n\t\t\t\t\tprein <- point{x: x, y: y}\n\t\t\t\t}\n\t\t\t\tif pcount+1 == int(i.W) {\n\t\t\t\t\tclose(prein)\n\t\t\t\t}\n\t\t\t\tpcount = pcount + 1\n\t\t\t}(x)\n\t\t}\n\t}()\n\n\t//Create the complex numbers\n\tfor j := 0; j < nCPU; j = j + 1 {\n\t\tgo func() {\n\t\t\tfor p := range prein {\n\t\t\t\tp.c = i.P1 - complex(float64(p.x)*xStep, float64(p.y)*yStep)\n\t\t\t\tin <- p\n\t\t\t}\n\t\t\tif icount+1 == nCPU {\n\t\t\t\tclose(in)\n\t\t\t}\n\t\t\ticount = icount + 1\n\t\t}()\n\t}\n\n\t// Start the worker functions who perform the calculations\n\tfor i := 0; i < nCPU; i = i + 1 {\n\t\tgo func() {\n\t\t\tfor p := range in {\n\t\t\t\tz := complex128(0)\n\t\t\t\tfor p.n = 1; p.n < nMax && fn.CheckBounds(z); p.n = p.n + 1 {\n\t\t\t\t\tz = fn.Iterate(z, p.c)\n\t\t\t\t}\n\t\t\t\td <- p\n\t\t\t}\n\t\t\tif count+1 == nCPU {\n\t\t\t\tclose(d)\n\t\t\t}\n\t\t\tcount = count + 1\n\t\t}()\n\t}\n\n\t// Enter the data into the array as it comes out\n\tfor p := range d {\n\t\tf.Data[p.x][p.y] = p.n\n\t}\n\n\treturn f\n}", "func (t *textRender) Render(w io.Writer) (err error) {\n\tif len(t.Values) > 0 {\n\t\t_, err = fmt.Fprintf(w, t.Format, t.Values...)\n\t} else {\n\t\t_, err = io.WriteString(w, t.Format)\n\t}\n\treturn\n}", "func mapCount(itr Iterator, m *mapper) {\n\tn := 0\n\tfor k, _ := itr.Next(); k != 0; k, _ = itr.Next() {\n\t\tn++\n\t}\n\tm.emit(itr.Time(), float64(n))\n}", "func GenderSpout(tuple []interface{}, result *[]interface{}, variables *[]interface{}) error {\n\t// Variables\n\tvar counterMap map[string]interface{}\n\tvar idArray interface{}\n\tvar genderArray interface{}\n\n\tif (len(*variables) == 0) {\n\t\tcounterMap = make(map[string]interface{})\n\t\t*variables = append(*variables, counterMap)\n\t\tcounterMap[\"counter\"] = float64(0)\n\n\t\tfile, _ := os.Open(\"data.json\")\n\t\tdefer file.Close()\n\n\t\tb, _ := ioutil.ReadAll(file)\n\t\tvar object interface{}\n\t\tjson.Unmarshal(b, &object)\n\t\tobjectMap := object.(map[string]interface{})\n\t\tidArray = objectMap[\"id\"].([]interface{})\n\t\tgenderArray = objectMap[\"gender\"].([]interface{})\n\n\t\t*variables = append(*variables, idArray)\n\t\t*variables = append(*variables, genderArray)\n\t}\n\tcounterMap = (*variables)[0].(map[string]interface{})\n\tidArray = (*variables)[1]\n\tgenderArray = (*variables)[2]\n\n\t// Logic\n\tif counterMap[\"counter\"].(float64) < 1000 {\n\t\t*result = []interface{}{idArray.([]interface{})[int(counterMap[\"counter\"].(float64))], genderArray.([]interface{})[int(counterMap[\"counter\"].(float64))]}\n\t\tcounterMap[\"counter\"] = counterMap[\"counter\"].(float64) + 1\n\t}\n\n\t// // Logic\n\t// if counterMap[\"counter\"].(float64) < 10 {\n\t// \tif int(counterMap[\"counter\"].(float64)) % 2 == 0 {\n\t// \t\t*result = []interface{}{strconv.Itoa(int(counterMap[\"counter\"].(float64))), \"male\"}\n\t// \t} else {\n\t// \t\t*result = []interface{}{strconv.Itoa(int(counterMap[\"counter\"].(float64))), \"female\"}\n\t// \t}\n\t// \tcounterMap[\"counter\"] = counterMap[\"counter\"].(float64) + 1\n\t// }\n\n\ttime.Sleep(1 * time.Millisecond)\n\n\t// Return value\n\tif (len(*result) > 0) {\n\t\tlog.Printf(\"Gender Spout Emit (%v)\\n\", *result)\n\t\treturn nil\n\t} else {\n\t\treturn errors.New(\"next tuple is nil\")\n\t}\n}", "func (l LogItems) Render(showTime bool, ll [][]byte) {\n\tcolors := make(map[string]int, len(l))\n\tfor i, item := range l {\n\t\tinfo := item.ID()\n\t\tcolor, ok := colors[info]\n\t\tif !ok {\n\t\t\tcolor = colorFor(info)\n\t\t\tcolors[info] = color\n\t\t}\n\t\tll[i] = item.Render(color, showTime)\n\t}\n}", "func DrawElements(mode Enum, count int, ty Enum, offset int) {\n\tgl.DrawElements(uint32(mode), int32(count), uint32(ty), gl.PtrOffset(offset))\n}", "func DrawN(count int, opts ...options) (result []string, err error) {\n\tif count <= 0 {\n\t\tcount = 1\n\t}\n\n\tfor i := 0; i < count; i++ {\n\t\toutput, err := Draw(opts...)\n\t\tif err != nil {\n\t\t\treturn nil, err\n\t\t}\n\t\tresult = append(result, output)\n\t}\n\n\treturn\n}", "func (o *FactoryContainer) CountOutput() float64 {\n\tvar output float64 = 0.0\n\tfor i, _ := range o.Factories {\n\t\toutput = output + o.Factories[i].Production*o.Factories[i].ProductionModifier\n\t}\n\treturn output\n}", "func Render(w http.ResponseWriter, actions ...*Action) error {\n\tbuf := new(bytes.Buffer)\n\tfor _, a := range actions {\n\t\tif err := a.appendTo(buf); err != nil {\n\t\t\treturn err\n\t\t}\n\t\tif a != nil {\n\t\t\tbuf.WriteByte('\\n')\n\t\t}\n\t}\n\tw.Header().Set(\"Content-Type\", ContentType+\"; charset=utf-8\")\n\tw.Header().Set(\"Content-Length\", strconv.Itoa(buf.Len()))\n\tio.Copy(w, buf) // ignore errors, since we already wrote\n\treturn nil\n}", "func (vhs *VHS) Render() error {\n\t// Apply Loop Offset by modifying frame sequence\n\tif err := vhs.ApplyLoopOffset(); err != nil {\n\t\treturn err\n\t}\n\n\t// Generate the video(s) with the frames.\n\tvar cmds []*exec.Cmd\n\tcmds = append(cmds, MakeGIF(vhs.Options.Video))\n\tcmds = append(cmds, MakeMP4(vhs.Options.Video))\n\tcmds = append(cmds, MakeWebM(vhs.Options.Video))\n\tcmds = append(cmds, MakeScreenshots(vhs.Options.Screenshot)...)\n\n\tfor _, cmd := range cmds {\n\t\tif cmd == nil {\n\t\t\tcontinue\n\t\t}\n\t\tout, err := cmd.CombinedOutput()\n\t\tif err != nil {\n\t\t\tlog.Println(string(out))\n\t\t}\n\t}\n\n\treturn nil\n}", "func (g *Keyboard) Stream(samples []float64) {\n\tg.l.Lock()\n\tdefer g.l.Unlock()\n\n\tfor i := range samples {\n\t\tt := float64(g.totalSamples) / float64(g.sr)\n\t\tv := float64(0)\n\n\t\tfor _, w := range g.waves {\n\t\t\twaveV, _ := w(t)\n\t\t\tv += waveV\n\t\t}\n\t\tsamples[i] = v\n\t\tg.totalSamples++\n\t}\n\n\tt := float64(g.totalSamples) / float64(g.sr)\n\tnewWaves := []FiniteWaveFn{}\n\tfor _, w := range g.waves {\n\t\tif _, done := w(t); !done {\n\t\t\tnewWaves = append(newWaves, w)\n\t\t}\n\t}\n\tg.waves = newWaves\n}", "func (s *Spinner) Render() error {\n\tif len(s.frames) == 0 {\n\t\treturn errors.New(\"no frames available to to render\")\n\t}\n\n\ts.step = s.step % len(s.frames)\n\tpreviousLen := len(s.previousFrame)\n\ts.previousFrame = fmt.Sprintf(\"%s%s\", s.separator, s.frames[s.step])\n\tnewLen := len(s.previousFrame)\n\n\t// We need to clean the previous message\n\tif previousLen > newLen {\n\t\tr := previousLen - newLen\n\t\tsuffix := strings.Repeat(\" \", r)\n\t\ts.previousFrame = s.previousFrame + suffix\n\t}\n\n\tfmt.Fprint(s.Writer, s.previousFrame)\n\ts.step++\n\treturn nil\n}", "func (l *CaptureResponseList) Render(w http.ResponseWriter, r *http.Request) error {\n\tl.Captures = make([]CaptureResponse, len(l.cs))\n\tfor i := 0; i < len(l.cs); i++ {\n\t\tl.Captures[i] = *NewCaptureResponse(&l.cs[i])\n\t\tif err := l.Captures[i].Render(nil, nil); err != nil {\n\t\t\treturn perr.NewErrInternal(errors.Wrap(err, \"could not bind PropertyResponse\"))\n\t\t}\n\t}\n\n\treturn nil\n}", "func (r *Renderer) Render() {\n\tgl.DrawArrays(gl.TRIANGLES, 0, int32(len(r.RawRenderer)*4))\n}", "func NumberLamp(vs []val.Val) {\n\tfunc(vs []val.Val) {\n\t\tdraw := func(color, str string) {\n\t\t\tfmt.Print(colorstring.Color(\"[_\" + color + \"_]\" + str + \"[default]\"))\n\t\t}\n\t\tfor {\n\t\t\toff := \"black\"\n\t\t\ton := \"blue\"\n\t\t\tons := make([]string, 7)\n\t\t\tfor i := 0; i < 7; i++ {\n\t\t\t\tout := vs[i].Out()\n\t\t\t\tif out.IsNil() {\n\t\t\t\t\treturn\n\t\t\t\t}\n\t\t\t\tif out.Bool() {\n\t\t\t\t\tons[i] = on\n\t\t\t\t} else {\n\t\t\t\t\tons[i] = off\n\t\t\t\t}\n\t\t\t}\n\t\t\t//\t0\n\t\t\tdraw(off, \" \")\n\t\t\tdraw(ons[0], \" \")\n\t\t\tdraw(off, \" \")\n\t\t\tdraw(off, \"\\n\")\n\t\t\t//\t5 1\n\t\t\tdraw(ons[5], \" \")\n\t\t\tdraw(off, \" \")\n\t\t\tdraw(ons[1], \" \")\n\t\t\tdraw(off, \"\\n\")\n\t\t\tdraw(ons[5], \" \")\n\t\t\tdraw(off, \" \")\n\t\t\tdraw(ons[1], \" \")\n\t\t\tdraw(off, \"\\n\")\n\t\t\t//\t6\n\t\t\tdraw(off, \" \")\n\t\t\tdraw(ons[6], \" \")\n\t\t\tdraw(off, \" \")\n\t\t\tdraw(off, \"\\n\")\n\t\t\t//\t4 2\n\t\t\tdraw(ons[4], \" \")\n\t\t\tdraw(off, \" \")\n\t\t\tdraw(ons[2], \" \")\n\t\t\tdraw(off, \"\\n\")\n\t\t\tdraw(ons[4], \" \")\n\t\t\tdraw(off, \" \")\n\t\t\tdraw(ons[2], \" \")\n\t\t\tdraw(off, \"\\n\")\n\t\t\t//\t3\n\t\t\tdraw(off, \" \")\n\t\t\tdraw(ons[3], \" \")\n\t\t\tdraw(off, \" \")\n\t\t\tdraw(off, \"\\n\")\n\t\t\t//\tnew line\n\t\t\tdraw(off, \"\\n\")\n\t\t}\n\t}(vs)\n}", "func WriteCount(buffer []byte, offset int, value byte, valueCount int) {\n for i := 0; i < valueCount; i++ {\n buffer[offset + i] = value\n }\n}", "func CountPrintln(f ...interface{}) {\n\tcount++\n\tfmt.Printf(\"%d - \", count)\n\tfmt.Println(f...)\n}", "func (ctx *RecordContext) Render(v interface{}) error {\n\tctx.Renders = append(ctx.Renders, v)\n\treturn ctx.Context.Render(v)\n}", "func (b *renderSystem) Render(dt float64) {\n\n\tb.renderer.Clear()\n\n\tfor i := 0; i < 100; i++ {\n\t\tl := b.layers[i]\n\t\tif l != nil {\n\t\t\tfor _, renderable := range *l {\n\t\t\t\trenderable.Paint(b.renderer)\n\t\t\t}\n\t\t}\n\t}\n\n\tb.renderer.Present()\n}", "func MultiDrawElements(mode uint32, count *int32, xtype uint32, indices *unsafe.Pointer, drawcount int32) {\n\tsyscall.Syscall6(gpMultiDrawElements, 5, uintptr(mode), uintptr(unsafe.Pointer(count)), uintptr(xtype), uintptr(unsafe.Pointer(indices)), uintptr(drawcount), 0)\n}", "func main() {\n\tctx := pipeliner.FirstError()\n\tsourceCh := source(ctx, 0, 9000)\n\tbatches := batchInts(ctx, 320, sourceCh)\n\tfor batch := range batches {\n\t\tfmt.Printf(\"received batch of length: %d\\n\", len(batch))\n\t}\n}", "func (l *LogItems) Render(showTime bool, ll [][]byte) {\n\tindex := len(l.colors)\n\tfor i, item := range l.items {\n\t\tid := item.ID()\n\t\tcolor, ok := l.colors[id]\n\t\tif !ok {\n\t\t\tif index >= len(colorPalette) {\n\t\t\t\tindex = 0\n\t\t\t}\n\t\t\tcolor = colorPalette[index]\n\t\t\tl.colors[id] = color\n\t\t\tindex++\n\t\t}\n\t\tll[i] = item.Render(int(color-tcell.ColorValid), showTime)\n\t}\n}", "func parseObjectStream(osd *types.ObjectStreamDict) error {\n\n\tlog.Read.Printf(\"parseObjectStream begin: decoding %d objects.\\n\", osd.ObjCount)\n\n\tdecodedContent := osd.Content\n\tprolog := decodedContent[:osd.FirstObjOffset]\n\n\t// The separator used in the prolog shall be white space\n\t// but some PDF writers use 0x00.\n\tprolog = bytes.ReplaceAll(prolog, []byte{0x00}, []byte{0x20})\n\n\tobjs := strings.Fields(string(prolog))\n\tif len(objs)%2 > 0 {\n\t\treturn errors.New(\"pdfcpu: parseObjectStream: corrupt object stream dict\")\n\t}\n\n\t// e.g., 10 0 11 25 = 2 Objects: #10 @ offset 0, #11 @ offset 25\n\n\tvar objArray types.Array\n\n\tvar offsetOld int\n\n\tfor i := 0; i < len(objs); i += 2 {\n\n\t\toffset, err := strconv.Atoi(objs[i+1])\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\n\t\toffset += osd.FirstObjOffset\n\n\t\tif i > 0 {\n\t\t\tdstr := string(decodedContent[offsetOld:offset])\n\t\t\tlog.Read.Printf(\"parseObjectStream: objString = %s\\n\", dstr)\n\t\t\to, err := compressedObject(dstr)\n\t\t\tif err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\n\t\t\tlog.Read.Printf(\"parseObjectStream: [%d] = obj %s:\\n%s\\n\", i/2-1, objs[i-2], o)\n\t\t\tobjArray = append(objArray, o)\n\t\t}\n\n\t\tif i == len(objs)-2 {\n\t\t\tdstr := string(decodedContent[offset:])\n\t\t\tlog.Read.Printf(\"parseObjectStream: objString = %s\\n\", dstr)\n\t\t\to, err := compressedObject(dstr)\n\t\t\tif err != nil {\n\t\t\t\treturn err\n\t\t\t}\n\n\t\t\tlog.Read.Printf(\"parseObjectStream: [%d] = obj %s:\\n%s\\n\", i/2, objs[i], o)\n\t\t\tobjArray = append(objArray, o)\n\t\t}\n\n\t\toffsetOld = offset\n\t}\n\n\tosd.ObjArray = objArray\n\n\tlog.Read.Println(\"parseObjectStream end\")\n\n\treturn nil\n}", "func (tofu Tofu) Render(wr io.Writer, name string, obj interface{}) error {\n\tvar m data.Map\n\tif obj != nil {\n\t\tvar ok bool\n\t\tm, ok = data.New(obj).(data.Map)\n\t\tif !ok {\n\t\t\treturn fmt.Errorf(\"invalid data type. expected map/struct, got %T\", obj)\n\t\t}\n\t}\n\treturn tofu.NewRenderer(name).Execute(wr, m)\n}", "func (s *Layer) Render(ctx *RenderContext) {\n\tfor _, e := range s.entities {\n\t\te.Render(ctx)\n\t}\n}", "func main() {\n\tfloor := surface.UnitCube().Move(0, -1, 0).Scale(100, 1, 100)\n\thalogen := material.Light(10000000, 10000000, 10000000)\n\tlight := surface.UnitSphere(halogen).Move(-50, 100, -10)\n\tbox := surface.UnitSphere(material.Gold)\n\tscene := pbr.NewScene(floor, light, box)\n\tcam := pbr.NewCamera(888, 500).MoveTo(-3, 2, 5).LookAt(box.Center(), box.Center())\n\trender := pbr.NewRender(scene, cam)\n\tinterrupt := make(chan os.Signal, 2)\n\n\trender.SetDirect(1)\n\n\tfmt.Println(\"rendering hello.png (press Ctrl+C to finish)...\")\n\tsignal.Notify(interrupt, os.Interrupt, syscall.SIGTERM)\n\trender.Start()\n\t<-interrupt\n\trender.Stop()\n\trender.WritePngs(\"hello.png\", \"hello-heat.png\", \"hello-noise.png\", 1)\n}", "func CountFrom(start, step int) Stream {\n return &count{start, step}\n}", "func (c *Canvas) Count() int {\n\treturn len(c.paint)\n}", "func renderInteger(f float64) string {\n\tif f > math.Nextafter(float64(math.MaxInt64), 0) {\n\t\treturn fmt.Sprintf(\"%d\", int64(math.MaxInt64))\n\t}\n\tif f < math.Nextafter(float64(math.MinInt64), 0) {\n\t\treturn fmt.Sprintf(\"%d\", int64(math.MinInt64))\n\t}\n\treturn fmt.Sprintf(\"%d\", int64(f))\n}", "func (v *StackPanel) Render(rn Renderer) {\n\toff := 0\n\tfor _, child := range v.childs {\n\t\tif v.orientation == Vertical {\n\t\t\tif off >= v.height {\n\t\t\t\tbreak\n\t\t\t}\n\t\t\theight := v.heights[child]\n\t\t\trn.RenderChild(child, v.width, height, 0, off)\n\t\t\toff += height\n\t\t} else {\n\t\t\tif off >= v.width {\n\t\t\t\tbreak\n\t\t\t}\n\t\t\twidth := v.widths[child]\n\t\t\trn.RenderChild(child, width, v.height, off, 0)\n\t\t\toff += width\n\t\t}\n\t}\n}", "func (gm *GraphicsManager) Render(compsToSend *common.Vector) {\n\thandlerIndex := 0\n\tdefer gm.handleClosedGraphicsHandler(handlerIndex)\n\n\t//common.LogInfo.Println(compsToSend)\n\tfor handlerIndex = range gm.graphicsHandlersLink {\n\t\tif gm.graphicsHandlersLink[handlerIndex] == nil {\n\t\t\tcontinue\n\t\t}\n\t\tgm.graphicsHandlersLink[handlerIndex] <- compsToSend\n\t}\n}", "func writeSubscriptionMetrics(object *SubscriptionMetrics, stream *jsoniter.Stream) {\n\tcount := 0\n\tstream.WriteObjectStart()\n\tvar present_ bool\n\tpresent_ = object.bitmap_&1 != 0\n\tif present_ {\n\t\tif count > 0 {\n\t\t\tstream.WriteMore()\n\t\t}\n\t\tstream.WriteObjectField(\"cloud_provider\")\n\t\tstream.WriteString(object.cloudProvider)\n\t\tcount++\n\t}\n\tpresent_ = object.bitmap_&2 != 0 && object.computeNodesCpu != nil\n\tif present_ {\n\t\tif count > 0 {\n\t\t\tstream.WriteMore()\n\t\t}\n\t\tstream.WriteObjectField(\"compute_nodes_cpu\")\n\t\twriteClusterResource(object.computeNodesCpu, stream)\n\t\tcount++\n\t}\n\tpresent_ = object.bitmap_&4 != 0 && object.computeNodesMemory != nil\n\tif present_ {\n\t\tif count > 0 {\n\t\t\tstream.WriteMore()\n\t\t}\n\t\tstream.WriteObjectField(\"compute_nodes_memory\")\n\t\twriteClusterResource(object.computeNodesMemory, stream)\n\t\tcount++\n\t}\n\tpresent_ = object.bitmap_&8 != 0 && object.computeNodesSockets != nil\n\tif present_ {\n\t\tif count > 0 {\n\t\t\tstream.WriteMore()\n\t\t}\n\t\tstream.WriteObjectField(\"compute_nodes_sockets\")\n\t\twriteClusterResource(object.computeNodesSockets, stream)\n\t\tcount++\n\t}\n\tpresent_ = object.bitmap_&16 != 0\n\tif present_ {\n\t\tif count > 0 {\n\t\t\tstream.WriteMore()\n\t\t}\n\t\tstream.WriteObjectField(\"console_url\")\n\t\tstream.WriteString(object.consoleUrl)\n\t\tcount++\n\t}\n\tpresent_ = object.bitmap_&32 != 0 && object.cpu != nil\n\tif present_ {\n\t\tif count > 0 {\n\t\t\tstream.WriteMore()\n\t\t}\n\t\tstream.WriteObjectField(\"cpu\")\n\t\twriteClusterResource(object.cpu, stream)\n\t\tcount++\n\t}\n\tpresent_ = object.bitmap_&64 != 0\n\tif present_ {\n\t\tif count > 0 {\n\t\t\tstream.WriteMore()\n\t\t}\n\t\tstream.WriteObjectField(\"critical_alerts_firing\")\n\t\tstream.WriteFloat64(object.criticalAlertsFiring)\n\t\tcount++\n\t}\n\tpresent_ = object.bitmap_&128 != 0\n\tif present_ {\n\t\tif count > 0 {\n\t\t\tstream.WriteMore()\n\t\t}\n\t\tstream.WriteObjectField(\"health_state\")\n\t\tstream.WriteString(object.healthState)\n\t\tcount++\n\t}\n\tpresent_ = object.bitmap_&256 != 0 && object.memory != nil\n\tif present_ {\n\t\tif count > 0 {\n\t\t\tstream.WriteMore()\n\t\t}\n\t\tstream.WriteObjectField(\"memory\")\n\t\twriteClusterResource(object.memory, stream)\n\t\tcount++\n\t}\n\tpresent_ = object.bitmap_&512 != 0 && object.nodes != nil\n\tif present_ {\n\t\tif count > 0 {\n\t\t\tstream.WriteMore()\n\t\t}\n\t\tstream.WriteObjectField(\"nodes\")\n\t\twriteClusterMetricsNodes(object.nodes, stream)\n\t\tcount++\n\t}\n\tpresent_ = object.bitmap_&1024 != 0\n\tif present_ {\n\t\tif count > 0 {\n\t\t\tstream.WriteMore()\n\t\t}\n\t\tstream.WriteObjectField(\"openshift_version\")\n\t\tstream.WriteString(object.openshiftVersion)\n\t\tcount++\n\t}\n\tpresent_ = object.bitmap_&2048 != 0\n\tif present_ {\n\t\tif count > 0 {\n\t\t\tstream.WriteMore()\n\t\t}\n\t\tstream.WriteObjectField(\"operating_system\")\n\t\tstream.WriteString(object.operatingSystem)\n\t\tcount++\n\t}\n\tpresent_ = object.bitmap_&4096 != 0\n\tif present_ {\n\t\tif count > 0 {\n\t\t\tstream.WriteMore()\n\t\t}\n\t\tstream.WriteObjectField(\"operators_condition_failing\")\n\t\tstream.WriteFloat64(object.operatorsConditionFailing)\n\t\tcount++\n\t}\n\tpresent_ = object.bitmap_&8192 != 0\n\tif present_ {\n\t\tif count > 0 {\n\t\t\tstream.WriteMore()\n\t\t}\n\t\tstream.WriteObjectField(\"region\")\n\t\tstream.WriteString(object.region)\n\t\tcount++\n\t}\n\tpresent_ = object.bitmap_&16384 != 0 && object.sockets != nil\n\tif present_ {\n\t\tif count > 0 {\n\t\t\tstream.WriteMore()\n\t\t}\n\t\tstream.WriteObjectField(\"sockets\")\n\t\twriteClusterResource(object.sockets, stream)\n\t\tcount++\n\t}\n\tpresent_ = object.bitmap_&32768 != 0\n\tif present_ {\n\t\tif count > 0 {\n\t\t\tstream.WriteMore()\n\t\t}\n\t\tstream.WriteObjectField(\"state\")\n\t\tstream.WriteString(object.state)\n\t\tcount++\n\t}\n\tpresent_ = object.bitmap_&65536 != 0\n\tif present_ {\n\t\tif count > 0 {\n\t\t\tstream.WriteMore()\n\t\t}\n\t\tstream.WriteObjectField(\"state_description\")\n\t\tstream.WriteString(object.stateDescription)\n\t\tcount++\n\t}\n\tpresent_ = object.bitmap_&131072 != 0 && object.storage != nil\n\tif present_ {\n\t\tif count > 0 {\n\t\t\tstream.WriteMore()\n\t\t}\n\t\tstream.WriteObjectField(\"storage\")\n\t\twriteClusterResource(object.storage, stream)\n\t\tcount++\n\t}\n\tpresent_ = object.bitmap_&262144 != 0\n\tif present_ {\n\t\tif count > 0 {\n\t\t\tstream.WriteMore()\n\t\t}\n\t\tstream.WriteObjectField(\"subscription_cpu_total\")\n\t\tstream.WriteFloat64(object.subscriptionCpuTotal)\n\t\tcount++\n\t}\n\tpresent_ = object.bitmap_&524288 != 0\n\tif present_ {\n\t\tif count > 0 {\n\t\t\tstream.WriteMore()\n\t\t}\n\t\tstream.WriteObjectField(\"subscription_obligation_exists\")\n\t\tstream.WriteFloat64(object.subscriptionObligationExists)\n\t\tcount++\n\t}\n\tpresent_ = object.bitmap_&1048576 != 0\n\tif present_ {\n\t\tif count > 0 {\n\t\t\tstream.WriteMore()\n\t\t}\n\t\tstream.WriteObjectField(\"subscription_socket_total\")\n\t\tstream.WriteFloat64(object.subscriptionSocketTotal)\n\t\tcount++\n\t}\n\tpresent_ = object.bitmap_&2097152 != 0 && object.upgrade != nil\n\tif present_ {\n\t\tif count > 0 {\n\t\t\tstream.WriteMore()\n\t\t}\n\t\tstream.WriteObjectField(\"upgrade\")\n\t\twriteClusterUpgrade(object.upgrade, stream)\n\t\tcount++\n\t}\n\tstream.WriteObjectEnd()\n}", "func _EvtRender(\n\tcontext EvtHandle,\n\tfragment EvtHandle,\n\tflags EvtRenderFlag,\n\tbufferSize uint32,\n\tbuffer *byte,\n\tbufferUsed *uint32,\n\tpropertyCount *uint32,\n) error {\n\tr1, _, e1 := syscall.SyscallN(\n\t\tprocEvtRender.Addr(),\n\t\tuintptr(context),\n\t\tuintptr(fragment),\n\t\tuintptr(flags),\n\t\tuintptr(bufferSize),\n\t\tuintptr(unsafe.Pointer(buffer)), //nolint:gosec // G103: Valid use of unsafe call to pass buffer\n\t\tuintptr(unsafe.Pointer(bufferUsed)), //nolint:gosec // G103: Valid use of unsafe call to pass bufferUsed\n\t\tuintptr(unsafe.Pointer(propertyCount)), //nolint:gosec // G103: Valid use of unsafe call to pass propertyCount\n\t)\n\n\tvar err error\n\tif r1 == 0 {\n\t\tif e1 != 0 {\n\t\t\terr = errnoErr(e1)\n\t\t} else {\n\t\t\terr = syscall.EINVAL\n\t\t}\n\t}\n\treturn err\n}", "func DrawElements(mode uint32, count int32, xtype uint32, indices unsafe.Pointer) {\n C.glowDrawElements(gpDrawElements, (C.GLenum)(mode), (C.GLsizei)(count), (C.GLenum)(xtype), indices)\n}", "func (self *GameObjectCreator) RenderTexture1O(width int) *RenderTexture{\n return &RenderTexture{self.Object.Call(\"renderTexture\", width)}\n}", "func (sh *ShaderStd) PostRender() error { return nil }", "func emitCount() int {\n\tlogn := math.Log(float64(knownNodes.length()))\n\tmult := (lambda * logn) + 0.5\n\n\treturn int(mult)\n}", "func BenchmarkStreamPipeline(b *testing.B) {\n\tb.ReportAllocs()\n\tnumbers := gen(1_000_000)\n\tfor i := 0; i < b.N; i++ {\n\t\tfor _, num := range numbers {\n\t\t\tsMultiply(sAdd(sMultiply(num, 2), 1), 2)\n\t\t}\n\t}\n}", "func TransformFeedbackVaryings(program uint32, count int32, varyings **uint8, bufferMode uint32) {\n\tC.glowTransformFeedbackVaryings(gpTransformFeedbackVaryings, (C.GLuint)(program), (C.GLsizei)(count), (**C.GLchar)(unsafe.Pointer(varyings)), (C.GLenum)(bufferMode))\n}", "func TransformFeedbackVaryings(program uint32, count int32, varyings **uint8, bufferMode uint32) {\n\tC.glowTransformFeedbackVaryings(gpTransformFeedbackVaryings, (C.GLuint)(program), (C.GLsizei)(count), (**C.GLchar)(unsafe.Pointer(varyings)), (C.GLenum)(bufferMode))\n}", "func (gm *GraphicsManager) RenderAll(sm component.SceneManager) (*common.Vector, *common.Vector) {\n\terrs := common.MakeVector()\n\tcompsToSend := common.MakeVector()\n\tcomps := gm.compList.Array()\n\n\tfor i := range comps {\n\t\tif comps[i] == nil {\n\t\t\tcontinue\n\t\t}\n\t\tcompsToSend.Insert(comps[i].(component.GOiD))\n\t}\n\n\treturn compsToSend, errs\n}", "func GenerateShapes() {\r\n\t// Square\r\n\tShapes[0].vertices = []gl.GLfloat{-1, -1, 1, -1, -1, 1, 1, 1}\r\n\tShapes[0].elements = []gl.GLushort{0, 1, 2, 2, 3, 1}\r\n\r\n\t// ___|\r\n\tShapes[1].vertices = []gl.GLfloat{-2, 0, -2, -1, 2, -1, 2, 0, 2, 1, 1, 1, 1, 0}\r\n\tShapes[1].elements = []gl.GLushort{0, 1, 2, 2, 3, 0, 3, 4, 5, 5, 6, 3}\r\n\r\n\t// _|_\r\n\tShapes[2].vertices = []gl.GLfloat{-1.5, 0, -0.5, 0, -0.5, 1, 0.5, 1, 0.5, 0, 1.5, 0, 1.5, -1, -1.5, -1}\r\n\tShapes[2].elements = []gl.GLushort{1, 2, 3, 3, 4, 1, 0, 7, 6, 6, 0, 5}\r\n\r\n\t// Snake\r\n\tShapes[3].vertices = []gl.GLfloat{-1.5, -1, -1.5, 0, -0.5, 0, -0.5, 1, 1.5, 1, 1.5, 0, 0.5, 0, 0.5, -1}\r\n\tShapes[3].elements = []gl.GLushort{0, 1, 6, 6, 7, 0, 2, 3, 4, 4, 5, 2}\r\n\r\n\t// Now fill out the rest automatically.\r\n\t// FIXME why doesn't using _, shape in this loop work ?\r\n\tfor i := range Shapes {\r\n\t\tShapes[i].vao = gl.GenVertexArray()\r\n\t\tShapes[i].vao.Bind()\r\n\t\tShapes[i].vbo = gl.GenBuffer()\r\n\t\tShapes[i].vbo.Bind(gl.ARRAY_BUFFER)\r\n\t\tgl.BufferData(gl.ARRAY_BUFFER, len(Shapes[i].vertices)*4, Shapes[i].vertices, gl.STATIC_DRAW)\r\n\t\tShapes[i].elementBuffer = gl.GenBuffer()\r\n\t\tShapes[i].elementBuffer.Bind(gl.ELEMENT_ARRAY_BUFFER)\r\n\t\tgl.BufferData(gl.ELEMENT_ARRAY_BUFFER, len(Shapes[i].elements)*2, Shapes[i].elements, gl.STATIC_DRAW)\r\n\t\tShapes[i].numElements = len(Shapes[i].elements)\r\n\r\n\t\tvertexAttribArray := shaderProgram.GetAttribLocation(\"position\")\r\n\t\tvertexAttribArray.AttribPointer(2, gl.FLOAT, false, 0, uintptr(0))\r\n\t\tvertexAttribArray.EnableArray()\r\n\t}\r\n}", "func WriteSummary(index_name string, fields []string) {\n\n // Setting font as needed\n pdf.SetFont(\"Helvetica\",\"\",10)\n\n // a slice of Summary{} that will hold Summary{} structure for each field\n response_struct := []Summary{}\n\n // Looping through each fields requestd\n for index := range fields {\n url := fmt.Sprintf(`https://127.0.0.1:9200/%s/_search?`, index_name)\n queries := fmt.Sprintf(`\n {\n \"size\":\"0\",\n \"aggs\" : {\n \"uniq_gender\" : {\n \"terms\" : { \"field\" : \"%s.keyword\" }\n }\n }\n }`, fields[index])\n\n p, err := es.Query(\"GET\", url, queries)\n if err != nil {\n fmt.Println(\"Report Generation error ERROR: Could not get response from Elasticsearch server \", err, \"Trying to connect again\")\n return\n }\n\n temp := Summary{}\n\n err = json.Unmarshal(p, &temp)\n if (err != nil) {\n fmt.Println(\"Error unmarshalling json\",err);\n }\n\n response_struct = append(response_struct,temp);\n }\n for i :=0; i < len(response_struct); i++ {\n pdf.Write(10,fmt.Sprintf(`%s Count\\n`,fields[i]))\n //DrawLine();\n for _, v := range(response_struct[i].Aggregations.Uniq.Buck){\n pdf.Write(10,fmt.Sprintf(`%s %d\\n`,v.Key,v.Count))\n }\n }\n}", "func (mm *massivemonster) render() {\n\n\trenderOutput(\"Massive Monster\", \"h1\", \"red\")\n\trenderOutput(mm.mmType, \"\", \"clear\")\n\trenderOutput(\"Class: \"+strconv.Itoa(mm.class), \"\", \"clear\")\n\trenderOutput(\"Motivation: \"+mm.motivation, \"\", \"clear\")\n\n\trenderOutput(\"Abilities\", \"h2\", \"clear\")\n\tif len(mm.abilities) > 0 {\n\t\tfor i := 0; i < len(mm.abilities); i++ {\n\t\t\trenderOutput(mm.abilities[i], \"listitem\", \"blue\")\n\t\t}\n\t}\n\n\trenderOutput(\"Natures\", \"h2\", \"clear\")\n\tif len(mm.natures) > 0 {\n\t\tfor i := 0; i < len(mm.natures); i++ {\n\t\t\trenderOutput(mm.natures[i], \"listitem\", \"green\")\n\t\t}\n\t}\n\trenderOutput(\"Weak Spot: \"+mm.weakSpot, \"\", \"yellow\")\n\trenderOutput(\"Incursion Zone Effect\", \"h2\", \"purple\")\n\trenderOutput(mm.zEffect, \"listitem\", \"clear\")\n\n}", "func (Parser) Render(rawBytes []byte, urlPrefix string, metas map[string]string, isWiki bool) []byte {\n\treturn Render(rawBytes, urlPrefix, metas, isWiki)\n}", "func makeRenderablePoly(name string, n int, drawType uint, color vec4) *Renderable {\n\t// build poly verts\n\tvertex := makePoly(n)\n\tr := &Renderable{\n\t\tworld.Transform(),\n\t\tworld.Operation(name, &world.Poly{Points: vertex}),\n\t\tworld.MaterialComponent{\n\t\t\tDrawType: drawType,\n\t\t\tProps: map[string]interface{}{\n\t\t\t\t\"color\": world.Color(color),\n\t\t\t},\n\t\t},\n\t}\n\n\treturn r\n}", "func (c *Context) Count(stat string, count float64) {\n\tfor _, sink := range c.sinks {\n\t\tsink.Count(c, stat, count)\n\t}\n}", "func (dev *E36xx) OutputCount() int {\n\treturn len(dev.Channels)\n}", "func (c *stackSetComponent) Render(out io.Writer) (int, error) {\n\tc.mu.Lock()\n\tdefer c.mu.Unlock()\n\n\tcomponents := cfnLineItemComponents(c.title, c.separator, c.statuses, c.stopWatch, c.style.Padding)\n\treturn renderComponents(out, components)\n}", "func (r renderer) List(out *bytes.Buffer, text func() bool, flags int) {\n\t// TODO: This is not desired (we'd rather not write lists as part of summary),\n\t// but see this issue: https://github.com/russross/blackfriday/issues/189\n\tmarker := out.Len()\n\tif !text() {\n\t\tout.Truncate(marker)\n\t}\n\tout.Write([]byte{' '})\n}", "func (vao *VAO) RenderInstanced(instancecount int32) {\n\tgl.BindVertexArray(vao.handle)\n\tif vao.indexBuffer != nil {\n\t\tgl.BindBuffer(gl.ELEMENT_ARRAY_BUFFER, vao.indexBuffer.GetHandle())\n\t\tgl.DrawElementsInstanced(vao.mode, vao.indexBuffer.Len(), gl.UNSIGNED_SHORT, nil, instancecount)\n\t\tgl.BindBuffer(gl.ELEMENT_ARRAY_BUFFER, 0)\n\t} else {\n\t\tgl.DrawArraysInstanced(vao.mode, 0, vao.vertexBuffers[0].Len(), instancecount)\n\t}\n\tgl.BindVertexArray(0)\n}", "func (w Widget) Buffer() []termui.Point {\n\tvar wrappedWidget uiWidget\n\n\twrapperHeight := w.Height - 3\n\tif w.Error() != nil && !w.shouldIgnoreError() {\n\t\ttextWidget := termui.NewPar(fmt.Sprintf(\"Error: %v\", w.Error().Error()))\n\t\ttextWidget.Height = wrapperHeight\n\t\ttextWidget.HasBorder = false\n\n\t\twrappedWidget = textWidget\n\t} else if !w.Ready {\n\t\ttextWidget := termui.NewPar(\"Loading entries, please wait...\")\n\t\ttextWidget.Height = wrapperHeight\n\t\ttextWidget.HasBorder = false\n\n\t\twrappedWidget = textWidget\n\t} else {\n\t\tlistWidget := termui.NewList()\n\t\tlistWidget.Height = wrapperHeight\n\t\tlistWidget.HasBorder = false\n\n\t\titems := make([]string, w.EntriesToDisplay())\n\n\t\t// addtional width: width that needs to be added so that they're\n\t\t// formatted properly.\n\t\taddWidth := int(math.Log10(float64(w.EntriesToDisplay()))) + 1\n\t\tfor i := 0; i < w.EntriesToDisplay() && i < len(w.EntryOrder); i++ {\n\t\t\tentryID := w.EntryOrder[i]\n\t\t\tentry, hasEntry := w.Entries[entryID]\n\n\t\t\tvar message string\n\t\t\tif hasEntry {\n\t\t\t\tmessage = entry.String()\n\t\t\t} else {\n\t\t\t\tmessage = \"Loading, please wait\"\n\t\t\t}\n\n\t\t\tdwidth := int(math.Log10(float64(i+1))) + 1\n\t\t\twidth := strconv.Itoa(addWidth - dwidth)\n\t\t\tf := strings.Replace(\"[%v]%{width}v %v...\", \"{width}\", width, 1)\n\t\t\titems[i] = fmt.Sprintf(f, i+1, \"\", message)\n\t\t}\n\n\t\tlistWidget.Items = items\n\t\twrappedWidget = listWidget\n\t}\n\n\twrappedWidget.SetWidth(w.Width - 4)\n\twrappedWidget.SetX(w.X + 2)\n\twrappedWidget.SetY(w.Y + 1)\n\n\tw.Border.Label = fmt.Sprintf(\"Hacker News (%v)\", w.Type.String())\n\tbuffer := append(w.Block.Buffer(), wrappedWidget.Buffer()...)\n\n\treturn buffer\n}", "func Render(w IWidget, size gowid.IRenderSize, focus gowid.Selector, app gowid.IApp) gowid.ICanvas {\n\tflow, isFlow := size.(gowid.IRenderFlowWith)\n\tif !isFlow {\n\t\tpanic(gowid.WidgetSizeError{Widget: w, Size: size, Required: \"gowid.IRenderFlowWith\"})\n\t}\n\tcols := flow.FlowColumns()\n\n\tdisplay := make([]rune, cols)\n\twi := w.Index()\n\tfor i := 0; i < cols; i++ {\n\t\tdisplay[i] = wave[wi]\n\t\twi += 1\n\t\tif wi == w.SpinnerLen() {\n\t\t\twi = 0\n\t\t}\n\t}\n\tbarCanvas :=\n\t\tstyled.New(\n\t\t\ttext.New(string(display)),\n\t\t\tw.Styler(),\n\t\t).Render(\n\n\t\t\tgowid.RenderBox{C: cols, R: 1}, gowid.NotSelected, app)\n\n\treturn barCanvas\n}", "func (f *Flash) Count() int {\n\treturn len(f.v)\n}", "func GenRenderbuffers(n int32, renderbuffers *uint32) {\n C.glowGenRenderbuffers(gpGenRenderbuffers, (C.GLsizei)(n), (*C.GLuint)(unsafe.Pointer(renderbuffers)))\n}", "func Stats(font *sfnt.Font) error {\n\tfor _, tag := range font.Tags() {\n\t\ttable, err := font.Table(tag)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\n\t\tfmt.Printf(\"%6d %q %s\\n\", len(table.Bytes()), tag, table.Name())\n\t}\n\treturn nil\n}", "func Transform(image io.Reader, extension string, numberOfShapes int, opts ...func() []string) (io.Reader, error) {\n\tvar args []string\n\n\tfor _, opt := range opts {\n\t\targs = append(args, opt()...)\n\t}\n\n\tinputTempFile, err := createTempFile(\"input_\", extension)\n\n\tif err != nil {\n\t\treturn nil, fmt.Errorf(\"primitive: failed to create temp input file:: %v\", err)\n\t}\n\n\toutputTempFile, err := createTempFile(\"output_\", extension)\n\n\tif err != nil {\n\t\treturn nil, fmt.Errorf(\"primitive: failed to create temp output file:: %v\", err)\n\t}\n\n\t// Read image\n\t_, err = io.Copy(inputTempFile, image)\n\n\tif err != nil {\n\t\treturn nil, fmt.Errorf(\"primitive: failed to copy temp input file:: %v\", err)\n\t}\n\n\t// Run primitive\n\tstdCombo, err := primitive(inputTempFile.Name(), outputTempFile.Name(), numberOfShapes, args...)\n\n\tif err != nil {\n\t\treturn nil, fmt.Errorf(\"primitive: failed to run the primitive command: %v, std combo: %s\", err, stdCombo)\n\t}\n\t// Read out into a reader, return reader and delete out\n\tb := bytes.NewBuffer(nil)\n\n\t_, err = io.Copy(b, outputTempFile)\n\n\tif err != nil {\n\t\treturn nil, fmt.Errorf(\"primitive: failed to copy temp output file:: %v\", err)\n\t}\n\n\treturn b, nil\n}", "func doTextProcessor(p proc.TextProcessor, label string, c *Chunk, msg string) *Chunk {\n\tres := p.Run(c.Data)\n\n\tfor _, match := range res.Matches {\n\t\tformattedMsg := fmt.Sprintf(msg)\n\t\tc.Matches = append(c.Matches, NewMatch(match.Match, label, match.Indices, formattedMsg))\n\t\tc.Score += 1\n\t}\n\n\treturn c\n}", "func (s Style) Render(raw string) string {\n\tt := NewAnstring(raw)\n\tfor i := len(s) - 1; i >= 0; i-- {\n\t\tt.meld(s[i])\n\t}\n\treturn string(t)\n}", "func (f *ParticleRenderFeature) Extract(v *gfx.View) {\n\tfor i, m := range f.et.comps[:f.et.index] {\n\t\tsid := gfx.PackSortId(m.zOrder, 0)\n\t\tv.RenderNodes = append(v.RenderNodes, gfx.SortObject{sid, uint32(i)})\n\t}\n}", "func (c *Collector) Transform(allStats *NodeStatsResponse) (metrics []*exportertools.Metric) {\n for _, stats := range allStats.Nodes {\n // GC Stats\n for _, gcstats := range stats.JVM.GC.Collectors {\n metrics = append(metrics, c.ConvertToMetric(\"jvm_gc_collection_seconds_count\",\n float64(gcstats.CollectionCount),\n \"COUNTER\",\n nil))\n\n metrics = append(metrics, c.ConvertToMetric(\"jvm_gc_collection_seconds_sum\",\n float64(gcstats.CollectionTime / 1000),\n \"COUNTER\",\n nil))\n }\n\n // Breaker stats\n for _, bstats := range stats.Breakers {\n metrics = append(metrics, c.ConvertToMetric(\"breakers_estimated_size_bytes\",\n float64(bstats.EstimatedSize),\n \"GAUGE\",\n nil))\n\n metrics = append(metrics, c.ConvertToMetric(\"breakers_limit_size_bytes\",\n float64(bstats.LimitSize),\n \"GAUGE\",\n nil))\n }\n\n // Thread Pool stats\n for pool, pstats := range stats.ThreadPool {\n metrics = append(metrics, c.ConvertToMetric(\"thread_pool_completed_count\",\n float64(pstats.Completed),\n \"COUNTER\",\n map[string]string{\"type\": pool}))\n\n metrics = append(metrics, c.ConvertToMetric(\"thread_pool_rejected_count\",\n float64(pstats.Rejected),\n \"COUNTER\",\n map[string]string{\"type\": pool}))\n\n metrics = append(metrics, c.ConvertToMetric(\"thread_pool_active_count\",\n float64(pstats.Active),\n \"GAUGE\",\n map[string]string{\"type\": pool}))\n\n metrics = append(metrics, c.ConvertToMetric(\"thread_pool_threads_count\",\n float64(pstats.Threads),\n \"GAUGE\",\n map[string]string{\"type\": pool}))\n\n metrics = append(metrics, c.ConvertToMetric(\"thread_pool_largest_count\",\n float64(pstats.Largest),\n \"GAUGE\",\n map[string]string{\"type\": pool}))\n\n metrics = append(metrics, c.ConvertToMetric(\"thread_pool_queue_count\",\n float64(pstats.Queue),\n \"GAUGE\",\n map[string]string{\"type\": pool}))\n }\n\n // JVM Memory Stats\n metrics = append(metrics, c.ConvertToMetric(\"jvm_memory_committed_bytes\",\n float64(stats.JVM.Mem.HeapCommitted),\n \"GAUGE\",\n nil))\n\n metrics = append(metrics, c.ConvertToMetric(\"jvm_memory_used_bytes\",\n float64(stats.JVM.Mem.HeapUsed),\n \"GAUGE\",\n nil))\n\n\n metrics = append(metrics, c.ConvertToMetric(\"jvm_memory_max_bytes\",\n float64(stats.JVM.Mem.HeapMax),\n \"GAUGE\",\n nil))\n\n metrics = append(metrics, c.ConvertToMetric(\"jvm_memory_committed_bytes\",\n float64(stats.JVM.Mem.NonHeapCommitted),\n \"GAUGE\",\n nil))\n\n metrics = append(metrics, c.ConvertToMetric(\"jvm_memory_used_bytes\",\n float64(stats.JVM.Mem.NonHeapUsed),\n \"GAUGE\",\n nil))\n\n // Indices Stats)\n metrics = append(metrics, c.ConvertToMetric(\"indices_fielddata_memory_size_bytes\",\n float64(stats.Indices.FieldData.MemorySize),\n \"GAUGE\",\n nil))\n\n metrics = append(metrics, c.ConvertToMetric(\"indices_fielddata_evictions\",\n float64(stats.Indices.FieldData.Evictions),\n \"COUNTER\",\n nil))\n\n metrics = append(metrics, c.ConvertToMetric(\"indices_filter_cache_memory_size_bytes\",\n float64(stats.Indices.FilterCache.MemorySize),\n \"GAUGE\",\n nil))\n\n metrics = append(metrics, c.ConvertToMetric(\"indices_filter_cache_evictions\",\n float64(stats.Indices.FilterCache.Evictions),\n \"COUNTER\",\n nil))\n\n metrics = append(metrics, c.ConvertToMetric(\"indices_query_cache_memory_size_bytes\",\n float64(stats.Indices.QueryCache.MemorySize),\n \"GAUGE\",\n nil))\n\n metrics = append(metrics, c.ConvertToMetric(\"indices_query_cache_evictions\",\n float64(stats.Indices.QueryCache.Evictions),\n \"COUNTER\",\n nil))\n\n metrics = append(metrics, c.ConvertToMetric(\"indices_request_cache_memory_size_bytes\",\n float64(stats.Indices.QueryCache.MemorySize),\n \"GAUGE\",\n nil))\n\n metrics = append(metrics, c.ConvertToMetric(\"indices_request_cache_evictions\",\n float64(stats.Indices.QueryCache.Evictions),\n \"COUNTER\",\n nil))\n\n metrics = append(metrics, c.ConvertToMetric(\"indices_docs\",\n float64(stats.Indices.Docs.Count),\n \"GAUGE\",\n nil))\n\n metrics = append(metrics, c.ConvertToMetric(\"indices_docs_deleted\",\n float64(stats.Indices.Docs.Deleted),\n \"GAUGE\",\n nil))\n\n metrics = append(metrics, c.ConvertToMetric(\"indices_segments_memory_bytes\",\n float64(stats.Indices.Segments.Memory),\n \"GAUGE\",\n nil))\n\n metrics = append(metrics, c.ConvertToMetric(\"indices_segments_count\",\n float64(stats.Indices.Segments.Count),\n \"GAUGE\",\n nil))\n\n metrics = append(metrics, c.ConvertToMetric(\"indices_store_size_bytes\",\n float64(stats.Indices.Store.Size),\n \"GAUGE\",\n nil))\n\n metrics = append(metrics, c.ConvertToMetric(\"indices_store_throttle_time_ms_total\",\n float64(stats.Indices.Store.ThrottleTime),\n \"COUNTER\",\n nil))\n\n metrics = append(metrics, c.ConvertToMetric(\"indices_flush_total\",\n float64(stats.Indices.Flush.Total),\n \"COUNTER\",\n nil))\n\n metrics = append(metrics, c.ConvertToMetric(\"indices_flush_time_ms_total\",\n float64(stats.Indices.Flush.Time),\n \"COUNTER\",\n nil))\n\n metrics = append(metrics, c.ConvertToMetric(\"indices_indexing_index_time_ms_total\",\n float64(stats.Indices.Indexing.IndexTime),\n \"COUNTER\",\n nil))\n\n metrics = append(metrics, c.ConvertToMetric(\"indices_indexing_index_total\",\n float64(stats.Indices.Indexing.IndexTotal),\n \"COUNTER\",\n nil))\n\n metrics = append(metrics, c.ConvertToMetric(\"indices_merges_total_time_ms_total\",\n float64(stats.Indices.Merges.TotalTime),\n \"COUNTER\",\n nil))\n\n metrics = append(metrics, c.ConvertToMetric(\"indices_merges_total_size_bytes_total\",\n float64(stats.Indices.Merges.TotalSize),\n \"COUNTER\",\n nil))\n\n metrics = append(metrics, c.ConvertToMetric(\"indices_merges_total\",\n float64(stats.Indices.Merges.Total),\n \"COUNTER\",\n nil))\n\n metrics = append(metrics, c.ConvertToMetric(\"indices_refresh_total_time_ms_total\",\n float64(stats.Indices.Refresh.TotalTime),\n \"COUNTER\",\n nil))\n\n metrics = append(metrics, c.ConvertToMetric(\"indices_refresh_total\",\n float64(stats.Indices.Refresh.Total),\n \"COUNTER\",\n nil))\n\n // Transport Stats)\n metrics = append(metrics, c.ConvertToMetric(\"transport_rx_packets_total\",\n float64(stats.Transport.RxCount),\n \"COUNTER\",\n nil))\n\n metrics = append(metrics, c.ConvertToMetric(\"transport_rx_size_bytes_total\",\n float64(stats.Transport.RxSize),\n \"COUNTER\",\n nil))\n\n\n metrics = append(metrics, c.ConvertToMetric(\"transport_tx_packets_total\",\n float64(stats.Transport.TxCount),\n \"COUNTER\",\n nil))\n\n metrics = append(metrics, c.ConvertToMetric(\"transport_tx_size_bytes_total\",\n float64(stats.Transport.TxSize),\n \"COUNTER\",\n nil))\n\n // Process Stats)\n metrics = append(metrics, c.ConvertToMetric(\"process_cpu_percent\",\n float64(stats.Process.CPU.Percent),\n \"GAUGE\",\n nil))\n\n metrics = append(metrics, c.ConvertToMetric(\"process_mem_resident_size_bytes\",\n float64(stats.Process.Memory.Resident),\n \"GAUGE\",\n nil))\n\n metrics = append(metrics, c.ConvertToMetric(\"process_mem_share_size_bytes\",\n float64(stats.Process.Memory.Share),\n \"GAUGE\",\n nil))\n\n metrics = append(metrics, c.ConvertToMetric(\"process_mem_virtual_size_bytes\",\n float64(stats.Process.Memory.TotalVirtual),\n \"GAUGE\",\n nil))\n\n metrics = append(metrics, c.ConvertToMetric(\"process_open_files_count\",\n float64(stats.Process.OpenFD),\n \"GAUGE\",\n nil))\n\n metrics = append(metrics, c.ConvertToMetric(\"process_cpu_time_seconds_sum\",\n float64(stats.Process.CPU.Total / 1000),\n \"COUNTER\",\n nil))\n\n metrics = append(metrics, c.ConvertToMetric(\"process_cpu_time_seconds_sum\",\n float64(stats.Process.CPU.Sys / 1000),\n \"COUNTER\",\n nil))\n\n metrics = append(metrics, c.ConvertToMetric(\"process_cpu_time_seconds_sum\",\n float64(stats.Process.CPU.User / 1000),\n \"COUNTER\",\n nil))\n\n }\n\n return metrics\n}", "func (r *renderer) Render(w io.Writer, m list.Model, index int, item list.Item) {\n\ti, ok := item.(candidateItem)\n\tif !ok {\n\t\treturn\n\t}\n\ts := i.Title()\n\tiw := rw.StringWidth(s)\n\tif iw < r.width {\n\t\ts += strings.Repeat(\" \", r.width-iw)\n\t}\n\tst := &r.m.Styles\n\tfn := st.Item.Render\n\tif r.m.selectedList == r.listIdx && index == m.Index() {\n\t\tfn = st.SelectedItem.Render\n\t}\n\tfmt.Fprint(w, fn(s))\n}", "func RenderList(w http.ResponseWriter, r *http.Request, l []Renderer) error {\n\tfor _, v := range l {\n\t\tif err := renderer(w, r, v); err != nil {\n\t\t\treturn err\n\t\t}\n\t}\n\tRespond(w, r, l)\n\treturn nil\n}", "func (ctx Context) Count(input chan float64) (n uint) {\n\tfor _ = range input {\n\t\tn++\n\t}\n\n\treturn n\n}" ]
[ "0.5151113", "0.5004257", "0.49938148", "0.4990763", "0.4976607", "0.4951048", "0.49248818", "0.4916577", "0.4866774", "0.4800929", "0.47981137", "0.47981137", "0.47901735", "0.4756205", "0.46942908", "0.46894792", "0.46840665", "0.4677495", "0.4675726", "0.46637085", "0.46624836", "0.46565616", "0.4645818", "0.46417838", "0.46114147", "0.46049377", "0.4599983", "0.458619", "0.4585512", "0.45697337", "0.45482323", "0.45183632", "0.45173186", "0.45165563", "0.45099097", "0.45075205", "0.45074305", "0.45031667", "0.45007053", "0.44816276", "0.44726396", "0.44723874", "0.44668853", "0.44658583", "0.44618943", "0.44542634", "0.44504246", "0.44503716", "0.4449292", "0.44484746", "0.44394025", "0.44279328", "0.4424622", "0.4416367", "0.4406913", "0.4385353", "0.43724492", "0.43671498", "0.4365641", "0.4354382", "0.4346163", "0.43457067", "0.43430066", "0.43414623", "0.43345138", "0.43341932", "0.43322212", "0.43261778", "0.4323278", "0.43211812", "0.4312017", "0.4306904", "0.43046993", "0.43026555", "0.4302624", "0.4301722", "0.4301722", "0.4299764", "0.4294337", "0.42939496", "0.42895654", "0.42890137", "0.42760253", "0.42754024", "0.4270864", "0.42652878", "0.42581832", "0.42545912", "0.42537668", "0.42508844", "0.4250403", "0.42474648", "0.42411345", "0.42408386", "0.42369917", "0.42342585", "0.42337465", "0.42302683", "0.42279676", "0.42246485", "0.42111897" ]
0.0
-1
Parameter image has type C.GLeglImageOES.
func EGLImageTargetTexStorageEXT(target uint32, image unsafe.Pointer, attrib_list *int32) { C.glowEGLImageTargetTexStorageEXT(gpEGLImageTargetTexStorageEXT, (C.GLenum)(target), (C.GLeglImageOES)(image), (*C.GLint)(unsafe.Pointer(attrib_list))) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func EGLImageTargetTextureStorageEXT(texture uint32, image unsafe.Pointer, attrib_list *int32) {\n\tC.glowEGLImageTargetTextureStorageEXT(gpEGLImageTargetTextureStorageEXT, (C.GLuint)(texture), (C.GLeglImageOES)(image), (*C.GLint)(unsafe.Pointer(attrib_list)))\n}", "func EGLImageTargetTextureStorageEXT(texture uint32, image unsafe.Pointer, attrib_list *int32) {\n\tC.glowEGLImageTargetTextureStorageEXT(gpEGLImageTargetTextureStorageEXT, (C.GLuint)(texture), (C.GLeglImageOES)(image), (*C.GLint)(unsafe.Pointer(attrib_list)))\n}", "func GetTexParameterfv(target Enum, pname Enum, params []Float) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tcpname, _ := (C.GLenum)(pname), cgoAllocsUnknown\n\tcparams, _ := (*C.GLfloat)(unsafe.Pointer((*sliceHeader)(unsafe.Pointer(&params)).Data)), cgoAllocsUnknown\n\tC.glGetTexParameterfv(ctarget, cpname, cparams)\n}", "func (b *GoGLBackend) AsImage() backendbase.Image {\n\treturn nil\n}", "func GetTexImage(target uint32, level int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowGetTexImage(gpGetTexImage, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexImage1D(target uint32, level int32, internalformat int32, width int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexImage1D(gpTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexImage2D(gpTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexImage2D(target Enum, level int, width, height int, format Enum, ty Enum, data []byte) {\n\tp := unsafe.Pointer(nil)\n\tif len(data) > 0 {\n\t\tp = gl.Ptr(&data[0])\n\t}\n\tgl.TexImage2D(uint32(target), int32(level), int32(format), int32(width), int32(height), 0, uint32(format), uint32(ty), p)\n}", "func TexImage2D(target GLEnum, level int32, internalformat GLEnum, width, height, border int32, format, xtype GLEnum, pixels []float32) {\n\tgl.TexImage2D(uint32(target), level, int32(internalformat), width, height, border, uint32(format), uint32(xtype), unsafe.Pointer(&pixels[0]))\n}", "func (g *GLTF) LoadImage(imgIdx int) (*image.RGBA, error) {\n\n\t// Check if provided image index is valid\n\tif imgIdx < 0 || imgIdx >= len(g.Images) {\n\t\treturn nil, fmt.Errorf(\"invalid image index\")\n\t}\n\timgData := g.Images[imgIdx]\n\t// Return cached if available\n\tif imgData.cache != nil {\n\t\tlog.Debug(\"Fetching Image %d (cached)\", imgIdx)\n\t\treturn imgData.cache, nil\n\t}\n\tlog.Debug(\"Loading Image %d\", imgIdx)\n\n\tvar data []byte\n\tvar err error\n\t// If Uri is empty, load image from GLB binary chunk\n\tif imgData.Uri == \"\" {\n\t\tif imgData.BufferView == nil {\n\t\t\treturn nil, fmt.Errorf(\"image has empty URI and no BufferView\")\n\t\t}\n\t\tdata, err = g.loadBufferView(*imgData.BufferView)\n\t} else if isDataURL(imgData.Uri) {\n\t\t// Checks if image URI is data URL\n\t\tdata, err = loadDataURL(imgData.Uri)\n\t} else {\n\t\t// Load image data from file\n\t\tdata, err = g.loadFileBytes(imgData.Uri)\n\t}\n\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\n\t// Decodes image data\n\tbb := bytes.NewBuffer(data)\n\timg, _, err := image.Decode(bb)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\n\t// Converts image to RGBA format\n\trgba := image.NewRGBA(img.Bounds())\n\tif rgba.Stride != rgba.Rect.Size().X*4 {\n\t\treturn nil, fmt.Errorf(\"unsupported stride\")\n\t}\n\tdraw.Draw(rgba, rgba.Bounds(), img, image.Point{0, 0}, draw.Src)\n\n\t// Cache image\n\tg.Images[imgIdx].cache = rgba\n\n\treturn rgba, nil\n}", "func TexImage2D(target Enum, level Int, internalformat Int, width Sizei, height Sizei, border Int, format Enum, kind Enum, pixels unsafe.Pointer) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tclevel, _ := (C.GLint)(level), cgoAllocsUnknown\n\tcinternalformat, _ := (C.GLint)(internalformat), cgoAllocsUnknown\n\tcwidth, _ := (C.GLsizei)(width), cgoAllocsUnknown\n\tcheight, _ := (C.GLsizei)(height), cgoAllocsUnknown\n\tcborder, _ := (C.GLint)(border), cgoAllocsUnknown\n\tcformat, _ := (C.GLenum)(format), cgoAllocsUnknown\n\tckind, _ := (C.GLenum)(kind), cgoAllocsUnknown\n\tcpixels, _ := (unsafe.Pointer)(unsafe.Pointer(pixels)), cgoAllocsUnknown\n\tC.glTexImage2D(ctarget, clevel, cinternalformat, cwidth, cheight, cborder, cformat, ckind, cpixels)\n}", "func TexParameterf(target Enum, pname Enum, param Float) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tcpname, _ := (C.GLenum)(pname), cgoAllocsUnknown\n\tcparam, _ := (C.GLfloat)(param), cgoAllocsUnknown\n\tC.glTexParameterf(ctarget, cpname, cparam)\n}", "func hogImage(img image.Image, binSize int) cv.RealVectorImage {\n\treturn hog.HOG(cv.ColorImageToReal(img), binSize)\n}", "func TexParameteri(target Enum, pname Enum, param Int) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tcpname, _ := (C.GLenum)(pname), cgoAllocsUnknown\n\tcparam, _ := (C.GLint)(param), cgoAllocsUnknown\n\tC.glTexParameteri(ctarget, cpname, cparam)\n}", "func GetTexImage(target uint32, level int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall6(gpGetTexImage, 5, uintptr(target), uintptr(level), uintptr(format), uintptr(xtype), uintptr(pixels), 0)\n}", "func (self *GameObjectCreator) Image1O(x int, y int, key interface{}, frame interface{}) *Image{\n return &Image{self.Object.Call(\"image\", x, y, key, frame)}\n}", "func (b *XMobileBackend) PutImageData(img *image.RGBA, x, y int) {\n\tb.activate()\n\n\tb.glctx.ActiveTexture(gl.TEXTURE0)\n\tif b.imageBufTex.Value == 0 {\n\t\tb.imageBufTex = b.glctx.CreateTexture()\n\t\tb.glctx.BindTexture(gl.TEXTURE_2D, b.imageBufTex)\n\t\tb.glctx.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.LINEAR)\n\t\tb.glctx.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, gl.LINEAR)\n\t\tb.glctx.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_S, gl.CLAMP_TO_EDGE)\n\t\tb.glctx.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_T, gl.CLAMP_TO_EDGE)\n\t} else {\n\t\tb.glctx.BindTexture(gl.TEXTURE_2D, b.imageBufTex)\n\t}\n\n\tw, h := img.Bounds().Dx(), img.Bounds().Dy()\n\n\tif img.Stride == img.Bounds().Dx()*4 {\n\t\tb.glctx.TexImage2D(gl.TEXTURE_2D, 0, gl.RGBA, w, h, gl.RGBA, gl.UNSIGNED_BYTE, img.Pix[0:])\n\t} else {\n\t\tdata := make([]uint8, 0, w*h*4)\n\t\tfor cy := 0; cy < h; cy++ {\n\t\t\tstart := cy * img.Stride\n\t\t\tend := start + w*4\n\t\t\tdata = append(data, img.Pix[start:end]...)\n\t\t}\n\t\tb.glctx.TexImage2D(gl.TEXTURE_2D, 0, gl.RGBA, w, h, gl.RGBA, gl.UNSIGNED_BYTE, data[0:])\n\t}\n\n\tdx, dy := float32(x), float32(y)\n\tdw, dh := float32(w), float32(h)\n\n\tb.glctx.BindBuffer(gl.ARRAY_BUFFER, b.buf)\n\tdata := [16]float32{dx, dy, dx + dw, dy, dx + dw, dy + dh, dx, dy + dh,\n\t\t0, 0, 1, 0, 1, 1, 0, 1}\n\tb.glctx.BufferData(gl.ARRAY_BUFFER, byteSlice(unsafe.Pointer(&data[0]), len(data)*4), gl.STREAM_DRAW)\n\n\tb.glctx.UseProgram(b.shd.ID)\n\tb.glctx.Uniform1i(b.shd.Image, 0)\n\tb.glctx.Uniform2f(b.shd.CanvasSize, float32(b.fw), float32(b.fh))\n\tb.glctx.UniformMatrix3fv(b.shd.Matrix, mat3identity[:])\n\tb.glctx.Uniform1f(b.shd.GlobalAlpha, 1)\n\tb.glctx.Uniform1i(b.shd.UseAlphaTex, 0)\n\tb.glctx.Uniform1i(b.shd.Func, shdFuncImage)\n\tb.glctx.VertexAttribPointer(b.shd.Vertex, 2, gl.FLOAT, false, 0, 0)\n\tb.glctx.VertexAttribPointer(b.shd.TexCoord, 2, gl.FLOAT, false, 0, 8*4)\n\tb.glctx.EnableVertexAttribArray(b.shd.Vertex)\n\tb.glctx.EnableVertexAttribArray(b.shd.TexCoord)\n\tb.glctx.DrawArrays(gl.TRIANGLE_FAN, 0, 4)\n\tb.glctx.DisableVertexAttribArray(b.shd.Vertex)\n\tb.glctx.DisableVertexAttribArray(b.shd.TexCoord)\n}", "func BindImageTexture(unit uint32, texture uint32, level int32, layered bool, layer int32, access uint32, format uint32) {\n C.glowBindImageTexture(gpBindImageTexture, (C.GLuint)(unit), (C.GLuint)(texture), (C.GLint)(level), (C.GLboolean)(boolToInt(layered)), (C.GLint)(layer), (C.GLenum)(access), (C.GLenum)(format))\n}", "func TexImage1D(target uint32, level int32, internalformat int32, width int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexImage1D(gpTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexImage1D(target uint32, level int32, internalformat int32, width int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexImage1D(gpTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func GetTexParameterfv(dst []float32, target, pname Enum) {\n\tgl.GetTexParameterfv(uint32(target), uint32(pname), &dst[0])\n}", "func (native *OpenGL) TexImage2D(target uint32, level int32, internalFormat uint32, width int32, height int32,\n\tborder int32, format uint32, xtype uint32, pixels interface{}) {\n\tptr, isPointer := pixels.(unsafe.Pointer)\n\tif isPointer {\n\t\tgl.TexImage2D(target, level, int32(internalFormat), width, height, border, format, xtype, ptr)\n\t} else {\n\t\tgl.TexImage2D(target, level, int32(internalFormat), width, height, border, format, xtype, gl.Ptr(pixels))\n\t}\n}", "func GetTexParameteriv(target Enum, pname Enum, params []Int) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tcpname, _ := (C.GLenum)(pname), cgoAllocsUnknown\n\tcparams, _ := (*C.GLint)(unsafe.Pointer((*sliceHeader)(unsafe.Pointer(&params)).Data)), cgoAllocsUnknown\n\tC.glGetTexParameteriv(ctarget, cpname, cparams)\n}", "func TexImage1D(target uint32, level int32, internalformat int32, width int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTexImage1D, 8, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(width), uintptr(border), uintptr(format), uintptr(xtype), uintptr(pixels), 0)\n}", "func CompressedTexImage2D(target uint32, level int32, internalformat uint32, width int32, height int32, border int32, imageSize int32, data unsafe.Pointer) {\n C.glowCompressedTexImage2D(gpCompressedTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func (self *GameObjectCreator) Image(x int, y int, key interface{}) *Image{\n return &Image{self.Object.Call(\"image\", x, y, key)}\n}", "func FramebufferParameteri(target uint32, pname uint32, param int32) {\n C.glowFramebufferParameteri(gpFramebufferParameteri, (C.GLenum)(target), (C.GLenum)(pname), (C.GLint)(param))\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexImage2D(gpTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexImage2D(gpTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func GetTexImage(target uint32, level int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowGetTexImage(gpGetTexImage, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func GetTexImage(target uint32, level int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowGetTexImage(gpGetTexImage, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CompressedTexImage1D(target uint32, level int32, internalformat uint32, width int32, border int32, imageSize int32, data unsafe.Pointer) {\n C.glowCompressedTexImage1D(gpCompressedTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func GetCompressedTexImage(target uint32, level int32, img unsafe.Pointer) {\n C.glowGetCompressedTexImage(gpGetCompressedTexImage, (C.GLenum)(target), (C.GLint)(level), img)\n}", "func TexParameterfv(target Enum, pname Enum, params []Float) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tcpname, _ := (C.GLenum)(pname), cgoAllocsUnknown\n\tcparams, _ := (*C.GLfloat)(unsafe.Pointer((*sliceHeader)(unsafe.Pointer(&params)).Data)), cgoAllocsUnknown\n\tC.glTexParameterfv(ctarget, cpname, cparams)\n}", "func EGLImageTargetTextureStorageEXT(texture uint32, image unsafe.Pointer, attrib_list *int32) {\n\tsyscall.Syscall(gpEGLImageTargetTextureStorageEXT, 3, uintptr(texture), uintptr(image), uintptr(unsafe.Pointer(attrib_list)))\n}", "func GetRenderbufferParameteriv(target uint32, pname uint32, params *int32) {\n C.glowGetRenderbufferParameteriv(gpGetRenderbufferParameteriv, (C.GLenum)(target), (C.GLenum)(pname), (*C.GLint)(unsafe.Pointer(params)))\n}", "func (debugging *debuggingOpenGL) TexImage2D(target uint32, level int32, internalFormat uint32, width int32, height int32,\n\tborder int32, format uint32, xtype uint32, pixels interface{}) {\n\tdebugging.recordEntry(\"TexImage2D\", target, level, internalFormat, width, height, border, format, xtype, pixels)\n\tdebugging.gl.TexImage2D(target, level, internalFormat, width, height, border, format, xtype, pixels)\n\tdebugging.recordExit(\"TexImage2D\")\n}", "func (native *OpenGL) TexParameteri(target uint32, pname uint32, param int32) {\n\tgl.TexParameteri(target, pname, param)\n}", "func TexParameterf(target, pname GLEnum, param float32) {\n\tgl.TexParameterf(uint32(target), uint32(pname), param)\n}", "func imageGet(L *lua.LState) int {\n\tp := checkImage(L)\n\n\tL.Push(lua.LNumber(*p))\n\n\treturn 1\n}", "func TexParameterf(target, pname Enum, param float32) {\n\tgl.TexParameterf(uint32(target), uint32(pname), param)\n}", "func TexParameteri(target, pname GLEnum, param int32) {\n\tgl.TexParameteri(uint32(target), uint32(pname), param)\n}", "func (self *GameObjectCreator) ImageI(args ...interface{}) *Image{\n return &Image{self.Object.Call(\"image\", args)}\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTexImage2D, 9, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(width), uintptr(height), uintptr(border), uintptr(format), uintptr(xtype), uintptr(pixels))\n}", "func (native *OpenGL) TexParameterf(target uint32, pname uint32, param float32) {\n\tgl.TexParameterf(target, pname, param)\n}", "func TexParameteriv(target Enum, pname Enum, params []Int) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tcpname, _ := (C.GLenum)(pname), cgoAllocsUnknown\n\tcparams, _ := (*C.GLint)(unsafe.Pointer((*sliceHeader)(unsafe.Pointer(&params)).Data)), cgoAllocsUnknown\n\tC.glTexParameteriv(ctarget, cpname, cparams)\n}", "func PixelStorei(pname Enum, param Int) {\n\tcpname, _ := (C.GLenum)(pname), cgoAllocsUnknown\n\tcparam, _ := (C.GLint)(param), cgoAllocsUnknown\n\tC.glPixelStorei(cpname, cparam)\n}", "func TexParameteri(target, pname Enum, param int) {\n\tgl.TexParameteri(uint32(target), uint32(pname), int32(param))\n}", "func Uniform1fv(location int32, count int32, value *float32) {\n C.glowUniform1fv(gpUniform1fv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func (gl *WebGL) TexImage2D(target GLEnum, level int, internalFormat GLEnum, format GLEnum, texelType GLEnum, pixels interface{}) {\n\tgl.context.Call(\"texImage2D\", target, level, internalFormat, format, texelType, pixels)\n}", "func PassThrough(token float32) {\n C.glowPassThrough(gpPassThrough, (C.GLfloat)(token))\n}", "func ArrayElement(i int32) {\n C.glowArrayElement(gpArrayElement, (C.GLint)(i))\n}", "func GetTextureImage(texture uint32, level int32, format uint32, xtype uint32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetTextureImage(gpGetTextureImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLenum)(format), (C.GLenum)(xtype), (C.GLsizei)(bufSize), pixels)\n}", "func GetTextureImage(texture uint32, level int32, format uint32, xtype uint32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetTextureImage(gpGetTextureImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLenum)(format), (C.GLenum)(xtype), (C.GLsizei)(bufSize), pixels)\n}", "func (self *Graphics) GenerateTexture1O(resolution int) *Texture{\n return &Texture{self.Object.Call(\"generateTexture\", resolution)}\n}", "func InitGo(loader func(string) unsafe.Pointer) {\n ver := Version{OpenGL, -1, -1}\n\n\tC.pfn_glGetString = C.PFNGLGETSTRING(loader(\"glGetString\"))\n\tvs := C.GoString((*C.char)(unsafe.Pointer(C.gogl_glGetString(GL_VERSION))))\n i := strings.IndexFunc(vs, func(r rune) bool {\n return r >= '0' && r <= '9'\n })\n if i >= 0 {\n fmt.Sscanf(vs[i:], \"%d.%d\", &ver.Major, &ver.Minor)\n }\n if !ver.GE(OpenGL, 1, 0) {\n panic(\"failed to identify OpenGL version\")\n }\n C.GLVersion.major = C.int(ver.Major)\n C.GLVersion.minor = C.int(ver.Minor)\n\n C.pfn_glAccum = C.PFNGLACCUM(loader(\"glAccum\"))\n C.pfn_glAlphaFunc = C.PFNGLALPHAFUNC(loader(\"glAlphaFunc\"))\n C.pfn_glBegin = C.PFNGLBEGIN(loader(\"glBegin\"))\n C.pfn_glBitmap = C.PFNGLBITMAP(loader(\"glBitmap\"))\n C.pfn_glBlendFunc = C.PFNGLBLENDFUNC(loader(\"glBlendFunc\"))\n C.pfn_glCallList = C.PFNGLCALLLIST(loader(\"glCallList\"))\n C.pfn_glCallLists = C.PFNGLCALLLISTS(loader(\"glCallLists\"))\n C.pfn_glClear = C.PFNGLCLEAR(loader(\"glClear\"))\n C.pfn_glClearAccum = C.PFNGLCLEARACCUM(loader(\"glClearAccum\"))\n C.pfn_glClearColor = C.PFNGLCLEARCOLOR(loader(\"glClearColor\"))\n C.pfn_glClearDepth = C.PFNGLCLEARDEPTH(loader(\"glClearDepth\"))\n C.pfn_glClearIndex = C.PFNGLCLEARINDEX(loader(\"glClearIndex\"))\n C.pfn_glClearStencil = C.PFNGLCLEARSTENCIL(loader(\"glClearStencil\"))\n C.pfn_glClipPlane = C.PFNGLCLIPPLANE(loader(\"glClipPlane\"))\n C.pfn_glColor3b = C.PFNGLCOLOR3B(loader(\"glColor3b\"))\n C.pfn_glColor3bv = C.PFNGLCOLOR3BV(loader(\"glColor3bv\"))\n C.pfn_glColor3d = C.PFNGLCOLOR3D(loader(\"glColor3d\"))\n C.pfn_glColor3dv = C.PFNGLCOLOR3DV(loader(\"glColor3dv\"))\n C.pfn_glColor3f = C.PFNGLCOLOR3F(loader(\"glColor3f\"))\n C.pfn_glColor3fv = C.PFNGLCOLOR3FV(loader(\"glColor3fv\"))\n C.pfn_glColor3i = C.PFNGLCOLOR3I(loader(\"glColor3i\"))\n C.pfn_glColor3iv = C.PFNGLCOLOR3IV(loader(\"glColor3iv\"))\n C.pfn_glColor3s = C.PFNGLCOLOR3S(loader(\"glColor3s\"))\n C.pfn_glColor3sv = C.PFNGLCOLOR3SV(loader(\"glColor3sv\"))\n C.pfn_glColor3ub = C.PFNGLCOLOR3UB(loader(\"glColor3ub\"))\n C.pfn_glColor3ubv = C.PFNGLCOLOR3UBV(loader(\"glColor3ubv\"))\n C.pfn_glColor3ui = C.PFNGLCOLOR3UI(loader(\"glColor3ui\"))\n C.pfn_glColor3uiv = C.PFNGLCOLOR3UIV(loader(\"glColor3uiv\"))\n C.pfn_glColor3us = C.PFNGLCOLOR3US(loader(\"glColor3us\"))\n C.pfn_glColor3usv = C.PFNGLCOLOR3USV(loader(\"glColor3usv\"))\n C.pfn_glColor4b = C.PFNGLCOLOR4B(loader(\"glColor4b\"))\n C.pfn_glColor4bv = C.PFNGLCOLOR4BV(loader(\"glColor4bv\"))\n C.pfn_glColor4d = C.PFNGLCOLOR4D(loader(\"glColor4d\"))\n C.pfn_glColor4dv = C.PFNGLCOLOR4DV(loader(\"glColor4dv\"))\n C.pfn_glColor4f = C.PFNGLCOLOR4F(loader(\"glColor4f\"))\n C.pfn_glColor4fv = C.PFNGLCOLOR4FV(loader(\"glColor4fv\"))\n C.pfn_glColor4i = C.PFNGLCOLOR4I(loader(\"glColor4i\"))\n C.pfn_glColor4iv = C.PFNGLCOLOR4IV(loader(\"glColor4iv\"))\n C.pfn_glColor4s = C.PFNGLCOLOR4S(loader(\"glColor4s\"))\n C.pfn_glColor4sv = C.PFNGLCOLOR4SV(loader(\"glColor4sv\"))\n C.pfn_glColor4ub = C.PFNGLCOLOR4UB(loader(\"glColor4ub\"))\n C.pfn_glColor4ubv = C.PFNGLCOLOR4UBV(loader(\"glColor4ubv\"))\n C.pfn_glColor4ui = C.PFNGLCOLOR4UI(loader(\"glColor4ui\"))\n C.pfn_glColor4uiv = C.PFNGLCOLOR4UIV(loader(\"glColor4uiv\"))\n C.pfn_glColor4us = C.PFNGLCOLOR4US(loader(\"glColor4us\"))\n C.pfn_glColor4usv = C.PFNGLCOLOR4USV(loader(\"glColor4usv\"))\n C.pfn_glColorMask = C.PFNGLCOLORMASK(loader(\"glColorMask\"))\n C.pfn_glColorMaterial = C.PFNGLCOLORMATERIAL(loader(\"glColorMaterial\"))\n C.pfn_glCopyPixels = C.PFNGLCOPYPIXELS(loader(\"glCopyPixels\"))\n C.pfn_glCullFace = C.PFNGLCULLFACE(loader(\"glCullFace\"))\n C.pfn_glDeleteLists = C.PFNGLDELETELISTS(loader(\"glDeleteLists\"))\n C.pfn_glDepthFunc = C.PFNGLDEPTHFUNC(loader(\"glDepthFunc\"))\n C.pfn_glDepthMask = C.PFNGLDEPTHMASK(loader(\"glDepthMask\"))\n C.pfn_glDepthRange = C.PFNGLDEPTHRANGE(loader(\"glDepthRange\"))\n C.pfn_glDisable = C.PFNGLDISABLE(loader(\"glDisable\"))\n C.pfn_glDrawBuffer = C.PFNGLDRAWBUFFER(loader(\"glDrawBuffer\"))\n C.pfn_glDrawPixels = C.PFNGLDRAWPIXELS(loader(\"glDrawPixels\"))\n C.pfn_glEdgeFlag = C.PFNGLEDGEFLAG(loader(\"glEdgeFlag\"))\n C.pfn_glEdgeFlagv = C.PFNGLEDGEFLAGV(loader(\"glEdgeFlagv\"))\n C.pfn_glEnable = C.PFNGLENABLE(loader(\"glEnable\"))\n C.pfn_glEnd = C.PFNGLEND(loader(\"glEnd\"))\n C.pfn_glEndList = C.PFNGLENDLIST(loader(\"glEndList\"))\n C.pfn_glEvalCoord1d = C.PFNGLEVALCOORD1D(loader(\"glEvalCoord1d\"))\n C.pfn_glEvalCoord1dv = C.PFNGLEVALCOORD1DV(loader(\"glEvalCoord1dv\"))\n C.pfn_glEvalCoord1f = C.PFNGLEVALCOORD1F(loader(\"glEvalCoord1f\"))\n C.pfn_glEvalCoord1fv = C.PFNGLEVALCOORD1FV(loader(\"glEvalCoord1fv\"))\n C.pfn_glEvalCoord2d = C.PFNGLEVALCOORD2D(loader(\"glEvalCoord2d\"))\n C.pfn_glEvalCoord2dv = C.PFNGLEVALCOORD2DV(loader(\"glEvalCoord2dv\"))\n C.pfn_glEvalCoord2f = C.PFNGLEVALCOORD2F(loader(\"glEvalCoord2f\"))\n C.pfn_glEvalCoord2fv = C.PFNGLEVALCOORD2FV(loader(\"glEvalCoord2fv\"))\n C.pfn_glEvalMesh1 = C.PFNGLEVALMESH1(loader(\"glEvalMesh1\"))\n C.pfn_glEvalMesh2 = C.PFNGLEVALMESH2(loader(\"glEvalMesh2\"))\n C.pfn_glEvalPoint1 = C.PFNGLEVALPOINT1(loader(\"glEvalPoint1\"))\n C.pfn_glEvalPoint2 = C.PFNGLEVALPOINT2(loader(\"glEvalPoint2\"))\n C.pfn_glFeedbackBuffer = C.PFNGLFEEDBACKBUFFER(loader(\"glFeedbackBuffer\"))\n C.pfn_glFinish = C.PFNGLFINISH(loader(\"glFinish\"))\n C.pfn_glFlush = C.PFNGLFLUSH(loader(\"glFlush\"))\n C.pfn_glFogf = C.PFNGLFOGF(loader(\"glFogf\"))\n C.pfn_glFogfv = C.PFNGLFOGFV(loader(\"glFogfv\"))\n C.pfn_glFogi = C.PFNGLFOGI(loader(\"glFogi\"))\n C.pfn_glFogiv = C.PFNGLFOGIV(loader(\"glFogiv\"))\n C.pfn_glFrontFace = C.PFNGLFRONTFACE(loader(\"glFrontFace\"))\n C.pfn_glFrustum = C.PFNGLFRUSTUM(loader(\"glFrustum\"))\n C.pfn_glGenLists = C.PFNGLGENLISTS(loader(\"glGenLists\"))\n C.pfn_glGetBooleanv = C.PFNGLGETBOOLEANV(loader(\"glGetBooleanv\"))\n C.pfn_glGetClipPlane = C.PFNGLGETCLIPPLANE(loader(\"glGetClipPlane\"))\n C.pfn_glGetDoublev = C.PFNGLGETDOUBLEV(loader(\"glGetDoublev\"))\n C.pfn_glGetError = C.PFNGLGETERROR(loader(\"glGetError\"))\n C.pfn_glGetFloatv = C.PFNGLGETFLOATV(loader(\"glGetFloatv\"))\n C.pfn_glGetIntegerv = C.PFNGLGETINTEGERV(loader(\"glGetIntegerv\"))\n C.pfn_glGetLightfv = C.PFNGLGETLIGHTFV(loader(\"glGetLightfv\"))\n C.pfn_glGetLightiv = C.PFNGLGETLIGHTIV(loader(\"glGetLightiv\"))\n C.pfn_glGetMapdv = C.PFNGLGETMAPDV(loader(\"glGetMapdv\"))\n C.pfn_glGetMapfv = C.PFNGLGETMAPFV(loader(\"glGetMapfv\"))\n C.pfn_glGetMapiv = C.PFNGLGETMAPIV(loader(\"glGetMapiv\"))\n C.pfn_glGetMaterialfv = C.PFNGLGETMATERIALFV(loader(\"glGetMaterialfv\"))\n C.pfn_glGetMaterialiv = C.PFNGLGETMATERIALIV(loader(\"glGetMaterialiv\"))\n C.pfn_glGetPixelMapfv = C.PFNGLGETPIXELMAPFV(loader(\"glGetPixelMapfv\"))\n C.pfn_glGetPixelMapuiv = C.PFNGLGETPIXELMAPUIV(loader(\"glGetPixelMapuiv\"))\n C.pfn_glGetPixelMapusv = C.PFNGLGETPIXELMAPUSV(loader(\"glGetPixelMapusv\"))\n C.pfn_glGetPolygonStipple = C.PFNGLGETPOLYGONSTIPPLE(loader(\"glGetPolygonStipple\"))\n C.pfn_glGetString = C.PFNGLGETSTRING(loader(\"glGetString\"))\n C.pfn_glGetTexEnvfv = C.PFNGLGETTEXENVFV(loader(\"glGetTexEnvfv\"))\n C.pfn_glGetTexEnviv = C.PFNGLGETTEXENVIV(loader(\"glGetTexEnviv\"))\n C.pfn_glGetTexGendv = C.PFNGLGETTEXGENDV(loader(\"glGetTexGendv\"))\n C.pfn_glGetTexGenfv = C.PFNGLGETTEXGENFV(loader(\"glGetTexGenfv\"))\n C.pfn_glGetTexGeniv = C.PFNGLGETTEXGENIV(loader(\"glGetTexGeniv\"))\n C.pfn_glGetTexImage = C.PFNGLGETTEXIMAGE(loader(\"glGetTexImage\"))\n C.pfn_glGetTexLevelParameterfv = C.PFNGLGETTEXLEVELPARAMETERFV(loader(\"glGetTexLevelParameterfv\"))\n C.pfn_glGetTexLevelParameteriv = C.PFNGLGETTEXLEVELPARAMETERIV(loader(\"glGetTexLevelParameteriv\"))\n C.pfn_glGetTexParameterfv = C.PFNGLGETTEXPARAMETERFV(loader(\"glGetTexParameterfv\"))\n C.pfn_glGetTexParameteriv = C.PFNGLGETTEXPARAMETERIV(loader(\"glGetTexParameteriv\"))\n C.pfn_glHint = C.PFNGLHINT(loader(\"glHint\"))\n C.pfn_glIndexMask = C.PFNGLINDEXMASK(loader(\"glIndexMask\"))\n C.pfn_glIndexd = C.PFNGLINDEXD(loader(\"glIndexd\"))\n C.pfn_glIndexdv = C.PFNGLINDEXDV(loader(\"glIndexdv\"))\n C.pfn_glIndexf = C.PFNGLINDEXF(loader(\"glIndexf\"))\n C.pfn_glIndexfv = C.PFNGLINDEXFV(loader(\"glIndexfv\"))\n C.pfn_glIndexi = C.PFNGLINDEXI(loader(\"glIndexi\"))\n C.pfn_glIndexiv = C.PFNGLINDEXIV(loader(\"glIndexiv\"))\n C.pfn_glIndexs = C.PFNGLINDEXS(loader(\"glIndexs\"))\n C.pfn_glIndexsv = C.PFNGLINDEXSV(loader(\"glIndexsv\"))\n C.pfn_glInitNames = C.PFNGLINITNAMES(loader(\"glInitNames\"))\n C.pfn_glIsEnabled = C.PFNGLISENABLED(loader(\"glIsEnabled\"))\n C.pfn_glIsList = C.PFNGLISLIST(loader(\"glIsList\"))\n C.pfn_glLightModelf = C.PFNGLLIGHTMODELF(loader(\"glLightModelf\"))\n C.pfn_glLightModelfv = C.PFNGLLIGHTMODELFV(loader(\"glLightModelfv\"))\n C.pfn_glLightModeli = C.PFNGLLIGHTMODELI(loader(\"glLightModeli\"))\n C.pfn_glLightModeliv = C.PFNGLLIGHTMODELIV(loader(\"glLightModeliv\"))\n C.pfn_glLightf = C.PFNGLLIGHTF(loader(\"glLightf\"))\n C.pfn_glLightfv = C.PFNGLLIGHTFV(loader(\"glLightfv\"))\n C.pfn_glLighti = C.PFNGLLIGHTI(loader(\"glLighti\"))\n C.pfn_glLightiv = C.PFNGLLIGHTIV(loader(\"glLightiv\"))\n C.pfn_glLineStipple = C.PFNGLLINESTIPPLE(loader(\"glLineStipple\"))\n C.pfn_glLineWidth = C.PFNGLLINEWIDTH(loader(\"glLineWidth\"))\n C.pfn_glListBase = C.PFNGLLISTBASE(loader(\"glListBase\"))\n C.pfn_glLoadIdentity = C.PFNGLLOADIDENTITY(loader(\"glLoadIdentity\"))\n C.pfn_glLoadMatrixd = C.PFNGLLOADMATRIXD(loader(\"glLoadMatrixd\"))\n C.pfn_glLoadMatrixf = C.PFNGLLOADMATRIXF(loader(\"glLoadMatrixf\"))\n C.pfn_glLoadName = C.PFNGLLOADNAME(loader(\"glLoadName\"))\n C.pfn_glLogicOp = C.PFNGLLOGICOP(loader(\"glLogicOp\"))\n C.pfn_glMap1d = C.PFNGLMAP1D(loader(\"glMap1d\"))\n C.pfn_glMap1f = C.PFNGLMAP1F(loader(\"glMap1f\"))\n C.pfn_glMap2d = C.PFNGLMAP2D(loader(\"glMap2d\"))\n C.pfn_glMap2f = C.PFNGLMAP2F(loader(\"glMap2f\"))\n C.pfn_glMapGrid1d = C.PFNGLMAPGRID1D(loader(\"glMapGrid1d\"))\n C.pfn_glMapGrid1f = C.PFNGLMAPGRID1F(loader(\"glMapGrid1f\"))\n C.pfn_glMapGrid2d = C.PFNGLMAPGRID2D(loader(\"glMapGrid2d\"))\n C.pfn_glMapGrid2f = C.PFNGLMAPGRID2F(loader(\"glMapGrid2f\"))\n C.pfn_glMaterialf = C.PFNGLMATERIALF(loader(\"glMaterialf\"))\n C.pfn_glMaterialfv = C.PFNGLMATERIALFV(loader(\"glMaterialfv\"))\n C.pfn_glMateriali = C.PFNGLMATERIALI(loader(\"glMateriali\"))\n C.pfn_glMaterialiv = C.PFNGLMATERIALIV(loader(\"glMaterialiv\"))\n C.pfn_glMatrixMode = C.PFNGLMATRIXMODE(loader(\"glMatrixMode\"))\n C.pfn_glMultMatrixd = C.PFNGLMULTMATRIXD(loader(\"glMultMatrixd\"))\n C.pfn_glMultMatrixf = C.PFNGLMULTMATRIXF(loader(\"glMultMatrixf\"))\n C.pfn_glNewList = C.PFNGLNEWLIST(loader(\"glNewList\"))\n C.pfn_glNormal3b = C.PFNGLNORMAL3B(loader(\"glNormal3b\"))\n C.pfn_glNormal3bv = C.PFNGLNORMAL3BV(loader(\"glNormal3bv\"))\n C.pfn_glNormal3d = C.PFNGLNORMAL3D(loader(\"glNormal3d\"))\n C.pfn_glNormal3dv = C.PFNGLNORMAL3DV(loader(\"glNormal3dv\"))\n C.pfn_glNormal3f = C.PFNGLNORMAL3F(loader(\"glNormal3f\"))\n C.pfn_glNormal3fv = C.PFNGLNORMAL3FV(loader(\"glNormal3fv\"))\n C.pfn_glNormal3i = C.PFNGLNORMAL3I(loader(\"glNormal3i\"))\n C.pfn_glNormal3iv = C.PFNGLNORMAL3IV(loader(\"glNormal3iv\"))\n C.pfn_glNormal3s = C.PFNGLNORMAL3S(loader(\"glNormal3s\"))\n C.pfn_glNormal3sv = C.PFNGLNORMAL3SV(loader(\"glNormal3sv\"))\n C.pfn_glOrtho = C.PFNGLORTHO(loader(\"glOrtho\"))\n C.pfn_glPassThrough = C.PFNGLPASSTHROUGH(loader(\"glPassThrough\"))\n C.pfn_glPixelMapfv = C.PFNGLPIXELMAPFV(loader(\"glPixelMapfv\"))\n C.pfn_glPixelMapuiv = C.PFNGLPIXELMAPUIV(loader(\"glPixelMapuiv\"))\n C.pfn_glPixelMapusv = C.PFNGLPIXELMAPUSV(loader(\"glPixelMapusv\"))\n C.pfn_glPixelStoref = C.PFNGLPIXELSTOREF(loader(\"glPixelStoref\"))\n C.pfn_glPixelStorei = C.PFNGLPIXELSTOREI(loader(\"glPixelStorei\"))\n C.pfn_glPixelTransferf = C.PFNGLPIXELTRANSFERF(loader(\"glPixelTransferf\"))\n C.pfn_glPixelTransferi = C.PFNGLPIXELTRANSFERI(loader(\"glPixelTransferi\"))\n C.pfn_glPixelZoom = C.PFNGLPIXELZOOM(loader(\"glPixelZoom\"))\n C.pfn_glPointSize = C.PFNGLPOINTSIZE(loader(\"glPointSize\"))\n C.pfn_glPolygonMode = C.PFNGLPOLYGONMODE(loader(\"glPolygonMode\"))\n C.pfn_glPolygonStipple = C.PFNGLPOLYGONSTIPPLE(loader(\"glPolygonStipple\"))\n C.pfn_glPopAttrib = C.PFNGLPOPATTRIB(loader(\"glPopAttrib\"))\n C.pfn_glPopMatrix = C.PFNGLPOPMATRIX(loader(\"glPopMatrix\"))\n C.pfn_glPopName = C.PFNGLPOPNAME(loader(\"glPopName\"))\n C.pfn_glPushAttrib = C.PFNGLPUSHATTRIB(loader(\"glPushAttrib\"))\n C.pfn_glPushMatrix = C.PFNGLPUSHMATRIX(loader(\"glPushMatrix\"))\n C.pfn_glPushName = C.PFNGLPUSHNAME(loader(\"glPushName\"))\n C.pfn_glRasterPos2d = C.PFNGLRASTERPOS2D(loader(\"glRasterPos2d\"))\n C.pfn_glRasterPos2dv = C.PFNGLRASTERPOS2DV(loader(\"glRasterPos2dv\"))\n C.pfn_glRasterPos2f = C.PFNGLRASTERPOS2F(loader(\"glRasterPos2f\"))\n C.pfn_glRasterPos2fv = C.PFNGLRASTERPOS2FV(loader(\"glRasterPos2fv\"))\n C.pfn_glRasterPos2i = C.PFNGLRASTERPOS2I(loader(\"glRasterPos2i\"))\n C.pfn_glRasterPos2iv = C.PFNGLRASTERPOS2IV(loader(\"glRasterPos2iv\"))\n C.pfn_glRasterPos2s = C.PFNGLRASTERPOS2S(loader(\"glRasterPos2s\"))\n C.pfn_glRasterPos2sv = C.PFNGLRASTERPOS2SV(loader(\"glRasterPos2sv\"))\n C.pfn_glRasterPos3d = C.PFNGLRASTERPOS3D(loader(\"glRasterPos3d\"))\n C.pfn_glRasterPos3dv = C.PFNGLRASTERPOS3DV(loader(\"glRasterPos3dv\"))\n C.pfn_glRasterPos3f = C.PFNGLRASTERPOS3F(loader(\"glRasterPos3f\"))\n C.pfn_glRasterPos3fv = C.PFNGLRASTERPOS3FV(loader(\"glRasterPos3fv\"))\n C.pfn_glRasterPos3i = C.PFNGLRASTERPOS3I(loader(\"glRasterPos3i\"))\n C.pfn_glRasterPos3iv = C.PFNGLRASTERPOS3IV(loader(\"glRasterPos3iv\"))\n C.pfn_glRasterPos3s = C.PFNGLRASTERPOS3S(loader(\"glRasterPos3s\"))\n C.pfn_glRasterPos3sv = C.PFNGLRASTERPOS3SV(loader(\"glRasterPos3sv\"))\n C.pfn_glRasterPos4d = C.PFNGLRASTERPOS4D(loader(\"glRasterPos4d\"))\n C.pfn_glRasterPos4dv = C.PFNGLRASTERPOS4DV(loader(\"glRasterPos4dv\"))\n C.pfn_glRasterPos4f = C.PFNGLRASTERPOS4F(loader(\"glRasterPos4f\"))\n C.pfn_glRasterPos4fv = C.PFNGLRASTERPOS4FV(loader(\"glRasterPos4fv\"))\n C.pfn_glRasterPos4i = C.PFNGLRASTERPOS4I(loader(\"glRasterPos4i\"))\n C.pfn_glRasterPos4iv = C.PFNGLRASTERPOS4IV(loader(\"glRasterPos4iv\"))\n C.pfn_glRasterPos4s = C.PFNGLRASTERPOS4S(loader(\"glRasterPos4s\"))\n C.pfn_glRasterPos4sv = C.PFNGLRASTERPOS4SV(loader(\"glRasterPos4sv\"))\n C.pfn_glReadBuffer = C.PFNGLREADBUFFER(loader(\"glReadBuffer\"))\n C.pfn_glReadPixels = C.PFNGLREADPIXELS(loader(\"glReadPixels\"))\n C.pfn_glRectd = C.PFNGLRECTD(loader(\"glRectd\"))\n C.pfn_glRectdv = C.PFNGLRECTDV(loader(\"glRectdv\"))\n C.pfn_glRectf = C.PFNGLRECTF(loader(\"glRectf\"))\n C.pfn_glRectfv = C.PFNGLRECTFV(loader(\"glRectfv\"))\n C.pfn_glRecti = C.PFNGLRECTI(loader(\"glRecti\"))\n C.pfn_glRectiv = C.PFNGLRECTIV(loader(\"glRectiv\"))\n C.pfn_glRects = C.PFNGLRECTS(loader(\"glRects\"))\n C.pfn_glRectsv = C.PFNGLRECTSV(loader(\"glRectsv\"))\n C.pfn_glRenderMode = C.PFNGLRENDERMODE(loader(\"glRenderMode\"))\n C.pfn_glRotated = C.PFNGLROTATED(loader(\"glRotated\"))\n C.pfn_glRotatef = C.PFNGLROTATEF(loader(\"glRotatef\"))\n C.pfn_glScaled = C.PFNGLSCALED(loader(\"glScaled\"))\n C.pfn_glScalef = C.PFNGLSCALEF(loader(\"glScalef\"))\n C.pfn_glScissor = C.PFNGLSCISSOR(loader(\"glScissor\"))\n C.pfn_glSelectBuffer = C.PFNGLSELECTBUFFER(loader(\"glSelectBuffer\"))\n C.pfn_glShadeModel = C.PFNGLSHADEMODEL(loader(\"glShadeModel\"))\n C.pfn_glStencilFunc = C.PFNGLSTENCILFUNC(loader(\"glStencilFunc\"))\n C.pfn_glStencilMask = C.PFNGLSTENCILMASK(loader(\"glStencilMask\"))\n C.pfn_glStencilOp = C.PFNGLSTENCILOP(loader(\"glStencilOp\"))\n C.pfn_glTexCoord1d = C.PFNGLTEXCOORD1D(loader(\"glTexCoord1d\"))\n C.pfn_glTexCoord1dv = C.PFNGLTEXCOORD1DV(loader(\"glTexCoord1dv\"))\n C.pfn_glTexCoord1f = C.PFNGLTEXCOORD1F(loader(\"glTexCoord1f\"))\n C.pfn_glTexCoord1fv = C.PFNGLTEXCOORD1FV(loader(\"glTexCoord1fv\"))\n C.pfn_glTexCoord1i = C.PFNGLTEXCOORD1I(loader(\"glTexCoord1i\"))\n C.pfn_glTexCoord1iv = C.PFNGLTEXCOORD1IV(loader(\"glTexCoord1iv\"))\n C.pfn_glTexCoord1s = C.PFNGLTEXCOORD1S(loader(\"glTexCoord1s\"))\n C.pfn_glTexCoord1sv = C.PFNGLTEXCOORD1SV(loader(\"glTexCoord1sv\"))\n C.pfn_glTexCoord2d = C.PFNGLTEXCOORD2D(loader(\"glTexCoord2d\"))\n C.pfn_glTexCoord2dv = C.PFNGLTEXCOORD2DV(loader(\"glTexCoord2dv\"))\n C.pfn_glTexCoord2f = C.PFNGLTEXCOORD2F(loader(\"glTexCoord2f\"))\n C.pfn_glTexCoord2fv = C.PFNGLTEXCOORD2FV(loader(\"glTexCoord2fv\"))\n C.pfn_glTexCoord2i = C.PFNGLTEXCOORD2I(loader(\"glTexCoord2i\"))\n C.pfn_glTexCoord2iv = C.PFNGLTEXCOORD2IV(loader(\"glTexCoord2iv\"))\n C.pfn_glTexCoord2s = C.PFNGLTEXCOORD2S(loader(\"glTexCoord2s\"))\n C.pfn_glTexCoord2sv = C.PFNGLTEXCOORD2SV(loader(\"glTexCoord2sv\"))\n C.pfn_glTexCoord3d = C.PFNGLTEXCOORD3D(loader(\"glTexCoord3d\"))\n C.pfn_glTexCoord3dv = C.PFNGLTEXCOORD3DV(loader(\"glTexCoord3dv\"))\n C.pfn_glTexCoord3f = C.PFNGLTEXCOORD3F(loader(\"glTexCoord3f\"))\n C.pfn_glTexCoord3fv = C.PFNGLTEXCOORD3FV(loader(\"glTexCoord3fv\"))\n C.pfn_glTexCoord3i = C.PFNGLTEXCOORD3I(loader(\"glTexCoord3i\"))\n C.pfn_glTexCoord3iv = C.PFNGLTEXCOORD3IV(loader(\"glTexCoord3iv\"))\n C.pfn_glTexCoord3s = C.PFNGLTEXCOORD3S(loader(\"glTexCoord3s\"))\n C.pfn_glTexCoord3sv = C.PFNGLTEXCOORD3SV(loader(\"glTexCoord3sv\"))\n C.pfn_glTexCoord4d = C.PFNGLTEXCOORD4D(loader(\"glTexCoord4d\"))\n C.pfn_glTexCoord4dv = C.PFNGLTEXCOORD4DV(loader(\"glTexCoord4dv\"))\n C.pfn_glTexCoord4f = C.PFNGLTEXCOORD4F(loader(\"glTexCoord4f\"))\n C.pfn_glTexCoord4fv = C.PFNGLTEXCOORD4FV(loader(\"glTexCoord4fv\"))\n C.pfn_glTexCoord4i = C.PFNGLTEXCOORD4I(loader(\"glTexCoord4i\"))\n C.pfn_glTexCoord4iv = C.PFNGLTEXCOORD4IV(loader(\"glTexCoord4iv\"))\n C.pfn_glTexCoord4s = C.PFNGLTEXCOORD4S(loader(\"glTexCoord4s\"))\n C.pfn_glTexCoord4sv = C.PFNGLTEXCOORD4SV(loader(\"glTexCoord4sv\"))\n C.pfn_glTexEnvf = C.PFNGLTEXENVF(loader(\"glTexEnvf\"))\n C.pfn_glTexEnvfv = C.PFNGLTEXENVFV(loader(\"glTexEnvfv\"))\n C.pfn_glTexEnvi = C.PFNGLTEXENVI(loader(\"glTexEnvi\"))\n C.pfn_glTexEnviv = C.PFNGLTEXENVIV(loader(\"glTexEnviv\"))\n C.pfn_glTexGend = C.PFNGLTEXGEND(loader(\"glTexGend\"))\n C.pfn_glTexGendv = C.PFNGLTEXGENDV(loader(\"glTexGendv\"))\n C.pfn_glTexGenf = C.PFNGLTEXGENF(loader(\"glTexGenf\"))\n C.pfn_glTexGenfv = C.PFNGLTEXGENFV(loader(\"glTexGenfv\"))\n C.pfn_glTexGeni = C.PFNGLTEXGENI(loader(\"glTexGeni\"))\n C.pfn_glTexGeniv = C.PFNGLTEXGENIV(loader(\"glTexGeniv\"))\n C.pfn_glTexImage1D = C.PFNGLTEXIMAGE1D(loader(\"glTexImage1D\"))\n C.pfn_glTexImage2D = C.PFNGLTEXIMAGE2D(loader(\"glTexImage2D\"))\n C.pfn_glTexParameterf = C.PFNGLTEXPARAMETERF(loader(\"glTexParameterf\"))\n C.pfn_glTexParameterfv = C.PFNGLTEXPARAMETERFV(loader(\"glTexParameterfv\"))\n C.pfn_glTexParameteri = C.PFNGLTEXPARAMETERI(loader(\"glTexParameteri\"))\n C.pfn_glTexParameteriv = C.PFNGLTEXPARAMETERIV(loader(\"glTexParameteriv\"))\n C.pfn_glTranslated = C.PFNGLTRANSLATED(loader(\"glTranslated\"))\n C.pfn_glTranslatef = C.PFNGLTRANSLATEF(loader(\"glTranslatef\"))\n C.pfn_glVertex2d = C.PFNGLVERTEX2D(loader(\"glVertex2d\"))\n C.pfn_glVertex2dv = C.PFNGLVERTEX2DV(loader(\"glVertex2dv\"))\n C.pfn_glVertex2f = C.PFNGLVERTEX2F(loader(\"glVertex2f\"))\n C.pfn_glVertex2fv = C.PFNGLVERTEX2FV(loader(\"glVertex2fv\"))\n C.pfn_glVertex2i = C.PFNGLVERTEX2I(loader(\"glVertex2i\"))\n C.pfn_glVertex2iv = C.PFNGLVERTEX2IV(loader(\"glVertex2iv\"))\n C.pfn_glVertex2s = C.PFNGLVERTEX2S(loader(\"glVertex2s\"))\n C.pfn_glVertex2sv = C.PFNGLVERTEX2SV(loader(\"glVertex2sv\"))\n C.pfn_glVertex3d = C.PFNGLVERTEX3D(loader(\"glVertex3d\"))\n C.pfn_glVertex3dv = C.PFNGLVERTEX3DV(loader(\"glVertex3dv\"))\n C.pfn_glVertex3f = C.PFNGLVERTEX3F(loader(\"glVertex3f\"))\n C.pfn_glVertex3fv = C.PFNGLVERTEX3FV(loader(\"glVertex3fv\"))\n C.pfn_glVertex3i = C.PFNGLVERTEX3I(loader(\"glVertex3i\"))\n C.pfn_glVertex3iv = C.PFNGLVERTEX3IV(loader(\"glVertex3iv\"))\n C.pfn_glVertex3s = C.PFNGLVERTEX3S(loader(\"glVertex3s\"))\n C.pfn_glVertex3sv = C.PFNGLVERTEX3SV(loader(\"glVertex3sv\"))\n C.pfn_glVertex4d = C.PFNGLVERTEX4D(loader(\"glVertex4d\"))\n C.pfn_glVertex4dv = C.PFNGLVERTEX4DV(loader(\"glVertex4dv\"))\n C.pfn_glVertex4f = C.PFNGLVERTEX4F(loader(\"glVertex4f\"))\n C.pfn_glVertex4fv = C.PFNGLVERTEX4FV(loader(\"glVertex4fv\"))\n C.pfn_glVertex4i = C.PFNGLVERTEX4I(loader(\"glVertex4i\"))\n C.pfn_glVertex4iv = C.PFNGLVERTEX4IV(loader(\"glVertex4iv\"))\n C.pfn_glVertex4s = C.PFNGLVERTEX4S(loader(\"glVertex4s\"))\n C.pfn_glVertex4sv = C.PFNGLVERTEX4SV(loader(\"glVertex4sv\"))\n C.pfn_glViewport = C.PFNGLVIEWPORT(loader(\"glViewport\"))\n\n // OpenGL 1.1\n if !ver.GE(OpenGL, 1, 1) {\n return\n }\n C.pfn_glAreTexturesResident = C.PFNGLARETEXTURESRESIDENT(loader(\"glAreTexturesResident\"))\n C.pfn_glArrayElement = C.PFNGLARRAYELEMENT(loader(\"glArrayElement\"))\n C.pfn_glBindTexture = C.PFNGLBINDTEXTURE(loader(\"glBindTexture\"))\n C.pfn_glColorPointer = C.PFNGLCOLORPOINTER(loader(\"glColorPointer\"))\n C.pfn_glCopyTexImage1D = C.PFNGLCOPYTEXIMAGE1D(loader(\"glCopyTexImage1D\"))\n C.pfn_glCopyTexImage2D = C.PFNGLCOPYTEXIMAGE2D(loader(\"glCopyTexImage2D\"))\n C.pfn_glCopyTexSubImage1D = C.PFNGLCOPYTEXSUBIMAGE1D(loader(\"glCopyTexSubImage1D\"))\n C.pfn_glCopyTexSubImage2D = C.PFNGLCOPYTEXSUBIMAGE2D(loader(\"glCopyTexSubImage2D\"))\n C.pfn_glDeleteTextures = C.PFNGLDELETETEXTURES(loader(\"glDeleteTextures\"))\n C.pfn_glDisableClientState = C.PFNGLDISABLECLIENTSTATE(loader(\"glDisableClientState\"))\n C.pfn_glDrawArrays = C.PFNGLDRAWARRAYS(loader(\"glDrawArrays\"))\n C.pfn_glDrawElements = C.PFNGLDRAWELEMENTS(loader(\"glDrawElements\"))\n C.pfn_glEdgeFlagPointer = C.PFNGLEDGEFLAGPOINTER(loader(\"glEdgeFlagPointer\"))\n C.pfn_glEnableClientState = C.PFNGLENABLECLIENTSTATE(loader(\"glEnableClientState\"))\n C.pfn_glGenTextures = C.PFNGLGENTEXTURES(loader(\"glGenTextures\"))\n C.pfn_glGetPointerv = C.PFNGLGETPOINTERV(loader(\"glGetPointerv\"))\n C.pfn_glIndexPointer = C.PFNGLINDEXPOINTER(loader(\"glIndexPointer\"))\n C.pfn_glIndexub = C.PFNGLINDEXUB(loader(\"glIndexub\"))\n C.pfn_glIndexubv = C.PFNGLINDEXUBV(loader(\"glIndexubv\"))\n C.pfn_glInterleavedArrays = C.PFNGLINTERLEAVEDARRAYS(loader(\"glInterleavedArrays\"))\n C.pfn_glIsTexture = C.PFNGLISTEXTURE(loader(\"glIsTexture\"))\n C.pfn_glNormalPointer = C.PFNGLNORMALPOINTER(loader(\"glNormalPointer\"))\n C.pfn_glPolygonOffset = C.PFNGLPOLYGONOFFSET(loader(\"glPolygonOffset\"))\n C.pfn_glPopClientAttrib = C.PFNGLPOPCLIENTATTRIB(loader(\"glPopClientAttrib\"))\n C.pfn_glPrioritizeTextures = C.PFNGLPRIORITIZETEXTURES(loader(\"glPrioritizeTextures\"))\n C.pfn_glPushClientAttrib = C.PFNGLPUSHCLIENTATTRIB(loader(\"glPushClientAttrib\"))\n C.pfn_glTexCoordPointer = C.PFNGLTEXCOORDPOINTER(loader(\"glTexCoordPointer\"))\n C.pfn_glTexSubImage1D = C.PFNGLTEXSUBIMAGE1D(loader(\"glTexSubImage1D\"))\n C.pfn_glTexSubImage2D = C.PFNGLTEXSUBIMAGE2D(loader(\"glTexSubImage2D\"))\n C.pfn_glVertexPointer = C.PFNGLVERTEXPOINTER(loader(\"glVertexPointer\"))\n\n // OpenGL 1.2\n if !ver.GE(OpenGL, 1, 2) {\n return\n }\n C.pfn_glCopyTexSubImage3D = C.PFNGLCOPYTEXSUBIMAGE3D(loader(\"glCopyTexSubImage3D\"))\n C.pfn_glDrawRangeElements = C.PFNGLDRAWRANGEELEMENTS(loader(\"glDrawRangeElements\"))\n C.pfn_glTexImage3D = C.PFNGLTEXIMAGE3D(loader(\"glTexImage3D\"))\n C.pfn_glTexSubImage3D = C.PFNGLTEXSUBIMAGE3D(loader(\"glTexSubImage3D\"))\n\n // OpenGL 1.3\n if !ver.GE(OpenGL, 1, 3) {\n return\n }\n C.pfn_glActiveTexture = C.PFNGLACTIVETEXTURE(loader(\"glActiveTexture\"))\n C.pfn_glClientActiveTexture = C.PFNGLCLIENTACTIVETEXTURE(loader(\"glClientActiveTexture\"))\n C.pfn_glCompressedTexImage1D = C.PFNGLCOMPRESSEDTEXIMAGE1D(loader(\"glCompressedTexImage1D\"))\n C.pfn_glCompressedTexImage2D = C.PFNGLCOMPRESSEDTEXIMAGE2D(loader(\"glCompressedTexImage2D\"))\n C.pfn_glCompressedTexImage3D = C.PFNGLCOMPRESSEDTEXIMAGE3D(loader(\"glCompressedTexImage3D\"))\n C.pfn_glCompressedTexSubImage1D = C.PFNGLCOMPRESSEDTEXSUBIMAGE1D(loader(\"glCompressedTexSubImage1D\"))\n C.pfn_glCompressedTexSubImage2D = C.PFNGLCOMPRESSEDTEXSUBIMAGE2D(loader(\"glCompressedTexSubImage2D\"))\n C.pfn_glCompressedTexSubImage3D = C.PFNGLCOMPRESSEDTEXSUBIMAGE3D(loader(\"glCompressedTexSubImage3D\"))\n C.pfn_glGetCompressedTexImage = C.PFNGLGETCOMPRESSEDTEXIMAGE(loader(\"glGetCompressedTexImage\"))\n C.pfn_glLoadTransposeMatrixd = C.PFNGLLOADTRANSPOSEMATRIXD(loader(\"glLoadTransposeMatrixd\"))\n C.pfn_glLoadTransposeMatrixf = C.PFNGLLOADTRANSPOSEMATRIXF(loader(\"glLoadTransposeMatrixf\"))\n C.pfn_glMultTransposeMatrixd = C.PFNGLMULTTRANSPOSEMATRIXD(loader(\"glMultTransposeMatrixd\"))\n C.pfn_glMultTransposeMatrixf = C.PFNGLMULTTRANSPOSEMATRIXF(loader(\"glMultTransposeMatrixf\"))\n C.pfn_glMultiTexCoord1d = C.PFNGLMULTITEXCOORD1D(loader(\"glMultiTexCoord1d\"))\n C.pfn_glMultiTexCoord1dv = C.PFNGLMULTITEXCOORD1DV(loader(\"glMultiTexCoord1dv\"))\n C.pfn_glMultiTexCoord1f = C.PFNGLMULTITEXCOORD1F(loader(\"glMultiTexCoord1f\"))\n C.pfn_glMultiTexCoord1fv = C.PFNGLMULTITEXCOORD1FV(loader(\"glMultiTexCoord1fv\"))\n C.pfn_glMultiTexCoord1i = C.PFNGLMULTITEXCOORD1I(loader(\"glMultiTexCoord1i\"))\n C.pfn_glMultiTexCoord1iv = C.PFNGLMULTITEXCOORD1IV(loader(\"glMultiTexCoord1iv\"))\n C.pfn_glMultiTexCoord1s = C.PFNGLMULTITEXCOORD1S(loader(\"glMultiTexCoord1s\"))\n C.pfn_glMultiTexCoord1sv = C.PFNGLMULTITEXCOORD1SV(loader(\"glMultiTexCoord1sv\"))\n C.pfn_glMultiTexCoord2d = C.PFNGLMULTITEXCOORD2D(loader(\"glMultiTexCoord2d\"))\n C.pfn_glMultiTexCoord2dv = C.PFNGLMULTITEXCOORD2DV(loader(\"glMultiTexCoord2dv\"))\n C.pfn_glMultiTexCoord2f = C.PFNGLMULTITEXCOORD2F(loader(\"glMultiTexCoord2f\"))\n C.pfn_glMultiTexCoord2fv = C.PFNGLMULTITEXCOORD2FV(loader(\"glMultiTexCoord2fv\"))\n C.pfn_glMultiTexCoord2i = C.PFNGLMULTITEXCOORD2I(loader(\"glMultiTexCoord2i\"))\n C.pfn_glMultiTexCoord2iv = C.PFNGLMULTITEXCOORD2IV(loader(\"glMultiTexCoord2iv\"))\n C.pfn_glMultiTexCoord2s = C.PFNGLMULTITEXCOORD2S(loader(\"glMultiTexCoord2s\"))\n C.pfn_glMultiTexCoord2sv = C.PFNGLMULTITEXCOORD2SV(loader(\"glMultiTexCoord2sv\"))\n C.pfn_glMultiTexCoord3d = C.PFNGLMULTITEXCOORD3D(loader(\"glMultiTexCoord3d\"))\n C.pfn_glMultiTexCoord3dv = C.PFNGLMULTITEXCOORD3DV(loader(\"glMultiTexCoord3dv\"))\n C.pfn_glMultiTexCoord3f = C.PFNGLMULTITEXCOORD3F(loader(\"glMultiTexCoord3f\"))\n C.pfn_glMultiTexCoord3fv = C.PFNGLMULTITEXCOORD3FV(loader(\"glMultiTexCoord3fv\"))\n C.pfn_glMultiTexCoord3i = C.PFNGLMULTITEXCOORD3I(loader(\"glMultiTexCoord3i\"))\n C.pfn_glMultiTexCoord3iv = C.PFNGLMULTITEXCOORD3IV(loader(\"glMultiTexCoord3iv\"))\n C.pfn_glMultiTexCoord3s = C.PFNGLMULTITEXCOORD3S(loader(\"glMultiTexCoord3s\"))\n C.pfn_glMultiTexCoord3sv = C.PFNGLMULTITEXCOORD3SV(loader(\"glMultiTexCoord3sv\"))\n C.pfn_glMultiTexCoord4d = C.PFNGLMULTITEXCOORD4D(loader(\"glMultiTexCoord4d\"))\n C.pfn_glMultiTexCoord4dv = C.PFNGLMULTITEXCOORD4DV(loader(\"glMultiTexCoord4dv\"))\n C.pfn_glMultiTexCoord4f = C.PFNGLMULTITEXCOORD4F(loader(\"glMultiTexCoord4f\"))\n C.pfn_glMultiTexCoord4fv = C.PFNGLMULTITEXCOORD4FV(loader(\"glMultiTexCoord4fv\"))\n C.pfn_glMultiTexCoord4i = C.PFNGLMULTITEXCOORD4I(loader(\"glMultiTexCoord4i\"))\n C.pfn_glMultiTexCoord4iv = C.PFNGLMULTITEXCOORD4IV(loader(\"glMultiTexCoord4iv\"))\n C.pfn_glMultiTexCoord4s = C.PFNGLMULTITEXCOORD4S(loader(\"glMultiTexCoord4s\"))\n C.pfn_glMultiTexCoord4sv = C.PFNGLMULTITEXCOORD4SV(loader(\"glMultiTexCoord4sv\"))\n C.pfn_glSampleCoverage = C.PFNGLSAMPLECOVERAGE(loader(\"glSampleCoverage\"))\n\n // OpenGL 1.4\n if !ver.GE(OpenGL, 1, 4) {\n return\n }\n C.pfn_glBlendColor = C.PFNGLBLENDCOLOR(loader(\"glBlendColor\"))\n C.pfn_glBlendEquation = C.PFNGLBLENDEQUATION(loader(\"glBlendEquation\"))\n C.pfn_glBlendFuncSeparate = C.PFNGLBLENDFUNCSEPARATE(loader(\"glBlendFuncSeparate\"))\n C.pfn_glFogCoordPointer = C.PFNGLFOGCOORDPOINTER(loader(\"glFogCoordPointer\"))\n C.pfn_glFogCoordd = C.PFNGLFOGCOORDD(loader(\"glFogCoordd\"))\n C.pfn_glFogCoorddv = C.PFNGLFOGCOORDDV(loader(\"glFogCoorddv\"))\n C.pfn_glFogCoordf = C.PFNGLFOGCOORDF(loader(\"glFogCoordf\"))\n C.pfn_glFogCoordfv = C.PFNGLFOGCOORDFV(loader(\"glFogCoordfv\"))\n C.pfn_glMultiDrawArrays = C.PFNGLMULTIDRAWARRAYS(loader(\"glMultiDrawArrays\"))\n C.pfn_glMultiDrawElements = C.PFNGLMULTIDRAWELEMENTS(loader(\"glMultiDrawElements\"))\n C.pfn_glPointParameterf = C.PFNGLPOINTPARAMETERF(loader(\"glPointParameterf\"))\n C.pfn_glPointParameterfv = C.PFNGLPOINTPARAMETERFV(loader(\"glPointParameterfv\"))\n C.pfn_glPointParameteri = C.PFNGLPOINTPARAMETERI(loader(\"glPointParameteri\"))\n C.pfn_glPointParameteriv = C.PFNGLPOINTPARAMETERIV(loader(\"glPointParameteriv\"))\n C.pfn_glSecondaryColor3b = C.PFNGLSECONDARYCOLOR3B(loader(\"glSecondaryColor3b\"))\n C.pfn_glSecondaryColor3bv = C.PFNGLSECONDARYCOLOR3BV(loader(\"glSecondaryColor3bv\"))\n C.pfn_glSecondaryColor3d = C.PFNGLSECONDARYCOLOR3D(loader(\"glSecondaryColor3d\"))\n C.pfn_glSecondaryColor3dv = C.PFNGLSECONDARYCOLOR3DV(loader(\"glSecondaryColor3dv\"))\n C.pfn_glSecondaryColor3f = C.PFNGLSECONDARYCOLOR3F(loader(\"glSecondaryColor3f\"))\n C.pfn_glSecondaryColor3fv = C.PFNGLSECONDARYCOLOR3FV(loader(\"glSecondaryColor3fv\"))\n C.pfn_glSecondaryColor3i = C.PFNGLSECONDARYCOLOR3I(loader(\"glSecondaryColor3i\"))\n C.pfn_glSecondaryColor3iv = C.PFNGLSECONDARYCOLOR3IV(loader(\"glSecondaryColor3iv\"))\n C.pfn_glSecondaryColor3s = C.PFNGLSECONDARYCOLOR3S(loader(\"glSecondaryColor3s\"))\n C.pfn_glSecondaryColor3sv = C.PFNGLSECONDARYCOLOR3SV(loader(\"glSecondaryColor3sv\"))\n C.pfn_glSecondaryColor3ub = C.PFNGLSECONDARYCOLOR3UB(loader(\"glSecondaryColor3ub\"))\n C.pfn_glSecondaryColor3ubv = C.PFNGLSECONDARYCOLOR3UBV(loader(\"glSecondaryColor3ubv\"))\n C.pfn_glSecondaryColor3ui = C.PFNGLSECONDARYCOLOR3UI(loader(\"glSecondaryColor3ui\"))\n C.pfn_glSecondaryColor3uiv = C.PFNGLSECONDARYCOLOR3UIV(loader(\"glSecondaryColor3uiv\"))\n C.pfn_glSecondaryColor3us = C.PFNGLSECONDARYCOLOR3US(loader(\"glSecondaryColor3us\"))\n C.pfn_glSecondaryColor3usv = C.PFNGLSECONDARYCOLOR3USV(loader(\"glSecondaryColor3usv\"))\n C.pfn_glSecondaryColorPointer = C.PFNGLSECONDARYCOLORPOINTER(loader(\"glSecondaryColorPointer\"))\n C.pfn_glWindowPos2d = C.PFNGLWINDOWPOS2D(loader(\"glWindowPos2d\"))\n C.pfn_glWindowPos2dv = C.PFNGLWINDOWPOS2DV(loader(\"glWindowPos2dv\"))\n C.pfn_glWindowPos2f = C.PFNGLWINDOWPOS2F(loader(\"glWindowPos2f\"))\n C.pfn_glWindowPos2fv = C.PFNGLWINDOWPOS2FV(loader(\"glWindowPos2fv\"))\n C.pfn_glWindowPos2i = C.PFNGLWINDOWPOS2I(loader(\"glWindowPos2i\"))\n C.pfn_glWindowPos2iv = C.PFNGLWINDOWPOS2IV(loader(\"glWindowPos2iv\"))\n C.pfn_glWindowPos2s = C.PFNGLWINDOWPOS2S(loader(\"glWindowPos2s\"))\n C.pfn_glWindowPos2sv = C.PFNGLWINDOWPOS2SV(loader(\"glWindowPos2sv\"))\n C.pfn_glWindowPos3d = C.PFNGLWINDOWPOS3D(loader(\"glWindowPos3d\"))\n C.pfn_glWindowPos3dv = C.PFNGLWINDOWPOS3DV(loader(\"glWindowPos3dv\"))\n C.pfn_glWindowPos3f = C.PFNGLWINDOWPOS3F(loader(\"glWindowPos3f\"))\n C.pfn_glWindowPos3fv = C.PFNGLWINDOWPOS3FV(loader(\"glWindowPos3fv\"))\n C.pfn_glWindowPos3i = C.PFNGLWINDOWPOS3I(loader(\"glWindowPos3i\"))\n C.pfn_glWindowPos3iv = C.PFNGLWINDOWPOS3IV(loader(\"glWindowPos3iv\"))\n C.pfn_glWindowPos3s = C.PFNGLWINDOWPOS3S(loader(\"glWindowPos3s\"))\n C.pfn_glWindowPos3sv = C.PFNGLWINDOWPOS3SV(loader(\"glWindowPos3sv\"))\n\n // OpenGL 1.5\n if !ver.GE(OpenGL, 1, 5) {\n return\n }\n C.pfn_glBeginQuery = C.PFNGLBEGINQUERY(loader(\"glBeginQuery\"))\n C.pfn_glBindBuffer = C.PFNGLBINDBUFFER(loader(\"glBindBuffer\"))\n C.pfn_glBufferData = C.PFNGLBUFFERDATA(loader(\"glBufferData\"))\n C.pfn_glBufferSubData = C.PFNGLBUFFERSUBDATA(loader(\"glBufferSubData\"))\n C.pfn_glDeleteBuffers = C.PFNGLDELETEBUFFERS(loader(\"glDeleteBuffers\"))\n C.pfn_glDeleteQueries = C.PFNGLDELETEQUERIES(loader(\"glDeleteQueries\"))\n C.pfn_glEndQuery = C.PFNGLENDQUERY(loader(\"glEndQuery\"))\n C.pfn_glGenBuffers = C.PFNGLGENBUFFERS(loader(\"glGenBuffers\"))\n C.pfn_glGenQueries = C.PFNGLGENQUERIES(loader(\"glGenQueries\"))\n C.pfn_glGetBufferParameteriv = C.PFNGLGETBUFFERPARAMETERIV(loader(\"glGetBufferParameteriv\"))\n C.pfn_glGetBufferPointerv = C.PFNGLGETBUFFERPOINTERV(loader(\"glGetBufferPointerv\"))\n C.pfn_glGetBufferSubData = C.PFNGLGETBUFFERSUBDATA(loader(\"glGetBufferSubData\"))\n C.pfn_glGetQueryObjectiv = C.PFNGLGETQUERYOBJECTIV(loader(\"glGetQueryObjectiv\"))\n C.pfn_glGetQueryObjectuiv = C.PFNGLGETQUERYOBJECTUIV(loader(\"glGetQueryObjectuiv\"))\n C.pfn_glGetQueryiv = C.PFNGLGETQUERYIV(loader(\"glGetQueryiv\"))\n C.pfn_glIsBuffer = C.PFNGLISBUFFER(loader(\"glIsBuffer\"))\n C.pfn_glIsQuery = C.PFNGLISQUERY(loader(\"glIsQuery\"))\n C.pfn_glMapBuffer = C.PFNGLMAPBUFFER(loader(\"glMapBuffer\"))\n C.pfn_glUnmapBuffer = C.PFNGLUNMAPBUFFER(loader(\"glUnmapBuffer\"))\n\n // OpenGL 2.0\n if !ver.GE(OpenGL, 2, 0) {\n return\n }\n C.pfn_glAttachShader = C.PFNGLATTACHSHADER(loader(\"glAttachShader\"))\n C.pfn_glBindAttribLocation = C.PFNGLBINDATTRIBLOCATION(loader(\"glBindAttribLocation\"))\n C.pfn_glBlendEquationSeparate = C.PFNGLBLENDEQUATIONSEPARATE(loader(\"glBlendEquationSeparate\"))\n C.pfn_glCompileShader = C.PFNGLCOMPILESHADER(loader(\"glCompileShader\"))\n C.pfn_glCreateProgram = C.PFNGLCREATEPROGRAM(loader(\"glCreateProgram\"))\n C.pfn_glCreateShader = C.PFNGLCREATESHADER(loader(\"glCreateShader\"))\n C.pfn_glDeleteProgram = C.PFNGLDELETEPROGRAM(loader(\"glDeleteProgram\"))\n C.pfn_glDeleteShader = C.PFNGLDELETESHADER(loader(\"glDeleteShader\"))\n C.pfn_glDetachShader = C.PFNGLDETACHSHADER(loader(\"glDetachShader\"))\n C.pfn_glDisableVertexAttribArray = C.PFNGLDISABLEVERTEXATTRIBARRAY(loader(\"glDisableVertexAttribArray\"))\n C.pfn_glDrawBuffers = C.PFNGLDRAWBUFFERS(loader(\"glDrawBuffers\"))\n C.pfn_glEnableVertexAttribArray = C.PFNGLENABLEVERTEXATTRIBARRAY(loader(\"glEnableVertexAttribArray\"))\n C.pfn_glGetActiveAttrib = C.PFNGLGETACTIVEATTRIB(loader(\"glGetActiveAttrib\"))\n C.pfn_glGetActiveUniform = C.PFNGLGETACTIVEUNIFORM(loader(\"glGetActiveUniform\"))\n C.pfn_glGetAttachedShaders = C.PFNGLGETATTACHEDSHADERS(loader(\"glGetAttachedShaders\"))\n C.pfn_glGetAttribLocation = C.PFNGLGETATTRIBLOCATION(loader(\"glGetAttribLocation\"))\n C.pfn_glGetProgramInfoLog = C.PFNGLGETPROGRAMINFOLOG(loader(\"glGetProgramInfoLog\"))\n C.pfn_glGetProgramiv = C.PFNGLGETPROGRAMIV(loader(\"glGetProgramiv\"))\n C.pfn_glGetShaderInfoLog = C.PFNGLGETSHADERINFOLOG(loader(\"glGetShaderInfoLog\"))\n C.pfn_glGetShaderSource = C.PFNGLGETSHADERSOURCE(loader(\"glGetShaderSource\"))\n C.pfn_glGetShaderiv = C.PFNGLGETSHADERIV(loader(\"glGetShaderiv\"))\n C.pfn_glGetUniformLocation = C.PFNGLGETUNIFORMLOCATION(loader(\"glGetUniformLocation\"))\n C.pfn_glGetUniformfv = C.PFNGLGETUNIFORMFV(loader(\"glGetUniformfv\"))\n C.pfn_glGetUniformiv = C.PFNGLGETUNIFORMIV(loader(\"glGetUniformiv\"))\n C.pfn_glGetVertexAttribPointerv = C.PFNGLGETVERTEXATTRIBPOINTERV(loader(\"glGetVertexAttribPointerv\"))\n C.pfn_glGetVertexAttribdv = C.PFNGLGETVERTEXATTRIBDV(loader(\"glGetVertexAttribdv\"))\n C.pfn_glGetVertexAttribfv = C.PFNGLGETVERTEXATTRIBFV(loader(\"glGetVertexAttribfv\"))\n C.pfn_glGetVertexAttribiv = C.PFNGLGETVERTEXATTRIBIV(loader(\"glGetVertexAttribiv\"))\n C.pfn_glIsProgram = C.PFNGLISPROGRAM(loader(\"glIsProgram\"))\n C.pfn_glIsShader = C.PFNGLISSHADER(loader(\"glIsShader\"))\n C.pfn_glLinkProgram = C.PFNGLLINKPROGRAM(loader(\"glLinkProgram\"))\n C.pfn_glShaderSource = C.PFNGLSHADERSOURCE(loader(\"glShaderSource\"))\n C.pfn_glStencilFuncSeparate = C.PFNGLSTENCILFUNCSEPARATE(loader(\"glStencilFuncSeparate\"))\n C.pfn_glStencilMaskSeparate = C.PFNGLSTENCILMASKSEPARATE(loader(\"glStencilMaskSeparate\"))\n C.pfn_glStencilOpSeparate = C.PFNGLSTENCILOPSEPARATE(loader(\"glStencilOpSeparate\"))\n C.pfn_glUniform1f = C.PFNGLUNIFORM1F(loader(\"glUniform1f\"))\n C.pfn_glUniform1fv = C.PFNGLUNIFORM1FV(loader(\"glUniform1fv\"))\n C.pfn_glUniform1i = C.PFNGLUNIFORM1I(loader(\"glUniform1i\"))\n C.pfn_glUniform1iv = C.PFNGLUNIFORM1IV(loader(\"glUniform1iv\"))\n C.pfn_glUniform2f = C.PFNGLUNIFORM2F(loader(\"glUniform2f\"))\n C.pfn_glUniform2fv = C.PFNGLUNIFORM2FV(loader(\"glUniform2fv\"))\n C.pfn_glUniform2i = C.PFNGLUNIFORM2I(loader(\"glUniform2i\"))\n C.pfn_glUniform2iv = C.PFNGLUNIFORM2IV(loader(\"glUniform2iv\"))\n C.pfn_glUniform3f = C.PFNGLUNIFORM3F(loader(\"glUniform3f\"))\n C.pfn_glUniform3fv = C.PFNGLUNIFORM3FV(loader(\"glUniform3fv\"))\n C.pfn_glUniform3i = C.PFNGLUNIFORM3I(loader(\"glUniform3i\"))\n C.pfn_glUniform3iv = C.PFNGLUNIFORM3IV(loader(\"glUniform3iv\"))\n C.pfn_glUniform4f = C.PFNGLUNIFORM4F(loader(\"glUniform4f\"))\n C.pfn_glUniform4fv = C.PFNGLUNIFORM4FV(loader(\"glUniform4fv\"))\n C.pfn_glUniform4i = C.PFNGLUNIFORM4I(loader(\"glUniform4i\"))\n C.pfn_glUniform4iv = C.PFNGLUNIFORM4IV(loader(\"glUniform4iv\"))\n C.pfn_glUniformMatrix2fv = C.PFNGLUNIFORMMATRIX2FV(loader(\"glUniformMatrix2fv\"))\n C.pfn_glUniformMatrix3fv = C.PFNGLUNIFORMMATRIX3FV(loader(\"glUniformMatrix3fv\"))\n C.pfn_glUniformMatrix4fv = C.PFNGLUNIFORMMATRIX4FV(loader(\"glUniformMatrix4fv\"))\n C.pfn_glUseProgram = C.PFNGLUSEPROGRAM(loader(\"glUseProgram\"))\n C.pfn_glValidateProgram = C.PFNGLVALIDATEPROGRAM(loader(\"glValidateProgram\"))\n C.pfn_glVertexAttrib1d = C.PFNGLVERTEXATTRIB1D(loader(\"glVertexAttrib1d\"))\n C.pfn_glVertexAttrib1dv = C.PFNGLVERTEXATTRIB1DV(loader(\"glVertexAttrib1dv\"))\n C.pfn_glVertexAttrib1f = C.PFNGLVERTEXATTRIB1F(loader(\"glVertexAttrib1f\"))\n C.pfn_glVertexAttrib1fv = C.PFNGLVERTEXATTRIB1FV(loader(\"glVertexAttrib1fv\"))\n C.pfn_glVertexAttrib1s = C.PFNGLVERTEXATTRIB1S(loader(\"glVertexAttrib1s\"))\n C.pfn_glVertexAttrib1sv = C.PFNGLVERTEXATTRIB1SV(loader(\"glVertexAttrib1sv\"))\n C.pfn_glVertexAttrib2d = C.PFNGLVERTEXATTRIB2D(loader(\"glVertexAttrib2d\"))\n C.pfn_glVertexAttrib2dv = C.PFNGLVERTEXATTRIB2DV(loader(\"glVertexAttrib2dv\"))\n C.pfn_glVertexAttrib2f = C.PFNGLVERTEXATTRIB2F(loader(\"glVertexAttrib2f\"))\n C.pfn_glVertexAttrib2fv = C.PFNGLVERTEXATTRIB2FV(loader(\"glVertexAttrib2fv\"))\n C.pfn_glVertexAttrib2s = C.PFNGLVERTEXATTRIB2S(loader(\"glVertexAttrib2s\"))\n C.pfn_glVertexAttrib2sv = C.PFNGLVERTEXATTRIB2SV(loader(\"glVertexAttrib2sv\"))\n C.pfn_glVertexAttrib3d = C.PFNGLVERTEXATTRIB3D(loader(\"glVertexAttrib3d\"))\n C.pfn_glVertexAttrib3dv = C.PFNGLVERTEXATTRIB3DV(loader(\"glVertexAttrib3dv\"))\n C.pfn_glVertexAttrib3f = C.PFNGLVERTEXATTRIB3F(loader(\"glVertexAttrib3f\"))\n C.pfn_glVertexAttrib3fv = C.PFNGLVERTEXATTRIB3FV(loader(\"glVertexAttrib3fv\"))\n C.pfn_glVertexAttrib3s = C.PFNGLVERTEXATTRIB3S(loader(\"glVertexAttrib3s\"))\n C.pfn_glVertexAttrib3sv = C.PFNGLVERTEXATTRIB3SV(loader(\"glVertexAttrib3sv\"))\n C.pfn_glVertexAttrib4Nbv = C.PFNGLVERTEXATTRIB4NBV(loader(\"glVertexAttrib4Nbv\"))\n C.pfn_glVertexAttrib4Niv = C.PFNGLVERTEXATTRIB4NIV(loader(\"glVertexAttrib4Niv\"))\n C.pfn_glVertexAttrib4Nsv = C.PFNGLVERTEXATTRIB4NSV(loader(\"glVertexAttrib4Nsv\"))\n C.pfn_glVertexAttrib4Nub = C.PFNGLVERTEXATTRIB4NUB(loader(\"glVertexAttrib4Nub\"))\n C.pfn_glVertexAttrib4Nubv = C.PFNGLVERTEXATTRIB4NUBV(loader(\"glVertexAttrib4Nubv\"))\n C.pfn_glVertexAttrib4Nuiv = C.PFNGLVERTEXATTRIB4NUIV(loader(\"glVertexAttrib4Nuiv\"))\n C.pfn_glVertexAttrib4Nusv = C.PFNGLVERTEXATTRIB4NUSV(loader(\"glVertexAttrib4Nusv\"))\n C.pfn_glVertexAttrib4bv = C.PFNGLVERTEXATTRIB4BV(loader(\"glVertexAttrib4bv\"))\n C.pfn_glVertexAttrib4d = C.PFNGLVERTEXATTRIB4D(loader(\"glVertexAttrib4d\"))\n C.pfn_glVertexAttrib4dv = C.PFNGLVERTEXATTRIB4DV(loader(\"glVertexAttrib4dv\"))\n C.pfn_glVertexAttrib4f = C.PFNGLVERTEXATTRIB4F(loader(\"glVertexAttrib4f\"))\n C.pfn_glVertexAttrib4fv = C.PFNGLVERTEXATTRIB4FV(loader(\"glVertexAttrib4fv\"))\n C.pfn_glVertexAttrib4iv = C.PFNGLVERTEXATTRIB4IV(loader(\"glVertexAttrib4iv\"))\n C.pfn_glVertexAttrib4s = C.PFNGLVERTEXATTRIB4S(loader(\"glVertexAttrib4s\"))\n C.pfn_glVertexAttrib4sv = C.PFNGLVERTEXATTRIB4SV(loader(\"glVertexAttrib4sv\"))\n C.pfn_glVertexAttrib4ubv = C.PFNGLVERTEXATTRIB4UBV(loader(\"glVertexAttrib4ubv\"))\n C.pfn_glVertexAttrib4uiv = C.PFNGLVERTEXATTRIB4UIV(loader(\"glVertexAttrib4uiv\"))\n C.pfn_glVertexAttrib4usv = C.PFNGLVERTEXATTRIB4USV(loader(\"glVertexAttrib4usv\"))\n C.pfn_glVertexAttribPointer = C.PFNGLVERTEXATTRIBPOINTER(loader(\"glVertexAttribPointer\"))\n\n // OpenGL 2.1\n if !ver.GE(OpenGL, 2, 1) {\n return\n }\n C.pfn_glUniformMatrix2x3fv = C.PFNGLUNIFORMMATRIX2X3FV(loader(\"glUniformMatrix2x3fv\"))\n C.pfn_glUniformMatrix2x4fv = C.PFNGLUNIFORMMATRIX2X4FV(loader(\"glUniformMatrix2x4fv\"))\n C.pfn_glUniformMatrix3x2fv = C.PFNGLUNIFORMMATRIX3X2FV(loader(\"glUniformMatrix3x2fv\"))\n C.pfn_glUniformMatrix3x4fv = C.PFNGLUNIFORMMATRIX3X4FV(loader(\"glUniformMatrix3x4fv\"))\n C.pfn_glUniformMatrix4x2fv = C.PFNGLUNIFORMMATRIX4X2FV(loader(\"glUniformMatrix4x2fv\"))\n C.pfn_glUniformMatrix4x3fv = C.PFNGLUNIFORMMATRIX4X3FV(loader(\"glUniformMatrix4x3fv\"))\n}", "func GetBufferParameteri64v(target uint32, pname uint32, params *int64) {\n\tC.glowGetBufferParameteri64v(gpGetBufferParameteri64v, (C.GLenum)(target), (C.GLenum)(pname), (*C.GLint64)(unsafe.Pointer(params)))\n}", "func GetBufferParameteri64v(target uint32, pname uint32, params *int64) {\n\tC.glowGetBufferParameteri64v(gpGetBufferParameteri64v, (C.GLenum)(target), (C.GLenum)(pname), (*C.GLint64)(unsafe.Pointer(params)))\n}", "func (b *XMobileBackend) GetImageData(x, y, w, h int) *image.RGBA {\n\tb.activate()\n\n\tif x < 0 {\n\t\tw += x\n\t\tx = 0\n\t}\n\tif y < 0 {\n\t\th += y\n\t\ty = 0\n\t}\n\tif w > b.w {\n\t\tw = b.w\n\t}\n\tif h > b.h {\n\t\th = b.h\n\t}\n\n\tvar vp [4]int32\n\tb.glctx.GetIntegerv(vp[:], gl.VIEWPORT)\n\n\tsize := int(vp[2] * vp[3] * 3)\n\tif len(b.imageBuf) < size {\n\t\tb.imageBuf = make([]byte, size)\n\t}\n\tb.glctx.ReadPixels(b.imageBuf[0:], int(vp[0]), int(vp[1]), int(vp[2]), int(vp[3]), gl.RGB, gl.UNSIGNED_BYTE)\n\n\trgba := image.NewRGBA(image.Rect(x, y, x+w, y+h))\n\tfor cy := y; cy < y+h; cy++ {\n\t\tbp := (int(vp[3])-h+cy)*int(vp[2])*3 + x*3\n\t\tfor cx := x; cx < x+w; cx++ {\n\t\t\trgba.SetRGBA(cx, y+h-1-cy, color.RGBA{R: b.imageBuf[bp], G: b.imageBuf[bp+1], B: b.imageBuf[bp+2], A: 255})\n\t\t\tbp += 3\n\t\t}\n\t}\n\treturn rgba\n}", "func imageToJsValue(img image.Image) (*js.Value, error) {\n\tbuf := new(bytes.Buffer)\n\terr := jpeg.Encode(buf, img, nil)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\n\timgBytes := buf.Bytes()\n\tret := js.Global().Get(\"Uint8Array\").New(len(imgBytes))\n\tjs.CopyBytesToJS(ret, imgBytes)\n\treturn &ret, nil\n}", "func GetTexParameteriv(dst []int32, target, pname Enum) {\n\tgl.GetTexParameteriv(uint32(target), uint32(pname), &dst[0])\n}", "func getImageName(w http.ResponseWriter, r *http.Request, parms martini.Params) {\r\n\tid, _ := strconv.ParseInt(parms[\"id\"], 10, 64)\r\n\tvar img CRImage\r\n\timage := img.Querylog(id)\r\n\t// name := image.ImageName + \":\" + strconv.Itoa(image.Tag)\r\n\t// log.Println(name)\r\n\t// fullName := imageFullName{fullname: name}\r\n\tif err := json.NewEncoder(w).Encode(image); err != nil {\r\n\t\tlogger.Error(err)\r\n\t\thttp.Error(w, err.Error(), http.StatusInternalServerError)\r\n\t}\r\n}", "func TexImage3D(target uint32, level int32, internalformat int32, width int32, height int32, depth int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexImage3D(gpTexImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func GetBufferParameteriv(target uint32, pname uint32, params *int32) {\n C.glowGetBufferParameteriv(gpGetBufferParameteriv, (C.GLenum)(target), (C.GLenum)(pname), (*C.GLint)(unsafe.Pointer(params)))\n}", "func EGLImageTargetTexStorageEXT(target uint32, image unsafe.Pointer, attrib_list *int32) {\n\tsyscall.Syscall(gpEGLImageTargetTexStorageEXT, 3, uintptr(target), uintptr(image), uintptr(unsafe.Pointer(attrib_list)))\n}", "func GetRenderbufferParameteri(target, pname Enum) int {\n\tlog.Println(\"GetRenderbufferParameteri: not yet tested (TODO: remove this after it's confirmed to work. Your feedback is welcome.)\")\n\tvar result int32\n\tgl.GetRenderbufferParameteriv(uint32(target), uint32(pname), &result)\n\treturn int(result)\n}", "func FramebufferParameteri(target uint32, pname uint32, param int32) {\n\tC.glowFramebufferParameteri(gpFramebufferParameteri, (C.GLenum)(target), (C.GLenum)(pname), (C.GLint)(param))\n}", "func FramebufferParameteri(target uint32, pname uint32, param int32) {\n\tC.glowFramebufferParameteri(gpFramebufferParameteri, (C.GLenum)(target), (C.GLenum)(pname), (C.GLint)(param))\n}", "func (imageService Service) ReserveImage (uploadParameters UploadParameters, hypervisor string, mode string) (ID string, Status string, err error) {\n\taddImageContainer := glanceAddImageResponse {}\n\theaders := make( []string, 10 )\n\n\ti := 0\n\theaders[i] = \"x-image-meta-name^\" + uploadParameters.Name\n\ti++\n\theaders[i] = \"x-image-meta-disk_format^\" + uploadParameters.DiskFormat\n\ti++\n\theaders[i] = \"x-image-meta-container_format^\" + uploadParameters.ContainerFormat\n\ti++\n\n\theaders[i] = \"x-image-meta-property-hypervisor_type^\" + hypervisor\n\ti++\n\n\theaders[i] = \"x-image-meta-property-vm_mode^\" + mode\n\ti++\n\n\tif uploadParameters.CopyFromUrl != \"\" {\n\t\theaders[i] = \"x-glance-api-copy-from^\" + uploadParameters.CopyFromUrl\n\t\ti++\n\t}\n\n\tif uploadParameters.Owner != \"\" {\n\t\theaders[i] = \"x-glance-meta-owner^\" + uploadParameters.Owner \n\t\ti++\n\t}\n\n\tif uploadParameters.IsPublic {\n\t\theaders[i] = \"x-image-meta-is_public^true\"\n\t\ti++\n\t}\n\n\tif uploadParameters.MinRam != 0 {\n\t\theaders[i] = \"x-image-meta-min_ram^\" + fmt.Sprintf(\"%d\", uploadParameters.MinRam)\n\t\ti++\n\t}\n\n\tif uploadParameters.MinDisk != 0 {\n\t\theaders[i] = \"x-image-meta-min_disk^\" + fmt.Sprintf(\"%d\", uploadParameters.MinDisk)\n\t\ti++\n\t}\n\n\turl := strings.TrimSuffix(imageService.URL, \"/\") + \"/images\"\n\terr = misc.PostHeader(url, imageService.TokenID, imageService.Client, headers, &addImageContainer)\n\tif err != nil {\n\t\treturn \"\", \"\", err\n\t}\n\n\tID = addImageContainer.Image.ID\n\tStatus = addImageContainer.Image.Status\n\n\treturn \n}", "func Image(ctx *gin.Context) {\n\n\tvar body v1r.ImagePayload\n\terr := ctx.Bind(&body)\n\tif err != nil {\n\t\tctx.JSON(http.StatusBadRequest, gin.H{\n\t\t\t\"Error\": err.Error(),\n\t\t})\n\t\tctx.Abort()\n\t\treturn\n\t}\n\n\tfile, header, err := ctx.Request.FormFile(\"file\")\n\tif err != nil {\n\t\tctx.JSON(http.StatusBadRequest, gin.H{\n\t\t\t\"Error\": err.Error(),\n\t\t})\n\t\tctx.Abort()\n\t\treturn\n\t}\n\n\tif header.Size > SIZE {\n\t\tctx.JSON(http.StatusBadRequest, gin.H{\n\t\t\t\"Error\": \"file size should be less than 5MB\",\n\t\t})\n\t\tctx.Abort()\n\t\treturn\n\t}\n\n\tbuff := make([]byte, 512) // see http://golang.org/pkg/net/http/#DetectContentType\n\t_, _ = file.Read(buff)\n\tfileType := http.DetectContentType(buff)\n\n\tre, _ := regexp.Compile(fileType)\n\tmatched := re.FindString(\"image/png image/jpeg\")\n\tif matched == \"\" {\n\t\tctx.JSON(http.StatusBadRequest, gin.H{\n\t\t\t\"Error\": \"Invalid filetype, must be jpeg or png.\",\n\t\t})\n\t\tctx.Abort()\n\t\treturn\n\t}\n\n\tctxData, _ := ctx.Get(\"client_name\")\n\tclient_name := fmt.Sprint(ctxData)\n\n\tuuid, err := v1s.ImageUpload(client_name, file, header, body)\n\tif err != nil {\n\t\tctx.JSON(http.StatusBadRequest, gin.H{\n\t\t\t\"Error\": err.Error(),\n\t\t})\n\t\tctx.Abort()\n\t\treturn\n\t}\n\n\tctx.JSON(http.StatusOK, gin.H{\n\t\t\"imageID\": uuid,\n\t})\n}", "func (debugging *debuggingOpenGL) TexParameteri(target uint32, pname uint32, param int32) {\n\tdebugging.recordEntry(\"TexParameteri\", target, pname, param)\n\tdebugging.gl.TexParameteri(target, pname, param)\n\tdebugging.recordExit(\"TexParameteri\")\n}", "func GetTextureImage(texture uint32, level int32, format uint32, xtype uint32, bufSize int32, pixels unsafe.Pointer) {\n\tsyscall.Syscall6(gpGetTextureImage, 6, uintptr(texture), uintptr(level), uintptr(format), uintptr(xtype), uintptr(bufSize), uintptr(pixels))\n}", "func Uniform2fv(location int32, count int32, value *float32) {\n C.glowUniform2fv(gpUniform2fv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func imgLed(camera int, mode int) int {\n\tlog.Printf(\"imgLed camera:%d mode:%d\", camera, mode)\n\tvar f = mod.NewProc(\"img_led\")\n\tret, _, _ := f.Call(uintptr(camera), uintptr(mode))\n\treturn int(ret) // retval is cameraID\n}", "func BufferData(target uint32, size int, data unsafe.Pointer, usage uint32) {\n C.glowBufferData(gpBufferData, (C.GLenum)(target), (C.GLsizeiptr)(size), data, (C.GLenum)(usage))\n}", "func checkImage(L *lua.LState) *common.Entity {\n\tud := L.CheckUserData(1)\n\tif v, ok := ud.Value.(*common.Entity); ok {\n\t\treturn v\n\t}\n\tL.ArgError(1, \"image expected\")\n\treturn nil\n}", "func ReleaseTexImageARB(hPbuffer unsafe.Pointer, iBuffer unsafe.Pointer) unsafe.Pointer {\n\tret, _, _ := syscall.Syscall(gpReleaseTexImageARB, 2, uintptr(hPbuffer), uintptr(iBuffer), 0)\n\treturn (unsafe.Pointer)(ret)\n}", "func (s *SpendPacket) Image() []byte {\n\tcalltype := make([]byte, 8)\n\tbinary.BigEndian.PutUint32(calltype, uint32(s.CallType))\n\th := sha256.Sum256(append(calltype, s.Token...))\n\treturn h[:]\n}", "func handler_image(w http.ResponseWriter, r *http.Request) {\n\tgetImage(w, num) // fetch the base64 encoded png image\n}", "func BindTexImageARB(hPbuffer unsafe.Pointer, iBuffer unsafe.Pointer) unsafe.Pointer {\n\tret, _, _ := syscall.Syscall(gpBindTexImageARB, 2, uintptr(hPbuffer), uintptr(iBuffer), 0)\n\treturn (unsafe.Pointer)(ret)\n}", "func linearImage(srcim image.Image, gamma float64) *image.NRGBA64 {\n\tdstim := image.NewNRGBA64(image.Rectangle{\n\t\tMax: image.Point{\n\t\t\tX: srcim.Bounds().Dx(),\n\t\t\tY: srcim.Bounds().Dy(),\n\t\t},\n\t})\n\tvar dsty int\n\tfor srcy := srcim.Bounds().Min.Y; srcy < srcim.Bounds().Max.Y; srcy++ {\n\t\tvar dstx int\n\t\tfor srcx := srcim.Bounds().Min.X; srcx < srcim.Bounds().Max.X; srcx++ {\n\t\t\tnrgba64 := color.NRGBA64Model.Convert(srcim.At(srcx, srcy)).(color.NRGBA64)\n\t\t\tnrgba64.R = uint16(nrgba64Max * math.Pow(float64(nrgba64.R)/nrgba64Max, gamma))\n\t\t\tnrgba64.G = uint16(nrgba64Max * math.Pow(float64(nrgba64.G)/nrgba64Max, gamma))\n\t\t\tnrgba64.B = uint16(nrgba64Max * math.Pow(float64(nrgba64.B)/nrgba64Max, gamma))\n\t\t\t// Alpha is not affected\n\t\t\tdstim.SetNRGBA64(dstx, dsty, nrgba64)\n\t\t\tdstx++\n\t\t}\n\t\tdsty++\n\t}\n\treturn dstim\n}", "func GetNamedRenderbufferParameteriv(renderbuffer uint32, pname uint32, params *int32) {\n\tC.glowGetNamedRenderbufferParameteriv(gpGetNamedRenderbufferParameteriv, (C.GLuint)(renderbuffer), (C.GLenum)(pname), (*C.GLint)(unsafe.Pointer(params)))\n}", "func GetNamedRenderbufferParameteriv(renderbuffer uint32, pname uint32, params *int32) {\n\tC.glowGetNamedRenderbufferParameteriv(gpGetNamedRenderbufferParameteriv, (C.GLuint)(renderbuffer), (C.GLenum)(pname), (*C.GLint)(unsafe.Pointer(params)))\n}", "func (self *Graphics) GenerateTextureI(args ...interface{}) *Texture{\n return &Texture{self.Object.Call(\"generateTexture\", args)}\n}", "func createImage(w, h int) image.Image {\n\t// create a RGBA image from the sensor\n\tpixels := image.NewRGBA(image.Rect(0, 0, w, h))\n\tn := 0\n\tfor _, i := range grid {\n\t\tcolor := colors[getColorIndex(i)]\n\t\tpixels.Pix[n] = getR(color)\n\t\tpixels.Pix[n+1] = getG(color)\n\t\tpixels.Pix[n+2] = getB(color)\n\t\tpixels.Pix[n+3] = 0xFF // we don't need to use this\n\t\tn = n + 4\n\t}\n\tdest := resize.Resize(360, 0, pixels, resize.Lanczos3)\n\treturn dest\n}", "func (self *GameObjectCreator) RenderTexture1O(width int) *RenderTexture{\n return &RenderTexture{self.Object.Call(\"renderTexture\", width)}\n}", "func Image(asset_path string, width, height int) ([]uint32, error) {\n pil := find(asset_path)\n if pil == nil { return nil, os.ErrNotExist }\n var imass ImageAsset\n imass, ok := pil.asset.(ImageAsset)\n if !ok { return nil, ErrAssetType }\n return imass.Render(width,height)\n}", "func (b *GoGLBackendOffscreen) AsImage() backendbase.Image {\n\treturn &b.offscrImg\n}", "func GetBufferParameteri(target, pname Enum) int {\n\tvar params int32\n\tgl.GetBufferParameteriv(uint32(target), uint32(pname), &params)\n\treturn int(params)\n}", "func (a *ImageApiService) GetGenreImage(ctx _context.Context, name string, imageType ImageType, imageIndex int32, localVarOptionals *GetGenreImageOpts) (*os.File, *_nethttp.Response, error) {\n\tvar (\n\t\tlocalVarHTTPMethod = _nethttp.MethodGet\n\t\tlocalVarPostBody interface{}\n\t\tlocalVarFormFileName string\n\t\tlocalVarFileName string\n\t\tlocalVarFileBytes []byte\n\t\tlocalVarReturnValue *os.File\n\t)\n\n\t// create path and map variables\n\tlocalVarPath := a.client.cfg.BasePath + \"/Genres/{name}/Images/{imageType}/{imageIndex}\"\n\tlocalVarPath = strings.Replace(localVarPath, \"{\"+\"name\"+\"}\", _neturl.QueryEscape(parameterToString(name, \"\")) , -1)\n\n\tlocalVarPath = strings.Replace(localVarPath, \"{\"+\"imageType\"+\"}\", _neturl.QueryEscape(parameterToString(imageType, \"\")) , -1)\n\n\tlocalVarPath = strings.Replace(localVarPath, \"{\"+\"imageIndex\"+\"}\", _neturl.QueryEscape(parameterToString(imageIndex, \"\")) , -1)\n\n\tlocalVarHeaderParams := make(map[string]string)\n\tlocalVarQueryParams := _neturl.Values{}\n\tlocalVarFormParams := _neturl.Values{}\n\n\tif localVarOptionals != nil && localVarOptionals.Tag.IsSet() {\n\t\tlocalVarQueryParams.Add(\"tag\", parameterToString(localVarOptionals.Tag.Value(), \"\"))\n\t}\n\tif localVarOptionals != nil && localVarOptionals.Format.IsSet() {\n\t\tlocalVarQueryParams.Add(\"format\", parameterToString(localVarOptionals.Format.Value(), \"\"))\n\t}\n\tif localVarOptionals != nil && localVarOptionals.MaxWidth.IsSet() {\n\t\tlocalVarQueryParams.Add(\"maxWidth\", parameterToString(localVarOptionals.MaxWidth.Value(), \"\"))\n\t}\n\tif localVarOptionals != nil && localVarOptionals.MaxHeight.IsSet() {\n\t\tlocalVarQueryParams.Add(\"maxHeight\", parameterToString(localVarOptionals.MaxHeight.Value(), \"\"))\n\t}\n\tif localVarOptionals != nil && localVarOptionals.PercentPlayed.IsSet() {\n\t\tlocalVarQueryParams.Add(\"percentPlayed\", parameterToString(localVarOptionals.PercentPlayed.Value(), \"\"))\n\t}\n\tif localVarOptionals != nil && localVarOptionals.UnplayedCount.IsSet() {\n\t\tlocalVarQueryParams.Add(\"unplayedCount\", parameterToString(localVarOptionals.UnplayedCount.Value(), \"\"))\n\t}\n\tif localVarOptionals != nil && localVarOptionals.Width.IsSet() {\n\t\tlocalVarQueryParams.Add(\"width\", parameterToString(localVarOptionals.Width.Value(), \"\"))\n\t}\n\tif localVarOptionals != nil && localVarOptionals.Height.IsSet() {\n\t\tlocalVarQueryParams.Add(\"height\", parameterToString(localVarOptionals.Height.Value(), \"\"))\n\t}\n\tif localVarOptionals != nil && localVarOptionals.Quality.IsSet() {\n\t\tlocalVarQueryParams.Add(\"quality\", parameterToString(localVarOptionals.Quality.Value(), \"\"))\n\t}\n\tif localVarOptionals != nil && localVarOptionals.CropWhitespace.IsSet() {\n\t\tlocalVarQueryParams.Add(\"cropWhitespace\", parameterToString(localVarOptionals.CropWhitespace.Value(), \"\"))\n\t}\n\tif localVarOptionals != nil && localVarOptionals.AddPlayedIndicator.IsSet() {\n\t\tlocalVarQueryParams.Add(\"addPlayedIndicator\", parameterToString(localVarOptionals.AddPlayedIndicator.Value(), \"\"))\n\t}\n\tif localVarOptionals != nil && localVarOptionals.Blur.IsSet() {\n\t\tlocalVarQueryParams.Add(\"blur\", parameterToString(localVarOptionals.Blur.Value(), \"\"))\n\t}\n\tif localVarOptionals != nil && localVarOptionals.BackgroundColor.IsSet() {\n\t\tlocalVarQueryParams.Add(\"backgroundColor\", parameterToString(localVarOptionals.BackgroundColor.Value(), \"\"))\n\t}\n\tif localVarOptionals != nil && localVarOptionals.ForegroundLayer.IsSet() {\n\t\tlocalVarQueryParams.Add(\"foregroundLayer\", parameterToString(localVarOptionals.ForegroundLayer.Value(), \"\"))\n\t}\n\t// to determine the Content-Type header\n\tlocalVarHTTPContentTypes := []string{}\n\n\t// set Content-Type header\n\tlocalVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes)\n\tif localVarHTTPContentType != \"\" {\n\t\tlocalVarHeaderParams[\"Content-Type\"] = localVarHTTPContentType\n\t}\n\n\t// to determine the Accept header\n\tlocalVarHTTPHeaderAccepts := []string{\"image/_*\", \"application/json\", \"application/json; profile=CamelCase\", \"application/json; profile=PascalCase\"}\n\n\t// set Accept header\n\tlocalVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts)\n\tif localVarHTTPHeaderAccept != \"\" {\n\t\tlocalVarHeaderParams[\"Accept\"] = localVarHTTPHeaderAccept\n\t}\n\tif ctx != nil {\n\t\t// API Key Authentication\n\t\tif auth, ok := ctx.Value(ContextAPIKey).(APIKey); ok {\n\t\t\tvar key string\n\t\t\tif auth.Prefix != \"\" {\n\t\t\t\tkey = auth.Prefix + \" \" + auth.Key\n\t\t\t} else {\n\t\t\t\tkey = auth.Key\n\t\t\t}\n\t\t\tlocalVarHeaderParams[\"X-Emby-Authorization\"] = key\n\t\t}\n\t}\n\tr, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes)\n\tif err != nil {\n\t\treturn localVarReturnValue, nil, err\n\t}\n\n\tlocalVarHTTPResponse, err := a.client.callAPI(r)\n\tif err != nil || localVarHTTPResponse == nil {\n\t\treturn localVarReturnValue, localVarHTTPResponse, err\n\t}\n\n\tlocalVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body)\n\tlocalVarHTTPResponse.Body.Close()\n\tif err != nil {\n\t\treturn localVarReturnValue, localVarHTTPResponse, err\n\t}\n\n\tif localVarHTTPResponse.StatusCode >= 300 {\n\t\tnewErr := GenericOpenAPIError{\n\t\t\tbody: localVarBody,\n\t\t\terror: localVarHTTPResponse.Status,\n\t\t}\n\t\tif localVarHTTPResponse.StatusCode == 404 {\n\t\t\tvar v ProblemDetails\n\t\t\terr = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get(\"Content-Type\"))\n\t\t\tif err != nil {\n\t\t\t\tnewErr.error = err.Error()\n\t\t\t\treturn localVarReturnValue, localVarHTTPResponse, newErr\n\t\t\t}\n\t\t\tnewErr.model = v\n\t\t}\n\t\treturn localVarReturnValue, localVarHTTPResponse, newErr\n\t}\n\n\terr = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get(\"Content-Type\"))\n\tif err != nil {\n\t\tnewErr := GenericOpenAPIError{\n\t\t\tbody: localVarBody,\n\t\t\terror: err.Error(),\n\t\t}\n\t\treturn localVarReturnValue, localVarHTTPResponse, newErr\n\t}\n\n\treturn localVarReturnValue, localVarHTTPResponse, nil\n}", "func newImageFromNative(obj unsafe.Pointer) interface{} {\n\tim := &Image{}\n\tim.object = C.to_GtkImage(obj)\n\n\tif gobject.IsObjectFloating(im) {\n\t\tgobject.RefSink(im)\n\t} else {\n\t\tgobject.Ref(im)\n\t}\n\tim.Widget = NewWidget(obj)\n\timageFinalizer(im)\n\n\treturn im\n}", "func (e *Escpos) Image(params map[string]string, data string) {\n\t// send alignment to printer\n\tif align, ok := params[\"align\"]; ok {\n\t\te.SetAlign(align)\n\t}\n\n\t// get width\n\twstr, ok := params[\"width\"]\n\tif !ok {\n\t\tlog.Println(\"No width specified on image\")\n\t}\n\n\t// get height\n\thstr, ok := params[\"height\"]\n\tif !ok {\n\t\tlog.Println(\"No height specified on image\")\n\t}\n\n\t// convert width\n\twidth, err := strconv.Atoi(wstr)\n\tif err != nil {\n\t\tlog.Println(\"Invalid image width %s\", wstr)\n\t}\n\n\t// convert height\n\theight, err := strconv.Atoi(hstr)\n\tif err != nil {\n\t\tlog.Println(\"Invalid image height %s\", hstr)\n\t}\n\n\t// decode data frome b64 string\n\tdec, err := base64.StdEncoding.DecodeString(data)\n\tif err != nil {\n\t\tlog.Println(err.Error())\n\t}\n\n\tif e.Verbose {\n\t\tlog.Println(\"Image len:%d w: %d h: %d\\n\", len(dec), width, height)\n\t}\n\n\theader := []byte{\n\t\tbyte('0'), 0x01, 0x01, byte('1'),\n\t}\n\n\ta := append(header, dec...)\n\n\te.gSend(byte('0'), byte('p'), a)\n\te.gSend(byte('0'), byte('2'), []byte{})\n\n}", "func BindImageTexture(unit uint32, texture uint32, level int32, layered bool, layer int32, access uint32, format uint32) {\n\tC.glowBindImageTexture(gpBindImageTexture, (C.GLuint)(unit), (C.GLuint)(texture), (C.GLint)(level), (C.GLboolean)(boolToInt(layered)), (C.GLint)(layer), (C.GLenum)(access), (C.GLenum)(format))\n}", "func BindImageTexture(unit uint32, texture uint32, level int32, layered bool, layer int32, access uint32, format uint32) {\n\tC.glowBindImageTexture(gpBindImageTexture, (C.GLuint)(unit), (C.GLuint)(texture), (C.GLint)(level), (C.GLboolean)(boolToInt(layered)), (C.GLint)(layer), (C.GLenum)(access), (C.GLenum)(format))\n}", "func imageLogs(w http.ResponseWriter, r *http.Request, parms martini.Params) {\r\n\tid, _ := strconv.ParseInt(parms[\"id\"], 10, 64)\r\n\tvar img CRImage\r\n\timage := img.Querylog(id)\r\n\tif err := json.NewEncoder(w).Encode(*image); err != nil {\r\n\t\tlogger.Error(err)\r\n\t\thttp.Error(w, err.Error(), http.StatusInternalServerError)\r\n\t}\r\n}", "func (et ElementType) getGLType() (gltype uint32) {\n\tswitch et {\n\tcase VEC2:\n\t\treturn gl.INT\n\tcase VEC3:\n\t\treturn gl.INT\n\tcase VEC4:\n\t\treturn gl.INT\n\tcase FVEC2:\n\t\treturn gl.FLOAT\n\tcase FVEC3:\n\t\treturn gl.FLOAT\n\tcase FVEC4:\n\t\treturn gl.FLOAT\n\tdefault:\n\t\treturn 0\n\t}\n}", "func TexParameterfv(target, pname Enum, params []float32) {\n\tgl.TexParameterfv(uint32(target), uint32(pname), &params[0])\n}", "func PixelStorei(pname Enum, param int32) {\n\tgl.PixelStorei(uint32(pname), param)\n}", "func Image(id, ref string) imageapi.Image {\n\treturn AgedImage(id, ref, 120)\n}" ]
[ "0.5778349", "0.5778349", "0.5703757", "0.56748", "0.56483406", "0.56117815", "0.55883145", "0.55622244", "0.55443203", "0.54496926", "0.5444753", "0.5422649", "0.5418509", "0.54089665", "0.538006", "0.53633386", "0.5346996", "0.5344023", "0.5328263", "0.5328263", "0.53250116", "0.5322426", "0.531047", "0.5291385", "0.52759385", "0.52561206", "0.5255278", "0.5228517", "0.5228517", "0.5222633", "0.5222633", "0.5194254", "0.51702636", "0.51645315", "0.51629525", "0.5133972", "0.51225406", "0.5111499", "0.5108014", "0.5103334", "0.51029605", "0.5089586", "0.50762224", "0.50639737", "0.5042263", "0.502411", "0.5010825", "0.49845982", "0.49792996", "0.49594632", "0.4946367", "0.49307886", "0.49295422", "0.49295422", "0.49165407", "0.49112684", "0.49112147", "0.49112147", "0.4906634", "0.4902415", "0.48941502", "0.48862714", "0.48848158", "0.4868545", "0.48665482", "0.48587668", "0.48539892", "0.48539892", "0.485194", "0.48516566", "0.48403725", "0.48269212", "0.4821123", "0.4815585", "0.48127115", "0.48065305", "0.4781563", "0.4777942", "0.47691402", "0.4757386", "0.47562897", "0.47464654", "0.47464654", "0.47458088", "0.47408968", "0.4736359", "0.47255445", "0.46981806", "0.46875975", "0.46842504", "0.46832955", "0.46725747", "0.46666273", "0.46666273", "0.46635622", "0.46606654", "0.46600813", "0.46532845", "0.4631603" ]
0.55393356
10
Parameter image has type C.GLeglImageOES.
func EGLImageTargetTextureStorageEXT(texture uint32, image unsafe.Pointer, attrib_list *int32) { C.glowEGLImageTargetTextureStorageEXT(gpEGLImageTargetTextureStorageEXT, (C.GLuint)(texture), (C.GLeglImageOES)(image), (*C.GLint)(unsafe.Pointer(attrib_list))) }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "func GetTexParameterfv(target Enum, pname Enum, params []Float) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tcpname, _ := (C.GLenum)(pname), cgoAllocsUnknown\n\tcparams, _ := (*C.GLfloat)(unsafe.Pointer((*sliceHeader)(unsafe.Pointer(&params)).Data)), cgoAllocsUnknown\n\tC.glGetTexParameterfv(ctarget, cpname, cparams)\n}", "func (b *GoGLBackend) AsImage() backendbase.Image {\n\treturn nil\n}", "func GetTexImage(target uint32, level int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowGetTexImage(gpGetTexImage, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexImage1D(target uint32, level int32, internalformat int32, width int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexImage1D(gpTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexImage2D(gpTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexImage2D(target Enum, level int, width, height int, format Enum, ty Enum, data []byte) {\n\tp := unsafe.Pointer(nil)\n\tif len(data) > 0 {\n\t\tp = gl.Ptr(&data[0])\n\t}\n\tgl.TexImage2D(uint32(target), int32(level), int32(format), int32(width), int32(height), 0, uint32(format), uint32(ty), p)\n}", "func TexImage2D(target GLEnum, level int32, internalformat GLEnum, width, height, border int32, format, xtype GLEnum, pixels []float32) {\n\tgl.TexImage2D(uint32(target), level, int32(internalformat), width, height, border, uint32(format), uint32(xtype), unsafe.Pointer(&pixels[0]))\n}", "func EGLImageTargetTexStorageEXT(target uint32, image unsafe.Pointer, attrib_list *int32) {\n\tC.glowEGLImageTargetTexStorageEXT(gpEGLImageTargetTexStorageEXT, (C.GLenum)(target), (C.GLeglImageOES)(image), (*C.GLint)(unsafe.Pointer(attrib_list)))\n}", "func EGLImageTargetTexStorageEXT(target uint32, image unsafe.Pointer, attrib_list *int32) {\n\tC.glowEGLImageTargetTexStorageEXT(gpEGLImageTargetTexStorageEXT, (C.GLenum)(target), (C.GLeglImageOES)(image), (*C.GLint)(unsafe.Pointer(attrib_list)))\n}", "func (g *GLTF) LoadImage(imgIdx int) (*image.RGBA, error) {\n\n\t// Check if provided image index is valid\n\tif imgIdx < 0 || imgIdx >= len(g.Images) {\n\t\treturn nil, fmt.Errorf(\"invalid image index\")\n\t}\n\timgData := g.Images[imgIdx]\n\t// Return cached if available\n\tif imgData.cache != nil {\n\t\tlog.Debug(\"Fetching Image %d (cached)\", imgIdx)\n\t\treturn imgData.cache, nil\n\t}\n\tlog.Debug(\"Loading Image %d\", imgIdx)\n\n\tvar data []byte\n\tvar err error\n\t// If Uri is empty, load image from GLB binary chunk\n\tif imgData.Uri == \"\" {\n\t\tif imgData.BufferView == nil {\n\t\t\treturn nil, fmt.Errorf(\"image has empty URI and no BufferView\")\n\t\t}\n\t\tdata, err = g.loadBufferView(*imgData.BufferView)\n\t} else if isDataURL(imgData.Uri) {\n\t\t// Checks if image URI is data URL\n\t\tdata, err = loadDataURL(imgData.Uri)\n\t} else {\n\t\t// Load image data from file\n\t\tdata, err = g.loadFileBytes(imgData.Uri)\n\t}\n\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\n\t// Decodes image data\n\tbb := bytes.NewBuffer(data)\n\timg, _, err := image.Decode(bb)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\n\t// Converts image to RGBA format\n\trgba := image.NewRGBA(img.Bounds())\n\tif rgba.Stride != rgba.Rect.Size().X*4 {\n\t\treturn nil, fmt.Errorf(\"unsupported stride\")\n\t}\n\tdraw.Draw(rgba, rgba.Bounds(), img, image.Point{0, 0}, draw.Src)\n\n\t// Cache image\n\tg.Images[imgIdx].cache = rgba\n\n\treturn rgba, nil\n}", "func TexImage2D(target Enum, level Int, internalformat Int, width Sizei, height Sizei, border Int, format Enum, kind Enum, pixels unsafe.Pointer) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tclevel, _ := (C.GLint)(level), cgoAllocsUnknown\n\tcinternalformat, _ := (C.GLint)(internalformat), cgoAllocsUnknown\n\tcwidth, _ := (C.GLsizei)(width), cgoAllocsUnknown\n\tcheight, _ := (C.GLsizei)(height), cgoAllocsUnknown\n\tcborder, _ := (C.GLint)(border), cgoAllocsUnknown\n\tcformat, _ := (C.GLenum)(format), cgoAllocsUnknown\n\tckind, _ := (C.GLenum)(kind), cgoAllocsUnknown\n\tcpixels, _ := (unsafe.Pointer)(unsafe.Pointer(pixels)), cgoAllocsUnknown\n\tC.glTexImage2D(ctarget, clevel, cinternalformat, cwidth, cheight, cborder, cformat, ckind, cpixels)\n}", "func TexParameterf(target Enum, pname Enum, param Float) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tcpname, _ := (C.GLenum)(pname), cgoAllocsUnknown\n\tcparam, _ := (C.GLfloat)(param), cgoAllocsUnknown\n\tC.glTexParameterf(ctarget, cpname, cparam)\n}", "func hogImage(img image.Image, binSize int) cv.RealVectorImage {\n\treturn hog.HOG(cv.ColorImageToReal(img), binSize)\n}", "func TexParameteri(target Enum, pname Enum, param Int) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tcpname, _ := (C.GLenum)(pname), cgoAllocsUnknown\n\tcparam, _ := (C.GLint)(param), cgoAllocsUnknown\n\tC.glTexParameteri(ctarget, cpname, cparam)\n}", "func GetTexImage(target uint32, level int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall6(gpGetTexImage, 5, uintptr(target), uintptr(level), uintptr(format), uintptr(xtype), uintptr(pixels), 0)\n}", "func (self *GameObjectCreator) Image1O(x int, y int, key interface{}, frame interface{}) *Image{\n return &Image{self.Object.Call(\"image\", x, y, key, frame)}\n}", "func (b *XMobileBackend) PutImageData(img *image.RGBA, x, y int) {\n\tb.activate()\n\n\tb.glctx.ActiveTexture(gl.TEXTURE0)\n\tif b.imageBufTex.Value == 0 {\n\t\tb.imageBufTex = b.glctx.CreateTexture()\n\t\tb.glctx.BindTexture(gl.TEXTURE_2D, b.imageBufTex)\n\t\tb.glctx.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.LINEAR)\n\t\tb.glctx.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, gl.LINEAR)\n\t\tb.glctx.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_S, gl.CLAMP_TO_EDGE)\n\t\tb.glctx.TexParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_T, gl.CLAMP_TO_EDGE)\n\t} else {\n\t\tb.glctx.BindTexture(gl.TEXTURE_2D, b.imageBufTex)\n\t}\n\n\tw, h := img.Bounds().Dx(), img.Bounds().Dy()\n\n\tif img.Stride == img.Bounds().Dx()*4 {\n\t\tb.glctx.TexImage2D(gl.TEXTURE_2D, 0, gl.RGBA, w, h, gl.RGBA, gl.UNSIGNED_BYTE, img.Pix[0:])\n\t} else {\n\t\tdata := make([]uint8, 0, w*h*4)\n\t\tfor cy := 0; cy < h; cy++ {\n\t\t\tstart := cy * img.Stride\n\t\t\tend := start + w*4\n\t\t\tdata = append(data, img.Pix[start:end]...)\n\t\t}\n\t\tb.glctx.TexImage2D(gl.TEXTURE_2D, 0, gl.RGBA, w, h, gl.RGBA, gl.UNSIGNED_BYTE, data[0:])\n\t}\n\n\tdx, dy := float32(x), float32(y)\n\tdw, dh := float32(w), float32(h)\n\n\tb.glctx.BindBuffer(gl.ARRAY_BUFFER, b.buf)\n\tdata := [16]float32{dx, dy, dx + dw, dy, dx + dw, dy + dh, dx, dy + dh,\n\t\t0, 0, 1, 0, 1, 1, 0, 1}\n\tb.glctx.BufferData(gl.ARRAY_BUFFER, byteSlice(unsafe.Pointer(&data[0]), len(data)*4), gl.STREAM_DRAW)\n\n\tb.glctx.UseProgram(b.shd.ID)\n\tb.glctx.Uniform1i(b.shd.Image, 0)\n\tb.glctx.Uniform2f(b.shd.CanvasSize, float32(b.fw), float32(b.fh))\n\tb.glctx.UniformMatrix3fv(b.shd.Matrix, mat3identity[:])\n\tb.glctx.Uniform1f(b.shd.GlobalAlpha, 1)\n\tb.glctx.Uniform1i(b.shd.UseAlphaTex, 0)\n\tb.glctx.Uniform1i(b.shd.Func, shdFuncImage)\n\tb.glctx.VertexAttribPointer(b.shd.Vertex, 2, gl.FLOAT, false, 0, 0)\n\tb.glctx.VertexAttribPointer(b.shd.TexCoord, 2, gl.FLOAT, false, 0, 8*4)\n\tb.glctx.EnableVertexAttribArray(b.shd.Vertex)\n\tb.glctx.EnableVertexAttribArray(b.shd.TexCoord)\n\tb.glctx.DrawArrays(gl.TRIANGLE_FAN, 0, 4)\n\tb.glctx.DisableVertexAttribArray(b.shd.Vertex)\n\tb.glctx.DisableVertexAttribArray(b.shd.TexCoord)\n}", "func BindImageTexture(unit uint32, texture uint32, level int32, layered bool, layer int32, access uint32, format uint32) {\n C.glowBindImageTexture(gpBindImageTexture, (C.GLuint)(unit), (C.GLuint)(texture), (C.GLint)(level), (C.GLboolean)(boolToInt(layered)), (C.GLint)(layer), (C.GLenum)(access), (C.GLenum)(format))\n}", "func TexImage1D(target uint32, level int32, internalformat int32, width int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexImage1D(gpTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexImage1D(target uint32, level int32, internalformat int32, width int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexImage1D(gpTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func GetTexParameterfv(dst []float32, target, pname Enum) {\n\tgl.GetTexParameterfv(uint32(target), uint32(pname), &dst[0])\n}", "func (native *OpenGL) TexImage2D(target uint32, level int32, internalFormat uint32, width int32, height int32,\n\tborder int32, format uint32, xtype uint32, pixels interface{}) {\n\tptr, isPointer := pixels.(unsafe.Pointer)\n\tif isPointer {\n\t\tgl.TexImage2D(target, level, int32(internalFormat), width, height, border, format, xtype, ptr)\n\t} else {\n\t\tgl.TexImage2D(target, level, int32(internalFormat), width, height, border, format, xtype, gl.Ptr(pixels))\n\t}\n}", "func GetTexParameteriv(target Enum, pname Enum, params []Int) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tcpname, _ := (C.GLenum)(pname), cgoAllocsUnknown\n\tcparams, _ := (*C.GLint)(unsafe.Pointer((*sliceHeader)(unsafe.Pointer(&params)).Data)), cgoAllocsUnknown\n\tC.glGetTexParameteriv(ctarget, cpname, cparams)\n}", "func TexImage1D(target uint32, level int32, internalformat int32, width int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTexImage1D, 8, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(width), uintptr(border), uintptr(format), uintptr(xtype), uintptr(pixels), 0)\n}", "func CompressedTexImage2D(target uint32, level int32, internalformat uint32, width int32, height int32, border int32, imageSize int32, data unsafe.Pointer) {\n C.glowCompressedTexImage2D(gpCompressedTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func FramebufferParameteri(target uint32, pname uint32, param int32) {\n C.glowFramebufferParameteri(gpFramebufferParameteri, (C.GLenum)(target), (C.GLenum)(pname), (C.GLint)(param))\n}", "func (self *GameObjectCreator) Image(x int, y int, key interface{}) *Image{\n return &Image{self.Object.Call(\"image\", x, y, key)}\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexImage2D(gpTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowTexImage2D(gpTexImage2D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func GetTexImage(target uint32, level int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowGetTexImage(gpGetTexImage, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func GetTexImage(target uint32, level int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tC.glowGetTexImage(gpGetTexImage, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func CompressedTexImage1D(target uint32, level int32, internalformat uint32, width int32, border int32, imageSize int32, data unsafe.Pointer) {\n C.glowCompressedTexImage1D(gpCompressedTexImage1D, (C.GLenum)(target), (C.GLint)(level), (C.GLenum)(internalformat), (C.GLsizei)(width), (C.GLint)(border), (C.GLsizei)(imageSize), data)\n}", "func GetCompressedTexImage(target uint32, level int32, img unsafe.Pointer) {\n C.glowGetCompressedTexImage(gpGetCompressedTexImage, (C.GLenum)(target), (C.GLint)(level), img)\n}", "func TexParameterfv(target Enum, pname Enum, params []Float) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tcpname, _ := (C.GLenum)(pname), cgoAllocsUnknown\n\tcparams, _ := (*C.GLfloat)(unsafe.Pointer((*sliceHeader)(unsafe.Pointer(&params)).Data)), cgoAllocsUnknown\n\tC.glTexParameterfv(ctarget, cpname, cparams)\n}", "func EGLImageTargetTextureStorageEXT(texture uint32, image unsafe.Pointer, attrib_list *int32) {\n\tsyscall.Syscall(gpEGLImageTargetTextureStorageEXT, 3, uintptr(texture), uintptr(image), uintptr(unsafe.Pointer(attrib_list)))\n}", "func GetRenderbufferParameteriv(target uint32, pname uint32, params *int32) {\n C.glowGetRenderbufferParameteriv(gpGetRenderbufferParameteriv, (C.GLenum)(target), (C.GLenum)(pname), (*C.GLint)(unsafe.Pointer(params)))\n}", "func (debugging *debuggingOpenGL) TexImage2D(target uint32, level int32, internalFormat uint32, width int32, height int32,\n\tborder int32, format uint32, xtype uint32, pixels interface{}) {\n\tdebugging.recordEntry(\"TexImage2D\", target, level, internalFormat, width, height, border, format, xtype, pixels)\n\tdebugging.gl.TexImage2D(target, level, internalFormat, width, height, border, format, xtype, pixels)\n\tdebugging.recordExit(\"TexImage2D\")\n}", "func (native *OpenGL) TexParameteri(target uint32, pname uint32, param int32) {\n\tgl.TexParameteri(target, pname, param)\n}", "func TexParameterf(target, pname GLEnum, param float32) {\n\tgl.TexParameterf(uint32(target), uint32(pname), param)\n}", "func TexParameterf(target, pname Enum, param float32) {\n\tgl.TexParameterf(uint32(target), uint32(pname), param)\n}", "func imageGet(L *lua.LState) int {\n\tp := checkImage(L)\n\n\tL.Push(lua.LNumber(*p))\n\n\treturn 1\n}", "func TexParameteri(target, pname GLEnum, param int32) {\n\tgl.TexParameteri(uint32(target), uint32(pname), param)\n}", "func (self *GameObjectCreator) ImageI(args ...interface{}) *Image{\n return &Image{self.Object.Call(\"image\", args)}\n}", "func TexImage2D(target uint32, level int32, internalformat int32, width int32, height int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n\tsyscall.Syscall9(gpTexImage2D, 9, uintptr(target), uintptr(level), uintptr(internalformat), uintptr(width), uintptr(height), uintptr(border), uintptr(format), uintptr(xtype), uintptr(pixels))\n}", "func (native *OpenGL) TexParameterf(target uint32, pname uint32, param float32) {\n\tgl.TexParameterf(target, pname, param)\n}", "func TexParameteriv(target Enum, pname Enum, params []Int) {\n\tctarget, _ := (C.GLenum)(target), cgoAllocsUnknown\n\tcpname, _ := (C.GLenum)(pname), cgoAllocsUnknown\n\tcparams, _ := (*C.GLint)(unsafe.Pointer((*sliceHeader)(unsafe.Pointer(&params)).Data)), cgoAllocsUnknown\n\tC.glTexParameteriv(ctarget, cpname, cparams)\n}", "func PixelStorei(pname Enum, param Int) {\n\tcpname, _ := (C.GLenum)(pname), cgoAllocsUnknown\n\tcparam, _ := (C.GLint)(param), cgoAllocsUnknown\n\tC.glPixelStorei(cpname, cparam)\n}", "func TexParameteri(target, pname Enum, param int) {\n\tgl.TexParameteri(uint32(target), uint32(pname), int32(param))\n}", "func Uniform1fv(location int32, count int32, value *float32) {\n C.glowUniform1fv(gpUniform1fv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func (gl *WebGL) TexImage2D(target GLEnum, level int, internalFormat GLEnum, format GLEnum, texelType GLEnum, pixels interface{}) {\n\tgl.context.Call(\"texImage2D\", target, level, internalFormat, format, texelType, pixels)\n}", "func PassThrough(token float32) {\n C.glowPassThrough(gpPassThrough, (C.GLfloat)(token))\n}", "func ArrayElement(i int32) {\n C.glowArrayElement(gpArrayElement, (C.GLint)(i))\n}", "func GetTextureImage(texture uint32, level int32, format uint32, xtype uint32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetTextureImage(gpGetTextureImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLenum)(format), (C.GLenum)(xtype), (C.GLsizei)(bufSize), pixels)\n}", "func GetTextureImage(texture uint32, level int32, format uint32, xtype uint32, bufSize int32, pixels unsafe.Pointer) {\n\tC.glowGetTextureImage(gpGetTextureImage, (C.GLuint)(texture), (C.GLint)(level), (C.GLenum)(format), (C.GLenum)(xtype), (C.GLsizei)(bufSize), pixels)\n}", "func (self *Graphics) GenerateTexture1O(resolution int) *Texture{\n return &Texture{self.Object.Call(\"generateTexture\", resolution)}\n}", "func GetBufferParameteri64v(target uint32, pname uint32, params *int64) {\n\tC.glowGetBufferParameteri64v(gpGetBufferParameteri64v, (C.GLenum)(target), (C.GLenum)(pname), (*C.GLint64)(unsafe.Pointer(params)))\n}", "func GetBufferParameteri64v(target uint32, pname uint32, params *int64) {\n\tC.glowGetBufferParameteri64v(gpGetBufferParameteri64v, (C.GLenum)(target), (C.GLenum)(pname), (*C.GLint64)(unsafe.Pointer(params)))\n}", "func InitGo(loader func(string) unsafe.Pointer) {\n ver := Version{OpenGL, -1, -1}\n\n\tC.pfn_glGetString = C.PFNGLGETSTRING(loader(\"glGetString\"))\n\tvs := C.GoString((*C.char)(unsafe.Pointer(C.gogl_glGetString(GL_VERSION))))\n i := strings.IndexFunc(vs, func(r rune) bool {\n return r >= '0' && r <= '9'\n })\n if i >= 0 {\n fmt.Sscanf(vs[i:], \"%d.%d\", &ver.Major, &ver.Minor)\n }\n if !ver.GE(OpenGL, 1, 0) {\n panic(\"failed to identify OpenGL version\")\n }\n C.GLVersion.major = C.int(ver.Major)\n C.GLVersion.minor = C.int(ver.Minor)\n\n C.pfn_glAccum = C.PFNGLACCUM(loader(\"glAccum\"))\n C.pfn_glAlphaFunc = C.PFNGLALPHAFUNC(loader(\"glAlphaFunc\"))\n C.pfn_glBegin = C.PFNGLBEGIN(loader(\"glBegin\"))\n C.pfn_glBitmap = C.PFNGLBITMAP(loader(\"glBitmap\"))\n C.pfn_glBlendFunc = C.PFNGLBLENDFUNC(loader(\"glBlendFunc\"))\n C.pfn_glCallList = C.PFNGLCALLLIST(loader(\"glCallList\"))\n C.pfn_glCallLists = C.PFNGLCALLLISTS(loader(\"glCallLists\"))\n C.pfn_glClear = C.PFNGLCLEAR(loader(\"glClear\"))\n C.pfn_glClearAccum = C.PFNGLCLEARACCUM(loader(\"glClearAccum\"))\n C.pfn_glClearColor = C.PFNGLCLEARCOLOR(loader(\"glClearColor\"))\n C.pfn_glClearDepth = C.PFNGLCLEARDEPTH(loader(\"glClearDepth\"))\n C.pfn_glClearIndex = C.PFNGLCLEARINDEX(loader(\"glClearIndex\"))\n C.pfn_glClearStencil = C.PFNGLCLEARSTENCIL(loader(\"glClearStencil\"))\n C.pfn_glClipPlane = C.PFNGLCLIPPLANE(loader(\"glClipPlane\"))\n C.pfn_glColor3b = C.PFNGLCOLOR3B(loader(\"glColor3b\"))\n C.pfn_glColor3bv = C.PFNGLCOLOR3BV(loader(\"glColor3bv\"))\n C.pfn_glColor3d = C.PFNGLCOLOR3D(loader(\"glColor3d\"))\n C.pfn_glColor3dv = C.PFNGLCOLOR3DV(loader(\"glColor3dv\"))\n C.pfn_glColor3f = C.PFNGLCOLOR3F(loader(\"glColor3f\"))\n C.pfn_glColor3fv = C.PFNGLCOLOR3FV(loader(\"glColor3fv\"))\n C.pfn_glColor3i = C.PFNGLCOLOR3I(loader(\"glColor3i\"))\n C.pfn_glColor3iv = C.PFNGLCOLOR3IV(loader(\"glColor3iv\"))\n C.pfn_glColor3s = C.PFNGLCOLOR3S(loader(\"glColor3s\"))\n C.pfn_glColor3sv = C.PFNGLCOLOR3SV(loader(\"glColor3sv\"))\n C.pfn_glColor3ub = C.PFNGLCOLOR3UB(loader(\"glColor3ub\"))\n C.pfn_glColor3ubv = C.PFNGLCOLOR3UBV(loader(\"glColor3ubv\"))\n C.pfn_glColor3ui = C.PFNGLCOLOR3UI(loader(\"glColor3ui\"))\n C.pfn_glColor3uiv = C.PFNGLCOLOR3UIV(loader(\"glColor3uiv\"))\n C.pfn_glColor3us = C.PFNGLCOLOR3US(loader(\"glColor3us\"))\n C.pfn_glColor3usv = C.PFNGLCOLOR3USV(loader(\"glColor3usv\"))\n C.pfn_glColor4b = C.PFNGLCOLOR4B(loader(\"glColor4b\"))\n C.pfn_glColor4bv = C.PFNGLCOLOR4BV(loader(\"glColor4bv\"))\n C.pfn_glColor4d = C.PFNGLCOLOR4D(loader(\"glColor4d\"))\n C.pfn_glColor4dv = C.PFNGLCOLOR4DV(loader(\"glColor4dv\"))\n C.pfn_glColor4f = C.PFNGLCOLOR4F(loader(\"glColor4f\"))\n C.pfn_glColor4fv = C.PFNGLCOLOR4FV(loader(\"glColor4fv\"))\n C.pfn_glColor4i = C.PFNGLCOLOR4I(loader(\"glColor4i\"))\n C.pfn_glColor4iv = C.PFNGLCOLOR4IV(loader(\"glColor4iv\"))\n C.pfn_glColor4s = C.PFNGLCOLOR4S(loader(\"glColor4s\"))\n C.pfn_glColor4sv = C.PFNGLCOLOR4SV(loader(\"glColor4sv\"))\n C.pfn_glColor4ub = C.PFNGLCOLOR4UB(loader(\"glColor4ub\"))\n C.pfn_glColor4ubv = C.PFNGLCOLOR4UBV(loader(\"glColor4ubv\"))\n C.pfn_glColor4ui = C.PFNGLCOLOR4UI(loader(\"glColor4ui\"))\n C.pfn_glColor4uiv = C.PFNGLCOLOR4UIV(loader(\"glColor4uiv\"))\n C.pfn_glColor4us = C.PFNGLCOLOR4US(loader(\"glColor4us\"))\n C.pfn_glColor4usv = C.PFNGLCOLOR4USV(loader(\"glColor4usv\"))\n C.pfn_glColorMask = C.PFNGLCOLORMASK(loader(\"glColorMask\"))\n C.pfn_glColorMaterial = C.PFNGLCOLORMATERIAL(loader(\"glColorMaterial\"))\n C.pfn_glCopyPixels = C.PFNGLCOPYPIXELS(loader(\"glCopyPixels\"))\n C.pfn_glCullFace = C.PFNGLCULLFACE(loader(\"glCullFace\"))\n C.pfn_glDeleteLists = C.PFNGLDELETELISTS(loader(\"glDeleteLists\"))\n C.pfn_glDepthFunc = C.PFNGLDEPTHFUNC(loader(\"glDepthFunc\"))\n C.pfn_glDepthMask = C.PFNGLDEPTHMASK(loader(\"glDepthMask\"))\n C.pfn_glDepthRange = C.PFNGLDEPTHRANGE(loader(\"glDepthRange\"))\n C.pfn_glDisable = C.PFNGLDISABLE(loader(\"glDisable\"))\n C.pfn_glDrawBuffer = C.PFNGLDRAWBUFFER(loader(\"glDrawBuffer\"))\n C.pfn_glDrawPixels = C.PFNGLDRAWPIXELS(loader(\"glDrawPixels\"))\n C.pfn_glEdgeFlag = C.PFNGLEDGEFLAG(loader(\"glEdgeFlag\"))\n C.pfn_glEdgeFlagv = C.PFNGLEDGEFLAGV(loader(\"glEdgeFlagv\"))\n C.pfn_glEnable = C.PFNGLENABLE(loader(\"glEnable\"))\n C.pfn_glEnd = C.PFNGLEND(loader(\"glEnd\"))\n C.pfn_glEndList = C.PFNGLENDLIST(loader(\"glEndList\"))\n C.pfn_glEvalCoord1d = C.PFNGLEVALCOORD1D(loader(\"glEvalCoord1d\"))\n C.pfn_glEvalCoord1dv = C.PFNGLEVALCOORD1DV(loader(\"glEvalCoord1dv\"))\n C.pfn_glEvalCoord1f = C.PFNGLEVALCOORD1F(loader(\"glEvalCoord1f\"))\n C.pfn_glEvalCoord1fv = C.PFNGLEVALCOORD1FV(loader(\"glEvalCoord1fv\"))\n C.pfn_glEvalCoord2d = C.PFNGLEVALCOORD2D(loader(\"glEvalCoord2d\"))\n C.pfn_glEvalCoord2dv = C.PFNGLEVALCOORD2DV(loader(\"glEvalCoord2dv\"))\n C.pfn_glEvalCoord2f = C.PFNGLEVALCOORD2F(loader(\"glEvalCoord2f\"))\n C.pfn_glEvalCoord2fv = C.PFNGLEVALCOORD2FV(loader(\"glEvalCoord2fv\"))\n C.pfn_glEvalMesh1 = C.PFNGLEVALMESH1(loader(\"glEvalMesh1\"))\n C.pfn_glEvalMesh2 = C.PFNGLEVALMESH2(loader(\"glEvalMesh2\"))\n C.pfn_glEvalPoint1 = C.PFNGLEVALPOINT1(loader(\"glEvalPoint1\"))\n C.pfn_glEvalPoint2 = C.PFNGLEVALPOINT2(loader(\"glEvalPoint2\"))\n C.pfn_glFeedbackBuffer = C.PFNGLFEEDBACKBUFFER(loader(\"glFeedbackBuffer\"))\n C.pfn_glFinish = C.PFNGLFINISH(loader(\"glFinish\"))\n C.pfn_glFlush = C.PFNGLFLUSH(loader(\"glFlush\"))\n C.pfn_glFogf = C.PFNGLFOGF(loader(\"glFogf\"))\n C.pfn_glFogfv = C.PFNGLFOGFV(loader(\"glFogfv\"))\n C.pfn_glFogi = C.PFNGLFOGI(loader(\"glFogi\"))\n C.pfn_glFogiv = C.PFNGLFOGIV(loader(\"glFogiv\"))\n C.pfn_glFrontFace = C.PFNGLFRONTFACE(loader(\"glFrontFace\"))\n C.pfn_glFrustum = C.PFNGLFRUSTUM(loader(\"glFrustum\"))\n C.pfn_glGenLists = C.PFNGLGENLISTS(loader(\"glGenLists\"))\n C.pfn_glGetBooleanv = C.PFNGLGETBOOLEANV(loader(\"glGetBooleanv\"))\n C.pfn_glGetClipPlane = C.PFNGLGETCLIPPLANE(loader(\"glGetClipPlane\"))\n C.pfn_glGetDoublev = C.PFNGLGETDOUBLEV(loader(\"glGetDoublev\"))\n C.pfn_glGetError = C.PFNGLGETERROR(loader(\"glGetError\"))\n C.pfn_glGetFloatv = C.PFNGLGETFLOATV(loader(\"glGetFloatv\"))\n C.pfn_glGetIntegerv = C.PFNGLGETINTEGERV(loader(\"glGetIntegerv\"))\n C.pfn_glGetLightfv = C.PFNGLGETLIGHTFV(loader(\"glGetLightfv\"))\n C.pfn_glGetLightiv = C.PFNGLGETLIGHTIV(loader(\"glGetLightiv\"))\n C.pfn_glGetMapdv = C.PFNGLGETMAPDV(loader(\"glGetMapdv\"))\n C.pfn_glGetMapfv = C.PFNGLGETMAPFV(loader(\"glGetMapfv\"))\n C.pfn_glGetMapiv = C.PFNGLGETMAPIV(loader(\"glGetMapiv\"))\n C.pfn_glGetMaterialfv = C.PFNGLGETMATERIALFV(loader(\"glGetMaterialfv\"))\n C.pfn_glGetMaterialiv = C.PFNGLGETMATERIALIV(loader(\"glGetMaterialiv\"))\n C.pfn_glGetPixelMapfv = C.PFNGLGETPIXELMAPFV(loader(\"glGetPixelMapfv\"))\n C.pfn_glGetPixelMapuiv = C.PFNGLGETPIXELMAPUIV(loader(\"glGetPixelMapuiv\"))\n C.pfn_glGetPixelMapusv = C.PFNGLGETPIXELMAPUSV(loader(\"glGetPixelMapusv\"))\n C.pfn_glGetPolygonStipple = C.PFNGLGETPOLYGONSTIPPLE(loader(\"glGetPolygonStipple\"))\n C.pfn_glGetString = C.PFNGLGETSTRING(loader(\"glGetString\"))\n C.pfn_glGetTexEnvfv = C.PFNGLGETTEXENVFV(loader(\"glGetTexEnvfv\"))\n C.pfn_glGetTexEnviv = C.PFNGLGETTEXENVIV(loader(\"glGetTexEnviv\"))\n C.pfn_glGetTexGendv = C.PFNGLGETTEXGENDV(loader(\"glGetTexGendv\"))\n C.pfn_glGetTexGenfv = C.PFNGLGETTEXGENFV(loader(\"glGetTexGenfv\"))\n C.pfn_glGetTexGeniv = C.PFNGLGETTEXGENIV(loader(\"glGetTexGeniv\"))\n C.pfn_glGetTexImage = C.PFNGLGETTEXIMAGE(loader(\"glGetTexImage\"))\n C.pfn_glGetTexLevelParameterfv = C.PFNGLGETTEXLEVELPARAMETERFV(loader(\"glGetTexLevelParameterfv\"))\n C.pfn_glGetTexLevelParameteriv = C.PFNGLGETTEXLEVELPARAMETERIV(loader(\"glGetTexLevelParameteriv\"))\n C.pfn_glGetTexParameterfv = C.PFNGLGETTEXPARAMETERFV(loader(\"glGetTexParameterfv\"))\n C.pfn_glGetTexParameteriv = C.PFNGLGETTEXPARAMETERIV(loader(\"glGetTexParameteriv\"))\n C.pfn_glHint = C.PFNGLHINT(loader(\"glHint\"))\n C.pfn_glIndexMask = C.PFNGLINDEXMASK(loader(\"glIndexMask\"))\n C.pfn_glIndexd = C.PFNGLINDEXD(loader(\"glIndexd\"))\n C.pfn_glIndexdv = C.PFNGLINDEXDV(loader(\"glIndexdv\"))\n C.pfn_glIndexf = C.PFNGLINDEXF(loader(\"glIndexf\"))\n C.pfn_glIndexfv = C.PFNGLINDEXFV(loader(\"glIndexfv\"))\n C.pfn_glIndexi = C.PFNGLINDEXI(loader(\"glIndexi\"))\n C.pfn_glIndexiv = C.PFNGLINDEXIV(loader(\"glIndexiv\"))\n C.pfn_glIndexs = C.PFNGLINDEXS(loader(\"glIndexs\"))\n C.pfn_glIndexsv = C.PFNGLINDEXSV(loader(\"glIndexsv\"))\n C.pfn_glInitNames = C.PFNGLINITNAMES(loader(\"glInitNames\"))\n C.pfn_glIsEnabled = C.PFNGLISENABLED(loader(\"glIsEnabled\"))\n C.pfn_glIsList = C.PFNGLISLIST(loader(\"glIsList\"))\n C.pfn_glLightModelf = C.PFNGLLIGHTMODELF(loader(\"glLightModelf\"))\n C.pfn_glLightModelfv = C.PFNGLLIGHTMODELFV(loader(\"glLightModelfv\"))\n C.pfn_glLightModeli = C.PFNGLLIGHTMODELI(loader(\"glLightModeli\"))\n C.pfn_glLightModeliv = C.PFNGLLIGHTMODELIV(loader(\"glLightModeliv\"))\n C.pfn_glLightf = C.PFNGLLIGHTF(loader(\"glLightf\"))\n C.pfn_glLightfv = C.PFNGLLIGHTFV(loader(\"glLightfv\"))\n C.pfn_glLighti = C.PFNGLLIGHTI(loader(\"glLighti\"))\n C.pfn_glLightiv = C.PFNGLLIGHTIV(loader(\"glLightiv\"))\n C.pfn_glLineStipple = C.PFNGLLINESTIPPLE(loader(\"glLineStipple\"))\n C.pfn_glLineWidth = C.PFNGLLINEWIDTH(loader(\"glLineWidth\"))\n C.pfn_glListBase = C.PFNGLLISTBASE(loader(\"glListBase\"))\n C.pfn_glLoadIdentity = C.PFNGLLOADIDENTITY(loader(\"glLoadIdentity\"))\n C.pfn_glLoadMatrixd = C.PFNGLLOADMATRIXD(loader(\"glLoadMatrixd\"))\n C.pfn_glLoadMatrixf = C.PFNGLLOADMATRIXF(loader(\"glLoadMatrixf\"))\n C.pfn_glLoadName = C.PFNGLLOADNAME(loader(\"glLoadName\"))\n C.pfn_glLogicOp = C.PFNGLLOGICOP(loader(\"glLogicOp\"))\n C.pfn_glMap1d = C.PFNGLMAP1D(loader(\"glMap1d\"))\n C.pfn_glMap1f = C.PFNGLMAP1F(loader(\"glMap1f\"))\n C.pfn_glMap2d = C.PFNGLMAP2D(loader(\"glMap2d\"))\n C.pfn_glMap2f = C.PFNGLMAP2F(loader(\"glMap2f\"))\n C.pfn_glMapGrid1d = C.PFNGLMAPGRID1D(loader(\"glMapGrid1d\"))\n C.pfn_glMapGrid1f = C.PFNGLMAPGRID1F(loader(\"glMapGrid1f\"))\n C.pfn_glMapGrid2d = C.PFNGLMAPGRID2D(loader(\"glMapGrid2d\"))\n C.pfn_glMapGrid2f = C.PFNGLMAPGRID2F(loader(\"glMapGrid2f\"))\n C.pfn_glMaterialf = C.PFNGLMATERIALF(loader(\"glMaterialf\"))\n C.pfn_glMaterialfv = C.PFNGLMATERIALFV(loader(\"glMaterialfv\"))\n C.pfn_glMateriali = C.PFNGLMATERIALI(loader(\"glMateriali\"))\n C.pfn_glMaterialiv = C.PFNGLMATERIALIV(loader(\"glMaterialiv\"))\n C.pfn_glMatrixMode = C.PFNGLMATRIXMODE(loader(\"glMatrixMode\"))\n C.pfn_glMultMatrixd = C.PFNGLMULTMATRIXD(loader(\"glMultMatrixd\"))\n C.pfn_glMultMatrixf = C.PFNGLMULTMATRIXF(loader(\"glMultMatrixf\"))\n C.pfn_glNewList = C.PFNGLNEWLIST(loader(\"glNewList\"))\n C.pfn_glNormal3b = C.PFNGLNORMAL3B(loader(\"glNormal3b\"))\n C.pfn_glNormal3bv = C.PFNGLNORMAL3BV(loader(\"glNormal3bv\"))\n C.pfn_glNormal3d = C.PFNGLNORMAL3D(loader(\"glNormal3d\"))\n C.pfn_glNormal3dv = C.PFNGLNORMAL3DV(loader(\"glNormal3dv\"))\n C.pfn_glNormal3f = C.PFNGLNORMAL3F(loader(\"glNormal3f\"))\n C.pfn_glNormal3fv = C.PFNGLNORMAL3FV(loader(\"glNormal3fv\"))\n C.pfn_glNormal3i = C.PFNGLNORMAL3I(loader(\"glNormal3i\"))\n C.pfn_glNormal3iv = C.PFNGLNORMAL3IV(loader(\"glNormal3iv\"))\n C.pfn_glNormal3s = C.PFNGLNORMAL3S(loader(\"glNormal3s\"))\n C.pfn_glNormal3sv = C.PFNGLNORMAL3SV(loader(\"glNormal3sv\"))\n C.pfn_glOrtho = C.PFNGLORTHO(loader(\"glOrtho\"))\n C.pfn_glPassThrough = C.PFNGLPASSTHROUGH(loader(\"glPassThrough\"))\n C.pfn_glPixelMapfv = C.PFNGLPIXELMAPFV(loader(\"glPixelMapfv\"))\n C.pfn_glPixelMapuiv = C.PFNGLPIXELMAPUIV(loader(\"glPixelMapuiv\"))\n C.pfn_glPixelMapusv = C.PFNGLPIXELMAPUSV(loader(\"glPixelMapusv\"))\n C.pfn_glPixelStoref = C.PFNGLPIXELSTOREF(loader(\"glPixelStoref\"))\n C.pfn_glPixelStorei = C.PFNGLPIXELSTOREI(loader(\"glPixelStorei\"))\n C.pfn_glPixelTransferf = C.PFNGLPIXELTRANSFERF(loader(\"glPixelTransferf\"))\n C.pfn_glPixelTransferi = C.PFNGLPIXELTRANSFERI(loader(\"glPixelTransferi\"))\n C.pfn_glPixelZoom = C.PFNGLPIXELZOOM(loader(\"glPixelZoom\"))\n C.pfn_glPointSize = C.PFNGLPOINTSIZE(loader(\"glPointSize\"))\n C.pfn_glPolygonMode = C.PFNGLPOLYGONMODE(loader(\"glPolygonMode\"))\n C.pfn_glPolygonStipple = C.PFNGLPOLYGONSTIPPLE(loader(\"glPolygonStipple\"))\n C.pfn_glPopAttrib = C.PFNGLPOPATTRIB(loader(\"glPopAttrib\"))\n C.pfn_glPopMatrix = C.PFNGLPOPMATRIX(loader(\"glPopMatrix\"))\n C.pfn_glPopName = C.PFNGLPOPNAME(loader(\"glPopName\"))\n C.pfn_glPushAttrib = C.PFNGLPUSHATTRIB(loader(\"glPushAttrib\"))\n C.pfn_glPushMatrix = C.PFNGLPUSHMATRIX(loader(\"glPushMatrix\"))\n C.pfn_glPushName = C.PFNGLPUSHNAME(loader(\"glPushName\"))\n C.pfn_glRasterPos2d = C.PFNGLRASTERPOS2D(loader(\"glRasterPos2d\"))\n C.pfn_glRasterPos2dv = C.PFNGLRASTERPOS2DV(loader(\"glRasterPos2dv\"))\n C.pfn_glRasterPos2f = C.PFNGLRASTERPOS2F(loader(\"glRasterPos2f\"))\n C.pfn_glRasterPos2fv = C.PFNGLRASTERPOS2FV(loader(\"glRasterPos2fv\"))\n C.pfn_glRasterPos2i = C.PFNGLRASTERPOS2I(loader(\"glRasterPos2i\"))\n C.pfn_glRasterPos2iv = C.PFNGLRASTERPOS2IV(loader(\"glRasterPos2iv\"))\n C.pfn_glRasterPos2s = C.PFNGLRASTERPOS2S(loader(\"glRasterPos2s\"))\n C.pfn_glRasterPos2sv = C.PFNGLRASTERPOS2SV(loader(\"glRasterPos2sv\"))\n C.pfn_glRasterPos3d = C.PFNGLRASTERPOS3D(loader(\"glRasterPos3d\"))\n C.pfn_glRasterPos3dv = C.PFNGLRASTERPOS3DV(loader(\"glRasterPos3dv\"))\n C.pfn_glRasterPos3f = C.PFNGLRASTERPOS3F(loader(\"glRasterPos3f\"))\n C.pfn_glRasterPos3fv = C.PFNGLRASTERPOS3FV(loader(\"glRasterPos3fv\"))\n C.pfn_glRasterPos3i = C.PFNGLRASTERPOS3I(loader(\"glRasterPos3i\"))\n C.pfn_glRasterPos3iv = C.PFNGLRASTERPOS3IV(loader(\"glRasterPos3iv\"))\n C.pfn_glRasterPos3s = C.PFNGLRASTERPOS3S(loader(\"glRasterPos3s\"))\n C.pfn_glRasterPos3sv = C.PFNGLRASTERPOS3SV(loader(\"glRasterPos3sv\"))\n C.pfn_glRasterPos4d = C.PFNGLRASTERPOS4D(loader(\"glRasterPos4d\"))\n C.pfn_glRasterPos4dv = C.PFNGLRASTERPOS4DV(loader(\"glRasterPos4dv\"))\n C.pfn_glRasterPos4f = C.PFNGLRASTERPOS4F(loader(\"glRasterPos4f\"))\n C.pfn_glRasterPos4fv = C.PFNGLRASTERPOS4FV(loader(\"glRasterPos4fv\"))\n C.pfn_glRasterPos4i = C.PFNGLRASTERPOS4I(loader(\"glRasterPos4i\"))\n C.pfn_glRasterPos4iv = C.PFNGLRASTERPOS4IV(loader(\"glRasterPos4iv\"))\n C.pfn_glRasterPos4s = C.PFNGLRASTERPOS4S(loader(\"glRasterPos4s\"))\n C.pfn_glRasterPos4sv = C.PFNGLRASTERPOS4SV(loader(\"glRasterPos4sv\"))\n C.pfn_glReadBuffer = C.PFNGLREADBUFFER(loader(\"glReadBuffer\"))\n C.pfn_glReadPixels = C.PFNGLREADPIXELS(loader(\"glReadPixels\"))\n C.pfn_glRectd = C.PFNGLRECTD(loader(\"glRectd\"))\n C.pfn_glRectdv = C.PFNGLRECTDV(loader(\"glRectdv\"))\n C.pfn_glRectf = C.PFNGLRECTF(loader(\"glRectf\"))\n C.pfn_glRectfv = C.PFNGLRECTFV(loader(\"glRectfv\"))\n C.pfn_glRecti = C.PFNGLRECTI(loader(\"glRecti\"))\n C.pfn_glRectiv = C.PFNGLRECTIV(loader(\"glRectiv\"))\n C.pfn_glRects = C.PFNGLRECTS(loader(\"glRects\"))\n C.pfn_glRectsv = C.PFNGLRECTSV(loader(\"glRectsv\"))\n C.pfn_glRenderMode = C.PFNGLRENDERMODE(loader(\"glRenderMode\"))\n C.pfn_glRotated = C.PFNGLROTATED(loader(\"glRotated\"))\n C.pfn_glRotatef = C.PFNGLROTATEF(loader(\"glRotatef\"))\n C.pfn_glScaled = C.PFNGLSCALED(loader(\"glScaled\"))\n C.pfn_glScalef = C.PFNGLSCALEF(loader(\"glScalef\"))\n C.pfn_glScissor = C.PFNGLSCISSOR(loader(\"glScissor\"))\n C.pfn_glSelectBuffer = C.PFNGLSELECTBUFFER(loader(\"glSelectBuffer\"))\n C.pfn_glShadeModel = C.PFNGLSHADEMODEL(loader(\"glShadeModel\"))\n C.pfn_glStencilFunc = C.PFNGLSTENCILFUNC(loader(\"glStencilFunc\"))\n C.pfn_glStencilMask = C.PFNGLSTENCILMASK(loader(\"glStencilMask\"))\n C.pfn_glStencilOp = C.PFNGLSTENCILOP(loader(\"glStencilOp\"))\n C.pfn_glTexCoord1d = C.PFNGLTEXCOORD1D(loader(\"glTexCoord1d\"))\n C.pfn_glTexCoord1dv = C.PFNGLTEXCOORD1DV(loader(\"glTexCoord1dv\"))\n C.pfn_glTexCoord1f = C.PFNGLTEXCOORD1F(loader(\"glTexCoord1f\"))\n C.pfn_glTexCoord1fv = C.PFNGLTEXCOORD1FV(loader(\"glTexCoord1fv\"))\n C.pfn_glTexCoord1i = C.PFNGLTEXCOORD1I(loader(\"glTexCoord1i\"))\n C.pfn_glTexCoord1iv = C.PFNGLTEXCOORD1IV(loader(\"glTexCoord1iv\"))\n C.pfn_glTexCoord1s = C.PFNGLTEXCOORD1S(loader(\"glTexCoord1s\"))\n C.pfn_glTexCoord1sv = C.PFNGLTEXCOORD1SV(loader(\"glTexCoord1sv\"))\n C.pfn_glTexCoord2d = C.PFNGLTEXCOORD2D(loader(\"glTexCoord2d\"))\n C.pfn_glTexCoord2dv = C.PFNGLTEXCOORD2DV(loader(\"glTexCoord2dv\"))\n C.pfn_glTexCoord2f = C.PFNGLTEXCOORD2F(loader(\"glTexCoord2f\"))\n C.pfn_glTexCoord2fv = C.PFNGLTEXCOORD2FV(loader(\"glTexCoord2fv\"))\n C.pfn_glTexCoord2i = C.PFNGLTEXCOORD2I(loader(\"glTexCoord2i\"))\n C.pfn_glTexCoord2iv = C.PFNGLTEXCOORD2IV(loader(\"glTexCoord2iv\"))\n C.pfn_glTexCoord2s = C.PFNGLTEXCOORD2S(loader(\"glTexCoord2s\"))\n C.pfn_glTexCoord2sv = C.PFNGLTEXCOORD2SV(loader(\"glTexCoord2sv\"))\n C.pfn_glTexCoord3d = C.PFNGLTEXCOORD3D(loader(\"glTexCoord3d\"))\n C.pfn_glTexCoord3dv = C.PFNGLTEXCOORD3DV(loader(\"glTexCoord3dv\"))\n C.pfn_glTexCoord3f = C.PFNGLTEXCOORD3F(loader(\"glTexCoord3f\"))\n C.pfn_glTexCoord3fv = C.PFNGLTEXCOORD3FV(loader(\"glTexCoord3fv\"))\n C.pfn_glTexCoord3i = C.PFNGLTEXCOORD3I(loader(\"glTexCoord3i\"))\n C.pfn_glTexCoord3iv = C.PFNGLTEXCOORD3IV(loader(\"glTexCoord3iv\"))\n C.pfn_glTexCoord3s = C.PFNGLTEXCOORD3S(loader(\"glTexCoord3s\"))\n C.pfn_glTexCoord3sv = C.PFNGLTEXCOORD3SV(loader(\"glTexCoord3sv\"))\n C.pfn_glTexCoord4d = C.PFNGLTEXCOORD4D(loader(\"glTexCoord4d\"))\n C.pfn_glTexCoord4dv = C.PFNGLTEXCOORD4DV(loader(\"glTexCoord4dv\"))\n C.pfn_glTexCoord4f = C.PFNGLTEXCOORD4F(loader(\"glTexCoord4f\"))\n C.pfn_glTexCoord4fv = C.PFNGLTEXCOORD4FV(loader(\"glTexCoord4fv\"))\n C.pfn_glTexCoord4i = C.PFNGLTEXCOORD4I(loader(\"glTexCoord4i\"))\n C.pfn_glTexCoord4iv = C.PFNGLTEXCOORD4IV(loader(\"glTexCoord4iv\"))\n C.pfn_glTexCoord4s = C.PFNGLTEXCOORD4S(loader(\"glTexCoord4s\"))\n C.pfn_glTexCoord4sv = C.PFNGLTEXCOORD4SV(loader(\"glTexCoord4sv\"))\n C.pfn_glTexEnvf = C.PFNGLTEXENVF(loader(\"glTexEnvf\"))\n C.pfn_glTexEnvfv = C.PFNGLTEXENVFV(loader(\"glTexEnvfv\"))\n C.pfn_glTexEnvi = C.PFNGLTEXENVI(loader(\"glTexEnvi\"))\n C.pfn_glTexEnviv = C.PFNGLTEXENVIV(loader(\"glTexEnviv\"))\n C.pfn_glTexGend = C.PFNGLTEXGEND(loader(\"glTexGend\"))\n C.pfn_glTexGendv = C.PFNGLTEXGENDV(loader(\"glTexGendv\"))\n C.pfn_glTexGenf = C.PFNGLTEXGENF(loader(\"glTexGenf\"))\n C.pfn_glTexGenfv = C.PFNGLTEXGENFV(loader(\"glTexGenfv\"))\n C.pfn_glTexGeni = C.PFNGLTEXGENI(loader(\"glTexGeni\"))\n C.pfn_glTexGeniv = C.PFNGLTEXGENIV(loader(\"glTexGeniv\"))\n C.pfn_glTexImage1D = C.PFNGLTEXIMAGE1D(loader(\"glTexImage1D\"))\n C.pfn_glTexImage2D = C.PFNGLTEXIMAGE2D(loader(\"glTexImage2D\"))\n C.pfn_glTexParameterf = C.PFNGLTEXPARAMETERF(loader(\"glTexParameterf\"))\n C.pfn_glTexParameterfv = C.PFNGLTEXPARAMETERFV(loader(\"glTexParameterfv\"))\n C.pfn_glTexParameteri = C.PFNGLTEXPARAMETERI(loader(\"glTexParameteri\"))\n C.pfn_glTexParameteriv = C.PFNGLTEXPARAMETERIV(loader(\"glTexParameteriv\"))\n C.pfn_glTranslated = C.PFNGLTRANSLATED(loader(\"glTranslated\"))\n C.pfn_glTranslatef = C.PFNGLTRANSLATEF(loader(\"glTranslatef\"))\n C.pfn_glVertex2d = C.PFNGLVERTEX2D(loader(\"glVertex2d\"))\n C.pfn_glVertex2dv = C.PFNGLVERTEX2DV(loader(\"glVertex2dv\"))\n C.pfn_glVertex2f = C.PFNGLVERTEX2F(loader(\"glVertex2f\"))\n C.pfn_glVertex2fv = C.PFNGLVERTEX2FV(loader(\"glVertex2fv\"))\n C.pfn_glVertex2i = C.PFNGLVERTEX2I(loader(\"glVertex2i\"))\n C.pfn_glVertex2iv = C.PFNGLVERTEX2IV(loader(\"glVertex2iv\"))\n C.pfn_glVertex2s = C.PFNGLVERTEX2S(loader(\"glVertex2s\"))\n C.pfn_glVertex2sv = C.PFNGLVERTEX2SV(loader(\"glVertex2sv\"))\n C.pfn_glVertex3d = C.PFNGLVERTEX3D(loader(\"glVertex3d\"))\n C.pfn_glVertex3dv = C.PFNGLVERTEX3DV(loader(\"glVertex3dv\"))\n C.pfn_glVertex3f = C.PFNGLVERTEX3F(loader(\"glVertex3f\"))\n C.pfn_glVertex3fv = C.PFNGLVERTEX3FV(loader(\"glVertex3fv\"))\n C.pfn_glVertex3i = C.PFNGLVERTEX3I(loader(\"glVertex3i\"))\n C.pfn_glVertex3iv = C.PFNGLVERTEX3IV(loader(\"glVertex3iv\"))\n C.pfn_glVertex3s = C.PFNGLVERTEX3S(loader(\"glVertex3s\"))\n C.pfn_glVertex3sv = C.PFNGLVERTEX3SV(loader(\"glVertex3sv\"))\n C.pfn_glVertex4d = C.PFNGLVERTEX4D(loader(\"glVertex4d\"))\n C.pfn_glVertex4dv = C.PFNGLVERTEX4DV(loader(\"glVertex4dv\"))\n C.pfn_glVertex4f = C.PFNGLVERTEX4F(loader(\"glVertex4f\"))\n C.pfn_glVertex4fv = C.PFNGLVERTEX4FV(loader(\"glVertex4fv\"))\n C.pfn_glVertex4i = C.PFNGLVERTEX4I(loader(\"glVertex4i\"))\n C.pfn_glVertex4iv = C.PFNGLVERTEX4IV(loader(\"glVertex4iv\"))\n C.pfn_glVertex4s = C.PFNGLVERTEX4S(loader(\"glVertex4s\"))\n C.pfn_glVertex4sv = C.PFNGLVERTEX4SV(loader(\"glVertex4sv\"))\n C.pfn_glViewport = C.PFNGLVIEWPORT(loader(\"glViewport\"))\n\n // OpenGL 1.1\n if !ver.GE(OpenGL, 1, 1) {\n return\n }\n C.pfn_glAreTexturesResident = C.PFNGLARETEXTURESRESIDENT(loader(\"glAreTexturesResident\"))\n C.pfn_glArrayElement = C.PFNGLARRAYELEMENT(loader(\"glArrayElement\"))\n C.pfn_glBindTexture = C.PFNGLBINDTEXTURE(loader(\"glBindTexture\"))\n C.pfn_glColorPointer = C.PFNGLCOLORPOINTER(loader(\"glColorPointer\"))\n C.pfn_glCopyTexImage1D = C.PFNGLCOPYTEXIMAGE1D(loader(\"glCopyTexImage1D\"))\n C.pfn_glCopyTexImage2D = C.PFNGLCOPYTEXIMAGE2D(loader(\"glCopyTexImage2D\"))\n C.pfn_glCopyTexSubImage1D = C.PFNGLCOPYTEXSUBIMAGE1D(loader(\"glCopyTexSubImage1D\"))\n C.pfn_glCopyTexSubImage2D = C.PFNGLCOPYTEXSUBIMAGE2D(loader(\"glCopyTexSubImage2D\"))\n C.pfn_glDeleteTextures = C.PFNGLDELETETEXTURES(loader(\"glDeleteTextures\"))\n C.pfn_glDisableClientState = C.PFNGLDISABLECLIENTSTATE(loader(\"glDisableClientState\"))\n C.pfn_glDrawArrays = C.PFNGLDRAWARRAYS(loader(\"glDrawArrays\"))\n C.pfn_glDrawElements = C.PFNGLDRAWELEMENTS(loader(\"glDrawElements\"))\n C.pfn_glEdgeFlagPointer = C.PFNGLEDGEFLAGPOINTER(loader(\"glEdgeFlagPointer\"))\n C.pfn_glEnableClientState = C.PFNGLENABLECLIENTSTATE(loader(\"glEnableClientState\"))\n C.pfn_glGenTextures = C.PFNGLGENTEXTURES(loader(\"glGenTextures\"))\n C.pfn_glGetPointerv = C.PFNGLGETPOINTERV(loader(\"glGetPointerv\"))\n C.pfn_glIndexPointer = C.PFNGLINDEXPOINTER(loader(\"glIndexPointer\"))\n C.pfn_glIndexub = C.PFNGLINDEXUB(loader(\"glIndexub\"))\n C.pfn_glIndexubv = C.PFNGLINDEXUBV(loader(\"glIndexubv\"))\n C.pfn_glInterleavedArrays = C.PFNGLINTERLEAVEDARRAYS(loader(\"glInterleavedArrays\"))\n C.pfn_glIsTexture = C.PFNGLISTEXTURE(loader(\"glIsTexture\"))\n C.pfn_glNormalPointer = C.PFNGLNORMALPOINTER(loader(\"glNormalPointer\"))\n C.pfn_glPolygonOffset = C.PFNGLPOLYGONOFFSET(loader(\"glPolygonOffset\"))\n C.pfn_glPopClientAttrib = C.PFNGLPOPCLIENTATTRIB(loader(\"glPopClientAttrib\"))\n C.pfn_glPrioritizeTextures = C.PFNGLPRIORITIZETEXTURES(loader(\"glPrioritizeTextures\"))\n C.pfn_glPushClientAttrib = C.PFNGLPUSHCLIENTATTRIB(loader(\"glPushClientAttrib\"))\n C.pfn_glTexCoordPointer = C.PFNGLTEXCOORDPOINTER(loader(\"glTexCoordPointer\"))\n C.pfn_glTexSubImage1D = C.PFNGLTEXSUBIMAGE1D(loader(\"glTexSubImage1D\"))\n C.pfn_glTexSubImage2D = C.PFNGLTEXSUBIMAGE2D(loader(\"glTexSubImage2D\"))\n C.pfn_glVertexPointer = C.PFNGLVERTEXPOINTER(loader(\"glVertexPointer\"))\n\n // OpenGL 1.2\n if !ver.GE(OpenGL, 1, 2) {\n return\n }\n C.pfn_glCopyTexSubImage3D = C.PFNGLCOPYTEXSUBIMAGE3D(loader(\"glCopyTexSubImage3D\"))\n C.pfn_glDrawRangeElements = C.PFNGLDRAWRANGEELEMENTS(loader(\"glDrawRangeElements\"))\n C.pfn_glTexImage3D = C.PFNGLTEXIMAGE3D(loader(\"glTexImage3D\"))\n C.pfn_glTexSubImage3D = C.PFNGLTEXSUBIMAGE3D(loader(\"glTexSubImage3D\"))\n\n // OpenGL 1.3\n if !ver.GE(OpenGL, 1, 3) {\n return\n }\n C.pfn_glActiveTexture = C.PFNGLACTIVETEXTURE(loader(\"glActiveTexture\"))\n C.pfn_glClientActiveTexture = C.PFNGLCLIENTACTIVETEXTURE(loader(\"glClientActiveTexture\"))\n C.pfn_glCompressedTexImage1D = C.PFNGLCOMPRESSEDTEXIMAGE1D(loader(\"glCompressedTexImage1D\"))\n C.pfn_glCompressedTexImage2D = C.PFNGLCOMPRESSEDTEXIMAGE2D(loader(\"glCompressedTexImage2D\"))\n C.pfn_glCompressedTexImage3D = C.PFNGLCOMPRESSEDTEXIMAGE3D(loader(\"glCompressedTexImage3D\"))\n C.pfn_glCompressedTexSubImage1D = C.PFNGLCOMPRESSEDTEXSUBIMAGE1D(loader(\"glCompressedTexSubImage1D\"))\n C.pfn_glCompressedTexSubImage2D = C.PFNGLCOMPRESSEDTEXSUBIMAGE2D(loader(\"glCompressedTexSubImage2D\"))\n C.pfn_glCompressedTexSubImage3D = C.PFNGLCOMPRESSEDTEXSUBIMAGE3D(loader(\"glCompressedTexSubImage3D\"))\n C.pfn_glGetCompressedTexImage = C.PFNGLGETCOMPRESSEDTEXIMAGE(loader(\"glGetCompressedTexImage\"))\n C.pfn_glLoadTransposeMatrixd = C.PFNGLLOADTRANSPOSEMATRIXD(loader(\"glLoadTransposeMatrixd\"))\n C.pfn_glLoadTransposeMatrixf = C.PFNGLLOADTRANSPOSEMATRIXF(loader(\"glLoadTransposeMatrixf\"))\n C.pfn_glMultTransposeMatrixd = C.PFNGLMULTTRANSPOSEMATRIXD(loader(\"glMultTransposeMatrixd\"))\n C.pfn_glMultTransposeMatrixf = C.PFNGLMULTTRANSPOSEMATRIXF(loader(\"glMultTransposeMatrixf\"))\n C.pfn_glMultiTexCoord1d = C.PFNGLMULTITEXCOORD1D(loader(\"glMultiTexCoord1d\"))\n C.pfn_glMultiTexCoord1dv = C.PFNGLMULTITEXCOORD1DV(loader(\"glMultiTexCoord1dv\"))\n C.pfn_glMultiTexCoord1f = C.PFNGLMULTITEXCOORD1F(loader(\"glMultiTexCoord1f\"))\n C.pfn_glMultiTexCoord1fv = C.PFNGLMULTITEXCOORD1FV(loader(\"glMultiTexCoord1fv\"))\n C.pfn_glMultiTexCoord1i = C.PFNGLMULTITEXCOORD1I(loader(\"glMultiTexCoord1i\"))\n C.pfn_glMultiTexCoord1iv = C.PFNGLMULTITEXCOORD1IV(loader(\"glMultiTexCoord1iv\"))\n C.pfn_glMultiTexCoord1s = C.PFNGLMULTITEXCOORD1S(loader(\"glMultiTexCoord1s\"))\n C.pfn_glMultiTexCoord1sv = C.PFNGLMULTITEXCOORD1SV(loader(\"glMultiTexCoord1sv\"))\n C.pfn_glMultiTexCoord2d = C.PFNGLMULTITEXCOORD2D(loader(\"glMultiTexCoord2d\"))\n C.pfn_glMultiTexCoord2dv = C.PFNGLMULTITEXCOORD2DV(loader(\"glMultiTexCoord2dv\"))\n C.pfn_glMultiTexCoord2f = C.PFNGLMULTITEXCOORD2F(loader(\"glMultiTexCoord2f\"))\n C.pfn_glMultiTexCoord2fv = C.PFNGLMULTITEXCOORD2FV(loader(\"glMultiTexCoord2fv\"))\n C.pfn_glMultiTexCoord2i = C.PFNGLMULTITEXCOORD2I(loader(\"glMultiTexCoord2i\"))\n C.pfn_glMultiTexCoord2iv = C.PFNGLMULTITEXCOORD2IV(loader(\"glMultiTexCoord2iv\"))\n C.pfn_glMultiTexCoord2s = C.PFNGLMULTITEXCOORD2S(loader(\"glMultiTexCoord2s\"))\n C.pfn_glMultiTexCoord2sv = C.PFNGLMULTITEXCOORD2SV(loader(\"glMultiTexCoord2sv\"))\n C.pfn_glMultiTexCoord3d = C.PFNGLMULTITEXCOORD3D(loader(\"glMultiTexCoord3d\"))\n C.pfn_glMultiTexCoord3dv = C.PFNGLMULTITEXCOORD3DV(loader(\"glMultiTexCoord3dv\"))\n C.pfn_glMultiTexCoord3f = C.PFNGLMULTITEXCOORD3F(loader(\"glMultiTexCoord3f\"))\n C.pfn_glMultiTexCoord3fv = C.PFNGLMULTITEXCOORD3FV(loader(\"glMultiTexCoord3fv\"))\n C.pfn_glMultiTexCoord3i = C.PFNGLMULTITEXCOORD3I(loader(\"glMultiTexCoord3i\"))\n C.pfn_glMultiTexCoord3iv = C.PFNGLMULTITEXCOORD3IV(loader(\"glMultiTexCoord3iv\"))\n C.pfn_glMultiTexCoord3s = C.PFNGLMULTITEXCOORD3S(loader(\"glMultiTexCoord3s\"))\n C.pfn_glMultiTexCoord3sv = C.PFNGLMULTITEXCOORD3SV(loader(\"glMultiTexCoord3sv\"))\n C.pfn_glMultiTexCoord4d = C.PFNGLMULTITEXCOORD4D(loader(\"glMultiTexCoord4d\"))\n C.pfn_glMultiTexCoord4dv = C.PFNGLMULTITEXCOORD4DV(loader(\"glMultiTexCoord4dv\"))\n C.pfn_glMultiTexCoord4f = C.PFNGLMULTITEXCOORD4F(loader(\"glMultiTexCoord4f\"))\n C.pfn_glMultiTexCoord4fv = C.PFNGLMULTITEXCOORD4FV(loader(\"glMultiTexCoord4fv\"))\n C.pfn_glMultiTexCoord4i = C.PFNGLMULTITEXCOORD4I(loader(\"glMultiTexCoord4i\"))\n C.pfn_glMultiTexCoord4iv = C.PFNGLMULTITEXCOORD4IV(loader(\"glMultiTexCoord4iv\"))\n C.pfn_glMultiTexCoord4s = C.PFNGLMULTITEXCOORD4S(loader(\"glMultiTexCoord4s\"))\n C.pfn_glMultiTexCoord4sv = C.PFNGLMULTITEXCOORD4SV(loader(\"glMultiTexCoord4sv\"))\n C.pfn_glSampleCoverage = C.PFNGLSAMPLECOVERAGE(loader(\"glSampleCoverage\"))\n\n // OpenGL 1.4\n if !ver.GE(OpenGL, 1, 4) {\n return\n }\n C.pfn_glBlendColor = C.PFNGLBLENDCOLOR(loader(\"glBlendColor\"))\n C.pfn_glBlendEquation = C.PFNGLBLENDEQUATION(loader(\"glBlendEquation\"))\n C.pfn_glBlendFuncSeparate = C.PFNGLBLENDFUNCSEPARATE(loader(\"glBlendFuncSeparate\"))\n C.pfn_glFogCoordPointer = C.PFNGLFOGCOORDPOINTER(loader(\"glFogCoordPointer\"))\n C.pfn_glFogCoordd = C.PFNGLFOGCOORDD(loader(\"glFogCoordd\"))\n C.pfn_glFogCoorddv = C.PFNGLFOGCOORDDV(loader(\"glFogCoorddv\"))\n C.pfn_glFogCoordf = C.PFNGLFOGCOORDF(loader(\"glFogCoordf\"))\n C.pfn_glFogCoordfv = C.PFNGLFOGCOORDFV(loader(\"glFogCoordfv\"))\n C.pfn_glMultiDrawArrays = C.PFNGLMULTIDRAWARRAYS(loader(\"glMultiDrawArrays\"))\n C.pfn_glMultiDrawElements = C.PFNGLMULTIDRAWELEMENTS(loader(\"glMultiDrawElements\"))\n C.pfn_glPointParameterf = C.PFNGLPOINTPARAMETERF(loader(\"glPointParameterf\"))\n C.pfn_glPointParameterfv = C.PFNGLPOINTPARAMETERFV(loader(\"glPointParameterfv\"))\n C.pfn_glPointParameteri = C.PFNGLPOINTPARAMETERI(loader(\"glPointParameteri\"))\n C.pfn_glPointParameteriv = C.PFNGLPOINTPARAMETERIV(loader(\"glPointParameteriv\"))\n C.pfn_glSecondaryColor3b = C.PFNGLSECONDARYCOLOR3B(loader(\"glSecondaryColor3b\"))\n C.pfn_glSecondaryColor3bv = C.PFNGLSECONDARYCOLOR3BV(loader(\"glSecondaryColor3bv\"))\n C.pfn_glSecondaryColor3d = C.PFNGLSECONDARYCOLOR3D(loader(\"glSecondaryColor3d\"))\n C.pfn_glSecondaryColor3dv = C.PFNGLSECONDARYCOLOR3DV(loader(\"glSecondaryColor3dv\"))\n C.pfn_glSecondaryColor3f = C.PFNGLSECONDARYCOLOR3F(loader(\"glSecondaryColor3f\"))\n C.pfn_glSecondaryColor3fv = C.PFNGLSECONDARYCOLOR3FV(loader(\"glSecondaryColor3fv\"))\n C.pfn_glSecondaryColor3i = C.PFNGLSECONDARYCOLOR3I(loader(\"glSecondaryColor3i\"))\n C.pfn_glSecondaryColor3iv = C.PFNGLSECONDARYCOLOR3IV(loader(\"glSecondaryColor3iv\"))\n C.pfn_glSecondaryColor3s = C.PFNGLSECONDARYCOLOR3S(loader(\"glSecondaryColor3s\"))\n C.pfn_glSecondaryColor3sv = C.PFNGLSECONDARYCOLOR3SV(loader(\"glSecondaryColor3sv\"))\n C.pfn_glSecondaryColor3ub = C.PFNGLSECONDARYCOLOR3UB(loader(\"glSecondaryColor3ub\"))\n C.pfn_glSecondaryColor3ubv = C.PFNGLSECONDARYCOLOR3UBV(loader(\"glSecondaryColor3ubv\"))\n C.pfn_glSecondaryColor3ui = C.PFNGLSECONDARYCOLOR3UI(loader(\"glSecondaryColor3ui\"))\n C.pfn_glSecondaryColor3uiv = C.PFNGLSECONDARYCOLOR3UIV(loader(\"glSecondaryColor3uiv\"))\n C.pfn_glSecondaryColor3us = C.PFNGLSECONDARYCOLOR3US(loader(\"glSecondaryColor3us\"))\n C.pfn_glSecondaryColor3usv = C.PFNGLSECONDARYCOLOR3USV(loader(\"glSecondaryColor3usv\"))\n C.pfn_glSecondaryColorPointer = C.PFNGLSECONDARYCOLORPOINTER(loader(\"glSecondaryColorPointer\"))\n C.pfn_glWindowPos2d = C.PFNGLWINDOWPOS2D(loader(\"glWindowPos2d\"))\n C.pfn_glWindowPos2dv = C.PFNGLWINDOWPOS2DV(loader(\"glWindowPos2dv\"))\n C.pfn_glWindowPos2f = C.PFNGLWINDOWPOS2F(loader(\"glWindowPos2f\"))\n C.pfn_glWindowPos2fv = C.PFNGLWINDOWPOS2FV(loader(\"glWindowPos2fv\"))\n C.pfn_glWindowPos2i = C.PFNGLWINDOWPOS2I(loader(\"glWindowPos2i\"))\n C.pfn_glWindowPos2iv = C.PFNGLWINDOWPOS2IV(loader(\"glWindowPos2iv\"))\n C.pfn_glWindowPos2s = C.PFNGLWINDOWPOS2S(loader(\"glWindowPos2s\"))\n C.pfn_glWindowPos2sv = C.PFNGLWINDOWPOS2SV(loader(\"glWindowPos2sv\"))\n C.pfn_glWindowPos3d = C.PFNGLWINDOWPOS3D(loader(\"glWindowPos3d\"))\n C.pfn_glWindowPos3dv = C.PFNGLWINDOWPOS3DV(loader(\"glWindowPos3dv\"))\n C.pfn_glWindowPos3f = C.PFNGLWINDOWPOS3F(loader(\"glWindowPos3f\"))\n C.pfn_glWindowPos3fv = C.PFNGLWINDOWPOS3FV(loader(\"glWindowPos3fv\"))\n C.pfn_glWindowPos3i = C.PFNGLWINDOWPOS3I(loader(\"glWindowPos3i\"))\n C.pfn_glWindowPos3iv = C.PFNGLWINDOWPOS3IV(loader(\"glWindowPos3iv\"))\n C.pfn_glWindowPos3s = C.PFNGLWINDOWPOS3S(loader(\"glWindowPos3s\"))\n C.pfn_glWindowPos3sv = C.PFNGLWINDOWPOS3SV(loader(\"glWindowPos3sv\"))\n\n // OpenGL 1.5\n if !ver.GE(OpenGL, 1, 5) {\n return\n }\n C.pfn_glBeginQuery = C.PFNGLBEGINQUERY(loader(\"glBeginQuery\"))\n C.pfn_glBindBuffer = C.PFNGLBINDBUFFER(loader(\"glBindBuffer\"))\n C.pfn_glBufferData = C.PFNGLBUFFERDATA(loader(\"glBufferData\"))\n C.pfn_glBufferSubData = C.PFNGLBUFFERSUBDATA(loader(\"glBufferSubData\"))\n C.pfn_glDeleteBuffers = C.PFNGLDELETEBUFFERS(loader(\"glDeleteBuffers\"))\n C.pfn_glDeleteQueries = C.PFNGLDELETEQUERIES(loader(\"glDeleteQueries\"))\n C.pfn_glEndQuery = C.PFNGLENDQUERY(loader(\"glEndQuery\"))\n C.pfn_glGenBuffers = C.PFNGLGENBUFFERS(loader(\"glGenBuffers\"))\n C.pfn_glGenQueries = C.PFNGLGENQUERIES(loader(\"glGenQueries\"))\n C.pfn_glGetBufferParameteriv = C.PFNGLGETBUFFERPARAMETERIV(loader(\"glGetBufferParameteriv\"))\n C.pfn_glGetBufferPointerv = C.PFNGLGETBUFFERPOINTERV(loader(\"glGetBufferPointerv\"))\n C.pfn_glGetBufferSubData = C.PFNGLGETBUFFERSUBDATA(loader(\"glGetBufferSubData\"))\n C.pfn_glGetQueryObjectiv = C.PFNGLGETQUERYOBJECTIV(loader(\"glGetQueryObjectiv\"))\n C.pfn_glGetQueryObjectuiv = C.PFNGLGETQUERYOBJECTUIV(loader(\"glGetQueryObjectuiv\"))\n C.pfn_glGetQueryiv = C.PFNGLGETQUERYIV(loader(\"glGetQueryiv\"))\n C.pfn_glIsBuffer = C.PFNGLISBUFFER(loader(\"glIsBuffer\"))\n C.pfn_glIsQuery = C.PFNGLISQUERY(loader(\"glIsQuery\"))\n C.pfn_glMapBuffer = C.PFNGLMAPBUFFER(loader(\"glMapBuffer\"))\n C.pfn_glUnmapBuffer = C.PFNGLUNMAPBUFFER(loader(\"glUnmapBuffer\"))\n\n // OpenGL 2.0\n if !ver.GE(OpenGL, 2, 0) {\n return\n }\n C.pfn_glAttachShader = C.PFNGLATTACHSHADER(loader(\"glAttachShader\"))\n C.pfn_glBindAttribLocation = C.PFNGLBINDATTRIBLOCATION(loader(\"glBindAttribLocation\"))\n C.pfn_glBlendEquationSeparate = C.PFNGLBLENDEQUATIONSEPARATE(loader(\"glBlendEquationSeparate\"))\n C.pfn_glCompileShader = C.PFNGLCOMPILESHADER(loader(\"glCompileShader\"))\n C.pfn_glCreateProgram = C.PFNGLCREATEPROGRAM(loader(\"glCreateProgram\"))\n C.pfn_glCreateShader = C.PFNGLCREATESHADER(loader(\"glCreateShader\"))\n C.pfn_glDeleteProgram = C.PFNGLDELETEPROGRAM(loader(\"glDeleteProgram\"))\n C.pfn_glDeleteShader = C.PFNGLDELETESHADER(loader(\"glDeleteShader\"))\n C.pfn_glDetachShader = C.PFNGLDETACHSHADER(loader(\"glDetachShader\"))\n C.pfn_glDisableVertexAttribArray = C.PFNGLDISABLEVERTEXATTRIBARRAY(loader(\"glDisableVertexAttribArray\"))\n C.pfn_glDrawBuffers = C.PFNGLDRAWBUFFERS(loader(\"glDrawBuffers\"))\n C.pfn_glEnableVertexAttribArray = C.PFNGLENABLEVERTEXATTRIBARRAY(loader(\"glEnableVertexAttribArray\"))\n C.pfn_glGetActiveAttrib = C.PFNGLGETACTIVEATTRIB(loader(\"glGetActiveAttrib\"))\n C.pfn_glGetActiveUniform = C.PFNGLGETACTIVEUNIFORM(loader(\"glGetActiveUniform\"))\n C.pfn_glGetAttachedShaders = C.PFNGLGETATTACHEDSHADERS(loader(\"glGetAttachedShaders\"))\n C.pfn_glGetAttribLocation = C.PFNGLGETATTRIBLOCATION(loader(\"glGetAttribLocation\"))\n C.pfn_glGetProgramInfoLog = C.PFNGLGETPROGRAMINFOLOG(loader(\"glGetProgramInfoLog\"))\n C.pfn_glGetProgramiv = C.PFNGLGETPROGRAMIV(loader(\"glGetProgramiv\"))\n C.pfn_glGetShaderInfoLog = C.PFNGLGETSHADERINFOLOG(loader(\"glGetShaderInfoLog\"))\n C.pfn_glGetShaderSource = C.PFNGLGETSHADERSOURCE(loader(\"glGetShaderSource\"))\n C.pfn_glGetShaderiv = C.PFNGLGETSHADERIV(loader(\"glGetShaderiv\"))\n C.pfn_glGetUniformLocation = C.PFNGLGETUNIFORMLOCATION(loader(\"glGetUniformLocation\"))\n C.pfn_glGetUniformfv = C.PFNGLGETUNIFORMFV(loader(\"glGetUniformfv\"))\n C.pfn_glGetUniformiv = C.PFNGLGETUNIFORMIV(loader(\"glGetUniformiv\"))\n C.pfn_glGetVertexAttribPointerv = C.PFNGLGETVERTEXATTRIBPOINTERV(loader(\"glGetVertexAttribPointerv\"))\n C.pfn_glGetVertexAttribdv = C.PFNGLGETVERTEXATTRIBDV(loader(\"glGetVertexAttribdv\"))\n C.pfn_glGetVertexAttribfv = C.PFNGLGETVERTEXATTRIBFV(loader(\"glGetVertexAttribfv\"))\n C.pfn_glGetVertexAttribiv = C.PFNGLGETVERTEXATTRIBIV(loader(\"glGetVertexAttribiv\"))\n C.pfn_glIsProgram = C.PFNGLISPROGRAM(loader(\"glIsProgram\"))\n C.pfn_glIsShader = C.PFNGLISSHADER(loader(\"glIsShader\"))\n C.pfn_glLinkProgram = C.PFNGLLINKPROGRAM(loader(\"glLinkProgram\"))\n C.pfn_glShaderSource = C.PFNGLSHADERSOURCE(loader(\"glShaderSource\"))\n C.pfn_glStencilFuncSeparate = C.PFNGLSTENCILFUNCSEPARATE(loader(\"glStencilFuncSeparate\"))\n C.pfn_glStencilMaskSeparate = C.PFNGLSTENCILMASKSEPARATE(loader(\"glStencilMaskSeparate\"))\n C.pfn_glStencilOpSeparate = C.PFNGLSTENCILOPSEPARATE(loader(\"glStencilOpSeparate\"))\n C.pfn_glUniform1f = C.PFNGLUNIFORM1F(loader(\"glUniform1f\"))\n C.pfn_glUniform1fv = C.PFNGLUNIFORM1FV(loader(\"glUniform1fv\"))\n C.pfn_glUniform1i = C.PFNGLUNIFORM1I(loader(\"glUniform1i\"))\n C.pfn_glUniform1iv = C.PFNGLUNIFORM1IV(loader(\"glUniform1iv\"))\n C.pfn_glUniform2f = C.PFNGLUNIFORM2F(loader(\"glUniform2f\"))\n C.pfn_glUniform2fv = C.PFNGLUNIFORM2FV(loader(\"glUniform2fv\"))\n C.pfn_glUniform2i = C.PFNGLUNIFORM2I(loader(\"glUniform2i\"))\n C.pfn_glUniform2iv = C.PFNGLUNIFORM2IV(loader(\"glUniform2iv\"))\n C.pfn_glUniform3f = C.PFNGLUNIFORM3F(loader(\"glUniform3f\"))\n C.pfn_glUniform3fv = C.PFNGLUNIFORM3FV(loader(\"glUniform3fv\"))\n C.pfn_glUniform3i = C.PFNGLUNIFORM3I(loader(\"glUniform3i\"))\n C.pfn_glUniform3iv = C.PFNGLUNIFORM3IV(loader(\"glUniform3iv\"))\n C.pfn_glUniform4f = C.PFNGLUNIFORM4F(loader(\"glUniform4f\"))\n C.pfn_glUniform4fv = C.PFNGLUNIFORM4FV(loader(\"glUniform4fv\"))\n C.pfn_glUniform4i = C.PFNGLUNIFORM4I(loader(\"glUniform4i\"))\n C.pfn_glUniform4iv = C.PFNGLUNIFORM4IV(loader(\"glUniform4iv\"))\n C.pfn_glUniformMatrix2fv = C.PFNGLUNIFORMMATRIX2FV(loader(\"glUniformMatrix2fv\"))\n C.pfn_glUniformMatrix3fv = C.PFNGLUNIFORMMATRIX3FV(loader(\"glUniformMatrix3fv\"))\n C.pfn_glUniformMatrix4fv = C.PFNGLUNIFORMMATRIX4FV(loader(\"glUniformMatrix4fv\"))\n C.pfn_glUseProgram = C.PFNGLUSEPROGRAM(loader(\"glUseProgram\"))\n C.pfn_glValidateProgram = C.PFNGLVALIDATEPROGRAM(loader(\"glValidateProgram\"))\n C.pfn_glVertexAttrib1d = C.PFNGLVERTEXATTRIB1D(loader(\"glVertexAttrib1d\"))\n C.pfn_glVertexAttrib1dv = C.PFNGLVERTEXATTRIB1DV(loader(\"glVertexAttrib1dv\"))\n C.pfn_glVertexAttrib1f = C.PFNGLVERTEXATTRIB1F(loader(\"glVertexAttrib1f\"))\n C.pfn_glVertexAttrib1fv = C.PFNGLVERTEXATTRIB1FV(loader(\"glVertexAttrib1fv\"))\n C.pfn_glVertexAttrib1s = C.PFNGLVERTEXATTRIB1S(loader(\"glVertexAttrib1s\"))\n C.pfn_glVertexAttrib1sv = C.PFNGLVERTEXATTRIB1SV(loader(\"glVertexAttrib1sv\"))\n C.pfn_glVertexAttrib2d = C.PFNGLVERTEXATTRIB2D(loader(\"glVertexAttrib2d\"))\n C.pfn_glVertexAttrib2dv = C.PFNGLVERTEXATTRIB2DV(loader(\"glVertexAttrib2dv\"))\n C.pfn_glVertexAttrib2f = C.PFNGLVERTEXATTRIB2F(loader(\"glVertexAttrib2f\"))\n C.pfn_glVertexAttrib2fv = C.PFNGLVERTEXATTRIB2FV(loader(\"glVertexAttrib2fv\"))\n C.pfn_glVertexAttrib2s = C.PFNGLVERTEXATTRIB2S(loader(\"glVertexAttrib2s\"))\n C.pfn_glVertexAttrib2sv = C.PFNGLVERTEXATTRIB2SV(loader(\"glVertexAttrib2sv\"))\n C.pfn_glVertexAttrib3d = C.PFNGLVERTEXATTRIB3D(loader(\"glVertexAttrib3d\"))\n C.pfn_glVertexAttrib3dv = C.PFNGLVERTEXATTRIB3DV(loader(\"glVertexAttrib3dv\"))\n C.pfn_glVertexAttrib3f = C.PFNGLVERTEXATTRIB3F(loader(\"glVertexAttrib3f\"))\n C.pfn_glVertexAttrib3fv = C.PFNGLVERTEXATTRIB3FV(loader(\"glVertexAttrib3fv\"))\n C.pfn_glVertexAttrib3s = C.PFNGLVERTEXATTRIB3S(loader(\"glVertexAttrib3s\"))\n C.pfn_glVertexAttrib3sv = C.PFNGLVERTEXATTRIB3SV(loader(\"glVertexAttrib3sv\"))\n C.pfn_glVertexAttrib4Nbv = C.PFNGLVERTEXATTRIB4NBV(loader(\"glVertexAttrib4Nbv\"))\n C.pfn_glVertexAttrib4Niv = C.PFNGLVERTEXATTRIB4NIV(loader(\"glVertexAttrib4Niv\"))\n C.pfn_glVertexAttrib4Nsv = C.PFNGLVERTEXATTRIB4NSV(loader(\"glVertexAttrib4Nsv\"))\n C.pfn_glVertexAttrib4Nub = C.PFNGLVERTEXATTRIB4NUB(loader(\"glVertexAttrib4Nub\"))\n C.pfn_glVertexAttrib4Nubv = C.PFNGLVERTEXATTRIB4NUBV(loader(\"glVertexAttrib4Nubv\"))\n C.pfn_glVertexAttrib4Nuiv = C.PFNGLVERTEXATTRIB4NUIV(loader(\"glVertexAttrib4Nuiv\"))\n C.pfn_glVertexAttrib4Nusv = C.PFNGLVERTEXATTRIB4NUSV(loader(\"glVertexAttrib4Nusv\"))\n C.pfn_glVertexAttrib4bv = C.PFNGLVERTEXATTRIB4BV(loader(\"glVertexAttrib4bv\"))\n C.pfn_glVertexAttrib4d = C.PFNGLVERTEXATTRIB4D(loader(\"glVertexAttrib4d\"))\n C.pfn_glVertexAttrib4dv = C.PFNGLVERTEXATTRIB4DV(loader(\"glVertexAttrib4dv\"))\n C.pfn_glVertexAttrib4f = C.PFNGLVERTEXATTRIB4F(loader(\"glVertexAttrib4f\"))\n C.pfn_glVertexAttrib4fv = C.PFNGLVERTEXATTRIB4FV(loader(\"glVertexAttrib4fv\"))\n C.pfn_glVertexAttrib4iv = C.PFNGLVERTEXATTRIB4IV(loader(\"glVertexAttrib4iv\"))\n C.pfn_glVertexAttrib4s = C.PFNGLVERTEXATTRIB4S(loader(\"glVertexAttrib4s\"))\n C.pfn_glVertexAttrib4sv = C.PFNGLVERTEXATTRIB4SV(loader(\"glVertexAttrib4sv\"))\n C.pfn_glVertexAttrib4ubv = C.PFNGLVERTEXATTRIB4UBV(loader(\"glVertexAttrib4ubv\"))\n C.pfn_glVertexAttrib4uiv = C.PFNGLVERTEXATTRIB4UIV(loader(\"glVertexAttrib4uiv\"))\n C.pfn_glVertexAttrib4usv = C.PFNGLVERTEXATTRIB4USV(loader(\"glVertexAttrib4usv\"))\n C.pfn_glVertexAttribPointer = C.PFNGLVERTEXATTRIBPOINTER(loader(\"glVertexAttribPointer\"))\n\n // OpenGL 2.1\n if !ver.GE(OpenGL, 2, 1) {\n return\n }\n C.pfn_glUniformMatrix2x3fv = C.PFNGLUNIFORMMATRIX2X3FV(loader(\"glUniformMatrix2x3fv\"))\n C.pfn_glUniformMatrix2x4fv = C.PFNGLUNIFORMMATRIX2X4FV(loader(\"glUniformMatrix2x4fv\"))\n C.pfn_glUniformMatrix3x2fv = C.PFNGLUNIFORMMATRIX3X2FV(loader(\"glUniformMatrix3x2fv\"))\n C.pfn_glUniformMatrix3x4fv = C.PFNGLUNIFORMMATRIX3X4FV(loader(\"glUniformMatrix3x4fv\"))\n C.pfn_glUniformMatrix4x2fv = C.PFNGLUNIFORMMATRIX4X2FV(loader(\"glUniformMatrix4x2fv\"))\n C.pfn_glUniformMatrix4x3fv = C.PFNGLUNIFORMMATRIX4X3FV(loader(\"glUniformMatrix4x3fv\"))\n}", "func (b *XMobileBackend) GetImageData(x, y, w, h int) *image.RGBA {\n\tb.activate()\n\n\tif x < 0 {\n\t\tw += x\n\t\tx = 0\n\t}\n\tif y < 0 {\n\t\th += y\n\t\ty = 0\n\t}\n\tif w > b.w {\n\t\tw = b.w\n\t}\n\tif h > b.h {\n\t\th = b.h\n\t}\n\n\tvar vp [4]int32\n\tb.glctx.GetIntegerv(vp[:], gl.VIEWPORT)\n\n\tsize := int(vp[2] * vp[3] * 3)\n\tif len(b.imageBuf) < size {\n\t\tb.imageBuf = make([]byte, size)\n\t}\n\tb.glctx.ReadPixels(b.imageBuf[0:], int(vp[0]), int(vp[1]), int(vp[2]), int(vp[3]), gl.RGB, gl.UNSIGNED_BYTE)\n\n\trgba := image.NewRGBA(image.Rect(x, y, x+w, y+h))\n\tfor cy := y; cy < y+h; cy++ {\n\t\tbp := (int(vp[3])-h+cy)*int(vp[2])*3 + x*3\n\t\tfor cx := x; cx < x+w; cx++ {\n\t\t\trgba.SetRGBA(cx, y+h-1-cy, color.RGBA{R: b.imageBuf[bp], G: b.imageBuf[bp+1], B: b.imageBuf[bp+2], A: 255})\n\t\t\tbp += 3\n\t\t}\n\t}\n\treturn rgba\n}", "func imageToJsValue(img image.Image) (*js.Value, error) {\n\tbuf := new(bytes.Buffer)\n\terr := jpeg.Encode(buf, img, nil)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\n\timgBytes := buf.Bytes()\n\tret := js.Global().Get(\"Uint8Array\").New(len(imgBytes))\n\tjs.CopyBytesToJS(ret, imgBytes)\n\treturn &ret, nil\n}", "func GetTexParameteriv(dst []int32, target, pname Enum) {\n\tgl.GetTexParameteriv(uint32(target), uint32(pname), &dst[0])\n}", "func getImageName(w http.ResponseWriter, r *http.Request, parms martini.Params) {\r\n\tid, _ := strconv.ParseInt(parms[\"id\"], 10, 64)\r\n\tvar img CRImage\r\n\timage := img.Querylog(id)\r\n\t// name := image.ImageName + \":\" + strconv.Itoa(image.Tag)\r\n\t// log.Println(name)\r\n\t// fullName := imageFullName{fullname: name}\r\n\tif err := json.NewEncoder(w).Encode(image); err != nil {\r\n\t\tlogger.Error(err)\r\n\t\thttp.Error(w, err.Error(), http.StatusInternalServerError)\r\n\t}\r\n}", "func TexImage3D(target uint32, level int32, internalformat int32, width int32, height int32, depth int32, border int32, format uint32, xtype uint32, pixels unsafe.Pointer) {\n C.glowTexImage3D(gpTexImage3D, (C.GLenum)(target), (C.GLint)(level), (C.GLint)(internalformat), (C.GLsizei)(width), (C.GLsizei)(height), (C.GLsizei)(depth), (C.GLint)(border), (C.GLenum)(format), (C.GLenum)(xtype), pixels)\n}", "func GetBufferParameteriv(target uint32, pname uint32, params *int32) {\n C.glowGetBufferParameteriv(gpGetBufferParameteriv, (C.GLenum)(target), (C.GLenum)(pname), (*C.GLint)(unsafe.Pointer(params)))\n}", "func EGLImageTargetTexStorageEXT(target uint32, image unsafe.Pointer, attrib_list *int32) {\n\tsyscall.Syscall(gpEGLImageTargetTexStorageEXT, 3, uintptr(target), uintptr(image), uintptr(unsafe.Pointer(attrib_list)))\n}", "func GetRenderbufferParameteri(target, pname Enum) int {\n\tlog.Println(\"GetRenderbufferParameteri: not yet tested (TODO: remove this after it's confirmed to work. Your feedback is welcome.)\")\n\tvar result int32\n\tgl.GetRenderbufferParameteriv(uint32(target), uint32(pname), &result)\n\treturn int(result)\n}", "func FramebufferParameteri(target uint32, pname uint32, param int32) {\n\tC.glowFramebufferParameteri(gpFramebufferParameteri, (C.GLenum)(target), (C.GLenum)(pname), (C.GLint)(param))\n}", "func FramebufferParameteri(target uint32, pname uint32, param int32) {\n\tC.glowFramebufferParameteri(gpFramebufferParameteri, (C.GLenum)(target), (C.GLenum)(pname), (C.GLint)(param))\n}", "func (imageService Service) ReserveImage (uploadParameters UploadParameters, hypervisor string, mode string) (ID string, Status string, err error) {\n\taddImageContainer := glanceAddImageResponse {}\n\theaders := make( []string, 10 )\n\n\ti := 0\n\theaders[i] = \"x-image-meta-name^\" + uploadParameters.Name\n\ti++\n\theaders[i] = \"x-image-meta-disk_format^\" + uploadParameters.DiskFormat\n\ti++\n\theaders[i] = \"x-image-meta-container_format^\" + uploadParameters.ContainerFormat\n\ti++\n\n\theaders[i] = \"x-image-meta-property-hypervisor_type^\" + hypervisor\n\ti++\n\n\theaders[i] = \"x-image-meta-property-vm_mode^\" + mode\n\ti++\n\n\tif uploadParameters.CopyFromUrl != \"\" {\n\t\theaders[i] = \"x-glance-api-copy-from^\" + uploadParameters.CopyFromUrl\n\t\ti++\n\t}\n\n\tif uploadParameters.Owner != \"\" {\n\t\theaders[i] = \"x-glance-meta-owner^\" + uploadParameters.Owner \n\t\ti++\n\t}\n\n\tif uploadParameters.IsPublic {\n\t\theaders[i] = \"x-image-meta-is_public^true\"\n\t\ti++\n\t}\n\n\tif uploadParameters.MinRam != 0 {\n\t\theaders[i] = \"x-image-meta-min_ram^\" + fmt.Sprintf(\"%d\", uploadParameters.MinRam)\n\t\ti++\n\t}\n\n\tif uploadParameters.MinDisk != 0 {\n\t\theaders[i] = \"x-image-meta-min_disk^\" + fmt.Sprintf(\"%d\", uploadParameters.MinDisk)\n\t\ti++\n\t}\n\n\turl := strings.TrimSuffix(imageService.URL, \"/\") + \"/images\"\n\terr = misc.PostHeader(url, imageService.TokenID, imageService.Client, headers, &addImageContainer)\n\tif err != nil {\n\t\treturn \"\", \"\", err\n\t}\n\n\tID = addImageContainer.Image.ID\n\tStatus = addImageContainer.Image.Status\n\n\treturn \n}", "func Image(ctx *gin.Context) {\n\n\tvar body v1r.ImagePayload\n\terr := ctx.Bind(&body)\n\tif err != nil {\n\t\tctx.JSON(http.StatusBadRequest, gin.H{\n\t\t\t\"Error\": err.Error(),\n\t\t})\n\t\tctx.Abort()\n\t\treturn\n\t}\n\n\tfile, header, err := ctx.Request.FormFile(\"file\")\n\tif err != nil {\n\t\tctx.JSON(http.StatusBadRequest, gin.H{\n\t\t\t\"Error\": err.Error(),\n\t\t})\n\t\tctx.Abort()\n\t\treturn\n\t}\n\n\tif header.Size > SIZE {\n\t\tctx.JSON(http.StatusBadRequest, gin.H{\n\t\t\t\"Error\": \"file size should be less than 5MB\",\n\t\t})\n\t\tctx.Abort()\n\t\treturn\n\t}\n\n\tbuff := make([]byte, 512) // see http://golang.org/pkg/net/http/#DetectContentType\n\t_, _ = file.Read(buff)\n\tfileType := http.DetectContentType(buff)\n\n\tre, _ := regexp.Compile(fileType)\n\tmatched := re.FindString(\"image/png image/jpeg\")\n\tif matched == \"\" {\n\t\tctx.JSON(http.StatusBadRequest, gin.H{\n\t\t\t\"Error\": \"Invalid filetype, must be jpeg or png.\",\n\t\t})\n\t\tctx.Abort()\n\t\treturn\n\t}\n\n\tctxData, _ := ctx.Get(\"client_name\")\n\tclient_name := fmt.Sprint(ctxData)\n\n\tuuid, err := v1s.ImageUpload(client_name, file, header, body)\n\tif err != nil {\n\t\tctx.JSON(http.StatusBadRequest, gin.H{\n\t\t\t\"Error\": err.Error(),\n\t\t})\n\t\tctx.Abort()\n\t\treturn\n\t}\n\n\tctx.JSON(http.StatusOK, gin.H{\n\t\t\"imageID\": uuid,\n\t})\n}", "func (debugging *debuggingOpenGL) TexParameteri(target uint32, pname uint32, param int32) {\n\tdebugging.recordEntry(\"TexParameteri\", target, pname, param)\n\tdebugging.gl.TexParameteri(target, pname, param)\n\tdebugging.recordExit(\"TexParameteri\")\n}", "func GetTextureImage(texture uint32, level int32, format uint32, xtype uint32, bufSize int32, pixels unsafe.Pointer) {\n\tsyscall.Syscall6(gpGetTextureImage, 6, uintptr(texture), uintptr(level), uintptr(format), uintptr(xtype), uintptr(bufSize), uintptr(pixels))\n}", "func Uniform2fv(location int32, count int32, value *float32) {\n C.glowUniform2fv(gpUniform2fv, (C.GLint)(location), (C.GLsizei)(count), (*C.GLfloat)(unsafe.Pointer(value)))\n}", "func imgLed(camera int, mode int) int {\n\tlog.Printf(\"imgLed camera:%d mode:%d\", camera, mode)\n\tvar f = mod.NewProc(\"img_led\")\n\tret, _, _ := f.Call(uintptr(camera), uintptr(mode))\n\treturn int(ret) // retval is cameraID\n}", "func BufferData(target uint32, size int, data unsafe.Pointer, usage uint32) {\n C.glowBufferData(gpBufferData, (C.GLenum)(target), (C.GLsizeiptr)(size), data, (C.GLenum)(usage))\n}", "func checkImage(L *lua.LState) *common.Entity {\n\tud := L.CheckUserData(1)\n\tif v, ok := ud.Value.(*common.Entity); ok {\n\t\treturn v\n\t}\n\tL.ArgError(1, \"image expected\")\n\treturn nil\n}", "func ReleaseTexImageARB(hPbuffer unsafe.Pointer, iBuffer unsafe.Pointer) unsafe.Pointer {\n\tret, _, _ := syscall.Syscall(gpReleaseTexImageARB, 2, uintptr(hPbuffer), uintptr(iBuffer), 0)\n\treturn (unsafe.Pointer)(ret)\n}", "func (s *SpendPacket) Image() []byte {\n\tcalltype := make([]byte, 8)\n\tbinary.BigEndian.PutUint32(calltype, uint32(s.CallType))\n\th := sha256.Sum256(append(calltype, s.Token...))\n\treturn h[:]\n}", "func handler_image(w http.ResponseWriter, r *http.Request) {\n\tgetImage(w, num) // fetch the base64 encoded png image\n}", "func BindTexImageARB(hPbuffer unsafe.Pointer, iBuffer unsafe.Pointer) unsafe.Pointer {\n\tret, _, _ := syscall.Syscall(gpBindTexImageARB, 2, uintptr(hPbuffer), uintptr(iBuffer), 0)\n\treturn (unsafe.Pointer)(ret)\n}", "func linearImage(srcim image.Image, gamma float64) *image.NRGBA64 {\n\tdstim := image.NewNRGBA64(image.Rectangle{\n\t\tMax: image.Point{\n\t\t\tX: srcim.Bounds().Dx(),\n\t\t\tY: srcim.Bounds().Dy(),\n\t\t},\n\t})\n\tvar dsty int\n\tfor srcy := srcim.Bounds().Min.Y; srcy < srcim.Bounds().Max.Y; srcy++ {\n\t\tvar dstx int\n\t\tfor srcx := srcim.Bounds().Min.X; srcx < srcim.Bounds().Max.X; srcx++ {\n\t\t\tnrgba64 := color.NRGBA64Model.Convert(srcim.At(srcx, srcy)).(color.NRGBA64)\n\t\t\tnrgba64.R = uint16(nrgba64Max * math.Pow(float64(nrgba64.R)/nrgba64Max, gamma))\n\t\t\tnrgba64.G = uint16(nrgba64Max * math.Pow(float64(nrgba64.G)/nrgba64Max, gamma))\n\t\t\tnrgba64.B = uint16(nrgba64Max * math.Pow(float64(nrgba64.B)/nrgba64Max, gamma))\n\t\t\t// Alpha is not affected\n\t\t\tdstim.SetNRGBA64(dstx, dsty, nrgba64)\n\t\t\tdstx++\n\t\t}\n\t\tdsty++\n\t}\n\treturn dstim\n}", "func GetNamedRenderbufferParameteriv(renderbuffer uint32, pname uint32, params *int32) {\n\tC.glowGetNamedRenderbufferParameteriv(gpGetNamedRenderbufferParameteriv, (C.GLuint)(renderbuffer), (C.GLenum)(pname), (*C.GLint)(unsafe.Pointer(params)))\n}", "func GetNamedRenderbufferParameteriv(renderbuffer uint32, pname uint32, params *int32) {\n\tC.glowGetNamedRenderbufferParameteriv(gpGetNamedRenderbufferParameteriv, (C.GLuint)(renderbuffer), (C.GLenum)(pname), (*C.GLint)(unsafe.Pointer(params)))\n}", "func (self *Graphics) GenerateTextureI(args ...interface{}) *Texture{\n return &Texture{self.Object.Call(\"generateTexture\", args)}\n}", "func createImage(w, h int) image.Image {\n\t// create a RGBA image from the sensor\n\tpixels := image.NewRGBA(image.Rect(0, 0, w, h))\n\tn := 0\n\tfor _, i := range grid {\n\t\tcolor := colors[getColorIndex(i)]\n\t\tpixels.Pix[n] = getR(color)\n\t\tpixels.Pix[n+1] = getG(color)\n\t\tpixels.Pix[n+2] = getB(color)\n\t\tpixels.Pix[n+3] = 0xFF // we don't need to use this\n\t\tn = n + 4\n\t}\n\tdest := resize.Resize(360, 0, pixels, resize.Lanczos3)\n\treturn dest\n}", "func (self *GameObjectCreator) RenderTexture1O(width int) *RenderTexture{\n return &RenderTexture{self.Object.Call(\"renderTexture\", width)}\n}", "func Image(asset_path string, width, height int) ([]uint32, error) {\n pil := find(asset_path)\n if pil == nil { return nil, os.ErrNotExist }\n var imass ImageAsset\n imass, ok := pil.asset.(ImageAsset)\n if !ok { return nil, ErrAssetType }\n return imass.Render(width,height)\n}", "func (b *GoGLBackendOffscreen) AsImage() backendbase.Image {\n\treturn &b.offscrImg\n}", "func GetBufferParameteri(target, pname Enum) int {\n\tvar params int32\n\tgl.GetBufferParameteriv(uint32(target), uint32(pname), &params)\n\treturn int(params)\n}", "func (a *ImageApiService) GetGenreImage(ctx _context.Context, name string, imageType ImageType, imageIndex int32, localVarOptionals *GetGenreImageOpts) (*os.File, *_nethttp.Response, error) {\n\tvar (\n\t\tlocalVarHTTPMethod = _nethttp.MethodGet\n\t\tlocalVarPostBody interface{}\n\t\tlocalVarFormFileName string\n\t\tlocalVarFileName string\n\t\tlocalVarFileBytes []byte\n\t\tlocalVarReturnValue *os.File\n\t)\n\n\t// create path and map variables\n\tlocalVarPath := a.client.cfg.BasePath + \"/Genres/{name}/Images/{imageType}/{imageIndex}\"\n\tlocalVarPath = strings.Replace(localVarPath, \"{\"+\"name\"+\"}\", _neturl.QueryEscape(parameterToString(name, \"\")) , -1)\n\n\tlocalVarPath = strings.Replace(localVarPath, \"{\"+\"imageType\"+\"}\", _neturl.QueryEscape(parameterToString(imageType, \"\")) , -1)\n\n\tlocalVarPath = strings.Replace(localVarPath, \"{\"+\"imageIndex\"+\"}\", _neturl.QueryEscape(parameterToString(imageIndex, \"\")) , -1)\n\n\tlocalVarHeaderParams := make(map[string]string)\n\tlocalVarQueryParams := _neturl.Values{}\n\tlocalVarFormParams := _neturl.Values{}\n\n\tif localVarOptionals != nil && localVarOptionals.Tag.IsSet() {\n\t\tlocalVarQueryParams.Add(\"tag\", parameterToString(localVarOptionals.Tag.Value(), \"\"))\n\t}\n\tif localVarOptionals != nil && localVarOptionals.Format.IsSet() {\n\t\tlocalVarQueryParams.Add(\"format\", parameterToString(localVarOptionals.Format.Value(), \"\"))\n\t}\n\tif localVarOptionals != nil && localVarOptionals.MaxWidth.IsSet() {\n\t\tlocalVarQueryParams.Add(\"maxWidth\", parameterToString(localVarOptionals.MaxWidth.Value(), \"\"))\n\t}\n\tif localVarOptionals != nil && localVarOptionals.MaxHeight.IsSet() {\n\t\tlocalVarQueryParams.Add(\"maxHeight\", parameterToString(localVarOptionals.MaxHeight.Value(), \"\"))\n\t}\n\tif localVarOptionals != nil && localVarOptionals.PercentPlayed.IsSet() {\n\t\tlocalVarQueryParams.Add(\"percentPlayed\", parameterToString(localVarOptionals.PercentPlayed.Value(), \"\"))\n\t}\n\tif localVarOptionals != nil && localVarOptionals.UnplayedCount.IsSet() {\n\t\tlocalVarQueryParams.Add(\"unplayedCount\", parameterToString(localVarOptionals.UnplayedCount.Value(), \"\"))\n\t}\n\tif localVarOptionals != nil && localVarOptionals.Width.IsSet() {\n\t\tlocalVarQueryParams.Add(\"width\", parameterToString(localVarOptionals.Width.Value(), \"\"))\n\t}\n\tif localVarOptionals != nil && localVarOptionals.Height.IsSet() {\n\t\tlocalVarQueryParams.Add(\"height\", parameterToString(localVarOptionals.Height.Value(), \"\"))\n\t}\n\tif localVarOptionals != nil && localVarOptionals.Quality.IsSet() {\n\t\tlocalVarQueryParams.Add(\"quality\", parameterToString(localVarOptionals.Quality.Value(), \"\"))\n\t}\n\tif localVarOptionals != nil && localVarOptionals.CropWhitespace.IsSet() {\n\t\tlocalVarQueryParams.Add(\"cropWhitespace\", parameterToString(localVarOptionals.CropWhitespace.Value(), \"\"))\n\t}\n\tif localVarOptionals != nil && localVarOptionals.AddPlayedIndicator.IsSet() {\n\t\tlocalVarQueryParams.Add(\"addPlayedIndicator\", parameterToString(localVarOptionals.AddPlayedIndicator.Value(), \"\"))\n\t}\n\tif localVarOptionals != nil && localVarOptionals.Blur.IsSet() {\n\t\tlocalVarQueryParams.Add(\"blur\", parameterToString(localVarOptionals.Blur.Value(), \"\"))\n\t}\n\tif localVarOptionals != nil && localVarOptionals.BackgroundColor.IsSet() {\n\t\tlocalVarQueryParams.Add(\"backgroundColor\", parameterToString(localVarOptionals.BackgroundColor.Value(), \"\"))\n\t}\n\tif localVarOptionals != nil && localVarOptionals.ForegroundLayer.IsSet() {\n\t\tlocalVarQueryParams.Add(\"foregroundLayer\", parameterToString(localVarOptionals.ForegroundLayer.Value(), \"\"))\n\t}\n\t// to determine the Content-Type header\n\tlocalVarHTTPContentTypes := []string{}\n\n\t// set Content-Type header\n\tlocalVarHTTPContentType := selectHeaderContentType(localVarHTTPContentTypes)\n\tif localVarHTTPContentType != \"\" {\n\t\tlocalVarHeaderParams[\"Content-Type\"] = localVarHTTPContentType\n\t}\n\n\t// to determine the Accept header\n\tlocalVarHTTPHeaderAccepts := []string{\"image/_*\", \"application/json\", \"application/json; profile=CamelCase\", \"application/json; profile=PascalCase\"}\n\n\t// set Accept header\n\tlocalVarHTTPHeaderAccept := selectHeaderAccept(localVarHTTPHeaderAccepts)\n\tif localVarHTTPHeaderAccept != \"\" {\n\t\tlocalVarHeaderParams[\"Accept\"] = localVarHTTPHeaderAccept\n\t}\n\tif ctx != nil {\n\t\t// API Key Authentication\n\t\tif auth, ok := ctx.Value(ContextAPIKey).(APIKey); ok {\n\t\t\tvar key string\n\t\t\tif auth.Prefix != \"\" {\n\t\t\t\tkey = auth.Prefix + \" \" + auth.Key\n\t\t\t} else {\n\t\t\t\tkey = auth.Key\n\t\t\t}\n\t\t\tlocalVarHeaderParams[\"X-Emby-Authorization\"] = key\n\t\t}\n\t}\n\tr, err := a.client.prepareRequest(ctx, localVarPath, localVarHTTPMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFormFileName, localVarFileName, localVarFileBytes)\n\tif err != nil {\n\t\treturn localVarReturnValue, nil, err\n\t}\n\n\tlocalVarHTTPResponse, err := a.client.callAPI(r)\n\tif err != nil || localVarHTTPResponse == nil {\n\t\treturn localVarReturnValue, localVarHTTPResponse, err\n\t}\n\n\tlocalVarBody, err := _ioutil.ReadAll(localVarHTTPResponse.Body)\n\tlocalVarHTTPResponse.Body.Close()\n\tif err != nil {\n\t\treturn localVarReturnValue, localVarHTTPResponse, err\n\t}\n\n\tif localVarHTTPResponse.StatusCode >= 300 {\n\t\tnewErr := GenericOpenAPIError{\n\t\t\tbody: localVarBody,\n\t\t\terror: localVarHTTPResponse.Status,\n\t\t}\n\t\tif localVarHTTPResponse.StatusCode == 404 {\n\t\t\tvar v ProblemDetails\n\t\t\terr = a.client.decode(&v, localVarBody, localVarHTTPResponse.Header.Get(\"Content-Type\"))\n\t\t\tif err != nil {\n\t\t\t\tnewErr.error = err.Error()\n\t\t\t\treturn localVarReturnValue, localVarHTTPResponse, newErr\n\t\t\t}\n\t\t\tnewErr.model = v\n\t\t}\n\t\treturn localVarReturnValue, localVarHTTPResponse, newErr\n\t}\n\n\terr = a.client.decode(&localVarReturnValue, localVarBody, localVarHTTPResponse.Header.Get(\"Content-Type\"))\n\tif err != nil {\n\t\tnewErr := GenericOpenAPIError{\n\t\t\tbody: localVarBody,\n\t\t\terror: err.Error(),\n\t\t}\n\t\treturn localVarReturnValue, localVarHTTPResponse, newErr\n\t}\n\n\treturn localVarReturnValue, localVarHTTPResponse, nil\n}", "func newImageFromNative(obj unsafe.Pointer) interface{} {\n\tim := &Image{}\n\tim.object = C.to_GtkImage(obj)\n\n\tif gobject.IsObjectFloating(im) {\n\t\tgobject.RefSink(im)\n\t} else {\n\t\tgobject.Ref(im)\n\t}\n\tim.Widget = NewWidget(obj)\n\timageFinalizer(im)\n\n\treturn im\n}", "func (e *Escpos) Image(params map[string]string, data string) {\n\t// send alignment to printer\n\tif align, ok := params[\"align\"]; ok {\n\t\te.SetAlign(align)\n\t}\n\n\t// get width\n\twstr, ok := params[\"width\"]\n\tif !ok {\n\t\tlog.Println(\"No width specified on image\")\n\t}\n\n\t// get height\n\thstr, ok := params[\"height\"]\n\tif !ok {\n\t\tlog.Println(\"No height specified on image\")\n\t}\n\n\t// convert width\n\twidth, err := strconv.Atoi(wstr)\n\tif err != nil {\n\t\tlog.Println(\"Invalid image width %s\", wstr)\n\t}\n\n\t// convert height\n\theight, err := strconv.Atoi(hstr)\n\tif err != nil {\n\t\tlog.Println(\"Invalid image height %s\", hstr)\n\t}\n\n\t// decode data frome b64 string\n\tdec, err := base64.StdEncoding.DecodeString(data)\n\tif err != nil {\n\t\tlog.Println(err.Error())\n\t}\n\n\tif e.Verbose {\n\t\tlog.Println(\"Image len:%d w: %d h: %d\\n\", len(dec), width, height)\n\t}\n\n\theader := []byte{\n\t\tbyte('0'), 0x01, 0x01, byte('1'),\n\t}\n\n\ta := append(header, dec...)\n\n\te.gSend(byte('0'), byte('p'), a)\n\te.gSend(byte('0'), byte('2'), []byte{})\n\n}", "func BindImageTexture(unit uint32, texture uint32, level int32, layered bool, layer int32, access uint32, format uint32) {\n\tC.glowBindImageTexture(gpBindImageTexture, (C.GLuint)(unit), (C.GLuint)(texture), (C.GLint)(level), (C.GLboolean)(boolToInt(layered)), (C.GLint)(layer), (C.GLenum)(access), (C.GLenum)(format))\n}", "func BindImageTexture(unit uint32, texture uint32, level int32, layered bool, layer int32, access uint32, format uint32) {\n\tC.glowBindImageTexture(gpBindImageTexture, (C.GLuint)(unit), (C.GLuint)(texture), (C.GLint)(level), (C.GLboolean)(boolToInt(layered)), (C.GLint)(layer), (C.GLenum)(access), (C.GLenum)(format))\n}", "func imageLogs(w http.ResponseWriter, r *http.Request, parms martini.Params) {\r\n\tid, _ := strconv.ParseInt(parms[\"id\"], 10, 64)\r\n\tvar img CRImage\r\n\timage := img.Querylog(id)\r\n\tif err := json.NewEncoder(w).Encode(*image); err != nil {\r\n\t\tlogger.Error(err)\r\n\t\thttp.Error(w, err.Error(), http.StatusInternalServerError)\r\n\t}\r\n}", "func TexParameterfv(target, pname Enum, params []float32) {\n\tgl.TexParameterfv(uint32(target), uint32(pname), &params[0])\n}", "func (et ElementType) getGLType() (gltype uint32) {\n\tswitch et {\n\tcase VEC2:\n\t\treturn gl.INT\n\tcase VEC3:\n\t\treturn gl.INT\n\tcase VEC4:\n\t\treturn gl.INT\n\tcase FVEC2:\n\t\treturn gl.FLOAT\n\tcase FVEC3:\n\t\treturn gl.FLOAT\n\tcase FVEC4:\n\t\treturn gl.FLOAT\n\tdefault:\n\t\treturn 0\n\t}\n}", "func PixelStorei(pname Enum, param int32) {\n\tgl.PixelStorei(uint32(pname), param)\n}", "func Image(id, ref string) imageapi.Image {\n\treturn AgedImage(id, ref, 120)\n}" ]
[ "0.5703575", "0.5673022", "0.5646862", "0.5610714", "0.55872226", "0.55618536", "0.55437726", "0.55379856", "0.55379856", "0.5449579", "0.5444548", "0.5423716", "0.5417828", "0.5409993", "0.537816", "0.53615034", "0.5347774", "0.53440773", "0.532743", "0.532743", "0.5324721", "0.53223515", "0.5309703", "0.529029", "0.52756894", "0.52560204", "0.5255316", "0.5227739", "0.5227739", "0.52212095", "0.52212095", "0.5194233", "0.5170098", "0.5165198", "0.5161397", "0.513421", "0.5122381", "0.5112748", "0.510941", "0.51041377", "0.5102257", "0.5090856", "0.50746804", "0.50629485", "0.5043684", "0.5024329", "0.5009807", "0.49857065", "0.4979755", "0.4959194", "0.49465373", "0.49306804", "0.4928748", "0.4928748", "0.49152797", "0.4911692", "0.4911692", "0.49115992", "0.4905679", "0.49027234", "0.48931903", "0.4886503", "0.48832688", "0.48690814", "0.48650682", "0.48599276", "0.48551628", "0.48551628", "0.4852301", "0.48507798", "0.48413882", "0.48258346", "0.4821575", "0.48162425", "0.4812542", "0.4805833", "0.47810367", "0.47775254", "0.47684383", "0.47576657", "0.47576553", "0.47474897", "0.47474897", "0.47443736", "0.47399974", "0.47351357", "0.47239885", "0.46966222", "0.46890777", "0.46833327", "0.4681285", "0.4671785", "0.46670982", "0.46670982", "0.46634644", "0.46607104", "0.46604368", "0.46524036", "0.46305436" ]
0.5777002
1